Swap focal point order to left,top to match resize X,Y coordinates
This commit is contained in:
@@ -70,11 +70,11 @@ angular.module("umbraco")
|
||||
if ($scope.control.value.coordinates) {
|
||||
// New way, crop by percent must come before width/height.
|
||||
var coords = $scope.control.value.coordinates;
|
||||
url += `?crop=${coords.x1},${coords.y1},${coords.x2},${coords.y2}&cropmode=percentage`;
|
||||
url += `?cc=${coords.x1},${coords.y1},${coords.x2},${coords.y2}`;
|
||||
} else {
|
||||
// Here in order not to break existing content where focalPoint were used.
|
||||
if ($scope.control.value.focalPoint) {
|
||||
url += `?rxy=${$scope.control.value.focalPoint.top},${$scope.control.value.focalPoint.left}`;
|
||||
url += `?rxy=${$scope.control.value.focalPoint.left},${$scope.control.value.focalPoint.top}`;
|
||||
} else {
|
||||
// Prevent black padding and no crop when focal point not set / changed from default
|
||||
url += '?rxy=0.5,0.5';
|
||||
|
||||
Reference in New Issue
Block a user