UNPKG

cometchat-react-ui-kit2

Version:

CometChat UI Kit for React App

62 lines (61 loc) 3.64 kB
"use strict"; var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); Object.defineProperty(exports, "__esModule", { value: true }); exports.ConversationListConfiguration = void 0; var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass")); var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck")); var _ConversationListCustomView = require("../../../Chats/ConversationListCustomView"); var _Chats = require("../../../Chats/"); var _ConversationListItemConfiguration = require("./ConversationListItemConfiguration"); /** * @class ConversationListConfiguration * @param {Number} limit * @param {String} conversationType * @param {false} userAndGroupTags * @param {Array} tags * @param {Boolean} loadingIconURL * @param {Object} customView * @param {false} hideError * @param {false} enableSoundForMessages * @param {String} customIncomingMessageSound * @param {Object} style * @param {Object} conversationListItemConfiguration */var ConversationListConfiguration = /*#__PURE__*/(0, _createClass2["default"])(function ConversationListConfiguration(_ref) { var _ref$limit = _ref.limit, limit = _ref$limit === void 0 ? 30 : _ref$limit, _ref$conversationType = _ref.conversationType, conversationType = _ref$conversationType === void 0 ? "both" : _ref$conversationType, _ref$userAndGroupTags = _ref.userAndGroupTags, userAndGroupTags = _ref$userAndGroupTags === void 0 ? false : _ref$userAndGroupTags, _ref$tags = _ref.tags, tags = _ref$tags === void 0 ? [] : _ref$tags, _ref$loadingIconURL = _ref.loadingIconURL, loadingIconURL = _ref$loadingIconURL === void 0 ? "" : _ref$loadingIconURL, _ref$customView = _ref.customView, customView = _ref$customView === void 0 ? new _ConversationListCustomView.ConversationListCustomView({}) : _ref$customView, _ref$hideError = _ref.hideError, hideError = _ref$hideError === void 0 ? false : _ref$hideError, _ref$enableSoundForMe = _ref.enableSoundForMessages, enableSoundForMessages = _ref$enableSoundForMe === void 0 ? false : _ref$enableSoundForMe, _ref$customIncomingMe = _ref.customIncomingMessageSound, customIncomingMessageSound = _ref$customIncomingMe === void 0 ? "" : _ref$customIncomingMe, _ref$style = _ref.style, style = _ref$style === void 0 ? new _Chats.ConversationListStyles({}) : _ref$style, _ref$conversationList = _ref.conversationListItemConfiguration, conversationListItemConfiguration = _ref$conversationList === void 0 ? new _ConversationListItemConfiguration.ConversationListItemConfiguration({}) : _ref$conversationList; (0, _classCallCheck2["default"])(this, ConversationListConfiguration); this.limit = limit; this.conversationType = conversationType; this.userAndGroupTags = userAndGroupTags; this.tags = tags; this.loadingIconURL = loadingIconURL; this.customView = new _ConversationListCustomView.ConversationListCustomView(customView !== null && customView !== void 0 ? customView : {}); this.hideError = hideError; this.enableSoundForMessages = enableSoundForMessages; this.customIncomingMessageSound = customIncomingMessageSound; this.style = new _Chats.ConversationListStyles(style !== null && style !== void 0 ? style : {}); this.conversationListItemConfiguration = new _ConversationListItemConfiguration.ConversationListItemConfiguration(conversationListItemConfiguration !== null && conversationListItemConfiguration !== void 0 ? conversationListItemConfiguration : {}); }); exports.ConversationListConfiguration = ConversationListConfiguration;