You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On canvas area, outside of neither the uploaded image nor generated cropboxes, which is displayed like gray-meshed,
the event "touch-move" is interpreted as "crop-move".
Problem.
Under smartphone screen on its narrow width, it is apt to zoom the image by mistake,
whereas actually the user wants to scroll upwards or downwards.
Phenomenon.
On canvas area, outside of neither the uploaded image nor generated cropboxes, which is displayed like gray-meshed,
the event "touch-move" is interpreted as "crop-move".
Problem.
Under smartphone screen on its narrow width, it is apt to zoom the image by mistake,
whereas actually the user wants to scroll upwards or downwards.
This seems resolved on the predecessor library "cropper":
fengyuanchen/cropper#727
Solution ideas.
Here shows two alternatives, the one is conservative, the other brings rather destructive change:
Idea1. (conservative)
Introduce a new dragMode, in addition to CROP, MOVE and NONE,
or, Create a new independent mode "touch-scroll":
.cropper-container { ... -ms-touch-action: auto; touch-action: auto; }
and
.cropper-face, .cropper-line, .cropper-point { ... -ms-touch-action: none; touch-action: none; }
Idea2. (destructive)
Attach the configuration of Idea1 to DRAG_MODE_NONE as default.
You can test is as follows:
<button type="button" class="btn btn-primary" data-method="setDragMode" data-option="none" title="None"> <span class="docs-tooltip" data-toggle="tooltip" title="cropper.setDragMode("none")"> <span class="fa fa-scroll"></span> </span> </button>
And at the same time, toggle ALL CSS settings described in Idea1.
A sample design looks like
The text was updated successfully, but these errors were encountered: