feat(testimonials): filter quotes by locale with English fallback#12
Merged
Conversation
Testimonials now render in the speaker's own language: show the quotes said in the active locale, falling back to the English set when none match (so a German visitor sees the English quotes, not a stray Ukrainian one). Case-page inline quote respects locale too. No behaviour change today (the array is still empty); this unblocks collecting real UA/PT/EN client quotes without them cross-showing on every locale. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Testimonials now render in the speaker's own language:
TestimonialListshows the quotes whoselocalematches the active locale, and falls back to the English set when none match.findTestimonialFor(slug, locale)(case-page inline quote) prefers the active-locale quote, then English, then any.Why
We're about to collect real client testimonials in mixed languages — Nazar (GreenOlivia) in Ukrainian, Eduardo Pêgo in Portuguese, RSR/Inside-Out in English. Without this filter every quote showed on every locale (a Ukrainian quote would appear on the German site). Quotes stay in the speaker's authentic voice; each locale sees a coherent set.
Notes
testimonialsarray is still empty and the block hides itself.useLocale()inside the two server components; no changes toaboutorwork/[slug]pages.pnpm typecheckclean.🤖 Generated with Claude Code