Add testimonials section and Q&A submit CTA; v1.0.8
- Testimonials: new Testimonial type, CMS field, admin UI under About, and TestimonialsSection rendered on homepage and About page (hidden when empty) - Q&A: "Submit a Question →" CTA at bottom of Q&A page linking to /contact Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+28
-1
@@ -6,7 +6,7 @@ import QASection from './components/QASection'
|
||||
import ContactForm from './components/ContactForm'
|
||||
import { ColossiansStudyIndexPage, ColossiansStudyNotesPage, ColossiansStudySectionPage, StudyLandingPage, StudySignupPage, StudyAccountPage, StudyCommunityPage, StudyQuizPage } from './colossiansStudy'
|
||||
import { SpotifyIcon } from './icons'
|
||||
import type { SiteContent, StudyProgram } from './content'
|
||||
import type { SiteContent, StudyProgram, Testimonial } from './content'
|
||||
import { DEFAULTS } from './content'
|
||||
import { usePageMeta } from './hooks/usePageMeta'
|
||||
import { useGlobalSearch } from './hooks/useGlobalSearch'
|
||||
@@ -1078,6 +1078,30 @@ function HomepageQACallout() {
|
||||
)
|
||||
}
|
||||
|
||||
function TestimonialsSection({ testimonials }: { testimonials: Testimonial[] }) {
|
||||
if (!testimonials || testimonials.length === 0) return null
|
||||
return (
|
||||
<section className="section-testimonials" aria-label="Listener testimonials">
|
||||
<div className="section-inner">
|
||||
<h2 className="section-heading">
|
||||
<span className="ornament">✦</span> What Listeners Are Saying <span className="ornament">✦</span>
|
||||
</h2>
|
||||
<div className="testimonials-grid">
|
||||
{testimonials.map(t => (
|
||||
<blockquote key={t.id} className="testimonial-card">
|
||||
<p className="testimonial-quote">"{t.quote}"</p>
|
||||
<footer className="testimonial-footer">
|
||||
<span className="testimonial-name">— {t.name}</span>
|
||||
{t.source && <span className="testimonial-source">{t.source}</span>}
|
||||
</footer>
|
||||
</blockquote>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
)
|
||||
}
|
||||
|
||||
function LandingPage({ content }: { content: SiteContent }) {
|
||||
const featuredStudy = getHomepageFeaturedStudy(content)
|
||||
|
||||
@@ -1232,6 +1256,8 @@ function LandingPage({ content }: { content: SiteContent }) {
|
||||
|
||||
<HomepageQACallout />
|
||||
|
||||
<TestimonialsSection testimonials={content.testimonials ?? []} />
|
||||
|
||||
<section className="section-share" aria-label="Share the show">
|
||||
<div className="section-inner section-share-inner">
|
||||
<div className="share-text">
|
||||
@@ -1622,6 +1648,7 @@ function AboutPage({ content }: { content: SiteContent }) {
|
||||
<SiteHeader content={content} />
|
||||
<SiteSearchBar content={content} />
|
||||
<AboutSection content={content} />
|
||||
<TestimonialsSection testimonials={content.testimonials ?? []} />
|
||||
<CustomBlocksSection content={content} page="about" />
|
||||
<SiteFooter content={content} />
|
||||
<AnalyticsConsentBanner content={content} />
|
||||
|
||||
Reference in New Issue
Block a user