'use strict';

var React = require('react');
var PropTypes = require('prop-types');
var SendbirdProvider = require('./SendbirdProvider.js');
var MediaQueryContext = require('./MediaQueryContext-8ec3f647.js');
var ChannelList = require('./ChannelList.js');
var Channel = require('./Channel.js');
var ChannelSettings = require('./ChannelSettings.js');
var MessageSearch = require('./MessageSearch.js');
var Thread = require('./Thread.js');
var groupChannel = require('@sendbird/chat/groupChannel');
var useSendbirdStateContext = require('./useSendbirdStateContext.js');
var uuid = require('./uuid-0b4ed44c.js');
var consts = require('./consts-a5382bc1.js');
require('./_rollupPluginBabelHelpers-c5955c81.js');
require('./withSendbird.js');
require('css-vars-ponyfill');
require('./index.module-9f5edc7b.js');
require('./actionTypes-f2efbb7c.js');
require('@sendbird/chat');
require('@sendbird/chat/openChannel');
require('./index-f2146bae.js');
require('./utils/message/getOutgoingMessageState.js');
require('./index-9d518988.js');
require('./VoiceRecorder/context.js');
require('./LocalizationContext-af96cf5f.js');
require('./stringSet-68748705.js');
require('./index-83d1d15e.js');
require('./ChannelListProvider-61d644da.js');
require('./topics-825e5d42.js');
require('./utils-d5176360.js');
require('./UserProfileContext-f068b0ba.js');
require('./ChannelList/components/ChannelListUI.js');
require('./ChannelList/components/ChannelListHeader.js');
require('./index-73643285.js');
require('./ui/Avatar.js');
require('./ui/ImageRenderer.js');
require('./ui/Icon.js');
require('./ChannelList/components/AddChannel.js');
require('./ui/IconButton.js');
require('./CreateChannel.js');
require('./CreateChannel/components/CreateChannelUI.js');
require('./CreateChannelProvider-88b316a6.js');
require('./sendbirdSelectors.js');
require('./CreateChannel/components/InviteUsers.js');
require('./ui/Modal.js');
require('react-dom');
require('./index-68c57136.js');
require('./ui/Button.js');
require('./ui/UserListItem.js');
require('./ui/MutedAvatarOverlay.js');
require('./ui/Checkbox.js');
require('./ui/UserProfile.js');
require('./ui/ContextMenu.js');
require('./ui/SortByRow.js');
require('./CreateChannel/components/SelectChannelType.js');
require('./ChannelList/components/ChannelPreview.js');
require('./ui/ChannelAvatar.js');
require('./utils-7f75ad97.js');
require('./ui/Badge.js');
require('./index-900dd19f.js');
require('./index-f65677b1.js');
require('./ui/Loader.js');
require('./index-6cb4a530.js');
require('./index-4ee95667.js');
require('./ui/MentionUserLabel.js');
require('./consts-6ec77e9a.js');
require('./ui/TextButton.js');
require('./color-afeb8dc2.js');
require('./Channel/components/TypingIndicator.js');
require('./ChannelProvider-620bb354.js');
require('./compareIds-18b3b1d6.js');
require('./const-6691e574.js');
require('@sendbird/chat/message');
require('./ui/ReactionButton.js');
require('./useLongPress-d9deb354.js');
require('./ChannelList/components/ChannelPreviewAction.js');
require('./EditUserProfile.js');
require('./index-a50b2339.js');
require('./ui/Input.js');
require('./index-ff8ea47f.js');
require('./Channel/components/ChannelUI.js');
require('./ui/ConnectionStatus.js');
require('./Channel/components/ChannelHeader.js');
require('./utils-4b74ea64.js');
require('./Channel/components/MessageList.js');
require('./Channel/components/Message.js');
require('./Channel/components/SuggestedMentionList.js');
require('./const-ab0f6056.js');
require('./ThreadProvider-572574d7.js');
require('./Thread/context/types.js');
require('./ui/DateSeparator.js');
require('./ui/MessageInput.js');
require('dompurify');
require('./consts-bc27beff.js');
require('./consts-a422c2f9.js');
require('./tokenize-d86ab0c7.js');
require('./ui/MessageContent.js');
require('./ui/MessageItemMenu.js');
require('./types-24accb8d.js');
require('./ui/MessageItemReactionMenu.js');
require('./ui/EmojiReactions.js');
require('./ui/Tooltip.js');
require('./ui/TooltipWrapper.js');
require('./ui/ReactionBadge.js');
require('./ui/AdminMessage.js');
require('./ui/TextMessageItemBody.js');
require('./index-0b344bd7.js');
require('./Message/context.js');
require('./ui/MentionLabel.js');
require('./ui/LinkLabel.js');
require('./ui/FileMessageItemBody.js');
require('./ui/ThumbnailMessageItemBody.js');
require('./ui/OGMessageItemBody.js');
require('./ui/UnknownMessageItemBody.js');
require('./ui/QuoteMessage.js');
require('./ui/BottomSheet.js');
require('./ui/ThreadReplies.js');
require('./ui/VoiceMessageItemBody.js');
require('./ui/ProgressBar.js');
require('./VoicePlayer/useVoicePlayer.js');
require('./ui/PlaybackTime.js');
require('./Channel/components/FileViewer.js');
require('./Channel/components/RemoveMessageModal.js');
require('./index-8049c2a3.js');
require('./Channel/components/UnreadCount.js');
require('./Channel/components/FrozenNotification.js');
require('./Channel/components/MessageInput.js');
require('./ui/QuoteMessageInput.js');
require('./VoiceMessageInputWrapper-db7f2b72.js');
require('./VoiceRecorder/useVoiceRecorder.js');
require('./index-c1de8d8f.js');
require('./ChannelSettings/components/ChannelSettingsUI.js');
require('./ChannelSettings/context.js');
require('./ChannelSettings/components/ChannelProfile.js');
require('./ChannelSettings/components/EditDetailsModal.js');
require('./ChannelSettings/components/ModerationPanel.js');
require('./ui/Accordion.js');
require('./ui/AccordionGroup.js');
require('./context-60c4d3b7.js');
require('./ui/Toggle.js');
require('./ChannelSettings/components/UserListItem.js');
require('./MemberList-7513f386.js');
require('./ChannelSettings/components/LeaveChannel.js');
require('./ChannelSettings/components/UserPanel.js');
require('./MessageSearch/components/MessageSearchUI.js');
require('./MessageSearch/context.js');
require('./ui/MessageSearchItem.js');
require('./ui/MessageSearchFileItem.js');
require('./Thread/components/ThreadUI.js');
require('./Thread/components/ParentMessageInfo.js');
require('./RemoveMessageModal-15d1dcbd.js');
require('./Thread/components/ParentMessageInfoItem.js');
require('./ui/FileViewer.js');
require('./Thread/components/ThreadHeader.js');
require('./Thread/components/ThreadList.js');
require('./Thread/components/ThreadListItem.js');
require('date-fns');
require('./Thread/components/ThreadMessageInput.js');

function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }

var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
var PropTypes__default = /*#__PURE__*/_interopDefaultLegacy(PropTypes);

const DesktopLayout = props => {
  const {
    isReactionEnabled,
    replyType,
    isMessageGroupingEnabled,
    allowProfileEdit,
    showSearchIcon,
    onProfileEditSuccess,
    disableAutoSelect,
    currentChannel,
    setCurrentChannel,
    showSettings,
    setShowSettings,
    showSearch,
    setShowSearch,
    highlightedMessage,
    setHighlightedMessage,
    startingPoint,
    setStartingPoint,
    showThread,
    setShowThread,
    threadTargetMessage,
    setThreadTargetMessage
  } = props;
  const [animatedMessageId, setAnimatedMessageId] = React.useState(null);
  return /*#__PURE__*/React__default["default"].createElement("div", {
    className: "sendbird-app__wrap"
  }, /*#__PURE__*/React__default["default"].createElement("div", {
    className: "sendbird-app__channellist-wrap"
  }, /*#__PURE__*/React__default["default"].createElement(ChannelList, {
    allowProfileEdit: allowProfileEdit,
    activeChannelUrl: currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url,
    onProfileEditSuccess: onProfileEditSuccess,
    disableAutoSelect: disableAutoSelect,
    onChannelSelect: channel => {
      setStartingPoint(null);
      setHighlightedMessage(null);
      if (channel) {
        setCurrentChannel(channel);
      } else {
        setCurrentChannel(null);
      }
    }
  })), /*#__PURE__*/React__default["default"].createElement("div", {
    className: `
          ${showSettings ? 'sendbird-app__conversation--settings-open' : ''}
          ${showSearch ? 'sendbird-app__conversation--search-open' : ''}
          sendbird-app__conversation-wrap
        `
  }, /*#__PURE__*/React__default["default"].createElement(Channel, {
    channelUrl: (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url) || '',
    onChatHeaderActionClick: () => {
      setShowSearch(false);
      setShowThread(false);
      setShowSettings(!showSettings);
    },
    onSearchClick: () => {
      setShowSettings(false);
      setShowThread(false);
      setShowSearch(!showSearch);
    },
    onReplyInThread: _ref => {
      let {
        message
      } = _ref;
      // parent message
      setShowSettings(false);
      setShowSearch(false);
      if (replyType === 'THREAD') {
        setThreadTargetMessage(message);
        setShowThread(true);
      }
    },
    onQuoteMessageClick: _ref2 => {
      let {
        message
      } = _ref2;
      // thread message
      setShowSettings(false);
      setShowSearch(false);
      if (replyType === 'THREAD') {
        setThreadTargetMessage(message);
        setShowThread(true);
      }
    },
    onMessageAnimated: () => {
      setAnimatedMessageId(null);
    },
    onMessageHighlighted: () => {
      setHighlightedMessage(null);
    },
    showSearchIcon: showSearchIcon,
    startingPoint: startingPoint,
    animatedMessage: animatedMessageId,
    highlightedMessage: highlightedMessage,
    isReactionEnabled: isReactionEnabled,
    replyType: replyType,
    isMessageGroupingEnabled: isMessageGroupingEnabled
  })), showSettings && /*#__PURE__*/React__default["default"].createElement("div", {
    className: "sendbird-app__settingspanel-wrap"
  }, /*#__PURE__*/React__default["default"].createElement(ChannelSettings, {
    className: "sendbird-channel-settings",
    channelUrl: (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url) || '',
    onCloseClick: () => {
      setShowSettings(false);
    }
  })), showSearch && /*#__PURE__*/React__default["default"].createElement("div", {
    className: "sendbird-app__searchpanel-wrap"
  }, /*#__PURE__*/React__default["default"].createElement(MessageSearch, {
    channelUrl: (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url) || '',
    onResultClick: message => {
      if (message.messageId === highlightedMessage) {
        setHighlightedMessage(null);
        setTimeout(() => {
          setHighlightedMessage(message.messageId);
        });
      } else {
        setStartingPoint(message.createdAt);
        setHighlightedMessage(message.messageId);
      }
    },
    onCloseClick: () => {
      setShowSearch(false);
    }
  })), showThread && /*#__PURE__*/React__default["default"].createElement(Thread, {
    className: "sendbird-app__thread",
    channelUrl: (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url) || '',
    message: threadTargetMessage,
    onHeaderActionClick: () => {
      setShowThread(false);
    },
    onMoveToParentMessage: _ref3 => {
      let {
        message,
        channel
      } = _ref3;
      if ((channel === null || channel === void 0 ? void 0 : channel.url) !== (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url)) {
        setCurrentChannel(channel);
      }
      if ((message === null || message === void 0 ? void 0 : message.messageId) !== animatedMessageId) {
        setStartingPoint(message === null || message === void 0 ? void 0 : message.createdAt);
      }
      setTimeout(() => {
        setAnimatedMessageId(message === null || message === void 0 ? void 0 : message.messageId);
      }, 500);
    }
  }));
};

var PANELS = /*#__PURE__*/function (PANELS) {
  PANELS["CHANNEL_LIST"] = "CHANNEL_LIST";
  PANELS["CHANNEL"] = "CHANNEL";
  PANELS["CHANNEL_SETTINGS"] = "CHANNEL_SETTINGS";
  PANELS["MESSAGE_SEARCH"] = "MESSAGE_SEARCH";
  return PANELS;
}(PANELS || {});
const MobileLayout = props => {
  var _store$stores, _store$stores$sdkStor, _store$config;
  const {
    replyType,
    isMessageGroupingEnabled,
    allowProfileEdit,
    isReactionEnabled,
    showSearchIcon,
    onProfileEditSuccess,
    currentChannel,
    setCurrentChannel,
    highlightedMessage,
    setHighlightedMessage,
    startingPoint,
    setStartingPoint
  } = props;
  const [panel, setPanel] = React.useState(PANELS === null || PANELS === void 0 ? void 0 : PANELS.CHANNEL_LIST);
  const store = useSendbirdStateContext();
  const sdk = store === null || store === void 0 ? void 0 : (_store$stores = store.stores) === null || _store$stores === void 0 ? void 0 : (_store$stores$sdkStor = _store$stores.sdkStore) === null || _store$stores$sdkStor === void 0 ? void 0 : _store$stores$sdkStor.sdk;
  const userId = store === null || store === void 0 ? void 0 : (_store$config = store.config) === null || _store$config === void 0 ? void 0 : _store$config.userId;
  const goToMessage = message => {
    setStartingPoint(message === null || message === void 0 ? void 0 : message.createdAt);
    setTimeout(() => {
      setHighlightedMessage(message === null || message === void 0 ? void 0 : message.messageId);
    });
  };
  React.useEffect(() => {
    if (panel !== (PANELS === null || PANELS === void 0 ? void 0 : PANELS.CHANNEL)) {
      goToMessage();
    }
  }, [panel]);
  React.useEffect(() => {
    var _sdk$groupChannel;
    const handlerId = uuid.uuidv4();
    if (sdk !== null && sdk !== void 0 && (_sdk$groupChannel = sdk.groupChannel) !== null && _sdk$groupChannel !== void 0 && _sdk$groupChannel.addGroupChannelHandler) {
      var _sdk$groupChannel2;
      const handler = new groupChannel.GroupChannelHandler({
        onUserBanned: (groupChannel, user) => {
          if (groupChannel.url === (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url) && (user === null || user === void 0 ? void 0 : user.userId) === userId) {
            setPanel(PANELS.CHANNEL_LIST);
          }
        },
        onChannelDeleted: channelUrl => {
          if (channelUrl === (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url)) {
            setPanel(PANELS.CHANNEL_LIST);
          }
        },
        onUserLeft: (groupChannel, user) => {
          if (groupChannel.url === (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url) && (user === null || user === void 0 ? void 0 : user.userId) === userId) {
            setPanel(PANELS.CHANNEL_LIST);
          }
        }
      });
      sdk === null || sdk === void 0 ? void 0 : (_sdk$groupChannel2 = sdk.groupChannel) === null || _sdk$groupChannel2 === void 0 ? void 0 : _sdk$groupChannel2.addGroupChannelHandler(handlerId, handler);
    }
    return () => {
      var _sdk$groupChannel3, _sdk$groupChannel3$re;
      sdk === null || sdk === void 0 ? void 0 : (_sdk$groupChannel3 = sdk.groupChannel) === null || _sdk$groupChannel3 === void 0 ? void 0 : (_sdk$groupChannel3$re = _sdk$groupChannel3.removeGroupChannelHandler) === null || _sdk$groupChannel3$re === void 0 ? void 0 : _sdk$groupChannel3$re.call(_sdk$groupChannel3, handlerId);
    };
  }, [sdk]);
  return /*#__PURE__*/React__default["default"].createElement("div", null, panel === (PANELS === null || PANELS === void 0 ? void 0 : PANELS.CHANNEL_LIST) && /*#__PURE__*/React__default["default"].createElement("div", {
    className: "sb_mobile__panelwrap"
  }, /*#__PURE__*/React__default["default"].createElement(ChannelList, {
    onProfileEditSuccess: onProfileEditSuccess,
    onChannelSelect: channel => {
      setCurrentChannel(channel);
      setPanel(PANELS.CHANNEL);
    },
    allowProfileEdit: allowProfileEdit
    // this condition must be true for mobile
    ,
    disableAutoSelect: true
  })), panel === (PANELS === null || PANELS === void 0 ? void 0 : PANELS.CHANNEL) && /*#__PURE__*/React__default["default"].createElement("div", {
    className: "sb_mobile__panelwrap"
  }, /*#__PURE__*/React__default["default"].createElement(Channel, {
    replyType: replyType,
    channelUrl: (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url) || '',
    onSearchClick: () => {
      setPanel(PANELS.MESSAGE_SEARCH);
    },
    onBackClick: () => {
      setPanel(PANELS.CHANNEL_LIST);
    },
    isReactionEnabled: isReactionEnabled,
    showSearchIcon: showSearchIcon,
    isMessageGroupingEnabled: isMessageGroupingEnabled,
    startingPoint: startingPoint,
    highlightedMessage: highlightedMessage,
    onChatHeaderActionClick: () => {
      setPanel(PANELS.CHANNEL_SETTINGS);
    }
  })), panel === (PANELS === null || PANELS === void 0 ? void 0 : PANELS.CHANNEL_SETTINGS) && /*#__PURE__*/React__default["default"].createElement("div", {
    className: "sb_mobile__panelwrap"
  }, /*#__PURE__*/React__default["default"].createElement(ChannelSettings, {
    channelUrl: (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url) || '',
    onCloseClick: () => {
      setPanel(PANELS.CHANNEL);
    },
    onLeaveChannel: () => {
      setPanel(PANELS.CHANNEL_LIST);
    }
  })), panel === (PANELS === null || PANELS === void 0 ? void 0 : PANELS.MESSAGE_SEARCH) && /*#__PURE__*/React__default["default"].createElement("div", {
    className: "sb_mobile__panelwrap"
  }, /*#__PURE__*/React__default["default"].createElement(MessageSearch, {
    channelUrl: (currentChannel === null || currentChannel === void 0 ? void 0 : currentChannel.url) || '',
    onCloseClick: () => {
      setPanel(PANELS.CHANNEL);
    },
    onResultClick: message => {
      setPanel(PANELS.CHANNEL);
      goToMessage(message);
    }
  })));
};

const AppLayout = props => {
  const {
    isReactionEnabled,
    replyType,
    isMessageGroupingEnabled,
    allowProfileEdit,
    showSearchIcon,
    onProfileEditSuccess,
    disableAutoSelect,
    currentChannel,
    setCurrentChannel
  } = props;
  const [showThread, setShowThread] = React.useState(false);
  const [threadTargetMessage, setThreadTargetMessage] = React.useState(null);
  const [showSettings, setShowSettings] = React.useState(false);
  const [showSearch, setShowSearch] = React.useState(false);
  const [highlightedMessage, setHighlightedMessage] = React.useState(null);
  const [startingPoint, setStartingPoint] = React.useState(null);
  const {
    isMobile
  } = MediaQueryContext.useMediaQueryContext();
  return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, isMobile ? /*#__PURE__*/React__default["default"].createElement(MobileLayout, {
    replyType: replyType,
    isMessageGroupingEnabled: isMessageGroupingEnabled,
    allowProfileEdit: allowProfileEdit,
    isReactionEnabled: isReactionEnabled,
    showSearchIcon: showSearchIcon,
    onProfileEditSuccess: onProfileEditSuccess,
    currentChannel: currentChannel,
    setCurrentChannel: setCurrentChannel,
    highlightedMessage: highlightedMessage,
    setHighlightedMessage: setHighlightedMessage,
    startingPoint: startingPoint,
    setStartingPoint: setStartingPoint
  }) : /*#__PURE__*/React__default["default"].createElement(DesktopLayout, {
    isReactionEnabled: isReactionEnabled,
    replyType: replyType,
    isMessageGroupingEnabled: isMessageGroupingEnabled,
    allowProfileEdit: allowProfileEdit,
    showSearchIcon: showSearchIcon,
    onProfileEditSuccess: onProfileEditSuccess,
    disableAutoSelect: disableAutoSelect,
    currentChannel: currentChannel,
    setCurrentChannel: setCurrentChannel,
    showThread: showThread,
    setShowThread: setShowThread,
    threadTargetMessage: threadTargetMessage,
    setThreadTargetMessage: setThreadTargetMessage,
    showSettings: showSettings,
    setShowSettings: setShowSettings,
    showSearch: showSearch,
    setShowSearch: setShowSearch,
    highlightedMessage: highlightedMessage,
    setHighlightedMessage: setHighlightedMessage,
    startingPoint: startingPoint,
    setStartingPoint: setStartingPoint
  }));
};

/**
 * This is a drop in Chat solution
 * Can also be used as an example for creating
 * default chat apps
 */
function App(props) {
  const {
    appId,
    userId,
    accessToken,
    customApiHost,
    customWebSocketHost,
    mediaQueryBreakPoint,
    theme,
    userListQuery,
    nickname,
    profileUrl,
    dateLocale,
    config = {},
    isReactionEnabled,
    isMentionEnabled,
    isVoiceMessageEnabled,
    voiceRecord,
    replyType,
    isMessageGroupingEnabled,
    colorSet,
    stringSet,
    allowProfileEdit,
    disableUserProfile,
    disableMarkAsDelivered,
    renderUserProfile,
    showSearchIcon,
    onProfileEditSuccess,
    imageCompression,
    disableAutoSelect,
    isTypingIndicatorEnabledOnChannelList,
    isMessageReceiptStatusEnabledOnChannelList
  } = props;
  const [currentChannel, setCurrentChannel] = React.useState(null);
  return /*#__PURE__*/React__default["default"].createElement(SendbirdProvider, {
    stringSet: stringSet,
    appId: appId,
    userId: userId,
    accessToken: accessToken,
    customApiHost: customApiHost,
    customWebSocketHost: customWebSocketHost,
    mediaQueryBreakPoint: mediaQueryBreakPoint,
    theme: theme,
    nickname: nickname,
    profileUrl: profileUrl,
    dateLocale: dateLocale,
    userListQuery: userListQuery,
    config: config,
    colorSet: colorSet,
    disableUserProfile: disableUserProfile,
    disableMarkAsDelivered: disableMarkAsDelivered,
    renderUserProfile: renderUserProfile,
    imageCompression: imageCompression,
    isReactionEnabled: isReactionEnabled,
    isMentionEnabled: isMentionEnabled,
    isVoiceMessageEnabled: isVoiceMessageEnabled,
    voiceRecord: voiceRecord,
    onUserProfileMessage: channel => {
      setCurrentChannel(channel);
    },
    isTypingIndicatorEnabledOnChannelList: isTypingIndicatorEnabledOnChannelList,
    isMessageReceiptStatusEnabledOnChannelList: isMessageReceiptStatusEnabledOnChannelList,
    replyType: replyType
  }, /*#__PURE__*/React__default["default"].createElement(AppLayout, {
    isReactionEnabled: isReactionEnabled,
    replyType: replyType,
    isMessageGroupingEnabled: isMessageGroupingEnabled,
    allowProfileEdit: allowProfileEdit,
    showSearchIcon: showSearchIcon,
    onProfileEditSuccess: onProfileEditSuccess,
    disableAutoSelect: disableAutoSelect,
    currentChannel: currentChannel,
    setCurrentChannel: setCurrentChannel
  }));
}
App.propTypes = {
  appId: PropTypes__default["default"].string.isRequired,
  userId: PropTypes__default["default"].string.isRequired,
  accessToken: PropTypes__default["default"].string,
  customApiHost: PropTypes__default["default"].string,
  customWebSocketHost: PropTypes__default["default"].string,
  theme: PropTypes__default["default"].string,
  userListQuery: PropTypes__default["default"].func,
  nickname: PropTypes__default["default"].string,
  profileUrl: PropTypes__default["default"].string,
  mediaQueryBreakPoint: PropTypes__default["default"].string,
  allowProfileEdit: PropTypes__default["default"].bool,
  disableUserProfile: PropTypes__default["default"].bool,
  disableMarkAsDelivered: PropTypes__default["default"].bool,
  renderUserProfile: PropTypes__default["default"].func,
  onProfileEditSuccess: PropTypes__default["default"].func,
  dateLocale: PropTypes__default["default"].shape({}),
  config: PropTypes__default["default"].shape({
    // None Error Warning Info 'All/Debug'
    logLevel: PropTypes__default["default"].oneOfType([PropTypes__default["default"].string, PropTypes__default["default"].arrayOf(PropTypes__default["default"].string)]),
    isREMUnitEnabled: PropTypes__default["default"].bool
  }),
  isReactionEnabled: PropTypes__default["default"].bool,
  replyType: PropTypes__default["default"].oneOf(['NONE', 'QUOTE_REPLY', 'THREAD']),
  showSearchIcon: PropTypes__default["default"].bool,
  isMessageGroupingEnabled: PropTypes__default["default"].bool,
  stringSet: PropTypes__default["default"].objectOf(PropTypes__default["default"].string),
  colorSet: PropTypes__default["default"].objectOf(PropTypes__default["default"].string),
  imageCompression: PropTypes__default["default"].shape({
    compressionRate: PropTypes__default["default"].number,
    resizingWidth: PropTypes__default["default"].oneOfType([PropTypes__default["default"].number, PropTypes__default["default"].string]),
    resizingHeight: PropTypes__default["default"].oneOfType([PropTypes__default["default"].number, PropTypes__default["default"].string])
  }),
  disableAutoSelect: PropTypes__default["default"].bool,
  isMentionEnabled: PropTypes__default["default"].bool,
  isVoiceMessageEnabled: PropTypes__default["default"].bool,
  voiceRecord: PropTypes__default["default"].shape({
    maxRecordingTime: PropTypes__default["default"].number,
    minRecordingTime: PropTypes__default["default"].number
  }),
  isTypingIndicatorEnabledOnChannelList: PropTypes__default["default"].bool,
  isMessageReceiptStatusEnabledOnChannelList: PropTypes__default["default"].bool
};
App.defaultProps = {
  accessToken: '',
  customApiHost: '',
  customWebSocketHost: '',
  theme: 'light',
  nickname: '',
  profileUrl: '',
  userListQuery: null,
  mediaQueryBreakPoint: null,
  dateLocale: null,
  allowProfileEdit: false,
  onProfileEditSuccess: null,
  disableUserProfile: false,
  disableMarkAsDelivered: false,
  showSearchIcon: false,
  renderUserProfile: null,
  config: {},
  isReactionEnabled: true,
  isMentionEnabled: false,
  isVoiceMessageEnabled: true,
  voiceRecord: {
    maxRecordingTime: consts.VOICE_RECORDER_DEFAULT_MAX,
    minRecordingTime: consts.VOICE_RECORDER_DEFAULT_MIN
  },
  replyType: 'NONE',
  isMessageGroupingEnabled: true,
  stringSet: null,
  colorSet: null,
  imageCompression: {},
  disableAutoSelect: false,
  isTypingIndicatorEnabledOnChannelList: false,
  isMessageReceiptStatusEnabledOnChannelList: false
};

module.exports = App;
//# sourceMappingURL=App.js.map
