@bynder/compact-view 2.4.1 → 2.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -1,7 +1,26 @@
1
1
 
2
2
  /*
3
- * bynder-compactview v2.4.1
4
- * (c) 2021 Bynder
3
+ * bynder-compactview v2.6.0
4
+ * (c) 2022 Bynder
5
5
  */
6
6
 
7
- import{createContext as e,createElement as t,useState as n,useLayoutEffect as r,useRef as o,useEffect as i,useContext as a,forwardRef as s,useMemo as u,Component as c,useCallback as l,Fragment as d,memo as f}from"react";import{createPortal as v}from"react-dom";var p="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function h(e,t,n){return e(n={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}()}},n.exports),n.exports}var m=function(e){return e&&e.Math==Math&&e},g=m("object"==typeof globalThis&&globalThis)||m("object"==typeof window&&window)||m("object"==typeof self&&self)||m("object"==typeof p&&p)||Function("return this")(),b=function(e){try{return!!e()}catch(e){return!0}},x=!b((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),y={}.propertyIsEnumerable,w=Object.getOwnPropertyDescriptor,k={f:w&&!y.call({1:2},1)?function(e){var t=w(this,e);return!!t&&t.enumerable}:y},N=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},C={}.toString,S=function(e){return C.call(e).slice(8,-1)},_="".split,L=b((function(){return!Object("z").propertyIsEnumerable(0)}))?function(e){return"String"==S(e)?_.call(e,""):Object(e)}:Object,A=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e},T=function(e){return L(A(e))},O=function(e){return"object"==typeof e?null!==e:"function"==typeof e},M=function(e,t){if(!O(e))return e;var n,r;if(t&&"function"==typeof(n=e.toString)&&!O(r=n.call(e)))return r;if("function"==typeof(n=e.valueOf)&&!O(r=n.call(e)))return r;if(!t&&"function"==typeof(n=e.toString)&&!O(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")},U={}.hasOwnProperty,I=function(e,t){return U.call(e,t)},E=g.document,j=O(E)&&O(E.createElement),z=function(e){return j?E.createElement(e):{}},q=!x&&!b((function(){return 7!=Object.defineProperty(z("div"),"a",{get:function(){return 7}}).a})),P=Object.getOwnPropertyDescriptor,G={f:x?P:function(e,t){if(e=T(e),t=M(t,!0),q)try{return P(e,t)}catch(e){}if(I(e,t))return N(!k.f.call(e,t),e[t])}},Q=function(e){if(!O(e))throw TypeError(String(e)+" is not an object");return e},R=Object.defineProperty,F={f:x?R:function(e,t,n){if(Q(e),t=M(t,!0),Q(n),q)try{return R(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},B=x?function(e,t,n){return F.f(e,t,N(1,n))}:function(e,t,n){return e[t]=n,e},H=function(e,t){try{B(g,e,t)}catch(n){g[e]=t}return t},V=g["__core-js_shared__"]||H("__core-js_shared__",{}),D=Function.toString;"function"!=typeof V.inspectSource&&(V.inspectSource=function(e){return D.call(e)});var $,W,Y,J=V.inspectSource,X=g.WeakMap,K="function"==typeof X&&/native code/.test(J(X)),Z=h((function(e){(e.exports=function(e,t){return V[e]||(V[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.6.5",mode:"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})})),ee=0,te=Math.random(),ne=function(e){return"Symbol("+String(void 0===e?"":e)+")_"+(++ee+te).toString(36)},re=Z("keys"),oe=function(e){return re[e]||(re[e]=ne(e))},ie={},ae=g.WeakMap;if(K){var se=new ae,ue=se.get,ce=se.has,le=se.set;$=function(e,t){return le.call(se,e,t),t},W=function(e){return ue.call(se,e)||{}},Y=function(e){return ce.call(se,e)}}else{var de=oe("state");ie[de]=!0,$=function(e,t){return B(e,de,t),t},W=function(e){return I(e,de)?e[de]:{}},Y=function(e){return I(e,de)}}var fe,ve={set:$,get:W,has:Y,enforce:function(e){return Y(e)?W(e):$(e,{})},getterFor:function(e){return function(t){var n;if(!O(t)||(n=W(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return n}}},pe=h((function(e){var t=ve.get,n=ve.enforce,r=String(String).split("String");(e.exports=function(e,t,o,i){var a=!!i&&!!i.unsafe,s=!!i&&!!i.enumerable,u=!!i&&!!i.noTargetGet;"function"==typeof o&&("string"!=typeof t||I(o,"name")||B(o,"name",t),n(o).source=r.join("string"==typeof t?t:"")),e!==g?(a?!u&&e[t]&&(s=!0):delete e[t],s?e[t]=o:B(e,t,o)):s?e[t]=o:H(t,o)})(Function.prototype,"toString",(function(){return"function"==typeof this&&t(this).source||J(this)}))})),he=g,me=function(e){return"function"==typeof e?e:void 0},ge=function(e,t){return arguments.length<2?me(he[e])||me(g[e]):he[e]&&he[e][t]||g[e]&&g[e][t]},be=Math.ceil,xe=Math.floor,ye=function(e){return isNaN(e=+e)?0:(e>0?xe:be)(e)},we=Math.min,ke=function(e){return e>0?we(ye(e),9007199254740991):0},Ne=Math.max,Ce=Math.min,Se=function(e){return function(t,n,r){var o,i=T(t),a=ke(i.length),s=function(e,t){var n=ye(e);return n<0?Ne(n+t,0):Ce(n,t)}(r,a);if(e&&n!=n){for(;a>s;)if((o=i[s++])!=o)return!0}else for(;a>s;s++)if((e||s in i)&&i[s]===n)return e||s||0;return!e&&-1}},_e=(Se(!0),Se(!1)),Le=function(e,t){var n,r=T(e),o=0,i=[];for(n in r)!I(ie,n)&&I(r,n)&&i.push(n);for(;t.length>o;)I(r,n=t[o++])&&(~_e(i,n)||i.push(n));return i},Ae=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],Te=Ae.concat("length","prototype"),Oe={f:Object.getOwnPropertyNames||function(e){return Le(e,Te)}},Me={f:Object.getOwnPropertySymbols},Ue=ge("Reflect","ownKeys")||function(e){var t=Oe.f(Q(e)),n=Me.f;return n?t.concat(n(e)):t},Ie=function(e,t){for(var n=Ue(t),r=F.f,o=G.f,i=0;i<n.length;i++){var a=n[i];I(e,a)||r(e,a,o(t,a))}},Ee=/#|\.prototype\./,je=function(e,t){var n=qe[ze(e)];return n==Ge||n!=Pe&&("function"==typeof t?b(t):!!t)},ze=je.normalize=function(e){return String(e).replace(Ee,".").toLowerCase()},qe=je.data={},Pe=je.NATIVE="N",Ge=je.POLYFILL="P",Qe=je,Re=G.f,Fe=function(e,t,n){if(function(e){if("function"!=typeof e)throw TypeError(String(e)+" is not a function")}(e),void 0===t)return e;switch(n){case 0:return function(){return e.call(t)};case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,o){return e.call(t,n,r,o)}}return function(){return e.apply(t,arguments)}},Be=Array.isArray||function(e){return"Array"==S(e)},He=!!Object.getOwnPropertySymbols&&!b((function(){return!String(Symbol())})),Ve=He&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,De=Z("wks"),$e=g.Symbol,We=Ve?$e:$e&&$e.withoutSetter||ne,Ye=function(e){return I(De,e)||(He&&I($e,e)?De[e]=$e[e]:De[e]=We("Symbol."+e)),De[e]},Je=Ye("species"),Xe=function(e,t){var n;return Be(e)&&("function"!=typeof(n=e.constructor)||n!==Array&&!Be(n.prototype)?O(n)&&null===(n=n[Je])&&(n=void 0):n=void 0),new(void 0===n?Array:n)(0===t?0:t)},Ke=[].push,Ze=function(e){var t=1==e,n=2==e,r=3==e,o=4==e,i=6==e,a=5==e||i;return function(s,u,c,l){for(var d,f,v=Object(A(s)),p=L(v),h=Fe(u,c,3),m=ke(p.length),g=0,b=l||Xe,x=t?b(s,m):n?b(s,0):void 0;m>g;g++)if((a||g in p)&&(f=h(d=p[g],g,v),e))if(t)x[g]=f;else if(f)switch(e){case 3:return!0;case 5:return d;case 6:return g;case 2:Ke.call(x,d)}else if(o)return!1;return i?-1:r||o?o:x}},et={forEach:Ze(0),map:Ze(1),filter:Ze(2),some:Ze(3),every:Ze(4),find:Ze(5),findIndex:Ze(6)},tt=Object.keys||function(e){return Le(e,Ae)},nt=x?Object.defineProperties:function(e,t){Q(e);for(var n,r=tt(t),o=r.length,i=0;o>i;)F.f(e,n=r[i++],t[n]);return e},rt=ge("document","documentElement"),ot=oe("IE_PROTO"),it=function(){},at=function(e){return"<script>"+e+"<\/script>"},st=function(){try{fe=document.domain&&new ActiveXObject("htmlfile")}catch(e){}var e,t;st=fe?function(e){e.write(at("")),e.close();var t=e.parentWindow.Object;return e=null,t}(fe):((t=z("iframe")).style.display="none",rt.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(at("document.F=Object")),e.close(),e.F);for(var n=Ae.length;n--;)delete st.prototype[Ae[n]];return st()};ie[ot]=!0;var ut=Object.create||function(e,t){var n;return null!==e?(it.prototype=Q(e),n=new it,it.prototype=null,n[ot]=e):n=st(),void 0===t?n:nt(n,t)},ct=Ye("unscopables"),lt=Array.prototype;null==lt[ct]&&F.f(lt,ct,{configurable:!0,value:ut(null)});var dt=Object.defineProperty,ft={},vt=function(e){throw e},pt=et.find,ht=!0,mt=function(e,t){if(I(ft,"find"))return ft.find;t||(t={});var n=[].find,r=!!I(t,"ACCESSORS")&&t.ACCESSORS,o=I(t,0)?t[0]:vt,i=I(t,1)?t[1]:void 0;return ft.find=!!n&&!b((function(){if(r&&!x)return!0;var e={length:-1};r?dt(e,1,{enumerable:!0,get:vt}):e[1]=1,n.call(e,o,i)}))}();"find"in[]&&Array(1).find((function(){ht=!1})),function(e,t){var n,r,o,i,a,s=e.target,u=e.global,c=e.stat;if(n=u?g:c?g[s]||H(s,{}):(g[s]||{}).prototype)for(r in t){if(i=t[r],o=e.noTargetGet?(a=Re(n,r))&&a.value:n[r],!Qe(u?r:s+(c?".":"#")+r,e.forced)&&void 0!==o){if(typeof i==typeof o)continue;Ie(i,o)}(e.sham||o&&o.sham)&&B(i,"sham",!0),pe(n,r,i,e)}}({target:"Array",proto:!0,forced:ht||!mt},{find:function(e){return pt(this,e,arguments.length>1?arguments[1]:void 0)}}),lt[ct].find=!0;var gt=Function.call;function bt(e,t){return t.tag=e,t}Fe(gt,g.Array.prototype.find,void 0),function(){if("object"==typeof window)if("IntersectionObserver"in window&&"IntersectionObserverEntry"in window&&"intersectionRatio"in window.IntersectionObserverEntry.prototype)"isIntersecting"in window.IntersectionObserverEntry.prototype||Object.defineProperty(window.IntersectionObserverEntry.prototype,"isIntersecting",{get:function(){return this.intersectionRatio>0}});else{var e=window.document;n.prototype.THROTTLE_TIMEOUT=100,n.prototype.POLL_INTERVAL=null,n.prototype.USE_MUTATION_OBSERVER=!0,n.prototype.observe=function(e){if(!this._observationTargets.some((function(t){return t.element==e}))){if(!e||1!=e.nodeType)throw new Error("target must be an Element");this._registerInstance(),this._observationTargets.push({element:e,entry:null}),this._monitorIntersections(),this._checkForIntersections()}},n.prototype.unobserve=function(e){this._observationTargets=this._observationTargets.filter((function(t){return t.element!=e})),this._observationTargets.length||(this._unmonitorIntersections(),this._unregisterInstance())},n.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorIntersections(),this._unregisterInstance()},n.prototype.takeRecords=function(){var e=this._queuedEntries.slice();return this._queuedEntries=[],e},n.prototype._initThresholds=function(e){var t=e||[0];return Array.isArray(t)||(t=[t]),t.sort().filter((function(e,t,n){if("number"!=typeof e||isNaN(e)||e<0||e>1)throw new Error("threshold must be a number between 0 and 1 inclusively");return e!==n[t-1]}))},n.prototype._parseRootMargin=function(e){var t=(e||"0px").split(/\s+/).map((function(e){var t=/^(-?\d*\.?\d+)(px|%)$/.exec(e);if(!t)throw new Error("rootMargin must be specified in pixels or percent");return{value:parseFloat(t[1]),unit:t[2]}}));return t[1]=t[1]||t[0],t[2]=t[2]||t[0],t[3]=t[3]||t[1],t},n.prototype._monitorIntersections=function(){this._monitoringIntersections||(this._monitoringIntersections=!0,this.POLL_INTERVAL?this._monitoringInterval=setInterval(this._checkForIntersections,this.POLL_INTERVAL):(r(window,"resize",this._checkForIntersections,!0),r(e,"scroll",this._checkForIntersections,!0),this.USE_MUTATION_OBSERVER&&"MutationObserver"in window&&(this._domObserver=new MutationObserver(this._checkForIntersections),this._domObserver.observe(e,{attributes:!0,childList:!0,characterData:!0,subtree:!0}))))},n.prototype._unmonitorIntersections=function(){this._monitoringIntersections&&(this._monitoringIntersections=!1,clearInterval(this._monitoringInterval),this._monitoringInterval=null,o(window,"resize",this._checkForIntersections,!0),o(e,"scroll",this._checkForIntersections,!0),this._domObserver&&(this._domObserver.disconnect(),this._domObserver=null))},n.prototype._checkForIntersections=function(){var e=this._rootIsInDom(),n=e?this._getRootRect():{top:0,bottom:0,left:0,right:0,width:0,height:0};this._observationTargets.forEach((function(r){var o=r.element,a=i(o),s=this._rootContainsTarget(o),u=r.entry,c=e&&s&&this._computeTargetAndRootIntersection(o,n),l=r.entry=new t({time:window.performance&&performance.now&&performance.now(),target:o,boundingClientRect:a,rootBounds:n,intersectionRect:c});u?e&&s?this._hasCrossedThreshold(u,l)&&this._queuedEntries.push(l):u&&u.isIntersecting&&this._queuedEntries.push(l):this._queuedEntries.push(l)}),this),this._queuedEntries.length&&this._callback(this.takeRecords(),this)},n.prototype._computeTargetAndRootIntersection=function(t,n){if("none"!=window.getComputedStyle(t).display){for(var r,o,a,u,c,l,d,f,v=i(t),p=s(t),h=!1;!h;){var m=null,g=1==p.nodeType?window.getComputedStyle(p):{};if("none"==g.display)return;if(p==this.root||p==e?(h=!0,m=n):p!=e.body&&p!=e.documentElement&&"visible"!=g.overflow&&(m=i(p)),m&&(r=m,o=v,void 0,void 0,void 0,void 0,void 0,void 0,a=Math.max(r.top,o.top),u=Math.min(r.bottom,o.bottom),c=Math.max(r.left,o.left),f=u-a,!(v=(d=(l=Math.min(r.right,o.right))-c)>=0&&f>=0&&{top:a,bottom:u,left:c,right:l,width:d,height:f})))break;p=s(p)}return v}},n.prototype._getRootRect=function(){var t;if(this.root)t=i(this.root);else{var n=e.documentElement,r=e.body;t={top:0,left:0,right:n.clientWidth||r.clientWidth,width:n.clientWidth||r.clientWidth,bottom:n.clientHeight||r.clientHeight,height:n.clientHeight||r.clientHeight}}return this._expandRectByRootMargin(t)},n.prototype._expandRectByRootMargin=function(e){var t=this._rootMarginValues.map((function(t,n){return"px"==t.unit?t.value:t.value*(n%2?e.width:e.height)/100})),n={top:e.top-t[0],right:e.right+t[1],bottom:e.bottom+t[2],left:e.left-t[3]};return n.width=n.right-n.left,n.height=n.bottom-n.top,n},n.prototype._hasCrossedThreshold=function(e,t){var n=e&&e.isIntersecting?e.intersectionRatio||0:-1,r=t.isIntersecting?t.intersectionRatio||0:-1;if(n!==r)for(var o=0;o<this.thresholds.length;o++){var i=this.thresholds[o];if(i==n||i==r||i<n!=i<r)return!0}},n.prototype._rootIsInDom=function(){return!this.root||a(e,this.root)},n.prototype._rootContainsTarget=function(t){return a(this.root||e,t)},n.prototype._registerInstance=function(){},n.prototype._unregisterInstance=function(){},window.IntersectionObserver=n,window.IntersectionObserverEntry=t}function t(e){this.time=e.time,this.target=e.target,this.rootBounds=e.rootBounds,this.boundingClientRect=e.boundingClientRect,this.intersectionRect=e.intersectionRect||{top:0,bottom:0,left:0,right:0,width:0,height:0},this.isIntersecting=!!e.intersectionRect;var t=this.boundingClientRect,n=t.width*t.height,r=this.intersectionRect,o=r.width*r.height;this.intersectionRatio=n?Number((o/n).toFixed(4)):this.isIntersecting?1:0}function n(e,t){var n=t||{};if("function"!=typeof e)throw new Error("callback must be a function");if(n.root&&1!=n.root.nodeType)throw new Error("root must be an Element");this._checkForIntersections=function(e,t){var n=null;return function(){n||(n=setTimeout((function(){e(),n=null}),t))}}(this._checkForIntersections.bind(this),this.THROTTLE_TIMEOUT),this._callback=e,this._observationTargets=[],this._queuedEntries=[],this._rootMarginValues=this._parseRootMargin(n.rootMargin),this.thresholds=this._initThresholds(n.threshold),this.root=n.root||null,this.rootMargin=this._rootMarginValues.map((function(e){return e.value+e.unit})).join(" ")}function r(e,t,n,r){"function"==typeof e.addEventListener?e.addEventListener(t,n,r||!1):"function"==typeof e.attachEvent&&e.attachEvent("on"+t,n)}function o(e,t,n,r){"function"==typeof e.removeEventListener?e.removeEventListener(t,n,r||!1):"function"==typeof e.detatchEvent&&e.detatchEvent("on"+t,n)}function i(e){var t;try{t=e.getBoundingClientRect()}catch(e){}return t?(t.width&&t.height||(t={top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:t.right-t.left,height:t.bottom-t.top}),t):{top:0,bottom:0,left:0,right:0,width:0,height:0}}function a(e,t){for(var n=t;n;){if(n==e)return!0;n=s(n)}return!1}function s(e){var t=e.parentNode;return t&&11==t.nodeType&&t.host?t.host:t&&t.assignedSlot?t.assignedSlot.parentNode:t}}();var xt=["Invalid_argument",-3],yt=["Division_by_zero",-5];function wt(e,t,n){for(var r=new Array(n),o=0,i=t;o<n;)r[o]=e[i],o=o+1|0,i=i+1|0;return r}function kt(e,t){if(t<0||t>=e.length)throw[xt,"index out of bounds"];return e[t]}function Nt(e,t){for(;;){var n=t,r=e,o=r.length,i=0===o?1:o,a=i-n.length|0;if(0===a)return r.apply(null,n);if(!(a<0))return function(e,t){return function(n){return Nt(e,t.concat([n]))}}(r,n);t=wt(n,i,0|-a),e=r.apply(null,wt(n,0,i))}}function Ct(e,t){var n=e.length;return 1===n?e(t):function(e,t,n){switch(n){case 1:return e(t);case 2:return function(n){return e(t,n)};case 3:return function(n,r){return e(t,n,r)};case 4:return function(n,r,o){return e(t,n,r,o)};case 5:return function(n,r,o,i){return e(t,n,r,o,i)};case 6:return function(n,r,o,i,a){return e(t,n,r,o,i,a)};case 7:return function(n,r,o,i,a,s){return e(t,n,r,o,i,a,s)};default:return Nt(e,[t])}}(e,t,n)}function St(e){return 1===e.length?e:function(t){return Ct(e,t)}}function _t(e,t,n){var r=e.length;return 2===r?e(t,n):function(e,t,n,r){switch(r){case 1:return Nt(e(t),[n]);case 2:return e(t,n);case 3:return function(r){return e(t,n,r)};case 4:return function(r,o){return e(t,n,r,o)};case 5:return function(r,o,i){return e(t,n,r,o,i)};case 6:return function(r,o,i,a){return e(t,n,r,o,i,a)};case 7:return function(r,o,i,a,s){return e(t,n,r,o,i,a,s)};default:return Nt(e,[t,n])}}(e,t,n,r)}function Lt(e){return 2===e.length?e:function(t,n){return _t(e,t,n)}}function At(e,t,n,r){var o=e.length;return 3===o?e(t,n,r):function(e,t,n,r,o){switch(o){case 1:return Nt(e(t),[n,r]);case 2:return Nt(e(t,n),[r]);case 3:return e(t,n,r);case 4:return function(o){return e(t,n,r,o)};case 5:return function(o,i){return e(t,n,r,o,i)};case 6:return function(o,i,a){return e(t,n,r,o,i,a)};case 7:return function(o,i,a,s){return e(t,n,r,o,i,a,s)};default:return Nt(e,[t,n,r])}}(e,t,n,r,o)}function Tt(e,t,n,r,o){var i=e.length;return 4===i?e(t,n,r,o):function(e,t,n,r,o,i){switch(i){case 1:return Nt(e(t),[n,r,o]);case 2:return Nt(e(t,n),[r,o]);case 3:return Nt(e(t,n,r),[o]);case 4:return e(t,n,r,o);case 5:return function(i){return e(t,n,r,o,i)};case 6:return function(i,a){return e(t,n,r,o,i,a)};case 7:return function(i,a,s){return e(t,n,r,o,i,a,s)};default:return Nt(e,[t,n,r,o])}}(e,t,n,r,o,i)}function Ot(e,t,n,r,o,i){var a=e.length;return 5===a?e(t,n,r,o,i):function(e,t,n,r,o,i,a){switch(a){case 1:return Nt(e(t),[n,r,o,i]);case 2:return Nt(e(t,n),[r,o,i]);case 3:return Nt(e(t,n,r),[o,i]);case 4:return Nt(e(t,n,r,o),[i]);case 5:return e(t,n,r,o,i);case 6:return function(a){return e(t,n,r,o,i,a)};case 7:return function(a,s){return e(t,n,r,o,i,a,s)};default:return Nt(e,[t,n,r,o,i])}}(e,t,n,r,o,i,a)}function Mt(e,t,n,r,o,i,a){var s=e.length;return 6===s?e(t,n,r,o,i,a):function(e,t,n,r,o,i,a,s){switch(s){case 1:return Nt(e(t),[n,r,o,i,a]);case 2:return Nt(e(t,n),[r,o,i,a]);case 3:return Nt(e(t,n,r),[o,i,a]);case 4:return Nt(e(t,n,r,o),[i,a]);case 5:return Nt(e(t,n,r,o,i),[a]);case 6:return e(t,n,r,o,i,a);case 7:return function(s){return e(t,n,r,o,i,a,s)};default:return Nt(e,[t,n,r,o,i,a])}}(e,t,n,r,o,i,a,s)}xt.tag=248,yt.tag=248;var Ut={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},It=e&&e(Ut),Et=function(){return(Et=Object.assign||function(e){for(var t,n=arguments,r=1,o=arguments.length;r<o;r++)for(var i in t=n[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function jt(e){return function(n){return t(zt,Et({attr:Et({},e.attr)},n),function e(n){return n&&n.map((function(n,r){return t(n.tag,Et({key:r},n.attr),e(n.child))}))}(e.child))}}function zt(e){var n=function(n){var r,o=e.size||n.size||"1em";n.className&&(r=n.className),e.className&&(r=(r?r+" ":"")+e.className);var i=e.attr,a=e.title,s=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&(n[r[o]]=e[r[o]])}return n}(e,["attr","title"]);return t("svg",Et({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,i,s,{className:r,style:Et({color:e.color||n.color},n.style,e.style),height:o,width:o,xmlns:"http://www.w3.org/2000/svg"}),a&&t("title",null,a),e.children)};return void 0!==It?t(It.Consumer,null,(function(e){return n(e)})):n(Ut)}var qt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M19 12h-2v3h-3v2h5v-5zM7 9h3V7H5v5h2V9zm14-6H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02z"}}]})(e)};qt.displayName="MdAspectRatio";var Pt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M10.09 15.59L11.5 17l5-5-5-5-1.41 1.41L12.67 11H3v2h9.67l-2.58 2.59zM19 3H5c-1.11 0-2 .9-2 2v4h2V5h14v14H5v-4H3v4c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"}}]})(e)};Pt.displayName="MdExitToApp";var Gt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M17.63 5.84C17.27 5.33 16.67 5 16 5L5 5.01C3.9 5.01 3 5.9 3 7v10c0 1.1.9 1.99 2 1.99L16 19c.67 0 1.27-.33 1.63-.84L22 12l-4.37-6.16z"}}]})(e)};Gt.displayName="MdLabel";var Qt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M19 19H5V5h7V3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"}}]})(e)};Qt.displayName="MdOpenInNew";var Rt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"}}]})(e)};Rt.displayName="MdSearch";var Ft=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M17 10.5V7c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h12c.55 0 1-.45 1-1v-3.5l4 4v-11l-4 4z"}}]})(e)};Ft.displayName="MdVideocam";var Bt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3 9v6h4l5 5V4L7 9H3zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02zM14 3.23v2.06c2.89.86 5 3.54 5 6.71s-2.11 5.85-5 6.71v2.06c4.01-.91 7-4.49 7-8.77s-2.99-7.86-7-8.77z"}}]})(e)};Bt.displayName="MdVolumeUp";var Ht=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3 18h6v-2H3v2zM3 6v2h18V6H3zm0 7h12v-2H3v2z"}}]})(e)};Ht.displayName="MdSort";var Vt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M6 2c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6H6zm7 7V3.5L18.5 9H13z"}}]})(e)};Vt.displayName="MdInsertDriveFile";var Dt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"}}]})(e)};Dt.displayName="MdInsertPhoto";var $t=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"circle",attr:{cx:"12",cy:"12",r:"3.2"}},{tag:"path",attr:{d:"M9 2L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3.17L15 2H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5z"}}]})(e)};$t.displayName="MdPhotoCamera";var Wt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M22 16V4c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2zm-11-4l2.03 2.71L16 11l4 5H8l3-4zM2 6v14c0 1.1.9 2 2 2h14v-2H4V6H2z"}}]})(e)};Wt.displayName="MdPhotoLibrary";var Yt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3 17v2h6v-2H3zM3 5v2h10V5H3zm10 16v-2h8v-2h-8v-2h-2v6h2zM7 9v2H3v2h4v2h2V9H7zm14 4v-2H11v2h10zm-6-4h2V7h4V5h-4V3h-2v6z"}}]})(e)};Yt.displayName="MdTune";var Jt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M7 10l5 5 5-5z"}}]})(e)};Jt.displayName="MdArrowDropDown";var Xt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"}}]})(e)};Xt.displayName="MdCancel";var Kt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}}]})(e)};Kt.displayName="MdCheck";var Zt=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"}}]})(e)};Zt.displayName="MdChevronLeft";var en=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}}]})(e)};en.displayName="MdChevronRight";var tn=function(e){return jt({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}}]})(e)};tn.displayName="MdClose";var nn=[];function rn(e){if(void 0===e){var t=[nn,0];return t.tag=256,t}if(null!==e&&e[0]===nn){var n=e[1]+1|0,r=[nn,n];return r.tag=256,r}return e}function on(e){return null==e?void 0:rn(e)}function an(e){return null===e?void 0:rn(e)}function sn(e){if(null!==e&&e[0]===nn){var t=e[1];return 0===t?void 0:[nn,t-1|0]}return e}function un(e,t){if(t in e)return rn(e[t])}function cn(e){for(var t=Object.keys(e),n=t.length,r=new Array(n),o=0,i=n-1|0;o<=i;++o){var a=t[o];r[o]=[a,e[a]]}return r}function ln(e){for(var t=Object.keys(e),n=t.length,r=new Array(n),o=0,i=n-1|0;o<=i;++o)r[o]=e[t[o]];return r}function dn(e){for(var t={},n=0,r=e.length-1|0;n<=r;++n){var o=e[n];t[o[0]]=o[1]}return t}var fn={contents:void 0};function vn(e){var t=fn.contents;if(void 0!==t){var n=un(sn(t),e);return void 0!==n?""===n?e:n:e}return e}var pn={contents:0};function hn(e){var t=[e,(pn.contents=pn.contents+1,pn.contents)];return t.tag=248,t}var mn=hn("Caml_js_exceptions.Error");function gn(e){return function(e){if(void 0===e)return!1;if(248===e.tag)return!0;var t=e[0];return void 0!==t&&248===t.tag}(e)?e:[mn,e]}function bn(e){throw new Error(e)}function xn(e){switch(e){case 0:return"beforebegin";case 1:return"afterbegin";case 2:return"beforeend";case 3:return"afterend"}}function yn(e){var t=e-1|0;return t>11||t<0?12:t}function wn(e){return{nodeType:function(e){return yn(e.nodeType)}}}function kn(e){if(0===function(e){return yn(e.nodeType)}(e))return rn(e)}function Nn(e){return{asHtmlElement:function(e){return an(void 0!==(t=e).contentEditable?t:null);var t},ofNode:kn,insertAdjacentElement:function(e,t,n){return n.insertAdjacentElement(xn(e),t),0},insertAdjacentHTML:function(e,t,n){return n.insertAdjacentHTML(xn(e),t),0},insertAdjacentText:function(e,t,n){return n.insertAdjacentText(xn(e),t),0}}}var Cn=wn().nodeType,Sn=Object.freeze({__proto__:null,Impl:Nn,nodeType:Cn,asHtmlElement:function(e){return an(void 0!==(t=e).contentEditable?t:null);var t},ofNode:kn,insertAdjacentElement:function(e,t,n){return n.insertAdjacentElement(xn(e),t),0},insertAdjacentHTML:function(e,t,n){return n.insertAdjacentHTML(xn(e),t),0},insertAdjacentText:function(e,t,n){return n.insertAdjacentText(xn(e),t),0}}),_n=wn(),Ln=Nn(),An=(_n.nodeType,Ln.asHtmlElement,Ln.ofNode,Ln.insertAdjacentElement,Ln.insertAdjacentHTML,Ln.insertAdjacentText,Sn),Tn=function(e){return Array.prototype.slice.call(e.children)},On=function(e,t,n){return e.style.setProperty(t,n,""),e},Mn=function(e){return an(localStorage.getItem(e))},Un=function(e,t){return void 0!==t?(localStorage.setItem(e,t),0):(localStorage.removeItem(e),0)},In=window,En=window.location,jn=In.document,zn=function(e){return e>2147483647?2147483647:e<-2147483648?-2147483648:Math.ceil(e)};function qn(e,t){return e<t?-1:e===t?0:1}function Pn(e,t){return e===t?0:e<t?-1:1}function Gn(e,t,n,r,o){if(r<=t){for(var i=0,a=o-1|0;i<=a;++i)n[i+r|0]=e[i+t|0];return 0}for(var s=o-1|0;s>=0;--s)n[s+r|0]=e[s+t|0];return 0}function Qn(e,t){for(var n=e.length,r=new Array(n),o=0,i=n-1|0;o<=i;++o)r[o]=t(e[o]);return r}function Rn(e,t){return Qn(e,St(t))}function Fn(e,t){return function(e,t){for(var n=e.length,r=new Array(n),o=0,i=n-1|0;o<=i;++o)r[o]=t(o,e[o]);return r}(e,Lt(t))}function Bn(e,t){return function(e,t){for(var n=e.length,r=new Array(n),o=0,i=0,a=n-1|0;i<=a;++i){var s=e[i];t(s)&&(r[o]=s,o=o+1|0)}return r.length=o,r}(e,St(t))}function Hn(e,t){return function(e,t){for(var n=0,r=e.length-1|0;n<=r;++n)t(e[n]);return 0}(e,St(t))}function Vn(e,t){return function(e,t){for(var n=e,r=0,o=t,i=e.length;;){var a=r;if(a===i)return!1;if(o(n[a]))return!0;r=a+1|0}}(e,St(t))}function Dn(e,t){return function(e,t){for(var n=e.length,r=new Array(n),o=0,i=0,a=n-1|0;i<=a;++i){var s=t(e[i]);void 0!==s&&(r[o]=sn(s),o=o+1|0)}return r.length=o,r}(e,St(t))}function $n(e,t){return t.push(e),0}function Wn(e){return 0===e.length}var Yn=function(e,t){if(t>=0&&t<e.length)return rn(e[t])};function Jn(e,t){if(void 0!==e)return rn(t(sn(e)))}function Xn(e,t){return void 0!==e?sn(e):t}function Kn(e){return void 0!==e}function Zn(e,t,n){return function(e,t,n){return void 0!==e?void 0!==t&&n(sn(e),sn(t)):void 0===t}(e,t,Lt(n))}function er(e,t){return Jn(e,St(t))}function tr(e,t){return function(e,t){if(void 0!==e)return t(sn(e))}(e,St(t))}function nr(e,t){return Jn(e,St(t)),0}var rr=Xn,or=Zn;function ir(e,t){return void 0!==e?bt(0,[sn(e)]):bt(1,[t])}function ar(e,t){return void 0!==e?e:t}var sr=Xn,ur=Kn,cr=function(e){return void 0===e},lr=Zn,dr=function(e){return e.target.value},fr=function(e){if(void 0!==e){var t=e;switch(t){case"aif":return"https://d8ejoa1fys2rk.cloudfront.net/includes/img/placeholder/medium/aiff.jpg";case"m4a":return"https://d8ejoa1fys2rk.cloudfront.net/includes/img/placeholder/medium/m4r.jpg";case"aiff":case"avi":case"doc":case"docx":case"fla":case"indd":case"m4r":case"mov":case"mp3":case"mp4":case"mpeg":case"numbers":case"otf":case"pages":case"pdf":case"ppt":case"pptx":case"rar":case"ttf":case"txt":case"wav":case"webm":case"xls":case"xlsx":case"zip":break;default:return"https://d8ejoa1fys2rk.cloudfront.net/includes/img/common/no-image.png"}return"https://d8ejoa1fys2rk.cloudfront.net/includes/img/placeholder/medium/"+t+".jpg"}return"https://d8ejoa1fys2rk.cloudfront.net/includes/img/common/no-image.png"};function vr(e){return"https://"+e.replace(/^https?:\/\//i,"").replace(/\/+$/i,"")+"/"}var pr={ensureValidUrl:vr,getQueryParameter:function(e,t){t=t.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");var n=new RegExp("[\\?&]"+t+"=([^&#]*)").exec(e);return null===n?"":decodeURIComponent(n[1].replace(/\+/g," "))},extension:function(e){var t=function(e,t){var n=t.lastIndexOf(e);if(-1!==n)return t.slice(n+1|0)},n=sr(t("/",e),e);return t(".",n)},isBynderPortal:function(e){var t=vr(e)+"feeds/media/is-bynder-portal/";return fetch(t).then((function(e){var n=e.status,r=e.headers.get("Content-Type");return 200!==n||null===r||"application/json;charset=UTF-8"!==r?Promise.reject([xt,t]):Promise.resolve(!0)})).catch((function(e){return Promise.resolve(!1)}))}},hr=function(e,t,n){return(1!==e?t:n).replace("{}",String(e))},mr=" ",gr=function(e){return e.join(" ")},br=function(e,t){return e?t:""},xr=function(e){return void 0!==e?e:""},yr=function(e,t){return 16807*((t+20)%2147483647+2147483646)%2147483647%e},wr=function(e){for(var t=e.length,n=0,r=5381;;){var o=n;if(!(o<t))return r;r=((r<<5)+r|0)^e.charCodeAt(o),n=o+1|0}},kr=function(e){if(e<1)return"0 Bytes";var t,n=Math.floor(Math.log(e)/Math.log(1024)),r=Number((e/Math.pow(1024,n)).toFixed(1));switch(0|n){case 0:t="Bytes";break;case 1:t="kB";break;case 2:t="MB";break;case 3:t="GB";break;case 4:t="TB";break;case 5:t="PB";break;case 6:t="EB";break;case 7:t="ZB";break;case 8:t="YB";break;default:t=function(e){throw new RangeError("O_O")}()}return String(r)+" "+String(t)},Nr=function(e){return new Promise((function(e,t){return In.addEventListener("message",(function(t){return e(t)})),0}))};function Cr(e){var t=function(e,t){var i={contents:e},a={contents:[]},s=function(e,t,n){var r=void 0!==t?t:function(e,t){return Object.is(e,t)},o={contents:i.contents},s=function(t){var n=i.contents;return _t(r,n,o.contents)||(Ct(e,n),o.contents=n),0};return a.contents=a.contents.concat([s]),function(e){return a.contents=a.contents.filter((function(e){return e!==s})),0}},u=function(e,t,n,r){var o=void 0!==n?n:function(e,t){return Object.is(e,t)},s={contents:Ct(e,i.contents)},u=function(n){var r=Ct(e,i.contents);return _t(o,r,s.contents)||(Ct(t,r),s.contents=r),0};return a.contents=a.contents.concat([u]),function(e){return a.contents=a.contents.filter((function(e){return e!==u})),0}};return{getState:function(e){return i.contents},subscribe:s,subscribeWithSelector:u,dispatch:function(e){return i.contents=_t(t,i.contents,e),a.contents.forEach((function(e){return Ct(e,0)})),0},useStore:function(e,t){var o=n((function(){return 1}))[1];return r((function(){var t=s((function(e){return Ct(o,(function(e){return e+1|0}))}),e);return Ct(o,(function(e){return e+1|0})),function(e){return Ct(t,0)}}),[]),i.contents},useStoreWithSelector:function(e,t,a){var s=o(void 0),c=o(e),l=s.current,d=c.current,f=e===d&&void 0!==l?sn(l):Ct(e,i.contents);r((function(){s.current=rn(f)}),[f]),r((function(){c.current=e}),[e]);var v=n((function(){return 1}))[1];return r((function(){var n=u((function(e){return Ct(c.current,e)}),(function(e){return s.current=rn(e),Ct(v,(function(e){return e+1|0}))}),t);return s.current=rn(Ct(e,i.contents)),Ct(v,(function(e){return e+1|0})),function(e){return Ct(n,0)}}),[]),f}}}(e.initialState,e.reducer),i=t.getState,a=t.dispatch,s=function(e,t){return e===t};return{state:i,send:a,use:function(n){return _t(t.useStore,e.equal,0)},useWith:function(e,n){return At(t.useStoreWithSelector,n,void 0!==e?e:s,0)},subscribe:function(n){return At(t.subscribe,n,e.equal,0),0},subscribeWith:function(e,n,r){return Tt(t.subscribeWithSelector,n,r,void 0!==e?e:s,0),0}}}function Sr(e){if("number"!=typeof e)return e[0];switch(e){case 0:return"GET";case 1:return"HEAD";case 2:return"POST";case 3:return"PUT";case 4:return"DELETE";case 5:return"CONNECT";case 6:return"OPTIONS";case 7:return"TRACE";case 8:return"PATCH"}}function _r(e){switch(e){case 0:return"navigate";case 1:return"same-origin";case 2:return"no-cors";case 3:return"cors"}}function Lr(e){switch(e){case 0:return"omit";case 1:return"same-origin";case 2:return"include"}}function Ar(e){switch(e){case 0:return"default";case 1:return"no-store";case 2:return"reload";case 3:return"no-cache";case 4:return"force-cache";case 5:return"only-if-cached"}}function Tr(e){switch(e){case 0:return"follow";case 1:return"error";case 2:return"manual"}}function Or(e,t){if(void 0!==t)return rn(Ct(e,sn(t)))}var Mr=function(e,t,n,r,o,i,a,s,u,c,l,d){var f=void 0!==o?o:0,v=void 0!==c?c:"",p=Or(Tr,u),h=Or(Ar,s),m=Or(Lr,a),g=Or(_r,i),b=function(e){switch(e){case 0:return"";case 1:return"no-referrer";case 2:return"no-referrer-when-downgrade";case 3:return"same-origin";case 4:return"origin";case 5:return"strict-origin";case 6:return"origin-when-cross-origin";case 7:return"strict-origin-when-cross-origin";case 8:return"unsafe-url"}}(f),x=Or(Sr,e);return function(e){var o={};return void 0!==x&&(o.method=sn(x)),void 0!==t&&(o.headers=sn(t)),void 0!==n&&(o.body=sn(n)),void 0!==r&&(o.referrer=sn(r)),void 0!==b&&(o.referrerPolicy=sn(b)),void 0!==g&&(o.mode=sn(g)),void 0!==m&&(o.credentials=sn(m)),void 0!==h&&(o.cache=sn(h)),void 0!==p&&(o.redirect=sn(p)),void 0!==v&&(o.integrity=sn(v)),void 0!==l&&(o.keepalive=sn(l)),void 0!==d&&(o.signal=sn(d)),o}};function Ur(e,t,n,r){if(n<0||r<0||n>(t.length-r|0))throw[xt,"input"];return function(e){var t=function(){if("undefined"!=typeof globalThis)return globalThis;if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if("undefined"!=typeof global)return global;if(void 0!==this)return this;throw new Error("Unable to locate global `this`")}();if(void 0===t[e])throw new Error(e+" not polyfilled by BuckleScript yet\n");return t[e]}("caml_ml_input")(e,t,n,r)}hn("Pervasives.Exit"),hn("Array.Bottom");var Ir=hn("Json_decode.DecodeError");function Er(e){if("number"==typeof e)return e;throw[Ir,"Expected number, got "+JSON.stringify(e)]}function jr(e){var t=Er(e);if(function(e){return!!isFinite(e)&&Math.floor(e)===e}(t))return t;throw[Ir,"Expected integer, got "+JSON.stringify(e)]}function zr(e){if("string"==typeof e)return e;throw[Ir,"Expected string, got "+JSON.stringify(e)]}function qr(e,t,n){if("object"!=typeof n||Array.isArray(n)||null===n)throw[Ir,"Expected object, got "+JSON.stringify(n)];var r=un(n,e);if(void 0===r)throw[Ir,"Expected field '"+String(e)+"'"];try{return Ct(t,sn(r))}catch(t){var o=gn(t);if(o[0]===Ir)throw[Ir,o[1]+"\n\tat field '"+e+"'"];throw o}}function Pr(e,t){try{return rn(Ct(e,t))}catch(e){var n=gn(e);if(n[0]===Ir)return;throw n}}function Gr(e,t){return t.then((function(t){return Ct(e,t),Promise.resolve(0)})),0}var Qr=function(e){return Promise.resolve(e)};function Rr(e){return Promise.resolve(bt(0,[e]))}function Fr(e,t){return t.then((function(t){return t.tag?Promise.resolve(t):Ct(e,t[0])}))}function Br(e){return e.then((function(e){return Promise.resolve(bt(0,[e]))})).catch((function(e){return Promise.resolve(bt(1,[e.toString()]))}))}var Hr={$$return:Rr,fail:function(e){return Promise.resolve(bt(1,[e]))},resolve:function(e){return Promise.resolve(e)}},Vr="42b1eefa-d754-4802-b9c4-bf80d6ab6052",Dr="https://d8ejoa1fys2rk.cloudfront.net/5.0.5/modules/compactview/loginCompleted.html",$r=function(e){if(window.TextEncoder)return new TextEncoder("utf-8").encode(e);for(var t=unescape(encodeURIComponent(e)),n=new Uint8Array(t.length),r=0;r<t.length;r++)n[r]=t.charCodeAt(r);return n},Wr=function(e,t,n){return{client_id:Vr,code_challenge:e,code_challenge_method:"S256",redirect_uri:Dr,response_type:"code",scope:n.join(" "),state:t}};function Yr(e){var t;return(t=cn(e),Rn(t,(function(e){var t=encodeURIComponent(e[0]),n=encodeURIComponent(e[1]);return String(t)+"="+String(n)}))).join("&")}var Jr=function(e,t){return pr.ensureValidUrl(t)+"v6/authentication/oauth2/auth?"+Yr(e)},Xr=function(e,t){return{grant_type:"authorization_code",client_id:Vr,code_verifier:t,code:e,redirect_uri:Dr}},Kr=function(e){return{grant_type:"refresh_token",client_id:Vr,refresh_token:e}},Zr=function(e){return btoa(String.fromCharCode.apply(null,new Uint8Array(e))).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")},eo=function(e){return function(e){var t=window.crypto&&(window.crypto.subtle||window.crypto.webkitSubtle),n=window.msCrypto&&window.msCrypto.subtle;return t?t.digest("SHA-256",e):n?new Promise((function(t,r){var o=n.digest("SHA-256",e);o.oncomplete=function(){t(o.result)},o.onerror=function(e){r(e)}})):Promise.reject("Access to the WebCrypto API is restricted to secure origins. Compact View requires HTTPS when used outside localhost (for development).")}(Ct($r,e))},to=function(e){var t;return Rn((t=new Uint32Array(new Array(28)),(window.crypto||window.msCrypto).getRandomValues(t)),(function(e){return("0"+e.toString(16)).substr(-2)})).join("")},no=function(e,t){var n=pr.ensureValidUrl(t)+"v6/authentication/oauth2/token",r=Yr(e);return Br(fetch(n,Mr(2,{Accept:"application/json","Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"},rn(r),void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0)(0)).then((function(e){return e.json().then((function(e){return Qr(function(e){return{refreshToken:qr("refresh_token",zr,e),accessToken:qr("access_token",zr,e),expiresIn:qr("expires_in",Er,e)}}(e))}))})))},ro=function(e,t){var n=pr.ensureValidUrl(t)+"v6/authentication/oauth2/token",r=Yr(e);return Br(fetch(n,Mr(2,{Accept:"application/json","Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"},rn(r),void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0)(0)).then((function(e){return e.json().then((function(e){return Qr(function(e){return{accessToken:qr("access_token",zr,e),expiresIn:qr("expires_in",Er,e)}}(e))}))})))},oo=Cr({initialState:{accessToken:void 0,refreshToken:Mn("cvrt"),accountDomain:Mn("cvad")},reducer:function(e,t){if("number"==typeof t)return Un("cvrt",void 0),{accessToken:void 0,refreshToken:void 0,accountDomain:Mn("cvad")};if(t.tag)return{accessToken:t[0],refreshToken:e.refreshToken,accountDomain:e.accountDomain};var n=t[0];return Un("cvrt",n.refreshToken),Un("cvad",n.accountDomain),n},equal:function(e,t){var n=!1,r=t.accessToken,o=e.accessToken;if(void 0!==o?void 0!==r&&o===r:void 0===r){var i=t.refreshToken,a=e.refreshToken;n=void 0!==a?void 0!==i&&a===i:void 0===i}if(n){var s=t.accountDomain,u=e.accountDomain;return void 0!==u?void 0!==s&&u===s:void 0===s}return!1}}),io={contents:void 0};function ao(e){return nr(io.contents,(function(e){return clearTimeout(e),0})),io.contents=rn(setTimeout((function(e){return Ct(oo.send,bt(1,[void 0]))}),1e3*e)),0}function so(e){var t=Ct(oo.use,0),n=t.accountDomain,r=t.refreshToken,o=t.accessToken;return i((function(){var e;if(void 0!==o||void 0===r||void 0===n)e=Rr(0);else{var t=n,i=ro;e=Fr((function(e){return ao(e.expiresIn),Ct(oo.send,bt(1,[e.accessToken])),Hr.$$return(0)}),function(e){return _t(i,e,t)}(Kr(r)))}Gr((function(e){return e.tag?(console.error(e[0]),Ct(oo.send,0)):0}),e)}),[o,r,n]),t}var uo={contents:void 0};function co(e){return t=function(e){return uo.contents=void 0,bt(1,["Login window closed"])},n=function(t){return function(e){try{return!e||e.closed}catch(e){return!0}}(e)},r={contents:0},new Promise((function(e,o){var i=function(o){return Ct(n,0)?e(Ct(t,0)):r.contents<6e5?(r.contents=r.contents+1e3|0,setTimeout(i,1e3),0):(Ct(t,0),e(bt(1,["Timeout"])))};return setTimeout(i,1e3),0}));var t,n,r}function lo(e){return Ct(oo.send,0)}function fo(e){var t=function(e,t){return e===t};return At(oo.subscribeWith,(function(e){return function(n){return or(e,n,t)}}),(function(e){return e.refreshToken}),(function(t){return Ct(e,0)}))}function vo(e,t,n,r,o,i,a,s,u){for(var c=t+n|0,l=o+i|0,d=t,f=e[t],v=o,p=r[o],h=s;;){var m=h,g=p,b=v,x=f,y=d;if(u(x,g)<=0){a[m]=x;var w=y+1|0;if(w<c){h=m+1|0,f=e[w],d=w;continue}return Gn(r,b,a,m+1|0,l-b|0)}a[m]=g;var k=b+1|0;if(!(k<l))return Gn(e,y,a,m+1|0,c-y|0);h=m+1|0,p=r[k],v=k}}function po(e,t,n,r,o,i){for(var a=0,s=o-1|0;a<=s;++a){for(var u=e[t+a|0],c=(r+a|0)-1|0;c>=r&&i(n[c],u)>0;)n[c+1|0]=n[c],c=c-1|0;n[c+1|0]=u}return 0}function ho(e,t,n,r,o,i){if(o<=5)return po(e,t,n,r,o,i);var a=o/2|0,s=o-a|0;return ho(e,t+a|0,n,r+a|0,s,i),ho(e,t,e,t+s|0,a,i),vo(e,t+s|0,a,n,r+a|0,s,n,r,i)}function mo(e,t){return function(e,t){var n=e.slice(0);return function(e,t){var n=e.length;if(n<=5)return po(e,0,e,0,n,t);var r=n/2|0,o=n-r|0,i=new Array(o);ho(e,r,i,0,o,t),ho(e,0,e,o,r,t),vo(e,o,r,i,0,o,e,0,t)}(n,t),n}(e,Lt(t))}function go(e){return null!==e?e.height:0}function bo(e,t,n,r){var o=go(e),i=go(r);return{key:t,value:n,height:o>=i?o+1|0:i+1|0,left:e,right:r}}function xo(e,t){return{key:e,value:t,height:1,left:null,right:null}}function yo(e,t){return e.value===t?e:{key:e.key,value:t,height:e.height,left:e.left,right:e.right}}function wo(e,t,n,r){var o=null!==e?e.height:0,i=null!==r?r.height:0;if(o>(i+2|0)){var a=e.left,s=e.key,u=e.value,c=e.right;if(go(a)>=go(c))return bo(a,s,u,bo(c,t,n,r));var l=c.left,d=c.key,f=c.value,v=c.right;return bo(bo(a,s,u,l),d,f,bo(v,t,n,r))}if(i>(o+2|0)){var p=r.left,h=r.key,m=r.value,g=r.right;if(go(g)>=go(p))return bo(bo(e,t,n,p),h,m,g);var b=p.left,x=p.key,y=p.value,w=p.right;return bo(bo(e,t,n,b),x,y,bo(w,h,m,g))}return{key:t,value:n,height:o>=i?o+1|0:i+1|0,left:e,right:r}}function ko(e,t){for(;;){if(null===e)return t;t=[e,t],e=e.left}}function No(e){return null!==e?function e(t){var n=t.left,r=t.right;return(1+(null!==n?e(n):0)|0)+(null!==r?e(r):0)|0}(e):0}var Co=function(e,t,n){return function(e,t,n){return No(e)===No(t)&&function(e,t,n){for(;;){var r=t,o=e;if(o&&r){var i=r[0],a=o[0];if(a.key===i.key&&n(a.value,i.value)){t=ko(i.right,r[1]),e=ko(a.right,o[1]);continue}return!1}return!0}}(ko(e,0),ko(t,0),n)}(e,t,Lt(n))};function So(e,t){return e[0]===t[0]}var _o=Cr({initialState:null,reducer:function(e,t){var n=t[0];return function e(t,n,r){if(null!==t){var o=t.key;if(n===o)return yo(t,r);var i=t.value;return n<o?wo(e(t.left,n,r),o,i,t.right):wo(t.left,o,i,e(t.right,n,r))}return xo(n,r)}(e,n,[n,t[1]])},equal:function(e,t){return Co(e,t,So)}});function Lo(e){var t=_t(_o.useWith,(function(e){return function(t){return or(e,t,So)}}),(function(t){return function(e,t){for(;;){var n=e;if(null===n)return;var r=n.key;if(t===r)return rn(n.value);e=t<r?n.left:n.right}}(t,e)}));return i((function(){void 0===t&&Gr((function(t){var n=void 0!==t?rn(sn(t)):void 0;return Ct(_o.send,[e,n]),fn.contents=n,0}),function(e){var t,n,r=e.slice(0,2).toLowerCase();return 2!==r.length?Promise.resolve(void 0):(t=Br(fetch("https://d8ejoa1fys2rk.cloudfront.net/5.0.5/modules/compactview/i18n/"+String(r)+".json").then((function(e){return e.json()}))),n=function(e){return e.tag?void 0:rn(e[0])},t.then((function(e){return Promise.resolve(Ct(n,e))})))}(e))}),[er(t,(function(e){return e[0]}))]),0}function Ao(e,t){return function(e,t){var n=void 0!==e?e:100,r={contents:void 0},o={contents:void 0},i={contents:void 0},a=function(e){var s=r.contents;void 0!==s&&clearTimeout(sn(s));var u=0|Date.now();if(function(e){var t=i.contents;if(void 0!==t){var r=e-t|0;return r>=n||r<0}return!0}(u)){var c=o.contents;return void 0!==c?(o.contents=void 0,r.contents=void 0,Ct(t,sn(c))):(r.contents=void 0,0)}return r.contents=rn(setTimeout(a,function(e){var t=i.contents;return void 0!==t?n-(e-t|0)|0:n}(u))),0},s=function(e){var t=r.contents;return void 0!==t?(clearTimeout(sn(t)),r.contents=void 0,o.contents=void 0,i.contents=void 0,0):0};return{invoke:function(e){return s(),Ct(t,e)},schedule:function(e){var t=0|Date.now();return o.contents=rn(e),i.contents=t,r.contents=rn(setTimeout(a,n)),0},scheduled:function(e){return Kn(r.contents)},cancel:s}}(e,t).schedule}var To=e(void 0),Oo=To.Provider;function Mo(e){return a(To)}function Uo(e){var t=e.root,n=e.children;return void 0!==t?v(n,sn(t)):null}var Io,Eo=e(0),jo=Eo.Provider,zo='@import url("https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/css/vendor/font-awesome.min.css");\n\n/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%}body{margin:0}h1{font-size:2em;margin:.67em 0}a{background-color:transparent}b{font-weight:bolder}code{font-family:monospace,monospace;font-size:1em}img{border-style:none}button,input,select{font-family:inherit;font-size:100%;line-height:1.15;margin:0}button,input{overflow:visible}button,select{text-transform:none}[type=button],[type=reset],button{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}[type=button]:-moz-focusring,[type=reset]:-moz-focusring,button:-moz-focusring{outline:1px dotted ButtonText}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-decoration{-webkit-appearance:none}[hidden]{display:none}h1,p{margin:0}button{background-color:transparent;background-image:none;padding:0}button:focus{outline:1px dotted;outline:5px auto -webkit-focus-ring-color}ul{list-style:none;margin:0;padding:0}html{font-family:SourceSansPro,Source Sans Pro,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}*,:after,:before{-webkit-box-sizing:border-box;box-sizing:border-box;border:0 solid rgba(0,34,51,.1)}img{border-style:solid}input::-webkit-input-placeholder{color:#a0aec0}input::-moz-placeholder{color:#a0aec0}input:-ms-input-placeholder{color:#a0aec0}input::-ms-input-placeholder{color:#a0aec0}input::placeholder{color:#a0aec0}button{cursor:pointer}h1{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}button,input,select{padding:0;line-height:inherit;color:inherit}code{font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}audio,img,object,svg,video{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}.container{width:100%}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}.appearance-none{-webkit-appearance:none;-moz-appearance:none;appearance:none}.bg-brand-500{background-color:#0af}.bg-ui-0{background-color:#fff}.bg-ui-400{background-color:rgba(0,34,51,.03)}.bg-ui-500{background-color:rgba(0,34,51,.05)}.bg-ui-600{background-color:rgba(0,34,51,.1)}.bg-ui-800{background-color:rgba(0,34,51,.2)}.bg-ui-900{background-color:rgba(0,34,51,.35)}.bg-ui-0-\\.8{background-color:hsla(0,0%,100%,.8)}.hover\\:bg-brand-600:hover{background-color:#008ed5}.hover\\:bg-ui-0:hover{background-color:#fff}.hover\\:bg-ui-400:hover{background-color:rgba(0,34,51,.03)}.focus\\:bg-ui-500:focus,.hover\\:bg-ui-500:hover{background-color:rgba(0,34,51,.05)}.active\\:bg-brand-700:active{background-color:#008dd5}.active\\:bg-ui-700:active{background-color:rgba(0,34,51,.15)}.disabled\\:bg-ui-500:disabled{background-color:rgba(0,34,51,.05)}.border-transparent{border-color:transparent}.border-error{border-color:#f4562b}.border-brand-500{border-color:#0af}.border-ui-600{border-color:rgba(0,34,51,.1)}.border-ui-700{border-color:rgba(0,34,51,.15)}.hover\\:border-ui-900:hover{border-color:rgba(0,34,51,.35)}.focus\\:border-ui-700:focus{border-color:rgba(0,34,51,.15)}.focus\\:border-ui-900:focus{border-color:rgba(0,34,51,.35)}.disabled\\:border-ui-500:disabled{border-color:rgba(0,34,51,.05)}.rounded{border-radius:5px}.rounded-full{border-radius:9999px}.border-2{border-width:2px}.border{border-width:1px}.border-b{border-bottom-width:1px}.last\\:border-b-0:last-child{border-bottom-width:0}.cursor-default{cursor:default}.cursor-pointer{cursor:pointer}.cursor-wait{cursor:wait}.block{display:block}.inline{display:inline}.flex{display:-webkit-box;display:-ms-flexbox;display:flex}.inline-flex{display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.hidden{display:none}.group:hover .group-hover\\:block{display:block}.flex-col{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.flex-wrap{-ms-flex-wrap:wrap;flex-wrap:wrap}.items-center{-webkit-box-align:center;-ms-flex-align:center;align-items:center}.self-start{-ms-flex-item-align:start;align-self:flex-start}.justify-center{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.justify-between{-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between}.flex-1{-webkit-box-flex:1;-ms-flex:1 1 0%;flex:1 1 0%}.flex-grow{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.flex-shrink-0{-ms-flex-negative:0;flex-shrink:0}.font-semibold{font-weight:600}.h-3{height:12px}.h-4{height:16px}.h-5{height:20px}.h-6{height:24px}.h-8{height:32px}.h-10{height:40px}.h-12{height:48px}.h-16{height:64px}.h-20{height:80px}.h-32{height:128px}.h-40{height:160px}.h-2\\/4{height:50%}.h-full{height:100%}.m-2{margin:8px}.my-2{margin-top:8px;margin-bottom:8px}.mx-2{margin-left:8px;margin-right:8px}.my-px{margin-top:1px;margin-bottom:1px}.-mx-1{margin-left:-4px;margin-right:-4px}.-my-2{margin-top:-8px;margin-bottom:-8px}.mt-1{margin-top:4px}.mr-1{margin-right:4px}.ml-1{margin-left:4px}.mt-2{margin-top:8px}.mr-2{margin-right:8px}.mb-2{margin-bottom:8px}.ml-2{margin-left:8px}.mt-3{margin-top:12px}.mr-3{margin-right:12px}.ml-3{margin-left:12px}.mt-4{margin-top:16px}.mr-4{margin-right:16px}.mb-4{margin-bottom:16px}.mr-5{margin-right:20px}.mt-6{margin-top:24px}.mt-8{margin-top:32px}.mb-8{margin-bottom:32px}.mt-10{margin-top:40px}.mr-auto{margin-right:auto}.ml-auto{margin-left:auto}.ml-px{margin-left:1px}.-mr-1{margin-right:-4px}.-mr-2{margin-right:-8px}.max-w-24{max-width:96px}.max-w-32{max-width:128px}.min-w-24{min-width:96px}.object-contain{-o-object-fit:contain;object-fit:contain}.object-cover{-o-object-fit:cover;object-fit:cover}.disabled\\:opacity-60:disabled{opacity:.6}.focus\\:outline-none:focus{outline:0}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.p-3{padding:12px}.p-4{padding:16px}.p-0\\.5{padding:2px}.py-1{padding-top:4px;padding-bottom:4px}.py-2{padding-top:8px;padding-bottom:8px}.py-3{padding-top:12px;padding-bottom:12px}.px-3{padding-left:12px;padding-right:12px}.py-4{padding-top:16px;padding-bottom:16px}.px-4{padding-left:16px;padding-right:16px}.px-6{padding-left:24px;padding-right:24px}.py-px{padding-top:1px;padding-bottom:1px}.pr-0{padding-right:0}.pl-0{padding-left:0}.pb-1{padding-bottom:4px}.pb-2{padding-bottom:8px}.pl-3{padding-left:12px}.pt-4{padding-top:16px}.pr-4{padding-right:16px}.pl-4{padding-left:16px}.pr-5{padding-right:20px}.pr-10{padding-right:40px}.pl-10{padding-left:40px}.placeholder-body-300::-webkit-input-placeholder{color:rgba(0,34,51,.3)}.placeholder-body-300::-moz-placeholder{color:rgba(0,34,51,.3)}.placeholder-body-300:-ms-input-placeholder{color:rgba(0,34,51,.3)}.placeholder-body-300::-ms-input-placeholder{color:rgba(0,34,51,.3)}.placeholder-body-300::placeholder{color:rgba(0,34,51,.3)}.disabled\\:pointer-events-none:disabled,.pointer-events-none{pointer-events:none}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-0{right:0;left:0}.inset-0,.inset-y-0{top:0;bottom:0}.top-0{top:0}.right-0{right:0}.bottom-0{bottom:0}.left-0{left:0}.top-3{top:12px}.right-3{right:12px}.right-4{right:16px}.right-px{right:1px}.left-px{left:1px}.-bottom-0\\.75{bottom:-3px}.resize{resize:both}.shadow{-webkit-box-shadow:0 1px 6px 0 rgba(0,34,51,.1),0 0 0 1px rgba(0,34,51,.1);box-shadow:0 1px 6px 0 rgba(0,34,51,.1),0 0 0 1px rgba(0,34,51,.1)}.shadow-outline{-webkit-box-shadow:0 0 0 2px #0af;box-shadow:0 0 0 2px #0af}.shadow-border{-webkit-box-shadow:0 1px 6px -2px rgba(0,34,51,.1);box-shadow:0 1px 6px -2px rgba(0,34,51,.1)}.shadow-fade-left{-webkit-box-shadow:-16px 0 10px 0 #fff;box-shadow:-16px 0 10px 0 #fff}.shadow-fade-right{-webkit-box-shadow:4px 0 13px 13px #fff;box-shadow:4px 0 13px 13px #fff}.shadow-footer{-webkit-box-shadow:0 -1px 0 0 rgba(0,34,51,.1),0 -1px 6px 0 rgba(0,34,51,.1);box-shadow:0 -1px 0 0 rgba(0,34,51,.1),0 -1px 6px 0 rgba(0,34,51,.1)}.shadow-overlay{-webkit-box-shadow:0 4px 10px 0 rgba(0,34,51,.1);box-shadow:0 4px 10px 0 rgba(0,34,51,.1)}.shadow-modal{-webkit-box-shadow:0 2px 12px 0 rgba(0,34,51,.1);box-shadow:0 2px 12px 0 rgba(0,34,51,.1)}.active\\:shadow-inner:active{-webkit-box-shadow:inset 0 1px 3px 0 rgba(0,34,51,.1);box-shadow:inset 0 1px 3px 0 rgba(0,34,51,.1)}.active\\:shadow-fade-left:active{-webkit-box-shadow:-16px 0 10px 0 #fff;box-shadow:-16px 0 10px 0 #fff}.active\\:shadow-fade-right:active{-webkit-box-shadow:4px 0 13px 13px #fff;box-shadow:4px 0 13px 13px #fff}.fill-current{fill:currentColor}.text-center{text-align:center}.text-right{text-align:right}.text-error{color:#f4562b}.text-body-300{color:rgba(0,34,51,.3)}.text-body-400{color:rgba(0,34,51,.5)}.text-body-500{color:rgba(0,34,51,.8)}.text-ui-0{color:#fff}.focus-within\\:text-body-400:focus-within{color:rgba(0,34,51,.5)}.hover\\:text-body-400:hover{color:rgba(0,34,51,.5)}.active\\:text-body-500:active,.focus\\:text-body-500:focus,.hover\\:text-body-500:hover{color:rgba(0,34,51,.8)}.disabled\\:text-body-300:disabled{color:rgba(0,34,51,.3)}.text-xs{font-size:12px}.text-sm{font-size:14px}.text-xl{font-size:20px}.text-2xl{font-size:22px}.uppercase{text-transform:uppercase}.capitalize{text-transform:capitalize}.select-none{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.visible{visibility:visible}.invisible{visibility:hidden}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.w-5{width:20px}.w-6{width:24px}.w-10{width:40px}.w-40{width:160px}.w-48{width:192px}.w-56{width:224px}.w-80{width:320px}.w-2\\/4{width:50%}.w-full{width:100%}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.transform{--transform-translate-x:0;--transform-translate-y:0;--transform-rotate:0;--transform-skew-x:0;--transform-skew-y:0;--transform-scale-x:1;--transform-scale-y:1;-webkit-transform:translateX(var(--transform-translate-x)) translateY(var(--transform-translate-y)) rotate(var(--transform-rotate)) skewX(var(--transform-skew-x)) skewY(var(--transform-skew-y)) scaleX(var(--transform-scale-x)) scaleY(var(--transform-scale-y));transform:translateX(var(--transform-translate-x)) translateY(var(--transform-translate-y)) rotate(var(--transform-rotate)) skewX(var(--transform-skew-x)) skewY(var(--transform-skew-y)) scaleX(var(--transform-scale-x)) scaleY(var(--transform-scale-y))}.transition{-webkit-transition-property:background-color,border-color,color,fill,stroke,opacity,-webkit-box-shadow,-webkit-transform;transition-property:background-color,border-color,color,fill,stroke,opacity,-webkit-box-shadow,-webkit-transform;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,-webkit-box-shadow,-webkit-transform}.transition-shadow{-webkit-transition-property:-webkit-box-shadow;transition-property:-webkit-box-shadow;transition-property:box-shadow;transition-property:box-shadow,-webkit-box-shadow}.transition-transform{-webkit-transition-property:-webkit-transform;transition-property:-webkit-transform;transition-property:transform;transition-property:transform,-webkit-transform}@keyframes fade-in{0%{opacity:0}to{opacity:1}}@keyframes fade-in-down{0%{opacity:0;-webkit-transform:translateY(-2px);transform:translateY(-2px)}to{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes border-rotate{to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes border-dash{0%{stroke-dasharray:1,100;stroke-dashoffset:0}50%{stroke-dasharray:80,100;stroke-dashoffset:-20}to{stroke-dasharray:80,100;stroke-dashoffset:-48}}.transition-shadow{-webkit-transition:-webkit-box-shadow .1s linear;transition:-webkit-box-shadow .1s linear;transition:box-shadow .1s linear;transition:box-shadow .1s linear,-webkit-box-shadow .1s linear}.transition-color{-webkit-transition:color .05s linear,background-color .05s linear,border-color .05s linear,opacity .05s linear;transition:color .05s linear,background-color .05s linear,border-color .05s linear,opacity .05s linear}.transition-transform{-webkit-transition:-webkit-transform .6s cubic-bezier(.175,.885,.32,1.15);transition:-webkit-transform .6s cubic-bezier(.175,.885,.32,1.15);transition:transform .6s cubic-bezier(.175,.885,.32,1.15);transition:transform .6s cubic-bezier(.175,.885,.32,1.15),-webkit-transform .6s cubic-bezier(.175,.885,.32,1.15)}.cv-root{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;background-color:#fff;font-family:SourceSansPro,Source Sans Pro,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-size:16px;color:rgba(0,34,51,.8);-webkit-box-sizing:border-box;box-sizing:border-box}.cv-root *,.cv-root :after,.cv-root :before{-webkit-box-sizing:inherit;box-sizing:inherit}.cv-container{overflow:hidden;width:100%;height:100%}.cv-container nav:last-of-type{-webkit-box-shadow:0 1px 0 0 rgba(0,34,51,.1),0 1px 6px 0 rgba(0,34,51,.1);box-shadow:0 1px 0 0 rgba(0,34,51,.1),0 1px 6px 0 rgba(0,34,51,.1)}.cv-dropdown{position:fixed;border-width:1px;border-color:rgba(0,34,51,.1);-webkit-animation:fade-in-down .15s ease-out;animation:fade-in-down .15s ease-out;margin-top:4px;margin-bottom:4px;overflow-y:auto;border-radius:5px;-webkit-box-shadow:0 4px 10px 0 rgba(0,34,51,.1);box-shadow:0 4px 10px 0 rgba(0,34,51,.1);z-index:9999999;-webkit-transition:left .1s ease-out;transition:left .1s ease-out}.card-list{padding-left:8px;padding-right:8px;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;-ms-flex-line-pack:start;align-content:flex-start;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.max-h-400{max-height:400px}.max-w-600{max-width:600px}.flip-y{-webkit-transform:scaleY(-1);transform:scaleY(-1)}.spinner{-webkit-animation:border-rotate 1s linear infinite;animation:border-rotate 1s linear infinite;z-index:2;position:absolute;top:50%;left:50%;margin:-10px 0 0 -10px;width:20px;height:20px}.spinner circle{stroke:currentColor;stroke-linecap:round;-webkit-animation:border-dash 1.5s ease-in-out infinite;animation:border-dash 1.5s ease-in-out infinite}.fade-in{-webkit-animation:fade-in .15s ease-out;animation:fade-in .15s ease-out}.fade-in-down{-webkit-animation:fade-in-down .15s ease-out;animation:fade-in-down .15s ease-out}.group:hover .group-hover\\:fade-in{-webkit-animation:fade-in .15s ease-out;animation:fade-in .15s ease-out}.animation-duration-500{-webkit-animation-duration:.5s;animation-duration:.5s}.selected-outline{-webkit-box-shadow:0 0 0 2px #0af;box-shadow:0 0 0 2px #0af}.cv-skeleton{overflow:hidden;display:inline-block;position:relative;border-radius:4px;background-color:rgba(0,34,51,.05)}.cv-skeleton:before{position:absolute;height:100%;top:0;-webkit-animation:cv-skeleton-progress 1.5s ease-in-out infinite;animation:cv-skeleton-progress 1.5s ease-in-out infinite;content:"";width:500px;left:-500px;background-image:-webkit-gradient(linear,left top,right top,from(hsla(0,0%,100%,0)),color-stop(hsla(0,0%,100%,.6)),to(hsla(0,0%,100%,0)));background-image:linear-gradient(90deg,hsla(0,0%,100%,0),hsla(0,0%,100%,.6),hsla(0,0%,100%,0))}@keyframes cv-skeleton-progress{0%{left:-500px}to{left:100%}}.cbx{border-radius:3px;background-color:#fff;-webkit-box-shadow:inset 0 0 0 1px rgba(0,34,51,.1),inset 0 1px 2px 0 rgba(0,34,51,.15);box-shadow:inset 0 0 0 1px rgba(0,34,51,.1),inset 0 1px 2px 0 rgba(0,34,51,.15);position:relative;-ms-flex-negative:0;flex-shrink:0;height:13px;-webkit-transition:background-color .15s linear;transition:background-color .15s linear;width:13px}.cbx svg{position:absolute;top:2px;left:2px;height:8px;width:10px;fill:none;-webkit-filter:drop-shadow(0 1px .5px #296bb0);filter:drop-shadow(0 1px .5px #296bb0);stroke-dasharray:17;stroke-dashoffset:17;stroke-linecap:round;stroke-linejoin:round;stroke-width:2.2;stroke:#fff;-webkit-transform:translateZ(0);transform:translateZ(0)}.cbx.cbx--checked{background-color:#0af}.cbx.cbx--checked svg{stroke-dashoffset:0;-webkit-transition:stroke-dashoffset .15s linear;transition:stroke-dashoffset .15s linear}.overlay-pill{position:absolute;margin:12px;padding-left:4px;padding-right:4px;height:20px;border-radius:4px;background-color:rgba(0,34,51,.3);color:#fff;font-size:12px;font-weight:600;line-height:22px}.fa-lg{line-height:1.05em}.z-a-lot{z-index:999999}';try{var qo=new CSSStyleSheet;qo.replaceSync(zo),Io=rn(qo)}catch(e){Io=void 0}var Po=[];function Go(e,t){var n=jn.head,r=rr(e,n);return Vn(Po,(function(e){return e[0]===r&&e[1]===t}))?0:(function(e,t){var n=jn.createElement("style"),r=jn.createTextNode(e);n.appendChild(r),t.appendChild(n)}(t,r),$n([r,t],Po))}function Qo(e){var r=e.topLevel,a=e.children,s=o(null),u=n((function(){})),c=u[1],l=u[0];i((function(){if(r){var e=jn.body;if(null==e)return;var t=jn.createElement("div");return e.appendChild(t),s.current=t,function(n){return e.removeChild(t),s.current=null,0}}}),[s,r]),i((function(){var e=s.current;if(null!=e){var t,n=function(e){var t;try{t=e.attachShadow({mode:"open"})}catch(e){return}return rn(t)}(e);return t=n,void 0!==Io&&void 0!==t?sn(t).adoptedStyleSheets=[sn(Io)]:Go(t,zo),void 0!==n&&Go(void 0,"\n@font-face {\n font-family: 'Source Sans Pro';\n font-style: normal;\n font-weight: 400;\n src: local('Source Sans Pro Regular'),\n local('SourceSansPro-Regular'),\n url('https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/fonts/SourceSans/sourcesanspro-regular.woff2') format('woff2'),\n url('https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/fonts/SourceSans/sourcesanspro-regular.woff') format('woff');\n}\n\n@font-face {\n font-family: \"FontAwesome\";\n src: url(\"https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/fonts/fontawesome-webfont.woff2?v=4.7.0\") format(\"woff2\"),\n url(\"https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/fonts/fontawesome-webfont.woff?v=4.7.0\") format(\"woff\");\n font-weight: 400;\n font-style: normal;\n}\n"),void Ct(c,(function(t){return rn(rr(n,e))}))}}),[s]);var d={style:{display:"flex",height:"100%"}},f=r?void 0:rn(s);return void 0!==f&&(d.ref=sn(f)),t("div",d,t(Oo,function(e,t,n){return{value:e,children:t}}(l,t(Uo,{root:l,children:a}))))}var Ro=function(e){var n=e.topLevel,r=e.children,o=void 0!==n&&n;return a(Eo)?r:t(jo,function(e,t,n){return{value:1,children:t}}(0,t(Qo,{topLevel:o,children:r})))},Fo=e(void 0);function Bo(e,t,n){return{value:e,children:t}}var Ho=Fo.Provider,Vo=function(e){return a(Fo)};function Do(e){return e.colorPrimary}function $o(e,t,n){var r,o;if(void 0!==e){var i=e,a=i.colorButtonPrimary,s=0,u=i.colorButtonPrimaryActive,c=0;if(void 0!==u?-791844958!==t?749755612!==t||-891636250!==n?c=2:r=u:-891636250!==n?c=2:r=u:c=2,2===c){var l=i.colorButtonPrimaryHover;if(void 0!==l){var d=0;-791844958!==t&&749755612!==t?s=1:d=3,3===d&&(-891636250!==n&&1049777564!==n?s=1:r=l)}else s=1}if(1===s)if(void 0!==a){var f=0;-791844958!==t&&749755612!==t?r=void 0:f=2,2===f&&(r=-891636250!==n&&870530776!==n&&1049777564!==n?void 0:a)}else r=void 0}else r=void 0;if(void 0!==e){var v=e,p=v.colorButtonPrimaryLabel,h=0,m=v.colorButtonPrimaryHoverLabel;if(void 0!==m?-791844958!==t?749755612!==t||1049777564!==n?h=1:o=m:1049777564!==n?h=1:o=m:h=1,1===h)if(void 0!==p){var g=0;-791844958!==t&&749755612!==t?o=void 0:g=2,2===g&&(o=-891636250!==n&&870530776!==n&&1049777564!==n?void 0:p)}else o=void 0}else o=void 0;var b={};return void 0!==r&&(b.background=sn(r)),void 0!==o&&(b.color=sn(o)),b}var Wo=e({assetFieldSelection:void 0,assetFilter:void 0,assetTypes:[],language:"en_US",onSuccess:function(e,t){return console.log(e,t),0},selectionMode:2,theme:void 0,hideExternalAccess:!1}),Yo=Wo.Provider;function Jo(e){return a(Wo)}function Xo(e){return a(Wo).theme}function Ko(e){return a(Wo).assetFilter}function Zo(e){return-323491629!==e?e>=749755612?e>=781662169?"text-body-400 active:bg-ui-700 active:text-body-500 focus:bg-ui-500 focus:text-body-500 hover:bg-ui-500 hover:text-body-500 disabled:text-body-300":"text-ui-0 bg-brand-500 hover:bg-brand-600 active:bg-brand-700 disabled:opacity-60":e>=-791844957?"text-body-500 bg-ui-400 hover:bg-ui-500 hover:text-body-500 active:bg-ui-700 focus:text-body-500 disabled:text-body-300 disabled:bg-ui-500":"text-ui-0 bg-brand-500 hover:bg-brand-600 active:bg-brand-700 disabled:opacity-60":"text-body-400 active:bg-ui-700 active:text-body-500 focus:bg-ui-500 focus:text-body-500 hover:bg-ui-500 hover:text-body-500 disabled:text-body-300"}function ei(e){return-323491629!==e?e>=749755612?e>=781662169?"focus:border-ui-700":"focus:border-ui-900":e>=-791844957?"border-ui-600 focus:border-ui-900 disabled:border-ui-500":"focus:border-ui-900":"focus:border-ui-700"}var ti=s((function(e,r){var o,i=e.className,a=e.title,s=e.disabled,u=e.onClick,c=e.kind,l=e.children,d=r,f=void 0!==c?c:781662169,v=n((function(){return!1})),p=v[1],h=n((function(){return!1})),m=h[1],g=h[0],b=Xo(),x=gr(["rounded inline-flex items-center flex-shrink-0 text-md border border-transparent select-none active:shadow-inner focus:outline-none disabled:pointer-events-none transition-color",(o=f,o>=87487758?o>=781662169?"h-10 px-4":"h-8 px-3":-323491629!==o?"h-10 px-4":"h-8 px-3"),Zo(f),ei(f),xr(i)]),y=$o(b,f,v[0]?g?-891636250:1049777564:g?-891636250:870530776),w=function(e){return e},k={className:x,style:y,onMouseDown:function(e){return Ct(m,(function(e){return!0}))},onMouseOut:function(e){return Ct(p,(function(e){return!1}))},onMouseOver:function(e){return Ct(p,(function(e){return!0}))},onMouseUp:function(e){return Ct(m,(function(e){return!1}))}},N=function(e){return er(e,w)}(null==d?void 0:rn(d));return void 0!==N&&(k.ref=sn(N)),void 0!==a&&(k.title=sn(a)),void 0!==s&&(k.disabled=sn(s)),void 0!==u&&(k.onClick=sn(u)),t("button",k,l)})),ni=function(e){var n=e.className,r=gr(["w-6 h-6 text-body-300",xr(n)]);return t("div",{className:r},t("svg",{className:"spinner",viewBox:"0 0 20 20"},t("circle",{cx:"10",cy:"10",fill:"none",r:"8",strokeWidth:"3"})))},ri=e(!1);function oi(e,t,n){return{value:e,children:t}}var ii=ri.Provider,ai=function(e){return a(ri)};function si(e){var n=e.className;return t("svg",{className:n,viewBox:"0 0 479.438 361.46"},t("path",{d:"M365.18 0a114 114 0 00-85.9 38.93l-153.18 153-43.82-43.84a45.18 45.18 0 01-11.54-30.75 46.06 46.06 0 0146.34-46.08 44.81 44.81 0 0130.42 11.49c2.73 2.42 10.48 10.43 10.48 10.43l48.5-48.51-14-14C172.19 11.43 144.48.03 114.3.03 51.24.03 0 51.03 0 114.1a115.08 115.08 0 0028.09 75.46l98.35 98.77 205.53-205.5a44.78 44.78 0 0130.58-11.57 46.07 46.07 0 0146.06 46.43 45.07 45.07 0 01-11.52 30.5l-136.6 136.57a28.73 28.73 0 01-20.83 8.58 28.29 28.29 0 01-20.51-8.92l-10.27-10.16-48.28 48.28 9.88 9.72a97.06 97.06 0 0069.38 29.2h.07a96 96 0 0069-29.13l142.35-142.67A114.47 114.47 0 00365.18 0z",fill:"#0af"}))}function ui(e){var r=e.portal,a=so(),s=n((function(){if(void 0!==r)return r.url.trim();var e=a.accountDomain;return void 0!==e?e.trim():""})),c=s[1],l=s[0],d=u((function(){return Ao(1e3,(function(e){return Ct(c,(function(t){return e}))}))}),[]),f=n((function(){return-709493348})),v=f[1],p=f[0],h=Vo(0),m=o(null);i((function(){var e={contents:!1},t=m.current;return null!=t&&(t.value=l),""!==l&&(Ct(v,(function(e){return-660729997})),Gr((function(t){return e.contents?0:Ct(v,(function(e){return t?-102231997:144245463}))}),pr.isBynderPortal(l))),function(t){return e.contents=!0,0}}),[l]);var g,b=function(e){return Gr((function(e){return e.tag?(console.error(e[0]),Ct(v,(function(e){return-102231997}))):0}),(Ct(v,(function(e){return-312601306})),function(e){return Fr((function(t){var n=to(0);return Fr((function(r){var o=Zr(r),i=to(0),a=_t(Jr,Wr(o,i,["offline","asset:read","collection:read","meta.assetbank:read"]),e);return t.location=a,Fr((function(t){var r=t.data,o=pr.getQueryParameter(r,"state"),a=pr.getQueryParameter(r,"code");return Fr((function(t){var r=no;return Fr((function(t){return ao(t.expiresIn),Ct(oo.send,bt(0,[{accessToken:t.accessToken,refreshToken:t.refreshToken,accountDomain:e}])),Hr.$$return(0)}),function(t){return _t(r,t,e)}(Xr(a,n)))}),"https://d8ejoa1fys2rk.cloudfront.net"!==t.origin||o!==i||""===a?Hr.fail("Error logging in"):Hr.$$return(0))}),Promise.race([Br(Nr(0)),co(t)]))}),Br(eo(n)))}),Hr.resolve(ir(function(e){var t=In.screen,n=((t.width/2|0)-285|0)+In.screenX|0,r=((t.height/2|0)-350|0)+In.screenY|0;!function(e){var t=uo.contents;void 0!==t&&(function(e){try{e&&!e.closed&&e.close()}catch(e){return}}(sn(t)),uo.contents=void 0)}();var o=In.open("","Bynder Brand Portal","height="+String(700)+",width="+String(570)+",left="+String(n)+",top="+String(r)),i=null==o?void 0:rn(o);if(null!=o){var a=o.document;a.head.innerHTML='<title>Redirecting...</title><style>@keyframes cv-spinner-animation{to{transform:rotate(1turn)}}.cv-spinner{position:relative;display:inline-block;padding:175px 0 100px;width:100%;height:auto;background:#fff;box-sizing:border-box}.cv-spinner:before{position:absolute;top:50%;left:50%;width:40px;height:40px;margin-top:-20px;margin-left:-20px;box-sizing:border-box;border-top:3px solid #7e8890;border-right:3px solid transparent;border-radius:50%;content:"";animation:cv-spinner-animation .8s linear infinite;z-index:3}</style>';var s=a.body;null==s||(s.innerHTML='<div class="cv-spinner"></div>')}return uo.contents=i,i}(),"Error opening login window")))}(l)))},x=gr(["appearance-none block h-10 w-80 border rounded text-body-500 placeholder-body-300 focus:outline-none transition-color",p>=144245463?"pl-4 pr-10 border-error":"px-4 border-ui-600 hover:border-ui-900 focus:border-ui-900"]),y=void 0!==r&&!r.editable||-312601306===p;if(void 0!==h){var w=h.onClose;g=t(ti,{className:"absolute top-3 right-4",title:vn("Close"),onClick:function(e){return Ct(w,0)},children:t(tn,{className:"w-6 h-6 -mx-1"})})}else g=null;return t("div",{className:"bg-ui-0 w-full h-full flex flex-col items-center justify-center cv-root relative"},g,t("div",{className:"flex flex-col"},t(si,{className:"w-10 mb-8"}),t("h1",{className:"text-xl mb-2"},vn("Connect your brand portal")),t("div",{className:"text-body-400 mb-8"},vn("Enter the portal domain")),t("div",{className:"mb-4"},t("div",{className:"relative"},t("input",{ref:m,className:x,autoFocus:!0,placeholder:"yourdomain.bynder.com",readOnly:y,onKeyDown:function(e){var t=e.keyCode;return-102231997!==p||13!==t?0:b()},onChange:function(e){return Ct(v,(function(e){return-709493348})),Ct(d,dr(e).trim())}}),-660729997!==p?p>=144245463?t(tn,{className:"absolute top-0 right-3 w-6 h-full text-error fade-in cursor-pointer",onClick:function(e){var t=m.current;return null!=t&&(t.value=""),Ct(v,(function(e){return-709493348})),Ct(c,(function(e){return""}))}}):null:t(ni,{className:"absolute top-0 right-0 mr-3 h-full"})),144245463===p?t("div",{className:"text-error text-sm mt-1 fade-in"},vn("This portal domain does not exist")):null),t(ti,{className:"justify-center relative",disabled:-102231997!==p,onClick:function(e){return b()},kind:-791844958,children:-312601306!==p?vn("Connect"):t(ni,{className:"text-ui-0"})})))}function ci(e){return{cmp:Lt(e.cmp)}}function li(e){var t=typeof e;return"string"===t?bt(0,[e]):"number"===t?bt(1,[e]):"boolean"===t?!0===e?1:0:null===e?2:Array.isArray(e)?bt(3,[e]):bt(2,[e])}function di(e){if("string"==typeof e)return e}function fi(e){if("number"==typeof e)return e}function vi(e){if("object"==typeof e&&!Array.isArray(e)&&null!==e)return rn(e)}function pi(e){if(Array.isArray(e))return e}function hi(e){if("boolean"==typeof e)return e}function mi(e){if(null===e)return null}function gi(e){if(void 0!==e)return sn(e);throw new Error("getExn")}var bi=function(e,t){return Pn(e.id,t.id)},xi=function(e,t){return e.id===t.id};function yi(e){return e>=757540433?"DESC":"ASC"}function wi(e){return e>=868235851?"NAME":"CREATED_AT"}function ki(e){return dn([["direction",yi(e.direction)],["field",wi(e.field)]].filter((function(e){return!0})))}var Ni={definition:[function(e){var t,n=un(gi(vi(e)),"collections");if(void 0!==n){var r=vi(sn(n));if(void 0!==r){var o,i=sn(r),a=un(i,"nodes"),s=void 0!==a?gi(pi(sn(a))).map((function(e){var t=vi(e);if(void 0!==t){var n,r=sn(t),o=un(r,"id");if(void 0!==o){var i=di(sn(o));n=void 0!==i?i:bn("Unexpected GraphQL query response")}else n=bn("Unexpected GraphQL query response");var a,s=un(r,"name");if(void 0!==s){var u=di(sn(s));a=void 0!==u?u:bn("Unexpected GraphQL query response")}else a=bn("Unexpected GraphQL query response");var c,l=un(r,"assetCount");if(void 0!==l){var d=fi(sn(l));c=void 0!==d?0|d:bn("Unexpected GraphQL query response")}else c=bn("Unexpected GraphQL query response");var f=un(r,"thumbnailUrls"),v=void 0!==f?gi(pi(sn(f))).map((function(e){return e})):bn("Unexpected GraphQL query response"),p=un(r,"url");return{id:n,name:a,assetCount:c,thumbnailUrls:v,url:void 0!==p?sn(p):bn("Unexpected GraphQL query response")}}return bn("Unexpected GraphQL query response")})):bn("Unexpected GraphQL query response"),u=un(i,"totalCount");if(void 0!==u){var c=fi(sn(u));o=void 0!==c?0|c:bn("Unexpected GraphQL query response")}else o=bn("Unexpected GraphQL query response");var l,d=un(i,"pageInfo");if(void 0!==d){var f=vi(sn(d));if(void 0!==f){var v,p=sn(f),h=un(p,"endCursor");if(void 0!==h){var m=sn(h);v=void 0!==mi(m)?void 0:rn(m)}else v=void 0;var g,b=un(p,"hasNextPage");if(void 0!==b){var x=hi(sn(b));g=void 0!==x?x:bn("Unexpected GraphQL query response")}else g=bn("Unexpected GraphQL query response");l={endCursor:v,hasNextPage:g}}else l=bn("Unexpected GraphQL query response")}else l=bn("Unexpected GraphQL query response");t={nodes:s,totalCount:o,pageInfo:l}}else t=bn("Unexpected GraphQL query response")}else t=bn("Unexpected GraphQL query response");return{collections:t}},"query getCollections($after: Cursor, $searchTerm: String, $orderBy: CollectionOrder!) {\ncollections(after: $after, first: 50, filter: {name_contains: $searchTerm, assetCount_gte: 1}, orderBy: $orderBy) {\nnodes {\nid \nname \nassetCount \nthumbnailUrls \nurl \n}\n\ntotalCount \npageInfo {\nendCursor \nhasNextPage \n}\n\n}\n\n}\n",function(e,t,n,r,o){return Ct(e,dn([["after",void 0!==t?sn(t):null],["searchTerm",void 0!==n?n:null],["orderBy",ki(r)]].filter((function(e){return!0}))))}],getPageInfo:function(e){return e.collections.pageInfo},concatNodes:function(e,t){var n=t.collections;return{collections:{nodes:e.collections.nodes.concat(t.collections.nodes),totalCount:n.totalCount,pageInfo:n.pageInfo}}}},Ci=ci({cmp:function(e,t){if("number"==typeof e){if(0!==e){if("number"==typeof t&&0!==t)return 0}else if("number"==typeof t&&0===t)return 0}else if("number"!=typeof t)return bi(e[0],t[0]);var n=function(e){return"number"==typeof e?0!==e?1:0:2};return qn(n(e),n(t))}}),Si=Cr({initialState:0,reducer:function(e,t){return t},equal:function(e,t){return"number"==typeof e?0!==e?"number"==typeof t&&0!==t:"number"==typeof t&&0===t:"number"!=typeof t&&xi(e[0],t[0])}}),_i=Si.send;fo((function(e){return Ct(_i,0)}));var Li=Si.use,Ai=Si.subscribe;function Ti(e){return t("svg",{height:"130",width:"190"},t("defs",void 0,t("linearGradient",{id:"prefix__b",x1:"100%",x2:"25.598%",y1:"11.782%",y2:"100%"},t("stop",{offset:"0%",stopColor:"#F8FAFC"}),t("stop",{offset:"100%",stopColor:"#EFF2F4"})),t("rect",{id:"prefix__a",height:"130",width:"190",rx:"3"})),t("g",{fill:"none",fillRule:"evenodd"},t("mask",{id:"prefix__c",fill:"#fff"},t("use",{xlinkHref:"#prefix__a"})),t("use",{fill:"url(#prefix__b)",xlinkHref:"#prefix__a"}),t("g",{mask:"url(#prefix__c)"},t("path",{d:"M100.296 45.951l23.01 43.23A6 6 0 01118.009 98H71.991a6 6 0 01-5.297-8.82l23.01-43.229a6 6 0 0110.592 0z",fill:"#F5A623"}),t("path",{d:"M93.21 60h3.58a2 2 0 011.99 2.199l-1.6 16A2 2 0 0195.19 80h-.38a2 2 0 01-1.99-1.801l-1.6-16A2 2 0 0193.21 60zM95 84a3 3 0 110 6 3 3 0 010-6z",fill:"#FFF",fillRule:"nonzero"})),t("path",{d:"M3 0h184a3 3 0 013 3v13H0V3a3 3 0 013-3z",fill:"#EEF1F3",mask:"url(#prefix__c)"}),t("circle",{cx:"11",cy:"8",fill:"#023",fillOpacity:"0.1",mask:"url(#prefix__c)",r:"3"}),t("circle",{cx:"20",cy:"8",fill:"#023",fillOpacity:"0.1",mask:"url(#prefix__c)",r:"3"}),t("circle",{cx:"29",cy:"8",fill:"#023",fillOpacity:"0.1",mask:"url(#prefix__c)",r:"3"})))}var Oi=function(e){var n=e.error,r=e.onRetry;return console.error(n),t("div",{className:" w-full h-full flex flex-col items-center justify-center"},t(Ti,{}),t("h1",{className:"mt-10 text-2xl"},vn("Oops! Something went wrong")),t("span",{className:"mt-4 text-body-400"},vn("Please try again or get in contact with our customer support.")),t(ti,{className:"mt-8",title:vn("Try again"),onClick:function(e){return Ct(r,0)},kind:-791844958,children:vn("Try again")}))},Mi=function(e){function n(t){e.call(this,t),this.state={error:null}}return e&&(n.__proto__=e),n.prototype=Object.create(e&&e.prototype),n.prototype.constructor=n,n.getDerivedStateFromError=function(e){return{error:e}},n.prototype.render=function(){var e=this;return this.state.error?t(Oi,{error:this.state.error,onRetry:function(){return e.setState({error:null})}}):this.props.children},n}(c);function Ui(e,t){if(0===t)throw yt;return e/t|0}var Ii=Math.imul||function(e,t){return((e>>16)*(t|=0)<<16)+(65535&e)*t|0};function Ei(e,t){return e<<t|e>>>(32-t|0)}function ji(e,t){var n=t;n=Ei(n=Ii(n,3432918353),15);var r=e^(n=Ii(n,461845907));return 3864292196+((r=Ei(r,13))+(r<<2)|0)|0}function zi(e){var t=e^e>>>16;return t=Ii(t,2246822507),(t=Ii(t^=t>>>13,3266489909))^t>>>16}function qi(e,t,n){for(;;){var r=n;if(void 0===r)return 0;var o=zi(ji(0,r.key))&(e.length-1|0),i=t[o];void 0!==i?i.next=r:e[o]=r,t[o]=r,n=r.next}}var Pi,Gi=(Pi=function(e,t){for(;;){if(e>=10||e<<1<e)return e;e<<=1}}(16),{size:0,buckets:new Array(Pi),hash:0,eq:0});function Qi(e,t,n,r,o){var i=void 0!==t&&t,a=JSON.stringify({query:r,variables:o}),s=er(n,(function(e){return"Bearer "+e})),u=e+(a+sr(n,"")),c=function(e,t){var n=e.buckets,r=n[zi(ji(0,t))&(n.length-1|0)];if(void 0!==r){if(t===r.key)return rn(r.value);var o=r.next;if(void 0===o)return;if(t===o.key)return rn(o.value);var i=o.next;if(void 0===i)return;if(t===i.key)return rn(i.value);for(var a=t,s=i.next;;){var u=s;if(void 0===u)return;if(a===u.key)return rn(u.value);s=u.next}}}(Gi,wr(u));if(i);else if(void 0!==c)return Rr(sn(c));return Fr((function(e){return void 0===e.errors&&function(e,t){(function(e,t,n){var r=e.buckets,o=r.length,i=zi(ji(0,t))&(o-1|0),a=r[i];if(void 0!==a?function(e,t,n){for(;;){var r=n;if(r.key===e)return r.value=t,!1;var o=r.next;if(void 0===o)return!0;n=o}}(t,n,a)&&(r[i]={key:t,value:n,next:a},e.size=e.size+1|0):(r[i]={key:t,value:n,next:void 0},e.size=e.size+1|0),e.size>o<<1){var s=e,u=s.buckets,c=u.length,l=c<<1;if(l>=c){var d=new Array(l),f=new Array(l);s.buckets=d;for(var v=0,p=c-1|0;v<=p;++v)qi(d,f,u[v]);for(var h=0,m=l-1|0;h<=m;++h){var g=f[h];void 0!==g&&(g.next=void 0)}return 0}return 0}})(Gi,wr(e),t)}(u,e),Hr.$$return(e)}),Br(fetch(e,Mr(2,{Accept:"application/json","Content-Type":"application/json",Authorization:s},rn(a),void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0)(0)).then((function(e){return e.json()}))))}function Ri(e,t,n,r,o){var i,a=void 0!==e&&e,s=o.accessToken,u=0;if(void 0!==s){var c=o.accountDomain;void 0!==c?i=[pr.ensureValidUrl(c.trim())+"graphql",s]:u=1}else u=1;return 1===u&&(i=["https://"+En.host+"/graphql",void 0]),Fr((function(e){var t,n=e.data,o=e.errors;if(null==n)return void 0!==o?Hr.fail(Rn(o,(function(e){return e.message})).join(",")):Hr.fail("Unreachable");try{t=Ct(r,n)}catch(e){var i=gn(e);return Hr.fail(function(e){return rr(e,"Error parsing response")}(tr(function(e){if(e[0]===mn)return rn(e[1])}(i),(function(e){return e.message}))))}return Hr.$$return(t)}),Qi(i[0],a,i[1],t,n))}var Fi=Ri;function Bi(e){switch(0|e.tag){case 0:var t=e[0];return void 0!==t?bt(0,[rn(sn(t))]):e;case 1:return bt(0,[rn(e[0])]);case 2:return bt(0,[void 0])}}function Hi(e,t,r){var o,a=so(),s=n((function(){return bt(0,[void 0])})),u=s[1],c=s[0],l={},d=function(n){return Ct(u,Bi),function(e){return Ri(!1,e,r,t,a)}(e).then((function(e){var t=l.didCancel;if(e.tag){var n=e[0];"Invalid or expired token"===n?(lo(),Ct(u,(function(e){return bt(2,[n])}))):t||Ct(u,(function(e){return bt(2,[n])}))}else if(!t){var r=e[0];Ct(u,(function(e){return bt(1,[r])}))}return Qr(0)})),0};switch(0|c.tag){case 0:o=!0;break;case 1:case 2:o=!1}return function(e,t){for(var n in t)e[n]=t[n]}(l,{data:c,executeQuery:d,isLoading:o,auth:a,parse:t,query:e,setData:u,variables:r,didCancel:!1}),i((function(){return d(),function(e){return l.didCancel=!0,0}}),[JSON.stringify(r)]),l}var Vi=function(e){switch(0|e.tag){case 0:return e[0];case 1:return rn(e[0]);case 2:return}},Di=function(e){var t=e[1],n=e[0];return Ct(e[2],(function(e){return Hi(t,n,e)}))};function $i(e,t,n,r){var o,i,a=e.variables,s=e.setData,u=e.parse,c=e.auth,l=e.data;switch(0|l.tag){case 1:o=rn(l[0]);break;case 0:case 2:o=void 0}if(void 0!==o){var d=Ct(t,sn(o));if(void 0!==d){var f=d;i=[f.hasNextPage,f.endCursor]}else i=void 0}else i=void 0;if(void 0!==i){var v=i;if(v[0]){var p=v[1];if(void 0!==p){Ct(s,(function(e){return bt(0,[o])}));var h=li(a);"number"!=typeof h&&2===h.tag&&(h[0].after=sn(p)),function(e){return Ri(!1,e,a,u,c)}(e.query).then((function(t){var r=e.didCancel;if(t.tag){if(!r){var i=t[0];Ct(s,(function(e){return bt(2,[i])}))}}else if(!r){var a=t[0],u=void 0!==o?_t(n,sn(o),a):a;Ct(s,(function(e){return bt(1,[u])}))}return Promise.resolve(0)}))}}}return 0}var Wi=function(e){var t=e.concatNodes,n=e.getPageInfo,r=e.definition,o=r[1],i=r[0];return Ct(r[2],(function(e){var r,a,s=Hi(o,i,e),u=s.data,c=0;switch(0|u.tag){case 0:var l=u[0];void 0!==l?(a=sn(l),c=1):r=!1;break;case 1:a=u[0],c=1;break;case 2:r=!1}if(1===c){var d=Ct(n,a);r=void 0!==d&&d.hasNextPage}return{data:u,isLoading:s.isLoading,hasNextPage:r,loadMore:function(e){return $i(s,n,t)},executeQuery:s.executeQuery}}))};function Yi(e,t,n,r){if(null!==e){var o=e.key,i=r(t,o);if(0===i)return yo(e,n);var a=e.left,s=e.right,u=e.value;return i<0?wo(Yi(a,t,n,r),o,u,s):wo(a,o,u,Yi(s,t,n,r))}return xo(t,n)}function Ji(e,t,n){return function(e,t,n){return function(e,t,n,r){if(No(e)!==No(t))return!1;for(var o=ko(e,0),i=ko(t,0),a=n,s=r;;){var u=i,c=o;if(c&&u){var l=u[0],d=c[0];if(0===a(d.key,l.key)&&s(d.value,l.value)){i=ko(l.right,u[1]),o=ko(d.right,c[1]);continue}return!1}return!0}}(e.data,t.data,e.cmp,n)}(e,t,Lt(n))}function Xi(e,t){return e.width===t.width&&e.height===t.height&&e.scrollWidth===t.scrollWidth}var Ki=function(e){var t=n((function(){})),o=t[1],i=n((function(){})),a=i[1],s=i[0],u=n((function(){return 0})),c=u[1],d=l((function(e){return Ct(a,(function(t){return null==e?void 0:rn(e)}))}),[]);return r((function(){var e={contents:0},t=function(t){return cancelAnimationFrame(e.contents),e.contents=requestAnimationFrame((function(e){if(void 0!==s){var t=sn(s),n=t.getBoundingClientRect();return Ct(o,(function(e){var r={width:n.width,height:n.height,scrollWidth:t.scrollWidth};return lr(e,r,Xi)?e:r}))}return 0})),0};return t(),In.addEventListener("resize",t),function(e){return In.removeEventListener("resize",t),0}}),[s,u[0]]),{dimensions:t[0],node:s,reMeasure:function(e){return Ct(c,(function(e){return e+1|0}))},nodeRef:d}},Zi=function(e,t){var n=Mo();return i((function(){var r=function(n){var r=n.target,o=function(e){return e.contains(r)};return function(e){return Vn(e,o)}(Dn(e,(function(e){return on(e.current)})))?0:Ct(t,n)};if(void 0!==n){var o=sn(n);return o.addEventListener("mousedown",r),function(e){return o.removeEventListener("mousedown",r),0}}}),[function(e){return{contents:e}},t,n]),0},ea=function(e){var n=e.className,r=e.onClick,o=e.selected,i=e.children,a=void 0!==o&&o,s={className:gr(["cursor-pointer flex hover:bg-ui-400 hover:text-body-500 items-center transition-color",a?"text-body-500":"text-body-400",xr(n)])};return void 0!==r&&(s.onClick=sn(r)),t("li",s,i,a?t(Kt,{className:gr(["w-6 h-6 ml-3 fade-in"])}):null)};function ta(e){var i=e.className,a=e.onClickOutside,s=e.direction,u=e.target,c=e.children,l=o(null),d=n((function(){return 0}))[1];Zi([u,l],a);var f=u.current;r((function(){Ct(d,(function(e){return null==f?0:f.getBoundingClientRect().x}))}));var p=Mo();if(void 0!==p&&null!=f){var h,m=f.getBoundingClientRect(),g=m.left,b=In.innerWidth;if(g+300>b){var x=b-m.width-g;h=[void 0,String(x)+"px"]}else h=[String(g)+"px",void 0];var y,w=h[1],k=h[0];if(s>=759637122){var N={top:String(m.top+m.height)+"px"};void 0!==k&&(N.left=sn(k)),void 0!==w&&(N.right=sn(w)),y=N}else{var C=In.innerHeight,S={bottom:String(C-m.top)+"px"};void 0!==k&&(S.left=sn(k)),void 0!==w&&(S.right=sn(w)),y=S}var _=gr(["cv-root cv-dropdown select-none",xr(i)]);return v(t("div",{ref:l,className:_,style:y},c),sn(p))}return null}var na=function(e){var r=e.className,i=e.buttonClassName,a=e.buttonKind,s=e.direction,u=e.title,c=e.alt,l=e.disabled,f=e.children,v=void 0!==a?a:-323491629,p=void 0!==s?s:759637122,h=n((function(){return!1})),m=h[1],g=h[0],b=o(null),x=function(e){return Ct(m,(function(e){return!e}))},y={className:gr([br(g,"bg-ui-400 border-ui-700 text-body-500"),xr(i)]),onClick:x,kind:v,children:null,ref:b};void 0!==l&&(y.disabled=sn(l));var w,k={className:"inline-flex items-center"};if(void 0!==c&&(k.title=sn(c)),g){var N={onClickOutside:x,direction:p,target:b,children:Ct(f,x)};void 0!==r&&(N.className=sn(r)),w=t(ta,N)}else w=null;return t(d,void 0,t(ti,y,t("span",k,u),t(Jt,{className:"w-6 h-6 ml-1 -mr-2"})),w)};function ra(e,t){return e.field===t.field&&e.direction===t.direction}var oa={field:-600305078,direction:757540433},ia={cmp:Ci.cmp,data:null},aa=Cr({initialState:ia,reducer:function(e,t){if(t){var n=t[0];return function(e,t,n){var r=e.cmp;return{cmp:r,data:Yi(e.data,t,n,r)}}(e,n.page,n.ordering)}return ia},equal:function(e,t){return Ji(e,t,ra)}}),sa=aa.send,ua=aa.useWith;function ca(e){var t=_t(ua,void 0,(function(t){return function(e,t){return function(e,t,n){for(;;){var r=e;if(null===r)return;var o=n(t,r.key);if(0===o)return rn(r.value);e=o<0?r.left:r.right}}(e.data,t,e.cmp)}(t,e)}));return[void 0!==t?t:oa,function(t){return Ct(sa,[{page:e,ordering:t}])}]}fo((function(e){return Ct(sa,0)}));var la=aa.state,da=aa.use,fa=aa.subscribe,va=aa.subscribeWith,pa={initialState:ia,state:la,send:sa,use:da,useWith:ua,subscribe:fa,subscribeWith:va,usePage:ca};function ha(e){return vn(e>=83152964?e>=868235851?"Name":"Date published":e>=39795671?"Date modified":"Date added")}var ma=[-600305078,83152964,39795671,868235851],ga=function(e){var n=e.options,r=void 0!==n?n:ma,o=ca(Ct(Li,0)),i=o[1],a=o[0],s=a.direction,u=a.field;return t(na,{className:"py-2",buttonClassName:"ml-auto",title:ha(u),alt:vn("Order by"),children:function(e){return t("ul",void 0,Rn(r,(function(n){var r=ha(n);return t(ea,{className:"px-4 py-px text-sm",onClick:function(t){return Ct(i,{field:n,direction:s}),Ct(e,0)},selected:u===n,children:t("span",{className:"flex-grow min-w-24 py-2"},r),key:r})})))}})};var ba=function(e){var n,r=ca(Ct(Li,0)),o=r[1],i=r[0],a=i.direction,s=i.field,u=gr(["w-6 h-6 -mx-1",br(3250961===a,"flip-y")]);return t(ti,{title:(n=a,vn(n>=757540433?"Descending":"Ascending")),onClick:function(e){return Ct(o,{field:s,direction:a>=757540433?3250961:757540433})},kind:-323491629,children:t(Ht,{className:u})})};function xa(e){return null!==e?e.height:0}function ya(e,t,n){var r=null!==e?e.height:0,o=null!==n?n.height:0;return{value:t,height:r>=o?r+1|0:o+1|0,left:e,right:n}}function wa(e){return{value:e,height:1,left:null,right:null}}function ka(e,t){return null===t||null!==e&&e.height>=t.height}function Na(e,t,n){var r=null!==e?e.height:0,o=null!==n?n.height:0;if(r>(o+2|0)){var i=e.left,a=e.value,s=e.right;if(ka(i,s))return ya(i,a,ya(s,t,n));var u=s.left,c=s.value,l=s.right;return ya(ya(i,a,u),c,ya(l,t,n))}if(o>(r+2|0)){var d=n.left,f=n.value,v=n.right;if(ka(v,d))return ya(ya(e,t,d),f,v);var p=d.left,h=d.value,m=d.right;return ya(ya(e,t,p),h,ya(m,f,v))}return{value:t,height:r>=o?r+1|0:o+1|0,left:e,right:n}}function Ca(e,t){var n=e.left,r=e.right,o=e.value;return null!==n?Na(Ca(n,t),o,r):(t.contents=o,r)}function Sa(e){return null===e}function _a(e,t){for(;;){if(null===e)return t;t=[e,t],e=e.left}}function La(e,t,n){if(null!==e){if(null!==n){var r=e.height,o=n.height;return r>(o+2|0)?Na(e.left,e.value,La(e.right,t,n)):o>(r+2|0)?Na(La(e,t,n.left),n.value,n.right):ya(e,t,n)}return function e(t,n){return null!==t?Na(t.left,t.value,e(t.right,n)):wa(n)}(e,t)}return function e(t,n){return null!==t?Na(e(t.left,n),t.value,t.right):wa(n)}(n,t)}function Aa(e){var t=e.left,n=e.right;return(1+(null!==t?Aa(t):0)|0)+(null!==n?Aa(n):0)|0}function Ta(e){return null!==e?Aa(e):0}function Oa(e){if(null!==e){var t=Aa(e),n=new Array(t);return function e(t,n,r){for(;;){var o=n,i=t,a=i.left,s=i.value,u=i.right,c=null!==a?e(a,o,r):o;r[c]=s;var l=c+1|0;if(null===u)return l;n=l,t=u}}(e,0,n),n}return[]}function Ma(e){var t=e.left;e.left=t.right,t.right=e;var n=xa(e.left),r=xa(e.right);e.height=(n>r?n:r)+1|0;var o=xa(t.left),i=e.height;return t.height=(o>i?o:i)+1|0,t}function Ua(e){var t=e.right;e.right=t.left,t.left=e;var n=xa(e.left),r=xa(e.right);e.height=(n>r?n:r)+1|0;var o=xa(t.right),i=e.height;return t.height=(o>i?o:i)+1|0,t}function Ia(e){var t=xa(e.left),n=xa(e.right);return e.height=(t>n?t:n)+1|0,e}function Ea(e,t,n){if(null!==t){var r=e(n,t.value);if(0===r)return t;var o=t.left,i=t.right;if(r<0){var a=Ea(e,o,n);t.left=a}else t.right=Ea(e,i,n);return function(e){var t,n,r=e.left,o=e.right,i=xa(r),a=xa(o);if(i>(2+a|0))return ka(r.left,r.right)?Ia(Ma(e)):Ia((n=Ua((t=e).left),t.left=n,Ma(t)));if(a>(2+i|0)){var s=o.left;return ka(o.right,s)?Ia(Ua(e)):Ia(function(e){var t=Ma(e.right);return e.right=t,Ua(e)}(e))}return e.height=(i>a?i:a)+1|0,e}(t)}return wa(n)}function ja(e,t,n){if(null!==e&&null!==t){var r=e.left,o=e.value,i=e.right,a={contents:!1},s=function e(t,n,r,o){var i=n.left,a=n.value,s=n.right,u=t(r,a);if(0===u)return o.contents=!0,[i,s];if(u<0){if(null!==i){var c=e(t,i,r,o);return[c[0],La(c[1],a,s)]}return[null,n]}if(null!==s){var l=e(t,s,r,o);return[La(i,a,l[0]),l[1]]}return[n,null]}(n,t,o,a),u=ja(r,s[0],n),c=ja(i,s[1],n);return a.contents?La(u,o,c):function(e,t){if(null!==e){if(null!==t){var n={contents:t.value},r=Ca(t,n);return La(e,n.contents,r)}return e}return t}(u,c)}return null}var za=function(e,t){var n=e.length;if(0===n)return null;var r,o=function(e,t){var n=e.length;if(0===n||1===n)return n;var r=e[0],o=e[1];if(!t(r,o))return t(o,r)?0|-function(e,t,n,r,o){for(;;){var i=n,a=t;if(i>=r)return i;var s=e[i];if(!o(s,a))return i;n=i+1|0,t=s}}(e,o,2,n,t):1;for(var i=e,a=o,s=2,u=n,c=t;;){var l=s,d=a;if(l>=u)return l;var f=i[l];if(!c(d,f))return l;s=l+1|0,a=f}}(e,(function(e,n){return t(e,n)<0}));r=o>=0?function e(t,n,r){switch(r){case 0:return null;case 1:return wa(t[n]);case 2:var o=t[n];return{value:t[n+1|0],height:2,left:wa(o),right:null};case 3:var i=t[n],a=t[n+1|0],s=t[n+2|0];return{value:a,height:2,left:wa(i),right:wa(s)};default:var u=r/2|0;return ya(e(t,n,u),t[n+u|0],e(t,1+(n+u|0)|0,(r-u|0)-1|0))}}(e,0,o):function e(t,n,r){switch(r){case 0:return null;case 1:return wa(t[n]);case 2:var o=t[n];return{value:t[n-1|0],height:2,left:wa(o),right:null};case 3:var i=t[n],a=t[n-1|0],s=t[n-2|0];return{value:a,height:2,left:wa(i),right:wa(s)};default:var u=r/2|0;return ya(e(t,n,u),t[n-u|0],e(t,(n-u|0)-1|0,(r-u|0)-1|0))}}(e,(o=0|-o)-1|0,o);for(var i=o,a=n-1|0;i<=a;++i)r=Ea(t,r,e[i]);return r},qa=Sa,Pa=Oa;function Ga(e,t){var n=e.cmp,r=e.data,o=function e(t,n,r){if(null!==t){var o=t.left,i=t.value,a=t.right,s=r(n,i);if(0===s){if(null!==o){if(null!==a){var u={contents:a.value},c=Ca(a,u);return Na(o,u.contents,c)}return o}return a}if(s<0){var l=e(o,n,r);return l===o?t:Na(l,i,a)}var d=e(a,n,r);return d===a?t:Na(o,i,d)}return t}(r,t,n);return o===r?e:{cmp:n,data:o}}function Qa(e,t){var n=e.cmp,r=e.data,o=function e(t,n,r){if(null!==t){var o=t.value,i=r(n,o);if(0===i)return t;var a=t.left,s=t.right;if(i<0){var u=e(a,n,r);return u===a?t:Na(u,o,s)}var c=e(s,n,r);return c===s?t:Na(a,o,c)}return wa(n)}(r,t,n);return o===r?e:{cmp:n,data:o}}function Ra(e){return{cmp:e.cmp,data:null}}function Fa(e){return qa(e.data)}function Ba(e,t){return n=e.data,r=t.data,o=e.cmp,0===function(e,t,n){var r=Ta(e),o=Ta(t);if(r!==o)return r<o?-1:1;for(var i=_a(e,0),a=_a(t,0),s=n;;){var u=a,c=i;if(c&&u){var l=u[0],d=c[0],f=s(d.value,l.value);if(0===f){a=_a(l.right,u[1]),i=_a(d.right,c[1]);continue}return f}return 0}}(n,r,o);var n,r,o}function Ha(e){return Pa(e.data)}function Va(e,t){if(null!==e){var n=e.value;if(t===n)return e;var r=e.left,o=e.right;if(t<n){var i=Va(r,t);return i===r?e:Na(i,n,o)}var a=Va(o,t);return a===o?e:Na(r,n,a)}return wa(t)}function Da(e,t){if(null!==e){var n=e.left,r=e.value,o=e.right;if(t===r){if(null!==n){if(null!==o){var i={contents:o.value},a=Ca(o,i);return Na(n,i.contents,a)}return n}return o}if(t<r){var s=Da(n,t);return s===n?e:Na(s,r,o)}var u=Da(o,t);return u===o?e:Na(n,r,u)}return e}var $a=Sa,Wa=function(e,t){return 0===function(e,t){var n=Ta(e),r=Ta(t);return n===r?function(e,t){for(;;){var n=t,r=e;if(r&&n){var o=n[0],i=r[0],a=i.value,s=o.value;if(a===s){t=_a(o.right,n[1]),e=_a(i.right,r[1]);continue}return a<s?-1:1}return 0}}(_a(e,0),_a(t,0)):n<r?-1:1}(e,t)},Ya=Oa,Ja=function(e){var n=e.className,r=e.onClick,o=e.children,i={className:gr(["bg-ui-0 border border-ui-600 flex-shrink-0 h-8 inline-flex items-center justify-center px-3 rounded-full select-none shadow-border text-sm text-white transition-color",xr(n)])};return void 0!==r&&(i.onClick=sn(r)),t("div",i,o)},Xa=function(e){var n=e.className,r=e.name;return t("i",{className:gr(["fa fa-lg",r,xr(n)])})},Ka=function(e){var n=e.className,r=e.onClick,o=e.checked,i={className:gr(["cbx",br(void 0!==o&&o,"cbx--checked"),xr(n)])};return void 0!==r&&(i.onClick=sn(r)),t("div",i,t("svg",{viewBox:"0 0 12 11"},t("polyline",{points:"1 6.29411765 4.5 10 11 1"})))};function Za(e){var n=e.mpo,r=e.selectedOptionIds,o=e.isLoading,i=e.onAddOption,a=e.onRemoveOption,s=void 0!==r?r:[],u=void 0!==o&&o,c=n.id,l=Vn(s,(function(e){return c===e})),d=gr(["flex items-center py-2 px-4 text-sm hover:bg-ui-400 transition-color",br(!l,"text-body-400"),br(!l&&u,"cursor-wait"),u&&!l?"cursor-default":"cursor-pointer"]);return t("li",{key:n.id,className:d,onClick:function(e){return l?Ct(a,n):u?0:Ct(i,n)}},t(Ka,{className:"mr-2",checked:l}),t("span",{className:"flex-grow mr-4 my-px truncate fade-in-down",title:n.label},n.label),t("span",{key:String(n.assetCount),className:"fade-in-down"},String(n.assetCount)))}var es=function(e){return e.id};function ts(e){var n=e.metaproperty,r=e.selectedOptionIds,o=e.isLoading,i=e.onAddOption,a=e.onRemoveOption,s=void 0!==o&&o;return t("div",{className:"pt-4 w-56"},t("h1",{className:"mb-2 px-4 truncate",title:n.label},n.label),t("ul",{className:"overflow-y-auto pb-1 max-h-400"},Rn(n.options,(function(e){return t(Za,{mpo:e,selectedOptionIds:r,isLoading:s,onAddOption:i,onRemoveOption:a,key:e.id})}))))}var ns=ts,rs=function(e){var n=e.smartfilter,r=e.selectedOptionIds,o=e.isLoading,i=e.onAddOption,a=e.onRemoveOption,s=void 0!==o&&o;return t("div",{className:"flex"},Rn(n.metaproperties,(function(e){return t(ts,{metaproperty:e,selectedOptionIds:r,isLoading:s,onAddOption:i,onRemoveOption:a,key:e.id})})))},os=function(e){var n=e.width,r=e.className,o=void 0!==n?n:100;return t("span",{className:gr(["cv-skeleton",xr(r)]),style:{width:String(o)+"px"}},"‌")},is=ci({cmp:function(e,t){if(e>=887770203){if(e>=995579707){if(995579707===t)return 0}else if(887770203===t)return 0}else if(e>=628011190){if(628011190===t)return 0}else if(-191332581===t)return 0;var n=function(e){return e>=887770203?e>=995579707?2:3:e>=628011190?0:1};return qn(n(e),n(t))}}),as={empty:Ra(is),fromArray:function(e){return function(e,t){var n=is.cmp;return{cmp:n,data:za(e,n)}}(e)}};function ss(e){return vn(e>=887770203?e>=995579707?"Image":"Video":e>=628011190?"Audio":"Document")}function us(e){return e>=887770203?e>=995579707?{name:"Image",makeProps:function(e,t,n,r,o,i){var a={};return void 0!==e&&(a.className=sn(e)),void 0!==t&&(a.style=sn(t)),void 0!==n&&(a.title=sn(n)),void 0!==r&&(a.onClick=sn(r)),void 0!==o&&(a.key=sn(o)),a},make:$t}:{name:"Video",makeProps:function(e,t,n,r,o,i){var a={};return void 0!==e&&(a.className=sn(e)),void 0!==t&&(a.style=sn(t)),void 0!==n&&(a.title=sn(n)),void 0!==r&&(a.onClick=sn(r)),void 0!==o&&(a.key=sn(o)),a},make:Ft}:e>=628011190?{name:"Audio",makeProps:function(e,t,n,r,o,i){var a={};return void 0!==e&&(a.className=sn(e)),void 0!==t&&(a.style=sn(t)),void 0!==n&&(a.title=sn(n)),void 0!==r&&(a.onClick=sn(r)),void 0!==o&&(a.key=sn(o)),a},make:Bt}:{name:"Document",makeProps:function(e,t,n,r,o,i){var a={};return void 0!==e&&(a.className=sn(e)),void 0!==t&&(a.style=sn(t)),void 0!==n&&(a.title=sn(n)),void 0!==r&&(a.onClick=sn(r)),void 0!==o&&(a.key=sn(o)),a},make:Vt}}function cs(e){return bt(0,[e])}function ls(e){return bt(1,[e])}function ds(e){return bt(2,[e])}var fs={assets:"",collection:"",collections:"",isLoading:!1,preselectedAssets:[]},vs=Cr({initialState:fs,reducer:function(e,t){if("number"==typeof t)return fs;switch(0|t.tag){case 0:var n=t[0],r=""!==n;return{assets:n,collection:e.collection,collections:e.collections,isLoading:r,preselectedAssets:e.preselectedAssets};case 1:var o=t[0],i=""!==o;return{assets:e.assets,collection:o,collections:e.collections,isLoading:i,preselectedAssets:e.preselectedAssets};case 2:var a=t[0],s=""!==a;return{assets:e.assets,collection:e.collection,collections:a,isLoading:s,preselectedAssets:e.preselectedAssets};case 3:return{assets:e.assets,collection:e.collection,collections:e.collections,isLoading:t[0],preselectedAssets:e.preselectedAssets};case 4:return{assets:e.assets,collection:e.collection,collections:e.collections,isLoading:e.isLoading,preselectedAssets:t[0]}}},equal:function(e,t){if(e.assets!==t.assets||e.collection!==t.collection||e.collections!==t.collections||e.isLoading!==t.isLoading)return!1;var n=t.preselectedAssets,r=e.preselectedAssets;if(r.length!==n.length)return!1;for(var o=0;;){var i=o;if(i===r.length)return!0;if(kt(r,i)!==kt(n,i))return!1;o=i+1|0}}}),ps=vs.send,hs=vs.useWith;function ms(e){return _t(hs,void 0,(function(e){var t=e.assets.trim();return""===t?void 0:t}))}function gs(e){return e>=887770203?e>=995579707?"IMAGE":"VIDEO":e>=628011190?"AUDIO":"DOCUMENT"}function bs(e){var t,n=e.isLimitedUse,r=e.metapropertyOptionId_in;t=void 0!==r?r.map((function(e){return e})):null;var o,i=e.collectionId,a=e.assetType_in;o=void 0!==a?a.map(gs):null;var s,u=e.tagNames_in;s=void 0!==u?u.map((function(e){return e})):null;var c=e.searchTerm;return dn([["isLimitedUse",void 0!==n?n:null],["metapropertyOptionId_in",t],["collectionId",void 0!==i?i:null],["assetType_in",o],["tagNames_in",s],["searchTerm",void 0!==c?c:null]].filter((function(e){return!0})))}Ct(Ai,(function(e){return"number"==typeof e?0:Ct(ps,bt(1,[""]))})),fo((function(e){return Ct(ps,0)}));var xs=[function(e){var t,n=un(gi(vi(e)),"searchAssets");if(void 0!==n){var r,o=gi(vi(sn(n))),i=un(o,"tags");if(void 0!==i){var a=sn(i);if(void 0!==mi(a))r=void 0;else{var s=un(gi(vi(a)),"nodes");r={nodes:void 0!==s?gi(pi(sn(s))).map((function(e){var t=vi(e);if(void 0!==t){var n,r=sn(t),o=un(r,"id");if(void 0!==o){var i=di(sn(o));n=void 0!==i?i:bn("Unexpected GraphQL query response")}else n=bn("Unexpected GraphQL query response");var a,s=un(r,"name");if(void 0!==s){var u=di(sn(s));a=void 0!==u?u:bn("Unexpected GraphQL query response")}else a=bn("Unexpected GraphQL query response");var c,l=un(r,"assetCount");if(void 0!==l){var d=fi(sn(l));c=void 0!==d?0|d:bn("Unexpected GraphQL query response")}else c=bn("Unexpected GraphQL query response");return{id:n,name:a,assetCount:c}}return bn("Unexpected GraphQL query response")})):bn("Unexpected GraphQL query response")}}}else r=void 0;var u,c=un(o,"metapropertyFilters");if(void 0!==c){var l=sn(c);if(void 0!==mi(l))u=void 0;else{var d=un(gi(vi(l)),"nodes");u={nodes:void 0!==d?gi(pi(sn(d))).map((function(e){var t=vi(e);if(void 0===t)return bn("Unexpected GraphQL query response");var n=un(sn(t),"__typename");if(void 0===n)return bn("Unexpected GraphQL query response");var r=di(sn(n));if(void 0===r)return bn("Unexpected GraphQL query response");switch(r){case"Metaproperty":var o,i=vi(e);if(void 0!==i){var a,s=sn(i),u=un(s,"id");if(void 0!==u){var c=di(sn(u));a=void 0!==c?c:bn("Unexpected GraphQL query response")}else a=bn("Unexpected GraphQL query response");var l,d=un(s,"label");if(void 0!==d){var f=di(sn(d));l=void 0!==f?f:bn("Unexpected GraphQL query response")}else l=bn("Unexpected GraphQL query response");var v=un(s,"options"),p=void 0!==v?gi(pi(sn(v))).map((function(e){var t=vi(e);if(void 0!==t){var n,r=sn(t),o=un(r,"id");if(void 0!==o){var i=di(sn(o));n=void 0!==i?i:bn("Unexpected GraphQL query response")}else n=bn("Unexpected GraphQL query response");var a,s=un(r,"label");if(void 0!==s){var u=di(sn(s));a=void 0!==u?u:bn("Unexpected GraphQL query response")}else a=bn("Unexpected GraphQL query response");var c,l=un(r,"assetCount");if(void 0!==l){var d=fi(sn(l));c=void 0!==d?0|d:bn("Unexpected GraphQL query response")}else c=bn("Unexpected GraphQL query response");return{id:n,label:a,assetCount:c}}return bn("Unexpected GraphQL query response")})):bn("Unexpected GraphQL query response");o={id:a,label:l,options:p}}else o=bn("Unexpected GraphQL query response");return[-641487814,o];case"Smartfilter":var h,m=vi(e);if(void 0!==m){var g,b=sn(m),x=un(b,"id");if(void 0!==x){var y=di(sn(x));g=void 0!==y?y:bn("Unexpected GraphQL query response")}else g=bn("Unexpected GraphQL query response");var w,k=un(b,"label");if(void 0!==k){var N=di(sn(k));w=void 0!==N?N:bn("Unexpected GraphQL query response")}else w=bn("Unexpected GraphQL query response");var C,S=un(b,"metaproperties"),_=void 0!==S?gi(pi(sn(S))).map((function(e){var t=vi(e);if(void 0!==t){var n,r=sn(t),o=un(r,"id");if(void 0!==o){var i=di(sn(o));n=void 0!==i?i:bn("Unexpected GraphQL query response")}else n=bn("Unexpected GraphQL query response");var a,s=un(r,"label");if(void 0!==s){var u=di(sn(s));a=void 0!==u?u:bn("Unexpected GraphQL query response")}else a=bn("Unexpected GraphQL query response");var c=un(r,"options"),l=void 0!==c?gi(pi(sn(c))).map((function(e){var t=vi(e);if(void 0!==t){var n,r=sn(t),o=un(r,"id");if(void 0!==o){var i=di(sn(o));n=void 0!==i?i:bn("Unexpected GraphQL query response")}else n=bn("Unexpected GraphQL query response");var a,s=un(r,"label");if(void 0!==s){var u=di(sn(s));a=void 0!==u?u:bn("Unexpected GraphQL query response")}else a=bn("Unexpected GraphQL query response");var c,l=un(r,"assetCount");if(void 0!==l){var d=fi(sn(l));c=void 0!==d?0|d:bn("Unexpected GraphQL query response")}else c=bn("Unexpected GraphQL query response");return{id:n,label:a,assetCount:c}}return bn("Unexpected GraphQL query response")})):bn("Unexpected GraphQL query response");return{id:n,label:a,options:l}}return bn("Unexpected GraphQL query response")})):bn("Unexpected GraphQL query response"),L=un(b,"icon");if(void 0!==L){var A=sn(L);if(void 0!==mi(A))C=void 0;else{var T=di(A);C=void 0!==T?T:bn("Unexpected GraphQL query response")}}else C=void 0;var O,M=un(b,"zIndex");if(void 0!==M){var U=fi(sn(M));O=void 0!==U?0|U:bn("Unexpected GraphQL query response")}else O=bn("Unexpected GraphQL query response");h={id:g,label:w,metaproperties:_,icon:C,zIndex:O}}else h=bn("Unexpected GraphQL query response");return[-357541279,h];default:return bn("Unexpected GraphQL query response")}})):bn("Unexpected GraphQL query response")}}}else u=void 0;var f,v=un(o,"count");if(void 0!==v){var p,h=un(gi(vi(sn(v))),"assetType");if(void 0!==h){var m,g=gi(vi(sn(h))),b=un(g,"image");if(void 0!==b){var x=fi(sn(b));m=void 0!==x?0|x:bn("Unexpected GraphQL query response")}else m=bn("Unexpected GraphQL query response");var y,w=un(g,"video");if(void 0!==w){var k=fi(sn(w));y=void 0!==k?0|k:bn("Unexpected GraphQL query response")}else y=bn("Unexpected GraphQL query response");var N,C=un(g,"audio");if(void 0!==C){var S=fi(sn(C));N=void 0!==S?0|S:bn("Unexpected GraphQL query response")}else N=bn("Unexpected GraphQL query response");var _,L=un(g,"document");if(void 0!==L){var A=fi(sn(L));_=void 0!==A?0|A:bn("Unexpected GraphQL query response")}else _=bn("Unexpected GraphQL query response");p={image:m,video:y,audio:N,document:_}}else p=bn("Unexpected GraphQL query response");f={assetType:p}}else f=bn("Unexpected GraphQL query response");t={tags:r,metapropertyFilters:u,count:f}}else t=bn("Unexpected GraphQL query response");return{searchAssets:t}},"query searchAssets($filter: AssetFilter!, $language: String!) {\nsearchAssets(filter: $filter) {\ntags {\nnodes {\nid \nname \nassetCount \n}\n\n}\n\nmetapropertyFilters {\nnodes {\n__typename\n...on Smartfilter {\nid \nlabel(language: $language) \nmetaproperties {\nid \nlabel(language: $language) \noptions {\nid \nlabel(language: $language) \nassetCount \n}\n\n}\n\nicon \nzIndex \n}\n\n...on Metaproperty {\nid \nlabel(language: $language) \noptions {\nid \nlabel(language: $language) \nassetCount \n}\n\n}\n\n}\n\n}\n\ncount {\nassetType {\nimage \nvideo \naudio \ndocument \n}\n\n}\n\n}\n\n}\n",function(e,t,n,r){return Ct(e,dn([["filter",bs(t)],["language",n]].filter((function(e){return!0}))))}],ys=es,ws=Ra(ci({cmp:function(e,t){return Pn(e.id,t.id)}}));function ks(e,t,n){var r,o,i,a=e.tags,s=e.assetTypes,u=as.fromArray(n),c=Fa(s)?Ha(u):Ha((o=u,{cmp:i=(r=s).cmp,data:ja(r.data,o.data,i)})),l=Ha(e.metaproperties);return{assetType_in:c,collectionId:void 0,metapropertyOptionId_in:0!==l.length?Rn(l,ys):void 0,searchTerm:t,tagNames_in:$a(a)?void 0:Ya(a),isLimitedUse:!1}}var Ns={assetTypes:as.empty,metaproperties:ws,tags:null},Cs=Cr({initialState:Ns,reducer:function(e,t){if("number"==typeof t)return Ns;switch(0|t.tag){case 0:return{assetTypes:Qa(e.assetTypes,t[0]),metaproperties:e.metaproperties,tags:e.tags};case 1:return{assetTypes:Ga(e.assetTypes,t[0]),metaproperties:e.metaproperties,tags:e.tags};case 2:return{assetTypes:e.assetTypes,metaproperties:Qa(e.metaproperties,t[0]),tags:e.tags};case 3:return{assetTypes:e.assetTypes,metaproperties:Ga(e.metaproperties,t[0]),tags:e.tags};case 4:return{assetTypes:e.assetTypes,metaproperties:e.metaproperties,tags:Va(e.tags,t[0])};case 5:return{assetTypes:e.assetTypes,metaproperties:e.metaproperties,tags:Da(e.tags,t[0])}}},equal:function(e,t){return!(!Ba(e.assetTypes,t.assetTypes)||!Ba(e.metaproperties,t.metaproperties))&&Wa(e.tags,t.tags)}}),Ss=Cs.send;fo((function(e){return Ct(Ss,0)}));var _s=Cs.use,Ls=Cs.useWith,As=function(e){var o,a,s=e.static,u=e.className,c=e.children,l=void 0!==s?sn(s):null,f=n((function(){return 0})),v=f[1],p=f[0],h=Ki(0),m=h.reMeasure,g=h.node,b=h.dimensions;if(void 0!==g){var x=sn(g);o=x.scrollWidth-x.clientWidth|0}else o=0;if(void 0!==b){var y=b;a=zn(y.width)<y.scrollWidth}else a=!1;r((function(){Ct(m,0)}),[c]),i((function(){a||Ct(v,(function(e){return 0}))}),[a]);var w=String(-p)+"px";return t("div",{className:gr(["inline-flex flex-grow overflow-hidden",xr(u)])},a?t(d,void 0,t(ti,{className:gr(["pl-0 pr-0 z-20",br(p>0,"shadow-fade-right active:shadow-fade-right"),br(0===p,"hidden")]),onClick:function(e){return Ct(v,(function(e){var t=Math.max(0,e-250);return t<100?0:t}))},kind:-323491629,children:t(Zt,{className:"w-6 h-6"})})):null,t("div",{ref:h.nodeRef,className:"overflow-hidden"},t("div",{className:"transition-transform inline-flex",style:{transform:"translateX("+String(w)+")"}},c)),a?t(d,void 0,t(ti,{className:gr(["pl-0 pr-0 z-20",o<=5||p===o?"hidden":"shadow-fade-left active:shadow-fade-left"]),onClick:function(e){return Ct(v,(function(e){var t=Math.min(o,e+250);return t>o-100?o:t}))},kind:-323491629,children:t(en,{className:"w-6 h-6"})})):null,l)},Ts=t(ni,{className:"absolute top-0 right-0 mr-2 mt-3 bg-ui-0"});function Os(e){return e[0]>=-357541279?e[1].zIndex:1e4}function Ms(e){return e.metaproperties}function Us(e){var n=e.metapropertyFilters,r=e.isLoading,o=es,i=Rn(Ha(_t(Ls,Ba,Ms)),o),a=function(e){return Ct(Ss,bt(2,[e]))},s=function(e){return Ct(Ss,bt(3,[e]))};return Rn(mo(n,(function(e,t){return qn(Os(e),Os(t))})),(function(e){var n;if(e[0]>=-357541279){var o,u=e[1],c=u.icon;if(0!==u.metaproperties.length)o=void 0!==c?""===c?null:t(Xa,{className:"mr-2",name:c}):null,n=[u.id,u.label,o,t(rs,{smartfilter:u,selectedOptionIds:i,isLoading:r,onAddOption:a,onRemoveOption:s})];else n=void 0}else{var l=e[1];n=[l.id,l.label,null,t(ns,{metaproperty:l,selectedOptionIds:i,isLoading:r,onAddOption:a,onRemoveOption:s})]}if(void 0!==n){var f=n,v=f[3],p=f[1],h=t(d,void 0,f[2],t("span",{className:"max-w-24 truncate"},p));return t(na,{buttonClassName:"text-sm fade-in-down",title:h,alt:p,children:function(e){return t(d,void 0,r?Ts:null,v)},key:f[0]})}return null}))}function Is(e){return e.tags}function Es(e){var n=e.tags,r=e.isLoading,o=_t(Ls,Wa,Is),i=t(d,void 0,t(Gt,{className:"mr-2 inline w-6 h-6"}),vn("Tags"));return t(na,{className:"pt-4 pb-1 overflow-hidden max-w-600",buttonClassName:"text-sm fade-in-down",title:i,children:function(e){return t(d,void 0,r?Ts:null,t("h1",{className:"px-4 mb-4"},vn("Tags")),t("div",{className:"flex flex-wrap px-4 -mr-2"},Rn(mo(n,(function(e,t){return qn(t.assetCount,e.assetCount)})),(function(e){var n=function(e,t){for(;;){var n=e;if(null===n)return!1;var r=n.value;if(t===r)return!0;e=t<r?n.left:n.right}}(o,e.name),i=gr(["mb-2 mr-2",br(n,"bg-ui-500"),r&&!n?"cursor-default":"cursor-pointer"]);return t(Ja,{className:i,onClick:function(t){return n?Ct(Ss,bt(5,[e.name])):r?0:Ct(Ss,bt(4,[e.name]))},children:null,key:e.id},t("span",{className:"max-w-32 truncate"},e.name),t("span",{className:"text-body-400 ml-2"},String(e.assetCount)))}))))}})}function js(e){var n=e.isLoading,r=e.count,o=Jo().assetTypes,i=_t(Ls,void 0,(function(e){return e.assetTypes}));if(Wn(o))return null;var a=t(d,void 0,t(Yt,{className:"mr-2 inline w-6 h-6"}),vn("Advanced")),s=Dn(o,(function(e){var o,a,s=function(e,t){return t>=887770203?t>=995579707?e.image:e.video:t>=628011190?e.audio:e.document}(r,e),u=0!==s?s:void 0;if(void 0!==u){var c=u,l=(a=e,function(e,t,n){for(;;){var r=e;if(null===r)return!1;var o=n(t,r.value);if(0===o)return!0;e=o<0?r.left:r.right}}((o=i).data,a,o.cmp)),d=gr(["flex items-center py-2 px-4 text-sm hover:bg-ui-400 transition-color",br(!l,"text-body-400"),br(!l&&n,"cursor-wait"),n&&!l?"cursor-default":"cursor-pointer"]),f=ss(e),v=us(e);return rn(t("li",{key:f,className:d,onClick:function(t){return Ct(Ss,bt(l?1:0,[e]))}},t(Ka,{className:"mr-2",checked:l}),t(v.make,Mt(v.makeProps,"w-6 h-6 mr-2 -my-2",void 0,void 0,void 0,void 0,0)),t("span",{className:"flex-grow mr-2 my-px"},f),t("span",{key:String(c),className:"fade-in-down"},String(c))))}}));return s.length>0?t(na,{className:"pt-4 pb-1",buttonClassName:"text-sm fade-in-down",title:a,children:function(e){return t(d,void 0,n?Ts:null,t("h1",{className:"px-4 mb-4"},vn("Type")),t("ul",void 0,s))}}):null}var zs=f((function(e){var n=Ct(_s,0),r=ms(),o=Jo(),i=o.language;Lo(i);var a,s=At(Di(xs),ks(n,r,o.assetTypes),i,0),u=s.isLoading,c=s.data,l=0;switch(0|c.tag){case 0:var d=c[0];void 0!==d?(a=sn(d),l=2):l=1;break;case 1:a=c[0],l=2;break;case 2:l=1}switch(l){case 1:return t("div",{className:"inline-flex items-center"},Rn([100,80,110],(function(e){return t(os,{width:e,className:"h-4 ml-2 mr-2 my-2",key:String(e)})})));case 2:var f,v=a.searchAssets.metapropertyFilters;if(void 0!==v){var p=sn(v).nodes;f=Wn(p)?null:t(Us,{metapropertyFilters:p,isLoading:u})}else f=null;var h,m=a.searchAssets.tags;if(void 0!==m){var g=sn(m).nodes;h=Wn(g)?null:t(Es,{tags:g,isLoading:u})}else h=null;return t(As,{className:"h-8",children:null},f,h,t(js,{isLoading:u,count:a.searchAssets.count.assetType}))}}));function qs(e){var t=vi(e);if(void 0!==t){var n,r=sn(t),o=un(r,"id");if(void 0!==o){var i=di(sn(o));n=void 0!==i?i:bn("Unexpected GraphQL query response")}else n=bn("Unexpected GraphQL query response");var a,s=un(r,"derivatives");if(void 0!==s){var u,c=un(gi(vi(sn(s))),"thumbnail");if(void 0!==c){var l=sn(c);u=void 0!==mi(l)?void 0:rn(l)}else u=bn("Unexpected GraphQL query response");a={thumbnail:u}}else a=bn("Unexpected GraphQL query response");var d,f=un(r,"extensions"),v=void 0!==f?gi(pi(sn(f))).map((function(e){var t=di(e);return void 0!==t?t:bn("Unexpected GraphQL query response")})):bn("Unexpected GraphQL query response"),p=un(r,"name");if(void 0!==p){var h=di(sn(p));d=void 0!==h?h:bn("Unexpected GraphQL query response")}else d=bn("Unexpected GraphQL query response");var m,g=un(r,"url"),b=void 0!==g?sn(g):bn("Unexpected GraphQL query response"),x=un(r,"isArchived");if(void 0!==x){var y=hi(sn(x));m=void 0!==y?y:bn("Unexpected GraphQL query response")}else m=bn("Unexpected GraphQL query response");var w,k=un(r,"isWatermarked");if(void 0!==k){var N=hi(sn(k));w=void 0!==N?N:bn("Unexpected GraphQL query response")}else w=bn("Unexpected GraphQL query response");return{id:n,derivatives:a,extensions:v,name:d,url:b,isArchived:m,isWatermarked:w}}return bn("Unexpected GraphQL query response")}function Ps(e){return e>=887770203?e>=995579707?"IMAGE":"VIDEO":e>=628011190?"AUDIO":"DOCUMENT"}function Gs(e){var t,n=e.isLimitedUse,r=e.metapropertyOptionId_in;t=void 0!==r?r.map((function(e){return e})):null;var o,i=e.collectionId,a=e.assetType_in;o=void 0!==a?a.map(Ps):null;var s,u=e.tagNames_in;s=void 0!==u?u.map((function(e){return e})):null;var c=e.searchTerm;return dn([["isLimitedUse",void 0!==n?n:null],["metapropertyOptionId_in",t],["collectionId",void 0!==i?i:null],["assetType_in",o],["tagNames_in",s],["searchTerm",void 0!==c?c:null]].filter((function(e){return!0})))}function Qs(e){return e>=757540433?"DESC":"ASC"}function Rs(e){return e>=83152964?e>=868235851?"NAME":"PUBLISHED_AT":e>=39795671?"UPDATED_AT":"CREATED_AT"}function Fs(e){return dn([["direction",Qs(e.direction)],["field",Rs(e.field)]].filter((function(e){return!0})))}function Bs(e,t){if(void 0!==e){if(void 0!==t){var n=t;return{nodes:e.nodes.concat(n.nodes),totalCount:n.totalCount,pageInfo:n.pageInfo}}return e}return void 0!==t?t:void 0}function Hs(e){var t=e.searchAssets.assets;return rr(void 0!==t?Rn(t.nodes,(function(e){return e[1].node})):void 0,[])}function Vs(e){return function(e,t){switch(0|e.tag){case 0:var n=e[0];return void 0!==n?bt(0,[rn(Ct(t,sn(n)))]):e;case 1:return bt(1,[Ct(t,e[0])]);case 2:return e}}(e,Hs)}var Ds={definition:[function(e){var t,n=un(gi(vi(e)),"searchAssets");if(void 0!==n){var r,o=un(gi(vi(sn(n))),"assets");if(void 0!==o){var i=sn(o);if(void 0!==mi(i))r=void 0;else{var a,s=vi(i);if(void 0!==s){var u,c=sn(s),l=un(c,"nodes"),d=void 0!==l?gi(pi(sn(l))).map((function(e){var t=vi(e);if(void 0!==t){var n=un(sn(t),"__typename");return void 0!==n&&void 0!==di(sn(n))?[963041744,{node:qs(gi(vi(e)))}]:bn("Unexpected GraphQL query response")}return bn("Unexpected GraphQL query response")})):bn("Unexpected GraphQL query response"),f=un(c,"totalCount");if(void 0!==f){var v=fi(sn(f));u=void 0!==v?0|v:bn("Unexpected GraphQL query response")}else u=bn("Unexpected GraphQL query response");var p,h=un(c,"pageInfo");if(void 0!==h){var m=vi(sn(h));if(void 0!==m){var g,b=sn(m),x=un(b,"endCursor");if(void 0!==x){var y=sn(x);g=void 0!==mi(y)?void 0:rn(y)}else g=void 0;var w,k=un(b,"hasNextPage");if(void 0!==k){var N=hi(sn(k));w=void 0!==N?N:bn("Unexpected GraphQL query response")}else w=bn("Unexpected GraphQL query response");p={endCursor:g,hasNextPage:w}}else p=bn("Unexpected GraphQL query response")}else p=bn("Unexpected GraphQL query response");a={nodes:d,totalCount:u,pageInfo:p}}else a=bn("Unexpected GraphQL query response");r=a}}else r=void 0;t={assets:r}}else t=bn("Unexpected GraphQL query response");return{searchAssets:t}},"query searchAssets($filter: AssetFilter!, $after: Cursor, $orderBy: AssetOrder!) {\nsearchAssets(filter: $filter) {\nassets(after: $after, first: 50, orderBy: $orderBy) {\nnodes {\n__typename\n...DisplayAsset \n}\n\ntotalCount \npageInfo {\nendCursor \nhasNextPage \n}\n\n}\n\n}\n\n}\nfragment DisplayAsset on Asset {\n__typename\nid \nderivatives {\nthumbnail \n}\n\nextensions \nname \nurl \nisArchived \nisWatermarked \n}\n",function(e,t,n,r,o){return Ct(e,dn([["filter",Gs(t)],["after",void 0!==n?sn(n):null],["orderBy",Fs(r)]].filter((function(e){return!0}))))}],getPageInfo:function(e){var t=e.searchAssets.assets;if(void 0!==t)return t.pageInfo},concatNodes:function(e,t){return{searchAssets:{assets:Bs(e.searchAssets.assets,t.searchAssets.assets)}}}};function $s(e){return!0}function Ws(e){var r=e.url,o=e.cover,i=void 0===o||o,a=n((function(){return!1})),s=a[1],u="select-none w-full h-full "+(i?"object-cover ":"object-contain ")+(a[0]?" fade-in animation-duration-500":" invisible");return t("img",{className:u,draggable:!1,src:void 0!==r?r:"data:,",onLoad:function(e){return Ct(s,$s)}})}var Ys=Ws,Js=function(e){var n,r=e.urls,o=e.totalCount,i=(4,r.slice(0,4)),a=i.length;if(a>=5)n=null;else switch(a){case 0:n=t(Ws,{});break;case 1:var s=i[0];n=t(Ws,{url:s,cover:!1});break;case 2:var u=i[0],c=i[1];n=t(d,void 0,t("div",{className:"w-2/4 h-full"},t(Ws,{url:u})),t("div",{className:"w-2/4 h-full"},t(Ws,{url:c})));break;case 3:var l=i[0],f=i[1],v=i[2];n=t(d,void 0,t("div",{className:"w-2/4 h-full"},t(Ws,{url:l})),t("div",{className:"flex flex-col w-2/4"},t("div",{className:"h-2/4 bg-ui-500 fade-in"},t(Ws,{url:f})),t("div",{className:"h-2/4 bg-ui-600 fade-in"},t(Ws,{url:v}))));break;case 4:var p=i[0],h=i[1],m=i[2],g=i[3];n=t(d,void 0,t("div",{className:"flex flex-col w-2/4"},t("div",{className:"h-2/4"},t(Ws,{url:p})),t("div",{className:"h-2/4 bg-ui-400 fade-in"},t(Ws,{url:h}))),t("div",{className:"flex flex-col w-2/4"},t("div",{className:"h-2/4 bg-ui-500 fade-in"},t(Ws,{url:m})),t("div",{className:"h-2/4 bg-ui-600 fade-in"},t(Ws,{url:g}))))}var b=o>4?t("div",{className:"absolute text-ui-0 right-0 bottom-0 text-xl h-2/4 w-2/4 text-center flex items-center justify-center bg-ui-900"},"+"+String(o-4|0)):null;return t(d,void 0,n,b)},Xs=function(e){var n=e.alt,r=e.className,o=e.fadeIn,i=e.id,a=e.style,s=e.stacked,u=e.title,c=e.onClick,l=e.children,d=void 0===o||o,f=void 0!==s&&s,v=void 0!==l?sn(l):null,p={className:gr(["m-2 w-48 self-start group relative rounded bg-ui-500 shadow transition-shadow cursor-pointer",br(d,"fade-in-down"),xr(r)])};return void 0!==i&&(p.id=sn(i)),void 0!==a&&(p.style=sn(a)),void 0!==n&&(p.title=sn(n)),void 0!==c&&(p.onClick=sn(c)),t("div",p,t("div",{className:"overflow-hidden rounded"},t("div",{className:"flex h-32 relative"},v),t("header",{className:"p-3 truncate bg-ui-0"},u)),f?t("div",{className:"absolute border-b rounded left-px right-px h-3 -bottom-0.75"}):null)},Ks=function(e){var r=e.className,o=e.active,i=e.onClick,a=e.title,s=e.children,u=void 0!==o&&o,c=n((function(){return 870530776})),l=c[1],d=c[0],f=Xo(),v=gr(["inline-flex p-0.5 items-center text-md text-body-400 select-none shadow shadow-overlay focus:outline-none transition-color",u?"bg-brand-500 hover:bg-brand-600 text-ui-0":"bg-ui-0-.8 hover:bg-ui-0 hover:text-body-500",xr(r)]),p=u||870530776!==d?rn($o(f,-791844958,d)):void 0,h={className:v,onMouseOut:function(e){return Ct(l,(function(e){return 870530776}))},onMouseOver:function(e){return Ct(l,(function(e){return 1049777564}))}};return void 0!==p&&(h.style=sn(p)),void 0!==a&&(h.title=sn(a)),void 0!==i&&(h.onClick=sn(i)),t("button",h,s)};function Zs(e){return e.id}function eu(e){var t=e.derivatives.thumbnail;return void 0!==t?t:fr(Yn(e.extensions,0))}function tu(e){var t=Yn(e.extensions,0);if(void 0!==t){var n=t.toUpperCase();return"JPG"===n?"JPEG":n}}var nu=f((function(e){var n,r=e.className,o=e.fadeIn,i=e.asset,a=e.isSelected,s=e.onClick,u=e.theme,c=e.children,l=void 0===o||o,f=void 0!==c?sn(c):null,v=gr([xr(r),br(a,"shadow-outline")]);if(a&&void 0!==u){var p=u.colorPrimary;n=void 0!==p?{boxShadow:"0 0 0 2px "+String(p)}:void 0}else n=void 0;var h,m,g,b=Jo(),x=t(Ks,{className:"absolute left-0 top-0 ml-3 mt-3 rounded hidden group-hover:block group-hover:fade-in",onClick:function(e){var t;return e.stopPropagation(),(t=i.url,function(e){var n=t,r=e;return on(In.open(n,r,void 0))})("_blank"),0},title:vn("Open in new tab"),children:t(Qt,{className:"w-6 h-6"})}),y=!0===b.hideExternalAccess?null:x;if(void 0!==s){var w=s;h=function(e){return e.stopPropagation(),Ct(w,i)}}else h=void 0;if(i.isArchived||i.isWatermarked){var k=(g=[i.isArchived?vn("archived"):void 0,i.isWatermarked?vn("watermarked"):void 0],Dn(g,(function(e){return e}))).join(", ");m=t("span",{className:"overlay-pill left-0 bottom-0 max-w-32 truncate",title:k},k)}else m=null;var N=tu(i),C={alt:i.name,className:v,fadeIn:l,id:i.id,title:i.name,children:t(d,void 0,t(Ys,{url:eu(i),cover:!1}),a?t("div",{className:"absolute h-full w-full bg-ui-800 fade-in"}):null,y,t(Ks,{className:gr(["absolute right-0 top-0 mr-3 mt-3 rounded-full",br(!a,"hidden group-hover:block group-hover:fade-in")]),active:a,title:vn(a?"Deselect":"Select"),children:t(Kt,{className:"w-6 h-6"})}),m,void 0!==N?t("span",{className:"overlay-pill right-0 bottom-0"},N.toUpperCase()):null,f)};return void 0!==n&&(C.style=sn(n)),void 0!==h&&(C.onClick=sn(h)),t(Xs,C)})),ru=function(e){var n=e.title,r=e.rows,o=e.columns,i=void 0!==n?sn(n):null;return function(e,t){if(e<=0)return[];for(var n=new Array(e),r=0,o=e-1|0;r<=o;++r)n[r]=t(r);return n}(Ii(r,o),St((function(e){return t(Xs,{style:{animationDuration:String(Ii(Ui(e,o),200)+500|0)+"ms"},title:t(d,void 0,t(os,{width:70+yr(100,e)|0,className:"h-4"}),i),key:String(e)})})))};function ou(e,t){if(!e)throw new Error("Invariant failed")}function iu(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function au(){return(au=Object.assign||function(e){for(var t=arguments,n=1;n<arguments.length;n++){var r=t[n];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e}).apply(this,arguments)}function su(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var uu=new Map,cu=new Map,lu=new Map,du=0;function fu(e,t,n){void 0===n&&(n={}),n.threshold||(n.threshold=0);var r=n,o=r.root,i=r.rootMargin,a=r.threshold;if(uu.has(e)&&ou(!1),e){var s=function(e){return e?lu.has(e)?lu.get(e):(du+=1,lu.set(e,du.toString()),lu.get(e)+"_"):""}(o)+(i?a.toString()+"_"+i:a.toString()),u=cu.get(s);u||(u=new IntersectionObserver(pu,n),s&&cu.set(s,u));var c={callback:t,element:e,inView:!1,observerId:s,observer:u,thresholds:u.thresholds||(Array.isArray(a)?a:[a])};return uu.set(e,c),u.observe(e),c}}function vu(e){if(e){var t=uu.get(e);if(t){var n=t.observerId,r=t.observer,o=r.root;r.unobserve(e);var i=!1,a=!1;n&&uu.forEach((function(t,r){r!==e&&(t.observerId===n&&(i=!0,a=!0),t.observer.root===o&&(a=!0))})),!a&&o&&lu.delete(o),r&&!i&&r.disconnect(),uu.delete(e)}}}function pu(e){e.forEach((function(e){var t=e.isIntersecting,n=e.intersectionRatio,r=e.target,o=uu.get(r);if(o&&n>=0){var i=o.thresholds.some((function(e){return o.inView?n>e:n>=e}));void 0!==t&&(i=i&&t),o.inView=i,o.callback(i,e)}}))}var hu=function(e){var n,r;function o(){for(var t,n=arguments,r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=n[i];return iu(su(t=e.call.apply(e,[this].concat(o))||this),"state",{inView:!1,entry:void 0}),iu(su(t),"node",null),iu(su(t),"handleNode",(function(e){t.node&&(vu(t.node),e||t.props.triggerOnce||t.setState({inView:!1,entry:void 0})),t.node=e||null,t.observeNode()})),iu(su(t),"handleChange",(function(e,n){(e!==t.state.inView||e)&&t.setState({inView:e,entry:n}),t.props.onChange&&t.props.onChange(e,n)})),t}r=e,(n=o).prototype=Object.create(r.prototype),n.prototype.constructor=n,n.__proto__=r;var i=o.prototype;return i.componentDidMount=function(){this.node||ou(!1)},i.componentDidUpdate=function(e,t){e.rootMargin===this.props.rootMargin&&e.root===this.props.root&&e.threshold===this.props.threshold||(vu(this.node),this.observeNode()),t.inView!==this.state.inView&&this.state.inView&&this.props.triggerOnce&&(vu(this.node),this.node=null)},i.componentWillUnmount=function(){this.node&&(vu(this.node),this.node=null)},i.observeNode=function(){if(this.node){var e=this.props,t=e.threshold,n=e.root,r=e.rootMargin;fu(this.node,this.handleChange,{threshold:t,root:n,rootMargin:r})}},i.render=function(){var e=this.state,n=e.inView,r=e.entry;if(!function(e){return"function"!=typeof e.children}(this.props))return this.props.children({inView:n,entry:r,ref:this.handleNode});var o=this.props,i=o.children,a=o.as,s=o.tag,u=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(o,["children","as","tag","triggerOnce","threshold","root","rootMargin","onChange"]);return t(a||s||"div",au({ref:this.handleNode},u),i)},o}(c);iu(hu,"displayName","InView"),iu(hu,"defaultProps",{threshold:0,triggerOnce:!1});var mu={inView:!1,entry:void 0},gu=function(e){var r=e.isLoading,a=e.hasNextPage,s=e.loadMore,u=e.children,c=function(e){void 0===e&&(e={});var t=o(),r=n(mu),i=r[0],a=r[1];return[l((function(n){t.current&&(vu(t.current),e.triggerOnce||a(mu)),n&&fu(n,(function(t,r){a({inView:t,entry:r}),t&&e.triggerOnce&&vu(n)}),e),t.current=n}),[e.threshold,e.root,e.rootMargin,e.triggerOnce]),i.inView,i.entry]}({}),f=c[1];i((function(){f&&!r&&a&&Ct(s,0)}),[f]);var v=a?t("div",{ref:c[0],className:"relative h-32 w-full"},t(ni,{className:br(!f,"hidden")})):null;return t(d,void 0,u,v)},bu=On;function xu(e){return e.preventDefault(),0}function yu(e,t){return Vn(e,(function(e){return t===e}))}function wu(e){return{x:e.clientX,y:e.clientY,target:e.target}}function ku(e,t,n,r,o,i){switch(0|e.tag){case 0:var a=e[0];return Hn(a.added,(function(e){return""===e.id||e.classList.contains("shadow-outline")?0:(e.classList.add("selected-outline"),void 0!==r?(On(e,"box-shadow","0 0 0 2px "+String(sn(r))),0):0)})),Hn(a.removed,(function(e){return""!==e.id?(e.classList.remove("selected-outline"),ur(r)&&!e.classList.contains("shadow-outline")?(On(e,"box-shadow",""),0):0):0}))}if(void 0===n)return 0;var s;switch(Hn(Array.prototype.slice.call(sn(n).querySelectorAll(".selected-outline")),(function(e){var t=Ct(An.ofNode,e);return void 0!==t?(sn(t).classList.remove("selected-outline"),0):0})),0|t.tag){case 0:var u=t[0];s=void 0!==u?u:void 0;break;case 1:var c=t[0];s=0!==c.length?c:void 0;break;case 2:s=void 0}if(void 0===s)return 0;var l=Dn(e[0].selected,(function(e){var t=e.id;return""===t?void 0:t})),d=Bn(s,(function(e){var t=e.id,n=function(e){return t===e};return function(e){return Vn(e,n)}(l)}));switch(0|e.tag){case 0:return 0;case 1:return Ct(o,d);case 2:return Ct(i,d)}}var Nu=f((function(e){var n,r=e.assets,a=e.count,s=e.hasNextPage,u=e.isLoading,c=e.loadMore,l=e.onSelect,d=e.onToggle,f=e.renderAsset,v=e.renderEmptyState,p=e.selectedAssetIds,h=e.selectionMode,m=e.theme,g=e.children,b=void 0!==s&&s,x=void 0!==u&&u,y=void 0!==c?c:function(e){return 0},w=void 0!==l?l:function(e){return 0},k=void 0!==d?d:function(e){return 0},N=void 0!==v?v:function(e){return null},C=void 0!==p?p:[],S=void 0!==h?h:2,_=void 0!==g?sn(g):null,L=dn(Rn(C,(function(e){return[e,0]}))),A=Ki(0),T=A.nodeRef,O=A.node,M=A.dimensions,U=ar(Mo(),O),I=o(void 0),E=tr(m,Do),j=_t(hs,void 0,(function(e){return e.preselectedAssets}));if(i((function(){I.current=function(e){return ku(e,r,U,E,w,k)}}),[U,r]),i((function(){if(void 0===O||void 0===U);else if(void 0!==(S>=2?0:void 0)){var e=function(e){var t=function(t,n){var r=void 0===t||t,o=function(t){return e.rootElement.addEventListener(t,n,{passive:r,capture:!1,once:!1}),0};return function(e){return Hn(e,o)}},n=function(t,n){var r=void 0===t||t,o=function(t){return e.rootElement.removeEventListener(t,n,{passive:r,capture:!1}),0};return function(e){return Hn(e,o)}},r={added:[],removed:[],scrollAvailable:!0,scrollSpeed:0,selected:[],singleClick:!0},o={start:{x:0,y:0},end_:{x:0,y:0}},i=jn.createElement("div");i.className=e.rectangleClass;var a=e.rectangleColor;void 0!==a&&bu(i,"border-color",a);var s=bu(bu(bu(bu(i,"will-change","top, left, bottom, right, width, height"),"top","0"),"left","0"),"position","fixed"),u=function(t){var n,i=e.targetContainer,a=i.getBoundingClientRect(),u=o.end_.x,c=u<a.left?a.left:u>a.left+a.width?a.left+a.width:u,l=o.end_.y;if(l<a.top){var d=i.scrollTop;r.scrollSpeed=0!==d?-Math.abs(a.top-l):0,n=a.top}else if(l>a.top+a.height){var f=i.scrollHeight-i.scrollTop-i.clientHeight;r.scrollSpeed=0!==f?Math.abs(a.top+a.height-l):0,n=a.top+a.height}else r.scrollSpeed=0,n=l;var v=Math.min(o.start.x,c),p=Math.min(o.start.y,n),h=Math.max(o.start.x,c),m=Math.max(o.start.y,n);return bu(bu(bu(bu(s,"top",String(p)+"px"),"left",String(v)+"px"),"width",String(h-v)+"px"),"height",String(m-p)+"px"),0},c={position:o,el:s,redraw:u},l=jn.createElement("div");l.appendChild(s);var d=bu(bu(bu(bu(bu(l,"overflow","hidden"),"pointer-events","none"),"position","fixed"),"z-index","9999999"),"transform","translate3d(0, 0, 0)"),f=function(e){if(void 0!==e){var t=sn(e),n=t.top,r=t.left,o=t.width,i=t.height;return bu(bu(bu(bu(d,"top",String(n)+"px"),"left",String(r)+"px"),"width",String(o)+"px"),"height",String(i)+"px"),0}return bu(bu(bu(bu(d,"top","0"),"left","0"),"width","100%"),"height","100%"),0},v=function(e){return r.selected=[],r.added=[],r.removed=[],0},p=function(t){var n=e.targetContainer.querySelector(".card-list");if(null==n)return 0;var o=s.getBoundingClientRect(),i=[];r.added=[],r.removed=[];var a=function(e){return t=e.getBoundingClientRect(),n=o,t.right>=n.left&&t.left<=n.right&&t.bottom>=n.top&&t.top<=n.bottom?(yu(r.selected,e)||$n(e,r.added),$n(e,i)):0;var t,n};return function(e){Hn(e,a)}(Tn(n)),Hn(r.selected,(function(e){return yu(i,e)?0:$n(e,r.removed)})),r.selected=i,0},h=function(t){t.preventDefault();var n=wu(t);if(o.end_={x:n.x,y:n.y},r.scrollAvailable&&0!==r.scrollSpeed){var i=function(t){if(0!==r.scrollSpeed){if(0!==r.scrollSpeed){var n=e.targetContainer.scrollTop;e.targetContainer.scrollTop=Math.ceil(r.scrollSpeed/10)+n,o.start.y=o.start.y-(e.targetContainer.scrollTop-n)}return u(),p(),Ct(e.send,bt(0,[{added:r.added,removed:r.removed,selected:r.selected}])),requestAnimationFrame(i),0}return 0};return requestAnimationFrame(i),0}return u(),p(),Ct(e.send,bt(0,[{added:r.added,removed:r.removed,selected:r.selected}]))},m=function(e){var t=li(e.wheelDeltaY);return"number"==typeof t||1!==t.tag?0:(r.scrollSpeed=r.scrollSpeed+10*-t[0],h(e))},g=function(i){i.preventDefault();var a=wu(i);if(Math.abs(a.x+a.y-(o.start.x+o.start.y))>=10){n(!1,g)(["mousemove","touchmove"]),t(!1,h)(["mousemove","touchmove"]),bu(s,"display","block"),e.rootElement.appendChild(d),r.singleClick=!1;var u=e.targetContainer,c=u.getBoundingClientRect();if(u.scrollHeight!==Math.round(c.height)){r.scrollAvailable=!0,t(!1,m)(["wheel"]),f(rn(c));var l=-c.top,v=-c.left;bu(bu(s,"margin-top",String(l)+"px"),"margin-left",String(v)+"px")}else r.scrollAvailable=!1,f(void 0),bu(bu(s,"margin-top","0"),"margin-left","0");return h(i)}return 0},b=function(t){n(void 0,g)(["mousemove","touchmove"]),n(void 0,h)(["touchmove","mousemove"]),n(void 0,b)(["mouseup","touchcancel","touchend"]),r.singleClick||(p(),t.ctrlKey||t.metaKey?Ct(e.send,bt(2,[{added:r.added,removed:r.removed,selected:r.selected}])):Ct(e.send,bt(1,[{added:r.added,removed:r.removed,selected:r.selected}]))),r.scrollSpeed=0,n(void 0,m)(["wheel"]);return nr(on(d.parentNode),(function(e){return e.removeChild(d)})),n(void 0,xu)(["selectstart"]),bu(s,"display","none"),0},x=function(n){if("mousedown"===n.type&&0!==n.button)return 0;var i=wu(n);return function(e){for(var t=e,n=5;;){var r=n,o=t;if(0===r)return!1;if("BUTTON"===o.tagName)return!0;var i=o.parentElement;if(null==i)return!1;n=r-1|0,t=i}}(i.target)?0:yu(function(e){var t=e.path||e.composedPath&&e.composedPath();if(t)return t;var n=e.target.parentElement;for(t=[e.target,n];n=n.parentElement;)t.push(n);return t.push(document,window),t}(n),e.targetContainer)?(o.start={x:i.x,y:i.y},o.end_={x:0,y:0},r.singleClick=!0,v(),t(void 0,xu)(["selectstart"]),t(!1,g)(["touchmove","mousemove"]),t(!1,b)(["mouseup","touchcancel","touchend"])):0},y=function(e){return n(void 0,x)(["mousedown"]),n(!1,x)(["touchstart"])};return{selectAll:function(t){var n=Rn(t,(function(t){return Array.prototype.slice.call(e.rootElement.querySelectorAll(t))}));return function(e){return function(e,t,n){var r,o;o=n.length;var i=[];for(r=0;r<o-1;++r)i.push(n[r]);var a=n[o-1];for(r=0;r<a.length;++r)i.push(a[r]);return e.concat.apply(e,i)}(e,0,[n])}},on:t,off:n,state:r,makePayload:function(e){return{added:r.added,removed:r.removed,selected:r.selected}},Area:c,Clipping:{el:d,redraw:f},clearSelection:v,removeFromSelection:function(e){return $n(e,r.removed),t=e,-1!==(o=(n=r.selected).indexOf(t))?(n.splice(o,1),0):0;var t,n,o},updateCollidingElements:p,onTapMove:h,manualScroll:m,delayedTapMove:g,onTapStop:b,onTapStart:x,enable:function(e){return t(void 0,x)(["mousedown"]),t(!1,x)(["touchstart"])},disable:y,destroy:function(e){y();var t=function(e){return e.removeChild(d)};return function(e){return nr(e,t)}(on(d.parentNode))}}}({send:function(e){var t=I.current;return void 0!==t?Ct(t,e):0},rootElement:sn(U),rectangleClass:"rounded border-2 border-brand-500",rectangleColor:E,targetContainer:sn(O)});return Ct(e.enable,0),function(t){return Ct(e.destroy,0)}}}),[U,O,ku,m]),void 0!==a)n=[1,a];else if(void 0!==M){var z=M;n=[zn(z.height/188),(z.width-16)/208|0]}else n=[0,0];var q,P,G=n[1],Q=n[0],R=0;switch(0|r.tag){case 0:var F=r[0];void 0!==F?(P=F,R=2):R=1;break;case 1:var B=r[0];0!==B.length?(P=B,R=2):q=Ct(N,0);break;case 2:R=1}switch(R){case 1:q=t(ru,{rows:Q,columns:G});break;case 2:var H=function(e){return Ct(k,[e])};q=t(gu,{isLoading:x,hasNextPage:b,loadMore:y,children:Fn(P,(function(e,n){!function(e){var t,n,r=(t=e.url.indexOf("mediaId="),2!==(n=e.url.substring(t).split("=")).length?"":n[1]);if(0!==j.length&&!function(e,t){for(var n=t.length,r=0;;){var o=r;if(o===n)return!0;if(!Ct(e,t[o]))return!1;r=o+1|0}}((function(e){return e!==r}),j)){var o=Bn(j,(function(e){return e!==r}));Ct(ps,bt(4,[o])),Ct(k,[e])}}(n);var r=ur(un(L,n.id)),o=e>=Ii(Q,G);return void 0!==f?Ot(f,n,e,o,r,H):t(nu,{fadeIn:o,asset:n,isSelected:r,onClick:H,key:n.id})}))})}return t("div",{ref:T,className:"flex flex-col flex-grow overflow-y-auto"},_,t("div",{ref:T,className:"card-list"},q))}));function Cu(e){return t("svg",{className:"h-20",viewBox:"0 5 60 82"},t("defs",void 0,t("filter",{id:"prefix__a",height:"105%",width:"103.3%",filterUnits:"objectBoundingBox",x:"-1.7%",y:"-1.2%"},t("feOffset",{dy:"2",in:"SourceAlpha",result:"shadowOffsetOuter1"}),t("feColorMatrix",{in:"shadowOffsetOuter1",values:"0 0 0 0 0 0 0 0 0 0.133333333 0 0 0 0 0.2 0 0 0 0.05 0"})),t("filter",{id:"prefix__c",height:"120%",width:"110%",filterUnits:"objectBoundingBox",x:"-5%",y:"-5%"},t("feOffset",{dy:"2",in:"SourceAlpha",result:"shadowOffsetOuter1"}),t("feColorMatrix",{in:"shadowOffsetOuter1",values:"0 0 0 0 0 0 0 0 0 0.133333333 0 0 0 0 0.2 0 0 0 0.05 0"})),t("path",{id:"prefix__b",d:"M5 5h35l20 20v55a5 5 0 01-5 5H5a5 5 0 01-5-5V10a5 5 0 015-5z"}),t("path",{id:"prefix__d",d:"M40 5l20 20H45a5 5 0 01-5-5V5z"})),t("g",{fill:"none",fillRule:"evenodd"},t("use",{fill:"#000",filter:"url(#prefix__a)",xlinkHref:"#prefix__b"}),t("use",{fill:"#FFF",xlinkHref:"#prefix__b"}),t("g",{fillRule:"nonzero"},t("use",{fill:"#000",filter:"url(#prefix__c)",xlinkHref:"#prefix__d"}),t("use",{fill:"#FFF",xlinkHref:"#prefix__d"}))))}var Su=function(e){var n=e.onReset;return t("div",{className:" w-full h-full flex flex-col items-center justify-center"},t("div",{className:"bg-ui-400 rounded-full w-40 h-40 flex items-center justify-center"},t(Cu,{}),t(Rt,{className:"absolute mt-1 ml-px text-body-300",style:{height:"36px",width:"36px"}})),t("h1",{className:"mt-6 text-2xl"},vn("No results found")),t("span",{className:"mt-4 text-body-400"},vn("Try adjusting the filter to find assets.")),t(ti,{className:"mt-8",title:vn("Reset filters"),onClick:function(e){return Ct(n,0)},kind:-791844958,children:vn("Reset filters")}))};function _u(e){return bt(0,[e])}var Lu=Cr({initialState:[],reducer:function(e,t){if("number"==typeof t)return[];switch(0|t.tag){case 1:var n=t[0];return void 0!==e.find((function(e){return!e.tag&&n.id===e[0].id}))?[]:[bt(0,[n])];case 0:case 2:break;case 3:var r=t[0],o=Bn(e,(function(e){return!e.tag||e[0].id!==r.id}));return e.length===o.length&&$n(bt(1,[r]),o),o}var i,a,s;if("number"==typeof t)i=bn("Unreachable");else switch(0|t.tag){case 0:case 2:i=dn((a=t[0],s=Zs,Qn(a,(function(e){var t=e;return[Ct(s,t),t]}))));break;default:i=bn("Unreachable")}return function(e,t){for(var n=e.length,r=t.length,o=new Array(n+r|0),i=0,a=n-1|0;i<=a;++i)o[i]=e[i];for(var s=0,u=r-1|0;s<=u;++s)o[n+s|0]=t[s];return o}(Bn(e,(function(e){if(e.tag)return!0;var n=e[0].id;if(void 0===un(i,n))return!0;if(function(e,t){delete e[t]}(i,n),"number"==typeof t)return bn("Unreachable");switch(0|t.tag){case 0:return!0;case 2:return!1;default:return bn("Unreachable")}})),function(e){return Rn(e,_u)}(ln(i)))},equal:function(e,t){if(e.length!==t.length)return!1;for(var n=0;;){var r=n;if(r===e.length)return!0;if(!function(e){return function(t){return r=t,(n=e).tag?!!r.tag&&xi(n[0],r[0]):!r.tag&&(o=n[0],i=r[0],o.id===i.id);var n,r,o,i}}(kt(e,r))(kt(t,r)))return!1;n=r+1|0}}}),Au=Lu.send,Tu=Lu.use;function Ou(e){return Ct(Au,bt(0,[e]))}function Mu(e){var n,r=e.onClick,o=e.title,i=e.icon;if(void 0!==i){var a=i;n=t(a.make,Mt(a.makeProps,"w-5 h-5 mr-1",void 0,void 0,void 0,void 0,0))}else n=null;var s={className:"w-5 h-5 ml-1 -mr-1 text-body-300 hover:text-body-400 cursor-pointer",title:vn("Remove filter")};return void 0!==r&&(s.onClick=sn(r)),t(Ja,{className:"mr-2 fade-in-down",children:null},n,t("span",{className:"max-w-32 truncate",title:o},o),t(tn,s))}function Uu(e){var n=Ct(_s,0),r=n.tags,o=n.metaproperties,i=n.assetTypes,a=Fa(o)&&Fa(i)&&$a(r)?void 0:rn(t(ti,{className:"flex-shrink-0 fade-in-down",onClick:function(e){return Ct(Ss,0)},kind:-323491629,children:vn("Clear filters")})),s={className:"ml-2",children:null};void 0!==a&&(s.static=sn(a));var u=function(e){return t(Mu,{onClick:function(t){return Ct(Ss,bt(3,[e]))},title:e.label,key:e.id})},c=function(e){return t(Mu,{onClick:function(t){return Ct(Ss,bt(5,[e]))},title:e,key:e})};return t(As,s,Rn(Ha(i),(function(e){var n=ss(e);return t(Mu,{onClick:function(t){return Ct(Ss,bt(1,[e]))},title:n,icon:us(e),key:n})})),function(e){return Rn(e,u)}(Ha(o)),function(e){return Rn(e,c)}(Ya(r)))}function Iu(e){return t(Su,{onReset:function(e){return Ct(Ss,0),Ct(ps,bt(0,[""])),Ct(ps,bt(1,[""]))}})}fo((function(e){return Ct(Au,0)}));var Eu=function(e){var n=e.connection,r=e.totalCount,o=e.showActiveFilters,a=void 0!==o&&o,s=n.isLoading,u=n.data,c=Jo(),l=Dn(Ct(Tu,0),(function(e){return e.tag?void 0:e[0].id}));switch(i((function(){s||Ct(ps,bt(3,[s]))}),[s]),0|u.tag){case 0:case 1:break;case 2:return t(Oi,{error:u[0],onRetry:n.executeQuery})}var f,v=Vi(u);if(void 0!==v){var p=sn(v).searchAssets.assets;f=void 0!==p?p.totalCount:void 0}else f=void 0;var h,m=ar(f,r);if(void 0!==m){var g=m;h=t("span",{key:String(g),className:"flex-shrink-0 text-body-400 fade-in-down"},hr(g,vn("{} assets"),vn("{} asset")))}else h=null;var b=c.selectionMode,x={assets:Vs(u),hasNextPage:n.hasNextPage,isLoading:s,loadMore:n.loadMore,onSelect:Ou,onToggle:function(e){return function(e,t){if(t>=2)return Ct(Au,bt(2,[e]));return nr(Yn(e,0),(function(e){return Ct(Au,bt(1,[e]))}))}(e,b)},renderEmptyState:Iu,selectedAssetIds:l,selectionMode:c.selectionMode,children:t("div",{className:"flex justify-between items-center px-4 pt-4 pb-2 z-10"},h,a?t(Uu,{}):null,t(ga,{}),t(ba,{}))};return void 0!==m&&(x.count=sn(m)),void 0!==c.theme&&(x.theme=sn(c.theme)),t(d,void 0,t(Nu,x))},ju=function(e){var n=Ct(_s,0),r=ms(),o=pa.usePage(0)[0],i=Jo(),a=Ko(),s=Tt(Wi(Ds),void 0!==a?sn(a):ks(n,r,i.assetTypes),void 0,{field:o.field,direction:o.direction},0);return t(d,void 0,cr(a)?t("nav",{className:"flex justify-between bg-ui-0 px-4 py-2 z-20"},t(zs,{})):null,t(Eu,{connection:s,showActiveFilters:cr(a)}))},zu=function(e){var n=Ct(Li,0);return t("div",{className:"inline-flex mr-auto"},t(ti,{className:"number"==typeof n&&0===n?"bg-ui-500 text-body-500":"",onClick:function(e){return Ct(_i,0)},children:vn("Assets")}),t(ti,{className:"number"==typeof n&&0!==n?"bg-ui-500 text-body-500":"",onClick:function(e){return Ct(_i,1)},children:vn("Collections")}))},qu=function(e){var n=Ct(Li,0),r=_t(hs,void 0,(function(e){return"number"==typeof n?0!==n?[e.collections,ds,e.isLoading]:[e.assets,cs,e.isLoading]:[e.collection,ls,e.isLoading]})),a=r[1],s=r[0],c=o(null);i((function(){var e=c.current;null!=e&&""===s&&(e.value="")}),[s,Ur]);var l,d,f=u((function(){return Ao(500,(function(e){return Ct(ps,Ct(a,e))}))}),[a]),v=vn("number"==typeof n&&0!==n?"Search for collections":"Search for assets"),p=s.trim();return l=r[2]?t(ni,{className:"absolute right-0 mr-3 h-full"}):""===p?null:t("button",{className:"h-full absolute right-3 focus:outline-none text-body-300 hover:text-body-400 fade-in",onClick:function(e){var t=c.current;return null!=t&&(t.value=""),Ct(ps,Ct(a,""))}},t(Xt,{className:"w-6 h-6"})),t("div",{className:"w-full inline-flex relative text-body-300 focus-within:text-body-400 transition-color",style:{maxWidth:"440px"}},t("div",{className:"pointer-events-none absolute inset-y-0 left-0 pl-3 flex items-center"},t(Rt,{className:"fill-current pointer-events-none w-6 h-6"})),t("input",{key:(d=n,"number"==typeof d?0!==d?"Collections":"Assets":"Collection("+String(d[0].id)+")"),ref:c,defaultValue:s,className:"appearance-none block w-full border border-ui-600 rounded py-2 pr-4 pl-10 text-body-500 placeholder-body-300 focus:outline-none hover:border-ui-900 focus:border-ui-900 transition-color",placeholder:v,onChange:function(e){return Ct(f,dr(e))}}),l)},Pu=function(e){var n=e.collection,r=_t(hs,void 0,(function(e){var t=e.collection.trim();return""===t?void 0:t})),o=pa.usePage([n])[0],i=Jo(),a=Tt(Wi(Ds),{collectionId:n.id,assetType_in:i.assetTypes,metapropertyOptionId_in:void 0,searchTerm:r,tagNames_in:void 0,isLimitedUse:!1},void 0,{field:o.field,direction:o.direction},0);return t(d,void 0,t("nav",{className:"px-4 py-4"},t("span",{className:"text-body-400 select-none cursor-pointer",onClick:function(e){return Ct(_i,1)}},vn("Collections")," / "),t("span",void 0,n.name)),t(Eu,{connection:a,totalCount:n.assetCount}))},Gu=f((function(e){var n=e.className,r=e.collection,o=e.fadeIn,i=e.isSelected,s=e.style,u=void 0===o||o,c=a(Wo).selectionMode,l=gr([xr(n),br(i,"shadow-outline")]),f=t(d,void 0,t("div",{className:"truncate"},r.name),t("div",{className:"mt-2 text-sm text-body-400"},hr(r.assetCount,vn("{} assets"),vn("{} asset")))),v=Jo(),p=t(Ks,{className:"absolute left-0 top-0 ml-3 mt-3 rounded hidden group-hover:block group-hover:fade-in",onClick:function(e){var t;return e.stopPropagation(),(t=r.url,function(e){var n=t,r=e;return on(In.open(n,r,void 0))})("_blank"),0},title:vn("Open in new tab"),children:t(Qt,{className:"w-6 h-6"})}),h=!0===v.hideExternalAccess?null:p,m={alt:r.name,className:l,fadeIn:u,id:r.id,stacked:!0,title:f,onClick:function(e){return Ct(_i,[r])},children:t(d,void 0,t(Js,{urls:r.thumbnailUrls,totalCount:r.assetCount}),i?t("div",{className:"absolute h-full w-full bg-ui-800 fade-in"}):null,h,2===c?t(Ks,{className:gr(["absolute right-0 top-0 mr-3 mt-3 rounded-full",br(!i,"hidden group-hover:block group-hover:fade-in")]),active:i,onClick:function(e){return e.stopPropagation(),Ct(Au,bt(3,[r]))},title:vn(i?"Deselect":"Select"),children:t(Kt,{className:"w-6 h-6"})}):null)};return void 0!==s&&(m.style=sn(s)),t(Xs,m)})),Qu=f((function(e){var n,r=e.connection,o=r.data,i=Ki(0),a=i.dimensions,s=dn(Dn(Ct(Tu,0),(function(e){if(e.tag)return[e[0].id,0]})));if(void 0!==a){var u=a;n=[zn(u.height/184),(u.width-32)/204|0]}else n=[0,0];var c,l,d=n[1],f=n[0],v=0;switch(0|o.tag){case 0:var p=o[0];void 0!==p?(l=sn(p),v=2):v=1;break;case 1:var h=o[0];Wn(h.collections.nodes)?c=t(Su,{onReset:function(e){return Ct(ps,bt(2,[""]))}}):(l=h,v=2);break;case 2:v=1}switch(v){case 1:c=t(ru,{title:t("div",{className:"mt-2 text-sm"},mr),rows:f,columns:d});break;case 2:var m=l.collections.nodes;c=t(gu,{isLoading:r.isLoading,hasNextPage:r.hasNextPage,loadMore:r.loadMore,children:Fn(m,(function(e,n){var r=ur(un(s,n.id)),o=e>=Ii(f,d);return t(Gu,{collection:n,fadeIn:o,isSelected:r,key:n.id})}))})}return t("div",{ref:i.nodeRef,className:"card-list"},c)})),Ru=function(e){var n=_t(hs,void 0,(function(e){var t=e.collections.trim();return""===t?void 0:t})),r=pa.usePage(1)[0],o=Tt(Wi(Ni),void 0,n,{field:r.field,direction:r.direction},0),a=o.isLoading,s=o.data;switch(i((function(){a||Ct(ps,bt(3,[a]))}),[a]),0|s.tag){case 0:case 1:break;case 2:return t(Oi,{error:s[0],onRetry:o.executeQuery})}var u=Vi(s),c=void 0!==u?t("span",{key:"a",className:"flex-shrink-0 flex-grow text-body-400 fade-in-down"},hr(sn(u).collections.totalCount,vn("{} collections"),vn("{} collection"))):t("span",{key:"b",className:"flex-grow"});return t("div",{className:"flex flex-col flex-grow overflow-y-auto"},t("div",{className:"flex items-center px-4 pt-4 pb-2 z-10"},c,t(ga,{options:[-600305078,868235851]}),t(ba,{})),t(Qu,{connection:o}))},Fu=/([a-z0-9])([A-Z])/g;function Bu(e){return e.replace(Fu,"$1 $2")}var Hu="\n id\n name\n description\n databaseId\n createdAt\n originalUrl\n publishedAt\n tags\n type\n updatedAt\n url\n metaproperties {\n nodes {\n name\n type\n options {\n name\n displayLabel\n }\n }\n }\n textMetaproperties {\n name\n value\n }\n derivatives {\n thumbnail\n webImage\n }\n ... on Video {\n previewUrls\n }\n ";function Vu(e){return"\n fragment AddMediaAsset on Asset { "+String(e)+" }\n "}function Du(e,t,n){var r=Fi,o={ids:Rn(e,(function(e){return e[0].id}))};return Ot(r,!1,"\n query getAssetsById($ids: [ID!]!) {\n nodes(ids: $ids) {\n __typename\n id\n ...on Asset {\n ...AddMediaAsset\n files\n }\n ...on Collection {\n assets {\n nodes {\n __typename\n id\n ...AddMediaAsset\n }\n }\n }\n }\n }\n "+Vu(rr(t,Hu)),o,(function(e){return ln((t=function(e,t){return"Collection"===t.__typename?(Hn(t.assets.nodes,(function(t){return e[t.id]=t,0})),e):(e[t.id]=t,e)},n={},function(e,t,n){return function(e,t,n){for(var r=t,o=0,i=e.length-1|0;o<=i;++o)r=n(r,e[o]);return r}(e,t,Lt(n))}(e.nodes,n,t)));var t,n}),n)}function $u(e,t,n){var r={id:e};return Ot(Fi,!1,"\n query getAssetById($id: ID!) {\n node(id: $id) {\n __typename\n id\n ...on Asset {\n ...AddMediaAsset\n files\n }\n }\n }\n "+Vu(rr(t,Hu)),r,(function(e){return e.node}),n)}function Wu(e){var r=e.asset,o=e.onChange,a=n((function(){return 1})),s=a[1],u=a[0],c=so(),l=Jo().assetFieldSelection;i((function(){Ct(s,(function(e){return 1})),Ct(o,void 0),function(e,t,n){return Fr((function(e){return Promise.resolve(ir(function(e){return Pr((function(e){return qr("files",(function(e){return function(e,t){if("object"!=typeof t||Array.isArray(t)||null===t)throw[Ir,"Expected object, got "+JSON.stringify(t)];for(var n=Object.keys(t),r={},o=0,i=n.length-1|0;o<=i;++o){var a,s=n[o];try{a=Ct(e,t[s])}catch(e){var u=gn(e);if(u[0]===Ir)throw[Ir,u[1]+"\n\tin dict"];throw u}r[s]=a}return r}((function(e){return{url:qr("url",zr,e),width:Pr((function(e){return qr("width",jr,e)}),e),height:Pr((function(e){return qr("height",jr,e)}),e),fileSize:Pr((function(e){return qr("fileSize",jr,e)}),e)}}),e)}),e)}),e)}(e),"Error retrieving asset files"))}),$u(e.id,t,n))}(r,l,c).then((function(e){if(e.tag)console.error(e[0]),Ct(s,(function(e){return 0}));else{var t,n=e[0];if(void 0!==un(n,"transformBaseUrl"))t="transformBaseUrl";else{var r=un(n,"original");t=void 0!==r?"original":"webImage"}Ct(s,(function(e){return[n,t]})),Ct(o,un(n,t))}return Qr(0)}))}),[r.id]);var f="number"==typeof u?0!==u?t(os,{width:50,className:"h-4"}):"Error":Bu(u[1]);return t(na,{className:"py-2",buttonClassName:"mr-4 capitalize",buttonKind:67972948,direction:19067,title:f,disabled:1===u,children:function(e){if("number"==typeof u)return null;var n=u[1];return t("ul",{className:"overflow-y-auto pb-1 max-h-400"},Rn(cn(u[0]),(function(r){var i,a=r[1],u=r[0];if("transformBaseUrl"===u)i=t(qt,{className:"w-6 h-6"});else{var c=pr.extension(a.url);i=void 0!==c?c:t(Dt,{className:"w-6 h-6"})}var l,f=a.width;if(void 0!==f){var v=a.height;l=void 0!==v?String(f)+" x "+String(v)+" px":null}else l=null;var p=a.fileSize,h=void 0!==p?kr(p):null,m=void 0!==a.width&&void 0!==a.height&&void 0!==a.fileSize?t("span",{className:"mx-2"},"•"):null;return t(ea,{className:"px-3 py-2",onClick:function(t){return function(e){Ct(s,(function(t){if("number"==typeof t)return t;var n=t[0];return Ct(o,un(n,e)),[n,e]}))}(u),Ct(e,0)},selected:n===u,children:null,key:u},t("div",{className:"w-10 h-10 mr-3 bg-ui-500 rounded flex items-center justify-center font-semibold text-body-400 text-xs uppercase"},i),t("div",{className:"flex-grow w-40"},t("div",{className:"capitalize text-body-500 truncate"},Bu(u)),t("div",{className:"text-sm"},t(d,void 0,l,m,h))))})))}})}var Yu=function(e){var r,o,i=e.selection,a=Jo(),s=a.selectionMode,u=a.onSuccess,c=a.assetFieldSelection,l=n((function(){return 1!==s?4:3})),f=l[1],v=l[0],p=so();if(1!==s||1!==i.length)r=null;else{var h=i[0];r=h.tag?null:t(Wu,{asset:h[0],onChange:function(e){if(void 0!==e){var t=e;return Ct(f,(function(e){return[t]}))}return Ct(f,(function(e){return 3}))}})}var m=0;if("number"==typeof v)switch(v){case 0:o=t(Kt,{className:"w-6 h-6"});break;case 1:o=vn("Retry");break;case 2:o=t(ni,{className:"text-ui-0"});break;case 3:case 4:m=1}else m=1;return 1===m&&(o=hr(i.length,vn("Add assets"),vn("Add asset"))),t(d,void 0,r,t(ti,{className:"relative",disabled:"number"==typeof v&&(3===v||2===v),onClick:function(e){var t,n="number"==typeof v?void 0:v[0];if(Ct(f,(function(e){return 2})),s>=2||1!==i.length)t=Du(i,c,p);else{var r=i[0];t=r.tag?Du(i,c,p):Fr((function(e){return Hr.$$return([e])}),$u(r[0].id,c,p))}return t.then((function(e){if(e.tag)Ct(f,(function(e){return 1}));else{try{_t(u,e[0],n)}catch(e){var t=gn(e);console.error(t)}Ct(f,(function(e){return 0})),setTimeout((function(e){return Ct(f,(function(e){return 4}))}),2e3)}return Qr(0)})),0},kind:-791844958,children:o}))};function Ju(e){var n=e.onRemove,r=e.children;return t("li",{className:"flex flex-1 h-12 border-b last:border-b-0 pl-3 pr-5 py-1 items-center group relative"},t(Ka,{className:"ml-2 mr-5 cursor-pointer",onClick:n,checked:!0}),r)}function Xu(e){var n=e.asset,r=tu(n);return t(Ju,{onRemove:function(e){return Ct(Au,bt(2,[[n]]))},children:null},t("img",{className:"w-10 h-10 mr-3 select-none object-cover bg-ui-500 rounded",draggable:!1,src:eu(n)}),t("span",{className:"w-40 mr-2 truncate",title:n.name},n.name),void 0!==r?t("span",{className:"flex-grow text-body-400 text-sm text-right"},r):null)}function Ku(e){var n=e.collection;return t(Ju,{onRemove:function(e){return Ct(Au,bt(3,[n]))},children:null},t("div",{className:"w-10 h-10 mr-3 bg-ui-500 rounded flex items-center justify-center"},t(Wt,{className:"w-6 h-6 text-body-500 opacity-75"})),t("span",{className:"w-40 mr-2 truncate",title:n.name},n.name),t("span",{className:"flex-grow text-body-400 text-sm text-right"},hr(n.assetCount,vn("{} assets"),vn("{} asset"))))}function Zu(e){var n=Rn(e.selection,(function(e){if(e.tag){var n=e[0];return t(Ku,{collection:n,key:n.id})}var r=e[0];return t(Xu,{asset:r,key:r.id})}));return t("ul",{className:"flex flex-col py-2 overflow-y-auto max-h-400"},n)}var ec=function(e){var n=Ct(Tu,0),r=n.length;return r>0?t("div",{className:"flex flex-shrink-0 h-16 z-10 px-6 items-center shadow-footer fade-in-down"},t("span",{className:"flex-grow flex items-center"},t(na,{buttonKind:67972948,direction:19067,title:vn("View {} selected").replace("{}",String(r)),children:function(e){return t(Zu,{selection:n})}}),t(ti,{className:"ml-1",onClick:function(e){return Ct(Au,0)},children:vn("Clear selection")})),t(Yu,{selection:n})):null};function tc(e){var n=ai(0),r=Vo(0),o=Ko();if(n||ur(r)||cr(o)){var i;if(void 0!==r){var a=r.onClose;i=t(ti,{title:vn("Close"),onClick:function(e){return Ct(a,0)},children:t(tn,{className:"w-6 h-6 -mx-1"})})}else i=null;return t("nav",{className:"flex justify-between bg-ui-0 px-4 py-3 z-30"},cr(o)?t(d,void 0,t(zu,{}),t(qu,{})):null,t("div",{className:"inline-flex ml-auto"},n?t(ti,{onClick:function(e){return lo()},children:null},t("span",{className:"mr-1"},vn("Log out")),t(Pt,{className:"w-6 h-6 -mr-1"})):null,i))}return null}var nc=function(e){var n=e.assetFieldSelection,r=e.assetFilter,o=e.assetTypes,a=e.defaultSearchTerm,s=e.language,u=e.mode,c=e.onSuccess,l=e.theme,d=e.hideExternalAccess,f=e.selectedAssets,v=void 0!==o?o:[995579707,628011190,887770203,-191332581],p=void 0!==a?a:"",h=void 0!==s?s:"en_US",m=void 0!==u?u:2,g=void 0!==c?c:function(e,t){return console.log(e,t),0};i((function(){Ct(Au,0)}),[]),i((function(){var e;if(void 0!==f){var t=f;e=0!==t.length?t:[]}else e=[];Ct(ps,bt(4,[e]))}),[f]),i((function(){Ct(ps,bt(0,[p]))}),[p]);var b=Ct(Li,0);Lo(h);var x={assetFieldSelection:n,assetFilter:r,assetTypes:v,language:h,onSuccess:g,selectionMode:m,theme:l,hideExternalAccess:d},y=t("div",{className:"cv-root cv-container"},t(tc,{}),t(Mi,"number"==typeof b?0!==b?{children:t(Ru,{})}:{children:t(ju,{})}:{children:t(Pu,{collection:b[0]})}),t(ec,{}));return t(Yo,function(e,t,n){return{value:e,children:t}}(x,t(Ro,{topLevel:!1,children:y})))},rc={AUDIO:628011190,DOCUMENT:-191332581,IMAGE:995579707,VIDEO:887770203},oc={SingleSelect:0,SingleSelectFile:1,MultiSelect:2},ic=function(e){var n={assetFieldSelection:e.assetFieldSelection,assetFilter:null==e.assetFilter?void 0:{assetType_in:null==e.assetFilter.assetType_in?void 0:e.assetFilter.assetType_in.map((function(e){return rc[e]})),collectionId:e.assetFilter.collectionId,metapropertyOptionId_in:e.assetFilter.metapropertyOptionId_in,searchTerm:e.assetFilter.searchTerm,tagNames_in:e.assetFilter.tagNames_in,isLimitedUse:e.assetFilter.isLimitedUse},assetTypes:null==e.assetTypes?void 0:e.assetTypes.map((function(e){return rc[e]})),defaultSearchTerm:e.defaultSearchTerm,hideExternalAccess:e.hideExternalAccess,language:e.language,mode:null==e.mode?void 0:oc[e.mode],onSuccess:null==e.onSuccess?void 0:function(t,n){return e.onSuccess(t,{selectedFile:n})},selectedAssets:e.selectedAssets,theme:e.theme};return t(nc,n)},ac=function(e){var n=e.portal,r=e.language,o=e.children,i=void 0!==r?r:"en_US",a=so();return Lo(i),void 0!==a.accessToken?t(ii,oi(!0,o)):void 0!==a.refreshToken?t("div",{className:"bg-ui-0 w-full h-full"},t(ni,{})):t(Ro,{topLevel:!1,children:t(ui,{portal:n})})},sc=function(e){var n=e.children,r=e.isOpen,o=e.style,i=e.onClose;if(void 0===r||r){var a={onClose:void 0!==i?i:function(e){return 0}},s={className:"shadow-modal h-full w-full overflow-hidden rounded"};return void 0!==o&&(s.style=sn(o)),t(Ho,Bo(a,t(Ro,{topLevel:!0,children:t("div",{className:"inset-0 flex items-center p-4 z-a-lot fixed bg-ui-600 fade-in-down"},t("div",s,n))})))}return null};export{ic as CompactView,ac as Login,sc as Modal};
7
+ import*as e from"react";import t,{createContext as n,useState as r,useMemo as o,useContext as i,useEffect as a,forwardRef as s,createElement as c,useRef as l,useLayoutEffect as u,useCallback as d,Component as p}from"react";import f,{createPortal as h}from"react-dom";var m="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},g=function(e){return e&&e.Math==Math&&e},v=g("object"==typeof globalThis&&globalThis)||g("object"==typeof window&&window)||g("object"==typeof self&&self)||g("object"==typeof m&&m)||Function("return this")(),y={},b=function(e){try{return!!e()}catch(e){return!0}},x=!b((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),_={},w={}.propertyIsEnumerable,S=Object.getOwnPropertyDescriptor,E=S&&!w.call({1:2},1);_.f=E?function(e){var t=S(this,e);return!!t&&t.enumerable}:w;var k=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},C={}.toString,T=function(e){return C.call(e).slice(8,-1)},N=T,I="".split,O=b((function(){return!Object("z").propertyIsEnumerable(0)}))?function(e){return"String"==N(e)?I.call(e,""):Object(e)}:Object,A=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e},P=O,B=A,R=function(e){return P(B(e))},F=function(e){return"object"==typeof e?null!==e:"function"==typeof e},z=F,L=function(e,t){if(!z(e))return e;var n,r;if(t&&"function"==typeof(n=e.toString)&&!z(r=n.call(e)))return r;if("function"==typeof(n=e.valueOf)&&!z(r=n.call(e)))return r;if(!t&&"function"==typeof(n=e.toString)&&!z(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")},j={}.hasOwnProperty,M=function(e,t){return j.call(e,t)},D=F,H=v.document,U=D(H)&&D(H.createElement),q=function(e){return U?H.createElement(e):{}},V=q,W=!x&&!b((function(){return 7!=Object.defineProperty(V("div"),"a",{get:function(){return 7}}).a})),$=x,Y=_,G=k,X=R,J=L,K=M,Z=W,Q=Object.getOwnPropertyDescriptor;y.f=$?Q:function(e,t){if(e=X(e),t=J(t,!0),Z)try{return Q(e,t)}catch(e){}if(K(e,t))return G(!Y.f.call(e,t),e[t])};var ee={},te=F,ne=function(e){if(!te(e))throw TypeError(String(e)+" is not an object");return e},re=x,oe=W,ie=ne,ae=L,se=Object.defineProperty;ee.f=re?se:function(e,t,n){if(ie(e),t=ae(t,!0),ie(n),oe)try{return se(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(e[t]=n.value),e};var ce=ee,le=k,ue=x?function(e,t,n){return ce.f(e,t,le(1,n))}:function(e,t,n){return e[t]=n,e},de={exports:{}},pe=v,fe=ue,he=function(e,t){try{fe(pe,e,t)}catch(n){pe[e]=t}return t},me=he,ge=v["__core-js_shared__"]||me("__core-js_shared__",{}),ve=ge,ye=Function.toString;"function"!=typeof ve.inspectSource&&(ve.inspectSource=function(e){return ye.call(e)});var be=ve.inspectSource,xe=be,_e=v.WeakMap,we="function"==typeof _e&&/native code/.test(xe(_e)),Se={exports:{}},Ee=ge;(Se.exports=function(e,t){return Ee[e]||(Ee[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.6.5",mode:"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"});var ke,Ce,Te,Ne=0,Ie=Math.random(),Oe=function(e){return"Symbol("+String(void 0===e?"":e)+")_"+(++Ne+Ie).toString(36)},Ae=Se.exports,Pe=Oe,Be=Ae("keys"),Re=function(e){return Be[e]||(Be[e]=Pe(e))},Fe={},ze=we,Le=F,je=ue,Me=M,De=Re,He=Fe,Ue=v.WeakMap;if(ze){var qe=new Ue,Ve=qe.get,We=qe.has,$e=qe.set;ke=function(e,t){return $e.call(qe,e,t),t},Ce=function(e){return Ve.call(qe,e)||{}},Te=function(e){return We.call(qe,e)}}else{var Ye=De("state");He[Ye]=!0,ke=function(e,t){return je(e,Ye,t),t},Ce=function(e){return Me(e,Ye)?e[Ye]:{}},Te=function(e){return Me(e,Ye)}}var Ge={set:ke,get:Ce,has:Te,enforce:function(e){return Te(e)?Ce(e):ke(e,{})},getterFor:function(e){return function(t){var n;if(!Le(t)||(n=Ce(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return n}}},Xe=v,Je=ue,Ke=M,Ze=he,Qe=be,et=Ge.get,tt=Ge.enforce,nt=String(String).split("String");(de.exports=function(e,t,n,r){var o=!!r&&!!r.unsafe,i=!!r&&!!r.enumerable,a=!!r&&!!r.noTargetGet;"function"==typeof n&&("string"!=typeof t||Ke(n,"name")||Je(n,"name",t),tt(n).source=nt.join("string"==typeof t?t:"")),e!==Xe?(o?!a&&e[t]&&(i=!0):delete e[t],i?e[t]=n:Je(e,t,n)):i?e[t]=n:Ze(t,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&et(this).source||Qe(this)}));var rt=v,ot=v,it=function(e){return"function"==typeof e?e:void 0},at=function(e,t){return arguments.length<2?it(rt[e])||it(ot[e]):rt[e]&&rt[e][t]||ot[e]&&ot[e][t]},st={},ct=Math.ceil,lt=Math.floor,ut=function(e){return isNaN(e=+e)?0:(e>0?lt:ct)(e)},dt=ut,pt=Math.min,ft=function(e){return e>0?pt(dt(e),9007199254740991):0},ht=ut,mt=Math.max,gt=Math.min,vt=R,yt=ft,bt=function(e){return function(t,n,r){var o,i=vt(t),a=yt(i.length),s=function(e,t){var n=ht(e);return n<0?mt(n+t,0):gt(n,t)}(r,a);if(e&&n!=n){for(;a>s;)if((o=i[s++])!=o)return!0}else for(;a>s;s++)if((e||s in i)&&i[s]===n)return e||s||0;return!e&&-1}},xt={includes:bt(!0),indexOf:bt(!1)},_t=M,wt=R,St=xt.indexOf,Et=Fe,kt=function(e,t){var n,r=wt(e),o=0,i=[];for(n in r)!_t(Et,n)&&_t(r,n)&&i.push(n);for(;t.length>o;)_t(r,n=t[o++])&&(~St(i,n)||i.push(n));return i},Ct=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],Tt=kt,Nt=Ct.concat("length","prototype");st.f=Object.getOwnPropertyNames||function(e){return Tt(e,Nt)};var It={};It.f=Object.getOwnPropertySymbols;var Ot,At=st,Pt=It,Bt=ne,Rt=at("Reflect","ownKeys")||function(e){var t=At.f(Bt(e)),n=Pt.f;return n?t.concat(n(e)):t},Ft=M,zt=Rt,Lt=y,jt=ee,Mt=b,Dt=/#|\.prototype\./,Ht=function(e,t){var n=qt[Ut(e)];return n==Wt||n!=Vt&&("function"==typeof t?Mt(t):!!t)},Ut=Ht.normalize=function(e){return String(e).replace(Dt,".").toLowerCase()},qt=Ht.data={},Vt=Ht.NATIVE="N",Wt=Ht.POLYFILL="P",$t=Ht,Yt=v,Gt=y.f,Xt=ue,Jt=de.exports,Kt=he,Zt=function(e,t){for(var n=zt(t),r=jt.f,o=Lt.f,i=0;i<n.length;i++){var a=n[i];Ft(e,a)||r(e,a,o(t,a))}},Qt=$t,en=function(e,t,n){if(function(e){if("function"!=typeof e)throw TypeError(String(e)+" is not a function")}(e),void 0===t)return e;switch(n){case 0:return function(){return e.call(t)};case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,o){return e.call(t,n,r,o)}}return function(){return e.apply(t,arguments)}},tn=A,nn=T,rn=Array.isArray||function(e){return"Array"==nn(e)},on=b,an=!!Object.getOwnPropertySymbols&&!on((function(){return!String(Symbol())})),sn=an&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,cn=v,ln=Se.exports,un=M,dn=Oe,pn=an,fn=sn,hn=ln("wks"),mn=cn.Symbol,gn=fn?mn:mn&&mn.withoutSetter||dn,vn=function(e){return un(hn,e)||(pn&&un(mn,e)?hn[e]=mn[e]:hn[e]=gn("Symbol."+e)),hn[e]},yn=F,bn=rn,xn=vn("species"),_n=en,wn=O,Sn=ft,En=function(e,t){var n;return bn(e)&&("function"!=typeof(n=e.constructor)||n!==Array&&!bn(n.prototype)?yn(n)&&null===(n=n[xn])&&(n=void 0):n=void 0),new(void 0===n?Array:n)(0===t?0:t)},kn=[].push,Cn=function(e){var t=1==e,n=2==e,r=3==e,o=4==e,i=6==e,a=5==e||i;return function(s,c,l,u){for(var d,p,f=Object(tn(s)),h=wn(f),m=_n(c,l,3),g=Sn(h.length),v=0,y=u||En,b=t?y(s,g):n?y(s,0):void 0;g>v;v++)if((a||v in h)&&(p=m(d=h[v],v,f),e))if(t)b[v]=p;else if(p)switch(e){case 3:return!0;case 5:return d;case 6:return v;case 2:kn.call(b,d)}else if(o)return!1;return i?-1:r||o?o:b}},Tn={forEach:Cn(0),map:Cn(1),filter:Cn(2),some:Cn(3),every:Cn(4),find:Cn(5),findIndex:Cn(6)},Nn=kt,In=Ct,On=Object.keys||function(e){return Nn(e,In)},An=ee,Pn=ne,Bn=On,Rn=x?Object.defineProperties:function(e,t){Pn(e);for(var n,r=Bn(t),o=r.length,i=0;o>i;)An.f(e,n=r[i++],t[n]);return e},Fn=at("document","documentElement"),zn=ne,Ln=Rn,jn=Ct,Mn=Fe,Dn=Fn,Hn=q,Un=Re("IE_PROTO"),qn=function(){},Vn=function(e){return"<script>"+e+"<\/script>"},Wn=function(){try{Ot=document.domain&&new ActiveXObject("htmlfile")}catch(e){}var e,t;Wn=Ot?function(e){e.write(Vn("")),e.close();var t=e.parentWindow.Object;return e=null,t}(Ot):((t=Hn("iframe")).style.display="none",Dn.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(Vn("document.F=Object")),e.close(),e.F);for(var n=jn.length;n--;)delete Wn.prototype[jn[n]];return Wn()};Mn[Un]=!0;var $n=Object.create||function(e,t){var n;return null!==e?(qn.prototype=zn(e),n=new qn,qn.prototype=null,n[Un]=e):n=Wn(),void 0===t?n:Ln(n,t)},Yn=ee,Gn=vn("unscopables"),Xn=Array.prototype;null==Xn[Gn]&&Yn.f(Xn,Gn,{configurable:!0,value:$n(null)});var Jn,Kn=x,Zn=b,Qn=M,er=Object.defineProperty,tr={},nr=function(e){throw e},rr=Tn.find,or=!0,ir=function(e,t){if(Qn(tr,"find"))return tr.find;t||(t={});var n=[].find,r=!!Qn(t,"ACCESSORS")&&t.ACCESSORS,o=Qn(t,0)?t[0]:nr,i=Qn(t,1)?t[1]:void 0;return tr.find=!!n&&!Zn((function(){if(r&&!Kn)return!0;var e={length:-1};r?er(e,1,{enumerable:!0,get:nr}):e[1]=1,n.call(e,o,i)}))}();"find"in[]&&Array(1).find((function(){or=!1})),function(e,t){var n,r,o,i,a,s=e.target,c=e.global,l=e.stat;if(n=c?Yt:l?Yt[s]||Kt(s,{}):(Yt[s]||{}).prototype)for(r in t){if(i=t[r],o=e.noTargetGet?(a=Gt(n,r))&&a.value:n[r],!Qt(c?r:s+(l?".":"#")+r,e.forced)&&void 0!==o){if(typeof i==typeof o)continue;Zt(i,o)}(e.sham||o&&o.sham)&&Xt(i,"sham",!0),Jt(n,r,i,e)}}({target:"Array",proto:!0,forced:or||!ir},{find:function(e){return rr(this,e,arguments.length>1?arguments[1]:void 0)}}),Jn="find",Xn[Gn][Jn]=!0;var ar=v,sr=en,cr=Function.call;sr(cr,ar.Array.prototype.find,void 0),function(){if("object"==typeof window)if("IntersectionObserver"in window&&"IntersectionObserverEntry"in window&&"intersectionRatio"in window.IntersectionObserverEntry.prototype)"isIntersecting"in window.IntersectionObserverEntry.prototype||Object.defineProperty(window.IntersectionObserverEntry.prototype,"isIntersecting",{get:function(){return this.intersectionRatio>0}});else{var e=window.document;n.prototype.THROTTLE_TIMEOUT=100,n.prototype.POLL_INTERVAL=null,n.prototype.USE_MUTATION_OBSERVER=!0,n.prototype.observe=function(e){if(!this._observationTargets.some((function(t){return t.element==e}))){if(!e||1!=e.nodeType)throw new Error("target must be an Element");this._registerInstance(),this._observationTargets.push({element:e,entry:null}),this._monitorIntersections(),this._checkForIntersections()}},n.prototype.unobserve=function(e){this._observationTargets=this._observationTargets.filter((function(t){return t.element!=e})),this._observationTargets.length||(this._unmonitorIntersections(),this._unregisterInstance())},n.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorIntersections(),this._unregisterInstance()},n.prototype.takeRecords=function(){var e=this._queuedEntries.slice();return this._queuedEntries=[],e},n.prototype._initThresholds=function(e){var t=e||[0];return Array.isArray(t)||(t=[t]),t.sort().filter((function(e,t,n){if("number"!=typeof e||isNaN(e)||e<0||e>1)throw new Error("threshold must be a number between 0 and 1 inclusively");return e!==n[t-1]}))},n.prototype._parseRootMargin=function(e){var t=(e||"0px").split(/\s+/).map((function(e){var t=/^(-?\d*\.?\d+)(px|%)$/.exec(e);if(!t)throw new Error("rootMargin must be specified in pixels or percent");return{value:parseFloat(t[1]),unit:t[2]}}));return t[1]=t[1]||t[0],t[2]=t[2]||t[0],t[3]=t[3]||t[1],t},n.prototype._monitorIntersections=function(){this._monitoringIntersections||(this._monitoringIntersections=!0,this.POLL_INTERVAL?this._monitoringInterval=setInterval(this._checkForIntersections,this.POLL_INTERVAL):(r(window,"resize",this._checkForIntersections,!0),r(e,"scroll",this._checkForIntersections,!0),this.USE_MUTATION_OBSERVER&&"MutationObserver"in window&&(this._domObserver=new MutationObserver(this._checkForIntersections),this._domObserver.observe(e,{attributes:!0,childList:!0,characterData:!0,subtree:!0}))))},n.prototype._unmonitorIntersections=function(){this._monitoringIntersections&&(this._monitoringIntersections=!1,clearInterval(this._monitoringInterval),this._monitoringInterval=null,o(window,"resize",this._checkForIntersections,!0),o(e,"scroll",this._checkForIntersections,!0),this._domObserver&&(this._domObserver.disconnect(),this._domObserver=null))},n.prototype._checkForIntersections=function(){var e=this._rootIsInDom(),n=e?this._getRootRect():{top:0,bottom:0,left:0,right:0,width:0,height:0};this._observationTargets.forEach((function(r){var o=r.element,a=i(o),s=this._rootContainsTarget(o),c=r.entry,l=e&&s&&this._computeTargetAndRootIntersection(o,n),u=r.entry=new t({time:window.performance&&performance.now&&performance.now(),target:o,boundingClientRect:a,rootBounds:n,intersectionRect:l});c?e&&s?this._hasCrossedThreshold(c,u)&&this._queuedEntries.push(u):c&&c.isIntersecting&&this._queuedEntries.push(u):this._queuedEntries.push(u)}),this),this._queuedEntries.length&&this._callback(this.takeRecords(),this)},n.prototype._computeTargetAndRootIntersection=function(t,n){if("none"!=window.getComputedStyle(t).display){for(var r,o,a,c,l,u,d,p,f=i(t),h=s(t),m=!1;!m;){var g=null,v=1==h.nodeType?window.getComputedStyle(h):{};if("none"==v.display)return;if(h==this.root||h==e?(m=!0,g=n):h!=e.body&&h!=e.documentElement&&"visible"!=v.overflow&&(g=i(h)),g&&(r=g,o=f,void 0,void 0,void 0,void 0,void 0,void 0,a=Math.max(r.top,o.top),c=Math.min(r.bottom,o.bottom),l=Math.max(r.left,o.left),p=c-a,!(f=(d=(u=Math.min(r.right,o.right))-l)>=0&&p>=0&&{top:a,bottom:c,left:l,right:u,width:d,height:p})))break;h=s(h)}return f}},n.prototype._getRootRect=function(){var t;if(this.root)t=i(this.root);else{var n=e.documentElement,r=e.body;t={top:0,left:0,right:n.clientWidth||r.clientWidth,width:n.clientWidth||r.clientWidth,bottom:n.clientHeight||r.clientHeight,height:n.clientHeight||r.clientHeight}}return this._expandRectByRootMargin(t)},n.prototype._expandRectByRootMargin=function(e){var t=this._rootMarginValues.map((function(t,n){return"px"==t.unit?t.value:t.value*(n%2?e.width:e.height)/100})),n={top:e.top-t[0],right:e.right+t[1],bottom:e.bottom+t[2],left:e.left-t[3]};return n.width=n.right-n.left,n.height=n.bottom-n.top,n},n.prototype._hasCrossedThreshold=function(e,t){var n=e&&e.isIntersecting?e.intersectionRatio||0:-1,r=t.isIntersecting?t.intersectionRatio||0:-1;if(n!==r)for(var o=0;o<this.thresholds.length;o++){var i=this.thresholds[o];if(i==n||i==r||i<n!=i<r)return!0}},n.prototype._rootIsInDom=function(){return!this.root||a(e,this.root)},n.prototype._rootContainsTarget=function(t){return a(this.root||e,t)},n.prototype._registerInstance=function(){},n.prototype._unregisterInstance=function(){},window.IntersectionObserver=n,window.IntersectionObserverEntry=t}function t(e){this.time=e.time,this.target=e.target,this.rootBounds=e.rootBounds,this.boundingClientRect=e.boundingClientRect,this.intersectionRect=e.intersectionRect||{top:0,bottom:0,left:0,right:0,width:0,height:0},this.isIntersecting=!!e.intersectionRect;var t=this.boundingClientRect,n=t.width*t.height,r=this.intersectionRect,o=r.width*r.height;this.intersectionRatio=n?Number((o/n).toFixed(4)):this.isIntersecting?1:0}function n(e,t){var n,r,o,i=t||{};if("function"!=typeof e)throw new Error("callback must be a function");if(i.root&&1!=i.root.nodeType)throw new Error("root must be an Element");this._checkForIntersections=(n=this._checkForIntersections.bind(this),r=this.THROTTLE_TIMEOUT,o=null,function(){o||(o=setTimeout((function(){n(),o=null}),r))}),this._callback=e,this._observationTargets=[],this._queuedEntries=[],this._rootMarginValues=this._parseRootMargin(i.rootMargin),this.thresholds=this._initThresholds(i.threshold),this.root=i.root||null,this.rootMargin=this._rootMarginValues.map((function(e){return e.value+e.unit})).join(" ")}function r(e,t,n,r){"function"==typeof e.addEventListener?e.addEventListener(t,n,r||!1):"function"==typeof e.attachEvent&&e.attachEvent("on"+t,n)}function o(e,t,n,r){"function"==typeof e.removeEventListener?e.removeEventListener(t,n,r||!1):"function"==typeof e.detatchEvent&&e.detatchEvent("on"+t,n)}function i(e){var t;try{t=e.getBoundingClientRect()}catch(e){}return t?(t.width&&t.height||(t={top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:t.right-t.left,height:t.bottom-t.top}),t):{top:0,bottom:0,left:0,right:0,width:0,height:0}}function a(e,t){for(var n=t;n;){if(n==e)return!0;n=s(n)}return!1}function s(e){var t=e.parentNode;return t&&11==t.nodeType&&t.host?t.host:t&&t.assignedSlot?t.assignedSlot.parentNode:t}}();var lr=n(null),ur={field:"CREATED_AT",direction:"DESC"};function dr(e){var n=r(ur),i=n[0],a=n[1],s=r(ur),c=s[0],l=s[1],u=r(ur),d=u[0],p=u[1];function f(e,t){"assets"===e?a(t):"collections"===e?l(t):p(t)}function h(){a(ur),l(ur),p(ur)}var m=o((function(){return{assets:i,collections:c,collection:d,setOrdering:f,reset:h}}),[i,d,c]);return t.createElement(lr.Provider,{value:m},e.children)}function pr(e){var t=function(){var e=i(lr);if(null===e)throw new Error("useOrdering must be used with a OrderingProvider");return e}();return[t[e],function(n){return t.setOrdering(e,n)}]}
8
+ /*! *****************************************************************************
9
+ Copyright (c) Microsoft Corporation.
10
+
11
+ Permission to use, copy, modify, and/or distribute this software for any
12
+ purpose with or without fee is hereby granted.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
15
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
16
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
17
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
18
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
19
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
20
+ PERFORMANCE OF THIS SOFTWARE.
21
+ ***************************************************************************** */var fr=function(e,t){return(fr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)};function hr(e,t){function n(){this.constructor=e}fr(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var mr=function(){return(mr=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function gr(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}function vr(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}c((r=r.apply(e,t||[])).next())}))}function yr(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!((o=(o=a.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}}function br(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function xr(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function _r(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(xr(arguments[t]));return e}function wr(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),o=0;for(t=0;t<n;t++)for(var i=arguments[t],a=0,s=i.length;a<s;a++,o++)r[o]=i[a];return r}var Sr=n(null);function Er(e){var n=r({page:"assets"});return t.createElement(Sr.Provider,{value:n},e.children)}function kr(){var e=i(Sr);if(null===e)throw new Error("useRouter must be used with a RouterProvider");return e}var Cr,Tr,Nr=n(null),Ir={assets:"",collection:"",collections:"",isLoading:!1};function Or(e){var n=r(Ir),i=n[0],s=n[1],c=kr()[0];function l(e,t){var n=""!==t;s((function(r){var o;return mr(mr({},r),((o={})[e]=t,o.isLoading=n,o))}))}function u(e){s((function(t){return mr(mr({},t),{isLoading:e})}))}function d(){s(Ir)}a((function(){var t;l("assets",null!==(t=e.defaultValue)&&void 0!==t?t:"")}),[e.defaultValue]),a((function(){s((function(e){return mr(mr({},e),{collection:""})}))}),[c]);var p=o((function(){return mr(mr({},i),{setSearch:l,setIsLoading:u,clear:d})}),[i]);return t.createElement(Nr.Provider,{value:p},e.children)}function Ar(){var e=i(Nr);if(null===e)throw new Error("useSearchState must be used within a SearchStateContext");return e}function Pr(e){var t=Ar();return{value:t[e],isLoading:t.isLoading,setSearch:function(n){return t.setSearch(e,n)},setIsLoading:t.setIsLoading}}function Br(e){switch(Object.prototype.toString.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return Ur(e,Error)}}function Rr(e){return"[object ErrorEvent]"===Object.prototype.toString.call(e)}function Fr(e){return"[object DOMError]"===Object.prototype.toString.call(e)}function zr(e){return"[object String]"===Object.prototype.toString.call(e)}function Lr(e){return null===e||"object"!=typeof e&&"function"!=typeof e}function jr(e){return"[object Object]"===Object.prototype.toString.call(e)}function Mr(e){return"undefined"!=typeof Event&&Ur(e,Event)}function Dr(e){return"undefined"!=typeof Element&&Ur(e,Element)}function Hr(e){return Boolean(e&&e.then&&"function"==typeof e.then)}function Ur(e,t){try{return e instanceof t}catch(e){return!1}}function qr(e){try{for(var t=e,n=[],r=0,o=0,i=" > ".length,a=void 0;t&&r++<5&&!("html"===(a=Vr(t))||r>1&&o+n.length*i+a.length>=80);)n.push(a),o+=a.length,t=t.parentNode;return n.reverse().join(" > ")}catch(e){return"<unknown>"}}function Vr(e){var t,n,r,o,i,a=e,s=[];if(!a||!a.tagName)return"";if(s.push(a.tagName.toLowerCase()),a.id&&s.push("#"+a.id),(t=a.className)&&zr(t))for(n=t.split(/\s+/),i=0;i<n.length;i++)s.push("."+n[i]);var c=["type","name","title","alt"];for(i=0;i<c.length;i++)r=c[i],(o=a.getAttribute(r))&&s.push("["+r+'="'+o+'"]');return s.join("")}!function(e){e.Fatal="fatal",e.Error="error",e.Warning="warning",e.Log="log",e.Info="info",e.Debug="debug",e.Critical="critical"}(Cr||(Cr={})),function(e){e.fromString=function(t){switch(t){case"debug":return e.Debug;case"info":return e.Info;case"warn":case"warning":return e.Warning;case"error":return e.Error;case"fatal":return e.Fatal;case"critical":return e.Critical;case"log":default:return e.Log}}}(Cr||(Cr={})),function(e){e.Unknown="unknown",e.Skipped="skipped",e.Success="success",e.RateLimit="rate_limit",e.Invalid="invalid",e.Failed="failed"}(Tr||(Tr={})),function(e){e.fromHttpCode=function(t){return t>=200&&t<300?e.Success:429===t?e.RateLimit:t>=400&&t<500?e.Invalid:t>=500?e.Failed:e.Unknown}}(Tr||(Tr={}));var Wr=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(e,t){return e.__proto__=t,e}:function(e,t){for(var n in t)e.hasOwnProperty(n)||(e[n]=t[n]);return e}),$r=function(e){function t(t){var n=this.constructor,r=e.call(this,t)||this;return r.message=t,r.name=n.prototype.constructor.name,Wr(r,n.prototype),r}return hr(t,e),t}(Error),Yr=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/,Gr=function(){function e(e){"string"==typeof e?this._fromString(e):this._fromComponents(e),this._validate()}return e.prototype.toString=function(e){void 0===e&&(e=!1);var t=this,n=t.host,r=t.path,o=t.pass,i=t.port,a=t.projectId;return t.protocol+"://"+t.publicKey+(e&&o?":"+o:"")+"@"+n+(i?":"+i:"")+"/"+(r?r+"/":r)+a},e.prototype._fromString=function(e){var t=Yr.exec(e);if(!t)throw new $r("Invalid Dsn");var n=xr(t.slice(1),6),r=n[0],o=n[1],i=n[2],a=void 0===i?"":i,s=n[3],c=n[4],l=void 0===c?"":c,u="",d=n[5],p=d.split("/");if(p.length>1&&(u=p.slice(0,-1).join("/"),d=p.pop()),d){var f=d.match(/^\d+/);f&&(d=f[0])}this._fromComponents({host:s,pass:a,path:u,projectId:d,port:l,protocol:r,publicKey:o})},e.prototype._fromComponents=function(e){"user"in e&&!("publicKey"in e)&&(e.publicKey=e.user),this.user=e.publicKey||"",this.protocol=e.protocol,this.publicKey=e.publicKey||"",this.pass=e.pass||"",this.host=e.host,this.port=e.port||"",this.path=e.path||"",this.projectId=e.projectId},e.prototype._validate=function(){var e=this;if(["protocol","publicKey","host","projectId"].forEach((function(t){if(!e[t])throw new $r("Invalid Dsn: "+t+" missing")})),!this.projectId.match(/^\d+$/))throw new $r("Invalid Dsn: Invalid projectId "+this.projectId);if("http"!==this.protocol&&"https"!==this.protocol)throw new $r("Invalid Dsn: Invalid protocol "+this.protocol);if(this.port&&isNaN(parseInt(this.port,10)))throw new $r("Invalid Dsn: Invalid port "+this.port)},e}();function Xr(){return"[object process]"===Object.prototype.toString.call("undefined"!=typeof process?process:0)}function Jr(e,t){return void 0===t&&(t=0),"string"!=typeof e||0===t||e.length<=t?e:e.substr(0,t)+"..."}function Kr(e,t){if(!Array.isArray(e))return"";for(var n=[],r=0;r<e.length;r++){var o=e[r];try{n.push(String(o))}catch(e){n.push("[value cannot be serialized]")}}return n.join(t)}function Zr(e,t){return!!zr(e)&&(n=t,"[object RegExp]"===Object.prototype.toString.call(n)?t.test(e):"string"==typeof t&&-1!==e.indexOf(t));var n}var Qr={};function eo(){return Xr()?global:"undefined"!=typeof window?window:"undefined"!=typeof self?self:Qr}function to(){var e=eo(),t=e.crypto||e.msCrypto;if(void 0!==t&&t.getRandomValues){var n=new Uint16Array(8);t.getRandomValues(n),n[3]=4095&n[3]|16384,n[4]=16383&n[4]|32768;var r=function(e){for(var t=e.toString(16);t.length<4;)t="0"+t;return t};return r(n[0])+r(n[1])+r(n[2])+r(n[3])+r(n[4])+r(n[5])+r(n[6])+r(n[7])}return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}function no(e){if(!e)return{};var t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};var n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],relative:t[5]+n+r}}function ro(e){if(e.message)return e.message;if(e.exception&&e.exception.values&&e.exception.values[0]){var t=e.exception.values[0];return t.type&&t.value?t.type+": "+t.value:t.type||t.value||e.event_id||"<unknown>"}return e.event_id||"<unknown>"}function oo(e){var t=eo();if(!("console"in t))return e();var n=t.console,r={};["debug","info","warn","error","log","assert"].forEach((function(e){e in t.console&&n[e].__sentry_original__&&(r[e]=n[e],n[e]=n[e].__sentry_original__)}));var o=e();return Object.keys(r).forEach((function(e){n[e]=r[e]})),o}function io(e,t,n){e.exception=e.exception||{},e.exception.values=e.exception.values||[],e.exception.values[0]=e.exception.values[0]||{},e.exception.values[0].value=e.exception.values[0].value||t||"",e.exception.values[0].type=e.exception.values[0].type||n||"Error"}function ao(e,t){void 0===t&&(t={});try{e.exception.values[0].mechanism=e.exception.values[0].mechanism||{},Object.keys(t).forEach((function(n){e.exception.values[0].mechanism[n]=t[n]}))}catch(e){}}var so=eo(),co="Sentry Logger ",lo=function(){function e(){this._enabled=!1}return e.prototype.disable=function(){this._enabled=!1},e.prototype.enable=function(){this._enabled=!0},e.prototype.log=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._enabled&&oo((function(){so.console.log(co+"[Log]: "+e.join(" "))}))},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._enabled&&oo((function(){so.console.warn(co+"[Warn]: "+e.join(" "))}))},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._enabled&&oo((function(){so.console.error(co+"[Error]: "+e.join(" "))}))},e}();so.__SENTRY__=so.__SENTRY__||{};var uo=so.__SENTRY__.logger||(so.__SENTRY__.logger=new lo),po=function(){function e(){this._hasWeakSet="function"==typeof WeakSet,this._inner=this._hasWeakSet?new WeakSet:[]}return e.prototype.memoize=function(e){if(this._hasWeakSet)return!!this._inner.has(e)||(this._inner.add(e),!1);for(var t=0;t<this._inner.length;t++)if(this._inner[t]===e)return!0;return this._inner.push(e),!1},e.prototype.unmemoize=function(e){if(this._hasWeakSet)this._inner.delete(e);else for(var t=0;t<this._inner.length;t++)if(this._inner[t]===e){this._inner.splice(t,1);break}},e}();function fo(e){try{return e&&"function"==typeof e&&e.name||"<anonymous>"}catch(e){return"<anonymous>"}}function ho(e,t,n){if(t in e){var r=e[t],o=n(r);if("function"==typeof o)try{o.prototype=o.prototype||{},Object.defineProperties(o,{__sentry_original__:{enumerable:!1,value:r}})}catch(e){}e[t]=o}}function mo(e){if(Br(e)){var t=e,n={message:t.message,name:t.name,stack:t.stack};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n}if(Mr(e)){var o=e,i={};i.type=o.type;try{i.target=Dr(o.target)?qr(o.target):Object.prototype.toString.call(o.target)}catch(e){i.target="<unknown>"}try{i.currentTarget=Dr(o.currentTarget)?qr(o.currentTarget):Object.prototype.toString.call(o.currentTarget)}catch(e){i.currentTarget="<unknown>"}for(var r in"undefined"!=typeof CustomEvent&&Ur(e,CustomEvent)&&(i.detail=o.detail),o)Object.prototype.hasOwnProperty.call(o,r)&&(i[r]=o);return i}return e}function go(e,t,n){void 0===t&&(t=3),void 0===n&&(n=102400);var r,o=yo(e,t);return r=o,function(e){return~-encodeURI(e).split(/%..|./).length}(JSON.stringify(r))>n?go(e,t-1,n):o}function vo(e,t){return"domain"===t&&e&&"object"==typeof e&&e._events?"[Domain]":"domainEmitter"===t?"[DomainEmitter]":"undefined"!=typeof global&&e===global?"[Global]":"undefined"!=typeof window&&e===window?"[Window]":"undefined"!=typeof document&&e===document?"[Document]":jr(n=e)&&"nativeEvent"in n&&"preventDefault"in n&&"stopPropagation"in n?"[SyntheticEvent]":"number"==typeof e&&e!=e?"[NaN]":void 0===e?"[undefined]":"function"==typeof e?"[Function: "+fo(e)+"]":"symbol"==typeof e?"["+String(e)+"]":"bigint"==typeof e?"[BigInt: "+String(e)+"]":e;var n}function yo(e,t){try{return JSON.parse(JSON.stringify(e,(function(e,n){return function e(t,n,r,o){if(void 0===r&&(r=1/0),void 0===o&&(o=new po),0===r)return function(e){var t=Object.prototype.toString.call(e);if("string"==typeof e)return e;if("[object Object]"===t)return"[Object]";if("[object Array]"===t)return"[Array]";var n=vo(e);return Lr(n)?n:t}(n);if(null!=n&&"function"==typeof n.toJSON)return n.toJSON();var i=vo(n,t);if(Lr(i))return i;var a=mo(n),s=Array.isArray(n)?[]:{};if(o.memoize(n))return"[Circular ~]";for(var c in a)Object.prototype.hasOwnProperty.call(a,c)&&(s[c]=e(c,a[c],r-1,o));return o.unmemoize(n),s}(e,n,t)})))}catch(e){return"**non-serializable**"}}function bo(e,t){void 0===t&&(t=40);var n=Object.keys(mo(e));if(n.sort(),!n.length)return"[object has no keys]";if(n[0].length>=t)return Jr(n[0],t);for(var r=n.length;r>0;r--){var o=n.slice(0,r).join(", ");if(!(o.length>t))return r===n.length?o:Jr(o,t)}return""}function xo(e){var t,n;if(jr(e)){var r=e,o={};try{for(var i=br(Object.keys(r)),a=i.next();!a.done;a=i.next()){var s=a.value;void 0!==r[s]&&(o[s]=xo(r[s]))}}catch(e){t={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return o}return Array.isArray(e)?e.map(xo):e}function _o(){if(!("fetch"in eo()))return!1;try{return new Headers,new Request(""),new Response,!0}catch(e){return!1}}function wo(e){return e&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function So(){if(!_o())return!1;try{return new Request("_",{referrerPolicy:"origin"}),!0}catch(e){return!1}}var Eo,ko,Co,To=eo(),No={},Io={};function Oo(e){e&&"string"==typeof e.type&&"function"==typeof e.callback&&(No[e.type]=No[e.type]||[],No[e.type].push(e.callback),function(e){if(!Io[e])switch(Io[e]=!0,e){case"console":"console"in To&&["debug","info","warn","error","log","assert"].forEach((function(e){e in To.console&&ho(To.console,e,(function(t){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];Ao("console",{args:n,level:e}),t&&Function.prototype.apply.call(t,To.console,n)}}))}));break;case"dom":!function(){if("document"in To){var e=Ao.bind(null,"dom"),t=Ro(e,!0);To.document.addEventListener("click",t,!1),To.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach((function(t){var n=To[t]&&To[t].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(ho(n,"addEventListener",(function(t){return function(n,r,o){if("click"===n||"keypress"==n)try{var i=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},a=i[n]=i[n]||{refCount:0};if(!a.handler){var s=Ro(e);a.handler=s,t.call(this,n,s,o)}a.refCount+=1}catch(e){}return t.call(this,n,r,o)}})),ho(n,"removeEventListener",(function(e){return function(t,n,r){if("click"===t||"keypress"==t)try{var o=this.__sentry_instrumentation_handlers__||{},i=o[t];i&&(i.refCount-=1,i.refCount<=0&&(e.call(this,t,i.handler,r),i.handler=void 0,delete o[t]),0===Object.keys(o).length&&delete this.__sentry_instrumentation_handlers__)}catch(e){}return e.call(this,t,n,r)}})))}))}}();break;case"xhr":!function(){if("XMLHttpRequest"in To){var e=[],t=[],n=XMLHttpRequest.prototype;ho(n,"open",(function(n){return function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var i=this,a=r[1];i.__sentry_xhr__={method:zr(r[0])?r[0].toUpperCase():r[0],url:r[1]},zr(a)&&"POST"===i.__sentry_xhr__.method&&a.match(/sentry_key/)&&(i.__sentry_own_request__=!0);var s=function(){if(4===i.readyState){try{i.__sentry_xhr__&&(i.__sentry_xhr__.status_code=i.status)}catch(e){}try{var n=e.indexOf(i);if(-1!==n){e.splice(n);var o=t.splice(n)[0];i.__sentry_xhr__&&void 0!==o[0]&&(i.__sentry_xhr__.body=o[0])}}catch(e){}Ao("xhr",{args:r,endTimestamp:Date.now(),startTimestamp:Date.now(),xhr:i})}};return"onreadystatechange"in i&&"function"==typeof i.onreadystatechange?ho(i,"onreadystatechange",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return s(),e.apply(i,t)}})):i.addEventListener("readystatechange",s),n.apply(i,r)}})),ho(n,"send",(function(n){return function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return e.push(this),t.push(r),Ao("xhr",{args:r,startTimestamp:Date.now(),xhr:this}),n.apply(this,r)}}))}}();break;case"fetch":(function(){if(!_o())return!1;var e=eo();if(wo(e.fetch))return!0;var t=!1,n=e.document;if(n&&"function"==typeof n.createElement)try{var r=n.createElement("iframe");r.hidden=!0,n.head.appendChild(r),r.contentWindow&&r.contentWindow.fetch&&(t=wo(r.contentWindow.fetch)),n.head.removeChild(r)}catch(e){uo.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",e)}return t})()&&ho(To,"fetch",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r={args:t,fetchData:{method:Po(t),url:Bo(t)},startTimestamp:Date.now()};return Ao("fetch",mr({},r)),e.apply(To,t).then((function(e){return Ao("fetch",mr(mr({},r),{endTimestamp:Date.now(),response:e})),e}),(function(e){throw Ao("fetch",mr(mr({},r),{endTimestamp:Date.now(),error:e})),e}))}}));break;case"history":!function(){if(function(){var e=eo(),t=e.chrome,n=t&&t.app&&t.app.runtime,r="history"in e&&!!e.history.pushState&&!!e.history.replaceState;return!n&&r}()){var e=To.onpopstate;To.onpopstate=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=To.location.href,o=Eo;if(Eo=r,Ao("history",{from:o,to:r}),e)try{return e.apply(this,t)}catch(e){}},ho(To.history,"pushState",t),ho(To.history,"replaceState",t)}function t(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=t.length>2?t[2]:void 0;if(r){var o=Eo,i=String(r);Eo=i,Ao("history",{from:o,to:i})}return e.apply(this,t)}}}();break;case"error":zo=To.onerror,To.onerror=function(e,t,n,r,o){return Ao("error",{column:r,error:o,line:n,msg:e,url:t}),!!zo&&zo.apply(this,arguments)};break;case"unhandledrejection":Lo=To.onunhandledrejection,To.onunhandledrejection=function(e){return Ao("unhandledrejection",e),!Lo||Lo.apply(this,arguments)};break;default:uo.warn("unknown instrumentation type:",e)}}(e.type))}function Ao(e,t){var n,r;if(e&&No[e])try{for(var o=br(No[e]||[]),i=o.next();!i.done;i=o.next()){var a=i.value;try{a(t)}catch(t){uo.error("Error while triggering instrumentation handler.\nType: "+e+"\nName: "+fo(a)+"\nError: "+t)}}}catch(e){n={error:e}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}}function Po(e){return void 0===e&&(e=[]),"Request"in To&&Ur(e[0],Request)&&e[0].method?String(e[0].method).toUpperCase():e[1]&&e[1].method?String(e[1].method).toUpperCase():"GET"}function Bo(e){return void 0===e&&(e=[]),"string"==typeof e[0]?e[0]:"Request"in To&&Ur(e[0],Request)?e[0].url:String(e[0])}function Ro(e,t){return void 0===t&&(t=!1),function(n){if(n&&Co!==n&&!function(e){if("keypress"!==e.type)return!1;try{var t=e.target;if(!t||!t.tagName)return!0;if("INPUT"===t.tagName||"TEXTAREA"===t.tagName||t.isContentEditable)return!1}catch(e){}return!0}(n)){var r="keypress"===n.type?"input":n.type;(void 0===ko||function(e,t){if(!e)return!0;if(e.type!==t.type)return!0;try{if(e.target!==t.target)return!0}catch(e){}return!1}(Co,n))&&(e({event:n,name:r,global:t}),Co=n),clearTimeout(ko),ko=To.setTimeout((function(){ko=void 0}),1e3)}}}var Fo,zo=null,Lo=null;!function(e){e.PENDING="PENDING",e.RESOLVED="RESOLVED",e.REJECTED="REJECTED"}(Fo||(Fo={}));var jo=function(){function e(e){var t=this;this._state=Fo.PENDING,this._handlers=[],this._resolve=function(e){t._setResult(Fo.RESOLVED,e)},this._reject=function(e){t._setResult(Fo.REJECTED,e)},this._setResult=function(e,n){t._state===Fo.PENDING&&(Hr(n)?n.then(t._resolve,t._reject):(t._state=e,t._value=n,t._executeHandlers()))},this._attachHandler=function(e){t._handlers=t._handlers.concat(e),t._executeHandlers()},this._executeHandlers=function(){if(t._state!==Fo.PENDING){var e=t._handlers.slice();t._handlers=[],e.forEach((function(e){e.done||(t._state===Fo.RESOLVED&&e.onfulfilled&&e.onfulfilled(t._value),t._state===Fo.REJECTED&&e.onrejected&&e.onrejected(t._value),e.done=!0)}))}};try{e(this._resolve,this._reject)}catch(e){this._reject(e)}}return e.resolve=function(t){return new e((function(e){e(t)}))},e.reject=function(t){return new e((function(e,n){n(t)}))},e.all=function(t){return new e((function(n,r){if(Array.isArray(t))if(0!==t.length){var o=t.length,i=[];t.forEach((function(t,a){e.resolve(t).then((function(e){i[a]=e,0==(o-=1)&&n(i)})).then(null,r)}))}else n([]);else r(new TypeError("Promise.all requires an array as input."))}))},e.prototype.then=function(t,n){var r=this;return new e((function(e,o){r._attachHandler({done:!1,onfulfilled:function(n){if(t)try{return void e(t(n))}catch(e){return void o(e)}else e(n)},onrejected:function(t){if(n)try{return void e(n(t))}catch(e){return void o(e)}else o(t)}})}))},e.prototype.catch=function(e){return this.then((function(e){return e}),e)},e.prototype.finally=function(t){var n=this;return new e((function(e,r){var o,i;return n.then((function(e){i=!1,o=e,t&&t()}),(function(e){i=!0,o=e,t&&t()})).then((function(){i?r(o):e(o)}))}))},e.prototype.toString=function(){return"[object SyncPromise]"},e}(),Mo=function(){function e(e){this._limit=e,this._buffer=[]}return e.prototype.isReady=function(){return void 0===this._limit||this.length()<this._limit},e.prototype.add=function(e){var t=this;return this.isReady()?(-1===this._buffer.indexOf(e)&&this._buffer.push(e),e.then((function(){return t.remove(e)})).then(null,(function(){return t.remove(e).then(null,(function(){}))})),e):jo.reject(new $r("Not adding Promise due to buffer limit reached."))},e.prototype.remove=function(e){return this._buffer.splice(this._buffer.indexOf(e),1)[0]},e.prototype.length=function(){return this._buffer.length},e.prototype.drain=function(e){var t=this;return new jo((function(n){var r=setTimeout((function(){e&&e>0&&n(!1)}),e);jo.all(t._buffer).then((function(){clearTimeout(r),n(!0)})).then(null,(function(){n(!0)}))}))},e}(),Do={nowSeconds:function(){return Date.now()/1e3}},Ho=Xr()?function(){try{return(e=module,"perf_hooks",e.require("perf_hooks")).performance}catch(e){return}var e}():function(){var e=eo().performance;if(e&&e.now)return{now:function(){return e.now()},timeOrigin:Date.now()-e.now()}}(),Uo=void 0===Ho?Do:{nowSeconds:function(){return(Ho.timeOrigin+Ho.now())/1e3}},qo=Do.nowSeconds.bind(Do);Uo.nowSeconds.bind(Uo),function(){var e=eo().performance;if(e){var t=e.now(),n=Date.now(),r=e.timeOrigin?Math.abs(e.timeOrigin+t-n):36e5,o=r<36e5,i=e.timing&&e.timing.navigationStart,a="number"==typeof i?Math.abs(i+t-n):36e5;(o||a<36e5)&&r<=a&&e.timeOrigin}}();var Vo,Wo,$o=function(){function e(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._user={},this._tags={},this._extra={},this._contexts={}}return e.clone=function(t){var n=new e;return t&&(n._breadcrumbs=_r(t._breadcrumbs),n._tags=mr({},t._tags),n._extra=mr({},t._extra),n._contexts=mr({},t._contexts),n._user=t._user,n._level=t._level,n._span=t._span,n._session=t._session,n._transactionName=t._transactionName,n._fingerprint=t._fingerprint,n._eventProcessors=_r(t._eventProcessors),n._requestSession=t._requestSession),n},e.prototype.addScopeListener=function(e){this._scopeListeners.push(e)},e.prototype.addEventProcessor=function(e){return this._eventProcessors.push(e),this},e.prototype.setUser=function(e){return this._user=e||{},this._session&&this._session.update({user:e}),this._notifyScopeListeners(),this},e.prototype.getUser=function(){return this._user},e.prototype.getRequestSession=function(){return this._requestSession},e.prototype.setRequestSession=function(e){return this._requestSession=e,this},e.prototype.setTags=function(e){return this._tags=mr(mr({},this._tags),e),this._notifyScopeListeners(),this},e.prototype.setTag=function(e,t){var n;return this._tags=mr(mr({},this._tags),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setExtras=function(e){return this._extra=mr(mr({},this._extra),e),this._notifyScopeListeners(),this},e.prototype.setExtra=function(e,t){var n;return this._extra=mr(mr({},this._extra),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setFingerprint=function(e){return this._fingerprint=e,this._notifyScopeListeners(),this},e.prototype.setLevel=function(e){return this._level=e,this._notifyScopeListeners(),this},e.prototype.setTransactionName=function(e){return this._transactionName=e,this._notifyScopeListeners(),this},e.prototype.setTransaction=function(e){return this.setTransactionName(e)},e.prototype.setContext=function(e,t){var n;return null===t?delete this._contexts[e]:this._contexts=mr(mr({},this._contexts),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setSpan=function(e){return this._span=e,this._notifyScopeListeners(),this},e.prototype.getSpan=function(){return this._span},e.prototype.getTransaction=function(){var e,t,n,r,o=this.getSpan();return(null===(e=o)||void 0===e?void 0:e.transaction)?null===(t=o)||void 0===t?void 0:t.transaction:(null===(r=null===(n=o)||void 0===n?void 0:n.spanRecorder)||void 0===r?void 0:r.spans[0])?o.spanRecorder.spans[0]:void 0},e.prototype.setSession=function(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this},e.prototype.getSession=function(){return this._session},e.prototype.update=function(t){if(!t)return this;if("function"==typeof t){var n=t(this);return n instanceof e?n:this}return t instanceof e?(this._tags=mr(mr({},this._tags),t._tags),this._extra=mr(mr({},this._extra),t._extra),this._contexts=mr(mr({},this._contexts),t._contexts),t._user&&Object.keys(t._user).length&&(this._user=t._user),t._level&&(this._level=t._level),t._fingerprint&&(this._fingerprint=t._fingerprint),t._requestSession&&(this._requestSession=t._requestSession)):jr(t)&&(t=t,this._tags=mr(mr({},this._tags),t.tags),this._extra=mr(mr({},this._extra),t.extra),this._contexts=mr(mr({},this._contexts),t.contexts),t.user&&(this._user=t.user),t.level&&(this._level=t.level),t.fingerprint&&(this._fingerprint=t.fingerprint),t.requestSession&&(this._requestSession=t.requestSession)),this},e.prototype.clear=function(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this},e.prototype.addBreadcrumb=function(e,t){var n=mr({timestamp:qo()},e);return this._breadcrumbs=void 0!==t&&t>=0?_r(this._breadcrumbs,[n]).slice(-t):_r(this._breadcrumbs,[n]),this._notifyScopeListeners(),this},e.prototype.clearBreadcrumbs=function(){return this._breadcrumbs=[],this._notifyScopeListeners(),this},e.prototype.applyToEvent=function(e,t){var n;if(this._extra&&Object.keys(this._extra).length&&(e.extra=mr(mr({},this._extra),e.extra)),this._tags&&Object.keys(this._tags).length&&(e.tags=mr(mr({},this._tags),e.tags)),this._user&&Object.keys(this._user).length&&(e.user=mr(mr({},this._user),e.user)),this._contexts&&Object.keys(this._contexts).length&&(e.contexts=mr(mr({},this._contexts),e.contexts)),this._level&&(e.level=this._level),this._transactionName&&(e.transaction=this._transactionName),this._span){e.contexts=mr({trace:this._span.getTraceContext()},e.contexts);var r=null===(n=this._span.transaction)||void 0===n?void 0:n.name;r&&(e.tags=mr({transaction:r},e.tags))}return this._applyFingerprint(e),e.breadcrumbs=_r(e.breadcrumbs||[],this._breadcrumbs),e.breadcrumbs=e.breadcrumbs.length>0?e.breadcrumbs:void 0,this._notifyEventProcessors(_r(Yo(),this._eventProcessors),e,t)},e.prototype._notifyEventProcessors=function(e,t,n,r){var o=this;return void 0===r&&(r=0),new jo((function(i,a){var s=e[r];if(null===t||"function"!=typeof s)i(t);else{var c=s(mr({},t),n);Hr(c)?c.then((function(t){return o._notifyEventProcessors(e,t,n,r+1).then(i)})).then(null,a):o._notifyEventProcessors(e,c,n,r+1).then(i).then(null,a)}}))},e.prototype._notifyScopeListeners=function(){var e=this;this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((function(t){t(e)})),this._notifyingListeners=!1)},e.prototype._applyFingerprint=function(e){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],this._fingerprint&&(e.fingerprint=e.fingerprint.concat(this._fingerprint)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint},e}();function Yo(){var e=eo();return e.__SENTRY__=e.__SENTRY__||{},e.__SENTRY__.globalEventProcessors=e.__SENTRY__.globalEventProcessors||[],e.__SENTRY__.globalEventProcessors}function Go(e){Yo().push(e)}!function(e){e.Ok="ok",e.Exited="exited",e.Crashed="crashed",e.Abnormal="abnormal"}(Vo||(Vo={})),function(e){e.Ok="ok",e.Errored="errored",e.Crashed="crashed"}(Wo||(Wo={}));var Xo=function(){function e(e,t,n){void 0===t&&(t=new $o),void 0===n&&(n=4),this._version=n,this._stack=[{}],this.getStackTop().scope=t,this.bindClient(e)}return e.prototype.isOlderThan=function(e){return this._version<e},e.prototype.bindClient=function(e){this.getStackTop().client=e,e&&e.setupIntegrations&&e.setupIntegrations()},e.prototype.pushScope=function(){var e=$o.clone(this.getScope());return this.getStack().push({client:this.getClient(),scope:e}),e},e.prototype.popScope=function(){return!(this.getStack().length<=1||!this.getStack().pop())},e.prototype.withScope=function(e){var t=this.pushScope();try{e(t)}finally{this.popScope()}},e.prototype.getClient=function(){return this.getStackTop().client},e.prototype.getScope=function(){return this.getStackTop().scope},e.prototype.getStack=function(){return this._stack},e.prototype.getStackTop=function(){return this._stack[this._stack.length-1]},e.prototype.captureException=function(e,t){var n=this._lastEventId=to(),r=t;if(!t){var o=void 0;try{throw new Error("Sentry syntheticException")}catch(e){o=e}r={originalException:e,syntheticException:o}}return this._invokeClient("captureException",e,mr(mr({},r),{event_id:n})),n},e.prototype.captureMessage=function(e,t,n){var r=this._lastEventId=to(),o=n;if(!n){var i=void 0;try{throw new Error(e)}catch(e){i=e}o={originalException:e,syntheticException:i}}return this._invokeClient("captureMessage",e,t,mr(mr({},o),{event_id:r})),r},e.prototype.captureEvent=function(e,t){var n=this._lastEventId=to();return this._invokeClient("captureEvent",e,mr(mr({},t),{event_id:n})),n},e.prototype.lastEventId=function(){return this._lastEventId},e.prototype.addBreadcrumb=function(e,t){var n=this.getStackTop(),r=n.scope,o=n.client;if(r&&o){var i=o.getOptions&&o.getOptions()||{},a=i.beforeBreadcrumb,s=void 0===a?null:a,c=i.maxBreadcrumbs,l=void 0===c?100:c;if(!(l<=0)){var u=qo(),d=mr({timestamp:u},e),p=s?oo((function(){return s(d,t)})):d;null!==p&&r.addBreadcrumb(p,Math.min(l,100))}}},e.prototype.setUser=function(e){var t=this.getScope();t&&t.setUser(e)},e.prototype.setTags=function(e){var t=this.getScope();t&&t.setTags(e)},e.prototype.setExtras=function(e){var t=this.getScope();t&&t.setExtras(e)},e.prototype.setTag=function(e,t){var n=this.getScope();n&&n.setTag(e,t)},e.prototype.setExtra=function(e,t){var n=this.getScope();n&&n.setExtra(e,t)},e.prototype.setContext=function(e,t){var n=this.getScope();n&&n.setContext(e,t)},e.prototype.configureScope=function(e){var t=this.getStackTop(),n=t.scope,r=t.client;n&&r&&e(n)},e.prototype.run=function(e){var t=Ko(this);try{e(this)}finally{Ko(t)}},e.prototype.getIntegration=function(e){var t=this.getClient();if(!t)return null;try{return t.getIntegration(e)}catch(t){return uo.warn("Cannot retrieve integration "+e.id+" from the current Hub"),null}},e.prototype.startSpan=function(e){return this._callExtensionMethod("startSpan",e)},e.prototype.startTransaction=function(e,t){return this._callExtensionMethod("startTransaction",e,t)},e.prototype.traceHeaders=function(){return this._callExtensionMethod("traceHeaders")},e.prototype.captureSession=function(e){if(void 0===e&&(e=!1),e)return this.endSession();this._sendSessionUpdate()},e.prototype.endSession=function(){var e,t,n,r,o;null===(n=null===(t=null===(e=this.getStackTop())||void 0===e?void 0:e.scope)||void 0===t?void 0:t.getSession())||void 0===n||n.close(),this._sendSessionUpdate(),null===(o=null===(r=this.getStackTop())||void 0===r?void 0:r.scope)||void 0===o||o.setSession()},e.prototype.startSession=function(e){var t=this.getStackTop(),n=t.scope,r=t.client,o=r&&r.getOptions()||{},i=o.release,a=o.environment,s=new ni(mr(mr({release:i,environment:a},n&&{user:n.getUser()}),e));if(n){var c=n.getSession&&n.getSession();c&&c.status===Vo.Ok&&c.update({status:Vo.Exited}),this.endSession(),n.setSession(s)}return s},e.prototype._sendSessionUpdate=function(){var e=this.getStackTop(),t=e.scope,n=e.client;if(t){var r=t.getSession&&t.getSession();r&&n&&n.captureSession&&n.captureSession(r)}},e.prototype._invokeClient=function(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var o=this.getStackTop(),i=o.scope,a=o.client;a&&a[e]&&(t=a)[e].apply(t,_r(n,[i]))},e.prototype._callExtensionMethod=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=Jo(),o=r.__SENTRY__;if(o&&o.extensions&&"function"==typeof o.extensions[e])return o.extensions[e].apply(this,t);uo.warn("Extension method "+e+" couldn't be found, doing nothing.")},e}();function Jo(){var e=eo();return e.__SENTRY__=e.__SENTRY__||{extensions:{},hub:void 0},e}function Ko(e){var t=Jo(),n=ei(t);return ti(t,e),n}function Zo(){var e=Jo();return Qo(e)&&!ei(e).isOlderThan(4)||ti(e,new Xo),Xr()?function(e){var t,n,r;try{var o=null===(r=null===(n=null===(t=Jo().__SENTRY__)||void 0===t?void 0:t.extensions)||void 0===n?void 0:n.domain)||void 0===r?void 0:r.active;if(!o)return ei(e);if(!Qo(o)||ei(o).isOlderThan(4)){var i=ei(e).getStackTop();ti(o,new Xo(i.client,$o.clone(i.scope)))}return ei(o)}catch(t){return ei(e)}}(e):ei(e)}function Qo(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function ei(e){return e&&e.__SENTRY__&&e.__SENTRY__.hub||(e.__SENTRY__=e.__SENTRY__||{},e.__SENTRY__.hub=new Xo),e.__SENTRY__.hub}function ti(e,t){return!!e&&(e.__SENTRY__=e.__SENTRY__||{},e.__SENTRY__.hub=t,!0)}var ni=function(){function e(e){this.errors=0,this.sid=to(),this.timestamp=Date.now(),this.started=Date.now(),this.duration=0,this.status=Vo.Ok,this.init=!0,e&&this.update(e)}return e.prototype.update=function(e){void 0===e&&(e={}),e.user&&(e.user.ip_address&&(this.ipAddress=e.user.ip_address),e.did||(this.did=e.user.id||e.user.email||e.user.username)),this.timestamp=e.timestamp||Date.now(),e.sid&&(this.sid=32===e.sid.length?e.sid:to()),void 0!==e.init&&(this.init=e.init),e.did&&(this.did=""+e.did),"number"==typeof e.started&&(this.started=e.started),"number"==typeof e.duration?this.duration=e.duration:this.duration=this.timestamp-this.started,e.release&&(this.release=e.release),e.environment&&(this.environment=e.environment),e.ipAddress&&(this.ipAddress=e.ipAddress),e.userAgent&&(this.userAgent=e.userAgent),"number"==typeof e.errors&&(this.errors=e.errors),e.status&&(this.status=e.status)},e.prototype.close=function(e){e?this.update({status:e}):this.status===Vo.Ok?this.update({status:Vo.Exited}):this.update()},e.prototype.toJSON=function(){return xo({sid:""+this.sid,init:this.init,started:new Date(this.started).toISOString(),timestamp:new Date(this.timestamp).toISOString(),status:this.status,errors:this.errors,did:"number"==typeof this.did||"string"==typeof this.did?""+this.did:void 0,duration:this.duration,attrs:xo({release:this.release,environment:this.environment,ip_address:this.ipAddress,user_agent:this.userAgent})})},e}();function ri(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=Zo();if(r&&r[e])return r[e].apply(r,_r(t));throw new Error("No hub defined or "+e+" was not found on the hub, please open a bug report.")}function oi(e,t){var n;try{throw new Error("Sentry syntheticException")}catch(e){n=e}return ri("captureException",e,{captureContext:t,originalException:e,syntheticException:n})}function ii(e){ri("withScope",e)}var ai,si,ci,li=function(){function e(e,t){void 0===t&&(t={}),this.dsn=e,this._dsnObject=new Gr(e),this.metadata=t}return e.prototype.getDsn=function(){return this._dsnObject},e.prototype.getBaseApiEndpoint=function(){var e=this._dsnObject,t=e.protocol?e.protocol+":":"",n=e.port?":"+e.port:"";return t+"//"+e.host+n+(e.path?"/"+e.path:"")+"/api/"},e.prototype.getStoreEndpoint=function(){return this._getIngestEndpoint("store")},e.prototype.getStoreEndpointWithUrlEncodedAuth=function(){return this.getStoreEndpoint()+"?"+this._encodedAuth()},e.prototype.getEnvelopeEndpointWithUrlEncodedAuth=function(){return this._getEnvelopeEndpoint()+"?"+this._encodedAuth()},e.prototype.getStoreEndpointPath=function(){var e=this._dsnObject;return(e.path?"/"+e.path:"")+"/api/"+e.projectId+"/store/"},e.prototype.getRequestHeaders=function(e,t){var n=this._dsnObject,r=["Sentry sentry_version=7"];return r.push("sentry_client="+e+"/"+t),r.push("sentry_key="+n.publicKey),n.pass&&r.push("sentry_secret="+n.pass),{"Content-Type":"application/json","X-Sentry-Auth":r.join(", ")}},e.prototype.getReportDialogEndpoint=function(e){void 0===e&&(e={});var t=this._dsnObject,n=this.getBaseApiEndpoint()+"embed/error-page/",r=[];for(var o in r.push("dsn="+t.toString()),e)if("dsn"!==o)if("user"===o){if(!e.user)continue;e.user.name&&r.push("name="+encodeURIComponent(e.user.name)),e.user.email&&r.push("email="+encodeURIComponent(e.user.email))}else r.push(encodeURIComponent(o)+"="+encodeURIComponent(e[o]));return r.length?n+"?"+r.join("&"):n},e.prototype._getEnvelopeEndpoint=function(){return this._getIngestEndpoint("envelope")},e.prototype._getIngestEndpoint=function(e){return""+this.getBaseApiEndpoint()+this._dsnObject.projectId+"/"+e+"/"},e.prototype._encodedAuth=function(){var e,t={sentry_key:this._dsnObject.publicKey,sentry_version:"7"};return e=t,Object.keys(e).map((function(t){return encodeURIComponent(t)+"="+encodeURIComponent(e[t])})).join("&")},e}();!function(e){e.Ok="ok",e.Exited="exited",e.Crashed="crashed",e.Abnormal="abnormal"}(ai||(ai={})),function(e){e.Ok="ok",e.Errored="errored",e.Crashed="crashed"}(si||(si={})),function(e){e.Unknown="unknown",e.Skipped="skipped",e.Success="success",e.RateLimit="rate_limit",e.Invalid="invalid",e.Failed="failed"}(ci||(ci={})),function(e){e.fromHttpCode=function(t){return t>=200&&t<300?e.Success:429===t?e.RateLimit:t>=400&&t<500?e.Invalid:t>=500?e.Failed:e.Unknown}}(ci||(ci={}));var ui=[];function di(e){return e.reduce((function(e,t){return e.every((function(e){return t.name!==e.name}))&&e.push(t),e}),[])}var pi=function(){function e(e,t){this._integrations={},this._processing=0,this._backend=new e(t),this._options=t,t.dsn&&(this._dsn=new Gr(t.dsn))}return e.prototype.captureException=function(e,t,n){var r=this,o=t&&t.event_id;return this._process(this._getBackend().eventFromException(e,t).then((function(e){return r._captureEvent(e,t,n)})).then((function(e){o=e}))),o},e.prototype.captureMessage=function(e,t,n,r){var o=this,i=n&&n.event_id,a=Lr(e)?this._getBackend().eventFromMessage(String(e),t,n):this._getBackend().eventFromException(e,n);return this._process(a.then((function(e){return o._captureEvent(e,n,r)})).then((function(e){i=e}))),i},e.prototype.captureEvent=function(e,t,n){var r=t&&t.event_id;return this._process(this._captureEvent(e,t,n).then((function(e){r=e}))),r},e.prototype.captureSession=function(e){"string"!=typeof e.release?uo.warn("Discarded session because of missing or non-string release"):(this._sendSession(e),e.update({init:!1}))},e.prototype.getDsn=function(){return this._dsn},e.prototype.getOptions=function(){return this._options},e.prototype.flush=function(e){var t=this;return this._isClientProcessing(e).then((function(n){return t._getBackend().getTransport().close(e).then((function(e){return n&&e}))}))},e.prototype.close=function(e){var t=this;return this.flush(e).then((function(e){return t.getOptions().enabled=!1,e}))},e.prototype.setupIntegrations=function(){var e,t;this._isEnabled()&&(this._integrations=(e=this._options,t={},function(e){var t=e.defaultIntegrations&&_r(e.defaultIntegrations)||[],n=e.integrations,r=_r(di(t));Array.isArray(n)?r=_r(r.filter((function(e){return n.every((function(t){return t.name!==e.name}))})),di(n)):"function"==typeof n&&(r=n(r),r=Array.isArray(r)?r:[r]);var o=r.map((function(e){return e.name}));return-1!==o.indexOf("Debug")&&r.push.apply(r,_r(r.splice(o.indexOf("Debug"),1))),r}(e).forEach((function(e){t[e.name]=e,function(e){-1===ui.indexOf(e.name)&&(e.setupOnce(Go,Zo),ui.push(e.name),uo.log("Integration installed: "+e.name))}(e)})),t))},e.prototype.getIntegration=function(e){try{return this._integrations[e.id]||null}catch(t){return uo.warn("Cannot retrieve integration "+e.id+" from the current Client"),null}},e.prototype._updateSessionFromEvent=function(e,t){var n,r,o,i=!1,a=!1,s=t.exception&&t.exception.values;if(s){a=!0;try{for(var c=br(s),l=c.next();!l.done;l=c.next()){var u=l.value.mechanism;if(u&&!1===u.handled){i=!0;break}}}catch(e){n={error:e}}finally{try{l&&!l.done&&(r=c.return)&&r.call(c)}finally{if(n)throw n.error}}}var d=t.user;if(!e.userAgent){var p=t.request?t.request.headers:{};for(var f in p)if("user-agent"===f.toLowerCase()){o=p[f];break}}e.update(mr(mr({},i&&{status:ai.Crashed}),{user:d,userAgent:o,errors:e.errors+Number(a||i)})),this.captureSession(e)},e.prototype._sendSession=function(e){this._getBackend().sendSession(e)},e.prototype._isClientProcessing=function(e){var t=this;return new jo((function(n){var r=0,o=setInterval((function(){0==t._processing?(clearInterval(o),n(!0)):(r+=1,e&&r>=e&&(clearInterval(o),n(!1)))}),1)}))},e.prototype._getBackend=function(){return this._backend},e.prototype._isEnabled=function(){return!1!==this.getOptions().enabled&&void 0!==this._dsn},e.prototype._prepareEvent=function(e,t,n){var r=this,o=this.getOptions().normalizeDepth,i=void 0===o?3:o,a=mr(mr({},e),{event_id:e.event_id||(n&&n.event_id?n.event_id:to()),timestamp:e.timestamp||qo()});this._applyClientOptions(a),this._applyIntegrationsMetadata(a);var s=t;n&&n.captureContext&&(s=$o.clone(s).update(n.captureContext));var c=jo.resolve(a);return s&&(c=s.applyToEvent(a,n)),c.then((function(e){return"number"==typeof i&&i>0?r._normalizeEvent(e,i):e}))},e.prototype._normalizeEvent=function(e,t){if(!e)return null;var n=mr(mr(mr(mr(mr({},e),e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map((function(e){return mr(mr({},e),e.data&&{data:yo(e.data,t)})}))}),e.user&&{user:yo(e.user,t)}),e.contexts&&{contexts:yo(e.contexts,t)}),e.extra&&{extra:yo(e.extra,t)});return e.contexts&&e.contexts.trace&&(n.contexts.trace=e.contexts.trace),n},e.prototype._applyClientOptions=function(e){var t=this.getOptions(),n=t.environment,r=t.release,o=t.dist,i=t.maxValueLength,a=void 0===i?250:i;"environment"in e||(e.environment="environment"in t?n:"production"),void 0===e.release&&void 0!==r&&(e.release=r),void 0===e.dist&&void 0!==o&&(e.dist=o),e.message&&(e.message=Jr(e.message,a));var s=e.exception&&e.exception.values&&e.exception.values[0];s&&s.value&&(s.value=Jr(s.value,a));var c=e.request;c&&c.url&&(c.url=Jr(c.url,a))},e.prototype._applyIntegrationsMetadata=function(e){var t=Object.keys(this._integrations);t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=_r(e.sdk.integrations||[],t))},e.prototype._sendEvent=function(e){this._getBackend().sendEvent(e)},e.prototype._captureEvent=function(e,t,n){return this._processEvent(e,t,n).then((function(e){return e.event_id}),(function(e){uo.error(e)}))},e.prototype._processEvent=function(e,t,n){var r=this,o=this.getOptions(),i=o.beforeSend,a=o.sampleRate;if(!this._isEnabled())return jo.reject(new $r("SDK not enabled, will not send event."));var s="transaction"===e.type;return!s&&"number"==typeof a&&Math.random()>a?jo.reject(new $r("Discarding event because it's not included in the random sample (sampling rate = "+a+")")):this._prepareEvent(e,n,t).then((function(e){if(null===e)throw new $r("An event processor returned null, will not send event.");if(t&&t.data&&!0===t.data.__sentry__||s||!i)return e;var n=i(e,t);if(void 0===n)throw new $r("`beforeSend` method has to return `null` or a valid event.");return Hr(n)?n.then((function(e){return e}),(function(e){throw new $r("beforeSend rejected with "+e)})):n})).then((function(e){if(null===e)throw new $r("`beforeSend` returned `null`, will not send event.");var t=n&&n.getSession&&n.getSession();return!s&&t&&r._updateSessionFromEvent(t,e),r._sendEvent(e),e})).then(null,(function(e){if(e instanceof $r)throw e;throw r.captureException(e,{data:{__sentry__:!0},originalException:e}),new $r("Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: "+e)}))},e.prototype._process=function(e){var t=this;this._processing+=1,e.then((function(e){return t._processing-=1,e}),(function(e){return t._processing-=1,e}))},e}(),fi=function(){function e(){}return e.prototype.sendEvent=function(e){return jo.resolve({reason:"NoopTransport: Event has been skipped because no Dsn is configured.",status:ci.Skipped})},e.prototype.close=function(e){return jo.resolve(!0)},e}(),hi=function(){function e(e){this._options=e,this._options.dsn||uo.warn("No DSN provided, backend will not do anything."),this._transport=this._setupTransport()}return e.prototype.eventFromException=function(e,t){throw new $r("Backend has to implement `eventFromException` method")},e.prototype.eventFromMessage=function(e,t,n){throw new $r("Backend has to implement `eventFromMessage` method")},e.prototype.sendEvent=function(e){this._transport.sendEvent(e).then(null,(function(e){uo.error("Error while sending event: "+e)}))},e.prototype.sendSession=function(e){this._transport.sendSession?this._transport.sendSession(e).then(null,(function(e){uo.error("Error while sending session: "+e)})):uo.warn("Dropping session because custom transport doesn't implement sendSession")},e.prototype.getTransport=function(){return this._transport},e.prototype._setupTransport=function(){return new fi},e}();function mi(e){if(e.metadata&&e.metadata.sdk){var t=e.metadata.sdk;return{name:t.name,version:t.version}}}function gi(e,t){return t?(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=_r(e.sdk.integrations||[],t.integrations||[]),e.sdk.packages=_r(e.sdk.packages||[],t.packages||[]),e):e}function vi(e,t){var n=mi(t),r="aggregates"in e?"sessions":"session";return{body:JSON.stringify(mr({sent_at:(new Date).toISOString()},n&&{sdk:n}))+"\n"+JSON.stringify({type:r})+"\n"+JSON.stringify(e),type:r,url:t.getEnvelopeEndpointWithUrlEncodedAuth()}}function yi(e,t){var n=mi(t),r=e.type||"event",o="transaction"===r,i=e.debug_meta||{},a=i.transactionSampling,s=gr(i,["transactionSampling"]),c=a||{},l=c.method,u=c.rate;0===Object.keys(s).length?delete e.debug_meta:e.debug_meta=s;var d={body:JSON.stringify(n?gi(e,t.metadata.sdk):e),type:r,url:o?t.getEnvelopeEndpointWithUrlEncodedAuth():t.getStoreEndpointWithUrlEncodedAuth()};if(o){var p=JSON.stringify(mr({event_id:e.event_id,sent_at:(new Date).toISOString()},n&&{sdk:n}))+"\n"+JSON.stringify({type:e.type,sample_rates:[{id:l,rate:u}]})+"\n"+d.body;d.body=p}return d}var bi,xi=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(){bi=Function.prototype.toString,Function.prototype.toString=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=this.__sentry_original__||this;return bi.apply(n,e)}},e.id="FunctionToString",e}(),_i=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/],wi=function(){function e(t){void 0===t&&(t={}),this._options=t,this.name=e.id}return e.prototype.setupOnce=function(){Go((function(t){var n=Zo();if(!n)return t;var r=n.getIntegration(e);if(r){var o=n.getClient(),i=o?o.getOptions():{},a="function"==typeof r._mergeOptions?r._mergeOptions(i):{};return"function"!=typeof r._shouldDropEvent?t:r._shouldDropEvent(t,a)?null:t}return t}))},e.prototype._shouldDropEvent=function(e,t){return this._isSentryError(e,t)?(uo.warn("Event dropped due to being internal Sentry Error.\nEvent: "+ro(e)),!0):this._isIgnoredError(e,t)?(uo.warn("Event dropped due to being matched by `ignoreErrors` option.\nEvent: "+ro(e)),!0):this._isDeniedUrl(e,t)?(uo.warn("Event dropped due to being matched by `denyUrls` option.\nEvent: "+ro(e)+".\nUrl: "+this._getEventFilterUrl(e)),!0):!this._isAllowedUrl(e,t)&&(uo.warn("Event dropped due to not being matched by `allowUrls` option.\nEvent: "+ro(e)+".\nUrl: "+this._getEventFilterUrl(e)),!0)},e.prototype._isSentryError=function(e,t){if(!t.ignoreInternal)return!1;try{return e&&e.exception&&e.exception.values&&e.exception.values[0]&&"SentryError"===e.exception.values[0].type||!1}catch(e){return!1}},e.prototype._isIgnoredError=function(e,t){return!(!t.ignoreErrors||!t.ignoreErrors.length)&&this._getPossibleEventMessages(e).some((function(e){return t.ignoreErrors.some((function(t){return Zr(e,t)}))}))},e.prototype._isDeniedUrl=function(e,t){if(!t.denyUrls||!t.denyUrls.length)return!1;var n=this._getEventFilterUrl(e);return!!n&&t.denyUrls.some((function(e){return Zr(n,e)}))},e.prototype._isAllowedUrl=function(e,t){if(!t.allowUrls||!t.allowUrls.length)return!0;var n=this._getEventFilterUrl(e);return!n||t.allowUrls.some((function(e){return Zr(n,e)}))},e.prototype._mergeOptions=function(e){return void 0===e&&(e={}),{allowUrls:_r(this._options.whitelistUrls||[],this._options.allowUrls||[],e.whitelistUrls||[],e.allowUrls||[]),denyUrls:_r(this._options.blacklistUrls||[],this._options.denyUrls||[],e.blacklistUrls||[],e.denyUrls||[]),ignoreErrors:_r(this._options.ignoreErrors||[],e.ignoreErrors||[],_i),ignoreInternal:void 0===this._options.ignoreInternal||this._options.ignoreInternal}},e.prototype._getPossibleEventMessages=function(e){if(e.message)return[e.message];if(e.exception)try{var t=e.exception.values&&e.exception.values[0]||{},n=t.type,r=void 0===n?"":n,o=t.value,i=void 0===o?"":o;return[""+i,r+": "+i]}catch(t){return uo.error("Cannot extract message for event "+ro(e)),[]}return[]},e.prototype._getEventFilterUrl=function(e){try{if(e.stacktrace){var t=e.stacktrace.frames;return t&&t[t.length-1].filename||null}if(e.exception){var n=e.exception.values&&e.exception.values[0].stacktrace&&e.exception.values[0].stacktrace.frames;return n&&n[n.length-1].filename||null}return null}catch(t){return uo.error("Cannot extract url for event "+ro(e)),null}},e.id="InboundFilters",e}(),Si=/^\s*at (?:(.*?) ?\()?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,Ei=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension|capacitor).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,ki=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,Ci=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,Ti=/\((\S*)(?::(\d+))(?::(\d+))\)/,Ni=/Minified React error #\d+;/i;function Ii(e){var t=null,n=0;e&&("number"==typeof e.framesToPop?n=e.framesToPop:Ni.test(e.message)&&(n=1));try{if(t=function(e){if(!e||!e.stacktrace)return null;for(var t,n=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,r=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\((.*)\))? in (.*):\s*$/i,o=e.stacktrace.split("\n"),i=[],a=0;a<o.length;a+=2){var s=null;(t=n.exec(o[a]))?s={url:t[2],func:t[3],args:[],line:+t[1],column:null}:(t=r.exec(o[a]))&&(s={url:t[6],func:t[3]||t[4],args:t[5]?t[5].split(","):[],line:+t[1],column:+t[2]}),s&&(!s.func&&s.line&&(s.func="?"),i.push(s))}return i.length?{message:Ai(e),name:e.name,stack:i}:null}(e))return Oi(t,n)}catch(e){}try{if(t=function(e){if(!e||!e.stack)return null;for(var t,n,r,o=[],i=e.stack.split("\n"),a=0;a<i.length;++a){if(n=Si.exec(i[a])){var s=n[2]&&0===n[2].indexOf("native");n[2]&&0===n[2].indexOf("eval")&&(t=Ti.exec(n[2]))&&(n[2]=t[1],n[3]=t[2],n[4]=t[3]);var c=n[2]&&0===n[2].indexOf("address at ")?n[2].substr("address at ".length):n[2],l=n[1]||"?",u=-1!==l.indexOf("safari-extension"),d=-1!==l.indexOf("safari-web-extension");(u||d)&&(l=-1!==l.indexOf("@")?l.split("@")[0]:"?",c=u?"safari-extension:"+c:"safari-web-extension:"+c),r={url:c,func:l,args:s?[n[2]]:[],line:n[3]?+n[3]:null,column:n[4]?+n[4]:null}}else if(n=ki.exec(i[a]))r={url:n[2],func:n[1]||"?",args:[],line:+n[3],column:n[4]?+n[4]:null};else{if(!(n=Ei.exec(i[a])))continue;n[3]&&n[3].indexOf(" > eval")>-1&&(t=Ci.exec(n[3]))?(n[1]=n[1]||"eval",n[3]=t[1],n[4]=t[2],n[5]=""):0!==a||n[5]||void 0===e.columnNumber||(o[0].column=e.columnNumber+1),r={url:n[3],func:n[1]||"?",args:n[2]?n[2].split(","):[],line:n[4]?+n[4]:null,column:n[5]?+n[5]:null}}!r.func&&r.line&&(r.func="?"),o.push(r)}return o.length?{message:Ai(e),name:e.name,stack:o}:null}(e))return Oi(t,n)}catch(e){}return{message:Ai(e),name:e&&e.name,stack:[],failed:!0}}function Oi(e,t){try{return mr(mr({},e),{stack:e.stack.slice(t)})}catch(t){return e}}function Ai(e){var t=e&&e.message;return t?t.error&&"string"==typeof t.error.message?t.error.message:t:"No error message"}function Pi(e){var t=Ri(e.stack),n={type:e.name,value:e.message};return t&&t.length&&(n.stacktrace={frames:t}),void 0===n.type&&""===n.value&&(n.value="Unrecoverable error caught"),n}function Bi(e){return{exception:{values:[Pi(e)]}}}function Ri(e){if(!e||!e.length)return[];var t=e,n=t[0].func||"",r=t[t.length-1].func||"";return-1===n.indexOf("captureMessage")&&-1===n.indexOf("captureException")||(t=t.slice(1)),-1!==r.indexOf("sentryWrapped")&&(t=t.slice(0,-1)),t.slice(0,50).map((function(e){return{colno:null===e.column?void 0:e.column,filename:e.url||t[0].url,function:e.func||"?",in_app:!0,lineno:null===e.line?void 0:e.line}})).reverse()}function Fi(e,t,n){var r,o;if(void 0===n&&(n={}),Rr(e)&&e.error)return Bi(Ii(e=e.error));if(Fr(e)||(o=e,"[object DOMException]"===Object.prototype.toString.call(o))){var i=e,a=i.name||(Fr(i)?"DOMError":"DOMException"),s=i.message?a+": "+i.message:a;return io(r=zi(s,t,n),s),"code"in i&&(r.tags=mr(mr({},r.tags),{"DOMException.code":""+i.code})),r}return Br(e)?r=Bi(Ii(e)):jr(e)||Mr(e)?(ao(r=function(e,t,n){var r={exception:{values:[{type:Mr(e)?e.constructor.name:n?"UnhandledRejection":"Error",value:"Non-Error "+(n?"promise rejection":"exception")+" captured with keys: "+bo(e)}]},extra:{__serialized__:go(e)}};if(t){var o=Ri(Ii(t).stack);r.stacktrace={frames:o}}return r}(e,t,n.rejection),{synthetic:!0}),r):(io(r=zi(e,t,n),""+e,void 0),ao(r,{synthetic:!0}),r)}function zi(e,t,n){void 0===n&&(n={});var r={message:e};if(n.attachStacktrace&&t){var o=Ri(Ii(t).stack);r.stacktrace={frames:o}}return r}var Li={event:"error",transaction:"transaction",session:"session",attachment:"attachment"},ji=function(){function e(e){this.options=e,this._buffer=new Mo(30),this._rateLimits={},this._api=new li(e.dsn,e._metadata),this.url=this._api.getStoreEndpointWithUrlEncodedAuth()}return e.prototype.sendEvent=function(e){throw new $r("Transport Class has to implement `sendEvent` method")},e.prototype.close=function(e){return this._buffer.drain(e)},e.prototype._handleResponse=function(e){var t=e.requestType,n=e.response,r=e.headers,o=e.resolve,i=e.reject,a=Tr.fromHttpCode(n.status);this._handleRateLimit(r)&&uo.warn("Too many requests, backing off until: "+this._disabledUntil(t)),a!==Tr.Success?i(n):o({status:a})},e.prototype._disabledUntil=function(e){var t=Li[e];return this._rateLimits[t]||this._rateLimits.all},e.prototype._isRateLimited=function(e){return this._disabledUntil(e)>new Date(Date.now())},e.prototype._handleRateLimit=function(e){var t,n,r,o,i=Date.now(),a=e["x-sentry-rate-limits"],s=e["retry-after"];if(a){try{for(var c=br(a.trim().split(",")),l=c.next();!l.done;l=c.next()){var u=l.value.split(":",2),d=parseInt(u[0],10),p=1e3*(isNaN(d)?60:d);try{for(var f=(r=void 0,br(u[1].split(";"))),h=f.next();!h.done;h=f.next()){var m=h.value;this._rateLimits[m||"all"]=new Date(i+p)}}catch(e){r={error:e}}finally{try{h&&!h.done&&(o=f.return)&&o.call(f)}finally{if(r)throw r.error}}}}catch(e){t={error:e}}finally{try{l&&!l.done&&(n=c.return)&&n.call(c)}finally{if(t)throw t.error}}return!0}return!!s&&(this._rateLimits.all=new Date(i+function(e,t){if(!t)return 6e4;var n=parseInt(""+t,10);if(!isNaN(n))return 1e3*n;var r=Date.parse(""+t);return isNaN(r)?6e4:r-e}(i,s)),!0)},e}(),Mi=function(e){function t(t,n){void 0===n&&(n=function(){var e,t,n=eo();if(wo(n.fetch))return n.fetch.bind(n);var r=n.document,o=n.fetch;if("function"==typeof(null===(e=r)||void 0===e?void 0:e.createElement))try{var i=r.createElement("iframe");i.hidden=!0,r.head.appendChild(i),(null===(t=i.contentWindow)||void 0===t?void 0:t.fetch)&&(o=i.contentWindow.fetch),r.head.removeChild(i)}catch(e){uo.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",e)}return o.bind(n)}());var r=e.call(this,t)||this;return r._fetch=n,r}return hr(t,e),t.prototype.sendEvent=function(e){return this._sendRequest(yi(e,this._api),e)},t.prototype.sendSession=function(e){return this._sendRequest(vi(e,this._api),e)},t.prototype._sendRequest=function(e,t){var n=this;if(this._isRateLimited(e.type))return Promise.reject({event:t,type:e.type,reason:"Transport locked till "+this._disabledUntil(e.type)+" due to too many requests.",status:429});var r={body:e.body,method:"POST",referrerPolicy:So()?"origin":""};return void 0!==this.options.fetchParameters&&Object.assign(r,this.options.fetchParameters),void 0!==this.options.headers&&(r.headers=this.options.headers),this._buffer.add(new jo((function(t,o){n._fetch(e.url,r).then((function(r){var i={"x-sentry-rate-limits":r.headers.get("X-Sentry-Rate-Limits"),"retry-after":r.headers.get("Retry-After")};n._handleResponse({requestType:e.type,response:r,headers:i,resolve:t,reject:o})})).catch(o)})))},t}(ji),Di=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return hr(t,e),t.prototype.sendEvent=function(e){return this._sendRequest(yi(e,this._api),e)},t.prototype.sendSession=function(e){return this._sendRequest(vi(e,this._api),e)},t.prototype._sendRequest=function(e,t){var n=this;return this._isRateLimited(e.type)?Promise.reject({event:t,type:e.type,reason:"Transport locked till "+this._disabledUntil(e.type)+" due to too many requests.",status:429}):this._buffer.add(new jo((function(t,r){var o=new XMLHttpRequest;for(var i in o.onreadystatechange=function(){if(4===o.readyState){var i={"x-sentry-rate-limits":o.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":o.getResponseHeader("Retry-After")};n._handleResponse({requestType:e.type,response:o,headers:i,resolve:t,reject:r})}},o.open("POST",e.url),n.options.headers)n.options.headers.hasOwnProperty(i)&&o.setRequestHeader(i,n.options.headers[i]);o.send(e.body)})))},t}(ji),Hi=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return hr(t,e),t.prototype.eventFromException=function(e,t){return function(e,t,n){var r=Fi(t,n&&n.syntheticException||void 0,{attachStacktrace:e.attachStacktrace});return ao(r,{handled:!0,type:"generic"}),r.level=Cr.Error,n&&n.event_id&&(r.event_id=n.event_id),jo.resolve(r)}(this._options,e,t)},t.prototype.eventFromMessage=function(e,t,n){return void 0===t&&(t=Cr.Info),function(e,t,n,r){void 0===n&&(n=Cr.Info);var o=zi(t,r&&r.syntheticException||void 0,{attachStacktrace:e.attachStacktrace});return o.level=n,r&&r.event_id&&(o.event_id=r.event_id),jo.resolve(o)}(this._options,e,t,n)},t.prototype._setupTransport=function(){if(!this._options.dsn)return e.prototype._setupTransport.call(this);var t=mr(mr({},this._options.transportOptions),{dsn:this._options.dsn,_metadata:this._options._metadata});return this._options.transport?new this._options.transport(t):_o()?new Mi(t):new Di(t)},t}(hi),Ui=0;function qi(){return Ui>0}function Vi(){Ui+=1,setTimeout((function(){Ui-=1}))}function Wi(e,t,n){if(void 0===t&&(t={}),"function"!=typeof e)return e;try{if(e.__sentry__)return e;if(e.__sentry_wrapped__)return e.__sentry_wrapped__}catch(t){return e}var r=function(){var r=Array.prototype.slice.call(arguments);try{n&&"function"==typeof n&&n.apply(this,arguments);var o=r.map((function(e){return Wi(e,t)}));return e.handleEvent?e.handleEvent.apply(this,o):e.apply(this,o)}catch(e){throw Vi(),ii((function(n){n.addEventProcessor((function(e){var n=mr({},e);return t.mechanism&&(io(n,void 0,void 0),ao(n,t.mechanism)),n.extra=mr(mr({},n.extra),{arguments:r}),n})),oi(e)})),e}};try{for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(r[o]=e[o])}catch(e){}e.prototype=e.prototype||{},r.prototype=e.prototype,Object.defineProperty(e,"__sentry_wrapped__",{enumerable:!1,value:r}),Object.defineProperties(r,{__sentry__:{enumerable:!1,value:!0},__sentry_original__:{enumerable:!1,value:e}});try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get:function(){return e.name}})}catch(e){}return r}var $i=function(){function e(t){this.name=e.id,this._onErrorHandlerInstalled=!1,this._onUnhandledRejectionHandlerInstalled=!1,this._options=mr({onerror:!0,onunhandledrejection:!0},t)}return e.prototype.setupOnce=function(){Error.stackTraceLimit=50,this._options.onerror&&(uo.log("Global Handler attached: onerror"),this._installGlobalOnErrorHandler()),this._options.onunhandledrejection&&(uo.log("Global Handler attached: onunhandledrejection"),this._installGlobalOnUnhandledRejectionHandler())},e.prototype._installGlobalOnErrorHandler=function(){var t=this;this._onErrorHandlerInstalled||(Oo({callback:function(n){var r=n.error,o=Zo(),i=o.getIntegration(e),a=r&&!0===r.__sentry_own_request__;if(i&&!qi()&&!a){var s=o.getClient(),c=Lr(r)?t._eventFromIncompleteOnError(n.msg,n.url,n.line,n.column):t._enhanceEventWithInitialFrame(Fi(r,void 0,{attachStacktrace:s&&s.getOptions().attachStacktrace,rejection:!1}),n.url,n.line,n.column);ao(c,{handled:!1,type:"onerror"}),o.captureEvent(c,{originalException:r})}},type:"error"}),this._onErrorHandlerInstalled=!0)},e.prototype._installGlobalOnUnhandledRejectionHandler=function(){var t=this;this._onUnhandledRejectionHandlerInstalled||(Oo({callback:function(n){var r=n;try{"reason"in n?r=n.reason:"detail"in n&&"reason"in n.detail&&(r=n.detail.reason)}catch(e){}var o=Zo(),i=o.getIntegration(e),a=r&&!0===r.__sentry_own_request__;if(!i||qi()||a)return!0;var s=o.getClient(),c=Lr(r)?t._eventFromRejectionWithPrimitive(r):Fi(r,void 0,{attachStacktrace:s&&s.getOptions().attachStacktrace,rejection:!0});c.level=Cr.Error,ao(c,{handled:!1,type:"onunhandledrejection"}),o.captureEvent(c,{originalException:r})},type:"unhandledrejection"}),this._onUnhandledRejectionHandlerInstalled=!0)},e.prototype._eventFromIncompleteOnError=function(e,t,n,r){var o,i=Rr(e)?e.message:e;if(zr(i)){var a=i.match(/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i);a&&(o=a[1],i=a[2])}var s={exception:{values:[{type:o||"Error",value:i}]}};return this._enhanceEventWithInitialFrame(s,t,n,r)},e.prototype._eventFromRejectionWithPrimitive=function(e){return{exception:{values:[{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: "+String(e)}]}}},e.prototype._enhanceEventWithInitialFrame=function(e,t,n,r){e.exception=e.exception||{},e.exception.values=e.exception.values||[],e.exception.values[0]=e.exception.values[0]||{},e.exception.values[0].stacktrace=e.exception.values[0].stacktrace||{},e.exception.values[0].stacktrace.frames=e.exception.values[0].stacktrace.frames||[];var o=isNaN(parseInt(r,10))?void 0:r,i=isNaN(parseInt(n,10))?void 0:n,a=zr(t)&&t.length>0?t:function(){try{return document.location.href}catch(e){return""}}();return 0===e.exception.values[0].stacktrace.frames.length&&e.exception.values[0].stacktrace.frames.push({colno:o,filename:a,function:"?",in_app:!0,lineno:i}),e},e.id="GlobalHandlers",e}(),Yi=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],Gi=function(){function e(t){this.name=e.id,this._options=mr({XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0},t)}return e.prototype.setupOnce=function(){var e=eo();this._options.setTimeout&&ho(e,"setTimeout",this._wrapTimeFunction.bind(this)),this._options.setInterval&&ho(e,"setInterval",this._wrapTimeFunction.bind(this)),this._options.requestAnimationFrame&&ho(e,"requestAnimationFrame",this._wrapRAF.bind(this)),this._options.XMLHttpRequest&&"XMLHttpRequest"in e&&ho(XMLHttpRequest.prototype,"send",this._wrapXHR.bind(this)),this._options.eventTarget&&(Array.isArray(this._options.eventTarget)?this._options.eventTarget:Yi).forEach(this._wrapEventTarget.bind(this))},e.prototype._wrapTimeFunction=function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=t[0];return t[0]=Wi(r,{mechanism:{data:{function:fo(e)},handled:!0,type:"instrument"}}),e.apply(this,t)}},e.prototype._wrapRAF=function(e){return function(t){return e.call(this,Wi(t,{mechanism:{data:{function:"requestAnimationFrame",handler:fo(e)},handled:!0,type:"instrument"}}))}},e.prototype._wrapEventTarget=function(e){var t=eo(),n=t[e]&&t[e].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(ho(n,"addEventListener",(function(t){return function(n,r,o){try{"function"==typeof r.handleEvent&&(r.handleEvent=Wi(r.handleEvent.bind(r),{mechanism:{data:{function:"handleEvent",handler:fo(r),target:e},handled:!0,type:"instrument"}}))}catch(e){}return t.call(this,n,Wi(r,{mechanism:{data:{function:"addEventListener",handler:fo(r),target:e},handled:!0,type:"instrument"}}),o)}})),ho(n,"removeEventListener",(function(e){return function(t,n,r){var o,i=n;try{var a=null===(o=i)||void 0===o?void 0:o.__sentry_wrapped__;a&&e.call(this,t,a,r)}catch(e){}return e.call(this,t,i,r)}})))},e.prototype._wrapXHR=function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=this,o=["onload","onerror","onprogress","onreadystatechange"];return o.forEach((function(e){e in r&&"function"==typeof r[e]&&ho(r,e,(function(t){var n={mechanism:{data:{function:e,handler:fo(t)},handled:!0,type:"instrument"}};return t.__sentry_original__&&(n.mechanism.data.handler=fo(t.__sentry_original__)),Wi(t,n)}))})),e.apply(this,t)}},e.id="TryCatch",e}(),Xi=function(){function e(t){this.name=e.id,this._options=mr({console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0},t)}return e.prototype.addSentryBreadcrumb=function(e){this._options.sentry&&Zo().addBreadcrumb({category:"sentry."+("transaction"===e.type?"transaction":"event"),event_id:e.event_id,level:e.level,message:ro(e)},{event:e})},e.prototype.setupOnce=function(){var e=this;this._options.console&&Oo({callback:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];e._consoleBreadcrumb.apply(e,_r(t))},type:"console"}),this._options.dom&&Oo({callback:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];e._domBreadcrumb.apply(e,_r(t))},type:"dom"}),this._options.xhr&&Oo({callback:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];e._xhrBreadcrumb.apply(e,_r(t))},type:"xhr"}),this._options.fetch&&Oo({callback:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];e._fetchBreadcrumb.apply(e,_r(t))},type:"fetch"}),this._options.history&&Oo({callback:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];e._historyBreadcrumb.apply(e,_r(t))},type:"history"})},e.prototype._consoleBreadcrumb=function(e){var t={category:"console",data:{arguments:e.args,logger:"console"},level:Cr.fromString(e.level),message:Kr(e.args," ")};if("assert"===e.level){if(!1!==e.args[0])return;t.message="Assertion failed: "+(Kr(e.args.slice(1)," ")||"console.assert"),t.data.arguments=e.args.slice(1)}Zo().addBreadcrumb(t,{input:e.args,level:e.level})},e.prototype._domBreadcrumb=function(e){var t;try{t=e.event.target?qr(e.event.target):qr(e.event)}catch(e){t="<unknown>"}0!==t.length&&Zo().addBreadcrumb({category:"ui."+e.name,message:t},{event:e.event,name:e.name,global:e.global})},e.prototype._xhrBreadcrumb=function(e){if(e.endTimestamp){if(e.xhr.__sentry_own_request__)return;var t=e.xhr.__sentry_xhr__||{},n=t.method,r=t.url,o=t.status_code,i=t.body;Zo().addBreadcrumb({category:"xhr",data:{method:n,url:r,status_code:o},type:"http"},{xhr:e.xhr,input:i})}},e.prototype._fetchBreadcrumb=function(e){e.endTimestamp&&(e.fetchData.url.match(/sentry_key/)&&"POST"===e.fetchData.method||(e.error?Zo().addBreadcrumb({category:"fetch",data:e.fetchData,level:Cr.Error,type:"http"},{data:e.error,input:e.args}):Zo().addBreadcrumb({category:"fetch",data:mr(mr({},e.fetchData),{status_code:e.response.status}),type:"http"},{input:e.args,response:e.response})))},e.prototype._historyBreadcrumb=function(e){var t=eo(),n=e.from,r=e.to,o=no(t.location.href),i=no(n),a=no(r);i.path||(i=o),o.protocol===a.protocol&&o.host===a.host&&(r=a.relative),o.protocol===i.protocol&&o.host===i.host&&(n=i.relative),Zo().addBreadcrumb({category:"navigation",data:{from:n,to:r}})},e.id="Breadcrumbs",e}(),Ji=function(){function e(t){void 0===t&&(t={}),this.name=e.id,this._key=t.key||"cause",this._limit=t.limit||5}return e.prototype.setupOnce=function(){Go((function(t,n){var r=Zo().getIntegration(e);return r?r._handler(t,n):t}))},e.prototype._handler=function(e,t){if(!(e.exception&&e.exception.values&&t&&Ur(t.originalException,Error)))return e;var n=this._walkErrorTree(t.originalException,this._key);return e.exception.values=_r(n,e.exception.values),e},e.prototype._walkErrorTree=function(e,t,n){if(void 0===n&&(n=[]),!Ur(e[t],Error)||n.length+1>=this._limit)return n;var r=Pi(Ii(e[t]));return this._walkErrorTree(e[t],t,_r([r],n))},e.id="LinkedErrors",e}(),Ki=eo(),Zi=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(){Go((function(t){var n,r,o;if(Zo().getIntegration(e)){if(!Ki.navigator&&!Ki.location&&!Ki.document)return t;var i=(null===(n=t.request)||void 0===n?void 0:n.url)||(null===(r=Ki.location)||void 0===r?void 0:r.href),a=(Ki.document||{}).referrer,s=(Ki.navigator||{}).userAgent,c=mr(mr(mr({},null===(o=t.request)||void 0===o?void 0:o.headers),a&&{Referer:a}),s&&{"User-Agent":s}),l=mr(mr({},i&&{url:i}),{headers:c});return mr(mr({},t),{request:l})}return t}))},e.id="UserAgent",e}(),Qi=function(e){function t(t){return void 0===t&&(t={}),t._metadata=t._metadata||{},t._metadata.sdk=t._metadata.sdk||{name:"sentry.javascript.browser",packages:[{name:"npm:@sentry/browser",version:"6.5.0"}],version:"6.5.0"},e.call(this,Hi,t)||this}return hr(t,e),t.prototype.showReportDialog=function(e){void 0===e&&(e={}),eo().document&&(this._isEnabled()?function(e){if(void 0===e&&(e={}),e.eventId)if(e.dsn){var t=document.createElement("script");t.async=!0,t.src=new li(e.dsn).getReportDialogEndpoint(e),e.onLoad&&(t.onload=e.onLoad),(document.head||document.body).appendChild(t)}else uo.error("Missing dsn option in showReportDialog call");else uo.error("Missing eventId option in showReportDialog call")}(mr(mr({},e),{dsn:e.dsn||this.getDsn()})):uo.error("Trying to call showReportDialog with Sentry Client disabled"))},t.prototype._prepareEvent=function(t,n,r){return t.platform=t.platform||"javascript",e.prototype._prepareEvent.call(this,t,n,r)},t.prototype._sendEvent=function(t){var n=this.getIntegration(Xi);n&&n.addSentryBreadcrumb(t),e.prototype._sendEvent.call(this,t)},t}(pi),ea=[new wi,new xi,new Gi,new Xi,new $i,new Ji,new Zi],ta={error:console.error},na=n(null),ra=na.Provider,oa=function(){var e=i(na);if(!e)throw new Error("useRootElement must be used withn a RootElementProvider");return e},ia=n({assetTypes:[],language:"en_US",onSuccess:function(e,t){var n=t.selectedFile;return console.log(e,n)},selectionMode:"MultiSelect",hideExternalAccess:!1}),aa=ia.Provider,sa=function(){return i(ia)},ca=function(){return sa().theme},la=function(){return sa().selectionMode};function ua(e,t,n){return{background:da(e,t,n),color:pa(e,t,n)}}function da(e,t,n){if("Primary"===t||"PrimarySm"===t)return void 0!==(null==e?void 0:e.colorButtonPrimaryActive)&&"Active"===n?e.colorButtonPrimaryActive:void 0===(null==e?void 0:e.colorButtonPrimaryHover)||"Hover"!==n&&"Active"!==n?void 0!==(null==e?void 0:e.colorButtonPrimary)?e.colorButtonPrimary:void 0:e.colorButtonPrimaryHover}function pa(e,t,n){if("Primary"===t||"PrimarySm"===t)return void 0!==(null==e?void 0:e.colorButtonPrimaryHoverLabel)&&"Hover"===n?e.colorButtonPrimaryHoverLabel:void 0!==(null==e?void 0:e.colorButtonPrimaryLabel)?e.colorButtonPrimaryLabel:void 0}function fa(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return e.filter(Boolean).join(" ")}var ha=s((function(e,n){var o,i,a=null!==(o=e.kind)&&void 0!==o?o:"Flat",s=r(!1),c=s[0],l=s[1],u=r(!1),d=u[0],p=u[1],f=ca(),h=fa("rounded inline-flex items-center flex-shrink-0 text-md border border-transparent\n\tselect-none active:shadow-inner focus:outline-none disabled:pointer-events-none\n\ttransition-color",function(e){switch(e){case"Flat":case"Primary":case"Secondary":return"h-10 px-4";case"FlatSm":case"PrimarySm":case"SecondarySm":return"h-8 px-3"}}(a),function(e){switch(e){case"Primary":case"PrimarySm":return"text-ui-0 bg-brand-500 hover:bg-brand-600 active:bg-brand-700\n\t\t\t\tdisabled:opacity-60";case"Secondary":case"SecondarySm":return"text-body-500 bg-ui-400 hover:bg-ui-500 hover:text-body-500 active:bg-ui-700\n\t\t\t\tfocus:text-body-500 disabled:text-body-300 disabled:bg-ui-500";case"Flat":case"FlatSm":return"text-body-400 active:bg-ui-700 active:text-body-500\n\t\t\t\tfocus:bg-ui-500 focus:text-body-500 hover:bg-ui-500 hover:text-body-500\n\t\t\t\tdisabled:text-body-300"}}(a),function(e){switch(e){case"Primary":case"PrimarySm":return"focus:border-ui-900";case"Secondary":case"SecondarySm":return"border-ui-600 focus:border-ui-900 disabled:border-ui-500";case"Flat":case"FlatSm":return"focus:border-ui-700"}}(a),e.className),m=ua(f,a,function(e,t){return t?"Active":e?"Hover":"None"}(c,d));return t.createElement("button",{className:h,style:m,onMouseOver:function(){return l(!0)},onFocus:function(){return l(!0)},onMouseOut:function(){return l(!1)},onBlur:function(){return l(!1)},onMouseDown:function(){return p(!0)},onMouseUp:function(){return p(!1)},title:e.title,disabled:e.isDisabled,onClick:e.onClick,ref:n,"data-testid":null!==(i=e.testId)&&void 0!==i?i:"button",type:"button"},e.children)}));function ma(e){var t;return null!==(t=ga[e])&&void 0!==t?t:e}var ga={};function va(e){a((function(){var t=e.slice(0,2).toLowerCase();fetch("https://d8ejoa1fys2rk.cloudfront.net/5.0.5/modules/compactview/i18n/"+t+".json").then((function(e){return e.json()})).then((function(e){ga=e}))}),[e])}function ya(){return t.createElement("svg",{width:"190",height:"130"},t.createElement("defs",null,t.createElement("linearGradient",{id:"prefix__b",x1:"100%",x2:"25.598%",y1:"11.782%",y2:"100%"},t.createElement("stop",{offset:"0%",stopColor:"#F8FAFC"}),t.createElement("stop",{offset:"100%",stopColor:"#EFF2F4"})),t.createElement("rect",{id:"prefix__a",width:"190",height:"130",rx:"3"})),t.createElement("g",{fill:"none",fillRule:"evenodd"},t.createElement("mask",{id:"prefix__c",fill:"#fff"},t.createElement("use",{xlinkHref:"#prefix__a"})),t.createElement("use",{fill:"url(#prefix__b)",xlinkHref:"#prefix__a"}),t.createElement("g",{mask:"url(#prefix__c)"},t.createElement("path",{fill:"#F5A623",d:"M100.296 45.951l23.01 43.23A6 6 0 01118.009 98H71.991a6 6 0 01-5.297-8.82l23.01-43.229a6 6 0 0110.592 0z"}),t.createElement("path",{fill:"#FFF",fillRule:"nonzero",d:"M93.21 60h3.58a2 2 0 011.99 2.199l-1.6 16A2 2 0 0195.19 80h-.38a2 2 0 01-1.99-1.801l-1.6-16A2 2 0 0193.21 60zM95 84a3 3 0 110 6 3 3 0 010-6z"})),t.createElement("path",{fill:"#EEF1F3",d:"M3 0h184a3 3 0 013 3v13H0V3a3 3 0 013-3z",mask:"url(#prefix__c)"}),t.createElement("circle",{cx:"11",cy:"8",r:"3",fill:"#023",fillOpacity:"0.1",mask:"url(#prefix__c)"}),t.createElement("circle",{cx:"20",cy:"8",r:"3",fill:"#023",fillOpacity:"0.1",mask:"url(#prefix__c)"}),t.createElement("circle",{cx:"29",cy:"8",r:"3",fill:"#023",fillOpacity:"0.1",mask:"url(#prefix__c)"})))}function ba(e){return t.createElement(t.Fragment,null,t.createElement(ya,null),t.createElement("h1",{className:"mt-10 text-2xl"},ma("Oops! Something went wrong")),t.createElement("span",{className:"mt-4 text-body-400"},ma("Please try again or get in contact with our customer support.")),t.createElement("div",{className:"mt-8"},t.createElement(ha,{kind:"Secondary",title:ma("Send report"),onClick:e.onClickSend,isDisabled:e.isReportSent},e.isReportSent?ma("Report sent"):ma("Send report...")),t.createElement(ha,{kind:"Primary",title:ma("Try again"),className:"ml-2",onClick:e.onClickRetry},ma("Try again"))))}var xa={exports:{}},_a={},wa="function"==typeof Symbol&&Symbol.for,Sa=wa?Symbol.for("react.element"):60103,Ea=wa?Symbol.for("react.portal"):60106,ka=wa?Symbol.for("react.fragment"):60107,Ca=wa?Symbol.for("react.strict_mode"):60108,Ta=wa?Symbol.for("react.profiler"):60114,Na=wa?Symbol.for("react.provider"):60109,Ia=wa?Symbol.for("react.context"):60110,Oa=wa?Symbol.for("react.async_mode"):60111,Aa=wa?Symbol.for("react.concurrent_mode"):60111,Pa=wa?Symbol.for("react.forward_ref"):60112,Ba=wa?Symbol.for("react.suspense"):60113,Ra=wa?Symbol.for("react.suspense_list"):60120,Fa=wa?Symbol.for("react.memo"):60115,za=wa?Symbol.for("react.lazy"):60116,La=wa?Symbol.for("react.block"):60121,ja=wa?Symbol.for("react.fundamental"):60117,Ma=wa?Symbol.for("react.responder"):60118,Da=wa?Symbol.for("react.scope"):60119;function Ha(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case Sa:switch(e=e.type){case Oa:case Aa:case ka:case Ta:case Ca:case Ba:return e;default:switch(e=e&&e.$$typeof){case Ia:case Pa:case za:case Fa:case Na:return e;default:return t}}case Ea:return t}}}function Ua(e){return Ha(e)===Aa}function qa(e){function t(e,t,r){var o=t.trim().split(h);t=o;var i=o.length,a=e.length;switch(a){case 0:case 1:var s=0;for(e=0===a?"":e[0]+" ";s<i;++s)t[s]=n(e,t[s],r).trim();break;default:var c=s=0;for(t=[];s<i;++s)for(var l=0;l<a;++l)t[c++]=n(e[l]+" ",o[s],r).trim()}return t}function n(e,t,n){var r=t.charCodeAt(0);switch(33>r&&(r=(t=t.trim()).charCodeAt(0)),r){case 38:return t.replace(m,"$1"+e.trim());case 58:return e.trim()+t.replace(m,"$1"+e.trim());default:if(0<1*n&&0<t.indexOf("\f"))return t.replace(m,(58===e.charCodeAt(0)?"":"$1")+e.trim())}return e+t}function r(e,t,n,i){var a=e+";",s=2*t+3*n+4*i;if(944===s){e=a.indexOf(":",9)+1;var c=a.substring(e,a.length-1).trim();return c=a.substring(0,e).trim()+c+";",1===I||2===I&&o(c,1)?"-webkit-"+c+c:c}if(0===I||2===I&&!o(a,1))return a;switch(s){case 1015:return 97===a.charCodeAt(10)?"-webkit-"+a+a:a;case 951:return 116===a.charCodeAt(3)?"-webkit-"+a+a:a;case 963:return 110===a.charCodeAt(5)?"-webkit-"+a+a:a;case 1009:if(100!==a.charCodeAt(4))break;case 969:case 942:return"-webkit-"+a+a;case 978:return"-webkit-"+a+"-moz-"+a+a;case 1019:case 983:return"-webkit-"+a+"-moz-"+a+"-ms-"+a+a;case 883:if(45===a.charCodeAt(8))return"-webkit-"+a+a;if(0<a.indexOf("image-set(",11))return a.replace(k,"$1-webkit-$2")+a;break;case 932:if(45===a.charCodeAt(4))switch(a.charCodeAt(5)){case 103:return"-webkit-box-"+a.replace("-grow","")+"-webkit-"+a+"-ms-"+a.replace("grow","positive")+a;case 115:return"-webkit-"+a+"-ms-"+a.replace("shrink","negative")+a;case 98:return"-webkit-"+a+"-ms-"+a.replace("basis","preferred-size")+a}return"-webkit-"+a+"-ms-"+a+a;case 964:return"-webkit-"+a+"-ms-flex-"+a+a;case 1023:if(99!==a.charCodeAt(8))break;return"-webkit-box-pack"+(c=a.substring(a.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+a+"-ms-flex-pack"+c+a;case 1005:return p.test(a)?a.replace(d,":-webkit-")+a.replace(d,":-moz-")+a:a;case 1e3:switch(t=(c=a.substring(13).trim()).indexOf("-")+1,c.charCodeAt(0)+c.charCodeAt(t)){case 226:c=a.replace(b,"tb");break;case 232:c=a.replace(b,"tb-rl");break;case 220:c=a.replace(b,"lr");break;default:return a}return"-webkit-"+a+"-ms-"+c+a;case 1017:if(-1===a.indexOf("sticky",9))break;case 975:switch(t=(a=e).length-10,s=(c=(33===a.charCodeAt(t)?a.substring(0,t):a).substring(e.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|c.charCodeAt(7))){case 203:if(111>c.charCodeAt(8))break;case 115:a=a.replace(c,"-webkit-"+c)+";"+a;break;case 207:case 102:a=a.replace(c,"-webkit-"+(102<s?"inline-":"")+"box")+";"+a.replace(c,"-webkit-"+c)+";"+a.replace(c,"-ms-"+c+"box")+";"+a}return a+";";case 938:if(45===a.charCodeAt(5))switch(a.charCodeAt(6)){case 105:return c=a.replace("-items",""),"-webkit-"+a+"-webkit-box-"+c+"-ms-flex-"+c+a;case 115:return"-webkit-"+a+"-ms-flex-item-"+a.replace(w,"")+a;default:return"-webkit-"+a+"-ms-flex-line-pack"+a.replace("align-content","").replace(w,"")+a}break;case 973:case 989:if(45!==a.charCodeAt(3)||122===a.charCodeAt(4))break;case 931:case 953:if(!0===E.test(e))return 115===(c=e.substring(e.indexOf(":")+1)).charCodeAt(0)?r(e.replace("stretch","fill-available"),t,n,i).replace(":fill-available",":stretch"):a.replace(c,"-webkit-"+c)+a.replace(c,"-moz-"+c.replace("fill-",""))+a;break;case 962:if(a="-webkit-"+a+(102===a.charCodeAt(5)?"-ms-"+a:"")+a,211===n+i&&105===a.charCodeAt(13)&&0<a.indexOf("transform",10))return a.substring(0,a.indexOf(";",27)+1).replace(f,"$1-webkit-$2")+a}return a}function o(e,t){var n=e.indexOf(1===t?":":"{"),r=e.substring(0,3!==t?n:10);return n=e.substring(n+1,e.length-1),B(2!==t?r:r.replace(S,"$1"),n,t)}function i(e,t){var n=r(t,t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2));return n!==t+";"?n.replace(_," or ($1)").substring(4):"("+t+")"}function a(e,t,n,r,o,i,a,s,l,u){for(var d,p=0,f=t;p<P;++p)switch(d=A[p].call(c,e,f,n,r,o,i,a,s,l,u)){case void 0:case!1:case!0:case null:break;default:f=d}if(f!==t)return f}function s(e){return void 0!==(e=e.prefix)&&(B=null,e?"function"!=typeof e?I=1:(I=2,B=e):I=0),s}function c(e,n){var s=e;if(33>s.charCodeAt(0)&&(s=s.trim()),s=[s],0<P){var c=a(-1,n,s,s,T,C,0,0,0,0);void 0!==c&&"string"==typeof c&&(n=c)}var d=function e(n,s,c,d,p){for(var f,h,m,b,_,w=0,S=0,E=0,k=0,A=0,B=0,F=m=f=0,z=0,L=0,j=0,M=0,D=c.length,H=D-1,U="",q="",V="",W="";z<D;){if(h=c.charCodeAt(z),z===H&&0!==S+k+E+w&&(0!==S&&(h=47===S?10:47),k=E=w=0,D++,H++),0===S+k+E+w){if(z===H&&(0<L&&(U=U.replace(u,"")),0<U.trim().length)){switch(h){case 32:case 9:case 59:case 13:case 10:break;default:U+=c.charAt(z)}h=59}switch(h){case 123:for(f=(U=U.trim()).charCodeAt(0),m=1,M=++z;z<D;){switch(h=c.charCodeAt(z)){case 123:m++;break;case 125:m--;break;case 47:switch(h=c.charCodeAt(z+1)){case 42:case 47:e:{for(F=z+1;F<H;++F)switch(c.charCodeAt(F)){case 47:if(42===h&&42===c.charCodeAt(F-1)&&z+2!==F){z=F+1;break e}break;case 10:if(47===h){z=F+1;break e}}z=F}}break;case 91:h++;case 40:h++;case 34:case 39:for(;z++<H&&c.charCodeAt(z)!==h;);}if(0===m)break;z++}switch(m=c.substring(M,z),0===f&&(f=(U=U.replace(l,"").trim()).charCodeAt(0)),f){case 64:switch(0<L&&(U=U.replace(u,"")),h=U.charCodeAt(1)){case 100:case 109:case 115:case 45:L=s;break;default:L=O}if(M=(m=e(s,L,m,h,p+1)).length,0<P&&(_=a(3,m,L=t(O,U,j),s,T,C,M,h,p,d),U=L.join(""),void 0!==_&&0===(M=(m=_.trim()).length)&&(h=0,m="")),0<M)switch(h){case 115:U=U.replace(x,i);case 100:case 109:case 45:m=U+"{"+m+"}";break;case 107:m=(U=U.replace(g,"$1 $2"))+"{"+m+"}",m=1===I||2===I&&o("@"+m,3)?"@-webkit-"+m+"@"+m:"@"+m;break;default:m=U+m,112===d&&(q+=m,m="")}else m="";break;default:m=e(s,t(s,U,j),m,d,p+1)}V+=m,m=j=L=F=f=0,U="",h=c.charCodeAt(++z);break;case 125:case 59:if(1<(M=(U=(0<L?U.replace(u,""):U).trim()).length))switch(0===F&&(f=U.charCodeAt(0),45===f||96<f&&123>f)&&(M=(U=U.replace(" ",":")).length),0<P&&void 0!==(_=a(1,U,s,n,T,C,q.length,d,p,d))&&0===(M=(U=_.trim()).length)&&(U="\0\0"),f=U.charCodeAt(0),h=U.charCodeAt(1),f){case 0:break;case 64:if(105===h||99===h){W+=U+c.charAt(z);break}default:58!==U.charCodeAt(M-1)&&(q+=r(U,f,h,U.charCodeAt(2)))}j=L=F=f=0,U="",h=c.charCodeAt(++z)}}switch(h){case 13:case 10:47===S?S=0:0===1+f&&107!==d&&0<U.length&&(L=1,U+="\0"),0<P*R&&a(0,U,s,n,T,C,q.length,d,p,d),C=1,T++;break;case 59:case 125:if(0===S+k+E+w){C++;break}default:switch(C++,b=c.charAt(z),h){case 9:case 32:if(0===k+w+S)switch(A){case 44:case 58:case 9:case 32:b="";break;default:32!==h&&(b=" ")}break;case 0:b="\\0";break;case 12:b="\\f";break;case 11:b="\\v";break;case 38:0===k+S+w&&(L=j=1,b="\f"+b);break;case 108:if(0===k+S+w+N&&0<F)switch(z-F){case 2:112===A&&58===c.charCodeAt(z-3)&&(N=A);case 8:111===B&&(N=B)}break;case 58:0===k+S+w&&(F=z);break;case 44:0===S+E+k+w&&(L=1,b+="\r");break;case 34:case 39:0===S&&(k=k===h?0:0===k?h:k);break;case 91:0===k+S+E&&w++;break;case 93:0===k+S+E&&w--;break;case 41:0===k+S+w&&E--;break;case 40:if(0===k+S+w){if(0===f)switch(2*A+3*B){case 533:break;default:f=1}E++}break;case 64:0===S+E+k+w+F+m&&(m=1);break;case 42:case 47:if(!(0<k+w+E))switch(S){case 0:switch(2*h+3*c.charCodeAt(z+1)){case 235:S=47;break;case 220:M=z,S=42}break;case 42:47===h&&42===A&&M+2!==z&&(33===c.charCodeAt(M+2)&&(q+=c.substring(M,z+1)),b="",S=0)}}0===S&&(U+=b)}B=A,A=h,z++}if(0<(M=q.length)){if(L=s,0<P&&void 0!==(_=a(2,q,L,n,T,C,M,d,p,d))&&0===(q=_).length)return W+q+V;if(q=L.join(",")+"{"+q+"}",0!=I*N){switch(2!==I||o(q,2)||(N=0),N){case 111:q=q.replace(y,":-moz-$1")+q;break;case 112:q=q.replace(v,"::-webkit-input-$1")+q.replace(v,"::-moz-$1")+q.replace(v,":-ms-input-$1")+q}N=0}}return W+q+V}(O,s,n,0,0);return 0<P&&void 0!==(c=a(-2,d,s,s,T,C,d.length,0,0,0))&&(d=c),N=0,C=T=1,d}var l=/^\0+/g,u=/[\0\r\f]/g,d=/: */g,p=/zoo|gra/,f=/([,: ])(transform)/g,h=/,\r+?/g,m=/([\t\r\n ])*\f?&/g,g=/@(k\w+)\s*(\S*)\s*/,v=/::(place)/g,y=/:(read-only)/g,b=/[svh]\w+-[tblr]{2}/,x=/\(\s*(.*)\s*\)/g,_=/([\s\S]*?);/g,w=/-self|flex-/g,S=/[^]*?(:[rp][el]a[\w-]+)[^]*/,E=/stretch|:\s*\w+\-(?:conte|avail)/,k=/([^-])(image-set\()/,C=1,T=1,N=0,I=1,O=[],A=[],P=0,B=null,R=0;return c.use=function e(t){switch(t){case void 0:case null:P=A.length=0;break;default:if("function"==typeof t)A[P++]=t;else if("object"==typeof t)for(var n=0,r=t.length;n<r;++n)e(t[n]);else R=0|!!t}return e},c.set=s,void 0!==e&&s(e),c}_a.AsyncMode=Oa,_a.ConcurrentMode=Aa,_a.ContextConsumer=Ia,_a.ContextProvider=Na,_a.Element=Sa,_a.ForwardRef=Pa,_a.Fragment=ka,_a.Lazy=za,_a.Memo=Fa,_a.Portal=Ea,_a.Profiler=Ta,_a.StrictMode=Ca,_a.Suspense=Ba,_a.isAsyncMode=function(e){return Ua(e)||Ha(e)===Oa},_a.isConcurrentMode=Ua,_a.isContextConsumer=function(e){return Ha(e)===Ia},_a.isContextProvider=function(e){return Ha(e)===Na},_a.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===Sa},_a.isForwardRef=function(e){return Ha(e)===Pa},_a.isFragment=function(e){return Ha(e)===ka},_a.isLazy=function(e){return Ha(e)===za},_a.isMemo=function(e){return Ha(e)===Fa},_a.isPortal=function(e){return Ha(e)===Ea},_a.isProfiler=function(e){return Ha(e)===Ta},_a.isStrictMode=function(e){return Ha(e)===Ca},_a.isSuspense=function(e){return Ha(e)===Ba},_a.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===ka||e===Aa||e===Ta||e===Ca||e===Ba||e===Ra||"object"==typeof e&&null!==e&&(e.$$typeof===za||e.$$typeof===Fa||e.$$typeof===Na||e.$$typeof===Ia||e.$$typeof===Pa||e.$$typeof===ja||e.$$typeof===Ma||e.$$typeof===Da||e.$$typeof===La)},_a.typeOf=Ha,xa.exports=_a;var Va={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Wa=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,$a=function(e){var t={};return function(e){return void 0===t[e]&&(t[e]=(n=e,Wa.test(n)||111===n.charCodeAt(0)&&110===n.charCodeAt(1)&&n.charCodeAt(2)<91)),t[e];var n}}(),Ya=xa.exports,Ga={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},Xa={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},Ja={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Ka={};function Za(e){return Ya.isMemo(e)?Ja:Ka[e.$$typeof]||Ga}Ka[Ya.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Ka[Ya.Memo]=Ja;var Qa=Object.defineProperty,es=Object.getOwnPropertyNames,ts=Object.getOwnPropertySymbols,ns=Object.getOwnPropertyDescriptor,rs=Object.getPrototypeOf,os=Object.prototype;function is(){return(is=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}var as=function(e,t){for(var n=[e[0]],r=0,o=t.length;r<o;r+=1)n.push(t[r],e[r+1]);return n},ss=function(e){return null!==e&&"object"==typeof e&&"[object Object]"===(e.toString?e.toString():Object.prototype.toString.call(e))&&!xa.exports.typeOf(e)},cs=Object.freeze([]),ls=Object.freeze({});function us(e){return"function"==typeof e}function ds(e){return e.displayName||e.name||"Component"}function ps(e){return e&&"string"==typeof e.styledComponentId}var fs="undefined"!=typeof process&&(process.env.REACT_APP_SC_ATTR||process.env.SC_ATTR)||"data-styled",hs="undefined"!=typeof window&&"HTMLElement"in window,ms=Boolean("boolean"==typeof SC_DISABLE_SPEEDY?SC_DISABLE_SPEEDY:"undefined"!=typeof process&&void 0!==process.env.REACT_APP_SC_DISABLE_SPEEDY&&""!==process.env.REACT_APP_SC_DISABLE_SPEEDY?"false"!==process.env.REACT_APP_SC_DISABLE_SPEEDY&&process.env.REACT_APP_SC_DISABLE_SPEEDY:"undefined"!=typeof process&&void 0!==process.env.SC_DISABLE_SPEEDY&&""!==process.env.SC_DISABLE_SPEEDY&&"false"!==process.env.SC_DISABLE_SPEEDY&&process.env.SC_DISABLE_SPEEDY),gs={};function vs(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];throw new Error("An error occurred. See https://git.io/JUIaE#"+e+" for more information."+(n.length>0?" Args: "+n.join(", "):""))}var ys=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}var t=e.prototype;return t.indexOfGroup=function(e){for(var t=0,n=0;n<e;n++)t+=this.groupSizes[n];return t},t.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var n=this.groupSizes,r=n.length,o=r;e>=o;)(o<<=1)<0&&vs(16,""+e);this.groupSizes=new Uint32Array(o),this.groupSizes.set(n),this.length=o;for(var i=r;i<o;i++)this.groupSizes[i]=0}for(var a=this.indexOfGroup(e+1),s=0,c=t.length;s<c;s++)this.tag.insertRule(a,t[s])&&(this.groupSizes[e]++,a++)},t.clearGroup=function(e){if(e<this.length){var t=this.groupSizes[e],n=this.indexOfGroup(e),r=n+t;this.groupSizes[e]=0;for(var o=n;o<r;o++)this.tag.deleteRule(n)}},t.getGroup=function(e){var t="";if(e>=this.length||0===this.groupSizes[e])return t;for(var n=this.groupSizes[e],r=this.indexOfGroup(e),o=r+n,i=r;i<o;i++)t+=this.tag.getRule(i)+"/*!sc*/\n";return t},e}(),bs=new Map,xs=new Map,_s=1,ws=function(e){if(bs.has(e))return bs.get(e);for(;xs.has(_s);)_s++;var t=_s++;return bs.set(e,t),xs.set(t,e),t},Ss=function(e){return xs.get(e)},Es=function(e,t){bs.set(e,t),xs.set(t,e)},ks="style["+fs+'][data-styled-version="5.3.0"]',Cs=new RegExp("^"+fs+'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)'),Ts=function(e,t,n){for(var r,o=n.split(","),i=0,a=o.length;i<a;i++)(r=o[i])&&e.registerName(t,r)},Ns=function(e,t){for(var n=t.innerHTML.split("/*!sc*/\n"),r=[],o=0,i=n.length;o<i;o++){var a=n[o].trim();if(a){var s=a.match(Cs);if(s){var c=0|parseInt(s[1],10),l=s[2];0!==c&&(Es(l,c),Ts(e,l,s[3]),e.getTag().insertRules(c,r)),r.length=0}else r.push(a)}}},Is=function(e){var t=document.head,n=e||t,r=document.createElement("style"),o=function(e){for(var t=e.childNodes,n=t.length;n>=0;n--){var r=t[n];if(r&&1===r.nodeType&&r.hasAttribute(fs))return r}}(n),i=void 0!==o?o.nextSibling:null;r.setAttribute(fs,"active"),r.setAttribute("data-styled-version","5.3.0");var a="undefined"!=typeof window&&void 0!==window.__webpack_nonce__?window.__webpack_nonce__:null;return a&&r.setAttribute("nonce",a),n.insertBefore(r,i),r},Os=function(){function e(e){var t=this.element=Is(e);t.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,n=0,r=t.length;n<r;n++){var o=t[n];if(o.ownerNode===e)return o}vs(17)}(t),this.length=0}var t=e.prototype;return t.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch(e){return!1}},t.deleteRule=function(e){this.sheet.deleteRule(e),this.length--},t.getRule=function(e){var t=this.sheet.cssRules[e];return void 0!==t&&"string"==typeof t.cssText?t.cssText:""},e}(),As=function(){function e(e){var t=this.element=Is(e);this.nodes=t.childNodes,this.length=0}var t=e.prototype;return t.insertRule=function(e,t){if(e<=this.length&&e>=0){var n=document.createTextNode(t),r=this.nodes[e];return this.element.insertBefore(n,r||null),this.length++,!0}return!1},t.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},t.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},e}(),Ps=function(){function e(e){this.rules=[],this.length=0}var t=e.prototype;return t.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,!0)},t.deleteRule=function(e){this.rules.splice(e,1),this.length--},t.getRule=function(e){return e<this.length?this.rules[e]:""},e}(),Bs=hs,Rs={isServer:!hs,useCSSOMInjection:!ms},Fs=function(){function e(e,t,n){void 0===e&&(e=ls),void 0===t&&(t={}),this.options=is({},Rs,{},e),this.gs=t,this.names=new Map(n),!this.options.isServer&&hs&&Bs&&(Bs=!1,function(e){for(var t=document.querySelectorAll(ks),n=0,r=t.length;n<r;n++){var o=t[n];o&&"active"!==o.getAttribute(fs)&&(Ns(e,o),o.parentNode&&o.parentNode.removeChild(o))}}(this))}e.registerId=function(e){return ws(e)};var t=e.prototype;return t.reconstructWithOptions=function(t,n){return void 0===n&&(n=!0),new e(is({},this.options,{},t),this.gs,n&&this.names||void 0)},t.allocateGSInstance=function(e){return this.gs[e]=(this.gs[e]||0)+1},t.getTag=function(){return this.tag||(this.tag=(n=(t=this.options).isServer,r=t.useCSSOMInjection,o=t.target,e=n?new Ps(o):r?new Os(o):new As(o),new ys(e)));var e,t,n,r,o},t.hasNameForId=function(e,t){return this.names.has(e)&&this.names.get(e).has(t)},t.registerName=function(e,t){if(ws(e),this.names.has(e))this.names.get(e).add(t);else{var n=new Set;n.add(t),this.names.set(e,n)}},t.insertRules=function(e,t,n){this.registerName(e,t),this.getTag().insertRules(ws(e),n)},t.clearNames=function(e){this.names.has(e)&&this.names.get(e).clear()},t.clearRules=function(e){this.getTag().clearGroup(ws(e)),this.clearNames(e)},t.clearTag=function(){this.tag=void 0},t.toString=function(){return function(e){for(var t=e.getTag(),n=t.length,r="",o=0;o<n;o++){var i=Ss(o);if(void 0!==i){var a=e.names.get(i),s=t.getGroup(o);if(void 0!==a&&0!==s.length){var c=fs+".g"+o+'[id="'+i+'"]',l="";void 0!==a&&a.forEach((function(e){e.length>0&&(l+=e+",")})),r+=""+s+c+'{content:"'+l+'"}/*!sc*/\n'}}}return r}(this)},e}(),zs=/(a)(d)/gi,Ls=function(e){return String.fromCharCode(e+(e>25?39:97))};function js(e){var t,n="";for(t=Math.abs(e);t>52;t=t/52|0)n=Ls(t%52)+n;return(Ls(t%52)+n).replace(zs,"$1-$2")}var Ms=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},Ds=function(e){return Ms(5381,e)};function Hs(e){for(var t=0;t<e.length;t+=1){var n=e[t];if(us(n)&&!ps(n))return!1}return!0}var Us=Ds("5.3.0"),qs=function(){function e(e,t,n){this.rules=e,this.staticRulesId="",this.isStatic=(void 0===n||n.isStatic)&&Hs(e),this.componentId=t,this.baseHash=Ms(Us,t),this.baseStyle=n,Fs.registerId(t)}return e.prototype.generateAndInjectStyles=function(e,t,n){var r=this.componentId,o=[];if(this.baseStyle&&o.push(this.baseStyle.generateAndInjectStyles(e,t,n)),this.isStatic&&!n.hash)if(this.staticRulesId&&t.hasNameForId(r,this.staticRulesId))o.push(this.staticRulesId);else{var i=sc(this.rules,e,t,n).join(""),a=js(Ms(this.baseHash,i.length)>>>0);if(!t.hasNameForId(r,a)){var s=n(i,"."+a,void 0,r);t.insertRules(r,a,s)}o.push(a),this.staticRulesId=a}else{for(var c=this.rules.length,l=Ms(this.baseHash,n.hash),u="",d=0;d<c;d++){var p=this.rules[d];if("string"==typeof p)u+=p;else if(p){var f=sc(p,e,t,n),h=Array.isArray(f)?f.join(""):f;l=Ms(l,h+d),u+=h}}if(u){var m=js(l>>>0);if(!t.hasNameForId(r,m)){var g=n(u,"."+m,void 0,r);t.insertRules(r,m,g)}o.push(m)}}return o.join(" ")},e}(),Vs=/^\s*\/\/.*$/gm,Ws=[":","[",".","#"];function $s(e){var t,n,r,o,i=void 0===e?ls:e,a=i.options,s=void 0===a?ls:a,c=i.plugins,l=void 0===c?cs:c,u=new qa(s),d=[],p=function(e){function t(t){if(t)try{e(t+"}")}catch(e){}}return function(n,r,o,i,a,s,c,l,u,d){switch(n){case 1:if(0===u&&64===r.charCodeAt(0))return e(r+";"),"";break;case 2:if(0===l)return r+"/*|*/";break;case 3:switch(l){case 102:case 112:return e(o[0]+r),"";default:return r+(0===d?"/*|*/":"")}case-2:r.split("/*|*/}").forEach(t)}}}((function(e){d.push(e)})),f=function(e,r,i){return 0===r&&-1!==Ws.indexOf(i[n.length])||i.match(o)?e:"."+t};function h(e,i,a,s){void 0===s&&(s="&");var c=e.replace(Vs,""),l=i&&a?a+" "+i+" { "+c+" }":c;return t=s,n=i,r=new RegExp("\\"+n+"\\b","g"),o=new RegExp("(\\"+n+"\\b){2,}"),u(a||!i?"":i,l)}return u.use([].concat(l,[function(e,t,o){2===e&&o.length&&o[0].lastIndexOf(n)>0&&(o[0]=o[0].replace(r,f))},p,function(e){if(-2===e){var t=d;return d=[],t}}])),h.hash=l.length?l.reduce((function(e,t){return t.name||vs(15),Ms(e,t.name)}),5381).toString():"",h}var Ys=t.createContext(),Gs=t.createContext(),Xs=new Fs,Js=$s();function Ks(){return i(Ys)||Xs}function Zs(){return i(Gs)||Js}function Qs(e){var n=r(e.stylisPlugins),i=n[0],s=n[1],c=Ks(),l=o((function(){var t=c;return e.sheet?t=e.sheet:e.target&&(t=t.reconstructWithOptions({target:e.target},!1)),e.disableCSSOMInjection&&(t=t.reconstructWithOptions({useCSSOMInjection:!1})),t}),[e.disableCSSOMInjection,e.sheet,e.target]),u=o((function(){return $s({options:{prefix:!e.disableVendorPrefixes},plugins:i})}),[e.disableVendorPrefixes,i]);return a((function(){(function(e,t,n,r){var o=void 0;if(void 0!==o)return!!o;if(e===t)return!0;if("object"!=typeof e||!e||"object"!=typeof t||!t)return!1;var i=Object.keys(e),a=Object.keys(t);if(i.length!==a.length)return!1;for(var s=Object.prototype.hasOwnProperty.bind(t),c=0;c<i.length;c++){var l=i[c];if(!s(l))return!1;var u=e[l],d=t[l];if(!1===(o=void 0)||void 0===o&&u!==d)return!1}return!0})(i,e.stylisPlugins)||s(e.stylisPlugins)}),[e.stylisPlugins]),t.createElement(Ys.Provider,{value:l},t.createElement(Gs.Provider,{value:u},e.children))}var ec=function(){function e(e,t){var n=this;this.inject=function(e,t){void 0===t&&(t=Js);var r=n.name+t.hash;e.hasNameForId(n.id,r)||e.insertRules(n.id,r,t(n.rules,r,"@keyframes"))},this.toString=function(){return vs(12,String(n.name))},this.name=e,this.id="sc-keyframes-"+e,this.rules=t}return e.prototype.getName=function(e){return void 0===e&&(e=Js),this.name+e.hash},e}(),tc=/([A-Z])/,nc=/([A-Z])/g,rc=/^ms-/,oc=function(e){return"-"+e.toLowerCase()};function ic(e){return tc.test(e)?e.replace(nc,oc).replace(rc,"-ms-"):e}var ac=function(e){return null==e||!1===e||""===e};function sc(e,t,n,r){if(Array.isArray(e)){for(var o,i=[],a=0,s=e.length;a<s;a+=1)""!==(o=sc(e[a],t,n,r))&&(Array.isArray(o)?i.push.apply(i,o):i.push(o));return i}return ac(e)?"":ps(e)?"."+e.styledComponentId:us(e)?"function"!=typeof(c=e)||c.prototype&&c.prototype.isReactComponent||!t?e:sc(e(t),t,n,r):e instanceof ec?n?(e.inject(n,r),e.getName(r)):e:ss(e)?function e(t,n){var r,o,i=[];for(var a in t)t.hasOwnProperty(a)&&!ac(t[a])&&(ss(t[a])?i.push.apply(i,e(t[a],a)):us(t[a])?i.push(ic(a)+":",t[a],";"):i.push(ic(a)+": "+(r=a,null==(o=t[a])||"boolean"==typeof o||""===o?"":"number"!=typeof o||0===o||r in Va?String(o).trim():o+"px")+";"));return n?[n+" {"].concat(i,["}"]):i}(e):e.toString();var c}function cc(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return us(e)||ss(e)?sc(as(cs,[e].concat(n))):0===n.length&&1===e.length&&"string"==typeof e[0]?e:sc(as(e,n))}var lc=function(e,t,n){return void 0===n&&(n=ls),e.theme!==n.theme&&e.theme||t||n.theme},uc=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,dc=/(^-|-$)/g;function pc(e){return e.replace(uc,"-").replace(dc,"")}var fc=function(e){return js(Ds(e)>>>0)};function hc(e){return"string"==typeof e&&!0}var mc=function(e){return"function"==typeof e||"object"==typeof e&&null!==e&&!Array.isArray(e)},gc=function(e){return"__proto__"!==e&&"constructor"!==e&&"prototype"!==e};function vc(e,t,n){var r=e[n];mc(t)&&mc(r)?yc(r,t):e[n]=t}function yc(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];for(var o=0,i=n;o<i.length;o++){var a=i[o];if(mc(a))for(var s in a)gc(s)&&vc(e,a[s],s)}return e}var bc=t.createContext(),xc={};function _c(e,n,r){var o=ps(e),a=!hc(e),s=n.attrs,l=void 0===s?cs:s,u=n.componentId,d=void 0===u?function(e,t){var n="string"!=typeof e?"sc":pc(e);xc[n]=(xc[n]||0)+1;var r=n+"-"+fc("5.3.0"+n+xc[n]);return t?t+"-"+r:r}(n.displayName,n.parentComponentId):u,p=n.displayName,f=void 0===p?function(e){return hc(e)?"styled."+e:"Styled("+ds(e)+")"}(e):p,h=n.displayName&&n.componentId?pc(n.displayName)+"-"+n.componentId:n.componentId||d,m=o&&e.attrs?Array.prototype.concat(e.attrs,l).filter(Boolean):l,g=n.shouldForwardProp;o&&e.shouldForwardProp&&(g=n.shouldForwardProp?function(t,r,o){return e.shouldForwardProp(t,r,o)&&n.shouldForwardProp(t,r,o)}:e.shouldForwardProp);var v,y=new qs(r,h,o?e.componentStyle:void 0),b=y.isStatic&&0===l.length,x=function(e,t){return function(e,t,n,r){var o=e.attrs,a=e.componentStyle,s=e.defaultProps,l=e.foldedComponentIds,u=e.shouldForwardProp,d=e.styledComponentId,p=e.target,f=function(e,t,n){void 0===e&&(e=ls);var r=is({},t,{theme:e}),o={};return n.forEach((function(e){var t,n,i,a=e;for(t in us(a)&&(a=a(r)),a)r[t]=o[t]="className"===t?(n=o[t],i=a[t],n&&i?n+" "+i:n||i):a[t]})),[r,o]}(lc(t,i(bc),s)||ls,t,o),h=f[0],m=f[1],g=function(e,t,n,r){var o=Ks(),i=Zs();return t?e.generateAndInjectStyles(ls,o,i):e.generateAndInjectStyles(n,o,i)}(a,r,h),v=n,y=m.$as||t.$as||m.as||t.as||p,b=hc(y),x=m!==t?is({},t,{},m):t,_={};for(var w in x)"$"!==w[0]&&"as"!==w&&("forwardedAs"===w?_.as=x[w]:(u?u(w,$a,y):!b||$a(w))&&(_[w]=x[w]));return t.style&&m.style!==t.style&&(_.style=is({},t.style,{},m.style)),_.className=Array.prototype.concat(l,d,g!==d?g:null,t.className,m.className).filter(Boolean).join(" "),_.ref=v,c(y,_)}(v,e,t,b)};return x.displayName=f,(v=t.forwardRef(x)).attrs=m,v.componentStyle=y,v.displayName=f,v.shouldForwardProp=g,v.foldedComponentIds=o?Array.prototype.concat(e.foldedComponentIds,e.styledComponentId):cs,v.styledComponentId=h,v.target=o?e.target:e,v.withComponent=function(e){var t=n.componentId,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(n,["componentId"]),i=t&&t+"-"+(hc(e)?e:pc(ds(e)));return _c(e,is({},o,{attrs:m,componentId:i}),r)},Object.defineProperty(v,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(t){this._foldedDefaultProps=o?yc({},e.defaultProps,t):t}}),v.toString=function(){return"."+v.styledComponentId},a&&function e(t,n,r){if("string"!=typeof n){if(os){var o=rs(n);o&&o!==os&&e(t,o,r)}var i=es(n);ts&&(i=i.concat(ts(n)));for(var a=Za(t),s=Za(n),c=0;c<i.length;++c){var l=i[c];if(!(Xa[l]||r&&r[l]||s&&s[l]||a&&a[l])){var u=ns(n,l);try{Qa(t,l,u)}catch(e){}}}}return t}(v,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0,withComponent:!0}),v}var wc=function(e){return function e(t,n,r){if(void 0===r&&(r=ls),!xa.exports.isValidElementType(n))return vs(1,String(n));var o=function(){return t(n,r,cc.apply(void 0,arguments))};return o.withConfig=function(o){return e(t,n,is({},r,{},o))},o.attrs=function(o){return e(t,n,is({},r,{attrs:Array.prototype.concat(r.attrs,o).filter(Boolean)}))},o}(_c,e)};["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","textPath","tspan"].forEach((function(e){wc[e]=wc(e)}));var Sc=function(){function e(e,t){this.rules=e,this.componentId=t,this.isStatic=Hs(e),Fs.registerId(this.componentId+1)}var t=e.prototype;return t.createStyles=function(e,t,n,r){var o=r(sc(this.rules,t,n,r).join(""),""),i=this.componentId+e;n.insertRules(i,i,o)},t.removeStyles=function(e,t){t.clearRules(this.componentId+e)},t.renderStyles=function(e,t,n,r){e>2&&Fs.registerId(this.componentId+e),this.removeStyles(e,n),this.createStyles(e,t,n,r)},e}();function Ec(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];var a=cc.apply(void 0,[e].concat(r)),s="sc-global-"+fc(JSON.stringify(a)),c=new Sc(a,s);function d(e){var t=Ks(),n=Zs(),r=i(bc),o=l(t.allocateGSInstance(s)).current;return u((function(){return p(o,e,t,r,n),function(){return c.removeStyles(o,t)}}),[o,e,t,r,n]),null}function p(e,t,n,r,o){if(c.isStatic)c.renderStyles(e,gs,n,o);else{var i=is({},t,{theme:lc(t,r,d.defaultProps)});c.renderStyles(e,i,n,o)}}return t.memo(d)}function kc(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=cc.apply(void 0,[e].concat(n)).join(""),i=fc(o);return new ec(i,o)}let Cc=new Map,Tc=new Set;function Nc(){if("undefined"==typeof window)return;let e=t=>{let n=Cc.get(t.target);if(n&&(n.delete(t.propertyName),0===n.size&&(t.target.removeEventListener("transitioncancel",e),Cc.delete(t.target)),0===Cc.size)){for(let e of Tc)e();Tc.clear()}};document.body.addEventListener("transitionrun",t=>{let n=Cc.get(t.target);n||(n=new Set,Cc.set(t.target,n),t.target.addEventListener("transitioncancel",e)),n.add(t.propertyName)}),document.body.addEventListener("transitionend",e)}"undefined"!=typeof document&&("loading"!==document.readyState?Nc():document.addEventListener("DOMContentLoaded",Nc)),t.createContext(null).displayName="PressResponderContext";let Ic=null,Oc=new Set,Ac=!1,Pc=!1;const Bc={Tab:!0,Escape:!0};function Rc(e,t){for(let n of Oc)n(e,t)}function Fc(e){Pc=!0,function(e){return!(e.metaKey||("undefined"==typeof window||null==window.navigator||!/^Mac/.test(window.navigator.platform))&&e.altKey||e.ctrlKey)}(e)&&(Ic="keyboard",Rc("keyboard",e))}function zc(e){Ic="pointer","mousedown"!==e.type&&"pointerdown"!==e.type||(Pc=!0,Rc("pointer",e))}function Lc(e){var t;(0===(t=e).mozInputSource&&t.isTrusted||0===t.detail&&!t.pointerType)&&(Pc=!0,Ic="virtual")}function jc(e){e.target!==window&&e.target!==document&&(Pc||(Ic="virtual",Rc("virtual",e)),Pc=!1)}function Mc(){Pc=!1}function Dc(){if("undefined"==typeof window||Ac)return;let e=HTMLElement.prototype.focus;HTMLElement.prototype.focus=function(){Pc=!0,e.apply(this,arguments)},document.addEventListener("keydown",Fc,!0),document.addEventListener("keyup",Fc,!0),document.addEventListener("click",Lc,!0),window.addEventListener("focus",jc,!0),window.addEventListener("blur",Mc,!1),"undefined"!=typeof PointerEvent?(document.addEventListener("pointerdown",zc,!0),document.addEventListener("pointermove",zc,!0),document.addEventListener("pointerup",zc,!0)):(document.addEventListener("mousedown",zc,!0),document.addEventListener("mousemove",zc,!0),document.addEventListener("mouseup",zc,!0)),Ac=!0}function Hc(){return"pointer"!==Ic}function Uc(e){void 0===e&&(e={}),Dc();let{isTextInput:t,autoFocus:n}=e,[o,i]=r(n||Hc());return a(()=>{let e=(e,n)=>{t&&"keyboard"===e&&n instanceof KeyboardEvent&&!Bc[n.key]||i(Hc())};return Oc.add(e),()=>{Oc.delete(e)}},[t]),{isFocusVisible:o}}"undefined"!=typeof document&&("loading"!==document.readyState?Dc():document.addEventListener("DOMContentLoaded",Dc));var qc={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},Vc=e.createContext&&e.createContext(qc),Wc=function(){return(Wc=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function $c(t){return function(n){return e.createElement(Yc,Wc({attr:Wc({},t.attr)},n),function t(n){return n&&n.map((function(n,r){return e.createElement(n.tag,Wc({key:r},n.attr),t(n.child))}))}(t.child))}}function Yc(t){var n=function(n){var r,o=t.size||n.size||"1em";n.className&&(r=n.className),t.className&&(r=(r?r+" ":"")+t.className);var i=t.attr,a=t.title,s=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&(n[r[o]]=e[r[o]])}return n}(t,["attr","title"]);return e.createElement("svg",Wc({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,i,s,{className:r,style:Wc({color:t.color||n.color},n.style,t.style),height:o,width:o,xmlns:"http://www.w3.org/2000/svg"}),a&&e.createElement("title",null,a),t.children)};return void 0!==Vc?e.createElement(Vc.Consumer,null,(function(e){return n(e)})):n(qc)}var Gc=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M19 12h-2v3h-3v2h5v-5zM7 9h3V7H5v5h2V9zm14-6H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02z"}}]})(e)};Gc.displayName="MdAspectRatio";var Xc=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M10.09 15.59L11.5 17l5-5-5-5-1.41 1.41L12.67 11H3v2h9.67l-2.58 2.59zM19 3H5c-1.11 0-2 .9-2 2v4h2V5h14v14H5v-4H3v4c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"}}]})(e)};Xc.displayName="MdExitToApp";var Jc=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M17.63 5.84C17.27 5.33 16.67 5 16 5L5 5.01C3.9 5.01 3 5.9 3 7v10c0 1.1.9 1.99 2 1.99L16 19c.67 0 1.27-.33 1.63-.84L22 12l-4.37-6.16z"}}]})(e)};Jc.displayName="MdLabel";var Kc=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M19 19H5V5h7V3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"}}]})(e)};Kc.displayName="MdOpenInNew";var Zc=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"}}]})(e)};Zc.displayName="MdSearch";var Qc=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M17 10.5V7c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h12c.55 0 1-.45 1-1v-3.5l4 4v-11l-4 4z"}}]})(e)};Qc.displayName="MdVideocam";var el=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3 9v6h4l5 5V4L7 9H3zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02zM14 3.23v2.06c2.89.86 5 3.54 5 6.71s-2.11 5.85-5 6.71v2.06c4.01-.91 7-4.49 7-8.77s-2.99-7.86-7-8.77z"}}]})(e)};el.displayName="MdVolumeUp";var tl=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3 18h6v-2H3v2zM3 6v2h18V6H3zm0 7h12v-2H3v2z"}}]})(e)};tl.displayName="MdSort";var nl=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M6 2c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6H6zm7 7V3.5L18.5 9H13z"}}]})(e)};nl.displayName="MdInsertDriveFile";var rl=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"}}]})(e)};rl.displayName="MdInsertPhoto";var ol=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"circle",attr:{cx:"12",cy:"12",r:"3.2"}},{tag:"path",attr:{d:"M9 2L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3.17L15 2H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5z"}}]})(e)};ol.displayName="MdPhotoCamera";var il=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M22 16V4c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2zm-11-4l2.03 2.71L16 11l4 5H8l3-4zM2 6v14c0 1.1.9 2 2 2h14v-2H4V6H2z"}}]})(e)};il.displayName="MdPhotoLibrary";var al=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3 17v2h6v-2H3zM3 5v2h10V5H3zm10 16v-2h8v-2h-8v-2h-2v6h2zM7 9v2H3v2h4v2h2V9H7zm14 4v-2H11v2h10zm-6-4h2V7h4V5h-4V3h-2v6z"}}]})(e)};al.displayName="MdTune";var sl=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M7 10l5 5 5-5z"}}]})(e)};sl.displayName="MdArrowDropDown";var cl=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"}}]})(e)};cl.displayName="MdCancel";var ll=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}}]})(e)};ll.displayName="MdCheck";var ul=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"}}]})(e)};ul.displayName="MdChevronLeft";var dl=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}}]})(e)};dl.displayName="MdChevronRight";var pl,fl=function(e){return $c({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}}]})(e)};fl.displayName="MdClose",function(e){e[e.ENTERING=0]="ENTERING",e[e.LEAVING=1]="LEAVING",e[e.IDLE=2]="IDLE"}(pl||(pl={}));var hl={exports:{}};
22
+ /*!
23
+ Copyright (c) 2018 Jed Watson.
24
+ Licensed under the MIT License (MIT), see
25
+ http://jedwatson.github.io/classnames
26
+ */!function(e){!function(){var t={}.hasOwnProperty;function n(){for(var e=[],r=0;r<arguments.length;r++){var o=arguments[r];if(o){var i=typeof o;if("string"===i||"number"===i)e.push(o);else if(Array.isArray(o)){if(o.length){var a=n.apply(null,o);a&&e.push(a)}}else if("object"===i)if(o.toString===Object.prototype.toString)for(var s in o)t.call(o,s)&&o[s]&&e.push(s);else e.push(o.toString())}}return e.join(" ")}e.exports?(n.default=n,e.exports=n):window.classNames=n}()}(hl);var ml=hl.exports,gl=!1;if("undefined"!=typeof window){var vl={get passive(){gl=!0}};window.addEventListener("testPassive",null,vl),window.removeEventListener("testPassive",null,vl)}var yl="undefined"!=typeof window&&window.navigator&&window.navigator.platform&&(/iP(ad|hone|od)/.test(window.navigator.platform)||"MacIntel"===window.navigator.platform&&window.navigator.maxTouchPoints>1),bl=[],xl=!1,_l=-1,wl=void 0,Sl=void 0,El=function(e){return bl.some((function(t){return!(!t.options.allowTouchMove||!t.options.allowTouchMove(e))}))},kl=function(e){var t=e||window.event;return!!El(t.target)||t.touches.length>1||(t.preventDefault&&t.preventDefault(),!1)};function Cl(){return(Cl=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}var Tl=function(e){var n=e.classes,r=e.classNames,o=e.styles,i=e.id,a=e.closeIcon,s=e.onClick;return t.createElement("button",{id:i,className:ml(n.closeButton,null==r?void 0:r.closeButton),style:null==o?void 0:o.closeButton,onClick:s,"data-testid":"close-button"},a||t.createElement("svg",{className:null==r?void 0:r.closeIcon,style:null==o?void 0:o.closeIcon,width:28,height:28,viewBox:"0 0 36 36","data-testid":"close-icon"},t.createElement("path",{d:"M28.5 9.62L26.38 7.5 18 15.88 9.62 7.5 7.5 9.62 15.88 18 7.5 26.38l2.12 2.12L18 20.12l8.38 8.38 2.12-2.12L20.12 18z"})))},Nl="undefined"!=typeof window,Il=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'];function Ol(e){return null===e.offsetParent||"hidden"===getComputedStyle(e).visibility}function Al(e){if("INPUT"!==e.tagName||"radio"!==e.type||!e.name)return!0;var t=(e.form||e.ownerDocument).querySelectorAll('input[type="radio"][name="'+e.name+'"]'),n=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]}(t,e.form);return n===e||void 0===n&&t[0]===e}function Pl(e){for(var t=document.activeElement,n=e.querySelectorAll(Il.join(",")),r=[],o=0;o<n.length;o++){var i=n[o];(t===i||!i.disabled&&Bl(i)>-1&&!Ol(i)&&Al(i))&&r.push(i)}return r}function Bl(e){var t=parseInt(e.getAttribute("tabindex"),10);return isNaN(t)?function(e){return e.getAttribute("contentEditable")}(e)?0:e.tabIndex:t}var Rl=function(e){var t=e.container,n=e.initialFocusRef,r=l();return a((function(){var e=function(e){(null==t?void 0:t.current)&&function(e,t){if(e&&"Tab"===e.key){if(!t||!t.contains)return process,!1;if(!t.contains(e.target))return!1;var n=Pl(t),r=n[0],o=n[n.length-1];e.shiftKey&&e.target===r?(o.focus(),e.preventDefault()):!e.shiftKey&&e.target===o&&(r.focus(),e.preventDefault())}}(e,t.current)};if(Nl&&document.addEventListener("keydown",e),Nl&&(null==t?void 0:t.current)){var o=function(){-1!==Il.findIndex((function(e){var t;return null==(t=document.activeElement)?void 0:t.matches(e)}))&&(r.current=document.activeElement)};if(n)o(),requestAnimationFrame((function(){var e;null==(e=n.current)||e.focus()}));else{var i=Pl(t.current);i[0]&&(o(),i[0].focus())}}return function(){var t;Nl&&(document.removeEventListener("keydown",e),null==(t=r.current)||t.focus())}}),[t,n]),null},Fl=[],zl={root:"react-responsive-modal-root",overlay:"react-responsive-modal-overlay",overlayAnimationIn:"react-responsive-modal-overlay-in",overlayAnimationOut:"react-responsive-modal-overlay-out",modalContainer:"react-responsive-modal-container",modalContainerCenter:"react-responsive-modal-containerCenter",modal:"react-responsive-modal-modal",modalAnimationIn:"react-responsive-modal-modal-in",modalAnimationOut:"react-responsive-modal-modal-out",closeButton:"react-responsive-modal-closeButton"},Ll=t.forwardRef((function(e,n){var o,i,s,c,u=e.open,d=e.center,p=e.blockScroll,h=void 0===p||p,m=e.closeOnEsc,g=void 0===m||m,v=e.closeOnOverlayClick,y=void 0===v||v,b=e.container,x=e.showCloseIcon,_=void 0===x||x,w=e.closeIconId,S=e.closeIcon,E=e.focusTrapped,k=void 0===E||E,C=e.initialFocusRef,T=void 0===C?void 0:C,N=e.animationDuration,I=void 0===N?300:N,O=e.classNames,A=e.styles,P=e.role,B=void 0===P?"dialog":P,R=e.ariaDescribedby,F=e.ariaLabelledby,z=e.modalId,L=e.onClose,j=e.onEscKeyDown,M=e.onOverlayClick,D=e.onAnimationEnd,H=e.children,U=function(e){var n=function(e){void 0===e&&(e=null);var n=t.useState(e),r=n[0],o=n[1],i=t.useRef({current:r}).current;return Object.defineProperty(i,"current",{get:function(){return r},set:function(e){Object.is(r,e)||(r=e,o(e))}}),i}(null);return t.useEffect((function(){e&&("function"==typeof e?e(n.current):e.current=n.current)})),n}(n),q=l(null),V=l(null),W=l(null);null===W.current&&Nl&&(W.current=document.createElement("div"));var $=r(!1),Y=$[0],G=$[1];!function(e,t){a((function(){return t&&(n=e,Fl.push(n)),function(){var t;t=e,Fl=Fl.filter((function(e){return e!==t}))};var n}),[t,e])}(q,u),function(e,t,n,r){var o=l(null);a((function(){return t&&e.current&&r&&(o.current=e.current,function(e,t){if(e){if(!bl.some((function(t){return t.targetElement===e}))){var n={targetElement:e,options:t||{}};bl=[].concat(function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(bl),[n]),yl?(e.ontouchstart=function(e){1===e.targetTouches.length&&(_l=e.targetTouches[0].clientY)},e.ontouchmove=function(t){1===t.targetTouches.length&&function(e,t){var n=e.targetTouches[0].clientY-_l;!El(e.target)&&(t&&0===t.scrollTop&&n>0||function(e){return!!e&&e.scrollHeight-e.scrollTop<=e.clientHeight}(t)&&n<0?kl(e):e.stopPropagation())}(t,e)},xl||(document.addEventListener("touchmove",kl,gl?{passive:!1}:void 0),xl=!0)):function(e){if(void 0===Sl){var t=!!e&&!0===e.reserveScrollBarGap,n=window.innerWidth-document.documentElement.clientWidth;t&&n>0&&(Sl=document.body.style.paddingRight,document.body.style.paddingRight=n+"px")}void 0===wl&&(wl=document.body.style.overflow,document.body.style.overflow="hidden")}(t)}}else console.error("disableBodyScroll unsuccessful - targetElement must be provided when calling disableBodyScroll on IOS devices.")}(e.current)),function(){var e;o.current&&((e=o.current)?(bl=bl.filter((function(t){return t.targetElement!==e})),yl?(e.ontouchstart=null,e.ontouchmove=null,xl&&0===bl.length&&(document.removeEventListener("touchmove",kl,gl?{passive:!1}:void 0),xl=!1)):bl.length||(void 0!==Sl&&(document.body.style.paddingRight=Sl,Sl=void 0),void 0!==wl&&(document.body.style.overflow=wl,wl=void 0))):console.error("enableBodyScroll unsuccessful - targetElement must be provided when calling enableBodyScroll on IOS devices."),o.current=null)}}),[t,n,e])}(q,u,Y,h);var X=function(e){var t;27===e.keyCode&&(t=q,Fl.length&&Fl[Fl.length-1]===t)&&(null==j||j(e),g&&L())};a((function(){return function(){Y&&(W.current&&!b&&document.body.contains(W.current)&&document.body.removeChild(W.current),document.removeEventListener("keydown",X))}}),[Y]),a((function(){u&&!Y&&(G(!0),!W.current||b||document.body.contains(W.current)||document.body.appendChild(W.current),document.addEventListener("keydown",X))}),[u]);var J=function(){V.current=!1},K=b||W.current,Z=u?null!=(o=null==O?void 0:O.overlayAnimationIn)?o:zl.overlayAnimationIn:null!=(i=null==O?void 0:O.overlayAnimationOut)?i:zl.overlayAnimationOut,Q=u?null!=(s=null==O?void 0:O.modalAnimationIn)?s:zl.modalAnimationIn:null!=(c=null==O?void 0:O.modalAnimationOut)?c:zl.modalAnimationOut;return Y&&K?f.createPortal(t.createElement("div",{className:ml(zl.root,null==O?void 0:O.root),style:null==A?void 0:A.root,"data-testid":"root"},t.createElement("div",{className:ml(zl.overlay,null==O?void 0:O.overlay),"data-testid":"overlay","aria-hidden":!0,style:Cl({animation:Z+" "+I+"ms"},null==A?void 0:A.overlay)}),t.createElement("div",{ref:q,className:ml(zl.modalContainer,d&&zl.modalContainerCenter,null==O?void 0:O.modalContainer),style:null==A?void 0:A.modalContainer,"data-testid":"modal-container",onClick:function(e){null===V.current&&(V.current=!0),V.current?(null==M||M(e),y&&L(),V.current=null):V.current=null}},t.createElement("div",{ref:U,className:ml(zl.modal,null==O?void 0:O.modal),style:Cl({animation:Q+" "+I+"ms"},null==A?void 0:A.modal),onMouseDown:J,onMouseUp:J,onClick:J,onAnimationEnd:function(){u||G(!1),null==D||D()},id:z,role:B,"aria-modal":"true","aria-labelledby":F,"aria-describedby":R,"data-testid":"modal",tabIndex:-1},k&&t.createElement(Rl,{container:U,initialFocusRef:T}),H,_&&t.createElement(Tl,{classes:zl,classNames:O,styles:A,closeIcon:S,onClick:L,id:w})))),K):null}));const jl={white:"var(--white)","white-rgb":"var(--white-rgb)",gray1000:"var(--gray1000)","gray1000-rgb":"var(--gray1000-rgb)",gray900:"var(--gray900)",gray800:"var(--gray800)",gray700:"var(--gray700)",gray600:"var(--gray600)",gray500:"var(--gray500)",gray400:"var(--gray400)",gray300:"var(--gray300)",gray200:"var(--gray200)",gray100:"var(--gray100)",gray75:"var(--gray75)",gray50:"var(--gray50)",gray25:"var(--gray25)",gray10:"var(--gray10)",blue1000:"var(--blue1000)",blue900:"var(--blue900)",blue800:"var(--blue800)",blue700:"var(--blue700)",blue600:"var(--blue600)",blue500:"var(--blue500)",blue400:"var(--blue400)",blue300:"var(--blue300)",blue200:"var(--blue200)",blue100:"var(--blue100)",red400:"var(--red400)",red500:"var(--red500)",red600:"var(--red600)",red700:"var(--red700)",yellow500:"var(--yellow500)",green500:"var(--green500)",purple1000:"var(--purple1000)",purple900:"var(--purple900)",purple800:"var(--purple800)",purple700:"var(--purple700)",purple600:"var(--purple600)",purple500:"var(--purple500)",purple400:"var(--purple400)",purple300:"var(--purple300)",purple200:"var(--purple200)",purple100:"var(--purple100)",magenta1000:"var(--magenta1000)",magenta900:"var(--magenta900)",magenta800:"var(--magenta800)",magenta700:"var(--magenta700)",magenta600:"var(--magenta600)",magenta500:"var(--magenta500)",magenta400:"var(--magenta400)",magenta300:"var(--magenta300)",magenta200:"var(--magenta200)",magenta100:"var(--magenta100)",teal1000:"var(--teal1000)",teal900:"var(--teal900)",teal800:"var(--teal800)",teal700:"var(--teal700)",teal600:"var(--teal600)",teal500:"var(--teal500)",teal400:"var(--teal400)",teal300:"var(--teal300)",teal200:"var(--teal200)",teal100:"var(--teal100)",brandPrimary700:"var(--brandPrimary700)",brandPrimary600:"var(--brandPrimary600)",brandPrimary500:"var(--brandPrimary500)","brandPrimary500-rgb":"var(--brandPrimary500-rgb)",brandPrimary300:"var(--brandPrimary300)",brandPrimary100:"var(--brandPrimary100)",spacing1:"var(--spacing1)",spacing2:"var(--spacing2)",spacing3:"var(--spacing3)",spacing4:"var(--spacing4)",spacing5:"var(--spacing5)",spacing6:"var(--spacing6)",spacing7:"var(--spacing7)",spacing8:"var(--spacing8)",spacing9:"var(--spacing9)",layoutSpacing1:"var(--layoutSpacing1)",layoutSpacing2:"var(--layoutSpacing2)",layoutSpacing3:"var(--layoutSpacing3)",layoutSpacing4:"var(--layoutSpacing4)",layoutSpacing5:"var(--layoutSpacing5)",layoutSpacing6:"var(--layoutSpacing6)",layoutSpacing7:"var(--layoutSpacing7)",radiusSmall:"var(--radiusSmall)",radiusMedium:"var(--radiusMedium)",radiusLarge:"var(--radiusLarge)",radiusCircle:"var(--radiusCircle)",radiusPill:"var(--radiusPill)",radiusBase:"var(--radiusBase)",brandRadiusBase:"var(--brandRadiusBase)",fontStackBase:"var(--fontStackBase)",brandFontStackBase:"var(--brandFontStackBase)",fontSize25:"var(--fontSize25)",fontSize50:"var(--fontSize50)",fontSize75:"var(--fontSize75)",fontSize100:"var(--fontSize100)",fontSize200:"var(--fontSize200)",fontSize300:"var(--fontSize300)",fontSize400:"var(--fontSize400)",fontSize500:"var(--fontSize500)",fontSize600:"var(--fontSize600)",fontSize700:"var(--fontSize700)",fontSize800:"var(--fontSize800)",fontSize900:"var(--fontSize900)",fontSize1000:"var(--fontSize1000)",fontSizeBase:"var(--fontSizeBase)",lineHeightBase:"var(--lineHeightBase)",lineHeightHeading:"var(--lineHeightHeading)",lineHeightText:"var(--lineHeightText)",gray900a:"var(--gray900a)",gray800a:"var(--gray800a)",gray700a:"var(--gray700a)",gray600a:"var(--gray600a)",gray500a:"var(--gray500a)",gray400a:"var(--gray400a)",gray300a:"var(--gray300a)",gray200a:"var(--gray200a)",gray100a:"var(--gray100a)",gray75a:"var(--gray75a)",gray50a:"var(--gray50a)",gray25a:"var(--gray25a)",colorText:"var(--colorText)",colorTextDisabled:"var(--colorTextDisabled)",focusRingWidth:"var(--focusRingWidth)",focusRingColorPrimary:"var(--focusRingColorPrimary)",focusRingColorSecondary:"var(--focusRingColorSecondary)",colorShadow:"var(--colorShadow)",elevationStatic:"var(--elevationStatic)",elevation1:"var(--elevation1)",elevation2:"var(--elevation2)",elevation4:"var(--elevation4)",elevation8:"var(--elevation8)",elevation12:"var(--elevation12)",elevation16:"var(--elevation16)",elevation24:"var(--elevation24)",componentButtonPrimaryBorderHover:"var(--componentButtonPrimaryBorderHover)",componentButtonPrimaryBorderActive:"var(--componentButtonPrimaryBorderActive)",componentButtonPrimaryBorderFocus:"var(--componentButtonPrimaryBorderFocus)",componentButtonPrimaryBorderDisabled:"var(--componentButtonPrimaryBorderDisabled)",componentButtonPrimaryColor:"var(--componentButtonPrimaryColor)",componentButtonPrimaryColorHover:"var(--componentButtonPrimaryColorHover)",componentButtonPrimaryColorActive:"var(--componentButtonPrimaryColorActive)",componentButtonPrimaryColorFocus:"var(--componentButtonPrimaryColorFocus)",componentButtonPrimaryColorDisabled:"var(--componentButtonPrimaryColorDisabled)",componentButtonPrimaryFill:"var(--componentButtonPrimaryFill)",componentButtonPrimaryFillHover:"var(--componentButtonPrimaryFillHover)",componentButtonPrimaryFillActive:"var(--componentButtonPrimaryFillActive)",componentButtonPrimaryFillFocus:"var(--componentButtonPrimaryFillFocus)",componentButtonPrimaryFillDisabled:"var(--componentButtonPrimaryFillDisabled)",componentButtonPrimaryFocusRing:"var(--componentButtonPrimaryFocusRing)",componentButtonSecondaryBorder:"var(--componentButtonSecondaryBorder)",componentButtonSecondaryBorderHover:"var(--componentButtonSecondaryBorderHover)",componentButtonSecondaryBorderActive:"var(--componentButtonSecondaryBorderActive)",componentButtonSecondaryBorderFocus:"var(--componentButtonSecondaryBorderFocus)",componentButtonSecondaryBorderDisabled:"var(--componentButtonSecondaryBorderDisabled)",componentButtonSecondaryColor:"var(--componentButtonSecondaryColor)",componentButtonSecondaryColorHover:"var(--componentButtonSecondaryColorHover)",componentButtonSecondaryColorActive:"var(--componentButtonSecondaryColorActive)",componentButtonSecondaryColorFocus:"var(--componentButtonSecondaryColorFocus)",componentButtonSecondaryColorDisabled:"var(--componentButtonSecondaryColorDisabled)",componentButtonSecondaryFill:"var(--componentButtonSecondaryFill)",componentButtonSecondaryFillHover:"var(--componentButtonSecondaryFillHover)",componentButtonSecondaryFillActive:"var(--componentButtonSecondaryFillActive)",componentButtonSecondaryFillFocus:"var(--componentButtonSecondaryFillFocus)",componentButtonSecondaryFillDisabled:"var(--componentButtonSecondaryFillDisabled)",componentButtonSecondaryFocusRing:"var(--componentButtonSecondaryFocusRing)",componentButtonCleanBorderFocus:"var(--componentButtonCleanBorderFocus)",componentButtonCleanBorderActive:"var(--componentButtonCleanBorderActive)",componentButtonCleanColor:"var(--componentButtonCleanColor)",componentButtonCleanColorHover:"var(--componentButtonCleanColorHover)",componentButtonCleanColorActive:"var(--componentButtonCleanColorActive)",componentButtonCleanColorFocus:"var(--componentButtonCleanColorFocus)",componentButtonCleanColorDisabled:"var(--componentButtonCleanColorDisabled)",componentButtonCleanFill:"var(--componentButtonCleanFill)",componentButtonCleanFillHover:"var(--componentButtonCleanFillHover)",componentButtonCleanFillActive:"var(--componentButtonCleanFillActive)",componentButtonCleanFillFocus:"var(--componentButtonCleanFillFocus)",componentButtonCleanFillDisabled:"var(--componentButtonCleanFillDisabled)",componentButtonCleanFocusRing:"var(--componentButtonCleanFocusRing)"},Ml=cc(["color:",";font-size:",";font-family:",";line-height:",";"],jl.colorText,jl.fontSizeBase,jl.brandFontStackBase,jl.lineHeightBase);wc.div.withConfig({displayName:"BaseStyles",componentId:"zvdl8u-0"})(["",""],Ml),wc.div.withConfig({shouldForwardProp:(e,t)=>!["color"].includes(e)&&t(e)}).withConfig({displayName:"BadgeStyled",componentId:"zvdl8u-1"})(["display:inline-flex;vertical-align:middle;flex-wrap:nowrap;align-items:center;justify-content:center;box-sizing:border-box;height:",";padding:0 ",";border:2px solid transparent;border-radius:",";color:",";font-weight:normal;font-size:",";line-height:normal;",""],e=>e.isSmall?"20px":"24px",e=>e.isSmall?jl.spacing2:"6px",e=>e.isPillShaped?jl.radiusPill:jl.radiusMedium,jl.white,jl.fontSize50,e=>{if(!e.isSecondary&&e.color){const t={brand:jl.brandPrimary500,gray:jl.gray400,black:jl.gray900,blue:jl.blue500,red:jl.red400};return e.hasBorder?cc(["border-color:",";color:",";"],t[e.color],t[e.color]):cc(["background-color:",";"],t[e.color])}if(e.isSecondary)return cc(["border-color:",";background-color:",";color:",";"],e.hasBorder?jl.gray100:"transparent",e.hasBorder?jl.white:jl.gray100,jl.gray800)}),wc.div.withConfig({displayName:"IconHolder",componentId:"zvdl8u-2"})(["display:flex;align-items:center;height:100%;margin-right:",";margin-left:calc("," * -1);svg{width:18px;height:18px;}"],e=>e.isSmall?jl.spacing1:jl.spacing2,jl.spacing1),wc.div.withConfig({shouldForwardProp:(e,t)=>!["color"].includes(e)&&t(e)}).withConfig({displayName:"Track1",componentId:"zvdl8u-3"})(["overflow:hidden;height:4px;border-radius:",";background:",";"],e=>e.noCornerRadius?"0":jl.radiusPill,e=>"brand"===e.color?jl.brandPrimary500:`\n\t\t\t\tlinear-gradient(\n\t\t\t\t\t0deg,\n\t\t\t\t\trgb(${jl["white-rgb"]} / 30%),\n\t\t\t\t\trgb(${jl["white-rgb"]} / 30%)\n\t\t\t\t),\n\t\t\t\t${jl.gray100a}\n\t\t\t`);const Dl=kc(["to{transform:translateX(-40px);}"]),Hl=`rgb(${jl["white-rgb"]} / 0.15)`,Ul=`rgb(${jl["gray1000-rgb"]} / 0.15)`;wc.div.withConfig({displayName:"Fill2",componentId:"zvdl8u-4"})(["width:calc(100% + 60px);height:100%;background-image:linear-gradient( -45deg,"," 25%,"," 25%,"," 50%,"," 50%,"," 75%,"," 75%,"," );background-size:40px 40px;background-repeat:repeat-x;animation:"," 0.8s linear infinite;"],Hl,Ul,Ul,Hl,Hl,Ul,Ul,Dl);const ql={paragraphS:cc(["font-weight:normal;font-size:",";line-height:",";"],jl.fontSize75,jl.lineHeightText),paragraphM:cc(["font-weight:normal;font-size:",";line-height:",";"],jl.fontSize100,jl.lineHeightText),paragraphL:cc(["font-weight:normal;font-size:",";line-height:",";"],jl.fontSize200,jl.lineHeightText),uiTextXS:cc(["font-weight:normal;font-size:",";line-height:20px;"],jl.fontSize50),uiTextS:cc(["font-weight:normal;font-size:",";line-height:20px;"],jl.fontSize75),uiTextM:cc(["font-weight:normal;font-size:",";line-height:20px;"],jl.fontSize100),uiTextL:cc(["font-weight:normal;font-size:",";line-height:24px;"],jl.fontSize200),headingXS:cc(["font-weight:600;font-size:",";line-height:",";"],jl.fontSize100,jl.lineHeightHeading),headingS:cc(["font-weight:600;font-size:",";line-height:",";"],jl.fontSize200,jl.lineHeightHeading),headingM:cc(["font-weight:normal;font-size:",";line-height:",";"],jl.fontSize400,jl.lineHeightHeading),headingL:cc(["font-weight:normal;font-size:",";line-height:",";"],jl.fontSize600,jl.lineHeightHeading),headingXL:cc(["font-weight:normal;font-size:",";line-height:",";"],jl.fontSize800,jl.lineHeightHeading),headingXXL:cc(["font-weight:normal;font-size:",";line-height:",";"],jl.fontSize1000,jl.lineHeightHeading)};wc.label.withConfig({displayName:"Container5",componentId:"zvdl8u-5"})([""," display:flex;align-items:flex-start;margin:0;padding:"," 0;cursor:",";user-select:none;"],ql.uiTextM,jl.spacing1,e=>!e.isDisabled&&"pointer"),wc.div.withConfig({displayName:"IndicatorPosition1",componentId:"zvdl8u-6"})(["display:flex;flex:none;align-items:center;&::before{content:'​';}"]),wc.div.withConfig({displayName:"Indicator2",componentId:"zvdl8u-7"})(["position:relative;display:flex;align-items:center;justify-content:center;box-sizing:border-box;width:16px;height:16px;border:2px solid ",";border-radius:",";background-color:transparent;&::before{content:'';position:absolute;top:-5px;right:-5px;bottom:-5px;left:-5px;border:"," solid transparent;border-radius:calc( "," + 3px );}"," "," "," "," ",":hover &,",":focus-visible &{"," background-color:",";}"],jl.gray300,jl.radiusMedium,jl.focusRingWidth,jl.radiusMedium,e=>e.isFocusVisible&&cc(["border-color:",";&::before{border-color:",";}"],jl.gray500,e.isChecked||e.isIndeterminate?jl.focusRingColorPrimary:jl.focusRingColorSecondary),e=>e.isChecked&&cc(["border-color:transparent;background-color:",";fill:#fff;"],jl.blue500),e=>e.isIndeterminate&&cc(["border-color:transparent;background-color:",";"],jl.blue500),e=>e.isDisabled&&cc(["border-color:transparent;background-color:",";fill:",";"],jl.gray100,jl.gray500),".ds-checkbox__pointer-events-wrapper",".ds-checkbox__pointer-events-wrapper",e=>!e.isChecked&&!e.isIndeterminate&&!e.isDisabled&&`border-color: ${jl.gray500};`,e=>!e.isChecked&&!e.isIndeterminate||e.isDisabled?void 0:jl.blue600),wc.input.withConfig({displayName:"Input1",componentId:"zvdl8u-8"})(["position:absolute;overflow:hidden;clip:rect(0,0,0,0);width:1px;height:1px;margin:0 -1px -1px 0;padding:0;border:0;white-space:nowrap;clip-path:inset(50%);"]),wc.div.withConfig({displayName:"IndeterminateMark",componentId:"zvdl8u-9"})(["width:8px;height:2px;border-radius:",";background-color:",";"],jl.radiusPill,jl.white),wc.div.withConfig({displayName:"Label4",componentId:"zvdl8u-10"})(["display:block;margin-left:8px;color:",";"],e=>e.isDisabled?jl.gray400:jl.colorText),wc.div.withConfig({displayName:"GroupStyled",componentId:"zvdl8u-11"})(["margin:0;padding:"," 0;border:0;"],jl.spacing3),wc.div.withConfig({displayName:"HelperTextStyled",componentId:"zvdl8u-12"})([""," display:flex;align-items:center;margin-top:",";padding-top:",";color:",";"],ql.uiTextS,jl.spacing2,e=>e.hasIcon?"2px":"0",e=>e.isInvalid?jl.red500:jl.gray600),wc.div.withConfig({displayName:"Icon2",componentId:"zvdl8u-13"})(["flex:none;align-self:flex-start;margin-top:-2px;margin-right:",";"],jl.spacing2),wc.label.withConfig({displayName:"LabelStyled",componentId:"zvdl8u-14"})([""," display:block;margin:0 0 ",";padding:0;border:none;color:",";"],ql.uiTextM,jl.spacing3,jl.colorText),wc.span.withConfig({displayName:"SecondaryText",componentId:"zvdl8u-15"})(["color:",";"],jl.gray600),wc.span.withConfig({displayName:"Space",componentId:"zvdl8u-16"})(["display:inline-block;width:",";"],jl.spacing3),wc.div.withConfig({displayName:"RowStyled",componentId:"zvdl8u-17"})(["display:grid;grid-template-columns:repeat(auto-fit,minmax(10px,1fr));gap:",";"],jl.spacing4),wc.div.withConfig({displayName:"InputRowStyled",componentId:"zvdl8u-18"})(["display:flex;& > *{min-width:min-content;&:not(:first-child){margin-left:",";}}"],jl.spacing4),wc.ul.withConfig({displayName:"List",componentId:"zvdl8u-19"})(["margin:0;padding:0;list-style:none;"]),wc.li.withConfig({displayName:"Item2",componentId:"zvdl8u-20"})(["&:not(:last-child){margin-bottom:",";}"],jl.spacing2);const Vl=wc.span.withConfig({displayName:"DeleteButton",componentId:"zvdl8u-21"})(["display:flex;align-items:center;justify-content:center;width:24px;height:24px;margin:0 calc("," * -1) 0 ",";padding:0;border:0;border-radius:",";background:none;color:",";outline:0;cursor:pointer;&:hover{background:",";color:",";}&:active{background:",";}"],jl.spacing3,jl.spacing3,jl.radiusCircle,e=>e.isDisabled?jl.gray400:jl.gray600,jl.gray50a,jl.gray800,jl.gray100a);wc.button.withConfig({displayName:"ChipStyled",componentId:"zvdl8u-22"})(["display:inline-flex;align-items:center;border:0;border-radius:",";background-color:",";color:",";outline:none;font-family:",";white-space:nowrap;",";",";",";",";",";"],jl.radiusPill,jl.gray50,jl.gray800,jl.brandFontStackBase,e=>e.onClick&&cc(["cursor:pointer;&:hover{background-color:",";","{color:",";}}&:active{background-color:",";}"],jl.gray75,Vl,jl.gray800,jl.gray100),e=>e.isFocusVisible&&cc(["background:",";box-shadow:inset ",";outline:0;"],jl.gray25,jl.elevationStatic),e=>"m"===e.size&&Yl,e=>"s"===e.size&&$l,e=>e.isDisabled&&Gl);const Wl=wc.div.withConfig({displayName:"ThumbnailContainer1",componentId:"zvdl8u-23"})(["display:block;"]),$l=cc([""," height:32px;padding:0 12px;","{margin:0 "," 0 calc("," * -1);}"],ql.uiTextS,Wl,jl.spacing3,jl.spacing3),Yl=cc([""," height:40px;padding:0 16px;","{margin:0 "," 0 calc("," * -1);}"],ql.uiTextM,Wl,jl.spacing3,jl.spacing4),Gl=cc(["background-color:",";color:",";pointer-events:none;"],jl.gray25,jl.gray400);function Xl(e){if(!function(e){return/^#([\da-f]{3}){1,2}$/i.test(e)}(e))throw new Error(`Invalid HEX to RGB conversion: ${e}`);let t,n,r;return 4===e.length?(t="0x"+e[1]+e[1],n="0x"+e[2]+e[2],r="0x"+e[3]+e[3]):7===e.length?(t="0x"+e[1]+e[2],n="0x"+e[3]+e[4],r="0x"+e[5]+e[6]):(t="",n="",r=""),`${Number(t)} ${Number(n)} ${Number(r)}`}wc.div.withConfig({displayName:"IconContainer1",componentId:"zvdl8u-24"})(["width:24px;height:24px;margin-left:calc("," * -1);padding:0 "," 0 0;"],jl.spacing2,jl.spacing3);const Jl={"--white":"#ffffff","--white-rgb":Xl("#ffffff"),"--gray1000":"#002233","--gray1000-rgb":Xl("#002233"),"--gray900":"#1a3847","--gray800":"#334e5c","--gray700":"#4d6470","--gray600":"#667a85","--gray500":"#809199","--gray400":"#99a7ad","--gray300":"#b3bdc2","--gray200":"#ccd3d6","--gray100":"#e6e9eb","--gray75":"#ebedef","--gray50":"#f2f4f5","--gray25":"#f7f8f9","--gray10":"#ffffff","--blue1000":"#001f33","--blue900":"#003d66","--blue800":"#005c99","--blue700":"#007acc","--blue600":"#008ae6","--blue500":"#0099ff","--blue400":"#1aa3ff","--blue300":"#33adff","--blue200":"#80ccff","--blue100":"#ccebff","--red400":"#f45225","--red500":"#f23e0d","--red600":"#da380b","--red700":"#c2320a","--yellow500":"#fea900","--green500":"#72d400","--purple1000":"#15122e","--purple900":"#1f1b44","--purple800":"#2a245c","--purple700":"#40378a","--purple600":"#5549b8","--purple500":"#6b5ce6","--purple400":"#978ced","--purple300":"#c3bdf5","--purple200":"#e1defa","--purple100":"#f7f6fd","--magenta1000":"#2e0d18","--magenta900":"#451424","--magenta800":"#5c1b30","--magenta700":"#8a2949","--magenta600":"#b83761","--magenta500":"#e6457a","--magenta400":"#eb6a94","--magenta300":"#f5b4c9","--magenta200":"#fad9e4","--magenta100":"#fdf5f8","--teal1000":"#062822","--teal900":"#0a3c32","--teal800":"#0d5144","--teal700":"#147a66","--teal600":"#1ba388","--teal500":"#22ccaa","--teal400":"#64dbc3","--teal300":"#a6eadd","--teal200":"#d2f4ee","--teal100":"#f3fcfa","--brandPrimary700":"#0087e0","--brandPrimary600":"#0095eb","--brandPrimary500":"var(--userBrandPrimary500, #00aaff)","--brandPrimary500-rgb":Xl("#00aaff"),"--brandPrimary300":"#b3e6ff","--brandPrimary100":"#e5f7ff","--spacing1":"2px","--spacing2":"4px","--spacing3":"8px","--spacing4":"12px","--spacing5":"16px","--spacing6":"24px","--spacing7":"32px","--spacing8":"40px","--spacing9":"48px","--layoutSpacing1":"16px","--layoutSpacing2":"24px","--layoutSpacing3":"32px","--layoutSpacing4":"48px","--layoutSpacing5":"64px","--layoutSpacing6":"96px","--layoutSpacing7":"160px","--radiusSmall":"2px","--radiusMedium":"5px","--radiusLarge":"8px","--radiusCircle":"50%","--radiusPill":"9999px","--radiusBase":"var(--radiusMedium)","--brandRadiusBase":"var(--radiusBase)","--fontStackBase":"Source Sans Pro, SourceSansPro, system-ui, sans-serif","--brandFontStackBase":"inherit","--fontSize25":"10px","--fontSize50":"12px","--fontSize75":"14px","--fontSize100":"16px","--fontSize200":"18px","--fontSize300":"20px","--fontSize400":"22px","--fontSize500":"25px","--fontSize600":"28px","--fontSize700":"32px","--fontSize800":"36px","--fontSize900":"40px","--fontSize1000":"45px","--fontSizeBase":"var(--fontSize100)","--lineHeightBase":"1.25","--lineHeightHeading":"1.25","--lineHeightText":"1.5","--gray900a":"rgb(var(--gray1000-rgb) / 90%)","--gray800a":"rgb(var(--gray1000-rgb) / 80%)","--gray700a":"rgb(var(--gray1000-rgb) / 70%)","--gray600a":"rgb(var(--gray1000-rgb) / 60%)","--gray500a":"rgb(var(--gray1000-rgb) / 50%)","--gray400a":"rgb(var(--gray1000-rgb) / 40%)","--gray300a":"rgb(var(--gray1000-rgb) / 30%)","--gray200a":"rgb(var(--gray1000-rgb) / 20%)","--gray100a":"rgb(var(--gray1000-rgb) / 10%)","--gray75a":"rgb(var(--gray1000-rgb) / 7%)","--gray50a":"rgb(var(--gray1000-rgb) / 5%)","--gray25a":"rgb(var(--gray1000-rgb) / 3%)","--colorText":"var(--gray800)","--colorTextDisabled":"var(--gray400)","--focusRingWidth":"2px","--focusRingColorPrimary":"var(--blue500)","--focusRingColorSecondary":"var(--gray200)","--colorShadow":"var(--gray100a)","--elevationStatic":"0 0 0 1px var(--colorShadow)","--elevation1":"0 1px 4px -1px var(--colorShadow)","--elevation2":"0 2px 4px -1px var(--colorShadow)","--elevation4":"0 4px 6px -2px var(--colorShadow)","--elevation8":"0 8px 12px -2px var(--colorShadow)","--elevation12":"0 12px 12px -2px var(--colorShadow)","--elevation16":"0 16px 12px -2px var(--colorShadow)","--elevation24":"0 24px 12px -2px var(--colorShadow)","--componentButtonPrimaryBorderHover":"var(--brandPrimary600)","--componentButtonPrimaryBorderActive":"var(--brandPrimary700)","--componentButtonPrimaryBorderFocus":"var(--brandPrimary500)","--componentButtonPrimaryBorderDisabled":"transparent","--componentButtonPrimaryColor":"var(--white)","--componentButtonPrimaryColorHover":"var(--white)","--componentButtonPrimaryColorActive":"var(--white)","--componentButtonPrimaryColorFocus":"var(--white)","--componentButtonPrimaryColorDisabled":"var(--white)","--componentButtonPrimaryFill":"var(--brandPrimary500)","--componentButtonPrimaryFillHover":"var(--brandPrimary600)","--componentButtonPrimaryFillActive":"var(--brandPrimary700)","--componentButtonPrimaryFillFocus":"var(--brandPrimary500)","--componentButtonPrimaryFillDisabled":"var(--brandPrimary300)","--componentButtonPrimaryFocusRing":"0 0 0 3px rgb(var(--brandPrimary500-rgb) / 30%)","--componentButtonSecondaryBorder":"var(--gray100)","--componentButtonSecondaryBorderHover":"var(--gray200)","--componentButtonSecondaryBorderActive":"var(--gray300)","--componentButtonSecondaryBorderFocus":"var(--gray300)","--componentButtonSecondaryBorderDisabled":"var(--gray50)","--componentButtonSecondaryColor":"var(--gray800)","--componentButtonSecondaryColorHover":"var(--gray800)","--componentButtonSecondaryColorActive":"var(--gray800)","--componentButtonSecondaryColorFocus":"var(--gray800)","--componentButtonSecondaryColorDisabled":"var(--gray300)","--componentButtonSecondaryFill":"var(--gray25)","--componentButtonSecondaryFillHover":"var(--gray50)","--componentButtonSecondaryFillActive":"var(--gray75)","--componentButtonSecondaryFillFocus":"var(--gray25)","--componentButtonSecondaryFillDisabled":"var(--gray25)","--componentButtonSecondaryFocusRing":"0 0 0 3px var(--gray50a)","--componentButtonCleanBorderFocus":"var(--gray200)","--componentButtonCleanBorderActive":"transparent","--componentButtonCleanColor":"var(--gray600)","--componentButtonCleanColorHover":"var(--gray900)","--componentButtonCleanColorActive":"var(--gray900)","--componentButtonCleanColorFocus":"var(--gray900)","--componentButtonCleanColorDisabled":"var(--gray300)","--componentButtonCleanFill":"transparent","--componentButtonCleanFillHover":"var(--gray25)","--componentButtonCleanFillActive":"var(--gray75)","--componentButtonCleanFillFocus":"transparent","--componentButtonCleanFillDisabled":"transparent","--componentButtonCleanFocusRing":"0 0 0 3px var(--gray50a)"},Kl={"--gray1000":"#ffffff","--gray1000-rgb":Xl("#ffffff"),"--gray900":"#e6e9eb","--gray800":"#ccd3d6","--gray700":"#b3bdc2","--gray600":"#99a7ad","--gray500":"#809199","--gray400":"#667a85","--gray300":"#4d6470","--gray200":"#334e5c","--gray100":"#1a3847","--gray75":"#123141","--gray50":"#0d2d3d","--gray25":"#082939","--gray10":"#002233"},Zl=Ec`${cc([":root,:host,.",",.","{","}.","{","}"],"ds-light-theme","ds-dark-theme",Ql(Jl),"ds-dark-theme",Ql(Kl))}`;function Ql(e){return Object.entries(e).map(e=>e.join(":")).join(";")+";"}const eu={size:"24px",attr:{"aria-hidden":"true"},style:{verticalAlign:"middle"}};function tu({children:e,noTheme:n}){return t.createElement(Vc.Provider,{value:eu},!n&&t.createElement(Zl,null),e)}wc.div.withConfig({displayName:"ArrowStyled",componentId:"zvdl8u-25"})(["margin-right:calc("," * -1);margin-left:calc("," * -1);"],jl.spacing2,jl.spacing2);const nu=s(({children:e,...n},r)=>t.createElement(ru,Object.assign({role:"menu",ref:r},n),e)),ru=wc.div.withConfig({displayName:"ContainerStyled",componentId:"zvdl8u-26"})(["z-index:1032;overflow-y:auto;box-sizing:border-box;min-width:224px;max-width:336px;max-height:calc(36px * 9.5 + ",");padding:"," 0;border-radius:",";background:",";box-shadow:",",",";"],jl.spacing3,jl.spacing3,jl.radiusBase,jl.gray10,jl.elevationStatic,jl.elevation2);wc.hr.withConfig({displayName:"DividerStyled",componentId:"zvdl8u-27"})(["box-sizing:content-box;height:1px;margin:0;padding:"," 0;border:none;background:",";background-clip:content-box;"],jl.spacing3,jl.gray50),wc.label.withConfig({displayName:"SwitchStyled",componentId:"zvdl8u-28"})([""," display:flex;align-items:baseline;margin:0;padding:"," 0;color:",";cursor:",";user-select:none;"],ql.uiTextM,jl.spacing1,jl.gray800,e=>!e.isDisabled&&"pointer"),wc.span.withConfig({displayName:"Label2",componentId:"zvdl8u-29"})(["align-self:center;margin-right:",";"],jl.spacing4),wc.span.withConfig({displayName:"ToggleAlignment",componentId:"zvdl8u-30"})(["margin-left:auto;&::before{content:'\\200B';display:inline-block;vertical-align:middle;}"]);const ou=wc.span.withConfig({displayName:"Toggle",componentId:"zvdl8u-31"})(["position:relative;display:inline-block;vertical-align:middle;width:36px;height:22px;input{position:absolute;opacity:0;}"]);wc.span.withConfig({displayName:"Indicator1",componentId:"zvdl8u-32"})(["position:absolute;top:0;right:0;bottom:0;left:0;box-sizing:border-box;width:100%;height:100%;border-radius:",";background:",";cursor:",";transition:0.2s;&::before{content:'';position:absolute;right:calc(100% - 20px);bottom:2px;left:2px;height:18px;border-radius:50%;background-color:",";box-shadow:",";transition:0.2s;}"," input:checked + &{background-color:",";opacity:",";&::before{right:2px;left:calc(100% - 20px);background-color:",";}}"," ",":hover &,",":focus-visible &{background-color:",";}",":hover input:checked + &,",":focus-visible input:checked + &{background-color:",";}",""],jl.radiusPill,e=>e.isDisabled?jl.gray100:jl.gray75,e=>!e.isDisabled&&"pointer",e=>e.isDisabled?jl.gray50:jl.gray10,jl.elevation2,ou,e=>e.isDisabled?jl.gray400:jl.blue500,e=>e.isDisabled?"0.5":"1",e=>e.isDisabled?jl.gray100:jl.gray10,e=>!e.isDisabled&&cc(["",":active input + &::before{right:calc(100% - 24px);left:2px;border-radius:9px;}",":active input:checked + &::before{right:2px;left:calc(100% - 24px);}"],".ds-switch__pointer-events-wrapper",".ds-switch__pointer-events-wrapper"),".ds-switch__pointer-events-wrapper",".ds-switch__pointer-events-wrapper",jl.gray100,".ds-switch__pointer-events-wrapper",".ds-switch__pointer-events-wrapper",e=>e.isDisabled?jl.gray400:jl.blue600,e=>e.isFocusVisible&&cc([""," input + &{background-color:",";&::after{content:'';position:absolute;top:-3px;right:-3px;bottom:-3px;left:-3px;border:2px solid ",";border-radius:100px;}}"," input:checked + &::after{border-color:",";}"],ou,jl.gray100,jl.gray200,ou,jl.blue500)),wc.div.withConfig({displayName:"ItemWrapper",componentId:"zvdl8u-33"})(["position:relative;"]);const iu=wc.button.withConfig({displayName:"ItemStyled",componentId:"zvdl8u-34"})([""," display:flex;align-items:center;box-sizing:border-box;width:100%;height:36px;margin:0;padding:0 ",";border:none;background:none;color:",";outline:none;font-family:",";cursor:pointer;"," "," &:hover{background:",";color:",";}&:active{background:",";color:",";}&:disabled{background:none;color:",";cursor:default;}"],ql.uiTextS,jl.spacing5,e=>e.isChecked?jl.gray800:jl.gray600,jl.brandFontStackBase,e=>e.isSubmenuOpen&&cc(["background:",";color:",";"],jl.gray25,jl.gray800),e=>e.isFocusVisible&&cc(["background:",";color:",";"],jl.gray50,jl.gray800),jl.gray25,jl.gray800,jl.gray50,jl.gray800,jl.gray400);function au({children:e,direction:n="row",wrap:r="nowrap",justifyContent:o="flex-start",alignItems:i="stretch",gap:a,...s}){return t.createElement(su,Object.assign({},s),t.createElement(cu,{direction:n,wrap:r,justifyContent:o,alignItems:i,gap:a},e))}wc.span.withConfig({displayName:"CheckboxContainer",componentId:"zvdl8u-35"})(["display:flex;flex:none;align-items:center;justify-content:center;width:24px;height:24px;margin-right:",";"],jl.spacing3),wc.span.withConfig({displayName:"Icon1",componentId:"zvdl8u-36"})(["display:flex;flex:none;align-items:center;justify-content:center;width:24px;height:24px;margin-right:",";"],jl.spacing3),wc.span.withConfig({displayName:"Label1",componentId:"zvdl8u-37"})(["flex:1;overflow:hidden;min-width:0;text-align:left;text-overflow:ellipsis;white-space:nowrap;"]),wc.span.withConfig({displayName:"RightContainer",componentId:"zvdl8u-38"})(["flex:none;margin:0 ",";&:last-child{margin-right:calc("," * -1);}"],jl.spacing3,jl.spacing2),wc.span.withConfig({displayName:"SubmenuIconContainer",componentId:"zvdl8u-39"})(["flex:none;margin-right:calc("," * -1);margin-left:",";color:",";",":hover,",":active{color:",";}"],jl.spacing3,jl.spacing3,e=>e.isActive?jl.gray400:jl.gray200,iu,iu,jl.gray400),wc(nu).withConfig({displayName:"SubMenuContainer",componentId:"zvdl8u-40"})(["margin-top:calc("," * -1);"],jl.spacing3),wc.div.withConfig({displayName:"SectionTitleStyled",componentId:"zvdl8u-41"})([""," overflow:hidden;padding:"," "," ",";color:",";text-overflow:ellipsis;white-space:nowrap;"],ql.uiTextS,jl.spacing4,jl.spacing5,jl.spacing3,jl.gray800),wc.span.withConfig({displayName:"Text1",componentId:"zvdl8u-42"})(["width:100%;text-align:left;"]);const su=wc.div.withConfig({displayName:"Wrapper",componentId:"zvdl8u-43"})(["display:flex;"]),cu=wc.div.withConfig({shouldForwardProp:(e,t)=>!["direction","wrap"].includes(e)&&t(e)}).withConfig({displayName:"Container3",componentId:"zvdl8u-44"})(["display:flex;flex-direction:",";flex-wrap:",";align-items:",";justify-content:",";box-sizing:border-box;width:100%;height:100%;",""],e=>e.direction,e=>e.wrap,e=>e.alignItems,e=>e.justifyContent,e=>{if(!e.gap)return null;const t=jl[`spacing${e.gap}`];return cc(["width:calc(100% + calc("," + 1px));height:calc(100% + ",");margin-bottom:calc("," * -1);margin-left:calc("," * -1);&& > *{margin-bottom:",";margin-left:",";}"],t,t,t,t,t,t)}),lu=wc.button.withConfig({displayName:"ButtonStyled",componentId:"zvdl8u-45"})(["display:inline-flex;vertical-align:middle;flex-wrap:nowrap;align-items:center;justify-content:center;box-sizing:border-box;min-width:40px;border:1px solid transparent;border-radius:",";background-color:transparent;outline:none;font-weight:400;font-style:normal;font-size:",";font-family:",";line-height:",";letter-spacing:normal;text-align:center;text-decoration:none;white-space:nowrap;cursor:pointer;fill:currentColor;transition-duration:0.1s;transition-property:background-color,border-color,box-shadow,color;&:disabled{cursor:default;}"," ",";",""],jl.brandRadiusBase,jl.fontSizeBase,jl.brandFontStackBase,jl.lineHeightBase,e=>e.isFullWidth&&"width: 100%;",e=>e.isSmall?cc(["height:32px;padding:0 ",";font-size:",";line-height:20px;"],jl.spacing4,jl.fontSize75):cc(["height:40px;padding:0 ",";"],jl.spacing5),e=>{if("primary"===e.variant){const t=cc(["border-color:",";background-color:",";color:",";box-shadow:none;"],jl.componentButtonPrimaryBorderActive,jl.componentButtonPrimaryFillActive,jl.componentButtonPrimaryColorActive);return cc(["border-color:transparent;background-color:",";color:",";"," &:hover{border-color:",";background-color:",";color:",";box-shadow:",";}&:active{","}"," &:disabled{border-color:",";background-color:",";color:",";box-shadow:none;}"],jl.componentButtonPrimaryFill,jl.componentButtonPrimaryColor,e.isPressed&&t,jl.componentButtonPrimaryBorderHover,jl.componentButtonPrimaryFillHover,jl.componentButtonPrimaryColorHover,jl.elevation1,t,e.isFocusVisible&&cc(["background-color:",";color:",";&,&:hover{border-color:",";box-shadow:",";}"],jl.componentButtonPrimaryFillFocus,jl.componentButtonPrimaryColorFocus,jl.componentButtonPrimaryBorderFocus,jl.componentButtonPrimaryFocusRing),jl.componentButtonPrimaryBorderDisabled,jl.componentButtonPrimaryFillDisabled,jl.componentButtonPrimaryColorDisabled)}if("secondary"===e.variant){const t=cc(["border-color:",";background-color:",";color:",";box-shadow:none;"],jl.componentButtonSecondaryBorderActive,jl.componentButtonSecondaryFillActive,jl.componentButtonSecondaryColorActive);return cc(["border-color:",";background-color:",";color:",";"," &:hover{border-color:",";background-color:",";color:",";box-shadow:",";}&:active{","}"," &:disabled{border-color:",";background-color:",";color:",";box-shadow:none;}"],jl.componentButtonSecondaryBorder,jl.componentButtonSecondaryFill,jl.componentButtonSecondaryColor,e.isPressed&&t,jl.componentButtonSecondaryBorderHover,jl.componentButtonSecondaryFillHover,jl.componentButtonSecondaryColorHover,jl.elevation1,t,e.isFocusVisible&&cc(["background-color:",";color:",";&,&:hover{border-color:",";box-shadow:",";}"],jl.componentButtonSecondaryFillFocus,jl.componentButtonSecondaryColorFocus,jl.componentButtonSecondaryBorderFocus,jl.componentButtonSecondaryFocusRing),jl.componentButtonSecondaryBorderDisabled,jl.componentButtonSecondaryFillDisabled,jl.componentButtonSecondaryColorDisabled)}if("clean"===e.variant){const t=cc(["border-color:",";background-color:",";color:",";box-shadow:none;"],jl.componentButtonCleanBorderActive,jl.componentButtonCleanFillActive,jl.componentButtonCleanColorActive);return cc(["background-color:",";color:",";"," &:hover{background-color:",";color:",";box-shadow:none;}&:active{","}"," &:disabled{background-color:",";color:",";}"],jl.componentButtonCleanFill,jl.componentButtonCleanColor,e.isPressed&&t,jl.componentButtonCleanFillHover,jl.componentButtonCleanColorHover,t,e.isFocusVisible&&cc(["color:",";&,&:hover{border-color:",";box-shadow:",";}"],jl.componentButtonCleanColorFocus,jl.componentButtonCleanBorderFocus,jl.componentButtonCleanFocusRing),jl.componentButtonCleanFillDisabled,jl.componentButtonCleanColorDisabled)}return""}),uu=wc.div.withConfig({displayName:"Icon",componentId:"zvdl8u-46"})(["display:flex;align-items:center;height:100%;"]),du=wc(uu).withConfig({displayName:"LeftIcon",componentId:"zvdl8u-47"})(["margin-right:",";margin-left:calc("," * -1);"],e=>e.lastChild?`calc(${jl.spacing2} * -1) `:jl.spacing3,jl.spacing2),pu=wc(uu).withConfig({displayName:"RightIcon",componentId:"zvdl8u-48"})(["margin-right:calc("," * -1);margin-left:",";"],jl.spacing2,jl.spacing3);function fu(){return t.createElement(gu,{viewBox:"0 0 24 24","aria-hidden":"true"},t.createElement(vu,{cx:"12",cy:"12",r:"8",fill:"none",strokeWidth:"3"}))}const hu=kc(["100%{transform:rotate(360deg);}"]),mu=kc(["0%{stroke-dasharray:1,100;stroke-dashoffset:0;}50%{stroke-dasharray:80,100;stroke-dashoffset:-20;}100%{stroke-dasharray:80,100;stroke-dashoffset:-48;}"]),gu=wc.svg.withConfig({displayName:"Svg",componentId:"zvdl8u-49"})(["width:24px;height:24px;animation:"," 1s linear infinite;"],hu),vu=wc.circle.withConfig({displayName:"Circle",componentId:"zvdl8u-50"})(["stroke:currentColor;animation:"," 1.5s ease-in-out infinite;stroke-linecap:round;"],mu),yu=s(({children:e,variant:n="secondary",isSmall:o=!1,icon:i,rightIcon:a,isDisabled:s=!1,isLoading:c=!1,type:u="button",...d},p)=>{const{isFocusVisible:f,focusProps:h}=function(e){void 0===e&&(e={});let{within:t}=e,[n,o]=r(!1),[i,a]=r(!1),{isFocusVisible:s}=Uc(e),{focusProps:c}=function(e){if(e.isDisabled)return{focusProps:{}};let t,n;return(e.onFocus||e.onFocusChange)&&(t=t=>{t.target===t.currentTarget&&(e.onFocus&&e.onFocus(t),e.onFocusChange&&e.onFocusChange(!0))}),(e.onBlur||e.onFocusChange)&&(n=t=>{t.target===t.currentTarget&&(e.onBlur&&e.onBlur(t),e.onFocusChange&&e.onFocusChange(!1))}),{focusProps:{onFocus:t,onBlur:n}}}({isDisabled:t,onFocusChange:o}),{focusWithinProps:u}=function(e){let t=l({isFocusWithin:!1}).current;return e.isDisabled?{focusWithinProps:{}}:{focusWithinProps:{onFocus:n=>{t.isFocusWithin||(e.onFocusWithin&&e.onFocusWithin(n),e.onFocusWithinChange&&e.onFocusWithinChange(!0),t.isFocusWithin=!0)},onBlur:n=>{t.isFocusWithin&&!n.currentTarget.contains(n.relatedTarget)&&(e.onBlurWithin&&e.onBlurWithin(n),e.onFocusWithinChange&&e.onFocusWithinChange(!1),t.isFocusWithin=!1)}}}}({isDisabled:!t,onFocusWithinChange:a});return{isFocused:t?i:n,isFocusVisible:(t?i:n)&&s,focusProps:t?u:c}}();return t.createElement(lu,Object.assign({variant:n,isSmall:o,disabled:c||s,type:u,as:d.href?"a":"button",isFocusVisible:f,ref:p},h,d),c?t.createElement(t.Fragment,null,t.createElement(du,{"data-testid":"ds-button-loading-icon"},t.createElement(fu,null)),e):t.createElement(t.Fragment,null,i&&t.createElement(du,{lastChild:!e},i),e,a&&t.createElement(pu,null,a)))}),bu=Ec`${cc(["@keyframes ","{0%{opacity:0;}100%{opacity:1;}}@keyframes ","{0%{opacity:1;}100%{opacity:0;}}@keyframes ","{0%{opacity:0.5;transform:scale(0.95);}100%{opacity:1;transform:scale(1);}}@keyframes ","{0%{opacity:1;transform:scale(1);}100%{opacity:0.5;transform:scale(0.95);}}.",",.","{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1031;}.","{background:",";}.","{display:flex;align-items:flex-start;overflow-x:hidden;overflow-y:auto;padding:",";}.","{position:relative;display:flex;flex-direction:column;align-items:stretch;box-sizing:border-box;width:520px;margin:auto;border-radius:",";background:",";box-shadow:",";",";}.","{width:100%;height:100%;min-height:0;}"],"b-modal-overlay-in","b-modal-overlay-out","b-modal-container-in","b-modal-container-out","b-modal__overlay","b-modal__container","b-modal__overlay",jl.gray200a,"b-modal__container",jl.spacing6,"b-modal__modal",jl.radiusBase,jl.gray10,jl.elevation8,Ml,"b-modal__modal--full-screen")}`,xu=wc.div.withConfig({displayName:"HeaderStyled",componentId:"zvdl8u-51"})(["display:flex;flex:none;align-items:center;box-sizing:border-box;height:72px;padding:"," ",";",""],jl.spacing4,jl.spacing6,e=>!e.hideCloseIcon&&cc(["padding-right:calc( "," + 50px + "," );"],jl.spacing4,jl.spacing6)),_u=wc.div.withConfig({displayName:"BackButton",componentId:"zvdl8u-52"})(["margin-right:",";margin-left:calc("," * -1);"],jl.spacing4,jl.spacing4),wu=wc.div.withConfig({displayName:"ModalThumbnail",componentId:"zvdl8u-53"})(["margin-right:",";"],jl.spacing4),Su=wc.div.withConfig({displayName:"Headings",componentId:"zvdl8u-54"})(["flex:1;min-width:0;"]),Eu=wc.h2.withConfig({displayName:"Title2",componentId:"zvdl8u-55"})([""," overflow:hidden;margin:0;color:",";text-overflow:ellipsis;white-space:nowrap;"],ql.uiTextL,jl.colorText),ku=wc.h3.withConfig({displayName:"SecondaryInformation",componentId:"zvdl8u-56"})([""," overflow:hidden;margin:0;color:",";text-overflow:ellipsis;white-space:nowrap;"],ql.uiTextS,jl.gray500),Cu=wc.div.withConfig({displayName:"ContentStyled",componentId:"zvdl8u-57"})(["flex:1 1 auto;min-height:0;",""],e=>e.scrollable&&cc(["position:relative;&::before,&::after{content:'';position:absolute;left:0;display:block;width:100%;height:6px;}&::before{top:0;z-index:1;background:linear-gradient(to bottom,",",transparent);}&::after{bottom:0;background:linear-gradient(to top,",",transparent);}"],jl.colorShadow,jl.colorShadow)),Tu=wc.div.withConfig({displayName:"ContentInner",componentId:"zvdl8u-58"})(["box-sizing:border-box;padding:"," ",";"," ",""],jl.spacing5,jl.spacing6,Ml,e=>e.scrollable&&cc(["position:relative;overflow-x:hidden;overflow-y:auto;height:100%;scroll-behavior:smooth;&::before,&::after{content:'';position:relative;left:0;z-index:1;display:block;height:",";}&::before{margin:calc("," * -1) calc("," * -1) 0;background:linear-gradient( to bottom,",","," 50%,rgb(255 255 255 / 0) );}&::after{margin:0 calc("," * -1) calc("," * -1);background:linear-gradient( to top,",","," 50%,rgb(255 255 255 / 0) );}"],jl.spacing5,jl.spacing5,jl.spacing6,jl.gray10,jl.gray10,jl.spacing6,jl.spacing5,jl.gray10,jl.gray10)),Nu=wc.div.withConfig({displayName:"ContentExpander",componentId:"zvdl8u-59"})(["min-height:100%;"]),Iu=wc.div.withConfig({displayName:"FooterStyled",componentId:"zvdl8u-60"})(["display:flex;flex:none;padding:",";"],jl.spacing6),Ou=wc.div.withConfig({displayName:"ActionsRight",componentId:"zvdl8u-61"})(["margin-left:auto;"]),Au=wc.div.withConfig({displayName:"CloseButton",componentId:"zvdl8u-62"})(["position:absolute;top:",";right:",";"],jl.spacing5,jl.spacing4),Pu=t.createContext({fullScreen:!1,hideCloseIcon:!1});function Bu({isOpen:e,onClose:n,isFullScreen:r=!1,isCloseButtonHidden:o=!1,closeButtonTitle:i="Close",isClosedOnOverlayClick:a=!1,children:s,container:c}){const l={root:"b-modal",overlay:"b-modal__overlay",modalContainer:"b-modal__container",modal:`b-modal__modal ${r?"b-modal__modal--full-screen":""}`,modalAnimationIn:"b-modal-container-in",modalAnimationOut:"b-modal-container-out",overlayAnimationIn:"b-modal-overlay-in",overlayAnimationOut:"b-modal-overlay-out"},u=!o;return t.createElement(Pu.Provider,{value:{fullScreen:r,hideCloseIcon:o}},t.createElement(Ll,{open:e,onClose:n,classNames:l,animationDuration:200,showCloseIcon:!1,closeOnEsc:u,closeOnOverlayClick:a,container:c},s,u&&t.createElement(Au,null,t.createElement(yu,{variant:"clean",icon:t.createElement(fl,null),"aria-label":i,title:i,onClick:n}))),t.createElement(bu,null))}function Ru({isOpen:e,onClose:n,isFullScreen:r,isCloseButtonHidden:o,isClosedOnOverlayClick:i,closeButtonTitle:a,title:s,secondaryInfo:c,thumbnail:l,children:u,actionPrimary:d,actionSecondary:p,container:f}){return t.createElement(Bu,{isOpen:e,onClose:n,isClosedOnOverlayClick:i,isCloseButtonHidden:o,isFullScreen:r,closeButtonTitle:a,container:f},t.createElement(Bu.Header,{title:s,secondaryInfo:c,thumbnail:l}),t.createElement(Bu.Content,null,u),d&&t.createElement(Bu.Footer,{actionPrimary:d,actionSecondary:p}))}function Fu(e){return t.createElement(Ru,Object.assign({},e))}Bu.Header=function({title:e,secondaryInfo:n,thumbnail:r,backButton:o}){const{hideCloseIcon:a}=i(Pu);return t.createElement(xu,{hideCloseIcon:a},o&&t.createElement(_u,null,t.createElement(yu,Object.assign({variant:"clean",icon:t.createElement(ul,null),"aria-label":o.title},o))),r&&t.createElement(wu,null,r),t.createElement(Su,null,t.createElement(Eu,null,e),n&&t.createElement(ku,null,n)))},Bu.Content=function({children:e}){const{fullScreen:n}=i(Pu);return t.createElement(Cu,{scrollable:n},t.createElement(Tu,{scrollable:n},n?t.createElement(Nu,null,e):e))},Bu.Footer=function({actionPrimary:e,actionSecondary:n,actionTertiary:r}){return t.createElement(Iu,null,r,t.createElement(Ou,null,t.createElement(au,{gap:"5"},n,e)))},wc.div.withConfig({displayName:"NotificationPositionStyled",componentId:"zvdl8u-63"})(["position:absolute;bottom:0;left:0;z-index:",";opacity:",";transition:all 0.2s ease-out;transform:translateY(","px) translate3d(0,",",0) translateX(",");will-change:transform,opacity;"],e=>e.isVisible?"9999":void 0,e=>e.isExists?"1":"0",e=>-1*e.offset,e=>e.isItJustAdded?"calc(100% + 16px)":"0",e=>e.isDismissed?"-100%":"0"),wc.div.withConfig({displayName:"NotificationsStyled",componentId:"zvdl8u-64"})(["position:fixed;bottom:",";left:",";z-index:9999;"],jl.spacing6,jl.spacing6),wc.div.withConfig({shouldForwardProp:(e,t)=>!["shape"].includes(e)&&t(e)}).withConfig({displayName:"ThumbnailContainer",componentId:"zvdl8u-65"})(["position:relative;overflow:hidden;border-radius:",";"," ",""],e=>"circle"===e.shape?jl.radiusCircle:jl.brandRadiusBase,e=>e.hasCheckers&&cc(["background:url(\"data:image/svg+xml,%3Csvg width='8' height='8' xmlns='http://www.w3.org/2000/svg'%3E%3Crect height='8' width='8' y='0' x='0' fill='%23ffffff'/%3E%3Crect height='4' width='4' y='0' x='0' fill='%23e9ecee'/%3E%3Crect height='4' width='4' y='4' x='4' fill='%23e9ecee'/%3E%3C/svg%3E%0A\");"]),e=>{const t={xs:"24px",s:"32px",m:"40px",l:"64px"}[e.size];return cc(["width:",";height:",";"],t,t)}),wc.div.withConfig({displayName:"Fill1",componentId:"zvdl8u-66"})(["display:flex;align-items:center;justify-content:center;width:100%;height:100%;background:50% 50% no-repeat;background-color:",";background-image:",";background-size:cover;color:",";"],e=>e.backgroundColor,e=>e.imageUrl?`url(${e.imageUrl}) `:void 0,e=>e.iconColor),wc.div.withConfig({shouldForwardProp:(e,t)=>!["shape"].includes(e)&&t(e)}).withConfig({displayName:"InnerShadow",componentId:"zvdl8u-67"})(["position:absolute;top:0;left:0;box-sizing:border-box;width:100%;height:100%;border:1px solid ",";border-radius:",";"],jl.gray100a,e=>"circle"===e.shape?jl.radiusCircle:jl.brandRadiusBase),wc.div.withConfig({displayName:"NoImage",componentId:"zvdl8u-68"})(["width:80%;height:2px;border-radius:2px;background:",";transform:rotate(-45deg);"],jl.red500),wc.div.withConfig({displayName:"BaloonStyled",componentId:"zvdl8u-69"})(["",";position:relative;display:flex;align-items:flex-start;overflow:hidden;box-sizing:border-box;width:480px;padding:",";border-radius:",";background:",";box-shadow:",",",";"],Ml,jl.spacing5,jl.radiusLarge,jl.white,jl.elevationStatic,jl.elevation2),wc.div.withConfig({displayName:"ThumbnailWrapper",componentId:"zvdl8u-70"})(["flex:none;margin-right:",";"],jl.spacing5),wc.div.withConfig({displayName:"Text",componentId:"zvdl8u-71"})(["flex:1;align-self:center;"]),wc.h2.withConfig({displayName:"Title1",componentId:"zvdl8u-72"})(["display:-webkit-box;overflow:hidden;margin:0;font:inherit;-webkit-line-clamp:3;-webkit-box-orient:vertical;"]),wc.p.withConfig({displayName:"Description",componentId:"zvdl8u-73"})(["display:-webkit-box;overflow:hidden;margin:"," 0 0;color:",";font-size:",";line-height:20px;-webkit-line-clamp:4;-webkit-box-orient:vertical;"],jl.spacing2,jl.gray500,jl.fontSize75),wc.div.withConfig({displayName:"Action",componentId:"zvdl8u-74"})(["flex:none;"]),wc.div.withConfig({displayName:"Progress1",componentId:"zvdl8u-75"})(["position:absolute;bottom:0;left:0;height:4px;background-color:",";transition:width 0.2s;"],jl.brandPrimary500),wc.div.withConfig({displayName:"Track",componentId:"zvdl8u-76"})(["height:4px;border-radius:",";background:",";"],e=>e.noCornerRadius?"0":jl.radiusPill,e=>e.noBackground?"none":jl.gray100a),wc.div.withConfig({shouldForwardProp:(e,t)=>!["color"].includes(e)&&t(e)}).withConfig({displayName:"Fill",componentId:"zvdl8u-77"})(["max-width:100%;height:100%;border-radius:",";background:",";transition:width 0.2s ease-out;"],e=>e.noCornerRadius?"0":jl.radiusPill,e=>"brand"===e.color?jl.brandPrimary500:jl.gray600),wc.div.withConfig({displayName:"IndicatorPosition",componentId:"zvdl8u-78"})(["display:flex;flex:none;align-items:center;&::before{content:'​';}"]);const zu=wc.div.withConfig({displayName:"Indicator",componentId:"zvdl8u-79"})(["position:relative;display:flex;align-items:center;justify-content:center;box-sizing:border-box;width:16px;height:16px;border:2px solid ",";border-radius:",";background-color:transparent;&::before{content:'';position:absolute;top:-5px;right:-5px;bottom:-5px;left:-5px;border:"," solid transparent;border-color:",";border-radius:",";}"," ",""],jl.gray300,jl.radiusCircle,jl.focusRingWidth,e=>e.isFocusVisible&&jl.focusRingColorPrimary,jl.radiusCircle,e=>e.isChecked&&cc(["border-color:transparent;background-color:",";color:#fff;"],jl.blue500),e=>e.isDisabled&&cc(["border-color:transparent;background-color:",";color:",";"],jl.gray100,jl.gray500));wc.div.withConfig({displayName:"IndicatorMark",componentId:"zvdl8u-80"})(["width:6px;height:6px;border-radius:",";background:currentColor;"],jl.radiusCircle),wc.input.withConfig({displayName:"Input",componentId:"zvdl8u-81"})(["position:absolute;overflow:hidden;clip:rect(0,0,0,0);width:1px;height:1px;margin:0 -1px -1px 0;padding:0;border:0;white-space:nowrap;clip-path:inset(50%);"]),wc.label.withConfig({displayName:"Container2",componentId:"zvdl8u-82"})([""," display:flex;align-items:flex-start;margin:0;padding:"," 0;cursor:",";user-select:none;&:hover ","{","}"],ql.uiTextM,jl.spacing1,e=>!e.isDisabled&&"pointer",zu,e=>{if(!e.isDisabled)return e.isChecked?cc(["background-color:",";"],jl.blue600):cc(["border-color:",";"],jl.gray500)}),wc.div.withConfig({displayName:"Label",componentId:"zvdl8u-83"})(["display:block;margin-left:8px;color:",";"],e=>e.isDisabled?jl.gray400:jl.colorText),wc.aside.withConfig({displayName:"Container1",componentId:"zvdl8u-84"})(["overflow-y:auto;box-sizing:border-box;width:272px;height:100%;padding:"," 0;border-right:1px solid ",";background:",";"],jl.spacing5,jl.gray100,jl.white),wc.div.withConfig({displayName:"TooltipContainer",componentId:"zvdl8u-85"})([""," display:flex;max-width:240px;padding:calc("," / 2) ",";border-radius:",";background:",";color:",";"],ql.uiTextS,jl.spacing4,jl.spacing4,jl.radiusBase,jl.gray900a,jl.gray10),wc.span.withConfig({displayName:"IconContainer",componentId:"zvdl8u-86"})(["display:flex;align-items:center;width:24px;height:24px;margin:-"," "," -"," -",";color:",";"],jl.spacing1,jl.spacing2,jl.spacing1,jl.spacing2,jl.gray400),wc.span.withConfig({displayName:"LabelContainer",componentId:"zvdl8u-87"})(["margin-right:",";color:",";"],jl.spacing2,jl.gray400),wc.div.withConfig({displayName:"VerticalLabelContainer",componentId:"zvdl8u-88"})(["color:",";"],jl.gray400),wc.div.withConfig({displayName:"LeftIconContainer",componentId:"zvdl8u-89"})(["margin-right:",";*{max-width:24px;max-height:24px;}"],jl.spacing4),wc.div.withConfig({displayName:"RightElementIcon",componentId:"zvdl8u-90"})(["margin-left:",";&:last-child{margin-right:calc("," * -1);}"],jl.spacing3,jl.spacing2);const Lu=wc.div.withConfig({displayName:"RightElementText",componentId:"zvdl8u-91"})(["display:flex;align-items:center;justify-content:flex-end;margin-left:",";color:",";text-align:right;"],jl.spacing4,jl.gray400);wc.div.withConfig({displayName:"RightElementsContainer",componentId:"zvdl8u-92"})(["display:flex;align-items:center;margin-left:auto;"]);const ju=cc(["background-color:",";color:",";","{color:",";}"],jl.gray50,jl.gray800,Lu,jl.gray600);function Mu(e){var n;return t.createElement(Fu,{title:ma("Send error report"),isOpen:e.isOpen,onClose:e.onCancel,actionPrimary:t.createElement(ha,{kind:"Primary",title:ma("Send report"),className:"ml-2",onClick:e.onDone},ma("Send report")),actionSecondary:t.createElement(ha,{"data-testid":"bla",kind:"Secondary",title:ma("Cancel"),onClick:e.onCancel},ma("Cancel")),container:e.container},t.createElement("div",{className:"leading-6"},ma("We have created a report that you can send us to help us prevent this from happening in the future.")),t.createElement("div",{className:"my-4 flex-grow self-stretch bg-ui-400 rounded border border-ui-600 px-4 py-3 leading-6 overflow-scroll",style:{maxHeight:200},"data-testid":"error-stack"},null===(n=e.error.stack)||void 0===n?void 0:n.split("\n").map((function(e){return t.createElement(t.Fragment,{key:e},e,t.createElement("br",null))}))),t.createElement("span",{className:"text-body-400 text-sm leading-5"},ma("We will treat this report as confidential and anonymous.")))}function Du(e){var n=e.error,o=e.onRetry,i=oa(),s=r(!1),c=s[0],l=s[1],u=r(!1),d=u[0],p=u[1];return a((function(){ta.error(n)}),[n]),t.createElement("div",{className:"w-full h-full flex flex-col items-center justify-center bg-ui-0 font-sans\n text-base text-body-500"},t.createElement(ba,{isReportSent:d,onClickSend:function(){l(!0)},onClickRetry:o}),t.createElement(Mu,{isOpen:c,error:n,container:i,onDone:function(){oi(n),l(!1),p(!0)},onCancel:function(){l(!1)}}))}function Hu(){var e=pr(kr()[0].page),n=e[0],r=e[1],o=fa("w-6 h-6 -mx-1","ASC"===n.direction&&"flip-y"),i={ASC:ma("Ascending"),DESC:ma("Descending")},a={ASC:"DESC",DESC:"ASC"};return t.createElement(ha,{kind:"FlatSm",title:i[n.direction],onClick:function(){r({field:n.field,direction:a[n.direction]})}},t.createElement(tl,{className:o}))}function Uu(e){var n=l(null),o=r(0)[1];!function(e,t){var n=oa();a((function(){function r(n){var r=n.target;e.map((function(e){return null==e?void 0:e.current})).some((function(e){return e&&e.contains(r)}))||t()}return null==n||n.addEventListener("mousedown",r),function(){return null==n?void 0:n.removeEventListener("mousedown",r)}}),[e,t,n])}([e.target,n],e.onClickOutside),u((function(){o(null!==e.target.current?e.target.current.getBoundingClientRect().x:0)}),[e.target]);var i=oa();if(null===i||null===e.target.current)return null;var s=e.target.current.getBoundingClientRect(),c=s.x,d=window.innerWidth,p={left:c+300>d?void 0:c,right:c+300>d?d-s.width-c:void 0,top:"Down"===e.direction?s.top+s.height:void 0,bottom:"Up"===e.direction?window.innerHeight-s.top:void 0},f=fa("cv-root cv-dropdown select-none",e.className);return h(t.createElement("div",{className:f,style:p,ref:n},e.children),i)}function qu(e){var n=e.buttonKind,o=void 0===n?"FlatSm":n,i=e.direction,a=void 0===i?"Down":i,s=gr(e,["buttonKind","direction"]),c=r(!1),u=c[0],d=c[1],p=l(null),f=function(){return d((function(e){return!e}))},h=fa(u&&"bg-ui-400 border-ui-700 text-body-500",s.buttonClassName);return t.createElement(t.Fragment,null,t.createElement(ha,{kind:o,onClick:f,className:h,ref:p,isDisabled:s.disabled},t.createElement("span",{className:"inline-flex items-center",title:s.alt},s.title),t.createElement(sl,{className:"w-6 h-6 ml-1 -mr-2"})),u&&t.createElement(Uu,{className:s.className,onClickOutside:f,direction:a,target:p},s.children(f)))}function Vu(e){var n=e.selected,r=void 0!==n&&n,o=gr(e,["selected"]),i=fa("cursor-pointer flex hover:bg-ui-400 hover:text-body-500 items-center transition-color",r?"text-body-500":"text-body-400",o.className);return t.createElement("li",{className:i,onClick:o.onClick,"data-testid":"dropdown-list-item"},o.children,r&&t.createElement(ll,{className:"w-6 h-6 ml-3 fade-in"}))}function Wu(e){var n=e.options,r=void 0===n?["CREATED_AT","PUBLISHED_AT","UPDATED_AT","NAME"]:n,o=pr(kr()[0].page),i=o[0],a=o[1],s={CREATED_AT:ma("Date added"),NAME:ma("Name"),PUBLISHED_AT:ma("Date published"),UPDATED_AT:ma("Date modified")};return t.createElement(qu,{className:"py-2",buttonClassName:"ml-auto",title:s[i.field],alt:ma("Order by")},(function(e){return t.createElement("ul",null,r.map((function(n){return t.createElement(Vu,{className:"px-4 py-px text-sm",selected:i.field===n,key:s[n],onClick:function(){a({field:n,direction:i.direction}),e()}},t.createElement("span",{className:"flex-grow min-w-24 py-2"},s[n]))})))}))}function $u(e,t,n){return(1===e?t:n).replace("{}",e.toString())}function Yu(e){var n=e.alt,r=e.className,o=e.fadeIn,i=void 0===o||o,a=e.id,s=e.style,c=e.stacked,l=void 0!==c&&c,u=e.title,d=e.onClick,p=e.children,f=void 0===p?null:p,h=e.metaproperties,m=gr(e,["alt","className","fadeIn","id","style","stacked","title","onClick","children","metaproperties"]);return t.createElement("div",{className:fa("m-2 w-56 self-start group relative rounded bg-ui-500 shadow transition-shadow\n\t\t\t\t cursor-pointer",i&&"fade-in-down",r),id:a,style:s,title:n,onClick:d,"aria-selected":m["aria-selected"],"data-testid":"asset-card"},t.createElement("div",{className:"overflow-hidden rounded"},t.createElement("div",{className:"flex h-32 relative"},f),t.createElement("div",{className:"p-3 bg-ui-0"},t.createElement("header",{className:"truncate"},u),!!(null==h?void 0:h.length)&&t.createElement("dl",{className:"pt-2 mt-2 border-t border-ui-600 text-body-400 text-sm"},h&&h.map((function(e){var n=e.label,r=e.options.map((function(e){return e.label})).join(", ");return t.createElement("div",{className:"flex flex-wrap pb-1",key:n},t.createElement("dt",{className:"text-body-300 pr-1"},n,":"),t.createElement("dd",{className:""},r))}))))),l&&t.createElement("div",{className:"absolute border-b rounded left-px right-px h-3 -bottom-0.75","data-testid":"stacked"}))}function Gu(e){var n=e.width,r=void 0===n?100:n,o=e.className;return t.createElement("span",{className:fa("cv-skeleton",o),style:{width:r},"data-testid":"skeleton"},"‌")}function Xu(e){return t.createElement(t.Fragment,null,Array(e.rows*e.columns).fill(void 0).map((function(n,r){return t.createElement(Yu,{key:r,style:{animationDuration:Math.round(r/e.columns*200+500)+"ms"},title:t.createElement(t.Fragment,null,t.createElement(Gu,{width:70+Ju(100,r),className:"h-4"}),e.title)})})))}function Ju(e,t){return 16807*((t+20)%2147483647+2147483646)%2147483647%e}function Ku(e){var n=r("None"),o=n[0],i=n[1],a=ca(),s=fa("inline-flex p-0.5 items-center text-md text-body-400 select-none shadow shadow-overlay\n\t\t focus:outline-none transition-color",e.active?"bg-brand-500 hover:bg-brand-600 text-ui-0":"bg-ui-0-.8 hover:bg-ui-0 hover:text-body-500",e.className),c=e.active||"None"!==o?ua(a,"Primary",o):void 0;return t.createElement("button",{className:s,style:c,title:e.title,onClick:e.onClick,onMouseOver:function(){return i("Hover")},onFocus:function(){return i("Hover")},onMouseOut:function(){return i("None")},onBlur:function(){return i("None")},type:"button"},e.children)}function Zu(e){return{tag:"ok",value:e}}function Qu(e){return{tag:"error",error:e}}function ed(e){return"ok"===e.tag}function td(e){return"error"===e.tag}function nd(e){return"https://"+e.replace(/^https?:\/\//i,"").replace(/\/+$/i,"")+"/"}wc.a.withConfig({displayName:"StyledNavItem",componentId:"zvdl8u-93"})(["&&{"," display:flex;align-items:center;box-sizing:border-box;width:100%;height:40px;margin:0;padding:"," ",";border:0;border-radius:",";background:none;color:",";outline:none;font-family:",";text-decoration:none;cursor:",";&:hover{background-color:",";color:",";","{color:",";}}&:active{","}"," "," ",";}"],ql.uiTextM,jl.spacing3,jl.spacing4,jl.brandRadiusBase,jl.gray600,jl.brandFontStackBase,e=>e.disabled?"default":"pointer",jl.gray25,jl.gray800,Lu,jl.gray600,ju,e=>e.isSelected&&ju,e=>e.isFocusVisible&&cc(["background-color:",";color:",";","{color:",";}"],jl.gray25,jl.gray800,Lu,jl.gray600),e=>e.disabled&&cc(["background-color:inherit;color:",";pointer-events:none;","{color:",";}"],jl.gray400,Lu,jl.gray400)),wc.div.withConfig({displayName:"ItemTitle",componentId:"zvdl8u-94"})(["overflow:hidden;text-decoration:none;text-overflow:ellipsis;white-space:nowrap;"]),wc.hr.withConfig({displayName:"Divider",componentId:"zvdl8u-95"})(["height:1px;margin:",";border:0;background-color:",";"],jl.spacing4,jl.gray50),wc.div.withConfig({displayName:"StyledTitleContainer",componentId:"zvdl8u-96"})(["",";display:flex;align-items:center;box-sizing:border-box;height:32px;padding:0 ",";color:",";"],ql.uiTextS,jl.spacing4,jl.gray800),wc.div.withConfig({displayName:"StyledTitle",componentId:"zvdl8u-97"})(["overflow:hidden;text-decoration:none;text-overflow:ellipsis;white-space:nowrap;"]),wc.div.withConfig({displayName:"Container",componentId:"zvdl8u-98"})(["margin:0 ",";"],jl.spacing5);var rd=new Map;function od(e,t,n){return vr(this,void 0,void 0,(function(){var r,o,i,a,s,c;return yr(this,(function(l){switch(l.label){case 0:if(!n)return[2,Qu("No authentication provided")];if("/"===(r=void 0!==n.accountDomain?nd(n.accountDomain.trim()):"https://"+window.location.host).charAt(r.length-1)&&(r=r.slice(0,-1)),o=r+":"+e+":"+JSON.stringify(t)+":"+n.accessToken,rd.has(o))return[2,Zu(rd.get(o))];i={Accept:"application/json","Content-Type":"application/json","X-Bynder-Integration":"UCV/v2.6.0"},a=void 0===(null==n?void 0:n.accessToken)?i:mr(mr({},i),{Authorization:"Bearer "+n.accessToken}),s={method:"post",headers:a,body:JSON.stringify({query:e,variables:t})},l.label=1;case 1:return l.trys.push([1,4,,5]),[4,fetch(r+"/graphql",s)];case 2:return[4,l.sent().json()];case 3:return c=l.sent(),[3,5];case 4:return[2,Qu(l.sent())];case 5:return void 0!==c.errors?[2,Qu(c.errors.map((function(e){return e.message})).join(","))]:(rd.set(o,c.data),rd.size>50&&rd.delete(rd.keys().next().value),[2,Zu(c.data)])}}))}))}function id(e){var t;if(!(null===(t=window.crypto)||void 0===t?void 0:t.subtle))return Promise.reject("Access to the WebCrypto API is restricted to secure origins. Compact View requires HTTPS when used outside localhost (for development).");var n=(new TextEncoder).encode(e);return window.crypto.subtle.digest("SHA-256",n)}function ad(){var e=new Uint32Array(28),t=window.crypto.getRandomValues(e);return Array.from(t).map((function(e){return("0"+e.toString(16)).substr(-2)})).join("")}var sd="42b1eefa-d754-4802-b9c4-bf80d6ab6052",cd="https://d8ejoa1fys2rk.cloudfront.net/5.0.5/modules/compactview/loginCompleted.html",ld=["offline","asset:read","collection:read","meta.assetbank:read"];function ud(e,t,n){return vr(this,void 0,void 0,(function(){var r,o,i,a;return yr(this,(function(s){switch(s.label){case 0:r=dd(n)+"token",o=new URLSearchParams({client_id:sd,code_verifier:t,code:e,redirect_uri:cd,grant_type:"authorization_code"}),s.label=1;case 1:return s.trys.push([1,4,,5]),[4,fetch(r,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"},body:o})];case 2:return(i=s.sent()).ok?[4,i.json()]:[2,Qu("Failed to fetch access token: "+i.status)];case 3:return[2,Zu({refreshToken:(a=s.sent()).refresh_token,accessToken:a.access_token,expiresIn:a.expires_in})];case 4:return[2,Qu(s.sent().toString())];case 5:return[2]}}))}))}function dd(e){return"webdam"===pd()?"https://apiv2.webdamdb.com/oauth2/":nd(e)+"v6/authentication/oauth2/"}function pd(){var e;return null!==(e=localStorage.getItem("cvp"))&&void 0!==e?e:void 0}function fd(e){return vr(this,void 0,void 0,(function(){var t,n,r,o,i,a;return yr(this,(function(s){switch(s.label){case 0:return t=window.screen,n=t.width/2-285+window.screenX,r=t.height/2-350+window.screenY,null===(o=window.open("","Bynder Brand Portal","height=700,width=570,left="+n+",top="+r))?[2,Qu("Error opening login window")]:(o.document.head.innerHTML=hd,o.document.body.innerHTML=md,o.location.href=e,[4,Promise.race([new Promise((function(e){window.addEventListener("message",(function(t){"https://d8ejoa1fys2rk.cloudfront.net"===t.origin&&e(Zu(t))}))})),new Promise((function(e){setTimeout((function(){return e(Qu("Timeout"))}),6e5)})),(c=o,new Promise((function(e){var t=setInterval((function(){c.closed&&(clearInterval(t),e(Qu("Login window closed")))}),1e3)})))])]);case 1:return td(i=s.sent())?[2,i]:[2,Zu({state:(a=new URLSearchParams(i.value.data)).get("state"),code:a.get("code")})]}var c}))}))}var hd='\n<title>Redirecting...</title>\n<style>\n @keyframes cv-spinner-animation {\n to {\n transform:rotate(1turn)\n }\n }\n\n .cv-spinner {\n position: relative;\n display: inline-block;\n padding: 175px 0 100px;\n width: 100%;\n height: auto;\n background: #fff;\n box-sizing: border-box;\n }\n \n .cv-spinner:before {\n position: absolute;\n top: 50%;\n left: 50%;\n width: 40px;\n height: 40px;\n margin-top: -20px;\n margin-left: -20px;\n box-sizing: border-box;\n border-top: 3px solid #7e8890;\n border-right: 3px solid transparent;\n border-radius: 50%;\n content: "";\n animation: cv-spinner-animation .8s linear infinite;\n z-index: 3;\n }\n</style>',md='<div class="cv-spinner"></div>';function gd(e){var n=oa();return t.createElement(Qs,{target:n,disableVendorPrefixes:!0},t.createElement(tu,null,e.children))}function vd(e){var n=e.children,o=t.useRef(null),i=r(null),s=i[0],c=i[1];return a((function(){if(null!==o.current){var e,t=function(e){try{return e.attachShadow({mode:"open"})}catch(e){return null}}(o.current);yd(null!=(e=t)?e:document.head,'@import url(https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/css/vendor/font-awesome.min.css);/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%}body{margin:0}main{display:block}h1{font-size:2em;margin:.67em 0}a{background-color:transparent}b{font-weight:bolder}code{font-family:monospace,monospace;font-size:1em}small{font-size:80%}img{border-style:none}button,input,select{font-family:inherit;font-size:100%;line-height:1.15;margin:0}button,input{overflow:visible}button,select{text-transform:none}[type=button],[type=reset],button{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}[type=button]:-moz-focusring,[type=reset]:-moz-focusring,button:-moz-focusring{outline:1px dotted ButtonText}progress{vertical-align:baseline}[type=checkbox]{-webkit-box-sizing:border-box;box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-decoration{-webkit-appearance:none}[hidden]{display:none}dd,dl,h1{margin:0}button{background-color:transparent;background-image:none;padding:0}button:focus{outline:1px dotted;outline:5px auto -webkit-focus-ring-color}ul{list-style:none;margin:0;padding:0}html{font-family:SourceSansPro,Source Sans Pro,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}*,:after,:before{-webkit-box-sizing:border-box;box-sizing:border-box;border:0 solid rgba(0,34,51,.1)}img{border-style:solid}input::-webkit-input-placeholder{color:#a0aec0}input::-moz-placeholder{color:#a0aec0}input:-ms-input-placeholder{color:#a0aec0}input::-ms-input-placeholder{color:#a0aec0}input::placeholder{color:#a0aec0}[role=button],button{cursor:pointer}h1{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}button,input,select{padding:0;line-height:inherit;color:inherit}code{font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}audio,img,object,svg,video{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}.container{width:100%}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}.appearance-none{-webkit-appearance:none;-moz-appearance:none;appearance:none}.bg-brand-500{background-color:#0af}.bg-ui-0{background-color:#fff}.bg-ui-400{background-color:rgba(0,34,51,.03)}.bg-ui-500{background-color:rgba(0,34,51,.05)}.bg-ui-600{background-color:rgba(0,34,51,.1)}.bg-ui-800{background-color:rgba(0,34,51,.2)}.bg-ui-900{background-color:rgba(0,34,51,.35)}.bg-ui-0-\\.8{background-color:hsla(0,0%,100%,.8)}.hover\\:bg-brand-600:hover{background-color:#008ed5}.hover\\:bg-ui-0:hover{background-color:#fff}.hover\\:bg-ui-400:hover{background-color:rgba(0,34,51,.03)}.focus\\:bg-ui-500:focus,.hover\\:bg-ui-500:hover{background-color:rgba(0,34,51,.05)}.active\\:bg-brand-700:active{background-color:#008dd5}.active\\:bg-ui-700:active{background-color:rgba(0,34,51,.15)}.disabled\\:bg-ui-500:disabled{background-color:rgba(0,34,51,.05)}.border-transparent{border-color:transparent}.border-error{border-color:#f4562b}.border-brand-500{border-color:#0af}.border-ui-600{border-color:rgba(0,34,51,.1)}.border-ui-700{border-color:rgba(0,34,51,.15)}.hover\\:border-ui-900:hover{border-color:rgba(0,34,51,.35)}.focus\\:border-ui-700:focus{border-color:rgba(0,34,51,.15)}.focus\\:border-ui-900:focus{border-color:rgba(0,34,51,.35)}.disabled\\:border-ui-500:disabled{border-color:rgba(0,34,51,.05)}.rounded{border-radius:5px}.rounded-full{border-radius:9999px}.border-2{border-width:2px}.border{border-width:1px}.border-t{border-top-width:1px}.border-b{border-bottom-width:1px}.last\\:border-b-0:last-child{border-bottom-width:0}.cursor-default{cursor:default}.cursor-pointer{cursor:pointer}.cursor-wait{cursor:wait}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:-webkit-box;display:-ms-flexbox;display:flex}.inline-flex{display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.grid{display:grid}.hidden{display:none}.group:hover .group-hover\\:block{display:block}.flex-col{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.flex-wrap{-ms-flex-wrap:wrap;flex-wrap:wrap}.items-center{-webkit-box-align:center;-ms-flex-align:center;align-items:center}.self-start{-ms-flex-item-align:start;align-self:flex-start}.self-stretch{-ms-flex-item-align:stretch;align-self:stretch}.justify-center{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.justify-between{-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between}.flex-1{-webkit-box-flex:1;-ms-flex:1 1 0%;flex:1 1 0%}.flex-grow{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.flex-shrink-0{-ms-flex-negative:0;flex-shrink:0}.font-sans{font-family:SourceSansPro,Source Sans Pro,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}.font-semibold{font-weight:600}.h-3{height:12px}.h-4{height:16px}.h-5{height:20px}.h-6{height:24px}.h-8{height:32px}.h-10{height:40px}.h-12{height:48px}.h-16{height:64px}.h-20{height:80px}.h-32{height:128px}.h-40{height:160px}.h-2\\/4{height:50%}.h-full{height:100%}.leading-5{line-height:1.25rem}.leading-6{line-height:1.5rem}.m-2{margin:8px}.my-2{margin-top:8px;margin-bottom:8px}.mx-2{margin-left:8px;margin-right:8px}.my-4{margin-top:16px;margin-bottom:16px}.my-px{margin-top:1px;margin-bottom:1px}.-mx-1{margin-left:-4px;margin-right:-4px}.-my-2{margin-top:-8px;margin-bottom:-8px}.mt-1{margin-top:4px}.mr-1{margin-right:4px}.ml-1{margin-left:4px}.mt-2{margin-top:8px}.mr-2{margin-right:8px}.mb-2{margin-bottom:8px}.ml-2{margin-left:8px}.mt-3{margin-top:12px}.mr-3{margin-right:12px}.ml-3{margin-left:12px}.mt-4{margin-top:16px}.mr-4{margin-right:16px}.mb-4{margin-bottom:16px}.mr-5{margin-right:20px}.mt-6{margin-top:24px}.mt-8{margin-top:32px}.mb-8{margin-bottom:32px}.mt-10{margin-top:40px}.mr-auto{margin-right:auto}.ml-auto{margin-left:auto}.ml-px{margin-left:1px}.-mr-1{margin-right:-4px}.-mr-2{margin-right:-8px}.max-w-24{max-width:96px}.max-w-32{max-width:128px}.min-w-24{min-width:96px}.object-contain{-o-object-fit:contain;object-fit:contain}.object-cover{-o-object-fit:cover;object-fit:cover}.disabled\\:opacity-60:disabled{opacity:.6}.focus\\:outline-none:focus{outline:0}.overflow-hidden{overflow:hidden}.overflow-scroll{overflow:scroll}.overflow-y-auto{overflow-y:auto}.p-3{padding:12px}.p-4{padding:16px}.p-0\\.5{padding:2px}.py-1{padding-top:4px;padding-bottom:4px}.py-2{padding-top:8px;padding-bottom:8px}.px-2{padding-left:8px;padding-right:8px}.py-3{padding-top:12px;padding-bottom:12px}.px-3{padding-left:12px;padding-right:12px}.py-4{padding-top:16px;padding-bottom:16px}.px-4{padding-left:16px;padding-right:16px}.px-6{padding-left:24px;padding-right:24px}.py-px{padding-top:1px;padding-bottom:1px}.pr-0{padding-right:0}.pl-0{padding-left:0}.pr-1{padding-right:4px}.pb-1{padding-bottom:4px}.pt-2{padding-top:8px}.pb-2{padding-bottom:8px}.pl-3{padding-left:12px}.pt-4{padding-top:16px}.pr-4{padding-right:16px}.pl-4{padding-left:16px}.pr-5{padding-right:20px}.pr-10{padding-right:40px}.pl-10{padding-left:40px}.placeholder-body-300::-webkit-input-placeholder{color:rgba(0,34,51,.3)}.placeholder-body-300::-moz-placeholder{color:rgba(0,34,51,.3)}.placeholder-body-300:-ms-input-placeholder{color:rgba(0,34,51,.3)}.placeholder-body-300::-ms-input-placeholder{color:rgba(0,34,51,.3)}.placeholder-body-300::placeholder{color:rgba(0,34,51,.3)}.disabled\\:pointer-events-none:disabled,.pointer-events-none{pointer-events:none}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-0{right:0;left:0}.inset-0,.inset-y-0{top:0;bottom:0}.top-0{top:0}.right-0{right:0}.bottom-0{bottom:0}.left-0{left:0}.top-3{top:12px}.right-3{right:12px}.right-4{right:16px}.right-px{right:1px}.left-px{left:1px}.-bottom-0\\.75{bottom:-3px}.resize{resize:both}.shadow{-webkit-box-shadow:0 1px 6px 0 rgba(0,34,51,.1),0 0 0 1px rgba(0,34,51,.1);box-shadow:0 1px 6px 0 rgba(0,34,51,.1),0 0 0 1px rgba(0,34,51,.1)}.shadow-outline{-webkit-box-shadow:0 0 0 2px #0af;box-shadow:0 0 0 2px #0af}.shadow-border{-webkit-box-shadow:0 1px 6px -2px rgba(0,34,51,.1);box-shadow:0 1px 6px -2px rgba(0,34,51,.1)}.shadow-fade-left{-webkit-box-shadow:-16px 0 10px 0 #fff;box-shadow:-16px 0 10px 0 #fff}.shadow-fade-right{-webkit-box-shadow:4px 0 13px 13px #fff;box-shadow:4px 0 13px 13px #fff}.shadow-footer{-webkit-box-shadow:0 -1px 0 0 rgba(0,34,51,.1),0 -1px 6px 0 rgba(0,34,51,.1);box-shadow:0 -1px 0 0 rgba(0,34,51,.1),0 -1px 6px 0 rgba(0,34,51,.1)}.shadow-overlay{-webkit-box-shadow:0 4px 10px 0 rgba(0,34,51,.1);box-shadow:0 4px 10px 0 rgba(0,34,51,.1)}.shadow-modal{-webkit-box-shadow:0 2px 12px 0 rgba(0,34,51,.1);box-shadow:0 2px 12px 0 rgba(0,34,51,.1)}.active\\:shadow-inner:active{-webkit-box-shadow:inset 0 1px 3px 0 rgba(0,34,51,.1);box-shadow:inset 0 1px 3px 0 rgba(0,34,51,.1)}.active\\:shadow-fade-left:active{-webkit-box-shadow:-16px 0 10px 0 #fff;box-shadow:-16px 0 10px 0 #fff}.active\\:shadow-fade-right:active{-webkit-box-shadow:4px 0 13px 13px #fff;box-shadow:4px 0 13px 13px #fff}.fill-current{fill:currentColor}.text-center{text-align:center}.text-right{text-align:right}.text-error{color:#f4562b}.text-body-300{color:rgba(0,34,51,.3)}.text-body-400{color:rgba(0,34,51,.5)}.text-body-500{color:rgba(0,34,51,.8)}.text-ui-0{color:#fff}.focus-within\\:text-body-400:focus-within{color:rgba(0,34,51,.5)}.hover\\:text-body-400:hover{color:rgba(0,34,51,.5)}.active\\:text-body-500:active,.focus\\:text-body-500:focus,.hover\\:text-body-500:hover{color:rgba(0,34,51,.8)}.disabled\\:text-body-300:disabled{color:rgba(0,34,51,.3)}.text-xs{font-size:12px}.text-sm{font-size:14px}.text-base{font-size:16px}.text-xl{font-size:20px}.text-2xl{font-size:22px}.uppercase{text-transform:uppercase}.lowercase{text-transform:lowercase}.capitalize{text-transform:capitalize}.select-none{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.visible{visibility:visible}.invisible{visibility:hidden}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.w-5{width:20px}.w-6{width:24px}.w-10{width:40px}.w-40{width:160px}.w-48{width:192px}.w-56{width:224px}.w-80{width:320px}.w-2\\/4{width:50%}.w-full{width:100%}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.transform{--transform-translate-x:0;--transform-translate-y:0;--transform-rotate:0;--transform-skew-x:0;--transform-skew-y:0;--transform-scale-x:1;--transform-scale-y:1;-webkit-transform:translateX(var(--transform-translate-x)) translateY(var(--transform-translate-y)) rotate(var(--transform-rotate)) skewX(var(--transform-skew-x)) skewY(var(--transform-skew-y)) scaleX(var(--transform-scale-x)) scaleY(var(--transform-scale-y));transform:translateX(var(--transform-translate-x)) translateY(var(--transform-translate-y)) rotate(var(--transform-rotate)) skewX(var(--transform-skew-x)) skewY(var(--transform-skew-y)) scaleX(var(--transform-scale-x)) scaleY(var(--transform-scale-y))}.transition-shadow{-webkit-transition-property:-webkit-box-shadow;transition-property:-webkit-box-shadow;transition-property:box-shadow;transition-property:box-shadow,-webkit-box-shadow}.transition-transform{-webkit-transition-property:-webkit-transform;transition-property:-webkit-transform;transition-property:transform;transition-property:transform,-webkit-transform}@keyframes fade-in{0%{opacity:0}to{opacity:1}}@keyframes fade-in-down{0%{opacity:0;-webkit-transform:translateY(-2px);transform:translateY(-2px)}to{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes border-rotate{to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes border-dash{0%{stroke-dasharray:1,100;stroke-dashoffset:0}50%{stroke-dasharray:80,100;stroke-dashoffset:-20}to{stroke-dasharray:80,100;stroke-dashoffset:-48}}.transition-shadow{-webkit-transition:-webkit-box-shadow .1s linear;transition:-webkit-box-shadow .1s linear;transition:box-shadow .1s linear;transition:box-shadow .1s linear,-webkit-box-shadow .1s linear}.transition-color{-webkit-transition:color .05s linear,background-color .05s linear,border-color .05s linear,opacity .05s linear;transition:color .05s linear,background-color .05s linear,border-color .05s linear,opacity .05s linear}.transition-transform{-webkit-transition:-webkit-transform .6s cubic-bezier(.175,.885,.32,1.15);transition:-webkit-transform .6s cubic-bezier(.175,.885,.32,1.15);transition:transform .6s cubic-bezier(.175,.885,.32,1.15);transition:transform .6s cubic-bezier(.175,.885,.32,1.15),-webkit-transform .6s cubic-bezier(.175,.885,.32,1.15)}.cv-root{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;background-color:#fff;font-family:SourceSansPro,Source Sans Pro,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-size:16px;color:rgba(0,34,51,.8);-webkit-box-sizing:border-box;box-sizing:border-box}.cv-root *,.cv-root :after,.cv-root :before{-webkit-box-sizing:inherit;box-sizing:inherit}.cv-container{overflow:hidden;width:100%;height:100%}.cv-container nav:last-of-type{-webkit-box-shadow:0 1px 0 0 rgba(0,34,51,.1),0 1px 6px 0 rgba(0,34,51,.1);box-shadow:0 1px 0 0 rgba(0,34,51,.1),0 1px 6px 0 rgba(0,34,51,.1)}.cv-dropdown{position:fixed;border-width:1px;border-color:rgba(0,34,51,.1);-webkit-animation:fade-in-down .15s ease-out;animation:fade-in-down .15s ease-out;margin-top:4px;margin-bottom:4px;overflow-y:auto;border-radius:5px;-webkit-box-shadow:0 4px 10px 0 rgba(0,34,51,.1);box-shadow:0 4px 10px 0 rgba(0,34,51,.1);z-index:9999999;-webkit-transition:left .1s ease-out;transition:left .1s ease-out}.card-list{padding-left:8px;padding-right:8px;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;-ms-flex-line-pack:start;align-content:flex-start;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.max-h-400{max-height:400px}.max-w-600{max-width:600px}.flip-y{-webkit-transform:scaleY(-1);transform:scaleY(-1)}.spinner{-webkit-animation:border-rotate 1s linear infinite;animation:border-rotate 1s linear infinite;z-index:2;position:absolute;top:50%;left:50%;margin:-10px 0 0 -10px;width:20px;height:20px}.spinner circle{stroke:currentColor;stroke-linecap:round;-webkit-animation:border-dash 1.5s ease-in-out infinite;animation:border-dash 1.5s ease-in-out infinite}.fade-in{-webkit-animation:fade-in .15s ease-out;animation:fade-in .15s ease-out}.fade-in-down{-webkit-animation:fade-in-down .15s ease-out;animation:fade-in-down .15s ease-out}.group:hover .group-hover\\:fade-in{-webkit-animation:fade-in .15s ease-out;animation:fade-in .15s ease-out}.animation-duration-500{-webkit-animation-duration:.5s;animation-duration:.5s}.selected-outline{-webkit-box-shadow:0 0 0 2px #0af;box-shadow:0 0 0 2px #0af}.cv-skeleton{overflow:hidden;display:inline-block;position:relative;border-radius:4px;background-color:rgba(0,34,51,.05)}.cv-skeleton:before{position:absolute;height:100%;top:0;-webkit-animation:cv-skeleton-progress 1.5s ease-in-out infinite;animation:cv-skeleton-progress 1.5s ease-in-out infinite;content:"";width:500px;left:-500px;background-image:-webkit-gradient(linear,left top,right top,from(hsla(0,0%,100%,0)),color-stop(hsla(0,0%,100%,.6)),to(hsla(0,0%,100%,0)));background-image:linear-gradient(90deg,hsla(0,0%,100%,0),hsla(0,0%,100%,.6),hsla(0,0%,100%,0))}@keyframes cv-skeleton-progress{0%{left:-500px}to{left:100%}}.cbx{border-radius:3px;background-color:#fff;-webkit-box-shadow:inset 0 0 0 1px rgba(0,34,51,.1),inset 0 1px 2px 0 rgba(0,34,51,.15);box-shadow:inset 0 0 0 1px rgba(0,34,51,.1),inset 0 1px 2px 0 rgba(0,34,51,.15);position:relative;-ms-flex-negative:0;flex-shrink:0;height:13px;-webkit-transition:background-color .15s linear;transition:background-color .15s linear;width:13px}.cbx svg{position:absolute;top:2px;left:2px;height:8px;width:10px;fill:none;-webkit-filter:drop-shadow(0 1px .5px #296bb0);filter:drop-shadow(0 1px .5px #296bb0);stroke-dasharray:17;stroke-dashoffset:17;stroke-linecap:round;stroke-linejoin:round;stroke-width:2.2;stroke:#fff;-webkit-transform:translateZ(0);transform:translateZ(0)}.cbx.cbx--checked{background-color:#0af}.cbx.cbx--checked svg{stroke-dashoffset:0;-webkit-transition:stroke-dashoffset .15s linear;transition:stroke-dashoffset .15s linear}.overlay-pill{position:absolute;margin:12px;padding-left:4px;padding-right:4px;height:20px;border-radius:4px;background-color:rgba(0,34,51,.3);color:#fff;font-size:12px;font-weight:600;line-height:22px}.fa-lg{line-height:1.05em}.z-a-lot{z-index:999999}'),t&&yd(document.head,bd),c(null!=t?t:o.current)}}),[]),t.createElement("div",{ref:o,style:{display:"flex",height:"100%"},"data-testid":"root"},s&&t.createElement(ra,{value:s},t.createElement(gd,null,h(n,s))))}function yd(e,t){var n=document.createElement("style"),r=document.createTextNode(t);n.appendChild(r),e.appendChild(n)}var bd="\n@font-face {\n font-family: 'Source Sans Pro';\n font-style: normal;\n font-weight: 400;\n src: local('Source Sans Pro Regular'),\n local('SourceSansPro-Regular'),\n url('https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/fonts/SourceSans/sourcesanspro-regular.woff2') format('woff2'),\n url('https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/fonts/SourceSans/sourcesanspro-regular.woff') format('woff');\n }\n \n @font-face {\n font-family: \"FontAwesome\";\n src: url(\"https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/fonts/fontawesome-webfont.woff2?v=4.7.0\") format(\"woff2\"),\n url(\"https://d8ejoa1fys2rk.cloudfront.net/5.0.5/includes/fonts/fontawesome-webfont.woff?v=4.7.0\") format(\"woff\");\n font-weight: 400;\n font-style: normal;\n }\n",xd=n("parent");function _d(e){return"parent"===i(xd)?t.createElement(xd.Provider,{value:"child"},t.createElement(vd,null,e.children)):t.createElement(t.Fragment,null,e.children)}var wd=n(null),Sd=function(){return i(wd)};function Ed(e){var n=e.children,i=e.isOpen,s=void 0===i||i,c=e.style,l=e.onClose,u=void 0===l?function(){}:l,d=r(null),p=d[0],f=d[1],m=o((function(){return{onClose:u}}),[u]);return a((function(){var e=document.createElement("div");return document.body.appendChild(e),f(e),function(){e.remove()}}),[]),s?t.createElement(wd.Provider,{value:m},p&&t.createElement(t.Fragment,null,h(t.createElement(_d,null,t.createElement("div",{className:"inset-0 flex items-center p-4 z-a-lot fixed bg-ui-600 fade-in-down"},t.createElement("div",{className:"shadow-modal h-full w-full overflow-hidden rounded",style:c,"data-testid":"modal"},n))),p))):null}function kd(e){var n=Sd();return t.createElement("div",{className:"bg-ui-0 w-full h-full flex flex-col items-center justify-center cv-root relative"},null!==n&&t.createElement(ha,{onClick:n.onClose,title:ma("Close"),className:"absolute top-3 right-4"},t.createElement(fl,{className:"w-6 h-6 -mx-1"})),t.createElement("div",{className:"flex flex-col"},e.children))}function Cd(){return t.createElement("label",{htmlFor:"account-domain-input",className:"text-body-400 mb-8"},ma("Enter the portal domain"))}function Td(){return t.createElement(t.Fragment,null,t.createElement("svg",{viewBox:"0 0 479.438 361.46",className:"w-10 mb-8"},t.createElement("path",{d:"\n\t\t\t\t\t\tM365.18 0a114 114 0 00-85.9 38.93l-153.18 153-43.82-43.84a45.18 45.18\n\t\t\t\t\t\t0 01-11.54-30.75 46.06 46.06 0 0146.34-46.08 44.81 44.81 0 0130.42\n\t\t\t\t\t\t11.49c2.73 2.42 10.48 10.43 10.48 10.43l48.5-48.51-14-14C172.19 11.43\n\t\t\t\t\t\t144.48.03 114.3.03 51.24.03 0 51.03 0 114.1a115.08 115.08 0 0028.09\n\t\t\t\t\t\t75.46l98.35 98.77 205.53-205.5a44.78 44.78 0 0130.58-11.57 46.07 46.07 0\n\t\t\t\t\t\t0146.06 46.43 45.07 45.07 0 01-11.52 30.5l-136.6 136.57a28.73 28.73 0\n\t\t\t\t\t\t01-20.83 8.58 28.29 28.29 0 01-20.51-8.92l-10.27-10.16-48.28 48.28 9.88\n\t\t\t\t\t\t9.72a97.06 97.06 0 0069.38 29.2h.07a96 96 0\n\t\t\t\t\t\t0069-29.13l142.35-142.67A114.47 114.47 0 00365.18 0z",fill:"#0af"})),t.createElement("h1",{className:"text-xl mb-2"},ma("Connect your brand portal")))}function Nd(e){var n=fa("w-6 h-6 text-body-300",e.className);return t.createElement("div",{"data-testid":"spinner",className:n},t.createElement("svg",{className:"spinner",viewBox:"0 0 20 20"},t.createElement("circle",{cx:"10",cy:"10",r:"8",fill:"none",strokeWidth:"3"})))}function Id(e){var n=fa("appearance-none block h-10 w-80 border rounded text-body-500 placeholder-body-300\n\t\t focus:outline-none transition-color","invalid"===e.status?"pl-4 pr-10 border-error":"px-4 border-ui-600 hover:border-ui-900 focus:border-ui-900");return t.createElement("div",{className:"mb-4"},t.createElement("div",{className:"relative"},t.createElement("input",{id:"account-domain-input",value:e.value,className:n,placeholder:"yourdomain.bynder.com",readOnly:e.isReadOnly,autoFocus:!0,onChange:function(t){e.onChange(t.target.value)},onKeyDown:function(t){"valid"===e.status&&13===t.keyCode&&e.onSubmit()}}),"validating"===e.status&&t.createElement("div",{role:"alert","aria-live":"polite"},t.createElement(Nd,{className:"absolute top-0 right-0 mr-3 h-full"})),"invalid"===e.status&&t.createElement(fl,{className:"absolute top-0 right-3 w-6 h-full text-error fade-in cursor-pointer",onClick:function(){e.onChange("")}})),"invalid"===e.status&&t.createElement("div",{className:"text-error text-sm mt-1 fade-in"},ma("This portal domain does not exist")))}function Od(e){return t.createElement(ha,{kind:"Primary",className:"justify-center relative",isDisabled:!e.isValidDomain||e.isSubmitting,onClick:e.onClick,testId:"login-button"},e.isSubmitting?t.createElement("div",{role:"alert","aria-live":"polite"},t.createElement(Nd,{className:"text-ui-0"})):ma("Connect"))}function Ad(e){return t.createElement(kd,null,t.createElement(Td,null),t.createElement(Cd,null),t.createElement(Id,{value:e.domainValue,isReadOnly:!1===e.isEditable||e.isSubmitting,onChange:e.onChangeDomain,onSubmit:e.onSubmit,status:e.domainStatus}),t.createElement(Od,{isValidDomain:"valid"===e.domainStatus,isSubmitting:e.isSubmitting,onClick:e.onSubmit}))}var Pd=function(e){function n(t){var n=e.call(this,t)||this;return n.state={error:null},n}return hr(n,e),n.getDerivedStateFromError=function(e){return{error:e}},n.prototype.render=function(){var e=this;return this.state.error?t.createElement(Du,{error:this.state.error,onRetry:function(){return e.setState({error:null})}}):this.props.children},n}(t.Component);function Bd(){return t.createElement("div",{role:"alert","aria-live":"polite",className:"bg-ui-0 w-full h-full"}," ",t.createElement(Nd,null)," ")}var Rd=n(null);function Fd(e){var n,o,i,s,c;va(null!==(n=e.language)&&void 0!==n?n:"en_US");var u=function(){var e,t,n=r(void 0),o=n[0],i=n[1],s=r(null!==(e=localStorage.getItem("cvrt"))&&void 0!==e?e:void 0),c=s[0],u=s[1],d=r(null!==(t=localStorage.getItem("cvad"))&&void 0!==t?t:void 0),p=d[0],f=d[1],h=r(x()),m=h[0],g=h[1],v=l();function y(e){i(e.accessToken),u(e.refreshToken),f(e.accountDomain),g(x(e.accessToken,e.refreshToken)),localStorage.setItem("cvrt",e.refreshToken),localStorage.setItem("cvad",e.accountDomain),v.current&&clearTimeout(v.current),v.current=setTimeout((function(){i(void 0)}),1e3*e.expiresIn)}function b(){var e;i(void 0),u(void 0),f(null!==(e=localStorage.getItem("cvad"))&&void 0!==e?e:void 0),g("not-authenticated"),localStorage.removeItem("cvrt"),v.current&&clearTimeout(v.current)}function x(e,t){return void 0===e&&(e=o),void 0===t&&(t=c),void 0!==e?"authenticated":void 0!==t?"refreshing":"not-authenticated"}return a((function(){return function(){v.current&&clearTimeout(v.current)}}),[]),a((function(){void 0===o&&c&&p&&(g("refreshing"),function(e,t){return vr(this,void 0,void 0,(function(){var n,r,o,i;return yr(this,(function(a){switch(a.label){case 0:n=dd(t)+"token",r=new URLSearchParams({client_id:sd,refresh_token:e,grant_type:"refresh_token"}),a.label=1;case 1:return a.trys.push([1,4,,5]),[4,fetch(n,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"},body:r})];case 2:return(o=a.sent()).ok?[4,o.json()]:[2,Qu("Failed to fetch refresh token: "+o.status)];case 3:return[2,Zu({accessToken:(i=a.sent()).access_token,expiresIn:i.expires_in})];case 4:return[2,Qu(a.sent().toString())];case 5:return[2]}}))}))}(c,p).then((function(e){ed(e)?y({accessToken:e.value.accessToken,expiresIn:e.value.expiresIn,refreshToken:c,accountDomain:p}):(ta.error(e.error),b())})))}),[o,c,p]),[{accessToken:o,accountDomain:p,status:m},y,b]}(),d=u[0],p=u[1],f=u[2],h=function(e){var t=r(null!=e?e:""),n=t[0],o=t[1],i=r(e?"validating":"empty"),s=i[0],c=i[1],u=l();return a((function(){if(n){var e=!1;return u.current=setTimeout((function(){(function(e){return vr(this,void 0,void 0,(function(){var t,n,r;return yr(this,(function(o){switch(o.label){case 0:t=nd(e.trim())+"feeds/media/is-bynder-portal/",o.label=1;case 1:return o.trys.push([1,4,,5]),[4,fetch(t)];case 2:return[4,(n=o.sent()).json()];case 3:return r=o.sent(),200===n.status&&"application/json;charset=UTF-8"===n.headers.get("Content-Type")?[2,r.webdam?"webdam":"bynder"]:[2,"invalid"];case 4:return o.sent(),[2,"invalid"];case 5:return[2]}}))}))})(n).then((function(t){e||(c("invalid"!==t?"valid":"invalid"),localStorage.setItem("cvp",t))}))}),1e3),function(){e=!0}}}),[n]),[n,function(e){u.current&&clearTimeout(u.current),o(e),c(""===e?"empty":"validating")},s]}(null!==(i=null===(o=e.portal)||void 0===o?void 0:o.url)&&void 0!==i?i:d.accountDomain),m=h[0],g=h[1],v=h[2],y=r(!1),b=y[0],x=y[1];a((function(){var e=!0;return!0===b&&function(e){return vr(this,void 0,void 0,(function(){var t,n,r,o,i,a,s,c,l,u;return yr(this,(function(d){switch(d.label){case 0:t=ad(),d.label=1;case 1:return d.trys.push([1,3,,4]),[4,id(t)];case 2:return n=d.sent(),[3,4];case 3:return[2,Qu(d.sent().toString())];case 4:return p=n,r=btoa(String.fromCharCode.apply(null,Array.from(new Uint8Array(p)))).replace(/\+/g,"-").replace(/\//g,"_").replace(/[=]+$/,""),o=ad(),[4,fd(function(e,t,n){var r={client_id:sd,code_challenge:e,code_challenge_method:"S256",redirect_uri:cd,response_type:"code",scope:ld.join(" "),domain:"",state:t},o="auth?";"webdam"===pd()&&(o="authorize?",delete r.scope,r.domain=n);var i=new URLSearchParams(r);return dd(n)+o+i}(r,o,e))];case 5:return td(i=d.sent())?[2,i]:i.value.state!==o||null===i.value.code?[2,Qu("Error logging in")]:[4,ud(i.value.code,t,e)];case 6:return td(a=d.sent())?[2,a]:(s=a.value,c=s.refreshToken,l=s.accessToken,u=s.expiresIn,[2,Zu({accessToken:l,expiresIn:parseFloat(u),refreshToken:c})])}var p}))}))}(m).then((function(t){e&&(function(e){ed(e)?p(mr(mr({},e.value),{accountDomain:m})):ta.error(e.error)}(t),x(!1))})),function(){e=!1}}),[b,m]);var _=mr(mr({},d),{logout:function(){f()}});switch(d.status){case"authenticated":return t.createElement(Rd.Provider,{value:_},e.children);case"not-authenticated":return t.createElement(_d,null,t.createElement(Ad,{domainValue:m,domainStatus:v,onChangeDomain:g,isSubmitting:b,isEditable:null===(c=null===(s=e.portal)||void 0===s?void 0:s.editable)||void 0===c||c,onSubmit:function(){x(!0)}}));case"refreshing":return t.createElement(Bd,null)}}var zd=function(e){return t.createElement(Pd,null,t.createElement(Fd,mr({},e)))},Ld=function(){return i(Rd)};function jd(e){var t,n,o,i,s=this,c=Ld(),l=r({tag:"Loading",value:null}),u=l[0],d=l[1],p=!1,f=function(t){return vr(s,void 0,void 0,(function(){var n;return yr(this,(function(r){switch(r.label){case 0:return d((function(e){return{tag:"Loading",value:"Failure"===e.tag?null:e.value}})),[4,od("\n query searchAssets($filter: AssetFilter!, $after: Cursor, $orderBy: AssetOrder!, $language: String) {\n searchAssets(filter: $filter) {\n assets(after: $after, first: 50, orderBy: $orderBy) {\n nodes {\n __typename\n ...DisplayAsset\n }\n\t\t\t\ttotalCount\n\t\t\t\tpageInfo {\n\t\t\t\t\tendCursor\n\t\t\t\t\thasNextPage\n }\n }\n }\n }\n \nfragment DisplayAsset on Asset {\n __typename\n id\n derivatives {\n thumbnail\n }\n extensions\n name\n url\n isArchived\n isWatermarked\n\tmetaproperties {\n\t\tnodes {\n\t\t id\n\t\t label(language: $language)\n\t\t showInGridView\n\t\t showInListView\n\t\t options {\n\t\t\tid\n\t\t\tlabel(language: $language)\n\t\t\tassetCount\n\t\t }\n\t\t}\n\t}\n}\n",Md(e,null!=t?t:null),c)];case 1:return n=r.sent(),p||(td(n)?d({tag:"Failure",value:n.error}):h(n,t)),[2]}}))}))},h=function(e,t){Dd(u)&&t?d((function(t){var n,r,o=null!==(r=null===(n=Dd(t))||void 0===n?void 0:n.nodes)&&void 0!==r?r:[];return{tag:"Loaded",value:{searchAssets:{assets:mr(mr({},e.value.searchAssets.assets),{nodes:wr(o,e.value.searchAssets.assets.nodes)})}}}})):d({tag:"Loaded",value:e.value})};return a((function(){return f(),function(){p=!0}}),[null===(t=e.filter)||void 0===t?void 0:t.assetTypes,null===(n=e.filter)||void 0===n?void 0:n.metaproperties,null===(o=e.filter)||void 0===o?void 0:o.tags,e.collection,e.orderBy,e.searchTerm,e.language]),{data:u,executeQuery:function(){return f()},isLoading:!u||"Loading"===u.tag,loadMore:function(){var e;return f(null===(e=Dd(u))||void 0===e?void 0:e.pageInfo.endCursor)},hasNextPage:!!(null===(i=Dd(u))||void 0===i?void 0:i.pageInfo.hasNextPage)}}var Md=function(e,t){var n,r,o,i,a,s=e.filter,c=e.predefinedFilter,l=e.collection,u=e.orderBy,d=e.allAssetTypes,p=e.searchTerm,f=e.language,h=(null===(n=null==s?void 0:s.assetTypes)||void 0===n?void 0:n.length)?s.assetTypes:null==c?void 0:c.assetType_in;return{orderBy:u,filter:{collectionId:null!==(r=null==l?void 0:l.id)&&void 0!==r?r:null==c?void 0:c.collectionId,assetType_in:null!=h?h:d,metapropertyOptionId_in:null!==(o=Hd(null==s?void 0:s.metaproperties))&&void 0!==o?o:null==c?void 0:c.metapropertyOptionId_in,searchTerm:null!==(i=null!=p?p:null==c?void 0:c.searchTerm)&&void 0!==i?i:null,tagNames_in:null!==(a=null==s?void 0:s.tags)&&void 0!==a?a:null==c?void 0:c.tagNames_in,isLimitedUse:!1},after:t,language:f}},Dd=function(e,t){var n,r=null!=t?t:e;if("Failure"!==r.tag)return null===(n=r.value)||void 0===n?void 0:n.searchAssets.assets},Hd=function(e){return e?e.map((function(e){return e.id})):null};function Ud(e,t,n){return vr(this,void 0,void 0,(function(){var r;return yr(this,(function(o){switch(o.label){case 0:return[4,od("\n query getAssetsById($ids: [ID!]!, $language: String) {\n nodes(ids: $ids) {\n __typename\n id\n ...on Asset {\n ...DisplayAsset\n files\n }\n }\n }\n \nfragment DisplayAsset on Asset {\n __typename\n id\n derivatives {\n thumbnail\n }\n extensions\n name\n url\n isArchived\n isWatermarked\n\tmetaproperties {\n\t\tnodes {\n\t\t id\n\t\t label(language: $language)\n\t\t showInGridView\n\t\t showInListView\n\t\t options {\n\t\t\tid\n\t\t\tlabel(language: $language)\n\t\t\tassetCount\n\t\t }\n\t\t}\n\t}\n}",{ids:e.map((function(e){return btoa("(Asset_id "+e+")")})),language:n},t)];case 1:return td(r=o.sent())?[2,r]:[2,Zu(r.value.nodes)]}}))}))}var qd=n(null);function Vd(e){var n=r([]),i=n[0],s=n[1],c=function(e){var t=this,n=r([]),o=n[0],i=n[1],s=sa(),c=s.selectionMode,l=s.language,u=Ld(),d=!1;return a((function(){var n,r=null!=e?e:[];return"MultiSelect"!==c&&(r=r[0]?[r[0]]:[]),n=r,vr(t,void 0,void 0,(function(){var e,t;return yr(this,(function(r){switch(r.label){case 0:return n.length?[4,Ud(n,u,l)]:[3,2];case 1:e=r.sent(),d||td(e)||i(null!==(t=e.value)&&void 0!==t?t:[]),r.label=2;case 2:return[2]}}))})),function(){d=!0}}),[e]),o}(e.preselectedAssetIds),l=la();function u(){s([])}function d(e){s((function(t){var n=e.filter((function(e){return!Wd(t,e)}));return wr(t,n.map((function(e){return{type:"asset",value:e}})))}))}function p(e){var t;"MultiSelect"!==l?(t=e[0],i.some((function(e){return e.value.id===t.id}))?s([]):s([{type:"asset",value:t}])):s((function(t){var n=e.filter((function(e){return!Wd(t,e)})),r=e.filter((function(e){return Wd(t,e)}));return wr(t.filter((function(e){return!r.some((function(t){return t.id===e.value.id}))})),n.map((function(e){return{type:"asset",value:e}})))}))}function f(e){s((function(t){return Wd(t,e)?t.filter((function(t){return t.value.id!==e.id})):wr(t,[{type:"collection",value:e}])}))}a((function(){d(c)}),[c]);var h=o((function(){return{selection:i,clear:u,selectAssets:d,toggleAssets:p,toggleCollection:f}}),[i]);return t.createElement(qd.Provider,{value:h},e.children)}function Wd(e,t){return e.some((function(e){return e.value.id===t.id}))}function $d(){var e=i(qd);if(null===e)throw new Error("useSelection must be used with a SelectionProvider");return e}function Yd(e){var n=e.url,o=e.cover,i=void 0===o||o,a=e.alt,s=r(!1),c=s[0],l=s[1],u=fa("select-none w-full h-full",i?"object-cover":"object-contain",c?"fade-in animation-duration-500":"invisible"),d=null!=n?n:"data:,";return t.createElement("img",{className:u,src:d,draggable:!1,onLoad:function(){return l(!0)},alt:a,"data-testid":"card-image"})}function Gd(e){var n=e.urls,r=e.totalCount,o=e.alt;return t.createElement(t.Fragment,null,0===n.length&&t.createElement(Yd,{alt:o}),1===n.length&&t.createElement(Yd,{url:n[0],cover:!1,alt:o}),2===n.length&&t.createElement(t.Fragment,null,t.createElement("div",{className:"w-2/4 h-full"}," ",t.createElement(Yd,{url:n[0],alt:o})," "),t.createElement("div",{className:"w-2/4 h-full"}," ",t.createElement(Yd,{url:n[1],alt:o})," ")),3===n.length&&t.createElement(t.Fragment,null,t.createElement("div",{className:"w-2/4 h-full"}," ",t.createElement(Yd,{url:n[0],alt:o})," "),t.createElement("div",{className:"flex flex-col w-2/4"},t.createElement("div",{className:"h-2/4 bg-ui-500 fade-in"}," ",t.createElement(Yd,{url:n[1],alt:o})," "),t.createElement("div",{className:"h-2/4 bg-ui-600 fade-in"}," ",t.createElement(Yd,{url:n[2],alt:o})," "))),n.length>=4&&t.createElement(t.Fragment,null,t.createElement("div",{className:"flex flex-col w-2/4"},t.createElement("div",{className:"h-2/4"}," ",t.createElement(Yd,{url:n[0],alt:o})," "),t.createElement("div",{className:"h-2/4 bg-ui-400 fade-in"}," ",t.createElement(Yd,{url:n[1],alt:o})," ")),t.createElement("div",{className:"flex flex-col w-2/4"},t.createElement("div",{className:"h-2/4 bg-ui-500 fade-in"}," ",t.createElement(Yd,{url:n[2],alt:o})," "),t.createElement("div",{className:"h-2/4 bg-ui-600 fade-in"}," ",t.createElement(Yd,{url:n[3],alt:o})," "))),r>4&&t.createElement("div",{className:"absolute text-ui-0 right-0 bottom-0 text-xl h-2/4 w-2/4 text-center\n\t\t\t\t\t flex items-center justify-center bg-ui-900"},"+",r-4))}function Xd(e){var n=e.className,r=e.collection,o=e.fadeIn,i=void 0===o||o,a=e.isSelected,s=e.style,c=la(),l=kr()[1],u=$d(),d=sa().hideExternalAccess,p=t.createElement(t.Fragment,null,t.createElement("div",{className:"truncate"}," ",r.name," "),t.createElement("div",{className:"mt-2 text-sm text-body-400"},$u(r.assetCount,ma("{} asset"),ma("{} assets"))));return t.createElement(Yu,{id:r.id,style:s,title:p,alt:r.name,className:fa(n,a&&"shadow-outline"),fadeIn:i,stacked:!0,onClick:function(){return l({page:"collection",collection:r})},"aria-selected":a},t.createElement(t.Fragment,null,t.createElement(Gd,{urls:r.thumbnailUrls,totalCount:r.assetCount,alt:r.name}),a&&t.createElement("div",{className:"absolute h-full w-full bg-ui-800 fade-in"}),!d&&t.createElement(Ku,{className:"absolute left-0 top-0 ml-3 mt-3 rounded hidden\n\t\t\t\t\t\t group-hover:block group-hover:fade-in",title:ma("Open in new tab"),onClick:function(e){e.stopPropagation(),window.open(r.url,"_blank")}},t.createElement(Kc,{className:"w-6 h-6"})),"MultiSelect"===c&&t.createElement(Ku,{active:a,title:ma(a?"Deselect":"Select"),className:fa("absolute right-0 top-0 mr-3 mt-3 rounded-full",!a&&"hidden group-hover:block group-hover:fade-in"),onClick:function(e){e.stopPropagation(),u.toggleCollection(r)}},t.createElement(ll,{className:"w-6 h-6"}))))}function Jd(e){var t=r(void 0),n=t[0],o=t[1],i=l(void 0);function s(t){void 0!==i.current&&cancelAnimationFrame(i.current),i.current=requestAnimationFrame((function(){var n=null!=t?t:e;if(null!==n){var r=n.getBoundingClientRect();o({width:r.width,height:r.height,scrollWidth:n.scrollWidth})}}))}return a((function(){s();var e=function(){return s()};return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e),i.current&&cancelAnimationFrame(i.current)}}),[e]),{dimensions:n,remeasure:s}}function Kd(e,t){if(!e)throw new Error("Invariant failed")}function Zd(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Qd(){return(Qd=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function ep(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var tp=new Map,np=new Map,rp=new Map,op=0;function ip(e,t,n){void 0===n&&(n={}),n.threshold||(n.threshold=0);var r=n,o=r.root,i=r.rootMargin,a=r.threshold;if(tp.has(e)&&Kd(!1),e){var s=function(e){return e?rp.has(e)?rp.get(e):(op+=1,rp.set(e,op.toString()),rp.get(e)+"_"):""}(o)+(i?a.toString()+"_"+i:a.toString()),c=np.get(s);c||(c=new IntersectionObserver(sp,n),s&&np.set(s,c));var l={callback:t,element:e,inView:!1,observerId:s,observer:c,thresholds:c.thresholds||(Array.isArray(a)?a:[a])};return tp.set(e,l),c.observe(e),l}}function ap(e){if(e){var t=tp.get(e);if(t){var n=t.observerId,r=t.observer,o=r.root;r.unobserve(e);var i=!1,a=!1;n&&tp.forEach((function(t,r){r!==e&&(t.observerId===n&&(i=!0,a=!0),t.observer.root===o&&(a=!0))})),!a&&o&&rp.delete(o),r&&!i&&r.disconnect(),tp.delete(e)}}}function sp(e){e.forEach((function(e){var t=e.isIntersecting,n=e.intersectionRatio,r=e.target,o=tp.get(r);if(o&&n>=0){var i=o.thresholds.some((function(e){return o.inView?n>e:n>=e}));void 0!==t&&(i=i&&t),o.inView=i,o.callback(i,e)}}))}var cp=function(e){var t,n;function r(){for(var t,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return Zd(ep(t=e.call.apply(e,[this].concat(r))||this),"state",{inView:!1,entry:void 0}),Zd(ep(t),"node",null),Zd(ep(t),"handleNode",(function(e){t.node&&(ap(t.node),e||t.props.triggerOnce||t.setState({inView:!1,entry:void 0})),t.node=e||null,t.observeNode()})),Zd(ep(t),"handleChange",(function(e,n){(e!==t.state.inView||e)&&t.setState({inView:e,entry:n}),t.props.onChange&&t.props.onChange(e,n)})),t}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var o=r.prototype;return o.componentDidMount=function(){this.node||Kd(!1)},o.componentDidUpdate=function(e,t){e.rootMargin===this.props.rootMargin&&e.root===this.props.root&&e.threshold===this.props.threshold||(ap(this.node),this.observeNode()),t.inView!==this.state.inView&&this.state.inView&&this.props.triggerOnce&&(ap(this.node),this.node=null)},o.componentWillUnmount=function(){this.node&&(ap(this.node),this.node=null)},o.observeNode=function(){if(this.node){var e=this.props,t=e.threshold,n=e.root,r=e.rootMargin;ip(this.node,this.handleChange,{threshold:t,root:n,rootMargin:r})}},o.render=function(){var e=this.state,t=e.inView,n=e.entry;if(!function(e){return"function"!=typeof e.children}(this.props))return this.props.children({inView:t,entry:n,ref:this.handleNode});var r=this.props,o=r.children,i=r.as,a=r.tag,s=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(r,["children","as","tag","triggerOnce","threshold","root","rootMargin","onChange"]);return c(i||a||"div",Qd({ref:this.handleNode},s),o)},r}(p);Zd(cp,"displayName","InView"),Zd(cp,"defaultProps",{threshold:0,triggerOnce:!1});var lp={inView:!1,entry:void 0};function up(e){var n=function(e){void 0===e&&(e={});var t=l(),n=r(lp),o=n[0],i=n[1];return[d((function(n){t.current&&(ap(t.current),e.triggerOnce||i(lp)),n&&ip(n,(function(t,r){i({inView:t,entry:r}),t&&e.triggerOnce&&ap(n)}),e),t.current=n}),[e.threshold,e.root,e.rootMargin,e.triggerOnce]),o.inView,o.entry]}(),o=n[0],i=n[1];return a((function(){i&&!e.isLoading&&e.hasNextPage&&e.loadMore()}),[i]),t.createElement(t.Fragment,null,e.children,e.hasNextPage&&t.createElement("div",{className:"relative h-32 w-full",ref:o,"data-testid":"loading-element"},t.createElement(Nd,{className:fa(!i&&"hidden")})))}function dp(){return t.createElement("svg",{viewBox:"0 5 60 82",className:"h-20"},t.createElement("defs",null,t.createElement("filter",{x:"-1.7%",y:"-1.2%",width:"103.3%",height:"105%",filterUnits:"objectBoundingBox",id:"prefix__a"},t.createElement("feOffset",{dy:"2",in:"SourceAlpha",result:"shadowOffsetOuter1"}),t.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0.133333333 0 0 0 0 0.2 0 0 0 0.05 0",in:"shadowOffsetOuter1"})),t.createElement("filter",{x:"-5%",y:"-5%",width:"110%",height:"120%",filterUnits:"objectBoundingBox",id:"prefix__c"},t.createElement("feOffset",{dy:"2",in:"SourceAlpha",result:"shadowOffsetOuter1"}),t.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0.133333333 0 0 0 0 0.2 0 0 0 0.05 0",in:"shadowOffsetOuter1"})),t.createElement("path",{d:"M5 5h35l20 20v55a5 5 0 01-5 5H5a5 5 0 01-5-5V10a5 5 0 015-5z",id:"prefix__b"}),t.createElement("path",{d:"M40 5l20 20H45a5 5 0 01-5-5V5z",id:"prefix__d"})),t.createElement("g",{fill:"none",fillRule:"evenodd"},t.createElement("use",{fill:"#000",filter:"url(#prefix__a)",xlinkHref:"#prefix__b"}),t.createElement("use",{fill:"#FFF",xlinkHref:"#prefix__b"}),t.createElement("g",{fillRule:"nonzero"},t.createElement("use",{fill:"#000",filter:"url(#prefix__c)",xlinkHref:"#prefix__d"}),t.createElement("use",{fill:"#FFF",xlinkHref:"#prefix__d"}))))}function pp(e){return t.createElement("div",{className:" w-full h-full flex flex-col items-center justify-center"},t.createElement("div",{className:"bg-ui-400 rounded-full w-40 h-40 flex items-center justify-center"},t.createElement(dp,null),t.createElement(Zc,{className:"absolute mt-1 ml-px text-body-300",style:{width:36,height:36}})),t.createElement("h1",{className:"mt-6 text-2xl"},ma("No results found")),t.createElement("span",{className:"mt-4 text-body-400"},ma("Try adjusting the filter to find assets.")),t.createElement(ha,{kind:"Primary",title:ma("Reset filters"),className:"mt-8",onClick:e.onReset},ma("Reset filters")))}function fp(e){var n,o,i=r(null),a=i[0],s=i[1],c=Jd(a).dimensions,l=$d().selection.filter((function(e){return"collection"===e.type})).map((function(e){return e.value.id})),u=Ar().setSearch,d=e.connection,p=d.data,f=d.isLoading,h=d.loadMore,m=d.hasNextPage,g=void 0!==c?Math.ceil(c.height/184):0,v=void 0!==c?Math.round((c.width-32)/204):0;return t.createElement("div",{className:"card-list",ref:function(e){s(e)}},("Failure"===p.tag||"Loading"===p.tag&&!p.value)&&t.createElement(Xu,{rows:g,columns:v,title:t.createElement("div",{className:"mt-2 text-sm"}," ")}),"Loaded"===p.tag&&0===(null===(n=p.value)||void 0===n?void 0:n.collections.nodes.length)&&t.createElement(pp,{onReset:function(){return u("collections","")}}),("Loading"===p.tag&&!!p.value||"Loaded"===p.tag&&p.value.collections.nodes.length>0)&&t.createElement(up,{hasNextPage:m,isLoading:f,loadMore:h},null===(o=p.value)||void 0===o?void 0:o.collections.nodes.map((function(e,n){return t.createElement(Xd,{key:e.id,isSelected:l.includes(e.id),collection:e,fadeIn:n>=g*v})}))))}function hp(){var e=Pr("collections"),n=e.value,o=e.setIsLoading,i=function(e){var t,n=this,o=Ld(),i=r({tag:"Loading",value:null}),s=i[0],c=i[1],l=!1,u=function(t){return vr(n,void 0,void 0,(function(){var n,r;return yr(this,(function(i){switch(i.label){case 0:return c((function(e){return{tag:"Loading",value:"Failure"===e.tag?null:e.value}})),[4,od("\nquery getCollections($searchTerm: String, $orderBy: CollectionOrder!, $after: Cursor) {\n collections(after: $after, first: 50, filter: {name_contains: $searchTerm, assetCount_gte: 1}, orderBy: $orderBy) {\n nodes {\n id\n name\n assetCount\n thumbnailUrls\n url\n }\n totalCount\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n}",mr(mr({},e),{searchTerm:null!==(r=e.searchTerm)&&void 0!==r?r:null,after:null!=t?t:null}),o)];case 1:return n=i.sent(),l||(td(n)?c({tag:"Failure",value:n.error}):d(n,t)),[2]}}))}))},d=function(e,t){p()&&t?c((function(t){var n,r,o=null!==(r=null===(n=p(t))||void 0===n?void 0:n.nodes)&&void 0!==r?r:[];return{tag:"Loaded",value:{collections:mr(mr({},e.value.collections),{nodes:wr(o,e.value.collections.nodes)})}}})):c({tag:"Loaded",value:e.value})},p=function(e){var t,n=null!=e?e:s;if("Failure"!==n.tag)return null===(t=n.value)||void 0===t?void 0:t.collections};return a((function(){return u(),function(){l=!0}}),[e.searchTerm,e.orderBy]),{data:s,executeQuery:function(){return u()},isLoading:!s||"Loading"===s.tag,loadMore:function(){var e;return u(null===(e=p())||void 0===e?void 0:e.pageInfo.endCursor)},hasNextPage:!!(null===(t=p())||void 0===t?void 0:t.pageInfo.hasNextPage)}}({searchTerm:n,orderBy:pr("collections")[0]});return a((function(){i.isLoading||o(!1)}),[i.isLoading]),"Failure"===i.data.tag?t.createElement(Du,{error:new Error(i.data.value),onRetry:i.executeQuery}):t.createElement("div",{className:"flex flex-col flex-grow overflow-y-auto"},t.createElement("div",{className:"flex items-center px-4 pt-4 pb-2 z-10"},i.data.value&&t.createElement("span",{className:"flex-shrink-0 flex-grow text-body-400 fade-in-down"},$u(i.data.value.collections.totalCount,ma("{} collection"),ma("{} collections"))),!i.data.value&&t.createElement("span",{className:"flex-grow"}),t.createElement(Wu,{options:["CREATED_AT","NAME"]}),t.createElement(Hu,null)),t.createElement(fp,{connection:i}))}var mp=n(null);function gp(e){var n=r([]),i=n[0],a=n[1],s=r([]),c=s[0],l=s[1],u=r([]),d=u[0],p=u[1],f=r({}),h=f[0],m=f[1];function g(e){a((function(t){return vp(t,e)}))}function v(e){a((function(t){return yp(t,e)}))}function y(e){l((function(t){return vp(t,e.id)})),m((function(t){var n;return mr(mr({},t),((n={})[e.id]=e,n))}))}function b(e){l((function(t){return yp(t,e.id)})),m((function(t){var n=t,r=e.id;return gr(n,["symbol"==typeof r?r:r+""])}))}function x(e){p((function(t){return vp(t,e)}))}function _(e){p((function(t){return yp(t,e)}))}function w(){a([]),l([]),m({}),p([])}var S=c.map((function(e){return h[e]})),E=o((function(){return{assetTypes:i,metaproperties:S,tags:d,addAssetType:g,removeAssetType:v,addMetaproperty:y,removeMetaproperty:b,addTag:x,removeTag:_,clear:w}}),[i,S,d]);return t.createElement(mp.Provider,{value:E},e.children)}function vp(e,t){return e.includes(t)?e:wr(e,[t])}function yp(e,t){return e.filter((function(e){return e!==t}))}function bp(){var e=i(mp);if(null===e)throw new Error("useAssetFilter must be used with a AssetFilterProvider");return e}function xp(e){return ma({AUDIO:"Audio",DOCUMENT:"Document",IMAGE:"Image",VIDEO:"Video"}[e])}function _p(e){switch(e){case"AUDIO":return el;case"DOCUMENT":return nl;case"IMAGE":return ol;case"VIDEO":return Qc}}function wp(e){return t.createElement(ha,{kind:"FlatSm",className:fa("pl-0 pr-0 z-20",e.isVisible?"shadow-fade-left active:shadow-fade-left":"hidden"),onClick:e.onClick,testId:"arrow-right"},t.createElement(dl,{className:"w-6 h-6"}))}function Sp(e){return t.createElement(ha,{kind:"FlatSm",className:fa("pl-0 pr-0 z-20",e.isVisible?"shadow-fade-right active:shadow-fade-right":"hidden"),onClick:e.onClick,testId:"arrow-left"},t.createElement(ul,{className:"w-6 h-6"}))}function Ep(e){var n=r(0),o=n[0],i=n[1],s=l(null),c=Jd(s.current),u=c.dimensions,d=c.remeasure,p=null!==s.current?s.current.scrollWidth-s.current.clientWidth:0,f=void 0!==u&&u.width<u.scrollWidth;a((function(){d(s.current)}),[e.children,s.current]),a((function(){f||i(0)}),[f]);var h=o>0,m=p>5&&o!==p;return t.createElement("div",{className:fa("inline-flex flex-grow overflow-hidden",e.className)},f&&t.createElement(Sp,{isVisible:h,onClick:function(){i((function(e){var t=Math.max(e-250,0);return t>=100?t:0}))}}),t.createElement("div",{className:"overflow-hidden",ref:s},t.createElement("div",{className:"transition-transform inline-flex",style:{transform:"translateX("+-o+"px)"},"data-testid":"horizontal-scrollable-el"},e.children)),f&&t.createElement(wp,{isVisible:m,onClick:function(){i((function(e){var t=Math.min(e+250,p);return t<=p-100?t:p}))}}),e.static)}function kp(e){var n=fa("bg-ui-0 border border-ui-600 flex-shrink-0 h-8 inline-flex\n\t\t items-center justify-center px-3 rounded-full select-none shadow-border\n\t\t text-sm text-white transition-color",e.className);return t.createElement("div",{className:n,onClick:e.onClick,"data-testid":e["data-testid"]},e.children)}function Cp(e){return t.createElement(kp,{className:"mr-2 fade-in-down","data-testid":"selected-filter:"+e.title},e.icon,t.createElement("span",{className:"max-w-32 truncate",title:e.title},e.title),t.createElement(fl,{onClick:e.onClick,title:ma("Remove filter"),className:"w-5 h-5 ml-1 -mr-1 text-body-300 hover:text-body-400 cursor-pointer"}))}function Tp(){var e=bp(),n=0===e.metaproperties.length&&0===e.assetTypes.length&&0===e.tags.length?void 0:t.createElement(ha,{kind:"FlatSm",className:"flex-shrink-0 fade-in-down",onClick:e.clear},ma("Clear filters"));return t.createElement("div",{"data-testid":"selected-filter-list"},t.createElement(Ep,{className:"ml-2",static:n},e.assetTypes.map((function(n){var r=_p(n);return t.createElement(Cp,{key:n,onClick:function(){return e.removeAssetType(n)},title:xp(n),icon:t.createElement(r,{className:"w-5 h-5 mr-1"})})})),e.metaproperties.map((function(n){return t.createElement(Cp,{key:n.id,onClick:function(){return e.removeMetaproperty(n)},title:n.label})})),e.tags.map((function(n){return t.createElement(Cp,{key:n,onClick:function(){return e.removeTag(n)},title:n})}))))}function Np(e){var n=e.isSelected;return t.createElement(Ku,{active:n,title:ma(n?"Deselect":"Select"),className:fa("absolute right-0 top-0 mr-3 mt-3 rounded-full",!n&&"hidden group-hover:block group-hover:fade-in")},t.createElement(ll,{className:"w-6 h-6"}))}function Ip(e){var n=e.asset;return t.createElement(Ku,{className:"absolute left-0 top-0 ml-3 mt-3 rounded hidden group-hover:block\n\t\t\t group-hover:fade-in",title:ma("Open in new tab"),onClick:function(e){e.stopPropagation(),window.open(n.url,"_blank")}},t.createElement(Kc,{className:"w-6 h-6"}))}var Op=["xls","xlsx","ppt","pdf","pptx","indd","mp4","wav","docx","doc","numbers","pages","otf","txt","ttf","mov","avi","mpeg","webm","fla","aiff","mp3","m4r","zip","rar"];function Ap(e){if(e.derivatives.thumbnail)return e.derivatives.thumbnail;var t=e.extensions[0];return Op.includes(t)?"https://d8ejoa1fys2rk.cloudfront.net/includes/img/placeholder/medium/"+t+".jpg":"aif"===t?"https://d8ejoa1fys2rk.cloudfront.net/includes/img/placeholder/medium/aiff.jpg":"m4a"===t?"https://d8ejoa1fys2rk.cloudfront.net/includes/img/placeholder/medium/m4r.jpg":"https://d8ejoa1fys2rk.cloudfront.net/includes/img/common/no-image.png"}function Pp(e){var t=e.extensions[0];return"JPG"===(null==t?void 0:t.toUpperCase())?"JPEG":null==t?void 0:t.toUpperCase()}function Bp(e){var n=e.className,o=e.fadeIn,i=void 0===o||o,s=e.asset,c=e.isSelected,l=e.isOutlined,u=e.onClick,d=e.children,p=void 0===d?null:d,f=r(),h=f[0],m=f[1],g=sa().theme,v=(c||l)&&void 0!==(null==g?void 0:g.colorPrimary)?{boxShadow:"0 0 0 2px "+g.colorPrimary}:void 0,y=sa().hideExternalAccess,b=function(e){return e.isArchived&&e.isWatermarked?ma("archived")+", "+ma("watermarked"):e.isArchived?ma("archived"):e.isWatermarked?ma("watermarked"):void 0}(s),x=Pp(s);return a((function(){var e,t=null===(e=s.metaproperties)||void 0===e?void 0:e.nodes.filter((function(e){return e.showInGridView||e.showInListView}));m(t)}),[s.metaproperties]),t.createElement("div",{"data-drag-select-id":s.id},t.createElement(Yu,{id:s.id,style:v,title:s.name,alt:s.name,metaproperties:h,className:fa(n,c&&"shadow-outline",l&&"selected-outline"),fadeIn:i,onClick:function(e){void 0!==u&&(e.stopPropagation(),u(s,e))},"aria-selected":c},t.createElement(Yd,{url:Ap(s),cover:!1,alt:s.name}),c&&t.createElement("div",{className:"absolute h-full w-full bg-ui-800 fade-in"}),!y&&t.createElement(Ip,{asset:s}),t.createElement(Np,{isSelected:c}),b&&t.createElement("span",{className:"overlay-pill left-0 bottom-0 max-w-32 truncate",title:b},b),x&&t.createElement("span",{className:"overlay-pill right-0 bottom-0"},x),p))}function Rp(e,t,n){var r=this,i=l(null),s=l(0),c=l(null),u=l([]),d=l(),p=l(),f=l(e),h=l(!0);f.current=e;var m=!t&&0!==t&&"undefined"!=typeof window;if("function"!=typeof e)throw new TypeError("Expected a function");t=+t||0;var g=!!(n=n||{}).leading,v=!("trailing"in n)||!!n.trailing,y="maxWait"in n,b=y?Math.max(+n.maxWait||0,t):null;return a((function(){return h.current=!0,function(){h.current=!1}}),[]),o((function(){var e=function(e){var t=u.current,n=d.current;return u.current=d.current=null,s.current=e,p.current=f.current.apply(n,t)},n=function(e,t){m&&cancelAnimationFrame(c.current),c.current=m?requestAnimationFrame(e):setTimeout(e,t)},o=function(e){if(!h.current)return!1;var n=e-i.current,r=e-s.current;return!i.current||n>=t||n<0||y&&r>=b},a=function(t){return c.current=null,v&&u.current?e(t):(u.current=d.current=null,p.current)},l=function(){var e=Date.now();if(o(e))return a(e);if(h.current){var r=e-i.current,c=e-s.current,u=t-r,d=y?Math.min(u,b-c):u;n(l,d)}},x=function(){for(var a=[],f=0;f<arguments.length;f++)a[f]=arguments[f];var m=Date.now(),v=o(m);if(u.current=a,d.current=r,i.current=m,v){if(!c.current&&h.current)return s.current=i.current,n(l,t),g?e(i.current):p.current;if(y)return n(l,t),e(i.current)}return c.current||n(l,t),p.current};return x.cancel=function(){c.current&&(m?cancelAnimationFrame(c.current):clearTimeout(c.current)),s.current=0,u.current=i.current=d.current=c.current=null},x.isPending=function(){return!!c.current},x.flush=function(){return c.current?a(Date.now()):p.current},x}),[g,y,t,b,v,m])}function Fp(e,t){return e===t}function zp(e){return"function"==typeof e?function(){return e}:e}function Lp(e,t,n){var o=n&&n.equalityFn||Fp,i=function(e){var t=r(zp(e)),n=t[0],o=t[1];return[n,d((function(e){return o(zp(e))}),[])]}(e),s=i[0],c=i[1],u=Rp(d((function(e){return c(e)}),[c]),t,n),p=l(e);return a((function(){o(p.current,e)||(u(e),p.current=e)}),[e,u,o]),[s,{cancel:u.cancel,isPending:u.isPending,flush:u.flush}]}var jp={x:null,y:null},Mp=function(e){var n=e.dragContainer,o=e.selectionBoxCustomAttr,i=e.onSelect,s=e.onDeselect,c=e.onDragStart,u=e.onDragEnd,p=r(jp),h=p[0],m=p[1],g=r(jp),v=g[0],y=g[1],b=Lp(v,10,{leading:!0,maxWait:10})[0],x=r(),_=x[0],w=x[1],S=oa(),E=t.useMemo((function(){return Hp(h,b,S.querySelector(".cv-root"))}),[h,b,S]),k=Lp(E,50,{leading:!1,maxWait:50})[0],C=r([]),T=C[0],N=C[1],I=$p(T),O=l(h),A=l(v),P=l(null!==O.current.x&&null!==O.current.y&&null!==A.current.x&&null!==A.current.y),B=l({shiftKey:!1,metaKey:!1});a((function(){return document.addEventListener("keydown",R,!1),document.addEventListener("keyup",R,!1),function(){document.removeEventListener("keydown",R,!1),document.removeEventListener("keyup",R,!1)}}),[]);var R=function(e){var t=e.shiftKey,n=e.metaKey,r=t||n?"inverse":"select";B.current={shiftKey:t,metaKey:n},P.current&&r!==_&&w(r)};a((function(){var e;return"function"==typeof c&&P.current?(R(B.current),c(null!=_?_:"select")):"function"!=typeof u||P.current||(e=setTimeout((function(){return u(null!=_?_:"select")}),10)),function(){return clearTimeout(e)}}),[P.current,_]);var F=function(e){O.current=e,m(e),L()},z=function(e){A.current=e,y(e),L()},L=function(){P.current=null!==O.current.x&&null!==O.current.y&&null!==A.current.x&&null!==A.current.y},j=d((function(e){var t,n,r=e.clientY,o=e.clientX,i=null!==O.current.x,a=Math.abs(null!==(t=O.current.x)&&void 0!==t?t:0-o)>=1||Math.abs(null!==(n=O.current.y)&&void 0!==n?n:0-r)>=1;i&&a&&z({x:o,y:r})}),[]),M=d((function(){S.removeEventListener("mousemove",j),S.removeEventListener("mouseup",M),F(jp),z(jp)}),[j,S]),D=d((function(e){var t=e.clientY,n=e.clientX;0===e.button&&(S.addEventListener("mousemove",j),S.addEventListener("mouseup",M),F({x:n,y:t}))}),[j,M,S]);a((function(){var e=S.querySelector(n);return e&&(Vp(S),e.addEventListener("mousedown",D)),function(){e&&(e.removeEventListener("mousedown",D),Wp(S))}}),[n,D,j,M,S]),a((function(){var e=S.querySelectorAll("[data-drag-select-id]"),t=Array.from(e).reduce((function(e,t){var n=qp(t);return t instanceof HTMLElement&&Up(n,k)&&t.dataset.dragSelectId&&e.push(t.dataset.dragSelectId),e}),[]);N(t)}),[k,S]),a((function(){if(I&&I!==T&&P.current){var e=T.filter((function(e){return!I.includes(e)})),t=I.filter((function(e){return!T.includes(e)}));e.length&&i(e),t.length&&s(t)}}),[T,I,i,s,P]);var H=S.querySelector("#drag-select-container");return P.current&&H?f.createPortal(t.createElement("div",mr({},o,{style:o.style?mr(mr(mr({},Dp),o.style),E):mr(mr({},Dp),E),"data-testid":"drag-selection"})),H):null},Dp={position:"absolute",zIndex:100},Hp=function(e,t,n){if(!(e.x&&e.y&&t.x&&t.y&&n))return{left:0,top:0,height:0,width:0};var r=n.getBoundingClientRect(),o=Math.max(t.x,0),i=Math.min(e.x,o);i=Math.max(i,r.left+4);var a=Math.min(e.y,t.y),s=Math.abs(t.y-e.y),c=Math.abs(o-e.x),l=r.width+r.left-i-4;return{left:i,top:a,height:s,width:c=Math.min(c,l)}},Up=function(e,t){return e.left<=t.left+t.width&&e.left+e.width>=t.left&&e.top<=t.top+t.height&&e.top+e.height>=t.top},qp=function(e){var t=e.getBoundingClientRect();return{left:t.left,top:t.top+window.scrollY,height:t.height,width:t.width}},Vp=function(e){var t=document.createElement("div");t.id="drag-select-container",e.appendChild(t)},Wp=function(e){var t=e.querySelector("#drag-select-container");t&&t.remove()},$p=function(e){var t=l();return a((function(){t.current=e})),t.current};function Yp(e){var n,o=e.assets,i=e.count,a=e.hasNextPage,s=void 0!==a&&a,c=e.isLoading,u=void 0!==c&&c,d=e.loadMore,p=void 0===d?function(){}:d,f=e.onSelect,h=void 0===f?function(){}:f,m=e.onToggle,g=void 0===m?function(){}:m,v=e.emptyStateElement,y=void 0===v?null:v,b=e.selectedAssetIds,x=void 0===b?[]:b,_=e.selectionMode,w=void 0===_?"MultiSelect":_,S=e.theme,E=e.children,k=void 0===E?null:E,C=l(null),T=Jd(C.current).dimensions,N=r([]),I=N[0],O=N[1],A=r("inactive"),P=A[0],B=A[1],R=function(e,t){return void 0!==e?[1,e]:t?[Math.ceil(t.height/188),Math.round((t.width-16)/208)]:[0,0]}(i,T),F=R[0],z=R[1];function L(e){return("inverse"!==P||!x.includes(e.id)||!I.includes(e.id))&&(x.includes(e.id)||I.includes(e.id))}return t.createElement("div",{className:"flex flex-col flex-grow overflow-y-auto",ref:C,"data-drag-select-container":!0},k,t.createElement("div",{className:"card-list"},"Loading"===o.tag&&!o.value&&t.createElement(Xu,{rows:F,columns:z}),"Loaded"===o.tag&&0===o.value.length&&y,("Loading"===o.tag&&o.value||"Loaded"===o.tag)&&t.createElement(t.Fragment,null,"MultiSelect"===w&&t.createElement(Mp,{dragContainer:"[data-drag-select-container]",selectionBoxCustomAttr:{className:"rounded border-2 border-brand-500",style:{zIndex:1e6,borderColor:null==S?void 0:S.colorPrimary}},onSelect:function(e){O((function(t){return wr(t,e)}))},onDeselect:function(e){O((function(t){return t.filter((function(t){return!e.includes(t)}))}))},onDragStart:function(e){B(e)},onDragEnd:function(e){if(B("inactive"),I.length){var t=[];I.forEach((function(e){var n=function(e){var t;if("Loading"!==o.tag||o.value)return null===(t=o.value)||void 0===t?void 0:t.find((function(t){return e===t.id}))}(e);n&&t.push(n)})),"inverse"===e?g(t):h(t),O([])}}}),t.createElement(up,{hasNextPage:s,isLoading:u,loadMore:p},null===(n=o.value)||void 0===n?void 0:n.map((function(e,n){return t.createElement(Bp,{key:e.id,isSelected:L(e),isOutlined:L(e),asset:e,fadeIn:n>=F*z,onClick:function(e,t){return function(e,t){var n,r,i;if(t.shiftKey&&"MultiSelect"===w&&(null===(n=o.value)||void 0===n?void 0:n.length)){var a=o.value.findIndex((function(t){return t.id===e.id})),s=null===(r=o.value)||void 0===r?void 0:r.findIndex((function(e){return e.id===x[x.length-1]}));h(s<a?null===(i=o.value)||void 0===i?void 0:i.slice(s,a+1):o.value.slice(a,s+1))}else g([e])}(e,t)}})}))))))}function Gp(e){var n,r,o,i,s=e.connection,c=s.data,l=s.isLoading,u=s.loadMore,d=s.hasNextPage,p=s.executeQuery,f=Ar().setIsLoading,h=sa(),m=$d().selection.filter((function(e){return"asset"===e.type})).map((function(e){return e.value.id})),g=$d(),v=g.selectAssets,y=g.toggleAssets,b=Ar().setSearch,x=bp();if(a((function(){l||f(!1)}),[l]),"Failure"===c.tag)return t.createElement(Du,{error:new Error(c.value),onRetry:p});var _=null!==(i=null===(o=null===(r=null===(n=c.value)||void 0===n?void 0:n.searchAssets)||void 0===r?void 0:r.assets)||void 0===o?void 0:o.totalCount)&&void 0!==i?i:e.totalCount;return t.createElement(Yp,{assets:Xp(c),count:_,isLoading:l,loadMore:u,hasNextPage:d,theme:h.theme,selectionMode:h.selectionMode,selectedAssetIds:m,onSelect:v,onToggle:y,emptyStateElement:t.createElement(pp,{onReset:function(){x.clear(),b("assets",""),b("collection","")}})},t.createElement("div",{className:"flex justify-between items-center px-4 pt-4 pb-2 z-10"},void 0!==_&&t.createElement("span",{className:"flex-shrink-0 text-body-400 fade-in-down",key:_},$u(_,ma("{} asset"),ma("{} assets"))),e.showActiveFilters&&t.createElement(Tp,null),t.createElement(Wu,null),t.createElement(Hu,null)))}function Xp(e){var t;return"Loading"!==e.tag||e.value?"Loading"===e.tag?{tag:e.tag,value:null===(t=e.value)||void 0===t?void 0:t.searchAssets.assets.nodes}:{tag:e.tag,value:e.value.searchAssets.assets.nodes}:{tag:"Loading",value:void 0}}function Jp(e){var n=Pr("collection").value,r=kr()[1],o=pr("collection")[0],i=sa(),a=i.assetTypes,s=i.language,c=jd({collection:e.collection,allAssetTypes:a,searchTerm:n,orderBy:o,language:s});return t.createElement(t.Fragment,null,t.createElement("nav",{className:"px-4 py-4","data-testid":"collection-toolbar"},t.createElement("button",{className:"text-body-400 select-none cursor-pointer",onClick:function(){return r({page:"collections"})},type:"button"},ma("Collections")," / "),t.createElement("span",null," ",e.collection.name," ")),t.createElement(Gp,{connection:c,totalCount:e.collection.assetCount}))}function Kp(e){var n=e.className,r=e.onClick,o=e.isChecked,i=void 0!==o&&o,a=e.title;return t.createElement("div",{onClick:r,className:fa("cbx",i&&"cbx--checked",n),title:a},t.createElement("svg",{viewBox:"0 0 12 11"},t.createElement("polyline",{points:"1 6.29411765 4.5 10 11 1"})))}function Zp(e){var n=void 0!==e.selectedOptionIds&&e.selectedOptionIds.includes(e.metapropertyOption.id),r=fa("flex items-center py-2 px-4 text-sm hover:bg-ui-400 transition-color",!n&&"text-body-400",!n&&e.isLoading?"cursor-wait cursor-default":"cursor-pointer");return t.createElement("li",{className:r,onClick:function(){n?e.onRemoveOption():e.isLoading||e.onAddOption()},"data-testid":"metaproperty-option"},t.createElement(Kp,{isChecked:n,className:"mr-2"}),t.createElement("span",{className:"flex-grow mr-4 my-px truncate fade-in-down",title:e.metapropertyOption.label},e.metapropertyOption.label),t.createElement("span",{className:"fade-in-down"},e.metapropertyOption.assetCount))}function Qp(e){return t.createElement("div",{className:"pt-4 w-56","data-testid":"metaproperty-filter-content"},t.createElement("h1",{className:"mb-2 px-4 truncate",title:e.metaproperty.label},e.metaproperty.label),t.createElement("ul",{className:"overflow-y-auto pb-1 max-h-400"},e.metaproperty.options.map((function(n){return t.createElement(Zp,{key:n.id,metapropertyOption:n,selectedOptionIds:e.selectedOptionIds,isLoading:e.isLoading,onAddOption:function(){return e.onAddOption(n)},onRemoveOption:function(){return e.onRemoveOption(n)}})}))))}function ef(e){return t.createElement("div",{className:"flex"},e.smartfilter.metaproperties.map((function(n){return t.createElement(Qp,{key:n.id,metaproperty:n,selectedOptionIds:e.selectedOptionIds,isLoading:e.isLoading,onAddOption:e.onAddOption,onRemoveOption:e.onRemoveOption})})))}function tf(e){var n=bp(),r=n.metaproperties.map((function(e){return e.id})),o=function(e){var t=function(e){return"Metaproperty"===e.__typename?1e4:e.zIndex};return wr(e).sort((function(e,n){return t(e)-t(n)}))}(e.metapropertyFilters.filter((function(e){return"Metaproperty"===e.__typename||0!==e.metaproperties.length})));return t.createElement(t.Fragment,null,o.map((function(o){return t.createElement(qu,{key:o.id,title:t.createElement(nf,{filter:o}),alt:o.label,buttonClassName:"text-sm fade-in-down"},(function(){return t.createElement(t.Fragment,null,e.isLoading&&t.createElement(Nd,{className:"absolute top-0 right-0 mr-2 mt-3 bg-ui-0"}),"Metaproperty"===o.__typename?t.createElement(Qp,{metaproperty:o,selectedOptionIds:r,isLoading:e.isLoading,onAddOption:n.addMetaproperty,onRemoveOption:n.removeMetaproperty}):t.createElement(ef,{smartfilter:o,selectedOptionIds:r,isLoading:e.isLoading,onAddOption:n.addMetaproperty,onRemoveOption:n.removeMetaproperty}))}))})))}function nf(e){var n=e.filter;return t.createElement(t.Fragment,null,"Smartfilter"===n.__typename&&n.icon&&t.createElement("i",{className:fa("fa fa-lg mr-2",n.icon)}),t.createElement("span",{className:"max-w-24 truncate","data-testid":"metaproperty-filter"},n.label))}function rf(e){var n=bp(),r=n.tags.includes(e.tag.name),o=fa("mb-2 mr-2",r&&"bg-ui-500",e.isLoading&&!r?"cursor-default":"cursor-pointer");return t.createElement(kp,{key:e.tag.id,className:o,onClick:function(){r?n.removeTag(e.tag.name):e.isLoading||n.addTag(e.tag.name)},"data-testid":"tag-item"},t.createElement("span",{className:"max-w-32 truncate"},e.tag.name),t.createElement("span",{className:"text-body-400 ml-2"},e.tag.assetCount))}function of(e){var n=wr(e.tags).sort((function(e,t){return t.assetCount-e.assetCount}));return t.createElement(qu,{title:t.createElement(af,null),className:"pt-4 pb-1 overflow-hidden max-w-600",buttonClassName:"text-sm fade-in-down"},(function(){return t.createElement(t.Fragment,null,e.isLoading&&t.createElement(Nd,{className:"absolute top-0 right-0 mr-2 mt-3 bg-ui-0"}),t.createElement("h1",{className:"px-4 mb-4"}," ",ma("Tags")," "),t.createElement("div",{className:"flex flex-wrap px-4 -mr-2"},n.map((function(n){return t.createElement(rf,{key:n.id,tag:n,isLoading:e.isLoading})}))))}))}function af(){return t.createElement(t.Fragment,null,t.createElement(Jc,{className:"mr-2 inline w-6 h-6"}),t.createElement("span",{"data-testid":"tags-filter"},ma("Tags")))}function sf(e){var n=bp(),r=n.assetTypes.includes(e.type),o=fa("flex items-center py-2 px-4 text-sm hover:bg-ui-400 transition-color",!r&&"text-body-400",!r&&e.isLoading?"cursor-wait cursor-default":"cursor-pointer"),i=_p(e.type);return t.createElement("li",{className:o,onClick:function(){r?n.removeAssetType(e.type):n.addAssetType(e.type)},"data-testid":xp(e.type)+"-filter"},t.createElement(Kp,{isChecked:r,className:"mr-2"}),t.createElement(i,{className:"w-6 h-6 mr-2 -my-2"}),t.createElement("span",{className:"flex-grow mr-2 my-px"},xp(e.type)),t.createElement("span",{className:"fade-in-down"},e.count))}function cf(e){var n=sa().assetTypes,r=n.filter((function(t){return uf(e.count,t)>0}));return 0===n.length||0===r.length?null:t.createElement(qu,{title:t.createElement(lf,null),className:"pt-4 pb-1",buttonClassName:"text-sm fade-in-down"},(function(){return t.createElement(t.Fragment,null,e.isLoading&&t.createElement(Nd,{className:"absolute top-0 right-0 mr-2 mt-3 bg-ui-0"}),t.createElement("h1",{className:"px-4 mb-4"},ma("Type")),t.createElement("ul",null,r.map((function(n){return t.createElement(sf,{key:n,type:n,count:uf(e.count,n),isLoading:e.isLoading})}))))}))}function lf(){return t.createElement(t.Fragment,null,t.createElement(al,{className:"mr-2 inline w-6 h-6"}),ma("Advanced"))}function uf(e,t){switch(t){case"AUDIO":return e.audio;case"DOCUMENT":return e.document;case"IMAGE":return e.image;case"VIDEO":return e.video}}function df(){var e=bp(),n=Pr("assets").value,o=sa(),i=o.assetTypes,s=o.language;va(s);var c=function(e){var t=this,n=Ld(),o=r({tag:"Loading",value:null}),i=o[0],s=o[1],c=!1;return a((function(){return vr(t,void 0,void 0,(function(){var t,r,o,i,a,l;return yr(this,(function(u){switch(u.label){case 0:return s((function(e){return{tag:"Loading",value:"Failure"===e.tag?null:e.value}})),t=e.filter,r=e.searchTerm,o=e.allAssetTypes,i=e.language,[4,od("\nquery searchAssets($filter: AssetFilter!, $language: String!) {\n searchAssets(filter: $filter) {\n tags {\n nodes {\n id\n name\n assetCount\n }\n }\n metapropertyFilters {\n nodes {\n __typename\n ... on Smartfilter {\n id\n label(language: $language)\n metaproperties {\n id\n label(language: $language)\n options {\n id\n label(language: $language)\n assetCount\n }\n }\n icon\n zIndex\n }\n ... on Metaproperty {\n id\n label(language: $language)\n options {\n id\n label(language: $language)\n assetCount\n }\n }\n }\n }\n count {\n assetType {\n image\n video\n audio\n document\n }\n }\n }\n }",{filter:{assetType_in:null!==(l=t.assetTypes)&&void 0!==l?l:o,collectionId:null,isLimitedUse:!1,metapropertyOptionId_in:t.metaproperties.map((function(e){return e.id})),searchTerm:r,tagNames_in:t.tags},language:i},n)];case 1:return a=u.sent(),c||(td(a)?s({tag:"Failure",value:a.error}):s({tag:"Loaded",value:a.value})),[2]}}))})),function(){c=!0}}),[e.filter.assetTypes,e.filter.metaproperties,e.filter.tags,e.searchTerm]),{data:i,isLoading:"Loading"===i.tag}}({filter:e,searchTerm:n||null,allAssetTypes:i,language:s}),l=c.data,u=c.isLoading;if("Failure"===l.tag||!l.value)return t.createElement("nav",{className:"flex justify-between bg-ui-0 px-4 py-2 z-20"},t.createElement(pf,null));var d=l.value.searchAssets,p=d.metapropertyFilters,f=d.tags,h=d.count;return t.createElement("nav",{className:"flex justify-between bg-ui-0 px-4 py-2 z-20","data-testid":"filter-nav"},t.createElement(Ep,{className:"h-8"},p&&p.nodes.length>0&&t.createElement(tf,{metapropertyFilters:p.nodes,isLoading:u}),f&&f.nodes.length>0&&t.createElement(of,{tags:f.nodes,isLoading:u}),t.createElement(cf,{isLoading:u,count:h.assetType})))}function pf(){return t.createElement("div",{className:"inline-flex items-center"},t.createElement(Gu,{className:"h-4 ml-2 mr-2 my-2",width:100}),t.createElement(Gu,{className:"h-4 ml-2 mr-2 my-2",width:80}),t.createElement(Gu,{className:"h-4 ml-2 mr-2 my-2",width:110}))}function ff(){var e=kr()[0],n=Pr(e.page),o=n.value,i=n.isLoading,s=n.setSearch,c=Rp(s,500),l=r(o),u=l[0],d=l[1];a((function(){d(o)}),[e,o]),a((function(){return function(){c.flush()}}),[e,c]);var p="collections"===e.page?ma("Search for collections"):ma("Search for assets"),f=!i&&""!==o;return t.createElement("div",{className:"w-full inline-flex relative text-body-300 focus-within:text-body-400\n\t\t\t transition-color",style:{maxWidth:"440px"}},t.createElement("div",{className:"pointer-events-none absolute inset-y-0 left-0 pl-3 flex items-center"},t.createElement(Zc,{className:"fill-current pointer-events-none w-6 h-6"})),t.createElement("input",{value:u,className:"appearance-none block w-full border border-ui-600 rounded py-2 pr-4\n\t\t\t\t pl-10 text-body-500 placeholder-body-300 focus:outline-none\n\t\t\t\t hover:border-ui-900 focus:border-ui-900 transition-color",placeholder:p,onChange:function(e){return t=e.target.value,d(t),void c(t);var t},"data-testid":"search-input"}),i&&t.createElement("div",{role:"alert","aria-live":"polite"},t.createElement(Nd,{className:"absolute right-0 mr-3 h-full"})),f&&t.createElement("button",{"data-testid":"clear-search-input",className:"h-full absolute right-3 focus:outline-none text-body-300\n\t\t\t\t\t hover:text-body-400 fade-in",onClick:function(){d(""),s("")},type:"button"},t.createElement(cl,{className:"w-6 h-6"})))}function hf(){var e=kr(),n=e[0],r=e[1];return t.createElement("div",{className:"inline-flex mr-auto"},t.createElement(ha,{className:"assets"===n.page?"bg-ui-500 text-body-500":void 0,onClick:function(){return r({page:"assets"})}},ma("Assets")),t.createElement(ha,{className:"collections"===n.page?"bg-ui-500 text-body-500":void 0,onClick:function(){return r({page:"collections"})}},ma("Collections")))}function mf(){var e,n="authenticated"===(null===(e=i(Rd))||void 0===e?void 0:e.status)||!1,r=Sd(),o=Ld(),a=void 0!==sa().assetFilter;return n||r||!a?t.createElement("nav",{className:"flex justify-between bg-ui-0 px-4 py-3 z-30"},!a&&t.createElement(t.Fragment,null,t.createElement(hf,null),t.createElement(ff,null)),t.createElement("div",{className:"inline-flex ml-auto"},n&&t.createElement(ha,{onClick:function(){return null==o?void 0:o.logout()}},t.createElement("span",{className:"mr-1"}," ",ma("Log out")," "),t.createElement(Xc,{className:"w-6 h-6 -mr-1"})),r&&t.createElement(ha,{onClick:function(){return r.onClose()},title:ma("Close")},t.createElement(fl,{className:"w-6 h-6 -mx-1"})))):null}function gf(){var e=bp(),n=e.assetTypes,r=e.metaproperties,o=e.tags,i=Pr("assets").value,a=pr("assets")[0],s=sa(),c=s.assetFilter,l=s.assetTypes,u=s.language,d=jd(void 0===c?{filter:{assetTypes:n,metaproperties:r,tags:o},searchTerm:i,orderBy:a,allAssetTypes:l,language:u}:{predefinedFilter:c,orderBy:a,language:u});return t.createElement(Gp,{connection:d,showActiveFilters:void 0===c})}function vf(e,t,n){return void 0===n&&(n="\n id\n name\n description\n databaseId\n createdAt\n originalUrl\n publishedAt\n tags\n type\n updatedAt\n url\n metaproperties {\n nodes {\n name\n type\n options {\n name\n displayLabel\n }\n }\n }\n textMetaproperties {\n name\n value\n }\n derivatives {\n thumbnail\n webImage\n }\n ... on Video {\n previewUrls\n }\n"),vr(this,void 0,void 0,(function(){var r;return yr(this,(function(o){switch(o.label){case 0:return[4,od("\n fragment AddMediaAsset on Asset {\n "+n+"\n }\n\n query getAssetById($id: ID!) {\n node(id: $id) {\n __typename\n id\n ...on Asset {\n ...AddMediaAsset\n files\n }\n }\n }",{id:e},t)];case 1:return td(r=o.sent())?[2,r]:[2,Zu(r.value.node)]}}))}))}function yf(e){return e.replace(/([a-z0-9])([A-Z])/g,(function(e,t,n){return t+" "+n}))}function bf(e){var n=r({status:"Loading"}),o=n[0],i=n[1],s=Ld(),c=sa().assetFieldSelection;return a((function(){i({status:"Loading"}),e.onChange(void 0),function(e,t,n){return vr(this,void 0,void 0,(function(){var r;return yr(this,(function(o){switch(o.label){case 0:return[4,vf(e.id,t,n)];case 1:return[2,ed(r=o.sent())&&r.value.files?Zu(r.value.files):Qu("Error retrieving asset files")]}}))}))}(e.asset,s,c).then((function(t){if(td(t))return ta.error(t.error),void i({status:"Failure"});var n=t.value,r=function(e){return"transformBaseUrl"in e?"transformBaseUrl":"original"in e?"original":"webImage"}(n);i({status:"Data",files:n,key:r}),e.onChange(n[r])}))}),[e.asset.id,s,c]),t.createElement(qu,{title:t.createElement(xf,{state:o}),buttonKind:"Secondary",className:"py-2",buttonClassName:"mr-4 capitalize",direction:"Up",disabled:"Loading"===o.status},(function(n){return"Data"===o.status&&t.createElement("ul",{className:"overflow-y-auto pb-1 max-h-400"},Object.entries(o.files).map((function(r){var a,s=r[0],c=r[1];return t.createElement(Vu,{key:s,className:"px-3 py-2",selected:o.key===s,onClick:function(){!function(t){i((function(n){return"Data"!==n.status?n:(e.onChange(n.files[t]),mr(mr({},n),{key:t}))}))}(s),n()}},t.createElement("div",{className:"w-10 h-10 mr-3 bg-ui-500 rounded flex items-center\n\t\t\t\t\t\t\t\t\t justify-center font-semibold text-body-400 text-xs\n\t\t\t\t\t\t\t\t\t uppercase","data-testid":"file-extension"},"transformBaseUrl"===s?t.createElement(Gc,{className:"w-6 h-6"}):null!==(a=function(e){if(e)return function(e){var t=e.match(/filename=(.*?)&/);if(t){var n=/(?:\.([^.]+))?$/.exec(t[1]);if(n&&n[1])return n[1]}}(e)||function(e){var t=e.split("/"),n=t[t.length-1].split(".");if(!(n.length<=1)){var r=n[n.length-1],o=r.indexOf("?");return-1!==o?r.substring(0,o):r}}(e)}(c.url))&&void 0!==a?a:t.createElement(rl,{className:"w-6 h-6"})),t.createElement("div",{className:"flex-grow w-40"},t.createElement("div",{className:"capitalize text-body-500 truncate"},yf(s)),t.createElement("div",{className:"text-sm"},c.width&&c.height&&c.width+" x "+c.height+" px",c.width&&c.height&&c.fileSize&&t.createElement("span",{className:"mx-2"},"•"),c.fileSize&&function(e){if(e<1)return"0 Bytes";var t=Math.floor(Math.log(e)/Math.log(1024));return(e/Math.pow(1024,t)).toFixed(1)+" "+{0:"Bytes",1:"kB",2:"MB",3:"GB",4:"TB",5:"PB",6:"EB",7:"ZB",8:"YB"}[t]}(c.fileSize))))})))}))}function xf(e){var n=e.state;return"Loading"===n.status?t.createElement(Gu,{width:50,className:"h-4"}):"Data"===n.status?t.createElement(t.Fragment,null,yf(n.key)):t.createElement(t.Fragment,null,"Error")}function _f(e){var n=e.status,r=e.numberOfSelectedItems;return"Done"===n?t.createElement(ll,{"data-testid":"check",className:"w-6 h-6"}):"Error"===n?t.createElement(t.Fragment,null,ma("Retry")):"Loading"===n?t.createElement(Nd,{className:"text-ui-0"}):t.createElement(t.Fragment,null,$u(r,ma("Add asset"),ma("Add assets")))}function wf(e){var n,o=sa(),i=o.assetFieldSelection,s=o.onSuccess,c=o.selectionMode,u=Ld(),d=l(!0),p=r("SingleSelectFile"===c?{status:"WaitingForFileSelection"}:{status:"Ready"}),f=p[0],h=p[1];function m(e,t){if(td(e))h({status:"Error"});else{try{var n=Array.isArray(e.value)?e.value:[e.value];s(n,{selectedFile:t})}catch(e){ta.error(e)}d.current&&(h({status:"Done"}),setTimeout((function(){d.current&&h({status:"Ready"})}),2e3))}}return a((function(){return function(){d.current=!1}}),[]),t.createElement(t.Fragment,null,"SingleSelectFile"===c&&"asset"===(null===(n=e.selection[0])||void 0===n?void 0:n.type)&&t.createElement(bf,{asset:e.selection[0].value,onChange:function(e){h(void 0===e?{status:"WaitingForFileSelection"}:{status:"ReadyWithFile",file:e})}}),t.createElement(ha,{kind:"Primary",className:"relative",isDisabled:"Loading"===f.status||"WaitingForFileSelection"===f.status,onClick:function(){var t,n="ReadyWithFile"===f.status?f.file:void 0;h({status:"Loading"}),"MultiSelect"!==c&&"asset"===(null===(t=e.selection[0])||void 0===t?void 0:t.type)?vf(e.selection[0].value.id,u,i).then((function(e){m(e,n)})):function(e,t,n){return void 0===n&&(n="\n id\n name\n description\n databaseId\n createdAt\n originalUrl\n publishedAt\n tags\n type\n updatedAt\n url\n metaproperties {\n nodes {\n name\n type\n options {\n name\n displayLabel\n }\n }\n }\n textMetaproperties {\n name\n value\n }\n derivatives {\n thumbnail\n webImage\n }\n ... on Video {\n previewUrls\n }\n"),vr(this,void 0,void 0,(function(){var r,o,i,a,s,c,l,u,d,p,f,h;return yr(this,(function(m){switch(m.label){case 0:return r="\n fragment AddMediaAsset on Asset {\n "+n+"\n }\n\n query getAssetsById($ids: [ID!]!) {\n nodes(ids: $ids) {\n __typename\n id\n ...on Asset {\n ...AddMediaAsset\n files\n }\n ...on Collection {\n assets {\n nodes {\n __typename\n id\n ...AddMediaAsset\n files\n }\n }\n }\n }\n }",o={ids:e.map((function(e){return e.value.id}))},[4,od(r,o,t)];case 1:if(td(i=m.sent()))return[2,i];for(a=[],s=0,c=i.value.nodes;s<c.length;s++)"Collection"===(l=c[s]).__typename?a.push.apply(a,l.assets.nodes):a.push(l);for(u=new Set,d=[],p=0,f=a;p<f.length;p++)h=f[p],u.has(h.id)||(d.push(h),u.add(h.id));return[2,Zu(d)]}}))}))}(e.selection,u,i).then((function(e){m(e,n)}))},testId:"add-button"},t.createElement(_f,{status:f.status,numberOfSelectedItems:e.selection.length})))}function Sf(e){var n=e.title,r=e.onRemove,o=e.children;return t.createElement("li",{className:"flex flex-1 h-12 border-b last:border-b-0 pl-3 pr-5 py-1 items-center group relative",title:n},t.createElement(Kp,{isChecked:!0,className:"ml-2 mr-5 cursor-pointer",onClick:r,title:ma("Deselect")}),o)}function Ef(e){var n=e.asset,r=$d();return t.createElement(Sf,{title:n.name,onRemove:function(){return r.toggleAssets([n])}},t.createElement("img",{alt:n.name,className:"w-10 h-10 mr-3 select-none object-cover bg-ui-500 rounded",src:Ap(n),draggable:!1}),t.createElement("span",{className:"w-40 mr-2 truncate"},n.name),Pp(n)&&t.createElement("span",{className:"flex-grow text-body-400 text-sm text-right"},Pp(n)))}function kf(e){var n=e.collection,r=$d();return t.createElement(Sf,{title:n.name,onRemove:function(){return r.toggleCollection(n)}},t.createElement("div",{className:"w-10 h-10 mr-3 bg-ui-500 rounded flex items-center justify-center"},t.createElement(il,{className:"w-6 h-6 text-body-500 opacity-75"})),t.createElement("span",{className:"w-40 mr-2 truncate"},n.name),t.createElement("span",{className:"flex-grow text-body-400 text-sm text-right"},$u(n.assetCount,ma("{} asset"),ma("{} assets"))))}function Cf(e){var n=e.selection;return t.createElement("ul",{className:"flex flex-col py-2 overflow-y-auto max-h-400","data-testid":"selected-items-list"},n.map((function(e){return"asset"===e.type?t.createElement(Ef,{key:e.value.id,asset:e.value}):t.createElement(kf,{key:e.value.id,collection:e.value})})))}function Tf(){var e=$d(),n=e.selection,r=e.clear,o=n.length;return 0===o?null:t.createElement("div",{className:"flex flex-shrink-0 h-16 z-10 px-6 items-center shadow-footer fade-in-down","data-testid":"selection-footer"},t.createElement("span",{className:"flex-grow flex items-center"},t.createElement(qu,{buttonKind:"Secondary",direction:"Up",title:ma("View {} selected").replace("{}",o.toString())},(function(){return t.createElement(Cf,{selection:n})})),t.createElement(ha,{className:"ml-1",onClick:r},ma("Clear selection"))),t.createElement(wf,{selection:n}))}function Nf(e){return"[object String]"===Object.prototype.toString.call(e)}function If(e){return"[object Object]"===Object.prototype.toString.call(e)}function Of(e){return Boolean(e&&e.then&&"function"==typeof e.then)}function Af(e,t){try{return e instanceof t}catch(e){return!1}}function Pf(e){var t,n,r,o,i,a=e,s=[];if(!a||!a.tagName)return"";if(s.push(a.tagName.toLowerCase()),a.id&&s.push("#"+a.id),(t=a.className)&&Nf(t))for(n=t.split(/\s+/),i=0;i<n.length;i++)s.push("."+n[i]);var c=["type","name","title","alt"];for(i=0;i<c.length;i++)r=c[i],(o=a.getAttribute(r))&&s.push("["+r+'="'+o+'"]');return s.join("")}function Bf(){return"[object process]"===Object.prototype.toString.call("undefined"!=typeof process?process:0)}function Rf(e,t){return e.require(t)}function Ff(e){var t;try{t=Rf(module,e)}catch(e){}try{var n=Rf(module,"process").cwd;t=Rf(module,n()+"/node_modules/"+e)}catch(e){}return t}function zf(e,t){return!!Nf(e)&&(n=t,"[object RegExp]"===Object.prototype.toString.call(n)?t.test(e):"string"==typeof t&&-1!==e.indexOf(t));var n}var Lf={};function jf(){return Bf()?global:"undefined"!=typeof window?window:"undefined"!=typeof self?self:Lf}function Mf(){var e=jf(),t=e.crypto||e.msCrypto;if(void 0!==t&&t.getRandomValues){var n=new Uint16Array(8);t.getRandomValues(n),n[3]=4095&n[3]|16384,n[4]=16383&n[4]|32768;var r=function(e){for(var t=e.toString(16);t.length<4;)t="0"+t;return t};return r(n[0])+r(n[1])+r(n[2])+r(n[3])+r(n[4])+r(n[5])+r(n[6])+r(n[7])}return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}function Df(e){var t=jf();if(!("console"in t))return e();var n=t.console,r={};["debug","info","warn","error","log","assert"].forEach((function(e){e in t.console&&n[e].__sentry_original__&&(r[e]=n[e],n[e]=n[e].__sentry_original__)}));var o=e();return Object.keys(r).forEach((function(e){n[e]=r[e]})),o}var Hf=jf(),Uf="Sentry Logger ",qf=function(){function e(){this._enabled=!1}return e.prototype.disable=function(){this._enabled=!1},e.prototype.enable=function(){this._enabled=!0},e.prototype.log=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._enabled&&Df((function(){Hf.console.log(Uf+"[Log]: "+e.join(" "))}))},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._enabled&&Df((function(){Hf.console.warn(Uf+"[Warn]: "+e.join(" "))}))},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._enabled&&Df((function(){Hf.console.error(Uf+"[Error]: "+e.join(" "))}))},e}();Hf.__SENTRY__=Hf.__SENTRY__||{};var Vf=Hf.__SENTRY__.logger||(Hf.__SENTRY__.logger=new qf);function Wf(e){try{return e&&"function"==typeof e&&e.name||"<anonymous>"}catch(e){return"<anonymous>"}}function $f(e,t,n){if(t in e){var r=e[t],o=n(r);if("function"==typeof o)try{o.prototype=o.prototype||{},Object.defineProperties(o,{__sentry_original__:{enumerable:!1,value:r}})}catch(e){}e[t]=o}}function Yf(e){var t,n;if(If(e)){var r=e,o={};try{for(var i=br(Object.keys(r)),a=i.next();!a.done;a=i.next()){var s=a.value;void 0!==r[s]&&(o[s]=Yf(r[s]))}}catch(e){t={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return o}return Array.isArray(e)?e.map(Yf):e}function Gf(e){return e&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}var Xf,Jf,Kf,Zf=jf(),Qf={},eh={};function th(e){if(!eh[e])switch(eh[e]=!0,e){case"console":"console"in Zf&&["debug","info","warn","error","log","assert"].forEach((function(e){e in Zf.console&&$f(Zf.console,e,(function(t){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];rh("console",{args:n,level:e}),t&&Function.prototype.apply.call(t,Zf.console,n)}}))}));break;case"dom":!function(){if("document"in Zf){var e=rh.bind(null,"dom"),t=ah(e,!0);Zf.document.addEventListener("click",t,!1),Zf.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach((function(t){var n=Zf[t]&&Zf[t].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&($f(n,"addEventListener",(function(t){return function(n,r,o){if("click"===n||"keypress"==n)try{var i=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},a=i[n]=i[n]||{refCount:0};if(!a.handler){var s=ah(e);a.handler=s,t.call(this,n,s,o)}a.refCount+=1}catch(e){}return t.call(this,n,r,o)}})),$f(n,"removeEventListener",(function(e){return function(t,n,r){if("click"===t||"keypress"==t)try{var o=this.__sentry_instrumentation_handlers__||{},i=o[t];i&&(i.refCount-=1,i.refCount<=0&&(e.call(this,t,i.handler,r),i.handler=void 0,delete o[t]),0===Object.keys(o).length&&delete this.__sentry_instrumentation_handlers__)}catch(e){}return e.call(this,t,n,r)}})))}))}}();break;case"xhr":!function(){if("XMLHttpRequest"in Zf){var e=[],t=[],n=XMLHttpRequest.prototype;$f(n,"open",(function(n){return function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var i=this,a=r[1];i.__sentry_xhr__={method:Nf(r[0])?r[0].toUpperCase():r[0],url:r[1]},Nf(a)&&"POST"===i.__sentry_xhr__.method&&a.match(/sentry_key/)&&(i.__sentry_own_request__=!0);var s=function(){if(4===i.readyState){try{i.__sentry_xhr__&&(i.__sentry_xhr__.status_code=i.status)}catch(e){}try{var n=e.indexOf(i);if(-1!==n){e.splice(n);var o=t.splice(n)[0];i.__sentry_xhr__&&void 0!==o[0]&&(i.__sentry_xhr__.body=o[0])}}catch(e){}rh("xhr",{args:r,endTimestamp:Date.now(),startTimestamp:Date.now(),xhr:i})}};return"onreadystatechange"in i&&"function"==typeof i.onreadystatechange?$f(i,"onreadystatechange",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return s(),e.apply(i,t)}})):i.addEventListener("readystatechange",s),n.apply(i,r)}})),$f(n,"send",(function(n){return function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return e.push(this),t.push(r),rh("xhr",{args:r,startTimestamp:Date.now(),xhr:this}),n.apply(this,r)}}))}}();break;case"fetch":(function(){if(!function(){if(!("fetch"in jf()))return!1;try{return new Headers,new Request(""),new Response,!0}catch(e){return!1}}())return!1;var e=jf();if(Gf(e.fetch))return!0;var t=!1,n=e.document;if(n&&"function"==typeof n.createElement)try{var r=n.createElement("iframe");r.hidden=!0,n.head.appendChild(r),r.contentWindow&&r.contentWindow.fetch&&(t=Gf(r.contentWindow.fetch)),n.head.removeChild(r)}catch(e){Vf.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",e)}return t})()&&$f(Zf,"fetch",(function(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r={args:t,fetchData:{method:oh(t),url:ih(t)},startTimestamp:Date.now()};return rh("fetch",mr({},r)),e.apply(Zf,t).then((function(e){return rh("fetch",mr(mr({},r),{endTimestamp:Date.now(),response:e})),e}),(function(e){throw rh("fetch",mr(mr({},r),{endTimestamp:Date.now(),error:e})),e}))}}));break;case"history":!function(){if(function(){var e=jf(),t=e.chrome,n=t&&t.app&&t.app.runtime,r="history"in e&&!!e.history.pushState&&!!e.history.replaceState;return!n&&r}()){var e=Zf.onpopstate;Zf.onpopstate=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=Zf.location.href,o=Xf;if(Xf=r,rh("history",{from:o,to:r}),e)try{return e.apply(this,t)}catch(e){}},$f(Zf.history,"pushState",t),$f(Zf.history,"replaceState",t)}function t(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=t.length>2?t[2]:void 0;if(r){var o=Xf,i=String(r);Xf=i,rh("history",{from:o,to:i})}return e.apply(this,t)}}}();break;case"error":ch=Zf.onerror,Zf.onerror=function(e,t,n,r,o){return rh("error",{column:r,error:o,line:n,msg:e,url:t}),!!ch&&ch.apply(this,arguments)};break;case"unhandledrejection":lh=Zf.onunhandledrejection,Zf.onunhandledrejection=function(e){return rh("unhandledrejection",e),!lh||lh.apply(this,arguments)};break;default:Vf.warn("unknown instrumentation type:",e)}}function nh(e){e&&"string"==typeof e.type&&"function"==typeof e.callback&&(Qf[e.type]=Qf[e.type]||[],Qf[e.type].push(e.callback),th(e.type))}function rh(e,t){var n,r;if(e&&Qf[e])try{for(var o=br(Qf[e]||[]),i=o.next();!i.done;i=o.next()){var a=i.value;try{a(t)}catch(t){Vf.error("Error while triggering instrumentation handler.\nType: "+e+"\nName: "+Wf(a)+"\nError: "+t)}}}catch(e){n={error:e}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}}function oh(e){return void 0===e&&(e=[]),"Request"in Zf&&Af(e[0],Request)&&e[0].method?String(e[0].method).toUpperCase():e[1]&&e[1].method?String(e[1].method).toUpperCase():"GET"}function ih(e){return void 0===e&&(e=[]),"string"==typeof e[0]?e[0]:"Request"in Zf&&Af(e[0],Request)?e[0].url:String(e[0])}function ah(e,t){return void 0===t&&(t=!1),function(n){if(n&&Kf!==n&&!function(e){if("keypress"!==e.type)return!1;try{var t=e.target;if(!t||!t.tagName)return!0;if("INPUT"===t.tagName||"TEXTAREA"===t.tagName||t.isContentEditable)return!1}catch(e){}return!0}(n)){var r="keypress"===n.type?"input":n.type;(void 0===Jf||function(e,t){if(!e)return!0;if(e.type!==t.type)return!0;try{if(e.target!==t.target)return!0}catch(e){}return!1}(Kf,n))&&(e({event:n,name:r,global:t}),Kf=n),clearTimeout(Jf),Jf=Zf.setTimeout((function(){Jf=void 0}),1e3)}}}var sh,ch=null,lh=null;!function(e){e.PENDING="PENDING",e.RESOLVED="RESOLVED",e.REJECTED="REJECTED"}(sh||(sh={}));var uh,dh,ph,fh=function(){function e(e){var t=this;this._state=sh.PENDING,this._handlers=[],this._resolve=function(e){t._setResult(sh.RESOLVED,e)},this._reject=function(e){t._setResult(sh.REJECTED,e)},this._setResult=function(e,n){t._state===sh.PENDING&&(Of(n)?n.then(t._resolve,t._reject):(t._state=e,t._value=n,t._executeHandlers()))},this._attachHandler=function(e){t._handlers=t._handlers.concat(e),t._executeHandlers()},this._executeHandlers=function(){if(t._state!==sh.PENDING){var e=t._handlers.slice();t._handlers=[],e.forEach((function(e){e.done||(t._state===sh.RESOLVED&&e.onfulfilled&&e.onfulfilled(t._value),t._state===sh.REJECTED&&e.onrejected&&e.onrejected(t._value),e.done=!0)}))}};try{e(this._resolve,this._reject)}catch(e){this._reject(e)}}return e.resolve=function(t){return new e((function(e){e(t)}))},e.reject=function(t){return new e((function(e,n){n(t)}))},e.all=function(t){return new e((function(n,r){if(Array.isArray(t))if(0!==t.length){var o=t.length,i=[];t.forEach((function(t,a){e.resolve(t).then((function(e){i[a]=e,0==(o-=1)&&n(i)})).then(null,r)}))}else n([]);else r(new TypeError("Promise.all requires an array as input."))}))},e.prototype.then=function(t,n){var r=this;return new e((function(e,o){r._attachHandler({done:!1,onfulfilled:function(n){if(t)try{return void e(t(n))}catch(e){return void o(e)}else e(n)},onrejected:function(t){if(n)try{return void e(n(t))}catch(e){return void o(e)}else o(t)}})}))},e.prototype.catch=function(e){return this.then((function(e){return e}),e)},e.prototype.finally=function(t){var n=this;return new e((function(e,r){var o,i;return n.then((function(e){i=!1,o=e,t&&t()}),(function(e){i=!0,o=e,t&&t()})).then((function(){i?r(o):e(o)}))}))},e.prototype.toString=function(){return"[object SyncPromise]"},e}(),hh={nowSeconds:function(){return Date.now()/1e3}},mh=Bf()?function(){try{return Rf(module,"perf_hooks").performance}catch(e){return}}():function(){var e=jf().performance;if(e&&e.now)return{now:function(){return e.now()},timeOrigin:Date.now()-e.now()}}(),gh=void 0===mh?hh:{nowSeconds:function(){return(mh.timeOrigin+mh.now())/1e3}},vh=hh.nowSeconds.bind(hh),yh=gh.nowSeconds.bind(gh),bh=yh,xh=function(){var e=jf().performance;if(e){var t=e.now(),n=Date.now(),r=e.timeOrigin?Math.abs(e.timeOrigin+t-n):36e5,o=r<36e5,i=e.timing&&e.timing.navigationStart,a="number"==typeof i?Math.abs(i+t-n):36e5;return o||a<36e5?r<=a?e.timeOrigin:i:n}}(),_h=function(){function e(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._user={},this._tags={},this._extra={},this._contexts={}}return e.clone=function(t){var n=new e;return t&&(n._breadcrumbs=_r(t._breadcrumbs),n._tags=mr({},t._tags),n._extra=mr({},t._extra),n._contexts=mr({},t._contexts),n._user=t._user,n._level=t._level,n._span=t._span,n._session=t._session,n._transactionName=t._transactionName,n._fingerprint=t._fingerprint,n._eventProcessors=_r(t._eventProcessors),n._requestSession=t._requestSession),n},e.prototype.addScopeListener=function(e){this._scopeListeners.push(e)},e.prototype.addEventProcessor=function(e){return this._eventProcessors.push(e),this},e.prototype.setUser=function(e){return this._user=e||{},this._session&&this._session.update({user:e}),this._notifyScopeListeners(),this},e.prototype.getUser=function(){return this._user},e.prototype.getRequestSession=function(){return this._requestSession},e.prototype.setRequestSession=function(e){return this._requestSession=e,this},e.prototype.setTags=function(e){return this._tags=mr(mr({},this._tags),e),this._notifyScopeListeners(),this},e.prototype.setTag=function(e,t){var n;return this._tags=mr(mr({},this._tags),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setExtras=function(e){return this._extra=mr(mr({},this._extra),e),this._notifyScopeListeners(),this},e.prototype.setExtra=function(e,t){var n;return this._extra=mr(mr({},this._extra),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setFingerprint=function(e){return this._fingerprint=e,this._notifyScopeListeners(),this},e.prototype.setLevel=function(e){return this._level=e,this._notifyScopeListeners(),this},e.prototype.setTransactionName=function(e){return this._transactionName=e,this._notifyScopeListeners(),this},e.prototype.setTransaction=function(e){return this.setTransactionName(e)},e.prototype.setContext=function(e,t){var n;return null===t?delete this._contexts[e]:this._contexts=mr(mr({},this._contexts),((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setSpan=function(e){return this._span=e,this._notifyScopeListeners(),this},e.prototype.getSpan=function(){return this._span},e.prototype.getTransaction=function(){var e,t,n,r,o=this.getSpan();return(null===(e=o)||void 0===e?void 0:e.transaction)?null===(t=o)||void 0===t?void 0:t.transaction:(null===(r=null===(n=o)||void 0===n?void 0:n.spanRecorder)||void 0===r?void 0:r.spans[0])?o.spanRecorder.spans[0]:void 0},e.prototype.setSession=function(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this},e.prototype.getSession=function(){return this._session},e.prototype.update=function(t){if(!t)return this;if("function"==typeof t){var n=t(this);return n instanceof e?n:this}return t instanceof e?(this._tags=mr(mr({},this._tags),t._tags),this._extra=mr(mr({},this._extra),t._extra),this._contexts=mr(mr({},this._contexts),t._contexts),t._user&&Object.keys(t._user).length&&(this._user=t._user),t._level&&(this._level=t._level),t._fingerprint&&(this._fingerprint=t._fingerprint),t._requestSession&&(this._requestSession=t._requestSession)):If(t)&&(t=t,this._tags=mr(mr({},this._tags),t.tags),this._extra=mr(mr({},this._extra),t.extra),this._contexts=mr(mr({},this._contexts),t.contexts),t.user&&(this._user=t.user),t.level&&(this._level=t.level),t.fingerprint&&(this._fingerprint=t.fingerprint),t.requestSession&&(this._requestSession=t.requestSession)),this},e.prototype.clear=function(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this},e.prototype.addBreadcrumb=function(e,t){var n=mr({timestamp:vh()},e);return this._breadcrumbs=void 0!==t&&t>=0?_r(this._breadcrumbs,[n]).slice(-t):_r(this._breadcrumbs,[n]),this._notifyScopeListeners(),this},e.prototype.clearBreadcrumbs=function(){return this._breadcrumbs=[],this._notifyScopeListeners(),this},e.prototype.applyToEvent=function(e,t){var n;if(this._extra&&Object.keys(this._extra).length&&(e.extra=mr(mr({},this._extra),e.extra)),this._tags&&Object.keys(this._tags).length&&(e.tags=mr(mr({},this._tags),e.tags)),this._user&&Object.keys(this._user).length&&(e.user=mr(mr({},this._user),e.user)),this._contexts&&Object.keys(this._contexts).length&&(e.contexts=mr(mr({},this._contexts),e.contexts)),this._level&&(e.level=this._level),this._transactionName&&(e.transaction=this._transactionName),this._span){e.contexts=mr({trace:this._span.getTraceContext()},e.contexts);var r=null===(n=this._span.transaction)||void 0===n?void 0:n.name;r&&(e.tags=mr({transaction:r},e.tags))}return this._applyFingerprint(e),e.breadcrumbs=_r(e.breadcrumbs||[],this._breadcrumbs),e.breadcrumbs=e.breadcrumbs.length>0?e.breadcrumbs:void 0,this._notifyEventProcessors(_r(function(){var e=jf();return e.__SENTRY__=e.__SENTRY__||{},e.__SENTRY__.globalEventProcessors=e.__SENTRY__.globalEventProcessors||[],e.__SENTRY__.globalEventProcessors}(),this._eventProcessors),e,t)},e.prototype._notifyEventProcessors=function(e,t,n,r){var o=this;return void 0===r&&(r=0),new fh((function(i,a){var s=e[r];if(null===t||"function"!=typeof s)i(t);else{var c=s(mr({},t),n);Of(c)?c.then((function(t){return o._notifyEventProcessors(e,t,n,r+1).then(i)})).then(null,a):o._notifyEventProcessors(e,c,n,r+1).then(i).then(null,a)}}))},e.prototype._notifyScopeListeners=function(){var e=this;this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((function(t){t(e)})),this._notifyingListeners=!1)},e.prototype._applyFingerprint=function(e){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],this._fingerprint&&(e.fingerprint=e.fingerprint.concat(this._fingerprint)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint},e}();!function(e){e.Ok="ok",e.Exited="exited",e.Crashed="crashed",e.Abnormal="abnormal"}(uh||(uh={})),function(e){e.Ok="ok",e.Errored="errored",e.Crashed="crashed"}(dh||(dh={})),function(e){e.Explicit="explicitly_set",e.Sampler="client_sampler",e.Rate="client_rate",e.Inheritance="inheritance"}(ph||(ph={}));var wh=function(){function e(e,t,n){void 0===t&&(t=new _h),void 0===n&&(n=4),this._version=n,this._stack=[{}],this.getStackTop().scope=t,this.bindClient(e)}return e.prototype.isOlderThan=function(e){return this._version<e},e.prototype.bindClient=function(e){this.getStackTop().client=e,e&&e.setupIntegrations&&e.setupIntegrations()},e.prototype.pushScope=function(){var e=_h.clone(this.getScope());return this.getStack().push({client:this.getClient(),scope:e}),e},e.prototype.popScope=function(){return!(this.getStack().length<=1||!this.getStack().pop())},e.prototype.withScope=function(e){var t=this.pushScope();try{e(t)}finally{this.popScope()}},e.prototype.getClient=function(){return this.getStackTop().client},e.prototype.getScope=function(){return this.getStackTop().scope},e.prototype.getStack=function(){return this._stack},e.prototype.getStackTop=function(){return this._stack[this._stack.length-1]},e.prototype.captureException=function(e,t){var n=this._lastEventId=Mf(),r=t;if(!t){var o=void 0;try{throw new Error("Sentry syntheticException")}catch(e){o=e}r={originalException:e,syntheticException:o}}return this._invokeClient("captureException",e,mr(mr({},r),{event_id:n})),n},e.prototype.captureMessage=function(e,t,n){var r=this._lastEventId=Mf(),o=n;if(!n){var i=void 0;try{throw new Error(e)}catch(e){i=e}o={originalException:e,syntheticException:i}}return this._invokeClient("captureMessage",e,t,mr(mr({},o),{event_id:r})),r},e.prototype.captureEvent=function(e,t){var n=this._lastEventId=Mf();return this._invokeClient("captureEvent",e,mr(mr({},t),{event_id:n})),n},e.prototype.lastEventId=function(){return this._lastEventId},e.prototype.addBreadcrumb=function(e,t){var n=this.getStackTop(),r=n.scope,o=n.client;if(r&&o){var i=o.getOptions&&o.getOptions()||{},a=i.beforeBreadcrumb,s=void 0===a?null:a,c=i.maxBreadcrumbs,l=void 0===c?100:c;if(!(l<=0)){var u=vh(),d=mr({timestamp:u},e),p=s?Df((function(){return s(d,t)})):d;null!==p&&r.addBreadcrumb(p,Math.min(l,100))}}},e.prototype.setUser=function(e){var t=this.getScope();t&&t.setUser(e)},e.prototype.setTags=function(e){var t=this.getScope();t&&t.setTags(e)},e.prototype.setExtras=function(e){var t=this.getScope();t&&t.setExtras(e)},e.prototype.setTag=function(e,t){var n=this.getScope();n&&n.setTag(e,t)},e.prototype.setExtra=function(e,t){var n=this.getScope();n&&n.setExtra(e,t)},e.prototype.setContext=function(e,t){var n=this.getScope();n&&n.setContext(e,t)},e.prototype.configureScope=function(e){var t=this.getStackTop(),n=t.scope,r=t.client;n&&r&&e(n)},e.prototype.run=function(e){var t=Eh(this);try{e(this)}finally{Eh(t)}},e.prototype.getIntegration=function(e){var t=this.getClient();if(!t)return null;try{return t.getIntegration(e)}catch(t){return Vf.warn("Cannot retrieve integration "+e.id+" from the current Hub"),null}},e.prototype.startSpan=function(e){return this._callExtensionMethod("startSpan",e)},e.prototype.startTransaction=function(e,t){return this._callExtensionMethod("startTransaction",e,t)},e.prototype.traceHeaders=function(){return this._callExtensionMethod("traceHeaders")},e.prototype.captureSession=function(e){if(void 0===e&&(e=!1),e)return this.endSession();this._sendSessionUpdate()},e.prototype.endSession=function(){var e,t,n,r,o;null===(n=null===(t=null===(e=this.getStackTop())||void 0===e?void 0:e.scope)||void 0===t?void 0:t.getSession())||void 0===n||n.close(),this._sendSessionUpdate(),null===(o=null===(r=this.getStackTop())||void 0===r?void 0:r.scope)||void 0===o||o.setSession()},e.prototype.startSession=function(e){var t=this.getStackTop(),n=t.scope,r=t.client,o=r&&r.getOptions()||{},i=o.release,a=o.environment,s=new Oh(mr(mr({release:i,environment:a},n&&{user:n.getUser()}),e));if(n){var c=n.getSession&&n.getSession();c&&c.status===uh.Ok&&c.update({status:uh.Exited}),this.endSession(),n.setSession(s)}return s},e.prototype._sendSessionUpdate=function(){var e=this.getStackTop(),t=e.scope,n=e.client;if(t){var r=t.getSession&&t.getSession();r&&n&&n.captureSession&&n.captureSession(r)}},e.prototype._invokeClient=function(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var o=this.getStackTop(),i=o.scope,a=o.client;a&&a[e]&&(t=a)[e].apply(t,_r(n,[i]))},e.prototype._callExtensionMethod=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=Sh(),o=r.__SENTRY__;if(o&&o.extensions&&"function"==typeof o.extensions[e])return o.extensions[e].apply(this,t);Vf.warn("Extension method "+e+" couldn't be found, doing nothing.")},e}();function Sh(){var e=jf();return e.__SENTRY__=e.__SENTRY__||{extensions:{},hub:void 0},e}function Eh(e){var t=Sh(),n=Th(t);return Nh(t,e),n}function kh(){var e=Sh();return Ch(e)&&!Th(e).isOlderThan(4)||Nh(e,new wh),Bf()?function(e){var t,n,r;try{var o=null===(r=null===(n=null===(t=Sh().__SENTRY__)||void 0===t?void 0:t.extensions)||void 0===n?void 0:n.domain)||void 0===r?void 0:r.active;if(!o)return Th(e);if(!Ch(o)||Th(o).isOlderThan(4)){var i=Th(e).getStackTop();Nh(o,new wh(i.client,_h.clone(i.scope)))}return Th(o)}catch(t){return Th(e)}}(e):Th(e)}function Ch(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function Th(e){return e&&e.__SENTRY__&&e.__SENTRY__.hub||(e.__SENTRY__=e.__SENTRY__||{},e.__SENTRY__.hub=new wh),e.__SENTRY__.hub}function Nh(e,t){return!!e&&(e.__SENTRY__=e.__SENTRY__||{},e.__SENTRY__.hub=t,!0)}var Ih,Oh=function(){function e(e){this.errors=0,this.sid=Mf(),this.duration=0,this.status=uh.Ok,this.init=!0,this.ignoreDuration=!1;var t=yh();this.timestamp=t,this.started=t,e&&this.update(e)}return e.prototype.update=function(e){if(void 0===e&&(e={}),e.user&&(e.user.ip_address&&(this.ipAddress=e.user.ip_address),e.did||(this.did=e.user.id||e.user.email||e.user.username)),this.timestamp=e.timestamp||yh(),e.ignoreDuration&&(this.ignoreDuration=e.ignoreDuration),e.sid&&(this.sid=32===e.sid.length?e.sid:Mf()),void 0!==e.init&&(this.init=e.init),e.did&&(this.did=""+e.did),"number"==typeof e.started&&(this.started=e.started),this.ignoreDuration)this.duration=void 0;else if("number"==typeof e.duration)this.duration=e.duration;else{var t=this.timestamp-this.started;this.duration=t>=0?t:0}e.release&&(this.release=e.release),e.environment&&(this.environment=e.environment),e.ipAddress&&(this.ipAddress=e.ipAddress),e.userAgent&&(this.userAgent=e.userAgent),"number"==typeof e.errors&&(this.errors=e.errors),e.status&&(this.status=e.status)},e.prototype.close=function(e){e?this.update({status:e}):this.status===uh.Ok?this.update({status:uh.Exited}):this.update()},e.prototype.toJSON=function(){return Yf({sid:""+this.sid,init:this.init,started:new Date(1e3*this.started).toISOString(),timestamp:new Date(1e3*this.timestamp).toISOString(),status:this.status,errors:this.errors,did:"number"==typeof this.did||"string"==typeof this.did?""+this.did:void 0,duration:this.duration,attrs:Yf({release:this.release,environment:this.environment,ip_address:this.ipAddress,user_agent:this.userAgent})})},e}();!function(e){e.Ok="ok",e.DeadlineExceeded="deadline_exceeded",e.Unauthenticated="unauthenticated",e.PermissionDenied="permission_denied",e.NotFound="not_found",e.ResourceExhausted="resource_exhausted",e.InvalidArgument="invalid_argument",e.Unimplemented="unimplemented",e.Unavailable="unavailable",e.InternalError="internal_error",e.UnknownError="unknown_error",e.Cancelled="cancelled",e.AlreadyExists="already_exists",e.FailedPrecondition="failed_precondition",e.Aborted="aborted",e.OutOfRange="out_of_range",e.DataLoss="data_loss"}(Ih||(Ih={})),function(e){e.fromHttpCode=function(t){if(t<400)return e.Ok;if(t>=400&&t<500)switch(t){case 401:return e.Unauthenticated;case 403:return e.PermissionDenied;case 404:return e.NotFound;case 409:return e.AlreadyExists;case 413:return e.FailedPrecondition;case 429:return e.ResourceExhausted;default:return e.InvalidArgument}if(t>=500&&t<600)switch(t){case 501:return e.Unimplemented;case 503:return e.Unavailable;case 504:return e.DeadlineExceeded;default:return e.InternalError}return e.UnknownError}}(Ih||(Ih={}));var Ah=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function Ph(e){var t;return void 0===e&&(e=null===(t=kh().getClient())||void 0===t?void 0:t.getOptions()),!!e&&("tracesSampleRate"in e||"tracesSampler"in e)}function Bh(e){var t,n;return void 0===e&&(e=kh()),null===(n=null===(t=e)||void 0===t?void 0:t.getScope())||void 0===n?void 0:n.getTransaction()}function Rh(e){return e/1e3}function Fh(){var e=Bh();e&&(Vf.log("[Tracing] Transaction: "+Ih.InternalError+" -> Global error occured"),e.setStatus(Ih.InternalError))}var zh=function(){function e(e){void 0===e&&(e=1e3),this.spans=[],this._maxlen=e}return e.prototype.add=function(e){this.spans.length>this._maxlen?e.spanRecorder=void 0:this.spans.push(e)},e}(),Lh=function(e){function t(t,n){var r=e.call(this,t)||this;return r._measurements={},r._hub=kh(),Af(n,wh)&&(r._hub=n),r.name=t.name||"",r.metadata=t.metadata||{},r._trimEnd=t.trimEnd,r.transaction=r,r}return hr(t,e),t.prototype.setName=function(e){this.name=e},t.prototype.initSpanRecorder=function(e){void 0===e&&(e=1e3),this.spanRecorder||(this.spanRecorder=new zh(e)),this.spanRecorder.add(this)},t.prototype.setMeasurements=function(e){this._measurements=mr({},e)},t.prototype.setMetadata=function(e){this.metadata=mr(mr({},this.metadata),e)},t.prototype.finish=function(t){var n=this;if(void 0===this.endTimestamp){if(this.name||(Vf.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this.name="<unlabeled transaction>"),e.prototype.finish.call(this,t),!0===this.sampled){var r=this.spanRecorder?this.spanRecorder.spans.filter((function(e){return e!==n&&e.endTimestamp})):[];this._trimEnd&&r.length>0&&(this.endTimestamp=r.reduce((function(e,t){return e.endTimestamp&&t.endTimestamp?e.endTimestamp>t.endTimestamp?e:t:e})).endTimestamp);var o={contexts:{trace:this.getTraceContext()},spans:r,start_timestamp:this.startTimestamp,tags:this.tags,timestamp:this.endTimestamp,transaction:this.name,type:"transaction",debug_meta:this.metadata};return Object.keys(this._measurements).length>0&&(Vf.log("[Measurements] Adding measurements to transaction",JSON.stringify(this._measurements,void 0,2)),o.measurements=this._measurements),Vf.log("[Tracing] Finishing "+this.op+" transaction: "+this.name+"."),this._hub.captureEvent(o)}Vf.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled.")}},t.prototype.toContext=function(){var t=e.prototype.toContext.call(this);return Yf(mr(mr({},t),{name:this.name,trimEnd:this._trimEnd}))},t.prototype.updateWithContext=function(t){var n;return e.prototype.updateWithContext.call(this,t),this.name=null!=(n=t.name)?n:"",this._trimEnd=t.trimEnd,this},t}(function(){function e(e){if(this.traceId=Mf(),this.spanId=Mf().substring(16),this.startTimestamp=bh(),this.tags={},this.data={},!e)return this;e.traceId&&(this.traceId=e.traceId),e.spanId&&(this.spanId=e.spanId),e.parentSpanId&&(this.parentSpanId=e.parentSpanId),"sampled"in e&&(this.sampled=e.sampled),e.op&&(this.op=e.op),e.description&&(this.description=e.description),e.data&&(this.data=e.data),e.tags&&(this.tags=e.tags),e.status&&(this.status=e.status),e.startTimestamp&&(this.startTimestamp=e.startTimestamp),e.endTimestamp&&(this.endTimestamp=e.endTimestamp)}return e.prototype.child=function(e){return this.startChild(e)},e.prototype.startChild=function(t){var n=new e(mr(mr({},t),{parentSpanId:this.spanId,sampled:this.sampled,traceId:this.traceId}));return n.spanRecorder=this.spanRecorder,n.spanRecorder&&n.spanRecorder.add(n),n.transaction=this.transaction,n},e.prototype.setTag=function(e,t){var n;return this.tags=mr(mr({},this.tags),((n={})[e]=t,n)),this},e.prototype.setData=function(e,t){var n;return this.data=mr(mr({},this.data),((n={})[e]=t,n)),this},e.prototype.setStatus=function(e){return this.status=e,this},e.prototype.setHttpStatus=function(e){this.setTag("http.status_code",String(e));var t=Ih.fromHttpCode(e);return t!==Ih.UnknownError&&this.setStatus(t),this},e.prototype.isSuccess=function(){return this.status===Ih.Ok},e.prototype.finish=function(e){this.endTimestamp="number"==typeof e?e:bh()},e.prototype.toTraceparent=function(){var e="";return void 0!==this.sampled&&(e=this.sampled?"-1":"-0"),this.traceId+"-"+this.spanId+e},e.prototype.toContext=function(){return Yf({data:this.data,description:this.description,endTimestamp:this.endTimestamp,op:this.op,parentSpanId:this.parentSpanId,sampled:this.sampled,spanId:this.spanId,startTimestamp:this.startTimestamp,status:this.status,tags:this.tags,traceId:this.traceId})},e.prototype.updateWithContext=function(e){var t,n,r,o,i;return this.data=null!=(t=e.data)?t:{},this.description=e.description,this.endTimestamp=e.endTimestamp,this.op=e.op,this.parentSpanId=e.parentSpanId,this.sampled=e.sampled,this.spanId=null!=(n=e.spanId)?n:this.spanId,this.startTimestamp=null!=(r=e.startTimestamp)?r:this.startTimestamp,this.status=e.status,this.tags=null!=(o=e.tags)?o:{},this.traceId=null!=(i=e.traceId)?i:this.traceId,this},e.prototype.getTraceContext=function(){return Yf({data:Object.keys(this.data).length>0?this.data:void 0,description:this.description,op:this.op,parent_span_id:this.parentSpanId,span_id:this.spanId,status:this.status,tags:Object.keys(this.tags).length>0?this.tags:void 0,trace_id:this.traceId})},e.prototype.toJSON=function(){return Yf({data:Object.keys(this.data).length>0?this.data:void 0,description:this.description,op:this.op,parent_span_id:this.parentSpanId,span_id:this.spanId,start_timestamp:this.startTimestamp,status:this.status,tags:Object.keys(this.tags).length>0?this.tags:void 0,timestamp:this.endTimestamp,trace_id:this.traceId})},e}()),jh=function(e){function t(t,n,r,o){void 0===r&&(r="");var i=e.call(this,o)||this;return i._pushActivity=t,i._popActivity=n,i.transactionSpanId=r,i}return hr(t,e),t.prototype.add=function(t){var n=this;t.spanId!==this.transactionSpanId&&(t.finish=function(e){t.endTimestamp="number"==typeof e?e:bh(),n._popActivity(t.spanId)},void 0===t.endTimestamp&&this._pushActivity(t.spanId)),e.prototype.add.call(this,t)},t}(zh),Mh=function(e){function t(t,n,r,o){void 0===r&&(r=1e3),void 0===o&&(o=!1);var i=e.call(this,t,n)||this;return i._idleHub=n,i._idleTimeout=r,i._onScope=o,i.activities={},i._heartbeatTimer=0,i._heartbeatCounter=0,i._finished=!1,i._beforeFinishCallbacks=[],n&&o&&(Dh(n),Vf.log("Setting idle transaction on scope. Span ID: "+i.spanId),n.configureScope((function(e){return e.setSpan(i)}))),i._initTimeout=setTimeout((function(){i._finished||i.finish()}),i._idleTimeout),i}return hr(t,e),t.prototype.finish=function(t){var n,r,o=this;if(void 0===t&&(t=bh()),this._finished=!0,this.activities={},this.spanRecorder){Vf.log("[Tracing] finishing IdleTransaction",new Date(1e3*t).toISOString(),this.op);try{for(var i=br(this._beforeFinishCallbacks),a=i.next();!a.done;a=i.next())(0,a.value)(this,t)}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}this.spanRecorder.spans=this.spanRecorder.spans.filter((function(e){if(e.spanId===o.spanId)return!0;e.endTimestamp||(e.endTimestamp=t,e.setStatus(Ih.Cancelled),Vf.log("[Tracing] cancelling span since transaction ended early",JSON.stringify(e,void 0,2)));var n=e.startTimestamp<t;return n||Vf.log("[Tracing] discarding Span since it happened after Transaction was finished",JSON.stringify(e,void 0,2)),n})),Vf.log("[Tracing] flushing IdleTransaction")}else Vf.log("[Tracing] No active IdleTransaction");return this._onScope&&Dh(this._idleHub),e.prototype.finish.call(this,t)},t.prototype.registerBeforeFinishCallback=function(e){this._beforeFinishCallbacks.push(e)},t.prototype.initSpanRecorder=function(e){var t=this;this.spanRecorder||(this.spanRecorder=new jh((function(e){t._finished||t._pushActivity(e)}),(function(e){t._finished||t._popActivity(e)}),this.spanId,e),Vf.log("Starting heartbeat"),this._pingHeartbeat()),this.spanRecorder.add(this)},t.prototype._pushActivity=function(e){this._initTimeout&&(clearTimeout(this._initTimeout),this._initTimeout=void 0),Vf.log("[Tracing] pushActivity: "+e),this.activities[e]=!0,Vf.log("[Tracing] new activities count",Object.keys(this.activities).length)},t.prototype._popActivity=function(e){var t=this;if(this.activities[e]&&(Vf.log("[Tracing] popActivity "+e),delete this.activities[e],Vf.log("[Tracing] new activities count",Object.keys(this.activities).length)),0===Object.keys(this.activities).length){var n=this._idleTimeout,r=bh()+n/1e3;setTimeout((function(){t._finished||t.finish(r)}),n)}},t.prototype._beat=function(){if(clearTimeout(this._heartbeatTimer),!this._finished){var e=Object.keys(this.activities),t=e.length?e.reduce((function(e,t){return e+t})):"";t===this._prevHeartbeatString?this._heartbeatCounter+=1:this._heartbeatCounter=1,this._prevHeartbeatString=t,this._heartbeatCounter>=3?(Vf.log("[Tracing] Transaction finished because of no change for 3 heart beats"),this.setStatus(Ih.DeadlineExceeded),this.setTag("heartbeat","failed"),this.finish()):this._pingHeartbeat()}},t.prototype._pingHeartbeat=function(){var e=this;Vf.log("pinging Heartbeat -> current counter: "+this._heartbeatCounter),this._heartbeatTimer=setTimeout((function(){e._beat()}),5e3)},t}(Lh);function Dh(e){if(e){var t=e.getScope();t&&t.getTransaction()&&t.setSpan(void 0)}}function Hh(e,t,n){return Ph()?void 0!==e.sampled?(e.setMetadata({transactionSampling:{method:ph.Explicit}}),e):("function"==typeof t.tracesSampler?(o=t.tracesSampler(n),e.setMetadata({transactionSampling:{method:ph.Sampler,rate:Number(o)}})):void 0!==n.parentSampled?(o=n.parentSampled,e.setMetadata({transactionSampling:{method:ph.Inheritance}})):(o=t.tracesSampleRate,e.setMetadata({transactionSampling:{method:ph.Rate,rate:Number(o)}})),r=o,(isNaN(r)||"number"!=typeof r&&"boolean"!=typeof r?(Vf.warn("[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got "+JSON.stringify(r)+" of type "+JSON.stringify(typeof r)+"."),0):!(r<0||r>1)||(Vf.warn("[Tracing] Given sample rate is invalid. Sample rate must be between 0 and 1. Got "+r+"."),0))?o?(e.sampled=Math.random()<o,e.sampled?(Vf.log("[Tracing] starting "+e.op+" transaction - "+e.name),e):(Vf.log("[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = "+Number(o)+")"),e)):(Vf.log("[Tracing] Discarding transaction because "+("function"==typeof t.tracesSampler?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0")),e.sampled=!1,e):(Vf.warn("[Tracing] Discarding transaction because of invalid sample rate."),e.sampled=!1,e)):(e.sampled=!1,e);var r,o}var Uh,qh,Vh=jf(),Wh=function(e,t,n,r){var o;return function(){n&&t.isFinal&&n.disconnect(),t.value>=0&&(r||t.isFinal||"hidden"===document.visibilityState)&&(t.delta=t.value-(o||0),(t.delta||t.isFinal||void 0===o)&&(e(t),o=t.value))}},$h=function(e,t){return void 0===t&&(t=-1),{name:e,value:t,delta:0,entries:[],id:Date.now()+"-"+(Math.floor(8999999999999*Math.random())+1e12),isFinal:!1}},Yh=function(e,t){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var n=new PerformanceObserver((function(e){return e.getEntries().map(t)}));return n.observe({type:e,buffered:!0}),n}}catch(e){}},Gh=!1,Xh=!1,Jh=function(e){Gh=!e.persisted},Kh=function(e,t){void 0===t&&(t=!1),Xh||(addEventListener("pagehide",Jh),addEventListener("beforeunload",(function(){})),Xh=!0),addEventListener("visibilitychange",(function(t){var n=t.timeStamp;"hidden"===document.visibilityState&&e({timeStamp:n,isUnloading:Gh})}),{capture:!0,once:t})},Zh=function(){return void 0===Uh&&(Uh="hidden"===document.visibilityState?0:1/0,Kh((function(e){var t=e.timeStamp;return Uh=t}),!0)),{get timeStamp(){return Uh}}},Qh=jf(),em=function(){function e(){var e;this._measurements={},this._performanceCursor=0,!Bf()&&(null===(e=Qh)||void 0===e?void 0:e.performance)&&(Qh.performance.mark&&Qh.performance.mark("sentry-tracing-init"),this._trackCLS(),this._trackLCP(),this._trackFID())}return e.prototype.addPerformanceEntries=function(e){var t=this;if(Qh&&Qh.performance&&Qh.performance.getEntries&&xh){Vf.log("[Tracing] Adding & adjusting spans using Performance API");var n,r,o,i,a,s=Rh(xh);if(Qh.document)for(var c=0;c<document.scripts.length;c++)if("true"===document.scripts[c].dataset.entry){n=document.scripts[c].src;break}if(Qh.performance.getEntries().slice(this._performanceCursor).forEach((function(c){var l=Rh(c.startTime),u=Rh(c.duration);if(!("navigation"===e.op&&s+l<e.startTimestamp))switch(c.entryType){case"navigation":!function(e,t,n){tm({transaction:e,entry:t,event:"unloadEvent",timeOrigin:n}),tm({transaction:e,entry:t,event:"redirect",timeOrigin:n}),tm({transaction:e,entry:t,event:"domContentLoadedEvent",timeOrigin:n}),tm({transaction:e,entry:t,event:"loadEvent",timeOrigin:n}),tm({transaction:e,entry:t,event:"connect",timeOrigin:n}),tm({transaction:e,entry:t,event:"secureConnection",timeOrigin:n,eventEnd:"connectEnd",description:"TLS/SSL"}),tm({transaction:e,entry:t,event:"fetch",timeOrigin:n,eventEnd:"domainLookupStart",description:"cache"}),tm({transaction:e,entry:t,event:"domainLookup",timeOrigin:n,description:"DNS"}),function(e,t,n){nm(e,{op:"browser",description:"request",startTimestamp:n+Rh(t.requestStart),endTimestamp:n+Rh(t.responseEnd)}),nm(e,{op:"browser",description:"response",startTimestamp:n+Rh(t.responseStart),endTimestamp:n+Rh(t.responseEnd)})}(e,t,n)}(e,c,s),i=s+Rh(c.responseStart),a=s+Rh(c.requestStart);break;case"mark":case"paint":case"measure":var d=function(e,t,n,r,o){var i=o+n,a=i+r;return nm(e,{description:t.name,endTimestamp:a,op:t.entryType,startTimestamp:i}),i}(e,c,l,u,s);void 0===o&&"sentry-tracing-init"===c.name&&(o=d);var p=Zh(),f=c.startTime<p.timeStamp;"first-paint"===c.name&&f&&(Vf.log("[Measurements] Adding FP"),t._measurements.fp={value:c.startTime},t._measurements["mark.fp"]={value:d}),"first-contentful-paint"===c.name&&f&&(Vf.log("[Measurements] Adding FCP"),t._measurements.fcp={value:c.startTime},t._measurements["mark.fcp"]={value:d});break;case"resource":var h=c.name.replace(window.location.origin,""),m=function(e,t,n,r,o,i){if("xmlhttprequest"!==t.initiatorType&&"fetch"!==t.initiatorType){var a={};"transferSize"in t&&(a["Transfer Size"]=t.transferSize),"encodedBodySize"in t&&(a["Encoded Body Size"]=t.encodedBodySize),"decodedBodySize"in t&&(a["Decoded Body Size"]=t.decodedBodySize);var s=i+r,c=s+o;return nm(e,{description:n,endTimestamp:c,op:t.initiatorType?"resource."+t.initiatorType:"resource",startTimestamp:s,data:a}),c}}(e,c,h,l,u,s);void 0===r&&(n||"").indexOf(h)>-1&&(r=m)}})),void 0!==r&&void 0!==o&&nm(e,{description:"evaluation",endTimestamp:o,op:"script",startTimestamp:r}),this._performanceCursor=Math.max(performance.getEntries().length-1,0),this._trackNavigator(e),"pageload"===e.op){var l=Rh(xh);"number"==typeof i&&(Vf.log("[Measurements] Adding TTFB"),this._measurements.ttfb={value:1e3*(i-e.startTimestamp)},"number"==typeof a&&a<=i&&(this._measurements["ttfb.requestTime"]={value:1e3*(i-a)})),["fcp","fp","lcp"].forEach((function(n){if(t._measurements[n]&&!(l>=e.startTimestamp)){var r=t._measurements[n].value,o=l+Rh(r),i=Math.abs(1e3*(o-e.startTimestamp)),a=i-r;Vf.log("[Measurements] Normalized "+n+" from "+r+" to "+i+" ("+a+")"),t._measurements[n].value=i}})),this._measurements["mark.fid"]&&this._measurements.fid&&nm(e,{description:"first input delay",endTimestamp:this._measurements["mark.fid"].value+Rh(this._measurements.fid.value),op:"web.vitals",startTimestamp:this._measurements["mark.fid"].value}),e.setMeasurements(this._measurements),this._lcpEntry&&(Vf.log("[Measurements] Adding LCP Data"),this._lcpEntry.element&&e.setTag("lcp.element",function(e){try{for(var t=e,n=[],r=0,o=0,i=" > ".length,a=void 0;t&&r++<5&&!("html"===(a=Pf(t))||r>1&&o+n.length*i+a.length>=80);)n.push(a),o+=a.length,t=t.parentNode;return n.reverse().join(" > ")}catch(e){return"<unknown>"}}(this._lcpEntry.element)),this._lcpEntry.id&&e.setTag("lcp.id",this._lcpEntry.id),this._lcpEntry.url&&e.setTag("lcp.url",this._lcpEntry.url.trim().slice(0,200)),e.setTag("lcp.size",this._lcpEntry.size))}}},e.prototype._trackCLS=function(){var e=this;!function(t,n){void 0===n&&(n=!1);var r,o=$h("CLS",0),i=function(e){e.hadRecentInput||(o.value+=e.value,o.entries.push(e),r())},a=Yh("layout-shift",i);a&&(r=Wh((function(t){t.entries.pop()&&(Vf.log("[Measurements] Adding CLS"),e._measurements.cls={value:t.value})}),o,a,n),Kh((function(e){var t=e.isUnloading;a.takeRecords().map(i),t&&(o.isFinal=!0),r()})))}()},e.prototype._trackNavigator=function(e){var t=Qh.navigator;if(t){var n=t.connection;n&&(n.effectiveType&&e.setTag("effectiveConnectionType",n.effectiveType),n.type&&e.setTag("connectionType",n.type),rm(n.rtt)&&(this._measurements["connection.rtt"]={value:n.rtt}),rm(n.downlink)&&(this._measurements["connection.downlink"]={value:n.downlink})),rm(t.deviceMemory)&&e.setTag("deviceMemory",String(t.deviceMemory)),rm(t.hardwareConcurrency)&&e.setTag("hardwareConcurrency",String(t.hardwareConcurrency))}},e.prototype._trackLCP=function(){var e=this;!function(e,t){void 0===t&&(t=!1);var n,r=$h("LCP"),o=Zh(),i=function(e){var t=e.startTime;t<o.timeStamp?(r.value=t,r.entries.push(e)):r.isFinal=!0,n()},a=Yh("largest-contentful-paint",i);if(a){n=Wh(e,r,a,t);var s=function(){r.isFinal||(a.takeRecords().map(i),r.isFinal=!0,n())};(qh||(qh=new Promise((function(e){return["scroll","keydown","pointerdown"].map((function(t){addEventListener(t,e,{once:!0,passive:!0,capture:!0})}))}))),qh).then(s),Kh(s,!0)}}((function(t){var n=t.entries.pop();if(n){var r=Rh(xh),o=Rh(n.startTime);Vf.log("[Measurements] Adding LCP"),e._measurements.lcp={value:t.value},e._measurements["mark.lcp"]={value:r+o},e._lcpEntry=n}}))},e.prototype._trackFID=function(){var e,t,n,r,o,i=this;e=$h("FID"),t=Zh(),r=Yh("first-input",n=function(n){n.startTime<t.timeStamp&&(e.value=n.processingStart-n.startTime,e.entries.push(n),e.isFinal=!0,o())}),o=Wh((function(e){var t=e.entries.pop();if(t){var n=Rh(xh),r=Rh(t.startTime);Vf.log("[Measurements] Adding FID"),i._measurements.fid={value:e.value},i._measurements["mark.fid"]={value:n+r}}}),e,r),r?Kh((function(){r.takeRecords().map(n),r.disconnect()}),!0):window.perfMetrics&&window.perfMetrics.onFirstInputDelay&&window.perfMetrics.onFirstInputDelay((function(n,r){r.timeStamp<t.timeStamp&&(e.value=n,e.isFinal=!0,e.entries=[{entryType:"first-input",name:r.type,target:r.target,cancelable:r.cancelable,startTime:r.timeStamp,processingStart:r.timeStamp+n}],o())}))},e}();function tm(e){var t=e.transaction,n=e.entry,r=e.event,o=e.timeOrigin,i=e.eventEnd,a=e.description,s=i?n[i]:n[r+"End"],c=n[r+"Start"];c&&s&&nm(t,{op:"browser",description:null!=a?a:r,startTimestamp:o+Rh(c),endTimestamp:o+Rh(s)})}function nm(e,t){var n=t.startTimestamp,r=gr(t,["startTimestamp"]);return n&&e.startTimestamp>n&&(e.startTimestamp=n),e.startChild(mr({startTimestamp:n},r))}function rm(e){return"number"==typeof e&&isFinite(e)}var om={traceFetch:!0,traceXHR:!0,tracingOrigins:["localhost",/^\//]};var im=jf(),am=mr({idleTimeout:1e3,markBackgroundTransactions:!0,maxTransactionDuration:600,routingInstrumentation:function(e,t,n){if(void 0===t&&(t=!0),void 0===n&&(n=!0),im&&im.location){var r,o=im.location.href;t&&(r=e({name:im.location.pathname,op:"pageload"})),n&&nh({callback:function(t){var n=t.to,i=t.from;void 0===i&&o&&-1!==o.indexOf(n)?o=void 0:i!==n&&(o=void 0,r&&(Vf.log("[Tracing] Finishing current transaction with op: "+r.op),r.finish()),r=e({name:im.location.pathname,op:"navigation"}))},type:"history"})}else Vf.warn("Could not initialize routing instrumentation due to invalid location")},startTransactionOnLocationChange:!0,startTransactionOnPageLoad:!0},om),sm=function(){function e(t){this.name=e.id,this._metrics=new em,this._emitOptionsWarning=!1;var n=om.tracingOrigins;t&&t.tracingOrigins&&Array.isArray(t.tracingOrigins)&&0!==t.tracingOrigins.length?n=t.tracingOrigins:this._emitOptionsWarning=!0,this.options=mr(mr(mr({},am),t),{tracingOrigins:n})}return e.prototype.setupOnce=function(e,t){var n=this;this._getCurrentHub=t,this._emitOptionsWarning&&(Vf.warn("[Tracing] You need to define `tracingOrigins` in the options. Set an array of urls or patterns to trace."),Vf.warn("[Tracing] We added a reasonable default for you: "+om.tracingOrigins));var r=this.options,o=r.routingInstrumentation,i=r.startTransactionOnLocationChange,a=r.startTransactionOnPageLoad,s=r.markBackgroundTransactions,c=r.traceFetch,l=r.traceXHR,u=r.tracingOrigins,d=r.shouldCreateSpanForRequest;o((function(e){return n._createRouteTransaction(e)}),a,i),s&&(Vh&&Vh.document?Vh.document.addEventListener("visibilitychange",(function(){var e=Bh();Vh.document.hidden&&e&&(Vf.log("[Tracing] Transaction: "+Ih.Cancelled+" -> since tab moved to the background, op: "+e.op),e.status||e.setStatus(Ih.Cancelled),e.setTag("visibilitychange","document.hidden"),e.finish())})):Vf.warn("[Tracing] Could not set up background tab detection due to lack of global document")),function(e){var t=mr(mr({},om),e),n=t.traceFetch,r=t.traceXHR,o=t.tracingOrigins,i=t.shouldCreateSpanForRequest,a={},s=function(e){if(a[e])return a[e];var t=o;return a[e]=t.some((function(t){return zf(e,t)}))&&!zf(e,"sentry_key"),a[e]},c=s;"function"==typeof i&&(c=function(e){return s(e)&&i(e)});var l={};n&&nh({callback:function(e){!function(e,t,n){if(Ph()&&e.fetchData&&t(e.fetchData.url))if(e.endTimestamp&&e.fetchData.__span)(o=n[e.fetchData.__span])&&(e.response?o.setHttpStatus(e.response.status):e.error&&o.setStatus(Ih.InternalError),o.finish(),delete n[e.fetchData.__span]);else{var r=Bh();if(r){var o=r.startChild({data:mr(mr({},e.fetchData),{type:"fetch"}),description:e.fetchData.method+" "+e.fetchData.url,op:"http"});e.fetchData.__span=o.spanId,n[o.spanId]=o;var i=e.args[0]=e.args[0],a=e.args[1]=e.args[1]||{},s=a.headers;Af(i,Request)&&(s=i.headers),s?"function"==typeof s.append?s.append("sentry-trace",o.toTraceparent()):s=Array.isArray(s)?_r(s,[["sentry-trace",o.toTraceparent()]]):mr(mr({},s),{"sentry-trace":o.toTraceparent()}):s={"sentry-trace":o.toTraceparent()},a.headers=s}}}(e,c,l)},type:"fetch"}),r&&nh({callback:function(e){!function(e,t,n){var r,o;if(Ph()&&!(null===(r=e.xhr)||void 0===r?void 0:r.__sentry_own_request__)&&(null===(o=e.xhr)||void 0===o?void 0:o.__sentry_xhr__)&&t(e.xhr.__sentry_xhr__.url)){var i=e.xhr.__sentry_xhr__;if(e.endTimestamp&&e.xhr.__sentry_xhr_span_id__)(s=n[e.xhr.__sentry_xhr_span_id__])&&(s.setHttpStatus(i.status_code),s.finish(),delete n[e.xhr.__sentry_xhr_span_id__]);else{var a=Bh();if(a){var s=a.startChild({data:mr(mr({},i.data),{type:"xhr",method:i.method,url:i.url}),description:i.method+" "+i.url,op:"http"});if(e.xhr.__sentry_xhr_span_id__=s.spanId,n[e.xhr.__sentry_xhr_span_id__]=s,e.xhr.setRequestHeader)try{e.xhr.setRequestHeader("sentry-trace",s.toTraceparent())}catch(e){}}}}}(e,c,l)},type:"xhr"})}({traceFetch:c,traceXHR:l,tracingOrigins:u,shouldCreateSpanForRequest:d})},e.prototype._createRouteTransaction=function(e){var t=this;if(this._getCurrentHub){var n=this.options,r=n.beforeNavigate,o=n.idleTimeout,i=n.maxTransactionDuration,a="pageload"===e.op?function(){var e,t=("sentry-trace",(e=document.querySelector("meta[name=sentry-trace]"))?e.getAttribute("content"):null);if(t)return function(e){var t=e.match(Ah);if(t){var n=void 0;return"1"===t[3]?n=!0:"0"===t[3]&&(n=!1),{traceId:t[1],parentSampled:n,parentSpanId:t[2]}}}(t)}():void 0,s=mr(mr(mr({},e),a),{trimEnd:!0}),c="function"==typeof r?r(s):s,l=void 0===c?mr(mr({},s),{sampled:!1}):c;!1===l.sampled&&Vf.log("[Tracing] Will not send "+l.op+" transaction because of beforeNavigate."),Vf.log("[Tracing] Starting "+l.op+" transaction on scope");var u=function(e,t,n,r,o){var i,a,s=(null===(i=e.getClient())||void 0===i?void 0:i.getOptions())||{},c=new Mh(t,e,n,!0);return(c=Hh(c,s,mr({parentSampled:t.parentSampled,transactionContext:t},o))).sampled&&c.initSpanRecorder(null===(a=s._experiments)||void 0===a?void 0:a.maxSpans),c}(this._getCurrentHub(),l,o,0,{location:jf().location});return u.registerBeforeFinishCallback((function(e,n){t._metrics.addPerformanceEntries(e),function(e,t,n){var r=n-t.startTimestamp;n&&(r>e||r<0)&&(t.setStatus(Ih.DeadlineExceeded),t.setTag("maxTransactionDurationExceeded","true"))}(1e3*i,e,n)})),u}Vf.warn("[Tracing] Did not create "+e.op+" transaction because _getCurrentHub is invalid.")},e.id="BrowserTracing",e}(),cm=function(){function e(t){void 0===t&&(t={}),this.name=e.id,this._router=t.router||t.app,this._methods=(Array.isArray(t.methods)?t.methods:[]).concat("use")}return e.prototype.setupOnce=function(){var e,t;this._router?(e=this._router,void 0===(t=this._methods)&&(t=[]),t.forEach((function(t){return function(e,t){var n=e[t];return e[t]=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return n.call.apply(n,_r([this],um(e,t)))},e}(e,t)}))):Vf.error("ExpressIntegration is missing an Express instance")},e.id="Express",e}();function lm(e,t){var n=e.length;switch(n){case 2:return function(n,r){var o=r.__sentry_transaction;if(o){var i=o.startChild({description:e.name,op:"middleware."+t});r.once("finish",(function(){i.finish()}))}return e.call(this,n,r)};case 3:return function(n,r,o){var i,a=null===(i=r.__sentry_transaction)||void 0===i?void 0:i.startChild({description:e.name,op:"middleware."+t});e.call(this,n,r,(function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];null===(e=a)||void 0===e||e.finish(),o.call.apply(o,_r([this],t))}))};case 4:return function(n,r,o,i){var a,s=null===(a=o.__sentry_transaction)||void 0===a?void 0:a.startChild({description:e.name,op:"middleware."+t});e.call(this,n,r,o,(function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];null===(e=s)||void 0===e||e.finish(),i.call.apply(i,_r([this],t))}))};default:throw new Error("Express middleware takes 2-4 arguments. Got: "+n)}}function um(e,t){return e.map((function(e){return"function"==typeof e?lm(e,t):Array.isArray(e)?e.map((function(e){return"function"==typeof e?lm(e,t):e})):e}))}var dm,pm=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(e,t){var n=Ff("pg");n?$f(n.Client.prototype,"query",(function(e){return function(n,r,o){var i,a,s,c=null===(a=null===(i=t().getScope())||void 0===i?void 0:i.getSpan())||void 0===a?void 0:a.startChild({description:"string"==typeof n?n:n.text,op:"db"});if("function"==typeof o)return e.call(this,n,r,(function(e,t){var n;null===(n=c)||void 0===n||n.finish(),o(e,t)}));if("function"==typeof r)return e.call(this,n,(function(e,t){var n;null===(n=c)||void 0===n||n.finish(),r(e,t)}));var l=void 0!==r?e.call(this,n,r):e.call(this,n);return Of(l)?l.then((function(e){var t;return null===(t=c)||void 0===t||t.finish(),e})):(null===(s=c)||void 0===s||s.finish(),l)}})):Vf.error("Postgres Integration was unable to require `pg` package.")},e.id="Postgres",e}(),fm=function(){function e(){this.name=e.id}return e.prototype.setupOnce=function(e,t){var n=Ff("mysql/lib/Connection.js");n?$f(n,"createQuery",(function(e){return function(n,r,o){var i,a,s=null===(a=null===(i=t().getScope())||void 0===i?void 0:i.getSpan())||void 0===a?void 0:a.startChild({description:"string"==typeof n?n:n.sql,op:"db"});return"function"==typeof o?e.call(this,n,r,(function(e,t,n){var r;null===(r=s)||void 0===r||r.finish(),o(e,t,n)})):"function"==typeof r?e.call(this,n,(function(e,t,n){var o;null===(o=s)||void 0===o||o.finish(),r(e,t,n)})):e.call(this,n,r,o)}})):Vf.error("Mysql Integration was unable to require `mysql` package.")},e.id="Mysql",e}(),hm=["aggregate","bulkWrite","countDocuments","createIndex","createIndexes","deleteMany","deleteOne","distinct","drop","dropIndex","dropIndexes","estimatedDocumentCount","find","findOne","findOneAndDelete","findOneAndReplace","findOneAndUpdate","indexes","indexExists","indexInformation","initializeOrderedBulkOp","insertMany","insertOne","isCapped","mapReduce","options","parallelCollectionScan","rename","replaceOne","stats","updateMany","updateOne"],mm={bulkWrite:["operations"],countDocuments:["query"],createIndex:["fieldOrSpec"],createIndexes:["indexSpecs"],deleteMany:["filter"],deleteOne:["filter"],distinct:["key","query"],dropIndex:["indexName"],find:["query"],findOne:["query"],findOneAndDelete:["filter"],findOneAndReplace:["filter","replacement"],findOneAndUpdate:["filter","update"],indexExists:["indexes"],insertMany:["docs"],insertOne:["doc"],mapReduce:["map","reduce"],rename:["newName"],replaceOne:["filter","doc"],updateMany:["filter","update"],updateOne:["filter","update"]},gm=function(){function e(t){void 0===t&&(t={}),this.name=e.id,this._operations=Array.isArray(t.operations)?t.operations:hm,this._describeOperations=!("describeOperations"in t)||t.describeOperations,this._useMongoose=!!t.useMongoose}return e.prototype.setupOnce=function(e,t){var n=this._useMongoose?"mongoose":"mongodb",r=Ff(n);r?this._instrumentOperations(r.Collection,this._operations,t):Vf.error("Mongo Integration was unable to require `"+n+"` package.")},e.prototype._instrumentOperations=function(e,t,n){var r=this;t.forEach((function(t){return r._patchOperation(e,t,n)}))},e.prototype._patchOperation=function(e,t,n){if(t in e.prototype){var r=this._getSpanContextFromOperationArguments.bind(this);$f(e.prototype,t,(function(e){return function(){for(var o,i,a,s,c=[],l=0;l<arguments.length;l++)c[l]=arguments[l];var u=c[c.length-1],d=n().getScope(),p=null===(o=d)||void 0===o?void 0:o.getSpan();if("function"!=typeof u||"mapReduce"===t&&2===c.length){var f=null===(i=p)||void 0===i?void 0:i.startChild(r(this,t,c)),h=e.call.apply(e,_r([this],c));return Of(h)?h.then((function(e){var t;return null===(t=f)||void 0===t||t.finish(),e})):(null===(a=f)||void 0===a||a.finish(),h)}var m=null===(s=p)||void 0===s?void 0:s.startChild(r(this,t,c.slice(0,-1)));return e.call.apply(e,_r([this],c.slice(0,-1),[function(e,t){var n;null===(n=m)||void 0===n||n.finish(),u(e,t)}]))}}))}},e.prototype._getSpanContextFromOperationArguments=function(e,t,n){var r={collectionName:e.collectionName,dbName:e.dbName,namespace:e.namespace},o={op:"db",description:t,data:r},i=mm[t],a=Array.isArray(this._describeOperations)?this._describeOperations.includes(t):this._describeOperations;if(!i||!a)return o;try{if("mapReduce"===t){var s=xr(n,2),c=s[0],l=s[1];r[i[0]]="string"==typeof c?c:c.name||"<anonymous>",r[i[1]]="string"==typeof l?l:l.name||"<anonymous>"}else for(var u=0;u<i.length;u++)r[i[u]]=JSON.stringify(n[u])}catch(e){}return o},e.id="Mongo",e}(),vm=mr(mr({},Object.freeze({__proto__:null,Express:cm,Postgres:pm,Mysql:fm,Mongo:gm})),{BrowserTracing:sm});function ym(e){var n=e.assetFieldSelection,r=e.assetFilter,o=e.assetTypes,i=void 0===o?["IMAGE","AUDIO","VIDEO","DOCUMENT"]:o,a=e.defaultSearchTerm,s=e.language,c=void 0===s?"en_US":s,l=e.mode,u=void 0===l?"MultiSelect":l,d=e.onSuccess,p=void 0===d?function(e,t){var n=t.selectedFile;return console.log(e,n)}:d,f=e.theme,h=e.hideExternalAccess,m=e.selectedAssets;va(c);var g={assetFieldSelection:n,assetFilter:r,assetTypes:i,language:c,onSuccess:p,selectionMode:u,theme:f,hideExternalAccess:h};return t.createElement(Pd,null,t.createElement(Er,null,t.createElement(dr,null,t.createElement(gp,null,t.createElement(Or,{defaultValue:a,selectionMode:g.selectionMode},t.createElement(aa,{value:g},t.createElement(Vd,{preselectedAssetIds:null!=m?m:[]},t.createElement(_d,null,t.createElement("div",{className:"cv-root cv-container"},t.createElement(mf,null),t.createElement(bm,null),t.createElement(Tf,null))))))))))}function bm(){var e=kr()[0],n=sa().assetFilter;return t.createElement(t.Fragment,null,"assets"===e.page&&void 0===n&&t.createElement(df,null),"assets"===e.page&&t.createElement(gf,null),"collections"===e.page&&t.createElement(hp,null),"collection"===e.page&&t.createElement(Jp,{collection:e.collection}))}(dm=Sh()).__SENTRY__&&(dm.__SENTRY__.extensions=dm.__SENTRY__.extensions||{},dm.__SENTRY__.extensions.startTransaction||(dm.__SENTRY__.extensions.startTransaction=function(e,t){var n,r,o=(null===(n=this.getClient())||void 0===n?void 0:n.getOptions())||{},i=new Lh(e,this);return(i=Hh(i,o,mr({parentSampled:e.parentSampled,transactionContext:e},t))).sampled&&i.initSpanRecorder(null===(r=o._experiments)||void 0===r?void 0:r.maxSpans),i}),dm.__SENTRY__.extensions.traceHeaders||(dm.__SENTRY__.extensions.traceHeaders=function(){var e=this.getScope();if(e){var t=e.getSpan();if(t)return{"sentry-trace":t.toTraceparent()}}return{}})),Bf()&&function(){var e=Sh();if(e.__SENTRY__){var t={mongodb:function(){return new(Rf(module,"./integrations/mongo").Mongo)},mongoose:function(){return new(Rf(module,"./integrations/mongo").Mongo)({mongoose:!0})},mysql:function(){return new(Rf(module,"./integrations/mysql").Mysql)},pg:function(){return new(Rf(module,"./integrations/postgres").Postgres)}},n=Object.keys(t).filter((function(e){return!!Ff(e)})).map((function(e){try{return t[e]()}catch(e){return}})).filter((function(e){return e}));n.length>0&&(e.__SENTRY__.integrations=_r(e.__SENTRY__.integrations||[],n))}}(),nh({callback:Fh,type:"error"}),nh({callback:Fh,type:"unhandledrejection"}),function(e){if(void 0===e&&(e={}),void 0===e.defaultIntegrations&&(e.defaultIntegrations=ea),void 0===e.release){var t=eo();t.SENTRY_RELEASE&&t.SENTRY_RELEASE.id&&(e.release=t.SENTRY_RELEASE.id)}void 0===e.autoSessionTracking&&(e.autoSessionTracking=!0),function(e,t){var n;!0===t.debug&&uo.enable();var r=Zo();null===(n=r.getScope())||void 0===n||n.update(t.initialScope);var o=new e(t);r.bindClient(o)}(Qi,e),e.autoSessionTracking&&function(){if(void 0!==eo().document){var e=Zo();"function"==typeof e.startSession&&"function"==typeof e.captureSession&&(e.startSession(),e.captureSession(),Oo({callback:function(t){var n=t.from,r=t.to;void 0!==n&&n!==r&&(e.startSession(),e.captureSession())},type:"history"}))}else uo.warn("Session tracking in non-browser environment with @sentry/browser is not supported.")}()}({dsn:"https://dd74b64cc05845468f0c3654b458da29@sentry10.bynder.cloud/464",autoSessionTracking:!0,integrations:[new vm.BrowserTracing],tracesSampleRate:1,defaultIntegrations:!1});export{ym as CompactView,zd as Login,Ed as Modal};