bits

Aspect Ratio

Displays content with a specified aspect ratio, ensuring consistent and visually balanced presentation.

Structure

	<script lang="ts">
  import { AspectRatio } from "bits-ui";
</script>
 
<AspectRatio.Root />
	<script lang="ts">
  import { AspectRatio } from "bits-ui";
</script>
 
<AspectRatio.Root />

Component API

Root

The aspect ratio component.

Prop Default Type/Description
ratio 1 number

The desired aspect ratio.

🚧 UNDER CONSTRUCTION 🚧