@@ -4,17 +4,18 @@ import { cn } from "@/lib/utils";
44import { fields , radiusVariants , selectFrom , type Radius } from "@/lib/puck/tokens" ;
55import { ImageIcon } from "lucide-react" ;
66
7- const aspectRatioOptions = [ "auto" , "square" , "video" , "wide" ] as const ;
7+ const aspectRatioOptions = [ "auto" , "square" , "photo" , " video", "wide" ] as const ;
88type AspectRatio = ( typeof aspectRatioOptions ) [ number ] ;
99
1010const objectFitOptions = [ "cover" , "contain" , "fill" ] as const ;
1111type ObjectFit = ( typeof objectFitOptions ) [ number ] ;
1212
13- const mediaWrapperVariants = cva ( "relative w-full overflow-hidden" , {
13+ const mediaWrapperVariants = cva ( "relative h-full w-full overflow-hidden" , {
1414 variants : {
1515 aspectRatio : {
1616 auto : "" ,
1717 square : "aspect-square" ,
18+ photo : "aspect-[4/3]" ,
1819 video : "aspect-video" ,
1920 wide : "aspect-[21/9]" ,
2021 } ,
@@ -59,6 +60,7 @@ export const Media: ComponentConfig<MediaProps> = {
5960 options : [
6061 { label : "Auto" , value : "auto" } ,
6162 { label : "Square (1:1)" , value : "square" } ,
63+ { label : "Photo (4:3)" , value : "photo" } ,
6264 { label : "Video (16:9)" , value : "video" } ,
6365 { label : "Wide (21:9)" , value : "wide" } ,
6466 ] ,
0 commit comments