diff --git a/data/study-reminders.json b/data/study-reminders.json index 6974f84..ec992c2 100644 --- a/data/study-reminders.json +++ b/data/study-reminders.json @@ -1,4 +1,4 @@ { "users": {}, - "updatedAt": "2026-06-04T13:16:50.352Z" + "updatedAt": "2026-06-04T13:37:05.049Z" } \ No newline at end of file diff --git a/src/App.css b/src/App.css index f39b177..281e2ee 100644 --- a/src/App.css +++ b/src/App.css @@ -1131,6 +1131,12 @@ margin-bottom: 0.5rem; } +.tfl-widget-wrap iframe { + max-width: 760px; + margin: 0 auto; + display: block; +} + .tfl-attribution { color: #8a7f5a; font-size: 0.9rem; diff --git a/src/App.tsx b/src/App.tsx index 4360ce8..cadb174 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1056,13 +1056,11 @@ function HomepageNewsletterSection() { ) } -type TflWidgetType = 'audiodevo' | 'abdevotional' +type TflWidgetType = 'audiodevo' | 'abdevotional' | 'resourcead' function TruthForLifeWidget({ type = 'audiodevo' }: { type?: TflWidgetType }) { - // Use an iframe so TFL's script gets a fresh page context with its own - // DOMContentLoaded — required because this is a SPA and that event has - // already fired on the outer page before this component ever mounts. - const iframeHeight = type === 'audiodevo' ? '420' : '800' + const iframeHeight = type === 'audiodevo' ? '420' : type === 'resourcead' ? '270' : '800' + const heading = type === 'resourcead' ? 'Recommended Resources' : 'Daily Devotional' const srcdoc = ` @@ -1085,11 +1083,11 @@ function TruthForLifeWidget({ type = 'audiodevo' }: { type?: TflWidgetType }) { ` return ( -
+
-
+

- Daily Devotional + {heading}

Truth For Life @@ -1102,7 +1100,7 @@ function TruthForLifeWidget({ type = 'audiodevo' }: { type?: TflWidgetType }) { title="Truth For Life daily devotional" width="100%" height={iframeHeight} - style={{ border: 'none', display: 'block', borderRadius: '10px' }} + style={{ border: 'none', display: 'block', borderRadius: '10px', maxWidth: type === 'resourcead' ? '500px' : '760px', margin: '0 auto' }} sandbox="allow-scripts allow-same-origin allow-popups" />

@@ -1663,6 +1661,7 @@ function ResourcesPage({ content }: { content: SiteContent }) { +