kui-crm 0.0.67 → 0.0.68

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/cjs/index.js CHANGED
@@ -2682,6 +2682,8 @@ var AdaptiveImagesBlock = React.forwardRef(function (props) {
2682
2682
  var displayedImagesCount = displayedCardsCount - staticCards - blurImage.length;
2683
2683
  var displayedImages = images.slice(0, displayedImagesCount);
2684
2684
  var notDisplayedImagesCount = images.slice(displayedImagesCount).length;
2685
+ var withFlatWidth = displayedImages.length + staticCards + blurImage.length >=
2686
+ displayedCardsCount;
2685
2687
  var handleClick = function (index) {
2686
2688
  setSelectedImage(index);
2687
2689
  handleModalOpen();
@@ -2697,7 +2699,7 @@ var AdaptiveImagesBlock = React.forwardRef(function (props) {
2697
2699
  handleResize();
2698
2700
  return function () { return window.removeEventListener("resize", handleResize); };
2699
2701
  }, [ref]);
2700
- return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsxs(Wrapper, __assign({ container: true, ref: ref, spacing: 1, justify: blurImage.length ? "space-between" : "flex-start" }, otherProps, { children: [displayedImages.map(function (image, index) { return (jsxRuntime.jsx(kuiBasic.Grid, __assign({ item: true }, { children: jsxRuntime.jsx(ImageCard, { url: image.smallImageUrl, index: index, onClick: handleClick }) }), image.smallImageUrl)); }), !!blurImage.length && !!notDisplayedImagesCount && (jsxRuntime.jsx(kuiBasic.Grid, __assign({ item: true }, { children: jsxRuntime.jsx(ImageCardWithBackdrop, { url: blurImage[0].smallImageUrl, count: notDisplayedImagesCount, index: displayedImages.length, onClick: handleClick }) }))), blurImage.length > 0 && notDisplayedImagesCount === 0 && (jsxRuntime.jsx(kuiBasic.Grid, __assign({ item: true }, { children: jsxRuntime.jsx(ImageCard, { url: blurImage[0].smallImageUrl, index: displayedImages.length, onClick: handleClick }) }))), endComponent] })), jsxRuntime.jsx(GalleryWithThumbnails, { images: images, activeSlide: selectedImage, isOpen: isModalOpen, handleClose: handleModalClose, onDelete: onDelete })] }));
2702
+ return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsxs(Wrapper, __assign({ container: true, ref: ref, spacing: 1, justify: withFlatWidth ? "space-between" : "flex-start" }, otherProps, { children: [displayedImages.map(function (image, index) { return (jsxRuntime.jsx(kuiBasic.Grid, __assign({ item: true }, { children: jsxRuntime.jsx(ImageCard, { url: image.smallImageUrl, index: index, onClick: handleClick }) }), image.smallImageUrl)); }), !!blurImage.length && !!notDisplayedImagesCount && (jsxRuntime.jsx(kuiBasic.Grid, __assign({ item: true }, { children: jsxRuntime.jsx(ImageCardWithBackdrop, { url: blurImage[0].smallImageUrl, count: notDisplayedImagesCount, index: displayedImages.length, onClick: handleClick }) }))), blurImage.length > 0 && notDisplayedImagesCount === 0 && (jsxRuntime.jsx(kuiBasic.Grid, __assign({ item: true }, { children: jsxRuntime.jsx(ImageCard, { url: blurImage[0].smallImageUrl, index: displayedImages.length, onClick: handleClick }) }))), endComponent] })), jsxRuntime.jsx(GalleryWithThumbnails, { images: images, activeSlide: selectedImage, isOpen: isModalOpen, handleClose: handleModalClose, onDelete: onDelete })] }));
2701
2703
  });
2702
2704
  var Wrapper = styled__default["default"](kuiBasic.Grid)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n overflow: hidden;\n flex-wrap: nowrap;\n"], ["\n overflow: hidden;\n flex-wrap: nowrap;\n"])));
2703
2705
  var templateObject_1;