A
AstraWind
v0.2.0
System
Layout

aspect-ratio

Utilities for controlling the aspect ratio of an element.

Quick reference

2 of 3 classes apply on React Native
Class
Styles
React Native
aspect-auto
aspect-ratio: auto;
No native equivalent
aspect-square
aspect-ratio: 1 / 1;
aspectRatio: 1
aspect-video
aspect-ratio: var(--aspect-video);
aspectRatio: 1.778
The React Native column is what AstraWind resolves each class to, computed live on this page with the current color scheme. Classes with no native equivalent are accepted without effect, and AstraWind warns about them in development. See Compatibility.