Stepped Accordion
Displays content sequentially, reducing overwhelm when there's too much to show at once.
@volvo-cars/css v3.3.1@volvo-cars/react-accordion v2.4.0
Stepped Accordion With Content
Section titled “Stepped Accordion With Content”Immersive listening
This advanced sound system employs 21 speakers and two amplifiers to deliver high-fidelity audio in 3D throughout the cabin.
Integrated speakers
With the new soundbar concept, a 1040W amplifier and nine high-performance speakers, this state-of-the-art system delivers immersive surround sound for everyone.
Customisable audio
Every aspect of the audio system is tuned to the interior. Select Dynamic, Soft or Voice mode to deepen your listening experience.
Show code
import { SteppedAccordion, SteppedAccordionDetails, SteppedAccordionSummary,} from '@volvo-cars/react-accordion';import { useState } from 'react';
export function SteppedAccordionWithContent() { const [currentStep, setCurrentStep] = useState(0);
const steps = [ { id: 0, title: 'Immersive listening', content: 'This advanced sound system employs 21 speakers and two amplifiers to deliver high-fidelity audio in 3D throughout the cabin.', }, { id: 1, title: 'Integrated speakers', content: 'With the new soundbar concept, a 1040W amplifier and nine high-performance speakers, this state-of-the-art system delivers immersive surround sound for everyone.', }, { id: 2, title: 'Customisable audio', content: 'Every aspect of the audio system is tuned to the interior. Select Dynamic, Soft or Voice mode to deepen your listening experience.', }, ];
return ( <SteppedAccordion> {steps.map(({ id, title, content }) => ( <SteppedAccordionDetails key={id} open={currentStep === id} onToggle={() => setCurrentStep(id)} > <SteppedAccordionSummary>{title}</SteppedAccordionSummary> <div className="pb-8 px-24 text-secondary">{content}</div> </SteppedAccordionDetails> ))} </SteppedAccordion> );}