{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "aspect-ratio",
  "title": "Aspect Ratio",
  "author": "@fma-ui/ui",
  "description": "Constrains content (typically an image or video) to a fixed width/height ratio, so it scales without distortion or layout shift.",
  "dependencies": [
    "cn@^0.4.0"
  ],
  "files": [
    {
      "path": "src/core/aspect-ratio/aspect-ratio.tsx",
      "content": "import { cn } from \"cn\";\n\nfunction AspectRatio({\n  ratio,\n  className,\n  ...props\n}: React.ComponentProps<\"div\"> & { ratio: number }) {\n  return (\n    <div\n      data-slot=\"aspect-ratio\"\n      style={\n        {\n          \"--ratio\": ratio,\n        } as React.CSSProperties\n      }\n      className={cn(\"relative aspect-(--ratio)\", className)}\n      {...props}\n    />\n  );\n}\n\nexport { AspectRatio };\n",
      "type": "registry:component",
      "target": "components/fma-ui/aspect-ratio.tsx"
    }
  ],
  "meta": {
    "status": "stable",
    "source": "shadcn",
    "tags": [
      "media",
      "layout"
    ]
  },
  "categories": [
    "media"
  ],
  "type": "registry:ui"
}