Closed dark-cms closed 9 years ago
var $image = $('#myImage').cropper(), // Initialize
cropper = $image.data('cropper'), // Get the instance
cropBox = cropper.cropBox; // Get the crop box object
...
cropBox.minWidth = 160; // Set a new minimum width
cropBox.minWidth = 90; // Set a new minimum height
...
I use the Cropper for a Mediaeditor.
Based on some Extensions it should be possible to "pre"-resize the Image (Points of interest and so on), but i am missing the feature to set minCropBoxWidth and Height after loading another ratio.
As Example: Image-Setup 1 scales Images to 800x600px, so the cropbox should not be lower than this values. Image-Setup 2 scales Images to 250x400px, so the cropbox should not be lower than this values.
This works fine with radio buttons
but is it possible to change the min-values of Crop?
something like