@meduza/ui-kit-2 0.1.47 → 0.1.49
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/Image/Image.types.d.ts +0 -1
- package/dist/ui-kit-2.cjs.development.js +5 -7
- package/dist/ui-kit-2.cjs.development.js.map +1 -1
- package/dist/ui-kit-2.cjs.production.min.js +1 -1
- package/dist/ui-kit-2.cjs.production.min.js.map +1 -1
- package/dist/ui-kit-2.esm.js +5 -7
- package/dist/ui-kit-2.esm.js.map +1 -1
- package/dist/ui-kit.css +1279 -1279
- package/package.json +1 -1
- package/src/GroupedBlock/index.tsx +6 -3
- package/src/Image/Image.types.ts +0 -1
- package/src/Image/index.tsx +2 -3
package/dist/ui-kit-2.esm.js
CHANGED
|
@@ -436,8 +436,6 @@ var Image = function Image(_ref) {
|
|
|
436
436
|
height = _ref.height,
|
|
437
437
|
source = _ref.source,
|
|
438
438
|
lazy = _ref.lazy,
|
|
439
|
-
_ref$fullscreen = _ref.fullscreen,
|
|
440
|
-
fullscreen = _ref$fullscreen === void 0 ? true : _ref$fullscreen,
|
|
441
439
|
ratio = _ref.ratio,
|
|
442
440
|
styleContext = _ref.styleContext;
|
|
443
441
|
|
|
@@ -449,7 +447,7 @@ var Image = function Image(_ref) {
|
|
|
449
447
|
setIsLoaded = _useState[1];
|
|
450
448
|
|
|
451
449
|
var handleClick = function handleClick() {
|
|
452
|
-
if (!
|
|
450
|
+
if (!lightBox || optimized && !optimized.original) {
|
|
453
451
|
return;
|
|
454
452
|
}
|
|
455
453
|
|
|
@@ -466,7 +464,7 @@ var Image = function Image(_ref) {
|
|
|
466
464
|
/* fallback w325 url until w6 was released */
|
|
467
465
|
|
|
468
466
|
var fallbackSource = source && source[0] || optimized.w325 && optimized.w325['1x'] || optimized.original;
|
|
469
|
-
var classNames = [[styles$4.root, true], [styles$4.isLoaded, isLoaded], [styles$4.fullscreen,
|
|
467
|
+
var classNames = [[styles$4.root, true], [styles$4.isLoaded, isLoaded], [styles$4.fullscreen, lightBox && optimized && optimized.original]];
|
|
470
468
|
|
|
471
469
|
if (styleContext) {
|
|
472
470
|
classNames = makeStyleContext(classNames, styleContext, styles$4);
|
|
@@ -1737,11 +1735,11 @@ var GroupedBlock = function GroupedBlock(_ref) {
|
|
|
1737
1735
|
onlyOn = _ref.block.only_on,
|
|
1738
1736
|
styleContext = _ref.styleContext;
|
|
1739
1737
|
var maxHeight = Math.min.apply(Math, block.data.map(function (item) {
|
|
1740
|
-
return item.data && item.data.height || item.item.data.height;
|
|
1738
|
+
return item.data && item.data.height || item.item && item.item.data.height;
|
|
1741
1739
|
}));
|
|
1742
1740
|
var normalizedBoxesWidth = block.data.map(function (item) {
|
|
1743
|
-
var width = item.data && item.data.width || item.item.data.heigh;
|
|
1744
|
-
var height = item.data && item.data.height || item.item.data.heigh;
|
|
1741
|
+
var width = item.data && item.data.width || item.item && item.item.data.heigh;
|
|
1742
|
+
var height = item.data && item.data.height || item.item && item.item.data.heigh;
|
|
1745
1743
|
return width / (height / maxHeight);
|
|
1746
1744
|
});
|
|
1747
1745
|
var sumWidth = normalizedBoxesWidth.reduce(function (sum, x) {
|