PageSourceSearch

https://kainex.pl/wp-content/plugins/wise-chat-pro-with-ai/assets/js/wise-chat-pro.min.js?ver=3.7.1791072120

js kainex.pl collected 2026-10-04 00:13:36 UTC 1,415,915 bytes, 164 lines download raw bytes

1!function e(t,n,r){function i(a,s){if(!n[a]){if(!t[a]){var l="function"==typeof require&&require;if(!s&&l)return l(a,!0);if(o)return o(a,!0);var c=new Error("Cannot find module '"+a+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[a]={exports:{}};t[a][0].call(u.exports,(function(e){return i(t[a][1][e]||e)}),u,u.exports,e,t,n,r)}return n[a].exports}for(var o="function"==typeof require&&require,a=0;a<r.length;a++)i(r[a]);return i}({1:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("ui/chat/Chat")),d=r(e("engine/Engine")),h=r(e("./ui/common/PresenceChecker")),m=r(e("./ui/common/toasts/Toasts")),y=r(e("react-dom")),b=r(e("jquery"));function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var g=function(e){(0,a.default)(n,e);var t=v(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e,t,n){var r=this;e.destroyRequest!==this.props.destroyRequest&&(this.props.engine.stop(),y.default.unmountComponentAtNode(this.props.rootElement),(0,b.default)("#"+this.props.configuration.chatId).remove(),window._wiseChat.instances=window._wiseChat.instances.filter((function(e){return e.chatId!==r.props.configuration.chatId})))}},{key:"render",value:function(){return c.default.createElement(c.default.Fragment,null,c.default.createElement(f.default,{engine:this.props.engine}),c.default.createElement(h.default,{rootElement:this.props.rootElement}),c.default.createElement(m.default,null))}}]),n}(c.default.Component);g.propTypes={configuration:u.default.object.isRequired,rootElement:u.default.object.isRequired,engine:u.default.instanceOf(d.default).isRequired};var w=(0,p.connect)((function(e){return{configuration:e.configuration,destroyRequest:e.ui.destroyRequest}}))(g);n.default=w},{"./ui/common/PresenceChecker":24,"./ui/common/toasts/Toasts":87,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"engine/Engine":88,jquery:244,"prop-types":256,react:307,"react-dom":268,"react-redux":295,"ui/chat/Chat":2}],2:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=r(e("engine/Engine")),m=r(e("./classic/ClassicChat")),y=r(e("./sidebar/SidebarChat")),b=r(e("ui/common/alerts/Alerts")),v=r(e("ui/common/alerts/Confirms")),g=r(e("ui/common/incoming/Incoming")),w=r(e("ui/common/stream/LifeCycleManagement")),C=r(e("ui/common/session/UserSession")),_=r(e("ui/common/notifications/Notifications")),k=r(e("../common/logic/ChannelsManager")),S=r(e("utils/channels-storage")),E=r(e("jquery"));function T(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var O=function(e){(0,s.default)(n,e);var t=T(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleResize=r.handleResize.bind((0,a.default)(r)),r}
1return(0,o.default)(n,[{key:"componentDidMount",value:function(){window.addEventListener("resize",this.handleResize),this.handleResize(),this.props.engine.start()}},{key:"componentWillUnmount",value:function(){window.removeEventListener("resize",this.handleResize),this.props.engine.stop()}},{key:"handleResize",value:function(){var e=(0,E.default)(window).width(),t="Xl";e<380?t="XXs":e<576?t="Xs":e<768?t="Sm":e<992?t="Md":e<1200&&(t="Lg"),this.props.updateProperties({windowWidth:e,windowSizeClass:t,isMobile:["Xs","XXs"].includes(t)})}},{key:"componentDidUpdate",value:function(e){var t=this.props.user!==e.user&&this.props.user,n=this.props.auth!==e.auth&&this.props.auth;if(t&&(!e.user||e.user.id!==this.props.user.id)){var r=new S.default(this.props.user.cacheId);(this.props.configuration.disableChannelsRestore||r.isEmpty())&&1===this.props.configuration.mode&&this.props.configuration.interface.chat.fb.minimizeOnStart&&this.props.configuration.interface.browser.enabled&&this.props.configuration.interface.chat.fb.browserMinimizable&&this.props.minimizeChannels(["browser"]),this.props.restoreChannels(),this.props.completeInit()}n&&!this.props.user&&(new S.default("na").isEmpty()&&1===this.props.configuration.mode&&this.props.configuration.interface.chat.fb.minimizeOnStart&&this.props.minimizeChannels(["auth"]))}},{key:"render",value:function(){return u.default.createElement(u.default.Fragment,null,0===this.props.configuration.mode&&u.default.createElement(m.default,null),1===this.props.configuration.mode&&u.default.createElement(y.default,null),u.default.createElement(k.default,null),u.default.createElement(b.default,null),u.default.createElement(v.default,null),this.props.configuration.interface.incoming.enabled&&u.default.createElement(g.default,null),u.default.createElement(w.default,null),u.default.createElement(_.default,null),u.default.createElement(C.default,null))}}]),n}(u.default.Component);O.propTypes={configuration:p.default.object.isRequired,engine:p.default.instanceOf(h.default).isRequired};var P=(0,f.connect)((function(e){return{configuration:e.configuration,user:e.application.user,auth:e.application.auth,openedChannels:e.ui.openedChannels}}),{restoreChannels:d.restoreChannels,minimizeChannels:d.minimizeChannels,completeInit:d.completeInit,updateProperties:d.updateProperties})(O);n.default=P},{"../common/logic/ChannelsManager":76,"./classic/ClassicChat":3,"./sidebar/SidebarChat":14,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"engine/Engine":88,jquery:244,"prop-types":256,react:307,"react-redux":295,"ui/common/alerts/Alerts":25,"ui/common/alerts/Confirms":26,"ui/common/incoming/Incoming":73,"ui/common/notifications/Notifications":78,"ui/common/session/UserSession":83,"ui/common/stream/LifeCycleManagement":84,"utils/channels-storage":114}],3:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("./desktop/DesktopChat")),h=r(e("./mobile/MobileChat")),m=r(e("jquery")),y=r(e("ui/common/auth/Auth")),b=r(e("ui/common/loading/Loading")),v=r(e("ui/common/logger/Logger"));function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var w=function(e){(0,s.default)(n,e);var t=g(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={breakpointUpClassName:""},r.element=u.default.createRef(),r.handleResize=r.handleResize.bind((0,a.default)(r)),r}
1return(0,o.default)(n,[{key:"componentDidMount",value:function(){window.addEventListener("resize",this.handleResize),this.handleResize()}},{key:"componentWillUnmount",value:function(){window.removeEventListener("resize",this.handleResize)}},{key:"handleResize",value:function(){var e=(0,m.default)(this.element.current).closest(".wcContainer").width(),t="";t=e<380?"wcSizeXXs":e<576?"wcSizeXs":e<768?"wcSizeSm":e<992?"wcSizeMd":e<1200?"wcSizeLg":"wcSizeXl",this.state.breakpointUpClassName!==t&&this.setState({breakpointUpClassName:t})}},{key:"render",value:function(){var e=["wcSizeXXs","wcSizeXs"].includes(this.state.breakpointUpClassName);return!this.props.user&&!this.props.auth?u.default.createElement("div",{className:"wcClassic",ref:this.element},u.default.createElement(b.default,null),this.props.configuration.debug&&u.default.createElement(v.default,null)):u.default.createElement("div",{className:"wcClassic ".concat(this.state.breakpointUpClassName," ").concat(e?"wcMobile":"wcDesktop"),ref:this.element},this.props.user&&u.default.createElement(u.default.Fragment,null,e?u.default.createElement(h.default,null):u.default.createElement(d.default,null)),null===this.props.user&&this.props.auth&&u.default.createElement(y.default,null))}}]),n}(u.default.Component);w.propTypes={configuration:p.default.object.isRequired};var C=(0,f.connect)((function(e){return{configuration:e.configuration,user:e.application.user,auth:e.application.auth}}))(w);n.default=C},{"./desktop/DesktopChat":4,"./mobile/MobileChat":11,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,jquery:244,"prop-types":256,react:307,"react-redux":295,"ui/common/auth/Auth":28,"ui/common/loading/Loading":74,"ui/common/logger/Logger":75}],4:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("ui/common/browser/Browser")),d=r(e("ui/common/logger/Logger")),h=r(e("./TabbedController")),m=r(e("ui/common/customize/Cu
1stomize")),y=r(e("ui/common/recent/Recent")),b=r(e("./GridController"));function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var g=function(e){(0,a.default)(n,e);var t=v(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){var e=this.props.configuration.interface.browser.location;return c.default.createElement(c.default.Fragment,null,this.props.configuration.interface.chat.title.length>0&&c.default.createElement("div",{className:"wcTitle"},this.props.configuration.interface.chat.title,c.default.createElement(y.default,{keepInside:"#"+this.props.configuration.chatId})),c.default.createElement("div",{className:"wcBody "+("left"===e?"wcBrowserAreaLeft":"wcBrowserAreaRight")},c.default.createElement("div",{className:"wcMessagesArea"},"tabs"===this.props.configuration.interface.chat.classic.channelsView&&c.default.createElement(h.default,null),"grid"===this.props.configuration.interface.chat.classic.channelsView&&c.default.createElement(b.default,null),c.default.createElement(m.default,null)),this.props.configuration.interface.browser.enabled&&c.default.createElement("div",{className:"wcBrowserArea"},c.default.createElement(f.default,{infoWindowPosition:"left"===e?"right center":"left center"}))),this.props.configuration.debug&&c.default.createElement(d.default,null))}}]),n}(c.default.Component);g.propTypes={configuration:u.default.object.isRequired};var w=(0,p.connect)((function(e){return{configuration:e.configuration}}))(g);n.default=w},{"./GridController":5,"./TabbedController":6,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"ui/common/browser/Browser":32,"ui/common/customize/Cu
1stomize":70,"ui/common/logger/Logger":75,"ui/common/recent/Recent":81}],5:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("ui/common/channel/Channel")),h=e("actions/ui"),m=e("react-scrollbars-custom"),y=r(e("ui/common/channel/components/CloseButton")),b=r(e("../../../common/channel/components/streams/StreamStatus"));function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var g=function(e){(0,s.default)(n,e);var t=v(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={channelClicked:!1},r.scrollRef=u.default.createRef(),r.handleClick=r.handleClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleClick",value:function(e){var t=this;this.setState({channelClicked:!0},(function(){t.props.focusChannel(e)}))}},{key:"getOpenedChannels",value:function(){var e=this;return this.props.openedChannels.filter((function(t){return e.props.channels.find((function(n){return n.id===t&&(e.props.configuration.interface.chat.publicEnabled||"direct"===n.type)}))})).map((function(t){return e.props.channels.find((function(e){return e.id===t}))}))}},{key:"componentDidUpdate",value:function(e,t,n){if(e.focusedChannel!==this.props.focusedChannel)if(this.state.channelClicked)this.setState({channelClicked:!1});else{var r=this.getOpenedChannels().map((function(e){return e.id})),i=r.indexOf(this.props.focusedChannel);if(i>=0){var o=Math.min(r.length,this.props.configuration.interface.chat.classic.grid.cols),a=Math.floor(i/o);this.scrollRef.current.scrollTo(0,a*this.props.configuration.interface.chat.classic.grid.height)}}}},{key:"render",value:function(){var e=this,t=this.getOpenedChannels(),n="wcGridChannel"+Math.min(t.length,this.props.configuration.interface.chat.classic.grid.cols);return u.default.createElement(u.default.Fragment,null,u.default.createElement(m.Scrollbar,{ref:this.scrollRef,noScrollX:!0},u.default.createElement("div",{className:"wcGrid"},t.map((function(t){return u.default.createElement("div",{key:t.id,className:"wcGridChannelContainer ".concat(n)+(t.id===e.props.focusedChannel?" wcFocused":""),onClick:function(n){return e.handleClick(t.id)}},u.default.createElement("div",{className:"wcGridChannel"},u.default.createElement("div",{className:"wcHeader"},u.default.createElement("div",{className:"wcMain"},u.default.createElement("span",{className:"wcName"},t.name),u.default.createElement(b.default,{channel:t})),(e.props.publicChannels.length>1||"direct"===t.type)&&u.default.createElement(y.default,{channel:t,focusOnClose:!0})),u.default.createElement(d.default,{channel:t})))})),this.props.channels.length>0&&!t.find((function(t){return t.id===e.props.focusedChannel}))&&u.default.createElement("div",{className:"wcGridFull"},u.default.createElement("span",{className:"wcEmpty"},this.props.i18nBase.noChannels)))))}}]),n}(u.default.Component);g.propTypes={configuration:p.default.object.isRequired,channels:p.default.array.isRequired,publicChannels:p.default.array.isRequired};var w=(0,f.connect)((function(e){return{configuration:e.configuration,i18nBase:e.configuration.i18n,channels:e.application.channels,focusedChannel:e.ui.focusedChannel,openedChannels:e.ui.openedChannels,publicChannels:e.application.channels.filter((function(e){return"direct"!==e.type}))}}),{focusChannel:h.focusChannel})(g);n.default=w},{"../../../common/channel/components/streams/StreamStatus":45,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"ui/common/channel/Channel":38,"ui/common/channel/components/CloseButton":40}],6:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("ui/common/channel/Channel")),h=e("actions/ui"),m=r(e("jquery")),y=r(e("ui/common/channel/components/CloseButton")),b=r(e("../../../common/channel/components/streams/StreamStatus"));function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var g=function(e){(0,s.default)(n,e);var t=v(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={tooManyTabs:!1},r.tabsElement=u.default.createRef(),r.handleTabClick=r.handleTabClick.bind((0,a.default)(r)),r.handleTabsChange=r.handleTabsChange.bind((0,a.default)(r)),r.handleResize=r.handleResize.bind((0,a.default)(r)),r.handleNavigateLeft=r.handleNavigateLeft.bind((0,a.default)(r)),r.handleNavigateRight=r.handleNavigateRight.bind((0,a.default)(r)),r}
1return(0,o.default)(n,[{key:"componentDidMount",value:function(){window.addEventListener("resize",this.handleResize),this.handleTabsChange()}},{key:"componentWillUnmount",value:function(){window.removeEventListener("resize",this.handleResize)}},{key:"componentDidUpdate",value:function(e){this.props.openedChannels!==e.openedChannels&&this.handleTabsChange()}},{key:"handleResize",value:function(){this.handleTabsChange()}},{key:"handleTabClick",value:function(e,t){e.preventDefault(),this.props.focusChannel(t)}},{key:"handleTabsChange",value:function(){this.tabsElement.current&&(this.isOverflown(this.tabsElement.current)?this.state.tooManyTabs||this.setState({tooManyTabs:!0}):this.state.tooManyTabs&&this.setState({tooManyTabs:!1}))}},{key:"handleNavigateLeft",value:function(e){e.preventDefault();var t=(0,m.default)(this.tabsElement.current);t.scrollLeft()>0&&t.scrollLeft(t.scrollLeft()-20)}},{key:"handleNavigateRight",value:function(e){e.preventDefault();var t=(0,m.default)(this.tabsElement.current);t.scrollLeft(t.scrollLeft()+20)}},{key:"isOverflown",value:function(e){return e.scrollHeight>e.clientHeight||e.scrollWidth>e.clientWidth}},{key:"isTabNavigatorVisible",value:function(){var e=1===this.props.publicChannels.length;return!!this.props.configuration.interface.browser.enabled&&(!e||!this.props.configuration.interface.chat.publicEnabled||this.getOpenedChannels().length>1)}},{key:"getOpenedChannels",value:function(){var e=this;return this.props.openedChannels.filter((function(t){return e.props.channels.find((function(n){return n.id===t&&(e.props.configuration.interface.chat.publicEnabled||"direct"===n.type)}))})).map((function(t){return e.props.channels.find((function(e){return e.id===t}))}))}},{key:"render",value:function(){var e=this,t=this.getOpenedChannels();return u.default.createElement(u.default.Fragment,null,this.isTabNavigatorVisible()&&u.default.createElement("div",{className:"wcTabsContainer ".concat(this.state.tooManyTabs?"wcTabsTooMany":"")},u.default.createElement("div",{className:"wcTabs",ref:this.tabsElement},t.map((function(t){return u.default.createElement("div",{key:t.id,className:"wcTab"+(t.id===e.props.focusedChannel?"  wcCurrent":""),onClick:function(n){return e.handleTabClick(n,t.id)}},u.default.createElement("span",{className:"wcName"},t.name," ",e.props.channelsUi[t.id]&&e.props.channelsUi[t.id].unread>0?u.default.createElement("span",{className:"wcUnread"},"*"):""),u.default.createElement(b.default,{channel:t}),(e.props.publicChannels.length>1||"direct"===t.type)&&u.default.createElement(y.default,{channel:t,focusOnClose:!0}))}))),u.default.createElement("div",{className:"wcTabsNav"},u.default.createElement("a",{href:"#",onClick:function(t){return e.handleNavigateLeft(t)},className:"wcLeft wcFunctional"}),u.default.createElement("a",{href:"#",onClick:function(t){return e.handleNavigateRight(t)},className:"wcRight wcFunctional"}))),t.map((function(t){return u.default.createElement("div",{key:t.id,className:"wcTabContent"+(t.id!==e.props.focusedChannel?" wcInvisible":"")},u.default.createElement(d.default,{channel:t}))})),this.props.channels.length>0&&!t.find((function(t){return t.id===e.props.focusedChannel}))&&u.default.createElement("div",{className:"wcTabContent wcTabContentEmpty"},u.default.createElement("span",{className:"wcEmptyChannel"},this.props.i18nBase.noChannels)))}}]),n}(u.default.Component);g.propTypes={configuration:p.default.object.isRequired,publicChannels:p.default.array.isRequired,channels:p.default.array.isRequired};var w=(0,f.connect)((function(e){return{configuration:e.configuration,i18nBase:e.configuration.i18n,publicChannels:e.application.channels.filter((function(e){return"direct"!==e.type})),channels:e.application.channels,focusedChannel:e.ui.focusedChannel,openedChannels:e.ui.openedChannels,channelsUi:e.ui.channels}}),{focusChannel:h.focusChannel})(g);n.default=w},{"../../../common/channel/components/streams/StreamStatus":45,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,jquery:244,"prop-types":256,react:307,"react-redux":295,"ui/common/channel/Channel":38,"ui/common/channel/components/CloseButton":40}],7:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("ui/common/channel/Channel"));function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var h=function(e){(0,a.default)(n,e);var t=d(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){var e=this,t=this.props.channels.filter((function(t){return e.props.openedChannels.includes(t.id)}));return c.default.createElement(c.default.Fragment,null,t.map((function(t){return c.default.createElement("div",{key:t.id,className:"wcChannelContainer"+(t.id!==e.props.focusedChannel?" wcInvisible":"")},c.default.createElement(f.default,{channel:t}))})),this.props.channels.length>0&&!t.find((function(t){return t.id===e.props.focusedChannel}))&&c.default.createElement("div",{className:"wcChannelContainer wcChannelContainerEmpty"},c.default.createElement("span",{className:"wcEmptyChannel"},this.props.i18nBase.noChannels)))}}]),n}(c.default.Component);h.propTypes={configuration:u.default.object.isRequired};var m=(0,p.connect)((function(e){return{configuration:e.configuration,i18nBase:e.configuration.i18n,channels:e.application.channels,focusedChannel:e.ui.focusedChannel,openedChannels:e.ui.openedChannels}}))(h);n.default=m},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"ui/common/channel/Channel":38}],8:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("react-scrollbars-custom"),h=e("actions/ui"),m=r(e("components/ui/common/channel/manage/ChannelAdd")),y=r(e("components/ui/common/channel/browse/ChannelsBrowse")),b=r(e("components/ui/common/channel/manage/ChannelEdit")),v=r(e("components/ui/common/channel/manage/ChannelRemove"));function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var w=function(e){(0,s.default)(n,e);var t=g(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleChannelClick=r.handleChannelClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleChannelClick",value:function(e){e.locked||(this.props.openChannel(e.id),this.props.focusChannel(e.id),this.props.setMobileTopTab("channel"),this.props.setMobileTitle(e.name))}},{key:"getPublicChannelClasses",value:function(e){var t=["wcChannelEntry"];return!0===e.protected&&!1===e.authorized&&t.push("wcLockedChannel"),!0===e.protected&&!0===e.authorized&&t.push("wcUnLockedChannel"),t.join(" ")}},{key:"render",value:function(){var e=this;return u.default.createElement(d.Scrollbar,null,u.default.createElement("div",{className:"wcPadding2 wcMarginBottom1"},u.default.createElement(m.default,{label:!0,className:"wcMarginRight2"}),u.default.createElement(y.default,{label:!0})),this.props.publicChannels.map((function(t){return u.default.createElement("div",{key:t.id,className:e.getPublicChannelClasses(t),onClick:function(n){return e.handleChannelClick(t)}},u.default.createElement("div",{className:"wcDetails"},u.default.createElement("img",{src:t.avatar?t.avatar:"",className:"wcFunctional wcChannelAvatar",alt:t.name}),u.default.createElement("span",{className:"wcName"},t.name)),u.default.createElement("div",{className:"wcButtons"},u.default.createElement(b.default,{channel:t}),u.default.createElement(v.default,{channel:t})))})))}}]),n}(u.default.Component);w.propTypes={configuration:p.default.object.isRequired};var C=(0,f.connect)((function(e){return{configuration:e.configuration,publicChannels:e.application.channels.filter((function(e){return"direct"!==e.type}))}}),{focusChannel:h.focusChannel,openChannel:h.openChannel,setMobileTopTab:h.setMobileTopTab,setMobileTitle:h.setMobileTitle})(w);n.default=C},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"components/ui/common/channel/browse/ChannelsBrowse"
1:39,"components/ui/common/channel/manage/ChannelAdd":53,"components/ui/common/channel/manage/ChannelEdit":54,"components/ui/common/channel/manage/ChannelRemove":55,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304}],9:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=e("react-scrollbars-custom"),m=r(e("ui/common/channel/components/CloseButton")),y=r(e("../../../common/channel/components/streams/StreamStatus"));function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var v=function(e){(0,s.default)(n,e);var t=b(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleChannelClick=r.handleChannelClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleChannelClick",value:function(e){this.props.focusChannel(e.id),this.props.setMobileTopTab("channel"),this.props.setMobileTitle(e.name)}},{key:"render",value:function(){var e=this,t=this.props.channels.filter((function(t){return e.props.openedChannels.includes(t.id)}));return 0===t.length?u.default.createElement("div",{className:"wcCenter"},u.default.createElement("span",{className:"wcNoChats"},this.props.i18nBase.noChats)):u.default.createElement(h.Scrollbar,null,t.map((function(t){return u.default.createElement("div",{key:t.id,className:"wcChannelEntry",onClick:function(n){return e.handleChannelClick(t)}},u.default.createElement("div",{className:"wcDetails"},t.avatar&&u.default.createElement("img",{src:t.avatar,className:"wcFunctional wcChannelAvatar",alt:t.name}),u.default.createElement("span",{className:"wcName"},t.name," ",e.props.channelsUi[t.id]&&e.props.channelsUi[t.id].unread>0?u.default.createElement("span",{className:"wcUnread"},"*"):""),u.default.createElement(y.default,{channel:t})),(e.props.publicChannels.length>0||"direct"===t.type)&&u.default.createElement(m.default,{channel:t}))})))}}]),n}(u.default.Component);v.propTypes={configuration:p.default.object.isRequired};var g=(0,f.connect)((function(e){return{configuration:e.configuration,i18nBase:e.configuration.i18n,publicChannels:e.application.channels.filter((function(e){return"direct"!==e.type})),channels:e.application.channels,openedChannels:e.ui.openedChannels,channelsUi:e.ui.channels}}),{focusChannel:d.focusChannel,setMobileTopTab:d.setMobileTopTab,setMobileTitle:d.setMobileTitle})(v);n.default=g},{"../../../common/channel/components/streams/StreamStatus":45,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"ui/common/channel/components/CloseButton":40}],10:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("components/ui/common/customize/Cu
1stomizeArea"));function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var h=function(e){(0,a.default)(n,e);var t=d(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement("div",{className:"wcCustomizations"},c.default.createElement(f.default,{visible:this.props.visible}))}}]),n}(c.default.Component);h.propTypes={configuration:u.default.object.isRequired,visible:u.default.bool};var m=(0,p.connect)((function(e){return{configuration:e.configuration}}))(h);n.default=m},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"components/ui/common/customize/Cu
1stomizeArea":71,"prop-types":256,react:307,"react-redux":295}],11:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=r(e("ui/common/logger/Logger")),m=r(e("./ChatsView")),y=r(e("./ChannelsView")),b=r(e("./UsersView")),v=r(e("./RecentView")),g=e("utils/string"),w=r(e("./ChannelView")),C=r(e("./CustomizeView"));function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var k=function(e){(0,s.default)(n,e);var t=_(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleTabClick=r.handleTabClick.bind((0,a.default)(r)),r.showFocusedChannel(),!r.props.configuration.interface.chat.publicEnabled&&r.isUsersTabVisible()&&r.props.setMobileTopTab("users"),r}return(0,o.default)(n,[{key:"handleTabClick",value:function(e){this.props.setMobileTopTab(e.slug),this.props.setMobileTitle(e.name),this.props.focusChannel(void 0)}},{key:"componentDidUpdate",value:function(e){this.props.focusedChannel!==e.focusedChannel&&this.props.focusedChannel&&this.showFocusedChannel()}},{key:"showFocusedChannel",value:function(){var e=this,t=this.props.channels.find((function(t){return t.id===e.props.focusedChannel}));t&&(this.props.setMobileTopTab("channel"),this.props.setMobileTitle(t.name))}},{key:"isUsersTabVisible",value:function(){return this.props.configuration.interface.browser.enabled}},{key:"render",value:function(){var e=this,t=[{slug:"chats",name:this.props.i18nBase.chats,component:u.default.createElement(m.default,null),header:this.props.configuration.interface.chat.mobile.tabs.chats},{slug:"channels",name:this.props.i18nBase.channels,component:u.default.createElement(y.default,null),header:this.props.configuration.interface.chat.publicEnabled},{slug:"users",name:this.props.i18nBase.users,component:u.default.createElement(b.default,null),header:this.isUsersTabVisible()},{slug:"channel",name:this.props.i18nBase.channel,component:u.default.createElement(w.default,null),header:!1}];return this.props.configuration.interface.recent.enabled&&t.push({slug:"recent",name:this.props.i18nBase.recent,component:u.default.createElement(v.default,null),header:!0,redCounter:this.props.recentChats.filter((function(e){return!1===e.read})).length+this.props.userFeed.filter((function(e){return!1===e.seen})).length}),this.props.user&&this.props.user.settings.allowCustomize&&t.push({slug:"customize",name:"",component:u.default.createElement(C.default,{visible:"customize"===this.props.topTab}),header:!0}),u.default.createElement(u.default.Fragment,null,this.props.titleVisible&&(this.props.titleOverride||this.props.configuration.interface.chat.title)&&u.default.createElement("div",{className:"wcTitle"},[this.props.configuration.interface.chat.title,this.props.titleOverride].filter((function(e){return e&&e.length})).join(" - ")),u.default.createElement("div",{className:"wcTabs"+(t.filter((function(e){return e.header})).length>3?" wcTabsCompact":"")},t.filter((function(e){return e.header})).map((function(t,n){return u.default.createElement("div",{key:n,className:"wcTab wcTab"+(0,g.capitalizeFirstLetter)(t.slug)+(e.props.topTab===t.slug?" wcCurrent":""),onClick:function(n){return e.handleTabClick(t)}},u.default.createElement("span",{className:"wcName"},t.name),t.redCounter>0&&u.default.createElement("span",{className:"wcRedCounter"},t.redCounter))}))),t.map((function(t,n){return u.default.createElement("div",{key:n,className:"wcTabContent wcTabContent"+(0,g.capitalizeFirstLetter)(t.slug)+(e.props.topTab!==t.slug?" wcInvisible":"")},t.component)})),this.props.configuration.debug&&u.default.createElement(h.default,null))}}]),n}(u.default.Component);k.propTypes={configuration:p.default.object.isRequired,titleVisible:p.default.bool.isRequired},k.defaultProps={titleVisible:!0};var S=(0,f.connect)((function(e){return{i18nBase:e.configuration.i18n,configuration:e.configuration,topTab:e.ui.mobile.topTab,titleOverride:e.ui.mobile.title,channels:e.application.channels,focusedChannel:e.ui.focusedChannel,openedChannels:e.ui.openedChannels,user:e.application.user,recentChats:e.application.recentChats,userFeed:e.application.userFeed,publicChannels:e.application.channels.filter((function(e){return"direct"!==e.type}))}}),{setMobileTopTab:d.setMobileTopTab,setMobileTitle:d.setMobileTitle,focusChannel:d.focusChannel,openChannel:d.openChannel})(k);n.default=S},{"./ChannelView":7,"./ChannelsView":8,"./ChatsView":9,"./CustomizeView":10,"./RecentView":12,"./UsersView":13,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"ui/common/logger/Logger":75,"utils/string":122}],12:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=r(e("components/ui/common/recent/RecentArea"));function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleChannelClick=r.handleChannelClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleChannelClick",value:function(e){this.props.setMobileTopTab("channel"),this.props.setMobileTitle(e.name)}
1},{key:"render",value:function(){var e=this;return u.default.createElement(h.default,{onClick:function(t){return e.handleChannelClick(t.channel)}})}}]),n}(u.default.Component);y.propTypes={configuration:p.default.object.isRequired};var b=(0,f.connect)((function(e){return{configuration:e.configuration}}),{setMobileTopTab:d.setMobileTopTab,setMobileTitle:d.setMobileTitle})(y);n.default=b},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"components/ui/common/recent/RecentArea":82,"prop-types":256,react:307,"react-redux":295}],13:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("react-scrollbars-custom"),h=r(e("components/ui/common/browser/components/DirectChannel")),m=e("actions/ui");function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var b=function(e){(0,s.default)(n,e);var t=y(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={searchPhrase:""},r.handleSearchClear=r.handleSearchClear.bind((0,a.default)(r)),r.handleChannelClick=r.handleChannelClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleSearchClear",value:function(e){e.preventDefault(),this.setState({searchPhrase:""})}},{key:"handleChannelClick",value:function(e){this.props.setMobileTopTab("channel"),this.props.setMobileTitle(e.name)}},{key:"render",value:function(){var e=this;return u.default.createElement("div",{className:"wcBrowser"},u.default.createElement("div",{className:"wcChannels wcDirectChannels"},u.default.createElement(d.Scrollbar,null,this.props.directChannels.filter((function(t){return!e.state.searchPhrase||t.name.match(new RegExp(e.state.searchPhrase,"i"))})).map((function(t,n){return u.default.createElement(h.default,{key:t.id,channel:t,onClick:e.handleChannelClick})})))),this.props.configuration.interface.browser.searchSubChannels&&u.default.createElement("div",{className:"wcFooter"},u.default.createElement("div",{className:"wcSearch"},u.default.createElement("input",{type:"text",className:"wcControl",placeholder:this.props.i18n.subChannelsSearchHint,value:this.state.searchPhrase,onChange:function(t){return e.setState({searchPhrase:t.target.value})}}),this.state.searchPhrase&&u.default.createElement("a",{href:"#",className:"wcClear wcFunctional",onClick:this.handleSearchClear}))))}}]),n}(u.default.Component);b.propTypes={configuration:p.default.object.isRequired};var v=(0,f.connect)((function(e){return{configuration:e.configuration,directChannels:e.application.channels.filter((function(e){return"direct"===e.type})),i18n:e.application.i18n,focusedChannel:e.ui.focusedChannel}}),{setMobileTitle:m.setMobileTitle,setMobileTopTab:m.setMobileTopTab})(b);n.default=v},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"components/ui/common/browser/components/DirectChannel":36,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304}],14:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("./mobile/MobileChat")),d=r(e("./desktop/DesktopChat")),h=r(e("./desktop/LoadingColumn")),m=r(e("./desktop/AuthColumn"));function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var b=function(e){(0,a.default)(n,e);var t=y(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return!this.props.user&&!this.props.auth?c.default.createElement("div",{className:"wcSidebar wcSize".concat(this.props.windowSizeClass," ").concat(this.props.isMobile?"wcMobile":"wcDesktop")},c.default.createElement(h.default,null)):c.default.createElement("div",{className:"wcSidebar wcSize".concat(this.props.windowSizeClass," ").concat(this.props.isMobile?"wcMobile":"wcDesktop")},this.props.user&&this.props.initiated&&c.default.createElement(c.default.Fragment,null,this.props.isMobile?c.default.createElement(f.default,null):c.default.createElement(d.default,null)),null===this.props.user&&this.props.auth&&c.default.createElement(m.default,null))}}]),n}(c.default.Component);b.propTypes={configuration:u.default.object.isRequired};var v=(0,p.connect)((function(e){return{configuration:e.configuration,user:e.application.user,auth:e.application.auth,initiated:e.ui.initiated,windowSizeClass:e.ui.properties.windowSizeClass,isMobile:e.ui.properties.isMobile}}))(b);n.default=v},{"./desktop/AuthColumn":17,"./desktop/DesktopChat":18,"./desktop/LoadingColumn":19,"./mobile/MobileChat":22,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],15:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("./ColumnHeader")),h=e("actions/ui");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).isMinimized=r.isMinimized.bind((0,a.default)(r)),r.handleMinimizeToggle=r.handleMinimizeToggle.bind((0,a.default)(r)),r.handleClick=r.handleClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"isMinimized",value:function(){return!!this.props.minimizable&&this.props.minimizedChannels.includes(this.props.id)}},{key:"handleMinimizeToggle",value:function(){this.isMinimized()?this.props.maximizeChannel(this.props.id):this.props.minimizeChannel(this.props.id)}},{key:"handleClick",value:function(){this.props.minimizable&&this.handleMinimizeToggle()}},{key:"render",value:function(){return u.default.createElement("div",{className:"wcColumn"+(this.props.className?" "+this.props.className:""),onClick:this.props.onClick?this.props.onClick:function(e){}},u.default.createElement(d.default,{id:this.props.id,text:this.props.title,minimizable:this.props.minimizable,minimized:this.isMinimized(),onMaximize:this.handleMinimizeToggle,onMinimize:this.handleMinimizeToggle,onClick:this.handleClick,closeButton:this.props.closeButton,closable:this.props.closable,unread:this.props.unread,unreadNumber:this.props.unreadNumber,contentElements:this.props.headerContentElements},this.props.headerElement),u.default.createElement("div",{className:"wcContent"+(this.props.contentClassName?" "+this.props.contentClassName:"")+(this.isMinimized()?" wcInvisible":""),style:{backgroundColor:this.props.configuration.defaultBackgroun
1dColor}},this.props.children))}}]),n}(u.default.Component);y.defaultProps={closable:!1,unread:!1,minimizable:!0,headerContentElements:[]},y.propTypes={id:p.default.string.isRequired,title:p.default.string.isRequired,className:p.default.string,contentClassName:p.default.string,configuration:p.default.object.isRequired,headerElement:p.default.object,onClick:p.default.func,closeButton:p.default.object,closable:p.default.bool,unread:p.default.bool,unreadNumber:p.default.number,minimizable:p.default.bool,headerContentElements:p.default.array.isRequired};var b=(0,f.connect)((function(e){return{configuration:e.configuration,minimizedChannels:e.ui.minimizedChannels}}),{minimizeChannel:h.minimizeChannel,maximizeChannel:h.maximizeChannel})(y);n.default=b},{"./ColumnHeader":16,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],16:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux");function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var h=function(e){(0,s.default)(n,e);var t=d(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleClick=r.handleClick.bind((0,a.default)(r)),r.handleMinimizeClick=r.handleMinimizeClick.bind((0,a.default)(r)),r.handleMaximizeClick=r.handleMaximizeClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleClick",value:function(e){e.preventDefault(),this.props.onClick&&this.props.onClick(this.props.id)}},{key:"handleMinimizeClick",value:function(e){e.preventDefault(),e.stopPropagation(),this.props.onMinimize&&this.props.onMinimize(this.props.id)}},{key:"handleMaximizeClick",value:function(e){e.preventDefault(),e.stopPropagation(),this.props.onMaximize&&this.props.onMaximize(this.props.id)}},{key:"render",value:function(){return u.default.createElement("div",{className:"wcHeader",style:{backgroundColor:this.props.configuration.defaultBackgroundColor},onClick:this.handleClick},u.default.createElement("div",{className:"wcContent"},u.default.createElement("span",null,this.props.text," ",this.props.unread?u.default.createElement("span",{className:"wcUnread"},"*"):""),this.props.unreadNumber>0&&u.default.createElement("span",{className:"wcRedCounter"},this.props.unreadNumber),this.props.contentElements),u.default.createElement("div",{className:"wcButtons"},this.props.children,this.props.minimizable&&u.default.createElement(u.default.Fragment,null,this.props.minimized?u.default.createElement("a",{href:"#",className:"wcFunctional wcMaximize",onClick:this.handleMaximizeClick,title:this.props.i18n.maximize}):u.default.createElement("a",{href:"#",className:"wcFunctional wcMinimize",onClick:this.handleMinimizeClick,title:this.props.i18n.minimize})),this.props.closable&&this.props.closeButton))}}]),n}(u.default.Component);h.defaultProps={contentElements:[],closable:!1,minimizable:!0},h.propTypes={configuration:p.default.object.isRequired,closable:p.default.bool.isRequired,minimizable:p.default.bool.isRequired,minimized:p.default.bool.isRequired,onClick:p.default.func,onMinimize:p.default.func,onMaximize:p.default.func,closeButton:p.default.object,id:p.default.string.isRequired,text:p.default.string.isRequired,unreadNumber:p.default.number,contentElements:p.default.array.isRequired};var m=(0,f.connect)((function(e){return{configuration:e.configuration,i18n:e.application.i18n}}))(h);n.default=m},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],17:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("ui/common/auth/Auth")),d=r(e("../components/Column"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var m=function(e){(0,a.default)(n,e);var t=h(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement(d.default,{id:"auth",contentClassName:"wcAuthContent",title:this.props.configuration.interface.chat.title},c.default.createElement(f.default,{titleVisible:!1}))}}]),n}(c.default.Component);m.propTypes={configuration:u.default.object.isRequired};var y=(0,p.connect)((function(e){return{configuration:e.configuration}}))(m);
1n.default=y},{"../components/Column":15,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"ui/common/auth/Auth":28}],18:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("ui/common/browser/Browser")),d=r(e("./WindowsController")),h=r(e("ui/common/customize/Customize")),m=r(e("ui/common/recent/Recent")),y=r(e("ui/common/logger/Logger")),b=r(e("../components/Column"));function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var g=function(e){(0,a.default)(n,e);var t=v(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement(c.default.Fragment,null,this.props.configuration.debug&&c.default.createElement("div",{className:"wcColumn"},c.default.createElement(y.default,null)),c.default.createElement(d.default,null),this.props.configuration.interface.browser.enabled&&c.default.createElement(b.default,{id:"browser",title:this.props.i18nBase.usersAndChannels,className:"wcBrowserColumn",contentClassName:"wcBrowserContent",headerElement:c.default.createElement(m.default,null),minimizable:this.props.configuration.interface.chat.fb.browserMinimizable},c.default.createElement(f.default,{keepInside:".wcSidebar",infoWindowPosition:"left"===this.props.configuration.interface.chat.fb.location?"right center":"left center"}),c.default.createElement(h.default,null)))}}]),n}(c.default.Component);g.propTypes={configuration:u.default.object.isRequired};var w=(0,p.connect)((function(e){return{configuration:e.configuration,i18nBase:e.configuration.i18n}}))(g);n.default=w},{"../components/Column":15,"./WindowsController":21,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"ui/common/browser/Browser":32,"ui/common/customize/Cu
1stomize":70,"ui/common/logger/Logger":75,"ui/common/recent/Recent":81}],19:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("ui/common/logger/Logger")),d=r(e("ui/common/loading/Loading")),h=r(e("../components/Column"));function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var y=function(e){(0,a.default)(n,e);var t=m(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement(h.default,{id:"loading",title:this.props.configuration.interface.chat.title},c.default.createElement(d.default,{titleVisible:!1}),this.props.configuration.debug&&c.default.createElement(f.default,null))}}]),n}(c.default.Component);y.propTypes={configuration:u.default.object.isRequired};var b=(0,p.connect)((function(e){return{configuration:e.configuration}}))(y);n.default=b},{"../components/Column":15,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"ui/common/loading/Loading":74,"ui/common/logger/Logger":75}],20:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("../components/Column")),h=e("actions/ui");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleCloseClick=r.handleCloseClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleCloseClick",value:function(){this.props.configuration.interface.channel.logOffOnCloseLast&&this.props.logOff(),this.props.configuration.interface.channel.destroyOnCloseLast&&this.props.destroy()}},{key:"render",value:function(){return u.default.createElement(d.default,{key:"noChannel",id:"noChannel",title:this.props.configuration.interface.chat.title,className:"wcFocused",closeButton:u.default.createElement("a",{href:"#",onClick:this.handleCloseClick,title:this.props.i18n.close,className:"wcFunctional wcClose"}),closable:!0},u.default.createElement("div",{className:"wcTabContent wcTabContentEmpty"},u.default.createElement("span",{className:"wcEmptyChannel"},this.props.i18nBase.noChannels)))}}]),n}(u.default.Component);y.propTypes={configuration:p.default.object.isRequired};var b=(0,f.connect)((function(e){return{configuration:e.configuration,i18nBase:e.configuration.i18n,i18n:e.application.i18n}}),{logOff:h.logOff,destroy:h.destroy})(y);n.default=b},{"../components/Column":15,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],21:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("ui/common/channel/Channel")),h=e("actions/ui"),m=r(e("ui/common/customize/Cu
1stomize")),y=r(e("../components/Column")),b=r(e("./NoChannelColumn")),v=r(e("ui/common/channel/components/CloseButton")),g=r(e("ui/common/channel/components/streams/StreamStatus"));function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var C=function(e){(0,s.default)(n,e);var t=w(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleWindowClick=r.handleWindowClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleWindowClick",value:function(e){this.props.focusChannel(e.id)}},{key:"getOpenedChannels",value:function(){var e=this;return this.props.openedChannels.filter((function(t){return e.props.channels.find((function(n){return n.id===t&&(e.props.configuration.interface.chat.publicEnabled||"direct"===n.type)}))})).map((function(t){return e.props.channels.find((function(e){return e.id===t}))}))}},{key:"render",value:function(){var e=this,t=this.getOpenedChannels();return u.default.createElement(u.default.Fragment,null,t.map((function(t,n){return u.default.createElement(y.default,{key:n,id:t.id,title:e.props.configuration.interface.channel.direct.title?e.props.configuration.interface.channel.direct.title:t.name,className:t.id===e.props.focusedChannel?" wcFocused":"",unread:e.props.channelsUi[t.id]&&e.props.channelsUi[t.id].unread>0,closable:e.props.publicChannels.length>1||"direct"===t.type,closeButton:u.default.createElement(v.default,{channel:t,focusOnClose:!0,className:"wcFunctional wcClose"}),onClick:function(n){return e.handleWindowClick(t)},contentClassName:"wcChannelContent",headerContentElements:[u.default.createElement(g.default,{key:t.id,channel:t})]},u.default.createElement(d.default,{channel:t,className:e.props.minimizedChannels.includes(t.id)?"wcInvisible":void 0}),!e.props.configuration.interface.browser.enabled&&0===n&&!e.props.minimizedChannels.includes(t.id)&&u.default.createElement(m.default,null))})),0===t.length&&!this.props.configuration.interface.browser.enabled&&u.default.createElement(b.default,null))}}]),n}(u.default.Component);C.propTypes={configuration:p.default.object.isRequired};var _=(0,f.connect)((function(e){return{i18n:e.application.i18n,i18nBase:e.configuration.i18n,configuration:e.configuration,publicChannels:e.application.channels.filter((function(e){return"direct"!==e.type})),channels:e.application.channels,focusedChannel:e.ui.focusedChannel,openedChannels:e.ui.openedChannels,minimizedChannels:e.ui.minimizedChannels,channelsUi:e.ui.channels}}),{focusChannel:h.focusChannel})(C);n.default=_},{"../components/Column":15,"./NoChannelColumn":20,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"ui/common/channel/Channel":38,"ui/common/channel/components/CloseButton":40,"ui/common/channel/components/streams/StreamStatus":45,"ui/common/customize/Cu
1stomize":70}],22:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("ui/chat/classic/mobile/MobileChat")),d=r(e("../components/Column"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var m=function(e){(0,a.default)(n,e);var t=h(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement(d.default,{id:"browser",title:[this.props.configuration.interface.chat.title,this.props.titleOverride].filter((function(e){return e&&e.length})).join(" - "),contentClassName:"wcMobileContainer",unreadNumber:this.props.recentChats.filter((function(e){return!1===e.read})).length+this.props.userFeed.filter((function(e){return!1===e.seen})).length},c.default.createElement(f.default,{visible:!0,titleVisible:!1}))}}]),n}(c.default.Component);m.propTypes={configuration:u.default.object.isRequired};var y=(0,p.connect)((function(e){return{configuration:e.configuration,titleOverride:e.ui.mobile.title,recentChats:e.application.recentChats,userFeed:e.application.userFeed}}))(m);n.default=y},{"../components/Column":15,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"ui/chat/classic/mobile/MobileChat":11}],23:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types"));function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var f=function(e){(0,a.default)(n,e);var t=p(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement("div",{className:"wcLoaderContainer"+(this.props.center?" wcLoaderContainerCenter":""),style:{marginTop:this.props.marginTop?this.props.marginTop:void 0,marginBottom:this.props.marginBottom?this.props.marginBottom:void 0}},c.default.createElement("div",{className:"wcLoader "+this.props.className},c.default.createElement("div",null),c.default.createElement("div",null),c.default.createElement("div",null),c.default.createElement("div",null)),this.props.message&&c.default.createElement("div",{className:"wcLoaderText"},this.props.message))}}]),n}(c.default.Component);f.propTypes={className:u.default.string,message:u.default.string,center:u.default.bool,marginTop:u.default.number,marginBottom:u.default.number};var d=f;n.default=d},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307}],24:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("actions/ui"),d=r(e("jquery")),h=e("react-redux");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={domPresent:!0},r.domCheck=r.domCheck.bind((0,a.default)(r)),r}
1return(0,o.default)(n,[{key:"componentDidMount",value:function(){this.interval=setInterval(this.domCheck,1e3)}},{key:"componentWillUnmount",value:function(){this.interval&&clearInterval(this.interval)}},{key:"domCheck",value:function(){d.default.contains(document,this.props.rootElement)?!1===this.state.domPresent&&this.setState({domPresent:!0}):!0===this.state.domPresent&&(this.setState({domPresent:!1}),this.props.destroy())}},{key:"render",value:function(){return null}}]),n}(u.default.Component);y.propTypes={rootElement:p.default.object.isRequired};var b=(0,h.connect)((function(e){return{}}),{destroy:f.destroy})(y);n.default=b},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,jquery:244,"prop-types":256,react:307,"react-redux":295}],25:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=e("react-redux"),f=e("actions/ui"),d=r(e("../modal/Modal"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var m=function(e){(0,s.default)(n,e);var t=h(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={type:"Info",popupOpen:!1,title:"",text:""},r.close=r.close.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.error!==e.error&&this.props.error,n=this.props.info!==e.info&&this.props.info;t&&(this.setState({type:"Error",popupOpen:!0,title:this.props.i18n.error,text:this.props.error}),this.props.clearAlerts()),n&&(this.setState({type:"Info",popupOpen:!0,title:this.props.i18n.information,text:this.props.info}),this.props.clearAlerts())}},{key:"close",value:function(){this.setState({popupOpen:!1,title:"",text:""})}},{key:"render",value:function(){return u.default.createElement(d.default,{title:this.state.title,open:this.state.popupOpen,onClose:this.close,closeButtonLabel:this.props.i18n.ok,size:"sm"},this.state.text)}}]),n}(u.default.Component),y=(0,p.connect)((function(e){return{error:e.ui.alerts.error,info:e.ui.alerts.info,i18n:e.application.i18n}}),{clearAlerts:f.clearAlerts})(m);n.default=y},{"../modal/Modal":77,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,react:307,"react-redux":295}],26:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=e("react-redux"),f=(r(e("reactjs-popup")),e("actions/ui")),d=r(e("../modal/Modal"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var m=function(e){(0,s.default)(n,e);var t=h(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={popupOpen:!1},r.handleCancel=r.handleCancel.bind((0,a.default)(r)),r.handleConfirm=r.handleConfirm.bind((0,a.default)(r)),r.handleCustomButton=r.handleCustomButton.bind((0,a.default)(r)),r}
1return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this;this.props.confirms!==e.confirms&&this.props.confirms&&(this.setState({popupOpen:!0}),this.props.confirms.configuration.timeout&&(this.closeTimer=setTimeout((function(){t.handleCancel()}),1e3*this.props.confirms.configuration.timeout)))}},{key:"componentWillUnmount",value:function(){this.clearCloseTimer()}},{key:"close",value:function(){this.setState({popupOpen:!1}),this.props.clearConfirm(),this.clearCloseTimer()}},{key:"clearCloseTimer",value:function(){this.closeTimer&&(clearTimeout(this.closeTimer),delete this.closeTimer)}},{key:"handleCancel",value:function(){this.close(),this.props.confirms&&this.props.confirms.cancelCallback&&this.props.confirms.cancelCallback()}},{key:"handleConfirm",value:function(){this.close(),this.props.confirms.callback&&this.props.confirms.callback()}},{key:"handleCustomButton",value:function(e,t){e.preventDefault(),this.close(),t.callback&&t.callback()}},{key:"render",value:function(){var e,t,n,r,i=this;if(!this.props.confirms)return null;var o,a,s,l,c,p,f=[];(null===(e=this.props.confirms.configuration)||void 0===e||null===(t=e.buttonNo)||void 0===t?void 0:t.hidden)||f.push(u.default.createElement("button",{key:"no",className:"wcButton wcNoButton",onClick:this.handleCancel},null!==(o=null===(a=this.props.confirms.configuration)||void 0===a||null===(s=a.buttonNo)||void 0===s?void 0:s.text)&&void 0!==o?o:this.props.i18n.no));(null===(n=this.props.confirms.configuration)||void 0===n||null===(r=n.buttonYes)||void 0===r?void 0:r.hidden)||f.push(u.default.createElement("button",{key:"yes",className:"wcButton wcYesButton",onClick:this.handleConfirm},null!==(l=null===(c=this.props.confirms.configuration)||void 0===c||null===(p=c.buttonYes)||void 0===p?void 0:p.text)&&void 0!==l?l:this.props.i18n.yes));return this.props.confirms.buttons&&this.props.confirms.buttons.map((function(e,t){var n,r;"link"===e.type?f.push(u.default.createElement("a",{key:t,href:"#",className:"wcButton "+(null!==(n=e.className)&&void 0!==n?n:""),onClick:function(t){return i.handleCustomButton(t,e)}},e.text)):f.push(u.default.createElement("button",{key:t,className:"wcButton "+(null!==(r=e.className)&&void 0!==r?r:""),onClick:function(t){return i.handleCustomButton(t,e)}},e.text))})),u.default.createElement(d.default,{className:this.props.confirms.configuration.className,open:this.state.popupOpen,closeOnDocumentClick:!0,onClose:this.handleCancel,title:this.props.confirms.configuration.title?this.props.confirms.configuration.title:this.props.i18n.confirmation,footer:f,footerCloseButtonVisible:!1},this.props.confirms.text,this.props.confirms.configuration.sound&&u.default.createElement("audio",{loop:!0,autoPlay:!0,preload:"auto"},u.default.createElement("source",{src:this.props.confirms.configuration.sound.src,type:"audio/ogg"})))}}]),n}(u.default.Component),y=(0,p.connect)((function(e){return{confirms:e.ui.confirms,i18n:e.application.i18n,configuration:e.configuration}}),{clearConfirm:f.clearConfirm})(m);n.default=y},{"../modal/Modal":77,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,react:307,"react-redux":295,"reactjs-popup":308}],27:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("../plain/Decorator"));function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var h=function(e){(0,a.default)(n,e);var t=d(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement("div",{className:"wcErrorBox wcAccessDenied"},c.default.createElement(f.default,null,this.props.auth.error))}}]),n}(c.default.Component);h.propTypes={configuration:u.default.object.isRequired};var m=(0,p.connect)((function(e){return{configuration:e.configuration,auth:e.application.auth}}))(h);n.default=m},{"../plain/Decorator":79,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],28:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("./AccessDenied")),d=r(e("./AuthUserName")),h=r(e("./AuthExternal"));function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var y=function(e){(0,a.default)(n,e);var t=m(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement("div",{className:"wcAuthContainer",style:{backgroundColor:this.props.configuration.defaultBackgroun
1dColor}},this.props.titleVisible&&this.props.configuration.interface.chat.title&&c.default.createElement("div",{className:"wcTitle"},this.props.configuration.interface.chat.title),c.default.createElement("div",{className:"wcAuth"},"access-denied"===this.props.auth.mode&&c.default.createElement(f.default,null),"auth-username"===this.props.auth.mode&&c.default.createElement(d.default,null),"auth-external"===this.props.auth.mode&&c.default.createElement(h.default,null)))}}]),n}(c.default.Component);y.defaultProps={titleVisible:!0},y.propTypes={configuration:u.default.object.isRequired,auth:u.default.object.isRequired};var b=(0,p.connect)((function(e){return{configuration:e.configuration,auth:e.application.auth}}))(y);n.default=b},{"./AccessDenied":27,"./AuthExternal":30,"./AuthUserName":31,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],29:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/assertThisInitialized")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=e("actions/auth"),m=e("actions/application"),y=e("actions/messages");function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var v=function(e){(0,s.default)(n,e);var t=b(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={password:""},r.handleAuth=r.handleAuth.bind((0,o.default)(r)),r}return(0,a.default)(n,[{key:"AUTH_MODE",get:function(){return"channel-password"}}]),(0,a.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.authResult!==e.authResult&&this.props.authResult&&!0===this.props.authResult.success;this.props.authResult!==e.authResult&&this.props.authResult&&!1===this.props.authResult.success&&(this.props.alertError(this.props.authResult.error),this.props.clearAuth(this.AUTH_MODE)),t&&(this.props.markChannelAuthorized(this.props.channel.id),this.props.loadPastMessages(this.props.channel.id),this.props.clearAuth(this.AUTH_MODE))}},{key:"handleAuth",value:function(){0===this.state.password.length?this.props.alertError(this.props.i18n.enterPassword):this.props.sendAuth(this.AUTH_MODE,{password:this.state.password,channelId:this.props.channel.id})}},{key:"render",value:function(){var e=this;return u.default.createElement("div",{className:"wcAuthForm wcAuthChannelPassword"},u.default.createElement("div",{className:"wcHint"},this.props.i18n.enterPassword),u.default.createElement("div",{className:"wcFormRow"},u.default.createElement("input",{type:"password",className:"wcControl wcInputText wcUserName",value:this.state.password,onChange:function(t){return e.setState({password:t.currentTarget.value})},disabled:this.props.authResult&&this.props.authResult.inProgress}),u.default.createElement("button",{type:"button",className:"wcButton",onClick:this.handleAuth,disabled:this.props.authResult&&this.props.authResult.inProgress},this.props.i18nBase.logIn)))}}]),n}(u.default.Component);v.propTypes={channel:p.default.object.isRequired};var g=(0,f.connect)((function(e){return{i18nBase:e.configuration.i18n,i18n:e.application.i18n,authResult:e.auth.sent["channel-password"]}}),{alertError:d.alertError,alertInfo:d.alertInfo,sendAuth:h.sendAuth,clearAuth:h.clearAuth,markChannelAuthorized:m.markChannelAuthorized,loadPastMessages:y.loadPastMessages})(v);n.default=g},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/auth":96,"actions/messages":101,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],30:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/assertThisInitialized")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=e("actions/auth"),m=e("actions/application");function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var b=function(e){(0,s.default)(n,e);var t=y(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleAnonymousAuth=r.handleAnonymousAuth.bind((0,o.default)(r)),r}return(0,a.default)(n,[{key:"AUTH_MODE",get:function(){return"anonymous"}}
1]),(0,a.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.authResult!==e.authResult&&this.props.authResult&&!0===this.props.authResult.success;this.props.authResult!==e.authResult&&this.props.authResult&&!1===this.props.authResult.success&&(this.props.alertError(this.props.authResult.error),this.props.clearAuth(this.AUTH_MODE)),t&&(this.props.refreshAuthenticationData(),this.props.clearAuth(this.AUTH_MODE))}},{key:"handleAnonymousAuth",value:function(){this.props.sendAuth(this.AUTH_MODE,{nonce:this.props.auth.anonymous.nonce})}},{key:"render",value:function(){return u.default.createElement("div",{className:"wcAuthForm wcAuthExternal"},this.props.auth.anonymous&&u.default.createElement(u.default.Fragment,null,u.default.createElement("button",{className:"wcButton wcAnonymousLoginButton",type:"button",onClick:this.handleAnonymousAuth},this.props.configuration.i18n.logInAnonymously),u.default.createElement("div",{className:"wcHint"},this.props.configuration.i18n.logInUsing)),u.default.createElement("div",{className:"wcFormRow"},this.props.auth.facebook&&u.default.createElement("a",{href:this.props.auth.facebook.url,className:"wcFacebookLoginButton",title:"Facebook sign in"},"Facebook"),this.props.auth.twitter&&u.default.createElement("a",{href:this.props.auth.twitter.url,className:"wcTwitterLoginButton",title:"Twitter sign in"},"Twitter"),this.props.auth.google&&u.default.createElement("a",{href:this.props.auth.google.url,className:"wcGoogleLoginButton",title:"Google sign in"},"Google")),this.props.configuration.interface.auth.error&&u.default.createElement("div",{className:"wcErrorBox wcAuthExternalError"},this.props.configuration.interface.auth.error))}}]),n}(u.default.Component);b.propTypes={configuration:p.default.object.isRequired,auth:p.default.object.isRequired};var v=(0,f.connect)((function(e){return{configuration:e.configuration,auth:e.application.auth,authResult:e.auth.sent.anonymous}}),{alertError:d.alertError,alertInfo:d.alertInfo,sendAuth:h.sendAuth,clearAuth:h.clearAuth,refreshAuthenticationData:m.refreshAuthenticationData})(b);n.default=v},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/auth":96,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],31:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/createClass")),l=r(e("@babel/runtime/helpers/inherits")),c=r(e("@babel/runtime/helpers/possibleConstructorReturn")),u=r(e("@babel/runtime/helpers/getPrototypeOf")),p=r(e("react")),f=r(e("prop-types")),d=e("react-redux"),h=e("actions/ui"),m=e("actions/auth"),y=e("actions/application"),b=r(e("ui/common/channel/messages/message/Decorator"));function v(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?v(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):v(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,c.default)(this,n)}}var C=function(e){(0,l.default)(n,e);var t=w(n);function n(e){var r;return(0,o.default)(this,n),(r=t.call(this,e)).state={input:"",fields:r.props.configuration.interface.auth.username.fields.reduce((function(e,t){return g(g({},e),{},(0,i.default)({},t.id,""))}),{})},r.handleAuth=r.handleAuth.bind((0,a.default)(r)),r.renderField=r.renderField.bind((0,a.default)(r)),r.renderAuthButton=r.renderAuthButton.bind((0,a.default)(r)),r}return(0,s.default)(n,[{key:"AUTH_MODE",get:function(){return"username"}}
1]),(0,s.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.authResult!==e.authResult&&this.props.authResult&&!0===this.props.authResult.success;this.props.authResult!==e.authResult&&this.props.authResult&&!1===this.props.authResult.success&&(this.props.alertError(this.props.authResult.error),this.props.clearAuth(this.AUTH_MODE)),t&&(this.props.refreshAuthenticationData(),this.props.clearAuth(this.AUTH_MODE))}},{key:"handleAuth",value:function(){0===this.state.input.length?this.props.alertError(this.props.configuration.i18n.enterUserName):this.props.sendAuth(this.AUTH_MODE,{name:this.state.input,fields:this.state.fields,nonce:this.props.auth.nonce})}},{key:"renderField",value:function(e){var t=this;switch(e.type){case"text":return p.default.createElement("input",{id:"wcAuthField"+e.id,type:"text",className:"wcControl wcInputText",value:this.state.fields[e.id],onChange:function(n){return t.setState({fields:g(g({},t.state.fields),{},(0,i.default)({},e.id,n.currentTarget.value))})},disabled:this.props.authResult&&this.props.authResult.inProgress});case"long_text":return p.default.createElement("textarea",{id:"wcAuthField"+e.id,className:"wcControl wcInputText",value:this.state.fields[e.id],onChange:function(n){return t.setState({fields:g(g({},t.state.fields),{},(0,i.default)({},e.id,n.currentTarget.value))})},disabled:this.props.authResult&&this.props.authResult.inProgress})}return null}},{key:"renderAuthButton",value:function(){return p.default.createElement("button",{type:"button",className:"wcButton",onClick:this.handleAuth,disabled:this.props.authResult&&this.props.authResult.inProgress},this.props.configuration.i18n.logIn)}},{key:"render",value:function(){var e=this,t=this.props.configuration.interface.auth.username,n=t.fields,r=t.intro;return p.default.createElement("div",{className:"wcAuthForm wcAuthUserName"},r&&p.default.createElement("div",{className:"wcIntroContent"},p.default.createElement(b.default,null,r)),p.default.createElement("div",{className:"wcAuthFieldContainer"},p.default.createElement("label",{htmlFor:"wcAuthFieldUserName"},this.props.configuration.i18n.enterUserName),p.default.createElement("div",{className:"wcFormRow"},p.default.createElement("input",{id:"wcAuthFieldUserName",type:"text",className:"wcControl wcInputText wcUserName",value:this.state.input,onChange:function(t){return e.setState({input:t.currentTarget.value})},disabled:this.props.authResult&&this.props.authResult.inProgress,maxLength:this.props.configuration.interface.customization.userNameLengthLimit}),0===n.length&&this.renderAuthButton())),n.map((function(t,n){return p.default.createElement("div",{key:n,className:"wcAuthFieldContainer wcAuthFieldContainer"+t.id},p.default.createElement("label",{htmlFor:"wcAuthField"+t.id},t.name),e.renderField(t))})),n.length>0&&this.renderAuthButton())}}]),n}(p.default.Component);C.propTypes={configuration:f.default.object.isRequired,auth:f.default.object.isRequired};var _=(0,d.connect)((function(e){return{configuration:e.configuration,auth:e.application.auth,authResult:e.auth.sent.username}}),{alertError:h.alertError,alertInfo:h.alertInfo,sendAuth:m.sendAuth,clearAuth:m.clearAuth,refreshAuthenticationData:y.refreshAuthenticationData})(C);n.default=_},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/auth":96,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"ui/common/channel/messages/message/Decorator":61}],32:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("./FullChannelsMode")),d=r(e("./RecentChatsMode")),h=r(e("./RecentChatsWithCurrentMode"));function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var y=function(e){(0,a.default)(n,e);var t=m(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){var e="";return"full-channels"===this.props.configuration.interface.browser.mode&&(e="wcBrowserFullChannels"),"recent"===this.props.configuration.interface.browser.mode&&(e="wcBrowserRecent"),"recent-with-current"===this.props.configuration.interface.browser.mode&&(e="wcBrowserRecent wcBrowserRecentWithCurrent"),c.default.createElement("div",{className:"wcBrowser ".concat(e)+(this.props.visible?"":" wcInvisible"),style:{backgroundColor:this.props.configuration.defaultBackgroun
1dColor}},"full-channels"===this.props.configuration.interface.browser.mode&&c.default.createElement(f.default,{infoWindowPosition:this.props.infoWindowPosition,keepInside:this.props.keepInside}),"recent"===this.props.configuration.interface.browser.mode&&c.default.createElement(d.default,null),"recent-with-current"===this.props.configuration.interface.browser.mode&&c.default.createElement(h.default,{infoWindowPosition:this.props.infoWindowPosition,keepInside:this.props.keepInside}))}}]),n}(c.default.Component);y.defaultProps={visible:!0,infoWindowPosition:"left center"},y.propTypes={configuration:u.default.object.isRequired,visible:u.default.bool.isRequired,infoWindowPosition:u.default.string.isRequired,keepInside:u.default.string};var b=(0,p.connect)((function(e){return{configuration:e.configuration}}))(y);n.default=b},{"./FullChannelsMode":33,"./RecentChatsMode":34,"./RecentChatsWithCurrentMode":35,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],33:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/assertThisInitialized")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=e("react-scrollbars-custom"),m=r(e("./components/DirectChannel")),y=r(e("./components/DirectChannelWithPopup")),b=r(e("ui/common/counter/Counter")),v=r(e("../channel/manage/ChannelAdd")),g=r(e("../channel/manage/ChannelEdit")),w=r(e("../channel/browse/ChannelsBrowse")),C=r(e("../channel/manage/ChannelRemove"));function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var k=function(e){(0,s.default)(n,e);var t=_(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={highlighted:[],searchPhrase:""},r.handleChannelClick=r.handleChannelClick.bind((0,o.default)(r)),r.handleSearchClear=r.handleSearchClear.bind((0,o.default)(r)),r.clearHighlighted=r.clearHighlighted.bind((0,o.default)(r)),r.sortChannels=r.sortChannels.bind((0,o.default)(r)),r}return(0,a.default)(n,[{key:"MAX_PUBLIC_CHANNELS",get:function(){return 3}}]),(0,a.default)(n,[{key:"componentDidUpdate",value:function(e){if(this.props.directChannels!==e.directChannels){var t=e.directChannels.filter((function(e){return e.id&&e.online})).map((function(e){return e.id})),n=this.props.directChannels.filter((function(e){return e.id&&e.online})).map((function(e){return e.id})),r=this.props.directChannels.filter((function(e){return!t.includes(e.id)&&e.online})).map((function(e){return e.id}));r.length>0&&(this.props.notify("userJoined"),this.props.configuration.notifications.userJoined.browserHighlight&&this.setState({highlighted:r},this.clearHighlighted));var i=e.directChannels.filter((function(e){return!n.includes(e.id)&&e.online})).map((function(e){return e.id}));i.length>0&&(this.props.notify("userLeft"),this.props.configuration.notifications.userLeft.browserHighlight&&this.setState({highlighted:i},this.clearHighlighted))}}},{key:"clearHighlighted",value:function(){setTimeout(function(){this.setState({highlighted:[]})}.bind(this),5e3)}},{key:"handleChannelClick",value:function(e){this.props.ignoredChannels.includes(e.id)?this.props.confirm(this.props.i18n.ignoredInfo,function(){this.props.stopIgnoringChannel(e.id),this.props.openChannel(e.id),this.props.focusChannel(e.id)}.bind(this)):e.locked||(this.props.openChannel(e.id),this.props.focusChannel(e.id))}},{key:"handleSearchClear",value:function(e){e.preventDefault(),this.setState({searchPhrase:""})}},{key:"getPublicChannelClasses",value:function(e){var t=["wcChannelTrigger"];return e.id===this.props.focusedChannel&&t.push("wcFocusedChannel"),!0===e.protected&&!1===e.authorized&&t.push("wcLockedChannel"),!0===e.protected&&!0===e.authorized&&t.push("wcUnLockedChannel"),t.join(" ")}},{key:"sortChannels",value:function(e,t){return!1===e.online&&!0===t.online?1:!0===e.online&&!1===t.online?-1:e.name.localeCompare(t.name)}},{key:"render",value:function(){var e=this,t=(this.props.publicChannels.length>1||this.props.userRights.createChannels||this.props.userRights.searchChannels)&&this.props.configuration.interface.chat.publicEnabled;return u.default.createElement(u.default.Fragment,null,t&&u.default.createElement("div",{className:"wcChannels wcPublicChannels "+(0===this.props.directChannels.length?"wcPublicChannelsExpanded":"")},u.default.createElement("span",{className:"wcLabel"},this.props.i18nBase.channels," ",u.default.createElement(v.default,null),u.default.createElement(w.default,null)),u.default.createElement("div",{className:"wcList",style:{height:this.props.publicChannels.length<=this.MAX_PUBLIC_CHANNELS?"auto":void 0}},u.default.createElement(h.Scrollbar,{native:this.props.publicChannels.length<=this.MAX_PUBLIC_CHANNELS,noScrollX:!0},this.props.publicChannels.map((function(t){return u.default.createElement("a",{key:t.id,href:"#",onClick:function(n){n.preventDefault(),e.handleChannelClick(t)},className:e.getPublicChannelClasses(t)},u.default.createElement("span",{className:"wcDetails"},u.default.createElement("span",{className:"wcName",style:{color:t.textColor?t.textColor:void 0}},t.name)),u.default.createElement(g.default,{channel:t}),u.default.createElement(C.default,{channel:t}))}))))),this.props.directChannels.length>0&&u.default.createElement(u.default.Fragment,null,u.default.createElement("div",{className:"wcChannels wcDirectChannels"},this.props.publicChannels.length>1&&u.default.createElement("span",{className:"wcLabel"},this.props.i18nBase.users),u.default.createElement("div",{className:"wcList"},u.default.createElement(h.Scrollbar,{noScrollX:!0},this.props.directChannels.sort(this.sortChannels).filter((function(t){return!e.state.searchPhrase||t.name.match(new RegExp(e.state.searchPhrase,"i"))})).map((function(t,n){return u.default.createElement(u.default.Fragment,{key:t.id},t.infoWindow?u.default.createElement(y.default,{channel:t,popupPosition:e.props.infoWindowPosition,keepInside:e.props.keepInside,highlighted:e.state.highlighted.includes(t.id)}):u.default.createElement(m.default,{channel:t,highlighted:e.state.highlighted.includes(t.id)}))}))))),u.default.createElement(b.default,null),this.props.configuration.interface.browser.searchSubChannels&&u.default.createElement("div",{className:"wcFooter"},u.default.createElement("div",{className:"wcSearch"},u.default.createElement("input",{type:"text",className:"wcControl",placeholder:this.props.i18n.subChannelsSearchHint,value:this.state.searchPhrase,onChange:function(t){return e.setState({searchPhrase:t.target.value})}}),this.state.searchPhrase&&u.default.createElement("a",{href:"#",className:"wcClear wcFunctional",onClick:this.handleSearchClear})))))}}]),n}(u.default.Component);k.defaultProps={infoWindowPosition:"left center"},k.propTypes={configuration:p.default.object.isRequired,publicChannels:p.default.array.isRequired,ignoredChannels:p.default.array.isRequired,directChannels:p.default.array.isRequired,keepInside:p.default.string,infoWindowPosition:p.default.string.isRequired};var S=(0,f.connect)((function(e){return{configuration:e.configuration,publicChannels:e.application.browserChannels.filter((function(e){return"direct"!==e.type})),directChannels:e.application.browserChannels.filter((function(e){return"direct"===e.type})),i18nBase:e.configuration.i18n,i18n:e.application.i18n,focusedChannel:e.ui.focusedChannel,ignoredChannels:e.ui.ignoredChannels,userRights:e.application.user.rights}}),{focusChannel:d.focusChannel,openChannel:d.openChannel,stopIgnoringChannel:d.stopIgnoringChannel,confirm:d.confirm,notify:d.notify})(k);n.default=S}
1,{"../channel/browse/ChannelsBrowse":39,"../channel/manage/ChannelAdd":53,"../channel/manage/ChannelEdit":54,"../channel/manage/ChannelRemove":55,"./components/DirectChannel":36,"./components/DirectChannelWithPopup":37,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"ui/common/counter/Counter":68}],34:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("components/ui/common/recent/RecentArea"));function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var f=function(e){(0,a.default)(n,e);var t=p(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement(u.default,null)}}]),n}(c.default.Component);n.default=f},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"components/ui/common/recent/RecentArea":82,react:307}],35:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=e("react-redux"),f=e("react-scrollbars-custom"),d=e("actions/ui"),h=e("actions/application"),m=e("actions/commands"),y=r(e("ui/common/channel/messages/message/Time")),b=r(e("ui/common/channel/messages/message/Decorator")),v=r(e("prop-types"));function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var w=function(e){(0,s.default)(n,e);var t=g(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleClick=r.handleClick.bind((0,a.default)(r)),r.handleAvatarError=r.handleAvatarError.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleAvatarError",value:function(e){e.target.src=this.props.configuration.baseDir+"/gfx/icons/user.png"}},{key:"componentDidMount",value:function(){this.props.clearUserCommand("recent")}},{key:"componentDidUpdate",value:function(e){this.props.command!==e.command&&this.props.command&&!1===this.props.command.success&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand("recent"))}},{key:"handleClick",value:function(e){this.props.ignoredChannels.includes(e.channel.i
1d)?this.props.confirm(this.props.i18n.ignoredInfo,function(){this.props.stopIgnoringChannel(e.channel.id),this.openRecentChat(e)}.bind(this)):this.openRecentChat(e)}},{key:"openRecentChat",value:function(e){this.props.openChannel(e.channel.id),this.props.focusChannel(e.channel.id),e.read||(this.props.markRecentChatRead(e.channel.id),this.props.sendUserCommand("recent","markChannelAsRead",{channel:e.channel.id})),this.props.onClick&&this.props.onClick(e)}},{key:"getOpenedChannels",value:function(){var e=this;return this.props.openedChannels.filter((function(t){return e.props.channels.find((function(e){return e.id===t&&"direct"===e.type}))})).map((function(t){return e.props.channels.find((function(e){return e.id===t}))})).map((function(e){return{read:!0,channel:e}}))}},{key:"renderEntry",value:function(e,t,n){var r=this,i=this.props.uiChannels[e.channel.id];return u.default.createElement("div",{key:e.channel.id,className:"wcRecent "+(e.read?"wcRead":"wcUnread")+(0===t?" wcFirst":"")+(t+1===n.length?" wcLast":""),onClick:function(t){return r.handleClick(e)}},this.props.configuration.interface.recent.status&&u.default.createElement(u.default.Fragment,null,!0===e.channel.online?u.default.createElement("span",{className:"wcStatus wcOnline"}):u.default.createElement("span",{className:"wcStatus wcOffline"})),e.channel.avatar&&u.default.createElement("img",{src:e.channel.avatar,onError:this.handleAvatarError,className:"wcFunctional wcRecentChatAvatar",alt:e.channel.name}),u.default.createElement("div",{className:"wcRight"},u.default.createElement("div",{className:"wcHead"},u.default.createElement("span",{className:"wcName"},e.channel.name,i&&i.unread>0&&u.default.createElement("span",{key:i.unread,className:"wcUnreadMessagesCount wcAnimationFlash"},i.unread)),e.timeUTC&&u.default.createElement(y.default,{timeUTC:e.timeUTC})),this.props.configuration.interface.recent.excerpts&&e.text&&u.default.createElement("span",{className:"wcText"},u.default.createElement(b.default,null,e.text))))}},{key:"render",value:function(){var e=this;if(!this.props.configuration.interface.recent.enabled)return null;var t=this.getOpenedChannels(),n=this.props.recentChats.filter((function(t){return!e.props.openedChannels.includes(t.channel.id)})),r=n.filter((function(e){return!e.read})),i=n.filter((function(e){return e.read}));return u.default.createElement("div",{className:"wcRecentChats"},n.length>0||t.length>0?u.default.createElement(f.Scrollbar,{noScrollX:!0},t.length>0&&u.default.createElement(u.default.Fragment,null,u.default.createElement("div",{className:"wcHeader wcUnreadMessages"},this.props.i18n.openChats," "),t.map((function(t,n,r){return e.renderEntry(t,n,r)}))),r.length>0&&u.default.createElement("div",{className:"wcHeader wcUnreadMessages"},this.props.i18n.unreadChats," "),r.map((function(t,n,r){return e.renderEntry(t,n,r)})),i.length>0&&u.default.createElement("div",{className:"wcHeader wcReadMessages"},this.props.i18n.chatsArchive," "),i.map((function(t,n,r){return e.renderEntry(t,n,r)}))):u.default.createElement("span",{className:"wcNoRecent"},this.props.i18n.noRecentChats))}}]),n}(u.default.Component);w.propTypes={onClick:v.default.func,keepInside:v.default.string,infoWindowPosition:v.default.string.isRequired};var C=(0,p.connect)((function(e){return{i18nBase:e.configuration.i18n,i18n:e.application.i18n,configuration:e.configuration,channels:e.application.channels,recentChats:e.application.recentChats,openedChannels:e.ui.openedChannels,command:e.commands.sent.recent,ignoredChannels:e.ui.ignoredChannels,uiChannels:e.ui.channels}}),{focusChannel:d.focusChannel,openChannel:d.openChannel,alertError:d.alertError,sendUserCommand:m.sendUserCommand,clearUserCommand:m.clearUserCommand,markRecentChatRead:h.markRecentChatRead,stopIgnoringChannel:d.stopIgnoringChannel,confirm:d.confirm})(w);n.default=C},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"ui/common/channel/messages/message/Decorator":61,"ui/common/channel/messages/message/Time":67}],36:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/extends")),o=r(e("@babel/runtime/helpers/objectWithoutProperties")),a=r(e("@babel/runtime/helpers/classCallCheck")),s=r(e("@babel/runtime/helpers/createClass")),l=r(e("@babel/runtime/helpers/assertThisInitialized")),c=r(e("@babel/runtime/helpers/inherits")),u=r(e("@babel/runtime/helpers/possibleConstructorReturn")),p=r(e("@babel/runtime/helpers/getPrototypeOf")),f=r(e("react")),d=r(e("prop-types")),h=e("react-redux"),m=r(e("../../channel/components/Link")),y=r(e("../../channel/components/streams/StreamStatus")),b=r(e("../../channel/components/streams/StreamOpenButton"));function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,p.default)(e);if(t){var i=(0,p.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,u.default)(this,n)}}var g=function(e){(0,c.default)(n,e);var t=v(n);function n(e){var r;return(0,a.default)(this,n),(r=t.call(this,e)).handleAvatarError=r.handleAvatarError.bind((0,l.default)(r)),r}return(0,s.default)(n,[{key:"handleAvatarError",value:function(e){e.target.src=this.props.configuration.baseDir+"/gfx/icons/user.png"}},{key:"render",value:function(){return f.default.createElement(m.default,{channel:this.props.channel,forwardedRef:this.props.forwardedRef,className:"wcChannelTrigger"+(this.props.channel.i
1d===this.props.focusedChannel?" wcFocusedChannel":"")+(this.props.highlighted?" wcAnimation wcAnimationFlash":""),onMouseEnter:this.props.onMouseEnter,onMouseLeave:this.props.onMouseLeave,onFocus:this.props.onFocus,onBlur:this.props.onBlur},this.props.configuration.interface.browser.status&&f.default.createElement(f.default.Fragment,null,!0===this.props.channel.online&&f.default.createElement("span",{className:"wcStatus wcOnline"}),!1===this.props.channel.online&&f.default.createElement("span",{className:"wcStatus wcOffline"})),this.props.channel.avatar&&f.default.createElement("img",{src:this.props.channel.avatar,onError:this.handleAvatarError,className:"wcFunctional wcAvatar",alt:this.props.channel.name}),f.default.createElement("span",{className:"wcDetails"+(this.props.configuration.interface.browser.status?" wcDetailsWithStatus":"")},f.default.createElement("span",{className:"wcName",style:{color:this.props.channel.textColor?this.props.channel.textColor:void 0}},this.props.channel.name),this.props.channel.muted&&f.default.createElement("span",{className:"wcIcon wcIconProhibited wcIconXs",title:this.props.i18n.muted}),this.props.channel.countryFlagSrc&&f.default.createElement("img",{src:this.props.channel.countryFlagSrc,className:"wcFunctional wcCountryFlag",alt:this.props.channel.countryCode}),this.props.channel.city&&f.default.createElement("span",{className:"wcCity"},this.props.channel.city),this.props.channel.countryCode&&f.default.createElement("span",{className:"wcCountry"},this.props.channel.countryCode),f.default.createElement(b.default,{channel:this.props.channel}),f.default.createElement(y.default,{channel:this.props.channel})))}}]),n}(f.default.Component);g.propTypes={channel:d.default.object.isRequired,highlighted:d.default.bool};var w=(0,h.connect)((function(e){return{configuration:e.configuration,i18n:e.application.i18n,ignoredChannels:e.ui.ignoredChannels,focusedChannel:e.ui.focusedChannel}}))(g),C=f.default.forwardRef((function(e,t){e.open;var n=(0,o.default)(e,["open"]);return f.default.createElement(w,(0,i.default)({},n,{forwardedRef:t}))}));n.default=C},{"../../channel/components/Link":43,"../../channel/components/streams/StreamOpenButton":44,"../../channel/components/streams/StreamStatus":45,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/extends":131,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/objectWithoutProperties":142,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],37:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=r(e("./DirectChannel")),d=r(e("reactjs-popup")),h=e("react-scrollbars-custom"),m=r(e("ui/common/channel/messages/message/Decorator")),y=e("react-redux");function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var v=function(e){(0,s.default)(n,e);var t=b(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleAvatarError=r.handleAvatarError.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleAvatarError",value:function(e){e.target.src=this.props.configuration.baseDir+"/gfx/icons/user.png"}},{key:"render",value:function(){var e=this,t=this.props.channel.infoWindow;return u.default.createElement(d.default,{trigger:function(t){return u.default.createElement(f.default,{open:t,channel:e.props.channel,highlighted:e.props.highlighted})}
1,position:this.props.popupPosition,className:"wcPopup wcInfoWindowPopup "+this.props.configuration.themeClassName,on:["hover","focus"],arrow:!1,keepTooltipInside:this.props.keepInside},u.default.createElement(h.Scrollbar,{noScrollX:!0},u.default.createElement("div",{className:"wcContent"},t.avatar&&u.default.createElement("div",{className:"wcLeft"},u.default.createElement("img",{src:t.avatar,alt:t.name,onError:this.handleAvatarError})),u.default.createElement("div",{className:"wcRight"},t.url?u.default.createElement("a",{href:t.url,rel:"noopener noreferrer nofollow",className:"wcName"},t.name):u.default.createElement("span",{className:"wcName"},t.name),u.default.createElement("div",{className:"wcDetails"},u.default.createElement(m.default,null,t.content))))))}}]),n}(u.default.Component);v.defaultProps={popupPosition:"left center"},v.propTypes={channel:p.default.object.isRequired,popupPosition:p.default.string.isRequired,highlighted:p.default.bool,keepInside:p.default.string};var g=(0,y.connect)((function(e){return{configuration:e.configuration}}))(v);n.default=g},{"./DirectChannel":36,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"reactjs-popup":308,"ui/common/channel/messages/message/Decorator":61}],38:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("./messages/Messages")),h=r(e("./input/InputRich")),m=r(e("ui/common/auth/AuthChannelPassword")),y=r(e("./components/Full")),b=r(e("ui/common/counter/Counter")),v=r(e("./components/Intro")),g=r(e("./components/streams/Streams")),w=r(e("jquery"));function C(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var _=function(e){(0,s.default)(n,e);var t=C(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={view:"Compound"},r.element=u.default.createRef(),r.switchView=r.switchView.bind((0,a.default)(r)),r.getClasses=r.getClasses.bind((0,a.default)(r)),r.handleResize=r.handleResize.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"componentDidMount",value:function(){window.addEventListener("resize",this.handleResize),this.handleResize()}},{key:"componentWillUnmount",value:function(){window.removeEventListener("resize",this.handleResize)}},{key:"handleResize",value:function(){var e=(0,w.default)(this.element.current).closest(".wcChannel").width(),t="";t=e<380?"wcChannelSizeXXs":e<576?"wcChannelSizeXs":e<768?"wcChannelSizeSm":e<992?"wcChannelSizeMd":e<1200?"wcChannelSizeLg":"wcChannelSizeXl",this.state.breakpointUpClassName!==t&&this.setState({breakpointUpClassName:t})}},{key:"switchView",value:function(e){this.setState({view:e})}},{key:"getClasses",value:function(){var e=["wcChannel","wcChannelView"+this.state.view,"top"===this.props.configuration.interface.channel.inputLocation?" wcTopInput":" wcBottomInput"];return this.props.stream&&e.push("wcChannelStream"),this.props.stream&&this.props.uiChannel&&this.props.uiChannel.streamMaximized&&e.push("wcChannelStreamMaximized"),this.props.className&&e.push(this.props.className),this.state.breakpointUpClassName&&e.push(this.state.breakpointUpClassName)," "+e.join(" ")}},{key:"render",value:function(){var e=this,t=!0===this.props.channel.protected&&!1===this.props.channel.authorized;return u.default.createElement("div",{ref:this.element,className:(t?" wcChannelAuth":"")+this.getClasses(),"data-id":this.props.channel.i
1d,"data-name":this.props.channel.name,style:{backgroundColor:this.props.configuration.defaultBackgroundColor}},t?u.default.createElement("div",{className:"wcAuthContainer"},u.default.createElement("div",{className:"wcAuth"},u.default.createElement(m.default,{channel:this.props.channel}))):u.default.createElement(u.default.Fragment,null,this.props.channel.full?u.default.createElement(y.default,null):u.default.createElement(u.default.Fragment,null,u.default.createElement("div",{className:"wcChannelViewToolbar"},u.default.createElement("button",{className:"wcFunctional wcChannelViewButton wcChannelViewButtonChat"+("Chat"===this.state.view?" wcChannelViewButtonCurrent":""),onClick:function(t){return e.switchView("Chat")},title:this.props.i18n.switchToChat}),u.default.createElement("button",{className:"wcFunctional wcChannelViewButton wcChannelViewButtonStream"+("Stream"===this.state.view?" wcChannelViewButtonCurrent":""),onClick:function(t){return e.switchView("Stream")},title:this.props.i18n.switchToVideoCall})),u.default.createElement(v.default,{channel:this.props.channel}),u.default.createElement("div",{className:"wcChannelData"},u.default.createElement(d.default,{channel:this.props.channel}),u.default.createElement(g.default,{channel:this.props.channel})),(["wcChannelSizeXs","wcChannelSizeXXs"].includes(this.state.breakpointUpClassName)||!this.props.configuration.interface.browser.enabled)&&u.default.createElement(b.default,null),u.default.createElement(h.default,{channel:this.props.channel}))))}}]),n}(u.default.Component);_.propTypes={configuration:p.default.object.isRequired,channel:p.default.object.isRequired,className:p.default.string};var k=(0,f.connect)((function(e,t){return{i18n:e.application.i18n,stream:e.ui.streams.find((function(e){return e.channel&&e.channel.id===t.channel.id})),uiChannel:e.ui.channels[t.channel.id],configuration:e.configuration}}))(_);n.default=k},{"./components/Full":41,"./components/Intro":42,"./components/streams/Streams":46,"./input/InputRich":50,"./messages/Messages":58,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,jquery:244,"prop-types":256,react:307,"react-redux":295,"ui/common/auth/AuthChannelPassword":29,"ui/common/counter/Counter":68}],39:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/assertThisInitialized")),l=r(e("@babel/runtime/helpers/inherits")),c=r(e("@babel/runtime/helpers/possibleConstructorReturn")),u=r(e("@babel/runtime/helpers/getPrototypeOf")),p=r(e("react")),f=r(e("prop-types")),d=e("react-redux"),h=r(e("../../modal/Modal")),m=e("actions/ui"),y=e("actions/commands"),b=e("actions/application"),v=e("actions/messages"),g=e("react-scrollbars-custom");function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function C(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,c.default)(this,n)}}var k=function(e){(0,l.default)(n,e);var t=_(n);function n(e,r){var i;return(0,o.default)(this,n),(i=t.call(this,e,r)).state=C({modalOpen:!1}
1,i.getCleanState()),i.openModal=i.openModal.bind((0,s.default)(i)),i.searchChannels=i.searchChannels.bind((0,s.default)(i)),i.renderSearchResult=i.renderSearchResult.bind((0,s.default)(i)),i.joinChannel=i.joinChannel.bind((0,s.default)(i)),i}return(0,a.default)(n,[{key:"getCleanState",value:function(){return{search:""}}},{key:"openModal",value:function(e){e.preventDefault(),this.setState(C({modalOpen:!0},this.getCleanState()))}},{key:"componentDidUpdate",value:function(e){if(this.state.modalOpen){var t=this.props.requestChannelMembership!==e.requestChannelMembership&&this.props.requestChannelMembership&&!1===this.props.requestChannelMembership.success,n=this.props.requestChannelMembership!==e.requestChannelMembership&&this.props.requestChannelMembership&&!0===this.props.requestChannelMembership.success,r=this.props.addUserChannel!==e.addUserChannel&&this.props.addUserChannel&&!1===this.props.addUserChannel.success,i=this.props.addUserChannel!==e.addUserChannel&&this.props.addUserChannel&&!0===this.props.addUserChannel.success;if(t&&(this.props.alertError(this.props.requestChannelMembership.error),this.props.clearUserCommand("requestChannelMembership")),n&&(this.props.toastInfo(this.props.i18n.requestSent),this.props.clearUserCommand("requestChannelMembership")),r&&(this.props.alertError(this.props.addUserChannel.error),this.props.clearUserCommand("addUserChannel")),i){var o=this.props.addUserChannel.result.channel;this.props.addChannel(o),this.props.openChannel(o.id),this.props.focusChannel(o.id),this.props.clearUserCommand("addUserChannel"),this.props.toastInfo(this.props.i18n.channelAdded)}}}},{key:"componentWillUnmount",value:function(){this.props.clearUserCommand("searchChannels"),this.searchTimer&&(clearTimeout(this.searchTimer),this.searchTimer=null)}},{key:"searchChannels",value:function(){this.searchTimer&&(clearTimeout(this.searchTimer),this.searchTimer=null),this.state.search&&(this.searchTimer=setTimeout(function(){this.searchChannelsReal()}.bind(this),400))}},{key:"searchChannelsReal",value:function(){this.props.sendUserCommand("searchChannels","searchChannels",{search:this.state.search})}},{key:"renderSearchResult",value:function(e,t){var n=this,r=this.props.i18n.freeToJoin,i=this.props.i18n.openChannel;return"private"===e.channel.type&&(e.member?r=this.props.i18n.channelMember:(r=this.props.i18n.notMember,i=this.props.i18n.askToJoin)),p.default.createElement("tr",{key:t},p.default.createElement("td",null,e.channel.name),p.default.createElement("td",null,e.channel.type),p.default.createElement("td",null,r),p.default.createElement("td",null,p.default.createElement("a",{href:"#",onClick:function(t){return n.joinChannel(t,e)}},i)))}},{key:"joinChannel",value:function(e,t){e.preventDefault(),"private"!==t.channel.type||t.member?this.props.sendUserCommand("addUserChannel","addUserChannel",{channelId:t.channel.id}):this.props.confirm(this.props.i18n.askChannelAdmin,function(){this.props.sendUserCommand("requestChannelMembership","requestChannelMembership",{channelId:t.channel.id})}.bind(this))}},{key:"render",value:function(){var e=this;return this.props.userRights.searchChannels?p.default.createElement(p.default.Fragment,null,p.default.createElement("a",{href:"#",className:"wcFunctional",title:this.props.i18n.browseChannels,onClick:this.openModal},p.default.createElement("span",{className:"wcIcon wcIconZoom"}),this.props.label?this.props.i18n.browseChannels:""),p.default.createElement(h.default,{open:this.state.modalOpen,onClose:function(t){return e.setState({modalOpen:!1})},title:this.props.i18n.browseChannels,size:"lg",closable:!0,closeOnDocumentClick:!1},p.default.createElement("div",{className:"wcFormRow"},p.default.createElement("label",null,this.props.i18n.searchChannels,": "),p.default.createElement("input",{className:"wcFormControl",type:"text",maxLength:200,value:this.state.search,onChange:function(t){return e.setState({search:t.target.value},e.searchChannels)}})),this.state.search&&p.default.createElement("div",{className:"wcFormRow"},p.default.createElement("label",null,this.props.i18n.foundChannels,": "),p.default.createElement("div",{className:"wcFormControlBorder wcHeight10 wcPadding1"},this.props.channels&&this.props.channels.inProgress&&p.default.createElement("span",{className:"wcMargin1"},this.props.i18n.searching," ..."),this.props.channels&&!this.props.channels.inProgress&&0===this.props.channels.result.entries.length&&p.default.createElement("span",{className:"wcMargin1"},this.props.i18n.noChannels),this.props.channels&&this.props.channels.result&&this.props.channels.result.entries.length>0&&p.default.createElement(g.Scrollbar,null,p.default.createElement("table",{className:"wcTable"},p.default.createElement("thead",null,p.default.createElement("tr",null,p.default.createElement("th",
1null,this.props.i18n.channelName),p.default.createElement("th",null,this.props.i18n.channelType),p.default.createElement("th",null,this.props.i18n.channelStatus),p.default.createElement("th",null,this.props.i18n.channelActions))),p.default.createElement("tbody",null,this.props.channels.result.entries.map((function(t,n){return e.renderSearchResult(t,n)}))))))))):null}}]),n}(p.default.Component);k.propTypes={configuration:f.default.object.isRequired,label:f.default.bool};var S=(0,d.connect)((function(e){return{userRights:e.application.user.rights,configuration:e.configuration,i18n:e.application.i18n,channels:e.commands.sent.searchChannels,requestChannelMembership:e.commands.sent.requestChannelMembership,addUserChannel:e.commands.sent.addUserChannel}}),{sendUserCommand:y.sendUserCommand,clearUserCommand:y.clearUserCommand,alertError:m.alertError,alertInfo:m.alertInfo,focusChannel:m.focusChannel,openChannel:m.openChannel,addChannel:b.addChannel,toastInfo:m.toastInfo,confirm:m.confirm,loadPastMessages:v.loadPastMessages})(k);n.default=S},{"../../modal/Modal":77,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/commands":97,"actions/messages":101,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304}],40:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui");function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var m=function(e){(0,s.default)(n,e);var t=h(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleCloseClick=r.handleCloseClick.bind((0,a.default)(r)),r.closeChannel=r.closeChannel.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleCloseClick",value:function(e){e.preventDefault(),e.stopPropagation(),this.props.configuration.interface.channel.direct.closeConfirmation?this.props.confirm(this.props.i18n.directChannelCloseConfirmation,this.closeChannel):this.props.stream?this.props.confirm(this.props.i18n.directChannelWithStreamCloseConfirmation,this.closeChannel):this.closeChannel()}},{key:"closeChannel",value:function(){var e=!1;if(this.props.focusedChannel===this.props.channel.id&&this.props.focusOnClose){var t,n=this.props.openedChannels.indexOf(this.props.channel.id);n===this.props.openedChannels.length-1?t=this.getLastChannelBeforeIndex(n):(t=this.getFirstChannelAfterIndex(n))||(t=this.getLastChannelBeforeIndex(n)),this.props.closeChannel(this.props.channel.id),this.props.focusChannel(t||void 0),t||(e=!0)}else this.props.closeChannel(this.props.channel.id);this.props.configuration.interface.channel.logOffOnCloseLast&&e&&this.props.logOff(),this.props.configuration.interface.channel.destroyOnCloseLast&&e&&this.props.destroy()}},{key:"getFirstChannelAfterIndex",value:function(e){var t=this;return this.props.openedChannels.find((function(n,r){return r>e&&t.props.channels.find((function(e){return e.id===n}))}))}},{key:"getLastChannelBeforeIndex",value:function(e){var t=this,n=this.props.openedChannels.filter((function(n,r){return r<e&&t.props.channels.find((function(e){return e.id===n}))}));return n.length>0?n[n.length-1]:void 0}},{key:"render",value:function(){return u.default.createElement("a",{href:"#",onClick:this.handleCloseClick,title:this.props.i18n.close,className:this.props.className})}}]),n}(u.default.Component);
1m.defaultProps={className:"wcFunctional wcChannelClose",focusOnClose:!1},m.propTypes={channel:p.default.object.isRequired,className:p.default.string.isRequired,focusOnClose:p.default.bool.isRequired,onClose:p.default.func};var y=(0,f.connect)((function(e,t){return{i18n:e.application.i18n,configuration:e.configuration,channels:e.application.channels,openedChannels:e.ui.openedChannels,focusedChannel:e.ui.focusedChannel,stream:e.ui.streams.find((function(e){return e.channel&&e.channel.id===t.channel.id}))}}),{focusChannel:d.focusChannel,closeChannel:d.closeChannel,confirm:d.confirm,logOff:d.logOff,destroy:d.destroy})(m);n.default=y},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],41:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux");function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var d=function(e){(0,a.default)(n,e);var t=f(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement("div",{className:"wcChannelCoverContainer"},c.default.createElement("div",{className:"wcChannelCover"},c.default.createElement("div",{className:"wcChatFullMessage wcErrorBox"},this.props.i18n.chatFull)))}}]),n}(c.default.Component);d.defaultProps={titleVisible:!0},d.propTypes={configuration:u.default.object.isRequired};var h=(0,p.connect)((function(e){return{configuration:e.configuration,i18n:e.application.i18n}}))(d);n.default=h},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],42:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("ui/common/channel/messages/message/Decorator"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var m=function(e){(0,s.default)(n,e);var t=h(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleAvatarError=r.handleAvatarError.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleAvatarError",value:function(e){e.target.src=this.props.configuration.baseDir+"/gfx/icons/user.png"}},{key:"render",value:function(){return this.props.channel.intro?u.default.createElement("div",{className:"wcChannelIntro"},u.default.createElement("div",{className:"wcChannelIntroAvatar"},this.props.channel.avatar&&u.default.createElement("img",{src:this.props.channel.avatar,onError:this.handleAvatarError,className:"wcFunctional wcAvatar",alt:this.props.channel.name})),u.default.createElement("div",{className:"wcChannelIntroContent"},u.default.createElement(d.default,null,this.props.channel.intro))):null}}]),n}(u.default.Component);m.propTypes={channel:p.default.object.isRequired};var y=(0,f.connect)((function(e){return{configuration:e.configuration}}))(m);
1n.default=y},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"ui/common/channel/messages/message/Decorator":61}],43:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=e("actions/application");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleChannelClick=r.handleChannelClick.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleChannelClick",value:function(e){if(!this.props.channel.url&&(e.preventDefault(),!this.props.channel.own&&this.props.configuration.interface.channel.directEnabled)){this.props.addChannel(this.props.channel,!0);var t=this.props.channel.id;this.props.ignoredChannels.includes(t)?this.props.confirm(this.props.i18n.ignoredInfo,function(){this.props.stopIgnoringChannel(t),this.props.openChannel(t),this.props.focusChannel(t),this.props.onClick&&this.props.onClick(this.props.channel)}.bind(this)):this.props.channel.locked||(this.props.openChannel(t),this.props.focusChannel(t),this.props.onClick&&this.props.onClick(this.props.channel))}}},{key:"render",value:function(){var e=this;return u.default.createElement("a",{href:this.props.channel.url?this.props.channel.url:"#",onClick:function(t){return e.handleChannelClick(t)},ref:this.props.forwardedRef,target:"_blank",rel:"noopener noreferrer nofollow",className:this.props.className,onMouseEnter:this.props.onMouseEnter,onMouseLeave:this.props.onMouseLeave,onFocus:this.props.onFocus,onBlur:this.props.onBlur,style:this.props.style},this.props.children)}}]),n}(u.default.Component);y.propTypes={channel:p.default.object.isRequired,forwardedRef:p.default.object,className:p.default.string,onMouseEnter:p.default.func,onMouseLeave:p.default.func,onFocus:p.default.func,onBlur:p.default.func,style:p.default.object};var b=(0,f.connect)((function(e){return{configuration:e.configuration,i18n:e.application.i18n,ignoredChannels:e.ui.ignoredChannels}}),{focusChannel:d.focusChannel,openChannel:d.openChannel,stopIgnoringChannel:d.stopIgnoringChannel,confirm:d.confirm,addChannel:h.addChannel})(y);n.default=b},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],44:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("ui/common/stream/StreamOpenButton"));function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var h=function(e){(0,a.default)(n,e);var t=d(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"isVideoCallAvailable",value:function(){return!this.props.channel.locked&&this.props.channel.online&&!this.props.channel.readOnly&&this.props.configuration.interface.streams.video.calls.enabled&&this.props.configuration.interface.channel.directEnabled&&!this.props.stream}},{key:"render",value:function(){return this.isVideoCallAvailable()?c.default.createElement(f.default,{label:this.props.i18n.makeVideoCall?this.props.i18n.makeVideoCall:"",type:"stream.video.twilio.room.go",parameters:{channel:{id:this.props.channel.i
1d}}}):null}}]),n}(c.default.Component);h.propTypes={channel:u.default.object.isRequired};var m=(0,p.connect)((function(e,t){return{configuration:e.configuration,i18n:e.application.i18n,stream:e.ui.streams.find((function(e){return e.channel&&e.channel.id===t.channel.id}))}}))(h);n.default=m},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"ui/common/stream/StreamOpenButton":85}],45:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux");function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var d=function(e){(0,a.default)(n,e);var t=f(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"renderStreamStatus",value:function(){switch(this.props.stream.type){case"stream.video.twilio.room.go":return c.default.createElement("span",{className:"wcStreamStatus wcStreamOnGoing wcAnimation wcAnimationFlashSlow"});default:return"Unsupported stream"}}},{key:"render",value:function(){return this.props.stream?this.renderStreamStatus():null}}]),n}(c.default.Component);d.propTypes={channel:u.default.object.isRequired};var h=(0,p.connect)((function(e,t){return{stream:e.ui.streams.find((function(e){return e.channel&&e.channel.id===t.channel.id}))}}))(d);n.default=h},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],46:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("../../../stream/twilio/TwilioVideoGoRoom")),h=e("actions/ui");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleAvatarError=r.handleAvatarError.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleAvatarError",value:function(e){e.target.src=this.props.configuration.baseDir+"/gfx/icons/user.png"}},{key:"renderStream",value:function(){var e=this;switch(this.props.stream.type){case"stream.video.twilio.room.go":return u.default.createElement(d.default,{stream:this.props.stream,streamInfo:u.default.createElement("div",{className:"wcStreamChannelDetails"},this.props.channel.avatar&&u.default.createElement("img",{src:this.props.channel.avatar,onError:this.handleAvatarError,className:"wcFunctional wcAvatar",alt:this.props.channel.name}),u.default.createElement("div",{className:"wcStreamCaller"},this.props.channel.name)),maximized:this.props.uiChannel.streamMaximized,onMaximize:function(){return e.props.setChannelProperty(e.props.channel.i
1d,"streamMaximized",!0)},onMinimize:function(){return e.props.setChannelProperty(e.props.channel.id,"streamMaximized",void 0)}});default:return"Unsupported stream request"}}},{key:"render",value:function(){return this.props.stream?u.default.createElement("div",{className:"wcStream"},this.renderStream()):null}}]),n}(u.default.Component);y.propTypes={channel:p.default.object.isRequired};var b=(0,f.connect)((function(e,t){var n;return{configuration:e.configuration,stream:e.ui.streams.find((function(e){return e.channel&&e.channel.id===t.channel.id})),uiChannel:null!==(n=e.ui.channels[t.channel.id])&&void 0!==n?n:{}}}),{setChannelProperty:h.setChannelProperty})(y);n.default=b},{"../../../stream/twilio/TwilioVideoGoRoom":86,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],47:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=e("actions/messages"),d=e("actions/ui"),h=r(e("utils/image-viewer")),m=r(e("ui/common/plain/ProgressBar")),y=r(e("ui/common/Loader")),b=e("actions/log");function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var g=function(e){(0,a.default)(n,e);var t=v(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).imageViewer=new h.default,r}return(0,o.default)(n,[{key:"IMAGE_TYPES",get:function(){return["jpg","jpeg","png","gif"]}}]),(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.preparedImage!==e.preparedImage&&this.props.preparedImage&&this.props.preparedImage.success,n=this.props.preparedImage!==e.preparedImage&&this.props.preparedImage&&!1===this.props.preparedImage.success,r=this.props.imageSource!==e.imageSource&&this.props.imageSource,i=this.props.fileSource!==e.fileSource&&this.props.fileSource,o=this.props.soundSource!==e.soundSource&&this.props.soundSource;t&&this.onImagePrepared(this.props.preparedImage.result),n&&this.props.alertError(this.props.preparedImage.error),r&&this.onImageUploadFileChange(this.props.imageSource),i&&this.onFileUploadFileChange(this.props.fileSource),o&&this.onSoundSourceChange(this.props.soundSource)}},{key:"addAttachment",value:function(e,t,n,r){this.props.onChange([{type:e,data:t,name:n,url:r}])}},{key:"handleDelete",value:function(e,t){e.preventDefault(),this.props.onChange(this.props.attachments.filter((function(e,n){return n!==t})))}},{key:"handleImagePreview",value:function(e,t){e.preventDefault(),this.imageViewer.show(t)}},{key:"onImageUploadFileChange",value:function(e){var t=this;if("undefined"!=typeof FileReader)if(0!==e.length){var n=e[0];if(n.size&&n.size>this.props.configuration.interface.input.images.sizeLimit)this.props.alertError(this.props.application.i18n.sizeLimitError);else if(this.IMAGE_TYPES.indexOf(this.getExtension(n))>-1){var r=new FileReader;r.onload=function(e){t.props.prepareImage(e.target.result,t.props.channel.id)},r.readAsDataURL(n)}else this.props.alertError(this.props.application.i18n.unsupportedTypeOfFile)}else this.props.alertError("No files selected");else this.props.alertError("FileReader is not supported in this browser")}},{key:"onImagePrepared",value:function(e){e&&e.length>0?this.addAttachment("image",e):this.props.alertError("Cannot prepare image due to server error")}},{key:"onFileUploadFileChange",value:function(e){var t=this;if("undefined"!=typeof FileReader)if(0!==e.length){var n=e[0];if(this.props.configuration.interface.input.attachments.validFileFormats.indexOf(this.getExtension(n))>-1){var r=new FileReader,i=n.name;n.size>this.props.configuration.interface.input.attachments.sizeLimit?this.props.alertError(this.props.application.i18n.sizeLimitError):(r.onload=function(e){t.addAttachment("file",e.target.result,i
1)},r.readAsDataURL(n))}else this.props.alertError(this.props.application.i18n.unsupportedTypeOfFile)}else this.props.alertError("No files selected");else this.props.alertError("FileReader is not supported in this browser")}},{key:"onSoundSourceChange",value:function(e){var t=this;if("undefined"!=typeof FileReader){var n=new FileReader;n.onload=function(n){t.addAttachment(e.type,n.target.result,"Wise Chat Pro voice message",URL.createObjectURL(e.data))},n.onerror=function(e){t.props.alertError("Could not process sound data using FileReader"),t.props.logError("Could not process sound data using FileReader",e)},n.readAsDataURL(e.data)}else this.props.alertError("FileReader is not supported in this browser")}},{key:"getExtension",value:function(e){if(void 0!==e.name){var t=e.name.split(".");if(t.length>1)return t.pop().toLowerCase()}return null}},{key:"render",value:function(){var e=this;return c.default.createElement("div",{className:"wcAttachments"},this.props.preparedImage&&c.default.createElement(m.default,{visible:this.props.preparedImage.inProgress,progress:this.props.preparedImage.progress}),this.props.processingMessage&&c.default.createElement(y.default,{message:this.props.processingMessage}),this.props.attachments.map((function(t,n){return c.default.createElement("div",{key:n,className:"wcAttachment"},"file"===t.type&&c.default.createElement("span",null,t.name),"image"===t.type&&c.default.createElement("a",{href:"#",className:"wcFunctional",onClick:function(n){return e.handleImagePreview(n,t.data)}},c.default.createElement("img",{src:t.data,className:"wcImagePreview wcFunctional",alt:"Image preview"})),"mp3"===t.type&&c.default.createElement("audio",{controls:!0,src:t.url,controlsList:"nodownload noplaybackrate"}),c.default.createElement("a",{href:"#",className:"wcDelete wcFunctional",onClick:function(t){return e.handleDelete(t,n)}}))})))}}]),n}(c.default.Component);g.propTypes={channel:u.default.object.isRequired,configuration:u.default.object.isRequired,preparedImage:u.default.object,attachments:u.default.array.isRequired,onChange:u.default.func.isRequired,processingMessage:u.default.string};var w=(0,p.connect)((function(e,t){return{configuration:e.configuration,application:e.application,preparedImage:e.messages.image[t.channel.i
1d]}}),{sendMessage:f.sendMessage,prepareImage:f.prepareImage,alertError:d.alertError,logError:b.logError})(g);n.default=w},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/log":100,"actions/messages":101,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"ui/common/Loader":23,"ui/common/plain/ProgressBar":80,"utils/image-viewer":120}],48:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=r(e("reactjs-popup")),d=e("react-redux"),h=e("react-scrollbars-custom"),m=r(e("utils/emoticons")),y=r(e("./emoticons/TenorGIFs"));function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var v=function(e){(0,s.default)(n,e);var t=b(n);function n(e){var r;(0,i.default)(this,n),(r=t.call(this,e)).state={tab:"emoticons"},r.handleClick=r.handleClick.bind((0,a.default)(r));var o=new m.default(r.props.configuration.interface.input.emoticons);return o.buildSet(),r.layerWidth=o.LAYER_WIDTH,r.layerHeight=o.LAYER_HEIGHT,r.emoticons=o.emoticons,r}return(0,o.default)(n,[{key:"handleClick",value:function(e,t){e.preventDefault(),this.props.onSelect(t.shortcode)}},{key:"render",value:function(){var e=this,t=this.props.configuration.interface.input.emoticons.custom,n=this.props.configuration.interface.input.gifs.enabled,r=this.layerHeight+(n?50:0),i="XXs"!==this.props.windowSizeClass?this.layerWidth:"80%";return u.default.createElement(u.default.Fragment,null,u.default.createElement(f.default,{trigger:u.default.createElement("button",{className:"wcInputButton wcEmoticon wcFunctional",title:this.props.i18n.insertEmoticon}),position:"top center",lockScroll:!0,closeOnDocumentClick:!0,modal:"XXs"===this.props.windowSizeClass,className:"wcPopup wcEmoticonsPopup "+this.props.configuration.themeClassName,contentStyle:{width:i,height:r},keepTooltipInside:!0},(function(r){return u.default.createElement("div",{className:"wcAddonsLibrary"},n&&u.default.createElement("div",{className:"wcCategories"},u.default.createElement("a",{href:"#",className:"wcFunctional wcCategoryButton "+("emoticons"===e.state.tab?"wcCategoryButtonActive":""),onClick:function(t){t.preventDefault(),e.setState({tab:"emoticons"})}},u.default.createElement("span",{className:"wcIcon wcIconEmotion"})),u.default.createElement("a",{href:"#",className:"wcFunctional wcCategoryButton "+("gifs"===e.state.tab?"wcCategoryButtonActive":""),onClick:function(t){t.preventDefault(),e.setState({tab:"gifs"})}},u.default.createElement("span",{className:"wcIcon wcIconGif"}))),e.props.configuration.interface.input.gifs.enabled&&u.default.createElement("div",{className:"wcCategory wcCategoryGIFs "+("gifs"!==e.state.tab?"wcInvisible":"")},u.default.createElement(y.default,{onClick:function(t){e.props.onSelect(t+"\n\n"),r()}})),u.default.createElement("div",{className:"wcCategory wcCategoryEmoticons "+("emoticons"!==e.state.tab?"wcInvisible":"")},u.default.createElement(h.Scrollbar,{noScrollX:!0},t&&e.emoticons.map((function(t,n){return u.default.createElement("a",{href:"#",key:n,onClick:function(n){e.handleClick(n,t),r()}},u.default.createElement("img",{src:t.urlFull,style:t.maxWidth?{maxWidth:t.maxWidth}:void 0}))})),!t&&e.emoticons.map((function(t,n){return u.default.createElement("a",{href:"#",key:n,onClick:function(n){e.handleClick(n,t),r()}},u.default.createElement("span",{className:"wcEmoticon "+t.class}))})))))})))}}]),n}(u.default.Component);v.propTypes={configuration:p.default.object.isRequired,onSelect:p.default.func.isRequired};var g=(0,d.connect)((function(e){return{configuration:e.configuration,i18n:e.application.i18n,windowWidth:e.ui.properties.windowWidth,windowSizeClass:e.ui.properties.windowSizeClass}}))(v);n.default=g},{"./emoticons/TenorGIFs":52,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"reactjs-popup":308,"utils/emoticons":115}],49:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=r(e("jquery")),d=e("react-redux"),h=r(e("utils/html-renderer")),m=e("react-dom/server"),y=e("actions/log");function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var v=function(e){(0,s.default)(n,e);var t=b(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).editableRef=u.default.createRef(),r.htmlRenderer=new h.default(e.configuration),r.handleChange=r.handleChange.bind((0,a.default)(r)),r.handleClick=r.handleClick.bind((0,a.default)(r)),r.handleKeyDown=r.handleKeyDown.bind((0,a.default)(r)),r.handlePaste=r.handlePaste.bind((0,a.default)(r)),r}
1return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this,n=this.props.inputRequest!==e.inputRequest,r=this.props.resetRequest!==e.resetRequest&&!0===this.props.resetRequest;if(n&&this.props.inputRequest){if(this.isMaximumOfCharactersReached())return;var i=f.default.parseHTML(this.convertMessageToHTML(this.props.inputRequest));this.range?(this.range.deleteContents(),i.reverse().map((function(e){return t.range.insertNode(e)})),this.range.collapse(!1),this.selection.removeAllRanges(),this.selection.addRange(this.range)):(this.props.logError("Range is not available, fallback to jQuery append"),(0,f.default)(this.editableRef.current).append(i),this.focusAndPlaceCaretAtEnd(this.editableRef.current)),this.triggerChange()}r&&(0,f.default)(this.editableRef.current).html("")}},{key:"focusAndPlaceCaretAtEnd",value:function(e){if(e.focus(),void 0!==window.getSelection&&void 0!==document.createRange){var t=document.createRange();t.selectNodeContents(e),t.collapse(!1);var n=window.getSelection();n.removeAllRanges(),n.addRange(t)}else if(void 0!==document.body.createTextRange){var r=document.body.createTextRange();r.moveToElementText(e),r.collapse(!1),r.select()}}},{key:"convertMessageToHTML",value:function(e){return(0,m.renderToString)(this.htmlRenderer.toHtml(e))}},{key:"convertHTMLToMessage",value:function(e){var t=(0,f.default)("<div>"+e+"</div>");t.find("[data-org]").each((function(e,t){(0,f.default)(t).replaceWith(atob((0,f.default)(t).attr("data-org")))}));var n=(0,f.default)("<div>"+t.html()+"</div>");return n.contents().each((function(e,t){"BR"!==(0,f.default)(t).prop("tagName")&&(0,f.default)(t).replaceWith((0,f.default)(t).text()+"\n")})),n.text()}},{key:"getCharactersCount",value:function(e){var t=(0,f.default)("<div>"+e+"</div>");t.find("[data-org]").each((function(e,t){(0,f.default)(t).replaceWith("0")}));var n=(0,f.default)("<div>"+t.html()+"</div>");return n.contents().each((function(e,t){(0,f.default)(t).replaceWith((0,f.default)(t).text())})),n.text().length}},{key:"isMaximumOfCharactersReached",value:function(){return this.getCharactersCount((0,f.default)(this.editableRef.current).html())>=this.props.configuration.interface.input.maxLength}},{key:"handleClick",value:function(){this.storeSelectedRange()}},{key:"handleChange",value:function(){this.triggerChange(),this.storeSelectedRange()}},{key:"handleKeyDown",value:function(e){var t=this.props.configuration.interface.input.multilineEasy,n=e.shiftKey&&!t||!e.shiftKey&&t;this.isPrintableKey(e.nativeEvent)&&this.isMaximumOfCharactersReached()&&e.nativeEvent.preventDefault(),13!==e.keyCode||n||(this.props.onSendingRequest&&this.props.onSendingRequest(),e.nativeEvent.preventDefault())}},{key:"isPrintableKey",value:function(e){return e&&e.key&&1===e.key.length}},{key:"handlePaste",value:function(e){e.preventDefault();var t="";if((e=e.nativeEvent).clipboardData||e.originalEvent.clipboardData?t=(e.originalEvent||e).clipboardData.getData("text/plain"):window.clipboardData&&(t=window.clipboardData.getData("Text")),document.queryCommandSupported("insertText")){var n=this.props.configuration.interface.input.maxLength-this.getCharactersCount((0,f.default)(this.editableRef.current).html());n>0&&(document.execCommand("insertText",!1,t.substring(0,n)),this.triggerChange(),this.storeSelectedRange())}else{var r=null;if(!window.getSelection)return void(console&&console.error("getSelection unsupported"));var i=(r=window.getSelection()).getRangeAt(0);i.deleteContents();var o=document.createTextNode(t);i.insertNode(o),i.selectNodeContents(o),i.collapse(!1),(r=window.getSelection()).removeAllRanges(),r.addRange(i),this.triggerChange(),this.storeSelectedRange()}}},{key:"storeSelectedRange",value:function(){window.getSelection?(this.selection=window.getSelection(),this.selection.rangeCount>0?(this.range=this.selection.getRangeAt(0),this.parentNode=this.range.commonAncestorContainer.parentNode):(this.range=null,this.parentNode=null,this.props.logError("No range selected"))):this.props.logError("window.getSelection is not supported")}},{key:"triggerChange",value:function(){this.props.onChange&&this.props.onChange(this.convertHTMLToMessage((0,f.default)(this.editableRef.current).html()))}},{key:"focus",value:function(){(0,f.default)(this.editableRef.current).focus()}},{key:"render",value:function(){return u.default.createElement("div",{ref:this.editableRef,className:"wcInput wp-exclude-emoji",onKeyUp:this.handleChange,onInput:this.handleChange,onKeyDown:this.handleKeyDown,onClick:this.handleClick,onTouchEnd:this.handleClick,onPaste:this.handlePaste,contentEditable:!0,"data-placeholder":this.props.placeholder})}}]),n}(u.default.Component);v.propTypes={placeholder:p.default.string,inputRequest:p.default.string.isRequired,resetRequest:p.default.bool,onCh
1ange:p.default.func,onSendingRequest:p.default.func};var g=(0,d.connect)((function(e){return{configuration:e.configuration}}),{logError:y.logError},null,{forwardRef:!0})(v);n.default=g},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/log":100,jquery:244,"prop-types":256,react:307,"react-dom/server":269,"react-redux":295,"utils/html-renderer":117}],50:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/messages"),h=e("actions/ui"),m=r(e("./Attachments")),y=r(e("./EmoticonsPopup")),b=r(e("ui/common/plain/Decorator")),v=r(e("./HtmlInput")),g=r(e("ui/common/plain/ProgressBar")),w=r(e("./SoundInput"));function C(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var _=function(e){(0,s.default)(n,e);var t=C(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={message:"",messageChunk:"",imageSource:void 0,fileSource:void 0,attachmentsProcessing:void 0,attachments:[]},r.inputRef=u.default.createRef(),r.sendMessage=r.sendMessage.bind((0,a.default)(r)),r.handleFileChange=r.handleFileChange.bind((0,a.default)(r)),r.handleImageChange=r.handleImageChange.bind((0,a.default)(r)),r.handleSoundInputChange=r.handleSoundInputChange.bind((0,a.default)(r)),r.handleEmoticonSelect=r.handleEmoticonSelect.bind((0,a.default)(r)),r.handleCancelReplyTo=r.handleCancelReplyTo.bind((0,a.default)(r)),r.handleHtmlInputChange=r.handleHtmlInputChange.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.postedMessage!==e.postedMessage&&!0===this.props.postedMessage.success,n=this.props.postedMessage!==e.postedMessage&&!1===this.props.postedMessage.success,r=this.props.uiChannel!==e.uiChannel&&this.props.uiChannel&&e.uiChannel&&this.props.uiChannel.inputAppend!==e.uiChannel.inputAppend,i=this.props.replyTo!==e.replyTo&&this.props.replyTo;t&&(this.setState({attachments:[]}),this.props.cancelMessageReplyTo(this.props.channel.id),this.props.postedMessage.result&&this.props.postedMessage.result.message&&!0===this.props.postedMessage.result.message.hidden&&this.props.toastInfo(this.props.i18n.approvalWarning)),n&&this.props.alertError(this.props.postedMessage.error?this.props.postedMessage.error:"Error #i1"),r&&this.setState({messageChunk:this.props.uiChannel.inputAppend}),i&&this.inputRef.focus()}},{key:"sendMessage",value:function(e){(this.state.message.length>0||this.state.attachments.length>0)&&(this.props.sendMessage(this.state.message,this.state.attachments,{replyToMessageId:this.props.replyTo},this.props.channel.id),this.setState({message:""}))}},{key:"handleFileChange",value:function(e){this.setState({fileSource:e.target.files.length>0?[e.target.files[0]]:[]},(function(){e.target.value=""}))}},{key:"handleImageChange",value:function(e){this.setState({imageSource:e.target.files.length>0?[e.target.files[0]]:[]},(function(){e.target.value=""}))}},{key:"handleSoundInputChange",value:function(e){this.setState({soundSource:e})}},{key:"handleEmoticonSelect",value:function(e){this.setState({messageChunk:e})}},{key:"handleHtmlInputChange",value:function(e){this.setState({message:e,messageChunk:""})}},{key:"handleCancelReplyTo",value:function(e){e.preventDefault(),this.props.cancelMessageReplyTo(this.props.channel.i
1d)}},{key:"render",value:function(){var e=this;if("direct"===this.props.channel.type&&this.props.channel.readOnly)return u.default.createElement("div",{className:"wcChannelInput"},u.default.createElement("div",{className:"wcReadOnlyDirectChannel wcErrorBox"},u.default.createElement(b.default,null,this.props.i18n.notAllowedToSendDirectMessages)));if(["public","private"].includes(this.props.channel.type)&&this.props.channel.readOnly)return null;var t=this.props.replyTo&&this.props.channelMessages?this.props.channelMessages.find((function(t){return t.id===e.props.replyTo})):void 0;return u.default.createElement("div",{className:"wcChannelInput"},this.props.configuration.interface.input.userName&&!t&&u.default.createElement("div",{className:"wcCurrentUserName"},this.props.application.user.name,":"),t&&u.default.createElement("div",{className:"wcReplyTo"},u.default.createElement("div",{className:"wcName"},this.props.i18n.replyingTo," ",t.sender.name),u.default.createElement("div",{className:"wcContent"},u.default.createElement(b.default,null,t.text)),u.default.createElement("a",{className:"wcDeleteButton wcFunctional",onClick:this.handleCancelReplyTo})),u.default.createElement("div",{className:"wcInputs"},u.default.createElement(v.default,{ref:function(t){return e.inputRef=t},placeholder:this.props.postedMessage.inProgress?this.props.i18nBase.sending:this.props.i18nBase.hint,inputRequest:this.state.messageChunk,resetRequest:""===this.state.message,onChange:this.handleHtmlInputChange,onSendingRequest:this.sendMessage}),u.default.createElement("div",{className:"wcInputButtons"},this.props.configuration.interface.input.emoticons.enabled&&u.default.createElement(y.default,{onSelect:this.handleEmoticonSelect}),this.props.configuration.interface.input.sounds.enabled&&this.props.channel.configuration.enableVoiceMessages&&u.default.createElement(w.default,{channel:this.props.channel,onChange:this.handleSoundInputChange,onStartProcessing:function(){return e.setState({attachmentsProcessing:e.props.i18n.attachingVoiceMessage})},onCompleteProcessing:function(){return e.setState({attachmentsProcessing:void 0})}}),this.props.configuration.interface.input.images.enabled&&this.props.channel.configuration.enableImages&&u.default.createElement("div",{className:"wcInputButton wcImageAttachment",title:this.props.i18n.uploadPicture},u.default.createElement("input",{type:"file",accept:"image/*;capture=camera",title:this.props.i18n.uploadPicture,onChange:this.handleImageChange})),this.props.configuration.interface.input.attachments.enabled&&this.props.channel.configuration.enableAttachments&&u.default.createElement("div",{className:"wcInputButton wcFileAttachment",title:this.props.i18n.attachFile},u.default.createElement("input",{type:"file",accept:this.props.configuration.interface.input.attachments.extensionsList,title:this.props.i18n.attachFile,onChange:this.handleFileChange})),this.props.configuration.interface.input.submit&&u.default.createElement("button",{className:"wcButton wcSubmit",onClick:this.sendMessage,disabled:this.props.postedMessage.inProgress},this.props.i18nBase.send))),this.state.attachments.length>0&&u.default.createElement(g.default,{visible:this.props.postedMessage.inProgress,progress:this.props.postedMessage.progress}),u.default.createElement(m.default,{processingMessage:this.state.attachmentsProcessing,channel:this.props.channel,imageSource:this.state.imageSource,fileSource:this.state.fileSource,soundSource:this.state.soundSource,attachments:this.state.attachments,onChange:function(t){return e.setState({attachments:t})}}))}}]),n}(u.default.Component);_.propTypes={channel:p.default.object.isRequired,configuration:p.default.object.isRequired,channelMessages:p.default.array,postedMessage:p.default.object,replyTo:p.default.string};var k=(0,f.connect)((function(e,t){return{configuration:e.configuration,application:e.application,i18nBase:e.configuration.i18n,i18n:e.application.i18n,channelMessages:e.messages.received[t.channel.id],postedMessage:e.messages.posted[t.channel.id]||{},uiChannel:e.ui.channels[t.channel.id],replyTo:e.ui.replyToMessages[t.channel.i
1d]}}),{sendMessage:d.sendMessage,alertError:h.alertError,alertInfo:h.alertInfo,toastInfo:h.toastInfo,toastError:h.toastError,cancelMessageReplyTo:h.cancelMessageReplyTo})(_);n.default=k},{"./Attachments":47,"./EmoticonsPopup":48,"./HtmlInput":49,"./SoundInput":51,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/messages":101,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"ui/common/plain/Decorator":79,"ui/common/plain/ProgressBar":80}],51:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/messages"),h=e("actions/ui"),m=e("actions/log");function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var b=function(e){(0,s.default)(n,e);var t=y(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={recording:!1,time:0},r.startRecording=r.startRecording.bind((0,a.default)(r)),r.stopRecording=r.stopRecording.bind((0,a.default)(r)),r.initMedia=r.initMedia.bind((0,a.default)(r)),r.timerCount=r.timerCount.bind((0,a.default)(r)),r.renderTimer=r.renderTimer.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"componentWillUnmount",value:function(){this.clearTimer()}},{key:"initMedia",value:function(e){var t=this;this.audioContext||(this.audioContext=new AudioContext),navigator.mediaDevices.getUserMedia({audio:!0,video:!1}).then((function(n){t.gumStream=n,t.input=t.audioContext.createMediaStreamSource(n),t.recorder=new WebAudioRecorder(t.input,{workerDir:t.props.configuration.baseDir+"assets/js/libs/",encoding:"mp3",onEncoderLoading:function(e,n){t.props.logDebug("debug","Loading "+n+" encoder...")},onEncoderLoaded:function(e,n){t.props.logDebug("debug",n+" encoder loaded")}}),t.recorder.onComplete=function(e,n){t.props.logDebug("debug","Encoding complete",n),t.props.onChange({data:n,type:t.recorder.encoding}),t.props.onCompleteProcessing()},t.recorder.onTimeout=t.stopRecording,t.recorder.onError=function(e,n){t.props.alertError("Audio recorder error: "+n),t.props.logError("Audio recorder error",n),t.props.onCompleteProcessing()},t.recorder.setOptions({timeLimit:t.props.configuration.interface.input.sounds.maxLength,encodeAfterRecord:!0,mp3:{bitRate:t.props.configuration.interface.input.sounds.mp3BitRate}}),e()})).catch((function(e){t.props.alertError(t.props.i18n.noMicrophoneError),t.props.logError("Could not execute getUserMedia feature",e)}))}},{key:"startRecording",value:function(e){var t=this;e.preventDefault(),this.initMedia((function(){t.recorder.startRecording(),t.startTimer()}))}},{key:"stopRecording",value:function(){this.gumStream.getAudioTracks()[0].stop(),this.recorder.finishRecording(),this.props.onStartProcessing(),this.clearTimer()}},{key:"timerCount",value:function(){this.setState({time:this.state.time+1})}},{key:"clearTimer",value:function(){this.setState({recording:!1,time:0}),this.timer&&(clearInterval(this.timer),delete this.timer)}},{key:"startTimer",value:function(){this.setState({recording:!0,time:0}),this.timer=setInterval(this.timerCount,1e3)}},{key:"renderTimer",value:function(){var e=Math.floor(this.state.time/60),t=this.state.time%60;return e+":"+(t<10?"0":"")+t}},{key:"render",value:function(){return u.default.createElement(u.default.Fragment,null,!this.state.recording&&u.default.createElement("button",{className:"wcInputButton wcSoundAttachmentStart wcFunctional",onClick:this.startRecording}),this.state.recording&&u.default.createElement(u.default.Fragment,null,u.default.createElement("button",{className:"wcInputButton wcSoundAttachmentStop wcFunctional",onClick:this.stopRecording}),u.default.createElement("span",{className:"wcInputButtonSupplementary"},this.renderTimer())))}}]),n}(u.default.Component);b.propTypes={channel:p.default.object.isRequired,configuration:p.default.object.isRequired,onChange:p.default.func.isRequired,onStartProcessing:p.default.func.isRequired,onCompleteProcessing:p.default.func.isRequired};var v=(0,f.connect)((function(e){return{configuration:e.configuration,i18n:e.application.i18n}}),{sendMessage:d.sendMessage,prepareImage:d.prepareImage,alertError:h.alertError,logError:m.logError,logDebug:m.logDebug})(b);n.default=v},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/log":100,"actions/messages":101,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],52:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/toConsumableArray")),o=r(e("@babel/runtime/helpers/
1defineProperty")),a=r(e("@babel/runtime/helpers/classCallCheck")),s=r(e("@babel/runtime/helpers/createClass")),l=r(e("@babel/runtime/helpers/assertThisInitialized")),c=r(e("@babel/runtime/helpers/inherits")),u=r(e("@babel/runtime/helpers/possibleConstructorReturn")),p=r(e("@babel/runtime/helpers/getPrototypeOf")),f=r(e("react")),d=r(e("prop-types")),h=e("actions/integrations"),m=e("react-redux"),y=e("react-scrollbars-custom"),b=r(e("ui/common/Loader"));function v(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?v(Object(n),!0).forEach((function(t){(0,o.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):v(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,p.default)(e);if(t){var i=(0,p.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,u.default)(this,n)}}var C=function(e){(0,c.default)(n,e);var t=w(n);function n(e){var r;return(0,a.default)(this,n),(r=t.call(this,e)).state={keyword:e.keyword,items:r.prepareItems(),tags:r.prepareTags()},r.handleChange=r.handleChange.bind((0,l.default)(r)),r.triggerOnChange=r.triggerOnChange.bind((0,l.default)(r)),r.handleClear=r.handleClear.bind((0,l.default)(r)),r.handleStopScroll=r.handleStopScroll.bind((0,l.default)(r)),r.handleClick=r.handleClick.bind((0,l.default)(r)),r.handleTagClick=r.handleTagClick.bind((0,l.default)(r)),r}return(0,s.default)(n,[{key:"handleChange",value:function(e){this.props.inProgress||(this.actionsTrigger&&clearTimeout(this.actionsTrigger),this.setState((function(t){return{keyword:e.target.value}})),this.actionsTrigger=setTimeout(this.triggerOnChange,600))}},{key:"handleClear",value:function(e){e.preventDefault(),this.setState((function(e){return{keyword:""}}))}},{key:"handleStopScroll",value:function(e,t){this.state.keyword.length>0&&this.props.next&&e.scrollHeight-e.scrollTop-e.clientHeight<10&&this.props.searchNextGIFs(this.state.keyword)}},{key:"triggerOnChange",value:function(){this.state.keyword.length>0&&(this.setState((function(e){return{items:{col1:[],col2:[]}}})),this.props.searchGIFs(this.state.keyword))}},{key:"componentWillUnmount",value:function(){this.actionsTrigger&&clearTimeout(this.actionsTrigger)}},{key:"componentDidMount",value:function(){0===this.props.tags.length&&this.props.requestGIFCategories()}},{key:"prepareItems",value:function(){return this.props.results.reduce((function(e,t){var n=t.media_formats.tinygif.dims[1],r={id:t.id,src:t.media_formats.tinygif.url,description:t.content_description};return 0===e.col1height?g(g({},e),{}
1,{col1height:n,col1:[r]}):e.col1height<e.col2height?g(g({},e),{},{col1height:e.col1height+n,col1:[].concat((0,i.default)(e.col1),[r])}):g(g({},e),{},{col2height:e.col2height+n,col2:[].concat((0,i.default)(e.col2),[r])})}),{col1height:0,col2height:0,col1:[],col2:[]})}},{key:"prepareTags",value:function(){return{col1:this.props.tags.filter((function(e,t){return t%2==0})),col2:this.props.tags.filter((function(e,t){return t%2==1}))}}},{key:"componentDidUpdate",value:function(e,t,n){var r=this;this.props.results!==e.results&&this.setState((function(e){return{items:r.prepareItems()}})),this.props.tags!==e.tags&&this.setState((function(e){return{tags:r.prepareTags()}}))}},{key:"handleClick",value:function(e){var t='[img src="'.concat(e.src,'" className="wcTenorGIF"]');this.props.onClick(t)}},{key:"handleTagClick",value:function(e,t){e.preventDefault(),this.setState((function(e){return{keyword:t.searchterm}}),this.triggerOnChange)}},{key:"render",value:function(){var e=this;return f.default.createElement("div",{className:"wcTenor"},f.default.createElement("div",{className:"wcTenorSearch"},f.default.createElement("input",{type:"text",value:this.state.keyword,className:"wcControl",placeholder:this.props.i18n.messageSearch,onChange:this.handleChange}),this.state.keyword&&f.default.createElement("a",{href:"#",className:"wcClear wcFunctional",onClick:this.handleClear})),f.default.createElement(y.Scrollbar,{onScrollStop:this.handleStopScroll,noScrollX:!0,className:"wcTenorResultsContainer"},this.state.keyword.length>0&&this.props.results.length>0?f.default.createElement("div",{className:"wcTenorResults"},f.default.createElement("div",{className:"wcTenorResultsColumn"},this.state.items.col1.map((function(t,n){return f.default.createElement("img",{key:n,onClick:function(n){return e.handleClick(t)},src:t.src,alt:t.description,className:"wcFunctional"})}))),f.default.createElement("div",{className:"wcTenorResultsColumn"},this.state.items.col2.map((function(t,n){return f.default.createElement("img",{key:n,onClick:function(n){return e.handleClick(t)},src:t.src,alt:t.description,className:"wcFunctional"})})))):f.default.createElement("div",{className:"wcTenorResults"},f.default.createElement("div",{className:"wcTenorResultsColumn"},this.state.tags.col1.map((function(t,n){return f.default.createElement("a",{href:"#",key:n,onClick:function(n){return e.handleTagClick(n,t)},className:"wcFunctional"},f.default.createElement("img",{src:t.image,className:"wcFunctional"}),t.name)}))),f.default.createElement("div",{className:"wcTenorResultsColumn"},this.state.tags.col2.map((function(t,n){return f.default.createElement("a",{href:"#",key:n,onClick:function(n){return e.handleTagClick(n,t)},className:"wcFunctional"},f.default.createElement("img",{src:t.image,className:"wcFunctional"}),t.name)})))),this.props.inProgress&&f.default.createElement(b.default,{message:this.props.configuration.i18n.loading,center:!0,marginTop:10,marginBottom:10})),f.default.createElement("div",{className:"wcTenorPowered"},"Powered By Tenor"))}}]),n}(f.default.Component);C.propTypes={onClick:d.default.func.isRequired};var _=(0,m.connect)((function(e){return{configuration:e.configuration,i18n:e.application.i18n,keyword:e.integrations.tenor.search.keyword,inProgress:e.integrations.tenor.search.inProgress||e.integrations.tenor.categories.inProgress,tags:e.integrations.tenor.categories.results,results:e.integrations.tenor.search.results,next:e.integrations.tenor.search.next}}),{requestGIFCategories:h.requestGIFCategories,searchGIFs:h.searchGIFs,searchNextGIFs:h.searchNextGIFs})(C);n.default=_},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"@babel/runtime/helpers/toConsumableArray":147,"actions/integrations":99,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"ui/common/Loader":23}],53:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;
1var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/assertThisInitialized")),l=r(e("@babel/runtime/helpers/inherits")),c=r(e("@babel/runtime/helpers/possibleConstructorReturn")),u=r(e("@babel/runtime/helpers/getPrototypeOf")),p=r(e("react")),f=r(e("prop-types")),d=e("react-redux"),h=r(e("../../modal/Modal")),m=e("actions/ui"),y=e("actions/commands"),b=e("actions/application");function v(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?v(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):v(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,c.default)(this,n)}}var C=function(e){(0,l.default)(n,e);var t=w(n);function n(e,r){var i;return(0,o.default)(this,n),(i=t.call(this,e,r)).state=g({modalOpen:!1},i.getCleanState()),i.handleAdd=i.handleAdd.bind((0,s.default)(i)),i.openModal=i.openModal.bind((0,s.default)(i)),i}return(0,a.default)(n,[{key:"getCleanState",value:function(){return{name:"",type:void 0,invalidName:!1,invalidType:!1}}},{key:"handleAdd",value:function(){this.validate()&&this.props.sendUserCommand("createChannel","createChannel",{name:this.state.name,type:this.state.type})}},{key:"validate",value:function(){var e=!0;return this.state.name||(this.setState((function(e){return{invalidName:!0}})),e=!1),this.state.type||(this.setState((function(e){return{invalidType:!0}})),e=!1),e}},{key:"openModal",value:function(e){e.preventDefault(),this.setState(g({modalOpen:!0},this.getCleanState()))}},{key:"componentDidUpdate",value:function(e){var t=this.props.command!==e.command&&this.props.command&&!1===this.props.command.success,n=this.props.command!==e.command&&this.props.command&&!0===this.props.command.success;if(t&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand("createChannel")),n){this.setState({modalOpen:!1}),this.props.clearUserCommand("createChannel");var r=this.props.command.result.channel;this.props.addChannel(r),this.props.openChannel(r.id,!0),this.props.focusChannel(r.id),this.props.toastInfo(this.props.i18n.channelCreated)}}},{key:"render",value:function(){var e=this;return this.props.userRights.createChannels?p.default.createElement(p.default.Fragment,null,p.default.createElement("a",{href:"#",className:"wcFunctional "+this.props.className,title:this.props.i18n.createChannel,onClick:this.openModal},p.default.createElement("span",{className:"wcIcon wcIconPlus"}),this.props.label?this.props.i18n.createChannel:""),p.default.createElement(h.default,{open:this.state.modalOpen,onClose:function(t){return e.setState({modalOpen:!1})},title:this.props.i18n.createChannel,footer:[p.default.createElement("button",{key:"create",className:"wcButton",onClick:this.handleAdd,disabled:this.props.command&&this.props.command.inProgress},this.props.i18n.createChannel)],closable:!(this.props.command&&this.props.command.inProgress),closeOnDocumentClick:!1},p.default.createElement("div",{className:"wcFormRow"},p.default.createElement("label",null,this.props.i18n.name,": "),p.default.createElement("input",{className:"wcFormControl ".concat(this.state.invalidName?" wcFormError":""),type:"text",maxLength:200,value:this.state.name,onChange:function(t){return e.setState({name:t.target.value,invali
1dName:!1})}}),p.default.createElement("div",{className:"wcFormErrorMessage"},this.props.i18n.enterChannelName)),p.default.createElement("div",{className:"wcFormRow"},p.default.createElement("input",{className:"wcFormCheck ".concat(this.state.invalidType?" wcFormError":""),type:"radio",checked:"private"===this.state.type,value:"private",onChange:function(t){return e.setState({type:t.target.value,invalidType:!1})},name:"flexRadioDefault",id:"type1"}),p.default.createElement("label",{className:"wcFormCheckLabel",htmlFor:"type1"},this.props.i18n.privateChannel),p.default.createElement("input",{className:"wcFormCheck ".concat(this.state.invalidType?" wcFormError":""),type:"radio",checked:"public"===this.state.type,value:"public",onChange:function(t){return e.setState({type:t.target.value,invalidType:!1})},name:"flexRadioDefault",id:"type2"}),p.default.createElement("label",{className:"wcFormCheckLabel",htmlFor:"type2"},this.props.i18n.publicChannel),p.default.createElement("div",{className:"wcFormErrorMessage"},this.props.i18n.selectChannelType)),this.state.type&&p.default.createElement("div",{className:"wcFormRow"},"public"===this.state.type&&this.props.i18n.hintPublic,"private"===this.state.type&&this.props.i18n.hintPrivate))):null}}]),n}(p.default.Component);C.propTypes={configuration:f.default.object.isRequired,label:f.default.bool,className:f.default.string};var _=(0,d.connect)((function(e){return{userRights:e.application.user.rights,configuration:e.configuration,i18nBase:e.configuration.i18n,i18n:e.application.i18n,command:e.commands.sent.createChannel}}),{sendUserCommand:y.sendUserCommand,clearUserCommand:y.clearUserCommand,alertError:m.alertError,alertInfo:m.alertInfo,focusChannel:m.focusChannel,openChannel:m.openChannel,addChannel:b.addChannel,toastInfo:m.toastInfo})(C);n.default=_},{"../../modal/Modal":77,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],54:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/toConsumableArray")),o=r(e("@babel/runtime/helpers/defineProperty")),a=r(e("@babel/runtime/helpers/classCallCheck")),s=r(e("@babel/runtime/helpers/createClass")),l=r(e("@babel/runtime/helpers/assertThisInitialized")),c=r(e("@babel/runtime/helpers/inherits")),u=r(e("@babel/runtime/helpers/possibleConstructorReturn")),p=r(e("@babel/runtime/helpers/getPrototypeOf")),f=r(e("react")),d=r(e("prop-types")),h=e("react-redux"),m=r(e("../../modal/Modal")),y=e("actions/ui"),b=e("actions/commands"),v=e("actions/application"),g=e("react-scrollbars-custom"),w=r(e("./components/NotifyUsers")),C=r(e("./components/ChannelOptions"));function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){(0,o.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function S(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,p.default)(e);if(t){var i=(0,p.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,u.default)(this,n)}}var E=function(e){(0,c.default)(n,e);var t=S(n);function n(e,r){var i;return(0,a.default)(this,n),(i=t.call(this,e,r)).state=k(k({tab:"basic",modalOpen:!1},i.getCleanState()),{},{addRequests:[]}),i.handleAdd=i.handleAdd.bind((0,l.default)(i)),i.openModal=i.openM
1odal.bind((0,l.default)(i)),i.hideModal=i.hideModal.bind((0,l.default)(i)),i.deleteFromChannel=i.deleteFromChannel.bind((0,l.default)(i)),i.searchUsers=i.searchUsers.bind((0,l.default)(i)),i.renderMemberResult=i.renderMemberResult.bind((0,l.default)(i)),i.deleteChannel=i.deleteChannel.bind((0,l.default)(i)),i}return(0,s.default)(n,[{key:"switchTab",value:function(e,t){e.preventDefault(),this.setState({tab:t})}},{key:"getCleanState",value:function(){return{name:this.props.channel.name,type:this.props.channel.type,configuration:this.props.channel.configuration,invalidName:!1,invalidType:!1,newMember:""}}},{key:"handleAdd",value:function(){this.validate()&&this.props.sendUserCommand("saveChannel","saveChannel",{id:this.props.channel.id,name:this.state.name,type:this.state.type,configuration:JSON.stringify(this.state.configuration)})}},{key:"validate",value:function(){var e=!0;return this.state.name||(this.setState({invalidName:!0}),e=!1),this.state.type||(this.setState({invalidType:!0}),e=!1),e}},{key:"openModal",value:function(e){e.preventDefault(),e.stopPropagation(),this.setState(k({modalOpen:!0},this.getCleanState())),this.props.sendUserCommand("getChannelMembers","getChannelMembers",{id:this.props.channel.id})}},{key:"hideModal",value:function(){this.props.clearUserCommand("getChannelMembers"),this.setState({modalOpen:!1})}},{key:"componentDidUpdate",value:function(e){var t=this,n=this.props.command!==e.command&&this.props.command&&!1===this.props.command.success,r=this.props.command!==e.command&&this.props.command&&!0===this.props.command.success,o=this.props.deleteMember!==e.deleteMember&&this.props.deleteMember&&!1===this.props.deleteMember.success,a=this.props.deleteMember!==e.deleteMember&&this.props.deleteMember&&!0===this.props.deleteMember.success,s=this.props.deleteChannel!==e.deleteChannel&&this.props.deleteChannel&&!1===this.props.deleteChannel.success,l=this.props.deleteChannel!==e.deleteChannel&&this.props.deleteChannel&&!0===this.props.deleteChannel.success,c=this.props.inviteChannelMember!==e.inviteChannelMember&&this.props.inviteChannelMember&&!1===this.props.inviteChannelMember.success,u=this.props.inviteChannelMember!==e.inviteChannelMember&&this.props.inviteChannelMember&&!0===this.props.inviteChannelMember.success;if(n&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand("saveChannel")),r){var p=this.props.command.result.channel;p.id===this.props.channel.id&&(this.setState({modalOpen:!1}),this.props.clearUserCommand("saveChannel"),this.props.refreshChannel(p),this.props.toastInfo(this.props.i18n.channelSaved))}(o&&(this.props.alertError(this.props.deleteMember.error),this.props.clearUserCommand("deleteChannelMember")),a)&&(this.props.deleteMember.result.channel.id===this.props.channel.id&&(this.props.clearUserCommand("deleteChannelMember"),this.props.sendUserCommand("getChannelMembers","getChannelMembers",{id:this.props.channel.id}),this.props.toastInfo(this.props.i18n.memberRemoved),this.setState((function(e){return{addRequests:[]}}))));(c&&(this.props.alertError(this.props.inviteChannelMember.error),this.props.clearUserCommand("inviteChannelMember")),u)&&(this.props.inviteChannelMember.result.channel.id===this.props.channel.id&&(this.props.clearUserCommand("inviteChannelMember"),this.props.sendUserCommand("getChannelMembers","getChannelMembers",{id:this.props.channel.id}),this.props.toastInfo(this.props.i18n.invitationSent),this.setState((function(e){return{addRequests:[].concat((0,i.default)(e.addRequests),[t.props.inviteChannelMember.result.parameters.userId])}}))));if(s&&(this.props.alertError(this.props.deleteChannel.error),this.props.clearUserCommand("deleteChannel")),l){var f=this.props.deleteChannel.result.channelId;f===this.props.channel.id&&(this.props.closeChannel(f),this.props.removeChannel(f),this.props.clearUserCommand("deleteChannel"),this.props.toastInfo(this.props.i18n.channelDeleted))}}},{key:"componentWillUnmount",value:function(){this.props.clearUserCommand("getChannelMembers"),this.usersSearchTimer&&(clearTimeout(this.usersSearchTimer),this.usersSearchTimer=null)}},{key:"deleteFromChannel",value:function(e,t){e.preventDefault(),this.props.confirm(this.props.i18n.askRemoveMember,function(){this.props.sendUserCommand("deleteChannelMember","deleteChannelMember",{channelId:this.props.channel.i
1d,memberId:t.id})}.bind(this))}},{key:"inviteToChannel",value:function(e,t){e.preventDefault(),this.props.confirm(this.props.i18n.askJoin,function(){this.props.sendUserCommand("inviteChannelMember","inviteChannelMember",{channelId:this.props.channel.id,wpUserId:t.id})}.bind(this))}},{key:"deleteChannel",value:function(){this.props.confirm(this.props.i18n.askDeleteChannel,function(){this.props.sendUserCommand("deleteChannel","deleteChannel",{channelId:this.props.channel.id})}.bind(this))}},{key:"searchUsers",value:function(){this.usersSearchTimer&&(clearTimeout(this.usersSearchTimer),this.usersSearchTimer=null),this.state.newMember&&(this.usersSearchTimer=setTimeout(function(){this.searchUsersReal()}.bind(this),400))}},{key:"searchUsersReal",value:function(){this.props.sendUserCommand("searchUsers","searchUsers",{search:this.state.newMember})}},{key:"renderMemberResult",value:function(e,t){var n=this;return f.default.createElement("tr",{key:t},f.default.createElement("td",null,f.default.createElement("div",{className:"wcFlex wcFlexAlignCenter"},f.default.createElement("img",{src:e.avatarUrl,className:"wcMaxWidth2 wcFunctional",alt:"Member picture"})," ",f.default.createElement("span",null,e.name))),f.default.createElement("td",null,e.type),f.default.createElement("td",null,e.confirmed?this.props.i18n.confirmed:this.props.i18n.awaiting),f.default.createElement("td",null,f.default.createElement("a",{href:"#",className:"wcFunctional",title:this.props.i18n.deleteFromChannel,onClick:function(t){return n.deleteFromChannel(t,e)}},f.default.createElement("span",{className:"wcIcon wcIconX"}))))}},{key:"render",value:function(){var e=this;return this.props.channel.canEdit?f.default.createElement(f.default.Fragment,null,f.default.createElement("span",{className:"wcChannelEditButton wcIcon wcIconEdit",title:this.props.i18n.editChannel,onClick:this.openModal}),f.default.createElement(m.default,{open:this.state.modalOpen,onClose:this.hideModal,title:this.props.i18n.editChannel,size:"lg",footer:[f.default.createElement("button",{key:"save",className:"wcButton",onClick:this.handleAdd,disabled:this.props.command&&this.props.command.inProgress},this.props.i18n.save)],closable:!(this.props.command&&this.props.command.inProgress),closeOnDocumentClick:!1},f.default.createElement("ul",{className:"wcPrimaryTabs"},f.default.createElement("li",{className:"wcPrimaryTabItem"},f.default.createElement("a",{className:"wcPrimaryTabLink ".concat("basic"===this.state.tab?"wcPrimaryTabItemActive":""),onClick:function(t){return e.switchTab(t,"basic")},href:"#"},this.props.i18n.basic)),f.default.createElement("li",{className:"wcPrimaryTabItem"},f.default.createElement("a",{className:"wcPrimaryTabLink ".concat("participants"===this.state.tab?"wcPrimaryTabItemActive":""),onClick:function(t){return e.switchTab(t,"participants")},href:"#"},this.props.i18n.participants)),f.default.createElement("li",{className:"wcPrimaryTabItem"},f.default.createElement("a",{className:"wcPrimaryTabLink ".concat("options"===this.state.tab?"wcPrimaryTabItemActive":""),onClick:function(t){return e.switchTab(t,"options")},href:"#"},"Options")),f.default.createElement("li",{className:"wcPrimaryTabItem"},f.default.createElement("a",{className:"wcPrimaryTabLink ".concat("advanced"===this.state.tab?"wcPrimaryTabItemActive":""),onClick:function(t){return e.switchTab(t,"advanced")},href:"#"},this.props.i18n.advanced))),"basic"===this.state.tab&&f.default.createElement(f.default.Fragment,null,f.default.createElement("div",{className:"wcFormRow"},f.default.createElement("label",null,this.props.i18n.name,": "),f.default.createElement("input",{className:"wcFormControl ".concat(this.state.invalidName?" wcFormError":""),type:"text",maxLength:200,value:this.state.name,onChange:function(t){return e.setState({name:t.target.value,invalidName:!1})}}),f.default.createElement("div",{className:"wcFormErrorMessage"},this.props.i18n.enterChannelName)),f.default.createElement("div",{className:"wcFormRow"},f.default.createElement("input",{className:"wcFormCheck ".concat(this.state.invalidType?" wcFormError":""),type:"radio",checked:"private"===this.state.type,value:"private",onCh
1ange:function(t){return e.setState({type:t.target.value,invalidType:!1})},name:"flexRadioDefault",id:"type1"}),f.default.createElement("label",{className:"wcFormCheckLabel",htmlFor:"type1"},this.props.i18n.privateChannel),f.default.createElement("input",{className:"wcFormCheck ".concat(this.state.invalidType?" wcFormError":""),type:"radio",checked:"public"===this.state.type,value:"public",onChange:function(t){return e.setState({type:t.target.value,invalidType:!1})},name:"flexRadioDefault",id:"type2"}),f.default.createElement("label",{className:"wcFormCheckLabel",htmlFor:"type2"},this.props.i18n.publicChannel),f.default.createElement("div",{className:"wcFormErrorMessage"},this.props.i18n.selectChannelType)),this.state.type&&f.default.createElement("div",{className:"wcFormRow"},"public"===this.state.type&&this.props.i18n.hintPublic,"private"===this.state.type&&this.props.i18n.hintPrivate)),"participants"===this.state.tab&&f.default.createElement(f.default.Fragment,null,"public"===this.state.type&&f.default.createElement(w.default,{channel:this.props.channel}),"private"===this.state.type&&f.default.createElement(f.default.Fragment,null,f.default.createElement("div",{className:"wcFormRow"},f.default.createElement("label",null,this.props.i18n.inviteUser,": "),f.default.createElement("input",{className:"wcFormControl",type:"text",maxLength:200,value:this.state.newMember,onChange:function(t){return e.setState({newMember:t.target.value},e.searchUsers)}})),this.state.newMember&&f.default.createElement("div",{className:"wcFormRow"},f.default.createElement("label",null,this.props.i18n.foundUsers,": "),f.default.createElement("div",{className:"wcFormControlBorder wcHeight10 wcPadding1"},this.props.users&&this.props.users.inProgress&&f.default.createElement("span",{className:"wcMargin1"},this.props.i18n.searching),this.props.users&&!this.props.users.inProgress&&0===this.props.users.result.users.length&&f.default.createElement("span",{className:"wcMargin1"},this.props.i18n.noUsers),this.props.users&&this.props.users.result&&f.default.createElement(g.Scrollbar,null,this.props.users.result.users.map((function(t,n){return f.default.createElement("div",{key:n,className:"wcFlex wcFlexAlignCenter wcMargin1"},f.default.createElement("img",{src:t.avatarUrl,className:"wcMaxWidth2 wcFunctional",alt:"Member picture"})," ",f.default.createElement("span",null,t.name)," ",!e.state.addRequests.includes(t.id)&&f.default.createElement("a",{href:"#",className:"wcFunctional",title:e.props.i18n.inviteToJoin,onClick:function(n){return e.inviteToChannel(n,t)}},f.default.createElement("span",{className:"wcIcon wcIconPlus"})))}))))),f.default.createElement("div",{className:"wcFormRow"},f.default.createElement("label",null,this.props.i18n.channelMembers,": "),f.default.createElement("div",{className:"wcFormControlBorder wcHeight10 wcPadding1"},this.props.members&&this.props.members.inProgress&&f.default.createElement("span",{className:"wcMargin1"},this.props.i18nBase.loading),this.props.members&&this.props.members.result&&f.default.createElement(g.Scrollbar,null,f.default.createElement("table",{className:"wcTable"},f.default.createElement("thead",null,f.default.createElement("tr",null,f.default.createElement("th",
1null,this.props.i18n.memberName),f.default.createElement("th",null,this.props.i18n.memberType),f.default.createElement("th",null,this.props.i18n.memberStatus),f.default.createElement("th",null,this.props.i18n.memberActions))),f.default.createElement("tbody",null,this.props.members.result.members.map((function(t,n){return e.renderMemberResult(t,n)}))))))))),"options"===this.state.tab&&f.default.createElement(C.default,{channel:this.props.channel,configuration:this.state.configuration,onConfigurationChange:function(t){return e.setState((function(e){return{configuration:k(k({},e.configuration),t)}}))}}),"advanced"===this.state.tab&&f.default.createElement("div",{className:"wcFormRow"},f.default.createElement("button",{className:"wcButton wcButtonDanger",onClick:this.deleteChannel},this.props.i18n.deleteChannel),f.default.createElement("br",null),this.props.i18n.warningDelete))):null}}]),n}(f.default.Component);E.propTypes={configuration:d.default.object.isRequired,channel:d.default.object.isRequired};var T=(0,h.connect)((function(e){return{configuration:e.configuration,i18nBase:e.configuration.i18n,i18n:e.application.i18n,command:e.commands.sent.saveChannel,members:e.commands.sent.getChannelMembers,users:e.commands.sent.searchUsers,deleteMember:e.commands.sent.deleteChannelMember,inviteChannelMember:e.commands.sent.inviteChannelMember,deleteChannel:e.commands.sent.deleteChannel}}),{sendUserCommand:b.sendUserCommand,clearUserCommand:b.clearUserCommand,alertError:y.alertError,alertInfo:y.alertInfo,focusChannel:y.focusChannel,openChannel:y.openChannel,refreshChannel:v.refreshChannel,toastInfo:y.toastInfo,toastError:y.toastError,confirm:y.confirm,closeChannel:y.closeChannel,removeChannel:v.removeChannel})(E);n.default=T},{"../../modal/Modal":77,"./components/ChannelOptions":56,"./components/NotifyUsers":57,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"@babel/runtime/helpers/toConsumableArray":147,"actions/application":95,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304}],55:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=e("actions/commands"),m=e("actions/application");function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var b=function(e){(0,s.default)(n,e);var t=y(n);function n(e,r){var o;return(0,i.default)(this,n),(o=t.call(this,e,r)).handleRemove=o.handleRemove.bind((0,a.default)(o)),o}return(0,o.default)(n,[{key:"handleRemove",value:function(e){var t=this;e.preventDefault(),e.stopPropagation(),"private"===this.props.channel.type?this.props.confirm(this.props.i18n.askChannelRemoveAndQuit,null,(function(){}),[{text:this.props.i18n.removeFromList,callback:function(){return t.props.sendUserCommand("removeUserChannel","removeUserChannel",{channelId:t.props.channel.id})}},{text:this.props.i18n.quitMembership,callback:function(){return t.props.sendUserCommand("quitMembership","quitMembership",{channelId:t.props.channel.i
1d})}},{text:this.props.i18n.cancel,callback:function(){}}].filter((function(e){return e})),{buttonYes:{hidden:!0},buttonNo:{hidden:!0}}):this.props.confirm(this.props.i18n.askChannelRemove,null,(function(){}),[{text:this.props.i18n.removeFromList,callback:function(){return t.props.sendUserCommand("removeUserChannel","removeUserChannel",{channelId:t.props.channel.id})}},{text:this.props.i18n.cancel,callback:function(){}}].filter((function(e){return e})),{buttonYes:{hidden:!0},buttonNo:{hidden:!0}})}},{key:"componentDidUpdate",value:function(e){var t,n,r,i,o=this.props.removeUserChannel!==e.removeUserChannel&&this.props.removeUserChannel&&!1===this.props.removeUserChannel.success,a=this.props.removeUserChannel!==e.removeUserChannel&&this.props.removeUserChannel&&!0===this.props.removeUserChannel.success,s=this.props.quitMembership!==e.quitMembership&&this.props.quitMembership&&!1===this.props.quitMembership.success,l=this.props.quitMembership!==e.quitMembership&&this.props.quitMembership&&!0===this.props.quitMembership.success,c=(null===(t=this.props.removeUserChannel)||void 0===t||null===(n=t.result)||void 0===n?void 0:n.parameters.channelId)===this.props.channel.id,u=(null===(r=this.props.quitMembership)||void 0===r||null===(i=r.result)||void 0===i?void 0:i.parameters.channelId)===this.props.channel.id;o&&(this.props.alertError(this.props.removeUserChannel.error),this.props.clearUserCommand("removeUserChannel")),s&&(this.props.alertError(this.props.quitMembership.error),this.props.clearUserCommand("quitMembership")),a&&c&&(this.props.clearUserCommand("removeUserChannel"),this.props.closeChannel(this.props.channel.id),this.props.removeChannel(this.props.channel.id),this.props.toastInfo(this.props.i18n.channelRemovedFromList)),l&&u&&(this.props.clearUserCommand("quitMembership"),this.props.closeChannel(this.props.channel.id),this.props.removeChannel(this.props.channel.id),this.props.toastInfo(this.props.i18n.channelUnsubscribe))}},{key:"render",value:function(){return this.props.channel.canRemove?u.default.createElement("span",{className:"wcChannelEditButton wcIcon wcIconTimes",title:this.props.i18n.removeChannel,onClick:this.handleRemove}):null}}]),n}(u.default.Component);b.propTypes={channel:p.default.object.isRequired,configuration:p.default.object.isRequired};var v=(0,f.connect)((function(e){return{configuration:e.configuration,i18nBase:e.configuration.i18n,i18n:e.application.i18n,removeUserChannel:e.commands.sent.removeUserChannel,quitMembership:e.commands.sent.quitMembership}}),{sendUserCommand:h.sendUserCommand,clearUserCommand:h.clearUserCommand,alertError:d.alertError,confirm:d.confirm,closeChannel:d.closeChannel,removeChannel:m.removeChannel,toastInfo:d.toastInfo})(b);n.default=v},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],56:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/assertThisInitialized")),l=r(e("@babel/runtime/helpers/inherits")),c=r(e("@babel/runtime/helpers/possibleConstructorReturn")),u=r(e("@babel/runtime/helpers/getPrototypeOf")),p=r(e("react")),f=r(e("prop-types")),d=e("react-redux"),h=e("actions/ui"),m=e("actions/commands");e("react-scrollbars-custom");function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,c.default)(this,n)}}var b=function(e){(0,l.default)(n,e);var t=y(n);function n(e){var r;return(0,o.default)(this,n),(r=t.call(this,e)).renderCheckbox=r.renderCheckbox.bind((0,s.default)(r)),r}return(0,a.default)(n,[{key:"renderCheckbox",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=r.adminDisabled,a=void 0!==o&&o,s="This option was disabled by site administrator.";return p.default.createElement(p.default.Fragment,null,p.default.createElement("input",{className:"wcFormCheck",type:"checkbox",checked:!a&&this.props.configuration[e],disabled:a,value:"1",onChange:function(t){return n.props.onConfigurationChange((0,i.default)({},e,event.target.checked))}}),p.default.createElement("label",{className:"wcFormCheckLabel",htmlFor:"type1"},t),a&&p.default.createElement("div",null,s))}},{key:"render",value:function(){return p.default.createElement(p.default.Fragment,null,p.default.createElement("div",{className:"wcFormRow"},this.renderCheckbox("enableImages","Enable Images",{adminDisabled:!this.props.chatConfiguration.interface.input.images.enabled})),p.default.createElement("div",{className:"wcFormRow"},this.renderCheckbox("enableAttachments","Enable File Attachments",{adminDisabled:!this.props.chatConfiguration.interface.input.attachments.enabled})),p.default.createElement("div",{className:"wcFormRow"},this.renderCheckbox("enableVoiceMessages","Enable Voice Messages",{adminDisabled:!this.props.chatConfiguration.interface.input.s
1ounds.enabled})))}}]),n}(p.default.Component);b.propTypes={channel:f.default.object.isRequired,configuration:f.default.object.isRequired,onConfigurationChange:f.default.func.isRequired};var v=(0,d.connect)((function(e){return{i18nBase:e.configuration.i18n,i18n:e.application.i18n,chatConfiguration:e.configuration}}),{sendUserCommand:m.sendUserCommand,clearUserCommand:m.clearUserCommand,alertError:h.alertError,confirm:h.confirm,toastInfo:h.toastInfo})(b);n.default=v},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304}],57:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/toConsumableArray")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/assertThisInitialized")),l=r(e("@babel/runtime/helpers/inherits")),c=r(e("@babel/runtime/helpers/possibleConstructorReturn")),u=r(e("@babel/runtime/helpers/getPrototypeOf")),p=r(e("react")),f=r(e("prop-types")),d=e("react-redux"),h=e("actions/ui"),m=e("actions/commands"),y=e("react-scrollbars-custom");function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,c.default)(this,n)}}var v=function(e){(0,l.default)(n,e);var t=b(n);function n(e,r){var i;return(0,o.default)(this,n),(i=t.call(this,e,r)).state={searchPhrase:"",candidates:[]},i.renderCandidate=i.renderCandidate.bind((0,s.default)(i)),i.sendChannelNotifications=i.sendChannelNotifications.bind((0,s.default)(i)),i}return(0,a.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.sendChannelNotifications!==e.sendChannelNotifications&&this.props.sendChannelNotifications&&!1===this.props.sendChannelNotifications.success,n=this.props.sendChannelNotifications!==e.sendChannelNotifications&&this.props.sendChannelNotifications&&!0===this.props.sendChannelNotifications.success;(t&&(this.props.alertError(this.props.sendChannelNotifications.error),this.props.clearUserCommand("sendChannelNotifications")),n)&&(this.props.sendChannelNotifications.result.channelId===this.props.channel.id&&(this.props.clearUserCommand("sendChannelNotifications"),this.props.toastInfo(this.props.i18n.notificationsSent),this.setState((function(e){return{candidates:[],searchPhrase:""}}))))}},{key:"componentWillUnmount",value:function(){this.usersSearchTimer&&(clearTimeout(this.usersSearchTimer),this.usersSearchTimer=null)}},{key:"searchUsers",value:function(){this.usersSearchTimer&&(clearTimeout(this.usersSearchTimer),this.usersSearchTimer=null),this.state.searchPhrase&&(this.usersSearchTimer=setTimeout(function(){this.searchUsersReal()}.bind(this),400))}},{key:"searchUsersReal",value:function(){this.props.sendUserCommand("searchUsers","searchUsers",{search:this.state.searchPhrase})}},{key:"addToNotifyList",value:function(e,t){e.preventDefault(),this.state.candidates.find((function(e){return e.id===t.id}))||this.setState((function(e){return{candidates:[].concat((0,i.default)(e.candidates),[t])}}))}},{key:"sendChannelNotifications",value:function(){this.props.confirm(this.props.i18n.doYouWantNotify,function(){this.props.sendUserCommand("sendChannelNotifications","sendChannelNotifications",{channelId:this.props.channel.id,users:this.state.candidates.map((function(e){return e.id}))})}.bind(this))}},{key:"renderCandidate",value:function(e){return p.default.createElement("span",{key:e.id,className:"wcFlex wcFlexAlignCenter wcMargin1"},p.default.createElement("img",{src:e.avatarUrl,className:"wcMaxWidth2 wcFunctional",alt:"Member picture"})," ",p.default.createElement("span",null,e.name))}},{key:"render",value:function(){var e=this;return p.default.createElement(p.default.Fragment,null,p.default.createElement("div",{className:"wcFormRow"},this.props.i18n.notificationsIntro),p.default.createElement("div",{className:"wcFormRow"},p.default.createElement("label",null,this.props.i18n.searchUsers,": "),p.default.createElement("input",{className:"wcFormControl",type:"text",maxLength:200,value:this.state.searchPhrase,onChange:function(t){return e.setState({searchPhrase:t.target.value},e.searchUsers)}})),this.state.searchPhrase&&p.default.createElement("div",{className:"wcFormRow"},p.default.createElement("label",null,this.props.i18n.addUsersToList,": "),p.default.createElement("div",{className:"wcFormControlBorder wcHeight10 wcPadding1"},this.props.users&&this.props.users.inProgress&&p.default.createElement("span",{className:"wcMargin1"},this.props.i18n.searching),this.props.users&&!this.props.users.inProgress&&0===this.props.users.result.users.length&&p.default.createElement("span",{className:"wcMargin1"},this.props.i18n.noUsers),this.props.users&&this.props.users.result&&p.default.createElement(y.Scrollbar,null,this.props.users.result.users.map((function(t,n){return p.default.createElement("div",{key:n,className:"wcFlex wcFlexAlignCenter wcMargin1"},p.default.createElement("img",{src:t.avatarUrl,className:"wcMaxWidth2 wcFunctional",alt:"Member picture"})," ",p.default.createElement("span",null,t.name)," ",p.default.createElement("a",{href:"#",className:"wcFunctional",title:e.props.i18n.addToList,onClick:function(n){return e.addToNotifyList(n,t)}}
1,p.default.createElement("span",{className:"wcIcon wcIconPlus"})))}))))),p.default.createElement("div",{className:"wcFormRow"},p.default.createElement("label",null,this.props.i18n.sendChannelNotificationsTo,": "),p.default.createElement("div",{className:"wcFormControlBorder wcHeight4 wcPadding1"},0===this.state.candidates.length&&p.default.createElement("span",{className:"wcMargin1"},this.props.i18n.addUsers),p.default.createElement(y.Scrollbar,null,p.default.createElement("div",{className:"wcFlex wcFlexWrap"},this.state.candidates.map((function(t,n){return e.renderCandidate(t,n)})))))),this.state.candidates.length>0&&p.default.createElement("div",{className:"wcFormRow"},p.default.createElement("button",{className:"wcButton",onClick:this.sendChannelNotifications},this.props.i18nBase.send)))}}]),n}(p.default.Component);v.propTypes={channel:f.default.object.isRequired,configuration:f.default.object.isRequired};var g=(0,d.connect)((function(e){return{configuration:e.configuration,i18nBase:e.configuration.i18n,i18n:e.application.i18n,users:e.commands.sent.searchUsers,sendChannelNotifications:e.commands.sent.sendChannelNotifications}}),{sendUserCommand:m.sendUserCommand,clearUserCommand:m.clearUserCommand,alertError:h.alertError,confirm:h.confirm,toastInfo:h.toastInfo})(v);n.default=g},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"@babel/runtime/helpers/toConsumableArray":147,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304}],58:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("react-scrollbars-custom"),h=r(e("./message/Message")),m=e("actions/ui"),y=e("actions/log"),b=e("actions/messages"),v=r(e("ui/common/Loader"));function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var w=function(e){(0,s.default)(n,e);var t=g(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={autoScrollDisabled:"ascending"!==r.props.configuration.messagesOrder,autoScrollTemporaryDisabled:!1,noPastMessages:!1,messages:r.messagesToState(e.messages)},r.notificationsEnabled=!1,r.scrollRef=u.default.createRef(),r.handleScrollUpdate=r.handleScrollUpdate.bind((0,a.default)(r)),setTimeout(function(){this.notificationsEnabled=!0}.bind((0,a.default)(r)),2e3),r.handleStopScroll=r.handleStopScroll.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this,n=this.props.messages!==e.messages,r=this.props.messagesPast!==e.messagesPast&&!0===this.props.messagesPast.success&&this.props.messagesPast.result.length>0,i=this.props.messagesPast!==e.messagesPast&&!0===this.props.messagesPast.success&&0===this.props.messagesPast.result.length;if(n&&this.props.messages.length>0){var o=this.props.configuration.notifications.newMessage.mode,a=Array.isArray(e.messages)?e.messages.map((function(e){return e.id})):[],s=this.props.messages.filter((function(e){return!a.includes(e.id)&&!e.locked&&!e.own&&(""===o||"direct"===o&&"direct"===t.props.channel.type||"public"===o&&["public","private"].includes(t.props.channel.type))}));if(s.length>0&&this.notificationsEnabled){var l=!1,c=new RegExp("@"+this.props.user.n
1ame,"g");s.filter((function(e){return e.text.match(c)})).length>0&&(this.props.notify("mentioned"),l=!0),l||this.props.notify("newMessage"),this.props.channel.id!==this.props.focusedChannel&&this.props.unreadAdd(this.props.channel.id,s.length)}}n&&this.setState((function(e){return{messages:t.messagesToState(t.props.messages)}})),r&&"ascending"===this.props.configuration.messagesOrder&&this.scrollRef.current.scrollTo(0,200),i&&this.setState({noPastMessages:!0})}},{key:"messagesToState",value:function(e){return e?"ascending"!==this.props.configuration.messagesOrder?[].concat(e).reverse():e:[]}},{key:"handleStopScroll",value:function(e,t){var n=e.scrollHeight-(e.clientHeight+e.scrollTop)>.6*e.clientHeight;!this.state.noPastMessages&&this.state.messages.length>0&&(0===e.scrollTop&&"ascending"===this.props.configuration.messagesOrder&&this.props.loadPastMessages(this.props.channel.id,this.state.messages[0].id),"ascending"!==this.props.configuration.messagesOrder&&e.scrollHeight-e.scrollTop===e.clientHeight&&this.props.loadPastMessages(this.props.channel.id,this.state.messages[this.state.messages.length-1].id)),n!==this.state.autoScrollTemporaryDisabled&&this.setState({autoScrollTemporaryDisabled:n})}},{key:"handleScrollUpdate",value:function(e,t){this.state.autoScrollDisabled||this.state.autoScrollTemporaryDisabled||(t.scrollHeight!==e.scrollHeight&&this.scrollRef.current.scrollToBottom(),t.clientHeight!==e.clientHeight&&this.scrollRef.current.scrollToBottom())}},{key:"render",value:function(){var e=this;return u.default.createElement(d.Scrollbar,{ref:this.scrollRef,className:"wcMessages",onUpdate:this.handleScrollUpdate,onScrollStop:this.handleStopScroll,noScrollX:!0},"ascending"===this.props.configuration.messagesOrder&&this.props.messagesPast&&this.props.messagesPast.inProgress&&u.default.createElement(v.default,{message:this.props.configuration.i18n.loading,center:!0,marginTop:10,marginBottom:10}),this.state.messages.map((function(t,n,r){return u.default.createElement(h.default,{key:t.id,channel:e.props.channel,message:t,previousMessage:r[n-1]})})),"ascending"!==this.props.configuration.messagesOrder&&this.props.messagesPast&&this.props.messagesPast.inProgress&&u.default.createElement(v.default,{message:this.props.configuration.i18n.loading,center:!0,marginTop:10,marginBottom:10}))}}]),n}(u.default.Component);w.propTypes={configuration:p.default.object.isRequired,channel:p.default.object.isRequired,messages:p.default.array};var C=(0,f.connect)((function(e,t){return{configuration:e.configuration,user:e.application.user,focusedChannel:e.ui.focusedChannel,messages:e.messages.received[t.channel.id],messagesPast:e.messages.receivedPast[t.channel.i
1d]}}),{notify:m.notify,unreadAdd:m.unreadAdd,unreadClear:m.unreadClear,logInfo:y.logInfo,loadPastMessages:b.loadPastMessages})(w);n.default=C},{"./message/Message":63,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/log":100,"actions/messages":101,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"ui/common/Loader":23}],59:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=e("actions/commands"),m=e("actions/messages"),y=r(e("reactjs-popup"));function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var v=function(e){(0,s.default)(n,e);var t=b(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleAction=r.handleAction.bind((0,a.default)(r)),r.handleDeleteConfirmed=r.handleDeleteConfirmed.bind((0,a.default)(r)),r.handleBanConfirmed=r.handleBanConfirmed.bind((0,a.default)(r)),r.handleMuteConfirmed=r.handleMuteConfirmed.bind((0,a.default)(r)),r.handleSpamReportConfirmed=r.handleSpamReportConfirmed.bind((0,a.default)(r)),r.handleApprovalConfirmed=r.handleApprovalConfirmed.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.command!==e.command&&this.props.command&&!1===this.props.command.success,n=this.props.command!==e.command&&this.props.command&&!0===this.props.command.success;if(t&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand(this.props.message.id)),n){var r=this.props.command.result;this.props.clearUserCommand(this.props.message.id),"approveMessage"===r.command&&(2===this.props.configuration.interface.message.approvingMode?this.props.deleteMessage(r.parameters.id,r.parameters.channel.id):this.props.refreshMessage(r.parameters.id,r.parameters.channel.id)),"deleteMessage"===r.command&&this.props.deleteMessage(r.parameters.id,r.parameters.channel.id),"banUser"===r.command&&this.props.alertInfo(this.props.i18n.banConfirmed),"muteUser"===r.command&&this.props.alertInfo(this.props.i18n.muteConfirmed),"reportSpam"===r.command&&this.props.alertInfo(this.props.i18n.spamReportConfirmed)}}},{key:"handleAction",value:function(e,t){switch(e.preventDefault(),t){case"delete":this.props.confirm(this.props.i18n.deleteConfirmation,this.handleDeleteConfirmed);break;case"mute":this.props.confirm(this.props.i18n.muteConfirmation,this.handleMuteConfirmed);break;case"ban":this.props.confirm(this.props.i18n.banConfirmation,this.handleBanConfirmed);break;case"spam":this.props.confirm(this.props.i18n.spamReportConfirmation,this.handleSpamReportConfirmed);break;case"approve":this.props.configuration.interface.message.approvalConfirmation?this.props.confirm(this.props.i18n.approveConfirmation,this.handleApprovalConfirmed):this.handleApprovalConfirmed();break;case"edit":this.props.setMessageEditable(this.props.message.id);break;case"reply":this.props.setMessageReplyTo(this.props.message.id,this.props.message.channel.id)}}},{key:"handleApprovalConfirmed",value:function(){this.props.sendUserCommand(this.props.message.id,"approveMessage",{id:this.props.message.id,channel:this.props.message.channel})}},{key:"handleDeleteConfirmed",value:function(){this.props.sendUserCommand(this.props.message.id,"deleteMessage",{id:this.props.message.id,channel:this.props.message.channel})}},{key:"handleMuteConfirmed",value:function(){this.props.sendUserCommand(this.props.message.id,"muteUser",{id:this.props.message.id,channel:this.props.message.channel})}},{key:"handleBanConfirmed",value:function(){this.props.sendUserCommand(this.props.message.id,"banUser",{id:this.props.message.id,channel:this.props.message.channel})}},{key:"handleSpamReportConfirmed",value:function(){this.props.sendUserCommand(this.props.message.id,"reportSpam",{id:this.props.message.id,channel:this.props.message.channel,url:window.location.href})}},{key:"getRights",value:function(){var e=[];return this.props.message.awaitingApproval&&this.props.userRights.approveMessages&&e.push("approve"),this.props.userRights.banUsers&&e.push("ban"),(this.props.userRights.deleteMessages||this.props.message.own&&this.props.userRights.deleteOwnMessages)&&e.push("delete"),(this.props.userRights.editMessages||this.props.message.own&&this.props.userRights.editOwnMessages)&&e.push("edit"),this.props.userRights.muteUsers&&e.push("mute"),this.props.userRights.replyToMessages&&e.push("reply"),this.props.userRights.spamReport&&e.push("spam"),e}},{key:"render",value:function(){var e=this,t=this.getRights();return 0===t.length?null:u.default.createElement(u.default.Fragment,null,u.default.createElement(y.default,{trigger:u.default.createElement("button",{className:"wcActionsButton wcFunctional"+(this.props.visible?" wcActionsButtonVisible":"")}),position:"center center",closeOnDocumentClick:!0,className:"wcPopup 
1wcActionsPopup "+this.props.configuration.themeClassName,open:!1!==this.props.visible&&void 0,contentStyle:{height:40},keepTooltipInside:'.wcChannel[data-id="'+this.props.channel.id+'"]',arrow:!1},(function(n){return u.default.createElement("div",{className:"wcActions"},t.includes("approve")&&u.default.createElement("a",{href:"#",className:"wcAction wcApprove wcFunctional",onClick:function(t){return e.handleAction(t,"approve")},title:e.props.i18n.approveMessage}),t.includes("delete")&&u.default.createElement("a",{href:"#",className:"wcAction wcDelete wcFunctional",onClick:function(t){return e.handleAction(t,"delete")},title:e.props.i18n.deleteMessage}),t.includes("edit")&&u.default.createElement("a",{href:"#",className:"wcAction wcEdit wcFunctional",onClick:function(t){return e.handleAction(t,"edit")},title:e.props.i18n.editMessage}),t.includes("mute")&&u.default.createElement("a",{href:"#",className:"wcAction wcMute wcFunctional",onClick:function(t){return e.handleAction(t,"mute")},title:e.props.i18n.muteThisUser}),t.includes("ban")&&u.default.createElement("a",{href:"#",className:"wcAction wcBan wcFunctional",onClick:function(t){return e.handleAction(t,"ban")},title:e.props.i18n.banThisUser}),t.includes("spam")&&u.default.createElement("a",{href:"#",className:"wcAction wcSpam wcFunctional",onClick:function(t){return e.handleAction(t,"spam")},title:e.props.i18n.reportSpam}),t.includes("reply")&&u.default.createElement("a",{href:"#",className:"wcAction wcReply wcFunctional",onClick:function(t){return e.handleAction(t,"reply")},title:e.props.i18n.replyToMessage}))})))}}]),n}(u.default.Component);v.propTypes={channel:p.default.object.isRequired,message:p.default.object.isRequired,visible:p.default.bool.isRequired,command:p.default.object};var g=(0,f.connect)((function(e,t){return{configuration:e.configuration,i18n:e.application.i18n,userRights:e.application.user.rights,command:e.commands.sent[t.message.id]}}),{alertError:d.alertError,alertInfo:d.alertInfo,confirm:d.confirm,sendUserCommand:h.sendUserCommand,clearUserCommand:h.clearUserCommand,deleteMessage:m.deleteMessage,refreshMessage:m.refreshMessage,setMessageEditable:d.setMessageEditable,setMessageReplyTo:d.setMessageReplyTo})(v);n.default=g},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/commands":97,"actions/messages":101,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"reactjs-popup":308}],60:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux");function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var h=function(e){(0,s.default)(n,e);var t=d(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleError=r.handleError.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleError",value:function(e){e.target.src=this.props.configuration.baseDir+"/gfx/icons/user.png"}},{key:"render",value:function(){var e=this.props.message.sender;return e.avatarUrl?u.default.createElement("img",{className:"wcAvatar wcFunctional",onError:this.handleError,src:e.avatarUrl,alt:e.name}):null}}]),n}(u.default.Component);h.propTypes={message:p.default.object.isRequired};var m=(0,f.connect)((function(e){return{configuration:e.configuration}}))(h);n.default=m},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],61:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("utils/html-renderer")),h=r(e("ui/common/channel/components/streams/StreamOpenButton"));function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).onShortcodeRender=r.onShortcodeRender.bind((0,a.default)(r)),r.htmlRenderer=new d.default(e.configuration,{onShortcodeRender:r.onShortcodeRender}),r}return(0,o.default)(n,[{key:"onShortcodeRender",value:function(e,t,n){switch(e){case"video-call":var r=this.props.channels.find((function(e){return e.id===t.channelId}));if(r)return u.default.createElement(h.default,{key:n,channel:r})}return u.default.createElement("span",{key:n},"vii")}},{key:"render",value:function(){return u.default.createElement(u.default.Fragment,null,this.htmlRenderer.toHtml(this.props.children))}}]),n}(u.default.Component);y.propTypes={configuration:p.default.object.isRequired};var b=(0,f.connect)((function(e){return{configuration:e.configuration,channels:e.application.channels}}))(y);n.default=b},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"ui/common/channel/components/streams/StreamOpenButton":44,"utils/html-renderer":117}],62:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=e("actions/commands"),m=e("actions/messages"),y=r(e("jquery"));function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var v=function(e){(0,s.default)(n,e);var t=b(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleCancelEdit=r.handleCancelEdit.bind((0,a.default)(r)),r.handleSaveEdit=r.handleSaveEdit.bind((0,a.default)(r)),r.handlePaste=r.handlePaste.bind((0,a.default)(r)),r.editableRef=u.default.createRef(),r}
1return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e,t,n){var r=e.edit!==this.props.edit&&!0===this.props.edit,i=this.props.command!==e.command&&this.props.command&&!1===this.props.command.success,o=this.props.command!==e.command&&this.props.command&&!0===this.props.command.success;if(r&&((0,y.default)(this.editableRef.current).html((0,y.default)(this.props.contentRef.current).html()).focus(),document.execCommand&&document.execCommand("enableObjectResizing",null,!1)),i&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand(this.props.message.id)),o){var a=this.props.command.result;this.props.clearUserCommand(this.props.message.id),"saveMessage"===a.command&&(this.props.replaceMessage(a.message),this.props.cancelMessageEditable(this.props.message.id))}}},{key:"handleCancelEdit",value:function(e){e.preventDefault(),this.props.cancelMessageEditable(this.props.message.id)}},{key:"handleSaveEdit",value:function(e){e.preventDefault();var t=(0,y.default)(this.editableRef.current).html();this.props.sendUserCommand(this.props.message.id,"saveMessage",{id:this.props.message.id,channelId:this.props.message.channel.id,content:t})}},{key:"handlePaste",value:function(e){e.preventDefault();var t="";if((e=e.nativeEvent).clipboardData||e.originalEvent.clipboardData?t=(e.originalEvent||e).clipboardData.getData("text/plain"):window.clipboardData&&(t=window.clipboardData.getData("Text")),document.queryCommandSupported("insertText"))document.execCommand("insertText",!1,t);else{var n=null;if(!window.getSelection)return void(console&&console.error("getSelection unsupported"));var r=(n=window.getSelection()).getRangeAt(0);r.deleteContents();var i=document.createTextNode(t);
1r.insertNode(i),r.selectNodeContents(i),r.collapse(!1),(n=window.getSelection()).removeAllRanges(),n.addRange(r)}}},{key:"render",value:function(){return this.props.edit?u.default.createElement(u.default.Fragment,null,u.default.createElement("div",{ref:this.editableRef,className:"wcInternalEditing",contentEditable:this.props.edit,onPaste:this.handlePaste}),this.props.edit&&u.default.createElement("div",{className:"wcEditTools"},u.default.createElement("a",{href:"#",className:"wcFunctional wcCancelButton",title:"Cancel",onClick:this.handleCancelEdit}),u.default.createElement("a",{href:"#",className:"wcFunctional wcSaveButton",title:"Save the message",onClick:this.handleSaveEdit}))):null}}]),n}(u.default.Component);v.propTypes={configuration:p.default.object.isRequired,message:p.default.object.isRequired,i18n:p.default.object.isRequired,i18nBase:p.default.object,edit:p.default.bool,contentRef:p.default.object,command:p.default.object};var g=(0,f.connect)((function(e,t){return{configuration:e.configuration,i18n:e.application.i18n,i18nBase:e.configuration.i18n,edit:e.ui.editableMessages[t.message.id],command:e.commands.sent[t.message.id]}}),{cancelMessageEditable:d.cancelMessageEditable,sendUserCommand:h.sendUserCommand,clearUserCommand:h.clearUserCommand,alertError:d.alertError,replaceMessage:m.replaceMessage})(v);n.default=g},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/commands":97,"actions/messages":101,"actions/ui":102,jquery:244,"prop-types":256,react:307,"react-redux":295}],63:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/assertThisInitialized")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("./Time")),h=r(e("./Sender")),m=r(e("jquery")),y=r(e("./Actions")),b=r(e("./Decorator")),v=r(e("./Edit")),g=r(e("./Quoted")),w=r(e("./Avatar")),C=r(e("./Reactions")),_=r(e("moment"));function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var S=function(e){(0,s.default)(n,e);var t=k(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={actionsVisible:!1,hover:!1},r.handleEnter=r.handleEnter.bind((0,o.default)(r)),r.handleLeave=r.handleLeave.bind((0,o.default)(r)),r.handleClick=r.handleClick.bind((0,o.default)(r)),r.isSameBatch=r.isSameBatch.bind((0,o.default)(r)),r.handleDocumentClick=r.handleDocumentClick.bind((0,o.default)(r)),r.messageRef=u.default.createRef(),r.contentRef=u.default.createRef(),r}return(0,a.default)(n,[{key:"ACTIONS_AUTO_THRESHOLD",get:function(){return 500}}]),(0,a.default)(n,[{key:"componentDidMount",value:function(){(0,m.default)(document).on("click",this.handleDocumentClick)}},{key:"componentWillUnmount",value:function(){(0,m.default)(document).off("click",this.handleDocumentClick)}},{key:"handleEnter",value:function(){(0,m.default)(this.messageRef.current).width()>this.ACTIONS_AUTO_THRESHOLD&&this.setState({actionsVisible:!0}),this.setState({hover:!0})}},{key:"handleLeave",value:function(){(0,m.default)(this.messageRef.current).width()>this.ACTIONS_AUTO_THRESHOLD&&this.setState({actionsVisible:!1}),this.setState({hover:!1})}},{key:"handleClick",value:function(e){(0,m.default)(this.messageRef.current).width()<=this.ACTIONS_AUTO_THRESHOLD&&(this.state.actionsVisible?setTimeout(function(){this.setState({actionsVisible:!1})}.bind(this),200):this.setState({actionsVisible:!0}))}},{key:"handleDocumentClick",value:function(e){0===(0,m.default)(e.target).closest(this.messageRef.current).length&&this.state.actionsVisible&&this.setState({actionsVisible:!1})}},{key:"isSameBatch",value:function(){if(!this.props.previousMessage||!this.props.previousMessage.sender||!this.props.message.sender)return!1;if(this.props.previousMessage.sender.id!==this.props.message.sender.id)return!1;var e=_.default.utc(this.props.message.timeUTC,_.default.ISO_8601),t=_.default.utc(this.props.previousMessage.timeUTC,_.default.ISO_8601);return e.isSame(t,"day")}},{key:"render",value:function(){if(this.props.message.locked)return null;var e=this.props.configuration.interface.message.reactions.enabled,t=this.props.configuration.interface.message.compact,n=this.props.userRights.editMessages||this.props.message.own&&this.props.userRights.editOwnMessages,r=["wcMessage"];return this.state.hover&&r.push("wcHover"),this.props.message.sender.current&&r.push("wcCurrentUser"),"w"===this.props.message.sender.source&&r.push("wcWpUser"),this.props.message.awaitingApproval&&r.push("wcAwaitingApproval"),this.props.message.cssClasse
1s&&r.push(this.props.message.cssClasses),this.isSameBatch()&&r.push("wcBatch"),u.default.createElement("div",{ref:this.messageRef,className:r.join(" "),onClick:this.handleClick,onMouseEnter:this.handleEnter,onMouseLeave:this.handleLeave},u.default.createElement("div",{className:"wcRowHead"},u.default.createElement(h.default,{message:this.props.message}),u.default.createElement(d.default,{timeUTC:this.props.message.timeUTC,timeVisible:!t})),u.default.createElement("div",{className:"wcRowBody"},u.default.createElement(w.default,{message:this.props.message}),u.default.createElement("div",{className:"wcContent"+(this.props.edit?" wcEditing":"")},this.props.message.quoted&&u.default.createElement(g.default,{message:this.props.message.quoted}),u.default.createElement("div",{ref:this.contentRef,className:"wcInternalContent",style:{color:this.props.message.color}},u.default.createElement(b.default,{editEnabled:n},this.props.message.text)),t&&!e&&u.default.createElement(d.default,{timeUTC:this.props.message.timeUTC,dateVisible:!1}),u.default.createElement(v.default,{message:this.props.message,contentRef:this.contentRef}),u.default.createElement(C.default,{message:this.props.message}),u.default.createElement(y.default,{channel:this.props.channel,message:this.props.message,visible:this.state.actionsVisible&&!this.props.edit}))))}}]),n}(u.default.Component);S.propTypes={configuration:p.default.object.isRequired,channel:p.default.object.isRequired,message:p.default.object.isRequired,previousMessage:p.default.object,i18n:p.default.object.isRequired,i18nBase:p.default.object,edit:p.default.bool};var E=(0,f.connect)((function(e,t){return{configuration:e.configuration,userRights:e.application.user.rights,i18n:e.application.i18n,i18nBase:e.configuration.i18n,edit:e.ui.editableMessages[t.message.id]}}))(S);n.default=E},{"./Actions":59,"./Avatar":60,"./Decorator":61,"./Edit":62,"./Quoted":64,"./Reactions":65,"./Sender":66,"./Time":67,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,jquery:244,moment:246,"prop-types":256,react:307,"react-redux":295}],64:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux"),f=r(e("./Decorator")),d=r(e("./Sender")),h=r(e("./Time")),m=r(e("./Avatar"));function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var b=function(e){(0,a.default)(n,e);var t=y(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement("div",{className:"wcQuote"},c.default.createElement("div",{className:"wcQuoteHead"},c.default.createElement(m.default,{message:this.props.message}),c.default.createElement(d.default,{message:this.props.message}),c.default.createElement(h.default,{timeUTC:this.props.message.timeUTC})),c.default.createElement("div",{className:"wcQuoteContent"},c.default.createElement(f.default,null,this.props.message.text)))}}]),n}(c.default.Component);b.propTypes={configuration:u.default.object.isRequired,message:u.default.object.isRequired};var v=(0,p.connect)((function(e){return{configuration:e.configuration}}))(b);n.default=v}
1,{"./Avatar":60,"./Decorator":61,"./Sender":66,"./Time":67,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],65:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/toConsumableArray")),a=r(e("@babel/runtime/helpers/classCallCheck")),s=r(e("@babel/runtime/helpers/createClass")),l=r(e("@babel/runtime/helpers/assertThisInitialized")),c=r(e("@babel/runtime/helpers/inherits")),u=r(e("@babel/runtime/helpers/possibleConstructorReturn")),p=r(e("@babel/runtime/helpers/getPrototypeOf")),f=r(e("react")),d=r(e("prop-types")),h=e("react-redux"),m=e("actions/ui"),y=e("actions/commands"),b=r(e("reactjs-popup")),v=r(e("./Time"));function g(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function w(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?g(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function C(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,p.default)(e);if(t){var i=(0,p.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,u.default)(this,n)}}var _=function(e){(0,c.default)(n,e);var t=C(n);function n(e){var r;return(0,a.default)(this,n),(r=t.call(this,e)).state=r.reactionsToState(e.message),r.toggleReaction=r.toggleReaction.bind((0,l.default)(r)),r.getClassName=r.getClassName.bind((0,l.default)(r)),r.isAnyReactionActive=r.isAnyReactionActive.bind((0,l.default)(r)),r}return(0,s.default)(n,[{key:"componentDidUpdate",value:function(e,t,n){this.props.message!==e.message&&this.setState({counters:this.props.message.reactions&&this.props.message.reactions.counters?this.props.message.reactions.counters:{}})}},{key:"reactionsToState",value:function(e){return{own:e.reactions&&e.reactions.own?e.reactions.own:[],counters:e.reactions&&e.reactions.counters?e.reactions.counters:{}}}},{key:"toggleReaction",value:function(e,t){e.preventDefault(),this.isActive(t)?this.deactivateReactionInState(t):this.activateReactionInState(t),this.props.sendUserCommand(this.props.message.id,"reactToMessage",{id:this.props.message.id,channel:this.props.message.channel,reactionId:t})}},{key:"activateReactionInState",value:function(e){var t=this.state.counters[e]?this.state.counters[e]+1:1,n=this.state.own.includes(e)?(0,o.default)(this.state.own):[].concat((0,o.default)(this.state.own),[e]);this.setState({counters:w(w({},this.state.counters),{},(0,i.default)({},e,t>=0?t:0)),own:n})}},{key:"deactivateReactionInState",value:function(e){var t=this.state.counters[e]?this.state.counters[e]-1:0,n=this.state.own.filter((function(t){return t!==e}));this.setState({counters:w(w({},this.state.counters),{},(0,i.default)({},e,t>=0?t:0)),own:n})}},{key:"getClassName",value:function(e){var t=["wcFunctional","wcReactionButton","wcReactionButton"+e.id];return this.isActive(e.id)&&t.push("wcReactionButtonActive"),e.class&&t.push(e.class),t.join(" ")}},{key:"isActive",value:function(e){return this.state.own.includes(e)}},{key:"isAnyReactionActive",value:function(){var e=this.props.configuration.interface.message.reactions;return this.state.own.filter((function(t){return e.list.map((function(e){return e.id})).includes(t)})).length>0}},{key:"renderCounters",value:function(){var e=this,t=this.props.configuration.interface.message.reactions.list.filter((function(t){return e.state.counters[t.id]&&e.state.counters[t.id]>0}));return 0===t.length?null:f.default.createElement("div",{className:"wcReactionsCounters"},t.map((function(t,n){return f.default.createElement("span",{key:n,className:"wcReactionCounter wcReactionCounter"+t.id+(t.class?" "+t.class:"")},f.default.createElement("span",null,e.state.counters[t.id]),t.iconSm?f.default.createElement("img",{src:t.iconSm,alt:t.action}):t.counter)})))}},{key:"render",value:function(){var e=this,t=this.props.configuration.interface.message.compact,n=this.props.configuration.interface.message.reactions;if(!n.enabled||0===n.list.length)return null;var r=n.list[0],i=function(e){return e.icon&&("icon_text"===n.buttonMode||"icon"===n.buttonMode)},o="icon_text"===n.buttonMode||"text"===n.buttonMode;return f.default.createElement(f.default.Fragment,null,this.renderCounters(),this.isAnyReactionActive()?f.default.createElement("div",{className:"wcReactionsButtons wcReactionsDeactivate"},f.default.createElement("div",{className:"wcReactionsButtonsList"},n.list.filter((function(t){return e.state.own.includes(t.id)})).filter((function(e,t){return 0===t})).map((function(t,n){return f.default.createElement("a",{key:n,href:"#",onClick:function(n){return e.toggleReaction(n,t.id)},className:e.getClassName(t)},i(t)&&f.default.createElement("img",{src:t.icon,alt:t.action})," ",o&&f.default.createElement("span",null,t.active))}))),t&&f.default.createElement(v.default,{timeUTC:this.props.message.timeUTC,dateVisible:!1})):f.default.createElement("div",{className:"wcReactionsButtons wcReactionsActivate"},f.default.createElement("div",{className:"wcReactionsButtonsList"},n.group&&n.list.length>0?f.default.createElement(b.default,{trigger:function(t){return f.default.createElement("a",{href:"#",onClick:function(t){return e.toggleReaction(t,r.id)},className:e.getClassName(r)},i(r)&&f.default.createElement("img",{src:r.icon,alt:r.action})," ",o&&f.default.createElement("span",null,r.action))}
1,position:"top center",className:"wcPopup wcReactionsPopup "+this.props.configuration.themeClassName,on:["hover","right-click"],arrow:!1,mouseEnterDelay:700},f.default.createElement("div",{className:"wcReactionsButtons"},f.default.createElement("div",{className:"wcReactionsButtonsList"},n.list.map((function(t,n){return f.default.createElement("a",{key:n,href:"#",onClick:function(n){return e.toggleReaction(n,t.id)},className:e.getClassName(t)},i(t)&&f.default.createElement("img",{src:t.icon,alt:t.action})," ",o&&f.default.createElement("span",null,t.action))}))))):f.default.createElement(f.default.Fragment,null,n.list.map((function(t,n){return f.default.createElement("a",{key:n,href:"#",onClick:function(n){return e.toggleReaction(n,t.id)},className:e.getClassName(t)},i(t)&&f.default.createElement("img",{src:t.icon,alt:t.action})," ",o&&f.default.createElement("span",null,t.action))})))),t&&f.default.createElement(v.default,{timeUTC:this.props.message.timeUTC,dateVisible:!1})))}}]),n}(f.default.Component);_.propTypes={configuration:d.default.object.isRequired,message:d.default.object.isRequired};var k=(0,h.connect)((function(e){return{configuration:e.configuration,i18n:e.configuration.i18n}}),{sendUserCommand:y.sendUserCommand,clearUserCommand:y.clearUserCommand,confirm:m.confirm,alertError:m.alertError,alertInfo:m.alertInfo})(_);n.default=k}
1,{"./Time":67,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"@babel/runtime/helpers/toConsumableArray":147,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"reactjs-popup":308}],66:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=r(e("ui/common/channel/components/Link"));function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleMentionClick=r.handleMentionClick.bind((0,a.default)(r)),r.renderMode3=r.renderMode3.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleMentionClick",value:function(e){e.preventDefault(),this.props.appendToChannelInput(this.props.message.channel.id,"@"+this.props.message.sender.name+":")}},{key:"renderMode3",value:function(e){return e.channel?u.default.createElement(h.default,{channel:e.channel,className:"wcUser",style:{color:e.color}},e.name):u.default.createElement("span",{className:"wcUser",style:{color:e.color}},e.name)}},{key:"render",value:function(){var e=this.props.configuration.interface.message.senderMode,t=this.props.message.sender;return u.default.createElement(u.default.Fragment,null,0===e&&u.default.createElement("span",{className:"wcUser",style:{color:t.color}},t.name),1===e&&t.profileUrl&&u.default.createElement("a",{href:t.profileUrl,className:"wcUser",style:{color:t.color},title:t.name,target:"_blank",rel:"noopener noreferrer nofollow"},t.name),1===e&&!t.profileUrl&&u.default.createElement("span",{className:"wcUser",style:{color:t.color}},t.name),2===e&&u.default.createElement("a",{href:"#",className:"wcUser",style:{color:t.color},title:this.props.i18n.insertIntoMessage+": @"+t.name+":",rel:"noopener noreferrer nofollow",onClick:this.handleMentionClick},t.name),3===e&&this.renderMode3(t))}}]),n}(u.default.Component);y.propTypes={configuration:p.default.object.isRequired,message:p.default.object.isRequired};var b=(0,f.connect)((function(e){return{configuration:e.configuration,i18n:e.configuration.i18n}}),{appendToChannelInput:d.appendToChannelInput})(y);n.default=b},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"ui/common/channel/components/Link":43}],67:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("moment"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var m=function(e){(0,s.default)(n,e);var t=h(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={stopRender:!1,date:void 0,time:void 0},r.formatElapsedDateAndTime=r.formatElapsedDateAndTime.bind((0,a.default)(r)),r.formatFullDateAndTime=r.formatFullDateAndTime.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"shouldComponentUpdate",value:function(e,t,n){return!this.state.stopRender&&null!==this.props.serverTimeUTC}},{key:"componentDidMount",value:function(){this.prepareDateAndTime()}},{key:"componentDidUpdate",value:function(e,t,n){this.props.serverTimeUTC!==e.serverTimeUTC&&null!==this.props.serverTimeUTC&&!this.state.stopRender&&this.prepareDateAndTime()}},{key:"prepareDateAndTime",value:function(){var e=this.props.configuration.interface.message.timeMode;if("hidden"===e)return this.setState({stopRender:!0}),null;var t=d.default.utc(this.props.timeUTC,d.default.ISO_8601),n=d.default.utc(this.props.serverTimeUTC,d.default.ISO_8601);"elapsed"===e?this.formatElapsedDateAndTime(t,n):this.formatFullDateAndTime(t,n)}},{key:"formatFullDateAndTime",value:function(e,t){var n=this.props.configuration.interface.message.timeFormat,r=this.props.configuration.interface.message.dateFormat,i=e.local(),o=t.local(),a=n&&n.length>0?i.format(n):i.format("LT");if(i.isSame(o,"day"))this.setState({stopRender:!0,time:a});else{var s=r&&r.length>0?i.format(r):i.format("L");this.setState({stopRender:!0,date:s,time:a})}}},{key:"formatElapsedDateAndTime",value:function(e,t){var n=e.local(),r
1=t.local(),i=r.diff(n),o=d.default.duration(i).asSeconds(),a=(0,d.default)(r).subtract(1,"days"),s=this.props.configuration.interface.message.timeFormat,l=this.props.configuration.interface.message.dateFormat,c=s&&s.length>0?n.format(s):n.format("LT");if(o<60)o<=0&&(o=1),this.setState({time:o+" "+this.props.i18n.secAgo});else if(o<3600)this.setState({time:parseInt(o/60)+" "+this.props.i18n.minAgo});else if(n.isSame(r,"day"))this.setState({stopRender:!0,time:c});else if(n.isSame(a,"day"))this.setState({stopRender:!0,date:this.props.i18n.yesterday,time:c});else{var u=l&&l.length>0?n.format(l):n.format("L");this.setState({stopRender:!0,date:u,time:c})}}},{key:"render",value:function(){return u.default.createElement("span",{className:"wcTime"},this.props.dateVisible&&this.state.date&&u.default.createElement("span",{className:"wcMessageTimeDate"},this.state.date),this.props.timeVisible&&this.state.time&&u.default.createElement("span",{className:"wcMessageTimeHour"},this.state.time))}}]),n}(u.default.Component);m.defaultProps={timeVisible:!0,dateVisible:!0},m.propTypes={timeVisible:p.default.bool.isRequired,dateVisible:p.default.bool.isRequired,configuration:p.default.object.isRequired,timeUTC:p.default.string.isRequired};var y=(0,f.connect)((function(e){return{configuration:e.configuration,i18n:e.configuration.i18n,serverTimeUTC:e.application.heartbeat.nowTime}}))(m);n.default=y},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,moment:246,"prop-types":256,react:307,"react-redux":295}],68:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux");function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var d=function(e){(0,a.default)(n,e);var t=f(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return this.props.configuration.interface.counter.onlineUsers?c.default.createElement("div",{className:"wcCounter"},this.props.i18n.onlineUsers,": ",this.props.onlineUsersCounter):null}}]),n}(c.default.Component);d.propTypes={configuration:u.default.object.isRequired,onlineUsersCounter:u.default.number.isRequired};var h=(0,p.connect)((function(e){return{configuration:e.configuration,onlineUsersCounter:e.application.onlineUsersCounter,i18nBase:e.configuration.i18n,i18n:e.application.i18n}}),{})(d);n.default=h},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],69:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/assertThisInitialized")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=r(e("reactjs-popup")),d=e("react-redux");function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var m=function(e){(0,s.default)(n,e);var t=h(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).handleClick=r.handleClick.bind((0,o.default)(r)),r}return(0,a.default)(n,[{key:"COLORS",get:function(){return["330000","331900","333300","193300","003300","003319","003333","001933","000033","190033","330033","330019","000000","660000","663300","666600","336600","006600","006633","006666","003366","000066","330066","660066","660033","202020","990000","994c00","999900","4c9900","009900","00994c","009999","004c99","000099","4c0099","990099","99004c","404040","cc0000","cc6600","cccc00","66cc00","00cc00","00cc66","00cccc","0066cc","0000cc","6600cc","cc00cc","cc0066","606060","ff0000","ff8000","ffff00","80ff00","00ff00","00ff80","00ffff","0080ff","0000ff","7f00ff","ff00ff","ff007f","808080","ff3333","ff9933","ffff33","99ff33","33ff33","33ff99","33ffff","3399ff","3333ff","9933ff","ff33ff","ff3399","a0a0a0","ff6666","ffb266","ffff66","b2ff66","66ff66","66ffb2","66ffff","66b2ff","6666ff","b266ff","ff66ff","ff66b2","c0c0c0","ff9999","ffcc99","ffff99","ccff99","99ff99","99ffcc","99ffff","99ccff","9999ff","cc99ff","ff99ff","ff99cc","e0e0e0","ffcccc","ffe5cc","ffffcc","e5ffcc","ccffcc","ccffe5","ccffff","cce5ff","ccccff","e5ccff","ffccff","ffcce5","ffffff"]}}]),(0,a.default)(n,[{key:"handleClick",value:function(e,t){e.preventDefault(),this.props.onSelect("#"+t)}},{key:"render",value:function(){var e=this;return u.default.createElement(f.default,{trigger:u.default.createElement("button",{className:"wcColorSelect wcFunctional",title:"Select color",style:{backgroundColor:this.props.color}}
1),position:"top center",className:"wcPopup wcColorsPopup "+this.props.configuration.themeClassName},(function(t){return u.default.createElement("div",null,e.COLORS.map((function(n,r){return u.default.createElement("a",{href:"#",key:r,title:n,onClick:function(r){e.handleClick(r,n),t()},style:{backgroundColor:"#"+n}})})))}))}}]),n}(u.default.Component);m.propTypes={onSelect:p.default.func.isRequired};var y=(0,d.connect)((function(e){return{configuration:e.configuration}}))(m);n.default=y},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"reactjs-popup":308}],70:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("./CustomizeArea"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var m=function(e){(0,s.default)(n,e);var t=h(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={visible:!1},r.togglePanel=r.togglePanel.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"togglePanel",value:function(e){e.preventDefault(),this.setState({visible:!this.state.visible})}},{key:"render",value:function(){var e=this;return this.props.user.settings.allowCustomize?u.default.createElement("div",{className:"wcCustomizations"+(this.props.visible?"":" wcInvisible"),style:{backgroundColor:this.props.configuration.defaultBackgroundColor}},u.default.createElement("a",{href:"#",className:"wcCustomizeButton wcFunctional",onClick:function(t){return e.togglePanel(t)}},this.props.i18nBase.customize),u.default.createElement(d.default,{visible:this.state.visible,onSave:function(){return e.setState({visible:!1})}})):null}}]),n}(u.default.Component);m.defaultProps={visible:!0},m.propTypes={configuration:p.default.object.isRequired,visible:p.default.bool.isRequired};var y=(0,f.connect)((function(e){return{configuration:e.configuration,user:e.application.user,i18nBase:e.configuration.i18n}}))(m);n.default=y},{"./CustomizeArea":71,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],71:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/createClass")),l=r(e("@babel/runtime/helpers/inherits")),c=r(e("@babel/runtime/helpers/possibleConstructorReturn")),u=r(e("@babel/runtime/helpers/getPrototypeOf")),p=r(e("react")),f=r(e("prop-types")),d=e("react-redux"),h=e("actions/messages"),m=e("actions/ui"),y=e("actions/commands"),b=r(e("./ColorPopup"));function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,c.default)(this,n)}}var g=function(e){(0,l.default)(n,e);var t=v(n);function n(e){var r;return(0,o.default)(this,n),(r=t.call(this,e)).state=r.mapPropsToState(),r.handlePropertySet=r.handlePropertySet.bind((0,a.default)(r)),r.handleNameSave=r.handleNameSave.bind((0,a.default)(r)),r}return(0,s.default)(n,[{key:"COMMAND_ID",get:function(){return"customize"}}
1]),(0,s.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.user!==e.user&&this.props.user,n=this.props.command!==e.command&&this.props.command&&!1===this.props.command.success,r=this.props.command!==e.command&&this.props.command&&!0===this.props.command.success;t&&!this.props.visible&&this.setState(this.mapPropsToState()),r&&(this.props.onSave&&this.props.onSave(),this.props.toastInfo(this.props.i18n.savedSettings)),n&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand(this.COMMAND_ID))}},{key:"mapPropsToState",value:function(){return{name:this.props.user.name,muteSounds:this.props.user.settings.muteSounds,emailNotifications:this.props.user.settings.enableNotifications,textColor:this.props.user.settings.textColor}}},{key:"handlePropertySet",value:function(e,t){this.setState((0,i.default)({},e,t)),this.sendProperty(e,t)}},{key:"handleNameSave",value:function(){0===this.state.name.length?this.props.alertError(this.props.i18n.enterYourUsername):this.sendProperty("name",this.state.name)}},{key:"sendProperty",value:function(e,t){this.props.sendUserCommand(this.COMMAND_ID,"setUserProperty",{property:e,value:t})}},{key:"render",value:function(){var e=this;return this.props.visible?p.default.createElement("div",{className:"wcCustomizationsPanel"},this.props.user.settings.allowChangeUserName&&p.default.createElement("div",{className:"wcProperty"},p.default.createElement("label",null,this.props.i18n.name,": ",p.default.createElement("input",{className:"wcControl wcUserName",type:"text",maxLength:this.props.configuration.interface.customization.userNameLengthLimit,value:this.state.name,onChange:function(t){return e.setState({name:t.target.value})}})),p.default.createElement("button",{className:"wcButton wcUserNameApprove",type:"button",onClick:this.handleNameSave},this.props.i18n.save)),this.props.user.settings.allowMuteSound&&p.default.createElement("div",{className:"wcProperty"},p.default.createElement("label",null,this.props.i18n.muteSounds,p.default.createElement("input",{className:"wcMuteSound",type:"checkbox",checked:this.state.muteSounds,onChange:function(t){return e.handlePropertySet("muteSounds",t.target.checked)}}))),this.props.user.settings.allowControlUserNotifications&&p.default.createElement("div",{className:"wcProperty"},p.default.createElement("label",null,this.props.i18n.enableNotifications,p.default.createElement("input",{className:"wcEnableNotifications",type:"checkbox",checked:this.state.emailNotifications,onChange:function(t){return e.handlePropertySet("emailNotifications",t.target.checked)}}))),this.props.user.settings.allowChangeTextColor&&p.default.createElement("div",{id:"color",className:"wcProperty"},p.default.createElement("label",null,this.props.i18n.textColor,": "),p.default.createElement(b.default,{color:this.state.textColor,onSelect:function(t){return e.handlePropertySet("textColor",t)}}),p.default.createElement("button",{className:"wcButton wcTextColorReset",type:"button",onClick:function(t){return e.handlePropertySet("textColor",null)}},this.props.i18n.reset))):null}}]),n}(p.default.Component);g.propTypes={configuration:f.default.object.isRequired,visible:f.default.bool.isRequired,onSave:f.default.func};var w=(0,d.connect)((function(e){return{configuration:e.configuration,user:e.application.user,i18n:e.application.i18n,i18nBase:e.configuration.i18n,command:e.commands.sent.customize}}),{sendMessage:h.sendMessage,alertError:m.alertError,alertInfo:m.alertInfo,toastInfo:m.toastInfo,sendUserCommand:y.sendUserCommand,clearUserCommand:y.clearUserCommand})(g);n.default=w},{"./ColorPopup":69,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/commands":97,"actions/messages":101,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],72:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=e("react-redux"),f=e("react-scrollbars-custom"),d=e("actions/ui"),h=e("actions/application"),m=e("actions/commands"),y=e("utils/string"),b=r(e("ui/common/channel/messages/message/Time")),v=r(e("prop-types")),g=r(e("ui/common/Loader"));function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var C=function(e){(0,s.default)(n,e);var t=w(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={},r.handleClick=r.handleClick.bind((0,a.default)(r)),r.renderEntry=r.renderEntry.bind((0,a.default)(r)),r.handleStopScroll=r.handleStopScroll.bind((0,a.default)(r)),r}
1return(0,o.default)(n,[{key:"componentDidMount",value:function(){this.props.clearUserCommand("userFeed")}},{key:"componentDidUpdate",value:function(e){var t,n,r,i,o,a,s=this.props.command!==e.command&&this.props.command&&!1===this.props.command.success,l=this.props.addMember!==e.addMember&&this.props.addMember&&!1===this.props.addMember.success,c=this.props.addMember!==e.addMember&&this.props.addMember&&!0===this.props.addMember.success,u=(null===(t=this.props.confirmChannelMembership)||void 0===t?void 0:t.success)!==(null===(n=e.confirmChannelMembership)||void 0===n?void 0:n.success)&&!1===(null===(r=this.props.confirmChannelMembership)||void 0===r?void 0:r.success),p=(null===(i=this.props.confirmChannelMembership)||void 0===i?void 0:i.success)!==(null===(o=e.confirmChannelMembership)||void 0===o?void 0:o.success)&&!0===(null===(a=this.props.confirmChannelMembership)||void 0===a?void 0:a.success),f=this.props.addUserChannel!==e.addUserChannel&&this.props.addUserChannel&&!1===this.props.addUserChannel.success,d=this.props.addUserChannel!==e.addUserChannel&&this.props.addUserChannel&&!0===this.props.addUserChannel.success,h=this.props.getFeed!==e.getFeed&&this.props.getFeed&&!0===this.props.getFeed.success;if(s&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand("userFeed")),l&&(this.props.alertError(this.props.addMember.error),this.props.clearUserCommand("addChannelMember")),c&&(this.props.clearUserCommand("addChannelMember"),this.props.toastInfo(this.props.i18n.userAddedToChannel)),u&&(this.props.alertError(this.props.confirmChannelMembership.error),this.props.clearUserCommand("confirmChannelMembership")),p){var m=this.props.confirmChannelMembership.result.channel;this.props.addChannel(m),this.props.openChannel(m.id),this.props.focusChannel(m.id),this.props.clearUserCommand("confirmChannelMembership"),this.props.toastInfo(this.props.i18n.youJoinedChannel)}if(f&&(this.props.alertError(this.props.addUserChannel.error),this.props.clearUserCommand("addUserChannel")),d){var y=this.props.addUserChannel.result.channel;this.props.addChannel(y),this.props.openChannel(y.id),this.props.focusChannel(y.id),this.props.clearUserCommand("addUserChannel"),this.props.toastInfo(this.props.i18n.addedChannelToList)}h&&(0===this.props.getFeed.result.feed.length?this.setState({noPastMessages:!0}):this.props.mergeFeed(this.props.getFeed.result.feed))}},{key:"handleClick",value:function(e){switch(this.markAsSeen(e),e.type){case"channels.member.join.request":this.props.confirm(this.props.i18n.askToAcceptRequest,function(){this.props.sendUserCommand("addChannelMember","addChannelMember",{channelId:e.channel.i
1d,userId:e.user.id})}.bind(this));break;case"channels.member.invitation":this.props.confirm(this.props.i18n.askToAcceptInvitation,function(){this.props.sendUserCommand("confirmChannelMembership","confirmChannelMembership",{channelId:e.channel.id})}.bind(this));break;case"channels.notification":this.props.channels.find((function(t){return t.id===e.channel.id}))?(this.props.openChannel(e.channel.id),this.props.focusChannel(e.channel.id)):this.props.sendUserCommand("addUserChannel","addUserChannel",{channelId:e.channel.id})}}},{key:"markAsSeen",value:function(e){e.seen||(this.props.markFeedEntryAsSeen(e.id),this.props.sendUserCommand("userFeed","markFeedEntryAsSeen",{id:e.id}))}},{key:"renderEntry",value:function(e,t,n){var r=this;return u.default.createElement("div",{key:e.id,className:"wcRecent "+(e.seen?"wcRead":"wcUnread")+(0===t?" wcFirst":"")+(t+1===n.length?" wcLast":""),onClick:function(t){return r.handleClick(e)}},u.default.createElement("div",{className:"wcRight"},u.default.createElement("div",{className:"wcHead"},u.default.createElement("span",{className:"wcName"},this.renderTitle(e)),u.default.createElement(b.default,{timeUTC:e.created}))))}},{key:"renderTitle",value:function(e){switch(e.type){case"channels.notification":return u.default.createElement(u.default.Fragment,null,this.props.i18n.askToVisit," ",u.default.createElement("strong",null,e.channel?e.channel.name:this.props.i18n.unknown));case"channels.member.added":return u.default.createElement(u.default.Fragment,null,this.props.i18n.addedToChannel," ",u.default.createElement("strong",null,e.channel?e.channel.name:this.props.i18n.unknown));case"channels.member.invitation":return u.default.createElement(u.default.Fragment,null,this.props.i18n.askedToJoin," ",u.default.createElement("strong",null,e.channel?e.channel.name:this.props.i18n.unknown));case"channels.member.deleted":return u.default.createElement(u.default.Fragment,null,this.props.i18n.removedFromChannel," ",u.default.createElement("strong",null,e.channel?e.channel.name:this.props.i18n.unknown));case"channels.member.join.request":return u.default.createElement(u.default.Fragment,null,(0,y.sprintf)(this.props.i18n.userRequestsToJoin,e.user?e.user.name:this.props.i18n.unknown)," ",u.default.createElement("strong",null,e.channel?e.channel.name:this.props.i18n.unknown));default:return e.type}}},{key:"handleStopScroll",value:function(e){!this.state.noPastMessages&&this.props.userFeed.length>0&&e.scrollHeight-e.scrollTop===e.clientHeight&&this.props.sendUserCommand("getFeed","getFeed",{lastId:this.props.userFeed[this.props.userFeed.length-1].id})}},{key:"render",value:function(){var e,t=this;return u.default.createElement("div",{className:"wcRecentContainer"+(this.props.visible?"":" wcInvisible")},this.props.userFeed.length>0?u.default.createElement(f.Scrollbar,{onScrollStop:this.handleStopScroll,noScrollX:!0},this.props.userFeed.map((function(e,n,r){return t.renderEntry(e,n,r)})),!0===(null===(e=this.props.getFeed)||void 0===e?void 0:e.inProgress)&&u.default.createElement(g.default,{message:this.props.i18nBase.loading,center:!0,marginTop:10,marginBottom:10})):u.default.createElement("span",{className:"wcNoRecent"},this.props.i18n.feedEmpty))}}]),n}(u.default.Component);C.propTypes={visible:v.default.bool};var _=(0,p.connect)((function(e){return{i18n:e.application.i18n,i18nBase:e.configuration.i18n,configuration:e.configuration,channels:e.application.channels,userFeed:e.application.userFeed,command:e.commands.sent.userFeed,ignoredChannels:e.ui.ignoredChannels,addMember:e.commands.sent.addChannelMember,confirmChannelMembership:e.commands.sent.confirmChannelMembership,addUserChannel:e.commands.sent.addUserChannel,getFeed:e.commands.sent.getFeed}}),{markFeedEntryAsSeen:h.markFeedEntryAsSeen,mergeFeed:h.mergeFeed,alertError:d.alertError,sendUserCommand:m.sendUserCommand,clearUserCommand:m.clearUserCommand,confirm:d.confirm,toastInfo:d.toastInfo,toastError:d.toastError,focusChannel:d.focusChannel,openChannel:d.openChannel,addChannel:h.addChannel})(C);n.default=_},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"ui/common/Loader":23,"ui/common/channel/messages/message/Time":67,"utils/string":122}],73:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=e("actions/ui"),h=e("actions/application");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={isConfirmInProgress:!1},r.incomingConfirmed=r.incomingConfirmed.bind((0,a.default)(r)),r.incomingCancelled=r.incomingCancelled.bind((0,a.default)(r)),r.incomingIgnored=r.incomingIgnored.bind((0,a.default)(r)),r}
1return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this;if(this.props.incomingChats!==e.incomingChats&&this.props.incomingChats.length>0)if(this.props.configuration.interface.incoming.confirm){var n=this.props.incomingChats[0];!1!==this.state.isConfirmInProgress||this.props.openedChannels.includes(n.channelId)||(this.setState({isConfirmInProgress:!0}),this.props.confirm(n.channelName+" "+this.props.i18n.incomingAskApproval,this.incomingConfirmed,this.incomingCancelled,[{text:this.props.i18n.ignoreUser,callback:this.incomingIgnored}]),this.props.notify("newChat"))}else this.props.incomingChats.map((function(e){var n=e.channelId;t.props.openedChannels.includes(n)||(t.props.openChannel(n),t.props.configuration.interface.incoming.focus?t.props.focusChannel(n):t.props.unreadAdd(n,1),t.props.notify("newChat"))})),this.props.deleteIncomingChats(this.props.incomingChats.map((function(e){return e.channelId})))}},{key:"incomingIgnored",value:function(){this.props.ignoreChannel(this.props.incomingChats[0].channelId),this.deleteLastIncomingChat(),this.setState({isConfirmInProgress:!1})}},{key:"incomingConfirmed",value:function(){var e=this.props.incomingChats[0].channelId;this.props.openedChannels.includes(e)||this.props.openChannel(e),this.props.configuration.interface.incoming.focus?this.props.focusChannel(e):this.props.unreadAdd(e,1),this.deleteLastIncomingChat(),this.setState({isConfirmInProgress:!1})}},{key:"incomingCancelled",value:function(){this.deleteLastIncomingChat(),this.setState({isConfirmInProgress:!1})}},{key:"deleteLastIncomingChat",value:function(){this.props.incomingChats.length>0&&this.props.deleteIncomingChats([this.props.incomingChats[0].channelId])}},{key:"render",value:function(){return null}}]),n}(u.default.Component);y.propTypes={configuration:p.default.object.isRequired};var b=(0,f.connect)((function(e){return{i18n:e.application.i18n,configuration:e.configuration,incomingChats:e.application.incomingChats,openedChannels:e.ui.openedChannels}}),{focusChannel:d.focusChannel,openChannel:d.openChannel,ignoreChannel:d.ignoreChannel,deleteIncomingChats:h.deleteIncomingChats,unreadAdd:d.unreadAdd,confirm:d.confirm,notify:d.notify})(y);n.default=b},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],74:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types")),p=e("react-redux");function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var d=function(e){(0,a.default)(n,e);var t=f(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement("div",{className:"wcLoadingContainer",style:{backgroundColor:this.props.configuration.defaultBackgroundColor}},this.props.titleVisible&&this.props.configuration.interface.chat.title&&c.default.createElement("div",{className:"wcTitle"},this.props.configuration.interface.chat.title),c.default.createElement("div",{className:"wcLoading"},c.default.createElement("div",{className:"wcLoadingMessage"},this.props.configuration.i18n.loadingChat)))}}]),n}(c.default.Component);d.defaultProps={titleVisible:!0},d.propTypes={configuration:u.default.object.isRequired};var h=(0,p.connect)((function(e){return{configuration:e.configuration}}))(d);n.default=h},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295}],75:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("reactjs-popup"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var m=function(e){(0,s.default)(n,e);var t=h(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={popupOpen:!1},r.close=r.close.bind((0,a.default)(r)),r.show=r.show.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"close",value:function(){this.setState({popupOpen:!1})}},{key:"show",value:function(){this.setState({popupOpen:!0})}},{key:"render",value:function(){var e=this;return u.default.createElement("div",{className:"wcLogger",style:{backgroundColor:this.props.configuration.defaultBackgroun
1dColor}},u.default.createElement("a",{href:"#",onClick:function(t){t.preventDefault(),e.show()},className:"wcDebugLink"},"[Debug Chat (",this.props.entries.length,")]"),u.default.createElement(d.default,{className:"wcPopup wcDebugPopup "+this.props.configuration.themeClassName,open:this.state.popupOpen,modal:!0,closeOnDocumentClick:!0,onClose:this.close,contentStyle:{height:400}},u.default.createElement("div",{className:"wcDebugPopupBody"},u.default.createElement("span",null,"Debug mode error log. Select and copy the text below."),u.default.createElement("div",{className:"wcLogs"},0===this.props.entries.length?u.default.createElement("small",null,"No logs found"):"",this.props.entries.map((function(e,t){return u.default.createElement(u.default.Fragment,{key:t},u.default.createElement("small",null,u.default.createElement("strong",null,e.timestamp," [",e.level,"]")," ",e.content," ",JSON.stringify(e.details)),u.default.createElement("br",null))}))),u.default.createElement("div",{className:"wcFooter"},u.default.createElement("button",{className:"wcButton",onClick:function(t){t.preventDefault(),e.close()}},"Close")))))}}]),n}(u.default.Component);m.propTypes={configuration:p.default.object.isRequired,entries:p.default.array.isRequired};var y=(0,f.connect)((function(e){return{configuration:e.configuration,entries:e.log.entries}}))(m);n.default=y},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"reactjs-popup":308}],76:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=e("react-redux"),p=e("actions/ui"),f=e("actions/log"),d=e("actions/messages"),h=e("actions/application");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var y=function(e){(0,a.default)(n,e);var t=m(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.channelOpeningRequest!==e.channelOpeningRequest&&this.props.channelOpeningRequest,n=this.props.openChannelCommand!==e.openChannelCommand&&this.props.openChannelCommand&&!0===this.props.openChannelCommand.success;if(t){if(!this.props.configuration.interface.channel.directEnabled)return;var r=this.props.channelOpeningRequest;this.props.clearChannelOpeningRequest();var i=this.props.channels.find((function(e){return e.id===r}));if(!i)return void this.props.logError("Requested channel does not exist: "+r);this.props.ignoredChannels.includes(r)?this.props.confirm(this.props.i18n.ignoredInfo,function(){this.props.stopIgnoringChannel(r),this.props.openChannel(r),this.props.focusChannel(r)}.bind(this)):i.locked||(this.props.openChannel(r),this.props.focusChannel(r))}n&&this.props.openChannelCommand.result.messages&&(this.props.addChannel(this.props.openChannelCommand.result.channel,!0),this.props.replaceMessages(this.props.openChannelCommand.result.parameters.channelId,this.props.openChannelCommand.result.messages))}},{key:"render",value:function(){return null}}]),n}(c.default.Component),b=(0,u.connect)((function(e){return{configuration:e.configuration,i18n:e.application.i18n,channels:e.application.channels,ignoredChannels:e.ui.ignoredChannels,focusedChannel:e.ui.focusedChannel,channelOpeningRequest:e.ui.channelOpeningRequest,openChannelCommand:e.commands.sent.openChannel}}),{focusChannel:p.focusChannel,openChannel:p.openChannel,stopIgnoringChannel:p.stopIgnoringChannel,confirm:p.confirm,clearChannelOpeningRequest:p.clearChannelOpeningRequest,logError:f.logError,replaceMessages:d.replaceMessages,addChannel:h.addChannel})(y);n.default=b},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/log":100,"actions/messages":101,"actions/ui":102,react:307,"react-redux":295}],77:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("reactjs-popup"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var m=function(e){(0,s.default)(n,e);var t=h(n);function n(e,r){var o;return(0,i.default)(this,n),(o=t.call(this,e,r)).close=o.close.bind((0,a.default)(o)),o}return(0,o.default)(n,[{key:"close",value:function(e){e&&e.preventDefault(),this.props.closable&&this.props.onClose()}},{key:"render",value:function(){return u.default.createElement(u.default.Fragment,null,u.default.createElement(d.default,{open:this.props.open,className:"wcPopup 
1wcModal "+this.props.configuration.themeClassName+" wcModal-"+this.props.size+" "+this.props.className,modal:!0,nested:!0,onClose:this.props.onClose,closeOnDocumentClick:this.props.closeOnDocumentClick},u.default.createElement("div",{className:"wcModalContent"},u.default.createElement("div",{className:"wcHeader"},u.default.createElement("div",{className:"wcTitle"},this.props.title)," ",u.default.createElement("a",{href:"#",className:"wcCloseButton",title:this.props.i18n.close,onClick:this.close},"×")),u.default.createElement("div",{className:"wContent"},this.props.children),u.default.createElement("div",{className:"wcFooter"},this.props.footer,this.props.footerCloseButtonVisible&&u.default.createElement("button",{className:"wcButton",onClick:this.close},this.props.closeButtonLabel)))))}}]),n}(u.default.Component);m.defaultProps={footerCloseButtonVisible:!0,closeButtonLabel:"Cancel",footer:[],closable:!0,open:!1,closeOnDocumentClick:!0,size:"md",className:"",title:""},m.propTypes={configuration:p.default.object.isRequired,className:p.default.string.isRequired,footerCloseButtonVisible:p.default.bool.isRequired,title:p.default.string.isRequired,footer:p.default.array.isRequired,closeButtonLabel:p.default.string.isRequired,closable:p.default.bool.isRequired,closeOnDocumentClick:p.default.bool.isRequired,open:p.default.bool.isRequired,onClose:p.default.func.isRequired,size:p.default.string.isRequired};var y=(0,f.connect)((function(e){return{configuration:e.configuration,i18n:e.application.i18n}}))(m);n.default=y},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"reactjs-popup":308}],78:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=e("react-redux"),f=e("actions/ui");function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var h=function(e){(0,s.default)(n,e);var t=d(n);function n(e){var r;(0,i.default)(this,n),r=t.call(this,e);var o=[];for(var s in r.soundRefs={},e.configuration.notifications)e.configuration.notifications.hasOwnProperty(s)&&r.props.configuration.notifications[s].sound&&(o.push({event:s,file:r.props.configuration.notifications[s].sound}),r.soundRefs[s]=u.default.createRef());return r.state={sounds:o},r.rawTitle=document.title,r.isWindowFocused=!0,r.isTitleNotificationVisible=!1,r.notificationNumber=0,r.handleBlur=r.handleBlur.bind((0,a.default)(r)),r.handleFocus=r.handleFocus.bind((0,a.default)(r)),r.showTitleNotificationAnimStep1=r.showTitleNotificationAnimStep1.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"componentDidMount",value:function(){window.addEventListener("blur",this.handleBlur),window.addEventListener("focus",this.handleFocus)}},{key:"componentWillUnmount",value:function(){window.removeEventListener("blur",this.handleBlur),window.removeEventListener("focus",this.handleFocus)}},{key:"componentDidUpdate",value:function(e){this.props.notifications!==e.notifications&&this.props.notifications.length>0&&(this.handleNotifications(),this.props.clearNotifications())}},{key:"showTitleNotification",value:function(){this.isTitleNotificationVisible||(this.isTitleNotificationVisible=!0,this.rawTitle=document.title),this.notificationNumber++,document.title="("+this.notificationNumber+") (!) "+this.rawTitle,setTimeout(this.showTitleNotificationAnimStep1,1500)}},{key:"showTitleNotificationAnimStep1",value:function(){this.isTitleNotificationVisible&&(document.title="("+this.notificationNumber+") "+this.rawTitle)}},{key:"hideTitleNotification",value:function(){this.isTitleNotificationVisible&&(document.title=this.rawTitle,this.isTitleNotificationVisible=!1,this.notificationNumber=0)}},{key:"handleBlur",value:function(){this.isWindowFocused=!1}},{key:"handleFocus",value:function(){this.isWindowFocused=!0,this.hideTitleNotification()}},{key:"handleNotifications",value:function(){var e=this;this.props.notifications.map((function(t){switch(t.event){case"newMessage":e.notifyNewMessage();break;default:e.playSound(t.event)}}))}},{key:"notifyNewMessage",value:function(){this.props.configuration.notifications.newMessage.title&&!this.isWindowFocused&&this.showTitleNotification(),this.isWindowFocused||this.playSound("newMessage")}},{key:"playSound",value:function(e){!this.props.user.settings.muteSounds&&this.soundRefs[e]&&this.soundRefs[e].current.play&&this.soundRefs[e].current.play()}},{key:"render",value:function(){var e=this;return u.default.createElement(u.default.Fragment,null,this.state.sounds.map((function(t){return u.default.createElement("audio",{key:t.event,ref:e.soundRefs[t.event],preload:"auto","data-event":t.event},u.default.createElement("source",{src:e.props.configuration.baseDir+"sounds/"+t.file+".wav",type:"audio/x-wav"}),u.default.createElement("source",{src:e.props.configuration.baseDir+"sounds/"+t.file+".mp3",type:"audio/ogg"}),u.default.createElement("source",{src:e.props.configuration.baseDir+"sounds/"+t.file+".ogg",type:"audio/mpeg"}))})))}}]),n}(u.default.Component),m=(0,p.connect)((function(e){return{configuration:e.configuration,user:e.application.user,notifications:e.ui.notifications}}),{clearNotifications:f.clearNotifications})(h);n.default=m},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/ui":102,react:307,"react-redux":295}],79:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=r(e("prop-types")),f=e("react-redux"),d=r(e("utils/html-shortcodes-renderer")),h=e("js-base64");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).onShortcodeRender=r.onShortcodeRender.bind((0,a.default)(r)),r.htmlShortcodesRenderer=new d.default(e.configuration,{onShortcodeRender:r.onShortcodeRender}),r}return(0,o.default)(n,[{key:"onShortcodeRender",value:function(e,t,n,r){switch(e){case"link":return u.default.createElement("a",{key:n,href:t.src,target:t.target,className:t.className,title:t.title,rel:"noopener noreferrer nofollow","data-org":h.Base64.encode(r)},t.name?t.name:t.src);case"img":return u.default.createElement("img",{key:n,src:t.src,className:t.className,alt:t.alt});case"span":return u.default.createElement("span",{key:n,className:t.className},t.content)}return null}},{key:"render",value:function(){return u.default.createElement(u.default.Fragment,null,this.htmlShortcodesRenderer.toHtml(this.props.children))}}]),n}(u.default.Component);y.propTypes={configuration:p.default.object.isRequired};var b=(0,f.connect)((function(e){return{configuration:e.configuration}}))(y);n.default=b},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"js-base64":245,"prop-types":256,react:307,"react-redux":295,"utils/html-shortcodes-renderer":118}],80:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=r(e("prop-types"));function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var f=function(e){(0,a.default)(n,e);var t=p(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){return c.default.createElement("progress",{className:"wcMainProgressBar ".concat(this.props.visible?"":"wcHidden"),max:"100",value:this.props.progress})}}]),n}(c.default.Component);f.defaultProps={progress:0,visible:!1}
1,f.propTypes={progress:u.default.number,visible:u.default.bool};var d=f;n.default=d},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307}],81:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=e("react-redux"),p=r(e("reactjs-popup")),f=r(e("./RecentArea")),d=r(e("prop-types"));function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var m=function(e){(0,a.default)(n,e);var t=h(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}return(0,o.default)(n,[{key:"render",value:function(){if(!this.props.configuration.interface.recent.enabled||["recent-with-current","recent"].includes(this.props.configuration.interface.browser.mode))return null;var e=this.props.recentChats.filter((function(e){return!1===e.read})).length+this.props.userFeed.filter((function(e){return!1===e.seen})).length,t=this.props.recentChats.length+this.props.userFeed.length;return c.default.createElement(p.default,{trigger:function(t){return c.default.createElement("a",{className:"wcFunctional wcRecentTrigger"+(t?" wcOpen":"")},e?c.default.createElement("span",null,e):"")},position:"left center",className:"wcPopup wcRecentPopup "+this.props.configuration.themeClassName+(0===t?" wcRecentEmpty":""),on:["click"],arrow:!1,nested:!0,keepTooltipInside:this.props.keepInside},(function(e){return c.default.createElement(f.default,{onClick:e})}))}}]),n}(c.default.Component);m.defaultProps={keepInside:!0},m.propTypes={configuration:d.default.object.isRequired,keepInside:d.default.oneOfType([d.default.string,d.default.bool])};var y=(0,u.connect)((function(e){return{configuration:e.configuration,recentChats:e.application.recentChats,userFeed:e.application.userFeed}}))(m);n.default=y},{"./RecentArea":82,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"prop-types":256,react:307,"react-redux":295,"reactjs-popup":308}],82:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("react")),p=e("react-redux"),f=e("react-scrollbars-custom"),d=e("actions/ui"),h=e("actions/application"),m=e("actions/commands"),y=r(e("ui/common/channel/messages/message/Time")),b=r(e("ui/common/channel/messages/message/Decorator")),v=r(e("prop-types")),g=r(e("../feed/Feed"));function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var C=function(e){(0,s.default)(n,e);var t=w(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).state={tab:"messages"},r.handleClick=r.handleClick.bind((0,a.default)(r)),r.handleAvatarError=r.handleAvatarError.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"handleAvatarError",value:function(e){e.target.src=this.props.configuration.baseDir+"/gfx/icons/user.png"}},{key:"componentDidMount",value:function(){this.props.clearUserCommand("recent")}},{key:"componentDidUpdate",value:function(e){this.props.command!==e.command&&this.props.command&&!1===this.props.command.success&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand("recent"))}},{key:"handleClick",value:function(e){this.props.ignoredChannels.includes(e.channel.i
1d)?this.props.confirm(this.props.i18n.ignoredInfo,function(){this.props.stopIgnoringChannel(e.channel.id),this.openRecentChat(e)}.bind(this)):this.openRecentChat(e)}},{key:"openRecentChat",value:function(e){this.props.openChannel(e.channel.id),this.props.focusChannel(e.channel.id),e.read||(this.props.markRecentChatRead(e.channel.id),this.props.sendUserCommand("recent","markChannelAsRead",{channel:e.channel.id})),this.props.onClick&&this.props.onClick(e)}},{key:"renderEntry",value:function(e,t,n){var r=this;return u.default.createElement("div",{key:e.channel.id,className:"wcRecent "+(e.read?"wcRead":"wcUnread")+(0===t?" wcFirst":"")+(t+1===n.length?" wcLast":""),onClick:function(t){return r.handleClick(e)}},this.props.configuration.interface.recent.status&&u.default.createElement(u.default.Fragment,null,!0===e.channel.online?u.default.createElement("span",{className:"wcStatus wcOnline"}):u.default.createElement("span",{className:"wcStatus wcOffline"})),e.channel.avatar&&u.default.createElement("img",{src:e.channel.avatar,onError:this.handleAvatarError,className:"wcFunctional wcRecentChatAvatar",alt:e.channel.name}),u.default.createElement("div",{className:"wcRight"},u.default.createElement("div",{className:"wcHead"},u.default.createElement("span",{className:"wcName"},e.channel.name),u.default.createElement(y.default,{timeUTC:e.timeUTC})),this.props.configuration.interface.recent.excerpts&&u.default.createElement("span",{className:"wcText"},u.default.createElement(b.default,null,e.text))))}},{key:"switchTab",value:function(e,t){e.preventDefault(),this.setState({tab:t})}},{key:"render",value:function(){var e=this;if(!this.props.configuration.interface.recent.enabled)return null;var t=this.props.userFeed.length,n=this.props.userFeed.filter((function(e){return!e.seen})).length,r=this.props.recentChats.filter((function(e){return!e.read})),i=this.props.recentChats.filter((function(e){return e.read}));return u.default.createElement("div",{className:"wcRecentChats"},t>0&&u.default.createElement("div",{className:"wcPrimaryTabs"},u.default.createElement("li",{className:"wcPrimaryTabItem"},u.default.createElement("a",{className:"wcPrimaryTabLink ".concat("messages"===this.state.tab?"wcPrimaryTabItemActive":""),onClick:function(t){return e.switchTab(t,"messages")},href:"#"},r.length>0&&u.default.createElement("span",{className:"wcRedCounter"},r.length)," ",this.props.i18n.recentChats)),u.default.createElement("li",{className:"wcPrimaryTabItem"},u.default.createElement("a",{className:"wcPrimaryTabLink ".concat("feed"===this.state.tab?"wcPrimaryTabItemActive":""),onClick:function(t){return e.switchTab(t,"feed")},href:"#"},n>0&&u.default.createElement("span",{className:"wcRedCounter"},n)," ",this.props.i18n.notifications))),u.default.createElement(g.default,{visible:"feed"===this.state.tab}),u.default.createElement("div",{className:"wcRecentContainer"+("messages"!==this.state.tab?" wcInvisible":"")},this.props.recentChats.length>0?u.default.createElement(f.Scrollbar,{scrollTop:0},r.length>0&&u.default.createElement("div",{className:"wcHeader wcUnreadMessages"},this.props.i18n.unreadMessages," "),r.map((function(t,n,r){return e.renderEntry(t,n,r)})),i.length>0&&u.default.createElement("div",{className:"wcHeader wcUnreadMessages"},this.props.i18n.messagesArchive," "),i.map((function(t,n,r){return e.renderEntry(t,n,r)}))):u.default.createElement("span",{className:"wcNoRecent"},this.props.i18n.noRecentChats)))}}]),n}(u.default.Component);C.propTypes={onClick:v.default.func};var _=(0,p.connect)((function(e){return{i18n:e.application.i18n,configuration:e.configuration,channels:e.application.channels,recentChats:e.application.recentChats,userFeed:e.application.userFeed,command:e.commands.sent.recent,ignoredChannels:e.ui.ignoredChannels}}),{focusChannel:d.focusChannel,openChannel:d.openChannel,alertError:d.alertError,sendUserCommand:m.sendUserCommand,clearUserCommand:m.clearUserCommand,markRecentChatRead:h.markRecentChatRead,stopIgnoringChannel:d.stopIgnoringChannel,confirm:d.confirm})(C);n.default=_},{"../feed/Feed":72,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"react-scrollbars-custom":304,"ui/common/channel/messages/message/Decorator":61,"ui/common/channel/messages/message/Time":67}],83:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/inherits")),s=r(e("@babel/runtime/helpers/possibleConstructorReturn")),l=r(e("@babel/runtime/helpers/getPrototypeOf")),c=r(e("react")),u=e("react-redux"),p=e("actions/commands"),f=e("actions/ui"),d=e("actions/application"),h=e("actions/messages");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,s.default)(this,n)}}var y=function(e){(0,a.default)(n,e);var t=m(n);function n(){return(0,i.default)(this,n),t.apply(this,arguments)}
1return(0,o.default)(n,[{key:"componentDidUpdate",value:function(e){var t=this.props.logOffRequest!==e.logOffRequest&&this.props.logOffRequest,n=this.props.command!==e.command&&this.props.command&&!1===this.props.command.success,r=this.props.command!==e.command&&this.props.command&&!0===this.props.command.success;if(t&&this.props.sendUserCommand(this.COMMAND_ID,"logOff",{now:!0}),n&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand(this.COMMAND_ID)),r){this.props.command.result;this.props.clearUserCommand(this.COMMAND_ID),this.props.clearUI(),this.props.clearApplication(),this.props.clearMessages(),this.props.refreshAuthenticationData()}}},{key:"componentWillUnmount",value:function(){this.props.clearUserCommand(this.COMMAND_ID)}},{key:"render",value:function(){return null}},{key:"COMMAND_ID",get:function(){return"logOff"}}]),n}(c.default.Component),b=(0,u.connect)((function(e){return{command:e.commands.sent.logOff,logOffRequest:e.ui.logOffRequest}}),{alertError:f.alertError,sendUserCommand:p.sendUserCommand,clearUserCommand:p.clearUserCommand,clearUI:f.clear,clearApplication:d.clear,clearMessages:h.clear,refreshAuthenticationData:d.refreshAuthenticationData})(y);n.default=b},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/application":95,"actions/commands":97,"actions/messages":101,"actions/ui":102,react:307,"react-redux":295}],84:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/createClass")),l=r(e("@babel/runtime/helpers/inherits")),c=r(e("@babel/runtime/helpers/possibleConstructorReturn")),u=r(e("@babel/runtime/helpers/getPrototypeOf")),p=r(e("react")),f=r(e("prop-types")),d=e("react-redux"),h=e("actions/ui"),m=e("actions/commands");function y(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function b(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?y(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):y(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,c.default)(this,n)}}var g=function(e){(0,l.default)(n,e);var t=v(n);function n(e){var r;return(0,o.default)(this,n),(r=t.call(this,e)).state={processingStream:!1},r.handleChannelStreamClose=r.handleChannelStreamClose.bind((0,a.default)(r)),r.openChannelAndRequestForTwilioToken=r.openChannelAndRequestForTwilioToken.bind((0,a.default)(r)),r.getIncomingTwilioVideoStreamConfirmation=r.getIncomingTwilioVideoStreamConfirmation.bind((0,a.default)(r)),r.handleAvatarError=r.handleAvatarError.bind((0,a.default)(r)),r.declineStreamRequest=r.declineStreamRequest.bind((0,a.default)(r)),r}return(0,s.default)(n,[{key:"TOKEN_COMMAND",get:function(){return"getStreamToken"}},{key:"TOKEN_COMMAND_ID",get:function(){return"tokenRequest"}}]),(0,s.default)(n,[{key:"handleAvatarError",value:function(e){e.target.src=this.props.configuration.baseDir+"/gfx/icons/user.png"}},{key:"componentDidUpdate",value:function(e){var t=this,n=e.streamRequest!==this.props.streamRequest&&this.props.streamRequest,r=this.props.token
1RequestCommand!==e.tokenRequestCommand&&this.props.tokenRequestCommand&&!1===this.props.tokenRequestCommand.success,i=this.props.tokenRequestCommand!==e.tokenRequestCommand&&this.props.tokenRequestCommand&&!0===this.props.tokenRequestCommand.success;n&&!this.state.processingStream&&this.setState({processingStream:!0,streamRequest:b({},this.props.streamRequest)},this.handleIncomingRequest),i&&(this.props.openStream(this.state.streamRequest.id,"stream.video.twilio.room.go",this.props.tokenRequestCommand.result.stream),this.props.clearUserCommand(this.TOKEN_COMMAND_ID),this.setState({processingStream:!1,streamRequest:void 0})),r&&(this.props.alertError(this.props.tokenRequestCommand.error),this.props.clearUserCommand(this.TOKEN_COMMAND_ID),this.setState({processingStream:!1,streamRequest:void 0})),e.openedChannels!==this.props.openedChannels&&this.props.streams.filter((function(n){return n.channel&&e.openedChannels.includes(n.channel.id)&&!t.props.openedChannels.includes(n.channel.id)})).map(this.handleChannelStreamClose)}},{key:"handleIncomingRequest",value:function(){switch(this.state.streamRequest.type){case"stream.video.twilio.room.go":this.handleIncomingTwilioVideoStream();break;default:this.props.alertError("Unsupported stream request: "+this.state.streamRequest.type)}}},{key:"getIncomingTwilioVideoStreamConfirmation",value:function(){var e=this.state.streamRequest.channel;return p.default.createElement("div",{className:"wcStreamRequest"},e.avatar&&p.default.createElement("img",{src:e.avatar,onError:this.handleAvatarError,className:"wcFunctional wcAvatar",alt:e.name}),p.default.createElement("div",{className:"wcStreamCaller"},e.name),p.default.createElement("div",{className:"wcStreamIncomingText"},this.props.i18n.incomingVideoStream))}},{key:"openChannelAndRequestForTwilioToken",value:function(){var e=this.state.streamRequest.channel;this.props.openedChannels.includes(e.id)||this.props.openChannel(e.id),this.props.focusChannel(e.id),this.props.sendUserCommand(this.TOKEN_COMMAND_ID,this.TOKEN_COMMAND,this.state.streamRequest)}},{key:"declineStreamRequest",value:function(){this.setState({processingStream:!1,streamRequest:void 0})}},{key:"handleIncomingTwilioVideoStream",value:function(){this.props.confirm(this.getIncomingTwilioVideoStreamConfirmation(),void 0,this.declineStreamRequest,[{text:this.props.i18n.videoCallDecline,className:"wcDeclineButton",callback:this.declineStreamRequest,type:"link"},{text:this.props.i18n.videoCallAccept,className:"wcAcceptButton",callback:this.openChannelAndRequestForTwilioToken,type:"link"}],{title:this.props.i18n.videoCall,timeout:this.props.configuration.interface.streams.video.calls.callingTimeout,className:"wcStreamVideoConfirmation",buttonYes:{hidden:!0},buttonNo:{hidden:!0},sound:this.props.configuration.interface.streams.video.calls.incomingSound?{src:this.props.configuration.baseDir+"assets/sounds/ring01.mp3"}:void 0})}},{key:"handleChannelStreamClose",value:function(e){switch(e.type){case"stream.video.twilio.room.go":this.props.room.name===e.room&&(this.props.room.disconnect(),this.props.closeTwilioRoom()),this.props.closeStream(e.id)}}},{key:"render",value:function(){return null}}]),n}(p.default.Component);g.propTypes={configuration:f.default.object.isRequired};var w=(0,d.connect)((function(e){return{i18n:e.application.i18n,configuration:e.configuration,openedChannels:e.ui.openedChannels,streams:e.ui.streams,room:e.ui.twilio.room,streamRequest:e.ui.streamRequest,tokenRequestCommand:e.commands.sent.tokenRequest}}),{focusChannel:h.focusChannel,openChannel:h.openChannel,confirm:h.confirm,alertError:h.alertError,sendUserCommand:m.sendUserCommand,clearUserCommand:m.clearUserCommand,openStream:h.openStream,closeTwilioRoom:h.closeTwilioRoom,closeStream:h.closeStream})(g);n.default=w},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],85:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;
1var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/createClass")),l=r(e("@babel/runtime/helpers/inherits")),c=r(e("@babel/runtime/helpers/possibleConstructorReturn")),u=r(e("@babel/runtime/helpers/getPrototypeOf")),p=r(e("react")),f=r(e("prop-types")),d=e("react-redux"),h=e("actions/commands"),m=e("actions/ui");function y(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,c.default)(this,n)}}var v=function(e){(0,l.default)(n,e);var t=b(n);function n(e){var r;return(0,o.default)(this,n),(r=t.call(this,e)).state={started:!1},r.startStream=r.startStream.bind((0,a.default)(r)),r}return(0,s.default)(n,[{key:"START_STREAM_COMMAND",get:function(){return"startStream"}}]),(0,s.default)(n,[{key:"startStream",value:function(){this.props.streams.length?this.props.alertError(this.props.i18n.oneStreamWarning):this.setState({started:!0},this.sendStartCommand)}},{key:"sendStartCommand",value:function(){this.props.sendUserCommand("ss_"+this.props.type,this.START_STREAM_COMMAND,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?y(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):y(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({type:this.props.type},this.props.parameters))}},{key:"componentDidUpdate",value:function(e){var t=this.props.command!==e.command&&this.props.command&&!1===this.props.command.success,n=this.props.command!==e.command&&this.props.command&&!0===this.props.command.success;t&&(this.props.alertError(this.props.command.error),this.props.clearUserCommand("ss_"+this.props.type),this.setState({started:!1})),n&&(this.props.openStream(this.props.command.result.stream.id,this.props.type,this.props.command.result.stream),this.props.clearUserCommand("ss_"+this.props.type),this.setState({started:!1}))}},{key:"render",value:function(){return p.default.createElement("button",{onClick:this.startStream,disabled:this.state.started,className:"wcFunctional wcStreamStartButton wcStreamVideo",title:this.props.label})}}]),n}(p.default.Component);v.propTypes={label:f.default.string.isRequired,type:f.default.string.isRequired,parameters:f.default.object.isRequired};var g=(0,d.connect)((function(e,t){return{i18n:e.application.i18n,configuration:e.configuration,command:e.commands.sent["ss_"+t.type],streams:e.ui.streams}}),{sendUserCommand:h.sendUserCommand,clearUserCommand:h.clearUserCommand,alertError:m.alertError,alertInfo:m.alertInfo,openStream:m.openStream})(v);n.default=g},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"actions/commands":97,"actions/ui":102,"prop-types":256,react:307,"react-redux":295}],86:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/slicedToArray")),o=r(e("@babel/runtime/helpers/toConsumableArray")),a=r(e("@babel/runtime/helpers/classCallCheck")),s=r(e("@babel/runtime/helpers/createClass")),l=r(e("@babel/runtime/helpers/assertThisInitialized")),c=r(e("@babel/runtime/helpers/inherits")),u=r(e("@babel/runtime/helpers/possibleConstructorReturn")),p=r(e("@babel/runtime/helpers/getPrototypeOf")),f=r(e("react")),d=r(e("prop-types")),h=e("react-redux"),m=r(e("twilio-video")),y=e("actions/ui");function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,p.default)(e);if(t){var i=(0,p.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,u.default)(this,n)}}var v=function(e){(0,c.default)(n,e);var t=b(n);function n(e){var r;return(0,a.default)(this,n),(r=t.call(this,e)).state={streamMessage:"",streamDetails:!1,audioMuted:r.isAudioOff(),videoMuted:r.isVideoOff(),calling:!1},r.ref=f.default.createRef(),r.waitForAnswer=r.waitForAnswer.bind((0,l.default)(r)),r.handleParticipantConnect=r.handleParticipantConnect.bind((0,l.default)(r)),r.handleParticipantDisconnect=r.handleParticipantDisconnect.bind((0,l.default)(r)),r.handleDisconnect=r.handleDisconnect.bind((0,l.default)(r)),r.handleRoomDisconnect=r.handleRoomDisconnect.bind((0,l.default)(r)),r.disconnectRoomAndCloseStream=r.disconnectRoomAndCloseStream.bind((0,l.default)(r)),r.handleParticipantSubscribed=r.handleParticipantSubscribed.bind((0,l.default)(r)),r.handleParticipantUnsubscribed=r.handleParticipantUnsubscribed.bind((0,l.default)(r)),r.handleMuteAudio=r.handleMuteAudio.bind((0,l.default)(r)),r.handleUnmuteAudio=r.handleUnmuteAudio.bind((0,l.default)(r)),r.handleMuteVideo=r.handleMuteVideo.bind((0,l.default)(r)),r.handleUnmuteVideo=r.handleUnmuteVideo.bind((0,l.default)(r)),r.isAudioOff=r.isAudioOff.b
1ind((0,l.default)(r)),r.isVideoOff=r.isVideoOff.bind((0,l.default)(r)),r}return(0,s.default)(n,[{key:"componentDidUpdate",value:function(e,t,n){e.room!==this.props.room&&this.setState({audioMuted:this.isAudioOff(),videoMuted:this.isVideoOff()})}},{key:"componentDidMount",value:function(){var e=this;if(this.props.room){var t=this.ref.current;this.props.room.on("participantConnected",this.handleParticipantConnect),this.props.room.on("participantDisconnected",this.handleParticipantDisconnect),this.props.room.on("disconnected",this.handleRoomDisconnect),this.props.room.participants.forEach((function(n){n.on("trackSubscribed",e.handleParticipantSubscribed),n.on("trackUnsubscribed",e.handleParticipantUnsubscribed),n.tracks.forEach((function(e){e.isSubscribed&&(t.appendChild(e.track.attach()),console.log("re-attach"))}))}))}else this.connectToRoom()}},{key:"componentWillUnmount",value:function(){var e=this;this.clearAllTimers(),this.props.room&&(this.props.room.removeListener("participantConnected",this.handleParticipantConnect),this.props.room.removeListener("participantDisconnected",this.handleParticipantDisconnect),this.props.room.removeListener("disconnected",this.handleRoomDisconnect),this.props.room.participants.forEac
1h((function(t){t.removeListener("trackSubscribed",e.handleParticipantSubscribed),t.removeListener("trackUnsubscribed",e.handleParticipantUnsubscribed),t.tracks.forEach((function(e){e.isSubscribed&&e.track.detach().forEach((function(e){return e.remove()}))}))})))}},{key:"handleParticipantConnect",value:function(e){var t=this.ref.current;this.setState({calling:!1}),this.setStreamMessage(void 0),this.clearAllTimers(),e.tracks.forEach((function(e){if(e.isSubscribed){var n=e.track;t.track(n.attach())}})),e.on("trackSubscribed",this.handleParticipantSubscribed),e.on("trackUnsubscribed",this.handleParticipantUnsubscribed)}},{key:"handleParticipantSubscribed",value:function(e){this.ref.current.appendChild(e.attach()),this.setState({streamDetails:!1})}},{key:"handleParticipantUnsubscribed",value:function(e){e.detach().forEach((function(e){return e.remove()})),this.setState({streamDetails:!0})}},{key:"handleParticipantDisconnect",value:function(){this.disconnectRoomAndCloseStream(this.props.i18n.callWasEndedRemote)}},{key:"handleRoomDisconnect",value:function(e,t){this.setState({calling:!1}),t?this.props.alertError("Twilio room disconnect error: "+t.message):e.localParticipant.videoTracks.forEach((function(e){e.track.stop(),e.unpublish()})),this.props.closeTwilioRoom()}},{key:"connectToRoom",value:function(){var e=this,t=m.default.connect,n=(m.default.createLocalVideoTrack,{name:this.props.stream.room}),r=this.props.stream.token;this.setStreamMessage(this.props.i18n.calling),this.setState({calling:!0}),t(r,n).then((function(t){e.props.openTwilioRoom(t),e.waitForAnswer(),t.participants.forEac
1h(e.handleParticipantConnect),t.on("participantConnected",e.handleParticipantConnect),t.on("participantDisconnected",e.handleParticipantDisconnect),t.on("disconnected",e.handleRoomDisconnect)}),(function(t){e.setState({calling:!1}),e.props.alertError("Unable to connect: "+t.message)}))}},{key:"waitForAnswer",value:function(){this.connectTimer=setTimeout(this.disconnectRoomAndCloseStream,1e3*this.props.configuration.interface.streams.video.calls.callingTimeout,this.props.i18n.callWasNotAnswered)}},{key:"handleDisconnect",value:function(){this.disconnectRoomAndCloseStream(this.props.i18n.callWasEnded)}},{key:"handleMuteAudio",value:function(){this.props.room&&(this.props.room.localParticipant.audioTracks.forEach((function(e){e.track.disable()})),this.setState({audioMuted:!0}))}},{key:"handleUnmuteAudio",value:function(){this.props.room&&(this.props.room.localParticipant.audioTracks.forEach((function(e){e.track.enable()})),this.setState({audioMuted:!1}))}},{key:"handleMuteVideo",value:function(){this.props.room&&(this.props.room.localParticipant.videoTracks.forEach((function(e){e.track.stop(),e.unpublish()})),this.setState({videoMuted:!0}))}},{key:"handleUnmuteVideo",value:function(){var e=this;this.props.room&&(0,m.default.createLocalVideoTrack)().then((function(t){return e.props.room.localParticipant.publishTrack(t)})).then((function(t){e.setState({videoMuted:!1})}))}},{key:"isAudioOff",value:function(){if(this.props.room){var e=(0,o.default)(this.props.room.localParticipant.audioTracks).map((function(e){var t=(0,i.default)(e,2);t[0];return t[1]}));return e.length>0&&e.filter((function(e){return!e.track.isEnabled})).length===e.length}}},{key:"isVideoOff",value:function(){if(this.props.room){var e=(0,o.default)(this.props.room.localParticipant.videoTracks).map((function(e){var t=(0,i.default)(e,2);t[0];return t[1]}));return e.length>0&&e.filter((function(e){return e.track.isStopped})).length===e.length}}},{key:"setStreamMessage",value:function(e){this.setState({streamMessage:e})}},{key:"clearAllTimers",value:function(){this.disconnectTimer&&(clearTimeout(this.disconnectTimer),delete this.disconnectTimer),this.connectTimer&&(clearTimeout(this.connectTimer),delete this.connectTimer)}},{key:"disconnectRoomAndCloseStream",value:function(e){var t=this;this.props.room&&setTimeout((function(){t.props.room.disconnect()}),10),this.setStreamMessage(e),this.clearAllTimers(),this.disconnectTimer=setTimeout((function(){t.props.closeStream(t.props.stream.id)}),4e3)}},{key:"render",value:function(){return f.default.createElement("div",{className:"wcStreamContent"},f.default.createElement("div",{ref:this.ref}),this.state.streamMessage&&f.default.createElement("div",{className:"wcStreamInfo"},this.state.streamMessage),!this.state.streamMessage&&this.state.streamDetails&&f.default.createElement("div",{className:"wcStreamDetails"},this.props.streamInfo),f.default.createElement("div",{className:"wcStreamToolbar"},!1===this.state.audioMuted&&f.default.createElement("button",{className:"wcStreamButton wcFunctional wcMuteAudio",title:this.props.i18n.audioMute,onClick:this.handleMuteAudio}),this.state.audioMuted&&f.default.createElement("button",{className:"wcStreamButton wcFunctional wcUnmuteAudio",title:this.props.i18n.audioUnmute,onClick:this.handleUnmuteAudio}),!1===this.state.videoMuted&&f.default.createElement("button",{className:"wcStreamButton wcFunctional wcMuteVideo",title:this.props.i18n.videoMute,onClick:this.handleMuteVideo}),this.state.videoMuted&&f.default.createElement("button",{className:"wcStreamButton wcFunctional wcUnmuteVideo",title:this.props.i18n.videoUnmute,onClick:this.handleUnmuteVideo}),this.props.room&&!this.props.maximized&&f.default.createElement("button",{className:"wcStreamButton wcFunctional wcMaximizeVideo",title:this.props.i18n.maximize,onClick:this.props.onMaximize}),this.props.room&&this.props.maximized&&f.default.createElement("button",{className:"wcStreamButton wcFunctional wcMinimizeVideo",title:this.props.i18n.minimize,onClick:this.props.onMinimize}),this.props.room&&f.default.createElement("button",{className:"wcStreamButton wcFunctional wcStreamEnd",title:this.props.i18n.endCall,onClick:this.handleDisconnect})),this.props.configuration.interface.streams.video.calls.callingSound&&this.state.calling&&f.default.createElement("audio",{loop:!0,autoPlay:!0,preload:"auto"},f.default.createElement("source",{src:this.props.configuration.baseDir+"assets/sounds/calling01.mp3",type:"audio/ogg"})))}}]),n}(f.default.Component);v.propTypes={stream:d.default.object.isRequired,streamInfo:d.default.object.isRequired,maximized:d.default.bool,onMaximize:d.default.func.isRequired,onMinimize:d.default.func.isRequired};var g=(0,h.connect)((function(e,t){return{configuration:e.configuration,i18n:e.application.i18n,room:e.ui.twilio.room&&e.ui.twilio.room.name===t.stream.room?e.ui.twilio.room:void 0}}),{alertError:y.alertError,openTwilioRoom:y.openTwilioRoom,closeTwilioRoom:y.closeTwilioRoom,closeStream:y.closeStream})(v);n.default=g},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"@babel/runtime/helpers/slicedToArray":146,"@babel/runtime/helpers/toConsumableArray":147,"actions/ui":102,"prop-types":256,react:307,"react-redux":295,"twilio-video":352}],87:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/toConsumableArray")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("@babel/runtime/helpers/assertThisInitialized")),l=r(e("@babel/runtime/helpers/inherits")),c=r(e("@babel/runtime/helpers/possibleConstructorReturn")),u=r(e("@babel/runtime/helpers/getPrototypeOf")),p=r(e("react")),f=e("react-redux"),d=e("actions/ui"),h=e("utils/string");function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,c.default)(this,n)}}var y=function(e){(0,l.default)(n,e);var t=m(n);function n(e){var r;return(0,o.default)(this,n),(r=t.call(this,e)).state={toasts:[]},r.handleClick=r.handleClick.bind((0,s.default)(r)),r}
1return(0,a.default)(n,[{key:"componentDidUpdate",value:function(e){this.props.toasts!==e.toasts&&this.props.toasts.length>0&&(this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.setState({toasts:[].concat((0,i.default)(this.state.toasts),(0,i.default)(this.props.toasts))}),this.props.clearToasts(),this.timeout=setTimeout(function(){this.setState({toasts:[]})}.bind(this),3e3))}},{key:"componentWillUnmount",value:function(){this.timeout&&(clearTimeout(this.timeout),this.timeout=null)}},{key:"handleClick",value:function(e){this.setState({toasts:this.state.toasts.filter((function(t,n){return n!==e}))})}},{key:"render",value:function(){var e=this;return 0===this.state.toasts.length?null:p.default.createElement("div",{className:"wcToasts"},this.state.toasts.map((function(t,n){return p.default.createElement("div",{key:n,onClick:function(t){return e.handleClick(n)},className:"wcToast wcAnimation wcAnimationFade wcToast"+(0,h.capitalizeFirstLetter)(t.type),style:{backgroundColor:e.props.configuration.defaultBackgroundColor}},p.default.createElement("div",{className:"wcToastIcon"},p.default.createElement("span",{className:"wcIcon ".concat("info"===t.type?"wcIconTick":"wcIconTimes")}))," ",t.text)})))}}]),n}(p.default.Component),b=(0,f.connect)((function(e){return{toasts:e.ui.toasts,configuration:e.configuration}}),{clearToasts:d.clearToasts})(y);n.default=b},{"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"@babel/runtime/helpers/toConsumableArray":147,"actions/ui":102,react:307,"react-redux":295,"utils/string":122}],88:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=function(){function e(t){(0,i.default)(this,e),this.configuration=t}return(0,o.default)(e,[{key:"start",value:function(){console.log("Not implemented")}},{key:"stop",value:function(){console.log("Not implemented")}},{key:"subscribe",value:function(e,t,n){console.log("Not implemented")}},{key:"unsubscribe",value:function(e,t,n){console.log("Not implemented")}},{key:"sendMessage",value:function(e,t,n,r){console.log("Not implemented")}},{key:"prepareImage",value:function(e,t,n,r){console.log("Not implemented")}},{key:"getMessage",value:function(e,t,n){console.log("Not implemented")}},{key:"sendUserCommand",value:function(e,t,n,r){console.log("Not implemented")}},{key:"updateConfiguration",value:function(e){console.log("Not implemented")}},{key:"auth",value:function(e,t,n,r){console.log("Not implemented")}},{key:"triggerMaintenance",value:function(){console.log("Not implemented")}},{key:"loadPastMessages",value:function(e,t,n,r){console.log("Not implemented")}}]),e}();n.default=a},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/interopRequireDefault":134}],89:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=(r(e("./Engine")),r(e("./ajax/AjaxEngine"))),s=function(){function e(t){(0,i.default)(this,e),this.configuration=t}return(0,o.default)(e,[{key:"createEngine",value:function(){return new a.default(this.configuration)}}]),e}();n.default=s},{"./Engine":88,"./ajax/AjaxEngine":91,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/interopRequireDefault":134}],90:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireWildcard"),i=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var o=i(e("@babel/runtime/helpers/classCallCheck")),a=i(e("@babel/runtime/helpers/createClass")),s=r(e("actions/application")),l=r(e("actions/log")),c=r(e("actions/messages")),u=r(e("actions/ui")),p=(e("../redux/actions/application"),function(){function e(t,n){(0,o.default)(this,e),this.engine=t,this.store=n,this.subscribeToEngineEvents(),this.subscribeToActions()}return(0,a.default)(e,[{key:"subscribeToEngineEvents",value:function(){var e=this.store;this.engine.subscribe("maintenance","event",(function(t,n){e.dispatch(s.updateData(t,n))}
1)),this.engine.subscribe("maintenance","event:checkSum",function(e){this.engine.updateConfiguration({checksum:e})}.bind(this)),this.engine.subscribe("log",void 0,(function(t,n,r){e.dispatch(l.log(t,n,r))})),this.engine.subscribe("messages",void 0,(function(t){e.dispatch(c.receive(t))})),this.engine.subscribe("heartBeat",void 0,(function(t){e.dispatch(s.heartBeat(t))}))}},{key:"subscribeToActions",value:function(){this.engine.subscribe("actions",void 0,function(e){var t=this;e.map((function(e){return t.handleAction(e.command.name,e.command.data)}))}.bind(this))}},{key:"handleAction",value:function(e,t){var n=this.store.getState();switch(e){case"deleteChannel":this.store.dispatch(c.deleteAllMessagesFromChannel(t.channelId)),this.store.dispatch(u.closeChannel(t.channelId)),this.store.dispatch(s.removeChannel(t.channelId));break;case"deleteAllMessagesFromChannel":this.store.dispatch(c.deleteAllMessagesFromChannel(t.channelId));break;case"deleteMessage":this.store.dispatch(c.deleteMessage(t.id));break;case"deleteMessages":this.store.dispatch(c.deleteMessages(t.ids));break;case"refreshMessageReactionsCounters":this.store.dispatch(c.refreshMessageReactionsCounters(t.id,t.reactions));break;case"refreshMessage":Object.keys(n.messages.received).find((function(e){return n.messages.received[e].find((function(e){return e.id===t.id}))}))&&this.store.dispatch(c.refreshMessage(t.id));break;
1case"refreshUserName":this.store.dispatch(c.refreshSender(t.id,t.name));break;case"refreshChannelName":this.store.dispatch(s.refreshChannel({id:t.id,name:t.name}));break;case"incomingStream":this.store.dispatch(u.requestStream(t));break;case"incomingMessage":this.store.dispatch(s.addIncomingChat(t))}}}]),e}());n.default=p},{"../redux/actions/application":95,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/interopRequireWildcard":135,"actions/application":95,"actions/log":100,"actions/messages":101,"actions/ui":102}],91:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("@babel/runtime/helpers/assertThisInitialized")),s=r(e("@babel/runtime/helpers/inherits")),l=r(e("@babel/runtime/helpers/possibleConstructorReturn")),c=r(e("@babel/runtime/helpers/getPrototypeOf")),u=r(e("jquery")),p=r(e("events")),f=r(e("../Engine")),d=r(e("./AjaxEngineMaintenance")),h=r(e("./AjaxEngineSender"));function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=(0,c.default)(e);if(t){var i=(0,c.default)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return(0,l.default)(this,n)}}var y=function(e){(0,s.default)(n,e);var t=m(n);function n(e){var r;return(0,i.default)(this,n),(r=t.call(this,e)).emitter=new p.default,r.maintenance=new d.default(e),r.sender=new h.default(e),r.MESSAGES_REFRESH_TIMEOUT=e.engines.ajax.refresh,r.messagesEndpoint=e.engines.ajax.apiMessagesEndpointBase+(e.engines.ajax.apiMessagesEndpointBase.match(/\?/)?"&":"?")+"action=wise_chat_messages_endpoint",r.pastMessagesEndpoint=e.engines.ajax.apiWPEndpointBase+"?action=wise_chat_past_messages_endpoint",r.userCommandEndpoint=e.engines.ajax.apiWPEndpointBase+"?action=wise_chat_user_command_endpoint",r.authEndpoint=e.engines.ajax.apiWPEndpointBase+"?action=wise_chat_auth_endpoint",r.idsCache={},r.lastId=0,r.lastActionId=0,r.actionsIdsCache={},r.lastCheckTime=null,r.isInitialized=!1,r.currentRequest=null,r.messagesCallback=function(){},r.messagesErrorCallback=function(){},r.debugLoggerCallback=function(){},r.interval=null,r.initialDone=!1,r.checkNewMessages=r.checkNewMessages.bind((0,a.default)(r)),r.onNewMessagesArrived=r.onNewMessagesArrived.bind((0,a.default)(r)),r.onMessageArrivalError=r.onMessageArrivalError.bind((0,a.default)(r)),r.onAuthenticationComplete=r.onAuthenticationComplete.bind((0,a.default)(r)),r}return(0,o.default)(n,[{key:"start",value:function(){!0!==this.isInitialized&&(this.isInitialized=!0,this.maintenance.subscribe("event:user",this.onAuthenticationComplete),this.maintenance.start())}},{key:"stop",value:function(){this.maintenance.stop(),this.interval&&(clearInterval(this.interval),this.interval=null),this.isInitialized=!1,this.maintenance.unsubscribe("event:user",this.onAuthenticationComplete)}},{key:"subscribe",value:function(e,t,n){switch(e){case"heartBeat":this.emitter.on("heartBeat",n);break;case"maintenance":this.maintenance.subscribe(t,n);break;case"log":this.maintenance.subscribe("log",n),this.sender.subscribe("log",n),this.emitter.on("log",n);break;default:this.emitter.on(e,n)}}},{key:"unsubscribe",value:function(e,t,n){switch(e){case"heartBeat":this.emitter.removeListener("heartBeat",n);break;case"maintenance":this.maintenance.unsubscribe(t,n);break;case"log":this.maintenance.unsubscribe("log",n),this.sender.unsubscribe("log",n),this.emitter.removeListener("log",n);break;default:this.emitter.removeListener(e,n)}}},{key:"onAuthenticationComplete",value:function(e){this.isInitialized&&(e?this.interval||this.checkNewMessages():this.interval&&(clearInterval(this.interval),this.interval=null,this.initialDone=!1))}},{key:"checkNewMessages",value:function(){if(!(null!==this.currentRequest&&this.currentRequest.readyState>0&&this.currentRequest.readyState<4)&&!1!==this.isInitialized){var e={lastId:this.lastId,fromActionId:this.lastActionId,lastCheckTime:this.lastCheckTime,checksum:this.configuration.checksum,init:this.initialDone?0:1};!0===this.configuration.isMultisite&&(e.blogId=this.configuration.blogId),this.currentRequest=u.default.ajax({type:"GET",url:this.messagesEndpoint,data:e}).done(this.onNewMessagesArrived).fail(this.onMessageArrivalError)}}},{key:"onNewMessagesArrived",value:function(e){this.interval||(this.initialDone=!0,this.interval=setInterval(this.checkNewMessages,this.MESSAGES_REFRESH_TIMEOUT));try{var t=e;if(t.lastActionId&&this.lastActionId<t.lastActionId&&(this.lastActionId=t.lastActionId),t.actions&&t.actions.length&&this.executeActions(t.actions),t.result){for(var n=[],r=0;r<t.result.length;r++){var i=t.result[r],o=i.id;this.idsCache[o]||(this.lastId=o,n.push(i),this.idsCache[o]=!0)}t.result=n,this.processMessages(t)}}catch(t){this.logDebug("[onNewMessagesArrived] [result]",e),this.logDebug("[onNewMessagesArrived] [exception]",+t.toString());var a="";if("string"===u.default.type(e)){var s=e.split("\n");s.length>1&&(a=", "+s[1])}else a=e;this.logError("Server error: "+t.toString()+a)}}},{key:"onMessageArrivalError",value:function(e,t,n){if(void 0===e.status||0!==e.status)try{var r=u.default.parseJSON(e.responseText);r.error&&this.logError(r.error)}catch(t){this.logDebug("[onMessageArrivalError] [responseText]",e.responseText),this.logDebug("[onMessageArrivalError] [errorThrown]",n),this.logError("Server error: "+n)}}},{key:"processMessages",value:function(e){this.emitter.emit("heartBeat",{nowTime:e.nowTime}),this.lastCheckTime=e.nowTime?e.nowTime:this.lastCheckTime,e.result&&e.result.length>0&&this.configuration.rights.receiveMessages&&this.emitter.emit("messages",e.result),e.recentChats&&this.emitter.emit("recentChats",e)}},{key:"executeActions",value:function(e){for(var t=[],n=0;n<e.length;n++){var r=e[n],i=r.id;this.actionsIdsCache[i]||(this.actionsIdsCache[i]=!0,t.push(r))}this.emitter.emit("actions",t)}},{key:"sendMessage",value:function(e,t,n,r){if(this.isInitialized){var i=this;this.sender.sendMessage(e,(function(e){i.checkNewMessages(),t(e)}),n,r)}}},{key:"prepareImage",value:function(e,t,n,r){this.isInitialized&&this.sender.prepareImage(e,t,n,r)}},{key:"getMessage",value:function(e,t,n){this.isInitialized&&this.sender.getMessage(e,t,n)}},{key:"sendUserCommand",value:function(e,t,n,r){if(!u.default.isFunction(n)||!u.default.isFunction(r))throw new Error("Missing listeners");var i={parameters:t,command:e,checksum:this.configuration.checksum};u.default.ajax({type:"POST",url:this.userCommandEndpoint,data:i}).done(function(e){try{var t=e;t&&t.error?r(t.error):n(t)}catch(t){this.logDebug("[sendUserCommand] [result]",e),this.logDebug("[sendUserCommand] [exception]",t.toString()),r("Unknown error: "+t.toString())}}.bind(this)).fail(this.commonFailFunction("sendUserCommand",r))}},{key:"auth",value:function(e,t,n,r){if(!u.default.isFunction(n)||!u.default.isFunction(r))throw new Error("Missing listeners");var i=this,o={parameters:t,mode:e,checksum:this.configuration.checksum};u.default.ajax({type:"POST",url:this.authEndpoint,data:o}).done((function(e){try{var t=e;t&&t.error?r(t.error):n(t)}catch(t){i.logDebug("[auth] [result]",e),i.logDebug("[auth] [exception]",t.toString()),r("Unknown error: "+t.toString())}})).fail(this.commonFailFunction("auth",r))}},{key:"triggerMaintenance",value:function(){this.maintenance.performFullMaintenanceRequest
1()}},{key:"loadPastMessages",value:function(e,t,n,r){if(!1!==this.isInitialized){var i=this,o={channelId:e,beforeMessage:t,checksum:this.configuration.checksum};!0===this.configuration.isMultisite&&(o.blogId=this.configuration.blogId),u.default.ajax({type:"GET",url:this.pastMessagesEndpoint,data:o}).done((function(e){try{var t=e;t&&t.error?r(t.error):n(t.result)}catch(t){i.logDebug("[loadPastMessages] [result]",e),i.logDebug("[loadPastMessages] [exception]",t.toString()),r("Unknown error: "+t.toString())}})).fail(this.commonFailFunction("loadPastMessages",r))}}},{key:"updateConfiguration",value:function(e){this.maintenance.updateConfiguration(e),this.configuration=Object.assign({},this.configuration,e)}},{key:"logError",value:function(e){this.emitter.emit("log","error",e)}},{key:"logDebug",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.emitter.emit("log","debug","[engine.ajax.AjaxEngine] "+e,t)}},{key:"commonFailFunction",value:function(e,t){return function(n,r,i){if(void 0===n.status||0!==n.status)try{var o=u.default.parseJSON(n.responseText);t(o&&o.error?o.error:"Unknown server error occurred: "+i)}catch(r){this.logDebug("[".concat(e,"] [responseText]"),n.responseText),this.logDebug("[".concat(e,"] [errorThrown]"),i),this.logDebug("[".concat(e,"] [exception]"),r.toString()),t("Server error: "+i)}else t("No network connection")}.bind(this)}}]),n}(f.default);n.default=y},{"../Engine":88,"./AjaxEngineMaintenance":92,"./AjaxEngineSender":93,"@babel/runtime/helpers/assertThisInitialized":126,"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,events:222,jquery:244}],92:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("jquery")),s=r(e("events")),l=function(){function e(t){(0,i.default)(this,e),this.emitter=new s.default,this.configuration=t,this.started=!1,this.REFRESH_TIMEOUT=2e4,this.ENDPOINT_URL=t.engines.ajax.apiWPEndpointBase+"?action=wise_chat_maintenance_endpoint",this.full=!0,this.request=null,this.interval=null,this.performMaintenanceRequest=this.performMaintenanceRequest.bind(this),this.analyzeResponse=this.analyzeResponse.bind(this),this.onMaintenanceRequestError=this.onMaintenanceRequestError.bind(this)}return(0,o.default)(e,[{key:"updateConfiguration",value:function(e){this.configuration=Object.assign({},this.configuration,e)}},{key:"start",value:function(){!0!==this.started&&(this.started=!0,this.performMaintenanceRequest(),this.interval=setInterval(this.performMaintenanceRequest,this.REFRESH_TIMEOUT))}},{key:"stop",value:function(){this.interval&&(clearInterval(this.interval),this.interval=null),this.started=!1}},{key:"subscribe",value:function(e,t){this.emitter.on(e,t)}},{key:"unsubscribe",value:function(e,t){this.emitter.removeListener(e,t)}},{key:"isRequestStillRunning",value:function(){return null!==this.request&&this.request.readyState>0&&this.request.readyState<4}},{key:"performFullMaintenanceRequest",value:function(){this.full=!0,this.performMaintenanceRequest()}},{key:"performMaintenanceRequest",value:function(){if(!this.isRequestStillRunning()){var e={full:this.full,checksum:this.configuration.checksum};this.request=a.default.ajax({url:this.ENDPOINT_URL,data:e}).done(this.analyzeResponse).fail(this.onMaintenanceRequestError)}}},{key:"analyzeResponse",value:function(e){try{e.events&&this.handleEvents(e.events),e.error?this.logError("Maintenance error occurred: "+e.error):this.full=!1}catch(t){this.logDebug("[analyzeResponse] [data]",e),this.logDebug("[analyzeResponse] [exception]",t.message),this.logError("Maintenance error: corrupted data")}}},{key:"handleEvents",value:function(e){for(var t=0;t<e.length;t++){var n=e[t];this.emitter.emit("event",n.name,n.data),this.emitter.emit("event:"+n.name,n.data)}}},{key:"onMaintenanceRequestError",value:function(e,t,n){if(void 0===e.status||0!==e.status)try{var r=a.default.parseJSON(e.responseText);r.error?this.logError("Maintenance error: "+r.error):this.logError("Unknown maintenance error: "+n)}catch(t){this.logDebug("[onMaintenanceRequestError] [responseText]",e.responseText),this.logDebug("[onMaintenanceRequestError] [errorThrown]",n),this.logDebug("[onMaintenanceRequestError] [exception]",t.message),this.logError("Maintenance fatal error: "+n)}}},{key:"logError",value:function(e){this.emitter.emit("log","error",e)}},{key:"logDebug",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.emitter.emit("log","debug","[engine.ajax.AjaxEngineMaintenance] "+e,t)}}]),e}();n.default=l},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/interopRequireDefault":134,events:222,jquery:244}],93:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("jquery")),s=r(e("events")),l=function(){function e(t){(0,i.default)(this,e),this.emitter=new s.default,this.configuration=t,this.messageEndpoint=t.engines.ajax.apiWPEndpointBase+"?action=wise_chat_message_endpoint",this.messageGetEndpoint=t.engines.ajax.apiWPEndpointBase+"?action=wise_chat_get_message_endpoint",this.prepareImageEndpoint=t.engines.ajax.apiEndpointBase+(t.engines.ajax.apiEndpointBase.match(/\?/)?"&":"?")+"action=wise_chat_prepare_image_endpoint"}return(0,o.default)(e,[{key:"subscribe",value:function(e,t){this.emitter.on(e,t)}},{key:"unsubscribe",value:function(e,t){this.emitter.removeListener(e,t)}},{key:"sendMessage",value:function(e,t,n,r){if(!a.default.isFunction(t)||!a.default.isFunction(n)||!a.default.isFunction(r))throw new Error("Missing listeners");var i=this;n(0);var o={};a.default.isPlainObject(e.customParameters)&&(o=e.customParameters),o.attachments=e.attachments,o.channelId=e.channelId,o.message=e.content,o.checksum=e.checksum,a.default.ajax({type:"POST",url:this.messageEndpoint,data:o,progressUpload:function(e){if(e.lengthComputable){var t=parseInt(e.loaded/e.total*100);t>100&&(t=100),n(t)}}}).done((function(e){try{var n=e;n.error?r(n.error):t(n)}catch(t){i.logDebug("[onMessageSent] [result]",e),i.logDebug("[onMessageSent] [exception]",t.toString()),i.logError("Unknown error: "+t.toString()),r("Unknown error: "+t.toString())}})).fail((function(e,t,n){if(void 0===e.status||0!==e.status)try{var o=a.default.parseJSON(e.responseText);o.error?r(o.error):r("Unknown server error occurred: "+n)}catch(t){i.logDebug("[onMessageSentError] [responseText]",e.responseText),i.logDebug("[onMessageSentError] [errorThrown]",n),i.logDebug("[onMessageSentError] [exception]",t.toString()),i.logError("Server error: "+n),r("Server error: "+n)}else r("No network connection")}))}},{key:"prepareImage",value:function(e,t,n,r){if(!a.default.isFunction(t)||!a.default.isFunction(n)||!a.default.isFunction(r))throw new Error("Missing listeners");var i=this;n(0),a.default.ajax({type:"POST",url:this.prepareImageEndpoint,data:{data:e,checksum:this.configuration.checksum},progressUpload:function(e){if(e.lengthComputable){var t=parseInt(e.loaded/e.total*100);t>100&&(t=100),n(t)}}}).done((function(e){n(100),t(e)})).fail((function(e,t,n){if(void 0===e.status||0!==e.status)try{var o=a.default.parseJSON(e.responseText);o.error?r(o.error):r("Unknown server error occurred: "+n)}catch(t){i.logDebug("[onImagePrepareError] [responseText]",e.responseText),i.logDebug("[onImagePrepareError] [errorThrown]",n),i.logDebug("[onImagePrepareError] [exception]",t.toString()),i.logError("Server error: "+n),r("Server error: "+n)}else r("No network connection")}))}},{key:"getMessage",value:function(e,t,n){if(!a.default.isFunction(t)||!a.default.isFunction(n))throw new Error("Missing listeners");var r=this;a.default.ajax({type:"GET",url:this.messageGetEndpoint,data:e}).done((function(e){try{var i=e;i.error?n(i.error):t(i)}catch(t){r.logDebug("[onMessageGet] [result]",e),r.logDebug("[onMessageGet] [exception]",t.toString()),n("Unknown error: "+t.toString())}})).fail((function(e,t,i){if(void 0===e.status||0!==e.status)try{var o=a.default.parseJSON(e.responseText);o.error?n(o.error):n("Unknown server error occurred: "+i)}catch(t){r.logDebug("[onMessageGet] [responseText]",e.responseText),r.logDebug("[onMessageGet] [errorThrown]",i),r.logDebug("[onMessageGet] [exception]",t.toString()),n("Server error: "+i)}else n("No network connection")}))}},{key:"logError",value:function(e){this.emitter.emit("log","error",e)}},{key:"logDebug",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.emitter.emit("log","debug","[engine.ajax.AjaxEngineSender] "+e,t)}}]),e}();n.default=l},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/interopRequireDefault":134,events:222,jquery:244}],94:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireWildcard"),i=e("@babel/runtime/helpers/interopRequireDefault"),o=i(e("@babel/runtime/helpers/typeof")),a=i(e("react")),s=i(e("react-dom")),l=e("react-redux"),c=i(e("store")),u=i(e("store/external-actions")),p=i(e("Application")),f=r(e("actions/configuration")),d=e("react-cookie"),h=i(e("engine/EngineFactory")),m=i(e("engine/EngineStoreDispatcher")),y=e("utils/extensions"),b=e("utils/html"),v=i(e("string.prototype.matchall"));jQuery(window).on("load",(function(){v.default.shim(),(0,y.installXhrProgressEvent)(),window._wiseChat={instances:[],init:function(e){if(!jQuery(e).hasClass("wcInvisible")){var t=jQuery(e).data("wc-config");
1"object"===(0,o.default)(t)?(t.defaultBackgroundColor=0===t.theme.length?(0,b.getAncestorBackgroundColor)(jQuery(e)):null,function(e,t){var n=new h.default(t).createEngine(),r=(0,c.default)(n,t);r.dispatch(f.replace(t)),new m.default(n,r),(0,u.default)(r),s.default.render(a.default.createElement(l.Provider,{store:r},a.default.createElement(d.CookiesProvider,null,a.default.createElement(p.default,{rootElement:e,engine:n}))),e)}(jQuery(e)[0],t),this.instances.push(t)):jQuery(e).html('<strong style="color:#f00;">Error: invalid Wise Chat configuration</strong>')}}},jQuery(".wcContainer[data-wc-config]").each((function(){window._wiseChat.init(this)})),jQuery(".wcChatButton").on("click",(function(e){if(e.preventDefault(),window._wiseChat.instances.length>0)alert("Could not open the chat. Please close any other chats first.");else{var t=jQuery(this),n=jQuery(t.data("wc-template"));jQuery(document.body).append(n),n.removeClass("wcInvisible").each((function(){window._wiseChat.init(this)}))}}))}))},{"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/interopRequireWildcard":135,"@babel/runtime/helpers/typeof":148,Application:1,"actions/configuration":98,"engine/EngineFactory":89,"engine/EngineStoreDispatcher":90,react:307,"react-cookie":261,"react-dom":268,"react-redux":295,store:113,"store/external-actions":112,"string.prototype.matchall":329,"utils/extensions":116,"utils/html":119}],95:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.updateData=function(e,t){return{type:e,data:t}},n.heartBeat=function(e){return{type:"application.heartbeat",data:e}},n.markRecentChatRead=function(e){return{type:"application.recent.read",data:e}},n.markFeedEntryAsSeen=function(e){return{type:"application.feed.read",data:e}},n.refreshAuthenticationData=function(){return function(e,t,n){n.engine.triggerMaintenance()}},n.markChannelAuthorized=function(e){return{type:"application.channel.authorize",data:e}},n.addIncomingChat=function(e){return{type:"application.incoming.add",data:e}},n.deleteIncomingChats=function(e){return{type:"application.incoming.delete",data:e}},n.refreshChannel=function(e){return{type:"application.channel.replace",channel:e}},n.clear=function(){return{type:"application.clear"}},n.addChannel=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return{type:"application.channel.add",channel:e,storageOnly:t}},n.removeChannel=function(e){return{type:"application.channel.remove",channelId:e}},n.mergeFeed=function(e){return{type:"application.userFeed.merge",data:e}}},{}],96:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.sendAuth=function(e,t){return function(n,r,i){var o=i.engine;i.configuration;n({type:"auth.send",mode:e,data:{inProgress:!0,error:void 0,result:void 0,success:void 0}}),o.auth(e,t,(function(t){n({type:"auth.send",mode:e,data:{inProgress:!1,success:!0,result:t}})}),(function(t){n({type:"auth.send",mode:e,data:{inProgress:!1,success:!1,error:t}})}))}},n.clearAuth=function(e){return function(t){t({type:"auth.clear",mode:e})}}},{}],97:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.sendUserCommand=function(e,t,n){return function(r,i,o){var a=o.engine;o.configuration;r({type:"command.send",id:e,data:{inProgress:!0,error:void 0,result:void 0,success:void 0}}),a.sendUserCommand(t,n,(function(t){r({type:"command.send",id:e,data:{inProgress:!1,success:!0,result:t}})}),(function(t){r({type:"command.send",id:e,data:{inProgress:!1,success:!1,error:t}})}))}},n.clearUserCommand=function(e){return function(t){t({type:"command.clear",id:e})}}},{}],98:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.replace=function(e){return{type:"replace",data:e}}},{}],99:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.requestGIFCategories=function(){return function(e,t,n){n.engine;var r=n.configuration;if(!t().integrations.tenor.search.inProgress){r.interface.input.gifs.apiKey||alert("No Tenor GIF API key set");var i=t().application.user.id,o="https://tenor.googleapis.com/v2/categories?key="+r.interface.input.gifs.apiKey+"&client_key="+i+"&country="+r.interface.input.gifs.country+"&locale="+r.interface.input.gifs.language;e({type:"integrations.tenor.categories",data:{inProgress:!0,error:void 0,success:void 0}}),fetch(o).then((function(e){return e.json()})).then((function(t){e({type:"integrations.tenor.categories",data:{inProgress:!1,success:!0,results:t.tags}})})).catch((function(t){return e({type:"integrations.tenor.categories",data:{inProgress:!1,success:!1,error:t}})}))}}},n.searchGIFs=function(e){return function(t,n,r){r.engine;var i=r.configuration;if(!n().integrations.tenor.search.inProgress){i.interface.input.gifs.apiKey||alert("No Tenor GIF API key set");var o=n().application.user.id,a="https://tenor.googleapis.com/v2/search?q="+encodeURIComponent(e)+"&key="+i.interface.input.gifs.apiKey+"&client_key="+o+"&country="+i.interface.input.gifs.country+"&locale="+i.interface.input.gifs.language+"&limit="+i.interface.input.gifs.limit+"&media_filter=gif,tinygif";t({type:"integrations.tenor.search",data:{keyword:e,inProgress:!0,error:void 0,success:void 0,next:void 0}}),fetch(a).then((function(e){return e.json()})).then((function(e){t({type:"integrations.tenor.search",data:{inProgress:!1,success:!0,results:e.results,next:e.next}})})).catch((function(e){return t({type:"integrations.tenor.search",data:{inProgress:!1,success:!1,error:e,next:void 0}})}))}}},n.searchNextGIFs=function(e){return function(t,n,r){r.engine;var s=r.configuration,l=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?a(Object(n),!0).forEach((function(t){(0,o.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},n().integrations.tenor.search);if(!l.inProgress){s.interface.input.gifs.apiKey||alert("No Tenor GIF API key set");var c=n().application.user.id,u="https://tenor.googleapis.com/v2/search?q="+encodeURIComponent(e)+"&key="+s.interface.input.gifs.apiKey+"&client_key="+c+"&country="+s.interface.input.gifs.country+"&locale="+s.interface.input.gifs.language+"&limit="+s.interface.input.gifs.limit+"&pos="+l.next+"&media_filter=gif,tinygif";t({type:"integrations.tenor.search",data:{inProgress:!0,error:void 0,success:void 0,next:void 0}}),fetch(u).then((function(e){return e.json()})).then((function(e){t({type:"integrations.tenor.search",data:{inProgress:!1,success:!0,results:[].concat((0,i.default)(l.results),(0,i.default)(e.results)),next:e.next}})})).catch((function(e){return t({type:"integrations.tenor.search",data:{inProgress:!1,success:!1,error:e,next:void 0}})}))}}};var i=r(e("@babel/runtime/helpers/toConsumableArray")),o=r(e("@babel/runtime/helpers/defineProperty"));function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}},{"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/toConsumableArray":147}],100:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.log=o,n.logInfo=function(e,t){return o("info",e,t)},n.logError=function(e,t){return o("error",e,t)},n.logDebug=function(e,t,n){return o("debug",t,n)};var i=r(e("moment"));function o(e,t,n){return{type:"log.append",payload:{level:e,content:t,details:n,timestamp:(0,i.default)().format("YYYY-MM-DD hh:mm:ss")}}}},{"@babel/runtime/helpers/interopRequireDefault":134,moment:246}],101:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.sendMessage=function(e,t,n,r){return function(i,o,a){var s=a.engine,l=a.configuration;i({type:"message.send",id:r,data:{inProgress:!0,progress:0,error:void 0,result:void 0,success:void 0}}),s.sendMessage({content:e,attachments:t,customParameters:n,channelId:r,checksum:l.checksum},(function(e){i({type:"message.send",id:r,data:{inProgress:!1,success:!0,progress:100,result:e}}),e.channelMapping&&(i({type:"application.channel.map",from:e.channelMapping.from,to:e.channelMapping.to}),i({type:"ui.channel.map",from:e.channelMapping.from,to:e.channelMapping.to,userCacheId:o().application.user.cacheId}))}),(function(e){i({type:"message.send",id:r,data:{progress:e}})}),(function(e){i({type:"message.send",id:r,data:{inProgress:!1,success:!1,error:e}})}))}},n.receive=function(e){return function(t){t({type:"message.receive",messages:e})}},n.loadPastMessages=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0;return function(n,r,i){var o=i.engine;i.configuration;n({type:"message.receive.past",channelId:e,beforeMessage:t,data:{inProgress:!0,error:void 0,result:void 0,success:void 0}}),o.loadPastMessages(e,t,(function(r){n({type:"message.receive.past.done",channelId:e,beforeMessage:t,data:r}),n({type:"message.receive.past",channelId:e,beforeMessage:t,data:{inProgress:!1,success:!0,result:r}})}),(function(r){n({type:"message.receive.past",channelId:e,beforeMessage:t,data:{inProgress:!1,success:!1,error:r}})}))}},n.clearLoadPastMessages=function(e){return function(t){t({type:"message.receive.past.clear",id:e})}},n.deleteMessage=function(e,t){return function(n){n({type:"message.delete",id:e,channel:t})}},n.deleteAllMessagesFromChannel=function(e){return function(t){t({type:"message.delete.all.from.channel",channelId:e})}},n.deleteMessages=function(e){return function(t){t({type:"message.delete.multiple",ids:e})}},n.replaceMessage=function(e){return function(t){t({type:"message.replace",message:e})}},n.replaceMessages=function(e,t){return function(n){n({type:"messages.replace.all",channelId:e,messages:t})}},n.refreshMessage=function(e){return function(t,n,r){var o=r.engine,a=r.configuration;o.getMessage({id:e,checksum:a.checksum},(function(e){i.default.isArray(e.result)&&e.result.map((function(e){t({type:"message.replace",message:e})}))}),(function(e){}))}}
1,n.refreshSender=function(e,t){return function(n){n({type:"messages.sender.replace",id:e,name:t})}},n.refreshMessageReactionsCounters=function(e,t){return function(n){n({type:"message.reactions.counters.replace",id:e,reactions:t})}},n.prepareImage=function(e,t){return function(n,r,i){var o=i.engine;i.configuration;n({type:"message.image",id:t,data:{inProgress:!0,progress:0,error:void 0,result:void 0,success:void 0}}),o.prepareImage(e,(function(e){n({type:"message.image",id:t,data:{inProgress:!1,success:!0,progress:100,result:e}})}),(function(e){n({type:"message.image",id:t,data:{progress:e}})}),(function(e){n({type:"message.image",id:t,data:{inProgress:!1,success:!1,error:e}})}))}},n.clear=function(){return{type:"messages.clear"}};var i=r(e("jquery"))},{"@babel/runtime/helpers/interopRequireDefault":134,jquery:244}],102:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.requestChannelOpening=function(e){return{type:"ui.channel.opening.request",channelId:e}},n.clearChannelOpeningRequest=function(){return{type:"ui.channel.opening.request.clear"}},n.focusChannel=u,n.openChannel=p,n.ignoreChannel=function(e){return function(t,n){new a.default(n().application.user.cacheId).markIgnored(e),t({type:"ui.channel.ignore",id:e})}},n.restoreChannels=function(){return function(e,t){var n=t(),r=n.configuration,i=new a.default(n.application.user?n.application.user.cacheId:"na"),s=n.application.user.openChannels;if(e({type:"ui.channel.ignore.multiple",channels:i.getIgnoredChannels()}),e({type:"ui.channel.minimize.multiple",channels:i.getHiddenChannels()}),r.interface.browser.autoOpen){var l=n.application.channels.filter((function(e){return n.application.user.openChannels.includes(e.id)}
1)),c=n.application.autoOpenChannels;if(c.length>0){c.map((function(e){return e.id}));var d,h=c.filter((function(e){return!0===e.online}));if(d=h.length>0?h[Math.floor(Math.random()*h.length)]:c[Math.floor(Math.random()*c.length)],0===l.length)e(p(d.id)),e(u(d.id));else{var m=c.find((function(e){return l.includes(e.id)}));m?(e({type:"ui.channel.open.only",id:m.id}),e(u(m.id))):(e({type:"ui.channel.open.only",id:d.id}),e(u(d.id)))}return}}else if(r.interface.browser.autoOpenFirstPublic){var y=n.application.browserChannels.filter((function(e){return"public"===e.type}));if(0===n.application.channels.filter((function(e){return n.application.user.openChannels.includes(e.id)})).length&&y.length>0)return e(p(y[0].id)),e(u(y[0].id)),void(1===r.mode&&r.interface.chat.fb.minimizeOnStart&&e(f(y[0].id)))}e({type:"ui.channel.open.multiple",channels:s});var b=!1,v=i.getFocused();v&&(t().application.channels.find((function(e){return e.id===v}))&&(e(u(v)),b=!0));if(!b){var g=(0,o.default)(s).reverse().find((function(e){return t().application.channels.find((function(t){return t.id===e}))}));g&&e(u(g))}}},n.completeInit=function(){return{type:"ui.init.complete"}},n.closeChannel=function(e){return function(t,n,r){(0,s.sendUserCommand)("closeChannel","closeChannel",{channelId:e})(t,n,r),t({type:"ui.channel.close",id:e})}},n.minimizeChannel=f,n.minimizeChannels=function(e){return function(t,n){var r=new a.default(n().application.user?n().application.user.cacheId:"na");e.map((function(e){return r.markHidden(e)})),t({type:"ui.channel.minimize.multiple",channels:e})}},n.maximizeChannel=function(e){return function(t,n){new a.default(n().application.user?n().application.user.cacheId:"na").unmarkHidden(e),t({type:"ui.channel.maximize",id:e})}},n.stopIgnoringChannel=function(e){return function(t,n){new a.default(n().application.user.cacheId).clearIgnored(e),t({type:"ui.channel.ignore.stop",id:e})}},n.appendToChannelInput=function(e,t){return{type:"ui.channel.input.append",id:e,text:t}},n.alertError=function(e){return{type:"ui.alert.error",text:e}},n.alertInfo=function(e){return{type:"ui.alert.info",text:e}},n.clearAlerts=function(){return{type:"ui.alerts.clear"}},n.toastError=function(e){return{type:"ui.toast.error",text:e}},n.toastInfo=function(e){return{type:"ui.toast.info",text:e}},n.clearToasts=function(){return{type:"ui.toasts.clear"}},n.confirm=function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{title:"",timeout:void 0,className:""};return{type:"ui.confirm",text:e,callback:t,cancelCallback:n,buttons:r,configuration:i}},n.clearConfirm=function(){return{type:"ui.confirm.clear"}},n.setMessageEditable=function(e){return{type:"ui.message.edit.start",messageId:e}},n.cancelMessageEditable=function(e){return{type:"ui.message.edit.cancel",messageId:e}},n.setMessageReplyTo=function(e,t){return{type:"ui.message.reply-to.start",messageId:e,channel:t}},n.cancelMessageReplyTo=function(e){return{type:"ui.message.reply-to.cancel",channel:e}},n.setMobileTopTab=function(e){return{type:"ui.mobile.toptab",tab:e}},n.setMobileTitle=function(e){return{type:"ui.mobile.title",title:e}},n.notify=function(e){return{type:"ui.notification.add",notification:{event:e}}},n.clearNotifications=function(){return{type:"ui.notifications.clear"}},n.unreadAdd=function(e,t){return{type:"ui.channel.unread.add",id:e,quantity:t}},n.unreadClear=d,n.setChannelProperty=function(e,t,n){return{type:"ui.channel.property.set",id:e,name:t,value:n}},n.logOff=function(){return{type:"ui.log.off"}},n.destroy=function(){return{type:"ui.destroy"}},n.clear=function(){return{type:"ui.clear"}},n.requestStream=function(e){return{type:"ui.stream.request",data:e}},n.openStream=function(e,t,n){return{type:"ui.stream.open",data:c({id:e,type:t},n)}},n.closeStream=function(e){return{type:"ui.stream.close",id:e}},n.openTwilioRoom=function(e){return{type:"ui.stream.twilio.room.open",data:e}},n.closeTwilioRoom=function(){return{type:"ui.stream.twilio.room.close"}},n.updateProperties=function(e){return{type:"ui.properties.update",data:e}};var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/toConsumableArray")),a=r(e("utils/channels-storage")),s=e("./commands");function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?l(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function u(e){return function(t,n){new a.default(n().application.user.cacheId).markFocused(e),t({type:"ui.channel.focus",id:e}),t(d(e))}}function p(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return function(n,r,i){(0,s.sendUserCommand)("openChannel","openChannel",{channelId:e,openFirst:t})(n,r,i),n({type:"ui.channel.open",id:e,openFirst:t})}}function f(e){return function(t,n){new a.default(n().application.user?n().application.user.cacheId:"na").markHidden(e),t({type:"ui.channel.minimize",id:e})}}function d(e){return{type:"ui.channel.unread.clear",id:e}}},{"./commands":97,"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/toConsumableArray":147,"utils/channels-storage":114}],103:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:l,t=arguments.length>1?arguments[1]:void 0,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=arguments.length>1?arguments[1]:void 0;return Object.assign({},t,n)};switch(t.type){case"channels":if(0===t.data.length)return e;
1var r=[].concat((0,o.default)(e.channels.filter((function(e){return!t.data.find((function(t){return t.id===e.id}))}))),(0,o.default)(t.data));return n(e,{channels:JSON.stringify(r)!==JSON.stringify(e.channels)?r:e.channels});case"browserChannels":var a=t.data.filter((function(t){return!e.channels.find((function(e){return e.id===t.id}))})),c=(a.length>0?[].concat((0,o.default)(e.channels),(0,o.default)(a)):e.channels).map((function(e){var n;return null!==(n=t.data.find((function(t){return e.id===t.id})))&&void 0!==n?n:e}));return n(e,{browserChannels:JSON.stringify(e.browserChannels)!==JSON.stringify(t.data)?t.data:e.browserChannels,onlineUsersCounter:t.data.filter((function(e){return!0===e.online&&"direct"===e.type})).length,channels:JSON.stringify(c)!==JSON.stringify(e.channels)?c:e.channels});case"autoOpenChannels":var u=t.data.filter((function(t){return!e.channels.find((function(e){return e.id===t.id}))})),p=(u.length>0?[].concat((0,o.default)(e.channels),(0,o.default)(u)):e.channels).map((function(e){var n;return null!==(n=t.data.find((function(t){return e.id===t.id})))&&void 0!==n?n:e}));return n(e,{autoOpenChannels:JSON.stringify(e.autoOpenChannels)!==JSON.stringify(t.data)?t.data:e.autoOpenChannels,channels:JSON.stringify(p)!==JSON.stringify(e.channels)?p:e.channels});case"openChannels":var f=t.data.filter((function(t){return!e.channels.find((function(e){return e.id===t.id}))})),d=(f.length>0?[].concat((0,o.default)(e.channels),(0,o.default)(f)):e.channels).map((function(e){var n;return null!==(n=t.data.find((function(t){return e.id===t.id})))&&void 0!==n?n:e}));return n(e,{openChannels:JSON.stringify(e.openChannels)!==JSON.stringify(t.data)?t.data:e.openChannels,channels:JSON.stringify(d)!==JSON.stringify(e.channels)?d:e.channels});case"recentChats":var h=t.data.map((function(e){return e.channel})),m=[].concat((0,o.default)(e.channels.map((function(e){return h.find((function(t){return e.id===t.id}))?h.find((function(t){return e.id===t.id})):e}))),(0,o.default)(h.filter((function(t){return!e.channels.find((function(e){return e.id===t.id}))}))));return n(e,{recentChats:t.data,channels:JSON.stringify(m)!==JSON.stringify(e.channels)?m:e.channels});case"userFeed":case"application.userFeed.merge":var y=e.userFeed.map((function(e){return e.id})),b=t.data.filter((function(e){return!y.includes(e.id)}
1));return b.length>0?n(e,{userFeed:[].concat((0,o.default)(e.userFeed),(0,o.default)(b)).sort((function(e,t){return e.created.localeCompare(t.created)})).reverse()}):e;case"users":case"usersCounter":case"absentUsers":case"newUsers":case"userRights":case"user":case"auth":case"checkSum":case"actions":case"i18n":return n(e,(0,i.default)({},t.type,t.data));case"application.channel.map":return n(e,{channelMap:t,channels:e.channels.map((function(e){return e.id===t.from?s(s({},e),{},{id:t.to}):e}))});case"application.channel.authorize":return n(e,{channels:e.channels.map((function(e){return e.id===t.data?s(s({},e),{},{authorized:!0}):e})),browserChannels:e.browserChannels.map((function(e){return e.id===t.data?s(s({},e),{},{authorized:!0}):e}))});case"application.heartbeat":return n(e,{heartbeat:t.data});case"application.recent.read":return n(e,{recentChats:e.recentChats.map((function(e){return e.channel.id!==t.data?e:s(s({},e),{},{read:!0})}))});case"application.feed.read":return n(e,{userFeed:e.userFeed.map((function(e){return e.id!==t.data?e:s(s({},e),{},{seen:!0})}))});case"application.incoming.add":return n(e,{incomingChats:[].concat((0,o.default)(e.incomingChats),[t.data])});case"application.incoming.delete":return n(e,{incomingChats:e.incomingChats.filter((function(e){return!t.data.includes(e.channelId)}))});case"application.channel.replace":return n(e,{channels:e.channels.map((function(e){return e.id===t.channel.id?s(s({},e),t.channel):e})),browserChannels:e.browserChannels.map((function(e){return e.id===t.channel.id?s(s({},e),t.channel):e}))});case"application.channel.add":return n(e,{channels:e.channels.find((function(e){return e.id===t.channel.id}))?e.channels.map((function(e){return e.id===t.channel.id?t.channel:e})):[].concat((0,o.default)(e.channels),[t.channel]),browserChannels:t.storageOnly?e.browserChannels:e.browserChannels.find((function(e){return e.id===t.channel.id}))?e.browserChannels.map((function(e){return e.id===t.channel.id?t.channel:e})):[].concat((0,o.default)(e.browserChannels),[t.channel])});case"application.channel.remove":return n(e,{channels:e.channels.filter((function(e){return e.id!==t.channelId})),browserChannels:e.browserChannels.filter((function(e){return e.id!==t.channelId}))});case"application.clear":return n(e,s(s({},l),{},{checkSum:e.checkSum,i18n:e.i18n,heartbeat:e.heartbeat}));default:return e}};var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/toConsumableArray"));function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var l={channels:[],browserChannels:[],autoOpenChannels:[],onlineUsersCounter:0,channelMap:void 0,users:[],usersCounter:[],absentUsers:[],newUsers:[],userFeed:[],userRights:{},user:void 0,auth:void 0,checkSum:void 0,recentChats:[],incomingChats:[],actions:[],i18n:{},heartbeat:{nowTime:void 0}}},{"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/toConsumableArray":147}],104:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s,t=arguments.length>1?arguments[1]:void 0,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=arguments.length>1?arguments[1]:void 0;return Object.assign({},t,n)};switch(t.type){case"auth.send":return n(e,{sent:a(a({},e.sent),{},(0,i.default)({},t.mode,Object.assign({},e.sent[t.mode],t.data)))});default:return e}};
1var i=r(e("@babel/runtime/helpers/defineProperty"));function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var s={sent:{}}},{"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/interopRequireDefault":134}],105:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s,t=arguments.length>1?arguments[1]:void 0,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=arguments.length>1?arguments[1]:void 0;return Object.assign({},t,n)};switch(t.type){case"command.send":return n(e,{sent:a(a({},e.sent),{},(0,i.default)({},t.id,a({},t.data)))});case"command.clear":return n(e,{sent:a(a({},e.sent),{},(0,i.default)({},t.id,void 0))});default:return e}};var i=r(e("@babel/runtime/helpers/defineProperty"));function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var s={sent:{}}},{"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/interopRequireDefault":134}],106:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:r,t=arguments.length>1?arguments[1]:void 0,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=arguments.length>1?arguments[1]:void 0;return Object.assign({},t,n)};switch(t.type){case"replace":return n(e,t.data);default:return e}};var r={windowTitle:""}},{}],107:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=e("redux"),o=r(e("./log")),a=r(e("./configuration")),s=r(e("./application")),l=r(e("./messages")),c=r(e("./commands")),u=r(e("./ui")),p=r(e("./auth")),f=r(e("./integrations")),d=(0,i.combineReducers)({log:o.default,configuration:a.default,application:s.default,messages:l.default,ui:u.default,commands:c.default,auth:p.default,integrations:f.default});n.default=d},{"./application":103,"./auth":104,"./commands":105,"./configuration":106,"./integrations":108,"./log":109,"./messages":110,"./ui":111,"@babel/runtime/helpers/interopRequireDefault":134,redux:312}],108:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s,t=arguments.length>1?arguments[1]:void 0,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=arguments.length>1?arguments[1]:void 0;return Object.assign({},t,n)};switch(t.type){case"integrations.tenor.categories":return n(e,{tenor:a(a({},e.tenor),{},{categories:Object.assign({},e.tenor.categories,t.data)})});case"integrations.tenor.search":return n(e,{tenor:a(a({},e.tenor),{},{search:Object.assign({},e.tenor.search,t.data)})});default:return e}};var i=r(e("@babel/runtime/helpers/defineProperty"));function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?o(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var s={tenor:{categories:{inProgress:!1,results:[]},search:{keyword:"",inProgress:!1,results:[]}}}},{"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/interopRequireDefault":134}],109:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:o,t=arguments.length>1?arguments[1]:void 0,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=arguments.length>1?arguments[1]:void 0;return Object.assign({},t,n)};switch(t.type){case"log.append":return n(e,{entries:[].concat((0,i.default)(e.entries),[t.payload])});default:return e}};var i=r(e("@babel/runtime/helpers/toConsumableArray")),o={entries:[]}},{"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/toConsumableArray":147}],110:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:c,t=arguments.length>1?arguments[1]:void 0,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=arguments.length>1?arguments[1]:void 0;return Object.assign({},t,n)};switch(t.type){case"message.send":return n(e,{posted:l(l({},e.posted),{},(0,o.default)({},t.id,Object.assign({},e.posted[t.id],t.data)))});case"message.receive":for(var r={},s=0;s<t.messages.length;s++){var u=t.messages[s];r[u.channel.id]||(e.received[u.channel.id]?r[u.channel.id]=(0,i.default)(e.received[u.channel.id]):r[u.channel.id]=[]),r[u.channel.id].push(u)}return Object.keys(r).map((function(e){return r[e]=(0,a.default)(r[e])})),n(e,{received:l(l({},e.received),r)});case"message.receive.past":return n(e,{receivedPast:l(l({},e.receivedPast),{},(0,o.default)({},t.channelId,Object.assign({},e.receivedPast[t.channelId],t.data)))});case"message.receive.past.done":var p=e.received[t.channelId]?(0,a.default)([].concat((0,i.default)(e.received[t.channelId]),(0,i.default)(t.data))):t.data;return n(e,{received:l(l({},e.received),{},(0,o.default)({},t.channelId,p))});case"message.image":return n(e,{image:l(l({},e.image),{},(0,o.default)({},t.id,Object.assign({},e.image[t.id],t.data)))});case"message.delete":var f=Object.keys(e.received).find((function(n){return e.received[n].find((function(e){return e.id===t.id}))}));return f?n(e,{received:l(l({},e.received),{},(0,o.default)({},f,e.received[f].filter((function(e){return e.id!==t.id}))))}):e;case"message.delete.all.from.channel":return e.received[t.channelId]?n(e,{received:l(l({},e.received),{},(0,o.default)({},t.channelId,[]))}):e;case"message.delete.multiple":var d={};return Object.keys(e.received).forEach((function(n){d[n]=e.received[n].filter((function(e){return!t.ids.includes(e.id)}
1))})),n(e,{received:d});case"message.replace":return e.received[t.message.channel.id]?n(e,{received:l(l({},e.received),{},(0,o.default)({},t.message.channel.id,e.received[t.message.channel.id].map((function(e){return e.id!==t.message.id?e:l({},t.message)}))))}):e;case"messages.replace.all":return n(e,{received:l(l({},e.received),{},(0,o.default)({},t.channelId,t.messages))});case"messages.sender.replace":var h={};return Object.keys(e.received).forEach((function(n){h[n]=e.received[n].map((function(e){return e.sender.id===t.id?l(l({},e),{},{sender:l(l({},e.sender),{},{name:t.name})}):e}))})),n(e,{received:h});case"message.reactions.counters.replace":var m={};return Object.keys(e.received).forEach((function(n){m[n]=e.received[n].map((function(e){return e.id===t.id?l(l({},e),{},{reactions:t.reactions}):e}))})),n(e,{received:m});case"messages.clear":return n(e,c);default:return e}};var i=r(e("@babel/runtime/helpers/toConsumableArray")),o=r(e("@babel/runtime/helpers/defineProperty")),a=r(e("utils/messages"));function s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function l(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?s(Object(n),!0).forEach((function(t){(0,o.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var c={posted:{},received:{},receivedPast:{},image:{}}},{"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/toConsumableArray":147,"utils/messages":121}],111:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:c,t=arguments.length>1?arguments[1]:void 0,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=arguments.length>1?arguments[1]:void 0;return Object.assign({},t,n)};switch(t.type){case"ui.init.complete":return n(e,{initiated:!0});case"ui.channel.opening.request":return n(e,{channelOpeningRequest:t.channelId});case"ui.channel.opening.request.clear":return n(e,{channelOpeningRequest:void 0});case"ui.channel.focus":return n(e,{focusedChannel:t.id});case"ui.channel.open":return e.openedChannels.includes(t.id)?e:n(e,{openedChannels:t.openFirst?[t.id].concat((0,o.default)(e.openedChannels)):[].concat((0,o.default)(e.openedChannels),[t.id])});case"ui.channel.open.only":return n(e,{openedChannels:[t.id]});case"ui.channel.open.multiple":if(!Array.isArray(t.channels))return e;var r=(0,o.default)(new Set(t.channels.filter((function(t){return!e.openedChannels.includes(t)}))));return n(e,{openedChannels:[].concat((0,o.default)(e.openedChannels),(0,o.default)(r))});case"ui.channel.minimize":return e.minimizedChannels.includes(t.id)?e:n(e,{minimizedChannels:[].concat((0,o.default)(e.minimizedChannels),[t.id])});case"ui.channel.minimize.multiple":if(!Array.isArray(t.channels))return e;var s=(0,o.default)(new Set(t.channels.filter((function(t){return!e.minimizedChannels.includes(t)}))));return n(e,{minimizedChannels:[].concat((0,o.default)(e.minimizedChannels),(0,o.default)(s))});case"ui.channel.maximize":return n(e,{minimizedChannels:e.minimizedChannels.filter((function(e){return e!==t.id}))});case"ui.channel.ignore":return e.ignoredChannels.includes(t.id)?e:n(e,{ignoredChannels:[].concat((0,o.default)(e.ignoredChannels),[t.id])});case"ui.channel.ignore.stop":return n(e,{ignoredChannels:e.ignoredChannels.filter((function(e){return e!==t.id}))});case"ui.channel.ignore.multiple":if(!Array.isArray(t.channels))return e;var u=(0,o.default)(new Set(t.channels.filter((function(t){return!e.ignoredChannels.includes(t)}))));return n(e,{ignoredChannels:[].concat((0,o.default)(e.ignoredChannels),(0,o.default)(u))});
1case"ui.channel.close":return n(e,{openedChannels:e.openedChannels.filter((function(e){return e!==t.id})),focusedChannel:e.focusedChannel===t.id?void 0:e.focusedChannel});case"ui.channel.input.append":return n(e,{channels:l(l({},e.channels),{},(0,i.default)({},t.id,l(l({},e.channels[t.id]),{},{inputAppend:t.text})))});case"ui.channel.unread.add":var p=e.channels[t.id]&&e.channels[t.id].unread?e.channels[t.id].unread:0;return n(e,{channels:l(l({},e.channels),{},(0,i.default)({},t.id,l(l({},e.channels[t.id]),{},{unread:p+t.quantity})))});case"ui.channel.unread.clear":return n(e,{channels:l(l({},e.channels),{},(0,i.default)({},t.id,l(l({},e.channels[t.id]),{},{unread:0})))});case"ui.channel.property.set":return n(e,{channels:l(l({},e.channels),{},(0,i.default)({},t.id,l(l({},e.channels[t.id]),{},(0,i.default)({},t.name,t.value))))});case"ui.channel.map":var f=new a.default(t.userCacheId);return f.mapChannel(t.from,t.to),n(e,{openedChannels:e.openedChannels.map((function(e){return e===t.from?t.to:e})),focusedChannel:e.focusedChannel===t.from?t.to:e.focusedChannel});case"ui.alert.error":return n(e,{alerts:l(l({},e.alerts),{},{error:t.text})});case"ui.alert.info":return n(e,{alerts:l(l({},e.alerts),{},{info:t.text})});case"ui.alerts.clear":return n(e,{alerts:{error:void 0,info:void 0}});case"ui.toast.error":return n(e,{toasts:[].concat((0,o.default)(e.toasts),[{type:"error",text:t.text}])});case"ui.toast.info":return n(e,{toasts:[].concat((0,o.default)(e.toasts),[{type:"info",text:t.text}])});case"ui.toasts.clear":return n(e,{toasts:[]});case"ui.confirm":return n(e,{confirms:{text:t.text,callback:t.callback,cancelCallback:t.cancelCallback,buttons:t.buttons,configuration:t.configuration}});case"ui.confirm.clear":return n(e,{confirms:void 0});case"ui.message.edit.start":return n(e,{editableMessages:l(l({},e.editableMessages),{},(0,i.default)({},t.messageId,!0))});case"ui.message.edit.cancel":return n(e,{editableMessages:Object.keys(e.editableMessages).reduce((function(n,r){return r!==t.messageId&&(n[r]=e.editableMessages[r]),n}),{})});case"ui.message.reply-to.start":return n(e,{replyToMessages:l(l({},e.replyToMessages),{},(0,i.default)({},t.channel,t.messageId))});case"ui.message.reply-to.cancel":return n(e,{replyToMessages:Object.keys(e.replyToMessages).reduce((function(n,r){return r!==t.channel&&(n[r]=e.replyToMessages[r]),n}),{})});case"ui.mobile.toptab":return n(e,{mobile:l(l({},e.mobile),{},{topTab:t.tab})});case"ui.mobile.title":return n(e,{mobile:l(l({},e.mobile),{},{title:t.title})});case"ui.notification.add":return n(e,{notifications:[].concat((0,o.default)(e.notifications),[t.notification])});case"ui.notifications.clear":return n(e,{notifications:[]});case"ui.log.off":return n(e,{logOffRequest:new Date});case"ui.destroy":return n(e,{destroyRequest:new Date});case"ui.clear":return n(e,c);case"ui.stream.request":return n(e,{streamRequest:t.data});case"ui.stream.open":return e.streams.find((function(e){return e.id===t.data.id}))?n(e,{streams:e.streams.map((function(e){return e.id===t.data.id?t.data:e}))}):n(e,{streams:[].concat((0,o.default)(e.streams),[t.data])});case"ui.stream.close":return n(e,{streams:e.streams.filter((function(e){return e.id!==t.id}))});case"ui.stream.twilio.room.open":return n(e,{twilio:l(l({},e.twilio),{},{room:t.data})});case"ui.stream.twilio.room.close":return n(e,{twilio:l(l({},e.twilio),{},{room:void 0})});case"ui.properties.update":return n(e,{properties:l(l({},e.properties),t.data)});default:return e}};var i=r(e("@babel/runtime/helpers/defineProperty")),o=r(e("@babel/runtime/helpers/toConsumableArray")),a=r(e("utils/channels-storage"));function s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function l(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?s(Object(n),!0).forEach((function(t){(0,i.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEac
1h((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var c={initiated:!1,channelOpeningRequest:void 0,openedChannels:[],ignoredChannels:[],minimizedChannels:[],focusedChannel:void 0,alerts:{error:void 0,info:void 0},toasts:[],notifications:[],confirms:void 0,channels:{},editableMessages:{},replyToMessages:{},mobile:{topTab:"chats",title:void 0},logOffRequest:void 0,destroyRequest:void 0,streams:[],streamRequest:void 0,twilio:{room:void 0},properties:{windowWidth:1300,windowSizeClass:"Xl",isMobile:!1}}},{"@babel/runtime/helpers/defineProperty":130,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/toConsumableArray":147,"utils/channels-storage":114}],112:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(e){!function(e){jQuery(".wise-chat-send-message").on("click",(function(t){t.preventDefault(),e.dispatch((0,r.requestChannelOpening)(jQuery(this).data("user-id")))}))}(e)};var r=e("actions/ui")},{"actions/ui":102}],113:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=e("redux"),o=r(e("redux-thunk")),a=r(e("reducers"));var s=function(e,t){var n=window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__||i.compose;return(0,i.createStore)(a.default,n((0,i.applyMiddleware)(o.default.withExtraArgument({engine:e,configuration:t}))))};n.default=s},{"@babel/runtime/helpers/interopRequireDefault":134,reducers:107,redux:312,"redux-thunk":311}],114:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/toConsumableArray")),o=r(e("@babel/runtime/helpers/defineProperty")),a=r(e("@babel/runtime/helpers/classCallCheck")),s=r(e("@babel/runtime/helpers/createClass"));function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){(0,o.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var u=function(){function e(t){(0,a.default)(this,e),t||(t="c"),this.instanceId=t,this.LOCAL_STORAGE_KEY="WiseChatChannelsStorage"}return(0,s.default)(e,[{key:"isEmpty",value:function(){return void 0===this.getData()[this.instanceId]}},{key:"mapChannel",value:function(e,t){this.isFocused(e)&&this.markFocused(t),this.isOpen(e)&&(this.clear(e),this.markOpen(t))}},{key:"markHidden",value:function(e){var t=this.getInstanceData();t.hidden.includes(e)||t.hidden.push(e),this.saveInstanceData(t)}},{key:"isHidden",value:function(e){return this.getInstanceData().hidden.includes(e)}},{key:"unmarkHidden",value:function(e){var t=this.getInstanceData();this.saveInstanceData(c(c({},t),{},{hidden:t.hidden.filter((function(t){return t!==e}))}))}},{key:"markIgnored",value:function(e){var t=this.getInstanceData();this.saveInstanceData(c(c({},t),{},{ignored:[].concat((0,i.default)(t.ignored?t.ignored:[]),[e])}))}},{key:"markFocused",value:function(e){this.saveInstanceData(c(c({},this.getInstanceData()),{},{focused:e}))}},{key:"getFocused",value:function(){var e=this.getInstanceData();return e.focused?e.focused:null}},{key:"markOpen",value:function(e){var t=this.getInstanceData();this.saveInstanceData(c(c({},t),{},{open:[].concat((0,i.default)(t.open?t.open:[]),[e])}))}},{key:"clear",value:function(e){var t=this.getInstanceData();this.saveInstanceData(c(c({},t),{},{focused:t.focused===e?void 0:t.focused,open:t.open.filter((function(t){return t!==e})),hidden:t.hidden.filter((function(t){return t!==e}))}))}},{key:"isOpen",value:function(e){return this.getInstanceData().open.includes(e)}},{key:"isFocused",value:function(e){return this.getInstanceData().focused===e}},{key:"isIgnored",value:function(e){return this.getInstanceData().ignored.includes(e)}},{key:"clearIgnored",value:function(e){var t=this.getInstanceData();this.saveInstanceData(c(c({},t),{},{ignored:t.ignored.filter((function(t){return t!==e}))}))}},{key:"getOpenedChannels",value:function(){return this.getInstanceData().open}},{key:"getIgnoredChannels",value:function(){return this.getInstanceData().ignored}},{key:"getHiddenChannels",value:function(){return this.getInstanceData().hidden}},{key:"getInstanceData",value:function(){var e=this.getData();return e[this.instanceId]?e[this.instanceId]:{open:[],focused:void 0,hidden:[],ignored:[]}}},{key:"saveInstanceData",value:function(e){var t=c(c({},this.getData()),{},(0,o.default)({},this.instanceId,e));this.saveData(t)}},{key:"getData",value:function(){var e={};if("undefined"!=typeof Storage){var t=window.localStorage.getItem(this.LOCAL_STORAGE_KEY);if(null!==t)try{e=JSON.parse(t)}catch(e){}}return e}},{key:"saveData",value:function(e){"undefined"!=typeof Storage&&window.localStorage.setItem(this.LOCAL_STORAGE_KEY,JSON.stringify(e))}}]),e}();n.default=u},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/
1defineProperty":130,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/toConsumableArray":147}],115:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("jquery")),s=function(){function e(t){(0,i.default)(this,e),this.configuration=t}return(0,o.default)(e,[{key:"SETS",get:function(){return{1:{alias:"01",total:30,popup:{32:[240,210],64:[240,250],128:[240,250]}},2:{alias:"02",total:50,popup:{32:[240,210],64:[240,250],128:[240,250]}},3:{alias:"03",total:48,popup:{32:[240,210],64:[240,250],128:[240,250]}},4:{alias:"04",total:50,popup:{32:[240,210],64:[240,250],128:[240,250]}}}}}]),(0,o.default)(e,[{key:"buildSet",value:function(){var e=function(e,t){var n=t-e.toString().length+1;return n>0?Array(+n).join("0")+e:e},t=this.configuration.custom,n=this.SETS[this.configuration.set];if(this.emoticons=[],a.default.isArray(t)){for(var r=0;r<t.length;r++){var i=t[r],o=i.id;this.emoticons.push({shortcode:'[emoticon custom="'.concat(o,'"]'),url:i.url,urlFull:i.urlFull,maxWidth:this.configuration.customEmoticonMaxWidthInPopup>0?this.configuration.customEmoticonMaxWidthInPopup:void 0})}this.configuration.customPopupWidth>0&&(this.LAYER_WIDTH=this.configuration.customPopupWidth),this.configuration.customPopupHeight>0&&(this.LAYER_HEIGHT=this.configuration.customPopupHeight)}else if(n){for(var s=1;s<=n.total;s++)this.emoticons.push({class:"bg-emot_"+n.alias+"_"+this.configuration.size+"_"+e(s,3),shortcode:'[emoticon set="'.concat(n.alias,'" index="').concat(e(s,3),'" size="').concat(this.configuration.size,'"]')});this.LAYER_WIDTH=n.popup[this.configuration.size][0],this.LAYER_HEIGHT=n.popup[this.configuration.size][1]}}}]),e}();n.default=s},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/interopRequireDefault":134,jquery:244}],116:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.installXhrProgressEvent=function(){var e=o.default.ajaxSettings.xhr;o.default.ajaxSetup({xhr:function(){var t=e.call(o.default.ajaxSettings),n=this;return t&&("function"==typeof t.addEventListener&&void 0!==n.progress&&t.addEventListener("progress",(function(e){n.progress(e)}),!1),"object"==(0,i.default)(t.upload)&&void 0!==n.progressUpload&&t.upload.addEventListener("progress",(function(e){n.progressUpload(e)}),!1)),t}})};var i=r(e("@babel/runtime/helpers/typeof")),o=r(e("jquery"))},{"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/typeof":148,jquery:244}],117:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/toConsumableArray")),o=r(e("@babel/runtime/helpers/classCallCheck")),a=r(e("@babel/runtime/helpers/createClass")),s=r(e("react")),l=r(e("utils/image-viewer")),c=e("js-base64"),u=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};(0,o.default)(this,e),this.configuration=t,this.rendererConfiguration=n,this.currentKey=0,this.imageViewer=new l.default,this.parse=this.parse.bind(this),this.handleImagePreview=this.handleImagePreview.bind(this)}return(0,a.default)(e,[{key:"PARSERS",get:function(){var e=this,t=this.configuration.interface.input.emoticons,n=this.configuration.interface.input.sounds;return[{regExp:/\[link src="(.+?)"(\s+name="(.+?)")?]/g,callback:function(t,n,r){var i=t[1];if(e.configuration.interface.message.links){var o=(i.match(/^https|http|ftp|mailto:/)?"":"http://")+i;return t[2]&&(i=t[3]),s.default.createElement("a",{key:e.currentKey++,href:o,target:"_blank",rel:"noopener noreferrer nofollow","data-org":c.Base64.encode(t[0])},i)}return i}},{regExp:/\[sound id="(.+?)" src="(.+?)" name-org="(.+?)"]/g,callback:function(t,r,i){var o=t[2];return n.enabled?s.default.createElement("audio",{key:e.currentKey++,controls:!0,"data-org":c.Base64.encode(t[0]),c
1ontrolsList:"nodownload noplaybackrate"},s.default.createElement("source",{src:o,type:"audio/mpeg"}),"Your browser does not support the audio element."):""}},{regExp:/\[attachment id="(.+?)" src="(.+?)" name-org="(.+?)"]/g,callback:function(t,n,r){var i=t[2],o=t[3],a=e.configuration.interface.message.attachmentsVideoPlayer,l=e.configuration.interface.message.attachmentsSoundPlayer;if(e.configuration.interface.message.attachments)return a&&e.isFile(i,"mp4")?s.default.createElement("video",{key:e.currentKey++,controls:!0,"data-org":c.Base64.encode(t[0]),controlsList:"nodownload noplaybackrate"},s.default.createElement("source",{src:i,type:"video/mp4"}),"Your browser does not support the video tag."):a&&e.isFile(i,"webm")?s.default.createElement("video",{key:e.currentKey++,controls:!0,"data-org":c.Base64.encode(t[0]),controlsList:"nodownload noplaybackrate"},s.default.createElement("source",{src:i,type:"video/webm"}),"Your browser does not support the video tag."):l&&e.isFile(i,"mp3")?s.default.createElement("audio",{key:e.currentKey++,controls:!0,"data-org":c.Base64.encode(t[0]),controlsList:"nodownload noplaybackrate"},s.default.createElement("source",{src:i,type:"audio/mpeg"}),"Your browser does not support the audio element."):l&&e.isFile(i,"wav")?s.default.createElement("audio",{key:e.currentKey++,controls:!0,"data-org":c.Base64.encode(t[0]),controlsList:"nodownload noplaybackrate"},s.default.createElement("source",{src:i,type:"audio/wav"}),"Your browser does not support the audio element."):s.default.createElement("a",{key:e.currentKey++,href:i,target:"_blank",rel:"noopener noreferrer nofollow","data-org":c.Base64.encode(t[0])},o);if(e.configuration.interface.message.links){var u=(i.match(/^https|http|ftp:/)?"":"http://")+i;return s.default.createElement("a",{key:e.currentKey++,href:u,target:"_blank",rel:"noopener noreferrer nofollow","data-org":c.Base64.encode(t[0])},o)}return o}},{regExp:/\[img id="(\d+)" src="(.+?)" src-th="(.+?)" src-org="(.+?)"]/g,callback:function(t,n,r){var i=t[2],o=t[3],a=t[4];if(e.configuration.interface.message.images){var l=e.configuration.interface.message.imagesViewer;return s.default.createElement("a",{key:e.currentKey++,href:i,target:"browser_window"===l?"_blank":void 0,"data-lightbox":"lightbox"===l?"wise_chat":void 0,className:"wcFunctional",rel:"lightbox"===l?"lightbox[wise_chat]":void 0,"data-org":c.Base64.encode(t[0]),onClick:function(t){return"internal"===l?e.handleImagePreview(t,i):void 0}},s.default.createElement("img",{src:o,className:"wcImage wcFunctional",alt:"Chat image"}))}if(e.configuration.interface.message.links){"_"===a&&(a=i);var u=(a.match(/^https|http|ftp:/)?"":"http://")+a;return s.default.createElement("a",{key:e.currentKey++,href:u,target:"_blank",rel:"noopener noreferrer nofollow","data-org":c.Base64.encode(t[0])},a)}return"_"!==a?a:i}},{regExp:/\[img src="(.+?)"(\s+className="(.+?)")?]/g,callback:function(t,n,r){var i=t[1],o=t[2]?t[3]:"";return e.configuration.interface.message.images?s.default.createElement("img",{key:e.currentKey++,src:i,className:"wcImage wcFunctional ".concat(o),alt:"Chat image","data-org":c.Base64.encode(t[0])}):i}},{regExp:/\[span className="(.+?)" content="(.*?)"]/g,callback:function(t,n,r){var i=t[1],o=t[2];return s.default.createElement("span",{key:e.currentKey++,className:i,"data-org":c.Base64.encode(t[0])},o)}},{regExp:/\[youtube movie-id="(.+?)" src-org="(.+?)"]/g,callback:function(t,n,r){var i=t[1],o=t[2];if(e.configuration.interface.message.yt&&i.length>0)return s.default.createElement("iframe",{key:e.currentKey++,width:e.configuration.interface.message.ytWidth,height:e.configuration.interface.message.ytHeight,className:"wcVideoPlayer",src:"https://www.youtube.com/embed/"+i,frameBorder:"0",allowFullScreen:!0,"data-org":c.Base64.encode(t[0])});if(e.configuration.interface.message.links&&o.length>0){var a=(o.match(/^https|http|ftp:/)?"":"http://")+o;return s.default.createElement("a",{key:e.currentKey++,href:a,target:"_blank",rel:"noopener noreferrer nofollow","data-org":c.Base64.encode(t[0])},o)}return o.length>0?o:void 0}},{regExp:/#([^\s#\[\]\\<&;]+)/g,callback:function(t,n,r){var i=t[1];return e.configuration.interface.message.tt?s.default.createElement(s.default.Fragment,{key:e.currentKey++},s.default.createElement("a",{href:"https://twitter.com/hashtag/"+i+"?src=hash",target:"_blank",rel:"noopener noreferrer nofollow","data-org":c.Base64.encode(t[0])},"#",i)):t[0]}}
1,{regExp:/\[emoticon set="(.+?)" index="(.+?)" size="(\d+)"]/g,callback:function(n,r,i){var o=n[1],a=n[2],l=n[3];return t.set?s.default.createElement("img",{key:e.currentKey++,src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",alt:"Emoticon set #"+o+" "+l+"px #"+a,className:"wcFunctional wcEmoticon bg-emot_"+o+"_"+l+"_"+a,"data-org":c.Base64.encode(n[0])}):s.default.createElement("span",{key:e.currentKey++})}},{regExp:/\[emoticon custom="(\d+)"]/g,callback:function(n,r,i){var o=parseInt(n[1]);if(t.custom){var a=t.custom.find((function(e){return e.id===o}));return a?s.default.createElement("img",{key:e.currentKey++,src:a.url,alt:"Emoticon "+o,className:"wcFunctional wcEmoticon","data-org":c.Base64.encode(n[0])}):s.default.createElement("span",{key:e.currentKey++})}return s.default.createElement("span",{key:e.currentKey++})}},{regExp:/\[video-call channelId="([^"]+)"]/g,callback:function(t,n,r){var i=t[1];return e.rendererConfiguration.onShortcodeRender?e.rendererConfiguration.onShortcodeRender("video-call",{channelId:i},e.currentKey++):s.default.createElement("span",{key:e.currentKey++})}},{regExp:/\n/g,callback:function(t,n,r){return s.default.createElement("br",{key:e.currentKey++})}}]}}]),(0,a.default)(e,[{key:"toHtml",value:function(e){return this.parse(e,0)}},{key:"escapeRegExp",value:function(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}},{key:"isFile",value:function(e,t){return null!==e.toLowerCase().match(new RegExp("."+t+"$"))}},{key:"handleImagePreview",value:function(e,t){e.preventDefault(),this.imageViewer.show(t)}},{key:"parseString",value:function(e,t){var n=this;if(this.PARSERS.length<=t)return[e];if(""===e)return[e];var r=(0,i.default)(e.matchAll(this.PARSERS[t].regExp));if(0===r.length)return this.parseString(e,t+1);var o=[],a=0;return r.forEach((function(r,s){r.index>a&&o.push.apply(o,(0,i.default)(n.parseString(e.substring(a,r.index),t+1)));var l=n.PARSERS[t].callback(r,s,t);o.push(l),a=r.index+r[0].length})),e.length>a&&o.push.apply(o,(0,i.default)(this.parseString(e.substring(a),t+1))),o}},{key:"parse",value:function(e,t){var n=this;return"string"==typeof e?this.parseString(e,0):s.default.isValidElement(e)&&"a"!==e.type&&"button"!==e.type?s.default.cloneElement(e,{key:t},this.parse(e.props.children)):Array.isArray(e)?e.map((function(e,t){return n.parse(e,t)})):e}}]),e}();n.default=u},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/toConsumableArray":147,"js-base64":245,react:307,"utils/image-viewer":120}],118:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/typeof")),o=r(e("@babel/runtime/helpers/toConsumableArray")),a=r(e("@babel/runtime/helpers/inherits")),s=(r(e("@babel/runtime/helpers/possibleConstructorReturn")),r(e("@babel/runtime/helpers/getPrototypeOf")),r(e("@babel/runtime/helpers/wrapNativeSuper"))),l=r(e("@babel/runtime/helpers/classCallCheck")),c=r(e("@babel/runtime/helpers/createClass")),u=r(e("react"));function p(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return f(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return f(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw o}}}}function f(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function d(e,t){d=function(e,t){return new l(e,void 0,t)};
1var n=(0,s.default)(RegExp),r=RegExp.prototype,o=new WeakMap;function l(e,t,r){var i=n.call(this,e,t);return o.set(i,r||o.get(e)),i}function c(e,t){var n=o.get(t);return Object.keys(n).reduce((function(t,r){return t[r]=e[n[r]],t}),Object.create(null))}return(0,a.default)(l,n),l.prototype.exec=function(e){var t=r.exec.call(this,e);return t&&(t.groups=c(t,this)),t},l.prototype[Symbol.replace]=function(e,t){if("string"==typeof t){var n=o.get(this);return r[Symbol.replace].call(this,e,t.replace(/\$<([^>]+)>/g,(function(e,t){return"$"+n[t]})))}if("function"==typeof t){var a=this;return r[Symbol.replace].call(this,e,(function(){var e=[];return e.push.apply(e,arguments),"object"!==(0,i.default)(e[e.length-1])&&e.push(c(e,a)),t.apply(this,e)}))}return r[Symbol.replace].call(this,e,t)},d.apply(this,arguments)}var h=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};(0,l.default)(this,e),this.configuration=t,this.rendererConfiguration=n,this.currentKey=0,this.parse=this.parse.bind(this)}return(0,c.default)(e,[{key:"PARSERS",get:function(){var e=this;return[{regExp:/\[([a-z-]+?)(\s[^\]]*?)?]/g,callback:function(t,n,r){var i=t[1],o={};if(t[2]){var a,s=p(t[2].matchAll(d(/([0-9A-Za-z]+?)="((?:(?!")[\s\S])+?)"/gi,{attribute:1,value:2})));try{for(s.s();!(a=s.n()).done;){var l=a.value;o[l.groups.attribute]=l.groups.value}}catch(e){s.e(e)}finally{s.f()}}var c=e.rendererConfiguration.onShortcodeRender(i,o,e.currentKey++,t[0]);return null!==c?c:t[0]}},{regExp:/\n/g,callback:function(t,n,r){return u.default.createElement("br",{key:e.currentKey++})}}]}}]),(0,c.default)(e,[{key:"toHtml",value:function(e){return this.parse(e,0)}},{key:"escapeRegExp",value:function(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}},{key:"isFile",value:function(e,t){return null!==e.toLowerCase().match(new RegExp("."+t+"$"))}},{key:"parseString",value:function(e,t){var n=this;if(this.PARSERS.length<=t)return[e];if(""===e)return[e];var r=(0,o.default)(e.matchAll(this.PARSERS[t].regExp));if(0===r.length)return this.parseString(e,t+1);var i=[],a=0;return r.forEach((function(r,s){r.index>a&&i.push.apply(i,(0,o.default)(n.parseString(e.substring(a,r.index),t+1)));var l=n.PARSERS[t].callback(r,s,t);i.push(l),a=r.index+r[0].length})),e.length>a&&i.push.apply(i,(0,o.default)(this.parseString(e.substring(a),t+1))),i}},{key:"parse",value:function(e,t){var n=this;return"string"==typeof e?this.parseString(e,0):u.default.isValidElement(e)&&"a"!==e.type&&"button"!==e.type?u.default.cloneElement(e,{key:t},this.parse(e.props.children)):Array.isArray(e)?e.map((function(e,t){return n.parse(e,t)})):e}}]),e}();n.default=h},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/getPrototypeOf":132,"@babel/runtime/helpers/inherits":133,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/possibleConstructorReturn":144,"@babel/runtime/helpers/toConsumableArray":147,"@babel/runtime/helpers/typeof":148,"@babel/runtime/helpers/wrapNativeSuper":150,react:307}],119:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.getAncestorBackgroundColor=function(e){function t(e){return"transparent"===e||"rgba"===e.substring(0,4)}var n=e.css("background-color");t(n)&&e.parents().each((function(){if(!t((0,i.default)(this).css("background-color")))return n=(0,i.default)(this).css("background-color"),!1}));return n};var i=r(e("jquery"))},{"@babel/runtime/helpers/interopRequireDefault":134,jquery:244}],120:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=r(e("@babel/runtime/helpers/classCallCheck")),o=r(e("@babel/runtime/helpers/createClass")),a=r(e("jquery")),s=function(){function e(){(0,i.default)(this,e),this.hide=this.hide.bind(this)}return(0,o.default)(e,[{key:"HOURGLASS_ICON",get:function(){return"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3wQEDB4ktAYXpwAAAb5JREFUSMe1lr9qFFEUh78rg8gWW1ikSLEWgkVq2SoYsbBIk1dYEAsxaJt3sLAIFkEEX0FSRlgMhKAPkEIQwZDChATSBLMQP5uz4bKZmZ3ZxR+cYs75nT9z7rlnJpFBfQC8B24xG/4Cz1NK38eKYoKwADxiPiwA1wnSpFUdAO+A+y0D/wBeppQ+5sqihHgAdIBRSumsSWT1bvgcNCF31Et1tWnp6mr4dCZtNw4zpXQB7AJrLdqzBuyGb6OKBuq52m3A7QZ3UGZPVW0CfgJvgc/As4r4H4CnwGvgXkrpDy36uh6VPVRPvYnTsJ2r662HWS3U/ZDH6kkW/CR0Y3sx041Re+qh+kXtq59C+qE7V
1Ht1MWpXQkrpF7ACdIFhZhqGbiU4syX474gWHUU7FjP9YuiOprVo2iF/jUO8U3Hj94NTzJLgVYxgL0v4JqTI3rD9mEZ1v9WN7Hk7G9Pt8d5RN4LbaZPgelWE7JVctL3MXrkqqhLsqFvqbXVoNYbB2VJ32rTnMlbwptOxWbeuyxL0w/GJetUgwVVwVfuT8crGawm4AEbAi4ZdHYXPEvCtrvpl58dy3Rscx9dsnt+W41zxD60+eUN8VNiNAAAAAElFTkSuQmCC"}}]),(0,o.default)(e,[{key:"setup",value:function(){if(!this.imagePreview){var e=(0,a.default)("body");e.append('<div class="wcImagePreviewLayer wcHide"> </div>'),this.imagePreview=e.find(".wcImagePreviewLayer"),this.imagePreview.click(this.hide)}}},{key:"show",value:function(e){var t=this;this.setup(),this.clearRemnants(),this.addAndShowHourGlass();var n=(0,a.default)('<img style="display:none;" src="" alt="Image preview popup" />');n.on("load",(function(){t.removeHourGlass(),(0,a.default)(this).show()})),n.attr("src",e),n.appendTo(this.imagePreview),n.click(this.hide)}},{key:"hide",value:function(){this.clearRemnants(),this.imagePreview.addClass("wcHide"),this.imagePreview.removeClass("wcShow"),(0,a.default)("body").removeClass("wcScrollOff")}},{key:"clearRemnants",value:function(){this.imagePreview.find("img").remove()}},{key:"addAndShowHourGlass",value:function(){var e=(0,a.default)('<img class="wcHourGlass" src="" alt="hourglass" />');e.attr("src",this.HOURGLASS_ICON),e.appendTo(this.imagePreview),this.imagePreview.removeClass("wcHide"),this.imagePreview.addClass("wcShow"),(0,a.default)("body").addClass("wcScrollOff")}},{key:"removeHourGlass",value:function(){this.imagePreview.find(".wcHourGlass").remove()}}]),e}();n.default=s},{"@babel/runtime/helpers/classCallCheck":127,"@babel/runtime/helpers/createClass":129,"@babel/runtime/helpers/interopRequireDefault":134,jquery:244}],121:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(e){return(0,o.default)(e.reduce((function(e,t){return e.set(t.id,t)}),new Map)).map((function(e){var t=(0,i.default)(e,2);t[0];return t[1]})).sort((function(e,t){return e.sortKey<t.sortKey?-1:e.sortKey>t.sortKey?1:0}))};var i=r(e("@babel/runtime/helpers/slicedToArray")),o=r(e("@babel/runtime/helpers/toConsumableArray"))},{"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/slicedToArray":146,"@babel/runtime/helpers/toConsumableArray":147}],122:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.uniqueId=function(){return Math.random().toString(36).substr(2,9)},n.capitalizeFirstLetter=function(e){return e.charAt(0).toUpperCase()+e.slice(1)},n.htmlDecode=function(e){return r("<textarea/>").html(e).text()},n.sprintf=function(){for(var e=Array.prototype.slice.call(arguments),t=e.slice(1,-1),n=e[0],r=isNaN(parseInt(e[e.length-1]))?e[e.length-1]:Number(e[e.length-1]),i=t.concat(r),o=n,a=0;a<i.length;a++)o=o.replace(/%d|%s/,i[a]);return o};var r=e("jquery")},{jquery:244}],123:[function(e,t,n){t.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}},{}],124:[function(e,t,n){t.exports=function(e){if(Array.isArray(e))return e}},{}],125:[function(e,t,n){var r=e("./arrayLikeToArray");t.exports=function(e){if(Array.isArray(e))return r(e)}},{"./arrayLikeToArray":123}],126:[function(e,t,n){t.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},{}],127:[function(e,t,n){t.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},{}],128:[function(e,t,n){var r=e("./setPrototypeOf"),i=e("./isNativeReflectConstruct");function o(e,n,a){return i()?t.exports=o=Reflect.construct:t.exports=o=function(e,t,n){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return n&&r(o,n.prototype),o},o.apply(null,arguments)}t.exports=o},{"./isNativeReflectConstruct":137,"./setPrototypeOf":145}],129:[function(e,t,n){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}t.exports=function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}},{}],130:[function(e,t,n){t.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}},{}],131:[function(e,t,n){function r(){return t.exports=r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},r.apply(this,arguments)}t.exports=r},{}
1],132:[function(e,t,n){function r(e){return t.exports=r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},r(e)}t.exports=r},{}],133:[function(e,t,n){var r=e("./setPrototypeOf");t.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)}},{"./setPrototypeOf":145}],134:[function(e,t,n){t.exports=function(e){return e&&e.__esModule?e:{default:e}}},{}],135:[function(e,t,n){var r=e("@babel/runtime/helpers/typeof");function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}t.exports=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if(Object.prototype.hasOwnProperty.call(e,a)){var s=o?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(n,a,s):n[a]=e[a]}return n.default=e,t&&t.set(e,n),n}},{"@babel/runtime/helpers/typeof":148}],136:[function(e,t,n){t.exports=function(e){return-1!==Function.toString.call(e).indexOf("[native code]")}},{}],137:[function(e,t,n){t.exports=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}},{}],138:[function(e,t,n){t.exports=function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}},{}],139:[function(e,t,n){t.exports=function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}}},{}],140:[function(e,t,n){t.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}},{}],141:[function(e,t,n){t.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}},{}],142:[function(e,t,n){var r=e("./objectWithoutPropertiesLoose");t.exports=function(e,t){if(null==e)return{};var n,i,o=r(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}},{"./objectWithoutPropertiesLoose":143}],143:[function(e,t,n){t.exports=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}},{}],144:[function(e,t,n){var r=e("@babel/runtime/helpers/typeof"),i=e("./assertThisInitialized");t.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?i(e):t}},{"./assertThisInitialized":126,"@babel/runtime/helpers/typeof":148}],145:[function(e,t,n){function r(e,n){return t.exports=r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},r(e,n)}t.exports=r},{}],146:[function(e,t,n){var r=e("./arrayWithHoles"),i=e("./iterableToArrayLimit"),o=e("./unsupportedIterableToArray"),a=e("./nonIterableRest");t.exports=function(e,t){return r(e)||i(e,t)||o(e,t)||a()}},{"./arrayWithHoles":124,"./iterableToArrayLimit":139,"./nonIterableRest":140,"./unsupportedIterableToArray":149}],147:[function(e,t,n){var r=e("./arrayWithoutHoles"),i=e("./iterableToArray"),o=e("./unsupportedIterableToArray"),a=e("./nonIterableSpread");t.exports=function(e){return r(e)||i(e)||o(e)||a()}},{"./arrayWithoutHoles":125,"./iterableToArray":138,"./nonIterableSpread":141,"./unsupportedIterableToArray":149}],148:[function(e,t,n){function r(e){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?t.exports=r=function(e){return typeof e}:t.exports=r=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}t.exports=r},{}],149:[function(e,t,n){var r=e("./arrayLikeToArray");t.exports=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}},{"./arrayLikeToArray":123}],150:[function(e,t,n){var r=e("./getPrototypeOf"),i=e("./setPrototypeOf"),o=e("./isNativeFunction"),a=e("./construct");function s(e){var n="function"==typeof Map?new Map:void 0;return t.exports=s=function(e){if(null===e||!o(e))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");
vendor: 20,859 bytes, lines 1-8
1if(void 0!==n){if(n.has(e))return n.get(e);n.set(e,t)}function t(){return a(e,arguments,r(this).constructor)}return t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i(t,e)},s(e)}t.exports=s},{"./construct":128,"./getPrototypeOf":132,"./isNativeFunction":136,"./setPrototypeOf":145}],151:[function(e,t,n){"use strict";n.byteLength=function(e){var t=c(e),n=t[0],r=t[1];return 3*(n+r)/4-r},n.toByteArray=function(e){var t,n,r=c(e),a=r[0],s=r[1],l=new o(function(e,t,n){return 3*(t+n)/4-n}(0,a,s)),u=0,p=s>0?a-4:a;for(n=0;n<p;n+=4)t=i[e.charCodeAt(n)]<<18|i[e.charCodeAt(n+1)]<<12|i[e.charCodeAt(n+2)]<<6|i[e.charCodeAt(n+3)],l[u++]=t>>16&255,l[u++]=t>>8&255,l[u++]=255&t;2===s&&(t=i[e.charCodeAt(n)]<<2|i[e.charCodeAt(n+1)]>>4,l[u++]=255&t);1===s&&(t=i[e.charCodeAt(n)]<<10|i[e.charCodeAt(n+1)]<<4|i[e.charCodeAt(n+2)]>>2,l[u++]=t>>8&255,l[u++]=255&t);return l},n.fromByteArray=function(e){for(var t,n=e.length,i=n%3,o=[],a=0,s=n-i;a<s;a+=16383)o.push(u(e,a,a+16383>s?s:a+16383));1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return o.join("")};for(var r=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,l=a.length;s<l;++s)r[s]=a[s],i[a.charCodeAt(s)]=s;function c(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function u(e,t,n){for(var i,o,a=[],s=t;s<n;s+=3)i=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),a.push(r[(o=i)>>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return a.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},{}],152:[function(e,t,n){},{}],153:[function(e,t,n){(function(t){(function(){
2/*!
3 * The buffer module from node.js, for the browser.
4 *
5 * @author   Feross Aboukhadijeh <https://feross.org>
6 * @license  MIT
7 */
8"use strict";var t=e("base64-js"),r=e("ieee754");n.Buffer=o,n.SlowBuffer=function(e){+e!=e&&(e=0);return o.alloc(+e)},n.INSPECT_MAX_BYTES=50;function i(e){if(e>2147483647)throw new RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return t.__proto__=o.prototype,t}function o(e,t,n){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return l(e)}return a(e,t,n)}function a(e,t,n){if("string"==typeof e)return function(e,t){"string"==typeof t&&""!==t||(t="utf8");if(!o.isEncoding(t))throw new TypeError("Unknown encoding: "+t);var n=0|p(e,t),r=i(n),a=r.write(e,t);a!==n&&(r=r.slice(0,a));return r}(e,t);if(ArrayBuffer.isView(e))return c(e);if(null==e)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(F(e,ArrayBuffer)||e&&F(e.buffer,ArrayBuffer))return function(e,t,n){if(t<0||e.byteLength<t)throw new RangeError('"offset" is outside of buffer bounds');if(e.byteLength<t+(n||0))throw new RangeError('"length" is outside of buffer bounds');var r;r=void 0===t&&void 0===n?new Uint8Array(e):void 0===n?new Uint8Array(e,t):new Uint8Array(e,t,n);return r.__proto__=o.prototype,r}(e,t,n);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');var r=e.valueOf&&e.valueOf();if(null!=r&&r!==e)return o.from(r,t,n);var a=function(e){if(o.isBuffer(e)){var t=0|u(e.length),n=i(t);return 0===n.length||e.copy(n,0,0,t),n}if(void 0!==e.length)return"number"!=typeof e.length||U(e.length)?i(0):c(e);if("Buffer"===e.type&&Array.isArray(e.data))return c(e.data)}(e);if(a)return a;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return o.from(e[Symbol.toPrimitive]("string"),t,n);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function s(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function l(e){return s(e),i(e<0?0:0|u(e))}function c(e){for(var t=e.length<0?0:0|u(e.length),n=i(t),r=0;r<t;r+=1)n[r]=255&e[r];return n}function u(e){if(e>=2147483647)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+2147483647..toString(16)+" bytes");return 0|e}function p(e,t){if(o.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||F(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var n=e.length,r=arguments.length>2&&!0===arguments[2];if(!r&&0===n)return 0;for(var i=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":return I(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return N(e).length;default:if(i)return r?-1:I(e).length;t=(""+t).toLowerCase(),i=!0}}function f(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return T(this,t,n);case"utf8":case"utf-8":return k(this,t,n);case"ascii":return S(this,t,n);case"latin1":case"binary":return E(this,t,n);case"base64":return _(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function d(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function h(e,t,n,r,i){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),U(n=+n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0){if(!i)return-1;n=0}if("string"==typeof t&&(t=o.from(t,r)),o.isBuffer(t))return 0===t.length?-1:m(e,t,n,r,i);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):m(e,[t],n,r,i);throw new TypeError("val must be string, number or Buffer")}function m(e,t,n,r,i){var o,a=1,s=e.length,l=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,l/=2,n/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var u=-1;for(o=n;o<s;o++)if(c(e,o)===c(t,-1===u?0:o-u)){if(-1===u&&(u=o),o-u+1===l)return u*a}else-1!==u&&(o-=o-u),u=-1}else for(n+l>s&&(n=s-l),o=n;o>=0;o--){for(var p=!0,f=0;f<l;f++)if(c(e,o+f)!==c(t,f)){p=!1;break}if(p)return o}return-1}function y(e,t,n,r){n=Number(n)||0;var i=e.length-n;r?(r=Number(r))>i&&(r=i):r=i;var o=t.length;r>o/2&&(r=o/2);for(var a=0;a<r;++a){var s=parseInt(t.substr(2*a,2),16);if(U(s))return a;e[n+a]=s}return a}function b(e,t,n,r){return L(I(t,e.length-n),e,n,r)}function v(e,t,n,r){return L(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function g(e,t,n,r){return v(e,t,n,r)}function w(e,t,n,r){return L(N(t),e,n,r)}function C(e,t,n,r){return L(function(e,t){for(var n,r,i,o=[],a=0;a<e.length&&!((t-=2)<0);++a)n=e.charCodeAt(a),r=n>>8,i=n%256,o.push(i),o.push(r);return o}(t,e.length-n),e,n,r)}function _(e,n,r){return 0===n&&r===e.length?t.fromByteArray(e):t.fromByteArray(e.slice(n,r))}function k(e,t,n){n=Math.min(e.length,n);for(var r=[],i=t;i<n;){var o,a,s,l,c=e[i],u=null,p=c>239?4:c>223?3:c>191?2:1;if(i+p<=n)switch(p){case 1:c<128&&(u=c);break;case 2:128==(192&(o=e[i+1]))&&(l=(31&c)<<6|63&o)>127&&(u=l);break;case 3:o=e[i+1],a=e[i+2],128==(192&o)&&128==(192&a)&&(l=(15&c)<<12|(63&o)<<6|63&a)>2047&&(l<55296||l>57343)&&(u=l);break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&(l=(15&c)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&l<1114112&&(u=l)}null===u?(u=65533,p=1):u>65535&&(u-=65536,r.push(u>>>10&1023|55296),u=56320|1023&u),r.push(u),i+=p}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=4096));return n}(r)}n.kMaxLength=2147483647,o.TYPED_ARRAY_SUPPORT=function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()}catch(e){return!1}}(),o.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(o.prototype,"parent",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.buffer}}),Object.defineProperty(o.prototype,"offset",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.byteOffset}}),"undefined"!=typeof Symbol&&null!=Symbol.species&&o[Symbol.species]===o&&Object.defineProperty(o,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1}),o.poolSize=8192,o.from=function(e,t,n){return a(e,t,n)},o.prototype.__proto__=Uint8Array.prototype,o.__proto__=Uint8Array,o.alloc=function(e,t,n){return function(e,t,n){return s(e),e<=0?i(e):void 0!==t?"string"==typeof n?i(e).fill(t,n):i(e).fill(t):i(e)}(e,t,n)},o.allocUnsafe=function(e){return l(e)},o.allocUnsafeSlow=function(e){return l(e)},o.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==o.prototype},o.compare=function(e,t){if(F(e,Uint8Array)&&(e=o.from(e,e.offset,e.byteLength)),F(t,Uint8Array)&&(t=o.from(t,t.offset,t.byteLength)),!o.isBuffer(e)||!o.isBuffer(t))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;for(var n=e.length,r=t.length,i=0,a=Math.min(n,r);i<a;++i)if(e[i]!==t[i]){n=e[i],r=t[i];break}return n<r?-1:r<n?1:0},o.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},o.concat=function(e,t){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return o.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=o.allocUnsafe(t),i=0;for(n=0;n<e.length;++n){var a=e[n];if(F(a,Uint8Array)&&(a=o.from(a)),!o.isBuffer(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(r,i),i+=a.length}return r},o.byteLength=p,o.prototype._isBuffer=!0,o.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)d(this,t,t+1);return this},o.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)d(this,t,t+3),d(this,t+1,t+2);return this},o.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)d(this,t,t+7),d(this,t+1,t+6),d(this,t+2,t+5),d(this,t+3,t+4);return this},o.prototype.toString=function(){var e=this.length;return 0===e?"":0===arguments.length?k(this,0,e):f.apply(this,arguments)},o.prototype.toLocaleString=o.prototype.toString,o.prototype.equals=function(e){if(!o.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===o.compare(this,e)},o.prototype.inspect=function(){var e="",t=n.INSPECT_MAX_BYTES;return e=this.toString("hex",0,t).replace(/(.{2})/g,"$1 ").trim(),this.length>t&&(e+=" ... "),"<Buffer "+e+">"},o.prototype.compare=function(e,t,n,r,i){if(F(e,Uint8Array)&&(e=o.from(e,e.offset,e.byteLength)),!o.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(this===e)return 0;for(var a=(i>>>=0)-(r>>>=0),s=(n>>>=0)-(t>>>=0),l=Math.min(a,s),c=this.slice(r,i),u=e.slice(t,n),p=0;p<l;++p)if(c[p]!==u[p]){a=c[p],s=u[p];break}return a<s?-1:s<a?1:0},o.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},o.prototype.indexOf=function(e,t,n){return h(this,e,t,n,!0)},o.prototype.lastIndexOf=function(e,t,n){return h(this,e,t,n,!1)},o.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t>>>=0,isFinite(n)?(n>>>=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var i=this.length-t;if((void 0===n||n>i)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return y(this,e,t,n);case"utf8":case"utf-8":return b(this,e,t,n);case"ascii":return v(this,e,t,n);case"latin1":case"binary":return g(this,e,t,n);case"base64":return w(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return C(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function S(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;i<n;++i)r+=String.fromCharCode(127&e[i]);return r}function E(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;i<n;++i)r+=String.fromCharCode(e[i]);return r}function T(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var i="",o=t;o<n;++o)i+=A(e[o]);return i}function O(e,t,n){for(var r=e.slice(t,n),i="",o=0;o<r.length;o+=2)i+=String.fromCharCode(r[o]+256*r[o+1]);return i}function P(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function R(e,t,n,r,i,a){if(!o.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<a)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function x(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function D(e,t,n,i,o){return t=+t,n>>>=0,o||x(e,0,n,4),r.write(e,t,n,i,23,4),n+4}function j(e,t,n,i,o){return t=+t,n>>>=0,o||x(e,0,n,8),r.write(e,t,n,i,52,8),n+8}o.prototype.slice=function(e,t){var n=this.length;(e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t<e&&(t=e);var r=this.subarray(e,t);return r.__proto__=o.prototype,r},o.prototype.readUIntLE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=this[e],i=1,o=0;++o<t&&(i*=256);)r+=this[e+o]*i;return r},o.prototype.readUIntBE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=this[e+--t],i=1;t>0&&(i*=256);)r+=this[e+--t]*i;return r},o.prototype.readUInt8=function(e,t){return e>>>=0,t||P(e,1,this.length),this[e]},o.prototype.readUInt16LE=function(e,t){return e>>>=0,t||P(e,2,this.length),this[e]|this[e+1]<<8},o.prototype.readUInt16BE=function(e,t){return e>>>=0,t||P(e,2,this.length),this[e]<<8|this[e+1]},o.prototype.readUInt32LE=function(e,t){return e>>>=0,t||P(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},o.prototype.readUInt32BE=function(e,t){return e>>>=0,t||P(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},o.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=this[e],i=1,o=0;++o<t&&(i*=256);)r+=this[e+o]*i;return r>=(i*=128)&&(r-=Math.pow(2,8*t)),r},o.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=t,i=1,o=this[e+--r];r>0&&(i*=256);)o+=this[e+--r]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},o.prototype.readInt8=function(e,t){return e>>>=0,t||P(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},o.prototype.readInt16LE=function(e,t){e>>>=0,t||P(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},o.prototype.readInt16BE=function(e,t){e>>>=0,t||P(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},o.prototype.readInt32LE=function(e,t){return e>>>=0,t||P(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},o.prototype.readInt32BE=function(e,t){return e>>>=0,t||P(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},o.prototype.readFloatLE=function(e,t){return e>>>=0,t||P(e,4,this.length),r.read(this,e,!0,23,4)},o.prototype.readFloatBE=function(e,t){return e>>>=0,t||P(e,4,this.length),r.read(this,e,!1,23,4)},o.prototype.readDoubleLE=function(e,t){return e>>>=0,t||P(e,8,this.length),r.read(this,e,!0,52,8)},o.prototype.readDoubleBE=function(e,t){return e>>>=0,t||P(e,8,this.length),r.read(this,e,!1,52,8)},o.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t>>>=0,n>>>=0,r)||R(this,e,t,n,Math.pow(2,8*n)-1,0);var i=1,o=0;for(this[t]=255&e;++o<n&&(i*=256);)this[t+o]=e/i&255;return t+n},o.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t>>>=0,n>>>=0,r)||R(this,e,t,n,Math.pow(2,8*n)-1,0);var i=n-1,o=1;for(this[t+i]=255&e;--i>=0&&(o*=256);)this[t+i]=e/o&255;return t+n},o.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,1,255,0),this[t]=255&e,t+1},o.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},o.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},o.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},o.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},o.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=Math.pow(2,8*n-1);R(this,e,t,n,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o<n&&(a*=256);)e<0&&0===s&&0!==this[t+o-1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+n},o.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=Math.pow(2,8*n-1);R(this,e,t,n,i-1,-i)}var o=n-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+n},o.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},o.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},o.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},o.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},o.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||R(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},o.prototype.writeFloatLE=function(e,t,n){return D(this,e,t,!0,n)},o.prototype.writeFloatBE=function(e,t,n){return D(this,e,t,!1,n)},o.prototype.writeDoubleLE=function(e,t,n){return j(this,e,t,!0,n)},o.prototype.writeDoubleBE=function(e,t,n){return j(this,e,t,!1,n)},o.prototype.copy=function(e,t,n,r){if(!o.isBuffer(e))throw new TypeError("argument should be a Buffer");if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var i=r-n;if(this===e&&"function"==typeof Uint8Array.prototype.copyWithin)this.copyWithin(t,n,r);else if(this===e&&n<t&&t<r)for(var a=i-1;a>=0;--a)e[a+t]=this[a+n];else Uint8Array.prototype.set.call(e,this.subarray(n,r),t);return i},o.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!o.isEncoding(r))throw new TypeError("Unknown encoding: "+r);if(1===e.length){var i=e.charCodeAt(0);("utf8"===r&&i<128||"latin1"===r)&&(e=i)}}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var a;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(a=t;a<n;++a)this[a]=e;else{var s=o.isBuffer(e)?e:o.from(e,r),l=s.length;
8if(0===l)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(a=0;a<n-t;++a)this[a+t]=s[a%l]}return this};var M=/[^+/0-9A-Za-z-_]/g;function A(e){return e<16?"0"+e.toString(16):e.toString(16)}function I(e,t){var n;t=t||1/0;for(var r=e.length,i=null,o=[],a=0;a<r;++a){if((n=e.charCodeAt(a))>55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function N(e){return t.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(M,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function L(e,t,n,r){for(var i=0;i<r&&!(i+n>=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function F(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function U(e){return e!=e}}).call(this)}).call(this,e("buffer").Buffer)},{"base64-js":151,buffer:153,ieee754:230}],154:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=e("./"),o=i(r("String.prototype.indexOf"));t.exports=function(e,t){var n=r(e,!!t);return"function"==typeof n&&o(e,".prototype.")>-1?i(n):n}},{"./":155,"get-intrinsic":225}],155:[function(e,t,n){"use strict";var r=e("function-bind"),i=e("get-intrinsic"),o=i("%Function.prototype.apply%"),a=i("%Function.prototype.call%"),s=i("%Reflect.apply%",!0)||r.call(a,o),l=i("%Object.defineProperty%",!0);if(l)try{l({},"a",{value:1})}catch(e){l=null}t.exports=function(){return s(r,a,arguments)};var c=function(){return s(r,o,arguments)};l?l(t.exports,"apply",{value:c}):t.exports.apply=c},{"function-bind":224,"get-intrinsic":225}],156:[function(e,t,n){
9/*!
10  Copyright (c) 2017 Jed Watson.
11  Licensed under the MIT License (MIT), see
12  http://jedwatson.github.io/classnames
13*/
14!function(){"use strict";var e={}.hasOwnProperty;function n(){for(var t=[],r=0;r<arguments.length;r++){var i=arguments[r];if(i){var o=typeof i;if("string"===o||"number"===o)t.push(i);else if(Array.isArray(i)&&i.length){var a=n.apply(null,i);a&&t.push(a)}else if("object"===o)for(var s in i)e.call(i,s)&&i[s]&&t.push(s)}}return t.join(" ")}void 0!==t&&t.exports?(n.default=n,t.exports=n):"function"==typeof define&&"object"==typeof define.amd&&define.amd?define("classnames",[],(function(){return n})):window.classNames=n}()},{}],157:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=Array.isArray,i=function(e){if(!e)return"";if("string"==typeof e)return e;if("object"!=typeof e)return"";var t,n,o="";if(r(e)){if(0===(n=e.length))return"";if(1===n)return i(e[0]);for(var a=0;a<n;)(t=i(e[a++]))&&(o+=(o&&" ")+t);return o}for(t in e)e[t]&&t&&(o+=(o&&" ")+t);return o},o=/\s+/,a=Object.create,s=Array.isArray;function l(){}function c(e,t){var n;if(e)if("string"!=typeof e){if("object"==typeof e)if(s(e)){n=e.length;for(var r=0;r<n;r++)c(e[r],t)}else{var i;for(i in e)t[i]=!!e[i]}}else{n=(e=e.split(o)).length;for(var a=0;a<n;a++)t[e[a]]=!0}}l.prototype=a(null),n.cnb=function(){var e=arguments.length;if(0===e)return"";if(1===e)return i(arguments[0]);for(var t,n=0,r="";n<e;)(t=i(arguments[n++]))&&(r+=(r&&" ")+t);return r},n.dcnb=function(){for(var e=arguments.length,t=new l,n=0;n<e;n++)c(arguments[n],t);var r,i="";for(r in t)t[r]&&r&&(i+=(i&&" ")+r);return i}},{}],158:[function(e,t,n){
15/*!
16 * cookie
17 * Copyright(c) 2012-2014 Roman Shtylman
18 * Copyright(c) 2015 Douglas Christopher Wilson
19 * MIT Licensed
20 */
21"use strict";n.parse=function(e,t){if("string"!=typeof e)throw new TypeError("argument str must be a string");for(var n={},i=t||{},a=e.split(o),l=i.decode||r,c=0;c<a.length;c++){var u=a[c],p=u.indexOf("=");if(!(p<0)){var f=u.substr(0,p).trim(),d=u.substr(++p,u.length).trim();'"'==d[0]&&(d=d.slice(1,-1)),null==n[f]&&(n[f]=s(d,l))}}return n},n.serialize=function(e,t,n){var r=n||{},o=r.encode||i;if("function"!=typeof o)throw new TypeError("option encode is invali
21d");if(!a.test(e))throw new TypeError("argument name is invalid");var s=o(t);if(s&&!a.test(s))throw new TypeError("argument val is invalid");var l=e+"="+s;if(null!=r.maxAge){var c=r.maxAge-0;if(isNaN(c)||!isFinite(c))throw new TypeError("option maxAge is invalid");l+="; Max-Age="+Math.floor(c)}if(r.domain){if(!a.test(r.domain))throw new TypeError("option domain is invalid");l+="; Domain="+r.domain}if(r.path){if(!a.test(r.path))throw new TypeError("option path is invalid");l+="; Path="+r.path}if(r.expires){if("function"!=typeof r.expires.toUTCString)throw new TypeError("option expires is invalid");l+="; Expires="+r.expires.toUTCString()}r.httpOnly&&(l+="; HttpOnly");r.secure&&(l+="; Secure");if(r.sameSite){switch("string"==typeof r.sameSite?r.sameSite.toLowerCase():r.sameSite){case!0:l+="; SameSite=Strict";break;case"lax":l+="; SameSite=Lax";break;case"strict":l+="; SameSite=Strict";break;case"none":l+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}}return l};var r=decodeURIComponent,i=encodeURIComponent,o=/; */,a=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/;function s(e,t){try{return t(e)}catch(t){return e}}},{}],159:[function(e,t,n){"use strict";var r=e("object-keys"),i="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),o=Object.prototype.toString,a=Array.prototype.concat,s=Object.defineProperty,l=s&&function(){var e={};try{for(var t in s(e,"x",{enumerable:!1,value:e}),e)return!1;return e.x===e}catch(e){return!1}}(),c=function(e,t,n,r){var i;(!(t in e)||"function"==typeof(i=r)&&"[object Function]"===o.call(i)&&r())&&(l?s(e,t,{configurable:!0,enumerable:!1,value:n,writable:!0}):e[t]=n)},u=function(e,t){var n=arguments.length>2?arguments[2]:{},o=r(t);i&&(o=a.call(o,Object.getOwnPropertySymbols(t)));for(var s=0;s<o.length;s+=1)c(e,o[s],t[o[s]],n[o[s]])};u.supportsDescriptors=!!l,t.exports=u},{"object-keys":250}],160:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=e("./CodePointAt"),o=e("./IsInteger"),a=e("./Type"),s=e("../helpers/maxSafeInteger"),l=r("%TypeError%");t.exports=function(e,t,n){if("String"!==a(e))throw new l("Assertion failed: `S` must be a String");if(!o(t)||t<0||t>s)throw new l("Assertion failed: `length` must be an integer >= 0 and <= 2**53");if("Boolean"!==a(n))throw new l("Assertion failed: `unicode` must be a Boolean");return n?t+1>=e.length?t+1:t+i(e,t)["[[CodeUnitCount]]"]:t+1}},{"../helpers/maxSafeInteger":211,"./CodePointAt":162,"./IsInteger":174,"./Type":191,"get-intrinsic":216}],161:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=e("call-bind/callBound"),o=r("%TypeError%"),a=e("./IsArray"),s=r("%Reflect.apply%",!0)||i("%Function.prototype.apply%");t.exports=function(e,t){var n=arguments.length>2?arguments[2]:[];if(!a(n))throw new o("Assertion failed: optional `argumentsList`, if provided, must be a List");return s(e,t,n)}},{"./IsArray":170,"call-bind/callBound":214,"get-intrinsic":216}],162:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%TypeError%"),i=e("call-bind/callBound"),o=e("../helpers/isLeadingSurrogate"),a=e("../helpers/isTrailingSurrogate"),s=e("./Type"),l=e("./UTF16DecodeSurrogatePair"),c=i("String.prototype.charAt"),u=i("String.prototype.charCodeAt");t.exports=function(e,t){if("String"!==s(e))throw new r("Assertion failed: `string` must be a String");var n=e.length;if(t<0||t>=n)throw new r("Assertion failed: `position` must be >= 0, and < the length of `string`");var i=u(e,t),p=c(e,t),f=o(i),d=a(i);if(!f&&!d)return{"[[CodePoint]]":p,"[[CodeUnitCount]]":1,"[[IsUnpairedSurrogate]]":!1};if(d||t+1===n)return{"[[CodePoint]]":p,"[[CodeUnitCount]]":1,"[[IsUnpairedSurrogate]]":!0};var h=u(e,t+1);return a(h)?{"[[CodePoint]]":l(i,h),"[[CodeUnitCount]]":2,"[[IsUnpairedSurrogate]]":!1}:{"[[CodePoint]]":p,"[[CodeUnitCount]]":1,"[[IsUnpairedSurrogate]]":!0}}},{"../helpers/isLeadingSurrogate":206,"../helpers/isTrailingSurrogate":210,"./Type":191,"./UTF16DecodeSurrogatePair":192,"call-bind/callBound":214,"get-intrinsic":216}],163:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%TypeError%"),i=e("./Type");t.exports=function(e,t){if("Boolean"!==i(t))throw new r("Assertion failed: Type(done) is not Boolean");return{value:e,done:t}}},{"./Type":191,"get-intrinsic":216}],164:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%TypeError%"),i=e("../helpers/isPropertyDescriptor"),o=e("../helpers/DefineOwnProperty"),a=e("./FromPropertyDescriptor"),s=e("./IsAccessorDescriptor"),l=e("./IsDataDescriptor"),c=e("./IsPropertyKey"),u=e("./SameValue"),p=e("./ToPropertyDescriptor"),f=e("./Type");t.exports=function(e,t,n){if("Object"!==f(e))throw new r("Assertion failed: Type(O) 
21is not Object");if(!c(t))throw new r("Assertion failed: IsPropertyKey(P) is not true");var d=i({Type:f,IsDataDescriptor:l,IsAccessorDescriptor:s},n)?n:p(n);if(!i({Type:f,IsDataDescriptor:l,IsAccessorDescriptor:s},d))throw new r("Assertion failed: Desc is not a valid Property Descriptor");return o(l,u,a,e,t,d)}},{"../helpers/DefineOwnProperty":203,"../helpers/isPropertyDescriptor":209,"./FromPropertyDescriptor":165,"./IsAccessorDescriptor":169,"./IsDataDescriptor":173,"./IsPropertyKey":175,"./SameValue":180,"./ToPropertyDescriptor":189,"./Type":191,"get-intrinsic":216}],165:[function(e,t,n){"use strict";var r=e("../helpers/assertRecord"),i=e("./Type");t.exports=function(e){if(void 0===e)return e;r(i,"Property Descriptor","Desc",e);var t={};return"[[Value]]"in e&&(t.value=e["[[Value]]"]),"[[Writable]]"in e&&(t.writable=e["[[Writable]]"]),"[[Get]]"in e&&(t.get=e["[[Get]]"]),"[[Set]]"in e&&(t.set=e["[[Set]]"]),"[[Enumerable]]"in e&&(t.enumerable=e["[[Enumerable]]"]),"[[Configurable]]"in e&&(t.configurable=e["[[Configurable]]"]),t}},{"../helpers/assertRecord":204,"./Type":191}],166:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%TypeError%"),i=e("object-inspect"),o=e("./IsPropertyKey"),a=e("./Type");t.exports=function(e,t){if("Object"!==a(e))throw new r("Assertion failed: Type(O) is not Object");if(!o(t))throw new r("Assertion failed: IsPropertyKey(P) is not true, got "+i(t));return e[t]}},{"./IsPropertyKey":175,"./Type":191,"get-intrinsic":216,"object-inspect":248}],167:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%TypeError%"),i=e("./GetV"),o=e("./IsCallable"),a=e("./IsPropertyKey");t.exports=function(e,t){if(!a(t))throw new r("Assertion failed: IsPropertyKey(P) is not true");var n=i(e,t);if(null!=n){if(!o(n))throw new r(t+"is not a function");return n}}},{"./GetV":168,"./IsCallable":171,"./IsPropertyKey":175,"get-intrinsic":216}],168:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%TypeError%"),i=e("./IsPropertyKey"),o=e("./ToObject");t.exports=function(e,t){if(!i(t))throw new r("Assertion failed: IsPropertyKey(P) is not true");return o(e)[t]}},{"./IsPropertyKey":175,"./ToObject":187,"get-intrinsic":216}],169:[function(e,t,n){"use strict";var r=e("has"),i=e("../helpers/assertRecord"),o=e("./Type");t.exports=function(e){return void 0!==e&&(i(o,"Property Descriptor","Desc",e),!(!r(e,"[[Get]]")&&!r(e,"[[Set]]")))}},{"../helpers/assertRecord":204,"./Type":191,has:228}],170:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%Array%"),i=!r.isArray&&e("call-bind/callBound")("Object.prototype.toString");t.exports=r.isArray||function(e){return"[object Array]"===i(e)}},{"call-bind/callBound":214,"get-intrinsic":216}],171:[function(e,t,n){"use strict";t.exports=e("is-callable")},{"is-callable":233}],172:[function(e,t,n){"use strict";var r=e("../GetIntrinsic.js")("%Reflect.construct%",!0),i=e("./DefinePropertyOrThrow");try{i({},"",{"[[Get]]":function(){}})}catch(e){i=null}if(i&&r){var o={},a={};i(a,"length",{"[[Get]]":function(){throw o},"[[Enumerable]]":!0}),t.exports=function(e){try{r(e,a)}catch(e){return e===o}}}else t.exports=function(e){return"function"==typeof e&&!!e.prototype}},{"../GetIntrinsic.js":202,"./DefinePropertyOrThrow":164}],173:[function(e,t,n){"use strict";var r=e("has"),i=e("../helpers/assertRecord"),o=e("./Type");t.exports=function(e){return void 0!==e&&(i(o,"Property Descriptor","Desc",e),!(!r(e,"[[Value]]")&&!r(e,"[[Writable]]")))}},{"../helpers/assertRecord":204,"./Type":191,has:228}],174:[function(e,t,n){"use strict";var r=e("./abs"),i=e("./floor"),o=e("../helpers/isNaN"),a=e("../helpers/isFinite");t.exports=function(e){if("number"!=typeof e||o(e)||!a(e))return!1;var t=r(e);return i(t)===t}},{"../helpers/isFinite":205,"../helpers/isNaN":207,"./abs":193,"./floor":194}],175:[function(e,t,n){"use strict";t.exports=function(e){return"string"==typeof e||"symbol"==typeof e}},{}],176:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%Symbol.match%",!0),i=e("is-regex"),o=e("./ToBoolean");t.exports=function(e){if(!e||"object"!=typeof e)return!1;if(r){var t=e[r];if(void 0!==t)return o(t)}return i(e)}},{"./ToBoolean":183,"get-intrinsic":216,"is-regex":235}],177:[function(e,t,n){"use strict";
21var r=e("get-intrinsic"),i=r("%Object.create%",!0),o=r("%TypeError%"),a=r("%SyntaxError%"),s=e("./IsArray"),l=e("./Type"),c=!({__proto__:null}instanceof Object);t.exports=function(e){if(null!==e&&"Object"!==l(e))throw new o("Assertion failed: `proto` must be null or an object");var t=arguments.length<2?[]:arguments[1];if(!s(t))throw new o("Assertion failed: `additionalInternalSlotsList` must be an Array");if(t.length>0)throw new a("es-abstract does not yet support internal slots");if(i)return i(e);if(c)return{__proto__:e};if(null===e)throw new a("native Object.create support is required to create null objects");var n=function(){};return n.prototype=e,new n}},{"./IsArray":170,"./Type":191,"get-intrinsic":216}],178:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%TypeError%"),i=e("call-bind/callBound")("RegExp.prototype.exec"),o=e("./Call"),a=e("./Get"),s=e("./IsCallable"),l=e("./Type");t.exports=function(e,t){if("Object"!==l(e))throw new r("Assertion failed: `R` must be an Object");if("String"!==l(t))throw new r("Assertion failed: `S` must be a String");var n=a(e,"exec");if(s(n)){var c=o(n,e,[t]);if(null===c||"Object"===l(c))return c;throw new r('"exec" method must return `null` or an Object')}return i(e,t)}},{"./Call":161,"./Get":166,"./IsCallable":171,"./Type":191,"call-bind/callBound":214,"get-intrinsic":216}],179:[function(e,t,n){"use strict";t.exports=e("../5/CheckObjectCoercible")},{"../5/CheckObjectCoercible":195}],180:[function(e,t,n){"use strict";var r=e("../helpers/isNaN");t.exports=function(e,t){return e===t?0!==e||1/e==1/t:r(e)&&r(t)}},{"../helpers/isNaN":207}],181:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%TypeError%"),i=e("./IsPropertyKey"),o=e("./SameValue"),a=e("./Type"),s=function(){try{return delete[].length,!0}catch(e){return!1}}();t.exports=function(e,t,n,l){if("Object"!==a(e))throw new r("Assertion failed: `O` must be an Object");if(!i(t))throw new r("Assertion failed: `P` must be a Property Key");if("Boolean"!==a(l))throw new r("Assertion failed: `Throw` must be a Boolean");if(l){if(e[t]=n,s&&!o(e[t],n))throw new r("Attempted to assign to readonly property.");return!0}try{return e[t]=n,!s||o(e[t],n)}catch(e){return!1}}},{"./IsPropertyKey":175,"./SameValue":180,"./Type":191,"get-intrinsic":216}],182:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=r("%Symbol.species%",!0),o=r("%TypeError%"),a=e("./IsConstructor"),s=e("./Type");t.exports=function(e,t){if("Object"!==s(e))throw new o("Assertion failed: Type(O) is not Object");var n=e.constructor;if(void 0===n)return t;if("Object"!==s(n))throw new o("O.constructor is not an Object");var r=i?n[i]:void 0;if(null==r)return t;if(a(r))return r;throw new o("no constructor found")}},{"./IsConstructor":172,"./Type":191,"get-intrinsic":216}],183:[function(e,t,n){"use strict";t.exports=function(e){return!!e}},{}],184:[function(e,t,n){"use strict";var r=e("../5/ToInteger"),i=e("./ToNumber");t.exports=function(e){var t=i(e);return 0!==t&&(t=r(t)),0===t?0:t}},{"../5/ToInteger":196,"./ToNumber":186}],185:[function(e,t,n){"use strict";var r=e("../helpers/maxSafeInteger"),i=e("./ToInteger");t.exports=function(e){var t=i(e);return t<=0?0:t>r?r:t}},{"../helpers/maxSafeInteger":211,"./ToInteger":184}],186:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=r("%TypeError%"),o=r("%Number%"),a=r("%RegExp%"),s=r("%parseInt%"),l=e("call-bind/callBound"),c=e("../helpers/regexTester"),u=e("../helpers/isPrimitive"),p=l("String.prototype.slice"),f=c(/^0b[01]+$/i),d=c(/^0o[0-7]+$/i),h=c(/^[-+]0x[0-9a-f]+$/i),m=c(new a("["+["…","​","￾"].join("")+"]","g")),y=["\t\n\v\f\r   ᠎    ","          \u2028","\u2029\ufeff"].join(""),b=new RegExp("(^["+y+"]+)|(["+y+"]+$)","g"),v=l("String.prototype.replace"),g=e("./ToPrimitive");t.exports=function e(t){var n=u(t)?t:g(t,o);if("symbol"==typeof n)throw new i("Cannot convert a Symbol value to a number");if("bigint"==typeof n)throw new i("Conversion from 'BigInt' to 'number' is not allowed.");if("string"==typeof n){if(f(n))return e(s(p(n,2),2));if(d(n))return e(s(p(n,2),8));if(m(n)||h(n))return NaN;var r=function(e){return v(e,b,"")}(n);if(r!==n)return e(r)}return o(n)}},{"../helpers/isPrimitive":208,"../helpers/regexTester":212,"./ToPrimitive":188,"call-bind/callBound":214,"get-intrinsic":216}],187:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%Object%"),i=e("./RequireObjectCoercible");t.exports=function(e){return i(e),r(e)}},{"./RequireObjectCoercible":179,"get-intrinsic":216}],188:[function(e,t,n){"use strict";var r=e("es-to-primitive/es2015");t.exports=function(e){return arguments.length>1?r(e,arguments[1]):r(e)}},{"es-to-primitive/es2015":219}],189:[function(e,t,n){"use strict";var r=e("has"),i=e("get-intrinsic")("%TypeError%"),o=e("./Type"),a=e("./ToBoolean"),s=e("./IsCallable");t.exports=function(e){if("Object"!==o(e))throw new i("ToPropertyDescriptor requires an object");var t={};if(r(e,"enumerable")&&(t["[[Enumerable]]"]=a(e.enumerable)),r(e,"configurable")&&(t["[[Configurable]]"]=a(e.configurable)),r(e,"value")&&(t["[[Value]]"]=e.value),r(e,"writable")&&(t["[[Writable]]"]=a(e.writable)),r(e,"get")){var n=e.get;if(void 0!==n&&!s(n))throw new i("getter must be a function");t["[[Get]]"]=n}if(r(e,"set")){var l=e.set;if(void 0!==l&&!s(l))throw new i("setter must be a function");t["[[Set]]"]=l}if((r(t,"[[Get]]")||r(t,"[[Set]]"))&&(r(t,"[[Value]]")||r(t,"[[Writable]]")))throw new i("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return t}},{"./IsCallable":171,"./ToBoolean":183,"./Type":191,"get-intrinsic":216,has:228}],190:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=r("%String%"),o=r("%TypeError%");t.exports=function(e){if("symbol"==typeof e)throw new o("Cannot convert a Symbol value to a string");return i(e)}},{"get-intrinsic":216}],191:[function(e,t,n){"use strict";var r=e("../5/Type");t.exports=function(e){return"symbol"==typeof e?"Symbol":"bigint"==typeof e?"BigInt":r(e)}},{"../5/Type":199}],192:[function(e,t,n){"use strict";
21var r=e("get-intrinsic"),i=r("%TypeError%"),o=r("%String.fromCharCode%"),a=e("../helpers/isLeadingSurrogate"),s=e("../helpers/isTrailingSurrogate");t.exports=function(e,t){if(!a(e)||!s(t))throw new i("Assertion failed: `lead` must be a leading surrogate char code, and `trail` must be a trailing surrogate char code");return o(e)+o(t)}},{"../helpers/isLeadingSurrogate":206,"../helpers/isTrailingSurrogate":210,"get-intrinsic":216}],193:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%Math.abs%");t.exports=function(e){return r(e)}},{"get-intrinsic":216}],194:[function(e,t,n){"use strict";var r=Math.floor;t.exports=function(e){return r(e)}},{}],195:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%TypeError%");t.exports=function(e,t){if(null==e)throw new r(t||"Cannot call method on "+e);return e}},{"get-intrinsic":216}],196:[function(e,t,n){"use strict";var r=e("./abs"),i=e("./floor"),o=e("./ToNumber"),a=e("../helpers/isNaN"),s=e("../helpers/isFinite"),l=e("../helpers/sign");t.exports=function(e){var t=o(e);return a(t)?0:0!==t&&s(t)?l(t)*i(r(t)):t}},{"../helpers/isFinite":205,"../helpers/isNaN":207,"../helpers/sign":213,"./ToNumber":197,"./abs":200,"./floor":201}],197:[function(e,t,n){"use strict";var r=e("./ToPrimitive");t.exports=function(e){var t=r(e,Number);if("string"!=typeof t)return+t;var n=t.replace(/^[ \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u0085]+|[ \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u0085]+$/g,"");return/^0[ob]|^[+-]0x/.test(n)?NaN:+n}},{"./ToPrimitive":198}],198:[function(e,t,n){"use strict";t.exports=e("es-to-primitive/es5")},{"es-to-primitive/es5":220}],199:[function(e,t,n){"use strict";t.exports=function(e){return null===e?"Null":void 0===e?"Undefined":"function"==typeof e||"object"==typeof e?"Object":"number"==typeof e?"Number":"boolean"==typeof e?"Boolean":"string"==typeof e?"String":void 0}},{}],200:[function(e,t,n){arguments[4][193][0].apply(n,arguments)},{dup:193,"get-intrinsic":216}],201:[function(e,t,n){arguments[4][194][0].apply(n,arguments)},{dup:194}],202:[function(e,t,n){"use strict";t.exports=e("get-intrinsic")},{"get-intrinsic":216}],203:[function(e,t,n){"use strict";var r=e("get-intrinsic")("%Object.defineProperty%",!0);if(r)try{r({},"a",{value:1})}catch(e){r=null}var i=e("call-bind/callBound")("Object.prototype.propertyIsEnumerable");
21t.exports=function(e,t,n,o,a,s){if(!r){if(!e(s))return!1;if(!s["[[Configurable]]"]||!s["[[Writable]]"])return!1;if(a in o&&i(o,a)!==!!s["[[Enumerable]]"])return!1;var l=s["[[Value]]"];return o[a]=l,t(o[a],l)}return r(o,a,n(s)),!0}},{"call-bind/callBound":214,"get-intrinsic":216}],204:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=r("%TypeError%"),o=r("%SyntaxError%"),a=e("has"),s={"Property Descriptor":function(e,t){if("Object"!==e(t))return!1;var n={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var r in t)if(a(t,r)&&!n[r])return!1;var o=a(t,"[[Value]]"),s=a(t,"[[Get]]")||a(t,"[[Set]]");if(o&&s)throw new i("Property Descriptors may not be both accessor and data descriptors");return!0}};t.exports=function(e,t,n,r){var a=s[t];if("function"!=typeof a)throw new o("unknown record type: "+t);if(!a(e,r))throw new i(n+" must be a "+t)}},{"get-intrinsic":216,has:228}],205:[function(e,t,n){"use strict";var r=Number.isNaN||function(e){return e!=e};t.exports=Number.isFinite||function(e){return"number"==typeof e&&!r(e)&&e!==1/0&&e!==-1/0}},{}],206:[function(e,t,n){"use strict";t.exports=function(e){return"number"==typeof e&&e>=55296&&e<=56319}},{}],207:[function(e,t,n){"use strict";t.exports=Number.isNaN||function(e){return e!=e}},{}],208:[function(e,t,n){"use strict";t.exports=function(e){return null===e||"function"!=typeof e&&"object"!=typeof e}},{}],209:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=e("has"),o=r("%TypeError%");t.exports=function(e,t){if("Object"!==e.Type(t))return!1;var n={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var r in t)if(i(t,r)&&!n[r])return!1;if(e.IsDataDescriptor(t)&&e.IsAccessorDescriptor(t))throw new o("Property Descriptors may not be both accessor and data descriptors");return!0}},{"get-intrinsic":216,has:228}],210:[function(e,t,n){"use strict";t.exports=function(e){return"number"==typeof e&&e>=56320&&e<=57343}},{}],211:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=r("%Math%"),o=r("%Number%");t.exports=o.MAX_SAFE_INTEGER||i.pow(2,53)-1},{"get-intrinsic":216}],212:[function(e,t,n){"use strict";var r=e("get-intrinsic")("RegExp.prototype.test"),i=e("call-bind");t.exports=function(e){return i(r,e)}},{"call-bind":215,"get-intrinsic":216}],213:[function(e,t,n){"use strict";t.exports=function(e){return e>=0?1:-1}},{}],214:[function(e,t,n){arguments[4][154][0].apply(n,arguments)},{"./":215,dup:154,"get-intrinsic":216}],215:[function(e,t,n){"use strict";var r=e("function-bind"),i=e("get-intrinsic"),o=i("%Function.prototype.apply%"),a=i("%Function.prototype.call%"),s=i("%Reflect.apply%",!0)||r.call(a,o),l=i("%Object.getOwnPropertyDescriptor%",!0),c=i("%Object.defineProperty%",!0),u=i("%Math.max%");if(c)try{c({},"a",{value:1})}catch(e){c=null}t.exports=function(e){var t=s(r,a,arguments);if(l&&c){var n=l(t,"length");n.configurable&&c(t,"length",{value:1+u(0,e.length-(arguments.length-1))})}return t};var p=function(){return s(r,o,arguments)};c?c(t.exports,"apply",{value:p}):t.exports.apply=p},{"function-bind":224,"get-intrinsic":216}],216:[function(e,t,n){"use strict";var r=SyntaxError,i=Function,o=TypeError,a=function(e){try{return i('"use strict"; return ('+e+").constructor;")()}catch(e){}},s=Object.getOwnPropertyDescriptor;if(s)try{s({},"")}catch(e){s=null}var l=function(){throw new o},c=s?function(){try{return l}catch(e){try{return s(arguments,"callee").get}catch(e){return l}}}():l,u=e("has-symbols")(),p=Object.getPrototypeOf||function(e){return e.__proto__},f={},d="undefined"==typeof Uint8Array?void 0:p(Uint8Array),h={"%AggregateError%":"undefined"==typeof AggregateError?void 0:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?void 0:ArrayBuffer,"%ArrayIteratorPrototype%":u?p([][Symbol.iterator]()):void 0,"%AsyncFromSyncIteratorPrototype%":void 0,"%AsyncFunction%":f,"%AsyncGenerator%":f,"%AsyncGeneratorFunction%":f,"%AsyncIteratorPrototype%":f,"%Atomics%":"undefined"==typeof Atomics?void 0:Atomics,"%BigInt%":"undefined"==typeof BigInt?void 0:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?void 0:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?void 0:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?void 0:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?void 0:FinalizationRegistry,"%Function%":i,"%GeneratorFunction%":f,"%Int8Array%":"undefined"==typeof Int8Array?void 0:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?void 0:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?void 0:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%
21IteratorPrototype%":u?p(p([][Symbol.iterator]())):void 0,"%JSON%":"object"==typeof JSON?JSON:void 0,"%Map%":"undefined"==typeof Map?void 0:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&u?p((new Map)[Symbol.iterator]()):void 0,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?void 0:Promise,"%Proxy%":"undefined"==typeof Proxy?void 0:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?void 0:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?void 0:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&u?p((new Set)[Symbol.iterator]()):void 0,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?void 0:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":u?p(""[Symbol.iterator]()):void 0,"%Symbol%":u?Symbol:void 0,"%SyntaxError%":r,"%ThrowTypeError%":c,"%TypedArray%":d,"%TypeError%":o,"%Uint8Array%":"undefined"==typeof Uint8Array?void 0:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?void 0:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?void 0:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?void 0:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?void 0:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?void 0:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?void 0:WeakSet},m={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},y=e("function-bind"),b=e("has"),v=y.call(Function.call,Array.prototype.concat),g=y.call(Function.apply,Array.prototype.splice),w=y.call(Function.call,String.prototype.replace),C=y.call(Function.call,String.prototype.slice),_=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,k=/\\(\\)?/g,S=function(e){var t=C(e,0,1),n=C(e,-1);if("%"===t&&"%"!==n)throw new r("invalid intrinsic syntax, expected closing `%`");if("%"===n&&"%"!==t)throw new r("invalid intrinsic syntax, expected opening `%`");var i=[];return w(e,_,(function(e,t,n,r){i[i.length]=n?w(r,k,"$1"):t||e})),i},E=function(e,t){var n,i=e;
21if(b(m,i)&&(i="%"+(n=m[i])[0]+"%"),b(h,i)){var s=h[i];if(s===f&&(s=function e(t){var n;if("%AsyncFunction%"===t)n=a("async function () {}");else if("%GeneratorFunction%"===t)n=a("function* () {}");else if("%AsyncGeneratorFunction%"===t)n=a("async function* () {}");else if("%AsyncGenerator%"===t){var r=e("%AsyncGeneratorFunction%");r&&(n=r.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&(n=p(i.prototype))}return h[t]=n,n}(i)),void 0===s&&!t)throw new o("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:n,name:i,value:s}}throw new r("intrinsic "+e+" does not exist!")};t.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new o("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new o('"allowMissing" argument must be a boolean');var n=S(e),i=n.length>0?n[0]:"",a=E("%"+i+"%",t),l=a.name,c=a.value,u=!1,p=a.alias;p&&(i=p[0],g(n,v([0,1],p)));for(var f=1,d=!0;f<n.length;f+=1){var m=n[f],y=C(m,0,1),w=C(m,-1);if(('"'===y||"'"===y||"`"===y||'"'===w||"'"===w||"`"===w)&&y!==w)throw new r("property names with quotes must have matching quotes");if("constructor"!==m&&d||(u=!0),b(h,l="%"+(i+="."+m)+"%"))c=h[l];else if(null!=c){if(!(m in c)){if(!t)throw new o("base intrinsic for "+e+" exists, but the property is not available.");return}if(s&&f+1>=n.length){var _=s(c,m);c=(d=!!_)&&"get"in _&&!("originalValue"in _.get)?_.get:c[m]}else d=b(c,m),c=c[m];d&&!u&&(h[l]=c)}}return c}},{"function-bind":224,has:228,"has-symbols":217}],217:[function(e,t,n){"use strict";var r="undefined"!=typeof Symbol&&Symbol,i=e("./shams");t.exports=function(){return"function"==typeof r&&("function"==typeof Symbol&&("symbol"==typeof r("foo")&&("symbol"==typeof Symbol("bar")&&i())))}},{"./shams":218}],218:[function(e,t,n){"use strict";t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),n=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(n))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var r=Object.getOwnPropertySymbols(e);if(1!==r.length||r[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(e,t);if(42!==i.value||!0!==i.enumerable)return!1}return!0}},{}],219:[function(e,t,n){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,i=e("./helpers/isPrimitive"),o=e("is-callable"),a=e("is-date-object"),s=e("is-symbol"),l=function(e,t){if(null==e)throw new TypeError("Cannot call method on "+e);if("string"!=typeof t||"number"!==t&&"string"!==t)throw new TypeError('hint must be "string" or "number"');var n,r,a,s="string"===t?["toString","valueOf"]:["valueOf","toString"];for(a=0;a<s.length;++a)if(n=e[s[a]],o(n)&&(r=n.call(e),i(r)))return r;throw new TypeError("No default value")},c=function(e,t){var n=e[t];if(null!=n){if(!o(n))throw new TypeError(n+" returned for property "+t+" of object "+e+" is not a function");return n}};t.exports=function(e){if(i(e))return e;var t,n="default";if(arguments.length>1&&(arguments[1]===String?n="string":arguments[1]===Number&&(n="number")),r&&(Symbol.toPrimitive?t=c(e,Symbol.toPrimitive):s(e)&&(t=Symbol.prototype.valueOf)),void 0!==t){var o=t.call(e,n);if(i(o))return o;throw new TypeError("unable to convert exotic object to primitive")}return"default"===n&&(a(e)||s(e))&&(n="string"),l(e,"default"===n?"number":n)}},{"./helpers/isPrimitive":221,"is-callable":233,"is-date-object":234,"is-symbol":241}],220:[function(e,t,n){"use strict";var r=Object.prototype.toString,i=e("./helpers/isPrimitive"),o=e("is-callable"),a=function(e){var t;if((t=arguments.length>1?arguments[1]:"[object Date]"===r.call(e)?String:Number)===String||t===Number){var n,a,s=t===String?["toString","valueOf"]:["valueOf","toString"];for(a=0;a<s.length;++a)if(o(e[s[a]])&&(n=e[s[a]](),i(n)))return n;throw new TypeError("No default value")}throw new TypeError("invalid [[DefaultValue]] hint supplied")};t.exports=function(e){return i(e)?e:arguments.length>1?a(e,arguments[1]):a(e)}},{"./helpers/isPrimitive":221,"is-callable":233}],221:[function(e,t,n){arguments[4][208][0].apply(n,arguments)},{dup:208}],222:[function(e,t,n){var r=Object.create||function(e){var t=function(){};return t.prototype=e,new t},i=Object.keys||function(e){var t=[];
vendor: 4,771 bytes, line 21
21for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);return n},o=Function.prototype.bind||function(e){var t=this;return function(){return t.apply(e,arguments)}};function a(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=r(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0}t.exports=a,a.EventEmitter=a,a.prototype._events=void 0,a.prototype._maxListeners=void 0;var s,l=10;try{var c={};Object.defineProperty&&Object.defineProperty(c,"x",{value:0}),s=0===c.x}catch(e){s=!1}function u(e){return void 0===e._maxListeners?a.defaultMaxListeners:e._maxListeners}function p(e,t,n){if(t)e.call(n);else for(var r=e.length,i=C(e,r),o=0;o<r;++o)i[o].call(n)}function f(e,t,n,r){if(t)e.call(n,r);else for(var i=e.length,o=C(e,i),a=0;a<i;++a)o[a].call(n,r)}function d(e,t,n,r,i){if(t)e.call(n,r,i);else for(var o=e.length,a=C(e,o),s=0;s<o;++s)a[s].call(n,r,i)}function h(e,t,n,r,i,o){if(t)e.call(n,r,i,o);else for(var a=e.length,s=C(e,a),l=0;l<a;++l)s[l].call(n,r,i,o)}function m(e,t,n,r){if(t)e.apply(n,r);else for(var i=e.length,o=C(e,i),a=0;a<i;++a)o[a].apply(n,r)}function y(e,t,n,i){var o,a,s;if("function"!=typeof n)throw new TypeError('"listener" argument must be a function');if((a=e._events)?(a.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),a=e._events),s=a[t]):(a=e._events=r(null),e._eventsCount=0),s){if("function"==typeof s?s=a[t]=i?[n,s]:[s,n]:i?s.unshift(n):s.push(n),!s.warned&&(o=u(e))&&o>0&&s.length>o){s.warned=!0;var l=new Error("Possible EventEmitter memory leak detected. "+s.length+' "'+String(t)+'" listeners added. Use emitter.setMaxListeners() to increase limit.');l.name="MaxListenersExceededWarning",l.emitter=e,l.type=t,l.count=s.length,"object"==typeof console&&console.warn&&console.warn("%s: %s",l.name,l.message)}}else s=a[t]=n,++e._eventsCount;return e}function b(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var e=new Array(arguments.length),t=0;t<e.length;++t)e[t]=arguments[t];this.listener.apply(this.target,e)}}function v(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=o.call(b,r);return i.listener=n,r.wrapFn=i,i}function g(e,t,n){var r=e._events;if(!r)return[];var i=r[t];return i?"function"==typeof i?n?[i.listener||i]:[i]:n?function(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}(i):C(i,i.length):[]}function w(e){var t=this._events;if(t){var n=t[e];if("function"==typeof n)return 1;if(n)return n.length}return 0}function C(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}s?Object.defineProperty(a,"defaultMaxListeners",{enumerable:!0,get:function(){return l},set:function(e){if("number"!=typeof e||e<0||e!=e)throw new TypeError('"defaultMaxListeners" must be a positive number');l=e}}):a.defaultMaxListeners=l,a.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||isNaN(e))throw new TypeError('"n" argument must be a positive number');return this._maxListeners=e,this},a.prototype.getMaxListeners=function(){return u(this)},a.prototype.emit=function(e){var t,n,r,i,o,a,s="error"===e;if(a=this._events)s=s&&null==a.error;else if(!s)return!1;if(s){if(arguments.length>1&&(t=arguments[1]),t instanceof Error)throw t;var l=new Error('Unhandled "error" event. ('+t+")");throw l.context=t,l}if(!(n=a[e]))return!1;var c="function"==typeof n;switch(r=arguments.length){case 1:p(n,c,this);break;case 2:f(n,c,this,arguments[1]);break;case 3:d(n,c,this,arguments[1],arguments[2]);break;case 4:h(n,c,this,arguments[1],arguments[2],arguments[3]);break;default:for(i=new Array(r-1),o=1;o<r;o++)i[o-1]=arguments[o];m(n,c,this,i)}return!0},a.prototype.addListener=function(e,t){return y(this,e,t,!1)},a.prototype.on=a.prototype.addListener,a.prototype.prependListener=function(e,t){return y(this,e,t,!0)},a.prototype.once=function(e,t){if("function"!=typeof t)throw new TypeError('"listener" argument must be a function');return this.on(e,v(this,e,t)),this},a.prototype.prependOnceListener=function(e,t){if("function"!=typeof t)throw new TypeError('"listener" argument must be a function');return this.prependListener(e,v(this,e,t)),this},a.prototype.removeListener=function(e,t){var n,i,o,a,s;if("function"!=typeof t)throw new TypeError('"listener" argument must be a function');if(!(i=this._events))return this;if(!(n=i[e]))return this;if(n===t||n.listener===t)0==--this._eventsCount?this._events=r(null):(delete i[e],i.removeListener&&this.emit
vendor: 4,021 bytes, line 21
21("removeListener",e,n.listener||t));else if("function"!=typeof n){for(o=-1,a=n.length-1;a>=0;a--)if(n[a]===t||n[a].listener===t){s=n[a].listener,o=a;break}if(o<0)return this;0===o?n.shift():function(e,t){for(var n=t,r=n+1,i=e.length;r<i;n+=1,r+=1)e[n]=e[r];e.pop()}(n,o),1===n.length&&(i[e]=n[0]),i.removeListener&&this.emit("removeListener",e,s||t)}return this},a.prototype.removeAllListeners=function(e){var t,n,o;if(!(n=this._events))return this;if(!n.removeListener)return 0===arguments.length?(this._events=r(null),this._eventsCount=0):n[e]&&(0==--this._eventsCount?this._events=r(null):delete n[e]),this;if(0===arguments.length){var a,s=i(n);for(o=0;o<s.length;++o)"removeListener"!==(a=s[o])&&this.removeAllListeners(a);return this.removeAllListeners("removeListener"),this._events=r(null),this._eventsCount=0,this}if("function"==typeof(t=n[e]))this.removeListener(e,t);else if(t)for(o=t.length-1;o>=0;o--)this.removeListener(e,t[o]);return this},a.prototype.listeners=function(e){return g(this,e,!0)},a.prototype.rawListeners=function(e){return g(this,e,!1)},a.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):w.call(e,t)},a.prototype.listenerCount=w,a.prototype.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]}},{}],223:[function(e,t,n){"use strict";var r="Function.prototype.bind called on incompatible ",i=Array.prototype.slice,o=Object.prototype.toString;t.exports=function(e){var t=this;if("function"!=typeof t||"[object Function]"!==o.call(t))throw new TypeError(r+t);for(var n,a=i.call(arguments,1),s=function(){if(this instanceof n){var r=t.apply(this,a.concat(i.call(arguments)));return Object(r)===r?r:this}return t.apply(e,a.concat(i.call(arguments)))},l=Math.max(0,t.length-a.length),c=[],u=0;u<l;u++)c.push("$"+u);if(n=Function("binder","return function ("+c.join(",")+"){ return binder.apply(this,arguments); }")(s),t.prototype){var p=function(){};p.prototype=t.prototype,n.prototype=new p,p.prototype=null}return n}},{}],224:[function(e,t,n){"use strict";var r=e("./implementation");t.exports=Function.prototype.bind||r},{"./implementation":223}],225:[function(e,t,n){"use strict";var r=SyntaxError,i=Function,o=TypeError,a=function(e){try{return Function('"use strict"; return ('+e+").constructor;")()}catch(e){}},s=Object.getOwnPropertyDescriptor;if(s)try{s({},"")}catch(e){s=null}var l=function(){throw new o},c=s?function(){try{return l}catch(e){try{return s(arguments,"callee").get}catch(e){return l}}}():l,u=e("has-symbols")(),p=Object.getPrototypeOf||function(e){return e.__proto__},f=a("async function* () {}"),d=f?f.prototype:void 0,h=d?d.prototype:void 0,m="undefined"==typeof Uint8Array?void 0:p(Uint8Array),y={"%AggregateError%":"undefined"==typeof AggregateError?void 0:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?void 0:ArrayBuffer,"%ArrayIteratorPrototype%":u?p([][Symbol.iterator]()):void 0,"%AsyncFromSyncIteratorPrototype%":void 0,"%AsyncFunction%":a("async function () {}"),"%AsyncGenerator%":d,"%AsyncGeneratorFunction%":f,"%AsyncIteratorPrototype%":h?p(h):void 0,"%Atomics%":"undefined"==typeof Atomics?void 0:Atomics,"%BigInt%":"undefined"==typeof BigInt?void 0:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?void 0:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?void 0:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?void 0:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?void 0:FinalizationRegistry,"%Function%":i,"%GeneratorFunction%":a("function* () {}"),"%Int8Array%":"undefined"==typeof Int8Array?void 0:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?void 0:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?void 0:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%
21IteratorPrototype%":u?p(p([][Symbol.iterator]())):void 0,"%JSON%":"object"==typeof JSON?JSON:void 0,"%Map%":"undefined"==typeof Map?void 0:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&u?p((new Map)[Symbol.iterator]()):void 0,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?void 0:Promise,"%Proxy%":"undefined"==typeof Proxy?void 0:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?void 0:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?void 0:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&u?p((new Set)[Symbol.iterator]()):void 0,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?void 0:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":u?p(""[Symbol.iterator]()):void 0,"%Symbol%":u?Symbol:void 0,"%SyntaxError%":r,"%ThrowTypeError%":c,"%TypedArray%":m,"%TypeError%":o,"%Uint8Array%":"undefined"==typeof Uint8Array?void 0:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?void 0:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?void 0:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?void 0:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?void 0:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?void 0:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?void 0:WeakSet},b={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},v=e("function-bind"),g=e("has"),w=v.call(Function.call,Array.prototype.concat),C=v.call(Function.apply,Array.prototype.splice),_=v.call(Function.call,String.prototype.replace),k=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,S=/\\(\\)?/g,E=function(e){var t=[];return _(e,k,(function(e,n,r,i){t[t.length]=r?_(i,S,"$1"):n||e})),t},T=function(e,t){var n,i=e;
vendor: 4,589 bytes, lines 21-23
21if(g(b,i)&&(i="%"+(n=b[i])[0]+"%"),g(y,i)){var a=y[i];if(void 0===a&&!t)throw new o("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:n,name:i,value:a}}throw new r("intrinsic "+e+" does not exist!")};t.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new o("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new o('"allowMissing" argument must be a boolean');var n=E(e),r=n.length>0?n[0]:"",i=T("%"+r+"%",t),a=i.name,l=i.value,c=!1,u=i.alias;u&&(r=u[0],C(n,w([0,1],u)));for(var p=1,f=!0;p<n.length;p+=1){var d=n[p];if("constructor"!==d&&f||(c=!0),g(y,a="%"+(r+="."+d)+"%"))l=y[a];else if(null!=l){if(s&&p+1>=n.length){var h=s(l,d);if(f=!!h,!t&&!(d in l))throw new o("base intrinsic for "+e+" exists, but the property is not available.");l=f&&"get"in h&&!("originalValue"in h.get)?h.get:l[d]}else f=g(l,d),l=l[d];f&&!c&&(y[a]=l)}}return l}},{"function-bind":224,has:228,"has-symbols":226}],226:[function(e,t,n){(function(n){(function(){"use strict";var r=n.Symbol,i=e("./shams");t.exports=function(){return"function"==typeof r&&("function"==typeof Symbol&&("symbol"==typeof r("foo")&&("symbol"==typeof Symbol("bar")&&i())))}}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./shams":227}],227:[function(e,t,n){"use strict";t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),n=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(n))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var r=Object.getOwnPropertySymbols(e);if(1!==r.length||r[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(e,t);if(42!==i.value||!0!==i.enumerable)return!1}return!0}},{}],228:[function(e,t,n){"use strict";var r=e("function-bind");t.exports=r.call(Function.call,Object.prototype.hasOwnProperty)},{"function-bind":224}],229:[function(e,t,n){"use strict";var r=e("react-is"),i={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},o={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function l(e){return r.isMemo(e)?a:s[e.$$typeof]||i}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},s[r.Memo]=a;var c=Object.defineProperty,u=Object.getOwnPropertyNames,p=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,d=Object.getPrototypeOf,h=Object.prototype;t.exports=function e(t,n,r){if("string"!=typeof n){if(h){var i=d(n);i&&i!==h&&e(t,i,r)}var a=u(n);p&&(a=a.concat(p(n)));for(var s=l(t),m=l(n),y=0;y<a.length;++y){var b=a[y];if(!(o[b]||r&&r[b]||m&&m[b]||s&&s[b])){var v=f(n,b);try{c(t,b,v)}catch(e){}}}}return t}},{"react-is":280}],230:[function(e,t,n){
22/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
23n.read=function(e,t,n,r,i){var o,a,s=8*i-r-1,l=(1<<s)-1,c=l>>1,u=-7,p=n?i-1:0,f=n?-1:1,d=e[t+p];for(p+=f,o=d&(1<<-u)-1,d>>=-u,u+=s;u>0;o=256*o+e[t+p],p+=f,u-=8);for(a=o&(1<<-u)-1,o>>=-u,u+=r;u>0;a=256*a+e[t+p],p+=f,u-=8);if(0===o)o=1-c;else{if(o===l)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,r),o-=c}return(d?-1:1)*a*Math.pow(2,o-r)},n.write=function(e,t,n,r,i,o){var a,s,l,c=8*o-i-1,u=(1<<c)-1,p=u>>1,f=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=r?0:o-1,h=r?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=u):(a=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-a))<1&&(a--,l*=2),(t+=a+p>=1?f/l:f*Math.pow(2,1-p))*l>=2&&(a++,l/=2),a+p>=u?(s=0,a=u):a+p>=1?(s=(t*l-1)*Math.pow(2,i),a+=p):(s=t*Math.pow(2,p-1)*Math.pow(2,i),a=0));i>=8;e[n+d]=255&s,d+=h,s/=256,i-=8);for(a=a<<i|s,c+=i;c>0;e[n+d]=255&a,d+=h,a/=256,c-=8);e[n+d-h]|=128*m}},{}],231:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=e("has"),o=e("side-channel")(),a=r("%TypeError%"),s={assert:function(e,t){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new a("`O` is not an object");
23if("string"!=typeof t)throw new a("`slot` must be a string");o.assert(e)},get:function(e,t){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new a("`O` is not an object");if("string"!=typeof t)throw new a("`slot` must be a string");var n=o.get(e);return n&&n["$"+t]},has:function(e,t){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new a("`O` is not an object");if("string"!=typeof t)throw new a("`slot` must be a string");var n=o.get(e);return!!n&&i(n,"$"+t)},set:function(e,t,n){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new a("`O` is not an object");if("string"!=typeof t)throw new a("`slot` must be a string");var r=o.get(e);r||(r={},o.set(e,r)),r["$"+t]=n}};Object.freeze&&Object.freeze(s),t.exports=s},{"get-intrinsic":232,has:228,"side-channel":325}],232:[function(e,t,n){arguments[4][216][0].apply(n,arguments)},{dup:216,"function-bind":224,has:228,"has-symbols":226}],233:[function(e,t,n){"use strict";var r,i,o=Function.prototype.toString,a="object"==typeof Reflect&&null!==Reflect&&Reflect.apply;if("function"==typeof a&&"function"==typeof Object.defineProperty)try{r=Object.defineProperty({},"length",{get:function(){throw i}}),i={},a((function(){throw 42}),null,r)}catch(e){e!==i&&(a=null)}else a=null;var s=/^\s*class\b/,l=function(e){try{var t=o.call(e);return s.test(t)}catch(e){return!1}},c=Object.prototype.toString,u="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,p="object"==typeof document&&void 0===document.all&&void 0!==document.all?document.all:{};t.exports=a?function(e){if(e===p)return!0;if(!e)return!1;if("function"!=typeof e&&"object"!=typeof e)return!1;if("function"==typeof e&&!e.prototype)return!0;try{a(e,null,r)}catch(e){if(e!==i)return!1}return!l(e)}:function(e){if(e===p)return!0;if(!e)return!1;if("function"!=typeof e&&"object"!=typeof e)return!1;if("function"==typeof e&&!e.prototype)return!0;if(u)return function(e){try{return!l(e)&&(o.call(e),!0)}catch(e){return!1}}(e);if(l(e))return!1;var t=c.call(e);return"[object Function]"===t||"[object GeneratorFunction]"===t}},{}],234:[function(e,t,n){"use strict";var r=Date.prototype.getDay,i=Object.prototype.toString,o="function"==typeof Symbol&&!!Symbol.toStringTag;t.exports=function(e){return"object"==typeof e&&null!==e&&(o?function(e){try{return r.call(e),!0}catch(e){return!1}}(e):"[object Date]"===i.call(e))}},{}],235:[function(e,t,n){"use strict";var r,i,o,a,s=e("call-bind/callBound"),l=e("has-symbols/shams")()&&!!Symbol.toStringTag;if(l){r=s("Object.prototype.hasOwnProperty"),i=s("RegExp.prototype.exec"),o={};var c=function(){throw o};a={toString:c,valueOf:c},"symbol"==typeof Symbol.toPrimitive&&(a[Symbol.toPrimitive]=c)}var u=s("Object.prototype.toString"),p=Object.getOwnPropertyDescriptor;t.exports=l?function(e){if(!e||"object"!=typeof e)return!1;var t=p(e,"lastIndex");if(!(t&&r(t,"value")))return!1;try{i(e,a)}catch(e){return e===o}}:function(e){return!(!e||"object"!=typeof e&&"function"!=typeof e)&&"[object RegExp]"===u(e)}},{"call-bind/callBound":236,"has-symbols/shams":240}],236:[function(e,t,n){arguments[4][154][0].apply(n,arguments)},{"./":237,dup:154,"get-intrinsic":238}],237:[function(e,t,n){arguments[4][215][0].apply(n,arguments)},{dup:215,"function-bind":224,"get-intrinsic":238}],238:[function(e,t,n){arguments[4][216][0].apply(n,arguments)},{dup:216,"function-bind":224,has:228,"has-symbols":239}],239:[function(e,t,n){arguments[4][217][0].apply(n,arguments)},{"./shams":240,dup:217}],240:[function(e,t,n){arguments[4][218][0].apply(n,arguments)},{dup:218}],241:[function(e,t,n){"use strict";var r=Object.prototype.toString;if(e("has-symbols")()){var i=Symbol.prototype.toString,o=/^Symbol\(.*\)$/;t.exports=function(e){if("symbol"==typeof e)return!0;if("[object Symbol]"!==r.call(e))return!1;try{return function(e){return"symbol"==typeof e.valueOf()&&o.test(i.call(e))}(e)}catch(e){return!1}}}else t.exports=function(e){return!1}},{"has-symbols":242}],242:[function(e,t,n){arguments[4][217][0].apply(n,arguments)},{"./shams":243,dup:217}],243:[function(e,t,n){arguments[4][218][0].apply(n,arguments)},{dup:218}],244:[function(e,t,n){
24/*!
25 * jQuery JavaScript Library v3.5.1
26 * https://jquery.com/
27 *
28 * Includes Sizzle.js
29 * https://sizzlejs.com/
30 *
31 * Copyright JS Foundation and other contributors
32 * Released under the MIT license
33 * https://jquery.org/license
34 *
35 * Date: 2020-05-04T22:49Z
36 */
37!function(e,n){"use strict";"object"==typeof t&&"object"==typeof t.exports?t.exports=e.document?n(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return n(e)}:n(e)}("undefined"!=typeof window?window:this,(function(e,t){"use strict";var n=[],r=Object.getPrototypeOf,i=n.slice,o=n.flat?function(e){return n.flat.call(e)}:function(e){return n.concat.apply([],e)},a=n.push,s=n.indexOf,l={},c=l.toString,u=l.hasOwnProperty,p=u.toString,f=p.call(Object),d={},h=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},m=function(e){return null!=e&&e===e.window}
vendor: 5,708 bytes, lines 37-48
37,y=e.document,b={type:!0,src:!0,nonce:!0,noModule:!0};function v(e,t,n){var r,i,o=(n=n||y).createElement("script");if(o.text=e,t)for(r in b)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function g(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?l[c.call(e)]||"object":typeof e}var w=function(e,t){return new w.fn.init(e,t)};function C(e){var t=!!e&&"length"in e&&e.length,n=g(e);return!h(e)&&!m(e)&&("array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e)}w.fn=w.prototype={jquery:"3.5.1",constructor:w,length:0,toArray:function(){return i.call(this)},get:function(e){return null==e?i.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=w.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return w.each(this,e)},map:function(e){return this.pushStack(w.map(this,(function(t,n){return e.call(t,n,t)})))},slice:function(){return this.pushStack(i.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(w.grep(this,(function(e,t){return(t+1)%2})))},odd:function(){return this.pushStack(w.grep(this,(function(e,t){return t%2})))},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(n>=0&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:a,sort:n.sort,splice:n.splice},w.extend=w.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,l=arguments.length,c=!1;for("boolean"==typeof a&&(c=a,a=arguments[s]||{},s++),"object"==typeof a||h(a)||(a={}),s===l&&(a=this,s--);s<l;s++)if(null!=(e=arguments[s]))for(t in e)r=e[t],"__proto__"!==t&&a!==r&&(c&&r&&(w.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[t],o=i&&!Array.isArray(n)?[]:i||w.isPlainObject(n)?n:{},i=!1,a[t]=w.extend(c,o,r)):void 0!==r&&(a[t]=r));return a},w.extend({expando:"jQuery"+("3.5.1"+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isPlainObject:function(e){var t,n;return!(!e||"[object Object]"!==c.call(e))&&(!(t=r(e))||"function"==typeof(n=u.call(t,"constructor")&&t.constructor)&&p.call(n)===f)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e,t,n){v(e,{nonce:t&&t.nonce},n)},each:function(e,t){var n,r=0;if(C(e))for(n=e.length;r<n&&!1!==t.call(e[r],r,e[r]);r++);else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},makeArray:function(e,t){var n=t||[];return null!=e&&(C(Object(e))?w.merge(n,"string"==typeof e?[e]:e):a.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:s.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;r<n;r++)e[i++]=t[r];return e.length=i,e},grep:function(e,t,n){for(var r=[],i=0,o=e.length,a=!n;i<o;i++)!t(e[i],i)!==a&&r.push(e[i]);return r},map:function(e,t,n){var r,i,a=0,s=[];if(C(e))for(r=e.length;a<r;a++)null!=(i=t(e[a],a,n))&&s.push(i);else for(a in e)null!=(i=t(e[a],a,n))&&s.push(i);return o(s)},guid:1,support:d}),"function"==typeof Symbol&&(w.fn[Symbol.iterator]=n[Symbol.iterator]),w.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),(function(e,t){l["[object "+t+"]"]=t.toLowerCase()}));var _=
38/*!
39 * Sizzle CSS Selector Engine v2.3.5
40 * https://sizzlejs.com/
41 *
42 * Copyright JS Foundation and other contributors
43 * Released under the MIT license
44 * https://js.foundation/
45 *
46 * Date: 2020-03-14
47 */
48function(e){var t,n,r,i,o,a,s,l,c,u,p,f,d,h,m,y,b,v,g,w="sizzle"+1*new Date,C=e.document,_=0,k=0,S=le(),E=le(),T=le(),O=le(),P=function(e,t){return e===t&&(p=!0),0},R={}.hasOwnProperty,x=[],D=x.pop,j=x.push,M=x.push,A=x.slice,I=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},N="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",L="[\\x20\\t\\r\\n\\f]",F="(?:\\\\[\\da-fA-F]{1,6}"+L+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",U="\\["+L+"*("+F+")(?:"+L+"*([*^$|!~]?=)"+L+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+F+"))|)"+L+"*\\]",q=":("+F+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+U+")*)|.*)\\)|)",B=new RegExp(L+"+","g"),z=new RegExp("^"+L+"+|((?:^|[^\\\\])(?:\\\\.)*)"+L+"+$","g"),V=new RegExp("^"+L+"*,"+L+"*"),W=new RegExp("^"+L+"*([>+~]|"+L+")"+L+"*"),H=new RegExp(L+"|>"),Y=new RegExp(q),X=new RegExp("^"+F+"$"),G={ID:new RegExp("^#("+F+")"),CLASS:new RegExp("^\\.("+F+")"),TAG:new RegExp("^("+F+"|[*])"),ATTR:new RegExp("^"+U),PSEUDO:new RegExp("^"+q),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+N+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},$=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,K=/^h\d$/i,J=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+L+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"�":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){f()},ae=we((function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()}),{dir:"parentNode",next:"legend"});try{M.apply(x=A.call(C.childNodes),C.childNodes),x[C.childNodes.length].nodeType}catch(e){M={apply:x.length?function(e,t){j.apply(e,A.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}
vendor: 7,630 bytes, line 48
48function se(e,t,r,i){var o,s,c,u,p,h,b,v=t&&t.ownerDocument,C=t?t.nodeType:9;if(r=r||[],"string"!=typeof e||!e||1!==C&&9!==C&&11!==C)return r;if(!i&&(f(t),t=t||d,m)){if(11!==C&&(p=Z.exec(e)))if(o=p[1]){if(9===C){if(!(c=t.getElementById(o)))return r;if(c.id===o)return r.push(c),r}else if(v&&(c=v.getElementById(o))&&g(t,c)&&c.id===o)return r.push(c),r}else{if(p[2])return M.apply(r,t.getElementsByTagName(e)),r;if((o=p[3])&&n.getElementsByClassName&&t.getElementsByClassName)return M.apply(r,t.getElementsByClassName(o)),r}if(n.qsa&&!O[e+" "]&&(!y||!y.test(e))&&(1!==C||"object"!==t.nodeName.toLowerCase())){if(b=e,v=t,1===C&&(H.test(e)||W.test(e))){for((v=ee.test(e)&&be(t.parentNode)||t)===t&&n.scope||((u=t.getAttribute("id"))?u=u.replace(re,ie):t.setAttribute("id",u=w)),s=(h=a(e)).length;s--;)h[s]=(u?"#"+u:":scope")+" "+ge(h[s]);b=h.join(",")}try{return M.apply(r,v.querySelectorAll(b)),r}catch(t){O(e,!0)}finally{u===w&&t.removeAttribute("id")}}}return l(e.replace(z,"$1"),t,r,i)}function le(){var e=[];return function t(n,i){return e.push(n+" ")>r.cacheLength&&delete t[e.shift()],t[n+" "]=i}}function ce(e){return e[w]=!0,e}function ue(e){var t=d.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function pe(e,t){for(var n=e.split("|"),i=n.length;i--;)r.attrHandle[n[i]]=t}function fe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function de(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function he(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function me(e){return function(t){return"form"in t?t.parentNode&&!1===t.disabled?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&ae(t)===e:t.disabled===e:"label"in t&&t.disabled===e}}function ye(e){return ce((function(t){return t=+t,ce((function(n,r){for(var i,o=e([],n.length,t),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))}))}))}function be(e){return e&&void 0!==e.getElementsByTagName&&e}for(t in n=se.support={},o=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!$.test(t||n&&n.nodeName||"HTML")},f=se.setDocument=function(e){var t,i,a=e?e.ownerDocument||e:C;return a!=d&&9===a.nodeType&&a.documentElement?(h=(d=a).documentElement,m=!o(d),C!=d&&(i=d.defaultView)&&i.top!==i&&(i.addEventListener?i.addEventListener("unload",oe,!1):i.attachEvent&&i.attachEvent("onunload",oe)),n.scope=ue((function(e){return h.appendChild(e).appendChild(d.createElement("div")),void 0!==e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length})),n.attributes=ue((function(e){return e.className="i",!e.getAttribute("className")})),n.getElementsByTagName=ue((function(e){return e.appendChild(d.createComment("")),!e.getElementsByTagName("*").length})),n.getElementsByClassName=J.test(d.getElementsByClassName),n.getById=ue((function(e){return h.appendChild(e).id=w,!d.getElementsByName||!d.getElementsByName(w).length})),n.getById?(r.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},r.find.ID=function(e,t){if(void 0!==t.getElementById&&m){var n=t.getElementById(e);return n?[n]:[]}}):(r.filter.ID=function(e){var t=e.replace(te,ne);return function(e){var n=void 0!==e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}},r.find.ID=function(e,t){if(void 0!==t.getElementById&&m){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];for(i=t.getElementsByName(e),r=0;o=i[r++];)if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),r.find.TAG=n.getElementsByTagName?function(e,t){return void 0!==t.getElementsByTagName?t.getElementsByTagName(e):n.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},r.find.CLASS=n.getElementsByClassName&&function(e,t){if(void 0!==t.getElementsByClassName&&m)return t.getElementsByClassName(e)},b=[],y=[],(n.qsa=J.test(d.querySelectorAll))&&(ue((function(e){var t;h.appendChild(e).innerHTML="<a id='"+w+"'></a><select id='"+w+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&y.push("[*^$]="+L+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||y.push("\\["+L+"*(?:value|"+N+")"),e.querySelectorAll("[id~="+w+"-]").length||y.push("~="),(t=d.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||y.push("\\["+L+"*name"+L+"*="+L+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||y.push(":checked"),e.querySelectorAll("a#"+w+"+*").length||y.push(".#.+[+~]"),e.querySelectorAll("\\\f"),y.push("[\\r\\n\\f]")})),ue((function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=d.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&y.push("name"+L+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&y.push(":enabled",":disabled"),h.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&y.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),y.push(",.*:")}))),(n.matchesSelector=J.test(v=h.matches||h.webkitMatchesSelector||h.mozMatchesSelector||h.oMatchesSelector||h.msMatchesSelector))&&ue((function(e){n.disconnectedMatch=v.call(e,"*"),v.call(e,"[s!='']:x"),b.push("!=",q)})),y=y.length&&new RegExp(y.join("|")),b=b.length&&new RegExp(b.join("|")),t=J.test(h.compareDocumentPosition),g=t||J.test(h.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},P=t?function(e,t){if(e===t)return p=!0,0;var r=!e.compareDocumentPosition-!t.compareDocumentPosition;return r||(1&(r=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!n.sortDetached&&t.compareDocumentPosition(e)===r?e==d||e.ownerDocument==C&&g(C,e)?-1:t==d||t.ownerDocument==C&&g(C,t)?1:u?I(u,e)-I(u,t):0:4&r?-1:1)}:function(e,t){if(e===t)return p=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==d?-1:t==d?1:i?-1:o?1:u?I(u,e)-I(u,t):0;if(i===o)return fe(e,t);for(n=e;n=n.parentNode;)a.unshift(n);for(n=t;n=n.parentNode;)s.unshift(n);for(;a[r]===s[r];)r++;return r?fe(a[r],s[r]):a[r]==C?-1:s[r]==C?1:0},d):d},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(f(e),n.matchesSelector&&m&&!O[t+" "]&&(!b||!b.test(t))&&(!y||!y.test(t)))try{var r=v.call(e,t);if(r||n.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(e){O(t,!0)}return se(t,d,null,[e]).length>0},se.contains=function(e,t){return(e.ownerDocument||e)!=d&&f(e),g(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!=d&&f(e);var i=r.attrHandle[t.toLowerCase()],o=i&&R.call(r.attrHandle,t.toLowerCase())?i(e,t,!m):void 0;return void 0!==o?o:n.attributes||!m?e.getAttribute(t):(o=e.getAttributeNode(t))&&o.specified?o.value:null},se.escape=function(e){return(e+"").replace(re,ie)},se.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},se.uniqueSort=function(e){var t,r=[],i=0,o=0;if(p=!n.detectDuplicates,u=!n.sortStable&&e.slice(0),e.sort(P),p){for(;t=e[o++];)t===e[o]&&(i=r.push(o));for(;i--;
vendor: 10,437 bytes, line 48
48)e.splice(r[i],1)}return u=null,e},i=se.getText=function(e){var t,n="",r=0,o=e.nodeType;if(o){if(1===o||9===o||11===o){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=i(e)}else if(3===o||4===o)return e.nodeValue}else for(;t=e[r++];)n+=i(t);return n},(r=se.selectors={cacheLength:50,createPseudo:ce,match:G,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&Y.test(n)&&(t=a(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=S[e+" "];return t||(t=new RegExp("(^|"+L+")"+e+"("+L+"|$)"))&&S(e,(function(e){return t.test("string"==typeof e.className&&e.className||void 0!==e.getAttribute&&e.getAttribute("class")||"")}))},ATTR:function(e,t,n){return function(r){var i=se.attr(r,e);return null==i?"!="===t:!t||(i+="","="===t?i===n:"!="===t?i!==n:"^="===t?n&&0===i.indexOf(n):"*="===t?n&&i.indexOf(n)>-1:"$="===t?n&&i.slice(-n.length)===n:"~="===t?(" "+i.replace(B," ")+" ").indexOf(n)>-1:"|="===t&&(i===n||i.slice(0,n.length+1)===n+"-"))}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,l){var c,u,p,f,d,h,m=o!==a?"nextSibling":"previousSibling",y=t.parentNode,b=s&&t.nodeName.toLowerCase(),v=!l&&!s,g=!1;if(y){if(o){for(;m;){for(f=t;f=f[m];)if(s?f.nodeName.toLowerCase()===b:1===f.nodeType)return!1;h=m="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?y.firstChild:y.lastChild],a&&v){for(g=(d=(c=(u=(p=(f=y)[w]||(f[w]={}))[f.uniqueID]||(p[f.uniqueID]={}))[e]||[])[0]===_&&c[1])&&c[2],f=d&&y.childNodes[d];f=++d&&f&&f[m]||(g=d=0)||h.pop();)if(1===f.nodeType&&++g&&f===t){u[e]=[_,d,g];break}}else if(v&&(g=d=(c=(u=(p=(f=t)[w]||(f[w]={}))[f.uniqueID]||(p[f.uniqueID]={}))[e]||[])[0]===_&&c[1]),!1===g)for(;(f=++d&&f&&f[m]||(g=d=0)||h.pop())&&((s?f.nodeName.toLowerCase()!==b:1!==f.nodeType)||!++g||(v&&((u=(p=f[w]||(f[w]={}))[f.uniqueID]||(p[f.uniqueID]={}))[e]=[_,g]),f!==t)););return(g-=i)===r||g%r==0&&g/r>=0}}},PSEUDO:function(e,t){var n,i=r.pseudos[e]||r.setFilters[e.toLowerCase()]||se.error("unsupported pseudo: "+e);return i[w]?i(t):i.length>1?(n=[e,e,"",t],r.setFilters.hasOwnProperty(e.toLowerCase())?ce((function(e,n){for(var r,o=i(e,t),a=o.length;a--;)e[r=I(e,o[a])]=!(n[r]=o[a])})):function(e){return i(e,0,n)}):i}},pseudos:{not:ce((function(e){var t=[],n=[],r=s(e.replace(z,"$1"));return r[w]?ce((function(e,t,n,i){for(var o,a=r(e,null,i,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))})):function(e,i,o){return t[0]=e,r(t,null,o,n),t[0]=null,!n.pop()}})),has:ce((function(e){return function(t){return se(e,t).length>0}})),contains:ce((function(e){return e=e.replace(te,ne),function(t){return(t.textContent||i(t)).indexOf(e)>-1}})),lang:ce((function(e){return X.test(e||"")||se.error("unsupported lang: "+e),e=e.replace(te,ne).toLowerCase(),function(t){var n;do{if(n=m?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(n=n.toLowerCase())===e||0===n.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}})),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===h},focus:function(e){return e===d.activeElement&&(!d.hasFocus||d.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:me(!1),disabled:me(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!r.pseudos.empty(e)},header:function(e){return K.test(e.nodeName)},input:function(e){return Q.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:ye((function(){return[0]})),last:ye((function(e,t){return[t-1]})),eq:ye((function(e,t,n){return[n<0?n+t:n]})),even:ye((function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e})),odd:ye((function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e})),lt:ye((function(e,t,n){for(var r=n<0?n+t:n>t?t:n;--r>=0;)e.push(r);return e})),gt:ye((function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e}))}}).pseudos.nth=r.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})r.pseudos[t]=de(t);for(t in{submit:!0,reset:!0})r.pseudos[t]=he(t);function ve(){}function ge(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function we(e,t,n){var r=t.dir,i=t.next,o=i||r,a=n&&"parentNode"===o,s=k++;return t.first?function(t,n,i){for(;t=t[r];)if(1===t.nodeType||a)return e(t,n,i);return!1}:function(t,n,l){var c,u,p,f=[_,s];if(l){for(;t=t[r];)if((1===t.nodeType||a)&&e(t,n,l))return!0}else for(;t=t[r];)if(1===t.nodeType||a)if(u=(p=t[w]||(t[w]={}))[t.uniqueID]||(p[t.uniqueID]={}),i&&i===t.nodeName.toLowerCase())t=t[r]||t;else{if((c=u[o])&&c[0]===_&&c[1]===s)return f[2]=c[2];if(u[o]=f,f[2]=e(t,n,l))return!0}return!1}}function Ce(e){return e.length>1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function _e(e,t,n,r,i){for(var o,a=[],s=0,l=e.length,c=null!=t;s<l;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),c&&t.push(s)));return a}function ke(e,t,n,r,i,o){return r&&!r[w]&&(r=ke(r)),i&&!i[w]&&(i=ke(i,o)),ce((function(o,a,s,l){var c,u,p,f=[],d=[],h=a.length,m=o||function(e,t,n){for(var r=0,i=t.length;r<i;r++)se(e,t[r],n);return n}(t||"*",s.nodeType?[s]:s,[]),y=!e||!o&&t?m:_e(m,f,e,s,l),b=n?i||(o?e:h||r)?[]:a:y;if(n&&n(y,b,s,l),r)for(c=_e(b,d),r(c,[],s,l),u=c.length;u--;)(p=c[u])&&(b[d[u]]=!(y[d[u]]=p));if(o){if(i||e){if(i){for(c=[],u=b.length;u--;)(p=b[u])&&c.push(y[u]=p);i(null,b=[],c,l)}for(u=b.length;u--;)(p=b[u])&&(c=i?I(o,p):f[u])>-1&&(o[c]=!(a[c]=p))}}else b=_e(b===a?b.splice(h,b.length):b),i?i(null,a,b,l):M.apply(a,b)}))}function Se(e){for(var t,n,i,o=e.length,a=r.relative[e[0].type],s=a||r.relative[" "],l=a?1:0,u=we((function(e){return e===t}),s,!0),p=we((function(e){return I(t,e)>-1}),s,!0),f=[function(e,n,r){var i=!a&&(r||n!==c)||((t=n).nodeType?u(e,n,r):p(e,n,r));return t=null,i}];l<o;l++)if(n=r.relative[e[l].type])f=[we(Ce(f),n)];else{if((n=r.filter[e[l].type].apply(null,e[l].matches))[w]){for(i=++l;i<o&&!r.relative[e[i].type];i++);return ke(l>1&&Ce(f),l>1&&ge(e.slice(0,l-1).concat({value:" "===e[l-2].type?"*":""})).replace(z,"$1"),n,l<i&&Se(e.slice(l,i)),i<o&&Se(e=e.slice(i)),i<o&&ge(e))}f.push(n)}return Ce(f)}return ve.prototype=r.filters=r.pseudos,r.setFilters=new ve,a=se.tokenize=function(e,t){var n,i,o,a,s,l,c,u=E[e+" "];if(u)return t?0:u.slice(0);for(s=e,l=[],c=r.preFilter;s;){for(a in n&&!(i=V.exec(s))||(i&&(s=s.slice(i[0].length)||s),l.push(o=[])),n=!1,(i=W.exec(s))&&(n=i.shift(),o.push({value:n,type:i[0].replace(z," ")}),s=s.slice(n.length)),r.filter)!(i=G[a].exec(s))||c[a]&&!(i=c[a](i))||(n=i.shift(),o.push({value:n,type:a,matches:i}),s=s.slice(n.length));if(!n)break}return t?s.length:s?se.error(e):E(e,l).slice(0)},s=se.compile=function(e,t){var n,i=[],o=[],s=T[e+" "];if(!s){for(t||(t=a(e)),n=t.length;n--;)(s=Se(t[n]))[w]?i.push(s):o.push(s);(s=T(e,function(e,t){var n=t.length>0,i=e.length>0,o=function(o,a,s,l,u){var p,h,y,b=0,v="0",g=o&&[],w=[],C=c,k=o||i&&r.find.TAG("*",u),S=_+=null==C?1:Math.random()||.1,E=k.length;for(u&&(c=a==d||a||u);v!==E&&null!=(p=k[v]);v++){if(i&&p){for(h=0,a||p.ownerDocument==d||(f(p),s=!m);y=e[h++];)if(y(p,a||d,s)){l.push(p);break}u&&(_=S)}n&&((p=!y&&p)&&b--,o&&g.push(p))}if(b+=v,n&&v!==b){for(h=0;y=t[h++];)y(g,w,a,s);if(o){if(b>0)for(;v--;)g[v]||w[v]||(w[v]=D.call(l));w=_e(w)}M.apply(l,w),u&&!o&&w.length>0&&b+t.length>1&&se.uniqueSort(l)}return u&&(_=S,c=C),g};return n?ce(o):o}(o,i))).selector=e}return s},l=se.select=function(e,t,n,i){var o,l,c,u,p,f="function"==typeof e&&e,d=!i&&a(e=f.selector||e);if(n=n||[],1===d.length){if((l=d[0]=d[0].slice(0)).length>2&&"ID"===(c=l[0]).type&&9===t.nodeType&&m&&r.relative[l[1].type]){if(!(t=(r.find.ID(c.matches[0].replace(te,ne),t)||[])[0]))return n;f&&(t=t.parentNode),e=e.slice(l.shift().value.length)}for(o=G.needsContext.test(e)?0:l.length;o--&&(c=l[o],!r.relative[u=c.type]);)if((p=r.find[u])&&(i=p(c.matches[0].replace(te,ne),ee.test(l[0].type)&&be(t.parentNode)||t))){if(l.splice(o,1),!(e=i.length&&ge(l)))return M.apply(n,i),n;break}}return(f||s(e,d))(i,t,!m,n,!t||ee.test(e)&&be(t.parentNode)||t),n},n.sortStable=w.split("").sort(P).join("")===w,n.detectDuplicates=!!p,f(),n.sortDetached=ue((function(e){return 1&e.compareDocumentPosition(d.createElement("fieldset"))})),ue((function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")}))||pe("type|href|height|width",(function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)})),n.attributes&&ue((function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")}))||pe("value",(function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue})),ue((function(e){return null==e.getAttribute("disabled")}))||pe(N,(function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null})),se}(e);w.find=_,w.expr=_.selectors,w.expr[":"]=w.expr.pseudos,w.uniqueSort=w.unique=_.uniqueSort,w.text=_.getText,w.isXMLDoc=_.isXML,w.contains=_.contains,w.escapeSelector=_.escape;var k=function(e,t,n){for(var r=[],i=void 0!==n;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(i&&w(e).is(n))break;r.push(e)}return r},S=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},E=w.expr.match.needsContext;
vendor: 4,749 bytes, line 48
48function T(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var O=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function P(e,t,n){return h(t)?w.grep(e,(function(e,r){return!!t.call(e,r,e)!==n})):t.nodeType?w.grep(e,(function(e){return e===t!==n})):"string"!=typeof t?w.grep(e,(function(e){return s.call(t,e)>-1!==n})):w.filter(t,e,n)}w.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?w.find.matchesSelector(r,e)?[r]:[]:w.find.matches(e,w.grep(t,(function(e){return 1===e.nodeType})))},w.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(w(e).filter((function(){for(t=0;t<r;t++)if(w.contains(i[t],this))return!0})));for(n=this.pushStack([]),t=0;t<r;t++)w.find(e,i[t],n);return r>1?w.uniqueSort(n):n},filter:function(e){return this.pushStack(P(this,e||[],!1))},not:function(e){return this.pushStack(P(this,e||[],!0))},is:function(e){return!!P(this,"string"==typeof e&&E.test(e)?w(e):e||[],!1).length}});var R,x=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(w.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||R,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:x.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof w?t[0]:t,w.merge(this,w.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:y,!0)),O.test(r[1])&&w.isPlainObject(t))for(r in t)h(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=y.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):h(e)?void 0!==n.ready?n.ready(e):e(w):w.makeArray(e,this)}).prototype=w.fn,R=w(y);var D=/^(?:parents|prev(?:Until|All))/,j={children:!0,contents:!0,next:!0,prev:!0};function M(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}w.fn.extend({has:function(e){var t=w(e,this),n=t.length;return this.filter((function(){for(var e=0;e<n;e++)if(w.contains(this,t[e]))return!0}))},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&w(e);if(!E.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&w.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?w.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?s.call(w(e),this[0]):s.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(w.uniqueSort(w.merge(this.get(),w(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),w.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return k(e,"parentNode")},parentsUntil:function(e,t,n){return k(e,"parentNode",n)},next:function(e){return M(e,"nextSibling")},prev:function(e){return M(e,"previousSibling")},nextAll:function(e){return k(e,"nextSibling")},prevAll:function(e){return k(e,"previousSibling")},nextUntil:function(e,t,n){return k(e,"nextSibling",n)},prevUntil:function(e,t,n){return k(e,"previousSibling",n)},siblings:function(e){return S((e.parentNode||{}).firstChild,e)},children:function(e){return S(e.firstChild)},contents:function(e){return null!=e.contentDocument&&r(e.contentDocument)?e.contentDocument:(T(e,"template")&&(e=e.content||e),w.merge([],e.childNodes))}},(function(e,t){w.fn[e]=function(n,r){var i=w.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=w.filter(r,i)),this.length>1&&(j[e]||w.uniqueSort(i),D.test(e)&&i.reverse()),this.pushStack(i)}}));var A=/[^\x20\t\r\n\f]+/g;function I(e){return e}function N(e){throw e}function L(e,t,n,r){var i;try{e&&h(i=e.promise)?i.call(e).done(t).fail(n):e&&h(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}w.Callbacks=function(e){e="string"==typeof e?function(e){var t={};return w.each(e.match(A)||[],(function(e,n){t[n]=!0})),t}(e):w.extend({},e);var t,n,r,i,o=[],a=[],s=-1,l=function(){for(i=i||e.once,r=t=!0;a.length;s=-1)for(n=a.shift();++s<o.length;)!1===o[s].apply(n[0],n[1])&&e.stopOnFalse&&(s=o.length,n=!1);e.memory||(n=!1),t=!1,i&&(o=n?[]:"")},c={add:function(){return o&&(n&&!t&&(s=o.length-1,a.push(n)),function t(n){w.each(n,(function(n,r){h(r)?e.unique&&c.has(r)||o.push(r):r&&r.length&&"string"!==g(r)&&t(r)}))}(arguments),n&&!t&&l()),this},remove:function(){return w.each(arguments,(function(e,t){for(var n;(n=w.inArray(t,o,n))>-1;)o.splice(n,1),n<=s&&s--})),this},has:function(e){return e?w.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=a=[],o=n="",this},disabled:function(){return!o},lock:function(){return i=a=[],n||t||(o=n=""),this},locked:function(){return!!i}
vendor: 8,057 bytes, line 48
48,fireWith:function(e,n){return i||(n=[e,(n=n||[]).slice?n.slice():n],a.push(n),t||l()),this},fire:function(){return c.fireWith(this,arguments),this},fired:function(){return!!r}};return c},w.extend({Deferred:function(t){var n=[["notify","progress",w.Callbacks("memory"),w.Callbacks("memory"),2],["resolve","done",w.Callbacks("once memory"),w.Callbacks("once memory"),0,"resolved"],["reject","fail",w.Callbacks("once memory"),w.Callbacks("once memory"),1,"rejected"]],r="pending",i={state:function(){return r},always:function(){return o.done(arguments).fail(arguments),this},catch:function(e){return i.then(null,e)},pipe:function(){var e=arguments;return w.Deferred((function(t){w.each(n,(function(n,r){var i=h(e[r[4]])&&e[r[4]];o[r[1]]((function(){var e=i&&i.apply(this,arguments);e&&h(e.promise)?e.promise().progress(t.notify).done(t.resolve).fail(t.reject):t[r[0]+"With"](this,i?[e]:arguments)}))})),e=null})).promise()},then:function(t,r,i){var o=0;function a(t,n,r,i){return function(){var s=this,l=arguments,c=function(){var e,c;if(!(t<o)){if((e=r.apply(s,l))===n.promise())throw new TypeError("Thenable self-resolution");c=e&&("object"==typeof e||"function"==typeof e)&&e.then,h(c)?i?c.call(e,a(o,n,I,i),a(o,n,N,i)):(o++,c.call(e,a(o,n,I,i),a(o,n,N,i),a(o,n,I,n.notifyWith))):(r!==I&&(s=void 0,l=[e]),(i||n.resolveWith)(s,l))}},u=i?c:function(){try{c()}catch(e){w.Deferred.exceptionHook&&w.Deferred.exceptionHook(e,u.stackTrace),t+1>=o&&(r!==N&&(s=void 0,l=[e]),n.rejectWith(s,l))}};t?u():(w.Deferred.getStackHook&&(u.stackTrace=w.Deferred.getStackHook()),e.setTimeout(u))}}return w.Deferred((function(e){n[0][3].add(a(0,e,h(i)?i:I,e.notifyWith)),n[1][3].add(a(0,e,h(t)?t:I)),n[2][3].add(a(0,e,h(r)?r:N))})).promise()},promise:function(e){return null!=e?w.extend(e,i):i}},o={};return w.each(n,(function(e,t){var a=t[2],s=t[5];i[t[1]]=a.add,s&&a.add((function(){r=s}),n[3-e][2].disable,n[3-e][3].disable,n[0][2].lock,n[0][3].lock),a.add(t[3].fire),o[t[0]]=function(){return o[t[0]+"With"](this===o?void 0:this,arguments),this},o[t[0]+"With"]=a.fireWith})),i.promise(o),t&&t.call(o,o),o},when:function(e){var t=arguments.length,n=t,r=Array(n),o=i.call(arguments),a=w.Deferred(),s=function(e){return function(n){r[e]=this,o[e]=arguments.length>1?i.call(arguments):n,--t||a.resolveWith(r,o)}};if(t<=1&&(L(e,a.done(s(n)).resolve,a.reject,!t),"pending"===a.state()||h(o[n]&&o[n].then)))return a.then();for(;n--;)L(o[n],s(n),a.reject);return a.promise()}});var F=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;w.Deferred.exceptionHook=function(t,n){e.console&&e.console.warn&&t&&F.test(t.name)&&e.console.warn("jQuery.Deferred exception: "+t.message,t.stack,n)},w.readyException=function(t){e.setTimeout((function(){throw t}))};var U=w.Deferred();function q(){y.removeEventListener("DOMContentLoaded",q),e.removeEventListener("load",q),w.ready()}w.fn.ready=function(e){return U.then(e).catch((function(e){w.readyException(e)})),this},w.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--w.readyWait:w.isReady)||(w.isReady=!0,!0!==e&&--w.readyWait>0||U.resolveWith(y,[w]))}}),w.ready.then=U.then,"complete"===y.readyState||"loading"!==y.readyState&&!y.documentElement.doScroll?e.setTimeout(w.ready):(y.addEventListener("DOMContentLoaded",q),e.addEventListener("load",q));var B=function(e,t,n,r,i,o,a){var s=0,l=e.length,c=null==n;if("object"===g(n))for(s in i=!0,n)B(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,h(r)||(a=!0),c&&(a?(t.call(e,r),t=null):(c=t,t=function(e,t,n){return c.call(w(e),n)})),t))for(;s<l;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:c?t.call(e):l?t(e[0],n):o},z=/^-ms-/,V=/-([a-z])/g;function W(e,t){return t.toUpperCase()}function H(e){return e.replace(z,"ms-").replace(V,W)}var Y=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function X(){this.expando=w.expando+X.uid++}X.uid=1,X.prototype={cache:function(e){var t=e[this.expando];return t||(t={},Y(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,i=this.cache(e);if("string"==typeof t)i[H(t)]=n;else for(r in t)i[H(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][H(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){n=(t=Array.isArray(t)?t.map(H):(t=H(t))in r?[t]:t.match(A)||[]).length;for(;n--;)delete r[t[n]]}(void 0===t||w.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!w.isEmptyObject(t)}};var G=new X,$=new X,Q=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,K=/[A-Z]/g;function J(e,t,n){var r;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(K,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n=function(e){return"true"===e||"false"!==e&&("null"===e?null:e===+e+""?+e:Q.test(e)?JSON.parse(e):e)}(n)}catch(e){}$.set(e,t,n)}else n=void 0;return n}w.extend({hasData:function(e){return $.hasData(e)||G.hasData(e)},data:function(e,t,n){return $.access(e,t,n)},removeData:function(e,t){$.remove(e,t)},_data:function(e,t,n){return G.access(e,t,n)},_removeData:function(e,t){G.remove(e,t)}}),w.fn.extend({data:function(e,t){var n,r,i,o=this[0],a=o&&o.attributes;if(void 0===e){if(this.length&&(i=$.get(o),1===o.nodeType&&!G.get(o,"hasDataAttrs"))){for(n=a.length;n--;)a[n]&&0===(r=a[n].name).indexOf("data-")&&(r=H(r.slice(5)),J(o,r,i[r]));G.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof e?this.each((function(){$.set(this,e)})):B(this,(function(t){var n;if(o&&void 0===t)return void 0!==(n=$.get(o,e))||void 0!==(n=J(o,e))?n:void 0;this.each((function(){$.set(this,e,t)}))}),null,t,arguments.length>1,null,!0)},removeData:function(e){return this.each((function(){$.remove(this,e)}))}}),w.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=G.get(e,t),n&&(!r||Array.isArray(n)?r=G.access(e,t,w.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=w.queue(e,t),r=n.length,i=n.shift(),o=w._queueHooks(e,t);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,(function(){w.dequeue(e,t)}),o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return G.get(e,n)||G.access(e,n,{empty:w.Callbacks("once memory").add((function(){G.remove(e,[t+"queue",n])}))})}}),w.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?w.queue(this[0],e):void 0===t?this:this.each((function(){var n=w.queue(this,e,t);w._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&w.dequeue(this,e)}))},dequeue:function(e){return this.each((function(){w.dequeue(this,e)}))},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=w.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof e&&(t=e,e=void 0),e=e||"fx";a--;)(n=G.get(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var Z=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,ee=new RegExp("^(?:([+-])=|)("+Z+")([a-z%]*)$","i"),te=["Top","Right","Bottom","Left"],ne=y.documentElement,re=function(e){return w.contains(e.ownerDocument,e)},ie={composed:!0};ne.getRootNode&&(re=function(e){return w.contains(e.ownerDocument,e)||e.getRootNode(ie)===e.ownerDocument});var oe=function(e,t){return"none"===(e=t||e).style.display||""===e.style.display&&re(e)&&"none"===w.css(e,"display")};function ae(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return w.css(e,t,"")},l=s(),c=n&&n[3]||(w.cssNumber[t]?"":"px"),u=e.nodeType&&(w.cssNumber[t]||"px"!==c&&+l)&&ee.exec(w.css(e,t));if(u&&u[3]!==c){for(l/=2,c=c||u[3],u=+l||1;a--;)w.style(e,t,u+c),(1-o)*(1-(o=s()/l||.5))<=0&&(a=0),u/=o;u*=2,w.style(e,t,u+c),n=n||[]}return n&&(u=+u||+l||0,i=n[1]?u+(n[1]+1)*n[2]:+n[2],r&&(r.unit=c,r.start=u,r.end=i)),i}var se={};function le(e){var t,n=e.ownerDocument,r=e.nodeName,i=se[r];
vendor: 6,924 bytes, line 48
48return i||(t=n.body.appendChild(n.createElement(r)),i=w.css(t,"display"),t.parentNode.removeChild(t),"none"===i&&(i="block"),se[r]=i,i)}function ce(e,t){for(var n,r,i=[],o=0,a=e.length;o<a;o++)(r=e[o]).style&&(n=r.style.display,t?("none"===n&&(i[o]=G.get(r,"display")||null,i[o]||(r.style.display="")),""===r.style.display&&oe(r)&&(i[o]=le(r))):"none"!==n&&(i[o]="none",G.set(r,"display",n)));for(o=0;o<a;o++)null!=i[o]&&(e[o].style.display=i[o]);return e}w.fn.extend({show:function(){return ce(this,!0)},hide:function(){return ce(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each((function(){oe(this)?w(this).show():w(this).hide()}))}});var ue,pe,fe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ue=y.createDocumentFragment().appendChild(y.createElement("div")),(pe=y.createElement("input")).setAttribute("type","radio"),pe.setAttribute("checked","checked"),pe.setAttribute("name","t"),ue.appendChild(pe),d.checkClone=ue.cloneNode(!0).cloneNode(!0).lastChild.checked,ue.innerHTML="<textarea>x</textarea>",d.noCloneChecked=!!ue.cloneNode(!0).lastChild.defaultValue,ue.innerHTML="<option></option>",d.option=!!ue.lastChild;var me={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function ye(e,t){var n;return n=void 0!==e.getElementsByTagName?e.getElementsByTagName(t||"*"):void 0!==e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&T(e,t)?w.merge([e],n):n}function be(e,t){for(var n=0,r=e.length;n<r;n++)G.set(e[n],"globalEval",!t||G.get(t[n],"globalEval"))}me.tbody=me.tfoot=me.colgroup=me.caption=me.thead,me.th=me.td,d.option||(me.optgroup=me.option=[1,"<select multiple='multiple'>","</select>"]);var ve=/<|&#?\w+;/;function ge(e,t,n,r,i){for(var o,a,s,l,c,u,p=t.createDocumentFragment(),f=[],d=0,h=e.length;d<h;d++)if((o=e[d])||0===o)if("object"===g(o))w.merge(f,o.nodeType?[o]:o);else if(ve.test(o)){for(a=a||p.appendChild(t.createElement("div")),s=(de.exec(o)||["",""])[1].toLowerCase(),l=me[s]||me._default,a.innerHTML=l[1]+w.htmlPrefilter(o)+l[2],u=l[0];u--;)a=a.lastChild;w.merge(f,a.childNodes),(a=p.firstChild).textContent=""}else f.push(t.createTextNode(o));for(p.textContent="",d=0;o=f[d++];)if(r&&w.inArray(o,r)>-1)i&&i.push(o);else if(c=re(o),a=ye(p.appendChild(o),"script"),c&&be(a),n)for(u=0;o=a[u++];)he.test(o.type||"")&&n.push(o);return p}var we=/^key/,Ce=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,_e=/^([^.]*)(?:\.(.+)|)/;function ke(){return!0}function Se(){return!1}function Ee(e,t){return e===function(){try{return y.activeElement}catch(e){}}()==("focus"===t)}function Te(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)Te(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Se;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return w().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=w.guid++)),e.each((function(){w.event.add(this,t,i,r,n)}))}function Oe(e,t,n){n?(G.set(e,t,!1),w.event.add(e,t,{namespace:!1,handler:function(e){var r,o,a=G.get(this,t);if(1&e.isTrigger&&this[t]){if(a.length)(w.event.special[t]||{}).delegateType&&e.stopPropagation();else if(a=i.call(arguments),G.set(this,t,a),r=n(this,t),this[t](),a!==(o=G.get(this,t))||r?G.set(this,t,!1):o={},a!==o)return e.stopImmediatePropagation(),e.preventDefault(),o.value}else a.length&&(G.set(this,t,{value:w.event.trigger(w.extend(a[0],w.Event.prototype),a.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===G.get(e,t)&&w.event.add(e,t,ke)}w.event={global:{},add:function(e,t,n,r,i){var o,a,s,l,c,u,p,f,d,h,m,y=G.get(e);if(Y(e))for(n.handler&&(n=(o=n).handler,i=o.selector),i&&w.find.matchesSelector(ne,i),n.guid||(n.guid=w.guid++),(l=y.events)||(l=y.events=Object.create(null)),(a=y.handle)||(a=y.handle=function(t){return void 0!==w&&w.event.triggered!==t.type?w.event.dispatch.apply(e,arguments):void 0}),c=(t=(t||"").match(A)||[""]).length;c--;)d=m=(s=_e.exec(t[c])||[])[1],h=(s[2]||"").split(".").sort(),d&&(p=w.event.special[d]||{},d=(i?p.delegateType:p.bindType)||d,p=w.event.special[d]||{},u=w.extend({type:d,origType:m,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&w.expr.match.needsContext.test(i),namespace:h.join(".")},o),(f=l[d])||((f=l[d]=[]).delegateCount=0,p.setup&&!1!==p.setup.call(e,r,h,a)||e.addEventListener&&e.addEventListener(d,a)),p.add&&(p.add.call(e,u),u.handler.guid||(u.handler.guid=n.guid)),i?f.splice(f.delegateCount++,0,u):f.push(u),w.event.global[d]=!0)},remove:function(e,t,n,r,i){var o,a,s,l,c,u,p,f,d,h,m,y=G.hasData(e)&&G.get(e);if(y&&(l=y.events)){for(c=(t=(t||"").match(A)||[""]).length;c--;)if(d=m=(s=_e.exec(t[c])||[])[1],h=(s[2]||"").split(".").sort(),d){for(p=w.event.special[d]||{},f=l[d=(r?p.delegateType:p.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=f.length;o--;)u=f[o],!i&&m!==u.origType||n&&n.guid!==u.guid||s&&!s.test(u.namespace)||r&&r!==u.selector&&("**"!==r||!u.selector)||(f.splice(o,1),u.selector&&f.delegateCount--,p.remove&&p.remove.call(e,u));a&&!f.length&&(p.teardown&&!1!==p.teardown.call(e,h,y.handle)||w.removeEvent(e,d,y.handle),delete l[d])}else for(d in l)w.event.remove(e,d+t[c],n,r,!0);w.isEmptyObject(l)&&G.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=new Array(arguments.length),l=w.event.fix(e),c=(G.get(this,"events")||Object.create(null))[l.type]||[],u=w.event.special[l.type]||{};for(s[0]=l,t=1;t<arguments.length;t++)s[t]=arguments[t];if(l.delegateTarget=this,!u.preDispatch||!1!==u.preDispatch.call(this,l)){for(a=w.event.handlers.call(this,l,c),t=0;(i=a[t++])&&!l.isPropagationStopped();)for(l.currentTarget=i.elem,n=0;(o=i.handlers[n++])&&!l.isImmediatePropagationStopped();)l.rnamespace&&!1!==o.namespace&&!l.rnamespace.test(o.namespace)||(l.handleObj=o,l.data=o.data,void 0!==(r=((w.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,s))&&!1===(l.result=r)&&(l.preventDefault(),l.stopPropagation()));return u.postDispatch&&u.postDispatch.call(this,l),l.result}},handlers:function(e,t){var n,r,i,o,a,s=[],l=t.delegateCount,c=e.target;if(l&&c.nodeType&&!("click"===e.type&&e.button>=1))for(;c!==this;c=c.parentNode||this)if(1===c.nodeType&&("click"!==e.type||!0!==c.disabled)){for(o=[],a={},n=0;n<l;n++)void 0===a[i=(r=t[n]).selector+" "]&&(a[i]=r.needsContext?w(i,this).index(c)>-1:w.find(i,this,null,[c]).length),a[i]&&o.push(r);o.length&&s.push({elem:c,handlers:o})}return c=this,l<t.length&&s.push({elem:c,handlers:t.slice(l)}),s},addProp:function(e,t){Object.defineProperty(w.Event.prototype,e,{enumerable:!0,configurable:!0,get:h(t)?function(){if(this.originalEvent)return t(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[e]}
vendor: 2,431 bytes, line 48
48,set:function(t){Object.defineProperty(this,e,{enumerable:!0,configurable:!0,writable:!0,value:t})}})},fix:function(e){return e[w.expando]?e:new w.Event(e)},special:{load:{noBubble:!0},click:{setup:function(e){var t=this||e;return fe.test(t.type)&&t.click&&T(t,"input")&&Oe(t,"click",ke),!1},trigger:function(e){var t=this||e;return fe.test(t.type)&&t.click&&T(t,"input")&&Oe(t,"click"),!0},_default:function(e){var t=e.target;return fe.test(t.type)&&t.click&&T(t,"input")&&G.get(t,"click")||T(t,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},w.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},w.Event=function(e,t){if(!(this instanceof w.Event))return new w.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?ke:Se,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&w.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[w.expando]=!0},w.Event.prototype={constructor:w.Event,isDefaultPrevented:Se,isPropagationStopped:Se,isImmediatePropagationStopped:Se,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=ke,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=ke,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=ke,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},w.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,char:!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&we.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&Ce.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},w.event.addProp),w.each({focus:"focusin",blur:"focusout"},(function(e,t){w.event.special[e]={setup:function(){return Oe(this,e,Ee),!1},trigger:function(){return Oe(this,e),!0},delegateType:t}}
vendor: 5,920 bytes, line 48
48)),w.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},(function(e,t){w.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return i&&(i===r||w.contains(r,i))||(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}})),w.fn.extend({on:function(e,t,n,r){return Te(this,e,t,n,r)},one:function(e,t,n,r){return Te(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,w(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=Se),this.each((function(){w.event.remove(this,e,n,t)}))}});var Pe=/<script|<style|<link/i,Re=/checked\s*(?:[^=]|=\s*.checked.)/i,xe=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function De(e,t){return T(e,"table")&&T(11!==t.nodeType?t:t.firstChild,"tr")&&w(e).children("tbody")[0]||e}function je(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function Me(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Ae(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(G.hasData(e)&&(s=G.get(e).events))for(i in G.remove(t,"handle events"),s)for(n=0,r=s[i].length;n<r;n++)w.event.add(t,i,s[i][n]);$.hasData(e)&&(o=$.access(e),a=w.extend({},o),$.set(t,a))}}function Ie(e,t){var n=t.nodeName.toLowerCase();"input"===n&&fe.test(e.type)?t.checked=e.checked:"input"!==n&&"textarea"!==n||(t.defaultValue=e.defaultValue)}function Ne(e,t,n,r){t=o(t);var i,a,s,l,c,u,p=0,f=e.length,m=f-1,y=t[0],b=h(y);if(b||f>1&&"string"==typeof y&&!d.checkClone&&Re.test(y))return e.each((function(i){var o=e.eq(i);b&&(t[0]=y.call(this,i,o.html())),Ne(o,t,n,r)}));if(f&&(a=(i=ge(t,e[0].ownerDocument,!1,e,r)).firstChild,1===i.childNodes.length&&(i=a),a||r)){for(l=(s=w.map(ye(i,"script"),je)).length;p<f;p++)c=i,p!==m&&(c=w.clone(c,!0,!0),l&&w.merge(s,ye(c,"script"))),n.call(e[p],c,p);if(l)for(u=s[s.length-1].ownerDocument,w.map(s,Me),p=0;p<l;p++)c=s[p],he.test(c.type||"")&&!G.access(c,"globalEval")&&w.contains(u,c)&&(c.src&&"module"!==(c.type||"").toLowerCase()?w._evalUrl&&!c.noModule&&w._evalUrl(c.src,{nonce:c.nonce||c.getAttribute("nonce")},u):v(c.textContent.replace(xe,""),c,u))}return e}function Le(e,t,n){for(var r,i=t?w.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||w.cleanData(ye(r)),r.parentNode&&(n&&re(r)&&be(ye(r,"script")),r.parentNode.removeChild(r));return e}w.extend({htmlPrefilter:function(e){return e},clone:function(e,t,n){var r,i,o,a,s=e.cloneNode(!0),l=re(e);if(!(d.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||w.isXMLDoc(e)))for(a=ye(s),r=0,i=(o=ye(e)).length;r<i;r++)Ie(o[r],a[r]);if(t)if(n)for(o=o||ye(e),a=a||ye(s),r=0,i=o.length;r<i;r++)Ae(o[r],a[r]);else Ae(e,s);return(a=ye(s,"script")).length>0&&be(a,!l&&ye(e,"script")),s},cleanData:function(e){for(var t,n,r,i=w.event.special,o=0;void 0!==(n=e[o]);o++)if(Y(n)){if(t=n[G.expando]){if(t.events)for(r in t.events)i[r]?w.event.remove(n,r):w.removeEvent(n,r,t.handle);n[G.expando]=void 0}n[$.expando]&&(n[$.expando]=void 0)}}}),w.fn.extend({detach:function(e){return Le(this,e,!0)},remove:function(e){return Le(this,e)},text:function(e){return B(this,(function(e){return void 0===e?w.text(this):this.empty().each((function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)}))}),null,e,arguments.length)},append:function(){return Ne(this,arguments,(function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||De(this,e).appendChild(e)}))},prepend:function(){return Ne(this,arguments,(function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=De(this,e);t.insertBefore(e,t.firstChild)}}))},before:function(){return Ne(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this)}))},after:function(){return Ne(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)}))},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(w.cleanData(ye(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map((function(){return w.clone(this,e,t)}))},html:function(e){return B(this,(function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Pe.test(e)&&!me[(de.exec(e)||["",""])[1].toLowerCase()]){e=w.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(w.cleanData(ye(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)}),null,e,arguments.length)},replaceWith:function(){var e=[];return Ne(this,arguments,(function(t){var n=this.parentNode;w.inArray(this,e)<0&&(w.cleanData(ye(this)),n&&n.replaceChild(t,this))}),e)}}),w.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},(function(e,t){w.fn[e]=function(e){for(var n,r=[],i=w(e),o=i.length-1,s=0;s<=o;s++)n=s===o?this:this.clone(!0),w(i[s])[t](n),a.apply(r,n.get());return this.pushStack(r)}}));var Fe=new RegExp("^("+Z+")(?!px)[a-z%]+$","i"),Ue=function(t){var n=t.ownerDocument.defaultView;return n&&n.opener||(n=e),n.getComputedStyle(t)},qe=function(e,t,n){var r,i,o={};for(i in t)o[i]=e.style[i],e.style[i]=t[i];for(i in r=n.call(e),t)e.style[i]=o[i];return r},Be=new RegExp(te.join("|"),"i");function ze(e,t,n){var r,i,o,a,s=e.style;return(n=n||Ue(e))&&(""!==(a=n.getPropertyValue(t)||n[t])||re(e)||(a=w.style(e,t)),!d.pixelBoxStyles()&&Fe.test(a)&&Be.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function Ve(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}!function(){function t(){if(u){c.style.cssText="position:absolute;
48left:-11111px;width:60px;margin-top:1px;padding:0;border:0",u.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",ne.appendChild(c).appendChild(u);var t=e.getComputedStyle(u);r="1%"!==t.top,l=12===n(t.marginLeft),u.style.right="60%",a=36===n(t.right),i=36===n(t.width),u.style.position="absolute",o=12===n(u.offsetWidth/3),ne.removeChild(c),u=null}}function n(e){return Math.round(parseFloat(e))}var r,i,o,a,s,l,c=y.createElement("div"),u=y.createElement("div");u.style&&(u.style.backgroundClip="content-box",u.cloneNode(!0).style.backgroundClip="",d.clearCloneStyle="content-box"===u.style.backgroundClip,w.extend(d,{boxSizingReliable:function(){return t(),i},pixelBoxStyles:function(){return t(),a},pixelPosition:function(){return t(),r},reliableMarginLeft:function(){return t(),l},scrollboxSize:function(){return t(),o},reliableTrDimensions:function(){var t,n,r,i;return null==s&&(t=y.createElement("table"),n=y.createElement("tr"),r=y.createElement("div"),t.style.cssText="position:absolute;left:-11111px",n.style.height="1px",r.style.height="9px",ne.appendChild(t).appendChild(n).appendChild(r),i=e.getComputedStyle(n),s=parseInt(i.height)>3,ne.removeChild(t)),s}}))}();var We=["Webkit","Moz","ms"],He=y.createElement("div").style,Ye={};function Xe(e){var t=w.cssProps[e]||Ye[e];return t||(e in He?e:Ye[e]=function(e){for(var t=e[0].toUpperCase()+e.slice(1),n=We.length;n--;)if((e=We[n]+t)in He)return e}(e)||e)}var Ge=/^(none|table(?!-c[ea]).+)/,$e=/^--/,Qe={position:"absolute",visibility:"hidden",display:"block"},Ke={letterSpacing:"0",fontWeight:"400"};function Je(e,t,n){var r=ee.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function Ze(e,t,n,r,i,o){var a="width"===t?1:0,s=0,l=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(l+=w.css(e,n+te[a],!0,i)),r?("content"===n&&(l-=w.css(e,"padding"+te[a],!0,i)),"margin"!==n&&(l-=w.css(e,"border"+te[a]+"Width",!0,i))):(l+=w.css(e,"padding"+te[a],!0,i),"padding"!==n?l+=w.css(e,"border"+te[a]+"Width",!0,i):s+=w.css(e,"border"+te[a]+"Width",!0,i));return!r&&o>=0&&(l+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-l-s-.5))||0),l}function et(e,t,n){var r=Ue(e),i=(!d.boxSizingReliable()||n)&&"border-box"===w.css(e,"boxSizing",!1,r),o=i,a=ze(e,t,r),s="offset"+t[0].toUpperCase()+t.slice(1);if(Fe.test(a)){if(!n)return a;a="auto"}return(!d.boxSizingReliable()&&i||!d.reliableTrDimensions()&&T(e,"tr")||"auto"===a||!parseFloat(a)&&"inline"===w.css(e,"display",!1,r))&&e.getClientRects().length&&(i="border-box"===w.css(e,"boxSizing",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+Ze(e,t,n||(i?"border":"content"),o,r,a)+"px"}function tt(e,t,n,r,i){return new tt.prototype.init(e,t,n,r,i)}w.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=ze(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=H(t),l=$e.test(t),c=e.style;if(l||(t=Xe(s)),a=w.cssHooks[t]||w.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:c[t];"string"===(o=typeof n)&&(i=ee.exec(n))&&i[1]&&(n=ae(e,t,i),o="number"),null!=n&&n==n&&("number"!==o||l||(n+=i&&i[3]||(w.cssNumber[s]?"":"px")),d.clearCloneStyle||""!==n||0!==t.indexOf("background")||(c[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(l?c.setProperty(t,n):c[t]=n))}},css:function(e,t,n,r){var i,o,a,s=H(t);return $e.test(t)||(t=Xe(s)),(a=w.cssHooks[t]||w.cssHooks[s])&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=ze(e,t,r)),"normal"===i&&t in Ke&&(i=Ke[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),w.each(["height","width"],(function(e,t){w.cssHooks[t]={get:function(e,n,r){if(n)return!Ge.test(w.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?et(e,t,r):qe(e,Qe,(function(){return et(e,t,r)}))},set:function(e,n,r){var i,o=Ue(e),a=!d.scrollboxSize()&&"absolute"===o.position,s=(a||r)&&"border-box"===w.css(e,"boxSizing",!1,o),l=r?Ze(e,t,r,s,o):0;return s&&a&&(l-=Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-parseFloat(o[t])-Ze(e,t,"border",!1,o)-.5)),l&&(i=ee.exec(n))&&"px"!==(i[3]||"px")&&(e.style[t]=n,n=w.css(e,t)),Je(0,n,l)}}}
vendor: 4,720 bytes, line 48
48)),w.cssHooks.marginLeft=Ve(d.reliableMarginLeft,(function(e,t){if(t)return(parseFloat(ze(e,"marginLeft"))||e.getBoundingClientRect().left-qe(e,{marginLeft:0},(function(){return e.getBoundingClientRect().left})))+"px"})),w.each({margin:"",padding:"",border:"Width"},(function(e,t){w.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];r<4;r++)i[e+te[r]+t]=o[r]||o[r-2]||o[0];return i}},"margin"!==e&&(w.cssHooks[e+t].set=Je)})),w.fn.extend({css:function(e,t){return B(this,(function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Ue(e),i=t.length;a<i;a++)o[t[a]]=w.css(e,t[a],!1,r);return o}return void 0!==n?w.style(e,t,n):w.css(e,t)}),e,t,arguments.length>1)}}),w.Tween=tt,tt.prototype={constructor:tt,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||w.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(w.cssNumber[n]?"":"px")},cur:function(){var e=tt.propHooks[this.prop];return e&&e.get?e.get(this):tt.propHooks._default.get(this)},run:function(e){var t,n=tt.propHooks[this.prop];return this.options.duration?this.pos=t=w.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):tt.propHooks._default.set(this),this}},tt.prototype.init.prototype=tt.prototype,tt.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=w.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){w.fx.step[e.prop]?w.fx.step[e.prop](e):1!==e.elem.nodeType||!w.cssHooks[e.prop]&&null==e.elem.style[Xe(e.prop)]?e.elem[e.prop]=e.now:w.style(e.elem,e.prop,e.now+e.unit)}}},tt.propHooks.scrollTop=tt.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},w.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},w.fx=tt.prototype.init,w.fx.step={};var nt,rt,it=/^(?:toggle|show|hide)$/,ot=/queueHooks$/;function at(){rt&&(!1===y.hidden&&e.requestAnimationFrame?e.requestAnimationFrame(at):e.setTimeout(at,w.fx.interval),w.fx.tick())}function st(){return e.setTimeout((function(){nt=void 0})),nt=Date.now()}function lt(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i["margin"+(n=te[r])]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function ct(e,t,n){for(var r,i=(ut.tweeners[t]||[]).concat(ut.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function ut(e,t,n){var r,i,o=0,a=ut.prefilters.length,s=w.Deferred().always((function(){delete l.elem})),l=function(){if(i)return!1;for(var t=nt||st(),n=Math.max(0,c.startTime+c.duration-t),r=1-(n/c.duration||0),o=0,a=c.tweens.length;o<a;o++)c.tweens[o].run(r);return s.notifyWith(e,[c,r,n]),r<1&&a?n:(a||s.notifyWith(e,[c,1,0]),s.resolveWith(e,[c]),!1)},c=s.promise({elem:e,props:w.extend({},t),opts:w.extend(!0,{specialEasing:{},easing:w.easing._default},n),originalProperties:t,originalOptions:n,startTime:nt||st(),duration:n.duration,tweens:[],createTween:function(t,n){var r=w.Tween(e,c.opts,t,n,c.opts.specialEasing[t]||c.opts.easing);return c.tweens.push(r),r},stop:function(t){var n=0,r=t?c.tweens.length:0;if(i)return this;for(i=!0;n<r;n++)c.tweens[n].run(1);return t?(s.notifyWith(e,[c,1,0]),s.resolveWith(e,[c,t])):s.rejectWith(e,[c,t]),this}}),u=c.props;for(!function(e,t){var n,r,i,o,a;for(n in e)if(i=t[r=H(n)],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=w.cssHooks[r])&&"expand"in a)for(n in o=a.expand(o),delete e[r],o)n in e||(e[n]=o[n],t[n]=i);else t[r]=i}(u,c.opts.specialEasing);o<a;o++)if(r=ut.prefilters[o].call(c,e,u,c.opts))return h(r.stop)&&(w._queueHooks(c.elem,c.opts.queue).stop=r.stop.bind(r)),r;return w.map(u,ct,c),h(c.opts.start)&&c.opts.start.call(e,c),c.progress(c.opts.progress).done(c.opts.done,c.opts.complete).fail(c.opts.fail).always(c.opts.always),w.fx.timer(w.extend(l,{elem:e,anim:c,queue:c.opts.queue})),c}w.Animation=w.extend(ut,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return ae(n.elem,e,ee.exec(t),n),n}]},tweener:function(e,t){h(e)?(t=e,e=["*"]):e=e.match(A);for(var n,r=0,i=e.length;r<i;r++)n=e[r],ut.tweeners[n]=ut.tweeners[n]||[],ut.tweeners[n].unshift(t)},prefilters:[function(e,t,n){var r,i,o,a,s,l,c,u,p="width"in t||"height"in t,f=this,d={},h=e.style,m=e.nodeType&&oe(e),y=G.get(e,"fxshow");for(r in n.queue||(null==(a=w._queueHooks(e,"fx")).unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,f.always((function(){f.always((function(){a.unqueued--,w.queue(e,"fx").length||a.empty.fire()}))}
vendor: 5,389 bytes, line 48
48))),t)if(i=t[r],it.test(i)){if(delete t[r],o=o||"toggle"===i,i===(m?"hide":"show")){if("show"!==i||!y||void 0===y[r])continue;m=!0}d[r]=y&&y[r]||w.style(e,r)}if((l=!w.isEmptyObject(t))||!w.isEmptyObject(d))for(r in p&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(c=y&&y.display)&&(c=G.get(e,"display")),"none"===(u=w.css(e,"display"))&&(c?u=c:(ce([e],!0),c=e.style.display||c,u=w.css(e,"display"),ce([e]))),("inline"===u||"inline-block"===u&&null!=c)&&"none"===w.css(e,"float")&&(l||(f.done((function(){h.display=c})),null==c&&(u=h.display,c="none"===u?"":u)),h.display="inline-block")),n.overflow&&(h.overflow="hidden",f.always((function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]}))),l=!1,d)l||(y?"hidden"in y&&(m=y.hidden):y=G.access(e,"fxshow",{display:c}),o&&(y.hidden=!m),m&&ce([e],!0),f.done((function(){for(r in m||ce([e]),G.remove(e,"fxshow"),d)w.style(e,r,d[r])}))),l=ct(m?y[r]:0,r,f),r in y||(y[r]=l.start,m&&(l.end=l.start,l.start=0))}],prefilter:function(e,t){t?ut.prefilters.unshift(e):ut.prefilters.push(e)}}),w.speed=function(e,t,n){var r=e&&"object"==typeof e?w.extend({},e):{complete:n||!n&&t||h(e)&&e,duration:e,easing:n&&t||t&&!h(t)&&t};return w.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in w.fx.speeds?r.duration=w.fx.speeds[r.duration]:r.duration=w.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){h(r.old)&&r.old.call(this),r.queue&&w.dequeue(this,r.queue)},r},w.fn.extend({fadeTo:function(e,t,n,r){return this.filter(oe).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=w.isEmptyObject(e),o=w.speed(t,n,r),a=function(){var t=ut(this,w.extend({},e),o);(i||G.get(this,"finish"))&&t.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(e,t,n){var r=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=void 0),t&&this.queue(e||"fx",[]),this.each((function(){var t=!0,i=null!=e&&e+"queueHooks",o=w.timers,a=G.get(this);if(i)a[i]&&a[i].stop&&r(a[i]);else for(i in a)a[i]&&a[i].stop&&ot.test(i)&&r(a[i]);for(i=o.length;i--;)o[i].elem!==this||null!=e&&o[i].queue!==e||(o[i].anim.stop(n),t=!1,o.splice(i,1));!t&&n||w.dequeue(this,e)}))},finish:function(e){return!1!==e&&(e=e||"fx"),this.each((function(){var t,n=G.get(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=w.timers,a=r?r.length:0;for(n.finish=!0,w.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;t<a;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish}))}}),w.each(["toggle","show","hide"],(function(e,t){var n=w.fn[t];w.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(lt(t,!0),e,r,i)}})),w.each({slideDown:lt("show"),slideUp:lt("hide"),slideToggle:lt("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},(function(e,t){w.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}})),w.timers=[],w.fx.tick=function(){var e,t=0,n=w.timers;for(nt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||w.fx.stop(),nt=void 0},w.fx.timer=function(e){w.timers.push(e),w.fx.start()},w.fx.interval=13,w.fx.start=function(){rt||(rt=!0,at())},w.fx.stop=function(){rt=null},w.fx.speeds={slow:600,fast:200,_default:400},w.fn.delay=function(t,n){return t=w.fx&&w.fx.speeds[t]||t,n=n||"fx",this.queue(n,(function(n,r){var i=e.setTimeout(n,t);r.stop=function(){e.clearTimeout(i)}}))},function(){var e=y.createElement("input"),t=y.createElement("select").appendChild(y.createElement("option"));e.type="checkbox",d.checkOn=""!==e.value,d.optSelected=t.selected,(e=y.createElement("input")).value="t",e.type="radio",d.radioValue="t"===e.value}();var pt,ft=w.expr.attrHandle;w.fn.extend({attr:function(e,t){return B(this,w.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each((function(){w.removeAttr(this,e)}))}}),w.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return void 0===e.getAttribute?w.prop(e,t,n):(1===o&&w.isXMLDoc(e)||(i=w.attrHooks[t.toLowerCase()]||(w.expr.match.bool.test(t)?pt:void 0)),void 0!==n?null===n?void w.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:null==(r=w.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!d.radioValue&&"radio"===t&&T(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(A);if(i&&1===e.nodeType)for(;n=i[r++];)e.removeAttribute(n)}}),pt={set:function(e,t,n){return!1===t?w.removeAttr(e,n):e.setAttribute(n,n),n}},w.each(w.expr.match.bool.source.match(/\w+/g),(function(e,t){var n=ft[t]||w.find.attr;ft[t]=function(e,t,r){var i,o,a=t.toLowerCase();return r||(o=ft[a],ft[a]=i,i=null!=n(e,t,r)?a:null,ft[a]=o),i}}));var dt=/^(?:input|select|textarea|button)$/i,ht=/^(?:a|area)$/i;function mt(e){return(e.match(A)||[]).join(" ")}function yt(e){return e.getAttribute&&e.getAttribute("class")||""}function bt(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(A)||[]}w.fn.extend({prop:function(e,t){return B(this,w.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each((function(){delete this[w.propFix[e]||e]}))}}
vendor: 21,902 bytes, line 48
48),w.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&w.isXMLDoc(e)||(t=w.propFix[t]||t,i=w.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=w.find.attr(e,"tabindex");return t?parseInt(t,10):dt.test(e.nodeName)||ht.test(e.nodeName)&&e.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),d.optSelected||(w.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),w.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],(function(){w.propFix[this.toLowerCase()]=this})),w.fn.extend({addClass:function(e){var t,n,r,i,o,a,s,l=0;if(h(e))return this.each((function(t){w(this).addClass(e.call(this,t,yt(this)))}));if((t=bt(e)).length)for(;n=this[l++];)if(i=yt(n),r=1===n.nodeType&&" "+mt(i)+" "){for(a=0;o=t[a++];)r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=mt(r))&&n.setAttribute("class",s)}return this},removeClass:function(e){var t,n,r,i,o,a,s,l=0;if(h(e))return this.each((function(t){w(this).removeClass(e.call(this,t,yt(this)))}));if(!arguments.length)return this.attr("class","");if((t=bt(e)).length)for(;n=this[l++];)if(i=yt(n),r=1===n.nodeType&&" "+mt(i)+" "){for(a=0;o=t[a++];)for(;r.indexOf(" "+o+" ")>-1;)r=r.replace(" "+o+" "," ");i!==(s=mt(r))&&n.setAttribute("class",s)}return this},toggleClass:function(e,t){var n=typeof e,r="string"===n||Array.isArray(e);return"boolean"==typeof t&&r?t?this.addClass(e):this.removeClass(e):h(e)?this.each((function(n){w(this).toggleClass(e.call(this,n,yt(this),t),t)})):this.each((function(){var t,i,o,a;if(r)for(i=0,o=w(this),a=bt(e);t=a[i++];)o.hasClass(t)?o.removeClass(t):o.addClass(t);else void 0!==e&&"boolean"!==n||((t=yt(this))&&G.set(this,"__className__",t),this.setAttribute&&this.setAttribute("class",t||!1===e?"":G.get(this,"__className__")||""))}))},hasClass:function(e){var t,n,r=0;for(t=" "+e+" ";n=this[r++];)if(1===n.nodeType&&(" "+mt(yt(n))+" ").indexOf(t)>-1)return!0;return!1}});var vt=/\r/g;w.fn.extend({val:function(e){var t,n,r,i=this[0];return arguments.length?(r=h(e),this.each((function(n){var i;1===this.nodeType&&(null==(i=r?e.call(this,n,w(this).val()):e)?i="":"number"==typeof i?i+="":Array.isArray(i)&&(i=w.map(i,(function(e){return null==e?"":e+""}))),(t=w.valHooks[this.type]||w.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))}))):i?(t=w.valHooks[i.type]||w.valHooks[i.nodeName.toLowerCase()])&&"get"in t&&void 0!==(n=t.get(i,"value"))?n:"string"==typeof(n=i.value)?n.replace(vt,""):null==n?"":n:void 0}}),w.extend({valHooks:{option:{get:function(e){var t=w.find.attr(e,"value");return null!=t?t:mt(w.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a="select-one"===e.type,s=a?null:[],l=a?o+1:i.length;for(r=o<0?l:a?o:0;r<l;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!T(n.parentNode,"optgroup"))){if(t=w(n).val(),a)return t;s.push(t)}return s},set:function(e,t){for(var n,r,i=e.options,o=w.makeArray(t),a=i.length;a--;)((r=i[a]).selected=w.inArray(w.valHooks.option.get(r),o)>-1)&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),w.each(["radio","checkbox"],(function(){w.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=w.inArray(w(e).val(),t)>-1}},d.checkOn||(w.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})})),d.focusin="onfocusin"in e;var gt=/^(?:focusinfocus|focusoutblur)$/,wt=function(e){e.stopPropagation()};w.extend(w.event,{trigger:function(t,n,r,i){var o,a,s,l,c,p,f,d,b=[r||y],v=u.call(t,"type")?t.type:t,g=u.call(t,"namespace")?t.namespace.split("."):[];if(a=d=s=r=r||y,3!==r.nodeType&&8!==r.nodeType&&!gt.test(v+w.event.triggered)&&(v.indexOf(".")>-1&&(g=v.split("."),v=g.shift(),g.sort()),c=v.indexOf(":")<0&&"on"+v,(t=t[w.expando]?t:new w.Event(v,"object"==typeof t&&t)).isTrigger=i?2:3,t.namespace=g.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+g.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=r),n=null==n?[t]:w.makeArray(n,[t]),f=w.event.special[v]||{},i||!f.trigger||!1!==f.trigger.apply(r,n))){if(!i&&!f.noBubble&&!m(r)){for(l=f.delegateType||v,gt.test(l+v)||(a=a.parentNode);a;a=a.parentNode)b.push(a),s=a;s===(r.ownerDocument||y)&&b.push(s.defaultView||s.parentWindow||e)}for(o=0;(a=b[o++])&&!t.isPropagationStopped();)d=a,t.type=o>1?l:f.bindType||v,(p=(G.get(a,"events")||Object.create(null))[t.type]&&G.get(a,"handle"))&&p.apply(a,n),(p=c&&a[c])&&p.apply&&Y(a)&&(t.result=p.apply(a,n),!1===t.result&&t.preventDefault());return t.type=v,i||t.isDefaultPrevented()||f._default&&!1!==f._default.apply(b.pop(),n)||!Y(r)||c&&h(r[v])&&!m(r)&&((s=r[c])&&(r[c]=null),w.event.triggered=v,t.isPropagationStopped()&&d.addEventListener(v,wt),r[v](),t.isPropagationStopped()&&d.removeEventListener(v,wt),w.event.triggered=void 0,s&&(r[c]=s)),t.result}},simulate:function(e,t,n){var r=w.extend(new w.Event,n,{type:e,isSimulated:!0});w.event.trigger(r,null,t)}}),w.fn.extend({trigger:function(e,t){return this.each((function(){w.event.trigger(e,t,this)}))},triggerHandler:function(e,t){var n=this[0];if(n)return w.event.trigger(e,t,n,!0)}}),d.focusin||w.each({focus:"focusin",blur:"focusout"},(function(e,t){var n=function(e){w.event.simulate(t,e.target,w.event.fix(e))};w.event.special[t]={setup:function(){var r=this.ownerDocument||this.document||this,i=G.access(r,t);i||r.addEventListener(e,n,!0),G.access(r,t,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this.document||this,i=G.access(r,t)-1;i?G.access(r,t,i):(r.removeEventListener(e,n,!0),G.remove(r,t))}}}));var Ct=e.location,_t={guid:Date.now()},kt=/\?/;w.parseXML=function(t){var n;if(!t||"string"!=typeof t)return null;try{n=(new e.DOMParser).parseFromString(t,"text/xml")}catch(e){n=void 0}return n&&!n.getElementsByTagName("parsererror").length||w.error("Invalid XML: "+t),n};var St=/\[\]$/,Et=/\r?\n/g,Tt=/^(?:submit|button|image|reset|file)$/i,Ot=/^(?:input|select|textarea|keygen)/i;function Pt(e,t,n,r){var i;if(Array.isArray(t))w.each(t,(function(t,i){n||St.test(e)?r(e,i):Pt(e+"["+("object"==typeof i&&null!=i?t:"")+"]",i,n,r)}));else if(n||"object"!==g(t))r(e,t);else for(i in t)Pt(e+"["+i+"]",t[i],n,r)}w.param=function(e,t){var n,r=[],i=function(e,t){var n=h(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!w.isPlainObject(e))w.each(e,(function(){i(this.name,this.value)}));else for(n in e)Pt(n,e[n],t,i);return r.join("&")},w.fn.extend({serialize:function(){return w.param(this.serializeArray())},serializeArray:function(){return this.map((function(){var e=w.prop(this,"elements");return e?w.makeArray(e):this})).filter((function(){var e=this.type;return this.name&&!w(this).is(":disabled")&&Ot.test(this.nodeName)&&!Tt.test(e)&&(this.checked||!fe.test(e))})).map((function(e,t){var n=w(this).val();return null==n?null:Array.isArray(n)?w.map(n,(function(e){return{name:t.name,value:e.replace(Et,"\r\n")}})):{name:t.name,value:n.replace(Et,"\r\n")}})).get()}});var Rt=/%20/g,xt=/#.*$/,Dt=/([?&])_=[^&]*/,jt=/^(.*?):[ \t]*([^\r\n]*)$/gm,Mt=/^(?:GET|HEAD)$/,At=/^\/\//,It={},Nt={},Lt="*/".concat("*"),Ft=y.createElement("a");function Ut(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(A)||[];if(h(n))for(;r=o[i++];)"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function qt(e,t,n,r){var i={},o=e===Nt;function a(s){var l;return i[s]=!0,w.each(e[s]||[],(function(e,s){var c=s(t,n,r);return"string"!=typeof c||o||i[c]?o?!(l=c):void 0:(t.dataTypes.unshift(c),a(c),!1)})),l}return a(t.dataTypes[0])||!i["*"]&&a("*")}function Bt(e,t){var n,r,i=w.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&w.extend(!0,e,r),e}Ft.href=Ct.href,w.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ct.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Ct.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Lt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":w.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?Bt(Bt(e,w.ajaxSettings),t):Bt(w.ajaxSettings,e)},ajaxPrefilter:Ut(It),ajaxTransport:Ut(Nt),ajax:function(t,n){"object"==typeof t&&(n=t,t=void 0),n=n||{};var r,i,o,a,s,l,c,u,p,f,d=w.ajaxSetup({},n),h=d.context||d,m=d.context&&(h.nodeType||h.jquery)?w(h):w.event,b=w.Deferred(),v=w.Callbacks("once memory"),g=d.statusCode||{},C={},_={},k="canceled",S={readyState:0,getResponseHeader:function(e){var t;if(c){if(!a)for(a={};t=jt.exec(o);)a[t[1].toLowerCase()+" "]=(a[t[1].toLowerCase()+" "]||[]).concat(t[2]);t=a[e.toLowerCase()+" "]}return null==t?null:t.join(", ")},getAllResponseHeaders:function(){return c?o:null},setRequestHeader:function(e,t){return null==c&&(e=_[e.toLowerCase()]=_[e.toLowerCase()]||e,C[e]=t),this},overrideMimeType:function(e){return null==c&&(d.mimeType=e),this},statusCode:function(e){var t;if(e)if(c)S.always(e[S.status]);else for(t in e)g[t]=[g[t],e[t]];return this},abort:function(e){var t=e||k;return r&&r.abort(t),E(0,t),this}};if(b.promise(S),d.url=((t||d.url||Ct.href)+"").replace(At,Ct.protocol+"//"),d.type=n.method||n.type||d.method||d.type,d.dataTypes=(d.dataType||"*").toLowerCase().match(A)||[""],null==d.crossDomain){l=y.createElement("a");try{l.href=d.url,l.href=l.href,d.crossDomain=Ft.protocol+"//"+Ft.host!=l.protocol+"//"+l.host}catch(e){d.crossDomain=!0}}if(d.data&&d.processData&&"string"!=typeof d.data&&(d.data=w.param(d.data,d.traditional)),qt(It,d,n,S),c)return S;for(p in(u=w.event&&d.global)&&0==w.active++&&w.event.trigger("ajaxStart"),d.type=d.type.toUpperCase(),d.hasContent=!Mt.test(d.type),i=d.url.replace(xt,""),d.hasContent?d.data&&d.processData&&0===(d.contentType||"").indexOf("application/x-www-form-urlencoded")&&(d.data=d.data.replace(Rt,"+")):(f=d.url.slice(i.length),d.data&&(d.processData||"string"==typeof d.data)&&(i+=(kt.test(i)?"&":"?")+d.data,delete d.data),!1===d.cache&&(i=i.replace(Dt,"$1"),f=(kt.test(i)?"&":"?")+"_="+_t.guid+++f),d.url=i+f),d.ifModified&&(w.lastModified[i]&&S.setRequestHeader("If-Modified-Since",w.lastModified[i]),w.etag[i]&&S.setRequestHeader("If-None-Match",w.etag[i])),(d.data&&d.hasContent&&!1!==d.contentType||n.contentType)&&S.setRequestHeader("Content-Type",d.contentType),S.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+("*"!==d.dataTypes[0]?", "+Lt+"; q=0.01":""):d.accepts["*"]),d.headers)S.setRequestHeader(p,d.headers[p]);if(d.beforeSend&&(!1===d.beforeSend.call(h,S,d)||c))return S.abort();if(k="abort",v.add(d.complete),S.done(d.success),S.fail(d.error),r=qt(Nt,d,n,S)){if(S.readyState=1,u&&m.trigger("ajaxSend",[S,d]),c)return S;d.async&&d.timeout>0&&(s=e.setTimeout((function(){S.abort("timeout")}),d.timeout));try{c=!1,r.send(C,E)}catch(e){if(c)throw e;E(-1,e)}}else E(-1,"No Transport");function E(t,n,a,l){var p,f,y,C,_,k=n;c||(c=!0,s&&e.clearTimeout(s),r=void 0,o=l||"",S.readyState=t>0?4:0,p=t>=200&&t<300||304===t,a&&(C=function(e,t,n){for(var r,i,o,a,s=e.contents,l=e.dataTypes;"*"===l[0];)l.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){l.unshift(i);break}if(l[0]in n)o=l[0];else{for(i in n){if(!l[0]||e.converters[i+" "+l[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==l[0]&&l.unshift(o),n[o]}(d,S,a)),!p&&w.inArray("script",d.dataTypes)>-1&&(d.converters["text script"]=function(){}),C=function(e,t,n,r){var i,o,a,s,l,c={},u=e.dataTypes.slice();if(u[1])for(a in e.converters)c[a.toLowerCase()]=e.converters[a];for(o=u.shift();o;)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!l&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),l=o,o=u.shift())if("*"===o)o=l;else if("*"!==l&&l!==o){if(!(a=c[l+" "+o]||c["* "+o]))for(i in c)if((s=i.split(" "))[1]===o&&(a=c[l+" "+s[0]]||c["* "+s[0]])){!0===a?a=c[i]:!0!==c[i]&&(o=s[0],u.unshift(s[1]));break}if(!0!==a)if(a&&e.throws)t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+l+" to "+o}}}return{state:"success",data:t}}(d,C,S,p),p?(d.ifModified&&((_=S.getResponseHeader("Last-Modified"))&&(w.lastModified[i]=_),(_=S.getResponseHeader("etag"))&&(w.etag[i]=_)),204===t||"HEAD"===d.type?k="nocontent":304===t?k="notmodified":(k=C.state,f=C.data,p=!(y=C.error))):(y=k,!t&&k||(k="error",t<0&&(t=0))),S.status=t,S.statusText=(n||k)+"",p?b.resolveWith(h,[f,k,S]):b.rejectWith(h,[S,k,y]),S.statusCode(g),g=void 0,u&&m.trigger(p?"ajaxSuccess":"ajaxError",[S,d,p?f:y]),v.fireWith(h,[S,k]),u&&(m.trigger("ajaxComplete",[S,d]),--w.active||w.event.trigger("ajaxStop")))}return S},getJSON:function(e,t,n){return w.get(e,t,n,"json")},getScript:function(e,t){return w.get(e,void 0,t,"script")}}),w.each(["get","post"],(function(e,t){w[t]=function(e,n,r,i){return h(n)&&(i=i||r,r=n,n=void 0),w.ajax(w.extend({url:e,type:t,dataType:i,data:n,success:r},w.isPlainObject(e)&&e))}})),w.ajaxPrefilter((function(e){var t;for(t in e.headers)"content-type"===t.toLowerCase()&&(e.contentType=e.headers[t]||"")})),w._evalUrl=function(e,t,n){return w.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){w.globalEval(e,t,n)}})},w.fn.extend({wrapAll:function(e){var t;return this[0]&&(h(e)&&(e=e.call(this[0])),t=w(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map((function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e})).append(this)),this},wrapInner:function(e){return h(e)?this.each((function(t){w(this).wrapInner(e.call(this,t))})):this.each((function(){var t=w(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)}))},wrap:function(e){var t=h(e);return this.each((function(n){w(this).wrapAll(t?e.call(this,n):e)}))},unwrap:function(e){return this.parent(e).not("body").each((function(){w(this).replaceWith(this.childNodes)})),this}}),w.expr.pseudos.hidden=function(e){return!w.expr.pseudos.visible(e)},w.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},w.ajaxSettings.xhr=function(){try{return new e.XMLHttpRequest}catch(e){}};var zt={0:200,1223:204},Vt=w.ajaxSettings.xhr();d.cors=!!Vt&&"withCredentials"in Vt,d.ajax=Vt=!!Vt,w.ajaxTransport((function(t){var n,r;if(d.cors||Vt&&!t.crossDomain)return{send:function(i,o){var a,s=t.xhr();if(s.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(a in t.xhrFields)s[a]=t.xhrFields[a];for(a in t.mimeType&&s.overrideMimeType&&s.overrideMimeType(t.mimeType),t.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest"),i)s.setRequestHeader(a,i[a]);n=function(e){return function(){n&&(n=r=s.onload=s.onerror=s.onabort=s.ontimeout=s.onreadystatechange=null,"abort"===e?s.abort():"error"===e?"number"!=typeof s.status?o(0,"error"):o(s.status,s.statusText):o(zt[s.status]||s.status,s.statusText,"text"!==(s.responseType||"text")||"string"!=typeof s.responseText?{binary:s.response}:{text:s.responseText},s.getAllResponseHeaders()))}},s.onload=n(),r=s.onerror=s.ontimeout=n("error"),void 0!==s.onabort?s.onabort=r:s.onreadystatechange=function(){4===s.readyState&&e.setTimeout((function(){n&&r()}))},n=n("abort");try{s.send(t.hasContent&&t.data||null)}catch(e){if(n)throw e}},abort:function(){n&&n()}}})),w.ajaxPrefilter((function(e){e.crossDomain&&(e.contents.script=!1)})),w.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return w.globalEval(e),e}}}),w.ajaxPrefilter("script",(function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")})),w.ajaxTransport("script",(function(e){var t,n;if(e.crossDomain||e.scriptAttrs)return{send:function(r,i){t=w("<script>").attr(e.scriptAttrs||{}).prop({charset:e.scriptCharset,src:e.url}).on("load error",n=function(e){t.remove(),n=null,e&&i("error"===e.type?404:200,e.type)}),y.head.appendChild(t[0])},abort:function(){n&&n()}}}));var Wt,Ht=[],Yt=/(=)\?(?=&|$)|\?\?/;w.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Ht.pop()||w.expando+"_"+_t.guid++;return this[e]=!0,e}}),w.ajaxPrefilter("json jsonp",(function(t,n,r){var i,o,a,s=!1!==t.jsonp&&(Yt.test(t.url)?"url":"string"==typeof t.data&&0===(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&Yt.test(t.data)&&"data");if(s||"jsonp"===t.dataTypes[0])return i=t.jsonpCallback=h(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(Yt,"$1"+i):!1!==t.jsonp&&(t.url+=(kt.test(t.url)?"&":"?")+t.jsonp+"="+i),t.converters["script json"]=function(){return a||w.error(i+" was not called"),a[0]},t.dataTypes[0]="json",o=e[i],e[i]=function(){a=arguments},r.always((function(){void 0===o?w(e).removeProp(i):e[i]=o,t[i]&&(t.jsonpCallback=n.jsonpCallback,Ht.push(i)),a&&h(o)&&o(a[0]),a=o=void 0})),"script"})),d.createHTMLDocument=((Wt=y.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",2===Wt.childNodes.length),w.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(d.createHTMLDocument?((r=(t=y.implementation.createHTMLDocument("")).createElement("base")).href=y.location.href,t.head.appendChild(r)):t=y),o=!n&&[],(i=O.exec(e))?[t.createElement(i[1])]:(i=ge([e],t,o),o&&o.length&&w(o).remove(),w.merge([],i.childNodes)));var r,i,o},w.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return s>-1&&(r=mt(e.slice(s)),e=e.slice(0,s)),h(t)?(n=t,t=void 0):t&&"object"==typeof t&&(i="POST"),a.length>0&&w.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done((function(e){o=arguments,a.html(r?w("<div>").append(w.parseHTML(e)).find(r):e)})).always(n&&function(e,t){a.each((function(){n.apply(this,o||[e.responseText,t,e])}))}),this},w.expr.pseudos.animated=function(e){return w.grep(w.timers,(function(t){return e===t.elem})).length},w.offset={setOffset:function(e,t,n){var r,i,o,a,s,l,c=w.css(e,"position"),u=w(e),p={};"static"===c&&(e.style.position="relative"),s=u.offset(),o=w.css(e,"top"),l=w.css(e,"left"),("absolute"===c||"fixed"===c)&&(o+l).indexOf("auto")>-1?(a=(r=u.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(l)||0),h(t)&&(t=t.call(e,n,w.extend({},s))),null!=t.top&&(p.top=t.top-s.top+a),null!=t.left&&(p.left=t.left-s.left+i),"using"in t?t.using.call(e,p):("number"==typeof p.top&&(p.top+="px"),"number"==typeof p.left&&(p.left+="px"),u.css(p))}},w.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each((function(t){w.offset.setOffset(this,e,t)}));var t,n,r=this[0];return r?r.getClientRects().length?(t=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:t.top+n.pageYOffset,left:t.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===w.css(r,"position"))t=r.getBoundingClientRect();else{for(t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;e&&(e===n.body||e===n.documentElement)&&"static"===w.css(e,"position");)e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=w(e).offset()).top+=w.css(e,"borderTopWidth",!0),i.left+=w.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-w.css(r,"marginTop",!0),left:t.left-i.left-w.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map((function(){for(var e=this.offsetParent;e&&"static"===w.css(e,"position");)e=e.offsetParent;return e||ne}))}}),w.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},(function(e,t){var n="pageYOffset"===t;w.fn[e]=function(r){return B(this,(function(e,r,i){var o;if(m(e)?o=e:9===e.nodeType&&(o=e.defaultView),void 0===i)return o?o[t]:e[r];o?o.scrollTo(n?o.pageXOffset:i,n?i:o.pageYOffset):e[r]=i}),e,r,arguments.length)}})),w.each(["top","left"],(function(e,t){w.cssHooks[t]=Ve(d.pixelPosition,(function(e,n){if(n)return n=ze(e,t),Fe.test(n)?w(e).position()[t]+"px":n}))})),w.each({Height:"height",Width:"width"},(function(e,t){w.each({padding:"inner"+e,content:t,"":"outer"+e},(function(n,r){w.fn[r]=function(i,o){var a=arguments.length&&(n||"boolean"!=typeof i),s=n||(!0===i||!0===o?"margin":"border");return B(this,(function(t,n,i){var o;return m(t)?0===r.indexOf("outer")?t["inner"+e]:t.document.documentElement["client"+e]:9===t.nodeType?(o=t.documentElement,Math.max(t.body["scroll"+e],o["scroll"+e],t.body["offset"+e],o["offset"+e],o["client"+e])):void 0===i?w.css(t,n,s):w.style(t,n,i,s)}),t,a?i:void 0,a)}}))})),w.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],(function(e,t){w.fn[t]=function(e){return this.on(t,e)}})),w.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),w.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),(function(e,t){w.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}));var Xt=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;w.proxy=function(e,t){var n,r,o;
48if("string"==typeof t&&(n=e[t],t=e,e=n),h(e))return r=i.call(arguments,2),(o=function(){return e.apply(t||this,r.concat(i.call(arguments)))}).guid=e.guid=e.guid||w.guid++,o},w.holdReady=function(e){e?w.readyWait++:w.ready(!0)},w.isArray=Array.isArray,w.parseJSON=JSON.parse,w.nodeName=T,w.isFunction=h,w.isWindow=m,w.camelCase=H,w.type=g,w.now=Date.now,w.isNumeric=function(e){var t=w.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},w.trim=function(e){return null==e?"":(e+"").replace(Xt,"")},"function"==typeof define&&define.amd&&define("jquery",[],(function(){return w}));var Gt=e.jQuery,$t=e.$;return w.noConflict=function(t){return e.$===w&&(e.$=$t),t&&e.jQuery===w&&(e.jQuery=Gt),w},void 0===t&&(e.jQuery=e.$=w),w}))},{}],245:[function(e,t,n){(function(e,r){(function(){!function(e,r){var i,o;"object"==typeof n&&void 0!==t?t.exports=r():"function"==typeof define&&define.amd?define(r):(i=e.Base64,(o=r()).noConflict=function(){return e.Base64=i,o},e.Meteor&&(Base64=o),e.Base64=o)}("undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==e?e:this,(function(){"use strict";var e,t="function"==typeof atob,n="function"==typeof btoa,i="function"==typeof r,o="function"==typeof TextDecoder?new TextDecoder:void 0,a="function"==typeof TextEncoder?new TextEncoder:void 0,s=Array.prototype.slice.call("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="),l=(e={},s.forEach((function(t,n){return e[t]=n})),e),c=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,u=String.fromCharCode.bind(String),p="function"==typeof Uint8Array.from?Uint8Array.from.bind(Uint8Array):function(e,t){return void 0===t&&(t=function(e){return e}),new Uint8Array(Array.prototype.slice.call(e,0).map(t))},f=function(e){return e.replace(/=/g,"").replace(/[+\/]/g,(function(e){return"+"==e?"-":"_"}))},d=function(e){return e.replace(/[^A-Za-z0-9\+\/]/g,"")},h=function(e){for(var t,n,r,i,o="",a=e.length%3,l=0;l<e.length;){if((n=e.charCodeAt(l++))>255||(r=e.charCodeAt(l++))>255||(i=e.charCodeAt(l++))>255)throw new TypeError("invalid character found");o+=s[(t=n<<16|r<<8|i)>>18&63]+s[t>>12&63]+s[t>>6&63]+s[63&t]}return a?o.slice(0,a-3)+"===".substring(a):o},m=n?function(e){return btoa(e)}:i?function(e){return r.from(e,"binary").toString("base64")}:h,y=i?function(e){return r.from(e).toString("base64")}:function(e){for(var t=[],n=0,r=e.length;n<r;n+=4096)t.push(u.apply(null,e.subarray(n,n+4096)));return m(t.join(""))},b=function(e,t){return void 0===t&&(t=!1),t?f(y(e)):y(e)},v=function(e){if(e.length<2)return(t=e.charCodeAt(0))<128?e:t<2048?u(192|t>>>6)+u(128|63&t):u(224|t>>>12&15)+u(128|t>>>6&63)+u(128|63&t);var t=65536+1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320);return u(240|t>>>18&7)+u(128|t>>>12&63)+u(128|t>>>6&63)+u(128|63&t)},g=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,w=function(e){return e.replace(g,v)},C=i?function(e){return r.from(e,"utf8").toString("base64")}:a?function(e){return y(a.encode(e))}:function(e){return m(w(e))},_=function(e,t){return void 0===t&&(t=!1),t?f(C(e)):C(e)},k=function(e){return _(e,!0)},S=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,E=function(e){switch(e.length){case 4:var t=((7&e.charCodeAt(0))<<18|(63&e.charCodeAt(1))<<12|(63&e.charCodeAt(2))<<6|63&e.charCodeAt(3))-65536;return u(55296+(t>>>10))+u(56320+(1023&t));case 3:return u((15&e.charCodeAt(0))<<12|(63&e.charCodeAt(1))<<6|63&e.charCodeAt(2));default:return u((31&e.charCodeAt(0))<<6|63&e.charCodeAt(1))}},T=function(e){return e.replace(S,E)},O=function(e){if(e=e.replace(/\s+/g,""),!c.test(e))throw new TypeError("malformed base64.");e+="==".slice(2-(3&e.length));for(var t,n,r,i="",o=0;o<e.length;)t=l[e.charAt(o++)]<<18|l[e.charAt(o++)]<<12|(n=l[e.charAt(o++)])<<6|(r=l[e.charAt(o++)]),i+=64===n?u(t>>16&255):64===r?u(t>>16&255,t>>8&255):u(t>>16&255,t>>8&255,255&t);return i},P=t?function(e){return atob(d(e))}:i?function(e){return r.from(e,"base64").toString("binary")}:O,R=i?function(e){return p(r.from(e,"base64"))}:function(e){return p(P(e),(function(e){return e.charCodeAt(0)}))},x=function(e){return R(j(e))},D=i?function(e){return r.from(e,"base64").toString("utf8")}:o?function(e){return o.decode(R(e))}:function(e){return T(P(e))},j=function(e){return d(e.replace(/[-_]/g,(function(e){return"-"==e?"+":"/"})))},M=function(e){return D(j(e))},A=function(e){return{value:e,enumerable:!1,writable:!0,configurable:!0}},I=function(){var e=function(e,t){return Object.defineProperty(String.prototype,e,A(t))};e("fromBase64",(function(){return M(this)})),e("toBase64",(function(e){return _(this,e)})),e("toBase64URI",(function(){return _(this,!0)})),e("toBase64URL",(function(){return _(this,!0)})),e("toUint8Array",(function(){return x(this)}))},N=function(){var e=function(e,t){return Object.defineProperty(Uint8Array.prototype,e,A(t))};e("toBase64",(function(e){return b(this,e)})),e("toBase64URI",(function(){return b(this,!0)})),e("toBase64URL",(function(){return b(this,!0)}))},L={version:"3.7.3",VERSION:"3.7.3",atob:P,atobPolyfill:O,btoa:m,btoaPolyfill:h,fromBase64:M,toBase64:_,encode:_,encodeURI:k,encodeURL:k,utob:w,btou:T,decode:M,isValid:function(e){if("string"!=typeof e)return!1;var t=e.replace(/\s+/g,"").replace(/={0,2}$/,"");return!/[^\s0-9a-zA-Z\+/]/.test(t)||!/[^\s0-9a-zA-Z\-_]/.test(t)},fromUint8Array:b,toUint8Array:x,extendString:I,extendUint8Array:N,extendBuiltins:function(){I(),N()},Base64:{}};
vendor: 16,137 bytes, line 48
48return Object.keys(L).forEach((function(e){return L.Base64[e]=L[e]})),L}))}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer)},{buffer:153}],246:[function(e,t,n){!function(e,r){"object"==typeof n&&void 0!==t?t.exports=r():"function"==typeof define&&define.amd?define(r):e.moment=r()}(this,(function(){"use strict";var n,r;function i(){return n.apply(null,arguments)}function o(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function a(e){return null!=e&&"[object Object]"===Object.prototype.toString.call(e)}function s(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function l(e){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(e).length;var t;for(t in e)if(s(e,t))return!1;return!0}function c(e){return void 0===e}function u(e){return"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e)}function p(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function f(e,t){var n,r=[];for(n=0;n<e.length;++n)r.push(t(e[n],n));return r}function d(e,t){for(var n in t)s(t,n)&&(e[n]=t[n]);return s(t,"toString")&&(e.toString=t.toString),s(t,"valueOf")&&(e.valueOf=t.valueOf),e}function h(e,t,n,r){return Et(e,t,n,r,!0).utc()}function m(e){return null==e._pf&&(e._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidEra:null,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],era:null,meridiem:null,rfc2822:!1,weekdayMismatch:!1}),e._pf}function y(e){if(null==e._isValid){var t=m(e),n=r.call(t.parsedDateParts,(function(e){return null!=e})),i=!isNaN(e._d.getTime())&&t.overflow<0&&!t.empty&&!t.invalidEra&&!t.invalidMonth&&!t.invalidWeekday&&!t.weekdayMismatch&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n);if(e._strict&&(i=i&&0===t.charsLeftOver&&0===t.unusedTokens.length&&void 0===t.bigHour),null!=Object.isFrozen&&Object.isFrozen(e))return i;e._isValid=i}return e._isValid}function b(e){var t=h(NaN);return null!=e?d(m(t),e):m(t).userInvalidated=!0,t}r=Array.prototype.some?Array.prototype.some:function(e){var t,n=Object(this),r=n.length>>>0;for(t=0;t<r;t++)if(t in n&&e.call(this,n[t],t,n))return!0;return!1};var v=i.momentProperties=[],g=!1;function w(e,t){var n,r,i;if(c(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),c(t._i)||(e._i=t._i),c(t._f)||(e._f=t._f),c(t._l)||(e._l=t._l),c(t._strict)||(e._strict=t._strict),c(t._tzm)||(e._tzm=t._tzm),c(t._isUTC)||(e._isUTC=t._isUTC),c(t._offset)||(e._offset=t._offset),c(t._pf)||(e._pf=m(t)),c(t._locale)||(e._locale=t._locale),v.length>0)for(n=0;n<v.length;n++)c(i=t[r=v[n]])||(e[r]=i);return e}function C(e){w(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===g&&(g=!0,i.updateOffset(this),g=!1)}function _(e){return e instanceof C||null!=e&&null!=e._isAMomentObject}function k(e){!1===i.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function S(e,t){var n=!0;return d((function(){if(null!=i.deprecationHandler&&i.deprecationHandler(null,e),n){var r,o,a,l=[];for(o=0;o<arguments.length;o++){if(r="","object"==typeof arguments[o]){for(a in r+="\n["+o+"] ",arguments[0])s(arguments[0],a)&&(r+=a+": "+arguments[0][a]+", ");r=r.slice(0,-2)}else r=arguments[o];l.push(r)}k(e+"\nArguments: "+Array.prototype.slice.call(l).join("")+"\n"+(new Error).stack),n=!1}return t.apply(this,arguments)}),t)}var E,T={};function O(e,t){null!=i.deprecationHandler&&i.deprecationHandler(e,t),T[e]||(k(t),T[e]=!0)}function P(e){return"undefined"!=typeof Function&&e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function R(e,t){var n,r=d({},e);for(n in t)s(t,n)&&(a(e[n])&&a(t[n])?(r[n]={},d(r[n],e[n]),d(r[n],t[n])):null!=t[n]?r[n]=t[n]:delete r[n]);for(n in e)s(e,n)&&!s(t,n)&&a(e[n])&&(r[n]=d({},r[n]));return r}function x(e){null!=e&&this.set(e)}i.suppressDeprecationWarnings=!1,i.deprecationHandler=null,E=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)s(e,t)&&n.push(t);return n};function D(e,t,n){var r=""+Math.abs(e),i=t-r.length;return(e>=0?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}var j=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,M=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,A={},I={};function N(e,t,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),e&&(I[e]=i),t&&(I[t[0]]=function(){return D(i.apply(this,arguments),t[1],t[2])}),n&&(I[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),e)})}function L(e,t){return e.isValid()?(t=F(t,e.localeData()),A[t]=A[t]||function(e){var t,n,r,i=e.match(j);for(t=0,n=i.length;t<n;t++)I[i[t]]?i[t]=I[i[t]]:i[t]=(r=i[t]).match(/\[[\s\S]/)?r.replace(/^\[|\]$/g,""):r.replace(/\\/g,"");return function(t){var r,o="";for(r=0;r<n;r++)o+=P(i[r])?i[r].call(t,e):i[r];return o}}(t),A[t](e)):e.localeData().invalidDate()}function F(e,t){var n=5;function r(e){return t.longDateFormat(e)||e}for(M.lastIndex=0;n>=0&&M.test(e);)e=e.replace(M,r),M.lastIndex=0,n-=1;return e}var U={};function q(e,t){var n=e.toLowerCase();U[n]=U[n+"s"]=U[t]=e}function B(e){return"string"==typeof e?U[e]||U[e.toLowerCase()]:void 0}function z(e){var t,n,r={};for(n in e)s(e,n)&&(t=B(n))&&(r[t]=e[n]);return r}var V={};function W(e,t){V[e]=t}function H(e){return e%4==0&&e%100!=0||e%400==0}function Y(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function X(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=Y(t)),n}function G(e,t){return function(n){return null!=n?(Q(this,e,n),i.updateOffset(this,t),this):$(this,e)}}function $(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function Q(e,t,n){e.isValid()&&!isNaN(n)&&("FullYear"===t&&H(e.year())&&1===e.month()&&29===e.date()?(n=X(n),e._d["set"+(e._isUTC?"UTC":"")+t](n,e.month(),_e(n,e.month()))):e._d["set"+(e._isUTC?"UTC":"")+t](n))}var K,J=/\d/,Z=/\d\d/,ee=/\d{3}/,te=/\d{4}/,ne=/[+-]?\d{6}/,re=/\d\d?/,ie=/\d\d\d\d?/,oe=/\d\d\d\d\d\d?/,ae=/\d{1,3}/,se=/\d{1,4}/,le=/[+-]?\d{1,6}/,ce=/\d+/,ue=/[+-]?\d+/,pe=/Z|[+-]\d\d:?\d\d/gi,fe=/Z|[+-]\d\d(?::?\d\d)?/gi,de=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i;function he(e,t,n){K[e]=P(t)?t:function(e,r){return e&&n?n:t}}function me(e,t){return s(K,e)?K[e](t._strict,t._locale):new RegExp(ye(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(e,t,n,r,i){return t||n||r||i}))))}function ye(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}K={};var be={};function ve(e,t){var n,r=t;for("string"==typeof e&&(e=[e]),u(t)&&(r=function(e,n){n[t]=X(e)}),n=0;n<e.length;n++)be[e[n]]=r}function ge(e,t){ve(e,(function(e,n,r,i){r._w=r._w||{},t(e,r._w,r,i)}))}function we(e,t,n){null!=t&&s(be,e)&&be[e](t,n._a,n,e)}var Ce;function _e(e,t){if(isNaN(e)||isNaN(t))return NaN;var n,r=(t%(n=12)+n)%n;return e+=(t-r)/12,1===r?H(e)?29:28:31-r%7%2}Ce=Array.prototype.indexOf?Array.prototype.indexOf:function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1},N("M",["MM",2],"Mo",(function(){return this.month()+1})),N("MMM",0,0,(function(e){return this.localeData().monthsShort(this,e)})),N("MMMM",0,0,(function(e){return this.localeData().months(this,e)})),q("month","M"),W("month",8),he("M",re),he("MM",re,Z),he("MMM",(function(e,t){return t.monthsShortRegex(e)})),he("MMMM",(function(e,t){return t.monthsRegex(e)})),ve(["M","MM"],(function(e,t){t[1]=X(e)-1})),ve(["MMM","MMMM"],(function(e,t,n,r){var i=n._locale.monthsParse(e,r,n._strict);null!=i?t[1]=i:m(n).invalidMonth=e}));var ke="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Se="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),Ee=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,Te=de,Oe=de;function Pe(e,t,n){var r,i,o,a=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],r=0;r<12;++r)o=h([2e3,r]),this._shortMonthsParse[r]=this.monthsShort(o,"").toLocaleLowerCase(),this._longMonthsParse[r]=this.months(o,"").toLocaleLowerCase();return n?"MMM"===t?-1!==(i=Ce.call(this._shortMonthsParse,a))?i:null:-1!==(i=Ce.call(this._longMonthsParse,a))?i:null:"MMM"===t?-1!==(i=Ce.call(this._shortMonthsParse,a))||-1!==(i=Ce.call(this._longMonthsParse,a))?i:null:-1!==(i=Ce.call(this._longMonthsParse,a))||-1!==(i=Ce.call(this._shortMonthsParse,a))?i:null}function Re(e,t){var n;if(!e.isValid())return e;if("string"==typeof t)if(/^\d+$/.test(t))t=X(t);else if(!u(t=e.localeData().monthsParse(t)))return e;return n=Math.min(e.date(),_e(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,n),e}function xe(e){return null!=e?(Re(this,e),i.updateOffset(this,!0),this):$(this,"Month")}function De(){function e(e,t){return t.length-e.length}var t,n,r=[],i=[],o=[];for(t=0;t<12;t++)n=h([2e3,t]),r.push(this.monthsShort(n,"")),i.push(this.months(n,"")),o.push(this.months(n,"")),o.push(this.monthsShort(n,""));for(r.sort(e),i.sort(e),o.sort(e),t=0;t<12;t++)r[t]=ye(r[t]),i[t]=ye(i[t]);for(t=0;t<24;t++)o[t]=ye(o[t]);this._monthsRegex=new RegExp("^("+o.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+i.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+r.join("|")+")","i")}function je(e){return H(e)?366:365}N("Y",0,0,(function(){var e=this.year();return e<=9999?D(e,4):"+"+e})),N(0,["YY",2],0,(function(){return this.year()%100})),N(0,["YYYY",4],0,"year"),N(0,["YYYYY",5],0,"year"),N(0,["YYYYYY",6,!0],0,"year"),q("year","y"),W("year",1),he("Y",ue),he("YY",re,Z),he("YYYY",se,te),he("YYYYY",le,ne),he("YYYYYY",le,ne),ve(["YYYYY","YYYYYY"],0),ve("YYYY",(function(e,t){t[0]=2===e.length?i.parseTwoDigitYear(e):X(e)})),ve("YY",(function(e,t){t[0]=i.parseTwoDigitYear(e)})),ve("Y",(function(e,t){t[0]=parseInt(e,10)})),i.parseTwoDigitYear=function(e){return X(e)+(X(e)>68?1900:2e3)};var Me=G("FullYear",!0);function Ae(e,t,n,r,i,o,a){var s;return e<100&&e>=0?(s=new Date(e+400,t,n,r,i,o,a),isFinite(s.getFullYear())&&s.setFullYear(e)):s=new Date(e,t,n,r,i,o,a),s}function Ie(e){var t,n;return e<100&&e>=0?((n=Array.prototype.slice.call(arguments))[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function Ne(e,t,n){var r=7+t-n;return-((7+Ie(e,0,r).getUTCDay()-t)%7)+r-1}function Le(e,t,n,r,i){var o,a,s=1+7*(t-1)+(7+n-r)%7+Ne(e,r,i);return s<=0?a=je(o=e-1)+s:s>je(e)?(o=e+1,a=s-je(e)):(o=e,a=s),{year:o,dayOfYear:a}}function Fe(e,t,n){var r,i,o=Ne(e.year(),t,n),a=Math.floor((e.dayOfYear()-o-1)/7)+1;return a<1?r=a+Ue(i=e.year()-1,t,n):a>Ue(e.year(),t,n)?(r=a-Ue(e.year(),t,n),i=e.year()+1):(i=e.year(),r=a),{week:r,year:i}}function Ue(e,t,n){var r=Ne(e,t,n),i=Ne(e+1,t,n);return(je(e)-r+i)/7}N("w",["ww",2],"wo","week"),N("W",["WW",2],"Wo","isoWeek"),q("week","w"),q("isoWeek","W"),W("week",5),W("isoWeek",5),he("w",re),he("ww",re,Z),he("W",re),he("WW",re,Z),ge(["w","ww","W","WW"],(function(e,t,n,r){t[r.substr(0,1)]=X(e)}));function qe(e,t){return e.slice(t,7).concat(e.slice(0,t))}N("d",0,"do","day"),N("dd",0,0,(function(e){return this.localeData().weekdaysMin(this,e)})),N("ddd",0,0,(function(e){return this.localeData().weekdaysShort(this,e)})),N("dddd",0,0,(function(e){return this.localeData().weekdays(this,e)})),N("e",0,0,"weekday"),N("E",0,0,"isoWeekday"),q("day","d"),q("weekday","e"),q("isoWeekday","E"),W("day",11),W("weekday",11),W("isoWeekday",11),he("d",re),he("e",re),he("E",re),he("dd",(function(e,t){return t.weekdaysMinRegex(e)})),he("ddd",(function(e,t){return t.weekdaysShortRegex(e)})),he("dddd",(function(e,t){return t.weekdaysRegex(e)})),ge(["dd","ddd","dddd"],(function(e,t,n,r){var i=n._locale.weekdaysParse(e,r,n._strict);null!=i?t.d=i:m(n).invalidWeekday=e})),ge(["d","e","E"],(function(e,t,n,r){t[r]=X(e)}));var Be="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),ze="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Ve="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),We=de,He=de,Ye=de;function Xe(e,t,n){var r,i,o,a=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)o=h([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(o,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(o,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(o,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(i=Ce.call(this._weekdaysParse,a))?i:null:"ddd"===t?-1!==(i=Ce.call(this._shortWeekdaysParse,a))?i:null:-1!==(i=Ce.call(this._minWeekdaysParse,a))?i:null:"dddd"===t?-1!==(i=Ce.call(this._weekdaysParse,a))||-1!==(i=Ce.call(this._shortWeekdaysParse,a))||-1!==(i=Ce.call(this._minWeekdaysParse,a))?i:null:"ddd"===t?-1!==(i=Ce.call(this._shortWeekdaysParse,a))||-1!==(i=Ce.call(this._weekdaysParse,a))||-1!==(i=Ce.call(this._minWeekdaysParse,a))?i:null:-1!==(i=Ce.call(this._minWeekdaysParse,a))||-1!==(i=Ce.call(this._weekdaysParse,a))||-1!==(i=Ce.call(this._shortWeekdaysParse,a))?i:null}function Ge(){function e(e,t){return t.length-e.length}var t,n,r,i,o,a=[],s=[],l=[],c=[];for(t=0;t<7;t++)n=h([2e3,1]).day(t),r=ye(this.weekdaysMin(n,"")),i=ye(this.weekdaysShort(n,"")),o=ye(this.weekdays(n,"")),a.push(r),s.push(i),l.push(o),c.push(r),c.push(i),c.push(o);a.sort(e),s.sort(e),l.sort(e),c.sort(e),this._weekdaysRegex=new RegExp("^("+c.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+a.join("|")+")","i")}function $e(){return this.hours()%12||12}function Qe(e,t){N(e,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)}))}function Ke(e,t){return t._meridiemParse}N("H",["HH",2],0,"hour"),N("h",["hh",2],0,$e),N("k",["kk",2],0,(function(){return this.hours()||24})),N("hmm",0,0,(function(){return""+$e.apply(this)+D(this.minutes(),2)})),N("hmmss",0,0,(function(){return""+$e.apply(this)+D(this.minutes(),2)+D(this.seconds(),2)})),N("Hmm",0,0,(function(){return""+this.hours()+D(this.minutes(),2)})),N("Hmmss",0,0,(function(){return""+this.hours()+D(this.minutes(),2)+D(this.seconds(),2)})),Qe("a",!0),Qe("A",!1),q("hour","h"),W("hour",13),he("a",Ke),he("A",Ke),he("H",re),he("h",re),he("k",re),he("HH",re,Z),he("hh",re,Z),he("kk",re,Z),he("hmm",ie),he("hmmss",oe),he("Hmm",ie),he("Hmmss",oe),ve(["H","HH"],3),ve(["k","kk"],(function(e,t,n){var r=X(e);t[3]=24===r?0:r})),ve(["a","A"],(function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e})),ve(["h","hh"],(function(e,t,n){t[3]=X(e),m(n).bigHour=!0})),ve("hmm",(function(e,t,n){var r=e.length-2;t[3]=X(e.substr(0,r)),t[4]=X(e.substr(r)),m(n).bigHour=!0})),ve("hmmss",(function(e,t,n){var r=e.length-4,i=e.length-2;t[3]=X(e.substr(0,r)),t[4]=X(e.substr(r,2)),t[5]=X(e.substr(i)),m(n).bigHour=!0})),ve("Hmm",(function(e,t,n){var r=e.length-2;t[3]=X(e.substr(0,r)),t[4]=X(e.substr(r))})),ve("Hmmss",(function(e,t,n){var r=e.length-4,i=e.length-2;t[3]=X(e.substr(0,r)),t[4]=X(e.substr(r,2)),t[5]=X(e.substr(i))}));var Je=G("Hours",!0);var Ze,et={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:ke,monthsShort:Se,week:{dow:0,doy:6}
vendor: 34,743 bytes, line 48
48,weekdays:Be,weekdaysMin:Ve,weekdaysShort:ze,meridiemParse:/[ap]\.?m?\.?/i},tt={},nt={};function rt(e,t){var n,r=Math.min(e.length,t.length);for(n=0;n<r;n+=1)if(e[n]!==t[n])return n;return r}function it(e){return e?e.toLowerCase().replace("_","-"):e}function ot(n){var r=null;if(void 0===tt[n]&&void 0!==t&&t&&t.exports)try{r=Ze._abbr,e("./locale/"+n),at(r)}catch(e){tt[n]=null}return tt[n]}function at(e,t){var n;return e&&((n=c(t)?lt(e):st(e,t))?Ze=n:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),Ze._abbr}function st(e,t){if(null!==t){var n,r=et;if(t.abbr=e,null!=tt[e])O("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),r=tt[e]._config;else if(null!=t.parentLocale)if(null!=tt[t.parentLocale])r=tt[t.parentLocale]._config;else{if(null==(n=ot(t.parentLocale)))return nt[t.parentLocale]||(nt[t.parentLocale]=[]),nt[t.parentLocale].push({name:e,config:t}),null;r=n._config}return tt[e]=new x(R(r,t)),nt[e]&&nt[e].forEach((function(e){st(e.name,e.config)})),at(e),tt[e]}return delete tt[e],null}function lt(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return Ze;if(!o(e)){if(t=ot(e))return t;e=[e]}return function(e){for(var t,n,r,i,o=0;o<e.length;){for(t=(i=it(e[o]).split("-")).length,n=(n=it(e[o+1]))?n.split("-"):null;t>0;){if(r=ot(i.slice(0,t).join("-")))return r;if(n&&n.length>=t&&rt(i,n)>=t-1)break;t--}o++}return Ze}(e)}function ct(e){var t,n=e._a;return n&&-2===m(e).overflow&&(t=n[1]<0||n[1]>11?1:n[2]<1||n[2]>_e(n[0],n[1])?2:n[3]<0||n[3]>24||24===n[3]&&(0!==n[4]||0!==n[5]||0!==n[6])?3:n[4]<0||n[4]>59?4:n[5]<0||n[5]>59?5:n[6]<0||n[6]>999?6:-1,m(e)._overflowDayOfYear&&(t<0||t>2)&&(t=2),m(e)._overflowWeeks&&-1===t&&(t=7),m(e)._overflowWeekday&&-1===t&&(t=8),m(e).overflow=t),e}var ut=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,pt=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,ft=/Z|[+-]\d\d(?::?\d\d)?/,dt=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],ht=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],mt=/^\/?Date\((-?\d+)/i,yt=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,bt={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function vt(e){var t,n,r,i,o,a,s=e._i,l=ut.exec(s)||pt.exec(s);if(l){for(m(e).iso=!0,t=0,n=dt.length;t<n;t++)if(dt[t][1].exec(l[1])){i=dt[t][0],r=!1!==dt[t][2];break}if(null==i)return void(e._isValid=!1);if(l[3]){for(t=0,n=ht.length;t<n;t++)if(ht[t][1].exec(l[3])){o=(l[2]||" ")+ht[t][0];break}if(null==o)return void(e._isValid=!1)}if(!r&&null!=o)return void(e._isValid=!1);if(l[4]){if(!ft.exec(l[4]))return void(e._isValid=!1);a="Z"}e._f=i+(o||"")+(a||""),kt(e)}else e._isValid=!1}function gt(e){var t=parseInt(e,10);return t<=49?2e3+t:t<=999?1900+t:t}function wt(e){var t,n,r,i,o,a,s,l,c=yt.exec(e._i.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,""));if(c){if(n=c[4],r=c[3],i=c[2],o=c[5],a=c[6],s=c[7],l=[gt(n),Se.indexOf(r),parseInt(i,10),parseInt(o,10),parseInt(a,10)],s&&l.push(parseInt(s,10)),t=l,!function(e,t,n){return!e||ze.indexOf(e)===new Date(t[0],t[1],t[2]).getDay()||(m(n).weekdayMismatch=!0,n._isValid=!1,!1)}(c[1],t,e))return;e._a=t,e._tzm=function(e,t,n){if(e)return bt[e];if(t)return 0;var r=parseInt(n,10),i=r%100;return 60*((r-i)/100)+i}(c[8],c[9],c[10]),e._d=Ie.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),m(e).rfc2822=!0}else e._isValid=!1}function Ct(e,t,n){return null!=e?e:null!=t?t:n}function _t(e){var t,n,r,o,a,s=[];if(!e._d){for(r=function(e){var t=new Date(i.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}(e),e._w&&null==e._a[2]&&null==e._a[1]&&function(e){var t,n,r,i,o,a,s,l,c;null!=(t=e._w).GG||null!=t.W||null!=t.E?(o=1,a=4,n=Ct(t.GG,e._a[0],Fe(Tt(),1,4).year),r=Ct(t.W,1),((i=Ct(t.E,1))<1||i>7)&&(l=!0)):(o=e._locale._week.dow,a=e._locale._week.doy,c=Fe(Tt(),o,a),n=Ct(t.gg,e._a[0],c.year),r=Ct(t.w,c.week),null!=t.d?((i=t.d)<0||i>6)&&(l=!0):null!=t.e?(i=t.e+o,(t.e<0||t.e>6)&&(l=!0)):i=o);r<1||r>Ue(n,o,a)?m(e)._overflowWeeks=!0:null!=l?m(e)._overflowWeekday=!0:(s=Le(n,r,i,o,a),e._a[0]=s.year,e._dayOfYear=s.dayOfYear)}(e),null!=e._dayOfYear&&(a=Ct(e._a[0],r[0]),(e._dayOfYear>je(a)||0===e._dayOfYear)&&(m(e)._overflowDayOfYear=!0),n=Ie(a,0,e._dayOfYear),e._a[1]=n.getUTCMonth(),e._a[2]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=s[t]=r[t];for(;t<7;t++)e._a[t]=s[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[3]&&0===e._a[4]&&0===e._a[5]&&0===e._a[6]&&(e._nextDay=!0,e._a[3]=0),e._d=(e._useUTC?Ie:Ae).apply(null,s),o=e._useUTC?e._d.getUTCDay():e._d.getDay(),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[3]=24),e._w&&void 0!==e._w.d&&e._w.d!==o&&(m(e).weekdayMismatch=!0)}}function kt(e){if(e._f!==i.ISO_8601)if(e._f!==i.RFC_2822){e._a=[],m(e).empty=!0;var t,n,r,o,a,s,l=""+e._i,c=l.length,u=0;for(r=F(e._f,e._locale).match(j)||[],t=0;t<r.length;t++)o=r[t],(n=(l.match(me(o,e))||[])[0])&&((a=l.substr(0,l.indexOf(n))).length>0&&m(e).unusedInput.push(a),l=l.slice(l.indexOf(n)+n.length),u+=n.length),I[o]?(n?m(e).empty=!1:m(e).unusedTokens.push(o),we(o,n,e)):e._strict&&!n&&m(e).unusedTokens.push(o);m(e).charsLeftOver=c-u,l.length>0&&m(e).unusedInput.push(l),e._a[3]<=12&&!0===m(e).bigHour&&e._a[3]>0&&(m(e).bigHour=void 0),m(e).parsedDateParts=e._a.slice(0),m(e).meridiem=e._meridiem,e._a[3]=function(e,t,n){var r;if(null==n)return t;return null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?((r=e.isPM(n))&&t<12&&(t+=12),r||12!==t||(t=0),t):t}(e._locale,e._a[3],e._meridiem),null!==(s=m(e).era)&&(e._a[0]=e._locale.erasConvertYear(s,e._a[0])),_t(e),ct(e)}else wt(e);else vt(e)}function St(e){var t=e._i,n=e._f;return e._locale=e._locale||lt(e._l),null===t||void 0===n&&""===t?b({nullInput:!0}):("string"==typeof t&&(e._i=t=e._locale.preparse(t)),_(t)?new C(ct(t)):(p(t)?e._d=t:o(n)?function(e){var t,n,r,i,o,a,s=!1;if(0===e._f.length)return m(e).invalidFormat=!0,void(e._d=new Date(NaN));for(i=0;i<e._f.length;i++)o=0,a=!1,t=w({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._f=e._f[i],kt(t),y(t)&&(a=!0),o+=m(t).charsLeftOver,o+=10*m(t).unusedTokens.length,m(t).score=o,s?o<r&&(r=o,n=t):(null==r||o<r||a)&&(r=o,n=t,a&&(s=!0));d(e,n||t)}(e):n?kt(e):function(e){var t=e._i;c(t)?e._d=new Date(i.now()):p(t)?e._d=new Date(t.valueOf()):"string"==typeof t?function(e){var t=mt.exec(e._i);null===t?(vt(e),!1===e._isValid&&(delete e._isValid,wt(e),!1===e._isValid&&(delete e._isValid,e._strict?e._isValid=!1:i.createFromInputFallback(e)))):e._d=new Date(+t[1])}(e):o(t)?(e._a=f(t.slice(0),(function(e){return parseInt(e,10)})),_t(e)):a(t)?function(e){if(!e._d){var t=z(e._i),n=void 0===t.day?t.date:t.day;e._a=f([t.year,t.month,n,t.hour,t.minute,t.second,t.millisecond],(function(e){return e&&parseInt(e,10)})),_t(e)}}(e):u(t)?e._d=new Date(t):i.createFromInputFallback(e)}(e),y(e)||(e._d=null),e))}function Et(e,t,n,r,i){var s,c={};return!0!==t&&!1!==t||(r=t,t=void 0),!0!==n&&!1!==n||(r=n,n=void 0),(a(e)&&l(e)||o(e)&&0===e.length)&&(e=void 0),c._isAMomentObject=!0,c._useUTC=c._isUTC=i,c._l=n,c._i=e,c._f=t,c._strict=r,(s=new C(ct(St(c))))._nextDay&&(s.add(1,"d"),s._nextDay=void 0),s}function Tt(e,t,n,r){return Et(e,t,n,r,!1)}i.createFromInputFallback=S("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",(function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))})),i.ISO_8601=function(){},i.RFC_2822=function(){};var Ot=S("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var e=Tt.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:b()})),Pt=S("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var e=Tt.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:b()}));function Rt(e,t){var n,r;if(1===t.length&&o(t[0])&&(t=t[0]),!t.length)return Tt();for(n=t[0],r=1;r<t.length;++r)t[r].isValid()&&!t[r][e](n)||(n=t[r]);return n}var xt=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Dt(e){var t=z(e),n=t.year||0,r=t.quarter||0,i=t.month||0,o=t.week||t.isoWeek||0,a=t.day||0,l=t.hour||0,c=t.minute||0,u=t.second||0,p=t.millisecond||0;this._isValid=function(e){var t,n,r=!1;for(t in e)if(s(e,t)&&(-1===Ce.call(xt,t)||null!=e[t]&&isNaN(e[t])))return!1;for(n=0;n<xt.length;++n)if(e[xt[n]]){if(r)return!1;parseFloat(e[xt[n]])!==X(e[xt[n]])&&(r=!0)}return!0}(t),this._milliseconds=+p+1e3*u+6e4*c+1e3*l*60*60,this._days=+a+7*o,this._months=+i+3*r+12*n,this._data={},this._locale=lt(),this._bubble()}function jt(e){return e instanceof Dt}function Mt(e){return e<0?-1*Math.round(-1*e):Math.round(e)}function At(e,t){N(e,0,0,(function(){var e=this.utcOffset(),n="+";return e<0&&(e=-e,n="-"),n+D(~~(e/60),2)+t+D(~~e%60,2)}))}At("Z",":"),At("ZZ",""),he("Z",fe),he("ZZ",fe),ve(["Z","ZZ"],(function(e,t,n){n._useUTC=!0,n._tzm=Nt(fe,e)}));var It=/([\+\-]|\d\d)/gi;function Nt(e,t){var n,r,i=(t||"").match(e);return null===i?null:0===(r=60*(n=((i[i.length-1]||[])+"").match(It)||["-",0,0])[1]+X(n[2]))?0:"+"===n[0]?r:-r}function Lt(e,t){var n,r;return t._isUTC?(n=t.clone(),r=(_(e)||p(e)?e.valueOf():Tt(e).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+r),i.updateOffset(n,!1),n):Tt(e).local()}function Ft(e){return-Math.round(e._d.getTimezoneOffset())}function Ut(){return!!this.isValid()&&(this._isUTC&&0===this._offset)}i.updateOffset=function(){};var qt=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,Bt=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function zt(e,t){var n,r,i,o=e,a=null;return jt(e)?o={ms:e._milliseconds,d:e._days,M:e._months}:u(e)||!isNaN(+e)?(o={},t?o[t]=+e:o.milliseconds=+e):(a=qt.exec(e))?(n="-"===a[1]?-1:1,o={y:0,d:X(a[2])*n,h:X(a[3])*n,m:X(a[4])*n,s:X(a[5])*n,ms:X(Mt(1e3*a[6]))*n}):(a=Bt.exec(e))?(n="-"===a[1]?-1:1,o={y:Vt(a[2],n),M:Vt(a[3],n),w:Vt(a[4],n),d:Vt(a[5],n),h:Vt(a[6],n),m:Vt(a[7],n),s:Vt(a[8],n)}):null==o?o={}:"object"==typeof o&&("from"in o||"to"in o)&&(i=function(e,t){var n;if(!e.isValid()||!t.isValid())return{milliseconds:0,months:0};t=Lt(t,e),e.isBefore(t)?n=Wt(e,t):((n=Wt(t,e)).milliseconds=-n.milliseconds,n.months=-n.months);return n}(Tt(o.from),Tt(o.to)),(o={}).ms=i.milliseconds,o.M=i.months),r=new Dt(o),jt(e)&&s(e,"_locale")&&(r._locale=e._locale),jt(e)&&s(e,"_isValid")&&(r._isValid=e._isValid),r}function Vt(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function Wt(e,t){var n={};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function Ht(e,t){return function(n,r){var i;return null===r||isNaN(+r)||(O(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),i=n,n=r,r=i),Yt(this,zt(n,r),e),this}}function Yt(e,t,n,r){var o=t._milliseconds,a=Mt(t._days),s=Mt(t._months);e.isValid()&&(r=null==r||r,s&&Re(e,$(e,"Month")+s*n),a&&Q(e,"Date",$(e,"Date")+a*n),o&&e._d.setTime(e._d.valueOf()+o*n),r&&i.updateOffset(e,a||s))}zt.fn=Dt.prototype,zt.invalid=function(){return zt(NaN)};var Xt=Ht(1,"add"),Gt=Ht(-1,"subtract");function $t(e){return"string"==typeof e||e instanceof String}function Qt(e){return _(e)||p(e)||$t(e)||u(e)||function(e){var t=o(e),n=!1;t&&(n=0===e.filter((function(t){return!u(t)&&$t(e)})).length);return t&&n}(e)||function(e){var t,n,r=a(e)&&!l(e),i=!1,o=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"];for(t=0;t<o.length;t+=1)n=o[t],i=i||s(e,n);return r&&i}(e)||null==e}function Kt(e){var t,n=a(e)&&!l(e),r=!1,i=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"];for(t=0;t<i.length;t+=1)r=r||s(e,i[t]);return n&&r}function Jt(e,t){if(e.date()<t.date())return-Jt(t,e);var n=12*(t.year()-e.year())+(t.month()-e.month()),r=e.clone().add(n,"months");return-(n+(t-r<0?(t-r)/(r-e.clone().add(n-1,"months")):(t-r)/(e.clone().add(n+1,"months")-r)))||0}function Zt(e){var t;return void 0===e?this._locale._abbr:(null!=(t=lt(e))&&(this._locale=t),this)}i.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",i.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var en=S("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",(function(e){return void 0===e?this.localeData():this.locale(e)}));function tn(){return this._locale}function nn(e,t){return(e%t+t)%t}function rn(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-126227808e5:new Date(e,t,n).valueOf()}function on(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-126227808e5:Date.UTC(e,t,n)}function an(e,t){return t.erasAbbrRegex(e)}function sn(){var e,t,n=[],r=[],i=[],o=[],a=this.eras();for(e=0,t=a.length;e<t;++e)r.push(ye(a[e].name)),n.push(ye(a[e].abbr)),i.push(ye(a[e].narrow)),o.push(ye(a[e].name)),o.push(ye(a[e].abbr)),o.push(ye(a[e].narrow));this._erasRegex=new RegExp("^("+o.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+r.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+n.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+i.join("|")+")","i")}function ln(e,t){N(0,[e,e.length],0,t)}function cn(e,t,n,r,i){var o;return null==e?Fe(this,r,i).year:(t>(o=Ue(e,r,i))&&(t=o),un.call(this,e,t,n,r,i))}function un(e,t,n,r,i){var o=Le(e,t,n,r,i),a=Ie(o.year,0,o.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}N("N",0,0,"eraAbbr"),N("NN",0,0,"eraAbbr"),N("NNN",0,0,"eraAbbr"),N("NNNN",0,0,"eraName"),N("NNNNN",0,0,"eraNarrow"),N("y",["y",1],"yo","eraYear"),N("y",["yy",2],0,"eraYear"),N("y",["yyy",3],0,"eraYear"),N("y",["yyyy",4],0,"eraYear"),he("N",an),he("NN",an),he("NNN",an),he("NNNN",(function(e,t){return t.erasNameRegex(e)})),he("NNNNN",(function(e,t){return t.erasNarrowRegex(e)})),ve(["N","NN","NNN","NNNN","NNNNN"],(function(e,t,n,r){var i=n._locale.erasParse(e,r,n._strict);i?m(n).era=i:m(n).invalidEra=e})),he("y",ce),he("yy",ce),he("yyy",ce),he("yyyy",ce),he("yo",(function(e,t){return t._eraYearOrdinalRegex||ce})),ve(["y","yy","yyy","yyyy"],0),ve(["yo"],(function(e,t,n,r){var i;n._locale._eraYearOrdinalRegex&&(i=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[0]=n._locale.eraYearOrdinalParse(e,i):t[0]=parseInt(e,10)})),N(0,["gg",2],0,(function(){return this.weekYear()%100})),N(0,["GG",2],0,(function(){return this.isoWeekYear()%100})),ln("gggg","weekYear"),ln("ggggg","weekYear"),ln("GGGG","isoWeekYear"),ln("GGGGG","isoWeekYear"),q("weekYear","gg"),q("isoWeekYear","GG"),W("weekYear",1),W("isoWeekYear",1),he("G",ue),he("g",ue),he("GG",re,Z),he("gg",re,Z),he("GGGG",se,te),he("gggg",se,te),he("GGGGG",le,ne),he("ggggg",le,ne),ge(["gggg","ggggg","GGGG","GGGGG"],(function(e,t,n,r){t[r.substr(0,2)]=X(e)})),ge(["gg","GG"],(function(e,t,n,r){t[r]=i.parseTwoDigitYear(e)})),N("Q",0,"Qo","quarter"),q("quarter","Q"),W("quarter",7),he("Q",J),ve("Q",(function(e,t){t[1]=3*(X(e)-1)})),N("D",["DD",2],"Do","date"),q("date","D"),W("date",9),he("D",re),he("DD",re,Z),he("Do",(function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient})),ve(["D","DD"],2),ve("Do",(function(e,t){t[2]=X(e.match(re)[0])}));var pn=G("Date",!0);N("DDD",["DDDD",3],"DDDo","dayOfYear"),q("dayOfYear","DDD"),W("dayOfYear",4),he("DDD",ae),he("DDDD",ee),ve(["DDD","DDDD"],(function(e,t,n){n._dayOfYear=X(e)})),N("m",["mm",2],0,"minute"),q("minute","m"),W("minute",14),he("m",re),he("mm",re,Z),ve(["m","mm"],4);var fn=G("Minutes",!1);N("s",["ss",2],0,"second"),q("second","s"),W("second",15),he("s",re),he("ss",re,Z),ve(["s","ss"],5);var dn,hn,mn=G("Seconds",!1);for(N("S",0,0,(function(){return~~(this.millisecond()/100)})),N(0,["SS",2],0,(function(){return~~(this.millisecond()/10)})),N(0,["SSS",3],0,"millisecond"),N(0,["SSSS",4],0,(function(){return 10*this.millisecond()})),N(0,["SSSSS",5],0,(function(){return 100*this.millisecond()})),N(0,["SSSSSS",6],0,(function(){return 1e3*this.millisecond()})),N(0,["SSSSSSS",7],0,(function(){return 1e4*this.millisecond()})),N(0,["SSSSSSSS",8],0,(function(){return 1e5*this.millisecond()})),N(0,["SSSSSSSSS",9],0,(function(){return 1e6*this.millisecond()})),q("millisecond","ms"),W("millisecond",16),he("S",ae,J),he("SS",ae,Z),he("SSS",ae,ee),dn="SSSS";dn.length<=9;dn+="S")he(dn,ce);function yn(e,t){t[6]=X(1e3*("0."+e))}for(dn="S";dn.length<=9;dn+="S")ve(dn,yn);hn=G("Milliseconds",!1),N("z",0,0,"zoneAbbr"),N("zz",0,0,"zoneName");var bn=C.prototype;function vn(e){return e}bn.add=Xt,bn.calendar=function(e,t){1===arguments.length&&(arguments[0]?Qt(arguments[0])?(e=arguments[0],t=void 0):Kt(arguments[0])&&(t=arguments[0],e=void 0):(e=void 0,t=void 0));var n=e||Tt(),r=Lt(n,this).startOf("day"),o=i.calendarFormat(this,r)||"sameElse",a=t&&(P(t[o])?t[o].call(this,n):t[o]);return this.format(a||this.localeData().calendar(o,this,Tt(n)))},bn.clone=function(){return new C(this)},bn.diff=function(e,t,n){var r,i,o;if(!this.isValid())return NaN;if(!(r=Lt(e,this)).isValid())return NaN;switch(i=6e4*(r.utcOffset()-this.utcOffset()),t=B(t)){case"year":o=Jt(this,r)/12;break;case"month":o=Jt(this,r);break;case"quarter":o=Jt(this,r)/3;break;case"second":o=(this-r)/1e3;break;case"minute":o=(this-r)/6e4;break;case"hour":o=(this-r)/36e5;break;case"day":o=(this-r-i)/864e5;break;case"week":o=(this-r-i)/6048e5;break;default:o=this-r}return n?o:Y(o)},bn.endOf=function(e){var t,n;if(void 0===(e=B(e))||"millisecond"===e||!this.isValid())return this;switch(n=this._isUTC?on:rn,e){case"year":t=n(this.year()+1,0,1)-1;break;case"quarter":t=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=n(this.year(),this.month()+1,1)-1;break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=36e5-nn(t+(this._isUTC?0:6e4*this.utcOffset()),36e5)-1;break;case"minute":t=this._d.valueOf(),t+=6e4-nn(t,6e4)-1;break;case"second":t=this._d.valueOf(),t+=1e3-nn(t,1e3)-1}return this._d.setTime(t),i.updateOffset(this,!0),this},bn.format=function(e){e||(e=this.isUtc()?i.defaultFormatUtc:i.defaultFormat);var t=L(this,e);return this.localeData().postformat(t)},bn.from=function(e,t){return this.isValid()&&(_(e)&&e.isValid()||Tt(e).isValid())?zt({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},bn.fromNow=function(e){return this.from(Tt(),e)},bn.to=function(e,t){return this.isValid()&&(_(e)&&e.isValid()||Tt(e).isValid())?zt({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},bn.toNow=function(e){return this.to(Tt(),e)},bn.get=function(e){return P(this[e=B(e)])?this[e]():this},bn.invalidAt=function(){return m(this).overflow},bn.isAfter=function(e,t){var n=_(e)?e:Tt(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=B(t)||"millisecond")?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf())},bn.isBefore=function(e,t){var n=_(e)?e:Tt(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=B(t)||"millisecond")?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf())},bn.isBetween=function(e,t,n,r){var i=_(e)?e:Tt(e),o=_(t)?t:Tt(t);return!!(this.isValid()&&i.isValid()&&o.isValid())&&(("("===(r=r||"()")[0]?this.isAfter(i,n):!this.isBefore(i,n))&&(")"===r[1]?this.isBefore(o,n):!this.isAfter(o,n)))},bn.isSame=function(e,t){var n,r=_(e)?e:Tt(e);return!(!this.isValid()||!r.isValid())&&("millisecond"===(t=B(t)||"millisecond")?this.valueOf()===r.valueOf():(n=r.valueOf(),this.clone().startOf(t).valueOf()<=n&&n<=this.clone().endOf(t).valueOf()))},bn.isSameOrAfter=function(e,t){return this.isSame(e,t)||this.isAfter(e,t)},bn.isSameOrBefore=function(e,t){return this.isSame(e,t)||this.isBefore(e,t)},bn.isValid=function(){return y(this)},bn.lang=en,bn.locale=Zt,bn.localeData=tn,bn.max=Pt,bn.min=Ot,bn.parsingFlags=function(){return d({},m(this))},bn.set=function(e,t){if("object"==typeof e){var n,r=function(e){var t,n=[];for(t in e)s(e,t)&&n.push({unit:t,priority:V[t]});return n.sort((function(e,t){return e.priority-t.priority})),n}(e=z(e));for(n=0;n<r.length;n++)this[r[n].unit](e[r[n].unit])}else if(P(this[e=B(e)]))return this[e](t);return this},bn.startOf=function(e){var t,n;if(void 0===(e=B(e))||"millisecond"===e||!this.isValid())return this;switch(n=this._isUTC?on:rn,e){case"year":t=n(this.year(),0,1);break;case"quarter":t=n(this.year(),this.month()-this.month()%3,1);break;case"month":t=n(this.year(),this.month(),1);break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":t=n(this.year(),this.month(),this.date());break;case"hour":t=this._d.valueOf(),t-=nn(t+(this._isUTC?0:6e4*this.utcOffset()),36e5);break;case"minute":t=this._d.valueOf(),t-=nn(t,6e4);break;case"second":t=this._d.valueOf(),t-=nn(t,1e3)}return this._d.setTime(t),i.updateOffset(this,!0),this},bn.subtract=Gt,bn.toArray=function(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]},bn.toObject=function(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}},bn.toDate=function(){return new Date(this.valueOf())},bn.toISOString=function(e){if(!this.isValid())return null;var t=!0!==e,n=t?this.clone().utc():this;return n.year()<0||n.year()>9999?L(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):P(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",L(n,"Z")):L(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},bn.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e,t,n,r="moment",i="";return this.isLocal()||(r=0===this.utcOffset()?"moment.utc":"moment.parseZone",i="Z"),e="["+r+'("]',t=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY","-MM-DD[T]HH:mm:ss.SSS",n=i+'[")]',this.format(e+t+"-MM-DD[T]HH:mm:ss.SSS"+n)},"undefined"!=typeof Symbol&&null!=Symbol.for&&(bn[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),bn.toJSON=function(){return this.isValid()?this.toISOString():null},bn.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},bn.unix=function(){return Math.floor(this.valueOf()/1e3)},bn.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},bn.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},bn.eraName=function(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),r[e].since<=n&&n<=r[e].until)return r[e].name;if(r[e].until<=n&&n<=r[e].since)return r[e].name}return""},bn.eraNarrow=function(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),r[e].since<=n&&n<=r[e].until)return r[e].narrow;if(r[e].until<=n&&n<=r[e].since)return r[e].narrow}return""},bn.eraAbbr=function(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),r[e].since<=n&&n<=r[e].until)return r[e].abbr;if(r[e].until<=n&&n<=r[e].since)return r[e].abbr}return""},bn.eraYear=function(){var e,t,n,r,o=this.localeData().eras();for(e=0,t=o.length;e<t;++e)if(n=o[e].since<=o[e].until?1:-1,r=this.clone().startOf("day").valueOf(),o[e].since<=r&&r<=o[e].until||o[e].until<=r&&r<=o[e].since)return(this.year()-i(o[e].since).year())*n+o[e].offset;return this.year()},bn.year=Me,bn.isLeapYear=function(){return H(this.year())},bn.weekYear=function(e){return cn.call(this,e,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)},bn.isoWeekYear=function(e){return cn.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)},bn.quarter=bn.quarters=function(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)},bn.month=xe,bn.daysInMonth=function(){return _e(this.year(),this.month())},bn.week=bn.weeks=function(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")},bn.isoWeek=bn.isoWeeks=function(e){var t=Fe(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")},bn.weeksInYear=function(){var e=this.localeData()._week;return Ue(this.year(),e.dow,e.doy)},bn.weeksInWeekYear=function(){var e=this.localeData()._week;return Ue(this.weekYear(),e.dow,e.doy)},bn.isoWeeksInYear=function(){return Ue(this.year(),1,4)},bn.isoWeeksInISOWeekYear=function(){return Ue(this.isoWeekYear(),1,4)},bn.date=pn,bn.day=bn.days=function(e){if(!this.isValid())return null!=e?this:NaN;var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=e?(e=function(e,t){return"string"!=typeof e?e:isNaN(e)?"number"==typeof(e=t.weekdaysParse(e))?e:null:parseInt(e,10)}(e,this.localeData()),this.add(e-t,"d")):t},bn.weekday=function(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")},bn.isoWeekday=function(e){if(!this.isValid())return null!=e?this:NaN;if(null!=e){var t=function(e,t){return"string"==typeof e?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}(e,this.localeData());return this.day(this.day()%7?t:t-7)}return this.day()||7},bn.dayOfYear=function(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")},bn.hour=bn.hours=Je,bn.minute=bn.minutes=fn,bn.second=bn.seconds=mn,bn.millisecond=bn.milliseconds=hn,bn.utcOffset=function(e,t,n){var r,o=this._offset||0;if(!this.isValid())return null!=e?this:NaN;if(null!=e){if("string"==typeof e){if(null===(e=Nt(fe,e)))return this}else Math.abs(e)<16&&!n&&(e*=60);return!this._isUTC&&t&&(r=Ft(this)),this._offset=e,this._isUTC=!0,null!=r&&this.add(r,"m"),o!==e&&(!t||this._changeInProgress?Yt(this,zt(e-o,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,i.updateOffset(this,!0),this._changeInProgress=null)),this}return this._isUTC?o:Ft(this)},bn.utc=function(e){return this.utcOffset(0,e)},bn.local=function(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(Ft(this),"m")),this},bn.parseZone=function(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var e=Nt(pe,this._i);null!=e?this.utcOffset(e):this.utcOffset(0,!0)}return this},bn.hasAlignedHourOffset=function(e){return!!this.isValid()&&(e=e?Tt(e).utcOffset():0,(this.utcOffset()-e)%60==0)},bn.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},bn.isLocal=function(){return!!this.isValid()&&!this._isUTC},bn.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},bn.isUtc=Ut,bn.isUTC=Ut,bn.zoneAbbr=function(){return this._isUTC?"UTC":""},bn.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},bn.dates=S("dates accessor is deprecated. Use date instead.",pn),bn.months=S("months accessor is deprecated. Use month instead",xe),bn.years=S("years accessor is deprecated. Use year instead",Me),bn.zone=S("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",(function(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()})),bn.isDSTShifted=S("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",(function(){if(!c(this._isDSTShifted))return this._isDSTShifted;var e,t={};return w(t,this),(t=St(t))._a?(e=t._isUTC?h(t._a):Tt(t._a),this._isDSTShifted=this.isValid()&&function(e,t,n){var r,i=Math.min(e.length,t.length),o=Math.abs(e.length-t.length),a=0;for(r=0;r<i;r++)(n&&e[r]!==t[r]||!n&&X(e[r])!==X(t[r]))&&a++;return a+o}(t._a,e.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}));var gn=x.prototype;function wn(e,t,n,r){var i=lt(),o=h().set(r,t);return i[n](o,e)}function Cn(e,t,n){if(u(e)&&(t=e,e=void 0),e=e||"",null!=t)return wn(e,t,n,"month");var r,i=[];for(r=0;r<12;r++)i[r]=wn(e,r,n,"month");return i}function _n(e,t,n,r){"boolean"==typeof e?(u(t)&&(n=t,t=void 0),t=t||""):(n=t=e,e=!1,u(t)&&(n=t,t=void 0),t=t||"");var i,o=lt(),a=e?o._week.dow:0,s=[];if(null!=n)return wn(t,(n+a)%7,r,"day");for(i=0;i<7;i++)s[i]=wn(t,(i+a)%7,r,"day");return s}gn.calendar=function(e,t,n){var r=this._calendar[e]||this._calendar.sameElse;return P(r)?r.call(t,n):r},gn.longDateFormat=function(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(j).map((function(e){return"MMMM"===e||"MM"===e||"DD"===e||"dddd"===e?e.slice(1):e})).join(""),this._longDateFormat[e])},gn.invalidDate=function(){return this._invalidDate},gn.ordinal=function(e){return this._ordinal.replace("%d",e)},gn.preparse=vn,gn.postformat=vn,gn.relativeTime=function(e,t,n,r){var i=this._relativeTime[n];return P(i)?i(e,t,n,r):i.replace(/%d/i,e)},gn.pastFuture=function(e,t){var n=this._relativeTime[e>0?"future":"past"];return P(n)?n(t):n.replace(/%s/i,t)},gn.set=function(e){var t,n;for(n in e)s(e,n)&&(P(t=e[n])?this[n]=t:this["_"+n]=t);this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},gn.eras=function(e,t){var n,r,o,a=this._eras||lt("en")._eras;for(n=0,r=a.length;n<r;++n){switch(typeof a[n].since){case"string":o=i(a[n].since).startOf("day"),a[n].since=o.valueOf()}switch(typeof a[n].until){case"undefined":a[n].until=1/0;break;case"string":o=i(a[n].until).startOf("day").valueOf(),a[n].until=o.valueOf()}}return a},gn.erasParse=function(e,t,n){var r,i,o,a,s,l=this.eras();for(e=e.toUpperCase(),r=0,i=l.length;r<i;++r)if(o=l[r].name.toUpperCase(),a=l[r].abbr.toUpperCase(),s=l[r].narrow.toUpperCase(),n)switch(t){case"N":case"NN":case"NNN":if(a===e)return l[r];break;case"NNNN":if(o===e)return l[r];break;case"NNNNN":if(s===e)return l[r]}else if([o,a,s].indexOf(e)>=0)return l[r]},gn.erasConvertYear=function(e,t){var n=e.since<=e.until?1:-1;return void 0===t?i(e.since).year():i(e.since).year()+(t-e.offset)*n},gn.erasAbbrRegex=function(e){return s(this,"_erasAbbrRegex")||sn.call(this),e?this._erasAbbrRegex:this._erasRegex},gn.erasNameRegex=function(e){return s(this,"_erasNameRegex")||sn.call(this),e?this._erasNameRegex:this._erasRegex},gn.erasNarrowRegex=function(e){return s(this,"_erasNarrowRegex")||sn.call(this),e?this._erasNarrowRegex:this._erasRegex},gn.months=function(e,t){return e?o(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||Ee).test(t)?"format":"standalone"][e.month()]:o(this._months)?this._months:this._months.standalone},gn.monthsShort=function(e,t){return e?o(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[Ee.test(t)?"format":"standalone"][e.month()]:o(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},gn.monthsParse=function(e,t,n){var r,i,o;if(this._monthsParseExact)return Pe.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++){if(i=h([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(o="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(o.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[r].test(e))return r;if(n&&"MMM"===t&&this._shortMonthsParse[r].test(e))return r;if(!n&&this._monthsParse[r].test(e))return r}},gn.monthsRegex=function(e){return this._monthsParseExact?(s(this,"_monthsRegex")||De.call(this),e?this._monthsStrictRegex:this._monthsRegex):(s(this,"_monthsRegex")||(this._monthsRegex=Oe),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)},gn.monthsShortRegex=function(e){return this._monthsParseExact?(s(this,"_monthsRegex")||De.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(s(this,"_monthsShortRegex")||(this._monthsShortRegex=Te),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)},gn.week=function(e){return Fe(e,this._week.dow,this._week.doy).week},gn.firstDayOfYear=function(){return this._week.doy},gn.firstDayOfWeek=function(){return this._week.dow},gn.weekdays=function(e,t){var n=o(this._weekdays)?this._weekdays:this._weekdays[e&&!0!==e&&this._weekdays.isFormat.test(t)?"format":"standalone"];return!0===e?qe(n,this._week.dow):e?n[e.day()]:n},gn.weekdaysMin=function(e){return!0===e?qe(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin},gn.weekdaysShort=function(e){return!0===e?qe(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort},gn.weekdaysParse=function(e,t,n){var r,i,o;if(this._weekdaysParseExact)return Xe.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;
vendor: 5,649 bytes, line 48
48r++){if(i=h([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(i,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(i,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(i,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[r]||(o="^"+this.weekdays(i,"")+"|^"+this.weekdaysShort(i,"")+"|^"+this.weekdaysMin(i,""),this._weekdaysParse[r]=new RegExp(o.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[r].test(e))return r;if(n&&"ddd"===t&&this._shortWeekdaysParse[r].test(e))return r;if(n&&"dd"===t&&this._minWeekdaysParse[r].test(e))return r;if(!n&&this._weekdaysParse[r].test(e))return r}},gn.weekdaysRegex=function(e){return this._weekdaysParseExact?(s(this,"_weekdaysRegex")||Ge.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(s(this,"_weekdaysRegex")||(this._weekdaysRegex=We),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)},gn.weekdaysShortRegex=function(e){return this._weekdaysParseExact?(s(this,"_weekdaysRegex")||Ge.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(s(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=He),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},gn.weekdaysMinRegex=function(e){return this._weekdaysParseExact?(s(this,"_weekdaysRegex")||Ge.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(s(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=Ye),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},gn.isPM=function(e){return"p"===(e+"").toLowerCase().charAt(0)},gn.meridiem=function(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"},at("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1===X(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}}),i.lang=S("moment.lang is deprecated. Use moment.locale instead.",at),i.langData=S("moment.langData is deprecated. Use moment.localeData instead.",lt);var kn=Math.abs;function Sn(e,t,n,r){var i=zt(t,n);return e._milliseconds+=r*i._milliseconds,e._days+=r*i._days,e._months+=r*i._months,e._bubble()}function En(e){return e<0?Math.floor(e):Math.ceil(e)}function Tn(e){return 4800*e/146097}function On(e){return 146097*e/4800}function Pn(e){return function(){return this.as(e)}}var Rn=Pn("ms"),xn=Pn("s"),Dn=Pn("m"),jn=Pn("h"),Mn=Pn("d"),An=Pn("w"),In=Pn("M"),Nn=Pn("Q"),Ln=Pn("y");function Fn(e){return function(){return this.isValid()?this._data[e]:NaN}}var Un=Fn("milliseconds"),qn=Fn("seconds"),Bn=Fn("minutes"),zn=Fn("hours"),Vn=Fn("days"),Wn=Fn("months"),Hn=Fn("years");var Yn=Math.round,Xn={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function Gn(e,t,n,r,i){return i.relativeTime(t||1,!!n,e,r)}var $n=Math.abs;function Qn(e){return(e>0)-(e<0)||+e}function Kn(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n,r,i,o,a,s,l=$n(this._milliseconds)/1e3,c=$n(this._days),u=$n(this._months),p=this.asSeconds();return p?(e=Y(l/60),t=Y(e/60),l%=60,e%=60,n=Y(u/12),u%=12,r=l?l.toFixed(3).replace(/\.?0+$/,""):"",i=p<0?"-":"",o=Qn(this._months)!==Qn(p)?"-":"",a=Qn(this._days)!==Qn(p)?"-":"",s=Qn(this._milliseconds)!==Qn(p)?"-":"",i+"P"+(n?o+n+"Y":"")+(u?o+u+"M":"")+(c?a+c+"D":"")+(t||e||l?"T":"")+(t?s+t+"H":"")+(e?s+e+"M":"")+(l?s+r+"S":"")):"P0D"}var Jn=Dt.prototype;return Jn.isValid=function(){return this._isValid},Jn.abs=function(){var e=this._data;return this._milliseconds=kn(this._milliseconds),this._days=kn(this._days),this._months=kn(this._months),e.milliseconds=kn(e.milliseconds),e.seconds=kn(e.seconds),e.minutes=kn(e.minutes),e.hours=kn(e.hours),e.months=kn(e.months),e.years=kn(e.years),this},Jn.add=function(e,t){return Sn(this,e,t,1)},Jn.subtract=function(e,t){return Sn(this,e,t,-1)},Jn.as=function(e){if(!this.isValid())return NaN;var t,n,r=this._milliseconds;if("month"===(e=B(e))||"quarter"===e||"year"===e)switch(t=this._days+r/864e5,n=this._months+Tn(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(On(this._months)),e){case"week":return t/7+r/6048e5;case"day":return t+r/864e5;case"hour":return 24*t+r/36e5;case"minute":return 1440*t+r/6e4;case"second":return 86400*t+r/1e3;case"millisecond":return Math.floor(864e5*t)+r;default:throw new Error("Unknown unit "+e)}},Jn.asMilliseconds=Rn,Jn.asSeconds=xn,Jn.asMinutes=Dn,Jn.asHours=jn,Jn.asDays=Mn,Jn.asWeeks=An,Jn.asMonths=In,Jn.asQuarters=Nn,Jn.asYears=Ln,Jn.valueOf=function(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*X(this._months/12):NaN},Jn._bubble=function(){var e,t,n,r,i,o=this._milliseconds,a=this._days,s=this._months,l=this._data;return o>=0&&a>=0&&s>=0||o<=0&&a<=0&&s<=0||(o+=864e5*En(On(s)+a),a=0,s=0),l.milliseconds=o%1e3,e=Y(o/1e3),l.seconds=e%60,t=Y(e/60),l.minutes=t%60,n=Y(t/60),l.hours=n%24,a+=Y(n/24),s+=i=Y(Tn(a)),a-=En(On(i)),r=Y(s/12),s%=12,l.days=a,l.months=s,l.years=r,this},Jn.clone=function(){return zt(this)},Jn.get=function(e){return e=B(e),this.isValid()?this[e+"s"]():NaN},Jn.milliseconds=Un,Jn.seconds=qn,Jn.minutes=Bn,Jn.hours=zn,Jn.days=Vn,Jn.weeks=function(){return Y(this.days()/7)},Jn.months=Wn,Jn.years=Hn,Jn.humanize=function(e,t){if(!this.isValid())return this.localeData().invalidDate();var n,r,i=!1,o=Xn;return"object"==typeof e&&(t=e,e=!1),"boolean"==typeof e&&(i=e),"object"==typeof t&&(o=Object.assign({}
vendor: 2,823 bytes, lines 48-54
48,Xn,t),null!=t.s&&null==t.ss&&(o.ss=t.s-1)),r=function(e,t,n,r){var i=zt(e).abs(),o=Yn(i.as("s")),a=Yn(i.as("m")),s=Yn(i.as("h")),l=Yn(i.as("d")),c=Yn(i.as("M")),u=Yn(i.as("w")),p=Yn(i.as("y")),f=o<=n.ss&&["s",o]||o<n.s&&["ss",o]||a<=1&&["m"]||a<n.m&&["mm",a]||s<=1&&["h"]||s<n.h&&["hh",s]||l<=1&&["d"]||l<n.d&&["dd",l];return null!=n.w&&(f=f||u<=1&&["w"]||u<n.w&&["ww",u]),(f=f||c<=1&&["M"]||c<n.M&&["MM",c]||p<=1&&["y"]||["yy",p])[2]=t,f[3]=+e>0,f[4]=r,Gn.apply(null,f)}(this,!i,o,n=this.localeData()),i&&(r=n.pastFuture(+this,r)),n.postformat(r)},Jn.toISOString=Kn,Jn.toString=Kn,Jn.toJSON=Kn,Jn.locale=Zt,Jn.localeData=tn,Jn.toIsoString=S("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Kn),Jn.lang=en,N("X",0,0,"unix"),N("x",0,0,"valueOf"),he("x",ue),he("X",/[+-]?\d+(\.\d{1,3})?/),ve("X",(function(e,t,n){n._d=new Date(1e3*parseFloat(e))})),ve("x",(function(e,t,n){n._d=new Date(X(e))})),
49//! moment.js
50i.version="2.29.1",n=Tt,i.fn=bn,i.min=function(){var e=[].slice.call(arguments,0);return Rt("isBefore",e)},i.max=function(){var e=[].slice.call(arguments,0);return Rt("isAfter",e)},i.now=function(){return Date.now?Date.now():+new Date},i.utc=h,i.unix=function(e){return Tt(1e3*e)},i.months=function(e,t){return Cn(e,t,"months")},i.isDate=p,i.locale=at,i.invalid=b,i.duration=zt,i.isMoment=_,i.weekdays=function(e,t,n){return _n(e,t,n,"weekdays")},i.parseZone=function(){return Tt.apply(null,arguments).parseZone()},i.localeData=lt,i.isDuration=jt,i.monthsShort=function(e,t){return Cn(e,t,"monthsShort")},i.weekdaysMin=function(e,t,n){return _n(e,t,n,"weekdaysMin")},i.defineLocale=st,i.updateLocale=function(e,t){if(null!=t){var n,r,i=et;null!=tt[e]&&null!=tt[e].parentLocale?tt[e].set(R(tt[e]._config,t)):(null!=(r=ot(e))&&(i=r._config),t=R(i,t),null==r&&(t.abbr=e),(n=new x(t)).parentLocale=tt[e],tt[e]=n),at(e)}else null!=tt[e]&&(null!=tt[e].parentLocale?(tt[e]=tt[e].parentLocale,e===at()&&at(e)):null!=tt[e]&&delete tt[e]);return tt[e]},i.locales=function(){return E(tt)},i.weekdaysShort=function(e,t,n){return _n(e,t,n,"weekdaysShort")},i.normalizeUnits=B,i.relativeTimeRounding=function(e){return void 0===e?Yn:"function"==typeof e&&(Yn=e,!0)},i.relativeTimeThreshold=function(e,t){return void 0!==Xn[e]&&(void 0===t?Xn[e]:(Xn[e]=t,"s"===e&&(Xn.ss=t-1),!0))},i.calendarFormat=function(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"},i.prototype=bn,i.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},i}))},{}],247:[function(e,t,n){
51/*
52object-assign
53(c) Sindre Sorhus
54@license MIT
vendor: 8,578 bytes, lines 55-56
55*/
56"use strict";var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function a(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}t.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,s,l=a(e),c=1;c<arguments.length;c++){for(var u in n=Object(arguments[c]))i.call(n,u)&&(l[u]=n[u]);if(r){s=r(n);for(var p=0;p<s.length;p++)o.call(n,s[p])&&(l[s[p]]=n[s[p]])}}return l}},{}],248:[function(e,t,n){var r="function"==typeof Map&&Map.prototype,i=Object.getOwnPropertyDescriptor&&r?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,o=r&&i&&"function"==typeof i.get?i.get:null,a=r&&Map.prototype.forEach,s="function"==typeof Set&&Set.prototype,l=Object.getOwnPropertyDescriptor&&s?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,c=s&&l&&"function"==typeof l.get?l.get:null,u=s&&Set.prototype.forEach,p="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,f="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,d="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,h=Boolean.prototype.valueOf,m=Object.prototype.toString,y=Function.prototype.toString,b=String.prototype.match,v="function"==typeof BigInt?BigInt.prototype.valueOf:null,g=Object.getOwnPropertySymbols,w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,C="function"==typeof Symbol&&"object"==typeof Symbol.iterator,_=Object.prototype.propertyIsEnumerable,k=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null),S=e("./util.inspect").custom,E=S&&x(S)?S:null,T="function"==typeof Symbol&&void 0!==Symbol.toStringTag?Symbol.toStringTag:null;function O(e,t,n){var r="double"===(n.quoteStyle||t)?'"':"'";return r+e+r}function P(e){return String(e).replace(/"/g,"&quot;")}function R(e){return!("[object Array]"!==M(e)||T&&"object"==typeof e&&T in e)}function x(e){if(C)return e&&"object"==typeof e&&e instanceof Symbol;if("symbol"==typeof e)return!0;if(!e||"object"!=typeof e||!w)return!1;try{return w.call(e),!0}catch(e){}return!1}t.exports=function e(t,n,r,i){var s=n||{};if(j(s,"quoteStyle")&&"single"!==s.quoteStyle&&"double"!==s.quoteStyle)throw new TypeError('option "quoteStyle" must be "single" or "double"');if(j(s,"maxStringLength")&&("number"==typeof s.maxStringLength?s.maxStringLength<0&&s.maxStringLength!==1/0:null!==s.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var l=!j(s,"customInspect")||s.customInspect;if("boolean"!=typeof l)throw new TypeError('option "customInspect", if provided, must be `true` or `false`');if(j(s,"indent")&&null!==s.indent&&"\t"!==s.indent&&!(parseInt(s.indent,10)===s.indent&&s.indent>0))throw new TypeError('options "indent" must be "\\t", an integer > 0, or `null`');if(void 0===t)return"undefined";if(null===t)return"null";if("boolean"==typeof t)return t?"true":"false";if("string"==typeof t)return function e(t,n){if(t.length>n.maxStringLength){var r=t.length-n.maxStringLength,i="... "+r+" more character"+(r>1?"s":"");return e(t.slice(0,n.maxStringLength),n)+i}return O(t.replace(/(['\\])/g,"\\$1").replace(/[\x00-\x1f]/g,I),"single",n)}(t,s);if("number"==typeof t)return 0===t?1/0/t>0?"0":"-0":String(t);if("bigint"==typeof t)return String(t)+"n";var m=void 0===s.depth?5:s.depth;if(void 0===r&&(r=0),r>=m&&m>0&&"object"==typeof t)return R(t)?"[Array]":"[Object]";var g=function(e,t){var n;if("\t"===e.indent)n="\t";else{if(!("number"==typeof e.indent&&e.indent>0))return null;n=Array(e.indent+1).join(" ")}return{base:n,prev:Array(t+1).join(n)}}(s,r);if(void 0===i)i=[];else if(A(i,t)>=0)return"[Circular]";function _(t,n,o){if(n&&(i=i.slice()).push(n),o){var a={depth:s.depth};return j(s,"quoteStyle")&&(a.quoteStyle=s.quoteStyle),e(t,a,r+1,i)}return e(t,s,r+1,i)}if("function"==typeof t){var S=function(e){if(e.name)return e.name;var t=b.call(y.call(e),/^function\s*([\w$]+)/);if(t)return t[1];return null}(t),D=q(t,_);return"[Function"+(S?": "+S:" (anonymous)")+"]"+(D.length>0?" { "+D.join(", ")+" }":"")}if(x(t)){var B=C?String(t).replace(/^(Symbol\(.*\))_[^)]*$/,"$1"):w.call(t);return"object"!=typeof t||C?B:N(B)}if(function(e){if(!e||"object"!=typeof e)return!1;if("undefined"!=typeof HTMLElement&&e instanceof HTMLElement)return!0;return"string"==typeof e.nodeName&&"function"==typeof e.getAttribute}(t)){for(var z="<"+String(t.nodeName).toLowerCase(),V=t.attributes||[],W=0;W<V.length;W++)z+=" "+V[W].name+"="+O(P(V[W].value),"double",s);return z+=">",t.childNodes&&t.childNodes.length&&(z+="..."),z+="</"+String(t.nodeName).toLowerCase()+">"}if(R(t)){if(0===t.length)return"[]";var H=q(t,_);return g&&!function(e){for(var t=0;t<e.length;t++)if(A(e[t],"\n")>=0)return!1;return!0}(H)?"["+U(H,g)+"]":"[ "+H.join(", ")+" ]"}if(function(e){return!("[object Error]"!==M(e)||T&&"object"==typeof e&&T in e)}(t)){var Y=q(t,_);return 0===Y.length?"["+String(t)+"]":"{ ["+String(t)+"] "+Y.join(", ")+" }"}if("object"==typeof t&&l){if(E&&"function"==typeof t[E])return t[E]();if("function"==typeof t.inspect)return t.inspect()}if(function(e){if(!o||!e||"object"!=typeof e)return!1;try{o.call(e);try{c.call(e)}catch(e){return!0}return e instanceof Map}catch(e){}return!1}(t)){var X=[];return a.call(t,(function(e,n){X.push(_(n,t,!0)+" => "+_(e,t))})),F("Map",o.call(t),X,g)}if(function(e){if(!c||!e||"object"!=typeof e)return!1;try{c.call(e);try{o.call(e)}catch(e){return!0}return e instanceof Set}catch(e){}return!1}(t)){var G=[];return u.call(t,(function(e){G.push(_(e,t))})),F("Set",c.call(t),G,g)}if(function(e){if(!p||!e||"object"!=typeof e)return!1;try{p.call(e,p);try{f.call(e,f)}catch(e){return!0}return e instanceof WeakMap}catch(e){}return!1}(t))return L("WeakMap");if(function(e){if(!f||!e||"object"!=typeof e)return!1;try{f.call(e,f);try{p.call(e,p)}catch(e){return!0}return e instanceof WeakSet}catch(e){}return!1}(t))return L("WeakSet");if(function(e){if(!d||!e||"object"!=typeof e)return!1;try{return d.call(e),!0}catch(e){}return!1}(t))return L("WeakRef");if(function(e){return!("[object Number]"!==M(e)||T&&"object"==typeof e&&T in e)}(t))return N(_(Number(t)));if(function(e){if(!e||"object"!=typeof e||!v)return!1;try{return v.call(e),!0}catch(e){}return!1}(t))return N(_(v.call(t)));if(function(e){return!("[object Boolean]"!==M(e)||T&&"object"==typeof e&&T in e)}(t))return N(h.call(t));if(function(e){return!("[object String]"!==M(e)||T&&"object"==typeof e&&T in e)}(t))return N(_(String(t)));if(!function(e){return!("[object Date]"!==M(e)||T&&"object"==typeof e&&T in e)}(t)&&!function(e){return!("[object RegExp]"!==M(e)||T&&"object"==typeof e&&T in e)}(t)){var $=q(t,_),Q=k?k(t)===Object.prototype:t instanceof Object||t.constructor===Object,K=t instanceof Object?"":"null prototype",J=!Q&&T&&Object(t)===t&&T in t?M(t).slice(8,-1):K?"Object":"",Z=(Q||"function"!=typeof t.constructor?"":t.constructor.name?t.constructor.name+" ":"")+(J||K?"["+[].concat(J||[],K||[]).join(": ")+"] ":"");return 0===$.length?Z+"{}":g?Z+"{"+U($,g)+"}":Z+"{ "+$.join(", ")+" }"}return String(t)};var D=Object.prototype.hasOwnProperty||function(e){return e in this};function j(e,t){return D.call(e,t)}function M(e){return m.call(e)}function A(e,t){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}function I(e){var t=e.charCodeAt(0),n={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return n?"\\"+n:"\\x"+(t<16?"0":"")+t.toString(16).toUpperCase()}function N(e){return"Object("+e+")"}function L(e){return e+" { ? }"}function F(e,t,n,r){return e+" ("+t+") {"+(r?U(n,r):n.join(", "))+"}"}function U(e,t){if(0===e.length)return"";var n="\n"+t.prev+t.base;return n+e.join(","+n)+"\n"+t.prev}function q(e,t){var n=R(e),r=[];if(n){r.length=e.length;for(var i=0;i<e.length;i++)r[i]=j(e,i)?t(e[i],e):""}var o,a="function"==typeof g?g(e):[];if(C){o={};for(var s=0;s<a.length;s++)o["$"+a[s]]=a[s]}for(var l in e)j(e,l)&&(n&&String(Number(l))===l&&l<e.length||C&&o["$"+l]instanceof Symbol||(/[^\
vendor: 4,516 bytes, line 56
56w$]/.test(l)?r.push(t(l,e)+": "+t(e[l],e)):r.push(l+": "+t(e[l],e))));if("function"==typeof g)for(var c=0;c<a.length;c++)_.call(e,a[c])&&r.push("["+t(a[c])+"]: "+t(e[a[c]],e));return r}},{"./util.inspect":152}],249:[function(e,t,n){"use strict";var r;if(!Object.keys){var i=Object.prototype.hasOwnProperty,o=Object.prototype.toString,a=e("./isArguments"),s=Object.prototype.propertyIsEnumerable,l=!s.call({toString:null},"toString"),c=s.call((function(){}),"prototype"),u=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],p=function(e){var t=e.constructor;return t&&t.prototype===e},f={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},d=function(){if("undefined"==typeof window)return!1;for(var e in window)try{if(!f["$"+e]&&i.call(window,e)&&null!==window[e]&&"object"==typeof window[e])try{p(window[e])}catch(e){return!0}}catch(e){return!0}return!1}();r=function(e){var t=null!==e&&"object"==typeof e,n="[object Function]"===o.call(e),r=a(e),s=t&&"[object String]"===o.call(e),f=[];if(!t&&!n&&!r)throw new TypeError("Object.keys called on a non-object");var h=c&&n;if(s&&e.length>0&&!i.call(e,0))for(var m=0;m<e.length;++m)f.push(String(m));if(r&&e.length>0)for(var y=0;y<e.length;++y)f.push(String(y));else for(var b in e)h&&"prototype"===b||!i.call(e,b)||f.push(String(b));if(l)for(var v=function(e){if("undefined"==typeof window||!d)return p(e);try{return p(e)}catch(e){return!1}}(e),g=0;g<u.length;++g)v&&"constructor"===u[g]||!i.call(e,u[g])||f.push(u[g]);return f}}t.exports=r},{"./isArguments":251}],250:[function(e,t,n){"use strict";var r=Array.prototype.slice,i=e("./isArguments"),o=Object.keys,a=o?function(e){return o(e)}:e("./implementation"),s=Object.keys;a.shim=function(){Object.keys?function(){var e=Object.keys(arguments);return e&&e.length===arguments.length}(1,2)||(Object.keys=function(e){return i(e)?s(r.call(e)):s(e)}):Object.keys=a;return Object.keys||a},t.exports=a},{"./implementation":249,"./isArguments":251}],251:[function(e,t,n){"use strict";var r=Object.prototype.toString;t.exports=function(e){var t=r.call(e),n="[object Arguments]"===t;return n||(n="[object Array]"!==t&&null!==e&&"object"==typeof e&&"number"==typeof e.length&&e.length>=0&&"[object Function]"===r.call(e.callee)),n}},{}],252:[function(e,t,n){var r,i,o=t.exports={};function a(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function l(e){if(r===setTimeout)return setTimeout(e,0);if((r===a||!r)&&setTimeout)return r=setTimeout,setTimeout(e,0);try{return r(e,0)}catch(t){try{return r.call(null,e,0)}catch(t){return r.call(this,e,0)}}}!function(){try{r="function"==typeof setTimeout?setTimeout:a}catch(e){r=a}try{i="function"==typeof clearTimeout?clearTimeout:s}catch(e){i=s}}();var c,u=[],p=!1,f=-1;function d(){p&&c&&(p=!1,c.length?u=c.concat(u):f=-1,u.length&&h())}function h(){if(!p){var e=l(d);p=!0;for(var t=u.length;t;){for(c=u,u=[];++f<t;)c&&c[f].run();f=-1,t=u.length}c=null,p=!1,function(e){if(i===clearTimeout)return clearTimeout(e);if((i===s||!i)&&clearTimeout)return i=clearTimeout,clearTimeout(e);try{i(e)}catch(t){try{return i.call(null,e)}catch(t){return i.call(this,e)}}}(e)}}function m(e,t){this.fun=e,this.array=t}function y(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new m(e,t)),1!==u.length||p||l(h)},m.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=y,o.addListener=y,o.once=y,o.off=y,o.removeListener=y,o.removeAllListeners=y,o.emit=y,o.prependListener=y,o.prependOnceListener=y,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},{}],253:[function(e,t,n){"use strict";function r(e,t,n,r,i){}r.resetWarningCache=function(){0},t.exports=r},{"./lib/ReactPropTypesSecret":257}],254:[function(e,t,n){"use strict";var r=e("./lib/ReactPropTypesSecret");function i(){}function o(){}
vendor: 6,399 bytes, line 56
56o.resetWarningCache=i,t.exports=function(){function e(e,t,n,i,o,a){if(a!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:i};return n.PropTypes=n,n}},{"./lib/ReactPropTypesSecret":257}],255:[function(e,t,n){"use strict";var r=e("react-is"),i=e("object-assign"),o=e("./lib/ReactPropTypesSecret"),a=e("./checkPropTypes"),s=Function.call.bind(Object.prototype.hasOwnProperty),l=function(){};function c(){return null}t.exports=function(e,t){var n="function"==typeof Symbol&&Symbol.iterator;var u={array:h("array"),bool:h("boolean"),func:h("function"),number:h("number"),object:h("object"),string:h("string"),symbol:h("symbol"),any:d(c),arrayOf:function(e){return d((function(t,n,r,i,a){if("function"!=typeof e)return new f("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside arrayOf.");var s=t[n];if(!Array.isArray(s))return new f("Invalid "+i+" `"+a+"` of type `"+y(s)+"` supplied to `"+r+"`, expected an array.");for(var l=0;l<s.length;l++){var c=e(s,l,r,i,a+"["+l+"]",o);if(c instanceof Error)return c}return null}))},element:d((function(t,n,r,i,o){var a=t[n];return e(a)?null:new f("Invalid "+i+" `"+o+"` of type `"+y(a)+"` supplied to `"+r+"`, expected a single ReactElement.")})),elementType:d((function(e,t,n,i,o){var a=e[t];return r.isValidElementType(a)?null:new f("Invalid "+i+" `"+o+"` of type `"+y(a)+"` supplied to `"+n+"`, expected a single ReactElement type.")})),instanceOf:function(e){return d((function(t,n,r,i,o){if(!(t[n]instanceof e)){var a=e.name||"<<anonymous>>";return new f("Invalid "+i+" `"+o+"` of type `"+function(e){if(!e.constructor||!e.constructor.name)return"<<anonymous>>";return e.constructor.name}(t[n])+"` supplied to `"+r+"`, expected instance of `"+a+"`.")}return null}))},node:d((function(e,t,n,r,i){return m(e[t])?null:new f("Invalid "+r+" `"+i+"` supplied to `"+n+"`, expected a ReactNode.")})),objectOf:function(e){return d((function(t,n,r,i,a){if("function"!=typeof e)return new f("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside objectOf.");var l=t[n],c=y(l);if("object"!==c)return new f("Invalid "+i+" `"+a+"` of type `"+c+"` supplied to `"+r+"`, expected an object.");for(var u in l)if(s(l,u)){var p=e(l,u,r,i,a+"."+u,o);if(p instanceof Error)return p}return null}))},oneOf:function(e){if(!Array.isArray(e))return c;function t(t,n,r,i,o){for(var a=t[n],s=0;s<e.length;s++)if(p(a,e[s]))return null;var l=JSON.stringify(e,(function(e,t){return"symbol"===b(t)?String(t):t}));return new f("Invalid "+i+" `"+o+"` of value `"+String(a)+"` supplied to `"+r+"`, expected one of "+l+".")}return d(t)},oneOfType:function(e){if(!Array.isArray(e))return c;for(var t=0;t<e.length;t++){var n=e[t];if("function"!=typeof n)return l("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+v(n)+" at index "+t+"."),c}return d((function(t,n,r,i,a){for(var s=0;s<e.length;s++){if(null==(0,e[s])(t,n,r,i,a,o))return null}return new f("Invalid "+i+" `"+a+"` supplied to `"+r+"`.")}))},shape:function(e){return d((function(t,n,r,i,a){var s=t[n],l=y(s);if("object"!==l)return new f("Invalid "+i+" `"+a+"` of type `"+l+"` supplied to `"+r+"`, expected `object`.");for(var c in e){var u=e[c];if(u){var p=u(s,c,r,i,a+"."+c,o);if(p)return p}}return null}))},exact:function(e){return d((function(t,n,r,a,s){var l=t[n],c=y(l);if("object"!==c)return new f("Invalid "+a+" `"+s+"` of type `"+c+"` supplied to `"+r+"`, expected `object`.");var u=i({},t[n],e);for(var p in u){var d=e[p];if(!d)return new f("Invalid "+a+" `"+s+"` key `"+p+"` supplied to `"+r+"`.\nBad object: "+JSON.stringify(t[n],null,"  ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null,"  "));var h=d(l,p,r,a,s+"."+p,o);if(h)return h}return null}))}};function p(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function f(e){this.message=e,this.stack=""}function d(e){function n(n,r,i,a,s,l,c){if((a=a||"<<anonymous>>",l=l||i,c!==o)&&t){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}return null==r[i]?n?null===r[i]?new f("The "+s+" `"+l+"` is marked as required in `"+a+"`, but its value is `null`."):new f("The "+s+" `"+l+"` is marked as required in `"+a+"`, but its value is `undefined`."):null:e(r,i,a,s,l)}var r=n.bind(null,!1);return r.isRequired=n.bind(null,!0),r}function h(e){return d((function(t,n,r,i,o,a){var s=t[n];return y(s)!==e?new f("Invalid "+i+" `"+o+"` of type `"+b(s)+"` supplied to `"+r+"`, expected `"+e+"`."):null}))}function m(t){switch(typeof t){case"number":case"string":case"undefined":return!0;case"boolean":return!t;case"object":if(Array.isArray(t))return t.every(m);if(null===t||e(t))return!0;var r=function(e){var t=e&&(n&&e[n]||e["@@iterator"]);if("function"==typeof t)return t}(t);if(!r)return!1;var i,o=r.call(t);if(r!==t.entries){for(;!(i=o.next()).done;)if(!m(i.value))return!1}else for(;!(i=o.next()).done;){var a=i.value;if(a&&!m(a[1]))return!1}return!0;default:return!1}}function y(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function b(e){if(null==e)return""+e;var t=y(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function v(e){var t=b(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return f.prototype=Error.prototype,u.checkPropTypes=a,u.resetWarningCache=a.resetWarningCache,u.PropTypes=u,u}},{"./checkPropTypes":253,"./lib/ReactPropTypesSecret":257,"object-assign":247,"react-is":280}],256:[function(e,t,n){t.exports=e("./factoryWithThrowingShims")()},{"./factoryWithThrowingShims":254,"./factoryWithTypeCheckers":255,"react-is":280}],257:[function(e,t,n){"use strict";
56t.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},{}],258:[function(e,t,n){"use strict";var r;Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=((r=e("universal-cookie"))&&r.__esModule?r:{default:r}).default;n.default=i,t.exports=n.default},{"universal-cookie":516}],259:[function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(n,"__esModule",{value:!0}),n.default=n.Consumer=n.Provider=void 0;var i,o=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=s();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=i?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(e("react")),a=(i=e("./Cookies"))&&i.__esModule?i:{default:i};function s(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return s=function(){return e},e}var l=o.createContext(new a.default),c=l.Provider,u=l.Consumer;n.Consumer=u,n.Provider=c;var p=l;n.default=p},{"./Cookies":258,react:307}],260:[function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i,o=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=l();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var a=i?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(e("react")),a=(i=e("universal-cookie"))&&i.__esModule?i:{default:i},s=e("./CookiesContext");function l(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return l=function(){return e},e}var c,u=(c=function(e,t){return(c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}c(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),p=function(e){function t(t){var n=e.call(this,t)||this;return t.cookies?n.cookies=t.cookies:n.cookies=new a.default,n}return u(t,e),t.prototype.render=function(){return o.createElement(s.Provider,{value:this.cookies},this.props.children)},t}(o.Component);n.default=p,t.exports=n.default},{"./CookiesContext":259,react:307,"universal-cookie":516}],261:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"Cookies",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(n,"CookiesProvider",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(n,"withCookies",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(n,"useCookies",{enumerable:!0,get:function(){return a.default}});var r=s(e("./Cookies")),i=s(e("./CookiesProvider")),o=s(e("./withCookies")),a=s(e("./useCookies"));function s(e){return e&&e.__esModule?e:{default:e}}},{"./Cookies":258,"./CookiesProvider":260,"./useCookies":262,"./withCookies":263}],262:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(e){var t=(0,i.useContext)(o.default);if(!t)throw new Error("Missing <CookiesProvider>");var n=t.getAll(),r=(0,i.useState)(n),a=r[0],s=r[1],l=(0,i.useRef)(a);(0,i.useEffect)((function(){function n(){var n=t.getAll();(function(e,t,n){if(!e)return!0;for(var r=0,i=e;r<i.length;r++){var o=i[r];if(t[o]!==n[o])return!0}return!1})(e||null,n,l.current)&&s(n),l.current=n}return t.addChangeListener(n),function(){t.removeChangeListener(n)}}),[t]);var c=(0,i.useMemo)((function(){return t.set.bind(t)}),[t]),u=(0,i.useMemo)((function(){return t.remove.bind(t)}),[t]);return[a,c,u]};var r,i=e("react"),o=(r=e("./CookiesContext"))&&r.__esModule?r:{default:r};t.exports=n.default},{"./CookiesContext":259,react:307}],263:[function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(n,"__esModule",{value:!0}
vendor: 24,946 bytes, lines 56-92
56),n.default=function(e){var t=e.displayName||e.name,n=function(n){function r(){var e=null!==n&&n.apply(this,arguments)||this;return e.onChange=function(){e.forceUpdate()},e}return l(r,n),r.prototype.listen=function(){this.props.cookies.addChangeListener(this.onChange)},r.prototype.unlisten=function(e){(e||this.props.cookies).removeChangeListener(this.onChange)},r.prototype.componentDidMount=function(){this.listen()},r.prototype.componentDidUpdate=function(e){e.cookies!==this.props.cookies&&(this.unlisten(e.cookies),this.listen())},r.prototype.componentWillUnmount=function(){this.unlisten()},r.prototype.render=function(){var t=this.props,n=t.forwardedRef,r=t.cookies,o=u(t,["forwardedRef","cookies"]),a=r.getAll();return i.createElement(e,c({},o,{ref:n,cookies:r,allCookies:a}))},r.displayName="withCookies("+t+")",r.WrappedComponent=e,r}(i.Component),r=i.forwardRef((function(e,t){return i.createElement(o.Consumer,null,(function(r){return i.createElement(n,c({cookies:r},e,{forwardedRef:t}))}))}));return r.displayName=n.displayName,r.WrappedComponent=n.WrappedComponent,p(r,e)};var i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var s=i?Object.getOwnPropertyDescriptor(e,o):null;s&&(s.get||s.set)?Object.defineProperty(n,o,s):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(e("react")),o=e("./CookiesContext");function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}var s,l=(s=function(e,t){return(s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}s(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),c=function(){return(c=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},u=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n},p=e("hoist-non-react-statics");t.exports=n.default},{"./CookiesContext":259,"hoist-non-react-statics":229,react:307}],264:[function(e,t,n){
57/** @license React v17.0.1
58 * react-dom-server.browser.development.js
59 *
60 * Copyright (c) Facebook, Inc. and its affiliates.
61 *
62 * This source code is licensed under the MIT license found in the
63 * LICENSE file in the root directory of this source tree.
64 */
65"use strict"},{"object-assign":247,react:307}],265:[function(e,t,n){
66/** @license React v17.0.1
67 * react-dom-server.browser.production.min.js
68 *
69 * Copyright (c) Facebook, Inc. and its affiliates.
70 *
71 * This source code is licensed under the MIT license found in the
72 * LICENSE file in the root directory of this source tree.
73 */
74"use strict";var r=e("object-assign"),i=e("react");function o(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var a=60106,s=60107,l=60108,c=60114,u=60109,p=60110,f=60112,d=60113,h=60120,m=60115,y=60116,b=60121,v=60117,g=60119,w=60129,C=60131;if("function"==typeof Symbol&&Symbol.for){var _=Symbol.for;a=_("react.portal"),s=_("react.fragment"),l=_("react.strict_mode"),c=_("react.profiler"),u=_("react.provider"),p=_("react.context"),f=_("react.forward_ref"),d=_("react.suspense"),h=_("react.suspense_list"),m=_("react.memo"),y=_("react.lazy"),b=_("react.block"),v=_("react.fundamental"),g=_("react.scope"),w=_("react.debug_trace_mode"),C=_("react.legacy_hidden")}function k(e){if(null==e)return null;if("function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case s:return"Fragment";case a:return"Portal";case c:return"Profiler";case l:return"StrictMode";case d:return"Suspense";case h:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case p:return(e.displayName||"Context")+".Consumer";case u:return(e._context.displayName||"Context")+".Provider";case f:var t=e.render;return t=t.displayName||t.name||"",e.displayName||(""!==t?"ForwardRef("+t+")":"ForwardRef");case m:return k(e.type);case b:return k(e._render);case y:t=e._payload,e=e._init;try{return k(e(t))}catch(e){}}return null}var S=i.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,E={};function T(e,t){for(var n=0|e._threadCount;n<=t;n++)e[n]=e._currentValue2,e._threadCount=n+1}for(var O=new Uint16Array(16),P=0;15>P;P++)O[P]=P+1;O[15]=0;var R=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,x=Object.prototype.hasOwnProperty,D={},j={};function M(e){return!!x.call(j,e)||!x.call(D,e)&&(R.test(e)?j[e]=!0:(D[e]=!0,!1))}function A(e,t,n,r,i,o,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var I={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(e){I[e]=new A(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((function(e){var t=e[0];I[t]=new A(t,1,!1,e[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(e){I[e]=new A(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(e){I[e]=new A(e,2,!1,e,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(e){I[e]=new A(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(e){I[e]=new A(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((function(e){I[e]=new A(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((function(e){I[e]=new A(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((function(e){I[e]=new A(e,5,!1,e.toLowerCase(),null,!1,!1)}));var N=/[\-:]([a-z])/g;function L(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(e){var t=e.replace(N,L);I[t]=new A(t,1,!1,e,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(e){var t=e.replace(N,L);I[t]=new A(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(e){var t=e.replace(N,L);I[t]=new A(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(e){I[e]=new A(e,1,!1,e.toLowerCase(),null,!1,!1)})),I.xlinkHref=new A("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(e){I[e]=new A(e,1,!1,e.toLowerCase(),null,!0,!0)}));var F=/["'&<>]/;function U(e){if("boolean"==typeof e||"number"==typeof e)return""+e;e=""+e;var t=F.exec(e);if(t){var n,r="",i=0;for(n=t.index;n<e.length;n++){switch(e.charCodeAt(n)){case 34:t="&quot;";break;case 38:t="&amp;";break;case 39:t="&#x27;";break;case 60:t="&lt;";break;case 62:t="&gt;";break;default:continue}i!==n&&(r+=e.substring(i,n)),i=n+1,r+=t}e=i!==n?r+e.substring(i,n):r}return e}function q(e,t){var n,r=I.hasOwnProperty(e)?I[e]:null;return(n="style"!==e)&&(n=null!==r?0===r.type:2<e.length&&("o"===e[0]||"O"===e[0])&&("n"===e[1]||"N"===e[1])),n||function(e,t,n,r){if(null==t||function(e,t,n,r){if(null!==n&&0===n.type)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return!r&&(null!==n?!n.acceptsBooleans:"data-"!==(e=e.toLowerCase().slice(0,5))&&"aria-"!==e);default:return!1}}(e,t,n,r))return!0;if(r)return!1;if(null!==n)switch(n.type){case 3:return!t;case 4:return!1===t;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}(e,t,r,!1)?"":null!==r?(e=r.attributeName,3===(n=r.type)||4===n&&!0===t?e+'=""':(r.sanitizeURL&&(t=""+t),e+'="'+U(t)+'"')):M(e)?e+'="'+U(t)+'"':""}var B="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},z=null,V=null,W=null,H=!1,Y=!1,X=null,G=0;function $(){if(null===z)throw Error(o(321));return z}function Q(){if(0<G)throw Error(o(312));return{memoizedState:null,queue:null,next:null}}function K(){return null===W?null===V?(H=!1,V=W=Q()):(H=!0,W=V):null===W.next?(H=!1,W=W.next=Q()):(H=!0,W=W.next),W}function J(e,t,n,r){for(;Y;)Y=!1,G+=1,W=null,n=e(t,r);return Z(),n}function Z(){z=null,Y=!1,V=null,G=0,W=X=null}function ee(e,t){return"function"==typeof t?t(e):t}function te(e,t,n){if(z=$(),W=K(),H){var r=W.queue;if(t=r.dispatch,null!==X&&void 0!==(n=X.get(r))){X.delete(r),r=W.memoizedState;do{r=e(r,n.action),n=n.next}while(null!==n);return W.memoizedState=r,[r,t]}return[W.memoizedState,t]}return e=e===ee?"function"==typeof t?t():t:void 0!==n?n(t):t,W.memoizedState=e,e=(e=W.queue={last:null,dispatch:null}).dispatch=re.bind(null,z,e),[W.memoizedState,e]}function ne(e,t){if(z=$(),t=void 0===t?null:t,null!==(W=K())){var n=W.memoizedState;if(null!==n&&null!==t){var r=n[1];e:if(null===r)r=!1;else{for(var i=0;i<r.length&&i<t.length;i++)if(!B(t[i],r[i])){r=!1;break e}r=!0}if(r)return n[0]}}return e=e(),W.memoizedState=[e,t],e}function re(e,t,n){if(!(25>G))throw Error(o(301));if(e===z)if(Y=!0,e={action:n,next:null},null===X&&(X=new Map),void 0===(n=X.get(t)))X.set(t,e);else{for(t=n;null!==t.next;)t=t.next;t.next=e}}function ie(){}var oe=null,ae={readContext:function(e){var t=oe.threadID;return T(e,t),e[t]},useContext:function(e){$();var t=oe.threadID;return T(e,t),e[t]},useMemo:ne,useReducer:te,useRef:function(e){z=$();var t=(W=K()).memoizedState;return null===t?(e={current:e},W.memoizedState=e):t},useState:function(e){return te(ee,e)},useLayoutEffect:function(){},useCallback:function(e,t){return ne((function(){return e}),t)},useImperativeHandle:ie,useEffect:ie,useDebugValue:ie,useDeferredValue:function(e){return $(),e},useTransition:function(){return $(),[function(e){e()},!1]},useOpaqueIdentifier:function(){return(oe.identifierPrefix||"")+"R:"+(oe.uniqueID++).toString(36)},useMutableSource:function(e,t){return $(),t(e._source)}},se="http://www.w3.org/1999/xhtml";function le(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}var ce={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},ue=r({menuitem:!0},ce),pe={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},fe=["Webkit","ms","Moz","O"];Object.keys(pe).forEach((function(e){fe.forEach((function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),pe[t]=pe[e]}))}));var de=/([A-Z])/g,he=/^ms-/,me=i.Children.toArray,ye=S.ReactCurrentDispatcher,be={listing:!0,pre:!0,textarea:!0},ve=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,ge={},we={};var Ce=Object.prototype.hasOwnProperty,_e={children:null,dangerouslySetInnerHTML:null,suppressContentEditableWarning:null,suppressHydrationWarning:null};function ke(e,t){if(void 0===e)throw Error(o(152,k(t)||"Component"))}function Se(e,t,n){function a(i,a){var s=a.prototype&&a.prototype.isReactComponent,l=function(e,t,n,r){if(r&&("object"==typeof(r=e.contextType)&&null!==r))return T(r,n),r[n];if(e=e.contextTypes){for(var i in n={},e)n[i]=t[i];t=n}else t=E;return t}(a,t,n,s),c=[],u=!1,p={isMounted:function(){return!1},enqueueForceUpdate:function(){if(null===c)return null},enqueueReplaceState:function(e,t){u=!0,c=[t]},enqueueSetState:function(e,t){if(null===c)return null;c.push(t)}};if(s){if(s=new a(i.props,l,p),"function"==typeof a.getDerivedStateFromProps){var f=a.getDerivedStateFromProps.call(null,i.props,s.state);null!=f&&(s.state=r({},s.state,f))}}else if(z={},s=a(i.props,l,p),null==(s=J(a,i.props,s,l))||null==s.render)return void ke(e=s,a);if(s.props=i.props,s.context=l,s.updater=p,void 0===(p=s.state)&&(s.state=p=null),"function"==typeof s.UNSAFE_componentWillMount||"function"==typeof s.componentWillMount)if("function"==typeof s.componentWillMount&&"function"!=typeof a.getDerivedStateFromProps&&s.componentWillMount(),"function"==typeof s.UNSAFE_componentWillMount&&"function"!=typeof a.getDerivedStateFromProps&&s.UNSAFE_componentWillMount(),c.length){p=c;var d=u;if(c=null,u=!1,d&&1===p.length)s.state=p[0];else{f=d?p[0]:s.state;var h=!0;for(d=d?1:0;d<p.length;d++){var m=p[d];null!=(m="function"==typeof m?m.call(s,f,i.props,l):m)&&(h?(h=!1,f=r({},f,m)):r(f,m))}s.state=f}}else c=null;if(ke(e=s.render(),a),"function"==typeof s.getChildContext&&"object"==typeof(i=a.childContextTypes)){var y=s.getChildContext();for(var b in y)if(!(b in i))throw Error(o(108,k(a)||"Unknown",b))}y&&(t=r({},t,y))}for(;i.isValidElement(e);){var s=e,l=s.type;if("function"!=typeof l)break;a(s,l)}return{child:e,context:t}}var Ee=function(){function e(e,t,n){i.isValidElement(e)?e.type!==s?e=[e]:(e=e.props.children,e=i.isValidElement(e)?[e]:me(e)):e=me(e),e={type:null,domNamespace:se,children:e,childIndex:0,context:E,footer:""};var r=O[0];if(0===r){var a=O,l=2*(r=a.length);if(!(65536>=l))throw Error(o(304));var c=new Uint16Array(l);for(c.set(a),(O=c)[0]=r+1,a=r;a<l-1;a++)O[a]=a+1;O[l-1]=0}else O[0]=O[r];this.threadID=r,this.stack=[e],this.exhausted=!1,this.currentSelectValue=null,this.previousWasTextNode=!1,this.makeStaticMarkup=t,this.suspenseDepth=0,this.contextIndex=-1,this.contextStack=[],this.contextValueStack=[],this.uniqueID=0,this.identifierPrefix=n&&n.identifierPrefix||""}var t=e.prototype;return t.destroy=function(){if(!this.exhausted){this.exhausted=!0,this.clearProviders();var e=this.threadID;O[e]=O[0],O[0]=e}},t.pushProvider=function(e){var t=++this.contextIndex,n=e.type._context,r=this.threadID;T(n,r);var i=n[r];this.contextStack[t]=n,this.contextValueStack[t]=i,n[r]=e.props.value},t.popProvider=function(){var e=this.contextIndex,t=this.contextStack[e],n=this.contextValueStack[e];this.contextStack[e]=null,this.contextValueStack[e]=null,this.contextIndex--,t[this.threadID]=n},t.clearProviders=function(){for(var e=this.contextIndex;0<=e;e--)this.contextStack[e][this.threadID]=this.contextValueStack[e]},t.read=function(e){if(this.exhausted)return null;var t=oe;oe=this;var n=ye.current;ye.current=ae;try{for(var r=[""],i=!1;r[0].length<e;){if(0===this.stack.length){this.exhausted=!0;var a=this.threadID;O[a]=O[0],O[0]=a;break}var s=this.stack[this.stack.length-1];if(i||s.childIndex>=s.children.length){var l=s.footer;if(""!==l&&(this.previousWasTextNode=!1),this.stack.pop(),"select"===s.type)this.currentSelectValue=null;else if(null!=s.type&&null!=s.type.type&&s.type.type.$$typeof===u)this.popProvider(s.type);else if(s.type===d){this.suspenseDepth--;var c=r.pop();if(i){i=!1;var p=s.fallbackFrame;if(!p)throw Error(o(303));this.stack.push(p),r[this.suspenseDepth]+="\x3c!--$!--\x3e";continue}r[this.suspenseDepth]+=c}r[this.suspenseDepth]+=l}else{var f=s.children[s.childIndex++],h="";try{h+=this.render(f,s.context,s.domNamespace)}catch(e){if(null!=e&&"function"==typeof e.then)throw Error(o(294));throw e}r.length<=this.suspenseDepth&&r.push(""),r[this.suspenseDepth]+=h}}return r[0]}finally{ye.current=n,oe=t,Z()}},t.render=function(e,t,n){if("string"==typeof e||"number"==typeof e)return""===(n=""+e)?"":this.makeStaticMarkup?U(n):this.previousWasTextNode?"\x3c!-- --\x3e"+U(n):(this.previousWasTextNode=!0,U(n));if(e=(t=Se(e,t,this.threadID)).child,t=t.context,null===e||!1===e)return"";if(!i.isValidElement(e)){if(null!=e&&null!=e.$$typeof){if((n=e.$$typeof)===a)throw Error(o(257));throw Error(o(258,n.toString()))}return e=me(e),this.stack.push({type:null,domNamespace:n,children:e,childIndex:0,context:t,footer:""}),""}var b=e.type;if("string"==typeof b)return this.renderDOM(e,t,n);switch(b){case C:case w:case l:case c:case h:case s:return e=me(e.props.children),this.stack.push({type:null,domNamespace:n,children:e,childIndex:0,context:t,footer:""}),"";case d:throw Error(o(294));case g:throw Error(o(343))}if("object"==typeof b&&null!==b)switch(b.$$typeof){case f:z={};var _=b.render(e.props,e.ref);return _=J(b.render,e.props,_,e.ref),_=me(_),this.stack.push({type:null,domNamespace:n,children:_,childIndex:0,context:t,footer:""}),"";case m:return e=[i.createElement(b.type,r({ref:e.ref},e.props))],this.stack.push({type:null,domNamespace:n,children:e,childIndex:0,context:t,footer:""}),"";case u:return n={type:e,domNamespace:n,children:b=me(e.props.children),childIndex:0,context:t,footer:""},this.pushProvider(e),this.stack.push(n),"";case p:b=e.type,_=e.props;var k=this.threadID;return T(b,k),b=me(_.children(b[k])),this.stack.push({type:e,domNamespace:n,children:b,childIndex:0,context:t,footer:""}),"";case v:throw Error(o(338));case y:return b=(_=(b=e.type)._init)(b._payload),e=[i.createElement(b,r({ref:e.ref},e.props))],this.stack.push({type:null,domNamespace:n,children:e,childIndex:0,context:t,footer:""}),""}throw Error(o(130,null==b?b:typeof b,""))},t.renderDOM=function(e,t,n){var a=e.type.toLowerCase();if(n===se&&le(a),!ge.hasOwnProperty(a)){if(!ve.test(a))throw Error(o(65,a));ge[a]=!0}var s=e.props;if("input"===a)s=r({type:void 0},s,{defaultChecked:void 0,defaultValue:void 0,value:null!=s.value?s.value:s.defaultValue,checked:null!=s.checked?s.checked:s.defaultChecked});else if("textarea"===a){var l=s.value;if(null==l){l=s.defaultValue;var c=s.children;if(null!=c){if(null!=l)throw Error(o(92));if(Array.isArray(c)){if(!(1>=c.length))throw Error(o(93));c=c[0]}l=""+c}null==l&&(l="")}s=r({},s,{value:void 0,children:""+l})}else if("select"===a)this.currentSelectValue=null!=s.value?s.value:s.defaultValue,s=r({},s,{value:void 0});else if("option"===a){c=this.currentSelectValue;var u=function(e){if(null==e)return e;var t="";return i.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(s.children);if(null!=c){var p=null!=s.value?s.value+"":u;if(l=!1,Array.isArray(c)){for(var f=0;f<c.length;f++)if(""+c[f]===p){l=!0;break}}else l=""+c===p;s=r({selected:void 0,children:void 0},s,{selected:l,children:u})}}if(l=s){if(ue[a]&&(null!=l.children||null!=l.dangerouslySetInnerHTML))throw Error(o(137,a));if(null!=l.dangerouslySetInnerHTML){if(null!=l.children)throw Error(o(60));if("object"!=typeof l.dangerouslySetInnerHTML||!("__html"in l.dangerouslySetInnerHTML))throw Error(o(61))}if(null!=l.style&&"object"!=typeof l.style)throw Error(o(62))}l=s,c=this.makeStaticMarkup,u=1===this.stack.length,p="<"+e.type;e:if(-1===a.indexOf("-"))f="string"==typeof l.is;else switch(a){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":f=!1;break e;default:f=!0}for(C in l)if(Ce.call(l,C)){var d=l[C];if(null!=d){if("style"===C){var h=void 0,m="",y="";for(h in d)if(d.hasOwnProperty(h)){var b=0===h.indexOf("--"),v=d[h];if(null!=v){if(b)var g=h;else if(g=h,we.hasOwnProperty(g))g=we[g];else{var w=g.replace(de,"-$1").toLowerCase().replace(he,"-ms-");g=we[g]=w}m+=y+g+":",y=h,m+=b=null==v||"boolean"==typeof v||""===v?"":b||"number"!=typeof v||0===v||pe.hasOwnProperty(y)&&pe[y]?(""+v).trim():v+"px",y=";"}}d=m||null}h=null,f?_e.hasOwnProperty(C)||(h=M(h=C)&&null!=d?h+'="'+U(d)+'"':""):h=q(C,d),h&&(p+=" "+h)}}c||u&&(p+=' data-reactroot=""');var C=p;l="",ce.hasOwnProperty(a)?C+="/>":(C+=">",l="</"+e.type+">");e:{if(null!=(c=s.dangerouslySetInnerHTML)){if(null!=c.__html){c=c.__html;break e}}else if("string"==typeof(c=s.children)||"number"==typeof c){c=U(c);break e}c=null}return null!=c?(s=[],be.hasOwnProperty(a)&&"\n"===c.charAt(0)&&(C+="\n"),C+=c):s=me(s.children),e=e.type,n=null==n||"http://www.w3.org/1999/xhtml"===n?le(e):"http://www.w3.org/2000/svg"===n&&"foreignObject"===e?"http://www.w3.org/1999/xhtml":n,this.stack.push({domNamespace:n,type:a,children:s,childIndex:0,context:t,footer:l}),this.previousWasTextNode=!1,C},e}();n.renderToNodeStream=function(){throw Error(o(207))},n.renderToStaticMarkup=function(e,t){e=new Ee(e,!0,t);try{return e.read(1/0)}finally{e.destroy()}},n.renderToStaticNodeStream=function(){throw Error(o(208))},n.renderToString=function(e,t){e=new Ee(e,!1,t);try{return e.read(1/0)}finally{e.destroy()}},n.version="17.0.1"},{"object-assign":247,react:307}],266:[function(e,t,n){
75/** @license React v17.0.1
76 * react-dom.development.js
77 *
78 * Copyright (c) Facebook, Inc. and its affiliates.
79 *
80 * This source code is licensed under the MIT license found in the
81 * LICENSE file in the root directory of this source tree.
82 */
83"use strict"},{"object-assign":247,react:307,scheduler:323,"scheduler/tracing":324}],267:[function(e,t,n){
84/** @license React v17.0.1
85 * react-dom.production.min.js
86 *
87 * Copyright (c) Facebook, Inc. and its affiliates.
88 *
89 * This source code is licensed under the MIT license found in the
90 * LICENSE file in the root directory of this source tree.
91 */
92"use strict";var r=e("react"),i=e("object-assign"),o=e("scheduler");function a(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}if(!r)throw Error(a(227));var s=new Set,l={};function c(e,t){u(e,t),u(e+"Capture",t)}function u(e,t){for(l[e]=t,e=0;e<t.length;e++)s.add(t[e])}var p=!("undefined"==typeof window||void 0===window.document||void 0===window.document.createElement),f=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,d=Object.prototype.hasOwnProperty,h={},m={};function y(e,t,n,r,i,o,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var b={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(e){b[e]=new y(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEac
vendor: 17,166 bytes, line 92
92h((function(e){var t=e[0];b[t]=new y(t,1,!1,e[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(e){b[e]=new y(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(e){b[e]=new y(e,2,!1,e,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(e){b[e]=new y(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(e){b[e]=new y(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((function(e){b[e]=new y(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((function(e){b[e]=new y(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((function(e){b[e]=new y(e,5,!1,e.toLowerCase(),null,!1,!1)}));var v=/[\-:]([a-z])/g;function g(e){return e[1].toUpperCase()}function w(e,t,n,r){var i=b.hasOwnProperty(t)?b[t]:null;(null!==i?0===i.type:!r&&(2<t.length&&("o"===t[0]||"O"===t[0])&&("n"===t[1]||"N"===t[1])))||(function(e,t,n,r){if(null==t||function(e,t,n,r){if(null!==n&&0===n.type)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return!r&&(null!==n?!n.acceptsBooleans:"data-"!==(e=e.toLowerCase().slice(0,5))&&"aria-"!==e);default:return!1}}(e,t,n,r))return!0;if(r)return!1;if(null!==n)switch(n.type){case 3:return!t;case 4:return!1===t;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}(t,n,i,r)&&(n=null),r||null===i?function(e){return!!d.call(m,e)||!d.call(h,e)&&(f.test(e)?m[e]=!0:(h[e]=!0,!1))}(t)&&(null===n?e.removeAttribute(t):e.setAttribute(t,""+n)):i.mustUseProperty?e[i.propertyName]=null===n?3!==i.type&&"":n:(t=i.attributeName,r=i.attributeNamespace,null===n?e.removeAttribute(t):(n=3===(i=i.type)||4===i&&!0===n?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(e){var t=e.replace(v,g);b[t]=new y(t,1,!1,e,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(e){var t=e.replace(v,g);b[t]=new y(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(e){var t=e.replace(v,g);b[t]=new y(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(e){b[e]=new y(e,1,!1,e.toLowerCase(),null,!1,!1)})),b.xlinkHref=new y("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(e){b[e]=new y(e,1,!1,e.toLowerCase(),null,!0,!0)}));var C=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,_=60103,k=60106,S=60107,E=60108,T=60114,O=60109,P=60110,R=60112,x=60113,D=60120,j=60115,M=60116,A=60121,I=60128,N=60129,L=60130,F=60131;if("function"==typeof Symbol&&Symbol.for){var U=Symbol.for;_=U("react.element"),k=U("react.portal"),S=U("react.fragment"),E=U("react.strict_mode"),T=U("react.profiler"),O=U("react.provider"),P=U("react.context"),R=U("react.forward_ref"),x=U("react.suspense"),D=U("react.suspense_list"),j=U("react.memo"),M=U("react.lazy"),A=U("react.block"),U("react.scope"),I=U("react.opaque.id"),N=U("react.debug_trace_mode"),L=U("react.offscreen"),F=U("react.legacy_hidden")}var q,B="function"==typeof Symbol&&Symbol.iterator;function z(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=B&&e[B]||e["@@iterator"])?e:null}function V(e){if(void 0===q)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);q=t&&t[1]||""}return"\n"+q+e}var W=!1;function H(e,t){if(!e||W)return"";W=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(t,[])}catch(e){var r=e}Reflect.construct(e,[],t)}else{try{t.call()}catch(e){r=e}e.call(t.prototype)}else{try{throw Error()}catch(e){r=e}e()}}catch(e){if(e&&r&&"string"==typeof e.stack){for(var i=e.stack.split("\n"),o=r.stack.split("\n"),a=i.length-1,s=o.length-1;1<=a&&0<=s&&i[a]!==o[s];)s--;for(;1<=a&&0<=s;a--,s--)if(i[a]!==o[s]){if(1!==a||1!==s)do{if(a--,0>--s||i[a]!==o[s])return"\n"+i[a].replace(" at new "," at ")}while(1<=a&&0<=s);break}}}finally{W=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?V(e):""}function Y(e){switch(e.tag){case 5:return V(e.type);case 16:return V("Lazy");case 13:return V("Suspense");case 19:return V("SuspenseList");case 0:case 2:case 15:return e=H(e.type,!1);case 11:return e=H(e.type.render,!1);case 22:return e=H(e.type._render,!1);case 1:return e=H(e.type,!0);default:return""}}function X(e){if(null==e)return null;if("function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case S:return"Fragment";case k:return"Portal";case T:return"Profiler";case E:return"StrictMode";case x:return"Suspense";case D:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case P:return(e.displayName||"Context")+".Consumer";case O:return(e._context.displayName||"Context")+".Provider";case R:var t=e.render;return t=t.displayName||t.name||"",e.displayName||(""!==t?"ForwardRef("+t+")":"ForwardRef");case j:return X(e.type);case A:return X(e._render);case M:t=e._payload,e=e._init;try{return X(e(t))}catch(e){}}return null}function G(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function $(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function Q(e){e._valueTracker||(e._valueTracker=function(e){var t=$(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&void 0!==n&&"function"==typeof n.get&&"function"==typeof n.set){var i=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){r=""+e,o.call(this,e)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(e){r=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e))}function K(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=$(e)?e.checked?"true":"false":e.value),(e=r)!==n&&(t.setValue(e),!0)}function J(e){if(void 0===(e=e||("undefined"!=typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}function Z(e,t){var n=t.checked;return i({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:null!=n?n:e._wrapperState.initialChecked})}function ee(e,t){var n=null==t.defaultValue?"":t.defaultValue,r=null!=t.checked?t.checked:t.defaultChecked;n=G(null!=t.value?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:"checkbox"===t.type||"radio"===t.type?null!=t.checked:null!=t.value}}function te(e,t){null!=(t=t.checked)&&w(e,"checked",t,!1)}function ne(e,t){te(e,t);var n=G(t.value),r=t.type;if(null!=n)"number"===r?(0===n&&""===e.value||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if("submit"===r||"reset"===r)return void e.removeAttribute("value");t.hasOwnProperty("value")?ie(e,t.type,n):t.hasOwnProperty("defaultValue")&&ie(e,t.type,G(t.defaultValue)),null==t.checked&&null!=t.defaultChecked&&(e.defaultChecked=!!t.defaultChecked)}function re(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!("submit"!==r&&"reset"!==r||void 0!==t.value&&null!==t.value))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}""!==(n=e.name)&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,""!==n&&(e.name=n)}function ie(e,t,n){"number"===t&&J(e.ownerDocument)===e||(null==n?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}function oe(e,t){return e=i({children:void 0},t),(t=function(e){var t="";return r.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(t.children))&&(e.children=t),e}function ae(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t["$"+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty("$"+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=""+G(n),t=null,i=0;i<e.length;i++){if(e[i].value===n)return e[i].selected=!0,void(r&&(e[i].defaultSelected=!0));null!==t||e[i].disabled||(t=e[i])}null!==t&&(t.selected=!0)}}function se(e,t){if(null!=t.dangerouslySetInnerHTML)throw Error(a(91));return i({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function le(e,t){var n=t.value;if(null==n){if(n=t.children,t=t.defaultValue,null!=n){if(null!=t)throw Error(a(92));if(Array.isArray(n)){if(!(1>=n.length))throw Error(a(93));n=n[0]}t=n}null==t&&(t=""),n=t}e._wrapperState={initialValue:G(n)}}function ce(e,t){var n=G(t.value),r=G(t.defaultValue);null!=n&&((n=""+n)!==e.value&&(e.value=n),null==t.defaultValue&&e.defaultValue!==n&&(e.defaultValue=n)),null!=r&&(e.defaultValue=""+r)}function ue(e){var t=e.textContent;t===e._wrapperState.initialValue&&""!==t&&null!==t&&(e.value=t)}var pe="http://www.w3.org/1999/xhtml",fe="http://www.w3.org/2000/svg";function de(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function he(e,t){return null==e||"http://www.w3.org/1999/xhtml"===e?de(t):"http://www.w3.org/2000/svg"===e&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":e}var me,ye=function(e){return"undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction?function(t,n,r,i){MSApp.execUnsafeLocalFunction((function(){return e(t,n)}))}:e}((function(e,t){if(e.namespaceURI!==fe||"innerHTML"in e)e.innerHTML=t;else{for((me=me||document.createElement("div")).innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=me.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}}));function be(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t}var ve={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},ge=["Webkit","ms","Moz","O"];function we(e,t,n){return null==t||"boolean"==typeof t||""===t?"":n||"number"!=typeof t||0===t||ve.hasOwnProperty(e)&&ve[e]?(""+t).trim():t+"px"}function Ce(e,t){for(var n in e=e.style,t)if(t.hasOwnProperty(n)){var r=0===n.indexOf("--"),i=we(n,t[n],r);"float"===n&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}Object.keys(ve).forEach((function(e){ge.forEach((function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),ve[t]=ve[e]}))}));var _e=i({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function ke(e,t){if(t){if(_e[e]&&(null!=t.children||null!=t.dangerouslySetInnerHTML))throw Error(a(137,e));if(null!=t.dangerouslySetInnerHTML){if(null!=t.children)throw Error(a(60));if("object"!=typeof t.dangerouslySetInnerHTML||!("__html"in t.dangerouslySetInnerHTML))throw Error(a(61))}if(null!=t.style&&"object"!=typeof t.style)throw Error(a(62))}}function Se(e,t){if(-1===e.indexOf("-"))return"string"==typeof t.is;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function Ee(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}var Te=null,Oe=null,Pe=null;function Re(e){if(e=Jr(e)){if("function"!=typeof Te)throw Error(a(280));var t=e.stateNode;t&&(t=ei(t),Te(e.stateNode,e.type,t))}}function xe(e){Oe?Pe?Pe.push(e):Pe=[e]:Oe=e}function De(){if(Oe){var e=Oe,t=Pe;if(Pe=Oe=null,Re(e),t)for(e=0;e<t.length;e++)Re(t[e])}}function je(e,t){return e(t)}function Me(e,t,n,r,i){return e(t,n,r,i)}function Ae(){}var Ie=je,Ne=!1,Le=!1;function Fe(){null===Oe&&null===Pe||(Ae(),De())}function Ue(e,t){var n=e.stateNode;if(null===n)return null;var r=ei(n);if(null===r)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(r=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!r;break e;default:e=!1}if(e)return null;if(n&&"function"!=typeof n)throw Error(a(231,t,typeof n));return n}var qe=!1;if(p)try{var Be={};Object.defineProperty(Be,"passive",{get:function(){qe=!0}}),window.addEventListener("test",Be,Be),window.removeEventListener("test",Be,Be)}catch(e){qe=!1}function ze(e,t,n,r,i,o,a,s,l){var c=Array.prototype.slice.call(arguments,3);try{t.apply(n,c)}catch(e){this.onError(e)}}var Ve=!1,We=null,He=!1,Ye=null,Xe={onError:function(e){Ve=!0,We=e}};function Ge(e,t,n,r,i,o,a,s,l){Ve=!1,We=null,ze.apply(Xe,arguments)}function $e(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{0!=(1026&(t=e).flags)&&(n=t.return),e=t.return}while(e)}return 3===t.tag?n:null}function Qe(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&(null!==(e=e.alternate)&&(t=e.memoizedState)),null!==t)return t.dehydrated}return null}function Ke(e){if($e(e)!==e)throw Error(a(188))}function Je(e){if(!(e=function(e){var t=e.alternate;if(!t){if(null===(t=$e(e)))throw Error(a(188));return t!==e?null:e}for(var n=e,r=t;;){var i=n.return;if(null===i)break;var o=i.alternate;if(null===o){if(null!==(r=i.return)){n=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===n)return Ke(i),e;if(o===r)return Ke(i),t;o=o.sibling}throw Error(a(188))}if(n.return!==r.return)n=i,r=o;else{for(var s=!1,l=i.child;l;){if(l===n){s=!0,n=i,r=o;break}if(l===r){s=!0,r=i,n=o;break}l=l.sibling}if(!s){for(l=o.child;l;){if(l===n){s=!0,n=o,r=i;break}if(l===r){s=!0,r=o,n=i;break}l=l.sibling}if(!s)throw Error(a(189))}}if(n.alternate!==r)throw Error(a(190))}if(3!==n.tag)throw Error(a(188));return n.stateNode.current===n?e:t}(e)))return null;for(var t=e;;){if(5===t.tag||6===t.tag)return t;if(t.child)t.child.return=t,t=t.child;else{if(t===e)break;for(;!t.sibling;){if(!t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}}return null}function Ze(e,t){for(var n=e.alternate;null!==t;){if(t===e||t===n)return!0;t=t.return}return!1}var et,tt,nt,rt,it=!1,ot=[],at=null,st=null,lt=null,ct=new Map,ut=new Map,pt=[],ft="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function dt(e,t,n,r,i){return{blockedOn:e,domEventName:t,eventSystemFlags:16|n,nativeEvent:i,targetContainers:[r]}}function ht(e,t){switch(e){case"focusin":case"focusout":at=null;break;case"dragenter":case"dragleave":st=null;break;case"mouseover":case"mouseout":lt=null;break;case"pointerover":case"pointerout":ct.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":ut.delete(t.pointerId)}}function mt(e,t,n,r,i,o){return null===e||e.nativeEvent!==o?(e=dt(t,n,r,i,o),null!==t&&(null!==(t=Jr(t))&&tt(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,null!==i&&-1===t.indexOf(i)&&t.push(i),e)}function yt(e){var t=Kr(e.target);if(null!==t){var n=$e(t);
vendor: 7,413 bytes, line 92
92if(null!==n)if(13===(t=n.tag)){if(null!==(t=Qe(n)))return e.blockedOn=t,void rt(e.lanePriority,(function(){o.unstable_runWithPriority(e.priority,(function(){nt(n)}))}))}else if(3===t&&n.stateNode.hydrate)return void(e.blockedOn=3===n.tag?n.stateNode.containerInfo:null)}e.blockedOn=null}function bt(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var n=Jt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n)return null!==(t=Jr(n))&&tt(t),e.blockedOn=n,!1;t.shift()}return!0}function vt(e,t,n){bt(e)&&n.delete(t)}function gt(){for(it=!1;0<ot.length;){var e=ot[0];if(null!==e.blockedOn){null!==(e=Jr(e.blockedOn))&&et(e);break}for(var t=e.targetContainers;0<t.length;){var n=Jt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n){e.blockedOn=n;break}t.shift()}null===e.blockedOn&&ot.shift()}null!==at&&bt(at)&&(at=null),null!==st&&bt(st)&&(st=null),null!==lt&&bt(lt)&&(lt=null),ct.forEach(vt),ut.forEach(vt)}function wt(e,t){e.blockedOn===t&&(e.blockedOn=null,it||(it=!0,o.unstable_scheduleCallback(o.unstable_NormalPriority,gt)))}function Ct(e){function t(t){return wt(t,e)}if(0<ot.length){wt(ot[0],e);for(var n=1;n<ot.length;n++){var r=ot[n];r.blockedOn===e&&(r.blockedOn=null)}}for(null!==at&&wt(at,e),null!==st&&wt(st,e),null!==lt&&wt(lt,e),ct.forEach(t),ut.forEach(t),n=0;n<pt.length;n++)(r=pt[n]).blockedOn===e&&(r.blockedOn=null);for(;0<pt.length&&null===(n=pt[0]).blockedOn;)yt(n),null===n.blockedOn&&pt.shift()}function _t(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var kt={animationend:_t("Animation","AnimationEnd"),animationiteration:_t("Animation","AnimationIteration"),animationstart:_t("Animation","AnimationStart"),transitionend:_t("Transition","TransitionEnd")},St={},Et={};function Tt(e){if(St[e])return St[e];if(!kt[e])return e;var t,n=kt[e];for(t in n)if(n.hasOwnProperty(t)&&t in Et)return St[e]=n[t];return e}p&&(Et=document.createElement("div").style,"AnimationEvent"in window||(delete kt.animationend.animation,delete kt.animationiteration.animation,delete kt.animationstart.animation),"TransitionEvent"in window||delete kt.transitionend.transition);var Ot=Tt("animationend"),Pt=Tt("animationiteration"),Rt=Tt("animationstart"),xt=Tt("transitionend"),Dt=new Map,jt=new Map,Mt=["abort","abort",Ot,"animationEnd",Pt,"animationIteration",Rt,"animationStart","canplay","canPlay","canplaythrough","canPlayThrough","durationchange","durationChange","emptied","emptied","encrypted","encrypted","ended","ended","error","error","gotpointercapture","gotPointerCapture","load","load","loadeddata","loadedData","loadedmetadata","loadedMetadata","loadstart","loadStart","lostpointercapture","lostPointerCapture","playing","playing","progress","progress","seeking","seeking","stalled","stalled","suspend","suspend","timeupdate","timeUpdate",xt,"transitionEnd","waiting","waiting"];function At(e,t){for(var n=0;n<e.length;n+=2){var r=e[n],i=e[n+1];i="on"+(i[0].toUpperCase()+i.slice(1)),jt.set(r,t),Dt.set(r,i),c(i,[r])}}(0,o.unstable_now)();var It=8;function Nt(e){if(0!=(1&e))return It=15,1;if(0!=(2&e))return It=14,2;if(0!=(4&e))return It=13,4;var t=24&e;return 0!==t?(It=12,t):0!=(32&e)?(It=11,32):0!==(t=192&e)?(It=10,t):0!=(256&e)?(It=9,256):0!==(t=3584&e)?(It=8,t):0!=(4096&e)?(It=7,4096):0!==(t=4186112&e)?(It=6,t):0!==(t=62914560&e)?(It=5,t):67108864&e?(It=4,67108864):0!=(134217728&e)?(It=3,134217728):0!==(t=805306368&e)?(It=2,t):0!=(1073741824&e)?(It=1,1073741824):(It=8,e)}function Lt(e,t){var n=e.pendingLanes;if(0===n)return It=0;var r=0,i=0,o=e.expiredLanes,a=e.suspendedLanes,s=e.pingedLanes;if(0!==o)r=o,i=It=15;else if(0!==(o=134217727&n)){var l=o&~a;0!==l?(r=Nt(l),i=It):0!==(s&=o)&&(r=Nt(s),i=It)}else 0!==(o=n&~a)?(r=Nt(o),i=It):0!==s&&(r=Nt(s),i=It);if(0===r)return 0;if(r=n&((0>(r=31-Vt(r))?0:1<<r)<<1)-1,0!==t&&t!==r&&0==(t&a)){if(Nt(t),i<=It)return t;It=i}if(0!==(t=e.entangledLanes))for(e=e.entanglements,t&=r;0<t;)i=1<<(n=31-Vt(t)),r|=e[n],t&=~i;return r}function Ft(e){return 0!==(e=-1073741825&e.pendingLanes)?e:1073741824&e?1073741824:0}function Ut(e,t){switch(e){case 15:return 1;case 14:return 2;case 12:return 0===(e=qt(24&~t))?Ut(10,t):e;case 10:return 0===(e=qt(192&~t))?Ut(8,t):e;case 8:return 0===(e=qt(3584&~t))&&(0===(e=qt(4186112&~t))&&(e=512)),e;case 2:return 0===(t=qt(805306368&~t))&&(t=268435456),t}throw Error(a(358,e))}function qt(e){return e&-e}function Bt(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function zt(e,t,n){e.pendingLanes|=t;var r=t-1;e.suspendedLanes&=r,e.pingedLanes&=r,(e=e.eventTimes)[t=31-Vt(t)]=n}var Vt=Math.clz32?Math.clz32:function(e){return 0===e?32:31-(Wt(e)/Ht|0)|0},Wt=Math.log,Ht=Math.LN2;var Yt=o.unstable_UserBlockingPriority,Xt=o.unstable_runWithPriority,Gt=!0;function $t(e,t,n,r){Ne||Ae();var i=Kt,o=Ne;Ne=!0;try{Me(i,e,t,n,r)}finally{(Ne=o)||Fe()}}function Qt(e,t,n,r){Xt(Yt,Kt.bind(null,e,t,n,r))}function Kt(e,t,n,r){var i;if(Gt)if((i=0==(4&t))&&0<ot.length&&-1<ft.indexOf(e))e=dt(null,e,t,n,r),ot.push(e);else{var o=Jt(e,t,n,r);if(null===o)i&&ht(e,r);else{if(i){if(-1<ft.indexOf(e))return e=dt(o,e,t,n,r),void ot.push(e);if(function(e,t,n,r,i){switch(t){case"focusin":return at=mt(at,e,t,n,r,i),!0;case"dragenter":return st=mt(st,e,t,n,r,i),!0;case"mouseover":return lt=mt(lt,e,t,n,r,i),!0;case"pointerover":var o=i.pointerId;return ct.set(o,mt(ct.get(o)||null,e,t,n,r,i)),!0;case"gotpointercapture":return o=i.pointerId,ut.set(o,mt(ut.get(o)||null,e,t,n,r,i)),!0}return!1}(o,e,t,n,r))return;ht(e,r)}xr(e,t,r,null,n)}}}function Jt(e,t,n,r){var i=Ee(r);if(null!==(i=Kr(i))){var o=$e(i);if(null===o)i=null;else{var a=o.tag;if(13===a){if(null!==(i=Qe(o)))return i;i=null}else if(3===a){if(o.stateNode.hydrate)return 3===o.tag?o.stateNode.containerInfo:null;i=null}else o!==i&&(i=null)}}return xr(e,t,r,i,n),null}var Zt=null,en=null,tn=null;function nn(){if(tn)return tn;var e,t,n=en,r=n.length,i="value"in Zt?Zt.value:Zt.textContent,o=i.length;for(e=0;e<r&&n[e]===i[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===i[o-t];t++);return tn=i.slice(e,1<t?1-t:void 0)}function rn(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function on(){return!0}function an(){return!1}function sn(e){function t(t,n,r,i,o){for(var a in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=o,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(i):i[a]);return this.isDefaultPrevented=(null!=i.defaultPrevented?i.defaultPrevented:!1===i.returnValue)?on:an,this.isPropagationStopped=an,this}return i(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!=typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=on)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!=typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=on)},persist:function(){},isPersistent:on}),t}var ln,cn,un,pn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},fn=sn(pn),dn=i({},pn,{view:0,detail:0}),hn=sn(dn),mn=i({},dn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Tn,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.from
vendor: 8,805 bytes, line 92
92Element===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==un&&(un&&"mousemove"===e.type?(ln=e.screenX-un.screenX,cn=e.screenY-un.screenY):cn=ln=0,un=e),ln)},movementY:function(e){return"movementY"in e?e.movementY:cn}}),yn=sn(mn),bn=sn(i({},mn,{dataTransfer:0})),vn=sn(i({},dn,{relatedTarget:0})),gn=sn(i({},pn,{animationName:0,elapsedTime:0,pseudoElement:0})),wn=sn(i({},pn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}})),Cn=sn(i({},pn,{data:0})),_n={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},kn={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Sn={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function En(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=Sn[e])&&!!t[e]}function Tn(){return En}var On=sn(i({},dn,{key:function(e){if(e.key){var t=_n[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=rn(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?kn[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Tn,charCode:function(e){return"keypress"===e.type?rn(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?rn(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}})),Pn=sn(i({},mn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Rn=sn(i({},dn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Tn})),xn=sn(i({},pn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Dn=sn(i({},mn,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),jn=[9,13,27,32],Mn=p&&"CompositionEvent"in window,An=null;p&&"documentMode"in document&&(An=document.documentMode);var In=p&&"TextEvent"in window&&!An,Nn=p&&(!Mn||An&&8<An&&11>=An),Ln=String.fromCharCode(32),Fn=!1;function Un(e,t){switch(e){case"keyup":return-1!==jn.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function qn(e){return"object"==typeof(e=e.detail)&&"data"in e?e.data:null}var Bn=!1;var zn={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Vn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!zn[e.type]:"textarea"===t}function Wn(e,t,n,r){xe(r),0<(t=jr(t,"onChange")).length&&(n=new fn("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Hn=null,Yn=null;function Xn(e){Sr(e,0)}function Gn(e){if(K(Zr(e)))return e}function $n(e,t){if("change"===e)return t}var Qn=!1;if(p){var Kn;if(p){var Jn="oninput"in document;if(!Jn){var Zn=document.createElement("div");Zn.setAttribute("oninput","return;"),Jn="function"==typeof Zn.oninput}Kn=Jn}else Kn=!1;Qn=Kn&&(!document.documentMode||9<document.documentMode)}function er(){Hn&&(Hn.detachEvent("onpropertychange",tr),Yn=Hn=null)}function tr(e){if("value"===e.propertyName&&Gn(Yn)){var t=[];if(Wn(t,Yn,e,Ee(e)),e=Xn,Ne)e(t);else{Ne=!0;try{je(e,t)}finally{Ne=!1,Fe()}}}}function nr(e,t,n){"focusin"===e?(er(),Yn=n,(Hn=t).attachEvent("onpropertychange",tr)):"focusout"===e&&er()}function rr(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return Gn(Yn)}function ir(e,t){if("click"===e)return Gn(t)}function or(e,t){if("input"===e||"change"===e)return Gn(t)}var ar="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},sr=Object.prototype.hasOwnProperty;function lr(e,t){if(ar(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++)if(!sr.call(t,n[r])||!ar(e[n[r]],t[n[r]]))return!1;return!0}function cr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function ur(e,t){var n,r=cr(e);for(e=0;r;){if(3===r.nodeType){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=cr(r)}}function pr(){for(var e=window,t=J();t instanceof e.HTMLIFrameElement;){try{var n="string"==typeof t.contentWindow.location.href}catch(e){n=!1}if(!n)break;t=J((e=t.contentWindow).document)}return t}function fr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}var dr=p&&"documentMode"in document&&11>=document.documentMode,hr=null,mr=null,yr=null,br=!1;function vr(e,t,n){var r=n.window===n?n.document:9===n.nodeType?n:n.ownerDocument;br||null==hr||hr!==J(r)||("selectionStart"in(r=hr)&&fr(r)?r={start:r.selectionStart,end:r.selectionEnd}:r={anchorNode:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset},yr&&lr(yr,r)||(yr=r,0<(r=jr(mr,"onSelect")).length&&(t=new fn("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=hr)))}At("cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focusin focus focusout blur input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange".split(" "),0),At("drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel".split(" "),1),At(Mt,2);for(var gr="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),wr=0;wr<gr.length;wr++)jt.set(gr[wr],0);u("onMouseEnter",["mouseout","mouseover"]),u("onMouseLeave",["mouseout","mouseover"]),u("onPointerEnter",["pointerout","pointerover"]),u("onPointerLeave",["pointerout","pointerover"]),c("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),c("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),c("onBeforeInput",["compositionend","keypress","textInput","paste"]),c("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),c("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),c("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Cr="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),_r=new Set("cancel close invalid load scroll toggle".split(" ").concat(Cr));function kr(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,function(e,t,n,r,i,o,s,l,c){if(Ge.apply(this,arguments),Ve){if(!Ve)throw Error(a(198));var u=We;Ve=!1,We=null,He||(He=!0,Ye=u)}}(r,t,void 0,e),e.currentTarget=null}function Sr(e,t){t=0!=(4&t);for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;e:{var o=void 0;if(t)for(var a=r.length-1;0<=a;a--){var s=r[a],l=s.instance,c=s.currentTarget;if(s=s.listener,l!==o&&i.isPropagationStopped())break e;kr(i,s,c),o=l}else for(a=0;a<r.length;a++){if(l=(s=r[a]).instance,c=s.currentTarget,s=s.listener,l!==o&&i.isPropagationStopped())break e;kr(i,s,c),o=l}}}if(He)throw e=Ye,He=!1,Ye=null,e}function Er(e,t){var n=ti(t),r=e+"__bubble";n.has(r)||(Rr(t,e,2,!1),n.add(r))}var Tr="_reactListening"+Math.random().toString(36).slice(2);
vendor: 4,485 bytes, line 92
92function Or(e){e[Tr]||(e[Tr]=!0,s.forEach((function(t){_r.has(t)||Pr(t,!1,e,null),Pr(t,!0,e,null)})))}function Pr(e,t,n,r){var i=4<arguments.length&&void 0!==arguments[4]?arguments[4]:0,o=n;if("selectionchange"===e&&9!==n.nodeType&&(o=n.ownerDocument),null!==r&&!t&&_r.has(e)){if("scroll"!==e)return;i|=2,o=r}var a=ti(o),s=e+"__"+(t?"capture":"bubble");a.has(s)||(t&&(i|=4),Rr(o,e,i,t),a.add(s))}function Rr(e,t,n,r){var i=jt.get(t);switch(void 0===i?2:i){case 0:i=$t;break;case 1:i=Qt;break;default:i=Kt}n=i.bind(null,t,n,e),i=void 0,!qe||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(i=!0),r?void 0!==i?e.addEventListener(t,n,{capture:!0,passive:i}):e.addEventListener(t,n,!0):void 0!==i?e.addEventListener(t,n,{passive:i}):e.addEventListener(t,n,!1)}function xr(e,t,n,r,i){var o=r;if(0==(1&t)&&0==(2&t)&&null!==r)e:for(;;){if(null===r)return;var a=r.tag;if(3===a||4===a){var s=r.stateNode.containerInfo;if(s===i||8===s.nodeType&&s.parentNode===i)break;if(4===a)for(a=r.return;null!==a;){var l=a.tag;if((3===l||4===l)&&((l=a.stateNode.containerInfo)===i||8===l.nodeType&&l.parentNode===i))return;a=a.return}for(;null!==s;){if(null===(a=Kr(s)))return;if(5===(l=a.tag)||6===l){r=o=a;continue e}s=s.parentNode}}r=r.return}!function(e,t,n){if(Le)return e(t,n);Le=!0;try{Ie(e,t,n)}finally{Le=!1,Fe()}}((function(){var r=o,i=Ee(n),a=[];e:{var s=Dt.get(e);if(void 0!==s){var l=fn,c=e;switch(e){case"keypress":if(0===rn(n))break e;case"keydown":case"keyup":l=On;break;case"focusin":c="focus",l=vn;break;case"focusout":c="blur",l=vn;break;case"beforeblur":case"afterblur":l=vn;break;case"click":if(2===n.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":l=yn;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":l=bn;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":l=Rn;break;case Ot:case Pt:case Rt:l=gn;break;case xt:l=xn;break;case"scroll":l=hn;break;case"wheel":l=Dn;break;case"copy":case"cut":case"paste":l=wn;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":l=Pn}var u=0!=(4&t),p=!u&&"scroll"===e,f=u?null!==s?s+"Capture":null:s;u=[];for(var d,h=r;null!==h;){var m=(d=h).stateNode;if(5===d.tag&&null!==m&&(d=m,null!==f&&(null!=(m=Ue(h,f))&&u.push(Dr(h,m,d)))),p)break;h=h.return}0<u.length&&(s=new l(s,c,null,n,i),a.push({event:s,listeners:u}))}}if(0==(7&t)){if(l="mouseout"===e||"pointerout"===e,(!(s="mouseover"===e||"pointerover"===e)||0!=(16&t)||!(c=n.relatedTarget||n.fromElement)||!Kr(c)&&!c[$r])&&(l||s)&&(s=i.window===i?i:(s=i.ownerDocument)?s.defaultView||s.parentWindow:window,l?(l=r,null!==(c=(c=n.relatedTarget||n.toElement)?Kr(c):null)&&(c!==(p=$e(c))||5!==c.tag&&6!==c.tag)&&(c=null)):(l=null,c=r),l!==c)){if(u=yn,m="onMouseLeave",f="onMouseEnter",h="mouse","pointerout"!==e&&"pointerover"!==e||(u=Pn,m="onPointerLeave",f="onPointerEnter",h="pointer"),p=null==l?s:Zr(l),d=null==c?s:Zr(c),(s=new u(m,h+"leave",l,n,i)).target=p,s.relatedTarget=d,m=null,Kr(i)===r&&((u=new u(f,h+"enter",c,n,i)).target=d,u.relatedTarget=p,m=u),p=m,l&&c)e:{for(f=c,h=0,d=u=l;d;d=Mr(d))h++;for(d=0,m=f;m;m=Mr(m))d++;for(;0<h-d;)u=Mr(u),h--;for(;0<d-h;)f=Mr(f),d--;for(;h--;){if(u===f||null!==f&&u===f.alternate)break e;u=Mr(u),f=Mr(f)}u=null}else u=null;null!==l&&Ar(a,s,l,u,!1),null!==c&&null!==p&&Ar(a,p,c,u,!0)}if("select"===(l=(s=r?Zr(r):window).nodeName&&s.nodeName.toLowerCase())||"input"===l&&"file"===s.type)var y=$n;else if(Vn(s))if(Qn)y=or;else{y=rr;var b=nr}else(l=s.nodeName)&&"input"===l.toLowerCase()&&("checkbox"===s.type||"radio"===s.type)&&(y=ir);switch(y&&(y=y(e,r))?Wn(a,y,n,i):(b&&b(e,s,r),"focusout"===e&&(b=s._wrapperState)&&b.controlled&&"number"===s.type&&ie(s,"number",s.value)),b=r?Zr(r):window,e){case"focusin":(Vn(b)||"true"===b.contentEditable)&&(hr=b,mr=r,yr=null);break;case"focusout":yr=mr=hr=null;break;case"mousedown":br=!0;break;case"contextmenu":case"mouseup":case"dragend":br=!1,vr(a,n,i);break;case"selectionchange":if(dr)break;case"keydown":case"keyup":vr(a,n,i)}var v;if(Mn)e:{switch(e){case"compositionstart":var g="onCompositionStart";break e;case"compositionend":g="onCompositionEnd";break e;case"compositionupdate":g="onCompositionUpdate";break e}g=void 0}else Bn?Un(e,n)&&(g="onCompositionEnd"):"keydown"===e&&229===n.keyCode&&(g="onCompositionStart");
vendor: 18,844 bytes, line 92
92g&&(Nn&&"ko"!==n.locale&&(Bn||"onCompositionStart"!==g?"onCompositionEnd"===g&&Bn&&(v=nn()):(en="value"in(Zt=i)?Zt.value:Zt.textContent,Bn=!0)),0<(b=jr(r,g)).length&&(g=new Cn(g,e,null,n,i),a.push({event:g,listeners:b}),v?g.data=v:null!==(v=qn(n))&&(g.data=v))),(v=In?function(e,t){switch(e){case"compositionend":return qn(t);case"keypress":return 32!==t.which?null:(Fn=!0,Ln);case"textInput":return(e=t.data)===Ln&&Fn?null:e;default:return null}}(e,n):function(e,t){if(Bn)return"compositionend"===e||!Mn&&Un(e,t)?(e=nn(),tn=en=Zt=null,Bn=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Nn&&"ko"!==t.locale?null:t.data;default:return null}}(e,n))&&(0<(r=jr(r,"onBeforeInput")).length&&(i=new Cn("onBeforeInput","beforeinput",null,n,i),a.push({event:i,listeners:r}),i.data=v))}Sr(a,t)}))}function Dr(e,t,n){return{instance:e,listener:t,currentTarget:n}}function jr(e,t){for(var n=t+"Capture",r=[];null!==e;){var i=e,o=i.stateNode;5===i.tag&&null!==o&&(i=o,null!=(o=Ue(e,n))&&r.unshift(Dr(e,o,i)),null!=(o=Ue(e,t))&&r.push(Dr(e,o,i))),e=e.return}return r}function Mr(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag);return e||null}function Ar(e,t,n,r,i){for(var o=t._reactName,a=[];null!==n&&n!==r;){var s=n,l=s.alternate,c=s.stateNode;if(null!==l&&l===r)break;5===s.tag&&null!==c&&(s=c,i?null!=(l=Ue(n,o))&&a.unshift(Dr(n,l,s)):i||null!=(l=Ue(n,o))&&a.push(Dr(n,l,s))),n=n.return}0!==a.length&&e.push({event:t,listeners:a})}function Ir(){}var Nr=null,Lr=null;function Fr(e,t){switch(e){case"button":case"input":case"select":case"textarea":return!!t.autoFocus}return!1}function Ur(e,t){return"textarea"===e||"option"===e||"noscript"===e||"string"==typeof t.children||"number"==typeof t.children||"object"==typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var qr="function"==typeof setTimeout?setTimeout:void 0,Br="function"==typeof clearTimeout?clearTimeout:void 0;function zr(e){1===e.nodeType?e.textContent="":9===e.nodeType&&(null!=(e=e.body)&&(e.textContent=""))}function Vr(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break}return e}function Wr(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("$"===n||"$!"===n||"$?"===n){if(0===t)return e;t--}else"/$"===n&&t++}e=e.previousSibling}return null}var Hr=0;var Yr=Math.random().toString(36).slice(2),Xr="__reactFiber$"+Yr,Gr="__reactProps$"+Yr,$r="__reactContainer$"+Yr,Qr="__reactEvents$"+Yr;function Kr(e){var t=e[Xr];if(t)return t;for(var n=e.parentNode;n;){if(t=n[$r]||n[Xr]){if(n=t.alternate,null!==t.child||null!==n&&null!==n.child)for(e=Wr(e);null!==e;){if(n=e[Xr])return n;e=Wr(e)}return t}n=(e=n).parentNode}return null}function Jr(e){return!(e=e[Xr]||e[$r])||5!==e.tag&&6!==e.tag&&13!==e.tag&&3!==e.tag?null:e}function Zr(e){if(5===e.tag||6===e.tag)return e.stateNode;throw Error(a(33))}function ei(e){return e[Gr]||null}function ti(e){var t=e[Qr];return void 0===t&&(t=e[Qr]=new Set),t}var ni=[],ri=-1;function ii(e){return{current:e}}function oi(e){0>ri||(e.current=ni[ri],ni[ri]=null,ri--)}function ai(e,t){ri++,ni[ri]=e.current,e.current=t}var si={},li=ii(si),ci=ii(!1),ui=si;function pi(e,t){var n=e.type.contextTypes;if(!n)return si;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i,o={};for(i in n)o[i]=t[i];return r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function fi(e){return null!=(e=e.childContextTypes)}function di(){oi(ci),oi(li)}function hi(e,t,n){if(li.current!==si)throw Error(a(168));ai(li,t),ai(ci,n)}function mi(e,t,n){var r=e.stateNode;if(e=t.childContextTypes,"function"!=typeof r.getChildContext)return n;for(var o in r=r.getChildContext())if(!(o in e))throw Error(a(108,X(t)||"Unknown",o));return i({},n,r)}function yi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||si,ui=li.current,ai(li,e),ai(ci,ci.current),!0}function bi(e,t,n){var r=e.stateNode;if(!r)throw Error(a(169));n?(e=mi(e,t,ui),r.__reactInternalMemoizedMergedChildContext=e,oi(ci),oi(li),ai(li,e)):oi(ci),ai(ci,n)}var vi=null,gi=null,wi=o.unstable_runWithPriority,Ci=o.unstable_scheduleCallback,_i=o.unstable_cancelCallback,ki=o.unstable_shouldYield,Si=o.unstable_requestPaint,Ei=o.unstable_now,Ti=o.unstable_getCurrentPriorityLevel,Oi=o.unstable_ImmediatePriority,Pi=o.unstable_UserBlockingPriority,Ri=o.unstable_NormalPriority,xi=o.unstable_LowPriority,Di=o.unstable_IdlePriority,ji={},Mi=void 0!==Si?Si:function(){},Ai=null,Ii=null,Ni=!1,Li=Ei(),Fi=1e4>Li?Ei:function(){return Ei()-Li};function Ui(){switch(Ti()){case Oi:return 99;case Pi:return 98;case Ri:return 97;case xi:return 96;case Di:return 95;default:throw Error(a(332))}}function qi(e){switch(e){case 99:return Oi;case 98:return Pi;case 97:return Ri;case 96:return xi;case 95:return Di;default:throw Error(a(332))}}function Bi(e,t){return e=qi(e),wi(e,t)}function zi(e,t,n){return e=qi(e),Ci(e,t,n)}function Vi(){if(null!==Ii){var e=Ii;Ii=null,_i(e)}Wi()}function Wi(){if(!Ni&&null!==Ai){Ni=!0;var e=0;try{var t=Ai;Bi(99,(function(){for(;e<t.length;e++){var n=t[e];do{n=n(!0)}while(null!==n)}})),Ai=null}catch(t){throw null!==Ai&&(Ai=Ai.slice(e+1)),Ci(Oi,Vi),t}finally{Ni=!1}}}var Hi=C.ReactCurrentBatchConfig;function Yi(e,t){if(e&&e.defaultProps){for(var n in t=i({},t),e=e.defaultProps)void 0===t[n]&&(t[n]=e[n]);return t}return t}var Xi=ii(null),Gi=null,$i=null,Qi=null;function Ki(){Qi=$i=Gi=null}function Ji(e){var t=Xi.current;oi(Xi),e.type._context._currentValue=t}function Zi(e,t){for(;null!==e;){var n=e.alternate;if((e.childLanes&t)===t){if(null===n||(n.childLanes&t)===t)break;n.childLanes|=t}else e.childLanes|=t,null!==n&&(n.childLanes|=t);e=e.return}}function eo(e,t){Gi=e,Qi=$i=null,null!==(e=e.dependencies)&&null!==e.firstContext&&(0!=(e.lanes&t)&&(ja=!0),e.firstContext=null)}function to(e,t){if(Qi!==e&&!1!==t&&0!==t)if("number"==typeof t&&1073741823!==t||(Qi=e,t=1073741823),t={context:e,observedBits:t,next:null},null===$i){if(null===Gi)throw Error(a(308));$i=t,Gi.dependencies={lanes:0,firstContext:t,responders:null}}else $i=$i.next=t;return e._currentValue}var no=!1;function ro(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null},effects:null}}function io(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function oo(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function ao(e,t){if(null!==(e=e.updateQueue)){var n=(e=e.shared).pending;null===n?t.next=t:(t.next=n.next,n.next=t),e.pending=t}}function so(e,t){var n=e.updateQueue,r=e.alternate;if(null!==r&&n===(r=r.updateQueue)){var i=null,o=null;if(null!==(n=n.firstBaseUpdate)){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};null===o?i=o=a:o=o.next=a,n=n.next}while(null!==n);null===o?i=o=t:o=o.next=t}else i=o=t;return n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:o,shared:r.shared,effects:r.effects},void(e.updateQueue=n)}null===(e=n.lastBaseUpdate)?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function lo(e,t,n,r){var o=e.updateQueue;no=!1;var a=o.firstBaseUpdate,s=o.lastBaseUpdate,l=o.shared.pending;if(null!==l){o.shared.pending=null;var c=l,u=c.next;c.next=null,null===s?a=u:s.next=u,s=c;var p=e.alternate;if(null!==p){var f=(p=p.updateQueue).lastBaseUpdate;f!==s&&(null===f?p.firstBaseUpdate=u:f.next=u,p.lastBaseUpdate=c)}}if(null!==a){for(f=o.baseState,s=0,p=u=c=null;;){l=a.lane;var d=a.eventTime;if((r&l)===l){null!==p&&(p=p.next={eventTime:d,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var h=e,m=a;switch(l=t,d=n,m.tag){case 1:if("function"==typeof(h=m.payload)){f=h.call(d,f,l);break e}f=h;break e;case 3:h.flags=-4097&h.flags|64;case 0:if(null==(l="function"==typeof(h=m.payload)?h.call(d,f,l):h))break e;f=i({},f,l);break e;case 2:no=!0}}null!==a.callback&&(e.flags|=32,null===(l=o.effects)?o.effects=[a]:l.push(a))}else d={eventTime:d,lane:l,tag:a.tag,payload:a.payload,callback:a.callback,next:null},null===p?(u=p=d,c=f):p=p.next=d,s|=l;if(null===(a=a.next)){if(null===(l=o.shared.pending))break;a=l.next,l.next=null,o.lastBaseUpdate=l,o.shared.pending=null}}null===p&&(c=f),o.baseState=c,o.firstBaseUpdate=u,o.lastBaseUpdate=p,As|=s,e.lanes=s,e.memoizedState=f}}function co(e,t,n){if(e=t.effects,t.effects=null,null!==e)for(t=0;t<e.length;t++){var r=e[t],i=r.callback;if(null!==i){if(r.callback=null,r=n,"function"!=typeof i)throw Error(a(191,i));i.call(r)}}}var uo=(new r.Component).refs;function po(e,t,n,r){n=null==(n=n(r,t=e.memoizedState))?t:i({},t,n),e.memoizedState=n,0===e.lanes&&(e.updateQueue.baseState=n)}var fo={isMounted:function(e){return!!(e=e._reactInternals)&&$e(e)===e},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=ol(),i=al(e),o=oo(r,i);o.payload=t,null!=n&&(o.callback=n),ao(e,o),sl(e,i,r)},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=ol(),i=al(e),o=oo(r,i);o.tag=1,o.payload=t,null!=n&&(o.callback=n),ao(e,o),sl(e,i,r)},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ol(),r=al(e),i=oo(n,r);i.tag=2,null!=t&&(i.callback=t),ao(e,i),sl(e,r,n)}};function ho(e,t,n,r,i,o,a){return"function"==typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(r,o,a):!t.prototype||!t.prototype.isPureReactComponent||(!lr(n,r)||!lr(i,o))}function mo(e,t,n){var r=!1,i=si,o=t.contextType;return"object"==typeof o&&null!==o?o=to(o):(i=fi(t)?ui:li.current,o=(r=null!=(r=t.contextTypes))?pi(e,i):si),t=new t(n,o),e.memoizedState=null!==t.state&&void 0!==t.state?t.state:null,t.updater=fo,e.stateNode=t,t._reactInternals=e,r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=o),t}function yo(e,t,n,r){e=t.state,"function"==typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(n,r),"function"==typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&fo.enqueueReplaceState(t,t.state,null)}function bo(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs=uo,ro(e);var o=t.contextType;"object"==typeof o&&null!==o?i.context=to(o):(o=fi(t)?ui:li.current,i.context=pi(e,o)),lo(e,n,i,r),i.state=e.memoizedState,"function"==typeof(o=t.getDerivedStateFromProps)&&(po(e,t,o,n),i.state=e.memoizedState),"function"==typeof t.getDerivedStateFromProps||"function"==typeof i.getSnapshotBeforeUpdate||"function"!=typeof i.UNSAFE_componentWillMount&&"function"!=typeof i.componentWillMount||(t=i.state,"function"==typeof i.componentWillMount&&i.componentWillMount(),"function"==typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount(),t!==i.state&&fo.enqueueReplaceState(i,i.state,null),lo(e,n,i,r),i.state=e.memoizedState),"function"==typeof i.componentDidMount&&(e.flags|=4)}var vo=Array.isArray;function go(e,t,n){if(null!==(e=n.ref)&&"function"!=typeof e&&"object"!=typeof e){if(n._owner){if(n=n._owner){if(1!==n.tag)throw Error(a(309));var r=n.stateNode}if(!r)throw Error(a(147,e));var i=""+e;return null!==t&&null!==t.ref&&"function"==typeof t.ref&&t.ref._stringRef===i?t.ref:((t=function(e){var t=r.refs;t===uo&&(t=r.refs={}),null===e?delete t[i]:t[i]=e})._stringRef=i,t)}if("string"!=typeof e)throw Error(a(284));if(!n._owner)throw Error(a(290,e))}return e}function wo(e,t){if("textarea"!==e.type)throw Error(a(31,"[object Object]"===Object.prototype.toString.call(t)?"object with keys {"+Object.keys(t).join(", ")+"}":t))}function Co(e){function t(t,n){if(e){var r=t.lastEffect;null!==r?(r.nextEffect=n,t.lastEffect=n):t.firstEffect=t.lastEffect=n,n.nextEffect=null,n.flags=8}}function n(n,r){if(!e)return null;for(;null!==r;)t(n,r),r=r.sibling;return null}function r(e,t){for(e=new Map;null!==t;)null!==t.key?e.set(t.key,t):e.set(t.index,t),t=t.sibling;return e}function i(e,t){return(e=Ul(e,t)).index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?null!==(r=t.alternate)?(r=r.index)<n?(t.flags=2,n):r:(t.flags=2,n):n}function s(t){return e&&null===t.alternate&&(t.flags=2),t}function l(e,t,n,r){return null===t||6!==t.tag?((t=Vl(n,e.mode,r)).return=e,t):((t=i(t,n)).return=e,t)}function c(e,t,n,r){return null!==t&&t.elementType===n.type?((r=i(t,n.props)).ref=go(e,t,n),r.return=e,r):((r=ql(n.type,n.key,n.props,null,e.mode,r)).ref=go(e,t,n),r.return=e,r)}function u(e,t,n,r){return null===t||4!==t.tag||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?((t=Wl(n,e.mode,r)).return=e,t):((t=i(t,n.children||[])).return=e,t)}function p(e,t,n,r,o){return null===t||7!==t.tag?((t=Bl(n,e.mode,r,o)).return=e,t):((t=i(t,n)).return=e,t)}function f(e,t,n){if("string"==typeof t||"number"==typeof t)return(t=Vl(""+t,e.mode,n)).return=e,t;if("object"==typeof t&&null!==t){switch(t.$$typeof){case _:return(n=ql(t.type,t.key,t.props,null,e.mode,n)).ref=go(e,null,t),n.return=e,n;case k:return(t=Wl(t,e.mode,n)).return=e,t}if(vo(t)||z(t))return(t=Bl(t,e.mode,n,null)).return=e,t;wo(e,t)}return null}function d(e,t,n,r){var i=null!==t?t.key:null;if("string"==typeof n||"number"==typeof n)return null!==i?null:l(e,t,""+n,r);if("object"==typeof n&&null!==n){switch(n.$$typeof){case _:return n.key===i?n.type===S?p(e,t,n.props.children,r,i):c(e,t,n,r):null;case k:return n.key===i?u(e,t,n,r):null}if(vo(n)||z(n))return null!==i?null:p(e,t,n,r,null);wo(e,n)}return null}function h(e,t,n,r,i){if("string"==typeof r||"number"==typeof r)return l(t,e=e.get(n)||null,""+r,i);if("object"==typeof r&&null!==r){switch(r.$$typeof){case _:return e=e.get(null===r.key?n:r.key)||null,r.type===S?p(t,e,r.props.children,i,r.key):c(t,e,r,i);case k:return u(t,e=e.get(null===r.key?n:r.key)||null,r,i)}if(vo(r)||z(r))return p(t,e=e.get(n)||null,r,i,null);wo(t,r)}return null}function m(i,a,s,l){for(var c=null,u=null,p=a,m=a=0,y=null;null!==p&&m<s.length;m++){p.index>m?(y=p,p=null):y=p.sibling;var b=d(i,p,s[m],l);if(null===b){null===p&&(p=y);break}e&&p&&null===b.alternate&&t(i,p),a=o(b,a,m),null===u?c=b:u.sibling=b,u=b,p=y}if(m===s.length)return n(i,p),c;if(null===p){for(;m<s.length;m++)null!==(p=f(i,s[m],l))&&(a=o(p,a,m),null===u?c=p:u.sibling=p,u=p);return c}for(p=r(i,p);m<s.length;m++)null!==(y=h(p,i,m,s[m],l))&&(e&&null!==y.alternate&&p.delete(null===y.key?m:y.key),a=o(y,a,m),null===u?c=y:u.sibling=y,u=y);return e&&p.forEach((function(e){return t(i,e)})),c}function y(i,s,l,c){var u=z(l);if("function"!=typeof u)throw Error(a(150));if(null==(l=u.call(l)))throw Error(a(151));for(var p=u=null,m=s,y=s=0,b=null,v=l.next();null!==m&&!v.done;y++,v=l.next()){m.index>y?(b=m,m=null):b=m.sibling;var g=d(i,m,v.value,c);if(null===g){null===m&&(m=b);break}e&&m&&null===g.alternate&&t(i,m),s=o(g,s,y),null===p?u=g:p.sibling=g,p=g,m=b}if(v.done)return n(i,m),u;if(null===m){for(;!v.done;y++,v=l.next())null!==(v=f(i,v.value,c))&&(s=o(v,s,y),null===p?u=v:p.sibling=v,p=v);return u}for(m=r(i,m);!v.done;y++,v=l.next())null!==(v=h(m,i,y,v.value,c))&&(e&&null!==v.alternate&&m.delete(null===v.key?y:v.key),s=o(v,s,y),null===p?u=v:p.sibling=v,p=v);return e&&m.forEach((function(e){return t(i,e)})),u}return function(e,r,o,l){var c="object"==typeof o&&null!==o&&o.type===S&&null===o.key;c&&(o=o.props.children);var u="object"==typeof o&&null!==o;if(u)switch(o.$$typeof){case _:e:{for(u=o.key,c=r;null!==c;){if(c.key===u){switch(c.tag){case 7:if(o.type===S){n(e,c.sibling),(r=i(c,o.props.children)).return=e,e=r;break e}break;default:if(c.elementType===o.type){n(e,c.sibling),(r=i(c,o.props)).ref=go(e,c,o),r.return=e,e=r;break e}}n(e,c);break}t(e,c),c=c.sibling}o.type===S?((r=Bl(o.props.children,e.mode,l,o.key)).return=e,e=r):((l=ql(o.type,o.key,o.props,null,e.mode,l)).ref=go(e,r,o),l.return=e,e=l)}return s(e);case k:e:{for(c=o.key;null!==r;){if(r.key===c){if(4===r.tag&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),(r=i(r,o.children||[])).return=e,e=r;break e}n(e,r);break}t(e,r),r=r.sibling}(r=Wl(o,e.mode,l)).return=e,e=r}return s(e)}if("string"==typeof o||"number"==typeof o)return o=""+o,null!==r&&6===r.tag?(n(e,r.sibling),(r=i(r,o)).return=e,e=r):(n(e,r),(r=Vl(o,e.mode,l)).return=e,e=r),s(e);if(vo(o))return m(e,r,o,l);if(z(o))return y(e,r,o,l);if(u&&wo(e,o),void 0===o&&!c)switch(e.tag){case 1:case 22:case 0:case 11:case 15:throw Error(a(152,X(e.type)||"Component"))}return n(e,r)}}var _o=Co(!0),ko=Co(!1),So={},Eo=ii(So),To=ii(So),Oo=ii(So);function Po(e){if(e===So)throw Error(a(174));return e}function Ro(e,t){switch(ai(Oo,t),ai(To,e),ai(Eo,So),e=t.nodeType){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:he(null,"");break;default:t=he(t=(e=8===e?t.parentNode:t).namespaceURI||null,e=e.tagName)}oi(Eo),ai(Eo,t)}function xo(){oi(Eo),oi(To),oi(Oo)}function Do(e){Po(Oo.current);var t=Po(Eo.current),n=he(t,e.type);t!==n&&(ai(To,e),ai(Eo,n))}function jo(e){To.current===e&&(oi(Eo),oi(To))}var Mo=ii(0);function Ao(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||"$?"===n.data||"$!"===n.data))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(0!=(64&t.flags))return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Io=null,No=null,Lo=!1;function Fo(e,t){var n=Ll(5,null,null,0);n.elementType="DELETED",n.type="DELETED",n.stateNode=t,n.return=e,n.flags=8,null!==e.lastEffect?(e.lastEffect.nextEffect=n,e.lastEffect=n):e.firstEffect=e.lastEffect=n}function Uo(e,t){switch(e.tag){case 5:var n=e.type;return null!==(t=1!==t.nodeType||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t)&&(e.stateNode=t,!0);case 6:return null!==(t=""===e.pendingProps||3!==t.nodeType?null:t)&&(e.stateNode=t,!0);case 13:default:return!1}}function qo(e){if(Lo){var t=No;if(t){var n=t;if(!Uo(e,t)){if(!(t=Vr(n.nextSibling))||!Uo(e,t))return e.flags=-1025&e.flags|2,Lo=!1,void(Io=e);Fo(Io,n)}Io=e,No=Vr(t.firstChild)}else e.flags=-1025&e.flags|2,Lo=!1,Io=e}}function Bo(e){for(e=e.return;null!==e&&5!==e.tag&&3!==e.tag&&13!==e.tag;)e=e.return;Io=e}function zo(e){if(e!==Io)return!1;if(!Lo)return Bo(e),Lo=!0,!1;var t=e.type;if(5!==e.tag||"head"!==t&&"body"!==t&&!Ur(t,e.memoizedProps))for(t=No;t;)Fo(e,t),t=Vr(t.nextSibling);if(Bo(e),13===e.tag){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(a(317));e:{for(e=e.nextSibling,t=0;e;){if(8===e.nodeType){var n=e.data;if("/$"===n){if(0===t){No=Vr(e.nextSibling);break e}t--}
vendor: 7,733 bytes, line 92
92else"$"!==n&&"$!"!==n&&"$?"!==n||t++}e=e.nextSibling}No=null}}else No=Io?Vr(e.stateNode.nextSibling):null;return!0}function Vo(){No=Io=null,Lo=!1}var Wo=[];function Ho(){for(var e=0;e<Wo.length;e++)Wo[e]._workInProgressVersionPrimary=null;Wo.length=0}var Yo=C.ReactCurrentDispatcher,Xo=C.ReactCurrentBatchConfig,Go=0,$o=null,Qo=null,Ko=null,Jo=!1,Zo=!1;function ea(){throw Error(a(321))}function ta(e,t){if(null===t)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!ar(e[n],t[n]))return!1;return!0}function na(e,t,n,r,i,o){if(Go=o,$o=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Yo.current=null===e||null===e.memoizedState?Pa:Ra,e=n(r,i),Zo){o=0;do{if(Zo=!1,!(25>o))throw Error(a(301));o+=1,Ko=Qo=null,t.updateQueue=null,Yo.current=xa,e=n(r,i)}while(Zo)}if(Yo.current=Oa,t=null!==Qo&&null!==Qo.next,Go=0,Ko=Qo=$o=null,Jo=!1,t)throw Error(a(300));return e}function ra(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===Ko?$o.memoizedState=Ko=e:Ko=Ko.next=e,Ko}function ia(){if(null===Qo){var e=$o.alternate;e=null!==e?e.memoizedState:null}else e=Qo.next;var t=null===Ko?$o.memoizedState:Ko.next;if(null!==t)Ko=t,Qo=e;else{if(null===e)throw Error(a(310));e={memoizedState:(Qo=e).memoizedState,baseState:Qo.baseState,baseQueue:Qo.baseQueue,queue:Qo.queue,next:null},null===Ko?$o.memoizedState=Ko=e:Ko=Ko.next=e}return Ko}function oa(e,t){return"function"==typeof t?t(e):t}function aa(e){var t=ia(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=Qo,i=r.baseQueue,o=n.pending;if(null!==o){if(null!==i){var s=i.next;i.next=o.next,o.next=s}r.baseQueue=i=o,n.pending=null}if(null!==i){i=i.next,r=r.baseState;var l=s=o=null,c=i;do{var u=c.lane;if((Go&u)===u)null!==l&&(l=l.next={lane:0,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null}),r=c.eagerReducer===e?c.eagerState:e(r,c.action);else{var p={lane:u,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null};null===l?(s=l=p,o=r):l=l.next=p,$o.lanes|=u,As|=u}c=c.next}while(null!==c&&c!==i);null===l?o=r:l.next=s,ar(r,t.memoizedState)||(ja=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=l,n.lastRenderedState=r}return[t.memoizedState,n.dispatch]}function sa(e){var t=ia(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,o=t.memoizedState;if(null!==i){n.pending=null;var s=i=i.next;do{o=e(o,s.action),s=s.next}while(s!==i);ar(o,t.memoizedState)||(ja=!0),t.memoizedState=o,null===t.baseQueue&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function la(e,t,n){var r=t._getVersion;r=r(t._source);var i=t._workInProgressVersionPrimary;if(null!==i?e=i===r:(e=e.mutableReadLanes,(e=(Go&e)===e)&&(t._workInProgressVersionPrimary=r,Wo.push(t))),e)return n(t._source);throw Wo.push(t),Error(a(350))}function ca(e,t,n,r){var i=Ts;if(null===i)throw Error(a(349));var o=t._getVersion,s=o(t._source),l=Yo.current,c=l.useState((function(){return la(i,t,n)})),u=c[1],p=c[0];c=Ko;var f=e.memoizedState,d=f.refs,h=d.getSnapshot,m=f.source;f=f.subscribe;var y=$o;return e.memoizedState={refs:d,source:t,subscribe:r},l.useEffect((function(){d.getSnapshot=n,d.setSnapshot=u;var e=o(t._source);if(!ar(s,e)){e=n(t._source),ar(p,e)||(u(e),e=al(y),i.mutableReadLanes|=e&i.pendingLanes),e=i.mutableReadLanes,i.entangledLanes|=e;for(var r=i.entanglements,a=e;0<a;){var l=31-Vt(a),c=1<<l;r[l]|=e,a&=~c}}}),[n,t,r]),l.useEffect((function(){return r(t._source,(function(){var e=d.getSnapshot,n=d.setSnapshot;try{n(e(t._source));var r=al(y);i.mutableReadLanes|=r&i.pendingLanes}catch(e){n((function(){throw e}))}}))}),[t,r]),ar(h,n)&&ar(m,t)&&ar(f,r)||((e={pending:null,dispatch:null,lastRenderedReducer:oa,lastRenderedState:p}).dispatch=u=Ta.bind(null,$o,e),c.queue=e,c.baseQueue=null,p=la(i,t,n),c.memoizedState=c.baseState=p),p}function ua(e,t,n){return ca(ia(),e,t,n)}function pa(e){var t=ra();return"function"==typeof e&&(e=e()),t.memoizedState=t.baseState=e,e=(e=t.queue={pending:null,dispatch:null,lastRenderedReducer:oa,lastRenderedState:e}).dispatch=Ta.bind(null,$o,e),[t.memoizedState,e]}function fa(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},null===(t=$o.updateQueue)?(t={lastEffect:null},$o.updateQueue=t,t.lastEffect=e.next=e):null===(n=t.lastEffect)?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function da(e){return e={current:e},ra().memoizedState=e}function ha(){return ia().memoizedState}function ma(e,t,n,r){var i=ra();$o.flags|=e,i.memoizedState=fa(1|t,n,void 0,void 0===r?null:r)}function ya(e,t,n,r){var i=ia();r=void 0===r?null:r;var o=void 0;if(null!==Qo){var a=Qo.memoizedState;if(o=a.destroy,null!==r&&ta(r,a.deps))return void fa(t,n,o,r)}$o.flags|=e,i.memoizedState=fa(1|t,n,o,r)}function ba(e,t){return ma(516,4,e,t)}function va(e,t){return ya(516,4,e,t)}function ga(e,t){return ya(4,2,e,t)}function wa(e,t){return"function"==typeof t?(e=e(),t(e),function(){t(null)}):null!=t?(e=e(),t.current=e,function(){t.current=null}):void 0}function Ca(e,t,n){return n=null!=n?n.concat([e]):null,ya(4,2,wa.bind(null,t,e),n)}function _a(){}function ka(e,t){var n=ia();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&ta(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Sa(e,t){var n=ia();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&ta(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Ea(e,t){var n=Ui();Bi(98>n?98:n,(function(){e(!0)})),Bi(97<n?97:n,(function(){var n=Xo.transition;Xo.transition=1;try{e(!1),t()}finally{Xo.transition=n}}))}function Ta(e,t,n){var r=ol(),i=al(e),o={lane:i,action:n,eagerReducer:null,eagerState:null,next:null},a=t.pending;if(null===a?o.next=o:(o.next=a.next,a.next=o),t.pending=o,a=e.alternate,e===$o||null!==a&&a===$o)Zo=Jo=!0;else{if(0===e.lanes&&(null===a||0===a.lanes)&&null!==(a=t.lastRenderedReducer))try{var s=t.lastRenderedState,l=a(s,n);if(o.eagerReducer=a,o.eagerState=l,ar(l,s))return}catch(e){}sl(e,i,r)}}var Oa={readContext:to,useCallback:ea,useContext:ea,useEffect:ea,useImperativeHandle:ea,useLayoutEffect:ea,useMemo:ea,useReducer:ea,useRef:ea,useState:ea,useDebugValue:ea,useDeferredValue:ea,useTransition:ea,useMutableSource:ea,useOpaqueIdentifier:ea,unstable_isNewReconciler:!1},Pa={readContext:to,useCallback:function(e,t){return ra().memoizedState=[e,void 0===t?null:t],e},useContext:to,useEffect:ba,useImperativeHandle:function(e,t,n){return n=null!=n?n.concat([e]):null,ma(4,2,wa.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ma(4,2,e,t)},useMemo:function(e,t){var n=ra();return t=void 0===t?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=ra();return t=void 0!==n?n(t):t,r.memoizedState=r.baseState=t,e=(e=r.queue={pending:null,dispatch:null,lastRenderedReducer:e,lastRenderedState:t}).dispatch=Ta.bind(null,$o,e),[r.memoizedState,e]},useRef:da,useState:pa,useDebugValue:_a,useDeferredValue:function(e){var t=pa(e),n=t[0],r=t[1];return ba((function(){var t=Xo.transition;Xo.transition=1;try{r(e)}finally{Xo.transition=t}}),[e]),n},useTransition:function(){var e=pa(!1),t=e[0];return da(e=Ea.bind(null,e[1])),[e,t]},useMutableSource:function(e,t,n){var r=ra();return r.memoizedState={refs:{getSnapshot:t,setSnapshot:null},source:e,subscribe:n},ca(r,e,t,n)},useOpaqueIdentifier:function(){if(Lo){var e=!1,t=function(e){return{$$typeof:I,toString:e,valueOf:e}}((function(){throw e||(e=!0,n("r:"+(Hr++).toString(36))),Error(a(355))})),n=pa(t)[1];return 0==(2&$o.mode)&&($o.flags|=516,fa(5,(function(){n("r:"+(Hr++).toString(36))}),void 0,null)),t}return pa(t="r:"+(Hr++).toString(36)),t},unstable_isNewReconciler:!1},Ra={readContext:to,useCallback:ka,useContext:to,useEffect:va,useImperativeHandle:Ca,useLayoutEffect:ga,useMemo:Sa,useReducer:aa,useRef
vendor: 5,947 bytes, line 92
92:ha,useState:function(){return aa(oa)},useDebugValue:_a,useDeferredValue:function(e){var t=aa(oa),n=t[0],r=t[1];return va((function(){var t=Xo.transition;Xo.transition=1;try{r(e)}finally{Xo.transition=t}}),[e]),n},useTransition:function(){var e=aa(oa)[0];return[ha().current,e]},useMutableSource:ua,useOpaqueIdentifier:function(){return aa(oa)[0]},unstable_isNewReconciler:!1},xa={readContext:to,useCallback:ka,useContext:to,useEffect:va,useImperativeHandle:Ca,useLayoutEffect:ga,useMemo:Sa,useReducer:sa,useRef:ha,useState:function(){return sa(oa)},useDebugValue:_a,useDeferredValue:function(e){var t=sa(oa),n=t[0],r=t[1];return va((function(){var t=Xo.transition;Xo.transition=1;try{r(e)}finally{Xo.transition=t}}),[e]),n},useTransition:function(){var e=sa(oa)[0];return[ha().current,e]},useMutableSource:ua,useOpaqueIdentifier:function(){return sa(oa)[0]},unstable_isNewReconciler:!1},Da=C.ReactCurrentOwner,ja=!1;function Ma(e,t,n,r){t.child=null===e?ko(t,null,n,r):_o(t,e.child,n,r)}function Aa(e,t,n,r,i){n=n.render;var o=t.ref;return eo(t,i),r=na(e,t,n,r,o,i),null===e||ja?(t.flags|=1,Ma(e,t,r,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,es(e,t,i))}function Ia(e,t,n,r,i,o){if(null===e){var a=n.type;return"function"!=typeof a||Fl(a)||void 0!==a.defaultProps||null!==n.compare||void 0!==n.defaultProps?((e=ql(n.type,null,r,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=a,Na(e,t,a,r,i,o))}return a=e.child,0==(i&o)&&(i=a.memoizedProps,(n=null!==(n=n.compare)?n:lr)(i,r)&&e.ref===t.ref)?es(e,t,o):(t.flags|=1,(e=Ul(a,r)).ref=t.ref,e.return=t,t.child=e)}function Na(e,t,n,r,i,o){if(null!==e&&lr(e.memoizedProps,r)&&e.ref===t.ref){if(ja=!1,0==(o&i))return t.lanes=e.lanes,es(e,t,o);0!=(16384&e.flags)&&(ja=!0)}return Ua(e,t,n,r,o)}function La(e,t,n){var r=t.pendingProps,i=r.children,o=null!==e?e.memoizedState:null;if("hidden"===r.mode||"unstable-defer-without-hiding"===r.mode)if(0==(4&t.mode))t.memoizedState={baseLanes:0},ml(t,n);else{if(0==(1073741824&n))return e=null!==o?o.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e},ml(t,e),null;t.memoizedState={baseLanes:0},ml(t,null!==o?o.baseLanes:n)}else null!==o?(r=o.baseLanes|n,t.memoizedState=null):r=n,ml(t,r);return Ma(e,t,i,n),t.child}function Fa(e,t){var n=t.ref;(null===e&&null!==n||null!==e&&e.ref!==n)&&(t.flags|=128)}function Ua(e,t,n,r,i){var o=fi(n)?ui:li.current;return o=pi(t,o),eo(t,i),n=na(e,t,n,r,o,i),null===e||ja?(t.flags|=1,Ma(e,t,n,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,es(e,t,i))}function qa(e,t,n,r,i){if(fi(n)){var o=!0;yi(t)}else o=!1;if(eo(t,i),null===t.stateNode)null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),mo(t,n,r),bo(t,n,r,i),r=!0;else if(null===e){var a=t.stateNode,s=t.memoizedProps;a.props=s;var l=a.context,c=n.contextType;"object"==typeof c&&null!==c?c=to(c):c=pi(t,c=fi(n)?ui:li.current);var u=n.getDerivedStateFromProps,p="function"==typeof u||"function"==typeof a.getSnapshotBeforeUpdate;p||"function"!=typeof a.UNSAFE_componentWillReceiveProps&&"function"!=typeof a.componentWillReceiveProps||(s!==r||l!==c)&&yo(t,a,r,c),no=!1;var f=t.memoizedState;a.state=f,lo(t,r,a,i),l=t.memoizedState,s!==r||f!==l||ci.current||no?("function"==typeof u&&(po(t,n,u,r),l=t.memoizedState),(s=no||ho(t,n,s,r,f,l,c))?(p||"function"!=typeof a.UNSAFE_componentWillMount&&"function"!=typeof a.componentWillMount||("function"==typeof a.componentWillMount&&a.componentWillMount(),"function"==typeof a.UNSAFE_componentWillMount&&a.UNSAFE_componentWillMount()),"function"==typeof a.componentDidMount&&(t.flags|=4)):("function"==typeof a.componentDidMount&&(t.flags|=4),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=c,r=s):("function"==typeof a.componentDidMount&&(t.flags|=4),r=!1)}else{a=t.stateNode,io(e,t),s=t.memoizedProps,c=t.type===t.elementType?s:Yi(t.type,s),a.props=c,p=t.pendingProps,f=a.context,"object"==typeof(l=n.contextType)&&null!==l?l=to(l):l=pi(t,l=fi(n)?ui:li.current);var d=n.getDerivedStateFromProps;(u="function"==typeof d||"function"==typeof a.getSnapshotBeforeUpdate)||"function"!=typeof a.UNSAFE_componentWillReceiveProps&&"function"!=typeof a.componentWillReceiveProps||(s!==p||f!==l)&&yo(t,a,r,l),no=!1,f=t.memoizedState,a.state=f,lo(t,r,a,i);var h=t.memoizedState;s!==p||f!==h||ci.current||no?("function"==typeof d&&(po(t,n,d,r),h=t.memoizedState),(c=no||ho(t,n,c,r,f,h,l))?(u||"function"!=typeof a.UNSAFE_componentWillUpdate&&"function"!=typeof a.componentWillUpdate||("function"==typeof a.componentWillUpdate&&a.componentWillUpdate(r,h,l),"function"==typeof a.UNSAFE_componentWillUpdate&&a.UNSAFE_componentWillUpdate(r,h,l)),"function"==typeof a.componentDidUpdate&&(t.flags|=4),"function"==typeof a.getSnapshotBeforeUpdate&&(t.flags|=256)):("function"!=typeof a.componentDidUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=256),t.memoizedProps=r,t.memoizedState=h),a.props=r,a.state=h,a.context=l,r=c):("function"!=typeof a.componentDidUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=256),r=!1)}return Ba(e,t,n,r,o,i)}function Ba(e,t,n,r,i,o){Fa(e,t);var a=0!=(64&t.flags);if(!r&&!a)return i&&bi(t,n,!1),es(e,t,o);r=t.stateNode,Da.current=t;var s=a&&"function"!=typeof n.getDerivedStateFromError?null:r.render();return t.flags|=1,null!==e&&a?(t.child=_o(t,e.child,null,o),t.child=_o(t,null,s,o)):Ma(e,t,s,o),t.memoizedState=r.state,i&&bi(t,n,!0),t.child}function za(e){var t=e.stateNode;t.pendingContext?hi(0,t.pendingContext,t.pendingContext!==t.context):t.context&&hi(0,t.context,!1),Ro(e,t.containerInfo)}var Va,Wa,Ha,Ya={dehydrated:null,retryLane:0};function Xa(e,t,n){var r,i=t.pendingProps,o=Mo.current,a=!1;return(r=0!=(64&t.flags))||(r=(null===e||null!==e.memoizedState)&&0!=(2&o)),r?
vendor: 8,397 bytes, line 92
92(a=!0,t.flags&=-65):null!==e&&null===e.memoizedState||void 0===i.fallback||!0===i.unstable_avoidThisFallback||(o|=1),ai(Mo,1&o),null===e?(void 0!==i.fallback&&qo(t),e=i.children,o=i.fallback,a?(e=Ga(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Ya,e):"number"==typeof i.unstable_expectedLoadTime?(e=Ga(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Ya,t.lanes=33554432,e):((n=zl({mode:"visible",children:e},t.mode,n,null)).return=t,t.child=n)):(e.memoizedState,a?(i=Qa(e,t,i.children,i.fallback,n),a=t.child,o=e.child.memoizedState,a.memoizedState=null===o?{baseLanes:n}:{baseLanes:o.baseLanes|n},a.childLanes=e.childLanes&~n,t.memoizedState=Ya,i):(n=$a(e,t,i.children,n),t.memoizedState=null,n))}function Ga(e,t,n,r){var i=e.mode,o=e.child;return t={mode:"hidden",children:t},0==(2&i)&&null!==o?(o.childLanes=0,o.pendingProps=t):o=zl(t,i,0,null),n=Bl(n,i,r,null),o.return=e,n.return=e,o.sibling=n,e.child=o,n}function $a(e,t,n,r){var i=e.child;return e=i.sibling,n=Ul(i,{mode:"visible",children:n}),0==(2&t.mode)&&(n.lanes=r),n.return=t,n.sibling=null,null!==e&&(e.nextEffect=null,e.flags=8,t.firstEffect=t.lastEffect=e),t.child=n}function Qa(e,t,n,r,i){var o=t.mode,a=e.child;e=a.sibling;var s={mode:"hidden",children:n};return 0==(2&o)&&t.child!==a?((n=t.child).childLanes=0,n.pendingProps=s,null!==(a=n.lastEffect)?(t.firstEffect=n.firstEffect,t.lastEffect=a,a.nextEffect=null):t.firstEffect=t.lastEffect=null):n=Ul(a,s),null!==e?r=Ul(e,r):(r=Bl(r,o,i,null)).flags|=2,r.return=t,n.return=t,n.sibling=r,t.child=n,r}function Ka(e,t){e.lanes|=t;var n=e.alternate;null!==n&&(n.lanes|=t),Zi(e.return,t)}function Ja(e,t,n,r,i,o){var a=e.memoizedState;null===a?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,lastEffect:o}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=r,a.tail=n,a.tailMode=i,a.lastEffect=o)}function Za(e,t,n){var r=t.pendingProps,i=r.revealOrder,o=r.tail;if(Ma(e,t,r.children,n),0!=(2&(r=Mo.current)))r=1&r|2,t.flags|=64;else{if(null!==e&&0!=(64&e.flags))e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&Ka(e,n);else if(19===e.tag)Ka(e,n);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(ai(Mo,r),0==(2&t.mode))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;null!==n;)null!==(e=n.alternate)&&null===Ao(e)&&(i=n),n=n.sibling;null===(n=i)?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),Ja(t,!1,i,n,o,t.lastEffect);break;case"backwards":for(n=null,i=t.child,t.child=null;null!==i;){if(null!==(e=i.alternate)&&null===Ao(e)){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}Ja(t,!0,n,null,o,t.lastEffect);break;case"together":Ja(t,!1,null,null,void 0,t.lastEffect);break;default:t.memoizedState=null}return t.child}function es(e,t,n){if(null!==e&&(t.dependencies=e.dependencies),As|=t.lanes,0!=(n&t.childLanes)){if(null!==e&&t.child!==e.child)throw Error(a(153));if(null!==t.child){for(n=Ul(e=t.child,e.pendingProps),t.child=n,n.return=t;null!==e.sibling;)e=e.sibling,(n=n.sibling=Ul(e,e.pendingProps)).return=t;n.sibling=null}return t.child}return null}function ts(e,t){if(!Lo)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;null!==t;)null!==t.alternate&&(n=t),t=t.sibling;null===n?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;null!==n;)null!==n.alternate&&(r=n),n=n.sibling;null===r?t||null===e.tail?e.tail=null:e.tail.sibling=null:r.sibling=null}}function ns(e,t,n){var r=t.pendingProps;switch(t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:return fi(t.type)&&di(),null;case 3:return xo(),oi(ci),oi(li),Ho(),(r=t.stateNode).pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),null!==e&&null!==e.child||(zo(t)?t.flags|=4:r.hydrate||(t.flags|=256)),null;case 5:jo(t);var o=Po(Oo.current);if(n=t.type,null!==e&&null!=t.stateNode)Wa(e,t,n,r),e.ref!==t.ref&&(t.flags|=128);else{if(!r){if(null===t.stateNode)throw Error(a(166));return null}if(e=Po(Eo.current),zo(t)){r=t.stateNode,n=t.type;var s=t.memoizedProps;switch(r[Xr]=t,r[Gr]=s,n){case"dialog":Er("cancel",r),Er("close",r);break;case"iframe":case"object":case"embed":Er("load",r);break;case"video":case"audio":for(e=0;e<Cr.length;e++)Er(Cr[e],r);break;case"source":Er("error",r);break;case"img":case"image":case"link":Er("error",r),Er("load",r);break;case"details":Er("toggle",r);break;case"input":ee(r,s),Er("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!s.multiple},Er("invalid",r);break;case"textarea":le(r,s),Er("invalid",r)}for(var c in ke(n,s),e=null,s)s.hasOwnProperty(c)&&(o=s[c],"children"===c?"string"==typeof o?r.textContent!==o&&(e=["children",o]):"number"==typeof o&&r.textContent!==""+o&&(e=["children",""+o]):l.hasOwnProperty(c)&&null!=o&&"onScroll"===c&&Er("scroll",r));switch(n){case"input":Q(r),re(r,s,!0);break;case"textarea":Q(r),ue(r);break;case"select":case"option":break;default:"function"==typeof s.onClick&&(r.onclick=Ir)}r=e,t.updateQueue=r,null!==r&&(t.flags|=4)}else{switch(c=9===o.nodeType?o:o.ownerDocument,e===pe&&(e=de(n)),e===pe?"script"===n?((e=c.createElement("div")).innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):"string"==typeof r.is?e=c.createElement(n,{is:r.is}):(e=c.createElement(n),"select"===n&&(c=e,r.multiple?c.multiple=!0:r.size&&(c.size=r.size))):e=c.createElementNS(e,n),e[Xr]=t,e[Gr]=r,Va(e,t),t.stateNode=e,c=Se(n,r),n){case"dialog":Er("cancel",e),Er("close",e),o=r;break;case"iframe":case"object":case"embed":Er("load",e),o=r;break;case"video":case"audio":for(o=0;o<Cr.length;o++)Er(Cr[o],e);o=r;break;case"source":Er("error",e),o=r;break;case"img":case"image":case"link":Er("error",e),Er("load",e),o=r;break;case"details":Er("toggle",e),o=r;break;case"input":ee(e,r),o=Z(e,r),Er("invalid",e);break;case"option":o=oe(e,r);break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=i({},r,{value:void 0}),Er("invalid",e);break;case"textarea":le(e,r),o=se(e,r),Er("invalid",e);break;default:o=r}ke(n,o);var u=o;for(s in u)if(u.hasOwnProperty(s)){var p=u[s];"style"===s?Ce(e,p):"dangerouslySetInnerHTML"===s?null!=(p=p?p.__html:void 0)&&ye(e,p):"children"===s?"string"==typeof p?("textarea"!==n||""!==p)&&be(e,p):"number"==typeof p&&be(e,""+p):"suppressContentEditableWarning"!==s&&"suppressHydrationWarning"!==s&&"autoFocus"!==s&&(l.hasOwnProperty(s)?null!=p&&"onScroll"===s&&Er("scroll",e):null!=p&&w(e,s,p,c))}switch(n){case"input":Q(e),re(e,r,!1);break;case"textarea":Q(e),ue(e);break;case"option":null!=r.value&&e.setAttribute("value",""+G(r.value));break;case"select":e.multiple=!!r.multiple,null!=(s=r.value)?ae(e,!!r.multiple,s,!1):null!=r.defaultValue&&ae(e,!!r.multiple,r.defaultValue,!0);break;default:"function"==typeof o.onClick&&(e.onclick=Ir)}Fr(n,r)&&(t.flags|=4)}null!==t.ref&&(t.flags|=128)}return null;case 6:if(e&&null!=t.stateNode)Ha(0,t,e.memoizedProps,r);else{if("string"!=typeof r&&null===t.stateNode)throw Error(a(166));n=Po(Oo.current),Po(Eo.current),zo(t)?(r=t.stateNode,n=t.memoizedProps,r[Xr]=t,r.nodeValue!==n&&(t.flags|=4)):((r=(9===n.nodeType?n:n.ownerDocument).createTextNode(r))[Xr]=t,t.stateNode=r)}return null;case 13:return oi(Mo),r=t.memoizedState,0!=(64&t.flags)?(t.lanes=n,t):(r=null!==r,n=!1,null===e?void 0!==t.memoizedProps.fallback&&zo(t):n=null!==e.memoizedState,r&&!n&&0!=(2&t.mode)&&(null===e&&!0!==t.memoizedProps.unstable_avoidThisFallback||0!=(1&Mo.current)?0===Ds&&(Ds=3):(0!==Ds&&3!==Ds||(Ds=4),null===Ts||0==(134217727&As)&&0==(134217727&Is)||pl(Ts,Ps))),(r||n)&&(t.flags|=4),null);case 4:return xo(),null===e&&Or(t.stateNode.containerInfo),null;case 10:return Ji(t),null;case 17:return fi(t.type)&&di(),null;case 19:if(oi(Mo),null===(r=t.memoizedState))return null;if(s=0!=(64&t.flags),null===(c=r.rendering))if(s)ts(r,!1);else{if(0!==Ds||null!==e&&0!=(64&e.flags))for(e=t.child;null!==e;){if(null!==(c=Ao(e))){for(t.flags|=64,ts(r,!1),null!==(s=c.updateQueue)&&(t.updateQueue=s,t.flags|=4),null===r.lastEffect&&(t.firstEffect=null),t.lastEffect=r.lastEffect,r=n,n=t.child;null!==n;)e=r,(s=n).flags&=2,s.nextEffect=null,s.firstEffect=null,s.lastEffect=null,null===(c=s.alternate)?(s.childLanes=0,s.lanes=e,s.child=null,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,
vendor: 9,741 bytes, line 92
92s.stateNode=null):(s.childLanes=c.childLanes,s.lanes=c.lanes,s.child=c.child,s.memoizedProps=c.memoizedProps,s.memoizedState=c.memoizedState,s.updateQueue=c.updateQueue,s.type=c.type,e=c.dependencies,s.dependencies=null===e?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return ai(Mo,1&Mo.current|2),t.child}e=e.sibling}null!==r.tail&&Fi()>Us&&(t.flags|=64,s=!0,ts(r,!1),t.lanes=33554432)}else{if(!s)if(null!==(e=Ao(c))){if(t.flags|=64,s=!0,null!==(n=e.updateQueue)&&(t.updateQueue=n,t.flags|=4),ts(r,!0),null===r.tail&&"hidden"===r.tailMode&&!c.alternate&&!Lo)return null!==(t=t.lastEffect=r.lastEffect)&&(t.nextEffect=null),null}else 2*Fi()-r.renderingStartTime>Us&&1073741824!==n&&(t.flags|=64,s=!0,ts(r,!1),t.lanes=33554432);r.isBackwards?(c.sibling=t.child,t.child=c):(null!==(n=r.last)?n.sibling=c:t.child=c,r.last=c)}return null!==r.tail?(n=r.tail,r.rendering=n,r.tail=n.sibling,r.lastEffect=t.lastEffect,r.renderingStartTime=Fi(),n.sibling=null,t=Mo.current,ai(Mo,s?1&t|2:1&t),n):null;case 23:case 24:return yl(),null!==e&&null!==e.memoizedState!=(null!==t.memoizedState)&&"unstable-defer-without-hiding"!==r.mode&&(t.flags|=4),null}throw Error(a(156,t.tag))}function rs(e){switch(e.tag){case 1:fi(e.type)&&di();var t=e.flags;return 4096&t?(e.flags=-4097&t|64,e):null;case 3:if(xo(),oi(ci),oi(li),Ho(),0!=(64&(t=e.flags)))throw Error(a(285));return e.flags=-4097&t|64,e;case 5:return jo(e),null;case 13:return oi(Mo),4096&(t=e.flags)?(e.flags=-4097&t|64,e):null;case 19:return oi(Mo),null;case 4:return xo(),null;case 10:return Ji(e),null;case 23:case 24:return yl(),null;default:return null}}function is(e,t){try{var n="",r=t;do{n+=Y(r),r=r.return}while(r);var i=n}catch(e){i="\nError generating stack: "+e.message+"\n"+e.stack}return{value:e,source:t,stack:i}}function os(e,t){try{console.error(t.value)}catch(e){setTimeout((function(){throw e}))}}Va=function(e,t){for(var n=t.child;null!==n;){if(5===n.tag||6===n.tag)e.appendChild(n.stateNode);else if(4!==n.tag&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===t)break;for(;null===n.sibling;){if(null===n.return||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},Wa=function(e,t,n,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,Po(Eo.current);var a,s=null;switch(n){case"input":o=Z(e,o),r=Z(e,r),s=[];break;case"option":o=oe(e,o),r=oe(e,r),s=[];break;case"select":o=i({},o,{value:void 0}),r=i({},r,{value:void 0}),s=[];break;case"textarea":o=se(e,o),r=se(e,r),s=[];break;default:"function"!=typeof o.onClick&&"function"==typeof r.onClick&&(e.onclick=Ir)}for(p in ke(n,r),n=null,o)if(!r.hasOwnProperty(p)&&o.hasOwnProperty(p)&&null!=o[p])if("style"===p){var c=o[p];for(a in c)c.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else"dangerouslySetInnerHTML"!==p&&"children"!==p&&"suppressContentEditableWarning"!==p&&"suppressHydrationWarning"!==p&&"autoFocus"!==p&&(l.hasOwnProperty(p)?s||(s=[]):(s=s||[]).push(p,null));for(p in r){var u=r[p];if(c=null!=o?o[p]:void 0,r.hasOwnProperty(p)&&u!==c&&(null!=u||null!=c))if("style"===p)if(c){for(a in c)!c.hasOwnProperty(a)||u&&u.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in u)u.hasOwnProperty(a)&&c[a]!==u[a]&&(n||(n={}),n[a]=u[a])}else n||(s||(s=[]),s.push(p,n)),n=u;else"dangerouslySetInnerHTML"===p?(u=u?u.__html:void 0,c=c?c.__html:void 0,null!=u&&c!==u&&(s=s||[]).push(p,u)):"children"===p?"string"!=typeof u&&"number"!=typeof u||(s=s||[]).push(p,""+u):"suppressContentEditableWarning"!==p&&"suppressHydrationWarning"!==p&&(l.hasOwnProperty(p)?(null!=u&&"onScroll"===p&&Er("scroll",e),s||c===u||(s=[])):"object"==typeof u&&null!==u&&u.$$typeof===I?u.toString():(s=s||[]).push(p,u))}n&&(s=s||[]).push("style",n);var p=s;(t.updateQueue=p)&&(t.flags|=4)}},Ha=function(e,t,n,r){n!==r&&(t.flags|=4)};var as="function"==typeof WeakMap?WeakMap:Map;function ss(e,t,n){(n=oo(-1,n)).tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Vs||(Vs=!0,Ws=r),os(0,t)},n}function ls(e,t,n){(n=oo(-1,n)).tag=3;var r=e.type.getDerivedStateFromError;if("function"==typeof r){var i=t.value;n.payload=function(){return os(0,t),r(i)}}var o=e.stateNode;return null!==o&&"function"==typeof o.componentDidCatch&&(n.callback=function(){"function"!=typeof r&&(null===Hs?Hs=new Set([this]):Hs.add(this),os(0,t));var e=t.stack;this.componentDidCatch(t.value,{componentStack:null!==e?e:""})}),n}var cs="function"==typeof WeakSet?WeakSet:Set;function us(e){var t=e.ref;if(null!==t)if("function"==typeof t)try{t(null)}catch(t){Ml(e,t)}else t.current=null}function ps(e,t){switch(t.tag){case 0:case 11:case 15:case 22:return;case 1:if(256&t.flags&&null!==e){var n=e.memoizedProps,r=e.memoizedState;t=(e=t.stateNode).getSnapshotBeforeUpdate(t.elementType===t.type?n:Yi(t.type,n),r),e.__reactInternalSnapshotBeforeUpdate=t}return;case 3:return void(256&t.flags&&zr(t.stateNode.containerInfo));case 5:case 6:case 4:case 17:return}throw Error(a(163))}function fs(e,t,n){switch(n.tag){case 0:case 11:case 15:case 22:if(null!==(t=null!==(t=n.updateQueue)?t.lastEffect:null)){e=t=t.next;do{if(3==(3&e.tag)){var r=e.create;e.destroy=r()}e=e.next}while(e!==t)}if(null!==(t=null!==(t=n.updateQueue)?t.lastEffect:null)){e=t=t.next;do{var i=e;r=i.next,0!=(4&(i=i.tag))&&0!=(1&i)&&(xl(n,e),Rl(n,e)),e=r}while(e!==t)}return;case 1:return e=n.stateNode,4&n.flags&&(null===t?e.componentDidMount():(r=n.elementType===n.type?t.memoizedProps:Yi(n.type,t.memoizedProps),e.componentDidUpdate(r,t.memoizedState,e.__reactInternalSnapshotBeforeUpdate))),void(null!==(t=n.updateQueue)&&co(n,t,e));case 3:if(null!==(t=n.updateQueue)){if(e=null,null!==n.child)switch(n.child.tag){case 5:e=n.child.stateNode;break;case 1:e=n.child.stateNode}co(n,t,e)}return;case 5:return e=n.stateNode,void(null===t&&4&n.flags&&Fr(n.type,n.memoizedProps)&&e.focus());case 6:case 4:case 12:return;case 13:return void(null===n.memoizedState&&(n=n.alternate,null!==n&&(n=n.memoizedState,null!==n&&(n=n.dehydrated,null!==n&&Ct(n)))));case 19:case 17:case 20:case 21:case 23:case 24:return}throw Error(a(163))}function ds(e,t){for(var n=e;;){if(5===n.tag){var r=n.stateNode;if(t)"function"==typeof(r=r.style).setProperty?r.setProperty("display","none","important"):r.display="none";else{r=n.stateNode;var i=n.memoizedProps.style;i=null!=i&&i.hasOwnProperty("display")?i.display:null,r.style.display=we("display",i)}}else if(6===n.tag)n.stateNode.nodeValue=t?"":n.memoizedProps;else if((23!==n.tag&&24!==n.tag||null===n.memoizedState||n===e)&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===e)break;for(;null===n.sibling;){if(null===n.return||n.return===e)return;n=n.return}n.sibling.return=n.return,n=n.sibling}}function hs(e,t){if(gi&&"function"==typeof gi.onCommitFiberUnmount)try{gi.onCommitFiberUnmount(vi,t)}catch(e){}switch(t.tag){case 0:case 11:case 14:case 15:case 22:if(null!==(e=t.updateQueue)&&null!==(e=e.lastEffect)){var n=e=e.next;do{var r=n,i=r.destroy;if(r=r.tag,void 0!==i)if(0!=(4&r))xl(t,n);else{r=t;try{i()}catch(e){Ml(r,e)}}n=n.next}while(n!==e)}break;case 1:if(us(t),"function"==typeof(e=t.stateNode).componentWillUnmount)try{e.props=t.memoizedProps,e.state=t.memoizedState,e.componentWillUnmount()}catch(e){Ml(t,e)}break;case 5:us(t);break;case 4:vs(e,t)}}function ms(e){e.alternate=null,e.child=null,e.dependencies=null,e.firstEffect=null,e.lastEffect=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.return=null,e.updateQueue=null}function ys(e){return 5===e.tag||3===e.tag||4===e.tag}function bs(e){e:{for(var t=e.return;null!==t;){if(ys(t))break e;t=t.return}throw Error(a(160))}var n=t;switch(t=n.stateNode,n.tag){case 5:var r=!1;break;case 3:case 4:t=t.containerInfo,r=!0;break;default:throw Error(a(161))}16&n.flags&&(be(t,""),n.flags&=-17);e:t:for(n=e;;){for(;null===n.sibling;){if(null===n.return||ys(n.return)){n=null;break e}n=n.return}for(n.sibling.return=n.return,n=n.sibling;5!==n.tag&&6!==n.tag&&18!==n.tag;){if(2&n.flags)continue t;if(null===n.child||4===n.tag)continue t;n.child.return=n,n=n.child}if(!(2&n.flags)){n=n.stateNode;break e}}r?function e(t,n,r){var i=t.tag,o=5===i||6===i;if(o)t=o?t.stateNode:t.stateNode.instance,n?8===r.nodeType?r.parentNode.insertBefore(t,n):r.insertBefore(t,n):(8===r.nodeType?(n=r.parentNode).insertBefore(t,r):(n=r).appendChild(t),null!==(r=r._reactRootContainer)&&void 0!==r||null!==n.onclick||(n.onclick=Ir));else if(4!==i&&null!==(t=t.child))for(e(t,n,r),t=t.sibling;null!==t;)e(t,n,r),t=t.sibling}(e,n,t):function e(t,n,r){var i=t.tag,o=5===i||6===i;if(o)t=o?t.stateNode:t.stateNode.instance,n?r.insertBefore(t,n):r.appendChild(t);else if(4!==i&&null!==(t=t.child))for(e(t,n,r),t=t.sibling;null!==t;)e(t,n,r),t=t.sibling}(e,n,t)}function vs(e,t){for(var n,r,i=t,o=!1;;){if(!o){o=i.return;e:for(;;){if(null===o)throw Error(a(160));switch(n=o.stateNode,o.tag){case 5:r=!1;break e;case 3:case 4:n=n.containerInfo,r=!0;break e}o=o.return}o=!0}if(5===i.tag||6===i.tag){e:for(var s=e,l=i,c=l;;)if(hs(s,c),null!==c.child&&4!==c.tag)c.child.return=c,c=c.child;else{if(c===l)break e;for(;null===c.sibling;){if(null===c.return||c.return===l)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}r?(s=n,l=i.stateNode,8===s.nodeType?s.parentNode.removeChild(l):s.removeChild(l)):n.removeChild(i.stateNode)}else if(4===i.tag){if(null!==i.child){n=i.stateNode.containerInfo,r=!0,i.child.return=i,i=i.child;continue}}else if(hs(e,i),null!==i.child){i.child.return=i,i=i.child;continue}if(i===t)break;for(;null===i.sibling;){if(null===i.return||i.return===t)return;4===(i=i.return).tag&&(o=!1)}i.sibling.return=i.return,i=i.sibling}}function gs(e,t){switch(t.tag){case 0:case 11:case 14:case 15:case 22:var n=t.updateQueue;if(null!==(n=null!==n?n.lastEffect:null)){var r=n=n.next;do{3==(3&r.tag)&&(e=r.destroy,r.destroy=void 0,void 0!==e&&e()),r=r.next}
vendor: 4,321 bytes, line 92
92while(r!==n)}return;case 1:return;case 5:if(null!=(n=t.stateNode)){r=t.memoizedProps;var i=null!==e?e.memoizedProps:r;e=t.type;var o=t.updateQueue;if(t.updateQueue=null,null!==o){for(n[Gr]=r,"input"===e&&"radio"===r.type&&null!=r.name&&te(n,r),Se(e,i),t=Se(e,r),i=0;i<o.length;i+=2){var s=o[i],l=o[i+1];"style"===s?Ce(n,l):"dangerouslySetInnerHTML"===s?ye(n,l):"children"===s?be(n,l):w(n,s,l,t)}switch(e){case"input":ne(n,r);break;case"textarea":ce(n,r);break;case"select":e=n._wrapperState.wasMultiple,n._wrapperState.wasMultiple=!!r.multiple,null!=(o=r.value)?ae(n,!!r.multiple,o,!1):e!==!!r.multiple&&(null!=r.defaultValue?ae(n,!!r.multiple,r.defaultValue,!0):ae(n,!!r.multiple,r.multiple?[]:"",!1))}}}return;case 6:if(null===t.stateNode)throw Error(a(162));return void(t.stateNode.nodeValue=t.memoizedProps);case 3:return void((n=t.stateNode).hydrate&&(n.hydrate=!1,Ct(n.containerInfo)));case 12:return;case 13:return null!==t.memoizedState&&(Fs=Fi(),ds(t.child,!0)),void ws(t);case 19:return void ws(t);case 17:return;case 23:case 24:return void ds(t,null!==t.memoizedState)}throw Error(a(163))}function ws(e){var t=e.updateQueue;if(null!==t){e.updateQueue=null;var n=e.stateNode;null===n&&(n=e.stateNode=new cs),t.forEach((function(t){var r=Il.bind(null,e,t);n.has(t)||(n.add(t),t.then(r,r))}))}}function Cs(e,t){return null!==e&&(null===(e=e.memoizedState)||null!==e.dehydrated)&&(null!==(t=t.memoizedState)&&null===t.dehydrated)}var _s=Math.ceil,ks=C.ReactCurrentDispatcher,Ss=C.ReactCurrentOwner,Es=0,Ts=null,Os=null,Ps=0,Rs=0,xs=ii(0),Ds=0,js=null,Ms=0,As=0,Is=0,Ns=0,Ls=null,Fs=0,Us=1/0;function qs(){Us=Fi()+500}var Bs,zs=null,Vs=!1,Ws=null,Hs=null,Ys=!1,Xs=null,Gs=90,$s=[],Qs=[],Ks=null,Js=0,Zs=null,el=-1,tl=0,nl=0,rl=null,il=!1;function ol(){return 0!=(48&Es)?Fi():-1!==el?el:el=Fi()}function al(e){if(0==(2&(e=e.mode)))return 1;if(0==(4&e))return 99===Ui()?1:2;if(0===tl&&(tl=Ms),0!==Hi.transition){0!==nl&&(nl=null!==Ls?Ls.pendingLanes:0),e=tl;var t=4186112&~nl;return 0===(t&=-t)&&(0===(t=(e=4186112&~e)&-e)&&(t=8192)),t}return e=Ui(),0!=(4&Es)&&98===e?e=Ut(12,tl):e=Ut(e=function(e){switch(e){case 99:return 15;case 98:return 10;case 97:case 96:return 8;case 95:return 2;default:return 0}}(e),tl),e}function sl(e,t,n){if(50<Js)throw Js=0,Zs=null,Error(a(185));if(null===(e=ll(e,t)))return null;zt(e,t,n),e===Ts&&(Is|=t,4===Ds&&pl(e,Ps));var r=Ui();1===t?0!=(8&Es)&&0==(48&Es)?fl(e):(cl(e,n),0===Es&&(qs(),Vi())):(0==(4&Es)||98!==r&&99!==r||(null===Ks?Ks=new Set([e]):Ks.add(e)),cl(e,n)),Ls=e}function ll(e,t){e.lanes|=t;var n=e.alternate;for(null!==n&&(n.lanes|=t),n=e,e=e.return;null!==e;)e.childLanes|=t,null!==(n=e.alternate)&&(n.childLanes|=t),n=e,e=e.return;return 3===n.tag?n.stateNode:null}function cl(e,t){for(var n=e.callbackNode,r=e.suspendedLanes,i=e.pingedLanes,o=e.expirationTimes,s=e.pendingLanes;0<s;){var l=31-Vt(s),c=1<<l,u=o[l];if(-1===u){if(0==(c&r)||0!=(c&i)){u=t,Nt(c);var p=It;o[l]=10<=p?u+250:6<=p?u+5e3:-1}}else u<=t&&(e.expiredLanes|=c);s&=~c}if(r=Lt(e,e===Ts?Ps:0),t=It,0===r)null!==n&&(n!==ji&&_i(n),e.callbackNode=null,e.callbackPriority=0);else{if(null!==n){if(e.callbackPriority===t)return;n!==ji&&_i(n)}15===t?(n=fl.bind(null,e),null===Ai?(Ai=[n],Ii=Ci(Oi,Wi)):Ai.push(n),n=ji):14===t?n=zi(99,fl.bind(null,e)):n=zi(n=function(e){switch(e){case 15:case 14:return 99;case 13:case 12:case 11:case 10:return 98;case 9:case 8:case 7:case 6:case 4:case 5:return 97;case 3:case 2:case 1:return 95;case 0:return 90;default:throw Error(a(358,e))}}(t),ul.bind(null,e)),e.callbackPriority=t,e.callbackNode=n}}function ul(e){if(el=-1,nl=tl=0,0!=(48&Es))throw Error(a(327));var t=e.callbackNode;if(Pl()&&e.callbackNode!==t)return null;var n=Lt(e,e===Ts?Ps:0);if(0===n)return null;var r=n,i=Es;Es|=16;var o=gl();for(Ts===e&&Ps===r||(qs(),bl(e,r));;)try{_l();break}catch(t){vl(e,t)}if(Ki(),ks.current=o,Es=i,null!==Os?r=0:(Ts=null,Ps=0,r=Ds),0!=(Ms&Is))bl(e,0);else if(0!==r){if(2===r&&(Es|=64,e.hydrate&&(e.hydrate=!1,zr(e.containerInfo)),0!==(n=Ft(e))&&(r=wl(e,n))),1===r)throw t=js,bl(e,0),pl(e,n),cl(e,Fi()),t;switch(e.finishedWork=e.current.alternate,e.finishedLanes=n,r){case 0:case 1:throw Error(a(345));case 2:El(e);break;case 3:if(pl(e,n),(62914560&n)===n&&10<(r=Fs+500-Fi())){if(0!==Lt(e,0))break;if(((i=e.suspendedLanes)&n)!==n){ol(),e.pingedLanes|=e.suspendedLanes&i;break}
vendor: 24,610 bytes, line 92
92e.timeoutHandle=qr(El.bind(null,e),r);break}El(e);break;case 4:if(pl(e,n),(4186112&n)===n)break;for(r=e.eventTimes,i=-1;0<n;){var s=31-Vt(n);o=1<<s,(s=r[s])>i&&(i=s),n&=~o}if(n=i,10<(n=(120>(n=Fi()-n)?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*_s(n/1960))-n)){e.timeoutHandle=qr(El.bind(null,e),n);break}El(e);break;case 5:El(e);break;default:throw Error(a(329))}}return cl(e,Fi()),e.callbackNode===t?ul.bind(null,e):null}function pl(e,t){for(t&=~Ns,t&=~Is,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Vt(t),r=1<<n;e[n]=-1,t&=~r}}function fl(e){if(0!=(48&Es))throw Error(a(327));if(Pl(),e===Ts&&0!=(e.expiredLanes&Ps)){var t=Ps,n=wl(e,t);0!=(Ms&Is)&&(n=wl(e,t=Lt(e,t)))}else n=wl(e,t=Lt(e,0));if(0!==e.tag&&2===n&&(Es|=64,e.hydrate&&(e.hydrate=!1,zr(e.containerInfo)),0!==(t=Ft(e))&&(n=wl(e,t))),1===n)throw n=js,bl(e,0),pl(e,t),cl(e,Fi()),n;return e.finishedWork=e.current.alternate,e.finishedLanes=t,El(e),cl(e,Fi()),null}function dl(e,t){var n=Es;Es|=1;try{return e(t)}finally{0===(Es=n)&&(qs(),Vi())}}function hl(e,t){var n=Es;Es&=-2,Es|=8;try{return e(t)}finally{0===(Es=n)&&(qs(),Vi())}}function ml(e,t){ai(xs,Rs),Rs|=t,Ms|=t}function yl(){Rs=xs.current,oi(xs)}function bl(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(-1!==n&&(e.timeoutHandle=-1,Br(n)),null!==Os)for(n=Os.return;null!==n;){var r=n;switch(r.tag){case 1:null!=(r=r.type.childContextTypes)&&di();break;case 3:xo(),oi(ci),oi(li),Ho();break;case 5:jo(r);break;case 4:xo();break;case 13:case 19:oi(Mo);break;case 10:Ji(r);break;case 23:case 24:yl()}n=n.return}Ts=e,Os=Ul(e.current,null),Ps=Rs=Ms=t,Ds=0,js=null,Ns=Is=As=0}function vl(e,t){for(;;){var n=Os;try{if(Ki(),Yo.current=Oa,Jo){for(var r=$o.memoizedState;null!==r;){var i=r.queue;null!==i&&(i.pending=null),r=r.next}Jo=!1}if(Go=0,Ko=Qo=$o=null,Zo=!1,Ss.current=null,null===n||null===n.return){Ds=1,js=t,Os=null;break}e:{var o=e,a=n.return,s=n,l=t;if(t=Ps,s.flags|=2048,s.firstEffect=s.lastEffect=null,null!==l&&"object"==typeof l&&"function"==typeof l.then){var c=l;if(0==(2&s.mode)){var u=s.alternate;u?(s.updateQueue=u.updateQueue,s.memoizedState=u.memoizedState,s.lanes=u.lanes):(s.updateQueue=null,s.memoizedState=null)}var p=0!=(1&Mo.current),f=a;do{var d;if(d=13===f.tag){var h=f.memoizedState;if(null!==h)d=null!==h.dehydrated;else{var m=f.memoizedProps;d=void 0!==m.fallback&&(!0!==m.unstable_avoidThisFallback||!p)}}if(d){var y=f.updateQueue;if(null===y){var b=new Set;b.add(c),f.updateQueue=b}else y.add(c);if(0==(2&f.mode)){if(f.flags|=64,s.flags|=16384,s.flags&=-2981,1===s.tag)if(null===s.alternate)s.tag=17;else{var v=oo(-1,1);v.tag=2,ao(s,v)}s.lanes|=1;break e}l=void 0,s=t;var g=o.pingCache;if(null===g?(g=o.pingCache=new as,l=new Set,g.set(c,l)):void 0===(l=g.get(c))&&(l=new Set,g.set(c,l)),!l.has(s)){l.add(s);var w=Al.bind(null,o,c,s);c.then(w,w)}f.flags|=4096,f.lanes=t;break e}f=f.return}while(null!==f);l=Error((X(s.type)||"A React component")+" suspended while rendering, but no fallback UI was specified.\n\nAdd a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.")}5!==Ds&&(Ds=2),l=is(l,s),f=a;do{switch(f.tag){case 3:o=l,f.flags|=4096,t&=-t,f.lanes|=t,so(f,ss(0,o,t));break e;case 1:o=l;var C=f.type,_=f.stateNode;if(0==(64&f.flags)&&("function"==typeof C.getDerivedStateFromError||null!==_&&"function"==typeof _.componentDidCatch&&(null===Hs||!Hs.has(_)))){f.flags|=4096,t&=-t,f.lanes|=t,so(f,ls(f,o,t));break e}}f=f.return}while(null!==f)}Sl(n)}catch(e){t=e,Os===n&&null!==n&&(Os=n=n.return);continue}break}}function gl(){var e=ks.current;return ks.current=Oa,null===e?Oa:e}function wl(e,t){var n=Es;Es|=16;var r=gl();for(Ts===e&&Ps===t||bl(e,t);;)try{Cl();break}catch(t){vl(e,t)}if(Ki(),Es=n,ks.current=r,null!==Os)throw Error(a(261));return Ts=null,Ps=0,Ds}function Cl(){for(;null!==Os;)kl(Os)}function _l(){for(;null!==Os&&!ki();)kl(Os)}function kl(e){var t=Bs(e.alternate,e,Rs);e.memoizedProps=e.pendingProps,null===t?Sl(e):Os=t,Ss.current=null}function Sl(e){var t=e;do{var n=t.alternate;if(e=t.return,0==(2048&t.flags)){if(null!==(n=ns(n,t,Rs)))return void(Os=n);if(24!==(n=t).tag&&23!==n.tag||null===n.memoizedState||0!=(1073741824&Rs)||0==(4&n.mode)){for(var r=0,i=n.child;null!==i;)r|=i.lanes|i.childLanes,i=i.sibling;n.childLanes=r}null!==e&&0==(2048&e.flags)&&(null===e.firstEffect&&(e.firstEffect=t.firstEffect),null!==t.lastEffect&&(null!==e.lastEffect&&(e.lastEffect.nextEffect=t.firstEffect),e.lastEffect=t.lastEffect),1<t.flags&&(null!==e.lastEffect?e.lastEffect.nextEffect=t:e.firstEffect=t,e.lastEffect=t))}else{if(null!==(n=rs(t)))return n.flags&=2047,void(Os=n);null!==e&&(e.firstEffect=e.lastEffect=null,e.flags|=2048)}if(null!==(t=t.sibling))return void(Os=t);Os=t=e}while(null!==t);0===Ds&&(Ds=5)}function El(e){var t=Ui();return Bi(99,Tl.bind(null,e,t)),null}function Tl(e,t){do{Pl()}while(null!==Xs);if(0!=(48&Es))throw Error(a(327));var n=e.finishedWork;if(null===n)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(a(177));e.callbackNode=null;var r=n.lanes|n.childLanes,i=r,o=e.pendingLanes&~i;e.pendingLanes=i,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=i,e.mutableReadLanes&=i,e.entangledLanes&=i,i=e.entanglements;for(var s=e.eventTimes,l=e.expirationTimes;0<o;){var c=31-Vt(o),u=1<<c;i[c]=0,s[c]=-1,l[c]=-1,o&=~u}if(null!==Ks&&0==(24&r)&&Ks.has(e)&&Ks.delete(e),e===Ts&&(Os=Ts=null,Ps=0),1<n.flags?null!==n.lastEffect?(n.lastEffect.nextEffect=n,r=n.firstEffect):r=n:r=n.firstEffect,null!==r){if(i=Es,Es|=32,Ss.current=null,Nr=Gt,fr(s=pr())){if("selectionStart"in s)l={start:s.selectionStart,end:s.selectionEnd};else e:if(l=(l=s.ownerDocument)&&l.defaultView||window,(u=l.getSelection&&l.getSelection())&&0!==u.rangeCount){l=u.anchorNode,o=u.anchorOffset,c=u.focusNode,u=u.focusOffset;try{l.nodeType,c.nodeType}catch(e){l=null;break e}var p=0,f=-1,d=-1,h=0,m=0,y=s,b=null;t:for(;;){for(var v;y!==l||0!==o&&3!==y.nodeType||(f=p+o),y!==c||0!==u&&3!==y.nodeType||(d=p+u),3===y.nodeType&&(p+=y.nodeValue.length),null!==(v=y.firstChild);)b=y,y=v;for(;;){if(y===s)break t;if(b===l&&++h===o&&(f=p),b===c&&++m===u&&(d=p),null!==(v=y.nextSibling))break;b=(y=b).parentNode}y=v}l=-1===f||-1===d?null:{start:f,end:d}}else l=null;l=l||{start:0,end:0}}else l=null;Lr={focusedElem:s,selectionRange:l},Gt=!1,rl=null,il=!1,zs=r;do{try{Ol()}catch(e){if(null===zs)throw Error(a(330));Ml(zs,e),zs=zs.nextEffect}}while(null!==zs);rl=null,zs=r;do{try{for(s=e;null!==zs;){var g=zs.flags;if(16&g&&be(zs.stateNode,""),128&g){var w=zs.alternate;if(null!==w){var C=w.ref;null!==C&&("function"==typeof C?C(null):C.current=null)}}switch(1038&g){case 2:bs(zs),zs.flags&=-3;break;case 6:bs(zs),zs.flags&=-3,gs(zs.alternate,zs);break;case 1024:zs.flags&=-1025;break;case 1028:zs.flags&=-1025,gs(zs.alternate,zs);break;case 4:gs(zs.alternate,zs);break;case 8:vs(s,l=zs);var _=l.alternate;ms(l),null!==_&&ms(_)}zs=zs.nextEffect}}catch(e){if(null===zs)throw Error(a(330));Ml(zs,e),zs=zs.nextEffect}}while(null!==zs);if(C=Lr,w=pr(),g=C.focusedElem,s=C.selectionRange,w!==g&&g&&g.ownerDocument&&function e(t,n){return!(!t||!n)&&(t===n||(!t||3!==t.nodeType)&&(n&&3===n.nodeType?e(t,n.parentNode):"contains"in t?t.contains(n):!!t.compareDocumentPosition&&!!(16&t.compareDocumentPosition(n))))}(g.ownerDocument.documentElement,g)){null!==s&&fr(g)&&(w=s.start,void 0===(C=s.end)&&(C=w),"selectionStart"in g?(g.selectionStart=w,g.selectionEnd=Math.min(C,g.value.length)):(C=(w=g.ownerDocument||document)&&w.defaultView||window).getSelection&&(C=C.getSelection(),l=g.textContent.length,_=Math.min(s.start,l),s=void 0===s.end?_:Math.min(s.end,l),!C.extend&&_>s&&(l=s,s=_,_=l),l=ur(g,_),o=ur(g,s),l&&o&&(1!==C.rangeCount||C.anchorNode!==l.node||C.anchorOffset!==l.offset||C.focusNode!==o.node||C.focusOffset!==o.offset)&&((w=w.createRange()).setStart(l.node,l.offset),C.removeAllRanges(),_>s?(C.addRange(w),C.extend(o.node,o.offset)):(w.setEnd(o.node,o.offset),C.addRange(w))))),w=[];for(C=g;C=C.parentNode;)1===C.nodeType&&w.push({element:C,left:C.scrollLeft,top:C.scrollTop});for("function"==typeof g.focus&&g.focus(),g=0;g<w.length;g++)(C=w[g]).element.scrollLeft=C.left,C.element.scrollTop=C.top}Gt=!!Nr,Lr=Nr=null,e.current=n,zs=r;do{try{for(g=e;null!==zs;){var k=zs.flags;if(36&k&&fs(g,zs.alternate,zs),128&k){w=void 0;var S=zs.ref;if(null!==S){var E=zs.stateNode;switch(zs.tag){case 5:w=E;break;default:w=E}"function"==typeof S?S(w):S.current=w}}zs=zs.nextEffect}}catch(e){if(null===zs)throw Error(a(330));Ml(zs,e),zs=zs.nextEffect}}while(null!==zs);zs=null,Mi(),Es=i}else e.current=n;if(Ys)Ys=!1,Xs=e,Gs=t;else for(zs=r;null!==zs;)t=zs.nextEffect,zs.nextEffect=null,8&zs.flags&&((k=zs).sibling=null,k.stateNode=null),zs=t;if(0===(r=e.pendingLanes)&&(Hs=null),1===r?e===Zs?Js++:(Js=0,Zs=e):Js=0,n=n.stateNode,gi&&"function"==typeof gi.onCommitFiberRoot)try{gi.onCommitFiberRoot(vi,n,void 0,64==(64&n.current.flags))}catch(e){}if(cl(e,Fi()),Vs)throw Vs=!1,e=Ws,Ws=null,e;return 0!=(8&Es)||Vi(),null}function Ol(){for(;null!==zs;){var e=zs.alternate;il||null===rl||(0!=(8&zs.flags)?Ze(zs,rl)&&(il=!0):13===zs.tag&&Cs(e,zs)&&Ze(zs,rl)&&(il=!0));var t=zs.flags;0!=(256&t)&&ps(e,zs),0==(512&t)||Ys||(Ys=!0,zi(97,(function(){return Pl(),null}))),zs=zs.nextEffect}}function Pl(){if(90!==Gs){var e=97<Gs?97:Gs;return Gs=90,Bi(e,Dl)}return!1}function Rl(e,t){$s.push(t,e),Ys||(Ys=!0,zi(97,(function(){return Pl(),null})))}function xl(e,t){Qs.push(t,e),Ys||(Ys=!0,zi(97,(function(){return Pl(),null})))}function Dl(){if(null===Xs)return!1;var e=Xs;if(Xs=null,0!=(48&Es))throw Error(a(331));var t=Es;Es|=32;var n=Qs;Qs=[];for(var r=0;r<n.length;r+=2){var i=n[r],o=n[r+1],s=i.destroy;if(i.destroy=void 0,"function"==typeof s)try{s()}catch(e){if(null===o)throw Error(a(330));Ml(o,e)}}for(n=$s,$s=[],r=0;r<n.length;r+=2){i=n[r],o=n[r+1];try{var l=i.create;i.destroy=l()}catch(e){if(null===o)throw Error(a(330));Ml(o,e)}}for(l=e.current.firstEffect;null!==l;)e=l.nextEffect,l.nextEffect=null,8&l.flags&&(l.sibling=null,l.stateNode=null),l=e;return Es=t,Vi(),!0}function jl(e,t,n){ao(e,t=ss(0,t=is(n,t),1)),t=ol(),null!==(e=ll(e,1))&&(zt(e,1,t),cl(e,t))}function Ml(e,t){if(3===e.tag)jl(e,e,t);else for(var n=e.return;null!==n;){if(3===n.tag){jl(n,e,t);break}if(1===n.tag){var r=n.stateNode;if("function"==typeof n.type.getDerivedStateFromError||"function"==typeof r.componentDidCatch&&(null===Hs||!Hs.has(r))){var i=ls(n,e=is(t,e),1);if(ao(n,i),i=ol(),null!==(n=ll(n,1)))zt(n,1,i),cl(n,i);else if("function"==typeof r.componentDidCatch&&(null===Hs||!Hs.has(r)))try{r.componentDidCatch(t,e)}catch(e){}break}}n=n.return}}function Al(e,t,n){var r=e.pingCache;null!==r&&r.delete(t),t=ol(),e.pingedLanes|=e.suspendedLanes&n,Ts===e&&(Ps&n)===n&&(4===Ds||3===Ds&&(62914560&Ps)===Ps&&500>Fi()-Fs?bl(e,0):Ns|=n),cl(e,t)}function Il(e,t){var n=e.stateNode;null!==n&&n.delete(t),0===(t=0)&&(0==(2&(t=e.mode))?t=1:0==(4&t)?t=99===Ui()?1:2:(0===tl&&(tl=Ms),0===(t=qt(62914560&~tl))&&(t=4194304))),n=ol(),null!==(e=ll(e,t))&&(zt(e,t,n),cl(e,n))}function Nl(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.flags=0,this.lastEffect=this.firstEffect=this.nextEffect=null,this.childLanes=this.lanes=0,this.alternate=null}function Ll(e,t,n,r){return new Nl(e,t,n,r)}function Fl(e){return!(!(e=e.prototype)||!e.isReactComponent)}function Ul(e,t){var n=e.alternate;return null===n?((n=Ll(e.tag,t,e.key,e.mode)).elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.nextEffect=null,n.firstEffect=null,n.lastEffect=null),n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function ql(e,t,n,r,i,o){var s=2;if(r=e,"function"==typeof e)Fl(e)&&(s=1);else if("string"==typeof e)s=5;else e:switch(e){case S:return Bl(n.children,i,o,t);case N:s=8,i|=16;break;case E:s=8,i|=1;break;case T:return(e=Ll(12,n,t,8|i)).elementType=T,e.type=T,e.lanes=o,e;case x:return(e=Ll(13,n,t,i)).type=x,e.elementType=x,e.lanes=o,e;case D:return(e=Ll(19,n,t,i)).elementType=D,e.lanes=o,e;case L:return zl(n,i,o,t);case F:return(e=Ll(24,n,t,i)).elementType=F,e.lanes=o,e;default:if("object"==typeof e&&null!==e)switch(e.$$typeof){case O:s=10;break e;case P:s=9;break e;case R:s=11;break e;case j:s=14;break e;case M:s=16,r=null;break e;case A:s=22;break e}throw Error(a(130,null==e?e:typeof e,""))}return(t=Ll(s,n,t,i)).elementType=e,t.type=r,t.lanes=o,t}function Bl(e,t,n,r){return(e=Ll(7,e,r,t)).lanes=n,e}function zl(e,t,n,r){return(e=Ll(23,e,r,t)).elementType=L,e.lanes=n,e}function Vl(e,t,n){return(e=Ll(6,e,null,t)).lanes=n,e}function Wl(e,t,n){return(t=Ll(4,null!==e.children?e.children:[],e.key,t)).lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Hl(e,t,n){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.pendingContext=this.context=null,this.hydrate=n,this.callbackNode=null,this.callbackPriority=0,this.eventTimes=Bt(0),this.expirationTimes=Bt(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Bt(0),this.mutableSourceEagerHydrationData=null}function Yl(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:k,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}function Xl(e,t,n,r){var i=t.current,o=ol(),s=al(i);e:if(n){t:{if($e(n=n._reactInternals)!==n||1!==n.tag)throw Error(a(170));var l=n;do{switch(l.tag){case 3:l=l.stateNode.context;break t;case 1:if(fi(l.type)){l=l.stateNode.__reactInternalMemoizedMergedChildContext;break t}}l=l.return}while(null!==l);throw Error(a(171))}if(1===n.tag){var c=n.type;if(fi(c)){n=mi(n,c,l);break e}}n=l}else n=si;return null===t.context?t.context=n:t.pendingContext=n,(t=oo(o,s)).payload={element:e},null!==(r=void 0===r?null:r)&&(t.callback=r),ao(i,t),sl(i,s,o),s}function Gl(e){if(!(e=e.current).child)return null;switch(e.child.tag){case 5:default:return e.child.stateNode}}function $l(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var n=e.retryLane;e.retryLane=0!==n&&n<t?n:t}}function Ql(e,t){$l(e,t),(e=e.alternate)&&$l(e,t)}function Kl(e,t,n){var r=null!=n&&null!=n.hydrationOptions&&n.hydrationOptions.mutableSources||null;if(n=new Hl(e,t,null!=n&&!0===n.hydrate),t=Ll(3,null,null,2===t?7:1===t?3:0),n.current=t,t.stateNode=n,ro(t),e[$r]=n.current,Or(8===e.nodeType?e.parentNode:e),r)for(e=0;e<r.length;e++){var i=(t=r[e])._getVersion;i=i(t._source),null==n.mutableSourceEagerHydrationData?n.mutableSourceEagerHydrationData=[t,i]:n.mutableSourceEagerHydrationData.push(t,i)}this._internalRoot=n}function Jl(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType&&(8!==e.nodeType||" react-mount-point-unstable "!==e.nodeValue))}function Zl(e,t,n,r,i){var o=n._reactRootContainer;if(o){var a=o._internalRoot;if("function"==typeof i){var s=i;i=function(){var e=Gl(a);s.call(e)}}Xl(t,a,e,i)}else{if(o=n._reactRootContainer=function(e,t){if(t||(t=!(!(t=e?9===e.nodeType?e.documentElement:e.firstChild:null)||1!==t.nodeType||!t.hasAttribute("data-reactroot"))),!t)for(var n;n=e.lastChild;)e.removeChild(n);return new Kl(e,0,t?{hydrate:!0}:void 0)}(n,r),a=o._internalRoot,"function"==typeof i){var l=i;i=function(){var e=Gl(a);l.call(e)}}hl((function(){Xl(t,a,e,i)}))}return Gl(a)}function ec(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!Jl(t))throw Error(a(200));return Yl(e,t,null,n)}Bs=function(e,t,n){var r=t.lanes;if(null!==e)if(e.memoizedProps!==t.pendingProps||ci.current)ja=!0;else{if(0==(n&r)){switch(ja=!1,t.tag){case 3:za(t),Vo();break;case 5:Do(t);break;case 1:fi(t.type)&&yi(t);break;case 4:Ro(t,t.stateNode.containerInfo);break;case 10:r=t.memoizedProps.value;var i=t.type._context;ai(Xi,i._currentValue),i._currentValue=r;break;case 13:if(null!==t.memoizedState)return 0!=(n&t.child.childLanes)?Xa(e,t,n):(ai(Mo,1&Mo.current),null!==(t=es(e,t,n))?t.sibling:null);ai(Mo,1&Mo.current);break;case 19:if(r=0!=(n&t.childLanes),0!=(64&e.flags)){if(r)return Za(e,t,n);t.flags|=64}if(null!==(i=t.memoizedState)&&(i.rendering=null,i.tail=null,i.lastEffect=null),ai(Mo,Mo.current),r)break;return null;case 23:case 24:return t.lanes=0,La(e,t,n)}return es(e,t,n)}ja=0!=(16384&e.flags)}else ja=!1;switch(t.lanes=0,t.tag){case 2:if(r=t.type,null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=pi(t,li.current),eo(t,n),i=na(null,t,r,e,i,n),t.flags|=1,"object"==typeof i&&null!==i&&"function"==typeof i.render&&void 0===i.$$typeof){if(t.tag=1,t.memoizedState=null,t.updateQueue=null,fi(r)){var o=!0;yi(t)}else o=!1;t.memoizedState=null!==i.state&&void 0!==i.state?i.state:null,ro(t);var s=r.getDerivedStateFromProps;"function"==typeof s&&po(t,r,s,e),i.updater=fo,t.stateNode=i,i._reactInternals=t,bo(t,r,e,n),t=Ba(null,t,r,!0,o,n)}else t.tag=0,Ma(null,t,i,n),t=t.child;return t;case 16:i=t.elementType;e:{switch(null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=(o=i._init)(i._payload),t.type=i,o=t.tag=function(e){if("function"==typeof e)return Fl(e)?1:0;if(null!=e){if((e=e.$$typeof)===R)return 11;if(e===j)return 14}return 2}(i),e=Yi(i,e),o){case 0:t=Ua(null,t,i,e,n);break e;case 1:t=qa(null,t,i,e,n);break e;case 11:t=Aa(null,t,i,e,n);break e;case 14:t=Ia(null,t,i,Yi(i.type,e),r,n);break e}throw Error(a(306,i,""))}return t;case 0:return r=t.type,i=t.pendingProps,Ua(e,t,r,i=t.elementType===r?i:Yi(r,i),n);case 1:return r=t.type,i=t.pendingProps,qa(e,t,r,i=t.elementType===r?i:Yi(r,i),n);case 3:if(za(t),r=t.updateQueue,null===e||null===r)throw Error(a(282));if(r=t.pendingProps,i=null!==(i=t.memoizedState)?i.element:null,io(e,t),lo(t,r,null,n),(r=t.memoizedState.element)===i)Vo(),t=es(e,t,n);else{if((o=(i=t.stateNode).hydrate)&&(No=Vr(t.stateNode.containerInfo.firstChild),Io=t,o=Lo=!0),o){if(null!=(e=i.mutableSourceEagerHydrationData))for(i=0;i<e.length;i+=2)(o=e[i])._workInProgressVersionPrimary=e[i+1],Wo.push(o);for(n=ko(t,null,r,n),t.child=n;n;)n.flags=-3&n.flags|1024,n=n.sibling}else Ma(e,t,r,n),Vo();t=t.child}return t;case 5:return Do(t),null===e&&qo(t),r=t.type,i=t.pendingProps,o=null!==e?e.memoizedProps:null,s=i.children,Ur(r,i)?s=null:null!==o&&Ur(r,o)&&(t.flags|=16),Fa(e,t),Ma(e,t,s,n),t.child;case 6:return null===e&&qo(t),null;case 13:return Xa(e,t,n);case 4:return Ro(t,t.stateNode.containerInfo),r=t.pendingProps,null===e?t.child=_o(t,null,r,n):Ma(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,Aa(e,t,r,i=t.elementType===r?i:Yi(r,i),n);case 7:return Ma(e,t,t.pendingProps,n),t.child;case 8:case 12:return Ma(e,t,t.pendingProps.children,n),t.child;case 10:e:{r=t.type._context,i=t.pendingProps,s=t.memoizedProps,o=i.value;var l=t.type._context;if(ai(Xi,l._currentValue),l._currentValue=o,null!==s)if(l=s.value,0===(o=ar(l,o)?0:0|("function"==typeof r._calculateChangedBits?r._calculateChangedBits(l,o):1073741823))){if(s.children===i.children&&!ci.current){t=es(e,t,n);break e}}else for(null!==(l=t.child)&&(l.return=t);null!==l;){var c=l.dependencies;if(null!==c){s=l.child;for(var u=c.firstContext;null!==u;){if(u.context===r&&0!=(u.observedBits&o)){1===l.tag&&((u=oo(-1,n&-n)).tag=2,ao(l,u)),l.lanes|=n,null!==(u=l.alternate)&&(u.lanes|=n),Zi(l.return,n),c.lanes|=n;break}u=u.next}}else s=10===l.tag&&l.type===t.type?null:l.child;if(null!==s)s.return=l;else for(s=l;null!==s;){if(s===t){s=null;break}if(null!==(l=s.sibling)){l.return=s.return,s=l;break}s=s.return}l=s}Ma(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=(o=t.pendingProps).children,eo(t,n),r=r(i=to(i,o.unstable_observedBits)),t.flags|=1,Ma(e,t,r,n),t.child;case 14:return o=Yi(i=t.type,t.pendingProps),Ia(e,t,i,o=Yi(i.type,o),r,n);case 15:return Na(e,t,t.type,t.pendingProps,r,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Yi(r,i),null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),t.tag=1,fi(r)?(e=!0,yi(t)):e=!1,eo(t,n),mo(t,r,i),bo(t,r,i,n),Ba(null,t,r,!0,e,n);case 19:return Za(e,t,n);case 23:case 24:return La(e,t,n)}throw Error(a(156,t.tag))},Kl.prototype.render=function(e){Xl(e,this._internalRoot,null,null)},Kl.prototype.unmount=function(){var e=this._internalRoot,t=e.containerInfo;Xl(null,e,null,(function(){t[$r]=null}))},et=function(e){13===e.tag&&(sl(e,4,ol()),Ql(e,4))},tt=function(e){13===e.tag&&(sl(e,67108864,ol()),Ql(e,67108864))},nt=function(e){if(13===e.tag){var t=ol(),n=al(e);sl(e,n,t),Ql(e,n)}},rt=function(e,t){return t()},Te=function(e,t,n){switch(t){case"input":if(ne(e,n),t=n.name,"radio"===n.type&&null!=t){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=ei(r);if(!i)throw Error(a(90));K(r),ne(r,i)}}}break;case"textarea":ce(e,n);break;case"select":null!=(t=n.value)&&ae(e,!!n.multiple,t,!1)}},je=dl,Me=function(e,t,n,r,i){var o=Es;Es|=4;try{return Bi(98,e.bind(null,t,n,r,i))}finally{0===(Es=o)&&(qs(),Vi())}},Ae=function(){0==(49&Es)&&(function(){if(null!==Ks){var e=Ks;Ks=null,e.forEach((function(e){e.expiredLanes|=24&e.pendingLanes,cl(e,Fi())}))}Vi()}(),Pl())},Ie=function(e,t){var n=Es;Es|=2;try{return e(t)}finally{0===(Es=n)&&(qs(),Vi())}};var tc={Events:[Jr,Zr,ei,xe,De,Pl,{current:!1}]},nc={findFiberByHostInstance:Kr,bundleType:0,version:"17.0.1",rendererPackageName:"react-dom"},rc={bundleType:nc.bundleType,version:nc.version,rendererPackageName:nc.rendererPackageName,rendererConfig:nc.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:C.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return null===(e=Je(e))?null:e.stateNode},findFiberByHostInstance:nc.findFiberByHostInstance||function(){return null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null};if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var ic=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ic.isDisabled&&ic.supportsFiber)try{vi=ic.inject(rc),gi=ic}catch(e){}}n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=tc,n.createPortal=ec,n.findDOMNode=function(e){if(null==e)return null;if(1===e.nodeType)return e;var t=e._reactInternals;if(void 0===t){if("function"==typeof e.render)throw Error(a(188));throw Error(a(268,Object.keys(e)))}return e=null===(e=Je(t))?null:e.stateNode},n.flushSync=function(e,t){var n=Es;if(0!=(48&n))return e(t);Es|=1;try{if(e)return Bi(99,e.bind(null,t))}finally{Es=n,Vi()}},n.hydrate=function(e,t,n){if(!Jl(t))throw Error(a(200));return Zl(null,e,t,!0,n)},n.render=function(e,t,n){if(!Jl(t))throw Error(a(200));return Zl(null,e,t,!1,n)},n.unmountComponentAtNode=function(e){if(!Jl(e))throw Error(a(40));return!!e._reactRootContainer&&(hl((function(){Zl(null,null,e,!1,(function(){e._reactRootContainer=null,e[$r]=null}))})),!0)},n.unstable_batchedUpdates=dl,n.unstable_createPortal=function(e,t){return ec(e,t,2<arguments.length&&void 0!==arguments[2]?arguments[2]:null)},n.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!Jl(n))throw Error(a(200));if(null==e||void 0===e._reactInternals)throw Error(a(38));return Zl(e,t,n,!1,r)},n.version="17.0.1"},{"object-assign":247,react:307,scheduler:323}],268:[function(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE){0;try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}}(),t.exports=e("./cjs/react-dom.production.min.js")},{"./cjs/react-dom.development.js":266,"./cjs/react-dom.production.min.js":267}],269:[function(e,t,n){"use strict";t.exports=e("./cjs/react-dom-server.browser.production.min.js")},{"./cjs/react-dom-server.browser.development.js":264,"./cjs/react-dom-server.browser.production.min.js":265}],270:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"DraggableCore",{enumerable:!0,get:function(){return u.default}}),n.default=void 0;
vendor: 27,852 bytes, lines 92-101
92var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==h(e)&&"function"!=typeof e)return{default:e};var t=d();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(e("react")),i=f(e("prop-types")),o=f(e("react-dom")),a=f(e("classnames")),s=e("./utils/domFns"),l=e("./utils/positionFns"),c=e("./utils/shims"),u=f(e("./DraggableCore")),p=f(e("./utils/log"));function f(e){return e&&e.__esModule?e:{default:e}}function d(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return d=function(){return e},e}function h(e){return(h="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function m(){return(m=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function y(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function b(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return v(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return v(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function v(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function g(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function w(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?g(Object(n),!0).forEach((function(t){P(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function C(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _(e,t,n){return t&&C(e.prototype,t),n&&C(e,n),e}function k(e,t){return(k=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function S(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=O(e);if(t){var i=O(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return E(this,n)}}function E(e,t){return!t||"object"!==h(t)&&"function"!=typeof t?T(e):t}function T(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function O(e){return(O=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function P(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var R=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&k(e,t)}(n,e);var t=S(n);function n(e){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),P(T(r=t.call(this,e)),"onDragStart",(function(e,t){if((0,p.default)("Draggable: onDragStart: %j",t),!1===r.props.onStart(e,(0,l.createDraggableData)(T(r),t)))return!1;r.setState({dragging:!0,dragged:!0})})),P(T(r),"onDrag",(function(e,t){if(!r.state.dragging)return!1;(0,p.default)("Draggable: onDrag: %j",t);var n=(0,l.createDraggableData)(T(r),t),i={x:n.x,y:n.y};if(r.props.bounds){var o=i.x,a=i.y;i.x+=r.state.slackX,i.y+=r.state.slackY;var s=b((0,l.getBoundPosition)(T(r),i.x,i.y),2),c=s[0],u=s[1];i.x=c,i.y=u,i.slackX=r.state.slackX+(o-i.x),i.slackY=r.state.slackY+(a-i.y),n.x=i.x,n.y=i.y,n.deltaX=i.x-r.state.x,n.deltaY=i.y-r.state.y}if(!1===r.props.onDrag(e,n))return!1;r.setState(i)})),P(T(r),"onDragStop",(function(e,t){if(!r.state.dragging)return!1;if(!1===r.props.onStop(e,(0,l.createDraggableData)(T(r),t)))return!1;(0,p.default)("Draggable: onDragStop: %j",t);var n={dragging:!1,slackX:0,slackY:0};if(Boolean(r.props.position)){var i=r.props.position,o=i.x,a=i.y;n.x=o,n.y=a}r.setState(n)})),r.state={dragging:!1,dragged:!1,x:e.position?e.position.x:e.defaultPosition.x,y:e.position?e.position.y:e.defaultPosition.y,prevPropsPosition:w({},e.position),slackX:0,slackY:0,isElementSVG:!1},!e.position||e.onDrag||e.onStop||console.warn("A `position` was applied to this <Draggable>, without drag handlers. This will make this component effectively undraggable. Please attach `onDrag` or `onStop` handlers so you can adjust the `position` of this element."),r}return _(n,null,[{key:"getDerivedStateFromProps",value:function(e,t){var n=e.position,r=t.prevPropsPosition;return!n||r&&n.x===r.x&&n.y===r.y?null:((0,p.default)("Draggable: getDerivedStateFromProps %j",{position:n,prevPropsPosition:r}),{x:n.x,y:n.y,prevPropsPosition:w({},n)})}}]),_(n,[{key:"componentDidMount",value:function(){void 0!==window.SVGElement&&this.findDOMNode()instanceof window.SVGElement&&this.setState({isElementSVG:!0})}},{key:"componentWillUnmount",value:function(){this.setState({dragging:!1})}},{key:"findDOMNode",value:function(){return this.props.nodeRef?this.props.nodeRef.current:o.default.findDOMNode(this)}},{key:"render",value:function(){var e,t=this.props,n=(t.axis,t.bounds,t.children),i=t.defaultPosition,o=t.defaultClassName,c=t.defaultClassNameDragging,p=t.defaultClassNameDragged,f=t.position,d=t.positionOffset,h=(t.scale,y(t,["axis","bounds","children","defaultPosition","defaultClassName","defaultClassNameDragging","defaultClassNameDragged","position","positionOffset","scale"])),b={},v=null,g=!Boolean(f)||this.state.dragging,C=f||i,_={x:(0,l.canDragX)(this)&&g?this.state.x:C.x,y:(0,l.canDragY)(this)&&g?this.state.y:C.y};this.state.isElementSVG?v=(0,s.createSVGTransform)(_,d):b=(0,s.createCSSTransform)(_,d);var k=(0,a.default)(n.props.className||"",o,(P(e={},c,this.state.dragging),P(e,p,this.state.dragged),e));return r.createElement(u.default,m({},h,{onStart:this.onDragStart,onDrag:this.onDrag,onStop:this.onDragStop}),r.cloneElement(r.Children.only(n),{className:k,style:w(w({},n.props.style),b),transform:v}))}}]),n}(r.Component);n.default=R,P(R,"displayName","Draggable"),P(R,"propTypes",w(w({},u.default.propTypes),{},{axis:i.default.oneOf(["both","x","y","none"]),bounds:i.default.oneOfType([i.default.shape({left:i.default.number,right:i.default.number,top:i.default.number,bottom:i.default.number}),i.default.string,i.default.oneOf([!1])]),defaultClassName:i.default.string,defaultClassNameDragging:i.default.string,defaultClassNameDragged:i.default.string,defaultPosition:i.default.shape({x:i.default.number,y:i.default.number}),positionOffset:i.default.shape({x:i.default.oneOfType([i.default.number,i.default.string]),y:i.default.oneOfType([i.default.number,i.default.string])}),position:i.default.shape({x:i.default.number,y:i.default.number}),className:c.dontSetMe,style:c.dontSetMe,transform:c.dontSetMe})),P(R,"defaultProps",w(w({},u.default.defaultProps),{},{axis:"both",bounds:!1,defaultClassName:"react-draggable",defaultClassNameDragging:"react-draggable-dragging",defaultClassNameDragged:"react-draggable-dragged",defaultPosition:{x:0,y:0},position:null,scale:1}))},{"./DraggableCore":271,"./utils/domFns":273,"./utils/log":275,"./utils/positionFns":276,"./utils/shims":277,classnames:156,"prop-types":256,react:307,"react-dom":268}],271:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==f(e)&&"function"!=typeof e)return{default:e};var t=p();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(e("react")),i=u(e("prop-types")),o=u(e("react-dom")),a=e("./utils/domFns"),s=e("./utils/positionFns"),l=e("./utils/shims"),c=u(e("./utils/log"));function u(e){return e&&e.__esModule?e:{default:e}}function p(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return p=function(){return e},e}function f(e){return(f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function d(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return h(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return h(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function h(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function m(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function y(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function b(e,t){return(b=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=C(e);if(t){var i=C(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return g(this,n)}}function g(e,t){return!t||"object"!==f(t)&&"function"!=typeof t?w(e):t}function w(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function C(e){return(C=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function _(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var k={start:"touchstart",move:"touchmove",stop:"touchend"},S={start:"mousedown",move:"mousemove",stop:"mouseup"},E=S,T=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&b(e,t)}(u,e);var t,n,i,l=v(u);function u(){var e;m(this,u);for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return _(w(e=l.call.apply(l,[this].concat(n))),"state",{dragging:!1,lastX:NaN,lastY:NaN,touchIdentifier:null}),_(w(e),"mounted",!1),_(w(e),"handleDragStart",(function(t){if(e.props.onMouseDown(t),!e.props.allowAnyClick&&"number"==typeof t.button&&0!==t.button)return!1;var n=e.findDOMNode();if(!n||!n.ownerDocument||!n.ownerDocument.body)throw new Error("<DraggableCore> not mounted on DragStart!");var r=n.ownerDocument;if(!(e.props.disabled||!(t.target instanceof r.defaultView.Node)||e.props.handle&&!(0,a.matchesSelectorAndParentsTo)(t.target,e.props.handle,n)||e.props.cancel&&(0,a.matchesSelectorAndParentsTo)(t.target,e.props.cancel,n))){"touchstart"===t.type&&t.preventDefault();var i=(0,a.getTouchIdentifier)(t);e.setState({touchIdentifier:i});var o=(0,s.getControlPosition)(t,i,w(e));if(null!=o){var l=o.x,u=o.y,p=(0,s.createCoreData)(w(e),l,u);(0,c.default)("DraggableCore: handleDragStart: %j",p),(0,c.default)("calling",e.props.onStart),!1!==e.props.onStart(t,p)&&!1!==e.mounted&&(e.props.enableUserSelectHack&&(0,a.addUserSelectStyles)(r),e.setState({dragging:!0,lastX:l,lastY:u}),(0,a.addEvent)(r,E.move,e.handleDrag),(0,a.addEvent)(r,E.stop,e.handleDragStop))}}})),_(w(e),"handleDrag",(function(t){var n=(0,s.getControlPosition)(t,e.state.touchIdentifier,w(e));if(null!=n){var r=n.x,i=n.y;if(Array.isArray(e.props.grid)){var o=r-e.state.lastX,a=i-e.state.lastY,l=d((0,s.snapToGrid)(e.props.grid,o,a),2);if(o=l[0],a=l[1],!o&&!a)return;r=e.state.lastX+o,i=e.state.lastY+a}var u=(0,s.createCoreData)(w(e),r,i);if((0,c.default)("DraggableCore: handleDrag: %j",u),!1!==e.props.onDrag(t,u)&&!1!==e.mounted)e.setState({lastX:r,lastY:i});else try{e.handleDragStop(new MouseEvent("mouseup"))}catch(t){var p=document.createEvent("MouseEvents");p.initMouseEvent("mouseup",!0,!0,window,0,0,0,0,0,!1,!1,!1,!1,0,null),e.handleDragStop(p)}}})),_(w(e),"handleDragStop",(function(t){if(e.state.dragging){var n=(0,s.getControlPosition)(t,e.state.touchIdentifier,w(e));if(null!=n){var r=n.x,i=n.y,o=(0,s.createCoreData)(w(e),r,i);if(!1===e.props.onStop(t,o)||!1===e.mounted)return!1;var l=e.findDOMNode();l&&e.props.enableUserSelectHack&&(0,a.removeUserSelectStyles)(l.ownerDocument),(0,c.default)("DraggableCore: handleDragStop: %j",o),e.setState({dragging:!1,lastX:NaN,lastY:NaN}),l&&((0,c.default)("DraggableCore: Removing handlers"),(0,a.removeEvent)(l.ownerDocument,E.move,e.handleDrag),(0,a.removeEvent)(l.ownerDocument,E.stop,e.handleDragStop))}}})),_(w(e),"onMouseDown",(function(t){return E=S,e.handleDragStart(t)})),_(w(e),"onMouseUp",(function(t){return E=S,e.handleDragStop(t)})),_(w(e),"onTouchStart",(function(t){return E=k,e.handleDragStart(t)})),_(w(e),"onTouchEnd",(function(t){return E=k,e.handleDragStop(t)})),e}return t=u,(n=[{key:"componentDidMount",value:function(){this.mounted=!0;var e=this.findDOMNode();e&&(0,a.addEvent)(e,k.start,this.onTouchStart,{passive:!1})}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var e=this.findDOMNode();if(e){var t=e.ownerDocument;(0,a.removeEvent)(t,S.move,this.handleDrag),(0,a.removeEvent)(t,k.move,this.handleDrag),(0,a.removeEvent)(t,S.stop,this.handleDragStop),(0,a.removeEvent)(t,k.stop,this.handleDragStop),(0,a.removeEvent)(e,k.start,this.onTouchStart,{passive:!1}),this.props.enableUserSelectHack&&(0,a.removeUserSelectStyles)(t)}}},{key:"findDOMNode",value:function(){return this.props.nodeRef?this.props.nodeRef.current:o.default.findDOMNode(this)}},{key:"render",value:function(){return r.cloneElement(r.Children.only(this.props.children),{onMouseDown:this.onMouseDown,onMouseUp:this.onMouseUp,onTouchEnd:this.onTouchEnd})}}])&&y(t.prototype,n),i&&y(t,i),u}(r.Component);n.default=T,_(T,"displayName","DraggableCore"),_(T,"propTypes",{allowAnyClick:i.default.bool,disabled:i.default.bool,enableUserSelectHack:i.default.bool,offsetParent:function(e,t){if(e[t]&&1!==e[t].nodeType)throw new Error("Draggable's offsetParent must be a DOM Node.")},grid:i.default.arrayOf(i.default.number),handle:i.default.string,cancel:i.default.string,nodeRef:i.default.object,onStart:i.default.func,onDrag:i.default.func,onStop:i.default.func,onMouseDown:i.default.func,scale:i.default.number,className:l.dontSetMe,style:l.dontSetMe,transform:l.dontSetMe}),_(T,"defaultProps",{allowAnyClick:!1,cancel:null,disabled:!1,enableUserSelectHack:!0,offsetParent:null,handle:null,grid:null,transform:null,onStart:function(){},onDrag:function(){},onStop:function(){},onMouseDown:function(){},scale:1})},{"./utils/domFns":273,"./utils/log":275,"./utils/positionFns":276,"./utils/shims":277,"prop-types":256,react:307,"react-dom":268}],272:[function(e,t,n){"use strict";var r=e("./Draggable"),i=r.default,o=r.DraggableCore;t.exports=i,t.exports.default=i,t.exports.DraggableCore=o},{"./Draggable":270}],273:[function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(n,"__esModule",{value:!0}),n.matchesSelector=p,n.matchesSelectorAndParentsTo=function(e,t,n){var r=e;do{if(p(r,t))return!0;if(r===n)return!1;r=r.parentNode}while(r);return!1},n.addEvent=function(e,t,n,r){if(!e)return;var i=l({capture:!0},r);e.addEventListener?e.addEventListener(t,n,i):e.attachEvent?e.attachEvent("on"+t,n):e["on"+t]=n},n.removeEvent=function(e,t,n,r){if(!e)return;var i=l({capture:!0},r);e.removeEventListener?e.removeEventListener(t,n,i):e.detachEvent?e.detachEvent("on"+t,n):e["on"+t]=null},n.outerHeight=function(e){var t=e.clientHeight,n=e.ownerDocument.defaultView.getComputedStyle(e);return t+=(0,i.int)(n.borderTopWidth),t+=(0,i.int)(n.borderBottomWidth)},n.outerWidth=function(e){var t=e.clientWidth,n=e.ownerDocument.defaultView.getComputedStyle(e);return t+=(0,i.int)(n.borderLeftWidth),t+=(0,i.int)(n.borderRightWidth)},n.innerHeight=function(e){var t=e.clientHeight,n=e.ownerDocument.defaultView.getComputedStyle(e);return t-=(0,i.int)(n.paddingTop),t-=(0,i.int)(n.paddingBottom)},n.innerWidth=function(e){var t=e.clientWidth,n=e.ownerDocument.defaultView.getComputedStyle(e);return t-=(0,i.int)(n.paddingLeft),t-=(0,i.int)(n.paddingRight)},n.offsetXYFromParent=function(e,t,n){var r=t===t.ownerDocument.body?{left:0,top:0}:t.getBoundingClientRect(),i=(e.clientX+t.scrollLeft-r.left)/n,o=(e.clientY+t.scrollTop-r.top)/n;return{x:i,y:o}},n.createCSSTransform=function(e,t){var n=f(e,t,"px");return c({},(0,o.browserPrefixToKey)("transform",o.default),n)},n.createSVGTransform=function(e,t){return f(e,t,"")},n.getTranslation=f,n.getTouch=function(e,t){return e.targetTouches&&(0,i.findInArray)(e.targetTouches,(function(e){return t===e.identifier}))||e.changedTouches&&(0,i.findInArray)(e.changedTouches,(function(e){return t===e.identifier}))},n.getTouchIdentifier=function(e){if(e.targetTouches&&e.targetTouches[0])return e.targetTouches[0].identifier;if(e.changedTouches&&e.changedTouches[0])return e.changedTouches[0].identifier},n.addUserSelectStyles=function(e){if(!e)return;var t=e.getElementById("react-draggable-style-el");t||((t=e.createElement("style")).type="text/css",t.id="react-draggable-style-el",t.innerHTML=".react-draggable-transparent-selection *::-moz-selection {all: inherit;}\n",t.innerHTML+=".react-draggable-transparent-selection *::selection {all: inherit;}\n",e.getElementsByTagName("head")[0].appendChild(t));e.body&&d(e.body,"react-draggable-transparent-selection")},n.removeUserSelectStyles=function(e){if(!e)return;try{if(e.body&&h(e.body,"react-draggable-transparent-selection"),e.selection)e.selection.empty();else{var t=(e.defaultView||window).getSelection();t&&"Caret"!==t.type&&t.removeAllRanges()}}catch(e){}},n.addClassName=d,n.removeClassName=h;var i=e("./shims"),o=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var s=i?Object.getOwnPropertyDescriptor(e,o):null;s&&(s.get||s.set)?Object.defineProperty(n,o,s):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(e("./getPrefix"));function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}function s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function l(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?s(Object(n),!0).forEach((function(t){c(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var u="";function p(e,t){return u||(u=(0,i.findInArray)(["matches","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector"],(function(t){return(0,i.isFunction)(e[t])}))),!!(0,i.isFunction)(e[u])&&e[u](t)}function f(e,t,n){var r=e.x,i=e.y,o="translate(".concat(r).concat(n,",").concat(i).concat(n,")");if(t){var a="".concat("string"==typeof t.x?t.x:t.x+n),s="".concat("string"==typeof t.y?t.y:t.y+n);o="translate(".concat(a,", ").concat(s,")")+o}return o}function d(e,t){e.classList?e.classList.add(t):e.className.match(new RegExp("(?:^|\\s)".concat(t,"(?!\\S)")))||(e.className+=" ".concat(t))}function h(e,t){e.classList?e.classList.remove(t):e.className=e.className.replace(new RegExp("(?:^|\\s)".concat(t,"(?!\\S)"),"g"),"")}},{"./getPrefix":274,"./shims":277}],274:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.getPrefix=i,n.browserPrefixToKey=o,n.browserPrefixToStyle=function(e,t){return t?"-".concat(t.toLowerCase(),"-").concat(e):e},n.default=void 0;var r=["Moz","Webkit","O","ms"];function i(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"transform";if("undefined"==typeof window||void 0===window.document)return"";var t=window.document.documentElement.style;if(e in t)return"";for(var n=0;n<r.length;n++)if(o(e,r[n])in t)return r[n];return""}function o(e,t){return t?"".concat(t).concat(function(e){for(var t="",n=!0,r=0;r<e.length;r++)n?(t+=e[r].toUpperCase(),n=!1):"-"===e[r]?n=!0:t+=e[r];return t}(e)):e}var a=i();n.default=a},{}],275:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(){void 0}},{}],276:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.getBoundPosition=function(e,t,n){if(!e.props.bounds)return[t,n];var a=e.props.bounds;a="string"==typeof a?a:function(e){return{left:e.left,top:e.top,right:e.right,bottom:e.bottom}}(a);var s=o(e);if("string"==typeof a){var l,c=s.ownerDocument,u=c.defaultView;if(!((l="parent"===a?s.parentNode:c.querySelector(a))instanceof u.HTMLElement))throw new Error('Bounds selector "'+a+'" could not find an element.');var p=u.getComputedStyle(s),f=u.getComputedStyle(l);a={left:-s.offsetLeft+(0,r.int)(f.paddingLeft)+(0,r.int)(p.marginLeft),top:-s.offsetTop+(0,r.int)(f.paddingTop)+(0,r.int)(p.marginTop),right:(0,i.innerWidth)(l)-(0,i.outerWidth)(s)-s.offsetLeft+(0,r.int)(f.paddingRight)-(0,r.int)(p.marginRight),bottom:(0,i.innerHeight)(l)-(0,i.outerHeight)(s)-s.offsetTop+(0,r.int)(f.paddingBottom)-(0,r.int)(p.marginBottom)}}(0,r.isNum)(a.right)&&(t=Math.min(t,a.right));(0,r.isNum)(a.bottom)&&(n=Math.min(n,a.bottom));(0,r.isNum)(a.left)&&(t=Math.max(t,a.left));(0,r.isNum)(a.top)&&(n=Math.max(n,a.top));return[t,n]},n.snapToGrid=function(e,t,n){var r=Math.round(t/e[0])*e[0],i=Math.round(n/e[1])*e[1];return[r,i]},n.canDragX=function(e){return"both"===e.props.axis||"x"===e.props.axis},n.canDragY=function(e){return"both"===e.props.axis||"y"===e.props.axis},n.getControlPosition=function(e,t,n){var r="number"==typeof t?(0,i.getTouch)(e,t):null;if("number"==typeof t&&!r)return null;var a=o(n),s=n.props.offsetParent||a.offsetParent||a.ownerDocument.body;return(0,i.offsetXYFromParent)(r||e,s,n.props.scale)},n.createCoreData=function(e,t,n){var i=e.state,a=!(0,r.isNum)(i.lastX),s=o(e);return a?{node:s,deltaX:0,deltaY:0,lastX:t,lastY:n,x:t,y:n}:{node:s,deltaX:t-i.lastX,deltaY:n-i.lastY,lastX:i.lastX,lastY:i.lastY,x:t,y:n}},n.createDraggableData=function(e,t){var n=e.props.scale;return{node:t.node,x:e.state.x+t.deltaX/n,y:e.state.y+t.deltaY/n,deltaX:t.deltaX/n,deltaY:t.deltaY/n,lastX:e.state.x,lastY:e.state.y}};var r=e("./shims"),i=e("./domFns");function o(e){var t=e.findDOMNode();if(!t)throw new Error("<DraggableCore>: Unmounted during event!");return t}},{"./domFns":273,"./shims":277}],277:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.findInArray=function(e,t){for(var n=0,r=e.length;n<r;n++)if(t.apply(t,[e[n],n,e]))return e[n]},n.isFunction=function(e){return"function"==typeof e||"[object Function]"===Object.prototype.toString.call(e)},n.isNum=function(e){return"number"==typeof e&&!isNaN(e)},n.int=function(e){return parseInt(e,10)},n.dontSetMe=function(e,t,n){if(e[t])return new Error("Invalid prop ".concat(t," passed to ").concat(n," - do not set this, set it on the child."))}},{}],278:[function(e,t,n){(function(e){(function(){
93/** @license React v16.13.1
94 * react-is.development.js
95 *
96 * Copyright (c) Facebook, Inc. and its affiliates.
97 *
98 * This source code is licensed under the MIT license found in the
99 * LICENSE file in the root directory of this source tree.
100 */
101"use strict";"production"!==e.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,i=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,p=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,d=e?Symbol.for("react.suspense_list"):60120,h=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,y=e?Symbol.for("react.block"):60121,b=e?Symbol.for("react.fundamental"):60117,v=e?Symbol.for("react.responder"):60118,g=e?Symbol.for("react.scope"):60119;function w(e){if("object"==typeof e&&null!==e){var n=e.$$typeof;switch(n){case t:var d=e.type;switch(d){case c:case u:case i:case a:case o:case f:return d;default:var y=d&&d.$$typeof;switch(y){case l:case p:case m:case h:case s:return y;default:return n}}case r:return n}}}var C=c,_=u,k=l,S=s,E=t,T=p,O=i,P=m,R=h,x=r,D=a,j=o,M=f,A=!1;function I(e){return w(e)===u}n.AsyncMode=C,n.ConcurrentMode=_,n.ContextConsumer=k,n.ContextProvider=S,n.Element=E,n.ForwardRef=T,n.Fragment=O,n.Lazy=P,n.Memo=R,n.Portal=x,n.Profiler=D,n.StrictMode=j,n.Suspense=M,n.isAsyncMode=function(e){return A||(A=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your co
vendor: 8,218 bytes, lines 101-110
101de to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),I(e)||w(e)===c},n.isConcurrentMode=I,n.isContextConsumer=function(e){return w(e)===l},n.isContextProvider=function(e){return w(e)===s},n.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},n.isForwardRef=function(e){return w(e)===p},n.isFragment=function(e){return w(e)===i},n.isLazy=function(e){return w(e)===m},n.isMemo=function(e){return w(e)===h},n.isPortal=function(e){return w(e)===r},n.isProfiler=function(e){return w(e)===a},n.isStrictMode=function(e){return w(e)===o},n.isSuspense=function(e){return w(e)===f},n.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===u||e===a||e===o||e===f||e===d||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===h||e.$$typeof===s||e.$$typeof===l||e.$$typeof===p||e.$$typeof===b||e.$$typeof===v||e.$$typeof===g||e.$$typeof===y)},n.typeOf=w}()}).call(this)}).call(this,e("_process"))},{_process:252}],279:[function(e,t,n){
102/** @license React v16.13.1
103 * react-is.production.min.js
104 *
105 * Copyright (c) Facebook, Inc. and its affiliates.
106 *
107 * This source code is licensed under the MIT license found in the
108 * LICENSE file in the root directory of this source tree.
109 */
110"use strict";var r="function"==typeof Symbol&&Symbol.for,i=r?Symbol.for("react.element"):60103,o=r?Symbol.for("react.portal"):60106,a=r?Symbol.for("react.fragment"):60107,s=r?Symbol.for("react.strict_mode"):60108,l=r?Symbol.for("react.profiler"):60114,c=r?Symbol.for("react.provider"):60109,u=r?Symbol.for("react.context"):60110,p=r?Symbol.for("react.async_mode"):60111,f=r?Symbol.for("react.concurrent_mode"):60111,d=r?Symbol.for("react.forward_ref"):60112,h=r?Symbol.for("react.suspense"):60113,m=r?Symbol.for("react.suspense_list"):60120,y=r?Symbol.for("react.memo"):60115,b=r?Symbol.for("react.lazy"):60116,v=r?Symbol.for("react.block"):60121,g=r?Symbol.for("react.fundamental"):60117,w=r?Symbol.for("react.responder"):60118,C=r?Symbol.for("react.scope"):60119;function _(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case i:switch(e=e.type){case p:case f:case a:case l:case s:case h:return e;default:switch(e=e&&e.$$typeof){case u:case d:case b:case y:case c:return e;default:return t}}case o:return t}}}function k(e){return _(e)===f}n.AsyncMode=p,n.ConcurrentMode=f,n.ContextConsumer=u,n.ContextProvider=c,n.Element=i,n.ForwardRef=d,n.Fragment=a,n.Lazy=b,n.Memo=y,n.Portal=o,n.Profiler=l,n.StrictMode=s,n.Suspense=h,n.isAsyncMode=function(e){return k(e)||_(e)===p},n.isConcurrentMode=k,n.isContextConsumer=function(e){return _(e)===u},n.isContextProvider=function(e){return _(e)===c},n.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===i},n.isForwardRef=function(e){return _(e)===d},n.isFragment=function(e){return _(e)===a},n.isLazy=function(e){return _(e)===b},n.isMemo=function(e){return _(e)===y},n.isPortal=function(e){return _(e)===o},n.isProfiler=function(e){return _(e)===l},n.isStrictMode=function(e){return _(e)===s},n.isSuspense=function(e){return _(e)===h},n.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===a||e===f||e===l||e===s||e===h||e===m||"object"==typeof e&&null!==e&&(e.$$typeof===b||e.$$typeof===y||e.$$typeof===c||e.$$typeof===u||e.$$typeof===d||e.$$typeof===g||e.$$typeof===w||e.$$typeof===C||e.$$typeof===v)},n.typeOf=_},{}],280:[function(e,t,n){(function(n){(function(){"use strict";"production"===n.env.NODE_ENV?t.exports=e("./cjs/react-is.production.min.js"):t.exports=e("./cjs/react-is.development.js")}).call(this)}).call(this,e("_process"))},{"./cjs/react-is.development.js":278,"./cjs/react-is.production.min.js":279,_process:252}],281:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0,n.default=n.ReactReduxContext=void 0;var i=r(e("react")).default.createContext(null);n.ReactReduxContext=i;var o=i;n.default=o},{"@babel/runtime/helpers/interopRequireDefault":134,react:307}],282:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault"),i=e("@babel/runtime/helpers/interopRequireWildcard");n.__esModule=!0,n.default=void 0;var o=i(e("react")),a=(r(e("prop-types")),e("./Context")),s=r(e("../utils/Subscription"));function l(e){var t=e.store,n=e.context,r=e.children,i=(0,o.useMemo)((function(){var e=new s.default(t);return e.onStateChange=e.notifyNestedSubs,{store:t,subscription:e}}),[t]),l=(0,o.useMemo)((function(){return t.getState()}),[t]);(0,o.useEffect)((function(){var e=i.subscription;return e.trySubscribe(),l!==t.getState()&&e.notifyNestedSubs(),function(){e.tryUnsubscribe(),e.onStateChange=null}}),[i,l]);var c=n||a.ReactReduxContext;return o.default.createElement(c.Provider,{value:i},r)}var c=l;n.default=c},{"../utils/Subscription":296,"./Context":281,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/interopRequireWildcard":135,"prop-types":256,react:307}],283:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireWildcard"),i=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0,n.default=function(e,t){void 0===t&&(t={});var n=t,r=n.getDisplayName,i=void 0===r?function(e){return"ConnectAdvanced("+e+")"}:r,p=n.methodName,w=void 0===p?"connectAdvanced":p,C=n.renderCountProp,_=void 0===C?void 0:C,k=n.shouldHandleStateChanges,S=void 0===k||k,E=n.storeKey,T=void 0===E?"store":E,O=(n.withRef,n.forwardRef),P=void 0!==O&&O,R=n.context,x=void 0===R?f.ReactReduxContext:R,D=(0,a.default)(n,["getDisplayName","methodName","renderCountProp","shouldHandleStateChanges","storeKey","withRef","forwardRef","context"]);var j=x;return function(t){var n=t.displayName||t.name||"Component",r=i(n),p=(0,o.default)({},D,{getDisplayName:i,methodName:w,renderCountProp:_,shouldHandleStateChanges:S,storeKey:T,displayName:r,wrappedComponentName:n,WrappedComponent:t}),f=D.pure;var C=f?l.useMemo:function(e){return e()};function k(n){var r=(0,l.useMemo)((function(){var e=n.reactReduxForwardedRef,t=(0,a.default)(n,["reactReduxForwardedRef"]);return[n.context,e,t]}),[n]),i=r[0],s=r[1],f=r[2],w=(0,l.useMemo)((function(){return i&&i.Consumer&&(0,c.isContextConsumer)(l.default.createElement(i.Consumer,null))?i:j}),[i,j]),_=(0,l.useContext)(w),k=Boolean(n.store)&&Boolean(n.store.getState)&&Boolean(n.store.dispatch);Boolean(_)&&Boolean(_.store);var E=k?n.store:_.store,T=(0,l.useMemo)((function(){return function(t){return e(t.dispatch,p)}(E)}),[E]),O=(0,l.useMemo)((function(){if(!S)return h;var e=new u.default(E,k?null:_.subscription),t=e.notifyNestedSubs.bind(e);return[e,t]}),[E,k,_]),P=O[0],R=O[1],x=(0,l.useMemo)((function(){return k?_:(0,o.default)({},_,{subscription:P})}),[k,_,P]),D=(0,l.useReducer)(m,d,g),M=D[0][0],A=D[1];if(M&&M.error)throw M.error;var I=(0,l.useRef)(),N=(0,l.useRef)(f),L=(0,l.useRef)(),F=(0,l.useRef)(!1),U=C((function(){return L.current&&f===N.current?L.current:T(E.getState(),f)}),[E,M,f]);y(b,[N,I,F,f,U,L,R]),y(v,[S,E,P,T,N,I,F,L,R,A],[E,P,T]);var q=(0,l.useMemo)((function(){return l.default.createElement(t,(0,o.default)({},U,{ref:s}))}),[s,t,U]);return(0,l.useMemo)((function(){return S?l.default.createElement(w.Provider,{value:x},q):q}),[w,q,x])}var E=f?l.default.memo(k):k;if(E.WrappedComponent=t,E.displayName=r,P){var O=l.default.forwardRef((function(e,t){return l.default.createElement(E,(0,o.default)({},e,{reactReduxForwardedRef:t}))}));return O.displayName=r,O.WrappedComponent=t,(0,s.default)(O,t)}return(0,s.default)(E,t)}};var o=i(e("@babel/runtime/helpers/extends")),a=i(e("@babel/runtime/helpers/objectWithoutPropertiesLoose")),s=i(e("hoist-non-react-statics")),l=r(e("react")),c=e("react-is"),u=i(e("../utils/Subscription")),p=e("../utils/useIsomorphicLayoutEffect"),f=e("./Context"),d=[],h=[null,null];function m(e,t){var n=e[1];return[t.payload,n+1]}function y(e,t,n){(0,p.useIsomorphicLayoutEffect)((function(){return e.apply(void 0,t)}),n)}function b(e,t,n,r,i,o,a){e.current=r,t.current=i,n.current=!1,o.current&&(o.current=null,a())}function v(e,t,n,r,i,o,a,s,l,c){if(e){var u=!1,p=null,f=function(){if(!u){var e,n,f=t.getState();try{e=r(f,i.current)}catch(e){n=e,p=e}n||(p=null),e===o.current?a.current||l():(o.current=e,s.current=e,a.current=!0,
110c({type:"STORE_UPDATED",payload:{error:n}}))}};n.onStateChange=f,n.trySubscribe(),f();return function(){if(u=!0,n.tryUnsubscribe(),n.onStateChange=null,p)throw p}}}var g=function(){return[null,0]}},{"../utils/Subscription":296,"../utils/useIsomorphicLayoutEffect":301,"./Context":281,"@babel/runtime/helpers/extends":131,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/interopRequireWildcard":135,"@babel/runtime/helpers/objectWithoutPropertiesLoose":143,"hoist-non-react-statics":229,react:307,"react-is":280}],284:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0,n.createConnect=h,n.default=void 0;var i=r(e("@babel/runtime/helpers/extends")),o=r(e("@babel/runtime/helpers/objectWithoutPropertiesLoose")),a=r(e("../components/connectAdvanced")),s=r(e("../utils/shallowEqual")),l=r(e("./mapDispatchToProps")),c=r(e("./mapStateToProps")),u=r(e("./mergeProps")),p=r(e("./selectorFactory"));function f(e,t,n){for(var r=t.length-1;r>=0;r--){var i=t[r](e);if(i)return i}return function(t,r){throw new Error("Invalid value of type "+typeof e+" for "+n+" argument when connecting component "+r.wrappedComponentName+".")}}function d(e,t){return e===t}function h(e){var t=void 0===e?{}:e,n=t.connectHOC,r=void 0===n?a.default:n,h=t.mapStateToPropsFactories,m=void 0===h?c.default:h,y=t.mapDispatchToPropsFactories,b=void 0===y?l.default:y,v=t.mergePropsFactories,g=void 0===v?u.default:v,w=t.selectorFactory,C=void 0===w?p.default:w;return function(e,t,n,a){void 0===a&&(a={});var l=a,c=l.pure,u=void 0===c||c,p=l.areStatesEqual,h=void 0===p?d:p,y=l.areOwnPropsEqual,v=void 0===y?s.default:y,w=l.areStatePropsEqual,_=void 0===w?s.default:w,k=l.areMergedPropsEqual,S=void 0===k?s.default:k,E=(0,o.default)(l,["pure","areStatesEqual","areOwnPropsEqual","areStatePropsEqual","areMergedPropsEqual"]),T=f(e,m,"mapStateToProps"),O=f(t,b,"mapDispatchToProps"),P=f(n,g,"mergeProps");return r(C,(0,i.default)({methodName:"connect",getDisplayName:function(e){return"Connect("+e+")"},shouldHandleStateChanges:Boolean(e),initMapStateToProps:T,initMapDispatchToProps:O,initMergeProps:P,pure:u,areStatesEqual:h,areOwnPropsEqual:v,areStatePropsEqual:_,areMergedPropsEqual:S},E))}}var m=h();n.default=m},{"../components/connectAdvanced":283,"../utils/shallowEqual":300,"./mapDispatchToProps":285,"./mapStateToProps":286,"./mergeProps":287,"./selectorFactory":288,"@babel/runtime/helpers/extends":131,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/objectWithoutPropertiesLoose":143}],285:[function(e,t,n){"use strict";n.__esModule=!0,n.whenMapDispatchToPropsIsFunction=o,n.whenMapDispatchToPropsIsMissing=a,n.whenMapDispatchToPropsIsObject=s,n.default=void 0;var r=e("redux"),i=e("./wrapMapToProps");function o(e){return"function"==typeof e?(0,i.wrapMapToPropsFunc)(e,"mapDispatchToProps"):void 0}function a(e){return e?void 0:(0,i.wrapMapToPropsConstant)((function(e){return{dispatch:e}}))}function s(e){return e&&"object"==typeof e?(0,i.wrapMapToPropsConstant)((function(t){return(0,r.bindActionCreators)(e,t)})):void 0}var l=[o,a,s];n.default=l},{"./wrapMapToProps":290,redux:312}],286:[function(e,t,n){"use strict";n.__esModule=!0,n.whenMapStateToPropsIsFunction=i,n.whenMapStateToPropsIsMissing=o,n.default=void 0;var r=e("./wrapMapToProps");function i(e){return"function"==typeof e?(0,r.wrapMapToPropsFunc)(e,"mapStateToProps"):void 0}function o(e){return e?void 0:(0,r.wrapMapToPropsConstant)((function(){return{}}))}var a=[i,o];n.default=a},{"./wrapMapToProps":290}],287:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0,n.defaultMergeProps=o,n.wrapMergePropsFunc=a,n.whenMergePropsIsFunction=s,n.whenMergePropsIsOmitted=l,n.default=void 0;var i=r(e("@babel/runtime/helpers/extends"));r(e("../utils/verifyPlainObject"));function o(e,t,n){return(0,i.default)({},n,e,t)}function a(e){return function(t,n){n.displayName;var r,i=n.pure,o=n.areMergedPropsEqual,a=!1;return function(t,n,s){var l=e(t,n,s);return a?i&&o(l,r)||(r=l):(a=!0,r=l),r}}}function s(e){return"function"==typeof e?a(e):void 0}function l(e){return e?void 0:function(){return o}}var c=[s,l];n.default=c},{"../utils/verifyPlainObject":302,"@babel/runtime/helpers/extends":131,"@babel/runtime/helpers/interopRequireDefault":134}],288:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0,n.impureFinalPropsSelectorFactory=o,n.pureFinalPropsSelectorFactory=a,n.default=function(e,t){var n=t.initMapStateToProps,r=t.initMapDispat
110chToProps,s=t.initMergeProps,l=(0,i.default)(t,["initMapStateToProps","initMapDispatchToProps","initMergeProps"]),c=n(e,l),u=r(e,l),p=s(e,l);0;return(l.pure?a:o)(c,u,p,e,l)};var i=r(e("@babel/runtime/helpers/objectWithoutPropertiesLoose"));r(e("./verifySubselectors"));function o(e,t,n,r){return function(i,o){return n(e(i,o),t(r,o),o)}}function a(e,t,n,r,i){var o,a,s,l,c,u=i.areStatesEqual,p=i.areOwnPropsEqual,f=i.areStatePropsEqual,d=!1;function h(i,d){var h,m,y=!p(d,a),b=!u(i,o);return o=i,a=d,y&&b?(s=e(o,a),t.dependsOnOwnProps&&(l=t(r,a)),c=n(s,l,a)):y?(e.dependsOnOwnProps&&(s=e(o,a)),t.dependsOnOwnProps&&(l=t(r,a)),c=n(s,l,a)):b?(h=e(o,a),m=!f(h,s),s=h,m&&(c=n(s,l,a)),c):c}return function(i,u){return d?h(i,u):(s=e(o=i,a=u),l=t(r,a),c=n(s,l,a),d=!0,c)}}},{"./verifySubselectors":289,"@babel/runtime/helpers/interopRequireDefault":134,"@babel/runtime/helpers/objectWithoutPropertiesLoose":143}],289:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0,n.default=function(e,t,n,r){o(e,"mapStateToProps",r),o(t,"mapDispatchToProps",r),o(n,"mergeProps",r)};var i=r(e("../utils/warning"));function o(e,t,n){if(!e)throw new Error("Unexpected value for "+t+" in "+n+".");"mapStateToProps"!==t&&"mapDispatchToProps"!==t||Object.prototype.hasOwnProperty.call(e,"dependsOnOwnProps")||(0,i.default)("The selector for "+t+" of "+n+" did not specify a value for dependsOnOwnProps.")}},{"../utils/warning":303,"@babel/runtime/helpers/interopRequireDefault":134}],290:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0,n.wrapMapToPropsConstant=function(e){return function(t,n){var r=e(t,n);function i(){return r}return i.dependsOnOwnProps=!1,i}},n.getDependsOnOwnProps=i,n.wrapMapToPropsFunc=function(e,t){return function(t,n){n.displayName;var r=function(e,t){return r.dependsOnOwnProps?r.mapToProps(e,t):r.mapToProps(e)};return r.dependsOnOwnProps=!0,r.mapToProps=function(t,n){r.mapToProps=e,r.dependsOnOwnProps=i(e);var o=r(t,n);return"function"==typeof o&&(r.mapToProps=o,r.dependsOnOwnProps=i(o),o=r(t,n)),o},r}};r(e("../utils/verifyPlainObject"));function i(e){return null!==e.dependsOnOwnProps&&void 0!==e.dependsOnOwnProps?Boolean(e.dependsOnOwnProps):1!==e.length}},{"../utils/verifyPlainObject":302,"@babel/runtime/helpers/interopRequireDefault":134}],291:[function(e,t,n){"use strict";n.__esModule=!0,n.createDispatchHook=o,n.useDispatch=void 0;var r=e("../components/Context"),i=e("./useStore");function o(e){void 0===e&&(e=r.ReactReduxContext);var t=e===r.ReactReduxContext?i.useStore:(0,i.createStoreHook)(e);return function(){return t().dispatch}}var a=o();n.useDispatch=a},{"../components/Context":281,"./useStore":294}],292:[function(e,t,n){"use strict";n.__esModule=!0,n.useReduxContext=function(){var e=(0,r.useContext)(i.ReactReduxContext);0;return e};var r=e("react"),i=e("../components/Context")},{"../components/Context":281,react:307}],293:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0,n.createSelectorHook=u,n.useSelector=void 0;var i=e("react"),o=e("./useReduxContext"),a=r(e("../utils/Subscription")),s=e("../utils/useIsomorphicLayoutEffect"),l=e("../components/Context"),c=function(e,t){return e===t};function u(e){void 0===e&&(e=l.ReactReduxContext);var t=e===l.ReactReduxContext?o.useReduxContext:function(){return(0,i.useContext)(e)};return function(e,n){void 0===n&&(n=c);var r=t(),o=function(e,t,n,r){var o,l=(0,i.useReducer)((function(e){return e+1}),0)[1],c=(0,i.useMemo)((function(){return new a.default(n,r)}),[n,r]),u=(0,i.useRef)(),p=(0,i.useRef)(),f=(0,i.useRef)(),d=(0,i.useRef)(),h=n.getState();try{o=e!==p.current||h!==f.current||u.current?e(h):d.current}catch(e){throw u.current&&(e.message+="\nThe error may be correlated with this previous error:\n"+u.current.stack+"\n\n"),e}return(0,s.useIsomorphicLayoutEffect)((function(){p.current=e,f.current=h,d.current=o,u.current=void 0})),(0,s.useIsomorphicLayoutEffect)((function(){function e(){try{var e=p.current(n.getState());if(t(e,d.current))return;d.current=e}catch(e){u.current=e}l()}return c.onStateChange=e,c.trySubscribe(),e(),function(){return c.tryUnsubscribe()}}),[n,c]),o}(e,n,r.store,r.subscription);return(0,i.useDebugValue)(o),o}}var p=u();n.useSelector=p},{"../components/Context":281,"../utils/Subscription":296,"../utils/useIsomorphicLayoutEffect":301,"./useReduxContext":292,"@babel/runtime/helpers/interopRequireDefault":134,react:307}],294:[function(e,t,n){"use strict";n.__esModule=!0,n.createStoreHook=a,n.useStore=void 0;var r=e("react"),i=e("../components/Context"),o=e("./useReduxContext");function a(e){void 0===e&&(e=i.ReactReduxContext);var t=e===i.ReactReduxContext?o.useReduxContext:function(){return(0,r.useContext)(e)};return function(){return t().store}}var s=a();n.useStore=s},{"../components/Context":281,"./useReduxContext":292,react:307}],295:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0;var i=r(e("./components/Provider"));n.Provider=i.default;var o=r(e("./components/connectAdvanced"));n.connectAdvanced=o.default;var a=e("./components/Context");n.ReactReduxContext=a.ReactReduxContext;var s=r(e("./connect/connect"));n.connect=s.default;var l=e("./hooks/useDispatch");n.useDispatch=l.useDispatch,n.createDispatchHook=l.createDispatchHook;var c=e("./hooks/useSelector");n.useSelector=c.useSelector,n.createSelectorHook=c.createSelectorHook;var u=e("./hooks/useStore");n.useStore=u.useStore,n.createStoreHook=u.createStoreHook;
110var p=e("./utils/batch"),f=e("./utils/reactBatchedUpdates");n.batch=f.unstable_batchedUpdates;var d=r(e("./utils/shallowEqual"));n.shallowEqual=d.default,(0,p.setBatch)(f.unstable_batchedUpdates)},{"./components/Context":281,"./components/Provider":282,"./components/connectAdvanced":283,"./connect/connect":284,"./hooks/useDispatch":291,"./hooks/useSelector":293,"./hooks/useStore":294,"./utils/batch":297,"./utils/reactBatchedUpdates":299,"./utils/shallowEqual":300,"@babel/runtime/helpers/interopRequireDefault":134}],296:[function(e,t,n){"use strict";n.__esModule=!0,n.default=void 0;var r=e("./batch"),i={notify:function(){}};var o=function(){function e(e,t){this.store=e,this.parentSub=t,this.unsubscribe=null,this.listeners=i,this.handleChangeWrapper=this.handleChangeWrapper.bind(this)}var t=e.prototype;return t.addNestedSub=function(e){return this.trySubscribe(),this.listeners.subscribe(e)},t.notifyNestedSubs=function(){this.listeners.notify()},t.handleChangeWrapper=function(){this.onStateChange&&this.onStateChange()},t.isSubscribed=function(){return Boolean(this.unsubscribe)},t.trySubscribe=function(){var e,t,n;this.unsubscribe||(this.unsubscribe=this.parentSub?this.parentSub.addNestedSub(this.handleChangeWrapper):this.store.subscribe(this.handleChangeWrapper),this.listeners=(e=(0,r.getBatch)(),t=null,n=null,{clear:function(){t=null,n=null},notify:function(){e((function(){for(var e=t;e;)e.callback(),e=e.next}))},get:function(){for(var e=[],n=t;n;)e.push(n),n=n.next;return e},subscribe:function(e){var r=!0,i=n={callback:e,next:null,prev:n};return i.prev?i.prev.next=i:t=i,function(){r&&null!==t&&(r=!1,i.next?i.next.prev=i.prev:n=i.prev,i.prev?i.prev.next=i.next:t=i.next)}}}))},t.tryUnsubscribe=function(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=null,this.listeners.clear(),this.listeners=i)},e}();n.default=o},{"./batch":297}],297:[function(e,t,n){"use strict";n.__esModule=!0,n.getBatch=n.setBatch=void 0;var r=function(e){e()};n.setBatch=function(e){return r=e};n.getBatch=function(){return r}},{}],298:[function(e,t,n){"use strict";n.__esModule=!0,n.default=function(e){if("object"!=typeof e||null===e)return!1;var t=Object.getPrototypeOf(e);if(null===t)return!0;var n=t;for(;null!==Object.getPrototypeOf(n);)n=Object.getPrototypeOf(n);return t===n}},{}],299:[function(e,t,n){"use strict";n.__esModule=!0,n.unstable_batchedUpdates=void 0;var r=e("react-dom");n.unstable_batchedUpdates=r.unstable_batchedUpdates},{"react-dom":268}],300:[function(e,t,n){"use strict";function r(e,t){return e===t?0!==e||0!==t||1/e==1/t:e!=e&&t!=t}n.__esModule=!0,n.default=function(e,t){if(r(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),i=Object.keys(t);if(n.length!==i.length)return!1;for(var o=0;o<n.length;o++)if(!Object.prototype.hasOwnProperty.call(t,n[o])||!r(e[n[o]],t[n[o]]))return!1;return!0}},{}],301:[function(e,t,n){"use strict";n.__esModule=!0,n.useIsomorphicLayoutEffect=void 0;var r=e("react"),i="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?r.useLayoutEffect:r.useEffect;n.useIsomorphicLayoutEffect=i},{react:307}],302:[function(e,t,n){"use strict";var r=e("@babel/runtime/helpers/interopRequireDefault");n.__esModule=!0,n.default=function(e,t,n){(0,i.default)(e)||(0,o.default)(n+"() in "+t+" must return a plain object. Instead received "+e+".")};var i=r(e("./isPlainObject")),o=r(e("./warning"))},{"./isPlainObject":298,"./warning":303,"@babel/runtime/helpers/interopRequireDefault":134}],303:[function(e,t,n){"use strict";n.__esModule=!0,n.default=function(e){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e);try{throw new Error(e)}catch(e){}}},{}],304:[function(e,t,n){(function(t){(function(){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e("cnbuilder"),i=e("prop-types"),o=e("react"),a=e("zoom-level"),s=e("react-draggable"),l=function(e,t){return(l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)};function c(e,t){function n(){this.constructor=e}l(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var u=function(){return(u=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function p(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n}function f(e){return(f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var d,h="object"===("undefined"==typeof document?"undefined":f(document))?document:null,m=function(e){return void 0===e},y=function(e){return"function"==typeof e},b=function(e){return"number"==typeof e},v=function(e,t){if(y(e.renderer)){e.elementRef=t;var n=e.renderer;return delete e.renderer,n(e)}return delete e.elementRef,o.createElement("div",u({},e,{ref:t}))},g=function(e,t,n,r){var i=getComputedStyle(e);return"border-box"===i.boxSizing?Math.max(0,(parseFloat(i[t])||0)-(parseFloat(i[n])||0)-(parseFloat(i[r])||0)):parseFloat(i[t])||0},w=function(e){return g(e,"height","paddingTop","paddingBottom")},C=function(e){return g(e,"width","paddingLeft","paddingRight")},_=function(e,t,n,r,i){if(t>=e)return 0;var o=t/e*n;return b(i)&&(o=Math.min(i,o)),b(r)&&(o=Math.max(r,o)),o},k=function(e,t,n,r,i){return!i||!r||t>=e?0:(n-r)*i/(e-t)},S=function(e,t,n,r,i){return!i||!r||t>=e?0:i*(e-t)/(n-r)},E=function e(t){if(void 0===t&&(t=!1),!h)return e._cache=0;
110if(!t&&!m(e._cache))return e._cache;var n=h.createElement("div");if(n.setAttribute("style","position:absolute;width:100px;height:100px;top:-999px;left:-999px;overflow:scroll;"),h.body.appendChild(n),0!==n.clientWidth)return e._cache=100-n.clientWidth,h.body.removeChild(n),e._cache;h.body.removeChild(n)},T=function e(t){if(void 0===t&&(t=!1),!t&&!m(e._cache))return e._cache;if(!h)return e._cache=!1;var n=h.createElement("div"),r=h.createElement("div");return n.appendChild(r),n.setAttribute("style","position:absolute;width:100px;height:100px;top:-999px;left:-999px;overflow:scroll;direction:rtl"),r.setAttribute("style","width:1000px;height:1000px"),h.body.appendChild(n),n.scrollLeft=-50,e._cache=-50===n.scrollLeft,h.body.removeChild(n),e._cache},O=function(){function e(e){void 0===e&&(e=10),this.setMaxHandlers(e),this._handlers=Object.create(null)}return e._callEventHandlers=function(e,t,n){var r;if(t.length)if(1!==t.length)for(t=function(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),i=0;for(t=0;t<n;t++)for(var o=arguments[t],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r}(t),r=0;r<t.length;r++)Reflect.apply(t[r],e,n);else Reflect.apply(t[0],e,n)},e.prototype.setMaxHandlers=function(e){if(!b(e)||e<=0)throw new TypeError("Expected maxHandlers to be a positive number, got '"+e+"' of type "+f(e));return this._maxHandlers=e,this},e.prototype.getMaxHandlers=function(){return this._maxHandlers},e.prototype.emit=function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];return!("object"!==f(this._handlers[t])||!Array.isArray(this._handlers[t]))&&(e._callEventHandlers(this,this._handlers[t],n),!0)},e.prototype.on=function(t,n){return e._addHandler(this,t,n),this},e.prototype.prependOn=function(t,n){return e._addHandler(this,t,n,!0),this},e.prototype.once=function(t,n){if(!y(n))throw new TypeError("Expected event handler to be a function, got "+f(n));return e._addHandler(this,t,this._wrapOnceHandler(t,n)),this},e.prototype.prependOnce=function(t,n){if(!y(n))throw new TypeError("Expected event handler to be a function, got "+f(n));return e._addHandler(this,t,this._wrapOnceHandler(t,n),!0),this},e.prototype.off=function(t,n){return e._removeHandler(this,t,n),this},e.prototype.removeAllHandlers=function(){var t=this._handlers;this._handlers=Object.create(null);var n,r,i=t.removeHandler;for(r in delete t.removeHandler,t)for(n=t[r].length-1;n>=0;n--)e._callEventHandlers(this,i,[r,t[r][n].handler||t[r][n]]);return this},e.prototype._wrapOnceHandler=function(t,n){var r={fired:!1,handler:n,wrappedHandler:void 0,emitter:this,event:t},i=e._onceWrapper.bind(r);return r.wrappedHandler=i,i.handler=n,i.event=t,i},e._addHandler=function(e,t,n,r){if(void 0===r&&(r=!1),!y(n))throw new TypeError("Expected event handler to be a function, got "+f(n));return e._handlers[t]=e._handlers[t]||[],e.emit("addHandler",t,n),r?e._handlers[t].unshift(n):e._handlers[t].push(n),e},e._onceWrapper=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.fired||(this.fired=!0,this.emitter.off(this.event,this.wrappedHandler),Reflect.apply(this.handler,this.emitter,e))},e._removeHandler=function(e,t,n){if(!y(n))throw new TypeError("Expected event handler to be a function, got "+f(n));if(m(e._handlers[t])||!e._handlers[t].length)return e;var r=-1;if(1===e._handlers[t].length)e._handlers[t][0]!==n&&e._handlers[t][0].handler!==n||(r=0,n=e._handlers[t][0].handler||e._handlers[t][0]);else for(r=e._handlers[t].length-1;r>=0;r--)if(e._handlers[t][r]===n||e._handlers[t][r].handler===n){n=e._handlers[t][r].handler||e._handlers[t][r];break}return-1===r||(0===r?e._handlers[t].shift():e._handlers[t].splice(r,1),e.emit("removeHandler",t,n)),e},e}(),P=new(function(){function e(){var e=this;this.targets=[],this.animationFrameID=0,this._isActive=!1,this.start=function(){return!e._isActive&&e.targets.length&&(e._isActive=!0,e.animationFrameID&&cancelAnimationFrame(e.animationFrameID),e.animationFrameID=requestAnimationFrame(e.rafCallback)),e},this.stop=function(){return e._isActive&&(e._isActive=!1,e.animationFrameID&&cancelAnimationFrame(e.animationFrameID),e.animationFrameID=0),e},this.addTarget=function(t,n){return void 0===n&&(n=!1),-1===e.targets.indexOf(t)&&(e.targets.push(t),1===e.targets.length&&!n&&e.start()),e},this.removeTarget=function(t){var n=e.targets.indexOf(t);return-1!==n&&(e.targets.splice(n,1),0===e.targets.length&&e.stop()),e},this.rafCallback=function(){if(!e._isActive)return 0;for(var t=0;t<e.targets.length;t++)!e.targets[t]._unmounted&&e.targets[t].update();return e.animationFrameID=requestAnimationFrame(e.rafCallback)}}return Object.defineProperty(e.prototype,"isActive",{get:function(){return this._isActive}
110,enumerable:!1,configurable:!0}),e}());!function(e){e.X="x",e.Y="y"}(d||(d={}));var R,x=i.oneOf([d.X,d.Y]);!function(e){e.JUMP="jump",e.STEP="step"}(R||(R={}));var D=i.oneOf([R.JUMP,R.STEP]),j=function(e){function n(){var r=null!==e&&e.apply(this,arguments)||this;return r.initialOffsetX=0,r.initialOffsetY=0,r.lastDragData={x:0,y:0,deltaX:0,deltaY:0,lastX:0,lastY:0},r.element=null,r.handleOnDragStart=function(e,i){r.element?(t.document&&(r.prevUserSelect=t.document.body.style.userSelect,t.document.body.style.userSelect="none",r.prevOnSelectStart=t.document.onselectstart,t.document.onselectstart=n.selectStartReplacer),r.props.onDragStart&&r.props.onDragStart(r.lastDragData={x:i.x-r.initialOffsetX,y:i.y-r.initialOffsetY,lastX:i.lastX-r.initialOffsetX,lastY:i.lastY-r.initialOffsetY,deltaX:i.deltaX,deltaY:i.deltaY}),r.element.classList.add("dragging")):r.handleOnDragStop(e,i)},r.handleOnDrag=function(e,t){r.element?r.props.onDrag&&r.props.onDrag(r.lastDragData={x:t.x-r.initialOffsetX,y:t.y-r.initialOffsetY,lastX:t.lastX-r.initialOffsetX,lastY:t.lastY-r.initialOffsetY,deltaX:t.deltaX,deltaY:t.deltaY}):r.handleOnDragStop(e,t)},r.handleOnDragStop=function(e,n){var i=n?{x:n.x-r.initialOffsetX,y:n.y-r.initialOffsetY,lastX:n.lastX-r.initialOffsetX,lastY:n.lastY-r.initialOffsetY,deltaX:n.deltaX,deltaY:n.deltaY}:r.lastDragData;r.props.onDragEnd&&r.props.onDragEnd(i),r.element&&r.element.classList.remove("dragging"),t.document&&(t.document.body.style.userSelect=r.prevUserSelect,t.document.onselectstart=r.prevOnSelectStart,r.prevOnSelectStart=null),r.initialOffsetX=0,r.initialOffsetY=0,r.lastDragData={x:0,y:0,deltaX:0,deltaY:0,lastX:0,lastY:0}},r.handleOnMouseDown=function(e){if(r.element)if(e.preventDefault(),e.stopPropagation(),m(e.offsetX)){var t=r.element.getBoundingClientRect();r.initialOffsetX=(e.clientX||e.touches[0].clientX)-t.left,r.initialOffsetY=(e.clientY||e.touches[0].clientY)-t.top}else r.initialOffsetX=e.offsetX,r.initialOffsetY=e.offsetY},r.elementRefHack=o.createRef(),r.elementRef=function(e){y(r.props.elementRef)&&r.props.elementRef(e),r.element=e,r.elementRefHack.current=e},r}return c(n,e),n.prototype.componentDidMount=function(){this.element||this.setState((function(){throw new Error("<ScrollbarThumb> Element was not created. Possibly you haven't provided HTMLDivElement to renderer's `elementRef` function.")}))},n.prototype.componentWillUnmount=function(){this.handleOnDragStop(),this.elementRef(null)},n.prototype.render=function(){var e=this.props,t=(e.elementRef,e.axis),n=(e.onDrag,e.onDragEnd,e.onDragStart,p(e,["elementRef","axis","onDrag","onDragEnd","onDragStart"]));return n.className=r.cnb("ScrollbarsCustom-Thumb",t===d.X?"ScrollbarsCustom-ThumbX":"ScrollbarsCustom-ThumbY",n.className),n.renderer&&(n.axis=t),o.createElement(s.DraggableCore,{allowAnyClick:!1,enableUserSelectHack:!1,onMouseDown:this.handleOnMouseDown,onDrag:this.handleOnDrag,onStart:this.handleOnDragStart,onStop:this.handleOnDragStop,nodeRef:this.elementRefHack},v(n,this.elementRef))},n.propTypes={axis:x,onDrag:i.func,onDragStart:i.func,onDragEnd:i.func,elementRef:i.func,renderer:i.func},n.selectStartReplacer=function(){return!1},n}(o.Component),M=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.element=null,t.elementRef=function(e){y(t.props.elementRef)&&t.props.elementRef(e),t.element=e},t.handleClick=function(e){if(e&&t.element&&0===e.button){if(y(t.props.onClick)&&e.target===t.element)if(m(e.offsetX)){var n=t.element.getBoundingClientRect();t.props.onClick(e,{axis:t.props.axis,offset:t.props.axis===d.X?(e.clientX||e.touches[0].clientX)-n.left:(e.clientY||e.touches[0].clientY)-n.top})}else t.props.onClick(e,{axis:t.props.axis,offset:t.props.axis===d.X?e.offsetX:e.offsetY});return!0}},t}return c(t,e),t.prototype.componentDidMount=function(){this.element?this.element.addEventListener("click",this.handleClick):this.setState((function(){throw new Error("Element was not created. Possibly you haven't provided HTMLDivElement to renderer's `elementRef` function.")}))},t.prototype.componentWillUnmount=function(){this.element&&(this.element.removeEventListener("click",this.handleClick),this.element=null,this.elementRef(null))},t.prototype.render=function(){var e=this.props,t=(e.elementRef,e.axis),n=(e.onClick,p(e,["elementRef","axis","onClick"]));return n.className=r.cnb("ScrollbarsCustom-Track",t===d.X?"ScrollbarsCustom-TrackX":"ScrollbarsCustom-TrackY",n.className),n.renderer&&(n.axis=t),v(n,this.elementRef)}
110,t.propTypes={axis:x,onClick:i.func,elementRef:i.func,renderer:i.func},t}(o.Component),A={holder:{position:"relative",width:"100%",height:"100%"},wrapper:{position:"absolute",top:0,left:0,bottom:0,right:0},content:{boxSizing:"border-box"},track:{common:{position:"absolute",overflow:"hidden",borderRadius:4,background:"rgba(0,0,0,.1)",userSelect:"none"},x:{height:10,width:"calc(100% - 20px)",bottom:0,left:10},y:{width:10,height:"calc(100% - 20px)",top:10}},thumb:{common:{cursor:"pointer",borderRadius:4,background:"rgba(0,0,0,.4)"},x:{height:"100%",width:0},y:{width:"100%",height:0}}},I=t.window?a.zoomLevel():1;t.window&&t.window.addEventListener("resize",(function(){return I=a.zoomLevel()}),{passive:!0});var N=o.createContext({parentScrollbar:null}),L=function(e){function n(n){var r=e.call(this,n)||this;return r.getScrollState=function(e){if(void 0===e&&(e=!1),r.scrollValues&&!e)return u({},r.scrollValues);var t={clientHeight:0,clientWidth:0,contentScrollHeight:0,contentScrollWidth:0,scrollHeight:0,scrollWidth:0,scrollTop:0,scrollLeft:0,scrollYBlocked:!1,scrollXBlocked:!1,scrollYPossible:!1,scrollXPossible:!1,trackYVisible:!1,trackXVisible:!1,zoomLevel:1*I,isRTL:void 0},n=r.props;return t.isRTL=r.state.isRTL,t.scrollYBlocked=n.noScroll||n.noScrollY,t.scrollXBlocked=n.noScroll||n.noScrollX,r.scrollerElement&&(t.clientHeight=r.scrollerElement.clientHeight,t.clientWidth=r.scrollerElement.clientWidth,t.scrollHeight=r.scrollerElement.scrollHeight,t.scrollWidth=r.scrollerElement.scrollWidth,t.scrollTop=r.scrollerElement.scrollTop,t.scrollLeft=r.scrollerElement.scrollLeft,t.scrollYPossible=!t.scrollYBlocked&&t.scrollHeight>t.clientHeight,t.scrollXPossible=!t.scrollXBlocked&&t.scrollWidth>t.clientWidth,t.trackYVisible=t.scrollYPossible||n.permanentTracks||n.permanentTrackY,t.trackXVisible=t.scrollXPossible||n.permanentTracks||n.permanentTrackX),r.contentElement&&(t.contentScrollHeight=r.contentElement.scrollHeight,t.contentScrollWidth=r.contentElement.scrollWidth),t},r.scrollToTop=function(){return r.scrollerElement&&(r.scrollerElement.scrollTop=0),r},r.scrollToLeft=function(){return r.scrollerElement&&(r.scrollerElement.scrollLeft=0),r},r.scrollToBottom=function(){return r.scrollerElement&&(r.scrollerElement.scrollTop=r.scrollerElement.scrollHeight-r.scrollerElement.clientHeight),r},r.scrollToRight=function(){return r.scrollerElement&&(r.scrollerElement.scrollLeft=r.scrollerElement.scrollWidth-r.scrollerElement.clientWidth),r},r.scrollTo=function(e,t){return r.scrollerElement&&(b(e)&&(r.scrollerElement.scrollLeft=e),b(t)&&(r.scrollerElement.scrollTop=t)),r},r.centerAt=function(e,t){return r.scrollerElement&&(b(e)&&(r.scrollerElement.scrollLeft=e-r.scrollerElement.clientWidth/2),b(t)&&(r.scrollerElement.scrollTop=t-r.scrollerElement.clientHeight/2)),r},r.update=function(e){if(void 0===e&&(e=!1),r.scrollerElement){if(m(r.state.isRTL))return r.setState({isRTL:"rtl"===getComputedStyle(r.scrollerElement).direction}),r.getScrollState();var t=r.getScrollState(!0),n=u({},r.scrollValues),i=r.props,o=0;if(e)o=32767;else if(n.clientHeight!==t.clientHeight&&(o|=1),n.clientWidth!==t.clientWidth&&(o|=2),n.scrollHeight!==t.scrollHeight&&(o|=4),n.scrollWidth!==t.scrollWidth&&(o|=8),n.scrollTop!==t.scrollTop&&(o|=16),n.scrollLeft!==t.scrollLeft&&(o|=32),n.scrollYBlocked!==t.scrollYBlocked&&(o|=64),n.scrollXBlocked!==t.scrollXBlocked&&(o|=128),n.scrollYPossible!==t.scrollYPossible&&(o|=256),n.scrollXPossible!==t.scrollXPossible&&(o|=512),n.trackYVisible!==t.trackYVisible&&(o|=1024),n.trackXVisible!==t.trackXVisible&&(o|=2048),n.isRTL!==t.isRTL&&(o|=4096),n.contentScrollHeight!==t.contentScrollHeight&&(o|=8192),n.contentScrollWidth!==t.contentScrollWidth&&(o|=16384),n.zoomLevel!==t.zoomLevel&&(o|=32768),0===o)return n;if(i.native||!r.holderElement||(8192&o&&(i.translateContentSizesToHolder||i.translateContentSizeYToHolder)&&(r.holderElement.style.height=t.contentScrollHeight+"px"),16384&o&&(i.translateContentSizesToHolder||i.translateContentSizeXToHolder)&&(r.holderElement.style.width=t.contentScrollWidth+"px"),!(i.translateContentSizesToHolder||i.translateContentSizeYToHolder||i.translateContentSizeXToHolder)||!(!t.clientHeight&&t.contentScrollHeight||!t.clientWidth&&t.contentScrollWidth)))return 1024&o||2048&o?(n.scrollYBlocked=t.scrollYBlocked,n.scrollXBlocked=t.scrollXBlocked,n.scrollYPossible=t.scrollYPossible,n.scrollXPossible=t.scrollXPossible,r.trackYElement&&1024&o&&(r.trackYElement.style.display=t.trackYVisible?"":"none"),r.trackXElement&&2048&o&&(r.trackXElement.style.display=t.trackXVisible?"":"none"),r.scrollValues=n,void r.setState({trackYVisible:r.scrollValues.trackYVisible=t.trackYVisible,trackXVisible:r.scrollValues.trackXVisible=t.trackXVisible})):((i.native?r.updaterNative:r.updaterCustom)(o,t),r.scrollValues=t,!i.native&&32768&o&&(E(!0),r.forceUpdate()),r.eventEmitter.emit("update",u({},t),n),(16&o||32&o)&&r.eventEmitter.emit("scroll",u({},t),n),r.scrollValues)}},r.updaterNative=function(){return!0},r.updaterCustom=function(e,t){var n=r.props;if(r.trackYElement&&r.thumbYElement&&(1&e||4&e||16&e||64&e||256&e))if(t.scrollYPossible){var i=w(r.trackYElement),o=_(t.scrollHeight,t.clientHeight,i,n.minimalThumbYSize||n.minimalThumbSize,n.maximalThumbYSize||n.maximalThumbSize),a=k(t.scrollHeight,t.clientHeight,i,o,t.scrollTop);r.thumbYElement.style.transform="translateY("+a+"px)",r.thumbYElement.style.height=o+"px",r.thumbYElement.style.display=""}else r.thumbYElement.style.transform="",r.thumbYElement.style.height="0px",r.thumbYElement.style.display="none";if(r.trackXElement&&r.thumbXElement&&(2&e||8&e||32&e||128&e||512&e||4096&e))if(t.scrollXPossible){i=C(r.trackXElement),o=_(t.scrollWidth,t.clientWidth,i,n.minimalThumbXSize||n.minimalThumbSize,n.maximalThumbXSize||n.maximalThumbSize),a=k(t.scrollWidth,t.clientWidth,i,o,t.scrollLeft);r.state.isRTL&&T()&&(a+=i-o),r.thumbXElement.style.transform="translateX("+a+"px)",r.thumbXElement.style.width=o+"px",r.thumbXElement.style.display=""}else r.thumbXElement.style.transform="",r.thumbXElement.style.width="0px",r.thumbXElement.style.display="none";return!0},r.elementRefHolder=function(e){r.holderElement=e,y(r.props.elementRef)&&r.props.elementRef(e)},r.elementRefWrapper=function(e){r.wrapperElement=e,y(r.props.wrapperProps.elementRef)&&r.props.wrapperProps.elementRef(e)},r.elementRefScroller=function(e){r.scrollerElement=e,y(r.props.scrollerProps.elementRef)&&r.props.scrollerProps.elementRef(e)},r.elementRefContent=function(e){r.contentElement=e,y(r.props.contentProps.elementRef)&&r.props.contentProps.elementRef(e)},r.elementRefTrackX=function(e){r.trackXElement=e,y(r.props.trackXProps.elementRef)&&r.props.trackXProps.elementRef(e)},r.elementRefTrackY=function(e){r.trackYElement=e,y(r.props.trackYProps.elementRef)&&r.props.trackYProps.elementRef(e)},r.elementRefThumbX=function(e){r.thumbXElement=e,y(r.props.thumbXProps.elementRef)&&r.props.thumbXProps.elementRef(e)},r.elementRefThumbY=function(e){r.thumbYElement=e,y(r.props.thumbYProps.elementRef)&&r.props.thumbYProps.elementRef(e)},r.handleTrackXClick=function(e,t){if(r.props.trackXProps.onClick&&r.props.trackXProps.onClick(e,t),r.scrollerElement&&r.trackXElement&&r.thumbXElement&&r.scrollValues&&r.scrollValues.scrollXPossible){r._scrollDetection();var n=r.thumbXElement.clientWidth,i=C(r.trackXElement),o=(r.scrollValues.isRTL&&T()?t.offset+n/2-i:t.offset-n/2)-(parseFloat(getComputedStyle(r.trackXElement).paddingLeft)||0),a=S(r.scrollValues.scrollWidth,r.scrollValues.clientWidth,i,n,o);r.props.trackClickBehavior===R.STEP&&(a=(r.scrollValues.isRTL?r.scrollValues.scrollLeft>
110a:r.scrollValues.scrollLeft<a)?r.scrollValues.scrollLeft+r.scrollValues.clientWidth:r.scrollValues.scrollLeft-r.scrollValues.clientWidth),r.scrollerElement.scrollLeft=a}},r.handleTrackYClick=function(e,t){if(r.props.trackYProps.onClick&&r.props.trackYProps.onClick(e,t),r.scrollerElement&&r.trackYElement&&r.thumbYElement&&r.scrollValues&&r.scrollValues.scrollYPossible){r._scrollDetection();var n=r.thumbYElement.clientHeight,i=S(r.scrollValues.scrollHeight,r.scrollValues.clientHeight,w(r.trackYElement),n,t.offset-n/2)-(parseFloat(getComputedStyle(r.trackYElement).paddingTop)||0);r.props.trackClickBehavior===R.JUMP?r.scrollerElement.scrollTop=i:r.scrollerElement.scrollTop=r.scrollValues.scrollTop<i?r.scrollValues.scrollTop+r.scrollValues.clientHeight:r.scrollValues.scrollTop-r.scrollValues.clientHeight}},r.handleTrackYMouseWheel=function(e){var t=r.props;t.trackYProps&&t.trackYProps.onWheel&&t.trackYProps.onWheel(e),t.disableTracksMousewheelScrolling||t.disableTrackYMousewheelScrolling||(r._scrollDetection(),r.scrollerElement&&!r.scrollValues.scrollYBlocked&&(r.scrollTop+=e.deltaY))},r.handleTrackXMouseWheel=function(e){var t=r.props;t.trackXProps&&t.trackXProps.onWheel&&t.trackXProps.onWheel(e),t.disableTracksMousewheelScrolling||t.disableTrackXMousewheelScrolling||(r._scrollDetection(),r.scrollerElement&&!r.scrollValues.scrollXBlocked&&(r.scrollLeft+=e.deltaX))},r.handleThumbXDrag=function(e){var t;if(r.trackXElement&&r.thumbXElement&&r.scrollerElement&&r.scrollValues&&r.scrollValues.scrollXPossible){r._scrollDetection();var n=r.trackXElement.getBoundingClientRect(),i=getComputedStyle(r.trackXElement),o=parseFloat(i.paddingLeft)||0,a=parseFloat(i.paddingRight)||0,s=n.width-o-a,l=r.thumbXElement.clientWidth,c=r.scrollValues.isRTL&&T()?e.x+l-s+o:e.lastX-o;r.scrollerElement.scrollLeft=S(r.scrollValues.scrollWidth,r.scrollValues.clientWidth,s,l,c),(null===(t=r.props.thumbXProps)||void 0===t?void 0:t.onDrag)&&r.props.thumbXProps.onDrag(e)}},r.handleThumbXDragEnd=function(e){var t;r.handleThumbXDrag(e),(null===(t=r.props.thumbXProps)||void 0===t?void 0:t.onDragEnd)&&r.props.thumbXProps.onDragEnd(e)},r.handleThumbYDrag=function(e){var t;if(r.scrollerElement&&r.trackYElement&&r.thumbYElement&&r.scrollValues&&r.scrollValues.scrollYPossible){r._scrollDetection();var n=r.trackYElement.getBoundingClientRect(),i=getComputedStyle(r.trackYElement),o=parseFloat(i.paddingTop)||0,a=parseFloat(i.paddingBottom)||0,s=n.height-o-a,l=r.thumbYElement.clientHeight,c=e.y-o;r.scrollerElement.scrollTop=S(r.scrollValues.scrollHeight,r.scrollValues.clientHeight,s,l,c),(null===(t=r.props.thumbYProps)||void 0===t?void 0:t.onDrag)&&r.props.thumbYProps.onDrag(e)}},r.handleThumbYDragEnd=function(e){var t;r.handleThumbYDrag(e),(null===(t=r.props.thumbYProps)||void 0===t?void 0:t.onDragEnd)&&r.props.thumbYProps.onDragEnd(e)},r.handleScrollerScroll=function(){r._scrollDetection()},r._scrollDetection=function(){!r._scrollDetectionTO&&r.eventEmitter.emit("scrollStart",r.getScrollState()),r._scrollDetectionTO&&t.window&&t.window.clearTimeout(r._scrollDetectionTO),r._scrollDetectionTO=t.window?t.window.setTimeout(r._scrollDetectionCallback,r.props.scrollDetectionThreshold||0):null},r._scrollDetectionCallback=function(){r._scrollDetectionTO=null,r.eventEmitter.emit("scrollStop",r.getScrollState())},r.state={trackXVisible:!1,trackYVisible:!1,isRTL:n.rtl},r.scrollValues=r.getScrollState(!0),r.eventEmitter=new O(15),n.onUpdate&&r.eventEmitter.on("update",n.onUpdate),n.onScroll&&r.eventEmitter.on("scroll",n.onScroll),n.onScrollStart&&r.eventEmitter.on("scrollStart",n.onScrollStart),n.onScrollStop&&r.eventEmitter.on("scrollStop",n.onScrollStop),r.id=function(){for(var e="",t=0;t<32;t++)e+=8===t||20===t?"-"+(16*Math.random()|0).toString(16):12===t?"-4":16===t?"-"+(8|16*Math.random()).toString(16):(16*Math.random()|0).toString(16);return e}(),r}return c(n,e),Object.defineProperty(n.prototype,"scrollTop",{get:function(){return this.scrollerElement?this.scrollerElement.scrollTop:0},set:function(e){this.scrollerElement&&(this.scrollerElement.scrollTop=e,this.update())}
110,enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"scrollLeft",{get:function(){return this.scrollerElement?this.scrollerElement.scrollLeft:0},set:function(e){this.scrollerElement&&(this.scrollerElement.scrollLeft=e)},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"scrollHeight",{get:function(){return this.scrollerElement?this.scrollerElement.scrollHeight:0},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"scrollWidth",{get:function(){return this.scrollerElement?this.scrollerElement.scrollWidth:0},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"clientHeight",{get:function(){return this.scrollerElement?this.scrollerElement.clientHeight:0},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"clientWidth",{get:function(){return this.scrollerElement?this.scrollerElement.clientWidth:0},enumerable:!1,configurable:!0}),n.calculateStyles=function(e,t,n,r){var i,o,a,s,l=!e.noDefaultStyles;return{holder:u(u(u({},l&&A.holder),{position:"relative"}),e.style),wrapper:u(u(u({},l&&u(u(u({},A.wrapper),!e.disableTracksWidthCompensation&&!e.disableTrackYWidthCompensation&&(i={},i[t.isRTL?"left":"right"]=t.trackYVisible?10:0,i)),!e.disableTracksWidthCompensation&&!e.disableTrackXWidthCompensation&&{bottom:t.trackXVisible?10:0})),e.wrapperProps.style),{position:"absolute",overflow:"hidden"}),content:u(u(u(u(u({},l&&A.content),e.translateContentSizesToHolder||e.translateContentSizeYToHolder||e.translateContentSizeXToHolder?{display:"table-cell"}:{padding:.05}),l&&!(e.translateContentSizesToHolder||e.translateContentSizeYToHolder)&&{minHeight:"100%"}),l&&!(e.translateContentSizesToHolder||e.translateContentSizeXToHolder)&&{minWidth:"100%"}),e.contentProps.style),scroller:u(u(u(u((o={position:"absolute",top:0,left:0,bottom:0,right:0,paddingBottom:!r&&n.scrollXPossible?e.fallbackScrollbarWidth:void 0},o[t.isRTL?"paddingLeft":"paddingRight"]=!r&&n.scrollYPossible?e.fallbackScrollbarWidth:void 0,o),e.scrollerProps.style),!m(e.rtl)&&{direction:e.rtl?"rtl":"ltr"}),e.momentum&&{WebkitOverflowScrolling:"touch"}),(a={overflowY:n.scrollYPossible?"scroll":"hidden",overflowX:n.scrollXPossible?"scroll":"hidden",marginBottom:n.scrollXPossible?-(r||e.fallbackScrollbarWidth)-Number(1!==n.zoomLevel):void 0},a[t.isRTL?"marginLeft":"marginRight"]=n.scrollYPossible?-(r||e.fallbackScrollbarWidth)-Number(1!==n.zoomLevel):void 0,a)),trackX:u(u(u(u({},l&&A.track.common),l&&A.track.x),e.trackXProps.style),!t.trackXVisible&&{display:"none"}),trackY:u(u(u(u(u({},l&&A.track.common),l&&A.track.y),l&&(s={},s[t.isRTL?"left":"right"]=0,s)),e.trackYProps.style),!t.trackYVisible&&{display:"none"}),thumbX:u(u(u({},l&&A.thumb.common),l&&A.thumb.x),e.thumbXProps.style),thumbY:u(u(u({},l&&A.thumb.common),l&&A.thumb.y),e.thumbYProps.style)}},n.prototype.componentDidMount=function(){if(this.scrollerElement)if(this.contentElement){var e=this.props;if(!e.native&&!e.mobileNative){if(!this.holderElement)return void this.setState((function(){throw new Error("holder element was not created. Possibly you haven't provided HTMLDivElement to renderer's `elementRef` function.")}));if(!this.wrapperElement)return void this.setState((function(){throw new Error("wrapper element was not created. Possibly you haven't provided HTMLDivElement to renderer's `elementRef` function.")}))}P.addTarget(this),m(e.scrollTop)||(this.scrollerElement.scrollTop=e.scrollTop),m(e.scrollLeft)||(this.scrollerElement.scrollLeft=e.scrollLeft),this.update(!0)}else this.setState((function(){throw new Error("content element was not created. Possibly you haven't provided HTMLDivElement to renderer's `elementRef` function.")}));else this.setState((function(){throw new Error("scroller element was not created. Possibly you haven't provided HTMLDivElement to renderer's `elementRef` function.")}))},n.prototype.componentWillUnmount=function(){P.removeTarget(this)},n.prototype.componentDidUpdate=function(e,t){if(this.scrollerElement){var n=this.props;n.rtl!==e.rtl&&n.rtl!==this.state.isRTL&&this.setState({isRTL:n.rtl}),this.state.isRTL!==t.isRTL&&this.update(),m(n.scrollTop)||n.scrollTop===this.scrollerElement.scrollTop||(this.scrollerElement.scrollTop=n.scrollTop),m(n.scrollLeft)||n.scrollLeft===this.scrollerElement.scrollLeft||(this.scrollerElement.scrollLeft=n.scrollLeft),e.onUpdate!==n.onUpdate&&(e.onUpdate&&this.eventEmitter.off("update",e.onUpdate),n.onUp
110date&&this.eventEmitter.on("update",n.onUpdate)),e.onScroll!==n.onScroll&&(e.onScroll&&this.eventEmitter.off("scroll",e.onScroll),n.onScroll&&this.eventEmitter.on("scroll",n.onScroll)),e.onScrollStart!==n.onScrollStart&&(e.onScrollStart&&this.eventEmitter.off("scrollStart",e.onScrollStart),n.onScrollStart&&this.eventEmitter.on("scrollStart",n.onScrollStart)),e.onScrollStop!==n.onScrollStop&&(e.onScrollStop&&this.eventEmitter.off("scrollStop",e.onScrollStop),n.onScrollStop&&this.eventEmitter.on("scrollStop",n.onScrollStop))}},n.prototype.render=function(){var e=this.props,t=e.createContext,i=e.rtl,a=e.native,s=e.mobileNative,l=e.momentum,c=(e.noDefaultStyles,e.disableTracksMousewheelScrolling),f=e.disableTrackXMousewheelScrolling,h=e.disableTrackYMousewheelScrolling,y=(e.disableTracksWidthCompensation,e.disableTrackXWidthCompensation,e.disableTrackYWidthCompensation,e.noScrollX),b=e.noScrollY,g=e.noScroll,w=e.permanentTrackX,C=e.permanentTrackY,_=e.permanentTracks,k=e.removeTracksWhenNotUsed,S=e.removeTrackYWhenNotUsed,T=e.removeTrackXWhenNotUsed,O=(e.minimalThumbSize,e.maximalThumbSize,e.minimalThumbXSize,e.maximalThumbXSize,e.minimalThumbYSize,e.maximalThumbYSize,e.fallbackScrollbarWidth,e.scrollTop,e.scrollLeft,e.trackClickBehavior,e.scrollDetectionThreshold,e.wrapperProps),P=e.scrollerProps,R=e.contentProps,x=e.trackXProps,D=e.trackYProps,A=e.thumbXProps,I=e.thumbYProps,L=e.scrollbarWidth,F=(e.elementRef,e.onUpdate,e.onScroll,e.onScrollStart,e.onScrollStop,e.translateContentSizesToHolder,e.translateContentSizeYToHolder,e.translateContentSizeXToHolder,e.children),U=p(e,["createContext","rtl","native","mobileNative","momentum","noDefaultStyles","disableTracksMousewheelScrolling","disableTrackXMousewheelScrolling","disableTrackYMousewheelScrolling","disableTracksWidthCompensation","disableTrackXWidthCompensation","disableTrackYWidthCompensation","noScrollX","noScrollY","noScroll","permanentTrackX","permanentTrackY","permanentTracks","removeTracksWhenNotUsed","removeTrackYWhenNotUsed","removeTrackXWhenNotUsed","minimalThumbSize","maximalThumbSize","minimalThumbXSize","maximalThumbXSize","minimalThumbYSize","maximalThumbYSize","fallbackScrollbarWidth","scrollTop","scrollLeft","trackClickBehavior","scrollDetectionThreshold","wrapperProps","scrollerProps","contentProps","trackXProps","trackYProps","thumbXProps","thumbYProps","scrollbarWidth","elementRef","onUpdate","onScroll","onScrollStart","onScrollStop","translateContentSizesToHolder","translateContentSizeYToHolder","translateContentSizeXToHolder","children"]),q=m(L)?E()||0:L;if(a||!q&&s){this.elementRefHolder(null),this.elementRefWrapper(null),this.elementRefTrackX(null),this.elementRefTrackY(null),this.elementRefThumbX(null),this.elementRefThumbY(null);var B=u(u({},R),{key:"ScrollbarsCustom-Content",className:r.cnb("ScrollbarsCustom-Content",R.className),children:F}),z=u(u({},U),{className:r.cnb("ScrollbarsCustom native",this.state.trackYVisible&&"trackYVisible",this.state.trackXVisible&&"trackXVisible",this.state.isRTL&&"rtl",U.className),style:u(u(u(u({},U.style),!m(i)&&{direction:i?"rtl":"ltr"}),l&&{WebkitOverflowScrolling:"touch"}),{overflowX:g||y?"hidden":_||w?"scroll":"auto",overflowY:g||b?"hidden":_||C?"scroll":"auto"}),onScroll:this.handleScrollerScroll,children:v(B,this.elementRefContent),renderer:P.renderer,elementRef:P.elementRef});return v(z,this.elementRefScroller)}var V=n.calculateStyles(this.props,this.state,this.scrollValues,q),W=[],H=u(u({},R),{key:"ScrollbarsCustom-Content",className:r.cnb("ScrollbarsCustom-Content",R.className),style:V.content,children:t?o.createElement(N.Provider,{value:{parentScrollbar:this},children:F}):F}),Y=u(u({},P),{key:"ScrollbarsCustom-Scroller",className:r.cnb("ScrollbarsCustom-Scroller",P.className),style:V.scroller,children:v(H,this.elementRefContent),onScroll:this.handleScrollerScroll}),X=u(u({},O),{key:"ScrollbarsCustom-Wrapper",className:r.cnb("ScrollbarsCustom-Wrapper",O.className),style:V.wrapper,children:v(Y,this.elementRefScroller)});if(W.push(v(X,this.elementRefWrapper)),this.state.trackYVisible||!k&&!S){var G=u(u({},I),{key:"ScrollbarsCustom-ThumbY",style:V.thumbY,elementRef:this.elementRefThumbY,onDrag:this.handleThumbYDrag,onDragEnd:this.handleThumbYDragEnd,axis:d.Y}),$=u(u(u(u({},D),{key:"ScrollbarsCustom-TrackY",style:V.trackY,elementRef:this.elementRefTrackY,onClick:this.handleTrackYClick}),(c||h)&&{onWheel:this.handleTrackYMouseWheel}),{axis:d.Y});$.children=o.createElement(j,u({},G)),W.push(o.createElement(M,u({},$)))}else this.elementRefTrackY(null),this.elementRefThumbY(null);if(this.state.trackXVisible||!k&&!T){var Q=u(u({},A),{key:"ScrollbarsCustom-ThumbX",style:V.thumbX,elementRef:this.elementRefThumbX,onDrag:this.handleThumbXDrag,onDragEnd:this.handleThumbXDragEnd,axis:d.X}),K=u(u(u(u({},x),{key:"ScrollbarsCustom-TrackX",style:V.trackX,elementRef:this.elementRefTrackX,onClick:this.handleTrackXClick}),(c||f)&&{onWheel:this.handleTrackXMouseWheel}),{axis:d.X});K.children=o.createElement(j,u({},Q)),W.push(o.createElement(M,u({},K)))}else this.elementRefTrackX(null),this.elementRefThumbX(null);var J=u(u({},U),{className:r.cnb("ScrollbarsCustom",this.state.trackYVisible&&"trackYVisible",this.state.trackXVisible&&"trackXVisible",this.state.isRTL&&"rtl",U.className),style:V.holder,children:W});return v(J,this.elementRefHolder)},n.contextType=N,n.propTypes={createContext:i.bool,rtl:i.bool,native:i.bool,mobileNative:i.bool,momentum:i.bool,noDefaultStyles:i.bool,disableTracksMousewheelScrolling:i.bool,disableTrackXMousewheelScrolling:i.bool,disableTrackYMousewheelScrolling:i.bool,disableTracksWidthCompensation:i.bool,disableTrackXWidthCompensation:i.bool,disableTrackYWidthCompensation:i.bool,minimalThumbSize:i.number,maximalThumbSize:i.number,minimalThumbXSize:i.number,maximalThumbXSize:i.number,minimalThumbYSize:i.number,maximalThumbYSize:i.number,noScrollX:i.bool,noScrollY:i.bool,noScroll:i.bool,permanentTrackX:i.bool,permanentTrackY:i.bool,permanentTracks:i.bool,translateContentSizesToHolder:i.bool,translateContentSizeYToHolder:i.bool,translateContentSizeXToHolder:i.bool,removeTracksWhenNotUsed:i.bool,removeTrackYWhenNotUsed:i.bool,removeTrackXWhenNotUsed:i.bool,trackClickBehavior:D,scrollbarWidth:i.number,fallbackScrollbarWidth:i.number,scrollDetectionThreshold:i.number,scrollTop:i.number,scrollLeft:i.number,className:i.string,wrapperProps:i.object,contentProps:i.object,trackXProps:i.object,trackYProps:i.object,thumbXProps:i.object,thumbYProps:i.object,onUpdate:i.func,onScroll:i.func,onScrollStart:i.func,onScrollStop:i.func},n.defaultProps={momentum:!0,minimalThumbSize:30,fallbackScrollbarWidth:20,trackClickBehavior:R.JUMP,scrollDetectionThreshold:100,wrapperProps:{},scrollerProps:{},contentProps:{},trackXProps:{},trackYProps:{},thumbXProps:{},thumbYProps:{}},n}(o.Component);n.Scrollbar=L,n.ScrollbarContext=N,n.default=L}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{cnbuilder:157,"prop-types":256,react:307,"react-draggable":272,"zoom-level":518}],305:[function(e,t,n){
111/** @license React v17.0.1
112 * react.development.js
113 *
114 * Copyright (c) Facebook, Inc. and its affiliates.
115 *
116 * This source code is licensed under the MIT license found in the
117 * LICENSE file in the root directory of this source tree.
118 */
119"use strict"},{"object-assign":247}],306:[function(e,t,n){
120/** @license React v17.0.1
121 * react.production.min.js
122 *
123 * Copyright (c) Facebook, Inc. and its affiliates.
124 *
125 * This source code is licensed under the MIT license found in the
126 * LICENSE file in the root directory of this source tree.
127 */
128"use strict";var r=e("object-assign"),i=60103,o=60106;n.Fragment=60107,n.StrictMode=60108,n.Profiler=60114;var a=60109,s=60110,l=60112;n.Suspense=60113;var c=60115,u=60116;if("function"==typeof Symbol&&Symbol.for){var p=Symbol.for;i=p("react.element"),o=p("react.portal"),n.Fragment=p("react.fragment"),n.StrictMode=p("react.strict_mode"),n.Profiler=p("react.profiler"),a=p("react.provider"),s=p("react.context"),l=p("react.forward_ref"),n.Suspense=p("react.suspense"),c=p("react.memo"),u=p("react.lazy")}var f="function"==typeof Symbol&&Symbol.iterator;function d(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},m={};function y(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}function b(){}function v(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}y.prototype.isReactComponent={},y.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error(d(85));this.updater.enqueueSetState(this,e,t,"setState")},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},b.prototype=y.prototype;var g=v.prototype=new b;g.constructor=v,r(g,y.prototype),g.isPureReactComponent=!0;var w={current:null},C=Object.prototype.hasOwnProperty,_={key:!0,ref:!0,__self:!0,__source:!0};
vendor: 4,346 bytes, line 128
128function k(e,t,n){var r,o={},a=null,s=null;if(null!=t)for(r in void 0!==t.ref&&(s=t.ref),void 0!==t.key&&(a=""+t.key),t)C.call(t,r)&&!_.hasOwnProperty(r)&&(o[r]=t[r]);var l=arguments.length-2;if(1===l)o.children=n;else if(1<l){for(var c=Array(l),u=0;u<l;u++)c[u]=arguments[u+2];o.children=c}if(e&&e.defaultProps)for(r in l=e.defaultProps)void 0===o[r]&&(o[r]=l[r]);return{$$typeof:i,type:e,key:a,ref:s,props:o,_owner:w.current}}function S(e){return"object"==typeof e&&null!==e&&e.$$typeof===i}var E=/\/+/g;function T(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function O(e,t,n,r,a){var s=typeof e;"undefined"!==s&&"boolean"!==s||(e=null);var l=!1;if(null===e)l=!0;else switch(s){case"string":case"number":l=!0;break;case"object":switch(e.$$typeof){case i:case o:l=!0}}if(l)return a=a(l=e),e=""===r?"."+T(l,0):r,Array.isArray(a)?(n="",null!=e&&(n=e.replace(E,"$&/")+"/"),O(a,t,n,"",(function(e){return e}))):null!=a&&(S(a)&&(a=function(e,t){return{$$typeof:i,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(a,n+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(E,"$&/")+"/")+e)),t.push(a)),1;if(l=0,r=""===r?".":r+":",Array.isArray(e))for(var c=0;c<e.length;c++){var u=r+T(s=e[c],c);l+=O(s,t,n,u,a)}else if("function"==typeof(u=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=f&&e[f]||e["@@iterator"])?e:null}(e)))for(e=u.call(e),c=0;!(s=e.next()).done;)l+=O(s=s.value,t,n,u=r+T(s,c++),a);else if("object"===s)throw t=""+e,Error(d(31,"[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t));return l}function P(e,t,n){if(null==e)return e;var r=[],i=0;return O(e,r,"","",(function(e){return t.call(n,e,i++)})),r}function R(e){if(-1===e._status){var t=e._result;t=t(),e._status=0,e._result=t,t.then((function(t){0===e._status&&(t=t.default,e._status=1,e._result=t)}),(function(t){0===e._status&&(e._status=2,e._result=t)}))}if(1===e._status)return e._result;throw e._result}var x={current:null};function D(){var e=x.current;if(null===e)throw Error(d(321));return e}var j={ReactCurrentDispatcher:x,ReactCurrentBatchConfig:{transition:0},ReactCurrentOwner:w,IsSomeRendererActing:{current:!1},assign:r};n.Children={map:P,forEach:function(e,t,n){P(e,(function(){t.apply(this,arguments)}),n)},count:function(e){var t=0;return P(e,(function(){t++})),t},toArray:function(e){return P(e,(function(e){return e}))||[]},only:function(e){if(!S(e))throw Error(d(143));return e}},n.Component=y,n.PureComponent=v,n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=j,n.cloneElement=function(e,t,n){if(null==e)throw Error(d(267,e));var o=r({},e.props),a=e.key,s=e.ref,l=e._owner;if(null!=t){if(void 0!==t.ref&&(s=t.ref,l=w.current),void 0!==t.key&&(a=""+t.key),e.type&&e.type.defaultProps)var c=e.type.defaultProps;for(u in t)C.call(t,u)&&!_.hasOwnProperty(u)&&(o[u]=void 0===t[u]&&void 0!==c?c[u]:t[u])}var u=arguments.length-2;if(1===u)o.children=n;else if(1<u){c=Array(u);for(var p=0;p<u;p++)c[p]=arguments[p+2];o.children=c}return{$$typeof:i,type:e.type,key:a,ref:s,props:o,_owner:l}},n.createContext=function(e,t){return void 0===t&&(t=null),(e={$$typeof:s,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider={$$typeof:a,_context:e},e.Consumer=e},n.createElement=k,n.createFactory=function(e){var t=k.bind(null,e);return t.type=e,t},n.createRef=function(){return{current:null}},n.forwardRef=function(e){return{$$typeof:l,render:e}},n.isValidElement=S,n.lazy=function(e){return{$$typeof:u,_payload:{_status:-1,_result:e},_init:R}},n.memo=function(e,t){return{$$typeof:c,type:e,compare:void 0===t?null:t}},n.useCallback=function(e,t){return D().useCallback(e,t)},n.useContext=function(e,t){return D().useContext(e,t)},n.useDebugValue=function(){},n.useEffect=function(e,t){return D().useEffect(e,t)},n.useImperativeHandle=function(e,t,n){return D().useImperativeHandle(e,t,n)},n.useLayoutEffect=function(e,t){return D().useLayoutEffect(e,t)},n.useMemo=function(e,t){return D().useMemo(e,t)},n.useReducer=function(e,t,n){return D().useReducer(e,t,n)},n.useRef=function(e){return D().useRef(e)},n.useState=function(e){return D().useState(e)},n.version="17.0.1"},{"object-assign":247}],307:[function(e,t,n){"use strict";
128t.exports=e("./cjs/react.production.min.js")},{"./cjs/react.development.js":305,"./cjs/react.production.min.js":306}],308:[function(e,t,n){(function(n){(function(){"use strict";"production"===n.env.NODE_ENV?t.exports=e("./reactjs-popup.cjs.production.min.js"):t.exports=e("./reactjs-popup.cjs.development.js")}).call(this)}).call(this,e("_process"))},{"./reactjs-popup.cjs.development.js":309,"./reactjs-popup.cjs.production.min.js":310,_process:252}],309:[function(e,t,n){"use strict";function r(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(n,"__esModule",{value:!0});var i=e("react"),o=r(i),a=r(e("react-dom"));function s(){return(s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}var l="undefined"!=typeof window?i.useLayoutEffect:i.useEffect,c={popupContent:{tooltip:{position:"absolute",zIndex:999},modal:{position:"relative",margin:"auto"}},popupArrow:{height:"8px",width:"16px",position:"absolute",background:"transparent",color:"#FFF",zIndex:-1},overlay:{tooltip:{position:"fixed",top:"0",bottom:"0",left:"0",right:"0",zIndex:999},modal:{position:"fixed",top:"0",bottom:"0",left:"0",right:"0",display:"flex",zIndex:999}}},u=["top left","top center","top right","right top","right center","right bottom","bottom left","bottom center","bottom right","left top","left center","left bottom"],p=function(e,t,n,r,i){var o=i.offsetX,a=i.offsetY,s=r?8:0,l=n.split(" "),c=e.top+e.height/2,u=e.left+e.width/2,p=t.height,f=t.width,d=c-p/2,h=u-f/2,m="",y="0%",b="0%";switch(l[0]){case"top":d-=p/2+e.height/2+s,m="rotate(180deg)  translateX(50%)",y="100%",b="50%";break;case"bottom":d+=p/2+e.height/2+s,m="rotate(0deg) translateY(-100%) translateX(-50%)",b="50%";break;case"left":h-=f/2+e.width/2+s,m=" rotate(90deg)  translateY(50%) translateX(-25%)",b="100%",y="50%";break;case"right":h+=f/2+e.width/2+s,m="rotate(-90deg)  translateY(-150%) translateX(25%)",y="50%"}switch(l[1]){case"top":d=e.top,y=e.height/2+"px";break;case"bottom":d=e.top-p+e.height,y=p-e.height/2+"px";break;case"left":h=e.left,b=e.width/2+"px";break;case"right":h=e.left-f+e.width,b=f-e.width/2+"px"}return{top:d="top"===l[0]?d-a:d+a,left:h="left"===l[0]?h-o:h+o,transform:m,arrowLeft:b,arrowTop:y}},f=function(e,t,n,r,i,o){var a=i.offsetX,s=i.offsetY,l={arrowLeft:"0%",arrowTop:"0%",left:0,top:0,transform:"rotate(135deg)"},c=0,f=function(e){var t={top:0,left:0,width:window.innerWidth,height:window.innerHeight};if("string"==typeof e){var n=document.querySelector(e);if(null===n)throw new Error(e+" selector does not exist : keepTooltipInside must be a valid html selector 'class' or 'Id'  or a boolean value");null!==n&&(t=n.getBoundingClientRect())}return t}(o),d=Array.isArray(n)?n:[n];for((o||Array.isArray(n))&&(d=[].concat(d,u));c<d.length;){var h={top:(l=p(e,t,d[c],r,{offsetX:a,offsetY:s})).top,left:l.left,width:t.width,height:t.height};if(!(h.top<=f.top||h.left<=f.left||h.top+h.height>=f.top+f.height||h.left+h.width>=f.left+f.width))break;c++}return l},d=0,h=i.forwardRef((function(e,t){var n=e.trigger,r=void 0===n?null:n,u=e.onOpen,p=void 0===u?function(){}:u,h=e.onClose,m=void 0===h?function(){}:h,y=e.defaultOpen,b=void 0!==y&&y,v=e.open,g=void 0===v?void 0:v,w=e.disabled,C=void 0!==w&&w,_=e.nested,k=void 0!==_&&_,S=e.closeOnDocumentClick,E=void 0===S||S,T=e.repositionOnResize,O=void 0===T||T,P=e.closeOnEscape,R=void 0===P||P,x=e.on,D=void 0===x?["click"]:x,j=e.contentStyle,M=void 0===j?{}:j,A=e.arrowStyle,I=void 0===A?{}:A,N=e.overlayStyle,L=void 0===N?{}:N,F=e.className,U=void 0===F?"":F,q=e.position,B=void 0===q?"bottom center"
128:q,z=e.modal,V=void 0!==z&&z,W=e.lockScroll,H=void 0!==W&&W,Y=e.arrow,X=void 0===Y||Y,G=e.offsetX,$=void 0===G?0:G,Q=e.offsetY,K=void 0===Q?0:Q,J=e.mouseEnterDelay,Z=void 0===J?100:J,ee=e.mouseLeaveDelay,te=void 0===ee?100:ee,ne=e.keepTooltipInside,re=void 0!==ne&&ne,ie=e.children,oe=i.useState(g||b),ae=oe[0],se=oe[1],le=i.useRef(null),ce=i.useRef(null),ue=i.useRef(null),pe=i.useRef(null),fe=i.useRef("popup-"+ ++d),de=!!V||!r,he=i.useRef(0);l((function(){return ae?(pe.current=document.activeElement,Te(),ke(),Ce()):_e(),function(){clearTimeout(he.current)}}),[ae]),i.useEffect((function(){"boolean"==typeof g&&(g?me():ye())}),[g,C]);var me=function(){ae||C||(se(!0),setTimeout(p,0))},ye=function(){ae&&!C&&(se(!1),de&&pe.current.focus(),setTimeout(m,0))},be=function(e){null==e||e.stopPropagation(),ae?ye():me()},ve=function(){clearTimeout(he.current),he.current=setTimeout(me,Z)},ge=function(e){null==e||e.preventDefault(),be()},we=function(){clearTimeout(he.current),he.current=setTimeout(ye,te)},Ce=function(){de&&H&&(document.getElementsByTagName("body")[0].style.overflow="hidden")},_e=function(){de&&H&&(document.getElementsByTagName("body")[0].style.overflow="auto")},ke=function(){var e,t=null==ce||null===(e=ce.current)||void 0===e?void 0:e.querySelectorAll('a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), [tabindex="0"]'),n=Array.prototype.slice.call(t)[0];null==n||n.focus()};i.useImperativeHandle(t,(function(){return{open:function(){me()},close:function(){ye()},toggle:function(){be()}}}));var Se,Ee,Te=function(){if(!de&&ae&&(null==le?void 0:le.current)&&(null==le?void 0:le.current)&&(null==ce?void 0:ce.current)){var e,t,n=le.current.getBoundingClientRect(),r=ce.current.getBoundingClientRect(),i=f(n,r,B,X,{offsetX:$,offsetY:K},re);if(ce.current.style.top=i.top+window.scrollY+"px",ce.current.style.left=i.left+window.scrollX+"px",X&&ue.current)ue.current.style.transform=i.transform,ue.current.style.setProperty("-ms-transform",i.transform),ue.current.style.setProperty("-webkit-transform",i.transform),ue.current.style.top=(null===(e=I.top)||void 0===e?void 0:e.toString())||i.arrowTop,ue.current.style.left=(null===(t=I.left)||void 0===t?void 0:t.toString())||i.arrowLeft}};Se=ye,void 0===(Ee=R)&&(Ee=!0),i.useEffect((function(){if(Ee){var e=function(e){"Escape"===e.key&&Se()};return document.addEventListener("keyup",e),function(){Ee&&document.removeEventListener("keyup",e)}}}),[Se,Ee]),function(e,t){void 0===t&&(t=!0),i.useEffect((function(){if(t){var n=function(t){if(9===t.keyCode){var n,r=null==e||null===(n=e.current)||void 0===n?void 0:n.querySelectorAll('a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), [tabindex="0"]'),i=Array.prototype.slice.call(r);if(1===i.length)return void t.preventDefault();var o=i[0],a=i[i.length-1];t.shiftKey&&document.activeElement===o?(t.preventDefault(),a.focus()):document.activeElement===a&&(t.preventDefault(),o.focus())}};return document.addEventListener("keydown",n),function(){t&&document.removeEventListener("keydown",n)}}}),[e,t])}(ce,ae&&de),function(e,t){void 0===t&&(t=!0),i.useEffect((function(){if(t){var n=function(){e()};return window.addEventListener("resize",n),function(){t&&window.removeEventListener("resize",n)}}}),[e,t])}(Te,O),function(e,t,n){void 0===n&&(n=!0),i.useEffect((function(){if(n){var r=function(n){var r=Array.isArray(e)?e:[e],i=!1;r.forEach((function(e){e.current&&!e.current.contains(n.target)||(i=!0)})),n.stopPropagation(),i||t()};return document.addEventListener("mousedown",r),document.addEventListener("touchstart",r),function(){n&&(document.removeEventListener("mousedown",r),document.removeEventListener("touchstart",r))}}}),[e,t,n])}(r?[ce,le]:[ce],ye,E&&!k);var Oe,Pe=function(){return o.createElement("div",Object.assign({},(e=de?c.popupContent.modal:c.popupContent.tooltip,t={className:"popup-content "+(""!==U?U.split(" ").map((function(e){return e+"-content"})).join(" "):""),style:s({},e,M,{pointerEvents:"auto"}),ref:ce,onClick:function(e){e.stopPropagation()}},!V&&D.indexOf("hover")>=0&&(t.onMouseEnter=ve,t.onMouseLeave=we),t),{key:"C",role:de?"dialog":"tooltip",id:fe.current}),X&&!de&&o.createElement("div",{ref:ue,style:c.popupArrow},o.createElement("svg",{"data-testid":"arrow",className:"popup-arrow "+(""!==U?U.split(" ").map((function(e){return e+"-arrow"})).join(" "):""),viewBox:"0 0 32 16",style:s({position:"absolute"},I)}
128,o.createElement("path",{d:"M16 0l16 16H0z",fill:"currentcolor"}))),ie&&"function"==typeof ie?ie(ye,ae):ie);var e,t},Re=!(D.indexOf("hover")>=0),xe=de?c.overlay.modal:c.overlay.tooltip,De=[Re&&o.createElement("div",{key:"O","data-testid":"overlay","data-popup":de?"modal":"tooltip",className:"popup-overlay "+(""!==U?U.split(" ").map((function(e){return e+"-overlay"})).join(" "):""),style:s({},xe,L,{pointerEvents:E&&k||de?"auto":"none"}),onClick:E&&k?ye:void 0,tabIndex:-1},de&&Pe()),!de&&Pe()];return o.createElement(o.Fragment,null,function(){for(var e={key:"T",ref:le,"aria-describedby":fe.current},t=Array.isArray(D)?D:[D],n=0,i=t.length;n<i;n++)switch(t[n]){case"click":e.onClick=be;break;case"right-click":e.onContextMenu=ge;break;case"hover":e.onMouseEnter=ve,e.onMouseLeave=we;break;case"focus":e.onFocus=ve,e.onBlur=we}if("function"==typeof r){var a=r(ae);return!!r&&o.cloneElement(a,e)}return!!r&&o.cloneElement(r,e)}(),ae&&a.createPortal(De,(null===(Oe=document.getElementById("popup-root"))&&((Oe=document.createElement("div")).setAttribute("id","popup-root"),document.body.appendChild(Oe)),Oe)))}));n.Popup=h,n.default=h},{react:307,"react-dom":268}],310:[function(e,t,n){"use strict";function r(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(n,"__esModule",{value:!0});var i=e("react"),o=r(i),a=r(e("react-dom"));function s(){return(s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}var l="undefined"!=typeof window?i.useLayoutEffect:i.useEffect,c={popupContent:{tooltip:{position:"absolute",zIndex:999},modal:{position:"relative",margin:"auto"}},popupArrow:{height:"8px",width:"16px",position:"absolute",background:"transparent",color:"#FFF",zIndex:-1},overlay:{tooltip:{position:"fixed",top:"0",bottom:"0",left:"0",right:"0",zIndex:999},modal:{position:"fixed",top:"0",bottom:"0",left:"0",right:"0",display:"flex",zIndex:999}}},u=["top left","top center","top right","right top","right center","right bottom","bottom left","bottom center","bottom right","left top","left center","left bottom"],p=function(e,t,n,r,i){var o=i.offsetX,a=i.offsetY,s=r?8:0,l=n.split(" "),c=t.height,u=t.width,p=e.top+e.height/2-c/2,f=e.left+e.width/2-u/2,d="",h="0%",m="0%";switch(l[0]){case"top":p-=c/2+e.height/2+s,d="rotate(180deg)  translateX(50%)",h="100%",m="50%";break;case"bottom":p+=c/2+e.height/2+s,d="rotate(0deg) translateY(-100%) translateX(-50%)",m="50%";break;case"left":f-=u/2+e.width/2+s,d=" rotate(90deg)  translateY(50%) translateX(-25%)",m="100%",h="50%";break;case"right":f+=u/2+e.width/2+s,d="rotate(-90deg)  translateY(-150%) translateX(25%)",h="50%"}switch(l[1]){case"top":p=e.top,h=e.height/2+"px";break;case"bottom":p=e.top-c+e.height,h=c-e.height/2+"px";break;case"left":f=e.left,m=e.width/2+"px";break;case"right":f=e.left-u+e.width,m=u-e.width/2+"px"}return{top:p="top"===l[0]?p-a:p+a,left:f="left"===l[0]?f-o:f+o,transform:d,arrowLeft:m,arrowTop:h}},f=0,d=i.forwardRef((function(e,t){var n=e.trigger,r=void 0===n?null:n,d=e.onOpen,h=void 0===d?function(){}:d,m=e.onClose,y=void 0===m?function(){}:m,b=e.defaultOpen,v=e.open,g=void 0===v?void 0:v,w=e.disabled,C=void 0!==w&&w,_=e.nested,k=void 0!==_&&_,S=e.closeOnDocumentClick,E=void 0===S||S,T=e.repositionOnResize,O=void 0===T||T,P=e.closeOnEscape,R=void 0===P||P,x=e.on,D=void 0===x?["click"]:x,j=e.contentStyle,M=void 0===j?{}:j,A=e.arrowStyle,I=void 0===A?{}:A,N=e.overlayStyle,L=void 0===N?{}:N,F=e.className,U=void 0===F?"":F,q=e.position,B=void 0===q?"bottom center"
128:q,z=e.modal,V=void 0!==z&&z,W=e.lockScroll,H=void 0!==W&&W,Y=e.arrow,X=void 0===Y||Y,G=e.offsetX,$=void 0===G?0:G,Q=e.offsetY,K=void 0===Q?0:Q,J=e.mouseEnterDelay,Z=void 0===J?100:J,ee=e.mouseLeaveDelay,te=void 0===ee?100:ee,ne=e.keepTooltipInside,re=void 0!==ne&&ne,ie=e.children,oe=i.useState(g||void 0!==b&&b),ae=oe[0],se=oe[1],le=i.useRef(null),ce=i.useRef(null),ue=i.useRef(null),pe=i.useRef(null),fe=i.useRef("popup-"+ ++f),de=!!V||!r,he=i.useRef(0);l((function(){return ae?(pe.current=document.activeElement,Te(),ke(),Ce()):_e(),function(){clearTimeout(he.current)}}),[ae]),i.useEffect((function(){"boolean"==typeof g&&(g?me():ye())}),[g,C]);var me=function(){ae||C||(se(!0),setTimeout(h,0))},ye=function(){ae&&!C&&(se(!1),de&&pe.current.focus(),setTimeout(y,0))},be=function(e){null==e||e.stopPropagation(),ae?ye():me()},ve=function(){clearTimeout(he.current),he.current=setTimeout(me,Z)},ge=function(e){null==e||e.preventDefault(),be()},we=function(){clearTimeout(he.current),he.current=setTimeout(ye,te)},Ce=function(){de&&H&&(document.getElementsByTagName("body")[0].style.overflow="hidden")},_e=function(){de&&H&&(document.getElementsByTagName("body")[0].style.overflow="auto")},ke=function(){var e,t=null==ce||null===(e=ce.current)||void 0===e?void 0:e.querySelectorAll('a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), [tabindex="0"]'),n=Array.prototype.slice.call(t)[0];null==n||n.focus()};i.useImperativeHandle(t,(function(){return{open:function(){me()},close:function(){ye()},toggle:function(){be()}}}));var Se,Ee,Te=function(){if(!de&&ae&&(null==le?void 0:le.current)&&(null==le?void 0:le.current)&&(null==ce?void 0:ce.current)){var e,t,n=function(e,t,n,r,i,o){var a=i.offsetX,s=i.offsetY,l={arrowLeft:"0%",arrowTop:"0%",left:0,top:0,transform:"rotate(135deg)"},c=0,f=function(e){var t={top:0,left:0,width:window.innerWidth,height:window.innerHeight};if("string"==typeof e){var n=document.querySelector(e);null!==n&&(t=n.getBoundingClientRect())}return t}(o),d=Array.isArray(n)?n:[n];for((o||Array.isArray(n))&&(d=[].concat(d,u));c<d.length;){var h={top:(l=p(e,t,d[c],r,{offsetX:a,offsetY:s})).top,left:l.left,width:t.width,height:t.height};if(!(h.top<=f.top||h.left<=f.left||h.top+h.height>=f.top+f.height||h.left+h.width>=f.left+f.width))break;c++}return l}(le.current.getBoundingClientRect(),ce.current.getBoundingClientRect(),B,X,{offsetX:$,offsetY:K},re);ce.current.style.top=n.top+window.scrollY+"px",ce.current.style.left=n.left+window.scrollX+"px",X&&ue.current&&(ue.current.style.transform=n.transform,ue.current.style.setProperty("-ms-transform",n.transform),ue.current.style.setProperty("-webkit-transform",n.transform),ue.current.style.top=(null===(e=I.top)||void 0===e?void 0:e.toString())||n.arrowTop,ue.current.style.left=(null===(t=I.left)||void 0===t?void 0:t.toString())||n.arrowLeft)}};void 0===(Ee=R)&&(Ee=!0),i.useEffect((function(){if(Ee){var e=function(e){"Escape"===e.key&&Se()};return document.addEventListener("keyup",e),function(){Ee&&document.removeEventListener("keyup",e)}}}),[Se=ye,Ee]),function(e,t){void 0===t&&(t=!0),i.useEffect((function(){if(t){var n=function(t){if(9===t.keyCode){var n,r=null==e||null===(n=e.current)||void 0===n?void 0:n.querySelectorAll('a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), [tabindex="0"]'),i=Array.prototype.slice.call(r);if(1===i.length)return void t.preventDefault();var o=i[0],a=i[i.length-1];t.shiftKey&&document.activeElement===o?(t.preventDefault(),a.focus()):document.activeElement===a&&(t.preventDefault(),o.focus())}};return document.addEventListener("keydown",n),function(){t&&document.removeEventListener("keydown",n)}}}),[e,t])}(ce,ae&&de),function(e,t){void 0===t&&(t=!0),i.useEffect((function(){if(t){var n=function(){e()};return window.addEventListener("resize",n),function(){t&&window.removeEventListener("resize",n)}}}),[e,t])}(Te,O),function(e,t,n){void 0===n&&(n=!0),i.useEffect((function(){if(n){var r=function(n){var r=Array.isArray(e)?e:[e],i=!1;r.forEach((function(e){e.current&&!e.current.contains(n.target)||(i=!0)})),n.stopPropagation(),i||t()};return document.addEventListener("mousedown",r),document.addEventListener("touchstart",r),function(){n&&(document.removeEventListener("mousedown",r),document.removeEventListener("touchstart",r))}}}),[e,t,n])}(r?[ce,le]:[ce],ye,E&&!k);var Oe,Pe=function(){return o.createElement("div",Object.assign({},(e=de?c.popupContent.modal:c.popupContent.tooltip,t={className:"popup-content "+(""!==U?U.split(" ").map((function(e){return e+"-content"})).join(" "):""),style:s({},e,M,{pointerEvents:"auto"}),ref:ce,onClick:function(e){e.stopPropagation()}},!V&&D.indexOf("hover")>=0&&(t.onMouseEnter=ve,t.onMouseLeave=we),t),{key:"C",role:de?"dialog":"tooltip",id:fe.current}),X&&!de&&o.createElement("div",{ref:ue,style:c.popupArrow},o.createElement("svg",{"data-testid":"arrow",className:"popup-arrow "+(""!==U?U.split(" ").map((function(e){return e+"-arrow"})).join(" "):""),viewBox:"0 0 32 16",style:s({position:"absolute"},I)}
128,o.createElement("path",{d:"M16 0l16 16H0z",fill:"currentcolor"}))),ie&&"function"==typeof ie?ie(ye,ae):ie);var e,t},Re=!(D.indexOf("hover")>=0),xe=de?c.overlay.modal:c.overlay.tooltip,De=[Re&&o.createElement("div",{key:"O","data-testid":"overlay","data-popup":de?"modal":"tooltip",className:"popup-overlay "+(""!==U?U.split(" ").map((function(e){return e+"-overlay"})).join(" "):""),style:s({},xe,L,{pointerEvents:E&&k||de?"auto":"none"}),onClick:E&&k?ye:void 0,tabIndex:-1},de&&Pe()),!de&&Pe()];return o.createElement(o.Fragment,null,function(){for(var e={key:"T",ref:le,"aria-describedby":fe.current},t=Array.isArray(D)?D:[D],n=0,i=t.length;n<i;n++)switch(t[n]){case"click":e.onClick=be;break;case"right-click":e.onContextMenu=ge;break;case"hover":e.onMouseEnter=ve,e.onMouseLeave=we;break;case"focus":e.onFocus=ve,e.onBlur=we}if("function"==typeof r){var a=r(ae);return!!r&&o.cloneElement(a,e)}return!!r&&o.cloneElement(r,e)}(),ae&&a.createPortal(De,(null===(Oe=document.getElementById("popup-root"))&&((Oe=document.createElement("div")).setAttribute("id","popup-root"),document.body.appendChild(Oe)),Oe)))}));n.Popup=d,n.default=d},{react:307,"react-dom":268}],311:[function(e,t,n){"use strict";function r(e){return function(t){var n=t.dispatch,r=t.getState;return function(t){return function(i){return"function"==typeof i?i(n,r,e):t(i)}}}}n.__esModule=!0;var i=r();i.withExtraArgument=r,n.default=i},{}],312:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r,i=(r=e("symbol-observable"))&&"object"==typeof r&&"default"in r?r.default:r,o=function(){return Math.random().toString(36).substring(7).split("").join(".")},a={INIT:"@@redux/INIT"+o(),REPLACE:"@@redux/REPLACE"+o(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+o()}};function s(e){if("object"!=typeof e||null===e)return!1;for(var t=e;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function l(e,t){var n=t&&t.type;return"Given "+(n&&'action "'+String(n)+'"'||"an action")+', reducer "'+e+'" returned undefined. To ignore an action, you must explicitly return the previous state. If you want this reducer to hold no value, you can return null instead of undefined.'}function c(e,t){return function(){return t(e.apply(this,arguments))}}function u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function p(e,t){var n=Object.keys(e);return Object.getOwnPropertySymbols&&n.push.apply(n,Object.getOwnPropertySymbols(e)),t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(n,!0).forEach((function(t){u(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(n).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function d(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return 0===t.length?function(e){return e}:1===t.length?t[0]:t.reduce((function(e,t){return function(){return e(t.apply(void 0,arguments))}}))}n.__DO_NOT_USE__ActionTypes=a,n.applyMiddleware=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){return function(){var n=e.apply(void 0,arguments),r=function(){throw new Error("Dispatching while constructing your middleware is not allowed. Other middleware would not be applied to this dispatch.")},i={getState:n.getState,dispatch:function(){return r.apply(void 0,arguments)}},o=t.map((function(e){return e(i)}));return f({},n,{dispatch:r=d.apply(void 0,o)(n.dispatch)})}}},n.bindActionCreators=function(e,t){if("function"==typeof e)return c(e,t);if("object"!=typeof e||null===e)throw new Error("bindActionCreators expected an object or a function, instead received "+(null===e?"null":typeof e)+'. Did you write "import ActionCreators from" instead of "import * as ActionCreators from"?');var n={};for(var r in e){var i=e[r];"function"==typeof i&&(n[r]=c(i,t))}return n},n.combineReducers=function(e){for(var t=Object.keys(e),n={},r=0;r<t.length;r++){var i=t[r];0,"function"==typeof e[i]&&(n[i]=e[i])}var o,s=Object.keys(n);try{!function(e){Object.keys(e).forEach((function(t){var n=e[t];if(void 0===n(void 0,{type:a.INIT}))throw new Error('Reducer "'+t+"\" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined. If you don't want to set a value for this reducer, you can use null instead of undefined.");if(void 0===n(void 0,{type:a.PROBE_UNKNOWN_ACTION()}))throw new Error('Reducer "'+t+"\" returned undefined when probed with a random type. Don't try to handle "+a.INIT+' or other actions in "redux/*" namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined, but can be null.')}))}(n)}catch(e){o=e}return function(e,t){if(void 0===e&&(e={}),o)throw o;for(var r=!1,i={},a=0;a<s.length;a++){var c=s[a],u=n[c],p=e[c],f=u(p,t);
128if(void 0===f){var d=l(c,t);throw new Error(d)}i[c]=f,r=r||f!==p}return(r=r||s.length!==Object.keys(e).length)?i:e}},n.compose=d,n.createStore=function e(t,n,r){var o;if("function"==typeof n&&"function"==typeof r||"function"==typeof r&&"function"==typeof arguments[3])throw new Error("It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function.");if("function"==typeof n&&void 0===r&&(r=n,n=void 0),void 0!==r){if("function"!=typeof r)throw new Error("Expected the enhancer to be a function.");return r(e)(t,n)}if("function"!=typeof t)throw new Error("Expected the reducer to be a function.");var l=t,c=n,u=[],p=u,f=!1;function d(){p===u&&(p=u.slice())}function h(){if(f)throw new Error("You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return c}function m(e){if("function"!=typeof e)throw new Error("Expected the listener to be a function.");if(f)throw new Error("You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api-reference/store#subscribelistener for more details.");var t=!0;return d(),p.push(e),function(){if(t){if(f)throw new Error("You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api-reference/store#subscribelistener for more details.");t=!1,d();var n=p.indexOf(e);p.splice(n,1),u=null}}}function y(e){if(!s(e))throw new Error("Actions must be plain objects. Use custom middleware for async actions.");if(void 0===e.type)throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?');if(f)throw new Error("Reducers may not dispatch actions.");try{f=!0,c=l(c,e)}finally{f=!1}for(var t=u=p,n=0;n<t.length;n++){(0,t[n])()}return e}function b(e){if("function"!=typeof e)throw new Error("Expected the nextReducer to be a function.");l=e,y({type:a.REPLACE})}function v(){var e,t=m;return(e={subscribe:function(e){if("object"!=typeof e||null===e)throw new TypeError("Expected the observer to be an object.");function n(){e.next&&e.next(h())}return n(),{unsubscribe:t(n)}}})[i]=function(){return this},e}return y({type:a.INIT}),(o={dispatch:y,subscribe:m,getState:h,replaceReducer:b})[i]=v,o}},{"symbol-observable":339}],313:[function(e,t,n){"use strict";var r=Object,i=TypeError;t.exports=function(){if(null!=this&&this!==r(this))throw new i("RegExp.prototype.flags getter called on non-object");var e="";return this.global&&(e+="g"),this.ignoreCase&&(e+="i"),this.multiline&&(e+="m"),this.dotAll&&(e+="s"),this.unicode&&(e+="u"),this.sticky&&(e+="y"),e}},{}],314:[function(e,t,n){"use strict";var r=e("define-properties"),i=e("call-bind"),o=e("./implementation"),a=e("./polyfill"),s=e("./shim"),l=i(o);r(l,{getPolyfill:a,implementation:o,shim:s}),t.exports=l},{"./implementation":313,"./polyfill":317,"./shim":318,"call-bind":315,"define-properties":159}],315:[function(e,t,n){arguments[4][215][0].apply(n,arguments)},{dup:215,"function-bind":224,"get-intrinsic":316}],316:[function(e,t,n){arguments[4][216][0].apply(n,arguments)},{dup:216,"function-bind":224,has:228,"has-symbols":226}],317:[function(e,t,n){"use strict";var r=e("./implementation"),i=e("define-properties").supportsDescriptors,o=Object.getOwnPropertyDescriptor,a=TypeError;t.exports=function(){if(!i)throw new a("RegExp.prototype.flags requires a true ES5 environment that supports property descriptors");if("gim"===/a/gim.flags){var e=o(RegExp.prototype,"flags");if(e&&"function"==typeof e.get&&"boolean"==typeof/a/.dotAll)return e.get}return r}},{"./implementation":313,"define-properties":159}],318:[function(e,t,n){"use strict";var r=e("define-properties").supportsDescriptors,i=e("./polyfill"),o=Object.getOwnPropertyDescriptor,a=Object.defineProperty,s=TypeError,l=Object.getPrototypeOf,c=/a/;t.exports=function(){if(!r||!l)throw new s("RegExp.prototype.flags requires a true ES5 environment that supports property descriptors");var e=i(),t=l(c),n=o(t,"flags");return n&&n.get===e||a(t,"flags",{configurable:!0,enumerable:!1,get:e}),e}},{"./polyfill":317,"define-properties":159}],319:[function(e,t,n){
129/** @license React v0.20.1
130 * scheduler-tracing.development.js
131 *
132 * Copyright (c) Facebook, Inc. and its affiliates.
133 *
134 * This source code is licensed under the MIT license found in the
135 * LICENSE file in the root directory of this source tree.
136 */
137"use strict"},{}],320:[function(e,t,n){
138/** @license React v0.20.1
139 * scheduler-tracing.production.min.js
140 *
141 * Copyright (c) Facebook, Inc. and its affiliates.
142 *
143 * This source code is licensed under the MIT license found in the
144 * LICENSE file in the root directory of this source tree.
145 */
146"use strict";var r=0;n.__interactionsRef=null,n.__subscriberRef=null,n.unstable_clear=function(e){return e()},n.unstable_getCurrent=function(){return null},n.unstable_getThreadID=function(){return++r},n.unstable_subscribe=function(){},n.unstable_trace=function(e,t,n){return n()},n.unstable_unsubscribe=function(){},n.unstable_wrap=function(e){return e}},{}],321:[function(e,t,n){
147/** @license React v0.20.1
148 * scheduler.development.js
149 *
150 * Copyright (c) Facebook, Inc. and its affiliates.
151 *
152 * This source code is licensed under the MIT license found in the
153 * LICENSE file in the root directory of this source tree.
154 */
155"use strict"},{}],322:[function(e,t,n){
156/** @license React v0.20.1
157 * scheduler.production.min.js
158 *
159 * Copyright (c) Facebook, Inc. and its affiliates.
160 *
161 * This source code is licensed under the MIT license found in the
162 * LICENSE file in the root directory of this source tree.
163 */
164"use strict";var r,i,o,a;if("object"==typeof performance&&"function"==typeof performance.now){var s=performance;n.unstable_now=function(){return s.now()}}else{var l=Date,c=l.now();n.unstable_now=function(){return l.now()-c}}if("undefined"==typeof window||"function"!=typeof MessageChannel){var u=null,p=null,f=function(){if(null!==u)try{var e=n.unstable_now();
vendor: 4,220 bytes, line 164
164u(!0,e),u=null}catch(e){throw setTimeout(f,0),e}};r=function(e){null!==u?setTimeout(r,0,e):(u=e,setTimeout(f,0))},i=function(e,t){p=setTimeout(e,t)},o=function(){clearTimeout(p)},n.unstable_shouldYield=function(){return!1},a=n.unstable_forceFrameRate=function(){}}else{var d=window.setTimeout,h=window.clearTimeout;if("undefined"!=typeof console){var m=window.cancelAnimationFrame;"function"!=typeof window.requestAnimationFrame&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"),"function"!=typeof m&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")}var y=!1,b=null,v=-1,g=5,w=0;n.unstable_shouldYield=function(){return n.unstable_now()>=w},a=function(){},n.unstable_forceFrameRate=function(e){0>e||125<e?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):g=0<e?Math.floor(1e3/e):5};var C=new MessageChannel,_=C.port2;C.port1.onmessage=function(){if(null!==b){var e=n.unstable_now();w=e+g;try{b(!0,e)?_.postMessage(null):(y=!1,b=null)}catch(e){throw _.postMessage(null),e}}else y=!1},r=function(e){b=e,y||(y=!0,_.postMessage(null))},i=function(e,t){v=d((function(){e(n.unstable_now())}),t)},o=function(){h(v),v=-1}}function k(e,t){var n=e.length;e.push(t);e:for(;;){var r=n-1>>>1,i=e[r];if(!(void 0!==i&&0<T(i,t)))break e;e[r]=t,e[n]=i,n=r}}function S(e){return void 0===(e=e[0])?null:e}function E(e){var t=e[0];if(void 0!==t){var n=e.pop();if(n!==t){e[0]=n;e:for(var r=0,i=e.length;r<i;){var o=2*(r+1)-1,a=e[o],s=o+1,l=e[s];if(void 0!==a&&0>T(a,n))void 0!==l&&0>T(l,a)?(e[r]=l,e[s]=n,r=s):(e[r]=a,e[o]=n,r=o);else{if(!(void 0!==l&&0>T(l,n)))break e;e[r]=l,e[s]=n,r=s}}}return t}return null}function T(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}var O=[],P=[],R=1,x=null,D=3,j=!1,M=!1,A=!1;function I(e){for(var t=S(P);null!==t;){if(null===t.callback)E(P);else{if(!(t.startTime<=e))break;E(P),t.sortIndex=t.expirationTime,k(O,t)}t=S(P)}}function N(e){if(A=!1,I(e),!M)if(null!==S(O))M=!0,r(L);else{var t=S(P);null!==t&&i(N,t.startTime-e)}}function L(e,t){M=!1,A&&(A=!1,o()),j=!0;var r=D;try{for(I(t),x=S(O);null!==x&&(!(x.expirationTime>t)||e&&!n.unstable_shouldYield());){var a=x.callback;if("function"==typeof a){x.callback=null,D=x.priorityLevel;var s=a(x.expirationTime<=t);t=n.unstable_now(),"function"==typeof s?x.callback=s:x===S(O)&&E(O),I(t)}else E(O);x=S(O)}if(null!==x)var l=!0;else{var c=S(P);null!==c&&i(N,c.startTime-t),l=!1}return l}finally{x=null,D=r,j=!1}}var F=a;n.unstable_IdlePriority=5,n.unstable_ImmediatePriority=1,n.unstable_LowPriority=4,n.unstable_NormalPriority=3,n.unstable_Profiling=null,n.unstable_UserBlockingPriority=2,n.unstable_cancelCallback=function(e){e.callback=null},n.unstable_continueExecution=function(){M||j||(M=!0,r(L))},n.unstable_getCurrentPriorityLevel=function(){return D},n.unstable_getFirstCallbackNode=function(){return S(O)},n.unstable_next=function(e){switch(D){case 1:case 2:case 3:var t=3;break;default:t=D}var n=D;D=t;try{return e()}finally{D=n}},n.unstable_pauseExecution=function(){},n.unstable_requestPaint=F,n.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=D;D=e;try{return t()}finally{D=n}},n.unstable_scheduleCallback=function(e,t,a){var s=n.unstable_now();switch("object"==typeof a&&null!==a?a="number"==typeof(a=a.delay)&&0<a?s+a:s:a=s,e){case 1:var l=-1;break;case 2:l=250;break;case 5:l=1073741823;break;case 4:l=1e4;break;default:l=5e3}return e={id:R++,callback:t,priorityLevel:e,startTime:a,expirationTime:l=a+l,sortIndex:-1},a>s?(e.sortIndex=a,k(P,e),null===S(O)&&e===S(P)&&(A?o():A=!0,i(N,a-s))):(e.sortIndex=l,k(O,e),M||j||(M=!0,r(L))),e},n.unstable_wrapCallback=function(e){var t=D;return function(){var n=D;D=t;try{return e.apply(this,arguments)}finally{D=n}}}},{}],323:[function(e,t,n){"use strict";t.exports=e("./cjs/scheduler.production.min.js")},{"./cjs/scheduler.development.js":321,"./cjs/scheduler.production.min.js":322}],324:[function(e,t,n){"use strict";
164t.exports=e("./cjs/scheduler-tracing.production.min.js")},{"./cjs/scheduler-tracing.development.js":319,"./cjs/scheduler-tracing.production.min.js":320}],325:[function(e,t,n){"use strict";var r=e("get-intrinsic"),i=e("call-bind/callBound"),o=e("object-inspect"),a=r("%TypeError%"),s=r("%WeakMap%",!0),l=r("%Map%",!0),c=i("WeakMap.prototype.get",!0),u=i("WeakMap.prototype.set",!0),p=i("WeakMap.prototype.has",!0),f=i("Map.prototype.get",!0),d=i("Map.prototype.set",!0),h=i("Map.prototype.has",!0),m=function(e,t){for(var n,r=e;null!==(n=r.next);r=n)if(n.key===t)return r.next=n.next,n.next=e.next,e.next=n,n};t.exports=function(){var e,t,n,r={assert:function(e){if(!r.has(e))throw new a("Side channel does not contain "+o(e))},get:function(r){if(s&&r&&("object"==typeof r||"function"==typeof r)){if(e)return c(e,r)}else if(l){if(t)return f(t,r)}else if(n)return function(e,t){var n=m(e,t);return n&&n.value}(n,r)},has:function(r){if(s&&r&&("object"==typeof r||"function"==typeof r)){if(e)return p(e,r)}else if(l){if(t)return h(t,r)}else if(n)return function(e,t){return!!m(e,t)}(n,r);return!1},set:function(r,i){s&&r&&("object"==typeof r||"function"==typeof r)?(e||(e=new s),u(e,r,i)):l?(t||(t=new l),d(t,r,i)):(n||(n={key:{},next:null}),function(e,t,n){var r=m(e,t);r?r.value=n:e.next={key:t,next:e.next,value:n}}(n,r,i))}};return r}},{"call-bind/callBound":154,"get-intrinsic":326,"object-inspect":248}],326:[function(e,t,n){arguments[4][216][0].apply(n,arguments)},{dup:216,"function-bind":224,has:228,"has-symbols":226}],327:[function(e,t,n){"use strict";var r=e("define-properties"),i=e("es-abstract/2020/AdvanceStringIndex"),o=e("es-abstract/2020/CreateIterResultObject"),a=e("es-abstract/2020/Get"),s=e("get-intrinsic"),l=e("es-abstract/2020/OrdinaryObjectCreate"),c=e("es-abstract/2020/RegExpExec"),u=e("es-abstract/2020/Set"),p=e("es-abstract/2020/ToLength"),f=e("es-abstract/2020/ToString"),d=e("es-abstract/2020/Type"),h=e("has-symbols")(),m=e("internal-slot"),y=function(e,t,n,r){if("String"!==d(t))throw new TypeError("S must be a string");if("Boolean"!==d(n))throw new TypeError("global must be a boolean");if("Boolean"!==d(r))throw new TypeError("fullUnicode must be a boolean");m.set(this,"[[IteratingRegExp]]",e),m.set(this,"[[IteratedString]]",t),m.set(this,"[[Global]]",n),m.set(this,"[[Unicode]]",r),m.set(this,"[[Done]]",!1)},b=s("%IteratorPrototype%",!0);if(b&&(y.prototype=l(b)),r(y.prototype,{next:function(){var e=this;if("Object"!==d(e))throw new TypeError("receiver must be an object");if(!(e instanceof y&&m.has(e,"[[IteratingRegExp]]")&&m.has(e,"[[IteratedString]]")&&m.has(e,"[[Global]]")&&m.has(e,"[[Unicode]]")&&m.has(e,"[[Done]]")))throw new TypeError('"this" value must be a RegExpStringIterator instance');if(m.get(e,"[[Done]]"))return o(void 0,!0);var t=m.get(e,"[[IteratingRegExp]]"),n=m.get(e,"[[IteratedString]]"),r=m.get(e,"[[Global]]"),s=m.get(e,"[[Unicode]]"),l=c(t,n);if(null===l)return m.set(e,"[[Done]]",!0),o(void 0,!0);if(r){if(""===f(a(l,"0"))){var h=p(a(t,"lastIndex")),b=i(n,h,s);u(t,"lastIndex",b,!0)}return o(l,!1)}return m.set(e,"[[Done]]",!0),o(l,!1)}}),h){var v=Object.defineProperty;if(Symbol.toStringTag&&(v?v(y.prototype,Symbol.toStringTag,{configurable:!0,enumerable:!1,value:"RegExp String Iterator",writable:!1}):y.prototype[Symbol.toStringTag]="RegExp String Iterator"),!b&&Symbol.iterator){var g={};g[Symbol.iterator]=y.prototype[Symbol.iterator]||function(){return this};var w={};w[Symbol.iterator]=function(){return y.prototype[Symbol.iterator]!==g[Symbol.iterator]},r(y.prototype,g,w)}}t.exports=y},{"define-properties":159,"es-abstract/2020/AdvanceStringIndex":160,"es-abstract/2020/CreateIterResultObject":163,"es-abstract/2020/Get":166,"es-abstract/2020/OrdinaryObjectCreate":177,"es-abstract/2020/RegExpExec":178,"es-abstract/2020/Set":181,"es-abstract/2020/ToLength":185,"es-abstract/2020/ToString":190,"es-abstract/2020/Type":191,"get-intrinsic":332,"has-symbols":333,"internal-slot":231}],328:[function(e,t,n){"use strict";var r=e("es-abstract/2020/Call"),i=e("es-abstract/2020/Get"),o=e("es-abstract/2020/GetMethod"),a=e("es-abstract/2020/IsRegExp"),s=e("es-abstract/2020/ToString"),l=e("es-abstract/2020/RequireObjectCoercible"),c=e("call-bind/callBound"),u=e("has-symbols")(),p=e("regexp.prototype.flags"),f=c("String.prototype.indexOf"),d=e("./polyfill-regexp-matchall"),h=function(e){var t=d();if(u&&"symbol"==typeof Symbol.matchAll){var n=o(e,Symbol.matchAll);return n===RegExp.prototype[Symbol.matchAll]&&n!==t?t:n}if(a(e))return t};t.exports=function(e){var t=l(this);if(null!=e){if(a(e)){var n="flags"in e?i(e,"flags"):p(e);if(l(n),f(s(n),"g")<0)throw new TypeError("matchAll requires a global regular expression")}var o=h(e);if(void 0!==o)return r(o,e,[t])}var c=s(t),u=new RegExp(e,"g");return r(h(u),u,[c])}},{"./polyfill-regexp-matchall":335,"call-bind/callBound":330,"es-abstract/2020/Call":161,"es-abstract/2020/Get":166,"es-abstract/2020/GetMethod":167,"es-abstract/2020/IsRegExp":176,"es-abstract/2020/RequireObjectCoercible":179,"es-abstract/2020/ToString":190,"has-symbols":333,"regexp.prototype.flags":314}],329:[function(e,t,n){"use strict";var r=e("call-bind"),i=e("define-properties"),o=e("./implementation"),a=e("./polyfill"),s=e("./shim"),l=r(o);i(l,{getPolyfill:a,implementation:o,shim:s}),t.exports=l},{"./implementation":328,"./polyfill":336,"./shim":338,"call-bind":331,"define-properties":159}],330:[function(e,t,n){arguments[4][154][0].apply(n,arguments)}
164,{"./":331,dup:154,"get-intrinsic":332}],331:[function(e,t,n){arguments[4][215][0].apply(n,arguments)},{dup:215,"function-bind":224,"get-intrinsic":332}],332:[function(e,t,n){arguments[4][216][0].apply(n,arguments)},{dup:216,"function-bind":224,has:228,"has-symbols":333}],333:[function(e,t,n){arguments[4][217][0].apply(n,arguments)},{"./shams":334,dup:217}],334:[function(e,t,n){arguments[4][218][0].apply(n,arguments)},{dup:218}],335:[function(e,t,n){"use strict";var r=e("has-symbols")(),i=e("./regexp-matchall");t.exports=function(){return r&&"symbol"==typeof Symbol.matchAll&&"function"==typeof RegExp.prototype[Symbol.matchAll]?RegExp.prototype[Symbol.matchAll]:i}},{"./regexp-matchall":337,"has-symbols":333}],336:[function(e,t,n){"use strict";var r=e("./implementation");t.exports=function(){if(String.prototype.matchAll)try{"".matchAll(RegExp.prototype)}catch(e){return String.prototype.matchAll}return r}},{"./implementation":328}],337:[function(e,t,n){"use strict";var r=e("es-abstract/2020/Get"),i=e("es-abstract/2020/Set"),o=e("es-abstract/2020/SpeciesConstructor"),a=e("es-abstract/2020/ToLength"),s=e("es-abstract/2020/ToString"),l=e("es-abstract/2020/Type"),c=e("regexp.prototype.flags"),u=e("./helpers/RegExpStringIterator"),p=RegExp,f="flags"in RegExp.prototype,d=function(e){var t=this;if("Object"!==l(t))throw new TypeError('"this" value must be an Object');var n=s(e),d=function(e,t){var n="flags"in t?r(t,"flags"):s(c(t));return{flags:n,matcher:new e(f&&"string"==typeof n?t:e===p?t.source:t,n)}}(o(t,p),t),h=d.flags,m=d.matcher,y=a(r(t,"lastIndex"));return i(m,"lastIndex",y,!0),function(e,t,n,r){if("String"!==l(t))throw new TypeError('"S" value must be a String');if("Boolean"!==l(n))throw new TypeError('"global" value must be a Boolean');if("Boolean"!==l(r))throw new TypeError('"fullUnicode" value must be a Boolean');return new u(e,t,n,r)}(m,n,h.indexOf("g")>-1,h.indexOf("u")>-1)},h=Object.defineProperty,m=Object.getOwnPropertyDescriptor;if(h&&m){var y=m(d,"name");y&&y.configurable&&h(d,"name",{value:"[Symbol.matchAll]"})}t.exports=d},{"./helpers/RegExpStringIterator":327,"es-abstract/2020/Get":166,"es-abstract/2020/Set":181,"es-abstract/2020/SpeciesConstructor":182,"es-abstract/2020/ToLength":185,"es-abstract/2020/ToString":190,"es-abstract/2020/Type":191,"regexp.prototype.flags":314}],338:[function(e,t,n){"use strict";var r=e("define-properties"),i=e("has-symbols")(),o=e("./polyfill"),a=e("./polyfill-regexp-matchall"),s=Object.defineProperty,l=Object.getOwnPropertyDescriptor;t.exports=function(){var e=o();if(r(String.prototype,{matchAll:e},{matchAll:function(){return String.prototype.matchAll!==e}}),i){var t=Symbol.matchAll||(Symbol.for?Symbol.for("Symbol.matchAll"):Symbol("Symbol.matchAll"));if(r(Symbol,{matchAll:t},{matchAll:function(){return Symbol.matchAll!==t}}),s&&l){var n=l(Symbol,t);n&&!n.configurable||s(Symbol,t,{configurable:!1,enumerable:!1,value:t,writable:!1})}var c=a(),u={};u[t]=c;var p={};p[t]=function(){return RegExp.prototype[t]!==c},r(RegExp.prototype,u,p)}return e}},{"./polyfill":336,"./polyfill-regexp-matchall":335,"define-properties":159,"has-symbols":333}],339:[function(e,t,n){(function(r){(function(){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var i,o,a=e("./ponyfill.js"),s=(i=a)&&i.__esModule?i:{default:i};o="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==r?r:void 0!==t?t:Function("return this")();var l=(0,s.default)(o);n.default=l}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./ponyfill.js":340}],340:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=function(e){var t,n=e.Symbol;"function"==typeof n?n.observable?t=n.observable:(t=n("observable"),n.observable=t):t="@@observable";return t}},{}],341:[function(e,t,n){"use strict";var r=e("./util/cancelablepromise");t.exports=function(e,t,n,i){var o,a=new Error("Canceled");return new r((function(s,l,c){var u;e((function(e){return c()?r.reject(a):(u=t(e),n(u).then((function(e){if(c())throw a;return o=e()})))})).then((function(e){if(c())throw e.disconnect(),a;s(i(u,e))})).catch((function(e){l(e)}))}),(function(){o&&o.cancel()}))}},{"./util/cancelablepromise":464}],342:[function(e,t,n){"use strict";var r=e("./webrtc").MediaStreamTrack,i=e("./webrtc/util"),o=i.guessBrowser,a=i.guessBrowserVersion,s=i.isCodecSupported,l=e("./cancelableroompromise"),c=e("./encodingparameters"),u=e("./localparticipant"),p=e("./util/insightspublisher"),f=e("./util/insightspublisher/null"),d=e("./media/track/es5"),h=d.LocalAudioTrack,m=d.LocalDataTrack,y=d.LocalVideoTrack,b=e("./networkqualityconfiguration"),v=e("./room"),g=e("./signaling/v2"),w=e("./util"),C=w.asLocalTrack,_=w.buildLogLevels,k=w.filterObject,S=w.isNonArrayObject,E=e("./util/constants"),T=E.DEFAULT_ENVIRONMENT,O=E.DEFAULT_LOG_LEVEL,P=E.DEFAULT_LOGGER_NAME,R=E.DEFAULT_REALM,x=E.DEFAULT_REGION,D=E.WS_SERVER,j=E.SDK_NAME,M=E.SDK_VERSION,A=E.typeErrors,I=e("./util/cancelablepromise"),N=e("./util/eventobserver"),L=e("./util/log"),F=e("./util/validate").validateBandwidthProfile,U="safari"===o()&&a(),q=0,B=!1,z=!1;if(U){var V=U.major,W=U.minor;z=V<12||12===V&&W<1}var H=new Set([{didWarn:!1,shouldDelete:!0,name:"abortOnIceServersTimeout"},{didWarn:!1,shouldDelete:!0,name:"dscpTagging",newName:"enableDscp"},{didWarn:!1,shouldDelete:!0,name:"iceServersTimeout"},{didWarn:!1,shouldDelete:!1,name:"eventListener",newName:"Video.Logger"},{didWarn:!1,shouldDelete:!1,name:"logLevel",newName:"Video.Logger"}]),Y=new Set([{didWarn:!1,shouldDelete:!1,name:"maxTracks",newName:"bandwidthProfile.video.clientTrackSwitchOffControl"},{didWarn:!1,shouldDelete:!1,name:"renderDimensions",newName:"bandwidthProfile.video.contentPreferencesMode"}]);
164function X(e,t,n){n.forEach((function(n){var r=n.didWarn,i=n.name,o=n.newName,a=n.shouldDelete;i in e&&void 0!==e[i]&&(o&&a&&(e[o]=e[i]),a&&delete e[i],r||["error","off"].includes(t.level)||(t.warn('The ConnectOptions "'+i+'" is '+(o?'deprecated and scheduled for removal. Please use "'+o+'" instead.':"no longer applicable and will be ignored.")),n.didWarn=!0))}))}function G(e,t,n,r,i,o){var a=e.createLocalParticipantSignaling(n,r);return t.debug("Creating a new LocalParticipant:",a),new i.LocalParticipant(a,o,i)}function $(e,t,n){var r=new v(t,n,e),i=e.log;return i.debug("Creating a new Room:",r),n.on("stateChanged",(function e(t){"disconnected"===t&&(i.info("Disconnected from Room:",r.toString()),n.removeListener("stateChanged",e))})),r}function Q(e,t,n,r,i,o){return t.log.debug("Creating a new RoomSignaling"),n.connect(o._signaling,e,r,i,t)}function K(e,t){var n=e.log;return e.shouldStopLocalTracks=!e.tracks,e.shouldStopLocalTracks?n.info("LocalTracks were not provided, so they will be acquired automatically before connecting to the Room. LocalTracks will be released if connecting to the Room fails or if the Room is disconnected"):(n.info("Getting LocalTracks"),n.debug("Options:",e)),e.createLocalTracks(e).then((function(r){var i=t(r);return i.catch((function(){e.shouldStopLocalTracks&&(n.info("The automatically acquired LocalTracks will now be stopped"),r.forEach((function(e){e.stop()})))})),i}))}function J(e){var t="string"==typeof e?{codec:e}:e;switch(t.codec.toLowerCase()){case"opus":return Object.assign({dtx:!0},t);case"vp8":return Object.assign({simulcast:!1},t);default:return t}}t.exports=function(e,t){if(void 0===t&&(t={}),!S(t))return I.reject(A.INVALID_TYPE("options","object"));var n,i=t.Log||L,o=t.loggerName||P,a=t.logLevel||O,d=_(a),v="[connect #"+ ++q+"]";try{n=new i("default",v,d,o)}catch(ee){return I.reject(ee)}X(t,n,H);var w="auto"===t.preferredVideoCodecs;if(w&&(t.preferredVideoCodecs=[{codec:"VP8",simulcast:!0,adaptiveSimulcast:!0}]),t.maxVideoBitrate&&w)return n.error('ConnectOptions "maxVideoBitrate" is not compatible with "preferredVideoCodecs=auto"'),I.reject(A.ILLEGAL_INVOKE("connect",'ConnectOptions "maxVideoBitrate" is not compatible with "preferredVideoCodecs=auto"'));var E={};"string"==typeof(t=Object.assign({automaticSubscription:!0,dominantSpeaker:!1,enableDscp:!1,environment:T,eventListener:null,insights:!0,LocalAudioTrack:h,LocalDataTrack:m,LocalParticipant:u,LocalVideoTrack:y,Log:i,MediaStreamTrack:r,loggerName:o,logLevel:a,maxAudioBitrate:null,maxVideoBitrate:null,name:null,networkMonitor:!0,networkQuality:!1,preferredAudioCodecs:[],preferredVideoCodecs:[],realm:R,region:x,signaling:g},k(t))).wsServerInsights&&(E.gateway=t.wsServerInsights);var U=new(t.insights?p:f)(e,j,M,t.environment,t.realm,E),V=D(t.environment,t.region),W=new N(U,Date.now(),n,t.eventListener);if((t=Object.assign({eventObserver:W,wsServer:V},t)).log=n,z&&!B&&"error"!==n.logLevel&&"off"!==n.logLevel&&(B=!0,n.warn(["Support for Safari 12.0 and below is limited because it does not support VP8.","This means you may experience codec issues in Group Rooms. You may also","experience codec issues in Peer-to-Peer (P2P) Rooms containing Android- or","iOS-based Participants who do not support H.264. However, P2P Rooms","with browser-based Participants should work. For more information, please","refer to this guide: https://www.twilio.com/docs/video/javascript-v2-developing-safari-11"].join(" "))),"string"!=typeof e)return I.reject(A.INVALID_TYPE("token","string"));var Z=Object.assign({},t);if(delete Z.name,"tracks"in t){if(!Array.isArray(t.tracks))return I.reject(A.INVALID_TYPE("options.tracks","Array of LocalAudioTrack, LocalVideoTrack or MediaStreamTrack"));try{t.tracks=t.tracks.map((function(e){return C(e,Z)}))}catch(ee){return I.reject(ee)}}var ee=F(t.bandwidthProfile);if(ee)return I.reject(ee);t.clientTrackSwitchOffControl="disabled",t.contentPreferencesMode="disabled",t.bandwidthProfile&&(t.clientTrackSwitchOffControl="auto",t.contentPreferencesMode="auto",t.bandwidthProfile.video&&(X(t.bandwidthProfile.video,n,Y),"maxTracks"in t.bandwidthProfile.video?t.clientTrackSwitchOffControl="disabled":"manual"===t.bandwidthProfile.video.clientTrackSwitchOffControl?t.clientTrackSwitchOffControl="manual":t.clientTrackSwitchOffControl="auto","renderDimensions"in t.bandwidthProfile.video?t.contentPreferencesMode="disabled":"manual"===t.bandwidthProfile.video.contentPreferencesMode?t.contentPreferencesMode="manual":t.contentPreferencesMode="auto"));var te=new(0,t.signaling)(t.wsServer,t);n.info("Connecting to a Room"),n.debug("Options:",t);var ne=new c({maxAudioBitrate:t.maxAudioBitrate,maxVideoBitrate:t.maxVideoBitrate},w),re={audio:t.preferredAudioCodecs.map(J),video:t.preferredVideoCodecs.map(J)},ie=new b(S(t.networkQuality)?t.networkQuality:{});["audio","video"].forEach((function(e){return re[e].forEach((function(t){var r=t.codec;return s(r,e).then((function(t){return!t&&n.warn("The preferred "+e+' codec "'+r+'" will be ignored as it is not supported by the browser.')}))}))}));var oe=l(K.bind(null,t),G.bind(null,te,n,ne,ie,t),Q.bind(null,e,t,te,ne,re),$.bind(null,t));return oe.then((function(e){return U.connect(e.sid,e.localParticipant.sid),n.info("Connected to Room:",e.toString()),n.info("Room name:",e.name),n.debug("Room:",e),e.once("disconnected",(function(){return U.disconnect()})),e}),(function(e){U.disconnect(),oe._isCanceled?n.info("Attempt to connect to a Room was canceled"):n.info("Error while connecting to a Room:",e)})),oe}},{"./cancelableroompromise":341,"./encodingparameters":349,"./localparticipant":353,"./media/track/es5":355,"./networkqualityconfiguration":384,"./room":397,"./signaling/v2":411,"./util":472,"./util/cancelablepromise":464,"./util/constants":465,"./util/eventobserver":470,"./util/insightspublisher":473,"./ut
164il/insightspublisher/null":474,"./util/log":476,"./util/validate":490,"./webrtc":498,"./webrtc/util":510}],343:[function(e,t,n){"use strict";var r=e("./util/constants"),i=r.DEFAULT_LOG_LEVEL,o=r.DEFAULT_LOGGER_NAME;function a(e,t){t=Object.assign({loggerName:o,logLevel:i},t);var n={};n.loggerName=t.loggerName,n.logLevel=t.logLevel,delete t.loggerName,delete t.logLevel;var r=t.createLocalTracks;return delete t.createLocalTracks,n[e]=!(Object.keys(t).length>0)||t,r(n).then((function(e){return e[0]}))}t.exports={audio:function(e){return a("audio",e)},video:function(e){return a("video",e)}}},{"./util/constants":465}],344:[function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},i=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{l(r.next(e))}catch(e){o(e)}}function s(e){try{l(r.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var n,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},s=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e};Object.defineProperty(n,"__esModule",{value:!0}),n.createLocalTracks=void 0;var l=e("./media/track/noisecancellationimpl"),c=e("./util").buildLogLevels,u=e("./webrtc"),p=u.getUserMedia,f=u.MediaStreamTrack,d=e("./media/track/es5"),h=d.LocalAudioTrack,m=d.LocalDataTrack,y=d.LocalVideoTrack,b=e("./util/log"),v=e("./util/constants"),g=v.DEFAULT_LOG_LEVEL,w=v.DEFAULT_LOGGER_NAME,C=v.typeErrors.INVALID_VALUE,_=e("./webaudio/workaround180748"),k=0;n.createLocalTracks=function(e){return i(this,void 0,void 0,(function(){var t,n,u,d,v,S,E,T,O,P,R,x,D,j=this;return o(this,(function(M){switch(M.label){case 0:if(n=r({audio:t=!(e&&("audio"in e||"video"in e)),getUserMedia:p,loggerName:w,logLevel:g,LocalAudioTrack:h,LocalDataTrack:m,LocalVideoTrack:y,MediaStreamTrack:f,Log:b,video:t},e),u="[createLocalTracks #"+ ++k+"]",d=c(n.logLevel),v=new n.Log("default",u,d,n.loggerName),delete(S=Object.assign({log:v},n)).name,!1===n.audio&&!1===n.video)return v.info("Neither audio nor video requested, so returning empty LocalTracks"),[2,[]];if(n.tracks)return v.info("Adding user-provided LocalTracks"),v.debug("LocalTracks:",n.tracks),[2,n.tracks];if((E={audio:"object"==typeof n.audio&&n.audio.name?{name:n.audio.name}:{defaultDeviceCaptureMode:"auto"},video:"object"==typeof n.video&&n.video.name?{name:n.video.name}:{}}).audio.isCreatedByCreateLocalTracks=!0,E.video.isCreatedByCreateLocalTracks=!0,"object"==typeof n.audio)if("boolean"==typeof n.audio.workaroundWebKitBug1208516&&(E.audio.workaroundWebKitBug1208516=n.audio.workaroundWebKitBug1208516),"noiseCancellationOptions"in n.audio&&(T=n.audio.noiseCancellationOptions,delete n.audio.noiseCancellationOptions),"defaultDeviceCaptureMode"in n.audio){if(["auto","manual"].every((function(e){return e!==n.audio.defaultDeviceCaptureMode})))throw C("CreateLocalAudioTrackOptions.defaultDeviceCaptureMode",["auto","manual"]);E.audio.defaultDeviceCaptureMode=n.audio.defaultDeviceCaptureMode}else E.audio.defaultDeviceCaptureMode="auto";"object"==typeof n.video&&"boolean"==typeof n.video.workaroundWebKitBug1208516&&(E.video.workaroundWebKitBug1208516=n.video.workaroundWebKitBug1208516),"object"==typeof n.audio&&delete n.audio.name,"object"==typeof n.video&&delete n.video.name,O={audio:n.audio,video:n.video},P="object"==typeof n.audio&&n.audio.workaroundWebKitBug180748,M.label=1;case 1:return M.trys.push([1,4,,5]),[4,P?_(v,n.getUserMedia,O):n.getUserMedia(O)];case 2:return R=M.sent(),x=s(s([],a(R.getAudioTracks())),a(R.getVideoTracks())),v.info("Call to getUserMedia successful; got tracks:",x),[4,Promise.all(x.map((function(e){return i(j,void 0,void 0,(function(){var t,n,i;return o(this,(function(o){switch(o.label){case 0:return"audio"===e.kind&&T?[4,l.applyNoiseCancellation(e,T,v)]:[3,2];case 1:return t=o.sent(),n=t.cleanTrack,i=t.noiseCancellation,[2,new S.LocalAudioTrack(n,r(r(r({},E.audio),S),{noiseCancellation:i}))];case 2:if("audio"===e.kind)return[2,new S.LocalAudioTrack(e,r(r({},E.audio),S))];o.label=3;case 3:return[2,new S.LocalVideoTrack(e,r(r({},E.video),S))]}}))}))})))];case 3:return[2,M.sent()];case 4:throw D=M.sent(),v.warn("Call to getUserMedia failed:",D),D;case 5:return[2]}}
164))}))}},{"./media/track/es5":355,"./media/track/noisecancellationimpl":369,"./util":472,"./util/constants":465,"./util/log":476,"./webaudio/workaround180748":495,"./webrtc":498}],345:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./transceiver"),a=e("./transport"),s=function(e){function t(t){var n=e.call(this,t.label,t.maxPacketLifeTime,t.maxRetransmits,t.ordered)||this;return Object.defineProperties(n,{_dataChannel:{value:t}}),t.binaryType="arraybuffer",t.addEventListener("message",(function(e){n.emit("message",e.data)})),t.addEventListener("close",(function(){n.emit("close")})),n}return i(t,e),t.prototype.stop=function(){this._dataChannel.close(),e.prototype.stop.call(this)},t.prototype.toDataTransport=function(){return new a(this._dataChannel)},t}(o);t.exports=s},{"./transceiver":347,"./transport":348}],346:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./transceiver"),a=e("../util").makeUUID,s=function(e){function t(t,n,r){var i=e.call(this,a(),t,n,r)||this;return Object.defineProperties(i,{_clones:{value:new Set},_dataChannels:{value:new Set}}),i}return i(t,e),t.prototype._addClone=function(e){this._clones.add(e)},t.prototype.removeClone=function(e){this._clones.delete(e)},t.prototype.addDataChannel=function(e){return this._dataChannels.add(e),this},t.prototype.clone=function(){var e=this,n=new t(this.maxPacketLifeTime,this.maxRetransmits,this.ordered);return this._addClone(n),n.once("stopped",(function(){return e.removeClone(n)})),n},t.prototype.removeDataChannel=function(e){return this._dataChannels.delete(e),this},t.prototype.send=function(e){return this._dataChannels.forEach((function(t){try{t.send(e)}catch(e){}})),this._clones.forEach((function(t){try{t.send(e)}catch(e){}})),this},t.prototype.stop=function(){this._dataChannels.forEach((function(e){return e.close()})),this._clones.forEach((function(e){return e.stop()})),e.prototype.stop.call(this)},t}(o);t.exports=s},{"../util":472,"./transceiver":347}],347:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r,i){var o=e.call(this,t,"data")||this;return Object.defineProperties(o,{maxPacketLifeTime:{enumerable:!0,value:n},maxRetransmits:{enumerable:!0,value:r},ordered:{enumerable:!0,value:i}}),o}return i(t,e),t}(e("../transceiver"));t.exports=o},{"../transceiver":459}],348:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t){var n=e.call(this)||this;return Object.defineProperties(n,{_dataChannel:{value:t},_messageQueue:{value:[]}}),t.addEventListener("open",(function(){n._messageQueue.splice(0).forEac
164h((function(e){return n._publish(e)}))})),t.addEventListener("message",(function(e){var t=e.data;try{var r=JSON.parse(t);n.emit("message",r)}catch(e){}})),n.publish({type:"ready"}),n}return i(t,e),t.prototype._publish=function(e){var t=JSON.stringify(e);try{this._dataChannel.send(t)}catch(e){}},t.prototype.publish=function(e){var t=this._dataChannel;return"closing"!==t.readyState&&"closed"!==t.readyState&&("connecting"===t.readyState?(this._messageQueue.push(e),!0):(this._publish(e),!0))},t}(e("events").EventEmitter);t.exports=o},{events:222}],349:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this)||this;return t=Object.assign({maxAudioBitrate:null,maxVideoBitrate:null},t),Object.defineProperties(r,{maxAudioBitrate:{value:t.maxAudioBitrate,writable:!0},maxVideoBitrate:{value:t.maxVideoBitrate,writable:!0},adaptiveSimulcast:{value:n}}),r}return i(t,e),t.prototype.toJSON=function(){return{maxAudioBitrate:this.maxAudioBitrate,maxVideoBitrate:this.maxVideoBitrate}},t.prototype.update=function(e){var t=this;e=Object.assign({maxAudioBitrate:this.maxAudioBitrate,maxVideoBitrate:this.maxVideoBitrate},e),["maxAudioBitrate","maxVideoBitrate"].reduce((function(n,r){return t[r]!==e[r]&&(t[r]=e[r],n=!0),n}),!1)&&this.emit("changed")},t}(e("events").EventEmitter);t.exports=o},{events:222}],350:[function(e,t,n){"use strict";var r=e("events").EventEmitter,i=e("./util").hidePrivateAndCertainPublicPropertiesInClass;t.exports=i(r,["domain"])},{"./util":472,events:222}],351:[function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},o=e("events").EventEmitter,a=function(){function e(){Object.defineProperties(this,{_eventEmitter:{value:new o}})}return e.prototype.dispatchEvent=function(e){return this._eventEmitter.emit(e.type,e)},e.prototype.addEventListener=function(){var e;return(e=this._eventEmitter).addListener.apply(e,i([],r(arguments)))},e.prototype.removeEventListener=function(){var e;return(e=this._eventEmitter).removeListener.apply(e,i([],r(arguments)))},e}();t.exports=a},{events:222}],352:[function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};Object.defineProperty(n,"__esModule",{value:!0});var i=e("./createlocaltracks"),o=e("./preflight/preflighttest"),a={connect:e("./connect"),createLocalAudioTrack:e("./createlocaltrack").audio,createLocalVideoTrack:e("./createlocaltrack").video,isSupported:e("./util/support")(),version:e("../package.json").version,Logger:e("./vendor/loglevel"),LocalAudioTrack:e("./media/track/es5").LocalAudioTrack,LocalDataTrack:e("./media/track/es5").LocalDataTrack,LocalVideoTrack:e("./media/track/es5").LocalVideoTrack};var s=a.isSupported,l=a.version,c=a.Logger,u=a.LocalAudioTrack,p=a.LocalVideoTrack,f=a.LocalDataTrack;t.exports={connect:function(e,t){var n=r({createLocalTracks:i.createLocalTracks},t);return a.connect(e,n)},createLocalAudioTrack:function(e){var t=r({createLocalTracks:i.createLocalTracks},e);return a.createLocalAudioTrack(t)},createLocalVideoTrack:function(e){var t=r({createLocalTracks:i.createLocalTracks},e);return a.createLocalVideoTrack(t)},createLocalTracks:i.createLocalTracks,runPreflight:o.runPreflight,isSupported:s,version:l,Logger:c,LocalAudioTrack:u,LocalVideoTrack:p,LocalDataTrack:f}},{"../package.json":513,"./connect":342,"./createlocaltrack":343,"./createlocaltracks":344,"./media/track/es5":355,"./preflight/preflighttest":391,"./util/support":485,"./vendor/loglevel":492}],353:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./webrtc").MediaStreamTrack,a=e("./util"),s=a.asLocalTrack,l=a.asLocalTrackPublication,c=a.trackClass,u=e("./util/constants"),p=u.typeErrors,f=u.trackPriority,d=e("./util/validate").validateLocalTrack,h=e("./media/track/es5"),m=h.LocalAudioTrack,y=h.LocalDataTrack,b=h.LocalVideoTrack,v=e("./media/track/localaudiotrackpublication"),g=e("./media/track/localdatatrackpublication"),w=e("./media/track/localvideotrackpublication"),C=function(e){function t(t,n,r){var i=this,a=(r=Object.assign({LocalAudioTrack:m,LocalVideoTrack:b,LocalDataTrack:y,MediaStreamTrack:o,LocalAudioTrackPublication:v,LocalVideoTrackPublication:w,LocalDataTrackPublication:g,shouldStopLocalTracks:!1,tracks:n},r)).shouldStopLocalTracks?new Set(n.filter((function(e){return"data"!==e.kind}))):new Set;return i=e.call(this,t,r)||this,Object.defineProperties(i,{_eventObserver:{value:r.eventObserver},_LocalAudioTrack:{value:r.LocalAudioTrack},_LocalDataTrack:{value:r.LocalDataTrack},_LocalVideoTrack:{value:r.LocalVideoTrack},_MediaStreamTrack:{value:r.MediaStreamTrack},_LocalAudioTrackPublication:{value:r.LocalAudioTrackPublication},_LocalDataTrackPublication:{value:r.LocalDataTrackPublication},_LocalVideoTrackPublication:{value:r.LocalVideoTrackPublication},_tracksToStop:{value:a},signalingRegion:{enumerable:!0,get:function(){return t.signalingRegion}}}),i._handleTrackSignalingEvents(),i}return i(t,e),t.prototype._addTrack=function(t,n,r){var i=e.prototype._addTrack.call(this,t,n);return i&&"disconnected"!==this.state&&this._addLocalTrack(t,r),i},t.prototype._addLocalTrack=function(e,t){var n,r=null===(n=e.noiseCancellation)||void 0===n?void 0:n.vendor;this._signaling.addTrack(e._trackSender,e.name,t,r),this._log.info("Added a new "+c(e,!0)+":",e.id),this._log.debug(c(e,!0)+":",e)},t.prototype._removeTrack=function(t,n){var r=e.prototype._removeTrack.call(this,t,n);return r&&"disconnected"!==this.state&&(this._signaling.removeTrack(t._trackSender),this._log.info("Removed a "+c(t,!0)+":",t.id),this._log.debug(c(t,!0)+":",t)),r},t.prototype._getTrackEvents=function(){return e.prototype._getTrackEvents.call(this).concat([["disabled","trackDisabled"],["enabled","trackEnabled"],["stopped","trackStopped"]])},t.prototype.toString=function(){return"[LocalParticipant #"+this._instanceId+(this.sid?": "+this.sid:"")+"]"},t.prototype._handleTrackSignalingEvents=function(){var e=this,t=this._log;if("disconnected"!==this.state){var n=function(n){var r=e._signaling.getPublication(n._trackSender);r&&(r.disable(),t.debug("Disabled the "+c(n,!0)+":",n.id))},r=function(n){var r=e._signaling.getPublication(n._trackSender);r&&(r.enable(),t.debug("Enabled the "+c(n,!0)+":",n.id))},i=function(t){var n=e._signaling.getPublication(t._trackSender);return n&&n.stop(),n},o=function(a){t.debug("Transitioned to state:",a),"disconnected"===a?(t.debug("Removing LocalTrack event listeners"),e._signaling.removeListener("stateChanged",o),e.removeListener("trackDisabled",n),e.removeListener("trackEnabled",r),e.removeListener("trackStopped",i),e._tracks.forEach((function(e){var t=i(e);t&&e._trackSender.removeClone(t._trackTransceiver)})),t.info("LocalParticipant disconnected. Stopping "+e._tracksToStop.size+" automatically-acquired LocalTracks"),e._tracksToStop.forEac
164h((function(e){e.stop()}))):"connected"===a&&(t.info("reconnected"),setTimeout((function(){return e.emit("reconnected")}),0))};this.on("trackDisabled",n),this.on("trackEnabled",r),this.on("trackStopped",i),this._signaling.on("stateChanged",o),this._tracks.forEach((function(n){e._addLocalTrack(n,f.PRIORITY_STANDARD),e._getOrCreateLocalTrackPublication(n).catch((function(e){t.warn("Failed to get or create LocalTrackPublication for "+n+":",e)}))}))}},t.prototype._getOrCreateLocalTrackPublication=function(e){var t=_(this.tracks,e);if(t)return Promise.resolve(t);var n=this._log,r=this,i=this._signaling.getPublication(e._trackSender);return i?new Promise((function(o,a){i.on("updated",(function s(){var u=i.error;if(u)return i.removeListener("updated",s),n.warn("Failed to publish the "+c(e,!0)+": "+u.message),r._removeTrack(e,e.id),setTimeout((function(){r.emit("trackPublicationFailed",u,e)})),void a(u);if(!r._tracks.has(e.id))return i.removeListener("updated",s),void a(new Error("The "+e+" was unpublished"));if(i.sid){i.removeListener("updated",s);var p={log:n,LocalAudioTrackPublication:r._LocalAudioTrackPublication,LocalDataTrackPublication:r._LocalDataTrackPublication,LocalVideoTrackPublication:r._LocalVideoTrackPublication};t=_(r.tracks,e);var f=function(e){return r.emit("trackWarning",e,t)},d=function(){return r.emit("trackWarningsCleared",t)};t||(t=l(e,i,(function(e){t.removeListener("trackWarning",f),t.removeListener("trackWarningsCleared",d),r.unpublishTrack(e.track)}),p),r._addTrackPublication(t)),t.on("warning",f),t.on("warningsCleared",d);var h=r._signaling.state;"connected"!==h&&"connecting"!==h||(e._processorEventObserver&&e._processorEventObserver.on("event",(function(e){r._eventObserver.emit("event",{name:e.name,payload:e.data,group:"video-processor",level:"info"})})),e.processedTrack&&(e._captureFrames(),e._setSenderMediaStreamTrack(!0))),"connected"===h&&setTimeout((function(){r.emit("trackPublished",t)})),o(t)}}))})):Promise.reject(new Error("Unexpected error: The "+e+" cannot be published"))},t.prototype.publishTrack=function(e,t){var n,r=_(this.tracks,e);if(r)return Promise.resolve(r);t=Object.assign({log:this._log,priority:f.PRIORITY_STANDARD,LocalAudioTrack:this._LocalAudioTrack,LocalDataTrack:this._LocalDataTrack,LocalVideoTrack:this._LocalVideoTrack,MediaStreamTrack:this._MediaStreamTrack},t);try{n=s(e,t)}catch(e){return Promise.reject(e)}var i=n.noiseCancellation,o=this._signaling.audioProcessors;i&&!o.includes(i.vendor)&&(this._log.warn(i.vendor+" is not supported in this room. disabling it permanently"),i.disablePermanently());var a=Object.values(f);if(!a.includes(t.priority))return Promise.reject(p.INVALID_VALUE("LocalTrackPublishOptions.priority",a));var l=this._addTrack(n,n.id,t.priority)||this._tracks.get(n.id);return this._getOrCreateLocalTrackPublication(l)},t.prototype.publishTracks=function(e){if(!Array.isArray(e))throw p.INVALID_TYPE("tracks","Array of LocalAudioTrack, LocalVideoTrack, LocalDataTrack, or MediaStreamTrack");return Promise.all(e.map(this.publishTrack,this))},t.prototype.setBandwidthProfile=function(){this._log.warn("setBandwidthProfile is not implemented yet and may be available in future versions of twilio-video.js")},t.prototype.setNetworkQualityConfiguration=function(e){if("object"!=typeof e||null===e)throw p.INVALID_TYPE("networkQualityConfiguration","NetworkQualityConfiguration");return["local","remote"].forEach((function(t){if(t in e&&("number"!=typeof e[t]||isNaN(e[t])))throw p.INVALID_TYPE("networkQualityConfiguration."+t,"number")})),this._signaling.setNetworkQualityConfiguration(e),this},t.prototype.setParameters=function(e){if(void 0!==e&&"object"!=typeof e)throw p.INVALID_TYPE("encodingParameters","EncodingParameters, null or undefined");if(e){if(this._signaling.getParameters().adaptiveSimulcast&&e.maxVideoBitrate)throw p.INVALID_TYPE("encodingParameters",'encodingParameters.maxVideoBitrate is not compatible with "preferredVideoCodecs=auto"');["maxAudioBitrate","maxVideoBitrate"].forEach((function(t){if(void 0!==e[t]&&"number"!=typeof e[t]&&null!==e[t])throw p.INVALID_TYPE("encodingParameters."+t,"number, null or undefined")}))}else null===e&&(e={maxAudioBitrate:null,maxVideoBitrate:null});return this._signaling.setParameters(e),this},t.prototype.unpublishTrack=function(e){d(e,{LocalAudioTrack:this._LocalAudioTrack,LocalDataTrack:this._LocalDataTrack,LocalVideoTrack:this._LocalVideoTrack,MediaStreamTrack:this._MediaStreamTrack});var t=this._tracks.get(e.id);if(!t)return null;if(this._signaling.getPublication(t._trackSender).publishFailed(new Error("The "+t+" was unpublished")),!(t=this._removeTrack(t,t.id)))return null;var n=_(this.tracks,t);return n&&this._removeTrackPublication(n),n},t.prototype.unpublishTracks=function(e){var t=this;if(!Array.isArray(e))throw p.INVALID_TYPE("tracks","Array of LocalAudioTrack, LocalVideoTrack, LocalDataTrack, or MediaStreamTrack");return e.reduce((function(e,n){var r=t.unpublishTrack(n);return r?e.concat(r):e}),[])},t}(e("./participant"));function _(e,t){return Array.from(e.values()).find((function(e){return e.track===t||e.track.mediaStreamTrack===t}))||null}t.exports=C},{"./media/track/es5":355,"./media/track/localaudiotrackpublication":361,"./media/track/localdatatrackpublication":363,"./media/track/localvideotrackpublication":367,"./participant":386,"./util":472,"./util/constants":465,"./util/validate":490,"./webrtc":498}],354:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){return e.call(this,t,n)||this}return i(t,e),t.prototype.attach=function(){return e.prototype.attach.apply(this,arguments)},t.prototype.detach=function(){return e.prototype.detach.apply(this,arguments)},t}(e("./mediatrack"));t.exports=o},{"./mediatrack":368}],355:[function(e,t,n){"use strict";
164t.exports={LocalAudioTrack:e("./localaudiotrack"),LocalVideoTrack:e("./localvideotrack"),LocalDataTrack:e("./localdatatrack")}},{"./localaudiotrack":356,"./localdatatrack":357,"./localvideotrack":358}],356:[function(e,t,n){"use strict";var r=e("../../../vendor/inherits"),i=e("../localaudiotrack");function o(e,t){var n=new i(e,t);return Object.setPrototypeOf(n,o.prototype),n}r(o,i),t.exports=o},{"../../../vendor/inherits":491,"../localaudiotrack":360}],357:[function(e,t,n){"use strict";var r=e("../../../vendor/inherits"),i=e("../localdatatrack");function o(e){var t=new i(e);return Object.setPrototypeOf(t,o.prototype),t}r(o,i),t.exports=o},{"../../../vendor/inherits":491,"../localdatatrack":362}],358:[function(e,t,n){"use strict";var r=e("../../../vendor/inherits"),i=e("../localvideotrack");function o(e,t){var n=new i(e,t);return Object.setPrototypeOf(n,o.prototype),n}r(o,i),t.exports=o},{"../../../vendor/inherits":491,"../localvideotrack":366}],359:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../../eventemitter"),a=e("../../util"),s=a.buildLogLevels,l=a.valueToJSON,c=e("../../util/constants").DEFAULT_LOG_LEVEL,u=e("../../util/log"),p=0,f=function(e){function t(t,n,r){var i;r=Object.assign({name:t,log:null,logLevel:c},r),i=e.call(this)||this;var o=String(r.name),a=s(r.logLevel),l=r.log?r.log.createLog("media",i):new u("media",i,a,r.loggerName);return Object.defineProperties(i,{_instanceId:{value:++p},_log:{value:l},kind:{enumerable:!0,value:n},name:{enumerable:!0,value:o}}),i}return i(t,e),t.prototype.toJSON=function(){return l(this)},t}(o);t.exports=f},{"../../eventemitter":350,"../../util":472,"../../util/constants":465,"../../util/log":476}],360:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../../util/browserdetection").isIOS,a=e("./audiotrack"),s=function(e){function t(t,n){var r=this,i=(null==n?void 0:n.noiseCancellation)||null,a=(r=e.call(this,t,n)||this)._log,s=t.label,l=void 0===s?"":s,c=t.getSettings(),u=c.deviceId,p=void 0===u?"":u,f=c.groupId,d=void 0===f?"":f;return Object.defineProperties(r,{_currentDefaultDeviceInfo:{value:{deviceId:p,groupId:d,label:l},writable:!0},_defaultDeviceCaptureMode:{value:!o()&&r._isCreatedByCreateLocalTracks&&"object"==typeof navigator&&"object"==typeof navigator.mediaDevices&&"function"==typeof navigator.mediaDevices.addEventListener&&"function"==typeof navigator.mediaDevices.enumerateDevices?(null==n?void 0:n.defaultDeviceCaptureMode)||"auto":"manual"},_onDeviceChange:{value:function(){navigator.mediaDevices.enumerateDevices().then((function(e){var t=e.find((function(e){var t=e.deviceId;return"audioinput"===e.kind&&"default"!==t}));t&&["deviceId","groupId"].some((function(e){return t[e]!==r._currentDefaultDeviceInfo[e]}))&&(a.info("Default device changed, restarting the LocalAudioTrack"),a.debug('Old default device: "'+r._currentDefaultDeviceInfo.deviceId+'" => "'+r._currentDefaultDeviceInfo.label+'"'),a.debug('New default device: "'+t.deviceId+'" => "'+t.label+'"'),r._currentDefaultDeviceInfo=t,r._restartDefaultDevice().catch((function(e){return a.warn("Failed to restart: "+e.message)})))}),(function(e){a.warn("Failed to run enumerateDevices(): "+e.message)}))}},_restartOnDefaultDeviceChangeCleanup:{value:null,writable:!0},noiseCancellation:{enumerable:!0,value:i,writable:!1}}),a.debug("defaultDeviceCaptureMode:",r._defaultDeviceCaptureMode),r._maybeRestartOnDefaultDeviceChange(),r}return i(t,e),t.prototype.toString=function(){return"[LocalAudioTrack #"+this._instanceId+": "+this.id+"]"},t.prototype.attach=function(t){return(t=e.prototype.attach.call(this,t)).muted=!0,t},t.prototype._end=function(){return e.prototype._end.apply(this,arguments)},t.prototype._maybeRestartOnDefaultDeviceChange=function(){var e=this,t=this._constraints,n=this._defaultDeviceCaptureMode,r=this._log,i=(this.noiseCancellation?this.noiseCancellation.sourceTrack:this.mediaStreamTrack).getSettings().deviceId,o=function(e){return e!==i||"default"===e},a=function e(t){return void 0===t&&(t={}),"string"==typeof t?o(t):Array.isArray(t)?t.every(o):t.exact?e(t.exact):!t.ideal||e(t.ideal)}(t.deviceId);"auto"===n&&a?this._restartOnDefaultDeviceChangeCleanup||(r.info("LocalAudioTrack will be restarted if the default device changes"),navigator.mediaDevices.addEventListener("devicechange",this._onDeviceChange),this._restartOnDefaultDeviceChangeCleanup=function(){r.info("Cleaning up the listener to restart the LocalAudioTrack if the default device changes"),navigator.mediaDevices.removeEventListener("devicechange",e._onDeviceChange),e._restartOnDefaultDeviceChangeCleanup=null}):(r.info("LocalAudioTrack will NOT be restarted if the default device changes"),this._restartOnDefaultDeviceChangeCleanup&&this._restartOnDefaultDeviceChangeCleanup())},t.prototype._reacquireTrack=function(t){var n=this;return this._log.debug("_reacquireTrack: ",t),this.noiseCancellation?this.noiseCancellation.reacquireTrack((function(){return e.prototype._reacquireTrack.call(n,t)})):e.prototype._reacquireTrack.call(this,t)},t.prototype._restartDefaultDevice=function(){var e=this,t=Object.assign({},this._constraints),n=Object.assign({},t,{deviceId:this._currentDefaultDeviceInfo.deviceId});return this.restart(n).then((function(){e._constraints=t,e._maybeRestartOnDefaultDeviceChange()}))},t.prototype.disable=function(){return e.prototype.disable.apply(this,arguments)},t.prototype.enable=function(){return e.prototype.enable.apply(this,arguments)},t.prototype.restart=function(){return e.prototype.restart.apply(this,arguments)},t.prototype.stop=function(){return this.noiseCancellation&&this.noiseCancellation.stop(),this._restartOnDefaultDeviceChangeCleanup&&this._restartOnDefaultDeviceChangeCleanup(),e.prototype.stop.apply(this,arguments)},t}(e("./localmediatrack")(a));t.exports=s},{"../../util/browserdetection":463,"./audiotrack":354,"./localmediatrack":364}],361:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r,i){return e.call(this,t,n,r,i)||this}return i(t,e),t.prototype.toString=function(){return"[LocalAudioTrackPublication #"+this._instanceId+": "+this.trackSid+"]"},t}(e("./localtrackpublication"));t.exports=o},{"./localtrackpublication":365}],362:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./"),a=e("../../data/sender"),s=function(e){function t(t){var n,r=new(0,(t=Object.assign({DataTrackSender:a,maxPacketLifeTime:null,maxRetransmits:null,ordered:!0}
164,t)).DataTrackSender)(t.maxPacketLifeTime,t.maxRetransmits,t.ordered);return n=e.call(this,r.id,"data",t)||this,Object.defineProperties(n,{_trackSender:{value:r},id:{enumerable:!0,value:r.id},maxPacketLifeTime:{enumerable:!0,value:t.maxPacketLifeTime},maxRetransmits:{enumerable:!0,value:t.maxRetransmits},ordered:{enumerable:!0,value:t.ordered},reliable:{enumerable:!0,value:null===t.maxPacketLifeTime&&null===t.maxRetransmits}}),n}return i(t,e),t.prototype.send=function(e){this._trackSender.send(e)},t}(o);t.exports=s},{"../../data/sender":346,"./":359}],363:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r,i){return e.call(this,t,n,r,i)||this}return i(t,e),t.prototype.toString=function(){return"[LocalDataTrackPublication #"+this._instanceId+": "+this.trackSid+"]"},t}(e("./localtrackpublication"));t.exports=o},{"./localtrackpublication":365}],364:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../../webrtc").getUserMedia,a=e("../../util/browserdetection").isIOS,s=e("../../util"),l=s.capitalize,c=s.defer,u=s.isUserMediaTrack,p=s.waitForSometime,f=s.waitForEvent,d=e("../../util/constants").typeErrors.ILLEGAL_INVOKE,h=e("../../util/detectsilentaudio"),m=e("../../util/detectsilentvideo"),y=e("../../util/documentvisibilitymonitor.js"),b=e("../../util/localmediarestartdeferreds"),v=e("../../webaudio/workaround180748"),g=e("./sender");function w(e){var t=e._log,n=e.kind,r={audio:h,video:m}[n],i=e._dummyEl,o=e.mediaStreamTrack,a=null;function s(){var n=e._workaroundWebKitBug1208516Cleanup,o=e.isStopped,s=e.mediaStreamTrack.muted,l=o&&!!n;return Promise.resolve().then((function(){return"visible"===document.visibilityState&&!a&&(s||l||i.play().then((function(){return r(i)})).then((function(e){return e?t.warn("Silence detected"):t.info("Non-silence detected"),e})).catch((function(e){t.warn("Failed to detect silence:",e)})).finally((function(){e.processedTrack||i.pause()})))}))}function l(){return Promise.race([f(o,"unmute"),p(50)]).then((function(){return s()})).then((function(r){return r&&!a&&(a=c(),e._restart().finally((function(){i=e._dummyEl,v(),o=e.mediaStreamTrack,d(),a.resolve(),a=null})).catch((function(e){t.error("failed to restart track: ",e)}))),(a&&a.promise||Promise.resolve()).finally((function(){return b.resolveDeferred(n)}))})).catch((function(e){t.error("error in maybeRestart: "+e.message)}))}function u(){var t=e._log,n=e.kind;t.info("Muted"),t.debug("LocalMediaTrack:",e),b.startDeferred(n)}function d(){o.addEventListener("ended",l),o.addEventListener("mute",u),o.addEventListener("unmute",l)}function v(){o.removeEventListener("ended",l),o.removeEventListener("mute",u),o.removeEventListener("unmute",l)}var g=function(e){return!!e&&l()};return y.onVisibilityChange(1,g),d(),function(){y.offVisibilityChange(1,g),v()}}t.exports=function(e){return function(e){function t(t,n){var r=this,i=a()&&u(t)&&"object"==typeof document&&"function"==typeof document.addEventListener&&"string"==typeof document.visibilityState;n=Object.assign({getUserMedia:o,isCreatedByCreateLocalTracks:!1,workaroundWebKitBug1208516:i,gUMSilentTrackWorkaround:v},n);var s=new g(t),l=s.kind;return r=e.call(this,s,n)||this,Object.defineProperties(r,{_constraints:{value:"object"==typeof n[l]?n[l]:{},writable:!0},_getUserMedia:{value:n.getUserMedia}
164,_gUMSilentTrackWorkaround:{value:n.gUMSilentTrackWorkaround},_eventsToReemitters:{value:new Map([["muted",function(){return r.emit("muted",r)}],["unmuted",function(){return r.emit("unmuted",r)}]])},_workaroundWebKitBug1208516:{value:n.workaroundWebKitBug1208516},_workaroundWebKitBug1208516Cleanup:{value:null,writable:!0},_didCallEnd:{value:!1,writable:!0},_isCreatedByCreateLocalTracks:{value:n.isCreatedByCreateLocalTracks},_trackSender:{value:s},id:{enumerable:!0,value:s.id},isEnabled:{enumerable:!0,get:function(){return s.enabled}},isMuted:{enumerable:!0,get:function(){return s.muted}},isStopped:{enumerable:!0,get:function(){return"ended"===s.readyState}}}),r._workaroundWebKitBug1208516&&(r._workaroundWebKitBug1208516Cleanup=w(r)),r._reemitTrackSenderEvents(),r}return i(t,e),t.prototype._end=function(){var t=this;this._didCallEnd||(e.prototype._end.call(this),this._didCallEnd=!0,this._eventsToReemitters.forEach((function(e,n){return t._trackSender.removeListener(n,e)})),this.emit("stopped",this))},t.prototype._initialize=function(){this._didCallEnd&&(this._didCallEnd=!1),this._eventsToReemitters&&this._reemitTrackSenderEvents(),e.prototype._initialize.call(this)},t.prototype._reacquireTrack=function(e){var t,n=this._getUserMedia,r=this._gUMSilentTrackWorkaround,i=this._log,o=this.mediaStreamTrack.kind;i.info("Re-acquiring the MediaStreamTrack"),i.debug("Constraints:",e);var a=Object.assign({audio:!1,video:!1},((t={})[o]=e,t));return(this._workaroundWebKitBug1208516Cleanup?r(i,n,a):n(a)).then((function(e){return e.getTracks()[0]}))},t.prototype._reemitTrackSenderEvents=function(){var e=this;this._eventsToReemitters.forEach((function(t,n){return e._trackSender.on(n,t)})),this._trackSender.dequeue("muted"),this._trackSender.dequeue("unmuted")},t.prototype._restart=function(e){var t=this,n=this._log;return e=e||this._constraints,this._stop(),this._reacquireTrack(e).catch((function(t){throw n.error("Failed to re-acquire the MediaStreamTrack:",{error:t,constraints:e}),t})).then((function(r){return n.info("Re-acquired the MediaStreamTrack"),n.debug("MediaStreamTrack:",r),t._constraints=Object.assign({},e),t._setMediaStreamTrack(r)}))},t.prototype._setMediaStreamTrack=function(e){var t=this;return e.enabled=this.mediaStreamTrack.enabled,this._stop(),(this._unprocessedTrack?Promise.resolve().then((function(){t._unprocessedTrack=e})):this._trackSender.setMediaStreamTrack(e).catch((function(n){t._log.warn("setMediaStreamTrack failed:",{error:n,mediaStreamTrack:e})}))).then((function(){t._initialize(),t._getAllAttachedElements().forEach((function(e){return t._attach(e)}))}))},t.prototype._stop=function(){return this.mediaStreamTrack.stop(),this._end(),this},t.prototype.enable=function(e){return(e="boolean"!=typeof e||e)!==this.mediaStreamTrack.enabled&&(this._log.info((e?"En":"Dis")+"abling"),this.mediaStreamTrack.enabled=e,this.emit(e?"enabled":"disabled",this)),this},t.prototype.disable=function(){return this.enable(!1)},t.prototype.restart=function(e){var t=this,n=this.kind;if(!this._isCreatedByCreateLocalTracks)return Promise.reject(d("restart","can only be called on a Local"+l(n)+"Track that is created using createLocalTracks or createLocal"+l(n)+"Track."));this._workaroundWebKitBug1208516Cleanup&&(this._workaroundWebKitBug1208516Cleanup(),this._workaroundWebKitBug1208516Cleanup=null);var r=this._restart(e);return this._workaroundWebKitBug1208516&&(r=r.finally((function(){t._workaroundWebKitBug1208516Cleanup=w(t)}))),r},t.prototype.stop=function(){return this._log.info("Stopping"),this._workaroundWebKitBug1208516Cleanup&&(this._workaroundWebKitBug1208516Cleanup(),this._workaroundWebKitBug1208516Cleanup=null),this._stop()},t}(e)}},{"../../util":472,"../../util/browserdetection":463,"../../util/constants":465,"../../util/detectsilentaudio":466,"../../util/detectsilentvideo":467,"../../util/documentvisibilitymonitor.js":468,"../../util/localmediarestartdeferreds":475,"../../webaudio/workaround180748":495,"../../webrtc":498,"./sender":379}],365:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("./trackpublication"),l=e("../../util/constants"),c=l.typeErrors,u=l.trackPriority,p=function(e){function t(t,n,r,i){var s=e.call(this,n.name,t.sid,i)||this;return Object.defineProperties(s,{_reemitSignalingEvent:{value:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return s.emit.apply(s,a([e&&e.length?"warning":"warningsCleared"],o(e)))}},_reemitTrackEvent:{value:function(){return s.emit(s.isTrackEnabled?"trackEnabled":"trackDisabled")}},_signaling:{value:t},_unpublish:{value:r},isTrackEnabled:{enumerable:!0,get:function(){return"data"===this.track.kind||this.track.isEnabled}},kind:{enumerable:!0,value:n.kind},priority:{enumerable:!0,get:function(){return t.updatedPriority}},track:{enumerable:!0,value:n}}),["disabled","enabled"].forEach((function(e){return n.on(e,s._reemitTrackEvent)})),["warning","warningsCleared"].forEach((function(e){return t.on(e,s._reemitSignalingEvent)})),s}return i(t,e),t.prototype.toString=function(){return"[LocalTrackPublication #"+this._instanceId+": "+this.trackSid+"]"},t.prototype.setPriority=function(e){var t=Object.values(u);if(!t.includes(e))throw c.INVALID_VALUE("priority",t);return this._signaling.setPriority(e),this},t.prototype.unpublish=function(){var e=this;return["disabled","enabled"].forEach((function(t){return e.track.removeListener(t,e._reemitTrackEvent)})),["warning","warningsCleared"].forEach((function(t){return e._signaling.removeListener(t,e._reemitSignalingEvent)})),this._unpublish(this),this},t}(s);t.exports=p},{"../../util/constants":465,"./trackpublication":380}],366:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../../util/browserdetection").isIOS,a=e("../../util/detectsilentvideo"),s=e("./localmediatrack"),l=e("./videotrack"),c=e("../../util").isUserMediaTrack,u=function(e){function t(t,n){var r=this;return n=Object.assign({workaroundSilentLocalVideo:o()&&c(t)&&"undefined"!=typeof document&&"function"==typeof document.createElement},n),r=e.call(this,t,n)||this,Object.defineProperties(r,{_workaroundSilentLocalVideo:{value:n.workaroundSilentLocalVideo?p:null},_workaroundSilentLocalVideoCleanup:{value:null,writable:!0}}),r._workaroundSilentLocalVideo&&(r._workaroundSilentLocalVideoCleanup=r._workaroundSilentLocalVideo(r,document)),r}return i(t,e),t.prototype.toString=function(){return"[LocalVideoTrack #"+this._instanceId+": "+this.id+"]"},t.prototype._checkIfCanCaptureFrames=function(){return e.prototype._checkIfCanCaptureFrames.call(this,this._trackSender.isPublishing)},t.prototype._end=function(){return e.prototype._end.apply(this,arguments)},t.prototype._setSenderMediaStreamTrack=function(e){var t=this,n=this.mediaStreamTrack,r=e?this.processedTrack:n;return this._trackSender.setMediaStreamTrack(r).catch((function(e){return t._log.warn("setMediaStreamTrack failed on LocalVideoTrack RTCRtpSender",{error:e,mediaStreamTrack:r})})).then((function(){t._unprocessedTrack=e?n:null}))},t.prototype.addProcessor=function(){this._log.debug("Adding VideoProcessor to the LocalVideoTrack");var t=e.prototype.addProcessor.apply(this,arguments);return this.processedTrack?(this._log.debug("Updating LocalVideoTrack's MediaStreamTrack 
164with the processed MediaStreamTrack",this.processedTrack),this._setSenderMediaStreamTrack(!0),t):this._log.warn("Unable to add a VideoProcessor to the LocalVideoTrack")},t.prototype.removeProcessor=function(){var t=this;this._log.debug("Removing VideoProcessor from the LocalVideoTrack");var n=e.prototype.removeProcessor.apply(this,arguments);return this._log.debug("Updating LocalVideoTrack's MediaStreamTrack with the original MediaStreamTrack"),this._setSenderMediaStreamTrack().then((function(){return t._updateElementsMediaStreamTrack()})),n},t.prototype.disable=function(){var t=e.prototype.disable.apply(this,arguments);return this.processedTrack&&(this.processedTrack.enabled=!1),t},t.prototype.enable=function(t){void 0===t&&(t=!0);var n=e.prototype.enable.apply(this,arguments);return this.processedTrack&&(this.processedTrack.enabled=t,t&&(this._captureFrames(),this._log.debug("Updating LocalVideoTrack's MediaStreamTrack with the processed MediaStreamTrack",this.processedTrack),this._setSenderMediaStreamTrack(!0))),n},t.prototype.restart=function(){var t=this;this._workaroundSilentLocalVideoCleanup&&(this._workaroundSilentLocalVideoCleanup(),this._workaroundSilentLocalVideoCleanup=null);var n=e.prototype.restart.apply(this,arguments);return this.processor&&n.then((function(){t._restartProcessor()})),this._workaroundSilentLocalVideo&&n.finally((function(){t._workaroundSilentLocalVideoCleanup=t._workaroundSilentLocalVideo(t,document)})),n},t.prototype.stop=function(){return this._workaroundSilentLocalVideoCleanup&&(this._workaroundSilentLocalVideoCleanup(),this._workaroundSilentLocalVideoCleanup=null),e.prototype.stop.apply(this,arguments)},t}(s(l));function p(e,t){var n=e._log,r=e._dummyEl,i=e.mediaStreamTrack;function o(){e.isEnabled&&(n.info("Unmuted, checking silence"),r.play().then((function(){return a(r,t)})).then((function(t){if(t)return n.warn("Silence detected, restarting"),e._stop(),e._restart();n.info("Non-silent frames detected, so no need to restart")})).catch((function(e){n.warn("Failed to detect silence and restart:",e)})).finally((function(){!(r=e._dummyEl)||r.paused||e.processedTrack||r.pause(),i.removeEventListener("unmute",o),(i=e.mediaStreamTrack).addEventListener("unmute",o)})))}return i.addEventListener("unmute",o),function(){i.removeEventListener("unmute",o)}}t.exports=u},{"../../util":472,"../../util/browserdetection":463,"../../util/detectsilentvideo":467,"./localmediatrack":364,"./videotrack":383}],367:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r,i){return e.call(this,t,n,r,i)||this}return i(t,e),t.prototype.toString=function(){return"[LocalVideoTrackPublication #"+this._instanceId+": "+this.trackSid+"]"},t}(e("./localtrackpublication"));t.exports=o},{"./localtrackpublication":365}],368:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../../util/browserdetection").isIOS,a=e("../../webrtc").MediaStream,s=e("../../util"),l=s.waitForEvent,c=s.waitForSometime,u=e("../../util/localmediarestartdeferreds"),p=function(e){function t(t,n){var r=this;n=Object.assign({playPausedElementsIfNotBackgrounded:o()&&"object"==typeof document&&"function"==typeof document.addEventListener&&"string"==typeof document.visibilityState},n),r=e.call(this,t.id,t.kind,n)||this;var i=!1;return n=Object.assign({MediaStream:a},n),Object.defineProperties(r,{_attachments:{value:new Set},_dummyEl:{value:null,writable:!0},_elShims:{value:new WeakMap},_isStarted:{get:function(){return i},set:function(e){i=e}}
164,_playPausedElementsIfNotBackgrounded:{value:n.playPausedElementsIfNotBackgrounded},_shouldShimAttachedElements:{value:n.workaroundWebKitBug212780||n.playPausedElementsIfNotBackgrounded},_unprocessedTrack:{value:null,writable:!0},_MediaStream:{value:n.MediaStream},isStarted:{enumerable:!0,get:function(){return i}},mediaStreamTrack:{enumerable:!0,get:function(){return this._unprocessedTrack||t.track}},processedTrack:{enumerable:!0,value:null,writable:!0}}),r._initialize(),r}return i(t,e),t.prototype._start=function(){this._log.debug("Started"),this._isStarted=!0,this._dummyEl&&(this._dummyEl.oncanplay=null),this.emit("started",this)},t.prototype._initialize=function(){var e=this;this._log.debug("Initializing"),this._dummyEl=this._createElement(),this.mediaStreamTrack.addEventListener("ended",(function t(){e._end(),e.mediaStreamTrack.removeEventListener("ended",t)})),this._dummyEl&&(this._dummyEl.muted=!0,this._dummyEl.oncanplay=this._start.bind(this,this._dummyEl),this._attach(this._dummyEl,this.mediaStreamTrack),this._attachments.delete(this._dummyEl))},t.prototype._end=function(){this._log.debug("Ended"),this._dummyEl&&(this._dummyEl.remove(),this._dummyEl.srcObject=null,this._dummyEl.oncanplay=null,this._dummyEl=null)},t.prototype.attach=function(e){var t=this;if("string"==typeof e?e=this._selectElement(e):e||(e=this._createElement()),this._log.debug("Attempting to attach to element:",e),e=this._attach(e),this._shouldShimAttachedElements&&!this._elShims.has(e)){var n=this._playPausedElementsIfNotBackgrounded?function(){return function(e,t){var n=e.tagName.toLowerCase();t.warn("Unintentionally paused:",e),Promise.race([l(document,"visibilitychange"),c(1e3)]).then((function(){"visible"===document.visibilityState&&u.whenResolved("audio").then((function(){return t.info("Playing unintentionally paused <"+n+"> element"),t.debug("Element:",e),e.play()})).then((function(){t.info("Successfully played unintentionally paused <"+n+"> element"),t.debug("Element:",e)})).catch((function(r){t.warn("Error while playing unintentionally paused <"+n+"> element:",{error:r,el:e})}))}))}(e,t._log)}:null;this._elShims.set(e,function(e,t){void 0===t&&(t=null);var n=e.pause,r=e.play,i=!1;e.pause=function(){return i=!0,n.call(e)},e.play=function(){return i=!1,r.call(e)};var o=t?function(){i||t()}:null;o&&e.addEventListener("pause",o);return{pausedIntentionally:function(){return i},unShim:function(){e.pause=n,e.play=r,o&&e.removeEventListener("pause",o)}}}(e,n))}return e},t.prototype._attach=function(e,t){void 0===t&&(t=this.processedTrack||this.mediaStreamTrack);var n=e.srcObject;n instanceof this._MediaStream||(n=new this._MediaStream);var r="audio"===t.kind?"getAudioTracks":"getVideoTracks";return n[r]().forEach((function(e){n.removeTrack(e)})),n.addTrack(t),e.srcObject=n,e.autoplay=!0,e.playsInline=!0,this._attachments.has(e)||this._attachments.add(e),e},t.prototype._selectElement=function(e){var t=document.querySelector(e);if(!t)throw new Error("Selector matched no element: "+e);return t},t.prototype._updateElementsMediaStreamTrack=function(){var e=this;this._log.debug("Reattaching all elements to update mediaStreamTrack"),this._getAllAttachedElements().forEach((function(t){return e._attach(t)}))},t.prototype._createElement=function(){return"undefined"!=typeof document?document.createElement(this.kind):null},t.prototype.detach=function(e){var t;return t="string"==typeof e?[this._selectElement(e)]:e?[e]:this._getAllAttachedElements(),this._log.debug("Attempting to detach from elements:",t),this._detachElements(t),e?t[0]:t},t.prototype._detachElements=function(e){return e.map(this._detachElement.bind(this))},t.prototype._detachElement=function(e){if(!this._attachments.has(e))return e;var t=e.srcObject;(t instanceof this._MediaStream&&t.removeTrack(this.processedTrack||this.mediaStreamTrack),this._attachments.delete(e),this._shouldShimAttachedElements&&this._elShims.has(e))&&(this._elShims.get(e).unShim(),this._elShims.delete(e));return e},t.prototype._getAllAttachedElements=function(){var e=[];return this._attachments.forEach((function(t){e.push(t)})),e},t}(e("./"));t.exports=p},{"../../util":472,"../../util/browserdetection":463,"../../util/localmediarestartdeferreds":475,"../../webrtc":498,"./":359}],369:[function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Prom
164ise))((function(i,o){function a(e){try{l(r.next(e))}catch(e){o(e)}}function s(e){try{l(r.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},i=this&&this.__generator||function(e,t){var n,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}};Object.defineProperty(n,"__esModule",{value:!0}),n.applyNoiseCancellation=n.NoiseCancellationImpl=void 0;var o=e("../../noisecancellationadapter"),a=(e("../../util/log"),function(){function e(e,t){this._processor=e,this._sourceTrack=t,this._disabledPermanent=!1}return Object.defineProperty(e.prototype,"vendor",{get:function(){return this._processor.vendor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"sourceTrack",{get:function(){return this._sourceTrack},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isEnabled",{get:function(){return this._processor.isEnabled()},enumerable:!1,configurable:!0}),e.prototype.enable=function(){if(this._disabledPermanent)throw new Error(this.vendor+" noise cancellation is disabled permanently for this track");return this._processor.enable(),Promise.resolve()},e.prototype.disable=function(){return this._processor.disable(),Promise.resolve()},e.prototype.reacquireTrack=function(e){return r(this,void 0,void 0,(function(){var t,n,r;return i(this,(function(i){switch(i.label){case 0:return t=this._processor.isEnabled(),this._processor.disconnect(),[4,e()];case 1:return n=i.sent(),this._sourceTrack=n,[4,this._processor.connect(n)];case 2:return r=i.sent(),t?this._processor.enable():this._processor.disable(),[2,r]}}))}))},e.prototype.disablePermanently=function(){return this._disabledPermanent=!0,this.disable()},e.prototype.stop=function(){this._processor.disconnect(),this._sourceTrack.stop()},e}());n.NoiseCancellationImpl=a,n.applyNoiseCancellation=function(e,t,n){return r(this,void 0,void 0,(function(){var r,s,l,c;return i(this,(function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,o.createNoiseCancellationAudioProcessor(t,n)];case 1:return r=i.sent(),s=r.connect(e),l=new a(r,e),[2,{cleanTrack:s,noiseCancellation:l}];case 2:return c=i.sent(),n.warn("Failed to create noise cancellation. Returning normal audio track: "+c),[2,{cleanTrack:e}];case 3:return[2]}}
164))}))}},{"../../noisecancellationadapter":385,"../../util/log":476}],370:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){return e.call(this,t,n)||this}return i(t,e),t}(e("./transceiver"));t.exports=o},{"./transceiver":381}],371:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./audiotrack"),a=function(e){function t(t,n,r,i,o,a,s){return e.call(this,t,n,r,i,o,a,s)||this}return i(t,e),t.prototype.toString=function(){return"[RemoteAudioTrack #"+this._instanceId+": "+this.sid+"]"},t.prototype._start=function(){e.prototype._start.call(this),this._dummyEl&&(this._dummyEl.srcObject=null,this._dummyEl=null)},t.prototype.setPriority=function(t){return e.prototype.setPriority.call(this,t)},t}(e("./remotemediatrack")(o));t.exports=a},{"./audiotrack":354,"./remotemediatrack":375}],372:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){return e.call(this,t,n)||this}return i(t,e),t.prototype.toString=function(){return"[RemoteAudioTrackPublication #"+this._instanceId+": "+this.trackSid+"]"},t}(e("./remotetrackpublication"));t.exports=o},{"./remotetrackpublication":376}],373:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("./"),l=e("../../util/constants"),c=l.typeErrors,u=l.trackPriority,p=function(e){function t(t,n,r){var i=e.call(this,n.id,"data",r)||this;return Object.defineProperties(i,{_isSwitchedOff:{value:!1,writable:!0},_priority:{value:null,writable:!0},isEnabled:{enumerable:!0,value:!0},isSwitchedOff:{enumerable:!0,get:function(){return this._isSwitchedOff}},maxPacketLifeTime:{enumerable:!0,value:n.maxPacketLifeTime},maxRetransmits:{enumerable:!0,value:n.maxRetransmits},ordered:{enumerable:!0,value:n.ordered},priority:{enumerable:!0,get:function(){return this._priority}},reliable:{enumerable:!0,value:null===n.maxPacketLifeTime&&null===n.maxRetransmits},sid:{enumerable:!0,value:t}}),n.on("message",(function(e){i.emit("message",e,i)})),i}return i(t,e),t.prototype.setPriority=function(e){var t=a([null],o(Object.values(u)));if(!t.includes(e))throw c.INVALID_VALUE("priority",t);return this._priority=e,this},t.prototype._setEnabled=function(){},t.prototype._setSwitchedOff=function(e){this._isSwitchedOff!==e&&(this._isSwitchedOff=e,this.emit
164(e?"switchedOff":"switchedOn",this))},t}(s);t.exports=p},{"../../util/constants":465,"./":359}],374:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){return e.call(this,t,n)||this}return i(t,e),t.prototype.toString=function(){return"[RemoteDataTrackPublication #"+this._instanceId+": "+this.trackSid+"]"},t}(e("./remotetrackpublication"));t.exports=o},{"./remotetrackpublication":376}],375:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("../../util/constants"),l=s.typeErrors,c=s.trackPriority,u=e("../../util/browserdetection").isIOS,p=e("../../util/documentvisibilitymonitor.js");t.exports=function(e){return function(e){function t(t,n,r,i,o,a,s){var l=this;return s=Object.assign({workaroundWebKitBug212780:u()&&"object"==typeof document&&"function"==typeof document.addEventListener&&"string"==typeof document.visibilityState},s),l=e.call(this,n,s)||this,Object.defineProperties(l,{_isEnabled:{value:r,writable:!0},_isSwitchedOff:{value:i,writable:!0},_priority:{value:null,writable:!0},_setPriority:{value:o},_setRenderHint:{value:function(e){l._log.debug("updating render hint:",e),a(e)}},isEnabled:{enumerable:!0,get:function(){return this._isEnabled}},isSwitchedOff:{enumerable:!0,get:function(){return this._isSwitchedOff}},priority:{enumerable:!0,get:function(){return this._priority}},sid:{enumerable:!0,value:t},_workaroundWebKitBug212780:{value:s.workaroundWebKitBug212780},_workaroundWebKitBug212780Cleanup:{value:null,writable:!0}}),l}return i(t,e),t.prototype.setPriority=function(e){var t=a([null],o(Object.values(c)));if(!t.includes(e))throw l.INVALID_VALUE("priority",t);return this._priority!==e&&(this._priority=e,this._setPriority(e)),this},t.prototype._setEnabled=function(e){this._isEnabled!==e&&(this._isEnabled=e,this.emit(this._isEnabled?"enabled":"disabled",this))},t.prototype._setSwitchedOff=function(e){this._isSwitchedOff!==e&&(this._isSwitchedOff=e,this.emit(e?"switchedOff":"switchedOn",this))},t.prototype.attach=function(t){var n=e.prototype.attach.call(this,t);return!0!==this.mediaStreamTrack.enabled&&(this.mediaStreamTrack.enabled=!0,this.processedTrack&&(this.processedTrack.enabled=!0),this.processor&&this._captureFrames()),this._workaroundWebKitBug212780&&(this._workaroundWebKitBug212780Cleanup=this._workaroundWebKitBug212780Cleanup||function(e){var t=e._log,n=e.kind;function r(r){r&&e._attachments.forEach((function(r){var i=e._elShims.get(r);r.paused&&i&&!i.pausedIntentionally()&&(t.info("Playing inadvertently paused <"+n+"> element"),t.debug("Element:",r),t.debug("RemoteMediaTrack:",e),r.play().then((function(){t.info("Successfully played inadvertently paused <"+n+"> element"),t.debug("Element:",r),t.debug("RemoteMediaTrack:",e)})).catch((function(i){t.warn("Error while playing inadvertently paused <"+n+"> element:",{err:i,el:r,remoteMediaTrack:e})})))}))}return p.onVisibilityChange(2,r),function(){p.offVisibilityChange(2,r)}}(this)),n},t.prototype.detach=function(t){var n=e.prototype.detach.call(this,t);return 0===this._attachments.size&&(this.mediaStreamTrack.enabled=!1,this.processedTrack&&(this.processedTrack.enabled=!1),this._workaroundWebKitBug212780Cleanup&&(this._workaroundWebKitBug212780Cleanup(),this._workaroundWebKitBug212780Cleanup=null)),n},t}(e)}},{"../../util/browserdetection":463,"../../util/constants":465,"../../util/documentvisibilitymonitor.js":468}],376:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this,t.name,t.sid,n)||this;Object.defineProperties(r,{_signaling:{value:t},_track:{value:null,writable:!0},isSubscribed:{enumerable:!0,get:function(){return!!this._track}},isTrackEnabled:{enumerable:!0,get:function(){return t.isEnabled}},kind:{enumerable:!0,value:t.kind},publishPriority:{enumerable:!0,get:function(){return t.priority}},track:{enumerable:!0,get:function(){return this._track}}});var i=t.error,o=t.isEnabled,a=t.isSwitchedOff,s=t.priority;return t.on("updated",(function(){if(i!==t.error)return i=t.error,void r.emit("subscriptionFailed",t.error);o!==t.isEnabled&&(o=t.isEnabled,r.track&&r.track._setEnabled(t.isEnabled),r.emit(t.isEnabled?"trackEnabled":"trackDisabled")),a!==t.isSwitchedOff&&(r._log.debug(r.trackSid+": "+(a?"OFF":"ON")+" => "+(t.isSwitchedOff?"OFF":"ON")),a=t.isSwitchedOff,r.track?(r.track._setSwitchedOff(t.isSwitchedOff),r.emit(a?"trackSwitchedOff":"trackSwitchedOn",r.track)):a&&r._log.warn("Track was not subscribed when switched Off.")),s!==t.priority&&(s=t.priority,r.emit("publishPriorityChanged",s))}
164)),r}return i(t,e),t.prototype.toString=function(){return"[RemoteTrackPublication #"+this._instanceId+": "+this.trackSid+"]"},t.prototype._subscribed=function(e){!this._track&&e&&(this._track=e,this.emit("subscribed",e))},t.prototype._unsubscribe=function(){if(this._track){var e=this._track;this._track=null,this.emit("unsubscribed",e)}},t}(e("./trackpublication"));t.exports=o},{"./trackpublication":380}],377:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=e("./remotemediatrack"),s=e("./videotrack"),l=e("../../util/documentvisibilitymonitor.js"),c=e("../../util/nullobserver.js").NullObserver,u=e("../../util/timeout"),p=a(s),f=function(e){function t(t,n,r,i,o,a,s){var l=this;return s=Object.assign({clientTrackSwitchOffControl:"auto",contentPreferencesMode:"auto",enableDocumentVisibilityTurnOff:!0},s),s=Object.assign({IntersectionObserver:"undefined"==typeof IntersectionObserver||"auto"!==s.clientTrackSwitchOffControl?c:IntersectionObserver,ResizeObserver:"undefined"==typeof ResizeObserver||"auto"!==s.contentPreferencesMode?c:ResizeObserver},s),l=e.call(this,t,n,r,i,o,a,s)||this,Object.defineProperties(l,{_enableDocumentVisibilityTurnOff:{value:!0===s.enableDocumentVisibilityTurnOff&&"auto"===s.clientTrackSwitchOffControl},_documentVisibilityTurnOffCleanup:{value:null,writable:!0},_clientTrackSwitchOffControl:{value:s.clientTrackSwitchOffControl},_contentPreferencesMode:{value:s.contentPreferencesMode},_invisibleElements:{value:new WeakSet},_elToPipCallbacks:{value:new WeakMap},_elToPipWindows:{value:new WeakMap},_turnOffTimer:{value:new u((function(){l._setRenderHint({enabled:!1})}),50,!1)},_resizeObserver:{value:new s.ResizeObserver((function(e){e.find((function(e){return!l._invisibleElements.has(e.target)}))&&h(l)}))},_intersectionObserver:{value:new s.IntersectionObserver((function(e){var t=!1;e.forEach((function(e){!l._invisibleElements.has(e.target)!==e.isIntersecting&&(e.isIntersecting?(l._log.debug("intersectionObserver detected: Off => On"),l._invisibleElements.delete(e.target)):(l._log.debug("intersectionObserver detected: On => Off"),l._invisibleElements.add(e.target)),t=!0)})),t&&(d(l),h(l))}),{threshold:.25})}}),l}return i(t,e),t.prototype._start=function(t){var n=e.prototype._start.call(this,t);return d(this),n},t.prototype.switchOn=function(){if("manual"!==this._clientTrackSwitchOffControl)throw new Error('Invalid state. You can call switchOn only when bandwidthProfile.video.clientTrackSwitchOffControl is set to "manual"');return this._setRenderHint({enabled:!0}),this},t.prototype.switchOff=function(){if("manual"!==this._clientTrackSwitchOffControl)throw new Error('Invalid state. You can call switchOff only when bandwidthProfile.video.clientTrackSwitchOffControl is set to "manual"');return this._setRenderHint({enabled:!1}),this},t.prototype.setContentPreferences=function(e){if("manual"!==this._contentPreferencesMode)throw new Error('Invalid state. You can call switchOn only when bandwidthProfile.video.contentPreferencesMode is set to "manual"');return e.renderDimensions&&this._setRenderHint({renderDimensions:e.renderDimensions}),this},t.prototype._unObservePip=function(e){var t=this._elToPipCallbacks.get(e);t&&(e.removeEventListener("enterpictureinpicture",t.onEnterPip),e.removeEventListener("leavepictureinpicture",t.onLeavePip),this._elToPipCallbacks.delete(e))},t.prototype._observePip=function(e){var t=this;if(!this._elToPipCallbacks.get(e)){var n=function(n){return t._onEnterP
164ip(n,e)},r=function(n){return t._onLeavePip(n,e)};e.addEventListener("enterpictureinpicture",n),e.addEventListener("leavepictureinpicture",r),this._elToPipCallbacks.set(e,{onEnterPip:n,onLeavePip:r,onResizePip:function(n){return t._onResizePip(n,e)}})}},t.prototype._onEnterPip=function(e,t){this._log.debug("onEnterPip");var n=e.pictureInPictureWindow;this._elToPipWindows.set(t,n);var r=this._elToPipCallbacks.get(t).onResizePip;n.addEventListener("resize",r),d(this)},t.prototype._onLeavePip=function(e,t){this._log.debug("onLeavePip"),this._elToPipWindows.delete(t);var n=this._elToPipCallbacks.get(t).onResizePip;e.pictureInPictureWindow.removeEventListener("resize",n),d(this)},t.prototype._onResizePip=function(){h(this)},t.prototype.attach=function(t){var n=e.prototype.attach.call(this,t);return"auto"===this._clientTrackSwitchOffControl&&this._invisibleElements.add(n),this._intersectionObserver.observe(n),this._resizeObserver.observe(n),this._enableDocumentVisibilityTurnOff&&(this._documentVisibilityTurnOffCleanup=this._documentVisibilityTurnOffCleanup||function(e){function t(){d(e)}return l.onVisibilityChange(1,t),function(){l.offVisibilityChange(1,t)}}(this)),this._observePip(n),n},t.prototype.detach=function(t){var n=this,r=e.prototype.detach.call(this,t);return(Array.isArray(r)?r:[r]).forEach((function(e){n._intersectionObserver.unobserve(e),n._resizeObserver.unobserve(e),n._invisibleElements.delete(e),n._unObservePip(e)})),0===this._attachments.size&&this._documentVisibilityTurnOffCleanup&&(this._documentVisibilityTurnOffCleanup(),this._documentVisibilityTurnOffCleanup=null),d(this),h(this),r},t.prototype.addProcessor=function(){return e.prototype.addProcessor.apply(this,arguments)},t.prototype.removeProcessor=function(){return e.prototype.removeProcessor.apply(this,arguments)},t.prototype.toString=function(){return"[RemoteVideoTrack #"+this._instanceId+": "+this.sid+"]"},t.prototype.setPriority=function(t){return e.prototype.setPriority.call(this,t)},t}(p);function d(e){if("auto"===e._clientTrackSwitchOffControl){var t=e._getAllAttachedElements().filter((function(t){return!e._invisibleElements.has(t)}));!0===(e._getAllAttachedElements().filter((function(t){return e._elToPipWindows.has(t)})).length>0||"visible"===document.visibilityState&&t.length>0)?(e._turnOffTimer.clear(),e._setRenderHint({enabled:!0})):e._turnOffTimer.isSet||e._turnOffTimer.start()}}function h(e){if("auto"===e._contentPreferencesMode){var t=e._getAllAttachedElements().filter((function(t){return!e._invisibleElements.has(t)})),n=e._getAllAttachedElements().map((function(t){var n=e._elToPipWindows.get(t);return n?{clientHeight:n.height,clientWidth:n.width}:{clientHeight:0,clientWidth:0}})),r=t.concat(n);if(r.length>0){var i=o(r.sort((function(e,t){return t.clientHeight+t.clientWidth-e.clientHeight-e.clientWidth-1})),1)[0],a={height:i.clientHeight,width:i.clientWidth};e._setRenderHint({renderDimensions:a})}}}t.exports=f},{"../../util/documentvisibilitymonitor.js":468,"../../util/nullobserver.js":479,"../../util/timeout":486,"./remotemediatrack":375,"./videotrack":383}],378:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){return e.call(this,t,n)||this}return i(t,e),t.prototype.toString=function(){return"[RemoteVideoTrackPublication #"+this._instanceId+": "+this.trackSid+"]"},t}(e("./remotetrackpublication"));t.exports=o},{"./remotetrackpublication":376}],379:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=function(e){function t(t){var n=e.call(this,t.id,t)||this;return Object.defineProperties(n,{_clones:{value:new Set},_eventsToReemitters:{value:new Map([["mute",function(){return n.queue("muted")}],["unmute",function(){return n.queue("unmuted")}]])},_senders:{value:new Set},_senderToPublisherHintCallbacks:{value:new Map},isPublishing:{enumerable:!0,get:function(){return!!this._clones.size}},muted:{enumerable:!0,get:function(){return this._track.muted}}}),n._reemitMediaStreamTrackEvents(),n}return i(t,e),t.prototype._reemitMediaStreamTrackEvents=function(e){void 0===e&&(e=this._track);var t=this._eventsToReemitters,n=this._track;(t.forEach((function(t,n){return e.addEventListener(n,t)})),n!==e)&&(t.forEach((function(e,t){return n.removeEventListener(t,e)})),n.muted!==e.muted&&t.get(e.muted?"mute":"unmute")())},t.prototype.clone=function(){var e=new t(this.track.clone());return this._clones.add(e),e},t.prototype.removeClone=function(e){this._clones.delete(e)},t.prototype.setMediaStreamTrack=function(e){var t=this,n=Array.from(this._clones),r=Array.from(this._senders);return Promise.all(n.map((function(t){return t.setMediaStreamTrack(e.clone())})).concat(r.map((function(n){return t._replaceTrack(n,e)})))).finally((function(){t._reemitMediaStreamTrackEvents(e),t._track=e}))},t.prototype.addSender=function(e,t){return this._senders.add(e),t&&this._senderToPublisherHintCallbacks.set(e,t),this},t.prototype.removeSender=function(e){return this._senders.delete(e),this._senderToPublisherHintCallbacks.delete(e),this},t.prototype.setPublisherHint=function(e){var t=o(Array.from(this._senderToPublisherHintCallbacks.values()),1)[0];return t?t(e):Promise.resolve("COULD_NOT_APPLY_HINT")},t.prototype._replaceTrack=function(e,t){var n=this;return e.replaceTrack(t).then((function(e){return n.setPublisherHint(null).cat
164ch((function(){})),n.emit("replaced"),e}))},t}(e("./transceiver"));t.exports=a},{"./transceiver":381}],380:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../../eventemitter"),a=e("../../util"),s=a.buildLogLevels,l=a.valueToJSON,c=e("../../util/constants").DEFAULT_LOG_LEVEL,u=e("../../util/log"),p=0,f=function(e){function t(t,n,r){var i=e.call(this)||this;r=Object.assign({logLevel:c},r);var o=s(r.logLevel);return Object.defineProperties(i,{_instanceId:{value:p++},_log:{value:r.log?r.log.createLog("default",i):new u("default",i,o,r.loggerName)},trackName:{enumerable:!0,value:t},trackSid:{enumerable:!0,value:n}}),i}return i(t,e),t.prototype.toJSON=function(){return l(this)},t.prototype.toString=function(){return"[TrackPublication #"+this._instanceId+": "+this.trackSid+"]"},t}(o);t.exports=f},{"../../eventemitter":350,"../../util":472,"../../util/constants":465,"../../util/log":476}],381:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this,t,n.kind)||this;return Object.defineProperties(r,{_track:{value:n,writable:!0},enabled:{enumerable:!0,get:function(){return this._track.enabled}},readyState:{enumerable:!0,get:function(){return this._track.readyState}},track:{enumerable:!0,get:function(){return this._track}}}),r}return i(t,e),t.prototype.stop=function(){this.track.stop(),e.prototype.stop.call(this)},t}(e("../../transceiver"));t.exports=o},{"../../transceiver":459}],382:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("events").EventEmitter,a=e("../../util/constants").DEFAULT_VIDEO_PROCESSOR_STATS_INTERVAL_MS,s=function(e){function t(t){var n=e.call(this)||this;return Object.defineProperties(n,{_lastStatsSaveTime:{value:null,writable:!0},_lastStatsPublishTime:{value:null,writable:!0},_log:{value:t},_processorInfo:{value:null,writable:!0},_stats:{value:null,writable:!0}}),n.on("add",(function(e){n._lastStatsSaveTime=Date.now(),n._lastStatsPublishTime=Date.now(),n._processorInfo=e,n._stats=[],n._reemitEvent("add",n._getEventData())})),n.on("remove",(function(){var e=n._getEventData();n._lastStatsSaveTime=null,n._lastStatsPublishTime=null,n._processorInfo=null,n._stats=null,n._reemitEvent("remove",e)})),n.on("start",(function(){n._reemitEvent("start",n._getEventData())})),n.on("stop",(function(e){n._reemitEvent("stop",Object.assign({message:e},n._getEventData()))})),n.on("stats",(function(){return n._maybeEmitStats()})),n}return i(t,e),t.prototype._getEventData=function(){if(!this._processorInfo)return{};var e=this._processorInfo,t=e.processor,n={captureHeight:e.captureHeight,captureWidth:e.captureWidth,inputFrameRate:e.inputFrameRate,isRemoteVideoTrack:e.isRemoteVideoTrack,inputFrameBufferType:e.inputFrameBufferType,outputFrameBufferContextType:e.outputFrameBufferContextType};return n.name=t._name||"VideoProcessor",["assetsPath","blurFilterRadius","debounce","fitType","isSimdEnabled","maskBlurRadius","pipeline","version"].forEach((function(e){var r=t["_"+e];void 0!==r&&(n[e]=r)}
164)),Object.keys(n).forEach((function(e){var t=n[e];"boolean"==typeof t&&(n[e]=t?"true":"false")})),n},t.prototype._maybeEmitStats=function(){if(this._stats&&this._processorInfo){var e=this._processorInfo.processor._benchmark;if(e){var t=Date.now();if(!(t-this._lastStatsSaveTime<1e3)){var n={outputFrameRate:e.getRate("totalProcessingDelay")};if(["captureFrameDelay","imageCompositionDelay","inputImageResizeDelay","processFrameDelay","segmentationDelay"].forEach((function(t){n[t]=e.getAverageDelay(t)})),this._lastStatsSaveTime=t,this._stats.push(n),!(t-this._lastStatsPublishTime<a)){this._lastStatsPublishTime=t;var r=this._stats.splice(0).reduce((function(e,t,r){return Object.keys(n).forEach((function(n){e[n]||(e[n]=0),e[n]=(e[n]*r+t[n])/(r+1)})),e}),{});Object.keys(r).forEach((function(e){r[e]=parseFloat(r[e].toFixed(2))})),this._reemitEvent("stats",Object.assign({},r,this._getEventData()))}}}}},t.prototype._reemitEvent=function(e,t){this._log.debug("VideoProcessor:"+e,t),this.emit("event",{name:e,data:t})},t}(o);t.exports=s},{"../../util/constants":465,events:222}],383:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./mediatrack"),a=e("./videoprocessoreventobserver"),s=e("../../util/constants").DEFAULT_FRAME_RATE,l=function(e){function t(t,n){var r=e.call(this,t,n)||this;return Object.defineProperties(r,{_captureTimeoutId:{value:null,writable:!0},_isCapturing:{value:!1,writable:!0},_inputFrame:{value:null,writable:!0},_outputFrame:{value:null,writable:!0},_processorEventObserver:{value:null,writable:!0},_processorOptions:{value:{},writable:!0},_unmuteHandler:{value:null,writable:!0},dimensions:{enumerable:!0,value:{width:null,height:null}},processor:{enumerable:!0,value:null,writable:!0}}),r._processorEventObserver=new(n.VideoProcessorEventObserver||a)(r._log),r}return i(t,e),t.prototype._checkIfCanCaptureFrames=function(e){void 0===e&&(e=!1);var t=!0,n="",r=this.mediaStreamTrack;return r.enabled||(t=!1,n="MediaStreamTrack is disabled"),"ended"===r.readyState&&(t=!1,n="MediaStreamTrack is ended"),this.processor||(t=!1,n="VideoProcessor not detected."),this._attachments.size||e||(t=!1,n="VideoTrack is not publishing and there is no attached element."),n&&this._log.debug(n),{canCaptureFrames:t,message:n}},t.prototype._captureFrames=function(){var e=this;if(this._isCapturing)this._log.debug("Ignoring captureFrames call. Capture is already in progress");else{if(!this._checkIfCanCaptureFrames().canCaptureFrames)return this._isCapturing=!1,void this._log.debug("Cannot capture frames. Ignoring captureFrames call.");this._isCapturing=!0,this._processorEventObserver.emit("start"),this._log.debug("Start capturing frames");var t,n=Date.now();this._dummyEl.play().then((function(){var r=function(n){clearTimeout(e._captureTimeoutId);var r=e.mediaStreamTrack.getSettings().frameRate,i=void 0===r?s:r,o=Math.floor(1e3/i)-t;(o<0||"number"!=typeof t)&&(o=0),e._captureTimeoutId=setTimeout(n,o)},i=function(){var o=e._checkIfCanCaptureFrames();if(!o.canCaptureFrames)return e._isCapturing=!1,e._processorEventObserver.emit("stop",o.message),void e._log.debug("Cannot capture frames. Stopping capturing frames.");n=Date.now();var a=e.mediaStreamTrack.getSettings(),s=a.width,l=void 0===s?0:s,c=a.height,u=void 0===c?0:c;e._outputFrame&&e._outputFrame.width!==l&&(e._outputFrame.width=l,e._outputFrame.height=u),e._inputFrame&&(e._inputFrame.width!==l&&(e._inputFrame.width=l,e._inputFrame.height=u),e._inputFrame.getContext("2d").drawImage(e._dummyEl,0,0,l,u));var p=null;try{var f="video"===e._processorOptions.inputFrameBufferType?e._dummyEl:e._inputFrame;p=e.processor.processFrame(f,e._outputFrame)}catch(t){e._log.debug("Exception detected after calling processFrame.",t)}(p instanceof Promise?p:Promise.resolve(p)).then((function(){e._outputFrame&&("function"==typeof e.processedTrack.requestFrame&&e.processedTrack.requestFrame(),e._processorEventObserver.emit("stats"))})).finally((function(){t=Date.now()-n,r(i)}))};r(i)})).catch((function(t){return e._log.error("Video element cannot be played",{error:t,track:e})}))}},t.prototype._initialize=function(){var n=this;e.prototype._initialize.call(this),this._dummyEl&&(this._dummyEl.onloadedmetadata=function(){c(n,n._dummyEl)&&(n.dimensions.width=n._dummyEl.videoWidth,n.dimensions.height=n._dummyEl.videoHeight)},this._dummyEl.onresize=function(){c(n,n._dummyEl)&&(n.dimensions.width=n._dummyEl.videoWidth,n.dimensions.height=n._dummyEl.videoHeight,n.isStarted&&(n._log.debug("Dimensions changed:",n.dimensions),n.emit(t.DIMENSIONS_CHANGED,n)))})},t.prototype._restartProcessor=function(){var e=this.processor;if(e){var t=Object.assign({},this._processorOptions);this.removeProcessor(e),this.addProcessor(e,t)}},t.prototype._start=function(n){return this.dimensions.width=n.videoWidth,this.dimensions.height=n.videoHeight,this._log.debug("Dimensions:",this.dimensions),this.emit
164(t.DIMENSIONS_CHANGED,this),e.prototype._start.call(this,n)},t.prototype.addProcessor=function(e,t){var n=this;if(!e||"function"!=typeof e.processFrame)throw new Error("Received an invalid VideoProcessor from addProcessor.");if(this.processor)throw new Error("A VideoProcessor has already been added.");if(!this._dummyEl)throw new Error("VideoTrack has not been initialized.");this._log.debug("Adding VideoProcessor to the VideoTrack",e),this._unmuteHandler||(this._unmuteHandler=function(){n._log.debug("mediaStreamTrack unmuted"),n.processedTrack.muted&&(n._log.debug("mediaStreamTrack is unmuted but processedTrack is muted. Restarting processor."),n._restartProcessor())},this.mediaStreamTrack.addEventListener("unmute",this._unmuteHandler)),this._processorOptions=t||{};var r=this._processorOptions,i=r.inputFrameBufferType,o=r.outputFrameBufferContextType;if("undefined"==typeof OffscreenCanvas&&"offscreencanvas"===i)throw new Error("OffscreenCanvas is not supported by this browser.");if(i&&"video"!==i&&"canvas"!==i&&"offscreencanvas"!==i)throw new Error("Invalid inputFrameBufferType of "+i);i||(i="undefined"==typeof OffscreenCanvas?"canvas":"offscreencanvas");var a=this.mediaStreamTrack.getSettings(),l=a.width,c=void 0===l?0:l,u=a.height,p=void 0===u?0:u,f=a.frameRate,d=void 0===f?s:f;if("offscreencanvas"===i&&(this._inputFrame=new OffscreenCanvas(c,p)),"canvas"===i&&(this._inputFrame=document.createElement("canvas")),this._inputFrame&&(this._inputFrame.width=c,this._inputFrame.height=p),this._outputFrame=document.createElement("canvas"),this._outputFrame.width=c,this._outputFrame.height=p,o=o||"2d",!this._outputFrame.getContext(o))throw new Error("Cannot get outputFrameBufferContextType: "+o+".");var h="undefined"!=typeof CanvasCaptureMediaStreamTrack&&CanvasCaptureMediaStreamTrack.prototype&&"function"==typeof CanvasCaptureMediaStreamTrack.prototype.requestFrame?0:void 0;return this.processedTrack=this._outputFrame.captureStream(h).getTracks()[0],this.processedTrack.enabled=this.mediaStreamTrack.enabled,this.processor=e,this._processorEventObserver.emit("add",{processor:e,captureHeight:p,captureWidth:c,inputFrameRate:d,isRemoteVideoTrack:this.toString().includes("RemoteVideoTrack"),inputFrameBufferType:i,outputFrameBufferContextType:o}),this._updateElementsMediaStreamTrack(),this._captureFrames(),this},t.prototype.attach=function(){var t=e.prototype.attach.apply(this,arguments);return this.processor&&this._captureFrames(),t},t.prototype.detach=function(){return e.prototype.detach.apply(this,arguments)},t.prototype.removeProcessor=function(e){if(!e)throw new Error("Received an invalid VideoProcessor from removeProcessor.");if(!this.processor)throw new Error("No existing VideoProcessor detected.");if(e!==this.processor)throw new Error("The provided VideoProcessor is different than the existing one.");return this._processorEventObserver.emit("remove"),this._log.debug("Removing VideoProcessor from the VideoTrack",e),clearTimeout(this._captureTimeoutId),this.mediaStreamTrack.removeEventListener("unmute",this._unmuteHandler),this._processorOptions={},this._unmuteHandler=null,this._isCapturing=!1,this.processor=null,this.processedTrack=null,this._inputFrame=null,this._outputFrame=null,this._updateElementsMediaStreamTrack(),this},t}(o);function c(e,t){return e.dimensions.width!==t.videoWidth||e.dimensions.height!==t.videoHeight}l.DIMENSIONS_CHANGED="dimensionsChanged",t.exports=l},{"../../util/constants":465,"./mediatrack":368,"./videoprocessoreventobserver":382}],384:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=e("events").EventEmitter,s=e("./util/constants"),l=s.DEFAULT_NQ_LEVEL_LOCAL,c=s.DEFAULT_NQ_LEVEL_REMOTE,u=s.MAX_NQ_LEVEL,p=e("./util").inRange,f=function(e){function t(t){var n=e.call(this)||this;return t=Object.assign({local:l,remote:c},t),Object.defineProperties(n,{local:{value:p(t.local,l,u)?t.local:l,writable:!0},remote:{value:p(t.remote,c,u)?t.remote:c,writable:!0}}),n}return i(t,e),t.prototype.update=function(e){var t=this;e=Object.assign({local:this.local,remote:this.remote}
164,e),[["local",l,3],["remote",c,3]].forEach((function(n){var r=o(n,3),i=r[0],a=r[1],s=r[2];t[i]="number"==typeof e[i]&&p(e[i],a,s)?e[i]:a}))},t}(a);t.exports=f},{"./util":472,"./util/constants":465,events:222}],385:[function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{l(r.next(e))}catch(e){o(e)}}function s(e){try{l(r.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},i=this&&this.__generator||function(e,t){var n,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}};Object.defineProperty(n,"__esModule",{value:!0}),n.createNoiseCancellationAudioProcessor=void 0;var o=e("./util/dynamicimport"),a=(e("./util/log"),{krisp:{supportedVersion:"1.0.0",pluginFile:"krispsdk.mjs"},rnnoise:{supportedVersion:"0.6.0",pluginFile:"rnnoise_sdk.mjs"}}),s=new Map;n.createNoiseCancellationAudioProcessor=function(e,t){return r(this,void 0,void 0,(function(){var n,r,l,c,u,p,f,d,h;return i(this,(function(i){switch(i.label){case 0:if(n=s.get(e.vendor))return[3,6];if(!(r=a[e.vendor]))throw new Error("Unsupported NoiseCancellationOptions.vendor: "+e.vendor);l=r.supportedVersion,c=r.pluginFile,u=e.sdkAssetsPath,p=u+"/"+c,i.label=1;case 1:return i.trys.push([1,5,,6]),t.debug("loading noise cancellation sdk: ",p),[4,o(p)];case 2:return f=i.sent(),t.debug("Loaded noise cancellation sdk:",f),d=f.default,function(e){var t=e.supportedVersion,n=e.plugin,r=e.log;if(!n.getVersion||!n.isSupported)throw new Error("Plugin does not export getVersion/isSupported api. Are you using old version of the plugin ?");var i=n.getVersion();r.debug("Plugin Version = "+i);var o=t.split(".").map((function(e){return Number(e)})),a=i.split(".").map((function(e){return Number(e)}));if(3!==o.length||3!==a.length)throw new Error("Unsupported Plugin version format: "+t+", "+i);if(o[0]!==a[0])throw new Error("Major version mismatch: [Plugin version "+i+"],  [Supported Version "+t+"]");if(a[1]<o[1])throw new Error("Minor version mismatch: [Plugin version "+i+"] < [Supported Version "+t+"]");var s=new AudioContext,l=n.isSupported(s);if(s.close(),!l)throw new Error("Noise Cancellation plugin is not supported on your browser")}({supportedVersion:l,plugin:d,log:t}),d.isInitialized()?[3,4]:(t.debug("initializing noise cancellation sdk: ",u),[4,d.init({rootDir:u})]);case 3:i.sent(),t.debug("noise cancellation sdk initialized!"),i.label=4;case 4:return n={vendor:e.vendor,isInitialized:function(){return d.isInitialized()},isConnected:function(){return d.isConnected()},isEnabled:function(){return d.isEnabled()},disconnect:function(){return d.disconnect()},enable:function(){return d.enable()},disable:function(){return d.disable()},destroy:function(){return d.destroy()},setLogging:function(e){return d.setLogging(e)},connect:function(e){t.debug("connect: ",e.id),d.isConnected()&&d.disconnect();var n=d.connect(new MediaStream([e]));if(!n)throw new Error("Error connecting with noise cancellation sdk");var r=n.getAudioTracks()[0];if(!r)throw new Error("Error getting clean track from noise cancellation sdk");return d.enable(),r}}
164,s.set(e.vendor,n),[3,6];case 5:throw h=i.sent(),t.error("Error loading noise cancellation sdk:"+p,h),h;case 6:return[2,n]}}))}))}},{"./util/dynamicimport":469,"./util/log":476}],386:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("./eventemitter"),l=e("./media/track/remoteaudiotrack"),c=e("./media/track/remoteaudiotrackpublication"),u=e("./media/track/remotedatatrack"),p=e("./media/track/remotedatatrackpublication"),f=e("./media/track/remotevideotrack"),d=e("./media/track/remotevideotrackpublication"),h=e("./util"),m=0,y=function(e){function t(t,n){var r=e.call(this)||this,i=function(e){var t=e.map((function(e){return[e.id,e]})),n=t.filter((function(e){return"audio"===e[1].kind})),r=t.filter((function(e){return"video"===e[1].kind})),i=t.filter((function(e){return"data"===e[1].kind}));return{audioTracks:n,dataTracks:i,tracks:t,videoTracks:r}}((n=Object.assign({RemoteAudioTrack:l,RemoteAudioTrackPublication:c,RemoteDataTrack:u,RemoteDataTrackPublication:p,RemoteVideoTrack:f,RemoteVideoTrackPublication:d,tracks:[]},n)).tracks),o=n.log.createLog("default",r),a=new Map(i.audioTracks),s=new Map(i.dataTracks),h=new Map(i.tracks),y=new Map(i.videoTracks);return Object.defineProperties(r,{_RemoteAudioTrack:{value:n.RemoteAudioTrack},_RemoteAudioTrackPublication:{value:n.RemoteAudioTrackPublication},_RemoteDataTrack:{value:n.RemoteDataTrack},_RemoteDataTrackPublication:{value:n.RemoteDataTrackPublication},_RemoteVideoTrack:{value:n.RemoteVideoTrack},_RemoteVideoTrackPublication:{value:n.RemoteVideoTrackPublication},_audioTracks:{value:a},_dataTracks:{value:s},_instanceId:{value:++m},_clientTrackSwitchOffControl:{value:n.clientTrackSwitchOffControl},_contentPreferencesMode:{value:n.contentPreferencesMode},_log:{value:o},_signaling:{value:t},_tracks:{value:h},_trackEventReemitters:{value:new Map},_trackPublicationEventReemitters:{value:new Map},_trackSignalingUpdatedEventCallbacks:{value:new Map},_videoTracks:{value:y},audioTracks:{enumerable:!0,value:new Map},dataTracks:{enumerable:!0,value:new Map},identity:{enumerable:!0,get:function(){return t.identity}},networkQualityLevel:{enumerable:!0,get:function(){return t.networkQualityLevel}},networkQualityStats:{enumerable:!0,get:function(){return t.networkQualityStats}},sid:{enumerable:!0,get:function(){return t.sid}},state:{enumerable:!0,get:function(){return t.state}},tracks:{enumerable:!0,value:new Map},videoTracks:{enumerable:!0,value:new Map}}),r._tracks.forEach(b.bind(null,r)),t.on("networkQualityLevelChanged",(function(){return r.emit("networkQualityLevelChanged",r.networkQualityLevel,r.networkQualityStats&&(r.networkQualityStats.audio||r.networkQualityStats.video)?r.networkQualityStats:null)})),function(e,t){var n=e._log;if("disconnected"===e.state)return;t.on("stateChanged",(function r(i){n.debug("Transitioned to state:",i),e.emit(i,e),"disconnected"===i&&(n.debug("Removing Track event reemitters"),t.removeListener("stateChanged",r),e._tracks.forEach((function(t){var n=e._trackEventReemitters.get(t.id);t&&n&&n.forEach((function(e,n){t.removeListener(n,e)}))})),t.tracks.forEach((function(t){var n=e._tracks.get(t.id),r=e._trackEventReemitters.get(t.id);n&&r&&r.forEach((function(e,t){n.removeListener(t,e)}))}
164)),e._trackEventReemitters.clear(),e.tracks.forEach((function(t){e._trackPublicationEventReemitters.get(t.trackSid).forEach((function(e,n){t.removeListener(n,e)}))})),e._trackPublicationEventReemitters.clear())}))}(r,t),o.info("Created a new Participant"+(r.identity?": "+r.identity:"")),r}return i(t,e),t.prototype._getTrackEvents=function(){return[["dimensionsChanged","trackDimensionsChanged"],["message","trackMessage"],["started","trackStarted"]]},t.prototype._getTrackPublicationEvents=function(){return[]},t.prototype.toString=function(){return"[Participant #"+this._instanceId+": "+this.sid+"]"},t.prototype._addTrack=function(e,t){var n=this._log;return this._tracks.has(t)?null:(this._tracks.set(t,e),{audio:this._audioTracks,video:this._videoTracks,data:this._dataTracks}[e.kind].set(t,e),b(this,e,t),n.info("Added a new "+h.trackClass(e)+":",t),n.debug(h.trackClass(e)+":",e),e)},t.prototype._addTrackPublication=function(e){var t=this._log;return this.tracks.has(e.trackSid)?null:(this.tracks.set(e.trackSid,e),{audio:this.audioTracks,data:this.dataTracks,video:this.videoTracks}[e.kind].set(e.trackSid,e),function(e,t){var n=new Map;if("disconnected"===e.state)return;e._getTrackPublicationEvents().forEach((function(r){var i=o(r,2),s=i[0],l=i[1];n.set(s,(function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];e.emit.apply(e,a(a([l],o(n)),[t]))})),t.on(s,n.get(s))})),e._trackPublicationEventReemitters.set(t.trackSid,n)}(this,e),t.info("Added a new "+h.trackPublicationClass(e)+":",e.trackSid),t.debug(h.trackPublicationClass(e)+":",e),e)},t.prototype._handleTrackSignalingEvents=function(){var e=this._log,t=this._clientTrackSwitchOffControl,n=this._contentPreferencesMode,r=this;if("disconnected"!==this.state){var i=this._RemoteAudioTrack,a=this._RemoteAudioTrackPublication,s=this._RemoteVideoTrack,l=this._RemoteVideoTrackPublication,c=this._RemoteDataTrack,u=this._RemoteDataTrackPublication,p=this._signaling;p.on("trackAdded",f),p.on("trackRemoved",d),p.tracks.forEach(f),p.on("stateChanged",(function t(n){"disconnected"===n?(e.debug("Removing event listeners"),p.removeListener("stateChanged",t),p.removeListener("trackAdded",f),p.removeListener("trackRemoved",d)):"connected"===n&&(e.info("reconnected"),setTimeout((function(){return r.emit("reconnected")}),0))}))}function f(t){var n=new(0,{audio:a,data:u,video:l}[t.kind])(t,{log:e});r._addTrackPublication(n);var i=t.isSubscribed;i&&h(t),r._trackSignalingUpdatedEventCallbacks.set(t.sid,(function(){if(i!==t.isSubscribed){if(i=t.isSubscribed)return void h(t);!function(e){var t=o(Array.from(r._tracks.entries()).find((function(t){return o(t,2)[1].sid===e.sid})),2),n=t[0],i=t[1],a=r.tracks.get(e.sid);i&&r._removeTrack(i,a,n)}(t)}})),t.on("updated",r._trackSignalingUpdatedEventCallbacks.get(t.sid))}function d(e){e.isSubscribed&&e.setTrackTransceiver(null);var t=r._trackSignalingUpdatedEventCallbacks.get(e.sid);t&&(e.removeListener("updated",t),r._trackSignalingUpdatedEventCallbacks.delete(e.sid));var n=r.tracks.get(e.sid);n&&r._removeTrackPublication(n)}function h(o){var a=o.isEnabled,l=o.name,u=o.kind,f=o.sid,d=o.trackTransceiver,h=o.isSwitchedOff,m={audio:i,video:s,data:c}[u],y=r.tracks.get(f);if(m&&u===d.kind){var b={log:e,name:l,clientTrackSwitchOffControl:t,contentPreferencesMode:n},v="data"===u?new m(f,d,b):new m(f,d,a,h,(function(e){return p.updateSubscriberTrackPriority(f,e)}),(function(e){o.isSubscribed&&p.updateTrackRenderHint(f,e)}),b);r._addTrack(v,y,d.id)}}},t.prototype._removeTrack=function(e,t){if(!this._tracks.has(t))return null;this._tracks.delete(t),{audio:this._audioTracks,video:this._videoTracks,data:this._dataTracks}[e.kind].delete(t),(this._trackEventReemitters.get(t)||new Map).forEach((function(t,n){e.removeListener(n,t)}));var n=this._log;return n.info("Removed a "+h.trackClass(e)+":",t),n.debug(h.trackClass(e)+":",e),e},t.prototype._removeTrackPublication=function(e){if(!(e=this.tracks.get(e.trackSid)))return null;this.tracks.delete(e.trackSid),{audio:this.audioTracks,data:this.dataTracks,video:this.videoTracks}[e.kind].delete(e.trackSid),(this._trackPublicationEventReemitters.get(e.trackSid)||new Map).forEac
164h((function(t,n){e.removeListener(n,t)}));var t=this._log;return t.info("Removed a "+h.trackPublicationClass(e)+":",e.trackSid),t.debug(h.trackPublicationClass(e)+":",e),e},t.prototype.toJSON=function(){return h.valueToJSON(this)},t}(s);function b(e,t,n){var r=new Map;"disconnected"!==e.state&&(e._getTrackEvents().forEach((function(n){var i=n[0],s=n[1];r.set(i,(function(){var t=[s].concat([].slice.call(arguments));return e.emit.apply(e,a([],o(t)))})),t.on(i,r.get(i))})),e._trackEventReemitters.set(n,r))}t.exports=y},{"./eventemitter":350,"./media/track/remoteaudiotrack":371,"./media/track/remoteaudiotrackpublication":372,"./media/track/remotedatatrack":373,"./media/track/remotedatatrackpublication":374,"./media/track/remotevideotrack":377,"./media/track/remotevideotrackpublication":378,"./util":472}],387:[function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{l(r.next(e))}catch(e){o(e)}}function s(e){try{l(r.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},i=this&&this.__generator||function(e,t){var n,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}},o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a};function a(e,t,n,r){var i=[];return e.forEach((function(e){0!==r.length&&!r.includes(e.type)||0!==n.length&&!n.includes(e.kind)||"number"!=typeof e[t]||i.push(e[t])})),i}function s(e){return[{key:"transportId",type:"string"},{key:"candidateType",type:"string"},{key:"port",altKeys:["portNumber"],type:"number"},{key:"address",altKeys:["ip","ipAddress"],type:"string"},{key:"priority",type:"number"},{key:"protocol",altKeys:["transport"],type:"string"},{key:"url",type:"string"},{key:"relayProtocol",type:"string"}].reduce((function(t,n){var r=[n.key];n.altKeys&&(r=r.concat(n.altKeys));var i=r.find((function(t){return t in e}));return i&&typeof e[i]===n.type&&(t[n.key]=e[i]),t}),{})}Object.defineProperty(n,"__esModule",{value:!0}),n.getCombinedConnectionStats=void 0,n.getCombinedConnectionStats=function(e){var t=e.publisher,n=e.subscriber;return r(this,void 0,void 0,(function(){var e,r,l,c,u,p,f,d,h,m,y,b,v,g,w;return i(this,(function(i){switch(i.label){case 0:return[4,Promise.all([t,n].map((function(e){return e.getStats()})))];case 1:return e=o.apply(void 0,[i.sent(),2]),r=e[0],l=e[1],c=a(l,"timestamp",["audio"],["inbound-rtp"]),u=c.length>0?c[0]:0,p=a(l,"jitter",["audio"],["inbound-rtp"]).reduce((function(e,t){return Math.max(e,t)}),0),f=a(l,"packetsReceived",["audio","video"],["inbound-rtp"]).reduce((function(e,t){return e+t}),0),d=a(l,"packetsLost",["audio","video"],["inbound-rtp"]).reduce((function(e,t){return e+t}),0),h=a(r,"roundTripTime",["audio","video"],["remote-inbound-rtp"]).reduce((function(e,t){return Math.max(e,t)}),0),m=a(l,"currentRoundTripTime",[],["candidate-pair"]).reduce((function(e,t){return Math.max(e,t)}),0),y=1e3*(m||h),b=a(r,"bytesSent",[],["candidate-pair"]).reduce((function(e,t){return e+t}),0),v=a(l,"bytesReceived",[],["candidate-pair"]).reduce((function(e,t){return e+t}),0),g=function(e){var t=null,n=[];e.forEach((function(e){"transport"===e.type&&e.selectedCandidatePairId?t=e.selectedCandidatePairId:"candidate-pair"===e.type&&n.push(e)}));var r=n.find((function(e){return e.selected||t&&e.id===t}));if(!r)return null;var i=r,o=e.get(i.localCandidateId),a=e.get(i.remoteCandidateId);if(!o||!a)return null;return{localCandidate:s(o),remoteCandidate:s(a)}}(l),w=[],l.forEach((function(e){"local-candidate"!==e.type&&"remote-candidate"!==e.type||w.push(s(e))}
164)),[2,{timestamp:u,jitter:p,packets:f,packetsLost:d,roundTripTime:y,bytesSent:b,bytesReceived:v,selectedIceCandidatePairStats:g,iceCandidateStats:w}]}}))}))}},{}],388:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.getTurnCredentials=void 0;var r=e("../twilioconnection.js"),i=e("../util/constants").ICE_VERSION,o=e("../util/twilio-video-errors"),a=o.createTwilioError,s=o.SignalingConnectionError,l=e("events");n.getTurnCredentials=function(e,t){return new Promise((function(n,o){var c=new l.EventEmitter,u=new r(t,{networkMonitor:null,eventObserver:c,helloBody:{edge:"roaming",preflight:!0,token:e,type:"ice",version:i}}),p=!1;u.once("close",(function(){p||(p=!0,o(new s))})),u.on("message",(function(e){var t=e.code,r=e.message,i=e.ice_servers,s=e.type;"iced"!==s&&"error"!==s||p||(p=!0,"iced"===s?n(i):o(a(t,r)),u.close())}))}))}},{"../twilioconnection.js":460,"../util/constants":465,"../util/twilio-video-errors":487,events:222}],389:[function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e};Object.defineProperty(n,"__esModule",{value:!0}),n.makeStat=void 0,n.makeStat=function(e){return e&&e.length?{min:Math.min.apply(Math,i([],r(e))),max:Math.max.apply(Math,i([],r(e))),average:e.reduce((function(e,t){return e+t}),0)/e.length}:null}},{}],390:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.mosToScore=n.calculateMOS=void 0;n.calculateMOS=function(e,t,n){var r=e+2*t+10,i=0;switch(!0){case r<160:i=94.768-r/40;break;case r<1e3:i=94.768-(r-120)/10}switch(!0){case n<=i/2.5:i=Math.max(i-2.5*n,6.52);break;default:i=0}return 1+.035*i+7e-6*i*(i-60)*(100-i)},n.mosToScore=function(e){return e?e>4.2?5:e>4?4:e>3.6?3:e>3?2:1:0}},{}],391:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{l(r.next(e))}catch(e){o(e)}}function s(e){try{l(r.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},s=this&&this.__generator||function(e,t){var n,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}};Object.defineProperty(n,"__esModule",{value:!0}),n.runPreflight=n.PreflightTest=void 0;var l=e("../util/constants"),c=e("./timer"),u=e("./mos"),p=e("./getCombinedConnectionStats"),f=e("./getturncredentials"),d=e("./makestat"),h=e("./syntheticaudio"),m=e("./syntheticvideo"),y=e("../util/index"),b=e("../util/constants").WS_SERVER,v=e("../util/log"),g=e("../eventemitter"),w=e("../util/movingaveragedelta"),C=e("../util/eventobserver"),_=e("../util/insightspublisher"),k=e("../util/sid"),S=k.createSID,E=k.sessionSID,T=e("../util/twilio-video-errors"),O=T.SignalingConnectionTimeoutError,P=T.MediaConnectionError,R="mediaAcquired",x="connected",D="mediaSubscribed",j="mediaStarted",M="dtlsConnected",A="peerConnectionConnected",I="iceConnected";function N(e){return null!=e}var L=0,F=function(e){function t(t,n){var r=e.call(this)||this;r._testTiming=new c.Timer,r._dtlsTiming=new c.Timer,r._iceTiming=new c.Timer,r._peerConnectionTiming=new c.Timer,r._mediaTiming=new c.Timer,r._connectTiming=new c.Timer,r._sentBytesMovingAverage=new w,r._packetLossMovingAverage=new w,r._progressEvents=[],r._receivedBytesMovingAverage=new w;var i=n,o=i.environment,a=void 0===o?"prod":o,s=i.region,u=void 0===s?"gll":s,p=i.duration,f=void 0===p?1e4:p,d=i.wsServer||b(a,u);return r._log=new v("default",r,l.DEFAULT_LOG_LEVEL,l.DEFAULT_LOGGER_NAME),r._testDuration=f,r._instanceId=L++,r._testTiming.start(),r._runPreflightTest(t,a,d),r}return i(t,e),t.prototype.toString=function(){return"[Preflight #"+this._instanceId+"]"},t.prototype.stop=function(){this._stopped=!0},t.prototype._generatePreflightReport=function(e){return this._testTiming.stop(),{testTiming:this._testTiming.getTimeMeasurement(),networkTiming:{dtls:this._dtlsTiming.getTimeMeasurement(),ice:this._iceTiming.getTimeMeasurement(),peerConnection:this._peerConnectionTiming.getTimeMeasurement(),connect:this._connectTiming.getTimeMeasurement(),media:this._mediaTiming.getTimeMeasurement()},stats:{jitter:d.makeStat(null==e?void 0:e.jitter),rtt:d.makeStat(null==e?void 0:e.rtt),packetLoss:d.makeStat(null==e?void 0:e.packetLoss)},selectedIceCandidatePairStats:e?e.selectedIceCandidatePairStats:null,iceCandidateStats:e?e.iceCandidateStats:[],progressEvents:this._progressEvents,mos:d.makeStat(null==e?void 0:e.mos)}},t.prototype._executePreflightStep=function(e,t,n){return a(this,void 0,void 0,(function(){var r,i,o,a;return s(this,(function(s){switch(s.label){case 0:if(this._log.debug("Executing step: ",e),r=this._testDuration+1e4,this._stopped)throw new Error("stopped");i=Promise.resolve().then(t),o=null,a=new Promise((function(t,i){o=setTimeout((function(){i(n||new Error(e+" timeout."))}),r)})),s.label=1;case 1:return s.trys.push([1,,3,4]),[4,Promise.race([a,i])];case 2:return[2,s.sent()];case 3:return null!==o&&clearTimeout(o),[7];case 4:return[2]}}
164))}))},t.prototype._collectNetworkTimings=function(e){var t=this;return new Promise((function(n){var r;e.addEventListener("iceconnectionstatechange",(function(){"checking"===e.iceConnectionState&&t._iceTiming.start(),"connected"===e.iceConnectionState&&(t._iceTiming.stop(),t._updateProgress(I),(!r||r&&"connected"===r.state)&&n())})),e.addEventListener("connectionstatechange",(function(){"connecting"===e.connectionState&&t._peerConnectionTiming.start(),"connected"===e.connectionState&&(t._peerConnectionTiming.stop(),t._updateProgress(A))}));var i=e.getSenders().map((function(e){return e.transport})).find(N);void 0!==i&&(r=i).addEventListener("statechange",(function(){"connecting"===r.state&&t._dtlsTiming.start(),"connected"===r.state&&(t._dtlsTiming.stop(),t._updateProgress(M),"connected"===e.iceConnectionState&&n())}))}))},t.prototype._setupInsights=function(e){var t=e.token,n=e.environment,r=void 0===n?l.DEFAULT_ENVIRONMENT:n,i=e.realm,o=void 0===i?l.DEFAULT_REALM:i,a=new _(t,l.SDK_NAME,l.SDK_VERSION,r,o,{});a.connect("PREFLIGHT_ROOM_SID","PREFLIGHT_PARTICIPANT");var s=new C(a,Date.now(),this._log);return{reportToInsights:function(e){var t,n,r=e.report,i=r.stats.jitter||void 0,o=r.stats.rtt||void 0,l=r.stats.packetLoss||void 0,c=r.mos||void 0,u=new Map;
164r.iceCandidateStats.forEach((function(e){if(e.candidateType&&e.protocol){var t=u.get(e.candidateType)||[];t.indexOf(e.protocol)<0&&t.push(e.protocol),u.set(e.candidateType,t)}}));var p=JSON.stringify(Object.fromEntries(u)),f={name:"report",group:"preflight",level:r.error?"error":"info",payload:{sessionSID:E,preflightSID:S("PF"),progressEvents:JSON.stringify(r.progressEvents),testTiming:r.testTiming,dtlsTiming:r.networkTiming.dtls,iceTiming:r.networkTiming.ice,peerConnectionTiming:r.networkTiming.peerConnection,connectTiming:r.networkTiming.connect,mediaTiming:r.networkTiming.media,selectedLocalCandidate:null===(t=r.selectedIceCandidatePairStats)||void 0===t?void 0:t.localCandidate,selectedRemoteCandidate:null===(n=r.selectedIceCandidatePairStats)||void 0===n?void 0:n.remoteCandidate,iceCandidateStats:p,jitterStats:i,rttStats:o,packetLossStats:l,mosStats:c,error:r.error}};s.emit("event",f),setTimeout((function(){return a.disconnect()}),2e3)}}},t.prototype._runPreflightTest=function(e,t,n){return a(this,void 0,void 0,(function(){var r,i,l,c,u,p,d,y,b,v,g,w,C=this;return s(this,(function(_){switch(_.label){case 0:r=[],i=[],l=this._setupInsights({token:e,environment:t}).reportToInsights,_.label=1;case 1:return _.trys.push([1,8,9,10]),c=[],[4,this._executePreflightStep("Acquire media",(function(){return[h.syntheticAudio(),m.syntheticVideo({width:640,height:480})]}))];case 2:return r=_.sent(),this._updateProgress(R),this.emit("debug",{localTracks:r}),this._connectTiming.start(),[4,this._executePreflightStep("Get turn credentials",(function(){return f.getTurnCredentials(e,n)}),new O)];case 3:return u=_.sent(),this._connectTiming.stop(),this._updateProgress(x),p=new RTCPeerConnection({iceServers:u,iceTransportPolicy:"relay",bundlePolicy:"max-bundle"}),d=new RTCPeerConnection({iceServers:u,bundlePolicy:"max-bundle"}),i.push(p),i.push(d),this._mediaTiming.start(),[4,this._executePreflightStep("Setup Peer Connections",(function(){return a(C,void 0,void 0,(function(){var e,t,n,i;return s(this,(function(o){switch(o.label){case 0:return p.addEventListener("icecandidate",(function(e){return e.candidate&&d.addIceCandidate(e.candidate)})),d.addEventListener("icecandidate",(function(e){return e.candidate&&p.addIceCandidate(e.candidate)})),r.forEach((function(e){return p.addTrack(e)})),e=new Promise((function(e){var t=[];d.addEventListener("track",(function(n){t.push(n.track),t.length===r.length&&e(t)}))})),[4,p.createOffer()];case 1:return t=o.sent(),n=t,[4,p.setLocalDescription(n)];case 2:return o.sent(),[4,d.setRemoteDescription(n)];case 3:return o.sent(),[4,d.createAnswer()];case 4:return i=o.sent(),[4,d.setLocalDescription(i)];case 5:return o.sent(),[4,p.setRemoteDescription(i)];case 6:return o.sent(),[4,this._collectNetworkTimings(p)];case 7:return o.sent(),[2,e]}}))}))}),new P)];case 4:return y=_.sent(),this.emit("debug",{remoteTracks:y}),y.forEach((function(e){e.addEventListener("ended",(function(){return C._log.warn(e.kind+":ended")})),e.addEventListener("mute",(function(){return C._log.warn(e.kind+":muted")})),e.addEventListener("unmute",(function(){return C._log.warn(e.kind+":unmuted")}))})),this._updateProgress(D),[4,this._executePreflightStep("Wait for tracks to start",(function(){return new Promise((function(e){var t=document.createElement("video");t.autoplay=!0,t.playsInline=!0,t.muted=!0,t.srcObject=new MediaStream(y),c.push(t),C.emit("debugElement",t),t.oncanplay=e}))}),new P)];case 5:return _.sent(),this._mediaTiming.stop(),this._updateProgress(j),[4,this._executePreflightStep("Collect stats for duration",(function(){return C._collectRTCStatsForDuration(C._testDuration,{mos:[],jitter:[],rtt:[],outgoingBitrate:[],incomingBitrate:[],packetLoss:[],selectedIceCandidatePairStats:null,iceCandidateStats:[]},p,d)}))];case 6:return b=_.sent(),[4,this._executePreflightStep("Generate report",(function(){return C._generatePreflightReport(b)}))];case 7:return v=_.sent(),l({report:v}),this.emit("completed",v),[3,10];case 8:return g=_.sent(),w=this._generatePreflightReport(),l({report:o(o({},w),{error:null==g?void 0:g.toString()})}
164),this.emit("failed",g,w),[3,10];case 9:return i.forEach((function(e){return e.close()})),r.forEach((function(e){return e.stop()})),[7];case 10:return[2]}}))}))},t.prototype._collectRTCStats=function(e,t,n){return a(this,void 0,void 0,(function(){var r,i,o,a,l,c,f,d,h,m,y,b,v,g;return s(this,(function(s){switch(s.label){case 0:return[4,p.getCombinedConnectionStats({publisher:t,subscriber:n})];case 1:return r=s.sent(),i=r.timestamp,o=r.bytesSent,a=r.bytesReceived,l=r.packets,c=r.packetsLost,f=r.roundTripTime,d=r.jitter,h=r.selectedIceCandidatePairStats,m=r.iceCandidateStats,y=e.jitter.length>0,e.jitter.push(d),e.rtt.push(f),this._sentBytesMovingAverage.putSample(o,i),this._receivedBytesMovingAverage.putSample(a,i),this._packetLossMovingAverage.putSample(c,l),y&&(e.outgoingBitrate.push(1e3*this._sentBytesMovingAverage.get()*8),e.incomingBitrate.push(1e3*this._receivedBytesMovingAverage.get()*8),b=this._packetLossMovingAverage.get(),v=Math.min(100,100*b),e.packetLoss.push(v),g=u.calculateMOS(f,d,b),e.mos.push(g)),e.selectedIceCandidatePairStats||(e.selectedIceCandidatePairStats=h),0===e.iceCandidateStats.length&&(e.iceCandidateStats=m),[2]}}))}))},t.prototype._collectRTCStatsForDuration=function(e,t,n,r){return a(this,void 0,void 0,(function(){var i,o,a;return s(this,(function(s){switch(s.label){case 0:return i=Date.now(),o=Math.min(1e3,e),[4,y.waitForSometime(o)];case 1:return s.sent(),[4,this._collectRTCStats(t,n,r)];case 2:return s.sent(),(a=e-(Date.now()-i))>0?[4,this._collectRTCStatsForDuration(a,t,n,r)]:[3,4];case 3:t=s.sent(),s.label=4;case 4:return[2,t]}}))}))},t.prototype._updateProgress=function(e){var t=Date.now()-this._testTiming.getTimeMeasurement().start;this._progressEvents.push({duration:t,name:e}),this.emit("progress",e)},t}(g);n.PreflightTest=F,n.runPreflight=function(e,t){return void 0===t&&(t={}),new F(e,t)}},{"../eventemitter":350,"../util/constants":465,"../util/eventobserver":470,"../util/index":472,"../util/insightspublisher":473,"../util/log":476,"../util/movingaveragedelta":477,"../util/sid":484,"../util/twilio-video-errors":487,"./getCombinedConnectionStats":387,"./getturncredentials":388,"./makestat":389,"./mos":390,"./syntheticaudio":392,"./syntheticvideo":393,"./timer":394}],392:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.syntheticAudio=void 0,n.syntheticAudio=function(){var t=e("../webaudio/audiocontext"),n={},r=t.getOrCreate(n),i=r.createOscillator(),o=i.connect(r.createMediaStreamDestination());i.start();var a=o.stream.getAudioTracks()[0],s=a.stop;return a.stop=function(){s.call(a),t.release(n)},a}},{"../webaudio/audiocontext":493}],393:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.syntheticVideo=void 0,n.syntheticVideo=function(e){var t=void 0===e?{}:e,n=t.width,r=void 0===n?640:n,i=t.height,o=void 0===i?480:i,a=Object.assign(document.createElement("canvas"),{width:r,height:o}),s=a.getContext("2d");s.fillStyle="green",s.fillRect(0,0,a.width,a.height);var l=!1;requestAnimationFrame((function e(){if(!l){var t=Math.round(255*Math.random()),n=Math.round(255*Math.random()),i=Math.round(255*Math.random()),a=Math.round(255*Math.random());s.fillStyle="rgba("+t+", "+n+", "+i+", "+a+")",s.fillRect(Math.random()*r,Math.random()*o,50,50),requestAnimationFrame(e)}}));var c=a.captureStream(30).getTracks()[0],u=c.stop;return c.stop=function(){l=!0,u.call(c)},c}},{}],394:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.Timer=void 0;var r=function(){function e(){this._end=void 0,this.start()}return e.prototype.start=function(){return this._start=Date.now(),this},e.prototype.stop=function(){return this._end=Date.now(),this},e.prototype.getTimeMeasurement=function(){return{start:this._start,end:this._end,duration:void 0===this._end?void 0:this._end-this._start}},e}();n.Timer=r},{}],395:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=function(e){function t(){var t=e.call(this)||this;return Object.defineProperties(t,{_queuedEvents:{value:new Map}}),t}return i(t,e),t.prototype.dequeue=function(e){var t=this,n=!0;
164if(!e)return this._queuedEvents.forEach((function(e,t){n=this.dequeue(t)&&n}),this),n;var r=this._queuedEvents.get(e)||[];return this._queuedEvents.delete(e),r.reduce((function(n,r){return t.emit.apply(t,a([],o([e].concat(r))))&&n}),n)},t.prototype.queue=function(){var e=[].slice.call(arguments);if(this.emit.apply(this,a([],o(e))))return!0;var t=e[0];return this._queuedEvents.has(t)||this._queuedEvents.set(t,[]),this._queuedEvents.get(t).push(e.slice(1)),!1},t}(e("events").EventEmitter);t.exports=s},{events:222}],396:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r._handleTrackSignalingEvents(),r.once("disconnected",r._unsubscribeTracks.bind(r)),r}return i(t,e),t.prototype.toString=function(){return"[RemoteParticipant #"+this._instanceId+(this.sid?": "+this.sid:"")+"]"},t.prototype._addTrack=function(t,n,r){return e.prototype._addTrack.call(this,t,r)?(n._subscribed(t),this.emit("trackSubscribed",t,n),t):null},t.prototype._addTrackPublication=function(t){var n=e.prototype._addTrackPublication.call(this,t);return n?(this.emit("trackPublished",n),n):null},t.prototype._getTrackPublicationEvents=function(){return a(a([],o(e.prototype._getTrackPublicationEvents.call(this))),[["subscriptionFailed","trackSubscriptionFailed"],["trackDisabled","trackDisabled"],["trackEnabled","trackEnabled"],["publishPriorityChanged","trackPublishPriorityChanged"],["trackSwitchedOff","trackSwitchedOff"],["trackSwitchedOn","trackSwitchedOn"]])},t.prototype._unsubscribeTracks=function(){var e=this;this.tracks.forEach((function(t){if(t.isSubscribed){var n=t.track;t._unsubscribe(),e.emit("trackUnsubscribed",n,t)}}))},t.prototype._removeTrack=function(t,n,r){var i=this._tracks.get(r);return i?(e.prototype._removeTrack.call(this,i,r),n._unsubscribe(),this.emit("trackUnsubscribed",i,n),i):null},t.prototype._removeTrackPublication=function(t){this._signaling.clearTrackHint(t.trackSid);var n=e.prototype._removeTrackPublication.call(this,t);return n?(this.emit("trackUnpublished",n),n):null},t}(e("./participant"));t.exports=s},{"./participant":386}],397:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("./eventemitter"),l=e("./remoteparticipant"),c=e("./stats/statsreport"),u=e("./util"),p=u.flatMap,f=u.valueToJSON,d=0,h=function(e){function t(t,n,r){var i,s,l=e.call(this)||this,c=r.log.createLog("default",l),u=new Map;return Object.defineProperties(l,{_log:{value:c},_clientTrackSwitchOffControl:{value:r.clientTrackSwitchOffControl||"disabled"}
164,_contentPreferencesMode:{value:r.contentPreferencesMode||"disabled"},_instanceId:{value:++d},_options:{value:r},_participants:{value:u},_signaling:{value:n},dominantSpeaker:{enumerable:!0,get:function(){return this.participants.get(n.dominantSpeakerSid)||null}},isRecording:{enumerable:!0,get:function(){return n.recording.isEnabled||!1}},localParticipant:{enumerable:!0,value:t},name:{enumerable:!0,value:n.name},participants:{enumerable:!0,value:u},sid:{enumerable:!0,value:n.sid},state:{enumerable:!0,get:function(){return n.state}},mediaRegion:{enumerable:!0,value:n.mediaRegion}}),function(e,t){var n=["trackWarning","trackWarningsCleared"].map((function(n){return{eventName:n,handler:function(){for(var r=[],i=0;i<arguments.length;i++)r[i]=arguments[i];return e.emit.apply(e,a([n],o(a(a([],o(r)),[t]))))}}}));n.forEach((function(e){var n=e.eventName,r=e.handler;return t.on(n,r)})),e.once("disconnected",(function(){return n.forEach((function(e){var n=e.eventName,r=e.handler;return t.removeListener(n,r)}))}))}(l,t),i=l,(s=n.recording).on("updated",(function(){var e=s.isEnabled;i._log.info("Recording "+(e?"started":"stopped")),i.emit("recording"+(e?"Started":"Stopped"))})),function(e,t){var n=e._log;n.debug("Creating a new RemoteParticipant for each ParticipantSignaling in the RoomSignaling"),t.participants.forEac
164h(y.bind(null,e)),n.debug("Setting up RemoteParticipant creation for all subsequent ParticipantSignalings that connect to the RoomSignaling"),t.on("participantConnected",y.bind(null,e)),t.on("dominantSpeakerChanged",(function(){return e.emit("dominantSpeakerChanged",e.dominantSpeaker)})),t.on("stateChanged",(function r(i,o){switch(n.info("Transitioned to state:",i),i){case"disconnected":e.participants.forEach((function(e){e._unsubscribeTracks()})),e.emit(i,e,o),e.localParticipant.tracks.forEach((function(e){e.unpublish()})),t.removeListener("stateChanged",r);break;case"reconnecting":setTimeout((function(){return e.emit("reconnecting",o)}),0);break;default:setTimeout((function(){return e.emit("reconnected")}),0)}}))}(l,n),function(e){var t=e.localParticipant._signaling.audioProcessors;e.localParticipant.audioTracks.forEach((function(n){var r=n.track.noiseCancellation;r&&!t.includes(r.vendor)&&(e._log.warn(r.vendor+" is not supported in this room. disabling it permanently"),r.disablePermanently())}))}(l),c.info("Created a new Room:",l.name),c.debug("Initial RemoteParticipants:",Array.from(l._participants.values())),l}return i(t,e),t.prototype.toString=function(){return"[Room #"+this._instanceId+": "+this.sid+"]"},t.prototype.disconnect=function(){return this._log.info("Disconnecting"),this._signaling.disconnect(),this},t.prototype.getStats=function(){var e=this;return this._signaling.getStats().then((function(t){return Array.from(t).map((function(t){var n=o(t,2),r=n[0],i=n[1];return new c(r,Object.assign({},i,{localAudioTrackStats:m(e,i.localAudioTrackStats),localVideoTrackStats:m(e,i.localVideoTrackStats)}))}))}))},t.prototype.refreshInactiveMedia=function(){var e=this.localParticipant.tracks,t=Array.from(e.values()).filter((function(e){return"data"!==e.track.kind})).map((function(e){return e.track})),n=p(this.participants,(function(e){return Array.from(e.tracks.values())})).filter((function(e){var t=e.track;return t&&"data"!==t.kind})).map((function(e){return e.track})),r=t.concat(n),i=new Event("unmute");t.forEach((function(e){var t=e.isMuted,n=e.mediaStreamTrack;t&&n.dispatchEvent(i)}));var o=new Event("pause");return r.forEach((function(e){var t=e._attachments,n=e._elShims;return t.forEach((function(e){var t=n.get(e);e.paused&&t&&!t.pausedIntentionally()&&e.dispatchEvent(o)}))})),this},t.prototype.toJSON=function(){return f(this)},t}(s);function m(e,t){var n=e.localParticipant._signaling;return t.reduce((function(e,t){var r=n.tracks.get(t.trackId),i=n.getSender(r);return i?[Object.assign({},t,{trackId:i.id})].concat(e):e}),[])}function y(e,t){var n=e._log,r=e._clientTrackSwitchOffControl,i=e._contentPreferencesMode,s=new l(t,{log:n,
164clientTrackSwitchOffControl:r,contentPreferencesMode:i});n.info("A new RemoteParticipant connected:",s),e._participants.set(s.sid,s),e.emit("participantConnected",s);var c=[["reconnected","participantReconnected"],["reconnecting","participantReconnecting"],"trackDimensionsChanged","trackDisabled","trackEnabled","trackMessage","trackPublished","trackPublishPriorityChanged","trackStarted","trackSubscribed","trackSubscriptionFailed","trackSwitchedOff","trackSwitchedOn","trackUnpublished","trackUnsubscribed"].map((function(t){var n=o(Array.isArray(t)?t:[t,t],2),r=n[0],i=n[1];function l(){var t=[].slice.call(arguments);t.unshift(i),t.push(s),e.emit.apply(e,a([],o(t)))}return s.on(r,l),[r,l]}));s.once("disconnected",(function(){var t=e.dominantSpeaker;n.info("RemoteParticipant disconnected:",s),e._participants.delete(s.sid),c.forEach((function(e){s.removeListener(e[0],e[1])})),e.emit("participantDisconnected",s),s===t&&e.emit("dominantSpeakerChanged",e.dominantSpeaker)}))}t.exports=h},{"./eventemitter":350,"./remoteparticipant":396,"./stats/statsreport":456,"./util":472}],398:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./participant"),a=e("./room"),s=e("../statemachine"),l={closed:["opening"],opening:["closed","open"],open:["closed","closing"],closing:["closed","open"]},c=function(e){function t(){return e.call(this,"closed",l)||this}return i(t,e),t.prototype._close=function(e){return this.transition("closing",e),this.transition("closed",e),Promise.resolve(this)},t.prototype._connect=function(e,t,n,r,i){e.connect("PA00000000000000000000000000000000","test");var o=Promise.resolve(new a(e,"RM00000000000000000000000000000000",i));return o.cancel=function(){},o},t.prototype._open=function(e){return this.transition("opening",e),this.transition("open",e),Promise.resolve(this)},t.prototype.close=function(){var e=this;return this.bracket("close",(function(t){switch(e.state){case"closed":return e;case"open":return e._close(t);default:throw new Error('Unexpected Signaling state "'+e.state+'"')}}))},t.prototype.connect=function(e,t,n,r,i){var o=this;return this.bracket("connect",(function a(s){switch(o.state){case"closed":return o._open(s).then(a.bind(null,s));case"open":return o.releaseLockCompletely(s),o._connect(e,t,n,r,i);default:throw new Error('Unexpected Signaling state "'+o.state+'"')}}))},t.prototype.createLocalParticipantSignaling=function(){return new o},t.prototype.open=function(){var e=this;return this.bracket("open",(function(t){switch(e.state){case"closed":return e._open(t);case"open":return e;default:throw new Error('Unexpected Signaling state "'+e.state+'"')}}))},t}(s);t.exports=c},{"../statemachine":428,"./participant":401,"./room":405}],399:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(){var t=e.call(this)||this;return Object.defineProperties(t,{_publicationsToTrackSenders:{value:new Map},_trackSendersToPublications:{value:new Map}}),t}return i(t,e),t.prototype.addTrack=function(t,n,r,i){void 0===i&&(i=null);var o=this._createLocalTrackPublicationSignaling(t,n,r,i);return this._trackSendersToPublications.set(t,o),this._publicationsToTrackSenders.set(o,t),e.prototype.addTrack.call(this,o),this},t.prototype.getPublication=function(e){return this._trackSendersToPublications.get(e)||null},t.prototype.getSender=function(e){return this._publicationsToTrackSenders.get(e)||null},t.prototype.removeTrack=function(t){var n=this._trackSendersToPublications.get(t);return n?(this._trackSendersToPublications.delete(t),this._publicationsToTrackSenders.delete(n),e.prototype.removeTrack.call(this,n)&&n.stop(),n):null},t}(e("./participant"));t.exports=o},{"./participant":401}],400:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r){var i=this,o="data"===(t=t.clone()).kind||t.track.enabled;return(i=e.call(this,n,t.kind,o,r)||this).setTrackTransceiver(t),Object.defineProperties(i,{_updatedPriority:{value:r,writable:!0},id:{enumerable:!0,value:t.id}}),i}return i(t,e),Object.defineProperty(t.prototype,"updatedPriority",{get:function(){return this._updatedPriority}
164,enumerable:!1,configurable:!0}),t.prototype.enable=function(t){return t="boolean"!=typeof t||t,this.trackTransceiver.track.enabled=t,e.prototype.enable.call(this,t)},t.prototype.publishFailed=function(e){return function(e,t){if(null!==e._sid||e._error)return!1;return e._error=t,!0}(this,e)&&this.emit("updated"),this},t.prototype.setPriority=function(e){return this._updatedPriority!==e&&(this._updatedPriority=e,this.emit("updated")),this},t.prototype.setSid=function(t){return this._error?this:e.prototype.setSid.call(this,t)},t.prototype.stop=function(){this.trackTransceiver.stop()},t}(e("./track"));t.exports=o},{"./track":406}],401:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../statemachine"),a=e("../stats/networkqualitystats"),s={connecting:["connected"],connected:["disconnected","reconnecting"],reconnecting:["connected","disconnected"],disconnected:[]},l=function(e){function t(){var t=e.call(this,"connecting",s)||this;return Object.defineProperties(t,{_identity:{writable:!0,value:null},_networkQualityLevel:{value:null,writable:!0},_networkQualityStats:{value:null,writable:!0},_sid:{writable:!0,value:null},identity:{enumerable:!0,get:function(){return this._identity}},sid:{enumerable:!0,get:function(){return this._sid}},tracks:{enumerable:!0,value:new Map}}),t}return i(t,e),Object.defineProperty(t.prototype,"networkQualityLevel",{get:function(){return this._networkQualityLevel},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"networkQualityStats",{get:function(){return this._networkQualityStats},enumerable:!1,configurable:!0}),t.prototype.addTrack=function(e){return this.tracks.set(e.id||e.sid,e),this.emit("trackAdded",e),this},t.prototype.disconnect=function(){return"disconnected"!==this.state&&(this.preempt("disconnected"),!0)},t.prototype.removeTrack=function(e){var t=this.tracks.get(e.id||e.sid);return this.tracks.delete(e.id||e.sid),t&&this.emit("trackRemoved",e),t||null},t.prototype.setNetworkQualityLevel=function(e,t){this._networkQualityLevel!==e&&(this._networkQualityLevel=e,this._networkQualityStats=t&&(t.audio||t.video)?new a(t):null,this.emit("networkQualityLevelChanged"))},t.prototype.connect=function(e,t){return("connecting"===this.state||"reconnecting"===this.state)&&(this._sid||(this._sid=e),this._identity||(this._identity=t),this.preempt("connected"),!0)},t.prototype.reconnecting=function(){return("connecting"===this.state||"connected"===this.state)&&(this.preempt("reconnecting"),!0)},t}(o);t.exports=l},{"../statemachine":428,"../stats/networkqualitystats":443}],402:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(){var t=e.call(this)||this;return Object.defineProperties(t,{_isEnabled:{value:null,writable:!0},isEnabled:{enumerable:!0,get:function(){return this._isEnabled}}}),t}return i(t,e),t.prototype.disable=function(){return this.enable(!1)},t.prototype.enable=function(e){return e="boolean"!=typeof e||e,this.isEnabled!==e&&(this._isEnabled=e,this.emit("updated")),this},t}(e("events").EventEmitter);t.exports=o},{events:222}],403:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this)||this;return r.connect(t,n),r}return i(t,e),t}(e("./participant"));t.exports=o},{"./participant":401}],404:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r,i,o,a){var s=e.call(this,n,r,i,o)||this;return Object.defineProperties(s,{_isSwitchedOff:{value:a,writable:!0}}),s.setSid(t),s}return i(t,e),Object.defineProperty(t.prototype,"isSubscribed",{get:function(){return!!this.trackTransceiver}
164,enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isSwitchedOff",{get:function(){return this._isSwitchedOff},enumerable:!1,configurable:!0}),t.prototype.subscribeFailed=function(e){return this.error||(this._error=e,this.emit("updated")),this},t.prototype.setPriority=function(e){return this._priority!==e&&(this._priority=e,this.emit("updated")),this},t.prototype.setSwitchedOff=function(e){return this._isSwitchedOff!==e&&(this._isSwitchedOff=e,this.emit("updated")),this},t}(e("./track"));t.exports=o},{"./track":406}],405:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./recording"),a=e("../statemachine"),s=e("../util/timeout"),l=e("../util").buildLogLevels,c=e("../util/constants").DEFAULT_LOG_LEVEL,u=e("../util/log"),p=e("../util/twilio-video-errors"),f=p.MediaConnectionError,d=p.MediaDTLSTransportFailedError,h=p.SignalingConnectionDisconnectedError,m=0,y={connected:["reconnecting","disconnected"],reconnecting:["connected","disconnected"],disconnected:[]},b=function(e){function t(t,n,r,i){var a=this;i=Object.assign({logLevel:c,RecordingSignaling:o,Timeout:s},i);var p=l(i.logLevel);a=e.call(this,"connected",y)||this;var f=i.RecordingSignaling,h=new i.Timeout((function(){a._disconnect(a._reconnectingError)}),i.sessionTimeout,!1);return Object.defineProperties(a,{_instanceId:{value:m++},_log:{value:i.log?i.log.createLog("default",a):new u("default",a,p,i.loggerName)},_mediaConnectionIsReconnecting:{writable:!0,value:!1},_options:{value:i},_reconnectingError:{value:null,writable:!0},_sessionTimeout:{value:h},dominantSpeakerSid:{enumerable:!0,value:null,writable:!0},localParticipant:{enumerable:!0,value:t},name:{enumerable:!0,value:r},participants:{enumerable:!0,value:new Map},recording:{enumerable:!0,value:new f},sid:{enumerable:!0,value:n}}),a.on("connectionStateChanged",(function(){"failed"!==a.connectionState||["disconnected","failed"].includes(a.iceConnectionState)||a._disconnect(new d)})),a.on("iceConnectionStateChanged",(function(){return v(a)})),a.on("signalingConnectionStateChanged",(function(){return v(a)})),setTimeout((function(){return v(a)})),a}return i(t,e),t.prototype._disconnect=function(e){return"disconnected"!==this.state&&(this.preempt("disconnected",null,[e]),!0)},t.prototype.toString=function(){return"[RoomSignaling #"+this._instanceId+": "+(this.localParticipant?this.localParticipant.sid:"null")+"]"},t.prototype.connectParticipant=function(e){var t=this;return"disconnected"!==e.state&&(!this.participants.has(e.sid)&&(this.participants.set(e.sid,e),e.on("stateChanged",(function n(r){"disconnected"===r&&(e.removeListener("stateChanged",n),t.participants.delete(e.sid),t.emit("participantDisconnected",e))})),this.emit("participantConnected",e),!0))},t.prototype.disconnect=function(){return this._disconnect()},t.prototype.setDominantSpeaker=function(e){this.dominantSpeakerSid=e,this.emit("dominantSpeakerChanged")},t}(a);function v(e){var t;"disconnected"!==e.state&&"disconnected"!==e.signalingConnectionState?("reconnecting"===e.signalingConnectionState?t=e.signalingConnectionState:"failed"===e.iceConnectionState?(e._mediaConnectionIsReconnecting=!0,t="reconnecting"):"new"===e.iceConnectionState||"checking"===e.iceConnectionState?t=e._mediaConnectionIsReconnecting?"reconnecting":"connected":(e._mediaConnectionIsReconnecting=!1,e._reconnectingError=null,e._sessionTimeout.clear(),t="connected"),t!==e.state&&("reconnecting"===t?(e._reconnectingError="reconnecting"===e.signalingConnectionState?new h:new f,e._sessionTimeout.start(),e.preempt(t,null,[e._reconnectingError])):e.preempt(t))):e._sessionTimeout.clear()}t.exports=b},{"../statemachine":428,"../util":472,"../util/constants":465,"../util/log":476,"../util/timeout":486,"../util/twilio-video-errors":487,"./recording":402}],406:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r,i){var o=e.call(this)||this,a=null;return Object.defineProperties(o,{_error:{value:null,writable:!0},_isEnabled:{value:r,writable:!0},_priority:{value:i,writable:!0},_trackTransceiver:{value:null,writable:!0},_sid:{get:function(){return a}
164,set:function(e){null===a&&(a=e)}},kind:{enumerable:!0,value:n},name:{enumerable:!0,value:t}}),o}return i(t,e),Object.defineProperty(t.prototype,"error",{get:function(){return this._error},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isEnabled",{get:function(){return this._isEnabled},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"priority",{get:function(){return this._priority},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"sid",{get:function(){return this._sid},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"trackTransceiver",{get:function(){return this._trackTransceiver},enumerable:!1,configurable:!0}),t.prototype.disable=function(){return this.enable(!1)},t.prototype.enable=function(e){return e="boolean"!=typeof e||e,this.isEnabled!==e&&(this._isEnabled=e,this.emit("updated")),this},t.prototype.setTrackTransceiver=function(e){return e=e||null,this.trackTransceiver!==e&&(this._trackTransceiver=e,this.emit("updated")),this},t.prototype.setSid=function(e){return null===this.sid&&(this._sid=e,this.emit("updated")),this},t}(e("events").EventEmitter);t.exports=o},{events:222}],407:[function(e,t,n){"use strict";var r=e("../../util/cancelablepromise"),i=e("./peerconnectionmanager"),o=e("./room"),a=e("./twilioconnectiontransport"),s=e("../../util/twilio-video-errors"),l=s.SignalingConnectionDisconnectedError,c=s.SignalingIncomingMessageInvalidError,u=e("../../util"),p=u.flatMap,f=u.createRoomConnectEventPayload;t.exports=function(e,t,n,s,u,d){d=Object.assign({PeerConnectionManager:i,RoomV2:o,Transport:a},d);var h=u.video[0]&&!0===u.video[0].adaptiveSimulcast,m=d.PeerConnectionManager,y=d.RoomV2,b=d.Transport,v=d.iceServers,g=d.log,w=new m(s,u,d),C=p(n.tracks,(function(e){return[e.trackTransceiver]}));w.setTrackSenders(C);var _,k=new Error("Canceled"),S=new r((function(r,i,o){var a=d.automaticSubscription,s=d.bandwidthProfile,u=d.dominantSpeaker,p=d.environment,m=d.eventObserver,C=d.loggerName,S=d.logLevel,E=d.name,T=d.networkMonitor,O=d.networkQuality,P=d.notifyWarnings,R=d.realm,x=d.sdpSemantics,D=!!s,j=!!s,M=!!s&&("disabled"!==d.clientTrackSwitchOffControl||"disabled"!==d.contentPreferencesMode),A=Object.assign({adaptiveSimulcast:h,automaticSubscription:a,dominantSpeaker:u,environment:p,eventObserver:m,loggerName:C,logLevel:S,networkMonitor:T,networkQuality:O,notifyWarnings:P,iceServers:v,onIced:function(e){return o()?(i(k),Promise.reject(k)):(g.debug("Got ICE servers:",e),d.iceServers=e,w.setConfiguration(d),w.createAndOffer().then((function(){if(o())throw i(k),k;g.debug("createAndOffer() succeeded."),w.dequeue("description")})).catch((function(e){throw g.error("createAndOffer() failed:",e),i(e),e})))},realm:R,renderHints:M,sdpSemantics:x,trackPriority:D,trackSwitchOff:j},s?{bandwidthProfile:s}:{});_=new b(E,e,n,w,t,A);var I=f(d);m.emit("event",I),_.once("connected",(function(e){(g.debug("Transport connected:",e),o())?i(k):e.participant?r(new y(n,e,_,w,d)):i(new c)})),_.once("stateChanged",(function(e,t){"disconnected"===e?(_=null,i(t||new l)):g.debug("Transport state changed:",e)}))}),(function(){_&&(_.disconnect(),_=null)}));return S.catch((function(){_&&(_.disconnect(),_=null),w.close()})),S}},{"../../util":472,"../../util/cancelablepromise":464,"../../util/twilio-video-errors":487,"./peerconnectionmanager":418,"./room":424,"./twilioconnectiontransport":427}],408:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this,t,"active_speaker",n)||this;return Object.defineProperties(r,{_loudestParticipantSid:{value:null,writable:!0}}),r.on("ready",(function(e){e.on("message",(function(e){switch(e.type){case"active_speaker":r._setLoudestParticipantSid(e.participant)}}))})),r}return i(t,e),Object.defineProperty(t.prototype,"loudestParticipantSid",{get:function(){return this._loudestParticipantSid}
164,enumerable:!1,configurable:!0}),t.prototype._setLoudestParticipantSid=function(e){this.loudestParticipantSid!==e&&(this._loudestParticipantSid=e,this.emit("updated"))},t}(e("./mediasignaling"));t.exports=o},{"./mediasignaling":414}],409:[function(e,t,n){"use strict";var r=e("../../util/filter"),i=function(){function e(){Object.defineProperties(this,{_filter:{value:new r({getKey:function(e){return e.ufrag},isLessThanOrEqualTo:function(e,t){return e.revision<=t.revision}})},_ufrag:{writable:!0,value:null},ufrag:{enumerable:!0,get:function(){return this._ufrag}}})}return e.prototype.setUfrag=function(e){this._ufrag=e;var t=this._filter.toMap().get(e);return t?t.candidates:[]},e.prototype.update=function(e){e.candidates=e.candidates||[];var t=this._filter.toMap().get(e.ufrag),n=t?t.candidates:[];return this._filter.update(e)&&this._ufrag===e.ufrag?e.candidates.slice(n.length):[]},e}();t.exports=i},{"../../util/filter":471}],410:[function(e,t,n){"use strict";var r=e("../../util/constants"),i=r.ICE_ACTIVITY_CHECK_PERIOD_MS,o=r.ICE_INACTIVITY_THRESHOLD_MS,a=function(){function e(e,t){t=Object.assign({activityCheckPeriodMs:i,inactivityThresholdMs:o},t),Object.defineProperties(this,{_activityCheckPeriodMs:{value:t.activityCheckPeriodMs},_inactivityThresholdMs:{value:t.inactivityThresholdMs},_lastActivity:{value:null,writable:!0},_peerConnection:{value:e},_timer:{value:null,writable:!0},_onIceConnectionStateChanged:{value:null,writable:!0}})}return e.prototype._getActivePairStat=function(e){return Array.from(e.values()).find((function(e){return"candidate-pair"===e.type&&e.nominated}))||{bytesReceived:0,timestamp:Math.round((new Date).getTime())}},e.prototype._getIceConnectionStats=function(){var e=this;return this._peerConnection.getStats().then((function(t){return e._getActivePairStat(t)})).catch((function(){return null}))},e.prototype._scheduleInactivityCallback=function(e){var t=this;e&&null===this._onIceConnectionStateChanged?(this._onIceConnectionStateChanged=function(){"disconnected"===t._peerConnection.iceConnectionState&&e()},this._peerConnection.addEventListener("iceconnectionstatechange",this._onIceConnectionStateChanged)):!e&&this._onIceConnectionStateChanged&&(this._peerConnection.removeEventListener("iceconnectionstatechange",this._onIceConnectionStateChanged),this._onIceConnectionStateChanged=null)},e.prototype.start=function(e){var t=this;this.stop(),this._timer=setInterval((function(){t._getIceConnectionStats().then((function(n){n&&(t._lastActivity&&t._lastActivity.bytesReceived===n.bytesReceived||(t._lastActivity=n,t._scheduleInactivityCallback(null)),n.timestamp-t._lastActivity.timestamp>=t._inactivityThresholdMs&&("disconnected"===t._peerConnection.iceConnectionState?e():null===t._onIceConnectionStateChanged&&t._scheduleInactivityCallback(e)))}))}),this._activityCheckPeriodMs)},e.prototype.stop=function(){this._scheduleInactivityCallback(null),null!==this._timer&&(clearInterval(this._timer),this._timer=null,this._lastActivity=null)},e}();t.exports=a},{"../../util/constants":465}],411:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./cancelableroomsignalingpromise"),a=e("./localparticipant"),s=function(e){function t(t,n){var r;return n=Object.assign({createCancelableRoomSignalingPromise:o},n),r=e.call(this)||this,Object.defineProperties(r,{_createCancelableRoomSignalingPromise:{value:n.createCancelableRoomSignalingPromise},_options:{value:n},_wsServer:{value:t}}),r}return i(t,e),t.prototype._connect=function(e,t,n,r,i){return i=Object.assign({},this._options,i),this._createCancelableRoomSignalingPromise.bind(null,t,this._wsServer,e,n,r,i)},t.prototype.createLocalParticipantSignaling=function(e,t){return new a(e,t)},t}(e("../"));t.exports=s},{"../":398,"./cancelableroomsignalingpromise":407,"./localparticipant":412}],412:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../localparticipant"),a=e("./localtrackpublication"),s=e("../../util/constants").DEFAULT_LOG_LEVEL,l=e("../../util/log"),c=e("../../util"),u=c.buildLogLevels,p=c.isDeepEqual,f=function(e){function t(t,n,r){var i;r=Object.assign({logLevel:s,LocalTrackPublicationV2:a},r),i=e.call(this)||this;var o=u(r.logLevel);return Object.defineProperties(i,{_bandwidthProfile:{value:null,writable:!0},_bandwidthProfileRevision:{value:0,writable:!0},_encodingParameters:{value:t},_removeListeners:{value:new Map},_LocalTrackPublicationV2:{value:r.LocalTrackPublicationV2},_log:{value:r.log?r.log.createLog("default",i):new l("default",i,o,r.loggerName)}
164,_publishedRevision:{writable:!0,value:0},_revision:{writable:!0,value:1},_signalingRegion:{value:null,writable:!0},audioProcessors:{value:[],writable:!0},bandwidthProfile:{enumerable:!0,get:function(){return this._bandwidthProfile}},bandwidthProfileRevision:{enumerable:!0,get:function(){return this._bandwidthProfileRevision}},networkQualityConfiguration:{enumerable:!0,value:n},revision:{enumerable:!0,get:function(){return this._revision}},signalingRegion:{enumerable:!0,get:function(){return this._signalingRegion}}}),i}return i(t,e),t.prototype.toString=function(){return"[LocalParticipantSignaling: "+this.sid+"]"},t.prototype.setSignalingRegion=function(e){this._signalingRegion||(this._signalingRegion=e)},t.prototype.setBandwidthProfile=function(e){p(this._bandwidthProfile,e)||(this._bandwidthProfile=JSON.parse(JSON.stringify(e)),this._bandwidthProfileRevision++,this.didUpdate())},t.prototype.setAudioProcessors=function(e){this.audioProcessors=e},t.prototype.getParameters=function(){return this._encodingParameters},t.prototype.setParameters=function(e){return this._encodingParameters.update(e),this},t.prototype.update=function(e){return this._publishedRevision>=e.revision||(this._publishedRevision=e.revision,e.tracks.forEach((function(e){var t=this.tracks.get(e.id);t&&t.update(e)}),this)),this},t.prototype.updateMediaStates=function(e){return e&&e.tracks?(Array.from(this.tracks.values()).forEach((function(t){var n=e.tracks[t.sid];n&&t.updateMediaStates(n)})),this):this},t.prototype._createLocalTrackPublicationSignaling=function(e,t,n,r){return new this._LocalTrackPublicationV2(e,t,n,r,{log:this._log})},t.prototype.addTrack=function(t,n,r,i){var o=this;e.prototype.addTrack.call(this,t,n,r,i);var a=this.getPublication(t),s=a.isEnabled,l=a.updatedPriority,c=function(){s===a.isEnabled&&l===a.updatedPriority||(o.didUpdate(),s=a.isEnabled,l=a.updatedPriority)};return a.on("updated",c),this._removeListener(a),this._removeListeners.set(a,(function(){return a.removeListener("updated",c)})),this.didUpdate(),this},t.prototype._removeListener=function(e){var t=this._removeListeners.get(e);t&&t()},t.prototype.getState=function(){return{revision:this.revision,tracks:Array.from(this.tracks.values()).map((function(e){return e.getState()}))}},t.prototype.didUpdate=function(){this._revision++,this.emit("updated")},t.prototype.removeTrack=function(t){var n=e.prototype.removeTrack.call(this,t);return n&&(t.removeClone(n.trackTransceiver),this._removeListener(n),this.didUpdate()),n},t.prototype.setNetworkQualityConfiguration=function(e){this.networkQualityConfiguration.update(e)},t.prototype.setPublisherHint=function(e,t){var n=Array.from(this.tracks.values()).find((function(t){return t.sid===e}));return n?n.trackTransceiver.setPublisherHint(t):(this._log.warn("track:"+e+" not found"),Promise.resolve("UNKNOWN_TRACK"))},t}(o);t.exports=f},{"../../util":472,"../../util/constants":465,"../../util/log":476,"../localparticipant":399,"./localtrackpublication":413}],413:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../localtrackpublication"),a=e("../../util/twiliowarning"),s=e("../../util/twilio-video-errors").createTwil
164ioError,l=function(e){function t(t,n,r,i,o){var a=e.call(this,t,n,r)||this;return Object.defineProperties(a,{_log:{value:o.log.createLog("default",a)},_mediaStates:{value:{recordings:null},writable:!0},_noiseCancellationVendor:{value:i}}),a}return i(t,e),t.prototype.getState=function(){var e={enabled:this.isEnabled,id:this.id,kind:this.kind,name:this.name,priority:this.updatedPriority};return this._noiseCancellationVendor&&(e.audio_processor=this._noiseCancellationVendor),e},t.prototype.toString=function(){return"[LocalTrackPublicationV2: "+this.sid+"]"},t.prototype.update=function(e){switch(e.state){case"ready":this.setSid(e.sid);break;case"failed":var t=e.error;this.publishFailed(s(t.code,t.message))}return this},t.prototype.updateMediaStates=function(e){if(!e||!e.recordings||this._mediaStates.recordings===e.recordings)return this;switch(this._mediaStates.recordings=e.recordings,this._mediaStates.recordings){case"OK":this._log.info("Warnings have cleared."),this.emit("warningsCleared");break;case"NO_MEDIA":this._log.warn("Recording media lost."),this.emit("warning",a.recordingMediaLost);break;default:this._log.warn("Unknown media state detected: "+this._mediaStates.recordings)}return this},t}(o);t.exports=l},{"../../util/twilio-video-errors":487,"../../util/twiliowarning":489,"../localtrackpublication":400}],414:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("events"),a=0,s=function(e){function t(t,n,r){var i=e.call(this)||this;return Object.defineProperties(i,{_instanceId:{value:a++},channel:{value:n},_log:{value:r.log.createLog("default",i)},_getReceiver:{value:t},_receiverPromise:{value:null,writable:!0},_transport:{value:null,writable:!0}}),i}return i(t,e),Object.defineProperty(t.prototype,"isSetup",{get:function(){return!!this._receiverPromise},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"[MediaSignaling #"+this._instanceId+":"+this.channel+"]"},t.prototype.setup=function(e){var t=this;this._teardown(),this._log.info("setting up msp transport for id:",e);var n=this._getReceiver(e).then((function(e){if("data"!==e.kind&&t._log.error("Expected a DataTrackReceiver"),t._receiverPromise===n){try{t._transport=e.toDataTransport(),t.emit("ready",t._transport)}catch(e){t._log.error("Failed to toDataTransport: "+e.message)}e.once("close",(function(){return t._teardown()}))}}));this._receiverPromise=n},t.prototype._teardown=function(){this._transport&&(this._log.info("Tearing down"),this._transport=null,this._receiverPromise=null,this.emit("teardown"))},t}(o);t.exports=s},{events:222}],415:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=e("events"),s=e("../../stats/peerconnectionreportfactory"),l=function(e){function t(t,n){var r=e.call(this)||this;return Object.defineProperties(r,{_factories:{value:new WeakMap},_manager:{value:t},_signaling:{value:n}}),n.on("updated",(function(){return r.emit("updated")})),r}return i(t,e),Object.defineProperty(t.prototype,"level",{get:function(){return this._signaling.level}
164,enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"levels",{get:function(){return this._signaling.levels},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"remoteLevels",{get:function(){return this._signaling.remoteLevels},enumerable:!1,configurable:!0}),t.prototype.start=function(){var e=this;this.stop();var t=setTimeout((function(){var n,r;e._timeout===t&&(n=e,r=(n._manager._peerConnections?Array.from(n._manager._peerConnections.values()):[]).map((function(e){return e._peerConnection})).filter((function(e){return"closed"!==e.signalingState})).map((function(e){if(n._factories.has(e))return n._factories.get(e);var t=new s(e);return n._factories.set(e,t),t})).map((function(e){return e.next().catch((function(){return null}))})),Promise.all(r).then((function(e){return e.filter((function(e){return e})).map((function(e){return e.summarize()}))}))).then((function(n){if(e._timeout===t){if(n.length){var r=o(n,1)[0];e._signaling.put(r)}e.start()}}))}),200);this._timeout=t},t.prototype.stop=function(){clearTimeout(this._timeout),this._timeout=null},t}(a);t.exports=l},{"../../stats/peerconnectionreportfactory":446,events:222}],416:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./mediasignaling"),a=e("../../util/asyncvar"),s=e("../../util/timeout"),l=function(e){function t(t,n,r){var i=e.call(this,t,"network_quality",r)||this;return Object.defineProperties(i,{_level:{value:null,writable:!0},_levels:{value:null,writable:!0},_remoteLevels:{value:new Map,writable:!0},_networkQualityInputs:{value:new a},_resendTimer:{value:new s((function(){i._resendTimer.setDelay(1.5*i._resendTimer.delay),i._sendNetworkQualityInputs()}),5e3,!1)},_networkQualityReportLevels:{get:function(){return{reportLevel:n.local,remoteReportLevel:n.remote}}}}),i.on("ready",(function(e){e.on("message",(function(e){switch(i._log.debug("Incoming: ",e),e.type){case"network_quality":i._handleNetworkQualityMessage(e)}}))})),i._sendNetworkQualityInputs(),i}return i(t,e),Object.defineProperty(t.prototype,"level",{get:function(){return this._level},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"levels",{get:function(){return this._levels},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"remoteLevels",{get:function(){return this._remoteLevels},enumerable:!1,configurable:!0}),t.prototype._handleNetworkQualityMessage=function(e){var t=this,n=!1,r=null,i=e?e.local:null;"number"==typeof i?(r=i,this._levels=null):"object"==typeof i&&i&&(this._levels=i,r="number"==typeof i.level?i.level:Math.min(i.audio.send,i.audio.recv,i.video.send,i.video.recv)),null!==r&&this.level!==r&&(this._level=r,n=!0),this._remoteLevels=e&&e.remotes?e.remotes.reduce((function(e,r){return(t._remoteLevels.get(r.sid)||{}).level!==r.level&&(n=!0),e.set(r.sid,r)}),new Map):this._remoteLevels,n&&this.emit("updated"),this._resendTimer.setDelay(5e3),this._resendTimer.isSet&&setTimeout((function(){return t._sendNetworkQualityInputs()}),1e3)},t.prototype._sendNetworkQualityInputs=function(){var e=this;return this._resendTimer.clear(),this._networkQualityInputs.take().then((function(t){e._transport&&e._transport.publish(function(e,t){return Object.assign({type:"network_quality"},e,t)}(t,e._networkQualityReportLevels))})).finally((function(){e._resendTimer.start()}))},t.prototype.put=function(e){this._networkQualityInputs.put(e)},t}(o);t.exports=l},{"../../util/asyncvar":461,"../../util/timeout":486,"./mediasignaling":414}],417:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("../../util/backoff"),l=e("../../webrtc"),c=l.RTCIceCandidate,u=l.RTCPeerConnection,p=l.RTCSessionDescription,f=l.getStats,d=e("../../webrtc/util"),h=e("../../util/constants"),m=h.DEFAULT_ICE_GATHERING_TIMEOUT_MS,y=h.DEFAULT_LOG_LEVEL,b=h.DEFAULT_SESSION_TIMEOUT_SEC,v=h.iceRestartBackoffConfig,g=e("../../util/sdp"),w=g.addOrRewriteNewTrackIds,C=g.addOrRewriteTrackIds,_=g.createCodecMapForMediaSection,k=g.disableRtx,S=g.enableDtxForOpus,E=g.filterLocalCodecs,T=g.getMediaSections,O=g.removeSSRCAttributes,P=g.revertSimulcast,R=g.setCodecPreferences,x=g.setSimulcast,D=e("../../util/timeout"),j=e("../../util/twilio-video-errors"),M=j.MediaClientLocalDescFailedError,A=j.MediaClientRemoteDescFailedError,I=e("../../util"),N=I.buildLogLevels,L=I.getPlatform,F=I.isChromeScreenShareTrack,U=I.oncePerTick,q=I.defer,B=e("./icebox"),z=e("./iceconnectionmonitor.js"),V=e("../../data/receiver"),W=e("../../media/track/receiver"),H=e("../../statemachine"),Y=e("../../util/log"),X=e("../../util/sdp/trackmatcher"),G=e("../../util/sdp/issue8329"),$=d.guessBrowser(),Q=L(),K=/android/.test(Q),J="chrome"===$,Z="firefox"===$,ee="safari"===$,te=0,ne={open:["closed","updating"],updating:["closed","open"],closed:[]},re=function(e){function t(t,n,r,i){var o=e.call(this,"open",ne)||this,a=se(i=Object.assign({enableDscp:!1,dummyAudioMediaStreamTrack:null,isChromeScreenShareTrack:F,iceServers:[],logLevel:y,offerOptions:{},revertSimulcast:P,sessionTimeout:1e3*b,setCodecPreferences:R,setSimulcast:x,Backoff:s,IceConnectionMonitor:z,RTCIceCandidate:c,RTCPeerConnection:u,RTCSessionDescription:p,Timeout:D},i)),l=N(i.logLevel),f=i.RTCPeerConnection;!0===i.enableDscp&&(i.chromeSpecificConstraints=i.chromeSpecificConstraints||{},i.chromeSpecificConstraints.optional=i.chromeSpecificConstraints.optional||[],i.chromeSpecificConstraints.optional.pu
164sh({googDscp:!0}));var d=i.log?i.log.createLog("webrtc",o):new Y("webrtc",o,l,i.loggerName),h=new f(a,i.chromeSpecificConstraints);i.dummyAudioMediaStreamTrack&&h.addTrack(i.dummyAudioMediaStreamTrack),Object.defineProperties(o,{_appliedTrackIdsToAttributes:{value:new Map,writable:!0},_dataChannels:{value:new Map},_dataTrackReceivers:{value:new Set},_descriptionRevision:{writable:!0,value:0},_didGenerateLocalCandidates:{writable:!0,value:!1},_enableDscp:{value:i.enableDscp},_encodingParameters:{value:n},_isChromeScreenShareTrack:{value:i.isChromeScreenShareTrack},_iceGatheringFailed:{value:!1,writable:!0},_iceGatheringTimeout:{value:new i.Timeout((function(){return o._handleIceGatheringTimeout()}),m,!1)},_iceRestartBackoff:{value:new i.Backoff(v)},_instanceId:{value:++te},_isIceConnectionInactive:{writable:!0,value:!1},_isIceLite:{writable:!0,value:!1},_isIceRestartBackoffInProgress:{writable:!0,value:!1},_isRestartingIce:{writable:!0,value:!1},_lastIceConnectionState:{writable:!0,value:null},_lastStableDescriptionRevision:{writable:!0,value:0},_localCandidates:{writable:!0,value:[]},_localCodecs:{value:new Set},_localCandidatesRevision:{writable:!0,value:1},_localDescriptionWithoutSimulcast:{writable:!0,value:null},_localDescription:{writable:!0,value:null},_localUfrag:{writable:!0,value:null},_log:{value:d},_eventObserver:{value:i.eventObserver},_remoteCodecMaps:{value:new Map},_rtpSenders:{value:new Map},_rtpNewSenders:{value:new Set},_iceConnectionMonitor:{value:new i.IceConnectionMonitor(h)},_mediaTrackReceivers:{value:new Set},_needsAnswer:{writable:!0,value:!1},_negotiationRole:{writable:!0,value:null},_offerOptions:{writable:!0,value:i.offerOptions},_onEncodingParametersChanged:{value:U((function(){o._needsAnswer||ue(o)}))},_peerConnection:{value:h},_preferredAudioCodecs:{value:r.audio},_preferredVideoCodecs:{value:r.video},_shouldApplyDtx:{value:r.audio.every((function(e){return"opus"!==e.codec}))||r.audio.some((function(e){var t=e.codec,n=e.dtx;return"opus"===t&&n}))},_queuedDescription:{writable:!0,value:null},_iceReconnectTimeout:{value:new i.Timeout((function(){d.debug("ICE reconnect timed out"),o.close()}),i.sessionTimeout,!1)},_recycledTransceivers:{value:{audio:[],video:[]}},_replaceTrackPromises:{value:new Map},_remoteCandidates:{writable:!0,value:new B},_setCodecPreferences:{value:Z&&K&&r.video[0]&&"h264"!==r.video[0].codec.toLowerCase()?function(e){return e}:i.setCodecPreferences},_setSimulcast:{value:i.setSimulcast},_revertSimulcast:{value:i.revertSimulcast},_RTCIceCandidate:{value:i.RTCIceCandidate},_RTCPeerConnection:{value:i.RTCPeerConnection},_RTCSessionDescription:{value:i.RTCSessionDescription},_shouldOffer:{writable:!0,value:!1},_shouldRestartIce:{writable:!0,value:!1},_trackIdsToAttributes:{value:new Map,writable:!0},_trackMatcher:{writable:!0,value:null},_mediaTrackSenderToPublisherHints:{value:new Map},id:{enumerable:!0,value:t}}),n.on("changed",o._onEncodingParametersChanged),h.addEventListener("connectionstatechange",o._handleConnectionStateChange.bind(o)),h.addEventListener("datachannel",o._handleDataChannelEvent.bind(o)),h.addEventListener("icecandidate",o._handleIceCandidateEvent.bind(o)),h.addEventListener("iceconnectionstatechange",o._handleIceConnectionStateChange.bind(o)),h.addEventListener("icegatheringstatechange",o._handleIceGatheringStateChange.bind(o)),h.addEventListener("signalingstatechange",o._handleSignalingStateChange.bind(o)),h.addEventListener("track",o._handleTrackEvent.bind(o));var g=o;return o.on("stateChanged",(function e(t){"closed"===t&&(g.removeListener("stateChanged",e),g._dataChannels.forEach((function(e,t){g.removeDataTrackSender(t)})))})),o}return i(t,e),t.prototype.toString=function(){return"[PeerConnectionV2 #"+this._instanceId+": "+this.id+"]"},t.prototype.setEffectiveAdaptiveSimulcast=function(e){this._log.debug("Setting setEffectiveAdaptiveSimulcast: ",e),this._preferredVideoCodecs.forEach((function(t){"adaptiveSimulcast"in t&&(t.adaptiveSimulcast=e)}))},Object.defineProperty(t.prototype,"_shouldApplySimulcast",{get:function(){return!(!J&&!ee)&&this._preferredVideoCodecs.some((function(e){return"vp8"===e.codec.toLowerCase()&&e.simulcast&&!1!==e.adaptiveSimulcast}))}
164,enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"connectionState",{get:function(){return"failed"===this.iceConnectionState?"failed":this._peerConnection.connectionState||this.iceConnectionState},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"iceConnectionState",{get:function(){return this._isIceConnectionInactive&&"disconnected"===this._peerConnection.iceConnectionState||this._iceGatheringFailed?"failed":this._peerConnection.iceConnectionState},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isApplicationSectionNegotiated",{get:function(){return"closed"===this._peerConnection.signalingState||!!this._peerConnection.localDescription&&T(this._peerConnection.localDescription.sdp,"application").length>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"_isAdaptiveSimulcastEnabled",{get:function(){var e=this._preferredVideoCodecs.find((function(e){return"adaptiveSimulcast"in e}));return e&&!0===e.adaptiveSimulcast},enumerable:!1,configurable:!0}),t.prototype._maybeUpdateEncodings=function(e,t,n){if(void 0===n&&(n=!1),"video"!==e.kind||"ended"===e.readyState)return!1;var r=e.getSettings(),i=r.height,o=r.width;if("number"!=typeof i||"number"!=typeof o)return!1;var a=d.guessBrowser();return!!("safari"===a||"chrome"===a&&this._isAdaptiveSimulcastEnabled)&&(this._updateEncodings(e,t,n),!0)},t.prototype._updateEncodings=function(e,t,n){if(this._isChromeScreenShareTrack(e)){var r=[{scaleResolutionDownBy:1},{scaleResolutionDownBy:1}];t.forEach((function(e,t){var i=r[t];i?(e.scaleResolutionDownBy=i.scaleResolutionDownBy,n&&delete e.active):(e.active=!1,delete e.scaleResolutionDownBy)}))}else{var i=e.getSettings(),o=i.width*i.height,a=[{pixels:518400,maxActiveLayers:3},{pixels:129600,maxActiveLayers:2},{pixels:0,maxActiveLayers:1}].find((function(e){return o>=e.pixels})),s=Math.min(t.length,a.maxActiveLayers);t.forEach((function(e,t){t<s?(e.scaleResolutionDownBy=1<<s-t-1,n&&(e.active=!0)):(e.active=!1,delete e.scaleResolutionDownBy)}))}this._log.debug("_updateEncodings:",t.map((function(e,t){return"["+t+": "+e.active+", "+(e.scaleResolutionDownBy||0)+"]"})).join(", "))},t.prototype._addIceCandidate=function(e){var t=this;return Promise.resolve().then((function(){return e=new t._RTCIceCandidate(e),t._peerConnection.addIceCandidate(e)})).catch((function(n){t._log.warn("Failed to add RTCIceCandidate "+(e?'"'+e.candidate+'"':"null")+": "+n.message)}))},t.prototype._addIceCandidates=function(e){return Promise.all(e.map(this._addIceCandidate,this)).then((function(){}))},t.prototype._addOrUpdateTransceiver=function(e){var t=this,n=function(e,t){var n={audio:e._preferredAudioCodecs.map((function(e){return e.codec.toLowerCase()})),video:e._preferredVideoCodecs.map((function(e){return e.codec.toLowerCase()}))}[t],r=e._recycledTransceivers[t],i=n.find((function(t){return e._localCodecs.has(t)}));if(!i)return r.shift();var o=r.find((function(t){var n=e._remoteCodecMaps.get(t.mid);return n&&n.has(i)}));o&&r.splice(r.indexOf(o),1);return o}(this,e.kind);if(n&&n.sender){var r=n.sender.track?n.sender.track.id:null;return r&&this._log.warn("Reusing transceiver: "+n.mid+"] "+r+" => "+e.id),this._replaceTrackPromises.set(n,n.sender.replaceTrack(e).then((function(){n.direction="sendrecv"}),(function(){})).finally((function(){t._replaceTrackPromises.delete(n)}))),n}return this._peerConnection.addTransceiver(e)},t.prototype._checkIceBox=function(e){var t=ae(e);if(!t)return Promise.resolve();var n=this._remoteCandidates.setUfrag(t);return this._addIceCandidates(n)},t.prototype._answer=function(e){var t=this;return Promise.resolve().then((function(){return t._negotiationRole||(t._negotiationRole="answerer"),t._setRemoteDescription(e)})).catch((function(){throw new A})).then((function(){return t._peerConnection.createAnswer()})).then((function(n){n=Z?new t._RTCSessionDescription({sdp:k(n.sdp),type:n.type}):G(n);var r=O(n.sdp,["mslabel","label"]);if(t._shouldApplySimulcast){var i=r;r=t._setSimulcast(i,t._trackIdsToAttributes),r=t._revertSimulcast(r,i,e.sdp)}return r=r.replace(/42e015/g,"42e01f"),t._setLocalDescription({type:n.type,sdp:r})})).then((function(){return t._checkIceBox(e)})).then((function(){return t._queuedDescription&&t._updateDescription(t._queuedDescription)})).then((function(){return t._queuedDescription=null,t._maybeReoffer(t._peerConnection.localDescription)})).catch((function(e){var n=e instanceof A?e:new M;throw t._publishMediaWarning({message:"Failed to _answer",code:n.code,error:e}),n}))},t.prototype._close=function(){return this._iceConnectionMonitor.stop(),"closed"!==this._peerConnection.signalingState&&(this._peerConnection.close(),this.preempt("closed"),this._encodingParameters.removeListener("changed",this._onEncodingParametersChanged),!0)}
164,t.prototype._handleConnectionStateChange=function(){this.emit("connectionStateChanged")},t.prototype._handleDataChannelEvent=function(e){var t=this,n=e.channel,r=new V(n);this._dataTrackReceivers.add(r),n.addEventListener("close",(function(){t._dataTrackReceivers.delete(r)})),this.emit("trackAdded",r)},t.prototype._handleGlare=function(e){var t=this;return this._log.debug("Glare detected; rolling back"),this._isRestartingIce&&(this._log.debug("An ICE restart was in progress; we'll need to restart ICE again after rolling back"),this._isRestartingIce=!1,this._shouldRestartIce=!0),Promise.resolve().then((function(){return t._trackIdsToAttributes=new Map(t._appliedTrackIdsToAttributes),t._setLocalDescription({type:"rollback"})})).then((function(){return t._needsAnswer=!1,t._answer(e)})).then((function(e){return e?Promise.resolve():t._offer()}))},t.prototype._publishMediaWarning=function(e){var t=e.message,n=e.code,r=e.error,i=e.sdp;this._eventObserver.emit("event",{level:"warning",name:"error",group:"media",payload:{message:t,code:n,context:JSON.stringify({error:r.message,sdp:i})}})},t.prototype._handleIceCandidateEvent=function(e){e.candidate&&(this._log.debug("Clearing ICE gathering timeout"),this._didGenerateLocalCandidates=!0,this._iceGatheringTimeout.clear(),this._localCandidates.push(e.candidate));var t={ice:{candidates:this._isIceLite?[]:this._localCandidates.slice(),ufrag:this._localUfrag},id:this.id};e.candidate||(t.ice.complete=!0),this._isIceLite&&e.candidate||(t.ice.revision=this._localCandidatesRevision++,this.emit("candidates",t))},t.prototype._handleIceConnectionStateChange=function(){var e=this,t=this._peerConnection.iceConnectionState,n=["connected","completed"].includes(t),r=this._log;r.debug('ICE connection state is "'+t+'"'),n&&(this._iceReconnectTimeout.clear(),this._iceRestartBackoff.reset()),"failed"===this._lastIceConnectionState||"failed"!==t||this._shouldRestartIce||this._isRestartingIce?["disconnected","failed"].includes(this._lastIceConnectionState)&&n&&r.debug("ICE reconnected"):(r.warn("ICE failed"),this._initiateIceRestartBackoff()),"connected"===t?(this._isIceConnectionInactive=!1,this._iceConnectionMonitor.start((function(){e._iceConnectionMonitor.stop(),e._shouldRestartIce||e._isRestartingIce||(r.warn("ICE Connection Monitor detected inactivity"),e._isIceConnectionInactive=!0,e._initiateIceRestartBackoff(),e.emit("iceConnectionStateChanged"),e.emit("connectionStateChanged"))}))):["disconnected","completed"].includes(t)||(this._iceConnectionMonitor.stop(),this._isIceConnectionInactive=!1),this._lastIceConnectionState=t,this.emit("iceConnectionStateChanged")},t.prototype._handleIceGatheringTimeout=function(){this._log.warn("ICE failed to gather any local candidates"),this._iceGatheringFailed=!0,this._initiateIceRestartBackoff(),this.emit("iceConnectionStateChanged"),this.emit("connectionStateChanged")},t.prototype._handleIceGatheringStateChange=function(){var e=this._peerConnection.iceGatheringState,t=this._log;t.debug('ICE gathering state is "'+e+'"');var n=this._iceGatheringTimeout,r=n.delay,i=n.isSet;"gathering"!==e||this._didGenerateLocalCandidates||i||(t.debug("Starting ICE gathering timeout: "+r),this._iceGatheringFailed=!1,this._iceGatheringTimeout.start())},t.prototype._handleSignalingStateChange=function(){"stable"===this._peerConnection.signalingState&&(this._appliedTrackIdsToAttributes=new Map(this._trackIdsToAttributes))},t.prototype._handleTrackEvent=function(e){var t=this,n=this._peerConnection.remoteDescription?this._peerConnection.remoteDescription.sdp:null;this._trackMatcher=this._trackMatcher||new X,this._trackMatcher.update(n);var r=e.track,i=this._trackMatcher.match(e)||r.id,o=new W(i,r);this._mediaTrackReceivers.forEach((function(e){e.track.id===o.track.id&&t._mediaTrackReceivers.delete(e)})),this._mediaTrackReceivers.add(o),r.addEventListener("ended",(function(){return t._mediaTrackReceivers.delete(o)})),this.emit("trackAdded",o)},t.prototype._initiateIceRestart=function(){if("closed"!==this._peerConnection.signalingState){var e=this._log;e.warn("Attempting to restart ICE"),this._didGenerateLocalCandidates=!1,this._isIceRestartBackoffInProgress=!1,this._shouldRestartIce=!0;var t=this._iceReconnectTimeout,n=t.delay;t.isSet||(e.debug("Starting ICE reconnect timeout: "+n),this._iceReconnectTimeout.start()),this.offer().catch((function(t){e.error("offer failed in _initiateIceRestart with: "+t.message)}))}},t.prototype._initiateIceRestartBackoff=function(){var e=this;"closed"===this._peerConnection.signalingState||this._isIceRestartBackoffInProgress||(this._log.warn("An ICE restart has been scheduled"),this._isIceRestartBackoffInProgress=!0,this._iceRestartBackoff.backoff((function(){return e._initiateIceRestart()})))},t.prototype._maybeReoffer=function(e){var t=this._shouldOffer;if(e&&e.sdp){var n=this._peerConnection.getSenders().filter((function(e){return e.track}));t=["audio","video"].reduce((function(t,r){var i=T(e.sdp,r,"(sendrecv|sendonly)"),o=n.filter(le.bind(null,r));return t||i.length<o.length}),t);var r=this._dataChannels.size>0,i=T(e.sdp,"application").length>0;t=t||r&&!i}return(t?this._offer():Promise.resolve()).then((function(){return t}))},t.prototype._offer=function(){var e=this,t=Object.assign({},this._offerOptions);return this._needsAnswer=!0,this._shouldRestartIce&&(this._shouldRestartIce=!1,this._isRestartingIce=!0,t.iceRestart=!0),Promise.all(this._replaceTrackPromises.values()).then((function(){return e._peerConnection.createOffer(t)}
164)).catch((function(t){var n=new M;throw e._publishMediaWarning({message:"Failed to create offer",code:n.code,error:t}),n})).then((function(t){t=Z?new e._RTCSessionDescription({sdp:k(t.sdp),type:t.type}):G(t);var n=O(t.sdp,["mslabel","label"]);n=e._peerConnection.remoteDescription?E(n,e._peerConnection.remoteDescription.sdp):n;var r=e._setCodecPreferences(n,e._preferredAudioCodecs,e._preferredVideoCodecs);return e._shouldOffer=!1,e._negotiationRole||(e._negotiationRole="offerer"),e._shouldApplySimulcast&&(e._localDescriptionWithoutSimulcast={type:"offer",sdp:r},r=e._setSimulcast(r,e._trackIdsToAttributes)),e._setLocalDescription({type:"offer",sdp:r})}))},t.prototype._getMediaTrackSenderId=function(e){var t=Array.from(this._rtpSenders.keys()).find((function(t){return t.track.id===e}));return t?t.id:e},t.prototype._addOrRewriteLocalTrackIds=function(e){var t=this,n=this._peerConnection.getTransceivers().filter((function(e){var t=e.sender;return!e.stopped&&t&&t.track})),r=n.filter((function(e){return e.mid})),i=new Map(r.map((function(e){var n=e.mid,r=e.sender;return[n,t._getMediaTrackSenderId(r.track.id)]}))),o=C(e.sdp,i),a=n.filter((function(e){return!e.mid})),s=new Map(["audio","video"].map((function(e){return[e,a.filter((function(t){return t.sender.track.kind===e})).map((function(e){var n=e.sender;return t._getMediaTrackSenderId(n.track.id)}))]}))),l=w(o,i,s);return new this._RTCSessionDescription({sdp:l,type:e.type})},t.prototype._rollbackAndApplyOffer=function(e){var t=this;return this._setLocalDescription({type:"rollback"}).then((function(){return t._setLocalDescription(e)}))},t.prototype._setLocalDescription=function(e){var t=this;return"rollback"!==e.type&&this._shouldApplyDtx&&(e=new this._RTCSessionDescription({sdp:S(e.sdp),type:e.type})),this._peerConnection.setLocalDescription(e).catch((function(n){t._log.warn('Calling setLocalDescription with an RTCSessionDescription of type "'+e.type+'" failed with the error "'+n.message+'".',n);var r=new M,i={message:'Calling setLocalDescription with an RTCSessionDescription of type "'+e.type+'" failed',code:r.code,error:n};throw e.sdp&&(t._log.warn("The SDP was "+e.sdp),i.sdp=e.sdp),t._publishMediaWarning(i),r})).then((function(){"rollback"!==e.type&&(t._localDescription=t._addOrRewriteLocalTrackIds(e),t._shouldApplyDtx&&(t._localDescription=new t._RTCSessionDescription({sdp:S(t._localDescription.sdp,[]),type:t._localDescription.type})),t._localCandidates=[],"offer"===e.type?t._descriptionRevision++:"answer"===e.type&&(t._lastStableDescriptionRevision=t._descriptionRevision,ce(t)),t._localUfrag=ae(e),t.emit("description",t.getState()))}))},t.prototype._setRemoteDescription=function(e){var t=this;return e.sdp&&(e.sdp=this._setCodecPreferences(e.sdp,this._preferredAudioCodecs,this._preferredVideoCodecs),this._shouldApplyDtx?e.sdp=S(e.sdp):e.sdp=S(e.sdp,[]),Z&&(e.sdp=e.sdp.replace(/a=msid:[^ ]+ /g,"a=msid:- ")),this._peerConnection.remoteDescription||(this._isIceLite=/a=ice-lite/.test(e.sdp))),e=new this._RTCSessionDescription(e),Promise.resolve().then((function(){if("answer"===e.type&&t._localDescriptionWithoutSimulcast){var n=t._preferredVideoCodecs.find((function(e){return"adaptiveSimulcast"in e})),r=!!n&&!1===n.adaptiveSimulcast,i=t._revertSimulcast(t._localDescription.sdp,t._localDescriptionWithoutSimulcast.sdp,e.sdp,r);if(t._localDescriptionWithoutSimulcast=null,i!==t._localDescription.sdp)return t._rollbackAndApplyOffer({type:t._localDescription.type,sdp:i})}})).then((function(){return t._peerConnection.setRemoteDescription(e)})).then((function(){"answer"===e.type&&(t._isRestartingIce&&(t._log.debug("An ICE restart was in-progress and is now completed"),t._isRestartingIce=!1),ce(t))}),(function(n){throw t._log.warn('Calling setRemoteDescription with an RTCSessionDescription of type "'+e.type+'" failed with the error "'+n.message+'".',n),e.sdp&&t._log.warn("The SDP was "+e.sdp),n}))},t.prototype._updateDescription=function(e){var t=this;switch(e.type){case"answer":case"pranswer":if(e.revision!==this._descriptionRevision||"have-local-offer"!==this._peerConnection.signalingState)return Promise.resolve();this._descriptionRevision=e.revision;break;
164case"close":return this._close();case"create-offer":return e.revision<=this._lastStableDescriptionRevision?Promise.resolve():this._needsAnswer?(this._queuedDescription=e,Promise.resolve()):(this._descriptionRevision=e.revision,this._offer());case"offer":return e.revision<=this._lastStableDescriptionRevision||"closed"===this._peerConnection.signalingState?Promise.resolve():"have-local-offer"===this._peerConnection.signalingState?this._needsAnswer&&0===this._lastStableDescriptionRevision?(this._queuedDescription=e,Promise.resolve()):(this._descriptionRevision=e.revision,this._handleGlare(e)):(this._descriptionRevision=e.revision,this._answer(e).then((function(){})))}var n=e.revision;return Promise.resolve().then((function(){return t._setRemoteDescription(e)})).catch((function(n){var r=new A;throw t._publishMediaWarning({message:'Calling setRemoteDescription with an RTCSessionDescription of type "'+e.type+'" failed',code:r.code,error:n,sdp:e.sdp}),r})).then((function(){return t._lastStableDescriptionRevision=n,t._needsAnswer=!1,t._checkIceBox(e)})).then((function(){return t._queuedDescription&&t._updateDescription(t._queuedDescription)})).then((function(){return t._queuedDescription=null,t._maybeReoffer(t._peerConnection.localDescription).then((function(){}))}))},t.prototype._updateIce=function(e){var t=this._remoteCandidates.update(e);return this._addIceCandidates(t)},t.prototype.addDataTrackSender=function(e){if(!this._dataChannels.has(e))try{var t={ordered:e.ordered};null!==e.maxPacketLifeTime&&(t.maxPacketLifeTime=e.maxPacketLifeTime),null!==e.maxRetransmits&&(t.maxRetransmits=e.maxRetransmits);var n=this._peerConnection.createDataChannel(e.id,t);e.addDataChannel(n),this._dataChannels.set(e,n)}catch(t){this._log.warn('Error creating an RTCDataChannel for DataTrack "'+e.id+'": '+t.message)}},t.prototype._handleQueuedPublisherHints=function(){var e=this;"stable"===this._peerConnection.signalingState&&this._mediaTrackSenderToPublisherHints.forEach((function(t,n){var r=t.deferred,i=t.encodings;e._mediaTrackSenderToPublisherHints.delete(n),e._setPublisherHint(n,i).then((function(e){return r.resolve(e)})).catch((function(e){return r.reject(e)}))}))},t.prototype._setPublisherHint=function(e,t){var n=this;if(Z)return Promise.resolve("COULD_NOT_APPLY_HINT");this._mediaTrackSenderToPublisherHints.has(e)&&(this._mediaTrackSenderToPublisherHints.get(e).deferred.resolve("REQUEST_SKIPPED"),this._mediaTrackSenderToPublisherHints.delete(e));var r=this._rtpSenders.get(e);if(!r)return this._log.warn("Could not apply publisher hint because RTCRtpSender was not found"),Promise.resolve("UNKNOWN_TRACK");if("closed"===this._peerConnection.signalingState)return this._log.warn('Could not apply publisher hint because signalingState was "closed"'),Promise.resolve("COULD_NOT_APPLY_HINT");if("stable"!==this._peerConnection.signalingState){this._log.debug("Queuing up publisher hint because signalingState:",this._peerConnection.signalingState);var i=q();return this._mediaTrackSenderToPublisherHints.set(e,{deferred:i,encodings:t}),i.promise}var o=r.getParameters();return null!==t&&t.forEach((function(e){var t=e.enabled,r=e.layer_index;o.encodings.length>r?(n._log.debug("layer:"+r+", active:"+o.encodings[r].active+" => "+t),o.encodings[r].active=t):n._log.warn("invalid layer:"+r+", active:"+t)})),this._maybeUpdateEncodings(r.track,o.encodings,null===t),r.setParameters(o).then((function(){return"OK"})).catch((function(e){return n._log.error("Failed to apply publisher hints:",e),"COULD_NOT_APPLY_HINT"}))},t.prototype.addMediaTrackSender=function(e){var t=this;if("closed"!==this._peerConnection.signalingState&&!this._rtpSenders.has(e)){var n=this._addOrUpdateTransceiver(e.track).sender;e.addSender(n,(function(n){return t._setPublisherHint(e,n)}
164)),this._rtpNewSenders.add(n),this._rtpSenders.set(e,n)}},t.prototype.close=function(){this._close()&&(this._descriptionRevision++,this._localDescription={type:"close"},this.emit("description",this.getState()))},t.prototype.getTrackReceivers=function(){return Array.from(this._dataTrackReceivers).concat(Array.from(this._mediaTrackReceivers))},t.prototype.getState=function(){if(!this._localDescription)return null;var e="answer"===this._localDescription.type?this._lastStableDescriptionRevision:this._descriptionRevision,t={type:this._localDescription.type,revision:e};return this._localDescription.sdp&&(t.sdp=this._localDescription.sdp),{description:t,id:this.id}},t.prototype.offer=function(){var e=this;return this._needsAnswer||this._isRestartingIce?(this._shouldOffer=!0,Promise.resolve()):this.bracket("offering",(function(t){return e.transition("updating",t),(e._needsAnswer||e._isRestartingIce?Promise.resolve():e._offer()).then((function(){e.tryTransition("open",t)}),(function(n){throw e.tryTransition("open",t),n}))}))},t.prototype.removeDataTrackSender=function(e){var t=this._dataChannels.get(e);t&&(e.removeDataChannel(t),this._dataChannels.delete(e),t.close())},t.prototype.removeMediaTrackSender=function(e){var t=this._rtpSenders.get(e);if(t){if("closed"!==this._peerConnection.signalingState&&this._peerConnection.removeTrack(t),e.removeSender(t),this._mediaTrackSenderToPublisherHints.has(e))this._mediaTrackSenderToPublisherHints.get(e).deferred.resolve("UNKNOWN_TRACK"),this._mediaTrackSenderToPublisherHints.delete(e);
164this._rtpNewSenders.delete(t),this._rtpSenders.delete(e)}},t.prototype.setConfiguration=function(e){"function"==typeof this._peerConnection.setConfiguration&&this._peerConnection.setConfiguration(se(e))},t.prototype.setIceReconnectTimeout=function(e){return this._iceReconnectTimeout.setDelay(e),this._log.debug("Updated ICE reconnection timeout period:",this._iceReconnectTimeout.delay),this},t.prototype.update=function(e){var t=this;return this.bracket("updating",(function(n){if("closed"===t.state)return Promise.resolve();t.transition("updating",n);var r=[];return e.ice&&r.push(t._updateIce(e.ice)),e.description&&r.push(t._updateDescription(e.description)),Promise.all(r).then((function(){t.tryTransition("open",n)}),(function(e){throw t.tryTransition("open",n),e}))}))},t.prototype.getStats=function(){var e=this;return f(this._peerConnection).then((function(t){return function(e,t){return Object.assign(t,{remoteAudioTrackStats:t.remoteAudioTrackStats.map((function(t){return oe(e,t)})),remoteVideoTrackStats:t.remoteVideoTrackStats.map((function(t){return oe(e,t)})),localAudioTrackStats:t.localAudioTrackStats.map((function(t){return ie(e,t)})),localVideoTrackStats:t.localVideoTrackStats.map((function(t){return ie(e,t)}))})}(e,t)}))},t}(H);function ie(e,t){var n=e._getMediaTrackSenderId(t.trackId);return Object.assign(t,{trackId:n})}function oe(e,t){var n=a([],o(e._mediaTrackReceivers)).find((function(e){return e.track.id===t.trackId})),r=n?n.id:null;return Object.assign(t,{trackId:r})}function ae(e){if(e.sdp){var t=e.sdp.match(/^a=ice-ufrag:([a-zA-Z0-9+/]+)/m);if(t)return t[1]}return null}function se(e){return Object.assign({bundlePolicy:"max-bundle",rtcpMuxPolicy:"require"},e)}function le(e,t){var n=t.track;return n&&n.kind===e&&"ended"!==n.readyState}function ce(e){!function(e){e._recycledTransceivers.audio=[],e._recycledTransceivers.video=[],e._peerConnection.getTransceivers().forEach((function(t){if(function(e,t){return!e.stopped&&!t._replaceTrackPromises.has(e)&&["inactive","recvonly"].includes(e.direction)}(t,e)){var n=t.receiver.track;e._recycledTransceivers[n.kind].push(t)}}))}(e),function(e){var t=e._peerConnection.localDescription;t&&t.sdp&&T(t.sdp).forEach((function(t){_(t).forEach((function(t,n){return e._localCodecs.add(n)}))}))}(e),function(e){var t=e._peerConnection.remoteDescription;t&&t.sdp&&T(t.sdp).forEach((function(t){var n=t.match(/^a=mid:(.+)$/m);if(n&&n[1]){var r=n[1],i=_(t);e._remoteCodecMaps.set(r,i)}}))}(e),ue(e).then((function(){e._handleQueuedPublisherHints()}))}function ue(e){var t=e._encodingParameters,n=t.maxAudioBitrate,r=t.maxVideoBitrate,i=new Map([["audio",n],["video",r]]),o=[];return e._peerConnection.getSenders().filter((function(e){return e.track})).forEach((function(t){var n=i.get(t.track.kind),r=t.getParameters();null===n||0===n?function(e){Array.isArray(e.encodings)&&e.encodings.forEac
164h((function(e){return delete e.maxBitrate}))}(r):e._isChromeScreenShareTrack(t.track)?e._log.warn("Not setting maxBitrate for "+t.track.kind+" Track "+t.track.id+" because it appears to be screen share track: "+t.track.label):function(e,t){Z?e.encodings=[{maxBitrate:t}]:e.encodings.forEach((function(e){e.maxBitrate=t}))}(r,n),!Z&&r.encodings.length>0&&("audio"===t.track.kind?r.encodings[0].priority="high":e._isChromeScreenShareTrack(t.track)&&(r.encodings[0].priority="medium"),e._enableDscp&&(r.encodings[0].networkPriority="high"));var a=e._rtpNewSenders.has(t);e._maybeUpdateEncodings(t.track,r.encodings,a),e._rtpNewSenders.delete(t);var s=t.setParameters(r).catch((function(n){e._log.warn("Error while setting encodings parameters for "+t.track.kind+" Track "+t.track.id+": "+(n.message||n.name))}));o.push(s)})),Promise.all(o)}t.exports=re},{"../../data/receiver":345,"../../media/track/receiver":370,"../../statemachine":428,"../../util":472,"../../util/backoff":462,"../../util/constants":465,"../../util/log":476,"../../util/sdp":480,"../../util/sdp/issue8329":481,"../../util/sdp/trackmatcher":483,"../../util/timeout":486,"../../util/twilio-video-errors":487,"../../webrtc":498,"../../webrtc/util":510,"./icebox":409,"./iceconnectionmonitor.js":410}],418:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("../../webrtc/util").guessBrowser,l=e("./peerconnection"),c=e("../../media/track/sender"),u=e("../../queueingeventemitter"),p=e("../../util"),f=e("../../util/twilio-video-errors").MediaConnectionError,d="firefox"===s(),h=function(t){function n(n,r,i){var o=t.call(this)||this,a=(i=Object.assign({audioContextFactory:d?e("../../webaudio/audiocontext"):null,PeerConnectionV2:l},i)).audioContextFactory?i.audioContextFactory.getOrCreate(o):null,s=a?{offerToReceiveVideo:!0}:{offerToReceiveAudio:!0,offerToReceiveVideo:!0};return Object.defineProperties(o,{_audioContextFactory:{value:i.audioContextFactory},_closedPeerConnectionIds:{value:new Set},_configuration:{writable:!0,value:null},_configurationDeferred:{writable:!0,value:p.defer()},_connectionState:{value:"new",writable:!0},_dummyAudioTrackSender:{value:a?new c(m(a)):null},_encodingParameters:{value:n},_iceConnectionState:{writable:!0,value:"new"},_dataTrackSenders:{writable:!0,value:new Set},_lastConnectionState:{value:"new",writable:!0},_lastIceConnectionState:{writable:!0,value:"new"},_mediaTrackSenders:{writable:!0,value:new Set},_offerOptions:{value:s},_peerConnections:{value:new Map},_preferredCodecs:{value:r},_sessionTimeout:{value:null,writable:!0},_PeerConnectionV2:{value:i.PeerConnectionV2}}),o}return i(n,t),n.prototype.setEffectiveAdaptiveSimulcast=function(e){this._peerConnections.forEach((function(t){return t.setEffectiveAdaptiveSimulcast(e)})),this._preferredCodecs.video.forEach((function(t){"adaptiveSimulcast"in t&&(t.adaptiveSimulcast=e)}))},Object.defineProperty(n.prototype,"connectionState",{get:function(){return this._connectionState},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"iceConnectionState",{get:function(){return this._iceConnectionState},enumerable:!1,configurable:!0}),n.prototype._closeAbsentPeerConnections=function(e){var t=new Set(e.map((function(e){return e.id})));return this._peerConnections.forEach((function(e){t.has(e.id)||e._close()})),this},n.prototype._getConfiguration=function(){return this._configurationDeferred.promise},n.prototype._getOrCreate=function(e,t){var n=this,r=this,i=this._peerConnections.get(e);if(!i){var o=this._PeerConnectionV2,a=Object.assign({dummyAudioMediaStreamTrack:this._dummyAudioTrackSender?this._dummyAudioTrackSender.track:null,offerOptions:this._offerOptions},this._sessionTimeout?{sessionTimeout:this._sessionTimeout}:{},t);try{i=new o(e,this._encodingParameters,this._preferredCodecs,a)}catch(e){throw new f}this._peerConnections.set(i.id,i),i.on("candidates",this.queue.bind(this,"candidates")),i.on("description",this.queue.bind(this,"description")),i.on("trackAdded",this.queue.bind(this,"trackAdded")),i.on("stateChanged",(function e(t){"closed"===t&&(i.removeListener("stateChanged",e),r._dataTrackSenders.forEac
164h((function(e){return i.removeDataTrackSender(e)})),r._mediaTrackSenders.forEach((function(e){return i.removeMediaTrackSender(e)})),r._peerConnections.delete(i.id),r._closedPeerConnectionIds.add(i.id),_(r),C(r))})),i.on("connectionStateChanged",(function(){return _(n)})),i.on("iceConnectionStateChanged",(function(){return C(n)})),this._dataTrackSenders.forEach(i.addDataTrackSender,i),this._mediaTrackSenders.forEach(i.addMediaTrackSender,i),C(this)}return i},n.prototype.close=function(){return this._peerConnections.forEach((function(e){e.close()})),this._dummyAudioTrackSender&&this._dummyAudioTrackSender.stop(),this._audioContextFactory&&this._audioContextFactory.release(this),C(this),this},n.prototype.createAndOffer=function(){var e=this;return this._getConfiguration().then((function(t){var n;do{n=p.makeUUID()}while(e._peerConnections.has(n));return e._getOrCreate(n,t)})).then((function(e){return e.offer()})).then((function(){return e}))},n.prototype.getTrackReceivers=function(){return p.flatMap(this._peerConnections,(function(e){return e.getTrackReceivers()}))},n.prototype.getStates=function(){var e=[];return this._peerConnections.forEach((function(t){var n=t.getState();n&&e.push(n)})),e},n.prototype.setConfiguration=function(e){return this._configuration&&(this._configurationDeferred=p.defer(),this._peerConnections.forEach((function(t){t.setConfiguration(e)}))),this._configuration=e,this._configurationDeferred.resolve(e),this},n.prototype.setIceReconnectTimeout=function(e){return null===this._sessionTimeout&&(this._peerConnections.forEach((function(t){t.setIceReconnectTimeout(e)})),this._sessionTimeout=e),this},n.prototype.setTrackSenders=function(e){var t=new Set(e.filter((function(e){return"data"===e.kind}))),n=new Set(e.filter((function(e){return e&&("audio"===e.kind||"video"===e.kind)}))),r=function(e,t,n){return{data:y(e,t),media:b(e,n)}}(this,t,n);return this._dataTrackSenders=t,this._mediaTrackSenders=n,function(e,t){(t.data.add.size||t.data.remove.size||t.media.add.size||t.media.remove.size)&&e._peerConnections.forEach((function(e){t.data.remove.forEach(e.removeDataTrackSender,e),t.media.remove.forEach(e.removeMediaTrackSender,e),t.data.add.forEach(e.addDataTrackSender,e),t.media.add.forEach(e.addMediaTrackSender,e),(t.media.add.size||t.media.remove.size||t.data.add.size&&!e.isApplicationSectionNegotiated)&&e.offer()}))}(this,r),this},n.prototype.update=function(e,t){var n=this;return void 0===t&&(t=!1),t&&this._closeAbsentPeerConnections(e),this._getConfiguration().then((function(t){return Promise.all(e.map((function(e){return n._closedPeerConnectionIds.has(e.id)?null:n._getOrCreate(e.id,t).update(e)})))})).then((function(){return n}))},n.prototype.getStats=function(){var e=Array.from(this._peerConnections.values());return Promise.all(e.map((function(e){return e.getStats().then((function(t){return[e.id,t]}))}))).then((function(e){return new Map(e)}))},n}(u);function m(e){return e.createMediaStreamDestination().stream.getAudioTracks()[0]}function y(e,t){return{add:p.difference(t,e._dataTrackSenders),remove:p.difference(e._dataTrackSenders,t)}}function b(e,t){return{add:p.difference(t,e._mediaTrackSenders),remove:p.difference(e._mediaTrackSenders,t)}}
164var v,g={new:0,checking:1,connecting:2,connected:3,completed:4,disconnected:-1,failed:-2,closed:-3};function w(e){return e.length?(v=v||Object.keys(g).reduce((function(e,t){var n;return Object.assign(e,((n={})[g[t]]=t,n))}),{}),e.reduce((function(e,t){return v[Math.max(g[e],g[t])]}))):"new"}function C(e){e._lastIceConnectionState=e.iceConnectionState,e._iceConnectionState=w(a([],o(e._peerConnections.values())).map((function(e){return e.iceConnectionState}))),e.iceConnectionState!==e._lastIceConnectionState&&e.emit("iceConnectionStateChanged")}function _(e){e._lastConnectionState=e.connectionState,e._connectionState=w(a([],o(e._peerConnections.values())).map((function(e){return e.connectionState}))),e.connectionState!==e._lastConnectionState&&e.emit("connectionStateChanged")}t.exports=h},{"../../media/track/sender":379,"../../queueingeventemitter":395,"../../util":472,"../../util/twilio-video-errors":487,"../../webaudio/audiocontext":493,"../../webrtc/util":510,"./peerconnection":417}],419:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./mediasignaling"),a=1,s=function(e){function t(t,n){var r=e.call(this,t,"publisher_hints",n)||this;return r.on("ready",(function(e){r._log.debug("publisher_hints transport ready:",e),e.on("message",(function(e){switch(r._log.debug("Incoming: ",e),e.type){case"publisher_hints":e.publisher&&e.publisher.hints&&e.publisher.id&&r._processPublisherHints(e.publisher.hints,e.publisher.id);break;default:r._log.warn("Unknown message type: ",e.type)}}))})),r}return i(t,e),t.prototype.sendTrackReplaced=function(e){var t=e.trackSid;if(this._transport){var n={type:"client_reset",track:t,id:a++};this._log.debug("Outgoing: ",n),this._transport.publish(n)}},t.prototype.sendHintResponse=function(e){var t=e.id,n=e.hints;if(this._transport){var r={type:"publisher_hints",id:t,hints:n};this._log.debug("Outgoing: ",r),this._transport.publish(r)}},t.prototype._processPublisherHints=function(e,t){try{this.emit("updated",e,t)}catch(e){this._log.error("error processing hints:",e)}},t}(o);t.exports=s},{"./mediasignaling":414}],420:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(){var t=e.call(this)||this;return Object.defineProperties(t,{_revision:{value:1,writable:!0}}),t}return i(t,e),t.prototype.update=function(e){return e.revision<this._revision?this:(this._revision=e.revision,this.enable(e.is_recording))},t}
164(e("../recording"));t.exports=o},{"../recording":402}],421:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../remoteparticipant"),a=e("./remotetrackpublication"),s=function(e){function t(t,n,r,i,o,s){var l=e.call(this,t.sid,t.identity)||this;return s=Object.assign({RemoteTrackPublicationV2:a},s),Object.defineProperties(l,{_revision:{writable:!0,value:null},_RemoteTrackPublicationV2:{value:s.RemoteTrackPublicationV2},_getInitialTrackSwitchOffState:{value:n},updateSubscriberTrackPriority:{value:function(e,t){return r(e,t)}},updateTrackRenderHint:{value:function(e,t){return i(e,t)}},clearTrackHint:{value:function(e){return o(e)}},revision:{enumerable:!0,get:function(){return this._revision}}}),l.update(t)}return i(t,e),t.prototype._getOrCreateTrack=function(e){var t=this._RemoteTrackPublicationV2,n=this.tracks.get(e.sid);n||(n=new t(e,this._getInitialTrackSwitchOffState(e.sid)),this.addTrack(n));return n},t.prototype.update=function(e){var t=this;if(null!==this.revision&&e.revision<=this.revision)return this;this._revision=e.revision;var n=new Set;switch(e.tracks.forEach((function(e){var r=t._getOrCreateTrack(e);r.update(e),n.add(r)})),this.tracks.forEach((function(e){n.has(e)||t.removeTrack(e)})),e.state){case"disconnected":this.disconnect();break;case"reconnecting":this.reconnecting();break;case"connected":this.connect(this.sid,this.identity)}return this},t}(o);t.exports=s},{"../remoteparticipant":403,"./remotetrackpublication":422}],422:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){return e.call(this,t.sid,t.name,t.kind,t.enabled,t.priority,n)||this}return i(t,e),t.prototype.update=function(e){return this.enable(e.enabled),this.setPriority(e.priority),this},t}(e("../remotetrackpublication"));t.exports=o},{"../remotetrackpublication":404}],423:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./mediasignaling"),a=e("../../util/timeout"),s=e("../../util").isDeepEqual,l=1,c=function(e){function t(t,n){var r=e.call(this,t,"render_hints",n)||this;return Object.defineProperties(r,{_trackSidsToRenderHints:{value:new Map},_responseTimer:{value:new a((function(){r._sendAllHints(),r._responseTimer.setDelay(2*r._responseTimer.delay)}),2e3,!1)}}),r.on("ready",(function(e){e.on("message",(function(e){switch(r._log.debug("Incoming: ",e),e.type){case"render_hints":r._processHintResults(e&&e.subscriber&&e.subscriber.hints||[]);break;default:r._log.warn("Unknown message type: ",e.type)}})),r._sendAllHints()})),r}return i(t,e),t.prototype._sendAllHints=function(){var e=this;Array.from(this._trackSidsToRenderHints.keys()).forEach((function(t){var n=e._trackSidsToRenderHints.get(t);n.renderDimensions&&(n.isDimensionDirty=!0),"enabled"in n&&(n.isEnabledDirty=!0)})),this._sendHints()},t.prototype._processHintResults=function(e){var t=this;this._responseTimer.clear(),this._responseTimer.setDelay(2e3),e.forEach((function(e){"OK"!==e.result&&t._log.debug("Server error processing hint:",e)})),this._sendHints()},t.prototype._sendHints=function(){var e=this;if(this._transport&&!this._responseTimer.isSet){var t=[];
164if(Array.from(this._trackSidsToRenderHints.keys()).forEach((function(n){var r=e._trackSidsToRenderHints.get(n);if(r.isEnabledDirty||r.isDimensionDirty){var i={track:n};r.isEnabledDirty&&(i.enabled=r.enabled,r.isEnabledDirty=!1),r.isDimensionDirty&&(i.render_dimensions=r.renderDimensions,r.isDimensionDirty=!1),t.push(i)}})),t.length>0){var n={type:"render_hints",subscriber:{id:l++,hints:t}};this._log.debug("Outgoing: ",n),this._transport.publish(n),this._responseTimer.start()}}},t.prototype.setTrackHint=function(e,t){var n=this._trackSidsToRenderHints.get(e)||{isEnabledDirty:!1,isDimensionDirty:!1};"enabled"in t&&n.enabled!==t.enabled&&(n.enabled=!!t.enabled,n.isEnabledDirty=!0),t.renderDimensions&&!s(t.renderDimensions,n.renderDimensions)&&(n.renderDimensions=t.renderDimensions,n.isDimensionDirty=!0),this._trackSidsToRenderHints.set(e,n),this._sendHints()},t.prototype.clearTrackHint=function(e){this._trackSidsToRenderHints.delete(e)},t}(o);t.exports=c},{"../../util":472,"../../util/timeout":486,"./mediasignaling":414}],424:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=e("./dominantspeakersignaling"),s=e("./networkqualitymonitor"),l=e("./networkqualitysignaling"),c=e("./recording"),u=e("../room"),p=e("./remoteparticipant"),f=e("../../stats/statsreport"),d=e("./trackprioritysignaling"),h=e("./trackswitchoffsignaling"),m=e("./renderhintssignaling"),y=e("./publisherhintsignaling.js"),b=e("../../util"),v=b.constants.DEFAULT_SESSION_TIMEOUT_SEC,g=b.createBandwidthProfilePayload,w=b.defer,C=b.difference,_=b.filterObject,k=b.flatMap,S=b.oncePerTick,E=e("../../util/movingaveragedelta"),T=e("../../util/twilio-video-errors").createTwil
164ioError,O=function(e){function t(t,n,r,i,o){var u=this;n.options=Object.assign({session_timeout:v},n.options),o=Object.assign({DominantSpeakerSignaling:a,NetworkQualityMonitor:s,NetworkQualitySignaling:l,RecordingSignaling:c,RemoteParticipantV2:p,TrackPrioritySignaling:d,TrackSwitchOffSignaling:h,bandwidthProfile:null,sessionTimeout:1e3*n.options.session_timeout,statsPublishIntervalMs:1e4},o),t.setBandwidthProfile(o.bandwidthProfile);var b=n.options,g=b.signaling_region,w=b.audio_processors,E=void 0===w?[]:w;t.setSignalingRegion(g),E.includes("krisp")&&E.push("rnnoise"),t.setAudioProcessors(E),i.setIceReconnectTimeout(o.sessionTimeout);var T=function(e){return u._getTrackReceiver(e)},O=(u=e.call(this,t,n.sid,n.name,o)||this)._log;return Object.defineProperties(u,{_disconnectedParticipantRevisions:{value:new Map},_NetworkQualityMonitor:{value:o.NetworkQualityMonitor},_lastBandwidthProfileRevision:{value:t.bandwidthProfileRevision,writable:!0},_mediaStatesWarningsRevision:{value:0,writable:!0},_networkQualityMonitor:{value:null,writable:!0},_networkQualityConfiguration:{value:t.networkQualityConfiguration},_peerConnectionManager:{value:i},_published:{value:new Map},_publishedRevision:{value:0,writable:!0},_RemoteParticipantV2:{value:o.RemoteParticipantV2},_subscribed:{value:new Map},_subscribedRevision:{value:0,writable:!0},_subscriptionFailures:{value:new Map},_dominantSpeakerSignaling:{value:new o.DominantSpeakerSignaling(T,{log:O})},_networkQualitySignaling:{value:new o.NetworkQualitySignaling(T,t.networkQualityConfiguration,{log:O})},_renderHintsSignaling:{value:new m(T,{log:O})},_publisherHintsSignaling:{value:new y(T,{log:O})},_trackPrioritySignaling:{value:new o.TrackPrioritySignaling(T,{log:O})},_trackSwitchOffSignaling:{value:new o.TrackSwitchOffSignaling(T,{log:O})},_pendingSwitchOffStates:{value:new Map},_transport:{value:r},_trackReceiverDeferreds:{value:new Map},mediaRegion:{enumerable:!0,value:n.options.media_region||null}}),u._initTrackSwitchOffSignaling(),u._initDominantSpeakerSignaling(),u._initNetworkQualityMonitorSignaling(),u._initPublisherHintSignaling(),function(e,t){var n=S((function(){e._publishNewLocalParticipantState()})),r=S((function(){var n=k(t.tracks,(function(e){return e.trackTransceiver}));e._peerConnectionManager.setTrackSenders(n)}));t.on("trackAdded",r),t.on("trackRemoved",r),t.on("updated",n),e.on("stateChanged",(function i(o){"disconnected"===o&&(t.removeListener("trackAdded",r),t.removeListener("trackRemoved",r),t.removeListener("updated",n),e.removeListener("stateChanged",i),t.disconnect())})),e.on("signalingConnectionStateChanged",(function(){var t=e.localParticipant,n=e.signalingConnectionState,r=t.identity,i=t.sid;switch(n){case"connected":t.connect(i,r);break;case"reconnecting":t.reconnecting()}}))}(u,t),function(e,t){t.on("description",(function(t){e._publishPeerConnectionState(t)})),t.dequeue("description"),t.on("candidates",(function(t){e._publishPeerConnectionState(t)})),t.dequeue("candidates"),t.on("trackAdded",e._addTrackReceiver.bind(e)),t.dequeue("trackAdded"),t.getTrackReceivers().forEach(e._addTrackReceiver,e),t.on("connectionStateChanged",(function(){e.emit("connectionStateChanged")})),t.on("iceConnectionStateChanged",(function(){e.emit("iceConnectionStateChanged"),"failed"===e.iceConnectionState&&(null!==e.localParticipant.networkQualityLevel&&e.localParticipant.setNetworkQualityLevel(0),e.participants.forEac
164h((function(e){null!==e.networkQualityLevel&&e.setNetworkQualityLevel(0)})))}))}(u,i),function(e,t){t.on("message",e._update.bind(e)),t.on("stateChanged",(function n(r,i){"disconnected"===r&&("disconnected"!==e.state&&e._disconnect(i),t.removeListener("stateChanged",n)),e.emit("signalingConnectionStateChanged")}))}(u,r),function(e,t,n){var r=new Map,i=!1,o=setInterval((function(){e.getStats().then((function(e){i=!i,e.forEach((function(e,n){var o=new f(n,e,!0);t.publishEvent("quality","stats-report","info",{audioTrackStats:o.remoteAudioTrackStats.map((function(t,n){return j(t,e.remoteAudioTrackStats[n],r)})),localAudioTrackStats:o.localAudioTrackStats.map((function(t,n){return D(t,e.localAudioTrackStats[n],r)})),localVideoTrackStats:o.localVideoTrackStats.map((function(t,n){return D(t,e.localVideoTrackStats[n],r)})),peerConnectionId:o.peerConnectionId,videoTrackStats:o.remoteVideoTrackStats.map((function(t,n){return j(t,e.remoteVideoTrackStats[n],r)}))});var a=k(["localAudioTrackStats","localVideoTrackStats","remoteAudioTrackStats","remoteVideoTrackStats"],(function(e){return o[e].map((function(e){var t=e.ssrc;return e.trackSid+"+"+t}))}));if(C(Array.from(r.keys()),a).forEach((function(e){return r.delete(e)})),i){var s=function(e,t){return(e=Object.assign({availableIncomingBitrate:0,availableOutgoingBitrate:0,bytesReceived:0,bytesSent:0,consentRequestsSent:0,currentRoundTripTime:0,lastPacketReceivedTimestamp:0,lastPacketSentTimestamp:0,nominated:!1,peerConnectionId:t,priority:0,readable:!1,requestsReceived:0,requestsSent:0,responsesReceived:0,responsesSent:0,retransmissionsReceived:0,retransmissionsSent:0,state:"failed",totalRoundTripTime:0,transportId:"",writable:!1},_(e||{},null))).localCandidate=Object.assign({candidateType:"host",deleted:!1,ip:"",port:0,priority:0,protocol:"udp",url:""},_(e.localCandidate||{},null)),e.remoteCandidate=Object.assign({candidateType:"host",ip:"",port:0,priority:0,protocol:"udp",url:""},_(e.remoteCandidate||{},null)),e}(e.activeIceCandidatePair,o.peerConnectionId);t.publishEvent("quality","active-ice-candidate-pair","info",s)}}))}),(function(){}))}),n);e.on("stateChanged",(function t(n){"disconnected"===n&&(clearInterval(o),e.removeListener("stateChanged",t))}))}(u,r,o.statsPublishIntervalMs),u._update(n),u._peerConnectionManager.setEffectiveAdaptiveSimulcast(u._publisherHintsSignaling.isSetup),u}return i(t,e),Object.defineProperty(t.prototype,"connectionState",{get:function(){return this._peerConnectionManager.connectionState},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"signalingConnectionState",{get:function(){return"syncing"===this._transport.state?"reconnecting":this._transport.state},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"iceConnectionState",{get:function(){return this._peerConnectionManager.iceConnectionState},enumerable:!1,configurable:!0}),t.prototype._deleteTrackReceiverDeferred=function(e){return this._trackReceiverDeferreds.delete(e)},t.prototype._getOrCreateTrackReceiverDeferred=function(e){var t=this._trackReceiverDeferreds.get(e)||w(),n=this._peerConnectionManager.getTrackReceivers().find((function(t){return t.id===e&&"ended"!==t.readyState}));return n?t.resolve(n):this._trackReceiverDeferreds.set(e,t),t},t.prototype._addTrackReceiver=function(e){return this._getOrCreateTrackReceiverDeferred(e.id).resolve(e),this},t.prototype._disconnect=function(t){var n=e.prototype._disconnect.call(this,t);return n&&(this._teardownNetworkQualityMonitor(),this._transport.disconnect(),this._peerConnectionManager.close()),this.localParticipant.tracks.forEach((function(e){e.publishFailed(t||new Error("LocalParticipant disconnected"))})),n},t.prototype._getTrackReceiver=function(e){var t=this;return this._getOrCreateTrackReceiverDeferred(e).promise.then((function(n){return t._deleteTrackReceiverDeferred(e),n}))},t.prototype._getInitialTrackSwitchOffState=function(e){var t=this._pendingSwitchOffStates.get(e)||!1;return this._pendingSwitchOffStates.delete(e),t&&this._log.warn("["+e+"] was initially switched off! "),t},t.prototype._getTrackSidsToTrackSignalings=function(){var e=k(this.participants,(function(e){return Array.from(e.tracks)}));return new Map(e)},t.prototype._getOrCreateRemoteParticipant=function(e){var t=this,n=this._RemoteParticipantV2,r=this.participants.get(e.sid),i=this;return r||((r=new n(e,(function(e){return t._getInitialTrackSwitchOffState(e)}),(function(e,n){return t._trackPrioritySignaling.sendTrackPriorityUpdate(e,"subscribe",n)}),(function(e,n){return t._renderHintsSignaling.setTrackHint(e,n)}),(function(e){return t._renderHintsSignaling.clearTrackHint(e)}))).on("stateChanged",(function e(t){"disconnected"===t&&(r.removeListener("stateChanged",e),i.participants.delete(r.sid),i._disconnectedParticipantRevisions.set(r.sid,r.revision))})),this.connectParticipant(r)),r},t.prototype._getState=function(){return{participant:this.localParticipant.getState()}},t.prototype._maybeAddBandwidthProfile=function(e){var t=this.localParticipant,n=t.bandwidthProfile,r=t.bandwidthProfileRevision;return n&&this._lastBandwidthProfileRevision<r?(this._lastBandwidthProfileRevision=r,Object.assign({bandwidth_profile:g(n)},e)):e}
164,t.prototype._publishNewLocalParticipantState=function(){this._transport.publish(this._maybeAddBandwidthProfile(this._getState()))},t.prototype._publishPeerConnectionState=function(e){this._transport.publish(Object.assign({peer_connections:[e]},this._getState()))},t.prototype._update=function(e){var t=this;if(e.subscribed&&e.subscribed.revision>this._subscribedRevision){this._subscribedRevision=e.subscribed.revision,e.subscribed.tracks.forEach((function(e){e.id?(t._subscriptionFailures.delete(e.sid),t._subscribed.set(e.sid,e.id)):e.error&&!t._subscriptionFailures.has(e.sid)&&t._subscriptionFailures.set(e.sid,e.error)}));var n=new Set(e.subscribed.tracks.filter((function(e){return!!e.id})).map((function(e){return e.sid})));this._subscribed.forEach((function(e,r){n.has(r)||t._subscribed.delete(r)}))}var r,i,o=new Set;return(e.participants||[]).forEach((function(e){if(e.sid!==t.localParticipant.sid){var n=t._disconnectedParticipantRevisions.get(e.sid);if(!(n&&e.revision<=n)){n&&t._disconnectedParticipantRevisions.delete(e.sid);var r=t._getOrCreateRemoteParticipant(e);r.update(e),o.add(r)}}}
164)),"synced"===e.type&&this.participants.forEach((function(e){o.has(e)||e.disconnect()})),i=(r=this)._getTrackSidsToTrackSignalings(),r._subscriptionFailures.forEach((function(e,t){var n=i.get(t);n&&(r._subscriptionFailures.delete(t),n.subscribeFailed(T(e.code,e.message)))})),i.forEach((function(e){var t=r._subscribed.get(e.sid);(!t||e.isSubscribed&&e.trackTransceiver.id!==t)&&e.setTrackTransceiver(null),t&&r._getTrackReceiver(t).then((function(t){return e.setTrackTransceiver(t)}))})),e.peer_connections&&this._peerConnectionManager.update(e.peer_connections,"synced"===e.type),e.recording&&this.recording.update(e.recording),e.published&&e.published.revision>this._publishedRevision&&(this._publishedRevision=e.published.revision,e.published.tracks.forEach((function(e){e.sid&&t._published.set(e.id,e.sid)})),this.localParticipant.update(e.published)),e.participant&&this.localParticipant.connect(e.participant.sid,e.participant.identity),[this._dominantSpeakerSignaling,this._networkQualitySignaling,this._trackPrioritySignaling,this._trackSwitchOffSignaling,this._renderHintsSignaling,this._publisherHintsSignaling].forEach((function(t){var n=t.channel;!t.isSetup&&e.media_signaling&&e.media_signaling[n]&&e.media_signaling[n].transport&&"data-channel"===e.media_signaling[n].transport.type&&t.setup(e.media_signaling[n].transport.label)})),"warning"===e.type&&e.states&&e.states.revision>this._mediaStatesWarningsRevision&&(this._mediaStatesWarningsRevision=e.states.revision,this.localParticipant.updateMediaStates(e.states)),this},t.prototype._initPublisherHintSignaling=function(){var e=this;this._publisherHintsSignaling.on("updated",(function(t,n){Promise.all(t.map((function(t){return e.localParticipant.setPublisherHint(t.track,t.encodings).then((function(e){return{track:t.track,result:e}}))}))).then((function(t){e._publisherHintsSignaling.sendHintResponse({id:n,hints:t})}))}));var t=function(t){"video"===t.kind&&t.trackTransceiver.on("replaced",(function(){e._publisherHintsSignaling.sendTrackReplaced({trackSid:t.sid})}))};Array.from(this.localParticipant.tracks.values()).forEach((function(e){return t(e)})),this.localParticipant.on("trackAdded",(function(e){return t(e)}))},t.prototype._initTrackSwitchOffSignaling=function(){var e=this;this._trackSwitchOffSignaling.on("updated",(function(t,n){try{e._log.debug("received trackSwitch: ",{tracksOn:n,tracksOff:t});var r=new Map;n.forEach((function(e){return r.set(e,!0)})),t.forEach((function(t){r.get(t)&&e._log.warn(t+" is DUPLICATED in both tracksOff and tracksOn list"),r.set(t,!1)}
164)),e.participants.forEach((function(e){e.tracks.forEach((function(e){var t=r.get(e.sid);void 0!==t&&(e.setSwitchedOff(!t),r.delete(e.sid))}))})),r.forEach((function(t,n){return e._pendingSwitchOffStates.set(n,!t)}))}catch(t){e._log.error("error processing track switch off:",t)}}))},t.prototype._initDominantSpeakerSignaling=function(){var e=this;this._dominantSpeakerSignaling.on("updated",(function(){return e.setDominantSpeaker(e._dominantSpeakerSignaling.loudestParticipantSid)}))},t.prototype._initNetworkQualityMonitorSignaling=function(){var e=this;this._networkQualitySignaling.on("ready",(function(){var t=new e._NetworkQualityMonitor(e._peerConnectionManager,e._networkQualitySignaling);e._networkQualityMonitor=t,t.on("updated",(function(){"failed"!==e.iceConnectionState&&(e.localParticipant.setNetworkQualityLevel(t.level,t.levels),e.participants.forEach((function(e){var n=t.remoteLevels.get(e.sid);n&&e.setNetworkQualityLevel(n.level,n)})))})),t.start()})),this._networkQualitySignaling.on("teardown",(function(){return e._teardownNetworkQualityMonitor()}))},t.prototype._teardownNetworkQualityMonitor=function(){this._networkQualityMonitor&&(this._networkQualityMonitor.stop(),this._networkQualityMonitor=null)},t.prototype.getStats=function(){var e=this;return this._peerConnectionManager.getStats().then((function(t){return new Map(Array.from(t).map((function(t){var n=o(t,2),r=n[0],i=n[1];return[r,Object.assign({},i,{localAudioTrackStats:R(e,i.localAudioTrackStats),localVideoTrackStats:R(e,i.localVideoTrackStats),remoteAudioTrackStats:x(e,i.remoteAudioTrackStats),remoteVideoTrackStats:x(e,i.remoteVideoTrackStats)})]})))}))},t}(u);function P(e,t){return t.reduce((function(t,n){var r=e.get(n.trackId);return r?[Object.assign({},n,{trackSid:r})].concat(t):t}),[])}function R(e,t){return P(e._published,t)}function x(e,t){return P(new Map(Array.from(e._subscribed.entries()).map((function(e){var t=o(e,2),n=t[0];return[t[1],n]}))),t)}function D(e,t,n){var r=t.framesEncoded,i=t.packetsSent,o=t.totalEncodeTime,a=t.totalPacketSendDelay,s=Object.assign({},e),l=e.trackSid+"+"+e.ssrc,c=n.get(l)||new Map;if("number"==typeof o&&"number"==typeof r){var u=c.get("avgEncodeDelay")||new E;u.putSample(1e3*o,r),s.avgEncodeDelay=Math.round(u.get()),c.set("avgEncodeDelay",u)}if("number"==typeof a&&"number"==typeof i){var p=c.get("avgPacketSendDelay")||new E;p.putSample(1e3*a,i),s.avgPacketSendDelay=Math.round(p.get()),c.set("avgPacketSendDelay",p)}return n.set(l,c),s}function j(e,t,n){var r=t.estimatedPlayoutTimestamp,i=t.framesDecoded,o=t.jitterBufferDelay,a=t.jitterBufferEmittedCount,s=t.totalDecodeTime,l=Object.assign({},e),c=e.trackSid+"+"+e.ssrc,u=n.get(c)||new Map;if("number"==typeof r&&(l.estimatedPlayoutTimestamp=r),"number"==typeof i&&"number"==typeof s){var p=u.get("avgDecodeDelay")||new E;p.putSample(1e3*s,i),l.avgDecodeDelay=Math.round(p.get()),u.set("avgDecodeDelay",p)}if("number"==typeof o&&"number"==typeof a){var f=u.get("avgJitterBufferDelay")||new E;f.putSample(1e3*o,a),l.avgJitterBufferDelay=Math.round(f.get()),u.set("avgJitterBufferDelay",f)}return n.set(c,u),l}t.exports=O},{"../../stats/statsreport":456,"../../util":472,"../../util/movingaveragedelta":477,"../../util/twilio-video-errors":487,"../room":405,"./dominantspeakersignaling":408,"./networkqualitymonitor":415,"./networkqualitysignaling":416,"./publisherhintsignaling.js":419,"./recording":420,"./remoteparticipant":421,"./renderhintssignaling":423,"./trackprioritysignaling":425,"./trackswitchoffsignaling":426}],425:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this,t,"track_priority",n)||this;return Object.defineProperties(r,{_enqueuedPriorityUpdates:{value:new Map}}),r.on("ready",(function(e){Array.from(r._enqueuedPriorityUpdates.keys()).forEac
164h((function(t){e.publish({type:"track_priority",track:t,subscribe:r._enqueuedPriorityUpdates.get(t)})}))})),r}return i(t,e),t.prototype.sendTrackPriorityUpdate=function(e,t,n){if("subscribe"!==t)throw new Error("only subscribe priorities are supported, found: "+t);this._enqueuedPriorityUpdates.set(e,n),this._transport&&this._transport.publish({type:"track_priority",track:e,subscribe:n})},t}(e("./mediasignaling"));t.exports=o},{"./mediasignaling":414}],426:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this,t,"track_switch_off",n)||this;return r.on("ready",(function(e){e.on("message",(function(e){switch(e.type){case"track_switch_off":r._setTrackSwitchOffUpdates(e.off||[],e.on||[])}}))})),r}return i(t,e),t.prototype._setTrackSwitchOffUpdates=function(e,t){this.emit("updated",e,t)},t}(e("./mediasignaling"));t.exports=o},{"./mediasignaling":414}],427:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../../statemachine"),a=e("../../twilioconnection"),s=e("../../util/backoff"),l=e("../../util/constants").reconnectBackoffConfig,c=e("../../util/timeout"),u=e("../../util/constants"),p=u.SDK_NAME,f=u.SDK_VERSION,d=u.SDP_FORMAT,h=e("../../util"),m=h.createBandwidthProfilePayload,y=h.createMediaSignalingPayload,b=h.createMediaWarningsPayload,v=h.createSubscribePayload,g=h.getUserAgent,w=h.isNonArrayObject,C=e("../../util/twilio-video-errors"),_=C.createTwil
164ioError,k=C.RoomCompletedError,S=C.SignalingConnectionError,E=C.SignalingServerBusyError,T={connecting:["connected","disconnected"],connected:["disconnected","syncing"],syncing:["connected","disconnected"],disconnected:[]},O=function(e){function t(t,n,r,i,o,c){var u;return c=Object.assign({Backoff:s,TwilioConnection:a,iceServers:null,trackPriority:!0,trackSwitchOff:!0,renderHints:!0,userAgent:g()},c),u=e.call(this,"connecting",T)||this,Object.defineProperties(u,{_accessToken:{value:n},_automaticSubscription:{value:c.automaticSubscription},_bandwidthProfile:{value:c.bandwidthProfile},_dominantSpeaker:{value:c.dominantSpeaker},_adaptiveSimulcast:{value:c.adaptiveSimulcast},_eventObserver:{value:c.eventObserver,writable:!1},_renderHints:{value:c.renderHints},_iceServersStatus:{value:Array.isArray(c.iceServers)?"overrode":"acquire"},_localParticipant:{value:r},_name:{value:t},_networkQuality:{value:w(c.networkQuality)||c.networkQuality},_notifyWarnings:{value:c.notifyWarnings},_options:{value:c},_peerConnectionManager:{value:i},_sessionTimer:{value:null,writable:!0},_sessionTimeoutMS:{value:0,writable:!0},_reconnectBackoff:{value:new c.Backoff(l)},_session:{value:null,writable:!0},_trackPriority:{value:c.trackPriority},_trackSwitchOff:{value:c.trackSwitchOff},_twilioConnection:{value:null,writable:!0},_updatesReceived:{value:[]},_updatesToSend:{value:[]},_userAgent:{value:c.userAgent},_wsServer:{value:o}}),function(e){function t(){if("disconnected"!==e.state){e._twilioConnection&&e._twilioConnection.removeListener("message",r);var t=e._iceServersStatus,i=e._options,o=e._wsServer,a=e.state,s=i.TwilioConnection,l=new s(o,Object.assign({helloBody:"connecting"===a&&"acquire"===t?e._createIceMessage():e._createConnectOrSyncOrDisconnectMessage()},i));l.once("close",(function(e){e===s.CloseReason.LOCAL?n():n(new Error(e))})),l.on("message",r),e._twilioConnection=l}}
164function n(n){if("disconnected"!==e.state)if(n){var r=e._getReconnectTimer();if(r)"connected"===e.state&&e.preempt("syncing"),r.then(t);else{var i=n.message===a.CloseReason.BUSY?new E:new S;e.disconnect(i)}}else e.disconnect()}function r(t){if("disconnected"!==e.state)if("error"!==t.type)switch(e.state){case"connected":switch(t.type){case"connected":case"synced":case"update":case"warning":return void e.emit("message",t);case"disconnected":return void e.disconnect("completed"===t.status?new k:null);default:return}case"connecting":switch(t.type){case"iced":return void e._options.onIced(t.ice_servers).then((function(){e._sendConnectOrSyncOrDisconnectMessage()}));case"connected":return e._setSession(t.session,t.options.session_timeout),e.emit("connected",t),void e.preempt("connected");case"synced":case"update":return void e._updatesReceived.push(t);case"disconnected":return void e.disconnect("completed"===t.status?new k:null);default:return}case"syncing":switch(t.type){case"connected":case"update":return void e._updatesReceived.push(t);case"synced":return e._clearReconnectTimer(),e.emit("message",t),void e.preempt("connected");case"disconnected":return void e.disconnect("completed"===t.status?new k:null);default:return}default:return}else e.disconnect(_(t.code,t.message))}e.on("stateChanged",(function t(n){switch(n){case"connected":var i=e._updatesToSend.splice(0);return i.length&&e.publish(function(e){return e.reduce((function(e,t){return(!e.participant&&t.participant||e.participant&&t.participant&&t.participant.revision>e.participant.revision)&&(e.participant=t.participant),!e.peer_connections&&t.peer_connections?e.peer_connections=P(t.peer_connections):e.peer_connections&&t.peer_connections&&(e.peer_connections=P(e.peer_connections.concat(t.peer_connections))),e}),{})}(i)),void e._updatesReceived.splice(0).forEach((function(t){return e.emit("message",t)}));case"disconnected":return e._twilioConnection.removeListener("message",r),void e.removeListener("stateChanged",t);case"syncing":default:return}}));var i=e._options,o=e._iceServersStatus,s=i.iceServers,l=i.onIced;"overrode"===o?l(s).then(t):t()}(u),u}return i(t,e),t.prototype._createConnectOrSyncOrDisconnectMessage=function(){if("connected"===this.state)return null;if("disconnected"===this.state)return{session:this._session,type:"disconnect",version:2};var e={connecting:"connect",syncing:"sync"}[this.state],t={name:this._name,participant:this._localParticipant.getState(),peer_connections:this._peerConnectionManager.getStates(),type:e,version:2};return"connect"===t.type?(t.ice_servers=this._iceServersStatus,t.publisher={name:p,sdk_version:f,user_agent:this._userAgent},this._bandwidthProfile&&(t.bandwidth_profile=m(this._bandwidthProfile)),this._notifyWarnings&&(t.participant.media_warnings=b(this._notifyWarnings)),t.media_signaling=y(this._dominantSpeaker,this._networkQuality,this._trackPriority,this._trackSwitchOff,this._adaptiveSimulcast,this._renderHints),t.subscribe=v(this._automaticSubscription),t.format=d,t.token=this._accessToken):"sync"===t.type?(t.session=this._session,t.token=this._accessToken):"update"===t.type&&(t.session=this._session),t},t.prototype._createIceMessage=function(){return{edge:"roaming",token:this._accessToken,type:"ice",version:1}},t.prototype._sendConnectOrSyncOrDisconnectMessage=function(){var e=this._createConnectOrSyncOrDisconnectMessage();e&&this._twilioConnection.sendMessage(e)},t.prototype.disconnect=function(e){return"disconnected"!==this.state&&(this.preempt("disconnected",null,[e]),this._sendConnectOrSyncOrDisconnectMessage(),this._twilioConnection.close(),!0)},t.prototype.publish=function(e){switch(this.state){case"connected":return this._twilioConnection.sendMessage(Object.assign({session:this._session,type:"update",version:2},e)),!0;case"connecting":case"syncing":return this._updatesToSend.push(e),!0;case"disconnected":default:return!1}},t.prototype.publishEvent=function(e,t,n,r){this._eventObserver.emit("event",{group:e,name:t,level:n,payload:r})},t.prototype.sync=function(){return"connected"===this.state&&(this.preempt("syncing"),this._sendConnectOrSyncOrDisconnectMessage(),!0)},t.prototype._setSession=function(e,t){this._session=e,this._sessionTimeoutMS=1e3*t},t.prototype._getReconnectTimer=function(){var e=this;return 0===this._sessionTimeoutMS?null:(this._sessionTimer||(this._sessionTimer=new c((function(){e._sessionTimer&&(e._sessionTimeoutMS=0)}),this._sessionTimeoutMS)),new Promise((function(t){e._reconnectBackoff.backoff(t)})))},t.prototype._clearReconnectTimer=function(){this._reconnectBackoff.reset(),this._sessionTimer&&(this._sessionTimer.clear(),this._sessionTimer=null)},t}(o);function P(e){return Array.from(e.reduce((function(e,t){var n=e.get(t.id)||t;return(!n.description&&t.description||n.description&&t.description&&t.description.revision>n.description.revision)&&(n.description=t.description),(!n.ice&&t.ice||n.ice&&t.ice&&t.ice.revision>n.ice.revision)&&(n.ice=t.ice),e.set(n.id,n),e}),new Map).values())}t.exports=O},{"../../statemachine":428,"../../twilioconnection":460,"../../util":472,"../../util/backoff":462,"../../util/constants":465,"../../util/timeout":486,"../../util/twilio-video-errors":487}],428:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("events").EventEmitter,l=e("./util"),c=function(e){function t(t,n){var r,i=e.call(this)||this,o=null,a=t;return n=function(e){var t=new Map;for(var n in e)t.set(n,new Set(e[n]));return t}(n),Object.defineProperties(i,{_lock:{get:function(){return o}
164,set:function(e){o=e}},_reachableStates:{value:(r=n,Array.from(r.keys()).reduce((function(e,t){return e.set(t,function e(t,n,r){return r=r||new Set,t.get(n).forEach((function(n){r.has(n)||(r.add(n),e(t,n,r).forEach(r.add,r))})),r}(r,t))}),new Map))},_state:{get:function(){return a},set:function(e){a=e}},_states:{value:n},_whenDeferreds:{value:new Set},isLocked:{enumerable:!0,get:function(){return null!==o}},state:{enumerable:!0,get:function(){return a}}}),i.on("stateChanged",(function(e){i._whenDeferreds.forEach((function(t){t.when(e,t.resolve,t.reject)}))})),i}return i(t,e),t.prototype._whenPromise=function(e){var t=this;if("function"!=typeof e)return Promise.reject(new Error("when() executor must be a function"));var n=l.defer();return n.when=e,this._whenDeferreds.add(n),n.promise.then((function(e){return t._whenDeferreds.delete(n),e}),(function(e){throw t._whenDeferreds.delete(n),e}))},t.prototype.bracket=function(e,t){var n,r=this;function i(e){if(r.hasLock(n)&&r.releaseLockCompletely(n),e)throw e}return this.takeLock(e).then((function(e){return t(n=e)})).then((function(e){return i(),e}),i)},t.prototype.hasLock=function(e){return this._lock===e},t.prototype.preempt=function(e,t,n){if(!u(this._states,this.state,e))throw new Error('Cannot transition from "'+this.state+'" to "'+e+'"');var r;this.isLocked&&(r=this._lock,this._lock=null);var i=null;t&&(i=this.takeLockSync(t));var o=i?null:this.takeLockSync("preemption");return this.transition(e,i||o,n),r&&r.resolve(),o&&this.releaseLock(o),i},t.prototype.releaseLock=function(e){if(!this.isLocked)throw new Error("Could not release the lock for "+e.name+" because the StateMachine is not locked");if(!this.hasLock(e))throw new Error("Could not release the lock for "+e.name+" because "+this._lock.name+" has the lock");0===e.depth?(this._lock=null,e.resolve()):e.depth--},t.prototype.releaseLockCompletely=function(e){if(!this.isLocked)throw new Error("Could not release the lock for "+e.name+" because the StateMachine is not locked");if(!this.hasLock(e))throw new Error("Could not release the lock for "+e.name+" because "+this._lock.name+" has the lock");e.depth=0,this._lock=null,e.resolve()},t.prototype.takeLock=function(e){var t=this;if("object"==typeof e){var n=e;return new Promise((function(e){e(t.takeLockSync(n))}))}var r=e;if(this.isLocked){var i=this.takeLock.bind(this,r);return this._lock.promise.then(i)}return Promise.resolve(this.takeLockSync(r))},t.prototype.takeLockSync=function(e){var t="string"==typeof e?null:e,n=t?t.name:e;if(t&&!this.hasLock(t)||!t&&this.isLocked)throw new Error("Could not take the lock for "+n+" because the lock for "+this._lock.name+" was not released");if(t)return t.depth++,t;var r=function(e){var t=l.defer();return t.name=e,t.depth=0,t}(n);return this._lock=r,r},t.prototype.transition=function(e,t,n){if(n=n||[],this.isLocked){if(!t)throw new Error("You must provide the key in order to transition");if(!this.hasLock(t))throw new Error("Could not transition using the key for "+t.name+" because "+this._lock.name+" has the lock")}else if(t)throw new Error("Key provided for "+t.name+", but the StateMachine was not locked (possibly due to preemption)");if(!u(this._states,this.state,e))throw new Error('Cannot transition from "'+this.state+'" to "'+e+'"');this._state=e,this.emit.apply(this,a([],o(["stateChanged",e].concat(n))))},t.prototype.tryTransition=function(e,t,n){try{this.transition(e,t,n)}catch(e){return!1}return!0},t.prototype.when=function(e){var t=this;return this.state===e?Promise.resolve(this):u(this._reachableStates,this.state,e)?this._whenPromise((function(n,r,i){n===e?r(t):u(t._reachableStates,n,e)||i(p(n,e))})):Promise.reject(p(this.state,e))},t}(s);function u(e,t,n){return e.get(t).has(n)}function p(e,t){return new Error('"'+t+'" cannot be reached from "'+e+'"')}t.exports=c},{"./util":472,events:222}],429:[function(e,t,n){"use strict";t.exports=function(e){return(e=e.filter((function(e){return"number"==typeof e}))).length<1?void 0:e.reduce((function(e,t){return t+e}))/e.length}},{}],430:[function(e,t,n){"use strict";var r=function(){function e(e,t,n,r){Object.defineProperties(this,{availableSend:{enumerable:!0,value:n},recv:{enumerable:!0,value:t},rtt:{enumerable:!0,value:r},send:{enumerable:!0,value:e}})}return e.of=function(t,n){var r=(n.timestamp-t.timestamp)/1e3,i=n.bytesSent-t.bytesSent,o=n.bytesReceived-t.bytesReceived;return new e(r>0?i/r*8:0,r>0?o/r*8:0,n.availableOutgoingBitrate,n.currentRoundTripTime)},e}();t.exports=r},{}],431:[function(e,t,n){"use strict";var r=e("./icereport"),i=function(){function e(){Object.defineProperties(this,{lastReport:{enumerable:!0,value:new r(0,0),writable:!0},lastStats:{enumerable:!0,value:null,writable:!0}})}return e.prototype.next=function(e){var t=this.lastStats;if(this.lastStats=e,t){var n=t.id===e.id?r.of(t,e):new r(0,0);this.lastReport=n}return this.lastReport},e}();t.exports=i},{"./icereport":430}],432:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r){var i=e.call(this,t,n,r)||this;return Object.defineProperties(i,{audioLevel:{value:"number"==typeof n.audioInput
164Level?n.audioInputLevel:null,enumerable:!0},jitter:{value:"number"==typeof n.jitter?n.jitter:null,enumerable:!0}}),i}return i(t,e),t}(e("./localtrackstats"));t.exports=o},{"./localtrackstats":433}],433:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r){var i=e.call(this,t,n)||this;return Object.defineProperties(i,{bytesSent:{value:"number"==typeof n.bytesSent?n.bytesSent:r?0:null,enumerable:!0},packetsSent:{value:"number"==typeof n.packetsSent?n.packetsSent:r?0:null,enumerable:!0},roundTripTime:{value:"number"==typeof n.roundTripTime?n.roundTripTime:r?0:null,enumerable:!0}}),i}return i(t,e),t}(e("./trackstats"));t.exports=o},{"./trackstats":458}],434:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n,r){var i=e.call(this,t,n,r)||this,o=null;"number"==typeof n.frameWidthInput&&"number"==typeof n.frameHeightInput&&(o={},Object.defineProperties(o,{width:{value:n.frameWidthInput,enumerable:!0},height:{value:n.frameHeightInput,enumerable:!0}}));var a=null;return"number"==typeof n.frameWidthSent&&"number"==typeof n.frameHeightSent&&(a={},Object.defineProperties(a,{width:{value:n.frameWidthSent,enumerable:!0},height:{value:n.frameHeightSent,enumerable:!0}})),Object.defineProperties(i,{captureDimensions:{value:o,enumerable:!0},dimensions:{value:a,enumerable:!0},captureFrameRate:{value:"number"==typeof n.frameRateInput?n.frameRateInput:null,enumerable:!0},frameRate:{value:"number"==typeof n.frameRateSent?n.frameRateSent:null,enumerable:!0}}),i}return i(t,e),t}(e("./localtrackstats"));t.exports=o},{"./localtrackstats":433}],435:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t){return e.call(this,t)||this}return i(t,e),t}(e("./networkqualitymediastats"));t.exports=o},{"./networkqualitymediastats":439}],436:[function(e,t,n){"use strict";var r=function(e){var t=e.actual,n=void 0===t?null:t,r=e.available,i=void 0===r?null:r,o=e.level,a=void 0===o?null:o;Object.defineProperties(this,{actual:{value:n,enumerable:!0},available:{value:i,enumerable:!0},level:{value:a,enumerable:!0}})};t.exports=r},{}],437:[function(e,t,n){"use strict";var r=function(e){var t=e.fractionLost,n=void 0===t?null:t,r=e.level,i=void 0===r?null:r;Object.defineProperties(this,{fractionLost:{value:n,enumerable:!0},level:{value:i,enumerable:!0}})};t.exports=r},{}],438:[function(e,t,n){"use strict";var r=function(e){var t=e.jitter,n=void 0===t?null:t,r=e.rtt,i=void 0===r?null:r,o=e.level,a=void 0===o?null:o;Object.defineProperties(this,{jitter:{value:n,enumerable:!0},rtt:{value:i,enumerable:!0},level:{value:a,enumerable:!0}})};t.exports=r},{}],439:[function(e,t,n){"use strict";var r=e("./networkqualitysendstats"),i=e("./networkqualityrecvstats"),o=function(e){var t=e.send,n=e.recv,o=e.sendStats,a=void 0===o?null:o,s=e.recvStats,l=void 0===s?null:s;Object.defineProperties(this,{send:{value:t,enumerable:!0},recv:{value:n,enumerable:!0},sendStats:{value:a?new r(a):null,enumerable:!0},recvStats:{value:l?new i(l):null,enumerable:!0}})};t.exports=o},{"./networkqualityrecvstats":440,"./networkqualitysendstats":442}],440:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t){return e.call(this,t)||this}return i(t,e),t}(e("./networkqualitysendorrecvstats"));t.exports=o},{"./networkqualitysendorrecvstats":441}],441:[function(e,t,n){"use strict";var r=e("./networkqualitybandwidthstats"),i=e("./networkqualityfractionloststats"),o=e("./networkqualitylatencystats"),a=function(e){var t=e.bandwidth,n=void 0===t?null:t,a=e.fractionLost,s=void 0===a?null:a,l=e.latency,c=void 0===l?null:l;Object.defineProperties(this,{bandwidth:{value:n?new r(n):null,enumerable:!0},fractionLost:{value:s?new i(s):null,enumerable:!0},latency:{value:c?new o(c):null,enumerable:!0}})};t.exports=a},{"./networkqualitybandwidthstats":436,"./networkqualityfractionloststats":437,"./networkqualitylatencystats":438}],442:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t){return e.call(this,t)||this}return i(t,e),t}(e("./networkqualitysendorrecvstats"));t.exports=o},{"./networkqualitysendorrecvstats":441}],443:[function(e,t,n){"use strict";var r=e("./networkqualityaudiostats"),i=e("./networkqualityvideostats"),o=function(e){var t=e.level,n=e.audio,o=e.video;Object.defineProperties(this,{level:{value:t,enumerable:!0},audio:{value:n?new r(n):null,enumerable:!0},video:{value:o?new i(o):null,enumerable:!0}})};t.exports=o},{"./networkqualityaudiostats":435,"./networkqualityvideostats":444}],444:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t){return e.call(this,t)||this}return i(t,e),t}(e("./networkqualitymediastats"));t.exports=o},{"./networkqualitymediastats":439}],445:[function(e,t,n){"use strict";var r=e("./receiverreport"),i=e("./senderreport"),o=function(){function e(e,t,n){Object.defineProperties(this,{ice:{enumerable:!0,value:e},audio:{enumerable:!0,value:t},video:{enumerable:!0,value:n}})}return e.prototype.summarize=function(){var e=this.audio.send.concat(this.video.send),t=i.summarize(e),n=this.audio.recv.concat(this.video.recv),o=r.summarize(n);return{ice:this.ice,send:t,recv:o,audio:{send:i.summarize(this.audio.send),recv:r.summarize(this.audio.recv)},video:{send:i.summarize(this.video.send),recv:r.summarize(this.video.recv)}}},e}();t.exports=o},{"./receiverreport":447,"./senderreport":454}],446:[function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},o=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);
164if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},a=e("../webrtc/util").guessBrowser,s=e("./icereportfactory"),l=e("./peerconnectionreport"),c=e("./receiverreportfactory"),u=e("./senderreportfactory"),p=function(){function e(e){Object.defineProperties(this,{pc:{enumerable:!0,value:e},ice:{enumerable:!0,value:new s},audio:{enumerable:!0,value:{send:new Map,recv:new Map}},video:{enumerable:!0,value:{send:new Map,recv:new Map}},lastReport:{enumerable:!0,value:null,writable:!0}})}return e.prototype.next=function(){var e,t,n,o=this;return("firefox"===a()?(t=(e=this).pc.getTransceivers().filter((function(e){return e.currentDirection&&e.currentDirection.match(/send/)&&e.sender.track})).map((function(e){return e.sender})),n=e.pc.getTransceivers().filter((function(e){return e.currentDirection&&e.currentDirection.match(/recv/)})).map((function(e){return e.receiver})),Promise.all([f(t),f(n),e.pc.getStats()]).then((function(t){var n=r(t,3),i=n[0],o=n[1],a=n[2],s=h(e),l=v(e);i.forEach((function(t,n){return w(e,t,l,n)})),_(s,l);var c=m(e),u=g(e);o.forEach((function(t,n){return C(e,t,u,n)})),_(c,u),k(e.ice,a)}))):function(e){return e.pc.getStats().then((function(t){var n=h(e),r=v(e);w(e,t,r),_(n,r);var i=m(e),o=g(e);C(e,t,o),_(i,o),k(e.ice,t)}))}(this)).then((function(){var e=i([],r(o.audio.send.values())),t=i([],r(o.video.send.values())),n=i([],r(o.audio.recv.values())),a=i([],r(o.video.recv.values())),s=new l(o.ice.lastReport,{send:e.map((function(e){return e.lastReport})).filter((function(e){return e})),recv:n.map((function(e){return e.lastReport})).filter((function(e){return e}))},{send:t.map((function(e){return e.lastReport})).filter((function(e){return e})),recv:a.map((function(e){return e.lastReport})).filter((function(e){return e}))});return o.lastReport=s,s}))},e}();function f(e){return Promise.all(e.map((function(e){var t=e.track.id;return e.getStats().then((function(e){var n,r;try{for(var i=o(e.values()),a=i.next();!a.done;a=i.next()){var s=a.value;"inbound-rtp"===s.type&&(s.id=t+"-"+s.id)}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}return[t,e]}))}))).then((function(e){return new Map(e)}))}function d(e,t,n,r,i){var o=t[r.mediaType];if(!i){var a=n.get(r.trackId);a&&(i=a.trackIdentifier)}if(o&&i){if(o.has(r.id))return o.get(r.id);var s=new e(i,r);o.set(r.id,s)}return null}function h(e){return{audio:e.audio.send,video:e.video.send}}function m(e){return{audio:e.audio.recv,video:e.video.recv}}function y(e,t,n,r){return d(u,h(e),t,n,r)}function b(e,t,n,r){return d(c,m(e),t,n,r)}function v(e){return{audio:new Set(e.audio.send.keys()),video:new Set(e.video.send.keys())}}function g(e){return{audio:new Set(e.audio.recv.keys()),video:new Set(e.video.recv.keys())}}function w(e,t,n,r){var i,s;try{for(var l=o(t.values()),c=l.next();!c.done;c=l.next()){var u=c.value;if("outbound-rtp"===u.type&&!u.isRemote){if("firefox"!==a()&&!u.trackId)continue;var p=n[u.mediaType];p&&p.delete(u.id);var f=y(e,t,u,r);if(f){var d=t.get(u.remoteId);f.next(r||f.trackId,u,d)}}}}catch(e){i={error:e}}finally{try{c&&!c.done&&(s=l.return)&&s.call(l)}finally{if(i)throw i.error}}}function C(e,t,n,r){var i,a;try{for(var s=o(t.values()),l=s.next();!l.done;l=s.next()){var c=l.value;if("inbound-rtp"===c.type&&!c.isRemote){var u=n[c.mediaType];u&&u.delete(c.id);var p=b(e,t,c,r);p&&p.next(r||p.trackId,c)}}}catch(e){i={error:e}}finally{try{l&&!l.done&&(a=s.return)&&a.call(s)}finally{if(i)throw i.error}}}function _(e,t){var n=function(n){var r=e[n];t[n].forEach((function(e){return r.delete(e)}))};for(var r in t)n(r)}function k(e,t){var n,r,i,a,s;try{for(var l=o(t.values()),c=l.next();!c.done;c=l.next()){"transport"===(f=c.value).type&&(s=t.get(f.selectedCandidatePairId))}}catch(e){n={error:e}}finally{try{c&&!c.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}if(s)e.next(s);else try{for(var u=o(t.values()),p=u.next();!p.done;p=u.next()){var f;"candidate-pair"!==(f=p.value).type||!f.nominated||"selected"in f&&!f.selected||e.next(f)}}catch(e){i={error:e}}finally{try{p&&!p.done&&(a=u.return)&&a.call(u)}finally{if(i)throw i.error}}}t.exports=p},{"../webrtc/util":510,"./icereportfactory":431,"./peerconnectionreport":445,"./receiverreportfactory":448,"./senderreportfactory":455}],447:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./average"),a=e("./senderorreceiverreport"),s=e("./sum"),l=function(e){function t(t,n,r,i,o,a,s){var l=e.call(this,t,n,r)||this,c=o>0?i/o:0;return Object.defineProperties(l,{deltaPacketsLost:{enumerable:!0,value:i},deltaPacketsReceived:{enumerable:!0,value:o},fractionLost:{enumerable:!0,value:a},jitter:{enumerable:!0,value:s},phonyFractionLost:{enumerable:!0,value:c}}),l}return i(t,e),t.of=function(e,n,r){if(n.id!==r.id)throw new Error("RTCStats IDs must match");var i=(r.timestamp-n.timestamp)/1e3,o=r.bytesReceived-n.bytesReceived,a=i>0?o/i*8:0,s=Math.max(r.packetsLost-n.packetsLost,0),l=r.packetsReceived-n.packetsReceived,c=r.fractionLost,u=r.jitter;return new t(n.id,e,a,s,l,c,u)},t.summarize=function(e){var t=e.map((function(e){return e.summarize()}));return{bitrate:s(t.map((function(e){return e.bitrate}
164))),fractionLost:o(t.map((function(e){return e.fractionLost}))),jitter:o(t.map((function(e){return e.jitter})))}},t.prototype.summarize=function(){return{bitrate:this.bitrate,fractionLost:"number"==typeof this.fractionLost?this.fractionLost:this.phonyFractionLost,jitter:this.jitter}},t}(a);t.exports=l},{"./average":429,"./senderorreceiverreport":452,"./sum":457}],448:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./receiverreport"),a=function(e){function t(t,n){var r=e.call(this,n.id,t,n)||this;return Object.defineProperties(r,{lastReport:{enumerable:!0,value:null,writable:!0}}),r}return i(t,e),t.prototype.next=function(e,t){var n=this.lastStats;this.lastStats=t,this.trackId=e;var r=o.of(e,n,t);return this.lastReport=r,r},t}(e("./senderorreceiverreportfactory"));t.exports=a},{"./receiverreport":447,"./senderorreceiverreportfactory":453}],449:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this,t,n)||this;return Object.defineProperties(r,{audioLevel:{value:"number"==typeof n.audioOutputLevel?n.audioOutputLevel:null,enumerable:!0},jitter:{value:"number"==typeof n.jitter?n.jitter:null,enumerable:!0}}),r}return i(t,e),t}(e("./remotetrackstats"));t.exports=o},{"./remotetrackstats":450}],450:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this,t,n)||this;return Object.defineProperties(r,{bytesReceived:{value:"number"==typeof n.bytesReceived?n.bytesReceived:null,enumerable:!0},packetsReceived:{value:"number"==typeof n.packetsReceived?n.packetsReceived:null,enumerable:!0}}),r}return i(t,e),t}(e("./trackstats"));t.exports=o},{"./trackstats":458}],451:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this,t,n)||this,i=null;return"number"==typeof n.frameWidthReceived&&"number"==typeof n.frameHeightReceived&&(i={},Object.defineProperties(i,{width:{value:n.frameWidthReceived,enumerable:!0},height:{value:n.frameHeightReceived,enumerable:!0}})),Object.defineProperties(r,{dimensions:{value:i,enumerable:!0},frameRate:{value:"number"==typeof n.frameRateReceived?n.frameRateReceived:null,enumerable:!0}}),r}return i(t,e),t}(e("./remotetrackstats"));t.exports=o},{"./remotetrackstats":450}],452:[function(e,t,n){"use strict";var r=function(e,t,n){Object.defineProperties(this,{id:{enumerable:!0,value:e},trackId:{enumerable:!0,value:t},bitrate:{enumerable:!0,value:n}})};t.exports=r},{}],453:[function(e,t,n){"use strict";var r=function(e,t,n){Object.defineProperties(this,{id:{enumerable:!0,value:e,writable:!0},trackId:{enumerable:!0,value:t,writable:!0},lastStats:{enumerable:!0,value:n,writable:!0}})};t.exports=r},{}],454:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./average"),a=e("./senderorreceiverreport"),s=e("./sum"),l=function(e){function t(t,n,r,i){var o=e.call(this,t,n,r)||this;return Object.defineProperties(o,{rtt:{enumerable:!0,value:i}}),o}return i(t,e),t.of=function(e,n,r,i){if(n.id!==r.id)throw new Error("RTCStats IDs must match");var o=(r.timestamp-n.timestamp)/1e3,a=r.bytesSent-n.bytesSent,s=o>0?a/o*8:0,l=i&&"number"==typeof i.roundTripTime?i.roundTripTime/1e3:void 0;return new t(n.id,e,s,l)},t.summarize=function(e){return{bitrate:s(e.map((function(e){return e.bitrate}
164))),rtt:o(e.map((function(e){return e.rtt})))}},t}(a);t.exports=l},{"./average":429,"./senderorreceiverreport":452,"./sum":457}],455:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./senderorreceiverreportfactory"),a=e("./senderreport"),s=function(e){function t(t,n){var r=e.call(this,n.id,t,n)||this;return Object.defineProperties(r,{lastReport:{enumerable:!0,value:null,writable:!0}}),r}return i(t,e),t.prototype.next=function(e,t,n){var r=this.lastStats;this.lastStats=t,this.trackId=e;var i=a.of(e,r,t,n);return this.lastReport=i,i},t}(o);t.exports=s},{"./senderorreceiverreportfactory":453,"./senderreport":454}],456:[function(e,t,n){"use strict";var r=e("./localaudiotrackstats"),i=e("./localvideotrackstats"),o=e("./remoteaudiotrackstats"),a=e("./remotevideotrackstats"),s=function(e,t,n){if("string"!=typeof e)throw new Error("RTCPeerConnection id must be a string");Object.defineProperties(this,{peerConnectionId:{value:e,enumerable:!0},localAudioTrackStats:{value:t.localAudioTrackStats.map((function(e){return new r(e.trackId,e,n)})),enumerable:!0},localVideoTrackStats:{value:t.localVideoTrackStats.map((function(e){return new i(e.trackId,e,n)})),enumerable:!0},remoteAudioTrackStats:{value:t.remoteAudioTrackStats.map((function(e){return new o(e.trackId,e)})),enumerable:!0},remoteVideoTrackStats:{value:t.remoteVideoTrackStats.map((function(e){return new a(e.trackId,e)})),enumerable:!0}})};t.exports=s},{"./localaudiotrackstats":432,"./localvideotrackstats":434,"./remoteaudiotrackstats":449,"./remotevideotrackstats":451}],457:[function(e,t,n){"use strict";t.exports=function(e){return e.reduce((function(e,t){return"number"==typeof t?t+e:e}),0)}},{}],458:[function(e,t,n){"use strict";var r=function(e,t){if("string"!=typeof e)throw new Error("Track id must be a string");Object.defineProperties(this,{trackId:{value:e,enumerable:!0},trackSid:{value:t.trackSid,enumerable:!0},timestamp:{value:t.timestamp,enumerable:!0},ssrc:{value:t.ssrc,enumerable:!0},packetsLost:{value:"number"==typeof t.packetsLost?t.packetsLost:null,enumerable:!0},codec:{value:"string"==typeof t.codecName?t.codecName:null,enumerable:!0}})};t.exports=r},{}],459:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var r=e.call(this)||this;return Object.defineProperties(r,{id:{enumerable:!0,value:t},kind:{enumerable:!0,value:n}}),r}return i(t,e),t.prototype.stop=function(){this.emit("stopped")},t}(e("./queueingeventemitter"));t.exports=o},{"./queueingeventemitter":395}],460:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("./statemachine"),l=e("./util"),c=l.buildLogLevels,u=l.makeUUID,p=e("./util/log"),f=e("./util/networkmonitor"),d=e("./util/timeout"),h=0,m={closed:[],connecting:["closed","open","waiting"],early:["closed","connecting"],open:["closed"],waiting:["closed","connecting","early","open"]}
164,y={closed:"close",open:"open",waiting:"waiting"},b=globalThis,v=b.WebSocket?b.WebSocket:e("ws"),g={BUSY:"busy",FAILED:"failed",LOCAL:"local",REMOTE:"remote",TIMEOUT:"timeout"},w=new Map([[3e3,g.TIMEOUT],[3001,g.TIMEOUT],[3002,g.FAILED],[3003,g.FAILED],[3004,g.TIMEOUT],[3006,g.BUSY],[3007,g.TIMEOUT]]),C=function(e){function t(t,n){var r=e.call(this,"early",m)||this;n=Object.assign({helloBody:null,maxConsecutiveFailedHellos:3,maxConsecutiveMissedHeartbeats:3,requestedHeartbeatTimeout:5e3,openTimeout:15e3,welcomeTimeout:5e3,Log:p,WebSocket:v},n);var i=c(n.logLevel),s=new n.Log("default",r,i,n.loggerName),l=n.networkMonitor?new f((function(){var e=l.type,t="Network changed"+(e?" to "+e:"");s.debug(t),r._close({code:3004,reason:t})})):null;Object.defineProperties(r,{_busyWaitTimeout:{value:null,writable:!0},_consecutiveHeartbeatsMissed:{value:0,writable:!0},_cookie:{value:null,writable:!0},_eventObserver:{value:n.eventObserver},_heartbeatTimeout:{value:null,writable:!0},_hellosLeft:{value:n.maxConsecutiveFailedHellos,writable:!0},_instanceId:{value:++h},_log:{value:s},_messageQueue:{value:[]},_networkMonitor:{value:l},_options:{value:n},_openTimeout:{value:null,writable:!0},_sendHeartbeatTimeout:{value:null,writable:!0},_serverUrl:{value:t},_welcomeTimeout:{value:null,writable:!0},_ws:{value:null,writable:!0}});var u={connecting:"info",early:"info",open:"info",waiting:"warning",closed:"info"};return r.on("stateChanged",(function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e in y&&r.emit.apply(r,a([y[e]],o(t)));var i={name:e,group:"signaling",level:u[r.state]};if("closed"===e){var s=o(t,1),l=s[0];i.payload={reason:l},i.level=l===g.LOCAL?"info":"error"}r._eventObserver.emit("event",i)})),r._eventObserver.emit("event",{name:r.state,group:"signaling",level:u[r.state]}),r._connect(),r}return i(t,e),t.prototype.toString=function(){return"[TwilioConnection #"+this._instanceId+": "+this._ws.url+"]"},t.prototype._close=function(e){var t=e.code,n=e.reason;if("closed"!==this.state){this._openTimeout&&this._openTimeout.clear(),this._welcomeTimeout&&this._welcomeTimeout.clear(),this._heartbeatTimeout&&this._heartbeatTimeout.clear(),this._sendHeartbeatTimeout&&this._sendHeartbeatTimeout.clear(),this._networkMonitor&&this._networkMonitor.stop(),this._busyWaitTimeout&&3005!==t&&this._busyWaitTimeout.clear(),this._messageQueue.splice(0);var r=this._log;1e3===t?(r.debug("Closed"),this.transition("closed",null,[g.LOCAL])):(r.warn("Closed: "+t+" - "+n),3005!==t&&this.transition("closed",null,[w.get(t)||g.REMOTE]));var i=this._ws.readyState,o=this._options.WebSocket;i!==o.CLOSING&&i!==o.CLOSED&&this._ws.close(t,n)}},t.prototype._connect=function(){var e=this,t=this._log;if("waiting"===this.state)this.transition("early");else if("early"!==this.state)return void t.warn('Unexpected state "'+this.state+'" for connecting to the TCMP server.');this._ws=new this._options.WebSocket(this._serverUrl);var n=this._ws;t.debug("Created a new WebSocket:",n),n.addEventListener("close",(function(t){return e._close(t)}));var r=this._options.openTimeout;this._openTimeout=new d((function(){var t="Failed to open in "+r+" ms";e._close({code:3007,reason:t})}),r),n.addEventListener("open",(function(){t.debug("WebSocket opened:",n),e._openTimeout.clear(),e._startHandshake(),e._networkMonitor&&e._networkMonitor.start()})),n.addEventListener("message",(function(n){t.debug("Incoming: "+n.data);try{n=JSON.parse(n.data)}catch(t){return void e.emit("error",t)}switch(n.type){case"bad":e._handleBad(n);break;case"busy":e._handleBusy(n);break;case"bye":break;case"msg":e._handleMessage(n);case"heartbeat":e._handleHeartbeat();break;case"welcome":e._handleWelcome(n);break;default:e._log.debug("Unknown message type: "+n.type),e.emit("error",new Error("Unknown message type: "+n.type))}}))},t.prototype._handleBad=function(e){var t=e.reason,n=this._log;if(["connecting","open"].includes(this.state)){if("connecting"===this.state)return n.warn("Closing: 3002 - "+t),void this._close({code:3002,reason:t});n.debug("Error: "+t),this.emit("error",new Error(t))}else n.warn('Unexpected state "'+this.state+'" for handling a "bad" message from the TCMP server.')},t.prototype._handleBusy=function(e){var t=this,n=e.cookie,r=e.keepAlive,i=e.retryAfter,o=this._log;if(["connecting","waiting"].includes(this.state)){this._busyWaitTimeout&&this._busyWaitTimeout.clear(),this._welcomeTimeout&&this._welcomeTimeout.clear();var a=i<0?'Received terminal "busy" message':'Received "busy" message, retrying after '+i+" ms";if(i<0)return o.warn("Closing: 3006 - "+a),void this._close({code:3006,reason:a});var s=this._options.maxConsecutiveFailedHellos;this._hellosLeft=s,this._cookie=n||null,r?(o.warn(a),this._busyWaitTimeout=new d((function(){return t._startHandshake()}),i)):(o.warn("Closing: 3005 - "+a),this._close({code:3005,reason:a}),this._busyWaitTimeout=new d((function(){return t._connect()}),i)),this.transition("waiting",null,[r,i])}else o.warn('Unexpected state "'+this.state+'" for handling a "busy" message from the TCMP server.')},t.prototype._handleHeartbeat=function(){"open"===this.state?this._heartbeatTimeout.reset():this._log.warn('Unexpected state "'+this.state+'" for handling a "heartbeat" message from the TCMP server.')},t.prototype._handleHeartbeatTimeout=function(){if("open"===this.state){var e=this._log,t=this._options.maxConsecutiveMissedHeartbeats;e.debug("Consecutive heartbeats missed: "+t);var n="Missed "+t+' "heartbeat" messages';e.warn("Closing: 3001 - "+n),this._close({code:3001,reason:n})}},t.prototype._handleMessage=function(e){var t=e.body;
164"open"===this.state?this.emit("message",t):this._log.warn('Unexpected state "'+this.state+'" for handling a "msg" message from the TCMP server.')},t.prototype._handleWelcome=function(e){var t=this,n=e.negotiatedTimeout,r=this._log;if(["connecting","waiting"].includes(this.state)){"waiting"===this.state&&(r.debug('Received "welcome" message, no need to retry connection.'),this._busyWaitTimeout.clear());var i=n*this._options.maxConsecutiveMissedHeartbeats,o=n-200;this._welcomeTimeout.clear(),this._heartbeatTimeout=new d((function(){return t._handleHeartbeatTimeout()}),i),this._messageQueue.splice(0).forEach((function(e){return t._send(e)})),this._sendHeartbeatTimeout=new d((function(){return t._sendHeartbeat()}),o),this.transition("open")}else r.warn('Unexpected state "'+this.state+'" for handling a "welcome" message from the TCMP server.')},t.prototype._handleWelcomeTimeout=function(){if("connecting"===this.state){var e=this._log;if(this._hellosLeft<=0){var t="All handshake attempts failed";return e.warn("Closing: 3000 - "+t),void this._close({code:3e3,reason:t})}var n=this._options.maxConsecutiveFailedHellos;e.warn("Handshake attempt "+(n-this._hellosLeft)+" failed"),this._startHandshake()}},t.prototype._send=function(e){if(this._ws.readyState===this._options.WebSocket.OPEN){var t=JSON.stringify(e);this._log.debug("Outgoing: "+t);try{this._ws.send(t),this._sendHeartbeatTimeout&&this._sendHeartbeatTimeout.reset()}catch(e){var n="Failed to send message";this._log.warn("Closing: 3003 - "+n),this._close({code:3003,reason:n})}}},t.prototype._sendHeartbeat=function(){"closed"!==this.state&&this._send({type:"heartbeat"})},t.prototype._sendHello=function(){var e=this._options,t=e.helloBody,n=e.requestedHeartbeatTimeout,r={id:u(),timeout:n,type:"hello",version:2};this._cookie&&(r.cookie=this._cookie),t&&(r.body=t),this._send(r)},t.prototype._sendOrEnqueue=function(e){var t=this;"closed"!==this.state&&("open"===this.state?function(e){return t._send(e)}:function(e){return t._messageQueue.push(e)})(e)},t.prototype._startHandshake=function(){var e=this;if(["early","waiting"].includes(this.state)&&this.transition("connecting"),"connecting"===this.state){this._hellosLeft--,this._sendHello();var t=this._options.welcomeTimeout;this._welcomeTimeout=new d((function(){return e._handleWelcomeTimeout()}),t)}},t.prototype.close=function(){"closed"!==this.state&&(this._sendOrEnqueue({type:"bye"}),this._close({code:1e3,reason:"Normal"}))},t.prototype.sendMessage=function(e){this._sendOrEnqueue({body:e,type:"msg"})},t}(s);C.CloseReason=g,t.exports=C},{"./statemachine":428,"./util":472,"./util/log":476,"./util/networkmonitor":478,"./util/timeout":486,ws:514}],461:[function(e,t,n){"use strict";var r=e("./").defer,i=function(){function e(){Object.defineProperties(this,{_deferreds:{value:[]},_hasValue:{value:!1,writable:!0},_value:{value:null,writable:!0}})}return e.prototype.put=function(e){this._hasValue=!0,this._value=e;var t=this._deferreds.shift();return t&&t.resolve(e),this},e.prototype.take=function(){var e=this;if(this._hasValue&&!this._deferreds.length)return this._hasValue=!1,Promise.resolve(this._value);var t=r();return this._deferreds.push(t),t.promise.then((function(t){return e._hasValue=!1,t}))},e}();t.exports=i},{"./":472}],462:[function(e,t,n){var r=function(){function e(e){Object.defineProperties(this,{_min:{value:e.min||100},_max:{value:e.max||1e4},_jitter:{value:e.jitter>0&&e.jitter<=1?e.jitter:0},_factor:{value:e.factor||2},_attempts:{value:0,writable:!0},_duration:{enumerable:!1,get:function(){var e=this._min*Math.pow(this._factor,this._attempts);if(this._jitter){var t=Math.random(),n=Math.floor(t*this._jitter*e);e=0==(1&Math.floor(10*t))?e-n:e+n}return 0|Math.min(e,this._max)}},_timeoutID:{value:null,writable:!0}})}return e.prototype.backoff=function(e){var t=this,n=this._duration;this._timeoutID&&(clearTimeout(this._timeoutID),this._timeoutID=null),this._timeoutID=setTimeout((function(){t._attempts++,e()}),n)},e.prototype.reset=function(){this._attempts=0,this._timeoutID&&(clearTimeout(this._timeoutID),this._timeoutID=null)},e}();t.exports=r},{}],463:[function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a};function i(){return!!(navigator&&navigator.maxTouchPoints&&navigator.maxTouchPoints>2)}function o(){return i()&&window.screen.width>=744&&(/Macintosh/i.test(navigator.userAgent)||/iPad/.test(navigator.userAgent)||/iPad/.test(navigator.platform))}function a(){return i()&&window.screen.width<=476&&(/Macintosh/i.test(navigator.userAgent)||/iPhone/.test(navigator.userAgent)||/iPhone/.test(navigator.platform))}t.exports={isAndroid:function(){return/Android/.test(navigator.userAgent)},isIOS:function(){return o()||a()},isIpad:o,isIphone:a,isMobile:function(){return/Mobi/.test(navigator.userAgent)},isNonChromiumEdge:function(e){return"chrome"===e&&/Edge/.test(navigator.userAgent)&&("undefined"==typeof chrome||void 0===chrome.runtime)},mobileWebKitBrowser:function(e){return"safari"!==e?null:"brave"in navigator?"brave":["edge","edg"].find((function(e){return navigator.userAgent.toLowerCase().includes(e)}))||null},rebrandedChromeBrowser:function(e){if("chrome"!==e)return null;if("brave"in navigator)return"brave";var t=function(e){for(var t=[],n=[],r=0;r<e.length;r++)if("("===e[r])t.push(r);else if(")"===e[r]&&t.length>0){var i=t.pop();0===t.length&&n.push(e.substring(i,r+1))}return n}(navigator.userAgent).reduce((function(e,t){return e.replace(t,"")}),navigator.userAgent).match(/[^\s]+/g)||[];return r(t.map((function(e){return e.split("/")[0].toLowerCase()}))).slice(2).find((function(e){return!["chrome","mobile","safari"].includes(e)}))||null}}},{}],464:[function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},o=function(){function e(e,t){var n=this;Object.defineProperties(this,{_isCancelable:{writable:!0,value:!0},_isCanceled:{writable:!0,value:!1},_onCancel:{value:t}}),Object.defineProperty(this,"_promise",{value:new Promise((function(t,r){e((function(e){n._isCancelable=!1,t(e)}),(function(e){n._isCancelable=!1,r(e)}),(function(){return n._isCanceled}))}))})}
164return e.reject=function(t){return new e((function(e,n){n(t)}),(function(){}))},e.resolve=function(t){return new e((function(e){e(t)}),(function(){}))},e.prototype.cancel=function(){return this._isCancelable&&(this._isCanceled=!0,this._onCancel()),this},e.prototype.catch=function(){var t=[].slice.call(arguments),n=this._promise;return new e((function(e,o){n.catch.apply(n,i([],r(t))).then(e,o)}),this._onCancel)},e.prototype.then=function(){var t=[].slice.call(arguments),n=this._promise;return new e((function(e,o){n.then.apply(n,i([],r(t))).then(e,o)}),this._onCancel)},e.prototype.finally=function(){var t=[].slice.call(arguments),n=this._promise;return new e((function(e,o){n.finally.apply(n,i([],r(t))).then(e,o)}),this._onCancel)},e}();t.exports=o},{}],465:[function(e,t,n){"use strict";var r=e("../../package.json");t.exports.SDK_NAME=r.name+".js",t.exports.SDK_VERSION=r.version,t.exports.SDP_FORMAT="unified",t.exports.hardwareDevicePublisheriPad={hwDeviceManufacturer:"Apple",hwDeviceModel:"iPad",hwDeviceType:"tablet",platformName:"iOS"},t.exports.hardwareDevicePublisheriPhone={hwDeviceManufacturer:"Apple",hwDeviceModel:"iPhone",hwDeviceType:"mobile",platformName:"iOS"},t.exports.DEFAULT_ENVIRONMENT="prod",t.exports.DEFAULT_REALM="us1",t.exports.DEFAULT_REGION="gll",t.exports.DEFAULT_LOG_LEVEL="warn",t.exports.DEFAULT_LOGGER_NAME="twilio-video",t.exports.WS_SERVER=function(e,t){return t="gll"===t?"global":encodeURIComponent(t),"prod"===e?"wss://"+t+".vss.twilio.com/signaling":"wss://"+t+".vss."+e+".twilio.com/signaling"}
164,t.exports.PUBLISH_MAX_ATTEMPTS=5,t.exports.PUBLISH_BACKOFF_JITTER=10,t.exports.PUBLISH_BACKOFF_MS=20,t.exports.typeErrors={ILLEGAL_INVOKE:function(e,t){return new TypeError("Illegal call to "+e+": "+t)},INVALID_TYPE:function(e,t){return new TypeError(e+" must be "+((["a","e","i","o","u"].includes(t.toLowerCase()[0])?"an":"a")+" ")+t)},INVALID_VALUE:function(e,t){return new RangeError(e+" must be one of "+t.join(", "))},REQUIRED_ARGUMENT:function(e){return new TypeError(e+" must be specified")}},t.exports.DEFAULT_FRAME_RATE=24,t.exports.DEFAULT_VIDEO_PROCESSOR_STATS_INTERVAL_MS=1e4,t.exports.DEFAULT_ICE_GATHERING_TIMEOUT_MS=15e3,t.exports.DEFAULT_SESSION_TIMEOUT_SEC=30,t.exports.DEFAULT_NQ_LEVEL_LOCAL=1,t.exports.DEFAULT_NQ_LEVEL_REMOTE=0,t.exports.MAX_NQ_LEVEL=3,t.exports.ICE_ACTIVITY_CHECK_PERIOD_MS=1e3,t.exports.ICE_INACTIVITY_THRESHOLD_MS=3e3,t.exports.iceRestartBackoffConfig={factor:1.1,min:1,max:1e3*t.exports.DEFAULT_SESSION_TIMEOUT_SEC,jitter:1},t.exports.reconnectBackoffConfig={factor:1.5,min:80,jitter:1},t.exports.subscriptionMode={MODE_COLLABORATION:"collaboration",MODE_GRID:"grid",MODE_PRESENTATION:"presentation"},t.exports.trackSwitchOffMode={MODE_DISABLED:"disabled",MODE_DETECTED:"detected",MODE_PREDICTED:"predicted"},t.exports.trackPriority={PRIORITY_HIGH:"high",PRIORITY_LOW:"low",PRIORITY_STANDARD:"standard"},t.exports.clientTrackSwitchOffControl={MODE_AUTO:"auto",MODE_MANUAL:"manual"},t.exports.videoContentPreferencesMode={MODE_AUTO:"auto",MODE_MANUAL:"manual"}},{"../../package.json":513}],466:[function(e,t,n){"use strict";var r=e("../webaudio/detectsilence");t.exports=function(t){var n=e("../webaudio/audiocontext"),i={},o=n.getOrCreate(i),a=3;return function e(){return a--,r(o,t.srcObject,250).then((function(t){return!!t&&(!(a>0)||e())})).catch((function(){return!0}))}().finally((function(){n.release(i)}))}},{"../webaudio/audiocontext":493,"../webaudio/detectsilence":494}],467:[function(e,t,n){"use strict";var r=null;t.exports=function(e){return r=r||document.createElement("canvas"),new Promise((function(t){var n=3;setTimeout((function i(){return n--,function(e){try{var t=r.getContext("2d");t.drawImage(e,0,0,50,50);var n=t.getImageData(0,0,50,50).data.filter((function(e,t){return(t+1)%4}));return 0===Math.max.apply(Math,n)}catch(e){return console.log("Error checking silence: ",e),!1}}(e)?n>0?setTimeout(i,250):t(!0):t(!1)}),250)}))}},{}],468:[function(e,t,n){"use strict";var r=function(){function e(e){var t=this;void 0===e&&(e=1),Object.defineProperties(this,{_listeners:{value:[]},_onVisibilityChange:{value:function(){t._emitVisible("visible"===document.visibilityState)}}});for(var n=0;n<e;n++)this._listeners.push([])}return e.prototype.clear=function(){for(var e=this._listeners.length,t=0;t<e;t++)this._listeners[t]=[]},e.prototype._listenerCount=function(){return this._listeners.reduce((function(e,t){return e+t.length}),0)},e.prototype._emitVisible=function(e){for(var t=this,n=Promise.resolve(),r=function(r){n=n.then((function(){return t._emitVisiblePhase(r,e)}))},i=1;i<=this._listeners.length;i++)r(i);return n},e.prototype._emitVisiblePhase=function(e,t){var n=this._listeners[e-1];return Promise.all(n.map((function(e){var n=e(t);return n instanceof Promise?n:Promise.resolve(n)})))},e.prototype._start=function(){document.addEventListener("visibilitychange",this._onVisibilityChange)},e.prototype._stop=function(){document.removeEventListener("visibilitychange",this._onVisibilityChange)},e.prototype.onVisibilityChange=function(e,t){if("number"!=typeof e||e<=0||e>this._listeners.length)throw new Error("invalid phase: ",e);return this._listeners[e-1].push(t),1===this._listenerCount()&&this._start(),this},e.prototype.offVisibilityChange=function(e,t){if("number"!=typeof e||e<=0||e>this._listeners.length)throw new Error("invalid phase: ",e);var n=this._listeners[e-1],r=n.indexOf(t);return-1!==r&&(n.splice(r,1),0===this._listenerCount()&&this._stop()),this},e}();t.exports=new r(2)},{}],469:[function(e,t,n){"use strict";t.exports=function(e){var t=e.location,n=e.URL;return[t,n].some((function(e){return!e}))?function(e){return Promise.reject(new Error("Failed to import: "+e+": dynamicImport is not supported"))}:(e.__twilioVideoImportedModules={},function(r){return r in e.__twilioVideoImportedModules?Promise.resolve(e.__twilioVideoImportedModules[r]):new Function("scope","return import('"+new n(r,t)+"').then(m => scope.__twilioVideoImportedModules['"+r+"'] = m);")(e)})}(globalThis)},{}],470:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("events").EventEmitter,a=["signaling","room","media","quality","video-processor","preflight"],s=["debug","error","info","warning"],l=function(e){function t(t,n,r,i){void 0===i&&(i=null);var o=e.call(this)||this;return o.on("event",(function(e){var o=e.name,l=e.group,c=e.level,u=e.payload;if("string"!=typeof o)throw r.error("Unexpected name: ",o),new Error("Unexpected name: ",o);if(!a.includes(l))throw r.error("Unexpected group: ",l),new Error("Unexpected group: ",l);if(!s.includes(c))throw r.error("Unexpected level: ",c),new Error("Unexpected level: ",c);var p=Date.now(),f=p-n,d=Object.assign({elapsedTime:f,level:c},u||{});t.publish(l,o,d);var h=Object.assign({elapsedTime:f,group:l,level:c,name:o,timestamp:p},u?{payload:u}:{});r[{debug:"debug",error:"error",info:"info",warning:"warn"}[c]]("event",h),i&&"signaling"===l&&i.emit("event",h)})),o}return i(t,e),t}(o);t.exports=l},{events:222}],471:[function(e,t,n){"use strict";var r=function(){function e(e){e=Object.assign({getKey:function(e){return e},getValue:function(e){return e},isLessThanOrEqualTo:function(e,t){return e<=t}},e),Object.defineProperties(this,{_getKey:{value:e.getKey},_getValue:{value:e.getValue},_isLessThanOrEqualTo:{value:e.isLessThanOrEqualTo},_map:{value:new Map}})}return e.prototype.toMap=function(){return new Map(this._map)},e.prototype.updateAndFilter=function(e){return e.filter(this.update,this)},e.prototype.update=function(e){var t=this._getKey(e),n=this._getValue(e);return(!this._map.has(t)||!this._isLessThanOrEqualTo(n,this._map.get(t)))&&(this._map.set(t,n),!0)},e}();t.exports=r},{}],472:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("./constants"),l=s.typeErrors,c=s.trackPriority,u=e("../webrtc/util"),p=e("./sid").sessionSID,f=e("./twiliowarning");function d(){return"undefined"!=typeof navigator&&navigator.userAgent?navigator.userAgent:"Unknown"}function h(e,t,n,r){if(!(r in t)&&!r.match(/^on[a-z]+$/)){var i;try{i=typeof e[r]}catch(e){}"function"===i&&(t[r]=function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return(e=this[n])[r].apply(e,a([],o(t)))})}}function m(e){return"object"==typeof e&&!Array.isArray(e)}function y(e){Object.getOwnPropertyNames(e).forEach((function(t){t.startsWith("_")&&b(e,t)}))}function b(e,t){var n=Object.getOwnPropertyDescriptor(e,t);n.enumerable=!1,Object.defineProperty(e,t,n)}function v(e,t){void 0===t&&(t=[]),t.forEach((function(t){e.hasOwnProperty(t)&&b(e,t)}))}function g(e){return e.map(w)}function w(e){return Array.isArray(e)?g(e):e instanceof Set?g(a([],o(e))):e instanceof Map?a([],o(e.entries())).reduce((function(e,t){var n,r=o(t,2),i=r[0],a=r[1];return Object.assign(((n={})[i]=w(a),n),e)}),{}):e&&"object"==typeof e?(t=e,Object.entries(t).reduce((function(e,t){var n,r=o(t,2),i=r[0],a=r[1];return Object.assign(((n={})[i]=w(a),n),e)}),{})):e;var t}function C(e){return S(e,[{prop:"dominantSpeakerPriority",type:"string",payloadProp:"active_speaker_priority"},{prop:"maxSubscriptionBitrate",type:"number",payloadProp:"max_subscription_bandwidth"},{prop:"maxTracks",type:"number",payloadProp:"max_tracks"},{prop:"mode",type:"string"},{prop:"renderDimensions",type:"object",payloadProp:"render_dimensions",transform:k},{prop:"trackSwitchOffMode",type:"string",payloadProp:"track_switch_off"}
164])}function _(e){return S(e,[{prop:"height",type:"number"},{prop:"width",type:"number"}])}function k(e){return S(e,[{prop:c.PRIORITY_HIGH,type:"object",transform:_},{prop:c.PRIORITY_LOW,type:"object",transform:_},{prop:c.PRIORITY_STANDARD,type:"object",transform:_}])}function S(e,t){return t.reduce((function(t,n){var r,i=n.prop,o=n.type,a=n.payloadProp,s=void 0===a?i:a,l=n.transform,c=void 0===l?function(e){return e}:l;return typeof e[i]===o?Object.assign(((r={})[s]=c(e[i]),r),t):t}),{})}n.constants=s,n.createBandwidthProfilePayload=function(e){return S(e,[{prop:"video",type:"object",transform:C}])},n.createMediaSignalingPayload=function(e,t,n,r,i,o){var a={transports:[{type:"data-channel"}]};return Object.assign(e?{active_speaker:a}:{},t?{network_quality:a}:{},o?{render_hints:a}:{},i?{publisher_hints:a}:{},n?{track_priority:a}:{},r?{track_switch_off:a}:{})},n.createMediaWarningsPayload=function(e){var t,n=((t={})[f.recordingMediaLost]="recordings",t);return e.map((function(e){return n[e]})).filter((function(e){return!!e}))},n.createRoomConnectEventPayload=function(e){function t(e){return e?"true":"false"}var n={sessionSID:p,iceServers:(e.iceServers||[]).length,audioTracks:(e.tracks||[]).filter((function(e){return"audio"===e.kind})).length,videoTracks:(e.tracks||[]).filter((function(e){return"video"===e.kind})).length,dataTracks:(e.tracks||[]).filter((function(e){return"data"===e.kind})).length};if([["audio"],["automaticSubscription"],["enableDscp"],["eventListener"],["preflight"],["video"],["dominantSpeaker","enableDominantSpeaker"]].forEach((function(r){var i=o(r,2),a=i[0],s=i[1];n[s=s||a]=t(!!e[a])})),[["maxVideoBitrate"],["maxAudioBitrate"]].forEach((function(t){var r=o(t,2),i=r[0],a=r[1];a=a||i,"number"==typeof e[i]?n[a]=e[i]:isNaN(Number(e[i]))||(n[a]=Number(e[i]))})),[["iceTransportPolicy"],["region"],["name","roomName"]].forEach((function(t){var r=o(t,2),i=r[0],a=r[1];a=a||i,"string"==typeof e[i]?n[a]=e[i]:"number"==typeof e[i]&&"name"===i&&(n[a]=e[i].toString())})),["preferredAudioCodecs","preferredVideoCodecs"].forEach((function(t){t in e&&(n[t]=JSON.stringify(e[t]))})),"networkQuality"in e&&(n.networkQualityConfiguration={},m(e.networkQuality)?["local","remote"].forEach((function(t){"number"==typeof e.networkQuality[t]&&(n.networkQualityConfiguration[t]=e.networkQuality[t])})):(n.networkQualityConfiguration.remote=0,n.networkQualityConfiguration.local=e.networkQuality?1:0)),e.bandwidthProfile&&e.bandwidthProfile.video){var r=e.bandwidthProfile.video||{};n.bandwidthProfileOptions={},["mode","maxTracks","trackSwitchOffMode","dominantSpeakerPriority","maxSubscriptionBitrate","renderDimensions","contentPreferencesMode","clientTrackSwitchOffControl"].forEach((function(e){"number"==typeof r[e]||"string"==typeof r[e]?n.bandwidthProfileOptions[e]=r[e]:"boolean"==typeof r[e]?n.bandwidthProfileOptions[e]=t(r[e]):"object"==typeof r[e]&&(n.bandwidthProfileOptions[e]=JSON.stringify(r[e]))}))}return{group:"room",name:"connect",level:"info",payload:n}},n.createSubscribePayload=function(e){return{rules:[{type:e?"include":"exclude",all:!0}],revision:1}},n.asLocalTrack=function(e,t){if(e instanceof t.LocalAudioTrack||e instanceof t.LocalVideoTrack||e instanceof t.LocalDataTrack)return e;if(e instanceof t.MediaStreamTrack)return"audio"===e.kind?new t.LocalAudioTrack(e,t):new t.LocalVideoTrack(e,t);throw l.INVALID_TYPE("track","LocalAudioTrack, LocalVideoTrack, LocalDataTrack, or MediaStreamTrack")},n.asLocalTrackPublication=function(e,t,n,r){return new(0,{audio:r.LocalAudioTrackPublication,video:r.LocalVideoTrackPublication,data:r.LocalDataTrackPublication}[e.kind])(t,e,n,r)},n.capitalize=function(e){return e[0].toUpperCase()+e.slice(1)},n.deprecateEvents=function(e,t,n,r){var i=new Set;t.on("newListener",(function o(a){n.has(a)&&!i.has(a)&&(r.deprecated(e+"#"+a+" has been deprecated and scheduled for removal in [email protected]."+(n.get(a)?" Use "+e+"#"+n.get(a)+" instead.":"")),i.add(a)),i.size>=n.size&&t.removeListener("newListener",o)}))},n.difference=function(e,t){e=Array.isArray(e)?new Set(e):new Set(e.values()),t=Array.isArray(t)?new Set(t):new Set(t.values());var n=new Set;return e.forEach((function(e){t.has(e)||n.add(e)})),n},n.filterObject=function(e,t){return Object.keys(e).reduce((function(n,r){return e[r]!==t&&(n[r]=e[r]),n}),{})},n.flatMap=function(e,t){var n=e instanceof Map||e instanceof Set?Array.from(e.values()):e;return t=t||function(e){return e},n.reduce((function(e,n){var r=t(n);return e.concat(r)}),[])},n.getPlatform=function(){var e=d(),t=o(e.match(/\(([^)]+)\)/)||[],2)[1];return o((void 0===t?"unknown":t).split(";").map((function(e){return e.trim()})),1)[0].toLowerCase()},n.getUserAgent=d,n.hidePrivateProperties=y,n.hidePrivateAndCertainPublicPropertiesInClass=function(e,t){return function(e){function n(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var i=e.apply(this,a([],o(n)))||this;return y(i),v(i,t),i}return i(n,e),n}(e)},n.isDeepEqual=function e(t,n){if(t===n)return!0;
164if(typeof t!=typeof n)return!1;if(null===t)return null===n;if(null===n)return!1;if(Array.isArray(t))return Array.isArray(n)&&t.length===n.length&&t.every((function(t,r){return e(t,n[r])}));if("object"==typeof t){var r=Object.keys(t).sort(),i=Object.keys(n).sort();return!Array.isArray(n)&&e(r,i)&&r.every((function(r){return e(t[r],n[r])}))}return!1},n.isNonArrayObject=m,n.inRange=function(e,t,n){return t<=e&&e<=n},n.makeUUID=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))},n.oncePerTick=function(e){var t=null;function n(){t=null,e()}return function(){t&&clearTimeout(t),t=setTimeout(n)}},n.promiseFromEvents=function(e,t,n,r){return new Promise((function(i,s){function l(){var e=[].slice.call(arguments);r&&t.removeListener(r,c),i.apply(void 0,a([],o(e)))}function c(){var e=[].slice.call(arguments);t.removeListener(n,l),s.apply(void 0,a([],o(e)))}t.once(n,l),r&&t.once(r,c),e()}))},n.getOrNull=function(e,t){return t.split(".").reduce((function(e,t){return e?e[t]:null}),e)},n.defer=function(){var e={};return e.promise=new Promise((function(t,n){e.resolve=t,e.reject=n})),e},n.delegateMethods=function(e,t,n){for(var r in e)h(e,t,n,r)},n.proxyProperties=function(e,t,n){Object.getOwnPropertyNames(e).forEach((function(e){!function(e,t,n,r){if(r in t)return;if(r.match(/^on[a-z]+$/))return Object.defineProperty(t,r,{value:null,writable:!0}),void n.addEventListener(r.slice(2),(function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];t.dispatchEvent.apply(t,a([],o(e)))}));Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[r]}})}(0,t,n,e)}))},n.legacyPromise=function(e,t,n){return t?e.then((function(e){t(e)}),(function(e){n(e)})):e},n.buildLogLevels=function(e){return"string"==typeof e?{default:e,media:e,signaling:e,webrtc:e}:e},n.trackClass=function(e,t){return(t=t?"Local":"")+(e.kind||"").replace(/\w{1}/,(function(e){return e.toUpperCase()}))+"Track"},n.trackPublicationClass=function(e,t){return(t=t?"Local":"")+(e.kind||"").replace(/\w{1}/,(function(e){return e.toUpperCase()}))+"TrackPublication"},n.valueToJSON=w,n.withJitter=function(e,t){var n=Math.random();return e-t+Math.floor(2*t*n+.5)},n.isChromeScreenShareTrack=function(e){return"chrome"===u.guessBrowser()&&"video"===e.kind&&"displaySurface"in e.getSettings()},n.isUserMediaTrack=function(e){return"string"==typeof e.getSettings().deviceId},n.waitForSometime=function(e){return void 0===e&&(e=10),new Promise((function(t){return setTimeout(t,e)}))},n.waitForEvent=function(e,t){return new Promise((function(n){e.addEventListener(t,(function r(i){e.removeEventListener(t,r),n(i)}))}))}},{"../webrtc/util":510,"./constants":465,"./sid":484,"./twiliowarning":489}],473:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=e("events").EventEmitter,s=e("..").getUserAgent,l=globalThis,c=l.WebSocket?l.WebSocket:e("ws"),u=e("../constants"),p=u.hardwareDevicePublisheriPad,f=u.hardwareDevicePublisheriPhone,d=e("../../util"),h=e("../browserdetection"),m=function(e){function t(t,n,r,i,o,a){var l=e.call(this)||this;return a=Object.assign({gateway:b(i,o)+"/v1/VideoEvents",maxReconnectAttempts:5,reconnectIntervalMs:50,userAgent:s(),WebSocket:c},a),Object.defineProperties(l,{_connectTimestamp:{value:0,writable:!0},_eventQueue:{value:[]},_readyToConnect:{value:d.defer()},_reconnectAttemptsLeft:{value:a.maxReconnectAttempts,writable:!0},_ws:{value:null,writable:!0},_WebSocket:{value:a.WebSocket}}),l._readyToConnect.promise.then((function(e){var i=e.roomSid,o=e.participantSid,s=l;l.on("disconnected",(function e(l){if(s._session=null,l&&s._reconnectAttemptsLeft>0)return s.emit("reconnecting"),void function(e,t,n,r,i,o,a){var s=Date.now()-e._connectTimestamp,l=a.reconnectIntervalMs-s;if(l>0)return void setTimeout((function(){y(e,t,n,r,i,o,a)}),l);y(e,t,n,r,i,o,a)}(s,t,n,r,i,o,a);s.removeListener("disconnected",e)})),y(l,t,n,r,i,o,a)})).catch((function(){})),l}return i(t,e),t.prototype.connect=function(e,t){this._readyToConnect.resolve({roomSid:e,participantSid:t})},t.prototype._publish=function(e){e.session=this._session,this._ws.send(JSON.stringify(e))},t.prototype.disconnect=function(){if(null===this._ws||this._ws.readyState===this._WebSocket.CLOSING||this._ws.readyState===this._WebSocket.CLOSED)return!1;try{this._ws.close()}catch(e){}
164return this.emit("disconnected"),!0},t.prototype.publish=function(e,t,n){return(null===this._ws||this._ws.readyState!==this._WebSocket.CLOSING&&this._ws.readyState!==this._WebSocket.CLOSED)&&(("string"==typeof this._session?this._publish.bind(this):this._eventQueue.push.bind(this._eventQueue))({group:e,name:t,payload:n,timestamp:Date.now(),type:"event",version:1}),!0)},t}(a);function y(e,t,n,r,i,a,s){e._connectTimestamp=Date.now(),e._reconnectAttemptsLeft--,e._ws=new s.WebSocket(s.gateway);var l=e._ws;l.addEventListener("close",(function(t){1e3!==t.code?e.emit("disconnected",new Error("WebSocket Error "+t.code+": "+t.reason)):e.emit("disconnected")})),l.addEventListener("message",(function(t){!function(e,t,n){switch(t.type){case"connected":e._session=t.session,e._reconnectAttemptsLeft=n.maxReconnectAttempts,e._eventQueue.splice(0).forEach(e._publish,e),e.emit("connected");break;case"error":e._ws.close(),e.emit("disconnected",new Error(t.message))}}(e,JSON.parse(t.data),s)})),l.addEventListener("open",(function(){var e={type:"connect",token:t,version:1};e.publisher={name:n,sdkVersion:r,userAgent:s.userAgent,participantSid:a,roomSid:i},h.isIpad()?e.publisher=o(o({},e.publisher),p):h.isIphone()&&(e.publisher=o(o({},e.publisher),f)),l.send(JSON.stringify(e))}))}function b(e,t){return"prod"===e?"wss://sdkgw."+t+".twilio.com":"wss://sdkgw."+e+"-"+t+".twilio.com"}t.exports=m},{"..":472,"../../util":472,"../browserdetection":463,"../constants":465,events:222,ws:514}],474:[function(e,t,n){"use strict";var r=function(){function e(){Object.defineProperties(this,{_connected:{writable:!0,value:!0}})}return e.prototype.connect=function(){},e.prototype.disconnect=function(){return!!this._connected&&(this._connected=!1,!0)},e.prototype.publish=function(){return this._connected},e}();t.exports=r},{}],475:[function(e,t,n){"use strict";var r=e("./").defer,i=function(){function e(){Object.defineProperties(this,{_audio:{value:r(),writable:!0},_video:{value:r(),writable:!0}}),this._audio.resolve(),this._video.resolve()}return e.prototype.resolveDeferred=function(e){"audio"===e?this._audio.resolve():this._video.resolve()},e.prototype.startDeferred=function(e){"audio"===e?this._audio=r():this._video=r()},e.prototype.whenResolved=function(e){return"audio"===e?this._audio.promise:this._video.promise},e}();t.exports=new i},{"./":472}],476:[function(e,t,n){"use strict";var r,i=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},a=e("../vendor/loglevel").getLogger,s=e("./constants"),l=s.DEFAULT_LOG_LEVEL,c=s.DEFAULT_LOGGER_NAME,u=e("./constants").typeErrors;var p=function(){function e(t,n,r,i,o){if("string"!=typeof t)throw u.INVALID_TYPE("moduleName","string");if(!n)throw u.REQUIRED_ARGUMENT("component");"object"!=typeof r&&(r={}),o=o||a,y(r),Object.defineProperties(this,{_component:{value:n},_logLevels:{value:r},_warnings:{value:new Set},_loggerName:{get:function(){var e=i&&"string"==typeof i?i:c;return this._logLevelsEqual||(e=e+"-"+t),e}},_logger:{get:function(){var e=o(this._loggerName),n=this._logLevels[t]||l;return n="off"===n?"silent":n,e.setDefaultLevel(n),e}},_logLevelsEqual:{get:function(){return 1===new Set(Object.values(this._logLevels)).size}},logLevel:{get:function(){return e.getLevelByName(r[t]||l)}},name:{get:n.toString.bind(n)}})}return e.getLevelByName=function(t){return isNaN(t)?(m(t=t.toUpperCase()),e[t]):parseInt(t,10)},e.prototype.createLog=function(t,n){var r=this._loggerName;return this._logLevelsEqual||(r=r.substring(0,r.lastIndexOf("-"))),new e(t,n,this._logLevels,r)},e.prototype.setLevels=function(e){return y(e),Object.assign(this._logLevels,e),this},e.prototype.log=function(t,n){var r=e._levels[t];if(!r)throw u.INVALID_VALUE("logLevel",d);r=r.toLowerCase();var a=[(new Date).toISOString(),r,this.name];return(this._logger[r]||function(){}).apply(void 0,o([],i(a.concat(n)))),this},e.prototype.debug=function(){return this.log(e.DEBUG,[].slice.call(arguments))},e.prototype.deprecated=function(e){var t=function(e){if((r=r||new Map).has(e))return r.get(e);var t=new Set;return r.set(e,t),t}(this._component.constructor);return t.has(e)?this:(t.add(e),this.warn(e))},e.prototype.info=function(){return this.log(e.INFO,[].slice.call(arguments))},e.prototype.warn=function(){return this.log(e.WARN,[].slice.call(arguments))},e.prototype.warnOnce=function(e){return this._warnings.has(e)?this:(this._warnings.add(e),this.warn(e))},e.prototype.error=function(){return this.log(e.ERROR,[].slice.call(arguments))},e.prototype.throw=function(t,n){throw t.clone&&(t=t.clone(n)),this.log(e.ERROR,t),t},e}();Object.defineProperties(p,{DEBUG:{value:0},INFO:{value:1},WARN:{value:2},ERROR:{value:3},OFF:{value:4},_levels:{value:["DEBUG","INFO","WARN","ERROR","OFF"]}});var f={},d=[],h=p._levels.map((function(e,t){return f[e]=!0,d.push(t),e}));function m(e){if(!(e in f))throw u.INVALID_VALUE("level",h)}function y(e){Object.keys(e).forEach((function(t){m(e[t].toUpperCase())}))}t.exports=p},{"../vendor/loglevel":492,"./constants":465}],477:[function(e,t,n){"use strict";var r=function(){function e(){Object.defineProperties(this,{_samples:{value:[{denominator:0,numerator:0},{denominator:0,numerator:0}]}})}return e.prototype.get=function(){var e=this._samples,t=e[1].denominator-e[0].denominator||1/0;return(e[1].numerator-e[0].numerator)/t},e.prototype.putSample=function(e,t){var n=this._samples;n.shift(),n.push({denominator:t,numerator:e})},e}();t.exports=r},{}],478:[function(e,t,n){"use strict";var r=function(){function e(e,t){var n=this,r=(t=Object.assign({navigator:navigator,window:window},t)).navigator,i=r.connection||{type:null},o=i.type,a=i.type?{_events:{value:["change","typechange"]},_listener:{value:function(){var t=o!==n.type&&n.isOnline;o=n.type,t&&e()}},_target:{value:i}}:{_events:{value:["online"]},_listener:{value:e},_target:{value:t.window}},s=a._events,l=a._listener,c=a._target;Object.defineProperties(this,{isOnline:{enumerable:!0,get:function(){return"boolean"!=typeof r.onLine||r.onLine}},type:{enumerable:!0,get:function(){return i.type||null}},_listener:l,_events:s,_target:c})}return e.prototype.start=function(){var e=this;
164this._events.forEach((function(t){e._target.addEventListener(t,e._listener)}))},e.prototype.stop=function(){var e=this;this._events.forEach((function(t){e._target.removeEventListener(t,e._listener)}))},e}();t.exports=r},{}],479:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(){function e(e){Object.defineProperties(this,{_callback:{value:e}})}return e.prototype.observe=function(){},e.prototype.unobserve=function(){},e.prototype.makeVisible=function(e){var t=this._makeFakeEntry(e,!0);this._callback([t])},e.prototype.makeInvisible=function(e){var t=this._makeFakeEntry(e,!1);this._callback([t])},e.prototype._makeFakeEntry=function(e,t){return{target:e,isIntersecting:t}},e}(),a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t}(o),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.resize=function(e){var t=this._makeFakeEntry(e,!0);this._callback([t])},t}(o);t.exports={NullIntersectionObserver:a,NullResizeObserver:s,NullObserver:o}},{}],480:[function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},i=e("../"),o=i.difference,a=i.flatMap,s=e("./simulcast"),l={0:"PCMU",8:"PCMA"};function c(e){return Array.from(p(e)).reduce((function(e,t){var n=t[0],r=t[1],i=e.get(r)||[];return e.set(r,i.concat(n))}),new Map)}function u(e){return h(e).reduce((function(e,t){var n=d(t);return n?e.set(n,t):e}),new Map)}function p(e){return m(e).reduce((function(t,n){var r=new RegExp("a=rtpmap:"+n+" ([^/]+)"),i=e.match(r),o=i?i[1].toLowerCase():l[n]?l[n].toLowerCase():"";return t.set(n,o)}),new Map)}function f(e,t){var n=new RegExp("^a=fmtp:"+e+" (.+)$","m"),i=t.match(n);return i&&i[1].split(";").reduce((function(e,t){var n=r(t.split("="),2),i=n[0],o=n[1];return e[i]=isNaN(o)?o:parseInt(o,10),e}),{})}function d(e){var t=e.match(/^a=mid:(.+)$/m);return t&&t[1]}function h(e,t,n){return e.replace(/\r\n\r\n$/,"\r\n").split("\r\nm=").slice(1).map((function(e){return"m="+e})).filter((function(e){var r=new RegExp("m="+(t||".*"),"gm"),i=new RegExp("a="+(n||".*"),"gm");return r.test(e)&&i.test(e)}))}function m(e){var t=e.split("\r\n")[0].match(/([0-9]+)/g);return t?t.slice(1).map((function(e){return parseInt(e,10)})):[]}function y(e,t){var n=t.split("\r\n"),r=n[0],i=n.slice(1);return[r=r.replace(/([0-9]+\s?)+$/,e.join(" "))].concat(i).join("\r\n")}function b(e,t,n){if(!/^m=(audio|video)/.test(e))return e;var i=d(e),o=i&&t.get(i);if(!o)return e;var s=p(o),l=c(e),u=a(Array.from(s),(function(t){var i=r(t,2),a=i[0],s=i[1];return"rtx"===s||n.includes(s)?[]:function(e,t,n,r,i){var o=n.get(e)||[];if(o.length<=1)return o;var a=f(t,i);if(!a)return o;var s=o.find((function(e){var t=f(e,r);return t&&Object.keys(a).every((function(e){return a[e]===t[e]}))}));return"number"==typeof s?[s]:o}(s,a,l,e,o)})),h=l.get("rtx")||[];u=u.concat(h.filter((function(t){var n=f(t,e);return n&&u.includes(n.apt)})));var b=e.split("\r\n").filter((function(e){var t=e.match(/^a=(rtpmap|fmtp|rtcp-fb):(.+) .+$/),n=t&&t[2];return!t||n&&u.includes(parseInt(n,10))}));return y(m(e).filter((function(e){return u.includes(e)})),b.join("\r\n"))}function v(e,t){var n=h(e);return[e.split("\r\nm=")[0]].concat(n.map((function(e){if(!/^m=(audio|video)/.test(e))return e;var n=d(e);if(!n)return e;var i=t.get(n);if(!i)return e;var o=(e.match(/^a=msid:(.+)$/m)||[])[1];if(!o)return e;var a=r(o.split(" "),2),s=a[0],l=a[1],c=new RegExp("msid:"+s+(l?" "+l:"")+"$","gm");return e.replace(c,"msid:"+s+" "+i)}))).join("\r\n")}function g(e,t){return"a=fmtp:"+e+" "+Object.entries(t).map((function(e){var t=r(e,2);return t[0]+"="+t[1]})).join(";")}n.addOrRewriteNewTrackIds=function(e,t,n){var i=Array.from(n).reduce((function(n,i){var o=r(i,2),a=o[0],s=o[1];return h(e,a,"send(only|recv)").map(d).filter((function(e){return!t.has(e)}
164)).forEach((function(e,t){return n.set(e,s[t])})),n}),new Map);return v(e,i)},n.addOrRewriteTrackIds=v,n.createCodecMapForMediaSection=c,n.createPtToCodecName=p,n.disableRtx=function(e){var t=h(e);return[e.split("\r\nm=")[0]].concat(t.map((function(e){if(!/^m=video/.test(e))return e;var t=c(e).get("rtx");if(!t)return e;var n=new Set(m(e));t.forEach((function(e){return n.delete(e)}));var r=e.match(/a=ssrc-group:FID [0-9]+ ([0-9]+)/),i=r&&r[1],o=[/^a=fmtp:.+ apt=.+$/,/^a=rtpmap:.+ rtx\/.+$/,/^a=ssrc-group:.+$/].concat(i?[new RegExp("^a=ssrc:"+i+" .+$")]:[]);return e=e.split("\r\n").filter((function(e){return o.every((function(t){return!t.test(e)}))})).join("\r\n"),y(Array.from(n),e)}))).join("\r\n")},n.enableDtxForOpus=function(e,t){var n=h(e),r=e.split("\r\nm=")[0];return t=t||n.filter((function(e){return/^m=audio/.test(e)})).map(d),[r].concat(n.map((function(e){if(!/^m=audio/.test(e))return e;var n=c(e).get("opus");if(!n)return e;var r=f(n,e);if(!r)return e;var i=g(n,r),o=new RegExp(i),a=d(e);t.includes(a)?r.usedtx=1:delete r.usedtx;var s=g(n,r);return e.replace(o,s)}))).join("\r\n")},n.filterLocalCodecs=function(e,t){var n=h(e),r=e.split("\r\nm=")[0],i=u(t);return[r].concat(n.map((function(e){return b(e,i,[])}))).join("\r\n")},n.getMediaSections=h,n.removeSSRCAttributes=function(e,t){return e.split("\r\n").filter((function(e){return!t.find((function(t){return new RegExp("a=ssrc:.*"+t+":","g").test(e)}))})).join("\r\n")},n.revertSimulcast=function(e,t,n,r){void 0===r&&(r=!1);var i=u(n),o=u(t),a=h(e);return[e.split("\r\nm=")[0]].concat(a.map((function(e){if(e=e.replace(/\r\n$/,""),!/^m=video/.test(e))return e;var t=e.match(/^a=mid:(.+)$/m),n=t&&t[1];if(!n)return e;var a=i.get(n),s=p(a),l=m(a),c=l.length&&"vp8"===s.get(l[0]);return r||!c?o.get(n).replace(/\r\n$/,""):e}))).concat("").join("\r\n")},n.setCodecPreferences=function(e,t,n){var r=h(e);return[e.split("\r\nm=")[0]].concat(r.map((function(e){if(!/^m=(audio|video)/.test(e))return e;var r=e.match(/^m=(audio|video)/)[1],i=c(e),s=function(e,t){t=t.map((function(e){return e.codec.toLowerCase()}));var n=a(t,(function(t){return e.get(t)||[]})),r=o(Array.from(e.keys()),t),i=a(r,(function(t){return e.get(t)}));return n.concat(i)}(i,"audio"===r?t:n),l=y(s,e),u=i.get("pcma")||[],p=i.get("pcmu")||[];return("audio"===r?new Set(u.concat(p)):new Set).has(s[0])?l.replace(/\r\nb=(AS|TIAS):([0-9]+)/g,""):l}))).join("\r\n")},n.setSimulcast=function(e,t){var n=h(e);return[e.split("\r\nm=")[0]].concat(n.map((function(e){if(e=e.replace(/\r\n$/,""),!/^m=video/.test(e))return e;var n=c(e),r=m(e),i=new Set(n.get("vp8")||[]);return r.some((function(e){return i.has(e)}))?s(e,t):e}))).concat("").join("\r\n")}},{"../":472,"./simulcast":482}],481:[function(e,t,n){"use strict";var r=e("../../webrtc").RTCSessionDescription,i=e("./"),o=i.createPtToCodecName,a=i.getMediaSections;function s(e){var t=o(e);e=function(e,t){return Array.from(t.keys()).reduce((function(e,n){var r=new RegExp("^a=rtpmap:"+n+" rtx.+$","gm");return(e.match(r)||[]).slice("rtx"===t.get(n)?1:0).reduce((function(e,t){var r=new RegExp("\r\n"+t),i=new RegExp("\r\na=fmtp:"+n+" apt=[0-9]+");return e.replace(r,"").replace(i,"")}),e)}),e)}(e,t);var n=function(e){var t=new Map;return e.forEach((function(e,n){var r=t.get(e)||new Set;return t.set(e,r.add(n))})),t}(t),r=n.get("rtx")||new Set,i=new Set,a=function(e,t){var n=Array.from(e).reduce((function(e,t){var n=t[0],r=t[1],i=e.get(r)||new Set;return e.set(r,i.add(n))}),new Map);return Array.from(n).reduce((function(e,n){var r=n[0],i=Array.from(n[1]);return i.length>1?(i.forEach((function(e){t.add(e)})),e):e.set(r,i[0])}),new Map)}(function(e,t,n,r){return Array.from(n).reduce((function(n,i){var o=new RegExp("a=fmtp:"+i+" apt=(\\d+)"),a=e.match(o);if(!a)return r.add(i),n;var s=Number.parseInt(a[1]);return t.has(s)?"rtx"===t.get(s)?(r.add(i),n):n.set(i,s):(r.add(i),n)}),new Map)}(e,t,r,i),i),s=Array.from(i);return["h264","vp8","vp9"].reduce((function(e,t){var r=n.get(t)||new Set;return Array.from(r).reduce((function(e,t){return a.has(t)?e:e.add(t)}),e)}),new Set).forEach((function(t){if(s.length){var n=s.shift();e=function(e,t,n){return e.endsWith("\r\n")?e+"a=fmtp:"+t+" apt="+n+"\r\n":e+"\r\na=fmtp:"+t+" apt="+n}(e=l(e,n),n,t)}}
164)),s.forEach((function(t){e=function(e,t){var n=new RegExp("a=rtpmap:"+t+".*\r\n","gm");return e.replace(n,"")}(e=l(e,t),t)})),e}function l(e,t){var n=new RegExp("a=fmtp:"+t+".*\r\n","gm");return e.replace(n,"")}t.exports=function(e){var t,n,i={type:e.type};return"rollback"!==e.type&&(i.sdp=(t=e.sdp,n=a(t),[t.split("\r\nm=")[0]].concat(n.map(s)).join("\r\n"))),new r(i)}},{"../../webrtc":498,"./":480}],482:[function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},i=e("../"),o=i.difference,a=i.flatMap;function s(){return String(Math.floor(4294967295*Math.random()))}var l=function(){function e(e,t,n){Object.defineProperties(this,{cName:{enumerable:!0,value:n},isSimulcastEnabled:{enumerable:!0,value:!1,writable:!0},primarySSRCs:{enumerable:!0,value:new Set},rtxPairs:{enumerable:!0,value:new Map},streamId:{enumerable:!0,value:t},trackId:{enumerable:!0,value:e}})}return e.prototype.addSimulcastSSRCs=function(){if(!this.isSimulcastEnabled){var e=[s(),s()];e.forEach((function(e){this.primarySSRCs.add(e)}),this),this.rtxPairs.size&&e.forEach((function(e){this.rtxPairs.set(s(),e)}),this)}},e.prototype.addSSRC=function(e,t,n){t?this.rtxPairs.set(e,t):this.primarySSRCs.add(e),this.isSimulcastEnabled=this.isSimulcastEnabled||n},e.prototype.toSdpLines=function(e){var t=this,n=e?[]:Array.from(this.rtxPairs.entries()).map((function(e){return e.reverse()})),r=Array.from(this.primarySSRCs.values()),i=n.length?a(n):r,o=a(i,(function(e){return["a=ssrc:"+e+" cname:"+t.cName,"a=ssrc:"+e+" msid:"+t.streamId+" "+t.trackId]})),s=n.map((function(e){return"a=ssrc-group:FID "+e.join(" ")})),l=["a=ssrc-group:SIM "+r.join(" ")];return s.concat(o).concat(l)},e}();function c(e,t){return(e.match(new RegExp(t,"gm"))||[]).map((function(e){return(e.match(new RegExp(t))||[]).slice(1)}))}function u(e){var t=function(e){return new Set(a(c(e,"^a=ssrc-group:SIM ([0-9]+) ([0-9]+) ([0-9]+)$")))}(e),n=function(e){return new Map(c(e,"^a=ssrc-group:FID ([0-9]+) ([0-9]+)$").map((function(e){return e.reverse()})))}(e);return function(e){var t=r(a(c(e,"^a=msid:(.+) (.+)$")),2),n=t[0],i=t[1];return a(c(e,"^a=ssrc:(.+) cname:.+$")).map((function(e){return[e,n,i]}))}(e).reduce((function(r,i){var o=i[0],a=i[1],s=i[2],c=r.get(s)||new l(s,a,function(e,t,n){var r="a=ssrc:"+t+" "+n+":(.+)";return e.match(new RegExp(r))[1]}(e,o,"cname")),u=n.get(o)||null;return c.addSSRC(o,u,t.has(o)),r.set(s,c)}),new Map)}t.exports=function(e,t){var n=u(e),r=Array.from(n.keys()),i=Array.from(t.keys()),s=o(r,i),l=o(i,r);a(s,(function(e){return n.get(e)})).forEach((function(e){e.addSimulcastSSRCs(),t.set(e.trackId,e)})),i=Array.from(t.keys());var c=o(i,l),p=a(c,(function(e){return t.get(e)})),f=!e.match(/a=rtpmap:[0-9]+ rtx/),d=a(p,(function(e){return e.toSdpLines(f)})),h=a(new Set(e.split("\r\n").concat(d)));return e.match("a=x-google-flag:conference")||h.push("a=x-google-flag:conference"),h.join("\r\n")}},{"../":472}],483:[function(e,t,n){"use strict";var r=e("./").getMediaSections,i=function(){function e(){Object.defineProperties(this,{_midsToTrackIds:{value:new Map,writable:!0}})}return e.prototype.match=function(e){return this._midsToTrackIds.get(e.transceiver.mid)||null},e.prototype.update=function(e){var t=r(e,"(audio|video)");this._midsToTrackIds=t.reduce((function(e,t){var n=t.match(/^a=mid:(.+)$/m)||[],r=t.match(/^a=msid:.+ (.+)$/m)||[],i=n[1],o=r[1];return i&&o?e.set(i,o):e}),this._midsToTrackIds)},e}();t.exports=i},{"./":480}],484:[function(e,t,n){function r(e){for(var t="",n=0;n<32;n++)t+="1234567890abcdef".charAt(Math.floor(Math.random()*"1234567890abcdef".length));return""+e+t}n.sessionSID=r("SS"),n.createSID=r},{}],485:[function(e,t,n){"use strict";var r=e("../webrtc/util"),i=r.guessBrowser,o=r.support,a=e("../webrtc/util/sdp").getSdpFormat,s=e("./browserdetection"),l=s.isAndroid,c=s.isMobile,u=s.isNonChromiumEdge,p=s.rebrandedChromeBrowser,f=s.mobileWebKitBrowser,d=["crios","edg","edge","electron","headlesschrome"],h=["chrome","firefox"],m=["chrome","safari"],y=[];t.exports=function(){var e=i();if(!e)return!1;var t=p(e),n=f(e),r=l()?h:m;return!!e&&o()&&"unified"===a()&&(!t||d.includes(t))&&!u(e)&&(!n||y.includes(n))&&(!c()||r.includes(e))}},{"../webrtc/util":510,"../webrtc/util/sdp":512,"./browserdetection":463}],486:[function(e,t,n){"use strict";var r=function(){function e(e,t,n){void 0===n&&(n=!0),Object.defineProperties(this,{_delay:{value:t,writable:!0},_fn:{value:e},_timeout:{value:null,writable:!0}}),n&&this.start()}return Object.defineProperty(e.prototype,"delay",{get:function(){return this._delay}
164,enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSet",{get:function(){return!!this._timeout},enumerable:!1,configurable:!0}),e.prototype.setDelay=function(e){this._delay=e},e.prototype.start=function(){var e=this;this.isSet||(this._timeout=setTimeout((function(){var t=e._fn;e.clear(),t()}),this._delay))},e.prototype.clear=function(){clearTimeout(this._timeout),this._timeout=null},e.prototype.reset=function(){this.clear(),this.start()},e}();t.exports=r},{}],487:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./twilioerror"),a={};n.createTwilioError=function(e,t){return t="string"==typeof t&&t?t:"Unknown error",a[e="number"==typeof e?e:0]?new a[e]:new o(e,t)};var s=function(e){function t(){var n=e.call(this,20101,"Invalid Access Token")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.AccessTokenInvalidError=s,Object.defineProperty(a,20101,{value:s});var l=function(e){function t(){var n=e.call(this,20102,"Invalid Access Token header")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.AccessTokenHeaderInvalidError=l,Object.defineProperty(a,20102,{value:l});var c=function(e){function t(){var n=e.call(this,20103,"Invalid Access Token issuer/subject")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.AccessTokenIssuerInvalidError=c,Object.defineProperty(a,20103,{value:c});var u=function(e){function t(){var n=e.call(this,20104,"Access Token expired or expiration date invalid")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.AccessTokenExpiredError=u,Object.defineProperty(a,20104,{value:u});var p=function(e){function t(){var n=e.call(this,20105,"Access Token not yet valid")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.AccessTokenNotYetValidError=p,Object.defineProperty(a,20105,{value:p});var f=function(e){function t(){var n=e.call(this,20106,"Invalid Access Token grants")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.AccessTokenGrantsInvalidError=f,Object.defineProperty(a,20106,{value:f});var d=function(e){function t(){var n=e.call(this,20107,"Invalid Access Token signature")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.AccessTokenSignatureInvalidError=d,Object.defineProperty(a,20107,{value:d});var h=function(e){function t(){var n=e.call(this,53e3,"Signaling connection error")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.SignalingConnectionError=h,Object.defineProperty(a,53e3,{value:h});var m=function(e){function t(){var n=e.call(this,53001,"Signaling connection disconnected")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.SignalingConnectionDisconnectedError=m,Object.defineProperty(a,53001,{value:m});var y=function(e){function t(){var n=e.call(this,53002,"Signaling connection timed out")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.SignalingConnectionTimeoutError=y,Object.defineProperty(a,53002,{value:y});var b=function(e){function t(){var n=e.call(this,53003,"Client received an invalid signaling message")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.SignalingIncomingMessageInvalidError=b,Object.defineProperty(a,53003,{value:b});var v=function(e){function t(){var n=e.call(this,53004,"Client sent an invalid signaling message")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.SignalingOutgoingMessageInvalidError=v,Object.defineProperty(a,53004,{value:v});var g=function(e){function t(){var n=e.call(this,53006,"Video server is busy")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.SignalingServerBusyError=g,Object.defineProperty(a,53006,{value:g});var w=function(e){function t(){var n=e.call(this,53100,"Room name is invali
164d")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomNameInvalidError=w,Object.defineProperty(a,53100,{value:w});var C=function(e){function t(){var n=e.call(this,53101,"Room name is too long")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomNameTooLongError=C,Object.defineProperty(a,53101,{value:C});var _=function(e){function t(){var n=e.call(this,53102,"Room name contains invalid characters")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomNameCharsInvalidError=_,Object.defineProperty(a,53102,{value:_});var k=function(e){function t(){var n=e.call(this,53103,"Unable to create Room")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomCreateFailedError=k,Object.defineProperty(a,53103,{value:k});var S=function(e){function t(){var n=e.call(this,53104,"Unable to connect to Room")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomConnectFailedError=S,Object.defineProperty(a,53104,{value:S});var E=function(e){function t(){var n=e.call(this,53105,"Room contains too many Participants")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomMaxParticipantsExceededError=E,Object.defineProperty(a,53105,{value:E});var T=function(e){function t(){var n=e.call(this,53106,"Room not found")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomNotFoundError=T,Object.defineProperty(a,53106,{value:T});var O=function(e){function t(){var n=e.call(this,53107,"MaxParticipants is out of range")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomMaxParticipantsOutOfRangeError=O,Object.defineProperty(a,53107,{value:O});var P=function(e){function t(){var n=e.call(this,53108,"RoomType is not valid")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomTypeInvalidError=P,Object.defineProperty(a,53108,{value:P});var R=function(e){function t(){var n=e.call(this,53109,"Timeout is out of range")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomTimeoutOutOfRangeError=R,Object.defineProperty(a,53109,{value:R});var x=function(e){function t(){var n=e.call(this,53110,"StatusCallbackMethod is invalid")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomStatusCallbackMethodInvalidError=x,Object.defineProperty(a,53110,{value:x});var D=function(e){function t(){var n=e.call(this,53111,"StatusCallback is invalid")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomStatusCallbackInvalidError=D,Object.defineProperty(a,53111,{value:D});var j=function(e){function t(){var n=e.call(this,53112,"Status is invali
164d")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomStatusInvalidError=j,Object.defineProperty(a,53112,{value:j});var M=function(e){function t(){var n=e.call(this,53113,"Room exists")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomRoomExistsError=M,Object.defineProperty(a,53113,{value:M});var A=function(e){function t(){var n=e.call(this,53114,"Room creation parameter(s) incompatible with the Room type")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomInvalidParametersError=A,Object.defineProperty(a,53114,{value:A});var I=function(e){function t(){var n=e.call(this,53115,"MediaRegion is invalid")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomMediaRegionInvalidError=I,Object.defineProperty(a,53115,{value:I});var N=function(e){function t(){var n=e.call(this,53116,"There are no media servers available in the MediaRegion")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomMediaRegionUnavailableError=N,Object.defineProperty(a,53116,{value:N});var L=function(e){function t(){var n=e.call(this,53117,"The subscription operation requested is not supported for the Room type")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomSubscriptionOperationNotSupportedError=L,Object.defineProperty(a,53117,{value:L});var F=function(e){function t(){var n=e.call(this,53118,"Room completed")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomCompletedError=F,Object.defineProperty(a,53118,{value:F});var U=function(e){function t(){var n=e.call(this,53124,"The AudioOnly flag is not supported for the Room type")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomAudioOnlyFlagNotSupportedError=U,Object.defineProperty(a,53124,{value:U});var q=function(e){function t(){var n=e.call(this,53125,"The track kind is not supported by the Room")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.RoomTrackKindNotSupportedError=q,Object.defineProperty(a,53125,{value:q});var B=function(e){function t(){var n=e.call(this,53200,"Participant identity is invali
164d")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.ParticipantIdentityInvalidError=B,Object.defineProperty(a,53200,{value:B});var z=function(e){function t(){var n=e.call(this,53201,"Participant identity is too long")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.ParticipantIdentityTooLongError=z,Object.defineProperty(a,53201,{value:z});var V=function(e){function t(){var n=e.call(this,53202,"Participant identity contains invalid characters")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.ParticipantIdentityCharsInvalidError=V,Object.defineProperty(a,53202,{value:V});var W=function(e){function t(){var n=e.call(this,53203,"The maximum number of published tracks allowed in the Room at the same time has been reached")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.ParticipantMaxTracksExceededError=W,Object.defineProperty(a,53203,{value:W});var H=function(e){function t(){var n=e.call(this,53204,"Participant not found")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.ParticipantNotFoundError=H,Object.defineProperty(a,53204,{value:H});var Y=function(e){function t(){var n=e.call(this,53205,"Participant disconnected because of duplicate identity")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.ParticipantDuplicateIdentityError=Y,Object.defineProperty(a,53205,{value:Y});var X=function(e){function t(){var n=e.call(this,53300,"Track is invalid")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.TrackInvalidError=X,Object.defineProperty(a,53300,{value:X});var G=function(e){function t(){var n=e.call(this,53301,"Track name is invalid")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.TrackNameInvalidError=G,Object.defineProperty(a,53301,{value:G});var $=function(e){function t(){var n=e.call(this,53302,"Track name is too long")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.TrackNameTooLongError=$,Object.defineProperty(a,53302,{value:$});var Q=function(e){function t(){var n=e.call(this,53303,"Track name contains invalid characters")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.TrackNameCharsInvalidError=Q,Object.defineProperty(a,53303,{value:Q});var K=function(e){function t(){var n=e.call(this,53304,"Track name is duplicated")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.TrackNameIsDuplicatedError=K,Object.defineProperty(a,53304,{value:K});var J=function(e){function t(){var n=e.call(this,53305,"The server has reached capacity and cannot fulfill this request")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.TrackServerTrackCapacityReachedError=J,Object.defineProperty(a,53305,{value:J});var Z=function(e){function t(){var n=e.call(this,53400,"Client is unable to create or apply a local media description")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.MediaClientLocalDescFailedError=Z,Object.defineProperty(a,53400,{value:Z});var ee=function(e){function t(){var n=e.call(this,53401,"Server is unable to create or apply a local media description")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.MediaServerLocalDescFailedError=ee,Object.defineProperty(a,53401,{value:ee});var te=function(e){function t(){var n=e.call(this,53402,"Client is unable to apply a remote media description")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.MediaClientRemoteDescFailedError=te,Object.defineProperty(a,53402,{value:te});var ne=function(e){function t(){var n=e.call(this,53403,"Server is unable to apply a remote media description")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.MediaServerRemoteDescFailedError=ne,Object.defineProperty(a,53403,{value:ne});var re=function(e){function t(){var n=e.call(this,53404,"No supported codec")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.MediaNoSupportedCodecError=re,Object.defineProperty(a,53404,{value:re});var ie=function(e){function t(){var n=e.call(this,53405,"Media connection failed or Media activity ceased")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.MediaConnectionError=ie,Object.defineProperty(a,53405,{value:ie});var oe=function(e){function t(){var n=e.call(this,53407,"Media connection failed due to DTLS handshake failure")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.MediaDTLSTransportFailedError=oe,Object.defineProperty(a,53407,{value:oe});var ae=function(e){function t(){var n=e.call(this,53500,"Unable to acquire configuration")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.ConfigurationAcquireFailedError=ae,Object.defineProperty(a,53500,{value:ae});var se=function(e){function t(){var n=e.call(this,53501,"Unable to acquire TURN credentials")||this;return Object.setPrototypeOf(n,t.prototype),n}return i(t,e),t}(o);n.ConfigurationAcquireTurnFailedError=se,Object.defineProperty(a,53501,{value:se})},{"./twilioerror":488}],488:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=function(e){function t(n){var r=this,i=[].slice.call(arguments,1
164);r=e.apply(this,a([],o(i)))||this,Object.setPrototypeOf(r,t.prototype);var s=Error.apply(r,i);return s.name="TwilioError",Object.defineProperty(r,"code",{value:n,enumerable:!0}),Object.getOwnPropertyNames(s).forEach((function(e){Object.defineProperty(this,e,{value:s[e],enumerable:!0})}),r),r}return i(t,e),t.prototype.toString=function(){var e=this.message?": "+this.message:"";return this.name+" "+this.code+e},t}(Error);t.exports=s},{}],489:[function(e,t,n){"use strict";t.exports={recordingMediaLost:"recording-media-lost"}},{}],490:[function(e,t,n){"use strict";var r=e("./").isNonArrayObject,i=e("./constants"),o=i.typeErrors,a=i.clientTrackSwitchOffControl,s=i.videoContentPreferencesMode,l=i.subscriptionMode,c=i.trackPriority,u=i.trackSwitchOffMode;function p(e,t,n){return void 0===n&&(n=[]),void 0===e?null:null!==e&&r(e)?n.reduce((function(n,r){var i=r.prop,a=r.type,s=r.values;if(n||!(i in e))return n;var l=e[i];return a&&typeof l!==a||"number"===a&&isNaN(l)?o.INVALID_TYPE(t+"."+i,a):Array.isArray(s)&&!s.includes(l)?o.INVALID_VALUE(t+"."+i,s):n}),null):o.INVALID_TYPE(t,"object")}n.validateBandwidthProfile=function(e){var t=p(e,"options.bandwidthProfile");return!e||t?t:(t=p(e.video,"options.bandwidthProfile.video",[{prop:"contentPreferencesMode",values:Object.values(s)},{prop:"dominantSpeakerPriority",values:Object.values(c)},{prop:"maxSubscriptionBitrate",type:"number"},{prop:"maxTracks",type:"number"},{prop:"mode",values:Object.values(l)},{prop:"clientTrackSwitchOffControl",values:Object.values(a)},{prop:"trackSwitchOffMode",values:Object.values(u)}]))||(e.video?"maxTracks"in e.video&&"clientTrackSwitchOffControl"in e.video?new TypeError("options.bandwidthProfile.video.maxTracks is deprecated. Use options.bandwidthProfile.video.clientTrackSwitchOffControl instead."):"renderDimensions"in e.video&&"contentPreferencesMode"in e.video?new TypeError("options.bandwidthProfile.video.renderDimensions is deprecated. Use options.bandwidthProfile.video.contentPreferencesMode instead."):function(e){var t="options.bandwidthProfile.video.renderDimensions",n=p(e,t);return e?n||Object.values(c).reduce((function(n,r){return n||p(e[r],t+"."+r,[{prop:"height",type:"number"},{prop:"width",type:"number"}])}),null):n}(e.video.renderDimensions):null)},n.validateLocalTrack=function(e,t){if(!(e instanceof t.LocalAudioTrack||e instanceof t.LocalDataTrack||e instanceof t.LocalVideoTrack||e instanceof t.MediaStreamTrack))throw o.INVALID_TYPE("track","LocalAudioTrack, LocalVideoTrack, LocalDataTrack, or MediaStreamTrack")},n.validateObject=p},{"./":472,"./constants":465}],491:[function(e,t,n){t.exports=function(e,t){if(e&&t)if(e.super_=t,"function"==typeof Object.create)e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}});else{var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}}},{}],492:[function(e,t,n){var r=function(){},i="undefined"!=typeof window&&void 0!==window.navigator&&/Trident\/|MSIE /.test(window.navigator.userAgent),o=["trace","debug","info","warn","error"];function a(e,t){var n=e[t];if("function"==typeof n.bind)return n.bind(e);try{return Function.prototype.bind.call(n,e)}catch(t){return function(){return Function.prototype.apply.apply(n,[e,arguments])}}}function s(){console.log&&(console.log.apply?console.log.apply(console,arguments):Function.prototype.apply.apply(console.log,[console,arguments])),console.trace&&console.trace()}function l(e){return"debug"===e&&(e="log"),"undefined"!=typeof console&&("trace"===e&&i?s:void 0!==console[e]?a(console,e):void 0!==console.log?a(console,"log"):r)}function c(e,t){for(var n=0;n<o.length;n++){var i=o[n];this[i]=n<e?r:this.methodFactory(i,e,t)}this.log=this.debug}function u(e,t,n){return function(){"undefined"!=typeof console&&(c.call(this,t,n),this[e].apply(this,arguments))}}function p(e,t,n){return l(e)||u.apply(this,arguments)}function f(e,t,n){var r,i=this,a="loglevel";function s(){var e;if("undefined"!=typeof window&&a){try{e=window.localStorage[a]}catch(e){}if(void 0===e)try{var t=window.document.cookie,n=t.indexOf(encodeURIComponent(a)+"=");-1!==n&&(e=/^([^;]+)/.exec(t.slice(n))[1])}catch(e){}return void 0===i.levels[e]&&(e=void 0),e}}"string"==typeof e?a+=":"+e:"symbol"==typeof e&&(a=void 0),i.name=e,i.levels={TRACE:0,DEBUG:1,INFO:2,WARN:3,ERROR:4,SILENT:5},i.methodFactory=n||p,i.getLevel=function(){return r},i.setLevel=function(t,n){if("string"==typeof t&&void 0!==i.levels[t.toUpperCase()]&&(t=i.levels[t.toUpperCase()]),!("number"==typeof t&&t>
164=0&&t<=i.levels.SILENT))throw"log.setLevel() called with invalid level: "+t;if(r=t,!1!==n&&function(e){var t=(o[e]||"silent").toUpperCase();if("undefined"!=typeof window&&a){try{return void(window.localStorage[a]=t)}catch(e){}try{window.document.cookie=encodeURIComponent(a)+"="+t+";"}catch(e){}}}(t),c.call(i,t,e),"undefined"==typeof console&&t<i.levels.SILENT)return"No console available for logging"},i.setDefaultLevel=function(e){s()||i.setLevel(e,!1)},i.enableAll=function(e){i.setLevel(i.levels.TRACE,e)},i.disableAll=function(e){i.setLevel(i.levels.SILENT,e)};var l=s();null==l&&(l=null==t?"WARN":t),i.setLevel(l,!1)}var d=new f,h={};d.getLogger=function(e){if("symbol"!=typeof e&&"string"!=typeof e||""===e)throw new TypeError("You must supply a name when creating a logger.");var t=h[e];return t||(t=h[e]=new f(e,d.getLevel(),d.methodFactory)),t};var m="undefined"!=typeof window?window.log:void 0;d.noConflict=function(){return"undefined"!=typeof window&&window.log===d&&(window.log=m),d},d.getLoggers=function(){return h},d.default=d,t.exports=d},{}],493:[function(e,t,n){"use strict";var r="undefined"!=typeof AudioContext?AudioContext:"undefined"!=typeof webkitAudioContext?webkitAudioContext:null,i=function(){function e(t){t=Object.assign({AudioContext:r},t),Object.defineProperties(this,{_AudioContext:{value:t.AudioContext},_audioContext:{value:null,writable:!0},_holders:{value:new Set},AudioContextFactory:{enumerable:!0,value:e}})}return e.prototype.getOrCreate=function(e){if(!this._holders.has(e)&&(this._holders.add(e),this._AudioContext&&!this._audioContext))try{this._audioContext=new this._AudioContext}catch(e){}return this._audioContext},e.prototype.release=function(e){this._holders.has(e)&&(this._holders.delete(e),!this._holders.size&&this._audioContext&&(this._audioContext.close(),this._audioContext=null))},e}();t.exports=new i},{}],494:[function(e,t,n){"use strict";t.exports=function(e,t,n){n="number"==typeof n?n:250;var r=e.createMediaStreamSource(t),i=e.createAnalyser();i.fftSize=2048,r.connect(i);var o=new Uint8Array(i.fftSize),a=!1;return setTimeout((function(){a=!0}),n),function e(){return a?Promise.resolve(!0):(i.getByteTimeDomainData(o),o.some((function(e){return 128!==e&&0!==e}))?Promise.resolve(!1):function(e){return e="number"==typeof e?e:0,new Promise((function(t){return setTimeout(t,e)}))}().then(e))}().then((function(e){return r.disconnect(),e}),(function(e){throw r.disconnect(),e}))}},{}],495:[function(e,t,n){"use strict";var r=e("./detectsilence");t.exports=function(t,n,i,o,a){o="number"==typeof o?o:3;var s=0,l=e("./audiocontext"),c={},u=l.getOrCreate(c);return function e(){return n(i).then((function(n){return(i.audio?r(u,n,a).catch((function(e){return t.warn("Encountered an error while detecting silence",e),!0})):Promise.resolve(!1)).then((function(r){return r?o<=0?(t.warn("Got a silent audio MediaStreamTrack. Normally we would try to get a new one, but we've run out of retries; returning it anyway."),n):(t.warn("Got a silent audio MediaStreamTrack. Stopping all MediaStreamTracks and calling getUserMedia again. This is retry #"+ ++s+"."),n.getTracks().forEach((function(e){return e.stop()})),o--,e()):(t.info("Got a non-silent audio MediaStreamTrack; returning it."),n)}))}))}().then((function(e){return l.release(c),e}),(function(e){throw l.release(c),e}))}},{"./audiocontext":493,"./detectsilence":494}],496:[function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},i=e("./util"),o=i.flatMap,a=i.guessBrowser,s=i.guessBrowserVersion,l=e("./util/sdp").getSdpFormat,c=a(),u=s(),p="chrome"===c,f="firefox"===c,d="safari"===c,h=p?u.major:null;function m(e){var t=Array.from(e.values()).find((function(e){var t=e.nominated;return"candidate-pair"===e.type&&t}));if(!t)return null;var n=e.get(t.localCandidateId),r=e.get(t.remoteCandidateId),i=[{key:"candidateType",type:"string"},{key:"ip",type:"string"},{key:"port",type:"number"},{key:"priority",type:"number"},{key:"protocol",type:"string"},{key:"url",type:"string"}],o=i.concat([{key:"deleted",type:"boolean"},{key:"relayProtocol",type:"string"}]),a=n?o.reduce((function(e,t){var r=t.key,i=t.type;return e[r]=typeof n[r]===i?n[r]:"deleted"!==r&&null,e}),{}):null,s=r?i.reduce((function(e,t){var n=t.key,i=t.type;return e[n]=typeof r[n]===i?r[n]:null,e}),{}):null;return[{key:"availableIncomingBitrate",type:"number"},{key:"availableOutgoingBitrate",type:"number"},{key:"bytesReceived",type:"number"},{key:"bytesSent",type:"number"},{key:"consentRequestsSent",type:"number"},{key:"currentRoundTripTime",type:"number"},{key:"lastPacketReceivedTimestamp",type:"number"},{key:"lastPacketSentTimestamp",type:"number"},{key:"nominated",type:"boolean"},{key:"priority",type:"number"},{key:"readable",type:"boolean"},{key:"requestsReceived",type:"number"},{key:"requestsSent",type:"number"},{key:"responsesReceived",type:"number"},{key:"responsesSent",type:"number"},{key:"retransmissionsReceived",type:"number"},{key:"retransmissionsSent",type:"number"},{key:"state",type:"string",fixup:function(e){return"inprogress"===e?"in-
164progress":e}},{key:"totalRoundTripTime",type:"number"},{key:"transportId",type:"string"},{key:"writable",type:"boolean"}].reduce((function(e,n){var r=n.key,i=n.type,o=n.fixup;return e[r]=typeof t[r]===i?o?o(t[r]):t[r]:null,e}),{localCandidate:a,remoteCandidate:s})}function y(e){var t=Array.from(e.values()).find((function(e){var t=e.nominated;return"candidate-pair"===e.type&&t}));if(!t)return null;var n=e.get(t.localCandidateId),r=e.get(t.remoteCandidateId),i=[{key:"candidateType",type:"string"},{key:"ip",ffKeys:["address","ipAddress"],type:"string"},{key:"port",ffKeys:["portNumber"],type:"number"},{key:"priority",type:"number"},{key:"protocol",ffKeys:["transport"],type:"string"},{key:"url",type:"string"}],o=i.concat([{key:"deleted",type:"boolean"},{key:"relayProtocol",type:"string"}]),a={host:"host",peerreflexive:"prflx",relayed:"relay",serverreflexive:"srflx"},s=n?o.reduce((function(e,t){var r=t.ffKeys,i=t.key,o=t.type,s=r&&r.find((function(e){return e in n}))||i;return e[i]=typeof n[s]===o?"candidateType"===s&&a[n[s]]||n[s]:"deleted"!==s&&null,e}),{}):null,l=r?i.reduce((function(e,t){var n=t.ffKeys,i=t.key,o=t.type,s=n&&n.find((function(e){return e in r}))||i;return e[i]=typeof r[s]===o?"candidateType"===s&&a[r[s]]||r[s]:null,e}),{}):null;return[{key:"availableIncomingBitrate",type:"number"},{key:"availableOutgoingBitrate",type:"number"},{key:"bytesReceived",type:"number"},{key:"bytesSent",type:"number"},{key:"consentRequestsSent",type:"number"},{key:"currentRoundTripTime",type:"number"},{key:"lastPacketReceivedTimestamp",type:"number"},{key:"lastPacketSentTimestamp",type:"number"},{key:"nominated",type:"boolean"},{key:"priority",type:"number"},{key:"readable",type:"boolean"},{key:"requestsReceived",type:"number"},{key:"requestsSent",type:"number"},{key:"responsesReceived",type:"number"},{key:"responsesSent",type:"number"},{key:"retransmissionsReceived",type:"number"},{key:"retransmissionsSent",type:"number"},{key:"state",type:"string"},{key:"totalRoundTripTime",type:"number"},{key:"transportId",type:"string"},{key:"writable",type:"boolean"}].reduce((function(e,n){var r=n.key,i=n.type;return e[r]=typeof t[r]===i?t[r]:null,e}),{localCandidate:s,remoteCandidate:l})}function b(e,t,n){var r="local"===n?"getSenders":"getReceivers";if(e[r])return e[r]().map((function(e){return e.track})).filter((function(e){return e&&e.kind===t}));var i="audio"===t?"getAudioTracks":"getVideoTracks";return o(e["local"===n?"getLocalStreams":"getRemoteStreams"](),(function(e){return e[i]()}))}function v(e,t,n){return h&&h<67?new Promise((function(n,r){e.getStats((function(e){n([g(e,t)])}),null,r)})):e.getStats(t).then((function(e){return function(e,t){var n=t.simulateExceptionWhileStandardizingStats;if(void 0!==n&&n)throw new Error("Error while gathering stats");var r=null,i=[],o=null,a=null,s=null,l=null,c=null;
164e.forEach((function(e){switch(e.type){case"inbound-rtp":r=e;break;case"outbound-rtp":i.push(e);break;case"media-source":c=e;break;case"track":s=e;break;case"codec":l=e;break;case"remote-inbound-rtp":o=e;break;case"remote-outbound-rtp":a=e}}));var u=s?s.remoteSource:!c,p=[],f=u?a:o;return(u?[r]:i).forEach((function(e){var t={},n=[e,c,s,l,f&&f.ssrc===e.ssrc?f:null];function r(e){var t=n.find((function(t){return t&&void 0!==t[e]}))||null;return t?t[e]:null}var i=r("ssrc");"number"==typeof i&&(t.ssrc=String(i));var o=r("timestamp");t.timestamp=Math.round(o);var a=r("mimeType");"string"==typeof a&&(a=a.split("/"),t.codecName=a[a.length-1]);var d=r("roundTripTime");"number"==typeof d&&(t.roundTripTime=Math.round(1e3*d));var h=r("jitter");"number"==typeof h&&(t.jitter=Math.round(1e3*h));var m=r("frameWidth");"number"==typeof m&&(u?t.frameWidthReceived=m:(t.frameWidthSent=m,t.frameWidthInput=s?s.frameWidth:c.width));var y=r("frameHeight");"number"==typeof y&&(u?t.frameHeightReceived=y:(t.frameHeightSent=y,t.frameHeightInput=s?s.frameHeight:c.height));var b=r("framesPerSecond");"number"==typeof b&&(t[u?"frameRateReceived":"frameRateSent"]=b);var v=r("bytesReceived");"number"==typeof v&&(t.bytesReceived=v);var g=r("bytesSent");"number"==typeof g&&(t.bytesSent=g);var w=r("packetsLost");"number"==typeof w&&(t.packetsLost=w);var C=r("packetsReceived");"number"==typeof C&&(t.packetsReceived=C);var _=r("packetsSent");"number"==typeof _&&(t.packetsSent=_);var k=r("audioLevel");"number"==typeof k&&(k=Math.round(32767*k),u?t.audioOutputLevel=k:t.audioInputLevel=k);var S=r("totalPacketSendDelay");"number"==typeof S&&(t.totalPacketSendDelay=S);var E=r("totalEncodeTime");"number"==typeof E&&(t.totalEncodeTime=E);var T=r("framesEncoded");"number"==typeof T&&(t.framesEncoded=T);var O=r("estimatedPlayoutTimestamp");"number"==typeof O&&(t.estimatedPlayoutTimestamp=O);var P=r("totalDecodeTime");"number"==typeof P&&(t.totalDecodeTime=P);var R=r("framesDecoded");"number"==typeof R&&(t.framesDecoded=R);var x=r("jitterBufferDelay");"number"==typeof x&&(t.jitterBufferDelay=x);var D=r("jitterBufferEmittedCount");"number"==typeof D&&(t.jitterBufferEmittedCount=D),p.push(t)})),p}(e,n)}))}function g(e,t){var n=e.result().find((function(e){return"ssrc"===e.type&&e.stat("googTrackId")===t.id})),r={};return n&&(r.timestamp=Math.round(Number(n.timestamp)),r=n.names().reduce((function(e,t){switch(t){case"googCodecName":e.codecName=n.stat(t);break;case"googRtt":e.roundTripTime=Number(n.stat(t));break;case"googJitterReceived":e.jitter=Number(n.stat(t));break;case"googFrameWidthInput":e.frameWidthInput=Number(n.stat(t));break;case"googFrameHeightInput":e.frameHeightInput=Number(n.stat(t));break;case"googFrameWidthSent":e.frameWidthSent=Number(n.stat(t));break;case"googFrameHeightSent":e.frameHeightSent=Number(n.stat(t));break;case"googFrameWidthReceived":e.frameWidthReceived=Number(n.stat(t));break;case"googFrameHeightReceived":e.frameHeightReceived=Number(n.stat(t));break;case"googFrameRateInput":e.frameRateInput=Number(n.stat(t));break;case"googFrameRateSent":e.frameRateSent=Number(n.stat(t));break;case"googFrameRateReceived":e.frameRateReceived=Number(n.stat(t));break;case"ssrc":e[t]=n.stat(t);break;case"bytesReceived":case"bytesSent":case"packetsLost":case"packetsReceived":case"packetsSent":case"audioInputLevel":case"audioOutputLevel":e[t]=Number(n.stat(t))}return e}),r)),r}function w(e,t){void 0===e&&(e=new Map);var n=t.isRemote,r=t.simulateExceptionWhileStandardizingStats;if(void 0!==r&&r)throw new Error("Error while gathering stats");var i=null,o=null;e.forEach((function(t){var n=t.isRemote,r=t.remoteId,a=t.type;if(!n)switch(a){case"inbound-rtp":i=t,o=e.get(r);break;case"outbound-rtp":o=t,i=e.get(r)}}));var a=n?i:o,s=n?o:i;function l(e){return a&&void 0!==a[e]?a[e]:s&&void 0!==s[e]?s[e]:null}var c={},u=l("timestamp");c.timestamp=Math.round(u);var p=l("ssrc");"number"==typeof p&&(c.ssrc=String(p));var f=l("bytesSent");"number"==typeof f&&(c.bytesSent=f);var d=l("packetsLost");"number"==typeof d&&(c.packetsLost=d);var h=l("packetsSent");"number"==typeof h&&(c.packetsSent=h);var m=l("roundTripTime");"number"==typeof m&&(c.roundTripTime=Math.round(1e3*m));var y=l("jitter");"number"==typeof y&&(c.jitter=Math.round(1e3*y));var b=l("framerateMean");"number"==typeof b&&(c.frameRateSent=Math.round(b));var v=l("bytesReceived");"number"==typeof v&&(c.bytesReceived=v);var g=l("packetsReceived");"number"==typeof g&&(c.packetsReceived=g);var w=l("framerateMean");"number"==typeof w&&(c.frameRateReceived=Math.round(w));var C=l("totalPacketSendDelay");"number"==typeof C&&(c.totalPacketSendDelay=C);var _=l("totalEncodeTime");"number"==typeof _&&(c.totalEncodeTime=_);var k=l("framesEncoded");"number"==typeof k&&(c.framesEncoded=k);var S=l("estimatedPlayoutTimestamp");"number"==typeof S&&(c.estimatedPlayoutTimestamp=S);var E=l("totalDecodeTime");"number"==typeof E&&(c.totalDecodeTime=E);var T=l("framesDecoded");"number"==typeof T&&(c.framesDecoded=T);var O=l("jitterBufferDelay");"number"==typeof O&&(c.jitterBufferDelay=O);var P=l("jitterBufferEmittedCount");return"number"==typeof P&&(c.jitterBufferEmittedCount=P),c}t.exports=function(e,t){return e&&"function"==typeof e.getStats?function(e,t){var n=b(e,"audio","local"),i=b(e,"video","local"),a=b(e,"audio"),s=b(e,"video"),c={activeIceCandidatePair:null,localAudioTrackStats:[],localVideoTrackStats:[],remoteAudioTrackStats:[],remoteVideoTrackStats:[]},u=o([[n,"localAudioTrackStats",!1],[i,"localVideoTrackStats",!1],[a,"remoteAudioTrackStats",!0],[s,"remoteVideoTrackStats",!0]],(function(n){var i=r(n,3),o=i[0],a=i[1],s=i[2];return o.map((function(n){return function(e,t,n){void 0===n&&(n={});if(void 0!==n.testForChrome||p)return v(e,t,n);if(void 0!==n.testForFirefox||f)return function(e,t,n){return e.getStats(t).then((function(e){return[w(e,n)]}))}
164(e,t,n);if(void 0!==n.testForSafari||d)return void 0!==n.testForSafari||"unified"===l()?v(e,t,n):Promise.reject(new Error(["getStats() is not supported on this version of Safari","due to this bug: https://bugs.webkit.org/show_bug.cgi?id=192601"].join(" ")));return Promise.reject(new Error("RTCPeerConnection#getStats() not supported"))}(e,n,Object.assign({isRemote:s},t)).then((function(e){e.forEach((function(e){e.trackId=n.id,c[a].push(e)}))}))}))}));return Promise.all(u).then((function(){return function(e,t){void 0===t&&(t={});if(void 0!==t.testForChrome||p||void 0!==t.testForSafari||d)return e.getStats().then(m);if(void 0!==t.testForFirefox||f)return e.getStats().then(y);return Promise.reject(new Error("RTCPeerConnection#getStats() not supported"))}(e,t)})).then((function(e){return c.activeIceCandidatePair=e,c}))}(e,t):Promise.reject(new Error("Given PeerConnection does not support getStats"))}},{"./util":510,"./util/sdp":512}],497:[function(e,t,n){"use strict";t.exports=function(e){return void 0===e&&(e={audio:!0,video:!0}),"object"==typeof navigator&&"object"==typeof navigator.mediaDevices&&"function"==typeof navigator.mediaDevices.getUserMedia?navigator.mediaDevices.getUserMedia(e):Promise.reject(new Error("getUserMedia is not supported"))}},{}],498:[function(e,t,n){"use strict";var r={};Object.defineProperties(r,{getStats:{enumerable:!0,value:e("./getstats")},getUserMedia:{enumerable:!0,value:e("./getusermedia")},MediaStream:{enumerable:!0,value:e("./mediastream")},MediaStreamTrack:{enumerable:!0,value:e("./mediastreamtrack")},RTCIceCandidate:{enumerable:!0,value:e("./rtcicecandidate")},RTCPeerConnection:{enumerable:!0,value:e("./rtcpeerconnection")},RTCSessionDescription:{enumerable:!0,value:e("./rtcsessiondescription")}}),t.exports=r},{"./getstats":496,"./getusermedia":497,"./mediastream":499,"./mediastreamtrack":500,"./rtcicecandidate":501,"./rtcpeerconnection":504,"./rtcsessiondescription":509}],499:[function(e,t,n){"use strict";"function"==typeof MediaStream?t.exports=MediaStream:t.exports=function(){throw new Error("MediaStream is not supported")}},{}],500:[function(e,t,n){"use strict";"function"==typeof MediaStreamTrack?t.exports=MediaStreamTrack:t.exports=function(){throw new Error("MediaStreamTrack is not supported")}},{}],501:[function(e,t,n){"use strict";"function"==typeof RTCIceCandidate?t.exports=RTCIceCandidate:t.exports=function(){throw new Error("RTCIceCandidate is not supported")}},{}],502:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("../rtcsessiondescription/chrome"),l=e("../../eventtarget"),c=e("../util/latch"),u=e("../mediastream"),p=e("../rtcrtpsender"),f=e("../util/sdp"),d=f.getSdpFormat,h=f.updatePlanBTrackIdsToSSRCs,m=f.updateUnifiedPlanTrackIdsToSSRCs,y=e("../util"),b=y.delegateMethods,v=y.interceptEvent,g=y.isIOSChrome,w=y.legacyPromise,C=y.proxyProperties,_="unified"===d(),k=function(e){function t(t,n){void 0===t&&(t={});var r=e.call(this)||this,i=Object.assign(t.iceTransportPolicy?{iceTransports:t.iceTransportPolicy}:{},t);v(r,"datachannel"),v(r,"signalingstatechange");var s=d(i.sdpSemantics),l=new RTCPeerConnection(i,n);return Object.defineProperties(r,{_appliedTracksToSSRCs:{value:new Map,writable:!0},_localStream:{value:new u},_peerConnection:{value:l}
164,_pendingLocalOffer:{value:null,writable:!0},_pendingRemoteOffer:{value:null,writable:!0},_rolledBackTracksToSSRCs:{value:new Map,writable:!0},_sdpFormat:{value:s},_senders:{value:new Map},_signalingStateLatch:{value:new c},_tracksToSSRCs:{value:new Map,writable:!0}}),l.addEventListener("datachannel",(function(e){P(e.channel),r.dispatchEvent(e)})),l.addEventListener("signalingstatechange",(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];"stable"===l.signalingState&&(r._appliedTracksToSSRCs=new Map(r._tracksToSSRCs)),r._pendingLocalOffer||r._pendingRemoteOffer||r.dispatchEvent.apply(r,a([],o(e)))})),l.ontrack=function(){},"function"!=typeof l.addTrack&&l.addStream(r._localStream),C(RTCPeerConnection.prototype,r,l),r}return i(t,e),Object.defineProperty(t.prototype,"localDescription",{get:function(){return this._pendingLocalOffer?this._pendingLocalOffer:this._peerConnection.localDescription},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"remoteDescription",{get:function(){return this._pendingRemoteOffer?this._pendingRemoteOffer:this._peerConnection.remoteDescription},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"signalingState",{get:function(){return this._pendingLocalOffer?"have-local-offer":this._pendingRemoteOffer?"have-remote-offer":this._peerConnection.signalingState},enumerable:!1,configurable:!0}),t.prototype.addTrack=function(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];if("function"==typeof this._peerConnection.addTrack)return(t=this._peerConnection).addTrack.apply(t,a([e],o(n)));if("closed"===this._peerConnection.signalingState)throw new Error("Cannot add MediaStreamTrack ["+e.id+", \n        "+e.kind+"]: RTCPeerConnection is closed");var i=this._senders.get(e);if(i&&i.track)throw new Error("Cannot add MediaStreamTrack ['"+e.id+", \n        "+e.kind+"]: RTCPeerConnection already has it");return this._peerConnection.removeStream(this._localStream),this._localStream.addTrack(e),this._peerConnection.addStream(this._localStream),i=new p(e),this._senders.set(e,i),i},t.prototype.removeTrack=function(e){if("closed"===this._peerConnection.signalingState)throw new Error("Cannot remove MediaStreamTrack: RTCPeerConnection is closed");if("function"==typeof this._peerConnection.addTrack)try{return this._peerConnection.removeTrack(e)}catch(e){}else{var t=e.track;if(!t)return;(e=this._senders.get(t))&&e.track&&(e.track=null,this._peerConnection.removeStream(this._localStream),this._localStream.removeTrack(t),this._peerConnection.addStream(this._localStream))}},t.prototype.getSenders=function(){return"function"==typeof this._peerConnection.addTrack?this._peerConnection.getSenders():Array.from(this._senders.values())},t.prototype.addIceCandidate=function(e){for(var t,n=this,r=[],i=1;i<arguments.length;i++)r[i-1]=arguments[i];return t="have-remote-offer"===this.signalingState?this._signalingStateLatch.when("low").then((function(){return n._peerConnection.addIceCandidate(e)})):this._peerConnection.addIceCandidate(e),r.length>0?w.apply(void 0,a([t],o(r))):t},t.prototype.close=function(){"closed"!==this.signalingState&&(this._pendingLocalOffer=null,this._pendingRemoteOffer=null,this._peerConnection.close())},t.prototype.createAnswer=function(){for(var e,t=this,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return e=this._pendingRemoteOffer?this._peerConnection.setRemoteDescription(this._pendingRemoteOffer).then((function(){return t._signalingStateLatch.lower(),t._peerConnection.createAnswer()})).then((function(e){return t._pendingRemoteOffer=null,t._rolledBackTracksToSSRCs.clear(),new s({type:"answer",sdp:R(t._sdpFormat,t._tracksToSSRCs,e.sdp)})}),(function(e){throw t._pendingRemoteOffer=null,e})):this._peerConnection.createAnswer().then((function(e){return t._rolledBackTracksToSSRCs.clear(),new s({type:"answer",sdp:R(t._sdpFormat,t._tracksToSSRCs,e.sdp)})})),n.length>1?w.apply(void 0,a([e],o(n))):e},t.prototype.createOffer=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=o(t,3),i=r[0],a=r[1],l=r[2],c=l||i||{};if(g()){if(c.offerToReceiveVideo&&!this._audioTransceiver&&(!_||!E(this,"audio"))){delete c.offerToReceiveAudio;try{this._audioTransceiver=_?this.addTransceiver("audio",{direction:"recvonly"}):this.addTransceiver("audio")}catch(e){return Promise.reject(e)}}if(c.offerToReceiveVideo&&!this._videoTransceiver&&(!_||!E(this,"video"))){delete c.offerToReceiveVideo;try{this._videoTransceiver=_?this.addTransceiver("video",{direction:"recvonly"}):this.addTransceiver("video")}catch(e){return Promise.reject(e)}}}var u=this._peerConnection.createOffer(c).then((function(t){return e._rolledBackTracksToSSRCs.clear(),new s({type:t.type,sdp:R(e._sdpFormat,e._tracksToSSRCs,t.sdp)})}));return t.length>1?w(u,i,a):u},t.prototype.createDataChannel=function(e,t){t=function(e){e=Object.assign({},e),O()&&"maxPacketLifeTime"in e&&(e.maxRetransmitTime=e.maxPacketLifeTime);return e}(t);
164var n=this._peerConnection.createDataChannel(e,t);return P(n),n},t.prototype.setLocalDescription=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=o(e,3),r=n[0],i=n[1],a=n[2];this._rolledBackTracksToSSRCs.size>0&&(this._tracksToSSRCs=new Map(this._rolledBackTracksToSSRCs),this._rolledBackTracksToSSRCs.clear());var s=S(this,!0,r);return e.length>1?w(s,i,a):s},t.prototype.setRemoteDescription=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=o(e,3),r=n[0],i=n[1],a=n[2];this._rolledBackTracksToSSRCs.clear();var s=S(this,!1,r);return e.length>1?w(s,i,a):s},t}(l);function S(e,t,n){var r,i,o=t?e._pendingLocalOffer:e._pendingRemoteOffer,a=t?e._pendingRemoteOffer:e._pendingLocalOffer,s=t?"have-local-offer":"have-remote-offer",l=t?"setLocalDescription":"setRemoteDescription";if(!t&&a&&"answer"===n.type)r=function(e,t){var n=e._pendingLocalOffer;return e._peerConnection.setLocalDescription(n).then((function(){return e._pendingLocalOffer=null,e.setRemoteDescription(t)})).then((function(){e._signalingStateLatch.lower()}))}(e,n);else if("offer"===n.type){if(e.signalingState!==s&&"stable"!==e.signalingState)return Promise.reject(new Error("Cannot set "+(t?"local":"remote")+" offer in state "+e.signalingState));o||"low"!==e._signalingStateLatch.state||e._signalingStateLatch.raise();var c=e.signalingState;i=T(n),t?e._pendingLocalOffer=i:e._pendingRemoteOffer=i,r=Promise.resolve(),e.signalingState!==c&&r.then((function(){return e.dispatchEvent(new Event("signalingstatechange"))}))}else"rollback"===n.type&&(e.signalingState!==s?r=Promise.reject(new Error("Cannot rollback "+(t?"local":"remote")+" description in "+e.signalingState)):(t?e._pendingLocalOffer=null:e._pendingRemoteOffer=null,e._rolledBackTracksToSSRCs=new Map(e._tracksToSSRCs),e._tracksToSSRCs=new Map(e._appliedTracksToSSRCs),(r=Promise.resolve()).then((function(){return e.dispatchEvent(new Event("signalingstatechange"))}))));return r||e._peerConnection[l](T(n))}function E(e,t){return!!e.getTransceivers().find((function(e){var n=e.receiver,r=(void 0===n?{}:n).track;return(void 0===r?{}:r).kind===t}))}function T(e){return e instanceof s&&e._description?e._description:new RTCSessionDescription(e)}function O(){return"maxRetransmitTime"in RTCDataChannel.prototype&&!("maxPacketLifeTime"in RTCDataChannel.prototype)}function P(e){return Object.defineProperty(e,"maxRetransmits",{value:65535===e.maxRetransmits?null:e.maxRetransmits}),O()&&Object.defineProperty(e,"maxPacketLifeTime",{value:65535===e.maxRetransmitTime?null:e.maxRetransmitTime}),e}function R(e,t,n){return"unified"===e?m(t,n):h(t,n)}b(RTCPeerConnection.prototype,k.prototype,"_peerConnection"),t.exports=k},{"../../eventtarget":351,"../mediastream":499,"../rtcrtpsender":506,"../rtcsessiondescription/chrome":507,"../util":510,"../util/latch":511,"../util/sdp":512}],503:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("../../eventtarget"),l=e("../rtcsessiondescription/firefox"),c=e("../util/sdp").updateUnifiedPlanTrackIdsToSSRCs,u=e("../util"),p=u.delegateMethods,f=u.interceptEvent,d=u.legacyPromise,h=u.proxyProperties,m=function(e){function t(t){var n=e.call(this)||this;f(n,"signalingstatechange");var r,i=new RTCPeerConnection(t);return Object.defineProperties(n,{_initiallyNegotiatedDtlsRole:{value:null,writable:!0},_isClosed:{value:!1,writable:!0},_peerConnection:{value:i},_rollingBack:{value:!1,writable:!0},_tracksToSSRCs:{value:new Map},peerIdentity:{enumerable:!0,value:Promise.resolve({idp:"",name:""})}}),i.addEventListener("signalingstatechange",(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];n._rollingBack||n.signalingState===r||(r=n.signalingState,n._isClosed?setTimeout((function(){return n.dispatchEvent.apply(n,a([],o(e)))})):n.dispatchEvent.apply(n,a([],o(e))))})),h(RTCPeerConnection.prototype,n,i),n}return i(t,e),Object.defineProperty(t.prototype,"iceGatheringState",{get:function(){return this._isClosed?"complete":this._peerConnection.iceGatheringState}
164,enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"localDescription",{get:function(){return v(this._peerConnection.localDescription,this._initiallyNegotiatedDtlsRole)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"signalingState",{get:function(){return this._isClosed?"closed":this._peerConnection.signalingState},enumerable:!1,configurable:!0}),t.prototype.createAnswer=function(){for(var e,t=this,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return e=this._peerConnection.createAnswer().then((function(e){return b(t,e),v(e,t._initiallyNegotiatedDtlsRole)})),"function"==typeof n[0]?d.apply(void 0,a([e],o(n))):e},t.prototype.createOffer=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r,i=o(t,3),a=i[0],s=i[1],u=i[2],p=u||a||{};if("have-local-offer"===this.signalingState||"have-remote-offer"===this.signalingState){var f="have-local-offer"===this.signalingState;r=y(this,f,(function(){return e.createOffer(p)}))}else r=this._peerConnection.createOffer(p);return r=r.then((function(t){return new l({type:t.type,sdp:c(e._tracksToSSRCs,t.sdp)})})),t.length>1?d(r,a,s):r},t.prototype.setLocalDescription=function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r,i=o(t),s=i[0],l=i.slice(1);return s&&"answer"===s.type&&"have-local-offer"===this.signalingState&&(r=Promise.reject(new Error("Cannot set local answer in state have-local-offer"))),r?t.length>1?d.apply(void 0,a([r],o(l))):r:(e=this._peerConnection).setLocalDescription.apply(e,a([],o(t)))},t.prototype.setRemoteDescription=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r,i=o(t),s=i[0],l=i.slice(1);return s&&"have-remote-offer"===this.signalingState&&("answer"===s.type?r=Promise.reject(new Error("Cannot set remote answer in state have-remote-offer")):"offer"===s.type&&(r=y(this,!1,(function(){return e._peerConnection.setRemoteDescription(s)})))),r||(r=this._peerConnection.setRemoteDescription(s)),r=r.then((function(){return b(e,s,!0)})),t.length>1?d.apply(void 0,a([r],o(l))):r},t.prototype.close=function(){"closed"!==this.signalingState&&(this._isClosed=!0,this._peerConnection.close())},t}(s);function y(e,t,n){var r=t?"setLocalDescription":"setRemoteDescription";return e._rollingBack=!0,e._peerConnection[r](new l({type:"rollback"})).then(n).then((function(t){return e._rollingBack=!1,t}),(function(t){throw e._rollingBack=!1,t}))}function b(e,t,n){if(!e._initiallyNegotiatedDtlsRole&&"offer"!==t.type){var r=t.sdp.match(/a=setup:([a-z]+)/);if(r){var i=r[1];e._initiallyNegotiatedDtlsRole=n?{active:"passive",passive:"active"}[i]:i}}}function v(e,t){return e&&"answer"===e.type&&t?new l({type:e.type,sdp:e.sdp.replace(/a=setup:[a-z]+/g,"a=setup:"+t)}):e}p(RTCPeerConnection.prototype,m.prototype,"_peerConnection"),t.exports=m},{"../../eventtarget":351,"../rtcsessiondescription/firefox":508,"../util":510,"../util/sdp":512}],504:[function(e,t,n){"use strict";if("function"==typeof RTCPeerConnection)switch((0,e("../util").guessBrowser)()){case"chrome":t.exports=e("./chrome");break;case"firefox":t.exports=e("./firefox");break;case"safari":t.exports=e("./safari");break;default:t.exports=RTCPeerConnection}else t.exports=function(){throw new Error("RTCPeerConnection is not supported")}},{"../util":510,"./chrome":502,"./firefox":503,"./safari":505}],505:[function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e},s=e("../../eventtarget"),l=e("../util/latch"),c=e("../util/sdp"),u=c.getSdpFormat,p=c.updatePlanBTrackIdsToSSRCs,f=c.updateUnifiedPlanTrackIdsToSSRCs,d=e("../util"),h=d.delegateMethods,m=d.interceptEvent,y=d.proxyProperties,b="unified"===u(),v=b?f:p,g=function(e){function t(t){var n=e.call(this)||this;m(n,"datachannel"),m(n,"iceconnectionstatechange"),m(n,"signalingstatechange"),m(n,"track");var r=new RTCPeerConnection(t);return Object.defineProperties(n,{_appliedTracksToSSRCs:{value:new Map,writable:!0},_audioTransceiver:{value:null,writable:!0},_isClosed:{value:!1,writable:!0},_peerConnection:{value:r},_pendingLocalOffer:{value:null,writable:!0},_pendingRemoteOffer:{value:null,writable:!0},_rolledBackTracksToSSRCs:{value:new Map,writable:!0},_signalingStateLatch:{value:new l},_tracksToSSRCs:{value:new Map,writable:!0},_videoTransceiver:{value:null,writable:!0}}),r.addEventListener("datachannel",(function(e){_(e.channel),n.dispatchEvent(e)})),r.addEventListener("iceconnectionstatechange",(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];n._isClosed||n.dispatchEvent.apply(n,a([],o(e)))})),r.addEventListener("signalingstatechange",(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];n._isClosed||("stable"===r.signalingState&&(n._appliedTracksToSSRCs=new Map(n._tracksToSSRCs)),n._pendingLocalOffer||n._pendingRemoteOffer||n.dispatchEvent.apply(n,a([],o(e))))})),r.addEventListener("track",(function(e){n._pendingRemoteOffer=null,n.dispatchEvent(e)})),y(RTCPeerConnection.prototype,n,r),n}return i(t,e),Object.defineProperty(t.prototype,"localDescription",{get:function(){return this._pendingLocalOffer||this._peerConnection.localDescription}
164,enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"iceConnectionState",{get:function(){return this._isClosed?"closed":this._peerConnection.iceConnectionState},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"iceGatheringState",{get:function(){return this._isClosed?"complete":this._peerConnection.iceGatheringState},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"remoteDescription",{get:function(){return this._pendingRemoteOffer||this._peerConnection.remoteDescription},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"signalingState",{get:function(){return this._isClosed?"closed":this._pendingLocalOffer?"have-local-offer":this._pendingRemoteOffer?"have-remote-offer":this._peerConnection.signalingState},enumerable:!1,configurable:!0}),t.prototype.addIceCandidate=function(e){var t=this;return"have-remote-offer"===this.signalingState?this._signalingStateLatch.when("low").then((function(){return t._peerConnection.addIceCandidate(e)})):this._peerConnection.addIceCandidate(e)},t.prototype.createOffer=function(e){var t=this;if((e=Object.assign({},e)).offerToReceiveVideo&&!this._audioTransceiver&&(!b||!C(this,"audio"))){delete e.offerToReceiveAudio;try{this._audioTransceiver=b?this.addTransceiver("audio",{direction:"recvonly"}):this.addTransceiver("audio")}catch(e){return Promise.reject(e)}}if(e.offerToReceiveVideo&&!this._videoTransceiver&&(!b||!C(this,"video"))){delete e.offerToReceiveVideo;try{this._videoTransceiver=b?this.addTransceiver("video",{direction:"recvonly"}):this.addTransceiver("video")}catch(e){return Promise.reject(e)}}return this._peerConnection.createOffer(e).then((function(e){return t._rolledBackTracksToSSRCs.clear(),new RTCSessionDescription({type:e.type,sdp:v(t._tracksToSSRCs,e.sdp)})}))},t.prototype.createAnswer=function(e){var t=this;return this._pendingRemoteOffer?this._peerConnection.setRemoteDescription(this._pendingRemoteOffer).then((function(){return t._signalingStateLatch.lower(),t._peerConnection.createAnswer()})).then((function(e){return t._pendingRemoteOffer=null,t._rolledBackTracksToSSRCs.clear(),b?new RTCSessionDescription({type:e.type,sdp:v(t._tracksToSSRCs,e.sdp)}):e}),(function(e){throw t._pendingRemoteOffer=null,e})):this._peerConnection.createAnswer(e).then((function(e){return t._rolledBackTracksToSSRCs.clear(),b?new RTCSessionDescription({type:e.type,sdp:v(t._tracksToSSRCs,e.sdp)}):e}))},t.prototype.createDataChannel=function(e,t){var n=this._peerConnection.createDataChannel(e,t);return _(n),n},t.prototype.removeTrack=function(e){e.replaceTrack(null),this._peerConnection.removeTrack(e)},t.prototype.setLocalDescription=function(e){return this._rolledBackTracksToSSRCs.size>0&&(this._tracksToSSRCs=new Map(this._rolledBackTracksToSSRCs),this._rolledBackTracksToSSRCs.clear()),w(this,!0,e)},t.prototype.setRemoteDescription=function(e){return this._rolledBackTracksToSSRCs.clear(),w(this,!1,e)},t.prototype.close=function(){var e=this;this._isClosed||(this._isClosed=!0,this._peerConnection.close(),setTimeout((function(){e.dispatchEvent(new Event("iceconnectionstatechange")),e.dispatchEvent(new Event("signalingstatechange"))})))},t}(s);function w(e,t,n){var r,i=t?e._pendingLocalOffer:e._pendingRemoteOffer,o=t?e._pendingRemoteOffer:e._pendingLocalOffer,a=t?"have-local-offer":"have-remote-offer",s=t?"setLocalDescription":"setRemoteDescription";if(!t&&o&&"answer"===n.type)return function(e,t){var n=e._pendingLocalOffer;return e._peerConnection.setLocalDescription(n).then((function(){return e._pendingLocalOffer=null,e.setRemoteDescription(t)})).then((function(){return e._signalingStateLatch.lower()}))}(e,n);if("offer"===n.type){if(e.signalingState!==a&&"stable"!==e.signalingState)return Promise.reject(new Error("Cannot set "+(t?"local":"remote")+"\n        offer in state "+e.signalingState));i||"low"!==e._signalingStateLatch.state||e._signalingStateLatch.raise();var l=e.signalingState;return r=n,t?e._pendingLocalOffer=r:e._pendingRemoteOffer=r,e.signalingState!==l?Promise.resolve().then((function(){return e.dispatchEvent(new Event("signalingstatechange"))})):Promise.resolve()}return"rollback"===n.type?e.signalingState!==a?Promise.reject(new Error("Cannot rollback \n        "+(t?"local":"remote")+" description in "+e.signalingState)):(t?e._pendingLocalOffer=null:e._pendingRemoteOffer=null,e._rolledBackTracksToSSRCs=new Map(e._tracksToSSRCs),e._tracksToSSRCs=new Map(e._appliedTracksToSSRCs),Promise.resolve().then((function(){return e.dispatchEvent(new Event("signalingstatechange"))}))):e._peerConnection[s](n)}function C(e,t){return!!e.getTransceivers().find((function(e){var n=e.receiver,r=(void 0===n?{}:n).track;return(void 0===r?{}:r).kind===t}))}function _(e){return Object.defineProperties(e,{maxPacketLifeTime:{value:65535===e.maxPacketLifeTime?null:e.maxPacketLifeTime},maxRetransmits:{value:65535===e.maxRetransmits?null:e.maxRetransmits}})}h(RTCPeerConnection.prototype,g.prototype,"_peerConnection"),t.exp
164orts=g},{"../../eventtarget":351,"../util":510,"../util/latch":511,"../util/sdp":512}],506:[function(e,t,n){"use strict";var r=function(e){Object.defineProperties(this,{track:{enumerable:!0,value:e,writable:!0}})};t.exports=r},{}],507:[function(e,t,n){"use strict";var r=function(){function e(e){this.descriptionInitDict=e;var t=e&&"rollback"===e.type?null:new RTCSessionDescription(e);Object.defineProperties(this,{_description:{get:function(){return t}}})}return Object.defineProperty(e.prototype,"sdp",{get:function(){return this._description?this._description.sdp:this.descriptionInitDict.sdp},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"type",{get:function(){return this._description?this._description.type:this.descriptionInitDict.type},enumerable:!1,configurable:!0}),e}();t.exports=r},{}],508:[function(e,t,n){"use strict";t.exports=RTCSessionDescription},{}],509:[function(e,t,n){"use strict";if("function"==typeof RTCSessionDescription)switch((0,e("../util").guessBrowser)()){case"chrome":t.exports=e("./chrome");break;case"firefox":t.exports=e("./firefox");break;default:t.exports=RTCSessionDescription}else t.exports=function(){throw new Error("RTCSessionDescription is not supported")}},{"../util":510,"./chrome":507,"./firefox":508}],510:[function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,i=e.length;n<r;n++,i++)e[i]=t[n];return e};function o(e,t,n,r){if(!(r in t)&&!r.match(/^on[a-z]+$/)){var i=!1;try{var o=Object.getOwnPropertyDescriptor(e,r);i=o&&!!o.get}catch(e){}if(!i){var a;try{a=typeof e[r]}catch(e){}"function"===a&&(t[r]=function(){return this[n][r].apply(this[n],arguments)})}}}function a(){return"undefined"!=typeof navigator&&"string"==typeof navigator.userAgent?navigator.userAgent:null}function s(e){return void 0===e&&(e=a()),/Chrome|CriOS/.test(e)?"chrome":/Firefox|FxiOS/.test(e)?"firefox":/Safari|iPhone|iPad|iPod/.test(e)?"safari":null}var l=new Map;n.clearCachedSupportedCodecs=function(){l.clear()},n.defer=function(){var e={};return e.promise=new Promise((function(t,n){e.resolve=t,e.reject=n})),e},n.delegateMethods=function(e,t,n){for(var r in e)o(e,t,n,r)},n.difference=function(e,t){e=Array.isArray(e)?new Set(e):new Set(e.values()),t=Array.isArray(t)?new Set(t):new Set(t.values());var n=new Set;return e.forEach((function(e){t.has(e)||n.add(e)})),n},n.flatMap=function(e,t){return(e instanceof Map||e instanceof Set?Array.from(e.values()):e).reduce((function(e,n){return e.concat(t(n))}),[])},n.guessBrowser=s,n.guessBrowserVersion=function(e){void 0===e&&(e=a());var t={chrome:"Chrome|CriOS",firefox:"Firefox|FxiOS",safari:"Version"}[s(e)];if(!t)return null;var n=new RegExp("("+t+")/([^\\s]+)"),i=r(e.match(n)||[],3)[2];if(!i)return null;var o=i.split(".").map(Number);return{major:isNaN(o[0])?null:o[0],minor:isNaN(o[1])?null:o[1]}},n.isCodecSupported=function(e,t){var n=l.get(t);return n?Promise.resolve(n.has(e.toLowerCase())):function(e){if("undefined"!=typeof RTCRtpSender&&"function"==typeof RTCRtpSender.getCapabilities)return Promise.resolve(new Set(RTCRtpSender.getCapabilities(e).codecs.map((function(e){return e.mimeType.split("/")[1].toLowerCase()}))));if("undefined"==typeof RTCPeerConnection||void 0===RTCPeerConnection.prototype||"function"!=typeof RTCPeerConnection.prototype.addTransceiver||"function"!=typeof RTCPeerConnection.prototype.close||"function"!=typeof RTCPeerConnection.prototype.createOffer)return Promise.resolve(new Set);var t=new RTCPeerConnection;return t.addTransceiver(e),t.createOffer().then((function(e){var n=e.sdp;return t.close(),new Set((n.match(/^a=rtpmap:.+$/gm)||[]).map((function(e){return e.match(/^a=rtpmap:.+ ([^/]+)/)[1].toLowerCase()})))}),(function(){return t.close(),new Set}))}(t).then((function(n){return l.set(t,n),n.has(e.toLowerCase())}))},n.isIOSChrome=function(e){return void 0===e&&(e=a()),/Mobi/.test(e)&&"chrome"===s()&&/iPad|iPhone|iPod/.test(e)},n.interceptEvent=function(e,t){var n=null;Object.defineProperty(e,"on"+t,{get:function(){return n},set:function(e){n&&this.removeEventListener(t,n),"function"==typeof e?(n=e,this.addEventListener(t,n)):n=null}})},n.legacyPromise=function(e,t,n){return t?e.then(t,n):e},n.makeUUID=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))},n.proxyProperties=function(e,t,n){Object.getOwnPropertyNames(e).forEach((function(e){!function(e,t,n,o){if(o in t)return;if(o.match(/^on[a-z]+$/))return Object.defineProperty(t,o,{value:null,writable:!0}),void n.addEventListener(o.slice(2),(function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return t.dispatchEvent.apply(t,i([],r(e)))}));Object.defineProperty(t,o,{enumerable:!0,get:function(){return n[o]}})}(0,t,n,e)}))},n.support=function(){return"object"==typeof navigator&&"object"==typeof navigator.mediaDevices&&"function"==typeof navigator.mediaDevices.getUserMedia&&"function"==typeof RTCPeerConnection}},{}],511:[function(e,t,n){"use strict";var r=e("./").defer,i={high:new Set(["low"]),low:new Set(["high"])},o=function(){function e(e){void 0===e&&(e="low");var t=e;Object.defineProperties(this,{_state:{set:function(e){var n=this;if(t!==e){t=e;var r=this._whenDeferreds.get(t);r.forEach((function(e){return e.resolve(n)})),r.clear()}},get:function(){return t}},_whenDeferreds:{value:new Map([["high",new Set],["low",new Set]])}})}return Object.defineProperty(e.prototype,"state",{get:function(){return this._state}
164,enumerable:!1,configurable:!0}),e.prototype.lower=function(){return this.transition("low")},e.prototype.raise=function(){return this.transition("high")},e.prototype.transition=function(e){if(!i[this.state].has(e))throw a(this.state,e);return this._state=e,this},e.prototype.when=function(e){if(this.state===e)return Promise.resolve(this);if(!i[this.state].has(e))return Promise.reject(a(this.state,e));var t=r();return this._whenDeferreds.get(e).add(t),t.promise},e}();function a(e,t){return new Error('Cannot transition from "'+e+'" to "'+t+'"')}t.exports=o},{"./":510}],512:[function(e,t,n){"use strict";var r=e("./"),i=r.flatMap,o=r.guessBrowser,a=null;var s=null;function l(e){return e&&function(){if("boolean"==typeof a)return a;if("undefined"==typeof RTCPeerConnection)return a=!1;try{new RTCPeerConnection({sdpSemantics:"foo"}),a=!1}catch(e){a=!0}return a}()?{"plan-b":"planb","unified-plan":"unified"}[e]:function(){if(!s)if("undefined"!=typeof RTCPeerConnection&&"addTransceiver"in RTCPeerConnection.prototype){var e=new RTCPeerConnection;try{e.addTransceiver("audio"),s="unified"}catch(e){s="planb"}e.close()}else s="planb";return s}()}function c(e,t){return(t.match(new RegExp(e,"gm"))||[]).reduce((function(t,n){var r=n.match(new RegExp(e));return r?t.add(r[1]):t}),new Set)}function u(e,t){return c(e,t)}function p(e){return u("^a=ssrc:[0-9]+ +msid:.+ +(.+) *$",e)}function f(e){return u("^a=msid:.+ +(.+) *$",e)}function d(e,t){return c("^a=ssrc:([0-9]+) +msid:[^ ]+ +"+t+" *$",e)}function h(e,t,n){return void 0===t&&(t=".*"),void 0===n&&(n=".*"),e.split("\r\nm=").slice(1).map((function(e){return"m="+e})).filter((function(e){var r=new RegExp("m="+t,"gm"),i=new RegExp("a="+n,"gm");return r.test(e)&&i.test(e)}))}function m(e){return Array.from(c("^a=ssrc:([0-9]+) +.*$",e))}function y(e,t){var n=h(e),r=new RegExp("^a=msid:[^ ]+ +"+t+" *$","gm"),o=n.filter((function(e){return e.match(r)}));return new Set(i(o,m))}function b(e,t,n){return new Map(Array.from(e(n)).map((function(e){return[e,t(n,e)]})))}function v(e){return b(p,d,e)}function g(e){return b(f,y,e)}function w(e,t,n){var r=e(n),i=new Map;r.forEach((function(e,r){if(t.has(r)){var o=Array.from(t.get(r)),a=Array.from(e);o.forEach((function(e,t){var r=a[t];i.set(r,e);var o="^a=ssrc:"+r+" (.*)$",s="a=ssrc:"+e+" $1";n=n.replace(new RegExp(o,"gm"),s)}))}else t.set(r,e)}));var o="^(a=ssrc-group:[^ ]+ +)(.*)$";return(n.match(new RegExp(o,"gm"))||[]).forEach((function(e){var t=e.match(new RegExp(o));if(t){var r=t[1],a=t[2].split(" ").map((function(e){var t=i.get(e);return t||e})).join(" ");n=n.replace(t[0],r+a)}})),n}n.clearChromeCachedSdpFormat=function(){s=null},n.getSdpFormat=function(e){return{chrome:l(e),firefox:"unified",safari:"undefined"!=typeof RTCRtpTransceiver&&"currentDirection"in RTCRtpTransceiver.prototype?"unified":"planb"}[o()]||null},n.getMediaSections=h,n.getPlanBTrackIds=p,n.getUnifiedPlanTrackIds=f,n.getPlanBSSRCs=d,n.getUnifiedPlanSSRCs=y,n.updatePlanBTrackIdsToSSRCs=function(e,t){return w(v,e,t)},n.updateUnifiedPlanTrackIdsToSSRCs=function(e,t){return w(g,e,t)}},{"./":510}],513:[function(e,t,n){t.exports={_from:"twilio-video",_id:"[email protected]",_inBundle:!1,_integrity:"sha512-hdiYOKuujtLdG7A8Ae/8qeJWfL/zZXVTrh79fWq7d/QAgZ966R7QJdWkTAxdairhlhGLCu4cN4jOBxQ1Bqe9MQ==",_location:"/twilio-video",_phantomChildren:{inherits:"2.0.4","is-arguments":"1.1.1","is-generator-function":"1.0.10","is-typed-array":"1.1.10","which-typed-array":"1.1.9"},_requested:{type:"tag",registry:!0,raw:"twilio-video",name:"twilio-video",escapedName:"twilio-video",rawSpec:"",saveSpec:null,fetchSpec:"latest"},_requiredBy:["#DEV:/","#USER"],_resolved:"https://registry.npmjs.org/twilio-video/-/twilio-video-2.27.0.tgz",_shasum:"1c4afe1cafaf69535ccfd6f3506fe1927920471b",_spec:"twilio-video",_where:"C:\\XAMPP-7.3.9\\htdocs\\wp52\\wp-content\\plugins\\wise-chat-pro",author:{name:"Mark Andrus Roberts",email:"[email protected]"},browser:{ws:"./src/ws.js",xmlhttprequest:"./src/xmlhttprequest.js"},bugs:{url:"https://github.com/twilio/twilio-video.js/issues"},bundleDependencies:!1,contributors:[{name:"Ryan Rowland",email:"[email protected]"},{name:"Manjesh Malavalli",email:"[email protected]"},{name:"Makarand Patwardhan",email:"[email protected]"}],dependencies:{events:"^3.3.0",util:"^0.12.4",ws:"^7.4.6",xmlhttprequest:"^1.8.0"},deprecated:!1,description:"Twilio Video JavaScript Library",devDependencies:{"@babel/core":"^7.14.2","@babel/preset-env":"^7.14.2","@babel/preset-typescript":"^7.13.0","@types/express":"^4.11.0","@types/node":"^8.5.1","@types/selenium-webdriver":"^3.0.8","@types/ws":"^3.2.1","@typescript-eslint/eslint-plugin":"^4.13.0","@typescript-eslint/parser":"^4.0.0","babel-cli":"^6.26.0","babel-preset-es2015":"^6.24.1",browserify:"^17.0.0",cheerio:"^0.22.0",cors:"^2.8.5",electron:"^17.2.0",envify:"^4.0.0",eslint:"^6.2.1","eslint-config-standard":"^14.0.0","eslint-plugin-import":"^2.18.2","eslint-plugin-node":"^9.1.0","eslint-plugin-
164promise":"^4.2.1","eslint-plugin-standard":"^4.0.1",express:"^4.16.2",glob:"^7.1.7","ink-docstrap":"^1.3.2",inquirer:"^7.0.0","is-docker":"^2.0.0",jsdoc:"^3.5.5","jsdoc-babel":"^0.5.0","json-loader":"^0.5.7",karma:"6.4.1","karma-browserify":"^8.0.0","karma-chrome-launcher":"^2.0.0","karma-edgium-launcher":"^4.0.0-0","karma-electron":"^6.1.0","karma-firefox-launcher":"^1.3.0","karma-htmlfile-reporter":"^0.3.8","karma-junit-reporter":"^1.2.0","karma-mocha":"^1.3.0","karma-safari-launcher":"^1.0.0","karma-spec-reporter":"0.0.32","karma-typescript":"^5.5.1","karma-typescript-es6-transform":"^5.5.1",mocha:"^3.2.0","mock-require":"^3.0.3",ncp:"^2.0.0","node-http-server":"^8.1.2","npm-run-all":"^4.0.2",nyc:"^15.1.0",requirejs:"^2.3.3",rimraf:"^2.6.1","simple-git":"^1.126.0",sinon:"^4.0.1","ts-node":"4.0.1",tslint:"5.8.0",twilio:"^3.49.0","twilio-release-tool":"^1.0.2",typescript:"4.2.2","uglify-js":"^2.8.22","vinyl-fs":"^2.4.4","vinyl-source-stream":"^1.1.0",watchify:"^3.11.1","webrtc-adapter":"^7.7.1"},engines:{node:">=0.12"},homepage:"https://twilio.com",keywords:["twilio","webrtc","library","javascript","video","rooms"],license:"BSD-3-Clause",main:"./es5/index.js",name:"twilio-video",repository:{type:"git",url:"git+https://github.com/twilio/twilio-video.js.git"},scripts:{build:"npm-run-all clean lint docs test:unit test:integration build:es5 build:js build:min.js test:umd","build:es5":"rimraf ./es5 && mkdir -p es5 && tsc tsdef/twilio-video-tests.ts --noEmit --lib es2018,dom && tsc","build:js":"node ./scripts/build.js ./src/twilio-video.js ./LICENSE.md ./dist/twilio-video.js","build:min.js":'uglifyjs ./dist/twilio-video.js -o ./dist/twilio-video.min.js --comments "/^! twilio-video.js/" -b beautify=false,ascii_only=true',"build:quick":"npm-run-all clean lint docs build:es5 build:js build:min.js",clean:"rimraf ./coverage ./es5 ./dist",docs:"node ./scripts/docs.js ./dist/docs",lint:"npm-run-all lint:js lint:ts","lint:js":"eslint ./lib ./test/*.js ./docker/**/*.js ./test/framework/*.js ./test/lib/*.js ./test/integration/** ./test/unit/** ","lint:ts":"eslint ./tsdef/*.ts ./lib/**/*.ts",printVersion:"node --version && npm --version",test:"npm-run-all test:unit test:integration","test:crossbrowser":"npm-run-all test:crossbrowser:*","test:crossbrowser:build":"npm-run-all test:crossbrowser:build:*","test:crossbrowser:build:browser":"cd ./test/crossbrowser && browserify lib/crossbrowser/src/browser/index.js > src/browser/index.js","test:crossbrowser:build:clean":"rimraf ./test/crossbrowser/lib ./test/crossbrowser/src/browser/index.js","test:crossbrowser:build:lint":"cd ./test/crossbrowser && tslint --project tsconfig.json","test:crossbrowser:build:tsc":"cd ./test/crossbrowser && tsc","test:crossbrowser:test":"cd ./test/crossbrowser && mocha --compilers ts:ts-node/register test/integration/spec/**/*.ts","test:framework":"npm-run-all test:framework:install test:framework:no-framework test:framework:react","test:framework:angular":"npm-run-all test:framework:angular:*","test:framework:angular:install":"cd ./test/framework/twilio-video-angular && rimraf ./node_modules package-lock.json && npm install","test:framework:angular:run":"mocha ./test/framework/twilio-video-angular.js","test:framework:install":"npm install chromedriver && npm install selenium-webdriver && npm install geckodriver && npm install puppeteer","test:framework:no-framework":"npm-run-all test:framework:no-framework:*","test:framework:no-framework:run":"mocha ./test/framework/twilio-video-no-framework.js","test:framework:react":"npm-run-all test:framework:react:*","test:framework:react:build":"cd ./test/framework/twilio-video-react && npm run build","test:framework:react:install":"cd ./test/framework/twilio-video-react && rimraf ./node_modules package-lock.json && npm install","test:framework:react:run":"mocha ./test/framework/twilio-video-react.js","test:framework:react:test":"node ./scripts/framework.js twilio-video-react","test:integration":"npm run build:es5 && node ./scripts/karma.js karma/integration.conf.js","test:integration:adapter":"node ./scripts/karma.js karma/integration.adapter.conf.js","test:sdkdriver":"npm-run-all test:sdkdriver:*","test:sdkdriver:build":"npm-run-all test:sdkdriver:build:*","test:sdkdriver:build:clean":"rimraf ./test/lib/sdkdriver/lib ./test/lib/sdkdriver/test/integration/browser/index.js","test:sdkdriver:build:lint":"cd ./test/lib/sdkdriver && tslint --project tsconfig.json","test:sdkdriver:build:tsc":"cd ./test/lib/sdkdriver && tsc --rootDir src","test:sdkdriver:test":"npm-run-all test:sdkdriver:test:*","test:sdkdriver:test:integration":"npm-run-all test:sdkdriver:test:integration:*","test:sdkdriver:test:integration:browser":"cd ./test/lib/sdkdriver/test/integration && browserify browser/browser.js > browser/index.js","test:sdkdriver:test:integration:run":"cd ./test/lib/sdkdriver && mocha --compilers ts:ts-node/register test/integration/spec/**/*.ts","test:sdkdriver:test:unit":"cd ./test/lib/sdkdriver && mocha --compilers ts:ts-node/register test/unit/spec/**/*.ts","test:serversiderender":"mocha ./test/serversiderender/index.js","test:umd":"mocha ./test/umd/index.js","test:umd:install":"npm install [email protected]","test:unit":"npm-run-all printVersion build:es5 && nyc --report-dir=./coverage --include=lib/**/* --reporter=html --reporter=lcov --reporter=text mocha -r ts-node/register ./test/unit/*","test:unit:quick":"nyc --report-dir=./coverage --include=lib/**/* --reporter=html --reporter=lcov mocha -r ts-node/register",watch:"tsc -w"}
164,title:"Twilio Video",types:"./tsdef/index.d.ts",version:"2.27.0"}},{}],514:[function(e,t,n){t.exports=WebSocket},{}],515:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==a(e)&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var s=r?Object.getOwnPropertyDescriptor(e,i):null;s&&(s.get||s.set)?Object.defineProperty(n,i,s):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(e("cookie")),i=e("./utils");function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var s=function(){return(s=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},l=function(){function e(e,t){var n=this;this.changeListeners=[],this.HAS_DOCUMENT_COOKIE=!1,this.cookies=(0,i.parseCookies)(e,t),new Promise((function(){n.HAS_DOCUMENT_COOKIE=(0,i.hasDocumentCookie)()})).catch((function(){}))}return e.prototype._updateBrowserValues=function(e){this.HAS_DOCUMENT_COOKIE&&(this.cookies=r.parse(document.cookie,e))},e.prototype._emitChange=function(e){for(var t=0;t<this.changeListeners.length;++t)this.changeListeners[t](e)},e.prototype.get=function(e,t,n){return void 0===t&&(t={}),this._updateBrowserValues(n),(0,i.readCookie)(this.cookies[e],t)},e.prototype.getAll=function(e,t){void 0===e&&(e={}),this._updateBrowserValues(t);var n={};for(var r in this.cookies)n[r]=(0,i.readCookie)(this.cookies[r],e);return n},e.prototype.set=function(e,t,n){var i;"object"===a(t)&&(t=JSON.stringify(t)),this.cookies=s(s({},this.cookies),((i={})[e]=t,i)),this.HAS_DOCUMENT_COOKIE&&(document.cookie=r.serialize(e,t,n)),this._emitChange({name:e,value:t,options:n})},e.prototype.remove=function(e,t){var n=t=s(s({},t),{expires:new Date(1970,1,1,0,0,1),maxAge:0});this.cookies=s({},this.cookies),delete this.cookies[e],this.HAS_DOCUMENT_COOKIE&&(document.cookie=r.serialize(e,"",n)),this._emitChange({name:e,value:void 0,options:t})},e.prototype.addChangeListener=function(e){this.changeListeners.push(e)},e.prototype.removeChangeListener=function(e){var t=this.changeListeners.indexOf(e);t>=0&&this.changeListeners.splice(t,1)},e}();n.default=l,t.exports=n.default},{"./utils":517,cookie:158}],516:[function(e,t,n){"use strict";var r;Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=((r=e("./Cookies"))&&r.__esModule?r:{default:r}).default;n.default=i,t.exports=n.default},{"./Cookies":515}],517:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.hasDocumentCookie=function(){return"object"===("undefined"==typeof document?"undefined":o(document))&&"string"==typeof document.cookie},n.cleanCookies=function(){document.cookie.split(";").forEach((function(e){document.cookie=e.replace(/^ +/,"").replace(/=.*/,"=;expires="+(new Date).toUTCString()+";path=/")}))},n.parseCookies=function(e,t){return"string"==typeof e?r.parse(e,t):"object"===o(e)&&null!==e?e:{}},n.isParsingCookie=a,n.readCookie=function(e,t){void 0===t&&(t={});var n=function(e){if(e&&"j"===e[0]&&":"===e[1])return e.substr(2);return e}(e);if(a(n,t.doNotParse))try{return JSON.parse(n)}catch(e){}return e};var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==o(e)&&"function"!=typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if(Object.prototype.hasOwnProperty.call(e,a)){var s=r?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(n,a,s):n[a]=e[a]}n.default=e,t&&t.set(e,n);return n}(e("cookie"));function i(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function a(e,t){return void 0===t&&(t=!e||"{"!==e[0]&&"["!==e[0]&&'"'!==e[0]),!t}}
164,{cookie:158}],518:[function(e,t,n){"use strict";function r(e,t,n,r){for(;t>=n&&!e("(min-resolution: "+t/r+"dppx)").matches;)t--;return t}function i(e){if(void 0===e&&(e=window),!e)return 1;if(void 0!==e.devicePixelRatio)return e.devicePixelRatio;var t=e.document.frames;return void 0!==t?void 0!==t.devicePixelRatio?t.devicePixelRatio:t.screen.deviceXDPI/t.screen.systemXDPI:void 0!==e.matchMedia?function(e){for(var t=e.matchMedia,n=10,i=.1,o=1,a=n,s=0;s<4;s++)n=9+(a=10*r(t,n,i,o)),i=a,o*=10;return a/o}(e):1}Object.defineProperty(n,"__esModule",{value:!0}),n.elementZoomLevel=function(e,t){var n=(e instanceof Element?getComputedStyle(e).zoom:e.zoom)||1;return i(t)*("string"==typeof n?parseFloat(n):n)},n.zoomLevel=i},{}]},{},[94]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.