@abtnode/webapp 1.8.10 → 1.8.11

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.
@@ -0,0 +1,2 @@
1
+ (self.webpackChunk_abtnode_webapp=self.webpackChunk_abtnode_webapp||[]).push([[976],{53989:function(e,t,n){"use strict";function r(){var e=[];return{add:function(t){return e.push(t),t.finally((function(){e=e.filter((function(e){return e!==t}))}))},cancelAll:function(){e.forEach((function(e){return e.cancel()}))},isEmpty:function(){return 0===e.length}}}function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t,n){var a=t.initialState;return{getState:function(){return a},dispatch:function(r,u){var l=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){i(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},a);a=e(a,{type:r,props:t,payload:u}),n({state:a,prevState:l})},pendingRequests:r()}}function u(e){return e.reduce((function(e,t){return e.concat(t)}),[])}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function f(e){return 0===e.collections.length?0:e.collections.reduce((function(e,t){return e+t.items.length}),0)}n.r(t),n.d(t,{autocomplete:function(){return Ln},getAlgoliaFacets:function(){return nr},getAlgoliaResults:function(){return rr}});var p=0;function d(){return"autocomplete-".concat(p++)}var v=function(){};function h(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function y(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function m(e,t){var n=[];return Promise.resolve(e(t)).then((function(e){return Array.isArray(e),Promise.all(e.filter((function(e){return Boolean(e)})).map((function(e){if(e.sourceId,n.includes(e.sourceId))throw new Error("[Autocomplete] The `sourceId` ".concat(JSON.stringify(e.sourceId)," is not unique."));n.push(e.sourceId);var t=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?h(Object(n),!0).forEach((function(t){y(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):h(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({getItemInputValue:function(e){return e.state.query},getItemUrl:function(){},onSelect:function(e){(0,e.setIsOpen)(!1)},onActive:v},e);return Promise.resolve(t)})))}))}function b(e){return function(e){if(Array.isArray(e))return g(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return g(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return g(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function g(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function O(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function w(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?O(Object(n),!0).forEach((function(t){j(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):O(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function j(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function P(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){S(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function S(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function x(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?x(Object(n),!0).forEach((function(t){E(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):x(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function E(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function I(e){return function(e){if(Array.isArray(e))return C(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return C(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return C(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function C(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function M(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function D(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?M(Object(n),!0).forEach((function(t){T(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):M(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function T(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function R(e){return Boolean(e.execute)}function A(e,t){return n=e,Boolean(null===n||void 0===n?void 0:n.execute)?D(D({},e),{},{requests:e.queries.map((function(n){return{query:n,sourceId:t,transformResponse:e.transformResponse}}))}):{items:e,sourceId:t};var n}function N(e){var t=e.reduce((function(e,t){if(!R(t))return e.push(t),e;var n=t.searchClient,r=t.execute,o=t.requesterId,i=t.requests,a=e.find((function(e){return R(t)&&R(e)&&e.searchClient===n&&Boolean(o)&&e.requesterId===o}));if(a){var u;(u=a.items).push.apply(u,I(i))}else{var l={execute:r,requesterId:o,items:i,searchClient:n};e.push(l)}return e}),[]).map((function(e){if(!R(e))return Promise.resolve(e);var t=e,n=t.execute,r=t.items;return n({searchClient:t.searchClient,requests:r})}));return Promise.all(t).then((function(e){return u(e)}))}function F(e,t){return t.map((function(t){var n=e.filter((function(e){return e.sourceId===t.sourceId})),r=n.map((function(e){return e.items})),o=n[0].transformResponse,i=o?o(function(e){var t=e.map((function(e){var t;return k(k({},e),{},{hits:null===(t=e.hits)||void 0===t?void 0:t.map((function(t){return k(k({},t),{},{__autocomplete_indexName:e.index,__autocomplete_queryID:e.queryID})}))})}));return{results:t,hits:t.map((function(e){return e.hits})).filter(Boolean),facetHits:t.map((function(e){var t;return null===(t=e.facetHits)||void 0===t?void 0:t.map((function(e){return{label:e.value,count:e.count,_highlightResult:{label:{value:e.highlighted}}}}))})).filter(Boolean)}}(r)):r;return Array.isArray(i),i.every(Boolean),'The `getItems` function from source "'.concat(t.sourceId,'" must return an array of items but returned ').concat(JSON.stringify(void 0),".\n\nDid you forget to return items?\n\nSee: https://www.algolia.com/doc/ui-libraries/autocomplete/core-concepts/sources/#param-getitems"),{source:t,items:i}}))}function L(e,t){var n=t;return{then:function(t,r){return L(e.then(B(t,n,e),B(r,n,e)),n)},catch:function(t){return L(e.catch(B(t,n,e)),n)},finally:function(t){return t&&n.onCancelList.push(t),L(e.finally(B(t&&function(){return n.onCancelList=[],t()},n,e)),n)},cancel:function(){n.isCanceled=!0;var e=n.onCancelList;n.onCancelList=[],e.forEach((function(e){e()}))},isCanceled:function(){return!0===n.isCanceled}}}function z(e){return L(new Promise((function(t,n){return e(t,n)})),{isCanceled:!1,onCancelList:[]})}function q(e){return L(e,{isCanceled:!1,onCancelList:[]})}function B(e,t,n){return e?function(n){return t.isCanceled?n:e(n)}:n}function U(e){var t=function(e){var t=e.collections.map((function(e){return e.items.length})).reduce((function(e,t,n){var r=(e[n-1]||0)+t;return e.push(r),e}),[]).reduce((function(t,n){return n<=e.activeItemId?t+1:t}),0);return e.collections[t]}(e);if(!t)return null;var n=t.items[function(e){for(var t=e.state,n=e.collection,r=!1,o=0,i=0;!1===r;){var a=t.collections[o];if(a===n){r=!0;break}i+=a.items.length,o++}return t.activeItemId-i}({state:e,collection:t})],r=t.source;return{item:n,itemInputValue:r.getItemInputValue({item:n,state:e}),itemUrl:r.getItemUrl({item:n,state:e}),source:r}}z.resolve=function(e){return q(Promise.resolve(e))},z.reject=function(e){return q(Promise.reject(e))};var V=["event","nextState","props","query","refresh","store"];function H(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function W(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?H(Object(n),!0).forEach((function(t){$(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):H(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function $(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function K(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var G=null,Y=function(){var e=-1,t=-1,n=void 0;return function(r){var o=++e;return Promise.resolve(r).then((function(e){return n&&o<t?n:(t=o,n=e,e)}))}}();function J(e){var t=e.event,n=e.nextState,r=void 0===n?{}:n,o=e.props,i=e.query,a=e.refresh,l=e.store,c=K(e,V);G&&o.environment.clearTimeout(G);var s=c.setCollections,f=c.setIsOpen,p=c.setQuery,d=c.setActiveItemId,v=c.setStatus;if(p(i),d(o.defaultActiveItemId),!i&&!1===o.openOnFocus){var h,y=l.getState().collections.map((function(e){return W(W({},e),{},{items:[]})}));v("idle"),s(y),f(null!==(h=r.isOpen)&&void 0!==h?h:o.shouldPanelOpen({state:l.getState()}));var m=q(Y(y).then((function(){return Promise.resolve()})));return l.pendingRequests.add(m)}v("loading"),G=o.environment.setTimeout((function(){v("stalled")}),o.stallThreshold);var b=q(Y(o.getSources(W({query:i,refresh:a,state:l.getState()},c)).then((function(e){return Promise.all(e.map((function(e){return Promise.resolve(e.getItems(W({query:i,refresh:a,state:l.getState()},c))).then((function(t){return A(t,e.sourceId)}))}))).then(N).then((function(t){return F(t,e)})).then((function(e){return function(e){var t=e.collections,n=e.props,r=e.state,o=t.reduce((function(e,t){return P(P({},e),{},S({},t.source.sourceId,P(P({},t.source),{},{getItems:function(){return u(t.items)}})))}),{});return u(n.reshape({sources:Object.values(o),sourcesBySourceId:o,state:r})).filter(Boolean).map((function(e){return{source:e,items:e.getItems()}}))}({collections:e,props:o,state:l.getState()})}))})))).then((function(e){var n;v("idle"),s(e);var u=o.shouldPanelOpen({state:l.getState()});f(null!==(n=r.isOpen)&&void 0!==n?n:o.openOnFocus&&!i&&u||u);var p=U(l.getState());if(null!==l.getState().activeItemId&&p){var d=p.item,h=p.itemInputValue,y=p.itemUrl,m=p.source;m.onActive(W({event:t,item:d,itemInputValue:h,itemUrl:y,refresh:a,source:m,state:l.getState()},c))}})).finally((function(){v("idle"),G&&o.environment.clearTimeout(G)}));return l.pendingRequests.add(b)}var Q=["event","props","refresh","store"];function Z(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function X(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Z(Object(n),!0).forEach((function(t){ee(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Z(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ee(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function te(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var ne=/((gt|sm)-|galaxy nexus)|samsung[- ]/i;var re=["props","refresh","store"],oe=["inputElement","formElement","panelElement"],ie=["inputElement"],ae=["inputElement","maxLength"],ue=["item","source"];function le(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ce(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?le(Object(n),!0).forEach((function(t){se(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):le(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function se(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function fe(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function pe(e){var t=e.props,n=e.refresh,r=e.store,o=fe(e,re);return{getEnvironmentProps:function(e){var n=e.inputElement,o=e.formElement,i=e.panelElement;function a(e){!r.getState().isOpen&&r.pendingRequests.isEmpty()||e.target===n||!1===[o,i].some((function(t){return n=t,r=e.target,n===r||n.contains(r);var n,r}))&&(r.dispatch("blur",null),t.debug||r.pendingRequests.cancelAll())}return ce({onTouchStart:a,onMouseDown:a,onTouchMove:function(e){!1!==r.getState().isOpen&&n===t.environment.document.activeElement&&e.target!==n&&n.blur()}},fe(e,oe))},getRootProps:function(e){return ce({role:"combobox","aria-expanded":r.getState().isOpen,"aria-haspopup":"listbox","aria-owns":r.getState().isOpen?"".concat(t.id,"-list"):void 0,"aria-labelledby":"".concat(t.id,"-label")},e)},getFormProps:function(e){e.inputElement;return ce({action:"",noValidate:!0,role:"search",onSubmit:function(i){var a;i.preventDefault(),t.onSubmit(ce({event:i,refresh:n,state:r.getState()},o)),r.dispatch("submit",null),null===(a=e.inputElement)||void 0===a||a.blur()},onReset:function(i){var a;i.preventDefault(),t.onReset(ce({event:i,refresh:n,state:r.getState()},o)),r.dispatch("reset",null),null===(a=e.inputElement)||void 0===a||a.focus()}},fe(e,ie))},getLabelProps:function(e){return ce({htmlFor:"".concat(t.id,"-input"),id:"".concat(t.id,"-label")},e)},getInputProps:function(e){var i;function a(e){(t.openOnFocus||Boolean(r.getState().query))&&J(ce({event:e,props:t,query:r.getState().completion||r.getState().query,refresh:n,store:r},o)),r.dispatch("focus",null)}var u=e||{},l=(u.inputElement,u.maxLength),c=void 0===l?512:l,s=fe(u,ae),f=U(r.getState()),p=function(e){return Boolean(e&&e.match(ne))}((null===(i=t.environment.navigator)||void 0===i?void 0:i.userAgent)||""),d=null!==f&&void 0!==f&&f.itemUrl&&!p?"go":"search";return ce({"aria-autocomplete":"both","aria-activedescendant":r.getState().isOpen&&null!==r.getState().activeItemId?"".concat(t.id,"-item-").concat(r.getState().activeItemId):void 0,"aria-controls":r.getState().isOpen?"".concat(t.id,"-list"):void 0,"aria-labelledby":"".concat(t.id,"-label"),value:r.getState().completion||r.getState().query,id:"".concat(t.id,"-input"),autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",enterKeyHint:d,spellCheck:"false",autoFocus:t.autoFocus,placeholder:t.placeholder,maxLength:c,type:"search",onChange:function(e){J(ce({event:e,props:t,query:e.currentTarget.value.slice(0,c),refresh:n,store:r},o))},onKeyDown:function(e){!function(e){var t=e.event,n=e.props,r=e.refresh,o=e.store,i=te(e,Q);if("ArrowUp"===t.key||"ArrowDown"===t.key){var a=function(){var e=n.environment.document.getElementById("".concat(n.id,"-item-").concat(o.getState().activeItemId));e&&(e.scrollIntoViewIfNeeded?e.scrollIntoViewIfNeeded(!1):e.scrollIntoView(!1))},u=function(){var e=U(o.getState());if(null!==o.getState().activeItemId&&e){var n=e.item,a=e.itemInputValue,u=e.itemUrl,l=e.source;l.onActive(X({event:t,item:n,itemInputValue:a,itemUrl:u,refresh:r,source:l,state:o.getState()},i))}};t.preventDefault(),!1===o.getState().isOpen&&(n.openOnFocus||Boolean(o.getState().query))?J(X({event:t,props:n,query:o.getState().query,refresh:r,store:o},i)).then((function(){o.dispatch(t.key,{nextActiveItemId:n.defaultActiveItemId}),u(),setTimeout(a,0)})):(o.dispatch(t.key,{}),u(),a())}else if("Escape"===t.key)t.preventDefault(),o.dispatch(t.key,null),o.pendingRequests.cancelAll();else if("Tab"===t.key)o.dispatch("blur",null),o.pendingRequests.cancelAll();else if("Enter"===t.key){if(null===o.getState().activeItemId||o.getState().collections.every((function(e){return 0===e.items.length})))return void(n.debug||o.pendingRequests.cancelAll());t.preventDefault();var l=U(o.getState()),c=l.item,s=l.itemInputValue,f=l.itemUrl,p=l.source;if(t.metaKey||t.ctrlKey)void 0!==f&&(p.onSelect(X({event:t,item:c,itemInputValue:s,itemUrl:f,refresh:r,source:p,state:o.getState()},i)),n.navigator.navigateNewTab({itemUrl:f,item:c,state:o.getState()}));else if(t.shiftKey)void 0!==f&&(p.onSelect(X({event:t,item:c,itemInputValue:s,itemUrl:f,refresh:r,source:p,state:o.getState()},i)),n.navigator.navigateNewWindow({itemUrl:f,item:c,state:o.getState()}));else if(t.altKey);else{if(void 0!==f)return p.onSelect(X({event:t,item:c,itemInputValue:s,itemUrl:f,refresh:r,source:p,state:o.getState()},i)),void n.navigator.navigate({itemUrl:f,item:c,state:o.getState()});J(X({event:t,nextState:{isOpen:!1},props:n,query:s,refresh:r,store:o},i)).then((function(){p.onSelect(X({event:t,item:c,itemInputValue:s,itemUrl:f,refresh:r,source:p,state:o.getState()},i))}))}}}(ce({event:e,props:t,refresh:n,store:r},o))},onFocus:a,onBlur:v,onClick:function(n){e.inputElement!==t.environment.document.activeElement||r.getState().isOpen||a(n)}},s)},getPanelProps:function(e){return ce({onMouseDown:function(e){e.preventDefault()},onMouseLeave:function(){r.dispatch("mouseleave",null)}},e)},getListProps:function(e){return ce({role:"listbox","aria-labelledby":"".concat(t.id,"-label"),id:"".concat(t.id,"-list")},e)},getItemProps:function(e){var i=e.item,a=e.source,u=fe(e,ue);return ce({id:"".concat(t.id,"-item-").concat(i.__autocomplete_id),role:"option","aria-selected":r.getState().activeItemId===i.__autocomplete_id,onMouseMove:function(e){if(i.__autocomplete_id!==r.getState().activeItemId){r.dispatch("mousemove",i.__autocomplete_id);var t=U(r.getState());if(null!==r.getState().activeItemId&&t){var a=t.item,u=t.itemInputValue,l=t.itemUrl,c=t.source;c.onActive(ce({event:e,item:a,itemInputValue:u,itemUrl:l,refresh:n,source:c,state:r.getState()},o))}}},onMouseDown:function(e){e.preventDefault()},onClick:function(e){var u=a.getItemInputValue({item:i,state:r.getState()}),l=a.getItemUrl({item:i,state:r.getState()});(l?Promise.resolve():J(ce({event:e,nextState:{isOpen:!1},props:t,query:u,refresh:n,store:r},o))).then((function(){a.onSelect(ce({event:e,item:i,itemInputValue:u,itemUrl:l,refresh:n,source:a,state:r.getState()},o))}))}},u)}}}var de="1.7.1",ve=[{segment:"autocomplete-core",version:de}];function he(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ye(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?he(Object(n),!0).forEach((function(t){me(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):he(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function me(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function be(e){var t,n,r,o,i=e.plugins,a=e.options,u=null===(t=((null===(n=a.__autocomplete_metadata)||void 0===n?void 0:n.userAgents)||[])[0])||void 0===t?void 0:t.segment,l=u?me({},u,Object.keys((null===(r=a.__autocomplete_metadata)||void 0===r?void 0:r.options)||{})):{};return{plugins:i.map((function(e){return{name:e.name,options:Object.keys(e.__autocomplete_pluginOptions||[])}})),options:ye({"autocomplete-core":Object.keys(a)},l),ua:ve.concat((null===(o=a.__autocomplete_metadata)||void 0===o?void 0:o.userAgents)||[])}}function ge(e){var t,n=e.state;return!1===n.isOpen||null===n.activeItemId?null:(null===(t=U(n))||void 0===t?void 0:t.itemInputValue)||null}function Oe(e,t,n,r){if(!n)return null;if(e<0&&(null===t||null!==r&&0===t))return n+e;var o=(null===t?-1:t)+e;return o<=-1||o>=n?null===r?null:0:o}function we(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function je(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?we(Object(n),!0).forEach((function(t){_e(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):we(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function _e(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Pe=function(e,t){switch(t.type){case"setActiveItemId":case"mousemove":return je(je({},e),{},{activeItemId:t.payload});case"setQuery":return je(je({},e),{},{query:t.payload,completion:null});case"setCollections":return je(je({},e),{},{collections:t.payload});case"setIsOpen":return je(je({},e),{},{isOpen:t.payload});case"setStatus":return je(je({},e),{},{status:t.payload});case"setContext":return je(je({},e),{},{context:je(je({},e.context),t.payload)});case"ArrowDown":var n=je(je({},e),{},{activeItemId:t.payload.hasOwnProperty("nextActiveItemId")?t.payload.nextActiveItemId:Oe(1,e.activeItemId,f(e),t.props.defaultActiveItemId)});return je(je({},n),{},{completion:ge({state:n})});case"ArrowUp":var r=je(je({},e),{},{activeItemId:Oe(-1,e.activeItemId,f(e),t.props.defaultActiveItemId)});return je(je({},r),{},{completion:ge({state:r})});case"Escape":return e.isOpen?je(je({},e),{},{activeItemId:null,isOpen:!1,completion:null}):je(je({},e),{},{activeItemId:null,query:"",status:"idle",collections:[]});case"submit":return je(je({},e),{},{activeItemId:null,isOpen:!1,status:"idle"});case"reset":return je(je({},e),{},{activeItemId:!0===t.props.openOnFocus?t.props.defaultActiveItemId:null,status:"idle",query:""});case"focus":return je(je({},e),{},{activeItemId:t.props.defaultActiveItemId,isOpen:(t.props.openOnFocus||Boolean(e.query))&&t.props.shouldPanelOpen({state:e})});case"blur":return t.props.debug?e:je(je({},e),{},{isOpen:!1,activeItemId:null});case"mouseleave":return je(je({},e),{},{activeItemId:t.props.defaultActiveItemId});default:return"The reducer action ".concat(JSON.stringify(t.type)," is not supported."),e}};function Se(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function xe(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Se(Object(n),!0).forEach((function(t){ke(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Se(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ke(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ee(e){var t=[],n=function(e,t){var n,r="undefined"!==typeof window?window:{},o=e.plugins||[];return w(w({debug:!1,openOnFocus:!1,placeholder:"",autoFocus:!1,defaultActiveItemId:null,stallThreshold:300,environment:r,shouldPanelOpen:function(e){return f(e.state)>0},reshape:function(e){return e.sources}},e),{},{id:null!==(n=e.id)&&void 0!==n?n:d(),plugins:o,initialState:w({activeItemId:null,query:"",completion:null,collections:[],isOpen:!1,status:"idle",context:{}},e.initialState),onStateChange:function(t){var n;null===(n=e.onStateChange)||void 0===n||n.call(e,t),o.forEach((function(e){var n;return null===(n=e.onStateChange)||void 0===n?void 0:n.call(e,t)}))},onSubmit:function(t){var n;null===(n=e.onSubmit)||void 0===n||n.call(e,t),o.forEach((function(e){var n;return null===(n=e.onSubmit)||void 0===n?void 0:n.call(e,t)}))},onReset:function(t){var n;null===(n=e.onReset)||void 0===n||n.call(e,t),o.forEach((function(e){var n;return null===(n=e.onReset)||void 0===n?void 0:n.call(e,t)}))},getSources:function(n){return Promise.all([].concat(b(o.map((function(e){return e.getSources}))),[e.getSources]).filter(Boolean).map((function(e){return m(e,n)}))).then((function(e){return u(e)})).then((function(e){return e.map((function(e){return w(w({},e),{},{onSelect:function(n){e.onSelect(n),t.forEach((function(e){var t;return null===(t=e.onSelect)||void 0===t?void 0:t.call(e,n)}))},onActive:function(n){e.onActive(n),t.forEach((function(e){var t;return null===(t=e.onActive)||void 0===t?void 0:t.call(e,n)}))}})}))}))},navigator:w({navigate:function(e){var t=e.itemUrl;r.location.assign(t)},navigateNewTab:function(e){var t=e.itemUrl,n=r.open(t,"_blank","noopener");null===n||void 0===n||n.focus()},navigateNewWindow:function(e){var t=e.itemUrl;r.open(t,"_blank","noopener")}},e.navigator)})}(e,t),r=a(Pe,n,(function(e){var t=e.prevState,r=e.state;n.onStateChange(xe({prevState:t,state:r,refresh:l},o))})),o=function(e){var t=e.store;return{setActiveItemId:function(e){t.dispatch("setActiveItemId",e)},setQuery:function(e){t.dispatch("setQuery",e)},setCollections:function(e){var n=0,r=e.map((function(e){return c(c({},e),{},{items:u(e.items).map((function(e){return c(c({},e),{},{__autocomplete_id:n++})}))})}));t.dispatch("setCollections",r)},setIsOpen:function(e){t.dispatch("setIsOpen",e)},setStatus:function(e){t.dispatch("setStatus",e)},setContext:function(e){t.dispatch("setContext",e)}}}({store:r}),i=pe(xe({props:n,refresh:l,store:r},o));function l(){return J(xe({event:new Event("input"),nextState:{isOpen:r.getState().isOpen},props:n,query:r.getState().query,refresh:l,store:r},o))}return n.plugins.forEach((function(e){var n;return null===(n=e.subscribe)||void 0===n?void 0:n.call(e,xe(xe({},o),{},{refresh:l,onSelect:function(e){t.push({onSelect:e})},onActive:function(e){t.push({onActive:e})}}))})),function(e){var t,n,r=e.metadata,o=e.environment;if(null===(t=o.navigator)||void 0===t||null===(n=t.userAgent)||void 0===n?void 0:n.includes("Algolia Crawler")){var i=o.document.createElement("meta"),a=o.document.querySelector("head");i.name="algolia:metadata",setTimeout((function(){i.content=JSON.stringify(r),a.appendChild(i)}),0)}}({metadata:be({plugins:n.plugins,options:e}),environment:n.environment}),xe(xe({refresh:l},i),o)}function Ie(e){return{current:e}}function Ce(e,t){var n=void 0;return function(){for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];n&&clearTimeout(n),n=setTimeout((function(){return e.apply(void 0,o)}),t)}}var Me=function e(t,n,r,o){var i;n[0]=0;for(var a=1;a<n.length;a++){var u=n[a++],l=n[a]?(n[0]|=u?1:2,r[n[a++]]):n[++a];3===u?o[0]=l:4===u?o[1]=Object.assign(o[1]||{},l):5===u?(o[1]=o[1]||{})[n[++a]]=l:6===u?o[1][n[++a]]+=l+"":u?(i=t.apply(l,e(t,l,r,["",null])),o.push(i),l[0]?n[0]|=2:(n[a-2]=0,n[a]=i)):o.push(l)}return o},De=new Map;function Te(e){var t=De.get(this);return t||(t=new Map,De.set(this,t)),(t=Me(this,t.get(e)||(t.set(e,t=function(e){for(var t,n,r=1,o="",i="",a=[0],u=function(e){1===r&&(e||(o=o.replace(/^\s*\n\s*|\s*\n\s*$/g,"")))?a.push(0,e,o):3===r&&(e||o)?(a.push(3,e,o),r=2):2===r&&"..."===o&&e?a.push(4,e,0):2===r&&o&&!e?a.push(5,0,!0,o):r>=5&&((o||!e&&5===r)&&(a.push(r,0,o,n),r=6),e&&(a.push(r,e,0,n),r=6)),o=""},l=0;l<e.length;l++){l&&(1===r&&u(),u(l));for(var c=0;c<e[l].length;c++)t=e[l][c],1===r?"<"===t?(u(),a=[a],r=3):o+=t:4===r?"--"===o&&">"===t?(r=1,o=""):o=t+o[0]:i?t===i?i="":o+=t:'"'===t||"'"===t?i=t:">"===t?(u(),r=1):r&&("="===t?(r=5,n=o,o=""):"/"===t&&(r<5||">"===e[l][c+1])?(u(),3===r&&(a=a[0]),r=a,(a=a[0]).push(2,0,r),r=0):" "===t||"\t"===t||"\n"===t||"\r"===t?(u(),r=2):o+=t),3===r&&"!--"===o&&(r=4,a=a[0])}return u(),a}(e)),t),arguments,[])).length>1?t:t[0]}var Re=function(e){var t=e.environment,n=t.document.createElementNS("http://www.w3.org/2000/svg","svg");n.setAttribute("class","aa-SubmitIcon"),n.setAttribute("viewBox","0 0 24 24"),n.setAttribute("width","20"),n.setAttribute("height","20"),n.setAttribute("fill","currentColor");var r=t.document.createElementNS("http://www.w3.org/2000/svg","path");return r.setAttribute("d","M16.041 15.856c-0.034 0.026-0.067 0.055-0.099 0.087s-0.060 0.064-0.087 0.099c-1.258 1.213-2.969 1.958-4.855 1.958-1.933 0-3.682-0.782-4.95-2.050s-2.050-3.017-2.050-4.95 0.782-3.682 2.050-4.95 3.017-2.050 4.95-2.050 3.682 0.782 4.95 2.050 2.050 3.017 2.050 4.95c0 1.886-0.745 3.597-1.959 4.856zM21.707 20.293l-3.675-3.675c1.231-1.54 1.968-3.493 1.968-5.618 0-2.485-1.008-4.736-2.636-6.364s-3.879-2.636-6.364-2.636-4.736 1.008-6.364 2.636-2.636 3.879-2.636 6.364 1.008 4.736 2.636 6.364 3.879 2.636 6.364 2.636c2.125 0 4.078-0.737 5.618-1.968l3.675 3.675c0.391 0.391 1.024 0.391 1.414 0s0.391-1.024 0-1.414z"),n.appendChild(r),n},Ae=function(e){var t=e.environment,n=t.document.createElementNS("http://www.w3.org/2000/svg","svg");n.setAttribute("class","aa-ClearIcon"),n.setAttribute("viewBox","0 0 24 24"),n.setAttribute("width","18"),n.setAttribute("height","18"),n.setAttribute("fill","currentColor");var r=t.document.createElementNS("http://www.w3.org/2000/svg","path");return r.setAttribute("d","M5.293 6.707l5.293 5.293-5.293 5.293c-0.391 0.391-0.391 1.024 0 1.414s1.024 0.391 1.414 0l5.293-5.293 5.293 5.293c0.391 0.391 1.024 0.391 1.414 0s0.391-1.024 0-1.414l-5.293-5.293 5.293-5.293c0.391-0.391 0.391-1.024 0-1.414s-1.024-0.391-1.414 0l-5.293 5.293-5.293-5.293c-0.391-0.391-1.024-0.391-1.414 0s-0.391 1.024 0 1.414z"),n.appendChild(r),n},Ne=function(e){var t=e.environment.document.createElementNS("http://www.w3.org/2000/svg","svg");return t.setAttribute("class","aa-LoadingIcon"),t.setAttribute("viewBox","0 0 100 100"),t.setAttribute("width","20"),t.setAttribute("height","20"),t.innerHTML='<circle\n cx="50"\n cy="50"\n fill="none"\n r="35"\n stroke="currentColor"\n stroke-dasharray="164.93361431346415 56.97787143782138"\n stroke-width="6"\n>\n <animateTransform\n attributeName="transform"\n type="rotate"\n repeatCount="indefinite"\n dur="1s"\n values="0 50 50;90 50 50;180 50 50;360 50 50"\n keyTimes="0;0.40;0.65;1"\n />\n</circle>',t},Fe=["ontouchstart","ontouchend","ontouchmove","ontouchcancel"];function Le(e,t,n){e[t]=null===n?"":"number"!==typeof n?n:n+"px"}function ze(e){this._listeners[e.type](e)}function qe(e,t,n){var r,o,i=e[t];if("style"===t)if("string"==typeof n)e.style=n;else if(null===n)e.style="";else for(t in n)i&&n[t]===i[t]||Le(e.style,t,n[t]);else"o"===t[0]&&"n"===t[1]?(r=t!==(t=t.replace(/Capture$/,"")),((o=t.toLowerCase())in e||Fe.includes(o))&&(t=o),t=t.slice(2),e._listeners||(e._listeners={}),e._listeners[t]=n,n?i||e.addEventListener(t,ze,r):e.removeEventListener(t,ze,r)):"list"!==t&&"tagName"!==t&&"form"!==t&&"type"!==t&&"size"!==t&&"download"!==t&&"href"!==t&&t in e?e[t]=null==n?"":n:"function"!=typeof n&&"dangerouslySetInnerHTML"!==t&&(null==n||!1===n&&!/^ar/.test(t)?e.removeAttribute(t):e.setAttribute(t,n))}function Be(e){return"onChange"===e?"onInput":e}function Ue(e,t){for(var n in t)qe(e,Be(n),t[n])}function Ve(e,t){for(var n in t)"o"===n[0]&&"n"===n[1]||qe(e,Be(n),t[n])}var He=["children"];function We(e){return function(e){if(Array.isArray(e))return $e(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return $e(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return $e(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function $e(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Ke(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function Ge(e){return function(t,n){var r=n.children,o=void 0===r?[]:r,i=Ke(n,He),a=e.document.createElement(t);return Ue(a,i),a.append.apply(a,We(o)),a}}var Ye=["autocompleteScopeApi","environment","classNames","getInputProps","getInputPropsCore","isDetached","state"];function Je(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Qe(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Je(Object(n),!0).forEach((function(t){Ze(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Je(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ze(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Xe(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function et(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function tt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?et(Object(n),!0).forEach((function(t){nt(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):et(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function nt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rt(e){var t=e.autocomplete,n=e.autocompleteScopeApi,r=e.classNames,o=e.environment,i=e.isDetached,a=e.placeholder,u=void 0===a?"Search":a,l=e.propGetters,c=e.setIsModalOpen,s=e.state,f=e.translations,p=Ge(o),d=l.getRootProps(tt({state:s,props:t.getRootProps({})},n)),v=p("div",tt({class:r.root},d)),h=p("div",{class:r.detachedContainer,onMouseDown:function(e){e.stopPropagation()}}),y=p("div",{class:r.detachedOverlay,children:[h],onMouseDown:function(){c(!1),t.setIsOpen(!1)}}),m=l.getLabelProps(tt({state:s,props:t.getLabelProps({})},n)),b=p("button",{class:r.submitButton,type:"submit",title:f.submitButtonTitle,children:[Re({environment:o})]}),g=p("label",tt({class:r.label,children:[b]},m)),O=p("button",{class:r.clearButton,type:"reset",title:f.clearButtonTitle,children:[Ae({environment:o})]}),w=p("div",{class:r.loadingIndicator,children:[Ne({environment:o})]}),j=function(e){var t=e.autocompleteScopeApi,n=e.environment,r=(e.classNames,e.getInputProps),o=e.getInputPropsCore,i=e.isDetached,a=e.state,u=Xe(e,Ye),l=Ge(n)("input",u),c=r(Qe({state:a,props:o({inputElement:l}),inputElement:l},t));return Ue(l,Qe(Qe({},c),{},{onKeyDown:function(e){i&&"Tab"===e.key||c.onKeyDown(e)}})),l}({class:r.input,environment:o,state:s,getInputProps:l.getInputProps,getInputPropsCore:t.getInputProps,autocompleteScopeApi:n,isDetached:i}),_=p("div",{class:r.inputWrapperPrefix,children:[g,w]}),P=p("div",{class:r.inputWrapperSuffix,children:[O]}),S=p("div",{class:r.inputWrapper,children:[j]}),x=l.getFormProps(tt({state:s,props:t.getFormProps({inputElement:j})},n)),k=p("form",tt({class:r.form,children:[_,S,P]},x)),E=l.getPanelProps(tt({state:s,props:t.getPanelProps({})},n)),I=p("div",tt({class:r.panel},E));if(i){var C=p("div",{class:r.detachedSearchButtonIcon,children:[Re({environment:o})]}),M=p("div",{class:r.detachedSearchButtonPlaceholder,textContent:u}),D=p("button",{type:"button",class:r.detachedSearchButton,onClick:function(){c(!0)},children:[C,M]}),T=p("button",{type:"button",class:r.detachedCancelButton,textContent:f.detachedCancelButtonText,onTouchStart:function(e){e.stopPropagation()},onClick:function(){t.setIsOpen(!1),c(!1)}}),R=p("div",{class:r.detachedFormContainer,children:[k,T]});h.appendChild(R),v.appendChild(D)}else v.appendChild(k);return{detachedContainer:h,detachedOverlay:y,inputWrapper:S,input:j,root:v,form:k,label:g,submitButton:b,clearButton:O,loadingIndicator:w,panel:I}}var ot,it,at,ut,lt,ct={},st=[],ft=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i;function pt(e,t){for(var n in t)e[n]=t[n];return e}function dt(e){var t=e.parentNode;t&&t.removeChild(e)}function vt(e,t,n){var r,o,i,a={};for(i in t)"key"==i?r=t[i]:"ref"==i?o=t[i]:a[i]=t[i];if(arguments.length>2&&(a.children=arguments.length>3?ot.call(arguments,2):n),"function"==typeof e&&null!=e.defaultProps)for(i in e.defaultProps)void 0===a[i]&&(a[i]=e.defaultProps[i]);return ht(e,a,r,o,null)}function ht(e,t,n,r,o){var i={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:null==o?++at:o};return null==o&&null!=it.vnode&&it.vnode(i),i}function yt(e){return e.children}function mt(e,t){this.props=e,this.context=t}function bt(e,t){if(null==t)return e.__?bt(e.__,e.__.__k.indexOf(e)+1):null;for(var n;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e)return n.__e;return"function"==typeof e.type?bt(e):null}function gt(e){var t,n;if(null!=(e=e.__)&&null!=e.__c){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e){e.__e=e.__c.base=n.__e;break}return gt(e)}}function Ot(e){(!e.__d&&(e.__d=!0)&&ut.push(e)&&!wt.__r++||lt!==it.debounceRendering)&&((lt=it.debounceRendering)||setTimeout)(wt)}function wt(){for(var e;wt.__r=ut.length;)e=ut.sort((function(e,t){return e.__v.__b-t.__v.__b})),ut=[],e.some((function(e){var t,n,r,o,i,a;e.__d&&(i=(o=(t=e).__v).__e,(a=t.__P)&&(n=[],(r=pt({},o)).__v=o.__v+1,It(a,o,r,t.__n,void 0!==a.ownerSVGElement,null!=o.__h?[i]:null,n,null==i?bt(o):i,o.__h),Ct(n,o),o.__e!=i&&gt(o)))}))}function jt(e,t,n,r,o,i,a,u,l,c){var s,f,p,d,v,h,y,m=r&&r.__k||st,b=m.length;for(n.__k=[],s=0;s<t.length;s++)if(null!=(d=n.__k[s]=null==(d=t[s])||"boolean"==typeof d?null:"string"==typeof d||"number"==typeof d||"bigint"==typeof d?ht(null,d,null,null,d):Array.isArray(d)?ht(yt,{children:d},null,null,null):d.__b>0?ht(d.type,d.props,d.key,null,d.__v):d)){if(d.__=n,d.__b=n.__b+1,null===(p=m[s])||p&&d.key==p.key&&d.type===p.type)m[s]=void 0;else for(f=0;f<b;f++){if((p=m[f])&&d.key==p.key&&d.type===p.type){m[f]=void 0;break}p=null}It(e,d,p=p||ct,o,i,a,u,l,c),v=d.__e,(f=d.ref)&&p.ref!=f&&(y||(y=[]),p.ref&&y.push(p.ref,null,d),y.push(f,d.__c||v,d)),null!=v?(null==h&&(h=v),"function"==typeof d.type&&d.__k===p.__k?d.__d=l=_t(d,l,e):l=Pt(e,d,p,m,v,l),"function"==typeof n.type&&(n.__d=l)):l&&p.__e==l&&l.parentNode!=e&&(l=bt(p))}for(n.__e=h,s=b;s--;)null!=m[s]&&("function"==typeof n.type&&null!=m[s].__e&&m[s].__e==n.__d&&(n.__d=bt(r,s+1)),Tt(m[s],m[s]));if(y)for(s=0;s<y.length;s++)Dt(y[s],y[++s],y[++s])}function _t(e,t,n){for(var r,o=e.__k,i=0;o&&i<o.length;i++)(r=o[i])&&(r.__=e,t="function"==typeof r.type?_t(r,t,n):Pt(n,r,r,o,r.__e,t));return t}function Pt(e,t,n,r,o,i){var a,u,l;if(void 0!==t.__d)a=t.__d,t.__d=void 0;else if(null==n||o!=i||null==o.parentNode)e:if(null==i||i.parentNode!==e)e.appendChild(o),a=null;else{for(u=i,l=0;(u=u.nextSibling)&&l<r.length;l+=2)if(u==o)break e;e.insertBefore(o,i),a=i}return void 0!==a?a:o.nextSibling}function St(e,t,n){"-"===t[0]?e.setProperty(t,n):e[t]=null==n?"":"number"!=typeof n||ft.test(t)?n:n+"px"}function xt(e,t,n,r,o){var i;e:if("style"===t)if("string"==typeof n)e.style.cssText=n;else{if("string"==typeof r&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||St(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||St(e.style,t,n[t])}else if("o"===t[0]&&"n"===t[1])i=t!==(t=t.replace(/Capture$/,"")),t=t.toLowerCase()in e?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=n,n?r||e.addEventListener(t,i?Et:kt,i):e.removeEventListener(t,i?Et:kt,i);else if("dangerouslySetInnerHTML"!==t){if(o)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("href"!==t&&"list"!==t&&"form"!==t&&"tabIndex"!==t&&"download"!==t&&t in e)try{e[t]=null==n?"":n;break e}catch(e){}"function"==typeof n||(null!=n&&(!1!==n||"a"===t[0]&&"r"===t[1])?e.setAttribute(t,n):e.removeAttribute(t))}}function kt(e){this.l[e.type+!1](it.event?it.event(e):e)}function Et(e){this.l[e.type+!0](it.event?it.event(e):e)}function It(e,t,n,r,o,i,a,u,l){var c,s,f,p,d,v,h,y,m,b,g,O,w,j=t.type;if(void 0!==t.constructor)return null;null!=n.__h&&(l=n.__h,u=t.__e=n.__e,t.__h=null,i=[u]),(c=it.__b)&&c(t);try{e:if("function"==typeof j){if(y=t.props,m=(c=j.contextType)&&r[c.__c],b=c?m?m.props.value:c.__:r,n.__c?h=(s=t.__c=n.__c).__=s.__E:("prototype"in j&&j.prototype.render?t.__c=s=new j(y,b):(t.__c=s=new mt(y,b),s.constructor=j,s.render=Rt),m&&m.sub(s),s.props=y,s.state||(s.state={}),s.context=b,s.__n=r,f=s.__d=!0,s.__h=[]),null==s.__s&&(s.__s=s.state),null!=j.getDerivedStateFromProps&&(s.__s==s.state&&(s.__s=pt({},s.__s)),pt(s.__s,j.getDerivedStateFromProps(y,s.__s))),p=s.props,d=s.state,f)null==j.getDerivedStateFromProps&&null!=s.componentWillMount&&s.componentWillMount(),null!=s.componentDidMount&&s.__h.push(s.componentDidMount);else{if(null==j.getDerivedStateFromProps&&y!==p&&null!=s.componentWillReceiveProps&&s.componentWillReceiveProps(y,b),!s.__e&&null!=s.shouldComponentUpdate&&!1===s.shouldComponentUpdate(y,s.__s,b)||t.__v===n.__v){s.props=y,s.state=s.__s,t.__v!==n.__v&&(s.__d=!1),s.__v=t,t.__e=n.__e,t.__k=n.__k,t.__k.forEach((function(e){e&&(e.__=t)})),s.__h.length&&a.push(s);break e}null!=s.componentWillUpdate&&s.componentWillUpdate(y,s.__s,b),null!=s.componentDidUpdate&&s.__h.push((function(){s.componentDidUpdate(p,d,v)}))}if(s.context=b,s.props=y,s.__v=t,s.__P=e,g=it.__r,O=0,"prototype"in j&&j.prototype.render)s.state=s.__s,s.__d=!1,g&&g(t),c=s.render(s.props,s.state,s.context);else do{s.__d=!1,g&&g(t),c=s.render(s.props,s.state,s.context),s.state=s.__s}while(s.__d&&++O<25);s.state=s.__s,null!=s.getChildContext&&(r=pt(pt({},r),s.getChildContext())),f||null==s.getSnapshotBeforeUpdate||(v=s.getSnapshotBeforeUpdate(p,d)),w=null!=c&&c.type===yt&&null==c.key?c.props.children:c,jt(e,Array.isArray(w)?w:[w],t,n,r,o,i,a,u,l),s.base=t.__e,t.__h=null,s.__h.length&&a.push(s),h&&(s.__E=s.__=null),s.__e=!1}else null==i&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=Mt(n.__e,t,n,r,o,i,a,l);(c=it.diffed)&&c(t)}catch(e){t.__v=null,(l||null!=i)&&(t.__e=u,t.__h=!!l,i[i.indexOf(u)]=null),it.__e(e,t,n)}}function Ct(e,t){it.__c&&it.__c(t,e),e.some((function(t){try{e=t.__h,t.__h=[],e.some((function(e){e.call(t)}))}catch(e){it.__e(e,t.__v)}}))}function Mt(e,t,n,r,o,i,a,u){var l,c,s,f=n.props,p=t.props,d=t.type,v=0;if("svg"===d&&(o=!0),null!=i)for(;v<i.length;v++)if((l=i[v])&&"setAttribute"in l==!!d&&(d?l.localName===d:3===l.nodeType)){e=l,i[v]=null;break}if(null==e){if(null===d)return document.createTextNode(p);e=o?document.createElementNS("http://www.w3.org/2000/svg",d):document.createElement(d,p.is&&p),i=null,u=!1}if(null===d)f===p||u&&e.data===p||(e.data=p);else{if(i=i&&ot.call(e.childNodes),c=(f=n.props||ct).dangerouslySetInnerHTML,s=p.dangerouslySetInnerHTML,!u){if(null!=i)for(f={},v=0;v<e.attributes.length;v++)f[e.attributes[v].name]=e.attributes[v].value;(s||c)&&(s&&(c&&s.__html==c.__html||s.__html===e.innerHTML)||(e.innerHTML=s&&s.__html||""))}if(function(e,t,n,r,o){var i;for(i in n)"children"===i||"key"===i||i in t||xt(e,i,null,n[i],r);for(i in t)o&&"function"!=typeof t[i]||"children"===i||"key"===i||"value"===i||"checked"===i||n[i]===t[i]||xt(e,i,t[i],n[i],r)}(e,p,f,o,u),s)t.__k=[];else if(v=t.props.children,jt(e,Array.isArray(v)?v:[v],t,n,r,o&&"foreignObject"!==d,i,a,i?i[0]:n.__k&&bt(n,0),u),null!=i)for(v=i.length;v--;)null!=i[v]&&dt(i[v]);u||("value"in p&&void 0!==(v=p.value)&&(v!==e.value||"progress"===d&&!v||"option"===d&&v!==f.value)&&xt(e,"value",v,f.value,!1),"checked"in p&&void 0!==(v=p.checked)&&v!==e.checked&&xt(e,"checked",v,f.checked,!1))}return e}function Dt(e,t,n){try{"function"==typeof e?e(t):e.current=t}catch(e){it.__e(e,n)}}function Tt(e,t,n){var r,o;if(it.unmount&&it.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||Dt(r,null,t)),null!=(r=e.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(e){it.__e(e,t)}r.base=r.__P=null}if(r=e.__k)for(o=0;o<r.length;o++)r[o]&&Tt(r[o],t,"function"!=typeof e.type);n||null==e.__e||dt(e.__e),e.__e=e.__d=void 0}function Rt(e,t,n){return this.constructor(e,n)}function At(e,t,n){var r,o,i;it.__&&it.__(e,t),o=(r="function"==typeof n)?null:n&&n.__k||t.__k,i=[],It(t,e=(!r&&n||t).__k=vt(yt,null,[e]),o||ct,ct,void 0!==t.ownerSVGElement,!r&&n?[n]:o?null:t.firstChild?ot.call(t.childNodes):null,i,!r&&n?n:o?o.__e:t.firstChild,r),Ct(i,e)}function Nt(e,t){return t.reduce((function(e,t){return e&&e[t]}),e)}ot=st.slice,it={__e:function(e,t,n,r){for(var o,i,a;t=t.__;)if((o=t.__c)&&!o.__)try{if((i=o.constructor)&&null!=i.getDerivedStateFromError&&(o.setState(i.getDerivedStateFromError(e)),a=o.__d),null!=o.componentDidCatch&&(o.componentDidCatch(e,r||{}),a=o.__d),a)return o.__E=o}catch(t){e=t}throw e}},at=0,mt.prototype.setState=function(e,t){var n;n=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=pt({},this.state),"function"==typeof e&&(e=e(pt({},n),this.props)),e&&pt(n,e),null!=e&&this.__v&&(t&&this.__h.push(t),Ot(this))},mt.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),Ot(this))},mt.prototype.render=yt,ut=[],wt.__r=0;var Ft="__aa-highlight__",Lt="__/aa-highlight__";function zt(e){var t=e.highlightedValue.split(Ft),n=t.shift(),r=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return{get:function(){return e},add:function(t){var n=e[e.length-1];(null===n||void 0===n?void 0:n.isHighlighted)===t.isHighlighted?e[e.length-1]={value:n.value+t.value,isHighlighted:n.isHighlighted}:e.push(t)}}}(n?[{value:n,isHighlighted:!1}]:[]);return t.forEach((function(e){var t=e.split(Lt);r.add({value:t[0],isHighlighted:!0}),""!==t[1]&&r.add({value:t[1],isHighlighted:!1})})),r.get()}function qt(e){return function(e){if(Array.isArray(e))return Bt(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return Bt(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Bt(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Bt(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Ut(e){var t=e.hit,n=e.attribute,r=Array.isArray(n)?n:[n],o=Nt(t,["_highlightResult"].concat(qt(r),["value"]));return"string"!==typeof o&&(o=Nt(t,r)||""),zt({highlightedValue:o})}function Vt(e){var t=e.createElement,n=e.Fragment;function r(e){var r=e.hit,o=e.attribute,i=e.tagName,a=void 0===i?"mark":i;return t(n,{},Ut({hit:r,attribute:o}).map((function(e,n){return e.isHighlighted?t(a,{key:n},e.value):e.value})))}return r.__autocomplete_componentName="Highlight",r}var Ht={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},Wt=new RegExp(/\w/i),$t=/&(amp|quot|lt|gt|#39);/g,Kt=RegExp($t.source);function Gt(e,t){var n,r,o,i=e[t],a=(null===(n=e[t+1])||void 0===n?void 0:n.isHighlighted)||!0,u=(null===(r=e[t-1])||void 0===r?void 0:r.isHighlighted)||!0;return Wt.test((o=i.value)&&Kt.test(o)?o.replace($t,(function(e){return Ht[e]})):o)||u!==a?i.isHighlighted:u}function Yt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Jt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yt(Object(n),!0).forEach((function(t){Qt(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Qt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Zt(e){return e.some((function(e){return e.isHighlighted}))?e.map((function(t,n){return Jt(Jt({},t),{},{isHighlighted:!Gt(e,n)})})):e.map((function(e){return Jt(Jt({},e),{},{isHighlighted:!1})}))}function Xt(e){var t=e.createElement,n=e.Fragment;function r(e){var r,o=e.hit,i=e.attribute,a=e.tagName,u=void 0===a?"mark":a;return t(n,{},(r={hit:o,attribute:i},Zt(Ut(r))).map((function(e,n){return e.isHighlighted?t(u,{key:n},e.value):e.value})))}return r.__autocomplete_componentName="ReverseHighlight",r}function en(e){return function(e){if(Array.isArray(e))return tn(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return tn(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return tn(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function tn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function nn(e){var t=e.hit,n=e.attribute,r=Array.isArray(n)?n:[n],o=Nt(t,["_snippetResult"].concat(en(r),["value"]));return"string"!==typeof o&&(o=Nt(t,r)||""),zt({highlightedValue:o})}function rn(e){var t=e.createElement,n=e.Fragment;function r(e){var r,o=e.hit,i=e.attribute,a=e.tagName,u=void 0===a?"mark":a;return t(n,{},(r={hit:o,attribute:i},Zt(nn(r))).map((function(e,n){return e.isHighlighted?t(u,{key:n},e.value):e.value})))}return r.__autocomplete_componentName="ReverseSnippet",r}function on(e){var t=e.createElement,n=e.Fragment;function r(e){var r=e.hit,o=e.attribute,i=e.tagName,a=void 0===i?"mark":i;return t(n,{},nn({hit:r,attribute:o}).map((function(e,n){return e.isHighlighted?t(a,{key:n},e.value):e.value})))}return r.__autocomplete_componentName="Snippet",r}function an(e,t){if("string"===typeof t){var n=e.document.querySelector(t);return"The element ".concat(JSON.stringify(t)," is not in the document."),n}return t}function un(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce((function(e,t){return Object.keys(t).forEach((function(n){var r=e[n],o=t[n];r!==o&&(e[n]=[r,o].filter(Boolean).join(" "))})),e}),{})}var ln=["classNames","container","getEnvironmentProps","getFormProps","getInputProps","getItemProps","getLabelProps","getListProps","getPanelProps","getRootProps","panelContainer","panelPlacement","render","renderNoResults","renderer","detachedMediaQuery","components","translations"];function cn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function sn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?cn(Object(n),!0).forEach((function(t){fn(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function fn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pn(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var dn={clearButton:"aa-ClearButton",detachedCancelButton:"aa-DetachedCancelButton",detachedContainer:"aa-DetachedContainer",detachedFormContainer:"aa-DetachedFormContainer",detachedOverlay:"aa-DetachedOverlay",detachedSearchButton:"aa-DetachedSearchButton",detachedSearchButtonIcon:"aa-DetachedSearchButtonIcon",detachedSearchButtonPlaceholder:"aa-DetachedSearchButtonPlaceholder",form:"aa-Form",input:"aa-Input",inputWrapper:"aa-InputWrapper",inputWrapperPrefix:"aa-InputWrapperPrefix",inputWrapperSuffix:"aa-InputWrapperSuffix",item:"aa-Item",label:"aa-Label",list:"aa-List",loadingIndicator:"aa-LoadingIndicator",panel:"aa-Panel",panelLayout:"aa-PanelLayout aa-Panel--scrollable",root:"aa-Autocomplete",source:"aa-Source",sourceFooter:"aa-SourceFooter",sourceHeader:"aa-SourceHeader",sourceNoResults:"aa-SourceNoResults",submitButton:"aa-SubmitButton"},vn=function(e,t){var n=e.children;(0,e.render)(n,t)},hn={createElement:vt,Fragment:yt,render:At};function yn(e){var t=e.panelPlacement,n=e.container,r=e.form,o=e.environment,i=n.getBoundingClientRect(),a=(o.pageYOffset||o.document.documentElement.scrollTop||o.document.body.scrollTop||0)+i.top+i.height;switch(t){case"start":return{top:a,left:i.left};case"end":return{top:a,right:o.document.documentElement.clientWidth-(i.left+i.width)};case"full-width":return{top:a,left:0,right:0,width:"unset",maxWidth:"unset"};case"input-wrapper-width":var u=r.getBoundingClientRect();return{top:a,left:u.left,right:o.document.documentElement.clientWidth-(u.left+u.width),width:"unset",maxWidth:"unset"};default:throw new Error("[Autocomplete] The `panelPlacement` value ".concat(JSON.stringify(t)," is not valid."))}}function mn(){return mn=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},mn.apply(this,arguments)}function bn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function gn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bn(Object(n),!0).forEach((function(t){On(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function On(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var wn=[{segment:"autocomplete-js",version:de}];function jn(e){return function(e){if(Array.isArray(e))return _n(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return _n(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _n(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function _n(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Pn(e){return Pn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Pn(e)}var Sn=function(e){return e&&"object"===Pn(e)&&"[object Object]"===Object.prototype.toString.call(e)};function xn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce((function(e,t){return Object.keys(t).forEach((function(n){var r=e[n],o=t[n];Array.isArray(r)&&Array.isArray(o)?e[n]=r.concat.apply(r,jn(o)):Sn(r)&&Sn(o)?e[n]=xn(r,o):e[n]=o})),e}),{})}function kn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function En(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?kn(Object(n),!0).forEach((function(t){In(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function In(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Cn(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==n)return;var r,o,i=[],a=!0,u=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(l){u=!0,o=l}finally{try{a||null==n.return||n.return()}finally{if(u)throw o}}return i}(e,t)||function(e,t){if(!e)return;if("string"===typeof e)return Mn(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Mn(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Mn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Dn(e,t){return Object.entries(e).reduce((function(e,n){var r=Cn(n,2),o=r[0],i=r[1];return t({key:o,value:i})?En(En({},e),{},In({},o,i)):e}),{})}var Tn=["components"];function Rn(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function An(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Nn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?An(Object(n),!0).forEach((function(t){Fn(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):An(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Fn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ln(e){var t=function(){var e=[],t=[];function n(n){e.push(n);var r=n();t.push(r)}return{runEffect:n,cleanupEffects:function(){var e=t;t=[],e.forEach((function(e){e()}))},runEffects:function(){var t=e;e=[],t.forEach((function(e){n(e)}))}}}(),n=t.runEffect,r=t.cleanupEffects,o=t.runEffects,i=function(){var e=[];return{reactive:function(t){var n=t(),r={_fn:t,_ref:{current:n},get value(){return this._ref.current},set value(e){this._ref.current=e}};return e.push(r),r},runReactives:function(){e.forEach((function(e){e._ref.current=e._fn()}))}}}(),a=i.reactive,u=i.runReactives,l=Ie(!1),c=Ie(e),s=Ie(void 0),p=a((function(){return function(e){var t,n=e.classNames,r=e.container,o=e.getEnvironmentProps,i=e.getFormProps,a=e.getInputProps,u=e.getItemProps,l=e.getLabelProps,c=e.getListProps,s=e.getPanelProps,f=e.getRootProps,p=e.panelContainer,v=e.panelPlacement,h=e.render,y=e.renderNoResults,m=e.renderer,b=e.detachedMediaQuery,g=e.components,O=e.translations,w=pn(e,ln),j="undefined"!==typeof window?window:{},_=an(j,r);_.tagName;var P=sn(sn({},hn),m),S={Highlight:Vt(P),ReverseHighlight:Xt(P),ReverseSnippet:rn(P),Snippet:on(P)};return{renderer:{classNames:un(dn,null!==n&&void 0!==n?n:{}),container:_,getEnvironmentProps:null!==o&&void 0!==o?o:function(e){return e.props},getFormProps:null!==i&&void 0!==i?i:function(e){return e.props},getInputProps:null!==a&&void 0!==a?a:function(e){return e.props},getItemProps:null!==u&&void 0!==u?u:function(e){return e.props},getLabelProps:null!==l&&void 0!==l?l:function(e){return e.props},getListProps:null!==c&&void 0!==c?c:function(e){return e.props},getPanelProps:null!==s&&void 0!==s?s:function(e){return e.props},getRootProps:null!==f&&void 0!==f?f:function(e){return e.props},panelContainer:p?an(j,p):j.document.body,panelPlacement:null!==v&&void 0!==v?v:"input-wrapper-width",render:null!==h&&void 0!==h?h:vn,renderNoResults:y,renderer:P,detachedMediaQuery:null!==b&&void 0!==b?b:getComputedStyle(j.document.documentElement).getPropertyValue("--aa-detached-media-query"),components:sn(sn({},S),g),translations:sn(sn({},{clearButtonTitle:"Clear",detachedCancelButtonText:"Cancel",submitButtonTitle:"Submit"}),O)},core:sn(sn({},w),{},{id:null!==(t=w.id)&&void 0!==t?t:d(),environment:j})}}(c.current)})),v=a((function(){return p.value.core.environment.matchMedia(p.value.renderer.detachedMediaQuery).matches})),h=a((function(){return Ee(Nn(Nn({},p.value.core),{},{onStateChange:function(e){var t,n,r;l.current=e.state.collections.some((function(e){return e.source.templates.noResults})),null===(t=s.current)||void 0===t||t.call(s,e),null===(n=(r=p.value.core).onStateChange)||void 0===n||n.call(r,e)},shouldPanelOpen:c.current.shouldPanelOpen||function(e){var t=e.state;if(v.value)return!0;var n=f(t)>0;if(!p.value.core.openOnFocus&&!t.query)return n;var r=Boolean(l.current||p.value.renderer.renderNoResults);return!n&&r||n},__autocomplete_metadata:{userAgents:wn,options:e}}))})),y=Ie(Nn({collections:[],completion:null,context:{},isOpen:!1,query:"",activeItemId:null,status:"idle"},p.value.core.initialState)),m={getEnvironmentProps:p.value.renderer.getEnvironmentProps,getFormProps:p.value.renderer.getFormProps,getInputProps:p.value.renderer.getInputProps,getItemProps:p.value.renderer.getItemProps,getLabelProps:p.value.renderer.getLabelProps,getListProps:p.value.renderer.getListProps,getPanelProps:p.value.renderer.getPanelProps,getRootProps:p.value.renderer.getRootProps},b={setActiveItemId:h.value.setActiveItemId,setQuery:h.value.setQuery,setCollections:h.value.setCollections,setIsOpen:h.value.setIsOpen,setStatus:h.value.setStatus,setContext:h.value.setContext,refresh:h.value.refresh},g=a((function(){return Te.bind(p.value.renderer.renderer.createElement)})),O=a((function(){return rt({autocomplete:h.value,autocompleteScopeApi:b,classNames:p.value.renderer.classNames,environment:p.value.core.environment,isDetached:v.value,placeholder:p.value.core.placeholder,propGetters:m,setIsModalOpen:P,state:y.current,translations:p.value.renderer.translations})}));function w(){Ue(O.value.panel,{style:v.value?{}:yn({panelPlacement:p.value.renderer.panelPlacement,container:O.value.root,form:O.value.form,environment:p.value.core.environment})})}function j(e){y.current=e;var t={autocomplete:h.value,autocompleteScopeApi:b,classNames:p.value.renderer.classNames,components:p.value.renderer.components,container:p.value.renderer.container,html:g.value,dom:O.value,panelContainer:v.value?O.value.detachedContainer:p.value.renderer.panelContainer,propGetters:m,state:y.current,renderer:p.value.renderer.renderer},n=!f(e)&&!l.current&&p.value.renderer.renderNoResults||p.value.renderer.render;!function(e){var t=e.autocomplete,n=e.autocompleteScopeApi,r=e.dom,o=e.propGetters,i=e.state;Ve(r.root,o.getRootProps(gn({state:i,props:t.getRootProps({})},n))),Ve(r.input,o.getInputProps(gn({state:i,props:t.getInputProps({inputElement:r.input}),inputElement:r.input},n))),Ue(r.label,{hidden:"stalled"===i.status}),Ue(r.loadingIndicator,{hidden:"stalled"!==i.status}),Ue(r.clearButton,{hidden:!i.query})}(t),function(e,t){var n=t.autocomplete,r=t.autocompleteScopeApi,o=t.classNames,i=t.html,a=t.dom,u=t.panelContainer,l=t.propGetters,c=t.state,s=t.components,f=t.renderer;if(c.isOpen){u.contains(a.panel)||"loading"===c.status||u.appendChild(a.panel),a.panel.classList.toggle("aa-Panel--stalled","stalled"===c.status);var p=c.collections.filter((function(e){var t=e.source,n=e.items;return t.templates.noResults||n.length>0})).map((function(e,t){var a=e.source,u=e.items;return f.createElement("section",{key:t,className:o.source,"data-autocomplete-source-id":a.sourceId},a.templates.header&&f.createElement("div",{className:o.sourceHeader},a.templates.header({components:s,createElement:f.createElement,Fragment:f.Fragment,items:u,source:a,state:c,html:i})),a.templates.noResults&&0===u.length?f.createElement("div",{className:o.sourceNoResults},a.templates.noResults({components:s,createElement:f.createElement,Fragment:f.Fragment,source:a,state:c,html:i})):f.createElement("ul",mn({className:o.list},l.getListProps(gn({state:c,props:n.getListProps({})},r))),u.map((function(e){var t=n.getItemProps({item:e,source:a});return f.createElement("li",mn({key:t.id,className:o.item},l.getItemProps(gn({state:c,props:t},r))),a.templates.item({components:s,createElement:f.createElement,Fragment:f.Fragment,item:e,state:c,html:i}))}))),a.templates.footer&&f.createElement("div",{className:o.sourceFooter},a.templates.footer({components:s,createElement:f.createElement,Fragment:f.Fragment,items:u,source:a,state:c,html:i})))})),d=f.createElement(f.Fragment,null,f.createElement("div",{className:o.panelLayout},p),f.createElement("div",{className:"aa-GradientBottom"})),v=p.reduce((function(e,t){return e[t.props["data-autocomplete-source-id"]]=t,e}),{});e(gn(gn({children:d,state:c,sections:p,elements:v},f),{},{components:s,html:i},r),a.panel)}else u.contains(a.panel)&&u.removeChild(a.panel)}(n,t)}function _(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};r();var t=p.value.renderer,n=t.components,i=Rn(t,Tn);c.current=xn(i,p.value.core,{components:Dn(n,(function(e){return!e.value.hasOwnProperty("__autocomplete_componentName")})),initialState:y.current},e),u(),o(),h.value.refresh().then((function(){j(y.current)}))}function P(e){requestAnimationFrame((function(){var t=p.value.core.environment.document.body.contains(O.value.detachedOverlay);e!==t&&(e?(p.value.core.environment.document.body.appendChild(O.value.detachedOverlay),p.value.core.environment.document.body.classList.add("aa-Detached"),O.value.input.focus()):(p.value.core.environment.document.body.removeChild(O.value.detachedOverlay),p.value.core.environment.document.body.classList.remove("aa-Detached"),h.value.setQuery(""),h.value.refresh()))}))}return n((function(){var e=h.value.getEnvironmentProps({formElement:O.value.form,panelElement:O.value.panel,inputElement:O.value.input});return Ue(p.value.core.environment,e),function(){Ue(p.value.core.environment,Object.keys(e).reduce((function(e,t){return Nn(Nn({},e),{},Fn({},t,void 0))}),{}))}})),n((function(){var e=v.value?p.value.core.environment.document.body:p.value.renderer.panelContainer,t=v.value?O.value.detachedOverlay:O.value.panel;return v.value&&y.current.isOpen&&P(!0),j(y.current),function(){e.contains(t)&&e.removeChild(t)}})),n((function(){var e=p.value.renderer.container;return e.appendChild(O.value.root),function(){e.removeChild(O.value.root)}})),n((function(){var e=Ce((function(e){j(e.state)}),0);return s.current=function(t){var n=t.state,r=t.prevState;(v.value&&r.isOpen!==n.isOpen&&P(n.isOpen),v.value||!n.isOpen||r.isOpen||w(),n.query!==r.query)&&p.value.core.environment.document.querySelectorAll(".aa-Panel--scrollable").forEach((function(e){0!==e.scrollTop&&(e.scrollTop=0)}));e({state:n})},function(){s.current=void 0}})),n((function(){var e=Ce((function(){var e=v.value;v.value=p.value.core.environment.matchMedia(p.value.renderer.detachedMediaQuery).matches,e!==v.value?_({}):requestAnimationFrame(w)}),20);return p.value.core.environment.addEventListener("resize",e),function(){p.value.core.environment.removeEventListener("resize",e)}})),n((function(){if(!v.value)return function(){};function e(e){O.value.detachedContainer.classList.toggle("aa-DetachedContainer--modal",e)}function t(t){e(t.matches)}var n=p.value.core.environment.matchMedia(getComputedStyle(p.value.core.environment.document.documentElement).getPropertyValue("--aa-detached-modal-media-query"));e(n.matches);var r=Boolean(n.addEventListener);return r?n.addEventListener("change",t):n.addListener(t),function(){r?n.removeEventListener("change",t):n.removeListener(t)}})),n((function(){return requestAnimationFrame(w),function(){}})),Nn(Nn({},b),{},{update:_,destroy:function(){r()}})}function zn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function qn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?zn(Object(n),!0).forEach((function(t){Bn(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Bn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Un=["params"];function Vn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Hn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Vn(Object(n),!0).forEach((function(t){Wn(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Vn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Wn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $n(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function Kn(e){return function(e){if(Array.isArray(e))return Gn(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return Gn(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Gn(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Gn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Yn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Jn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yn(Object(n),!0).forEach((function(t){Qn(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Qn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Zn=function(e,t){function n(t){return e({searchClient:t.searchClient,queries:t.requests.map((function(e){return e.query}))}).then((function(e){return e.map((function(e,n){var r=t.requests[n];return{items:e,sourceId:r.sourceId,transformResponse:r.transformResponse}}))}))}return function(e){return function(r){return qn(qn({requesterId:t,execute:n},e),r)}}}((function(e){return function(e){var t=e.searchClient,n=e.queries,r=e.userAgents,o=void 0===r?[]:r;return"function"===typeof t.addAlgoliaAgent&&[].concat(Kn(ve),Kn(o)).forEach((function(e){var n=e.segment,r=e.version;t.addAlgoliaAgent(n,r)})),t.search(n.map((function(e){var t=e.params;return Hn(Hn({},$n(e,Un)),{},{params:Hn({hitsPerPage:5,highlightPreTag:Ft,highlightPostTag:Lt},t)})}))).then((function(e){return e.results}))}(Jn(Jn({},e),{},{userAgents:wn}))}),"algolia");function Xn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function er(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Xn(Object(n),!0).forEach((function(t){tr(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function tr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nr(e){var t=Zn({transformResponse:function(e){return e.facetHits}}),n=e.queries.map((function(e){return er(er({},e),{},{type:"facet"})}));return t(er(er({},e),{},{queries:n}))}var rr=Zn({transformResponse:function(e){return e.hits}})},93979:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=j;var r,o=v(n(24974)),i=v(n(49284)),a=v(n(99)),u=v(n(43685)),l=v(n(96534)),c=v(n(88029)),s=v(n(74364)),f=n(215),p=n(37574),d=["title","did","description","cover","version","button","buttonText","buttonDisabled","buttonLoading","onButtonClick","onMainClick","className"];function v(e){return e&&e.__esModule?e:{default:e}}function h(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function y(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?h(Object(n),!0).forEach((function(t){m(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):h(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function b(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var g,O,w=(0,f.styled)("div")(r||(g=["\n &.arcblock-blocklet {\n padding: "," "," 0\n ",";\n }\n .arcblock-blocklet__content {\n cursor: pointer;\n display: flex;\n "," {\n align-items: center;\n }\n }\n .arcblock-blocklet__cover {\n width: 64px;\n height: 64px;\n margin-right: ",";\n overflow: hidden;\n border-radius: 12px;\n /* see: https://stackoverflow.com/questions/49066011/overflow-hidden-with-border-radius-not-working-on-safari */\n transform: translateZ(0);\n "," {\n width: 80px;\n height: 80px;\n margin-bottom: 12px;\n }\n }\n .arcblock-blocklet__button--hover {\n &:not(.Mui-disabled) {\n position: relative;\n z-index: 1;\n &::before {\n content: '';\n position: absolute;\n height: 100%;\n width: 100%;\n left: 0;\n top: 0;\n transition: opacity 0.3s;\n }\n &:hover::before {\n opacity: 0;\n }\n &::after {\n content: '';\n position: absolute;\n height: 100%;\n width: 100%;\n background-color: ",";\n transform: scale(0.1);\n opacity: 0;\n z-index: -1;\n transition: transform 0.3s, opacity 0.3s, background-color 0.3s;\n }\n &:hover::after {\n opacity: 1;\n transform-origin: center;\n transform: scale(1);\n }\n }\n\n &:not(.Mui-disabled) {\n background-color: transparent !important;\n color: ",";\n }\n &:not(.Mui-disabled) {\n &:hover {\n color: ",";\n }\n }\n }\n .arcblock-blocklet__info {\n flex: 1;\n overflow: hidden;\n border-bottom: 1px solid ",";\n padding-bottom: ",";\n }\n .arcblock-blocklet__text {\n height: 57px;\n overflow: hidden;\n }\n /* \u8bbe\u7f6e\u591a\u884c\u6587\u672c\u6ea2\u51fa\u663e\u793a\u7701\u7565\u53f7 \u517c\u5bb9fireFox\u3001safari */\n .arcblock-blocklet__title {\n margin: 0;\n font-size: 16px;\n font-weight: 500;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .arcblock-blocklet__describe {\n margin-top: ",";\n color: ",";\n font-size: 14px;\n font-weight: 500;\n line-height: 17px;\n max-height: 34px;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n word-break: break-word;\n }\n .arcblock-blocklet__version {\n color: ",";\n font-size: 12px;\n }\n"],O||(O=g.slice(0)),r=Object.freeze(Object.defineProperties(g,{raw:{value:Object.freeze(O)}}))),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.breakpoints.up("sm")}),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.breakpoints.up("sm")}),(function(e){return e.theme.palette.primary.main}),(function(e){return e.theme.palette.primary.main}),(function(e){return e.theme.palette.common.white}),(function(e){return e.theme.palette.divider}),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.spacing(.5)}),(function(e){return e.theme.palette.grey[600]}),(function(e){return e.theme.palette.grey[600]}));function j(e){var t=e.title,n=e.did,r=e.description,o=e.cover,v=e.version,h=e.button,m=e.buttonText,g=e.buttonDisabled,O=e.buttonLoading,j=e.onButtonClick,_=e.onMainClick,P=e.className,S=b(e,d),x=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){return!1};return function(n){if(t())n.preventDefault(),n.stopPropagation();else if(e instanceof Function){n.preventDefault(),n.stopPropagation();for(var r=arguments.length,o=new Array(r>1?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];e.apply(void 0,o)}}},k=x(j,(function(){return!!(h||g||O)})),E=(0,f.useTheme)(),I=(0,l.default)(E.breakpoints.up("sm")),C=x(_),M=I?80:64;return(0,p.jsx)(w,y(y({className:"".concat(P," arcblock-blocklet")},S),{},{children:(0,p.jsxs)("div",{className:"arcblock-blocklet__content",onClick:C,children:[o?(0,p.jsx)("div",{className:"arcblock-blocklet__cover",children:(0,p.jsx)(s.default,{src:o})}):n&&(0,p.jsx)("div",{className:"arcblock-blocklet__cover",children:(0,p.jsx)(u.default,{did:n,size:M})}),(0,p.jsxs)("div",{className:"arcblock-blocklet__info",children:[(0,p.jsxs)("div",{className:"arcblock-blocklet__text",children:[(0,p.jsx)(i.default,{component:"h3",variant:"h3",className:"arcblock-blocklet__title",title:t,children:t}),r&&(0,p.jsx)(i.default,{component:"div",variant:"body2",className:"arcblock-blocklet__describe",title:r,children:r})]}),(0,p.jsxs)("div",{style:{display:"flex",alignItems:"center",marginTop:"10px",flexFlow:"wrap"},children:[(0,p.jsx)("div",{onClick:k,style:{marginRight:"12px"},children:h||j&&(0,p.jsxs)(c.default,{className:"arcblock-blocklet__button--hover",variant:"outlined",color:"primary",size:"small",disabled:g||O,style:{padding:"3px 6px",fontSize:"14px",minWidth:"92px",textAlign:"center"},children:[O&&(0,p.jsx)(a.default,{size:15,style:{marginRight:3,color:"inherit"}}),m]})}),(0,p.jsx)("div",{className:"arcblock-blocklet__version",children:v&&"v".concat(v)})]})]})]})}))}j.propTypes={title:o.default.string.isRequired,did:o.default.string,description:o.default.string,cover:o.default.string,buttonText:o.default.string,buttonDisabled:o.default.bool,buttonLoading:o.default.bool,button:o.default.element,version:o.default.string,onButtonClick:o.default.func,onMainClick:o.default.func,className:o.default.string},j.defaultProps={description:null,cover:null,did:null,buttonText:"Install",buttonDisabled:!1,buttonLoading:!1,button:null,version:null,onButtonClick:null,onMainClick:null,className:null}},32371:function(e,t,n){"use strict";Object.defineProperty(t,"Kk",{enumerable:!0,get:function(){return r.default}}),t.ZP=void 0;var r=o(n(48578));function o(e){return e&&e.__esModule?e:{default:e}}var i=o(n(93979)).default;t.ZP=i},48578:function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o,i,a=(0,n(215).styled)("div")(r||(o=["\n background-color: transparent !important;\n & > :not(.Mui-disabled) {\n position: relative;\n z-index: 1;\n &::before {\n content: '';\n position: absolute;\n height: 100%;\n width: 100%;\n left: 0;\n top: 0;\n transition: opacity 0.3s;\n }\n &:hover::before {\n opacity: 0;\n }\n &::after {\n content: '';\n position: absolute;\n height: 100%;\n width: 100%;\n top: 0;\n left: 0;\n border-radius: 2px;\n background-color: ",";\n transform: scale(0.1);\n opacity: 0;\n z-index: -1;\n transition: transform 0.3s, opacity 0.3s, background-color 0.3s;\n }\n &:hover::after {\n opacity: 1;\n transform-origin: center;\n transform: scale(1);\n }\n }\n & > :not(.Mui-disabled) {\n background-color: transparent !important;\n color: ","!important;\n }\n & > :not(.Mui-disabled) {\n &:hover {\n color: ","!important;\n }\n }\n"],i||(i=o.slice(0)),r=Object.freeze(Object.defineProperties(o,{raw:{value:Object.freeze(i)}}))),(function(e){return e.theme.palette.primary.main}),(function(e){return e.theme.palette.primary.main}),(function(e){return e.theme.palette.common.white}));t.default=a},79476:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=n(2717),o={en:r({common:{searchStore:"Search the store",price:"Price",category:"Category"},sort:{sort:"Sort",nameDescend:"Name Descending",nameAscend:"Name Ascending",popularity:"Most Popular",lastPublished:"Latest Published"},category:{all:"All",placeholder:"Category name",helperText:"Please select a category"},blocklet:{noResults:"No Blocklets",payment:"Paid Blocklets",free:"Fee Blocklets",emptyTip:"Tips:",filterTip:"Appropriately reduce the filter conditions",keywordTip:"Try other keywords",owner:"Blocklets from {name}",noBlockletPart1:'No Blocklets associated with"',noBlockletPart2:'"were found',noCategoryResults1:'No "',noCategoryResults2:'" Blocklets'}}),zh:r({common:{searchStore:"\u641c\u7d22\u5546\u5e97\u5185\u5e94\u7528",price:"\u4ef7\u683c",category:"\u7c7b\u522b"},sort:{sort:"\u6392\u5e8f",nameDescend:"\u540d\u79f0\u964d\u5e8f",nameAscend:"\u540d\u79f0\u5347\u5e8f",popularity:"\u6700\u70ed\u95e8",lastPublished:"\u6700\u65b0\u53d1\u5e03"},category:{all:"\u5168\u90e8",placeholder:"\u5206\u7c7b\u540d\u79f0",helperText:"\u8bf7\u9009\u62e9\u5206\u7c7b"},blocklet:{noResults:"\u6682\u65e0\u5e94\u7528",free:"\u514d\u8d39\u5e94\u7528",payment:"\u4ed8\u8d39\u5e94\u7528",emptyTip:"\u5efa\u8bae:",filterTip:"\u9002\u5f53\u51cf\u5c11\u7b5b\u9009\u6761\u4ef6",keywordTip:"\u5c1d\u8bd5\u5176\u4ed6\u5173\u952e\u5b57",owner:"\u6765\u81ea {name} \u7684 Blocklets",noBlockletPart1:'\u6ca1\u6709\u627e\u5230\u4e0e"',noBlockletPart2:'"\u76f8\u5173\u7684 Blocklets',noCategoryResults1:'\u65e0 "',noCategoryResults2:'" \u7c7b\u522b\u7684 Blocklets'}})};t.default=o},63915:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o,i=g(n(16380)),a=g(n(79769)),u=n(11851),l=g(n(91118)),c=n(51921),s=n(2834),f=n(8366),p=g(n(40207)),d=n(81089),v=n(18967),h=g(n(96373)),y=g(n(21328)),m=g(n(72071)),b=n(37574);function g(e){return e&&e.__esModule?e:{default:e}}function O(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var w=i.default.main(r||(r=O(["\n display: flex;\n flex-direction: column;\n flex: 1;\n width: 100%;\n height: 100%;\n .filter-bar {\n justify-content: space-between;\n margin-bottom: ",";\n }\n .sort-button {\n white-space: nowrap;\n }\n .bl-search-container {\n flex: 2;\n margin-left: 0px;\n }\n\n .filter-container {\n flex: 1;\n display: flex;\n justify-content: flex-end;\n }\n @media (max-width: ","px) {\n .bl-search-container {\n width: 100%;\n margin-bottom: ",";\n }\n .filter-container {\n margin-left: 0;\n display: flex;\n justify-content: flex-start;\n }\n .filter-bar {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n }\n }\n @media (max-width: ","px) {\n .sort-button {\n font-size: 12px;\n }\n }\n"])),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.breakpoints.values.md}),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.breakpoints.values.md})),j=i.default.div(o||(o=O(["\n position: sticky;\n top: 0;\n z-index: 9;\n background-color: white;\n"]))),_=function(){var e,t,n=(0,f.useFilterContext)(),r=n.handleDeveloper,o=n.blockletList,i=n.filters,g=n.developerName,O=n.handleSort,_=n.handleCategory,P=n.handlePrice,S=n.handleSearchSelect,x=n.t,k=n.getCategoryLocale,E=n.priceOptions,I=(0,v.getSortOptions)(x),C=(null===(e=I.find((function(e){return e.value===i.sortBy})))||void 0===e?void 0:e.name)||x("sort.sort"),M=k(i.category),D=null===(t=E.find((function(e){return e.value===i.price})))||void 0===t?void 0:t.name;return(0,b.jsxs)(u.Box,{display:"flex",alignItems:"flex-start",height:"100%",children:[(0,b.jsx)(u.Hidden,{mdDown:!0,children:(0,b.jsx)(y.default,{})}),(0,b.jsxs)(w,{children:[(0,b.jsxs)(j,{children:[(0,b.jsxs)(u.Box,{className:"filter-bar",display:"flex",alignItems:"center",children:[(0,b.jsx)(m.default,{onSelect:S}),(0,b.jsxs)(u.Box,{mt:0,ml:"16px",className:"filter-container",children:[(0,b.jsx)(u.Hidden,{mdUp:!0,children:(0,b.jsx)(d.FilterIcon,{})}),(0,b.jsx)(p.default,{value:i.sortBy,options:I,title:C,icon:(0,b.jsx)(a.default,{}),onChange:function(e){O(e)}})]})]}),(0,b.jsxs)(u.Box,{display:"flex",flexWrap:"wrap",alignItems:"center",mb:"16px",children:[(0,b.jsx)(d.CustomChip,{label:g,icon:(0,b.jsx)(l.default,{}),onDelete:function(){r(null)}}),(0,b.jsx)(d.CustomChip,{label:M,onDelete:function(){_(null)}}),(0,b.jsx)(d.CustomChip,{label:D,onDelete:function(){P(null)}})]})]}),(0,b.jsx)(c.ErrorBoundary,{FallbackComponent:s.ErrorFallback,children:(0,b.jsx)("div",{style:{position:"relative",flex:1,overflow:"auto"},children:(0,b.jsx)(h.default,{blocklets:o})})})]})]})};t.default=_},21328:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o,i=(r=n(16380))&&r.__esModule?r:{default:r},a=n(8366),u=n(81089),l=n(37574);function c(){var e=(0,a.useFilterContext)(),t=e.selectedCategory,n=e.handleCategory,r=e.t,o=e.handlePrice,i=e.filters,c=e.categoryOptions,s=e.priceOptions;return(0,l.jsxs)(p,{children:[(0,l.jsx)("div",{children:(0,l.jsx)(u.FilterGroup,{title:r("common.price"),options:s,value:i.price,onChange:o})}),c.length>0&&(0,l.jsx)("div",{style:{marginTop:"16px"},children:(0,l.jsx)(u.FilterGroup,{title:r("common.category"),options:c,value:t,onChange:n})})]})}var s,f,p=i.default.aside(o||(s=["\n width: 220px;\n margin-right: ",";\n height: 100%;\n position: sticky;\n top: 0;\n overflow-y: auto;\n z-index: auto;\n"],f||(f=s.slice(0)),o=Object.freeze(Object.defineProperties(s,{raw:{value:Object.freeze(f)}}))),(function(e){return e.theme.spacing(2)}));c.propTypes={},c.defaultProps={};var d=c;t.default=d},72071:function(e,t,n){"use strict";var r=n(27609).default,o=n(91461).default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=w;var i=n(30969),a=m(n(24974)),u=n(71879),l=n(53989),c=n(54470),s=n(61699),f=m(n(19611)),p=m(n(4282)),d=n(18967),v=n(8366),h=m(n(54898)),y=n(37574);function m(e){return e&&e.__esModule?e:{default:e}}function b(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?b(Object(n),!0).forEach((function(t){O(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):b(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function O(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function w(e){var t=e.onSelect,n=(0,i.useRef)(null),a=(0,i.useRef)(null),m=(0,i.useRef)(null),b=(0,v.useFilterContext)(),O=b.storeApi,w=b.filters,j=b.endpoint,_=b.handleKeyword,P=b.t,S=(0,s.useTheme)(),x=(0,i.useCallback)(function(){var e=o(r().mark((function e(t){var n,o;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,O.get(p.default.blockletsPath,{params:t});case 2:return n=e.sent,o=n.data,e.abrupt("return",o.dataList||[]);case 5:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),[O]),k=(0,i.useCallback)((function(e){_(e.state.query)}),[_]),E=(0,i.useCallback)((function(){_()}),[_]);return(0,i.useEffect)((function(){if(n.current){var e=(0,l.autocomplete)({container:n.current,renderer:{createElement:i.createElement,Fragment:i.Fragment,render:function(){}},render:function(e,t){var n,r=e.children;a.current&&m.current===t||(m.current=t,null===(n=a.current)||void 0===n||n.unmount(),a.current=(0,u.createRoot)(t));a.current.render(r)},classNames:{panel:"bl-autocomplete-panel",label:"bl-autocomplete-label",form:"bl-autocomplete-form",input:"bl-autocomplete-input",clearButton:"bl-autocomplete-clear"},placeholder:P("common.searchStore"),initialState:{query:w.keyword},onSubmit:k,onReset:E,getSources:function(e){var n=e.query,r=g(g({},w),{},{sortBy:p.default[w.sortBy],page:1,pageSize:10,keyword:n});return(0,d.debounced)([{sourceId:"blocklets",getItems:function(){return x(r)},getItemInputValue:function(e){return e.item.title},onSelect:function(e){var n=e.item;t({blocklet:n,detailUrl:(0,f.default)(j,"/blocklets/".concat(n.did)),storeUrl:j})},templates:{item:function(e){var t=e.item,n=t.logo?(0,f.default)(j,"assets",t.did,t.logo):null;return(0,y.jsx)(s.ThemeProvider,{theme:S,children:(0,y.jsx)(c.ThemeProvider,{theme:S,children:(0,y.jsx)(h.default,{item:t,title:(null===t||void 0===t?void 0:t.title)||(null===t||void 0===t?void 0:t.name),did:t.did,description:t.description,cover:n})})})},noResults:function(){return P("blocklet.noResults")}}}])}});return function(){e.destroy()}}}),[j,w,x,S,E,k,t,P]),(0,y.jsx)("div",{className:"bl-search-container",ref:n})}w.propTypes={onSelect:a.default.func.isRequired}},54898:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=g;var r,o=f(n(16380)),i=f(n(24974)),a=f(n(49284)),u=f(n(74364)),l=f(n(43685)),c=n(37574),s=["cover","item","className"];function f(e){return e&&e.__esModule?e:{default:e}}function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function d(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){v(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function v(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function h(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var y,m,b=o.default.div(r||(y=["\n &.arcblock-blocklet {\n padding: "," "," 0\n ",";\n }\n .arcblock-blocklet__content {\n cursor: pointer;\n display: flex;\n }\n .arcblock-blocklet__cover {\n width: 64px;\n height: 64px;\n margin-right: ",";\n overflow: hidden;\n border-radius: 12px;\n transform: translateZ(0);\n }\n\n .arcblock-blocklet__info {\n flex: 1;\n overflow: hidden;\n border-bottom: 1px solid ",";\n padding-bottom: ",";\n }\n .arcblock-blocklet__text {\n height: 57px;\n overflow: hidden;\n }\n /* \u8bbe\u7f6e\u591a\u884c\u6587\u672c\u6ea2\u51fa\u663e\u793a\u7701\u7565\u53f7 \u517c\u5bb9fireFox\u3001safari */\n .arcblock-blocklet__title {\n margin: 0;\n font-size: 16px;\n font-weight: 500;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .arcblock-blocklet__describe {\n margin-top: ",";\n color: ",";\n font-size: 14px;\n font-weight: 500;\n line-height: 17px;\n max-height: 34px;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n word-break: break-word;\n }\n .ms-highlight {\n background-color: yellow;\n }\n"],m||(m=y.slice(0)),r=Object.freeze(Object.defineProperties(y,{raw:{value:Object.freeze(m)}}))),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.palette.divider}),(function(e){return e.theme.spacing(2)}),(function(e){return e.theme.spacing(.5)}),(function(e){return e.theme.palette.grey[600]}));function g(e){var t=e.cover,n=e.item,r=e.className,o=h(e,s),i=n.did,f=n.description,p=n.title,v=n.name;return(0,c.jsx)(b,d(d({className:"".concat(r," arcblock-blocklet")},o),{},{children:(0,c.jsxs)("div",{className:"arcblock-blocklet__content",children:[t?(0,c.jsx)("div",{className:"arcblock-blocklet__cover",children:(0,c.jsx)(u.default,{src:t})}):i&&(0,c.jsx)("div",{className:"arcblock-blocklet__cover",children:(0,c.jsx)(l.default,{did:i,size:64})}),(0,c.jsx)("div",{className:"arcblock-blocklet__info",children:(0,c.jsxs)("div",{className:"arcblock-blocklet__text",children:[(0,c.jsx)(a.default,{component:"h3",variant:"h3",className:"arcblock-blocklet__title",title:p,children:(0,c.jsx)(O,{item:n,attribute:"title",value:p||v})}),f&&(0,c.jsx)(a.default,{component:"div",variant:"body2",className:"arcblock-blocklet__describe",title:f,children:(0,c.jsx)(O,{item:n,attribute:"description",value:f})})]})})]})}))}function O(e){var t=e.item,n=e.attribute,r=e.value;return t._formatted?(0,c.jsx)("span",{"data-cy":"bl-autocomplete-item",dangerouslySetInnerHTML:{__html:t._formatted[n]}}):r}g.propTypes={cover:i.default.string,className:i.default.string,item:i.default.object.isRequired},g.defaultProps={cover:null,className:null},O.propTypes={item:i.default.object.isRequired,attribute:i.default.string.isRequired,value:i.default.string.isRequired}},23649:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o=n(30969),i=s(n(24974)),a=n(11851),u=s(n(16380)),l=n(37574),c=["children","rounded","loading","disabled"];function s(e){return e&&e.__esModule?e:{default:e}}function f(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?f(Object(n),!0).forEach((function(t){d(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):f(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function d(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function v(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var h,y,m=(0,u.default)(a.Button)(r||(h=["\n border-radius: 4px;\n"],y||(y=h.slice(0)),r=Object.freeze(Object.defineProperties(h,{raw:{value:Object.freeze(y)}})))),b=(0,o.forwardRef)((function(e,t){var n=e.children,r=(e.rounded,e.loading),o=e.disabled,i=v(e,c);return(0,l.jsx)(m,p(p({ref:t,disableElevation:!0,disabled:o||r},i),{},{startIcon:r&&(0,l.jsx)(a.CircularProgress,{size:"1em"}),children:n}))}));b.propTypes={children:i.default.any,rounded:i.default.bool,loading:i.default.bool,disabled:i.default.bool},b.defaultProps={children:null,rounded:!1,loading:!1,disabled:!1};var g=b;t.default=g},68463:function(e,t,n){"use strict";var r=n(43681).default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o,i,a=n(30969),u=n(61699),l=y(n(16380)),c=y(n(24974)),s=n(11851),f=y(n(96979)),p=y(n(76032)),d=y(n(23649)),v=n(37574),h=["title","value","icon","prepend","options","onChange","itemRender"];function y(e){return e&&e.__esModule?e:{default:e}}function m(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}function b(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?b(Object(n),!0).forEach((function(t){O(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):b(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function O(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function w(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function j(e){var t=e.title,n=e.value,o=e.icon,i=e.prepend,l=e.options,c=e.onChange,d=e.itemRender,y=w(e,h),m=(0,a.useRef)(null),b=(0,u.useTheme)(),O=(0,a.useState)(!1),j=r(O,2),S=j[0],x=j[1],k=(0,a.useState)(null!==n?n:""),E=r(k,2),I=E[0],C=E[1],M=(0,s.useMediaQuery)(b.breakpoints.down("sm"));(0,a.useEffect)((function(){C(null!==n?n:"")}),[n]);var D=(0,a.useCallback)((function(){x(!1)}),[]),T=(0,a.useCallback)((function(){x(!0)}),[]);return(0,v.jsxs)(v.Fragment,{children:[(0,v.jsxs)(_,g(g({ref:m,onClick:T,variant:"outlined",size:"small",className:["my-select__selector",(0,p.default)(I)?"":"my-select__selector--active"].join(" ")},y),{},{children:[(0,v.jsx)("div",{className:"my-select__icon",children:o}),t,(0,v.jsx)(s.SvgIcon,{className:"my-select__arrowdown",component:f.default,fontSize:"small"})]})),(0,v.jsx)(s.Popper,{open:S,anchorEl:m.current,transition:!0,style:{zIndex:"9999"},children:function(e){var t=e.TransitionProps,n=e.placement;return(0,v.jsx)(s.Grow,g(g({},t),{},{style:{transformOrigin:"bottom"===n?"center top":"center bottom"},children:(0,v.jsx)(s.Paper,{children:(0,v.jsx)(s.ClickAwayListener,{onClickAway:D,children:(0,v.jsxs)(P,{autoFocusItem:S,onMouseEnter:T,onMouseLeave:D,children:[i,l.map((function(e){return d?d(e):(0,v.jsx)(s.MenuItem,{onClick:function(){return function(e){C(e.value),c(e.value),M&&D()}(e)},className:["my-select__option",(t=e.value,t===I?"my-select__option--active":"")].join(" "),children:e.name},e.value);var t}))]})})})}))}})]})}j.propTypes={options:c.default.array.isRequired,value:c.default.oneOfType([c.default.string,c.default.number,c.default.array]),onChange:c.default.func,itemRender:c.default.func,title:c.default.string.isRequired,icon:c.default.any,prepend:c.default.any},j.defaultProps={value:null,icon:null,prepend:null,itemRender:null,onChange:function(){}};var _=(0,l.default)(d.default)(o||(o=m(["\n border: 1px solid #f0f0f0;\n padding: 6px 8px 6px 12px;\n font-weight: ",";\n font-size: 16px;\n color: #666;\n line-height: 1;\n text-transform: none;\n min-width: 100px;\n & + & {\n margin-left: 10px;\n }\n &.my-select__selector--active {\n &,\n .my-select__arrowdown,\n .my-select__icon svg {\n color: ",";\n }\n }\n .my-select__arrowdown {\n color: #999;\n font-size: 16px;\n margin-left: 6px;\n }\n .my-select__icon {\n font-size: 0;\n svg {\n color: #999;\n font-size: 18px;\n margin-right: 3px;\n }\n }\n"])),(function(e){return e.theme.typography.fontWeightBold}),(function(e){return e.theme.palette.primary.main})),P=(0,l.default)(s.MenuList)(i||(i=m(["\n .my-select__option__icon {\n color: transparent;\n font-size: 16px;\n margin: 0 3px 0 -5px;\n }\n .my-select__option {\n font-size: 16px;\n color: #999;\n }\n .my-select__option--active {\n &,\n .my-select__option__icon {\n color: ",";\n }\n }\n"])),(function(e){return e.theme.palette.primary.main})),S=j;t.default=S},40207:function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=((r=n(68463))&&r.__esModule?r:{default:r}).default;t.default=o},21294:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o=c(n(24974)),i=c(n(16380)),a=n(11851),u=n(37574),l=["label","icon","onDelete"];function c(e){return e&&e.__esModule?e:{default:e}}function s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?s(Object(n),!0).forEach((function(t){p(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function p(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var v,h,y=i.default.div(r||(v=["\n .MuiChip-root {\n border-radius: 4px;\n height: initial;\n text-transform: capitalize;\n margin-right: ",";\n padding: 4px 0;\n }\n"],h||(h=v.slice(0)),r=Object.freeze(Object.defineProperties(v,{raw:{value:Object.freeze(h)}}))),(function(e){return e.theme.spacing(2)}));function m(e){var t=e.label,n=e.icon,r=e.onDelete,o=d(e,l);return t?(0,u.jsx)(y,f(f({},o),{},{children:(0,u.jsx)(a.Chip,{color:"primary","data-cy":"filter-tag",icon:n,label:t,onDelete:r})})):null}m.propTypes={label:o.default.string,onDelete:o.default.func,icon:o.default.element},m.defaultProps={onDelete:function(){},icon:null,label:null};var b=m;t.default=b},34377:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o=u(n(24974)),i=u(n(16380)),a=n(37574);function u(e){return e&&e.__esModule?e:{default:e}}function l(e){var t=e.options,n=e.onChange,r=e.title,o=e.value;return(0,a.jsxs)(f,{children:[(0,a.jsx)("div",{className:"title",children:r}),(0,a.jsx)("div",{className:"list",children:t.map((function(e){return(0,a.jsx)("div",{title:e.name,"data-cy":"filter",className:o===e.value?"select item":"item",onClick:function(){return n(e.value)},children:e.name},e.value)}))})]})}var c,s,f=i.default.div(r||(c=["\n .title {\n font-size: 18px;\n font-weight: bold;\n margin-bottom: ",";\n }\n .list {\n }\n .item {\n font-size: 16px;\n padding: ",";\n color: #9397a1;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n text-transform: capitalize;\n cursor: pointer;\n &:hover {\n background-color: ",";\n color: initial;\n font-weight: bold;\n }\n }\n .select {\n color: ",";\n font-weight: bold;\n }\n"],s||(s=c.slice(0)),r=Object.freeze(Object.defineProperties(c,{raw:{value:Object.freeze(s)}}))),(function(e){return e.theme.spacing(1)}),(function(e){return e.theme.spacing(1)}),(function(e){return e.theme.palette.grey[50]}),(function(e){return e.theme.palette.primary.main}));l.propTypes={title:o.default.string.isRequired,options:o.default.array.isRequired,onChange:o.default.func.isRequired,value:o.default.oneOfType([o.default.string,o.default.number])},l.defaultProps={value:null};var p=l;t.default=p},59774:function(e,t,n){"use strict";var r=n(43681).default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o,i=n(30969),a=d(n(16380)),u=d(n(88544)),l=d(n(62068)),c=d(n(84916)),s=n(8366),f=d(n(34377)),p=n(37574);function d(e){return e&&e.__esModule?e:{default:e}}function v(){var e=(0,s.useFilterContext)(),t=e.selectedCategory,n=e.handleCategory,o=e.t,a=e.handlePrice,d=e.filters,v=e.categoryOptions,h=e.priceOptions,y=(0,i.useState)(!1),b=r(y,2),g=b[0],O=b[1],w=function(e,t){"category"===e&&n(t),"price"===e&&a(t),O(!1)};return(0,p.jsxs)(m,{children:[(0,p.jsx)(c.default,{variant:"outlined",className:"filter-button",onClick:function(){return O(!0)},children:(0,p.jsx)(u.default,{className:"filter-icon",fontSize:"small"})}),(0,p.jsxs)(l.default,{fullWidth:!0,title:"",open:g,onClose:function(){return O(!1)},children:[(0,p.jsx)(f.default,{title:o("common.price"),options:h,value:d.price,onChange:function(e){w("price",e)}}),v.length>0&&(0,p.jsx)("div",{style:{marginTop:"16px"},children:(0,p.jsx)(f.default,{title:o("common.category"),options:v,value:t,onChange:function(e){w("category",e)}})})]})]})}var h,y,m=a.default.div(o||(h=["\n .filter-button {\n margin-right: 16px;\n border-color: rgb(240, 240, 240);\n padding: 5px 8px;\n min-width: initial;\n }\n .filter-icon {\n cursor: pointer;\n color: ",";\n }\n"],y||(y=h.slice(0)),o=Object.freeze(Object.defineProperties(h,{raw:{value:Object.freeze(y)}}))),(function(e){return e.theme.palette.grey[500]}));v.propTypes={},v.defaultProps={};var b=v;t.default=b},81089:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"CustomChip",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"FilterGroup",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"FilterIcon",{enumerable:!0,get:function(){return r.default}});var r=a(n(59774)),o=a(n(21294)),i=a(n(34377));function a(e){return e&&e.__esModule?e:{default:e}}},55680:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EmptyTitle=s,t.NoResults=function(){var e=(0,a.useFilterContext)().t;return(0,u.jsx)(i.default,{style:{textAlign:"center"},variant:"subtitle2",children:e("blocklet.noResults")})},t.NoResultsTips=c;var r=l(n(24974)),o=l(n(92293)),i=l(n(49284)),a=n(8366),u=n(37574);function l(e){return e&&e.__esModule?e:{default:e}}function c(e){var t=e.filterTip,n=e.keywordTip,r=(0,a.useFilterContext)(),i=r.t,l=r.locale;return(0,u.jsxs)(o.default,{className:"tips",children:[(0,u.jsx)("span",{style:{marginRight:"16px"},children:i("blocklet.emptyTip")}),t&&(0,u.jsx)("span",{children:i("blocklet.filterTip")}),t&&n&&("zh"===l?"\u3001":" , "),n&&(0,u.jsx)("span",{children:i("blocklet.keywordTip")})]})}function s(e){var t=e.primaryStart,n=e.primaryEnd,r=e.filter;return(0,u.jsxs)(i.default,{variant:"subtitle2",children:[(0,u.jsx)("span",{children:t}),(0,u.jsxs)("span",{className:"primary",children:[" ",r," "]}),(0,u.jsxs)("span",{children:[n," "]})]})}c.propTypes={filterTip:r.default.bool,keywordTip:r.default.bool},c.defaultProps={filterTip:!1,keywordTip:!1},s.propTypes={primaryStart:r.default.string.isRequired,primaryEnd:r.default.string.isRequired,filter:r.default.string.isRequired}},96373:function(e,t,n){"use strict";var r=n(43681).default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=x;var o,i,a,u=n(30969),l=O(n(24974)),c=O(n(16380)),s=O(n(24972)),f=O(n(92293)),p=O(n(76182)),d=O(n(99)),v=O(n(1615)),h=n(2834),y=n(55680),m=n(8366),b=n(37574),g=["blocklets"];function O(e){return e&&e.__esModule?e:{default:e}}function w(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}function j(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function _(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?j(Object(n),!0).forEach((function(t){P(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):j(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function P(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function S(e,t){if(null==e)return{};var n,r,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}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function x(e){var t=e.blocklets,n=S(e,g),o=(0,m.useFilterContext)(),i=o.blockletRender,a=o.errors,u=o.loadings,l=o.selectedCategory,c=o.getCategoryLocale,s=o.filters,p=o.t,O=o.hasNextPage,w=o.loadMore,j=o.endpoint,P=!!l||!!s.price,x=(0,v.default)({loading:u.fetchBlockletsLoading||u.loadingMore,hasNextPage:O,onLoadMore:w}),C=r(x,1)[0];if(a.fetchBlockletsError)return(0,b.jsx)(h.ErrorFallback,{error:new Error("Failed to fetch blocklets from ".concat(j,": ").concat(a.fetchBlockletsError.message))});if(u.fetchBlockletsLoading)return(0,b.jsx)(f.default,{height:60,display:"flex",alignItems:"center",justifyContent:"center",children:(0,b.jsx)(d.default,{})});if(s.keyword&&P&&0===t.length)return(0,b.jsxs)(I,{children:[(0,b.jsx)(y.EmptyTitle,{primaryStart:p("blocklet.noBlockletPart1"),primaryEnd:p("blocklet.noBlockletPart2"),filter:s.keyword}),(0,b.jsx)(y.NoResultsTips,{keywordTip:!0,filterTip:!0})]});if(s.keyword&&0===t.length)return(0,b.jsxs)(I,{children:[(0,b.jsx)(y.EmptyTitle,{primaryStart:p("blocklet.noBlockletPart1"),primaryEnd:p("blocklet.noBlockletPart2"),filter:s.keyword}),(0,b.jsx)(y.NoResultsTips,{keywordTip:!0})]});if(P&&0===t.length){var M=c(l);return(0,b.jsxs)(I,{children:[M?(0,b.jsx)(y.EmptyTitle,{primaryStart:p("blocklet.noCategoryResults1"),primaryEnd:p("blocklet.noCategoryResults2"),filter:M}):(0,b.jsx)(y.NoResults,{}),(0,b.jsx)(y.NoResultsTips,{filterTip:!0})]})}return 0===t.length?(0,b.jsx)(I,{children:(0,b.jsx)(y.NoResults,{})}):(0,b.jsxs)(k,_(_({container:!0},n),{},{children:[t.map((function(e){return(0,b.jsx)(E,{item:!0,lg:4,md:6,sm:6,xs:12,"data-blocklet-did":e.did,children:i({blocklet:e,blocklets:t})},e.did)})),O&&(0,b.jsx)(E,{item:!0,md:12,sm:12,xs:12,ref:C,children:(0,b.jsx)(f.default,{height:60,display:"flex",justifyContent:"center",children:(0,b.jsx)(d.default,{})})})]}))}x.propTypes={blocklets:l.default.array.isRequired},x.defaultProps={};var k=(0,c.default)(p.default)(o||(o=w(["\n &.MuiGrid-root {\n width: 100%;\n margin: 0 -16px;\n }\n"]))),E=(0,u.memo)((0,c.default)(p.default)(i||(i=w(["\n @media (max-width: ","px) {\n &.MuiGrid-item {\n padding-bottom: 0px;\n }\n }\n @media (min-width: ","px) {\n &.MuiGrid-item {\n margin-bottom: ",";\n }\n }\n"])),(function(e){return e.theme.breakpoints.values.sm}),(function(e){return e.theme.breakpoints.values.sm}),(function(e){return e.theme.spacing(2)}))),I=(0,c.default)(s.default)(a||(a=w(["\n text-align: center;\n .primary {\n color: ",";\n }\n .tips {\n margin-top: ",";\n }\n"])),(function(e){return e.theme.palette.primary.main}),(function(e){return e.theme.spacing(1)}))},8366:function(e,t,n){"use strict";var r=n(27609).default,o=n(91461).default;Object.defineProperty(t,"__esModule",{value:!0}),t.FilterConsumer=void 0,t.FilterProvider=j,t.useFilterContext=function(){var e=(0,i.useContext)(g);if(!e)return{};return e};var i=n(30969),a=h(n(24974)),u=n(33768),l=h(n(3578)),c=h(n(95803)),s=n(18967),f=h(n(79476)),p=n(14142),d=h(n(4282)),v=n(37574);function h(e){return e&&e.__esModule?e:{default:e}}function y(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function m(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?y(Object(n),!0).forEach((function(t){b(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):y(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function b(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var g=(0,i.createContext)({}),O=g.Provider,w=g.Consumer;function j(e){var t=e.filters,n=e.children,a=e.endpoint,p=e.locale,h=e.blockletRender,y=e.onFilterChange,b=e.onSearchSelect,g=e.extraFilter,w=c.default.create({baseURL:a}),j=(0,i.useMemo)((function(){return m({sortBy:"popularity",sortDirection:"desc"},t)}),[t]),_=j.category,P=(0,u.useReactive)({currentPage:d.default.currentPage,pageSize:(0,s.isMobileScreen)()?d.default.mobilePageSize:d.default.pageSize,defaultCurrentPage:d.default.defaultCurrentPage}),S=(0,u.useRequest)(function(){var e=o(r().mark((function e(t){var n,o,i,a,u;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=m(m({},j),{},{sortBy:d.default[j.sortBy],page:(0,s.getCurrentPage)((null===t||void 0===t||null===(n=t.list)||void 0===n?void 0:n.length)||0,P.pageSize),pageSize:P.pageSize}),e.next=3,w.get(d.default.blockletsPath,{params:o});case 3:return i=e.sent,a=i.data,u=void 0===a?{}:a,e.abrupt("return",u);case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),{initialData:{list:[],total:0},loadMore:!0,isNoMore:function(e){return!!e&&e.list.length>=e.total},formatResult:function(e){return{list:null===e||void 0===e?void 0:e.dataList,total:e.total}},refreshDeps:[a,t]}),x=S.data,k=S.error,E=S.loading,I=S.loadMore,C=S.loadingMore,M=(0,u.useRequest)(o(r().mark((function e(){var t,n;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w.get(d.default.categoriesPath);case 2:return t=e.sent,n=t.data,e.abrupt("return",Array.isArray(n)?n:[]);case 5:case"end":return e.stop()}}),e)}))),{initialData:[]}),D=M.data,T=M.error,R=M.loading,A=(0,i.useMemo)((function(){var e=D||[];return(0,l.default)(e,[function(e){return e.name}],["asc"])}),[D]),N=function(e,t){return f.default[p]&&f.default[p][e]?(0,s.replaceTranslate)(f.default[p][e],t):(console.warn("Warning: no ".concat(e," translation of ").concat(p)),e)},F=(0,i.useMemo)((function(){var e=x.list||[];return e=g(e)}),[x,g]),L=(0,i.useMemo)((function(){return(0,s.getCategoryOptions)(A,p)}),[A,p]),z=(0,s.getPrices)(N),q={errors:{fetchBlockletsError:k,fetchCategoriesError:T},loadings:{fetchBlockletsLoading:E,fetchCategoriesLoading:R,loadingMore:C},endpoint:a,blockletList:F,t:N,filters:j,selectedCategory:_,categoryList:A,blockletRender:h,locale:p,categoryOptions:L,priceOptions:z,storeApi:w,hasNextPage:x.list.length<x.total,handleSort:function(e){var t=m(m({},j),{},{sortBy:e,sortDirection:"nameAsc"===e?"asc":"desc"});y(t)},handleKeyword:function(e){var t=m(m({},j),{},{keyword:e||void 0});y(t)},handlePrice:function(e){var t=m(m({},j),{},{price:e===j.price?void 0:e});y(t)},handleCategory:function(e){var t=e;"all"!==e&&e!==j.category||(t=void 0);var n=m(m({},j),{},{category:t});y(n)},handleDeveloper:function(e){var t=m(m({},j),{},{owner:e||void 0});y(t)},handlePage:function(e){var t=m(m({},j),{},{currentPage:e});y(t)},loadMore:function(){setTimeout((function(){I()}),1e3)},getCategoryLocale:function(e){if(!e)return null;var t=null,n=D.find((function(t){return t._id===e}));return n&&(t=n.locales[p]),t},get developerName(){var e,t;return(null===(e=F.find((function(e){var t;return(null===e||void 0===e||null===(t=e.owner)||void 0===t?void 0:t.did)===j.owner})))||void 0===e||null===(t=e.owner)||void 0===t?void 0:t.name)||""},handleSearchSelect:b};return(0,v.jsx)(O,{value:q,children:n})}t.FilterConsumer=w,j.propTypes=m(m({},p.propTypes),{},{children:a.default.any.isRequired}),j.defaultProps=p.defaultProps},69180:function(e,t,n){"use strict";t.Z=h;var r,o=n(54470),i=n(61699),a=(r=n(63915))&&r.__esModule?r:{default:r},u=n(8366),l=n(14142),c=n(18967);n(58089);var s,f=n(37574);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function d(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){v(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function v(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function h(e){var t=(0,i.useTheme)(),n=(0,c.toColorRgb)(t.palette.primary.main),r={autocomplete:function(e){return(0,o.css)(s||(t=["\n :root {\n --aa-detached-media-query: (max-width: ","px) !important;\n --aa-detached-modal-media-query: (min-width: ","px) !important;\n --aa-detached-modal-max-width: ","px !important;\n --aa-selected-color-rgb: ",", ",", "," !important;\n --aa-primary-color-rgb: ",", ",", "," !important;\n --aa-input-background-color-rgb: 250, 250, 250 !important;\n }\n .bl-autocomplete-panel {\n z-index: "," !important;\n }\n .bl-autocomplete-label {\n .aa-SubmitIcon {\n color: "," !important;\n }\n }\n .bl-autocomplete-form {\n border: none !important;\n &:focus-within {\n box-shadow: none !important;\n }\n }\n .aa-DetachedSearchButton {\n border: none !important;\n &:focus-within {\n box-shadow: none !important;\n }\n .aa-SubmitIcon {\n color: "," !important;\n }\n }\n "],r||(r=t.slice(0)),s=Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(r)}}))),e.breakpoints.values.md,e.breakpoints.values.md,e.breakpoints.values.md,n.r,n.g,n.b,n.r,n.g,n.b,e.zIndex.modal+1,e.palette.grey[500],e.palette.grey[500]);var t,r}};return(0,f.jsxs)(u.FilterProvider,d(d({},e),{},{children:[(0,f.jsx)(o.Global,{styles:r.autocomplete}),(0,f.jsx)(a.default,{})]}))}h.propTypes=l.propTypes,h.defaultProps=l.defaultProps},4282:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n={nameAsc:"title",nameDesc:"title",popularity:"stats.downloads",publishAt:"lastPublishedAt",mobilePageSize:10,pageSize:18,defaultCurrentPage:1,blockletsPath:"/api/v2/blocklets.json",categoriesPath:"/api/blocklets/categories",cacheSize:100};t.default=n},14142:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.propTypes=t.defaultProps=void 0;var r,o=(r=n(24974))&&r.__esModule?r:{default:r};var i={filters:o.default.shape({keyword:o.default.string,sortBy:o.default.string,sortDirection:o.default.string,price:o.default.string,category:o.default.string,developer:o.default.string}),extraFilter:o.default.func,endpoint:o.default.string.isRequired,blockletRender:o.default.func.isRequired,onFilterChange:o.default.func,onSearchSelect:o.default.func,locale:o.default.oneOf(["zh","en"])};t.propTypes=i;var a={locale:"zh",filters:{},onFilterChange:function(){},onSearchSelect:function(e){var t=e.detailUrl;window.location.href=t},extraFilter:function(e){return e}};t.defaultProps=a},18967:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.urlStringify=t.toColorRgb=t.replaceTranslate=t.removeUndefined=t.isMobileScreen=t.getStoreDetail=t.getSortOptions=t.getPrices=t.getCurrentPage=t.getCategoryOptions=t.formatLogoPath=t.formatError=t.filterBlockletByPrice=t.debounced=void 0;var r=a(n(19611)),o=a(n(74082)),i=a(n(8218));function a(e){return e&&e.__esModule?e:{default:e}}var u=function(e){return!e.payment||(e.payment.price||[]).map((function(e){return e.value||0})).every((function(e){return 0===e}))};t.getSortOptions=function(e){return[{name:e("sort.popularity"),value:"popularity"},{name:e("sort.lastPublished"),value:"publishAt"},{name:e("sort.nameAscend"),value:"nameAsc"},{name:e("sort.nameDescend"),value:"nameDesc"}]};t.getPrices=function(e){return[{name:e("blocklet.free"),value:"free"},{name:e("blocklet.payment"),value:"payment"}]};t.getCategoryOptions=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"en";return e.map((function(e){return{name:e.locales[t],value:e._id}}))};t.filterBlockletByPrice=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=e;return t?n="free"===t?e.filter((function(e){return u(e)})):e.filter((function(e){return!u(e)})):n};t.formatError=function(e){return Array.isArray(e.errors)?e.errors.map((function(e){return e.message})).join("\n"):e.message};t.getStoreDetail=function(e,t){return(0,r.default)(e,"/blocklets/".concat(t.did))};t.formatLogoPath=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"assets";return t.startsWith(n)?t:"".concat(n,"/").concat(e,"/").concat(t)};t.replaceTranslate=function(e,t){return e.replace(/{(\w*)}/g,(function(e,n){return t.hasOwnProperty(n)?t[n]:""}))};var l=function(e){var t=(0,o.default)(e);return Object.keys(t).forEach((function(e){void 0===t[e]&&delete t[e]})),t};t.removeUndefined=l;t.urlStringify=function(e){if(!e)throw new Error("obj is required in urlStringify ");return new URLSearchParams(l(e)).toString()};t.isMobileScreen=function(){return window.innerWidth<=600};t.getCurrentPage=function(e,t){var n=(e+t)/t;return n>1?n.toFixed():1};t.toColorRgb=function(e){return(0,i.default)(e).rgb().object()};var c=function(e,t){var n;return function(){for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n&&clearTimeout(n),new Promise((function(r){n=setTimeout((function(){return r(e.apply(void 0,o))}),t)}))}}((function(e){return Promise.resolve(e)}),300);t.debounced=c},33768:function(e,t,n){"use strict";n.r(t),n.d(t,{UseRequestProvider:function(){return $},configResponsive:function(){return _e},useAntdTable:function(){return Ct},useBoolean:function(){return Re},useClickAway:function(){return ut},useControllableValue:function(){return Q},useControlledValue:function(){return rr},useCookieState:function(){return vn},useCountDown:function(){return Bn},useCounter:function(){return Qt},useCreation:function(){return Ue},useDebounce:function(){return et},useDebounceEffect:function(){return ln},useDebounceFn:function(){return Ze},useDocumentVisibility:function(){return Le},useDrag:function(){return Ut},useDrop:function(){return Bt},useDynamicList:function(){return ee},useEventEmitter:function(){return re},useEventListener:function(){return Ae},useEventTarget:function(){return tn},useExternal:function(){return Zn},useFavicon:function(){return Nn},useFullscreen:function(){return ft},useFusionTable:function(){return Tt},useHistoryTravel:function(){return an},useHover:function(){return St},useInViewport:function(){return vt},useInterval:function(){return bn},useKeyPress:function(){return _t},useLocalStorageState:function(){return Ee},useLockFn:function(){return Gn},useMap:function(){return zt},useMount:function(){return Vt},useMouse:function(){return ot},useNetwork:function(){return kn},usePersistFn:function(){return ae},usePrevious:function(){return tt},useReactive:function(){return Rn},useRequest:function(){return K},useResponsive:function(){return Pe},useSafeState:function(){return er},useScroll:function(){return at},useSelections:function(){return Be},useSessionStorageState:function(){return Ie},useSet:function(){return Nt},useSetState:function(){return mn},useSize:function(){return de},useTextSelection:function(){return Gt},useThrottle:function(){return Ke},useThrottleEffect:function(){return Ye},useThrottleFn:function(){return We},useTimeout:function(){return En},useTitle:function(){return jn},useToggle:function(){return De},useTrackedEffect:function(){return Yn},useUnmount:function(){return le},useUnmountedRef:function(){return Jn},useUpdate:function(){return Xt},useUpdateEffect:function(){return G},useUpdateLayoutEffect:function(){return Ce},useVirtualList:function(){return he},useWebSocket:function(){return Vn},useWhyDidYouUpdate:function(){return On}});var r=n(30969),o=n(11257),i=n.n(o),a=n(66483),u=n.n(a);function l(){return"undefined"===typeof document||"undefined"===typeof document.visibilityState||"hidden"!==document.visibilityState}var c=new Map,s=function(e){var t=c.get(e);return{data:null===t||void 0===t?void 0:t.data,startTime:null===t||void 0===t?void 0:t.startTime}},f=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},p=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(f(arguments[t]));return e};var d=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},v=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(d(arguments[t]));return e};var h=function(e){var t=(0,r.useRef)((function(){throw new Error("Cannot call an event handler while rendering.")}));t.current=e;var n=(0,r.useCallback)((function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var r=t.current;if(r)return r.apply(void 0,v(e))}),[t]);if("function"===typeof e)return n},y=function(e,t){var n=(0,r.useRef)(!1);(0,r.useEffect)((function(){return function(){n.current=!1}}),[]),(0,r.useEffect)((function(){if(n.current)return e();n.current=!0}),t)},m=[];var b=!1;if("undefined"!==typeof window&&window.addEventListener&&!b){var g=function(){if(l()&&("undefined"===typeof navigator.onLine||navigator.onLine))for(var e=0;e<m.length;e++){(0,m[e])()}};window.addEventListener("visibilitychange",g,!1),window.addEventListener("focus",g,!1),b=!0}var O=function(e){return m.push(e),function(){var t=m.indexOf(e);m.splice(t,1)}},w=[];var j=!1;if("undefined"!==typeof window&&window.addEventListener&&!j){window.addEventListener("visibilitychange",(function(){if(l())for(var e=0;e<w.length;e++){(0,w[e])()}}),!1),j=!0}var _=function(e){return w.push(e),function(){var t=w.indexOf(e);w.splice(t,1)}},P=function(){return P=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},P.apply(this,arguments)},S=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},x=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(S(arguments[t]));return e},k="AHOOKS_USE_REQUEST_DEFAULT_KEY",E=function(){function e(e,t,n,r){this.count=0,this.pollingWhenVisibleFlag=!1,this.pollingTimer=void 0,this.loadingDelayTimer=void 0,this.unsubscribe=[],this.that=this,this.state={loading:!1,params:[],data:void 0,error:void 0,run:this.run.bind(this.that),mutate:this.mutate.bind(this.that),refresh:this.refresh.bind(this.that),cancel:this.cancel.bind(this.that),unmount:this.unmount.bind(this.that)},this.service=e,this.config=t,this.subscribe=n,r&&(this.state=P(P({},this.state),r)),this.debounceRun=this.config.debounceInterval?i()(this._run,this.config.debounceInterval):void 0,this.throttleRun=this.config.throttleInterval?u()(this._run,this.config.throttleInterval):void 0,this.limitRefresh=function(e,t){var n=!1;return function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];n||(n=!0,e.apply(void 0,p(r)),setTimeout((function(){n=!1}),t))}}(this.refresh.bind(this),this.config.focusTimespan),this.config.pollingInterval&&this.unsubscribe.push(_(this.rePolling.bind(this))),this.config.refreshOnWindowFocus&&this.unsubscribe.push(O(this.limitRefresh.bind(this)))}return e.prototype.setState=function(e){void 0===e&&(e={}),this.state=P(P({},this.state),e),this.subscribe(this.state)},e.prototype._run=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];this.pollingTimer&&clearTimeout(this.pollingTimer),this.loadingDelayTimer&&clearTimeout(this.loadingDelayTimer),this.count+=1;var r=this.count;return this.setState({loading:!this.config.loadingDelay,params:t}),this.config.loadingDelay&&(this.loadingDelayTimer=setTimeout((function(){e.setState({loading:!0})}),this.config.loadingDelay)),this.service.apply(this,x(t)).then((function(n){if(r!==e.count)return new Promise((function(){}));e.loadingDelayTimer&&clearTimeout(e.loadingDelayTimer);var o=e.config.formatResult?e.config.formatResult(n):n;return e.setState({data:o,error:void 0,loading:!1}),e.config.onSuccess&&e.config.onSuccess(o,t),o})).catch((function(n){if(r!==e.count)return new Promise((function(){}));if(e.loadingDelayTimer&&clearTimeout(e.loadingDelayTimer),e.setState({data:void 0,error:n,loading:!1}),e.config.onError&&e.config.onError(n,t),e.config.throwOnError)throw n;return console.error(n),Promise.reject("useRequest has caught the exception, if you need to handle the exception yourself, you can set options.throwOnError to true.")})).finally((function(){if(r===e.count&&e.config.pollingInterval){if(!l()&&!e.config.pollingWhenHidden)return void(e.pollingWhenVisibleFlag=!0);e.pollingTimer=setTimeout((function(){e._run.apply(e,x(t))}),e.config.pollingInterval)}}))},e.prototype.run=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return this.debounceRun?(this.debounceRun.apply(this,x(e)),Promise.resolve(null)):this.throttleRun?(this.throttleRun.apply(this,x(e)),Promise.resolve(null)):this._run.apply(this,x(e))},e.prototype.cancel=function(){this.debounceRun&&this.debounceRun.cancel(),this.throttleRun&&this.throttleRun.cancel(),this.loadingDelayTimer&&clearTimeout(this.loadingDelayTimer),this.pollingTimer&&clearTimeout(this.pollingTimer),this.pollingWhenVisibleFlag=!1,this.count+=1,this.setState({loading:!1})},e.prototype.refresh=function(){return this.run.apply(this,x(this.state.params))},e.prototype.rePolling=function(){this.pollingWhenVisibleFlag&&(this.pollingWhenVisibleFlag=!1,this.refresh())},e.prototype.mutate=function(e){"function"===typeof e?this.setState({data:e(this.state.data)||{}}):this.setState({data:e})},e.prototype.unmount=function(){this.cancel(),this.unsubscribe.forEach((function(e){e()}))},e}();var I=function(e,t){var n,o=t||{},i=o.refreshDeps,a=void 0===i?[]:i,u=o.manual,l=void 0!==u&&u,f=o.onSuccess,p=void 0===f?function(){}:f,d=o.onError,v=void 0===d?function(){}:d,m=o.defaultLoading,b=void 0!==m&&m,g=o.loadingDelay,O=o.pollingInterval,w=void 0===O?0:O,j=o.pollingWhenHidden,_=void 0===j||j,I=o.defaultParams,C=void 0===I?[]:I,M=o.refreshOnWindowFocus,D=void 0!==M&&M,T=o.focusTimespan,R=void 0===T?5e3:T,A=o.fetchKey,N=o.cacheKey,F=o.cacheTime,L=void 0===F?3e5:F,z=o.staleTime,q=void 0===z?0:z,B=o.debounceInterval,U=o.throttleInterval,V=o.initialData,H=o.ready,W=void 0===H||H,$=o.throwOnError,K=void 0!==$&&$,G=(0,r.useRef)(k),Y=h(e),J=h(p),Q=h(v),Z=h(A);"formatResult"in o&&(n=o.formatResult);var X={formatResult:h(n),onSuccess:J,onError:Q,loadingDelay:g,pollingInterval:w,pollingWhenHidden:_,refreshOnWindowFocus:!l&&D,focusTimespan:R,debounceInterval:B,throttleInterval:U,throwOnError:K},ee=h((function(e,t){re((function(n){return n[e]=t,P({},n)}))})),te=S((0,r.useState)((function(){var e;if(N){var t=null===(e=s(N))||void 0===e?void 0:e.data;if(t){G.current=t.newstFetchKey;var n={};return Object.keys(t.fetches).forEach((function(e){var r=t.fetches[e],o=new E(Y,X,ee.bind(null,e),{loading:r.loading,params:r.params,data:r.data,error:r.error});n[e]=o.state})),n}}return{}})),2),ne=te[0],re=te[1],oe=(0,r.useRef)(ne);oe.current=ne;var ie=(0,r.useRef)(),ae=(0,r.useCallback)((function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(W){if(Z){var n=Z.apply(void 0,x(e));G.current=void 0===n?k:n}var r=G.current,o=oe.current[r];if(!o){var i=new E(Y,X,ee.bind(null,r),{data:V});o=i.state,re((function(e){return e[r]=o,P({},e)}))}return o.run.apply(o,x(e))}ie.current=e}),[A,ee,W]),ue=(0,r.useRef)(ae);ue.current=ae,y((function(){N&&function(e,t,n){var r=c.get(e);(null===r||void 0===r?void 0:r.timer)&&clearTimeout(r.timer);var o=void 0;t>-1&&(o=setTimeout((function(){c.delete(e)}),t)),c.set(e,{data:n,timer:o,startTime:(new Date).getTime()})}(N,L,{fetches:ne,newstFetchKey:G.current})}),[N,ne]);var le=(0,r.useRef)(!1);y((function(){W&&(!le.current&&ie.current&&ue.current.apply(ue,x(ie.current)),le.current=!0)}),[W]),(0,r.useEffect)((function(){var e;if(!l)if(Object.keys(ne).length>0){var t=N&&(null===(e=s(N))||void 0===e?void 0:e.startTime)||0;-1===q||(new Date).getTime()-t<=q||Object.values(ne).forEach((function(e){e.refresh()}))}else ue.current.apply(ue,x(C))}),[]);var ce=(0,r.useCallback)((function(){Object.values(oe.current).forEach((function(e){e.unmount()})),G.current=k,re({}),oe.current={}}),[re]);y((function(){l||Object.values(oe.current).forEach((function(e){e.refresh()}))}),x(a)),(0,r.useEffect)((function(){return function(){Object.values(oe.current).forEach((function(e){e.unmount()}))}}),[]);var se=(0,r.useCallback)((function(e){return function(){console.warn("You should't call "+e+" when service not executed once.")}}),[]);return P(P({loading:W&&!l||b,data:V,error:void 0,params:[],cancel:se("cancel"),refresh:se("refresh"),mutate:se("mutate")},ne[G.current]||{}),{run:ae,fetches:ne,reset:ce})},C=function(){return C=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},C.apply(this,arguments)},M=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&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n},D=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},T=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(D(arguments[t]));return e};var R=function(e,t){var n=t.refreshDeps,o=void 0===n?[]:n,i=t.ref,a=t.isNoMore,u=t.threshold,l=void 0===u?100:u,c=(t.fetchKey,M(t,["refreshDeps","ref","isNoMore","threshold","fetchKey"])),s=D((0,r.useState)(!1),2),f=s[0],p=s[1];(0,r.useEffect)((function(){t.fetchKey&&console.warn("useRequest loadMore mode don't need fetchKey!")}),[]);var d=I(e,C(C({},c),{fetchKey:function(e){var t;return(null===(t=null===e||void 0===e?void 0:e.list)||void 0===t?void 0:t.length)||0},onSuccess:function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];p(!1),t.onSuccess&&t.onSuccess.apply(t,T(e))}})),v=d.data,h=d.run,m=d.params,b=d.reset,g=d.loading,O=d.fetches,w=(0,r.useCallback)((function(){b();var e=D(m).slice(1);h.apply(void 0,T([void 0],e))}),[h,b,m]),j=(0,r.useRef)(w);j.current=w,y((function(){t.manual||j.current()}),T(o));var _=(0,r.useMemo)((function(){var e=[],t=v;return Object.values(O).forEach((function(n){var r,o;(null===(r=n.data)||void 0===r?void 0:r.list)&&(e=e.concat(null===(o=n.data)||void 0===o?void 0:o.list)),n.loading||(t=n.data)})),C(C({},t),{list:e})}),[O,v]),P=!!a&&(!g&&!f&&a(_)),S=(0,r.useCallback)((function(){if(!P){p(!0);var e=D(m).slice(1);h.apply(void 0,T([_],e))}}),[P,h,_,m]),x=function(){!g&&!f&&i&&i.current&&i.current.scrollHeight-i.current.scrollTop<=i.current.clientHeight+l&&S()},k=(0,r.useRef)(x);return k.current=x,(0,r.useEffect)((function(){if(!i||!i.current)return function(){};var e=function(){return k.current()};return i.current.addEventListener("scroll",e),function(){i&&i.current&&i.current.removeEventListener("scroll",e)}}),[k]),C(C({},d),{data:_,reload:w,loading:g&&0===_.list.length,loadMore:S,loadingMore:f,noMore:P})},A=function(){return A=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},A.apply(this,arguments)},N=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&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n},F=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},L=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(F(arguments[t]));return e};var z=function(e,t){t.paginated;var n=t.defaultPageSize,o=void 0===n?10:n,i=t.refreshDeps,a=void 0===i?[]:i,u=t.fetchKey,l=N(t,["paginated","defaultPageSize","refreshDeps","fetchKey"]);(0,r.useEffect)((function(){u&&console.error("useRequest pagination's fetchKey will not work!")}),[]);var c=I(e,A({defaultParams:[{current:1,pageSize:o}]},l)),s=c.data,f=c.params,p=c.run,d=c.loading,v=N(c,["data","params","run","loading"]),h=f&&f[0]?f[0]:{},m=h.current,b=void 0===m?1:m,g=h.pageSize,O=void 0===g?o:g,w=h.sorter,j=void 0===w?{}:w,_=h.filters,P=void 0===_?{}:_,S=(0,r.useCallback)((function(e){var t=F(f),n=t[0],r=t.slice(1);p.apply(void 0,L([A(A({},n),e)],r))}),[p,f]),x=(null===s||void 0===s?void 0:s.total)||0,k=(0,r.useMemo)((function(){return Math.ceil(x/O)}),[O,x]),E=(0,r.useCallback)((function(e,t){var n=e<=0?1:e,r=t<=0?1:t,o=Math.ceil(x/r);n>o&&(n=Math.max(1,o)),S({current:n,pageSize:r})}),[x,S]),C=(0,r.useCallback)((function(e){E(e,O)}),[E,O]),M=(0,r.useCallback)((function(e){E(b,e)}),[E,b]),D=(0,r.useRef)(C);D.current=C,y((function(){t.manual||D.current(1)}),L(a));var T=(0,r.useCallback)((function(e,t,n){S({current:e.current,pageSize:e.pageSize||o,filters:t,sorter:n})}),[P,j,S]);return A({loading:d,data:s,params:f,run:p,pagination:{current:b,pageSize:O,total:x,totalPage:k,onChange:E,changeCurrent:C,changePageSize:M},tableProps:{dataSource:(null===s||void 0===s?void 0:s.list)||[],loading:d,onChange:T,pagination:{current:b,pageSize:O,total:x}},sorter:j,filters:P},v)},q=r.createContext({});q.displayName="UseRequestConfigContext";var B=q,U=function(){return U=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},U.apply(this,arguments)},V=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&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n},H=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},W=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(H(arguments[t]));return e};var $=B.Provider,K=function(e,t){void 0===t&&(t={});var n=(0,r.useContext)(B),o=U(U({},n),t),i=o.paginated,a=o.loadMore,u=o.requestMethod,l=(0,r.useRef)(i),c=(0,r.useRef)(a);if(l.current!==i)throw Error("You should not modify the paginated of options");if(c.current!==a)throw Error("You should not modify the loadMore of options");l.current=i,c.current=a;var s,f=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return fetch.apply(void 0,W(e)).then((function(e){if(e.ok)return e.json();throw new Error(e.statusText)}))},p=u||f;switch(typeof e){case"string":s=function(){return p(e)};break;case"object":var d=e.url,v=V(e,["url"]);s=function(){return u?u(e):f(d,v)};break;default:s=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new Promise((function(n,r){var o=e.apply(void 0,W(t)),i=o;if(!o.then)switch(typeof o){case"string":i=p(o);break;case"object":var a=o.url,l=V(o,["url"]);i=u?u(o):f(a,l)}i.then(n).catch(r)}))}}return a?R(s,o):i?z(s,o):I(s,o)},G=function(e,t){var n=(0,r.useRef)(!1);(0,r.useEffect)((function(){if(n.current)return e();n.current=!0}),t)},Y=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},J=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Y(arguments[t]));return e};var Q=function(e,t){void 0===e&&(e={}),void 0===t&&(t={});var n=t.defaultValue,o=t.defaultValuePropName,i=void 0===o?"defaultValue":o,a=t.valuePropName,u=void 0===a?"value":a,l=t.trigger,c=void 0===l?"onChange":l,s=e[u],f=Y((0,r.useState)((function(){return u in e?s:i in e?e[i]:n})),2),p=f[0],d=f[1];G((function(){u in e&&d(s)}),[s,u]);var v=(0,r.useCallback)((function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];u in e||d(t),e[c]&&e[c].apply(e,J([t],n))}),[e,u,c]);return[u in e?s:p,v]},Z=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},X=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Z(arguments[t]));return e},ee=function(e){var t=(0,r.useRef)(-1),n=(0,r.useRef)([]),o=(0,r.useCallback)((function(e){t.current+=1,n.current.splice(e,0,t.current)}),[]),i=Z((0,r.useState)((function(){return(e||[]).forEach((function(e,t){o(t)})),e||[]})),2),a=i[0],u=i[1],l=(0,r.useCallback)((function(e){void 0===e&&(e=[]),n.current=[],u((function(){return(e||[]).forEach((function(e,t){o(t)})),e||[]}))}),[]),c=(0,r.useCallback)((function(e,t){u((function(n){var r=X(n);return r.splice(e,0,t),o(e),r}))}),[]),s=(0,r.useCallback)((function(e){return n.current[e]}),[]),f=(0,r.useCallback)((function(e){return n.current.findIndex((function(t){return t===e}))}),[]),p=(0,r.useCallback)((function(e,t){u((function(n){var r=X(n);return t.forEach((function(t,n){o(e+n)})),r.splice.apply(r,X([e,0],t)),r}))}),[]),d=(0,r.useCallback)((function(e,t){u((function(n){var r=X(n);return r[e]=t,r}))}),[]),v=(0,r.useCallback)((function(e){u((function(t){var r=X(t);r.splice(e,1);try{n.current.splice(e,1)}catch(o){console.error(o)}return r}))}),[]),h=(0,r.useCallback)((function(e,t){e!==t&&u((function(r){var o=X(r),i=o.filter((function(t,n){return n!==e}));i.splice(t,0,o[e]);try{var a=n.current.filter((function(t,n){return n!==e}));a.splice(t,0,n.current[e]),n.current=a}catch(u){console.error(u)}return i}))}),[]),y=(0,r.useCallback)((function(e){u((function(t){return o(t.length),t.concat([e])}))}),[]),m=(0,r.useCallback)((function(){try{n.current=n.current.slice(0,n.current.length-1)}catch(e){console.error(e)}u((function(e){return e.slice(0,e.length-1)}))}),[]),b=(0,r.useCallback)((function(e){u((function(t){return o(0),[e].concat(t)}))}),[]),g=(0,r.useCallback)((function(e){return e.map((function(e,t){return{key:t,item:e}})).sort((function(e,t){return f(e.key)-f(t.key)})).filter((function(e){return!!e.item})).map((function(e){return e.item}))}),[]),O=(0,r.useCallback)((function(){try{n.current=n.current.slice(1,n.current.length)}catch(e){console.error(e)}u((function(e){return e.slice(1,e.length)}))}),[]);return{list:a,insert:c,merge:p,replace:d,remove:v,getKey:s,getIndex:f,move:h,push:y,pop:m,unshift:b,shift:O,sortForm:g,resetList:l}},te=function(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.")},ne=function(){var e=this;this.subscriptions=new Set,this.emit=function(t){var n,r;try{for(var o=te(e.subscriptions),i=o.next();!i.done;i=o.next())(0,i.value)(t)}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}},this.useSubscription=function(t){var n=(0,r.useRef)();n.current=t,(0,r.useEffect)((function(){function t(e){n.current&&n.current(e)}return e.subscriptions.add(t),function(){e.subscriptions.delete(t)}}),[])}};function re(){var e=(0,r.useRef)();return e.current||(e.current=new ne),e.current}var oe=n(2158);function ie(e,t){return e?"function"===typeof e?e():"current"in e?e.current:e:t}var ae=function(e){var t=(0,r.useRef)(e);t.current=e;var n=(0,r.useRef)();return n.current||(n.current=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return t.current.apply(this,e)}),n.current};function ue(e){return"function"===typeof e}var le=function(e){var t=ae(e);(0,r.useEffect)((function(){return function(){ue(t)&&t()}}),[])},ce=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},se=function(e){var t=(0,r.useRef)(0),n=ce((0,r.useState)(e),2),o=n[0],i=n[1],a=(0,r.useCallback)((function(e){cancelAnimationFrame(t.current),t.current=requestAnimationFrame((function(){i(e)}))}),[]);return le((function(){cancelAnimationFrame(t.current)})),[o,a]},fe=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var pe,de=function(e){var t=fe(se((function(){var t=ie(e);return{width:(t||{}).clientWidth,height:(t||{}).clientHeight}})),2),n=t[0],o=t[1];return(0,r.useLayoutEffect)((function(){var t=ie(e);if(!t)return function(){};var n=new oe.Z((function(e){e.forEach((function(e){o({width:e.target.clientWidth,height:e.target.clientHeight})}))}));return n.observe(t),function(){n.disconnect()}}),[e]),n},ve=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},he=function(e,t){var n=(0,r.useRef)(),o=de(n),i=ve((0,r.useState)({start:0,end:10}),2),a=i[0],u=i[1],l=t.itemHeight,c=t.overscan,s=void 0===c?5:c;l||console.warn("please enter a valid itemHeight");var f=function(){var t=n.current;if(t){var r=function(t){if("number"===typeof l)return Math.floor(t/l)+1;for(var n=0,r=0,o=0;o<e.length;o++)if((n+=l(o,e[o]))>=t){r=o;break}return r+1}(t.scrollTop),o=function(t){if("number"===typeof l)return Math.ceil(t/l);for(var n=a.start,r=void 0===n?0:n,o=0,i=0,u=r;u<e.length;u++)if((o+=l(u,e[u]))>=t){i=u;break}return i-r}(t.clientHeight),i=r-s,c=r+o+s;u({start:i<0?0:i,end:c>e.length?e.length:c})}};(0,r.useEffect)((function(){f()}),[o.width,o.height,e.length]);var p=(0,r.useMemo)((function(){return"number"===typeof l?e.length*l:e.reduce((function(t,n,r){return t+l(r,e[r])}),0)}),[e.length]),d=function(t){return"number"===typeof l?t*l:e.slice(0,t).reduce((function(t,n,r){return t+l(r,e[r])}),0)},v=(0,r.useMemo)((function(){return d(a.start)}),[a.start]);return{list:e.slice(a.start,a.end).map((function(e,t){return{data:e,index:t+a.start}})),scrollTo:function(e){n.current&&(n.current.scrollTop=d(e),f())},containerProps:{ref:function(e){n.current=e},onScroll:function(e){e.preventDefault(),f()},style:{overflowY:"auto"}},wrapperProps:{style:{width:"100%",height:p-v,marginTop:v}}}},ye=function(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.")},me=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},be=new Set,ge={xs:0,sm:576,md:768,lg:992,xl:1200};function Oe(){var e,t,n=pe;if(je(),n!==pe)try{for(var r=ye(be),o=r.next();!o.done;o=r.next()){(0,o.value)()}}catch(i){e={error:i}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}}var we=!1;function je(){var e,t,n=window.innerWidth,r={},o=!1;try{for(var i=ye(Object.keys(ge)),a=i.next();!a.done;a=i.next()){var u=a.value;r[u]=n>=ge[u],r[u]!==pe[u]&&(o=!0)}}catch(l){e={error:l}}finally{try{a&&!a.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}o&&(pe=r)}function _e(e){ge=e,pe&&je()}function Pe(){var e="undefined"!==typeof window;e&&!we&&(pe={},je(),window.addEventListener("resize",Oe),we=!0);var t=me((0,r.useState)(pe),2),n=t[0],o=t[1];return(0,r.useEffect)((function(){if(e){var t=function(){o(pe)};return be.add(t),function(){be.delete(t),0===be.size&&(window.removeEventListener("resize",Oe),we=!1)}}}),[]),n}var Se=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function xe(e){return"function"===typeof e}function ke(e){return e?function(t,n){var o=e,i=Se((0,r.useState)((function(){return l()})),2),a=i[0],u=i[1];function l(){try{var e=o.getItem(t);if(e)return JSON.parse(e)}catch(r){console.error(r)}return xe(n)?n():n}return G((function(){u(l())}),[t]),[a,(0,r.useCallback)((function(e){if("undefined"===typeof e)o.removeItem(t),u(void 0);else if(xe(e)){var n=e(l());try{o.setItem(t,JSON.stringify(n)),u(n)}catch(r){console.error(r)}}else try{o.setItem(t,JSON.stringify(e)),u(e)}catch(r){console.error(r)}}),[t])]}:function(e,t){return[xe(t)?t():t,function(){}]}}var Ee=ke("object"===typeof window?window.localStorage:null),Ie=ke("object"===typeof window?window.sessionStorage:null),Ce=function(e,t){var n=(0,r.useRef)(!1);(0,r.useLayoutEffect)((function(){if(n.current)return e();n.current=!0}),t)},Me=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var De=function(e,t){void 0===e&&(e=!1);var n=Me((0,r.useState)(e),2),o=n[0],i=n[1];return[o,(0,r.useMemo)((function(){var n=void 0===t?!e:t;return{toggle:function(t){i(void 0===t?function(t){return t===e?n:e}:t)},setLeft:function(){return i(e)},setRight:function(){return i(n)}}}),[e,t])]},Te=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function Re(e){void 0===e&&(e=!1);var t=Te(De(e),2),n=t[0],o=t[1].toggle;return[n,(0,r.useMemo)((function(){return{toggle:o,setTrue:function(){return o(!0)},setFalse:function(){return o(!1)}}}),[o])]}var Ae=function(e,t,n){void 0===n&&(n={});var o=(0,r.useRef)();o.current=t,(0,r.useEffect)((function(){var t=ie(n.target,window);if(t.addEventListener){var r=function(e){return o.current&&o.current(e)};return t.addEventListener(e,r,{capture:n.capture,once:n.once,passive:n.passive}),function(){t.removeEventListener(e,r,{capture:n.capture})}}}),[e,n.target,n.capture,n.once,n.passive])};var Ne=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},Fe=function(){return"undefined"!==typeof window&&window.document&&window.document.createElement?document.visibilityState:"visible"};var Le=function(){var e=Ne((0,r.useState)((function(){return Fe()})),2),t=e[0],n=e[1];return Ae("visibilitychange",(function(){n(Fe())}),{target:function(){return document}}),t},ze=function(){return ze=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},ze.apply(this,arguments)},qe=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function Be(e,t){void 0===t&&(t=[]);var n=qe((0,r.useState)(t),2),o=n[0],i=n[1],a=(0,r.useMemo)((function(){return new Set(o)}),[o]),u=(0,r.useMemo)((function(){var e=function(e){return a.has(e)},t=function(e){return a.add(e),i(Array.from(a))},n=function(e){return a.delete(e),i(Array.from(a))};return{isSelected:e,select:t,unSelect:n,toggle:function(r){e(r)?n(r):t(r)}}}),[a]),l=(0,r.useMemo)((function(){var t=function(){e.forEach((function(e){a.add(e)})),i(Array.from(a))},n=function(){e.forEach((function(e){a.delete(e)})),i(Array.from(a))},r=e.every((function(e){return!a.has(e)})),o=e.every((function(e){return a.has(e)}))&&!r;return{selectAll:t,unSelectAll:n,noneSelected:r,allSelected:o,partiallySelected:!r&&!o,toggleAll:function(){return o?n():t()}}}),[a,e]);return ze(ze({selected:o,setSelected:i},u),l)}function Ue(e,t){var n=(0,r.useRef)({deps:t,obj:void 0,initialized:!1}).current;return!1!==n.initialized&&function(e,t){if(e===t)return!0;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}(n.deps,t)||(n.deps=t,n.obj=e(),n.initialized=!0),n.obj}var Ve=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},He=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Ve(arguments[t]));return e};var We=function(e,t){var n,o=(0,r.useRef)(e);o.current=e;var i=null!==(n=null===t||void 0===t?void 0:t.wait)&&void 0!==n?n:1e3,a=Ue((function(){return u()((function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return o.current.apply(o,He(e))}),i,t)}),[]);return le((function(){a.cancel()})),{run:a,cancel:a.cancel,flush:a.flush}},$e=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var Ke=function(e,t){var n=$e((0,r.useState)(e),2),o=n[0],i=n[1],a=We((function(){i(e)}),t).run;return(0,r.useEffect)((function(){a()}),[e]),o},Ge=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var Ye=function(e,t,n){var o=Ge((0,r.useState)({}),2),i=o[0],a=o[1],u=We((function(){a({})}),n),l=u.run,c=u.cancel;(0,r.useEffect)((function(){return l()}),t),le(c),G(e,[i])},Je=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},Qe=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Je(arguments[t]));return e};var Ze=function(e,t){var n,o=(0,r.useRef)(e);o.current=e;var a=null!==(n=null===t||void 0===t?void 0:t.wait)&&void 0!==n?n:1e3,u=Ue((function(){return i()((function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return o.current.apply(o,Qe(e))}),a,t)}),[]);return le((function(){u.cancel()})),{run:u,cancel:u.cancel,flush:u.flush}},Xe=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var et=function(e,t){var n=Xe((0,r.useState)(e),2),o=n[0],i=n[1],a=Ze((function(){i(e)}),t).run;return(0,r.useEffect)((function(){a()}),[e]),o};var tt=function(e,t){var n=(0,r.useRef)(),o=(0,r.useRef)();return("function"!==typeof t||t(o.current,e))&&(n.current=o.current,o.current=e),n.current},nt=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},rt={screenX:NaN,screenY:NaN,clientX:NaN,clientY:NaN,pageX:NaN,pageY:NaN},ot=function(){var e=nt((0,r.useState)(rt),2),t=e[0],n=e[1];return Ae("mousemove",(function(e){var t=e.screenX,r=e.screenY,o=e.clientX,i=e.clientY,a=e.pageX,u=e.pageY;n({screenX:t,screenY:r,clientX:o,clientY:i,pageX:a,pageY:u})}),{target:document}),t},it=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var at=function(e,t){void 0===t&&(t=function(){return!0});var n=it((0,r.useState)({left:NaN,top:NaN}),2),o=n[0],i=n[1],a=ae(t);return(0,r.useEffect)((function(){var t=ie(e,document);if(t)return n(t),t.addEventListener("scroll",r),function(){t.removeEventListener("scroll",r)};function n(e){var t;if(e===document){if(!document.scrollingElement)return;t={left:document.scrollingElement.scrollLeft,top:document.scrollingElement.scrollTop}}else t={left:e.scrollLeft,top:e.scrollTop};a(t)&&i(t)}function r(e){e.target&&n(e.target)}}),[e,a]),o};function ut(e,t,n){void 0===n&&(n="click");var o=(0,r.useRef)(e);o.current=e,(0,r.useEffect)((function(){var e=function(e){(Array.isArray(t)?t:[t]).some((function(t){var n=ie(t);return!n||(null===n||void 0===n?void 0:n.contains(e.target))}))||o.current(e)};return document.addEventListener(n,e),function(){document.removeEventListener(n,e)}}),[t,n])}var lt=n(83448),ct=n.n(lt),st=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},ft=function(e,t){var n=t||{},o=n.onExitFull,i=n.onFull,a=(0,r.useRef)(o);a.current=o;var u=(0,r.useRef)(i);u.current=i;var l=st((0,r.useState)(!1),2),c=l[0],s=l[1],f=(0,r.useCallback)((function(){if(ct().isEnabled){var e=ct().isFullscreen;e?u.current&&u.current():(ct().off("change",f),a.current&&a.current()),s(e)}}),[]),p=(0,r.useCallback)((function(){var t=ie(e);if(t&&ct().isEnabled)try{ct().request(t),ct().on("change",f)}catch(n){}}),[e,f]),d=(0,r.useCallback)((function(){c&&ct().isEnabled&&ct().exit()}),[c]),v=(0,r.useCallback)((function(){c?d():p()}),[c,p,d]);return le((function(){ct().isEnabled&&ct().off("change",f)})),[c,{setFull:p,exitFull:d,toggleFull:v}]},pt=(n(30827),function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}),dt=function(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.")};var vt=function(e){var t=pt((0,r.useState)((function(){return function(e){if(e){var t=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,n=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight,r=e.getBoundingClientRect();if(r){var o=r.top,i=r.bottom,a=r.left,u=r.right;return i>0&&o<=n&&a<=t&&u>0}return!1}}(ie(e))})),2),n=t[0],o=t[1];return(0,r.useEffect)((function(){var t=ie(e);if(!t)return function(){};var n=new IntersectionObserver((function(e){var t,n;try{for(var r=dt(e),i=r.next();!i.done;i=r.next()){i.value.isIntersecting?o(!0):o(!1)}}catch(a){t={error:a}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}}));return n.observe(t),function(){n.disconnect()}}),[e]),n},ht=function(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.")},yt={esc:27,tab:9,enter:13,space:32,up:38,left:37,right:39,down:40,delete:[8,46]},mt={esc:"Escape",tab:"Tab",enter:"Enter",space:" ",up:["Up","ArrowUp"],left:["Left","ArrowLeft"],right:["Right","ArrowRight"],down:["Down","ArrowDown"],delete:["Backspace","Delete"]},bt={ctrl:function(e){return e.ctrlKey},shift:function(e){return e.shiftKey},alt:function(e){return e.altKey},meta:function(e){return e.metaKey}},gt=function(){};function Ot(e){return Object.prototype.toString.call(e).replace(/^\[object (.+)\]$/,"$1").toLowerCase()}function wt(e,t){var n,r;if(!e.key)return!1;if("number"===Ot(t))return e.keyCode===t;var o=t.split("."),i=0;try{for(var a=ht(o),u=a.next();!u.done;u=a.next()){var l=u.value,c=bt[l],s=mt[l],f=yt[l];(c&&c(e)||(s&&"array"===Ot(s)?s.includes(e.key):s===e.key)||(f&&"array"===Ot(f)?f.includes(e.keyCode):f===e.keyCode)||e.key.toUpperCase()===l.toUpperCase())&&i++}}catch(p){n={error:p}}finally{try{u&&!u.done&&(r=a.return)&&r.call(a)}finally{if(n)throw n.error}}return i===o.length}var jt=["keydown"];var _t=function(e,t,n){void 0===t&&(t=gt),void 0===n&&(n={});var o=n.events,i=void 0===o?jt:o,a=n.target,u=(0,r.useRef)(t);u.current=t,(0,r.useEffect)((function(){var t,n,r=function(t){var n=function(e){var t=Ot(e);return"function"===t?e:"string"===t||"number"===t?function(t){return wt(t,e)}:"array"===t?function(t){return e.some((function(e){return wt(t,e)}))}:e?function(){return!0}:function(){return!1}}(e);if(n(t))return u.current(t)},o=ie(a,window);try{for(var l=ht(i),c=l.next();!c.done;c=l.next()){var s=c.value;o.addEventListener(s,r)}}catch(f){t={error:f}}finally{try{c&&!c.done&&(n=l.return)&&n.call(l)}finally{if(t)throw t.error}}return function(){var e,t;try{for(var n=ht(i),a=n.next();!a.done;a=n.next()){var u=a.value;o.removeEventListener(u,r)}}catch(l){e={error:l}}finally{try{a&&!a.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}}}),[i,e,a])},Pt=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},St=function(e,t){var n=t||{},r=n.onEnter,o=n.onLeave,i=Pt(Re(!1),2),a=i[0],u=i[1],l=u.setTrue,c=u.setFalse;return Ae("mouseenter",(function(){r&&r(),l()}),{target:e}),Ae("mouseleave",(function(){o&&o(),c()}),{target:e}),a},xt=function(){return xt=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},xt.apply(this,arguments)},kt=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&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n},Et=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},It=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Et(arguments[t]));return e};var Ct=function(e,t){var n=t.form,o=t.refreshDeps,i=void 0===o?[]:o,a=t.manual,u=t.defaultType,l=void 0===u?"simple":u,c=t.defaultParams,s=kt(t,["form","refreshDeps","manual","defaultType","defaultParams"]),f=K(e,xt(xt({},s),{paginated:!0,manual:!0})),p=f.params,d=f.run,v=p[2]||{},h=Et((0,r.useState)(v.type||l),2),y=h[0],m=h[1],b=Et((0,r.useState)(v.allFormData||c&&c[1]||{}),2),g=b[0],O=b[1],w=(0,r.useCallback)((function(){if(!n)return{};if(n.getFieldInstance){var e=n.getFieldsValue(),t={};return Object.keys(e).forEach((function(r){n.getFieldInstance&&!n.getFieldInstance(r)||(t[r]=e[r])})),t}return n.getFieldsValue(null,(function(){return!0}))}),[n]),j=(0,r.useRef)(n);j.current=n,(0,r.useEffect)((function(){if(j.current)if(j.current.getFieldInstance){var e={};Object.keys(g).forEach((function(t){j.current.getFieldInstance&&!j.current.getFieldInstance(t)||(e[t]=g[t])})),j.current.setFieldsValue(e)}else j.current.setFieldsValue(g)}),[y]),(0,r.useEffect)((function(){p.length>0?d.apply(void 0,It(p)):a||S(c)}),[]);var _=(0,r.useCallback)((function(){var e=w();O(xt(xt({},g),e)),m("simple"===y?"advance":"simple")}),[y,g,w]),P=(0,r.useCallback)((function(){var e=w();if(!n)return Promise.resolve();var t=Object.keys(e);return n.getInternalHooks?n.validateFields(t):new Promise((function(e,r){n.validateFields(t,(function(t,n){t?r(t):e(n)}))}))}),[n]),S=(0,r.useCallback)((function(e){setTimeout((function(){P().then((function(){var n=w(),r=xt(xt({},g),n);O(r),d(e?e[0]:xt(xt({pageSize:t.defaultPageSize||10},p[0]||{}),{current:1}),n,{allFormData:r,type:y})})).catch((function(e){return e}))}))}),[w,d,p,g,y]),x=(0,r.useCallback)((function(){n&&n.resetFields(),S()}),[n,S]),k=ae(x);G((function(){a||k()}),It(i));var E=ae((function(e){e&&e.preventDefault&&e.preventDefault(),S()}));return xt(xt({},f),{search:{submit:E,type:y,changeType:_,reset:x}})},Mt=function(){return Mt=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},Mt.apply(this,arguments)},Dt=function(){return Dt=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},Dt.apply(this,arguments)};var Tt=function(e,t){var n;return function(e){var t={dataSource:e.tableProps.dataSource,loading:e.tableProps.loading,onSort:function(t,n){e.tableProps.onChange({current:e.pagination.current,pageSize:e.pagination.pageSize},e.filters,{field:t,order:n})},onFilter:function(t){e.tableProps.onChange({current:e.pagination.current,pageSize:e.pagination.pageSize},t,e.sorter)}},n={onChange:e.pagination.changeCurrent,onPageSizeChange:e.pagination.changePageSize,current:e.pagination.current,pageSize:e.pagination.pageSize,total:e.pagination.total};return Mt(Mt({},e),{tableProps:t,paginationProps:n})}(Ct(e,Dt(Dt({},t),{form:t.field?(n=t.field,{getFieldInstance:function(e){return n.getNames().includes(e)},setFieldsValue:n.setValues,getFieldsValue:n.getValues,resetFields:n.resetToDefault,validateFields:function(e,t){n.validate(t)}}):void 0})))},Rt=function(){return Rt=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},Rt.apply(this,arguments)},At=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var Nt=function(e){var t=(0,r.useMemo)((function(){return void 0===e?new Set:new Set(e)}),[]),n=At((0,r.useState)(t),2),o=n[0],i=n[1],a=(0,r.useMemo)((function(){return{add:function(e){i((function(t){var n=new Set(t);return n.add(e),n}))},remove:function(e){i((function(t){var n=new Set(t);return n.delete(e),n}))},reset:function(){return i(t)}}}),[i,t]),u=Rt({has:(0,r.useCallback)((function(e){return o.has(e)}),[o])},a);return[o,u]},Ft=function(){return Ft=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},Ft.apply(this,arguments)},Lt=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var zt=function(e){var t=(0,r.useMemo)((function(){return void 0===e?new Map:new Map(e)}),[]),n=Lt((0,r.useState)(t),2),o=n[0],i=n[1],a=(0,r.useMemo)((function(){return{set:function(e,t){i((function(n){var r=new Map(n);return r.set(e,t),r}))},setAll:function(e){i(new Map(e))},remove:function(e){i((function(t){var n=new Map(t);return n.delete(e),n}))},reset:function(){return i(t)}}}),[i,t]),u=Ft({get:(0,r.useCallback)((function(e){return o.get(e)}),[o])},a);return[o,u]},qt=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},Bt=function(e){void 0===e&&(e={});var t=(0,r.useRef)(e);t.current=e;var n=qt((0,r.useState)(!1),2),o=n[0],i=n[1],a=(0,r.useCallback)((function(e,n){var r=e.getData("text/uri-list"),o=e.getData("custom");if(o&&t.current.onDom){var i=o;try{i=JSON.parse(o)}catch(a){i=o}t.current.onDom(i,n)}else r&&t.current.onUri?t.current.onUri(r,n):e.files&&e.files.length&&t.current.onFiles?t.current.onFiles(Array.from(e.files),n):e.items&&e.items.length&&t.current.onText&&e.items[0].getAsString((function(e){t.current.onText(e,n)}))}),[]),u=(0,r.useMemo)((function(){return function(e,t){return{onDragOver:function(e){e.preventDefault()},onDragEnter:function(e){e.preventDefault(),t(!0)},onDragLeave:function(){t(!1)},onDrop:function(n){n.preventDefault(),n.persist(),t(!1),e(n.dataTransfer,n)},onPaste:function(t){t.persist(),e(t.clipboardData,t)}}}(a,i)}),[a,i]);return[u,{isHovering:o}]},Ut=function(e){return function(t){return{key:e&&!1===e.getPropsWithKey?void 0:JSON.stringify(t),draggable:"true",onDragStart:function(n){e&&e.onDragStart&&e.onDragStart(t,n),n.dataTransfer.setData("custom",JSON.stringify(t))},onDragEnd:function(n){e&&e.onDragEnd&&e.onDragEnd(t,n)}}}},Vt=function(e){(0,r.useEffect)((function(){e()}),[])},Ht=function(){return Ht=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},Ht.apply(this,arguments)},Wt=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},$t={top:NaN,left:NaN,bottom:NaN,right:NaN,height:NaN,width:NaN},Kt=Ht({text:""},$t);var Gt=function(e){var t=Wt((0,r.useState)(Kt),2),n=t[0],o=t[1],i=(0,r.useRef)(n);return i.current=n,(0,r.useEffect)((function(){var t=ie(e,document);if(!t)return function(){};var r=function(){var e,t=null,r=$t;window.getSelection&&(e=(t=window.getSelection())?t.toString():"")&&(r=function(e){if(!e)return $t;if(e.rangeCount<1)return $t;var t=e.getRangeAt(0).getBoundingClientRect();return{height:t.height,width:t.width,top:t.top,left:t.left,right:t.right,bottom:t.bottom}}(t),o(Ht(Ht(Ht({},n),{text:e}),r)))},a=function(){if(window.getSelection){i.current.text&&o(Ht({},Kt));var e=window.getSelection();e&&e.removeAllRanges()}};return t.addEventListener("mouseup",r),document.addEventListener("mousedown",a),function(){t.removeEventListener("mouseup",r),document.removeEventListener("mousedown",a)}}),["function"===typeof e?void 0:e]),n},Yt=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function Jt(e,t){void 0===t&&(t={});var n=t.min,r=t.max,o=e;return"number"===typeof r&&(o=Math.min(r,o)),"number"===typeof n&&(o=Math.max(n,o)),o}var Qt=function(e,t){void 0===e&&(e=0),void 0===t&&(t={});var n=t.min,o=t.max,i=Ue((function(){return Jt(e,{min:n,max:o})}),[]),a=Yt((0,r.useState)(i),2),u=a[0],l=a[1];return[u,(0,r.useMemo)((function(){var e=function(e){l((function(t){return Jt("number"===typeof e?e:e(t),{max:o,min:n})}))};return{inc:function(t){void 0===t&&(t=1),e((function(e){return e+t}))},dec:function(t){void 0===t&&(t=1),e((function(e){return e-t}))},set:function(t){e(t)},reset:function(){e(i)}}}),[i,o,n])]},Zt=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},Xt=function(){var e=Zt((0,r.useState)({}),2)[1];return(0,r.useCallback)((function(){return e({})}),[])},en=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var tn=function(e){var t=e||{},n=t.initialValue,o=t.transformer,i=en((0,r.useState)(n),2),a=i[0],u=i[1],l=(0,r.useCallback)((function(){return u(n)}),[]),c=(0,r.useRef)(o);return c.current=o,[a,{onChange:(0,r.useCallback)((function(e){var t=e.target.value;return"function"===typeof c.current?u(c.current(t)):u(t)}),[]),reset:l}]},nn=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},rn=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(nn(arguments[t]));return e},on=function(e,t){var n=function(e,t){var n=e>0?e-1:t.length+e;return n>=t.length-1&&(n=t.length-1),n<0&&(n=0),n}(e,t);return{_current:t[n],_before:t.slice(0,n),_after:t.slice(n+1)}};function an(e){var t=nn((0,r.useState)({present:e,past:[],future:[]}),2),n=t[0],o=t[1],i=n.present,a=n.past,u=n.future,l=(0,r.useRef)(e),c=(0,r.useCallback)((function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=e.length>0?e[0]:l.current;l.current=n,o({present:n,future:[],past:[]})}),[n,o]),s=(0,r.useCallback)((function(e){o({present:e,future:[],past:rn(a,[i])})}),[n,o]),f=(0,r.useCallback)((function(e){if(void 0===e&&(e=1),0!==u.length){var t=on(e,u),n=t._before,r=t._current,l=t._after;o({past:rn(a,[i],n),present:r,future:l})}}),[n,o]),p=(0,r.useCallback)((function(e){if(void 0===e&&(e=-1),0!==a.length){var t=on(e,a),n=t._before,r=t._current,l=t._after;o({past:n,present:r,future:rn(l,[i],u)})}}),[n,o]),d=(0,r.useCallback)((function(e){var t="number"===typeof e?e:Number(e);if(0!==t)return t>0?f(t):void p(t)}),[p,f]);return{value:i,setValue:s,backLength:a.length,forwardLength:u.length,go:d,back:(0,r.useCallback)((function(){d(-1)}),[d]),forward:(0,r.useCallback)((function(){d(1)}),[d]),reset:c}}var un=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var ln=function(e,t,n){var o=un((0,r.useState)({}),2),i=o[0],a=o[1],u=Ze((function(){a({})}),n),l=u.run,c=u.cancel;(0,r.useEffect)((function(){return l()}),t),le(c),G(e,[i])},cn=n(24221),sn=n.n(cn),fn=function(){return fn=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},fn.apply(this,arguments)},pn=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&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n},dn=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var vn=function(e,t){void 0===t&&(t={});var n=dn((0,r.useState)((function(){var n=sn().get(e);return"string"===typeof n?n:ue(t.defaultValue)?t.defaultValue():t.defaultValue})),2),o=n[0],i=n[1],a=(0,r.useCallback)((function(n,r){void 0===r&&(r={});var o=fn(fn({},t),r),a=(o.defaultValue,pn(o,["defaultValue"]));i((function(t){var r=ue(n)?n(t):n;return void 0===r||null===r?sn().remove(e):sn().set(e,r,a),r}))}),[e,t]);return[o,a]},hn=function(){return hn=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},hn.apply(this,arguments)},yn=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},mn=function(e){void 0===e&&(e={});var t=yn((0,r.useState)(e),2),n=t[0],o=t[1];return[n,(0,r.useCallback)((function(e){o((function(t){return hn(hn({},t),ue(e)?e(t):e)}))}),[])]};var bn=function(e,t,n){var o=null===n||void 0===n?void 0:n.immediate,i=(0,r.useRef)();i.current=e,(0,r.useEffect)((function(){var e;if(void 0!==t&&null!==t){o&&(null===(e=i.current)||void 0===e||e.call(i));var n=setInterval((function(){var e;null===(e=i.current)||void 0===e||e.call(i)}),t);return function(){clearInterval(n)}}}),[t])},gn=function(){return gn=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},gn.apply(this,arguments)};function On(e,t){var n=(0,r.useRef)({});(0,r.useEffect)((function(){if(n.current){var r=Object.keys(gn(gn({},n.current),t)),o={};r.forEach((function(e){n.current[e]!==t[e]&&(o[e]={from:n.current[e],to:t[e]})})),Object.keys(o).length&&console.log("[why-did-you-update]",e,o)}n.current=t}))}var wn={restoreOnUnmount:!1};var jn="undefined"!==typeof document?function(e,t){void 0===t&&(t=wn);var n=(0,r.useRef)(document.title);(0,r.useEffect)((function(){document.title=e}),[e]),le((function(){t&&t.restoreOnUnmount&&(document.title=n.current)}))}:function(){},_n=function(){return _n=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},_n.apply(this,arguments)},Pn=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function Sn(){var e=navigator;return"object"!==typeof e?null:e.connection||e.mozConnection||e.webkitConnection}function xn(){var e=Sn();return e?{rtt:e.rtt,type:e.type,saveData:e.saveData,downlink:e.downlink,downlinkMax:e.downlinkMax,effectiveType:e.effectiveType}:{}}var kn=function(){var e=Pn((0,r.useState)((function(){return _n({since:void 0,online:navigator.onLine},xn())})),2),t=e[0],n=e[1];return(0,r.useEffect)((function(){var e=function(){n((function(e){return _n(_n({},e),{online:!0,since:new Date})}))},t=function(){n((function(e){return _n(_n({},e),{online:!1,since:new Date})}))},r=function(){n((function(e){return _n(_n({},e),xn())}))};window.addEventListener("online",e),window.addEventListener("offline",t);var o=Sn();return null===o||void 0===o||o.addEventListener("change",r),function(){window.removeEventListener("online",e),window.removeEventListener("offline",t),null===o||void 0===o||o.removeEventListener("change",r)}}),[]),t};var En=function(e,t){var n=ae(e);(0,r.useEffect)((function(){if(void 0!==t&&null!==t){var e=setTimeout((function(){n()}),t);return function(){clearTimeout(e)}}}),[t,n])},In=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},Cn=new WeakMap,Mn=new WeakMap;function Dn(e,t){var n=Cn.get(e);if(n)return n;if(Mn.has(e))return e;var r=new Proxy(e,{get:function(e,n,r){var o,i=Reflect.get(e,n,r);return"object"===typeof(o=i)&&null!==o?Dn(i,t):Reflect.get(e,n)},set:function(e,n,r){var o=Reflect.set(e,n,r);return t(),o},deleteProperty:function(e,n){var r=Reflect.deleteProperty(e,n);return t(),r}});return Cn.set(e,r),Mn.set(r,e),r}var Tn,Rn=function(e){var t=In((0,r.useState)({}),2)[1],n=(0,r.useRef)(e);return Ue((function(){return Dn(n.current,(function(){t({})}))}),[])},An={SVG:"image/svg+xml",ICO:"image/x-icon",GIF:"image/gif",PNG:"image/png"},Nn=function(e){(0,r.useEffect)((function(){if(e){var t=e.split("."),n=t[t.length-1].toLocaleUpperCase(),r=document.querySelector("link[rel*='icon']")||document.createElement("link");r.type=An[n],r.href=e,r.rel="shortcut icon",document.getElementsByTagName("head")[0].appendChild(r)}}),[e])},Fn=n(74268),Ln=n.n(Fn),zn=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},qn=function(e){if(!e)return 0;var t=Ln()(e).valueOf()-(new Date).getTime();return t<0?0:t},Bn=function(e){var t=e||{},n=t.targetDate,o=t.interval,i=void 0===o?1e3:o,a=t.onEnd,u=zn((0,r.useState)(n),2),l=u[0],c=u[1],s=zn((0,r.useState)((function(){return qn(l)})),2),f=s[0],p=s[1],d=ae((function(){a&&a()}));(0,r.useEffect)((function(){if(l){p(qn(l));var e=setInterval((function(){var t=qn(l);p(t),0===t&&(clearInterval(e),d())}),i);return function(){return clearInterval(e)}}p(0)}),[l,i]);var v=(0,r.useMemo)((function(){return e=f,{days:Math.floor(e/864e5),hours:Math.floor(e/36e5)%24,minutes:Math.floor(e/6e4)%60,seconds:Math.floor(e/1e3)%60,milliseconds:Math.floor(e)%1e3};var e}),[f]);return[f,c,v]},Un=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function Vn(e,t){void 0===t&&(t={});var n=t.reconnectLimit,o=void 0===n?3:n,i=t.reconnectInterval,a=void 0===i?3e3:i,u=t.manual,l=void 0!==u&&u,c=t.onOpen,s=t.onClose,f=t.onMessage,p=t.onError,d=(0,r.useRef)(0),v=(0,r.useRef)(),h=(0,r.useRef)(),y=(0,r.useRef)(!1),m=Un((0,r.useState)(),2),b=m[0],g=m[1],O=Un((0,r.useState)(Tn.Closed),2),w=O[0],j=O[1],_=ae((function(){var e;d.current<o&&(null===(e=h.current)||void 0===e?void 0:e.readyState)!==Tn.Open&&(v.current&&clearTimeout(v.current),v.current=setTimeout((function(){P(),d.current++}),a))})),P=ae((function(){v.current&&clearTimeout(v.current),h.current&&h.current.close();try{h.current=new WebSocket(e),h.current.onerror=function(e){var t;_(),p&&p(e),j((null===(t=h.current)||void 0===t?void 0:t.readyState)||Tn.Closed)},h.current.onopen=function(e){var t;c&&c(e),d.current=0,j((null===(t=h.current)||void 0===t?void 0:t.readyState)||Tn.Closed)},h.current.onmessage=function(e){f&&f(e),g(e)},h.current.onclose=function(e){var t;y.current||(_(),s&&s(e),j((null===(t=h.current)||void 0===t?void 0:t.readyState)||Tn.Closed))}}catch(t){throw t}})),S=ae((function(e){var t;if(w!==Tn.Open)throw new Error("WebSocket disconnected");null===(t=h.current)||void 0===t||t.send(e)})),x=ae((function(){d.current=0,P()})),k=ae((function(){var e;v.current&&clearTimeout(v.current),d.current=o,null===(e=h.current)||void 0===e||e.close()}));return(0,r.useEffect)((function(){l||x()}),[e,l]),le((function(){y.current=!0,k()})),{latestMessage:b,sendMessage:S,connect:x,disconnect:k,readyState:w,webSocketIns:h.current}}!function(e){e[e.Connecting=0]="Connecting",e[e.Open=1]="Open",e[e.Closing=2]="Closing",e[e.Closed=3]="Closed"}(Tn||(Tn={}));var Hn=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(t){i(t)}}function u(e){try{l(r.throw(e))}catch(t){i(t)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,u)}l((r=r.apply(e,t||[])).next())}))},Wn=function(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:u(0),throw:u(1),return:u(2)},"function"===typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){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(u){i=[6,u],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}},$n=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},Kn=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat($n(arguments[t]));return e};var Gn=function(e){var t=this,n=(0,r.useRef)(!1);return(0,r.useCallback)((function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return Hn(t,void 0,void 0,(function(){var t,o;return Wn(this,(function(i){switch(i.label){case 0:if(n.current)return[2];n.current=!0,i.label=1;case 1:return i.trys.push([1,3,,4]),[4,e.apply(void 0,Kn(r))];case 2:return t=i.sent(),n.current=!1,[2,t];case 3:throw o=i.sent(),n.current=!1,o;case 4:return[2]}}))}))}),[e])},Yn=function(e,t){var n=(0,r.useRef)();(0,r.useEffect)((function(){var r,o,i=(r=n.current,o=t,r?r.map((function(e,t){return r[t]!==o[t]?t:-1})).filter((function(e){return e>=0})):o?o.map((function(e,t){return t})):[]),a=n.current;return n.current=t,e(i,a,t)}),t)},Jn=function(){var e=(0,r.useRef)(!1);return(0,r.useEffect)((function(){return e.current=!1,function(){e.current=!0}}),[]),e},Qn=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function Zn(e,t){var n="string"===typeof e&&""!==e,o=Qn((0,r.useState)(n?"loading":"unset"),2),i=o[0],a=o[1],u=Qn((0,r.useState)(n),2),l=u[0],c=u[1],s=(0,r.useRef)();return(0,r.useEffect)((function(){var r;if(null===(r=s.current)||void 0===r||r.remove(),!n||!l)return a("unset"),void(s.current=void 0);a("loading");var o=e.replace(/[|#].*$/,"");if("css"===(null===t||void 0===t?void 0:t.type)||/(^css!|\.css$)/.test(o))s.current=document.createElement("link"),s.current.rel="stylesheet",s.current.href=e,s.current.media=(null===t||void 0===t?void 0:t.media)||"all","hideFocus"in s.current&&s.current.relList&&(s.current.rel="preload",s.current.as="style"),s.current.setAttribute("data-status","loading"),document.head.appendChild(s.current);else if("js"===(null===t||void 0===t?void 0:t.type)||/(^js!|\.js$)/.test(o))s.current=document.createElement("script"),s.current.src=e,s.current.async=void 0===(null===t||void 0===t?void 0:t.async)||(null===t||void 0===t?void 0:t.async),s.current.setAttribute("data-status","loading"),document.body.appendChild(s.current);else if("img"===(null===t||void 0===t?void 0:t.type)||/(^img!|\.(png|gif|jpg|svg|webp)$)/.test(o)){s.current=document.createElement("img"),s.current.src=e,s.current.setAttribute("data-status","loading");var i=ie(null===t||void 0===t?void 0:t.target)||document.body;i&&i.appendChild(s.current)}else console.error("Cannot infer the type of external resource, and please provide a type ('js' | 'css' | 'img'). Refer to the https://ahooks.js.org/hooks/dom/use-external/#options");if(s.current){var u=function(e){var t;null===(t=s.current)||void 0===t||t.setAttribute("data-status","load"===e.type?"ready":"error")};s.current.addEventListener("load",u),s.current.addEventListener("error",u);var c=function(e){a("load"===e.type?"ready":"error")};return s.current.addEventListener("load",c),s.current.addEventListener("error",c),function(){var e,t;null===(e=s.current)||void 0===e||e.removeEventListener("load",c),null===(t=s.current)||void 0===t||t.removeEventListener("error",c)}}}),[e,l]),[i,(0,r.useMemo)((function(){return{toggle:function(){return c((function(e){return!e}))},load:function(){return c(!0)},unload:function(){return c(!1)}}}),[c])]}var Xn=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};var er=function(e){var t=Jn(),n=Xn(r.useState(e),2),o=n[0],i=n[1];return[o,r.useCallback((function(e){t.current||i(e)}),[])]},tr=function(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(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},nr=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(tr(arguments[t]));return e},rr=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return console.warn("useControlledValue is deprecated and will be removed in the next major version. Please use useControllableValue instead."),Q.apply(void 0,nr(e))}},30827:function(){!function(){"use strict";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,t=[];r.prototype.THROTTLE_TIMEOUT=100,r.prototype.POLL_INTERVAL=null,r.prototype.USE_MUTATION_OBSERVER=!0,r.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()}},r.prototype.unobserve=function(e){this._observationTargets=this._observationTargets.filter((function(t){return t.element!=e})),this._observationTargets.length||(this._unmonitorIntersections(),this._unregisterInstance())},r.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorIntersections(),this._unregisterInstance()},r.prototype.takeRecords=function(){var e=this._queuedEntries.slice();return this._queuedEntries=[],e},r.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]}))},r.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},r.prototype._monitorIntersections=function(){this._monitoringIntersections||(this._monitoringIntersections=!0,this.POLL_INTERVAL?this._monitoringInterval=setInterval(this._checkForIntersections,this.POLL_INTERVAL):(o(window,"resize",this._checkForIntersections,!0),o(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}))))},r.prototype._unmonitorIntersections=function(){this._monitoringIntersections&&(this._monitoringIntersections=!1,clearInterval(this._monitoringInterval),this._monitoringInterval=null,i(window,"resize",this._checkForIntersections,!0),i(e,"scroll",this._checkForIntersections,!0),this._domObserver&&(this._domObserver.disconnect(),this._domObserver=null))},r.prototype._checkForIntersections=function(){var e=this._rootIsInDom(),t=e?this._getRootRect():{top:0,bottom:0,left:0,right:0,width:0,height:0};this._observationTargets.forEach((function(r){var o=r.element,i=u(o),a=this._rootContainsTarget(o),l=r.entry,c=e&&a&&this._computeTargetAndRootIntersection(o,t),s=r.entry=new n({time:window.performance&&performance.now&&performance.now(),target:o,boundingClientRect:i,rootBounds:t,intersectionRect:c});l?e&&a?this._hasCrossedThreshold(l,s)&&this._queuedEntries.push(s):l&&l.isIntersecting&&this._queuedEntries.push(s):this._queuedEntries.push(s)}),this),this._queuedEntries.length&&this._callback(this.takeRecords(),this)},r.prototype._computeTargetAndRootIntersection=function(t,n){if("none"!=window.getComputedStyle(t).display){for(var r=u(t),o=c(t),i=!1;!i;){var l=null,s=1==o.nodeType?window.getComputedStyle(o):{};if("none"==s.display)return;if(o==this.root||o==e?(i=!0,l=n):o!=e.body&&o!=e.documentElement&&"visible"!=s.overflow&&(l=u(o)),l&&!(r=a(l,r)))break;o=c(o)}return r}},r.prototype._getRootRect=function(){var t;if(this.root)t=u(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)},r.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},r.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}},r.prototype._rootIsInDom=function(){return!this.root||l(e,this.root)},r.prototype._rootContainsTarget=function(t){return l(this.root||e,t)},r.prototype._registerInstance=function(){t.indexOf(this)<0&&t.push(this)},r.prototype._unregisterInstance=function(){var e=t.indexOf(this);-1!=e&&t.splice(e,1)},window.IntersectionObserver=r,window.IntersectionObserverEntry=n}function n(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 r(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 o(e,t,n,r){"function"==typeof e.addEventListener?e.addEventListener(t,n,r||!1):"function"==typeof e.attachEvent&&e.attachEvent("on"+t,n)}function i(e,t,n,r){"function"==typeof e.removeEventListener?e.removeEventListener(t,n,r||!1):"function"==typeof e.detatchEvent&&e.detatchEvent("on"+t,n)}function a(e,t){var n=Math.max(e.top,t.top),r=Math.min(e.bottom,t.bottom),o=Math.max(e.left,t.left),i=Math.min(e.right,t.right),a=i-o,u=r-n;return a>=0&&u>=0&&{top:n,bottom:r,left:o,right:i,width:a,height:u}}function u(e){var t;try{t=e.getBoundingClientRect()}catch(n){}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 l(e,t){for(var n=t;n;){if(n==e)return!0;n=c(n)}return!1}function c(e){var t=e.parentNode;return t&&11==t.nodeType&&t.host?t.host:t&&t.assignedSlot?t.assignedSlot.parentNode:t}}()},97475:function(e,t,n){"use strict";var r=n(71600);t.Z=void 0;var o=r(n(48035)),i=n(37574),a=(0,o.default)((0,i.jsx)("path",{d:"m7 10 5 5 5-5z"}),"ArrowDropDown");t.Z=a},30291:function(e,t,n){"use strict";var r=n(71600);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n(48035)),i=n(37574),a=(0,o.default)((0,i.jsx)("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM8 9h8v10H8V9zm7.5-5-1-1h-5l-1 1H5v2h14V4z"}),"DeleteOutline");t.default=a},91118:function(e,t,n){"use strict";var r=n(71600);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n(48035)),i=n(37574),a=(0,o.default)((0,i.jsx)("path",{d:"M9 11.75c-.69 0-1.25.56-1.25 1.25s.56 1.25 1.25 1.25 1.25-.56 1.25-1.25-.56-1.25-1.25-1.25zm6 0c-.69 0-1.25.56-1.25 1.25s.56 1.25 1.25 1.25 1.25-.56 1.25-1.25-.56-1.25-1.25-1.25zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8 0-.29.02-.58.05-.86 2.36-1.05 4.23-2.98 5.21-5.37C11.07 8.33 14.05 10 17.42 10c.78 0 1.53-.09 2.25-.26.21.71.33 1.47.33 2.26 0 4.41-3.59 8-8 8z"}),"Face");t.default=a},88544:function(e,t,n){"use strict";var r=n(71600);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n(48035)),i=n(37574),a=(0,o.default)((0,i.jsx)("path",{d:"M7 6h10l-5.01 6.3L7 6zm-2.75-.39C6.27 8.2 10 13 10 13v6c0 .55.45 1 1 1h2c.55 0 1-.45 1-1v-6s3.72-4.8 5.74-7.39c.51-.66.04-1.61-.79-1.61H5.04c-.83 0-1.3.95-.79 1.61z"}),"FilterAltOutlined");t.default=a},96979:function(e,t,n){"use strict";var r=n(71600);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n(48035)),i=n(37574),a=(0,o.default)((0,i.jsx)("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"}),"KeyboardArrowDown");t.default=a},11909:function(e,t,n){"use strict";var r=n(71600);t.Z=void 0;var o=r(n(48035)),i=n(37574),a=(0,o.default)((0,i.jsx)("path",{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"}),"Launch");t.Z=a},64698:function(e,t,n){"use strict";var r=n(71600);t.Z=void 0;var o=r(n(48035)),i=n(37574),a=(0,o.default)((0,i.jsx)("path",{d:"M7 18c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zM1 2v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.14 0-.25-.11-.25-.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.58-6.49c.08-.14.12-.31.12-.48 0-.55-.45-1-1-1H5.21l-.94-2H1zm16 16c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2z"}),"ShoppingCart");t.Z=a},79769:function(e,t,n){"use strict";var r=n(71600);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n(48035)),i=n(37574),a=(0,o.default)((0,i.jsx)("path",{d:"M3 18h6v-2H3v2zM3 6v2h18V6H3zm0 7h12v-2H3v2z"}),"Sort");t.default=a},36508:function(e,t,n){"use strict";var r=n(71600);t.Z=void 0;var o=r(n(48035)),i=n(37574),a=(0,o.default)((0,i.jsx)("path",{d:"M12 1 3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm-2 16-4-4 1.41-1.41L10 14.17l6.59-6.59L18 9l-8 8z"}),"VerifiedUser");t.Z=a},38752:function(e){"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},99843:function(e,t,n){var r=n(38752),o=n(2637),i=Object.hasOwnProperty,a=Object.create(null);for(var u in r)i.call(r,u)&&(a[r[u]]=u);var l=e.exports={to:{},get:{}};function c(e,t,n){return Math.min(Math.max(t,e),n)}function s(e){var t=Math.round(e).toString(16).toUpperCase();return t.length<2?"0"+t:t}l.get=function(e){var t,n;switch(e.substring(0,3).toLowerCase()){case"hsl":t=l.get.hsl(e),n="hsl";break;case"hwb":t=l.get.hwb(e),n="hwb";break;default:t=l.get.rgb(e),n="rgb"}return t?{model:n,value:t}:null},l.get.rgb=function(e){if(!e)return null;var t,n,o,a=[0,0,0,1];if(t=e.match(/^#([a-f0-9]{6})([a-f0-9]{2})?$/i)){for(o=t[2],t=t[1],n=0;n<3;n++){var u=2*n;a[n]=parseInt(t.slice(u,u+2),16)}o&&(a[3]=parseInt(o,16)/255)}else if(t=e.match(/^#([a-f0-9]{3,4})$/i)){for(o=(t=t[1])[3],n=0;n<3;n++)a[n]=parseInt(t[n]+t[n],16);o&&(a[3]=parseInt(o+o,16)/255)}else if(t=e.match(/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)){for(n=0;n<3;n++)a[n]=parseInt(t[n+1],0);t[4]&&(t[5]?a[3]=.01*parseFloat(t[4]):a[3]=parseFloat(t[4]))}else{if(!(t=e.match(/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)))return(t=e.match(/^(\w+)$/))?"transparent"===t[1]?[0,0,0,0]:i.call(r,t[1])?((a=r[t[1]])[3]=1,a):null:null;for(n=0;n<3;n++)a[n]=Math.round(2.55*parseFloat(t[n+1]));t[4]&&(t[5]?a[3]=.01*parseFloat(t[4]):a[3]=parseFloat(t[4]))}for(n=0;n<3;n++)a[n]=c(a[n],0,255);return a[3]=c(a[3],0,1),a},l.get.hsl=function(e){if(!e)return null;var t=e.match(/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);if(t){var n=parseFloat(t[4]);return[(parseFloat(t[1])%360+360)%360,c(parseFloat(t[2]),0,100),c(parseFloat(t[3]),0,100),c(isNaN(n)?1:n,0,1)]}return null},l.get.hwb=function(e){if(!e)return null;var t=e.match(/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);if(t){var n=parseFloat(t[4]);return[(parseFloat(t[1])%360+360)%360,c(parseFloat(t[2]),0,100),c(parseFloat(t[3]),0,100),c(isNaN(n)?1:n,0,1)]}return null},l.to.hex=function(){var e=o(arguments);return"#"+s(e[0])+s(e[1])+s(e[2])+(e[3]<1?s(Math.round(255*e[3])):"")},l.to.rgb=function(){var e=o(arguments);return e.length<4||1===e[3]?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"},l.to.rgb.percent=function(){var e=o(arguments),t=Math.round(e[0]/255*100),n=Math.round(e[1]/255*100),r=Math.round(e[2]/255*100);return e.length<4||1===e[3]?"rgb("+t+"%, "+n+"%, "+r+"%)":"rgba("+t+"%, "+n+"%, "+r+"%, "+e[3]+")"},l.to.hsl=function(){var e=o(arguments);return e.length<4||1===e[3]?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"},l.to.hwb=function(){var e=o(arguments),t="";return e.length>=4&&1!==e[3]&&(t=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+t+")"},l.to.keyword=function(e){return a[e.slice(0,3)]}},8218:function(e,t,n){for(var r=n(43681).default,o=n(38636).default,i=n(73408).default,a=n(99843),u=n(44245),l=["keyword","gray","hex"],c={},s=0,f=Object.keys(u);s<f.length;s++){var p=f[s];c[i(u[p].labels).sort().join("")]=p}var d={};function v(e,t){if(!(this instanceof v))return new v(e,t);if(t&&t in l&&(t=null),t&&!(t in u))throw new Error("Unknown model: "+t);var n,r;if(null==e)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(e instanceof v)this.model=e.model,this.color=i(e.color),this.valpha=e.valpha;else if("string"===typeof e){var o=a.get(e);if(null===o)throw new Error("Unable to parse color from string: "+e);this.model=o.model,r=u[this.model].channels,this.color=o.value.slice(0,r),this.valpha="number"===typeof o.value[r]?o.value[r]:1}else if(e.length>0){this.model=t||"rgb",r=u[this.model].channels;var s=Array.prototype.slice.call(e,0,r);this.color=w(s,r),this.valpha="number"===typeof e[r]?e[r]:1}else if("number"===typeof e)this.model="rgb",this.color=[e>>16&255,e>>8&255,255&e],this.valpha=1;else{this.valpha=1;var f=Object.keys(e);"alpha"in e&&(f.splice(f.indexOf("alpha"),1),this.valpha="number"===typeof e.alpha?e.alpha:0);var p=f.sort().join("");if(!(p in c))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=c[p];var h=u[this.model].labels,y=[];for(n=0;n<h.length;n++)y.push(e[h[n]]);this.color=w(y)}if(d[this.model])for(r=u[this.model].channels,n=0;n<r;n++){var m=d[this.model][n];m&&(this.color[n]=m(this.color[n]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}v.prototype={toString:function(){return this.string()},toJSON:function(){return this[this.model]()},string:function(e){var t=this.model in a.to?this:this.rgb(),n=1===(t=t.round("number"===typeof e?e:1)).valpha?t.color:[].concat(i(t.color),[this.valpha]);return a.to[t.model](n)},percentString:function(e){var t=this.rgb().round("number"===typeof e?e:1),n=1===t.valpha?t.color:[].concat(i(t.color),[this.valpha]);return a.to.rgb.percent(n)},array:function(){return 1===this.valpha?i(this.color):[].concat(i(this.color),[this.valpha])},object:function(){for(var e={},t=u[this.model].channels,n=u[this.model].labels,r=0;r<t;r++)e[n[r]]=this.color[r];return 1!==this.valpha&&(e.alpha=this.valpha),e},unitArray:function(){var e=this.rgb().color;return e[0]/=255,e[1]/=255,e[2]/=255,1!==this.valpha&&e.push(this.valpha),e},unitObject:function(){var e=this.rgb().object();return e.r/=255,e.g/=255,e.b/=255,1!==this.valpha&&(e.alpha=this.valpha),e},round:function(e){return e=Math.max(e||0,0),new v([].concat(i(this.color.map(function(e){return function(t){return function(e,t){return Number(e.toFixed(t))}(t,e)}}(e))),[this.valpha]),this.model)},alpha:function(e){return void 0!==e?new v([].concat(i(this.color),[Math.max(0,Math.min(1,e))]),this.model):this.valpha},red:b("rgb",0,g(255)),green:b("rgb",1,g(255)),blue:b("rgb",2,g(255)),hue:b(["hsl","hsv","hsl","hwb","hcg"],0,(function(e){return(e%360+360)%360})),saturationl:b("hsl",1,g(100)),lightness:b("hsl",2,g(100)),saturationv:b("hsv",1,g(100)),value:b("hsv",2,g(100)),chroma:b("hcg",1,g(100)),gray:b("hcg",2,g(100)),white:b("hwb",1,g(100)),wblack:b("hwb",2,g(100)),cyan:b("cmyk",0,g(100)),magenta:b("cmyk",1,g(100)),yellow:b("cmyk",2,g(100)),black:b("cmyk",3,g(100)),x:b("xyz",0,g(95.047)),y:b("xyz",1,g(100)),z:b("xyz",2,g(108.833)),l:b("lab",0,g(100)),a:b("lab",1),b:b("lab",2),keyword:function(e){return void 0!==e?new v(e):u[this.model].keyword(this.color)},hex:function(e){return void 0!==e?new v(e):a.to.hex(this.rgb().round().color)},hexa:function(e){if(void 0!==e)return new v(e);var t=this.rgb().round().color,n=Math.round(255*this.valpha).toString(16).toUpperCase();return 1===n.length&&(n="0"+n),a.to.hex(t)+n},rgbNumber:function(){var e=this.rgb().color;return(255&e[0])<<16|(255&e[1])<<8|255&e[2]},luminosity:function(){var e,t=this.rgb().color,n=[],i=o(t.entries());try{for(i.s();!(e=i.n()).done;){var a=r(e.value,2),u=a[0],l=a[1]/255;n[u]=l<=.04045?l/12.92:Math.pow((l+.055)/1.055,2.4)}}catch(c){i.e(c)}finally{i.f()}return.2126*n[0]+.7152*n[1]+.0722*n[2]},contrast:function(e){var t=this.luminosity(),n=e.luminosity();return t>n?(t+.05)/(n+.05):(n+.05)/(t+.05)},level:function(e){var t=this.contrast(e);return t>=7?"AAA":t>=4.5?"AA":""},isDark:function(){var e=this.rgb().color;return(2126*e[0]+7152*e[1]+722*e[2])/1e4<128},isLight:function(){return!this.isDark()},negate:function(){for(var e=this.rgb(),t=0;t<3;t++)e.color[t]=255-e.color[t];return e},lighten:function(e){var t=this.hsl();return t.color[2]+=t.color[2]*e,t},darken:function(e){var t=this.hsl();return t.color[2]-=t.color[2]*e,t},saturate:function(e){var t=this.hsl();return t.color[1]+=t.color[1]*e,t},desaturate:function(e){var t=this.hsl();return t.color[1]-=t.color[1]*e,t},whiten:function(e){var t=this.hwb();return t.color[1]+=t.color[1]*e,t},blacken:function(e){var t=this.hwb();return t.color[2]+=t.color[2]*e,t},grayscale:function(){var e=this.rgb().color,t=.3*e[0]+.59*e[1]+.11*e[2];return v.rgb(t,t,t)},fade:function(e){return this.alpha(this.valpha-this.valpha*e)},opaquer:function(e){return this.alpha(this.valpha+this.valpha*e)},rotate:function(e){var t=this.hsl(),n=t.color[0];return n=(n=(n+e)%360)<0?360+n:n,t.color[0]=n,t},mix:function(e,t){if(!e||!e.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e);var n=e.rgb(),r=this.rgb(),o=void 0===t?.5:t,i=2*o-1,a=n.alpha()-r.alpha(),u=((i*a===-1?i:(i+a)/(1+i*a))+1)/2,l=1-u;return v.rgb(u*n.red()+l*r.red(),u*n.green()+l*r.green(),u*n.blue()+l*r.blue(),n.alpha()*o+r.alpha()*(1-o))}};for(var h=function(){var e=m[y];if(l.includes(e))return"continue";var t=u[e].channels;v.prototype[e]=function(){if(this.model===e)return new v(this);for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return n.length>0?new v(n,e):new v([].concat(i(O(u[this.model][e].raw(this.color))),[this.valpha]),e)},v[e]=function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];var i=r[0];return"number"===typeof i&&(i=w(r,t)),new v(i,e)}},y=0,m=Object.keys(u);y<m.length;y++)h();function b(e,t,n){e=Array.isArray(e)?e:[e];var r,i=o(e);try{for(i.s();!(r=i.n()).done;){var a=r.value;(d[a]||(d[a]=[]))[t]=n}}catch(u){i.e(u)}finally{i.f()}return e=e[0],function(r){var o;return void 0!==r?(n&&(r=n(r)),(o=this[e]()).color[t]=r,o):(o=this[e]().color[t],n&&(o=n(o)),o)}}function g(e){return function(t){return Math.max(0,Math.min(e,t))}}function O(e){return Array.isArray(e)?e:[e]}function w(e,t){for(var n=0;n<t;n++)"number"!==typeof e[n]&&(e[n]=0);return e}e.exports=v},97090:function(e,t,n){for(var r=n(43681).default,o=n(38752),i={},a=0,u=Object.keys(o);a<u.length;a++){var l=u[a];i[o[l]]=l}var c={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};e.exports=c;for(var s=0,f=Object.keys(c);s<f.length;s++){var p=f[s];if(!("channels"in c[p]))throw new Error("missing channels property: "+p);if(!("labels"in c[p]))throw new Error("missing channel labels property: "+p);if(c[p].labels.length!==c[p].channels)throw new Error("channel and label counts mismatch: "+p);var d=c[p],v=d.channels,h=d.labels;delete c[p].channels,delete c[p].labels,Object.defineProperty(c[p],"channels",{value:v}),Object.defineProperty(c[p],"labels",{value:h})}c.rgb.hsl=function(e){var t,n=e[0]/255,r=e[1]/255,o=e[2]/255,i=Math.min(n,r,o),a=Math.max(n,r,o),u=a-i;a===i?t=0:n===a?t=(r-o)/u:r===a?t=2+(o-n)/u:o===a&&(t=4+(n-r)/u),(t=Math.min(60*t,360))<0&&(t+=360);var l=(i+a)/2;return[t,100*(a===i?0:l<=.5?u/(a+i):u/(2-a-i)),100*l]},c.rgb.hsv=function(e){var t,n,r,o,i,a=e[0]/255,u=e[1]/255,l=e[2]/255,c=Math.max(a,u,l),s=c-Math.min(a,u,l),f=function(e){return(c-e)/6/s+.5};return 0===s?(o=0,i=0):(i=s/c,t=f(a),n=f(u),r=f(l),a===c?o=r-n:u===c?o=1/3+t-r:l===c&&(o=2/3+n-t),o<0?o+=1:o>1&&(o-=1)),[360*o,100*i,100*c]},c.rgb.hwb=function(e){var t=e[0],n=e[1],r=e[2];return[c.rgb.hsl(e)[0],100*(1/255*Math.min(t,Math.min(n,r))),100*(r=1-1/255*Math.max(t,Math.max(n,r)))]},c.rgb.cmyk=function(e){var t=e[0]/255,n=e[1]/255,r=e[2]/255,o=Math.min(1-t,1-n,1-r);return[100*((1-t-o)/(1-o)||0),100*((1-n-o)/(1-o)||0),100*((1-r-o)/(1-o)||0),100*o]},c.rgb.keyword=function(e){var t=i[e];if(t)return t;for(var n,r,a,u=1/0,l=0,c=Object.keys(o);l<c.length;l++){var s=c[l],f=o[s],p=(r=e,a=f,Math.pow(r[0]-a[0],2)+Math.pow(r[1]-a[1],2)+Math.pow(r[2]-a[2],2));p<u&&(u=p,n=s)}return n},c.keyword.rgb=function(e){return o[e]},c.rgb.xyz=function(e){var t=e[0]/255,n=e[1]/255,r=e[2]/255;return[100*(.4124*(t=t>.04045?Math.pow((t+.055)/1.055,2.4):t/12.92)+.3576*(n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92)+.1805*(r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92)),100*(.2126*t+.7152*n+.0722*r),100*(.0193*t+.1192*n+.9505*r)]},c.rgb.lab=function(e){var t=c.rgb.xyz(e),n=t[0],r=t[1],o=t[2];return r/=100,o/=108.883,n=(n/=95.047)>.008856?Math.pow(n,1/3):7.787*n+16/116,[116*(r=r>.008856?Math.pow(r,1/3):7.787*r+16/116)-16,500*(n-r),200*(r-(o=o>.008856?Math.pow(o,1/3):7.787*o+16/116))]},c.hsl.rgb=function(e){var t,n,r,o=e[0]/360,i=e[1]/100,a=e[2]/100;if(0===i)return[r=255*a,r,r];for(var u=2*a-(t=a<.5?a*(1+i):a+i-a*i),l=[0,0,0],c=0;c<3;c++)(n=o+1/3*-(c-1))<0&&n++,n>1&&n--,r=6*n<1?u+6*(t-u)*n:2*n<1?t:3*n<2?u+(t-u)*(2/3-n)*6:u,l[c]=255*r;return l},c.hsl.hsv=function(e){var t=e[0],n=e[1]/100,r=e[2]/100,o=n,i=Math.max(r,.01);return n*=(r*=2)<=1?r:2-r,o*=i<=1?i:2-i,[t,100*(0===r?2*o/(i+o):2*n/(r+n)),100*((r+n)/2)]},c.hsv.rgb=function(e){var t=e[0]/60,n=e[1]/100,r=e[2]/100,o=Math.floor(t)%6,i=t-Math.floor(t),a=255*r*(1-n),u=255*r*(1-n*i),l=255*r*(1-n*(1-i));switch(r*=255,o){case 0:return[r,l,a];case 1:return[u,r,a];case 2:return[a,r,l];case 3:return[a,u,r];case 4:return[l,a,r];case 5:return[r,a,u]}},c.hsv.hsl=function(e){var t,n,r=e[0],o=e[1]/100,i=e[2]/100,a=Math.max(i,.01);n=(2-o)*i;var u=(2-o)*a;return t=o*a,[r,100*(t=(t/=u<=1?u:2-u)||0),100*(n/=2)]},c.hwb.rgb=function(e){var t,n=e[0]/360,r=e[1]/100,o=e[2]/100,i=r+o;i>1&&(r/=i,o/=i);var a=Math.floor(6*n),u=1-o;t=6*n-a,0!==(1&a)&&(t=1-t);var l,c,s,f=r+t*(u-r);switch(a){default:case 6:case 0:l=u,c=f,s=r;break;case 1:l=f,c=u,s=r;break;case 2:l=r,c=u,s=f;break;case 3:l=r,c=f,s=u;break;case 4:l=f,c=r,s=u;break;case 5:l=u,c=r,s=f}return[255*l,255*c,255*s]},c.cmyk.rgb=function(e){var t=e[0]/100,n=e[1]/100,r=e[2]/100,o=e[3]/100;return[255*(1-Math.min(1,t*(1-o)+o)),255*(1-Math.min(1,n*(1-o)+o)),255*(1-Math.min(1,r*(1-o)+o))]},c.xyz.rgb=function(e){var t,n,r,o=e[0]/100,i=e[1]/100,a=e[2]/100;return n=-.9689*o+1.8758*i+.0415*a,r=.0557*o+-.204*i+1.057*a,t=(t=3.2406*o+-1.5372*i+-.4986*a)>.0031308?1.055*Math.pow(t,1/2.4)-.055:12.92*t,n=n>.0031308?1.055*Math.pow(n,1/2.4)-.055:12.92*n,r=r>.0031308?1.055*Math.pow(r,1/2.4)-.055:12.92*r,[255*(t=Math.min(Math.max(0,t),1)),255*(n=Math.min(Math.max(0,n),1)),255*(r=Math.min(Math.max(0,r),1))]},c.xyz.lab=function(e){var t=e[0],n=e[1],r=e[2];return n/=100,r/=108.883,t=(t/=95.047)>.008856?Math.pow(t,1/3):7.787*t+16/116,[116*(n=n>.008856?Math.pow(n,1/3):7.787*n+16/116)-16,500*(t-n),200*(n-(r=r>.008856?Math.pow(r,1/3):7.787*r+16/116))]},c.lab.xyz=function(e){var t,n,r,o=e[0];t=e[1]/500+(n=(o+16)/116),r=n-e[2]/200;var i=Math.pow(n,3),a=Math.pow(t,3),u=Math.pow(r,3);return n=i>.008856?i:(n-16/116)/7.787,t=a>.008856?a:(t-16/116)/7.787,r=u>.008856?u:(r-16/116)/7.787,[t*=95.047,n*=100,r*=108.883]},c.lab.lch=function(e){var t,n=e[0],r=e[1],o=e[2];return(t=360*Math.atan2(o,r)/2/Math.PI)<0&&(t+=360),[n,Math.sqrt(r*r+o*o),t]},c.lch.lab=function(e){var t=e[0],n=e[1],r=e[2]/360*2*Math.PI;return[t,n*Math.cos(r),n*Math.sin(r)]},c.rgb.ansi16=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=r(e,3),o=n[0],i=n[1],a=n[2],u=null===t?c.rgb.hsv(e)[2]:t;if(0===(u=Math.round(u/50)))return 30;var l=30+(Math.round(a/255)<<2|Math.round(i/255)<<1|Math.round(o/255));return 2===u&&(l+=60),l},c.hsv.ansi16=function(e){return c.rgb.ansi16(c.hsv.rgb(e),e[2])},c.rgb.ansi256=function(e){var t=e[0],n=e[1],r=e[2];return t===n&&n===r?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5)},c.ansi16.rgb=function(e){var t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),[t=t/10.5*255,t,t];var n=.5*(1+~~(e>50));return[(1&t)*n*255,(t>>1&1)*n*255,(t>>2&1)*n*255]},c.ansi256.rgb=function(e){if(e>=232){var t=10*(e-232)+8;return[t,t,t]}var n;return e-=16,[Math.floor(e/36)/5*255,Math.floor((n=e%36)/6)/5*255,n%6/5*255]},c.rgb.hex=function(e){var t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".substring(t.length)+t},c.hex.rgb=function(e){var t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];var n=t[0];3===t[0].length&&(n=n.split("").map((function(e){return e+e})).join(""));var r=parseInt(n,16);return[r>>16&255,r>>8&255,255&r]},c.rgb.hcg=function(e){var t,n=e[0]/255,r=e[1]/255,o=e[2]/255,i=Math.max(Math.max(n,r),o),a=Math.min(Math.min(n,r),o),u=i-a;return t=u<=0?0:i===n?(r-o)/u%6:i===r?2+(o-n)/u:4+(n-r)/u,t/=6,[360*(t%=1),100*u,100*(u<1?a/(1-u):0)]},c.hsl.hcg=function(e){var t=e[1]/100,n=e[2]/100,r=n<.5?2*t*n:2*t*(1-n),o=0;return r<1&&(o=(n-.5*r)/(1-r)),[e[0],100*r,100*o]},c.hsv.hcg=function(e){var t=e[1]/100,n=e[2]/100,r=t*n,o=0;return r<1&&(o=(n-r)/(1-r)),[e[0],100*r,100*o]},c.hcg.rgb=function(e){var t=e[0]/360,n=e[1]/100,r=e[2]/100;if(0===n)return[255*r,255*r,255*r];var o,i=[0,0,0],a=t%1*6,u=a%1,l=1-u;switch(Math.floor(a)){case 0:i[0]=1,i[1]=u,i[2]=0;break;case 1:i[0]=l,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=u;break;case 3:i[0]=0,i[1]=l,i[2]=1;break;case 4:i[0]=u,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=l}return o=(1-n)*r,[255*(n*i[0]+o),255*(n*i[1]+o),255*(n*i[2]+o)]},c.hcg.hsv=function(e){var t=e[1]/100,n=t+e[2]/100*(1-t),r=0;return n>0&&(r=t/n),[e[0],100*r,100*n]},c.hcg.hsl=function(e){var t=e[1]/100,n=e[2]/100*(1-t)+.5*t,r=0;return n>0&&n<.5?r=t/(2*n):n>=.5&&n<1&&(r=t/(2*(1-n))),[e[0],100*r,100*n]},c.hcg.hwb=function(e){var t=e[1]/100,n=t+e[2]/100*(1-t);return[e[0],100*(n-t),100*(1-n)]},c.hwb.hcg=function(e){var t=e[1]/100,n=1-e[2]/100,r=n-t,o=0;return r<1&&(o=(n-r)/(1-r)),[e[0],100*r,100*o]},c.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},c.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},c.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},c.gray.hsl=function(e){return[0,0,e[0]]},c.gray.hsv=c.gray.hsl,c.gray.hwb=function(e){return[0,100,e[0]]},c.gray.cmyk=function(e){return[0,0,0,e[0]]},c.gray.lab=function(e){return[e[0],0,0]},c.gray.hex=function(e){var t=255&Math.round(e[0]/100*255),n=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(n.length)+n},c.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}},44245:function(e,t,n){var r=n(97090),o=n(28211),i={};Object.keys(r).forEach((function(e){i[e]={},Object.defineProperty(i[e],"channels",{value:r[e].channels}),Object.defineProperty(i[e],"labels",{value:r[e].labels});var t=o(e);Object.keys(t).forEach((function(n){var r=t[n];i[e][n]=function(e){var t=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=n[0];if(void 0===o||null===o)return o;o.length>1&&(n=o);var i=e(n);if("object"===typeof i)for(var a=i.length,u=0;u<a;u++)i[u]=Math.round(i[u]);return i};return"conversion"in e&&(t.conversion=e.conversion),t}(r),i[e][n].raw=function(e){var t=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=n[0];return void 0===o||null===o?o:(o.length>1&&(n=o),e(n))};return"conversion"in e&&(t.conversion=e.conversion),t}(r)}))})),e.exports=i},28211:function(e,t,n){var r=n(97090);function o(e){var t=function(){for(var e={},t=Object.keys(r),n=t.length,o=0;o<n;o++)e[t[o]]={distance:-1,parent:null};return e}(),n=[e];for(t[e].distance=0;n.length;)for(var o=n.pop(),i=Object.keys(r[o]),a=i.length,u=0;u<a;u++){var l=i[u],c=t[l];-1===c.distance&&(c.distance=t[o].distance+1,c.parent=o,n.unshift(l))}return t}function i(e,t){return function(n){return t(e(n))}}function a(e,t){for(var n=[t[e].parent,e],o=r[t[e].parent][e],a=t[e].parent;t[a].parent;)n.unshift(t[a].parent),o=i(r[t[a].parent][a],o),a=t[a].parent;return o.conversion=n,o}e.exports=function(e){for(var t=o(e),n={},r=Object.keys(t),i=r.length,u=0;u<i;u++){var l=r[u];null!==t[l].parent&&(n[l]=a(l,t))}return n}},11257:function(e,t,n){var r=/^\s+|\s+$/g,o=/^[-+]0x[0-9a-f]+$/i,i=/^0b[01]+$/i,a=/^0o[0-7]+$/i,u=parseInt,l="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,c="object"==typeof self&&self&&self.Object===Object&&self,s=l||c||Function("return this")(),f=Object.prototype.toString,p=Math.max,d=Math.min,v=function(){return s.Date.now()};function h(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function y(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==f.call(e)}(e))return NaN;if(h(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=h(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(r,"");var n=i.test(e);return n||a.test(e)?u(e.slice(2),n?2:8):o.test(e)?NaN:+e}e.exports=function(e,t,n){var r,o,i,a,u,l,c=0,s=!1,f=!1,m=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function b(t){var n=r,i=o;return r=o=void 0,c=t,a=e.apply(i,n)}function g(e){return c=e,u=setTimeout(w,t),s?b(e):a}function O(e){var n=e-l;return void 0===l||n>=t||n<0||f&&e-c>=i}function w(){var e=v();if(O(e))return j(e);u=setTimeout(w,function(e){var n=t-(e-l);return f?d(n,i-(e-c)):n}(e))}function j(e){return u=void 0,m&&r?b(e):(r=o=void 0,a)}function _(){var e=v(),n=O(e);if(r=arguments,o=this,l=e,n){if(void 0===u)return g(l);if(f)return u=setTimeout(w,t),b(l)}return void 0===u&&(u=setTimeout(w,t)),a}return t=y(t)||0,h(n)&&(s=!!n.leading,i=(f="maxWait"in n)?p(y(n.maxWait)||0,t):i,m="trailing"in n?!!n.trailing:m),_.cancel=function(){void 0!==u&&clearTimeout(u),c=0,r=l=o=u=void 0},_.flush=function(){return void 0===u?a:j(v())},_}},66483:function(e,t,n){var r="Expected a function",o=/^\s+|\s+$/g,i=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,u=/^0o[0-7]+$/i,l=parseInt,c="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,s="object"==typeof self&&self&&self.Object===Object&&self,f=c||s||Function("return this")(),p=Object.prototype.toString,d=Math.max,v=Math.min,h=function(){return f.Date.now()};function y(e,t,n){var o,i,a,u,l,c,s=0,f=!1,p=!1,y=!0;if("function"!=typeof e)throw new TypeError(r);function g(t){var n=o,r=i;return o=i=void 0,s=t,u=e.apply(r,n)}function O(e){return s=e,l=setTimeout(j,t),f?g(e):u}function w(e){var n=e-c;return void 0===c||n>=t||n<0||p&&e-s>=a}function j(){var e=h();if(w(e))return _(e);l=setTimeout(j,function(e){var n=t-(e-c);return p?v(n,a-(e-s)):n}(e))}function _(e){return l=void 0,y&&o?g(e):(o=i=void 0,u)}function P(){var e=h(),n=w(e);if(o=arguments,i=this,c=e,n){if(void 0===l)return O(c);if(p)return l=setTimeout(j,t),g(c)}return void 0===l&&(l=setTimeout(j,t)),u}return t=b(t)||0,m(n)&&(f=!!n.leading,a=(p="maxWait"in n)?d(b(n.maxWait)||0,t):a,y="trailing"in n?!!n.trailing:y),P.cancel=function(){void 0!==l&&clearTimeout(l),s=0,o=c=i=l=void 0},P.flush=function(){return void 0===l?u:_(h())},P}function m(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function b(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==p.call(e)}(e))return NaN;if(m(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=m(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(o,"");var n=a.test(e);return n||u.test(e)?l(e.slice(2),n?2:8):i.test(e)?NaN:+e}e.exports=function(e,t,n){var o=!0,i=!0;if("function"!=typeof e)throw new TypeError(r);return m(n)&&(o="leading"in n?!!n.leading:o,i="trailing"in n?!!n.trailing:i),y(e,t,{leading:o,maxWait:t,trailing:i})}},3578:function(e,t,n){var r=n(78770),o=n(49756);e.exports=function(e,t,n,i){return null==e?[]:(o(t)||(t=null==t?[]:[t]),o(n=i?void 0:n)||(n=null==n?[]:[n]),r(e,t,n))}},1615:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return u}});var r=n(30969),o=[0];function i(){return i=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},i.apply(this,arguments)}function a(e){var t,n=function(e){var t,n,i=null!=(t=null==e?void 0:e.rootMargin)?t:"0px",a=null!=(n=null==e?void 0:e.threshold)?n:o,u=(0,r.useRef)(null),l=(0,r.useRef)(null),c=(0,r.useRef)(null),s=(0,r.useState)(),f=s[0],p=s[1],d=(0,r.useCallback)((function(){var e=c.current;null==e||e.disconnect(),c.current=null}),[]),v=(0,r.useCallback)((function(){var e=u.current;if(e){var t=l.current,n=new IntersectionObserver((function(e){var t=e[0];p(t)}),{root:t,rootMargin:i,threshold:a});n.observe(e),c.current=n}}),[i,a]),h=(0,r.useCallback)((function(){d(),v()}),[v,d]),y=(0,r.useCallback)((function(e){u.current=e,h()}),[h]),m=(0,r.useCallback)((function(e){l.current=e,h()}),[h]);return(0,r.useEffect)((function(){return h(),function(){d()}}),[h,d]),[y,{entry:f,rootRef:m}]}(e),a=n[0],u=n[1],l=Boolean(null==(t=u.entry)?void 0:t.isIntersecting),c=(0,r.useState)(l),s=c[0],f=c[1];return(0,r.useEffect)((function(){l&&f(l)}),[l]),[a,i({},u,{isVisible:l,wasEverVisible:s})]}var u=function(e){var t=e.loading,n=e.hasNextPage,o=e.onLoadMore,i=e.rootMargin,u=e.disabled,l=e.delayInMs,c=void 0===l?100:l,s=a({rootMargin:i}),f=s[0],p=s[1],d=p.rootRef,v=p.isVisible,h=!u&&!t&&v&&n;return(0,r.useEffect)((function(){if(h){var e=setTimeout((function(){o()}),c);return function(){clearTimeout(e)}}}),[o,h,c]),[f,{rootRef:d}]}},2637:function(e,t,n){"use strict";var r=n(77343),o=Array.prototype.concat,i=Array.prototype.slice,a=e.exports=function(e){for(var t=[],n=0,a=e.length;n<a;n++){var u=e[n];r(u)?t=o.call(t,i.call(u)):t.push(u)}return t};a.wrap=function(e){return function(){return e(a(arguments))}}},77343:function(e){e.exports=function(e){return!(!e||"string"===typeof e)&&(e instanceof Array||Array.isArray(e)||e.length>=0&&(e.splice instanceof Function||Object.getOwnPropertyDescriptor(e,e.length-1)&&"String"!==e.constructor.name))}},58089:function(e,t,n){"use strict";n.r(t),t.default={}}}]);
2
+ //# sourceMappingURL=976.b5206735.chunk.js.map