Free, open-source image cropping component for shadcn-ui
Built with React, TypeScript, Tailwind CSS, shadcn-ui, and react-image-crop
Features intuitive cropping with zoom and rotation controls
Integrates via shadcn CLI
MIT-licensed
Shadcn Image Cropper is a free, open-source React component by sujjeee, designed to extend shadcn-ui with a minimal, user-friendly image cropping interface. It’s ideal for developers building applications requiring image uploads with editing capabilities, such as user avatars, profile editors, or content management systems, particularly in Next.js or React projects.
Built with React, TypeScript, Tailwind CSS, shadcn-ui, and react-image-crop, it offers a clean UI with features like zooming, rotation, and fixed or dynamic aspect ratio cropping. The component integrates seamlessly via shadcn CLI, aligning with shadcn-ui’s accessible, customizable design, and addresses community demand for an image cropper.
Intuitive Cropping: Drag and resize a crop area with precise pixel output.
Zoom and Rotation: Adjust image scale and orientation for accurate cropping.
Aspect Ratio Control: Supports fixed or dynamic ratios for flexible use cases.
Accessible Design: Inherits shadcn-ui’s WAI-ARIA compliance for accessibility.
CLI Integration: Install via shadcn CLI for quick setup in shadcn-ui projects.
Responsive Interface: Tailwind CSS ensures adaptability across devices.
Form Integration: Compatible with react-hook-form for seamless form workflows.
shadcn-ui Compatibility: Matches shadcn-ui’s aesthetic and accessibility standards.
Free and Open-Source: MIT license allows unrestricted use and customization.
Minimal Design: Clean, focused UI enhances user experience for image cropping.
Community Support: 381 GitHub stars and active issues show engagement (January 2025).
Easy Setup: CLI simplifies integration into shadcn-ui projects.
React Dependency: Limited to React/shadcn-ui ecosystems.
Setup Requirements: Needs shadcn-ui, Tailwind CSS, and react-image-crop installed.
Client-Side Focus: Cropping is client-side; server-side processing requires extra setup.
Limited Features: Lacks advanced editing like filters or multi-image cropping.
Dependency on react-image-crop: Adds external dependency, increasing bundle size.
ImageCropper: Main component for rendering the cropping interface with zoom and rotation controls.
Cropper Controls: UI elements for adjusting crop settings like aspect ratio and scale.
Shadcn Image Cropper is completely free under the MIT license, with no premium tiers.
React: Core framework for the component.
shadcn-ui: Provides accessible, styled primitives.
Tailwind CSS: Utility-first styling for responsive design.
Next.js: Optimized for Next.js projects.
TypeScript: Ensures type safety.
react-image-crop: Powers the core cropping functionality.
react-hook-form & Zod: Supports type-safe form integration.
A minimal image cropping component for shadcn-ui, built with react-image-crop for avatar or content editing.
Yes, it’s fully free under the MIT license.
It’s designed for shadcn-ui; non-shadcn-ui use requires replacing dependencies.
Highly customizable via Tailwind CSS, react-image-crop props, and shadcn-ui structure.
Image cropper built with shadcn/ui and react-image-crop.
Submit your Shadcn product to AllShadcn, get featured, and drive genuine traffic while showcasing your work to the world. Turn your creativity into revenue and begin selling today! 🚀