Aspect Ratio

Keeps content at a fixed width to height ratio.

components/ui/aspect-ratio.tsx
16 : 9

Installation

npx betterone-ds add aspect-ratio

Props

PropTypeDefault
rationumberrequired

Accessibility

  • Use for images and video so the layout does not jump while loading.