Primitives
Aspect Ratio
Locks children to a fixed aspect ratio (e.g. 16/9 media embeds).
Motionnone — layout primitive
Install
Install Kineto and follow the theme setup once in your app.
bash
npm install kinetotsx
import { AspectRatio } from "kineto/aspect-ratio";Preview
tsx
"use client";
import * as AspectRatioPrimitive from "@radix-ui/react-aspect-ratio";
const AspectRatio = AspectRatioPrimitive.Root;
export { AspectRatio };src/components/ui/aspect-ratio.tsx
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| ratio | number | 1 | Width ÷ height (e.g. 16/9). |