Image cropper (UI SDK): Rotate and flip
ImageCropperRotate turns the image a quarter clockwise and ImageCropperFlip mirrors it. Without children they’re icon buttons with English labels.
This adds the example as components/examples/ui-sdk-image-cropper/rotate-flip.tsx, together with the Image cropper component and the HextaUI theme tokens it needs.
pnpm dlx shadcn@latest add https://hextaui.com/r/ui-sdk-image-cropper-rotate-flip.jsonTo add only the component, follow the Image cropper installation.
Props in this example
The Image cropper props this example sets, from the API reference.
| Prop | Type | Default |
|---|---|---|
src | string | – |
aspectRatio | number | – |
| Prop | Type | Default |
|---|---|---|
altRequired. | string | – |
| Prop | Type | Default |
|---|---|---|
direction | "horizontal" | "vertical" | "horizontal" |
Every prop is in the Image cropper API reference.
See them all, with keyboard support and accessibility notes, on the Image cropper page.