Skip to content
Menu

Navigation

Auto height tabs

Auto height tabs: A tab group whose content container smoothly resizes its height to fit each panel as you switch tabs, instead of jumping or leaving empty space.

Using Auto height tabs

Auto height tabs uses the card preview frame with a light/dark theme setting.

Customize the preview

These controls are passed to the demo. Defaults and limits describe the preview; consult the implementation for its full prop API.

ControlTypeDefaultPreview limits
accentColorcolor#38BDF8No additional limit in the metadata.
defaultTabselectsummaryOptions: summary, details, history
animationSpeednumber300From 150 to 600; step 50
Which frameworks are available for Auto height tabs?

Auto height tabs is available for React, Vue, Svelte, Astro, HTML. The live preview uses React; the source observations below apply to index.tsx. Check the selected port before relying on the same interactions.

What does Auto height tabs depend on?

The React metadata lists these npm dependencies beyond React: motion, clsx, tailwind-merge.

What accessibility details are visible in Auto height tabs?

The React source for Auto height tabs includes: native elements (button); attributes and handlers (aria-controls, aria-hidden, aria-label, aria-labelledby, aria-selected, onKeyDown, tabIndex); explicit roles (tab, tablist, tabpanel); key comparisons (ArrowLeft, ArrowRight). These are source observations. Verify accessible names, focus order and keyboard behavior in the composed page.

How does Auto height tabs handle reduced motion?

Auto height tabs reads the motion preference in its React source through useReducedMotion(). Preference-dependent expressions in index.tsx: duration: reduce ? 0 : speed / 1000; duration: reduce ? 0.001 : speed / 1000. Check the full implementation, shared styles and selected port with reduced motion enabled; these observations do not establish that every animation stops.

Connect your agent

Related open components