motionsnack

Animated React sections that already feel finished.

Copy them into Next.js or add them with one command. Plain React and Tailwind, light and dark.

New sections, once a month

One short email when something new lands. No spam.

Library

  • Sections
  • Blocks
  • Components
  • Application UI
  • Templates

Popular

  • Hero
  • Gallery
  • Testimonials
  • Stats
  • Logos
  • FAQ

Resources

  • Installation
  • All components
  • All blocks
  • All sections
  • All application UI
  • Design system
  • Changelog
  • Pricing

Company

  • About
  • Contact
  • Terms
  • Privacy

Install

npx motionsnack add <name>Step-by-step guidehello@motionsnack.dev
Kuba Šťastný@kubastastnydev

© 2026 motionsnack. All rights reserved.

TermsPrivacy

motionsnack

motionsnack
DocsSectionsTemplatesWhat's newPricing
Get lifetime access
  1. Home
  2. Docs
  3. Components
  4. Cropper
  5. Image Cropper
ComponentsBlocksSectionsApplication UI
ComponentsBlocksSectionsApplication UI

Accordion

  • Spring Accordion

Alert

  • Glow Alert

Audio

  • Podcast PlayerNew
  • Voice NoteNew
  • Voice RecorderNew

Avatar

  • Avatar Stack

Badge

  • Pulse Badge

Breadcrumb

  • Slide Breadcrumb

Button

  • Chip ButtonNew
  • Glow Border Button
  • Glow ButtonNew
  • Plain ButtonNew

Calendar

  • Month Calendar

Checkbox

  • Checkbox CardsNew
  • Checkbox GroupNew
  • Chip CheckboxNew

Cropper

  • Image Cropper

Dialog

  • Spring Dialog

Dropdown

  • Command MenuNew
  • Stagger Dropdown
  • Switcher DropdownNew

File Upload

  • Drop Zone Upload

Input

  • Addon InputNew
  • Button InputNew
  • Copy InputNew
  • Date InputNew
  • Floating Label Input
  • Joined InputsNew
  • Notched Label InputNew
  • Number StepperNew
  • OTP InputNew
  • Password InputNew
  • Phone InputNew
  • Range InputNew
  • Search InputNew
  • Tag InputNew
  • Text FieldNew

Loader

  • Curtain LoaderNew
  • Greeting LoaderNew
  • Line LoaderNew
  • Meter LoaderNew
  • Split LoaderNew

Navigation Menu

  • Mobile Tab BarNew

Notification

  • Notification BellNew
  • Toast Stack

Pagination

  • Sliding Pagination

Popover

  • Spring Popover

Radio

  • Card Radio Group
  • Payment MethodNew
  • Radio GroupNew
  • Rating RadioNew

Select

  • ComboboxNew
  • Glide Select
  • Multi SelectNew
  • Rich SelectNew
  • Select FieldNew
  • Tree SelectNew

Sidebar

  • Icon RailNew

Slider

  • Glow Slider

Stepper

  • Progress Stepper

Switch

  • Billing SwitchNew
  • Switch RowNew
  • Toggle SwitchNew

Table

  • Sortable Table

Tabs

  • Sliding Tabs

Textarea

  • Auto Grow Textarea

Toggle

  • Icon ToggleNew
  • Theme ToggleNew
  • Toggle GroupNew

Tooltip

  • Follow Tooltip

Cropper

Image Cropper

An image in a fixed frame that you drag to reposition and zoom with a slider or the wheel.

npx motionsnack add image-cropper

Customize

%
%
x
x
x
<ImageCropper />

Props

25 properties

PropertyTypeDefaultDescription
value{ x: number; y: number; zoom: number }-Position and zoom (controlled). x and y run 0-100, 50 is centred.
defaultValue{ x: number; y: number; zoom: number }{ x: 50, y: 50, zoom: 1.2 }Position and zoom at the start (uncontrolled).
onChange(value: { x, y, zoom }) => void-Called when a drag ends, on a key press and on zoom changes.
labels{ area?, instructions?, zoomOut?, zoomIn?, zoom?, reset?, error? }EnglishUI strings.
localestring'en-US'BCP 47 locale of the zoom percentage.
gridboolean-Deprecated alias of showGrid.
sliderboolean-Deprecated alias of showSlider.
widthnumber-Deprecated, ignored: the root is max-w-sm.
radiusnumber-Deprecated, ignored: the frame is radius 12.
accentstring-Deprecated, ignored: the zoom slider is monochrome.
elasticitynumber-Deprecated, ignored.
durationnumber-Deprecated, ignored: the standard spring.
bouncenumber-Deprecated, ignored.
classNamestring''Extra classes on the root.
srcstring'/sections/motion-01.jpg'Image to crop. Empty renders nothing.
altstring'Photo being cropped'Alternative text that describes the photo.
shape'circle' | 'rectangle''circle'Shape of the crop: the whole frame, or a circle with the rest dimmed.
aspectRationumber1Width divided by height of the frame.
minZoomnumber1Smallest zoom. 1 is the image just covering the frame.
maxZoomnumber3Largest zoom.
showGridbooleantrueRule-of-thirds guides while dragging.
showSliderbooleantrueZoom slider with zoom-out and zoom-in buttons under the frame.
showResetbooleantrueReset button after the zoom row.
wheelZoombooleantrueZoom with the mouse wheel or a trackpad pinch over the frame.
disabledbooleanfalseDims the cropper and blocks every interaction.

About Image Cropper

An image cropper for avatars and cover photos: the picture sits in a frame with a fixed aspect ratio and the user drags it into place. Dragging past an edge is allowed with resistance, and on release the image eases back inside the bounds with a spring. A rule-of-thirds grid fades in while dragging and out again afterwards. Zoom comes from the slider, the plus and minus buttons, the mouse wheel or a trackpad pinch, always around the centre of the frame. The mask can be a rectangle or a circle with the surroundings dimmed, and onChange reports the position as x and y from 0 to 100 together with the zoom, so the result is independent of the rendered size.

What's included

  • Drag to reposition with elastic edges
  • Spring back inside the bounds on release
  • Zoom by slider, buttons, wheel or pinch
  • Rule-of-thirds grid while dragging
  • Circle or rectangle mask, any aspect ratio
  • Controlled or uncontrolled, onChange with x, y and zoom
  • Keyboard arrows to move, plus and minus to zoom
Type
Animated React cropper component
Library
Components · Cropper
Stack
Next.js, React, Tailwind CSS
Added
2026-09-20
Install
npx motionsnack add image-cropper