Landing sections
JS behaviour
Testimonials
A big-quote carousel with avatars, companies and names, over a grid of small star-rated quotes; navigate by button, by dots or with the arrow keys — all on a warm cream-and-amber palette that builds trust.
Real scenarios
The component as it is used in a product — not a specimen grid.
Teams don’t leave — they write about it
From Oslo to Singapore, the story repeats: less busywork, clearer ownership, faster mornings.
The week we adopted Beacon we retired three tools. The billing page nobody dared to touch finally has an owner.
The audit log paid for itself in one incident — we traced a broken deploy to a single env var in four minutes.
Onboarding new engineers dropped from two weeks to three days. They just read the runbooks.
Tip: the ← → keys work too.
Support answers in minutes, not days.
The changelog writes itself now.
A dashboard the whole team actually opens.
Zero training day. The team just used it.
Important props
| Prop | Type | Default | What it does |
|---|---|---|---|
| index | number | '0' | The active slide; slides stack in one grid area and swap with a soft fade-and-slide, so the height never jumps. |
| controls | 'buttons · dots · keys' | 'all three' | Prev/next buttons, clickable dots and the keyboard arrows — the carousel moves all three ways. |
| rating | 0–5 | '5' | The small cards carry stars; filled SVG stars spell the score out. |
| --sectm-accent | color | '#B45309' | The section’s warm amber; stars and the big quote take it, brightening to gold in dark mode. |
Snippet
<section class="sectm" x-data="{ i: 0 }"
x-on:keydown.window.arrow-right.prevent="i = (i + 1) % 3"
x-on:keydown.window.arrow-left.prevent="i = (i - 1 + 3) % 3">
<!-- slides stack in one grid area, so the height never jumps -->
<div class="sectm-stage">
<blockquote class="sectm-quote" x-show="i === 0" x-transition:enter.duration.400ms>
<p>“The week we adopted Beacon we retired three tools.”</p>
<footer><span class="sectm-avatar">AL</span><b>Amelie Laurent</b><small>Northwind · Oslo</small></footer>
</blockquote>
</div>
<div class="sectm-nav">
<button type="button" x-on:click="i = (i - 1 + 3) % 3" aria-label="Previous">←</button>
<button type="button" class="sectm-dot" :class="i === 0 && 'sectm-on'" x-on:click="i = 0" aria-label="Quote 1"></button>
<button type="button" x-on:click="i = (i + 1) % 3" aria-label="Next">→</button>
</div>
</section>
<style>
.sectm { padding: 3rem 1.5rem; background: #FBF7F0; color: #292524; font-family: 'Inter', sans-serif; }
.sectm-stage { display: grid; } .sectm-quote { grid-area: 1 / 1; margin: 0; }
.sectm-quote p { margin: 0 0 1.25rem; font-size: 1.375rem; font-weight: 650; line-height: 1.65; }
.sectm-avatar { display: inline-grid; place-items: center; inline-size: 2.75rem; aspect-ratio: 1;
border-radius: 999px; background: #B45309; color: #fff; font-weight: 700; }
.sectm-dot { inline-size: .5rem; aspect-ratio: 1; border-radius: 999px; border: none;
background: #E7D8C3; cursor: pointer; }
.sectm-dot.sectm-on { background: #B45309; inline-size: 1.25rem; }
</style>
// app/Pages/Love.jsx — Inertia (React) page; renders the React
// snippet below unchanged, with Inertia's Link wired into the provider.
import { Link } from '@inertiajs/react';
import { NabuXUIProvider } from '@nabuxai/ui-react';
import Testimonials from '@/components/Testimonials';
export default function Love() {
return (
<NabuXUIProvider locale="en" linkComponent={Link}>
<main className="nx-page">
<Testimonials />
</main>
</NabuXUIProvider>
);
}
// Testimonials.jsx — big-quote carousel + star grid, keys included
import { useEffect, useState } from 'react';
import '@nabuxai/ui-core/css';
const QUOTES = [
{ id: 'northwind', text: 'The week we adopted Beacon we retired three tools. The billing page nobody dared to touch finally has an owner.',
name: 'Amelie Laurent', role: 'VP Engineering · Northwind, Oslo', initials: 'AL' },
{ id: 'helios', text: 'The audit log paid for itself in one incident — we traced a broken deploy to a single env var in four minutes.',
name: 'Diego Ferreira', role: 'SRE Lead · Helios Labs, Lisbon', initials: 'DF' },
{ id: 'quantia', text: 'Onboarding new engineers dropped from two weeks to three days. They just read the runbooks.',
name: 'Mei Tanaka', role: 'CTO · Quantia, Singapore', initials: 'MT' },
];
const SHORTS = [
{ id: 's1', text: 'Support answers in minutes, not days.', name: 'Priya Sharma', co: 'Fabrik, Toronto', stars: 5 },
{ id: 's2', text: 'The changelog writes itself now.', name: 'Jonas Weber', co: 'Kanso, Berlin', stars: 5 },
{ id: 's3', text: 'A dashboard the whole team actually opens.', name: 'Sofia Rossi', co: 'Vantage, Milan', stars: 4 },
];
export default function Testimonials() {
const [i, setI] = useState(0);
const step = (d) => setI((v) => (v + d + QUOTES.length) % QUOTES.length);
// Arrow keys drive the carousel from anywhere on the page.
useEffect(() => {
const onKey = (e) => {
if (e.key === 'ArrowRight') step(1);
if (e.key === 'ArrowLeft') step(-1);
};
window.addEventListener('keydown', onKey);
return () => window.removeEventListener('keydown', onKey);
}, []);
return (
<>
<style>{`
.sct { display: grid; gap: 1.5rem; padding: 3rem 1.5rem; background: #FBF7F0; color: #292524;
font: 400 .9375rem/1.5 'Inter', sans-serif; }
.sct-stage { display: grid; max-inline-size: 44rem; margin-inline: auto; }
.sct-quote { grid-area: 1 / 1; margin: 0; display: grid; gap: 1.25rem; justify-items: center; text-align: center; }
.sct-quote p { margin: 0; font: 650 clamp(1.15rem, 2.6vw, 1.6rem)/1.6 'Inter', sans-serif; letter-spacing: -.01em; }
.sct-quote footer { display: inline-flex; align-items: center; gap: .75rem; }
.sct-avatar { display: inline-grid; place-items: center; inline-size: 2.75rem; aspect-ratio: 1;
border-radius: 999px; background: #B45309; color: #fff; font-weight: 700; }
.sct-on { opacity: 1; } .sct-off { opacity: 0; pointer-events: none; }
.sct-nav { display: flex; align-items: center; justify-content: center; gap: .75rem; }
.sct-nav button { border: none; cursor: pointer; background: transparent; }
.sct-arrow { inline-size: 2.25rem; aspect-ratio: 1; border-radius: 999px; background: #F3E8D7 !important; }
.sct-dot { inline-size: .5rem; aspect-ratio: 1; border-radius: 999px; background: #E7D8C3 !important; }
.sct-dot[data-on='true'] { background: #B45309 !important; inline-size: 1.25rem; }
.sct-shorts { display: grid; gap: 1rem; grid-template-columns: repeat(3, 1fr); max-inline-size: 62rem; margin-inline: auto; }
.sct-short { padding: 1.25rem; border: 1px solid #EADFCB; border-radius: 1.1rem; background: #FFFCF6; }
.sct-stars { color: #F59E0B; letter-spacing: .15em; }
@media (max-width: 640px) { .sct-shorts { grid-template-columns: 1fr; } }
`}</style>
<section className="sct">
<div className="sct-stage">
{QUOTES.map((q, n) => (
<blockquote className={`sct-quote ${n === i ? 'sct-on' : 'sct-off'}`} key={q.id} aria-hidden={n !== i}>
<p>“{q.text}”</p>
<footer>
<span className="sct-avatar" aria-hidden="true">{q.initials}</span>
<span><b>{q.name}</b><br /><small>{q.role}</small></span>
</footer>
</blockquote>
))}
</div>
<div className="sct-nav">
<button type="button" className="sct-arrow" aria-label="Previous quote" onClick={() => step(-1)}>←</button>
{QUOTES.map((q, n) => (
<button type="button" className="sct-dot" data-on={n === i} key={q.id}
aria-label={`Quote ${n + 1}`} onClick={() => setI(n)} />
))}
<button type="button" className="sct-arrow" aria-label="Next quote" onClick={() => step(1)}>→</button>
</div>
<div className="sct-shorts">
{SHORTS.map((s) => (
<figure className="sct-short" key={s.id}>
<div className="sct-stars" aria-label={`${s.stars} out of 5 stars`}>
{'★'.repeat(s.stars)}{'☆'.repeat(5 - s.stars)}
</div>
<blockquote>{s.text}</blockquote>
<figcaption><b>{s.name}</b> · {s.co}</figcaption>
</figure>
))}
</div>
</section>
</>
);
}
<!-- Testimonials.vue — big-quote carousel + star grid, keys included -->
<script setup lang="ts">
import { onBeforeUnmount, onMounted, ref } from 'vue';
import '@nabuxai/ui-core/css';
const quotes = [
{ id: 'northwind', text: 'The week we adopted Beacon we retired three tools. The billing page nobody dared to touch finally has an owner.',
name: 'Amelie Laurent', role: 'VP Engineering · Northwind, Oslo', initials: 'AL' },
{ id: 'helios', text: 'The audit log paid for itself in one incident — we traced a broken deploy to a single env var in four minutes.',
name: 'Diego Ferreira', role: 'SRE Lead · Helios Labs, Lisbon', initials: 'DF' },
{ id: 'quantia', text: 'Onboarding new engineers dropped from two weeks to three days. They just read the runbooks.',
name: 'Mei Tanaka', role: 'CTO · Quantia, Singapore', initials: 'MT' },
];
const shorts = [
{ id: 's1', text: 'Support answers in minutes, not days.', name: 'Priya Sharma', co: 'Fabrik, Toronto', stars: 5 },
{ id: 's2', text: 'The changelog writes itself now.', name: 'Jonas Weber', co: 'Kanso, Berlin', stars: 5 },
{ id: 's3', text: 'A dashboard the whole team actually opens.', name: 'Sofia Rossi', co: 'Vantage, Milan', stars: 4 },
];
const i = ref(0);
const step = (d: number) => { i.value = (i.value + d + quotes.length) % quotes.length; };
const onKey = (e: KeyboardEvent) => {
if (e.key === 'ArrowRight') step(1);
if (e.key === 'ArrowLeft') step(-1);
};
onMounted(() => window.addEventListener('keydown', onKey));
onBeforeUnmount(() => window.removeEventListener('keydown', onKey));
</script>
<template>
<section class="sct">
<div class="sct-stage">
<!-- slides stack in one grid area, so the height never jumps -->
<blockquote v-for="(q, n) in quotes" :key="q.id" class="sct-quote" :class="n === i ? 'sct-on' : 'sct-off'" :aria-hidden="n !== i">
<p>“{{ q.text }}”</p>
<footer>
<span class="sct-avatar" aria-hidden="true">{{ q.initials }}</span>
<span><b>{{ q.name }}</b><br /><small>{{ q.role }}</small></span>
</footer>
</blockquote>
</div>
<div class="sct-nav">
<button type="button" class="sct-arrow" aria-label="Previous quote" @click="step(-1)">←</button>
<button v-for="(q, n) in quotes" :key="q.id" type="button" class="sct-dot" :data-on="n === i"
:aria-label="`Quote ${n + 1}`" @click="i = n" />
<button type="button" class="sct-arrow" aria-label="Next quote" @click="step(1)">→</button>
</div>
<div class="sct-shorts">
<figure v-for="s in shorts" :key="s.id" class="sct-short">
<div class="sct-stars" :aria-label="`${s.stars} out of 5 stars`">★★★★★</div>
<blockquote>{{ s.text }}</blockquote>
<figcaption><b>{{ s.name }}</b> · {{ s.co }}</figcaption>
</figure>
</div>
</section>
</template>
<style scoped>
.sct { display: grid; gap: 1.5rem; padding: 3rem 1.5rem; background: #FBF7F0; color: #292524;
font: 400 .9375rem/1.5 'Inter', sans-serif; }
.sct-stage { display: grid; max-inline-size: 44rem; margin-inline: auto; }
.sct-quote { grid-area: 1 / 1; margin: 0; display: grid; gap: 1.25rem; justify-items: center; text-align: center; }
.sct-quote p { margin: 0; font: 650 clamp(1.15rem, 2.6vw, 1.6rem)/1.6 'Inter', sans-serif; letter-spacing: -.01em; }
.sct-quote footer { display: inline-flex; align-items: center; gap: .75rem; }
.sct-avatar { display: inline-grid; place-items: center; inline-size: 2.75rem; aspect-ratio: 1;
border-radius: 999px; background: #B45309; color: #fff; font-weight: 700; }
.sct-on { opacity: 1; } .sct-off { opacity: 0; pointer-events: none; }
.sct-nav { display: flex; align-items: center; justify-content: center; gap: .75rem; }
.sct-nav button { border: none; cursor: pointer; background: transparent; }
.sct-arrow { inline-size: 2.25rem; aspect-ratio: 1; border-radius: 999px; background: #F3E8D7; }
.sct-dot { inline-size: .5rem; aspect-ratio: 1; border-radius: 999px; background: #E7D8C3; }
.sct-dot[data-on='true'] { background: #B45309; inline-size: 1.25rem; }
.sct-shorts { display: grid; gap: 1rem; grid-template-columns: repeat(3, 1fr); max-inline-size: 62rem; margin-inline: auto; }
.sct-short { margin: 0; padding: 1.25rem; border: 1px solid #EADFCB; border-radius: 1.1rem; background: #FFFCF6; }
.sct-short blockquote { margin: .5rem 0; }
.sct-stars { color: #F59E0B; letter-spacing: .15em; }
@media (max-width: 640px) { .sct-shorts { grid-template-columns: 1fr; } }
</style>
<!-- Testimonials.svelte — big-quote carousel + star grid, keys included -->
<script lang="ts">
import { onMount } from 'svelte';
import '@nabuxai/ui-core/css';
const quotes = [
{ id: 'northwind', text: 'The week we adopted Beacon we retired three tools. The billing page nobody dared to touch finally has an owner.',
name: 'Amelie Laurent', role: 'VP Engineering · Northwind, Oslo', initials: 'AL' },
{ id: 'helios', text: 'The audit log paid for itself in one incident — we traced a broken deploy to a single env var in four minutes.',
name: 'Diego Ferreira', role: 'SRE Lead · Helios Labs, Lisbon', initials: 'DF' },
{ id: 'quantia', text: 'Onboarding new engineers dropped from two weeks to three days. They just read the runbooks.',
name: 'Mei Tanaka', role: 'CTO · Quantia, Singapore', initials: 'MT' },
];
const shorts = [
{ id: 's1', text: 'Support answers in minutes, not days.', name: 'Priya Sharma', co: 'Fabrik, Toronto', stars: 5 },
{ id: 's2', text: 'The changelog writes itself now.', name: 'Jonas Weber', co: 'Kanso, Berlin', stars: 5 },
{ id: 's3', text: 'A dashboard the whole team actually opens.', name: 'Sofia Rossi', co: 'Vantage, Milan', stars: 4 },
];
let i = $state(0);
const step = (d: number) => { i = (i + d + quotes.length) % quotes.length; };
// Arrow keys drive the carousel from anywhere on the page.
onMount(() => {
const onKey = (e: KeyboardEvent) => {
if (e.key === 'ArrowRight') step(1);
if (e.key === 'ArrowLeft') step(-1);
};
window.addEventListener('keydown', onKey);
return () => window.removeEventListener('keydown', onKey);
});
</script>
<section class="sct">
<div class="sct-stage">
<!-- slides stack in one grid area, so the height never jumps -->
{#each quotes as q, n (q.id)}
<blockquote class="sct-quote" class:on={n === i} class:off={n !== i} aria-hidden={n !== i}>
<p>“{q.text}”</p>
<footer>
<span class="sct-avatar" aria-hidden="true">{q.initials}</span>
<span><b>{q.name}</b><br /><small>{q.role}</small></span>
</footer>
</blockquote>
{/each}
</div>
<div class="sct-nav">
<button type="button" class="sct-arrow" aria-label="Previous quote" onclick={() => step(-1)}>←</button>
{#each quotes as q, n (q.id)}
<button type="button" class="sct-dot" class:on={n === i} aria-label="Quote {n + 1}" onclick={() => (i = n)} />
{/each}
<button type="button" class="sct-arrow" aria-label="Next quote" onclick={() => step(1)}>→</button>
</div>
<div class="sct-shorts">
{#each shorts as s (s.id)}
<figure class="sct-short">
<div class="sct-stars" aria-label="{s.stars} out of 5 stars">★★★★★</div>
<blockquote>{s.text}</blockquote>
<figcaption><b>{s.name}</b> · {s.co}</figcaption>
</figure>
{/each}
</div>
</section>
<style>
.sct { display: grid; gap: 1.5rem; padding: 3rem 1.5rem; background: #FBF7F0; color: #292524;
font: 400 .9375rem/1.5 'Inter', sans-serif; }
.sct-stage { display: grid; max-inline-size: 44rem; margin-inline: auto; }
.sct-quote { grid-area: 1 / 1; margin: 0; display: grid; gap: 1.25rem; justify-items: center; text-align: center; }
.sct-quote p { margin: 0; font: 650 clamp(1.15rem, 2.6vw, 1.6rem)/1.6 'Inter', sans-serif; letter-spacing: -.01em; }
.sct-quote footer { display: inline-flex; align-items: center; gap: .75rem; }
.sct-avatar { display: inline-grid; place-items: center; inline-size: 2.75rem; aspect-ratio: 1;
border-radius: 999px; background: #B45309; color: #fff; font-weight: 700; }
.sct-quote.on { opacity: 1; } .sct-quote.off { opacity: 0; pointer-events: none; }
.sct-nav { display: flex; align-items: center; justify-content: center; gap: .75rem; }
.sct-nav button { border: none; cursor: pointer; background: transparent; }
.sct-arrow { inline-size: 2.25rem; aspect-ratio: 1; border-radius: 999px; background: #F3E8D7; }
.sct-dot { inline-size: .5rem; aspect-ratio: 1; border-radius: 999px; background: #E7D8C3; }
.sct-dot.on { background: #B45309; inline-size: 1.25rem; }
.sct-shorts { display: grid; gap: 1rem; grid-template-columns: repeat(3, 1fr); max-inline-size: 62rem; margin-inline: auto; }
.sct-short { margin: 0; padding: 1.25rem; border: 1px solid #EADFCB; border-radius: 1.1rem; background: #FFFCF6; }
.sct-short blockquote { margin: .5rem 0; }
.sct-stars { color: #F59E0B; letter-spacing: .15em; }
@media (max-width: 640px) { .sct-shorts { grid-template-columns: 1fr; } }
</style>