209 lines
196 KiB
JavaScript
209 lines
196 KiB
JavaScript
(this.webpackChunkdiscord_app=this.webpackChunkdiscord_app||[]).push([[70272],{823660:(e,t,n)=>{e.exports=n.p+"61550500acf9704ea60d48d688f07f08.svg"},323236:(e,t,n)=>{e.exports=n.p+"d11edc65a78063b7cb45bed37baedc9b.svg"},860321:(e,t,n)=>{e.exports=n.p+"2366391afb15ed6c2a019a0c0caa0797.svg"},145792:(e,t,n)=>{e.exports=n.p+"6345e6aced36309efc7fe28a539383ab.svg"},832834:(e,t,n)=>{e.exports=n.p+"2d04bd07a768396c5570cb883f542130.svg"},852617:(e,t,n)=>{e.exports=n.p+"8b3efa4cbe0bd215b4902188010632d5.svg"},67976:(e,t,n)=>{e.exports=n.p+"63f7edfcf31598ede046d1c9dab98351.svg"},967305:(e,t,n)=>{e.exports=n.p+"2f621771fd7297d9176d37c455e703db.png"},412384:(e,t,n)=>{e.exports=n.p+"9edb8746150af4d84c0c7677b9c1b7b9.png"},881874:(e,t,n)=>{e.exports=n.p+"6c31bc0514ccb0fa49302f76340350bd.png"},442907:(e,t,n)=>{e.exports=n.p+"ab68afa775860024063291a2a56eaa09.svg"},6912:(e,t,n)=>{"use strict";n.d(t,{Z:()=>f});var r=n(785893),i=(n(667294),
|
|
n(294184)),o=n.n(i),a=n(707961),l=n(721160),c=n(621329),s=n(189865),u=n(36919),d=n.n(u);function f(e){var t=e.grantedPermissions,n=e.disabledPermissions,i=e.grantedPermissionsHeader,u=e.disabledPermissionsHeader,f=e.className;return(0,r.jsxs)("div",{className:o()(d().list,f),children:[null!=t&&t.length>0?(0,r.jsxs)(r.Fragment,{children:[null!=i?(0,r.jsx)(a.vwX,{className:d().permissionHeader,children:i}):null,(0,r.jsx)("div",{className:d().container,children:t.map((function(e){return(0,r.jsxs)("div",{className:d().permission,children:[(0,r.jsx)(c.Z,{width:16,height:16,className:d().check}),(0,r.jsx)(a.xvT,{variant:"text-sm/normal",children:(0,l.wt)(e)})]},e.toString())}))})]}):null,null!=n&&n.length>0?(0,r.jsxs)(r.Fragment,{children:[null!=u?(0,r.jsx)(a.vwX,{className:d().permissionHeader,children:u}):null,(0,r.jsx)("div",{className:d().container,children:n.map((function(e){return(0,r.jsxs)("div",{className:d().permission,children:[(0,r.jsx)(s.Z,{width:16,height:16,className:d().cross
|
|
}),(0,r.jsx)(a.xvT,{variant:"text-sm/normal",children:(0,l.wt)(e)})]},e.toString())}))})]}):null]})}},851547:(e,t,n)=>{"use strict";n.d(t,{r:()=>A,Z:()=>Y});var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(853158),c=n(707961),s=n(672380),u=n(918771),d=n(910348),f=n(159055),p=n(802139),h=n(45984),m=n(159689),y=n(220496),g=n(930948),b=n(2590),v=n(16582),O=n.n(v);function j(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function C(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function P(e){P=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return P(e)}function I(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n)
|
|
;"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){_(e,t,n[t])}))}return e}function x(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function E(e,t){return!t||"object"!==S(t)&&"function"!=typeof t?j(e):t}function w(e,t){w=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return w(e,t)}var S=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function N(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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){var n,r=P(e);if(t){var i=P(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return E(this,n)}}function R(){var e=function(e,t){t||(t=e.slice(0));return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}(["grayscale(",")"]);R=function(){return e};return e}var A={SMALL:{width:640,height:360,margin:15},MEDIUM:{width:880,height:495,margin:20}},T={width:1920,height:1080},L={width:1280,height:720},D=function(e){return(0,u.lV)(x(I({},e),{className:O().videoWrapper,mediaPlayerClassName:O().mediaPlayer}))},M=function(e){return(0,r.jsx)(m.Z,I({},e))},k=function(e){
|
|
var t,n,i=e.item,o=e.size,a=e.onPlay,l=e.onEnded,s=e.onClick,d=e.playable,f=e.volume,h=e.isMuted,m=e.onVolumeChange,y=e.onMute;if(i.type===b.s9s.YOUTUBE_VIDEO){t=I({url:(0,b.n8r)(i.youtubeVideoId)},T);n=I({url:"".concat((0,b.ivE)(i.youtubeVideoId),"?").concat("rel=0&iv_load_policy=3&showinfo=0&modestbranding=1")},L)}else{var g=null!=i.width?i.width:0,v=null!=i.height?i.height:0;t={url:i.thumbnailSrc,width:g,height:v};n={url:i.src,proxyURL:i.src,width:g,height:v}}var j=(0,r.jsx)(p.BC,{href:null,thumbnail:t,video:n,allowFullScreen:!0,maxHeight:o.height,maxWidth:o.width,onPlay:a,onEnded:l,playable:d,className:O().video,volume:f,onVolumeChange:m,autoMute:h,onMute:y,autoPlay:d,renderVideoComponent:D,renderImageComponent:M,renderLinkComponent:u.iT});return d?j:(0,r.jsx)(c.P3F,{className:O().itemImageWrapper,onClick:s,children:j})},Z=function(){return(0,r.jsx)("div",{className:O().paginationVideoOverlay,children:(0,r.jsx)(y.Z,{inactive:!0,className:O().paginationVideoPlayPill,
|
|
renderLinkComponent:u.iT})})},G=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&&w(e,t)}(n,e);var t=N(n);function n(){C(this,n);var e;(e=t.apply(this,arguments)).state={currentIndex:0,animate:!0,playingVideo:!1,hasInteracted:!1,hoveringPreviousItem:!1,hoveringNextItem:!1,volume:1,isMuted:!0};e.getItemSize=function(){var t=e.props.width,n=A.MEDIUM;null!=t&&t<n.width&&(n=A.SMALL);return n};e.setItem=function(t,n){var r=j(e),i=r.props,o=i.items,a=i.onIntentionalChange,l=r.state.currentIndex,c=(0,f.gN)(l,o.length),s=(0,f.gN)(t,o.length),u=1===Math.abs(t-c)||t===o.length-1&&0===c||0===t&&c===o.length-1;e.setState({playingVideo:!1,currentIndex:s,animate:u,hasInteracted:n});n&&null!=a&&a(o[s],c,s)};e.autoNext=function(){e.setItem(e.state.currentIndex+1,!1)};e.manualNext=function(){
|
|
e.setItem(e.state.currentIndex+1,!0)};e.manualPrevious=function(){e.setItem(e.state.currentIndex-1,!0)};e.handlePlay=function(t){return e.setState({playingVideo:!0,hasInteracted:!t})};e.handleEnded=function(){e.state.hasInteracted||e.autoNext()};e.handleVolumeChange=function(t){e.setState({volume:t,hasInteracted:!0})};e.handleMute=function(t){e.setState({isMuted:t,hasInteracted:!0})};e.handleVideoClick=function(t){e.setItem(t,!0)};e.handleEdgeItemMouseLeave=function(){e.setState({hoveringPreviousItem:!1,hoveringNextItem:!1})};e.renderCarouselImage=function(t,n,i){return i?(0,r.jsx)(c.P3F,{onClick:function(){return e.handleCurrentItemClick(t,n)},className:O().itemImageWrapper,children:(0,r.jsx)("img",{src:t.src,alt:"",className:O().currentImage})}):(0,r.jsx)(c.P3F,{onClick:function(){return e.setItem(n,!0)},className:O().itemImageWrapper,children:(0,r.jsx)("img",{alt:"",className:O().itemImage,src:t.src,draggable:!1})})};e.renderItem=function(t,n,i){
|
|
var o=e.state,c=o.currentIndex,s=o.volume,u=o.isMuted,d=n===(0,f.gN)(c,e.props.items.length);return(0,r.jsx)(l.Z.div,{className:a()(O().item,_({},O().currentItem,d)),style:null!=i?e.getStyle(n,i):null,onMouseEnter:d?null:function(){return e.handleEdgeItemMouseEnter(n)},onMouseLeave:d?null:e.handleEdgeItemMouseLeave,children:t.type===b.s9s.VIDEO||t.type===b.s9s.YOUTUBE_VIDEO?(0,r.jsx)(k,{item:t,size:e.getItemSize(),onPlay:e.handlePlay,onEnded:e.handleEnded,playable:d,onClick:function(){return e.handleVideoClick(n)},volume:s,onVolumeChange:e.handleVolumeChange,isMuted:u,onMute:e.handleMute}):e.renderCarouselImage(t,n,d)})};e.renderPaginationItem=function(t,n){var i=e.state.currentIndex===n;return(0,r.jsxs)("div",{className:a()(O().paginationItem,i?O().selectedStorePaginationItem:O().unselectedStorePaginationItem),children:[(0,r.jsx)("img",{alt:null==t.alt?n:t.alt,className:O().storePaginationImg,src:e.getPaginationSrc(t),draggable:!1
|
|
}),t.type===b.s9s.YOUTUBE_VIDEO||t.type===b.s9s.VIDEO?(0,r.jsx)(Z,{}):null,i?(0,r.jsx)("div",{className:O().overlappingBorder}):null]},"page-".concat(n))};return e}var i=n.prototype;i.componentDidMount=function(){g.S.subscribe(b.CkL.CAROUSEL_PREV,this.manualPrevious);g.S.subscribe(b.CkL.CAROUSEL_NEXT,this.manualNext)};i.componentWillUnmount=function(){g.S.unsubscribe(b.CkL.CAROUSEL_PREV,this.manualPrevious);g.S.unsubscribe(b.CkL.CAROUSEL_NEXT,this.manualNext)};i.getStyle=function(e,t){var n=t.interpolate({inputRange:[0,1],outputRange:[1,0],extrapolate:l.Z.Extrapolate.CLAMP});return{opacity:t.interpolate({inputRange:[0,1],outputRange:[.3,1],extrapolate:l.Z.Extrapolate.CLAMP}),filter:l.Z.template(R(),n)}};i.handleCurrentItemClick=function(e,t){var n=this.props.onCurrentItemClick;null!=n&&n(e,t);this.setState({hasInteracted:!0})};i.handleEdgeItemMouseEnter=function(e){var t=this.state.currentIndex;e<t?this.setState({hoveringPreviousItem:!0}):e>t&&this.setState({hoveringNextItem:!0})}
|
|
;i.renderCarousel=function(){var e=this.props.items,t=this.state,n=t.currentIndex,i=t.animate,o=t.hoveringPreviousItem,l=t.hoveringNextItem,c=(0,r.jsx)(f.ZP,{items:e,itemSize:this.getItemSize(),renderItem:this.renderItem,currentIndex:n,animate:i,edgeItems:2});return e.length<=1?c:(0,r.jsxs)("div",{className:O().carouselButtonsContainer,children:[c,(0,r.jsx)(d.am,{onClick:this.manualPrevious,className:a()(O().arrow,_({},O().arrowHovered,o))}),(0,r.jsx)(d.Pz,{onClick:this.manualNext,className:a()(O().arrow,_({},O().arrowHovered,l))})]})};i.getPaginationSrc=function(e){return e.type===b.s9s.YOUTUBE_VIDEO?(0,b.n8r)(e.youtubeVideoId):e.type===b.s9s.IMG?e.src:e.type===b.s9s.VIDEO?e.thumbnailSrc:null};i.render=function(){var e=this,t=this.props,n=t.items,i=t.className,o=t.autoplayInterval,a=t.paused,l=this.state,c=l.currentIndex,s=l.playingVideo,u=l.hasInteracted;return(0,r.jsxs)(h.Z,{pauseOnHover:!0,onInterval:this.autoNext,interval:o,className:i,disable:s||u||a,
|
|
children:[this.renderCarousel(),(0,r.jsx)("div",{className:O().pagination,children:(0,r.jsx)(d.ZP,{renderItem:this.renderPaginationItem,scrollToPadding:85,items:n,selectedIndex:c,onSetItem:function(t){return e.setItem(t,!0)},paginationContainerClass:O().scroller,align:n.length<6?d.ZP.Align.LEFT:d.ZP.Align.CENTER})})]})};return n}(i.PureComponent);G.defaultProps={autoplayInterval:8e3,paused:!1};const Y=(0,s.Z)(G)},714898:(e,t,n)=>{"use strict";n.d(t,{Z:()=>L});var r,i=n(785893),o=n(667294),a=n(294184),l=n.n(a),c=n(823493),s=n.n(c),u=n(853158),d=n(443660),f=n(775461),p=n(2590);function h(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}var m=(h(r={},p.EkH.MODAL_CAROUSEL_NEXT,f.XM),h(r,p.EkH.MODAL_CAROUSEL_PREV,f.py),h(r,p.EkH.CLOSE_MODAL,f.U3),r),y=n(241166),g=n(874049),b=n(910348),v=n(930948),O=n(354392),j=n.n(O);function C(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _(e,t,n){
|
|
t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function P(e){P=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return P(e)}function I(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&&w(e,t)}function x(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){_(e,t,n[t])}))}return e}function E(e,t){return!t||"object"!==S(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function w(e,t){
|
|
w=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return w(e,t)}var S=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function N(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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){var n,r=P(e);if(t){var i=P(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return E(this,n)}}var R={friction:10,tension:100};function A(e,t){return(e%t+t)%t}var T=function(e){I(n,e);var t=N(n);function n(){C(this,n);var e;(e=t.apply(this,arguments)).state={translate:new u.Z.Value(0),opacity:new u.Z.Value(1)};return e}var r=n.prototype;r.componentWillEnter=function(e){var t=this.props.directionHistory,n=this.state,r=n.translate,i=n.opacity;r.setValue(t[t.length-1]);i.setValue(0);e()
|
|
;u.Z.parallel([u.Z.timing(i,{toValue:1,easing:u.Z.Easing.out(u.Z.Easing.linear),duration:200}),u.Z.spring(r,x({toValue:0},R))]).start()};r.componentWillLeave=function(e){var t=this.props.directionHistory,n=this.state,r=n.opacity,i=n.translate;u.Z.parallel([u.Z.timing(r,{toValue:0,easing:u.Z.Easing.in(u.Z.Easing.linear),duration:200}),u.Z.spring(i,x({toValue:-1*t[t.length-1]},R))]).start(e)};r.getStyle=function(){var e=this.state,t=e.translate,n=e.opacity;return u.Z.accelerate({opacity:n,transform:[{translateX:t.interpolate({inputRange:[0,1],outputRange:["0px","300px"]})}]})};r.render=function(){var e=this.props.item;return(0,i.jsx)(u.Z.img,{src:e.src,alt:"",className:j().slide,style:this.getStyle()})};return n}(o.Component),L=function(e){I(n,e);var t=N(n);function n(e){C(this,n);var r;(r=t.call(this,e)).gotoNext=function(){var e=r.state.currentIndex;r.navigateTo(e+1)};r.gotoPrev=function(){var e=r.state.currentIndex;r.navigateTo(e-1)};r.gotoNextThrottled=s()(r.gotoNext,300)
|
|
;r.gotoPrevThrottled=s()(r.gotoPrev,300);r.state={currentIndex:e.startWith,directionHistory:[]};return r}var r=n.prototype;r.componentDidMount=function(){this.preloadNextImages();y.Z.disable();y.Z.enableTemp(m);v.S.subscribe(p.CkL.MODAL_CAROUSEL_NEXT,this.gotoNextThrottled);v.S.subscribe(p.CkL.MODAL_CAROUSEL_PREV,this.gotoPrevThrottled)};r.componentWillUnmount=function(){y.Z.disableTemp();v.S.unsubscribe(p.CkL.MODAL_CAROUSEL_NEXT,this.gotoNextThrottled);v.S.unsubscribe(p.CkL.MODAL_CAROUSEL_PREV,this.gotoPrevThrottled)};r.preloadNextImages=function(){var e=this.state.currentIndex,t=this.props.items,n=A(e+1,t.length),r=A(e-1,t.length);this.preloadImage(t[n]);this.preloadImage(t[r])};r.preloadImage=function(e){(0,g.po)(e.src)};r.componentDidUpdate=function(e,t){this.state.currentIndex!==t.currentIndex&&this.preloadNextImages()};r.navigateTo=function(e){var t,n,r=this.state,i=r.directionHistory,o=r.currentIndex;i.push(e-o);e=A(e,this.props.items.length);this.setState({currentIndex:e,
|
|
directionHistory:i});null===(n=(t=this.props).onIndexChange)||void 0===n||n.call(t,e)};r.render=function(){var e,t=this.props.className,n=this.state,r=n.currentIndex,o=n.directionHistory,a=this.props.items[r];return(0,i.jsxs)(d.Z,{component:"div",className:l()(j().wrapper,t),children:[(0,i.jsx)(b.am,{className:j().navPrev,onClick:this.gotoPrev}),null!==(e=a.component)&&void 0!==e?e:(0,i.jsx)(T,{item:a,directionHistory:o},a.src),(0,i.jsx)(b.Pz,{className:j().navNext,onClick:this.gotoNext})]})};return n}(o.Component);L.defaultProps={startWith:0}},259738:(e,t,n)=>{"use strict";n.d(t,{i:()=>w,Z:()=>R});var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(120053),c=n.n(l),s=n(707961),u=n(965309),d=n(749266),f=n(534681),p=n(473708),h=n(601672),m=n.n(h);function y(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){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function b(e,t,n){
|
|
t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function v(e){v=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return v(e)}function O(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){b(e,t,n[t])}))}return e}function j(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){
|
|
Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function C(e,t){return!t||"object"!==I(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function _(e,t){_=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return _(e,t)}function P(e){return function(e){if(Array.isArray(e))return y(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return y(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(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return y(e,t)}(e)||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.")}()}var I=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function x(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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){var n,r=v(e);if(t){var i=v(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return C(this,n)}}var E=/^!\[([^\]]*)\]\(asset:\/\/(\d+)\)/,w=j(O({},d.Z.rules),{heading:j(O({},d.Z.rules.heading),{react:function(e,t,n){var i="h".concat(Math.min(Math.max(2,e.level+1),4));return(0,r.jsx)(u.Z,{tag:i,children:t(e.content,n)},n.key)}}),assetImage:{order:5,match:function(e,t){var n=e.match(E);if(null!=n){
|
|
var r=n[2],i=t.assets.find((function(e){return e.id===r}));return null!=i&&P(n).concat([i,t.applicationId])}return!1},parse:function(e){return{asset:e[3],alt:e[1],applicationId:e[4]}},react:function(e,t,n){return(0,r.jsx)("div",{className:m().assetWrapper,children:(0,r.jsx)("img",{alt:e.alt,src:(0,f._W)(e.applicationId,e.asset,800),className:m().asset})},n.key)}}}),S=c().parserFor(w),N=c().reactFor(c().ruleOutput(w,"react"));const 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&&_(e,t)}(n,e);var t=x(n);function n(){g(this,n);var e;(e=t.apply(this,arguments)).state={collapsed:!0,collapsable:!0};e.handleToggleCollapse=function(){e.setState({collapsed:!e.state.collapsed})};e.setContentContainerRef=function(t){e._container=t};return e}var i=n.prototype;i.componentDidMount=function(){
|
|
if(null!=this._container){var e=this._container.getBoundingClientRect().height>400;this.setState({collapsable:e})}};i.render=function(){var e=this.props,t=e.applicationId,n=e.description,i=e.blurb,o=e.className,l=e.assets,c=this.state,u=c.collapsed,f=c.collapsable;return(0,r.jsxs)("div",{className:o,children:[(0,r.jsx)("div",{className:a()(b({},m().collapsed,f&&u)),children:(0,r.jsxs)("div",{ref:this.setContentContainerRef,children:[(0,r.jsx)("div",{className:m().blurb,children:i}),(0,r.jsx)(d.Z,{className:m().description,parser:S,output:N,state:{assets:l,applicationId:t},children:n})]})}),f?(0,r.jsx)(s.zxk,{className:m().toggleCollapseButton,onClick:this.handleToggleCollapse,color:s.zxk.Colors.PRIMARY,children:u?p.Z.Messages.APPLICATION_STORE_DESCRIPTION_READ_MORE:p.Z.Messages.APPLICATION_STORE_DESCRIPTION_READ_LESS}):null]})};return n}(i.PureComponent)},725778:(e,t,n)=>{"use strict";n.d(t,{Q:()=>C,Z:()=>P})
|
|
;var r=n(785893),i=n(667294),o=n(707961),a=n(851547),l=n(714898),c=n(146431),s=n(680625),u=n(2590),d=n(473708);function f(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function p(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function h(e){h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return h(e)}function m(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){p(e,t,n[t])}))}return e}function y(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function g(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!t||"object"!==O(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function v(e,t){v=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return v(e,t)}var O=function(e){
|
|
return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function j(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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){var n,r=h(e);if(t){var i=h(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return b(this,n)}}function C(e){return"".concat(e.split("?")[0],"?size=").concat(2048)}var _=function(e){var t=e.index,n=e.items,i=g(e,["index","items"]),o=n[t],a=0,c=[],s=!0,d=!1,f=void 0;try{for(var p,h=n[Symbol.iterator]();!(s=(p=h.next()).done);s=!0){var b=p.value;if(b.type===u.s9s.IMG){var v=b.width,O=b.height,j=b.src;b===o&&(a=c.length);c.push({src:C(j),width:v,height:O})}}}catch(e){d=!0;f=e}finally{try{s||null==h.return||h.return()}finally{if(d)throw f}}return(0,r.jsx)(l.Z,y(m({},i),{items:c,startWith:a
|
|
}))};const P=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&&v(e,t)}(n,e);var t=j(n);function n(){f(this,n);var e;(e=t.apply(this,arguments)).handleCurrentItemClick=function(t,n){t.type!==u.s9s.IMG||(0,o.$sL)()||(0,o.h7j)((function(t){return(0,r.jsx)(o.Y0X,y(m({size:o.CgR.DYNAMIC,"aria-label":d.Z.Messages.IMAGE},t),{children:(0,r.jsx)(_,y(m({},t),{index:n,items:e.props.items}))}))}))};return e}n.prototype.render=function(){var e=this.props,t=e.pageSize,n=g(e,["pageSize"]),i=t===s.b.SMALL?c.Z:a.Z;return(0,r.jsx)(i,y(m({},n),{onCurrentItemClick:this.handleCurrentItemClick}))};return n}(i.Component)},680625:(e,t,n)=>{"use strict";n.d(t,{x:()=>r,b:()=>i});var r=1e3,i=Object.freeze({SMALL:"small",LARGE:"large"})},146431:(e,t,n)=>{"use strict";n.d(t,{Z:()=>D})
|
|
;var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(707961),c=n(851547),s=n(918771),u=n(561329),d=n(802139),f=n(159689),p=n(586054),h=n(680625),m=n(2590),y=n(473708),g=n(831586),b=n.n(g);function v(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function O(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function j(e){j=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return j(e)}function C(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){O(e,t,n[t])}))}return e}function _(e,t){t=null!=t?t:{}
|
|
;Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function P(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 I(e,t){return!t||"object"!==E(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}
|
|
function x(e,t){x=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return x(e,t)}var E=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof 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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){var n,r=j(e);if(t){var i=j(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return I(this,n)}}var S=function(e){var t=e.className,n=P(e,["className"]);return(0,r.jsx)(p.Z,_(C({},n),{className:a()(b().sizedToParent,t),mediaPlayerClassName:b().sizedToParent,renderLinkComponent:s.iT}))},N=function(e){var t=e.containerClassName,n=e.className,i=P(e,["containerClassName","className"]);return(0,r.jsx)(f.Z,_(C({},i),{className:a()(n,t)}))},R={width:1280,height:720},A={width:640,
|
|
height:360},T=function(e){var t,n,i=e.item,o=e.onPlay,a=e.volume,l=e.onVolumeChange,u=e.onMute,f=e.isMuted,p=e.autoPlay;if(i.type===m.s9s.YOUTUBE_VIDEO){t=C({url:(0,m.n8r)(i.youtubeVideoId)},R);n=C({url:"".concat((0,m.ivE)(i.youtubeVideoId),"?").concat("rel=0&iv_load_policy=3&showinfo=0&modestbranding=1")},A)}else{var y=null!=i.width?i.width:0,g=null!=i.height?i.height:0;t={url:i.thumbnailSrc,width:y,height:g};n={url:i.src,proxyURL:i.src,width:y,height:g}}return(0,r.jsx)("div",{className:b().embedContainer,children:(0,r.jsx)(d.BC,{className:b().sizedToParent,iframeWrapperClassName:b().sizedToParent,href:null,thumbnail:t,video:n,maxHeight:c.r.SMALL.height,maxWidth:h.b.SMALL,onPlay:o,playable:!0,volume:a,onVolumeChange:l,autoMute:f,onMute:u,autoPlay:p,renderImageComponent:N,renderVideoComponent:S,renderLinkComponent:s.iT})})},L=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&&x(e,t)}(n,e);var t=w(n);function n(){v(this,n);var e;(e=t.apply(this,arguments)).state={hasInteracted:!1,isVideoPlaying:!1,isMuted:!0,volume:1,status:new Map,imageLoadingStartTime:new Map};e.handlePlay=function(t){e.setState({isVideoPlaying:!0,hasInteracted:!t})};e.handleVolumeChange=function(t){e.setState({volume:t,hasInteracted:!0})};e.handleMute=function(t){e.setState({isMuted:t,hasInteracted:!0})};e.handleChangeItem=function(t){e.setState({isVideoPlaying:!1});t.type===m.s9s.IMG&&e.setState({imageLoadingStartTime:new Map(e.state.imageLoadingStartTime).set(t.src,Date.now())})};e.handleIntentionalChange=function(t,n,r,i){e.setState({hasInteracted:!0});var o=e.props.onIntentionalChange;null!=o&&o(t,n,r,i)};e.handleOnErrorImg=function(t){e.setState({status:new Map(e.state.status).set(t.target.src,"errored")})};e.handleOnLoadImg=function(t){var n=e.props.onImageLoad;e.setState({
|
|
status:new Map(e.state.status).set(t.target.src,"loaded")});var r=e.state.imageLoadingStartTime.get(t.target.src),i=null!=r?Date.now()-r:void 0;null==n||n({src:t.target.src,loadTimeMs:i})};e.renderItem=function(t,n){var i,o=e.state,c=o.isMuted,s=o.volume,u=e.props.videoAutoPlay;switch(t.type){case m.s9s.YOUTUBE_VIDEO:case m.s9s.VIDEO:i=(0,r.jsx)(T,{item:t,onPlay:e.handlePlay,isMuted:c,volume:s,onVolumeChange:e.handleVolumeChange,onMute:e.handleMute,autoPlay:u});break;case m.s9s.IMG:if("errored"===e.state.status.get(t.src)){var d=(0,r.jsx)(l.X6q,{variant:"heading-xl/semibold",children:y.Z.Messages.ERRORS_IMAGE_NOT_FOUND});return(0,r.jsx)("div",{className:b().errorContainer,children:void 0!==e.props.errorComponent?e.props.errorComponent:d})}var f,p=null!==(f=t.alt)&&void 0!==f?f:y.Z.Messages.IMAGE;i=(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(l.$jN,{className:a()(b().spinner,O({},b().hidden,void 0!==e.state.status.get(t.src))),type:l.$jN.Type.SPINNING_CIRCLE}),(0,r.jsx)("img",{
|
|
onError:e.handleOnErrorImg,onLoad:e.handleOnLoadImg,className:a()(b().smallCarouselImage,O({},b().hidden,"loaded"!==e.state.status.get(t.src))),src:t.src,alt:p})]});break;default:throw new Error("Unexpected MediaType")}return(0,r.jsx)(l.P3F,{className:b().smallCarouselItem,onClick:function(){return e.handleCurrentItemClick(t,n)},children:i})};return e}var i=n.prototype;i.componentDidMount=function(){var e=this.props.items;e.length>0&&e[0].type===m.s9s.IMG&&this.setState({imageLoadingStartTime:new Map(this.state.imageLoadingStartTime).set(e[0].src,Date.now())})};i.handleCurrentItemClick=function(e,t){var n=this.props.onCurrentItemClick;null!=n&&n(e,t);this.setState({hasInteracted:!0})};i.render=function(){var e=this.props,t=e.items,n=e.autoplayInterval,i=e.className,o=e.paused,l=e.themedPagination,c=this.state.hasInteracted;return(0,r.jsx)(u.Z,{items:t.slice(0,12),delay:n,paused:o||c,renderItem:this.renderItem,className:a()(b().smallCarousel,i),themedPagination:l,
|
|
onIntentionalChange:this.handleIntentionalChange,onChangeItem:this.handleChangeItem})};return n}(i.PureComponent);L.defaultProps={paused:!1,videoAutoPlay:!0};const D=L},775461:(e,t,n)=>{"use strict";n.d(t,{lI:()=>c,hd:()=>s,XM:()=>u,py:()=>d,U3:()=>f});var r=n(707961),i=n(50433),o=n(930948),a=n(2590),l=function(){return i.Z.hasLayers()||(0,r.$sL)()},c={binds:["right"],comboKeysBindGlobal:!0,action:function(){if(!l()){o.S.dispatch(a.CkL.CAROUSEL_NEXT);return!1}}},s={binds:["left"],comboKeysBindGlobal:!0,action:function(){if(!l()){o.S.dispatch(a.CkL.CAROUSEL_PREV);return!1}}},u={binds:["right","down","space"],comboKeysBindGlobal:!0,action:function(){o.S.dispatch(a.CkL.MODAL_CAROUSEL_NEXT);return!1}},d={binds:["left","up"],comboKeysBindGlobal:!0,action:function(){o.S.dispatch(a.CkL.MODAL_CAROUSEL_PREV);return!1}},f={binds:["esc"],comboKeysBindGlobal:!0,action:function(){if(o.S.hasSubscribers(a.CkL.MODAL_CLOSE)){o.S.dispatch(a.CkL.MODAL_CLOSE);return!1}}}},106200:(e,t,n)=>{"use strict"
|
|
;n.d(t,{Z:()=>c});var r=n(798159),i=n(202351),o=n(316878);function a(){return Promise.resolve()}function l(e){var t=document.querySelector(e);null!=t&&t.focus()}function c(e,t){var n=(0,i.e7)([o.Z],(function(){return o.Z.keyboardModeEnabled}));return(0,r.ZP)({id:e,isEnabled:n,orientation:t,setFocus:l,scrollToStart:a,scrollToEnd:a})}},363287:(e,t,n)=>{"use strict";n.d(t,{K3:()=>o,sD:()=>l,Ck:()=>c,r:()=>s});var r=n(260561),i=n(61209),o=(0,r.B)({kind:"user",id:"2022-12_get_my_guilds_application_ids_endpoint",label:"Get My Guilds' Application IDs Endpoint Experiment",defaultConfig:{enabled:!1},treatments:[{id:1,label:"Enabled",config:{enabled:!0}}]}),a=(0,r.B)({kind:"guild",id:"2023-02_app_directory_for_all_guild",label:"App Directory Upsell For All Guild",defaultConfig:{enabled:!1},treatments:[{id:1,label:"Enabled",config:{enabled:!0}}]}),l=(0,r.B)({kind:"user",id:"2023-02_app_directory_for_all_modal",label:"App Directory Upsell For All Modal",defaultConfig:{enabled:!1},treatments:[{
|
|
id:1,label:"Enabled",config:{enabled:!0}}]});function c(e,t){return a.getCurrentConfig({guildId:e},{autoTrackExposure:t}).enabled}function s(e,t){if(void 0===e)return!1;var n=i.Z.getChannel(e);return null!=n&&null!=n.guild_id&&a.getCurrentConfig({guildId:n.guild_id},{autoTrackExposure:t}).enabled}},570272:(e,t,n)=>{"use strict";n.r(t);n.d(t,{default:()=>ra,openApplicationDirectoryModal:()=>ia});var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(496486),c=n.n(l),s=n(468811),u=n.n(s),d=n(289283),f=n(707961),p=n(72831),h=n(320142),m=n(422513),y=n(873308),g=n(633878);function b(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function v(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function O(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 j(e){var t=e.width,n=void 0===t?124:t,i=e.height,o=void 0===i?24:i,a=e.color,l=void 0===a?"currentColor":a,c=e.foreground,s=O(e,["width","height","color","foreground"]);return(0,r.jsx)("svg",v(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){
|
|
return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){b(e,t,n[t])}))}return e}({},(0,g.Z)(s)),{width:n,height:o,viewBox:"0 0 124 24",children:(0,r.jsxs)("g",{fill:l,className:c,children:[(0,r.jsx)("path",{
|
|
d:"M26.2421 2.00996C24.2367 1.07098 22.0925 0.388543 19.8509 0C19.5755 0.498132 19.2539 1.16812 19.0322 1.70112C16.6492 1.34247 14.2881 1.34247 11.949 1.70112C11.7273 1.16812 11.3983 0.498132 11.1206 0C8.87648 0.388543 6.72984 1.07347 4.72453 2.01494C0.679785 8.132 -0.41668 14.0971 0.131553 19.9776C2.81424 21.9826 5.41408 23.2005 7.97006 23.9975C8.60114 23.1283 9.16399 22.2042 9.64888 21.2304C8.72541 20.8792 7.84093 20.4458 7.00517 19.9427C7.2269 19.7783 7.44376 19.6065 7.65331 19.4296C12.7507 21.8157 18.289 21.8157 23.3255 19.4296C23.5374 19.6065 23.7543 19.7783 23.9736 19.9427C23.1354 20.4483 22.2485 20.8817 21.325 21.2329C21.8099 22.2042 22.3703 23.1308 23.0038 24C25.5622 23.203 28.1645 21.9851 30.8472 19.9776C31.4905 13.1606 29.7483 7.25031 26.2421 2.00996ZM10.3433 16.3611C8.81313 16.3611 7.55828 14.9315 7.55828 13.1905C7.55828 11.4496 8.78632 10.0174 10.3433 10.0174C11.9003 10.0174 13.1551 11.4471 13.1283 13.1905C13.1308 14.9315 11.9003 16.3611 10.3433 16.3611ZM20.6355 16.3611C19.1053 16.3611 17.8504 14.9315 17.8504 13.1905C17.8504 11.4496 19.0785 10.0174 20.6355 10.0174C22.1924 10.0174 23.4473 11.4471 23.4205 13.1905C23.4205 14.9315 22.1924 16.3611 20.6355 16.3611Z"
|
|
}),(0,r.jsx)("path",{d:"M41.6289 6.12256H48.2808C49.8841 6.12256 51.2388 6.3791 52.3499 6.88968C53.4586 7.40027 54.2894 8.1126 54.8401 9.02418C55.3908 9.93576 55.6685 10.9793 55.6685 12.1549C55.6685 13.3056 55.381 14.3492 54.806 15.2832C54.2309 16.2197 53.3562 16.9594 52.1793 17.5049C51.0025 18.0503 49.5454 18.3243 47.8032 18.3243H41.6289V6.12256ZM47.735 15.2234C48.8144 15.2234 49.6453 14.947 50.2252 14.3965C50.8051 13.8436 51.0951 13.0914 51.0951 12.1375C51.0951 11.2533 50.8368 10.5485 50.3202 10.0204C49.8037 9.49242 49.0215 9.22592 47.9762 9.22592H45.8954V15.2234H47.735Z"}),(0,r.jsx)("path",{
|
|
d:"M65.6272 18.3094C64.7061 18.0654 63.8752 17.7117 63.137 17.2459V14.3518C63.6949 14.7926 64.443 15.1563 65.3811 15.4427C66.3191 15.7266 67.2256 15.8686 68.1027 15.8686C68.5121 15.8686 68.8215 15.8138 69.0311 15.7042C69.2406 15.5946 69.3454 15.4626 69.3454 15.3107C69.3454 15.1363 69.2894 14.9919 69.1748 14.8748C69.0603 14.7578 68.8386 14.6606 68.5096 14.5784L66.4629 14.1077C65.2909 13.8287 64.46 13.4427 63.9654 12.947C63.4708 12.4539 63.2247 11.8063 63.2247 11.0043C63.2247 10.3294 63.4391 9.74406 63.8728 9.24343C64.3041 8.74281 64.9181 8.35676 65.7149 8.08528C66.5116 7.8113 67.4424 7.67432 68.5121 7.67432C69.4672 7.67432 70.342 7.77892 71.1387 7.98814C71.9355 8.19736 72.5934 8.46386 73.1172 8.79013V11.5274C72.5812 11.2011 71.9672 10.9446 71.2654 10.7503C70.5661 10.5585 69.8473 10.4639 69.1066 10.4639C68.0369 10.4639 67.5033 10.6507 67.5033 11.0218C67.5033 11.1961 67.5862 11.3256 67.7519 11.4128C67.9176 11.5 68.2221 11.5896 68.6631 11.6843L70.3688 11.9981C71.4823 12.1949 72.3132 12.5411 72.859 13.0342C73.4047 13.5274 73.6777 14.2571 73.6777 15.2235C73.6777 16.282 73.2269 17.1214 72.3229 17.7441C71.4189 18.3667 70.1373 18.6781 68.4755 18.6781C67.4985 18.6756 66.5482 18.5535 65.6272 18.3094Z"
|
|
}),(0,r.jsx)("path",{d:"M77.703 17.9432C76.726 17.455 75.9877 16.7925 75.4955 15.9557C75.0033 15.1188 74.7548 14.1773 74.7548 13.1312C74.7548 12.0852 75.0106 11.1487 75.5223 10.3243C76.034 9.49986 76.7844 8.85229 77.7737 8.38155C78.763 7.91082 79.9447 7.6767 81.3214 7.6767C83.027 7.6767 84.4426 8.04282 85.5683 8.77508V11.9656C85.1712 11.6867 84.7082 11.46 84.1795 11.2857C83.6508 11.1113 83.0855 11.0241 82.4812 11.0241C81.4237 11.0241 80.5977 11.2209 80.0007 11.6169C79.4038 12.0129 79.1041 12.5285 79.1041 13.1686C79.1041 13.7962 79.394 14.3093 79.9739 14.7128C80.5538 15.1138 81.3945 15.3156 82.4982 15.3156C83.066 15.3156 83.6264 15.2309 84.1795 15.064C84.7302 14.8946 85.2053 14.6879 85.6025 14.4438V17.5297C84.3525 18.2969 82.9027 18.6804 81.2531 18.6804C79.8643 18.6755 78.6801 18.4314 77.703 17.9432Z"}),(0,r.jsx)("path",{
|
|
d:"M89.8227 17.9433C88.8383 17.4551 88.0878 16.7876 87.5713 15.9383C87.0547 15.089 86.794 14.1425 86.794 13.0965C86.794 12.0504 87.0523 11.1164 87.5713 10.297C88.0903 9.47754 88.8359 8.83495 89.8154 8.3692C90.7925 7.90345 91.9596 7.67181 93.3119 7.67181C94.6642 7.67181 95.8313 7.90345 96.8084 8.3692C97.7855 8.83495 98.5311 9.47256 99.0428 10.287C99.5544 11.1015 99.8103 12.0354 99.8103 13.094C99.8103 14.1401 99.5544 15.0865 99.0428 15.9358C98.5311 16.7851 97.783 17.4526 96.7987 17.9408C95.8143 18.429 94.652 18.6731 93.3095 18.6731C91.9669 18.6731 90.8046 18.4315 89.8227 17.9433ZM95.0053 14.8499C95.4195 14.4265 95.6291 13.8661 95.6291 13.1687C95.6291 12.4713 95.422 11.9159 95.0053 11.5049C94.5911 11.0915 94.0258 10.8848 93.3095 10.8848C92.5809 10.8848 92.0108 11.0915 91.5941 11.5049C91.1799 11.9184 90.9728 12.4713 90.9728 13.1687C90.9728 13.8661 91.1799 14.4265 91.5941 14.8499C92.0083 15.2733 92.5809 15.4875 93.3095 15.4875C94.0258 15.485 94.5911 15.2733 95.0053 14.8499Z"}),(0,
|
|
r.jsx)("path",{d:"M110.059 8.31931V12.0852C109.625 11.7938 109.065 11.6493 108.37 11.6493C107.461 11.6493 106.76 11.9308 106.272 12.4937C105.782 13.0565 105.539 13.9333 105.539 15.1188V18.3268H101.36V8.12753H105.454V11.3704C105.68 10.1848 106.048 9.31059 106.555 8.74521C107.059 8.18232 107.712 7.90088 108.507 7.90088C109.108 7.90088 109.625 8.04036 110.059 8.31931Z"}),(0,r.jsx)("path",{
|
|
d:"M123.942 5.77393V18.3268H119.763V16.0429C119.41 16.9022 118.874 17.5572 118.153 18.0056C117.432 18.4514 116.54 18.6755 115.482 18.6755C114.537 18.6755 113.713 18.4414 113.009 17.9707C112.305 17.5 111.762 16.8549 111.379 16.0354C110.999 15.216 110.806 14.2895 110.806 13.2534C110.794 12.1849 110.997 11.226 111.413 10.3767C111.827 9.52735 112.415 8.86483 113.17 8.38912C113.925 7.9134 114.788 7.6743 115.755 7.6743C117.746 7.6743 119.081 8.55848 119.763 10.3244V5.77393H123.942ZM119.14 14.7802C119.566 14.3567 119.778 13.8063 119.778 13.1338C119.778 12.4838 119.571 11.9533 119.157 11.5473C118.742 11.1413 118.175 10.9371 117.461 10.9371C116.757 10.9371 116.194 11.1438 115.772 11.5572C115.351 11.9707 115.141 12.5062 115.141 13.1687C115.141 13.8312 115.351 14.3717 115.772 14.7901C116.194 15.2085 116.749 15.4178 117.444 15.4178C118.148 15.4153 118.713 15.2036 119.14 14.7802Z"}),(0,r.jsx)("path",{
|
|
d:"M59.1896 9.21341C60.3401 9.21341 61.2728 8.35701 61.2728 7.30058C61.2728 6.24416 60.3401 5.38776 59.1896 5.38776C58.039 5.38776 57.1063 6.24416 57.1063 7.30058C57.1063 8.35701 58.039 9.21341 59.1896 9.21341Z"}),(0,r.jsx)("path",{d:"M57.1044 10.531C58.3811 11.0939 59.9649 11.1188 61.2709 10.531V18.3816H57.1044V10.531Z"})]})}))}var C=n(585798),_=n(652591),P=n(930948),I=n(348592),x=n(363287),E=n(874049),w=n(247729);function S(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function N(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}
|
|
function R(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 A(e){var t=e.width,n=void 0===t?24:t,i=e.height,o=void 0===i?24:i,a=e.color,l=void 0===a?"currentColor":a,c=e.className,s=e.foreground,u=R(e,["width","height","color","className","foreground"]);return(0,r.jsx)("svg",N(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){S(e,t,n[t])}))}return e}({},(0,g.Z)(u)),{className:c,width:n,height:o,viewBox:"0 0 24 24",
|
|
children:(0,r.jsx)("path",{className:s,fill:l,d:"M11.992 2c.945 0 1.739.784 1.739 1.716v5.336l4.688-2.686c.794-.448 1.89-.187 2.344.634.492.82.19 1.866-.643 2.313L15.47 12l4.65 2.65c.832.484 1.135 1.53.643 2.35-.453.82-1.55 1.082-2.344.634l-4.688-2.686v5.336c0 .932-.794 1.716-1.74 1.716-.945 0-1.739-.784-1.739-1.716v-5.336l-4.65 2.686c-.832.448-1.89.187-2.382-.634a1.74 1.74 0 0 1 .643-2.35L8.55 12 3.863 9.313C3.03 8.866 2.766 7.821 3.22 7c.491-.82 1.55-1.082 2.382-.634l4.65 2.686V3.716c0-.932.794-1.716 1.74-1.716Z"})}))}var T=n(491275);function L(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function D(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function M(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 k(e){var t=e.width,n=void 0===t?24:t,i=e.height,o=void 0===i?24:i,a=e.color,l=void 0===a?"currentColor":a,c=e.className,s=e.foreground,u=M(e,["width","height","color","className","foreground"]);return(0,r.jsx)("svg",D(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))))
|
|
;r.forEach((function(t){L(e,t,n[t])}))}return e}({},(0,g.Z)(u)),{className:c,width:n,height:o,viewBox:"0 0 24 24",children:(0,r.jsx)("path",{className:s,fill:l,d:"M6 22H2v-4h4v4Zm8-7h-4v7h4v-7Zm8-3h-4v10h4V12ZM16 2v2h2.59L14 8.59l-5-5-6.71 6.7 1.42 1.42L9 6.41l5 5 6-6V8h2V2h-6Z"})}))}var Z=n(755284),G=n(707073);function Y(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function F(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function H(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 U(e){var t=e.width,n=void 0===t?24:t,i=e.height,o=void 0===i?24:i,a=e.color,l=void 0===a?"currentColor":a,c=e.foreground,s=H(e,["width","height","color","foreground"]);return(0,r.jsx)("svg",F(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){Y(e,t,n[t])}))}return e}({},(0,g.Z)(s)),{width:n,height:o,viewBox:"0 0 14 20",children:(0,r.jsx)("path",{className:c,fill:l,fillRule:"evenodd",
|
|
d:"M14 6.318C14 3.527 12.363 1.125 10 0.00100017V5.318C10 6.975 8.657 8.318 7 8.318C5.343 8.318 4 6.975 4 5.318V0C1.637 1.125 0 3.526 0 6.318C0 8.696 1.188 10.793 3 12.058V19.318H6V14.318H8V19.318H11V12.058C12.812 10.793 14 8.696 14 6.318Z"})}))}var V=n(775173),B=n(2590),z=n(473708),W=n(460429),K=n.n(W),q=window.GLOBAL_ENV,X=q.API_ENDPOINT,$=q.CDN_HOST;function Q(){return{id:0,name:z.Z.Messages.APP_DIRECTORY_ALL_CATEGORY}}function J(e){switch(e.id){case 0:return Z.Z;case 4:return G.Z;case 5:return k;case 6:return w.Z;case 8:return A;case 9:return T.Z;case 10:return U}return A}function ee(e){return c().sortBy(e,["position","id"])}function te(e){return c().sortBy(e,["position","id"])}function ne(e){var t=e.itemId,n=e.hash,r=(0,E.oO)(parseFloat(K().contentMaxWidth)*(0,E.x_)()).toString(),i=new URLSearchParams({size:r}).toString(),o=V.$k?"webp":"png"
|
|
;return null!=$?"".concat(location.protocol,"//").concat($,"/app-assets/application-directory/collection-items/").concat(t,"/").concat(n,".").concat(o,"?").concat(i):"".concat(location.protocol).concat(X).concat(B.ANM.APPLICATION_DIRECTORY_COLLECTION_ITEM_IMAGE(t,n,o),"?").concat(i)}var re=n(281110),ie=n(744564),oe=n(202351);function ae(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function le(e){le=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return le(e)}function ce(e,t){return!t||"object"!==de(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function se(e,t){se=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return se(e,t)}var ue,de=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function fe(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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){var n,r=le(e);if(t){var i=le(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ce(this,n)}}!function(e){e[e.NOT_FETCHED=0]="NOT_FETCHED";e[e.FETCHING=1]="FETCHING";e[e.FETCHED=2]="FETCHED";e[e.ERROR=3]="ERROR"}(ue||(ue={}));var pe={applicationIdToGuildIds:{},lastFetchTimeMs:null,nextFetchRetryTimeMs:null,fetchState:ue.NOT_FETCHED};function he(e){var t=e.applicationId,n=e.guildId;null==pe.applicationIdToGuildIds[t]&&(pe.applicationIdToGuildIds[t]=new Set);pe.applicationIdToGuildIds[t].add(n);pe.applicationIdToGuildIds[t]=new Set(pe.applicationIdToGuildIds[t])}var me=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&&se(e,t)}(n,e);var t=fe(n);function n(){ae(this,n);return t.apply(this,arguments)}var r=n.prototype;r.initialize=function(e){if(null!=e){pe.lastFetchTimeMs=e.lastFetchTimeMs;pe.nextFetchRetryTimeMs=e.nextFetchRetryTimeMs;pe.fetchState=e.fetchState;for(var t in e.applicationIdToGuildIds)pe.applicationIdToGuildIds[t]=new Set(e.applicationIdToGuildIds[t])}};r.getState=function(){return pe};r.getGuildIdsForApplication=function(e){if(null!=e)return pe.applicationIdToGuildIds[e]};r.getLastFetchTimeMs=function(){return pe.lastFetchTimeMs};r.getNextFetchRetryTimeMs=function(){return pe.nextFetchRetryTimeMs};r.getFetchState=function(){return pe.fetchState};r.__getLocalVars=function(){return{state:pe}};return n}(oe.ZP.PersistedStore);me.displayName="MyGuildApplicationsStore"
|
|
;me.persistKey="MyGuildApplicationsStore";const ye=new me(ie.Z,{LOGOUT:function(){pe.applicationIdToGuildIds={};pe.lastFetchTimeMs=null;pe.nextFetchRetryTimeMs=null;pe.fetchState=ue.NOT_FETCHED},FETCH_INTEGRATION_APPLICATION_IDS_FOR_MY_GUILDS:function(){pe.fetchState=ue.FETCHING},FETCH_INTEGRATION_APPLICATION_IDS_FOR_MY_GUILDS_SUCCESS:function(e){var t=e.guildIdToApplicationIds;pe.fetchState=ue.FETCHED;pe.lastFetchTimeMs=Date.now();pe.applicationIdToGuildIds={};pe.nextFetchRetryTimeMs=null;for(var n in t){var r=!0,i=!1,o=void 0;try{for(var a,l=t[n][Symbol.iterator]();!(r=(a=l.next()).done);r=!0){he({applicationId:a.value,guildId:n})}}catch(e){i=!0;o=e}finally{try{r||null==l.return||l.return()}finally{if(i)throw o}}}},FETCH_INTEGRATION_APPLICATION_IDS_FOR_MY_GUILDS_FAILURE:function(e){var t=e.retryAfterSeconds;pe.fetchState=ue.ERROR;if(null!=t){var n=1e3*t;pe.nextFetchRetryTimeMs=Date.now()+n}},INTEGRATION_CREATE:function(e){var t=e.application,n=e.guildId;he({applicationId:t.id,
|
|
guildId:n})},INTEGRATION_DELETE:function(e){!function(e){var t=e.applicationId,n=e.guildId;if(null!=pe.applicationIdToGuildIds[t]){pe.applicationIdToGuildIds[t].delete(n);pe.applicationIdToGuildIds[t]=new Set(pe.applicationIdToGuildIds[t])}}({applicationId:e.applicationId,guildId:e.guildId})}});function ge(e,t,n,r,i,o,a){try{var l=e[o](a),c=l.value}catch(e){n(e);return}l.done?t(c):Promise.resolve(c).then(r,i)}function be(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function a(e){ge(o,r,i,a,l,"next",e)}function l(e){ge(o,r,i,a,l,"throw",e)}a(void 0)}))}}var ve=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:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){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;(r=0,i)&&(o=[2&o[0],i.value]);switch(o[0]){case 0:case 1:i=o;break;case 4:a.label++;return{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,l])}}},Oe=864e5;function je(e){return re.Z.get({url:B.ANM.APPLICATION_DIRECTORY_APPLICATION(e)}).then((function(e){return e.body}))}function Ce(e,t,n){var r=null!=n?n:{},i=r.page,o=r.categoryId;return re.Z.get({url:B.ANM.APPLICATION_DIRECTORY_SEARCH,query:{query:e,guild_id:t,page:i,category_id:o}
|
|
}).then((function(e){return{results:e.body.results,countsByCategory:e.body.counts_by_category,totalCount:e.body.result_count,totalPages:e.body.num_pages,type:e.body.type,loadId:e.body.load_id}}))}function _e(e,t,n){var r=(null!=n?n:{}).page;return re.Z.get({url:B.ANM.APPLICATION_DIRECTORY_SIMILAR(e),query:{guild_id:t,page:r}}).then((function(e){return{applications:e.body.applications,totalPages:e.body.num_pages,loadId:e.body.load_id}}))}function Pe(){return re.Z.get({url:B.ANM.APPLICATION_DIRECTORY_CATEGORIES}).then((function(e){return e.body}))}function Ie(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).includesInactive;return re.Z.get({url:B.ANM.APPLICATION_DIRECTORY_COLLECTIONS,query:{includes_inactive:e}}).then((function(e){return e.body}))}function xe(){return(xe=be((function(){var e,t,n,r,i,o,a,l;return ve(this,(function(c){switch(c.label){case 0:e=Date.now();t=ye.getFetchState();n=ye.getLastFetchTimeMs();r=ye.getNextFetchRetryTimeMs()
|
|
;if(t===ue.FETCHING)return[2];if(null!=n&&n+Oe>e)return[2];if(null!=r&&e<r)return[2];ie.Z.dispatch({type:"FETCH_INTEGRATION_APPLICATION_IDS_FOR_MY_GUILDS"});c.label=1;case 1:c.trys.push([1,3,,4]);return[4,re.Z.get({url:B.ANM.INTEGRATION_APPLICATION_IDS_FOR_MY_GUILDS})];case 2:i=c.sent();ie.Z.dispatch({type:"FETCH_INTEGRATION_APPLICATION_IDS_FOR_MY_GUILDS_SUCCESS",guildIdToApplicationIds:i.body});return[3,4];case 3:o=c.sent();l=429===(null==o?void 0:o.status);ie.Z.dispatch({type:"FETCH_INTEGRATION_APPLICATION_IDS_FOR_MY_GUILDS_FAILURE",retryAfterSeconds:l?null==o||null===(a=o.body)||void 0===a?void 0:a.retry_after:void 0});return[3,4];case 4:return[2]}}))}))).apply(this,arguments)}function Ee(e){return null==e?void 0:e[e.length-2]}function we(e){return null==e?void 0:e[e.length-1]}const Se=i.createContext([]);var Ne=n(166166),Re=n.n(Ne);function Ae(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 Te(e){return function(e){
|
|
if(Array.isArray(e))return Ae(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Ae(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(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ae(e,t)}(e)||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.")}()}function Le(e){var t=e.categories,n=e.guildId,o=e.className,l=e.onView,c=i.useContext(Se),s=i.useMemo((function(){return[Q()].concat(Te(t))}),[t]);return(0,r.jsx)("nav",{className:a()(Re().container,o),children:s.map((function(e){var t=e.id,i=e.name,o=J(e);return(0,r.jsxs)(f.P3F,{className:Re().category,
|
|
"aria-label":z.Z.Messages.APP_DIRECTORY_CATEGORY_BUTTON_A11Y_LABEL.format({categoryName:i}),onClick:function(){return function(e){var t,r=s.find((function(t){return t.id===e}));_.default.track(B.rMx.APP_DIRECTORY_CATEGORY_CLICKED,{category:r.name,category_id:r.id,current_page:null===(t=we(c))||void 0===t?void 0:t.type,guild_id:n});l(r)}(t)},children:[(0,r.jsx)(o,{className:Re().icon,width:"24",height:"24"}),(0,r.jsx)(f.xvT,{variant:"text-md/normal",children:i})]},t)}))})}var De=n(250539),Me=n(118044),ke=n(927798),Ze=n.n(ke),Ge=n(852617),Ye=n.n(Ge);function Fe(e){var t=e.heading,n=void 0===t?z.Z.Messages.APP_DIRECTORY_ERROR_HEADING:t,o=e.body,l=void 0===o?z.Z.Messages.APP_DIRECTORY_ERROR_BODY:o,c=e.className;return(0,r.jsxs)("div",{className:a()(Ze().container,c),children:[(0,r.jsx)("img",{className:Ze().image,src:Ye(),alt:z.Z.Messages.APP_DIRECTORY_CONFUSED_CLYDE_IMAGE_ALT}),(0,r.jsxs)(i.Fragment,{children:[(0,r.jsx)(f.X6q,{className:Ze().header,variant:"heading-xl/semibold",children:n
|
|
}),(0,r.jsx)(f.xvT,{variant:"text-md/normal",children:l})]})]})}var He=n(119906),Ue=n.n(He);function Ve(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function Be(e){var t=e.loading,n=e.children;return(0,r.jsxs)("div",{className:Ue().container,children:[t?(0,r.jsx)("div",{className:Ue().spinnerContainer,children:(0,r.jsx)(f.$jN,{className:Ue().spinner,type:f.$jN.Type.SPINNING_CIRCLE})}):null,(0,r.jsx)("div",{className:a()(Ve({},Ue().loading,t)),children:n})]})}var ze=n(532832),We=n(561329),Ke=n(87931),qe=n(531441),Xe=n(954010),$e=n.n(Xe);function Qe(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function Je(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function et(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 tt(e){var t=e.className,n=et(e,["className"]);return(0,r.jsx)(qe.IG,Je(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){Qe(e,t,n[t])}))}return e}({},n),{
|
|
text:z.Z.Messages.APP_DIRECTORY_PARTNER,color:Ke.Z.BACKGROUND_TERTIARY,className:a()(t,$e().partnerBadge)}))}var nt=n(428034),rt=n.n(nt);function it(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 ot(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function at(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done);a=!0){o.push(r.value);if(t&&o.length===t)break}}catch(e){l=!0;i=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}return o}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return it(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(n)
|
|
;if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return it(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 lt(e){var t=e.collectionTitle,n=e.title,i=e.description,o=e.handleClick,l=e.imageSrc,c=e.ctaLabel,s=e.ctaLink,u="936929561302675456"===e.applicationId;return(0,r.jsxs)("div",{className:rt().card,children:[(0,r.jsx)("div",{className:rt().textContainer,children:(0,r.jsxs)("div",{className:rt().verticallyCenter,children:[(0,r.jsx)(f.xvT,{className:rt().collectionTitle,tag:"span",color:"header-secondary",variant:"heading-deprecated-12/semibold",children:t}),(0,r.jsxs)(f.X6q,{className:rt().applicationName,variant:"heading-xxl/medium",children:[n," ",u&&(0,r.jsx)(tt,{})]}),(0,r.jsx)(f.xvT,{className:rt().applicationDescription,variant:"text-md/normal",lineClamp:3,children:i}),null==s?(0,r.jsx)(f.zxk,{
|
|
className:rt().applicationCta,onClick:o,children:c}):(0,r.jsx)(f.eee,{onClick:o,href:s,className:a()((0,f.nYM)({grow:!1}),rt().applicationCta),children:c})]})}),(0,r.jsx)("div",{className:rt().imageContainer,children:(0,r.jsx)("img",{alt:n,className:rt().image,src:l})})]})}function ct(e){var t=e.collection,n=t.id,o=t.title,l=t.application_directory_collection_items,c=e.guildId,s=e.onClickApplication,u=i.useRef(null),d=at(i.useState(),2),f=d[0],p=d[1];i.useEffect((function(){var e=null==u?void 0:u.current;if(null!=e){var t=new ResizeObserver((function(){var t=document.body.offsetWidth<parseFloat(rt().mediaBreakpoint)?parseFloat(rt().columnCardHeight):parseFloat(rt().rowCardHeight);p(e.offsetWidth/t)}));t.observe(document.body);return function(){t.disconnect()}}}),[]);return(0,r.jsx)("article",{ref:u,className:a()(ot({},rt().collectionBottomMargin,l.length<=1)),children:(0,r.jsx)(We.Z,{aspectRatio:f,themedPagination:!0,paginationClassName:rt().paginationControls,
|
|
paginationArrowClassName:rt().paginationArrow,items:l,onChangeItem:function(e,t,r){var i=e.application;null!=i&&_.default.track(B.rMx.APP_DIRECTORY_COLLECTION_SCROLLED,{collection_id:n,offset:r,results:[i.id],guild_id:c})},renderItem:function(e){var t=e.id,i=e.image_hash,a=e.application,l=e.type,u=e.description,d=e.title,f=e.call_to_action_label,p=e.call_to_action_url;if(null!=i){var h=ne({itemId:t,hash:i});if(l===ze.C.APPLICATION&&null!=a){var m,y;return(0,r.jsx)(lt,{collectionTitle:o,title:a.name,description:null!==(y=null===(m=a.directory_entry)||void 0===m?void 0:m.short_description)&&void 0!==y?y:a.description,handleClick:function(){_.default.track(B.rMx.APP_DIRECTORY_COLLECTION_ITEM_CLICKED,{collection_id:n,application_id:a.id,guild_id:c,shown_mutual_guilds_count:void 0});s(a)},imageSrc:h,ctaLabel:z.Z.Messages.APP_DIRECTORY_GALLERY_COLLECTION_VIEW_APP_CTA,applicationId:a.id})}if(l===ze.C.LINK&&null!=d&&null!=p&&null!=f){return(0,r.jsx)(lt,{collectionTitle:o,title:d,description:u,
|
|
handleClick:function(){_.default.track(B.rMx.APP_DIRECTORY_COLLECTION_ITEM_CLICKED,{collection_id:n,link:p,guild_id:c,shown_mutual_guilds_count:void 0})},imageSrc:h,ctaLabel:f,ctaLink:p})}}}})})}var st=n(443812),ut=n(787215),dt=n(100293),ft=n.n(dt);function pt(e,t){return void 0===e?ft():null!==(n=V.ZP.getApplicationIconURL({id:e.id,icon:e.icon,size:t}))&&void 0!==n?n:ft();var n}function ht(e,t){return{canInstall:i.useMemo((function(){return null!=e&&(0,ut.E)(e.id,e.custom_install_url,e.install_params)}),[e]),install:i.useCallback((function(n){null!=e&&(0,ut.L)(e.id,e.custom_install_url,e.install_params,t,n)}),[e,t])}}var mt,yt,gt=n(794547),bt=n(211482),vt=n(421281),Ot=n(788103),jt=n.n(Ot);function Ct(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function _t(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n)
|
|
;"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){Ct(e,t,n[t])}))}return e}function Pt(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}!function(e){e[e.SMALL=(0,vt.Mg)(jt().smallIconSize)]="SMALL";e[e.LARGE=(0,vt.Mg)(jt().largeIconSize)]="LARGE"}(mt||(mt={}));var It,xt=(Ct(yt={},mt.SMALL,jt().moreGuildsSmall),Ct(yt,mt.LARGE,jt().moreGuildsLarge),yt),Et=(Ct(It={},mt.SMALL,jt().iconSmall),Ct(It,mt.LARGE,jt().iconLarge),It);function wt(e){
|
|
var t,n,o,l=e.application,c=e.mutualGuilds,s=e.mutualGuildShownMax,u=void 0===s?4:s,d=e.className,p=e.textVariant,h=void 0===p?"text-sm/normal":p,m=e.compact,y=e.guildIconSize,g=void 0===y?mt.LARGE:y,b=new Intl.ListFormat("en-US"),v=null!==(n=null===(t=l.directory_entry)||void 0===t?void 0:t.guild_count)&&void 0!==n?n:0,O=null!==(o=null==c?void 0:c.length)&&void 0!==o?o:0,j=Math.max(0,v-O),C=i.useMemo((function(){var e=[],t=[];null==c||c.forEach((function(n){e.length<u&&null!=n.icon?e.push(n):t.push(n)}));if(e.length===u&&t.length>0){t.push(e[u-1]);e=e.slice(0,u-1)}return{shownMutualGuilds:e,hiddenMutualGuilds:t}}),[c,u]),_=C.shownMutualGuilds,P=C.hiddenMutualGuilds,I=P.length,x=function(e,t,n,r){if(0===t&&0===e)return null;if(t>0&&0===n)return z.Z.Messages.APP_DIRECTORY_MUTUAL_GUILD_COUNT.format({mutualGuildCount:t});var i=t>0?z.Z.Messages.APP_DIRECTORY_GUILD_COUNT_WITH_MUTUALS:z.Z.Messages.APP_DIRECTORY_GUILD_COUNT,o=new Intl.NumberFormat("en-US",{notation:r?"compact":"standard",
|
|
compactDisplay:"short"});return i.format({guildCount:o.format(e),mutualGuildCount:t,nonMutualGuildCount:o.format(n)})}(v,O,j,m);return 0===_.length&&null==x?null:(0,r.jsxs)("div",{className:a()(d,jt().wrapper),children:[(0,r.jsx)("div",{className:jt().icons,children:_.length>0?(0,r.jsxs)(r.Fragment,{children:[_.map((function(e,t){var n=t===_.length-1&&0===I,o=V.ZP.getGuildIconURL({id:e.id,icon:e.icon,size:g,canAnimate:!1}),l=(0,r.jsx)(f.ua7,{text:e.name,position:"top",children:function(e){return(0,r.jsx)("img",Pt(_t({},e),{className:a()(jt().icon,Et[g]),src:o,alt:""}))}});return n?(0,r.jsx)(i.Fragment,{children:l},e.id):(0,r.jsx)(bt.ZP,{className:jt().iconMask,height:g,width:g,mask:bt.ZP.Masks.VOICE_USER_SUMMARY_ITEM,children:l},e.id)})),I>0?(0,r.jsx)(f.ua7,{text:z.Z.Messages.APP_DIRECTORY_GUILD_COUNT_PLUS_MUTUALS_TOOLTIP.format({appNames:b.format(P.map((function(e){return e.name})))}),position:"top",children:function(e){return(0,r.jsxs)("div",Pt(_t({},e),{
|
|
className:a()(jt().moreGuilds,xt[g]),children:["+",I]}))}}):null]}):(0,r.jsx)(gt.Z,{width:g,height:g,className:jt().defaultIcon})}),null!=x?(0,r.jsx)(f.xvT,{variant:h,color:"header-secondary",children:x}):null]})}var St=n(881080),Nt=n.n(St);function Rt(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function At(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function Tt(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 Lt(e){var t=e.className,n=e.onClick,i=e.imageSrc,o=e.iconSrc,l=e.header,c=e.headerClassName,s=e.subheaderVariant,u=void 0===s?"text-sm/normal":s,d=e.subheader,p=e.children,h=e.animatesOnHover,m=Tt(e,["className","onClick","imageSrc","iconSrc","header","headerClassName","subheaderVariant","subheader","children","animatesOnHover"]),y=null!=i,g=(0,r.jsxs)(r.Fragment,{children:[y&&(0,r.jsx)("div",{className:Nt().imageContainer,children:(0,r.jsx)("img",{alt:"",className:Nt().image,src:i})}),(0,r.jsxs)("div",{className:Nt().textContainer,children:[(0,r.jsxs)("div",{className:a()(Nt().topRowContainer),children:[null!=o&&(0,r.jsx)("img",{className:Nt().icon,alt:"","aria-hidden":!0,src:o,width:48,height:48}),(0,r.jsxs)("div",{className:Nt().headerContainer,children:[(0,r.jsx)(f.X6q,{
|
|
variant:"heading-md/medium",className:c,children:l}),null!=d&&(0,r.jsx)(f.xvT,{className:Nt().subheader,color:"header-secondary",variant:u,children:d})]})]}),p]})]}),b=a()(t,Nt().container,Rt({},Nt().hasImage,y));return null!=n?(0,r.jsx)(f.kL8,{tag:"article","aria-label":z.Z.Messages.APP_DIRECTORY_LISTING_CARD_BUTTON_A11Y_LABEL.format({name:l}),onClick:n,className:a()(b,Nt().clickable,Rt({},Nt().animatesOnHoverContainer,h)),focusProps:{offset:4},children:g}):(0,r.jsx)("article",At(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){Rt(e,t,n[t])}))}return e}({className:b},m),{children:g}))}var Dt=n(567403);function Mt(e){var t=e.application,n=e.showMutualGuilds,r=void 0===n||n,o=(0,oe.e7)([ye],(function(){
|
|
return ye.getGuildIdsForApplication(null==t?void 0:t.id)}),[t]);return i.useMemo((function(){var e=[];if(!r||null==o||null==t)return e;var n=!0,i=!1,a=void 0;try{for(var l,c=o[Symbol.iterator]();!(n=(l=c.next()).done);n=!0){var s=l.value,u=Dt.Z.getGuild(s);null!=u&&e.push(u)}}catch(e){i=!0;a=e}finally{try{n||null==c.return||c.return()}finally{if(i)throw a}}return e}),[o,t,r])}var kt=n(425770),Zt=n.n(kt);function Gt(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function Yt(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}
|
|
function Ft(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 Ht(e){var t,n,o,a,l,c=e.application,s=e.className,u=e.childrenClassName,d=e.animatesOnHover,p=e.onClick,h=Ft(e,["application","className","childrenClassName","animatesOnHover","onClick"]),m=pt(c,48),y=Mt({application:c}),g=null===(t=c.categories)||void 0===t?void 0:t[0],b=(null!==(a=null===(n=c.directory_entry)||void 0===n?void 0:n.guild_count)&&void 0!==a?a:0)>0||y.length>0,v=i.useCallback((function(){p({mutualGuilds:y})}),[p,y]),O=(0,r.jsx)(wt,{application:c,textVariant:"text-xs/normal",mutualGuilds:y,mutualGuildShownMax:3,guildIconSize:mt.SMALL,compact:!0});return(0,r.jsxs)(Lt,Yt(function(e){
|
|
for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){Gt(e,t,n[t])}))}return e}({className:s,onClick:v,iconSrc:m,header:c.name,subheader:null!=g&&(0,r.jsx)(f.xvT,{tag:"span",color:"header-secondary",variant:"text-xs/normal",children:g.name}),animatesOnHover:d},h),{children:[(null!=c.description||null!=u)&&(0,r.jsx)("div",{className:u,children:(0,r.jsx)(f.xvT,{className:Zt().listingDescription,variant:"text-sm/normal",lineClamp:2,children:null!==(l=null===(o=c.directory_entry)||void 0===o?void 0:o.short_description)&&void 0!==l?l:c.description})}),b&&(0,r.jsx)("div",{className:Zt().bottomGuildCountContainer,children:O})]}))}var Ut=n(973935),Vt=n(809784),Bt=n(672380),zt=n(677483),Wt=n(22119),Kt=n.n(Wt);function qt(e,t){
|
|
if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Xt(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function $t(e){$t=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return $t(e)}function Qt(e,t){return!t||"object"!==tn(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Jt(e,t){Jt=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return Jt(e,t)}var en,tn=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function nn(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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}()
|
|
;return function(){var n,r=$t(e);if(t){var i=$t(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Qt(this,n)}}!function(e){e[e.LEFT=0]="LEFT";e[e.RIGHT=1]="RIGHT"}(en||(en={}));var rn=function(e){var t=e.onClick,n=e.className,i=e.direction;return(0,r.jsx)(f.P3F,{"aria-hidden":!0,className:a()(Kt().scrollerButton,n),onClick:t,children:(0,r.jsx)(zt.Z,{className:Kt().scrollerButtonArrow,direction:i})})},on=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&&Jt(e,t)}(n,e);var t=nn(n);function n(){qt(this,n);var e;(e=t.apply(this,arguments)).state={tileIndex:0,prevWidth:e.props.width,lastArrowDirection:en.LEFT,scrollerWidth:0};e.advancedScrollerRef=i.createRef();e.tileScrollerRef=i.createRef();e.setScrollerWidth=function(){var t=(0,Ut.findDOMNode)(e.tileScrollerRef.current)
|
|
;(0,Vt.k)(t,HTMLElement)&&t.offsetWidth!==e.state.scrollerWidth&&e.setState({scrollerWidth:t.offsetWidth})};e.prev=function(){e.setState({tileIndex:Math.max(e.state.tileIndex-1,0),lastArrowDirection:en.LEFT})};e.next=function(){e.setState({tileIndex:Math.min(e.state.tileIndex+1,e.getMaxIndex()),lastArrowDirection:en.RIGHT})};return e}var o=n.prototype;o.getMaxOffset=function(){var e=this.props.width,t=this.state.scrollerWidth;return Math.max(Math.floor(t-e),0)};o.getSideOffset=function(){var e=this.props,t=e.tileWidth,n=e.tileMargin,r=this.getMaxOffset(),i=t+n;return r-Math.floor(r/i)*i};o.getMaxIndex=function(){var e=this.props,t=e.tileWidth,n=e.tileMargin;return Math.round(this.getMaxOffset()/(t+n))};o.getOffset=function(e,t){var n=this.props,r=n.tileWidth,i=n.tileMargin;return Math.min(e*(r+i)+(t===en.RIGHT?this.getSideOffset():0),this.getMaxOffset())};o.componentDidMount=function(){this.setScrollerWidth()};o.componentDidUpdate=function(e,t){
|
|
if(t.tileIndex!==this.state.tileIndex||t.lastArrowDirection!==this.state.lastArrowDirection){var n,r,i,o=this.state.tileIndex,a=this.getOffset(this.state.tileIndex,this.state.lastArrowDirection);null===(n=this.advancedScrollerRef.current)||void 0===n||n.scrollTo({to:a,animate:!0});null===(i=(r=this.props).onScroll)||void 0===i||i.call(r,{tileIndex:o})}e.width!==this.props.width&&this.setScrollerWidth()};o.render=function(){var e=this,t=this.state,n=t.tileIndex,i=t.lastArrowDirection,o=this.props,l=o.header,c=o.headerId,s=this.getMaxOffset()>0;return(0,r.jsxs)("div",{children:[(0,r.jsxs)("div",{className:Kt().headerContainer,children:[(0,r.jsx)(f.X6q,{id:c,variant:"heading-lg/semibold",children:l}),s?(0,r.jsxs)("div",{className:Kt().arrowsContainer,children:[(0,r.jsx)(rn,{direction:zt.Z.Directions.LEFT,onClick:this.prev,className:a()(Kt().arrowLeft,Xt({},Kt().arrowDisabled,0===n&&i===en.LEFT))}),(0,r.jsx)(rn,{direction:zt.Z.Directions.RIGHT,onClick:this.next,
|
|
className:a()(Kt().arrowRight,Xt({},Kt().arrowDisabled,n===this.getMaxIndex()&&i===en.RIGHT))})]}):null]}),(0,r.jsx)("div",{className:Kt().scrollerContainer,children:(0,r.jsx)(f.xVE,{ref:this.advancedScrollerRef,orientation:"horizontal",className:Kt().scroller,children:(0,r.jsx)("div",{className:Kt().scroller,ref:function(t){e.tileScrollerRef.current=t;e.setScrollerWidth()},children:this.props.children})})})]})};n.getDerivedStateFromProps=function(e,t){return t.prevWidth!==e.width?{tileIndex:0,prevWidth:e.width,lastArrowDirection:en.LEFT}:null};return n}(i.Component);const an=(0,Bt.Z)(on);var ln=n(712123),cn=n.n(ln);function sn(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 un(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done);a=!0){o.push(r.value)
|
|
;if(t&&o.length===t)break}}catch(e){l=!0;i=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}return o}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return sn(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(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return sn(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 dn(e){var t=e.collection,n=t.id,o=t.title,a=t.application_directory_collection_items,l=e.guildId,c=e.onClickApplication,s=i.useRef(null),u=un(i.useState(300),2),d=u[0],f=u[1],p=un(i.useState(4),2),h=p[0],m=p[1],y=parseFloat(cn().cardGap);i.useEffect((function(){var e=function(){var e,t=null===(e=s.current)||void 0===e?void 0:e.offsetWidth,n=1;if(null==t)return 300;t>=500&&(n=2)
|
|
;t>=700&&(n=3);t>=1e3&&(n=4);m(n);return(t-(n-1)*y)/n},t=s.current;if(null!=t){var n=new ResizeObserver((function(){f(e())}));f(e());n.observe(t);return function(){n.disconnect()}}}),[y]);var g=(0,st.Dt)();return(0,r.jsx)("div",{ref:s,children:(0,r.jsx)(an,{header:o,headerId:g,tileWidth:d,tileMargin:y,onScroll:function(e){var t=e.tileIndex,r=a.slice(t,t+h).reduce((function(e,t){var n=t.type,r=t.application;n===ze.C.APPLICATION&&null!=r&&e.push(r.id);return e}),[]);_.default.track(B.rMx.APP_DIRECTORY_COLLECTION_SCROLLED,{collection_id:n,offset:t,results:r,guild_id:l})},children:(0,r.jsx)("ul",{"aria-labelledby":g,className:cn().itemsContainer,children:a.map((function(e){var t=e.id,i=e.type,o=e.application;if(i===ze.C.APPLICATION&&null!=o){return(0,r.jsx)("li",{style:{width:d},className:cn().itemContainer,children:(0,r.jsx)(Ht,{application:o,onClick:function(e){var t=e.mutualGuilds;_.default.track(B.rMx.APP_DIRECTORY_COLLECTION_ITEM_CLICKED,{collection_id:n,application_id:o.id,
|
|
guild_id:l,shown_mutual_guilds_count:t.length});c(o)},animatesOnHover:!0})},t)}}))})})})}var fn=n(388737),pn=n.n(fn);function hn(e){var t,n,o,a,l,c=e.application,s=e.onClick,u=e.imageSrc,d=e.className,p=e.animatesOnHover,h=Mt({application:c}),m=null===(t=c.categories)||void 0===t?void 0:t[0],y=(null!==(a=null===(n=c.directory_entry)||void 0===n?void 0:n.guild_count)&&void 0!==a?a:0)>0||h.length>0,g=i.useCallback((function(){s({mutualGuilds:h})}),[s,h]),b=(0,r.jsx)(wt,{application:c,textVariant:"text-xs/normal",mutualGuilds:h,mutualGuildShownMax:3,guildIconSize:mt.SMALL,compact:!0});return(0,r.jsx)(Lt,{className:d,imageSrc:u,onClick:g,header:c.name,subheader:(0,r.jsxs)("div",{className:pn().subheader,children:[null!=m&&(0,r.jsx)(f.xvT,{tag:"span",color:"header-secondary",variant:"text-xs/normal",children:m.name}),y&&(0,r.jsxs)(r.Fragment,{children:[null!=m&&(0,r.jsx)("span",{className:pn().bullet,children:"•"}),b]})]}),animatesOnHover:p,children:null!=c.description&&(0,r.jsx)("div",{
|
|
className:pn().children,children:(0,r.jsx)(f.xvT,{className:pn().listingDescription,variant:"text-sm/normal",lineClamp:2,children:null!==(l=null===(o=c.directory_entry)||void 0===o?void 0:o.short_description)&&void 0!==l?l:c.description})})})}var mn=n(128064),yn=n.n(mn);function gn(e){var t=e.collection,n=t.id,i=t.title,o=t.application_directory_collection_items,l=e.guildId,c=e.onClickApplication;return(0,r.jsxs)("div",{children:[(0,r.jsx)(f.X6q,{variant:"heading-lg/semibold",className:yn().header,children:i}),(0,r.jsx)("div",{className:yn().list,children:o.map((function(e){var t=e.id,i=e.type,o=e.application,s=e.image_hash,u=e.title,d=e.description,p=e.call_to_action_label,h=e.call_to_action_url;if(null!=s){var m=ne({itemId:t,hash:s});if(i===ze.C.APPLICATION&&null!=o){return(0,r.jsx)(hn,{className:yn().item,imageSrc:m,application:o,onClick:function(e){var t=e.mutualGuilds;_.default.track(B.rMx.APP_DIRECTORY_COLLECTION_ITEM_CLICKED,{collection_id:n,application_id:o.id,guild_id:l,
|
|
shown_mutual_guilds_count:t.length});c(o)},animatesOnHover:!0},t)}if(i===ze.C.LINK&&null!=u){return(0,r.jsxs)(Lt,{className:a()(yn().item,yn().linkCard),imageSrc:m,header:u,headerClassName:yn().cardHeader,children:[(0,r.jsx)(f.xvT,{variant:"text-sm/normal",className:yn().linkDescription,children:d}),(0,r.jsx)(f.eee,{onClick:function(){_.default.track(B.rMx.APP_DIRECTORY_COLLECTION_ITEM_CLICKED,{collection_id:n,link:h,guild_id:l,shown_mutual_guilds_count:void 0})},href:h,className:a()((0,f.nYM)(),yn().linkCta),children:p})]},t)}}}))})]})}var bn=n(887779),vn=n.n(bn);function On(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 jn(e,t,n,r,i,o,a){try{var l=e[o](a),c=l.value}catch(e){n(e);return}l.done?t(c):Promise.resolve(c).then(r,i)}function Cn(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function a(e){jn(o,r,i,a,l,"next",e)}function l(e){jn(o,r,i,a,l,"throw",e)}a(void 0)}))}}
|
|
function _n(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function Pn(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done);a=!0){o.push(r.value);if(t&&o.length===t)break}}catch(e){l=!0;i=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}return o}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return On(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(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return On(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.")}()}
|
|
var In,xn=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:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){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;(r=0,i)&&(o=[2&o[0],i.value]);switch(o[0]){case 0:case 1:i=o;break;case 4:a.label++;return{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,l])}}};!function(e){e[e.NOT_LOADED=0]="NOT_LOADED";e[e.LOADING=1]="LOADING";e[e.LOADED=2]="LOADED";e[e.ERROR=3]="ERROR"}(In||(In={}));function En(e){var t=e.guildId,n=e.onClickApplication,o=Pn(i.useState(In.NOT_LOADED),2),l=o[0],c=o[1],s=Pn(i.useState([]),2),u=s[0],d=s[1],f=(0,oe.e7)([Me.default],(function(){return Me.default.appDirectoryIncludesInactiveCollections}));i.useEffect((function(){function e(){return(e=Cn((function(){var e,t;return xn(this,(function(n){switch(n.label){case 0:c(In.LOADING);n.label=1;case 1:n.trys.push([1,3,,4]);return[4,Ie({includesInactive:f})];case 2:e=n.sent();t=ee(e.map((function(e){e.application_directory_collection_items=te(e.application_directory_collection_items);return e})));d(t);c(In.LOADED);return[3,4];case 3:n.sent();c(In.ERROR);return[3,4];case 4:return[2]}}))}))).apply(this,arguments)}!function(){e.apply(this,arguments)}()}),[f]);return l===In.ERROR?(0,r.jsx)(Fe,{}):(0,r.jsx)(Be,{
|
|
loading:l===In.LOADING,children:u.map((function(e,i){var o,l=i>0&&u[i-1].type!==De.o.GALLERY;switch(e.type){case De.o.LIST:o=(0,r.jsx)(dn,{collection:e,guildId:t,onClickApplication:n});break;case De.o.LIST_WITH_IMAGE:o=(0,r.jsx)(gn,{collection:e,guildId:t,onClickApplication:n});break;case De.o.GALLERY:o=(0,r.jsx)(ct,{collection:e,guildId:t,onClickApplication:n});break;default:return null}return(0,r.jsx)("div",{className:a()(_n({},vn().topMargin,l)),children:o},e.id)}))})}var wn=n(282898),Sn=n(792045),Nn=n.n(Sn);function Rn(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 An(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done);a=!0){o.push(r.value);if(t&&o.length===t)break}}catch(e){l=!0;i=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}
|
|
return o}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Rn(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(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Rn(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 Tn(e,t){var n=e.query,o=e.canShowCta,l=void 0!==o&&o,c=e.onChange,s=e.onSubmit,u=e.className,d=An(i.useState(!1),2),f=d[0],p=d[1];return(0,r.jsx)(wn.Z,{ref:t,className:a()(Nn().search,u),label:z.Z.Messages.APP_DIRECTORY_SEARCH_PLACEHOLDER,placeholder:z.Z.Messages.APP_DIRECTORY_SEARCH_PLACEHOLDER,searchTerm:n,cta:l&&f&&n.length>0?z.Z.Messages.GUILD_DISCOVERY_SEARCH_ENTER_CTA:null,onChange:c,onClear:function(){return c("")},onFocus:function(){return p(!0)},onBlur:function(){return p(!1)},
|
|
onKeyPress:function(e){e.charCode===B.yXg.ENTER&&s()},autoFocus:!0})}const Ln=i.forwardRef(Tn);var Dn=n(327727),Mn=n.n(Dn),kn=n(323236),Zn=n.n(kn);function Gn(e){var t=e.searchRef,n=e.searchQuery,i=e.onSearchChange,o=e.onSearchSubmit;return(0,r.jsxs)("div",{className:Mn().container,children:[(0,r.jsxs)("div",{className:Mn().searchBarContainer,children:[(0,r.jsx)(f.X6q,{variant:"display-lg",className:Mn().heading,children:z.Z.Messages.APP_DIRECTORY_HERO_HEADING}),(0,r.jsx)(Ln,{className:Mn().searchBar,ref:t,query:n,onChange:i,onSubmit:o,canShowCta:!0})]}),(0,r.jsx)("img",{src:Zn(),alt:"",className:Mn().rightImage})]})}var Yn=n(368153),Fn=n.n(Yn),Hn=n(832834),Un=n.n(Hn);function Vn(e){var t=e.guildId;return(0,r.jsxs)("div",{className:Fn().container,role:"contentinfo",children:[(0,r.jsx)("img",{className:Fn().image,src:Un(),alt:""}),(0,r.jsxs)("div",{className:Fn().content,children:[(0,r.jsx)(f.X6q,{variant:"heading-md/semibold",
|
|
children:z.Z.Messages.APP_DIRECTORY_HOME_NEW_TO_APPS_BANNER_HEADING}),(0,r.jsx)(f.xvT,{variant:"text-sm/normal",color:"header-secondary",children:z.Z.Messages.APP_DIRECTORY_HOME_NEW_TO_APPS_BANNER_BODY})]}),(0,r.jsx)(f.zxk,{size:f.zxk.Sizes.SMALL,onClick:function(){_.default.track(B.rMx.APP_DIRECTORY_CTA_CLICKED,{cta:"new_to_apps",current_page:"home",guild_id:t});(0,h.Z)("https://discord.com/blog/how-to-use-discord-apps")},className:Fn().button,children:z.Z.Messages.APP_DIRECTORY_HOME_NEW_TO_APPS_BANNER_CTA})]})}var Bn=n(476509),zn=n.n(Bn);function Wn(e){var t=e.categories,n=e.guildId,o=e.onViewApplication,a=e.onViewCategory,l=e.searchRef,c=e.searchQuery,s=e.onSearchChange,u=e.onSearchSubmit,d=i.useContext(Se);i.useEffect((function(){var e;_.default.track(B.rMx.APP_DIRECTORY_PAGE_VIEWED,{current_page:"home",previous_page:null===(e=Ee(d))||void 0===e?void 0:e.type,guild_id:n})}),[d,n]);return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(Gn,{searchRef:l,searchQuery:c,onSearchChange:s,
|
|
onSearchSubmit:u}),null!=t&&t.length>0&&(0,r.jsx)(Le,{guildId:n,className:zn().categoryList,categories:t,onView:a}),(0,r.jsx)("main",{className:zn().collectionsContainer,children:(0,r.jsx)(En,{guildId:n,onClickApplication:o})}),(0,r.jsx)(Vn,{guildId:n})]})}var Kn=n(120053),qn=n.n(Kn),Xn=n(940060),$n=n(712861),Qn=n(336194),Jn=n(6912),er=n(725778),tr=n(146431),nr=n(73904),rr=n(898302),ir=n(248046),or=n(301443),ar=n(59882),lr=n(109206),cr=n(112897),sr=n(721160),ur=n(253958),dr=n(384411),fr=n(901654),pr=n(749266),hr=n(377463),mr=n(58838),yr=n(186440),gr=n(691797),br=n(72580),vr=n(709992),Or=n(915781),jr=n.n(Or);function Cr(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function _r(e){var t=e.applications,n=e.className,i=e.listingClassName,o=e.title,a=e.showViewAll,l=e.onViewOne,c=e.onViewAll;return(0,r.jsxs)("div",{className:n,children:[null!=o?(0,r.jsxs)("div",{className:jr().header,children:[(0,r.jsx)(f.X6q,{
|
|
variant:"heading-lg/semibold",children:o}),a?(0,r.jsx)(f.zxk,{look:f.zxk.Looks.LINK,color:f.zxk.Colors.LINK,onClick:c,children:z.Z.Messages.APP_DIRECTORY_LISTING_VIEW_ALL_BUTTON}):null]}):null,(0,r.jsx)("ul",{className:jr().list,children:t.map((function(e){return(0,r.jsx)(Pr,{className:i,application:e,onClick:function(t){var n=t.mutualGuilds;return l({application:e,mutualGuilds:n})}},e.id)}))})]})}function Pr(e){return(0,r.jsx)(Ht,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){Cr(e,t,n[t])}))}return e}({},e))}var Ir=n(996051),xr=n(469313),Er=n.n(xr);function wr(e){var t=e.commands,n=e.className;return(0,r.jsx)("div",{className:a()(Er().list,n),children:t.map((function(e){return(0,r.jsxs)("div",{className:Er().row,children:[(0,
|
|
r.jsxs)(f.xvT,{className:Er().commandName,variant:"text-md/semibold",color:"header-primary",children:[Ir.GI,e.displayName]}),(0,r.jsx)(f.xvT,{variant:"text-md/normal",children:e.displayDescription})]},e.id)}))})}var Sr=n(712125),Nr=n(921122),Rr=n(363582),Ar=n(853039),Tr=n(688271),Lr=n(282961),Dr=n.n(Lr);function Mr(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}var kr=I.Z.getArticleURL(B.BhN.BOT_DATA_ACCESS);function Zr(e){var t=e.icon,n=e.heading,i=e.body;return(0,r.jsxs)("li",{className:Dr().intentContainer,children:[(0,r.jsx)("div",{children:(0,r.jsx)(t,{height:"24",width:"24"})}),(0,r.jsxs)("div",{className:Dr().intentTextContainer,children:[(0,r.jsx)("div",{children:(0,r.jsx)(f.X6q,{variant:"eyebrow",color:"header-secondary",children:n})}),(0,r.jsx)("div",{className:Dr().intentBody,children:(0,r.jsx)(f.xvT,{variant:"text-sm/normal",color:"header-secondary",children:i})})]})]})}function Gr(e){var t=e.application,n=(0,
|
|
Sr.w)({flags:null==t?void 0:t.flags}),o=n.hasMessageContent,l=n.hasGuildPresences,c=n.hasGuildMembers,s=n.hasIntents,u=i.useCallback((function(){null!=(null==t?void 0:t.privacy_policy_url)&&(0,Tr.q)({href:t.privacy_policy_url})}),[null==t?void 0:t.privacy_policy_url]);return(0,r.jsxs)(r.Fragment,{children:[s&&(0,r.jsx)("div",{className:Dr().intentsListHeading,children:(0,r.jsx)(f.xvT,{variant:"text-md/normal",children:z.Z.Messages.APP_DIRECTORY_PROFILE_DATA_ACCESS_INTENTS_LIST_HEADING})}),(0,r.jsxs)("div",{className:Dr().intentsContainer,children:[s&&(0,r.jsxs)("ul",{className:Dr().intentsList,children:[o&&(0,r.jsx)(Zr,{icon:Nr.Z,heading:z.Z.Messages.APP_DIRECTORY_PROFILE_DATA_ACCESS_MESSAGE_CONTENT_HEADING,body:z.Z.Messages.APP_DIRECTORY_PROFILE_DATA_ACCESS_MESSAGE_CONTENT_BODY}),l&&(0,r.jsx)(Zr,{icon:Ar.Z,heading:z.Z.Messages.APP_DIRECTORY_PROFILE_DATA_ACCESS_GUILD_PRESENCES_HEADING,body:z.Z.Messages.APP_DIRECTORY_PROFILE_DATA_ACCESS_GUILD_PRESENCES_BODY}),c&&(0,r.jsx)(Zr,{icon:Rr.Z,
|
|
heading:z.Z.Messages.APP_DIRECTORY_PROFILE_DATA_ACCESS_GUILD_MEMBERS_HEADING,body:z.Z.Messages.APP_DIRECTORY_PROFILE_DATA_ACCESS_GUILD_MEMBERS_BODY})]}),(0,r.jsxs)("div",{className:a()(Mr({},Dr().hasSeparator,s)),children:[(0,r.jsx)(f.xvT,{variant:"text-sm/normal",color:"header-secondary",children:z.Z.Messages.BOTS_DATA_ACCESS_BASELINE.format({helpCenterUrl:kr})}),null!=(null==t?void 0:t.privacy_policy_url)&&(0,r.jsx)(f.xvT,{variant:"text-sm/normal",color:"header-secondary",className:Dr().privacyPolicy,children:z.Z.Messages.APP_DIRECTORY_PROFILE_DATA_ACCESS_PRIVACY_POLICY_V2.format({onClick:u})})]})]})]})}var Yr=n(224813),Fr=n(259738),Hr=n(890607),Ur=n(317594),Vr=n(5304);function Br(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function zr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n)
|
|
;"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){Br(e,t,n[t])}))}return e}var Wr=/^discord.gg\/[a-zA-Z0-9-]+/,Kr=function(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}(zr({},pr.Z.rules),{heading:zr({},Fr.i.heading),inviteLink:{order:pr.Z.rules.link.order+1,match:function(e,t){return t.inline?Wr.exec(e):null},parse:function(e,t,n){var r=(0,Ur.z)(e[0]);return null==r||r.type!==Hr.g.INVITE?{type:"text",content:e[0]}:{type:"inviteLink",content:[{
|
|
type:"text",content:e[0]}],onClick:function(){var e;Yr.Z.acceptInviteAndTransitionToInviteChannel({inviteKey:r.code,context:{location:"Application Directory"}});null===(e=n.closeModal)||void 0===e||e.call(n)}}},react:function(e,t,n){return(0,r.jsx)(f.eee,{onClick:function(t){t.preventDefault();e.onClick()},children:(0,Vr.S)(e,t,n)},n.key)}}});const qr=Kr;var Xr=n(4629),$r=n(74535),Qr=n(265688),Jr=n(963881),ei=n(349491),ti=n(848285),ni=n(206986),ri=n(124251),ii=n(104630),oi=n(192539),ai=n.n(oi),li=n(860321),ci=n.n(li),si=n(145792),ui=n.n(si);function di(e){var t=e.guild,n=e.className,i=e.onClick,o=(0,$r.ZP)(),l=new ti.Z({name:t.name,icon:t.icon}),c=V.ZP.getGuildDiscoverySplashURL({id:t.id,splash:t.discovery_splash,size:192*(0,E.x_)()}),s=null!=c?c:function(e){switch(e){case B.BRd.DARK:return ci();case B.BRd.LIGHT:return ui()}}(o),u=V.ZP.getGuildIconURL({id:t.id,icon:t.icon,size:50});return(0,r.jsxs)(f.P3F,{className:a()(ai().card,n),onClick:i,
|
|
"aria-label":z.Z.Messages.APP_DIRECTORY_JOIN_SERVER_LABEL,children:[(0,r.jsxs)("div",{className:ai().cardHeader,children:[(0,r.jsx)("img",{src:s,alt:"",className:ai().splashImage}),(0,r.jsx)("div",{className:ai().guildIcon,children:(0,r.jsx)(bt.ZP,{mask:bt.ZP.Masks.AVATAR_DEFAULT,width:58,height:58,children:(0,r.jsx)("div",{className:ai().iconMask,children:(0,r.jsx)(ri.Z,{className:ai().icon,iconSrc:u,guild:l,size:ri.Z.Sizes.LARGE})})})})]}),(0,r.jsxs)("div",{className:ai().cardDetails,children:[(0,r.jsxs)("div",{className:ai().guildNameWrapper,children:[(0,r.jsx)(ni.Z,{className:ai().guildBadge,guild:t,tooltipColor:f.ua7.Colors.PRIMARY}),(0,r.jsx)(f.X6q,{variant:"heading-md/semibold",className:ai().guildName,children:t.name})]}),(0,r.jsx)(f.xvT,{className:ai().guildDescription,variant:"text-sm/normal",color:"header-secondary",lineClamp:2,children:t.description}),(0,r.jsx)("div",{className:ai().memberInfo,children:(0,r.jsxs)("div",{className:ai().memberCountWrapper,children:[(0,
|
|
r.jsx)(ii.Z,{className:ai().memberCountIcon,width:"16",height:"16"}),(0,r.jsx)(f.xvT,{variant:"text-xs/normal",color:"header-secondary",children:z.Z.Messages.INSTANT_INVITE_GUILD_MEMBERS_TOTAL.format({count:t.approximate_member_count})})]})})]})]})}var fi=n(151183),pi=n.n(fi);function hi(e){var t=e.supportedLanguages;return(0,r.jsx)("ul",{className:pi().outerContainer,children:t.map((function(e){return(0,r.jsx)("li",{className:a()(pi().innerContainer,pi().languageItem),children:(0,r.jsx)(f.xvT,{variant:"text-md/normal",children:e})},e)}))})}var mi=n(602347),yi=n.n(mi);function gi(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 bi(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done);a=!0){o.push(r.value);if(t&&o.length===t)break}}catch(e){l=!0;i=e
|
|
}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}return o}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return gi(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(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return gi(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.")}()}var vi=z.Z.getAvailableLocales();function Oi(e){var t,n,i,o=e.onClick,a=e.url,l=e.children,c=(0,$r.ZP)(),s=Qr.Z.getByUrl(a),u=c===B.BRd.DARK?null==s||null===(t=s.icon)||void 0===t?void 0:t.darkSVG:null==s||null===(n=s.icon)||void 0===n?void 0:n.lightSVG;return(0,r.jsx)(ji,{icon:void 0===u?Jr.Z:void 0,imageSrc:u,onClick:o,url:a,type:null!==(i=null==s?void 0:s.name)&&void 0!==i?i:"website",children:l})}function ji(e){
|
|
var t=e.icon,n=e.imageSrc,i=e.iconColor,o=e.url,l=e.type,c=e.children,s=e.onClick,u=null;null!=t?u=(0,r.jsx)(t,{className:yi().listIcon,color:i,width:20,height:20}):null!=n&&(u=(0,r.jsx)("img",{className:yi().listImage,src:n,alt:""}));var d=(0,r.jsxs)(r.Fragment,{children:[u,(0,r.jsx)(f.xvT,{className:yi().listText,variant:"text-md/normal",selectable:!0,children:c})]});return(0,r.jsx)(Xr.Z,{href:o,className:a()(yi().listItem,yi().linkItem),onClick:function(){s(o,l);return!1},useDefaultUnderlineStyles:!1,children:d})}function Ci(e){var t,n,o=e.application,l=e.guildId,c=e.className,s=e.onViewCategory,u=e.onClickGuildWidget,d=bi(i.useState(null),2),p=d[0],h=d[1],m=[],y=null!==(n=null==o||null===(t=o.directory_entry)||void 0===t?void 0:t.external_urls)&&void 0!==n?n:[];i.useEffect((function(){var e;if(void 0!==(null===(e=o.directory_entry)||void 0===e?void 0:e.supported_locales)){var t=new Set(o.directory_entry.supported_locales),n=vi.filter((function(e){return t.has(e.value)}))
|
|
;h(n.map((function(e){return e.localizedName})))}}),[o.directory_entry]);var g=function(e,t){_.default.track(B.rMx.APP_DIRECTORY_APPLICATION_EXTERNAL_LINK_CLICKED,{application_id:o.id,guild_id:l,type:t,url:e})};if(null!=o.categories&&o.categories.length>0){var b;m.push((0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.X6q,{className:yi().sectionHeader,variant:"eyebrow",children:z.Z.Messages.APP_DIRECTORY_PROFILE_CATEGORIES_HEADING}),(0,r.jsx)("div",{className:yi().categories,children:(null!==(b=o.categories)&&void 0!==b?b:[]).map((function(e){return(0,r.jsx)(f.P3F,{className:yi().category,onClick:function(){return s(e)},children:(0,r.jsx)(f.xvT,{variant:"text-sm/normal",color:"header-primary",children:e.name})},e.id)}))})]}))}null!=p&&p.length>0&&m.push((0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.X6q,{className:yi().sectionHeader,variant:"eyebrow",children:z.Z.Messages.APP_DIRECTORY_PROFILE_LANGUAGES_HEADING}),(0,r.jsx)(hi,{supportedLanguages:p})]}))
|
|
;(null!=o.terms_of_service_url||null!=o.privacy_policy_url||y.length>0)&&m.push((0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.X6q,{className:yi().sectionHeader,variant:"eyebrow",children:z.Z.Messages.APP_DIRECTORY_PROFILE_LINKS_HEADING}),y.map((function(e,t){return(0,r.jsx)(Oi,{url:e.url,onClick:g,children:e.name},t)})),null!=o.terms_of_service_url?(0,r.jsx)(ji,{icon:Jr.Z,onClick:g,url:o.terms_of_service_url,type:"tos",children:z.Z.Messages.APP_DIRECTORY_PROFILE_TERMS_LINK}):null,null!=o.privacy_policy_url?(0,r.jsx)(ji,{icon:ei.Z,onClick:g,url:o.privacy_policy_url,type:"policy",children:z.Z.Messages.APP_DIRECTORY_PROFILE_PRIVACY_LINK}):null]}));null!=o.guild&&o.guild.features.includes(B.oNc.DISCOVERABLE)&&m.push((0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.X6q,{className:yi().sectionHeader,variant:"eyebrow",children:z.Z.Messages.APP_DIRECTORY_PROFILE_SERVER_HEADING}),(0,r.jsx)(di,{guild:o.guild,onClick:u})]}));return(0,r.jsx)("div",{className:a()(yi().sidebar,c),children:m.length>0?(0,
|
|
r.jsx)(r.Fragment,{children:m.map((function(e,t){return(0,r.jsx)("div",{className:yi().section,children:e},t)}))}):null})}var _i=n(67912),Pi=n.n(_i);function Ii(e){var t=e.activeSection,n=e.setSection,i=e.shownSections;return(0,r.jsx)(f.njP,{selectedItem:t,type:"top",onItemSelect:n,className:Pi().tabBar,children:i.map((function(e){return(0,r.jsx)(f.njP.Item,{id:e.sectionName,className:Pi().tabBarItem,children:e.sectionText},e.sectionName)}))})}var xi=n(389740),Ei=n(125477),wi=n.n(Ei);function Si(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 Ni(e,t,n,r,i,o,a){try{var l=e[o](a),c=l.value}catch(e){n(e);return}l.done?t(c):Promise.resolve(c).then(r,i)}function Ri(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function a(e){Ni(o,r,i,a,l,"next",e)}function l(e){Ni(o,r,i,a,l,"throw",e)}a(void 0)}))}}function Ai(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,
|
|
configurable:!0,writable:!0}):e[t]=n;return e}function Ti(){Ti=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};return Ti.apply(this,arguments)}function Li(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){Ai(e,t,n[t])}))}return e}function Di(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){
|
|
Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function Mi(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done);a=!0){o.push(r.value);if(t&&o.length===t)break}}catch(e){l=!0;i=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}return o}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Si(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(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Si(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.")}()}var ki=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:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){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;(r=0,i)&&(o=[2&o[0],i.value]);switch(o[0]){case 0:case 1:i=o;break;case 4:a.label++;return{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,l])}}},Zi=qn().parserFor(qr),Gi=qn().reactFor(qn().ruleOutput(qr,"react")),Yi=(0,$n.Mg)(wi().iconSize);function Fi(e){var t,o,l=e.application,c=e.guildId,s=e.onViewApplication,u=e.onViewCategory,d=e.onCloseModal,p=e.initialSection,m=void 0===p?xi.c.GENERAL:p,y=i.useRef(null==l?void 0:l.id),g=i.useRef(!1),b=i.useContext(Se),v=Mi(i.useState(!1),2),O=v[0],j=v[1],C=Mi(i.useState(!1),2),P=C[0],I=C[1],x=Mi(i.useState(null),2),E=x[0],w=x[1],S=Mi(i.useState(void 0),2),N=S[0],R=S[1],A=Mi(i.useState((function(){return{closeModal:d}})),1)[0],T=Mi(i.useState(xi.c.GENERAL),2),L=T[0],D=T[1],M=Mi(i.useState(),2),k=M[0],Z=M[1],G=(0,oe.e7)([fr.Z],(function(){return fr.Z.isFocused()})),Y=(0,oe.e7)([dr.default],(function(){return dr.default.locale})),F=Mi(i.useState(l),2),H=F[0],U=F[1],V=Mt({application:H});i.useEffect((function(){if(null!=(null==l?void 0:l.id)){var e=(t=Ri((function(){var e,t,n,r;return ki(this,(function(i){switch(i.label){case 0:j(!0)
|
|
;return[4,je(l.id)];case 1:e=i.sent();U(e);t=e.directory_entry;if(null!=(n=null==t?void 0:t.popular_application_commands)){r=n.map((function(e){return(0,ir.Z8)({rootCommand:e,command:e,applicationId:e.application_id})}));R(r)}else R(void 0);if(y.current!==l.id){D(xi.c.GENERAL);y.current=void 0}j(!1);return[2]}}))})),function(){return t.apply(this,arguments)});e()}var t}),[null==l?void 0:l.id]);var W,K=pt(H,Yi),q=(0,lr.ZP)(K,Qn.Z.unsafe_rawColors.PRIMARY_800.css),X=(0,cr.Z)(null!==(W=null==H?void 0:H.id)&&void 0!==W?W:""),$=ht(H,c),Q=$.canInstall,J=$.install,ee=null===(t=Ee(b))||void 0===t?void 0:t.type;i.useEffect((function(){null!=(null==H?void 0:H.id)&&_.default.track(B.rMx.APP_DIRECTORY_PAGE_VIEWED,{current_page:"product",previous_page:ee,application_id:H.id,guild_id:c,shown_mutual_guilds_count:V.length})}),[null==H?void 0:H.id,c,V]);var te=i.useMemo((function(){var e,t=null==H||null===(e=H.install_params)||void 0===e?void 0:e.permissions;if(null!=t)return sr.VY.filter((function(e){
|
|
return Xn.Z.has(Xn.Z.deserialize(t),e)}))}),[null==H||null===(o=H.install_params)||void 0===o?void 0:o.permissions]),ne=i.useCallback((function(e){D(e);g.current=!0;null!=(null==H?void 0:H.id)&&_.default.track(B.rMx.APP_DIRECTORY_PROFILE_TAB_CLICKED,{application_id:H.id,guild_id:c,tab_name:L})}),[null==H?void 0:H.id,c,L]),re=i.useMemo((function(){var e,t,n;return null!==(n=(null!==(t=null==H||null===(e=H.directory_entry)||void 0===e?void 0:e.carousel_items)&&void 0!==t?t:[]).map(Hi).filter(br.lm))&&void 0!==n?n:[]}),[H]),ie=i.useCallback((function(e,t){if(e.type===B.s9s.IMG){var i=re.filter((function(e){return e.type===B.s9s.IMG})),o=i.findIndex((function(t){return t===e}));if(o<0)return;var a=i.map((function(e){var t=e;return{src:(0,er.Q)(t.src),width:t.width,height:t.height}}));(0,f.ZDy)(Ri((function(){var e,t;return ki(this,(function(i){switch(i.label){case 0:return[4,Promise.all([n.e(40532),n.e(17260),n.e(70606),n.e(17081)]).then(n.bind(n,484991))];case 1:e=i.sent(),t=e.default
|
|
;return[2,function(e){var n=Ti({},e);return(0,r.jsx)(t,Di(Li({},n),{items:a,startingIndex:o}))}]}}))})))}}),[re]),ae=i.useCallback((function(e){null!=(null==H?void 0:H.id)&&_.default.track(B.rMx.APP_DIRECTORY_CATEGORY_CLICKED,{current_page:"product",category:e.name,category_id:e.id,application_id:H.id,guild_id:c});u(e)}),[u,H,c]);i.useEffect((function(){function e(){return(e=Ri((function(){var e;return ki(this,(function(t){switch(t.label){case 0:if(null==l)return[2];I(!0);t.label=1;case 1:t.trys.push([1,3,,4]);return[4,_e(l.id,c)];case 2:e=t.sent();w(e.applications.slice(0,3));Z(e.loadId);return[3,4];case 3:t.sent();w([]);Z(void 0);return[3,4];case 4:I(!1);return[2]}}))}))).apply(this,arguments)}!function(){e.apply(this,arguments)}()}),[l,c]);var le=i.useCallback((function(e){var t=e.application,n=e.mutualGuilds;null!=(null==H?void 0:H.id)&&_.default.track(B.rMx.APP_DIRECTORY_RECOMMENDATION_CLICKED,{current_page:"product",application_id:H.id,suggested_application_id:t.id,load_id:k,
|
|
guild_id:c,shown_mutual_guilds_count:n.length});s(t)}),[s,null==H?void 0:H.id,k,c]),ce=i.useCallback(Ri((function(){var e,t,n;return ki(this,(function(r){switch(r.label){case 0:r.trys.push([0,3,,4]);if(null==(t=null==H||null===(e=H.guild)||void 0===e?void 0:e.id))return[3,2];null!=(null==H?void 0:H.id)&&_.default.track(B.rMx.APP_DIRECTORY_SUPPORT_SERVER_JOINED,{application_id:H.id,guild_id:t});n={page:B.ZY5.APPLICATION_DIRECTORY};return[4,(0,vr.Ub)(t,n)];case 1:r.sent();d();r.label=2;case 2:return[3,4];case 3:r.sent();return[3,4];case 4:return[2]}}))})),[H,d]),se=i.useCallback((function(){null!=H&&(0,h.Z)(function(e,t){var n="https://".concat(B.xr4,"/hc/").concat(e.toLowerCase(),"/requests/new"),r=new URLSearchParams;r.append("tf_12275088515223","field_value_dc_category_report_an_app_bot");r.append("tf_12276208289431","field_value_dc_reported_action_app_directory");r.append("tf_12094971213335",t.id);r.append("ticket_form_id","12275528604823")
|
|
;r.append("tf_subject","App Directory Report ".concat(t.name," ").concat(t.id));return"".concat(n,"?").concat(r.toString())}(Y,H))}),[Y,H]),ue=i.useCallback((function(e){return(0,r.jsxs)(f.v2r,{navId:"application-directory-profile","aria-label":z.Z.Messages.APP_DIRECTORY_PROFILE_UTILITIES_A11Y_LABEL,onClose:e,onSelect:void 0,children:[(0,r.jsx)(f.kSQ,{children:(0,r.jsx)(f.sNh,{id:"report",label:z.Z.Messages.REPORT_APP,color:"danger",action:se})}),null!=X?(0,r.jsx)(f.kSQ,{children:X}):null]})}),[X,se]),de=Mi((0,rr.Z)(!1,1e3),2),fe=de[0],pe=de[1],he=i.useCallback((function(){if(null!=H){_.default.track(B.rMx.APP_SHARE_BUTTON_CLICKED,{source:"product_page",application_id:H.id,guild_id:c});(0,gr.JG)((e=H.id,"".concat(location.protocol,"//").concat(location.host).concat(B.Z5c.APPLICATION_DIRECTORY(e))));var e;pe(!0)}}),[H,pe,c]),me=(0,or.ZP)({applicationId:null==H?void 0:H.id,groupListingId:null==H?void 0:H.primary_sku_id,guildId:c,checksExperiment:!1
|
|
}).applicationSubscriptionListingsShown,ye="936929561302675456"===(null==H?void 0:H.id),ge=Mi(i.useState(!1),2),be=ge[0],ve=ge[1],Oe=Mi(i.useState(!1),2),Ce=Oe[0],Pe=Oe[1],Ie=Mi(i.useState(!0),2),xe=Ie[0],we=Ie[1],Ne=function(e){null!=e&&ve(e.scrollHeight>e.clientHeight)},Re=null!=te&&te.length>0,Ae=null!=(null==H?void 0:H.flags),Te=i.useMemo((function(){var e=[],t=!0;switch(L){case xi.c.GENERAL:var n,i,o=null==H||null===(n=H.directory_entry)||void 0===n?void 0:n.detailed_description;if(null!=o&&o.length>0){e.push((0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.X6q,{className:wi().sectionHeader,variant:"heading-md/semibold",children:z.Z.Messages.APP_DIRECTORY_PROFILE_DESCRIPTION_HEADING}),(0,r.jsx)("div",{ref:Ne,className:a()(Ai({},wi().descriptionClamp,!Ce)),children:(0,r.jsx)(pr.Z,{className:wi().detailedDescription,parser:Zi,output:Gi,state:A,children:o})}),(be||Ce)&&(0,r.jsx)(Ui,{isViewAll:Ce,onToggle:function(){Pe((function(e){return!e}))}})]}));t=!1
|
|
}else void 0!==(null==H||null===(i=H.directory_entry)||void 0===i?void 0:i.short_description)?e.push((0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.X6q,{className:wi().sectionHeader,variant:"heading-md/semibold",children:z.Z.Messages.APP_DIRECTORY_PROFILE_DESCRIPTION_HEADING}),(0,r.jsx)("span",{children:H.directory_entry.short_description})]})):null!=(null==H?void 0:H.description)&&e.push((0,r.jsx)(ur.Z,{className:wi().description,userBio:H.description}));if(null!=N&&N.length>0){e.push((0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.X6q,{className:wi().sectionHeader,variant:"heading-md/semibold",children:z.Z.Messages.APP_DIRECTORY_PROFILE_COMMANDS_HEADING}),(0,r.jsx)(wr,{className:wi().commandList,commands:N})]}));t=!0}break;case xi.c.IMAGES:var l=(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("img",{className:wi().errorImage,src:Ye(),"aria-hidden":!0,alt:""}),(0,r.jsx)(f.X6q,{variant:"heading-xl/semibold",children:z.Z.Messages.ERRORS_IMAGE_NOT_FOUND})]});re.map((function(e,t){
|
|
e.alt=null!=H?z.Z.Messages.APP_DIRECTORY_PROFILE_IMAGE_CAROUSEL_ALT.format({index:t+1,totalImages:re.length,name:H.name}):z.Z.Messages.APP_DIRECTORY_PROFILE_IMAGE_DEFAULT_ALT}));e.push((0,r.jsx)(tr.Z,{className:wi().carousel,themedPagination:!0,items:re,autoplayInterval:8e3,paused:!G,videoAutoPlay:!0,onCurrentItemClick:ie,errorComponent:l,onImageLoad:function(e){var t=e.src,n=e.loadTimeMs;null!=n&&null!=H&&_.default.track(B.rMx.APP_DIRECTORY_CAROUSEL_IMAGE_LOADED,{application_id:H.id,load_time_ms:n,src:t})}}));break;case xi.c.PREMIUM:me&&null!=(null==H?void 0:H.primary_sku_id)&&e.push((0,r.jsx)(ar.Z,{applicationId:H.id,applicationPrimarySkuId:null==H?void 0:H.primary_sku_id,analyticsLocation:B.Sbl.APP_DIRECTORY_PROFILE,onComplete:d}));break;case xi.c.PRIVACY:Re&&e.push((0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.X6q,{className:wi().sectionHeader,variant:"heading-md/semibold",children:z.Z.Messages.APP_DIRECTORY_PROFILE_REQUIRED_PERMISSIONS_HEADING}),(0,r.jsx)(Jn.Z,{
|
|
className:wi().commandList,grantedPermissions:te,grantedPermissionsHeader:z.Z.Messages.APP_DIRECTORY_PROFILE_REQUIRED_PERMISSIONS_SUB_HEADING})]}));Ae&&e.push((0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.X6q,{className:wi().sectionHeader,variant:"heading-md/semibold",children:z.Z.Messages.APP_DIRECTORY_PROFILE_DATA_ACCESS_HEADING}),(0,r.jsx)(Gr,{application:H})]}))}we(t);return e.map((function(e,t){return(0,r.jsx)("div",{className:wi().section,children:e},t)}))}),[H,me,re,N,te,ie,G,A,L,Ce,be,d,Re,Ae]),Le=i.useMemo((function(){var e=y.current===(null==l?void 0:l.id)&&!g.current,t=[{sectionName:xi.c.GENERAL,sectionText:z.Z.Messages.APP_DIRECTORY_PROFILE_TAB_GENERAL}];if(re.length>0){t.push({sectionName:xi.c.IMAGES,sectionText:z.Z.Messages.APP_DIRECTORY_PROFILE_TAB_IMAGES});e&&m===xi.c.IMAGES&&D(m)}if(me){t.push({sectionName:xi.c.PREMIUM,sectionText:z.Z.Messages.APP_DIRECTORY_PROFILE_TAB_PREMIUM});e&&m===xi.c.PREMIUM&&D(m)}if(Re||Ae){t.push({sectionName:xi.c.PRIVACY,
|
|
sectionText:z.Z.Messages.APP_DIRECTORY_PROFILE_TAB_PRIVACY});e&&m===xi.c.PRIVACY&&D(m)}return t}),[re.length,me,Re,Ae,m,null==l?void 0:l.id]);return null==H?(0,r.jsx)("div",{className:wi().page,children:(0,r.jsxs)("div",{className:wi().emptyContainer,children:[(0,r.jsx)("img",{className:wi().emptyImage,src:Ye(),alt:""}),(0,r.jsx)(f.X6q,{variant:"heading-xl/semibold",children:z.Z.Messages.APP_DIRECTORY_PROFILE_EMPTY_HEADING})]})}):(0,r.jsxs)(Be,{loading:O,children:[(0,r.jsx)("div",{style:{backgroundColor:q},className:wi().headerBanner}),(0,r.jsxs)("div",{className:wi().page,children:[(0,r.jsxs)("div",{className:wi().header,children:[(0,r.jsxs)("div",{className:wi().headerSidebar,children:[(0,r.jsx)("img",{className:wi().headerIcon,alt:"","aria-hidden":!0,src:K,width:Yi,height:Yi}),(0,r.jsx)(wt,{application:H,mutualGuilds:V,mutualGuildShownMax:3,compact:!0})]}),(0,r.jsxs)("div",{className:wi().headerContent,children:[(0,r.jsxs)("div",{className:wi().headerNameAndButtons,children:[(0,
|
|
r.jsxs)("div",{className:wi().headerNameAndIcon,children:[(0,r.jsx)(f.X6q,{className:wi().name,variant:"heading-xxl/semibold",children:H.name}),me&&(0,r.jsx)(f.ua7,{tooltipClassName:wi().premiumIconTooltip,text:z.Z.Messages.APPLICATION_DIRECTORY_PROFILE_TOOLTIP_PREMIUM,children:function(e){return(0,r.jsx)("img",Di(Li({},e),{alt:z.Z.Messages.APPLICATION_DIRECTORY_PROFILE_TOOLTIP_PREMIUM,className:wi().premiumIcon,src:n(823660)}))}}),ye&&(0,r.jsx)(tt,{className:wi().partnerBadge})]}),(0,r.jsxs)("div",{className:a()(wi().buttons),children:[(0,r.jsx)(f.zxk,{onClick:he,color:f.zxk.Colors.PRIMARY,children:fe?z.Z.Messages.INTEGRATIONS_WEBHOOK_COPIED_URL:z.Z.Messages.APP_DIRECTORY_PROFILE_SHARE_BUTTON}),(0,r.jsx)(f.zxk,{color:f.zxk.Colors.BRAND,onClick:function(){J("product_page")},disabled:!Q,children:z.Z.Messages.APP_DIRECTORY_PROFILE_ADD_BUTTON}),(0,r.jsx)(f.yRy,{renderPopout:function(e){var t=e.closePopout;return ue(t)},position:"left",align:"top",animation:f.yRy.Animation.NONE,
|
|
children:function(e){return(0,r.jsx)(f.P3F,Di(Li({className:wi().overflow},e),{children:(0,r.jsx)(yr.Z,{width:20,height:20,className:wi().iconInteractive})}))}})]})]}),(0,r.jsx)(Ii,{activeSection:L,setSection:ne,shownSections:Le})]})]}),(0,r.jsxs)("div",{className:wi().contentContainer,children:[(0,r.jsxs)("div",{className:wi().content,children:[Te,null!=E&&E.length>0?(0,r.jsxs)(r.Fragment,{children:[xe&&(0,r.jsx)("div",{className:wi().separator}),(0,r.jsxs)("div",{className:wi().section,children:[(0,r.jsx)(f.X6q,{className:wi().relatedHeader,variant:"eyebrow",children:z.Z.Messages.APP_DIRECTORY_PROFILE_RELATED_APPS_HEADING}),(0,r.jsx)(Be,{loading:P,children:(0,r.jsx)(_r,{applications:E,onViewOne:le})})]})]}):null]}),(0,r.jsx)(Ci,{className:wi().sidebar,application:H,guildId:c,onViewCategory:ae,onClickGuildWidget:ce})]})]})]})}function Hi(e){switch(e.type){case nr.ee.MEDIA_PROXY:var t,n=null!==(t=e.proxy_url)&&void 0!==t?t:e.url;return{type:B.s9s.IMG,width:0,height:0,src:n}
|
|
;case nr.ee.YOUTUBE:var r=function(e){if(null==e)return null;var t=e.match(/.*(?:youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=)([^#&?]*).*/);return null!=t?t[1]:null}(e.url);if(null!=r)return{type:B.s9s.YOUTUBE_VIDEO,youtubeVideoId:r}}console.warn("Unsupported carousel item",e);return null}var Ui=function(e){var t,n=e.onToggle;t=e.isViewAll?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.xvT,{className:wi().showMoreButtonText,variant:"eyebrow",children:z.Z.Messages.APP_DIRECTORY_PROFILE_SHOW_LESS}),(0,r.jsx)(mr.Z,{className:wi().showMoreButtonIcon})]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.xvT,{className:wi().showMoreButtonText,variant:"eyebrow",children:z.Z.Messages.APP_DIRECTORY_PROFILE_SHOW_MORE}),(0,r.jsx)(hr.Z,{className:wi().showMoreButtonIcon})]});return(0,r.jsx)(Vi,{children:(0,r.jsx)(f.zxk,{look:f.zxk.Looks.BLANK,color:f.zxk.Colors.TRANSPARENT,size:f.zxk.Sizes.NONE,className:wi().showMoreButton,innerClassName:wi().showMoreButtonInner,onClick:n,children:t})})},Vi=function(e){
|
|
var t=e.className,n=e.contentClassName,i=e.children;return(0,r.jsxs)("div",{className:a()([wi().dividerContainer,t]),children:[(0,r.jsx)("div",{className:wi().divider}),null!=i?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("div",{className:a()(wi().contentDivider,n),children:i}),(0,r.jsx)("div",{className:wi().divider})]}):null]})},Bi=n(229392),zi=n.n(Bi),Wi=n(457217),Ki=n(425537),qi=n(310790),Xi=n(106200),$i=n(243763),Qi=n(325198),Ji=n(618769),eo=n.n(Ji);function to(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function no(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){to(e,t,n[t])}))}return e}function ro(e,t){t=null!=t?t:{}
|
|
;Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function io(e){var t,n,o,l=e.application,c=e.className,s=e.childrenClassName,u=e.showAdd,d=e.showMutualGuilds,p=e.showPrimaryCategory,h=e.children,m=e.onView,y=e.guildCountPosition,g=void 0===y?"top":y,b=e.subheaderTextVariant,v=void 0===b?"text-sm/normal":b,O=e.mutualGuildShownMax,j=e.guildIconSize,C=e.source,_=(0,Wi.JA)(l.id),P=pt(l,48),I=ht(l),x=I.canInstall,E=I.install,w=Mt({application:l,showMutualGuilds:d}),S=i.useCallback((function(e){e.stopPropagation();E(C)
|
|
}),[E,C]),N=null===(t=l.categories)||void 0===t?void 0:t[0],R=(null!==(o=null===(n=l.directory_entry)||void 0===n?void 0:n.guild_count)&&void 0!==o?o:0)>0||w.length>0,A=(0,r.jsx)(wt,{application:l,textVariant:v,mutualGuilds:w,mutualGuildShownMax:O,guildIconSize:j,compact:!0}),T=p&&null!=N,L=R&&"top"===g,D=R&&"bottom"===g,M=null!=l.primary_sku&&(0,$i.KK)(l.primary_sku.flags),k=(0,r.jsxs)("article",{children:[(0,r.jsxs)("div",{className:eo().topWrapper,children:[(0,r.jsx)("img",{className:eo().icon,alt:"","aria-hidden":!0,src:P,width:48,height:48}),(0,r.jsxs)("div",{className:eo().info,children:[(0,r.jsx)(f.X6q,{variant:"heading-md/medium",children:l.name}),(T||L)&&(0,r.jsxs)("div",{className:eo().details,children:[T?(0,r.jsx)(f.xvT,{tag:"span",color:"header-secondary",variant:v,children:N.name}):null,L?(0,r.jsxs)(r.Fragment,{children:[T?(0,r.jsx)("span",{className:eo().bullet,children:"•"}):null,A,M?(0,r.jsxs)("div",{className:eo().premiumContainer,children:[(0,r.jsx)("span",{
|
|
className:eo().bullet,children:"•"}),(0,r.jsx)(Qi.Z,{width:16,height:16}),(0,r.jsx)(f.xvT,{variant:"text-sm/medium",className:eo().premiumText,children:z.Z.Messages.APPLICATION_DIRECTORY_LISTING_TOOLTIP_PREMIUM})]}):null]}):null]})]}),u?(0,r.jsx)(f.zxk,{size:f.zxk.Sizes.SMALL,onClick:S,disabled:!x,children:z.Z.Messages.APP_DIRECTORY_LISTING_ADD_BUTTON}):null]}),null!=h||null!=s?(0,r.jsx)("div",{className:a()(s,eo().children),children:h}):null,D?(0,r.jsx)("div",{className:eo().bottomGuildCountContainer,children:A}):null]});return null!=m?(0,r.jsx)(f.P3F,ro(no({tag:"li",onClick:function(){return m({mutualGuilds:w})},className:a()(c,eo().listing,eo().clickable)},_),{children:k})):(0,r.jsx)(f.tEY,{children:(0,r.jsx)("li",ro(no({className:a()(c,eo().listing)},_),{children:k}))})}function oo(e){var t,n,i=e.category,o=e.className,a=e.onViewAll;if(function(e){return 0===e.id}(i)){t=z.Z.Messages.APP_DIRECTORY_EMPTY_SEARCH_HEADING;n=z.Z.Messages.APP_DIRECTORY_EMPTY_SEARCH_SUBHEADING}else{
|
|
t=z.Z.Messages.APP_DIRECTORY_EMPTY_CATEGORY_SEARCH_HEADING.format({categoryName:i.name});n=z.Z.Messages.APP_DIRECTORY_EMPTY_CATEGORY_SEARCH_SUBHEADING.format({viewAllHook:function(e,t){return(0,r.jsx)(f.eee,{onClick:a,children:e},t)}})}return(0,r.jsx)(Fe,{className:o,heading:t,body:n})}var ao=n(422028),lo=n.n(ao);function co(e){e=null!==e?e:function(e){throw e}(new TypeError("Cannot destructure undefined"));return(0,r.jsxs)("div",{className:lo().container,children:[(0,r.jsxs)("div",{className:lo().content,children:[(0,r.jsx)(f.xvT,{variant:"text-sm/semibold",className:lo().title,children:z.Z.Messages.APP_DIRECTORY_MUSIC_BANNER_TITLE}),(0,r.jsx)(f.X6q,{variant:"heading-xxl/medium",children:z.Z.Messages.APP_DIRECTORY_MUSIC_BANNER_HEADER}),(0,r.jsx)(f.xvT,{variant:"text-md/normal",children:z.Z.Messages.APP_DIRECTORY_MUSIC_BANNER_CONTENT})]}),(0,r.jsx)("div",{className:lo().imageContainer,children:(0,r.jsx)("img",{className:lo().image,src:n(442907),alt:""})})]})}var so=n(890377),uo=n.n(so)
|
|
;function fo(e){var t=e.guildId;return(0,r.jsxs)("div",{className:uo().container,children:[(0,r.jsx)("img",{className:uo().image,src:n(967305),alt:""}),(0,r.jsxs)("div",{className:uo().content,children:[(0,r.jsx)(f.X6q,{variant:"heading-md/extrabold",children:z.Z.Messages.APP_DIRECTORY_MUSIC_FOOTER_HEADER}),(0,r.jsx)(f.xvT,{variant:"text-sm/medium",children:z.Z.Messages.APP_DIRECTORY_MUSIC_FOOTER_CONTENT})]}),(0,r.jsx)(f.zxk,{size:f.zxk.Sizes.SMALL,onClick:function(){_.default.track(B.rMx.APP_DIRECTORY_CTA_CLICKED,{cta:"submit_music_app",current_page:"search",guild_id:t});(0,h.Z)("https://dis.gd/music-search-page-inclusion")},color:f.zxk.Colors.TRANSPARENT,className:uo().button,children:z.Z.Messages.APP_DIRECTORY_MUSIC_FOOTER_CTA})]})}var po=n(281385),ho=n.n(po);function mo(e){var t=e.imageSrc,n=e.header,i=e.description,o=e.secondaryInfo,a=e.mutualGuildCount,l=e.ctaLabel,c=e.onCtaClick,s=e.children,u=(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)("div",{className:ho().topWrapper,
|
|
children:[(0,r.jsx)("div",{className:ho().imageContainer,children:(0,r.jsx)("img",{alt:"",className:ho().image,src:t})}),(0,r.jsxs)("div",{className:ho().content,children:[(0,r.jsxs)("div",{className:ho().header,children:[(0,r.jsxs)("div",{className:ho().info,children:[(0,r.jsx)(f.X6q,{className:ho().name,variant:"heading-md/semibold",children:n}),null!=a?a:(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)("div",{className:ho().details,children:[(0,r.jsx)(f.xvT,{tag:"span",color:"header-secondary",variant:"text-sm/medium",children:z.Z.Messages.APP_DIRECTORY_MUSIC_CATEGORY}),null!=o?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(f.xvT,{tag:"span",color:"interactive-muted",variant:"text-sm/normal",className:ho().bullet,children:"•"}),(0,r.jsx)(f.xvT,{tag:"span",color:"header-secondary",variant:"text-sm/medium",children:o})]}):null]})})]}),null!=c&&null!=l?(0,r.jsx)(f.zxk,{size:f.zxk.Sizes.SMALL,onClick:c,className:ho().button,children:l}):null]}),null!=i?(0,r.jsx)(f.xvT,{
|
|
className:ho().listingDescription,variant:"text-md/normal",children:i}):null,(0,r.jsx)("div",{className:ho().children,children:s})]})]})});return(0,r.jsx)(f.tEY,{children:(0,r.jsx)("div",{className:ho().listing,children:u})})}var yo=n(770515),go=n.n(yo),bo=new Map([["890343617762304070",{imageSrc:n(412384)}]]),vo=new Map,Oo=new Map([[B.ABu.SPOTIFY,{imageSrc:n(881874)}]]);function jo(e){var t,n=e.result,i=e.onViewApplication,o=n.data,a=Mt({application:o}),l=bo.get(n.data.id);if(null==l)return null;var c,s=a.length>0?(0,r.jsx)(wt,{application:n.data,textVariant:"text-sm/semibold",mutualGuilds:a,mutualGuildShownMax:3,guildIconSize:mt.SMALL,compact:!0}):null,u=null!==(c=null===(t=o.directory_entry)||void 0===t?void 0:t.guild_count)&&void 0!==c?c:0,d=u>0?z.Z.Messages.APP_DIRECTORY_SHORT_GUILD_COUNT.format({guildCount:u}):void 0;return(0,r.jsx)(mo,{imageSrc:l.imageSrc,header:n.data.name,description:n.data.description,secondaryInfo:d,ctaLabel:z.Z.Messages.APPLICATION_ADD_TO_SERVER,
|
|
mutualGuildCount:s,onCtaClick:function(){return i(o)}})}function Co(e){var t=e.result,n=vo.get(t.data.id);return null==n?null:(0,r.jsx)(mo,{imageSrc:n.imageSrc,header:t.data.name,description:t.data.description,secondaryInfo:z.Z.Messages.APP_DIRECTORY_ACTIVITY_LABEL})}function _o(e){var t,n,i,o=e.result,a=e.guildId,l=Oo.get(o.data.name);if(null==l)return null;if(o.data.name===B.ABu.SPOTIFY){t=z.Z.Messages.APP_DIRECTORY_SPOTIFY_TITLE;n=z.Z.Messages.APP_DIRECTORY_SPOTIFY_DESCRIPTION.format();i=function(){_.default.track(B.rMx.APP_DIRECTORY_CTA_CLICKED,{current_page:"search",cta:"spotify",guild_id:a});(0,h.Z)("https://support.discord.com/hc/en-us/articles/360000167212-Discord-Spotify-Connection")}}return null==t||null==n||null==i?null:(0,r.jsx)(mo,{imageSrc:l.imageSrc,header:t,description:n,ctaLabel:z.Z.Messages.LEARN_MORE,onCtaClick:i,secondaryInfo:z.Z.Messages.APP_DIRECTORY_CONNECTION_LABEL})}function Po(e){var t=e.results,n=e.guildId,i=e.onViewApplication;return(0,r.jsxs)("div",{
|
|
className:go().container,children:[(0,r.jsx)(co,{}),(0,r.jsx)("div",{className:go().list,children:t.map((function(e,t){var o="".concat(t).concat(e.type);return e.type===Ki.s.APPLICATION?(0,r.jsx)(jo,{result:e,onViewApplication:i},o):e.type===Ki.s.ACTIVITY_APPLICATION?(0,r.jsx)(Co,{result:e},o):e.type===Ki.s.CONNECTION?(0,r.jsx)(_o,{guildId:n,result:e},o):void 0}))}),(0,r.jsx)(fo,{guildId:n})]})}var Io=n(114741),xo=n.n(Io);function Eo(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 wo(e){return function(e){if(Array.isArray(e))return Eo(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Eo(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(n)
|
|
;if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Eo(e,t)}(e)||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.")}()}function So(e){var t=e.categories,n=e.currentCategoryId,o=e.guildId,l=e.className,c=e.countsByCategory,s=e.onView,u=i.useContext(Se),d=i.useMemo((function(){return[Q()].concat(wo(t))}),[t]);return(0,r.jsx)(f.njP,{className:a()(xo().container,l),selectedItem:n,type:"top-pill",onItemSelect:function(e){var t;if(e!==n){var r=d.find((function(t){return t.id===e}));_.default.track(B.rMx.APP_DIRECTORY_CATEGORY_CLICKED,{category:r.name,category_id:r.id,current_page:null===(t=we(u))||void 0===t?void 0:t.type,guild_id:o});s(r)}},orientation:"vertical",children:d.map((function(e){var t,i=e.id,o=e.name,l=J(e),s=a()(xo().category,function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n
|
|
;return e}({},xo().activeCategory,n===i));return(0,r.jsxs)(f.njP.Item,{id:i,className:s,"aria-label":o,disableItemStyles:!0,children:[(0,r.jsx)(l,{className:xo().icon,width:"24",height:"24"}),(0,r.jsx)(f.xvT,{variant:"text-md/normal",children:o}),null!=c?(0,r.jsx)(f.xvT,{className:xo().count,variant:"text-md/normal",color:"text-muted",children:null!==(t=null==c?void 0:c[i])&&void 0!==t?t:0}):null]},i)}))})}var No=n(451943),Ro=n.n(No),Ao=n(67976),To=n.n(Ao);function Lo(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 Do(e,t,n,r,i,o,a){try{var l=e[o](a),c=l.value}catch(e){n(e);return}l.done?t(c):Promise.resolve(c).then(r,i)}function Mo(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function ko(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n)
|
|
;"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){Mo(e,t,n[t])}))}return e}function Zo(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function Go(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 Yo(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done);a=!0){o.push(r.value);if(t&&o.length===t)break}}catch(e){l=!0;i=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}return o}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Lo(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(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Lo(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.")}()}var Fo=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:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){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;(r=0,i)&&(o=[2&o[0],i.value]);switch(o[0]){case 0:case 1:i=o;break;case 4:a.label++;return{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,l])}}};zi().shim();function Ho(e){var t=e.guildId,n=e.categories,o=e.query,a=e.onSearchChange,l=e.onSearchSubmit,s=e.searchRef,u=e.activeCategory,d=e.onViewApplication,f=e.onChangeCategoryFilter,p=e.currentPage,h=e.setCurrentPage,m=i.useContext(Se),y=Yo(i.useState(!1),2),g=y[0],b=y[1],v=Yo(i.useState(null),2),O=v[0],j=v[1],C=Yo(i.useState(0),2),P=C[0],I=C[1],x=Yo(i.useState({}),2),E=x[0],w=x[1],S=Yo(i.useState(qi.c.SEARCH_RESULTS),2),N=S[0],R=S[1],A=Yo(i.useState(),2),T=A[0],L=A[1],D=i.useRef(null),M=i.useCallback((function(e){var n;_.default.track(B.rMx.APP_DIRECTORY_SEARCHED,{search_term:o,num_results:e,current_page:null===(n=we(m))||void 0===n?void 0:n.type,result_page:p,category:u.name,category_id:u.id,guild_id:t})}),[u.id,u.name,p,t,m,o]),k=Yo(i.useState((function(){return c().debounce((t=(e=function(e){var t,n,r,i,o,a,l,c,s;return Fo(this,(function(u){switch(u.label){case 0:t=e.query,n=e.page,r=e.activeCategoryId,i=e.onSuccessCallback,
|
|
o=e.guildId,a=e.fetchCounts;b(!0);a&&(l=Ce(t,o));return[4,Ce(t,o,{page:n,categoryId:r})];case 1:c=u.sent();if(null==l)return[3,5];u.label=2;case 2:u.trys.push([2,4,,5]);return[4,l];case 3:s=u.sent();w(ko(Mo({},0,s.totalCount),s.countsByCategory));return[3,5];case 4:u.sent();w({});return[3,5];case 5:try{R(c.type);j(c.results.filter((function(e){return!(c.type===qi.c.SEARCH_RESULTS&&e.type!==Ki.s.APPLICATION)})));I(c.totalPages);L(c.loadId);i(c.totalCount)}catch(e){j([]);I(0);L(void 0)}D.current=t;b(!1);return[2]}}))},function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function a(e){Do(o,r,i,a,l,"next",e)}function l(e){Do(o,r,i,a,l,"throw",e)}a(void 0)}))}),function(e){return t.apply(this,arguments)}),400,{leading:!1,trailing:!0});var e,t})),1),Z=k[0],G=i.useCallback((function(e){h(e);b(!0);Z({query:o,page:e,activeCategoryId:u.id,guildId:t,onSuccessCallback:M})}),[u.id,Z,t,o,h,M]),Y=i.useCallback((function(e){var n=e.application,r=e.mutualGuilds
|
|
;_.default.track(B.rMx.APP_DIRECTORY_SEARCH_RESULT_CLICKED,{current_page:"search",application_id:n.id,load_id:T,search_term:o,guild_id:t,shown_mutual_guilds_count:r.length});d(n)}),[T,d,o,t]);i.useEffect((function(){b(!0);Z({query:o,page:p,activeCategoryId:u.id,guildId:t,fetchCounts:o!==D.current,onSuccessCallback:M})}),[o,u,Z,t,p]);var F,H=i.useMemo((function(){return Object.keys(E).length>0}),[E]);g||0!==P?null!=O&&O.length>0&&N===qi.c.SEARCH_RESULTS?F=(0,r.jsx)(Uo,{items:O,pageCount:P,currentPage:p,showPrimaryCategory:0===u.id,onItemClick:Y,onChangePage:G}):null!=O&&O.length>0&&N===qi.c.MUSIC&&(F=(0,r.jsx)(Po,{guildId:t,results:O,onViewApplication:d})):F=(0,r.jsx)(oo,{category:u,onViewAll:function(){return f(Q())}});return(0,r.jsxs)("div",{className:Ro().page,children:[(0,r.jsxs)("div",{className:Ro().sidebar,children:[(0,r.jsx)("img",{src:To(),alt:"",className:Ro().sidebarImage}),(0,r.jsx)(So,{guildId:t,className:Ro().categoryList,categories:null!=n?n:[],
|
|
countsByCategory:H?E:void 0,currentCategoryId:u.id,onView:f})]}),(0,r.jsxs)("div",{className:Ro().content,children:[(0,r.jsx)(Ln,{ref:s,query:o,onChange:a,onSubmit:l}),(0,r.jsx)(Be,{loading:g,children:(0,r.jsx)("div",{className:Ro().contentContainer,children:F})})]})]})}function Uo(e){var t=e.items,n=e.currentPage,o=e.pageCount,a=e.showPrimaryCategory,l=e.onItemClick,c=e.onChangePage,s=(0,Xi.Z)("application-directory-search");return(0,r.jsxs)(i.Fragment,{children:[(0,r.jsx)(Wi.bG,{navigator:s,children:(0,r.jsx)(Wi.SJ,{children:function(e){var n=e.ref,i=Go(e,["ref"]);return(0,r.jsx)("ul",Zo(ko({ref:n},i),{children:t.map((function(e){if(e.type===Ki.s.APPLICATION){var t,n,i=e.data;null!=(null===(t=i.directory_entry)||void 0===t?void 0:t.short_description)&&i.directory_entry.short_description.length>0?n=i.directory_entry.short_description:null!=i.description&&i.description.length>0&&(n=i.description);return(0,r.jsx)(io,{className:Ro().listing,childrenClassName:Ro().listingDetails,
|
|
application:i,onView:function(e){var t=e.mutualGuilds;return l({application:i,mutualGuilds:t})},showMutualGuilds:!0,showPrimaryCategory:a,source:"search",children:null!=n?(0,r.jsx)(f.xvT,{className:Ro().listingDescription,variant:"text-md/normal",lineClamp:3,children:n}):null},i.id)}}))}))}})}),(0,r.jsx)(f.DsT,{currentPage:n,totalCount:Math.min(7*o,700),pageSize:7,onPageChange:c,disablePaginationGap:!0})]})}function Vo(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 Bo(e,t,n,r,i,o,a){try{var l=e[o](a),c=l.value}catch(e){n(e);return}l.done?t(c):Promise.resolve(c).then(r,i)}function zo(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function a(e){Bo(o,r,i,a,l,"next",e)}function l(e){Bo(o,r,i,a,l,"throw",e)}a(void 0)}))}}function Wo(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function Ko(e,t){return function(e){
|
|
if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o=[],a=!0,l=!1;try{for(n=n.call(e);!(a=(r=n.next()).done);a=!0){o.push(r.value);if(t&&o.length===t)break}}catch(e){l=!0;i=e}finally{try{a||null==n.return||n.return()}finally{if(l)throw i}}return o}}(e,t)||Xo(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 qo(e){return function(e){if(Array.isArray(e))return Vo(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Xo(e)||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.")}()}function Xo(e,t){if(e){if("string"==typeof e)return Vo(e,t)
|
|
;var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);return"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Vo(e,t):void 0}}var $o=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:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){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;(r=0,i)&&(o=[2&o[0],i.value]);switch(o[0]){case 0:case 1:i=o;break;case 4:a.label++;return{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,l])}}},Qo=I.Z.getArticleURL(B.BhN.APP_DIRECTORY_HEADER_LEARN_MORE);function Jo(e){var t=e.onClose,n=i.useRef(null);return(0,r.jsx)("div",{ref:n,className:K().closeWrapper,children:(0,r.jsx)(f.JcV,{containerRef:n,children:(0,r.jsx)("div",{className:a()(K().closeContent,d.tq?K().closeContentMobile:K().closeContentNotMobile),children:(0,r.jsx)(p.Z,{className:a()(K().closeIcon,d.tq?K().closeIconMobile:K().closeIconNotMobile),closeAction:t,keybind:"ESC"})})})})}function ea(e){var t=e.onTitleClick,n=e.showsLearnMoreCta,o=e.guildId,l=(0,r.jsxs)(i.Fragment,{children:[(0,r.jsxs)("div",{className:K().headerName,children:[(0,r.jsx)(j,{className:K().logo}),(0,r.jsx)(f.y5t,{forceLevel:1,
|
|
children:(0,r.jsx)(f.X6q,{className:K().title,variant:"heading-md/semibold",color:"header-secondary",children:z.Z.Messages.APP_DIRECTORY})})]}),n&&(0,r.jsx)(f.eee,{onClick:function(){_.default.track(B.rMx.APP_DIRECTORY_CTA_CLICKED,{cta:"directory-help-center",current_page:"home",guild_id:o});(0,h.Z)(Qo)},children:z.Z.Messages.LEARN_MORE})]});return(0,r.jsx)("div",{className:K().header,children:null!=t?(0,r.jsx)(f.P3F,{onClick:t,className:a()(K().titleContainer,K().clickable),children:l}):(0,r.jsx)("div",{className:K().titleContainer,children:l})})}function ta(e){var t,n=e.view,i=e.onClick;switch(n.type){case"home":t=z.Z.Messages.HOME;break;case"search":t=z.Z.Messages.SEARCH;break;case"application":var o,a;t=null!==(a=null===(o=n.application)||void 0===o?void 0:o.name)&&void 0!==a?a:z.Z.Messages.BACK}return(0,r.jsxs)(f.P3F,{className:K().back,onClick:i,children:[(0,r.jsx)(y.Z,{direction:y.Z.Directions.LEFT,className:K().backIcon}),(0,r.jsx)(f.X6q,{className:K().backHeader,
|
|
variant:"heading-sm/semibold",children:t})]})}var na=(0,l.debounce)((function(e){var t=e.scrollTop,n=e.scrollOffset,r=e.scrollHeight,i=e.location,o=e.guildId,a=e.sessionId;t>0&&_.default.track(B.rMx.APP_DIRECTORY_PAGE_SCROLLED,{scroll_visible_percentile:(t+n)/r,guild_id:o,location:i,directory_session_id:a})}),200);function ra(e){var t,n=e.guildId,o=e.close,l=e.entrypoint,c=e.initialHistory,s=void 0===c?[{type:"home"}]:c,p=i.useRef(null),h=i.useRef(null),y=Ko(i.useState(null),2),g=y[0],b=y[1],v=Ko(i.useState(s),2),O=v[0],j=v[1],C=Ko(i.useState(Q()),2),I=C[0],E=C[1],w=Ko(i.useState(""),2),S=w[0],N=w[1],R=Ko(i.useState(1),2),A=R[0],T=R[1];i.useEffect((function(){function e(){return(e=zo((function(){return $o(this,(function(e){switch(e.label){case 0:e.trys.push([0,2,,3]);return[4,Pe()];case 1:b.apply(void 0,[e.sent()]);return[3,3];case 2:e.sent();return[3,3];case 3:return[2]}}))}))).apply(this,arguments)}!function(){e.apply(this,arguments)}()}),[]);i.useEffect((function(){
|
|
x.K3.getCurrentConfig({},{autoTrackExposure:!0}).enabled&&function(){xe.apply(this,arguments)}()}),[]);var L=O[O.length-1],D=O.length>1?O[O.length-2]:null,M="application"===L.type?null===(t=L.application)||void 0===t?void 0:t.id:void 0,k=i.useRef();i.useEffect((function(){k.current=u().v4()}),[L.type,M]);var Z=function(e){var t,n=qo(O).concat([e]),r=n[n.length-2];"search"===r.type?r.textFilter=S:r.textFilter="";"search"!==r.type&&"home"!==r.type||(r.categoryFilter=I.id);j(n);null===(t=p.current)||void 0===t||t.scrollToTop()},G=function(e){T(1);N(e);"search"===L.type&&0===e.length&&E(Q())},Y=function(){if("search"!==L.type){_.default.track(B.rMx.APP_DIRECTORY_SEARCH_STARTED,{search_term:S,category:I.name,current_page:L.type,category_id:I.id,guild_id:n});T(1);Z({type:"search"})}},F=function(e){var t;if("application"!==L.type||(null===(t=L.application)||void 0===t?void 0:t.id)!==e.id){E(Q());N("");Z({type:"application",application:e})}},H=function(e){e=null!=e?e:Q()
|
|
;if("search"!==L.type||L.categoryFilter!==e.id){E(e);T(1);N("");Z({type:"search"})}},U=i.useCallback((function(){o();_.default.track(B.rMx.MODAL_DISMISSED,{type:B.ZY5.APPLICATION_DIRECTORY})}),[o]);i.useEffect((function(){(0,m.Kw)(m.v6.APP_DIRECTORY_SETTINGS_NEW_PILL);_.default.track(B.rMx.OPEN_MODAL,{type:B.ZY5.APPLICATION_DIRECTORY,guild_id:n,location:l})}),[]);i.useEffect((function(){P.S.subscribe(B.CkL.LAYER_POP_ESCAPE_KEY,U);return function(){P.S.unsubscribe(B.CkL.LAYER_POP_ESCAPE_KEY,U)}}),[U]);var V=null;switch(L.type){case"home":V=(0,r.jsx)(Wn,{guildId:n,categories:g,onViewCategory:H,onViewApplication:F,searchRef:h,searchQuery:S,onSearchChange:G,onSearchSubmit:Y});break;case"search":V=(0,r.jsx)(Ho,{guildId:n,categories:g,query:S,activeCategory:I,onViewApplication:F,onChangeCategoryFilter:function(e){T(1);E(e)},currentPage:A,setCurrentPage:T,onSearchChange:G,onSearchSubmit:Y,searchRef:h});break;case"application":V=(0,r.jsx)(Fi,{application:L.application,guildId:n,
|
|
onViewApplication:F,onViewCategory:H,onCloseModal:U,initialSection:L.section})}var z="home"!==L.type;return(0,r.jsxs)(Se.Provider,{value:O,children:[(0,r.jsx)(Jo,{onClose:o}),(0,r.jsx)(f.Den,{className:a()(K().directoryModal,Wo({},K().directoryModalMobile,d.tq)),ref:p,onScroll:function(){var e,t,r;return na({scrollTop:null===(e=p.current)||void 0===e?void 0:e.getScrollerState().scrollTop,offsetHeight:null===(t=p.current)||void 0===t?void 0:t.getScrollerState().offsetHeight,scrollHeight:null===(r=p.current)||void 0===r?void 0:r.getScrollerState().scrollHeight,location:L.type,guildId:n,sessionId:k.current})},children:(0,r.jsxs)("div",{className:K().content,children:[(0,r.jsx)(ea,{onTitleClick:z?function(e){if("home"!==L.type){var t;T(1);E(null!=e?e:Q());N("");j([{type:"home"}]);null===(t=p.current)||void 0===t||t.scrollToTop()}}:void 0,showsLearnMoreCta:"home"===L.type,guildId:n}),null!=D?(0,r.jsx)(ta,{view:D,onClick:function(){if(O.length>1){var e,t=O.slice(0,-1),n=t[t.length-1]
|
|
;void 0!==n.textFilter&&N(n.textFilter);if(void 0!==n.categoryFilter){var r;E(null!==(r=(null!=g?g:[]).find((function(e){return e.id===n.categoryFilter})))&&void 0!==r?r:Q())}else E(Q());j(t);null===(e=p.current)||void 0===e||e.scrollToTop()}}}):null,V]})})]})}function ia(e){var t=e.guildId,n=e.applicationId,i=e.directoryDisabled,o=e.entrypoint,a=e.section;if(null!=n){var l=i?[]:[{type:"home"}];je(n).then((function(e){(0,C.q4)((function(n){var i=n.closeLayer;return(0,r.jsx)(ra,{guildId:t,close:i,entrypoint:o,initialHistory:l.concat({type:"application",application:e,section:a})})}))})).catch((function(){(0,C.q4)((function(e){var n=e.closeLayer;return(0,r.jsx)(ra,{guildId:t,close:n,entrypoint:o,initialHistory:l.concat({type:"application"})})}))}))}else i||(0,C.q4)((function(e){var n=e.closeLayer;return(0,r.jsx)(ra,{guildId:t,close:n,entrypoint:o})}))}},389740:(e,t,n)=>{"use strict";n.d(t,{c:()=>r});var r;!function(e){e.GENERAL="GENERAL";e.IMAGES="IMAGES";e.PREMIUM="PREMIUM"
|
|
;e.PRIVACY="PRIVACY"}(r||(r={}))},59882:(e,t,n)=>{"use strict";n.d(t,{Z:()=>R});var r=n(785893),i=n(667294),o=n(707961),a=n(673679),l=n(301443),c=n(243763),s=n(712861),u=n(202351),d=n(543491),f=n(615796),p=n(249052),h=n(534681),m=n(485084),y=n(835530),g=n(215043),b=n(2590),v=n(473708),O=n(873739),j=n.n(O);function C(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function _(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}var P=(0,s.Mg)(j().listingImageSize),I=function(e){var t=e.listing,n=t.image_asset;if(null==n)return null;var i=(0,
|
|
h._W)(t.application_id,n,P);return(0,r.jsx)("div",{children:(0,r.jsx)("img",{src:i,alt:"",className:j().listingImage})})},x=function(e){var t=e.children;return(0,r.jsx)(o.zxk,{look:o.zxk.Looks.OUTLINED,color:o.zxk.Colors.PRIMARY,disabled:!0,size:o.zxk.Sizes.SMALL,children:t})};function E(e){var t=e.listing,n=e.groupListingId,i=e.guildId,a=e.analyticsLocation,c=e.onComplete,s=(0,u.e7)([f.Z],(function(){return f.Z.isSyncing})),h=(0,l.F5)(t.application_id,i),O=h.activeSubscription,P=h.activeSubscriptionListing,E=(0,g.Z)({listing:t,guildId:i,groupListingId:n,showBenefitsFirst:!1,analyticsLocation:a,onComplete:c}),w=E.openModal,S=E.canOpenModal,N=E.cannotOpenReason,R=t.subscription_plans[0],A=0===R.price,T=(null==P?void 0:P.id)===t.id;return(0,r.jsxs)("div",{className:j().container,children:[(0,r.jsxs)("div",{className:j().cardHeader,children:[(0,r.jsx)(I,{listing:t}),(0,r.jsx)(o.xvT,{variant:"text-lg/medium",color:"interactive-active",children:t.name}),(0,r.jsxs)("div",{
|
|
className:j().priceAndButtonContainer,children:[(0,r.jsx)(o.xvT,{variant:"text-md/normal",color:"interactive-normal",children:A?v.Z.Messages.APPLICATION_SUBSCRIPTION_FREE:v.Z.Messages.APPLICATION_SUBSCRIPTION_AMOUNT_PER_PERIOD.format({amount:(0,p.T4)(R.price,R.currency),period:(0,d.JE)(R)})}),function(){if(T)return(0,r.jsx)(x,{children:(null==O?void 0:O.status)===b.O0b.CANCELED?v.Z.Messages.APPLICATION_SUBSCRIPTION_TIER_REVIEW_CANCELED_LABEL:v.Z.Messages.APPLICATION_SUBSCRIPTION_TIER_REVIEW_CURRENT_TIER_LABEL});if(A)return null==P?(0,r.jsx)(x,{children:v.Z.Messages.APPLICATION_SUBSCRIPTION_TIER_REVIEW_CURRENT_TIER_LABEL}):null;var e,t=!S||s;return(0,r.jsx)(o.ua7,{tooltipClassName:j().subscribeButtonTooltip,text:S?null:N,"aria-label":null!==(e=!S&&N)&&void 0!==e&&e,children:function(e){return(0,r.jsx)(m.Z,_(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n)
|
|
;"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){C(e,t,n[t])}))}return e}({},e),{disabled:t,submitting:!1,onClick:w,children:v.Z.Messages.APPLICATION_SUBSCRIPTION_TIER_REVIEW_SUBSCRIBE_LABEL}))}})}()]})]}),(0,r.jsx)("div",{className:j().benefitsContainer,children:t.sku_benefits.benefits.map((function(e,t){return(0,r.jsx)(y.Z,{benefit:e,className:j().benefit},t)}))})]})}var w=n(999907),S=n.n(w);function N(e){var t=e.listing,n=(0,c.KK)(t.sku_flags);return(0,c.KW)(t.sku_flags)||n?(0,r.jsxs)("div",{className:S().cta,children:[(0,r.jsx)(o.X6q,{variant:"heading-lg/bold",children:n?v.Z.Messages.APPLICATION_GUILD_SUBSCRIPTION_LISTING_HEADER:v.Z.Messages.APPLICATION_USER_SUBSCRIPTION_LISTING_HEADER}),(0,r.jsx)(o.X6q,{color:"interactive-normal",variant:"heading-md/normal",
|
|
children:n?v.Z.Messages.APPLICATION_GUILD_SUBSCRIPTION_LISTING_DETAILS:v.Z.Messages.APPLICATION_USER_SUBSCRIPTION_LISTING_DETAILS.format({applicationName:t.name})})]}):null}function R(e){var t=e.guildId,n=e.applicationId,c=e.applicationPrimarySkuId,s=e.analyticsLocation,u=e.onComplete,d=(0,l.FE)(n,c).listingsLoaded,f=(0,l.LM)({guildId:t}).entitlementsLoaded,p=(0,l.F5)(n,t).subscriptionGroupListing;i.useEffect((function(){a.jg()}),[]);var h=null==p?void 0:p.id,m=null==p?void 0:p.subscription_listings;return!d||null!=t&&!f?(0,r.jsx)("div",{className:S().loadingContainer,children:(0,r.jsx)(o.$jN,{})}):null==h||null==m||0===m.length?null:(0,r.jsx)("div",{className:S().container,children:m.map((function(e){return(0,r.jsxs)("div",{children:[(0,r.jsx)(N,{listing:e},e.id),(0,r.jsx)(E,{listing:e,guildId:t,groupListingId:h,analyticsLocation:s,onComplete:u},e.id)]},e.id)}))})}},712125:(e,t,n)=>{"use strict";n.d(t,{w:()=>o});var r=n(661123),i=n(2590);function o(e){var t=function(e){
|
|
if(null!=e)return{guildPresences:(0,r.yE)(e,i.udG.GATEWAY_PRESENCE),guildMembers:(0,r.yE)(e,i.udG.GATEWAY_GUILD_MEMBERS),messageContent:(0,r.yE)(e,i.udG.GATEWAY_MESSAGE_CONTENT),guildPresencesLimited:(0,r.yE)(e,i.udG.GATEWAY_PRESENCE_LIMITED),guildMembersLimited:(0,r.yE)(e,i.udG.GATEWAY_GUILD_MEMBERS_LIMITED),messageContentLimited:(0,r.yE)(e,i.udG.GATEWAY_MESSAGE_CONTENT_LIMITED)}}(e.flags),n=null!=t&&((null==t?void 0:t.messageContent)||(null==t?void 0:t.messageContentLimited)),o=null!=t&&((null==t?void 0:t.guildPresences)||(null==t?void 0:t.guildPresencesLimited)),a=null!=t&&((null==t?void 0:t.guildMembers)||(null==t?void 0:t.guildMembersLimited));return{hasMessageContent:n,hasGuildPresences:o,hasGuildMembers:a,hasIntents:n||o||a}}},543491:(e,t,n)=>{"use strict";n.d(t,{ab:()=>a,JE:()=>l,iG:()=>c,rC:()=>s,lL:()=>u});var r=n(856744),i=n(203600),o=n(473708);function a(e){
|
|
return"roles"in e?"emoji-".concat(e.id):"".concat(e.ref_type,"-").concat(e.emoji_id,"-").concat(e.name,"-").concat(e.ref_id)}function l(e){var t=e.interval,n=e.interval_count;return function(e){switch(e){case i.rV.DAY:return o.Z.Messages.DAY;case i.rV.MONTH:return o.Z.Messages.MONTH;case i.rV.YEAR:return o.Z.Messages.YEAR}}(t).format({count:n})}function c(e){var t=e.interval,n=e.interval_count;switch(t){case i.rV.DAY:return n>0&&n%7==0?o.Z.Messages.DURATION_WEEKS_CAPITALIZE.format({weeks:n/7}):o.Z.Messages.DURATION_DAYS_CAPITALIZE.format({days:n});case i.rV.MONTH:return o.Z.Messages.DURATION_MONTHS_CAPITALIZE.format({months:n});case i.rV.YEAR:return o.Z.Messages.DURATION_YEARS_CAPITALIZE.format({years:n})}}function s(e){return e.ref_type===r.Qs.CHANNEL}function u(e){return e.ref_type===r.Qs.INTANGIBLE}},677483:(e,t,n)=>{"use strict";n.d(t,{Z:()=>j});var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(829389),c=n(254187),s=n.n(c);function u(e,t){
|
|
if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function f(e){f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return f(e)}function p(e,t){return!t||"object"!==m(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h(e,t){h=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return h(e,t)}var m=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}()
|
|
;return function(){var n,r=f(e);if(t){var i=f(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return p(this,n)}}var g,b={UP:"up",RIGHT:"right",DOWN:"down",LEFT:"left"},v=(d(g={},b.UP,s().up),d(g,b.RIGHT,s().right),d(g,b.DOWN,s().down),d(g,b.LEFT,s().left),g),O=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&&h(e,t)}(n,e);var t=y(n);function n(){u(this,n);return t.apply(this,arguments)}n.prototype.render=function(){var e=this.props,t=e.direction,n=e.className;return(0,r.jsx)(l.Z,{className:a()(s().arrow,n,d({},v[t],!0))})};return n}(i.PureComponent);O.Directions=b;const j=O},993137:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var r=n(785893),i=(n(667294),n(294184)),o=n.n(i),a=n(831222),l=n.n(a);function c(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,
|
|
configurable:!0,writable:!0}):e[t]=n;return e}function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){c(e,t,n[t])}))}return e}const u=function(e){var t=e.aspectRatio,n=e.style,i=e.className,a=e.children;return(0,r.jsx)("div",{className:o()(l().outer,i),style:s({paddingTop:"".concat(1/t*100,"%")},n),children:(0,r.jsx)("div",{className:l().inner,children:a})})}},910348:(e,t,n)=>{"use strict";n.d(t,{am:()=>O,Pz:()=>j,ZP:()=>C});var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(707961),c=n(677483),s=n(582713),u=n.n(s);function d(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function f(e){f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return f(e)}
|
|
function p(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&&m(e,t)}function h(e,t){return!t||"object"!==y(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function m(e,t){m=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return m(e,t)}var y=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){var n,r=f(e);if(t){var i=f(this).constructor;n=Reflect.construct(r,arguments,i)
|
|
}else n=r.apply(this,arguments);return h(this,n)}}var b={CENTER:u().alignCenter,LEFT:u().alignLeft},v=function(e){p(n,e);var t=g(n);function n(){d(this,n);var e;(e=t.apply(this,arguments))._scrollerRef=null;e._paginationItemRefs=[];e.handleSetScrollerRef=function(t){e._scrollerRef=t};e.handleSelectedIndexChange=function(t){var n=e._scrollerRef;if(null!=n){var r=e._paginationItemRefs[t];null!=r&&n.scrollIntoViewNode({node:r,animate:!0,padding:e.props.scrollToPadding})}};e.handlePageClick=function(t){(0,e.props.onSetItem)(t)};return e}var o=n.prototype;o.componentDidUpdate=function(e){var t=this.props.selectedIndex;e.selectedIndex!==t&&this.handleSelectedIndexChange(t)};o.render=function(){var e=this,t=this.props,n=t.renderItem,o=t.items,c=t.vertical,s=t.paginationContainerClass,d=t.align,f=c?u().verticalPaginationItemContainer:u().horizontalPaginationItemContainer;return(0,r.jsx)(l.yWw,{orientation:c?"vertical":"horizontal",className:a()(f,s,d),ref:this.handleSetScrollerRef,
|
|
children:o.map((function(t,r){return i.cloneElement(n(t,r),{onClick:function(){return e.handlePageClick(r)},key:r,ref:function(t){e._paginationItemRefs[r]=t}})}))})};return n}(i.PureComponent);v.Align=b;v.defaultProps={scrollToPadding:{top:0,left:0,bottom:0,right:0},align:b.CENTER};var O=function(e){p(n,e);var t=g(n);function n(){d(this,n);var e;(e=t.apply(this,arguments)).handlePrevClick=function(t){t.stopPropagation();t.preventDefault();var n=e.props.onClick;null==n||n(t)};return e}n.prototype.render=function(){var e=this.props.className;return(0,r.jsx)(l.zxk,{look:l.zxk.Looks.BLANK,size:l.zxk.Sizes.NONE,className:a()(u().prevButtonContainer,e),onClick:this.handlePrevClick,children:(0,r.jsx)(c.Z,{className:u().arrow,direction:c.Z.Directions.LEFT})})};return n}(i.PureComponent),j=function(e){p(n,e);var t=g(n);function n(){d(this,n);var e;(e=t.apply(this,arguments)).handleNextClick=function(t){t.stopPropagation();t.preventDefault();var n=e.props.onClick;null==n||n(t)};return e}
|
|
n.prototype.render=function(){var e=this.props.className;return(0,r.jsx)(l.zxk,{look:l.zxk.Looks.BLANK,size:l.zxk.Sizes.NONE,className:a()(u().nextButtonContainer,e),onClick:this.handleNextClick,children:(0,r.jsx)(c.Z,{className:u().arrow,direction:c.Z.Directions.RIGHT})})};return n}(i.PureComponent);const C=v},561329:(e,t,n)=>{"use strict";n.d(t,{Z:()=>R});var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(496486),c=n.n(l),s=n(513328),u=n(707961),d=n(930948),f=n(677483),p=n(993137),h=n(270307),m=n(2590),y=n(473708),g=n(105724),b=n.n(g);function v(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function O(e){O=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return O(e)}function j(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&&_(e,t)}
|
|
function C(e,t){return!t||"object"!==P(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function _(e,t){_=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return _(e,t)}var P=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function I(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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!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 C(this,n)}}var x="jump",E="next",w="previous",S=function(e){j(n,e);var t=I(n);function n(){v(this,n);var e;(e=t.apply(this,arguments)).handleDotClick=function(t){
|
|
var n=e.props,r=n.onSetItem,i=n.onIntentionalChange,o=n.current;null==i||i(o,t,x);r(t)};e.handleNext=function(){var t=e.props,n=t.onIntentionalChange,r=t.current,i=(0,t.onChangePage)(1);null==n||n(r,i,E)};e.handlePrevious=function(){var t=e.props,n=t.onIntentionalChange,r=t.current,i=(0,t.onChangePage)(-1);null==n||n(r,i,w)};return e}var i=n.prototype;i.componentDidMount=function(){d.S.subscribe(m.CkL.CAROUSEL_PREV,this.handlePrevious);d.S.subscribe(m.CkL.CAROUSEL_NEXT,this.handleNext)};i.componentWillUnmount=function(){d.S.unsubscribe(m.CkL.CAROUSEL_PREV,this.handlePrevious);d.S.unsubscribe(m.CkL.CAROUSEL_NEXT,this.handleNext)};i.render=function(){var e=this,t=this.props,n=t.current,i=t.count,o=t.includeHitboxPadding,l=t.arrowClassName,s=a()(b().arrowHitbox,l,function(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}({},b().arrowHitboxPadding,o));return(0,r.jsxs)("div",{className:a()(b().controls,this.props.className),
|
|
children:[(0,r.jsx)(u.zxk,{look:u.zxk.Looks.BLANK,className:s,onClick:this.handlePrevious,"aria-label":y.Z.Messages.PAGINATION_PREVIOUS,children:(0,r.jsx)(f.Z,{className:b().arrow,direction:f.Z.Directions.LEFT})}),(0,r.jsx)("div",{className:b().dots,children:c().times(i,(function(t){return(0,r.jsx)(u.zxk,{look:u.zxk.Looks.BLANK,size:u.zxk.Sizes.NONE,onClick:function(){return e.handleDotClick(t)},className:t===n?b().dotSelected:b().dotNormal,"aria-label":y.Z.Messages.PAGINATION_SLIDE_LABEL.format({pageNumber:t+1})},"dot-".concat(t))}))}),(0,r.jsx)(u.zxk,{look:u.zxk.Looks.BLANK,className:s,onClick:this.handleNext,"aria-label":y.Z.Messages.PAGINATION_NEXT,children:(0,r.jsx)(f.Z,{className:b().arrow,direction:f.Z.Directions.RIGHT})})]})};return n}(i.PureComponent);S.defaultProps={includeHitboxPadding:!0};var N=function(e){j(n,e);var t=I(n);function n(e){v(this,n);var r;(r=t.call(this,e)).timer=new s.Xp;r.getCurrentDirection=function(){return r.state.direction};r.nextItem=function(){
|
|
var e=r.props.items;r.changeItem(e,1)};r.previousItem=function(){var e=r.props.items;r.changeItem(e,-1)};r.handleSetItem=function(e){var t=r.state.visibleIndex,n=r.props.items;r.changeItem(n,e-t)};r.handleMouseEnter=function(){r.setState({hovered:!0})};r.handleMouseLeave=function(){r.setState({hovered:!1})};r.handleIntentionalChange=function(e,t,n){var i=r.props,o=i.items,a=i.onIntentionalChange;return null==a?void 0:a(o[t],e,t,n)};r.state={visibleIndex:!0===e.randomize?c().random(0,e.items.length-1):0,direction:h.n.LEFT,hovered:!1};return r}var i=n.prototype;i.componentDidMount=function(){this.props.paused||this.state.hovered||this.startTimer()};i.componentWillUnmount=function(){this.stopTimer()};i.componentDidUpdate=function(e,t){var n=function(e,t){return!e.paused&&!t.hovered},r=n(this.props,this.state),i=n(e,t);r&&!i?this.startTimer():!r&&i&&this.stopTimer();var o=this.props.items;null==o[this.state.visibleIndex]&&this.changeItem(o,1)};i.startTimer=function(){
|
|
null!=this.props.delay&&this.timer.start(this.props.delay,this.nextItem)};i.stopTimer=function(){null!=this.props.delay&&this.timer.stop()};i.changeItem=function(e,t){var n=this.state.visibleIndex+t;n<0?n=e.length-1:n>e.length-1&&(n=0);var r=this.props.onChangeItem;null==r||r(e[n],this.state.visibleIndex,n);var i=t>0?h.n.LEFT:h.n.RIGHT;this.setState({visibleIndex:n,direction:i});return n};i.render=function(){var e=this,t=this.props,n=t.items,i=t.renderItem,o=t.className,l=t.paginationClassName,c=t.paginationArrowClassName,s=t.themedPagination,u=t.includeHitboxPadding,d=t.style,f=t.aspectRatio,m=this.state.visibleIndex;return(0,r.jsxs)("div",{className:a()(b().root,o),style:d,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave,children:[(0,r.jsx)(p.Z,{aspectRatio:f,children:(0,r.jsx)(h.Z,{step:m,direction:this.getCurrentDirection(),className:b().carousel,children:i(n[m],m)})}),n.length>1&&(0,r.jsx)(S,{className:a()(l,s?b().themedPagination:b().pagination),
|
|
arrowClassName:c,includeHitboxPadding:u,current:m,count:n.length,onChangePage:function(t){return e.changeItem(n,t)},onSetItem:this.handleSetItem,onIntentionalChange:this.handleIntentionalChange})]})};return n}(i.PureComponent);N.defaultProps={aspectRatio:16/9};const R=N},965309:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});var r=n(785893),i=(n(667294),n(294184)),o=n.n(i),a=n(93800),l=n.n(a);function c(e){var t=e.children,n=e.tag,i=e.className;n=null!=n?n:"h3";return(0,r.jsx)(n,{className:o()(l().title,i),children:t})}},45984:(e,t,n)=>{"use strict";n.d(t,{Z:()=>m});var r=n(785893),i=n(667294),o=n(513328);function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function c(e){c=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return c(e)}function s(e,t){t=null!=t?t:{}
|
|
;Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function u(e,t){return!t||"object"!==f(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function d(e,t){d=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return d(e,t)}var f=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};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{
|
|
Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!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 u(this,n)}}var h=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&&d(e,t)}(n,e);var t=p(n);function n(){a(this,n);var e;(e=t.apply(this,arguments)).timer=new o.Xp;e.state={hovered:!1};e.handlePause=function(){e.state.hovered||e.setState({hovered:!0})};e.handleResume=function(){e.setState({hovered:!1})};return e}var i=n.prototype;i.componentDidMount=function(){var e=this.props,t=e.pauseOnHover,n=e.disable,r=this.state.hovered&&t;n||r||this.startTimer()};i.componentWillUnmount=function(){this.stopTimer()};i.componentDidUpdate=function(e,t){
|
|
var n=this.props,r=function(e,t){return!(e.disable||t.hovered&&e.pauseOnHover)},i=r(n,this.state),o=r(e,t);i&&!o||e.interval!==n.interval?this.startTimer():!i&&o&&this.stopTimer()};i.startTimer=function(){var e=this.props,t=e.interval,n=e.onInterval;e.disable||this.timer.start(t,(function(){n()}))};i.stopTimer=function(){this.timer.stop()};i.render=function(){var e=this.props,t=e.children,n=e.className,i=e.disable?null:{onMouseEnter:this.handlePause,onFocus:this.handlePause,onMouseLeave:this.handleResume,onBlur:this.handleResume};return(0,r.jsx)("div",s(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){l(e,t,n[t])}))}return e}({},i),{className:n,children:t}))};n.getDerivedStateFromProps=function(e){return e.disable?{hovered:!1}:null}
|
|
;return n}(i.Component);h.defaultProps={disable:!1,pauseOnHover:!1};const m=h},749266:(e,t,n)=>{"use strict";n.d(t,{Z:()=>T});var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(120053),c=n.n(l),s=n(91174),u=n(707197),d=n(25978),f=n(965309),p=n(944408),h=n.n(p),m=n(333286),y=n.n(m);function g(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function b(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function v(e){v=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return v(e)}function O(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){b(e,t,n[t])}))}return e}function j(e,t){t=null!=t?t:{}
|
|
;Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function C(e,t){return!t||"object"!==I(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function _(e,t){_=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return _(e,t)}var P,I=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function x(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{
|
|
Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){var n,r=v(e);if(t){var i=v(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return C(this,n)}}var E=new RegExp("https?://".concat(null!==(P=window.GLOBAL_ENV.CDN_HOST)&&void 0!==P?P:""));function w(e){return"string"==typeof e.content?e.content:R(e.content)}var S=j(O({},c().defaultRules),{heading:j(O({},c().defaultRules.heading),{react:function(e,t,n){var i="h".concat(e.level);return(0,r.jsx)(f.Z,{tag:i,children:t(e.content,n)},n.key)}}),paragraph:j(O({},c().defaultRules.paragraph),{react:function(e,t,n){return(0,r.jsx)("div",{className:h().paragraph,children:t(e.content,n)},n.key)}}),strong:j(O({},c().defaultRules.strong),{order:6}),em:j(O({},c().defaultRules.em),{order:6}),u:j(O({},c().defaultRules.u),{order:5}),del:j(O({},c().defaultRules.del),{order:6}),link:j(O({},u.Z,(0,d.Z)({enableBuildOverrides:!1})),{order:6}),
|
|
blockQuote:j(O({},c().defaultRules.blockQuote),{react:function(e,t,n){return(0,r.jsx)("blockquote",{className:h().blockquote,children:w(e)},n.key)}}),image:j(O({},c().defaultRules.image),{order:6,match:function(e,t,n){var r=c().defaultRules.image;if(null==r||null==r.match)return!1;var i=r.match(e,t,n);if(null!=i&&Array.isArray(i)&&i.length>=3){var o=i[2];if("string"==typeof o)return null!=o.match(E)?i:null}return!1}}),inlineCode:j(O({},c().defaultRules.inlineCode),{order:6,react:function(e,t,n){return(0,r.jsx)("code",{className:h().codeInline,children:w(e)},n.key)}}),codeBlock:j(O({},c().defaultRules.codeBlock),{react:function(e,t,i){var o=function(){return(0,r.jsx)("pre",{children:(0,r.jsx)("code",{className:a()(y().scrollbarGhostHairline,"hljs"),children:w(e)})},i.key)};return(0,r.jsx)(s.GI,{createPromise:function(){return Promise.all([n.e(20637),n.e(11860)]).then(n.bind(n,455049))},webpackId:455049,renderFallback:o,render:function(t){
|
|
if(e.lang&&t.hasLanguage(e.lang)&&"string"==typeof e.content){var n=t.highlight(e.lang,e.content,!0);return null==n?o():(0,r.jsx)("pre",{children:(0,r.jsx)("code",{className:a()(y().scrollbarGhostHairline,"hljs",n.language),dangerouslySetInnerHTML:{__html:n.value}})},i.key)}return o()}},i.key)}})}),N=c().parserFor(S),R=c().reactFor(c().ruleOutput(S,"react")),A=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&&_(e,t)}(n,e);var t=x(n);function n(){g(this,n);return t.apply(this,arguments)}n.prototype.render=function(){var e=this.props,t=e.className,n=e.children,i=e.state,o=e.parser,l=(0,e.output)(o("".concat(n,"\n\n"),O({inline:!1},i)));return(0,r.jsx)("div",{className:a()(h().markdown,t),children:l})};return n}(i.PureComponent);A.rules=S;A.defaultProps={parser:N,output:R};const T=A},282898:(e,t,n)=>{
|
|
"use strict";n.d(t,{Z:()=>j});var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(707961),c=n(127661),s=n(361674),u=n(473708),d=n(357913),f=n.n(d);function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function m(e){m=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return m(e)}function y(e,t){return!t||"object"!==b(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function g(e,t){g=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return g(e,t)}var b=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof 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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){var n,r=m(e);if(t){var i=m(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return y(this,n)}}var O=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&&g(e,t)}(n,e);var t=v(n);function n(){p(this,n);var e;(e=t.apply(this,arguments))._textInputRef=i.createRef();e._containerRef=i.createRef();e.handleClear=function(){var t=e.props,n=t.onClear,r=t.forwardedRef,i=(null!=r?r:e._textInputRef).current;null!=i&&i.focus();null!=n&&n()};return e}n.prototype.render=function(){
|
|
var e=this.props,t=e.autoFocus,n=e.label,i=e.placeholder,o=e.searchTerm,d=e.inputClassName,p=e.className,h=e.onChange,m=e.onFocus,y=e.onBlur,g=e.onKeyPress,b=e.autoComplete,v=e.forwardedRef,O=e.closeIconClassName,j=e.searchIconClassName,C=e.cta,_=null!=o&&o.length>0,P=null!=v?v:this._textInputRef;return(0,r.jsx)(l.tEY,{focusTarget:P,ringTarget:this._containerRef,children:(0,r.jsxs)("div",{className:a()(f().searchBox,p),ref:this._containerRef,children:[(0,r.jsx)(l.oil,{inputRef:P,focusProps:{enabled:!1},name:"search",maxLength:100,className:f().searchBoxInputWrapper,inputClassName:a()(f().searchBoxInput,d),onChange:h,onFocus:m,onBlur:y,onKeyPress:g,value:_?o:"",placeholder:i,autoFocus:t,"aria-label":n,autoComplete:b?"on":"off"}),null!=C?(0,r.jsx)(l.xvT,{color:"text-muted",variant:"text-xs/normal",className:f().cta,children:C}):null,_?(0,r.jsx)(l.P3F,{onClick:this.handleClear,className:f().clear,"aria-label":u.Z.Messages.SEARCH_CLEAR,children:(0,r.jsx)(c.Z,{className:a()(f().clearIcon,O)
|
|
})}):(0,r.jsx)(s.Z,{className:a()(f().searchIcon,j),"aria-label":u.Z.Messages.SEARCH})]})})};return n}(i.Component);O.defaultProps={autoComplete:!1};const j=i.forwardRef((function(e,t){return(0,r.jsx)(O,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){h(e,t,n[t])}))}return e}({forwardedRef:t},e))}))},270307:(e,t,n)=>{"use strict";n.d(t,{n:()=>y,Z:()=>j});var r=n(785893),i=n(667294),o=n(294184),a=n.n(o),l=n(853158),c=n(443660),s=n(456663),u=n.n(s);function d(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function f(e){f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)};return f(e)}function p(e){
|
|
for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){d(e,t,n[t])}))}return e}function h(e,t){return!t||"object"!==g(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function m(e,t){m=Object.setPrototypeOf||function(e,t){e.__proto__=t;return e};return m(e,t)}var y,g=function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};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{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})));return!0}catch(e){return!1}}();return function(){
|
|
var n,r=f(e);if(t){var i=f(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return h(this,n)}}!function(e){e[e.RIGHT=-1]="RIGHT";e[e.LEFT=1]="LEFT"}(y||(y={}));var v={friction:7,tension:40,overshootClamping:!0},O=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&&m(e,t)}(n,e);var t=b(n);function n(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);var r;(r=t.call(this,e))._animated=new l.Z.Value(-1*e.direction);return r}var i=n.prototype;i.componentWillEnter=function(e){this._animated.setValue(-this.props.direction);l.Z.spring(this._animated,p({toValue:0},v)).start(e)};i.componentDidAppear=function(){this._animated.setValue(0)};i.componentWillLeave=function(e){l.Z.spring(this._animated,p({toValue:this.props.direction
|
|
},v)).start(e)};i.getStyle=function(){return l.Z.accelerate({transform:[{translateX:this._animated.interpolate({inputRange:[0,1],outputRange:["0%","-100%"]})}]})};i.render=function(){return(0,r.jsx)(l.Z.div,{style:this.getStyle(),className:u().item,children:this.props.children})};return n}(i.PureComponent);const j=function(e){var t=e.children,n=e.step,i=e.direction,o=e.className;return(0,r.jsx)(c.Z,{component:"div",className:a()(u().animator,o),children:(0,r.jsx)(O,{direction:i,children:t},n)})}},247729:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});var r=n(785893),i=(n(667294),n(633878));function o(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function a(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function l(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 c(e){var t=e.width,n=void 0===t?24:t,c=e.height,s=void 0===c?24:c,u=e.color,d=void 0===u?"currentColor":u,f=e.foreground,p=l(e,["width","height","color","foreground"]);return(0,r.jsx)("svg",a(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){
|
|
return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){o(e,t,n[t])}))}return e}({},(0,i.Z)(p)),{width:n,height:s,viewBox:"0 0 24 24",children:(0,r.jsxs)("g",{fill:"none",fillRule:"evenodd",children:[(0,r.jsx)("path",{className:f,fill:d,
|
|
d:"M5.79335761,5 L18.2066424,5 C19.7805584,5 21.0868816,6.21634264 21.1990185,7.78625885 L21.8575059,17.0050826 C21.9307825,18.0309548 21.1585512,18.9219909 20.132679,18.9952675 C20.088523,18.9984215 20.0442685,19 20,19 C18.8245863,19 17.8000084,18.2000338 17.5149287,17.059715 L17,15 L7,15 L6.48507125,17.059715 C6.19999155,18.2000338 5.1754137,19 4,19 C2.97151413,19 2.13776159,18.1662475 2.13776159,17.1377616 C2.13776159,17.0934931 2.1393401,17.0492386 2.1424941,17.0050826 L2.80098151,7.78625885 C2.91311838,6.21634264 4.21944161,5 5.79335761,5 Z M14.5,10 C15.3284271,10 16,9.32842712 16,8.5 C16,7.67157288 15.3284271,7 14.5,7 C13.6715729,7 13,7.67157288 13,8.5 C13,9.32842712 13.6715729,10 14.5,10 Z M18.5,13 C19.3284271,13 20,12.3284271 20,11.5 C20,10.6715729 19.3284271,10 18.5,10 C17.6715729,10 17,10.6715729 17,11.5 C17,12.3284271 17.6715729,13 18.5,13 Z M6,9 L4,9 L4,11 L6,11 L6,13 L8,13 L8,11 L10,11 L10,9 L8,9 L8,7 L6,7 L6,9 Z"}),(0,r.jsx)("rect",{width:"24",height:"24"})]})}))}},
|
|
829389:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var r=n(785893),i=(n(667294),n(873308));function o(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function a(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function l(e){return(0,r.jsx)(i.Z,a(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))))
|
|
;r.forEach((function(t){o(e,t,n[t])}))}return e}({},e),{direction:i.Z.Directions.UP}))}},794547:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});var r=n(785893),i=(n(667294),n(633878));function o(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function a(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function l(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 c(e){var t=e.width,n=void 0===t?24:t,c=e.height,s=void 0===c?24:c,u=e.color,d=void 0===u?"currentColor":u,f=e.className,p=e.foreground,h=l(e,["width","height","color","className","foreground"]);return(0,r.jsx)("svg",a(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){o(e,t,n[t])}))}return e}({},(0,i.Z)(h)),{className:f,width:n,height:s,viewBox:"0 0 24 24",children:(0,r.jsx)("path",{className:p,fill:d,
|
|
d:"M12 10.9C11.39 10.9 10.9 11.39 10.9 12C10.9 12.61 11.39 13.1 12 13.1C12.61 13.1 13.1 12.61 13.1 12C13.1 11.39 12.61 10.9 12 10.9ZM12 2C6.48 2 2 6.48 2 12C2 17.52 6.48 22 12 22C17.52 22 22 17.52 22 12C22 6.48 17.52 2 12 2ZM14.19 14.19L6 18L9.81 9.81L18 6L14.19 14.19Z"})}))}},104630:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});var r=n(785893),i=(n(667294),n(633878));function o(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function a(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function l(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 c(e){var t=e.width,n=void 0===t?24:t,c=e.height,s=void 0===c?24:c,u=e.color,d=void 0===u?"currentColor":u,f=e.foreground,p=l(e,["width","height","color","foreground"]);return(0,r.jsx)("svg",a(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){o(e,t,n[t])}))}return e}({},(0,i.Z)(p)),{width:n,height:s,viewBox:"0 0 24 24",children:(0,r.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",className:f,
|
|
d:"M16.002 8.00598C16.002 10.211 14.208 12.006 12.002 12.006C9.79695 12.006 8.00195 10.211 8.00195 8.00598C8.00195 5.80098 9.79595 4.00598 12.002 4.00598C14.208 4.00598 16.002 5.80098 16.002 8.00598ZM4.00195 19.006C4.00195 15.473 7.29195 13.006 12.002 13.006C16.713 13.006 20.002 15.473 20.002 19.006V20.006H4.00195V19.006Z",fill:d})}))}},853039:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});var r=n(785893),i=(n(667294),n(633878));function o(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function a(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))
|
|
;return e}function l(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 c(e){var t=e.width,n=void 0===t?24:t,c=e.height,s=void 0===c?24:c,u=e.color,d=void 0===u?"currentColor":u,f=e.foreground,p=l(e,["width","height","color","foreground"]);return(0,r.jsx)("svg",a(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){o(e,t,n[t])}))}return e}({},(0,i.Z)(p)),{width:n,height:s,viewBox:"0 0 24 24",children:(0,r.jsxs)("g",{
|
|
fill:"none",className:f,children:[(0,r.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12 22C12.4883 22 12.9684 21.965 13.438 21.8974C12.5414 20.8489 12 19.4877 12 18C12 17.6593 12.0284 17.3252 12.083 17H6V16.0244C6 14.0732 10 13 12 13C12.6215 13 13.436 13.1036 14.2637 13.305C15.2888 12.4882 16.5874 12 18 12C19.4877 12 20.8489 12.5414 21.8974 13.438C21.965 12.9684 22 12.4883 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22ZM12 12C13.66 12 15 10.66 15 9C15 7.34 13.66 6 12 6C10.34 6 9 7.34 9 9C9 10.66 10.34 12 12 12Z",fill:d}),(0,r.jsx)("path",{d:"M18 22C20.2091 22 22 20.2091 22 18C22 15.7909 20.2091 14 18 14C15.7909 14 14 15.7909 14 18C14 20.2091 15.7909 22 18 22Z",fill:d})]})}))}},491275:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});var r=n(785893),i=(n(667294),n(633878));function o(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function a(e,t){t=null!=t?t:{}
|
|
;Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function l(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 c(e){var t=e.width,n=void 0===t?16:t,c=e.height,s=void 0===c?16:c,u=e.color,d=void 0===u?"currentColor":u,f=e.foreground,p=l(e,["width","height","color","foreground"]);return(0,
|
|
r.jsx)("svg",a(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){o(e,t,n[t])}))}return e}({},(0,i.Z)(p)),{width:n,height:s,viewBox:"0 0 24 24",children:(0,r.jsxs)("g",{fill:"none",fillRule:"evenodd",children:[(0,r.jsx)("path",{fill:d,className:f,fillRule:"nonzero",d:"M0.5,0 L0.5,1.5 C0.5,5.65 2.71,9.28 6,11.3 L6,16 L21,16 L21,14 C21,11.34 15.67,10 13,10 C13,10 12.83,10 12.75,10 C8,10 4,6 4,1.5 L4,0 L0.5,0 Z M13,0 C10.790861,0 9,1.790861 9,4 C9,6.209139 10.790861,8 13,8 C15.209139,8 17,6.209139 17,4 C17,1.790861 15.209139,0 13,0 Z",transform:"translate(2 4)"}),(0,r.jsx)("path",{d:"M0,0 L24,0 L24,24 L0,24 L0,0 Z M0,0 L24,0 L24,24 L0,24 L0,0 Z M0,0 L24,0 L24,24 L0,24 L0,0 Z"})]})}))}},755284:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c})
|
|
;var r=n(785893),i=(n(667294),n(633878));function o(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function a(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function l(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 c(e){var t=e.width,n=void 0===t?24:t,c=e.height,s=void 0===c?24:c,u=e.color,d=void 0===u?"currentColor":u,f=e.className,p=e.foreground,h=l(e,["width","height","color","className","foreground"]);return(0,r.jsx)("svg",a(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){o(e,t,n[t])}))}return e}({},(0,i.Z)(h)),{className:f,width:n,height:s,viewBox:"0 0 24 24",children:(0,r.jsx)("path",{className:p,fill:d,
|
|
d:"M12 2C6.48 2 2 6.48 2 12C2 17.52 6.48 22 12 22C17.52 22 22 17.52 22 12C22 6.48 17.52 2 12 2ZM11 19.93C7.05 19.44 4 16.08 4 12C4 11.38 4.08 10.79 4.21 10.21L9 15V16C9 17.1 9.9 18 11 18V19.93ZM17.9 17.39C17.64 16.58 16.9 16 16 16H15V13C15 12.45 14.55 12 14 12H8V10H10C10.55 10 11 9.55 11 9V7H13C14.1 7 15 6.1 15 5V4.59C17.93 5.78 20 8.65 20 12C20 14.08 19.2 15.97 17.9 17.39Z"})}))}},707073:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});var r=n(785893),i=(n(667294),n(633878));function o(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n;return e}function a(e,t){t=null!=t?t:{};Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):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}(Object(t)).forEach((function(n){
|
|
Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}));return e}function l(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 c(e){var t=e.width,n=void 0===t?24:t,c=e.height,s=void 0===c?24:c,u=e.color,d=void 0===u?"currentColor":u,f=e.className,p=e.foreground,h=l(e,["width","height","color","className","foreground"]);return(0,r.jsx)("svg",a(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))));r.forEach((function(t){o(e,t,n[t])}))}
|
|
return e}({},(0,i.Z)(h)),{className:f,width:n,height:s,viewBox:"0 0 24 24",children:(0,r.jsx)("path",{className:p,fill:d,fillRule:"evenodd",clipRule:"evenodd",d:"M16.781 2.27293L14.081 5.7126H9.919L7.219 2.27293L8.781 1L12 5.10008L15.219 1L16.781 2.27293ZM4 6.73175H20C21.1 6.73175 22 7.649 22 8.77007V18.9617C22 20.0828 21.1 21 20 21H4C2.9 21 2 20.0828 2 18.9617V8.77007C2 7.649 2.9 6.73175 4 6.73175ZM4 18.9617H16V8.77007H4V18.9617ZM18 16.4138C18 16.9764 18.448 17.4329 19 17.4329C19.552 17.4329 20 16.9764 20 16.4138C20 15.8512 19.552 15.3946 19 15.3946C18.448 15.3946 18 15.8512 18 16.4138ZM18 11.318C18 11.8806 18.448 12.3371 19 12.3371C19.552 12.3371 20 11.8806 20 11.318C20 10.7554 19.552 10.2988 19 10.2988C18.448 10.2988 18 10.7554 18 11.318Z"})}))}}}]);
|
|
//# sourceMappingURL=76734cdd20782e55a5d9.js.map
|