<div class="max-w-[450px] w-full">
<ui-aspect-ratio ratio="16/9">
<div class="bg-muted flex items-center justify-center rounded-md h-full w-full">
<span class="text-muted-foreground text-sm">16:9 Aspect Ratio</span>
</div>
</ui-aspect-ratio>
</div>
<ui-aspect-ratio>
<ui-aspect-ratio>| Prop | Type | Default | Description |
|---|---|---|---|
ratio | number | 1 | The desired aspect ratio (e.g. 16/9). |
All components also accept standard HTML attributes (class, id, style, data-*, aria-*, etc.) which are passed through to the underlying element.