stream-chat-react 10.22.1 → 10.22.2

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.
@@ -10886,7 +10886,16 @@ var StreamChatReact = (function (exports, React$2, streamChat, ReactDOM) {
10886
10886
 
10887
10887
  var ImageGallery = /*@__PURE__*/getDefaultExportFromCjs(imageGallery.exports);
10888
10888
 
10889
- window.StreamChat.StreamChat=StreamChat;window.StreamChat.logChatPromiseExecution=logChatPromiseExecution;window.StreamChat.Channel=Channel;window.ICAL=window.ICAL||{};var ModalGallery = function (props) {
10889
+ window.StreamChat.StreamChat=StreamChat;window.StreamChat.logChatPromiseExecution=logChatPromiseExecution;window.StreamChat.Channel=Channel;window.ICAL=window.ICAL||{};var onError = function (e) {
10890
+ // Prevent having alt attribute on img as the img takes the height of the alt text
10891
+ // instead of the CSS / element width & height when the CSS mask (fallback) is applied.
10892
+ e.target.alt = '';
10893
+ };
10894
+ var renderItem = function (_a) {
10895
+ var original = _a.original, originalAlt = _a.originalAlt;
10896
+ return (React__default["default"].createElement(BaseImage, { alt: originalAlt, className: 'image-gallery-image', onError: onError, src: original }));
10897
+ };
10898
+ var ModalGallery = function (props) {
10890
10899
  var images = props.images, index = props.index;
10891
10900
  var t = useTranslationContext('ModalGallery').t;
10892
10901
  var formattedArray = React$2.useMemo(function () {
@@ -10899,7 +10908,7 @@ var StreamChatReact = (function (exports, React$2, streamChat, ReactDOM) {
10899
10908
  };
10900
10909
  });
10901
10910
  }, [images]);
10902
- return (React__default["default"].createElement(ImageGallery, { items: formattedArray, showIndex: true, showPlayButton: false, showThumbnails: false, startIndex: index }));
10911
+ return (React__default["default"].createElement(ImageGallery, { items: formattedArray, renderItem: renderItem, showIndex: true, showPlayButton: false, showThumbnails: false, startIndex: index }));
10903
10912
  };
10904
10913
 
10905
10914
  window.StreamChat.StreamChat=StreamChat;window.StreamChat.logChatPromiseExecution=logChatPromiseExecution;window.StreamChat.Channel=Channel;window.ICAL=window.ICAL||{};var UnMemoizedGallery = function (props) {
@@ -47781,7 +47790,7 @@ var StreamChatReact = (function (exports, React$2, streamChat, ReactDOM) {
47781
47790
 
47782
47791
  window.StreamChat.StreamChat=StreamChat;window.StreamChat.logChatPromiseExecution=logChatPromiseExecution;window.StreamChat.Channel=Channel;window.ICAL=window.ICAL||{};
47783
47792
 
47784
- window.StreamChat.StreamChat=StreamChat;window.StreamChat.logChatPromiseExecution=logChatPromiseExecution;window.StreamChat.Channel=Channel;window.ICAL=window.ICAL||{};var version$1 = '10.22.1';
47793
+ window.StreamChat.StreamChat=StreamChat;window.StreamChat.logChatPromiseExecution=logChatPromiseExecution;window.StreamChat.Channel=Channel;window.ICAL=window.ICAL||{};var version$1 = '10.22.2';
47785
47794
 
47786
47795
  window.StreamChat.StreamChat=StreamChat;window.StreamChat.logChatPromiseExecution=logChatPromiseExecution;window.StreamChat.Channel=Channel;window.ICAL=window.ICAL||{};var useChat = function (_a) {
47787
47796
  var _b, _c;