From 103e14dbc9edf9668f389a1e5ea740b30cf43cd5 Mon Sep 17 00:00:00 2001 From: Joshua Ryder Date: Wed, 1 Oct 2025 23:18:42 -0400 Subject: [PATCH] Add font size selector to sermon view page with Small, Medium, and Large options --- pages/[slug].vue | 37 +++++++++++++++++++++++++++++++++---- 1 file changed, 33 insertions(+), 4 deletions(-) diff --git a/pages/[slug].vue b/pages/[slug].vue index 1466599..a5ce628 100644 --- a/pages/[slug].vue +++ b/pages/[slug].vue @@ -6,7 +6,21 @@ New Life Christian Church - +
+
+ + +
+ +
@@ -29,7 +43,7 @@ class="bg-blue-50 rounded-lg p-6" >
-

+

{{ ref.text }}

@@ -45,7 +59,7 @@

Personal Appliance

-

{{ sermon.personal_appliance }}

+

{{ sermon.personal_appliance }}

@@ -53,7 +67,7 @@

Pastor's Challenge

-

{{ sermon.pastors_challenge }}

+

{{ sermon.pastors_challenge }}

@@ -95,6 +109,9 @@ const slug = route.params.slug as string const { data: sermon } = await useFetch(`/api/sermons/${slug}`) +// Font size state +const fontSize = ref('medium') + const bibleReferences = computed(() => { if (!sermon.value?.bible_references) return [] try { @@ -108,6 +125,18 @@ const bibleReferences = computed(() => { } }) +// Font size classes +const fontSizeClasses = computed(() => { + switch (fontSize.value) { + case 'small': + return 'text-sm' + case 'large': + return 'text-xl' + default: + return 'text-base' + } +}) + function formatDate(dateString: string) { const date = new Date(dateString) return date.toLocaleDateString('en-US', {