@wix/entity-advanced-permissions 1.1251.0 → 1.1252.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/statics/entity-advanced-permissions.umd.js +4 -10
- package/dist/statics/entity-advanced-permissions.umd.js.map +1 -1
- package/dist/statics/entity-advanced-permissions.umd.min.js +1 -1
- package/dist/statics/entity-advanced-permissions.umd.min.js.map +1 -1
- package/dist/statics/manifest.json +2 -2
- package/dist/statics/manifest.min.json +2 -2
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +8 -8
|
@@ -64069,19 +64069,12 @@ function isValidRequest(fittingType, src, target) {
|
|
|
64069
64069
|
function canTransformIfAnimatedWEBP(uri, hasAnimation, allowAnimatedTransform = false) {
|
|
64070
64070
|
return !(isWEBP(uri) && hasAnimation && !allowAnimatedTransform);
|
|
64071
64071
|
}
|
|
64072
|
-
/**
|
|
64073
|
-
* returns true if image is of GIF type and animated transform is allowed (experiment in placeholder flow)
|
|
64074
|
-
*/
|
|
64075
|
-
function isTransformableGIF(uri, allowAnimatedTransform = false) {
|
|
64076
|
-
return isGIF(uri) && allowAnimatedTransform;
|
|
64077
|
-
}
|
|
64078
64072
|
/**
|
|
64079
64073
|
* check if image transform is supported for source image
|
|
64080
64074
|
*/
|
|
64081
64075
|
function isImageTransformApplicable(uri, hasAnimation, allowAnimatedTransform) {
|
|
64082
64076
|
return (canTransformIfAnimatedWEBP(uri, hasAnimation, allowAnimatedTransform) &&
|
|
64083
|
-
|
|
64084
|
-
isTransformableGIF(uri, allowAnimatedTransform)) &&
|
|
64077
|
+
isImageTypeSupported(uri) &&
|
|
64085
64078
|
!isExternalUrl(uri));
|
|
64086
64079
|
}
|
|
64087
64080
|
/**
|
|
@@ -65934,10 +65927,11 @@ const PLACEHOLDER_IMG_CSS_OVERRIDES = { width: '100%', height: '100%' };
|
|
|
65934
65927
|
* @returns {ImageDataAttributes}
|
|
65935
65928
|
*/
|
|
65936
65929
|
function getPlaceholder(fittingType, src, target, options = {}) {
|
|
65937
|
-
|
|
65930
|
+
const { autoEncode = true, isSEOBot, shouldLoadHQImage, hasAnimation, allowAnimatedTransform, } = options;
|
|
65931
|
+
if (!isValidRequest(fittingType, src, target) ||
|
|
65932
|
+
(isGIF(src.id) && allowAnimatedTransform)) {
|
|
65938
65933
|
return emptyData;
|
|
65939
65934
|
}
|
|
65940
|
-
const { autoEncode = true, isSEOBot, shouldLoadHQImage, hasAnimation, allowAnimatedTransform, } = options;
|
|
65941
65935
|
const canTransformImage = isImageTransformApplicable(src.id, hasAnimation, allowAnimatedTransform);
|
|
65942
65936
|
if (!canTransformImage || shouldLoadHQImage) {
|
|
65943
65937
|
/* Either:
|