unleash-server 4.22.0-beta.2 → 4.22.0-beta.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/addons/feature-event-formatter-md.d.ts +12 -3
- package/dist/lib/addons/feature-event-formatter-md.js +135 -31
- package/dist/lib/addons/feature-event-formatter-md.js.map +1 -1
- package/dist/lib/addons/feature-event-formatter-md.test.d.ts +1 -0
- package/dist/lib/addons/feature-event-formatter-md.test.js +483 -0
- package/dist/lib/addons/feature-event-formatter-md.test.js.map +1 -0
- package/dist/lib/app.js +1 -1
- package/dist/lib/app.js.map +1 -1
- package/dist/lib/features/export-import-toggles/export-import-permissions.e2e.test.js +1 -1
- package/dist/lib/features/export-import-toggles/export-import-permissions.e2e.test.js.map +1 -1
- package/dist/lib/openapi/index.d.ts +46 -6
- package/dist/lib/openapi/spec/bulk-metrics-schema.d.ts +23 -3
- package/dist/lib/openapi/spec/bulk-registration-schema.d.ts +23 -3
- package/dist/lib/openapi/spec/bulk-registration-schema.js +15 -3
- package/dist/lib/openapi/spec/bulk-registration-schema.js.map +1 -1
- package/dist/lib/routes/admin-api/maintenance.d.ts +0 -1
- package/dist/lib/routes/admin-api/maintenance.js +0 -8
- package/dist/lib/routes/admin-api/maintenance.js.map +1 -1
- package/dist/lib/routes/admin-api/project/variants.js +29 -0
- package/dist/lib/routes/admin-api/project/variants.js.map +1 -1
- package/dist/lib/services/access-service.d.ts +2 -2
- package/dist/lib/services/access-service.js.map +1 -1
- package/dist/lib/types/experimental.d.ts +1 -2
- package/dist/lib/types/experimental.js +1 -2
- package/dist/lib/types/experimental.js.map +1 -1
- package/dist/migrations/20201216140726-add-last-seen-to-features.js +1 -0
- package/dist/migrations/20201216140726-add-last-seen-to-features.js.map +1 -1
- package/dist/migrations/20210105083014-add-tag-and-tag-types.js +1 -0
- package/dist/migrations/20210105083014-add-tag-and-tag-types.js.map +1 -1
- package/dist/migrations/20210119084617-add-addon-table.js +1 -0
- package/dist/migrations/20210119084617-add-addon-table.js.map +1 -1
- package/dist/migrations/20210212114759-add-session-table.js +1 -0
- package/dist/migrations/20210212114759-add-session-table.js.map +1 -1
- package/dist/migrations/20210217195834-rbac-tables.js +1 -0
- package/dist/migrations/20210217195834-rbac-tables.js.map +1 -1
- package/dist/migrations/20210409120136-create-reset-token-table.js +1 -0
- package/dist/migrations/20210409120136-create-reset-token-table.js.map +1 -1
- package/dist/migrations/20210414141220-fix-misspellings-in-role-descriptions.js +1 -0
- package/dist/migrations/20210414141220-fix-misspellings-in-role-descriptions.js.map +1 -1
- package/dist/migrations/20210423103647-lowercase-all-emails.js +1 -0
- package/dist/migrations/20210423103647-lowercase-all-emails.js.map +1 -1
- package/dist/migrations/20210428103923-onboard-projects-to-rbac.js +1 -0
- package/dist/migrations/20210428103923-onboard-projects-to-rbac.js.map +1 -1
- package/dist/migrations/20210504101429-deprecate-strategies.js +1 -0
- package/dist/migrations/20210504101429-deprecate-strategies.js.map +1 -1
- package/dist/migrations/20210615115226-migrate-strategies-to-feature-strategies.js +1 -0
- package/dist/migrations/20210615115226-migrate-strategies-to-feature-strategies.js.map +1 -1
- package/dist/migrations/20210618091331-project-environments-table.js +1 -0
- package/dist/migrations/20210618091331-project-environments-table.js.map +1 -1
- package/dist/migrations/20210618100913-add-cascade-for-user-feedback.js +1 -0
- package/dist/migrations/20210618100913-add-cascade-for-user-feedback.js.map +1 -1
- package/dist/migrations/20210624114855-drop-strategies-column-from-features.js +1 -0
- package/dist/migrations/20210624114855-drop-strategies-column-from-features.js.map +1 -1
- package/dist/migrations/20210624115109-drop-enabled-column-from-features.js +1 -0
- package/dist/migrations/20210624115109-drop-enabled-column-from-features.js.map +1 -1
- package/dist/migrations/20210625102126-connect-default-project-to-global-environment.js +1 -0
- package/dist/migrations/20210625102126-connect-default-project-to-global-environment.js.map +1 -1
- package/dist/migrations/20210629130734-add-health-rating-to-project.js +1 -0
- package/dist/migrations/20210629130734-add-health-rating-to-project.js.map +1 -1
- package/dist/migrations/20210830113948-connect-projects-to-global-envrionments.js +1 -0
- package/dist/migrations/20210830113948-connect-projects-to-global-envrionments.js.map +1 -1
- package/dist/migrations/20210831072631-add-sort-order-and-type-to-env.js +1 -0
- package/dist/migrations/20210831072631-add-sort-order-and-type-to-env.js.map +1 -1
- package/dist/migrations/20210907124058-add-dbcritic-indices.js +1 -0
- package/dist/migrations/20210907124058-add-dbcritic-indices.js.map +1 -1
- package/dist/migrations/20210907124850-add-dbcritic-primary-keys.js +1 -0
- package/dist/migrations/20210907124850-add-dbcritic-primary-keys.js.map +1 -1
- package/dist/migrations/20210908100701-add-enabled-to-environments.js +1 -0
- package/dist/migrations/20210908100701-add-enabled-to-environments.js.map +1 -1
- package/dist/migrations/20210909085651-add-protected-field-to-environments.js +1 -0
- package/dist/migrations/20210909085651-add-protected-field-to-environments.js.map +1 -1
- package/dist/migrations/20210913103159-api-keys-scoping.js +1 -0
- package/dist/migrations/20210913103159-api-keys-scoping.js.map +1 -1
- package/dist/migrations/20210928082228-connect-default-environment-to-all-existing-projects.js +1 -0
- package/dist/migrations/20210928082228-connect-default-environment-to-all-existing-projects.js.map +1 -1
- package/dist/migrations/20211004104917-client-metrics-env.js +1 -0
- package/dist/migrations/20211004104917-client-metrics-env.js.map +1 -1
- package/dist/migrations/20211109103930-add-splash-entry-for-users.js +1 -0
- package/dist/migrations/20211109103930-add-splash-entry-for-users.js.map +1 -1
- package/dist/migrations/20211126112551-disable-default-environment.js +1 -0
- package/dist/migrations/20211126112551-disable-default-environment.js.map +1 -1
- package/dist/migrations/20211202120808-add-custom-roles.js +1 -0
- package/dist/migrations/20211202120808-add-custom-roles.js.map +1 -1
- package/dist/migrations/20220103134659-add-permissions-to-project-roles.js +1 -0
- package/dist/migrations/20220103134659-add-permissions-to-project-roles.js.map +1 -1
- package/dist/migrations/20220103143843-add-permissions-to-editor-role.js +1 -0
- package/dist/migrations/20220103143843-add-permissions-to-editor-role.js.map +1 -1
- package/dist/migrations/20220111112804-update-permission-descriptions.js +1 -0
- package/dist/migrations/20220111112804-update-permission-descriptions.js.map +1 -1
- package/dist/migrations/20220111115613-move-feature-toggle-permission.js +1 -0
- package/dist/migrations/20220111115613-move-feature-toggle-permission.js.map +1 -1
- package/dist/migrations/20220111120346-roles-unique-name.js +1 -0
- package/dist/migrations/20220111120346-roles-unique-name.js.map +1 -1
- package/dist/migrations/20220111121010-update-project-for-editor-role.js +1 -0
- package/dist/migrations/20220111121010-update-project-for-editor-role.js.map +1 -1
- package/dist/migrations/20220111125620-role-permission-empty-string-for-non-environment-type.js +1 -0
- package/dist/migrations/20220111125620-role-permission-empty-string-for-non-environment-type.js.map +1 -1
- package/dist/migrations/20220224081422-remove-project-column-from-roles.js +1 -0
- package/dist/migrations/20220224081422-remove-project-column-from-roles.js.map +1 -1
- package/dist/migrations/20220408081222-clean-up-duplicate-foreign-key-role-permission.js +1 -0
- package/dist/migrations/20220408081222-clean-up-duplicate-foreign-key-role-permission.js.map +1 -1
- package/dist/migrations/20220711084613-add-projects-and-environments-for-addons.js +1 -0
- package/dist/migrations/20220711084613-add-projects-and-environments-for-addons.js.map +1 -1
- package/dist/migrations/20220808110415-add-projects-foreign-key.js +1 -0
- package/dist/migrations/20220808110415-add-projects-foreign-key.js.map +1 -1
- package/dist/migrations/20221108114358-add-change-request-permissions.js +1 -0
- package/dist/migrations/20221108114358-add-change-request-permissions.js.map +1 -1
- package/dist/migrations/20221125185244-change-request-unique-approvals.js +1 -0
- package/dist/migrations/20221125185244-change-request-unique-approvals.js.map +1 -1
- package/dist/migrations/20221128165141-change-request-min-approvals.js +1 -0
- package/dist/migrations/20221128165141-change-request-min-approvals.js.map +1 -1
- package/dist/migrations/20221205122253-skip-change-request.js +1 -0
- package/dist/migrations/20221205122253-skip-change-request.js.map +1 -1
- package/dist/migrations/20221220160345-user-pat-permissions.js +1 -0
- package/dist/migrations/20221220160345-user-pat-permissions.js.map +1 -1
- package/dist/migrations/20221221144132-service-account-users.js +1 -0
- package/dist/migrations/20221221144132-service-account-users.js.map +1 -1
- package/dist/migrations/20230125065315-project-stats-table.js +1 -0
- package/dist/migrations/20230125065315-project-stats-table.js.map +1 -1
- package/dist/migrations/20230127111638-new-project-stats-field.js +1 -0
- package/dist/migrations/20230127111638-new-project-stats-field.js.map +1 -1
- package/dist/migrations/20230130113337-revert-user-pat-permissions.js +1 -0
- package/dist/migrations/20230130113337-revert-user-pat-permissions.js.map +1 -1
- package/dist/migrations/20230208084046-project-api-token-permissions.js +1 -0
- package/dist/migrations/20230208084046-project-api-token-permissions.js.map +1 -1
- package/dist/migrations/20230208093627-assign-project-api-token-permissions-editor.js +1 -0
- package/dist/migrations/20230208093627-assign-project-api-token-permissions-editor.js.map +1 -1
- package/dist/migrations/20230208093750-assign-project-api-token-permissions-owner.js +1 -0
- package/dist/migrations/20230208093750-assign-project-api-token-permissions-owner.js.map +1 -1
- package/dist/migrations/20230208093942-assign-project-api-token-permissions-member.js +1 -0
- package/dist/migrations/20230208093942-assign-project-api-token-permissions-member.js.map +1 -1
- package/dist/migrations/20230222084211-add-login-events-table.js +1 -0
- package/dist/migrations/20230222084211-add-login-events-table.js.map +1 -1
- package/dist/migrations/20230222154915-create-notiications-table.js +4 -4
- package/dist/migrations/20230224093446-drop-createdBy-from-notifications-table.d.ts +2 -0
- package/dist/migrations/20230224093446-drop-createdBy-from-notifications-table.js +14 -0
- package/dist/migrations/20230224093446-drop-createdBy-from-notifications-table.js.map +1 -0
- package/dist/migrations/20230227115320-rename-login-events-table-to-sign-on-log.d.ts +2 -0
- package/dist/migrations/20230227115320-rename-login-events-table-to-sign-on-log.js +8 -0
- package/dist/migrations/20230227115320-rename-login-events-table-to-sign-on-log.js.map +1 -0
- package/dist/migrations/20230227120500-change-display-name-for-variants-per-env-permission.d.ts +2 -0
- package/dist/migrations/20230227120500-change-display-name-for-variants-per-env-permission.js +15 -0
- package/dist/migrations/20230227120500-change-display-name-for-variants-per-env-permission.js.map +1 -0
- package/dist/migrations/20230227123106-add-setting-for-sign-on-log-retention.d.ts +2 -0
- package/dist/migrations/20230227123106-add-setting-for-sign-on-log-retention.js +8 -0
- package/dist/migrations/20230227123106-add-setting-for-sign-on-log-retention.js.map +1 -0
- package/dist/server-dev.js +0 -1
- package/dist/server-dev.js.map +1 -1
- package/dist/test/e2e/api/admin/maintenance.e2e.test.js +2 -49
- package/dist/test/e2e/api/admin/maintenance.e2e.test.js.map +1 -1
- package/dist/test/e2e/stores/setting-store.e2e.test.js +1 -1
- package/frontend/build/index.html +1 -1
- package/frontend/build/static/{CreateProject-b852657c.js → CreateProject-f7ca75e0.js} +1 -1
- package/frontend/build/static/{Error-29ef2974.js → Error-2a87926a.js} +1 -1
- package/frontend/build/static/{ExpandMore-4b3cbf87.js → ExpandMore-e298a9a3.js} +1 -1
- package/frontend/build/static/{FeatureArchiveDialog-f9d8c71d.js → FeatureArchiveDialog-31430c0e.js} +1 -1
- package/frontend/build/static/{FeatureMetricsChart-86cc2280.js → FeatureMetricsChart-bcb36dbc.js} +1 -1
- package/frontend/build/static/{FeatureViewLazyExport-1366d6bf.js → FeatureViewLazyExport-fe2a9be7.js} +2 -2
- package/frontend/build/static/{LazyAdminExport-d9800386.js → LazyAdminExport-9ff8d442.js} +13 -13
- package/frontend/build/static/{LazyProjectExport-ef4471a8.js → LazyProjectExport-644ec52e.js} +8 -8
- package/frontend/build/static/{NetworkOverview-4b90dc34.js → NetworkOverview-cecb7bdc.js} +1 -1
- package/frontend/build/static/{NetworkTraffic-c9de9d5f.js → NetworkTraffic-953679ab.js} +1 -1
- package/frontend/build/static/{Playground-ee072216.js → Playground-f8d65d33.js} +1 -1
- package/frontend/build/static/{StrategyItemContainer-b65caaa6.js → StrategyItemContainer-b3595995.js} +1 -1
- package/frontend/build/static/{chartjs-adapter-date-fns.esm-5c47f5e0.js → chartjs-adapter-date-fns.esm-ad422152.js} +7 -7
- package/frontend/build/static/{index-bbbae9a8.js → index-19ee2080.js} +1 -1
- package/frontend/build/static/index-1d8518d6.js +392 -0
- package/frontend/build/static/{index-031b8ec3.js → index-c5afb04d.js} +1 -1
- package/frontend/build/static/{unknownify-88f06eea.js → unknownify-21e26f46.js} +1 -1
- package/frontend/build/static/{useProjectRole-d8edb83e.js → useProjectRole-9a28ceaf.js} +1 -1
- package/frontend/package.json +3 -3
- package/package.json +2 -2
- package/frontend/build/static/index-193ec8c2.js +0 -392
|
@@ -0,0 +1,392 @@
|
|
|
1
|
+
var rM=Object.defineProperty;var oM=(e,t,n)=>t in e?rM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var di=(e,t,n)=>(oM(e,typeof t!="symbol"?t+"":t,n),n);function aM(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const o in r)if(o!=="default"&&!(o in e)){const a=Object.getOwnPropertyDescriptor(r,o);a&&Object.defineProperty(e,o,a.get?a:{enumerable:!0,get:()=>r[o]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}var Fa=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Ym(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function zP(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){if(this instanceof r){var o=[null];o.push.apply(o,arguments);var a=Function.bind.apply(t,o);return new a}return t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var Vd={},iM={get exports(){return Vd},set exports(e){Vd=e}},$p={};/*
|
|
2
|
+
object-assign
|
|
3
|
+
(c) Sindre Sorhus
|
|
4
|
+
@license MIT
|
|
5
|
+
*/var B2=Object.getOwnPropertySymbols,sM=Object.prototype.hasOwnProperty,lM=Object.prototype.propertyIsEnumerable;function cM(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function uM(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de",Object.getOwnPropertyNames(e)[0]==="5")return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;var r=Object.getOwnPropertyNames(t).map(function(a){return t[a]});if(r.join("")!=="0123456789")return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach(function(a){o[a]=a}),Object.keys(Object.assign({},o)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}var jP=uM()?Object.assign:function(e,t){for(var n,r=cM(e),o,a=1;a<arguments.length;a++){n=Object(arguments[a]);for(var i in n)sM.call(n,i)&&(r[i]=n[i]);if(B2){o=B2(n);for(var l=0;l<o.length;l++)lM.call(n,o[l])&&(r[o[l]]=n[o[l]])}}return r},p={},dM={get exports(){return p},set exports(e){p=e}},Qt={};/** @license React v17.0.2
|
|
6
|
+
* react.production.min.js
|
|
7
|
+
*
|
|
8
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
9
|
+
*
|
|
10
|
+
* This source code is licensed under the MIT license found in the
|
|
11
|
+
* LICENSE file in the root directory of this source tree.
|
|
12
|
+
*/var Cw=jP,Gc=60103,UP=60106;Qt.Fragment=60107;Qt.StrictMode=60108;Qt.Profiler=60114;var WP=60109,HP=60110,VP=60112;Qt.Suspense=60113;var GP=60115,qP=60116;if(typeof Symbol=="function"&&Symbol.for){var fa=Symbol.for;Gc=fa("react.element"),UP=fa("react.portal"),Qt.Fragment=fa("react.fragment"),Qt.StrictMode=fa("react.strict_mode"),Qt.Profiler=fa("react.profiler"),WP=fa("react.provider"),HP=fa("react.context"),VP=fa("react.forward_ref"),Qt.Suspense=fa("react.suspense"),GP=fa("react.memo"),qP=fa("react.lazy")}var F2=typeof Symbol=="function"&&Symbol.iterator;function pM(e){return e===null||typeof e!="object"?null:(e=F2&&e[F2]||e["@@iterator"],typeof e=="function"?e:null)}function Op(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var KP={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},YP={};function qc(e,t,n){this.props=e,this.context=t,this.refs=YP,this.updater=n||KP}qc.prototype.isReactComponent={};qc.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error(Op(85));this.updater.enqueueSetState(this,e,t,"setState")};qc.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function XP(){}XP.prototype=qc.prototype;function Ew(e,t,n){this.props=e,this.context=t,this.refs=YP,this.updater=n||KP}var Tw=Ew.prototype=new XP;Tw.constructor=Ew;Cw(Tw,qc.prototype);Tw.isPureReactComponent=!0;var kw={current:null},JP=Object.prototype.hasOwnProperty,QP={key:!0,ref:!0,__self:!0,__source:!0};function ZP(e,t,n){var r,o={},a=null,i=null;if(t!=null)for(r in t.ref!==void 0&&(i=t.ref),t.key!==void 0&&(a=""+t.key),t)JP.call(t,r)&&!QP.hasOwnProperty(r)&&(o[r]=t[r]);var l=arguments.length-2;if(l===1)o.children=n;else if(1<l){for(var c=Array(l),u=0;u<l;u++)c[u]=arguments[u+2];o.children=c}if(e&&e.defaultProps)for(r in l=e.defaultProps,l)o[r]===void 0&&(o[r]=l[r]);return{$$typeof:Gc,type:e,key:a,ref:i,props:o,_owner:kw.current}}function fM(e,t){return{$$typeof:Gc,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Aw(e){return typeof e=="object"&&e!==null&&e.$$typeof===Gc}function hM(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var z2=/\/+/g;function $y(e,t){return typeof e=="object"&&e!==null&&e.key!=null?hM(""+e.key):t.toString(36)}function yh(e,t,n,r,o){var a=typeof e;(a==="undefined"||a==="boolean")&&(e=null);var i=!1;if(e===null)i=!0;else switch(a){case"string":case"number":i=!0;break;case"object":switch(e.$$typeof){case Gc:case UP:i=!0}}if(i)return i=e,o=o(i),e=r===""?"."+$y(i,0):r,Array.isArray(o)?(n="",e!=null&&(n=e.replace(z2,"$&/")+"/"),yh(o,t,n,"",function(u){return u})):o!=null&&(Aw(o)&&(o=fM(o,n+(!o.key||i&&i.key===o.key?"":(""+o.key).replace(z2,"$&/")+"/")+e)),t.push(o)),1;if(i=0,r=r===""?".":r+":",Array.isArray(e))for(var l=0;l<e.length;l++){a=e[l];var c=r+$y(a,l);i+=yh(a,t,n,c,o)}else if(c=pM(e),typeof c=="function")for(e=c.call(e),l=0;!(a=e.next()).done;)a=a.value,c=r+$y(a,l++),i+=yh(a,t,n,c,o);else if(a==="object")throw t=""+e,Error(Op(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t));return i}function Tf(e,t,n){if(e==null)return e;var r=[],o=0;return yh(e,r,"","",function(a){return t.call(n,a,o++)}),r}function mM(e){if(e._status===-1){var t=e._result;t=t(),e._status=0,e._result=t,t.then(function(n){e._status===0&&(n=n.default,e._status=1,e._result=n)},function(n){e._status===0&&(e._status=2,e._result=n)})}if(e._status===1)return e._result;throw e._result}var eI={current:null};function _i(){var e=eI.current;if(e===null)throw Error(Op(321));return e}var gM={ReactCurrentDispatcher:eI,ReactCurrentBatchConfig:{transition:0},ReactCurrentOwner:kw,IsSomeRendererActing:{current:!1},assign:Cw};Qt.Children={map:Tf,forEach:function(e,t,n){Tf(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return Tf(e,function(){t++}),t},toArray:function(e){return Tf(e,function(t){return t})||[]},only:function(e){if(!Aw(e))throw Error(Op(143));return e}};Qt.Component=qc;Qt.PureComponent=Ew;Qt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=gM;Qt.cloneElement=function(e,t,n){if(e==null)throw Error(Op(267,e));var r=Cw({},e.props),o=e.key,a=e.ref,i=e._owner;if(t!=null){if(t.ref!==void 0&&(a=t.ref,i=kw.current),t.key!==void 0&&(o=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(c in t)JP.call(t,c)&&!QP.hasOwnProperty(c)&&(r[c]=t[c]===void 0&&l!==void 0?l[c]:t[c])}var c=arguments.length-2;if(c===1)r.children=n;else if(1<c){l=Array(c);for(var u=0;u<c;u++)l[u]=arguments[u+2];r.children=l}return{$$typeof:Gc,type:e.type,key:o,ref:a,props:r,_owner:i}};Qt.createContext=function(e,t){return t===void 0&&(t=null),e={$$typeof:HP,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider={$$typeof:WP,_context:e},e.Consumer=e};Qt.createElement=ZP;Qt.createFactory=function(e){var t=ZP.bind(null,e);return t.type=e,t};Qt.createRef=function(){return{current:null}};Qt.forwardRef=function(e){return{$$typeof:VP,render:e}};Qt.isValidElement=Aw;Qt.lazy=function(e){return{$$typeof:qP,_payload:{_status:-1,_result:e},_init:mM}};Qt.memo=function(e,t){return{$$typeof:GP,type:e,compare:t===void 0?null:t}};Qt.useCallback=function(e,t){return _i().useCallback(e,t)};Qt.useContext=function(e,t){return _i().useContext(e,t)};Qt.useDebugValue=function(){};Qt.useEffect=function(e,t){return _i().useEffect(e,t)};Qt.useImperativeHandle=function(e,t,n){return _i().useImperativeHandle(e,t,n)};Qt.useLayoutEffect=function(e,t){return _i().useLayoutEffect(e,t)};Qt.useMemo=function(e,t){return _i().useMemo(e,t)};Qt.useReducer=function(e,t,n){return _i().useReducer(e,t,n)};Qt.useRef=function(e){return _i().useRef(e)};Qt.useState=function(e){return _i().useState(e)};Qt.version="17.0.2";(function(e){e.exports=Qt})(dM);const jt=Ym(p),ul=aM({__proto__:null,default:jt},[p]);/** @license React v17.0.2
|
|
13
|
+
* react-jsx-runtime.production.min.js
|
|
14
|
+
*
|
|
15
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
16
|
+
*
|
|
17
|
+
* This source code is licensed under the MIT license found in the
|
|
18
|
+
* LICENSE file in the root directory of this source tree.
|
|
19
|
+
*/var vM=p,tI=60103;$p.Fragment=60107;if(typeof Symbol=="function"&&Symbol.for){var j2=Symbol.for;tI=j2("react.element"),$p.Fragment=j2("react.fragment")}var yM=vM.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,bM=Object.prototype.hasOwnProperty,wM={key:!0,ref:!0,__self:!0,__source:!0};function nI(e,t,n){var r,o={},a=null,i=null;n!==void 0&&(a=""+n),t.key!==void 0&&(a=""+t.key),t.ref!==void 0&&(i=t.ref);for(r in t)bM.call(t,r)&&!wM.hasOwnProperty(r)&&(o[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)o[r]===void 0&&(o[r]=t[r]);return{$$typeof:tI,type:e,key:a,ref:i,props:o,_owner:yM.current}}$p.jsx=nI;$p.jsxs=nI;(function(e){e.exports=$p})(iM);const ke=Vd.Fragment,s=Vd.jsx,T=Vd.jsxs,SM=Object.freeze(Object.defineProperty({__proto__:null,Fragment:ke,jsx:s,jsxs:T},Symbol.toStringTag,{value:"Module"}));var zr=typeof globalThis<"u"&&globalThis||typeof self<"u"&&self||typeof zr<"u"&&zr,lo={searchParams:"URLSearchParams"in zr,iterable:"Symbol"in zr&&"iterator"in Symbol,blob:"FileReader"in zr&&"Blob"in zr&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in zr,arrayBuffer:"ArrayBuffer"in zr};function xM(e){return e&&DataView.prototype.isPrototypeOf(e)}if(lo.arrayBuffer)var CM=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],EM=ArrayBuffer.isView||function(e){return e&&CM.indexOf(Object.prototype.toString.call(e))>-1};function Lp(e){if(typeof e!="string"&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(e)||e==="")throw new TypeError('Invalid character in header field name: "'+e+'"');return e.toLowerCase()}function _w(e){return typeof e!="string"&&(e=String(e)),e}function Rw(e){var t={next:function(){var n=e.shift();return{done:n===void 0,value:n}}};return lo.iterable&&(t[Symbol.iterator]=function(){return t}),t}function yr(e){this.map={},e instanceof yr?e.forEach(function(t,n){this.append(n,t)},this):Array.isArray(e)?e.forEach(function(t){this.append(t[0],t[1])},this):e&&Object.getOwnPropertyNames(e).forEach(function(t){this.append(t,e[t])},this)}yr.prototype.append=function(e,t){e=Lp(e),t=_w(t);var n=this.map[e];this.map[e]=n?n+", "+t:t};yr.prototype.delete=function(e){delete this.map[Lp(e)]};yr.prototype.get=function(e){return e=Lp(e),this.has(e)?this.map[e]:null};yr.prototype.has=function(e){return this.map.hasOwnProperty(Lp(e))};yr.prototype.set=function(e,t){this.map[Lp(e)]=_w(t)};yr.prototype.forEach=function(e,t){for(var n in this.map)this.map.hasOwnProperty(n)&&e.call(t,this.map[n],n,this)};yr.prototype.keys=function(){var e=[];return this.forEach(function(t,n){e.push(n)}),Rw(e)};yr.prototype.values=function(){var e=[];return this.forEach(function(t){e.push(t)}),Rw(e)};yr.prototype.entries=function(){var e=[];return this.forEach(function(t,n){e.push([n,t])}),Rw(e)};lo.iterable&&(yr.prototype[Symbol.iterator]=yr.prototype.entries);function Oy(e){if(e.bodyUsed)return Promise.reject(new TypeError("Already read"));e.bodyUsed=!0}function rI(e){return new Promise(function(t,n){e.onload=function(){t(e.result)},e.onerror=function(){n(e.error)}})}function TM(e){var t=new FileReader,n=rI(t);return t.readAsArrayBuffer(e),n}function kM(e){var t=new FileReader,n=rI(t);return t.readAsText(e),n}function AM(e){for(var t=new Uint8Array(e),n=new Array(t.length),r=0;r<t.length;r++)n[r]=String.fromCharCode(t[r]);return n.join("")}function U2(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function oI(){return this.bodyUsed=!1,this._initBody=function(e){this.bodyUsed=this.bodyUsed,this._bodyInit=e,e?typeof e=="string"?this._bodyText=e:lo.blob&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:lo.formData&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:lo.searchParams&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():lo.arrayBuffer&&lo.blob&&xM(e)?(this._bodyArrayBuffer=U2(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):lo.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(e)||EM(e))?this._bodyArrayBuffer=U2(e):this._bodyText=e=Object.prototype.toString.call(e):this._bodyText="",this.headers.get("content-type")||(typeof e=="string"?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):lo.searchParams&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},lo.blob&&(this.blob=function(){var e=Oy(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){if(this._bodyArrayBuffer){var e=Oy(this);return e||(ArrayBuffer.isView(this._bodyArrayBuffer)?Promise.resolve(this._bodyArrayBuffer.buffer.slice(this._bodyArrayBuffer.byteOffset,this._bodyArrayBuffer.byteOffset+this._bodyArrayBuffer.byteLength)):Promise.resolve(this._bodyArrayBuffer))}else return this.blob().then(TM)}),this.text=function(){var e=Oy(this);if(e)return e;if(this._bodyBlob)return kM(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(AM(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},lo.formData&&(this.formData=function(){return this.text().then(PM)}),this.json=function(){return this.text().then(JSON.parse)},this}var _M=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function RM(e){var t=e.toUpperCase();return _M.indexOf(t)>-1?t:e}function dl(e,t){if(!(this instanceof dl))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');t=t||{};var n=t.body;if(e instanceof dl){if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new yr(e.headers)),this.method=e.method,this.mode=e.mode,this.signal=e.signal,!n&&e._bodyInit!=null&&(n=e._bodyInit,e.bodyUsed=!0)}else this.url=String(e);if(this.credentials=t.credentials||this.credentials||"same-origin",(t.headers||!this.headers)&&(this.headers=new yr(t.headers)),this.method=RM(t.method||this.method||"GET"),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&n)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(n),(this.method==="GET"||this.method==="HEAD")&&(t.cache==="no-store"||t.cache==="no-cache")){var r=/([?&])_=[^&]*/;if(r.test(this.url))this.url=this.url.replace(r,"$1_="+new Date().getTime());else{var o=/\?/;this.url+=(o.test(this.url)?"&":"?")+"_="+new Date().getTime()}}}dl.prototype.clone=function(){return new dl(this,{body:this._bodyInit})};function PM(e){var t=new FormData;return e.trim().split("&").forEach(function(n){if(n){var r=n.split("="),o=r.shift().replace(/\+/g," "),a=r.join("=").replace(/\+/g," ");t.append(decodeURIComponent(o),decodeURIComponent(a))}}),t}function IM(e){var t=new yr,n=e.replace(/\r?\n[\t ]+/g," ");return n.split("\r").map(function(r){return r.indexOf(`
|
|
20
|
+
`)===0?r.substr(1,r.length):r}).forEach(function(r){var o=r.split(":"),a=o.shift().trim();if(a){var i=o.join(":").trim();t.append(a,i)}}),t}oI.call(dl.prototype);function Ja(e,t){if(!(this instanceof Ja))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');t||(t={}),this.type="default",this.status=t.status===void 0?200:t.status,this.ok=this.status>=200&&this.status<300,this.statusText=t.statusText===void 0?"":""+t.statusText,this.headers=new yr(t.headers),this.url=t.url||"",this._initBody(e)}oI.call(Ja.prototype);Ja.prototype.clone=function(){return new Ja(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new yr(this.headers),url:this.url})};Ja.error=function(){var e=new Ja(null,{status:0,statusText:""});return e.type="error",e};var $M=[301,302,303,307,308];Ja.redirect=function(e,t){if($M.indexOf(t)===-1)throw new RangeError("Invalid status code");return new Ja(null,{status:t,headers:{location:e}})};var qs=zr.DOMException;try{new qs}catch{qs=function(t,n){this.message=t,this.name=n;var r=Error(t);this.stack=r.stack},qs.prototype=Object.create(Error.prototype),qs.prototype.constructor=qs}function aI(e,t){return new Promise(function(n,r){var o=new dl(e,t);if(o.signal&&o.signal.aborted)return r(new qs("Aborted","AbortError"));var a=new XMLHttpRequest;function i(){a.abort()}a.onload=function(){var c={status:a.status,statusText:a.statusText,headers:IM(a.getAllResponseHeaders()||"")};c.url="responseURL"in a?a.responseURL:c.headers.get("X-Request-URL");var u="response"in a?a.response:a.responseText;setTimeout(function(){n(new Ja(u,c))},0)},a.onerror=function(){setTimeout(function(){r(new TypeError("Network request failed"))},0)},a.ontimeout=function(){setTimeout(function(){r(new TypeError("Network request failed"))},0)},a.onabort=function(){setTimeout(function(){r(new qs("Aborted","AbortError"))},0)};function l(c){try{return c===""&&zr.location.href?zr.location.href:c}catch{return c}}a.open(o.method,l(o.url),!0),o.credentials==="include"?a.withCredentials=!0:o.credentials==="omit"&&(a.withCredentials=!1),"responseType"in a&&(lo.blob?a.responseType="blob":lo.arrayBuffer&&o.headers.get("Content-Type")&&o.headers.get("Content-Type").indexOf("application/octet-stream")!==-1&&(a.responseType="arraybuffer")),t&&typeof t.headers=="object"&&!(t.headers instanceof yr)?Object.getOwnPropertyNames(t.headers).forEach(function(c){a.setRequestHeader(c,_w(t.headers[c]))}):o.headers.forEach(function(c,u){a.setRequestHeader(u,c)}),o.signal&&(o.signal.addEventListener("abort",i),a.onreadystatechange=function(){a.readyState===4&&o.signal.removeEventListener("abort",i)}),a.send(typeof o._bodyInit>"u"?null:o._bodyInit)})}aI.polyfill=!0;zr.fetch||(zr.fetch=aI,zr.Headers=yr,zr.Request=dl,zr.Response=Ja);var W2={},OM={get exports(){return W2},set exports(e){W2=e}};(function(e){var t=function(n){var r=Object.prototype,o=r.hasOwnProperty,a=Object.defineProperty||function(W,z,R){W[z]=R.value},i,l=typeof Symbol=="function"?Symbol:{},c=l.iterator||"@@iterator",u=l.asyncIterator||"@@asyncIterator",d=l.toStringTag||"@@toStringTag";function f(W,z,R){return Object.defineProperty(W,z,{value:R,enumerable:!0,configurable:!0,writable:!0}),W[z]}try{f({},"")}catch{f=function(z,R,M){return z[R]=M}}function h(W,z,R,M){var ee=z&&z.prototype instanceof x?z:x,re=Object.create(ee.prototype),Se=new V(M||[]);return a(re,"_invoke",{value:D(W,R,Se)}),re}n.wrap=h;function m(W,z,R){try{return{type:"normal",arg:W.call(z,R)}}catch(M){return{type:"throw",arg:M}}}var y="suspendedStart",g="suspendedYield",v="executing",b="completed",w={};function x(){}function E(){}function A(){}var k={};f(k,c,function(){return this});var _=Object.getPrototypeOf,$=_&&_(_(te([])));$&&$!==r&&o.call($,c)&&(k=$);var L=A.prototype=x.prototype=Object.create(k);E.prototype=A,a(L,"constructor",{value:A,configurable:!0}),a(A,"constructor",{value:E,configurable:!0}),E.displayName=f(A,d,"GeneratorFunction");function O(W){["next","throw","return"].forEach(function(z){f(W,z,function(R){return this._invoke(z,R)})})}n.isGeneratorFunction=function(W){var z=typeof W=="function"&&W.constructor;return z?z===E||(z.displayName||z.name)==="GeneratorFunction":!1},n.mark=function(W){return Object.setPrototypeOf?Object.setPrototypeOf(W,A):(W.__proto__=A,f(W,d,"GeneratorFunction")),W.prototype=Object.create(L),W},n.awrap=function(W){return{__await:W}};function P(W,z){function R(re,Se,ce,Ce){var xe=m(W[re],W,Se);if(xe.type==="throw")Ce(xe.arg);else{var Ee=xe.arg,tt=Ee.value;return tt&&typeof tt=="object"&&o.call(tt,"__await")?z.resolve(tt.__await).then(function(me){R("next",me,ce,Ce)},function(me){R("throw",me,ce,Ce)}):z.resolve(tt).then(function(me){Ee.value=me,ce(Ee)},function(me){return R("throw",me,ce,Ce)})}}var M;function ee(re,Se){function ce(){return new z(function(Ce,xe){R(re,Se,Ce,xe)})}return M=M?M.then(ce,ce):ce()}a(this,"_invoke",{value:ee})}O(P.prototype),f(P.prototype,u,function(){return this}),n.AsyncIterator=P,n.async=function(W,z,R,M,ee){ee===void 0&&(ee=Promise);var re=new P(h(W,z,R,M),ee);return n.isGeneratorFunction(z)?re:re.next().then(function(Se){return Se.done?Se.value:re.next()})};function D(W,z,R){var M=y;return function(re,Se){if(M===v)throw new Error("Generator is already running");if(M===b){if(re==="throw")throw Se;return Z()}for(R.method=re,R.arg=Se;;){var ce=R.delegate;if(ce){var Ce=F(ce,R);if(Ce){if(Ce===w)continue;return Ce}}if(R.method==="next")R.sent=R._sent=R.arg;else if(R.method==="throw"){if(M===y)throw M=b,R.arg;R.dispatchException(R.arg)}else R.method==="return"&&R.abrupt("return",R.arg);M=v;var xe=m(W,z,R);if(xe.type==="normal"){if(M=R.done?b:g,xe.arg===w)continue;return{value:xe.arg,done:R.done}}else xe.type==="throw"&&(M=b,R.method="throw",R.arg=xe.arg)}}}function F(W,z){var R=z.method,M=W.iterator[R];if(M===i)return z.delegate=null,R==="throw"&&W.iterator.return&&(z.method="return",z.arg=i,F(W,z),z.method==="throw")||R!=="return"&&(z.method="throw",z.arg=new TypeError("The iterator does not provide a '"+R+"' method")),w;var ee=m(M,W.iterator,z.arg);if(ee.type==="throw")return z.method="throw",z.arg=ee.arg,z.delegate=null,w;var re=ee.arg;if(!re)return z.method="throw",z.arg=new TypeError("iterator result is not an object"),z.delegate=null,w;if(re.done)z[W.resultName]=re.value,z.next=W.nextLoc,z.method!=="return"&&(z.method="next",z.arg=i);else return re;return z.delegate=null,w}O(L),f(L,d,"Generator"),f(L,c,function(){return this}),f(L,"toString",function(){return"[object Generator]"});function U(W){var z={tryLoc:W[0]};1 in W&&(z.catchLoc=W[1]),2 in W&&(z.finallyLoc=W[2],z.afterLoc=W[3]),this.tryEntries.push(z)}function Y(W){var z=W.completion||{};z.type="normal",delete z.arg,W.completion=z}function V(W){this.tryEntries=[{tryLoc:"root"}],W.forEach(U,this),this.reset(!0)}n.keys=function(W){var z=Object(W),R=[];for(var M in z)R.push(M);return R.reverse(),function ee(){for(;R.length;){var re=R.pop();if(re in z)return ee.value=re,ee.done=!1,ee}return ee.done=!0,ee}};function te(W){if(W){var z=W[c];if(z)return z.call(W);if(typeof W.next=="function")return W;if(!isNaN(W.length)){var R=-1,M=function ee(){for(;++R<W.length;)if(o.call(W,R))return ee.value=W[R],ee.done=!1,ee;return ee.value=i,ee.done=!0,ee};return M.next=M}}return{next:Z}}n.values=te;function Z(){return{value:i,done:!0}}return V.prototype={constructor:V,reset:function(W){if(this.prev=0,this.next=0,this.sent=this._sent=i,this.done=!1,this.delegate=null,this.method="next",this.arg=i,this.tryEntries.forEach(Y),!W)for(var z in this)z.charAt(0)==="t"&&o.call(this,z)&&!isNaN(+z.slice(1))&&(this[z]=i)},stop:function(){this.done=!0;var W=this.tryEntries[0],z=W.completion;if(z.type==="throw")throw z.arg;return this.rval},dispatchException:function(W){if(this.done)throw W;var z=this;function R(Ce,xe){return re.type="throw",re.arg=W,z.next=Ce,xe&&(z.method="next",z.arg=i),!!xe}for(var M=this.tryEntries.length-1;M>=0;--M){var ee=this.tryEntries[M],re=ee.completion;if(ee.tryLoc==="root")return R("end");if(ee.tryLoc<=this.prev){var Se=o.call(ee,"catchLoc"),ce=o.call(ee,"finallyLoc");if(Se&&ce){if(this.prev<ee.catchLoc)return R(ee.catchLoc,!0);if(this.prev<ee.finallyLoc)return R(ee.finallyLoc)}else if(Se){if(this.prev<ee.catchLoc)return R(ee.catchLoc,!0)}else if(ce){if(this.prev<ee.finallyLoc)return R(ee.finallyLoc)}else throw new Error("try statement without catch or finally")}}},abrupt:function(W,z){for(var R=this.tryEntries.length-1;R>=0;--R){var M=this.tryEntries[R];if(M.tryLoc<=this.prev&&o.call(M,"finallyLoc")&&this.prev<M.finallyLoc){var ee=M;break}}ee&&(W==="break"||W==="continue")&&ee.tryLoc<=z&&z<=ee.finallyLoc&&(ee=null);var re=ee?ee.completion:{};return re.type=W,re.arg=z,ee?(this.method="next",this.next=ee.finallyLoc,w):this.complete(re)},complete:function(W,z){if(W.type==="throw")throw W.arg;return W.type==="break"||W.type==="continue"?this.next=W.arg:W.type==="return"?(this.rval=this.arg=W.arg,this.method="return",this.next="end"):W.type==="normal"&&z&&(this.next=z),w},finish:function(W){for(var z=this.tryEntries.length-1;z>=0;--z){var R=this.tryEntries[z];if(R.finallyLoc===W)return this.complete(R.completion,R.afterLoc),Y(R),w}},catch:function(W){for(var z=this.tryEntries.length-1;z>=0;--z){var R=this.tryEntries[z];if(R.tryLoc===W){var M=R.completion;if(M.type==="throw"){var ee=M.arg;Y(R)}return ee}}throw new Error("illegal catch attempt")},delegateYield:function(W,z,R){return this.delegate={iterator:te(W),resultName:z,nextLoc:R},this.method==="next"&&(this.arg=i),w}},n}(e.exports);try{regeneratorRuntime=t}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=t:Function("r","regeneratorRuntime = r")(t)}})(OM);var Gd={},LM={get exports(){return Gd},set exports(e){Gd=e}},aa={},y0={},NM={get exports(){return y0},set exports(e){y0=e}},iI={};/** @license React v0.20.2
|
|
21
|
+
* scheduler.production.min.js
|
|
22
|
+
*
|
|
23
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
24
|
+
*
|
|
25
|
+
* This source code is licensed under the MIT license found in the
|
|
26
|
+
* LICENSE file in the root directory of this source tree.
|
|
27
|
+
*/(function(e){var t,n,r,o;if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var i=Date,l=i.now();e.unstable_now=function(){return i.now()-l}}if(typeof window>"u"||typeof MessageChannel!="function"){var c=null,u=null,d=function(){if(c!==null)try{var R=e.unstable_now();c(!0,R),c=null}catch(M){throw setTimeout(d,0),M}};t=function(R){c!==null?setTimeout(t,0,R):(c=R,setTimeout(d,0))},n=function(R,M){u=setTimeout(R,M)},r=function(){clearTimeout(u)},e.unstable_shouldYield=function(){return!1},o=e.unstable_forceFrameRate=function(){}}else{var f=window.setTimeout,h=window.clearTimeout;if(typeof console<"u"){var m=window.cancelAnimationFrame;typeof window.requestAnimationFrame!="function"&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"),typeof m!="function"&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")}var y=!1,g=null,v=-1,b=5,w=0;e.unstable_shouldYield=function(){return e.unstable_now()>=w},o=function(){},e.unstable_forceFrameRate=function(R){0>R||125<R?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):b=0<R?Math.floor(1e3/R):5};var x=new MessageChannel,E=x.port2;x.port1.onmessage=function(){if(g!==null){var R=e.unstable_now();w=R+b;try{g(!0,R)?E.postMessage(null):(y=!1,g=null)}catch(M){throw E.postMessage(null),M}}else y=!1},t=function(R){g=R,y||(y=!0,E.postMessage(null))},n=function(R,M){v=f(function(){R(e.unstable_now())},M)},r=function(){h(v),v=-1}}function A(R,M){var ee=R.length;R.push(M);e:for(;;){var re=ee-1>>>1,Se=R[re];if(Se!==void 0&&0<$(Se,M))R[re]=M,R[ee]=Se,ee=re;else break e}}function k(R){return R=R[0],R===void 0?null:R}function _(R){var M=R[0];if(M!==void 0){var ee=R.pop();if(ee!==M){R[0]=ee;e:for(var re=0,Se=R.length;re<Se;){var ce=2*(re+1)-1,Ce=R[ce],xe=ce+1,Ee=R[xe];if(Ce!==void 0&&0>$(Ce,ee))Ee!==void 0&&0>$(Ee,Ce)?(R[re]=Ee,R[xe]=ee,re=xe):(R[re]=Ce,R[ce]=ee,re=ce);else if(Ee!==void 0&&0>$(Ee,ee))R[re]=Ee,R[xe]=ee,re=xe;else break e}}return M}return null}function $(R,M){var ee=R.sortIndex-M.sortIndex;return ee!==0?ee:R.id-M.id}var L=[],O=[],P=1,D=null,F=3,U=!1,Y=!1,V=!1;function te(R){for(var M=k(O);M!==null;){if(M.callback===null)_(O);else if(M.startTime<=R)_(O),M.sortIndex=M.expirationTime,A(L,M);else break;M=k(O)}}function Z(R){if(V=!1,te(R),!Y)if(k(L)!==null)Y=!0,t(W);else{var M=k(O);M!==null&&n(Z,M.startTime-R)}}function W(R,M){Y=!1,V&&(V=!1,r()),U=!0;var ee=F;try{for(te(M),D=k(L);D!==null&&(!(D.expirationTime>M)||R&&!e.unstable_shouldYield());){var re=D.callback;if(typeof re=="function"){D.callback=null,F=D.priorityLevel;var Se=re(D.expirationTime<=M);M=e.unstable_now(),typeof Se=="function"?D.callback=Se:D===k(L)&&_(L),te(M)}else _(L);D=k(L)}if(D!==null)var ce=!0;else{var Ce=k(O);Ce!==null&&n(Z,Ce.startTime-M),ce=!1}return ce}finally{D=null,F=ee,U=!1}}var z=o;e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(R){R.callback=null},e.unstable_continueExecution=function(){Y||U||(Y=!0,t(W))},e.unstable_getCurrentPriorityLevel=function(){return F},e.unstable_getFirstCallbackNode=function(){return k(L)},e.unstable_next=function(R){switch(F){case 1:case 2:case 3:var M=3;break;default:M=F}var ee=F;F=M;try{return R()}finally{F=ee}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=z,e.unstable_runWithPriority=function(R,M){switch(R){case 1:case 2:case 3:case 4:case 5:break;default:R=3}var ee=F;F=R;try{return M()}finally{F=ee}},e.unstable_scheduleCallback=function(R,M,ee){var re=e.unstable_now();switch(typeof ee=="object"&&ee!==null?(ee=ee.delay,ee=typeof ee=="number"&&0<ee?re+ee:re):ee=re,R){case 1:var Se=-1;break;case 2:Se=250;break;case 5:Se=1073741823;break;case 4:Se=1e4;break;default:Se=5e3}return Se=ee+Se,R={id:P++,callback:M,priorityLevel:R,startTime:ee,expirationTime:Se,sortIndex:-1},ee>re?(R.sortIndex=ee,A(O,R),k(L)===null&&R===k(O)&&(V?r():V=!0,n(Z,ee-re))):(R.sortIndex=Se,A(L,R),Y||U||(Y=!0,t(W))),R},e.unstable_wrapCallback=function(R){var M=F;return function(){var ee=F;F=M;try{return R.apply(this,arguments)}finally{F=ee}}}})(iI);(function(e){e.exports=iI})(NM);/** @license React v17.0.2
|
|
28
|
+
* react-dom.production.min.js
|
|
29
|
+
*
|
|
30
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
31
|
+
*
|
|
32
|
+
* This source code is licensed under the MIT license found in the
|
|
33
|
+
* LICENSE file in the root directory of this source tree.
|
|
34
|
+
*/var Xm=p,zn=jP,kr=y0;function Oe(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}if(!Xm)throw Error(Oe(227));var sI=new Set,qd={};function Cl(e,t){Pc(e,t),Pc(e+"Capture",t)}function Pc(e,t){for(qd[e]=t,e=0;e<t.length;e++)sI.add(t[e])}var Ei=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),MM=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,H2=Object.prototype.hasOwnProperty,V2={},G2={};function DM(e){return H2.call(G2,e)?!0:H2.call(V2,e)?!1:MM.test(e)?G2[e]=!0:(V2[e]=!0,!1)}function BM(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function FM(e,t,n,r){if(t===null||typeof t>"u"||BM(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function to(e,t,n,r,o,a,i){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=i}var Lr={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Lr[e]=new to(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Lr[t]=new to(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Lr[e]=new to(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Lr[e]=new to(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Lr[e]=new to(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Lr[e]=new to(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Lr[e]=new to(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Lr[e]=new to(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Lr[e]=new to(e,5,!1,e.toLowerCase(),null,!1,!1)});var Pw=/[\-:]([a-z])/g;function Iw(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Pw,Iw);Lr[t]=new to(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Pw,Iw);Lr[t]=new to(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Pw,Iw);Lr[t]=new to(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Lr[e]=new to(e,1,!1,e.toLowerCase(),null,!1,!1)});Lr.xlinkHref=new to("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Lr[e]=new to(e,1,!1,e.toLowerCase(),null,!0,!0)});function $w(e,t,n,r){var o=Lr.hasOwnProperty(t)?Lr[t]:null,a=o!==null?o.type===0:r?!1:!(!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N");a||(FM(t,n,o,r)&&(n=null),r||o===null?DM(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):o.mustUseProperty?e[o.propertyName]=n===null?o.type===3?!1:"":n:(t=o.attributeName,r=o.attributeNamespace,n===null?e.removeAttribute(t):(o=o.type,n=o===3||o===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var El=Xm.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,ld=60103,Qs=60106,Hi=60107,Ow=60108,bd=60114,Lw=60109,Nw=60110,Jm=60112,wd=60113,Gh=60120,Qm=60115,Mw=60116,Dw=60121,Bw=60128,lI=60129,Fw=60130,b0=60131;if(typeof Symbol=="function"&&Symbol.for){var xr=Symbol.for;ld=xr("react.element"),Qs=xr("react.portal"),Hi=xr("react.fragment"),Ow=xr("react.strict_mode"),bd=xr("react.profiler"),Lw=xr("react.provider"),Nw=xr("react.context"),Jm=xr("react.forward_ref"),wd=xr("react.suspense"),Gh=xr("react.suspense_list"),Qm=xr("react.memo"),Mw=xr("react.lazy"),Dw=xr("react.block"),xr("react.scope"),Bw=xr("react.opaque.id"),lI=xr("react.debug_trace_mode"),Fw=xr("react.offscreen"),b0=xr("react.legacy_hidden")}var q2=typeof Symbol=="function"&&Symbol.iterator;function Pu(e){return e===null||typeof e!="object"?null:(e=q2&&e[q2]||e["@@iterator"],typeof e=="function"?e:null)}var Ly;function cd(e){if(Ly===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);Ly=t&&t[1]||""}return`
|
|
35
|
+
`+Ly+e}var Ny=!1;function kf(e,t){if(!e||Ny)return"";Ny=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(c){var r=c}Reflect.construct(e,[],t)}else{try{t.call()}catch(c){r=c}e.call(t.prototype)}else{try{throw Error()}catch(c){r=c}e()}}catch(c){if(c&&r&&typeof c.stack=="string"){for(var o=c.stack.split(`
|
|
36
|
+
`),a=r.stack.split(`
|
|
37
|
+
`),i=o.length-1,l=a.length-1;1<=i&&0<=l&&o[i]!==a[l];)l--;for(;1<=i&&0<=l;i--,l--)if(o[i]!==a[l]){if(i!==1||l!==1)do if(i--,l--,0>l||o[i]!==a[l])return`
|
|
38
|
+
`+o[i].replace(" at new "," at ");while(1<=i&&0<=l);break}}}finally{Ny=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?cd(e):""}function zM(e){switch(e.tag){case 5:return cd(e.type);case 16:return cd("Lazy");case 13:return cd("Suspense");case 19:return cd("SuspenseList");case 0:case 2:case 15:return e=kf(e.type,!1),e;case 11:return e=kf(e.type.render,!1),e;case 22:return e=kf(e.type._render,!1),e;case 1:return e=kf(e.type,!0),e;default:return""}}function cc(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Hi:return"Fragment";case Qs:return"Portal";case bd:return"Profiler";case Ow:return"StrictMode";case wd:return"Suspense";case Gh:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Nw:return(e.displayName||"Context")+".Consumer";case Lw:return(e._context.displayName||"Context")+".Provider";case Jm:var t=e.render;return t=t.displayName||t.name||"",e.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case Qm:return cc(e.type);case Dw:return cc(e._render);case Mw:t=e._payload,e=e._init;try{return cc(e(t))}catch{}}return null}function us(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function cI(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function jM(e){var t=cI(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var o=n.get,a=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(i){r=""+i,a.call(this,i)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(i){r=""+i},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Af(e){e._valueTracker||(e._valueTracker=jM(e))}function uI(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=cI(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function qh(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function w0(e,t){var n=t.checked;return zn({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function K2(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=us(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function dI(e,t){t=t.checked,t!=null&&$w(e,"checked",t,!1)}function S0(e,t){dI(e,t);var n=us(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?x0(e,t.type,n):t.hasOwnProperty("defaultValue")&&x0(e,t.type,us(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Y2(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function x0(e,t,n){(t!=="number"||qh(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}function UM(e){var t="";return Xm.Children.forEach(e,function(n){n!=null&&(t+=n)}),t}function C0(e,t){return e=zn({children:void 0},t),(t=UM(t.children))&&(e.children=t),e}function uc(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o<n.length;o++)t["$"+n[o]]=!0;for(n=0;n<e.length;n++)o=t.hasOwnProperty("$"+e[n].value),e[n].selected!==o&&(e[n].selected=o),o&&r&&(e[n].defaultSelected=!0)}else{for(n=""+us(n),t=null,o=0;o<e.length;o++){if(e[o].value===n){e[o].selected=!0,r&&(e[o].defaultSelected=!0);return}t!==null||e[o].disabled||(t=e[o])}t!==null&&(t.selected=!0)}}function E0(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(Oe(91));return zn({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function X2(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(Oe(92));if(Array.isArray(n)){if(!(1>=n.length))throw Error(Oe(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:us(n)}}function pI(e,t){var n=us(t.value),r=us(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function J2(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}var T0={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};function fI(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function k0(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?fI(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var _f,hI=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,o){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,o)})}:e}(function(e,t){if(e.namespaceURI!==T0.svg||"innerHTML"in e)e.innerHTML=t;else{for(_f=_f||document.createElement("div"),_f.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=_f.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Kd(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Sd={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},WM=["Webkit","ms","Moz","O"];Object.keys(Sd).forEach(function(e){WM.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Sd[t]=Sd[e]})});function mI(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Sd.hasOwnProperty(e)&&Sd[e]?(""+t).trim():t+"px"}function gI(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,o=mI(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}var HM=zn({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function A0(e,t){if(t){if(HM[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(Oe(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(Oe(60));if(!(typeof t.dangerouslySetInnerHTML=="object"&&"__html"in t.dangerouslySetInnerHTML))throw Error(Oe(61))}if(t.style!=null&&typeof t.style!="object")throw Error(Oe(62))}}function _0(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function zw(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var R0=null,dc=null,pc=null;function Q2(e){if(e=Mp(e)){if(typeof R0!="function")throw Error(Oe(280));var t=e.stateNode;t&&(t=og(t),R0(e.stateNode,e.type,t))}}function vI(e){dc?pc?pc.push(e):pc=[e]:dc=e}function yI(){if(dc){var e=dc,t=pc;if(pc=dc=null,Q2(e),t)for(e=0;e<t.length;e++)Q2(t[e])}}function jw(e,t){return e(t)}function bI(e,t,n,r,o){return e(t,n,r,o)}function Uw(){}var wI=jw,Zs=!1,My=!1;function Ww(){(dc!==null||pc!==null)&&(Uw(),yI())}function VM(e,t,n){if(My)return e(t,n);My=!0;try{return wI(e,t,n)}finally{My=!1,Ww()}}function Yd(e,t){var n=e.stateNode;if(n===null)return null;var r=og(n);if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(Oe(231,t,typeof n));return n}var P0=!1;if(Ei)try{var Iu={};Object.defineProperty(Iu,"passive",{get:function(){P0=!0}}),window.addEventListener("test",Iu,Iu),window.removeEventListener("test",Iu,Iu)}catch{P0=!1}function GM(e,t,n,r,o,a,i,l,c){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(d){this.onError(d)}}var xd=!1,Kh=null,Yh=!1,I0=null,qM={onError:function(e){xd=!0,Kh=e}};function KM(e,t,n,r,o,a,i,l,c){xd=!1,Kh=null,GM.apply(qM,arguments)}function YM(e,t,n,r,o,a,i,l,c){if(KM.apply(this,arguments),xd){if(xd){var u=Kh;xd=!1,Kh=null}else throw Error(Oe(198));Yh||(Yh=!0,I0=u)}}function Tl(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&1026&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function SI(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function Z2(e){if(Tl(e)!==e)throw Error(Oe(188))}function XM(e){var t=e.alternate;if(!t){if(t=Tl(e),t===null)throw Error(Oe(188));return t!==e?null:e}for(var n=e,r=t;;){var o=n.return;if(o===null)break;var a=o.alternate;if(a===null){if(r=o.return,r!==null){n=r;continue}break}if(o.child===a.child){for(a=o.child;a;){if(a===n)return Z2(o),e;if(a===r)return Z2(o),t;a=a.sibling}throw Error(Oe(188))}if(n.return!==r.return)n=o,r=a;else{for(var i=!1,l=o.child;l;){if(l===n){i=!0,n=o,r=a;break}if(l===r){i=!0,r=o,n=a;break}l=l.sibling}if(!i){for(l=a.child;l;){if(l===n){i=!0,n=a,r=o;break}if(l===r){i=!0,r=a,n=o;break}l=l.sibling}if(!i)throw Error(Oe(189))}}if(n.alternate!==r)throw Error(Oe(190))}if(n.tag!==3)throw Error(Oe(188));return n.stateNode.current===n?e:t}function xI(e){if(e=XM(e),!e)return null;for(var t=e;;){if(t.tag===5||t.tag===6)return t;if(t.child)t.child.return=t,t=t.child;else{if(t===e)break;for(;!t.sibling;){if(!t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}}return null}function eE(e,t){for(var n=e.alternate;t!==null;){if(t===e||t===n)return!0;t=t.return}return!1}var CI,Hw,EI,TI,$0=!1,za=[],Zi=null,es=null,ts=null,Xd=new Map,Jd=new Map,$u=[],tE="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function O0(e,t,n,r,o){return{blockedOn:e,domEventName:t,eventSystemFlags:n|16,nativeEvent:o,targetContainers:[r]}}function nE(e,t){switch(e){case"focusin":case"focusout":Zi=null;break;case"dragenter":case"dragleave":es=null;break;case"mouseover":case"mouseout":ts=null;break;case"pointerover":case"pointerout":Xd.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Jd.delete(t.pointerId)}}function Ou(e,t,n,r,o,a){return e===null||e.nativeEvent!==a?(e=O0(t,n,r,o,a),t!==null&&(t=Mp(t),t!==null&&Hw(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,o!==null&&t.indexOf(o)===-1&&t.push(o),e)}function JM(e,t,n,r,o){switch(t){case"focusin":return Zi=Ou(Zi,e,t,n,r,o),!0;case"dragenter":return es=Ou(es,e,t,n,r,o),!0;case"mouseover":return ts=Ou(ts,e,t,n,r,o),!0;case"pointerover":var a=o.pointerId;return Xd.set(a,Ou(Xd.get(a)||null,e,t,n,r,o)),!0;case"gotpointercapture":return a=o.pointerId,Jd.set(a,Ou(Jd.get(a)||null,e,t,n,r,o)),!0}return!1}function QM(e){var t=el(e.target);if(t!==null){var n=Tl(t);if(n!==null){if(t=n.tag,t===13){if(t=SI(n),t!==null){e.blockedOn=t,TI(e.lanePriority,function(){kr.unstable_runWithPriority(e.priority,function(){EI(n)})});return}}else if(t===3&&n.stateNode.hydrate){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function bh(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Kw(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n!==null)return t=Mp(n),t!==null&&Hw(t),e.blockedOn=n,!1;t.shift()}return!0}function rE(e,t,n){bh(e)&&n.delete(t)}function ZM(){for($0=!1;0<za.length;){var e=za[0];if(e.blockedOn!==null){e=Mp(e.blockedOn),e!==null&&CI(e);break}for(var t=e.targetContainers;0<t.length;){var n=Kw(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n!==null){e.blockedOn=n;break}t.shift()}e.blockedOn===null&&za.shift()}Zi!==null&&bh(Zi)&&(Zi=null),es!==null&&bh(es)&&(es=null),ts!==null&&bh(ts)&&(ts=null),Xd.forEach(rE),Jd.forEach(rE)}function Lu(e,t){e.blockedOn===t&&(e.blockedOn=null,$0||($0=!0,kr.unstable_scheduleCallback(kr.unstable_NormalPriority,ZM)))}function kI(e){function t(o){return Lu(o,e)}if(0<za.length){Lu(za[0],e);for(var n=1;n<za.length;n++){var r=za[n];r.blockedOn===e&&(r.blockedOn=null)}}for(Zi!==null&&Lu(Zi,e),es!==null&&Lu(es,e),ts!==null&&Lu(ts,e),Xd.forEach(t),Jd.forEach(t),n=0;n<$u.length;n++)r=$u[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<$u.length&&(n=$u[0],n.blockedOn===null);)QM(n),n.blockedOn===null&&$u.shift()}function Rf(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var ec={animationend:Rf("Animation","AnimationEnd"),animationiteration:Rf("Animation","AnimationIteration"),animationstart:Rf("Animation","AnimationStart"),transitionend:Rf("Transition","TransitionEnd")},Dy={},AI={};Ei&&(AI=document.createElement("div").style,"AnimationEvent"in window||(delete ec.animationend.animation,delete ec.animationiteration.animation,delete ec.animationstart.animation),"TransitionEvent"in window||delete ec.transitionend.transition);function Zm(e){if(Dy[e])return Dy[e];if(!ec[e])return e;var t=ec[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in AI)return Dy[e]=t[n];return e}var _I=Zm("animationend"),RI=Zm("animationiteration"),PI=Zm("animationstart"),II=Zm("transitionend"),$I=new Map,Vw=new Map,eD=["abort","abort",_I,"animationEnd",RI,"animationIteration",PI,"animationStart","canplay","canPlay","canplaythrough","canPlayThrough","durationchange","durationChange","emptied","emptied","encrypted","encrypted","ended","ended","error","error","gotpointercapture","gotPointerCapture","load","load","loadeddata","loadedData","loadedmetadata","loadedMetadata","loadstart","loadStart","lostpointercapture","lostPointerCapture","playing","playing","progress","progress","seeking","seeking","stalled","stalled","suspend","suspend","timeupdate","timeUpdate",II,"transitionEnd","waiting","waiting"];function Gw(e,t){for(var n=0;n<e.length;n+=2){var r=e[n],o=e[n+1];o="on"+(o[0].toUpperCase()+o.slice(1)),Vw.set(r,t),$I.set(r,o),Cl(o,[r])}}var tD=kr.unstable_now;tD();var Pn=8;function Xl(e){if(1&e)return Pn=15,1;if(2&e)return Pn=14,2;if(4&e)return Pn=13,4;var t=24&e;return t!==0?(Pn=12,t):e&32?(Pn=11,32):(t=192&e,t!==0?(Pn=10,t):e&256?(Pn=9,256):(t=3584&e,t!==0?(Pn=8,t):e&4096?(Pn=7,4096):(t=4186112&e,t!==0?(Pn=6,t):(t=62914560&e,t!==0?(Pn=5,t):e&67108864?(Pn=4,67108864):e&134217728?(Pn=3,134217728):(t=805306368&e,t!==0?(Pn=2,t):1073741824&e?(Pn=1,1073741824):(Pn=8,e))))))}function nD(e){switch(e){case 99:return 15;case 98:return 10;case 97:case 96:return 8;case 95:return 2;default:return 0}}function rD(e){switch(e){case 15:case 14:return 99;case 13:case 12:case 11:case 10:return 98;case 9:case 8:case 7:case 6:case 4:case 5:return 97;case 3:case 2:case 1:return 95;case 0:return 90;default:throw Error(Oe(358,e))}}function Qd(e,t){var n=e.pendingLanes;if(n===0)return Pn=0;var r=0,o=0,a=e.expiredLanes,i=e.suspendedLanes,l=e.pingedLanes;if(a!==0)r=a,o=Pn=15;else if(a=n&134217727,a!==0){var c=a&~i;c!==0?(r=Xl(c),o=Pn):(l&=a,l!==0&&(r=Xl(l),o=Pn))}else a=n&~i,a!==0?(r=Xl(a),o=Pn):l!==0&&(r=Xl(l),o=Pn);if(r===0)return 0;if(r=31-ds(r),r=n&((0>r?0:1<<r)<<1)-1,t!==0&&t!==r&&!(t&i)){if(Xl(t),o<=Pn)return t;Pn=o}if(t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-ds(t),o=1<<n,r|=e[n],t&=~o;return r}function OI(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function Xh(e,t){switch(e){case 15:return 1;case 14:return 2;case 12:return e=Jl(24&~t),e===0?Xh(10,t):e;case 10:return e=Jl(192&~t),e===0?Xh(8,t):e;case 8:return e=Jl(3584&~t),e===0&&(e=Jl(4186112&~t),e===0&&(e=512)),e;case 2:return t=Jl(805306368&~t),t===0&&(t=268435456),t}throw Error(Oe(358,e))}function Jl(e){return e&-e}function By(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function eg(e,t,n){e.pendingLanes|=t;var r=t-1;e.suspendedLanes&=r,e.pingedLanes&=r,e=e.eventTimes,t=31-ds(t),e[t]=n}var ds=Math.clz32?Math.clz32:iD,oD=Math.log,aD=Math.LN2;function iD(e){return e===0?32:31-(oD(e)/aD|0)|0}var sD=kr.unstable_UserBlockingPriority,lD=kr.unstable_runWithPriority,wh=!0;function cD(e,t,n,r){Zs||Uw();var o=qw,a=Zs;Zs=!0;try{bI(o,e,t,n,r)}finally{(Zs=a)||Ww()}}function uD(e,t,n,r){lD(sD,qw.bind(null,e,t,n,r))}function qw(e,t,n,r){if(wh){var o;if((o=(t&4)===0)&&0<za.length&&-1<tE.indexOf(e))e=O0(null,e,t,n,r),za.push(e);else{var a=Kw(e,t,n,r);if(a===null)o&&nE(e,r);else{if(o){if(-1<tE.indexOf(e)){e=O0(a,e,t,n,r),za.push(e);return}if(JM(a,e,t,n,r))return;nE(e,r)}GI(e,t,r,null,n)}}}}function Kw(e,t,n,r){var o=zw(r);if(o=el(o),o!==null){var a=Tl(o);if(a===null)o=null;else{var i=a.tag;if(i===13){if(o=SI(a),o!==null)return o;o=null}else if(i===3){if(a.stateNode.hydrate)return a.tag===3?a.stateNode.containerInfo:null;o=null}else a!==o&&(o=null)}}return GI(e,t,r,o,n),null}var Gi=null,Yw=null,Sh=null;function LI(){if(Sh)return Sh;var e,t=Yw,n=t.length,r,o="value"in Gi?Gi.value:Gi.textContent,a=o.length;for(e=0;e<n&&t[e]===o[e];e++);var i=n-e;for(r=1;r<=i&&t[n-r]===o[a-r];r++);return Sh=o.slice(e,1<r?1-r:void 0)}function xh(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Pf(){return!0}function oE(){return!1}function Mo(e){function t(n,r,o,a,i){this._reactName=n,this._targetInst=o,this.type=r,this.nativeEvent=a,this.target=i,this.currentTarget=null;for(var l in e)e.hasOwnProperty(l)&&(n=e[l],this[l]=n?n(a):a[l]);return this.isDefaultPrevented=(a.defaultPrevented!=null?a.defaultPrevented:a.returnValue===!1)?Pf:oE,this.isPropagationStopped=oE,this}return zn(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=Pf)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Pf)},persist:function(){},isPersistent:Pf}),t}var Kc={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Xw=Mo(Kc),Np=zn({},Kc,{view:0,detail:0}),dD=Mo(Np),Fy,zy,Nu,tg=zn({},Np,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Jw,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Nu&&(Nu&&e.type==="mousemove"?(Fy=e.screenX-Nu.screenX,zy=e.screenY-Nu.screenY):zy=Fy=0,Nu=e),Fy)},movementY:function(e){return"movementY"in e?e.movementY:zy}}),aE=Mo(tg),pD=zn({},tg,{dataTransfer:0}),fD=Mo(pD),hD=zn({},Np,{relatedTarget:0}),jy=Mo(hD),mD=zn({},Kc,{animationName:0,elapsedTime:0,pseudoElement:0}),gD=Mo(mD),vD=zn({},Kc,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),yD=Mo(vD),bD=zn({},Kc,{data:0}),iE=Mo(bD),wD={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},SD={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},xD={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function CD(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=xD[e])?!!t[e]:!1}function Jw(){return CD}var ED=zn({},Np,{key:function(e){if(e.key){var t=wD[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=xh(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?SD[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Jw,charCode:function(e){return e.type==="keypress"?xh(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?xh(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),TD=Mo(ED),kD=zn({},tg,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),sE=Mo(kD),AD=zn({},Np,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Jw}),_D=Mo(AD),RD=zn({},Kc,{propertyName:0,elapsedTime:0,pseudoElement:0}),PD=Mo(RD),ID=zn({},tg,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),$D=Mo(ID),OD=[9,13,27,32],Qw=Ei&&"CompositionEvent"in window,Cd=null;Ei&&"documentMode"in document&&(Cd=document.documentMode);var LD=Ei&&"TextEvent"in window&&!Cd,NI=Ei&&(!Qw||Cd&&8<Cd&&11>=Cd),lE=String.fromCharCode(32),cE=!1;function MI(e,t){switch(e){case"keyup":return OD.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function DI(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var tc=!1;function ND(e,t){switch(e){case"compositionend":return DI(t);case"keypress":return t.which!==32?null:(cE=!0,lE);case"textInput":return e=t.data,e===lE&&cE?null:e;default:return null}}function MD(e,t){if(tc)return e==="compositionend"||!Qw&&MI(e,t)?(e=LI(),Sh=Yw=Gi=null,tc=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return NI&&t.locale!=="ko"?null:t.data;default:return null}}var DD={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function uE(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!DD[e.type]:t==="textarea"}function BI(e,t,n,r){vI(r),t=Jh(t,"onChange"),0<t.length&&(n=new Xw("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Ed=null,Zd=null;function BD(e){WI(e,0)}function ng(e){var t=rc(e);if(uI(t))return e}function FD(e,t){if(e==="change")return t}var FI=!1;if(Ei){var Uy;if(Ei){var Wy="oninput"in document;if(!Wy){var dE=document.createElement("div");dE.setAttribute("oninput","return;"),Wy=typeof dE.oninput=="function"}Uy=Wy}else Uy=!1;FI=Uy&&(!document.documentMode||9<document.documentMode)}function pE(){Ed&&(Ed.detachEvent("onpropertychange",zI),Zd=Ed=null)}function zI(e){if(e.propertyName==="value"&&ng(Zd)){var t=[];if(BI(t,Zd,e,zw(e)),e=BD,Zs)e(t);else{Zs=!0;try{jw(e,t)}finally{Zs=!1,Ww()}}}}function zD(e,t,n){e==="focusin"?(pE(),Ed=t,Zd=n,Ed.attachEvent("onpropertychange",zI)):e==="focusout"&&pE()}function jD(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return ng(Zd)}function UD(e,t){if(e==="click")return ng(t)}function WD(e,t){if(e==="input"||e==="change")return ng(t)}function HD(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Vo=typeof Object.is=="function"?Object.is:HD,VD=Object.prototype.hasOwnProperty;function ep(e,t){if(Vo(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++)if(!VD.call(t,n[r])||!Vo(e[n[r]],t[n[r]]))return!1;return!0}function fE(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function hE(e,t){var n=fE(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=fE(n)}}function jI(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?jI(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function mE(){for(var e=window,t=qh();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=qh(e.document)}return t}function L0(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var GD=Ei&&"documentMode"in document&&11>=document.documentMode,nc=null,N0=null,Td=null,M0=!1;function gE(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;M0||nc==null||nc!==qh(r)||(r=nc,"selectionStart"in r&&L0(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Td&&ep(Td,r)||(Td=r,r=Jh(N0,"onSelect"),0<r.length&&(t=new Xw("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=nc)))}Gw("cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focusin focus focusout blur input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange".split(" "),0);Gw("drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel".split(" "),1);Gw(eD,2);for(var vE="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),Hy=0;Hy<vE.length;Hy++)Vw.set(vE[Hy],0);Pc("onMouseEnter",["mouseout","mouseover"]);Pc("onMouseLeave",["mouseout","mouseover"]);Pc("onPointerEnter",["pointerout","pointerover"]);Pc("onPointerLeave",["pointerout","pointerover"]);Cl("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Cl("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Cl("onBeforeInput",["compositionend","keypress","textInput","paste"]);Cl("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Cl("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Cl("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var ud="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),UI=new Set("cancel close invalid load scroll toggle".split(" ").concat(ud));function yE(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,YM(r,t,void 0,e),e.currentTarget=null}function WI(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],o=r.event;r=r.listeners;e:{var a=void 0;if(t)for(var i=r.length-1;0<=i;i--){var l=r[i],c=l.instance,u=l.currentTarget;if(l=l.listener,c!==a&&o.isPropagationStopped())break e;yE(o,l,u),a=c}else for(i=0;i<r.length;i++){if(l=r[i],c=l.instance,u=l.currentTarget,l=l.listener,c!==a&&o.isPropagationStopped())break e;yE(o,l,u),a=c}}}if(Yh)throw e=I0,Yh=!1,I0=null,e}function $n(e,t){var n=KI(t),r=e+"__bubble";n.has(r)||(VI(t,e,2,!1),n.add(r))}var bE="_reactListening"+Math.random().toString(36).slice(2);function HI(e){e[bE]||(e[bE]=!0,sI.forEach(function(t){UI.has(t)||wE(t,!1,e,null),wE(t,!0,e,null)}))}function wE(e,t,n,r){var o=4<arguments.length&&arguments[4]!==void 0?arguments[4]:0,a=n;if(e==="selectionchange"&&n.nodeType!==9&&(a=n.ownerDocument),r!==null&&!t&&UI.has(e)){if(e!=="scroll")return;o|=2,a=r}var i=KI(a),l=e+"__"+(t?"capture":"bubble");i.has(l)||(t&&(o|=4),VI(a,e,o,t),i.add(l))}function VI(e,t,n,r){var o=Vw.get(t);switch(o===void 0?2:o){case 0:o=cD;break;case 1:o=uD;break;default:o=qw}n=o.bind(null,t,n,e),o=void 0,!P0||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(o=!0),r?o!==void 0?e.addEventListener(t,n,{capture:!0,passive:o}):e.addEventListener(t,n,!0):o!==void 0?e.addEventListener(t,n,{passive:o}):e.addEventListener(t,n,!1)}function GI(e,t,n,r,o){var a=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var i=r.tag;if(i===3||i===4){var l=r.stateNode.containerInfo;if(l===o||l.nodeType===8&&l.parentNode===o)break;if(i===4)for(i=r.return;i!==null;){var c=i.tag;if((c===3||c===4)&&(c=i.stateNode.containerInfo,c===o||c.nodeType===8&&c.parentNode===o))return;i=i.return}for(;l!==null;){if(i=el(l),i===null)return;if(c=i.tag,c===5||c===6){r=a=i;continue e}l=l.parentNode}}r=r.return}VM(function(){var u=a,d=zw(n),f=[];e:{var h=$I.get(e);if(h!==void 0){var m=Xw,y=e;switch(e){case"keypress":if(xh(n)===0)break e;case"keydown":case"keyup":m=TD;break;case"focusin":y="focus",m=jy;break;case"focusout":y="blur",m=jy;break;case"beforeblur":case"afterblur":m=jy;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":m=aE;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":m=fD;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":m=_D;break;case _I:case RI:case PI:m=gD;break;case II:m=PD;break;case"scroll":m=dD;break;case"wheel":m=$D;break;case"copy":case"cut":case"paste":m=yD;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":m=sE}var g=(t&4)!==0,v=!g&&e==="scroll",b=g?h!==null?h+"Capture":null:h;g=[];for(var w=u,x;w!==null;){x=w;var E=x.stateNode;if(x.tag===5&&E!==null&&(x=E,b!==null&&(E=Yd(w,b),E!=null&&g.push(tp(w,E,x)))),v)break;w=w.return}0<g.length&&(h=new m(h,y,null,n,d),f.push({event:h,listeners:g}))}}if(!(t&7)){e:{if(h=e==="mouseover"||e==="pointerover",m=e==="mouseout"||e==="pointerout",h&&!(t&16)&&(y=n.relatedTarget||n.fromElement)&&(el(y)||y[Yc]))break e;if((m||h)&&(h=d.window===d?d:(h=d.ownerDocument)?h.defaultView||h.parentWindow:window,m?(y=n.relatedTarget||n.toElement,m=u,y=y?el(y):null,y!==null&&(v=Tl(y),y!==v||y.tag!==5&&y.tag!==6)&&(y=null)):(m=null,y=u),m!==y)){if(g=aE,E="onMouseLeave",b="onMouseEnter",w="mouse",(e==="pointerout"||e==="pointerover")&&(g=sE,E="onPointerLeave",b="onPointerEnter",w="pointer"),v=m==null?h:rc(m),x=y==null?h:rc(y),h=new g(E,w+"leave",m,n,d),h.target=v,h.relatedTarget=x,E=null,el(d)===u&&(g=new g(b,w+"enter",y,n,d),g.target=x,g.relatedTarget=v,E=g),v=E,m&&y)t:{for(g=m,b=y,w=0,x=g;x;x=Dl(x))w++;for(x=0,E=b;E;E=Dl(E))x++;for(;0<w-x;)g=Dl(g),w--;for(;0<x-w;)b=Dl(b),x--;for(;w--;){if(g===b||b!==null&&g===b.alternate)break t;g=Dl(g),b=Dl(b)}g=null}else g=null;m!==null&&SE(f,h,m,g,!1),y!==null&&v!==null&&SE(f,v,y,g,!0)}}e:{if(h=u?rc(u):window,m=h.nodeName&&h.nodeName.toLowerCase(),m==="select"||m==="input"&&h.type==="file")var A=FD;else if(uE(h))if(FI)A=WD;else{A=jD;var k=zD}else(m=h.nodeName)&&m.toLowerCase()==="input"&&(h.type==="checkbox"||h.type==="radio")&&(A=UD);if(A&&(A=A(e,u))){BI(f,A,n,d);break e}k&&k(e,h,u),e==="focusout"&&(k=h._wrapperState)&&k.controlled&&h.type==="number"&&x0(h,"number",h.value)}switch(k=u?rc(u):window,e){case"focusin":(uE(k)||k.contentEditable==="true")&&(nc=k,N0=u,Td=null);break;case"focusout":Td=N0=nc=null;break;case"mousedown":M0=!0;break;case"contextmenu":case"mouseup":case"dragend":M0=!1,gE(f,n,d);break;case"selectionchange":if(GD)break;case"keydown":case"keyup":gE(f,n,d)}var _;if(Qw)e:{switch(e){case"compositionstart":var $="onCompositionStart";break e;case"compositionend":$="onCompositionEnd";break e;case"compositionupdate":$="onCompositionUpdate";break e}$=void 0}else tc?MI(e,n)&&($="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&($="onCompositionStart");$&&(NI&&n.locale!=="ko"&&(tc||$!=="onCompositionStart"?$==="onCompositionEnd"&&tc&&(_=LI()):(Gi=d,Yw="value"in Gi?Gi.value:Gi.textContent,tc=!0)),k=Jh(u,$),0<k.length&&($=new iE($,e,null,n,d),f.push({event:$,listeners:k}),_?$.data=_:(_=DI(n),_!==null&&($.data=_)))),(_=LD?ND(e,n):MD(e,n))&&(u=Jh(u,"onBeforeInput"),0<u.length&&(d=new iE("onBeforeInput","beforeinput",null,n,d),f.push({event:d,listeners:u}),d.data=_))}WI(f,t)})}function tp(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Jh(e,t){for(var n=t+"Capture",r=[];e!==null;){var o=e,a=o.stateNode;o.tag===5&&a!==null&&(o=a,a=Yd(e,n),a!=null&&r.unshift(tp(e,a,o)),a=Yd(e,t),a!=null&&r.push(tp(e,a,o))),e=e.return}return r}function Dl(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function SE(e,t,n,r,o){for(var a=t._reactName,i=[];n!==null&&n!==r;){var l=n,c=l.alternate,u=l.stateNode;if(c!==null&&c===r)break;l.tag===5&&u!==null&&(l=u,o?(c=Yd(n,a),c!=null&&i.unshift(tp(n,c,l))):o||(c=Yd(n,a),c!=null&&i.push(tp(n,c,l)))),n=n.return}i.length!==0&&e.push({event:t,listeners:i})}function Qh(){}var Vy=null,Gy=null;function qI(e,t){switch(e){case"button":case"input":case"select":case"textarea":return!!t.autoFocus}return!1}function D0(e,t){return e==="textarea"||e==="option"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var xE=typeof setTimeout=="function"?setTimeout:void 0,qD=typeof clearTimeout=="function"?clearTimeout:void 0;function Zw(e){e.nodeType===1?e.textContent="":e.nodeType===9&&(e=e.body,e!=null&&(e.textContent=""))}function fc(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break}return e}function CE(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var qy=0;function KD(e){return{$$typeof:Bw,toString:e,valueOf:e}}var rg=Math.random().toString(36).slice(2),qi="__reactFiber$"+rg,Zh="__reactProps$"+rg,Yc="__reactContainer$"+rg,EE="__reactEvents$"+rg;function el(e){var t=e[qi];if(t)return t;for(var n=e.parentNode;n;){if(t=n[Yc]||n[qi]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=CE(e);e!==null;){if(n=e[qi])return n;e=CE(e)}return t}e=n,n=e.parentNode}return null}function Mp(e){return e=e[qi]||e[Yc],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function rc(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(Oe(33))}function og(e){return e[Zh]||null}function KI(e){var t=e[EE];return t===void 0&&(t=e[EE]=new Set),t}var B0=[],oc=-1;function Es(e){return{current:e}}function Ln(e){0>oc||(e.current=B0[oc],B0[oc]=null,oc--)}function Xn(e,t){oc++,B0[oc]=e.current,e.current=t}var ps={},Wr=Es(ps),uo=Es(!1),pl=ps;function Ic(e,t){var n=e.type.contextTypes;if(!n)return ps;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},a;for(a in n)o[a]=t[a];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function po(e){return e=e.childContextTypes,e!=null}function em(){Ln(uo),Ln(Wr)}function TE(e,t,n){if(Wr.current!==ps)throw Error(Oe(168));Xn(Wr,t),Xn(uo,n)}function YI(e,t,n){var r=e.stateNode;if(e=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var o in r)if(!(o in e))throw Error(Oe(108,cc(t)||"Unknown",o));return zn({},n,r)}function Ch(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||ps,pl=Wr.current,Xn(Wr,e),Xn(uo,uo.current),!0}function kE(e,t,n){var r=e.stateNode;if(!r)throw Error(Oe(169));n?(e=YI(e,t,pl),r.__reactInternalMemoizedMergedChildContext=e,Ln(uo),Ln(Wr),Xn(Wr,e)):Ln(uo),Xn(uo,n)}var eS=null,il=null,YD=kr.unstable_runWithPriority,tS=kr.unstable_scheduleCallback,F0=kr.unstable_cancelCallback,XD=kr.unstable_shouldYield,AE=kr.unstable_requestPaint,z0=kr.unstable_now,JD=kr.unstable_getCurrentPriorityLevel,ag=kr.unstable_ImmediatePriority,XI=kr.unstable_UserBlockingPriority,JI=kr.unstable_NormalPriority,QI=kr.unstable_LowPriority,ZI=kr.unstable_IdlePriority,Ky={},QD=AE!==void 0?AE:function(){},fi=null,Eh=null,Yy=!1,_E=z0(),jr=1e4>_E?z0:function(){return z0()-_E};function $c(){switch(JD()){case ag:return 99;case XI:return 98;case JI:return 97;case QI:return 96;case ZI:return 95;default:throw Error(Oe(332))}}function e5(e){switch(e){case 99:return ag;case 98:return XI;case 97:return JI;case 96:return QI;case 95:return ZI;default:throw Error(Oe(332))}}function fl(e,t){return e=e5(e),YD(e,t)}function np(e,t,n){return e=e5(e),tS(e,t,n)}function ri(){if(Eh!==null){var e=Eh;Eh=null,F0(e)}t5()}function t5(){if(!Yy&&fi!==null){Yy=!0;var e=0;try{var t=fi;fl(99,function(){for(;e<t.length;e++){var n=t[e];do n=n(!0);while(n!==null)}}),fi=null}catch(n){throw fi!==null&&(fi=fi.slice(e+1)),tS(ag,ri),n}finally{Yy=!1}}}var ZD=El.ReactCurrentBatchConfig;function ma(e,t){if(e&&e.defaultProps){t=zn({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}var tm=Es(null),nm=null,ac=null,rm=null;function nS(){rm=ac=nm=null}function rS(e){var t=tm.current;Ln(tm),e.type._context._currentValue=t}function n5(e,t){for(;e!==null;){var n=e.alternate;if((e.childLanes&t)===t){if(n===null||(n.childLanes&t)===t)break;n.childLanes|=t}else e.childLanes|=t,n!==null&&(n.childLanes|=t);e=e.return}}function hc(e,t){nm=e,rm=ac=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(ya=!0),e.firstContext=null)}function Zo(e,t){if(rm!==e&&t!==!1&&t!==0)if((typeof t!="number"||t===1073741823)&&(rm=e,t=1073741823),t={context:e,observedBits:t,next:null},ac===null){if(nm===null)throw Error(Oe(308));ac=t,nm.dependencies={lanes:0,firstContext:t,responders:null}}else ac=ac.next=t;return e._currentValue}var Wi=!1;function oS(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null},effects:null}}function r5(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function ns(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function rs(e,t){if(e=e.updateQueue,e!==null){e=e.shared;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}}function RE(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var o=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var i={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};a===null?o=a=i:a=a.next=i,n=n.next}while(n!==null);a===null?o=a=t:a=a.next=t}else o=a=t;n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:a,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function rp(e,t,n,r){var o=e.updateQueue;Wi=!1;var a=o.firstBaseUpdate,i=o.lastBaseUpdate,l=o.shared.pending;if(l!==null){o.shared.pending=null;var c=l,u=c.next;c.next=null,i===null?a=u:i.next=u,i=c;var d=e.alternate;if(d!==null){d=d.updateQueue;var f=d.lastBaseUpdate;f!==i&&(f===null?d.firstBaseUpdate=u:f.next=u,d.lastBaseUpdate=c)}}if(a!==null){f=o.baseState,i=0,d=u=c=null;do{l=a.lane;var h=a.eventTime;if((r&l)===l){d!==null&&(d=d.next={eventTime:h,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var m=e,y=a;switch(l=t,h=n,y.tag){case 1:if(m=y.payload,typeof m=="function"){f=m.call(h,f,l);break e}f=m;break e;case 3:m.flags=m.flags&-4097|64;case 0:if(m=y.payload,l=typeof m=="function"?m.call(h,f,l):m,l==null)break e;f=zn({},f,l);break e;case 2:Wi=!0}}a.callback!==null&&(e.flags|=32,l=o.effects,l===null?o.effects=[a]:l.push(a))}else h={eventTime:h,lane:l,tag:a.tag,payload:a.payload,callback:a.callback,next:null},d===null?(u=d=h,c=f):d=d.next=h,i|=l;if(a=a.next,a===null){if(l=o.shared.pending,l===null)break;a=l.next,l.next=null,o.lastBaseUpdate=l,o.shared.pending=null}}while(1);d===null&&(c=f),o.baseState=c,o.firstBaseUpdate=u,o.lastBaseUpdate=d,Bp|=i,e.lanes=i,e.memoizedState=f}}function PE(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],o=r.callback;if(o!==null){if(r.callback=null,r=n,typeof o!="function")throw Error(Oe(191,o));o.call(r)}}}var o5=new Xm.Component().refs;function om(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:zn({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var ig={isMounted:function(e){return(e=e._reactInternals)?Tl(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=_o(),o=os(e),a=ns(r,o);a.payload=t,n!=null&&(a.callback=n),rs(e,a),as(e,o,r)},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=_o(),o=os(e),a=ns(r,o);a.tag=1,a.payload=t,n!=null&&(a.callback=n),rs(e,a),as(e,o,r)},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=_o(),r=os(e),o=ns(n,r);o.tag=2,t!=null&&(o.callback=t),rs(e,o),as(e,r,n)}};function IE(e,t,n,r,o,a,i){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,a,i):t.prototype&&t.prototype.isPureReactComponent?!ep(n,r)||!ep(o,a):!0}function a5(e,t,n){var r=!1,o=ps,a=t.contextType;return typeof a=="object"&&a!==null?a=Zo(a):(o=po(t)?pl:Wr.current,r=t.contextTypes,a=(r=r!=null)?Ic(e,o):ps),t=new t(n,a),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=ig,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=o,e.__reactInternalMemoizedMaskedChildContext=a),t}function $E(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&ig.enqueueReplaceState(t,t.state,null)}function j0(e,t,n,r){var o=e.stateNode;o.props=n,o.state=e.memoizedState,o.refs=o5,oS(e);var a=t.contextType;typeof a=="object"&&a!==null?o.context=Zo(a):(a=po(t)?pl:Wr.current,o.context=Ic(e,a)),rp(e,n,o,r),o.state=e.memoizedState,a=t.getDerivedStateFromProps,typeof a=="function"&&(om(e,t,a,n),o.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof o.getSnapshotBeforeUpdate=="function"||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(t=o.state,typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount(),t!==o.state&&ig.enqueueReplaceState(o,o.state,null),rp(e,n,o,r),o.state=e.memoizedState),typeof o.componentDidMount=="function"&&(e.flags|=4)}var If=Array.isArray;function Mu(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(Oe(309));var r=n.stateNode}if(!r)throw Error(Oe(147,e));var o=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===o?t.ref:(t=function(a){var i=r.refs;i===o5&&(i=r.refs={}),a===null?delete i[o]:i[o]=a},t._stringRef=o,t)}if(typeof e!="string")throw Error(Oe(284));if(!n._owner)throw Error(Oe(290,e))}return e}function $f(e,t){if(e.type!=="textarea")throw Error(Oe(31,Object.prototype.toString.call(t)==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":t))}function i5(e){function t(v,b){if(e){var w=v.lastEffect;w!==null?(w.nextEffect=b,v.lastEffect=b):v.firstEffect=v.lastEffect=b,b.nextEffect=null,b.flags=8}}function n(v,b){if(!e)return null;for(;b!==null;)t(v,b),b=b.sibling;return null}function r(v,b){for(v=new Map;b!==null;)b.key!==null?v.set(b.key,b):v.set(b.index,b),b=b.sibling;return v}function o(v,b){return v=hs(v,b),v.index=0,v.sibling=null,v}function a(v,b,w){return v.index=w,e?(w=v.alternate,w!==null?(w=w.index,w<b?(v.flags=2,b):w):(v.flags=2,b)):b}function i(v){return e&&v.alternate===null&&(v.flags=2),v}function l(v,b,w,x){return b===null||b.tag!==6?(b=e1(w,v.mode,x),b.return=v,b):(b=o(b,w),b.return=v,b)}function c(v,b,w,x){return b!==null&&b.elementType===w.type?(x=o(b,w.props),x.ref=Mu(v,b,w),x.return=v,x):(x=_h(w.type,w.key,w.props,null,v.mode,x),x.ref=Mu(v,b,w),x.return=v,x)}function u(v,b,w,x){return b===null||b.tag!==4||b.stateNode.containerInfo!==w.containerInfo||b.stateNode.implementation!==w.implementation?(b=t1(w,v.mode,x),b.return=v,b):(b=o(b,w.children||[]),b.return=v,b)}function d(v,b,w,x,E){return b===null||b.tag!==7?(b=yc(w,v.mode,x,E),b.return=v,b):(b=o(b,w),b.return=v,b)}function f(v,b,w){if(typeof b=="string"||typeof b=="number")return b=e1(""+b,v.mode,w),b.return=v,b;if(typeof b=="object"&&b!==null){switch(b.$$typeof){case ld:return w=_h(b.type,b.key,b.props,null,v.mode,w),w.ref=Mu(v,null,b),w.return=v,w;case Qs:return b=t1(b,v.mode,w),b.return=v,b}if(If(b)||Pu(b))return b=yc(b,v.mode,w,null),b.return=v,b;$f(v,b)}return null}function h(v,b,w,x){var E=b!==null?b.key:null;if(typeof w=="string"||typeof w=="number")return E!==null?null:l(v,b,""+w,x);if(typeof w=="object"&&w!==null){switch(w.$$typeof){case ld:return w.key===E?w.type===Hi?d(v,b,w.props.children,x,E):c(v,b,w,x):null;case Qs:return w.key===E?u(v,b,w,x):null}if(If(w)||Pu(w))return E!==null?null:d(v,b,w,x,null);$f(v,w)}return null}function m(v,b,w,x,E){if(typeof x=="string"||typeof x=="number")return v=v.get(w)||null,l(b,v,""+x,E);if(typeof x=="object"&&x!==null){switch(x.$$typeof){case ld:return v=v.get(x.key===null?w:x.key)||null,x.type===Hi?d(b,v,x.props.children,E,x.key):c(b,v,x,E);case Qs:return v=v.get(x.key===null?w:x.key)||null,u(b,v,x,E)}if(If(x)||Pu(x))return v=v.get(w)||null,d(b,v,x,E,null);$f(b,x)}return null}function y(v,b,w,x){for(var E=null,A=null,k=b,_=b=0,$=null;k!==null&&_<w.length;_++){k.index>_?($=k,k=null):$=k.sibling;var L=h(v,k,w[_],x);if(L===null){k===null&&(k=$);break}e&&k&&L.alternate===null&&t(v,k),b=a(L,b,_),A===null?E=L:A.sibling=L,A=L,k=$}if(_===w.length)return n(v,k),E;if(k===null){for(;_<w.length;_++)k=f(v,w[_],x),k!==null&&(b=a(k,b,_),A===null?E=k:A.sibling=k,A=k);return E}for(k=r(v,k);_<w.length;_++)$=m(k,v,_,w[_],x),$!==null&&(e&&$.alternate!==null&&k.delete($.key===null?_:$.key),b=a($,b,_),A===null?E=$:A.sibling=$,A=$);return e&&k.forEach(function(O){return t(v,O)}),E}function g(v,b,w,x){var E=Pu(w);if(typeof E!="function")throw Error(Oe(150));if(w=E.call(w),w==null)throw Error(Oe(151));for(var A=E=null,k=b,_=b=0,$=null,L=w.next();k!==null&&!L.done;_++,L=w.next()){k.index>_?($=k,k=null):$=k.sibling;var O=h(v,k,L.value,x);if(O===null){k===null&&(k=$);break}e&&k&&O.alternate===null&&t(v,k),b=a(O,b,_),A===null?E=O:A.sibling=O,A=O,k=$}if(L.done)return n(v,k),E;if(k===null){for(;!L.done;_++,L=w.next())L=f(v,L.value,x),L!==null&&(b=a(L,b,_),A===null?E=L:A.sibling=L,A=L);return E}for(k=r(v,k);!L.done;_++,L=w.next())L=m(k,v,_,L.value,x),L!==null&&(e&&L.alternate!==null&&k.delete(L.key===null?_:L.key),b=a(L,b,_),A===null?E=L:A.sibling=L,A=L);return e&&k.forEach(function(P){return t(v,P)}),E}return function(v,b,w,x){var E=typeof w=="object"&&w!==null&&w.type===Hi&&w.key===null;E&&(w=w.props.children);var A=typeof w=="object"&&w!==null;if(A)switch(w.$$typeof){case ld:e:{for(A=w.key,E=b;E!==null;){if(E.key===A){switch(E.tag){case 7:if(w.type===Hi){n(v,E.sibling),b=o(E,w.props.children),b.return=v,v=b;break e}break;default:if(E.elementType===w.type){n(v,E.sibling),b=o(E,w.props),b.ref=Mu(v,E,w),b.return=v,v=b;break e}}n(v,E);break}else t(v,E);E=E.sibling}w.type===Hi?(b=yc(w.props.children,v.mode,x,w.key),b.return=v,v=b):(x=_h(w.type,w.key,w.props,null,v.mode,x),x.ref=Mu(v,b,w),x.return=v,v=x)}return i(v);case Qs:e:{for(E=w.key;b!==null;){if(b.key===E)if(b.tag===4&&b.stateNode.containerInfo===w.containerInfo&&b.stateNode.implementation===w.implementation){n(v,b.sibling),b=o(b,w.children||[]),b.return=v,v=b;break e}else{n(v,b);break}else t(v,b);b=b.sibling}b=t1(w,v.mode,x),b.return=v,v=b}return i(v)}if(typeof w=="string"||typeof w=="number")return w=""+w,b!==null&&b.tag===6?(n(v,b.sibling),b=o(b,w),b.return=v,v=b):(n(v,b),b=e1(w,v.mode,x),b.return=v,v=b),i(v);if(If(w))return y(v,b,w,x);if(Pu(w))return g(v,b,w,x);if(A&&$f(v,w),typeof w>"u"&&!E)switch(v.tag){case 1:case 22:case 0:case 11:case 15:throw Error(Oe(152,cc(v.type)||"Component"))}return n(v,b)}}var am=i5(!0),s5=i5(!1),Dp={},Ha=Es(Dp),op=Es(Dp),ap=Es(Dp);function tl(e){if(e===Dp)throw Error(Oe(174));return e}function U0(e,t){switch(Xn(ap,t),Xn(op,e),Xn(Ha,Dp),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:k0(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=k0(t,e)}Ln(Ha),Xn(Ha,t)}function Oc(){Ln(Ha),Ln(op),Ln(ap)}function OE(e){tl(ap.current);var t=tl(Ha.current),n=k0(t,e.type);t!==n&&(Xn(op,e),Xn(Ha,n))}function aS(e){op.current===e&&(Ln(Ha),Ln(op))}var Yn=Es(0);function im(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&64)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var vi=null,Ki=null,Va=!1;function l5(e,t){var n=Go(5,null,null,0);n.elementType="DELETED",n.type="DELETED",n.stateNode=t,n.return=e,n.flags=8,e.lastEffect!==null?(e.lastEffect.nextEffect=n,e.lastEffect=n):e.firstEffect=e.lastEffect=n}function LE(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,!0):!1;case 13:return!1;default:return!1}}function W0(e){if(Va){var t=Ki;if(t){var n=t;if(!LE(e,t)){if(t=fc(n.nextSibling),!t||!LE(e,t)){e.flags=e.flags&-1025|2,Va=!1,vi=e;return}l5(vi,n)}vi=e,Ki=fc(t.firstChild)}else e.flags=e.flags&-1025|2,Va=!1,vi=e}}function NE(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;vi=e}function Of(e){if(e!==vi)return!1;if(!Va)return NE(e),Va=!0,!1;var t=e.type;if(e.tag!==5||t!=="head"&&t!=="body"&&!D0(t,e.memoizedProps))for(t=Ki;t;)l5(e,t),t=fc(t.nextSibling);if(NE(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(Oe(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){Ki=fc(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}Ki=null}}else Ki=vi?fc(e.stateNode.nextSibling):null;return!0}function Xy(){Ki=vi=null,Va=!1}var mc=[];function iS(){for(var e=0;e<mc.length;e++)mc[e]._workInProgressVersionPrimary=null;mc.length=0}var kd=El.ReactCurrentDispatcher,Yo=El.ReactCurrentBatchConfig,ip=0,Qn=null,Fr=null,Ir=null,sm=!1,Ad=!1;function io(){throw Error(Oe(321))}function sS(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Vo(e[n],t[n]))return!1;return!0}function lS(e,t,n,r,o,a){if(ip=a,Qn=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,kd.current=e===null||e.memoizedState===null?t6:n6,e=n(r,o),Ad){a=0;do{if(Ad=!1,!(25>a))throw Error(Oe(301));a+=1,Ir=Fr=null,t.updateQueue=null,kd.current=r6,e=n(r,o)}while(Ad)}if(kd.current=dm,t=Fr!==null&&Fr.next!==null,ip=0,Ir=Fr=Qn=null,sm=!1,t)throw Error(Oe(300));return e}function nl(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ir===null?Qn.memoizedState=Ir=e:Ir=Ir.next=e,Ir}function kl(){if(Fr===null){var e=Qn.alternate;e=e!==null?e.memoizedState:null}else e=Fr.next;var t=Ir===null?Qn.memoizedState:Ir.next;if(t!==null)Ir=t,Fr=e;else{if(e===null)throw Error(Oe(310));Fr=e,e={memoizedState:Fr.memoizedState,baseState:Fr.baseState,baseQueue:Fr.baseQueue,queue:Fr.queue,next:null},Ir===null?Qn.memoizedState=Ir=e:Ir=Ir.next=e}return Ir}function ja(e,t){return typeof t=="function"?t(e):t}function Du(e){var t=kl(),n=t.queue;if(n===null)throw Error(Oe(311));n.lastRenderedReducer=e;var r=Fr,o=r.baseQueue,a=n.pending;if(a!==null){if(o!==null){var i=o.next;o.next=a.next,a.next=i}r.baseQueue=o=a,n.pending=null}if(o!==null){o=o.next,r=r.baseState;var l=i=a=null,c=o;do{var u=c.lane;if((ip&u)===u)l!==null&&(l=l.next={lane:0,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null}),r=c.eagerReducer===e?c.eagerState:e(r,c.action);else{var d={lane:u,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null};l===null?(i=l=d,a=r):l=l.next=d,Qn.lanes|=u,Bp|=u}c=c.next}while(c!==null&&c!==o);l===null?a=r:l.next=i,Vo(r,t.memoizedState)||(ya=!0),t.memoizedState=r,t.baseState=a,t.baseQueue=l,n.lastRenderedState=r}return[t.memoizedState,n.dispatch]}function Bu(e){var t=kl(),n=t.queue;if(n===null)throw Error(Oe(311));n.lastRenderedReducer=e;var r=n.dispatch,o=n.pending,a=t.memoizedState;if(o!==null){n.pending=null;var i=o=o.next;do a=e(a,i.action),i=i.next;while(i!==o);Vo(a,t.memoizedState)||(ya=!0),t.memoizedState=a,t.baseQueue===null&&(t.baseState=a),n.lastRenderedState=a}return[a,r]}function ME(e,t,n){var r=t._getVersion;r=r(t._source);var o=t._workInProgressVersionPrimary;if(o!==null?e=o===r:(e=e.mutableReadLanes,(e=(ip&e)===e)&&(t._workInProgressVersionPrimary=r,mc.push(t))),e)return n(t._source);throw mc.push(t),Error(Oe(350))}function c5(e,t,n,r){var o=Zr;if(o===null)throw Error(Oe(349));var a=t._getVersion,i=a(t._source),l=kd.current,c=l.useState(function(){return ME(o,t,n)}),u=c[1],d=c[0];c=Ir;var f=e.memoizedState,h=f.refs,m=h.getSnapshot,y=f.source;f=f.subscribe;var g=Qn;return e.memoizedState={refs:h,source:t,subscribe:r},l.useEffect(function(){h.getSnapshot=n,h.setSnapshot=u;var v=a(t._source);if(!Vo(i,v)){v=n(t._source),Vo(d,v)||(u(v),v=os(g),o.mutableReadLanes|=v&o.pendingLanes),v=o.mutableReadLanes,o.entangledLanes|=v;for(var b=o.entanglements,w=v;0<w;){var x=31-ds(w),E=1<<x;b[x]|=v,w&=~E}}},[n,t,r]),l.useEffect(function(){return r(t._source,function(){var v=h.getSnapshot,b=h.setSnapshot;try{b(v(t._source));var w=os(g);o.mutableReadLanes|=w&o.pendingLanes}catch(x){b(function(){throw x})}})},[t,r]),Vo(m,n)&&Vo(y,t)&&Vo(f,r)||(e={pending:null,dispatch:null,lastRenderedReducer:ja,lastRenderedState:d},e.dispatch=u=dS.bind(null,Qn,e),c.queue=e,c.baseQueue=null,d=ME(o,t,n),c.memoizedState=c.baseState=d),d}function u5(e,t,n){var r=kl();return c5(r,e,t,n)}function Fu(e){var t=nl();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e=t.queue={pending:null,dispatch:null,lastRenderedReducer:ja,lastRenderedState:e},e=e.dispatch=dS.bind(null,Qn,e),[t.memoizedState,e]}function lm(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=Qn.updateQueue,t===null?(t={lastEffect:null},Qn.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function DE(e){var t=nl();return e={current:e},t.memoizedState=e}function cm(){return kl().memoizedState}function H0(e,t,n,r){var o=nl();Qn.flags|=e,o.memoizedState=lm(1|t,n,void 0,r===void 0?null:r)}function cS(e,t,n,r){var o=kl();r=r===void 0?null:r;var a=void 0;if(Fr!==null){var i=Fr.memoizedState;if(a=i.destroy,r!==null&&sS(r,i.deps)){lm(t,n,a,r);return}}Qn.flags|=e,o.memoizedState=lm(1|t,n,a,r)}function BE(e,t){return H0(516,4,e,t)}function um(e,t){return cS(516,4,e,t)}function d5(e,t){return cS(4,2,e,t)}function p5(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function f5(e,t,n){return n=n!=null?n.concat([e]):null,cS(4,2,p5.bind(null,t,e),n)}function uS(){}function h5(e,t){var n=kl();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&sS(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function m5(e,t){var n=kl();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&sS(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function e6(e,t){var n=$c();fl(98>n?98:n,function(){e(!0)}),fl(97<n?97:n,function(){var r=Yo.transition;Yo.transition=1;try{e(!1),t()}finally{Yo.transition=r}})}function dS(e,t,n){var r=_o(),o=os(e),a={lane:o,action:n,eagerReducer:null,eagerState:null,next:null},i=t.pending;if(i===null?a.next=a:(a.next=i.next,i.next=a),t.pending=a,i=e.alternate,e===Qn||i!==null&&i===Qn)Ad=sm=!0;else{if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var l=t.lastRenderedState,c=i(l,n);if(a.eagerReducer=i,a.eagerState=c,Vo(c,l))return}catch{}finally{}as(e,o,r)}}var dm={readContext:Zo,useCallback:io,useContext:io,useEffect:io,useImperativeHandle:io,useLayoutEffect:io,useMemo:io,useReducer:io,useRef:io,useState:io,useDebugValue:io,useDeferredValue:io,useTransition:io,useMutableSource:io,useOpaqueIdentifier:io,unstable_isNewReconciler:!1},t6={readContext:Zo,useCallback:function(e,t){return nl().memoizedState=[e,t===void 0?null:t],e},useContext:Zo,useEffect:BE,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,H0(4,2,p5.bind(null,t,e),n)},useLayoutEffect:function(e,t){return H0(4,2,e,t)},useMemo:function(e,t){var n=nl();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=nl();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e=r.queue={pending:null,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},e=e.dispatch=dS.bind(null,Qn,e),[r.memoizedState,e]},useRef:DE,useState:Fu,useDebugValue:uS,useDeferredValue:function(e){var t=Fu(e),n=t[0],r=t[1];return BE(function(){var o=Yo.transition;Yo.transition=1;try{r(e)}finally{Yo.transition=o}},[e]),n},useTransition:function(){var e=Fu(!1),t=e[0];return e=e6.bind(null,e[1]),DE(e),[e,t]},useMutableSource:function(e,t,n){var r=nl();return r.memoizedState={refs:{getSnapshot:t,setSnapshot:null},source:e,subscribe:n},c5(r,e,t,n)},useOpaqueIdentifier:function(){if(Va){var e=!1,t=KD(function(){throw e||(e=!0,n("r:"+(qy++).toString(36))),Error(Oe(355))}),n=Fu(t)[1];return!(Qn.mode&2)&&(Qn.flags|=516,lm(5,function(){n("r:"+(qy++).toString(36))},void 0,null)),t}return t="r:"+(qy++).toString(36),Fu(t),t},unstable_isNewReconciler:!1},n6={readContext:Zo,useCallback:h5,useContext:Zo,useEffect:um,useImperativeHandle:f5,useLayoutEffect:d5,useMemo:m5,useReducer:Du,useRef:cm,useState:function(){return Du(ja)},useDebugValue:uS,useDeferredValue:function(e){var t=Du(ja),n=t[0],r=t[1];return um(function(){var o=Yo.transition;Yo.transition=1;try{r(e)}finally{Yo.transition=o}},[e]),n},useTransition:function(){var e=Du(ja)[0];return[cm().current,e]},useMutableSource:u5,useOpaqueIdentifier:function(){return Du(ja)[0]},unstable_isNewReconciler:!1},r6={readContext:Zo,useCallback:h5,useContext:Zo,useEffect:um,useImperativeHandle:f5,useLayoutEffect:d5,useMemo:m5,useReducer:Bu,useRef:cm,useState:function(){return Bu(ja)},useDebugValue:uS,useDeferredValue:function(e){var t=Bu(ja),n=t[0],r=t[1];return um(function(){var o=Yo.transition;Yo.transition=1;try{r(e)}finally{Yo.transition=o}},[e]),n},useTransition:function(){var e=Bu(ja)[0];return[cm().current,e]},useMutableSource:u5,useOpaqueIdentifier:function(){return Bu(ja)[0]},unstable_isNewReconciler:!1},o6=El.ReactCurrentOwner,ya=!1;function co(e,t,n,r){t.child=e===null?s5(t,null,n,r):am(t,e.child,n,r)}function FE(e,t,n,r,o){n=n.render;var a=t.ref;return hc(t,o),r=lS(e,t,n,r,a,o),e!==null&&!ya?(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~o,yi(e,t,o)):(t.flags|=1,co(e,t,r,o),t.child)}function zE(e,t,n,r,o,a){if(e===null){var i=n.type;return typeof i=="function"&&!vS(i)&&i.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=i,g5(e,t,i,r,o,a)):(e=_h(n.type,null,r,t,t.mode,a),e.ref=t.ref,e.return=t,t.child=e)}return i=e.child,!(o&a)&&(o=i.memoizedProps,n=n.compare,n=n!==null?n:ep,n(o,r)&&e.ref===t.ref)?yi(e,t,a):(t.flags|=1,e=hs(i,r),e.ref=t.ref,e.return=t,t.child=e)}function g5(e,t,n,r,o,a){if(e!==null&&ep(e.memoizedProps,r)&&e.ref===t.ref)if(ya=!1,(a&o)!==0)e.flags&16384&&(ya=!0);else return t.lanes=e.lanes,yi(e,t,a);return V0(e,t,n,r,a)}function Jy(e,t,n){var r=t.pendingProps,o=r.children,a=e!==null?e.memoizedState:null;if(r.mode==="hidden"||r.mode==="unstable-defer-without-hiding")if(!(t.mode&4))t.memoizedState={baseLanes:0},Nf(t,n);else if(n&1073741824)t.memoizedState={baseLanes:0},Nf(t,a!==null?a.baseLanes:n);else return e=a!==null?a.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e},Nf(t,e),null;else a!==null?(r=a.baseLanes|n,t.memoizedState=null):r=n,Nf(t,r);return co(e,t,o,n),t.child}function v5(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=128)}function V0(e,t,n,r,o){var a=po(n)?pl:Wr.current;return a=Ic(t,a),hc(t,o),n=lS(e,t,n,r,a,o),e!==null&&!ya?(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~o,yi(e,t,o)):(t.flags|=1,co(e,t,n,o),t.child)}function jE(e,t,n,r,o){if(po(n)){var a=!0;Ch(t)}else a=!1;if(hc(t,o),t.stateNode===null)e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),a5(t,n,r),j0(t,n,r,o),r=!0;else if(e===null){var i=t.stateNode,l=t.memoizedProps;i.props=l;var c=i.context,u=n.contextType;typeof u=="object"&&u!==null?u=Zo(u):(u=po(n)?pl:Wr.current,u=Ic(t,u));var d=n.getDerivedStateFromProps,f=typeof d=="function"||typeof i.getSnapshotBeforeUpdate=="function";f||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(l!==r||c!==u)&&$E(t,i,r,u),Wi=!1;var h=t.memoizedState;i.state=h,rp(t,r,i,o),c=t.memoizedState,l!==r||h!==c||uo.current||Wi?(typeof d=="function"&&(om(t,n,d,r),c=t.memoizedState),(l=Wi||IE(t,n,l,r,h,c,u))?(f||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(t.flags|=4)):(typeof i.componentDidMount=="function"&&(t.flags|=4),t.memoizedProps=r,t.memoizedState=c),i.props=r,i.state=c,i.context=u,r=l):(typeof i.componentDidMount=="function"&&(t.flags|=4),r=!1)}else{i=t.stateNode,r5(e,t),l=t.memoizedProps,u=t.type===t.elementType?l:ma(t.type,l),i.props=u,f=t.pendingProps,h=i.context,c=n.contextType,typeof c=="object"&&c!==null?c=Zo(c):(c=po(n)?pl:Wr.current,c=Ic(t,c));var m=n.getDerivedStateFromProps;(d=typeof m=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(l!==f||h!==c)&&$E(t,i,r,c),Wi=!1,h=t.memoizedState,i.state=h,rp(t,r,i,o);var y=t.memoizedState;l!==f||h!==y||uo.current||Wi?(typeof m=="function"&&(om(t,n,m,r),y=t.memoizedState),(u=Wi||IE(t,n,u,r,h,y,c))?(d||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(r,y,c),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(r,y,c)),typeof i.componentDidUpdate=="function"&&(t.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(t.flags|=256)):(typeof i.componentDidUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=256),t.memoizedProps=r,t.memoizedState=y),i.props=r,i.state=y,i.context=c,r=u):(typeof i.componentDidUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=256),r=!1)}return G0(e,t,n,r,a,o)}function G0(e,t,n,r,o,a){v5(e,t);var i=(t.flags&64)!==0;if(!r&&!i)return o&&kE(t,n,!1),yi(e,t,a);r=t.stateNode,o6.current=t;var l=i&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&i?(t.child=am(t,e.child,null,a),t.child=am(t,null,l,a)):co(e,t,l,a),t.memoizedState=r.state,o&&kE(t,n,!0),t.child}function UE(e){var t=e.stateNode;t.pendingContext?TE(e,t.pendingContext,t.pendingContext!==t.context):t.context&&TE(e,t.context,!1),U0(e,t.containerInfo)}var Lf={dehydrated:null,retryLane:0};function WE(e,t,n){var r=t.pendingProps,o=Yn.current,a=!1,i;return(i=(t.flags&64)!==0)||(i=e!==null&&e.memoizedState===null?!1:(o&2)!==0),i?(a=!0,t.flags&=-65):e!==null&&e.memoizedState===null||r.fallback===void 0||r.unstable_avoidThisFallback===!0||(o|=1),Xn(Yn,o&1),e===null?(r.fallback!==void 0&&W0(t),e=r.children,o=r.fallback,a?(e=HE(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Lf,e):typeof r.unstable_expectedLoadTime=="number"?(e=HE(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Lf,t.lanes=33554432,e):(n=yS({mode:"visible",children:e},t.mode,n,null),n.return=t,t.child=n)):e.memoizedState!==null?a?(r=GE(e,t,r.children,r.fallback,n),a=t.child,o=e.child.memoizedState,a.memoizedState=o===null?{baseLanes:n}:{baseLanes:o.baseLanes|n},a.childLanes=e.childLanes&~n,t.memoizedState=Lf,r):(n=VE(e,t,r.children,n),t.memoizedState=null,n):a?(r=GE(e,t,r.children,r.fallback,n),a=t.child,o=e.child.memoizedState,a.memoizedState=o===null?{baseLanes:n}:{baseLanes:o.baseLanes|n},a.childLanes=e.childLanes&~n,t.memoizedState=Lf,r):(n=VE(e,t,r.children,n),t.memoizedState=null,n)}function HE(e,t,n,r){var o=e.mode,a=e.child;return t={mode:"hidden",children:t},!(o&2)&&a!==null?(a.childLanes=0,a.pendingProps=t):a=yS(t,o,0,null),n=yc(n,o,r,null),a.return=e,n.return=e,a.sibling=n,e.child=a,n}function VE(e,t,n,r){var o=e.child;return e=o.sibling,n=hs(o,{mode:"visible",children:n}),!(t.mode&2)&&(n.lanes=r),n.return=t,n.sibling=null,e!==null&&(e.nextEffect=null,e.flags=8,t.firstEffect=t.lastEffect=e),t.child=n}function GE(e,t,n,r,o){var a=t.mode,i=e.child;e=i.sibling;var l={mode:"hidden",children:n};return!(a&2)&&t.child!==i?(n=t.child,n.childLanes=0,n.pendingProps=l,i=n.lastEffect,i!==null?(t.firstEffect=n.firstEffect,t.lastEffect=i,i.nextEffect=null):t.firstEffect=t.lastEffect=null):n=hs(i,l),e!==null?r=hs(e,r):(r=yc(r,a,o,null),r.flags|=2),r.return=t,n.return=t,n.sibling=r,t.child=n,r}function qE(e,t){e.lanes|=t;var n=e.alternate;n!==null&&(n.lanes|=t),n5(e.return,t)}function Qy(e,t,n,r,o,a){var i=e.memoizedState;i===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:o,lastEffect:a}:(i.isBackwards=t,i.rendering=null,i.renderingStartTime=0,i.last=r,i.tail=n,i.tailMode=o,i.lastEffect=a)}function KE(e,t,n){var r=t.pendingProps,o=r.revealOrder,a=r.tail;if(co(e,t,r.children,n),r=Yn.current,r&2)r=r&1|2,t.flags|=64;else{if(e!==null&&e.flags&64)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&qE(e,n);else if(e.tag===19)qE(e,n);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(Xn(Yn,r),!(t.mode&2))t.memoizedState=null;else switch(o){case"forwards":for(n=t.child,o=null;n!==null;)e=n.alternate,e!==null&&im(e)===null&&(o=n),n=n.sibling;n=o,n===null?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),Qy(t,!1,o,n,a,t.lastEffect);break;case"backwards":for(n=null,o=t.child,t.child=null;o!==null;){if(e=o.alternate,e!==null&&im(e)===null){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}Qy(t,!0,n,null,a,t.lastEffect);break;case"together":Qy(t,!1,null,null,void 0,t.lastEffect);break;default:t.memoizedState=null}return t.child}function yi(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Bp|=t.lanes,n&t.childLanes){if(e!==null&&t.child!==e.child)throw Error(Oe(153));if(t.child!==null){for(e=t.child,n=hs(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=hs(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}return null}var y5,q0,b5,w5;y5=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};q0=function(){};b5=function(e,t,n,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,tl(Ha.current);var a=null;switch(n){case"input":o=w0(e,o),r=w0(e,r),a=[];break;case"option":o=C0(e,o),r=C0(e,r),a=[];break;case"select":o=zn({},o,{value:void 0}),r=zn({},r,{value:void 0}),a=[];break;case"textarea":o=E0(e,o),r=E0(e,r),a=[];break;default:typeof o.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Qh)}A0(n,r);var i;n=null;for(u in o)if(!r.hasOwnProperty(u)&&o.hasOwnProperty(u)&&o[u]!=null)if(u==="style"){var l=o[u];for(i in l)l.hasOwnProperty(i)&&(n||(n={}),n[i]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(qd.hasOwnProperty(u)?a||(a=[]):(a=a||[]).push(u,null));for(u in r){var c=r[u];if(l=o!=null?o[u]:void 0,r.hasOwnProperty(u)&&c!==l&&(c!=null||l!=null))if(u==="style")if(l){for(i in l)!l.hasOwnProperty(i)||c&&c.hasOwnProperty(i)||(n||(n={}),n[i]="");for(i in c)c.hasOwnProperty(i)&&l[i]!==c[i]&&(n||(n={}),n[i]=c[i])}else n||(a||(a=[]),a.push(u,n)),n=c;else u==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,l=l?l.__html:void 0,c!=null&&l!==c&&(a=a||[]).push(u,c)):u==="children"?typeof c!="string"&&typeof c!="number"||(a=a||[]).push(u,""+c):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(qd.hasOwnProperty(u)?(c!=null&&u==="onScroll"&&$n("scroll",e),a||l===c||(a=[])):typeof c=="object"&&c!==null&&c.$$typeof===Bw?c.toString():(a=a||[]).push(u,c))}n&&(a=a||[]).push("style",n);var u=a;(t.updateQueue=u)&&(t.flags|=4)}};w5=function(e,t,n,r){n!==r&&(t.flags|=4)};function zu(e,t){if(!Va)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function a6(e,t,n){var r=t.pendingProps;switch(t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:return po(t.type)&&em(),null;case 3:return Oc(),Ln(uo),Ln(Wr),iS(),r=t.stateNode,r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Of(t)?t.flags|=4:r.hydrate||(t.flags|=256)),q0(t),null;case 5:aS(t);var o=tl(ap.current);if(n=t.type,e!==null&&t.stateNode!=null)b5(e,t,n,r,o),e.ref!==t.ref&&(t.flags|=128);else{if(!r){if(t.stateNode===null)throw Error(Oe(166));return null}if(e=tl(Ha.current),Of(t)){r=t.stateNode,n=t.type;var a=t.memoizedProps;switch(r[qi]=t,r[Zh]=a,n){case"dialog":$n("cancel",r),$n("close",r);break;case"iframe":case"object":case"embed":$n("load",r);break;case"video":case"audio":for(e=0;e<ud.length;e++)$n(ud[e],r);break;case"source":$n("error",r);break;case"img":case"image":case"link":$n("error",r),$n("load",r);break;case"details":$n("toggle",r);break;case"input":K2(r,a),$n("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!a.multiple},$n("invalid",r);break;case"textarea":X2(r,a),$n("invalid",r)}A0(n,a),e=null;for(var i in a)a.hasOwnProperty(i)&&(o=a[i],i==="children"?typeof o=="string"?r.textContent!==o&&(e=["children",o]):typeof o=="number"&&r.textContent!==""+o&&(e=["children",""+o]):qd.hasOwnProperty(i)&&o!=null&&i==="onScroll"&&$n("scroll",r));switch(n){case"input":Af(r),Y2(r,a,!0);break;case"textarea":Af(r),J2(r);break;case"select":case"option":break;default:typeof a.onClick=="function"&&(r.onclick=Qh)}r=e,t.updateQueue=r,r!==null&&(t.flags|=4)}else{switch(i=o.nodeType===9?o:o.ownerDocument,e===T0.html&&(e=fI(n)),e===T0.html?n==="script"?(e=i.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=i.createElement(n,{is:r.is}):(e=i.createElement(n),n==="select"&&(i=e,r.multiple?i.multiple=!0:r.size&&(i.size=r.size))):e=i.createElementNS(e,n),e[qi]=t,e[Zh]=r,y5(e,t,!1,!1),t.stateNode=e,i=_0(n,r),n){case"dialog":$n("cancel",e),$n("close",e),o=r;break;case"iframe":case"object":case"embed":$n("load",e),o=r;break;case"video":case"audio":for(o=0;o<ud.length;o++)$n(ud[o],e);o=r;break;case"source":$n("error",e),o=r;break;case"img":case"image":case"link":$n("error",e),$n("load",e),o=r;break;case"details":$n("toggle",e),o=r;break;case"input":K2(e,r),o=w0(e,r),$n("invalid",e);break;case"option":o=C0(e,r);break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=zn({},r,{value:void 0}),$n("invalid",e);break;case"textarea":X2(e,r),o=E0(e,r),$n("invalid",e);break;default:o=r}A0(n,o);var l=o;for(a in l)if(l.hasOwnProperty(a)){var c=l[a];a==="style"?gI(e,c):a==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,c!=null&&hI(e,c)):a==="children"?typeof c=="string"?(n!=="textarea"||c!=="")&&Kd(e,c):typeof c=="number"&&Kd(e,""+c):a!=="suppressContentEditableWarning"&&a!=="suppressHydrationWarning"&&a!=="autoFocus"&&(qd.hasOwnProperty(a)?c!=null&&a==="onScroll"&&$n("scroll",e):c!=null&&$w(e,a,c,i))}switch(n){case"input":Af(e),Y2(e,r,!1);break;case"textarea":Af(e),J2(e);break;case"option":r.value!=null&&e.setAttribute("value",""+us(r.value));break;case"select":e.multiple=!!r.multiple,a=r.value,a!=null?uc(e,!!r.multiple,a,!1):r.defaultValue!=null&&uc(e,!!r.multiple,r.defaultValue,!0);break;default:typeof o.onClick=="function"&&(e.onclick=Qh)}qI(n,r)&&(t.flags|=4)}t.ref!==null&&(t.flags|=128)}return null;case 6:if(e&&t.stateNode!=null)w5(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(Oe(166));n=tl(ap.current),tl(Ha.current),Of(t)?(r=t.stateNode,n=t.memoizedProps,r[qi]=t,r.nodeValue!==n&&(t.flags|=4)):(r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[qi]=t,t.stateNode=r)}return null;case 13:return Ln(Yn),r=t.memoizedState,t.flags&64?(t.lanes=n,t):(r=r!==null,n=!1,e===null?t.memoizedProps.fallback!==void 0&&Of(t):n=e.memoizedState!==null,r&&!n&&t.mode&2&&(e===null&&t.memoizedProps.unstable_avoidThisFallback!==!0||Yn.current&1?Or===0&&(Or=3):((Or===0||Or===3)&&(Or=4),Zr===null||!(Bp&134217727)&&!(Jc&134217727)||gc(Zr,Ur))),(r||n)&&(t.flags|=4),null);case 4:return Oc(),q0(t),e===null&&HI(t.stateNode.containerInfo),null;case 10:return rS(t),null;case 17:return po(t.type)&&em(),null;case 19:if(Ln(Yn),r=t.memoizedState,r===null)return null;if(a=(t.flags&64)!==0,i=r.rendering,i===null)if(a)zu(r,!1);else{if(Or!==0||e!==null&&e.flags&64)for(e=t.child;e!==null;){if(i=im(e),i!==null){for(t.flags|=64,zu(r,!1),a=i.updateQueue,a!==null&&(t.updateQueue=a,t.flags|=4),r.lastEffect===null&&(t.firstEffect=null),t.lastEffect=r.lastEffect,r=n,n=t.child;n!==null;)a=n,e=r,a.flags&=2,a.nextEffect=null,a.firstEffect=null,a.lastEffect=null,i=a.alternate,i===null?(a.childLanes=0,a.lanes=e,a.child=null,a.memoizedProps=null,a.memoizedState=null,a.updateQueue=null,a.dependencies=null,a.stateNode=null):(a.childLanes=i.childLanes,a.lanes=i.lanes,a.child=i.child,a.memoizedProps=i.memoizedProps,a.memoizedState=i.memoizedState,a.updateQueue=i.updateQueue,a.type=i.type,e=i.dependencies,a.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return Xn(Yn,Yn.current&1|2),t.child}e=e.sibling}r.tail!==null&&jr()>Z0&&(t.flags|=64,a=!0,zu(r,!1),t.lanes=33554432)}else{if(!a)if(e=im(i),e!==null){if(t.flags|=64,a=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),zu(r,!0),r.tail===null&&r.tailMode==="hidden"&&!i.alternate&&!Va)return t=t.lastEffect=r.lastEffect,t!==null&&(t.nextEffect=null),null}else 2*jr()-r.renderingStartTime>Z0&&n!==1073741824&&(t.flags|=64,a=!0,zu(r,!1),t.lanes=33554432);r.isBackwards?(i.sibling=t.child,t.child=i):(n=r.last,n!==null?n.sibling=i:t.child=i,r.last=i)}return r.tail!==null?(n=r.tail,r.rendering=n,r.tail=n.sibling,r.lastEffect=t.lastEffect,r.renderingStartTime=jr(),n.sibling=null,t=Yn.current,Xn(Yn,a?t&1|2:t&1),n):null;case 23:case 24:return gS(),e!==null&&e.memoizedState!==null!=(t.memoizedState!==null)&&r.mode!=="unstable-defer-without-hiding"&&(t.flags|=4),null}throw Error(Oe(156,t.tag))}function i6(e){switch(e.tag){case 1:po(e.type)&&em();var t=e.flags;return t&4096?(e.flags=t&-4097|64,e):null;case 3:if(Oc(),Ln(uo),Ln(Wr),iS(),t=e.flags,t&64)throw Error(Oe(285));return e.flags=t&-4097|64,e;case 5:return aS(e),null;case 13:return Ln(Yn),t=e.flags,t&4096?(e.flags=t&-4097|64,e):null;case 19:return Ln(Yn),null;case 4:return Oc(),null;case 10:return rS(e),null;case 23:case 24:return gS(),null;default:return null}}function pS(e,t){try{var n="",r=t;do n+=zM(r),r=r.return;while(r);var o=n}catch(a){o=`
|
|
39
|
+
Error generating stack: `+a.message+`
|
|
40
|
+
`+a.stack}return{value:e,source:t,stack:o}}function K0(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var s6=typeof WeakMap=="function"?WeakMap:Map;function S5(e,t,n){n=ns(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){fm||(fm=!0,eb=r),K0(e,t)},n}function x5(e,t,n){n=ns(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var o=t.value;n.payload=function(){return K0(e,t),r(o)}}var a=e.stateNode;return a!==null&&typeof a.componentDidCatch=="function"&&(n.callback=function(){typeof r!="function"&&(Ua===null?Ua=new Set([this]):Ua.add(this),K0(e,t));var i=t.stack;this.componentDidCatch(t.value,{componentStack:i!==null?i:""})}),n}var l6=typeof WeakSet=="function"?WeakSet:Set;function YE(e){var t=e.ref;if(t!==null)if(typeof t=="function")try{t(null)}catch(n){is(e,n)}else t.current=null}function c6(e,t){switch(t.tag){case 0:case 11:case 15:case 22:return;case 1:if(t.flags&256&&e!==null){var n=e.memoizedProps,r=e.memoizedState;e=t.stateNode,t=e.getSnapshotBeforeUpdate(t.elementType===t.type?n:ma(t.type,n),r),e.__reactInternalSnapshotBeforeUpdate=t}return;case 3:t.flags&256&&Zw(t.stateNode.containerInfo);return;case 5:case 6:case 4:case 17:return}throw Error(Oe(163))}function u6(e,t,n){switch(n.tag){case 0:case 11:case 15:case 22:if(t=n.updateQueue,t=t!==null?t.lastEffect:null,t!==null){e=t=t.next;do{if((e.tag&3)===3){var r=e.create;e.destroy=r()}e=e.next}while(e!==t)}if(t=n.updateQueue,t=t!==null?t.lastEffect:null,t!==null){e=t=t.next;do{var o=e;r=o.next,o=o.tag,o&4&&o&1&&(I5(n,e),y6(n,e)),e=r}while(e!==t)}return;case 1:e=n.stateNode,n.flags&4&&(t===null?e.componentDidMount():(r=n.elementType===n.type?t.memoizedProps:ma(n.type,t.memoizedProps),e.componentDidUpdate(r,t.memoizedState,e.__reactInternalSnapshotBeforeUpdate))),t=n.updateQueue,t!==null&&PE(n,t,e);return;case 3:if(t=n.updateQueue,t!==null){if(e=null,n.child!==null)switch(n.child.tag){case 5:e=n.child.stateNode;break;case 1:e=n.child.stateNode}PE(n,t,e)}return;case 5:e=n.stateNode,t===null&&n.flags&4&&qI(n.type,n.memoizedProps)&&e.focus();return;case 6:return;case 4:return;case 12:return;case 13:n.memoizedState===null&&(n=n.alternate,n!==null&&(n=n.memoizedState,n!==null&&(n=n.dehydrated,n!==null&&kI(n))));return;case 19:case 17:case 20:case 21:case 23:case 24:return}throw Error(Oe(163))}function XE(e,t){for(var n=e;;){if(n.tag===5){var r=n.stateNode;if(t)r=r.style,typeof r.setProperty=="function"?r.setProperty("display","none","important"):r.display="none";else{r=n.stateNode;var o=n.memoizedProps.style;o=o!=null&&o.hasOwnProperty("display")?o.display:null,r.style.display=mI("display",o)}}else if(n.tag===6)n.stateNode.nodeValue=t?"":n.memoizedProps;else if((n.tag!==23&&n.tag!==24||n.memoizedState===null||n===e)&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return;n=n.return}n.sibling.return=n.return,n=n.sibling}}function JE(e,t){if(il&&typeof il.onCommitFiberUnmount=="function")try{il.onCommitFiberUnmount(eS,t)}catch{}switch(t.tag){case 0:case 11:case 14:case 15:case 22:if(e=t.updateQueue,e!==null&&(e=e.lastEffect,e!==null)){var n=e=e.next;do{var r=n,o=r.destroy;if(r=r.tag,o!==void 0)if(r&4)I5(t,n);else{r=t;try{o()}catch(a){is(r,a)}}n=n.next}while(n!==e)}break;case 1:if(YE(t),e=t.stateNode,typeof e.componentWillUnmount=="function")try{e.props=t.memoizedProps,e.state=t.memoizedState,e.componentWillUnmount()}catch(a){is(t,a)}break;case 5:YE(t);break;case 4:C5(e,t)}}function QE(e){e.alternate=null,e.child=null,e.dependencies=null,e.firstEffect=null,e.lastEffect=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.return=null,e.updateQueue=null}function ZE(e){return e.tag===5||e.tag===3||e.tag===4}function eT(e){e:{for(var t=e.return;t!==null;){if(ZE(t))break e;t=t.return}throw Error(Oe(160))}var n=t;switch(t=n.stateNode,n.tag){case 5:var r=!1;break;case 3:t=t.containerInfo,r=!0;break;case 4:t=t.containerInfo,r=!0;break;default:throw Error(Oe(161))}n.flags&16&&(Kd(t,""),n.flags&=-17);e:t:for(n=e;;){for(;n.sibling===null;){if(n.return===null||ZE(n.return)){n=null;break e}n=n.return}for(n.sibling.return=n.return,n=n.sibling;n.tag!==5&&n.tag!==6&&n.tag!==18;){if(n.flags&2||n.child===null||n.tag===4)continue t;n.child.return=n,n=n.child}if(!(n.flags&2)){n=n.stateNode;break e}}r?Y0(e,n,t):X0(e,n,t)}function Y0(e,t,n){var r=e.tag,o=r===5||r===6;if(o)e=o?e.stateNode:e.stateNode.instance,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Qh));else if(r!==4&&(e=e.child,e!==null))for(Y0(e,t,n),e=e.sibling;e!==null;)Y0(e,t,n),e=e.sibling}function X0(e,t,n){var r=e.tag,o=r===5||r===6;if(o)e=o?e.stateNode:e.stateNode.instance,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(X0(e,t,n),e=e.sibling;e!==null;)X0(e,t,n),e=e.sibling}function C5(e,t){for(var n=t,r=!1,o,a;;){if(!r){r=n.return;e:for(;;){if(r===null)throw Error(Oe(160));switch(o=r.stateNode,r.tag){case 5:a=!1;break e;case 3:o=o.containerInfo,a=!0;break e;case 4:o=o.containerInfo,a=!0;break e}r=r.return}r=!0}if(n.tag===5||n.tag===6){e:for(var i=e,l=n,c=l;;)if(JE(i,c),c.child!==null&&c.tag!==4)c.child.return=c,c=c.child;else{if(c===l)break e;for(;c.sibling===null;){if(c.return===null||c.return===l)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}a?(i=o,l=n.stateNode,i.nodeType===8?i.parentNode.removeChild(l):i.removeChild(l)):o.removeChild(n.stateNode)}else if(n.tag===4){if(n.child!==null){o=n.stateNode.containerInfo,a=!0,n.child.return=n,n=n.child;continue}}else if(JE(e,n),n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return,n.tag===4&&(r=!1)}n.sibling.return=n.return,n=n.sibling}}function Zy(e,t){switch(t.tag){case 0:case 11:case 14:case 15:case 22:var n=t.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var r=n=n.next;do(r.tag&3)===3&&(e=r.destroy,r.destroy=void 0,e!==void 0&&e()),r=r.next;while(r!==n)}return;case 1:return;case 5:if(n=t.stateNode,n!=null){r=t.memoizedProps;var o=e!==null?e.memoizedProps:r;e=t.type;var a=t.updateQueue;if(t.updateQueue=null,a!==null){for(n[Zh]=r,e==="input"&&r.type==="radio"&&r.name!=null&&dI(n,r),_0(e,o),t=_0(e,r),o=0;o<a.length;o+=2){var i=a[o],l=a[o+1];i==="style"?gI(n,l):i==="dangerouslySetInnerHTML"?hI(n,l):i==="children"?Kd(n,l):$w(n,i,l,t)}switch(e){case"input":S0(n,r);break;case"textarea":pI(n,r);break;case"select":e=n._wrapperState.wasMultiple,n._wrapperState.wasMultiple=!!r.multiple,a=r.value,a!=null?uc(n,!!r.multiple,a,!1):e!==!!r.multiple&&(r.defaultValue!=null?uc(n,!!r.multiple,r.defaultValue,!0):uc(n,!!r.multiple,r.multiple?[]:"",!1))}}}return;case 6:if(t.stateNode===null)throw Error(Oe(162));t.stateNode.nodeValue=t.memoizedProps;return;case 3:n=t.stateNode,n.hydrate&&(n.hydrate=!1,kI(n.containerInfo));return;case 12:return;case 13:t.memoizedState!==null&&(mS=jr(),XE(t.child,!0)),tT(t);return;case 19:tT(t);return;case 17:return;case 23:case 24:XE(t,t.memoizedState!==null);return}throw Error(Oe(163))}function tT(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new l6),t.forEach(function(r){var o=S6.bind(null,e,r);n.has(r)||(n.add(r),r.then(o,o))})}}function d6(e,t){return e!==null&&(e=e.memoizedState,e===null||e.dehydrated!==null)?(t=t.memoizedState,t!==null&&t.dehydrated===null):!1}var p6=Math.ceil,pm=El.ReactCurrentDispatcher,fS=El.ReactCurrentOwner,Tt=0,Zr=null,mr=null,Ur=0,hl=0,J0=Es(0),Or=0,sg=null,Xc=0,Bp=0,Jc=0,hS=0,Q0=null,mS=0,Z0=1/0;function Qc(){Z0=jr()+500}var Qe=null,fm=!1,eb=null,Ua=null,fs=!1,_d=null,dd=90,tb=[],nb=[],wi=null,Rd=0,rb=null,Th=-1,mi=0,kh=0,Pd=null,Ah=!1;function _o(){return Tt&48?jr():Th!==-1?Th:Th=jr()}function os(e){if(e=e.mode,!(e&2))return 1;if(!(e&4))return $c()===99?1:2;if(mi===0&&(mi=Xc),ZD.transition!==0){kh!==0&&(kh=Q0!==null?Q0.pendingLanes:0),e=mi;var t=4186112&~kh;return t&=-t,t===0&&(e=4186112&~e,t=e&-e,t===0&&(t=8192)),t}return e=$c(),Tt&4&&e===98?e=Xh(12,mi):(e=nD(e),e=Xh(e,mi)),e}function as(e,t,n){if(50<Rd)throw Rd=0,rb=null,Error(Oe(185));if(e=lg(e,t),e===null)return null;eg(e,t,n),e===Zr&&(Jc|=t,Or===4&&gc(e,Ur));var r=$c();t===1?Tt&8&&!(Tt&48)?ob(e):(ea(e,n),Tt===0&&(Qc(),ri())):(!(Tt&4)||r!==98&&r!==99||(wi===null?wi=new Set([e]):wi.add(e)),ea(e,n)),Q0=e}function lg(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}function ea(e,t){for(var n=e.callbackNode,r=e.suspendedLanes,o=e.pingedLanes,a=e.expirationTimes,i=e.pendingLanes;0<i;){var l=31-ds(i),c=1<<l,u=a[l];if(u===-1){if(!(c&r)||c&o){u=t,Xl(c);var d=Pn;a[l]=10<=d?u+250:6<=d?u+5e3:-1}}else u<=t&&(e.expiredLanes|=c);i&=~c}if(r=Qd(e,e===Zr?Ur:0),t=Pn,r===0)n!==null&&(n!==Ky&&F0(n),e.callbackNode=null,e.callbackPriority=0);else{if(n!==null){if(e.callbackPriority===t)return;n!==Ky&&F0(n)}t===15?(n=ob.bind(null,e),fi===null?(fi=[n],Eh=tS(ag,t5)):fi.push(n),n=Ky):t===14?n=np(99,ob.bind(null,e)):(n=rD(t),n=np(n,E5.bind(null,e))),e.callbackPriority=t,e.callbackNode=n}}function E5(e){if(Th=-1,kh=mi=0,Tt&48)throw Error(Oe(327));var t=e.callbackNode;if(Ts()&&e.callbackNode!==t)return null;var n=Qd(e,e===Zr?Ur:0);if(n===0)return null;var r=n,o=Tt;Tt|=16;var a=_5();(Zr!==e||Ur!==r)&&(Qc(),vc(e,r));do try{m6();break}catch(l){A5(e,l)}while(1);if(nS(),pm.current=a,Tt=o,mr!==null?r=0:(Zr=null,Ur=0,r=Or),Xc&Jc)vc(e,0);else if(r!==0){if(r===2&&(Tt|=64,e.hydrate&&(e.hydrate=!1,Zw(e.containerInfo)),n=OI(e),n!==0&&(r=pd(e,n))),r===1)throw t=sg,vc(e,0),gc(e,n),ea(e,jr()),t;switch(e.finishedWork=e.current.alternate,e.finishedLanes=n,r){case 0:case 1:throw Error(Oe(345));case 2:js(e);break;case 3:if(gc(e,n),(n&62914560)===n&&(r=mS+500-jr(),10<r)){if(Qd(e,0)!==0)break;if(o=e.suspendedLanes,(o&n)!==n){_o(),e.pingedLanes|=e.suspendedLanes&o;break}e.timeoutHandle=xE(js.bind(null,e),r);break}js(e);break;case 4:if(gc(e,n),(n&4186112)===n)break;for(r=e.eventTimes,o=-1;0<n;){var i=31-ds(n);a=1<<i,i=r[i],i>o&&(o=i),n&=~a}if(n=o,n=jr()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*p6(n/1960))-n,10<n){e.timeoutHandle=xE(js.bind(null,e),n);break}js(e);break;case 5:js(e);break;default:throw Error(Oe(329))}}return ea(e,jr()),e.callbackNode===t?E5.bind(null,e):null}function gc(e,t){for(t&=~hS,t&=~Jc,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-ds(t),r=1<<n;e[n]=-1,t&=~r}}function ob(e){if(Tt&48)throw Error(Oe(327));if(Ts(),e===Zr&&e.expiredLanes&Ur){var t=Ur,n=pd(e,t);Xc&Jc&&(t=Qd(e,t),n=pd(e,t))}else t=Qd(e,0),n=pd(e,t);if(e.tag!==0&&n===2&&(Tt|=64,e.hydrate&&(e.hydrate=!1,Zw(e.containerInfo)),t=OI(e),t!==0&&(n=pd(e,t))),n===1)throw n=sg,vc(e,0),gc(e,t),ea(e,jr()),n;return e.finishedWork=e.current.alternate,e.finishedLanes=t,js(e),ea(e,jr()),null}function f6(){if(wi!==null){var e=wi;wi=null,e.forEach(function(t){t.expiredLanes|=24&t.pendingLanes,ea(t,jr())})}ri()}function T5(e,t){var n=Tt;Tt|=1;try{return e(t)}finally{Tt=n,Tt===0&&(Qc(),ri())}}function k5(e,t){var n=Tt;Tt&=-2,Tt|=8;try{return e(t)}finally{Tt=n,Tt===0&&(Qc(),ri())}}function Nf(e,t){Xn(J0,hl),hl|=t,Xc|=t}function gS(){hl=J0.current,Ln(J0)}function vc(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,qD(n)),mr!==null)for(n=mr.return;n!==null;){var r=n;switch(r.tag){case 1:r=r.type.childContextTypes,r!=null&&em();break;case 3:Oc(),Ln(uo),Ln(Wr),iS();break;case 5:aS(r);break;case 4:Oc();break;case 13:Ln(Yn);break;case 19:Ln(Yn);break;case 10:rS(r);break;case 23:case 24:gS()}n=n.return}Zr=e,mr=hs(e.current,null),Ur=hl=Xc=t,Or=0,sg=null,hS=Jc=Bp=0}function A5(e,t){do{var n=mr;try{if(nS(),kd.current=dm,sm){for(var r=Qn.memoizedState;r!==null;){var o=r.queue;o!==null&&(o.pending=null),r=r.next}sm=!1}if(ip=0,Ir=Fr=Qn=null,Ad=!1,fS.current=null,n===null||n.return===null){Or=1,sg=t,mr=null;break}e:{var a=e,i=n.return,l=n,c=t;if(t=Ur,l.flags|=2048,l.firstEffect=l.lastEffect=null,c!==null&&typeof c=="object"&&typeof c.then=="function"){var u=c;if(!(l.mode&2)){var d=l.alternate;d?(l.updateQueue=d.updateQueue,l.memoizedState=d.memoizedState,l.lanes=d.lanes):(l.updateQueue=null,l.memoizedState=null)}var f=(Yn.current&1)!==0,h=i;do{var m;if(m=h.tag===13){var y=h.memoizedState;if(y!==null)m=y.dehydrated!==null;else{var g=h.memoizedProps;m=g.fallback===void 0?!1:g.unstable_avoidThisFallback!==!0?!0:!f}}if(m){var v=h.updateQueue;if(v===null){var b=new Set;b.add(u),h.updateQueue=b}else v.add(u);if(!(h.mode&2)){if(h.flags|=64,l.flags|=16384,l.flags&=-2981,l.tag===1)if(l.alternate===null)l.tag=17;else{var w=ns(-1,1);w.tag=2,rs(l,w)}l.lanes|=1;break e}c=void 0,l=t;var x=a.pingCache;if(x===null?(x=a.pingCache=new s6,c=new Set,x.set(u,c)):(c=x.get(u),c===void 0&&(c=new Set,x.set(u,c))),!c.has(l)){c.add(l);var E=w6.bind(null,a,u,l);u.then(E,E)}h.flags|=4096,h.lanes=t;break e}h=h.return}while(h!==null);c=Error((cc(l.type)||"A React component")+` suspended while rendering, but no fallback UI was specified.
|
|
41
|
+
|
|
42
|
+
Add a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.`)}Or!==5&&(Or=2),c=pS(c,l),h=i;do{switch(h.tag){case 3:a=c,h.flags|=4096,t&=-t,h.lanes|=t;var A=S5(h,a,t);RE(h,A);break e;case 1:a=c;var k=h.type,_=h.stateNode;if(!(h.flags&64)&&(typeof k.getDerivedStateFromError=="function"||_!==null&&typeof _.componentDidCatch=="function"&&(Ua===null||!Ua.has(_)))){h.flags|=4096,t&=-t,h.lanes|=t;var $=x5(h,a,t);RE(h,$);break e}}h=h.return}while(h!==null)}P5(n)}catch(L){t=L,mr===n&&n!==null&&(mr=n=n.return);continue}break}while(1)}function _5(){var e=pm.current;return pm.current=dm,e===null?dm:e}function pd(e,t){var n=Tt;Tt|=16;var r=_5();Zr===e&&Ur===t||vc(e,t);do try{h6();break}catch(o){A5(e,o)}while(1);if(nS(),Tt=n,pm.current=r,mr!==null)throw Error(Oe(261));return Zr=null,Ur=0,Or}function h6(){for(;mr!==null;)R5(mr)}function m6(){for(;mr!==null&&!XD();)R5(mr)}function R5(e){var t=$5(e.alternate,e,hl);e.memoizedProps=e.pendingProps,t===null?P5(e):mr=t,fS.current=null}function P5(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&2048){if(n=i6(t),n!==null){n.flags&=2047,mr=n;return}e!==null&&(e.firstEffect=e.lastEffect=null,e.flags|=2048)}else{if(n=a6(n,t,hl),n!==null){mr=n;return}if(n=t,n.tag!==24&&n.tag!==23||n.memoizedState===null||hl&1073741824||!(n.mode&4)){for(var r=0,o=n.child;o!==null;)r|=o.lanes|o.childLanes,o=o.sibling;n.childLanes=r}e!==null&&!(e.flags&2048)&&(e.firstEffect===null&&(e.firstEffect=t.firstEffect),t.lastEffect!==null&&(e.lastEffect!==null&&(e.lastEffect.nextEffect=t.firstEffect),e.lastEffect=t.lastEffect),1<t.flags&&(e.lastEffect!==null?e.lastEffect.nextEffect=t:e.firstEffect=t,e.lastEffect=t))}if(t=t.sibling,t!==null){mr=t;return}mr=t=e}while(t!==null);Or===0&&(Or=5)}function js(e){var t=$c();return fl(99,g6.bind(null,e,t)),null}function g6(e,t){do Ts();while(_d!==null);if(Tt&48)throw Error(Oe(327));var n=e.finishedWork;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(Oe(177));e.callbackNode=null;var r=n.lanes|n.childLanes,o=r,a=e.pendingLanes&~o;e.pendingLanes=o,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=o,e.mutableReadLanes&=o,e.entangledLanes&=o,o=e.entanglements;for(var i=e.eventTimes,l=e.expirationTimes;0<a;){var c=31-ds(a),u=1<<c;o[c]=0,i[c]=-1,l[c]=-1,a&=~u}if(wi!==null&&!(r&24)&&wi.has(e)&&wi.delete(e),e===Zr&&(mr=Zr=null,Ur=0),1<n.flags?n.lastEffect!==null?(n.lastEffect.nextEffect=n,r=n.firstEffect):r=n:r=n.firstEffect,r!==null){if(o=Tt,Tt|=32,fS.current=null,Vy=wh,i=mE(),L0(i)){if("selectionStart"in i)l={start:i.selectionStart,end:i.selectionEnd};else e:if(l=(l=i.ownerDocument)&&l.defaultView||window,(u=l.getSelection&&l.getSelection())&&u.rangeCount!==0){l=u.anchorNode,a=u.anchorOffset,c=u.focusNode,u=u.focusOffset;try{l.nodeType,c.nodeType}catch{l=null;break e}var d=0,f=-1,h=-1,m=0,y=0,g=i,v=null;t:for(;;){for(var b;g!==l||a!==0&&g.nodeType!==3||(f=d+a),g!==c||u!==0&&g.nodeType!==3||(h=d+u),g.nodeType===3&&(d+=g.nodeValue.length),(b=g.firstChild)!==null;)v=g,g=b;for(;;){if(g===i)break t;if(v===l&&++m===a&&(f=d),v===c&&++y===u&&(h=d),(b=g.nextSibling)!==null)break;g=v,v=g.parentNode}g=b}l=f===-1||h===-1?null:{start:f,end:h}}else l=null;l=l||{start:0,end:0}}else l=null;Gy={focusedElem:i,selectionRange:l},wh=!1,Pd=null,Ah=!1,Qe=r;do try{v6()}catch(L){if(Qe===null)throw Error(Oe(330));is(Qe,L),Qe=Qe.nextEffect}while(Qe!==null);Pd=null,Qe=r;do try{for(i=e;Qe!==null;){var w=Qe.flags;if(w&16&&Kd(Qe.stateNode,""),w&128){var x=Qe.alternate;if(x!==null){var E=x.ref;E!==null&&(typeof E=="function"?E(null):E.current=null)}}switch(w&1038){case 2:eT(Qe),Qe.flags&=-3;break;case 6:eT(Qe),Qe.flags&=-3,Zy(Qe.alternate,Qe);break;case 1024:Qe.flags&=-1025;break;case 1028:Qe.flags&=-1025,Zy(Qe.alternate,Qe);break;case 4:Zy(Qe.alternate,Qe);break;case 8:l=Qe,C5(i,l);var A=l.alternate;QE(l),A!==null&&QE(A)}Qe=Qe.nextEffect}}catch(L){if(Qe===null)throw Error(Oe(330));is(Qe,L),Qe=Qe.nextEffect}while(Qe!==null);if(E=Gy,x=mE(),w=E.focusedElem,i=E.selectionRange,x!==w&&w&&w.ownerDocument&&jI(w.ownerDocument.documentElement,w)){for(i!==null&&L0(w)&&(x=i.start,E=i.end,E===void 0&&(E=x),"selectionStart"in w?(w.selectionStart=x,w.selectionEnd=Math.min(E,w.value.length)):(E=(x=w.ownerDocument||document)&&x.defaultView||window,E.getSelection&&(E=E.getSelection(),l=w.textContent.length,A=Math.min(i.start,l),i=i.end===void 0?A:Math.min(i.end,l),!E.extend&&A>i&&(l=i,i=A,A=l),l=hE(w,A),a=hE(w,i),l&&a&&(E.rangeCount!==1||E.anchorNode!==l.node||E.anchorOffset!==l.offset||E.focusNode!==a.node||E.focusOffset!==a.offset)&&(x=x.createRange(),x.setStart(l.node,l.offset),E.removeAllRanges(),A>i?(E.addRange(x),E.extend(a.node,a.offset)):(x.setEnd(a.node,a.offset),E.addRange(x)))))),x=[],E=w;E=E.parentNode;)E.nodeType===1&&x.push({element:E,left:E.scrollLeft,top:E.scrollTop});for(typeof w.focus=="function"&&w.focus(),w=0;w<x.length;w++)E=x[w],E.element.scrollLeft=E.left,E.element.scrollTop=E.top}wh=!!Vy,Gy=Vy=null,e.current=n,Qe=r;do try{for(w=e;Qe!==null;){var k=Qe.flags;if(k&36&&u6(w,Qe.alternate,Qe),k&128){x=void 0;var _=Qe.ref;if(_!==null){var $=Qe.stateNode;switch(Qe.tag){case 5:x=$;break;default:x=$}typeof _=="function"?_(x):_.current=x}}Qe=Qe.nextEffect}}catch(L){if(Qe===null)throw Error(Oe(330));is(Qe,L),Qe=Qe.nextEffect}while(Qe!==null);Qe=null,QD(),Tt=o}else e.current=n;if(fs)fs=!1,_d=e,dd=t;else for(Qe=r;Qe!==null;)t=Qe.nextEffect,Qe.nextEffect=null,Qe.flags&8&&(k=Qe,k.sibling=null,k.stateNode=null),Qe=t;if(r=e.pendingLanes,r===0&&(Ua=null),r===1?e===rb?Rd++:(Rd=0,rb=e):Rd=0,n=n.stateNode,il&&typeof il.onCommitFiberRoot=="function")try{il.onCommitFiberRoot(eS,n,void 0,(n.current.flags&64)===64)}catch{}if(ea(e,jr()),fm)throw fm=!1,e=eb,eb=null,e;return Tt&8||ri(),null}function v6(){for(;Qe!==null;){var e=Qe.alternate;Ah||Pd===null||(Qe.flags&8?eE(Qe,Pd)&&(Ah=!0):Qe.tag===13&&d6(e,Qe)&&eE(Qe,Pd)&&(Ah=!0));var t=Qe.flags;t&256&&c6(e,Qe),!(t&512)||fs||(fs=!0,np(97,function(){return Ts(),null})),Qe=Qe.nextEffect}}function Ts(){if(dd!==90){var e=97<dd?97:dd;return dd=90,fl(e,b6)}return!1}function y6(e,t){tb.push(t,e),fs||(fs=!0,np(97,function(){return Ts(),null}))}function I5(e,t){nb.push(t,e),fs||(fs=!0,np(97,function(){return Ts(),null}))}function b6(){if(_d===null)return!1;var e=_d;if(_d=null,Tt&48)throw Error(Oe(331));var t=Tt;Tt|=32;var n=nb;nb=[];for(var r=0;r<n.length;r+=2){var o=n[r],a=n[r+1],i=o.destroy;if(o.destroy=void 0,typeof i=="function")try{i()}catch(c){if(a===null)throw Error(Oe(330));is(a,c)}}for(n=tb,tb=[],r=0;r<n.length;r+=2){o=n[r],a=n[r+1];try{var l=o.create;o.destroy=l()}catch(c){if(a===null)throw Error(Oe(330));is(a,c)}}for(l=e.current.firstEffect;l!==null;)e=l.nextEffect,l.nextEffect=null,l.flags&8&&(l.sibling=null,l.stateNode=null),l=e;return Tt=t,ri(),!0}function nT(e,t,n){t=pS(n,t),t=S5(e,t,1),rs(e,t),t=_o(),e=lg(e,1),e!==null&&(eg(e,1,t),ea(e,t))}function is(e,t){if(e.tag===3)nT(e,e,t);else for(var n=e.return;n!==null;){if(n.tag===3){nT(n,e,t);break}else if(n.tag===1){var r=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Ua===null||!Ua.has(r))){e=pS(t,e);var o=x5(n,e,1);if(rs(n,o),o=_o(),n=lg(n,1),n!==null)eg(n,1,o),ea(n,o);else if(typeof r.componentDidCatch=="function"&&(Ua===null||!Ua.has(r)))try{r.componentDidCatch(t,e)}catch{}break}}n=n.return}}function w6(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=_o(),e.pingedLanes|=e.suspendedLanes&n,Zr===e&&(Ur&n)===n&&(Or===4||Or===3&&(Ur&62914560)===Ur&&500>jr()-mS?vc(e,0):hS|=n),ea(e,t)}function S6(e,t){var n=e.stateNode;n!==null&&n.delete(t),t=0,t===0&&(t=e.mode,t&2?t&4?(mi===0&&(mi=Xc),t=Jl(62914560&~mi),t===0&&(t=4194304)):t=$c()===99?1:2:t=1),n=_o(),e=lg(e,t),e!==null&&(eg(e,t,n),ea(e,n))}var $5;$5=function(e,t,n){var r=t.lanes;if(e!==null)if(e.memoizedProps!==t.pendingProps||uo.current)ya=!0;else if(n&r)ya=!!(e.flags&16384);else{switch(ya=!1,t.tag){case 3:UE(t),Xy();break;case 5:OE(t);break;case 1:po(t.type)&&Ch(t);break;case 4:U0(t,t.stateNode.containerInfo);break;case 10:r=t.memoizedProps.value;var o=t.type._context;Xn(tm,o._currentValue),o._currentValue=r;break;case 13:if(t.memoizedState!==null)return n&t.child.childLanes?WE(e,t,n):(Xn(Yn,Yn.current&1),t=yi(e,t,n),t!==null?t.sibling:null);Xn(Yn,Yn.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&64){if(r)return KE(e,t,n);t.flags|=64}if(o=t.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),Xn(Yn,Yn.current),r)break;return null;case 23:case 24:return t.lanes=0,Jy(e,t,n)}return yi(e,t,n)}else ya=!1;switch(t.lanes=0,t.tag){case 2:if(r=t.type,e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,o=Ic(t,Wr.current),hc(t,n),o=lS(null,t,r,e,o,n),t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0){if(t.tag=1,t.memoizedState=null,t.updateQueue=null,po(r)){var a=!0;Ch(t)}else a=!1;t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,oS(t);var i=r.getDerivedStateFromProps;typeof i=="function"&&om(t,r,i,e),o.updater=ig,t.stateNode=o,o._reactInternals=t,j0(t,r,e,n),t=G0(null,t,r,!0,a,n)}else t.tag=0,co(null,t,o,n),t=t.child;return t;case 16:o=t.elementType;e:{switch(e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,a=o._init,o=a(o._payload),t.type=o,a=t.tag=C6(o),e=ma(o,e),a){case 0:t=V0(null,t,o,e,n);break e;case 1:t=jE(null,t,o,e,n);break e;case 11:t=FE(null,t,o,e,n);break e;case 14:t=zE(null,t,o,ma(o.type,e),r,n);break e}throw Error(Oe(306,o,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:ma(r,o),V0(e,t,r,o,n);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:ma(r,o),jE(e,t,r,o,n);case 3:if(UE(t),r=t.updateQueue,e===null||r===null)throw Error(Oe(282));if(r=t.pendingProps,o=t.memoizedState,o=o!==null?o.element:null,r5(e,t),rp(t,r,null,n),r=t.memoizedState.element,r===o)Xy(),t=yi(e,t,n);else{if(o=t.stateNode,(a=o.hydrate)&&(Ki=fc(t.stateNode.containerInfo.firstChild),vi=t,a=Va=!0),a){if(e=o.mutableSourceEagerHydrationData,e!=null)for(o=0;o<e.length;o+=2)a=e[o],a._workInProgressVersionPrimary=e[o+1],mc.push(a);for(n=s5(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|1024,n=n.sibling}else co(e,t,r,n),Xy();t=t.child}return t;case 5:return OE(t),e===null&&W0(t),r=t.type,o=t.pendingProps,a=e!==null?e.memoizedProps:null,i=o.children,D0(r,o)?i=null:a!==null&&D0(r,a)&&(t.flags|=16),v5(e,t),co(e,t,i,n),t.child;case 6:return e===null&&W0(t),null;case 13:return WE(e,t,n);case 4:return U0(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=am(t,null,r,n):co(e,t,r,n),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:ma(r,o),FE(e,t,r,o,n);case 7:return co(e,t,t.pendingProps,n),t.child;case 8:return co(e,t,t.pendingProps.children,n),t.child;case 12:return co(e,t,t.pendingProps.children,n),t.child;case 10:e:{r=t.type._context,o=t.pendingProps,i=t.memoizedProps,a=o.value;var l=t.type._context;if(Xn(tm,l._currentValue),l._currentValue=a,i!==null)if(l=i.value,a=Vo(l,a)?0:(typeof r._calculateChangedBits=="function"?r._calculateChangedBits(l,a):1073741823)|0,a===0){if(i.children===o.children&&!uo.current){t=yi(e,t,n);break e}}else for(l=t.child,l!==null&&(l.return=t);l!==null;){var c=l.dependencies;if(c!==null){i=l.child;for(var u=c.firstContext;u!==null;){if(u.context===r&&u.observedBits&a){l.tag===1&&(u=ns(-1,n&-n),u.tag=2,rs(l,u)),l.lanes|=n,u=l.alternate,u!==null&&(u.lanes|=n),n5(l.return,n),c.lanes|=n;break}u=u.next}}else i=l.tag===10&&l.type===t.type?null:l.child;if(i!==null)i.return=l;else for(i=l;i!==null;){if(i===t){i=null;break}if(l=i.sibling,l!==null){l.return=i.return,i=l;break}i=i.return}l=i}co(e,t,o.children,n),t=t.child}return t;case 9:return o=t.type,a=t.pendingProps,r=a.children,hc(t,n),o=Zo(o,a.unstable_observedBits),r=r(o),t.flags|=1,co(e,t,r,n),t.child;case 14:return o=t.type,a=ma(o,t.pendingProps),a=ma(o.type,a),zE(e,t,o,a,r,n);case 15:return g5(e,t,t.type,t.pendingProps,r,n);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:ma(r,o),e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),t.tag=1,po(r)?(e=!0,Ch(t)):e=!1,hc(t,n),a5(t,r,o),j0(t,r,o,n),G0(null,t,r,!0,e,n);case 19:return KE(e,t,n);case 23:return Jy(e,t,n);case 24:return Jy(e,t,n)}throw Error(Oe(156,t.tag))};function x6(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.flags=0,this.lastEffect=this.firstEffect=this.nextEffect=null,this.childLanes=this.lanes=0,this.alternate=null}function Go(e,t,n,r){return new x6(e,t,n,r)}function vS(e){return e=e.prototype,!(!e||!e.isReactComponent)}function C6(e){if(typeof e=="function")return vS(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Jm)return 11;if(e===Qm)return 14}return 2}function hs(e,t){var n=e.alternate;return n===null?(n=Go(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.nextEffect=null,n.firstEffect=null,n.lastEffect=null),n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function _h(e,t,n,r,o,a){var i=2;if(r=e,typeof e=="function")vS(e)&&(i=1);else if(typeof e=="string")i=5;else e:switch(e){case Hi:return yc(n.children,o,a,t);case lI:i=8,o|=16;break;case Ow:i=8,o|=1;break;case bd:return e=Go(12,n,t,o|8),e.elementType=bd,e.type=bd,e.lanes=a,e;case wd:return e=Go(13,n,t,o),e.type=wd,e.elementType=wd,e.lanes=a,e;case Gh:return e=Go(19,n,t,o),e.elementType=Gh,e.lanes=a,e;case Fw:return yS(n,o,a,t);case b0:return e=Go(24,n,t,o),e.elementType=b0,e.lanes=a,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Lw:i=10;break e;case Nw:i=9;break e;case Jm:i=11;break e;case Qm:i=14;break e;case Mw:i=16,r=null;break e;case Dw:i=22;break e}throw Error(Oe(130,e==null?e:typeof e,""))}return t=Go(i,n,t,o),t.elementType=e,t.type=r,t.lanes=a,t}function yc(e,t,n,r){return e=Go(7,e,r,t),e.lanes=n,e}function yS(e,t,n,r){return e=Go(23,e,r,t),e.elementType=Fw,e.lanes=n,e}function e1(e,t,n){return e=Go(6,e,null,t),e.lanes=n,e}function t1(e,t,n){return t=Go(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function E6(e,t,n){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.pendingContext=this.context=null,this.hydrate=n,this.callbackNode=null,this.callbackPriority=0,this.eventTimes=By(0),this.expirationTimes=By(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=By(0),this.mutableSourceEagerHydrationData=null}function T6(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Qs,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function hm(e,t,n,r){var o=t.current,a=_o(),i=os(o);e:if(n){n=n._reactInternals;t:{if(Tl(n)!==n||n.tag!==1)throw Error(Oe(170));var l=n;do{switch(l.tag){case 3:l=l.stateNode.context;break t;case 1:if(po(l.type)){l=l.stateNode.__reactInternalMemoizedMergedChildContext;break t}}l=l.return}while(l!==null);throw Error(Oe(171))}if(n.tag===1){var c=n.type;if(po(c)){n=YI(n,c,l);break e}}n=l}else n=ps;return t.context===null?t.context=n:t.pendingContext=n,t=ns(a,i),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),rs(o,t),as(o,i,a),i}function n1(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function rT(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function bS(e,t){rT(e,t),(e=e.alternate)&&rT(e,t)}function k6(){return null}function wS(e,t,n){var r=n!=null&&n.hydrationOptions!=null&&n.hydrationOptions.mutableSources||null;if(n=new E6(e,t,n!=null&&n.hydrate===!0),t=Go(3,null,null,t===2?7:t===1?3:0),n.current=t,t.stateNode=n,oS(t),e[Yc]=n.current,HI(e.nodeType===8?e.parentNode:e),r)for(e=0;e<r.length;e++){t=r[e];var o=t._getVersion;o=o(t._source),n.mutableSourceEagerHydrationData==null?n.mutableSourceEagerHydrationData=[t,o]:n.mutableSourceEagerHydrationData.push(t,o)}this._internalRoot=n}wS.prototype.render=function(e){hm(e,this._internalRoot,null,null)};wS.prototype.unmount=function(){var e=this._internalRoot,t=e.containerInfo;hm(null,e,null,function(){t[Yc]=null})};function Fp(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function A6(e,t){if(t||(t=e?e.nodeType===9?e.documentElement:e.firstChild:null,t=!(!t||t.nodeType!==1||!t.hasAttribute("data-reactroot"))),!t)for(var n;n=e.lastChild;)e.removeChild(n);return new wS(e,0,t?{hydrate:!0}:void 0)}function cg(e,t,n,r,o){var a=n._reactRootContainer;if(a){var i=a._internalRoot;if(typeof o=="function"){var l=o;o=function(){var u=n1(i);l.call(u)}}hm(t,i,e,o)}else{if(a=n._reactRootContainer=A6(n,r),i=a._internalRoot,typeof o=="function"){var c=o;o=function(){var u=n1(i);c.call(u)}}k5(function(){hm(t,i,e,o)})}return n1(i)}CI=function(e){if(e.tag===13){var t=_o();as(e,4,t),bS(e,4)}};Hw=function(e){if(e.tag===13){var t=_o();as(e,67108864,t),bS(e,67108864)}};EI=function(e){if(e.tag===13){var t=_o(),n=os(e);as(e,n,t),bS(e,n)}};TI=function(e,t){return t()};R0=function(e,t,n){switch(t){case"input":if(S0(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var o=og(r);if(!o)throw Error(Oe(90));uI(r),S0(r,o)}}}break;case"textarea":pI(e,n);break;case"select":t=n.value,t!=null&&uc(e,!!n.multiple,t,!1)}};jw=T5;bI=function(e,t,n,r,o){var a=Tt;Tt|=4;try{return fl(98,e.bind(null,t,n,r,o))}finally{Tt=a,Tt===0&&(Qc(),ri())}};Uw=function(){!(Tt&49)&&(f6(),Ts())};wI=function(e,t){var n=Tt;Tt|=2;try{return e(t)}finally{Tt=n,Tt===0&&(Qc(),ri())}};function O5(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Fp(t))throw Error(Oe(200));return T6(e,t,null,n)}var _6={Events:[Mp,rc,og,vI,yI,Ts,{current:!1}]},ju={findFiberByHostInstance:el,bundleType:0,version:"17.0.2",rendererPackageName:"react-dom"},R6={bundleType:ju.bundleType,version:ju.version,rendererPackageName:ju.rendererPackageName,rendererConfig:ju.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:El.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=xI(e),e===null?null:e.stateNode},findFiberByHostInstance:ju.findFiberByHostInstance||k6,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Mf=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Mf.isDisabled&&Mf.supportsFiber)try{eS=Mf.inject(R6),il=Mf}catch{}}aa.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=_6;aa.createPortal=O5;aa.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(Oe(188)):Error(Oe(268,Object.keys(e)));return e=xI(t),e=e===null?null:e.stateNode,e};aa.flushSync=function(e,t){var n=Tt;if(n&48)return e(t);Tt|=1;try{if(e)return fl(99,e.bind(null,t))}finally{Tt=n,ri()}};aa.hydrate=function(e,t,n){if(!Fp(t))throw Error(Oe(200));return cg(null,e,t,!0,n)};aa.render=function(e,t,n){if(!Fp(t))throw Error(Oe(200));return cg(null,e,t,!1,n)};aa.unmountComponentAtNode=function(e){if(!Fp(e))throw Error(Oe(40));return e._reactRootContainer?(k5(function(){cg(null,null,e,!1,function(){e._reactRootContainer=null,e[Yc]=null})}),!0):!1};aa.unstable_batchedUpdates=T5;aa.unstable_createPortal=function(e,t){return O5(e,t,2<arguments.length&&arguments[2]!==void 0?arguments[2]:null)};aa.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!Fp(n))throw Error(Oe(200));if(e==null||e._reactInternals===void 0)throw Error(Oe(38));return cg(e,t,n,!1,r)};aa.version="17.0.2";(function(e){function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(n){console.error(n)}}t(),e.exports=aa})(LM);const fd=Ym(Gd);/**
|
|
43
|
+
* @remix-run/router v1.3.2
|
|
44
|
+
*
|
|
45
|
+
* Copyright (c) Remix Software Inc.
|
|
46
|
+
*
|
|
47
|
+
* This source code is licensed under the MIT license found in the
|
|
48
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
49
|
+
*
|
|
50
|
+
* @license MIT
|
|
51
|
+
*/function sp(){return sp=Object.assign?Object.assign.bind():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},sp.apply(this,arguments)}var Yi;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(Yi||(Yi={}));const oT="popstate";function P6(e){e===void 0&&(e={});function t(r,o){let{pathname:a,search:i,hash:l}=r.location;return ab("",{pathname:a,search:i,hash:l},o.state&&o.state.usr||null,o.state&&o.state.key||"default")}function n(r,o){return typeof o=="string"?o:mm(o)}return $6(t,n,null,e)}function lr(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function I6(){return Math.random().toString(36).substr(2,8)}function aT(e,t){return{usr:e.state,key:e.key,idx:t}}function ab(e,t,n,r){return n===void 0&&(n=null),sp({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Zc(t):t,{state:n,key:t&&t.key||r||I6()})}function mm(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Zc(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function $6(e,t,n,r){r===void 0&&(r={});let{window:o=document.defaultView,v5Compat:a=!1}=r,i=o.history,l=Yi.Pop,c=null,u=d();u==null&&(u=0,i.replaceState(sp({},i.state,{idx:u}),""));function d(){return(i.state||{idx:null}).idx}function f(){l=Yi.Pop;let v=d(),b=v==null?null:v-u;u=v,c&&c({action:l,location:g.location,delta:b})}function h(v,b){l=Yi.Push;let w=ab(g.location,v,b);n&&n(w,v),u=d()+1;let x=aT(w,u),E=g.createHref(w);try{i.pushState(x,"",E)}catch{o.location.assign(E)}a&&c&&c({action:l,location:g.location,delta:1})}function m(v,b){l=Yi.Replace;let w=ab(g.location,v,b);n&&n(w,v),u=d();let x=aT(w,u),E=g.createHref(w);i.replaceState(x,"",E),a&&c&&c({action:l,location:g.location,delta:0})}function y(v){let b=o.location.origin!=="null"?o.location.origin:o.location.href,w=typeof v=="string"?v:mm(v);return lr(b,"No window.location.(origin|href) available to create URL for href: "+w),new URL(w,b)}let g={get action(){return l},get location(){return e(o,i)},listen(v){if(c)throw new Error("A history only accepts one active listener");return o.addEventListener(oT,f),c=v,()=>{o.removeEventListener(oT,f),c=null}},createHref(v){return t(o,v)},createURL:y,encodeLocation(v){let b=y(v);return{pathname:b.pathname,search:b.search,hash:b.hash}},push:h,replace:m,go(v){return i.go(v)}};return g}var iT;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(iT||(iT={}));function O6(e,t,n){n===void 0&&(n="/");let r=typeof t=="string"?Zc(t):t,o=D5(r.pathname||"/",n);if(o==null)return null;let a=L5(e);L6(a);let i=null;for(let l=0;i==null&&l<a.length;++l)i=W6(a[l],V6(o));return i}function L5(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r="");let o=(a,i,l)=>{let c={relativePath:l===void 0?a.path||"":l,caseSensitive:a.caseSensitive===!0,childrenIndex:i,route:a};c.relativePath.startsWith("/")&&(lr(c.relativePath.startsWith(r),'Absolute route path "'+c.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),c.relativePath=c.relativePath.slice(r.length));let u=ss([r,c.relativePath]),d=n.concat(c);a.children&&a.children.length>0&&(lr(a.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),L5(a.children,t,d,u)),!(a.path==null&&!a.index)&&t.push({path:u,score:j6(u,a.index),routesMeta:d})};return e.forEach((a,i)=>{var l;if(a.path===""||!((l=a.path)!=null&&l.includes("?")))o(a,i);else for(let c of N5(a.path))o(a,i,c)}),t}function N5(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,o=n.endsWith("?"),a=n.replace(/\?$/,"");if(r.length===0)return o?[a,""]:[a];let i=N5(r.join("/")),l=[];return l.push(...i.map(c=>c===""?a:[a,c].join("/"))),o&&l.push(...i),l.map(c=>e.startsWith("/")&&c===""?"/":c)}function L6(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:U6(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const N6=/^:\w+$/,M6=3,D6=2,B6=1,F6=10,z6=-2,sT=e=>e==="*";function j6(e,t){let n=e.split("/"),r=n.length;return n.some(sT)&&(r+=z6),t&&(r+=D6),n.filter(o=>!sT(o)).reduce((o,a)=>o+(N6.test(a)?M6:a===""?B6:F6),r)}function U6(e,t){return e.length===t.length&&e.slice(0,-1).every((r,o)=>r===t[o])?e[e.length-1]-t[t.length-1]:0}function W6(e,t){let{routesMeta:n}=e,r={},o="/",a=[];for(let i=0;i<n.length;++i){let l=n[i],c=i===n.length-1,u=o==="/"?t:t.slice(o.length)||"/",d=M5({path:l.relativePath,caseSensitive:l.caseSensitive,end:c},u);if(!d)return null;Object.assign(r,d.params);let f=l.route;a.push({params:r,pathname:ss([o,d.pathname]),pathnameBase:Y6(ss([o,d.pathnameBase])),route:f}),d.pathnameBase!=="/"&&(o=ss([o,d.pathnameBase]))}return a}function M5(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=H6(e.path,e.caseSensitive,e.end),o=t.match(n);if(!o)return null;let a=o[0],i=a.replace(/(.)\/+$/,"$1"),l=o.slice(1);return{params:r.reduce((u,d,f)=>{if(d==="*"){let h=l[f]||"";i=a.slice(0,a.length-h.length).replace(/(.)\/+$/,"$1")}return u[d]=G6(l[f]||"",d),u},{}),pathname:a,pathnameBase:i,pattern:e}}function H6(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),SS(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],o="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^$?{}|()[\]]/g,"\\$&").replace(/\/:(\w+)/g,(i,l)=>(r.push(l),"/([^\\/]+)"));return e.endsWith("*")?(r.push("*"),o+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?o+="\\/*$":e!==""&&e!=="/"&&(o+="(?:(?=\\/|$))"),[new RegExp(o,t?void 0:"i"),r]}function V6(e){try{return decodeURI(e)}catch(t){return SS(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function G6(e,t){try{return decodeURIComponent(e)}catch(n){return SS(!1,'The value for the URL param "'+t+'" will not be decoded because'+(' the string "'+e+'" is a malformed URL segment. This is probably')+(" due to a bad percent encoding ("+n+").")),e}}function D5(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function SS(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function q6(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:o=""}=typeof e=="string"?Zc(e):e;return{pathname:n?n.startsWith("/")?n:K6(n,t):t,search:X6(r),hash:J6(o)}}function K6(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(o=>{o===".."?n.length>1&&n.pop():o!=="."&&n.push(o)}),n.length>1?n.join("/"):"/"}function r1(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function B5(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function F5(e,t,n,r){r===void 0&&(r=!1);let o;typeof e=="string"?o=Zc(e):(o=sp({},e),lr(!o.pathname||!o.pathname.includes("?"),r1("?","pathname","search",o)),lr(!o.pathname||!o.pathname.includes("#"),r1("#","pathname","hash",o)),lr(!o.search||!o.search.includes("#"),r1("#","search","hash",o)));let a=e===""||o.pathname==="",i=a?"/":o.pathname,l;if(r||i==null)l=n;else{let f=t.length-1;if(i.startsWith("..")){let h=i.split("/");for(;h[0]==="..";)h.shift(),f-=1;o.pathname=h.join("/")}l=f>=0?t[f]:"/"}let c=q6(o,l),u=i&&i!=="/"&&i.endsWith("/"),d=(a||i===".")&&n.endsWith("/");return!c.pathname.endsWith("/")&&(u||d)&&(c.pathname+="/"),c}const ss=e=>e.join("/").replace(/\/\/+/g,"/"),Y6=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),X6=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,J6=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function Q6(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Z6=["post","put","patch","delete"];[...Z6];/**
|
|
52
|
+
* React Router v6.8.1
|
|
53
|
+
*
|
|
54
|
+
* Copyright (c) Remix Software Inc.
|
|
55
|
+
*
|
|
56
|
+
* This source code is licensed under the MIT license found in the
|
|
57
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
58
|
+
*
|
|
59
|
+
* @license MIT
|
|
60
|
+
*/function ib(){return ib=Object.assign?Object.assign.bind():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},ib.apply(this,arguments)}function e9(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}const t9=typeof Object.is=="function"?Object.is:e9,{useState:n9,useEffect:r9,useLayoutEffect:o9,useDebugValue:a9}=ul;function i9(e,t,n){const r=t(),[{inst:o},a]=n9({inst:{value:r,getSnapshot:t}});return o9(()=>{o.value=r,o.getSnapshot=t,o1(o)&&a({inst:o})},[e,r,t]),r9(()=>(o1(o)&&a({inst:o}),e(()=>{o1(o)&&a({inst:o})})),[e]),a9(r),r}function o1(e){const t=e.getSnapshot,n=e.value;try{const r=t();return!t9(n,r)}catch{return!0}}function s9(e,t,n){return t()}const l9=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",c9=!l9,u9=c9?s9:i9;"useSyncExternalStore"in ul&&(e=>e.useSyncExternalStore)(ul);const z5=p.createContext(null),ug=p.createContext(null),zp=p.createContext(null),dg=p.createContext(null),Al=p.createContext({outlet:null,matches:[]}),j5=p.createContext(null);function d9(e,t){let{relative:n}=t===void 0?{}:t;eu()||lr(!1);let{basename:r,navigator:o}=p.useContext(zp),{hash:a,pathname:i,search:l}=xS(e,{relative:n}),c=i;return r!=="/"&&(c=i==="/"?r:ss([r,i])),o.createHref({pathname:c,search:l,hash:a})}function eu(){return p.useContext(dg)!=null}function ia(){return eu()||lr(!1),p.useContext(dg).location}function lt(){eu()||lr(!1);let{basename:e,navigator:t}=p.useContext(zp),{matches:n}=p.useContext(Al),{pathname:r}=ia(),o=JSON.stringify(B5(n).map(l=>l.pathnameBase)),a=p.useRef(!1);return p.useEffect(()=>{a.current=!0}),p.useCallback(function(l,c){if(c===void 0&&(c={}),!a.current)return;if(typeof l=="number"){t.go(l);return}let u=F5(l,JSON.parse(o),r,c.relative==="path");e!=="/"&&(u.pathname=u.pathname==="/"?e:ss([e,u.pathname])),(c.replace?t.replace:t.push)(u,c.state,c)},[e,t,o,r])}function p9(){let{matches:e}=p.useContext(Al),t=e[e.length-1];return t?t.params:{}}function xS(e,t){let{relative:n}=t===void 0?{}:t,{matches:r}=p.useContext(Al),{pathname:o}=ia(),a=JSON.stringify(B5(r).map(i=>i.pathnameBase));return p.useMemo(()=>F5(e,JSON.parse(a),o,n==="path"),[e,a,o,n])}function f9(e,t){eu()||lr(!1);let{navigator:n}=p.useContext(zp),r=p.useContext(ug),{matches:o}=p.useContext(Al),a=o[o.length-1],i=a?a.params:{};a&&a.pathname;let l=a?a.pathnameBase:"/";a&&a.route;let c=ia(),u;if(t){var d;let g=typeof t=="string"?Zc(t):t;l==="/"||(d=g.pathname)!=null&&d.startsWith(l)||lr(!1),u=g}else u=c;let f=u.pathname||"/",h=l==="/"?f:f.slice(l.length)||"/",m=O6(e,{pathname:h}),y=v9(m&&m.map(g=>Object.assign({},g,{params:Object.assign({},i,g.params),pathname:ss([l,n.encodeLocation?n.encodeLocation(g.pathname).pathname:g.pathname]),pathnameBase:g.pathnameBase==="/"?l:ss([l,n.encodeLocation?n.encodeLocation(g.pathnameBase).pathname:g.pathnameBase])})),o,r||void 0);return t&&y?p.createElement(dg.Provider,{value:{location:ib({pathname:"/",search:"",hash:"",state:null,key:"default"},u),navigationType:Yi.Pop}},y):y}function h9(){let e=S9(),t=Q6(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,o={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"},a=null;return p.createElement(p.Fragment,null,p.createElement("h2",null,"Unexpected Application Error!"),p.createElement("h3",{style:{fontStyle:"italic"}},t),n?p.createElement("pre",{style:o},n):null,a)}class m9 extends p.Component{constructor(t){super(t),this.state={location:t.location,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location?{error:t.error,location:t.location}:{error:t.error||n.error,location:n.location}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error?p.createElement(Al.Provider,{value:this.props.routeContext},p.createElement(j5.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function g9(e){let{routeContext:t,match:n,children:r}=e,o=p.useContext(z5);return o&&o.static&&o.staticContext&&n.route.errorElement&&(o.staticContext._deepestRenderedBoundaryId=n.route.id),p.createElement(Al.Provider,{value:t},r)}function v9(e,t,n){if(t===void 0&&(t=[]),e==null)if(n!=null&&n.errors)e=n.matches;else return null;let r=e,o=n==null?void 0:n.errors;if(o!=null){let a=r.findIndex(i=>i.route.id&&(o==null?void 0:o[i.route.id]));a>=0||lr(!1),r=r.slice(0,Math.min(r.length,a+1))}return r.reduceRight((a,i,l)=>{let c=i.route.id?o==null?void 0:o[i.route.id]:null,u=n?i.route.errorElement||p.createElement(h9,null):null,d=t.concat(r.slice(0,l+1)),f=()=>p.createElement(g9,{match:i,routeContext:{outlet:a,matches:d}},c?u:i.route.element!==void 0?i.route.element:a);return n&&(i.route.errorElement||l===0)?p.createElement(m9,{location:n.location,component:u,error:c,children:f(),routeContext:{outlet:null,matches:d}}):f()},null)}var lT;(function(e){e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator"})(lT||(lT={}));var gm;(function(e){e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator"})(gm||(gm={}));function y9(e){let t=p.useContext(ug);return t||lr(!1),t}function b9(e){let t=p.useContext(Al);return t||lr(!1),t}function w9(e){let t=b9(),n=t.matches[t.matches.length-1];return n.route.id||lr(!1),n.route.id}function S9(){var e;let t=p.useContext(j5),n=y9(gm.UseRouteError),r=w9(gm.UseRouteError);return t||((e=n.errors)==null?void 0:e[r])}function _l(e){let{to:t,replace:n,state:r,relative:o}=e;eu()||lr(!1);let a=p.useContext(ug),i=lt();return p.useEffect(()=>{a&&a.navigation.state!=="idle"||i(t,{replace:n,state:r,relative:o})}),null}function Rh(e){lr(!1)}function x9(e){let{basename:t="/",children:n=null,location:r,navigationType:o=Yi.Pop,navigator:a,static:i=!1}=e;eu()&&lr(!1);let l=t.replace(/^\/*/,"/"),c=p.useMemo(()=>({basename:l,navigator:a,static:i}),[l,a,i]);typeof r=="string"&&(r=Zc(r));let{pathname:u="/",search:d="",hash:f="",state:h=null,key:m="default"}=r,y=p.useMemo(()=>{let g=D5(u,l);return g==null?null:{pathname:g,search:d,hash:f,state:h,key:m}},[l,u,d,f,h,m]);return y==null?null:p.createElement(zp.Provider,{value:c},p.createElement(dg.Provider,{children:n,value:{location:y,navigationType:o}}))}function C9(e){let{children:t,location:n}=e,r=p.useContext(z5),o=r&&!t?r.router.routes:sb(t);return f9(o,n)}var cT;(function(e){e[e.pending=0]="pending",e[e.success=1]="success",e[e.error=2]="error"})(cT||(cT={}));new Promise(()=>{});function sb(e,t){t===void 0&&(t=[]);let n=[];return p.Children.forEach(e,(r,o)=>{if(!p.isValidElement(r))return;if(r.type===p.Fragment){n.push.apply(n,sb(r.props.children,t));return}r.type!==Rh&&lr(!1),!r.props.index||!r.props.children||lr(!1);let a=[...t,o],i={id:r.props.id||a.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,hasErrorBoundary:r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle};r.props.children&&(i.children=sb(r.props.children,a)),n.push(i)}),n}/**
|
|
61
|
+
* React Router DOM v6.8.1
|
|
62
|
+
*
|
|
63
|
+
* Copyright (c) Remix Software Inc.
|
|
64
|
+
*
|
|
65
|
+
* This source code is licensed under the MIT license found in the
|
|
66
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
67
|
+
*
|
|
68
|
+
* @license MIT
|
|
69
|
+
*/function vm(){return vm=Object.assign?Object.assign.bind():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},vm.apply(this,arguments)}function U5(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,a;for(a=0;a<r.length;a++)o=r[a],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function E9(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function T9(e,t){return e.button===0&&(!t||t==="_self")&&!E9(e)}function lb(e){return e===void 0&&(e=""),new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(o=>[n,o]):[[n,r]])},[]))}function k9(e,t){let n=lb(e);if(t)for(let r of t.keys())n.has(r)||t.getAll(r).forEach(o=>{n.append(r,o)});return n}const A9=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset"],_9=["aria-current","caseSensitive","className","end","style","to","children"];function R9(e){let{basename:t,children:n,window:r}=e,o=p.useRef();o.current==null&&(o.current=P6({window:r,v5Compat:!0}));let a=o.current,[i,l]=p.useState({action:a.action,location:a.location});return p.useLayoutEffect(()=>a.listen(l),[a]),p.createElement(x9,{basename:t,children:n,location:i.location,navigationType:i.action,navigator:a})}const P9=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",ln=p.forwardRef(function(t,n){let{onClick:r,relative:o,reloadDocument:a,replace:i,state:l,target:c,to:u,preventScrollReset:d}=t,f=U5(t,A9),h,m=!1;if(P9&&typeof u=="string"&&/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i.test(u)){h=u;let b=new URL(window.location.href),w=u.startsWith("//")?new URL(b.protocol+u):new URL(u);w.origin===b.origin?u=w.pathname+w.search+w.hash:m=!0}let y=d9(u,{relative:o}),g=I9(u,{replace:i,state:l,target:c,preventScrollReset:d,relative:o});function v(b){r&&r(b),b.defaultPrevented||g(b)}return p.createElement("a",vm({},f,{href:h||y,onClick:m||a?r:v,ref:n,target:c}))}),EPe=p.forwardRef(function(t,n){let{"aria-current":r="page",caseSensitive:o=!1,className:a="",end:i=!1,style:l,to:c,children:u}=t,d=U5(t,_9),f=xS(c,{relative:d.relative}),h=ia(),m=p.useContext(ug),{navigator:y}=p.useContext(zp),g=y.encodeLocation?y.encodeLocation(f).pathname:f.pathname,v=h.pathname,b=m&&m.navigation&&m.navigation.location?m.navigation.location.pathname:null;o||(v=v.toLowerCase(),b=b?b.toLowerCase():null,g=g.toLowerCase());let w=v===g||!i&&v.startsWith(g)&&v.charAt(g.length)==="/",x=b!=null&&(b===g||!i&&b.startsWith(g)&&b.charAt(g.length)==="/"),E=w?r:void 0,A;typeof a=="function"?A=a({isActive:w,isPending:x}):A=[a,w?"active":null,x?"pending":null].filter(Boolean).join(" ");let k=typeof l=="function"?l({isActive:w,isPending:x}):l;return p.createElement(ln,vm({},d,{"aria-current":E,className:A,ref:n,style:k,to:c}),typeof u=="function"?u({isActive:w,isPending:x}):u)});var uT;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmitImpl="useSubmitImpl",e.UseFetcher="useFetcher"})(uT||(uT={}));var dT;(function(e){e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(dT||(dT={}));function I9(e,t){let{target:n,replace:r,state:o,preventScrollReset:a,relative:i}=t===void 0?{}:t,l=lt(),c=ia(),u=xS(e,{relative:i});return p.useCallback(d=>{if(T9(d,n)){d.preventDefault();let f=r!==void 0?r:mm(c)===mm(u);l(e,{replace:f,state:o,preventScrollReset:a,relative:i})}},[c,l,u,r,o,n,e,a,i])}function tu(e){let t=p.useRef(lb(e)),n=p.useRef(!1),r=ia(),o=p.useMemo(()=>k9(r.search,n.current?null:t.current),[r.search]),a=lt(),i=p.useCallback((l,c)=>{const u=lb(typeof l=="function"?l(o):l);n.current=!0,a("?"+u,c)},[a,o]);return[o,i]}const $9={black:"#000",white:"#fff"},lp=$9,O9={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Bl=O9,L9={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Fl=L9,N9={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},zl=N9,M9={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},jl=M9,D9={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},Ul=D9,B9={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},Uu=B9,F9={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},z9=F9;function bc(){return bc=Object.assign?Object.assign.bind():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},bc.apply(this,arguments)}function Ks(e){return e!==null&&typeof e=="object"&&e.constructor===Object}function W5(e){if(!Ks(e))return e;const t={};return Object.keys(e).forEach(n=>{t[n]=W5(e[n])}),t}function Ro(e,t,n={clone:!0}){const r=n.clone?bc({},e):e;return Ks(e)&&Ks(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(Ks(t[o])&&o in e&&Ks(e[o])?r[o]=Ro(e[o],t[o],n):n.clone?r[o]=Ks(t[o])?W5(t[o]):t[o]:r[o]=t[o])}),r}var ut={},j9={get exports(){return ut},set exports(e){ut=e}},U9="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",W9=U9,H9=W9;function H5(){}function V5(){}V5.resetWarningCache=H5;var V9=function(){function e(r,o,a,i,l,c){if(c!==H9){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:V5,resetWarningCache:H5};return n.PropTypes=n,n};j9.exports=V9();function ms(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n<arguments.length;n+=1)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified MUI error #"+e+"; visit "+t+" for the full message."}var cb={},G9={get exports(){return cb},set exports(e){cb=e}},gn={};/**
|
|
70
|
+
* @license React
|
|
71
|
+
* react-is.production.min.js
|
|
72
|
+
*
|
|
73
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
74
|
+
*
|
|
75
|
+
* This source code is licensed under the MIT license found in the
|
|
76
|
+
* LICENSE file in the root directory of this source tree.
|
|
77
|
+
*/var CS=Symbol.for("react.element"),ES=Symbol.for("react.portal"),pg=Symbol.for("react.fragment"),fg=Symbol.for("react.strict_mode"),hg=Symbol.for("react.profiler"),mg=Symbol.for("react.provider"),gg=Symbol.for("react.context"),q9=Symbol.for("react.server_context"),vg=Symbol.for("react.forward_ref"),yg=Symbol.for("react.suspense"),bg=Symbol.for("react.suspense_list"),wg=Symbol.for("react.memo"),Sg=Symbol.for("react.lazy"),K9=Symbol.for("react.offscreen"),G5;G5=Symbol.for("react.module.reference");function sa(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case CS:switch(e=e.type,e){case pg:case hg:case fg:case yg:case bg:return e;default:switch(e=e&&e.$$typeof,e){case q9:case gg:case vg:case Sg:case wg:case mg:return e;default:return t}}case ES:return t}}}gn.ContextConsumer=gg;gn.ContextProvider=mg;gn.Element=CS;gn.ForwardRef=vg;gn.Fragment=pg;gn.Lazy=Sg;gn.Memo=wg;gn.Portal=ES;gn.Profiler=hg;gn.StrictMode=fg;gn.Suspense=yg;gn.SuspenseList=bg;gn.isAsyncMode=function(){return!1};gn.isConcurrentMode=function(){return!1};gn.isContextConsumer=function(e){return sa(e)===gg};gn.isContextProvider=function(e){return sa(e)===mg};gn.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===CS};gn.isForwardRef=function(e){return sa(e)===vg};gn.isFragment=function(e){return sa(e)===pg};gn.isLazy=function(e){return sa(e)===Sg};gn.isMemo=function(e){return sa(e)===wg};gn.isPortal=function(e){return sa(e)===ES};gn.isProfiler=function(e){return sa(e)===hg};gn.isStrictMode=function(e){return sa(e)===fg};gn.isSuspense=function(e){return sa(e)===yg};gn.isSuspenseList=function(e){return sa(e)===bg};gn.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===pg||e===hg||e===fg||e===yg||e===bg||e===K9||typeof e=="object"&&e!==null&&(e.$$typeof===Sg||e.$$typeof===wg||e.$$typeof===mg||e.$$typeof===gg||e.$$typeof===vg||e.$$typeof===G5||e.getModuleId!==void 0)};gn.typeOf=sa;(function(e){e.exports=gn})(G9);const Y9=Ym(cb);function ie(e){if(typeof e!="string")throw new Error(ms(7));return e.charAt(0).toUpperCase()+e.slice(1)}function ym(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function ml(e,t=166){let n;function r(...o){const a=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(a,t)}return r.clear=()=>{clearTimeout(n)},r}function X9(e,t){return()=>null}function Id(e,t){return p.isValidElement(e)&&t.indexOf(e.type.muiName)!==-1}function Fn(e){return e&&e.ownerDocument||document}function ta(e){return Fn(e).defaultView||window}function J9(e,t){return()=>null}function cp(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Q9=typeof window<"u"?p.useLayoutEffect:p.useEffect,$o=Q9;let pT=0;function Z9(e){const[t,n]=p.useState(e),r=e||t;return p.useEffect(()=>{t==null&&(pT+=1,n(`mui-${pT}`))},[t]),r}const fT=ul["useId"];function nu(e){if(fT!==void 0){const t=fT();return e??t}return Z9(e)}function eB(e,t,n,r,o){return null}function Sa({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=p.useRef(e!==void 0),[a,i]=p.useState(t),l=o?e:a,c=p.useCallback(u=>{o||i(u)},[]);return[l,c]}function gr(e){const t=p.useRef(e);return $o(()=>{t.current=e}),p.useCallback((...n)=>(0,t.current)(...n),[])}function Sn(...e){return p.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{cp(n,t)})},e)}let xg=!0,ub=!1,hT;const tB={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function nB(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&tB[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function rB(e){e.metaKey||e.altKey||e.ctrlKey||(xg=!0)}function a1(){xg=!1}function oB(){this.visibilityState==="hidden"&&ub&&(xg=!0)}function aB(e){e.addEventListener("keydown",rB,!0),e.addEventListener("mousedown",a1,!0),e.addEventListener("pointerdown",a1,!0),e.addEventListener("touchstart",a1,!0),e.addEventListener("visibilitychange",oB,!0)}function iB(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return xg||nB(t)}function jp(){const e=p.useCallback(o=>{o!=null&&aB(o.ownerDocument)},[]),t=p.useRef(!1);function n(){return t.current?(ub=!0,window.clearTimeout(hT),hT=window.setTimeout(()=>{ub=!1},100),t.current=!1,!0):!1}function r(o){return iB(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function q5(e){const t=e.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}let Wl;function K5(){if(Wl)return Wl;const e=document.createElement("div"),t=document.createElement("div");return t.style.width="10px",t.style.height="1px",e.appendChild(t),e.dir="rtl",e.style.fontSize="14px",e.style.width="4px",e.style.height="1px",e.style.position="absolute",e.style.top="-1000px",e.style.overflow="scroll",document.body.appendChild(e),Wl="reverse",e.scrollLeft>0?Wl="default":(e.scrollLeft=1,e.scrollLeft===0&&(Wl="negative")),document.body.removeChild(e),Wl}function mT(e,t){const n=e.scrollLeft;if(t!=="rtl")return n;switch(K5()){case"negative":return e.scrollWidth-e.clientWidth+n;case"reverse":return e.scrollWidth-e.clientWidth-n;default:return n}}const sB=e=>{const t=p.useRef({});return p.useEffect(()=>{t.current=e}),t.current},lB=sB,cB={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:-1,overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"},uB=cB;function TS(e,t){const n=bc({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=bc({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},a=t[r];n[r]={},!a||!Object.keys(a)?n[r]=o:!o||!Object.keys(o)?n[r]=a:(n[r]=bc({},a),Object.keys(o).forEach(i=>{n[r][i]=TS(o[i],a[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function He(e,t,n){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((a,i)=>(i&&(a.push(t(i)),n&&n[i]&&a.push(n[i])),a),[]).join(" ")}),r}const gT=e=>e,dB=()=>{let e=gT;return{configure(t){e=t},generate(t){return e(t)},reset(){e=gT}}},pB=dB(),kS=pB,fB={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",required:"required",selected:"selected"};function je(e,t,n="Mui"){const r=fB[t];return r?`${n}-${r}`:`${kS.generate(e)}-${t}`}function Ue(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=je(e,o,n)}),r}function I(){return I=Object.assign?Object.assign.bind():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 $e(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,a;for(a=0;a<r.length;a++)o=r[a],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function bm(){return bm=Object.assign?Object.assign.bind():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},bm.apply(this,arguments)}function Y5(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var hB=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,mB=Y5(function(e){return hB.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91});function gB(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function vB(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var yB=function(){function e(n){var r=this;this._insertTag=function(o){var a;r.tags.length===0?r.insertionPoint?a=r.insertionPoint.nextSibling:r.prepend?a=r.container.firstChild:a=r.before:a=r.tags[r.tags.length-1].nextSibling,r.container.insertBefore(o,a),r.tags.push(o)},this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(r){r.forEach(this._insertTag)},t.insert=function(r){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(vB(this));var o=this.tags[this.tags.length-1];if(this.isSpeedy){var a=gB(o);try{a.insertRule(r,a.cssRules.length)}catch{}}else o.appendChild(document.createTextNode(r));this.ctr++},t.flush=function(){this.tags.forEach(function(r){return r.parentNode&&r.parentNode.removeChild(r)}),this.tags=[],this.ctr=0},e}(),Br="-ms-",wm="-moz-",rn="-webkit-",X5="comm",AS="rule",_S="decl",bB="@import",J5="@keyframes",wB=Math.abs,Cg=String.fromCharCode,SB=Object.assign;function xB(e,t){return $r(e,0)^45?(((t<<2^$r(e,0))<<2^$r(e,1))<<2^$r(e,2))<<2^$r(e,3):0}function Q5(e){return e.trim()}function CB(e,t){return(e=t.exec(e))?e[0]:e}function an(e,t,n){return e.replace(t,n)}function db(e,t){return e.indexOf(t)}function $r(e,t){return e.charCodeAt(t)|0}function up(e,t,n){return e.slice(t,n)}function Oa(e){return e.length}function RS(e){return e.length}function Df(e,t){return t.push(e),e}function EB(e,t){return e.map(t).join("")}var Eg=1,Lc=1,Z5=0,vo=0,or=0,ru="";function Tg(e,t,n,r,o,a,i){return{value:e,root:t,parent:n,type:r,props:o,children:a,line:Eg,column:Lc,length:i,return:""}}function Wu(e,t){return SB(Tg("",null,null,"",null,null,0),e,{length:-e.length},t)}function TB(){return or}function kB(){return or=vo>0?$r(ru,--vo):0,Lc--,or===10&&(Lc=1,Eg--),or}function Po(){return or=vo<Z5?$r(ru,vo++):0,Lc++,or===10&&(Lc=1,Eg++),or}function Ga(){return $r(ru,vo)}function Ph(){return vo}function Up(e,t){return up(ru,e,t)}function dp(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function e$(e){return Eg=Lc=1,Z5=Oa(ru=e),vo=0,[]}function t$(e){return ru="",e}function Ih(e){return Q5(Up(vo-1,pb(e===91?e+2:e===40?e+1:e)))}function AB(e){for(;(or=Ga())&&or<33;)Po();return dp(e)>2||dp(or)>3?"":" "}function _B(e,t){for(;--t&&Po()&&!(or<48||or>102||or>57&&or<65||or>70&&or<97););return Up(e,Ph()+(t<6&&Ga()==32&&Po()==32))}function pb(e){for(;Po();)switch(or){case e:return vo;case 34:case 39:e!==34&&e!==39&&pb(or);break;case 40:e===41&&pb(e);break;case 92:Po();break}return vo}function RB(e,t){for(;Po()&&e+or!==47+10;)if(e+or===42+42&&Ga()===47)break;return"/*"+Up(t,vo-1)+"*"+Cg(e===47?e:Po())}function PB(e){for(;!dp(Ga());)Po();return Up(e,vo)}function IB(e){return t$($h("",null,null,null,[""],e=e$(e),0,[0],e))}function $h(e,t,n,r,o,a,i,l,c){for(var u=0,d=0,f=i,h=0,m=0,y=0,g=1,v=1,b=1,w=0,x="",E=o,A=a,k=r,_=x;v;)switch(y=w,w=Po()){case 40:if(y!=108&&$r(_,f-1)==58){db(_+=an(Ih(w),"&","&\f"),"&\f")!=-1&&(b=-1);break}case 34:case 39:case 91:_+=Ih(w);break;case 9:case 10:case 13:case 32:_+=AB(y);break;case 92:_+=_B(Ph()-1,7);continue;case 47:switch(Ga()){case 42:case 47:Df($B(RB(Po(),Ph()),t,n),c);break;default:_+="/"}break;case 123*g:l[u++]=Oa(_)*b;case 125*g:case 59:case 0:switch(w){case 0:case 125:v=0;case 59+d:m>0&&Oa(_)-f&&Df(m>32?yT(_+";",r,n,f-1):yT(an(_," ","")+";",r,n,f-2),c);break;case 59:_+=";";default:if(Df(k=vT(_,t,n,u,d,o,l,x,E=[],A=[],f),a),w===123)if(d===0)$h(_,t,k,k,E,a,f,l,A);else switch(h===99&&$r(_,3)===110?100:h){case 100:case 109:case 115:$h(e,k,k,r&&Df(vT(e,k,k,0,0,o,l,x,o,E=[],f),A),o,A,f,l,r?E:A);break;default:$h(_,k,k,k,[""],A,0,l,A)}}u=d=m=0,g=b=1,x=_="",f=i;break;case 58:f=1+Oa(_),m=y;default:if(g<1){if(w==123)--g;else if(w==125&&g++==0&&kB()==125)continue}switch(_+=Cg(w),w*g){case 38:b=d>0?1:(_+="\f",-1);break;case 44:l[u++]=(Oa(_)-1)*b,b=1;break;case 64:Ga()===45&&(_+=Ih(Po())),h=Ga(),d=f=Oa(x=_+=PB(Ph())),w++;break;case 45:y===45&&Oa(_)==2&&(g=0)}}return a}function vT(e,t,n,r,o,a,i,l,c,u,d){for(var f=o-1,h=o===0?a:[""],m=RS(h),y=0,g=0,v=0;y<r;++y)for(var b=0,w=up(e,f+1,f=wB(g=i[y])),x=e;b<m;++b)(x=Q5(g>0?h[b]+" "+w:an(w,/&\f/g,h[b])))&&(c[v++]=x);return Tg(e,t,n,o===0?AS:l,c,u,d)}function $B(e,t,n){return Tg(e,t,n,X5,Cg(TB()),up(e,2,-2),0)}function yT(e,t,n,r){return Tg(e,t,n,_S,up(e,0,r),up(e,r+1,-1),r)}function wc(e,t){for(var n="",r=RS(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function OB(e,t,n,r){switch(e.type){case bB:case _S:return e.return=e.return||e.value;case X5:return"";case J5:return e.return=e.value+"{"+wc(e.children,r)+"}";case AS:e.value=e.props.join(",")}return Oa(n=wc(e.children,r))?e.return=e.value+"{"+n+"}":""}function LB(e){var t=RS(e);return function(n,r,o,a){for(var i="",l=0;l<t;l++)i+=e[l](n,r,o,a)||"";return i}}function NB(e){return function(t){t.root||(t=t.return)&&e(t)}}var MB=function(t,n,r){for(var o=0,a=0;o=a,a=Ga(),o===38&&a===12&&(n[r]=1),!dp(a);)Po();return Up(t,vo)},DB=function(t,n){var r=-1,o=44;do switch(dp(o)){case 0:o===38&&Ga()===12&&(n[r]=1),t[r]+=MB(vo-1,n,r);break;case 2:t[r]+=Ih(o);break;case 4:if(o===44){t[++r]=Ga()===58?"&\f":"",n[r]=t[r].length;break}default:t[r]+=Cg(o)}while(o=Po());return t},BB=function(t,n){return t$(DB(e$(t),n))},bT=new WeakMap,FB=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,r=t.parent,o=t.column===r.column&&t.line===r.line;r.type!=="rule";)if(r=r.parent,!r)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!bT.get(r))&&!o){bT.set(t,!0);for(var a=[],i=BB(n,a),l=r.props,c=0,u=0;c<i.length;c++)for(var d=0;d<l.length;d++,u++)t.props[u]=a[c]?i[c].replace(/&\f/g,l[d]):l[d]+" "+i[c]}}},zB=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}};function n$(e,t){switch(xB(e,t)){case 5103:return rn+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return rn+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return rn+e+wm+e+Br+e+e;case 6828:case 4268:return rn+e+Br+e+e;case 6165:return rn+e+Br+"flex-"+e+e;case 5187:return rn+e+an(e,/(\w+).+(:[^]+)/,rn+"box-$1$2"+Br+"flex-$1$2")+e;case 5443:return rn+e+Br+"flex-item-"+an(e,/flex-|-self/,"")+e;case 4675:return rn+e+Br+"flex-line-pack"+an(e,/align-content|flex-|-self/,"")+e;case 5548:return rn+e+Br+an(e,"shrink","negative")+e;case 5292:return rn+e+Br+an(e,"basis","preferred-size")+e;case 6060:return rn+"box-"+an(e,"-grow","")+rn+e+Br+an(e,"grow","positive")+e;case 4554:return rn+an(e,/([^-])(transform)/g,"$1"+rn+"$2")+e;case 6187:return an(an(an(e,/(zoom-|grab)/,rn+"$1"),/(image-set)/,rn+"$1"),e,"")+e;case 5495:case 3959:return an(e,/(image-set\([^]*)/,rn+"$1$`$1");case 4968:return an(an(e,/(.+:)(flex-)?(.*)/,rn+"box-pack:$3"+Br+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+rn+e+e;case 4095:case 3583:case 4068:case 2532:return an(e,/(.+)-inline(.+)/,rn+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Oa(e)-1-t>6)switch($r(e,t+1)){case 109:if($r(e,t+4)!==45)break;case 102:return an(e,/(.+:)(.+)-([^]+)/,"$1"+rn+"$2-$3$1"+wm+($r(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~db(e,"stretch")?n$(an(e,"stretch","fill-available"),t)+e:e}break;case 4949:if($r(e,t+1)!==115)break;case 6444:switch($r(e,Oa(e)-3-(~db(e,"!important")&&10))){case 107:return an(e,":",":"+rn)+e;case 101:return an(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+rn+($r(e,14)===45?"inline-":"")+"box$3$1"+rn+"$2$3$1"+Br+"$2box$3")+e}break;case 5936:switch($r(e,t+11)){case 114:return rn+e+Br+an(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return rn+e+Br+an(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return rn+e+Br+an(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return rn+e+Br+e+e}return e}var jB=function(t,n,r,o){if(t.length>-1&&!t.return)switch(t.type){case _S:t.return=n$(t.value,t.length);break;case J5:return wc([Wu(t,{value:an(t.value,"@","@"+rn)})],o);case AS:if(t.length)return EB(t.props,function(a){switch(CB(a,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return wc([Wu(t,{props:[an(a,/:(read-\w+)/,":"+wm+"$1")]})],o);case"::placeholder":return wc([Wu(t,{props:[an(a,/:(plac\w+)/,":"+rn+"input-$1")]}),Wu(t,{props:[an(a,/:(plac\w+)/,":"+wm+"$1")]}),Wu(t,{props:[an(a,/:(plac\w+)/,Br+"input-$1")]})],o)}return""})}},UB=[jB],r$=function(t){var n=t.key;if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(g){var v=g.getAttribute("data-emotion");v.indexOf(" ")!==-1&&(document.head.appendChild(g),g.setAttribute("data-s",""))})}var o=t.stylisPlugins||UB,a={},i,l=[];i=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(g){for(var v=g.getAttribute("data-emotion").split(" "),b=1;b<v.length;b++)a[v[b]]=!0;l.push(g)});var c,u=[FB,zB];{var d,f=[OB,NB(function(g){d.insert(g)})],h=LB(u.concat(o,f)),m=function(v){return wc(IB(v),h)};c=function(v,b,w,x){d=w,m(v?v+"{"+b.styles+"}":b.styles),x&&(y.inserted[b.name]=!0)}}var y={key:n,sheet:new yB({key:n,container:i,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:a,registered:{},insert:c};return y.sheet.hydrate(l),y},fb={},WB={get exports(){return fb},set exports(e){fb=e}},vn={};/** @license React v16.13.1
|
|
78
|
+
* react-is.production.min.js
|
|
79
|
+
*
|
|
80
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
81
|
+
*
|
|
82
|
+
* This source code is licensed under the MIT license found in the
|
|
83
|
+
* LICENSE file in the root directory of this source tree.
|
|
84
|
+
*/var Ar=typeof Symbol=="function"&&Symbol.for,PS=Ar?Symbol.for("react.element"):60103,IS=Ar?Symbol.for("react.portal"):60106,kg=Ar?Symbol.for("react.fragment"):60107,Ag=Ar?Symbol.for("react.strict_mode"):60108,_g=Ar?Symbol.for("react.profiler"):60114,Rg=Ar?Symbol.for("react.provider"):60109,Pg=Ar?Symbol.for("react.context"):60110,$S=Ar?Symbol.for("react.async_mode"):60111,Ig=Ar?Symbol.for("react.concurrent_mode"):60111,$g=Ar?Symbol.for("react.forward_ref"):60112,Og=Ar?Symbol.for("react.suspense"):60113,HB=Ar?Symbol.for("react.suspense_list"):60120,Lg=Ar?Symbol.for("react.memo"):60115,Ng=Ar?Symbol.for("react.lazy"):60116,VB=Ar?Symbol.for("react.block"):60121,GB=Ar?Symbol.for("react.fundamental"):60117,qB=Ar?Symbol.for("react.responder"):60118,KB=Ar?Symbol.for("react.scope"):60119;function Do(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case PS:switch(e=e.type,e){case $S:case Ig:case kg:case _g:case Ag:case Og:return e;default:switch(e=e&&e.$$typeof,e){case Pg:case $g:case Ng:case Lg:case Rg:return e;default:return t}}case IS:return t}}}function o$(e){return Do(e)===Ig}vn.AsyncMode=$S;vn.ConcurrentMode=Ig;vn.ContextConsumer=Pg;vn.ContextProvider=Rg;vn.Element=PS;vn.ForwardRef=$g;vn.Fragment=kg;vn.Lazy=Ng;vn.Memo=Lg;vn.Portal=IS;vn.Profiler=_g;vn.StrictMode=Ag;vn.Suspense=Og;vn.isAsyncMode=function(e){return o$(e)||Do(e)===$S};vn.isConcurrentMode=o$;vn.isContextConsumer=function(e){return Do(e)===Pg};vn.isContextProvider=function(e){return Do(e)===Rg};vn.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===PS};vn.isForwardRef=function(e){return Do(e)===$g};vn.isFragment=function(e){return Do(e)===kg};vn.isLazy=function(e){return Do(e)===Ng};vn.isMemo=function(e){return Do(e)===Lg};vn.isPortal=function(e){return Do(e)===IS};vn.isProfiler=function(e){return Do(e)===_g};vn.isStrictMode=function(e){return Do(e)===Ag};vn.isSuspense=function(e){return Do(e)===Og};vn.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===kg||e===Ig||e===_g||e===Ag||e===Og||e===HB||typeof e=="object"&&e!==null&&(e.$$typeof===Ng||e.$$typeof===Lg||e.$$typeof===Rg||e.$$typeof===Pg||e.$$typeof===$g||e.$$typeof===GB||e.$$typeof===qB||e.$$typeof===KB||e.$$typeof===VB)};vn.typeOf=Do;(function(e){e.exports=vn})(WB);var a$=fb,YB={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},XB={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},i$={};i$[a$.ForwardRef]=YB;i$[a$.Memo]=XB;var JB=!0;function s$(e,t,n){var r="";return n.split(" ").forEach(function(o){e[o]!==void 0?t.push(e[o]+";"):r+=o+" "}),r}var l$=function(t,n,r){var o=t.key+"-"+n.name;(r===!1||JB===!1)&&t.registered[o]===void 0&&(t.registered[o]=n.styles)},OS=function(t,n,r){l$(t,n,r);var o=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var a=n;do t.insert(n===a?"."+o:"",a,t.sheet,!0),a=a.next;while(a!==void 0)}};function QB(e){for(var t=0,n,r=0,o=e.length;o>=4;++r,o-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var ZB={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},eF=/[A-Z]|^ms/g,tF=/_EMO_([^_]+?)_([^]*?)_EMO_/g,c$=function(t){return t.charCodeAt(1)===45},wT=function(t){return t!=null&&typeof t!="boolean"},i1=Y5(function(e){return c$(e)?e:e.replace(eF,"-$&").toLowerCase()}),ST=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(tF,function(r,o,a){return La={name:o,styles:a,next:La},o})}return ZB[t]!==1&&!c$(t)&&typeof n=="number"&&n!==0?n+"px":n};function pp(e,t,n){if(n==null)return"";if(n.__emotion_styles!==void 0)return n;switch(typeof n){case"boolean":return"";case"object":{if(n.anim===1)return La={name:n.name,styles:n.styles,next:La},n.name;if(n.styles!==void 0){var r=n.next;if(r!==void 0)for(;r!==void 0;)La={name:r.name,styles:r.styles,next:La},r=r.next;var o=n.styles+";";return o}return nF(e,t,n)}case"function":{if(e!==void 0){var a=La,i=n(e);return La=a,pp(e,t,i)}break}}if(t==null)return n;var l=t[n];return l!==void 0?l:n}function nF(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=pp(e,t,n[o])+";";else for(var a in n){var i=n[a];if(typeof i!="object")t!=null&&t[i]!==void 0?r+=a+"{"+t[i]+"}":wT(i)&&(r+=i1(a)+":"+ST(a,i)+";");else if(Array.isArray(i)&&typeof i[0]=="string"&&(t==null||t[i[0]]===void 0))for(var l=0;l<i.length;l++)wT(i[l])&&(r+=i1(a)+":"+ST(a,i[l])+";");else{var c=pp(e,t,i);switch(a){case"animation":case"animationName":{r+=i1(a)+":"+c+";";break}default:r+=a+"{"+c+"}"}}}return r}var xT=/label:\s*([^\s;\n{]+)\s*(;|$)/g,La,Mg=function(t,n,r){if(t.length===1&&typeof t[0]=="object"&&t[0]!==null&&t[0].styles!==void 0)return t[0];var o=!0,a="";La=void 0;var i=t[0];i==null||i.raw===void 0?(o=!1,a+=pp(r,n,i)):a+=i[0];for(var l=1;l<t.length;l++)a+=pp(r,n,t[l]),o&&(a+=i[l]);xT.lastIndex=0;for(var c="",u;(u=xT.exec(a))!==null;)c+="-"+u[1];var d=QB(a)+c;return{name:d,styles:a,next:La}},rF=function(t){return t()},u$=ul["useInsertionEffect"]?ul["useInsertionEffect"]:!1,oF=u$||rF,CT=u$||p.useLayoutEffect,LS=p.createContext(typeof HTMLElement<"u"?r$({key:"css"}):null),aF=LS.Provider,iF=function(){return p.useContext(LS)},d$=function(t){return p.forwardRef(function(n,r){var o=p.useContext(LS);return t(n,o,r)})},NS=p.createContext({}),sF=d$(function(e,t){var n=e.styles,r=Mg([n],void 0,p.useContext(NS)),o=p.useRef();return CT(function(){var a=t.key+"-global",i=new t.sheet.constructor({key:a,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),l=!1,c=document.querySelector('style[data-emotion="'+a+" "+r.name+'"]');return t.sheet.tags.length&&(i.before=t.sheet.tags[0]),c!==null&&(l=!0,c.setAttribute("data-emotion",a),i.hydrate([c])),o.current=[i,l],function(){i.flush()}},[t]),CT(function(){var a=o.current,i=a[0],l=a[1];if(l){a[1]=!1;return}if(r.next!==void 0&&OS(t,r.next,!0),i.tags.length){var c=i.tags[i.tags.length-1].nextElementSibling;i.before=c,i.flush()}t.insert("",r,i,!1)},[t,r.name]),null});function ou(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return Mg(t)}var ks=function(){var t=ou.apply(void 0,arguments),n="animation-"+t.name;return{name:n,styles:"@keyframes "+n+"{"+t.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}},lF=mB,cF=function(t){return t!=="theme"},ET=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?lF:cF},TT=function(t,n,r){var o;if(n){var a=n.shouldForwardProp;o=t.__emotion_forwardProp&&a?function(i){return t.__emotion_forwardProp(i)&&a(i)}:a}return typeof o!="function"&&r&&(o=t.__emotion_forwardProp),o},uF=function(t){var n=t.cache,r=t.serialized,o=t.isStringTag;return l$(n,r,o),oF(function(){return OS(n,r,o)}),null},dF=function e(t,n){var r=t.__emotion_real===t,o=r&&t.__emotion_base||t,a,i;n!==void 0&&(a=n.label,i=n.target);var l=TT(t,n,r),c=l||ET(o),u=!c("as");return function(){var d=arguments,f=r&&t.__emotion_styles!==void 0?t.__emotion_styles.slice(0):[];if(a!==void 0&&f.push("label:"+a+";"),d[0]==null||d[0].raw===void 0)f.push.apply(f,d);else{f.push(d[0][0]);for(var h=d.length,m=1;m<h;m++)f.push(d[m],d[0][m])}var y=d$(function(g,v,b){var w=u&&g.as||o,x="",E=[],A=g;if(g.theme==null){A={};for(var k in g)A[k]=g[k];A.theme=p.useContext(NS)}typeof g.className=="string"?x=s$(v.registered,E,g.className):g.className!=null&&(x=g.className+" ");var _=Mg(f.concat(E),v.registered,A);x+=v.key+"-"+_.name,i!==void 0&&(x+=" "+i);var $=u&&l===void 0?ET(w):c,L={};for(var O in g)u&&O==="as"||$(O)&&(L[O]=g[O]);return L.className=x,L.ref=b,p.createElement(p.Fragment,null,p.createElement(uF,{cache:v,serialized:_,isStringTag:typeof w=="string"}),p.createElement(w,L))});return y.displayName=a!==void 0?a:"Styled("+(typeof o=="string"?o:o.displayName||o.name||"Component")+")",y.defaultProps=t.defaultProps,y.__emotion_real=y,y.__emotion_base=o,y.__emotion_styles=f,y.__emotion_forwardProp=l,Object.defineProperty(y,"toString",{value:function(){return"."+i}}),y.withComponent=function(g,v){return e(g,bm({},n,v,{shouldForwardProp:TT(y,v,!0)})).apply(void 0,f)},y}},pF=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],hb=dF.bind();pF.forEach(function(e){hb[e]=hb(e)});const fF=hb;function hF(e){return e==null||Object.keys(e).length===0}function mF(e){const{styles:t,defaultTheme:n={}}=e;return s(sF,{styles:typeof t=="function"?o=>t(hF(o)?n:o):t})}/**
|
|
85
|
+
* @mui/styled-engine v5.11.9
|
|
86
|
+
*
|
|
87
|
+
* @license MIT
|
|
88
|
+
* This source code is licensed under the MIT license found in the
|
|
89
|
+
* LICENSE file in the root directory of this source tree.
|
|
90
|
+
*/function p$(e,t){return fF(e,t)}const gF=(e,t)=>{Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))};function ir(){return ir=Object.assign?Object.assign.bind():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},ir.apply(this,arguments)}function $d(e,t){return t?Ro(e,t,{clone:!1}):e}const MS={xs:0,sm:600,md:900,lg:1200,xl:1536},kT={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${MS[e]}px)`};function na(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const a=r.breakpoints||kT;return t.reduce((i,l,c)=>(i[a.up(a.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const a=r.breakpoints||kT;return Object.keys(t).reduce((i,l)=>{if(Object.keys(a.values||MS).indexOf(l)!==-1){const c=a.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function f$(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const a=e.up(o);return r[a]={},r},{}))||{}}function h$(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function TPe(e,...t){const n=f$(e),r=[n,...t].reduce((o,a)=>Ro(o,a),{});return h$(Object.keys(n),r)}function vF(e,t){if(typeof e!="object")return{};const n={},r=Object.keys(t);return Array.isArray(e)?r.forEach((o,a)=>{a<e.length&&(n[o]=!0)}):r.forEach(o=>{e[o]!=null&&(n[o]=!0)}),n}function Dg({values:e,breakpoints:t,base:n}){const r=n||vF(e,t),o=Object.keys(r);if(o.length===0)return e;let a;return o.reduce((i,l,c)=>(Array.isArray(e)?(i[l]=e[c]!=null?e[c]:e[a],a=c):typeof e=="object"?(i[l]=e[l]!=null?e[l]:e[a],a=l):i[l]=e,i),{})}function Nc(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,a)=>o&&o[a]?o[a]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Sm(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=Nc(e,n)||r,t&&(o=t(o,r,e)),o}function un(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,a=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,u=Nc(c,r)||{};return na(i,l,f=>{let h=Sm(u,o,f);return f===h&&typeof f=="string"&&(h=Sm(u,o,`${t}${f==="default"?"":ie(f)}`,f)),n===!1?h:{[n]:h}})};return a.propTypes={},a.filterProps=[t],a}function Bg(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(a=>{r[a]=o}),r),{}),n=r=>Object.keys(r).reduce((o,a)=>t[a]?$d(o,t[a](r)):o,{});return n.propTypes={},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function yF(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const bF={m:"margin",p:"padding"},wF={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},AT={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},SF=yF(e=>{if(e.length>2)if(AT[e])e=AT[e];else return[e];const[t,n]=e.split(""),r=bF[t],o=wF[n]||"";return Array.isArray(o)?o.map(a=>r+a):[r+o]}),DS=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],BS=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"];[...DS,...BS];function Wp(e,t,n,r){var o;const a=(o=Nc(e,t,!1))!=null?o:n;return typeof a=="number"?i=>typeof i=="string"?i:a*i:Array.isArray(a)?i=>typeof i=="string"?i:a[i]:typeof a=="function"?a:()=>{}}function m$(e){return Wp(e,"spacing",8)}function Hp(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function xF(e,t){return n=>e.reduce((r,o)=>(r[o]=Hp(t,n),r),{})}function CF(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=SF(n),a=xF(o,r),i=e[n];return na(e,i,a)}function g$(e,t){const n=m$(e.theme);return Object.keys(e).map(r=>CF(e,t,r,n)).reduce($d,{})}function Gn(e){return g$(e,DS)}Gn.propTypes={};Gn.filterProps=DS;function qn(e){return g$(e,BS)}qn.propTypes={};qn.filterProps=BS;function Na(e){return typeof e!="number"?e:`${e}px solid`}const EF=un({prop:"border",themeKey:"borders",transform:Na}),TF=un({prop:"borderTop",themeKey:"borders",transform:Na}),kF=un({prop:"borderRight",themeKey:"borders",transform:Na}),AF=un({prop:"borderBottom",themeKey:"borders",transform:Na}),_F=un({prop:"borderLeft",themeKey:"borders",transform:Na}),RF=un({prop:"borderColor",themeKey:"palette"}),PF=un({prop:"borderTopColor",themeKey:"palette"}),IF=un({prop:"borderRightColor",themeKey:"palette"}),$F=un({prop:"borderBottomColor",themeKey:"palette"}),OF=un({prop:"borderLeftColor",themeKey:"palette"}),Fg=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=Wp(e.theme,"shape.borderRadius",4),n=r=>({borderRadius:Hp(t,r)});return na(e,e.borderRadius,n)}return null};Fg.propTypes={};Fg.filterProps=["borderRadius"];Bg(EF,TF,kF,AF,_F,RF,PF,IF,$F,OF,Fg);const zg=e=>{if(e.gap!==void 0&&e.gap!==null){const t=Wp(e.theme,"spacing",8),n=r=>({gap:Hp(t,r)});return na(e,e.gap,n)}return null};zg.propTypes={};zg.filterProps=["gap"];const jg=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=Wp(e.theme,"spacing",8),n=r=>({columnGap:Hp(t,r)});return na(e,e.columnGap,n)}return null};jg.propTypes={};jg.filterProps=["columnGap"];const Ug=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=Wp(e.theme,"spacing",8),n=r=>({rowGap:Hp(t,r)});return na(e,e.rowGap,n)}return null};Ug.propTypes={};Ug.filterProps=["rowGap"];const LF=un({prop:"gridColumn"}),NF=un({prop:"gridRow"}),MF=un({prop:"gridAutoFlow"}),DF=un({prop:"gridAutoColumns"}),BF=un({prop:"gridAutoRows"}),FF=un({prop:"gridTemplateColumns"}),zF=un({prop:"gridTemplateRows"}),jF=un({prop:"gridTemplateAreas"}),UF=un({prop:"gridArea"});Bg(zg,jg,Ug,LF,NF,MF,DF,BF,FF,zF,jF,UF);function Sc(e,t){return t==="grey"?t:e}const WF=un({prop:"color",themeKey:"palette",transform:Sc}),HF=un({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Sc}),VF=un({prop:"backgroundColor",themeKey:"palette",transform:Sc});Bg(WF,HF,VF);function Eo(e){return e<=1&&e!==0?`${e*100}%`:e}const GF=un({prop:"width",transform:Eo}),FS=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o,a;return{maxWidth:((r=e.theme)==null||(o=r.breakpoints)==null||(a=o.values)==null?void 0:a[n])||MS[n]||Eo(n)}};return na(e,e.maxWidth,t)}return null};FS.filterProps=["maxWidth"];const qF=un({prop:"minWidth",transform:Eo}),KF=un({prop:"height",transform:Eo}),YF=un({prop:"maxHeight",transform:Eo}),XF=un({prop:"minHeight",transform:Eo});un({prop:"size",cssProperty:"width",transform:Eo});un({prop:"size",cssProperty:"height",transform:Eo});const JF=un({prop:"boxSizing"});Bg(GF,FS,qF,KF,YF,XF,JF);const QF={border:{themeKey:"borders",transform:Na},borderTop:{themeKey:"borders",transform:Na},borderRight:{themeKey:"borders",transform:Na},borderBottom:{themeKey:"borders",transform:Na},borderLeft:{themeKey:"borders",transform:Na},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Fg},color:{themeKey:"palette",transform:Sc},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Sc},backgroundColor:{themeKey:"palette",transform:Sc},p:{style:qn},pt:{style:qn},pr:{style:qn},pb:{style:qn},pl:{style:qn},px:{style:qn},py:{style:qn},padding:{style:qn},paddingTop:{style:qn},paddingRight:{style:qn},paddingBottom:{style:qn},paddingLeft:{style:qn},paddingX:{style:qn},paddingY:{style:qn},paddingInline:{style:qn},paddingInlineStart:{style:qn},paddingInlineEnd:{style:qn},paddingBlock:{style:qn},paddingBlockStart:{style:qn},paddingBlockEnd:{style:qn},m:{style:Gn},mt:{style:Gn},mr:{style:Gn},mb:{style:Gn},ml:{style:Gn},mx:{style:Gn},my:{style:Gn},margin:{style:Gn},marginTop:{style:Gn},marginRight:{style:Gn},marginBottom:{style:Gn},marginLeft:{style:Gn},marginX:{style:Gn},marginY:{style:Gn},marginInline:{style:Gn},marginInlineStart:{style:Gn},marginInlineEnd:{style:Gn},marginBlock:{style:Gn},marginBlockStart:{style:Gn},marginBlockEnd:{style:Gn},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:zg},rowGap:{style:Ug},columnGap:{style:jg},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Eo},maxWidth:{style:FS},minWidth:{transform:Eo},height:{transform:Eo},maxHeight:{transform:Eo},minHeight:{transform:Eo},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},Wg=QF;function ZF(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function e7(e,t){return typeof e=="function"?e(t):e}function t7(){function e(n,r,o,a){const i={[n]:r,theme:o},l=a[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:u,transform:d,style:f}=l;if(r==null)return null;const h=Nc(o,u)||{};return f?f(i):na(i,r,y=>{let g=Sm(h,d,y);return y===g&&typeof y=="string"&&(g=Sm(h,d,`${n}${y==="default"?"":ie(y)}`,y)),c===!1?g:{[c]:g}})}function t(n){var r;const{sx:o,theme:a={}}=n||{};if(!o)return null;const i=(r=a.unstable_sxConfig)!=null?r:Wg;function l(c){let u=c;if(typeof c=="function")u=c(a);else if(typeof c!="object")return c;if(!u)return null;const d=f$(a.breakpoints),f=Object.keys(d);let h=d;return Object.keys(u).forEach(m=>{const y=e7(u[m],a);if(y!=null)if(typeof y=="object")if(i[m])h=$d(h,e(m,y,a,i));else{const g=na({theme:a},y,v=>({[m]:v}));ZF(g,y)?h[m]=t({sx:y,theme:a}):h=$d(h,g)}else h=$d(h,e(m,y,a,i))}),h$(f,h)}return Array.isArray(o)?o.map(l):l(o)}return t}const v$=t7();v$.filterProps=["sx"];const Hg=v$;function Si(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,a;for(a=0;a<r.length;a++)o=r[a],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}const n7=["sx"],r7=e=>{var t,n;const r={systemProps:{},otherProps:{}},o=(t=e==null||(n=e.theme)==null?void 0:n.unstable_sxConfig)!=null?t:Wg;return Object.keys(e).forEach(a=>{o[a]?r.systemProps[a]=e[a]:r.otherProps[a]=e[a]}),r};function zS(e){const{sx:t}=e,n=Si(e,n7),{systemProps:r,otherProps:o}=r7(n);let a;return Array.isArray(t)?a=[r,...t]:typeof t=="function"?a=(...i)=>{const l=t(...i);return Ks(l)?ir({},r,l):r}:a=ir({},r,t),ir({},o,{sx:a})}function y$(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=y$(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function ve(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=y$(e))&&(r&&(r+=" "),r+=t);return r}const o7=["values","unit","step"],a7=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>ir({},n,{[r.key]:r.val}),{})};function i7(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Si(e,o7),a=a7(t),i=Object.keys(a);function l(h){return`@media (min-width:${typeof t[h]=="number"?t[h]:h}${n})`}function c(h){return`@media (max-width:${(typeof t[h]=="number"?t[h]:h)-r/100}${n})`}function u(h,m){const y=i.indexOf(m);return`@media (min-width:${typeof t[h]=="number"?t[h]:h}${n}) and (max-width:${(y!==-1&&typeof t[i[y]]=="number"?t[i[y]]:m)-r/100}${n})`}function d(h){return i.indexOf(h)+1<i.length?u(h,i[i.indexOf(h)+1]):l(h)}function f(h){const m=i.indexOf(h);return m===0?l(i[1]):m===i.length-1?c(i[m]):u(h,i[i.indexOf(h)+1]).replace("@media","@media not all and")}return ir({keys:i,values:a,up:l,down:c,between:u,only:d,not:f,unit:n},o)}const s7={borderRadius:4},l7=s7;function c7(e=8){if(e.mui)return e;const t=m$({spacing:e}),n=(...r)=>(r.length===0?[1]:r).map(a=>{const i=t(a);return typeof i=="number"?`${i}px`:i}).join(" ");return n.mui=!0,n}const u7=["breakpoints","palette","spacing","shape"];function Vg(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:a={}}=e,i=Si(e,u7),l=i7(n),c=c7(o);let u=Ro({breakpoints:l,direction:"ltr",components:{},palette:ir({mode:"light"},r),spacing:c,shape:ir({},l7,a)},i);return u=t.reduce((d,f)=>Ro(d,f),u),u.unstable_sxConfig=ir({},Wg,i==null?void 0:i.unstable_sxConfig),u.unstable_sx=function(f){return Hg({sx:f,theme:this})},u}function mb(){return mb=Object.assign?Object.assign.bind():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},mb.apply(this,arguments)}const d7=p.createContext(null),b$=d7;function w$(){return p.useContext(b$)}const p7=typeof Symbol=="function"&&Symbol.for,f7=p7?Symbol.for("mui.nested"):"__THEME_NESTED__";function h7(e,t){return typeof t=="function"?t(e):mb({},e,t)}function m7(e){const{children:t,theme:n}=e,r=w$(),o=p.useMemo(()=>{const a=r===null?n:h7(r,n);return a!=null&&(a[f7]=r!==null),a},[n,r]);return s(b$.Provider,{value:o,children:t})}function g7(e){return Object.keys(e).length===0}function jS(e=null){const t=w$();return!t||g7(t)?e:t}const v7=Vg();function au(e=v7){return jS(e)}const y7=["className","component"];function b7(e={}){const{defaultTheme:t,defaultClassName:n="MuiBox-root",generateClassName:r}=e,o=p$("div",{shouldForwardProp:i=>i!=="theme"&&i!=="sx"&&i!=="as"})(Hg);return p.forwardRef(function(l,c){const u=au(t),d=zS(l),{className:f,component:h="div"}=d,m=Si(d,y7);return s(o,ir({as:h,ref:c,className:ve(f,r?r(n):n),theme:u},m))})}const w7=["variant"];function _T(e){return e.length===0}function S$(e){const{variant:t}=e,n=Si(e,w7);let r=t||"";return Object.keys(n).sort().forEach(o=>{o==="color"?r+=_T(r)?e[o]:ie(e[o]):r+=`${_T(r)?o:ie(o)}${ie(e[o].toString())}`}),r}const S7=["name","slot","skipVariantsResolver","skipSx","overridesResolver"],x7=["theme"],C7=["theme"];function Hu(e){return Object.keys(e).length===0}function E7(e){return typeof e=="string"&&e.charCodeAt(0)>96}const T7=(e,t)=>t.components&&t.components[e]&&t.components[e].styleOverrides?t.components[e].styleOverrides:null,k7=(e,t)=>{let n=[];t&&t.components&&t.components[e]&&t.components[e].variants&&(n=t.components[e].variants);const r={};return n.forEach(o=>{const a=S$(o.props);r[a]=o.style}),r},A7=(e,t,n,r)=>{var o,a;const{ownerState:i={}}=e,l=[],c=n==null||(o=n.components)==null||(a=o[r])==null?void 0:a.variants;return c&&c.forEach(u=>{let d=!0;Object.keys(u.props).forEach(f=>{i[f]!==u.props[f]&&e[f]!==u.props[f]&&(d=!1)}),d&&l.push(t[S$(u.props)])}),l};function Od(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const _7=Vg();function x$(e={}){const{defaultTheme:t=_7,rootShouldForwardProp:n=Od,slotShouldForwardProp:r=Od}=e,o=a=>{const i=Hu(a.theme)?t:a.theme;return Hg(ir({},a,{theme:i}))};return o.__mui_systemSx=!0,(a,i={})=>{gF(a,x=>x.filter(E=>!(E!=null&&E.__mui_systemSx)));const{name:l,slot:c,skipVariantsResolver:u,skipSx:d,overridesResolver:f}=i,h=Si(i,S7),m=u!==void 0?u:c&&c!=="Root"||!1,y=d||!1;let g,v=Od;c==="Root"?v=n:c?v=r:E7(a)&&(v=void 0);const b=p$(a,ir({shouldForwardProp:v,label:g},h)),w=(x,...E)=>{const A=E?E.map(L=>typeof L=="function"&&L.__emotion_real!==L?O=>{let{theme:P}=O,D=Si(O,x7);return L(ir({theme:Hu(P)?t:P},D))}:L):[];let k=x;l&&f&&A.push(L=>{const O=Hu(L.theme)?t:L.theme,P=T7(l,O);if(P){const D={};return Object.entries(P).forEach(([F,U])=>{D[F]=typeof U=="function"?U(ir({},L,{theme:O})):U}),f(L,D)}return null}),l&&!m&&A.push(L=>{const O=Hu(L.theme)?t:L.theme;return A7(L,k7(l,O),O,l)}),y||A.push(o);const _=A.length-E.length;if(Array.isArray(x)&&_>0){const L=new Array(_).fill("");k=[...x,...L],k.raw=[...x.raw,...L]}else typeof x=="function"&&x.__emotion_real!==x&&(k=L=>{let{theme:O}=L,P=Si(L,C7);return x(ir({theme:Hu(O)?t:O},P))});return b(k,...A)};return b.withConfig&&(w.withConfig=b.withConfig),w}}const R7=x$(),Nr=R7;function C$(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:TS(t.components[n].defaultProps,r)}function E$({props:e,name:t,defaultTheme:n}){const r=au(n);return C$({theme:r,name:t,props:e})}function US(e,t=0,n=1){return Math.min(Math.max(t,e),n)}function P7(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function gl(e){if(e.type)return e;if(e.charAt(0)==="#")return gl(P7(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(ms(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(ms(10,o))}else r=r.split(",");return r=r.map(a=>parseFloat(a)),{type:n,values:r,colorSpace:o}}function Gg(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,a)=>a<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function I7(e){e=gl(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,a=r*Math.min(o,1-o),i=(u,d=(u+n/30)%12)=>o-a*Math.max(Math.min(d-3,9-d,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),Gg({type:l,values:c})}function gb(e){e=gl(e);let t=e.type==="hsl"||e.type==="hsla"?gl(I7(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function $7(e,t){const n=gb(e),r=gb(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function Ot(e,t){return e=gl(e),t=US(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,Gg(e)}function gs(e,t){if(e=gl(e),t=US(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return Gg(e)}function vs(e,t){if(e=gl(e),t=US(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return Gg(e)}function RT(e,t=.15){return gb(e)>.5?gs(e,t):vs(e,t)}const O7={};function L7(e){const t=au();return s(NS.Provider,{value:typeof t=="object"?t:O7,children:e.children})}function N7(e){const{children:t,theme:n}=e;return s(m7,{theme:n,children:s(L7,{children:t})})}const M7=["className","component","disableGutters","fixed","maxWidth","classes"],D7=Vg(),B7=Nr("div",{name:"MuiContainer",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`maxWidth${ie(String(n.maxWidth))}`],n.fixed&&t.fixed,n.disableGutters&&t.disableGutters]}}),F7=e=>E$({props:e,name:"MuiContainer",defaultTheme:D7}),z7=(e,t)=>{const n=c=>je(t,c),{classes:r,fixed:o,disableGutters:a,maxWidth:i}=e,l={root:["root",i&&`maxWidth${ie(String(i))}`,o&&"fixed",a&&"disableGutters"]};return He(l,n,r)};function j7(e={}){const{createStyledComponent:t=B7,useThemeProps:n=F7,componentName:r="MuiContainer"}=e,o=t(({theme:i,ownerState:l})=>ir({width:"100%",marginLeft:"auto",boxSizing:"border-box",marginRight:"auto",display:"block"},!l.disableGutters&&{paddingLeft:i.spacing(2),paddingRight:i.spacing(2),[i.breakpoints.up("sm")]:{paddingLeft:i.spacing(3),paddingRight:i.spacing(3)}}),({theme:i,ownerState:l})=>l.fixed&&Object.keys(i.breakpoints.values).reduce((c,u)=>{const d=u,f=i.breakpoints.values[d];return f!==0&&(c[i.breakpoints.up(d)]={maxWidth:`${f}${i.breakpoints.unit}`}),c},{}),({theme:i,ownerState:l})=>ir({},l.maxWidth==="xs"&&{[i.breakpoints.up("xs")]:{maxWidth:Math.max(i.breakpoints.values.xs,444)}},l.maxWidth&&l.maxWidth!=="xs"&&{[i.breakpoints.up(l.maxWidth)]:{maxWidth:`${i.breakpoints.values[l.maxWidth]}${i.breakpoints.unit}`}}));return p.forwardRef(function(l,c){const u=n(l),{className:d,component:f="div",disableGutters:h=!1,fixed:m=!1,maxWidth:y="lg"}=u,g=Si(u,M7),v=ir({},u,{component:f,disableGutters:h,fixed:m,maxWidth:y}),b=z7(v,r);return s(o,ir({as:f,ownerState:v,className:ve(b.root,d),ref:c},g))})}function U7(e,t){return I({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const W7=["mode","contrastThreshold","tonalOffset"],PT={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:lp.white,default:lp.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},s1={text:{primary:lp.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:lp.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function IT(e,t,n,r){const o=r.light||r,a=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=vs(e.main,o):t==="dark"&&(e.dark=gs(e.main,a)))}function H7(e="light"){return e==="dark"?{main:zl[200],light:zl[50],dark:zl[400]}:{main:zl[700],light:zl[400],dark:zl[800]}}function V7(e="light"){return e==="dark"?{main:Fl[200],light:Fl[50],dark:Fl[400]}:{main:Fl[500],light:Fl[300],dark:Fl[700]}}function G7(e="light"){return e==="dark"?{main:Bl[500],light:Bl[300],dark:Bl[700]}:{main:Bl[700],light:Bl[400],dark:Bl[800]}}function q7(e="light"){return e==="dark"?{main:jl[400],light:jl[300],dark:jl[700]}:{main:jl[700],light:jl[500],dark:jl[900]}}function K7(e="light"){return e==="dark"?{main:Ul[400],light:Ul[300],dark:Ul[700]}:{main:Ul[800],light:Ul[500],dark:Ul[900]}}function Y7(e="light"){return e==="dark"?{main:Uu[400],light:Uu[300],dark:Uu[700]}:{main:"#ed6c02",light:Uu[500],dark:Uu[900]}}function X7(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=$e(e,W7),a=e.primary||H7(t),i=e.secondary||V7(t),l=e.error||G7(t),c=e.info||q7(t),u=e.success||K7(t),d=e.warning||Y7(t);function f(g){return $7(g,s1.text.primary)>=n?s1.text.primary:PT.text.primary}const h=({color:g,name:v,mainShade:b=500,lightShade:w=300,darkShade:x=700})=>{if(g=I({},g),!g.main&&g[b]&&(g.main=g[b]),!g.hasOwnProperty("main"))throw new Error(ms(11,v?` (${v})`:"",b));if(typeof g.main!="string")throw new Error(ms(12,v?` (${v})`:"",JSON.stringify(g.main)));return IT(g,"light",w,r),IT(g,"dark",x,r),g.contrastText||(g.contrastText=f(g.main)),g},m={dark:s1,light:PT};return Ro(I({common:I({},lp),mode:t,primary:h({color:a,name:"primary"}),secondary:h({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:h({color:l,name:"error"}),warning:h({color:d,name:"warning"}),info:h({color:c,name:"info"}),success:h({color:u,name:"success"}),grey:z9,contrastThreshold:n,getContrastText:f,augmentColor:h,tonalOffset:r},m[t]),o)}const J7=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Q7(e){return Math.round(e*1e5)/1e5}const $T={textTransform:"uppercase"},OT='"Roboto", "Helvetica", "Arial", sans-serif';function Z7(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=OT,fontSize:o=14,fontWeightLight:a=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:u=16,allVariants:d,pxToRem:f}=n,h=$e(n,J7),m=o/14,y=f||(b=>`${b/u*m}rem`),g=(b,w,x,E,A)=>I({fontFamily:r,fontWeight:b,fontSize:y(w),lineHeight:x},r===OT?{letterSpacing:`${Q7(E/w)}em`}:{},A,d),v={h1:g(a,96,1.167,-1.5),h2:g(a,60,1.2,-.5),h3:g(i,48,1.167,0),h4:g(i,34,1.235,.25),h5:g(i,24,1.334,0),h6:g(l,20,1.6,.15),subtitle1:g(i,16,1.75,.15),subtitle2:g(l,14,1.57,.1),body1:g(i,16,1.5,.15),body2:g(i,14,1.43,.15),button:g(l,14,1.75,.4,$T),caption:g(i,12,1.66,.4),overline:g(i,12,2.66,1,$T)};return Ro(I({htmlFontSize:u,pxToRem:y,fontFamily:r,fontSize:o,fontWeightLight:a,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},v),h,{clone:!1})}const e8=.2,t8=.14,n8=.12;function Bn(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${e8})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${t8})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${n8})`].join(",")}const r8=["none",Bn(0,2,1,-1,0,1,1,0,0,1,3,0),Bn(0,3,1,-2,0,2,2,0,0,1,5,0),Bn(0,3,3,-2,0,3,4,0,0,1,8,0),Bn(0,2,4,-1,0,4,5,0,0,1,10,0),Bn(0,3,5,-1,0,5,8,0,0,1,14,0),Bn(0,3,5,-1,0,6,10,0,0,1,18,0),Bn(0,4,5,-2,0,7,10,1,0,2,16,1),Bn(0,5,5,-3,0,8,10,1,0,3,14,2),Bn(0,5,6,-3,0,9,12,1,0,3,16,2),Bn(0,6,6,-3,0,10,14,1,0,4,18,3),Bn(0,6,7,-4,0,11,15,1,0,4,20,3),Bn(0,7,8,-4,0,12,17,2,0,5,22,4),Bn(0,7,8,-4,0,13,19,2,0,5,24,4),Bn(0,7,9,-4,0,14,21,2,0,5,26,4),Bn(0,8,9,-5,0,15,22,2,0,6,28,5),Bn(0,8,10,-5,0,16,24,2,0,6,30,5),Bn(0,8,11,-5,0,17,26,2,0,6,32,5),Bn(0,9,11,-5,0,18,28,2,0,7,34,6),Bn(0,9,12,-6,0,19,29,2,0,7,36,6),Bn(0,10,13,-6,0,20,31,3,0,8,38,7),Bn(0,10,13,-6,0,21,33,3,0,8,40,7),Bn(0,10,14,-6,0,22,35,3,0,8,42,7),Bn(0,11,14,-7,0,23,36,3,0,9,44,8),Bn(0,11,15,-7,0,24,38,3,0,9,46,8)],o8=r8,a8=["duration","easing","delay"],i8={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},T$={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function LT(e){return`${Math.round(e)}ms`}function s8(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function l8(e){const t=I({},i8,e.easing),n=I({},T$,e.duration);return I({getAutoHeightDuration:s8,create:(o=["all"],a={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=a;return $e(a,a8),(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:LT(i)} ${l} ${typeof c=="string"?c:LT(c)}`).join(",")}},e,{easing:t,duration:n})}const c8={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},u8=c8,d8=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function qg(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:a={}}=e,i=$e(e,d8);if(e.vars)throw new Error(ms(18));const l=X7(r),c=Vg(e);let u=Ro(c,{mixins:U7(c.breakpoints,n),palette:l,shadows:o8.slice(),typography:Z7(l,a),transitions:l8(o),zIndex:I({},u8)});return u=Ro(u,i),u=t.reduce((d,f)=>Ro(d,f),u),u.unstable_sxConfig=I({},Wg,i==null?void 0:i.unstable_sxConfig),u.unstable_sx=function(f){return Hg({sx:f,theme:this})},u}const p8=qg(),Kg=p8;function on(){return au(Kg)}function Ve({props:e,name:t}){return E$({props:e,name:t,defaultTheme:Kg})}const Bo=e=>Od(e)&&e!=="classes",WS=Od,f8=x$({defaultTheme:Kg,rootShouldForwardProp:Bo}),C=f8,h8=e=>{let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,(t/100).toFixed(2)},NT=h8;function sn(){return sn=Object.assign?Object.assign.bind():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},sn.apply(this,arguments)}function qa(e){return typeof e=="string"}function hd(e,t,n){return e===void 0||qa(e)?t:sn({},t,{ownerState:sn({},t.ownerState,n)})}function m8(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function vb(e,t){return typeof e=="function"?e(t):e}function Vp(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,a;for(a=0;a<r.length;a++)o=r[a],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function MT(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function g8(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:a}=e;if(!t){const m=ve(o==null?void 0:o.className,r==null?void 0:r.className,a,n==null?void 0:n.className),y=sn({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),g=sn({},n,o,r);return m.length>0&&(g.className=m),Object.keys(y).length>0&&(g.style=y),{props:g,internalRef:void 0}}const i=m8(sn({},o,r)),l=MT(r),c=MT(o),u=t(i),d=ve(u==null?void 0:u.className,n==null?void 0:n.className,a,o==null?void 0:o.className,r==null?void 0:r.className),f=sn({},u==null?void 0:u.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),h=sn({},u,n,c,l);return d.length>0&&(h.className=d),Object.keys(f).length>0&&(h.style=f),{props:h,internalRef:u.ref}}const v8=["elementType","externalSlotProps","ownerState"];function ga(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o}=e,a=Vp(e,v8),i=vb(r,o),{props:l,internalRef:c}=g8(sn({},a,{externalSlotProps:i})),u=Sn(c,i==null?void 0:i.ref,(t=e.additionalProps)==null?void 0:t.ref);return hd(n,sn({},l,{ref:u}),o)}function DT(e){return typeof e.normalize<"u"?e.normalize("NFD").replace(/[\u0300-\u036f]/g,""):e}function y8(e={}){const{ignoreAccents:t=!0,ignoreCase:n=!0,limit:r,matchFrom:o="any",stringify:a,trim:i=!1}=e;return(l,{inputValue:c,getOptionLabel:u})=>{let d=i?c.trim():c;n&&(d=d.toLowerCase()),t&&(d=DT(d));const f=d?l.filter(h=>{let m=(a||u)(h);return n&&(m=m.toLowerCase()),t&&(m=DT(m)),o==="start"?m.indexOf(d)===0:m.indexOf(d)>-1}):l;return typeof r=="number"?f.slice(0,r):f}}function l1(e,t){for(let n=0;n<e.length;n+=1)if(t(e[n]))return n;return-1}const b8=y8(),BT=5,w8=e=>{var t;return e.current!==null&&((t=e.current.parentElement)==null?void 0:t.contains(document.activeElement))};function S8(e){const{unstable_isActiveElementInListbox:t=w8,unstable_classNamePrefix:n="Mui",autoComplete:r=!1,autoHighlight:o=!1,autoSelect:a=!1,blurOnSelect:i=!1,clearOnBlur:l=!e.freeSolo,clearOnEscape:c=!1,componentName:u="useAutocomplete",defaultValue:d=e.multiple?[]:null,disableClearable:f=!1,disableCloseOnSelect:h=!1,disabled:m,disabledItemsFocusable:y=!1,disableListWrap:g=!1,filterOptions:v=b8,filterSelectedOptions:b=!1,freeSolo:w=!1,getOptionDisabled:x,getOptionLabel:E=ue=>{var ae;return(ae=ue.label)!=null?ae:ue},groupBy:A,handleHomeEndKeys:k=!e.freeSolo,id:_,includeInputInList:$=!1,inputValue:L,isOptionEqualToValue:O=(ue,ae)=>ue===ae,multiple:P=!1,onChange:D,onClose:F,onHighlightChange:U,onInputChange:Y,onOpen:V,open:te,openOnFocus:Z=!1,options:W,readOnly:z=!1,selectOnFocus:R=!e.freeSolo,value:M}=e,ee=nu(_);let re=E;re=ue=>{const ae=E(ue);return typeof ae!="string"?String(ae):ae};const Se=p.useRef(!1),ce=p.useRef(!0),Ce=p.useRef(null),xe=p.useRef(null),[Ee,tt]=p.useState(null),[me,Ge]=p.useState(-1),qe=o?0:-1,Be=p.useRef(qe),[he,Et]=Sa({controlled:M,default:d,name:u}),[Ke,ct]=Sa({controlled:L,default:"",name:u,state:"inputValue"}),[Rt,dt]=p.useState(!1),rt=p.useCallback((ue,ae)=>{if(!(P?he.length<ae.length:ae!==null)&&!l)return;let ot;if(P)ot="";else if(ae==null)ot="";else{const kt=re(ae);ot=typeof kt=="string"?kt:""}Ke!==ot&&(ct(ot),Y&&Y(ue,ot,"reset"))},[re,Ke,P,Y,ct,l,he]),[Nt,xt]=Sa({controlled:te,default:!1,name:u,state:"open"}),[pe,Te]=p.useState(!0),Xe=!P&&he!=null&&Ke===re(he),De=Nt&&!z,q=De?v(W.filter(ue=>!(b&&(P?he:[he]).some(ae=>ae!==null&&O(ue,ae)))),{inputValue:Xe&&pe?"":Ke,getOptionLabel:re}):[],K=lB({filteredOptions:q,value:he});p.useEffect(()=>{const ue=he!==K.value;Rt&&!ue||w&&!ue||rt(null,he)},[he,rt,Rt,K.value,w]);const se=Nt&&q.length>0&&!z,be=gr(ue=>{ue===-1?Ce.current.focus():Ee.querySelector(`[data-tag-index="${ue}"]`).focus()});p.useEffect(()=>{P&&me>he.length-1&&(Ge(-1),be(-1))},[he,P,me,be]);function Ae(ue,ae){if(!xe.current||ue===-1)return-1;let Fe=ue;for(;;){if(ae==="next"&&Fe===q.length||ae==="previous"&&Fe===-1)return-1;const ot=xe.current.querySelector(`[data-option-index="${Fe}"]`),kt=y?!1:!ot||ot.disabled||ot.getAttribute("aria-disabled")==="true";if(ot&&!ot.hasAttribute("tabindex")||kt)Fe+=ae==="next"?1:-1;else return Fe}}const mt=gr(({event:ue,index:ae,reason:Fe="auto"})=>{if(Be.current=ae,ae===-1?Ce.current.removeAttribute("aria-activedescendant"):Ce.current.setAttribute("aria-activedescendant",`${ee}-option-${ae}`),U&&U(ue,ae===-1?null:q[ae],Fe),!xe.current)return;const ot=xe.current.querySelector(`[role="option"].${n}-focused`);ot&&(ot.classList.remove(`${n}-focused`),ot.classList.remove(`${n}-focusVisible`));const kt=xe.current.parentElement.querySelector('[role="listbox"]');if(!kt)return;if(ae===-1){kt.scrollTop=0;return}const Tn=xe.current.querySelector(`[data-option-index="${ae}"]`);if(Tn&&(Tn.classList.add(`${n}-focused`),Fe==="keyboard"&&Tn.classList.add(`${n}-focusVisible`),kt.scrollHeight>kt.clientHeight&&Fe!=="mouse")){const _n=Tn,yt=kt.clientHeight+kt.scrollTop,Rn=_n.offsetTop+_n.offsetHeight;Rn>yt?kt.scrollTop=Rn-kt.clientHeight:_n.offsetTop-_n.offsetHeight*(A?1.3:0)<kt.scrollTop&&(kt.scrollTop=_n.offsetTop-_n.offsetHeight*(A?1.3:0))}}),et=gr(({event:ue,diff:ae,direction:Fe="next",reason:ot="auto"})=>{if(!De)return;const Tn=Ae((()=>{const _n=q.length-1;if(ae==="reset")return qe;if(ae==="start")return 0;if(ae==="end")return _n;const yt=Be.current+ae;return yt<0?yt===-1&&$?-1:g&&Be.current!==-1||Math.abs(ae)>1?0:_n:yt>_n?yt===_n+1&&$?-1:g||Math.abs(ae)>1?_n:0:yt})(),Fe);if(mt({index:Tn,reason:ot,event:ue}),r&&ae!=="reset")if(Tn===-1)Ce.current.value=Ke;else{const _n=re(q[Tn]);Ce.current.value=_n,_n.toLowerCase().indexOf(Ke.toLowerCase())===0&&Ke.length>0&&Ce.current.setSelectionRange(Ke.length,_n.length)}}),ht=()=>{const ue=(ae,Fe)=>{const ot=ae?re(ae):"",kt=Fe?re(Fe):"";return ot===kt};if(Be.current!==-1&&K.filteredOptions&&K.filteredOptions.length!==q.length&&(P?he.length===K.value.length&&K.value.every((ae,Fe)=>re(he[Fe])===re(ae)):ue(K.value,he))){const ae=K.filteredOptions[Be.current];if(ae&&q.some(ot=>re(ot)===re(ae)))return!0}return!1},Xt=p.useCallback(()=>{if(!De||ht())return;const ue=P?he[0]:he;if(q.length===0||ue==null){et({diff:"reset"});return}if(xe.current){if(ue!=null){const ae=q[Be.current];if(P&&ae&&l1(he,ot=>O(ae,ot))!==-1)return;const Fe=l1(q,ot=>O(ot,ue));Fe===-1?et({diff:"reset"}):mt({index:Fe});return}if(Be.current>=q.length-1){mt({index:q.length-1});return}mt({index:Be.current})}},[q.length,P?!1:he,b,et,mt,De,Ke,P]),Mn=gr(ue=>{cp(xe,ue),ue&&Xt()});p.useEffect(()=>{Xt()},[Xt]);const pt=ue=>{Nt||(xt(!0),Te(!0),V&&V(ue))},pn=(ue,ae)=>{Nt&&(xt(!1),F&&F(ue,ae))},Vt=(ue,ae,Fe,ot)=>{if(P){if(he.length===ae.length&&he.every((kt,Tn)=>kt===ae[Tn]))return}else if(he===ae)return;D&&D(ue,ae,Fe,ot),Et(ae)},en=p.useRef(!1),Ft=(ue,ae,Fe="selectOption",ot="options")=>{let kt=Fe,Tn=ae;if(P){Tn=Array.isArray(he)?he.slice():[];const _n=l1(Tn,yt=>O(ae,yt));_n===-1?Tn.push(ae):ot!=="freeSolo"&&(Tn.splice(_n,1),kt="removeOption")}rt(ue,Tn),Vt(ue,Tn,kt,{option:ae}),!h&&(!ue||!ue.ctrlKey&&!ue.metaKey)&&pn(ue,kt),(i===!0||i==="touch"&&en.current||i==="mouse"&&!en.current)&&Ce.current.blur()};function Hn(ue,ae){if(ue===-1)return-1;let Fe=ue;for(;;){if(ae==="next"&&Fe===he.length||ae==="previous"&&Fe===-1)return-1;const ot=Ee.querySelector(`[data-tag-index="${Fe}"]`);if(!ot||!ot.hasAttribute("tabindex")||ot.disabled||ot.getAttribute("aria-disabled")==="true")Fe+=ae==="next"?1:-1;else return Fe}}const br=(ue,ae)=>{if(!P)return;Ke===""&&pn(ue,"toggleInput");let Fe=me;me===-1?Ke===""&&ae==="previous"&&(Fe=he.length-1):(Fe+=ae==="next"?1:-1,Fe<0&&(Fe=0),Fe===he.length&&(Fe=-1)),Fe=Hn(Fe,ae),Ge(Fe),be(Fe)},ro=ue=>{Se.current=!0,ct(""),Y&&Y(ue,"","clear"),Vt(ue,P?[]:null,"clear")},yo=ue=>ae=>{if(ue.onKeyDown&&ue.onKeyDown(ae),!ae.defaultMuiPrevented&&(me!==-1&&["ArrowLeft","ArrowRight"].indexOf(ae.key)===-1&&(Ge(-1),be(-1)),ae.which!==229))switch(ae.key){case"Home":De&&k&&(ae.preventDefault(),et({diff:"start",direction:"next",reason:"keyboard",event:ae}));break;case"End":De&&k&&(ae.preventDefault(),et({diff:"end",direction:"previous",reason:"keyboard",event:ae}));break;case"PageUp":ae.preventDefault(),et({diff:-BT,direction:"previous",reason:"keyboard",event:ae}),pt(ae);break;case"PageDown":ae.preventDefault(),et({diff:BT,direction:"next",reason:"keyboard",event:ae}),pt(ae);break;case"ArrowDown":ae.preventDefault(),et({diff:1,direction:"next",reason:"keyboard",event:ae}),pt(ae);break;case"ArrowUp":ae.preventDefault(),et({diff:-1,direction:"previous",reason:"keyboard",event:ae}),pt(ae);break;case"ArrowLeft":br(ae,"previous");break;case"ArrowRight":br(ae,"next");break;case"Enter":if(Be.current!==-1&&De){const Fe=q[Be.current],ot=x?x(Fe):!1;if(ae.preventDefault(),ot)return;Ft(ae,Fe,"selectOption"),r&&Ce.current.setSelectionRange(Ce.current.value.length,Ce.current.value.length)}else w&&Ke!==""&&Xe===!1&&(P&&ae.preventDefault(),Ft(ae,Ke,"createOption","freeSolo"));break;case"Escape":De?(ae.preventDefault(),ae.stopPropagation(),pn(ae,"escape")):c&&(Ke!==""||P&&he.length>0)&&(ae.preventDefault(),ae.stopPropagation(),ro(ae));break;case"Backspace":if(P&&!z&&Ke===""&&he.length>0){const Fe=me===-1?he.length-1:me,ot=he.slice();ot.splice(Fe,1),Vt(ae,ot,"removeOption",{option:he[Fe]})}break;case"Delete":if(P&&!z&&Ke===""&&he.length>0&&me!==-1){const Fe=me,ot=he.slice();ot.splice(Fe,1),Vt(ae,ot,"removeOption",{option:he[Fe]})}break}},bo=ue=>{dt(!0),Z&&!Se.current&&pt(ue)},Rr=ue=>{if(t(xe)){Ce.current.focus();return}dt(!1),ce.current=!0,Se.current=!1,a&&Be.current!==-1&&De?Ft(ue,q[Be.current],"blur"):a&&w&&Ke!==""?Ft(ue,Ke,"blur","freeSolo"):l&&rt(ue,he),pn(ue,"blur")},oo=ue=>{const ae=ue.target.value;Ke!==ae&&(ct(ae),Te(!1),Y&&Y(ue,ae,"input")),ae===""?!f&&!P&&Vt(ue,null,"clear"):pt(ue)},Jn=ue=>{mt({event:ue,index:Number(ue.currentTarget.getAttribute("data-option-index")),reason:"mouse"})},ao=()=>{en.current=!0},wr=ue=>{const ae=Number(ue.currentTarget.getAttribute("data-option-index"));Ft(ue,q[ae],"selectOption"),en.current=!1},Bt=ue=>ae=>{const Fe=he.slice();Fe.splice(ue,1),Vt(ae,Fe,"removeOption",{option:he[ue]})},Gt=ue=>{Nt?pn(ue,"toggleInput"):pt(ue)},jn=ue=>{ue.target.getAttribute("id")!==ee&&ue.preventDefault()},hr=()=>{Ce.current.focus(),R&&ce.current&&Ce.current.selectionEnd-Ce.current.selectionStart===0&&Ce.current.select(),ce.current=!1},Kr=ue=>{(Ke===""||!Nt)&&Gt(ue)};let Yr=w&&Ke.length>0;Yr=Yr||(P?he.length>0:he!==null);let pa=q;return A&&(pa=q.reduce((ue,ae,Fe)=>{const ot=A(ae);return ue.length>0&&ue[ue.length-1].group===ot?ue[ue.length-1].options.push(ae):ue.push({key:Fe,index:Fe,group:ot,options:[ae]}),ue},[])),m&&Rt&&Rr(),{getRootProps:(ue={})=>sn({"aria-owns":se?`${ee}-listbox`:null},ue,{onKeyDown:yo(ue),onMouseDown:jn,onClick:hr}),getInputLabelProps:()=>({id:`${ee}-label`,htmlFor:ee}),getInputProps:()=>({id:ee,value:Ke,onBlur:Rr,onFocus:bo,onChange:oo,onMouseDown:Kr,"aria-activedescendant":De?"":null,"aria-autocomplete":r?"both":"list","aria-controls":se?`${ee}-listbox`:void 0,"aria-expanded":se,autoComplete:"off",ref:Ce,autoCapitalize:"none",spellCheck:"false",role:"combobox",disabled:m}),getClearProps:()=>({tabIndex:-1,onClick:ro}),getPopupIndicatorProps:()=>({tabIndex:-1,onClick:Gt}),getTagProps:({index:ue})=>sn({key:ue,"data-tag-index":ue,tabIndex:-1},!z&&{onDelete:Bt(ue)}),getListboxProps:()=>({role:"listbox",id:`${ee}-listbox`,"aria-labelledby":`${ee}-label`,ref:Mn,onMouseDown:ue=>{ue.preventDefault()}}),getOptionProps:({index:ue,option:ae})=>{const Fe=(P?he:[he]).some(kt=>kt!=null&&O(ae,kt)),ot=x?x(ae):!1;return{key:re(ae),tabIndex:-1,role:"option",id:`${ee}-option-${ue}`,onMouseOver:Jn,onClick:wr,onTouchStart:ao,"data-option-index":ue,"aria-disabled":ot,"aria-selected":Fe}},id:ee,inputValue:Ke,value:he,dirty:Yr,popupOpen:De,focused:Rt||me!==-1,anchorEl:Ee,setAnchorEl:tt,focusedTag:me,groupedOptions:pa}}function FT(e){return e.substring(2).toLowerCase()}function x8(e,t){return t.documentElement.clientWidth<e.clientX||t.documentElement.clientHeight<e.clientY}function k$(e){const{children:t,disableReactTree:n=!1,mouseEvent:r="onClick",onClickAway:o,touchEvent:a="onTouchEnd"}=e,i=p.useRef(!1),l=p.useRef(null),c=p.useRef(!1),u=p.useRef(!1);p.useEffect(()=>(setTimeout(()=>{c.current=!0},0),()=>{c.current=!1}),[]);const d=Sn(t.ref,l),f=gr(y=>{const g=u.current;u.current=!1;const v=Fn(l.current);if(!c.current||!l.current||"clientX"in y&&x8(y,v))return;if(i.current){i.current=!1;return}let b;y.composedPath?b=y.composedPath().indexOf(l.current)>-1:b=!v.documentElement.contains(y.target)||l.current.contains(y.target),!b&&(n||!g)&&o(y)}),h=y=>g=>{u.current=!0;const v=t.props[y];v&&v(g)},m={ref:d};return a!==!1&&(m[a]=h(a)),p.useEffect(()=>{if(a!==!1){const y=FT(a),g=Fn(l.current),v=()=>{i.current=!0};return g.addEventListener(y,f),g.addEventListener("touchmove",v),()=>{g.removeEventListener(y,f),g.removeEventListener("touchmove",v)}}},[f,a]),r!==!1&&(m[r]=h(r)),p.useEffect(()=>{if(r!==!1){const y=FT(r),g=Fn(l.current);return g.addEventListener(y,f),()=>{g.removeEventListener(y,f)}}},[f,r]),s(p.Fragment,{children:p.cloneElement(t,m)})}const C8=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function E8(e){const t=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(t)?e.contentEditable==="true"||(e.nodeName==="AUDIO"||e.nodeName==="VIDEO"||e.nodeName==="DETAILS")&&e.getAttribute("tabindex")===null?0:e.tabIndex:t}function T8(e){if(e.tagName!=="INPUT"||e.type!=="radio"||!e.name)return!1;const t=r=>e.ownerDocument.querySelector(`input[type="radio"]${r}`);let n=t(`[name="${e.name}"]:checked`);return n||(n=t(`[name="${e.name}"]`)),n!==e}function k8(e){return!(e.disabled||e.tagName==="INPUT"&&e.type==="hidden"||T8(e))}function A8(e){const t=[],n=[];return Array.from(e.querySelectorAll(C8)).forEach((r,o)=>{const a=E8(r);a===-1||!k8(r)||(a===0?t.push(r):n.push({documentOrder:o,tabIndex:a,node:r}))}),n.sort((r,o)=>r.tabIndex===o.tabIndex?r.documentOrder-o.documentOrder:r.tabIndex-o.tabIndex).map(r=>r.node).concat(t)}function _8(){return!0}function R8(e){const{children:t,disableAutoFocus:n=!1,disableEnforceFocus:r=!1,disableRestoreFocus:o=!1,getTabbable:a=A8,isEnabled:i=_8,open:l}=e,c=p.useRef(!1),u=p.useRef(null),d=p.useRef(null),f=p.useRef(null),h=p.useRef(null),m=p.useRef(!1),y=p.useRef(null),g=Sn(t.ref,y),v=p.useRef(null);p.useEffect(()=>{!l||!y.current||(m.current=!n)},[n,l]),p.useEffect(()=>{if(!l||!y.current)return;const x=Fn(y.current);return y.current.contains(x.activeElement)||(y.current.hasAttribute("tabIndex")||y.current.setAttribute("tabIndex","-1"),m.current&&y.current.focus()),()=>{o||(f.current&&f.current.focus&&(c.current=!0,f.current.focus()),f.current=null)}},[l]),p.useEffect(()=>{if(!l||!y.current)return;const x=Fn(y.current),E=_=>{const{current:$}=y;if($!==null){if(!x.hasFocus()||r||!i()||c.current){c.current=!1;return}if(!$.contains(x.activeElement)){if(_&&h.current!==_.target||x.activeElement!==h.current)h.current=null;else if(h.current!==null)return;if(!m.current)return;let P=[];if((x.activeElement===u.current||x.activeElement===d.current)&&(P=a(y.current)),P.length>0){var L,O;const D=Boolean(((L=v.current)==null?void 0:L.shiftKey)&&((O=v.current)==null?void 0:O.key)==="Tab"),F=P[0],U=P[P.length-1];typeof F!="string"&&typeof U!="string"&&(D?U.focus():F.focus())}else $.focus()}}},A=_=>{v.current=_,!(r||!i()||_.key!=="Tab")&&x.activeElement===y.current&&_.shiftKey&&(c.current=!0,d.current&&d.current.focus())};x.addEventListener("focusin",E),x.addEventListener("keydown",A,!0);const k=setInterval(()=>{x.activeElement&&x.activeElement.tagName==="BODY"&&E(null)},50);return()=>{clearInterval(k),x.removeEventListener("focusin",E),x.removeEventListener("keydown",A,!0)}},[n,r,o,i,l,a]);const b=x=>{f.current===null&&(f.current=x.relatedTarget),m.current=!0,h.current=x.target;const E=t.props.onFocus;E&&E(x)},w=x=>{f.current===null&&(f.current=x.relatedTarget),m.current=!0};return T(p.Fragment,{children:[s("div",{tabIndex:l?0:-1,onFocus:w,ref:u,"data-testid":"sentinelStart"}),p.cloneElement(t,{ref:g,onFocus:b}),s("div",{tabIndex:l?0:-1,onFocus:w,ref:d,"data-testid":"sentinelEnd"})]})}var fo="top",ra="bottom",oa="right",ho="left",HS="auto",Gp=[fo,ra,oa,ho],Mc="start",fp="end",P8="clippingParents",A$="viewport",Vu="popper",I8="reference",zT=Gp.reduce(function(e,t){return e.concat([t+"-"+Mc,t+"-"+fp])},[]),_$=[].concat(Gp,[HS]).reduce(function(e,t){return e.concat([t,t+"-"+Mc,t+"-"+fp])},[]),$8="beforeRead",O8="read",L8="afterRead",N8="beforeMain",M8="main",D8="afterMain",B8="beforeWrite",F8="write",z8="afterWrite",j8=[$8,O8,L8,N8,M8,D8,B8,F8,z8];function Qa(e){return e?(e.nodeName||"").toLowerCase():null}function la(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function vl(e){var t=la(e).Element;return e instanceof t||e instanceof Element}function Xo(e){var t=la(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function VS(e){if(typeof ShadowRoot>"u")return!1;var t=la(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function U8(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},a=t.elements[n];!Xo(a)||!Qa(a)||(Object.assign(a.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?a.removeAttribute(i):a.setAttribute(i,l===!0?"":l)}))})}function W8(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],a=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,u){return c[u]="",c},{});!Xo(o)||!Qa(o)||(Object.assign(o.style,l),Object.keys(a).forEach(function(c){o.removeAttribute(c)}))})}}const H8={name:"applyStyles",enabled:!0,phase:"write",fn:U8,effect:W8,requires:["computeStyles"]};function Ka(e){return e.split("-")[0]}var sl=Math.max,xm=Math.min,Dc=Math.round;function yb(){var e=navigator.userAgentData;return e!=null&&e.brands?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function R$(){return!/^((?!chrome|android).)*safari/i.test(yb())}function Bc(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,a=1;t&&Xo(e)&&(o=e.offsetWidth>0&&Dc(r.width)/e.offsetWidth||1,a=e.offsetHeight>0&&Dc(r.height)/e.offsetHeight||1);var i=vl(e)?la(e):window,l=i.visualViewport,c=!R$()&&n,u=(r.left+(c&&l?l.offsetLeft:0))/o,d=(r.top+(c&&l?l.offsetTop:0))/a,f=r.width/o,h=r.height/a;return{width:f,height:h,top:d,right:u+f,bottom:d+h,left:u,x:u,y:d}}function GS(e){var t=Bc(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function P$(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&VS(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function Ti(e){return la(e).getComputedStyle(e)}function V8(e){return["table","td","th"].indexOf(Qa(e))>=0}function As(e){return((vl(e)?e.ownerDocument:e.document)||window.document).documentElement}function Yg(e){return Qa(e)==="html"?e:e.assignedSlot||e.parentNode||(VS(e)?e.host:null)||As(e)}function jT(e){return!Xo(e)||Ti(e).position==="fixed"?null:e.offsetParent}function G8(e){var t=/firefox/i.test(yb()),n=/Trident/i.test(yb());if(n&&Xo(e)){var r=Ti(e);if(r.position==="fixed")return null}var o=Yg(e);for(VS(o)&&(o=o.host);Xo(o)&&["html","body"].indexOf(Qa(o))<0;){var a=Ti(o);if(a.transform!=="none"||a.perspective!=="none"||a.contain==="paint"||["transform","perspective"].indexOf(a.willChange)!==-1||t&&a.willChange==="filter"||t&&a.filter&&a.filter!=="none")return o;o=o.parentNode}return null}function qp(e){for(var t=la(e),n=jT(e);n&&V8(n)&&Ti(n).position==="static";)n=jT(n);return n&&(Qa(n)==="html"||Qa(n)==="body"&&Ti(n).position==="static")?t:n||G8(e)||t}function qS(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Ld(e,t,n){return sl(e,xm(t,n))}function q8(e,t,n){var r=Ld(e,t,n);return r>n?n:r}function I$(){return{top:0,right:0,bottom:0,left:0}}function $$(e){return Object.assign({},I$(),e)}function O$(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var K8=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,$$(typeof t!="number"?t:O$(t,Gp))};function Y8(e){var t,n=e.state,r=e.name,o=e.options,a=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Ka(n.placement),c=qS(l),u=[ho,oa].indexOf(l)>=0,d=u?"height":"width";if(!(!a||!i)){var f=K8(o.padding,n),h=GS(a),m=c==="y"?fo:ho,y=c==="y"?ra:oa,g=n.rects.reference[d]+n.rects.reference[c]-i[c]-n.rects.popper[d],v=i[c]-n.rects.reference[c],b=qp(a),w=b?c==="y"?b.clientHeight||0:b.clientWidth||0:0,x=g/2-v/2,E=f[m],A=w-h[d]-f[y],k=w/2-h[d]/2+x,_=Ld(E,k,A),$=c;n.modifiersData[r]=(t={},t[$]=_,t.centerOffset=_-k,t)}}function X8(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||P$(t.elements.popper,o)&&(t.elements.arrow=o))}const J8={name:"arrow",enabled:!0,phase:"main",fn:Y8,effect:X8,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Fc(e){return e.split("-")[1]}var Q8={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Z8(e){var t=e.x,n=e.y,r=window,o=r.devicePixelRatio||1;return{x:Dc(t*o)/o||0,y:Dc(n*o)/o||0}}function UT(e){var t,n=e.popper,r=e.popperRect,o=e.placement,a=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,u=e.adaptive,d=e.roundOffsets,f=e.isFixed,h=i.x,m=h===void 0?0:h,y=i.y,g=y===void 0?0:y,v=typeof d=="function"?d({x:m,y:g}):{x:m,y:g};m=v.x,g=v.y;var b=i.hasOwnProperty("x"),w=i.hasOwnProperty("y"),x=ho,E=fo,A=window;if(u){var k=qp(n),_="clientHeight",$="clientWidth";if(k===la(n)&&(k=As(n),Ti(k).position!=="static"&&l==="absolute"&&(_="scrollHeight",$="scrollWidth")),k=k,o===fo||(o===ho||o===oa)&&a===fp){E=ra;var L=f&&k===A&&A.visualViewport?A.visualViewport.height:k[_];g-=L-r.height,g*=c?1:-1}if(o===ho||(o===fo||o===ra)&&a===fp){x=oa;var O=f&&k===A&&A.visualViewport?A.visualViewport.width:k[$];m-=O-r.width,m*=c?1:-1}}var P=Object.assign({position:l},u&&Q8),D=d===!0?Z8({x:m,y:g}):{x:m,y:g};if(m=D.x,g=D.y,c){var F;return Object.assign({},P,(F={},F[E]=w?"0":"",F[x]=b?"0":"",F.transform=(A.devicePixelRatio||1)<=1?"translate("+m+"px, "+g+"px)":"translate3d("+m+"px, "+g+"px, 0)",F))}return Object.assign({},P,(t={},t[E]=w?g+"px":"",t[x]=b?m+"px":"",t.transform="",t))}function ez(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,a=n.adaptive,i=a===void 0?!0:a,l=n.roundOffsets,c=l===void 0?!0:l,u={placement:Ka(t.placement),variation:Fc(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,UT(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,UT(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const tz={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:ez,data:{}};var Bf={passive:!0};function nz(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,a=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=la(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&u.forEach(function(d){d.addEventListener("scroll",n.update,Bf)}),l&&c.addEventListener("resize",n.update,Bf),function(){a&&u.forEach(function(d){d.removeEventListener("scroll",n.update,Bf)}),l&&c.removeEventListener("resize",n.update,Bf)}}const rz={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:nz,data:{}};var oz={left:"right",right:"left",bottom:"top",top:"bottom"};function Oh(e){return e.replace(/left|right|bottom|top/g,function(t){return oz[t]})}var az={start:"end",end:"start"};function WT(e){return e.replace(/start|end/g,function(t){return az[t]})}function KS(e){var t=la(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function YS(e){return Bc(As(e)).left+KS(e).scrollLeft}function iz(e,t){var n=la(e),r=As(e),o=n.visualViewport,a=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){a=o.width,i=o.height;var u=R$();(u||!u&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:a,height:i,x:l+YS(e),y:c}}function sz(e){var t,n=As(e),r=KS(e),o=(t=e.ownerDocument)==null?void 0:t.body,a=sl(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=sl(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+YS(e),c=-r.scrollTop;return Ti(o||n).direction==="rtl"&&(l+=sl(n.clientWidth,o?o.clientWidth:0)-a),{width:a,height:i,x:l,y:c}}function XS(e){var t=Ti(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function L$(e){return["html","body","#document"].indexOf(Qa(e))>=0?e.ownerDocument.body:Xo(e)&&XS(e)?e:L$(Yg(e))}function Nd(e,t){var n;t===void 0&&(t=[]);var r=L$(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),a=la(r),i=o?[a].concat(a.visualViewport||[],XS(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(Nd(Yg(i)))}function bb(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function lz(e,t){var n=Bc(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function HT(e,t,n){return t===A$?bb(iz(e,n)):vl(t)?lz(t,n):bb(sz(As(e)))}function cz(e){var t=Nd(Yg(e)),n=["absolute","fixed"].indexOf(Ti(e).position)>=0,r=n&&Xo(e)?qp(e):e;return vl(r)?t.filter(function(o){return vl(o)&&P$(o,r)&&Qa(o)!=="body"}):[]}function uz(e,t,n,r){var o=t==="clippingParents"?cz(e):[].concat(t),a=[].concat(o,[n]),i=a[0],l=a.reduce(function(c,u){var d=HT(e,u,r);return c.top=sl(d.top,c.top),c.right=xm(d.right,c.right),c.bottom=xm(d.bottom,c.bottom),c.left=sl(d.left,c.left),c},HT(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function N$(e){var t=e.reference,n=e.element,r=e.placement,o=r?Ka(r):null,a=r?Fc(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case fo:c={x:i,y:t.y-n.height};break;case ra:c={x:i,y:t.y+t.height};break;case oa:c={x:t.x+t.width,y:l};break;case ho:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var u=o?qS(o):null;if(u!=null){var d=u==="y"?"height":"width";switch(a){case Mc:c[u]=c[u]-(t[d]/2-n[d]/2);break;case fp:c[u]=c[u]+(t[d]/2-n[d]/2);break}}return c}function hp(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,a=n.strategy,i=a===void 0?e.strategy:a,l=n.boundary,c=l===void 0?P8:l,u=n.rootBoundary,d=u===void 0?A$:u,f=n.elementContext,h=f===void 0?Vu:f,m=n.altBoundary,y=m===void 0?!1:m,g=n.padding,v=g===void 0?0:g,b=$$(typeof v!="number"?v:O$(v,Gp)),w=h===Vu?I8:Vu,x=e.rects.popper,E=e.elements[y?w:h],A=uz(vl(E)?E:E.contextElement||As(e.elements.popper),c,d,i),k=Bc(e.elements.reference),_=N$({reference:k,element:x,strategy:"absolute",placement:o}),$=bb(Object.assign({},x,_)),L=h===Vu?$:k,O={top:A.top-L.top+b.top,bottom:L.bottom-A.bottom+b.bottom,left:A.left-L.left+b.left,right:L.right-A.right+b.right},P=e.modifiersData.offset;if(h===Vu&&P){var D=P[o];Object.keys(O).forEach(function(F){var U=[oa,ra].indexOf(F)>=0?1:-1,Y=[fo,ra].indexOf(F)>=0?"y":"x";O[F]+=D[Y]*U})}return O}function dz(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,a=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,u=c===void 0?_$:c,d=Fc(r),f=d?l?zT:zT.filter(function(y){return Fc(y)===d}):Gp,h=f.filter(function(y){return u.indexOf(y)>=0});h.length===0&&(h=f);var m=h.reduce(function(y,g){return y[g]=hp(e,{placement:g,boundary:o,rootBoundary:a,padding:i})[Ka(g)],y},{});return Object.keys(m).sort(function(y,g){return m[y]-m[g]})}function pz(e){if(Ka(e)===HS)return[];var t=Oh(e);return[WT(e),t,WT(t)]}function fz(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,a=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,u=n.padding,d=n.boundary,f=n.rootBoundary,h=n.altBoundary,m=n.flipVariations,y=m===void 0?!0:m,g=n.allowedAutoPlacements,v=t.options.placement,b=Ka(v),w=b===v,x=c||(w||!y?[Oh(v)]:pz(v)),E=[v].concat(x).reduce(function(re,Se){return re.concat(Ka(Se)===HS?dz(t,{placement:Se,boundary:d,rootBoundary:f,padding:u,flipVariations:y,allowedAutoPlacements:g}):Se)},[]),A=t.rects.reference,k=t.rects.popper,_=new Map,$=!0,L=E[0],O=0;O<E.length;O++){var P=E[O],D=Ka(P),F=Fc(P)===Mc,U=[fo,ra].indexOf(D)>=0,Y=U?"width":"height",V=hp(t,{placement:P,boundary:d,rootBoundary:f,altBoundary:h,padding:u}),te=U?F?oa:ho:F?ra:fo;A[Y]>k[Y]&&(te=Oh(te));var Z=Oh(te),W=[];if(a&&W.push(V[D]<=0),l&&W.push(V[te]<=0,V[Z]<=0),W.every(function(re){return re})){L=P,$=!1;break}_.set(P,W)}if($)for(var z=y?3:1,R=function(Se){var ce=E.find(function(Ce){var xe=_.get(Ce);if(xe)return xe.slice(0,Se).every(function(Ee){return Ee})});if(ce)return L=ce,"break"},M=z;M>0;M--){var ee=R(M);if(ee==="break")break}t.placement!==L&&(t.modifiersData[r]._skip=!0,t.placement=L,t.reset=!0)}}const hz={name:"flip",enabled:!0,phase:"main",fn:fz,requiresIfExists:["offset"],data:{_skip:!1}};function VT(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function GT(e){return[fo,oa,ra,ho].some(function(t){return e[t]>=0})}function mz(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,a=t.modifiersData.preventOverflow,i=hp(t,{elementContext:"reference"}),l=hp(t,{altBoundary:!0}),c=VT(i,r),u=VT(l,o,a),d=GT(c),f=GT(u);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:u,isReferenceHidden:d,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":f})}const gz={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:mz};function vz(e,t,n){var r=Ka(e),o=[ho,fo].indexOf(r)>=0?-1:1,a=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=a[0],l=a[1];return i=i||0,l=(l||0)*o,[ho,oa].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function yz(e){var t=e.state,n=e.options,r=e.name,o=n.offset,a=o===void 0?[0,0]:o,i=_$.reduce(function(d,f){return d[f]=vz(f,t.rects,a),d},{}),l=i[t.placement],c=l.x,u=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=i}const bz={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:yz};function wz(e){var t=e.state,n=e.name;t.modifiersData[n]=N$({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const Sz={name:"popperOffsets",enabled:!0,phase:"read",fn:wz,data:{}};function xz(e){return e==="x"?"y":"x"}function Cz(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,a=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,u=n.rootBoundary,d=n.altBoundary,f=n.padding,h=n.tether,m=h===void 0?!0:h,y=n.tetherOffset,g=y===void 0?0:y,v=hp(t,{boundary:c,rootBoundary:u,padding:f,altBoundary:d}),b=Ka(t.placement),w=Fc(t.placement),x=!w,E=qS(b),A=xz(E),k=t.modifiersData.popperOffsets,_=t.rects.reference,$=t.rects.popper,L=typeof g=="function"?g(Object.assign({},t.rects,{placement:t.placement})):g,O=typeof L=="number"?{mainAxis:L,altAxis:L}:Object.assign({mainAxis:0,altAxis:0},L),P=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(k){if(a){var F,U=E==="y"?fo:ho,Y=E==="y"?ra:oa,V=E==="y"?"height":"width",te=k[E],Z=te+v[U],W=te-v[Y],z=m?-$[V]/2:0,R=w===Mc?_[V]:$[V],M=w===Mc?-$[V]:-_[V],ee=t.elements.arrow,re=m&&ee?GS(ee):{width:0,height:0},Se=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:I$(),ce=Se[U],Ce=Se[Y],xe=Ld(0,_[V],re[V]),Ee=x?_[V]/2-z-xe-ce-O.mainAxis:R-xe-ce-O.mainAxis,tt=x?-_[V]/2+z+xe+Ce+O.mainAxis:M+xe+Ce+O.mainAxis,me=t.elements.arrow&&qp(t.elements.arrow),Ge=me?E==="y"?me.clientTop||0:me.clientLeft||0:0,qe=(F=P==null?void 0:P[E])!=null?F:0,Be=te+Ee-qe-Ge,he=te+tt-qe,Et=Ld(m?xm(Z,Be):Z,te,m?sl(W,he):W);k[E]=Et,D[E]=Et-te}if(l){var Ke,ct=E==="x"?fo:ho,Rt=E==="x"?ra:oa,dt=k[A],rt=A==="y"?"height":"width",Nt=dt+v[ct],xt=dt-v[Rt],pe=[fo,ho].indexOf(b)!==-1,Te=(Ke=P==null?void 0:P[A])!=null?Ke:0,Xe=pe?Nt:dt-_[rt]-$[rt]-Te+O.altAxis,De=pe?dt+_[rt]+$[rt]-Te-O.altAxis:xt,q=m&&pe?q8(Xe,dt,De):Ld(m?Xe:Nt,dt,m?De:xt);k[A]=q,D[A]=q-dt}t.modifiersData[r]=D}}const Ez={name:"preventOverflow",enabled:!0,phase:"main",fn:Cz,requiresIfExists:["offset"]};function Tz(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function kz(e){return e===la(e)||!Xo(e)?KS(e):Tz(e)}function Az(e){var t=e.getBoundingClientRect(),n=Dc(t.width)/e.offsetWidth||1,r=Dc(t.height)/e.offsetHeight||1;return n!==1||r!==1}function _z(e,t,n){n===void 0&&(n=!1);var r=Xo(t),o=Xo(t)&&Az(t),a=As(t),i=Bc(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((Qa(t)!=="body"||XS(a))&&(l=kz(t)),Xo(t)?(c=Bc(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):a&&(c.x=YS(a))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function Rz(e){var t=new Map,n=new Set,r=[];e.forEach(function(a){t.set(a.name,a)});function o(a){n.add(a.name);var i=[].concat(a.requires||[],a.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(a)}return e.forEach(function(a){n.has(a.name)||o(a)}),r}function Pz(e){var t=Rz(e);return j8.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function Iz(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function $z(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qT={placement:"bottom",modifiers:[],strategy:"absolute"};function KT(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(r){return!(r&&typeof r.getBoundingClientRect=="function")})}function Oz(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,r=n===void 0?[]:n,o=t.defaultOptions,a=o===void 0?qT:o;return function(l,c,u){u===void 0&&(u=a);var d={placement:"bottom",orderedModifiers:[],options:Object.assign({},qT,a),modifiersData:{},elements:{reference:l,popper:c},attributes:{},styles:{}},f=[],h=!1,m={state:d,setOptions:function(b){var w=typeof b=="function"?b(d.options):b;g(),d.options=Object.assign({},a,d.options,w),d.scrollParents={reference:vl(l)?Nd(l):l.contextElement?Nd(l.contextElement):[],popper:Nd(c)};var x=Pz($z([].concat(r,d.options.modifiers)));return d.orderedModifiers=x.filter(function(E){return E.enabled}),y(),m.update()},forceUpdate:function(){if(!h){var b=d.elements,w=b.reference,x=b.popper;if(KT(w,x)){d.rects={reference:_z(w,qp(x),d.options.strategy==="fixed"),popper:GS(x)},d.reset=!1,d.placement=d.options.placement,d.orderedModifiers.forEach(function(O){return d.modifiersData[O.name]=Object.assign({},O.data)});for(var E=0;E<d.orderedModifiers.length;E++){if(d.reset===!0){d.reset=!1,E=-1;continue}var A=d.orderedModifiers[E],k=A.fn,_=A.options,$=_===void 0?{}:_,L=A.name;typeof k=="function"&&(d=k({state:d,options:$,name:L,instance:m})||d)}}}},update:Iz(function(){return new Promise(function(v){m.forceUpdate(),v(d)})}),destroy:function(){g(),h=!0}};if(!KT(l,c))return m;m.setOptions(u).then(function(v){!h&&u.onFirstUpdate&&u.onFirstUpdate(v)});function y(){d.orderedModifiers.forEach(function(v){var b=v.name,w=v.options,x=w===void 0?{}:w,E=v.effect;if(typeof E=="function"){var A=E({state:d,name:b,instance:m,options:x}),k=function(){};f.push(A||k)}})}function g(){f.forEach(function(v){return v()}),f=[]}return m}}var Lz=[rz,Sz,tz,H8,bz,hz,Ez,J8,gz],Nz=Oz({defaultModifiers:Lz});function Mz(e){return typeof e=="function"?e():e}const Dz=p.forwardRef(function(t,n){const{children:r,container:o,disablePortal:a=!1}=t,[i,l]=p.useState(null),c=Sn(p.isValidElement(r)?r.ref:null,n);if($o(()=>{a||l(Mz(o)||document.body)},[o,a]),$o(()=>{if(i&&!a)return cp(n,i),()=>{cp(n,null)}},[n,i,a]),a){if(p.isValidElement(r)){const u={ref:c};return p.cloneElement(r,u)}return s(p.Fragment,{children:r})}return s(p.Fragment,{children:i&&Gd.createPortal(r,i)})}),JS=Dz;function Bz(e){return je("MuiPopperUnstyled",e)}Ue("MuiPopperUnstyled",["root"]);const Fz=["anchorEl","children","component","direction","disablePortal","modifiers","open","ownerState","placement","popperOptions","popperRef","slotProps","slots","TransitionProps"],zz=["anchorEl","children","container","direction","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","style","transition","slotProps","slots"];function jz(e,t){if(t==="ltr")return e;switch(e){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return e}}function wb(e){return typeof e=="function"?e():e}function Uz(e){return e.nodeType!==void 0}const Wz=()=>He({root:["root"]},Bz,{}),Hz={},Vz=p.forwardRef(function(t,n){var r;const{anchorEl:o,children:a,component:i,direction:l,disablePortal:c,modifiers:u,open:d,ownerState:f,placement:h,popperOptions:m,popperRef:y,slotProps:g={},slots:v={},TransitionProps:b}=t,w=Vp(t,Fz),x=p.useRef(null),E=Sn(x,n),A=p.useRef(null),k=Sn(A,y),_=p.useRef(k);$o(()=>{_.current=k},[k]),p.useImperativeHandle(y,()=>A.current,[]);const $=jz(h,l),[L,O]=p.useState($),[P,D]=p.useState(wb(o));p.useEffect(()=>{A.current&&A.current.forceUpdate()}),p.useEffect(()=>{o&&D(wb(o))},[o]),$o(()=>{if(!P||!d)return;const te=z=>{O(z.placement)};let Z=[{name:"preventOverflow",options:{altBoundary:c}},{name:"flip",options:{altBoundary:c}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:z})=>{te(z)}}];u!=null&&(Z=Z.concat(u)),m&&m.modifiers!=null&&(Z=Z.concat(m.modifiers));const W=Nz(P,x.current,sn({placement:$},m,{modifiers:Z}));return _.current(W),()=>{W.destroy(),_.current(null)}},[P,c,u,d,m,$]);const F={placement:L};b!==null&&(F.TransitionProps=b);const U=Wz(),Y=(r=i??v.root)!=null?r:"div",V=ga({elementType:Y,externalSlotProps:g.root,externalForwardedProps:w,additionalProps:{role:"tooltip",ref:E},ownerState:sn({},t,f),className:U.root});return s(Y,sn({},V,{children:typeof a=="function"?a(F):a}))}),Gz=p.forwardRef(function(t,n){const{anchorEl:r,children:o,container:a,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:u,open:d,placement:f="bottom",popperOptions:h=Hz,popperRef:m,style:y,transition:g=!1,slotProps:v={},slots:b={}}=t,w=Vp(t,zz),[x,E]=p.useState(!0),A=()=>{E(!1)},k=()=>{E(!0)};if(!c&&!d&&(!g||x))return null;let _;if(a)_=a;else if(r){const O=wb(r);_=O&&Uz(O)?Fn(O).body:Fn(null).body}const $=!d&&c&&(!g||x)?"none":void 0,L=g?{in:d,onEnter:A,onExited:k}:void 0;return s(JS,{disablePortal:l,container:_,children:s(Vz,sn({anchorEl:r,direction:i,disablePortal:l,modifiers:u,ref:n,open:g?!x:d,placement:f,popperOptions:h,popperRef:m,slotProps:v,slots:b},w,{style:sn({position:"fixed",top:0,left:0,display:$},y),TransitionProps:L,children:o}))})}),qz=Gz;function Kz(e){const t=Fn(e);return t.body===e?ta(e).innerWidth>t.documentElement.clientWidth:e.scrollHeight>e.clientHeight}function Md(e,t){t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function YT(e){return parseInt(ta(e).getComputedStyle(e).paddingRight,10)||0}function Yz(e){const n=["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].indexOf(e.tagName)!==-1,r=e.tagName==="INPUT"&&e.getAttribute("type")==="hidden";return n||r}function XT(e,t,n,r,o){const a=[t,n,...r];[].forEach.call(e.children,i=>{const l=a.indexOf(i)===-1,c=!Yz(i);l&&c&&Md(i,o)})}function c1(e,t){let n=-1;return e.some((r,o)=>t(r)?(n=o,!0):!1),n}function Xz(e,t){const n=[],r=e.container;if(!t.disableScrollLock){if(Kz(r)){const i=q5(Fn(r));n.push({value:r.style.paddingRight,property:"padding-right",el:r}),r.style.paddingRight=`${YT(r)+i}px`;const l=Fn(r).querySelectorAll(".mui-fixed");[].forEach.call(l,c=>{n.push({value:c.style.paddingRight,property:"padding-right",el:c}),c.style.paddingRight=`${YT(c)+i}px`})}let a;if(r.parentNode instanceof DocumentFragment)a=Fn(r).body;else{const i=r.parentElement,l=ta(r);a=(i==null?void 0:i.nodeName)==="HTML"&&l.getComputedStyle(i).overflowY==="scroll"?i:r}n.push({value:a.style.overflow,property:"overflow",el:a},{value:a.style.overflowX,property:"overflow-x",el:a},{value:a.style.overflowY,property:"overflow-y",el:a}),a.style.overflow="hidden"}return()=>{n.forEach(({value:a,el:i,property:l})=>{a?i.style.setProperty(l,a):i.style.removeProperty(l)})}}function Jz(e){const t=[];return[].forEach.call(e.children,n=>{n.getAttribute("aria-hidden")==="true"&&t.push(n)}),t}class Qz{constructor(){this.containers=void 0,this.modals=void 0,this.modals=[],this.containers=[]}add(t,n){let r=this.modals.indexOf(t);if(r!==-1)return r;r=this.modals.length,this.modals.push(t),t.modalRef&&Md(t.modalRef,!1);const o=Jz(n);XT(n,t.mount,t.modalRef,o,!0);const a=c1(this.containers,i=>i.container===n);return a!==-1?(this.containers[a].modals.push(t),r):(this.containers.push({modals:[t],container:n,restore:null,hiddenSiblings:o}),r)}mount(t,n){const r=c1(this.containers,a=>a.modals.indexOf(t)!==-1),o=this.containers[r];o.restore||(o.restore=Xz(o,n))}remove(t,n=!0){const r=this.modals.indexOf(t);if(r===-1)return r;const o=c1(this.containers,i=>i.modals.indexOf(t)!==-1),a=this.containers[o];if(a.modals.splice(a.modals.indexOf(t),1),this.modals.splice(r,1),a.modals.length===0)a.restore&&a.restore(),t.modalRef&&Md(t.modalRef,n),XT(a.container,t.mount,t.modalRef,a.hiddenSiblings,!1),this.containers.splice(o,1);else{const i=a.modals[a.modals.length-1];i.modalRef&&Md(i.modalRef,!1)}return r}isTopModal(t){return this.modals.length>0&&this.modals[this.modals.length-1]===t}}function Zz(e){return je("MuiModal",e)}Ue("MuiModal",["root","hidden"]);const ej=["children","classes","closeAfterTransition","component","container","disableAutoFocus","disableEnforceFocus","disableEscapeKeyDown","disablePortal","disableRestoreFocus","disableScrollLock","hideBackdrop","keepMounted","manager","onBackdropClick","onClose","onKeyDown","open","onTransitionEnter","onTransitionExited","slotProps","slots"],tj=e=>{const{open:t,exited:n,classes:r}=e;return He({root:["root",!t&&n&&"hidden"],backdrop:["backdrop"]},Zz,r)};function nj(e){return typeof e=="function"?e():e}function rj(e){return e?e.props.hasOwnProperty("in"):!1}const oj=new Qz,aj=p.forwardRef(function(t,n){var r,o;const{children:a,classes:i,closeAfterTransition:l=!1,component:c,container:u,disableAutoFocus:d=!1,disableEnforceFocus:f=!1,disableEscapeKeyDown:h=!1,disablePortal:m=!1,disableRestoreFocus:y=!1,disableScrollLock:g=!1,hideBackdrop:v=!1,keepMounted:b=!1,manager:w=oj,onBackdropClick:x,onClose:E,onKeyDown:A,open:k,onTransitionEnter:_,onTransitionExited:$,slotProps:L={},slots:O={}}=t,P=Vp(t,ej),[D,F]=p.useState(!k),U=p.useRef({}),Y=p.useRef(null),V=p.useRef(null),te=Sn(V,n),Z=rj(a),W=(r=t["aria-hidden"])!=null?r:!0,z=()=>Fn(Y.current),R=()=>(U.current.modalRef=V.current,U.current.mountNode=Y.current,U.current),M=()=>{w.mount(R(),{disableScrollLock:g}),V.current&&(V.current.scrollTop=0)},ee=gr(()=>{const ct=nj(u)||z().body;w.add(R(),ct),V.current&&M()}),re=p.useCallback(()=>w.isTopModal(R()),[w]),Se=gr(ct=>{Y.current=ct,!(!ct||!V.current)&&(k&&re()?M():Md(V.current,W))}),ce=p.useCallback(()=>{w.remove(R(),W)},[w,W]);p.useEffect(()=>()=>{ce()},[ce]),p.useEffect(()=>{k?ee():(!Z||!l)&&ce()},[k,ce,Z,l,ee]);const Ce=sn({},t,{classes:i,closeAfterTransition:l,disableAutoFocus:d,disableEnforceFocus:f,disableEscapeKeyDown:h,disablePortal:m,disableRestoreFocus:y,disableScrollLock:g,exited:D,hideBackdrop:v,keepMounted:b}),xe=tj(Ce),Ee=()=>{F(!1),_&&_()},tt=()=>{F(!0),$&&$(),l&&ce()},me=ct=>{ct.target===ct.currentTarget&&(x&&x(ct),E&&E(ct,"backdropClick"))},Ge=ct=>{A&&A(ct),!(ct.key!=="Escape"||!re())&&(h||(ct.stopPropagation(),E&&E(ct,"escapeKeyDown")))},qe={};a.props.tabIndex===void 0&&(qe.tabIndex="-1"),Z&&(qe.onEnter=ym(Ee,a.props.onEnter),qe.onExited=ym(tt,a.props.onExited));const Be=(o=c??O.root)!=null?o:"div",he=ga({elementType:Be,externalSlotProps:L.root,externalForwardedProps:P,additionalProps:{ref:te,role:"presentation",onKeyDown:Ge},className:xe.root,ownerState:Ce}),Et=O.backdrop,Ke=ga({elementType:Et,externalSlotProps:L.backdrop,additionalProps:{"aria-hidden":!0,onClick:me,open:k},className:xe.backdrop,ownerState:Ce});return!b&&!k&&(!Z||D)?null:s(JS,{ref:Se,container:u,disablePortal:m,children:T(Be,sn({},he,{children:[!v&&Et?s(Et,sn({},Ke)):null,s(R8,{disableEnforceFocus:f,disableAutoFocus:d,disableRestoreFocus:y,isEnabled:re,open:k,children:p.cloneElement(a,qe)})]}))})}),ij=aj,sj=2;function M$(e,t){return e-t}function Gu(e,t,n){return e==null?t:Math.min(Math.max(t,e),n)}function JT(e,t){var n;const{index:r}=(n=e.reduce((o,a,i)=>{const l=Math.abs(t-a);return o===null||l<o.distance||l===o.distance?{distance:l,index:i}:o},null))!=null?n:{};return r}function Ff(e,t){if(t.current!==void 0&&e.changedTouches){const n=e;for(let r=0;r<n.changedTouches.length;r+=1){const o=n.changedTouches[r];if(o.identifier===t.current)return{x:o.clientX,y:o.clientY}}return!1}return{x:e.clientX,y:e.clientY}}function QT(e,t,n){return(e-t)*100/(n-t)}function lj(e,t,n){return(n-t)*e+t}function cj(e){if(Math.abs(e)<1){const n=e.toExponential().split("e-"),r=n[0].split(".")[1];return(r?r.length:0)+parseInt(n[1],10)}const t=e.toString().split(".")[1];return t?t.length:0}function uj(e,t,n){const r=Math.round((e-n)/t)*t+n;return Number(r.toFixed(cj(t)))}function ZT({values:e,newValue:t,index:n}){const r=e.slice();return r[n]=t,r.sort(M$)}function zf({sliderRef:e,activeIndex:t,setActive:n}){var r,o;const a=Fn(e.current);if(!((r=e.current)!=null&&r.contains(a.activeElement))||Number(a==null||(o=a.activeElement)==null?void 0:o.getAttribute("data-index"))!==t){var i;(i=e.current)==null||i.querySelector(`[type="range"][data-index="${t}"]`).focus()}n&&n(t)}const dj={horizontal:{offset:e=>({left:`${e}%`}),leap:e=>({width:`${e}%`})},"horizontal-reverse":{offset:e=>({right:`${e}%`}),leap:e=>({width:`${e}%`})},vertical:{offset:e=>({bottom:`${e}%`}),leap:e=>({height:`${e}%`})}},pj=e=>e;let jf;function u1(){return jf===void 0&&(typeof CSS<"u"&&typeof CSS.supports=="function"?jf=CSS.supports("touch-action","none"):jf=!0),jf}function fj(e){const{"aria-labelledby":t,defaultValue:n,disabled:r=!1,disableSwap:o=!1,isRtl:a=!1,marks:i=!1,max:l=100,min:c=0,name:u,onChange:d,onChangeCommitted:f,orientation:h="horizontal",ref:m,scale:y=pj,step:g=1,tabIndex:v,value:b}=e,w=p.useRef(),[x,E]=p.useState(-1),[A,k]=p.useState(-1),[_,$]=p.useState(!1),L=p.useRef(0),[O,P]=Sa({controlled:b,default:n??c,name:"Slider"}),D=d&&((pe,Te,Xe)=>{const De=pe.nativeEvent||pe,q=new De.constructor(De.type,De);Object.defineProperty(q,"target",{writable:!0,value:{value:Te,name:u}}),d(q,Te,Xe)}),F=Array.isArray(O);let U=F?O.slice().sort(M$):[O];U=U.map(pe=>Gu(pe,c,l));const Y=i===!0&&g!==null?[...Array(Math.floor((l-c)/g)+1)].map((pe,Te)=>({value:c+g*Te})):i||[],V=Y.map(pe=>pe.value),{isFocusVisibleRef:te,onBlur:Z,onFocus:W,ref:z}=jp(),[R,M]=p.useState(-1),ee=p.useRef(),re=Sn(z,ee),Se=Sn(m,re),ce=pe=>Te=>{var Xe;const De=Number(Te.currentTarget.getAttribute("data-index"));W(Te),te.current===!0&&M(De),k(De),pe==null||(Xe=pe.onFocus)==null||Xe.call(pe,Te)},Ce=pe=>Te=>{var Xe;Z(Te),te.current===!1&&M(-1),k(-1),pe==null||(Xe=pe.onBlur)==null||Xe.call(pe,Te)};$o(()=>{if(r&&ee.current.contains(document.activeElement)){var pe;(pe=document.activeElement)==null||pe.blur()}},[r]),r&&x!==-1&&E(-1),r&&R!==-1&&M(-1);const xe=pe=>Te=>{var Xe;(Xe=pe.onChange)==null||Xe.call(pe,Te);const De=Number(Te.currentTarget.getAttribute("data-index")),q=U[De],K=V.indexOf(q);let se=Te.target.valueAsNumber;if(Y&&g==null&&(se=se<q?V[K-1]:V[K+1]),se=Gu(se,c,l),Y&&g==null){const be=V.indexOf(U[De]);se=se<U[De]?V[be-1]:V[be+1]}if(F){o&&(se=Gu(se,U[De-1]||-1/0,U[De+1]||1/0));const be=se;se=ZT({values:U,newValue:se,index:De});let Ae=De;o||(Ae=se.indexOf(be)),zf({sliderRef:ee,activeIndex:Ae})}P(se),M(De),D&&D(Te,se,De),f&&f(Te,se)},Ee=p.useRef();let tt=h;a&&h==="horizontal"&&(tt+="-reverse");const me=({finger:pe,move:Te=!1})=>{const{current:Xe}=ee,{width:De,height:q,bottom:K,left:se}=Xe.getBoundingClientRect();let be;tt.indexOf("vertical")===0?be=(K-pe.y)/q:be=(pe.x-se)/De,tt.indexOf("-reverse")!==-1&&(be=1-be);let Ae;if(Ae=lj(be,c,l),g)Ae=uj(Ae,g,c);else{const et=JT(V,Ae);Ae=V[et]}Ae=Gu(Ae,c,l);let mt=0;if(F){Te?mt=Ee.current:mt=JT(U,Ae),o&&(Ae=Gu(Ae,U[mt-1]||-1/0,U[mt+1]||1/0));const et=Ae;Ae=ZT({values:U,newValue:Ae,index:mt}),o&&Te||(mt=Ae.indexOf(et),Ee.current=mt)}return{newValue:Ae,activeIndex:mt}},Ge=gr(pe=>{const Te=Ff(pe,w);if(!Te)return;if(L.current+=1,pe.type==="mousemove"&&pe.buttons===0){qe(pe);return}const{newValue:Xe,activeIndex:De}=me({finger:Te,move:!0});zf({sliderRef:ee,activeIndex:De,setActive:E}),P(Xe),!_&&L.current>sj&&$(!0),D&&Xe!==O&&D(pe,Xe,De)}),qe=gr(pe=>{const Te=Ff(pe,w);if($(!1),!Te)return;const{newValue:Xe}=me({finger:Te,move:!0});E(-1),pe.type==="touchend"&&k(-1),f&&f(pe,Xe),w.current=void 0,he()}),Be=gr(pe=>{if(r)return;u1()||pe.preventDefault();const Te=pe.changedTouches[0];Te!=null&&(w.current=Te.identifier);const Xe=Ff(pe,w);if(Xe!==!1){const{newValue:q,activeIndex:K}=me({finger:Xe});zf({sliderRef:ee,activeIndex:K,setActive:E}),P(q),D&&D(pe,q,K)}L.current=0;const De=Fn(ee.current);De.addEventListener("touchmove",Ge),De.addEventListener("touchend",qe)}),he=p.useCallback(()=>{const pe=Fn(ee.current);pe.removeEventListener("mousemove",Ge),pe.removeEventListener("mouseup",qe),pe.removeEventListener("touchmove",Ge),pe.removeEventListener("touchend",qe)},[qe,Ge]);p.useEffect(()=>{const{current:pe}=ee;return pe.addEventListener("touchstart",Be,{passive:u1()}),()=>{pe.removeEventListener("touchstart",Be,{passive:u1()}),he()}},[he,Be]),p.useEffect(()=>{r&&he()},[r,he]);const Et=pe=>Te=>{var Xe;if((Xe=pe.onMouseDown)==null||Xe.call(pe,Te),r||Te.defaultPrevented||Te.button!==0)return;Te.preventDefault();const De=Ff(Te,w);if(De!==!1){const{newValue:K,activeIndex:se}=me({finger:De});zf({sliderRef:ee,activeIndex:se,setActive:E}),P(K),D&&D(Te,K,se)}L.current=0;const q=Fn(ee.current);q.addEventListener("mousemove",Ge),q.addEventListener("mouseup",qe)},Ke=QT(F?U[0]:c,c,l),ct=QT(U[U.length-1],c,l)-Ke,Rt=(pe={})=>{const Te={onMouseDown:Et(pe||{})},Xe=sn({},pe,Te);return sn({ref:Se},Xe)},dt=pe=>Te=>{var Xe;(Xe=pe.onMouseOver)==null||Xe.call(pe,Te);const De=Number(Te.currentTarget.getAttribute("data-index"));k(De)},rt=pe=>Te=>{var Xe;(Xe=pe.onMouseLeave)==null||Xe.call(pe,Te),k(-1)};return{active:x,axis:tt,axisProps:dj,dragging:_,focusedThumbIndex:R,getHiddenInputProps:(pe={})=>{var Te;const Xe={onChange:xe(pe||{}),onFocus:ce(pe||{}),onBlur:Ce(pe||{})},De=sn({},pe,Xe);return sn({tabIndex:v,"aria-labelledby":t,"aria-orientation":h,"aria-valuemax":y(l),"aria-valuemin":y(c),name:u,type:"range",min:e.min,max:e.max,step:(Te=e.step)!=null?Te:void 0,disabled:r},De,{style:sn({},uB,{direction:a?"rtl":"ltr",width:"100%",height:"100%"})})},getRootProps:Rt,getThumbProps:(pe={})=>{const Te={onMouseOver:dt(pe||{}),onMouseLeave:rt(pe||{})};return sn({},pe,Te)},marks:Y,open:A,range:F,trackLeap:ct,trackOffset:Ke,values:U}}const hj=["onChange","maxRows","minRows","style","value"];function Uf(e,t){return parseInt(e[t],10)||0}const mj={shadow:{visibility:"hidden",position:"absolute",overflow:"hidden",height:0,top:0,left:0,transform:"translateZ(0)"}};function ek(e){return e==null||Object.keys(e).length===0}const gj=p.forwardRef(function(t,n){const{onChange:r,maxRows:o,minRows:a=1,style:i,value:l}=t,c=Vp(t,hj),{current:u}=p.useRef(l!=null),d=p.useRef(null),f=Sn(n,d),h=p.useRef(null),m=p.useRef(0),[y,g]=p.useState({}),v=p.useCallback(()=>{const A=d.current,_=ta(A).getComputedStyle(A);if(_.width==="0px")return{};const $=h.current;$.style.width=_.width,$.value=A.value||t.placeholder||"x",$.value.slice(-1)===`
|
|
91
|
+
`&&($.value+=" ");const L=_["box-sizing"],O=Uf(_,"padding-bottom")+Uf(_,"padding-top"),P=Uf(_,"border-bottom-width")+Uf(_,"border-top-width"),D=$.scrollHeight;$.value="x";const F=$.scrollHeight;let U=D;a&&(U=Math.max(Number(a)*F,U)),o&&(U=Math.min(Number(o)*F,U)),U=Math.max(U,F);const Y=U+(L==="border-box"?O+P:0),V=Math.abs(U-D)<=1;return{outerHeightStyle:Y,overflow:V}},[o,a,t.placeholder]),b=(A,k)=>{const{outerHeightStyle:_,overflow:$}=k;return m.current<20&&(_>0&&Math.abs((A.outerHeightStyle||0)-_)>1||A.overflow!==$)?(m.current+=1,{overflow:$,outerHeightStyle:_}):A},w=p.useCallback(()=>{const A=v();ek(A)||g(k=>b(k,A))},[v]),x=()=>{const A=v();ek(A)||Gd.flushSync(()=>{g(k=>b(k,A))})};p.useEffect(()=>{const A=ml(()=>{m.current=0,d.current&&x()}),k=ta(d.current);k.addEventListener("resize",A);let _;return typeof ResizeObserver<"u"&&(_=new ResizeObserver(A),_.observe(d.current)),()=>{A.clear(),k.removeEventListener("resize",A),_&&_.disconnect()}}),$o(()=>{w()}),p.useEffect(()=>{m.current=0},[l]);const E=A=>{m.current=0,u||w(),r&&r(A)};return T(p.Fragment,{children:[s("textarea",sn({value:l,onChange:E,ref:f,rows:a,style:sn({height:y.outerHeightStyle,overflow:y.overflow?"hidden":null},i)},c)),s("textarea",{"aria-hidden":!0,className:t.className,readOnly:!0,ref:h,tabIndex:-1,style:sn({},mj.shadow,i,{padding:0})})]})}),vj=gj;function yj(e){return je("MuiSvgIcon",e)}Ue("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const bj=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],wj=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${ie(t)}`,`fontSize${ie(n)}`]};return He(o,yj,r)},Sj=C("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${ie(n.color)}`],t[`fontSize${ie(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,a,i,l,c,u,d,f,h,m,y,g,v,b,w;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(a=o.duration)==null?void 0:a.shorter}),fontSize:{inherit:"inherit",small:((i=e.typography)==null||(l=i.pxToRem)==null?void 0:l.call(i,20))||"1.25rem",medium:((c=e.typography)==null||(u=c.pxToRem)==null?void 0:u.call(c,24))||"1.5rem",large:((d=e.typography)==null||(f=d.pxToRem)==null?void 0:f.call(d,35))||"2.1875rem"}[t.fontSize],color:(h=(m=(e.vars||e).palette)==null||(y=m[t.color])==null?void 0:y.main)!=null?h:{action:(g=(e.vars||e).palette)==null||(v=g.action)==null?void 0:v.active,disabled:(b=(e.vars||e).palette)==null||(w=b.action)==null?void 0:w.disabled,inherit:void 0}[t.color]}}),D$=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiSvgIcon"}),{children:o,className:a,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:u,inheritViewBox:d=!1,titleAccess:f,viewBox:h="0 0 24 24"}=r,m=$e(r,bj),y=I({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:d,viewBox:h}),g={};d||(g.viewBox=h);const v=wj(y);return T(Sj,I({as:l,className:ve(v.root,a),focusable:"false",color:u,"aria-hidden":f?void 0:!0,role:f?"img":void 0,ref:n},g,m,{ownerState:y,children:[o,f?s("title",{children:f}):null]}))});D$.muiName="SvgIcon";const Sb=D$;function Ye(e,t){function n(r,o){return s(Sb,I({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return n.muiName=Sb.muiName,p.memo(p.forwardRef(n))}const xj={configure:e=>{kS.configure(e)}},Cj=Object.freeze(Object.defineProperty({__proto__:null,capitalize:ie,createChainedFunction:ym,createSvgIcon:Ye,debounce:ml,deprecatedPropType:X9,isMuiElement:Id,ownerDocument:Fn,ownerWindow:ta,requirePropFactory:J9,setRef:cp,unstable_ClassNameGenerator:xj,unstable_useEnhancedEffect:$o,unstable_useId:nu,unsupportedProp:eB,useControlled:Sa,useEventCallback:gr,useForkRef:Sn,useIsFocusVisible:jp},Symbol.toStringTag,{value:"Module"}));function B$(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,a;for(a=0;a<r.length;a++)o=r[a],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function xb(e,t){return xb=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},xb(e,t)}function QS(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,xb(e,t)}const tk={disabled:!1},Cm=jt.createContext(null);var Ej=function(t){return t.scrollTop},md="unmounted",Us="exited",Ws="entering",Ql="entered",Cb="exiting",Ri=function(e){QS(t,e);function t(r,o){var a;a=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return a.appearStatus=null,r.in?l?(c=Us,a.appearStatus=Ws):c=Ql:r.unmountOnExit||r.mountOnEnter?c=md:c=Us,a.state={status:c},a.nextCallback=null,a}t.getDerivedStateFromProps=function(o,a){var i=o.in;return i&&a.status===md?{status:Us}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var a=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==Ws&&i!==Ql&&(a=Ws):(i===Ws||i===Ql)&&(a=Cb)}this.updateStatus(!1,a)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,a,i,l;return a=i=l=o,o!=null&&typeof o!="number"&&(a=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:a,enter:i,appear:l}},n.updateStatus=function(o,a){if(o===void 0&&(o=!1),a!==null)if(this.cancelNextCallback(),a===Ws){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:fd.findDOMNode(this);i&&Ej(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===Us&&this.setState({status:md})},n.performEnter=function(o){var a=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[fd.findDOMNode(this),l],u=c[0],d=c[1],f=this.getTimeouts(),h=l?f.appear:f.enter;if(!o&&!i||tk.disabled){this.safeSetState({status:Ql},function(){a.props.onEntered(u)});return}this.props.onEnter(u,d),this.safeSetState({status:Ws},function(){a.props.onEntering(u,d),a.onTransitionEnd(h,function(){a.safeSetState({status:Ql},function(){a.props.onEntered(u,d)})})})},n.performExit=function(){var o=this,a=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:fd.findDOMNode(this);if(!a||tk.disabled){this.safeSetState({status:Us},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:Cb},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:Us},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,a){a=this.setNextCallback(a),this.setState(o,a)},n.setNextCallback=function(o){var a=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,a.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,a){this.setNextCallback(a);var i=this.props.nodeRef?this.props.nodeRef.current:fd.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],u=c[0],d=c[1];this.props.addEndListener(u,d)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===md)return null;var a=this.props,i=a.children;a.in,a.mountOnEnter,a.unmountOnExit,a.appear,a.enter,a.exit,a.timeout,a.addEndListener,a.onEnter,a.onEntering,a.onEntered,a.onExit,a.onExiting,a.onExited,a.nodeRef;var l=B$(a,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return jt.createElement(Cm.Provider,{value:null},typeof i=="function"?i(o,l):jt.cloneElement(jt.Children.only(i),l))},t}(jt.Component);Ri.contextType=Cm;Ri.propTypes={};function Hl(){}Ri.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:Hl,onEntering:Hl,onEntered:Hl,onExit:Hl,onExiting:Hl,onExited:Hl};Ri.UNMOUNTED=md;Ri.EXITED=Us;Ri.ENTERING=Ws;Ri.ENTERED=Ql;Ri.EXITING=Cb;const Xg=Ri;function Tj(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ZS(e,t){var n=function(a){return t&&p.isValidElement(a)?t(a):a},r=Object.create(null);return e&&p.Children.map(e,function(o){return o}).forEach(function(o){r[o.key]=n(o)}),r}function kj(e,t){e=e||{},t=t||{};function n(d){return d in t?t[d]:e[d]}var r=Object.create(null),o=[];for(var a in e)a in t?o.length&&(r[a]=o,o=[]):o.push(a);var i,l={};for(var c in t){if(r[c])for(i=0;i<r[c].length;i++){var u=r[c][i];l[r[c][i]]=n(u)}l[c]=n(c)}for(i=0;i<o.length;i++)l[o[i]]=n(o[i]);return l}function rl(e,t,n){return n[t]!=null?n[t]:e.props[t]}function Aj(e,t){return ZS(e.children,function(n){return p.cloneElement(n,{onExited:t.bind(null,n),in:!0,appear:rl(n,"appear",e),enter:rl(n,"enter",e),exit:rl(n,"exit",e)})})}function _j(e,t,n){var r=ZS(e.children),o=kj(t,r);return Object.keys(o).forEach(function(a){var i=o[a];if(p.isValidElement(i)){var l=a in t,c=a in r,u=t[a],d=p.isValidElement(u)&&!u.props.in;c&&(!l||d)?o[a]=p.cloneElement(i,{onExited:n.bind(null,i),in:!0,exit:rl(i,"exit",e),enter:rl(i,"enter",e)}):!c&&l&&!d?o[a]=p.cloneElement(i,{in:!1}):c&&l&&p.isValidElement(u)&&(o[a]=p.cloneElement(i,{onExited:n.bind(null,i),in:u.props.in,exit:rl(i,"exit",e),enter:rl(i,"enter",e)}))}}),o}var Rj=Object.values||function(e){return Object.keys(e).map(function(t){return e[t]})},Pj={component:"div",childFactory:function(t){return t}},ex=function(e){QS(t,e);function t(r,o){var a;a=e.call(this,r,o)||this;var i=a.handleExited.bind(Tj(a));return a.state={contextValue:{isMounting:!0},handleExited:i,firstRender:!0},a}var n=t.prototype;return n.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},n.componentWillUnmount=function(){this.mounted=!1},t.getDerivedStateFromProps=function(o,a){var i=a.children,l=a.handleExited,c=a.firstRender;return{children:c?Aj(o,l):_j(o,i,l),firstRender:!1}},n.handleExited=function(o,a){var i=ZS(this.props.children);o.key in i||(o.props.onExited&&o.props.onExited(a),this.mounted&&this.setState(function(l){var c=bm({},l.children);return delete c[o.key],{children:c}}))},n.render=function(){var o=this.props,a=o.component,i=o.childFactory,l=B$(o,["component","childFactory"]),c=this.state.contextValue,u=Rj(this.state.children).map(i);return delete l.appear,delete l.enter,delete l.exit,a===null?jt.createElement(Cm.Provider,{value:c},u):jt.createElement(Cm.Provider,{value:c},jt.createElement(a,l,u))},t}(jt.Component);ex.propTypes={};ex.defaultProps=Pj;const Ij=ex,tx=e=>e.scrollTop;function ys(e,t){var n,r;const{timeout:o,easing:a,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof a=="object"?a[t.mode]:a,delay:i.transitionDelay}}function $j(e){return je("MuiCollapse",e)}Ue("MuiCollapse",["root","horizontal","vertical","entered","hidden","wrapper","wrapperInner"]);const Oj=["addEndListener","children","className","collapsedSize","component","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","orientation","style","timeout","TransitionComponent"],Lj=e=>{const{orientation:t,classes:n}=e,r={root:["root",`${t}`],entered:["entered"],hidden:["hidden"],wrapper:["wrapper",`${t}`],wrapperInner:["wrapperInner",`${t}`]};return He(r,$j,n)},Nj=C("div",{name:"MuiCollapse",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.orientation],n.state==="entered"&&t.entered,n.state==="exited"&&!n.in&&n.collapsedSize==="0px"&&t.hidden]}})(({theme:e,ownerState:t})=>I({height:0,overflow:"hidden",transition:e.transitions.create("height")},t.orientation==="horizontal"&&{height:"auto",width:0,transition:e.transitions.create("width")},t.state==="entered"&&I({height:"auto",overflow:"visible"},t.orientation==="horizontal"&&{width:"auto"}),t.state==="exited"&&!t.in&&t.collapsedSize==="0px"&&{visibility:"hidden"})),Mj=C("div",{name:"MuiCollapse",slot:"Wrapper",overridesResolver:(e,t)=>t.wrapper})(({ownerState:e})=>I({display:"flex",width:"100%"},e.orientation==="horizontal"&&{width:"auto",height:"100%"})),Dj=C("div",{name:"MuiCollapse",slot:"WrapperInner",overridesResolver:(e,t)=>t.wrapperInner})(({ownerState:e})=>I({width:"100%"},e.orientation==="horizontal"&&{width:"auto",height:"100%"})),F$=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiCollapse"}),{addEndListener:o,children:a,className:i,collapsedSize:l="0px",component:c,easing:u,in:d,onEnter:f,onEntered:h,onEntering:m,onExit:y,onExited:g,onExiting:v,orientation:b="vertical",style:w,timeout:x=T$.standard,TransitionComponent:E=Xg}=r,A=$e(r,Oj),k=I({},r,{orientation:b,collapsedSize:l}),_=Lj(k),$=on(),L=p.useRef(),O=p.useRef(null),P=p.useRef(),D=typeof l=="number"?`${l}px`:l,F=b==="horizontal",U=F?"width":"height";p.useEffect(()=>()=>{clearTimeout(L.current)},[]);const Y=p.useRef(null),V=Sn(n,Y),te=ce=>Ce=>{if(ce){const xe=Y.current;Ce===void 0?ce(xe):ce(xe,Ce)}},Z=()=>O.current?O.current[F?"clientWidth":"clientHeight"]:0,W=te((ce,Ce)=>{O.current&&F&&(O.current.style.position="absolute"),ce.style[U]=D,f&&f(ce,Ce)}),z=te((ce,Ce)=>{const xe=Z();O.current&&F&&(O.current.style.position="");const{duration:Ee,easing:tt}=ys({style:w,timeout:x,easing:u},{mode:"enter"});if(x==="auto"){const me=$.transitions.getAutoHeightDuration(xe);ce.style.transitionDuration=`${me}ms`,P.current=me}else ce.style.transitionDuration=typeof Ee=="string"?Ee:`${Ee}ms`;ce.style[U]=`${xe}px`,ce.style.transitionTimingFunction=tt,m&&m(ce,Ce)}),R=te((ce,Ce)=>{ce.style[U]="auto",h&&h(ce,Ce)}),M=te(ce=>{ce.style[U]=`${Z()}px`,y&&y(ce)}),ee=te(g),re=te(ce=>{const Ce=Z(),{duration:xe,easing:Ee}=ys({style:w,timeout:x,easing:u},{mode:"exit"});if(x==="auto"){const tt=$.transitions.getAutoHeightDuration(Ce);ce.style.transitionDuration=`${tt}ms`,P.current=tt}else ce.style.transitionDuration=typeof xe=="string"?xe:`${xe}ms`;ce.style[U]=D,ce.style.transitionTimingFunction=Ee,v&&v(ce)});return s(E,I({in:d,onEnter:W,onEntered:R,onEntering:z,onExit:M,onExited:ee,onExiting:re,addEndListener:ce=>{x==="auto"&&(L.current=setTimeout(ce,P.current||0)),o&&o(Y.current,ce)},nodeRef:Y,timeout:x==="auto"?null:x},A,{children:(ce,Ce)=>s(Nj,I({as:c,className:ve(_.root,i,{entered:_.entered,exited:!d&&D==="0px"&&_.hidden}[ce]),style:I({[F?"minWidth":"minHeight"]:D},w),ownerState:I({},k,{state:ce}),ref:V},Ce,{children:s(Mj,{ownerState:I({},k,{state:ce}),className:_.wrapper,ref:O,children:s(Dj,{ownerState:I({},k,{state:ce}),className:_.wrapperInner,children:a})})}))}))});F$.muiSupportAuto=!0;const z$=F$;function Bj(e){return je("MuiPaper",e)}Ue("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);const Fj=["className","component","elevation","square","variant"],zj=e=>{const{square:t,elevation:n,variant:r,classes:o}=e,a={root:["root",r,!t&&"rounded",r==="elevation"&&`elevation${n}`]};return He(a,Bj,o)},jj=C("div",{name:"MuiPaper",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],!n.square&&t.rounded,n.variant==="elevation"&&t[`elevation${n.elevation}`]]}})(({theme:e,ownerState:t})=>{var n;return I({backgroundColor:(e.vars||e).palette.background.paper,color:(e.vars||e).palette.text.primary,transition:e.transitions.create("box-shadow")},!t.square&&{borderRadius:e.shape.borderRadius},t.variant==="outlined"&&{border:`1px solid ${(e.vars||e).palette.divider}`},t.variant==="elevation"&&I({boxShadow:(e.vars||e).shadows[t.elevation]},!e.vars&&e.palette.mode==="dark"&&{backgroundImage:`linear-gradient(${Ot("#fff",NT(t.elevation))}, ${Ot("#fff",NT(t.elevation))})`},e.vars&&{backgroundImage:(n=e.vars.overlays)==null?void 0:n[t.elevation]}))}),Uj=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiPaper"}),{className:o,component:a="div",elevation:i=1,square:l=!1,variant:c="elevation"}=r,u=$e(r,Fj),d=I({},r,{component:a,elevation:i,square:l,variant:c}),f=zj(d);return s(jj,I({as:a,ownerState:d,className:ve(f.root,o),ref:n},u))}),pr=Uj,Wj=p.createContext({}),j$=Wj;function Hj(e){return je("MuiAccordion",e)}const Vj=Ue("MuiAccordion",["root","rounded","expanded","disabled","gutters","region"]),Wf=Vj,Gj=["children","className","defaultExpanded","disabled","disableGutters","expanded","onChange","square","TransitionComponent","TransitionProps"],qj=e=>{const{classes:t,square:n,expanded:r,disabled:o,disableGutters:a}=e;return He({root:["root",!n&&"rounded",r&&"expanded",o&&"disabled",!a&&"gutters"],region:["region"]},Hj,t)},Kj=C(pr,{name:"MuiAccordion",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`& .${Wf.region}`]:t.region},t.root,!n.square&&t.rounded,!n.disableGutters&&t.gutters]}})(({theme:e})=>{const t={duration:e.transitions.duration.shortest};return{position:"relative",transition:e.transitions.create(["margin"],t),overflowAnchor:"none","&:before":{position:"absolute",left:0,top:-1,right:0,height:1,content:'""',opacity:1,backgroundColor:(e.vars||e).palette.divider,transition:e.transitions.create(["opacity","background-color"],t)},"&:first-of-type":{"&:before":{display:"none"}},[`&.${Wf.expanded}`]:{"&:before":{opacity:0},"&:first-of-type":{marginTop:0},"&:last-of-type":{marginBottom:0},"& + &":{"&:before":{display:"none"}}},[`&.${Wf.disabled}`]:{backgroundColor:(e.vars||e).palette.action.disabledBackground}}},({theme:e,ownerState:t})=>I({},!t.square&&{borderRadius:0,"&:first-of-type":{borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius},"&:last-of-type":{borderBottomLeftRadius:(e.vars||e).shape.borderRadius,borderBottomRightRadius:(e.vars||e).shape.borderRadius,"@supports (-ms-ime-align: auto)":{borderBottomLeftRadius:0,borderBottomRightRadius:0}}},!t.disableGutters&&{[`&.${Wf.expanded}`]:{margin:"16px 0"}})),Yj=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiAccordion"}),{children:o,className:a,defaultExpanded:i=!1,disabled:l=!1,disableGutters:c=!1,expanded:u,onChange:d,square:f=!1,TransitionComponent:h=z$,TransitionProps:m}=r,y=$e(r,Gj),[g,v]=Sa({controlled:u,default:i,name:"Accordion",state:"expanded"}),b=p.useCallback(_=>{v(!g),d&&d(_,!g)},[g,d,v]),[w,...x]=p.Children.toArray(o),E=p.useMemo(()=>({expanded:g,disabled:l,disableGutters:c,toggle:b}),[g,l,c,b]),A=I({},r,{square:f,disabled:l,disableGutters:c,expanded:g}),k=qj(A);return T(Kj,I({className:ve(k.root,a),ref:n,ownerState:A,square:f},y,{children:[s(j$.Provider,{value:E,children:w}),s(h,I({in:g,timeout:"auto"},m,{children:s("div",{"aria-labelledby":w.props.id,id:w.props["aria-controls"],role:"region",className:k.region,children:x})}))]}))}),nx=Yj;function Xj(e){return je("MuiAccordionDetails",e)}Ue("MuiAccordionDetails",["root"]);const Jj=["className"],Qj=e=>{const{classes:t}=e;return He({root:["root"]},Xj,t)},Zj=C("div",{name:"MuiAccordionDetails",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({padding:e.spacing(1,2,2)})),eU=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiAccordionDetails"}),{className:o}=r,a=$e(r,Jj),i=r,l=Qj(i);return s(Zj,I({className:ve(l.root,o),ref:n,ownerState:i},a))}),rx=eU;function tU(e){const{className:t,classes:n,pulsate:r=!1,rippleX:o,rippleY:a,rippleSize:i,in:l,onExited:c,timeout:u}=e,[d,f]=p.useState(!1),h=ve(t,n.ripple,n.rippleVisible,r&&n.ripplePulsate),m={width:i,height:i,top:-(i/2)+a,left:-(i/2)+o},y=ve(n.child,d&&n.childLeaving,r&&n.childPulsate);return!l&&!d&&f(!0),p.useEffect(()=>{if(!l&&c!=null){const g=setTimeout(c,u);return()=>{clearTimeout(g)}}},[c,l,u]),s("span",{className:h,style:m,children:s("span",{className:y})})}const nU=Ue("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),Wo=nU,rU=["center","classes","className"];let Jg=e=>e,nk,rk,ok,ak;const Eb=550,oU=80,aU=ks(nk||(nk=Jg`
|
|
92
|
+
0% {
|
|
93
|
+
transform: scale(0);
|
|
94
|
+
opacity: 0.1;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
100% {
|
|
98
|
+
transform: scale(1);
|
|
99
|
+
opacity: 0.3;
|
|
100
|
+
}
|
|
101
|
+
`)),iU=ks(rk||(rk=Jg`
|
|
102
|
+
0% {
|
|
103
|
+
opacity: 1;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
100% {
|
|
107
|
+
opacity: 0;
|
|
108
|
+
}
|
|
109
|
+
`)),sU=ks(ok||(ok=Jg`
|
|
110
|
+
0% {
|
|
111
|
+
transform: scale(1);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
50% {
|
|
115
|
+
transform: scale(0.92);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
100% {
|
|
119
|
+
transform: scale(1);
|
|
120
|
+
}
|
|
121
|
+
`)),lU=C("span",{name:"MuiTouchRipple",slot:"Root"})({overflow:"hidden",pointerEvents:"none",position:"absolute",zIndex:0,top:0,right:0,bottom:0,left:0,borderRadius:"inherit"}),cU=C(tU,{name:"MuiTouchRipple",slot:"Ripple"})(ak||(ak=Jg`
|
|
122
|
+
opacity: 0;
|
|
123
|
+
position: absolute;
|
|
124
|
+
|
|
125
|
+
&.${0} {
|
|
126
|
+
opacity: 0.3;
|
|
127
|
+
transform: scale(1);
|
|
128
|
+
animation-name: ${0};
|
|
129
|
+
animation-duration: ${0}ms;
|
|
130
|
+
animation-timing-function: ${0};
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
&.${0} {
|
|
134
|
+
animation-duration: ${0}ms;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
& .${0} {
|
|
138
|
+
opacity: 1;
|
|
139
|
+
display: block;
|
|
140
|
+
width: 100%;
|
|
141
|
+
height: 100%;
|
|
142
|
+
border-radius: 50%;
|
|
143
|
+
background-color: currentColor;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
& .${0} {
|
|
147
|
+
opacity: 0;
|
|
148
|
+
animation-name: ${0};
|
|
149
|
+
animation-duration: ${0}ms;
|
|
150
|
+
animation-timing-function: ${0};
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
& .${0} {
|
|
154
|
+
position: absolute;
|
|
155
|
+
/* @noflip */
|
|
156
|
+
left: 0px;
|
|
157
|
+
top: 0;
|
|
158
|
+
animation-name: ${0};
|
|
159
|
+
animation-duration: 2500ms;
|
|
160
|
+
animation-timing-function: ${0};
|
|
161
|
+
animation-iteration-count: infinite;
|
|
162
|
+
animation-delay: 200ms;
|
|
163
|
+
}
|
|
164
|
+
`),Wo.rippleVisible,aU,Eb,({theme:e})=>e.transitions.easing.easeInOut,Wo.ripplePulsate,({theme:e})=>e.transitions.duration.shorter,Wo.child,Wo.childLeaving,iU,Eb,({theme:e})=>e.transitions.easing.easeInOut,Wo.childPulsate,sU,({theme:e})=>e.transitions.easing.easeInOut),uU=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTouchRipple"}),{center:o=!1,classes:a={},className:i}=r,l=$e(r,rU),[c,u]=p.useState([]),d=p.useRef(0),f=p.useRef(null);p.useEffect(()=>{f.current&&(f.current(),f.current=null)},[c]);const h=p.useRef(!1),m=p.useRef(null),y=p.useRef(null),g=p.useRef(null);p.useEffect(()=>()=>{clearTimeout(m.current)},[]);const v=p.useCallback(E=>{const{pulsate:A,rippleX:k,rippleY:_,rippleSize:$,cb:L}=E;u(O=>[...O,s(cU,{classes:{ripple:ve(a.ripple,Wo.ripple),rippleVisible:ve(a.rippleVisible,Wo.rippleVisible),ripplePulsate:ve(a.ripplePulsate,Wo.ripplePulsate),child:ve(a.child,Wo.child),childLeaving:ve(a.childLeaving,Wo.childLeaving),childPulsate:ve(a.childPulsate,Wo.childPulsate)},timeout:Eb,pulsate:A,rippleX:k,rippleY:_,rippleSize:$},d.current)]),d.current+=1,f.current=L},[a]),b=p.useCallback((E={},A={},k=()=>{})=>{const{pulsate:_=!1,center:$=o||A.pulsate,fakeElement:L=!1}=A;if((E==null?void 0:E.type)==="mousedown"&&h.current){h.current=!1;return}(E==null?void 0:E.type)==="touchstart"&&(h.current=!0);const O=L?null:g.current,P=O?O.getBoundingClientRect():{width:0,height:0,left:0,top:0};let D,F,U;if($||E===void 0||E.clientX===0&&E.clientY===0||!E.clientX&&!E.touches)D=Math.round(P.width/2),F=Math.round(P.height/2);else{const{clientX:Y,clientY:V}=E.touches&&E.touches.length>0?E.touches[0]:E;D=Math.round(Y-P.left),F=Math.round(V-P.top)}if($)U=Math.sqrt((2*P.width**2+P.height**2)/3),U%2===0&&(U+=1);else{const Y=Math.max(Math.abs((O?O.clientWidth:0)-D),D)*2+2,V=Math.max(Math.abs((O?O.clientHeight:0)-F),F)*2+2;U=Math.sqrt(Y**2+V**2)}E!=null&&E.touches?y.current===null&&(y.current=()=>{v({pulsate:_,rippleX:D,rippleY:F,rippleSize:U,cb:k})},m.current=setTimeout(()=>{y.current&&(y.current(),y.current=null)},oU)):v({pulsate:_,rippleX:D,rippleY:F,rippleSize:U,cb:k})},[o,v]),w=p.useCallback(()=>{b({},{pulsate:!0})},[b]),x=p.useCallback((E,A)=>{if(clearTimeout(m.current),(E==null?void 0:E.type)==="touchend"&&y.current){y.current(),y.current=null,m.current=setTimeout(()=>{x(E,A)});return}y.current=null,u(k=>k.length>0?k.slice(1):k),f.current=A},[]);return p.useImperativeHandle(n,()=>({pulsate:w,start:b,stop:x}),[w,b,x]),s(lU,I({className:ve(Wo.root,a.root,i),ref:g},l,{children:s(Ij,{component:null,exit:!0,children:c})}))}),dU=uU;function pU(e){return je("MuiButtonBase",e)}const fU=Ue("MuiButtonBase",["root","disabled","focusVisible"]),hU=fU,mU=["action","centerRipple","children","className","component","disabled","disableRipple","disableTouchRipple","focusRipple","focusVisibleClassName","LinkComponent","onBlur","onClick","onContextMenu","onDragLeave","onFocus","onFocusVisible","onKeyDown","onKeyUp","onMouseDown","onMouseLeave","onMouseUp","onTouchEnd","onTouchMove","onTouchStart","tabIndex","TouchRippleProps","touchRippleRef","type"],gU=e=>{const{disabled:t,focusVisible:n,focusVisibleClassName:r,classes:o}=e,i=He({root:["root",t&&"disabled",n&&"focusVisible"]},pU,o);return n&&r&&(i.root+=` ${r}`),i},vU=C("button",{name:"MuiButtonBase",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,padding:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"},[`&.${hU.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}}),yU=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiButtonBase"}),{action:o,centerRipple:a=!1,children:i,className:l,component:c="button",disabled:u=!1,disableRipple:d=!1,disableTouchRipple:f=!1,focusRipple:h=!1,LinkComponent:m="a",onBlur:y,onClick:g,onContextMenu:v,onDragLeave:b,onFocus:w,onFocusVisible:x,onKeyDown:E,onKeyUp:A,onMouseDown:k,onMouseLeave:_,onMouseUp:$,onTouchEnd:L,onTouchMove:O,onTouchStart:P,tabIndex:D=0,TouchRippleProps:F,touchRippleRef:U,type:Y}=r,V=$e(r,mU),te=p.useRef(null),Z=p.useRef(null),W=Sn(Z,U),{isFocusVisibleRef:z,onFocus:R,onBlur:M,ref:ee}=jp(),[re,Se]=p.useState(!1);u&&re&&Se(!1),p.useImperativeHandle(o,()=>({focusVisible:()=>{Se(!0),te.current.focus()}}),[]);const[ce,Ce]=p.useState(!1);p.useEffect(()=>{Ce(!0)},[]);const xe=ce&&!d&&!u;p.useEffect(()=>{re&&h&&!d&&ce&&Z.current.pulsate()},[d,h,re,ce]);function Ee(K,se,be=f){return gr(Ae=>(se&&se(Ae),!be&&Z.current&&Z.current[K](Ae),!0))}const tt=Ee("start",k),me=Ee("stop",v),Ge=Ee("stop",b),qe=Ee("stop",$),Be=Ee("stop",K=>{re&&K.preventDefault(),_&&_(K)}),he=Ee("start",P),Et=Ee("stop",L),Ke=Ee("stop",O),ct=Ee("stop",K=>{M(K),z.current===!1&&Se(!1),y&&y(K)},!1),Rt=gr(K=>{te.current||(te.current=K.currentTarget),R(K),z.current===!0&&(Se(!0),x&&x(K)),w&&w(K)}),dt=()=>{const K=te.current;return c&&c!=="button"&&!(K.tagName==="A"&&K.href)},rt=p.useRef(!1),Nt=gr(K=>{h&&!rt.current&&re&&Z.current&&K.key===" "&&(rt.current=!0,Z.current.stop(K,()=>{Z.current.start(K)})),K.target===K.currentTarget&&dt()&&K.key===" "&&K.preventDefault(),E&&E(K),K.target===K.currentTarget&&dt()&&K.key==="Enter"&&!u&&(K.preventDefault(),g&&g(K))}),xt=gr(K=>{h&&K.key===" "&&Z.current&&re&&!K.defaultPrevented&&(rt.current=!1,Z.current.stop(K,()=>{Z.current.pulsate(K)})),A&&A(K),g&&K.target===K.currentTarget&&dt()&&K.key===" "&&!K.defaultPrevented&&g(K)});let pe=c;pe==="button"&&(V.href||V.to)&&(pe=m);const Te={};pe==="button"?(Te.type=Y===void 0?"button":Y,Te.disabled=u):(!V.href&&!V.to&&(Te.role="button"),u&&(Te["aria-disabled"]=u));const Xe=Sn(n,ee,te),De=I({},r,{centerRipple:a,component:c,disabled:u,disableRipple:d,disableTouchRipple:f,focusRipple:h,tabIndex:D,focusVisible:re}),q=gU(De);return T(vU,I({as:pe,className:ve(q.root,l),ownerState:De,onBlur:ct,onClick:g,onContextMenu:me,onFocus:Rt,onKeyDown:Nt,onKeyUp:xt,onMouseDown:tt,onMouseLeave:Be,onMouseUp:qe,onDragLeave:Ge,onTouchEnd:Et,onTouchMove:Ke,onTouchStart:he,ref:Xe,tabIndex:u?-1:D,type:Y},Te,V,{children:[i,xe?s(dU,I({ref:W,center:a},F)):null]}))}),Ea=yU;function bU(e){return je("MuiAccordionSummary",e)}const wU=Ue("MuiAccordionSummary",["root","expanded","focusVisible","disabled","gutters","contentGutters","content","expandIconWrapper"]),ic=wU,SU=["children","className","expandIcon","focusVisibleClassName","onClick"],xU=e=>{const{classes:t,expanded:n,disabled:r,disableGutters:o}=e;return He({root:["root",n&&"expanded",r&&"disabled",!o&&"gutters"],focusVisible:["focusVisible"],content:["content",n&&"expanded",!o&&"contentGutters"],expandIconWrapper:["expandIconWrapper",n&&"expanded"]},bU,t)},CU=C(Ea,{name:"MuiAccordionSummary",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{const n={duration:e.transitions.duration.shortest};return I({display:"flex",minHeight:48,padding:e.spacing(0,2),transition:e.transitions.create(["min-height","background-color"],n),[`&.${ic.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`&.${ic.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity},[`&:hover:not(.${ic.disabled})`]:{cursor:"pointer"}},!t.disableGutters&&{[`&.${ic.expanded}`]:{minHeight:64}})}),EU=C("div",{name:"MuiAccordionSummary",slot:"Content",overridesResolver:(e,t)=>t.content})(({theme:e,ownerState:t})=>I({display:"flex",flexGrow:1,margin:"12px 0"},!t.disableGutters&&{transition:e.transitions.create(["margin"],{duration:e.transitions.duration.shortest}),[`&.${ic.expanded}`]:{margin:"20px 0"}})),TU=C("div",{name:"MuiAccordionSummary",slot:"ExpandIconWrapper",overridesResolver:(e,t)=>t.expandIconWrapper})(({theme:e})=>({display:"flex",color:(e.vars||e).palette.action.active,transform:"rotate(0deg)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shortest}),[`&.${ic.expanded}`]:{transform:"rotate(180deg)"}})),kU=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiAccordionSummary"}),{children:o,className:a,expandIcon:i,focusVisibleClassName:l,onClick:c}=r,u=$e(r,SU),{disabled:d=!1,disableGutters:f,expanded:h,toggle:m}=p.useContext(j$),y=b=>{m&&m(b),c&&c(b)},g=I({},r,{expanded:h,disabled:d,disableGutters:f}),v=xU(g);return T(CU,I({focusRipple:!1,disableRipple:!0,disabled:d,component:"div","aria-expanded":h,className:ve(v.root,a),focusVisibleClassName:ve(v.focusVisible,l),onClick:y,ref:n,ownerState:g},u,{children:[s(EU,{className:v.content,ownerState:g,children:o}),i&&s(TU,{className:v.expandIconWrapper,ownerState:g,children:i})]}))}),ox=kU;function AU(e){return je("MuiAlert",e)}const _U=Ue("MuiAlert",["root","action","icon","message","filled","filledSuccess","filledInfo","filledWarning","filledError","outlined","outlinedSuccess","outlinedInfo","outlinedWarning","outlinedError","standard","standardSuccess","standardInfo","standardWarning","standardError"]),ik=_U;function RU(e){return je("MuiIconButton",e)}const PU=Ue("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge"]),IU=PU,$U=["edge","children","className","color","disabled","disableFocusRipple","size"],OU=e=>{const{classes:t,disabled:n,color:r,edge:o,size:a}=e,i={root:["root",n&&"disabled",r!=="default"&&`color${ie(r)}`,o&&`edge${ie(o)}`,`size${ie(a)}`]};return He(i,RU,t)},LU=C(Ea,{name:"MuiIconButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="default"&&t[`color${ie(n.color)}`],n.edge&&t[`edge${ie(n.edge)}`],t[`size${ie(n.size)}`]]}})(({theme:e,ownerState:t})=>I({textAlign:"center",flex:"0 0 auto",fontSize:e.typography.pxToRem(24),padding:8,borderRadius:"50%",overflow:"visible",color:(e.vars||e).palette.action.active,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest})},!t.disableRipple&&{"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(e.palette.action.active,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},t.edge==="start"&&{marginLeft:t.size==="small"?-3:-12},t.edge==="end"&&{marginRight:t.size==="small"?-3:-12}),({theme:e,ownerState:t})=>{var n;const r=(n=(e.vars||e).palette)==null?void 0:n[t.color];return I({},t.color==="inherit"&&{color:"inherit"},t.color!=="inherit"&&t.color!=="default"&&I({color:r==null?void 0:r.main},!t.disableRipple&&{"&:hover":I({},r&&{backgroundColor:e.vars?`rgba(${r.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(r.main,e.palette.action.hoverOpacity)},{"@media (hover: none)":{backgroundColor:"transparent"}})}),t.size==="small"&&{padding:5,fontSize:e.typography.pxToRem(18)},t.size==="large"&&{padding:12,fontSize:e.typography.pxToRem(28)},{[`&.${IU.disabled}`]:{backgroundColor:"transparent",color:(e.vars||e).palette.action.disabled}})}),NU=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiIconButton"}),{edge:o=!1,children:a,className:i,color:l="default",disabled:c=!1,disableFocusRipple:u=!1,size:d="medium"}=r,f=$e(r,$U),h=I({},r,{edge:o,color:l,disabled:c,disableFocusRipple:u,size:d}),m=OU(h);return s(LU,I({className:ve(m.root,i),centerRipple:!0,focusRipple:!u,disabled:c,ref:n,ownerState:h},f,{children:a}))}),Yt=NU,MU=Ye(s("path",{d:"M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z"}),"SuccessOutlined"),DU=Ye(s("path",{d:"M12 5.99L19.53 19H4.47L12 5.99M12 2L1 21h22L12 2zm1 14h-2v2h2v-2zm0-6h-2v4h2v-4z"}),"ReportProblemOutlined"),BU=Ye(s("path",{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"ErrorOutline"),FU=Ye(s("path",{d:"M11,9H13V7H11M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20, 12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10, 10 0 0,0 12,2M11,17H13V11H11V17Z"}),"InfoOutlined"),U$=Ye(s("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close"),zU=["action","children","className","closeText","color","components","componentsProps","icon","iconMapping","onClose","role","severity","slotProps","slots","variant"],jU=e=>{const{variant:t,color:n,severity:r,classes:o}=e,a={root:["root",`${t}${ie(n||r)}`,`${t}`],icon:["icon"],message:["message"],action:["action"]};return He(a,AU,o)},UU=C(pr,{name:"MuiAlert",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],t[`${n.variant}${ie(n.color||n.severity)}`]]}})(({theme:e,ownerState:t})=>{const n=e.palette.mode==="light"?gs:vs,r=e.palette.mode==="light"?vs:gs,o=t.color||t.severity;return I({},e.typography.body2,{backgroundColor:"transparent",display:"flex",padding:"6px 16px"},o&&t.variant==="standard"&&{color:e.vars?e.vars.palette.Alert[`${o}Color`]:n(e.palette[o].light,.6),backgroundColor:e.vars?e.vars.palette.Alert[`${o}StandardBg`]:r(e.palette[o].light,.9),[`& .${ik.icon}`]:e.vars?{color:e.vars.palette.Alert[`${o}IconColor`]}:{color:e.palette[o].main}},o&&t.variant==="outlined"&&{color:e.vars?e.vars.palette.Alert[`${o}Color`]:n(e.palette[o].light,.6),border:`1px solid ${(e.vars||e).palette[o].light}`,[`& .${ik.icon}`]:e.vars?{color:e.vars.palette.Alert[`${o}IconColor`]}:{color:e.palette[o].main}},o&&t.variant==="filled"&&I({fontWeight:e.typography.fontWeightMedium},e.vars?{color:e.vars.palette.Alert[`${o}FilledColor`],backgroundColor:e.vars.palette.Alert[`${o}FilledBg`]}:{backgroundColor:e.palette.mode==="dark"?e.palette[o].dark:e.palette[o].main,color:e.palette.getContrastText(e.palette[o].main)}))}),WU=C("div",{name:"MuiAlert",slot:"Icon",overridesResolver:(e,t)=>t.icon})({marginRight:12,padding:"7px 0",display:"flex",fontSize:22,opacity:.9}),HU=C("div",{name:"MuiAlert",slot:"Message",overridesResolver:(e,t)=>t.message})({padding:"8px 0",minWidth:0,overflow:"auto"}),sk=C("div",{name:"MuiAlert",slot:"Action",overridesResolver:(e,t)=>t.action})({display:"flex",alignItems:"flex-start",padding:"4px 0 0 16px",marginLeft:"auto",marginRight:-8}),lk={success:s(MU,{fontSize:"inherit"}),warning:s(DU,{fontSize:"inherit"}),error:s(BU,{fontSize:"inherit"}),info:s(FU,{fontSize:"inherit"})},VU=p.forwardRef(function(t,n){var r,o,a,i,l,c;const u=Ve({props:t,name:"MuiAlert"}),{action:d,children:f,className:h,closeText:m="Close",color:y,components:g={},componentsProps:v={},icon:b,iconMapping:w=lk,onClose:x,role:E="alert",severity:A="success",slotProps:k={},slots:_={},variant:$="standard"}=u,L=$e(u,zU),O=I({},u,{color:y,severity:A,variant:$}),P=jU(O),D=(r=(o=_.closeButton)!=null?o:g.CloseButton)!=null?r:Yt,F=(a=(i=_.closeIcon)!=null?i:g.CloseIcon)!=null?a:U$,U=(l=k.closeButton)!=null?l:v.closeButton,Y=(c=k.closeIcon)!=null?c:v.closeIcon;return T(UU,I({role:E,elevation:0,ownerState:O,className:ve(P.root,h),ref:n},L,{children:[b!==!1?s(WU,{ownerState:O,className:P.icon,children:b||w[A]||lk[A]}):null,s(HU,{ownerState:O,className:P.message,children:f}),d!=null?s(sk,{ownerState:O,className:P.action,children:d}):null,d==null&&x?s(sk,{ownerState:O,className:P.action,children:s(D,I({size:"small","aria-label":m,title:m,color:"inherit",onClick:x},U,{children:s(F,I({fontSize:"small"},Y))}))}):null]}))}),Zt=VU;function GU(e){return je("MuiTypography",e)}Ue("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const qU=["align","className","component","gutterBottom","noWrap","paragraph","variant","variantMapping"],KU=e=>{const{align:t,gutterBottom:n,noWrap:r,paragraph:o,variant:a,classes:i}=e,l={root:["root",a,e.align!=="inherit"&&`align${ie(t)}`,n&&"gutterBottom",r&&"noWrap",o&&"paragraph"]};return He(l,GU,i)},YU=C("span",{name:"MuiTypography",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.variant&&t[n.variant],n.align!=="inherit"&&t[`align${ie(n.align)}`],n.noWrap&&t.noWrap,n.gutterBottom&&t.gutterBottom,n.paragraph&&t.paragraph]}})(({theme:e,ownerState:t})=>I({margin:0},t.variant&&e.typography[t.variant],t.align!=="inherit"&&{textAlign:t.align},t.noWrap&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t.gutterBottom&&{marginBottom:"0.35em"},t.paragraph&&{marginBottom:16})),ck={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},XU={primary:"primary.main",textPrimary:"text.primary",secondary:"secondary.main",textSecondary:"text.secondary",error:"error.main"},JU=e=>XU[e]||e,QU=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTypography"}),o=JU(r.color),a=zS(I({},r,{color:o})),{align:i="inherit",className:l,component:c,gutterBottom:u=!1,noWrap:d=!1,paragraph:f=!1,variant:h="body1",variantMapping:m=ck}=a,y=$e(a,qU),g=I({},a,{align:i,color:o,className:l,component:c,gutterBottom:u,noWrap:d,paragraph:f,variant:h,variantMapping:m}),v=c||(f?"p":m[h]||ck[h])||"span",b=KU(g);return s(YU,I({as:v,ref:n,ownerState:g,className:ve(b.root,l)},y))}),ye=QU;function ZU(e){return je("MuiAlertTitle",e)}Ue("MuiAlertTitle",["root"]);const eW=["className"],tW=e=>{const{classes:t}=e;return He({root:["root"]},ZU,t)},nW=C(ye,{name:"MuiAlertTitle",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({fontWeight:e.typography.fontWeightMedium,marginTop:-2})),rW=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiAlertTitle"}),{className:o}=r,a=$e(r,eW),i=r,l=tW(i);return s(nW,I({gutterBottom:!0,component:"div",ownerState:i,ref:n,className:ve(l.root,o)},a))}),Em=rW;function oW(e){return je("MuiAppBar",e)}Ue("MuiAppBar",["root","positionFixed","positionAbsolute","positionSticky","positionStatic","positionRelative","colorDefault","colorPrimary","colorSecondary","colorInherit","colorTransparent"]);const aW=["className","color","enableColorOnDark","position"],iW=e=>{const{color:t,position:n,classes:r}=e,o={root:["root",`color${ie(t)}`,`position${ie(n)}`]};return He(o,oW,r)},Hf=(e,t)=>e?`${e==null?void 0:e.replace(")","")}, ${t})`:t,sW=C(pr,{name:"MuiAppBar",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`position${ie(n.position)}`],t[`color${ie(n.color)}`]]}})(({theme:e,ownerState:t})=>{const n=e.palette.mode==="light"?e.palette.grey[100]:e.palette.grey[900];return I({display:"flex",flexDirection:"column",width:"100%",boxSizing:"border-box",flexShrink:0},t.position==="fixed"&&{position:"fixed",zIndex:(e.vars||e).zIndex.appBar,top:0,left:"auto",right:0,"@media print":{position:"absolute"}},t.position==="absolute"&&{position:"absolute",zIndex:(e.vars||e).zIndex.appBar,top:0,left:"auto",right:0},t.position==="sticky"&&{position:"sticky",zIndex:(e.vars||e).zIndex.appBar,top:0,left:"auto",right:0},t.position==="static"&&{position:"static"},t.position==="relative"&&{position:"relative"},!e.vars&&I({},t.color==="default"&&{backgroundColor:n,color:e.palette.getContrastText(n)},t.color&&t.color!=="default"&&t.color!=="inherit"&&t.color!=="transparent"&&{backgroundColor:e.palette[t.color].main,color:e.palette[t.color].contrastText},t.color==="inherit"&&{color:"inherit"},e.palette.mode==="dark"&&!t.enableColorOnDark&&{backgroundColor:null,color:null},t.color==="transparent"&&I({backgroundColor:"transparent",color:"inherit"},e.palette.mode==="dark"&&{backgroundImage:"none"})),e.vars&&I({},t.color==="default"&&{"--AppBar-background":t.enableColorOnDark?e.vars.palette.AppBar.defaultBg:Hf(e.vars.palette.AppBar.darkBg,e.vars.palette.AppBar.defaultBg),"--AppBar-color":t.enableColorOnDark?e.vars.palette.text.primary:Hf(e.vars.palette.AppBar.darkColor,e.vars.palette.text.primary)},t.color&&!t.color.match(/^(default|inherit|transparent)$/)&&{"--AppBar-background":t.enableColorOnDark?e.vars.palette[t.color].main:Hf(e.vars.palette.AppBar.darkBg,e.vars.palette[t.color].main),"--AppBar-color":t.enableColorOnDark?e.vars.palette[t.color].contrastText:Hf(e.vars.palette.AppBar.darkColor,e.vars.palette[t.color].contrastText)},{backgroundColor:"var(--AppBar-background)",color:t.color==="inherit"?"inherit":"var(--AppBar-color)"},t.color==="transparent"&&{backgroundImage:"none",backgroundColor:"transparent",color:"inherit"}))}),lW=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiAppBar"}),{className:o,color:a="primary",enableColorOnDark:i=!1,position:l="fixed"}=r,c=$e(r,aW),u=I({},r,{color:a,position:l,enableColorOnDark:i}),d=iW(u);return s(sW,I({square:!0,component:"header",ownerState:u,elevation:4,className:ve(d.root,o,l==="fixed"&&"mui-fixed"),ref:n},c))}),cW=lW,uW=["components","componentsProps","slots","slotProps"],dW=C(qz,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),pW=p.forwardRef(function(t,n){var r;const o=jS(),a=Ve({props:t,name:"MuiPopper"}),{components:i,componentsProps:l,slots:c,slotProps:u}=a,d=$e(a,uW),f=(r=c==null?void 0:c.root)!=null?r:i==null?void 0:i.Root;return s(dW,I({direction:o==null?void 0:o.direction,slots:{root:f},slotProps:u??l},d,{ref:n}))}),Qg=pW;function fW(e){return je("MuiListSubheader",e)}Ue("MuiListSubheader",["root","colorPrimary","colorInherit","gutters","inset","sticky"]);const hW=["className","color","component","disableGutters","disableSticky","inset"],mW=e=>{const{classes:t,color:n,disableGutters:r,inset:o,disableSticky:a}=e,i={root:["root",n!=="default"&&`color${ie(n)}`,!r&&"gutters",o&&"inset",!a&&"sticky"]};return He(i,fW,t)},gW=C("li",{name:"MuiListSubheader",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="default"&&t[`color${ie(n.color)}`],!n.disableGutters&&t.gutters,n.inset&&t.inset,!n.disableSticky&&t.sticky]}})(({theme:e,ownerState:t})=>I({boxSizing:"border-box",lineHeight:"48px",listStyle:"none",color:(e.vars||e).palette.text.secondary,fontFamily:e.typography.fontFamily,fontWeight:e.typography.fontWeightMedium,fontSize:e.typography.pxToRem(14)},t.color==="primary"&&{color:(e.vars||e).palette.primary.main},t.color==="inherit"&&{color:"inherit"},!t.disableGutters&&{paddingLeft:16,paddingRight:16},t.inset&&{paddingLeft:72},!t.disableSticky&&{position:"sticky",top:0,zIndex:1,backgroundColor:(e.vars||e).palette.background.paper})),vW=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiListSubheader"}),{className:o,color:a="default",component:i="li",disableGutters:l=!1,disableSticky:c=!1,inset:u=!1}=r,d=$e(r,hW),f=I({},r,{color:a,component:i,disableGutters:l,disableSticky:c,inset:u}),h=mW(f);return s(gW,I({as:i,className:ve(h.root,o),ref:n,ownerState:f},d))}),yW=vW,bW=Ye(s("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"}),"Cancel");function wW(e){return je("MuiChip",e)}const SW=Ue("MuiChip",["root","sizeSmall","sizeMedium","colorError","colorInfo","colorPrimary","colorSecondary","colorSuccess","colorWarning","disabled","clickable","clickableColorPrimary","clickableColorSecondary","deletable","deletableColorPrimary","deletableColorSecondary","outlined","filled","outlinedPrimary","outlinedSecondary","filledPrimary","filledSecondary","avatar","avatarSmall","avatarMedium","avatarColorPrimary","avatarColorSecondary","icon","iconSmall","iconMedium","iconColorPrimary","iconColorSecondary","label","labelSmall","labelMedium","deleteIcon","deleteIconSmall","deleteIconMedium","deleteIconColorPrimary","deleteIconColorSecondary","deleteIconOutlinedColorPrimary","deleteIconOutlinedColorSecondary","deleteIconFilledColorPrimary","deleteIconFilledColorSecondary","focusVisible"]),tn=SW,xW=["avatar","className","clickable","color","component","deleteIcon","disabled","icon","label","onClick","onDelete","onKeyDown","onKeyUp","size","variant","tabIndex","skipFocusWhenDisabled"],CW=e=>{const{classes:t,disabled:n,size:r,color:o,iconColor:a,onDelete:i,clickable:l,variant:c}=e,u={root:["root",c,n&&"disabled",`size${ie(r)}`,`color${ie(o)}`,l&&"clickable",l&&`clickableColor${ie(o)}`,i&&"deletable",i&&`deletableColor${ie(o)}`,`${c}${ie(o)}`],label:["label",`label${ie(r)}`],avatar:["avatar",`avatar${ie(r)}`,`avatarColor${ie(o)}`],icon:["icon",`icon${ie(r)}`,`iconColor${ie(a)}`],deleteIcon:["deleteIcon",`deleteIcon${ie(r)}`,`deleteIconColor${ie(o)}`,`deleteIcon${ie(c)}Color${ie(o)}`]};return He(u,wW,t)},EW=C("div",{name:"MuiChip",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e,{color:r,iconColor:o,clickable:a,onDelete:i,size:l,variant:c}=n;return[{[`& .${tn.avatar}`]:t.avatar},{[`& .${tn.avatar}`]:t[`avatar${ie(l)}`]},{[`& .${tn.avatar}`]:t[`avatarColor${ie(r)}`]},{[`& .${tn.icon}`]:t.icon},{[`& .${tn.icon}`]:t[`icon${ie(l)}`]},{[`& .${tn.icon}`]:t[`iconColor${ie(o)}`]},{[`& .${tn.deleteIcon}`]:t.deleteIcon},{[`& .${tn.deleteIcon}`]:t[`deleteIcon${ie(l)}`]},{[`& .${tn.deleteIcon}`]:t[`deleteIconColor${ie(r)}`]},{[`& .${tn.deleteIcon}`]:t[`deleteIcon${ie(c)}Color${ie(r)}`]},t.root,t[`size${ie(l)}`],t[`color${ie(r)}`],a&&t.clickable,a&&r!=="default"&&t[`clickableColor${ie(r)})`],i&&t.deletable,i&&r!=="default"&&t[`deletableColor${ie(r)}`],t[c],t[`${c}${ie(r)}`]]}})(({theme:e,ownerState:t})=>{const n=Ot(e.palette.text.primary,.26),r=e.palette.mode==="light"?e.palette.grey[700]:e.palette.grey[300];return I({maxWidth:"100%",fontFamily:e.typography.fontFamily,fontSize:e.typography.pxToRem(13),display:"inline-flex",alignItems:"center",justifyContent:"center",height:32,color:(e.vars||e).palette.text.primary,backgroundColor:(e.vars||e).palette.action.selected,borderRadius:32/2,whiteSpace:"nowrap",transition:e.transitions.create(["background-color","box-shadow"]),cursor:"default",outline:0,textDecoration:"none",border:0,padding:0,verticalAlign:"middle",boxSizing:"border-box",[`&.${tn.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity,pointerEvents:"none"},[`& .${tn.avatar}`]:{marginLeft:5,marginRight:-6,width:24,height:24,color:e.vars?e.vars.palette.Chip.defaultAvatarColor:r,fontSize:e.typography.pxToRem(12)},[`& .${tn.avatarColorPrimary}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.dark},[`& .${tn.avatarColorSecondary}`]:{color:(e.vars||e).palette.secondary.contrastText,backgroundColor:(e.vars||e).palette.secondary.dark},[`& .${tn.avatarSmall}`]:{marginLeft:4,marginRight:-4,width:18,height:18,fontSize:e.typography.pxToRem(10)},[`& .${tn.icon}`]:I({marginLeft:5,marginRight:-6},t.size==="small"&&{fontSize:18,marginLeft:4,marginRight:-4},t.iconColor===t.color&&I({color:e.vars?e.vars.palette.Chip.defaultIconColor:r},t.color!=="default"&&{color:"inherit"})),[`& .${tn.deleteIcon}`]:I({WebkitTapHighlightColor:"transparent",color:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / 0.26)`:n,fontSize:22,cursor:"pointer",margin:"0 5px 0 -6px","&:hover":{color:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / 0.4)`:Ot(n,.4)}},t.size==="small"&&{fontSize:16,marginRight:4,marginLeft:-4},t.color!=="default"&&{color:e.vars?`rgba(${e.vars.palette[t.color].contrastTextChannel} / 0.7)`:Ot(e.palette[t.color].contrastText,.7),"&:hover, &:active":{color:(e.vars||e).palette[t.color].contrastText}})},t.size==="small"&&{height:24},t.color!=="default"&&{backgroundColor:(e.vars||e).palette[t.color].main,color:(e.vars||e).palette[t.color].contrastText},t.onDelete&&{[`&.${tn.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Ot(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}},t.onDelete&&t.color!=="default"&&{[`&.${tn.focusVisible}`]:{backgroundColor:(e.vars||e).palette[t.color].dark}})},({theme:e,ownerState:t})=>I({},t.clickable&&{userSelect:"none",WebkitTapHighlightColor:"transparent",cursor:"pointer","&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:Ot(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity)},[`&.${tn.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Ot(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)},"&:active":{boxShadow:(e.vars||e).shadows[1]}},t.clickable&&t.color!=="default"&&{[`&:hover, &.${tn.focusVisible}`]:{backgroundColor:(e.vars||e).palette[t.color].dark}}),({theme:e,ownerState:t})=>I({},t.variant==="outlined"&&{backgroundColor:"transparent",border:e.vars?`1px solid ${e.vars.palette.Chip.defaultBorder}`:`1px solid ${e.palette.mode==="light"?e.palette.grey[400]:e.palette.grey[700]}`,[`&.${tn.clickable}:hover`]:{backgroundColor:(e.vars||e).palette.action.hover},[`&.${tn.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`& .${tn.avatar}`]:{marginLeft:4},[`& .${tn.avatarSmall}`]:{marginLeft:2},[`& .${tn.icon}`]:{marginLeft:4},[`& .${tn.iconSmall}`]:{marginLeft:2},[`& .${tn.deleteIcon}`]:{marginRight:5},[`& .${tn.deleteIconSmall}`]:{marginRight:3}},t.variant==="outlined"&&t.color!=="default"&&{color:(e.vars||e).palette[t.color].main,border:`1px solid ${e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / 0.7)`:Ot(e.palette[t.color].main,.7)}`,[`&.${tn.clickable}:hover`]:{backgroundColor:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(e.palette[t.color].main,e.palette.action.hoverOpacity)},[`&.${tn.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.focusOpacity})`:Ot(e.palette[t.color].main,e.palette.action.focusOpacity)},[`& .${tn.deleteIcon}`]:{color:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / 0.7)`:Ot(e.palette[t.color].main,.7),"&:hover, &:active":{color:(e.vars||e).palette[t.color].main}}})),TW=C("span",{name:"MuiChip",slot:"Label",overridesResolver:(e,t)=>{const{ownerState:n}=e,{size:r}=n;return[t.label,t[`label${ie(r)}`]]}})(({ownerState:e})=>I({overflow:"hidden",textOverflow:"ellipsis",paddingLeft:12,paddingRight:12,whiteSpace:"nowrap"},e.size==="small"&&{paddingLeft:8,paddingRight:8}));function uk(e){return e.key==="Backspace"||e.key==="Delete"}const kW=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiChip"}),{avatar:o,className:a,clickable:i,color:l="default",component:c,deleteIcon:u,disabled:d=!1,icon:f,label:h,onClick:m,onDelete:y,onKeyDown:g,onKeyUp:v,size:b="medium",variant:w="filled",tabIndex:x,skipFocusWhenDisabled:E=!1}=r,A=$e(r,xW),k=p.useRef(null),_=Sn(k,n),$=W=>{W.stopPropagation(),y&&y(W)},L=W=>{W.currentTarget===W.target&&uk(W)&&W.preventDefault(),g&&g(W)},O=W=>{W.currentTarget===W.target&&(y&&uk(W)?y(W):W.key==="Escape"&&k.current&&k.current.blur()),v&&v(W)},P=i!==!1&&m?!0:i,D=P||y?Ea:c||"div",F=I({},r,{component:D,disabled:d,size:b,color:l,iconColor:p.isValidElement(f)&&f.props.color||l,onDelete:!!y,clickable:P,variant:w}),U=CW(F),Y=D===Ea?I({component:c||"div",focusVisibleClassName:U.focusVisible},y&&{disableRipple:!0}):{};let V=null;y&&(V=u&&p.isValidElement(u)?p.cloneElement(u,{className:ve(u.props.className,U.deleteIcon),onClick:$}):s(bW,{className:ve(U.deleteIcon),onClick:$}));let te=null;o&&p.isValidElement(o)&&(te=p.cloneElement(o,{className:ve(U.avatar,o.props.className)}));let Z=null;return f&&p.isValidElement(f)&&(Z=p.cloneElement(f,{className:ve(U.icon,f.props.className)})),T(EW,I({as:D,className:ve(U.root,a),disabled:P&&d?!0:void 0,onClick:m,onKeyDown:L,onKeyUp:O,ref:_,tabIndex:E&&d?-1:x,ownerState:F},Y,A,{children:[te||Z,s(TW,{className:ve(U.label),ownerState:F,children:h}),V]}))}),To=kW;function _s({props:e,states:t,muiFormControl:n}){return t.reduce((r,o)=>(r[o]=e[o],n&&typeof e[o]>"u"&&(r[o]=n[o]),r),{})}const AW=p.createContext(void 0),Zg=AW;function oi(){return p.useContext(Zg)}function W$(e){return s(mF,I({},e,{defaultTheme:Kg}))}function dk(e){return e!=null&&!(Array.isArray(e)&&e.length===0)}function ax(e,t=!1){return e&&(dk(e.value)&&e.value!==""||t&&dk(e.defaultValue)&&e.defaultValue!=="")}function _W(e){return e.startAdornment}function RW(e){return je("MuiInputBase",e)}const PW=Ue("MuiInputBase",["root","formControl","focused","disabled","adornedStart","adornedEnd","error","sizeSmall","multiline","colorSecondary","fullWidth","hiddenLabel","readOnly","input","inputSizeSmall","inputMultiline","inputTypeSearch","inputAdornedStart","inputAdornedEnd","inputHiddenLabel"]),xo=PW,IW=["aria-describedby","autoComplete","autoFocus","className","color","components","componentsProps","defaultValue","disabled","disableInjectingGlobalStyles","endAdornment","error","fullWidth","id","inputComponent","inputProps","inputRef","margin","maxRows","minRows","multiline","name","onBlur","onChange","onClick","onFocus","onKeyDown","onKeyUp","placeholder","readOnly","renderSuffix","rows","size","slotProps","slots","startAdornment","type","value"],ev=(e,t)=>{const{ownerState:n}=e;return[t.root,n.formControl&&t.formControl,n.startAdornment&&t.adornedStart,n.endAdornment&&t.adornedEnd,n.error&&t.error,n.size==="small"&&t.sizeSmall,n.multiline&&t.multiline,n.color&&t[`color${ie(n.color)}`],n.fullWidth&&t.fullWidth,n.hiddenLabel&&t.hiddenLabel]},tv=(e,t)=>{const{ownerState:n}=e;return[t.input,n.size==="small"&&t.inputSizeSmall,n.multiline&&t.inputMultiline,n.type==="search"&&t.inputTypeSearch,n.startAdornment&&t.inputAdornedStart,n.endAdornment&&t.inputAdornedEnd,n.hiddenLabel&&t.inputHiddenLabel]},$W=e=>{const{classes:t,color:n,disabled:r,error:o,endAdornment:a,focused:i,formControl:l,fullWidth:c,hiddenLabel:u,multiline:d,readOnly:f,size:h,startAdornment:m,type:y}=e,g={root:["root",`color${ie(n)}`,r&&"disabled",o&&"error",c&&"fullWidth",i&&"focused",l&&"formControl",h==="small"&&"sizeSmall",d&&"multiline",m&&"adornedStart",a&&"adornedEnd",u&&"hiddenLabel",f&&"readOnly"],input:["input",r&&"disabled",y==="search"&&"inputTypeSearch",d&&"inputMultiline",h==="small"&&"inputSizeSmall",u&&"inputHiddenLabel",m&&"inputAdornedStart",a&&"inputAdornedEnd",f&&"readOnly"]};return He(g,RW,t)},nv=C("div",{name:"MuiInputBase",slot:"Root",overridesResolver:ev})(({theme:e,ownerState:t})=>I({},e.typography.body1,{color:(e.vars||e).palette.text.primary,lineHeight:"1.4375em",boxSizing:"border-box",position:"relative",cursor:"text",display:"inline-flex",alignItems:"center",[`&.${xo.disabled}`]:{color:(e.vars||e).palette.text.disabled,cursor:"default"}},t.multiline&&I({padding:"4px 0 5px"},t.size==="small"&&{paddingTop:1}),t.fullWidth&&{width:"100%"})),rv=C("input",{name:"MuiInputBase",slot:"Input",overridesResolver:tv})(({theme:e,ownerState:t})=>{const n=e.palette.mode==="light",r=I({color:"currentColor"},e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:n?.42:.5},{transition:e.transitions.create("opacity",{duration:e.transitions.duration.shorter})}),o={opacity:"0 !important"},a=e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:n?.42:.5};return I({font:"inherit",letterSpacing:"inherit",color:"currentColor",padding:"4px 0 5px",border:0,boxSizing:"content-box",background:"none",height:"1.4375em",margin:0,WebkitTapHighlightColor:"transparent",display:"block",minWidth:0,width:"100%",animationName:"mui-auto-fill-cancel",animationDuration:"10ms","&::-webkit-input-placeholder":r,"&::-moz-placeholder":r,"&:-ms-input-placeholder":r,"&::-ms-input-placeholder":r,"&:focus":{outline:0},"&:invalid":{boxShadow:"none"},"&::-webkit-search-decoration":{WebkitAppearance:"none"},[`label[data-shrink=false] + .${xo.formControl} &`]:{"&::-webkit-input-placeholder":o,"&::-moz-placeholder":o,"&:-ms-input-placeholder":o,"&::-ms-input-placeholder":o,"&:focus::-webkit-input-placeholder":a,"&:focus::-moz-placeholder":a,"&:focus:-ms-input-placeholder":a,"&:focus::-ms-input-placeholder":a},[`&.${xo.disabled}`]:{opacity:1,WebkitTextFillColor:(e.vars||e).palette.text.disabled},"&:-webkit-autofill":{animationDuration:"5000s",animationName:"mui-auto-fill"}},t.size==="small"&&{paddingTop:1},t.multiline&&{height:"auto",resize:"none",padding:0,paddingTop:0},t.type==="search"&&{MozAppearance:"textfield"})}),OW=s(W$,{styles:{"@keyframes mui-auto-fill":{from:{display:"block"}},"@keyframes mui-auto-fill-cancel":{from:{display:"block"}}}}),LW=p.forwardRef(function(t,n){var r;const o=Ve({props:t,name:"MuiInputBase"}),{"aria-describedby":a,autoComplete:i,autoFocus:l,className:c,components:u={},componentsProps:d={},defaultValue:f,disabled:h,disableInjectingGlobalStyles:m,endAdornment:y,fullWidth:g=!1,id:v,inputComponent:b="input",inputProps:w={},inputRef:x,maxRows:E,minRows:A,multiline:k=!1,name:_,onBlur:$,onChange:L,onClick:O,onFocus:P,onKeyDown:D,onKeyUp:F,placeholder:U,readOnly:Y,renderSuffix:V,rows:te,slotProps:Z={},slots:W={},startAdornment:z,type:R="text",value:M}=o,ee=$e(o,IW),re=w.value!=null?w.value:M,{current:Se}=p.useRef(re!=null),ce=p.useRef(),Ce=p.useCallback(q=>{},[]),xe=Sn(ce,x,w.ref,Ce),[Ee,tt]=p.useState(!1),me=oi(),Ge=_s({props:o,muiFormControl:me,states:["color","disabled","error","hiddenLabel","size","required","filled"]});Ge.focused=me?me.focused:Ee,p.useEffect(()=>{!me&&h&&Ee&&(tt(!1),$&&$())},[me,h,Ee,$]);const qe=me&&me.onFilled,Be=me&&me.onEmpty,he=p.useCallback(q=>{ax(q)?qe&&qe():Be&&Be()},[qe,Be]);$o(()=>{Se&&he({value:re})},[re,he,Se]);const Et=q=>{if(Ge.disabled){q.stopPropagation();return}P&&P(q),w.onFocus&&w.onFocus(q),me&&me.onFocus?me.onFocus(q):tt(!0)},Ke=q=>{$&&$(q),w.onBlur&&w.onBlur(q),me&&me.onBlur?me.onBlur(q):tt(!1)},ct=(q,...K)=>{if(!Se){const se=q.target||ce.current;if(se==null)throw new Error(ms(1));he({value:se.value})}w.onChange&&w.onChange(q,...K),L&&L(q,...K)};p.useEffect(()=>{he(ce.current)},[]);const Rt=q=>{ce.current&&q.currentTarget===q.target&&ce.current.focus(),O&&O(q)};let dt=b,rt=w;k&&dt==="input"&&(te?rt=I({type:void 0,minRows:te,maxRows:te},rt):rt=I({type:void 0,maxRows:E,minRows:A},rt),dt=vj);const Nt=q=>{he(q.animationName==="mui-auto-fill-cancel"?ce.current:{value:"x"})};p.useEffect(()=>{me&&me.setAdornedStart(Boolean(z))},[me,z]);const xt=I({},o,{color:Ge.color||"primary",disabled:Ge.disabled,endAdornment:y,error:Ge.error,focused:Ge.focused,formControl:me,fullWidth:g,hiddenLabel:Ge.hiddenLabel,multiline:k,size:Ge.size,startAdornment:z,type:R}),pe=$W(xt),Te=W.root||u.Root||nv,Xe=Z.root||d.root||{},De=W.input||u.Input||rv;return rt=I({},rt,(r=Z.input)!=null?r:d.input),T(p.Fragment,{children:[!m&&OW,T(Te,I({},Xe,!qa(Te)&&{ownerState:I({},xt,Xe.ownerState)},{ref:n,onClick:Rt},ee,{className:ve(pe.root,Xe.className,c),children:[z,s(Zg.Provider,{value:null,children:s(De,I({ownerState:xt,"aria-invalid":Ge.error,"aria-describedby":a,autoComplete:i,autoFocus:l,defaultValue:f,disabled:Ge.disabled,id:v,onAnimationStart:Nt,name:_,placeholder:U,readOnly:Y,required:Ge.required,rows:te,value:re,onKeyDown:D,onKeyUp:F,type:R},rt,!qa(De)&&{as:dt,ownerState:I({},xt,rt.ownerState)},{ref:xe,className:ve(pe.input,rt.className),onBlur:Ke,onChange:ct,onFocus:Et}))}),y,V?V(I({},Ge,{startAdornment:z})):null]}))]})}),ov=LW;function NW(e){return je("MuiInput",e)}const MW=I({},xo,Ue("MuiInput",["root","underline","input"])),Vi=MW;function DW(e){return je("MuiOutlinedInput",e)}const BW=I({},xo,Ue("MuiOutlinedInput",["root","notchedOutline","input"])),Ia=BW;function FW(e){return je("MuiFilledInput",e)}const zW=I({},xo,Ue("MuiFilledInput",["root","underline","input"])),Co=zW,H$=Ye(s("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown");function jW(e){return je("MuiAutocomplete",e)}const UW=Ue("MuiAutocomplete",["root","fullWidth","focused","focusVisible","tag","tagSizeSmall","tagSizeMedium","hasPopupIcon","hasClearIcon","inputRoot","input","inputFocused","endAdornment","clearIndicator","popupIndicator","popupIndicatorOpen","popper","popperDisablePortal","paper","listbox","loading","noOptions","option","groupLabel","groupUl"]),Wt=UW;var pk,fk;const WW=["autoComplete","autoHighlight","autoSelect","blurOnSelect","ChipProps","className","clearIcon","clearOnBlur","clearOnEscape","clearText","closeText","componentsProps","defaultValue","disableClearable","disableCloseOnSelect","disabled","disabledItemsFocusable","disableListWrap","disablePortal","filterOptions","filterSelectedOptions","forcePopupIcon","freeSolo","fullWidth","getLimitTagsText","getOptionDisabled","getOptionLabel","isOptionEqualToValue","groupBy","handleHomeEndKeys","id","includeInputInList","inputValue","limitTags","ListboxComponent","ListboxProps","loading","loadingText","multiple","noOptionsText","onChange","onClose","onHighlightChange","onInputChange","onOpen","open","openOnFocus","openText","options","PaperComponent","PopperComponent","popupIcon","readOnly","renderGroup","renderInput","renderOption","renderTags","selectOnFocus","size","slotProps","value"],HW=e=>{const{classes:t,disablePortal:n,focused:r,fullWidth:o,hasClearIcon:a,hasPopupIcon:i,inputFocused:l,popupOpen:c,size:u}=e,d={root:["root",r&&"focused",o&&"fullWidth",a&&"hasClearIcon",i&&"hasPopupIcon"],inputRoot:["inputRoot"],input:["input",l&&"inputFocused"],tag:["tag",`tagSize${ie(u)}`],endAdornment:["endAdornment"],clearIndicator:["clearIndicator"],popupIndicator:["popupIndicator",c&&"popupIndicatorOpen"],popper:["popper",n&&"popperDisablePortal"],paper:["paper"],listbox:["listbox"],loading:["loading"],noOptions:["noOptions"],option:["option"],groupLabel:["groupLabel"],groupUl:["groupUl"]};return He(d,jW,t)},VW=C("div",{name:"MuiAutocomplete",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e,{fullWidth:r,hasClearIcon:o,hasPopupIcon:a,inputFocused:i,size:l}=n;return[{[`& .${Wt.tag}`]:t.tag},{[`& .${Wt.tag}`]:t[`tagSize${ie(l)}`]},{[`& .${Wt.inputRoot}`]:t.inputRoot},{[`& .${Wt.input}`]:t.input},{[`& .${Wt.input}`]:i&&t.inputFocused},t.root,r&&t.fullWidth,a&&t.hasPopupIcon,o&&t.hasClearIcon]}})(({ownerState:e})=>I({[`&.${Wt.focused} .${Wt.clearIndicator}`]:{visibility:"visible"},"@media (pointer: fine)":{[`&:hover .${Wt.clearIndicator}`]:{visibility:"visible"}}},e.fullWidth&&{width:"100%"},{[`& .${Wt.tag}`]:I({margin:3,maxWidth:"calc(100% - 6px)"},e.size==="small"&&{margin:2,maxWidth:"calc(100% - 4px)"}),[`& .${Wt.inputRoot}`]:{flexWrap:"wrap",[`.${Wt.hasPopupIcon}&, .${Wt.hasClearIcon}&`]:{paddingRight:26+4},[`.${Wt.hasPopupIcon}.${Wt.hasClearIcon}&`]:{paddingRight:52+4},[`& .${Wt.input}`]:{width:0,minWidth:30}},[`& .${Vi.root}`]:{paddingBottom:1,"& .MuiInput-input":{padding:"4px 4px 4px 0px"}},[`& .${Vi.root}.${xo.sizeSmall}`]:{[`& .${Vi.input}`]:{padding:"2px 4px 3px 0"}},[`& .${Ia.root}`]:{padding:9,[`.${Wt.hasPopupIcon}&, .${Wt.hasClearIcon}&`]:{paddingRight:26+4+9},[`.${Wt.hasPopupIcon}.${Wt.hasClearIcon}&`]:{paddingRight:52+4+9},[`& .${Wt.input}`]:{padding:"7.5px 4px 7.5px 6px"},[`& .${Wt.endAdornment}`]:{right:9}},[`& .${Ia.root}.${xo.sizeSmall}`]:{paddingTop:6,paddingBottom:6,paddingLeft:6,[`& .${Wt.input}`]:{padding:"2.5px 4px 2.5px 6px"}},[`& .${Co.root}`]:{paddingTop:19,paddingLeft:8,[`.${Wt.hasPopupIcon}&, .${Wt.hasClearIcon}&`]:{paddingRight:26+4+9},[`.${Wt.hasPopupIcon}.${Wt.hasClearIcon}&`]:{paddingRight:52+4+9},[`& .${Co.input}`]:{padding:"7px 4px"},[`& .${Wt.endAdornment}`]:{right:9}},[`& .${Co.root}.${xo.sizeSmall}`]:{paddingBottom:1,[`& .${Co.input}`]:{padding:"2.5px 4px"}},[`& .${xo.hiddenLabel}`]:{paddingTop:8},[`& .${Co.root}.${xo.hiddenLabel}`]:{paddingTop:0,paddingBottom:0,[`& .${Wt.input}`]:{paddingTop:16,paddingBottom:17}},[`& .${Co.root}.${xo.hiddenLabel}.${xo.sizeSmall}`]:{[`& .${Wt.input}`]:{paddingTop:8,paddingBottom:9}},[`& .${Wt.input}`]:I({flexGrow:1,textOverflow:"ellipsis",opacity:0},e.inputFocused&&{opacity:1})})),GW=C("div",{name:"MuiAutocomplete",slot:"EndAdornment",overridesResolver:(e,t)=>t.endAdornment})({position:"absolute",right:0,top:"calc(50% - 14px)"}),qW=C(Yt,{name:"MuiAutocomplete",slot:"ClearIndicator",overridesResolver:(e,t)=>t.clearIndicator})({marginRight:-2,padding:4,visibility:"hidden"}),KW=C(Yt,{name:"MuiAutocomplete",slot:"PopupIndicator",overridesResolver:({ownerState:e},t)=>I({},t.popupIndicator,e.popupOpen&&t.popupIndicatorOpen)})(({ownerState:e})=>I({padding:2,marginRight:-2},e.popupOpen&&{transform:"rotate(180deg)"})),YW=C(Qg,{name:"MuiAutocomplete",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`& .${Wt.option}`]:t.option},t.popper,n.disablePortal&&t.popperDisablePortal]}})(({theme:e,ownerState:t})=>I({zIndex:(e.vars||e).zIndex.modal},t.disablePortal&&{position:"absolute"})),XW=C(pr,{name:"MuiAutocomplete",slot:"Paper",overridesResolver:(e,t)=>t.paper})(({theme:e})=>I({},e.typography.body1,{overflow:"auto"})),JW=C("div",{name:"MuiAutocomplete",slot:"Loading",overridesResolver:(e,t)=>t.loading})(({theme:e})=>({color:(e.vars||e).palette.text.secondary,padding:"14px 16px"})),QW=C("div",{name:"MuiAutocomplete",slot:"NoOptions",overridesResolver:(e,t)=>t.noOptions})(({theme:e})=>({color:(e.vars||e).palette.text.secondary,padding:"14px 16px"})),ZW=C("div",{name:"MuiAutocomplete",slot:"Listbox",overridesResolver:(e,t)=>t.listbox})(({theme:e})=>({listStyle:"none",margin:0,padding:"8px 0",maxHeight:"40vh",overflow:"auto",position:"relative",[`& .${Wt.option}`]:{minHeight:48,display:"flex",overflow:"hidden",justifyContent:"flex-start",alignItems:"center",cursor:"pointer",paddingTop:6,boxSizing:"border-box",outline:"0",WebkitTapHighlightColor:"transparent",paddingBottom:6,paddingLeft:16,paddingRight:16,[e.breakpoints.up("sm")]:{minHeight:"auto"},[`&.${Wt.focused}`]:{backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},'&[aria-disabled="true"]':{opacity:(e.vars||e).palette.action.disabledOpacity,pointerEvents:"none"},[`&.${Wt.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},'&[aria-selected="true"]':{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity),[`&.${Wt.focused}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:(e.vars||e).palette.action.selected}},[`&.${Wt.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}}}})),eH=C(yW,{name:"MuiAutocomplete",slot:"GroupLabel",overridesResolver:(e,t)=>t.groupLabel})(({theme:e})=>({backgroundColor:(e.vars||e).palette.background.paper,top:-8})),tH=C("ul",{name:"MuiAutocomplete",slot:"GroupUl",overridesResolver:(e,t)=>t.groupUl})({padding:0,[`& .${Wt.option}`]:{paddingLeft:24}}),nH=p.forwardRef(function(t,n){var r,o,a,i;const l=Ve({props:t,name:"MuiAutocomplete"}),{autoComplete:c=!1,autoHighlight:u=!1,autoSelect:d=!1,blurOnSelect:f=!1,ChipProps:h,className:m,clearIcon:y=pk||(pk=s(U$,{fontSize:"small"})),clearOnBlur:g=!l.freeSolo,clearOnEscape:v=!1,clearText:b="Clear",closeText:w="Close",componentsProps:x={},defaultValue:E=l.multiple?[]:null,disableClearable:A=!1,disableCloseOnSelect:k=!1,disabled:_=!1,disabledItemsFocusable:$=!1,disableListWrap:L=!1,disablePortal:O=!1,filterSelectedOptions:P=!1,forcePopupIcon:D="auto",freeSolo:F=!1,fullWidth:U=!1,getLimitTagsText:Y=Bt=>`+${Bt}`,getOptionLabel:V=Bt=>{var Gt;return(Gt=Bt.label)!=null?Gt:Bt},groupBy:te,handleHomeEndKeys:Z=!l.freeSolo,includeInputInList:W=!1,limitTags:z=-1,ListboxComponent:R="ul",ListboxProps:M,loading:ee=!1,loadingText:re="Loading…",multiple:Se=!1,noOptionsText:ce="No options",openOnFocus:Ce=!1,openText:xe="Open",PaperComponent:Ee=pr,PopperComponent:tt=Qg,popupIcon:me=fk||(fk=s(H$,{})),readOnly:Ge=!1,renderGroup:qe,renderInput:Be,renderOption:he,renderTags:Et,selectOnFocus:Ke=!l.freeSolo,size:ct="medium",slotProps:Rt={}}=l,dt=$e(l,WW),{getRootProps:rt,getInputProps:Nt,getInputLabelProps:xt,getPopupIndicatorProps:pe,getClearProps:Te,getTagProps:Xe,getListboxProps:De,getOptionProps:q,value:K,dirty:se,id:be,popupOpen:Ae,focused:mt,focusedTag:et,anchorEl:ht,setAnchorEl:Xt,inputValue:Mn,groupedOptions:pt}=S8(I({},l,{componentName:"Autocomplete"})),pn=!A&&!_&&se&&!Ge,Vt=(!F||D===!0)&&D!==!1,en=I({},l,{disablePortal:O,focused:mt,fullWidth:U,hasClearIcon:pn,hasPopupIcon:Vt,inputFocused:et===-1,popupOpen:Ae,size:ct}),Ft=HW(en);let Hn;if(Se&&K.length>0){const Bt=Gt=>I({className:Ft.tag,disabled:_},Xe(Gt));Et?Hn=Et(K,Bt,en):Hn=K.map((Gt,jn)=>s(To,I({label:V(Gt),size:ct},Bt({index:jn}),h)))}if(z>-1&&Array.isArray(Hn)){const Bt=Hn.length-z;!mt&&Bt>0&&(Hn=Hn.splice(0,z),Hn.push(s("span",{className:Ft.tag,children:Y(Bt)},Hn.length)))}const ro=qe||(Bt=>T("li",{children:[s(eH,{className:Ft.groupLabel,ownerState:en,component:"div",children:Bt.group}),s(tH,{className:Ft.groupUl,ownerState:en,children:Bt.children})]},Bt.key)),bo=he||((Bt,Gt)=>s("li",I({},Bt,{children:V(Gt)}))),Rr=(Bt,Gt)=>{const jn=q({option:Bt,index:Gt});return bo(I({},jn,{className:Ft.option}),Bt,{selected:jn["aria-selected"],index:Gt,inputValue:Mn})},oo=(r=Rt.clearIndicator)!=null?r:x.clearIndicator,Jn=(o=Rt.paper)!=null?o:x.paper,ao=(a=Rt.popper)!=null?a:x.popper,wr=(i=Rt.popupIndicator)!=null?i:x.popupIndicator;return T(p.Fragment,{children:[s(VW,I({ref:n,className:ve(Ft.root,m),ownerState:en},rt(dt),{children:Be({id:be,disabled:_,fullWidth:!0,size:ct==="small"?"small":void 0,InputLabelProps:xt(),InputProps:I({ref:Xt,className:Ft.inputRoot,startAdornment:Hn},(pn||Vt)&&{endAdornment:T(GW,{className:Ft.endAdornment,ownerState:en,children:[pn?s(qW,I({},Te(),{"aria-label":b,title:b,ownerState:en},oo,{className:ve(Ft.clearIndicator,oo==null?void 0:oo.className),children:y})):null,Vt?s(KW,I({},pe(),{disabled:_,"aria-label":Ae?w:xe,title:Ae?w:xe,ownerState:en},wr,{className:ve(Ft.popupIndicator,wr==null?void 0:wr.className),children:me})):null]})}),inputProps:I({className:Ft.input,disabled:_,readOnly:Ge},Nt())})})),ht?s(YW,I({as:tt,disablePortal:O,style:{width:ht?ht.clientWidth:null},ownerState:en,role:"presentation",anchorEl:ht,open:Ae},ao,{className:ve(Ft.popper,ao==null?void 0:ao.className),children:T(XW,I({ownerState:en,as:Ee},Jn,{className:ve(Ft.paper,Jn==null?void 0:Jn.className),children:[ee&&pt.length===0?s(JW,{className:Ft.loading,ownerState:en,children:re}):null,pt.length===0&&!F&&!ee?s(QW,{className:Ft.noOptions,ownerState:en,role:"presentation",onMouseDown:Bt=>{Bt.preventDefault()},children:ce}):null,pt.length>0?s(ZW,I({as:R,className:Ft.listbox,ownerState:en},De(),M,{children:pt.map((Bt,Gt)=>te?ro({key:Bt.key,group:Bt.group,children:Bt.options.map((jn,hr)=>Rr(jn,Bt.index+hr))}):Rr(Bt,Gt))})):null]}))})):null]})}),av=nH,rH=Ye(s("path",{d:"M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"}),"Person");function oH(e){return je("MuiAvatar",e)}Ue("MuiAvatar",["root","colorDefault","circular","rounded","square","img","fallback"]);const aH=["alt","children","className","component","imgProps","sizes","src","srcSet","variant"],iH=e=>{const{classes:t,variant:n,colorDefault:r}=e;return He({root:["root",n,r&&"colorDefault"],img:["img"],fallback:["fallback"]},oH,t)},sH=C("div",{name:"MuiAvatar",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],n.colorDefault&&t.colorDefault]}})(({theme:e,ownerState:t})=>I({position:"relative",display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,width:40,height:40,fontFamily:e.typography.fontFamily,fontSize:e.typography.pxToRem(20),lineHeight:1,borderRadius:"50%",overflow:"hidden",userSelect:"none"},t.variant==="rounded"&&{borderRadius:(e.vars||e).shape.borderRadius},t.variant==="square"&&{borderRadius:0},t.colorDefault&&I({color:(e.vars||e).palette.background.default},e.vars?{backgroundColor:e.vars.palette.Avatar.defaultBg}:{backgroundColor:e.palette.mode==="light"?e.palette.grey[400]:e.palette.grey[600]}))),lH=C("img",{name:"MuiAvatar",slot:"Img",overridesResolver:(e,t)=>t.img})({width:"100%",height:"100%",textAlign:"center",objectFit:"cover",color:"transparent",textIndent:1e4}),cH=C(rH,{name:"MuiAvatar",slot:"Fallback",overridesResolver:(e,t)=>t.fallback})({width:"75%",height:"75%"});function uH({crossOrigin:e,referrerPolicy:t,src:n,srcSet:r}){const[o,a]=p.useState(!1);return p.useEffect(()=>{if(!n&&!r)return;a(!1);let i=!0;const l=new Image;return l.onload=()=>{i&&a("loaded")},l.onerror=()=>{i&&a("error")},l.crossOrigin=e,l.referrerPolicy=t,l.src=n,r&&(l.srcset=r),()=>{i=!1}},[e,t,n,r]),o}const dH=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiAvatar"}),{alt:o,children:a,className:i,component:l="div",imgProps:c,sizes:u,src:d,srcSet:f,variant:h="circular"}=r,m=$e(r,aH);let y=null;const g=uH(I({},c,{src:d,srcSet:f})),v=d||f,b=v&&g!=="error",w=I({},r,{colorDefault:!b,component:l,variant:h}),x=iH(w);return b?y=s(lH,I({alt:o,src:d,srcSet:f,sizes:u,ownerState:w,className:x.img},c)):a!=null?y=a:v&&o?y=o[0]:y=s(cH,{ownerState:w,className:x.fallback}),s(sH,I({as:l,ownerState:w,className:ve(x.root,i),ref:n},m,{children:y}))}),iv=dH,pH=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"],fH={entering:{opacity:1},entered:{opacity:1}},hH=p.forwardRef(function(t,n){const r=on(),o={enter:r.transitions.duration.enteringScreen,exit:r.transitions.duration.leavingScreen},{addEndListener:a,appear:i=!0,children:l,easing:c,in:u,onEnter:d,onEntered:f,onEntering:h,onExit:m,onExited:y,onExiting:g,style:v,timeout:b=o,TransitionComponent:w=Xg}=t,x=$e(t,pH),E=p.useRef(null),A=Sn(E,l.ref,n),k=U=>Y=>{if(U){const V=E.current;Y===void 0?U(V):U(V,Y)}},_=k(h),$=k((U,Y)=>{tx(U);const V=ys({style:v,timeout:b,easing:c},{mode:"enter"});U.style.webkitTransition=r.transitions.create("opacity",V),U.style.transition=r.transitions.create("opacity",V),d&&d(U,Y)}),L=k(f),O=k(g),P=k(U=>{const Y=ys({style:v,timeout:b,easing:c},{mode:"exit"});U.style.webkitTransition=r.transitions.create("opacity",Y),U.style.transition=r.transitions.create("opacity",Y),m&&m(U)}),D=k(y);return s(w,I({appear:i,in:u,nodeRef:E,onEnter:$,onEntered:L,onEntering:_,onExit:P,onExited:D,onExiting:O,addEndListener:U=>{a&&a(E.current,U)},timeout:b},x,{children:(U,Y)=>p.cloneElement(l,I({style:I({opacity:0,visibility:U==="exited"&&!u?"hidden":void 0},fH[U],v,l.props.style),ref:A},Y))}))}),ix=hH;function mH(e){return je("MuiBackdrop",e)}Ue("MuiBackdrop",["root","invisible"]);const gH=["children","className","component","components","componentsProps","invisible","open","slotProps","slots","TransitionComponent","transitionDuration"],vH=e=>{const{classes:t,invisible:n}=e;return He({root:["root",n&&"invisible"]},mH,t)},yH=C("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.invisible&&t.invisible]}})(({ownerState:e})=>I({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent"},e.invisible&&{backgroundColor:"transparent"})),bH=p.forwardRef(function(t,n){var r,o,a;const i=Ve({props:t,name:"MuiBackdrop"}),{children:l,className:c,component:u="div",components:d={},componentsProps:f={},invisible:h=!1,open:m,slotProps:y={},slots:g={},TransitionComponent:v=ix,transitionDuration:b}=i,w=$e(i,gH),x=I({},i,{component:u,invisible:h}),E=vH(x),A=(r=y.root)!=null?r:f.root;return s(v,I({in:m,timeout:b},w,{children:s(yH,I({"aria-hidden":!0},A,{as:(o=(a=g.root)!=null?a:d.Root)!=null?o:u,className:ve(E.root,c,A==null?void 0:A.className),ownerState:I({},x,A==null?void 0:A.ownerState),classes:E,ref:n,children:l}))}))}),sx=bH,wH=qg(),SH=b7({defaultTheme:wH,defaultClassName:"MuiBox-root",generateClassName:kS.generate}),Me=SH,xH=Ye(s("path",{d:"M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"}),"MoreHoriz"),CH=C(Ea)(({theme:e})=>I({display:"flex",marginLeft:`calc(${e.spacing(1)} * 0.5)`,marginRight:`calc(${e.spacing(1)} * 0.5)`},e.palette.mode==="light"?{backgroundColor:e.palette.grey[100],color:e.palette.grey[700]}:{backgroundColor:e.palette.grey[700],color:e.palette.grey[100]},{borderRadius:2,"&:hover, &:focus":I({},e.palette.mode==="light"?{backgroundColor:e.palette.grey[200]}:{backgroundColor:e.palette.grey[600]}),"&:active":I({boxShadow:e.shadows[0]},e.palette.mode==="light"?{backgroundColor:RT(e.palette.grey[200],.12)}:{backgroundColor:RT(e.palette.grey[600],.12)})})),EH=C(xH)({width:24,height:16});function TH(e){const t=e;return s("li",{children:s(CH,I({focusRipple:!0},e,{ownerState:t,children:s(EH,{ownerState:t})}))})}function kH(e){return je("MuiBreadcrumbs",e)}const AH=Ue("MuiBreadcrumbs",["root","ol","li","separator"]),_H=AH,RH=["children","className","component","expandText","itemsAfterCollapse","itemsBeforeCollapse","maxItems","separator"],PH=e=>{const{classes:t}=e;return He({root:["root"],li:["li"],ol:["ol"],separator:["separator"]},kH,t)},IH=C(ye,{name:"MuiBreadcrumbs",slot:"Root",overridesResolver:(e,t)=>[{[`& .${_H.li}`]:t.li},t.root]})({}),$H=C("ol",{name:"MuiBreadcrumbs",slot:"Ol",overridesResolver:(e,t)=>t.ol})({display:"flex",flexWrap:"wrap",alignItems:"center",padding:0,margin:0,listStyle:"none"}),OH=C("li",{name:"MuiBreadcrumbs",slot:"Separator",overridesResolver:(e,t)=>t.separator})({display:"flex",userSelect:"none",marginLeft:8,marginRight:8});function LH(e,t,n,r){return e.reduce((o,a,i)=>(i<e.length-1?o=o.concat(a,s(OH,{"aria-hidden":!0,className:t,ownerState:r,children:n},`separator-${i}`)):o.push(a),o),[])}const NH=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiBreadcrumbs"}),{children:o,className:a,component:i="nav",expandText:l="Show path",itemsAfterCollapse:c=1,itemsBeforeCollapse:u=1,maxItems:d=8,separator:f="/"}=r,h=$e(r,RH),[m,y]=p.useState(!1),g=I({},r,{component:i,expanded:m,expandText:l,itemsAfterCollapse:c,itemsBeforeCollapse:u,maxItems:d,separator:f}),v=PH(g),b=p.useRef(null),w=E=>{const A=()=>{y(!0);const k=b.current.querySelector("a[href],button,[tabindex]");k&&k.focus()};return u+c>=E.length?E:[...E.slice(0,u),s(TH,{"aria-label":l,onClick:A},"ellipsis"),...E.slice(E.length-c,E.length)]},x=p.Children.toArray(o).filter(E=>p.isValidElement(E)).map((E,A)=>s("li",{className:v.li,children:E},`child-${A}`));return s(IH,I({ref:n,component:i,color:"text.secondary",className:ve(v.root,a),ownerState:g},h,{children:s($H,{className:v.ol,ref:b,ownerState:g,children:LH(m||d&&x.length<=d?x:w(x),v.separator,f,g)})}))}),MH=NH;function DH(e){return je("MuiButton",e)}const BH=Ue("MuiButton",["root","text","textInherit","textPrimary","textSecondary","textSuccess","textError","textInfo","textWarning","outlined","outlinedInherit","outlinedPrimary","outlinedSecondary","outlinedSuccess","outlinedError","outlinedInfo","outlinedWarning","contained","containedInherit","containedPrimary","containedSecondary","containedSuccess","containedError","containedInfo","containedWarning","disableElevation","focusVisible","disabled","colorInherit","textSizeSmall","textSizeMedium","textSizeLarge","outlinedSizeSmall","outlinedSizeMedium","outlinedSizeLarge","containedSizeSmall","containedSizeMedium","containedSizeLarge","sizeMedium","sizeSmall","sizeLarge","fullWidth","startIcon","endIcon","iconSizeSmall","iconSizeMedium","iconSizeLarge"]),Vf=BH,FH=p.createContext({}),zH=FH,jH=["children","color","component","className","disabled","disableElevation","disableFocusRipple","endIcon","focusVisibleClassName","fullWidth","size","startIcon","type","variant"],UH=e=>{const{color:t,disableElevation:n,fullWidth:r,size:o,variant:a,classes:i}=e,l={root:["root",a,`${a}${ie(t)}`,`size${ie(o)}`,`${a}Size${ie(o)}`,t==="inherit"&&"colorInherit",n&&"disableElevation",r&&"fullWidth"],label:["label"],startIcon:["startIcon",`iconSize${ie(o)}`],endIcon:["endIcon",`iconSize${ie(o)}`]},c=He(l,DH,i);return I({},i,c)},V$=e=>I({},e.size==="small"&&{"& > *:nth-of-type(1)":{fontSize:18}},e.size==="medium"&&{"& > *:nth-of-type(1)":{fontSize:20}},e.size==="large"&&{"& > *:nth-of-type(1)":{fontSize:22}}),WH=C(Ea,{shouldForwardProp:e=>Bo(e)||e==="classes",name:"MuiButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],t[`${n.variant}${ie(n.color)}`],t[`size${ie(n.size)}`],t[`${n.variant}Size${ie(n.size)}`],n.color==="inherit"&&t.colorInherit,n.disableElevation&&t.disableElevation,n.fullWidth&&t.fullWidth]}})(({theme:e,ownerState:t})=>{var n,r;return I({},e.typography.button,{minWidth:64,padding:"6px 16px",borderRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create(["background-color","box-shadow","border-color","color"],{duration:e.transitions.duration.short}),"&:hover":I({textDecoration:"none",backgroundColor:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(e.palette.text.primary,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},t.variant==="text"&&t.color!=="inherit"&&{backgroundColor:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},t.variant==="outlined"&&t.color!=="inherit"&&{border:`1px solid ${(e.vars||e).palette[t.color].main}`,backgroundColor:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},t.variant==="contained"&&{backgroundColor:(e.vars||e).palette.grey.A100,boxShadow:(e.vars||e).shadows[4],"@media (hover: none)":{boxShadow:(e.vars||e).shadows[2],backgroundColor:(e.vars||e).palette.grey[300]}},t.variant==="contained"&&t.color!=="inherit"&&{backgroundColor:(e.vars||e).palette[t.color].dark,"@media (hover: none)":{backgroundColor:(e.vars||e).palette[t.color].main}}),"&:active":I({},t.variant==="contained"&&{boxShadow:(e.vars||e).shadows[8]}),[`&.${Vf.focusVisible}`]:I({},t.variant==="contained"&&{boxShadow:(e.vars||e).shadows[6]}),[`&.${Vf.disabled}`]:I({color:(e.vars||e).palette.action.disabled},t.variant==="outlined"&&{border:`1px solid ${(e.vars||e).palette.action.disabledBackground}`},t.variant==="contained"&&{color:(e.vars||e).palette.action.disabled,boxShadow:(e.vars||e).shadows[0],backgroundColor:(e.vars||e).palette.action.disabledBackground})},t.variant==="text"&&{padding:"6px 8px"},t.variant==="text"&&t.color!=="inherit"&&{color:(e.vars||e).palette[t.color].main},t.variant==="outlined"&&{padding:"5px 15px",border:"1px solid currentColor"},t.variant==="outlined"&&t.color!=="inherit"&&{color:(e.vars||e).palette[t.color].main,border:e.vars?`1px solid rgba(${e.vars.palette[t.color].mainChannel} / 0.5)`:`1px solid ${Ot(e.palette[t.color].main,.5)}`},t.variant==="contained"&&{color:e.vars?e.vars.palette.text.primary:(n=(r=e.palette).getContrastText)==null?void 0:n.call(r,e.palette.grey[300]),backgroundColor:(e.vars||e).palette.grey[300],boxShadow:(e.vars||e).shadows[2]},t.variant==="contained"&&t.color!=="inherit"&&{color:(e.vars||e).palette[t.color].contrastText,backgroundColor:(e.vars||e).palette[t.color].main},t.color==="inherit"&&{color:"inherit",borderColor:"currentColor"},t.size==="small"&&t.variant==="text"&&{padding:"4px 5px",fontSize:e.typography.pxToRem(13)},t.size==="large"&&t.variant==="text"&&{padding:"8px 11px",fontSize:e.typography.pxToRem(15)},t.size==="small"&&t.variant==="outlined"&&{padding:"3px 9px",fontSize:e.typography.pxToRem(13)},t.size==="large"&&t.variant==="outlined"&&{padding:"7px 21px",fontSize:e.typography.pxToRem(15)},t.size==="small"&&t.variant==="contained"&&{padding:"4px 10px",fontSize:e.typography.pxToRem(13)},t.size==="large"&&t.variant==="contained"&&{padding:"8px 22px",fontSize:e.typography.pxToRem(15)},t.fullWidth&&{width:"100%"})},({ownerState:e})=>e.disableElevation&&{boxShadow:"none","&:hover":{boxShadow:"none"},[`&.${Vf.focusVisible}`]:{boxShadow:"none"},"&:active":{boxShadow:"none"},[`&.${Vf.disabled}`]:{boxShadow:"none"}}),HH=C("span",{name:"MuiButton",slot:"StartIcon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.startIcon,t[`iconSize${ie(n.size)}`]]}})(({ownerState:e})=>I({display:"inherit",marginRight:8,marginLeft:-4},e.size==="small"&&{marginLeft:-2},V$(e))),VH=C("span",{name:"MuiButton",slot:"EndIcon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.endIcon,t[`iconSize${ie(n.size)}`]]}})(({ownerState:e})=>I({display:"inherit",marginRight:-4,marginLeft:8},e.size==="small"&&{marginRight:-2},V$(e))),GH=p.forwardRef(function(t,n){const r=p.useContext(zH),o=TS(r,t),a=Ve({props:o,name:"MuiButton"}),{children:i,color:l="primary",component:c="button",className:u,disabled:d=!1,disableElevation:f=!1,disableFocusRipple:h=!1,endIcon:m,focusVisibleClassName:y,fullWidth:g=!1,size:v="medium",startIcon:b,type:w,variant:x="text"}=a,E=$e(a,jH),A=I({},a,{color:l,component:c,disabled:d,disableElevation:f,disableFocusRipple:h,fullWidth:g,size:v,type:w,variant:x}),k=UH(A),_=b&&s(HH,{className:k.startIcon,ownerState:A,children:b}),$=m&&s(VH,{className:k.endIcon,ownerState:A,children:m});return T(WH,I({ownerState:A,className:ve(r.className,k.root,u),component:c,disabled:d,focusRipple:!h,focusVisibleClassName:ve(k.focusVisible,y),ref:n,type:w},E,{classes:k,children:[_,i,$]}))}),Ze=GH;function qH(e){return je("MuiCard",e)}Ue("MuiCard",["root"]);const KH=["className","raised"],YH=e=>{const{classes:t}=e;return He({root:["root"]},qH,t)},XH=C(pr,{name:"MuiCard",slot:"Root",overridesResolver:(e,t)=>t.root})(()=>({overflow:"hidden"})),JH=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiCard"}),{className:o,raised:a=!1}=r,i=$e(r,KH),l=I({},r,{raised:a}),c=YH(l);return s(XH,I({className:ve(c.root,o),elevation:a?8:void 0,ref:n,ownerState:l},i))}),G$=JH;function QH(e){return je("MuiCardActions",e)}Ue("MuiCardActions",["root","spacing"]);const ZH=["disableSpacing","className"],eV=e=>{const{classes:t,disableSpacing:n}=e;return He({root:["root",!n&&"spacing"]},QH,t)},tV=C("div",{name:"MuiCardActions",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disableSpacing&&t.spacing]}})(({ownerState:e})=>I({display:"flex",alignItems:"center",padding:8},!e.disableSpacing&&{"& > :not(:first-of-type)":{marginLeft:8}})),nV=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiCardActions"}),{disableSpacing:o=!1,className:a}=r,i=$e(r,ZH),l=I({},r,{disableSpacing:o}),c=eV(l);return s(tV,I({className:ve(c.root,a),ownerState:l,ref:n},i))}),rV=nV;function oV(e){return je("PrivateSwitchBase",e)}Ue("PrivateSwitchBase",["root","checked","disabled","input","edgeStart","edgeEnd"]);const aV=["autoFocus","checked","checkedIcon","className","defaultChecked","disabled","disableFocusRipple","edge","icon","id","inputProps","inputRef","name","onBlur","onChange","onFocus","readOnly","required","tabIndex","type","value"],iV=e=>{const{classes:t,checked:n,disabled:r,edge:o}=e,a={root:["root",n&&"checked",r&&"disabled",o&&`edge${ie(o)}`],input:["input"]};return He(a,oV,t)},sV=C(Ea)(({ownerState:e})=>I({padding:9,borderRadius:"50%"},e.edge==="start"&&{marginLeft:e.size==="small"?-3:-12},e.edge==="end"&&{marginRight:e.size==="small"?-3:-12})),lV=C("input")({cursor:"inherit",position:"absolute",opacity:0,width:"100%",height:"100%",top:0,left:0,margin:0,padding:0,zIndex:1}),cV=p.forwardRef(function(t,n){const{autoFocus:r,checked:o,checkedIcon:a,className:i,defaultChecked:l,disabled:c,disableFocusRipple:u=!1,edge:d=!1,icon:f,id:h,inputProps:m,inputRef:y,name:g,onBlur:v,onChange:b,onFocus:w,readOnly:x,required:E=!1,tabIndex:A,type:k,value:_}=t,$=$e(t,aV),[L,O]=Sa({controlled:o,default:Boolean(l),name:"SwitchBase",state:"checked"}),P=oi(),D=W=>{w&&w(W),P&&P.onFocus&&P.onFocus(W)},F=W=>{v&&v(W),P&&P.onBlur&&P.onBlur(W)},U=W=>{if(W.nativeEvent.defaultPrevented)return;const z=W.target.checked;O(z),b&&b(W,z)};let Y=c;P&&typeof Y>"u"&&(Y=P.disabled);const V=k==="checkbox"||k==="radio",te=I({},t,{checked:L,disabled:Y,disableFocusRipple:u,edge:d}),Z=iV(te);return T(sV,I({component:"span",className:ve(Z.root,i),centerRipple:!0,focusRipple:!u,disabled:Y,tabIndex:null,role:void 0,onFocus:D,onBlur:F,ownerState:te,ref:n},$,{children:[s(lV,I({autoFocus:r,checked:o,defaultChecked:l,className:Z.input,disabled:Y,id:V?h:void 0,name:g,onChange:U,readOnly:x,ref:y,required:E,ownerState:te,tabIndex:A,type:k},k==="checkbox"&&_===void 0?{}:{value:_},m)),L?a:f]}))}),lx=cV,uV=Ye(s("path",{d:"M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"}),"CheckBoxOutlineBlank"),dV=Ye(s("path",{d:"M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"}),"CheckBox"),pV=Ye(s("path",{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10H7v-2h10v2z"}),"IndeterminateCheckBox");function fV(e){return je("MuiCheckbox",e)}const hV=Ue("MuiCheckbox",["root","checked","disabled","indeterminate","colorPrimary","colorSecondary"]),d1=hV,mV=["checkedIcon","color","icon","indeterminate","indeterminateIcon","inputProps","size","className"],gV=e=>{const{classes:t,indeterminate:n,color:r}=e,o={root:["root",n&&"indeterminate",`color${ie(r)}`]},a=He(o,fV,t);return I({},t,a)},vV=C(lx,{shouldForwardProp:e=>Bo(e)||e==="classes",name:"MuiCheckbox",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.indeterminate&&t.indeterminate,n.color!=="default"&&t[`color${ie(n.color)}`]]}})(({theme:e,ownerState:t})=>I({color:(e.vars||e).palette.text.secondary},!t.disableRipple&&{"&:hover":{backgroundColor:e.vars?`rgba(${t.color==="default"?e.vars.palette.action.activeChannel:e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(t.color==="default"?e.palette.action.active:e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},t.color!=="default"&&{[`&.${d1.checked}, &.${d1.indeterminate}`]:{color:(e.vars||e).palette[t.color].main},[`&.${d1.disabled}`]:{color:(e.vars||e).palette.action.disabled}})),yV=s(dV,{}),bV=s(uV,{}),wV=s(pV,{}),SV=p.forwardRef(function(t,n){var r,o;const a=Ve({props:t,name:"MuiCheckbox"}),{checkedIcon:i=yV,color:l="primary",icon:c=bV,indeterminate:u=!1,indeterminateIcon:d=wV,inputProps:f,size:h="medium",className:m}=a,y=$e(a,mV),g=u?d:c,v=u?d:i,b=I({},a,{color:l,indeterminate:u,size:h}),w=gV(b);return s(vV,I({type:"checkbox",inputProps:I({"data-indeterminate":u},f),icon:p.cloneElement(g,{fontSize:(r=g.props.fontSize)!=null?r:h}),checkedIcon:p.cloneElement(v,{fontSize:(o=v.props.fontSize)!=null?o:h}),ownerState:b,ref:n,className:ve(w.root,m)},y,{classes:w}))}),Rs=SV;function xV(e){return je("MuiCircularProgress",e)}Ue("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const CV=["className","color","disableShrink","size","style","thickness","value","variant"];let sv=e=>e,hk,mk,gk,vk;const zi=44,EV=ks(hk||(hk=sv`
|
|
165
|
+
0% {
|
|
166
|
+
transform: rotate(0deg);
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
100% {
|
|
170
|
+
transform: rotate(360deg);
|
|
171
|
+
}
|
|
172
|
+
`)),TV=ks(mk||(mk=sv`
|
|
173
|
+
0% {
|
|
174
|
+
stroke-dasharray: 1px, 200px;
|
|
175
|
+
stroke-dashoffset: 0;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
50% {
|
|
179
|
+
stroke-dasharray: 100px, 200px;
|
|
180
|
+
stroke-dashoffset: -15px;
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
100% {
|
|
184
|
+
stroke-dasharray: 100px, 200px;
|
|
185
|
+
stroke-dashoffset: -125px;
|
|
186
|
+
}
|
|
187
|
+
`)),kV=e=>{const{classes:t,variant:n,color:r,disableShrink:o}=e,a={root:["root",n,`color${ie(r)}`],svg:["svg"],circle:["circle",`circle${ie(n)}`,o&&"circleDisableShrink"]};return He(a,xV,t)},AV=C("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],t[`color${ie(n.color)}`]]}})(({ownerState:e,theme:t})=>I({display:"inline-block"},e.variant==="determinate"&&{transition:t.transitions.create("transform")},e.color!=="inherit"&&{color:(t.vars||t).palette[e.color].main}),({ownerState:e})=>e.variant==="indeterminate"&&ou(gk||(gk=sv`
|
|
188
|
+
animation: ${0} 1.4s linear infinite;
|
|
189
|
+
`),EV)),_V=C("svg",{name:"MuiCircularProgress",slot:"Svg",overridesResolver:(e,t)=>t.svg})({display:"block"}),RV=C("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.circle,t[`circle${ie(n.variant)}`],n.disableShrink&&t.circleDisableShrink]}})(({ownerState:e,theme:t})=>I({stroke:"currentColor"},e.variant==="determinate"&&{transition:t.transitions.create("stroke-dashoffset")},e.variant==="indeterminate"&&{strokeDasharray:"80px, 200px",strokeDashoffset:0}),({ownerState:e})=>e.variant==="indeterminate"&&!e.disableShrink&&ou(vk||(vk=sv`
|
|
190
|
+
animation: ${0} 1.4s ease-in-out infinite;
|
|
191
|
+
`),TV)),PV=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiCircularProgress"}),{className:o,color:a="primary",disableShrink:i=!1,size:l=40,style:c,thickness:u=3.6,value:d=0,variant:f="indeterminate"}=r,h=$e(r,CV),m=I({},r,{color:a,disableShrink:i,size:l,thickness:u,value:d,variant:f}),y=kV(m),g={},v={},b={};if(f==="determinate"){const w=2*Math.PI*((zi-u)/2);g.strokeDasharray=w.toFixed(3),b["aria-valuenow"]=Math.round(d),g.strokeDashoffset=`${((100-d)/100*w).toFixed(3)}px`,v.transform="rotate(-90deg)"}return s(AV,I({className:ve(y.root,o),style:I({width:l,height:l},v,c),ownerState:m,ref:n,role:"progressbar"},b,h,{children:s(_V,{className:y.svg,ownerState:m,viewBox:`${zi/2} ${zi/2} ${zi} ${zi}`,children:s(RV,{className:y.circle,style:g,ownerState:m,cx:zi,cy:zi,r:(zi-u)/2,fill:"none",strokeWidth:u})})}))}),IV=PV,$V=j7({createStyledComponent:C("div",{name:"MuiContainer",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`maxWidth${ie(String(n.maxWidth))}`],n.fixed&&t.fixed,n.disableGutters&&t.disableGutters]}}),useThemeProps:e=>Ve({props:e,name:"MuiContainer"})}),OV=$V,LV=(e,t)=>I({WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",boxSizing:"border-box",WebkitTextSizeAdjust:"100%"},t&&!e.vars&&{colorScheme:e.palette.mode}),NV=e=>I({color:(e.vars||e).palette.text.primary},e.typography.body1,{backgroundColor:(e.vars||e).palette.background.default,"@media print":{backgroundColor:(e.vars||e).palette.common.white}}),MV=(e,t=!1)=>{var n,r;const o={};t&&e.colorSchemes&&Object.entries(e.colorSchemes).forEach(([l,c])=>{var u;o[e.getColorSchemeSelector(l).replace(/\s*&/,"")]={colorScheme:(u=c.palette)==null?void 0:u.mode}});let a=I({html:LV(e,t),"*, *::before, *::after":{boxSizing:"inherit"},"strong, b":{fontWeight:e.typography.fontWeightBold},body:I({margin:0},NV(e),{"&::backdrop":{backgroundColor:(e.vars||e).palette.background.default}})},o);const i=(n=e.components)==null||(r=n.MuiCssBaseline)==null?void 0:r.styleOverrides;return i&&(a=[a,i]),a};function DV(e){const t=Ve({props:e,name:"MuiCssBaseline"}),{children:n,enableColorScheme:r=!1}=t;return T(p.Fragment,{children:[s(W$,{styles:o=>MV(o,r)}),n]})}const BV=["BackdropComponent","BackdropProps","closeAfterTransition","children","component","components","componentsProps","disableAutoFocus","disableEnforceFocus","disableEscapeKeyDown","disablePortal","disableRestoreFocus","disableScrollLock","hideBackdrop","keepMounted","slotProps","slots","theme"],FV=e=>e.classes,zV=C("div",{name:"MuiModal",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.open&&n.exited&&t.hidden]}})(({theme:e,ownerState:t})=>I({position:"fixed",zIndex:(e.vars||e).zIndex.modal,right:0,bottom:0,top:0,left:0},!t.open&&t.exited&&{visibility:"hidden"})),jV=C(sx,{name:"MuiModal",slot:"Backdrop",overridesResolver:(e,t)=>t.backdrop})({zIndex:-1}),UV=p.forwardRef(function(t,n){var r,o,a,i,l,c;const u=Ve({name:"MuiModal",props:t}),{BackdropComponent:d=jV,BackdropProps:f,closeAfterTransition:h=!1,children:m,component:y,components:g={},componentsProps:v={},disableAutoFocus:b=!1,disableEnforceFocus:w=!1,disableEscapeKeyDown:x=!1,disablePortal:E=!1,disableRestoreFocus:A=!1,disableScrollLock:k=!1,hideBackdrop:_=!1,keepMounted:$=!1,slotProps:L,slots:O,theme:P}=u,D=$e(u,BV),[F,U]=p.useState(!0),Y={closeAfterTransition:h,disableAutoFocus:b,disableEnforceFocus:w,disableEscapeKeyDown:x,disablePortal:E,disableRestoreFocus:A,disableScrollLock:k,hideBackdrop:_,keepMounted:$},V=I({},u,Y,{exited:F}),te=FV(V),Z=(r=(o=O==null?void 0:O.root)!=null?o:g.Root)!=null?r:zV,W=(a=(i=O==null?void 0:O.backdrop)!=null?i:g.Backdrop)!=null?a:d,z=(l=L==null?void 0:L.root)!=null?l:v.root,R=(c=L==null?void 0:L.backdrop)!=null?c:v.backdrop;return s(ij,I({slots:{root:Z,backdrop:W},slotProps:{root:()=>I({},vb(z,V),!qa(Z)&&{as:y,theme:P}),backdrop:()=>I({},f,vb(R,V))},onTransitionEnter:()=>U(!1),onTransitionExited:()=>U(!0),ref:n},D,{classes:te},Y,{children:m}))}),Kp=UV;function WV(e){return je("MuiDialog",e)}const HV=Ue("MuiDialog",["root","scrollPaper","scrollBody","container","paper","paperScrollPaper","paperScrollBody","paperWidthFalse","paperWidthXs","paperWidthSm","paperWidthMd","paperWidthLg","paperWidthXl","paperFullWidth","paperFullScreen"]),p1=HV,VV=p.createContext({}),q$=VV,GV=["aria-describedby","aria-labelledby","BackdropComponent","BackdropProps","children","className","disableEscapeKeyDown","fullScreen","fullWidth","maxWidth","onBackdropClick","onClose","open","PaperComponent","PaperProps","scroll","TransitionComponent","transitionDuration","TransitionProps"],qV=C(sx,{name:"MuiDialog",slot:"Backdrop",overrides:(e,t)=>t.backdrop})({zIndex:-1}),KV=e=>{const{classes:t,scroll:n,maxWidth:r,fullWidth:o,fullScreen:a}=e,i={root:["root"],container:["container",`scroll${ie(n)}`],paper:["paper",`paperScroll${ie(n)}`,`paperWidth${ie(String(r))}`,o&&"paperFullWidth",a&&"paperFullScreen"]};return He(i,WV,t)},YV=C(Kp,{name:"MuiDialog",slot:"Root",overridesResolver:(e,t)=>t.root})({"@media print":{position:"absolute !important"}}),XV=C("div",{name:"MuiDialog",slot:"Container",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.container,t[`scroll${ie(n.scroll)}`]]}})(({ownerState:e})=>I({height:"100%","@media print":{height:"auto"},outline:0},e.scroll==="paper"&&{display:"flex",justifyContent:"center",alignItems:"center"},e.scroll==="body"&&{overflowY:"auto",overflowX:"hidden",textAlign:"center","&:after":{content:'""',display:"inline-block",verticalAlign:"middle",height:"100%",width:"0"}})),JV=C(pr,{name:"MuiDialog",slot:"Paper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.paper,t[`scrollPaper${ie(n.scroll)}`],t[`paperWidth${ie(String(n.maxWidth))}`],n.fullWidth&&t.paperFullWidth,n.fullScreen&&t.paperFullScreen]}})(({theme:e,ownerState:t})=>I({margin:32,position:"relative",overflowY:"auto","@media print":{overflowY:"visible",boxShadow:"none"}},t.scroll==="paper"&&{display:"flex",flexDirection:"column",maxHeight:"calc(100% - 64px)"},t.scroll==="body"&&{display:"inline-block",verticalAlign:"middle",textAlign:"left"},!t.maxWidth&&{maxWidth:"calc(100% - 64px)"},t.maxWidth==="xs"&&{maxWidth:e.breakpoints.unit==="px"?Math.max(e.breakpoints.values.xs,444):`${e.breakpoints.values.xs}${e.breakpoints.unit}`,[`&.${p1.paperScrollBody}`]:{[e.breakpoints.down(Math.max(e.breakpoints.values.xs,444)+32*2)]:{maxWidth:"calc(100% - 64px)"}}},t.maxWidth&&t.maxWidth!=="xs"&&{maxWidth:`${e.breakpoints.values[t.maxWidth]}${e.breakpoints.unit}`,[`&.${p1.paperScrollBody}`]:{[e.breakpoints.down(e.breakpoints.values[t.maxWidth]+32*2)]:{maxWidth:"calc(100% - 64px)"}}},t.fullWidth&&{width:"calc(100% - 64px)"},t.fullScreen&&{margin:0,width:"100%",maxWidth:"100%",height:"100%",maxHeight:"none",borderRadius:0,[`&.${p1.paperScrollBody}`]:{margin:0,maxWidth:"100%"}})),QV=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiDialog"}),o=on(),a={enter:o.transitions.duration.enteringScreen,exit:o.transitions.duration.leavingScreen},{"aria-describedby":i,"aria-labelledby":l,BackdropComponent:c,BackdropProps:u,children:d,className:f,disableEscapeKeyDown:h=!1,fullScreen:m=!1,fullWidth:y=!1,maxWidth:g="sm",onBackdropClick:v,onClose:b,open:w,PaperComponent:x=pr,PaperProps:E={},scroll:A="paper",TransitionComponent:k=ix,transitionDuration:_=a,TransitionProps:$}=r,L=$e(r,GV),O=I({},r,{disableEscapeKeyDown:h,fullScreen:m,fullWidth:y,maxWidth:g,scroll:A}),P=KV(O),D=p.useRef(),F=te=>{D.current=te.target===te.currentTarget},U=te=>{D.current&&(D.current=null,v&&v(te),b&&b(te,"backdropClick"))},Y=nu(l),V=p.useMemo(()=>({titleId:Y}),[Y]);return s(YV,I({className:ve(P.root,f),closeAfterTransition:!0,components:{Backdrop:qV},componentsProps:{backdrop:I({transitionDuration:_,as:c},u)},disableEscapeKeyDown:h,onClose:b,open:w,ref:n,onClick:U,ownerState:O},L,{children:s(k,I({appear:!0,in:w,timeout:_,role:"presentation"},$,{children:s(XV,{className:ve(P.container),onMouseDown:F,ownerState:O,children:s(JV,I({as:x,elevation:24,role:"dialog","aria-describedby":i,"aria-labelledby":Y},E,{className:ve(P.paper,E.className),ownerState:O,children:s(q$.Provider,{value:V,children:d})}))})}))}))}),ZV=QV;function eG(e){return je("MuiDialogActions",e)}Ue("MuiDialogActions",["root","spacing"]);const tG=["className","disableSpacing"],nG=e=>{const{classes:t,disableSpacing:n}=e;return He({root:["root",!n&&"spacing"]},eG,t)},rG=C("div",{name:"MuiDialogActions",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disableSpacing&&t.spacing]}})(({ownerState:e})=>I({display:"flex",alignItems:"center",padding:8,justifyContent:"flex-end",flex:"0 0 auto"},!e.disableSpacing&&{"& > :not(:first-of-type)":{marginLeft:8}})),oG=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiDialogActions"}),{className:o,disableSpacing:a=!1}=r,i=$e(r,tG),l=I({},r,{disableSpacing:a}),c=nG(l);return s(rG,I({className:ve(c.root,o),ownerState:l,ref:n},i))}),aG=oG;function iG(e){return je("MuiDialogContent",e)}Ue("MuiDialogContent",["root","dividers"]);function sG(e){return je("MuiDialogTitle",e)}const lG=Ue("MuiDialogTitle",["root"]),cG=lG,uG=["className","dividers"],dG=e=>{const{classes:t,dividers:n}=e;return He({root:["root",n&&"dividers"]},iG,t)},pG=C("div",{name:"MuiDialogContent",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.dividers&&t.dividers]}})(({theme:e,ownerState:t})=>I({flex:"1 1 auto",WebkitOverflowScrolling:"touch",overflowY:"auto",padding:"20px 24px"},t.dividers?{padding:"16px 24px",borderTop:`1px solid ${(e.vars||e).palette.divider}`,borderBottom:`1px solid ${(e.vars||e).palette.divider}`}:{[`.${cG.root} + &`]:{paddingTop:0}})),fG=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiDialogContent"}),{className:o,dividers:a=!1}=r,i=$e(r,uG),l=I({},r,{dividers:a}),c=dG(l);return s(pG,I({className:ve(c.root,o),ownerState:l,ref:n},i))}),hG=fG,mG=["className","id"],gG=e=>{const{classes:t}=e;return He({root:["root"]},sG,t)},vG=C(ye,{name:"MuiDialogTitle",slot:"Root",overridesResolver:(e,t)=>t.root})({padding:"16px 24px",flex:"0 0 auto"}),yG=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiDialogTitle"}),{className:o,id:a}=r,i=$e(r,mG),l=r,c=gG(l),{titleId:u=a}=p.useContext(q$);return s(vG,I({component:"h2",className:ve(c.root,o),ownerState:l,ref:n,variant:"h6",id:u},i))}),bG=yG;function wG(e){return je("MuiDivider",e)}const SG=Ue("MuiDivider",["root","absolute","fullWidth","inset","middle","flexItem","light","vertical","withChildren","withChildrenVertical","textAlignRight","textAlignLeft","wrapper","wrapperVertical"]),yk=SG,xG=["absolute","children","className","component","flexItem","light","orientation","role","textAlign","variant"],CG=e=>{const{absolute:t,children:n,classes:r,flexItem:o,light:a,orientation:i,textAlign:l,variant:c}=e;return He({root:["root",t&&"absolute",c,a&&"light",i==="vertical"&&"vertical",o&&"flexItem",n&&"withChildren",n&&i==="vertical"&&"withChildrenVertical",l==="right"&&i!=="vertical"&&"textAlignRight",l==="left"&&i!=="vertical"&&"textAlignLeft"],wrapper:["wrapper",i==="vertical"&&"wrapperVertical"]},wG,r)},EG=C("div",{name:"MuiDivider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.absolute&&t.absolute,t[n.variant],n.light&&t.light,n.orientation==="vertical"&&t.vertical,n.flexItem&&t.flexItem,n.children&&t.withChildren,n.children&&n.orientation==="vertical"&&t.withChildrenVertical,n.textAlign==="right"&&n.orientation!=="vertical"&&t.textAlignRight,n.textAlign==="left"&&n.orientation!=="vertical"&&t.textAlignLeft]}})(({theme:e,ownerState:t})=>I({margin:0,flexShrink:0,borderWidth:0,borderStyle:"solid",borderColor:(e.vars||e).palette.divider,borderBottomWidth:"thin"},t.absolute&&{position:"absolute",bottom:0,left:0,width:"100%"},t.light&&{borderColor:e.vars?`rgba(${e.vars.palette.dividerChannel} / 0.08)`:Ot(e.palette.divider,.08)},t.variant==="inset"&&{marginLeft:72},t.variant==="middle"&&t.orientation==="horizontal"&&{marginLeft:e.spacing(2),marginRight:e.spacing(2)},t.variant==="middle"&&t.orientation==="vertical"&&{marginTop:e.spacing(1),marginBottom:e.spacing(1)},t.orientation==="vertical"&&{height:"100%",borderBottomWidth:0,borderRightWidth:"thin"},t.flexItem&&{alignSelf:"stretch",height:"auto"}),({theme:e,ownerState:t})=>I({},t.children&&{display:"flex",whiteSpace:"nowrap",textAlign:"center",border:0,"&::before, &::after":{position:"relative",width:"100%",borderTop:`thin solid ${(e.vars||e).palette.divider}`,top:"50%",content:'""',transform:"translateY(50%)"}}),({theme:e,ownerState:t})=>I({},t.children&&t.orientation==="vertical"&&{flexDirection:"column","&::before, &::after":{height:"100%",top:"0%",left:"50%",borderTop:0,borderLeft:`thin solid ${(e.vars||e).palette.divider}`,transform:"translateX(0%)"}}),({ownerState:e})=>I({},e.textAlign==="right"&&e.orientation!=="vertical"&&{"&::before":{width:"90%"},"&::after":{width:"10%"}},e.textAlign==="left"&&e.orientation!=="vertical"&&{"&::before":{width:"10%"},"&::after":{width:"90%"}})),TG=C("span",{name:"MuiDivider",slot:"Wrapper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.wrapper,n.orientation==="vertical"&&t.wrapperVertical]}})(({theme:e,ownerState:t})=>I({display:"inline-block",paddingLeft:`calc(${e.spacing(1)} * 1.2)`,paddingRight:`calc(${e.spacing(1)} * 1.2)`},t.orientation==="vertical"&&{paddingTop:`calc(${e.spacing(1)} * 1.2)`,paddingBottom:`calc(${e.spacing(1)} * 1.2)`})),kG=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiDivider"}),{absolute:o=!1,children:a,className:i,component:l=a?"div":"hr",flexItem:c=!1,light:u=!1,orientation:d="horizontal",role:f=l!=="hr"?"separator":void 0,textAlign:h="center",variant:m="fullWidth"}=r,y=$e(r,xG),g=I({},r,{absolute:o,component:l,flexItem:c,light:u,orientation:d,role:f,textAlign:h,variant:m}),v=CG(g);return s(EG,I({as:l,className:ve(v.root,i),role:f,ref:n,ownerState:g},y,{children:a?s(TG,{className:v.wrapper,ownerState:g,children:a}):null}))}),mo=kG,AG=["addEndListener","appear","children","container","direction","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function _G(e,t,n){const r=t.getBoundingClientRect(),o=n&&n.getBoundingClientRect(),a=ta(t);let i;if(t.fakeTransform)i=t.fakeTransform;else{const u=a.getComputedStyle(t);i=u.getPropertyValue("-webkit-transform")||u.getPropertyValue("transform")}let l=0,c=0;if(i&&i!=="none"&&typeof i=="string"){const u=i.split("(")[1].split(")")[0].split(",");l=parseInt(u[4],10),c=parseInt(u[5],10)}return e==="left"?o?`translateX(${o.right+l-r.left}px)`:`translateX(${a.innerWidth+l-r.left}px)`:e==="right"?o?`translateX(-${r.right-o.left-l}px)`:`translateX(-${r.left+r.width-l}px)`:e==="up"?o?`translateY(${o.bottom+c-r.top}px)`:`translateY(${a.innerHeight+c-r.top}px)`:o?`translateY(-${r.top-o.top+r.height-c}px)`:`translateY(-${r.top+r.height-c}px)`}function RG(e){return typeof e=="function"?e():e}function Gf(e,t,n){const r=RG(n),o=_G(e,t,r);o&&(t.style.webkitTransform=o,t.style.transform=o)}const PG=p.forwardRef(function(t,n){const r=on(),o={enter:r.transitions.easing.easeOut,exit:r.transitions.easing.sharp},a={enter:r.transitions.duration.enteringScreen,exit:r.transitions.duration.leavingScreen},{addEndListener:i,appear:l=!0,children:c,container:u,direction:d="down",easing:f=o,in:h,onEnter:m,onEntered:y,onEntering:g,onExit:v,onExited:b,onExiting:w,style:x,timeout:E=a,TransitionComponent:A=Xg}=t,k=$e(t,AG),_=p.useRef(null),$=Sn(c.ref,_,n),L=Z=>W=>{Z&&(W===void 0?Z(_.current):Z(_.current,W))},O=L((Z,W)=>{Gf(d,Z,u),tx(Z),m&&m(Z,W)}),P=L((Z,W)=>{const z=ys({timeout:E,style:x,easing:f},{mode:"enter"});Z.style.webkitTransition=r.transitions.create("-webkit-transform",I({},z)),Z.style.transition=r.transitions.create("transform",I({},z)),Z.style.webkitTransform="none",Z.style.transform="none",g&&g(Z,W)}),D=L(y),F=L(w),U=L(Z=>{const W=ys({timeout:E,style:x,easing:f},{mode:"exit"});Z.style.webkitTransition=r.transitions.create("-webkit-transform",W),Z.style.transition=r.transitions.create("transform",W),Gf(d,Z,u),v&&v(Z)}),Y=L(Z=>{Z.style.webkitTransition="",Z.style.transition="",b&&b(Z)}),V=Z=>{i&&i(_.current,Z)},te=p.useCallback(()=>{_.current&&Gf(d,_.current,u)},[d,u]);return p.useEffect(()=>{if(h||d==="down"||d==="right")return;const Z=ml(()=>{_.current&&Gf(d,_.current,u)}),W=ta(_.current);return W.addEventListener("resize",Z),()=>{Z.clear(),W.removeEventListener("resize",Z)}},[d,h,u]),p.useEffect(()=>{h||te()},[h,te]),s(A,I({nodeRef:_,onEnter:O,onEntered:D,onEntering:P,onExit:U,onExited:Y,onExiting:F,addEndListener:V,appear:l,in:h,timeout:E},k,{children:(Z,W)=>p.cloneElement(c,I({ref:$,style:I({visibility:Z==="exited"&&!h?"hidden":void 0},x,c.props.style)},W))}))}),IG=PG;function $G(e){return je("MuiDrawer",e)}Ue("MuiDrawer",["root","docked","paper","paperAnchorLeft","paperAnchorRight","paperAnchorTop","paperAnchorBottom","paperAnchorDockedLeft","paperAnchorDockedRight","paperAnchorDockedTop","paperAnchorDockedBottom","modal"]);const OG=["BackdropProps"],LG=["anchor","BackdropProps","children","className","elevation","hideBackdrop","ModalProps","onClose","open","PaperProps","SlideProps","TransitionComponent","transitionDuration","variant"],K$=(e,t)=>{const{ownerState:n}=e;return[t.root,(n.variant==="permanent"||n.variant==="persistent")&&t.docked,t.modal]},NG=e=>{const{classes:t,anchor:n,variant:r}=e,o={root:["root"],docked:[(r==="permanent"||r==="persistent")&&"docked"],modal:["modal"],paper:["paper",`paperAnchor${ie(n)}`,r!=="temporary"&&`paperAnchorDocked${ie(n)}`]};return He(o,$G,t)},MG=C(Kp,{name:"MuiDrawer",slot:"Root",overridesResolver:K$})(({theme:e})=>({zIndex:(e.vars||e).zIndex.drawer})),bk=C("div",{shouldForwardProp:Bo,name:"MuiDrawer",slot:"Docked",skipVariantsResolver:!1,overridesResolver:K$})({flex:"0 0 auto"}),DG=C(pr,{name:"MuiDrawer",slot:"Paper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.paper,t[`paperAnchor${ie(n.anchor)}`],n.variant!=="temporary"&&t[`paperAnchorDocked${ie(n.anchor)}`]]}})(({theme:e,ownerState:t})=>I({overflowY:"auto",display:"flex",flexDirection:"column",height:"100%",flex:"1 0 auto",zIndex:(e.vars||e).zIndex.drawer,WebkitOverflowScrolling:"touch",position:"fixed",top:0,outline:0},t.anchor==="left"&&{left:0},t.anchor==="top"&&{top:0,left:0,right:0,height:"auto",maxHeight:"100%"},t.anchor==="right"&&{right:0},t.anchor==="bottom"&&{top:"auto",left:0,bottom:0,right:0,height:"auto",maxHeight:"100%"},t.anchor==="left"&&t.variant!=="temporary"&&{borderRight:`1px solid ${(e.vars||e).palette.divider}`},t.anchor==="top"&&t.variant!=="temporary"&&{borderBottom:`1px solid ${(e.vars||e).palette.divider}`},t.anchor==="right"&&t.variant!=="temporary"&&{borderLeft:`1px solid ${(e.vars||e).palette.divider}`},t.anchor==="bottom"&&t.variant!=="temporary"&&{borderTop:`1px solid ${(e.vars||e).palette.divider}`})),Y$={left:"right",right:"left",top:"down",bottom:"up"};function BG(e){return["left","right"].indexOf(e)!==-1}function FG(e,t){return e.direction==="rtl"&&BG(t)?Y$[t]:t}const zG=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiDrawer"}),o=on(),a={enter:o.transitions.duration.enteringScreen,exit:o.transitions.duration.leavingScreen},{anchor:i="left",BackdropProps:l,children:c,className:u,elevation:d=16,hideBackdrop:f=!1,ModalProps:{BackdropProps:h}={},onClose:m,open:y=!1,PaperProps:g={},SlideProps:v,TransitionComponent:b=IG,transitionDuration:w=a,variant:x="temporary"}=r,E=$e(r.ModalProps,OG),A=$e(r,LG),k=p.useRef(!1);p.useEffect(()=>{k.current=!0},[]);const _=FG(o,i),L=I({},r,{anchor:i,elevation:d,open:y,variant:x},A),O=NG(L),P=s(DG,I({elevation:x==="temporary"?d:0,square:!0},g,{className:ve(O.paper,g.className),ownerState:L,children:c}));if(x==="permanent")return s(bk,I({className:ve(O.root,O.docked,u),ownerState:L,ref:n},A,{children:P}));const D=s(b,I({in:y,direction:Y$[_],timeout:w,appear:k.current},v,{children:P}));return x==="persistent"?s(bk,I({className:ve(O.root,O.docked,u),ownerState:L,ref:n},A,{children:D})):s(MG,I({BackdropProps:I({},l,h,{transitionDuration:w}),className:ve(O.root,O.modal,u),open:y,ownerState:L,onClose:m,hideBackdrop:f,ref:n},A,E,{children:D}))}),jG=zG,UG=["disableUnderline","components","componentsProps","fullWidth","hiddenLabel","inputComponent","multiline","slotProps","slots","type"],WG=e=>{const{classes:t,disableUnderline:n}=e,o=He({root:["root",!n&&"underline"],input:["input"]},FW,t);return I({},t,o)},HG=C(nv,{shouldForwardProp:e=>Bo(e)||e==="classes",name:"MuiFilledInput",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[...ev(e,t),!n.disableUnderline&&t.underline]}})(({theme:e,ownerState:t})=>{var n;const r=e.palette.mode==="light",o=r?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",a=r?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",i=r?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",l=r?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return I({position:"relative",backgroundColor:e.vars?e.vars.palette.FilledInput.bg:a,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:i,"@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:a}},[`&.${Co.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:a},[`&.${Co.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:l}},!t.disableUnderline&&{"&:after":{borderBottom:`2px solid ${(n=(e.vars||e).palette[t.color||"primary"])==null?void 0:n.main}`,left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Co.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Co.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&:before":{borderBottom:`1px solid ${e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`:o}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Co.disabled}, .${Co.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${Co.disabled}:before`]:{borderBottomStyle:"dotted"}},t.startAdornment&&{paddingLeft:12},t.endAdornment&&{paddingRight:12},t.multiline&&I({padding:"25px 12px 8px"},t.size==="small"&&{paddingTop:21,paddingBottom:4},t.hiddenLabel&&{paddingTop:16,paddingBottom:17}))}),VG=C(rv,{name:"MuiFilledInput",slot:"Input",overridesResolver:tv})(({theme:e,ownerState:t})=>I({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12},!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"}},e.vars&&{"&:-webkit-autofill":{borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},t.size==="small"&&{paddingTop:21,paddingBottom:4},t.hiddenLabel&&{paddingTop:16,paddingBottom:17},t.multiline&&{paddingTop:0,paddingBottom:0,paddingLeft:0,paddingRight:0},t.startAdornment&&{paddingLeft:0},t.endAdornment&&{paddingRight:0},t.hiddenLabel&&t.size==="small"&&{paddingTop:8,paddingBottom:9})),X$=p.forwardRef(function(t,n){var r,o,a,i;const l=Ve({props:t,name:"MuiFilledInput"}),{components:c={},componentsProps:u,fullWidth:d=!1,inputComponent:f="input",multiline:h=!1,slotProps:m,slots:y={},type:g="text"}=l,v=$e(l,UG),b=I({},l,{fullWidth:d,inputComponent:f,multiline:h,type:g}),w=WG(l),x={root:{ownerState:b},input:{ownerState:b}},E=m??u?Ro(m??u,x):x,A=(r=(o=y.root)!=null?o:c.Root)!=null?r:HG,k=(a=(i=y.input)!=null?i:c.Input)!=null?a:VG;return s(ov,I({slots:{root:A,input:k},componentsProps:E,fullWidth:d,inputComponent:f,multiline:h,ref:n,type:g},v,{classes:w}))});X$.muiName="Input";const J$=X$;function GG(e){return je("MuiFormControl",e)}Ue("MuiFormControl",["root","marginNone","marginNormal","marginDense","fullWidth","disabled"]);const qG=["children","className","color","component","disabled","error","focused","fullWidth","hiddenLabel","margin","required","size","variant"],KG=e=>{const{classes:t,margin:n,fullWidth:r}=e,o={root:["root",n!=="none"&&`margin${ie(n)}`,r&&"fullWidth"]};return He(o,GG,t)},YG=C("div",{name:"MuiFormControl",slot:"Root",overridesResolver:({ownerState:e},t)=>I({},t.root,t[`margin${ie(e.margin)}`],e.fullWidth&&t.fullWidth)})(({ownerState:e})=>I({display:"inline-flex",flexDirection:"column",position:"relative",minWidth:0,padding:0,margin:0,border:0,verticalAlign:"top"},e.margin==="normal"&&{marginTop:16,marginBottom:8},e.margin==="dense"&&{marginTop:8,marginBottom:4},e.fullWidth&&{width:"100%"})),XG=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiFormControl"}),{children:o,className:a,color:i="primary",component:l="div",disabled:c=!1,error:u=!1,focused:d,fullWidth:f=!1,hiddenLabel:h=!1,margin:m="none",required:y=!1,size:g="medium",variant:v="outlined"}=r,b=$e(r,qG),w=I({},r,{color:i,component:l,disabled:c,error:u,fullWidth:f,hiddenLabel:h,margin:m,required:y,size:g,variant:v}),x=KG(w),[E,A]=p.useState(()=>{let F=!1;return o&&p.Children.forEach(o,U=>{if(!Id(U,["Input","Select"]))return;const Y=Id(U,["Select"])?U.props.input:U;Y&&_W(Y.props)&&(F=!0)}),F}),[k,_]=p.useState(()=>{let F=!1;return o&&p.Children.forEach(o,U=>{Id(U,["Input","Select"])&&ax(U.props,!0)&&(F=!0)}),F}),[$,L]=p.useState(!1);c&&$&&L(!1);const O=d!==void 0&&!c?d:$;let P;const D=p.useMemo(()=>({adornedStart:E,setAdornedStart:A,color:i,disabled:c,error:u,filled:k,focused:O,fullWidth:f,hiddenLabel:h,size:g,onBlur:()=>{L(!1)},onEmpty:()=>{_(!1)},onFilled:()=>{_(!0)},onFocus:()=>{L(!0)},registerEffect:P,required:y,variant:v}),[E,i,c,u,k,O,f,h,P,y,g,v]);return s(Zg.Provider,{value:D,children:s(YG,I({as:l,ownerState:w,className:ve(x.root,a),ref:n},b,{children:o}))})}),Pi=XG;function JG(e){return je("MuiFormControlLabel",e)}const QG=Ue("MuiFormControlLabel",["root","labelPlacementStart","labelPlacementTop","labelPlacementBottom","disabled","label","error"]),qf=QG,ZG=["checked","className","componentsProps","control","disabled","disableTypography","inputRef","label","labelPlacement","name","onChange","slotProps","value"],eq=e=>{const{classes:t,disabled:n,labelPlacement:r,error:o}=e,a={root:["root",n&&"disabled",`labelPlacement${ie(r)}`,o&&"error"],label:["label",n&&"disabled"]};return He(a,JG,t)},tq=C("label",{name:"MuiFormControlLabel",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`& .${qf.label}`]:t.label},t.root,t[`labelPlacement${ie(n.labelPlacement)}`]]}})(({theme:e,ownerState:t})=>I({display:"inline-flex",alignItems:"center",cursor:"pointer",verticalAlign:"middle",WebkitTapHighlightColor:"transparent",marginLeft:-11,marginRight:16,[`&.${qf.disabled}`]:{cursor:"default"}},t.labelPlacement==="start"&&{flexDirection:"row-reverse",marginLeft:16,marginRight:-11},t.labelPlacement==="top"&&{flexDirection:"column-reverse",marginLeft:16},t.labelPlacement==="bottom"&&{flexDirection:"column",marginLeft:16},{[`& .${qf.label}`]:{[`&.${qf.disabled}`]:{color:(e.vars||e).palette.text.disabled}}})),nq=p.forwardRef(function(t,n){var r;const o=Ve({props:t,name:"MuiFormControlLabel"}),{className:a,componentsProps:i={},control:l,disabled:c,disableTypography:u,label:d,labelPlacement:f="end",slotProps:h={}}=o,m=$e(o,ZG),y=oi();let g=c;typeof g>"u"&&typeof l.props.disabled<"u"&&(g=l.props.disabled),typeof g>"u"&&y&&(g=y.disabled);const v={disabled:g};["checked","name","onChange","value","inputRef"].forEach(k=>{typeof l.props[k]>"u"&&typeof o[k]<"u"&&(v[k]=o[k])});const b=_s({props:o,muiFormControl:y,states:["error"]}),w=I({},o,{disabled:g,labelPlacement:f,error:b.error}),x=eq(w),E=(r=h.typography)!=null?r:i.typography;let A=d;return A!=null&&A.type!==ye&&!u&&(A=s(ye,I({component:"span"},E,{className:ve(x.label,E==null?void 0:E.className),children:A}))),T(tq,I({className:ve(x.root,a),ownerState:w,ref:n},m,{children:[p.cloneElement(l,v),A]}))}),Tr=nq;function rq(e){return je("MuiFormGroup",e)}Ue("MuiFormGroup",["root","row","error"]);const oq=["className","row"],aq=e=>{const{classes:t,row:n,error:r}=e;return He({root:["root",n&&"row",r&&"error"]},rq,t)},iq=C("div",{name:"MuiFormGroup",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.row&&t.row]}})(({ownerState:e})=>I({display:"flex",flexDirection:"column",flexWrap:"wrap"},e.row&&{flexDirection:"row"})),sq=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiFormGroup"}),{className:o,row:a=!1}=r,i=$e(r,oq),l=oi(),c=_s({props:r,muiFormControl:l,states:["error"]}),u=I({},r,{row:a,error:c.error}),d=aq(u);return s(iq,I({className:ve(d.root,o),ownerState:u,ref:n},i))}),lq=sq;function cq(e){return je("MuiFormHelperText",e)}const uq=Ue("MuiFormHelperText",["root","error","disabled","sizeSmall","sizeMedium","contained","focused","filled","required"]),wk=uq;var Sk;const dq=["children","className","component","disabled","error","filled","focused","margin","required","variant"],pq=e=>{const{classes:t,contained:n,size:r,disabled:o,error:a,filled:i,focused:l,required:c}=e,u={root:["root",o&&"disabled",a&&"error",r&&`size${ie(r)}`,n&&"contained",l&&"focused",i&&"filled",c&&"required"]};return He(u,cq,t)},fq=C("p",{name:"MuiFormHelperText",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.size&&t[`size${ie(n.size)}`],n.contained&&t.contained,n.filled&&t.filled]}})(({theme:e,ownerState:t})=>I({color:(e.vars||e).palette.text.secondary},e.typography.caption,{textAlign:"left",marginTop:3,marginRight:0,marginBottom:0,marginLeft:0,[`&.${wk.disabled}`]:{color:(e.vars||e).palette.text.disabled},[`&.${wk.error}`]:{color:(e.vars||e).palette.error.main}},t.size==="small"&&{marginTop:4},t.contained&&{marginLeft:14,marginRight:14})),hq=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiFormHelperText"}),{children:o,className:a,component:i="p"}=r,l=$e(r,dq),c=oi(),u=_s({props:r,muiFormControl:c,states:["variant","size","disabled","error","filled","focused","required"]}),d=I({},r,{component:i,contained:u.variant==="filled"||u.variant==="outlined",variant:u.variant,size:u.size,disabled:u.disabled,error:u.error,filled:u.filled,focused:u.focused,required:u.required}),f=pq(d);return s(fq,I({as:i,ownerState:d,className:ve(f.root,a),ref:n},l,{children:o===" "?Sk||(Sk=s("span",{className:"notranslate",children:""})):o}))}),mq=hq;function gq(e){return je("MuiFormLabel",e)}const vq=Ue("MuiFormLabel",["root","colorSecondary","focused","disabled","error","filled","required","asterisk"]),Dd=vq,yq=["children","className","color","component","disabled","error","filled","focused","required"],bq=e=>{const{classes:t,color:n,focused:r,disabled:o,error:a,filled:i,required:l}=e,c={root:["root",`color${ie(n)}`,o&&"disabled",a&&"error",i&&"filled",r&&"focused",l&&"required"],asterisk:["asterisk",a&&"error"]};return He(c,gq,t)},wq=C("label",{name:"MuiFormLabel",slot:"Root",overridesResolver:({ownerState:e},t)=>I({},t.root,e.color==="secondary"&&t.colorSecondary,e.filled&&t.filled)})(({theme:e,ownerState:t})=>I({color:(e.vars||e).palette.text.secondary},e.typography.body1,{lineHeight:"1.4375em",padding:0,position:"relative",[`&.${Dd.focused}`]:{color:(e.vars||e).palette[t.color].main},[`&.${Dd.disabled}`]:{color:(e.vars||e).palette.text.disabled},[`&.${Dd.error}`]:{color:(e.vars||e).palette.error.main}})),Sq=C("span",{name:"MuiFormLabel",slot:"Asterisk",overridesResolver:(e,t)=>t.asterisk})(({theme:e})=>({[`&.${Dd.error}`]:{color:(e.vars||e).palette.error.main}})),xq=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiFormLabel"}),{children:o,className:a,component:i="label"}=r,l=$e(r,yq),c=oi(),u=_s({props:r,muiFormControl:c,states:["color","required","focused","disabled","error","filled"]}),d=I({},r,{color:u.color||"primary",component:i,disabled:u.disabled,error:u.error,filled:u.filled,focused:u.focused,required:u.required}),f=bq(d);return T(wq,I({as:i,ownerState:d,className:ve(f.root,a),ref:n},l,{children:[o,u.required&&T(Sq,{ownerState:d,"aria-hidden":!0,className:f.asterisk,children:[" ","*"]})]}))}),Cq=xq,Eq=p.createContext(),xk=Eq;function Tq(e){return je("MuiGrid",e)}const kq=[0,1,2,3,4,5,6,7,8,9,10],Aq=["column-reverse","column","row-reverse","row"],_q=["nowrap","wrap-reverse","wrap"],qu=["auto",!0,1,2,3,4,5,6,7,8,9,10,11,12],mp=Ue("MuiGrid",["root","container","item","zeroMinWidth",...kq.map(e=>`spacing-xs-${e}`),...Aq.map(e=>`direction-xs-${e}`),..._q.map(e=>`wrap-xs-${e}`),...qu.map(e=>`grid-xs-${e}`),...qu.map(e=>`grid-sm-${e}`),...qu.map(e=>`grid-md-${e}`),...qu.map(e=>`grid-lg-${e}`),...qu.map(e=>`grid-xl-${e}`)]),Rq=["className","columns","columnSpacing","component","container","direction","item","rowSpacing","spacing","wrap","zeroMinWidth"];function xc(e){const t=parseFloat(e);return`${t}${String(e).replace(String(t),"")||"px"}`}function Pq({theme:e,ownerState:t}){let n;return e.breakpoints.keys.reduce((r,o)=>{let a={};if(t[o]&&(n=t[o]),!n)return r;if(n===!0)a={flexBasis:0,flexGrow:1,maxWidth:"100%"};else if(n==="auto")a={flexBasis:"auto",flexGrow:0,flexShrink:0,maxWidth:"none",width:"auto"};else{const i=Dg({values:t.columns,breakpoints:e.breakpoints.values}),l=typeof i=="object"?i[o]:i;if(l==null)return r;const c=`${Math.round(n/l*1e8)/1e6}%`;let u={};if(t.container&&t.item&&t.columnSpacing!==0){const d=e.spacing(t.columnSpacing);if(d!=="0px"){const f=`calc(${c} + ${xc(d)})`;u={flexBasis:f,maxWidth:f}}}a=I({flexBasis:c,flexGrow:0,maxWidth:c},u)}return e.breakpoints.values[o]===0?Object.assign(r,a):r[e.breakpoints.up(o)]=a,r},{})}function Iq({theme:e,ownerState:t}){const n=Dg({values:t.direction,breakpoints:e.breakpoints.values});return na({theme:e},n,r=>{const o={flexDirection:r};return r.indexOf("column")===0&&(o[`& > .${mp.item}`]={maxWidth:"none"}),o})}function Q$({breakpoints:e,values:t}){let n="";Object.keys(t).forEach(o=>{n===""&&t[o]!==0&&(n=o)});const r=Object.keys(e).sort((o,a)=>e[o]-e[a]);return r.slice(0,r.indexOf(n))}function $q({theme:e,ownerState:t}){const{container:n,rowSpacing:r}=t;let o={};if(n&&r!==0){const a=Dg({values:r,breakpoints:e.breakpoints.values});let i;typeof a=="object"&&(i=Q$({breakpoints:e.breakpoints.values,values:a})),o=na({theme:e},a,(l,c)=>{var u;const d=e.spacing(l);return d!=="0px"?{marginTop:`-${xc(d)}`,[`& > .${mp.item}`]:{paddingTop:xc(d)}}:(u=i)!=null&&u.includes(c)?{}:{marginTop:0,[`& > .${mp.item}`]:{paddingTop:0}}})}return o}function Oq({theme:e,ownerState:t}){const{container:n,columnSpacing:r}=t;let o={};if(n&&r!==0){const a=Dg({values:r,breakpoints:e.breakpoints.values});let i;typeof a=="object"&&(i=Q$({breakpoints:e.breakpoints.values,values:a})),o=na({theme:e},a,(l,c)=>{var u;const d=e.spacing(l);return d!=="0px"?{width:`calc(100% + ${xc(d)})`,marginLeft:`-${xc(d)}`,[`& > .${mp.item}`]:{paddingLeft:xc(d)}}:(u=i)!=null&&u.includes(c)?{}:{width:"100%",marginLeft:0,[`& > .${mp.item}`]:{paddingLeft:0}}})}return o}function Lq(e,t,n={}){if(!e||e<=0)return[];if(typeof e=="string"&&!Number.isNaN(Number(e))||typeof e=="number")return[n[`spacing-xs-${String(e)}`]];const r=[];return t.forEach(o=>{const a=e[o];Number(a)>0&&r.push(n[`spacing-${o}-${String(a)}`])}),r}const Nq=C("div",{name:"MuiGrid",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e,{container:r,direction:o,item:a,spacing:i,wrap:l,zeroMinWidth:c,breakpoints:u}=n;let d=[];r&&(d=Lq(i,u,t));const f=[];return u.forEach(h=>{const m=n[h];m&&f.push(t[`grid-${h}-${String(m)}`])}),[t.root,r&&t.container,a&&t.item,c&&t.zeroMinWidth,...d,o!=="row"&&t[`direction-xs-${String(o)}`],l!=="wrap"&&t[`wrap-xs-${String(l)}`],...f]}})(({ownerState:e})=>I({boxSizing:"border-box"},e.container&&{display:"flex",flexWrap:"wrap",width:"100%"},e.item&&{margin:0},e.zeroMinWidth&&{minWidth:0},e.wrap!=="wrap"&&{flexWrap:e.wrap}),Iq,$q,Oq,Pq);function Mq(e,t){if(!e||e<=0)return[];if(typeof e=="string"&&!Number.isNaN(Number(e))||typeof e=="number")return[`spacing-xs-${String(e)}`];const n=[];return t.forEach(r=>{const o=e[r];if(Number(o)>0){const a=`spacing-${r}-${String(o)}`;n.push(a)}}),n}const Dq=e=>{const{classes:t,container:n,direction:r,item:o,spacing:a,wrap:i,zeroMinWidth:l,breakpoints:c}=e;let u=[];n&&(u=Mq(a,c));const d=[];c.forEach(h=>{const m=e[h];m&&d.push(`grid-${h}-${String(m)}`)});const f={root:["root",n&&"container",o&&"item",l&&"zeroMinWidth",...u,r!=="row"&&`direction-xs-${String(r)}`,i!=="wrap"&&`wrap-xs-${String(i)}`,...d]};return He(f,Tq,t)},Bq=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiGrid"}),{breakpoints:o}=on(),a=zS(r),{className:i,columns:l,columnSpacing:c,component:u="div",container:d=!1,direction:f="row",item:h=!1,rowSpacing:m,spacing:y=0,wrap:g="wrap",zeroMinWidth:v=!1}=a,b=$e(a,Rq),w=m||y,x=c||y,E=p.useContext(xk),A=d?l||12:E,k={},_=I({},b);o.keys.forEach(O=>{b[O]!=null&&(k[O]=b[O],delete _[O])});const $=I({},a,{columns:A,container:d,direction:f,item:h,rowSpacing:w,columnSpacing:x,wrap:g,zeroMinWidth:v,spacing:y},k,{breakpoints:o.keys}),L=Dq($);return s(xk.Provider,{value:A,children:s(Nq,I({ownerState:$,className:ve(L.root,i),as:u,ref:n},_))})}),In=Bq,Fq=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function Tb(e){return`scale(${e}, ${e**2})`}const zq={entering:{opacity:1,transform:Tb(1)},entered:{opacity:1,transform:"none"}},f1=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Z$=p.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:a,easing:i,in:l,onEnter:c,onEntered:u,onEntering:d,onExit:f,onExited:h,onExiting:m,style:y,timeout:g="auto",TransitionComponent:v=Xg}=t,b=$e(t,Fq),w=p.useRef(),x=p.useRef(),E=on(),A=p.useRef(null),k=Sn(A,a.ref,n),_=Y=>V=>{if(Y){const te=A.current;V===void 0?Y(te):Y(te,V)}},$=_(d),L=_((Y,V)=>{tx(Y);const{duration:te,delay:Z,easing:W}=ys({style:y,timeout:g,easing:i},{mode:"enter"});let z;g==="auto"?(z=E.transitions.getAutoHeightDuration(Y.clientHeight),x.current=z):z=te,Y.style.transition=[E.transitions.create("opacity",{duration:z,delay:Z}),E.transitions.create("transform",{duration:f1?z:z*.666,delay:Z,easing:W})].join(","),c&&c(Y,V)}),O=_(u),P=_(m),D=_(Y=>{const{duration:V,delay:te,easing:Z}=ys({style:y,timeout:g,easing:i},{mode:"exit"});let W;g==="auto"?(W=E.transitions.getAutoHeightDuration(Y.clientHeight),x.current=W):W=V,Y.style.transition=[E.transitions.create("opacity",{duration:W,delay:te}),E.transitions.create("transform",{duration:f1?W:W*.666,delay:f1?te:te||W*.333,easing:Z})].join(","),Y.style.opacity=0,Y.style.transform=Tb(.75),f&&f(Y)}),F=_(h),U=Y=>{g==="auto"&&(w.current=setTimeout(Y,x.current||0)),r&&r(A.current,Y)};return p.useEffect(()=>()=>{clearTimeout(w.current)},[]),s(v,I({appear:o,in:l,nodeRef:A,onEnter:L,onEntered:O,onEntering:$,onExit:D,onExited:F,onExiting:P,addEndListener:U,timeout:g==="auto"?null:g},b,{children:(Y,V)=>p.cloneElement(a,I({style:I({opacity:0,transform:Tb(.75),visibility:Y==="exited"&&!l?"hidden":void 0},zq[Y],y,a.props.style),ref:k},V))}))});Z$.muiSupportAuto=!0;const kb=Z$;function jq(e,t,n,r,o){const[a,i]=p.useState(()=>o&&n?n(e).matches:r?r(e).matches:t);return $o(()=>{let l=!0;if(!n)return;const c=n(e),u=()=>{l&&i(c.matches)};return u(),c.addListener(u),()=>{l=!1,c.removeListener(u)}},[e,n]),a}const e4=ul["useSyncExternalStore"];function Uq(e,t,n,r,o){const a=p.useCallback(()=>t,[t]),i=p.useMemo(()=>{if(o&&n)return()=>n(e).matches;if(r!==null){const{matches:d}=r(e);return()=>d}return a},[a,e,r,o,n]),[l,c]=p.useMemo(()=>{if(n===null)return[a,()=>()=>{}];const d=n(e);return[()=>d.matches,f=>(d.addListener(f),()=>{d.removeListener(f)})]},[a,n,e]);return e4(c,l,i)}function cr(e,t={}){const n=jS(),r=typeof window<"u"&&typeof window.matchMedia<"u",{defaultMatches:o=!1,matchMedia:a=r?window.matchMedia:null,ssrMatchMedia:i=null,noSsr:l=!1}=C$({name:"MuiUseMediaQuery",props:t,theme:n});let c=typeof e=="function"?e(n):e;return c=c.replace(/^@media( ?)/m,""),(e4!==void 0?Uq:jq)(c,o,a,i,l)}function Wq(e){return je("MuiIcon",e)}Ue("MuiIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Hq=["baseClassName","className","color","component","fontSize"],Vq=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${ie(t)}`,`fontSize${ie(n)}`]};return He(o,Wq,r)},Gq=C("span",{name:"MuiIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${ie(n.color)}`],t[`fontSize${ie(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>({userSelect:"none",width:"1em",height:"1em",overflow:"hidden",display:"inline-block",textAlign:"center",flexShrink:0,fontSize:{inherit:"inherit",small:e.typography.pxToRem(20),medium:e.typography.pxToRem(24),large:e.typography.pxToRem(36)}[t.fontSize],color:{primary:(e.vars||e).palette.primary.main,secondary:(e.vars||e).palette.secondary.main,info:(e.vars||e).palette.info.main,success:(e.vars||e).palette.success.main,warning:(e.vars||e).palette.warning.main,action:(e.vars||e).palette.action.active,error:(e.vars||e).palette.error.main,disabled:(e.vars||e).palette.action.disabled,inherit:void 0}[t.color]})),t4=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiIcon"}),{baseClassName:o="material-icons",className:a,color:i="inherit",component:l="span",fontSize:c="medium"}=r,u=$e(r,Hq),d=I({},r,{baseClassName:o,color:i,component:l,fontSize:c}),f=Vq(d);return s(Gq,I({as:l,className:ve(o,"notranslate",f.root,a),ownerState:d,"aria-hidden":!0,ref:n},u))});t4.muiName="Icon";const cx=t4,qq=["disableUnderline","components","componentsProps","fullWidth","inputComponent","multiline","slotProps","slots","type"],Kq=e=>{const{classes:t,disableUnderline:n}=e,o=He({root:["root",!n&&"underline"],input:["input"]},NW,t);return I({},t,o)},Yq=C(nv,{shouldForwardProp:e=>Bo(e)||e==="classes",name:"MuiInput",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[...ev(e,t),!n.disableUnderline&&t.underline]}})(({theme:e,ownerState:t})=>{let r=e.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(r=`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`),I({position:"relative"},t.formControl&&{"label + &":{marginTop:16}},!t.disableUnderline&&{"&:after":{borderBottom:`2px solid ${(e.vars||e).palette[t.color].main}`,left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Vi.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Vi.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&:before":{borderBottom:`1px solid ${r}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Vi.disabled}, .${Vi.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${r}`}},[`&.${Vi.disabled}:before`]:{borderBottomStyle:"dotted"}})}),Xq=C(rv,{name:"MuiInput",slot:"Input",overridesResolver:tv})({}),n4=p.forwardRef(function(t,n){var r,o,a,i;const l=Ve({props:t,name:"MuiInput"}),{disableUnderline:c,components:u={},componentsProps:d,fullWidth:f=!1,inputComponent:h="input",multiline:m=!1,slotProps:y,slots:g={},type:v="text"}=l,b=$e(l,qq),w=Kq(l),E={root:{ownerState:{disableUnderline:c}}},A=y??d?Ro(y??d,E):E,k=(r=(o=g.root)!=null?o:u.Root)!=null?r:Yq,_=(a=(i=g.input)!=null?i:u.Input)!=null?a:Xq;return s(ov,I({slots:{root:k,input:_},slotProps:A,fullWidth:f,inputComponent:h,multiline:m,ref:n,type:v},b,{classes:w}))});n4.muiName="Input";const r4=n4;function Jq(e){return je("MuiInputAdornment",e)}const Qq=Ue("MuiInputAdornment",["root","filled","standard","outlined","positionStart","positionEnd","disablePointerEvents","hiddenLabel","sizeSmall"]),Ck=Qq;var Ek;const Zq=["children","className","component","disablePointerEvents","disableTypography","position","variant"],eK=(e,t)=>{const{ownerState:n}=e;return[t.root,t[`position${ie(n.position)}`],n.disablePointerEvents===!0&&t.disablePointerEvents,t[n.variant]]},tK=e=>{const{classes:t,disablePointerEvents:n,hiddenLabel:r,position:o,size:a,variant:i}=e,l={root:["root",n&&"disablePointerEvents",o&&`position${ie(o)}`,i,r&&"hiddenLabel",a&&`size${ie(a)}`]};return He(l,Jq,t)},nK=C("div",{name:"MuiInputAdornment",slot:"Root",overridesResolver:eK})(({theme:e,ownerState:t})=>I({display:"flex",height:"0.01em",maxHeight:"2em",alignItems:"center",whiteSpace:"nowrap",color:(e.vars||e).palette.action.active},t.variant==="filled"&&{[`&.${Ck.positionStart}&:not(.${Ck.hiddenLabel})`]:{marginTop:16}},t.position==="start"&&{marginRight:8},t.position==="end"&&{marginLeft:8},t.disablePointerEvents===!0&&{pointerEvents:"none"})),rK=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiInputAdornment"}),{children:o,className:a,component:i="div",disablePointerEvents:l=!1,disableTypography:c=!1,position:u,variant:d}=r,f=$e(r,Zq),h=oi()||{};let m=d;d&&h.variant,h&&!m&&(m=h.variant);const y=I({},r,{hiddenLabel:h.hiddenLabel,size:h.size,disablePointerEvents:l,position:u,variant:m}),g=tK(y);return s(Zg.Provider,{value:null,children:s(nK,I({as:i,ownerState:y,className:ve(g.root,a),ref:n},f,{children:typeof o=="string"&&!c?s(ye,{color:"text.secondary",children:o}):T(p.Fragment,{children:[u==="start"?Ek||(Ek=s("span",{className:"notranslate",children:""})):null,o]})}))})}),o4=rK;function oK(e){return je("MuiInputLabel",e)}Ue("MuiInputLabel",["root","focused","disabled","error","required","asterisk","formControl","sizeSmall","shrink","animated","standard","filled","outlined"]);const aK=["disableAnimation","margin","shrink","variant","className"],iK=e=>{const{classes:t,formControl:n,size:r,shrink:o,disableAnimation:a,variant:i,required:l}=e,u=He({root:["root",n&&"formControl",!a&&"animated",o&&"shrink",r==="small"&&"sizeSmall",i],asterisk:[l&&"asterisk"]},oK,t);return I({},t,u)},sK=C(Cq,{shouldForwardProp:e=>Bo(e)||e==="classes",name:"MuiInputLabel",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`& .${Dd.asterisk}`]:t.asterisk},t.root,n.formControl&&t.formControl,n.size==="small"&&t.sizeSmall,n.shrink&&t.shrink,!n.disableAnimation&&t.animated,t[n.variant]]}})(({theme:e,ownerState:t})=>I({display:"block",transformOrigin:"top left",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",maxWidth:"100%"},t.formControl&&{position:"absolute",left:0,top:0,transform:"translate(0, 20px) scale(1)"},t.size==="small"&&{transform:"translate(0, 17px) scale(1)"},t.shrink&&{transform:"translate(0, -1.5px) scale(0.75)",transformOrigin:"top left",maxWidth:"133%"},!t.disableAnimation&&{transition:e.transitions.create(["color","transform","max-width"],{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut})},t.variant==="filled"&&I({zIndex:1,pointerEvents:"none",transform:"translate(12px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"},t.size==="small"&&{transform:"translate(12px, 13px) scale(1)"},t.shrink&&I({userSelect:"none",pointerEvents:"auto",transform:"translate(12px, 7px) scale(0.75)",maxWidth:"calc(133% - 24px)"},t.size==="small"&&{transform:"translate(12px, 4px) scale(0.75)"})),t.variant==="outlined"&&I({zIndex:1,pointerEvents:"none",transform:"translate(14px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"},t.size==="small"&&{transform:"translate(14px, 9px) scale(1)"},t.shrink&&{userSelect:"none",pointerEvents:"auto",maxWidth:"calc(133% - 24px)",transform:"translate(14px, -9px) scale(0.75)"}))),lK=p.forwardRef(function(t,n){const r=Ve({name:"MuiInputLabel",props:t}),{disableAnimation:o=!1,shrink:a,className:i}=r,l=$e(r,aK),c=oi();let u=a;typeof u>"u"&&c&&(u=c.filled||c.focused||c.adornedStart);const d=_s({props:r,muiFormControl:c,states:["size","variant","required"]}),f=I({},r,{disableAnimation:o,formControl:c,shrink:u,size:d.size,variant:d.variant,required:d.required}),h=iK(f);return s(sK,I({"data-shrink":u,ownerState:f,ref:n,className:ve(h.root,i)},l,{classes:h}))}),Yp=lK;function cK(e){return je("MuiLinearProgress",e)}Ue("MuiLinearProgress",["root","colorPrimary","colorSecondary","determinate","indeterminate","buffer","query","dashed","dashedColorPrimary","dashedColorSecondary","bar","barColorPrimary","barColorSecondary","bar1Indeterminate","bar1Determinate","bar1Buffer","bar2Indeterminate","bar2Buffer"]);const uK=["className","color","value","valueBuffer","variant"];let iu=e=>e,Tk,kk,Ak,_k,Rk,Pk;const Ab=4,dK=ks(Tk||(Tk=iu`
|
|
192
|
+
0% {
|
|
193
|
+
left: -35%;
|
|
194
|
+
right: 100%;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
60% {
|
|
198
|
+
left: 100%;
|
|
199
|
+
right: -90%;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
100% {
|
|
203
|
+
left: 100%;
|
|
204
|
+
right: -90%;
|
|
205
|
+
}
|
|
206
|
+
`)),pK=ks(kk||(kk=iu`
|
|
207
|
+
0% {
|
|
208
|
+
left: -200%;
|
|
209
|
+
right: 100%;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
60% {
|
|
213
|
+
left: 107%;
|
|
214
|
+
right: -8%;
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
100% {
|
|
218
|
+
left: 107%;
|
|
219
|
+
right: -8%;
|
|
220
|
+
}
|
|
221
|
+
`)),fK=ks(Ak||(Ak=iu`
|
|
222
|
+
0% {
|
|
223
|
+
opacity: 1;
|
|
224
|
+
background-position: 0 -23px;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
60% {
|
|
228
|
+
opacity: 0;
|
|
229
|
+
background-position: 0 -23px;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
100% {
|
|
233
|
+
opacity: 1;
|
|
234
|
+
background-position: -200px -23px;
|
|
235
|
+
}
|
|
236
|
+
`)),hK=e=>{const{classes:t,variant:n,color:r}=e,o={root:["root",`color${ie(r)}`,n],dashed:["dashed",`dashedColor${ie(r)}`],bar1:["bar",`barColor${ie(r)}`,(n==="indeterminate"||n==="query")&&"bar1Indeterminate",n==="determinate"&&"bar1Determinate",n==="buffer"&&"bar1Buffer"],bar2:["bar",n!=="buffer"&&`barColor${ie(r)}`,n==="buffer"&&`color${ie(r)}`,(n==="indeterminate"||n==="query")&&"bar2Indeterminate",n==="buffer"&&"bar2Buffer"]};return He(o,cK,t)},ux=(e,t)=>t==="inherit"?"currentColor":e.vars?e.vars.palette.LinearProgress[`${t}Bg`]:e.palette.mode==="light"?vs(e.palette[t].main,.62):gs(e.palette[t].main,.5),mK=C("span",{name:"MuiLinearProgress",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`color${ie(n.color)}`],t[n.variant]]}})(({ownerState:e,theme:t})=>I({position:"relative",overflow:"hidden",display:"block",height:4,zIndex:0,"@media print":{colorAdjust:"exact"},backgroundColor:ux(t,e.color)},e.color==="inherit"&&e.variant!=="buffer"&&{backgroundColor:"none","&::before":{content:'""',position:"absolute",left:0,top:0,right:0,bottom:0,backgroundColor:"currentColor",opacity:.3}},e.variant==="buffer"&&{backgroundColor:"transparent"},e.variant==="query"&&{transform:"rotate(180deg)"})),gK=C("span",{name:"MuiLinearProgress",slot:"Dashed",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.dashed,t[`dashedColor${ie(n.color)}`]]}})(({ownerState:e,theme:t})=>{const n=ux(t,e.color);return I({position:"absolute",marginTop:0,height:"100%",width:"100%"},e.color==="inherit"&&{opacity:.3},{backgroundImage:`radial-gradient(${n} 0%, ${n} 16%, transparent 42%)`,backgroundSize:"10px 10px",backgroundPosition:"0 -23px"})},ou(_k||(_k=iu`
|
|
237
|
+
animation: ${0} 3s infinite linear;
|
|
238
|
+
`),fK)),vK=C("span",{name:"MuiLinearProgress",slot:"Bar1",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.bar,t[`barColor${ie(n.color)}`],(n.variant==="indeterminate"||n.variant==="query")&&t.bar1Indeterminate,n.variant==="determinate"&&t.bar1Determinate,n.variant==="buffer"&&t.bar1Buffer]}})(({ownerState:e,theme:t})=>I({width:"100%",position:"absolute",left:0,bottom:0,top:0,transition:"transform 0.2s linear",transformOrigin:"left",backgroundColor:e.color==="inherit"?"currentColor":(t.vars||t).palette[e.color].main},e.variant==="determinate"&&{transition:`transform .${Ab}s linear`},e.variant==="buffer"&&{zIndex:1,transition:`transform .${Ab}s linear`}),({ownerState:e})=>(e.variant==="indeterminate"||e.variant==="query")&&ou(Rk||(Rk=iu`
|
|
239
|
+
width: auto;
|
|
240
|
+
animation: ${0} 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite;
|
|
241
|
+
`),dK)),yK=C("span",{name:"MuiLinearProgress",slot:"Bar2",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.bar,t[`barColor${ie(n.color)}`],(n.variant==="indeterminate"||n.variant==="query")&&t.bar2Indeterminate,n.variant==="buffer"&&t.bar2Buffer]}})(({ownerState:e,theme:t})=>I({width:"100%",position:"absolute",left:0,bottom:0,top:0,transition:"transform 0.2s linear",transformOrigin:"left"},e.variant!=="buffer"&&{backgroundColor:e.color==="inherit"?"currentColor":(t.vars||t).palette[e.color].main},e.color==="inherit"&&{opacity:.3},e.variant==="buffer"&&{backgroundColor:ux(t,e.color),transition:`transform .${Ab}s linear`}),({ownerState:e})=>(e.variant==="indeterminate"||e.variant==="query")&&ou(Pk||(Pk=iu`
|
|
242
|
+
width: auto;
|
|
243
|
+
animation: ${0} 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) 1.15s infinite;
|
|
244
|
+
`),pK)),bK=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiLinearProgress"}),{className:o,color:a="primary",value:i,valueBuffer:l,variant:c="indeterminate"}=r,u=$e(r,uK),d=I({},r,{color:a,variant:c}),f=hK(d),h=on(),m={},y={bar1:{},bar2:{}};if((c==="determinate"||c==="buffer")&&i!==void 0){m["aria-valuenow"]=Math.round(i),m["aria-valuemin"]=0,m["aria-valuemax"]=100;let g=i-100;h.direction==="rtl"&&(g=-g),y.bar1.transform=`translateX(${g}%)`}if(c==="buffer"&&l!==void 0){let g=(l||0)-100;h.direction==="rtl"&&(g=-g),y.bar2.transform=`translateX(${g}%)`}return T(mK,I({className:ve(f.root,o),ownerState:d,role:"progressbar"},m,{ref:n},u,{children:[c==="buffer"?s(gK,{className:f.dashed,ownerState:d}):null,s(vK,{className:f.bar1,ownerState:d,style:y.bar1}),c==="determinate"?null:s(yK,{className:f.bar2,ownerState:d,style:y.bar2})]}))}),wK=bK;function SK(e){return je("MuiLink",e)}const xK=Ue("MuiLink",["root","underlineNone","underlineHover","underlineAlways","button","focusVisible"]),CK=xK,a4={primary:"primary.main",textPrimary:"text.primary",secondary:"secondary.main",textSecondary:"text.secondary",error:"error.main"},EK=e=>a4[e]||e,TK=({theme:e,ownerState:t})=>{const n=EK(t.color),r=Nc(e,`palette.${n}`,!1)||t.color,o=Nc(e,`palette.${n}Channel`);return"vars"in e&&o?`rgba(${o} / 0.4)`:Ot(r,.4)},kK=TK,AK=["className","color","component","onBlur","onFocus","TypographyClasses","underline","variant","sx"],_K=e=>{const{classes:t,component:n,focusVisible:r,underline:o}=e,a={root:["root",`underline${ie(o)}`,n==="button"&&"button",r&&"focusVisible"]};return He(a,SK,t)},RK=C(ye,{name:"MuiLink",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`underline${ie(n.underline)}`],n.component==="button"&&t.button]}})(({theme:e,ownerState:t})=>I({},t.underline==="none"&&{textDecoration:"none"},t.underline==="hover"&&{textDecoration:"none","&:hover":{textDecoration:"underline"}},t.underline==="always"&&I({textDecoration:"underline"},t.color!=="inherit"&&{textDecorationColor:kK({theme:e,ownerState:t})},{"&:hover":{textDecorationColor:"inherit"}}),t.component==="button"&&{position:"relative",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,padding:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none","&::-moz-focus-inner":{borderStyle:"none"},[`&.${CK.focusVisible}`]:{outline:"auto"}})),PK=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiLink"}),{className:o,color:a="primary",component:i="a",onBlur:l,onFocus:c,TypographyClasses:u,underline:d="always",variant:f="inherit",sx:h}=r,m=$e(r,AK),{isFocusVisibleRef:y,onBlur:g,onFocus:v,ref:b}=jp(),[w,x]=p.useState(!1),E=Sn(n,b),A=L=>{g(L),y.current===!1&&x(!1),l&&l(L)},k=L=>{v(L),y.current===!0&&x(!0),c&&c(L)},_=I({},r,{color:a,component:i,focusVisible:w,underline:d,variant:f}),$=_K(_);return s(RK,I({color:a,className:ve($.root,o),classes:u,component:i,onBlur:A,onFocus:k,ref:E,ownerState:_,variant:f,sx:[...Object.keys(a4).includes(a)?[]:[{color:a}],...Array.isArray(h)?h:[h]]},m))}),go=PK,IK=p.createContext({}),Ya=IK;function $K(e){return je("MuiList",e)}Ue("MuiList",["root","padding","dense","subheader"]);const OK=["children","className","component","dense","disablePadding","subheader"],LK=e=>{const{classes:t,disablePadding:n,dense:r,subheader:o}=e;return He({root:["root",!n&&"padding",r&&"dense",o&&"subheader"]},$K,t)},NK=C("ul",{name:"MuiList",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disablePadding&&t.padding,n.dense&&t.dense,n.subheader&&t.subheader]}})(({ownerState:e})=>I({listStyle:"none",margin:0,padding:0,position:"relative"},!e.disablePadding&&{paddingTop:8,paddingBottom:8},e.subheader&&{paddingTop:0})),MK=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiList"}),{children:o,className:a,component:i="ul",dense:l=!1,disablePadding:c=!1,subheader:u}=r,d=$e(r,OK),f=p.useMemo(()=>({dense:l}),[l]),h=I({},r,{component:i,dense:l,disablePadding:c}),m=LK(h);return s(Ya.Provider,{value:f,children:T(NK,I({as:i,className:ve(m.root,a),ref:n,ownerState:h},d,{children:[u,o]}))})}),xa=MK;function DK(e){return je("MuiListItem",e)}const BK=Ue("MuiListItem",["root","container","focusVisible","dense","alignItemsFlexStart","disabled","divider","gutters","padding","button","secondaryAction","selected"]),Zl=BK,FK=Ue("MuiListItemButton",["root","focusVisible","dense","alignItemsFlexStart","disabled","divider","gutters","selected"]),zK=FK;function jK(e){return je("MuiListItemSecondaryAction",e)}Ue("MuiListItemSecondaryAction",["root","disableGutters"]);const UK=["className"],WK=e=>{const{disableGutters:t,classes:n}=e;return He({root:["root",t&&"disableGutters"]},jK,n)},HK=C("div",{name:"MuiListItemSecondaryAction",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.disableGutters&&t.disableGutters]}})(({ownerState:e})=>I({position:"absolute",right:16,top:"50%",transform:"translateY(-50%)"},e.disableGutters&&{right:0})),i4=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiListItemSecondaryAction"}),{className:o}=r,a=$e(r,UK),i=p.useContext(Ya),l=I({},r,{disableGutters:i.disableGutters}),c=WK(l);return s(HK,I({className:ve(c.root,o),ownerState:l,ref:n},a))});i4.muiName="ListItemSecondaryAction";const VK=i4,GK=["className"],qK=["alignItems","autoFocus","button","children","className","component","components","componentsProps","ContainerComponent","ContainerProps","dense","disabled","disableGutters","disablePadding","divider","focusVisibleClassName","secondaryAction","selected","slotProps","slots"],KK=(e,t)=>{const{ownerState:n}=e;return[t.root,n.dense&&t.dense,n.alignItems==="flex-start"&&t.alignItemsFlexStart,n.divider&&t.divider,!n.disableGutters&&t.gutters,!n.disablePadding&&t.padding,n.button&&t.button,n.hasSecondaryAction&&t.secondaryAction]},YK=e=>{const{alignItems:t,button:n,classes:r,dense:o,disabled:a,disableGutters:i,disablePadding:l,divider:c,hasSecondaryAction:u,selected:d}=e;return He({root:["root",o&&"dense",!i&&"gutters",!l&&"padding",c&&"divider",a&&"disabled",n&&"button",t==="flex-start"&&"alignItemsFlexStart",u&&"secondaryAction",d&&"selected"],container:["container"]},DK,r)},XK=C("div",{name:"MuiListItem",slot:"Root",overridesResolver:KK})(({theme:e,ownerState:t})=>I({display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",width:"100%",boxSizing:"border-box",textAlign:"left"},!t.disablePadding&&I({paddingTop:8,paddingBottom:8},t.dense&&{paddingTop:4,paddingBottom:4},!t.disableGutters&&{paddingLeft:16,paddingRight:16},!!t.secondaryAction&&{paddingRight:48}),!!t.secondaryAction&&{[`& > .${zK.root}`]:{paddingRight:48}},{[`&.${Zl.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`&.${Zl.selected}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity),[`&.${Zl.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}},[`&.${Zl.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity}},t.alignItems==="flex-start"&&{alignItems:"flex-start"},t.divider&&{borderBottom:`1px solid ${(e.vars||e).palette.divider}`,backgroundClip:"padding-box"},t.button&&{transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest}),"&:hover":{textDecoration:"none",backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${Zl.selected}:hover`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity)}}},t.hasSecondaryAction&&{paddingRight:48})),JK=C("li",{name:"MuiListItem",slot:"Container",overridesResolver:(e,t)=>t.container})({position:"relative"}),QK=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiListItem"}),{alignItems:o="center",autoFocus:a=!1,button:i=!1,children:l,className:c,component:u,components:d={},componentsProps:f={},ContainerComponent:h="li",ContainerProps:{className:m}={},dense:y=!1,disabled:g=!1,disableGutters:v=!1,disablePadding:b=!1,divider:w=!1,focusVisibleClassName:x,secondaryAction:E,selected:A=!1,slotProps:k={},slots:_={}}=r,$=$e(r.ContainerProps,GK),L=$e(r,qK),O=p.useContext(Ya),P=p.useMemo(()=>({dense:y||O.dense||!1,alignItems:o,disableGutters:v}),[o,O.dense,y,v]),D=p.useRef(null);$o(()=>{a&&D.current&&D.current.focus()},[a]);const F=p.Children.toArray(l),U=F.length&&Id(F[F.length-1],["ListItemSecondaryAction"]),Y=I({},r,{alignItems:o,autoFocus:a,button:i,dense:P.dense,disabled:g,disableGutters:v,disablePadding:b,divider:w,hasSecondaryAction:U,selected:A}),V=YK(Y),te=Sn(D,n),Z=_.root||d.Root||XK,W=k.root||f.root||{},z=I({className:ve(V.root,W.className,c),disabled:g},L);let R=u||"li";return i&&(z.component=u||"div",z.focusVisibleClassName=ve(Zl.focusVisible,x),R=Ea),U?(R=!z.component&&!u?"div":R,h==="li"&&(R==="li"?R="div":z.component==="li"&&(z.component="div")),s(Ya.Provider,{value:P,children:T(JK,I({as:h,className:ve(V.container,m),ref:te,ownerState:Y},$,{children:[s(Z,I({},W,!qa(Z)&&{as:R,ownerState:I({},Y,W.ownerState)},z,{children:F})),F.pop()]}))})):s(Ya.Provider,{value:P,children:T(Z,I({},W,{as:R,ref:te},!qa(Z)&&{ownerState:I({},Y,W.ownerState)},z,{children:[F,E&&s(VK,{children:E})]}))})}),ba=QK;function ZK(e){return je("MuiListItemAvatar",e)}Ue("MuiListItemAvatar",["root","alignItemsFlexStart"]);const eY=["className"],tY=e=>{const{alignItems:t,classes:n}=e;return He({root:["root",t==="flex-start"&&"alignItemsFlexStart"]},ZK,n)},nY=C("div",{name:"MuiListItemAvatar",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.alignItems==="flex-start"&&t.alignItemsFlexStart]}})(({ownerState:e})=>I({minWidth:56,flexShrink:0},e.alignItems==="flex-start"&&{marginTop:8})),rY=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiListItemAvatar"}),{className:o}=r,a=$e(r,eY),i=p.useContext(Ya),l=I({},r,{alignItems:i.alignItems}),c=tY(l);return s(nY,I({className:ve(c.root,o),ownerState:l,ref:n},a))}),Xi=rY;function oY(e){return je("MuiListItemIcon",e)}const aY=Ue("MuiListItemIcon",["root","alignItemsFlexStart"]),Ik=aY,iY=["className"],sY=e=>{const{alignItems:t,classes:n}=e;return He({root:["root",t==="flex-start"&&"alignItemsFlexStart"]},oY,n)},lY=C("div",{name:"MuiListItemIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.alignItems==="flex-start"&&t.alignItemsFlexStart]}})(({theme:e,ownerState:t})=>I({minWidth:56,color:(e.vars||e).palette.action.active,flexShrink:0,display:"inline-flex"},t.alignItems==="flex-start"&&{marginTop:8})),cY=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiListItemIcon"}),{className:o}=r,a=$e(r,iY),i=p.useContext(Ya),l=I({},r,{alignItems:i.alignItems}),c=sY(l);return s(lY,I({className:ve(c.root,o),ownerState:l,ref:n},a))}),Lh=cY;function uY(e){return je("MuiListItemText",e)}const dY=Ue("MuiListItemText",["root","multiline","dense","inset","primary","secondary"]),Tm=dY,pY=["children","className","disableTypography","inset","primary","primaryTypographyProps","secondary","secondaryTypographyProps"],fY=e=>{const{classes:t,inset:n,primary:r,secondary:o,dense:a}=e;return He({root:["root",n&&"inset",a&&"dense",r&&o&&"multiline"],primary:["primary"],secondary:["secondary"]},uY,t)},hY=C("div",{name:"MuiListItemText",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`& .${Tm.primary}`]:t.primary},{[`& .${Tm.secondary}`]:t.secondary},t.root,n.inset&&t.inset,n.primary&&n.secondary&&t.multiline,n.dense&&t.dense]}})(({ownerState:e})=>I({flex:"1 1 auto",minWidth:0,marginTop:4,marginBottom:4},e.primary&&e.secondary&&{marginTop:6,marginBottom:6},e.inset&&{paddingLeft:56})),mY=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiListItemText"}),{children:o,className:a,disableTypography:i=!1,inset:l=!1,primary:c,primaryTypographyProps:u,secondary:d,secondaryTypographyProps:f}=r,h=$e(r,pY),{dense:m}=p.useContext(Ya);let y=c??o,g=d;const v=I({},r,{disableTypography:i,inset:l,primary:!!y,secondary:!!g,dense:m}),b=fY(v);return y!=null&&y.type!==ye&&!i&&(y=s(ye,I({variant:m?"body2":"body1",className:b.primary,component:u!=null&&u.variant?void 0:"span",display:"block"},u,{children:y}))),g!=null&&g.type!==ye&&!i&&(g=s(ye,I({variant:"body2",className:b.secondary,color:"text.secondary",display:"block"},f,{children:g}))),T(hY,I({className:ve(b.root,a),ownerState:v,ref:n},h,{children:[y,g]}))}),fn=mY,gY=["actions","autoFocus","autoFocusItem","children","className","disabledItemsFocusable","disableListWrap","onKeyDown","variant"];function h1(e,t,n){return e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:n?null:e.firstChild}function $k(e,t,n){return e===t?n?e.firstChild:e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:n?null:e.lastChild}function s4(e,t){if(t===void 0)return!0;let n=e.innerText;return n===void 0&&(n=e.textContent),n=n.trim().toLowerCase(),n.length===0?!1:t.repeating?n[0]===t.keys[0]:n.indexOf(t.keys.join(""))===0}function Ku(e,t,n,r,o,a){let i=!1,l=o(e,t,t?n:!1);for(;l;){if(l===e.firstChild){if(i)return!1;i=!0}const c=r?!1:l.disabled||l.getAttribute("aria-disabled")==="true";if(!l.hasAttribute("tabindex")||!s4(l,a)||c)l=o(e,l,n);else return l.focus(),!0}return!1}const vY=p.forwardRef(function(t,n){const{actions:r,autoFocus:o=!1,autoFocusItem:a=!1,children:i,className:l,disabledItemsFocusable:c=!1,disableListWrap:u=!1,onKeyDown:d,variant:f="selectedMenu"}=t,h=$e(t,gY),m=p.useRef(null),y=p.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});$o(()=>{o&&m.current.focus()},[o]),p.useImperativeHandle(r,()=>({adjustStyleForScrollbar:(x,E)=>{const A=!m.current.style.width;if(x.clientHeight<m.current.clientHeight&&A){const k=`${q5(Fn(x))}px`;m.current.style[E.direction==="rtl"?"paddingLeft":"paddingRight"]=k,m.current.style.width=`calc(100% + ${k})`}return m.current}}),[]);const g=x=>{const E=m.current,A=x.key,k=Fn(E).activeElement;if(A==="ArrowDown")x.preventDefault(),Ku(E,k,u,c,h1);else if(A==="ArrowUp")x.preventDefault(),Ku(E,k,u,c,$k);else if(A==="Home")x.preventDefault(),Ku(E,null,u,c,h1);else if(A==="End")x.preventDefault(),Ku(E,null,u,c,$k);else if(A.length===1){const _=y.current,$=A.toLowerCase(),L=performance.now();_.keys.length>0&&(L-_.lastTime>500?(_.keys=[],_.repeating=!0,_.previousKeyMatched=!0):_.repeating&&$!==_.keys[0]&&(_.repeating=!1)),_.lastTime=L,_.keys.push($);const O=k&&!_.repeating&&s4(k,_);_.previousKeyMatched&&(O||Ku(E,k,!1,c,h1,_))?x.preventDefault():_.previousKeyMatched=!1}d&&d(x)},v=Sn(m,n);let b=-1;p.Children.forEach(i,(x,E)=>{p.isValidElement(x)&&(x.props.disabled||(f==="selectedMenu"&&x.props.selected||b===-1)&&(b=E))});const w=p.Children.map(i,(x,E)=>{if(E===b){const A={};return a&&(A.autoFocus=!0),x.props.tabIndex===void 0&&f==="selectedMenu"&&(A.tabIndex=0),p.cloneElement(x,A)}return x});return s(xa,I({role:"menu",ref:v,className:l,onKeyDown:g,tabIndex:o?0:-1},h,{children:w}))}),l4=vY;function yY(e){return je("MuiPopover",e)}Ue("MuiPopover",["root","paper"]);const bY=["onEntering"],wY=["action","anchorEl","anchorOrigin","anchorPosition","anchorReference","children","className","container","elevation","marginThreshold","open","PaperProps","transformOrigin","TransitionComponent","transitionDuration","TransitionProps"];function Ok(e,t){let n=0;return typeof t=="number"?n=t:t==="center"?n=e.height/2:t==="bottom"&&(n=e.height),n}function Lk(e,t){let n=0;return typeof t=="number"?n=t:t==="center"?n=e.width/2:t==="right"&&(n=e.width),n}function Nk(e){return[e.horizontal,e.vertical].map(t=>typeof t=="number"?`${t}px`:t).join(" ")}function m1(e){return typeof e=="function"?e():e}const SY=e=>{const{classes:t}=e;return He({root:["root"],paper:["paper"]},yY,t)},xY=C(Kp,{name:"MuiPopover",slot:"Root",overridesResolver:(e,t)=>t.root})({}),CY=C(pr,{name:"MuiPopover",slot:"Paper",overridesResolver:(e,t)=>t.paper})({position:"absolute",overflowY:"auto",overflowX:"hidden",minWidth:16,minHeight:16,maxWidth:"calc(100% - 32px)",maxHeight:"calc(100% - 32px)",outline:0}),EY=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiPopover"}),{action:o,anchorEl:a,anchorOrigin:i={vertical:"top",horizontal:"left"},anchorPosition:l,anchorReference:c="anchorEl",children:u,className:d,container:f,elevation:h=8,marginThreshold:m=16,open:y,PaperProps:g={},transformOrigin:v={vertical:"top",horizontal:"left"},TransitionComponent:b=kb,transitionDuration:w="auto",TransitionProps:{onEntering:x}={}}=r,E=$e(r.TransitionProps,bY),A=$e(r,wY),k=p.useRef(),_=Sn(k,g.ref),$=I({},r,{anchorOrigin:i,anchorReference:c,elevation:h,marginThreshold:m,PaperProps:g,transformOrigin:v,TransitionComponent:b,transitionDuration:w,TransitionProps:E}),L=SY($),O=p.useCallback(()=>{if(c==="anchorPosition")return l;const z=m1(a),M=(z&&z.nodeType===1?z:Fn(k.current).body).getBoundingClientRect();return{top:M.top+Ok(M,i.vertical),left:M.left+Lk(M,i.horizontal)}},[a,i.horizontal,i.vertical,l,c]),P=p.useCallback(z=>({vertical:Ok(z,v.vertical),horizontal:Lk(z,v.horizontal)}),[v.horizontal,v.vertical]),D=p.useCallback(z=>{const R={width:z.offsetWidth,height:z.offsetHeight},M=P(R);if(c==="none")return{top:null,left:null,transformOrigin:Nk(M)};const ee=O();let re=ee.top-M.vertical,Se=ee.left-M.horizontal;const ce=re+R.height,Ce=Se+R.width,xe=ta(m1(a)),Ee=xe.innerHeight-m,tt=xe.innerWidth-m;if(re<m){const me=re-m;re-=me,M.vertical+=me}else if(ce>Ee){const me=ce-Ee;re-=me,M.vertical+=me}if(Se<m){const me=Se-m;Se-=me,M.horizontal+=me}else if(Ce>tt){const me=Ce-tt;Se-=me,M.horizontal+=me}return{top:`${Math.round(re)}px`,left:`${Math.round(Se)}px`,transformOrigin:Nk(M)}},[a,c,O,P,m]),[F,U]=p.useState(y),Y=p.useCallback(()=>{const z=k.current;if(!z)return;const R=D(z);R.top!==null&&(z.style.top=R.top),R.left!==null&&(z.style.left=R.left),z.style.transformOrigin=R.transformOrigin,U(!0)},[D]),V=(z,R)=>{x&&x(z,R),Y()},te=()=>{U(!1)};p.useEffect(()=>{y&&Y()}),p.useImperativeHandle(o,()=>y?{updatePosition:()=>{Y()}}:null,[y,Y]),p.useEffect(()=>{if(!y)return;const z=ml(()=>{Y()}),R=ta(a);return R.addEventListener("resize",z),()=>{z.clear(),R.removeEventListener("resize",z)}},[a,y,Y]);let Z=w;w==="auto"&&!b.muiSupportAuto&&(Z=void 0);const W=f||(a?Fn(m1(a)).body:void 0);return s(xY,I({BackdropProps:{invisible:!0},className:ve(L.root,d),container:W,open:y,ref:n,ownerState:$},A,{children:s(b,I({appear:!0,in:y,onEntering:V,onExited:te,timeout:Z},E,{children:s(CY,I({elevation:h},g,{ref:_,className:ve(L.paper,g.className)},F?void 0:{style:I({},g.style,{opacity:0})},{ownerState:$,children:u}))}))}))}),dx=EY;function TY(e){return je("MuiMenu",e)}Ue("MuiMenu",["root","paper","list"]);const kY=["onEntering"],AY=["autoFocus","children","disableAutoFocusItem","MenuListProps","onClose","open","PaperProps","PopoverClasses","transitionDuration","TransitionProps","variant"],_Y={vertical:"top",horizontal:"right"},RY={vertical:"top",horizontal:"left"},PY=e=>{const{classes:t}=e;return He({root:["root"],paper:["paper"],list:["list"]},TY,t)},IY=C(dx,{shouldForwardProp:e=>Bo(e)||e==="classes",name:"MuiMenu",slot:"Root",overridesResolver:(e,t)=>t.root})({}),$Y=C(pr,{name:"MuiMenu",slot:"Paper",overridesResolver:(e,t)=>t.paper})({maxHeight:"calc(100% - 96px)",WebkitOverflowScrolling:"touch"}),OY=C(l4,{name:"MuiMenu",slot:"List",overridesResolver:(e,t)=>t.list})({outline:0}),LY=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiMenu"}),{autoFocus:o=!0,children:a,disableAutoFocusItem:i=!1,MenuListProps:l={},onClose:c,open:u,PaperProps:d={},PopoverClasses:f,transitionDuration:h="auto",TransitionProps:{onEntering:m}={},variant:y="selectedMenu"}=r,g=$e(r.TransitionProps,kY),v=$e(r,AY),b=on(),w=b.direction==="rtl",x=I({},r,{autoFocus:o,disableAutoFocusItem:i,MenuListProps:l,onEntering:m,PaperProps:d,transitionDuration:h,TransitionProps:g,variant:y}),E=PY(x),A=o&&!i&&u,k=p.useRef(null),_=(O,P)=>{k.current&&k.current.adjustStyleForScrollbar(O,b),m&&m(O,P)},$=O=>{O.key==="Tab"&&(O.preventDefault(),c&&c(O,"tabKeyDown"))};let L=-1;return p.Children.map(a,(O,P)=>{p.isValidElement(O)&&(O.props.disabled||(y==="selectedMenu"&&O.props.selected||L===-1)&&(L=P))}),s(IY,I({onClose:c,anchorOrigin:{vertical:"bottom",horizontal:w?"right":"left"},transformOrigin:w?_Y:RY,PaperProps:I({component:$Y},d,{classes:I({},d.classes,{root:E.paper})}),className:E.root,open:u,ref:n,transitionDuration:h,TransitionProps:I({onEntering:_},g),ownerState:x},v,{classes:f,children:s(OY,I({onKeyDown:$,actions:k,autoFocus:o&&(L===-1||i),autoFocusItem:A,variant:y},l,{className:ve(E.list,l.className),children:a}))}))}),px=LY;function NY(e){return je("MuiMenuItem",e)}const MY=Ue("MuiMenuItem",["root","focusVisible","dense","disabled","divider","gutters","selected"]),Yu=MY,DY=["autoFocus","component","dense","divider","disableGutters","focusVisibleClassName","role","tabIndex","className"],BY=(e,t)=>{const{ownerState:n}=e;return[t.root,n.dense&&t.dense,n.divider&&t.divider,!n.disableGutters&&t.gutters]},FY=e=>{const{disabled:t,dense:n,divider:r,disableGutters:o,selected:a,classes:i}=e,c=He({root:["root",n&&"dense",t&&"disabled",!o&&"gutters",r&&"divider",a&&"selected"]},NY,i);return I({},i,c)},zY=C(Ea,{shouldForwardProp:e=>Bo(e)||e==="classes",name:"MuiMenuItem",slot:"Root",overridesResolver:BY})(({theme:e,ownerState:t})=>I({},e.typography.body1,{display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",minHeight:48,paddingTop:6,paddingBottom:6,boxSizing:"border-box",whiteSpace:"nowrap"},!t.disableGutters&&{paddingLeft:16,paddingRight:16},t.divider&&{borderBottom:`1px solid ${(e.vars||e).palette.divider}`,backgroundClip:"padding-box"},{"&:hover":{textDecoration:"none",backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${Yu.selected}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity),[`&.${Yu.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}},[`&.${Yu.selected}:hover`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity)}},[`&.${Yu.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`&.${Yu.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity},[`& + .${yk.root}`]:{marginTop:e.spacing(1),marginBottom:e.spacing(1)},[`& + .${yk.inset}`]:{marginLeft:52},[`& .${Tm.root}`]:{marginTop:0,marginBottom:0},[`& .${Tm.inset}`]:{paddingLeft:36},[`& .${Ik.root}`]:{minWidth:36}},!t.dense&&{[e.breakpoints.up("sm")]:{minHeight:"auto"}},t.dense&&I({minHeight:32,paddingTop:4,paddingBottom:4},e.typography.body2,{[`& .${Ik.root} svg`]:{fontSize:"1.25rem"}}))),jY=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiMenuItem"}),{autoFocus:o=!1,component:a="li",dense:i=!1,divider:l=!1,disableGutters:c=!1,focusVisibleClassName:u,role:d="menuitem",tabIndex:f,className:h}=r,m=$e(r,DY),y=p.useContext(Ya),g=p.useMemo(()=>({dense:i||y.dense||!1,disableGutters:c}),[y.dense,i,c]),v=p.useRef(null);$o(()=>{o&&v.current&&v.current.focus()},[o]);const b=I({},r,{dense:g.dense,divider:l,disableGutters:c}),w=FY(r),x=Sn(v,n);let E;return r.disabled||(E=f!==void 0?f:-1),s(Ya.Provider,{value:g,children:s(zY,I({ref:x,role:d,tabIndex:E,component:a,focusVisibleClassName:ve(w.focusVisible,u),className:ve(w.root,h)},m,{ownerState:b,classes:w}))})}),bs=jY;function UY(e){return je("MuiNativeSelect",e)}const WY=Ue("MuiNativeSelect",["root","select","multiple","filled","outlined","standard","disabled","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput"]),fx=WY,HY=["className","disabled","IconComponent","inputRef","variant"],VY=e=>{const{classes:t,variant:n,disabled:r,multiple:o,open:a}=e,i={select:["select",n,r&&"disabled",o&&"multiple"],icon:["icon",`icon${ie(n)}`,a&&"iconOpen",r&&"disabled"]};return He(i,UY,t)},c4=({ownerState:e,theme:t})=>I({MozAppearance:"none",WebkitAppearance:"none",userSelect:"none",borderRadius:0,cursor:"pointer","&:focus":I({},t.vars?{backgroundColor:`rgba(${t.vars.palette.common.onBackgroundChannel} / 0.05)`}:{backgroundColor:t.palette.mode==="light"?"rgba(0, 0, 0, 0.05)":"rgba(255, 255, 255, 0.05)"},{borderRadius:0}),"&::-ms-expand":{display:"none"},[`&.${fx.disabled}`]:{cursor:"default"},"&[multiple]":{height:"auto"},"&:not([multiple]) option, &:not([multiple]) optgroup":{backgroundColor:(t.vars||t).palette.background.paper},"&&&":{paddingRight:24,minWidth:16}},e.variant==="filled"&&{"&&&":{paddingRight:32}},e.variant==="outlined"&&{borderRadius:(t.vars||t).shape.borderRadius,"&:focus":{borderRadius:(t.vars||t).shape.borderRadius},"&&&":{paddingRight:32}}),GY=C("select",{name:"MuiNativeSelect",slot:"Select",shouldForwardProp:Bo,overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.select,t[n.variant],{[`&.${fx.multiple}`]:t.multiple}]}})(c4),u4=({ownerState:e,theme:t})=>I({position:"absolute",right:0,top:"calc(50% - .5em)",pointerEvents:"none",color:(t.vars||t).palette.action.active,[`&.${fx.disabled}`]:{color:(t.vars||t).palette.action.disabled}},e.open&&{transform:"rotate(180deg)"},e.variant==="filled"&&{right:7},e.variant==="outlined"&&{right:7}),qY=C("svg",{name:"MuiNativeSelect",slot:"Icon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.icon,n.variant&&t[`icon${ie(n.variant)}`],n.open&&t.iconOpen]}})(u4),KY=p.forwardRef(function(t,n){const{className:r,disabled:o,IconComponent:a,inputRef:i,variant:l="standard"}=t,c=$e(t,HY),u=I({},t,{disabled:o,variant:l}),d=VY(u);return T(p.Fragment,{children:[s(GY,I({ownerState:u,className:ve(d.select,r),disabled:o,ref:i||n},c)),t.multiple?null:s(qY,{as:a,ownerState:u,className:d.icon})]})}),YY=KY;var Mk;const XY=["children","classes","className","label","notched"],JY=C("fieldset")({textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%"}),QY=C("legend")(({ownerState:e,theme:t})=>I({float:"unset",width:"auto",overflow:"hidden"},!e.withLabel&&{padding:0,lineHeight:"11px",transition:t.transitions.create("width",{duration:150,easing:t.transitions.easing.easeOut})},e.withLabel&&I({display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:t.transitions.create("max-width",{duration:50,easing:t.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}},e.notched&&{maxWidth:"100%",transition:t.transitions.create("max-width",{duration:100,easing:t.transitions.easing.easeOut,delay:50})})));function ZY(e){const{className:t,label:n,notched:r}=e,o=$e(e,XY),a=n!=null&&n!=="",i=I({},e,{notched:r,withLabel:a});return s(JY,I({"aria-hidden":!0,className:t,ownerState:i},o,{children:s(QY,{ownerState:i,children:a?s("span",{children:n}):Mk||(Mk=s("span",{className:"notranslate",children:""}))})}))}const eX=["components","fullWidth","inputComponent","label","multiline","notched","slots","type"],tX=e=>{const{classes:t}=e,r=He({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},DW,t);return I({},t,r)},nX=C(nv,{shouldForwardProp:e=>Bo(e)||e==="classes",name:"MuiOutlinedInput",slot:"Root",overridesResolver:ev})(({theme:e,ownerState:t})=>{const n=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return I({position:"relative",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${Ia.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${Ia.notchedOutline}`]:{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:n}},[`&.${Ia.focused} .${Ia.notchedOutline}`]:{borderColor:(e.vars||e).palette[t.color].main,borderWidth:2},[`&.${Ia.error} .${Ia.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},[`&.${Ia.disabled} .${Ia.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled}},t.startAdornment&&{paddingLeft:14},t.endAdornment&&{paddingRight:14},t.multiline&&I({padding:"16.5px 14px"},t.size==="small"&&{padding:"8.5px 14px"}))}),rX=C(ZY,{name:"MuiOutlinedInput",slot:"NotchedOutline",overridesResolver:(e,t)=>t.notchedOutline})(({theme:e})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}}),oX=C(rv,{name:"MuiOutlinedInput",slot:"Input",overridesResolver:tv})(({theme:e,ownerState:t})=>I({padding:"16.5px 14px"},!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderRadius:"inherit"}},e.vars&&{"&:-webkit-autofill":{borderRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},t.size==="small"&&{padding:"8.5px 14px"},t.multiline&&{padding:0},t.startAdornment&&{paddingLeft:0},t.endAdornment&&{paddingRight:0})),d4=p.forwardRef(function(t,n){var r,o,a,i,l;const c=Ve({props:t,name:"MuiOutlinedInput"}),{components:u={},fullWidth:d=!1,inputComponent:f="input",label:h,multiline:m=!1,notched:y,slots:g={},type:v="text"}=c,b=$e(c,eX),w=tX(c),x=oi(),E=_s({props:c,muiFormControl:x,states:["required"]}),A=I({},c,{color:E.color||"primary",disabled:E.disabled,error:E.error,focused:E.focused,formControl:x,fullWidth:d,hiddenLabel:E.hiddenLabel,multiline:m,size:E.size,type:v}),k=(r=(o=g.root)!=null?o:u.Root)!=null?r:nX,_=(a=(i=g.input)!=null?i:u.Input)!=null?a:oX;return s(ov,I({slots:{root:k,input:_},renderSuffix:$=>s(rX,{ownerState:A,className:w.notchedOutline,label:h!=null&&h!==""&&E.required?l||(l=T(p.Fragment,{children:[h," ","*"]})):h,notched:typeof y<"u"?y:Boolean($.startAdornment||$.filled||$.focused)}),fullWidth:d,inputComponent:f,multiline:m,ref:n,type:v},b,{classes:I({},w,{notchedOutline:null})}))});d4.muiName="Input";const p4=d4,aX=Ye(s("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"RadioButtonUnchecked"),iX=Ye(s("path",{d:"M8.465 8.465C9.37 7.56 10.62 7 12 7C14.76 7 17 9.24 17 12C17 13.38 16.44 14.63 15.535 15.535C14.63 16.44 13.38 17 12 17C9.24 17 7 14.76 7 12C7 10.62 7.56 9.37 8.465 8.465Z"}),"RadioButtonChecked"),sX=C("span")({position:"relative",display:"flex"}),lX=C(aX)({transform:"scale(1)"}),cX=C(iX)(({theme:e,ownerState:t})=>I({left:0,position:"absolute",transform:"scale(0)",transition:e.transitions.create("transform",{easing:e.transitions.easing.easeIn,duration:e.transitions.duration.shortest})},t.checked&&{transform:"scale(1)",transition:e.transitions.create("transform",{easing:e.transitions.easing.easeOut,duration:e.transitions.duration.shortest})}));function f4(e){const{checked:t=!1,classes:n={},fontSize:r}=e,o=I({},e,{checked:t});return T(sX,{className:n.root,ownerState:o,children:[s(lX,{fontSize:r,className:n.background,ownerState:o}),s(cX,{fontSize:r,className:n.dot,ownerState:o})]})}const uX=p.createContext(void 0),h4=uX;function dX(){return p.useContext(h4)}function pX(e){return je("MuiRadio",e)}const fX=Ue("MuiRadio",["root","checked","disabled","colorPrimary","colorSecondary"]),Dk=fX,hX=["checked","checkedIcon","color","icon","name","onChange","size","className"],mX=e=>{const{classes:t,color:n}=e,r={root:["root",`color${ie(n)}`]};return I({},t,He(r,pX,t))},gX=C(lx,{shouldForwardProp:e=>Bo(e)||e==="classes",name:"MuiRadio",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`color${ie(n.color)}`]]}})(({theme:e,ownerState:t})=>I({color:(e.vars||e).palette.text.secondary},!t.disableRipple&&{"&:hover":{backgroundColor:e.vars?`rgba(${t.color==="default"?e.vars.palette.action.activeChannel:e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(t.color==="default"?e.palette.action.active:e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},t.color!=="default"&&{[`&.${Dk.checked}`]:{color:(e.vars||e).palette[t.color].main}},{[`&.${Dk.disabled}`]:{color:(e.vars||e).palette.action.disabled}}));function vX(e,t){return typeof t=="object"&&t!==null?e===t:String(e)===String(t)}const Bk=s(f4,{checked:!0}),Fk=s(f4,{}),yX=p.forwardRef(function(t,n){var r,o;const a=Ve({props:t,name:"MuiRadio"}),{checked:i,checkedIcon:l=Bk,color:c="primary",icon:u=Fk,name:d,onChange:f,size:h="medium",className:m}=a,y=$e(a,hX),g=I({},a,{color:c,size:h}),v=mX(g),b=dX();let w=i;const x=ym(f,b&&b.onChange);let E=d;return b&&(typeof w>"u"&&(w=vX(b.value,a.value)),typeof E>"u"&&(E=b.name)),s(gX,I({type:"radio",icon:p.cloneElement(u,{fontSize:(r=Fk.props.fontSize)!=null?r:h}),checkedIcon:p.cloneElement(l,{fontSize:(o=Bk.props.fontSize)!=null?o:h}),ownerState:g,classes:v,name:E,checked:w,onChange:x,ref:n,className:ve(v.root,m)},y))}),ol=yX,bX=["actions","children","defaultValue","name","onChange","value"],wX=p.forwardRef(function(t,n){const{actions:r,children:o,defaultValue:a,name:i,onChange:l,value:c}=t,u=$e(t,bX),d=p.useRef(null),[f,h]=Sa({controlled:c,default:a,name:"RadioGroup"});p.useImperativeHandle(r,()=>({focus:()=>{let v=d.current.querySelector("input:not(:disabled):checked");v||(v=d.current.querySelector("input:not(:disabled)")),v&&v.focus()}}),[]);const m=Sn(n,d),y=nu(i),g=p.useMemo(()=>({name:y,onChange(v){h(v.target.value),l&&l(v,v.target.value)},value:f}),[y,l,h,f]);return s(h4.Provider,{value:g,children:s(lq,I({role:"radiogroup",ref:m},u,{children:o}))})}),hx=wX;function SX(e){return je("MuiSelect",e)}const xX=Ue("MuiSelect",["select","multiple","filled","outlined","standard","disabled","focused","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput"]),Kf=xX;var zk;const CX=["aria-describedby","aria-label","autoFocus","autoWidth","children","className","defaultOpen","defaultValue","disabled","displayEmpty","IconComponent","inputRef","labelId","MenuProps","multiple","name","onBlur","onChange","onClose","onFocus","onOpen","open","readOnly","renderValue","SelectDisplayProps","tabIndex","type","value","variant"],EX=C("div",{name:"MuiSelect",slot:"Select",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`&.${Kf.select}`]:t.select},{[`&.${Kf.select}`]:t[n.variant]},{[`&.${Kf.multiple}`]:t.multiple}]}})(c4,{[`&.${Kf.select}`]:{height:"auto",minHeight:"1.4375em",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"}}),TX=C("svg",{name:"MuiSelect",slot:"Icon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.icon,n.variant&&t[`icon${ie(n.variant)}`],n.open&&t.iconOpen]}})(u4),kX=C("input",{shouldForwardProp:e=>WS(e)&&e!=="classes",name:"MuiSelect",slot:"NativeInput",overridesResolver:(e,t)=>t.nativeInput})({bottom:0,left:0,position:"absolute",opacity:0,pointerEvents:"none",width:"100%",boxSizing:"border-box"});function jk(e,t){return typeof t=="object"&&t!==null?e===t:String(e)===String(t)}function AX(e){return e==null||typeof e=="string"&&!e.trim()}const _X=e=>{const{classes:t,variant:n,disabled:r,multiple:o,open:a}=e,i={select:["select",n,r&&"disabled",o&&"multiple"],icon:["icon",`icon${ie(n)}`,a&&"iconOpen",r&&"disabled"],nativeInput:["nativeInput"]};return He(i,SX,t)},RX=p.forwardRef(function(t,n){const{"aria-describedby":r,"aria-label":o,autoFocus:a,autoWidth:i,children:l,className:c,defaultOpen:u,defaultValue:d,disabled:f,displayEmpty:h,IconComponent:m,inputRef:y,labelId:g,MenuProps:v={},multiple:b,name:w,onBlur:x,onChange:E,onClose:A,onFocus:k,onOpen:_,open:$,readOnly:L,renderValue:O,SelectDisplayProps:P={},tabIndex:D,value:F,variant:U="standard"}=t,Y=$e(t,CX),[V,te]=Sa({controlled:F,default:d,name:"Select"}),[Z,W]=Sa({controlled:$,default:u,name:"Select"}),z=p.useRef(null),R=p.useRef(null),[M,ee]=p.useState(null),{current:re}=p.useRef($!=null),[Se,ce]=p.useState(),Ce=Sn(n,y),xe=p.useCallback(K=>{R.current=K,K&&ee(K)},[]),Ee=M==null?void 0:M.parentNode;p.useImperativeHandle(Ce,()=>({focus:()=>{R.current.focus()},node:z.current,value:V}),[V]),p.useEffect(()=>{u&&Z&&M&&!re&&(ce(i?null:Ee.clientWidth),R.current.focus())},[M,i]),p.useEffect(()=>{a&&R.current.focus()},[a]),p.useEffect(()=>{if(!g)return;const K=Fn(R.current).getElementById(g);if(K){const se=()=>{getSelection().isCollapsed&&R.current.focus()};return K.addEventListener("click",se),()=>{K.removeEventListener("click",se)}}},[g]);const tt=(K,se)=>{K?_&&_(se):A&&A(se),re||(ce(i?null:Ee.clientWidth),W(K))},me=K=>{K.button===0&&(K.preventDefault(),R.current.focus(),tt(!0,K))},Ge=K=>{tt(!1,K)},qe=p.Children.toArray(l),Be=K=>{const se=qe.map(Ae=>Ae.props.value).indexOf(K.target.value);if(se===-1)return;const be=qe[se];te(be.props.value),E&&E(K,be)},he=K=>se=>{let be;if(se.currentTarget.hasAttribute("tabindex")){if(b){be=Array.isArray(V)?V.slice():[];const Ae=V.indexOf(K.props.value);Ae===-1?be.push(K.props.value):be.splice(Ae,1)}else be=K.props.value;if(K.props.onClick&&K.props.onClick(se),V!==be&&(te(be),E)){const Ae=se.nativeEvent||se,mt=new Ae.constructor(Ae.type,Ae);Object.defineProperty(mt,"target",{writable:!0,value:{value:be,name:w}}),E(mt,K)}b||tt(!1,se)}},Et=K=>{L||[" ","ArrowUp","ArrowDown","Enter"].indexOf(K.key)!==-1&&(K.preventDefault(),tt(!0,K))},Ke=M!==null&&Z,ct=K=>{!Ke&&x&&(Object.defineProperty(K,"target",{writable:!0,value:{value:V,name:w}}),x(K))};delete Y["aria-invalid"];let Rt,dt;const rt=[];let Nt=!1;(ax({value:V})||h)&&(O?Rt=O(V):Nt=!0);const xt=qe.map((K,se,be)=>{var Ae,mt,et,ht;if(!p.isValidElement(K))return null;let Xt;if(b){if(!Array.isArray(V))throw new Error(ms(2));Xt=V.some(pt=>jk(pt,K.props.value)),Xt&&Nt&&rt.push(K.props.children)}else Xt=jk(V,K.props.value),Xt&&Nt&&(dt=K.props.children);if(K.props.value===void 0)return p.cloneElement(K,{"aria-readonly":!0,role:"option"});const Mn=()=>{if(V)return Xt;const pt=be.find(pn=>{var Vt;return(pn==null||(Vt=pn.props)==null?void 0:Vt.value)!==void 0&&pn.props.disabled!==!0});return K===pt?!0:Xt};return p.cloneElement(K,{"aria-selected":Xt?"true":"false",onClick:he(K),onKeyUp:pt=>{pt.key===" "&&pt.preventDefault(),K.props.onKeyUp&&K.props.onKeyUp(pt)},role:"option",selected:((Ae=be[0])==null||(mt=Ae.props)==null?void 0:mt.value)===void 0||((et=be[0])==null||(ht=et.props)==null?void 0:ht.disabled)===!0?Mn():Xt,value:void 0,"data-value":K.props.value})});Nt&&(b?rt.length===0?Rt=null:Rt=rt.reduce((K,se,be)=>(K.push(se),be<rt.length-1&&K.push(", "),K),[]):Rt=dt);let pe=Se;!i&&re&&M&&(pe=Ee.clientWidth);let Te;typeof D<"u"?Te=D:Te=f?null:0;const Xe=P.id||(w?`mui-component-select-${w}`:void 0),De=I({},t,{variant:U,value:V,open:Ke}),q=_X(De);return T(p.Fragment,{children:[s(EX,I({ref:xe,tabIndex:Te,role:"button","aria-disabled":f?"true":void 0,"aria-expanded":Ke?"true":"false","aria-haspopup":"listbox","aria-label":o,"aria-labelledby":[g,Xe].filter(Boolean).join(" ")||void 0,"aria-describedby":r,onKeyDown:Et,onMouseDown:f||L?null:me,onBlur:ct,onFocus:k},P,{ownerState:De,className:ve(P.className,q.select,c),id:Xe,children:AX(Rt)?zk||(zk=s("span",{className:"notranslate",children:""})):Rt})),s(kX,I({value:Array.isArray(V)?V.join(","):V,name:w,ref:z,"aria-hidden":!0,onChange:Be,tabIndex:-1,disabled:f,className:q.nativeInput,autoFocus:a,ownerState:De},Y)),s(TX,{as:m,className:q.icon,ownerState:De}),s(px,I({id:`menu-${w||""}`,anchorEl:Ee,open:Ke,onClose:Ge,anchorOrigin:{vertical:"bottom",horizontal:"center"},transformOrigin:{vertical:"top",horizontal:"center"}},v,{MenuListProps:I({"aria-labelledby":g,role:"listbox",disableListWrap:!0},v.MenuListProps),PaperProps:I({},v.PaperProps,{style:I({minWidth:pe},v.PaperProps!=null?v.PaperProps.style:null)}),children:xt}))]})}),PX=RX;var Uk,Wk;const IX=["autoWidth","children","classes","className","defaultOpen","displayEmpty","IconComponent","id","input","inputProps","label","labelId","MenuProps","multiple","native","onClose","onOpen","open","renderValue","SelectDisplayProps","variant"],$X=e=>{const{classes:t}=e;return t},mx={name:"MuiSelect",overridesResolver:(e,t)=>t.root,shouldForwardProp:e=>Bo(e)&&e!=="variant",slot:"Root"},OX=C(r4,mx)(""),LX=C(p4,mx)(""),NX=C(J$,mx)(""),m4=p.forwardRef(function(t,n){const r=Ve({name:"MuiSelect",props:t}),{autoWidth:o=!1,children:a,classes:i={},className:l,defaultOpen:c=!1,displayEmpty:u=!1,IconComponent:d=H$,id:f,input:h,inputProps:m,label:y,labelId:g,MenuProps:v,multiple:b=!1,native:w=!1,onClose:x,onOpen:E,open:A,renderValue:k,SelectDisplayProps:_,variant:$="outlined"}=r,L=$e(r,IX),O=w?YY:PX,P=oi(),F=_s({props:r,muiFormControl:P,states:["variant"]}).variant||$,U=h||{standard:Uk||(Uk=s(OX,{})),outlined:s(LX,{label:y}),filled:Wk||(Wk=s(NX,{}))}[F],Y=I({},r,{variant:F,classes:i}),V=$X(Y),te=Sn(n,U.ref);return s(p.Fragment,{children:p.cloneElement(U,I({inputComponent:O,inputProps:I({children:a,IconComponent:d,variant:F,type:void 0,multiple:b},w?{id:f}:{autoWidth:o,defaultOpen:c,displayEmpty:u,labelId:g,MenuProps:v,onClose:x,onOpen:E,open:A,renderValue:k,SelectDisplayProps:I({id:f},_)},m,{classes:m?Ro(V,m.classes):V},h?h.props.inputProps:{})},b&&w&&F==="outlined"?{notched:!0}:{},{ref:te,className:ve(U.props.className,l)},!h&&{variant:F},L))})});m4.muiName="Select";const Xp=m4,MX=e=>!e||!qa(e),DX=MX;function BX(e){return je("MuiSlider",e)}const FX=Ue("MuiSlider",["root","active","colorPrimary","colorSecondary","disabled","dragging","focusVisible","mark","markActive","marked","markLabel","markLabelActive","rail","sizeSmall","thumb","thumbColorPrimary","thumbColorSecondary","track","trackInverted","trackFalse","thumbSizeSmall","valueLabel","valueLabelOpen","valueLabelCircle","valueLabelLabel","vertical"]),wa=FX,zX=e=>{const{open:t}=e;return{offset:ve(t&&wa.valueLabelOpen),circle:wa.valueLabelCircle,label:wa.valueLabelLabel}};function jX(e){const{children:t,className:n,value:r}=e,o=zX(e);return t?p.cloneElement(t,{className:ve(t.props.className)},T(p.Fragment,{children:[t.props.children,s("span",{className:ve(o.offset,n),"aria-hidden":!0,children:s("span",{className:o.circle,children:s("span",{className:o.label,children:r})})})]})):null}const UX=["aria-label","aria-valuetext","aria-labelledby","component","components","componentsProps","color","classes","className","disableSwap","disabled","getAriaLabel","getAriaValueText","marks","max","min","name","onChange","onChangeCommitted","orientation","size","step","scale","slotProps","slots","tabIndex","track","value","valueLabelDisplay","valueLabelFormat"],Hk=(e,t,n)=>(e-t)*100/(n-t);function Vk(e){return e}const WX=C("span",{name:"MuiSlider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`color${ie(n.color)}`],n.size!=="medium"&&t[`size${ie(n.size)}`],n.marked&&t.marked,n.orientation==="vertical"&&t.vertical,n.track==="inverted"&&t.trackInverted,n.track===!1&&t.trackFalse]}})(({theme:e,ownerState:t})=>I({borderRadius:12,boxSizing:"content-box",display:"inline-block",position:"relative",cursor:"pointer",touchAction:"none",color:(e.vars||e).palette[t.color].main,WebkitTapHighlightColor:"transparent"},t.orientation==="horizontal"&&I({height:4,width:"100%",padding:"13px 0","@media (pointer: coarse)":{padding:"20px 0"}},t.size==="small"&&{height:2},t.marked&&{marginBottom:20}),t.orientation==="vertical"&&I({height:"100%",width:4,padding:"0 13px","@media (pointer: coarse)":{padding:"0 20px"}},t.size==="small"&&{width:2},t.marked&&{marginRight:44}),{"@media print":{colorAdjust:"exact"},[`&.${wa.disabled}`]:{pointerEvents:"none",cursor:"default",color:(e.vars||e).palette.grey[400]},[`&.${wa.dragging}`]:{[`& .${wa.thumb}, & .${wa.track}`]:{transition:"none"}}})),HX=C("span",{name:"MuiSlider",slot:"Rail",overridesResolver:(e,t)=>t.rail})(({ownerState:e})=>I({display:"block",position:"absolute",borderRadius:"inherit",backgroundColor:"currentColor",opacity:.38},e.orientation==="horizontal"&&{width:"100%",height:"inherit",top:"50%",transform:"translateY(-50%)"},e.orientation==="vertical"&&{height:"100%",width:"inherit",left:"50%",transform:"translateX(-50%)"},e.track==="inverted"&&{opacity:1})),VX=C("span",{name:"MuiSlider",slot:"Track",overridesResolver:(e,t)=>t.track})(({theme:e,ownerState:t})=>{const n=e.palette.mode==="light"?vs(e.palette[t.color].main,.62):gs(e.palette[t.color].main,.5);return I({display:"block",position:"absolute",borderRadius:"inherit",border:"1px solid currentColor",backgroundColor:"currentColor",transition:e.transitions.create(["left","width","bottom","height"],{duration:e.transitions.duration.shortest})},t.size==="small"&&{border:"none"},t.orientation==="horizontal"&&{height:"inherit",top:"50%",transform:"translateY(-50%)"},t.orientation==="vertical"&&{width:"inherit",left:"50%",transform:"translateX(-50%)"},t.track===!1&&{display:"none"},t.track==="inverted"&&{backgroundColor:e.vars?e.vars.palette.Slider[`${t.color}Track`]:n,borderColor:e.vars?e.vars.palette.Slider[`${t.color}Track`]:n})}),GX=C("span",{name:"MuiSlider",slot:"Thumb",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.thumb,t[`thumbColor${ie(n.color)}`],n.size!=="medium"&&t[`thumbSize${ie(n.size)}`]]}})(({theme:e,ownerState:t})=>I({position:"absolute",width:20,height:20,boxSizing:"border-box",borderRadius:"50%",outline:0,backgroundColor:"currentColor",display:"flex",alignItems:"center",justifyContent:"center",transition:e.transitions.create(["box-shadow","left","bottom"],{duration:e.transitions.duration.shortest})},t.size==="small"&&{width:12,height:12},t.orientation==="horizontal"&&{top:"50%",transform:"translate(-50%, -50%)"},t.orientation==="vertical"&&{left:"50%",transform:"translate(-50%, 50%)"},{"&:before":I({position:"absolute",content:'""',borderRadius:"inherit",width:"100%",height:"100%",boxShadow:(e.vars||e).shadows[2]},t.size==="small"&&{boxShadow:"none"}),"&::after":{position:"absolute",content:'""',borderRadius:"50%",width:42,height:42,top:"50%",left:"50%",transform:"translate(-50%, -50%)"},[`&:hover, &.${wa.focusVisible}`]:{boxShadow:`0px 0px 0px 8px ${e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / 0.16)`:Ot(e.palette[t.color].main,.16)}`,"@media (hover: none)":{boxShadow:"none"}},[`&.${wa.active}`]:{boxShadow:`0px 0px 0px 14px ${e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / 0.16)`:Ot(e.palette[t.color].main,.16)}`},[`&.${wa.disabled}`]:{"&:hover":{boxShadow:"none"}}})),qX=C(jX,{name:"MuiSlider",slot:"ValueLabel",overridesResolver:(e,t)=>t.valueLabel})(({theme:e,ownerState:t})=>I({[`&.${wa.valueLabelOpen}`]:{transform:"translateY(-100%) scale(1)"},zIndex:1,whiteSpace:"nowrap"},e.typography.body2,{fontWeight:500,transition:e.transitions.create(["transform"],{duration:e.transitions.duration.shortest}),transform:"translateY(-100%) scale(0)",position:"absolute",backgroundColor:(e.vars||e).palette.grey[600],borderRadius:2,color:(e.vars||e).palette.common.white,display:"flex",alignItems:"center",justifyContent:"center",padding:"0.25rem 0.75rem"},t.orientation==="horizontal"&&{top:"-10px",transformOrigin:"bottom center","&:before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, 50%) rotate(45deg)",backgroundColor:"inherit",bottom:0,left:"50%"}},t.orientation==="vertical"&&{right:"30px",top:"24px",transformOrigin:"right center","&:before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, 50%) rotate(45deg)",backgroundColor:"inherit",right:"-20%",top:"25%"}},t.size==="small"&&{fontSize:e.typography.pxToRem(12),padding:"0.25rem 0.5rem"})),KX=C("span",{name:"MuiSlider",slot:"Mark",shouldForwardProp:e=>WS(e)&&e!=="markActive",overridesResolver:(e,t)=>{const{markActive:n}=e;return[t.mark,n&&t.markActive]}})(({theme:e,ownerState:t,markActive:n})=>I({position:"absolute",width:2,height:2,borderRadius:1,backgroundColor:"currentColor"},t.orientation==="horizontal"&&{top:"50%",transform:"translate(-1px, -50%)"},t.orientation==="vertical"&&{left:"50%",transform:"translate(-50%, 1px)"},n&&{backgroundColor:(e.vars||e).palette.background.paper,opacity:.8})),YX=C("span",{name:"MuiSlider",slot:"MarkLabel",shouldForwardProp:e=>WS(e)&&e!=="markLabelActive",overridesResolver:(e,t)=>t.markLabel})(({theme:e,ownerState:t,markLabelActive:n})=>I({},e.typography.body2,{color:(e.vars||e).palette.text.secondary,position:"absolute",whiteSpace:"nowrap"},t.orientation==="horizontal"&&{top:30,transform:"translateX(-50%)","@media (pointer: coarse)":{top:40}},t.orientation==="vertical"&&{left:36,transform:"translateY(50%)","@media (pointer: coarse)":{left:44}},n&&{color:(e.vars||e).palette.text.primary})),XX=e=>{const{disabled:t,dragging:n,marked:r,orientation:o,track:a,classes:i,color:l,size:c}=e,u={root:["root",t&&"disabled",n&&"dragging",r&&"marked",o==="vertical"&&"vertical",a==="inverted"&&"trackInverted",a===!1&&"trackFalse",l&&`color${ie(l)}`,c&&`size${ie(c)}`],rail:["rail"],track:["track"],mark:["mark"],markActive:["markActive"],markLabel:["markLabel"],markLabelActive:["markLabelActive"],valueLabel:["valueLabel"],thumb:["thumb",t&&"disabled",c&&`thumbSize${ie(c)}`,l&&`thumbColor${ie(l)}`],active:["active"],disabled:["disabled"],focusVisible:["focusVisible"]};return He(u,BX,i)},JX=({children:e})=>e,QX=p.forwardRef(function(t,n){var r,o,a,i,l,c,u,d,f,h,m,y,g,v,b,w,x,E,A,k,_,$,L,O;const P=Ve({props:t,name:"MuiSlider"}),F=on().direction==="rtl",{"aria-label":U,"aria-valuetext":Y,"aria-labelledby":V,component:te="span",components:Z={},componentsProps:W={},color:z="primary",classes:R,className:M,disableSwap:ee=!1,disabled:re=!1,getAriaLabel:Se,getAriaValueText:ce,marks:Ce=!1,max:xe=100,min:Ee=0,orientation:tt="horizontal",size:me="medium",step:Ge=1,scale:qe=Vk,slotProps:Be,slots:he,track:Et="normal",valueLabelDisplay:Ke="off",valueLabelFormat:ct=Vk}=P,Rt=$e(P,UX),dt=I({},P,{isRtl:F,max:xe,min:Ee,classes:R,disabled:re,disableSwap:ee,orientation:tt,marks:Ce,color:z,size:me,step:Ge,scale:qe,track:Et,valueLabelDisplay:Ke,valueLabelFormat:ct}),{axisProps:rt,getRootProps:Nt,getHiddenInputProps:xt,getThumbProps:pe,open:Te,active:Xe,axis:De,focusedThumbIndex:q,range:K,dragging:se,marks:be,values:Ae,trackOffset:mt,trackLeap:et}=fj(I({},dt,{ref:n}));dt.marked=be.length>0&&be.some(ue=>ue.label),dt.dragging=se,dt.focusedThumbIndex=q;const ht=XX(dt),Xt=(r=(o=he==null?void 0:he.root)!=null?o:Z.Root)!=null?r:WX,Mn=(a=(i=he==null?void 0:he.rail)!=null?i:Z.Rail)!=null?a:HX,pt=(l=(c=he==null?void 0:he.track)!=null?c:Z.Track)!=null?l:VX,pn=(u=(d=he==null?void 0:he.thumb)!=null?d:Z.Thumb)!=null?u:GX,Vt=(f=(h=he==null?void 0:he.valueLabel)!=null?h:Z.ValueLabel)!=null?f:qX,en=(m=(y=he==null?void 0:he.mark)!=null?y:Z.Mark)!=null?m:KX,Ft=(g=(v=he==null?void 0:he.markLabel)!=null?v:Z.MarkLabel)!=null?g:YX,Hn=(b=(w=he==null?void 0:he.input)!=null?w:Z.Input)!=null?b:"input",br=(x=Be==null?void 0:Be.root)!=null?x:W.root,ro=(E=Be==null?void 0:Be.rail)!=null?E:W.rail,yo=(A=Be==null?void 0:Be.track)!=null?A:W.track,bo=(k=Be==null?void 0:Be.thumb)!=null?k:W.thumb,Rr=(_=Be==null?void 0:Be.valueLabel)!=null?_:W.valueLabel,oo=($=Be==null?void 0:Be.mark)!=null?$:W.mark,Jn=(L=Be==null?void 0:Be.markLabel)!=null?L:W.markLabel,ao=(O=Be==null?void 0:Be.input)!=null?O:W.input,wr=ga({elementType:Xt,getSlotProps:Nt,externalSlotProps:br,externalForwardedProps:Rt,additionalProps:I({},DX(Xt)&&{as:te}),ownerState:I({},dt,br==null?void 0:br.ownerState),className:[ht.root,M]}),Bt=ga({elementType:Mn,externalSlotProps:ro,ownerState:dt,className:ht.rail}),Gt=ga({elementType:pt,externalSlotProps:yo,additionalProps:{style:I({},rt[De].offset(mt),rt[De].leap(et))},ownerState:I({},dt,yo==null?void 0:yo.ownerState),className:ht.track}),jn=ga({elementType:pn,getSlotProps:pe,externalSlotProps:bo,ownerState:I({},dt,bo==null?void 0:bo.ownerState)}),hr=ga({elementType:Vt,externalSlotProps:Rr,ownerState:I({},dt,Rr==null?void 0:Rr.ownerState),className:ht.valueLabel}),Kr=ga({elementType:en,externalSlotProps:oo,ownerState:dt,className:ht.mark}),Yr=ga({elementType:Ft,externalSlotProps:Jn,ownerState:dt}),pa=ga({elementType:Hn,getSlotProps:xt,externalSlotProps:ao,ownerState:dt});return T(Xt,I({},wr,{children:[s(Mn,I({},Bt)),s(pt,I({},Gt)),be.filter(ue=>ue.value>=Ee&&ue.value<=xe).map((ue,ae)=>{const Fe=Hk(ue.value,Ee,xe),ot=rt[De].offset(Fe);let kt;return Et===!1?kt=Ae.indexOf(ue.value)!==-1:kt=Et==="normal"&&(K?ue.value>=Ae[0]&&ue.value<=Ae[Ae.length-1]:ue.value<=Ae[0])||Et==="inverted"&&(K?ue.value<=Ae[0]||ue.value>=Ae[Ae.length-1]:ue.value>=Ae[0]),T(p.Fragment,{children:[s(en,I({"data-index":ae},Kr,!qa(en)&&{markActive:kt},{style:I({},ot,Kr.style),className:ve(Kr.className,kt&&ht.markActive)})),ue.label!=null?s(Ft,I({"aria-hidden":!0,"data-index":ae},Yr,!qa(Ft)&&{markLabelActive:kt},{style:I({},ot,Yr.style),className:ve(ht.markLabel,Yr.className,kt&&ht.markLabelActive),children:ue.label})):null]},ae)}),Ae.map((ue,ae)=>{const Fe=Hk(ue,Ee,xe),ot=rt[De].offset(Fe),kt=Ke==="off"?JX:Vt;return s(p.Fragment,{children:s(kt,I({},!qa(kt)&&{valueLabelFormat:ct,valueLabelDisplay:Ke,value:typeof ct=="function"?ct(qe(ue),ae):ct,index:ae,open:Te===ae||Xe===ae||Ke==="on",disabled:re},hr,{children:s(pn,I({"data-index":ae,"data-focusvisible":q===ae},jn,{className:ve(ht.thumb,jn.className,Xe===ae&&ht.active,q===ae&&ht.focusVisible),style:I({},ot,{pointerEvents:ee&&Xe!==ae?"none":void 0},jn.style),children:s(Hn,I({"data-index":ae,"aria-label":Se?Se(ae):U,"aria-valuenow":qe(ue),"aria-labelledby":V,"aria-valuetext":ce?ce(qe(ue),ae):Y,value:Ae[ae]},pa))}))}))},ae)})]}))}),ZX=QX;function eJ(e){return je("MuiTooltip",e)}const tJ=Ue("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),Wa=tJ,nJ=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function rJ(e){return Math.round(e*1e5)/1e5}const oJ=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:a}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${ie(a.split("-")[0])}`],arrow:["arrow"]};return He(i,eJ,t)},aJ=C(Qg,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>I({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${Wa.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${Wa.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${Wa.arrow}`]:I({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${Wa.arrow}`]:I({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),iJ=C("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${ie(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>I({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:Ot(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${rJ(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${Wa.popper}[data-popper-placement*="left"] &`]:I({transformOrigin:"right center"},t.isRtl?I({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):I({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${Wa.popper}[data-popper-placement*="right"] &`]:I({transformOrigin:"left center"},t.isRtl?I({marginRight:"14px"},t.touch&&{marginRight:"24px"}):I({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${Wa.popper}[data-popper-placement*="top"] &`]:I({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${Wa.popper}[data-popper-placement*="bottom"] &`]:I({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),sJ=C("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:Ot(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Yf=!1,g1=null,Xu={x:0,y:0};function Xf(e,t){return n=>{t&&t(n),e(n)}}const lJ=p.forwardRef(function(t,n){var r,o,a,i,l,c,u,d,f,h,m,y,g,v,b,w,x,E,A;const k=Ve({props:t,name:"MuiTooltip"}),{arrow:_=!1,children:$,components:L={},componentsProps:O={},describeChild:P=!1,disableFocusListener:D=!1,disableHoverListener:F=!1,disableInteractive:U=!1,disableTouchListener:Y=!1,enterDelay:V=100,enterNextDelay:te=0,enterTouchDelay:Z=700,followCursor:W=!1,id:z,leaveDelay:R=0,leaveTouchDelay:M=1500,onClose:ee,onOpen:re,open:Se,placement:ce="bottom",PopperComponent:Ce,PopperProps:xe={},slotProps:Ee={},slots:tt={},title:me,TransitionComponent:Ge=kb,TransitionProps:qe}=k,Be=$e(k,nJ),he=on(),Et=he.direction==="rtl",[Ke,ct]=p.useState(),[Rt,dt]=p.useState(null),rt=p.useRef(!1),Nt=U||W,xt=p.useRef(),pe=p.useRef(),Te=p.useRef(),Xe=p.useRef(),[De,q]=Sa({controlled:Se,default:!1,name:"Tooltip",state:"open"});let K=De;const se=nu(z),be=p.useRef(),Ae=p.useCallback(()=>{be.current!==void 0&&(document.body.style.WebkitUserSelect=be.current,be.current=void 0),clearTimeout(Xe.current)},[]);p.useEffect(()=>()=>{clearTimeout(xt.current),clearTimeout(pe.current),clearTimeout(Te.current),Ae()},[Ae]);const mt=yt=>{clearTimeout(g1),Yf=!0,q(!0),re&&!K&&re(yt)},et=gr(yt=>{clearTimeout(g1),g1=setTimeout(()=>{Yf=!1},800+R),q(!1),ee&&K&&ee(yt),clearTimeout(xt.current),xt.current=setTimeout(()=>{rt.current=!1},he.transitions.duration.shortest)}),ht=yt=>{rt.current&&yt.type!=="touchstart"||(Ke&&Ke.removeAttribute("title"),clearTimeout(pe.current),clearTimeout(Te.current),V||Yf&&te?pe.current=setTimeout(()=>{mt(yt)},Yf?te:V):mt(yt))},Xt=yt=>{clearTimeout(pe.current),clearTimeout(Te.current),Te.current=setTimeout(()=>{et(yt)},R)},{isFocusVisibleRef:Mn,onBlur:pt,onFocus:pn,ref:Vt}=jp(),[,en]=p.useState(!1),Ft=yt=>{pt(yt),Mn.current===!1&&(en(!1),Xt(yt))},Hn=yt=>{Ke||ct(yt.currentTarget),pn(yt),Mn.current===!0&&(en(!0),ht(yt))},br=yt=>{rt.current=!0;const Rn=$.props;Rn.onTouchStart&&Rn.onTouchStart(yt)},ro=ht,yo=Xt,bo=yt=>{br(yt),clearTimeout(Te.current),clearTimeout(xt.current),Ae(),be.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Xe.current=setTimeout(()=>{document.body.style.WebkitUserSelect=be.current,ht(yt)},Z)},Rr=yt=>{$.props.onTouchEnd&&$.props.onTouchEnd(yt),Ae(),clearTimeout(Te.current),Te.current=setTimeout(()=>{et(yt)},M)};p.useEffect(()=>{if(!K)return;function yt(Rn){(Rn.key==="Escape"||Rn.key==="Esc")&&et(Rn)}return document.addEventListener("keydown",yt),()=>{document.removeEventListener("keydown",yt)}},[et,K]);const oo=Sn($.ref,Vt,ct,n);!me&&me!==0&&(K=!1);const Jn=p.useRef(),ao=yt=>{const Rn=$.props;Rn.onMouseMove&&Rn.onMouseMove(yt),Xu={x:yt.clientX,y:yt.clientY},Jn.current&&Jn.current.update()},wr={},Bt=typeof me=="string";P?(wr.title=!K&&Bt&&!F?me:null,wr["aria-describedby"]=K?se:null):(wr["aria-label"]=Bt?me:null,wr["aria-labelledby"]=K&&!Bt?se:null);const Gt=I({},wr,Be,$.props,{className:ve(Be.className,$.props.className),onTouchStart:br,ref:oo},W?{onMouseMove:ao}:{}),jn={};Y||(Gt.onTouchStart=bo,Gt.onTouchEnd=Rr),F||(Gt.onMouseOver=Xf(ro,Gt.onMouseOver),Gt.onMouseLeave=Xf(yo,Gt.onMouseLeave),Nt||(jn.onMouseOver=ro,jn.onMouseLeave=yo)),D||(Gt.onFocus=Xf(Hn,Gt.onFocus),Gt.onBlur=Xf(Ft,Gt.onBlur),Nt||(jn.onFocus=Hn,jn.onBlur=Ft));const hr=p.useMemo(()=>{var yt;let Rn=[{name:"arrow",enabled:Boolean(Rt),options:{element:Rt,padding:4}}];return(yt=xe.popperOptions)!=null&&yt.modifiers&&(Rn=Rn.concat(xe.popperOptions.modifiers)),I({},xe.popperOptions,{modifiers:Rn})},[Rt,xe]),Kr=I({},k,{isRtl:Et,arrow:_,disableInteractive:Nt,placement:ce,PopperComponentProp:Ce,touch:rt.current}),Yr=oJ(Kr),pa=(r=(o=tt.popper)!=null?o:L.Popper)!=null?r:aJ,ue=(a=(i=(l=tt.transition)!=null?l:L.Transition)!=null?i:Ge)!=null?a:kb,ae=(c=(u=tt.tooltip)!=null?u:L.Tooltip)!=null?c:iJ,Fe=(d=(f=tt.arrow)!=null?f:L.Arrow)!=null?d:sJ,ot=hd(pa,I({},xe,(h=Ee.popper)!=null?h:O.popper,{className:ve(Yr.popper,xe==null?void 0:xe.className,(m=(y=Ee.popper)!=null?y:O.popper)==null?void 0:m.className)}),Kr),kt=hd(ue,I({},qe,(g=Ee.transition)!=null?g:O.transition),Kr),Tn=hd(ae,I({},(v=Ee.tooltip)!=null?v:O.tooltip,{className:ve(Yr.tooltip,(b=(w=Ee.tooltip)!=null?w:O.tooltip)==null?void 0:b.className)}),Kr),_n=hd(Fe,I({},(x=Ee.arrow)!=null?x:O.arrow,{className:ve(Yr.arrow,(E=(A=Ee.arrow)!=null?A:O.arrow)==null?void 0:E.className)}),Kr);return T(p.Fragment,{children:[p.cloneElement($,Gt),s(pa,I({as:Ce??Qg,placement:ce,anchorEl:W?{getBoundingClientRect:()=>({top:Xu.y,left:Xu.x,right:Xu.x,bottom:Xu.y,width:0,height:0})}:Ke,popperRef:Jn,open:Ke?K:!1,id:se,transition:!0},jn,ot,{popperOptions:hr,children:({TransitionProps:yt})=>s(ue,I({timeout:he.transitions.duration.shorter},yt,kt,{children:T(ae,I({},Tn,{children:[me,_?s(Fe,I({},_n,{ref:dt})):null]}))}))}))]})}),_t=lJ;function cJ(e){return je("MuiSwitch",e)}const uJ=Ue("MuiSwitch",["root","edgeStart","edgeEnd","switchBase","colorPrimary","colorSecondary","sizeSmall","sizeMedium","checked","disabled","input","thumb","track"]),Qr=uJ,dJ=["className","color","edge","size","sx"],pJ=e=>{const{classes:t,edge:n,size:r,color:o,checked:a,disabled:i}=e,l={root:["root",n&&`edge${ie(n)}`,`size${ie(r)}`],switchBase:["switchBase",`color${ie(o)}`,a&&"checked",i&&"disabled"],thumb:["thumb"],track:["track"],input:["input"]},c=He(l,cJ,t);return I({},t,c)},fJ=C("span",{name:"MuiSwitch",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.edge&&t[`edge${ie(n.edge)}`],t[`size${ie(n.size)}`]]}})(({ownerState:e})=>I({display:"inline-flex",width:34+12*2,height:14+12*2,overflow:"hidden",padding:12,boxSizing:"border-box",position:"relative",flexShrink:0,zIndex:0,verticalAlign:"middle","@media print":{colorAdjust:"exact"}},e.edge==="start"&&{marginLeft:-8},e.edge==="end"&&{marginRight:-8},e.size==="small"&&{width:40,height:24,padding:7,[`& .${Qr.thumb}`]:{width:16,height:16},[`& .${Qr.switchBase}`]:{padding:4,[`&.${Qr.checked}`]:{transform:"translateX(16px)"}}})),hJ=C(lx,{name:"MuiSwitch",slot:"SwitchBase",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.switchBase,{[`& .${Qr.input}`]:t.input},n.color!=="default"&&t[`color${ie(n.color)}`]]}})(({theme:e})=>({position:"absolute",top:0,left:0,zIndex:1,color:e.vars?e.vars.palette.Switch.defaultColor:`${e.palette.mode==="light"?e.palette.common.white:e.palette.grey[300]}`,transition:e.transitions.create(["left","transform"],{duration:e.transitions.duration.shortest}),[`&.${Qr.checked}`]:{transform:"translateX(20px)"},[`&.${Qr.disabled}`]:{color:e.vars?e.vars.palette.Switch.defaultDisabledColor:`${e.palette.mode==="light"?e.palette.grey[100]:e.palette.grey[600]}`},[`&.${Qr.checked} + .${Qr.track}`]:{opacity:.5},[`&.${Qr.disabled} + .${Qr.track}`]:{opacity:e.vars?e.vars.opacity.switchTrackDisabled:`${e.palette.mode==="light"?.12:.2}`},[`& .${Qr.input}`]:{left:"-100%",width:"300%"}}),({theme:e,ownerState:t})=>I({"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(e.palette.action.active,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},t.color!=="default"&&{[`&.${Qr.checked}`]:{color:(e.vars||e).palette[t.color].main,"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Ot(e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${Qr.disabled}`]:{color:e.vars?e.vars.palette.Switch[`${t.color}DisabledColor`]:`${e.palette.mode==="light"?vs(e.palette[t.color].main,.62):gs(e.palette[t.color].main,.55)}`}},[`&.${Qr.checked} + .${Qr.track}`]:{backgroundColor:(e.vars||e).palette[t.color].main}})),mJ=C("span",{name:"MuiSwitch",slot:"Track",overridesResolver:(e,t)=>t.track})(({theme:e})=>({height:"100%",width:"100%",borderRadius:14/2,zIndex:-1,transition:e.transitions.create(["opacity","background-color"],{duration:e.transitions.duration.shortest}),backgroundColor:e.vars?e.vars.palette.common.onBackground:`${e.palette.mode==="light"?e.palette.common.black:e.palette.common.white}`,opacity:e.vars?e.vars.opacity.switchTrack:`${e.palette.mode==="light"?.38:.3}`})),gJ=C("span",{name:"MuiSwitch",slot:"Thumb",overridesResolver:(e,t)=>t.thumb})(({theme:e})=>({boxShadow:(e.vars||e).shadows[1],backgroundColor:"currentColor",width:20,height:20,borderRadius:"50%"})),vJ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiSwitch"}),{className:o,color:a="primary",edge:i=!1,size:l="medium",sx:c}=r,u=$e(r,dJ),d=I({},r,{color:a,edge:i,size:l}),f=pJ(d),h=s(gJ,{className:f.thumb,ownerState:d});return T(fJ,{className:ve(f.root,o),sx:c,ownerState:d,children:[s(hJ,I({type:"checkbox",icon:h,checkedIcon:h,ref:n,ownerState:d},u,{classes:I({},f,{root:f.switchBase})})),s(mJ,{className:f.track,ownerState:d})]})}),Ii=vJ;function yJ(e){return je("MuiTab",e)}const bJ=Ue("MuiTab",["root","labelIcon","textColorInherit","textColorPrimary","textColorSecondary","selected","disabled","fullWidth","wrapped","iconWrapper"]),Bs=bJ,wJ=["className","disabled","disableFocusRipple","fullWidth","icon","iconPosition","indicator","label","onChange","onClick","onFocus","selected","selectionFollowsFocus","textColor","value","wrapped"],SJ=e=>{const{classes:t,textColor:n,fullWidth:r,wrapped:o,icon:a,label:i,selected:l,disabled:c}=e,u={root:["root",a&&i&&"labelIcon",`textColor${ie(n)}`,r&&"fullWidth",o&&"wrapped",l&&"selected",c&&"disabled"],iconWrapper:["iconWrapper"]};return He(u,yJ,t)},xJ=C(Ea,{name:"MuiTab",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.label&&n.icon&&t.labelIcon,t[`textColor${ie(n.textColor)}`],n.fullWidth&&t.fullWidth,n.wrapped&&t.wrapped]}})(({theme:e,ownerState:t})=>I({},e.typography.button,{maxWidth:360,minWidth:90,position:"relative",minHeight:48,flexShrink:0,padding:"12px 16px",overflow:"hidden",whiteSpace:"normal",textAlign:"center"},t.label&&{flexDirection:t.iconPosition==="top"||t.iconPosition==="bottom"?"column":"row"},{lineHeight:1.25},t.icon&&t.label&&{minHeight:72,paddingTop:9,paddingBottom:9,[`& > .${Bs.iconWrapper}`]:I({},t.iconPosition==="top"&&{marginBottom:6},t.iconPosition==="bottom"&&{marginTop:6},t.iconPosition==="start"&&{marginRight:e.spacing(1)},t.iconPosition==="end"&&{marginLeft:e.spacing(1)})},t.textColor==="inherit"&&{color:"inherit",opacity:.6,[`&.${Bs.selected}`]:{opacity:1},[`&.${Bs.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity}},t.textColor==="primary"&&{color:(e.vars||e).palette.text.secondary,[`&.${Bs.selected}`]:{color:(e.vars||e).palette.primary.main},[`&.${Bs.disabled}`]:{color:(e.vars||e).palette.text.disabled}},t.textColor==="secondary"&&{color:(e.vars||e).palette.text.secondary,[`&.${Bs.selected}`]:{color:(e.vars||e).palette.secondary.main},[`&.${Bs.disabled}`]:{color:(e.vars||e).palette.text.disabled}},t.fullWidth&&{flexShrink:1,flexGrow:1,flexBasis:0,maxWidth:"none"},t.wrapped&&{fontSize:e.typography.pxToRem(12)})),CJ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTab"}),{className:o,disabled:a=!1,disableFocusRipple:i=!1,fullWidth:l,icon:c,iconPosition:u="top",indicator:d,label:f,onChange:h,onClick:m,onFocus:y,selected:g,selectionFollowsFocus:v,textColor:b="inherit",value:w,wrapped:x=!1}=r,E=$e(r,wJ),A=I({},r,{disabled:a,disableFocusRipple:i,selected:g,icon:!!c,iconPosition:u,label:!!f,fullWidth:l,textColor:b,wrapped:x}),k=SJ(A),_=c&&f&&p.isValidElement(c)?p.cloneElement(c,{className:ve(k.iconWrapper,c.props.className)}):c,$=O=>{!g&&h&&h(O,w),m&&m(O)},L=O=>{v&&!g&&h&&h(O,w),y&&y(O)};return T(xJ,I({focusRipple:!i,className:ve(k.root,o),ref:n,role:"tab","aria-selected":g,disabled:a,onClick:$,onFocus:L,ownerState:A,tabIndex:g?0:-1},E,{children:[u==="top"||u==="start"?T(p.Fragment,{children:[_,f]}):T(p.Fragment,{children:[f,_]}),d]}))}),EJ=CJ,TJ=p.createContext(),g4=TJ;function kJ(e){return je("MuiTable",e)}Ue("MuiTable",["root","stickyHeader"]);const AJ=["className","component","padding","size","stickyHeader"],_J=e=>{const{classes:t,stickyHeader:n}=e;return He({root:["root",n&&"stickyHeader"]},kJ,t)},RJ=C("table",{name:"MuiTable",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.stickyHeader&&t.stickyHeader]}})(({theme:e,ownerState:t})=>I({display:"table",width:"100%",borderCollapse:"collapse",borderSpacing:0,"& caption":I({},e.typography.body2,{padding:e.spacing(2),color:(e.vars||e).palette.text.secondary,textAlign:"left",captionSide:"bottom"})},t.stickyHeader&&{borderCollapse:"separate"})),Gk="table",PJ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTable"}),{className:o,component:a=Gk,padding:i="normal",size:l="medium",stickyHeader:c=!1}=r,u=$e(r,AJ),d=I({},r,{component:a,padding:i,size:l,stickyHeader:c}),f=_J(d),h=p.useMemo(()=>({padding:i,size:l,stickyHeader:c}),[i,l,c]);return s(g4.Provider,{value:h,children:s(RJ,I({as:a,role:a===Gk?null:"table",ref:n,className:ve(f.root,o),ownerState:d},u))})}),IJ=PJ,$J=p.createContext(),lv=$J;function OJ(e){return je("MuiTableBody",e)}Ue("MuiTableBody",["root"]);const LJ=["className","component"],NJ=e=>{const{classes:t}=e;return He({root:["root"]},OJ,t)},MJ=C("tbody",{name:"MuiTableBody",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"table-row-group"}),DJ={variant:"body"},qk="tbody",BJ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTableBody"}),{className:o,component:a=qk}=r,i=$e(r,LJ),l=I({},r,{component:a}),c=NJ(l);return s(lv.Provider,{value:DJ,children:s(MJ,I({className:ve(c.root,o),as:a,ref:n,role:a===qk?null:"rowgroup",ownerState:l},i))})}),$i=BJ;function FJ(e){return je("MuiTableCell",e)}const zJ=Ue("MuiTableCell",["root","head","body","footer","sizeSmall","sizeMedium","paddingCheckbox","paddingNone","alignLeft","alignCenter","alignRight","alignJustify","stickyHeader"]),jJ=zJ,UJ=["align","className","component","padding","scope","size","sortDirection","variant"],WJ=e=>{const{classes:t,variant:n,align:r,padding:o,size:a,stickyHeader:i}=e,l={root:["root",n,i&&"stickyHeader",r!=="inherit"&&`align${ie(r)}`,o!=="normal"&&`padding${ie(o)}`,`size${ie(a)}`]};return He(l,FJ,t)},HJ=C("td",{name:"MuiTableCell",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],t[`size${ie(n.size)}`],n.padding!=="normal"&&t[`padding${ie(n.padding)}`],n.align!=="inherit"&&t[`align${ie(n.align)}`],n.stickyHeader&&t.stickyHeader]}})(({theme:e,ownerState:t})=>I({},e.typography.body2,{display:"table-cell",verticalAlign:"inherit",borderBottom:e.vars?`1px solid ${e.vars.palette.TableCell.border}`:`1px solid
|
|
245
|
+
${e.palette.mode==="light"?vs(Ot(e.palette.divider,1),.88):gs(Ot(e.palette.divider,1),.68)}`,textAlign:"left",padding:16},t.variant==="head"&&{color:(e.vars||e).palette.text.primary,lineHeight:e.typography.pxToRem(24),fontWeight:e.typography.fontWeightMedium},t.variant==="body"&&{color:(e.vars||e).palette.text.primary},t.variant==="footer"&&{color:(e.vars||e).palette.text.secondary,lineHeight:e.typography.pxToRem(21),fontSize:e.typography.pxToRem(12)},t.size==="small"&&{padding:"6px 16px",[`&.${jJ.paddingCheckbox}`]:{width:24,padding:"0 12px 0 16px","& > *":{padding:0}}},t.padding==="checkbox"&&{width:48,padding:"0 0 0 4px"},t.padding==="none"&&{padding:0},t.align==="left"&&{textAlign:"left"},t.align==="center"&&{textAlign:"center"},t.align==="right"&&{textAlign:"right",flexDirection:"row-reverse"},t.align==="justify"&&{textAlign:"justify"},t.stickyHeader&&{position:"sticky",top:0,zIndex:2,backgroundColor:(e.vars||e).palette.background.default})),VJ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTableCell"}),{align:o="inherit",className:a,component:i,padding:l,scope:c,size:u,sortDirection:d,variant:f}=r,h=$e(r,UJ),m=p.useContext(g4),y=p.useContext(lv),g=y&&y.variant==="head";let v;i?v=i:v=g?"th":"td";let b=c;v==="td"?b=void 0:!b&&g&&(b="col");const w=f||y&&y.variant,x=I({},r,{align:o,component:v,padding:l||(m&&m.padding?m.padding:"normal"),size:u||(m&&m.size?m.size:"medium"),sortDirection:d,stickyHeader:w==="head"&&m&&m.stickyHeader,variant:w}),E=WJ(x);let A=null;return d&&(A=d==="asc"?"ascending":"descending"),s(HJ,I({as:v,ref:n,className:ve(E.root,a),"aria-sort":A,scope:b,ownerState:x},h))}),v4=VJ;function GJ(e){return je("MuiTableHead",e)}Ue("MuiTableHead",["root"]);const qJ=["className","component"],KJ=e=>{const{classes:t}=e;return He({root:["root"]},GJ,t)},YJ=C("thead",{name:"MuiTableHead",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"table-header-group"}),XJ={variant:"head"},Kk="thead",JJ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTableHead"}),{className:o,component:a=Kk}=r,i=$e(r,qJ),l=I({},r,{component:a}),c=KJ(l);return s(lv.Provider,{value:XJ,children:s(YJ,I({as:a,className:ve(c.root,o),ref:n,role:a===Kk?null:"rowgroup",ownerState:l},i))})}),QJ=JJ,ZJ=Ye(s("path",{d:"M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"}),"KeyboardArrowLeft"),eQ=Ye(s("path",{d:"M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"}),"KeyboardArrowRight");function tQ(e){return je("MuiTableRow",e)}const nQ=Ue("MuiTableRow",["root","selected","hover","head","footer"]),Yk=nQ,rQ=["className","component","hover","selected"],oQ=e=>{const{classes:t,selected:n,hover:r,head:o,footer:a}=e;return He({root:["root",n&&"selected",r&&"hover",o&&"head",a&&"footer"]},tQ,t)},aQ=C("tr",{name:"MuiTableRow",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.head&&t.head,n.footer&&t.footer]}})(({theme:e})=>({color:"inherit",display:"table-row",verticalAlign:"middle",outline:0,[`&.${Yk.hover}:hover`]:{backgroundColor:(e.vars||e).palette.action.hover},[`&.${Yk.selected}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity),"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:Ot(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity)}}})),Xk="tr",iQ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTableRow"}),{className:o,component:a=Xk,hover:i=!1,selected:l=!1}=r,c=$e(r,rQ),u=p.useContext(lv),d=I({},r,{component:a,hover:i,selected:l,head:u&&u.variant==="head",footer:u&&u.variant==="footer"}),f=oQ(d);return s(aQ,I({as:a,ref:n,className:ve(f.root,o),role:a===Xk?null:"row",ownerState:d},c))}),ai=iQ;function sQ(e){return(1+Math.sin(Math.PI*e-Math.PI/2))/2}function lQ(e,t,n,r={},o=()=>{}){const{ease:a=sQ,duration:i=300}=r;let l=null;const c=t[e];let u=!1;const d=()=>{u=!0},f=h=>{if(u){o(new Error("Animation cancelled"));return}l===null&&(l=h);const m=Math.min(1,(h-l)/i);if(t[e]=a(m)*(n-c)+c,m>=1){requestAnimationFrame(()=>{o(null)});return}requestAnimationFrame(f)};return c===n?(o(new Error("Element already at target position")),d):(requestAnimationFrame(f),d)}const cQ=["onChange"],uQ={width:99,height:99,position:"absolute",top:-9999,overflow:"scroll"};function dQ(e){const{onChange:t}=e,n=$e(e,cQ),r=p.useRef(),o=p.useRef(null),a=()=>{r.current=o.current.offsetHeight-o.current.clientHeight};return p.useEffect(()=>{const i=ml(()=>{const c=r.current;a(),c!==r.current&&t(r.current)}),l=ta(o.current);return l.addEventListener("resize",i),()=>{i.clear(),l.removeEventListener("resize",i)}},[t]),p.useEffect(()=>{a(),t(r.current)},[t]),s("div",I({style:uQ,ref:o},n))}function pQ(e){return je("MuiTabScrollButton",e)}const fQ=Ue("MuiTabScrollButton",["root","vertical","horizontal","disabled"]),hQ=fQ;var Jk,Qk;const mQ=["className","direction","orientation","disabled"],gQ=e=>{const{classes:t,orientation:n,disabled:r}=e;return He({root:["root",n,r&&"disabled"]},pQ,t)},vQ=C(Ea,{name:"MuiTabScrollButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.orientation&&t[n.orientation]]}})(({ownerState:e})=>I({width:40,flexShrink:0,opacity:.8,[`&.${hQ.disabled}`]:{opacity:0}},e.orientation==="vertical"&&{width:"100%",height:40,"& svg":{transform:`rotate(${e.isRtl?-90:90}deg)`}})),yQ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTabScrollButton"}),{className:o,direction:a}=r,i=$e(r,mQ),c=on().direction==="rtl",u=I({isRtl:c},r),d=gQ(u);return s(vQ,I({component:"div",className:ve(d.root,o),ref:n,role:null,ownerState:u,tabIndex:null},i,{children:a==="left"?Jk||(Jk=s(ZJ,{fontSize:"small"})):Qk||(Qk=s(eQ,{fontSize:"small"}))}))}),bQ=yQ;function wQ(e){return je("MuiTabs",e)}const SQ=Ue("MuiTabs",["root","vertical","flexContainer","flexContainerVertical","centered","scroller","fixed","scrollableX","scrollableY","hideScrollbar","scrollButtons","scrollButtonsHideMobile","indicator"]),v1=SQ,xQ=["aria-label","aria-labelledby","action","centered","children","className","component","allowScrollButtonsMobile","indicatorColor","onChange","orientation","ScrollButtonComponent","scrollButtons","selectionFollowsFocus","TabIndicatorProps","TabScrollButtonProps","textColor","value","variant","visibleScrollbar"],Zk=(e,t)=>e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:e.firstChild,eA=(e,t)=>e===t?e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:e.lastChild,Jf=(e,t,n)=>{let r=!1,o=n(e,t);for(;o;){if(o===e.firstChild){if(r)return;r=!0}const a=o.disabled||o.getAttribute("aria-disabled")==="true";if(!o.hasAttribute("tabindex")||a)o=n(e,o);else{o.focus();return}}},CQ=e=>{const{vertical:t,fixed:n,hideScrollbar:r,scrollableX:o,scrollableY:a,centered:i,scrollButtonsHideMobile:l,classes:c}=e;return He({root:["root",t&&"vertical"],scroller:["scroller",n&&"fixed",r&&"hideScrollbar",o&&"scrollableX",a&&"scrollableY"],flexContainer:["flexContainer",t&&"flexContainerVertical",i&&"centered"],indicator:["indicator"],scrollButtons:["scrollButtons",l&&"scrollButtonsHideMobile"],scrollableX:[o&&"scrollableX"],hideScrollbar:[r&&"hideScrollbar"]},wQ,c)},EQ=C("div",{name:"MuiTabs",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`& .${v1.scrollButtons}`]:t.scrollButtons},{[`& .${v1.scrollButtons}`]:n.scrollButtonsHideMobile&&t.scrollButtonsHideMobile},t.root,n.vertical&&t.vertical]}})(({ownerState:e,theme:t})=>I({overflow:"hidden",minHeight:48,WebkitOverflowScrolling:"touch",display:"flex"},e.vertical&&{flexDirection:"column"},e.scrollButtonsHideMobile&&{[`& .${v1.scrollButtons}`]:{[t.breakpoints.down("sm")]:{display:"none"}}})),TQ=C("div",{name:"MuiTabs",slot:"Scroller",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.scroller,n.fixed&&t.fixed,n.hideScrollbar&&t.hideScrollbar,n.scrollableX&&t.scrollableX,n.scrollableY&&t.scrollableY]}})(({ownerState:e})=>I({position:"relative",display:"inline-block",flex:"1 1 auto",whiteSpace:"nowrap"},e.fixed&&{overflowX:"hidden",width:"100%"},e.hideScrollbar&&{scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}},e.scrollableX&&{overflowX:"auto",overflowY:"hidden"},e.scrollableY&&{overflowY:"auto",overflowX:"hidden"})),kQ=C("div",{name:"MuiTabs",slot:"FlexContainer",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.flexContainer,n.vertical&&t.flexContainerVertical,n.centered&&t.centered]}})(({ownerState:e})=>I({display:"flex"},e.vertical&&{flexDirection:"column"},e.centered&&{justifyContent:"center"})),AQ=C("span",{name:"MuiTabs",slot:"Indicator",overridesResolver:(e,t)=>t.indicator})(({ownerState:e,theme:t})=>I({position:"absolute",height:2,bottom:0,width:"100%",transition:t.transitions.create()},e.indicatorColor==="primary"&&{backgroundColor:(t.vars||t).palette.primary.main},e.indicatorColor==="secondary"&&{backgroundColor:(t.vars||t).palette.secondary.main},e.vertical&&{height:"100%",width:2,right:0})),_Q=C(dQ,{name:"MuiTabs",slot:"ScrollbarSize"})({overflowX:"auto",overflowY:"hidden",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}),tA={},RQ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTabs"}),o=on(),a=o.direction==="rtl",{"aria-label":i,"aria-labelledby":l,action:c,centered:u=!1,children:d,className:f,component:h="div",allowScrollButtonsMobile:m=!1,indicatorColor:y="primary",onChange:g,orientation:v="horizontal",ScrollButtonComponent:b=bQ,scrollButtons:w="auto",selectionFollowsFocus:x,TabIndicatorProps:E={},TabScrollButtonProps:A={},textColor:k="primary",value:_,variant:$="standard",visibleScrollbar:L=!1}=r,O=$e(r,xQ),P=$==="scrollable",D=v==="vertical",F=D?"scrollTop":"scrollLeft",U=D?"top":"left",Y=D?"bottom":"right",V=D?"clientHeight":"clientWidth",te=D?"height":"width",Z=I({},r,{component:h,allowScrollButtonsMobile:m,indicatorColor:y,orientation:v,vertical:D,scrollButtons:w,textColor:k,variant:$,visibleScrollbar:L,fixed:!P,hideScrollbar:P&&!L,scrollableX:P&&!D,scrollableY:P&&D,centered:u&&!P,scrollButtonsHideMobile:!m}),W=CQ(Z),[z,R]=p.useState(!1),[M,ee]=p.useState(tA),[re,Se]=p.useState({start:!1,end:!1}),[ce,Ce]=p.useState({overflow:"hidden",scrollbarWidth:0}),xe=new Map,Ee=p.useRef(null),tt=p.useRef(null),me=()=>{const q=Ee.current;let K;if(q){const be=q.getBoundingClientRect();K={clientWidth:q.clientWidth,scrollLeft:q.scrollLeft,scrollTop:q.scrollTop,scrollLeftNormalized:mT(q,o.direction),scrollWidth:q.scrollWidth,top:be.top,bottom:be.bottom,left:be.left,right:be.right}}let se;if(q&&_!==!1){const be=tt.current.children;if(be.length>0){const Ae=be[xe.get(_)];se=Ae?Ae.getBoundingClientRect():null}}return{tabsMeta:K,tabMeta:se}},Ge=gr(()=>{const{tabsMeta:q,tabMeta:K}=me();let se=0,be;if(D)be="top",K&&q&&(se=K.top-q.top+q.scrollTop);else if(be=a?"right":"left",K&&q){const mt=a?q.scrollLeftNormalized+q.clientWidth-q.scrollWidth:q.scrollLeft;se=(a?-1:1)*(K[be]-q[be]+mt)}const Ae={[be]:se,[te]:K?K[te]:0};if(isNaN(M[be])||isNaN(M[te]))ee(Ae);else{const mt=Math.abs(M[be]-Ae[be]),et=Math.abs(M[te]-Ae[te]);(mt>=1||et>=1)&&ee(Ae)}}),qe=(q,{animation:K=!0}={})=>{K?lQ(F,Ee.current,q,{duration:o.transitions.duration.standard}):Ee.current[F]=q},Be=q=>{let K=Ee.current[F];D?K+=q:(K+=q*(a?-1:1),K*=a&&K5()==="reverse"?-1:1),qe(K)},he=()=>{const q=Ee.current[V];let K=0;const se=Array.from(tt.current.children);for(let be=0;be<se.length;be+=1){const Ae=se[be];if(K+Ae[V]>q){be===0&&(K=q);break}K+=Ae[V]}return K},Et=()=>{Be(-1*he())},Ke=()=>{Be(he())},ct=p.useCallback(q=>{Ce({overflow:null,scrollbarWidth:q})},[]),Rt=()=>{const q={};q.scrollbarSizeListener=P?s(_Q,{onChange:ct,className:ve(W.scrollableX,W.hideScrollbar)}):null;const K=re.start||re.end,se=P&&(w==="auto"&&K||w===!0);return q.scrollButtonStart=se?s(b,I({orientation:v,direction:a?"right":"left",onClick:Et,disabled:!re.start},A,{className:ve(W.scrollButtons,A.className)})):null,q.scrollButtonEnd=se?s(b,I({orientation:v,direction:a?"left":"right",onClick:Ke,disabled:!re.end},A,{className:ve(W.scrollButtons,A.className)})):null,q},dt=gr(q=>{const{tabsMeta:K,tabMeta:se}=me();if(!(!se||!K)){if(se[U]<K[U]){const be=K[F]+(se[U]-K[U]);qe(be,{animation:q})}else if(se[Y]>K[Y]){const be=K[F]+(se[Y]-K[Y]);qe(be,{animation:q})}}}),rt=gr(()=>{if(P&&w!==!1){const{scrollTop:q,scrollHeight:K,clientHeight:se,scrollWidth:be,clientWidth:Ae}=Ee.current;let mt,et;if(D)mt=q>1,et=q<K-se-1;else{const ht=mT(Ee.current,o.direction);mt=a?ht<be-Ae-1:ht>1,et=a?ht>1:ht<be-Ae-1}(mt!==re.start||et!==re.end)&&Se({start:mt,end:et})}});p.useEffect(()=>{const q=ml(()=>{Ee.current&&(Ge(),rt())}),K=ta(Ee.current);K.addEventListener("resize",q);let se;return typeof ResizeObserver<"u"&&(se=new ResizeObserver(q),Array.from(tt.current.children).forEach(be=>{se.observe(be)})),()=>{q.clear(),K.removeEventListener("resize",q),se&&se.disconnect()}},[Ge,rt]);const Nt=p.useMemo(()=>ml(()=>{rt()}),[rt]);p.useEffect(()=>()=>{Nt.clear()},[Nt]),p.useEffect(()=>{R(!0)},[]),p.useEffect(()=>{Ge(),rt()}),p.useEffect(()=>{dt(tA!==M)},[dt,M]),p.useImperativeHandle(c,()=>({updateIndicator:Ge,updateScrollButtons:rt}),[Ge,rt]);const xt=s(AQ,I({},E,{className:ve(W.indicator,E.className),ownerState:Z,style:I({},M,E.style)}));let pe=0;const Te=p.Children.map(d,q=>{if(!p.isValidElement(q))return null;const K=q.props.value===void 0?pe:q.props.value;xe.set(K,pe);const se=K===_;return pe+=1,p.cloneElement(q,I({fullWidth:$==="fullWidth",indicator:se&&!z&&xt,selected:se,selectionFollowsFocus:x,onChange:g,textColor:k,value:K},pe===1&&_===!1&&!q.props.tabIndex?{tabIndex:0}:{}))}),Xe=q=>{const K=tt.current,se=Fn(K).activeElement;if(se.getAttribute("role")!=="tab")return;let Ae=v==="horizontal"?"ArrowLeft":"ArrowUp",mt=v==="horizontal"?"ArrowRight":"ArrowDown";switch(v==="horizontal"&&a&&(Ae="ArrowRight",mt="ArrowLeft"),q.key){case Ae:q.preventDefault(),Jf(K,se,eA);break;case mt:q.preventDefault(),Jf(K,se,Zk);break;case"Home":q.preventDefault(),Jf(K,null,Zk);break;case"End":q.preventDefault(),Jf(K,null,eA);break}},De=Rt();return T(EQ,I({className:ve(W.root,f),ownerState:Z,ref:n,as:h},O,{children:[De.scrollButtonStart,De.scrollbarSizeListener,T(TQ,{className:W.scroller,ownerState:Z,style:{overflow:ce.overflow,[D?`margin${a?"Left":"Right"}`:"marginBottom"]:L?void 0:-ce.scrollbarWidth},ref:Ee,onScroll:Nt,children:[s(kQ,{"aria-label":i,"aria-labelledby":l,"aria-orientation":v==="vertical"?"vertical":null,className:W.flexContainer,ownerState:Z,onKeyDown:Xe,ref:tt,role:"tablist",children:Te}),z&&xt]}),De.scrollButtonEnd]}))}),PQ=RQ;function IQ(e){return je("MuiTextField",e)}Ue("MuiTextField",["root"]);const $Q=["autoComplete","autoFocus","children","className","color","defaultValue","disabled","error","FormHelperTextProps","fullWidth","helperText","id","InputLabelProps","inputProps","InputProps","inputRef","label","maxRows","minRows","multiline","name","onBlur","onChange","onFocus","placeholder","required","rows","select","SelectProps","type","value","variant"],OQ={standard:r4,filled:J$,outlined:p4},LQ=e=>{const{classes:t}=e;return He({root:["root"]},IQ,t)},NQ=C(Pi,{name:"MuiTextField",slot:"Root",overridesResolver:(e,t)=>t.root})({}),MQ=p.forwardRef(function(t,n){const r=Ve({props:t,name:"MuiTextField"}),{autoComplete:o,autoFocus:a=!1,children:i,className:l,color:c="primary",defaultValue:u,disabled:d=!1,error:f=!1,FormHelperTextProps:h,fullWidth:m=!1,helperText:y,id:g,InputLabelProps:v,inputProps:b,InputProps:w,inputRef:x,label:E,maxRows:A,minRows:k,multiline:_=!1,name:$,onBlur:L,onChange:O,onFocus:P,placeholder:D,required:F=!1,rows:U,select:Y=!1,SelectProps:V,type:te,value:Z,variant:W="outlined"}=r,z=$e(r,$Q),R=I({},r,{autoFocus:a,color:c,disabled:d,error:f,fullWidth:m,multiline:_,required:F,select:Y,variant:W}),M=LQ(R),ee={};W==="outlined"&&(v&&typeof v.shrink<"u"&&(ee.notched=v.shrink),ee.label=E),Y&&((!V||!V.native)&&(ee.id=void 0),ee["aria-describedby"]=void 0);const re=nu(g),Se=y&&re?`${re}-helper-text`:void 0,ce=E&&re?`${re}-label`:void 0,Ce=OQ[W],xe=s(Ce,I({"aria-describedby":Se,autoComplete:o,autoFocus:a,defaultValue:u,fullWidth:m,multiline:_,name:$,rows:U,maxRows:A,minRows:k,type:te,value:Z,id:re,inputRef:x,onBlur:L,onChange:O,onFocus:P,placeholder:D,inputProps:b},ee,w));return T(NQ,I({className:ve(M.root,l),disabled:d,error:f,fullWidth:m,ref:n,required:F,color:c,variant:W,ownerState:R},z,{children:[E!=null&&E!==""&&s(Yp,I({htmlFor:re,id:ce},v,{children:E})),Y?s(Xp,I({"aria-describedby":Se,id:re,labelId:ce,value:Z,input:xe},V,{children:i})):xe,y&&s(mq,I({id:Se},h,{children:y}))]}))}),mn=MQ,y4=()=>({type:"success",title:"",text:"",components:[],show:!1,persist:!1}),DQ=()=>{throw new Error("setToast called outside UIContext")},BQ=()=>{throw new Error("setShowFeedback called outside UIContext")},FQ=()=>{throw new Error("setMode called outside UIContext")},Ps=jt.createContext({toastData:y4(),setToast:DQ,showFeedback:!1,setShowFeedback:BQ,themeMode:"light",setThemeMode:FQ});function gp(e){try{return zQ(window.localStorage.getItem(e))}catch(t){console.warn(t)}}function zc(e,t){try{window.localStorage.setItem(e,JSON.stringify(t,(n,r)=>r instanceof Set?[...r]:r))}catch(n){console.warn(n)}}function zQ(e){try{return e?JSON.parse(e):void 0}catch(t){console.warn(t)}}const ne={white:"#FFFFFF",black:"#000000",grey:{900:"#202021",800:"#6E6E70",700:"#78787A",600:"#9F9FA1",500:"#BDBDBF",400:"#E1E1E3",300:"#EAEAED",200:"#F2F2F5",100:"#F7F7FA",50:"#FFFFFF"},purple:{900:"#615BC2",800:"#6C65E5",700:"#817AFE",600:"#8C87EB",500:"#9D98EE",400:"#ADA9F1",300:"#BEBBF3",200:"#CECCF6",100:"#E4E3F9",50:"#F1F0FC"},red:{900:"#A6000E",800:"#D11525",700:"#D93644",600:"#E04C59",500:"#E04C59",400:"#F0616D",300:"#FEB0B7",200:"#FFD4D8",100:"#FFE5E7",50:"#FFF2F3"},orange:{900:"#B35300",800:"#D76500",700:"#F28D00",600:"#FFAA33",500:"#FFC46F",400:"#FFCF8B",300:"#FFD9A3",200:"#FFEACC",100:"#FFF4E5",50:"#FFFCF5"},green:{900:"#305200",800:"#3B6600",700:"#4D8400",600:"#68A611",500:"#7FB435",400:"#99C35D",300:"#B0D182",200:"#CFE5AE",100:"#E4F0D3",50:"#F4FAEB"},blue:{900:"#163E59",800:"#0060A1",700:"#0071BD",600:"#007ACA",500:"#0087E0",400:"#1C98EB",300:"#5BB4F0",200:"#96D2FA",100:"#DCEEFA",50:"#EBF7FF"},darkblue:{1e3:"#091826",900:"#041c32",800:"#1d3247",700:"#28415c",600:"#1f3751",500:"#0e2840"}},ws=qg({breakpoints:{values:{xs:0,sm:600,md:960,lg:1260,xl:1536}},boxShadows:{main:"0px 2px 4px rgba(129, 122, 254, 0.2)",card:"0px 2px 10px rgba(28, 25, 78, 0.12)",elevated:"0px 1px 20px rgba(45, 42, 89, 0.1)",popup:"0px 2px 6px rgba(0, 0, 0, 0.25)",primaryHeader:"0px 8px 24px rgba(97, 91, 194, 0.2)"},typography:{fontFamily:"Sen, Roboto, sans-serif",fontWeightBold:"700",fontWeightMedium:"700",allVariants:{lineHeight:1.4},button:{lineHeight:1.75},h1:{fontSize:"1.5rem",lineHeight:1.875},h2:{fontSize:`${20/16}rem`,fontWeight:"700"},h3:{fontSize:"1rem",fontWeight:"700"},caption:{fontSize:`${12/16}rem`}},fontSizes:{largeHeader:"2rem",mainHeader:"1.25rem",bodySize:"1rem",smallBody:`${14/16}rem`,smallerBody:`${12/16}rem`},fontWeight:{thin:300,medium:400,semi:700,bold:700},shape:{borderRadius:4,borderRadiusMedium:8,borderRadiusLarge:12,borderRadiusExtraLarge:20,tableRowHeight:64,tableRowHeightCompact:56,tableRowHeightDense:48},palette:{primary:{main:ne.purple[800],light:ne.purple[700],dark:ne.purple[900]},secondary:{light:ne.purple[50],main:ne.purple[800],dark:ne.purple[900],border:ne.purple[300]},info:{light:ne.blue[50],main:ne.blue[500],dark:ne.blue[700],border:ne.blue[200]},success:{light:ne.green[50],main:ne.green[600],dark:ne.green[800],border:ne.green[300]},warning:{light:ne.orange[100],main:ne.orange[800],dark:ne.orange[900],border:ne.orange[500]},error:{light:ne.red[50],main:ne.red[700],dark:ne.red[800],border:ne.red[300]},neutral:{light:ne.grey[100],main:ne.grey[700],dark:ne.grey[800],border:ne.grey[500]},tertiary:{light:ne.grey[200],main:ne.grey[400],dark:ne.grey[600],background:"white",contrast:ne.grey[300]},divider:ne.grey[300],dividerAlternative:ne.grey[400],tableHeaderHover:ne.grey[400],tableHeaderBackground:ne.grey[200],tableHeaderColor:ne.grey[900],formSidebarTextColor:ne.white,highlight:"#FFEACC",secondaryContainer:ne.grey[200],contentWrapper:ne.grey[300],headerBackground:ne.white,footerBackground:ne.white,formBackground:ne.white,formSidebar:ne.purple[800],featureMetaData:ne.purple[800],codebox:"rgba(32,32,33, 0.2)",sidebarContainer:"rgba(32,32,33, 0.2)",playgroundBackground:ne.grey[200],playgroundFormBackground:ne.grey[200],standaloneBackground:ne.grey[300],constraintAccordion:{editBackground:"#F6F6FA",background:ne.white,operatorBackground:ne.grey[200]},projectCard:{hover:ne.grey[100],textColor:"#4A4599"},standaloneBannerGradient:{from:ne.purple[900],to:"#173341"},checkmarkBadge:ne.purple[800],inputLabelBackground:ne.white,featureStrategySegmentChipBackground:ne.purple[800],featureSegmentSearchBackground:ne.purple[800],dialogHeaderBackground:ne.purple[800],dialogHeaderText:"#ffffffe6",grey:ne.grey,lightBorder:ne.grey[400],text:{primary:ne.grey[900],secondary:ne.grey[800],disabled:ne.grey[600],tertiaryContrast:"#fff"},code:{main:"#0b8c8f",diffAdd:"#3b6600",diffSub:"#d11525",diffNeutral:"black",edited:"black"},activityIndicators:{unknown:ne.grey[100],recent:ne.green[100],inactive:ne.orange[200],abandoned:ne.red[200],primary:ne.purple[100]},inactiveIcon:ne.grey[600]},components:{MuiLink:{styleOverrides:{root:{color:ne.purple[900],"&:hover":{textDecoration:"none"}}}},MuiBreadcrumbs:{styleOverrides:{root:{color:ne.grey[900],fontSize:"0.875rem","& a":{color:ne.purple[900],textDecoration:"none","&:hover":{textDecoration:"underline"}}}}},MuiTableHead:{styleOverrides:{root:{background:"transparent","& th":{background:ne.grey[200]}}}},MuiTableRow:{styleOverrides:{root:{"&.MuiTableRow-hover:hover":{background:ne.grey[100]}}}},MuiTableCell:{styleOverrides:{root:{borderBottomColor:ne.grey[300]}}},MuiAlert:{styleOverrides:{root:{borderRadius:"8px",a:{color:"inherit"},"&.MuiAlert-standardInfo":{backgroundColor:ne.blue[50],color:ne.blue[700],border:`1px solid ${ne.blue[200]}`,"& .MuiAlert-icon":{color:ne.blue[500]}},"&.MuiAlert-standardSuccess":{backgroundColor:ne.green[50],color:ne.green[800],border:`1px solid ${ne.green[300]}`,"& .MuiAlert-icon":{color:ne.green[500]}},"&.MuiAlert-standardWarning":{backgroundColor:ne.orange[100],color:ne.orange[900],border:`1px solid ${ne.orange[500]}`,"& .MuiAlert-icon":{color:ne.orange[800]}},"&.MuiAlert-standardError":{backgroundColor:ne.red[50],color:ne.red[800],border:`1px solid ${ne.red[300]}`,"& .MuiAlert-icon":{color:ne.red[700]}}}}},MuiTabs:{styleOverrides:{root:({theme:e})=>({"& .MuiTabs-indicator":{height:"4px"},"& .MuiTabs-flexContainer":{minHeight:"70px",maxHeight:"70px"}})}},MuiTab:{styleOverrides:{root:({theme:e})=>({color:ne.grey[900],fontSize:"1rem",textTransform:"none",fontWeight:400,lineHeight:"1",minHeight:"62px","&:hover":{backgroundColor:ne.grey[200]},"&.Mui-selected":{color:ne.grey[900],fontWeight:700},"& > span":{color:ne.purple[900]},[e.breakpoints.down("md")]:{padding:"12px 0px"}})}},MuiAccordion:{styleOverrides:{root:({theme:e})=>({"&:first-of-type, &:last-of-type":{borderRadius:e.shape.borderRadiusMedium}})}},MuiAccordionSummary:{styleOverrides:{root:{"& > .MuiAccordionSummary-content.Mui-expanded":{margin:"12px 0"},"&.Mui-expanded":{minHeight:"0"}}}},MuiSwitch:{styleOverrides:{switchBase:{zIndex:1,"&:not(.Mui-checked) .MuiTouchRipple-child":{color:ne.grey[500]}}}},MuiIcon:{styleOverrides:{colorDisabled:{color:ne.grey[600]}}},MuiMenuItem:{styleOverrides:{root:{"&.Mui-disabled":{opacity:.66}}}},MuiChip:{styleOverrides:{root:({ownerState:e,theme:t})=>({...e.variant==="outlined"&&e.size==="small"&&{borderRadius:t.shape.borderRadius,margin:0,borderWidth:1,borderStyle:"solid",fontWeight:t.typography.fontWeightBold,fontSize:t.typography.caption.fontSize,...e.color==="success"&&{backgroundColor:ne.green[50],borderColor:t.palette.success.border,color:t.palette.success.dark},...e.color==="default"&&{color:t.palette.text.secondary},...e.color==="error"&&{color:t.palette.error.dark,background:t.palette.error.light,borderColor:t.palette.error.border}}})}},MuiInputBase:{styleOverrides:{root:{backgroundColor:"#fff"}}},MuiPaper:{styleOverrides:{root:{backgroundColor:"#fff"}}},MuiAppBar:{styleOverrides:{root:{color:ne.black}}}}}),Pt={main:ne.darkblue[900],secondary:ne.darkblue[800],textColor:"#ffffffe6",hover:"rgb(255, 255, 255, 0.7)"},jQ=qg({breakpoints:{values:{xs:0,sm:600,md:960,lg:1260,xl:1536}},boxShadows:{main:"0px 2px 4px rgba(129, 122, 254, 0.2)",card:"0px 2px 10px rgba(28, 25, 78, 0.12)",elevated:"0px 1px 20px rgba(45, 42, 89, 0.1)",popup:"0px 2px 6px rgba(0, 0, 0, 0.25)",primaryHeader:"0px 8px 24px rgba(97, 91, 194, 0.2)"},typography:{fontFamily:"Sen, Roboto, sans-serif",fontWeightBold:"700",fontWeightMedium:"700",allVariants:{lineHeight:1.4},button:{lineHeight:1.75},h1:{fontSize:"1.5rem",lineHeight:1.875},h3:{fontSize:"1rem",fontWeight:"700"},caption:{fontSize:`${12/16}rem`}},fontSizes:{largeHeader:"2.25rem",mainHeader:"1.25rem",bodySize:"1rem",smallBody:`${14/16}rem`,smallerBody:`${12/16}rem`},fontWeight:{thin:300,medium:400,semi:700,bold:700},shape:{borderRadius:4,borderRadiusMedium:8,borderRadiusLarge:12,borderRadiusExtraLarge:20,tableRowHeight:64,tableRowHeightCompact:56,tableRowHeightDense:48},palette:{primary:{main:Pt.textColor,light:ne.purple[700],dark:ne.purple[900]},secondary:{main:ne.purple[800],light:ne.purple[700],dark:ne.purple[900]},info:{light:ne.blue[50],main:ne.blue[500],dark:ne.blue[700],border:ne.blue[200]},success:{light:ne.green[50],main:ne.green[600],dark:Pt.main,border:ne.green[300]},warning:{light:ne.orange[100],main:ne.orange[800],dark:ne.orange[900],border:ne.orange[500]},error:{light:ne.red[50],main:ne.red[700],dark:ne.red[800],border:ne.red[300]},background:{paper:Pt.main},divider:Pt.secondary,dividerAlternative:ne.grey[400],tableHeaderHover:ne.darkblue[700],tableHeaderBackground:Pt.secondary,tableHeaderColor:Pt.textColor,highlight:"#FFEACC",secondaryContainer:Pt.secondary,contentWrapper:ne.darkblue[800],formBackground:Pt.main,formSidebar:ne.darkblue[1e3],headerBackground:Pt.main,footerBackground:Pt.main,sidebarContainer:"rgba(32,32,33, 0.2)",codebox:ne.darkblue[600],featureMetaData:ne.darkblue[1e3],playgroundBackground:ne.darkblue[600],playgroundFormBackground:Pt.secondary,standaloneBackground:ne.black,featureStrategySegmentChipBackground:Pt.secondary,featureSegmentSearchBackground:Pt.secondary,dialogHeaderBackground:Pt.secondary,dialogHeaderText:Pt.textColor,lightBorder:ne.darkblue[500],constraintAccordion:{editBackground:ne.darkblue[600],background:Pt.secondary,operatorBackground:Pt.main},standaloneBannerGradient:{from:ne.darkblue[1e3],to:ne.black},projectCard:{hover:Pt.secondary,textColor:Pt.textColor},formSidebarTextColor:Pt.textColor,checkmarkBadge:Pt.secondary,inputLabelBackground:"transparent",grey:ne.grey,text:{primary:Pt.textColor,secondary:ne.grey[800],disabled:ne.grey[600]},code:{main:"#0b8c8f",diffAdd:"green",diffSub:"red",diffNeutral:"black",edited:"blue"},neutral:{light:ne.darkblue[500],main:ne.grey[700],dark:ne.grey[800],border:ne.grey[500]},activityIndicators:{primary:Pt.secondary,unknown:Pt.secondary,recent:Pt.secondary,inactive:Pt.secondary,abandoned:Pt.secondary},tertiary:{light:Pt.secondary,main:ne.grey[400],dark:ne.grey[600],background:"white",contrast:ne.grey[300]},inactiveIcon:ne.grey[600]},components:{MuiAppBar:{styleOverrides:{root:{color:Pt.textColor}}},MuiInputLabel:{styleOverrides:{root:{color:Pt.textColor}}},MuiIconButton:{styleOverrides:{root:{color:ne.white,"&:hover":{backgroundColor:Pt.hover},"&.Mui-disabled":{"& .MuiSvgIcon-root":{color:ne.grey[700]}}}}},MuiLink:{styleOverrides:{root:{color:ne.white,"&:hover":{textDecoration:"none"}}}},MuiBreadcrumbs:{styleOverrides:{root:{color:Pt.textColor,fontSize:"0.875rem","& a":{color:Pt.textColor,textDecoration:"underline","&:hover":{textDecoration:"none"}}}}},MuiTableHead:{styleOverrides:{root:{background:"transparent","& th":{background:ne.grey[200]}}}},MuiTableRow:{styleOverrides:{root:{"&.MuiTableRow-hover:hover":{background:Pt.secondary}}}},MuiTableCell:{styleOverrides:{root:{borderBottomColor:Pt.main}}},MuiAlert:{styleOverrides:{root:{borderRadius:"8px",a:{color:"inherit"},"&.MuiAlert-standardInfo":{backgroundColor:ne.blue[50],color:ne.blue[700],border:`1px solid ${ne.blue[200]}`,"& .MuiAlert-icon .MuiSvgIcon-root":{color:ne.blue[500]}},"&.MuiAlert-standardSuccess":{backgroundColor:ne.green[50],color:ne.green[800],border:`1px solid ${ne.green[300]}`,"& .MuiAlert-icon .MuiSvgIcon-root":{color:ne.green[500]}},"&.MuiAlert-standardWarning":{backgroundColor:ne.orange[100],color:ne.orange[900],border:`1px solid ${ne.orange[500]}`,"& .MuiAlert-icon .MuiSvgIcon-root":{color:ne.orange[800]}},"&.MuiAlert-standardError":{backgroundColor:ne.red[50],color:ne.red[800],border:`1px solid ${ne.red[300]}`,"& .MuiAlert-icon .MuiSvgIcon-root":{color:ne.red[700]}}}}},MuiButton:{styleOverrides:{root:{"&.Mui-disabled":{backgroundColor:ne.grey[400]}}}},MuiSvgIcon:{styleOverrides:{root:{color:Pt.textColor}}},MuiTabs:{styleOverrides:{root:{backgroundColor:Pt.main,color:Pt.textColor,"& .MuiTabs-indicator":{height:"4px"}}}},MuiTab:{styleOverrides:{root:{color:Pt.textColor,fontSize:"1rem",textTransform:"none",fontWeight:400,minHeight:"62px","&:hover":{backgroundColor:Pt.secondary},"&.Mui-selected":{color:Pt.textColor,fontWeight:700},"& > span":{color:ne.purple[900]}}}},MuiAccordionSummary:{styleOverrides:{root:{"& > .MuiAccordionSummary-content.Mui-expanded":{margin:"12px 0"}}}},MuiSwitch:{styleOverrides:{switchBase:{zIndex:1,"&:not(.Mui-checked) .MuiTouchRipple-child":{color:ne.grey[500]}}}},MuiIcon:{styleOverrides:{root:{color:ne.white},colorDisabled:{color:ne.white[600]}}},MuiMenu:{styleOverrides:{root:{".MuiMenu-list":{backgroundColor:ne.darkblue[600]}}}},MuiMenuItem:{styleOverrides:{root:{"&.Mui-disabled":{opacity:.66},"&:hover":{backgroundColor:Pt.secondary}}}},MuiInputBase:{styleOverrides:{root:{backgroundColor:ne.darkblue[1e3],".MuiSvgIcon-root":{color:"#fff"}}}},MuiPaper:{styleOverrides:{root:{backgroundColor:Pt.main,color:Pt.textColor}}}}});var km={},UQ={get exports(){return km},set exports(e){km=e}},b4={};/**
|
|
246
|
+
* @license React
|
|
247
|
+
* use-sync-external-store-shim.production.min.js
|
|
248
|
+
*
|
|
249
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
250
|
+
*
|
|
251
|
+
* This source code is licensed under the MIT license found in the
|
|
252
|
+
* LICENSE file in the root directory of this source tree.
|
|
253
|
+
*/var jc=p;function WQ(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var HQ=typeof Object.is=="function"?Object.is:WQ,VQ=jc.useState,GQ=jc.useEffect,qQ=jc.useLayoutEffect,KQ=jc.useDebugValue;function YQ(e,t){var n=t(),r=VQ({inst:{value:n,getSnapshot:t}}),o=r[0].inst,a=r[1];return qQ(function(){o.value=n,o.getSnapshot=t,y1(o)&&a({inst:o})},[e,n,t]),GQ(function(){return y1(o)&&a({inst:o}),e(function(){y1(o)&&a({inst:o})})},[e]),KQ(n),n}function y1(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!HQ(e,n)}catch{return!0}}function XQ(e,t){return t()}var JQ=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?XQ:YQ;b4.useSyncExternalStore=jc.useSyncExternalStore!==void 0?jc.useSyncExternalStore:JQ;(function(e){e.exports=b4})(UQ);const gi=new WeakMap,b1={},Qf={},Ji=()=>{},qo=Ji(),Nh=Object,kn=e=>e===qo,Ma=e=>typeof e=="function",ki=(e,t)=>({...e,...t}),gx="undefined",cv=typeof window!=gx,_b=typeof document!=gx,QQ=()=>cv&&typeof window.requestAnimationFrame!=gx,w4=(e,t)=>{const n=gi.get(e);return[()=>e.get(t)||b1,r=>{if(!kn(t)){const o=e.get(t);t in Qf||(Qf[t]=o),n[5](t,ki(o,r),o||b1)}},n[6],()=>!kn(t)&&t in Qf?Qf[t]:e.get(t)||b1]},Zf=new WeakMap;let ZQ=0;const vp=e=>{const t=typeof e,n=e&&e.constructor,r=n==Date;let o,a;if(Nh(e)===e&&!r&&n!=RegExp){if(o=Zf.get(e),o)return o;if(o=++ZQ+"~",Zf.set(e,o),n==Array){for(o="@",a=0;a<e.length;a++)o+=vp(e[a])+",";Zf.set(e,o)}if(n==Nh){o="#";const i=Nh.keys(e).sort();for(;!kn(a=i.pop());)kn(e[a])||(o+=a+":"+vp(e[a])+",");Zf.set(e,o)}}else o=r?e.toJSON():t=="symbol"?e.toString():t=="string"?JSON.stringify(e):""+e;return o};let Rb=!0;const eZ=()=>Rb,[Pb,Ib]=cv&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[Ji,Ji],tZ=()=>{const e=_b&&document.visibilityState;return kn(e)||e!=="hidden"},nZ=e=>(_b&&document.addEventListener("visibilitychange",e),Pb("focus",e),()=>{_b&&document.removeEventListener("visibilitychange",e),Ib("focus",e)}),rZ=e=>{const t=()=>{Rb=!0,e()},n=()=>{Rb=!1};return Pb("online",t),Pb("offline",n),()=>{Ib("online",t),Ib("offline",n)}},oZ={isOnline:eZ,isVisible:tZ},aZ={initFocus:nZ,initReconnect:rZ},nA=!jt.useId,yp=!cv||"Deno"in window,iZ=e=>QQ()?window.requestAnimationFrame(e):setTimeout(e,1),Mh=yp?p.useEffect:p.useLayoutEffect,w1=typeof navigator<"u"&&navigator.connection,rA=!yp&&w1&&(["slow-2g","2g"].includes(w1.effectiveType)||w1.saveData),vx=e=>{if(Ma(e))try{e=e()}catch{e=""}const t=e;return e=typeof e=="string"?e:(Array.isArray(e)?e.length:e)?vp(e):"",[e,t]};let sZ=0;const $b=()=>++sZ,S4=0,x4=1,C4=2;var S1={__proto__:null,FOCUS_EVENT:S4,RECONNECT_EVENT:x4,MUTATE_EVENT:C4};async function E4(...e){const[t,n,r,o]=e,a=ki({populateCache:!0,throwOnError:!0},typeof o=="boolean"?{revalidate:o}:o||{});let i=a.populateCache;const l=a.rollbackOnError;let c=a.optimisticData;const u=a.revalidate!==!1,d=m=>typeof l=="function"?l(m):l!==!1,f=a.throwOnError;if(Ma(n)){const m=n,y=[],g=t.keys();for(let v=g.next();!v.done;v=g.next()){const b=v.value;!b.startsWith("$inf$")&&m(t.get(b)._k)&&y.push(b)}return Promise.all(y.map(h))}return h(n);async function h(m){const[y]=vx(m);if(!y)return;const[g,v]=w4(t,y),[b,w,x]=gi.get(t),E=b[y],A=()=>u&&(delete x[y],E&&E[0])?E[0](C4).then(()=>g().data):g().data;if(e.length<3)return A();let k=r,_;const $=$b();w[y]=[$,0];const L=!kn(c),O=g(),P=O.data,D=O._c,F=kn(D)?P:D;if(L&&(c=Ma(c)?c(F):c,v({data:c,_c:F})),Ma(k))try{k=k(F)}catch(Y){_=Y}if(k&&Ma(k.then))if(k=await k.catch(Y=>{_=Y}),$!==w[y][0]){if(_)throw _;return k}else _&&L&&d(_)&&(i=!0,k=F,v({data:k,_c:qo}));i&&(_||(Ma(i)&&(k=i(k,F)),v({data:k,_c:qo}))),w[y][1]=$b();const U=await A();if(v({_c:qo}),_){if(f)throw _;return}return i?U:k}}const oA=(e,t)=>{for(const n in e)e[n][0]&&e[n][0](t)},T4=(e,t)=>{if(!gi.has(e)){const n=ki(aZ,t),r={},o=E4.bind(qo,e);let a=Ji;const i={},l=(d,f)=>{const h=i[d]||[];return i[d]=h,h.push(f),()=>h.splice(h.indexOf(f),1)},c=(d,f,h)=>{e.set(d,f);const m=i[d];if(m)for(let y=m.length;y--;)m[y](f,h)},u=()=>{if(!gi.has(e)&&(gi.set(e,[r,{},{},{},o,c,l]),!yp)){const d=n.initFocus(setTimeout.bind(qo,oA.bind(qo,r,S4))),f=n.initReconnect(setTimeout.bind(qo,oA.bind(qo,r,x4)));a=()=>{d&&d(),f&&f(),gi.delete(e)}}};return u(),[e,o,u,a]}return[e,gi.get(e)[4]]},lZ=(e,t,n,r,o)=>{const a=n.errorRetryCount,i=o.retryCount,l=~~((Math.random()+.5)*(1<<(i<8?i:8)))*n.errorRetryInterval;!kn(a)&&i>a||setTimeout(r,l,o)},cZ=(e,t)=>vp(e)==vp(t),[yx,Vr]=T4(new Map),k4=ki({onLoadingSlow:Ji,onSuccess:Ji,onError:Ji,onErrorRetry:lZ,onDiscarded:Ji,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:rA?1e4:5e3,focusThrottleInterval:5*1e3,dedupingInterval:2*1e3,loadingTimeout:rA?5e3:3e3,compare:cZ,isPaused:()=>!1,cache:yx,mutate:Vr,fallback:{}},oZ),A4=(e,t)=>{const n=ki(e,t);if(t){const{use:r,fallback:o}=e,{use:a,fallback:i}=t;r&&a&&(n.use=r.concat(a)),o&&i&&(n.fallback=ki(o,i))}return n},Ob=p.createContext({}),uZ=e=>{const{value:t}=e,n=p.useContext(Ob),r=Ma(t),o=p.useMemo(()=>r?t(n):t,[r,n,t]),a=p.useMemo(()=>r?o:A4(n,o),[r,n,o]),i=o&&o.provider,[l]=p.useState(()=>i?T4(i(a.cache||yx),o):qo);return l&&(a.cache=l[0],a.mutate=l[1]),Mh(()=>{if(l)return l[2]&&l[2](),l[3]},[]),p.createElement(Ob.Provider,ki(e,{value:a}))},_4=cv&&window.__SWR_DEVTOOLS_USE__,dZ=_4?window.__SWR_DEVTOOLS_USE__:[],pZ=()=>{_4&&(window.__SWR_DEVTOOLS_REACT__=jt)},R4=e=>Ma(e[1])?[e[0],e[1],e[2]||{}]:[e[0],null,(e[1]===null?e[2]:e[1])||{}],fZ=()=>ki(k4,p.useContext(Ob)),hZ=e=>(t,n,r)=>e(t,n&&((...a)=>{const i=vx(t)[0],[,,,l]=gi.get(yx),c=l[i];return c?(delete l[i],c):n(...a)}),r),mZ=dZ.concat(hZ),gZ=e=>function(...n){const r=fZ(),[o,a,i]=R4(n),l=A4(r,i);let c=e;const{use:u}=l,d=(u||[]).concat(mZ);for(let f=d.length;f--;)c=d[f](c);return c(o,a||l.fetcher||null,l)},vZ=(e,t,n)=>{const r=t[e]||(t[e]=[]);return r.push(n),()=>{const o=r.indexOf(n);o>=0&&(r[o]=r[r.length-1],r.pop())}},kPe=(e,t)=>(...n)=>{const[r,o,a]=R4(n),i=(a.use||[]).concat(t);return e(r,o,{...a,use:i})};pZ();const x1={dedupe:!0},yZ=(e,t,n)=>{const{cache:r,compare:o,suspense:a,fallbackData:i,revalidateOnMount:l,revalidateIfStale:c,refreshInterval:u,refreshWhenHidden:d,refreshWhenOffline:f,keepPreviousData:h}=n,[m,y,g]=gi.get(r),[v,b]=vx(e),w=p.useRef(!1),x=p.useRef(!1),E=p.useRef(v),A=p.useRef(t),k=p.useRef(n),_=()=>k.current,$=()=>_().isVisible()&&_().isOnline(),[L,O,P,D]=w4(r,v),F=p.useRef({}).current,U=kn(i)?n.fallback[v]:i,Y=(me,Ge)=>{let qe=!0;for(const Be in F){const he=Be;he==="data"?o(Ge[he],me[he])||kn(me[he])&&o(Ge[he],re)||(qe=!1):Ge[he]!==me[he]&&(qe=!1)}return qe},V=p.useMemo(()=>{const me=(()=>!v||!t?!1:kn(l)?_().isPaused()||a?!1:kn(c)?!0:c:l)(),Ge=he=>{const Et=ki(he);return delete Et._k,me?{isValidating:!0,isLoading:!0,...Et}:Et};let qe=Ge(L());const Be=Ge(D());return[()=>{const he=Ge(L());return Y(he,qe)?qe:qe=he},()=>Be]},[r,v]),te=km.useSyncExternalStore(p.useCallback(me=>P(v,(Ge,qe)=>{Y(qe,Ge)||me()}),[r,v]),V[0],V[1]),Z=!w.current,W=m[v]&&m[v].length>0,z=te.data,R=kn(z)?U:z,M=te.error,ee=p.useRef(R),re=h?kn(z)?ee.current:z:R,Se=(()=>W&&!kn(M)?!1:Z&&!kn(l)?l:_().isPaused()?!1:a?kn(R)?!1:c:kn(R)||c)(),ce=!!(v&&t&&Z&&Se),Ce=kn(te.isValidating)?ce:te.isValidating,xe=kn(te.isLoading)?ce:te.isLoading,Ee=p.useCallback(async me=>{const Ge=A.current;if(!v||!Ge||x.current||_().isPaused())return!1;let qe,Be,he=!0;const Et=me||{},Ke=!g[v]||!Et.dedupe,ct=()=>nA?!x.current&&v===E.current&&w.current:v===E.current,Rt={isValidating:!1,isLoading:!1},dt=()=>{O(Rt)},rt=()=>{const xt=g[v];xt&&xt[1]===Be&&delete g[v]},Nt={isValidating:!0};kn(L().data)&&(Nt.isLoading=!0);try{if(Ke&&(O(Nt),n.loadingTimeout&&kn(L().data)&&setTimeout(()=>{he&&ct()&&_().onLoadingSlow(v,n)},n.loadingTimeout),g[v]=[Ge(b),$b()]),[qe,Be]=g[v],qe=await qe,Ke&&setTimeout(rt,n.dedupingInterval),!g[v]||g[v][1]!==Be)return Ke&&ct()&&_().onDiscarded(v),!1;Rt.error=qo;const xt=y[v];if(!kn(xt)&&(Be<=xt[0]||Be<=xt[1]||xt[1]===0))return dt(),Ke&&ct()&&_().onDiscarded(v),!1;const pe=L().data;Rt.data=o(pe,qe)?pe:qe,Ke&&ct()&&_().onSuccess(qe,v,n)}catch(xt){rt();const pe=_(),{shouldRetryOnError:Te}=pe;pe.isPaused()||(Rt.error=xt,Ke&&ct()&&(pe.onError(xt,v,pe),(Te===!0||Ma(Te)&&Te(xt))&&$()&&pe.onErrorRetry(xt,v,pe,Ee,{retryCount:(Et.retryCount||0)+1,dedupe:!0})))}return he=!1,dt(),!0},[v,r]),tt=p.useCallback((...me)=>E4(r,E.current,...me),[]);if(Mh(()=>{A.current=t,k.current=n,kn(z)||(ee.current=z)}),Mh(()=>{if(!v)return;const me=Ee.bind(qo,x1);let Ge=0;const Be=vZ(v,m,he=>{if(he==S1.FOCUS_EVENT){const Et=Date.now();_().revalidateOnFocus&&Et>Ge&&$()&&(Ge=Et+_().focusThrottleInterval,me())}else if(he==S1.RECONNECT_EVENT)_().revalidateOnReconnect&&$()&&me();else if(he==S1.MUTATE_EVENT)return Ee()});return x.current=!1,E.current=v,w.current=!0,O({_k:b}),Se&&(kn(R)||yp?me():iZ(me)),()=>{x.current=!0,Be()}},[v]),Mh(()=>{let me;function Ge(){const Be=Ma(u)?u(R):u;Be&&me!==-1&&(me=setTimeout(qe,Be))}function qe(){!L().error&&(d||_().isVisible())&&(f||_().isOnline())?Ee(x1).then(Ge):Ge()}return Ge(),()=>{me&&(clearTimeout(me),me=-1)}},[u,d,f,v]),p.useDebugValue(re),a&&kn(R)&&v)throw!nA&&yp?new Error("Fallback data is required when using suspense in SSR."):(A.current=t,k.current=n,x.current=!1,kn(M)?Ee(x1):M);return{mutate:tt,get data(){return F.data=!0,re},get error(){return F.error=!0,M},get isValidating(){return F.isValidating=!0,Ce},get isLoading(){return F.isLoading=!0,xe}}},bZ=Nh.defineProperty(uZ,"defaultValue",{value:k4});var dn=gZ(yZ);const Dt=(e,t=Oi)=>bx(t,e),Ys=(e,t=Oi)=>bx(t,e),wZ=(e=SZ())=>e==="::baseUriPath::"?"":bx(e),bx=(...e)=>["",...e].join("/").replace(/\/+$/g,"").replace(/\/+/g,"/"),SZ=()=>{const e=document.querySelector('meta[name="baseUriPath"]');return(e==null?void 0:e.content)??""},Oi=wZ(),Ta=Ye(s("path",{d:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"}),"Add"),xZ=Ye(s("path",{d:"M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9h-4v4h-2v-4H9V9h4V5h2v4h4v2z"}),"AddToPhotos"),CZ=Ye(s("path",{d:"M12 2C6.49 2 2 6.49 2 12s4.49 10 10 10 10-4.49 10-10S17.51 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm3-8c0 1.66-1.34 3-3 3s-3-1.34-3-3 1.34-3 3-3 3 1.34 3 3z"}),"Adjust"),EZ=Ye(s("path",{d:"M4 8h4V4H4v4zm6 12h4v-4h-4v4zm-6 0h4v-4H4v4zm0-6h4v-4H4v4zm6 0h4v-4h-4v4zm6-10v4h4V4h-4zm-6 4h4V4h-4v4zm6 6h4v-4h-4v4zm0 6h4v-4h-4v4z"}),"Apps"),TZ=Ye(s("path",{d:"m7 10 5 5 5-5z"}),"ArrowDropDown"),kZ=Ye(s("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"}),"Cancel"),Am=Ye(s("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}),"Check"),AZ=Ye(s("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"}),"CheckCircle"),_Z=Ye(s("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"CircleOutlined"),RZ=Ye(s("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Clear"),uv=Ye(s("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close"),P4=Ye(s("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12 19 6.41z"}),"CloseOutlined"),I4=Ye(s("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm4.5 14H8c-1.66 0-3-1.34-3-3s1.34-3 3-3l.14.01C8.58 8.28 10.13 7 12 7c2.21 0 4 1.79 4 4h.5c1.38 0 2.5 1.12 2.5 2.5S17.88 16 16.5 16z"}),"CloudCircle"),Oo=Ye(s("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"}),"Delete"),PZ=Ye(s("path",{d:"m17 16-4-4V8.82C14.16 8.4 15 7.3 15 6c0-1.66-1.34-3-3-3S9 4.34 9 6c0 1.3.84 2.4 2 2.82V12l-4 4H3v5h5v-3.05l4-4.2 4 4.2V21h5v-5h-4z"}),"DeviceHub"),$4=Ye(s("path",{d:"M11 5.08V2c-5 .5-9 4.81-9 10s4 9.5 9 10v-3.08c-3-.48-6-3.4-6-6.92s3-6.44 6-6.92zM18.97 11H22c-.47-5-4-8.53-9-9v3.08C16 5.51 18.54 8 18.97 11zM13 18.92V22c5-.47 8.53-4 9-9h-3.03c-.43 3-2.97 5.49-5.97 5.92z"}),"DonutLarge"),IZ=Ye(s("path",{d:"M11 18c0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2 2 .9 2 2zm-2-8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 4c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"}),"DragIndicator"),Za=Ye(s("path",{d:"M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.9959.9959 0 0 0-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"}),"Edit"),$Z=Ye(s("path",{d:"M12 7c.55 0 1 .45 1 1v4c0 .55-.45 1-1 1s-1-.45-1-1V8c0-.55.45-1 1-1zm-.01-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm1-3h-2v-2h2v2z"}),"ErrorOutlineRounded"),O4=Ye(s("path",{d:"M20.5 11H19V7c0-1.1-.9-2-2-2h-4V3.5C13 2.12 11.88 1 10.5 1S8 2.12 8 3.5V5H4c-1.1 0-1.99.9-1.99 2v3.8H3.5c1.49 0 2.7 1.21 2.7 2.7s-1.21 2.7-2.7 2.7H2V20c0 1.1.9 2 2 2h3.8v-1.5c0-1.49 1.21-2.7 2.7-2.7 1.49 0 2.7 1.21 2.7 2.7V22H17c1.1 0 2-.9 2-2v-4h1.5c1.38 0 2.5-1.12 2.5-2.5S21.88 11 20.5 11z"}),"Extension"),OZ=Ye(s("circle",{cx:"12",cy:"12",r:"8"}),"FiberManualRecord"),L4=Ye(s("path",{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm-1 4 6 6v10c0 1.1-.9 2-2 2H7.99C6.89 23 6 22.1 6 21l.01-14c0-1.1.89-2 1.99-2h7zm-1 7h5.5L14 6.5V12z"}),"FileCopy"),LZ=Ye(s("path",{d:"M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z"}),"FilterList"),NZ=Ye(s("path",{d:"m14.4 6-.24-1.2c-.09-.46-.5-.8-.98-.8H6c-.55 0-1 .45-1 1v15c0 .55.45 1 1 1s1-.45 1-1v-6h5.6l.24 1.2c.09.47.5.8.98.8H19c.55 0 1-.45 1-1V7c0-.55-.45-1-1-1h-4.6z"}),"FlagRounded"),wx=Ye(s("path",{d:"M11 18h2v-2h-2v2zm1-16C6.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-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5 0-2.21-1.79-4-4-4z"}),"HelpOutline"),MZ=Ye(s("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"}),"Info"),Bd=Ye(s("path",{d:"M11 7h2v2h-2zm0 4h2v6h-2zm1-9C6.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-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"}),"InfoOutlined"),Lb=Ye(s("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"}),"KeyboardArrowDown"),Nb=Ye(s("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"}),"KeyboardArrowDownOutlined"),DZ=Ye(s("path",{d:"M7.41 15.41 12 10.83l4.59 4.58L18 14l-6-6-6 6z"}),"KeyboardArrowUp"),BZ=Ye(s("path",{d:"M17.63 5.84C17.27 5.33 16.67 5 16 5L5 5.01C3.9 5.01 3 5.9 3 7v10c0 1.1.9 1.99 2 1.99L16 19c.67 0 1.27-.33 1.63-.84L22 12l-4.37-6.16z"}),"Label"),FZ=Ye(s("path",{d:"M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9H9V9h10v2zm-4 4H9v-2h6v2zm4-8H9V5h10v2z"}),"LibraryBooks"),zZ=Ye(s("path",{d:"M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5z"}),"Link"),jZ=Ye(s("path",{d:"M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2z"}),"Lock"),UZ=Ye(s("path",{d:"M6 19h4V5H6v14zm8-14v14h4V5h-4z"}),"Pause"),WZ=Ye(s("path",{d:"M8 5v14l11-7z"}),"PlayArrow"),HZ=Ye(s("path",{d:"M12 7c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm0-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"RadioButtonChecked"),aA=Ye(s("path",{d:"M15.73 3H8.27L3 8.27v7.46L8.27 21h7.46L21 15.73V8.27L15.73 3zM12 17.3c-.72 0-1.3-.58-1.3-1.3 0-.72.58-1.3 1.3-1.3.72 0 1.3.58 1.3 1.3 0 .72-.58 1.3-1.3 1.3zm1-4.3h-2V7h2v6z"}),"Report"),Sx=Ye(s("path",{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"}),"Search"),xx=Ye(s("path",{d:"M12 17.27 18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"}),"Star"),Cx=Ye(s("path",{d:"m22 9.24-7.19-.62L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21 12 17.27 18.18 21l-1.63-7.03L22 9.24zM12 15.4l-3.76 2.27 1-4.28-3.32-2.88 4.38-.38L12 6.1l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.4z"}),"StarBorder"),VZ=Ye(s("path",{d:"M23 8c0 1.1-.9 2-2 2-.18 0-.35-.02-.51-.07l-3.56 3.55c.05.16.07.34.07.52 0 1.1-.9 2-2 2s-2-.9-2-2c0-.18.02-.36.07-.52l-2.55-2.55c-.16.05-.34.07-.52.07s-.36-.02-.52-.07l-4.55 4.56c.05.16.07.33.07.51 0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2c.18 0 .35.02.51.07l4.56-4.55C8.02 9.36 8 9.18 8 9c0-1.1.9-2 2-2s2 .9 2 2c0 .18-.02.36-.07.52l2.55 2.55c.16-.05.34-.07.52-.07s.36.02.52.07l3.55-3.56C19.02 8.35 19 8.18 19 8c0-1.1.9-2 2-2s2 .9 2 2z"}),"Timeline"),GZ=Ye(s("path",{d:"M17 6H7c-3.31 0-6 2.69-6 6s2.69 6 6 6h10c3.31 0 6-2.69 6-6s-2.69-6-6-6zm0 10H7c-2.21 0-4-1.79-4-4s1.79-4 4-4h10c2.21 0 4 1.79 4 4s-1.79 4-4 4zM7 9c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"}),"ToggleOffOutlined"),qZ=Ye(s("path",{d:"m19.07 4.93-1.41 1.41C19.1 7.79 20 9.79 20 12c0 4.42-3.58 8-8 8s-8-3.58-8-8c0-4.08 3.05-7.44 7-7.93v2.02C8.16 6.57 6 9.03 6 12c0 3.31 2.69 6 6 6s6-2.69 6-6c0-1.66-.67-3.16-1.76-4.24l-1.41 1.41C15.55 9.9 16 10.9 16 12c0 2.21-1.79 4-4 4s-4-1.79-4-4c0-1.86 1.28-3.41 3-3.86v2.14c-.6.35-1 .98-1 1.72 0 1.1.9 2 2 2s2-.9 2-2c0-.74-.4-1.38-1-1.72V2h-1C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10c0-2.76-1.12-5.26-2.93-7.07z"}),"TrackChanges"),KZ=Ye(s("path",{d:"M12.5 8c-2.65 0-5.05.99-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"}),"Undo"),YZ=Ye(s("path",{d:"M12 5.83 15.17 9l1.41-1.41L12 3 7.41 7.59 8.83 9 12 5.83zm0 12.34L8.83 15l-1.41 1.41L12 21l4.59-4.59L15.17 15 12 18.17z"}),"UnfoldMoreOutlined"),N4=Ye(s("path",{d:"M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"}),"Visibility"),M4=Ye(s("path",{d:"M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7zM2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3 2 4.27zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2zm4.31-.78 3.15 3.15.02-.16c0-1.66-1.34-3-3-3l-.17.01z"}),"VisibilityOff"),XZ=Ye(s("path",{d:"M12 6c3.79 0 7.17 2.13 8.82 5.5-.59 1.22-1.42 2.27-2.41 3.12l1.41 1.41c1.39-1.23 2.49-2.77 3.18-4.53C21.27 7.11 17 4 12 4c-1.27 0-2.49.2-3.64.57l1.65 1.65C10.66 6.09 11.32 6 12 6zm-1.07 1.14L13 9.21c.57.25 1.03.71 1.28 1.28l2.07 2.07c.08-.34.14-.7.14-1.07C16.5 9.01 14.48 7 12 7c-.37 0-.72.05-1.07.14zM2.01 3.87l2.68 2.68C3.06 7.83 1.77 9.53 1 11.5 2.73 15.89 7 19 12 19c1.52 0 2.98-.29 4.32-.82l3.42 3.42 1.41-1.41L3.42 2.45 2.01 3.87zm7.5 7.5 2.61 2.61c-.04.01-.08.02-.12.02-1.38 0-2.5-1.12-2.5-2.5 0-.05.01-.08.01-.13zm-3.4-3.4 1.75 1.75c-.23.55-.36 1.15-.36 1.78 0 2.48 2.02 4.5 4.5 4.5.63 0 1.23-.13 1.77-.36l.98.98c-.88.24-1.8.38-2.75.38-3.79 0-7.17-2.13-8.82-5.5.7-1.43 1.72-2.61 2.93-3.53z"}),"VisibilityOffOutlined"),JZ=Ye(s("path",{d:"M12 6c3.79 0 7.17 2.13 8.82 5.5C19.17 14.87 15.79 17 12 17s-7.17-2.13-8.82-5.5C4.83 8.13 8.21 6 12 6m0-2C7 4 2.73 7.11 1 11.5 2.73 15.89 7 19 12 19s9.27-3.11 11-7.5C21.27 7.11 17 4 12 4zm0 5c1.38 0 2.5 1.12 2.5 2.5S13.38 14 12 14s-2.5-1.12-2.5-2.5S10.62 9 12 9m0-2c-2.48 0-4.5 2.02-4.5 4.5S9.52 16 12 16s4.5-2.02 4.5-4.5S14.48 7 12 7z"}),"VisibilityOutlined"),QZ=Ye(s("path",{d:"M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"}),"Warning"),D4=Ye([s("path",{d:"M12 5.99 19.53 19H4.47L12 5.99M12 2 1 21h22L12 2z"},"0"),s("path",{d:"M13 16h-2v2h2zm0-6h-2v5h2z"},"1")],"WarningAmber"),iA={name:"Unleash",version:"3.x",slogan:"The enterprise ready feature toggle service.",flags:{P:!1,RE:!1,EEA:!1,SE:!1,T:!1,UNLEASH_CLOUD:!1,UG:!1},links:[{value:"Documentation",icon:FZ,href:"https://docs.getunleash.io/docs?source=oss",title:"User documentation"},{value:"GitHub",icon:"c_github",href:"https://github.com/Unleash",title:"Source code on GitHub"}],networkViewEnabled:!1},Ex=400,Jp=200,ZZ=201,B4=404,F4=403,z4=401;class j4 extends Error{constructor(n=z4){super("Authentication required");di(this,"statusCode");this.name="AuthenticationError",this.statusCode=n}}class eee extends Error{constructor(n=F4,r={}){var o;super((o=r.details)!=null&&o.length?r.details[0].message:"You cannot perform this action");di(this,"statusCode");di(this,"body");this.name="ForbiddenError",this.statusCode=n,this.body=r}}class Tx extends Error{constructor(n=Ex,r={}){var o;super((o=r.details)!=null&&o.length?r.details[0].message:"Bad request");di(this,"statusCode");di(this,"body");this.name="BadRequestError",this.statusCode=n,this.body=r}}class kx extends Error{constructor(n=B4){super("The requested resource could not be found.");di(this,"statusCode");this.name="NotFoundError",this.statusCode=n}}class U4 extends Error{constructor(n,r,o){super(`An error occurred while trying to get ${n}.`);di(this,"status");di(this,"body");this.name="ResponseError",this.status=r,this.body=o}}const Mb={Accept:"application/json","Content-Type":"application/json"},yn=e=>async t=>{if(!t.ok)throw new U4(e,t.status,await tee(t));return t},tee=async e=>{try{return await e.json()}catch{return e.statusText}},Lt=()=>{const e=Dt("api/admin/ui-config"),{data:t,error:n,mutate:r}=dn(e,nee),o=p.useCallback(()=>{var c,u;return!Boolean((u=(c=t==null?void 0:t.versionInfo)==null?void 0:c.current)==null?void 0:u.enterprise)},[t]),a=p.useCallback(()=>{var c;return((c=t==null?void 0:t.environment)==null?void 0:c.toLowerCase())==="pro"},[t]),i=p.useCallback(()=>{var c,u,d;return((c=t==null?void 0:t.environment)==null?void 0:c.toLowerCase())!=="pro"&&Boolean((d=(u=t==null?void 0:t.versionInfo)==null?void 0:u.current)==null?void 0:d.enterprise)},[t]);return{uiConfig:p.useMemo(()=>({...iA,...t,flags:{...iA.flags,...t==null?void 0:t.flags}}),[t]),loading:!n&&!t,error:n,refetch:r,isOss:o,isPro:a,isEnterprise:i}},nee=e=>fetch(e).then(yn("configuration")).then(t=>t.json()),W4=()=>{const{themeMode:e,setThemeMode:t}=p.useContext(Ps),{uiConfig:n}=Lt(),r=`${n.baseUriPath}:unleash-theme`;return{resolveTheme:()=>e==="light"?ws:jQ,onSetThemeMode:()=>{t(i=>i==="light"?(zc(r,"dark"),"dark"):(zc(r,"light"),"light"))},themeMode:e}},ree=r$({key:"mui",prepend:!0}),oee=({children:e})=>{const{resolveTheme:t}=W4();return s(aF,{value:ree,children:T(N7,{theme:t(),children:[s(DV,{}),e]})})};var aee=function(t,n){return t===void 0&&(t=[]),n===void 0&&(n=[]),t.length!==n.length||t.some(function(r,o){return!Object.is(r,n[o])})},sA={error:null},iee=function(e){QS(t,e);function t(){for(var r,o=arguments.length,a=new Array(o),i=0;i<o;i++)a[i]=arguments[i];return r=e.call.apply(e,[this].concat(a))||this,r.state=sA,r.resetErrorBoundary=function(){for(var l,c=arguments.length,u=new Array(c),d=0;d<c;d++)u[d]=arguments[d];r.props.onReset==null||(l=r.props).onReset.apply(l,u),r.reset()},r}t.getDerivedStateFromError=function(o){return{error:o}};var n=t.prototype;return n.reset=function(){this.setState(sA)},n.componentDidCatch=function(o,a){var i,l;(i=(l=this.props).onError)==null||i.call(l,o,a)},n.componentDidUpdate=function(o,a){var i=this.state.error,l=this.props.resetKeys;if(i!==null&&a.error!==null&&aee(o.resetKeys,l)){var c,u;(c=(u=this.props).onResetKeysChange)==null||c.call(u,o.resetKeys,l),this.reset()}},n.render=function(){var o=this.state.error,a=this.props,i=a.fallbackRender,l=a.FallbackComponent,c=a.fallback;if(o!==null){var u={error:o,resetErrorBoundary:this.resetErrorBoundary};if(p.isValidElement(c))return c;if(typeof i=="function")return i(u);if(l)return p.createElement(l,u);throw new Error("react-error-boundary requires either a fallback, fallbackRender, or FallbackComponent prop")}return this.props.children},t}(p.Component);const X=({condition:e,show:t,elseShow:n})=>{const r=a=>{const i=a();return i||(console.warn("Nothing was returned from your render function. Verify that you are returning a valid react component"),null)},o=a=>typeof a=="function";return e?o(t)?r(t):t:!e&&n?o(n)?r(n):n:null},see="NAVIGATE_TO_CREATE_FEATURE",APe="NAVIGATE_TO_CREATE_GROUP",lee="NAVIGATE_TO_CREATE_SEGMENT",_Pe="CREATE_API_TOKEN_BUTTON",cee="CF_NAME_ID",uee="CF_TYPE_ID",dee="CF_DESC_ID",pee="CF_CREATE_BTN_ID",RPe="UG_NAME_ID",PPe="UG_DESC_ID",IPe="UG_USERS_ID",$Pe="UG_CREATE_BTN_ID",OPe="UG_SAVE_BTN_ID",LPe="UG_EDIT_BTN_ID",NPe="UG_DELETE_BTN_ID",MPe="UG_EDIT_USERS_BTN_ID",DPe="UG_REMOVE_USER_BTN_ID",BPe="PA_ASSIGN_BUTTON_ID",FPe="PA_USERS_GROUPS_ID",zPe="PA_ROLE_ID",jPe="PA_ASSIGN_CREATE_ID",UPe="PA_USERS_GROUPS_TITLE_ID",WPe="PA_EDIT_BUTTON_ID",HPe="PA_REMOVE_BUTTON_ID",fee="SEGMENT_NAME_ID",hee="SEGMENT_DESC_ID",mee="SEGMENT_NEXT_BTN_ID",gee="SEGMENT_CREATE_BTN_ID",vee="SEGMENT_SAVE_BTN_ID",yee="SEGMENT_DELETE_BTN_ID",bee="SEGMENT_DIALOG_NAME_ID",dv="LOGIN_EMAIL_ID",pv="LOGIN_BUTTON",H4="LOGIN_PASSWORD_ID",wee="SSO_LOGIN_BUTTON",See="FORGOTTEN_PASSWORD_FIELD",xee="INVALID_TOKEN_BUTTON",VPe="FEATURE_ENVIRONMENT_ACCORDION",lA="ADD_NEW_STRATEGY_ID",Cee="ROLLOUT_SLIDER_ID",Eee="DIALOGUE_CONFIRM_ID",Tee="FLEXIBLE_STRATEGY_STICKINESS_ID",kee="FLEXIBLE_STRATEGY_GROUP_ID",V4="SELECT_ITEM_ID",Aee="STRATEGY_INPUT_LIST",_ee="ADD_TO_STRATEGY_INPUT_LIST",Ree="STRATEGY_FORM_SUBMIT_ID",GPe="STRATEGY_FORM_REMOVE_ID",qPe="STRATEGY_FORM_COPY_ID",G4="INPUT_ERROR_TEXT",Pee="HEADER_USER_AVATAR",Iee="SIDEBAR_MODAL_ID",$ee="AUTH_PAGE_ID",Oee="ANNOUNCER_ELEMENT_TEST_ID",Ax="INSTANCE_STATUS_BAR_ID",Lee="TOAST_TEXT",KPe="LARGE_NUMBER_PRETTIFIED",YPe="IMPORT_BUTTON",XPe="CODE_EDITOR_TAB",JPe="IMPORT_ENVIRONMENT",QPe="CODE_TEXT_FIELD",ZPe="VALIDATE_BUTTON",eIe="IMPORT_CONFIGURATION_BUTTON",Nee=C(ZV)(({theme:e,maxWidth:t})=>({"& .MuiDialog-paper":{borderRadius:e.shape.borderRadiusLarge,maxWidth:t?void 0:e.spacing(85),backgroundColor:"transparent"}})),Mee=C(bG)(({theme:e})=>({backgroundColor:e.palette.primary.main,color:e.palette.text.tertiaryContrast,padding:e.spacing(3.5,6),fontWeight:e.fontWeight.medium})),Dee=C("div")(({theme:e})=>({padding:e.spacing(6),backgroundColor:e.palette.background.paper})),Bee=C(hG)(({theme:e})=>({padding:0,marginBottom:e.spacing(6)})),Fee=C(aG)(({theme:e})=>({gap:e.spacing(2),padding:0})),Zn=({children:e,open:t,onClick:n,onClose:r,title:o,primaryButtonText:a,disabledPrimaryButton:i=!1,secondaryButtonText:l,maxWidth:c,fullWidth:u=!1,formId:d,permissionButton:f})=>{const h=d?m=>{m.preventDefault(),n&&n(m)}:n;return T(Nee,{open:t,onClose:r,fullWidth:u,"aria-labelledby":"simple-modal-title","aria-describedby":"simple-modal-description",maxWidth:c,children:[s(Mee,{children:o}),T(Dee,{children:[s(X,{condition:Boolean(e),show:s(Bee,{children:e})}),T(Fee,{children:[s(X,{condition:Boolean(f),show:f,elseShow:s(X,{condition:Boolean(n),show:s(Ze,{form:d,color:"primary",variant:"contained",onClick:h,autoFocus:!d,disabled:i,"data-testid":Eee,type:d?"submit":"button",children:a||"Yes, I'm sure"})})}),s(X,{condition:Boolean(r),show:s(Ze,{onClick:r,children:l||"No, take me back"})})]})]})]})},q4=p.createContext(null),ka=()=>{const e=p.useContext(q4);return{trackEvent:p.useCallback((n,r,o)=>{e!=null&&e.trackEvent?e.trackEvent(n,r,o):r!=null&&r.callback&&r.callback()},[e])}},zee=({error:e})=>{const t=lt(),{trackEvent:n}=ka();return p.useEffect(()=>{var a;const{message:r,stack:o="unknown"}=e;n("unknown_ui_error",{props:{location:((a=window==null?void 0:window.location)==null?void 0:a.href)||"unknown",message:r,stack:o}})},[]),s(Me,{sx:{backgroundColor:"neutral.light",height:"100%",p:4},children:T(Zn,{open:!0,title:"Something went wrong",primaryButtonText:"Go back",onClick:()=>{var r;t("/"),(r=window==null?void 0:window.location)==null||r.reload()},secondaryButtonText:"Reload this page",onClose:()=>{var r;(r=window==null?void 0:window.location)==null||r.reload()},maxWidth:"xl",children:[s(Me,{component:"pre",sx:{color:"error.main"},children:e.message}),s(X,{condition:Boolean(e.stack),show:s(Me,{component:"pre",sx:{color:"error.main"},children:e.stack})})]})})};var _x={},cn={},jee={get exports(){return cn},set exports(e){cn=e}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(jee);var C1={};const Uee=zP(Cj);var cA;function Cn(){return cA||(cA=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=Uee}(C1)),C1}const En=zP(SM);var Wee=cn;Object.defineProperty(_x,"__esModule",{value:!0});var fv=_x.default=void 0,Hee=Wee(Cn()),Vee=En,Gee=(0,Hee.default)((0,Vee.jsx)("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close");fv=_x.default=Gee;const qee=e=>p.createElement("svg",{width:23,height:23,viewBox:"0 0 23 23",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("rect",{x:.288513,y:.288574,width:7.13461,height:22.4231,fill:"#1A4049"}),p.createElement("rect",{x:15.5769,y:.288574,width:7.13461,height:22.4231,fill:"#1A4049"}),p.createElement("path",{d:"M22.7115 15.5771L22.7115 22.7118L0.28841 22.7118L0.28841 15.5771L22.7115 15.5771Z",fill:"#1A4049"}),p.createElement("rect",{x:15.5769,y:15.5771,width:7.13461,height:7.13461,fill:"#817AFE"})),Rx=({mounted:e,enter:t,start:n,leave:r,children:o,onStart:a,onEnd:i})=>{const[l,c]=p.useState(e),[u,d]=p.useState({}),f=p.useRef(null);return p.useEffect(()=>{(f.current!==e||f===null)&&(e?(c(!0),a==null||a(),setTimeout(()=>{d(t)},50)):(r||c(!1),d(r||{})))},[e,t,a,r]),s(X,{condition:l,show:s("div",{onTransitionEnd:()=>{e||(c(!1),i==null||i())},style:{...n,...u},children:o})})},Kee=Object.fromEntries?Object.fromEntries:e=>{if(!e||!e[Symbol.iterator])throw new Error("Object.fromEntries() requires a single iterable argument");const t={};return Object.keys(e).forEach(n=>{const[r,o]=e[n];t[r]=o}),t};function _m(e){return Object.keys(e)}function K4(e,t){if(!e)throw new Error(t)}function Y4(e,t){return t}const Px=e=>{const t=e.length;let n=0,r="";for(;n<t;n++){const o=e[n];if(o==null)continue;let a;switch(typeof o){case"boolean":break;case"object":{if(Array.isArray(o))a=Px(o);else{K4(!Y4(o,!1)),a="";for(const i in o)o[i]&&i&&(a&&(a+=" "),a+=i)}break}default:a=o}a&&(r&&(r+=" "),r+=a)}return r};function Yee(e,t){const n=p.useRef();return(!n.current||t.length!==n.current.prevDeps.length||n.current.prevDeps.map((r,o)=>r===t[o]).indexOf(!1)>=0)&&(n.current={v:e(),prevDeps:[...t]}),n.current.v}function Xee(e){return e instanceof Object&&!("styles"in e)&&!("length"in e)&&!("__emotion_styles"in e)}const{createCssAndCx:Jee}=(()=>{function e(n,r,o){const a=[],i=s$(n,a,o);return a.length<2?o:i+r(a)}function t(n){const{cache:r}=n,o=(...i)=>{const l=Mg(i,r.registered);OS(r,l,!1);const c=`${r.key}-${l.name}`;e:{const u=i[0];if(!Xee(u))break e;uA.saveClassNameCSSObjectMapping(r,c,u)}return c};return{css:o,cx:(...i)=>{const l=Px(i),c=uA.fixClassName(r,l,o);return e(r.registered,o,c)}}}return{createCssAndCx:t}})();function Qee(e){const{useCache:t}=e;function n(){const r=t(),{css:o,cx:a}=Yee(()=>Jee({cache:r}),[r]);return{css:o,cx:a}}return{useCssAndCx:n}}const uA=(()=>{const e=new WeakMap;return{saveClassNameCSSObjectMapping:(t,n,r)=>{let o=e.get(t);o===void 0&&(o=new Map,e.set(t,o)),o.set(n,r)},fixClassName:(()=>{function t(n){let r=!1;return n.map(([o,a])=>{if(a===void 0)return o;let i;if(r)i={"&&":a};else{i=o;for(const l in a)if(l.startsWith("@media")){r=!0;break}}return i})}return(n,r,o)=>{const a=e.get(n);return Px(t(r.split(" ").map(i=>[i,a==null?void 0:a.get(i)])).map(i=>typeof i=="string"?i:o(i)))}})()}})();function eh(e){if(!(e instanceof Object)||typeof e=="function")return e;const t=[];for(const n in e){const r=e[n],o=typeof r;if(!(o==="string"||o==="number"&&!isNaN(r)||o==="boolean"||r===void 0||r===null))return e;t.push(`${n}:${o}_${r}`)}return"xSqLiJdLMd9s"+t.join("|")}function dA(e,t,n){if(!(t instanceof Object))return e;const r={};return _m(e).forEach(o=>r[o]=n(e[o],t[o])),_m(t).forEach(o=>{if(o in e)return;const a=t[o];typeof a=="string"&&(r[o]=a)}),r}let Zee=0;function X4(e){const{useTheme:t,cache:n}=e;function r(){var l;const c=iF(),u=tte(),d=(l=n??u)!==null&&l!==void 0?l:c;if(d===null)throw new Error(["In order to get SSR working with tss-react you need to explicitly provide an Emotion cache.","MUI users be aware: This is not an error strictly related to tss-react, with or without tss-react,","MUI needs an Emotion cache to be provided for SSR to work.","Here is the MUI documentation related to SSR setup: https://mui.com/material-ui/guides/server-rendering/","TSS provides helper that makes the process of setting up SSR easier: https://docs.tss-react.dev/ssr"].join(`
|
|
254
|
+
`));return d}const{useCssAndCx:o}=Qee({useCache:r});function a(l){const{name:c,uniqId:u=Zee++}=l??{},d=typeof c!="object"?c:Object.keys(c)[0];return function(f){const h=typeof f=="function"?f:()=>f;return function(y,g){var v,b;const w=t(),{css:x,cx:E}=o(),A=r();let k=p.useMemo(()=>{const $={},L=typeof Proxy<"u"&&new Proxy({},{get:(D,F)=>(typeof F=="symbol"&&K4(!1),$[F]=`${A.key}-${u}${d!==void 0?`-${d}`:""}-${F}-ref`)}),O=h(w,y,L||{}),P=Kee(_m(O).map(D=>{const F=O[D];return F.label||(F.label=`${d!==void 0?`${d}-`:""}${D}`),[D,`${x(F)}${Y4(D,D in $)?` ${$[D]}`:""}`]}));return _m($).forEach(D=>{D in P||(P[D]=$[D])}),P},[A,x,E,w,eh(y)]);const _=g==null?void 0:g.props.classes;k=p.useMemo(()=>dA(k,_,E),[k,eh(_),E]);{let $;try{$=d!==void 0?(b=(v=w.components)===null||v===void 0?void 0:v[d])===null||b===void 0?void 0:b.styleOverrides:void 0}catch{}const L=p.useMemo(()=>{if(!$)return;const O={};for(const P in $){const D=$[P];D instanceof Object&&(O[P]=x(typeof D=="function"?D(Object.assign({theme:w,ownerState:g==null?void 0:g.ownerState},g==null?void 0:g.props)):D))}return O},[$===void 0?void 0:JSON.stringify($),eh(g==null?void 0:g.props),eh(g==null?void 0:g.ownerState),x]);k=p.useMemo(()=>dA(k,L,E),[k,L,E])}return{classes:k,theme:w,css:x,cx:E}}}}function i(){const l=t(),{css:c,cx:u}=o();return{theme:l,css:c,cx:u}}return{makeStyles:a,useStyles:i}}const ete=p.createContext(void 0);function tte(){return p.useContext(ete)}function pA(e){return e.charAt(0).toUpperCase()+e.slice(1)}var fA=globalThis&&globalThis.__rest||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(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function nte(e){const{useTheme:t,cache:n}=e,{makeStyles:r}=X4({useTheme:t,cache:n});function o(a,i,l){const c=typeof a=="string"?(()=>{const m=a,y=function(g){var{children:v}=g,b=fA(g,["children"]);return p.createElement(m,b,v)};return Object.defineProperty(y,"name",{value:pA(m)}),y})():a,u=(()=>{{const{name:m}=l??{};if(m!==void 0)return typeof m!="object"?m:Object.keys(m)[0]}{const m=c.displayName;if(typeof m=="string"&&m!=="")return m}{const{name:m}=c;if(m)return m}})(),d=r(Object.assign(Object.assign({},l),{name:u}))(typeof i=="function"?(m,y,g)=>hA(i(m,y,g)):hA(i));function f(m){for(const y in m)if(y!=="root")return!0;return!1}const h=p.forwardRef(function(m,y){const{className:g,classes:v}=m,b=fA(m,["className","classes"]),{classes:w,cx:x}=d(m,{props:m});return jt.createElement(c,Object.assign({ref:y,className:f(w)?g:x(w.root,g)},typeof a=="string"?{}:{classes:w},b))});return u!==void 0&&(h.displayName=`${pA(u)}WithStyles`,Object.defineProperty(h,"name",{value:h.displayName})),h}return{withStyles:o}}function hA(e){const t={},n={};return Object.keys(e).forEach(r=>(r.startsWith("@media")?n:t)[r]=e[r]),Object.keys(n).forEach(r=>{const o=n[r];Object.keys(o).forEach(a=>{var i;return t[a]=Object.assign(Object.assign({},(i=t[a])!==null&&i!==void 0?i:{}),{[r]:o[a]})})}),t}function rte(e){return Object.assign(Object.assign({},X4(e)),nte(e))}const{makeStyles:Li,withStyles:ote,useStyles:tIe}=rte({useTheme:on}),hv=e=>({"&:focus-visible":{outline:0,outlineStyle:"solid",outlineWidth:2,outlineOffset:2,outlineColor:e.palette.primary.main}}),Qp=e=>({"& > *":{marginTop:`${e.spacing(1)} !important`,marginBottom:`${e.spacing(1)} !important`}}),ate=e=>({fontSize:e.fontSizes.mainHeader,fontWeight:"bold",marginBottom:e.spacing(1)}),J4={textAlign:"center"},ite={textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},Zp={display:"flex",alignItems:"center"},Q4={display:"flex",flexDirection:"column"},ste={alignItems:"center"},lte={position:"relative"},nIe=e=>({borderRadius:`${e.shape.borderRadius}px`}),Z4={opacity:"0",right:"40px",bottom:"40px",transform:"translateY(400px)",zIndex:1400,position:"fixed"},e3={transform:"translateY(0)",opacity:"1",transition:"transform 0.6s ease, opacity 1s ease"},cte={transform:"translateY(400px)",opacity:"0",transition:"transform 1.25s ease, opacity 1s ease"},ute=e=>({opacity:"0",position:"fixed",right:"40px",top:"40px",transform:"translateY(-400px)",[e.breakpoints.down("sm")]:{right:20,left:10,top:40}}),dte={transform:"translateY(100px)",opacity:"1",transition:"transform 0.6s ease, opacity 1s ease"},pte={transform:"translateY(-400px)",opacity:"0",transition:"transform 1.25s ease, opacity 1s ease"},ef=Li()(e=>({focusable:{"&:focus-visible":{outline:0,outlineStyle:"solid",outlineWidth:2,outlineOffset:2,outlineColor:e.palette.primary.main}},contentSpacingY:{"& > *":{marginTop:"0.5rem !important",marginBottom:"0.5rem !important"}},divider:{margin:"1rem 0",backgroundColor:e.palette.divider,height:"3px",width:"100%"},largeDivider:{margin:"2rem 0",backgroundColor:e.palette.divider,height:"3px",width:"100%"},bold:{fontWeight:"bold"},flexRow:{display:"flex",alignItems:"center"},flexColumn:{display:"flex",flexDirection:"column"},itemsCenter:{alignItems:"center"},justifyCenter:{justifyContent:"center"},flexWrap:{flexWrap:"wrap"},textCenter:{textAlign:"center"},fullWidth:{width:"100%"},fullHeight:{height:"100%"},title:{fontSize:e.fontSizes.mainHeader,fontWeight:"bold",marginBottom:"0.5rem"},error:{fontSize:e.fontSizes.smallBody,color:e.palette.error.main}}));function Wn(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function Dh(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Dh=function(n){return typeof n}:Dh=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Dh(e)}function sr(e){Wn(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||Dh(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function bp(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}function mA(e){Wn(1,arguments);var t=sr(e);return t.setHours(0,0,0,0),t}var fte=864e5;function hte(e,t){Wn(2,arguments);var n=mA(e),r=mA(t),o=n.getTime()-bp(n),a=r.getTime()-bp(r);return Math.round((o-a)/fte)}function gA(e,t){var n=e.getFullYear()-t.getFullYear()||e.getMonth()-t.getMonth()||e.getDate()-t.getDate()||e.getHours()-t.getHours()||e.getMinutes()-t.getMinutes()||e.getSeconds()-t.getSeconds()||e.getMilliseconds()-t.getMilliseconds();return n<0?-1:n>0?1:n}function t3(e,t){Wn(2,arguments);var n=sr(e),r=sr(t),o=gA(n,r),a=Math.abs(hte(n,r));n.setDate(n.getDate()-o*a);var i=Number(gA(n,r)===-o),l=o*(a-i);return l===0?0:l}const n3="pnps",mte=e=>{if(!e)return!1;if(e.length===0)return!0;const t=e.find(n=>n.feedbackId===n3);if(!t)return!0;if(t.neverShow)return!1;if(t.given){const r=new Date;return t3(r,new Date(t.given))>182}return!1},tf=()=>{const{data:e,error:t}=dn(Db,gte,vte),n=p.useCallback(()=>{Vr(Db).catch(console.warn)},[]);return{data:e,refetchAuth:n,loading:!t&&!e,error:t}},gte=()=>fetch(Db).then(e=>e.json()),vte={revalidateIfStale:!1,revalidateOnFocus:!1,revalidateOnReconnect:!1,refreshInterval:15e3},Db=Dt("api/admin/user"),Ix=()=>{const e=tf();return{feedback:e.data&&"feedback"in e.data?e.data.feedback:void 0,refetchFeedback:e.refetchAuth,loading:e.loading,error:e.error}},r3=()=>{const{refetchFeedback:e}=Ix(),t=Dt("api/admin/feedback"),n=p.useCallback(async o=>{await vA("POST",t,o),await e()},[t,e]),r=p.useCallback(async o=>{const a=`${t}/${o.feedbackId}`;await vA("PUT",a,o),await e()},[t,e]);return{createFeedback:n,updateFeedback:r}},vA=async(e,t,n)=>{await fetch(t,{method:e,headers:{"Content-Type":"application/json"},body:JSON.stringify(n)})},yte=({openUrl:e})=>{const{showFeedback:t,setShowFeedback:n}=p.useContext(Ps),{createFeedback:r,updateFeedback:o}=r3(),{feedback:a}=Ix(),[i,l]=p.useState(!1),c=on(),u=n3,d=p.useMemo(()=>({start:{...ute(c),zIndex:c.zIndex.tooltip},enter:dte,leave:pte}),[c]),f=async()=>{try{await r({feedbackId:u})}catch(m){console.warn(m),n(!1)}window.open(e,"_blank"),setTimeout(()=>{n(!1)},200)},h=async()=>{try{await o({feedbackId:u,neverShow:!0})}catch(m){console.warn(m),n(!1)}setTimeout(()=>{n(!1)},100)};return mte(a)?s(Rx,{mounted:t,start:d.start,enter:d.enter,leave:d.leave,children:s(Me,{sx:{borderRadius:"12.5px",backgroundColor:c.palette.background.paper,zIndex:9999,boxShadow:"2px 2px 4px 4px rgba(143,143,143, 0.25)",padding:c.spacing(3),maxWidth:"400px"},children:T(Me,{sx:{display:"flex",flexDirection:"column",position:"relative",...Qp(c)},children:[s(_t,{title:"Close",arrow:!0,children:s(Yt,{sx:{position:"absolute",right:"-38px",top:"-47px",backgroundColor:c.palette.background.paper,boxShadow:"2px 2px 4px 4px rgba(143,143,143, 0.25)","&:hover":{backgroundColor:"#fff"}},onClick:()=>n(!1),size:"large",children:s(fv,{})})}),s(qee,{style:{width:"25px",height:"25px"}}),s(X,{condition:i,show:s("p",{children:"Alright, apologies for the disruption. Have a nice day!"}),elseShow:T("p",{children:["Hi. Do you have 2 minutes to help us improve Unleash?"," "]})}),s(Me,{children:s(X,{condition:i,show:s(Ze,{variant:"outlined",onClick:h,children:"Don't show again"}),elseShow:T(ke,{children:[s(Ze,{variant:"contained",color:"primary",onClick:f,children:"Yes, no problem"}),s(Ze,{sx:{marginLeft:m=>m.spacing(2)},onClick:()=>l(!0),children:"Not now"})]})})})]})})}):null};var $x={},bte=cn;Object.defineProperty($x,"__esModule",{value:!0});var o3=$x.default=void 0,wte=bte(Cn()),Ste=En,xte=(0,wte.default)((0,Ste.jsx)("path",{d:"M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"}),"Menu");o3=$x.default=xte;var Ox={},Cte=cn;Object.defineProperty(Ox,"__esModule",{value:!0});var Lx=Ox.default=void 0,Ete=Cte(Cn()),Tte=En,kte=(0,Ete.default)((0,Tte.jsx)("path",{d:"M19.14 12.94c.04-.3.06-.61.06-.94 0-.32-.02-.64-.07-.94l2.03-1.58c.18-.14.23-.41.12-.61l-1.92-3.32c-.12-.22-.37-.29-.59-.22l-2.39.96c-.5-.38-1.03-.7-1.62-.94l-.36-2.54c-.04-.24-.24-.41-.48-.41h-3.84c-.24 0-.43.17-.47.41l-.36 2.54c-.59.24-1.13.57-1.62.94l-2.39-.96c-.22-.08-.47 0-.59.22L2.74 8.87c-.12.21-.08.47.12.61l2.03 1.58c-.05.3-.09.63-.09.94s.02.64.07.94l-2.03 1.58c-.18.14-.23.41-.12.61l1.92 3.32c.12.22.37.29.59.22l2.39-.96c.5.38 1.03.7 1.62.94l.36 2.54c.05.24.24.41.48.41h3.84c.24 0 .44-.17.47-.41l.36-2.54c.59-.24 1.13-.56 1.62-.94l2.39.96c.22.08.47 0 .59-.22l1.92-3.32c.12-.22.07-.47-.12-.61l-2.01-1.58zM12 15.6c-1.98 0-3.6-1.62-3.6-3.6s1.62-3.6 3.6-3.6 3.6 1.62 3.6 3.6-1.62 3.6-3.6 3.6z"}),"Settings");Lx=Ox.default=kte;var Nx={},Ate=cn;Object.defineProperty(Nx,"__esModule",{value:!0});var a3=Nx.default=void 0,_te=Ate(Cn()),Rte=En,Pte=(0,_te.default)((0,Rte.jsx)("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"}),"KeyboardArrowDown");a3=Nx.default=Pte;var Mx={},Ite=cn;Object.defineProperty(Mx,"__esModule",{value:!0});var i3=Mx.default=void 0,$te=Ite(Cn()),Ote=En,Lte=(0,$te.default)((0,Ote.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"}),"OpenInNew");i3=Mx.default=Lte;const Nte=C(iv)(({theme:e})=>({width:e.spacing(3.5),height:e.spacing(3.5),margin:"auto",backgroundColor:e.palette.secondary.light,color:e.palette.text.primary,fontSize:e.fontSizes.smallerBody,fontWeight:e.fontWeight.bold})),Dx=({user:e,src:t,title:n,onMouseEnter:r,onMouseLeave:o,className:a,sx:i,children:l,...c})=>{!n&&!r&&e&&(n=`${(e==null?void 0:e.name)||(e==null?void 0:e.email)||(e==null?void 0:e.username)} (id: ${e==null?void 0:e.id})`),!t&&e&&(t=e==null?void 0:e.imageUrl);let u;return!l&&e&&(u=(e==null?void 0:e.name)||(e==null?void 0:e.email)||(e==null?void 0:e.username),u&&u.includes(" ")?u=`${u.split(" ")[0][0]}${u.split(" ")[1][0]}`.toUpperCase():u&&(u=u[0].toUpperCase())),s(Nte,{className:a,sx:i,...c,"data-loading":!0,alt:"Gravatar",src:t,title:n,onMouseEnter:r,onMouseLeave:o,children:s(X,{condition:Boolean(u),show:u,elseShow:l})})},Mte=C(pr)(({theme:e})=>({display:"flex",flexDirection:"column",alignItems:"center",padding:e.spacing(3),borderRadius:e.shape.borderRadiusMedium,boxShadow:e.boxShadows.popup,position:"absolute",zIndex:5e3,minWidth:e.spacing(37.5),right:0,[e.breakpoints.down("md")]:{width:"100%",padding:"1rem"}})),Dte=C("div")(({theme:e})=>({alignSelf:"flex-start",display:"flex",alignItems:"center",marginBottom:e.spacing(2)})),Bte=C(Dx)(({theme:e})=>({width:e.spacing(4.75),height:e.spacing(4.75),marginRight:e.spacing(1.5)})),Fte=C(ye)(({theme:e})=>({color:e.palette.text.secondary})),s3=C(go)(({theme:e})=>({display:"flex",alignItems:"center",gap:e.spacing(1),padding:0,color:e.palette.primary.dark,fontWeight:e.fontWeight.medium,"&:hover, &:focus":{textDecoration:"underline"},"& svg":{fontSize:e.spacing(2.25)}})),zte=C(s3)(({theme:e})=>({alignSelf:"flex-start"})),jte=C(Ze)(({theme:e})=>({width:"100%",height:e.spacing(5)})),yA=C("div")(({theme:e})=>({width:"100%",height:"1px",backgroundColor:e.palette.divider,margin:e.spacing(3,0)})),Ute=({id:e,showProfile:t,setShowProfile:n,profile:r})=>s(X,{condition:t,show:T(Mte,{id:e,children:[T(Dte,{children:[s(Bte,{user:r}),T("div",{children:[s(ye,{children:r.name||r.username}),s(Fte,{variant:"body2",children:r.email})]})]}),s(s3,{component:ln,to:"/profile",underline:"hover",onClick:()=>n(!1),children:"View profile settings"}),s(yA,{}),T(zte,{component:"a",href:"https://www.getunleash.io/privacy-policy",underline:"hover",rel:"noopener noreferrer",target:"_blank",children:["Privacy Policy ",s(i3,{})]}),s(yA,{}),s(jte,{variant:"outlined",color:"primary",href:`${Oi}/logout`,children:"Log out"})]})}),Ss=(e="useId")=>p.useMemo(()=>`${e}-${Wte++}`,[e]);let Wte=0;const Hte=C(Dx)(({theme:e})=>({width:e.spacing(4.5),height:e.spacing(4.5)})),Vte=C("div")(({theme:e})=>({position:"relative"})),Gte=C(Ze)(({theme:e})=>({...hv(e),...Zp,...ste,color:"inherit",padding:e.spacing(.5,2),"&:hover":{backgroundColor:"transparent"}})),qte=C(a3)(({theme:e})=>({color:e.palette.neutral.main})),Kte=({profile:e})=>{const[t,n]=p.useState(!1),r=Ss();return s(k$,{onClickAway:()=>n(!1),children:T(Vte,{children:[T(Gte,{onClick:()=>n(o=>!o),"aria-controls":t?r:void 0,"aria-expanded":t,color:"secondary",disableRipple:!0,children:[s(Hte,{user:e,"data-testid":Pee}),s(qte,{})]}),s(Ute,{id:r,showProfile:t,setShowProfile:n,profile:e})]})})},ca=()=>{const e=tf();return{user:e.data&&"user"in e.data?e.data.user:void 0,refetchUser:e.refetchAuth,loading:e.loading,error:e.error}},bA=()=>{const{user:e}=ca();return e?s(Kte,{profile:e}):null};var Bx={},Yte=cn;Object.defineProperty(Bx,"__esModule",{value:!0});var Fx=Bx.default=void 0,Xte=Yte(Cn()),wA=En,Jte=(0,Xte.default)([(0,wA.jsx)("path",{d:"M21 5c-1.11-.35-2.33-.5-3.5-.5-1.95 0-4.05.4-5.5 1.5-1.45-1.1-3.55-1.5-5.5-1.5S2.45 4.9 1 6v14.65c0 .25.25.5.5.5.1 0 .15-.05.25-.05C3.1 20.45 5.05 20 6.5 20c1.95 0 4.05.4 5.5 1.5 1.35-.85 3.8-1.5 5.5-1.5 1.65 0 3.35.3 4.75 1.05.1.05.15.05.25.05.25 0 .5-.25.5-.5V6c-.6-.45-1.25-.75-2-1zm0 13.5c-1.1-.35-2.3-.5-3.5-.5-1.7 0-4.15.65-5.5 1.5V8c1.35-.85 3.8-1.5 5.5-1.5 1.2 0 2.4.15 3.5.5v11.5z"},"0"),(0,wA.jsx)("path",{d:"M17.5 10.5c.88 0 1.73.09 2.5.26V9.24c-.79-.15-1.64-.24-2.5-.24-1.7 0-3.24.29-4.5.83v1.66c1.13-.64 2.7-.99 4.5-.99zM13 12.49v1.66c1.13-.64 2.7-.99 4.5-.99.88 0 1.73.09 2.5.26V11.9c-.79-.15-1.64-.24-2.5-.24-1.7 0-3.24.3-4.5.83zm4.5 1.84c-1.7 0-3.24.29-4.5.83v1.66c1.13-.64 2.7-.99 4.5-.99.88 0 1.73.09 2.5.26v-1.52c-.79-.16-1.64-.24-2.5-.24z"},"1")],"MenuBook");Fx=Bx.default=Jte;const Qte=e=>p.createElement("svg",{id:"bg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 653.4 251.24",...e},p.createElement("defs",null,p.createElement("style",null,".cls-1{fill:#1a4049;}.cls-2{fill:#fff;}.cls-3{fill:#817afe;}")),p.createElement("circle",{className:"cls-1",cx:125.62,cy:125.62,r:80}),p.createElement("polygon",{className:"cls-2",points:"137.05 91.33 137.05 114.19 137.05 137.05 159.9 137.05 159.9 114.19 159.9 91.33 137.05 91.33"}),p.createElement("polygon",{className:"cls-2",points:"114.19 114.19 114.19 91.33 91.33 91.33 91.33 114.19 91.33 137.05 91.33 159.9 114.19 159.9 137.05 159.9 137.05 137.05 114.19 137.05 114.19 114.19"}),p.createElement("polygon",{className:"cls-2",points:"137.05 91.33 137.05 114.19 137.05 137.05 159.9 137.05 159.9 114.19 159.9 91.33 137.05 91.33"}),p.createElement("polygon",{className:"cls-2",points:"114.19 114.19 114.19 91.33 91.33 91.33 91.33 114.19 91.33 137.05 91.33 159.9 114.19 159.9 137.05 159.9 137.05 137.05 114.19 137.05 114.19 114.19"}),p.createElement("rect",{className:"cls-3",x:137.05,y:137.05,width:22.86,height:22.86}),p.createElement("path",{className:"cls-1",d:"M251.58,139.13V112.77h11.93v25.06c0,7.36,3.91,12.2,11.27,12.2s11.27-4.84,11.27-12.2V112.77h12v26.36c0,12.67-8.48,21.8-23.1,21.8C260.06,160.93,251.58,151.8,251.58,139.13Z"}),p.createElement("path",{className:"cls-1",d:"M321.91,159.9H310.08V112.77h11.83v7.92a17.93,17.93,0,0,1,15.65-9c11.83,0,19.66,8.67,19.66,20.68V159.9h-12V134.75c0-7.45-4.38-12.39-11.46-12.39s-11.83,5-11.83,12.39Z"}),p.createElement("path",{className:"cls-1",d:"M369.42,91.34h11.92V159.9H369.42Z"}),p.createElement("path",{className:"cls-1",d:"M441.24,137v1.3H403.79c.47,7.36,5.87,13,13.69,13,7.55,0,10.62-3.82,11.46-5.12h11.74c-.75,4.84-7.17,15-23.2,15-15.27,0-25.61-10.61-25.61-24.77,0-14.63,10.24-24.78,24.68-24.78S441.24,121.62,441.24,137Zm-37.08-6.9h24.6c-1.77-6-6.15-9.31-12.21-9.31C410.12,120.78,405.65,124.23,404.16,130.09Z"}),p.createElement("path",{className:"cls-1",d:"M467.78,130.37h15.47c0-5.68-4.29-9.31-11.27-9.31-6.62,0-9,3.54-9.78,4.75h-12c1-4.94,6.89-14.25,21.8-14.25,14.62,0,22.73,7.64,22.73,18.81V146.3c0,2.89,1,4,3.72,4.29v9.59h-3.72c-6.06-.09-9.69-2.33-11-6.52-2.23,3.45-7.26,7.27-15.27,7.27-11.09,0-19.47-6.24-19.47-15.93S456.14,130.37,467.78,130.37Zm15.47,12.11v-4H469.74c-5.59,0-9,2-9,6.33,0,4.57,4.29,7.27,10.25,7.27C477.66,152.08,483.25,148.82,483.25,142.48Z"}),p.createElement("path",{className:"cls-1",d:"M523.12,140.62c-10.34-.74-17.33-5.59-17.33-14.72,0-8.85,8.1-14.44,20.77-14.44,17,0,21.8,8.76,23.1,13.32H537.09c-.84-1-3.54-4.28-10.62-4.28-5.68,0-8.66,1.86-8.66,4.75,0,2.61,2,4.29,6.7,4.94l8,.84c12.77,1.11,18,6,18,15.27,0,8.85-7.36,14.91-21.8,14.91-17.51,0-23.19-10.16-24.12-14.53h12.76c.47,1.11,3.35,5.31,11.36,5.31,6.62,0,9.69-2.24,9.69-5.22s-1.67-4.66-7-5.31C528.05,141.18,526.38,141,523.12,140.62Z"}),p.createElement("path",{className:"cls-1",d:"M571.55,159.9H559.72V91.34h11.83v29.35a17.93,17.93,0,0,1,15.65-9c11.83,0,19.66,8.67,19.66,20.68V159.9h-12V134.75c0-7.45-4.38-12.39-11.46-12.39s-11.83,5-11.83,12.39Z"})),Zte=e=>p.createElement("svg",{id:"bg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 653.4 251.24",...e},p.createElement("defs",null,p.createElement("style",null,".cls-1{fill:#fff;}.cls-2{fill:#1a4049;}.cls-3{fill:#817afe;}")),p.createElement("circle",{className:"cls-1",cx:125.62,cy:125.62,r:80}),p.createElement("polygon",{className:"cls-1",points:"137.05 91.33 137.05 114.19 137.05 137.05 159.9 137.05 159.9 114.19 159.9 91.33 137.05 91.33"}),p.createElement("polygon",{className:"cls-1",points:"114.19 114.19 114.19 91.33 91.33 91.33 91.33 114.19 91.33 137.05 91.33 159.9 114.19 159.9 137.05 159.9 137.05 137.05 114.19 137.05 114.19 114.19"}),p.createElement("polygon",{className:"cls-2",points:"137.05 91.33 137.05 114.19 137.05 137.05 159.9 137.05 159.9 114.19 159.9 91.33 137.05 91.33"}),p.createElement("polygon",{className:"cls-2",points:"114.19 114.19 114.19 91.33 91.33 91.33 91.33 114.19 91.33 137.05 91.33 159.9 114.19 159.9 137.05 159.9 137.05 137.05 114.19 137.05 114.19 114.19"}),p.createElement("rect",{className:"cls-3",x:137.05,y:137.05,width:22.86,height:22.86}),p.createElement("path",{className:"cls-1",d:"M251.58,139.13V112.77h11.93v25.06c0,7.36,3.91,12.2,11.27,12.2s11.27-4.84,11.27-12.2V112.77h12v26.36c0,12.67-8.48,21.8-23.1,21.8C260.06,160.93,251.58,151.8,251.58,139.13Z"}),p.createElement("path",{className:"cls-1",d:"M321.91,159.9H310.08V112.77h11.83v7.92a17.93,17.93,0,0,1,15.65-9c11.83,0,19.66,8.67,19.66,20.68V159.9h-12V134.75c0-7.45-4.38-12.39-11.46-12.39s-11.83,5-11.83,12.39Z"}),p.createElement("path",{className:"cls-1",d:"M369.42,91.34h11.92V159.9H369.42Z"}),p.createElement("path",{className:"cls-1",d:"M441.24,137v1.3H403.79c.47,7.36,5.87,13,13.69,13,7.55,0,10.62-3.82,11.46-5.12h11.74c-.75,4.84-7.17,15-23.2,15-15.27,0-25.61-10.61-25.61-24.77,0-14.63,10.24-24.78,24.68-24.78S441.24,121.62,441.24,137Zm-37.08-6.9h24.6c-1.77-6-6.15-9.31-12.21-9.31C410.12,120.78,405.65,124.23,404.16,130.09Z"}),p.createElement("path",{className:"cls-1",d:"M467.78,130.37h15.47c0-5.68-4.29-9.31-11.27-9.31-6.62,0-9,3.54-9.78,4.75h-12c1-4.94,6.89-14.25,21.8-14.25,14.62,0,22.73,7.64,22.73,18.81V146.3c0,2.89,1,4,3.72,4.29v9.59h-3.72c-6.06-.09-9.69-2.33-11-6.52-2.23,3.45-7.26,7.27-15.27,7.27-11.09,0-19.47-6.24-19.47-15.93S456.14,130.37,467.78,130.37Zm15.47,12.11v-4H469.74c-5.59,0-9,2-9,6.33,0,4.57,4.29,7.27,10.25,7.27C477.66,152.08,483.25,148.82,483.25,142.48Z"}),p.createElement("path",{className:"cls-1",d:"M523.12,140.62c-10.34-.74-17.33-5.59-17.33-14.72,0-8.85,8.1-14.44,20.77-14.44,17,0,21.8,8.76,23.1,13.32H537.09c-.84-1-3.54-4.28-10.62-4.28-5.68,0-8.66,1.86-8.66,4.75,0,2.61,2,4.29,6.7,4.94l8,.84c12.77,1.11,18,6,18,15.27,0,8.85-7.36,14.91-21.8,14.91-17.51,0-23.19-10.16-24.12-14.53h12.76c.47,1.11,3.35,5.31,11.36,5.31,6.62,0,9.69-2.24,9.69-5.22s-1.67-4.66-7-5.31C528.05,141.18,526.38,141,523.12,140.62Z"}),p.createElement("path",{className:"cls-1",d:"M571.55,159.9H559.72V91.34h11.83v29.35a17.93,17.93,0,0,1,15.65-9c11.83,0,19.66,8.67,19.66,20.68V159.9h-12V134.75c0-7.45-4.38-12.39-11.46-12.39s-11.83,5-11.83,12.39Z"}));var zx={},ene=cn;Object.defineProperty(zx,"__esModule",{value:!0});var l3=zx.default=void 0;rne(p);var tne=ene(Cn()),nne=En;function c3(e){if(typeof WeakMap!="function")return null;var t=new WeakMap,n=new WeakMap;return(c3=function(r){return r?n:t})(e)}function rne(e,t){if(!t&&e&&e.__esModule)return e;if(e===null||typeof e!="object"&&typeof e!="function")return{default:e};var n=c3(t);if(n&&n.has(e))return n.get(e);var r={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a)){var i=o?Object.getOwnPropertyDescriptor(e,a):null;i&&(i.get||i.set)?Object.defineProperty(r,a,i):r[a]=e[a]}return r.default=e,n&&n.set(e,r),r}var one=(0,tne.default)((0,nne.jsx)("path",{d:"M12 1.27a11 11 0 00-3.48 21.46c.55.09.73-.28.73-.55v-1.84c-3.03.64-3.67-1.46-3.67-1.46-.55-1.29-1.28-1.65-1.28-1.65-.92-.65.1-.65.1-.65 1.1 0 1.73 1.1 1.73 1.1.92 1.65 2.57 1.2 3.21.92a2 2 0 01.64-1.47c-2.47-.27-5.04-1.19-5.04-5.5 0-1.1.46-2.1 1.2-2.84a3.76 3.76 0 010-2.93s.91-.28 3.11 1.1c1.8-.49 3.7-.49 5.5 0 2.1-1.38 3.02-1.1 3.02-1.1a3.76 3.76 0 010 2.93c.83.74 1.2 1.74 1.2 2.94 0 4.21-2.57 5.13-5.04 5.4.45.37.82.92.82 2.02v3.03c0 .27.1.64.73.55A11 11 0 0012 1.27"}),"GitHub");l3=zx.default=one;var jx={},ane=cn;Object.defineProperty(jx,"__esModule",{value:!0});var u3=jx.default=void 0,ine=ane(Cn()),sne=En,lne=(0,ine.default)((0,sne.jsx)("path",{d:"M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9H9V9h10v2zm-4 4H9v-2h6v2zm4-8H9V5h10v2z"}),"LibraryBooks");u3=jx.default=lne;var Ux={},cne=cn;Object.defineProperty(Ux,"__esModule",{value:!0});var d3=Ux.default=void 0,une=cne(Cn()),dne=En,pne=(0,une.default)((0,dne.jsx)("path",{d:"M10.09 15.59 11.5 17l5-5-5-5-1.41 1.41L12.67 11H3v2h9.67l-2.58 2.59zM19 3H5c-1.11 0-2 .9-2 2v4h2V5h14v14H5v-4H3v4c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"}),"ExitToApp");d3=Ux.default=pne;const p3=e=>p.createElement("svg",{id:"bg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 251.43 251.03",...e},p.createElement("defs",null,p.createElement("style",null,".cls-1{fill:#1a4049;}.cls-2{fill:#fff;}.cls-3{fill:#817afe;}")),p.createElement("circle",{className:"cls-1",cx:125.71,cy:125.31,r:80}),p.createElement("polygon",{className:"cls-2",points:"137.14 91.03 137.14 113.88 137.14 136.74 160 136.74 160 113.88 160 91.03 137.14 91.03"}),p.createElement("polygon",{className:"cls-2",points:"114.29 113.88 114.29 91.03 91.43 91.03 91.43 113.88 91.43 136.74 91.43 159.6 114.29 159.6 137.14 159.6 137.14 136.74 114.29 136.74 114.29 113.88"}),p.createElement("rect",{className:"cls-3",x:137.14,y:136.74,width:22.86,height:22.86})),rIe="/static/logoBg-6e3a3ec3.svg",fne=C(ba)({minWidth:"150px",height:"100%",width:"100%",margin:"0",padding:"0"}),hne=C(ln)(({theme:e})=>({textDecoration:"none",alignItems:"center",display:"flex",color:"inherit",height:"100%",width:"100%","&&":{color:"black",padding:e.spacing(1,2)}})),mne=C("span")(({theme:e})=>({width:"12.5px",height:"12.5px",display:"block",backgroundColor:e.palette.primary.main,marginRight:"1rem",borderRadius:"2px"})),SA=({path:e,text:t,handleClose:n})=>s(fne,{onClick:()=>{n()},children:T(go,{style:{textDecoration:"none"},component:hne,to:e,underline:"hover",children:[s(mne,{}),t]})}),gne="_drawer_cxqms_1",vne="_drawerTitle_cxqms_6",yne="_drawerContainer_cxqms_13",bne="_drawerTitleLogo_cxqms_17",wne="_drawerTitleText_cxqms_22",Sne="_drawerList_cxqms_27",xne="_iconLinkList_cxqms_28",Cne="_iconLink_cxqms_28",Ene="_navigationLink_cxqms_42",Tne="_navigationLinkActive_cxqms_50",kne="_navigationIcon_cxqms_56",Ane="_iconGitHub_cxqms_61",wo={drawer:gne,drawerTitle:vne,drawerContainer:yne,drawerTitleLogo:bne,drawerTitleText:wne,drawerList:Sne,iconLinkList:xne,iconLink:Cne,navigationLink:Ene,navigationLinkActive:Tne,navigationIcon:kne,iconGitHub:Ane},_ne=({links:e=[],title:t="Unleash",flags:n={},open:r=!1,toggleDrawer:o,admin:a=!1,routes:i})=>{const l=()=>e.map(c=>{let u=null;return c.value==="GitHub"?u=s(l3,{className:wo.navigationIcon}):c.value==="Documentation"&&(u=s(u3,{className:wo.navigationIcon})),T("a",{href:c.href,rel:"noopener noreferrer",target:"_blank",className:wo.iconLink,children:[u,c.value]},c.value)});return s(jG,{className:wo.drawer,open:r,anchor:"left",onClose:o,children:T("nav",{id:"header-drawer",className:wo.drawerContainer,children:[s("div",{children:T(ln,{to:"/",className:wo.drawerTitle,"aria-label":"Home",onClick:()=>o(),children:[s(p3,{className:wo.drawerTitleLogo,"aria-label":"Unleash logo"}),s("span",{className:wo.drawerTitleText,children:t})]})}),s(mo,{}),s(xa,{className:wo.drawerList,children:i.mobileRoutes.map(c=>s(SA,{handleClose:()=>o(),path:c.path,text:c.title},c.path))}),s(X,{condition:a,show:T(ke,{children:[s(mo,{}),s(xa,{className:wo.drawerList,children:i.adminRoutes.map(c=>s(SA,{handleClose:()=>o(),path:c.path,text:c.title},c.path))})]})}),s(mo,{}),T("div",{className:wo.iconLinkList,children:[l(),T("a",{className:wo.iconLink,href:`${Oi}/logout`,children:[s(d3,{className:wo.navigationIcon}),"Sign out"]})]})]})})},Fo="ADMIN",wp="CREATE_FEATURE",f3="UPDATE_FEATURE",Rne="DELETE_FEATURE",Rm="CREATE_STRATEGY",mv="UPDATE_STRATEGY",Pne="DELETE_STRATEGY",xA="UPDATE_APPLICATION",Pm="CREATE_CONTEXT_FIELD",h3="UPDATE_CONTEXT_FIELD",Ine="DELETE_CONTEXT_FIELD",CA="CREATE_PROJECT",Bb="UPDATE_PROJECT",$ne="DELETE_PROJECT",One="DELETE_TAG_TYPE",Sp="UPDATE_TAG_TYPE",m3="CREATE_ADDON",Fb="UPDATE_ADDON",Lne="DELETE_ADDON",oIe="CREATE_API_TOKEN",aIe="DELETE_API_TOKEN",iIe="READ_API_TOKEN",Nne="DELETE_ENVIRONMENT",zb="UPDATE_ENVIRONMENT",g3="CREATE_FEATURE_STRATEGY",Wx="UPDATE_FEATURE_STRATEGY",Mne="DELETE_FEATURE_STRATEGY",Dne="UPDATE_FEATURE_ENVIRONMENT",Bne="UPDATE_FEATURE_ENVIRONMENT_VARIANTS",sIe="MOVE_FEATURE_TOGGLE",gv="CREATE_SEGMENT",Hx="UPDATE_SEGMENT",Fne="DELETE_SEGMENT",lIe="APPLY_CHANGE_REQUEST",cIe="APPROVE_CHANGE_REQUEST",uIe="READ_PROJECT_API_TOKEN",dIe="CREATE_PROJECT_API_TOKEN",zne=C(ln)(({theme:e})=>({textDecoration:"none",alignItems:"center",display:"flex",color:"inherit",height:"100%",width:"100%","&&":{padding:e.spacing(1,2)}})),jne=C("span")(({theme:e})=>({width:"12.5px",height:"12.5px",display:"block",backgroundColor:e.palette.primary.main,marginRight:e.spacing(2),borderRadius:"2px"})),EA=({options:e,id:t,handleClose:n,anchorEl:r,style:o})=>s(px,{id:t,onClose:n,anchorEl:r,open:Boolean(r),style:o,children:e.map(a=>T(bs,{component:zne,to:a.path,onClick:n,children:[s(jne,{}),a.title]},a.path))});var Kt={},Une={get exports(){return Kt},set exports(e){Kt=e}},Im={},Wne={get exports(){return Im},set exports(e){Im=e}};(function(e,t){(function(n,r){r(t,p)})(Fa,function(n,r){function o(S,N,B,j,J,G,Q){try{var le=S[G](Q),de=le.value}catch(fe){return void B(fe)}le.done?N(de):Promise.resolve(de).then(j,J)}function a(S){return function(){var N=this,B=arguments;return new Promise(function(j,J){var G=S.apply(N,B);function Q(de){o(G,j,J,Q,le,"next",de)}function le(de){o(G,j,J,Q,le,"throw",de)}Q(void 0)})}}function i(){return(i=Object.assign||function(S){for(var N=1;N<arguments.length;N++){var B=arguments[N];for(var j in B)Object.prototype.hasOwnProperty.call(B,j)&&(S[j]=B[j])}return S}).apply(this,arguments)}function l(S,N){if(S==null)return{};var B,j,J={},G=Object.keys(S);for(j=0;j<G.length;j++)B=G[j],N.indexOf(B)>=0||(J[B]=S[B]);return J}function c(S){var N=function(B,j){if(typeof B!="object"||B===null)return B;var J=B[Symbol.toPrimitive];if(J!==void 0){var G=J.call(B,j||"default");if(typeof G!="object")return G;throw new TypeError("@@toPrimitive must return a primitive value.")}return(j==="string"?String:Number)(B)}(S,"string");return typeof N=="symbol"?N:String(N)}r=r&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r;var u={init:"init"},d=function(S){var N=S.value;return N===void 0?"":N},f=function(){return r.createElement(r.Fragment,null," ")},h={Cell:d,width:150,minWidth:0,maxWidth:Number.MAX_SAFE_INTEGER};function m(){for(var S=arguments.length,N=new Array(S),B=0;B<S;B++)N[B]=arguments[B];return N.reduce(function(j,J){var G=J.style,Q=J.className;return j=i({},j,{},l(J,["style","className"])),G&&(j.style=j.style?i({},j.style||{},{},G||{}):G),Q&&(j.className=j.className?j.className+" "+Q:Q),j.className===""&&delete j.className,j},{})}var y=function(S,N){return N===void 0&&(N={}),function(B){return B===void 0&&(B={}),[].concat(S,[B]).reduce(function(j,J){return function G(Q,le,de){return typeof le=="function"?G({},le(Q,de)):Array.isArray(le)?m.apply(void 0,[Q].concat(le)):m(Q,le)}(j,J,i({},N,{userProps:B}))},{})}},g=function(S,N,B,j){return B===void 0&&(B={}),S.reduce(function(J,G){return G(J,B)},N)},v=function(S,N,B){return B===void 0&&(B={}),S.forEach(function(j){j(N,B)})};function b(S,N,B,j){S.findIndex(function(J){return J.pluginName===B}),N.forEach(function(J){S.findIndex(function(G){return G.pluginName===J})})}function w(S,N){return typeof S=="function"?S(N):S}function x(S){var N=r.useRef();return N.current=S,r.useCallback(function(){return N.current},[])}var E=typeof document<"u"?r.useLayoutEffect:r.useEffect;function A(S,N){var B=r.useRef(!1);E(function(){B.current&&S(),B.current=!0},N)}function k(S,N,B){return B===void 0&&(B={}),function(j,J){J===void 0&&(J={});var G=typeof j=="string"?N[j]:j;if(G===void 0)throw console.info(N),new Error("Renderer Error ☝️");return _(G,i({},S,{column:N},B,{},J))}}function _(S,N){return function(j){return typeof j=="function"&&(J=Object.getPrototypeOf(j)).prototype&&J.prototype.isReactComponent;var J}(B=S)||typeof B=="function"||function(j){return typeof j=="object"&&typeof j.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(j.$$typeof.description)}(B)?r.createElement(S,N):S;var B}function $(S,N,B){return B===void 0&&(B=0),S.map(function(j){return O(j=i({},j,{parent:N,depth:B})),j.columns&&(j.columns=$(j.columns,j,B+1)),j})}function L(S){return V(S,"columns")}function O(S){var N=S.id,B=S.accessor,j=S.Header;if(typeof B=="string"){N=N||B;var J=B.split(".");B=function(G){return function(Q,le,de){if(!le)return Q;var fe,Le=typeof le=="function"?le:JSON.stringify(le),Re=F.get(Le)||function(){var Pe=function(we){return function Ie(ze,We){if(We===void 0&&(We=[]),Array.isArray(ze))for(var it=0;it<ze.length;it+=1)Ie(ze[it],We);else We.push(ze);return We}(we).map(function(Ie){return String(Ie).replace(".","_")}).join(".").replace(M,".").replace(ee,"").split(".")}(le);return F.set(Le,Pe),Pe}();try{fe=Re.reduce(function(Pe,we){return Pe[we]},Q)}catch{}return fe!==void 0?fe:de}(G,J)}}if(!N&&typeof j=="string"&&j&&(N=j),!N&&S.columns)throw console.error(S),new Error('A column ID (or unique "Header" value) is required!');if(!N)throw console.error(S),new Error("A column ID (or string accessor) is required!");return Object.assign(S,{id:N,accessor:B}),S}function P(S,N){if(!N)throw new Error;return Object.assign(S,i({Header:f,Footer:f},h,{},N,{},S)),Object.assign(S,{originalWidth:S.width}),S}function D(S,N,B){B===void 0&&(B=function(){return{}});for(var j=[],J=S,G=0,Q=function(){return G++},le=function(){var de={headers:[]},fe=[],Le=J.some(function(Re){return Re.parent});J.forEach(function(Re){var Pe,we=[].concat(fe).reverse()[0];Le&&(Re.parent?Pe=i({},Re.parent,{originalId:Re.parent.id,id:Re.parent.id+"_"+Q(),headers:[Re]},B(Re)):Pe=P(i({originalId:Re.id+"_placeholder",id:Re.id+"_placeholder_"+Q(),placeholderOf:Re,headers:[Re]},B(Re)),N),we&&we.originalId===Pe.originalId?we.headers.push(Re):fe.push(Pe)),de.headers.push(Re)}),j.push(de),J=fe};J.length;)le();return j.reverse()}var F=new Map;function U(){for(var S=arguments.length,N=new Array(S),B=0;B<S;B++)N[B]=arguments[B];for(var j=0;j<N.length;j+=1)if(N[j]!==void 0)return N[j]}function Y(S){if(typeof S=="function")return S}function V(S,N){var B=[];return function j(J){J.forEach(function(G){G[N]?j(G[N]):B.push(G)})}(S),B}function te(S,N){var B=N.manualExpandedKey,j=N.expanded,J=N.expandSubRows,G=J===void 0||J,Q=[];return S.forEach(function(le){return function de(fe,Le){Le===void 0&&(Le=!0),fe.isExpanded=fe.original&&fe.original[B]||j[fe.id],fe.canExpand=fe.subRows&&!!fe.subRows.length,Le&&Q.push(fe),fe.subRows&&fe.subRows.length&&fe.isExpanded&&fe.subRows.forEach(function(Re){return de(Re,G)})}(le)}),Q}function Z(S,N,B){return Y(S)||N[S]||B[S]||B.text}function W(S,N,B){return S?S(N,B):N===void 0}function z(){throw new Error("React-Table: You have not called prepareRow(row) one or more rows you are attempting to render.")}var R=null,M=/\[/g,ee=/\]/g,re=function(S){return i({role:"table"},S)},Se=function(S){return i({role:"rowgroup"},S)},ce=function(S,N){var B=N.column;return i({key:"header_"+B.id,colSpan:B.totalVisibleHeaderCount,role:"columnheader"},S)},Ce=function(S,N){var B=N.column;return i({key:"footer_"+B.id,colSpan:B.totalVisibleHeaderCount},S)},xe=function(S,N){return i({key:"headerGroup_"+N.index,role:"row"},S)},Ee=function(S,N){return i({key:"footerGroup_"+N.index},S)},tt=function(S,N){return i({key:"row_"+N.row.id,role:"row"},S)},me=function(S,N){var B=N.cell;return i({key:"cell_"+B.row.id+"_"+B.column.id,role:"cell"},S)};function Ge(){return{useOptions:[],stateReducers:[],useControlledState:[],columns:[],columnsDeps:[],allColumns:[],allColumnsDeps:[],accessValue:[],materializedColumns:[],materializedColumnsDeps:[],useInstanceAfterData:[],visibleColumns:[],visibleColumnsDeps:[],headerGroups:[],headerGroupsDeps:[],useInstanceBeforeDimensions:[],useInstance:[],prepareRow:[],getTableProps:[re],getTableBodyProps:[Se],getHeaderGroupProps:[xe],getFooterGroupProps:[Ee],getHeaderProps:[ce],getFooterProps:[Ce],getRowProps:[tt],getCellProps:[me],useFinalInstance:[]}}u.resetHiddenColumns="resetHiddenColumns",u.toggleHideColumn="toggleHideColumn",u.setHiddenColumns="setHiddenColumns",u.toggleHideAllColumns="toggleHideAllColumns";var qe=function(S){S.getToggleHiddenProps=[Be],S.getToggleHideAllColumnsProps=[he],S.stateReducers.push(Et),S.useInstanceBeforeDimensions.push(Ke),S.headerGroupsDeps.push(function(N,B){var j=B.instance;return[].concat(N,[j.state.hiddenColumns])}),S.useInstance.push(ct)};qe.pluginName="useColumnVisibility";var Be=function(S,N){var B=N.column;return[S,{onChange:function(j){B.toggleHidden(!j.target.checked)},style:{cursor:"pointer"},checked:B.isVisible,title:"Toggle Column Visible"}]},he=function(S,N){var B=N.instance;return[S,{onChange:function(j){B.toggleHideAllColumns(!j.target.checked)},style:{cursor:"pointer"},checked:!B.allColumnsHidden&&!B.state.hiddenColumns.length,title:"Toggle All Columns Hidden",indeterminate:!B.allColumnsHidden&&B.state.hiddenColumns.length}]};function Et(S,N,B,j){if(N.type===u.init)return i({hiddenColumns:[]},S);if(N.type===u.resetHiddenColumns)return i({},S,{hiddenColumns:j.initialState.hiddenColumns||[]});if(N.type===u.toggleHideColumn){var J=(N.value!==void 0?N.value:!S.hiddenColumns.includes(N.columnId))?[].concat(S.hiddenColumns,[N.columnId]):S.hiddenColumns.filter(function(G){return G!==N.columnId});return i({},S,{hiddenColumns:J})}return N.type===u.setHiddenColumns?i({},S,{hiddenColumns:w(N.value,S.hiddenColumns)}):N.type===u.toggleHideAllColumns?i({},S,{hiddenColumns:(N.value!==void 0?N.value:!S.hiddenColumns.length)?j.allColumns.map(function(G){return G.id}):[]}):void 0}function Ke(S){var N=S.headers,B=S.state.hiddenColumns;r.useRef(!1).current;var j=0;N.forEach(function(J){return j+=function G(Q,le){Q.isVisible=le&&!B.includes(Q.id);var de=0;return Q.headers&&Q.headers.length?Q.headers.forEach(function(fe){return de+=G(fe,Q.isVisible)}):de=Q.isVisible?1:0,Q.totalVisibleHeaderCount=de,de}(J,!0)})}function ct(S){var N=S.columns,B=S.flatHeaders,j=S.dispatch,J=S.allColumns,G=S.getHooks,Q=S.state.hiddenColumns,le=S.autoResetHiddenColumns,de=le===void 0||le,fe=x(S),Le=J.length===Q.length,Re=r.useCallback(function(We,it){return j({type:u.toggleHideColumn,columnId:We,value:it})},[j]),Pe=r.useCallback(function(We){return j({type:u.setHiddenColumns,value:We})},[j]),we=r.useCallback(function(We){return j({type:u.toggleHideAllColumns,value:We})},[j]),Ie=y(G().getToggleHideAllColumnsProps,{instance:fe()});B.forEach(function(We){We.toggleHidden=function(it){j({type:u.toggleHideColumn,columnId:We.id,value:it})},We.getToggleHiddenProps=y(G().getToggleHiddenProps,{instance:fe(),column:We})});var ze=x(de);A(function(){ze()&&j({type:u.resetHiddenColumns})},[j,N]),Object.assign(S,{allColumnsHidden:Le,toggleHideColumn:Re,setHiddenColumns:Pe,toggleHideAllColumns:we,getToggleHideAllColumnsProps:Ie})}var Rt={},dt={},rt=function(S,N,B){return S},Nt=function(S,N){return S.subRows||[]},xt=function(S,N,B){return""+(B?[B.id,N].join("."):N)},pe=function(S){return S};function Te(S){var N=S.initialState,B=N===void 0?Rt:N,j=S.defaultColumn,J=j===void 0?dt:j,G=S.getSubRows,Q=G===void 0?Nt:G,le=S.getRowId,de=le===void 0?xt:le,fe=S.stateReducer,Le=fe===void 0?rt:fe,Re=S.useControlledState,Pe=Re===void 0?pe:Re;return i({},l(S,["initialState","defaultColumn","getSubRows","getRowId","stateReducer","useControlledState"]),{initialState:B,defaultColumn:J,getSubRows:Q,getRowId:de,stateReducer:Le,useControlledState:Pe})}function Xe(S,N){N===void 0&&(N=0);var B=0,j=0,J=0,G=0;return S.forEach(function(Q){var le=Q.headers;if(Q.totalLeft=N,le&&le.length){var de=Xe(le,N),fe=de[0],Le=de[1],Re=de[2],Pe=de[3];Q.totalMinWidth=fe,Q.totalWidth=Le,Q.totalMaxWidth=Re,Q.totalFlexWidth=Pe}else Q.totalMinWidth=Q.minWidth,Q.totalWidth=Math.min(Math.max(Q.minWidth,Q.width),Q.maxWidth),Q.totalMaxWidth=Q.maxWidth,Q.totalFlexWidth=Q.canResize?Q.totalWidth:0;Q.isVisible&&(N+=Q.totalWidth,B+=Q.totalMinWidth,j+=Q.totalWidth,J+=Q.totalMaxWidth,G+=Q.totalFlexWidth)}),[B,j,J,G]}function De(S){var N=S.data,B=S.rows,j=S.flatRows,J=S.rowsById,G=S.column,Q=S.getRowId,le=S.getSubRows,de=S.accessValueHooks,fe=S.getInstance;N.forEach(function(Le,Re){return function Pe(we,Ie,ze,We,it){ze===void 0&&(ze=0);var $t=we,at=Q(we,Ie,We),Ne=J[at];if(Ne)Ne.subRows&&Ne.originalSubRows.forEach(function(Je,wt){return Pe(Je,wt,ze+1,Ne)});else if((Ne={id:at,original:$t,index:Ie,depth:ze,cells:[{}]}).cells.map=z,Ne.cells.filter=z,Ne.cells.forEach=z,Ne.cells[0].getCellProps=z,Ne.values={},it.push(Ne),j.push(Ne),J[at]=Ne,Ne.originalSubRows=le(we,Ie),Ne.originalSubRows){var Ct=[];Ne.originalSubRows.forEach(function(Je,wt){return Pe(Je,wt,ze+1,Ne,Ct)}),Ne.subRows=Ct}G.accessor&&(Ne.values[G.id]=G.accessor(we,Ie,Ne,it,N)),Ne.values[G.id]=g(de,Ne.values[G.id],{row:Ne,column:G,instance:fe()})}(Le,Re,0,void 0,B)})}u.resetExpanded="resetExpanded",u.toggleRowExpanded="toggleRowExpanded",u.toggleAllRowsExpanded="toggleAllRowsExpanded";var q=function(S){S.getToggleAllRowsExpandedProps=[K],S.getToggleRowExpandedProps=[se],S.stateReducers.push(be),S.useInstance.push(Ae),S.prepareRow.push(mt)};q.pluginName="useExpanded";var K=function(S,N){var B=N.instance;return[S,{onClick:function(j){B.toggleAllRowsExpanded()},style:{cursor:"pointer"},title:"Toggle All Rows Expanded"}]},se=function(S,N){var B=N.row;return[S,{onClick:function(){B.toggleRowExpanded()},style:{cursor:"pointer"},title:"Toggle Row Expanded"}]};function be(S,N,B,j){if(N.type===u.init)return i({expanded:{}},S);if(N.type===u.resetExpanded)return i({},S,{expanded:j.initialState.expanded||{}});if(N.type===u.toggleAllRowsExpanded){var J=N.value,G=j.rowsById,Q=Object.keys(G).length===Object.keys(S.expanded).length;if(J!==void 0?J:!Q){var le={};return Object.keys(G).forEach(function(Ie){le[Ie]=!0}),i({},S,{expanded:le})}return i({},S,{expanded:{}})}if(N.type===u.toggleRowExpanded){var de,fe=N.id,Le=N.value,Re=S.expanded[fe],Pe=Le!==void 0?Le:!Re;if(!Re&&Pe)return i({},S,{expanded:i({},S.expanded,(de={},de[fe]=!0,de))});if(Re&&!Pe){var we=S.expanded;return we[fe],i({},S,{expanded:l(we,[fe].map(c))})}return S}}function Ae(S){var N=S.data,B=S.rows,j=S.rowsById,J=S.manualExpandedKey,G=J===void 0?"expanded":J,Q=S.paginateExpandedRows,le=Q===void 0||Q,de=S.expandSubRows,fe=de===void 0||de,Le=S.autoResetExpanded,Re=Le===void 0||Le,Pe=S.getHooks,we=S.plugins,Ie=S.state.expanded,ze=S.dispatch;b(we,["useSortBy","useGroupBy","usePivotColumns","useGlobalFilter"],"useExpanded");var We=x(Re),it=Boolean(Object.keys(j).length&&Object.keys(Ie).length);it&&Object.keys(j).some(function(zt){return!Ie[zt]})&&(it=!1),A(function(){We()&&ze({type:u.resetExpanded})},[ze,N]);var $t=r.useCallback(function(zt,gt){ze({type:u.toggleRowExpanded,id:zt,value:gt})},[ze]),at=r.useCallback(function(zt){return ze({type:u.toggleAllRowsExpanded,value:zt})},[ze]),Ne=r.useMemo(function(){return le?te(B,{manualExpandedKey:G,expanded:Ie,expandSubRows:fe}):B},[le,B,G,Ie,fe]),Ct=r.useMemo(function(){return function(zt){var gt=0;return Object.keys(zt).forEach(function(bt){var Jt=bt.split(".");gt=Math.max(gt,Jt.length)}),gt}(Ie)},[Ie]),Je=x(S),wt=y(Pe().getToggleAllRowsExpandedProps,{instance:Je()});Object.assign(S,{preExpandedRows:B,expandedRows:Ne,rows:Ne,expandedDepth:Ct,isAllRowsExpanded:it,toggleRowExpanded:$t,toggleAllRowsExpanded:at,getToggleAllRowsExpandedProps:wt})}function mt(S,N){var B=N.instance.getHooks,j=N.instance;S.toggleRowExpanded=function(J){return j.toggleRowExpanded(S.id,J)},S.getToggleRowExpandedProps=y(B().getToggleRowExpandedProps,{instance:j,row:S})}var et=function(S,N,B){return S=S.filter(function(j){return N.some(function(J){var G=j.values[J];return String(G).toLowerCase().includes(String(B).toLowerCase())})})};et.autoRemove=function(S){return!S};var ht=function(S,N,B){return S.filter(function(j){return N.some(function(J){var G=j.values[J];return G===void 0||String(G).toLowerCase()===String(B).toLowerCase()})})};ht.autoRemove=function(S){return!S};var Xt=function(S,N,B){return S.filter(function(j){return N.some(function(J){var G=j.values[J];return G===void 0||String(G)===String(B)})})};Xt.autoRemove=function(S){return!S};var Mn=function(S,N,B){return S.filter(function(j){return N.some(function(J){return j.values[J].includes(B)})})};Mn.autoRemove=function(S){return!S||!S.length};var pt=function(S,N,B){return S.filter(function(j){return N.some(function(J){var G=j.values[J];return G&&G.length&&B.every(function(Q){return G.includes(Q)})})})};pt.autoRemove=function(S){return!S||!S.length};var pn=function(S,N,B){return S.filter(function(j){return N.some(function(J){var G=j.values[J];return G&&G.length&&B.some(function(Q){return G.includes(Q)})})})};pn.autoRemove=function(S){return!S||!S.length};var Vt=function(S,N,B){return S.filter(function(j){return N.some(function(J){var G=j.values[J];return B.includes(G)})})};Vt.autoRemove=function(S){return!S||!S.length};var en=function(S,N,B){return S.filter(function(j){return N.some(function(J){return j.values[J]===B})})};en.autoRemove=function(S){return S===void 0};var Ft=function(S,N,B){return S.filter(function(j){return N.some(function(J){return j.values[J]==B})})};Ft.autoRemove=function(S){return S==null};var Hn=function(S,N,B){var j=B||[],J=j[0],G=j[1];if((J=typeof J=="number"?J:-1/0)>(G=typeof G=="number"?G:1/0)){var Q=J;J=G,G=Q}return S.filter(function(le){return N.some(function(de){var fe=le.values[de];return fe>=J&&fe<=G})})};Hn.autoRemove=function(S){return!S||typeof S[0]!="number"&&typeof S[1]!="number"};var br=Object.freeze({__proto__:null,text:et,exactText:ht,exactTextCase:Xt,includes:Mn,includesAll:pt,includesSome:pn,includesValue:Vt,exact:en,equals:Ft,between:Hn});u.resetFilters="resetFilters",u.setFilter="setFilter",u.setAllFilters="setAllFilters";var ro=function(S){S.stateReducers.push(yo),S.useInstance.push(bo)};function yo(S,N,B,j){if(N.type===u.init)return i({filters:[]},S);if(N.type===u.resetFilters)return i({},S,{filters:j.initialState.filters||[]});if(N.type===u.setFilter){var J=N.columnId,G=N.filterValue,Q=j.allColumns,le=j.filterTypes,de=Q.find(function(ze){return ze.id===J});if(!de)throw new Error("React-Table: Could not find a column with id: "+J);var fe=Z(de.filter,le||{},br),Le=S.filters.find(function(ze){return ze.id===J}),Re=w(G,Le&&Le.value);return W(fe.autoRemove,Re,de)?i({},S,{filters:S.filters.filter(function(ze){return ze.id!==J})}):i({},S,Le?{filters:S.filters.map(function(ze){return ze.id===J?{id:J,value:Re}:ze})}:{filters:[].concat(S.filters,[{id:J,value:Re}])})}if(N.type===u.setAllFilters){var Pe=N.filters,we=j.allColumns,Ie=j.filterTypes;return i({},S,{filters:w(Pe,S.filters).filter(function(ze){var We=we.find(function(it){return it.id===ze.id});return!W(Z(We.filter,Ie||{},br).autoRemove,ze.value,We)})})}}function bo(S){var N=S.data,B=S.rows,j=S.flatRows,J=S.rowsById,G=S.allColumns,Q=S.filterTypes,le=S.manualFilters,de=S.defaultCanFilter,fe=de!==void 0&&de,Le=S.disableFilters,Re=S.state.filters,Pe=S.dispatch,we=S.autoResetFilters,Ie=we===void 0||we,ze=r.useCallback(function(Je,wt){Pe({type:u.setFilter,columnId:Je,filterValue:wt})},[Pe]),We=r.useCallback(function(Je){Pe({type:u.setAllFilters,filters:Je})},[Pe]);G.forEach(function(Je){var wt=Je.id,zt=Je.accessor,gt=Je.defaultCanFilter,bt=Je.disableFilters;Je.canFilter=zt?U(bt!==!0&&void 0,Le!==!0&&void 0,!0):U(gt,fe,!1),Je.setFilter=function(St){return ze(Je.id,St)};var Jt=Re.find(function(St){return St.id===wt});Je.filterValue=Jt&&Jt.value});var it=r.useMemo(function(){if(le||!Re.length)return[B,j,J];var Je=[],wt={};return[function zt(gt,bt){bt===void 0&&(bt=0);var Jt=gt;return(Jt=Re.reduce(function(St,qt){var Ht=qt.id,bn=qt.value,st=G.find(function(Vn){return Vn.id===Ht});if(!st)return St;bt===0&&(st.preFilteredRows=St);var Ut=Z(st.filter,Q||{},br);return Ut?(st.filteredRows=Ut(St,[Ht],bn),st.filteredRows):(console.warn("Could not find a valid 'column.filter' for column with the ID: "+st.id+"."),St)},gt)).forEach(function(St){Je.push(St),wt[St.id]=St,St.subRows&&(St.subRows=St.subRows&&St.subRows.length>0?zt(St.subRows,bt+1):St.subRows)}),Jt}(B),Je,wt]},[le,Re,B,j,J,G,Q]),$t=it[0],at=it[1],Ne=it[2];r.useMemo(function(){G.filter(function(Je){return!Re.find(function(wt){return wt.id===Je.id})}).forEach(function(Je){Je.preFilteredRows=$t,Je.filteredRows=$t})},[$t,Re,G]);var Ct=x(Ie);A(function(){Ct()&&Pe({type:u.resetFilters})},[Pe,le?null:N]),Object.assign(S,{preFilteredRows:B,preFilteredFlatRows:j,preFilteredRowsById:J,filteredRows:$t,filteredFlatRows:at,filteredRowsById:Ne,rows:$t,flatRows:at,rowsById:Ne,setFilter:ze,setAllFilters:We})}ro.pluginName="useFilters",u.resetGlobalFilter="resetGlobalFilter",u.setGlobalFilter="setGlobalFilter";var Rr=function(S){S.stateReducers.push(oo),S.useInstance.push(Jn)};function oo(S,N,B,j){if(N.type===u.resetGlobalFilter)return i({},S,{globalFilter:j.initialState.globalFilter||void 0});if(N.type===u.setGlobalFilter){var J=N.filterValue,G=j.userFilterTypes,Q=Z(j.globalFilter,G||{},br),le=w(J,S.globalFilter);return W(Q.autoRemove,le)?(S.globalFilter,l(S,["globalFilter"])):i({},S,{globalFilter:le})}}function Jn(S){var N=S.data,B=S.rows,j=S.flatRows,J=S.rowsById,G=S.allColumns,Q=S.filterTypes,le=S.globalFilter,de=S.manualGlobalFilter,fe=S.state.globalFilter,Le=S.dispatch,Re=S.autoResetGlobalFilter,Pe=Re===void 0||Re,we=S.disableGlobalFilter,Ie=r.useCallback(function(Ne){Le({type:u.setGlobalFilter,filterValue:Ne})},[Le]),ze=r.useMemo(function(){if(de||fe===void 0)return[B,j,J];var Ne=[],Ct={},Je=Z(le,Q||{},br);if(!Je)return console.warn("Could not find a valid 'globalFilter' option."),B;G.forEach(function(zt){var gt=zt.disableGlobalFilter;zt.canFilter=U(gt!==!0&&void 0,we!==!0&&void 0,!0)});var wt=G.filter(function(zt){return zt.canFilter===!0});return[function zt(gt){return(gt=Je(gt,wt.map(function(bt){return bt.id}),fe)).forEach(function(bt){Ne.push(bt),Ct[bt.id]=bt,bt.subRows=bt.subRows&&bt.subRows.length?zt(bt.subRows):bt.subRows}),gt}(B),Ne,Ct]},[de,fe,le,Q,G,B,j,J,we]),We=ze[0],it=ze[1],$t=ze[2],at=x(Pe);A(function(){at()&&Le({type:u.resetGlobalFilter})},[Le,de?null:N]),Object.assign(S,{preGlobalFilteredRows:B,preGlobalFilteredFlatRows:j,preGlobalFilteredRowsById:J,globalFilteredRows:We,globalFilteredFlatRows:it,globalFilteredRowsById:$t,rows:We,flatRows:it,rowsById:$t,setGlobalFilter:Ie,disableGlobalFilter:we})}function ao(S,N){return N.reduce(function(B,j){return B+(typeof j=="number"?j:0)},0)}Rr.pluginName="useGlobalFilter";var wr=Object.freeze({__proto__:null,sum:ao,min:function(S){var N=S[0]||0;return S.forEach(function(B){typeof B=="number"&&(N=Math.min(N,B))}),N},max:function(S){var N=S[0]||0;return S.forEach(function(B){typeof B=="number"&&(N=Math.max(N,B))}),N},minMax:function(S){var N=S[0]||0,B=S[0]||0;return S.forEach(function(j){typeof j=="number"&&(N=Math.min(N,j),B=Math.max(B,j))}),N+".."+B},average:function(S){return ao(0,S)/S.length},median:function(S){if(!S.length)return null;var N=Math.floor(S.length/2),B=[].concat(S).sort(function(j,J){return j-J});return S.length%2!=0?B[N]:(B[N-1]+B[N])/2},unique:function(S){return Array.from(new Set(S).values())},uniqueCount:function(S){return new Set(S).size},count:function(S){return S.length}}),Bt=[],Gt={};u.resetGroupBy="resetGroupBy",u.setGroupBy="setGroupBy",u.toggleGroupBy="toggleGroupBy";var jn=function(S){S.getGroupByToggleProps=[hr],S.stateReducers.push(Kr),S.visibleColumnsDeps.push(function(N,B){var j=B.instance;return[].concat(N,[j.state.groupBy])}),S.visibleColumns.push(Yr),S.useInstance.push(ue),S.prepareRow.push(ae)};jn.pluginName="useGroupBy";var hr=function(S,N){var B=N.header;return[S,{onClick:B.canGroupBy?function(j){j.persist(),B.toggleGroupBy()}:void 0,style:{cursor:B.canGroupBy?"pointer":void 0},title:"Toggle GroupBy"}]};function Kr(S,N,B,j){if(N.type===u.init)return i({groupBy:[]},S);if(N.type===u.resetGroupBy)return i({},S,{groupBy:j.initialState.groupBy||[]});if(N.type===u.setGroupBy)return i({},S,{groupBy:N.value});if(N.type===u.toggleGroupBy){var J=N.columnId,G=N.value,Q=G!==void 0?G:!S.groupBy.includes(J);return i({},S,Q?{groupBy:[].concat(S.groupBy,[J])}:{groupBy:S.groupBy.filter(function(le){return le!==J})})}}function Yr(S,N){var B=N.instance.state.groupBy,j=B.map(function(G){return S.find(function(Q){return Q.id===G})}).filter(Boolean),J=S.filter(function(G){return!B.includes(G.id)});return(S=[].concat(j,J)).forEach(function(G){G.isGrouped=B.includes(G.id),G.groupedIndex=B.indexOf(G.id)}),S}var pa={};function ue(S){var N=S.data,B=S.rows,j=S.flatRows,J=S.rowsById,G=S.allColumns,Q=S.flatHeaders,le=S.groupByFn,de=le===void 0?Fe:le,fe=S.manualGroupBy,Le=S.aggregations,Re=Le===void 0?pa:Le,Pe=S.plugins,we=S.state.groupBy,Ie=S.dispatch,ze=S.autoResetGroupBy,We=ze===void 0||ze,it=S.disableGroupBy,$t=S.defaultCanGroupBy,at=S.getHooks;b(Pe,["useColumnOrder","useFilters"],"useGroupBy");var Ne=x(S);G.forEach(function(st){var Ut=st.accessor,Vn=st.defaultGroupBy,Xr=st.disableGroupBy;st.canGroupBy=Ut?U(st.canGroupBy,Xr!==!0&&void 0,it!==!0&&void 0,!0):U(st.canGroupBy,Vn,$t,!1),st.canGroupBy&&(st.toggleGroupBy=function(){return S.toggleGroupBy(st.id)}),st.Aggregated=st.Aggregated||st.Cell});var Ct=r.useCallback(function(st,Ut){Ie({type:u.toggleGroupBy,columnId:st,value:Ut})},[Ie]),Je=r.useCallback(function(st){Ie({type:u.setGroupBy,value:st})},[Ie]);Q.forEach(function(st){st.getGroupByToggleProps=y(at().getGroupByToggleProps,{instance:Ne(),header:st})});var wt=r.useMemo(function(){if(fe||!we.length)return[B,j,J,Bt,Gt,j,J];var st=we.filter(function(Sr){return G.find(function(Fi){return Fi.id===Sr})}),Ut=[],Vn={},Xr=[],vt={},Dn=[],tr={},Jr=function Sr(Fi,ui,$2){if(ui===void 0&&(ui=0),ui===st.length)return Fi.map(function(wf){return i({},wf,{depth:ui})});var Ry=st[ui],XN=de(Fi,Ry);return Object.entries(XN).map(function(wf,JN){var O2=wf[0],Sf=wf[1],xf=Ry+":"+O2,L2=Sr(Sf,ui+1,xf=$2?$2+">"+xf:xf),N2=ui?V(Sf,"leafRows"):Sf,QN=function(Uo,Py,eM){var Cf={};return G.forEach(function(nr){if(st.includes(nr.id))Cf[nr.id]=Py[0]?Py[0].values[nr.id]:null;else{var M2=typeof nr.aggregate=="function"?nr.aggregate:Re[nr.aggregate]||wr[nr.aggregate];if(M2){var tM=Py.map(function(Ef){return Ef.values[nr.id]}),nM=Uo.map(function(Ef){var Iy=Ef.values[nr.id];if(!eM&&nr.aggregateValue){var D2=typeof nr.aggregateValue=="function"?nr.aggregateValue:Re[nr.aggregateValue]||wr[nr.aggregateValue];if(!D2)throw console.info({column:nr}),new Error("React Table: Invalid column.aggregateValue option for column listed above");Iy=D2(Iy,Ef,nr)}return Iy});Cf[nr.id]=M2(nM,tM)}else{if(nr.aggregate)throw console.info({column:nr}),new Error("React Table: Invalid column.aggregate option for column listed above");Cf[nr.id]=null}}}),Cf}(N2,Sf,ui),ZN={id:xf,isGrouped:!0,groupByID:Ry,groupByVal:O2,values:QN,subRows:L2,leafRows:N2,depth:ui,index:JN};return L2.forEach(function(Uo){Ut.push(Uo),Vn[Uo.id]=Uo,Uo.isGrouped?(Xr.push(Uo),vt[Uo.id]=Uo):(Dn.push(Uo),tr[Uo.id]=Uo)}),ZN})}(B);return Jr.forEach(function(Sr){Ut.push(Sr),Vn[Sr.id]=Sr,Sr.isGrouped?(Xr.push(Sr),vt[Sr.id]=Sr):(Dn.push(Sr),tr[Sr.id]=Sr)}),[Jr,Ut,Vn,Xr,vt,Dn,tr]},[fe,we,B,j,J,G,Re,de]),zt=wt[0],gt=wt[1],bt=wt[2],Jt=wt[3],St=wt[4],qt=wt[5],Ht=wt[6],bn=x(We);A(function(){bn()&&Ie({type:u.resetGroupBy})},[Ie,fe?null:N]),Object.assign(S,{preGroupedRows:B,preGroupedFlatRow:j,preGroupedRowsById:J,groupedRows:zt,groupedFlatRows:gt,groupedRowsById:bt,onlyGroupedFlatRows:Jt,onlyGroupedRowsById:St,nonGroupedFlatRows:qt,nonGroupedRowsById:Ht,rows:zt,flatRows:gt,rowsById:bt,toggleGroupBy:Ct,setGroupBy:Je})}function ae(S){S.allCells.forEach(function(N){var B;N.isGrouped=N.column.isGrouped&&N.column.id===S.groupByID,N.isPlaceholder=!N.isGrouped&&N.column.isGrouped,N.isAggregated=!N.isGrouped&&!N.isPlaceholder&&((B=S.subRows)==null?void 0:B.length)})}function Fe(S,N){return S.reduce(function(B,j,J){var G=""+j.values[N];return B[G]=Array.isArray(B[G])?B[G]:[],B[G].push(j),B},{})}var ot=/([0-9]+)/gm;function kt(S,N){return S===N?0:S>N?1:-1}function Tn(S,N,B){return[S.values[B],N.values[B]]}function _n(S){return typeof S=="number"?isNaN(S)||S===1/0||S===-1/0?"":String(S):typeof S=="string"?S:""}var yt=Object.freeze({__proto__:null,alphanumeric:function(S,N,B){var j=Tn(S,N,B),J=j[0],G=j[1];for(J=_n(J),G=_n(G),J=J.split(ot).filter(Boolean),G=G.split(ot).filter(Boolean);J.length&&G.length;){var Q=J.shift(),le=G.shift(),de=parseInt(Q,10),fe=parseInt(le,10),Le=[de,fe].sort();if(isNaN(Le[0])){if(Q>le)return 1;if(le>Q)return-1}else{if(isNaN(Le[1]))return isNaN(de)?-1:1;if(de>fe)return 1;if(fe>de)return-1}}return J.length-G.length},datetime:function(S,N,B){var j=Tn(S,N,B),J=j[0],G=j[1];return kt(J=J.getTime(),G=G.getTime())},basic:function(S,N,B){var j=Tn(S,N,B);return kt(j[0],j[1])},string:function(S,N,B){var j=Tn(S,N,B),J=j[0],G=j[1];for(J=J.split("").filter(Boolean),G=G.split("").filter(Boolean);J.length&&G.length;){var Q=J.shift(),le=G.shift(),de=Q.toLowerCase(),fe=le.toLowerCase();if(de>fe)return 1;if(fe>de)return-1;if(Q>le)return 1;if(le>Q)return-1}return J.length-G.length},number:function(S,N,B){var j=Tn(S,N,B),J=j[0],G=j[1],Q=/[^0-9.]/gi;return kt(J=Number(String(J).replace(Q,"")),G=Number(String(G).replace(Q,"")))}});u.resetSortBy="resetSortBy",u.setSortBy="setSortBy",u.toggleSortBy="toggleSortBy",u.clearSortBy="clearSortBy",h.sortType="alphanumeric",h.sortDescFirst=!1;var Rn=function(S){S.getSortByToggleProps=[ty],S.stateReducers.push(ny),S.useInstance.push(ry)};Rn.pluginName="useSortBy";var ty=function(S,N){var B=N.instance,j=N.column,J=B.isMultiSortEvent,G=J===void 0?function(Q){return Q.shiftKey}:J;return[S,{onClick:j.canSort?function(Q){Q.persist(),j.toggleSortBy(void 0,!B.disableMultiSort&&G(Q))}:void 0,style:{cursor:j.canSort?"pointer":void 0},title:j.canSort?"Toggle SortBy":void 0}]};function ny(S,N,B,j){if(N.type===u.init)return i({sortBy:[]},S);if(N.type===u.resetSortBy)return i({},S,{sortBy:j.initialState.sortBy||[]});if(N.type===u.clearSortBy)return i({},S,{sortBy:S.sortBy.filter(function(Ne){return Ne.id!==N.columnId})});if(N.type===u.setSortBy)return i({},S,{sortBy:N.sortBy});if(N.type===u.toggleSortBy){var J,G=N.columnId,Q=N.desc,le=N.multi,de=j.allColumns,fe=j.disableMultiSort,Le=j.disableSortRemove,Re=j.disableMultiRemove,Pe=j.maxMultiSortColCount,we=Pe===void 0?Number.MAX_SAFE_INTEGER:Pe,Ie=S.sortBy,ze=de.find(function(Ne){return Ne.id===G}).sortDescFirst,We=Ie.find(function(Ne){return Ne.id===G}),it=Ie.findIndex(function(Ne){return Ne.id===G}),$t=Q!=null,at=[];return(J=!fe&&le?We?"toggle":"add":it!==Ie.length-1||Ie.length!==1?"replace":We?"toggle":"replace")!="toggle"||Le||$t||le&&Re||!(We&&We.desc&&!ze||!We.desc&&ze)||(J="remove"),J==="replace"?at=[{id:G,desc:$t?Q:ze}]:J==="add"?(at=[].concat(Ie,[{id:G,desc:$t?Q:ze}])).splice(0,at.length-we):J==="toggle"?at=Ie.map(function(Ne){return Ne.id===G?i({},Ne,{desc:$t?Q:!We.desc}):Ne}):J==="remove"&&(at=Ie.filter(function(Ne){return Ne.id!==G})),i({},S,{sortBy:at})}}function ry(S){var N=S.data,B=S.rows,j=S.flatRows,J=S.allColumns,G=S.orderByFn,Q=G===void 0?df:G,le=S.sortTypes,de=S.manualSortBy,fe=S.defaultCanSort,Le=S.disableSortBy,Re=S.flatHeaders,Pe=S.state.sortBy,we=S.dispatch,Ie=S.plugins,ze=S.getHooks,We=S.autoResetSortBy,it=We===void 0||We;b(Ie,["useFilters","useGlobalFilter","useGroupBy","usePivotColumns"],"useSortBy");var $t=r.useCallback(function(gt){we({type:u.setSortBy,sortBy:gt})},[we]),at=r.useCallback(function(gt,bt,Jt){we({type:u.toggleSortBy,columnId:gt,desc:bt,multi:Jt})},[we]),Ne=x(S);Re.forEach(function(gt){var bt=gt.accessor,Jt=gt.canSort,St=gt.disableSortBy,qt=gt.id,Ht=bt?U(St!==!0&&void 0,Le!==!0&&void 0,!0):U(fe,Jt,!1);gt.canSort=Ht,gt.canSort&&(gt.toggleSortBy=function(st,Ut){return at(gt.id,st,Ut)},gt.clearSortBy=function(){we({type:u.clearSortBy,columnId:gt.id})}),gt.getSortByToggleProps=y(ze().getSortByToggleProps,{instance:Ne(),column:gt});var bn=Pe.find(function(st){return st.id===qt});gt.isSorted=!!bn,gt.sortedIndex=Pe.findIndex(function(st){return st.id===qt}),gt.isSortedDesc=gt.isSorted?bn.desc:void 0});var Ct=r.useMemo(function(){if(de||!Pe.length)return[B,j];var gt=[],bt=Pe.filter(function(Jt){return J.find(function(St){return St.id===Jt.id})});return[function Jt(St){var qt=Q(St,bt.map(function(Ht){var bn=J.find(function(Vn){return Vn.id===Ht.id});if(!bn)throw new Error("React-Table: Could not find a column with id: "+Ht.id+" while sorting");var st=bn.sortType,Ut=Y(st)||(le||{})[st]||yt[st];if(!Ut)throw new Error("React-Table: Could not find a valid sortType of '"+st+"' for column '"+Ht.id+"'.");return function(Vn,Xr){return Ut(Vn,Xr,Ht.id,Ht.desc)}}),bt.map(function(Ht){var bn=J.find(function(st){return st.id===Ht.id});return bn&&bn.sortInverted?Ht.desc:!Ht.desc}));return qt.forEach(function(Ht){gt.push(Ht),Ht.subRows&&Ht.subRows.length!==0&&(Ht.subRows=Jt(Ht.subRows))}),qt}(B),gt]},[de,Pe,B,j,J,Q,le]),Je=Ct[0],wt=Ct[1],zt=x(it);A(function(){zt()&&we({type:u.resetSortBy})},[de?null:N]),Object.assign(S,{preSortedRows:B,preSortedFlatRows:j,sortedRows:Je,sortedFlatRows:wt,rows:Je,flatRows:wt,setSortBy:$t,toggleSortBy:at})}function df(S,N,B){return[].concat(S).sort(function(j,J){for(var G=0;G<N.length;G+=1){var Q=N[G],le=B[G]===!1||B[G]==="desc",de=Q(j,J);if(de!==0)return le?-de:de}return B[0]?j.index-J.index:J.index-j.index})}u.resetPage="resetPage",u.gotoPage="gotoPage",u.setPageSize="setPageSize";var pf=function(S){S.stateReducers.push(oy),S.useInstance.push(ff)};function oy(S,N,B,j){if(N.type===u.init)return i({pageSize:10,pageIndex:0},S);if(N.type===u.resetPage)return i({},S,{pageIndex:j.initialState.pageIndex||0});if(N.type===u.gotoPage){var J=j.pageCount,G=j.page,Q=w(N.pageIndex,S.pageIndex),le=!1;return Q>S.pageIndex?le=J===-1?G.length>=S.pageSize:Q<J:Q<S.pageIndex&&(le=Q>-1),le?i({},S,{pageIndex:Q}):S}if(N.type===u.setPageSize){var de=N.pageSize,fe=S.pageSize*S.pageIndex;return i({},S,{pageIndex:Math.floor(fe/de),pageSize:de})}}function ff(S){var N=S.rows,B=S.autoResetPage,j=B===void 0||B,J=S.manualExpandedKey,G=J===void 0?"expanded":J,Q=S.plugins,le=S.pageCount,de=S.paginateExpandedRows,fe=de===void 0||de,Le=S.expandSubRows,Re=Le===void 0||Le,Pe=S.state,we=Pe.pageSize,Ie=Pe.pageIndex,ze=Pe.expanded,We=Pe.globalFilter,it=Pe.filters,$t=Pe.groupBy,at=Pe.sortBy,Ne=S.dispatch,Ct=S.data,Je=S.manualPagination;b(Q,["useGlobalFilter","useFilters","useGroupBy","useSortBy","useExpanded"],"usePagination");var wt=x(j);A(function(){wt()&&Ne({type:u.resetPage})},[Ne,Je?null:Ct,We,it,$t,at]);var zt=Je?le:Math.ceil(N.length/we),gt=r.useMemo(function(){return zt>0?[].concat(new Array(zt)).fill(null).map(function(Ut,Vn){return Vn}):[]},[zt]),bt=r.useMemo(function(){var Ut;if(Je)Ut=N;else{var Vn=we*Ie,Xr=Vn+we;Ut=N.slice(Vn,Xr)}return fe?Ut:te(Ut,{manualExpandedKey:G,expanded:ze,expandSubRows:Re})},[Re,ze,G,Je,Ie,we,fe,N]),Jt=Ie>0,St=zt===-1?bt.length>=we:Ie<zt-1,qt=r.useCallback(function(Ut){Ne({type:u.gotoPage,pageIndex:Ut})},[Ne]),Ht=r.useCallback(function(){return qt(function(Ut){return Ut-1})},[qt]),bn=r.useCallback(function(){return qt(function(Ut){return Ut+1})},[qt]),st=r.useCallback(function(Ut){Ne({type:u.setPageSize,pageSize:Ut})},[Ne]);Object.assign(S,{pageOptions:gt,pageCount:zt,page:bt,canPreviousPage:Jt,canNextPage:St,gotoPage:qt,previousPage:Ht,nextPage:bn,setPageSize:st})}pf.pluginName="usePagination",u.resetPivot="resetPivot",u.togglePivot="togglePivot";var Os=function(S){S.getPivotToggleProps=[Eu],S.stateReducers.push(ay),S.useInstanceAfterData.push(iy),S.allColumns.push(sy),S.accessValue.push(ly),S.materializedColumns.push(cy),S.materializedColumnsDeps.push(uy),S.visibleColumns.push(Tu),S.visibleColumnsDeps.push(dy),S.useInstance.push(py),S.prepareRow.push(fy)};Os.pluginName="usePivotColumns";var hf=[],Eu=function(S,N){var B=N.header;return[S,{onClick:B.canPivot?function(j){j.persist(),B.togglePivot()}:void 0,style:{cursor:B.canPivot?"pointer":void 0},title:"Toggle Pivot"}]};function ay(S,N,B,j){if(N.type===u.init)return i({pivotColumns:hf},S);if(N.type===u.resetPivot)return i({},S,{pivotColumns:j.initialState.pivotColumns||hf});if(N.type===u.togglePivot){var J=N.columnId,G=N.value,Q=G!==void 0?G:!S.pivotColumns.includes(J);return i({},S,Q?{pivotColumns:[].concat(S.pivotColumns,[J])}:{pivotColumns:S.pivotColumns.filter(function(le){return le!==J})})}}function iy(S){S.allColumns.forEach(function(N){N.isPivotSource=S.state.pivotColumns.includes(N.id)})}function sy(S,N){var B=N.instance;return S.forEach(function(j){j.isPivotSource=B.state.pivotColumns.includes(j.id),j.uniqueValues=new Set}),S}function ly(S,N){var B=N.column;return B.uniqueValues&&S!==void 0&&B.uniqueValues.add(S),S}function cy(S,N){var B=N.instance,j=B.allColumns,J=B.state;if(!J.pivotColumns.length||!J.groupBy||!J.groupBy.length)return S;var G=J.pivotColumns.map(function(de){return j.find(function(fe){return fe.id===de})}).filter(Boolean),Q=j.filter(function(de){return!de.isPivotSource&&!J.groupBy.includes(de.id)&&!J.pivotColumns.includes(de.id)}),le=L(function de(fe,Le,Re){fe===void 0&&(fe=0),Re===void 0&&(Re=[]);var Pe=G[fe];return Pe?Array.from(Pe.uniqueValues).sort().map(function(we){var Ie=i({},Pe,{Header:Pe.PivotHeader||typeof Pe.header=="string"?Pe.Header+": "+we:we,isPivotGroup:!0,parent:Le,depth:fe,id:Le?Le.id+"."+Pe.id+"."+we:Pe.id+"."+we,pivotValue:we});return Ie.columns=de(fe+1,Ie,[].concat(Re,[function(ze){return ze.values[Pe.id]===we}])),Ie}):Q.map(function(we){return i({},we,{canPivot:!1,isPivoted:!0,parent:Le,depth:fe,id:""+(Le?Le.id+"."+we.id:we.id),accessor:function(Ie,ze,We){if(Re.every(function(it){return it(We)}))return We.values[we.id]}})})}());return[].concat(S,le)}function uy(S,N){var B=N.instance.state,j=B.pivotColumns,J=B.groupBy;return[].concat(S,[j,J])}function Tu(S,N){var B=N.instance.state;return S=S.filter(function(j){return!j.isPivotSource}),B.pivotColumns.length&&B.groupBy&&B.groupBy.length&&(S=S.filter(function(j){return j.isGrouped||j.isPivoted})),S}function dy(S,N){var B=N.instance;return[].concat(S,[B.state.pivotColumns,B.state.groupBy])}function py(S){var N=S.columns,B=S.allColumns,j=S.flatHeaders,J=S.getHooks,G=S.plugins,Q=S.dispatch,le=S.autoResetPivot,de=le===void 0||le,fe=S.manaulPivot,Le=S.disablePivot,Re=S.defaultCanPivot;b(G,["useGroupBy"],"usePivotColumns");var Pe=x(S);B.forEach(function(Ie){var ze=Ie.accessor,We=Ie.defaultPivot,it=Ie.disablePivot;Ie.canPivot=ze?U(Ie.canPivot,it!==!0&&void 0,Le!==!0&&void 0,!0):U(Ie.canPivot,We,Re,!1),Ie.canPivot&&(Ie.togglePivot=function(){return S.togglePivot(Ie.id)}),Ie.Aggregated=Ie.Aggregated||Ie.Cell}),j.forEach(function(Ie){Ie.getPivotToggleProps=y(J().getPivotToggleProps,{instance:Pe(),header:Ie})});var we=x(de);A(function(){we()&&Q({type:u.resetPivot})},[Q,fe?null:N]),Object.assign(S,{togglePivot:function(Ie,ze){Q({type:u.togglePivot,columnId:Ie,value:ze})}})}function fy(S){S.allCells.forEach(function(N){N.isPivoted=N.column.isPivoted})}u.resetSelectedRows="resetSelectedRows",u.toggleAllRowsSelected="toggleAllRowsSelected",u.toggleRowSelected="toggleRowSelected",u.toggleAllPageRowsSelected="toggleAllPageRowsSelected";var mf=function(S){S.getToggleRowSelectedProps=[hy],S.getToggleAllRowsSelectedProps=[my],S.getToggleAllPageRowsSelectedProps=[gy],S.stateReducers.push(gf),S.useInstance.push(vy),S.prepareRow.push(yy)};mf.pluginName="useRowSelect";var hy=function(S,N){var B=N.instance,j=N.row,J=B.manualRowSelectedKey,G=J===void 0?"isSelected":J;return[S,{onChange:function(Q){j.toggleRowSelected(Q.target.checked)},style:{cursor:"pointer"},checked:!(!j.original||!j.original[G])||j.isSelected,title:"Toggle Row Selected",indeterminate:j.isSomeSelected}]},my=function(S,N){var B=N.instance;return[S,{onChange:function(j){B.toggleAllRowsSelected(j.target.checked)},style:{cursor:"pointer"},checked:B.isAllRowsSelected,title:"Toggle All Rows Selected",indeterminate:Boolean(!B.isAllRowsSelected&&Object.keys(B.state.selectedRowIds).length)}]},gy=function(S,N){var B=N.instance;return[S,{onChange:function(j){B.toggleAllPageRowsSelected(j.target.checked)},style:{cursor:"pointer"},checked:B.isAllPageRowsSelected,title:"Toggle All Current Page Rows Selected",indeterminate:Boolean(!B.isAllPageRowsSelected&&B.page.some(function(j){var J=j.id;return B.state.selectedRowIds[J]}))}]};function gf(S,N,B,j){if(N.type===u.init)return i({selectedRowIds:{}},S);if(N.type===u.resetSelectedRows)return i({},S,{selectedRowIds:j.initialState.selectedRowIds||{}});if(N.type===u.toggleAllRowsSelected){var J=N.value,G=j.isAllRowsSelected,Q=j.rowsById,le=j.nonGroupedRowsById,de=le===void 0?Q:le,fe=J!==void 0?J:!G,Le=Object.assign({},S.selectedRowIds);return fe?Object.keys(de).forEach(function(qt){Le[qt]=!0}):Object.keys(de).forEach(function(qt){delete Le[qt]}),i({},S,{selectedRowIds:Le})}if(N.type===u.toggleRowSelected){var Re=N.id,Pe=N.value,we=j.rowsById,Ie=j.selectSubRows,ze=Ie===void 0||Ie,We=j.getSubRows,it=S.selectedRowIds[Re],$t=Pe!==void 0?Pe:!it;if(it===$t)return S;var at=i({},S.selectedRowIds);return function qt(Ht){var bn=we[Ht];if(bn&&(bn.isGrouped||($t?at[Ht]=!0:delete at[Ht]),ze&&We(bn)))return We(bn).forEach(function(st){return qt(st.id)})}(Re),i({},S,{selectedRowIds:at})}if(N.type===u.toggleAllPageRowsSelected){var Ne=N.value,Ct=j.page,Je=j.rowsById,wt=j.selectSubRows,zt=wt===void 0||wt,gt=j.isAllPageRowsSelected,bt=j.getSubRows,Jt=Ne!==void 0?Ne:!gt,St=i({},S.selectedRowIds);return Ct.forEach(function(qt){return function Ht(bn){var st=Je[bn];if(st.isGrouped||(Jt?St[bn]=!0:delete St[bn]),zt&&bt(st))return bt(st).forEach(function(Ut){return Ht(Ut.id)})}(qt.id)}),i({},S,{selectedRowIds:St})}return S}function vy(S){var N=S.data,B=S.rows,j=S.getHooks,J=S.plugins,G=S.rowsById,Q=S.nonGroupedRowsById,le=Q===void 0?G:Q,de=S.autoResetSelectedRows,fe=de===void 0||de,Le=S.state.selectedRowIds,Re=S.selectSubRows,Pe=Re===void 0||Re,we=S.dispatch,Ie=S.page,ze=S.getSubRows;b(J,["useFilters","useGroupBy","useSortBy","useExpanded","usePagination"],"useRowSelect");var We=r.useMemo(function(){var bt=[];return B.forEach(function(Jt){var St=Pe?function qt(Ht,bn,st){if(bn[Ht.id])return!0;var Ut=st(Ht);if(Ut&&Ut.length){var Vn=!0,Xr=!1;return Ut.forEach(function(vt){Xr&&!Vn||(qt(vt,bn,st)?Xr=!0:Vn=!1)}),!!Vn||!!Xr&&null}return!1}(Jt,Le,ze):!!Le[Jt.id];Jt.isSelected=!!St,Jt.isSomeSelected=St===null,St&&bt.push(Jt)}),bt},[B,Pe,Le,ze]),it=Boolean(Object.keys(le).length&&Object.keys(Le).length),$t=it;it&&Object.keys(le).some(function(bt){return!Le[bt]})&&(it=!1),it||Ie&&Ie.length&&Ie.some(function(bt){var Jt=bt.id;return!Le[Jt]})&&($t=!1);var at=x(fe);A(function(){at()&&we({type:u.resetSelectedRows})},[we,N]);var Ne=r.useCallback(function(bt){return we({type:u.toggleAllRowsSelected,value:bt})},[we]),Ct=r.useCallback(function(bt){return we({type:u.toggleAllPageRowsSelected,value:bt})},[we]),Je=r.useCallback(function(bt,Jt){return we({type:u.toggleRowSelected,id:bt,value:Jt})},[we]),wt=x(S),zt=y(j().getToggleAllRowsSelectedProps,{instance:wt()}),gt=y(j().getToggleAllPageRowsSelectedProps,{instance:wt()});Object.assign(S,{selectedFlatRows:We,isAllRowsSelected:it,isAllPageRowsSelected:$t,toggleRowSelected:Je,toggleAllRowsSelected:Ne,getToggleAllRowsSelectedProps:zt,getToggleAllPageRowsSelectedProps:gt,toggleAllPageRowsSelected:Ct})}function yy(S,N){var B=N.instance;S.toggleRowSelected=function(j){return B.toggleRowSelected(S.id,j)},S.getToggleRowSelectedProps=y(B.getHooks().getToggleRowSelectedProps,{instance:B,row:S})}var Ls=function(S){return{}},si=function(S){return{}};u.setRowState="setRowState",u.setCellState="setCellState",u.resetRowState="resetRowState";var ku=function(S){S.stateReducers.push(li),S.useInstance.push(by),S.prepareRow.push(wy)};function li(S,N,B,j){var J=j.initialRowStateAccessor,G=J===void 0?Ls:J,Q=j.initialCellStateAccessor,le=Q===void 0?si:Q,de=j.rowsById;if(N.type===u.init)return i({rowState:{}},S);if(N.type===u.resetRowState)return i({},S,{rowState:j.initialState.rowState||{}});if(N.type===u.setRowState){var fe,Le=N.rowId,Re=N.value,Pe=S.rowState[Le]!==void 0?S.rowState[Le]:G(de[Le]);return i({},S,{rowState:i({},S.rowState,(fe={},fe[Le]=w(Re,Pe),fe))})}if(N.type===u.setCellState){var we,Ie,ze,We,it,$t=N.rowId,at=N.columnId,Ne=N.value,Ct=S.rowState[$t]!==void 0?S.rowState[$t]:G(de[$t]),Je=(Ct==null||(we=Ct.cellState)==null?void 0:we[at])!==void 0?Ct.cellState[at]:le((Ie=de[$t])==null||(ze=Ie.cells)==null?void 0:ze.find(function(wt){return wt.column.id===at}));return i({},S,{rowState:i({},S.rowState,(it={},it[$t]=i({},Ct,{cellState:i({},Ct.cellState||{},(We={},We[at]=w(Ne,Je),We))}),it))})}}function by(S){var N=S.autoResetRowState,B=N===void 0||N,j=S.data,J=S.dispatch,G=r.useCallback(function(de,fe){return J({type:u.setRowState,rowId:de,value:fe})},[J]),Q=r.useCallback(function(de,fe,Le){return J({type:u.setCellState,rowId:de,columnId:fe,value:Le})},[J]),le=x(B);A(function(){le()&&J({type:u.resetRowState})},[j]),Object.assign(S,{setRowState:G,setCellState:Q})}function wy(S,N){var B=N.instance,j=B.initialRowStateAccessor,J=j===void 0?Ls:j,G=B.initialCellStateAccessor,Q=G===void 0?si:G,le=B.state.rowState;S&&(S.state=le[S.id]!==void 0?le[S.id]:J(S),S.setState=function(de){return B.setRowState(S.id,de)},S.cells.forEach(function(de){S.state.cellState||(S.state.cellState={}),de.state=S.state.cellState[de.column.id]!==void 0?S.state.cellState[de.column.id]:Q(de),de.setState=function(fe){return B.setCellState(S.id,de.column.id,fe)}}))}ku.pluginName="useRowState",u.resetColumnOrder="resetColumnOrder",u.setColumnOrder="setColumnOrder";var vf=function(S){S.stateReducers.push(Sy),S.visibleColumnsDeps.push(function(N,B){var j=B.instance;return[].concat(N,[j.state.columnOrder])}),S.visibleColumns.push(xy),S.useInstance.push(Cy)};function Sy(S,N,B,j){return N.type===u.init?i({columnOrder:[]},S):N.type===u.resetColumnOrder?i({},S,{columnOrder:j.initialState.columnOrder||[]}):N.type===u.setColumnOrder?i({},S,{columnOrder:w(N.columnOrder,S.columnOrder)}):void 0}function xy(S,N){var B=N.instance.state.columnOrder;if(!B||!B.length)return S;for(var j=[].concat(B),J=[].concat(S),G=[],Q=function(){var le=j.shift(),de=J.findIndex(function(fe){return fe.id===le});de>-1&&G.push(J.splice(de,1)[0])};J.length&&j.length;)Q();return[].concat(G,J)}function Cy(S){var N=S.dispatch;S.setColumnOrder=r.useCallback(function(B){return N({type:u.setColumnOrder,columnOrder:B})},[N])}vf.pluginName="useColumnOrder",h.canResize=!0,u.columnStartResizing="columnStartResizing",u.columnResizing="columnResizing",u.columnDoneResizing="columnDoneResizing",u.resetResize="resetResize";var Au=function(S){S.getResizerProps=[ci],S.getHeaderProps.push({style:{position:"relative"}}),S.stateReducers.push(Ey),S.useInstance.push(Ty),S.useInstanceBeforeDimensions.push(yf)},ci=function(S,N){var B=N.instance,j=N.header,J=B.dispatch,G=function(Q,le){var de=!1;if(Q.type==="touchstart"){if(Q.touches&&Q.touches.length>1)return;de=!0}var fe,Le,Re=function(at){var Ne=[];return function Ct(Je){Je.columns&&Je.columns.length&&Je.columns.map(Ct),Ne.push(Je)}(at),Ne}(le).map(function(at){return[at.id,at.totalWidth]}),Pe=de?Math.round(Q.touches[0].clientX):Q.clientX,we=function(){window.cancelAnimationFrame(fe),fe=null,J({type:u.columnDoneResizing})},Ie=function(){window.cancelAnimationFrame(fe),fe=null,J({type:u.columnResizing,clientX:Le})},ze=function(at){Le=at,fe||(fe=window.requestAnimationFrame(Ie))},We={mouse:{moveEvent:"mousemove",moveHandler:function(at){return ze(at.clientX)},upEvent:"mouseup",upHandler:function(at){document.removeEventListener("mousemove",We.mouse.moveHandler),document.removeEventListener("mouseup",We.mouse.upHandler),we()}},touch:{moveEvent:"touchmove",moveHandler:function(at){return at.cancelable&&(at.preventDefault(),at.stopPropagation()),ze(at.touches[0].clientX),!1},upEvent:"touchend",upHandler:function(at){document.removeEventListener(We.touch.moveEvent,We.touch.moveHandler),document.removeEventListener(We.touch.upEvent,We.touch.moveHandler),we()}}},it=de?We.touch:We.mouse,$t=!!function(){if(typeof R=="boolean")return R;var at=!1;try{var Ne={get passive(){return at=!0,!1}};window.addEventListener("test",null,Ne),window.removeEventListener("test",null,Ne)}catch{at=!1}return R=at}()&&{passive:!1};document.addEventListener(it.moveEvent,it.moveHandler,$t),document.addEventListener(it.upEvent,it.upHandler,$t),J({type:u.columnStartResizing,columnId:le.id,columnWidth:le.totalWidth,headerIdWidths:Re,clientX:Pe})};return[S,{onMouseDown:function(Q){return Q.persist()||G(Q,j)},onTouchStart:function(Q){return Q.persist()||G(Q,j)},style:{cursor:"col-resize"},draggable:!1,role:"separator"}]};function Ey(S,N){if(N.type===u.init)return i({columnResizing:{columnWidths:{}}},S);if(N.type===u.resetResize)return i({},S,{columnResizing:{columnWidths:{}}});if(N.type===u.columnStartResizing){var B=N.clientX,j=N.columnId,J=N.columnWidth,G=N.headerIdWidths;return i({},S,{columnResizing:i({},S.columnResizing,{startX:B,headerIdWidths:G,columnWidth:J,isResizingColumn:j})})}if(N.type===u.columnResizing){var Q=N.clientX,le=S.columnResizing,de=le.startX,fe=le.columnWidth,Le=le.headerIdWidths,Re=(Q-de)/fe,Pe={};return(Le===void 0?[]:Le).forEach(function(we){var Ie=we[0],ze=we[1];Pe[Ie]=Math.max(ze+ze*Re,0)}),i({},S,{columnResizing:i({},S.columnResizing,{columnWidths:i({},S.columnResizing.columnWidths,{},Pe)})})}return N.type===u.columnDoneResizing?i({},S,{columnResizing:i({},S.columnResizing,{startX:null,isResizingColumn:null})}):void 0}Au.pluginName="useResizeColumns";var yf=function(S){var N=S.flatHeaders,B=S.disableResizing,j=S.getHooks,J=S.state.columnResizing,G=x(S);N.forEach(function(Q){var le=U(Q.disableResizing!==!0&&void 0,B!==!0&&void 0,!0);Q.canResize=le,Q.width=J.columnWidths[Q.id]||Q.originalWidth||Q.width,Q.isResizing=J.isResizingColumn===Q.id,le&&(Q.getResizerProps=y(j().getResizerProps,{instance:G(),header:Q}))})};function Ty(S){var N=S.plugins,B=S.dispatch,j=S.autoResetResize,J=j===void 0||j,G=S.columns;b(N,["useAbsoluteLayout"],"useResizeColumns");var Q=x(J);A(function(){Q()&&B({type:u.resetResize})},[G]);var le=r.useCallback(function(){return B({type:u.resetResize})},[B]);Object.assign(S,{resetResizing:le})}var Ns={position:"absolute",top:0},_u=function(S){S.getTableBodyProps.push(Nl),S.getRowProps.push(Nl),S.getHeaderGroupProps.push(Nl),S.getFooterGroupProps.push(Nl),S.getHeaderProps.push(function(N,B){var j=B.column;return[N,{style:i({},Ns,{left:j.totalLeft+"px",width:j.totalWidth+"px"})}]}),S.getCellProps.push(function(N,B){var j=B.cell;return[N,{style:i({},Ns,{left:j.column.totalLeft+"px",width:j.column.totalWidth+"px"})}]}),S.getFooterProps.push(function(N,B){var j=B.column;return[N,{style:i({},Ns,{left:j.totalLeft+"px",width:j.totalWidth+"px"})}]})};_u.pluginName="useAbsoluteLayout";var Nl=function(S,N){return[S,{style:{position:"relative",width:N.instance.totalColumnsWidth+"px"}}]},Ru={display:"inline-block",boxSizing:"border-box"},Ml=function(S,N){return[S,{style:{display:"flex",width:N.instance.totalColumnsWidth+"px"}}]},bf=function(S){S.getRowProps.push(Ml),S.getHeaderGroupProps.push(Ml),S.getFooterGroupProps.push(Ml),S.getHeaderProps.push(function(N,B){var j=B.column;return[N,{style:i({},Ru,{width:j.totalWidth+"px"})}]}),S.getCellProps.push(function(N,B){var j=B.cell;return[N,{style:i({},Ru,{width:j.column.totalWidth+"px"})}]}),S.getFooterProps.push(function(N,B){var j=B.column;return[N,{style:i({},Ru,{width:j.totalWidth+"px"})}]})};function Ms(S){S.getTableProps.push(ky),S.getRowProps.push(Ds),S.getHeaderGroupProps.push(Ds),S.getFooterGroupProps.push(Ds),S.getHeaderProps.push(Ay),S.getCellProps.push(_y),S.getFooterProps.push(H)}bf.pluginName="useBlockLayout",Ms.pluginName="useFlexLayout";var ky=function(S,N){return[S,{style:{minWidth:N.instance.totalColumnsMinWidth+"px"}}]},Ds=function(S,N){return[S,{style:{display:"flex",flex:"1 0 auto",minWidth:N.instance.totalColumnsMinWidth+"px"}}]},Ay=function(S,N){var B=N.column;return[S,{style:{boxSizing:"border-box",flex:B.totalFlexWidth?B.totalFlexWidth+" 0 auto":void 0,minWidth:B.totalMinWidth+"px",width:B.totalWidth+"px"}}]},_y=function(S,N){var B=N.cell;return[S,{style:{boxSizing:"border-box",flex:B.column.totalFlexWidth+" 0 auto",minWidth:B.column.totalMinWidth+"px",width:B.column.totalWidth+"px"}}]},H=function(S,N){var B=N.column;return[S,{style:{boxSizing:"border-box",flex:B.totalFlexWidth?B.totalFlexWidth+" 0 auto":void 0,minWidth:B.totalMinWidth+"px",width:B.totalWidth+"px"}}]};function oe(S){S.stateReducers.push(Pr),S.getTableProps.push(ge),S.getHeaderProps.push(nt),S.getRowProps.push(er)}u.columnStartResizing="columnStartResizing",u.columnResizing="columnResizing",u.columnDoneResizing="columnDoneResizing",u.resetResize="resetResize",oe.pluginName="useGridLayout";var ge=function(S,N){var B=N.instance;return[S,{style:{display:"grid",gridTemplateColumns:B.visibleColumns.map(function(j){var J;return B.state.gridLayout.columnWidths[j.id]?B.state.gridLayout.columnWidths[j.id]+"px":(J=B.state.columnResizing)!=null&&J.isResizingColumn?B.state.gridLayout.startWidths[j.id]+"px":typeof j.width=="number"?j.width+"px":j.width}).join(" ")}}]},nt=function(S,N){var B=N.column;return[S,{id:"header-cell-"+B.id,style:{position:"sticky",gridColumn:"span "+B.totalVisibleHeaderCount}}]},er=function(S,N){var B=N.row;return B.isExpanded?[S,{style:{gridColumn:"1 / "+(B.cells.length+1)}}]:[S,{}]};function Pr(S,N,B,j){if(N.type===u.init)return i({gridLayout:{columnWidths:{}}},S);if(N.type===u.resetResize)return i({},S,{gridLayout:{columnWidths:{}}});if(N.type===u.columnStartResizing){var J=N.columnId,G=N.headerIdWidths,Q=Dr(J);if(Q!==void 0){var le=j.visibleColumns.reduce(function(Ne,Ct){var Je;return i({},Ne,((Je={})[Ct.id]=Dr(Ct.id),Je))},{}),de=j.visibleColumns.reduce(function(Ne,Ct){var Je;return i({},Ne,((Je={})[Ct.id]=Ct.minWidth,Je))},{}),fe=j.visibleColumns.reduce(function(Ne,Ct){var Je;return i({},Ne,((Je={})[Ct.id]=Ct.maxWidth,Je))},{}),Le=G.map(function(Ne){var Ct=Ne[0];return[Ct,Dr(Ct)]});return i({},S,{gridLayout:i({},S.gridLayout,{startWidths:le,minWidths:de,maxWidths:fe,headerIdGridWidths:Le,columnWidth:Q})})}return S}if(N.type===u.columnResizing){var Re=N.clientX,Pe=S.columnResizing.startX,we=S.gridLayout,Ie=we.columnWidth,ze=we.minWidths,We=we.maxWidths,it=we.headerIdGridWidths,$t=(Re-Pe)/Ie,at={};return(it===void 0?[]:it).forEach(function(Ne){var Ct=Ne[0],Je=Ne[1];at[Ct]=Math.min(Math.max(ze[Ct],Je+Je*$t),We[Ct])}),i({},S,{gridLayout:i({},S.gridLayout,{columnWidths:i({},S.gridLayout.columnWidths,{},at)})})}return N.type===u.columnDoneResizing?i({},S,{gridLayout:i({},S.gridLayout,{startWidths:{},minWidths:{},maxWidths:{}})}):void 0}function Dr(S){var N,B=(N=document.getElementById("header-cell-"+S))==null?void 0:N.offsetWidth;if(B!==void 0)return B}n._UNSTABLE_usePivotColumns=Os,n.actions=u,n.defaultColumn=h,n.defaultGroupByFn=Fe,n.defaultOrderByFn=df,n.defaultRenderer=d,n.emptyRenderer=f,n.ensurePluginOrder=b,n.flexRender=_,n.functionalUpdate=w,n.loopHooks=v,n.makePropGetter=y,n.makeRenderer=k,n.reduceHooks=g,n.safeUseLayoutEffect=E,n.useAbsoluteLayout=_u,n.useAsyncDebounce=function(S,N){N===void 0&&(N=0);var B=r.useRef({}),j=x(S),J=x(N);return r.useCallback(function(){var G=a(regeneratorRuntime.mark(function Q(){var le,de,fe,Le=arguments;return regeneratorRuntime.wrap(function(Re){for(;;)switch(Re.prev=Re.next){case 0:for(le=Le.length,de=new Array(le),fe=0;fe<le;fe++)de[fe]=Le[fe];return B.current.promise||(B.current.promise=new Promise(function(Pe,we){B.current.resolve=Pe,B.current.reject=we})),B.current.timeout&&clearTimeout(B.current.timeout),B.current.timeout=setTimeout(a(regeneratorRuntime.mark(function Pe(){return regeneratorRuntime.wrap(function(we){for(;;)switch(we.prev=we.next){case 0:return delete B.current.timeout,we.prev=1,we.t0=B.current,we.next=5,j().apply(void 0,de);case 5:we.t1=we.sent,we.t0.resolve.call(we.t0,we.t1),we.next=12;break;case 9:we.prev=9,we.t2=we.catch(1),B.current.reject(we.t2);case 12:return we.prev=12,delete B.current.promise,we.finish(12);case 15:case"end":return we.stop()}},Pe,null,[[1,9,12,15]])})),J()),Re.abrupt("return",B.current.promise);case 5:case"end":return Re.stop()}},Q)}));return function(){return G.apply(this,arguments)}}(),[j,J])},n.useBlockLayout=bf,n.useColumnOrder=vf,n.useExpanded=q,n.useFilters=ro,n.useFlexLayout=Ms,n.useGetLatest=x,n.useGlobalFilter=Rr,n.useGridLayout=oe,n.useGroupBy=jn,n.useMountedLayoutEffect=A,n.usePagination=pf,n.useResizeColumns=Au,n.useRowSelect=mf,n.useRowState=ku,n.useSortBy=Rn,n.useTable=function(S){for(var N=arguments.length,B=new Array(N>1?N-1:0),j=1;j<N;j++)B[j-1]=arguments[j];S=Te(S),B=[qe].concat(B);var J=r.useRef({}),G=x(J.current);Object.assign(G(),i({},S,{plugins:B,hooks:Ge()})),B.filter(Boolean).forEach(function(vt){vt(G().hooks)});var Q=x(G().hooks);G().getHooks=Q,delete G().hooks,Object.assign(G(),g(Q().useOptions,Te(S)));var le=G(),de=le.data,fe=le.columns,Le=le.initialState,Re=le.defaultColumn,Pe=le.getSubRows,we=le.getRowId,Ie=le.stateReducer,ze=le.useControlledState,We=x(Ie),it=r.useCallback(function(vt,Dn){if(!Dn.type)throw console.info({action:Dn}),new Error("Unknown Action 👆");return[].concat(Q().stateReducers,Array.isArray(We())?We():[We()]).reduce(function(tr,Jr){return Jr(tr,Dn,vt,G())||tr},vt)},[Q,We,G]),$t=r.useReducer(it,void 0,function(){return it(Le,{type:u.init})}),at=$t[0],Ne=$t[1],Ct=g([].concat(Q().useControlledState,[ze]),at,{instance:G()});Object.assign(G(),{state:Ct,dispatch:Ne});var Je=r.useMemo(function(){return $(g(Q().columns,fe,{instance:G()}))},[Q,G,fe].concat(g(Q().columnsDeps,[],{instance:G()})));G().columns=Je;var wt=r.useMemo(function(){return g(Q().allColumns,L(Je),{instance:G()}).map(O)},[Je,Q,G].concat(g(Q().allColumnsDeps,[],{instance:G()})));G().allColumns=wt;var zt=r.useMemo(function(){for(var vt=[],Dn=[],tr={},Jr=[].concat(wt);Jr.length;){var Sr=Jr.shift();De({data:de,rows:vt,flatRows:Dn,rowsById:tr,column:Sr,getRowId:we,getSubRows:Pe,accessValueHooks:Q().accessValue,getInstance:G})}return[vt,Dn,tr]},[wt,de,we,Pe,Q,G]),gt=zt[0],bt=zt[1],Jt=zt[2];Object.assign(G(),{rows:gt,initialRows:[].concat(gt),flatRows:bt,rowsById:Jt}),v(Q().useInstanceAfterData,G());var St=r.useMemo(function(){return g(Q().visibleColumns,wt,{instance:G()}).map(function(vt){return P(vt,Re)})},[Q,wt,G,Re].concat(g(Q().visibleColumnsDeps,[],{instance:G()})));wt=r.useMemo(function(){var vt=[].concat(St);return wt.forEach(function(Dn){vt.find(function(tr){return tr.id===Dn.id})||vt.push(Dn)}),vt},[wt,St]),G().allColumns=wt;var qt=r.useMemo(function(){return g(Q().headerGroups,D(St,Re),G())},[Q,St,Re,G].concat(g(Q().headerGroupsDeps,[],{instance:G()})));G().headerGroups=qt;var Ht=r.useMemo(function(){return qt.length?qt[0].headers:[]},[qt]);G().headers=Ht,G().flatHeaders=qt.reduce(function(vt,Dn){return[].concat(vt,Dn.headers)},[]),v(Q().useInstanceBeforeDimensions,G());var bn=St.filter(function(vt){return vt.isVisible}).map(function(vt){return vt.id}).sort().join("_");St=r.useMemo(function(){return St.filter(function(vt){return vt.isVisible})},[St,bn]),G().visibleColumns=St;var st=Xe(Ht),Ut=st[0],Vn=st[1],Xr=st[2];return G().totalColumnsMinWidth=Ut,G().totalColumnsWidth=Vn,G().totalColumnsMaxWidth=Xr,v(Q().useInstance,G()),[].concat(G().flatHeaders,G().allColumns).forEach(function(vt){vt.render=k(G(),vt),vt.getHeaderProps=y(Q().getHeaderProps,{instance:G(),column:vt}),vt.getFooterProps=y(Q().getFooterProps,{instance:G(),column:vt})}),G().headerGroups=r.useMemo(function(){return qt.filter(function(vt,Dn){return vt.headers=vt.headers.filter(function(tr){return tr.headers?function Jr(Sr){return Sr.filter(function(Fi){return Fi.headers?Jr(Fi.headers):Fi.isVisible}).length}(tr.headers):tr.isVisible}),!!vt.headers.length&&(vt.getHeaderGroupProps=y(Q().getHeaderGroupProps,{instance:G(),headerGroup:vt,index:Dn}),vt.getFooterGroupProps=y(Q().getFooterGroupProps,{instance:G(),headerGroup:vt,index:Dn}),!0)})},[qt,G,Q]),G().footerGroups=[].concat(G().headerGroups).reverse(),G().prepareRow=r.useCallback(function(vt){vt.getRowProps=y(Q().getRowProps,{instance:G(),row:vt}),vt.allCells=wt.map(function(Dn){var tr=vt.values[Dn.id],Jr={column:Dn,row:vt,value:tr};return Jr.getCellProps=y(Q().getCellProps,{instance:G(),cell:Jr}),Jr.render=k(G(),Dn,{row:vt,cell:Jr,value:tr}),Jr}),vt.cells=St.map(function(Dn){return vt.allCells.find(function(tr){return tr.column.id===Dn.id})}),v(Q().prepareRow,vt,{instance:G()})},[Q,G,wt,St]),G().getTableProps=y(Q().getTableProps,{instance:G()}),G().getTableBodyProps=y(Q().getTableBodyProps,{instance:G()}),v(Q().useFinalInstance,G()),G()},Object.defineProperty(n,"__esModule",{value:!0})})})(Wne,Im);(function(e){e.exports=Im})(Une);const Hne=()=>{throw new Error("setAnnouncement called outside AnnouncerContext")},Vx=jt.createContext({setAnnouncement:Hne}),Vne=C(v4,{shouldForwardProp:e=>e!=="isFlex"&&e!=="isSortable"&&e!=="isFlexGrow"})(({theme:e,isFlex:t,isSortable:n,isFlexGrow:r})=>({position:"relative",fontWeight:e.typography.fontWeightRegular,...t&&{justifyContent:"stretch",alignItems:"center",display:"flex",flexShrink:0,"& > *":{flexGrow:1}},...n&&{padding:0,"&:hover, &:focus":{backgroundColor:e.palette.tableHeaderHover,"& svg":{color:"inherit"}}},...r&&{flexGrow:1}})),Gne=C("button",{shouldForwardProp:e=>e!=="isSorted"})(({theme:e,isSorted:t})=>({all:"unset",whiteSpace:"nowrap",width:"100%",position:"relative",zIndex:1,":hover, :focus, &:focus-visible, &:active":{outline:"revert",".hover-only":{display:"inline-block"}},display:"flex",boxSizing:"inherit",cursor:"pointer",...t&&{fontWeight:e.typography.fontWeightBold}})),qne=C("span")(({theme:e})=>({display:"flex",flexDirection:"column",flexShrink:1,minWidth:0,"::after":{fontWeight:"bold",display:"inline-block",height:0,content:"attr(data-text)",visibility:"hidden",overflow:"hidden"}})),Kne=C("span")(({theme:e})=>({padding:e.spacing(2),visibility:"hidden",display:"flex",alignItems:"center",width:"100%"})),Yne=C("span")(({theme:e})=>({padding:e.spacing(2),position:"absolute",display:"flex",alignItems:"center",width:"100%",height:"100%",".hover-only":{display:"none"},"& > span":{minWidth:0,whiteSpace:"nowrap",textOverflow:"ellipsis",overflowX:"hidden",overflowY:"visible"}}));var jb={},Xne={get exports(){return jb},set exports(e){jb=e}};/*!
|
|
255
|
+
Copyright (c) 2018 Jed Watson.
|
|
256
|
+
Licensed under the MIT License (MIT), see
|
|
257
|
+
http://jedwatson.github.io/classnames
|
|
258
|
+
*/(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r=[],o=0;o<arguments.length;o++){var a=arguments[o];if(a){var i=typeof a;if(i==="string"||i==="number")r.push(a);else if(Array.isArray(a)){if(a.length){var l=n.apply(null,a);l&&r.push(l)}}else if(i==="object"){if(a.toString!==Object.prototype.toString&&!a.toString.toString().includes("[native code]")){r.push(a.toString());continue}for(var c in a)t.call(a,c)&&a[c]&&r.push(c)}}}return r.join(" ")}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(Xne);const Ca=jb,E1=e=>({marginLeft:e.spacing(.25),marginRight:e.spacing(-.5),color:e.palette.neutral.main,fontSize:e.fontSizes.mainHeader,verticalAlign:"middle"}),TA=({isSorted:e,isDesc:t=!1,className:n})=>s(X,{condition:Boolean(e),show:s(X,{condition:Boolean(t),show:s(Lb,{sx:r=>({...E1(r),color:r.palette.tableHeaderColor}),className:n,fontSize:"inherit"}),elseShow:s(DZ,{sx:r=>({...E1(r),color:r.palette.tableHeaderColor}),className:n,fontSize:"inherit"})}),elseShow:s(YZ,{sx:r=>({...E1(r)}),className:Ca(n,"hover-only"),fontSize:"inherit"})}),Jne=({children:e,isSortable:t=!0,isSorted:n=!1,isDescending:r,width:o,minWidth:a,maxWidth:i,align:l,ariaTitle:c,isFlex:u,isFlexGrow:d,onClick:f=()=>{}})=>{const{setAnnouncement:h}=p.useContext(Vx),[m,y]=p.useState(""),g=p.useRef(null),v=n?r?"descending":"ascending":void 0,b=x=>{f(x),h(`Sorted${c?` by ${c} `:""}, ${r?"ascending":"descending"}`)},w=p.useMemo(()=>{switch(l){case"left":return{justifyContent:"flex-start",textAlign:"left"};case"center":return{justifyContent:"center",textAlign:"center"};case"right":return{justifyContent:"flex-end",textAlign:"right"};default:return}},[l]);return p.useEffect(()=>{(()=>{var A,k;const E=c&&g.current&&((A=g==null?void 0:g.current)==null?void 0:A.offsetWidth)<((k=g==null?void 0:g.current)==null?void 0:k.scrollWidth)?`${e}`:"";E!==m&&y(E)})()},[y,c]),s(Vne,{component:"th","aria-sort":v,style:{width:o,minWidth:a,maxWidth:i},isFlex:u,isFlexGrow:d,isSortable:t,children:s(X,{condition:t,show:s(_t,{title:m,arrow:!0,children:T(Gne,{isSorted:n,type:"button",onClick:b,children:[T(Kne,{style:w,"aria-hidden":!0,children:[s(qne,{tabIndex:-1,"data-text":e,children:e}),s(TA,{isSorted:n,isDesc:r})]}),T(Yne,{style:w,children:[s("span",{ref:g,tabIndex:-1,children:s("span",{children:e})}),s(TA,{isSorted:n,isDesc:r,className:"sort-arrow"})]})]})}),elseShow:s("div",{style:w,children:e})})})},Qne=C(ai)(({theme:e})=>({"& > th":{height:e.shape.tableRowHeightCompact,border:0,backgroundColor:e.palette.tableHeaderBackground,color:e.palette.tableHeaderColor,"&:first-of-type":{borderTopLeftRadius:e.shape.borderRadiusMedium,borderBottomLeftRadius:e.shape.borderRadiusMedium},"&:last-of-type":{borderTopRightRadius:e.shape.borderRadiusMedium,borderBottomRightRadius:e.shape.borderRadiusMedium}}})),Ni=({headerGroups:e,className:t,flex:n})=>s(QJ,{className:t,children:e.map(r=>s(Qne,{...r.getHeaderGroupProps(),children:r.headers.map(o=>{const a=o.render("Header");return s(Jne,{...o.getHeaderProps(o.canSort?o.getSortByToggleProps():void 0),ariaTitle:typeof a=="string"?a:void 0,isSortable:Boolean(o.canSort),isSorted:o.isSorted,isDescending:o.isSortedDesc,maxWidth:o.maxWidth,minWidth:o.minWidth,width:o.width,isFlex:n,isFlexGrow:Boolean(o.minWidth),align:o.align,children:a})})}))}),Mi=({rowHeight:e="auto",...t})=>s(IJ,{sx:{position:"relative","& tbody tr":{height:n=>({auto:"auto",standard:n.shape.tableRowHeight,compact:n.shape.tableRowHeightCompact,dense:n.shape.tableRowHeightDense})[e]??e}},...t}),Zne=C(v4)(({theme:e})=>({padding:0})),ei=p.forwardRef(({className:e,...t},n)=>s(Zne,{...t,ref:n})),Un=({children:e})=>s(Me,{sx:{border:t=>`2px dashed ${t.palette.neutral.light}`,p:1.6,textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",mt:2,width:"100%"},children:e}),ere=(e,t=40,n=5)=>{const[r,o]=p.useState(Math.floor(window.pageYOffset/e));return p.useEffect(()=>{const a=()=>{requestAnimationFrame(()=>{o(Math.floor(window.pageYOffset/(e*n))*n)})};return window.addEventListener("scroll",a,{passive:!0}),()=>{window.removeEventListener("scroll",a)}},[e,n]),[r-t,r+t]},vv=({rowHeight:e,headerGroups:t,rows:n,prepareRow:r})=>{const o=on(),a=p.useMemo(()=>e||o.shape.tableRowHeight,[e,o.shape.tableRowHeight]),[i,l]=ere(a),c=p.useMemo(()=>a*n.length+o.shape.tableRowHeightCompact,[a,n.length,o.shape.tableRowHeightCompact]);return T(Mi,{role:"table",rowHeight:a,style:{height:c},children:[s(Ni,{headerGroups:t,flex:!0}),s($i,{role:"rowgroup",sx:{"& tr":{position:"absolute",width:"100%","&:hover":{".show-row-hover":{opacity:1}}},"& tr td":{alignItems:"center",display:"flex",flexShrink:0,"& > *":{flexGrow:1}}},children:n.map((u,d)=>{const f=d*a+o.shape.tableRowHeightCompact;return d<i||d>l?null:(r(u),p.createElement(ai,{hover:!0,...u.getRowProps({style:{display:"flex",top:f}}),key:u.id},u.cells.map(m=>s(ei,{...m.getCellProps({style:{flex:m.column.minWidth?"1 0 auto":void 0}}),children:m.render("Cell")}))))})})]})},tre=e=>fetch(e).then(yn("Feature toggle")).then(t=>t.json()),Gx=()=>{const{data:e,error:t,mutate:n}=dn(Dt("api/admin/features"),tre,{refreshInterval:15e3});return{features:e==null?void 0:e.features,loading:!t&&!e,refetchFeatures:n,error:t}},v3=p.createContext(""),Di=v3.Provider,su=()=>({searchQuery:p.useContext(v3)}),kA=e=>{let t;const n=new Set,r=(c,u)=>{const d=typeof c=="function"?c(t):c;if(d!==t){const f=t;t=u?d:Object.assign({},t,d),n.forEach(h=>h(t,f))}},o=()=>t,l={setState:r,getState:o,subscribe:c=>(n.add(c),()=>n.delete(c)),destroy:()=>n.clear()};return t=e(r,o,l),l},nre=e=>e?kA(e):kA;var Ub={},rre={get exports(){return Ub},set exports(e){Ub=e}},y3={};/**
|
|
259
|
+
* @license React
|
|
260
|
+
* use-sync-external-store-shim/with-selector.production.min.js
|
|
261
|
+
*
|
|
262
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
263
|
+
*
|
|
264
|
+
* This source code is licensed under the MIT license found in the
|
|
265
|
+
* LICENSE file in the root directory of this source tree.
|
|
266
|
+
*/var yv=p,ore=km;function are(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var ire=typeof Object.is=="function"?Object.is:are,sre=ore.useSyncExternalStore,lre=yv.useRef,cre=yv.useEffect,ure=yv.useMemo,dre=yv.useDebugValue;y3.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var a=lre(null);if(a.current===null){var i={hasValue:!1,value:null};a.current=i}else i=a.current;a=ure(function(){function c(m){if(!u){if(u=!0,d=m,m=r(m),o!==void 0&&i.hasValue){var y=i.value;if(o(y,m))return f=y}return f=m}if(y=f,ire(d,m))return y;var g=r(m);return o!==void 0&&o(y,g)?y:(d=m,f=g)}var u=!1,d,f,h=n===void 0?null:n;return[function(){return c(t())},h===null?void 0:function(){return c(h())}]},[t,n,r,o]);var l=sre(e,a[0],a[1]);return cre(function(){i.hasValue=!0,i.value=l},[l]),dre(l),l};(function(e){e.exports=y3})(rre);const pre=Ym(Ub),{useSyncExternalStoreWithSelector:fre}=pre;function hre(e,t=e.getState,n){const r=fre(e.subscribe,e.getState,e.getServerState||e.getState,t,n);return p.useDebugValue(r),r}const AA=e=>{const t=typeof e=="function"?nre(e):e,n=(r,o)=>hre(t,r,o);return Object.assign(n,t),n},mre=e=>e?AA(e):AA;var gre=mre;const vre=e=>{const t=gre(()=>e),n=(r,o)=>{t.setState(a=>{return{[r]:(i=a[r],l=o,typeof l=="function"?l(i):l)};var i,l})};return{useGlobalState:r=>{const o=p.useCallback(a=>a[r],[r]);return[t(o),p.useCallback(a=>n(r,a),[r])]},getGlobalState:r=>t.getState()[r],setGlobalState:n,subscribe:(r,o)=>{t.subscribe((a,i)=>{a[r]!==i[r]&&o(a[r])})}}},qx=(e,t)=>{const n=vre({[e]:gp(e)??t}),r=o=>{const a=n.getGlobalState(e),i=o instanceof Function?o(a):o;n.setGlobalState(e,i),zc(e,i)};return()=>[n.useGlobalState(e)[0],r]},ii=()=>{const[e,t]=bre();return{locationSettings:e,setLocationSettings:t}},yre=()=>({locale:navigator.language}),bre=qx(`${Oi}:useLocationSettings:v1`,yre()),bv=(e,t)=>new Date(e).toLocaleString(t,{day:"2-digit",month:"2-digit",year:"numeric",hour:"2-digit",minute:"2-digit",second:"2-digit"}),Uc=(e,t)=>new Date(e).toLocaleString(t,{day:"2-digit",month:"2-digit",year:"numeric"}),pIe=(e,t)=>new Date(e).toLocaleString(t,{hour:"2-digit",minute:"2-digit"});function xs(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function wre(e,t){Wn(2,arguments);var n=sr(e).getTime(),r=xs(t);return new Date(n+r)}var Sre={};function nf(){return Sre}function xre(e,t){Wn(2,arguments);var n=sr(e),r=sr(t),o=n.getTime()-r.getTime();return o<0?-1:o>0?1:o}var b3=6e4,w3=36e5,fIe=1e3;function Bh(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Bh=function(n){return typeof n}:Bh=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Bh(e)}function Cre(e){return Wn(1,arguments),e instanceof Date||Bh(e)==="object"&&Object.prototype.toString.call(e)==="[object Date]"}function Kx(e){if(Wn(1,arguments),!Cre(e)&&typeof e!="number")return!1;var t=sr(e);return!isNaN(Number(t))}function Ere(e,t){Wn(2,arguments);var n=xs(t);return wre(e,-n)}var Tre=864e5;function kre(e){Wn(1,arguments);var t=sr(e),n=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var r=t.getTime(),o=n-r;return Math.floor(o/Tre)+1}function $m(e){Wn(1,arguments);var t=1,n=sr(e),r=n.getUTCDay(),o=(r<t?7:0)+r-t;return n.setUTCDate(n.getUTCDate()-o),n.setUTCHours(0,0,0,0),n}function S3(e){Wn(1,arguments);var t=sr(e),n=t.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var o=$m(r),a=new Date(0);a.setUTCFullYear(n,0,4),a.setUTCHours(0,0,0,0);var i=$m(a);return t.getTime()>=o.getTime()?n+1:t.getTime()>=i.getTime()?n:n-1}function Are(e){Wn(1,arguments);var t=S3(e),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var r=$m(n);return r}var _re=6048e5;function Rre(e){Wn(1,arguments);var t=sr(e),n=$m(t).getTime()-Are(t).getTime();return Math.round(n/_re)+1}function Om(e,t){var n,r,o,a,i,l,c,u;Wn(1,arguments);var d=nf(),f=xs((n=(r=(o=(a=t==null?void 0:t.weekStartsOn)!==null&&a!==void 0?a:t==null||(i=t.locale)===null||i===void 0||(l=i.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&o!==void 0?o:d.weekStartsOn)!==null&&r!==void 0?r:(c=d.locale)===null||c===void 0||(u=c.options)===null||u===void 0?void 0:u.weekStartsOn)!==null&&n!==void 0?n:0);if(!(f>=0&&f<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=sr(e),m=h.getUTCDay(),y=(m<f?7:0)+m-f;return h.setUTCDate(h.getUTCDate()-y),h.setUTCHours(0,0,0,0),h}function x3(e,t){var n,r,o,a,i,l,c,u;Wn(1,arguments);var d=sr(e),f=d.getUTCFullYear(),h=nf(),m=xs((n=(r=(o=(a=t==null?void 0:t.firstWeekContainsDate)!==null&&a!==void 0?a:t==null||(i=t.locale)===null||i===void 0||(l=i.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&o!==void 0?o:h.firstWeekContainsDate)!==null&&r!==void 0?r:(c=h.locale)===null||c===void 0||(u=c.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(m>=1&&m<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var y=new Date(0);y.setUTCFullYear(f+1,0,m),y.setUTCHours(0,0,0,0);var g=Om(y,t),v=new Date(0);v.setUTCFullYear(f,0,m),v.setUTCHours(0,0,0,0);var b=Om(v,t);return d.getTime()>=g.getTime()?f+1:d.getTime()>=b.getTime()?f:f-1}function Pre(e,t){var n,r,o,a,i,l,c,u;Wn(1,arguments);var d=nf(),f=xs((n=(r=(o=(a=t==null?void 0:t.firstWeekContainsDate)!==null&&a!==void 0?a:t==null||(i=t.locale)===null||i===void 0||(l=i.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&o!==void 0?o:d.firstWeekContainsDate)!==null&&r!==void 0?r:(c=d.locale)===null||c===void 0||(u=c.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&n!==void 0?n:1),h=x3(e,t),m=new Date(0);m.setUTCFullYear(h,0,f),m.setUTCHours(0,0,0,0);var y=Om(m,t);return y}var Ire=6048e5;function $re(e,t){Wn(1,arguments);var n=sr(e),r=Om(n,t).getTime()-Pre(n,t).getTime();return Math.round(r/Ire)+1}function hn(e,t){for(var n=e<0?"-":"",r=Math.abs(e).toString();r.length<t;)r="0"+r;return n+r}var Ore={y:function(t,n){var r=t.getUTCFullYear(),o=r>0?r:1-r;return hn(n==="yy"?o%100:o,n.length)},M:function(t,n){var r=t.getUTCMonth();return n==="M"?String(r+1):hn(r+1,2)},d:function(t,n){return hn(t.getUTCDate(),n.length)},a:function(t,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.toUpperCase();case"aaa":return r;case"aaaaa":return r[0];case"aaaa":default:return r==="am"?"a.m.":"p.m."}},h:function(t,n){return hn(t.getUTCHours()%12||12,n.length)},H:function(t,n){return hn(t.getUTCHours(),n.length)},m:function(t,n){return hn(t.getUTCMinutes(),n.length)},s:function(t,n){return hn(t.getUTCSeconds(),n.length)},S:function(t,n){var r=n.length,o=t.getUTCMilliseconds(),a=Math.floor(o*Math.pow(10,r-3));return hn(a,n.length)}};const ji=Ore;var Vl={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Lre={G:function(t,n,r){var o=t.getUTCFullYear()>0?1:0;switch(n){case"G":case"GG":case"GGG":return r.era(o,{width:"abbreviated"});case"GGGGG":return r.era(o,{width:"narrow"});case"GGGG":default:return r.era(o,{width:"wide"})}},y:function(t,n,r){if(n==="yo"){var o=t.getUTCFullYear(),a=o>0?o:1-o;return r.ordinalNumber(a,{unit:"year"})}return ji.y(t,n)},Y:function(t,n,r,o){var a=x3(t,o),i=a>0?a:1-a;if(n==="YY"){var l=i%100;return hn(l,2)}return n==="Yo"?r.ordinalNumber(i,{unit:"year"}):hn(i,n.length)},R:function(t,n){var r=S3(t);return hn(r,n.length)},u:function(t,n){var r=t.getUTCFullYear();return hn(r,n.length)},Q:function(t,n,r){var o=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"Q":return String(o);case"QQ":return hn(o,2);case"Qo":return r.ordinalNumber(o,{unit:"quarter"});case"QQQ":return r.quarter(o,{width:"abbreviated",context:"formatting"});case"QQQQQ":return r.quarter(o,{width:"narrow",context:"formatting"});case"QQQQ":default:return r.quarter(o,{width:"wide",context:"formatting"})}},q:function(t,n,r){var o=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"q":return String(o);case"qq":return hn(o,2);case"qo":return r.ordinalNumber(o,{unit:"quarter"});case"qqq":return r.quarter(o,{width:"abbreviated",context:"standalone"});case"qqqqq":return r.quarter(o,{width:"narrow",context:"standalone"});case"qqqq":default:return r.quarter(o,{width:"wide",context:"standalone"})}},M:function(t,n,r){var o=t.getUTCMonth();switch(n){case"M":case"MM":return ji.M(t,n);case"Mo":return r.ordinalNumber(o+1,{unit:"month"});case"MMM":return r.month(o,{width:"abbreviated",context:"formatting"});case"MMMMM":return r.month(o,{width:"narrow",context:"formatting"});case"MMMM":default:return r.month(o,{width:"wide",context:"formatting"})}},L:function(t,n,r){var o=t.getUTCMonth();switch(n){case"L":return String(o+1);case"LL":return hn(o+1,2);case"Lo":return r.ordinalNumber(o+1,{unit:"month"});case"LLL":return r.month(o,{width:"abbreviated",context:"standalone"});case"LLLLL":return r.month(o,{width:"narrow",context:"standalone"});case"LLLL":default:return r.month(o,{width:"wide",context:"standalone"})}},w:function(t,n,r,o){var a=$re(t,o);return n==="wo"?r.ordinalNumber(a,{unit:"week"}):hn(a,n.length)},I:function(t,n,r){var o=Rre(t);return n==="Io"?r.ordinalNumber(o,{unit:"week"}):hn(o,n.length)},d:function(t,n,r){return n==="do"?r.ordinalNumber(t.getUTCDate(),{unit:"date"}):ji.d(t,n)},D:function(t,n,r){var o=kre(t);return n==="Do"?r.ordinalNumber(o,{unit:"dayOfYear"}):hn(o,n.length)},E:function(t,n,r){var o=t.getUTCDay();switch(n){case"E":case"EE":case"EEE":return r.day(o,{width:"abbreviated",context:"formatting"});case"EEEEE":return r.day(o,{width:"narrow",context:"formatting"});case"EEEEEE":return r.day(o,{width:"short",context:"formatting"});case"EEEE":default:return r.day(o,{width:"wide",context:"formatting"})}},e:function(t,n,r,o){var a=t.getUTCDay(),i=(a-o.weekStartsOn+8)%7||7;switch(n){case"e":return String(i);case"ee":return hn(i,2);case"eo":return r.ordinalNumber(i,{unit:"day"});case"eee":return r.day(a,{width:"abbreviated",context:"formatting"});case"eeeee":return r.day(a,{width:"narrow",context:"formatting"});case"eeeeee":return r.day(a,{width:"short",context:"formatting"});case"eeee":default:return r.day(a,{width:"wide",context:"formatting"})}},c:function(t,n,r,o){var a=t.getUTCDay(),i=(a-o.weekStartsOn+8)%7||7;switch(n){case"c":return String(i);case"cc":return hn(i,n.length);case"co":return r.ordinalNumber(i,{unit:"day"});case"ccc":return r.day(a,{width:"abbreviated",context:"standalone"});case"ccccc":return r.day(a,{width:"narrow",context:"standalone"});case"cccccc":return r.day(a,{width:"short",context:"standalone"});case"cccc":default:return r.day(a,{width:"wide",context:"standalone"})}},i:function(t,n,r){var o=t.getUTCDay(),a=o===0?7:o;switch(n){case"i":return String(a);case"ii":return hn(a,n.length);case"io":return r.ordinalNumber(a,{unit:"day"});case"iii":return r.day(o,{width:"abbreviated",context:"formatting"});case"iiiii":return r.day(o,{width:"narrow",context:"formatting"});case"iiiiii":return r.day(o,{width:"short",context:"formatting"});case"iiii":default:return r.day(o,{width:"wide",context:"formatting"})}},a:function(t,n,r){var o=t.getUTCHours(),a=o/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"aaa":return r.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return r.dayPeriod(a,{width:"narrow",context:"formatting"});case"aaaa":default:return r.dayPeriod(a,{width:"wide",context:"formatting"})}},b:function(t,n,r){var o=t.getUTCHours(),a;switch(o===12?a=Vl.noon:o===0?a=Vl.midnight:a=o/12>=1?"pm":"am",n){case"b":case"bb":return r.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"bbb":return r.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return r.dayPeriod(a,{width:"narrow",context:"formatting"});case"bbbb":default:return r.dayPeriod(a,{width:"wide",context:"formatting"})}},B:function(t,n,r){var o=t.getUTCHours(),a;switch(o>=17?a=Vl.evening:o>=12?a=Vl.afternoon:o>=4?a=Vl.morning:a=Vl.night,n){case"B":case"BB":case"BBB":return r.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"BBBBB":return r.dayPeriod(a,{width:"narrow",context:"formatting"});case"BBBB":default:return r.dayPeriod(a,{width:"wide",context:"formatting"})}},h:function(t,n,r){if(n==="ho"){var o=t.getUTCHours()%12;return o===0&&(o=12),r.ordinalNumber(o,{unit:"hour"})}return ji.h(t,n)},H:function(t,n,r){return n==="Ho"?r.ordinalNumber(t.getUTCHours(),{unit:"hour"}):ji.H(t,n)},K:function(t,n,r){var o=t.getUTCHours()%12;return n==="Ko"?r.ordinalNumber(o,{unit:"hour"}):hn(o,n.length)},k:function(t,n,r){var o=t.getUTCHours();return o===0&&(o=24),n==="ko"?r.ordinalNumber(o,{unit:"hour"}):hn(o,n.length)},m:function(t,n,r){return n==="mo"?r.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):ji.m(t,n)},s:function(t,n,r){return n==="so"?r.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):ji.s(t,n)},S:function(t,n){return ji.S(t,n)},X:function(t,n,r,o){var a=o._originalDate||t,i=a.getTimezoneOffset();if(i===0)return"Z";switch(n){case"X":return RA(i);case"XXXX":case"XX":return Hs(i);case"XXXXX":case"XXX":default:return Hs(i,":")}},x:function(t,n,r,o){var a=o._originalDate||t,i=a.getTimezoneOffset();switch(n){case"x":return RA(i);case"xxxx":case"xx":return Hs(i);case"xxxxx":case"xxx":default:return Hs(i,":")}},O:function(t,n,r,o){var a=o._originalDate||t,i=a.getTimezoneOffset();switch(n){case"O":case"OO":case"OOO":return"GMT"+_A(i,":");case"OOOO":default:return"GMT"+Hs(i,":")}},z:function(t,n,r,o){var a=o._originalDate||t,i=a.getTimezoneOffset();switch(n){case"z":case"zz":case"zzz":return"GMT"+_A(i,":");case"zzzz":default:return"GMT"+Hs(i,":")}},t:function(t,n,r,o){var a=o._originalDate||t,i=Math.floor(a.getTime()/1e3);return hn(i,n.length)},T:function(t,n,r,o){var a=o._originalDate||t,i=a.getTime();return hn(i,n.length)}};function _A(e,t){var n=e>0?"-":"+",r=Math.abs(e),o=Math.floor(r/60),a=r%60;if(a===0)return n+String(o);var i=t||"";return n+String(o)+i+hn(a,2)}function RA(e,t){if(e%60===0){var n=e>0?"-":"+";return n+hn(Math.abs(e)/60,2)}return Hs(e,t)}function Hs(e,t){var n=t||"",r=e>0?"-":"+",o=Math.abs(e),a=hn(Math.floor(o/60),2),i=hn(o%60,2);return r+a+n+i}const Nre=Lre;var PA=function(t,n){switch(t){case"P":return n.date({width:"short"});case"PP":return n.date({width:"medium"});case"PPP":return n.date({width:"long"});case"PPPP":default:return n.date({width:"full"})}},C3=function(t,n){switch(t){case"p":return n.time({width:"short"});case"pp":return n.time({width:"medium"});case"ppp":return n.time({width:"long"});case"pppp":default:return n.time({width:"full"})}},Mre=function(t,n){var r=t.match(/(P+)(p+)?/)||[],o=r[1],a=r[2];if(!a)return PA(t,n);var i;switch(o){case"P":i=n.dateTime({width:"short"});break;case"PP":i=n.dateTime({width:"medium"});break;case"PPP":i=n.dateTime({width:"long"});break;case"PPPP":default:i=n.dateTime({width:"full"});break}return i.replace("{{date}}",PA(o,n)).replace("{{time}}",C3(a,n))},Dre={p:C3,P:Mre};const Bre=Dre;var Fre=["D","DD"],zre=["YY","YYYY"];function jre(e){return Fre.indexOf(e)!==-1}function Ure(e){return zre.indexOf(e)!==-1}function IA(e,t,n){if(e==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var Wre={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Hre=function(t,n,r){var o,a=Wre[t];return typeof a=="string"?o=a:n===1?o=a.one:o=a.other.replace("{{count}}",n.toString()),r!=null&&r.addSuffix?r.comparison&&r.comparison>0?"in "+o:o+" ago":o};const Vre=Hre;function T1(e){return function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.width?String(t.width):e.defaultWidth,r=e.formats[n]||e.formats[e.defaultWidth];return r}}var Gre={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},qre={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Kre={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Yre={date:T1({formats:Gre,defaultWidth:"full"}),time:T1({formats:qre,defaultWidth:"full"}),dateTime:T1({formats:Kre,defaultWidth:"full"})};const Xre=Yre;var Jre={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Qre=function(t,n,r,o){return Jre[t]};const Zre=Qre;function Ju(e){return function(t,n){var r=n!=null&&n.context?String(n.context):"standalone",o;if(r==="formatting"&&e.formattingValues){var a=e.defaultFormattingWidth||e.defaultWidth,i=n!=null&&n.width?String(n.width):a;o=e.formattingValues[i]||e.formattingValues[a]}else{var l=e.defaultWidth,c=n!=null&&n.width?String(n.width):e.defaultWidth;o=e.values[c]||e.values[l]}var u=e.argumentCallback?e.argumentCallback(t):t;return o[u]}}var eoe={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},toe={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},noe={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},roe={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},ooe={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},aoe={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},ioe=function(t,n){var r=Number(t),o=r%100;if(o>20||o<10)switch(o%10){case 1:return r+"st";case 2:return r+"nd";case 3:return r+"rd"}return r+"th"},soe={ordinalNumber:ioe,era:Ju({values:eoe,defaultWidth:"wide"}),quarter:Ju({values:toe,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:Ju({values:noe,defaultWidth:"wide"}),day:Ju({values:roe,defaultWidth:"wide"}),dayPeriod:Ju({values:ooe,defaultWidth:"wide",formattingValues:aoe,defaultFormattingWidth:"wide"})};const loe=soe;function Qu(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.width,o=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],a=t.match(o);if(!a)return null;var i=a[0],l=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(l)?uoe(l,function(f){return f.test(i)}):coe(l,function(f){return f.test(i)}),u;u=e.valueCallback?e.valueCallback(c):c,u=n.valueCallback?n.valueCallback(u):u;var d=t.slice(i.length);return{value:u,rest:d}}}function coe(e,t){for(var n in e)if(e.hasOwnProperty(n)&&t(e[n]))return n}function uoe(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return n}function doe(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.match(e.matchPattern);if(!r)return null;var o=r[0],a=t.match(e.parsePattern);if(!a)return null;var i=e.valueCallback?e.valueCallback(a[0]):a[0];i=n.valueCallback?n.valueCallback(i):i;var l=t.slice(o.length);return{value:i,rest:l}}}var poe=/^(\d+)(th|st|nd|rd)?/i,foe=/\d+/i,hoe={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},moe={any:[/^b/i,/^(a|c)/i]},goe={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},voe={any:[/1/i,/2/i,/3/i,/4/i]},yoe={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},boe={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},woe={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Soe={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},xoe={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Coe={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},Eoe={ordinalNumber:doe({matchPattern:poe,parsePattern:foe,valueCallback:function(t){return parseInt(t,10)}}),era:Qu({matchPatterns:hoe,defaultMatchWidth:"wide",parsePatterns:moe,defaultParseWidth:"any"}),quarter:Qu({matchPatterns:goe,defaultMatchWidth:"wide",parsePatterns:voe,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:Qu({matchPatterns:yoe,defaultMatchWidth:"wide",parsePatterns:boe,defaultParseWidth:"any"}),day:Qu({matchPatterns:woe,defaultMatchWidth:"wide",parsePatterns:Soe,defaultParseWidth:"any"}),dayPeriod:Qu({matchPatterns:xoe,defaultMatchWidth:"any",parsePatterns:Coe,defaultParseWidth:"any"})};const Toe=Eoe;var koe={code:"en-US",formatDistance:Vre,formatLong:Xre,formatRelative:Zre,localize:loe,match:Toe,options:{weekStartsOn:0,firstWeekContainsDate:1}};const E3=koe;var Aoe=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,_oe=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Roe=/^'([^]*?)'?$/,Poe=/''/g,Ioe=/[a-zA-Z]/;function xp(e,t,n){var r,o,a,i,l,c,u,d,f,h,m,y,g,v,b,w,x,E;Wn(2,arguments);var A=String(t),k=nf(),_=(r=(o=n==null?void 0:n.locale)!==null&&o!==void 0?o:k.locale)!==null&&r!==void 0?r:E3,$=xs((a=(i=(l=(c=n==null?void 0:n.firstWeekContainsDate)!==null&&c!==void 0?c:n==null||(u=n.locale)===null||u===void 0||(d=u.options)===null||d===void 0?void 0:d.firstWeekContainsDate)!==null&&l!==void 0?l:k.firstWeekContainsDate)!==null&&i!==void 0?i:(f=k.locale)===null||f===void 0||(h=f.options)===null||h===void 0?void 0:h.firstWeekContainsDate)!==null&&a!==void 0?a:1);if(!($>=1&&$<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var L=xs((m=(y=(g=(v=n==null?void 0:n.weekStartsOn)!==null&&v!==void 0?v:n==null||(b=n.locale)===null||b===void 0||(w=b.options)===null||w===void 0?void 0:w.weekStartsOn)!==null&&g!==void 0?g:k.weekStartsOn)!==null&&y!==void 0?y:(x=k.locale)===null||x===void 0||(E=x.options)===null||E===void 0?void 0:E.weekStartsOn)!==null&&m!==void 0?m:0);if(!(L>=0&&L<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!_.localize)throw new RangeError("locale must contain localize property");if(!_.formatLong)throw new RangeError("locale must contain formatLong property");var O=sr(e);if(!Kx(O))throw new RangeError("Invalid time value");var P=bp(O),D=Ere(O,P),F={firstWeekContainsDate:$,weekStartsOn:L,locale:_,_originalDate:O},U=A.match(_oe).map(function(Y){var V=Y[0];if(V==="p"||V==="P"){var te=Bre[V];return te(Y,_.formatLong)}return Y}).join("").match(Aoe).map(function(Y){if(Y==="''")return"'";var V=Y[0];if(V==="'")return $oe(Y);var te=Nre[V];if(te)return!(n!=null&&n.useAdditionalWeekYearTokens)&&Ure(Y)&&IA(Y,t,String(e)),!(n!=null&&n.useAdditionalDayOfYearTokens)&&jre(Y)&&IA(Y,t,String(e)),te(D,Y,_.localize,F);if(V.match(Ioe))throw new RangeError("Format string contains an unescaped latin alphabet character `"+V+"`");return Y}).join("");return U}function $oe(e){var t=e.match(Roe);return t?t[1].replace(Poe,"'"):e}function T3(e,t){if(e==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}function Ooe(e){return T3({},e)}var $A=1e3*60,Lm=60*24,OA=Lm*30,LA=Lm*365;function Loe(e,t,n){var r,o,a;Wn(2,arguments);var i=nf(),l=(r=(o=n==null?void 0:n.locale)!==null&&o!==void 0?o:i.locale)!==null&&r!==void 0?r:E3;if(!l.formatDistance)throw new RangeError("locale must contain localize.formatDistance property");var c=xre(e,t);if(isNaN(c))throw new RangeError("Invalid time value");var u=T3(Ooe(n),{addSuffix:Boolean(n==null?void 0:n.addSuffix),comparison:c}),d,f;c>0?(d=sr(t),f=sr(e)):(d=sr(e),f=sr(t));var h=String((a=n==null?void 0:n.roundingMethod)!==null&&a!==void 0?a:"round"),m;if(h==="floor")m=Math.floor;else if(h==="ceil")m=Math.ceil;else if(h==="round")m=Math.round;else throw new RangeError("roundingMethod must be 'floor', 'ceil' or 'round'");var y=f.getTime()-d.getTime(),g=y/$A,v=bp(f)-bp(d),b=(y-v)/$A,w=n==null?void 0:n.unit,x;if(w?x=String(w):g<1?x="second":g<60?x="minute":g<Lm?x="hour":b<OA?x="day":b<LA?x="month":x="year",x==="second"){var E=m(y/1e3);return l.formatDistance("xSeconds",E,u)}else if(x==="minute"){var A=m(g);return l.formatDistance("xMinutes",A,u)}else if(x==="hour"){var k=m(g/60);return l.formatDistance("xHours",k,u)}else if(x==="day"){var _=m(b/Lm);return l.formatDistance("xDays",_,u)}else if(x==="month"){var $=m(b/OA);return $===12&&w!=="month"?l.formatDistance("xYears",1,u):l.formatDistance("xMonths",$,u)}else if(x==="year"){var L=m(b/LA);return l.formatDistance("xYears",L,u)}throw new RangeError("unit must be 'second', 'minute', 'hour', 'day', 'month' or 'year'")}function Noe(e,t){return Wn(1,arguments),Loe(e,Date.now(),t)}function Moe(e){return Wn(1,arguments),sr(e).getTime()<Date.now()}function rf(e,t){var n;Wn(1,arguments);var r=xs((n=t==null?void 0:t.additionalDigits)!==null&&n!==void 0?n:2);if(r!==2&&r!==1&&r!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(!(typeof e=="string"||Object.prototype.toString.call(e)==="[object String]"))return new Date(NaN);var o=zoe(e),a;if(o.date){var i=joe(o.date,r);a=Uoe(i.restDateString,i.year)}if(!a||isNaN(a.getTime()))return new Date(NaN);var l=a.getTime(),c=0,u;if(o.time&&(c=Woe(o.time),isNaN(c)))return new Date(NaN);if(o.timezone){if(u=Hoe(o.timezone),isNaN(u))return new Date(NaN)}else{var d=new Date(l+c),f=new Date(0);return f.setFullYear(d.getUTCFullYear(),d.getUTCMonth(),d.getUTCDate()),f.setHours(d.getUTCHours(),d.getUTCMinutes(),d.getUTCSeconds(),d.getUTCMilliseconds()),f}return new Date(l+c+u)}var th={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},Doe=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,Boe=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,Foe=/^([+-])(\d{2})(?::?(\d{2}))?$/;function zoe(e){var t={},n=e.split(th.dateTimeDelimiter),r;if(n.length>2)return t;if(/:/.test(n[0])?r=n[0]:(t.date=n[0],r=n[1],th.timeZoneDelimiter.test(t.date)&&(t.date=e.split(th.timeZoneDelimiter)[0],r=e.substr(t.date.length,e.length))),r){var o=th.timezone.exec(r);o?(t.time=r.replace(o[1],""),t.timezone=o[1]):t.time=r}return t}function joe(e,t){var n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),r=e.match(n);if(!r)return{year:NaN,restDateString:""};var o=r[1]?parseInt(r[1]):null,a=r[2]?parseInt(r[2]):null;return{year:a===null?o:a*100,restDateString:e.slice((r[1]||r[2]).length)}}function Uoe(e,t){if(t===null)return new Date(NaN);var n=e.match(Doe);if(!n)return new Date(NaN);var r=!!n[4],o=Zu(n[1]),a=Zu(n[2])-1,i=Zu(n[3]),l=Zu(n[4]),c=Zu(n[5])-1;if(r)return Yoe(t,l,c)?Voe(t,l,c):new Date(NaN);var u=new Date(0);return!qoe(t,a,i)||!Koe(t,o)?new Date(NaN):(u.setUTCFullYear(t,a,Math.max(o,i)),u)}function Zu(e){return e?parseInt(e):1}function Woe(e){var t=e.match(Boe);if(!t)return NaN;var n=k1(t[1]),r=k1(t[2]),o=k1(t[3]);return Xoe(n,r,o)?n*w3+r*b3+o*1e3:NaN}function k1(e){return e&&parseFloat(e.replace(",","."))||0}function Hoe(e){if(e==="Z")return 0;var t=e.match(Foe);if(!t)return 0;var n=t[1]==="+"?-1:1,r=parseInt(t[2]),o=t[3]&&parseInt(t[3])||0;return Joe(r,o)?n*(r*w3+o*b3):NaN}function Voe(e,t,n){var r=new Date(0);r.setUTCFullYear(e,0,4);var o=r.getUTCDay()||7,a=(t-1)*7+n+1-o;return r.setUTCDate(r.getUTCDate()+a),r}var Goe=[31,null,31,30,31,30,31,31,30,31,30,31];function k3(e){return e%400===0||e%4===0&&e%100!==0}function qoe(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(Goe[t]||(k3(e)?29:28))}function Koe(e,t){return t>=1&&t<=(k3(e)?366:365)}function Yoe(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}function Xoe(e,t,n){return e===24?t===0&&n===0:n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}function Joe(e,t){return t>=0&&t<=59}const Qoe=C(Me,{shouldForwardProp:e=>e!=="lineClamp"})(({theme:e,lineClamp:t})=>({padding:e.spacing(1,2),display:"-webkit-box",overflow:t?"hidden":"auto",WebkitLineClamp:t||"none",WebkitBoxOrient:"vertical",wordBreak:"break-all",[e.breakpoints.down("sm")]:{wordBreak:"normal"}})),eo=({value:e,children:t,lineClamp:n,sx:r,"data-testid":o})=>s(Qoe,{lineClamp:n,sx:r,children:s("span",{"data-loading":"true","data-testid":o,children:t??e})}),Cp=({value:e})=>{const{locationSettings:t}=ii(),n=e?e instanceof Date?Uc(e,t.locale):Uc(rf(e),t.locale):void 0;return s(eo,{lineClamp:1,children:n})};function Yx(e,t){return new RegExp(e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),t)}const Zoe=C("span")(({theme:e})=>({"&>mark":{backgroundColor:e.palette.highlight}})),yl=({search:e,children:t,caseSensitive:n})=>{if(!t)return null;if(!e)return s(ke,{children:t});const r=Yx(e,n?"g":"gi");return s(Zoe,{dangerouslySetInnerHTML:{__html:(t==null?void 0:t.replaceAll(r,"<mark>$&</mark>"))||""}})},A3=e=>({paddingTop:e.spacing(1.5),paddingBottom:e.spacing(1.5),paddingLeft:e.spacing(2),paddingRight:e.spacing(2),display:"flex",alignItems:"center",minHeight:"62px"}),eae=C("div")(({theme:e})=>A3(e)),NA=C(go)(({theme:e})=>({...A3(e),"&:hover, &:focus":{textDecoration:"none","& > div > span:first-of-type":{textDecoration:"underline"}}})),tae=C("div")(({theme:e})=>({display:"flex",flexDirection:"column",justifyContent:"center",wordBreak:"break-all"})),nae=C("span")(({theme:e})=>({overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitBoxOrient:"vertical"})),rae=C("span")(({theme:e})=>({color:e.palette.text.secondary,textDecoration:"none",fontSize:"inherit",WebkitLineClamp:1,lineClamp:1,overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitBoxOrient:"vertical"})),Is=({title:e,to:t,onClick:n,subtitle:r,children:o})=>{const{searchQuery:a}=su(),i=T(tae,{children:[T(nae,{"data-loading":!0,style:{WebkitLineClamp:Boolean(r)?1:2,lineClamp:Boolean(r)?1:2},children:[s(yl,{search:a,children:e}),o]}),s(X,{condition:Boolean(r),show:s(ke,{children:s(rae,{"data-loading":!0,children:s(yl,{search:a,children:r})})})})]});return t?s(NA,{component:ln,to:t,underline:"hover",children:i}):n?s(NA,{onClick:n,underline:"hover",children:i}):s(eae,{children:i})};function nh(e){const t=new Date(e);if(!Number.isNaN(t.valueOf()))return t;const n=String(e).match(/\d+/g);if(n==null||n.length<=2)return t;{const[r,o,...a]=n.map(c=>parseInt(c)),i=[r,o-1,...a];return new Date(Date.UTC(...i))}}function MA(e,t,n){const r=e!==1?t+"s":t;return e+" "+r+" "+n}function Wb(){return Wb=Object.assign?Object.assign.bind():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},Wb.apply(this,arguments)}const gd=60,vd=gd*60,Cc=vd*24,rh=Cc*7,DA=Cc*30,BA=Cc*365;function wv({date:e,formatter:t=MA,component:n="time",live:r=!0,minPeriod:o=0,maxPeriod:a=rh,title:i,now:l=()=>Date.now(),...c}){const[u,d]=p.useState(l());p.useEffect(()=>{if(!r)return;const A=(()=>{const k=nh(e).valueOf();if(!k)return console.warn("[react-timeago] Invalid Date provided"),0;const _=Math.round(Math.abs(u-k)/1e3),$=_<gd?1e3:_<vd?1e3*gd:_<Cc?1e3*vd:1e3*rh,L=Math.min(Math.max($,o*1e3),a*1e3);return L?setTimeout(()=>{d(l())},L):0})();return()=>{A&&clearTimeout(A)}},[e,r,a,o,l,u]);const f=n,h=nh(e).valueOf();if(!h)return null;const m=Math.round(Math.abs(u-h)/1e3),y=h<u?"ago":"from now",[g,v]=m<gd?[Math.round(m),"second"]:m<vd?[Math.round(m/gd),"minute"]:m<Cc?[Math.round(m/vd),"hour"]:m<rh?[Math.round(m/Cc),"day"]:m<DA?[Math.round(m/rh),"week"]:m<BA?[Math.round(m/DA),"month"]:[Math.round(m/BA),"year"],b=typeof i>"u"?typeof e=="string"?e:nh(e).toISOString().substr(0,16).replace("T"," "):i,w=f==="time"?{...c,dateTime:nh(e).toISOString()}:c,x=MA.bind(null,g,v,y);return p.createElement(f,Wb({},w,{title:b}),t(g,v,y,h,x,l))}function oae(e){switch(e){case"second":return"s";case"minute":return"m";case"hour":return"h";case"day":return"D";case"week":return"W";case"month":return"M";case"year":return"Y";default:return""}}const aae=()=>{const e=on();return t=>{switch(t){case"second":return e.palette.activityIndicators.recent;case"minute":return e.palette.activityIndicators.recent;case"hour":return e.palette.activityIndicators.recent;case"day":return e.palette.activityIndicators.recent;case"week":return e.palette.activityIndicators.inactive;case"month":return e.palette.activityIndicators.abandoned;case"year":return e.palette.activityIndicators.abandoned;default:return e.palette.activityIndicators.unknown}}},iae=C("div")(({theme:e})=>({display:"flex",padding:e.spacing(1.5)})),sae=C("div")(({theme:e})=>({width:"38px",height:"38px",background:e.palette.background.paper,borderRadius:`${e.shape.borderRadius}px`,textAlign:"center",display:"flex",alignItems:"center",justifyContent:"center",fontSize:e.typography.body2.fontSize,margin:"0 auto"})),FA=({unit:e,tooltip:t,children:n})=>{const r=aae();return s(iae,{children:s(_t,{title:t,arrow:!0,describeChild:!0,children:s(sae,{style:{background:r(e)},"data-loading":!0,children:n})})})},_3=({value:e})=>s(X,{condition:Boolean(e),show:s(wv,{date:e,title:"",live:!1,formatter:(t,n,r)=>T(FA,{tooltip:`Last usage reported ${t} ${n}${t!==1?"s":""} ${r}`,unit:n,children:[t,oae(n)]})}),elseShow:s(FA,{tooltip:"No usage reported from connected applications",children:"–"})}),lae="experiment",cae="release",uae="operational",dae="kill-switch",pae="permission";var Xx={},fae=cn;Object.defineProperty(Xx,"__esModule",{value:!0});var Hb=Xx.default=void 0,hae=fae(Cn()),mae=En,gae=(0,hae.default)((0,mae.jsx)("path",{d:"M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8L5.24 7.74C4.46 8.97 4 10.43 4 12c0 4.42 3.58 8 8 8v3l4-4-4-4v3z"}),"Loop");Hb=Xx.default=gae;var Jx={},vae=cn;Object.defineProperty(Jx,"__esModule",{value:!0});var R3=Jx.default=void 0,yae=vae(Cn()),bae=En,wae=(0,yae.default)((0,bae.jsx)("path",{d:"M23 8c0 1.1-.9 2-2 2-.18 0-.35-.02-.51-.07l-3.56 3.55c.05.16.07.34.07.52 0 1.1-.9 2-2 2s-2-.9-2-2c0-.18.02-.36.07-.52l-2.55-2.55c-.16.05-.34.07-.52.07s-.36-.02-.52-.07l-4.55 4.56c.05.16.07.33.07.51 0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2c.18 0 .35.02.51.07l4.56-4.55C8.02 9.36 8 9.18 8 9c0-1.1.9-2 2-2s2 .9 2 2c0 .18-.02.36-.07.52l2.55 2.55c.16-.05.34-.07.52-.07s.36.02.52.07l3.55-3.56C19.02 8.35 19 8.18 19 8c0-1.1.9-2 2-2s2 .9 2 2z"}),"Timeline");R3=Jx.default=wae;var Qx={},Sae=cn;Object.defineProperty(Qx,"__esModule",{value:!0});var Zx=Qx.default=void 0,xae=Sae(Cn()),Cae=En,Eae=(0,xae.default)((0,Cae.jsx)("path",{d:"M13 3h-2v10h2V3zm4.83 2.17-1.42 1.42C17.99 7.86 19 9.81 19 12c0 3.87-3.13 7-7 7s-7-3.13-7-7c0-2.19 1.01-4.14 2.58-5.42L6.17 5.17C4.23 6.82 3 9.26 3 12c0 4.97 4.03 9 9 9s9-4.03 9-9c0-2.74-1.23-5.18-3.17-6.83z"}),"PowerSettingsNew");Zx=Qx.default=Eae;var eC={},Tae=cn;Object.defineProperty(eC,"__esModule",{value:!0});var P3=eC.default=void 0,kae=Tae(Cn()),Aae=En,_ae=(0,kae.default)((0,Aae.jsx)("path",{d:"M23 5.5V20c0 2.2-1.8 4-4 4h-7.3c-1.08 0-2.1-.43-2.85-1.19L1 14.83s1.26-1.23 1.3-1.25c.22-.19.49-.29.79-.29.22 0 .42.06.6.16.04.01 4.31 2.46 4.31 2.46V4c0-.83.67-1.5 1.5-1.5S11 3.17 11 4v7h1V1.5c0-.83.67-1.5 1.5-1.5S15 .67 15 1.5V11h1V2.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5V11h1V5.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5z"}),"PanTool");P3=eC.default=_ae;var tC={},Rae=cn;Object.defineProperty(tC,"__esModule",{value:!0});var I3=tC.default=void 0,Pae=Rae(Cn()),Iae=En,$ae=(0,Pae.default)((0,Iae.jsx)("path",{d:"m22.7 19-9.1-9.1c.9-2.3.4-5-1.5-6.9-2-2-5-2.4-7.4-1.3L9 6 6 9 1.6 4.7C.4 7.1.9 10.1 2.9 12.1c1.9 1.9 4.6 2.4 6.9 1.5l9.1 9.1c.4.4 1 .4 1.4 0l2.3-2.3c.5-.4.5-1.1.1-1.4z"}),"Build");I3=tC.default=$ae;const Oae=e=>{switch(e){case cae:return Hb;case lae:return R3;case dae:return Zx;case uae:return I3;case pae:return P3;default:return Hb}},nC=(e={})=>{const t=async()=>{const c=Dt("api/admin/feature-types");return(await fetch(c,{method:"GET"}).then(yn("Feature types"))).json()},n="api/admin/feature-types",{data:r,error:o}=dn(n,t,e),[a,i]=p.useState(!o&&!r),l=()=>{Vr(n)};return p.useEffect(()=>{i(!o&&!r)},[r,o]),{featureTypes:(r==null?void 0:r.types)||[],error:o,loading:a,refetch:l}},Lae=C("div")(({theme:e})=>({padding:e.spacing(1.5),display:"flex",justifyContent:"center",alignItems:"center",color:e.palette.text.disabled})),$3=({value:e})=>{const{featureTypes:t}=nC(),n=Oae(e),o=`This is a "${t.filter(a=>a.id===e).map(a=>a.name)||e}" toggle`;return s(Lae,{children:s(_t,{arrow:!0,title:o,describeChild:!0,children:s(n,{"data-loading":!0})})})},Nae=({row:e})=>s(Is,{title:e.original.name,subtitle:e.original.description,to:`/projects/${e.original.project}/features/${e.original.name}`}),O3=e=>{const{setAnnouncement:t}=p.useContext(Vx);p.useEffect(()=>{if(e)return document.title=e,()=>{document.title=zA}},[e]),p.useEffect(()=>{e&&e!==zA&&t(`Navigated to ${e}`)},[t,e])},zA="Unleash",Mae=C(mo)(({theme:e})=>({height:"100%",borderColor:e.palette.dividerAlternative,width:"1px",display:"inline-block",marginLeft:e.spacing(2),marginRight:e.spacing(2),padding:e.spacing(.5,0),verticalAlign:"middle"})),Dae=C("div")(()=>({display:"flex",flexDirection:"column"})),Bae=C("div")(()=>({display:"flex",justifyContent:"space-between",alignItems:"center",position:"relative"})),Fae=C("div")(({theme:e})=>({overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",marginRight:e.spacing(2)})),zae=C(ye)(({theme:e})=>({fontSize:e.fontSizes.mainHeader,fontWeight:"normal"})),jae=C("div")(({theme:e})=>({display:"flex",flexGrow:1,justifyContent:"flex-end",alignItems:"center",gap:e.spacing(1)})),L3=({title:e,titleElement:t,actions:n,subtitle:r,variant:o,loading:a,className:i="",secondary:l,children:c})=>{const u=Ca({skeleton:a});return O3(l?"":e),T(Dae,{children:[T(Bae,{children:[T(Fae,{className:Ca(u),"data-loading":!0,children:[s(zae,{variant:o||l?"h2":"h1",className:Ca(i),children:t||e}),r&&s("small",{children:r})]}),s(X,{condition:Boolean(n),show:s(jae,{children:n})})]}),c]})},Uae=({sx:e})=>s(Mae,{orientation:"vertical",variant:"middle",sx:e});L3.Divider=Uae;const xn=L3,Wae=Li()(e=>({headerPadding:{padding:e.spacing(2,4)},bodyContainer:{padding:e.spacing(4),[e.breakpoints.down("md")]:{padding:e.spacing(2)},overflowX:"auto"},paddingDisabled:{padding:"0"},borderDisabled:{border:"none"}})),Sv=(e,t="[data-loading=true]")=>{const n=p.createRef();return p.useLayoutEffect(()=>{n.current&&n.current.querySelectorAll(t).forEach(o=>{e?o.classList.add("skeleton"):o.classList.remove("skeleton")})},[e,n]),n},Hae=C("div")(({theme:e})=>({borderBottomStyle:"solid",borderBottomWidth:"1px",borderBottomColor:e.palette.divider,[e.breakpoints.down("md")]:{padding:e.spacing(3,2)}})),Vae=C(pr)(({theme:e})=>({borderRadius:e.shape.borderRadiusLarge,boxShadow:"none"})),Gae=({children:e,isLoading:t})=>{const n=Sv(t);return s("div",{ref:n,"aria-busy":t,"aria-live":"polite",children:e})},fr=({children:e,header:t,disablePadding:n=!1,disableBorder:r=!1,bodyClass:o="",headerClass:a="",isLoading:i=!1,disableLoading:l=!1,className:c,...u})=>{const{classes:d}=Wae(),f=Ca("header",a||d.headerPadding,{[d.paddingDisabled]:n,[d.borderDisabled]:r}),h=Ca("body",o||d.bodyContainer,{[d.paddingDisabled]:n,[d.borderDisabled]:r}),y=T(Vae,{...u,...r?{elevation:0}:{},className:Ca(c),children:[s(X,{condition:Boolean(t),show:s(Hae,{className:f,children:s(X,{condition:typeof t=="string",show:s(xn,{title:t}),elseShow:t})})}),s("div",{className:h,children:e})]});return l?y:s(Gae,{isLoading:i,children:y})},lu=(e,t)=>{const n=`${Oi}:${e}:localStorage:v2`;return{value:(()=>{const a=gp(n);return a===void 0?t:a})(),setValue:a=>{if(a instanceof Function){const i=gp(n),l=a(i??t);return zc(n,l),l}return zc(n,a),a}}},Bi=(e={})=>{const t=()=>{const c=Dt("api/admin/projects");return fetch(c,{method:"GET"}).then(yn("Projects")).then(u=>u.json())},n="api/admin/projects",{data:r,error:o}=dn(n,t,e),[a,i]=p.useState(!o&&!r),l=()=>{Vr(n)};return p.useEffect(()=>{i(!o&&!r)},[r,o]),{projects:(r==null?void 0:r.projects)||[],error:o,loading:a,refetch:l}},Fh="default",qae=()=>{var n;const{projects:e=[]}=Bi(),t=e.find(r=>r.id===Fh);return(t==null?void 0:t.id)||((n=e[0])==null?void 0:n.id)},Nm=(e,t)=>`/projects/${e}/features/${t}`,Kae=(e,t)=>{const n=`/projects/${e}/create-toggle`;let r;return t&&(r=Object.keys(t).reduce((o,a)=>(o+=`${a}=${t[a]}`,o),"")),r?`${n}?${r}`:n},Yae=e=>`/projects/${e}/edit`,Xae=e=>{const t=qae(),n=e.project==="*"||!e.project?t:e.project;if(n)return{path:Kae(n),projectId:n}},Jae=C("div")(({theme:e})=>({overflow:"auto",padding:e.spacing(1,1.5)})),Qae=C(({className:e,maxWidth:t,maxHeight:n,fontSize:r,...o})=>s(_t,{...o,title:s(Jae,{children:o.title}),classes:{popper:e}}),{shouldForwardProp:e=>e!=="maxWidth"&&e!=="maxHeight"&&e!=="fontSize"})(({theme:e,maxWidth:t=e.spacing(37.5),maxHeight:n=e.spacing(37.5),fontSize:r=e.fontSizes.smallerBody})=>({maxWidth:t,[`& .${Wa.tooltip}`]:{display:"flex",flexDirection:"column",backgroundColor:e.palette.background.paper,padding:0,borderRadius:e.shape.borderRadiusMedium,boxShadow:e.shadows[2],color:e.palette.text.primary,fontWeight:e.fontWeight.medium,maxWidth:"inherit",border:`1px solid ${e.palette.lightBorder}`,maxHeight:n,fontSize:r},[`& .${Wa.arrow}`]:{"&:before":{border:`1px solid ${e.palette.lightBorder}`},color:e.palette.background.paper}})),xv=e=>s(Qae,{...e,children:e.children}),cu=({title:e,children:t,variant:n="default",titleComponent:r,...o})=>!e&&!r?t:n==="custom"?s(xv,{...o,title:e||r,arrow:!0,children:t}):s(_t,{...o,title:e||r,arrow:!0,children:t}),Vb="Access denied",Cv=(e,t)=>e?t:t?`${t} (${Vb})`:Vb,Zae=()=>{throw new Error("hasAccess called outside AccessContext")},Gr=jt.createContext({isAdmin:!1,hasAccess:Zae}),Ev=(e,t,n,r,o={})=>{const a=dn(e?n:null,r,o);return{...a,error:e?a.error:void 0,data:e?a.data:t}},eie=e=>{const{isEnterprise:t}=Lt(),{data:n,error:r,mutate:o}=Ev(Boolean(e)&&t(),[],Dt(`api/admin/projects/${e}/change-requests/config`),tie);return{data:n||[],loading:!r&&!n,refetchChangeRequestConfig:o,error:r}},tie=e=>fetch(e).then(yn("Request changes")).then(t=>t.json()),of=e=>{const{data:t}=eie(e),n=jt.useCallback(o=>t.some(a=>a.environment===o&&a.changeRequestEnabled),[JSON.stringify(t)]),r=jt.useCallback(()=>t.some(o=>o.changeRequestEnabled),[JSON.stringify(t)]);return{isChangeRequestConfigured:n,isChangeRequestConfiguredInAnyEnv:r}},rC=e=>{const{hasAccess:t}=p.useContext(Gr),n=(o,a,i)=>a&&i?t(o,a,i):a?t(o,a):t(o),r=(o,a,i)=>Array.isArray(o)?o.some(l=>n(l,a,i)):n(o,a,i);return(o,a)=>r(o,e,a)},hIe=e=>{const{isChangeRequestConfigured:t}=of(e),n=rC(e);return(r,o)=>t(o)||n(r,o)},nie=[g3,Wx,Mne,Dne,Bne],rie=(e,t)=>e.filter(n=>t.includes(n)).length>0,Wc=(e,t,n)=>{const{isChangeRequestConfigured:r}=of(t),o=rC(t);return r(n)&&rie(nie,[].concat(e))||o(e,n)},oC=(e,t,n)=>rC(t)(e,n),oie=jt.forwardRef((e,t)=>{const n=Wc(e.permission,e.projectId,e.environmentId);return s(N3,{...e,access:n,ref:t})}),aie=jt.forwardRef((e,t)=>{const n=oC(e.permission,e.projectId,e.environmentId);return s(N3,{...e,access:n,ref:t})}),N3=jt.forwardRef(({permission:e,access:t,variant:n="contained",color:r="primary",onClick:o,children:a,disabled:i,projectId:l,environmentId:c,tooltipProps:u,...d},f)=>{const h=Ss();return s(cu,{...u,title:Cv(t,u==null?void 0:u.title),arrow:!0,children:s("span",{id:h,children:s(Ze,{ref:f,onClick:o,disabled:i||!t,"aria-labelledby":h,variant:n,color:r,...d,endIcon:s(ke,{children:s(X,{condition:!t,show:s(jZ,{titleAccess:"Locked"}),elseShow:Boolean(d.endIcon)&&d.endIcon})}),children:a})})})}),zo=jt.forwardRef((e,t)=>typeof e.projectId<"u"&&typeof e.environmentId<"u"?s(oie,{...e,environmentId:e.environmentId,projectId:e.projectId,ref:t}):s(aie,{...e,ref:t})),iie=e=>{const t=oC(e.permission,e.projectId,e.environmentId);return s(M3,{...e,access:t})},sie=e=>{const t=Wc(e.permission,e.projectId,e.environmentId);return s(M3,{...e,access:t})},M3=({access:e,permission:t,projectId:n,children:r,environmentId:o,tooltipProps:a,disabled:i,...l})=>{const c=Ss();return s(cu,{...a,title:Cv(e,a==null?void 0:a.title),arrow:!0,onClick:u=>u.preventDefault(),children:s("div",{id:c,children:s(Yt,{...l,disabled:!e||i,"aria-labelledby":c,size:"large",children:r})})})},ur=e=>typeof e.projectId<"u"&&typeof e.environmentId<"u"?s(sie,{...e,projectId:e.projectId,environmentId:e.environmentId}):s(iie,{...e}),lie=({loading:e,filter:t})=>{const n=cr("(max-width:800px)"),r=Xae(t),o=lt();return r?s(X,{condition:n,show:s(ur,{permission:wp,projectId:r.projectId,component:ln,to:r.path,size:"large",tooltipProps:{title:"Create feature toggle"},children:s(Ta,{})}),elseShow:s(zo,{onClick:()=>{o(r.path)},permission:wp,projectId:r.projectId,color:"primary",variant:"contained","data-testid":see,className:Ca({skeleton:e}),children:"New feature toggle"})}):null},cie=e=>({color:e.palette.error.dark,fontSize:"inherit"}),uie=e=>({color:e.palette.success.dark,fontSize:"inherit"}),die=C(Me)(({theme:e})=>({padding:e.spacing(1.5,2)})),D3=({value:e})=>s(die,{children:s(X,{condition:Boolean(e),show:s(ye,{component:"span",sx:cie,"data-loading":!0,children:"Stale"}),elseShow:s(ye,{component:"span",sx:uie,"data-loading":!0,children:"Active"})})}),Tv=(e,t,n)=>{const r=B3(e),o=()=>({data:n,searchValue:t,columns:e});return t?{data:(()=>{const i=pie(e,t,n);return fie(e,r(t),i)})(),getSearchText:r,getSearchContext:o}:{data:n,getSearchText:r,getSearchContext:o}},pie=(e,t,n)=>{let r=n;return z3(e).filter(o=>F3(t,o.filterName)).forEach(o=>{const a=j3(o.filterName,t);r=r.filter(i=>o.filterBy?o.filterBy(i,a):hie(Mm(o,i),a))}),r},fie=(e,t,n)=>{const r=e.filter(o=>o.searchable&&o.accessor);return n.filter(o=>r.some(a=>a.searchBy?a.searchBy(o,t):mie(Mm(a,o),t)))},hie=(e,t)=>t.some(n=>(e==null?void 0:e.toLowerCase())===(n==null?void 0:n.toLowerCase())),mie=(e,t)=>e==null?void 0:e.toLowerCase().includes(t==null?void 0:t.toLowerCase()),B3=e=>{const t=e.filter(r=>r.filterName).map(r=>r.filterName),n=r=>t.some(o=>F3(r,o));return r=>r.split(" ").filter(o=>!n(o)).join(" ")},F3=(e,t)=>new RegExp(`${t}:\\w+`).test(e),z3=e=>e.filter(t=>t.filterName&&t.accessor),Mm=(e,t)=>{const n=typeof e.accessor=="function"?e.accessor(t):e.accessor.includes(".")?e.accessor.split(".").reduce((r,o)=>r==null?void 0:r[o],t):t[e.accessor];return e.filterParsing?e.filterParsing(n):n},j3=(e,t)=>{var n,r;return((r=(n=t==null?void 0:t.split(`${e}:`)[1])==null?void 0:n.split(" ")[0])==null?void 0:r.split(",").filter(o=>o))??[]},jA=C("span")(({theme:e})=>({fontSize:e.fontSizes.smallBody,color:e.palette.text.primary})),UA=C("span")(({theme:e})=>({backgroundColor:e.palette.secondaryContainer,color:e.palette.text.primary,padding:e.spacing(0,.5),borderRadius:e.spacing(.5)})),gie=({filters:e,getSearchContext:t,searchableColumnsString:n})=>{const r=t(),a=B3(r.columns)(r.searchValue),i=e.filter(l=>l.values.length>0);return T(ke,{children:[s(X,{condition:Boolean(a),show:T(ke,{children:[s(jA,{children:"Searching for:"}),T("p",{children:[s(UA,{children:a})," ",n?` in ${n}`:""]})]})}),s(X,{condition:i.length>0,show:T(ke,{children:[s(jA,{children:"Filtering by:"}),i.map(l=>T("p",{children:[s(UA,{children:l.values.join(",")})," ","in ",l.header,". Options:"," ",l.options.join(", ")]},l.name))]})})]})},vie=C("span")(({theme:e})=>({fontSize:e.fontSizes.smallBody,color:e.palette.text.primary})),WA=C("span")(({theme:e})=>({backgroundColor:e.palette.secondaryContainer,color:e.palette.text.primary,padding:e.spacing(0,.5),borderRadius:e.spacing(.5)})),yie=({filters:e,getSearchContext:t,searchableColumnsString:n})=>T(ke,{children:[s(vie,{children:e.length>0?"Filter your search with operators like:":`Start typing to search${n?` in ${n}`:"..."}`}),e.map(r=>T("p",{children:["Filter by ",r.header,":"," ",T(WA,{children:[r.name,":",r.options[0]]}),s(X,{condition:r.options.length>1,show:T(ke,{children:[" or ",T(WA,{children:[r.name,":",r.options.slice(0,2).join(",")]})]})})]},r.name))]}),bie=e=>Math.floor(Math.random()*e.length),wie=C(pr)(({theme:e})=>({position:"absolute",width:"100%",left:0,top:"20px",zIndex:2,padding:e.spacing(4,1.5,1.5),borderBottomLeftRadius:e.spacing(1),borderBottomRightRadius:e.spacing(1),boxShadow:"0px 8px 20px rgba(33, 33, 33, 0.15)",fontSize:e.fontSizes.smallBody,color:e.palette.text.secondary,wordBreak:"break-word"})),Sie=C(Me)(({theme:e})=>({display:"flex",gap:e.spacing(2)})),xie=C(LZ)(({theme:e})=>({color:e.palette.text.secondary})),Cie=C(mo)(({theme:e})=>({border:`1px dashed ${e.palette.dividerAlternative}`,margin:e.spacing(1.5,0)})),Eie=C("span")(({theme:e})=>({backgroundColor:e.palette.secondaryContainer,color:e.palette.text.primary,padding:e.spacing(0,.5),borderRadius:e.spacing(.5)})),Tie=({getSearchContext:e})=>{const t=e(),n=p.useMemo(()=>bie(t.data),[t.data]),r=z3(t.columns).map(l=>{const c=t.data.map(u=>Mm(l,u));return{name:l.filterName,header:l.Header??l.filterName,options:[...new Set(c)].sort((u,d)=>u.localeCompare(d)),suggestedOption:c[n]??`example-${l.filterName}`,values:j3(l.filterName,t.searchValue)}}).sort((l,c)=>l.name.localeCompare(c.name)),o=t.columns.filter(l=>l.searchable&&l.accessor),a=o.map(l=>l.Header??l.accessor).join(", "),i=t.data.length&&o.length?Mm(o[0],t.data[n]):"example-search-text";return T(wie,{children:[T(Sie,{children:[s(xie,{}),s(Me,{children:s(X,{condition:Boolean(t.searchValue),show:s(gie,{filters:r,getSearchContext:e,searchableColumnsString:a}),elseShow:s(yie,{filters:r,getSearchContext:e,searchableColumnsString:a})})})]}),s(Cie,{}),s(X,{condition:r.length>0,show:"Combine filters and search."}),T("p",{children:["Example:"," ",T(Eie,{children:[r.map(l=>T("span",{children:[l.name,":",l.suggestedOption," "]},l.name)),s("span",{children:i})]})]})]})},kie=()=>{const[e,t]=p.useState();return p.useEffect(()=>{var r;const n=((r=navigator==null?void 0:navigator.userAgentData)==null?void 0:r.platform)||(navigator==null?void 0:navigator.platform)||"unknown";t(n.toLowerCase().includes("mac")||n==="iPhone"||n==="iPad")},[]),e},HA=({key:e,modifiers:t=[],preventDefault:n=!1},r)=>{const o=kie();p.useEffect(()=>{const l=c=>{if(e===c.key){if(t.includes("ctrl")){if(o){if(!c.metaKey)return}else if(!c.ctrlKey)return}t.includes("alt")&&!c.altKey||t.includes("shift")&&!c.shiftKey||(n&&c.preventDefault(),r())}};return window.addEventListener("keydown",l),()=>{window.removeEventListener("keydown",l)}},[o,e,t,n,r]);const a=p.useMemo(()=>t.map(l=>({ctrl:o?"⌘":"Ctrl",alt:"Alt",shift:"Shift"})[l]),[o,t]);return p.useMemo(()=>[...a,`${e[0].toUpperCase()}${e.slice(1)}`].join("+"),[a,e])},Aie=C("div")(({theme:e})=>({display:"flex",flexGrow:1,alignItems:"center",position:"relative",backgroundColor:e.palette.background.paper,maxWidth:"400px",[e.breakpoints.down("md")]:{marginTop:e.spacing(1),maxWidth:"100%"}})),_ie=C("div")(({theme:e})=>({display:"flex",alignItems:"center",backgroundColor:e.palette.background.paper,border:`1px solid ${e.palette.neutral.border}`,borderRadius:e.shape.borderRadiusExtraLarge,padding:"3px 5px 3px 12px",width:"100%",zIndex:3,"&:focus-within":{borderColor:e.palette.primary.light,boxShadow:e.boxShadows.main}})),Rie=C(ov)(({theme:e})=>({width:"100%"})),Pie=C(uv)(({theme:e})=>({color:e.palette.neutral.main,fontSize:e.typography.body1.fontSize})),Hr=({initialValue:e="",onChange:t,className:n,placeholder:r,hasFilters:o,disabled:a,getSearchContext:i,containerStyles:l,debounceTime:c=200})=>{const u=p.useRef(),[d,f]=p.useState(!1),[h,m]=p.useState(e),y=Kt.useAsyncDebounce(t,c),g=w=>{y(w),m(w)},v=HA({modifiers:["ctrl"],key:"k",preventDefault:!0},()=>{var w,x;document.activeElement===u.current?(w=u.current)==null||w.blur():(x=u.current)==null||x.focus()});HA({key:"Escape"},()=>{var w;document.activeElement===u.current&&((w=u.current)==null||w.blur())});const b=`${r??"Search"} (${v})`;return T(Aie,{style:l,children:[T(_ie,{className:n,children:[s(Sx,{sx:{mr:1,color:w=>w.palette.inactiveIcon}}),s(Rie,{inputRef:u,placeholder:b,inputProps:{"aria-label":b},value:h,onChange:w=>g(w.target.value),onFocus:()=>f(!0),onBlur:()=>f(!1),disabled:a}),s(Me,{sx:{width:w=>w.spacing(4)},children:s(X,{condition:Boolean(h),show:s(_t,{title:"Clear search query",arrow:!0,children:s(Yt,{size:"small",onClick:()=>{var w;g(""),(w=u.current)==null||w.focus()},sx:{padding:w=>w.spacing(1)},children:s(Pie,{})})})})})]}),s(X,{condition:Boolean(o)&&d,show:s(Tie,{getSearchContext:i})})]})},Iie=C(go,{shouldForwardProp:e=>e!=="highlighted"})(({theme:e,highlighted:t})=>({backgroundColor:t?e.palette.highlight:"transparent",color:e.palette.text.primary,textDecorationColor:e.palette.text.disabled,textDecorationStyle:"dashed",textUnderlineOffset:e.spacing(.5)})),$ie=({tooltip:e,highlighted:t,tooltipProps:n,children:r,...o})=>s(xv,{title:e,...n,arrow:!0,children:s(Iie,{highlighted:t,...o,children:r})}),Oie=C(ye)(({theme:e})=>({fontSize:e.fontSizes.smallerBody})),Lie=({row:e,value:t})=>{var r,o,a;const{searchQuery:n}=su();return!e.original.tags||e.original.tags.length===0?s(eo,{}):s(eo,{children:s($ie,{highlighted:n.length>0&&t.toLowerCase().includes(n.toLowerCase()),tooltip:s(ke,{children:(r=e.original.tags)==null?void 0:r.map(i=>s(Oie,{children:s(yl,{search:n,children:`${i.type}:${i.value}`})},i.type+i.value))}),children:((o=e.original.tags)==null?void 0:o.length)===1?"1 tag":`${(a=e.original.tags)==null?void 0:a.length} tags`})})},Aa={date:(e,t,n,r)=>{var i,l;const o=new Date(((i=e==null?void 0:e.values)==null?void 0:i[n])||0),a=new Date(((l=t==null?void 0:t.values)==null?void 0:l[n])||0);return(a==null?void 0:a.getTime())-(o==null?void 0:o.getTime())},boolean:(e,t,n,r)=>{var i,l;const o=(i=e==null?void 0:e.values)==null?void 0:i[n],a=(l=t==null?void 0:t.values)==null?void 0:l[n];return o===a?0:o?1:-1},alphanumeric:(e,t,n,r)=>{var i,l;const o=`${((i=e==null?void 0:e.values)==null?void 0:i[n])||""}`.toLowerCase(),a=`${((l=t==null?void 0:t.values)==null?void 0:l[n])||""}`.toLowerCase();return o==null?void 0:o.localeCompare(a)},playgroundResultState:(e,t,n,r)=>{var i,l;const o=(i=e==null?void 0:e.values)==null?void 0:i[n],a=(l=t==null?void 0:t.values)==null?void 0:l[n];return o===a?0:o==="true"?1:a==="true"||o==="false"?-1:a==="false"?1:0}},Nie=Object.assign({},...Object.entries(Aa).map(([e,t])=>({[e]:(n,r,o,a)=>{var i,l,c,u;return(i=n==null?void 0:n.original)!=null&&i.favorite&&!((l=r==null?void 0:r.original)!=null&&l.favorite)?a?1:-1:!((c=n==null?void 0:n.original)!=null&&c.favorite)&&((u=r==null?void 0:r.original)!=null&&u.favorite)?a?-1:1:t(n,r,o,a)}}))),Mie=(e=!1)=>{const[t,n]=p.useState(e),{trackEvent:r}=ka(),o=i=>{r("favorite",{props:{eventType:`features ${i?"":"un"}pinned `}}),n(i)},a=p.useMemo(()=>t?Nie:Aa,[t]);return{isFavoritesPinned:t,onChangeIsFavoritePinned:o,sortTypes:a}},It=()=>{const{setToast:e}=p.useContext(Ps),t=()=>e(o=>({...o,show:!1})),n=p.useCallback((o,a)=>{e({title:"Something went wrong",text:o,type:"error",show:!0,autoHideDuration:12e3,...a})},[e]);return{setToastData:p.useCallback(o=>{o.persist?e({...o,show:!0}):e({...o,show:!0,autoHideDuration:6e3})},[e]),setToastApiError:n,hideToast:t}},ft=e=>e instanceof Error?e.message||e.toString():typeof e=="string"?e:"Unknown error",Nn=({handleBadRequest:e,handleNotFound:t,handleForbidden:n,handleUnauthorized:r,propagateErrors:o=!1})=>{const[a,i]=p.useState({}),[l,c]=p.useState(!1),u=p.useCallback(async(h,m)=>{var y;if(h.status===Ex){if(e)return e(i,h,m);if(i(g=>({...g,badRequest:"Bad request format"})),o){const g=await h.json();throw new Tx(h.status,g)}}if(h.status===B4){if(t)return t(i,h,m);if(i(g=>({...g,notFound:"Could not find the requested resource"})),o)throw new kx(h.status)}if(h.status===z4){if(r)return r(i,h,m);if(i(g=>({...g,unauthorized:Vb})),o)throw new j4(h.status)}if(h.status===F4){if(n)return n(i,h,m);if(i(g=>({...g,forbidden:"This operation is forbidden"})),o){const g=await h.json();throw new eee(h.status,g)}}if(h.status>399){const g=await h.json();if(((y=g==null?void 0:g.details)==null?void 0:y.length)>0&&o){const v=g.details[0];if(o)throw new Error(v.message||v.msg);return v}if((g==null?void 0:g.length)>0&&o){const v=g[0];throw new Error(v.message||v.msg)}if(o)throw new Error("Action could not be performed")}},[e,n,t,r,o]),d=p.useCallback(async(h,m,y=!0)=>{y&&c(!0);try{const g=await h();return c(!1),g.status>299&&await u(g,m),g.status===Jp&&i({}),g}catch(g){throw c(!1),g}},[u]),f=p.useCallback((h,m,y="")=>{const g={headers:Mb,credentials:"include"};return{caller:()=>fetch(Dt(h),{...g,...m}),id:y}},[]);return{loading:l,makeRequest:d,createRequest:f,errors:a}},Die=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0}),{setToastData:o,setToastApiError:a}=It(),{trackEvent:i}=ka(),l=p.useCallback(async(u,d)=>{const f=`api/admin/projects/${u}/features/${d}/favorites`,h=t(f,{method:"POST"},"addFavoriteFeature");try{await e(h.caller,h.id),o({title:"Toggle added to favorites",type:"success"}),i("favorite",{props:{eventType:"feature favorited"}})}catch(m){a(ft(m))}},[t,e]),c=p.useCallback(async(u,d)=>{const f=`api/admin/projects/${u}/features/${d}/favorites`,h=t(f,{method:"DELETE"},"removeFavoriteFeature");try{await e(h.caller,h.id),o({title:"Toggle removed from favorites",type:"success"}),i("favorite",{props:{eventType:"feature unfavorited"}})}catch(m){a(ft(m))}},[t,e]);return{favorite:l,unfavorite:c,errors:n,loading:r}},Bie=C(Me)(({theme:e})=>({paddingLeft:e.spacing(1.25)})),U3=C(Yt)(({theme:e})=>({color:e.palette.primary.main,padding:e.spacing(1.25)})),Fie=C(U3)({opacity:0}),zie=({value:e,onClick:t})=>s(Bie,{children:s(X,{condition:Boolean(e),show:s(U3,{onClick:t,size:"small",children:s(xx,{fontSize:"small"})}),elseShow:s(Fie,{className:"show-row-hover",onClick:t,size:"small",children:s(Cx,{fontSize:"small"})})})}),jie=({isActive:e=!1,onClick:t})=>{const[n,r]=p.useState(e);return s(cu,{title:n?"Unpin favorite features from the top":"Pin favorite features to the top",children:s(Yt,{sx:{mx:-.75,display:"flex",alignItems:"center",justifyContent:"center",padding:1.25},onClick:()=>{r(!n),t(!n)},size:"small",children:s(X,{condition:n,show:s(xx,{fontSize:"small"}),elseShow:s(Cx,{fontSize:"small"})})})})},Uie=()=>{const{value:e,setValue:t}=lu("global:v1",{});return{value:e,setValue:t}},af=(e,t,n)=>{p.useEffect(()=>{const r=e.filter(({condition:a})=>a).flatMap(({columns:a})=>a),o=e.flatMap(({columns:a})=>a).filter(a=>!r.includes(a));t(a=>[...new Set([...a,...r].filter(i=>!o.includes(i)))])},[...e.map(({condition:r})=>r),t,n])};var aC={},Wie=cn;Object.defineProperty(aC,"__esModule",{value:!0});var W3=aC.default=void 0,Hie=Wie(Cn()),Vie=En,Gie=(0,Hie.default)((0,Vie.jsx)("path",{d:"M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"}),"FileDownload");W3=aC.default=Gie;const uu=()=>{const{data:e,error:t,mutate:n}=dn(Dt("api/admin/environments"),qie),r=p.useMemo(()=>e||[],[e]),o=p.useCallback(async()=>{await n()},[n]),a=p.useCallback(async i=>{await n(i,!1)},[n]);return{environments:r,refetchEnvironments:o,mutateEnvironments:a,loading:!t&&!e,error:t}},qie=async e=>(await fetch(e).then(yn("Environments")).then(n=>n.json())).environments.sort((n,r)=>n.sortOrder-r.sortOrder),du=({name:e,value:t="",label:n="",options:r,onChange:o,id:a,disabled:i=!1,className:l,classes:c,fullWidth:u,...d})=>T(Pi,{variant:"outlined",size:"small",classes:c,fullWidth:u,children:[s(Yp,{htmlFor:a,children:n}),s(Xp,{name:e,disabled:i,onChange:h=>{h.preventDefault(),o(String(h.target.value))},className:l,label:n,id:a,value:t,IconComponent:Nb,...d,children:r.map(h=>s(bs,{sx:h.sx,value:h.key,title:h.title||"","data-testid":`${V4}-${h.label}`,disabled:h.disabled,children:h.label},h.key))})]}),Kie=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0}),{trackEvent:o}=ka();return{loading:r,errors:n,createExport:async i=>{const c=t("api/admin/features-batch/export",{method:"POST",body:JSON.stringify(i)});try{const u=await e(c.caller,c.id);return o("export_import",{props:{eventType:"features exported"}}),u}catch(u){throw u}}}},Yie=C(du)(({theme:e})=>({minWidth:"250px",marginTop:e.spacing(2)})),Xie=({showExportDialog:e,data:t,onClose:n,environments:r})=>{const[o,a]=p.useState(r[0]),{createExport:i}=Kie(),l=p.createRef(),{setToastApiError:c}=It(),u=()=>r.map(m=>({key:m,label:m})),d=()=>({features:t.map(m=>m.name),environment:o}),f=m=>{var w,x;const y=document.createElement("a");(w=l.current)==null||w.appendChild(y),y.style.display="display: none";const g=new Blob([JSON.stringify(m)],{type:"application/json"}),v=window.URL.createObjectURL(g);y.href=v;const b=new Date;y.download=`${b.toISOString()}-export.json`,y.click(),window.URL.revokeObjectURL(v),(x=l.current)==null||x.removeChild(y)};return s(Zn,{open:e,title:"Export feature toggle configuration",onClose:n,onClick:async()=>{try{const m=d(),g=await(await i(m)).json();f(g),n()}catch(m){c(ft(m))}},primaryButtonText:"Export selection",secondaryButtonText:"Cancel",children:T(Me,{ref:l,children:["The current search filter will be used to export feature toggles. Currently ",t.length," feature toggles will be exported.",s("br",{}),s("br",{}),s(ye,{children:"Select which environment to export feature toggle configuration from:"}),s(Yie,{options:u(),value:o,onChange:m=>a(m)})]})})},H3=Array(15).fill({name:"Name of the feature",description:"Short description of the feature",type:"-",createdAt:new Date(2022,1,1),project:"projectID"}),Jie={id:"createdAt"},{value:VA,setValue:Qie}=lu("FeatureToggleListTable:v1",Jie),Zie=()=>{var Z,W;const e=on(),{environments:t}=uu(),n=t.filter(z=>z.enabled).map(z=>z.name),r=cr(e.breakpoints.down("md")),o=cr(e.breakpoints.down("lg")),[a,i]=p.useState(!1),{features:l=[],loading:c,refetchFeatures:u}=Gx(),[d,f]=tu(),{uiConfig:h}=Lt(),[m]=p.useState(()=>({sortBy:[{id:d.get("sort")||VA.id,desc:d.has("order")?d.get("order")==="desc":VA.desc}],hiddenColumns:["description"],globalFilter:d.get("search")||""})),{value:y,setValue:g}=Uie(),{isFavoritesPinned:v,sortTypes:b,onChangeIsFavoritePinned:w}=Mie(d.has("favorites")?d.get("favorites")==="true":y.favorites),[x,E]=p.useState(m.globalFilter),{favorite:A,unfavorite:k}=Die(),_=p.useCallback(async z=>{z!=null&&z.favorite?await k(z.project,z.name):await A(z.project,z.name),u()},[A,u,k]),$=p.useMemo(()=>[{Header:s(jie,{isActive:v,onClick:w}),accessor:"favorite",Cell:({row:{original:z}})=>s(zie,{value:z==null?void 0:z.favorite,onClick:()=>_(z)}),maxWidth:50,disableSortBy:!0},{Header:"Seen",accessor:"lastSeenAt",Cell:_3,sortType:"date",align:"center",maxWidth:85},{Header:"Type",accessor:"type",Cell:$3,align:"center",maxWidth:85},{Header:"Name",accessor:"name",minWidth:150,Cell:Nae,sortType:"alphanumeric",searchable:!0},{id:"tags",Header:"Tags",accessor:z=>{var R;return((R=z.tags)==null?void 0:R.map(({type:M,value:ee})=>`${M}:${ee}`).join(`
|
|
267
|
+
`))||""},Cell:Lie,width:80,searchable:!0},{Header:"Created",accessor:"createdAt",Cell:Cp,sortType:"date",maxWidth:150},{Header:"Project ID",accessor:"project",Cell:({value:z})=>s(Is,{title:z,to:`/projects/${z}`}),sortType:"alphanumeric",maxWidth:150,filterName:"project",searchable:!0},{Header:"State",accessor:"stale",Cell:D3,sortType:"boolean",maxWidth:120,filterName:"state",filterParsing:z=>z?"stale":"active"},{accessor:"description",Header:"Description",searchable:!0}],[v]),{data:L,getSearchText:O,getSearchContext:P}=Tv($,x,l),D=p.useMemo(()=>(L==null?void 0:L.length)===0&&c?H3:L,[L,c]),{headerGroups:F,rows:U,prepareRow:Y,state:{sortBy:V},setHiddenColumns:te}=Kt.useTable({columns:$,data:D,initialState:m,sortTypes:b,autoResetHiddenColumns:!1,autoResetSortBy:!1,disableSortRemove:!0,disableMultiSort:!0},Kt.useSortBy,Kt.useFlexLayout);return af([{condition:!l.some(({tags:z})=>z==null?void 0:z.length),columns:["tags"]},{condition:r,columns:["type","createdAt","tags"]},{condition:o,columns:["lastSeenAt","stale"]}],te,$),p.useEffect(()=>{const z={};z.sort=V[0].id,V[0].desc&&(z.order="desc"),x&&(z.search=x),v&&(z.favorites="true"),f(z,{replace:!0}),Qie({id:V[0].id,desc:V[0].desc||!1}),g(R=>({...R,favorites:Boolean(v)}))},[V,x,f,v]),t.length>0?T(fr,{isLoading:c,header:s(xn,{title:`Feature toggles (${U.length<D.length?`${U.length} of ${D.length}`:D.length})`,actions:T(ke,{children:[s(X,{condition:!r,show:T(ke,{children:[s(Hr,{initialValue:x,onChange:E,hasFilters:!0,getSearchContext:P}),s(xn.Divider,{})]})}),s(go,{component:ln,to:"/archive",underline:"always",sx:{marginRight:2},children:"View archive"}),s(X,{condition:Boolean((Z=h==null?void 0:h.flags)==null?void 0:Z.featuresExportImport),show:s(_t,{title:"Export current selection",arrow:!0,children:s(Yt,{onClick:()=>i(!0),sx:z=>({marginRight:z.spacing(2)}),children:s(W3,{})})})}),s(lie,{loading:!1,filter:{query:"",project:"default"}})]}),children:s(X,{condition:r,show:s(Hr,{initialValue:x,onChange:E,hasFilters:!0,getSearchContext:P})})}),children:[s(Di,{value:O(x),children:s(vv,{rows:U,headerGroups:F,prepareRow:Y})}),s(X,{condition:U.length===0,show:s(X,{condition:(x==null?void 0:x.length)>0,show:T(Un,{children:["No feature toggles found matching “",x,"”"]}),elseShow:s(Un,{children:"No feature toggles available. Get started by adding a new feature toggle."})})}),s(X,{condition:Boolean((W=h==null?void 0:h.flags)==null?void 0:W.featuresExportImport),show:s(Xie,{showExportDialog:a,data:D,onClose:()=>i(!1),environments:n})})]}):null},pu=()=>{const{data:e,error:t}=dn(Gb,ese),n=p.useCallback(()=>{Vr(Gb).catch(console.warn)},[]);return{strategies:(e==null?void 0:e.strategies)||nse,refetchStrategies:n,loading:!t&&!e,error:t}},ese=()=>fetch(Gb).then(yn("Strategy types")).then(e=>e.json()),tse={deprecated:!1,name:"flexibleRollout",displayName:"Gradual rollout",editable:!1,description:"Roll out to a percentage of your userbase, and ensure that the experience is the same for the user on each visit.",parameters:[{name:"rollout",type:"percentage",description:"",required:!1},{name:"stickiness",type:"string",description:"Used to defined stickiness",required:!0},{name:"groupId",type:"string",description:"",required:!0}]},nse=[tse],Gb=Dt("api/admin/strategies"),rse=Dt("api/admin/metrics/applications"),V3=(e={})=>{const t=async()=>fetch(rse,{method:"GET"}).then(yn("Applications data")).then(c=>c.json()),n="api/admin/metrics/applications",{data:r,error:o}=dn(n,t,{...e}),[a,i]=p.useState(!o&&!r),l=()=>{Vr(n)};return p.useEffect(()=>{i(!o&&!r)},[r,o]),{applications:(r==null?void 0:r.applications)||[],error:o,loading:a,refetchApplications:l,APPLICATIONS_CACHE_KEY:n}},ose="_truncate_h6uff_2",ase="_fullwidth_h6uff_8",ise="_sectionPadding_h6uff_12",sse="_horisontalScroll_h6uff_16",lse="_listLink_h6uff_25",cse="_hideLt920_h6uff_37",use="_hideLt600_h6uff_42",dse="_dataTableHeader_h6uff_46",pse="_titleText_h6uff_51",fse="_actions_h6uff_56",hse="_switchWithLabel_h6uff_60",mse="_label_h6uff_63",gse="_emptyState_h6uff_72",vse="_toggleName_h6uff_80",yse="_toolbar_h6uff_85",bse="_toolbarButton_h6uff_91",wse="_error_h6uff_98",Sse="_headerTitle_h6uff_102",xse="_listItem_h6uff_107",Cse="_section_h6uff_12",Ese="_contentPadding_h6uff_115",Tse="_contentSpacing_h6uff_119",kse="_searchField_h6uff_123",Ec={truncate:ose,fullwidth:ase,sectionPadding:ise,horisontalScroll:sse,listLink:lse,hideLt920:cse,hideLt600:use,dataTableHeader:dse,titleText:pse,actions:fse,switchWithLabel:hse,label:mse,switch:"_switch_h6uff_60",emptyState:gse,toggleName:vse,toolbar:yse,toolbarButton:bse,error:wse,headerTitle:Sse,listItem:xse,section:Cse,contentPadding:Ese,contentSpacing:Tse,searchField:kse},iC=({apps:e})=>s(xa,{children:s(X,{condition:e.length>0,show:e.map(({appName:t,description:n,icon:r})=>T(ba,{className:Ec.listItem,children:[s(Xi,{children:s(iv,{children:s(X,{condition:r,show:s(cx,{children:r}),elseShow:s(EZ,{})},`avatar_conditional_${t}`)})}),s(fn,{primary:s(ln,{to:`/applications/${encodeURIComponent(t)}`,className:[Ec.listLink,Ec.truncate].join(" "),children:t}),secondary:n||"No description"})]},t))})});iC.propTypes={apps:ut.array.isRequired};ut.string,ut.any;ut.string,ut.func.isRequired,ut.string;ut.string,ut.object;const Ase=jt.forwardRef(({icon:e,label:t,disabled:n,...r},o)=>T(bs,{disabled:n,style:{display:"flex",alignItems:"center"},...r,children:[s(e,{}),t]}));Ase.propTypes={icon:ut.object,label:ut.string,disabled:ut.bool};const _se="_deprecated_nqviu_10",Rse="_formButtons_nqviu_14",Pse="_header_nqviu_18",Ise="_formContainer_nqviu_32",$se="_inset_nqviu_38",Ose="_parameter_menu_nqviu_42",Lse="_listcontainer_nqviu_52",Nse="_listItem_nqviu_56",Mse={"non-style-button":"_non-style-button_nqviu_1",deprecated:_se,formButtons:Rse,header:Pse,formContainer:Ise,inset:$se,parameter_menu:Ose,listcontainer:Lse,listItem:Nse},Dse=({toggles:e})=>s(xa,{style:{textAlign:"left"},className:Ec.truncate,children:s(X,{condition:e.length>0,show:e.map(({name:t,description:n="-",enabled:r})=>T(ba,{children:[s(Xi,{children:s(X,{condition:Boolean(r),show:s(_t,{title:"Enabled",arrow:!0,children:s(WZ,{"aria-hidden":!1})}),elseShow:s(_t,{title:"Disabled",arrow:!0,children:s(UZ,{"aria-hidden":!1})})})}),s(fn,{primary:s(ln,{to:`/features/view/${t}`,children:t},t),secondary:n})]},t))})}),Bse=({strategy:e,applications:t,toggles:n})=>{const r=on(),{parameters:o=[]}=e,a=i=>i.length>0?i.map(({name:l,type:c,description:u,required:d},f)=>T(ba,{children:[s(X,{condition:d,show:s(Xi,{children:s(_t,{title:"Required parameter",arrow:!0,children:s(Ta,{"aria-hidden":!1})})}),elseShow:s(Xi,{children:s(_t,{title:"Optional parameter",arrow:!0,children:s(HZ,{"aria-hidden":!1})})})}),s(fn,{primary:T("div",{children:[l," ",T("small",{children:["(",c,")"]})]}),secondary:u})]},`${l}-${f}`)):s(ba,{children:"No params"});return s("div",{className:Mse.listcontainer,children:T(In,{container:!0,children:[s(X,{condition:e.deprecated,show:s(In,{item:!0,children:s("h5",{style:{color:r.palette.error.main},children:"Deprecated"})})}),T(In,{item:!0,sm:12,md:12,children:[s("h6",{children:"Parameters"}),s("hr",{}),s(xa,{children:a(o)})]}),T(In,{item:!0,sm:12,md:n.length>0?6:12,children:[s("h6",{children:"Applications using this strategy"}),s("hr",{}),s(iC,{apps:t})]}),s(X,{condition:n.length>0,show:()=>T(In,{item:!0,sm:12,md:6,children:[s("h6",{children:"Toggles using this strategy"}),s("hr",{}),s(Dse,{toggles:n})]})})]})})},G3=e=>p9()[e],dr=e=>{const t=G3(e);if(!t)throw new Error(`Missing required path param: ${e}`);return t},Fse=()=>{const e=dr("name"),{strategies:t}=pu(),{features:n=[]}=Gx(),{applications:r}=V3(),o=lt(),a=n.filter(c=>{var u;return(u=c==null?void 0:c.environments)==null?void 0:u.flatMap(d=>d.strategies).some(d=>d&&d.name===e)}),i=t.find(c=>c.name===e),l=()=>{o(`/strategies/${e}/edit`)};return i?s(fr,{header:s(xn,{title:i==null?void 0:i.name,subtitle:i==null?void 0:i.description,actions:s(X,{condition:i.editable,show:s(ur,{permission:mv,"data-loading":!0,onClick:l,tooltipProps:{title:"Edit strategy"},children:s(Za,{})})})}),children:s(In,{container:!0,children:s(In,{item:!0,xs:12,sm:12,children:s(Bse,{strategy:i,toggles:a,applications:r})})})}):null},zse=C(Me)(({theme:e})=>({display:"flex",justifyContent:"center",alignItems:"center",padding:e.spacing(0,1.5)})),jse=C(mo)(({theme:e})=>({borderColor:e.palette.dividerAlternative,height:e.spacing(3),margin:e.spacing(0,2)})),Use=()=>s(jse,{orientation:"vertical",variant:"middle"}),q3=({children:e})=>s(zse,{children:e});q3.Divider=Use;const ti=q3;var sC={},Wse=cn;Object.defineProperty(sC,"__esModule",{value:!0});var K3=sC.default=void 0,Hse=Wse(Cn()),Vse=En,Gse=(0,Hse.default)((0,Vse.jsx)("path",{d:"M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"}),"LocationOn");K3=sC.default=Gse;var lC={},qse=cn;Object.defineProperty(lC,"__esModule",{value:!0});var Y3=lC.default=void 0,Kse=qse(Cn()),Yse=En,Xse=(0,Kse.default)((0,Yse.jsx)("path",{d:"M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3zm0 2c-2.33 0-7 1.17-7 3.5V19h14v-2.5c0-2.33-4.67-3.5-7-3.5zm8 0c-.29 0-.62.02-.97.05 1.16.84 1.97 1.97 1.97 3.45V19h6v-2.5c0-2.33-4.67-3.5-7-3.5z"}),"People");Y3=lC.default=Xse;var cC={},Jse=cn;Object.defineProperty(cC,"__esModule",{value:!0});var X3=cC.default=void 0,Qse=Jse(Cn()),Zse=En,ele=(0,Qse.default)((0,Zse.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z"}),"Language");X3=cC.default=ele;var uC={},tle=cn;Object.defineProperty(uC,"__esModule",{value:!0});var J3=uC.default=void 0,nle=tle(Cn()),rle=En,ole=(0,nle.default)((0,rle.jsx)("path",{d:"M9.4 16.6 4.8 12l4.6-4.6L8 6l-6 6 6 6 1.4-1.4zm5.2 0 4.6-4.6-4.6-4.6L16 6l6 6-6 6-1.4-1.4z"}),"Code");J3=uC.default=ole;const ale=e=>p.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M16.584 10H22a2 2 0 1 1 0 4h-5.416a5.001 5.001 0 0 1-9.168 0H2a2 2 0 1 1 0-4h5.416a5.001 5.001 0 0 1 9.168 0Z"})),Ep=e=>cle[e]??e,ile=e=>s(Sb,{...e,component:t=>s(ale,{...t}),inheritViewBox:!0}),sle=e=>{switch(e){case"default":return Zx;case"remoteAddress":return X3;case"flexibleRollout":return ile;case"userWithId":return Y3;case"applicationHostname":return K3;default:return J3}},lle=({strategyName:e})=>{const t=on(),n=sle(e);return s(n,{style:{color:t.palette.neutral.main}})},cle={applicationHostname:"Hosts",default:"Standard",flexibleRollout:"Gradual rollout",gradualRolloutRandom:"Randomized",gradualRolloutSessionId:"Sessions",gradualRolloutUserId:"Users",remoteAddress:"IPs",userWithId:"UserIDs"},ed="api/admin/strategies",dC=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0}),o=p.useCallback(async u=>{const d=t(ed,{method:"POST",body:JSON.stringify(u)});return e(d.caller,d.id)},[t,e]),a=p.useCallback(async u=>{const d=`${ed}/${u.name}`,f=t(d,{method:"PUT",body:JSON.stringify(u)});try{return await e(f.caller,f.id)}catch(h){throw h}},[t,e]),i=p.useCallback(async u=>{const d=`${ed}/${u.name}`,f=t(d,{method:"DELETE"});try{return await e(f.caller,f.id)}catch(h){throw h}},[t,e]),l=p.useCallback(async u=>{const d=`${ed}/${u.name}/deprecate`,f=t(d,{method:"POST"});try{return await e(f.caller,f.id)}catch(h){throw h}},[t,e]),c=p.useCallback(async u=>{const d=`${ed}/${u.name}/reactivate`,f=t(d,{method:"POST"});try{return await e(f.caller,f.id)}catch(h){throw h}},[t,e]);return{createStrategy:o,updateStrategy:a,removeStrategy:i,deprecateStrategy:l,reactivateStrategy:c,errors:n,loading:r}},ule=()=>{const e=cr("(max-width:700px)"),t=lt();return s(X,{condition:e,show:s(ur,{"data-testid":lA,onClick:()=>t("/strategies/create"),permission:Rm,size:"large",tooltipProps:{title:"New strategy type"},children:s(Ta,{})}),elseShow:s(zo,{onClick:()=>t("/strategies/create"),color:"primary",permission:Rm,"data-testid":lA,children:"New strategy type"})})},dle=jt.forwardRef((e,t)=>{const n=Wc(e.permission,e.projectId,e.environmentId);return s(Q3,{...e,access:n,ref:t})}),ple=jt.forwardRef((e,t)=>{const n=oC(e.permission,e.projectId,e.environmentId);return s(Q3,{...e,access:n,ref:t})}),Q3=jt.forwardRef((e,t)=>{const{access:n,permission:r,tooltip:o,disabled:a,projectId:i,environmentId:l,checked:c,onChange:u,...d}=e;return s(cu,{title:Cv(n,o),arrow:!0,children:s("span",{"data-loading":!0,children:s(Ii,{"data-testid":"toggle-switch",onChange:u,disabled:a||!n,checked:c,ref:t,...d})})})}),Z3=jt.forwardRef((e,t)=>typeof e.projectId<"u"&&typeof e.environmentId<"u"?s(dle,{...e,projectId:e.projectId,environmentId:e.environmentId,ref:t}):s(ple,{...e,ref:t})),fle=({deprecated:e,disabled:t,onToggle:n})=>{const r=()=>{n(e)},o=Ss();return s(_t,{title:t?"You cannot disable default strategy":e?"Excluded from strategy list":"Included in strategy list",describeChild:!0,arrow:!0,children:s("div",{id:o,children:s(Z3,{checked:!e,permission:mv,onClick:r,disabled:t,inputProps:{"aria-labelledby":o}})})})},hle=({strategy:e,onClick:t})=>{const n=Ss();return s(X,{condition:e==null?void 0:e.editable,show:s(ur,{onClick:t,permission:mv,tooltipProps:{title:"Edit strategy"},children:s(Za,{})}),elseShow:s(_t,{title:"You cannot edit a built-in strategy",arrow:!0,children:s("div",{id:n,children:s(Yt,{disabled:!0,size:"large",children:s(Za,{"aria-labelledby":n})})})})})},mle=({strategy:e,onClick:t})=>{const n=Ss();return s(X,{condition:e==null?void 0:e.editable,show:s(ur,{onClick:t,permission:Pne,tooltipProps:{title:"Delete strategy"},children:s(Oo,{})}),elseShow:s(_t,{title:"You cannot delete a built-in strategy",arrow:!0,children:s("div",{id:n,children:s(Yt,{disabled:!0,size:"large",children:s(Oo,{"aria-labelledby":n})})})})})},gle=C("div")(({theme:e,color:t="neutral",icon:n})=>({display:"inline-flex",alignItems:"center",padding:e.spacing(n?.375:.625,1),borderRadius:e.shape.borderRadius,fontSize:e.fontSizes.smallerBody,fontWeight:e.fontWeight.bold,lineHeight:1,backgroundColor:e.palette[t].light,color:e.palette[t].dark,border:`1px solid ${e.palette[t].border}`})),vle=C("div")(({theme:e,color:t="neutral",iconRight:n=!1})=>({display:"flex",color:e.palette[t].main,margin:n?e.spacing(0,0,0,.5):e.spacing(0,.5,0,0)})),GA=(e,t,n=!1)=>s(vle,{color:e,iconRight:n,children:s(X,{condition:Boolean(t==null?void 0:t.props.sx),show:t,elseShow:()=>p.cloneElement(t,{sx:{fontSize:"16px"}})})}),Io=p.forwardRef(({color:e="neutral",icon:t,iconRight:n,className:r,sx:o,children:a,...i},l)=>T(gle,{color:e,icon:t,className:r,sx:o,...i,ref:l,children:[s(X,{condition:Boolean(t)&&!Boolean(n),show:GA(e,t)}),a,s(X,{condition:Boolean(t)&&Boolean(n),show:GA(e,t,!0)})]})),yle=C(Io)(({theme:e})=>({marginLeft:e.spacing(1),display:"inline-block"})),ble=()=>{const e=lt(),[t,n]=p.useState({show:!1,title:"",onConfirm:()=>{}}),{strategies:r,refetchStrategies:o,loading:a}=pu(),{removeStrategy:i,deprecateStrategy:l,reactivateStrategy:c}=dC(),{setToastData:u,setToastApiError:d}=It(),f=p.useMemo(()=>a?Array(5).fill({name:"Context name",description:"Context description when loading"}):r.map(({name:O,description:P,editable:D,deprecated:F})=>({name:O,description:P,editable:D,deprecated:F})),[r,a]),h=p.useCallback(O=>P=>{n(P?{show:!0,title:"Really reactivate strategy?",onConfirm:async()=>{try{await c(O),o(),u({type:"success",title:"Success",text:"Strategy reactivated successfully"})}catch(D){d(ft(D))}}}:{show:!0,title:"Really deprecate strategy?",onConfirm:async()=>{try{await l(O),o(),u({type:"success",title:"Success",text:"Strategy deprecated successfully"})}catch(D){d(ft(D))}}})},[l,c,o,d,u]),m=p.useCallback(O=>{n({show:!0,title:"Really delete strategy?",onConfirm:async()=>{try{await i(O),o(),u({type:"success",title:"Success",text:"Strategy deleted successfully"})}catch(P){d(ft(P))}}})},[i,o,d,u]),y=p.useCallback(O=>{e(`/strategies/${O.name}/edit`)},[e]),g=p.useMemo(()=>[{id:"Icon",Cell:()=>s(Me,{"data-loading":!0,sx:{pl:3,pr:1,display:"flex",alignItems:"center"},children:s(O4,{color:"disabled"})}),disableGlobalFilter:!0},{id:"Name",Header:"Name",accessor:O=>Ep(O.name),width:"90%",Cell:({row:{original:{name:O,description:P,deprecated:D,editable:F}}})=>{const U=D?`${P} (deprecated)`:P;return s(Is,{"data-loading":!0,title:Ep(O),subtitle:U,to:`/strategies/${O}`,children:s(X,{condition:!F,show:()=>s(yle,{color:"success",children:"Predefined"})})})},sortType:"alphanumeric"},{Header:"Actions",id:"Actions",align:"center",Cell:({row:{original:O}})=>T(ti,{children:[s(fle,{deprecated:O.deprecated,onToggle:h(O),disabled:O.name==="default"}),s(ti.Divider,{}),s(hle,{strategy:O,onClick:()=>y(O)}),s(mle,{strategy:O,onClick:()=>m(O)})]}),width:150,disableGlobalFilter:!0,disableSortBy:!0},{accessor:"description",disableSortBy:!0},{accessor:"sortOrder",disableGlobalFilter:!0,sortType:"number"}],[h,y,m]),v=p.useMemo(()=>({sortBy:[{id:"Name",desc:!1}],hiddenColumns:["description","sortOrder"]}),[]),{getTableProps:b,getTableBodyProps:w,headerGroups:x,rows:E,prepareRow:A,state:{globalFilter:k},setGlobalFilter:_}=Kt.useTable({columns:g,data:f,initialState:v,sortTypes:Aa,autoResetGlobalFilter:!1,autoResetSortBy:!1,disableSortRemove:!0},Kt.useGlobalFilter,Kt.useSortBy),$=()=>{t==null||t.onConfirm(),n(O=>({...O,show:!1}))};let L=E.length;return T(fr,{isLoading:a,header:s(xn,{title:`Strategy types (${L})`,actions:T(ke,{children:[s(Hr,{initialValue:k,onChange:_}),s(xn.Divider,{}),s(ule,{})]})}),children:[s(Di,{value:k,children:T(Mi,{...b(),children:[s(Ni,{headerGroups:x}),s($i,{...w(),children:E.map(O=>(A(O),s(ai,{hover:!0,...O.getRowProps(),children:O.cells.map(P=>s(ei,{...P.getCellProps(),children:P.render("Cell")}))})))})]})}),s(X,{condition:E.length===0,show:s(X,{condition:(k==null?void 0:k.length)>0,show:T(Un,{children:["No strategies found matching “",k,"”"]}),elseShow:s(Un,{children:"No strategies available. Get started by adding one."})})}),s(Zn,{open:t.show,onClick:$,title:t==null?void 0:t.title,onClose:()=>n(O=>({...O,show:!1}))})]})},kv=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{createTag:async c=>{const d=t("api/admin/tag-types",{method:"POST",body:JSON.stringify(c)});try{return await e(d.caller,d.id)}catch(f){throw f}},validateTagName:async c=>{const d=t("api/admin/tag-types/validate",{method:"POST",body:JSON.stringify({name:c})});try{return await e(d.caller,d.id)}catch(f){throw f}},updateTagType:async(c,u)=>{const d=`api/admin/tag-types/${c}`,f=t(d,{method:"PUT",body:JSON.stringify(u)});try{return await e(f.caller,f.id)}catch(h){throw h}},deleteTagType:async c=>{const u=`api/admin/tag-types/${c}`,d=t(u,{method:"DELETE"});try{return await e(d.caller,d.id)}catch(f){throw f}},errors:n,loading:r}},wle=(e={})=>{const t=async()=>{const c=Dt("api/admin/tag-types");return(await fetch(c,{method:"GET"}).then(yn("Tag types"))).json()},n="api/admin/tag-types",{data:r,error:o}=dn(n,t,e),[a,i]=p.useState(!o&&!r),l=()=>{Vr(n)};return p.useEffect(()=>{i(!o&&!r)},[r,o]),{tagTypes:(r==null?void 0:r.tagTypes)||[],error:o,loading:a,refetch:l}},Sle=()=>{const e=lt(),t=cr("(max-width:700px)");return s(X,{condition:t,show:s(ur,{onClick:()=>e("/tag-types/create"),size:"large",permission:Sp,children:s(Ta,{})}),elseShow:s(zo,{permission:Sp,onClick:()=>e("/tag-types/create"),children:"New tag type"})})},xle=()=>{const[e,t]=p.useState({open:!1}),n=lt(),{deleteTagType:r}=kv(),{tagTypes:o,refetch:a,loading:i}=wle(),{setToastData:l,setToastApiError:c}=It(),u=p.useMemo(()=>i?Array(5).fill({name:"Tag type name",description:"Tag type description when loading"}):o.map(({name:E,description:A})=>({name:E,description:A})),[o,i]),d=p.useMemo(()=>[{id:"Icon",Cell:()=>s(Me,{"data-loading":!0,sx:{pl:2,pr:1,display:"flex",alignItems:"center"},children:s(BZ,{color:"disabled"})}),disableGlobalFilter:!0},{Header:"Name",accessor:"name",width:"90%",Cell:({row:{original:{name:E,description:A}}})=>s(Is,{"data-loading":!0,title:E,subtitle:A}),sortType:"alphanumeric"},{Header:"Actions",id:"Actions",align:"center",Cell:({row:{original:E}})=>T(Me,{sx:{display:"flex",justifyContent:"flex-end"},"data-loading":!0,children:[s(ur,{onClick:()=>n(`/tag-types/edit/${E.name}`),permission:Sp,tooltipProps:{title:"Edit tag type"},children:s(Za,{})}),s(ur,{permission:One,tooltipProps:{title:"Delete tag type"},onClick:()=>t({open:!0,name:E.name}),children:s(Oo,{})})]}),width:150,disableGlobalFilter:!0,disableSortBy:!0},{accessor:"description",disableSortBy:!0}],[n]),f=p.useMemo(()=>({sortBy:[{id:"name",desc:!1}],hiddenColumns:["description"]}),[]),{getTableProps:h,getTableBodyProps:m,headerGroups:y,rows:g,prepareRow:v,state:{globalFilter:b},setGlobalFilter:w}=Kt.useTable({columns:d,data:u,initialState:f,sortTypes:Aa,autoResetGlobalFilter:!1,autoResetSortBy:!1,disableSortRemove:!0},Kt.useGlobalFilter,Kt.useSortBy),x=async()=>{try{e.name&&(await r(e.name),a(),t({open:!1}),l({type:"success",show:!0,title:"Successfully deleted tag type."}))}catch(E){c(ft(E))}};return T(fr,{isLoading:i,header:s(xn,{title:`Tag types (${g.length})`,actions:T(ke,{children:[s(Hr,{initialValue:b,onChange:w}),s(xn.Divider,{}),s(Sle,{})]})}),children:[s(Di,{value:b,children:T(Mi,{...h(),children:[s(Ni,{headerGroups:y}),s($i,{...m(),children:g.map(E=>(v(E),s(ai,{hover:!0,...E.getRowProps(),children:E.cells.map(A=>s(ei,{...A.getCellProps(),children:A.render("Cell")}))})))})]})}),s(X,{condition:g.length===0,show:s(X,{condition:(b==null?void 0:b.length)>0,show:T(Un,{children:["No tags found matching “",b,"”"]}),elseShow:s(Un,{children:"No tags available. Get started by adding one."})})}),s(Zn,{title:"Really delete Tag type?",open:e.open,onClick:x,onClose:()=>{t({open:!1})}})]})},Av=(e={})=>{const t=async()=>{const c=Dt("api/admin/addons");return(await fetch(c,{method:"GET"}).then(yn("Addons"))).json()},n="api/admin/addons",{data:r,error:o}=dn(n,t,e),[a,i]=p.useState(!o&&!r),l=p.useCallback(()=>{Vr(n)},[n]);return p.useEffect(()=>{i(!o&&!r)},[r,o]),{addons:(r==null?void 0:r.addons)||[],providers:(r==null?void 0:r.providers)||[],error:o,loading:a,refetchAddons:l}},eO=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0}),o="api/admin/addons",a=async c=>{const d=t(o,{method:"POST",body:JSON.stringify(c)});return e(d.caller,d.id)},i=async c=>{const u=`${o}/${c}`,d=t(u,{method:"DELETE"});return await e(d.caller,d.id)},l=p.useCallback(async c=>{const u=`${o}/${c.id}`,d=t(u,{method:"PUT",body:JSON.stringify(c)});return e(d.caller,d.id)},[t,e]);return{createAddon:a,updateAddon:l,removeAddon:i,errors:n,loading:r}},_v=({icon:e})=>s(Me,{sx:{pl:2,pr:1,display:"flex",alignItems:"center"},children:e}),Cle="/static/slack-c0af31c6.svg",Ele="/static/jira-d9eb9af9.svg",Tle="/static/webhooks-ffa904ac.svg",kle="/static/teams-62e72076.svg",Ale="/static/datadog-591b6a73.svg",td={width:"32.5px",height:"32.5px",marginRight:"16px"},tO=({name:e})=>{switch(e){case"slack":return s("img",{style:td,alt:"Slack logo",src:Ys(Cle)});case"jira-comment":return s("img",{style:td,alt:"JIRA logo",src:Ys(Ele)});case"webhook":return s("img",{style:td,alt:"Generic Webhook logo",src:Ys(Tle)});case"teams":return s("img",{style:td,alt:"Microsoft Teams logo",src:Ys(kle)});case"datadog":return s("img",{style:td,alt:"Datadog logo",src:Ys(Ale)});default:return s(iv,{children:s(PZ,{})})}},_le=e=>{const[t,n]=p.useState(e),r=p.useCallback(()=>n(e),[e]);return p.useEffect(()=>{n(e)},[e]),[t,n,r]},Rle=({toggleAddon:e,setShowDelete:t,setDeletedAddon:n,original:r})=>{const o=lt(),[a,i,l]=_le(r.enabled),c=()=>{i(!a),e(r).catch(l)};return T(ti,{children:[s(_t,{title:a?`Disable addon ${r.provider}`:`Enable addon ${r.provider}`,arrow:!0,describeChild:!0,children:s(Z3,{permission:Fb,checked:a,onClick:c})}),s(ti.Divider,{}),s(ur,{permission:Fb,tooltipProps:{title:"Edit Addon"},onClick:()=>o(`/addons/edit/${r.id}`),children:s(Za,{})}),s(ur,{permission:Lne,tooltipProps:{title:"Remove Addon"},onClick:()=>{n(r),t(!0)},children:s(Oo,{})})]})},Ple=()=>{const{refetchAddons:e,addons:t,loading:n}=Av(),{updateAddon:r,removeAddon:o}=eO(),{setToastData:a,setToastApiError:i}=It(),[l,c]=p.useState(!1),[u,d]=p.useState({id:0,provider:"",description:"",enabled:!1,events:[],parameters:{}}),f=p.useMemo(()=>n?Array(5).fill({name:"Addon name",description:"Addon description when loading"}):t.map(k=>({...k})),[t,n]),h=p.useCallback(async k=>{try{await r({...k,enabled:!k.enabled}),e(),a({type:"success",title:"Success",text:k.enabled?"Addon is now disabled":"Addon is now enabled"})}catch(_){throw i(ft(_)),_}},[i,e,a,r]),m=p.useMemo(()=>[{id:"Icon",Cell:({row:{original:{provider:k}}})=>s(_v,{icon:s(tO,{name:k})})},{Header:"Name",accessor:"provider",width:"90%",Cell:({row:{original:{provider:k,description:_}}})=>s(Is,{"data-loading":!0,title:k,subtitle:_}),sortType:"alphanumeric"},{Header:"Actions",id:"Actions",align:"center",Cell:({row:{original:k}})=>s(Rle,{setShowDelete:c,toggleAddon:h,setDeletedAddon:d,original:k}),width:150,disableSortBy:!0},{accessor:"description",disableSortBy:!0}],[h]),y=p.useMemo(()=>({sortBy:[{id:"provider",desc:!1}],hiddenColumns:["description"]}),[]),{getTableProps:g,getTableBodyProps:v,headerGroups:b,rows:w,prepareRow:x,state:{globalFilter:E}}=Kt.useTable({columns:m,data:f,initialState:y,sortTypes:Aa,autoResetGlobalFilter:!1,autoResetSortBy:!1,disableSortRemove:!0},Kt.useSortBy),A=async k=>{try{await o(k.id),e(),a({type:"success",title:"Success",text:"Deleted addon successfully"})}catch(_){i(ft(_))}};return T(fr,{isLoading:n,header:s(xn,{title:`Configured addons (${w.length})`}),sx:k=>({marginBottom:k.spacing(2)}),children:[T(Mi,{...g(),children:[s(Ni,{headerGroups:b}),s($i,{...v(),children:w.map(k=>(x(k),s(ai,{hover:!0,...k.getRowProps(),children:k.cells.map(_=>s(ei,{..._.getCellProps(),padding:"none",children:_.render("Cell")}))})))})]}),s(X,{condition:w.length===0,show:s(X,{condition:(E==null?void 0:E.length)>0,show:T(Un,{children:["No addons found matching “",E,"”"]}),elseShow:s(Un,{children:"No addons configured"})})}),s(Zn,{open:l,onClick:()=>{A(u),c(!1)},onClose:()=>{c(!1)},title:"Confirm deletion",children:s("div",{children:"Are you sure you want to delete this Addon?"})})]})},Ile=({name:e})=>{const t=lt();return s(zo,{permission:m3,variant:"outlined",onClick:()=>t(`/addons/create/${e}`),children:"Configure"})},$le=({providers:e,loading:t})=>{const n=p.useMemo(()=>t?Array(5).fill({name:"Provider name",description:"Provider description when loading"}):e.map(({name:f,displayName:h,description:m})=>({name:f,displayName:h,description:m})),[e,t]),r=p.useMemo(()=>[{id:"Icon",Cell:({row:{original:{name:f}}})=>s(_v,{icon:s(tO,{name:f})})},{Header:"Name",accessor:"name",width:"90%",Cell:({row:{original:{name:f,description:h}}})=>s(Is,{"data-loading":!0,title:f,subtitle:h}),sortType:"alphanumeric"},{id:"Actions",align:"center",Cell:({row:{original:f}})=>s(ti,{children:s(Ile,{name:f.name})}),width:150,disableSortBy:!0},{accessor:"description",disableSortBy:!0}],[]),o=p.useMemo(()=>({sortBy:[{id:"name",desc:!1}],hiddenColumns:["description"]}),[]),{getTableProps:a,getTableBodyProps:i,headerGroups:l,rows:c,prepareRow:u,state:{globalFilter:d}}=Kt.useTable({columns:r,data:n,initialState:o,sortTypes:Aa,autoResetGlobalFilter:!1,autoResetSortBy:!1,disableSortRemove:!0},Kt.useSortBy);return T(fr,{isLoading:t,header:s(xn,{title:`Available addons (${c.length})`}),children:[T(Mi,{...a(),children:[s(Ni,{headerGroups:l}),s($i,{...i(),children:c.map(f=>(u(f),s(ai,{hover:!0,...f.getRowProps(),children:f.cells.map(h=>s(ei,{...h.getCellProps(),children:h.render("Cell")}))})))})]}),s(X,{condition:c.length===0,show:s(X,{condition:(d==null?void 0:d.length)>0,show:T(Un,{children:["No providers found matching “",d,"”"]}),elseShow:s(Un,{children:"No providers available."})})})]})},Ole=()=>{const{providers:e,addons:t,loading:n}=Av();return T(ke,{children:[s(X,{condition:t.length>0,show:s(Ple,{})}),s($le,{loading:n,providers:e})]})},Rl=()=>new URLSearchParams(ia().search),Lle=({children:e,from:t,to:n,style:r,...o})=>s("div",{style:{background:`linear-gradient(${t}, ${n})`,height:"100%",width:"100%",position:"relative",...r},...o,children:e}),Nle=e=>p.createElement("svg",{width:334,height:334,viewBox:"0 0 334 334",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("circle",{cx:167,cy:167,r:167,fill:"white"}),p.createElement("rect",{x:96.3462,y:96.3457,width:44.9615,height:141.308,fill:"#1A4049"}),p.createElement("rect",{x:192.692,y:96.3457,width:44.9615,height:141.308,fill:"#1A4049"}),p.createElement("path",{d:"M237.654 192.693L237.654 237.655L96.3461 237.655L96.3461 192.693L237.654 192.693Z",fill:"#1A4049"}),p.createElement("rect",{x:192.692,y:192.693,width:44.9615,height:44.9615,fill:"#817AFE"})),Mle=e=>p.createElement("svg",{id:"bg",width:"100%",height:"100%",viewBox:"0 0 622 318",fill:"none",...e},p.createElement("defs",null,p.createElement("style",null,".cls-1{fill:#fff;}.cls-2{fill:#1a4049;}.cls-3{fill:#817afe;}")),p.createElement("circle",{className:"cls-1",cx:125.62,cy:125.62,r:80}),p.createElement("polygon",{className:"cls-1",points:"137.05 91.33 137.05 114.19 137.05 137.05 159.9 137.05 159.9 114.19 159.9 91.33 137.05 91.33"}),p.createElement("polygon",{className:"cls-1",points:"114.19 114.19 114.19 91.33 91.33 91.33 91.33 114.19 91.33 137.05 91.33 159.9 114.19 159.9 137.05 159.9 137.05 137.05 114.19 137.05 114.19 114.19"}),p.createElement("polygon",{className:"cls-2",points:"137.05 91.33 137.05 114.19 137.05 137.05 159.9 137.05 159.9 114.19 159.9 91.33 137.05 91.33"}),p.createElement("polygon",{className:"cls-2",points:"114.19 114.19 114.19 91.33 91.33 91.33 91.33 114.19 91.33 137.05 91.33 159.9 114.19 159.9 137.05 159.9 137.05 137.05 114.19 137.05 114.19 114.19"}),p.createElement("rect",{className:"cls-3",x:137.05,y:137.05,width:22.86,height:22.86}),p.createElement("path",{className:"cls-1",d:"M251.58,139.13V112.77h11.93v25.06c0,7.36,3.91,12.2,11.27,12.2s11.27-4.84,11.27-12.2V112.77h12v26.36c0,12.67-8.48,21.8-23.1,21.8C260.06,160.93,251.58,151.8,251.58,139.13Z"}),p.createElement("path",{className:"cls-1",d:"M321.91,159.9H310.08V112.77h11.83v7.92a17.93,17.93,0,0,1,15.65-9c11.83,0,19.66,8.67,19.66,20.68V159.9h-12V134.75c0-7.45-4.38-12.39-11.46-12.39s-11.83,5-11.83,12.39Z"}),p.createElement("path",{className:"cls-1",d:"M369.42,91.34h11.92V159.9H369.42Z"}),p.createElement("path",{className:"cls-1",d:"M441.24,137v1.3H403.79c.47,7.36,5.87,13,13.69,13,7.55,0,10.62-3.82,11.46-5.12h11.74c-.75,4.84-7.17,15-23.2,15-15.27,0-25.61-10.61-25.61-24.77,0-14.63,10.24-24.78,24.68-24.78S441.24,121.62,441.24,137Zm-37.08-6.9h24.6c-1.77-6-6.15-9.31-12.21-9.31C410.12,120.78,405.65,124.23,404.16,130.09Z"}),p.createElement("path",{className:"cls-1",d:"M467.78,130.37h15.47c0-5.68-4.29-9.31-11.27-9.31-6.62,0-9,3.54-9.78,4.75h-12c1-4.94,6.89-14.25,21.8-14.25,14.62,0,22.73,7.64,22.73,18.81V146.3c0,2.89,1,4,3.72,4.29v9.59h-3.72c-6.06-.09-9.69-2.33-11-6.52-2.23,3.45-7.26,7.27-15.27,7.27-11.09,0-19.47-6.24-19.47-15.93S456.14,130.37,467.78,130.37Zm15.47,12.11v-4H469.74c-5.59,0-9,2-9,6.33,0,4.57,4.29,7.27,10.25,7.27C477.66,152.08,483.25,148.82,483.25,142.48Z"}),p.createElement("path",{className:"cls-1",d:"M523.12,140.62c-10.34-.74-17.33-5.59-17.33-14.72,0-8.85,8.1-14.44,20.77-14.44,17,0,21.8,8.76,23.1,13.32H537.09c-.84-1-3.54-4.28-10.62-4.28-5.68,0-8.66,1.86-8.66,4.75,0,2.61,2,4.29,6.7,4.94l8,.84c12.77,1.11,18,6,18,15.27,0,8.85-7.36,14.91-21.8,14.91-17.51,0-23.19-10.16-24.12-14.53h12.76c.47,1.11,3.35,5.31,11.36,5.31,6.62,0,9.69-2.24,9.69-5.22s-1.67-4.66-7-5.31C528.05,141.18,526.38,141,523.12,140.62Z"}),p.createElement("path",{className:"cls-1",d:"M571.55,159.9H559.72V91.34h11.83v29.35a17.93,17.93,0,0,1,15.65-9c11.83,0,19.66,8.67,19.66,20.68V159.9h-12V134.75c0-7.45-4.38-12.39-11.46-12.39s-11.83,5-11.83,12.39Z"})),Dle=C(Lle)(({theme:e})=>({display:"flex",justifyContent:"center",[e.breakpoints.up("sm")]:{borderBottomLeftRadius:"3px",borderTopLeftRadius:"3px"}})),Ble=C("div")(({theme:e})=>({padding:e.spacing(12,8),color:"#fff",position:"relative",borderTopLeftRadius:"3px",borderBottomLeftRadius:"3px",textAlign:"right",[e.breakpoints.down("md")]:{padding:e.spacing(6,4)},[e.breakpoints.down("sm")]:{padding:e.spacing(6,2)}})),Fle=C(ye)(({theme:e})=>({color:"#fff",marginBottom:e.spacing(2),fontSize:e.spacing(4),marginTop:e.spacing(10),[e.breakpoints.down("md")]:{display:"none"}})),zle=C(ye)(({theme:e})=>({[e.breakpoints.down("md")]:{display:"none"},[e.breakpoints.down("sm")]:{display:"none"},fontSize:e.spacing(4),fontWeight:"normal"})),jle=C("div")(({theme:e})=>({position:"absolute",[e.breakpoints.up("md")]:{bottom:"-50px",left:"-50px",display:"flex",flexDirection:"column"}})),nO=e=>({width:"200px",[e.breakpoints.up("md")]:{width:"240px",height:"200px"}}),Ule=C(Mle)(({theme:e})=>({...nO(e)})),Wle=C(Nle)(({theme:e})=>({...nO(e)})),rO=({title:e})=>{const t=on(),n=cr(t.breakpoints.down("md"));return T(Dle,{from:t.palette.standaloneBannerGradient.from,to:t.palette.standaloneBannerGradient.to,children:[T(Ble,{children:[s(Fle,{variant:"h1",children:e}),s(zle,{children:"Committed to creating new ways of developing software"})]}),s(jle,{children:s(X,{condition:n,show:s(Ule,{"aria-label":"Unleash logo"}),elseShow:s(Wle,{"aria-label":"Unleash logo"})})})]})},Hle=C("div")(({theme:e})=>({padding:e.spacing(11),background:e.palette.standaloneBackground,display:"flex",[e.breakpoints.down("md")]:{flexDirection:"column"},[e.breakpoints.down("sm")]:{padding:"0"},minHeight:"100vh"})),Vle=C("header")(({theme:e})=>({width:"40%",borderRadius:e.shape.borderRadius,[e.breakpoints.down("md")]:{borderRadius:"0",width:"100%",minHeight:"auto"}})),Gle=C("main")(({theme:e})=>({width:"60%",flex:"1",borderTopRightRadius:"3px",borderBottomRightRadius:"3px",backgroundColor:e.palette.background.paper,position:"relative",[e.breakpoints.down("md")]:{borderRadius:"0",width:"100%",position:"static",minHeight:"auto"}})),qle=C("div")(({theme:e})=>({display:"flex",justifyContent:"center",height:"100%",padding:e.spacing(12,6),[e.breakpoints.down("md")]:{padding:e.spacing(4,4)},[e.breakpoints.down("sm")]:{padding:e.spacing(4,2)}})),Rv=({children:e,BannerComponent:t})=>{let n=s(rO,{title:"Unleash"});return t&&(n=t),T(Hle,{children:[s(Vle,{children:n}),s(Gle,{children:s(qle,{children:e})})]})},Kle="unsecure",oO="demo",Yle="password",Xle="enterprise-hosted",Jle="_container_wn392_1",Qle="_button_wn392_10",qA={container:Jle,button:Qle},Pv=()=>{const{makeRequest:e,errors:t,loading:n}=Nn({propagateErrors:!0});return{passwordAuth:(a,i,l)=>{const c={caller:()=>fetch(a,{headers:Mb,method:"POST",body:JSON.stringify({username:i,password:l})}),id:"passwordAuth"};return e(c.caller,c.id)},emailAuth:(a,i)=>{const l={caller:()=>fetch(a,{headers:Mb,method:"POST",body:JSON.stringify({email:i})}),id:"emailAuth"};return e(l.caller,l.id)},errors:t,loading:n}},Zle=({authDetails:e,redirect:t})=>{const[n,r]=p.useState(""),{refetchUser:o}=ca(),{emailAuth:a}=Pv(),i=lt(),{setToastApiError:l}=It(),c=async d=>{d.preventDefault();try{await a(e.path,n),o(),i(t,{replace:!0})}catch(f){l(ft(f))}},u=d=>{const f=d.target.value;r(f)};return s("form",{onSubmit:c,children:T("div",{className:qA.container,children:[s("p",{children:e.message}),T("p",{children:["This instance of Unleash is not set up with a secure authentication provider. You can read more about"," ",s("a",{href:"https://github.com/Unleash/unleash/blob/master/docs/securing-unleash.md",target:"_blank",rel:"noreferrer",children:"securing Unleash on GitHub"})]}),s(mn,{value:n,onChange:u,inputProps:{"data-testid":"email-input-field"},size:"small",variant:"outlined",label:"Email",name:"email",id:"email",required:!0,type:"email","data-testid":dv,autoFocus:!0}),s("br",{}),s("div",{children:s(Ze,{type:"submit",variant:"contained",color:"primary",className:qA.button,"data-testid":pv,children:"Sign in"})})]})})},ece=({authDetails:e})=>T("div",{children:[s("p",{children:e.message}),s(rV,{style:{textAlign:"center"},children:s("a",{href:e.path,style:{width:"100%"},children:s(Ze,{variant:"contained",color:"primary",style:{width:"150px",margin:"0 auto"},children:"Sign In"})})})]}),tce=e=>p.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"46px",height:"46px",viewBox:"0 0 46 46",...e},p.createElement("defs",null,p.createElement("filter",{x:"-50%",y:"-50%",width:"200%",height:"200%",filterUnits:"objectBoundingBox",id:"filter-1"},p.createElement("feOffset",{dx:0,dy:1,in:"SourceAlpha",result:"shadowOffsetOuter1"}),p.createElement("feGaussianBlur",{stdDeviation:.5,in:"shadowOffsetOuter1",result:"shadowBlurOuter1"}),p.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.168 0",in:"shadowBlurOuter1",type:"matrix",result:"shadowMatrixOuter1"}),p.createElement("feOffset",{dx:0,dy:0,in:"SourceAlpha",result:"shadowOffsetOuter2"}),p.createElement("feGaussianBlur",{stdDeviation:.5,in:"shadowOffsetOuter2",result:"shadowBlurOuter2"}),p.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.084 0",in:"shadowBlurOuter2",type:"matrix",result:"shadowMatrixOuter2"}),p.createElement("feMerge",null,p.createElement("feMergeNode",{in:"shadowMatrixOuter1"}),p.createElement("feMergeNode",{in:"shadowMatrixOuter2"}),p.createElement("feMergeNode",{in:"SourceGraphic"}))),p.createElement("rect",{id:"path-2",x:0,y:0,width:40,height:40,rx:2})),p.createElement("g",{id:"Google-Button",stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},p.createElement("g",{id:"9-PATCH",transform:"translate(-608.000000, -160.000000)"}),p.createElement("g",{id:"btn_google_light_normal",transform:"translate(-1.000000, -1.000000)"},p.createElement("g",{id:"button",transform:"translate(4.000000, 4.000000)",filter:"url(#filter-1)"},p.createElement("g",{id:"button-bg"},p.createElement("use",{fill:"#FFFFFF",fillRule:"evenodd"}),p.createElement("use",{fill:"none"}),p.createElement("use",{fill:"none"}),p.createElement("use",{fill:"none"}))),p.createElement("g",{id:"logo_googleg_48dp",transform:"translate(15.000000, 15.000000)"},p.createElement("path",{d:"M17.64,9.20454545 C17.64,8.56636364 17.5827273,7.95272727 17.4763636,7.36363636 L9,7.36363636 L9,10.845 L13.8436364,10.845 C13.635,11.97 13.0009091,12.9231818 12.0477273,13.5613636 L12.0477273,15.8195455 L14.9563636,15.8195455 C16.6581818,14.2527273 17.64,11.9454545 17.64,9.20454545 L17.64,9.20454545 Z",id:"Shape",fill:"#000"}),p.createElement("path",{d:"M9,18 C11.43,18 13.4672727,17.1940909 14.9563636,15.8195455 L12.0477273,13.5613636 C11.2418182,14.1013636 10.2109091,14.4204545 9,14.4204545 C6.65590909,14.4204545 4.67181818,12.8372727 3.96409091,10.71 L0.957272727,10.71 L0.957272727,13.0418182 C2.43818182,15.9831818 5.48181818,18 9,18 L9,18 Z",id:"Shape",fill:"#000"}),p.createElement("path",{d:"M3.96409091,10.71 C3.78409091,10.17 3.68181818,9.59318182 3.68181818,9 C3.68181818,8.40681818 3.78409091,7.83 3.96409091,7.29 L3.96409091,4.95818182 L0.957272727,4.95818182 C0.347727273,6.17318182 0,7.54772727 0,9 C0,10.4522727 0.347727273,11.8268182 0.957272727,13.0418182 L3.96409091,10.71 L3.96409091,10.71 Z",id:"Shape",fill:"#000"}),p.createElement("path",{d:"M9,3.57954545 C10.3213636,3.57954545 11.5077273,4.03363636 12.4404545,4.92545455 L15.0218182,2.34409091 C13.4631818,0.891818182 11.4259091,0 9,0 C5.48181818,0 2.43818182,2.01681818 0.957272727,4.95818182 L3.96409091,7.29 C4.67181818,5.16272727 6.65590909,3.57954545 9,3.57954545 L9,3.57954545 Z",id:"Shape",fill:"#000"}),p.createElement("path",{d:"M0,0 L18,0 L18,18 L0,18 L0,0 Z",id:"Shape"})),p.createElement("g",{id:"handles_square"}))));var pC={},nce=cn;Object.defineProperty(pC,"__esModule",{value:!0});var aO=pC.default=void 0,rce=nce(Cn()),oce=En,ace=(0,rce.default)((0,oce.jsx)("path",{d:"M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM9 8V6c0-1.66 1.34-3 3-3s3 1.34 3 3v2H9z"}),"LockRounded");aO=pC.default=ace;const fC=({options:e})=>{const{classes:t}=ef();return s(ke,{children:e==null?void 0:e.map(n=>s("div",{className:Ca(t.flexColumn,t.contentSpacingY),children:s(Ze,{color:"primary","data-loading":!0,variant:"outlined",href:n.path,size:"small","data-testid":`${wee}-${n.type}`,style:{height:"40px",color:"#000"},startIcon:s(X,{condition:n.type==="google",show:s(tce,{style:{height:"35px",width:"35px"}}),elseShow:s(aO,{style:{height:"25px",width:"25px"}})}),children:n.message})},n.type))})},ice=C("div")(({theme:e})=>({display:"flex",alignItems:"center",justifyContent:"center",margin:e.spacing(2,"auto")})),KA=C("span")(({theme:e})=>({width:"80px",height:"3px",backgroundColor:e.palette.divider,borderRadius:e.shape.borderRadius})),sce=C(ye)(({theme:e})=>({textAlign:"center",display:"block",margin:e.spacing(0,2)})),Iv=({text:e,...t})=>T(ice,{...t,children:[s(KA,{}),s(sce,{variant:"body2",children:e}),s(KA,{})]}),Hc=({...e})=>{const[t,n]=p.useState(!1);return s(mn,{variant:"outlined",size:"small",type:t?"text":"password",InputProps:{style:{paddingRight:"0px"},endAdornment:s(o4,{position:"end",children:s(Yt,{onClick:()=>{n(!t)},onMouseDown:l=>{l.preventDefault()},size:"large",children:s(t?N4:M4,{titleAccess:"Toggle password visibility"})})})},...e})},lce=C(Zt)(({theme:e})=>({color:e.palette.error.main,marginBottom:e.spacing(1)})),cce=C("div")(({theme:e})=>({...Qp(e),display:"flex",flexDirection:"column"})),uce=({authDetails:e,redirect:t})=>{const n=lt(),{refetchUser:r}=ca(),o=Rl(),[a,i]=p.useState(o.get("email")||""),[l,c]=p.useState(""),{passwordAuth:u}=Pv(),[d,f]=p.useState({}),h=async g=>{if(g.preventDefault(),a||f(v=>({...v,usernameError:"This is a required field"})),l||f(v=>({...v,passwordError:"This is a required field"})),!(!l||!a))try{await u(e.path,a,l),r(),n(t,{replace:!0})}catch(v){v instanceof kx||v instanceof Tx?(f(b=>({...b,apiError:"Invalid login details"})),c(""),i("")):v instanceof j4?f({apiError:"Invalid password and username combination."}):f({apiError:"Unknown error while trying to authenticate."})}},m=()=>{const{usernameError:g,passwordError:v,apiError:b}=d;return s(X,{condition:!e.defaultHidden,show:T("form",{onSubmit:h,children:[s(X,{condition:Boolean(b),show:s(lce,{severity:"error",children:b})}),T(cce,{children:[s(mn,{label:"Username or email",name:"username",id:"username",type:"text",onChange:w=>i(w.target.value),value:a,error:Boolean(g),helperText:g,autoComplete:"username","data-testid":dv,variant:"outlined",size:"small",autoFocus:!0}),s(Hc,{label:"Password",onChange:w=>c(w.target.value),name:"password",id:"password",value:l,error:Boolean(v),helperText:v,autoComplete:"current-password","data-testid":H4}),s(Ze,{variant:"contained",color:"primary",type:"submit",style:{width:"150px",margin:"1rem auto"},"data-testid":pv,children:"Sign in"})]})]})})},{options:y=[]}=e;return s(ke,{children:s(X,{condition:y.length>0,show:T(ke,{children:[s(fC,{options:y}),s(X,{condition:!e.defaultHidden,show:s(Iv,{text:"Or sign in with username"})}),m()]}),elseShow:m()})})},dce=C(ye)(({theme:e})=>({color:e.palette.error.main})),pce=C("div")(({theme:e})=>({...Qp(e),display:"flex",flexDirection:"column"})),fce=C(Ze)(({theme:e})=>({width:"150px",margin:e.spacing(2,"auto",0,"auto"),display:"block",textAlign:"center"})),hce=({authDetails:e,redirect:t})=>{const{refetchUser:n}=ca(),r=lt(),o=Rl(),{passwordAuth:a}=Pv(),[i,l]=p.useState(o.get("email")||""),[c,u]=p.useState(""),[d,f]=p.useState({}),h=async b=>{if(b.preventDefault(),i||f(w=>({...w,usernameError:"This is a required field"})),c||f(w=>({...w,passwordError:"This is a required field"})),!(!c||!i))try{await a(e.path,i,c),n(),r(t,{replace:!0})}catch(w){w instanceof kx||w instanceof Tx?(f(x=>({...x,apiError:"Invalid login details"})),u(""),l("")):f({apiError:"Unknown error while trying to authenticate."})}},{usernameError:m,passwordError:y,apiError:g}=d,{options:v=[]}=e;return T(ke,{children:[s(X,{condition:v.length>0,show:T(ke,{children:[s(fC,{options:v}),s(Iv,{text:"or signin with username"})]})}),s(X,{condition:!e.defaultHidden,show:T("form",{onSubmit:h,children:[s(dce,{variant:"subtitle2",children:g}),T(pce,{children:[s(mn,{label:"Username or email",name:"username",id:"username",type:"text",onChange:b=>l(b.target.value),value:i,error:Boolean(m),helperText:m,variant:"outlined",size:"small","data-testid":dv}),s(Hc,{label:"Password",onChange:b=>u(b.target.value),name:"password",id:"password",value:c,error:Boolean(y),helperText:y,autoComplete:"current-password","data-testid":H4}),s(In,{container:!0,children:s(fce,{variant:"contained",color:"primary",type:"submit","data-testid":pv,children:"Sign in"})})]})]})})]})},mce="_container_abcn7_1",gce="_emailField_abcn7_9",vce="_form_abcn7_13",yce="_logo_abcn7_17",bce="_button_abcn7_24",nd={container:mce,emailField:gce,form:vce,logo:yce,button:bce},wce=e=>p.createElement("svg",{width:52,height:52,viewBox:"0 0 52 52",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("circle",{cx:26,cy:26,r:26,fill:"white"}),p.createElement("rect",{x:15,y:15,width:7,height:22,fill:"#1A4049"}),p.createElement("rect",{x:30,y:15,width:7,height:22,fill:"#1A4049"}),p.createElement("path",{d:"M37 30L37 37L15 37L15 30L37 30Z",fill:"#1A4049"}),p.createElement("rect",{x:30,y:30,width:7,height:7,fill:"#817AFE"})),Sce=({authDetails:e,redirect:t})=>{const[n,r]=p.useState(""),o=lt(),{refetchUser:a}=ca(),{emailAuth:i}=Pv(),{setToastApiError:l}=It(),c=async d=>{d.preventDefault();try{await i(e.path,n),a(),o(t,{replace:!0})}catch(f){l(ft(f))}},u=d=>{const f=d.target.value;r(f)};return T("form",{onSubmit:c,children:[s(wce,{className:nd.logo,"aria-label":"Unleash logo"}),T("div",{className:nd.container,children:[s("h2",{children:"Access the Unleash demo instance"}),s("p",{children:"No further data or Credit Card required"}),T("div",{className:nd.form,children:[s(mn,{value:n,className:nd.emailField,onChange:u,inputProps:{"data-testid":"email-input-field"},size:"small",variant:"outlined",label:"Email",name:"email",id:"email","data-testid":dv,required:!0,type:"email"}),s(Ze,{type:"submit",variant:"contained",color:"primary",className:nd.button,"data-testid":pv,children:"Sign in"})]}),T("p",{children:["By accessing our demo instance, you agree to the Unleash ",s("a",{href:"https://www.unleash-hosted.com/tos/",target:"_blank",rel:"noreferrer",children:"Customer Terms of Service"})," ","and ",s("a",{href:"https://www.unleash-hosted.com/privacy-policy/",target:"_blank",rel:"noreferrer",children:"Privacy Policy"})]})]})]})},xce=C("div")(({theme:e})=>({margin:"auto auto 0 auto",width:"230px",[e.breakpoints.down("md")]:{marginTop:e.spacing(2)}})),Cce=C(ln)(({theme:e})=>({fontWeight:"bold",textAlign:"center"})),Ece=C(ye)(({theme:e})=>({fontWeight:"bold",marginBottom:e.spacing(1)})),Tce=C("a")(({theme:e})=>({fontWeight:"bold",textAlign:"center"})),YA=()=>T(xce,{children:[s(Cce,{to:"/forgotten-password",children:s(Ece,{variant:"body2",children:"Forgot password?"})}),T(ye,{variant:"body2",children:["Don't have an account?"," ",s(Tce,{href:"https://www.getunleash.io/plans",target:"_blank",rel:"noopener noreferrer",children:"Sign up"})]})]}),fu=()=>{const e=tf();return{authDetails:e.data&&"type"in e.data?e.data:void 0,refetchAuthDetails:e.refetchAuth,loading:e.loading,error:e.error}},kce=({redirect:e,invited:t=!1})=>{const{authDetails:n}=fu(),o=Rl().get("errorMsg"),{trackEvent:a}=ka();if(p.useEffect(()=>{t&&a("invite",{props:{eventType:"user created"}})},[t,a]),!n)return null;let i;return n.type===Yle?i=T(ke,{children:[s(uce,{authDetails:n,redirect:e}),s(X,{condition:!n.defaultHidden,show:s(YA,{})})]}):n.type===Kle?i=s(Zle,{authDetails:n,redirect:e}):n.type===oO?i=s(Sce,{authDetails:n,redirect:e}):n.type===Xle?i=T(ke,{children:[s(hce,{authDetails:n,redirect:e}),s(X,{condition:!n.defaultHidden,show:s(YA,{})})]}):i=s(ece,{authDetails:n}),T(ke,{children:[s("div",{style:{maxWidth:"350px"},"data-testid":$ee,children:s(X,{condition:Boolean(o),show:s(Zt,{severity:"error",children:o})})}),i]})},Ace=e=>{const t=new URL(decodeURIComponent(e),window.location.protocol+"//"+window.location.host);return{pathname:t.pathname,search:t.search}},_ce=C("div")(({theme:e})=>({display:"flex",flexDirection:"column"})),Rce=C("h2")(({theme:e})=>({fontSize:e.fontSizes.mainHeader,marginBottom:e.spacing(2),textAlign:"center"})),Pce=()=>{const{authDetails:e}=fu(),{user:t}=ca(),n=Rl(),r=n.get("reset")==="true",o=n.get("invited")==="true",a=n.get("redirect")||"/";return t?s(_l,{to:Ace(a),replace:!0}):s(Rv,{children:T(_ce,{children:[s(X,{condition:r,show:T(Zt,{severity:"success",sx:{mb:4},children:[s(Em,{children:"Success"}),"You successfully reset your password."]})}),s(X,{condition:o,show:T(Zt,{severity:"success",sx:{mb:4},children:[s(Em,{children:"Success"}),"Your account has been created."]})}),s(X,{condition:(e==null?void 0:e.type)!==oO,show:s(Rce,{children:"Log in to continue the great work"})}),s(kce,{redirect:a,invited:o})]})})},Ice="P",$ce="EEA",Oce="RE",A1="SE",Lce="UG",Nce=e=>()=>{if(!e)return Promise.resolve({name:iO});const t=Dt(`auth/reset/validate?token=${e}`);return fetch(t,{method:"GET"}).then(n=>n.json())},iO="InvalidTokenError",Mce="UsedTokenError",sO=(e={})=>{const t=Rl(),n=t.get("token")||"",[r,o]=p.useState(n),a=Nce(r),i=`auth/reset/validate?token=${r}`,{data:l,error:c}=dn(i,a,e),[u,d]=p.useState(!c&&!l),f=()=>{const m=t.get("token")||"";o(m)};p.useEffect(()=>{d(!c&&!l)},[l,c]);const h=!(!u&&(l==null?void 0:l.name)===iO||(l==null?void 0:l.name)===Mce);return{token:r,data:l,error:c,loading:u,isValidToken:h,setLoading:d,retry:f}},Dce=(e,t)=>()=>{if(!e)return Promise.resolve(!1);const n=Dt(t);return fetch(n,{method:"GET"}).then(r=>r.status===Jp)},lO=(e={})=>{const n=Rl().get("invite")||"",r=`/invite/${n}/validate`,{data:o,error:a}=dn(r,Dce(n,r),e),[i,l]=p.useState(!a&&!o);return p.useEffect(()=>{l(!a&&o===void 0)},[o,a]),{secret:n,isValid:o,error:a,loading:i}},XA="api/admin/invite-link/tokens",Bce=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0}),o=p.useCallback(async l=>{const c=t(XA,{method:"POST",body:JSON.stringify(l)});return await e(c.caller,c.id)},[t,e]),a=p.useCallback(async(l,c)=>{const u=t(`${XA}/${l}`,{method:"PUT",body:JSON.stringify({...c.expiresAt?{expiresAt:c.expiresAt}:{},...c.enabled!==void 0?{enabled:c.enabled}:{}})});return await e(u.caller,u.id)},[t,e]),i=p.useCallback(async(l,c)=>{const u=t(`/invite/${l}/signup`,{method:"POST",body:JSON.stringify(c)});return await e(u.caller,u.id)},[t,e]);return{createToken:o,updateToken:a,addUser:i,errors:n,loading:r}},cO=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{resetPassword:p.useCallback(a=>{const i=t("auth/reset/password",{method:"POST",body:JSON.stringify(a)});return e(i.caller,i.id)},[t,e]),errors:n,loading:r}},Fce=C("span")(({theme:e})=>({display:"inline-grid",alignItems:"center",outline:0,cursor:"pointer","&:is(:focus-visible, :active) > *, &:hover > *":{outlineStyle:"solid",outlineWidth:2,outlineOffset:0,outlineColor:e.palette.primary.main,borderRadius:"100%",color:e.palette.primary.main},"& svg":{fontSize:e.fontSizes.mainHeader,color:e.palette.neutral.main,marginLeft:e.spacing(.5)}})),Dm=({tooltip:e,placement:t,children:n})=>s(_t,{title:e,placement:t,arrow:!0,children:s(Fce,{tabIndex:0,"aria-label":"Help",children:n??s(wx,{})})}),zce="The password must be at least 10 characters long.",jce="The password must contain at least one number.",Uce="The password must contain at least one special character.",Wce="The password must contain at least one uppercase letter.",Hce="The password must contain at least one lowercase letter.",Vce="The password may not contain sequences of three or more repeated characters.",uO="The password must be at least 10 characters long and must include an uppercase letter, a lowercase letter, a number, and a symbol.",Gce=C(ye)(({theme:e})=>({marginBottom:"0",display:"flex",alignItems:"center",gap:"1ch"})),qce=C("div")(({theme:e})=>({border:"1px solid #f1f1f1",borderRadius:e.shape.borderRadius,position:"relative",maxWidth:"350px",color:"#44606e"})),Kce=C("div")(({theme:e})=>({display:"flex",padding:e.spacing(1)})),Ui=C("div")(({theme:e})=>({width:"95px",margin:e.spacing(0,.5),display:"flex",justifyContent:"center"})),Yce=C("div")(({theme:e})=>({backgroundColor:e.palette.neutral.light,height:"1px",width:"100%"})),Xce=C("div")(({theme:e})=>({display:"flex",padding:e.spacing(1)})),Jce=C(Zt)(({theme:e})=>({marginTop:e.spacing(1),bottom:"0",position:"absolute"})),oh=C("div",{shouldForwardProp:e=>e!=="error"})(({theme:e,error:t})=>({width:"50px",borderRadius:e.shape.borderRadius,height:"6px",backgroundColor:t?"red":e.palette.primary.main})),dO=({password:e,callback:t,style:n={}})=>{const[r,o]=p.useState(!0),[a,i]=p.useState(!0),[l,c]=p.useState(!0),[u,d]=p.useState(!0),[f,h]=p.useState(!1),m=p.useCallback(()=>{const w=Dt("auth/reset/validate-password");return fetch(w,{headers:{"Content-Type":"application/json"},method:"POST",body:JSON.stringify({password:e})})},[e]),y=p.useCallback(()=>{v(!1)},[]),g=p.useCallback(async()=>{if(!e){v(!0);return}if(e.length<3){d(!0);return}try{const w=await m();if(w.status===Ex){const x=await w.json();b(x),t(!1)}w.status===Jp&&(y(),h(!1),t(!0))}catch{console.log("An exception was caught and handled")}},[m,t,e,y]);p.useEffect(()=>{g()},[e,g]);const v=w=>{o(w),i(w),c(w),d(w)},b=w=>{const x=w.details[0].validationErrors;x.includes(jce)?i(!0):i(!1),x.includes(Uce)?c(!0):c(!1),x.includes(zce)?d(!0):d(!1),x.includes(Hce)||x.includes(Wce)?o(!0):o(!1),x.includes(Vce)?h(!0):h(!1)};return T(ke,{children:[T(Gce,{variant:"body2","data-loading":!0,children:["Please set a strong password",s(Dm,{tooltip:uO})]}),T(qce,{style:{...n},children:[T(Kce,{children:[s(Ui,{children:s(ye,{variant:"body2","data-loading":!0,children:"Length"})}),s(Ui,{children:s(ye,{variant:"body2","data-loading":!0,children:"Casing"})}),s(Ui,{children:s(ye,{variant:"body2","data-loading":!0,children:"Number"})}),s(Ui,{children:s(ye,{variant:"body2","data-loading":!0,children:"Symbol"})})]}),s(Yce,{}),T(Xce,{children:[s(Ui,{children:s(oh,{error:u,"data-loading":!0})}),s(Ui,{children:s(oh,{error:r,"data-loading":!0})})," ",s(Ui,{children:s(oh,{error:a,"data-loading":!0})}),s(Ui,{children:s(oh,{error:l,"data-loading":!0})})]}),s(X,{condition:f,show:s(Jce,{severity:"error",children:"You may not repeat three characters in a row."})})]})]})};var hC={},Qce=cn;Object.defineProperty(hC,"__esModule",{value:!0});var pO=hC.default=void 0,Zce=Qce(Cn()),eue=En,tue=(0,Zce.default)((0,eue.jsx)("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}),"Check");pO=hC.default=tue;const nue=C("div")(({theme:e})=>({position:"relative",paddingTop:e.spacing(.5)})),rue=C(ye,{shouldForwardProp:e=>e!=="matchingPasswords"})(({theme:e,matchingPasswords:t})=>({position:"absolute",bottom:"-8px",display:"flex",alignItems:"center",color:t?e.palette.primary.main:e.palette.error.main})),oue=C(pO)(({theme:e})=>({marginRight:"5px"})),fO=({started:e,matchingPasswords:t})=>s(nue,{children:s(X,{condition:e,show:T(rue,{variant:"body2","data-loading":!0,matchingPasswords:t,children:[s(oue,{})," ",s(X,{condition:t,show:s(ye,{children:" Passwords match"}),elseShow:s(ye,{children:" Passwords do not match"})})]})})}),aue=C("form")(({theme:e})=>({display:"flex",flexDirection:"column",position:"relative","& > *":{marginTop:`${e.spacing(1)} !important`,marginBottom:`${e.spacing(1)} !important`}})),iue=C(Ze)(({theme:e})=>({width:"150px",margin:e.spacing(2,"auto"),display:"block"})),hO=({onSubmit:e})=>{const[t,n]=p.useState(""),[r,o]=p.useState(!1),[a,i]=p.useState(""),[l,c]=p.useState(!1),[u,d]=p.useState(!1),f=l&&u,h=p.useCallback(d,[d]);p.useEffect(()=>{t||d(!1),c(t===a)},[t,a]);const m=g=>{g.preventDefault(),f&&e(t)},y=Boolean(t&&a);return T(aue,{onSubmit:m,children:[s(Hc,{placeholder:"Password",value:t||"",onChange:g=>n(g.target.value),onFocus:()=>o(!0),autoComplete:"new-password","data-loading":!0}),s(Hc,{value:a||"",placeholder:"Confirm password",onChange:g=>i(g.target.value),autoComplete:"new-password","data-loading":!0}),s(X,{condition:r,show:s(dO,{password:t,callback:h,style:{marginBottom:"1rem"}})}),s(fO,{started:y,matchingPasswords:l}),s(iue,{variant:"contained",color:"primary",type:"submit","data-loading":!0,disabled:!f,children:"Submit"})]})},mO=()=>{const{authDetails:e}=fu(),{classes:t}=ef(),n=(e==null?void 0:e.defaultHidden)===!0,{secret:r}=lO();return T("div",{className:Ca(t.contentSpacingY,t.flexColumn,t.itemsCenter),children:[s(ye,{variant:"h2",className:t.title,children:"Invalid token"}),s(X,{condition:n,show:T(ke,{children:[s(ye,{variant:"subtitle1",children:"Your instance does not support password authentication. Use correct work email to access your account."}),s(Ze,{variant:"contained",color:"primary",component:ln,to:"/login",children:"Login"})]}),elseShow:s(X,{condition:Boolean(r),show:s(ye,{variant:"subtitle1",children:"Provided invite link is invalid or expired. Please request a new URL in order to create your account."}),elseShow:T(ke,{children:[s(ye,{variant:"subtitle1",children:"Your token has either been used to reset your password, or it has expired. Please request a new reset password URL in order to reset your password."}),s(Ze,{variant:"contained",color:"primary",component:ln,to:"/forgotten-password","data-testid":xee,children:"Reset password"})]})})})]})},JA=({children:e,loading:t,title:n})=>{const r=Sv(t||!1);return s("div",{ref:r,children:s(Rv,{showMenu:!1,BannerComponent:s(rO,{title:"Unleash"}),children:T(Me,{sx:{width:["100%","350px"]},children:[s(X,{condition:Boolean(n),show:s(ye,{component:"h2",sx:{fontSize:o=>o.fontSizes.mainHeader,marginBottom:2,textAlign:"center",fontWeight:o=>o.fontWeight.bold},children:n})}),e]})})})},gO=()=>T(Zt,{severity:"error","data-loading":!0,children:[s(Em,{children:"Unable to reset password"}),"Something went wrong when attempting to update your password. This could be due to unstable internet connectivity. If retrying the request does not work, please try again later."]}),sue=()=>{var $,L;const{authDetails:e}=fu(),{setToastApiError:t}=It(),n=lt(),[r,o]=p.useState(!1),[a,i]=p.useState(""),[l,c]=p.useState(""),{token:u,data:d,loading:f,isValidToken:h}=sO(),{secret:m,loading:y,isValid:g}=lO(),{addUser:v,loading:b}=Bce(),{resetPassword:w,loading:x}=cO(),E=(e==null?void 0:e.defaultHidden)===!0,A=async O=>{try{(await v(m,{name:l,email:a,password:O})).status===ZZ?n("/login?invited=true"):t("Couldn't create user. Check if your invite link is valid.")}catch(P){t(ft(P))}},k=async O=>{try{(await w({token:u,password:O})).status===Jp?n("/login?reset=true"):o(!0)}catch{o(!0)}},_=O=>{g?A(O):k(O)};return!h&&!g?s(JA,{loading:f||y,children:s(mO,{})}):T(JA,{loading:f||y||b||x,title:E?"Connect your account and start your journey":"Enter your personal details and start your journey",children:[s(X,{condition:d==null?void 0:d.createdBy,show:T(ye,{variant:"body1","data-loading":!0,sx:{textAlign:"center",mb:2},children:[d==null?void 0:d.createdBy,s("br",{})," has invited you to join Unleash."]})}),T(ye,{color:"text.secondary",children:["We suggest using"," ",s(ye,{component:"strong",fontWeight:"bold",children:"the email you use for work"}),"."]}),s(X,{condition:Boolean(($=e==null?void 0:e.options)==null?void 0:$.length),show:s(Me,{sx:{mt:2},children:s(fC,{options:e==null?void 0:e.options})})}),s(X,{condition:Boolean((L=e==null?void 0:e.options)==null?void 0:L.length)&&!E,show:s(Iv,{text:"or sign-up with an email address","data-loading":!0})}),s(X,{condition:!E,show:T(ke,{children:[s(X,{condition:d==null?void 0:d.email,show:()=>s(ye,{"data-loading":!0,variant:"body1",sx:{my:1},children:"Your username is"})}),s(mn,{"data-loading":!0,type:"email",value:h?(d==null?void 0:d.email)||"":a,id:"email",label:"Email",variant:"outlined",size:"small",sx:{my:1},disabled:h,fullWidth:!0,required:!0,onChange:O=>{h||i(O.target.value)}}),s(X,{condition:Boolean(g),show:()=>s(mn,{"data-loading":!0,value:l,id:"username",label:"Full name",variant:"outlined",size:"small",sx:{my:1},fullWidth:!0,required:!0,onChange:O=>{c(O.target.value)}})}),s(ye,{variant:"body1","data-loading":!0,sx:{mt:2},children:"Set a password for your account."}),s(X,{condition:r&&h,show:s(gO,{})}),s(hO,{onSubmit:_})]})})]})},lue=C("div")(({theme:e})=>({width:"350px",maxWidth:"350px",[e.breakpoints.down("sm")]:{width:"100%"}})),cue=C(ye)(({theme:e})=>({fontWeight:"bold",fontSize:e.spacing(2.5),marginBottom:e.spacing(2)})),uue=()=>{const{token:e,loading:t,isValidToken:n}=sO(),{resetPassword:r,loading:o}=cO(),{authDetails:a}=fu(),i=Sv(t||o),l=lt(),[c,u]=p.useState(!1),d=(a==null?void 0:a.defaultHidden)===!0;return s("div",{ref:i,children:s(Rv,{children:s(lue,{children:s(X,{condition:!n||d,show:s(mO,{}),elseShow:T(ke,{children:[s(cue,{variant:"h2","data-loading":!0,children:"Reset password"}),s(X,{condition:c,show:s(gO,{})}),s(hO,{onSubmit:async h=>{try{(await r({token:e,password:h})).status===Jp?(l("/login?reset=true"),u(!1)):u(!0)}catch{u(!0)}}})]})})})})})},due=C("div")(({theme:e})=>({...Qp,...Q4,width:"350px",[e.breakpoints.down("sm")]:{width:"100%"}})),pue=C("strong")(({theme:e})=>({display:"block",margin:e.spacing(1,0)})),fue=C(Ze)(({theme:e})=>({width:"150px",margin:e.spacing(2,"auto")})),hue=C("h2")(({theme:e})=>({...ate(e),...J4})),mue=C("form")(({theme:e})=>({...Qp(e),...Q4})),gue=C(ye)(({theme:e})=>({...J4})),vue=()=>{const[e,t]=p.useState(""),[n,r]=p.useState(!1),[o,a]=p.useState(!1),[i,l]=p.useState(""),c=Sv(o);return s(Rv,{children:T(due,{ref:c,children:[s(hue,{"data-loading":!0,children:"Forgotten password"}),s(X,{condition:n,show:T(Zt,{severity:"success","data-loading":!0,children:[s(Em,{children:"Attempted to send email"}),"We've attempted to send a reset password email to:",s(pue,{children:i}),"If you did not receive an email, please verify that you typed in the correct email, and contact your administrator to make sure that you are in the system."]})}),T(mue,{onSubmit:async d=>{d.preventDefault(),a(!0),l(e);const f=Dt("auth/reset/password-email");await fetch(f,{headers:{"Content-Type":"application/json"},method:"POST",body:JSON.stringify({email:e})}),r(!0),a(!1)},children:[s(gue,{variant:"body1","data-loading":!0,children:"Please provide your email address. If it exists in the system we'll send a new reset link."}),s(mn,{variant:"outlined",size:"small",placeholder:"email",type:"email","data-loading":!0,"data-testid":See,value:e,onChange:d=>{t(d.target.value)}}),s(fue,{variant:"contained",type:"submit","data-loading":!0,color:"primary",disabled:o,children:s(X,{condition:!n,show:s("span",{children:"Submit"}),elseShow:s("span",{children:"Try again"})})}),s(Iv,{text:"Or log in"}),s(Ze,{type:"submit","data-loading":!0,variant:"outlined",disabled:o,component:ln,to:"/login",sx:d=>({width:"150px",margin:d.spacing(2,"auto")}),children:"Log in"})]})]})})},vO=e=>{const t=()=>{const r=Dt(`api/admin/projects/${e}`);return fetch(r,{method:"GET"}).then(yn("Project overview")).then(o=>o.json())},n=`api/admin/projects/${e}`;return{fetcher:t,KEY:n}};var mC={},yue=cn;Object.defineProperty(mC,"__esModule",{value:!0});var gC=mC.default=void 0,bue=yue(Cn()),wue=En,Sue=(0,bue.default)((0,wue.jsx)("path",{d:"M12 8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"}),"MoreVert");gC=mC.default=Sue;const xue=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0}),{setToastData:o,setToastApiError:a}=It(),{trackEvent:i}=ka(),l=p.useCallback(async u=>{const d=`api/admin/projects/${u}/favorites`,f=t(d,{method:"POST"},"addFavoriteProject");try{await e(f.caller,f.id),o({title:"Project added to favorites",type:"success"}),i("favorite",{props:{eventType:"project favorited"}})}catch(h){a(ft(h))}},[t,e]),c=p.useCallback(async u=>{const d=`api/admin/projects/${u}/favorites`,f=t(d,{method:"DELETE"},"removeFavoriteProject");try{await e(f.caller,f.id),o({title:"Project removed from favorites",type:"success"}),i("favorite",{props:{eventType:"project unfavorited"}})}catch(h){a(ft(h))}},[t,e]);return{favorite:l,unfavorite:c,errors:n,loading:r}},Cue=({isFavorite:e,size:t="large",...n})=>s(cu,{title:e?"Remove from favorites":"Add to favorites",children:s(Yt,{size:t,"data-loading":!0,...n,children:s(X,{condition:e,show:s(xx,{color:"primary",sx:{fontSize:r=>t==="medium"?r.spacing(2):r.spacing(3)}}),elseShow:s(Cx,{sx:{fontSize:r=>t==="medium"?r.spacing(2):r.spacing(3)}})})})}),vC=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{createProject:async v=>{const w=t("api/admin/projects",{method:"POST",body:JSON.stringify(v)});try{return await e(w.caller,w.id)}catch(x){throw x}},validateId:async v=>{const w=t("api/admin/projects/validate",{method:"POST",body:JSON.stringify(v)});try{return await e(w.caller,w.id)}catch(x){throw x}},editProject:async(v,b)=>{const w=`api/admin/projects/${v}`,x=t(w,{method:"PUT",body:JSON.stringify(b)});try{return await e(x.caller,x.id)}catch(E){throw E}},deleteProject:async v=>{const b=`api/admin/projects/${v}`,w=t(b,{method:"DELETE"});try{return await e(w.caller,w.id)}catch(x){throw x}},addEnvironmentToProject:async(v,b)=>{const w=`api/admin/projects/${v}/environments`,x=t(w,{method:"POST",body:JSON.stringify({environment:b})});try{return await e(x.caller,x.id)}catch(E){throw E}},removeEnvironmentFromProject:async(v,b)=>{const w=`api/admin/projects/${v}/environments/${b}`,x=t(w,{method:"DELETE"});try{return await e(x.caller,x.id)}catch(E){throw E}},addAccessToProject:async(v,b,w)=>{const x=`api/admin/projects/${v}/role/${b}/access`,E=t(x,{method:"POST",body:JSON.stringify(w)});try{return await e(E.caller,E.id)}catch(A){throw A}},removeUserFromRole:async(v,b,w)=>{const x=`api/admin/projects/${v}/users/${w}/roles/${b}`,E=t(x,{method:"DELETE"});try{return await e(E.caller,E.id)}catch(A){throw A}},removeGroupFromRole:async(v,b,w)=>{const x=`api/admin/projects/${v}/groups/${w}/roles/${b}`,E=t(x,{method:"DELETE"});try{return await e(E.caller,E.id)}catch(A){throw A}},changeUserRole:(v,b,w)=>{const x=`api/admin/projects/${v}/users/${w}/roles/${b}`,E=t(x,{method:"PUT"});return e(E.caller,E.id)},changeGroupRole:(v,b,w)=>{const x=`api/admin/projects/${v}/groups/${w}/roles/${b}`,E=t(x,{method:"PUT"});return e(E.caller,E.id)},errors:n,loading:r,searchProjectUser:async v=>{const b=`api/admin/user-admin/search?q=${v}`,w=t(b,{method:"GET"});try{return await e(w.caller,w.id)}catch(x){throw x}}}},Eue=({open:e,onClose:t,project:n,onSuccess:r})=>{const{deleteProject:o}=vC(),{refetch:a}=Bi(),{setToastData:i,setToastApiError:l}=It();return s(Zn,{open:e,onClick:async u=>{u.preventDefault();try{await o(n),a(),i({title:"Deleted project",type:"success",text:"Successfully deleted project"}),r==null||r()}catch(d){l(ft(d))}t==null||t()},onClose:t,title:"Really delete project"})},Tue=e=>p.createElement("svg",{width:88,height:40,viewBox:"0 0 88 40",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("rect",{width:9,height:39,fill:"#635DC5"}),p.createElement("rect",{x:13,width:10,height:39,fill:"#635DC5"}),p.createElement("rect",{x:27,y:6,width:9,height:33,fill:"#635DC5"}),p.createElement("rect",{x:40,y:12,width:9,height:27,fill:"#635DC5"}),p.createElement("rect",{x:52,y:15,width:9,height:24,fill:"#635DC5"}),p.createElement("rect",{x:65.0752,y:15.2578,width:9.2957,height:23.9101,fill:"#635DC5"}),p.createElement("rect",{x:78.355,y:19.0352,width:9.2957,height:20.1348,fill:"#635DC5"})),kue=C(G$)(({theme:e})=>({padding:e.spacing(1,2,2,2),width:"220px",height:"204px",display:"flex",flexDirection:"column",justifyContent:"space-between",margin:e.spacing(1),boxShadow:"none",border:`1px solid ${e.palette.tertiary.contrast}`,[e.breakpoints.down("sm")]:{justifyContent:"center"},"&:hover":{transition:"background-color 0.2s ease-in-out",backgroundColor:e.palette.projectCard.hover}})),Aue=C("div")(()=>({...Zp,width:"100%"})),_ue=C("h2")(({theme:e})=>({fontWeight:"normal",fontSize:e.fontSizes.bodySize,lineClamp:2,display:"-webkit-box",boxOrient:"vertical",textOverflow:"ellipsis",overflow:"hidden",alignItems:"flex-start"})),Rue=C(Me)(()=>({...Zp,marginRight:"auto"})),Pue=C(Za)(({theme:e})=>({color:e.palette.neutral.main,marginRight:e.spacing(1)})),Iue=C(Oo)(({theme:e})=>({color:e.palette.neutral.main,marginRight:e.spacing(1)})),$ue=C(Tue)(({theme:e})=>({margin:e.spacing(2,"auto"),width:"80px",display:"block"})),Oue=C("div")(({theme:e})=>({display:"flex",justifyContent:"space-between",fontSize:e.fontSizes.smallerBody})),_1=C("div")(()=>({textAlign:"center"})),R1=C("p")(({theme:e})=>({color:e.palette.projectCard.textColor,fontWeight:"bold"})),QA=({name:e,featureCount:t,health:n,memberCount:r,onHover:o,id:a,isFavorite:i=!1})=>{const{hasAccess:l}=p.useContext(Gr),{isOss:c}=Lt(),[u,d]=p.useState(null),[f,h]=p.useState(!1),m=lt(),{favorite:y,unfavorite:g}=xue(),{refetch:v}=Bi(),b=E=>{E.preventDefault(),d(E.currentTarget)},w=l($ne,a)&&a!==Fh;return T(kue,{onMouseEnter:o,children:[T(Aue,{"data-loading":!0,children:[T(Rue,{children:[s(Cue,{onClick:async E=>{E.preventDefault(),i?await g(a):await y(a),v()},isFavorite:i,size:"medium",sx:{ml:-1}}),s(_ue,{children:e})]}),s(ur,{style:{transform:"translateX(7px)"},permission:Bb,hidden:c(),projectId:a,"data-loading":!0,onClick:b,tooltipProps:{title:"Options"},children:s(gC,{})}),T(px,{id:"project-card-menu",open:Boolean(u),anchorEl:u,style:{top:0,left:-100},onClick:E=>{E.preventDefault()},onClose:E=>{E.preventDefault(),d(null)},children:[T(bs,{onClick:E=>{E.preventDefault(),m(Yae(a))},children:[s(Pue,{}),"Edit project"]}),T(bs,{onClick:E=>{E.preventDefault(),h(!0)},disabled:!w,children:[s(Iue,{}),a===Fh&&!w?"You can't delete the default project":"Delete project"]})]})]}),s("div",{"data-loading":!0,children:s($ue,{})}),T(Oue,{children:[T(_1,{children:[s(R1,{"data-loading":!0,children:t}),s("p",{"data-loading":!0,children:"toggles"})]}),T(_1,{children:[T(R1,{"data-loading":!0,children:[n,"%"]}),s("p",{"data-loading":!0,children:"health"})]}),s(X,{condition:a!==Fh,show:T(_1,{children:[s(R1,{"data-loading":!0,children:r}),s("p",{"data-loading":!0,children:"members"})]})})]}),s(Eue,{project:a,open:f,onClose:()=>{d(null),h(!1)}})]})},Lue=[{id:"loading1",name:"loading1",memberCount:1,health:95,featureCount:4,createdAt:"",description:""},{id:"loading2",name:"loading2",memberCount:1,health:95,featureCount:4,createdAt:"",description:""},{id:"loading3",name:"loading3",memberCount:1,health:95,featureCount:4,createdAt:"",description:""},{id:"loading4",name:"loading4",memberCount:1,health:95,featureCount:4,createdAt:"",description:""}],yO=({Icon:e,onClick:t,maxWidth:n,disabled:r=!1,children:o,permission:a,environmentId:i,projectId:l,...c})=>{const u=cr(`(max-width:${n})`);return s(X,{condition:u,show:s(ur,{disabled:r,onClick:t,permission:a,projectId:l,environmentId:i,"data-loading":!0,...c,children:s(e,{})}),elseShow:s(zo,{onClick:t,permission:a,projectId:l,color:"primary",variant:"contained",disabled:r,environmentId:i,"data-loading":!0,...c,children:o})})},Nue=({className:e,onClick:t,text:n,...r})=>s(Zt,{className:e||"",action:s(Ze,{color:"inherit",size:"small",onClick:t,children:"TRY AGAIN"}),severity:"error",...r,children:n}),bO=e=>p.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("path",{d:"M11.2608 0.811331C11.6574 0.375976 12.3426 0.375977 12.7392 0.811332L14.0529 2.25322C14.316 2.54202 14.7233 2.65114 15.0955 2.53259L16.9542 1.94073C17.5154 1.76203 18.1087 2.10458 18.2345 2.67993L18.6513 4.58549C18.7347 4.96716 19.0328 5.26527 19.4145 5.34875L21.3201 5.7655C21.8954 5.89133 22.238 6.48465 22.0593 7.04583L21.4674 8.90447C21.3489 9.27675 21.458 9.68397 21.7468 9.9471L23.1887 11.2608C23.624 11.6574 23.624 12.3426 23.1887 12.7392L21.7468 14.0529C21.458 14.316 21.3489 14.7233 21.4674 15.0955L22.0593 16.9542C22.238 17.5154 21.8954 18.1087 21.3201 18.2345L19.4145 18.6513C19.0328 18.7347 18.7347 19.0328 18.6513 19.4145L18.2345 21.3201C18.1087 21.8954 17.5154 22.238 16.9542 22.0593L15.0955 21.4674C14.7233 21.3489 14.316 21.458 14.0529 21.7468L12.7392 23.1887C12.3426 23.624 11.6574 23.624 11.2608 23.1887L9.9471 21.7468C9.68397 21.458 9.27675 21.3489 8.90447 21.4674L7.04583 22.0593C6.48465 22.238 5.89133 21.8954 5.7655 21.3201L5.34875 19.4145C5.26527 19.0328 4.96716 18.7347 4.58549 18.6513L2.67993 18.2345C2.10458 18.1087 1.76203 17.5154 1.94073 16.9542L2.53259 15.0955C2.65114 14.7233 2.54202 14.316 2.25322 14.0529L0.811331 12.7392C0.375976 12.3426 0.375977 11.6574 0.811332 11.2608L2.25322 9.9471C2.54202 9.68397 2.65114 9.27675 2.53259 8.90447L1.94073 7.04583C1.76203 6.48465 2.10458 5.89133 2.67993 5.7655L4.58549 5.34875C4.96716 5.26527 5.26527 4.96716 5.34875 4.58549L5.7655 2.67993C5.89133 2.10458 6.48465 1.76203 7.04583 1.94073L8.90447 2.53259C9.27675 2.65114 9.68397 2.54202 9.9471 2.25322L11.2608 0.811331Z",fill:"#1A4049"}),p.createElement("path",{d:"M10.4351 7.3042H7.30469V16.6955H16.696V7.3042H13.5656V13.5651H10.4351V7.3042Z",fill:"white"}),p.createElement("path",{d:"M13.5664 13.5649H16.6968V16.6954H13.5664V13.5649Z",fill:"#817AFE"})),Mue=C(Me,{shouldForwardProp:e=>e!=="tooltip"})(({theme:e,tooltip:t})=>({display:"flex",flexDirection:"column",alignItems:t?"start":"center",textAlign:t?"left":"center",backgroundColor:t?"transparent":e.palette.secondaryContainer,borderRadius:t?0:e.shape.borderRadiusLarge,padding:t?e.spacing(1,.5):e.spacing(7.5,1)})),Due=C(ye)(({theme:e})=>({display:"inline-flex",alignItems:"center",fontWeight:e.fontWeight.bold,gap:e.spacing(1)})),ZA=C("div",{shouldForwardProp:e=>e!=="tooltip"})(({theme:e,tooltip:t})=>({margin:t?e.spacing(1,0):e.spacing(3,0,5,0)})),P1=C(ye)(({theme:e})=>({fontSize:e.fontSizes.smallBody})),e_=C("div")(()=>({display:"flex"})),t_=C(go)(({theme:e})=>({fontSize:e.fontSizes.smallBody})),Bue={"adding-new-projects":{plan:"Pro & Enterprise",url:"",label:"Adding new projects"},access:{plan:"Pro & Enterprise",url:"https://docs.getunleash.io/reference/rbac",label:"Access"},"change-requests":{plan:"Enterprise",url:"https://docs.getunleash.io/reference/change-requests",label:"Change Requests"}},Fue="https://www.getunleash.io/plans",zue=({feature:e,tooltip:t})=>{const{url:n,plan:r,label:o}=Bue[e],a=ka(),i=()=>{a.trackEvent("upgrade_plan_clicked",{props:{feature:o}})},l=Boolean(n)?s(t_,{href:n,target:"_blank",children:o}):o,c=T(ke,{children:[l," is a feature available for the"," ",s("strong",{children:r})," ",r==="Pro & Enterprise"?"plans":"plan"]}),u=`${Fue}?feature=${e}`;return T(Mue,{tooltip:t,children:[T(Due,{children:[s(bO,{}),`${r} feature`]}),s(X,{condition:Boolean(t),show:T(ke,{children:[s(ZA,{tooltip:!0,children:T(P1,{children:[c,". You need to upgrade your plan if you want to use it"]})}),s(e_,{children:s(t_,{href:u,target:"_blank",onClick:i,children:"Upgrade now"})})]}),elseShow:T(ke,{children:[T(ZA,{children:[s(P1,{children:c}),s(P1,{children:"You need to upgrade your plan if you want to use it"})]}),s(e_,{children:s(Ze,{variant:"outlined",href:u,target:"_blank",onClick:i,children:"Upgrade now"})})]})})]})},jue=C("div")(({theme:e})=>({display:"flex",flexWrap:"wrap",[e.breakpoints.down("sm")]:{justifyContent:"center"}})),Uue=C(Nue)(({theme:e})=>({maxWidth:"400px",marginBottom:e.spacing(2)})),Wue=C(ln)(({theme:e})=>({color:"inherit",textDecoration:"none",border:"none",padding:"0",background:"transparent",fontFamily:e.typography.fontFamily,pointer:"cursor"}));function Hue(e,t){return e?{disabled:!0,tooltip:{titleComponent:s(zue,{feature:"adding-new-projects",tooltip:!0}),sx:{maxWidth:"320px"},variant:"custom"},endIcon:s(bO,{})}:t?{tooltip:{title:"Click to create a new project"},disabled:!1}:{tooltip:{title:"You do not have permission to create new projects"},disabled:!0}}const Vue=()=>{const{hasAccess:e}=p.useContext(Gr),t=lt(),{projects:n,loading:r,error:o,refetch:a}=Bi(),[i,l]=p.useState({}),{isOss:c}=Lt(),u=cr(ws.breakpoints.down("md")),[d,f]=tu(),[h,m]=p.useState(d.get("search")||"");p.useEffect(()=>{const x={};h&&(x.search=h),f(x,{replace:!0})},[h,f]);const y=p.useMemo(()=>{const x=Yx(h,"i");return(h?n.filter(E=>x.test(E.name)):n).sort((E,A)=>E!=null&&E.favorite&&!(A!=null&&A.favorite)?-1:!(E!=null&&E.favorite)&&(A!=null&&A.favorite)?1:0)},[n,h]),g=x=>{if(i[x])return;const{KEY:E,fetcher:A}=vO(x);Vr(E,A),l(k=>({...k,[x]:!0}))},v=Hue(c(),e(CA)),b=()=>s(Uue,{onClick:a,text:"Error fetching projects"});let w=y.length<n.length?`${y.length} of ${n.length}`:n.length;return T(fr,{isLoading:r,header:s(xn,{title:`Projects (${w})`,actions:T(ke,{children:[s(X,{condition:!u,show:T(ke,{children:[s(Hr,{initialValue:h,onChange:m}),s(xn.Divider,{})]})}),s(yO,{Icon:Ta,endIcon:v.endIcon,onClick:()=>t("/projects/create"),maxWidth:"700px",permission:CA,disabled:v.disabled,tooltipProps:v.tooltip,children:"New project"})]}),children:s(X,{condition:u,show:s(Hr,{initialValue:h,onChange:m})})}),children:[s(X,{condition:o,show:b()}),s(jue,{children:s(X,{condition:y.length<1&&!r,show:s(X,{condition:(h==null?void 0:h.length)>0,show:T(Un,{children:["No projects found matching “",h,"”"]}),elseShow:s(Un,{children:"No projects available."})}),elseShow:s(X,{condition:r,show:()=>Lue.map(x=>s(QA,{"data-loading":!0,onHover:()=>{},name:x.name,id:x.id,memberCount:2,health:95,featureCount:4},x.id)),elseShow:()=>y.map(x=>s(Wue,{to:`/projects/${x.id}`,children:s(QA,{onHover:()=>g(x.id),name:x.name,memberCount:x.memberCount??0,health:x.health,id:x.id,featureCount:x.featureCount,isFavorite:x.favorite})},x.id))})})})]})},Gue=()=>s(_l,{to:"/archive",replace:!0}),hu=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{validateEnvName:async h=>{const y=t("api/admin/environments/validate",{method:"POST",body:JSON.stringify({name:h})},"validateEnvName");try{return await e(y.caller,y.id,!1)}catch(g){throw g}},createEnvironment:async h=>{const y=t("api/admin/environments",{method:"POST",body:JSON.stringify(h)},"createEnvironment");try{return await e(y.caller,y.id)}catch(g){throw g}},errors:n,loading:r,deleteEnvironment:async h=>{const m=`api/admin/environments/${h}`,y=t(m,{method:"DELETE"},"deleteEnvironment");try{return await e(y.caller,y.id)}catch(g){throw g}},updateEnvironment:async(h,m)=>{const y=`api/admin/environments/update/${h}`,g=t(y,{method:"PUT",body:JSON.stringify(m)},"updateEnvironment");try{return await e(g.caller,g.id)}catch(v){throw v}},cloneEnvironment:async(h,m)=>{const y=`api/admin/environments/${h}/clone`,g=t(y,{method:"POST",body:JSON.stringify(m)},"cloneEnvironment");return await e(g.caller,g.id)},changeSortOrder:async h=>{const y=t("api/admin/environments/sort-order",{method:"PUT",body:JSON.stringify(h)},"changeSortOrder");try{return await e(y.caller,y.id)}catch(g){throw g}},toggleEnvironmentOff:async h=>{const m=`api/admin/environments/${h}/off`,y=t(m,{method:"POST"},"toggleEnvironmentOff");try{return await e(y.caller,y.id)}catch(g){throw g}},toggleEnvironmentOn:async h=>{const m=`api/admin/environments/${h}/on`,y=t(m,{method:"POST"},"toggleEnvironmentOn");try{return await e(y.caller,y.id)}catch(g){throw g}}}},que=e=>e.reduce((t,n,r)=>(t[n.name]=r+1,t),{}),wO=(e="",t="development")=>{const[n,r]=p.useState(e),[o,a]=p.useState(t),[i,l]=p.useState({});p.useEffect(()=>{r(e)},[e]),p.useEffect(()=>{a(t)},[t]);const{validateEnvName:c}=hu();return{name:n,setName:r,type:o,setType:a,getEnvPayload:()=>({name:n,type:o}),validateEnvironmentName:async()=>{if(n.length===0)return l(h=>({...h,name:"Environment name can not be empty"})),!1;try{return await c(n),!0}catch(h){return l(m=>({...m,name:ft(h)})),!1}},clearErrors:()=>{l({})},errors:i}},Kue=Li()(e=>({helperText:{position:"absolute",bottom:"-1rem",whiteSpace:"nowrap",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis"}})),Yue=C("div")({position:"relative"}),_r=({label:e,placeholder:t,error:n,errorText:r,style:o,className:a,value:i,onChange:l,...c})=>{const{classes:u}=Kue();return s(Yue,{"data-loading":!0,children:s(mn,{size:"small",variant:"outlined",label:e,placeholder:t,error:n,helperText:r,style:o,className:a||"",value:i,onChange:l,FormHelperTextProps:{["data-testid"]:G4,title:r,classes:{root:u.helperText}},...c})})},Xue=C(hx)({flexDirection:"row"}),n_=C("div")({display:"flex",flexDirection:"column"}),SO=({onChange:e,value:t})=>s(Pi,{component:"fieldset",children:T(Xue,{"data-loading":!0,value:t,onChange:e,children:[T(n_,{children:[s(Tr,{value:"development",label:"Development",control:s(ol,{})}),s(Tr,{value:"test",label:"Test",control:s(ol,{})})]}),T(n_,{children:[s(Tr,{value:"preproduction",label:"Pre production",control:s(ol,{})}),s(Tr,{value:"production",label:"Production",control:s(ol,{})})]})]})}),Bm={FIX:"fix",VARIABLE:"variable"},I1=e=>t=>{if(t.flag){const n=e.flags;return Boolean(n[t.flag])}return t.configFlag?Boolean(e[t.configFlag]):!0},Jue=()=>{window.scrollTo(0,0)},Cs=e=>e&&e.trim?e.trim():e,Que=e=>{const t=new Date(e);return xp(t,"yyyy-MM-dd")+"T"+xp(t,"HH:mm")},xO=e=>{const t=new Date(e);if(Kx(t))return t},mIe=e=>e/10;function gIe(e,t){if(e.length===0)return[];const n=e.reduce(({remainingPercentage:i,variableVariantCount:l},c)=>(c.weight&&c.weightType===Bm.FIX?i-=Number(c.weight):l+=1,{remainingPercentage:i,variableVariantCount:l}),{remainingPercentage:t,variableVariantCount:0}),{remainingPercentage:r,variableVariantCount:o}=n;if(r<0)throw new Error("The traffic distribution total must equal 100%");if(!o)throw new Error("There must be at least one variable variant");const a=parseInt(String(r/o));return e.map(i=>(i.weightType!==Bm.FIX&&(i.weight=a),i))}function vIe(e,t){if(e.length===0)return[];const{remainingPercentage:n,variableVariantCount:r}=e.reduce(({remainingPercentage:a,variableVariantCount:i},l)=>(l.weight&&l.weightType===Bm.FIX?a-=Number(l.weight):i+=1,{remainingPercentage:a,variableVariantCount:i}),{remainingPercentage:t,variableVariantCount:0}),o=parseInt(String(n/r));return e.map(a=>(a.weightType!==Bm.FIX&&(a.weight=o),a))}const Zue=C("form")({display:"flex",flexDirection:"column",height:"100%"}),ede=C("h3")({fontWeight:"normal",marginTop:"0"}),tde=C("div")({maxWidth:"440px"}),r_=C("p")(({theme:e})=>({marginBottom:e.spacing(1)})),nde=C(_r)(({theme:e})=>({width:"100%",marginBottom:e.spacing(2)})),rde=C("div")(({theme:e})=>({marginTop:"auto",display:"flex",justifyContent:"flex-end"})),ode=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),CO=({children:e,handleSubmit:t,handleCancel:n,name:r,type:o,setName:a,setType:i,validateEnvironmentName:l,errors:c,mode:u,clearErrors:d})=>T(Zue,{onSubmit:t,children:[s(ede,{children:"Environment information"}),T(tde,{children:[s(r_,{children:"What is your environment name? (Can't be changed later)"}),s(nde,{label:"Environment name",value:r,onChange:f=>a(Cs(f.target.value)),error:Boolean(c.name),errorText:c.name,onFocus:()=>d(),onBlur:l,disabled:u==="Edit",autoFocus:!0}),s(r_,{children:"What type of environment do you want to create?"}),s(SO,{onChange:f=>i(f.currentTarget.value),value:o})]}),T(rde,{children:[e,s(ode,{onClick:n,children:"Cancel"})]})]}),ade=C("div")(({theme:e})=>({backgroundColor:e.palette.codebox,padding:e.spacing(2),borderRadius:e.shape.borderRadiusMedium,position:"relative",maxHeight:"500px",overflow:"auto"})),ide=C("pre")(({theme:e})=>({margin:0,wordBreak:"break-all",whiteSpace:"pre-wrap",color:e.palette.formSidebarTextColor,fontSize:e.fontSizes.smallBody})),sde=({text:e})=>s(ade,{children:s(ide,{children:e})}),lde="/static/unleashLogoIconDarkAlpha-de056a82.gif",cde=C("div")(({theme:e})=>({display:"flex",justifyContent:"center",alignItems:"center",minHeight:"100vh",backgroundColor:e.palette.background.paper})),ude=C("img")(({theme:e})=>({width:"100px",height:"100px"})),Fm=()=>s(cde,{role:"alert","aria-label":"Loading",children:s(ude,{src:Ys(lde),alt:""})});var dde=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,n=[],r=0;r<e.rangeCount;r++)n.push(e.getRangeAt(r));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null;break}return e.removeAllRanges(),function(){e.type==="Caret"&&e.removeAllRanges(),e.rangeCount||n.forEach(function(o){e.addRange(o)}),t&&t.focus()}},pde=dde,o_={"text/plain":"Text","text/html":"Url",default:"Text"},fde="Copy to clipboard: #{key}, Enter";function hde(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}function mde(e,t){var n,r,o,a,i,l,c=!1;t||(t={}),n=t.debug||!1;try{o=pde(),a=document.createRange(),i=document.getSelection(),l=document.createElement("span"),l.textContent=e,l.ariaHidden="true",l.style.all="unset",l.style.position="fixed",l.style.top=0,l.style.clip="rect(0, 0, 0, 0)",l.style.whiteSpace="pre",l.style.webkitUserSelect="text",l.style.MozUserSelect="text",l.style.msUserSelect="text",l.style.userSelect="text",l.addEventListener("copy",function(d){if(d.stopPropagation(),t.format)if(d.preventDefault(),typeof d.clipboardData>"u"){n&&console.warn("unable to use e.clipboardData"),n&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var f=o_[t.format]||o_.default;window.clipboardData.setData(f,e)}else d.clipboardData.clearData(),d.clipboardData.setData(t.format,e);t.onCopy&&(d.preventDefault(),t.onCopy(d.clipboardData))}),document.body.appendChild(l),a.selectNodeContents(l),i.addRange(a);var u=document.execCommand("copy");if(!u)throw new Error("copy command was unsuccessful");c=!0}catch(d){n&&console.error("unable to copy using execCommand: ",d),n&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),c=!0}catch(f){n&&console.error("unable to copy using clipboardData: ",f),n&&console.error("falling back to prompt"),r=hde("message"in t?t.message:fde),window.prompt(r,e)}}finally{i&&(typeof i.removeRange=="function"?i.removeRange(a):i.removeAllRanges()),l&&document.body.removeChild(l),o()}return c}var EO=mde;const gde=e=>p.createElement("svg",{width:48,height:50,viewBox:"0 0 48 50",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("path",{d:"M0.5 0.000193412C11 2.00019 17 9 18 18C19 27 23.5 31.5 30.5 34C37.5 36.5 47.34 41.4 48 49.5L48 12.0012C48 5.37332 42.6309 0.000381623 36.003 0.000366343C24.1359 0.000338986 8.66406 -0.000263908 0.5 0.000193412Z",fill:"#6C65E5"})),TO="27.5rem",vde=C("section",{shouldForwardProp:e=>e!=="modal"})(({theme:e,modal:t})=>({minHeight:t?"100vh":"80vh",borderRadius:t?0:e.spacing(2),width:"100%",display:"flex",margin:"0 auto",overflow:"hidden",[e.breakpoints.down(1100)]:{flexDirection:"column",minHeight:0}})),yde=C("div")(({theme:e})=>lte),bde=C("div")(({theme:e})=>({backgroundColor:e.palette.formBackground,display:"flex",flexDirection:"column",padding:e.spacing(6),flexGrow:1,[e.breakpoints.down("lg")]:{padding:e.spacing(4)},[e.breakpoints.down(1100)]:{width:"100%"},[e.breakpoints.down(500)]:{padding:e.spacing(4,2)}})),wde=C("h1")(({theme:e})=>({marginBottom:e.fontSizes.mainHeader,fontWeight:"normal"})),Sde=C(mo)(({theme:e})=>({opacity:.3,marginBottom:e.spacing(.5)})),xde=C("h2")(({theme:e})=>({color:e.palette.formSidebarTextColor,marginBottom:e.spacing(2),display:"flex",justifyContent:"space-between",alignItems:"center",fontWeight:e.fontWeight.bold,fontSize:e.fontSizes.bodySize})),Cde=C(L4)(({theme:e})=>({fill:e.palette.text.tertiaryContrast})),Ede=C("div")(()=>({zIndex:1,position:"absolute",right:-3,top:-3})),Tde=C(gde)(()=>({width:"75px",height:"75px"})),kde=C(Yt)(()=>({position:"absolute",zIndex:400,right:0})),Ade=C(MZ)(({theme:e})=>({fill:e.palette.text.tertiaryContrast})),_de=C("aside")(({theme:e})=>({backgroundColor:e.palette.formSidebar,padding:e.spacing(4),flexGrow:0,flexShrink:0,width:TO,[e.breakpoints.down(1100)]:{width:"100%",color:"red"},[e.breakpoints.down(500)]:{padding:e.spacing(4,2)}})),Rde=C("p")(({theme:e})=>({color:e.palette.formSidebarTextColor,zIndex:1,position:"relative"})),Pde=C("div")(({theme:e})=>({margin:e.spacing(3,0),display:"flex",alignItems:"center"})),Ide=C(Fx)(({theme:e})=>({marginRight:e.spacing(1),color:e.palette.text.tertiaryContrast})),$de=C("a")(({theme:e})=>({color:e.palette.text.tertiaryContrast,display:"block","&:hover":{textDecoration:"none"}})),Mr=({title:e,description:t,children:n,documentationLink:r,documentationLinkLabel:o,loading:a,modal:i,formatApiCode:l})=>{const{setToastData:c}=It(),u=cr(`(max-width:${1099}px)`);return T(vde,{modal:i,children:[s(X,{condition:u,show:s(yde,{children:s(Ode,{description:t,documentationLink:r,documentationLinkLabel:o})})}),T(bde,{children:[s(X,{condition:a||!1,show:s(Fm,{}),elseShow:T(ke,{children:[s(wde,{children:e}),n]})})," "]}),s(X,{condition:!u,show:T(kO,{description:t,documentationLink:r,documentationLinkLabel:o,children:[s(Sde,{}),T(xde,{children:["API Command"," ",s(_t,{title:"Copy command",arrow:!0,children:s(Yt,{onClick:()=>{EO(l())?c({title:"Successfully copied the command",text:"The command should now be automatically copied to your clipboard",autoHideDuration:6e3,type:"success",show:!0}):c({title:"Could not copy the command",text:"Sorry, but we could not copy the command.",autoHideDuration:6e3,type:"error",show:!0})},size:"large",children:s(Cde,{})})})]}),s(sde,{text:l()})]})})]})},Ode=({description:e,documentationLink:t,documentationLinkLabel:n})=>{const[r,o]=p.useState(!1);return T(ke,{children:[s(Ede,{children:s(Tde,{})}),s(_t,{title:"Toggle help",arrow:!0,children:s(kde,{onClick:()=>o(a=>!a),size:"large",children:s(Ade,{})})}),s(z$,{in:r,timeout:500,children:s(kO,{description:e,documentationLink:t,documentationLinkLabel:n})})]})},kO=({description:e,children:t,documentationLink:n,documentationLinkLabel:r="Learn more"})=>T(_de,{children:[s(Rde,{children:e}),T(Pde,{children:[s(Ide,{}),s($de,{href:n,rel:"noopener noreferrer",target:"_blank",children:r})]}),t]}),mu=({name:e,...t})=>T(zo,{type:"submit",...t,children:["Create ",e]}),yC=(e={})=>{const t=()=>{const c=Dt("api/admin/permissions");return fetch(c,{method:"GET"}).then(yn("Project permissions")).then(u=>u.json())},n="api/admin/permissions",{data:r,error:o}=dn(n,t,e),[a,i]=p.useState(!o&&!r),l=()=>{Vr(n)};return p.useEffect(()=>{i(!o&&!r)},[r,o]),{permissions:(r==null?void 0:r.permissions)||{project:[],environments:[]},error:o,loading:a,refetch:l}},jo=-1,zm=50,Lde=()=>{const{setToastApiError:e,setToastData:t}=It(),{uiConfig:n}=Lt(),r=lt(),{environments:o}=uu(),a=o.length<zm,{createEnvironment:i,loading:l}=hu(),{refetch:c}=yC(),{name:u,setName:d,type:f,setType:h,getEnvPayload:m,validateEnvironmentName:y,clearErrors:g,errors:v}=wO(),b=async E=>{if(E.preventDefault(),g(),await y()){const k=m();try{await i(k),c(),t({title:"Environment created",type:"success",confetti:!0}),r("/environments")}catch(_){e(ft(_))}}},w=()=>`curl --location --request POST '${n.unleashUrl}/api/admin/environments' \\
|
|
268
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
269
|
+
--header 'Content-Type: application/json' \\
|
|
270
|
+
--data-raw '${JSON.stringify(m(),void 0,2)}'`,x=()=>{r(jo)};return s(X,{condition:a,show:s(Mr,{loading:l,title:"Create environment",description:`Environments allow you to manage your
|
|
271
|
+
product lifecycle from local development
|
|
272
|
+
through production. Your projects and
|
|
273
|
+
feature toggles are accessible in all your
|
|
274
|
+
environments, but they can take different
|
|
275
|
+
configurations per environment. This means
|
|
276
|
+
that you can enable a feature toggle in a
|
|
277
|
+
development or test environment without
|
|
278
|
+
enabling the feature toggle in the
|
|
279
|
+
production environment.`,documentationLink:"https://docs.getunleash.io/reference/environments",documentationLinkLabel:"Environments documentation",formatApiCode:w,children:s(CO,{errors:v,handleSubmit:b,handleCancel:x,validateEnvironmentName:y,name:u,type:f,setName:d,setType:h,mode:"Create",clearErrors:g,children:s(mu,{name:"environment",permission:Fo})})}),elseShow:s(ke,{children:T(fr,{header:s(xn,{title:"Create environment"}),children:[s(Zt,{severity:"error",children:T("p",{children:["Currently Unleash does not support more than"," ",zm," environments. If you need more please reach out."]})}),s("br",{}),s(Ze,{onClick:x,variant:"contained",color:"primary",children:"Go back"})]})})})},Pl=({...e})=>s(zo,{type:"submit",...e,children:"Save"}),Nde={name:"",type:"",createdAt:"",sortOrder:0,enabled:!1,protected:!1},Mde=(e,t={})=>{const n=async()=>{const u=Dt(`api/admin/environments/${e}`);return fetch(u,{method:"GET"}).then(yn("Environment data")).then(d=>d.json())},r=`api/admin/environments/${e}`,{data:o,error:a}=dn(r,n,{...t}),[i,l]=p.useState(!a&&!o),c=()=>{Vr(r)};return p.useEffect(()=>{l(!a&&!o)},[o,a]),{environment:o||Nde,error:a,loading:i,refetch:c,FEATURE_CACHE_KEY:r}},Dde=()=>{const{uiConfig:e}=Lt(),{setToastData:t,setToastApiError:n}=It(),r=dr("id"),{environment:o}=Mde(r),{updateEnvironment:a}=hu(),i=lt(),{name:l,type:c,setName:u,setType:d,errors:f,clearErrors:h}=wO(o.name,o.type),{refetch:m}=yC(),y=()=>({type:c,sortOrder:o.sortOrder});return s(Mr,{title:"Edit environment",description:`Environments allow you to manage your
|
|
280
|
+
product lifecycle from local development
|
|
281
|
+
through production. Your projects and
|
|
282
|
+
feature toggles are accessible in all your
|
|
283
|
+
environments, but they can take different
|
|
284
|
+
configurations per environment. This means
|
|
285
|
+
that you can enable a feature toggle in a
|
|
286
|
+
development or test environment without
|
|
287
|
+
enabling the feature toggle in the
|
|
288
|
+
production environment.`,documentationLink:"https://docs.getunleash.io/reference/environments",documentationLinkLabel:"Environments documentation",formatApiCode:()=>`curl --location --request PUT '${e.unleashUrl}/api/admin/environments/update/${r}' \\
|
|
289
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
290
|
+
--header 'Content-Type: application/json' \\
|
|
291
|
+
--data-raw '${JSON.stringify(y(),void 0,2)}'`,children:s(CO,{handleSubmit:async w=>{w.preventDefault();try{await a(r,y()),m(),i("/environments"),t({type:"success",title:"Successfully updated environment."})}catch(x){n(ft(x))}},handleCancel:()=>{i(jo)},name:l,type:c,setName:u,setType:d,mode:"Edit",errors:f,clearErrors:h,children:s(Pl,{permission:Fo})})})},$v=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0}),o="api/admin/context";return{createContext:async u=>{const f=t(o,{method:"POST",body:JSON.stringify(u)});try{return await e(f.caller,f.id)}catch(h){throw h}},validateContextName:async u=>{const d=`${o}/validate`,f=t(d,{method:"POST",body:JSON.stringify({name:u})});try{return await e(f.caller,f.id)}catch(h){throw h}},updateContext:async u=>{const d=`${o}/${u.name}`,f=t(d,{method:"PUT",body:JSON.stringify(u)});try{return await e(f.caller,f.id)}catch(h){throw h}},removeContext:async u=>{const d=`${o}/${u}`,f=t(d,{method:"DELETE"});try{return await e(f.caller,f.id)}catch(h){throw h}},errors:n,loading:r}},Bde=(e,t={})=>{const n=async()=>{const u=Dt(`api/admin/context/${e}`);return fetch(u,{method:"GET"}).then(yn("Context data")).then(d=>d.json())},r=`api/admin/context/${e}`,{data:o,error:a}=dn(r,n,{...t}),[i,l]=p.useState(!a&&!o),c=()=>{Vr(r)};return p.useEffect(()=>{l(!a&&!o)},[o,a]),{context:o||{name:"",description:"",legalValues:[],stickiness:!1},error:a,loading:i,refetch:c,FEATURE_CACHE_KEY:r}},Fde=C("li")(({theme:e})=>({display:"grid",lineHeight:1.25,gridTemplateColumns:"1fr auto",alignSelf:"start",alignItems:"start",gap:e.spacing(1),padding:e.spacing(1),background:e.palette.secondaryContainer,borderRadius:e.shape.borderRadius,wordBreak:"break-word"})),zde=C("div")(({theme:e})=>({fontSize:e.fontSizes.smallBody})),jde=C("div")(({theme:e})=>({fontSize:e.fontSizes.smallerBody,color:e.palette.neutral.main})),Ude=C("button")(({theme:e})=>({all:"unset",lineHeight:.1,paddingTop:"1px",display:"block",cursor:"pointer","& svg":{fontSize:e.fontSizes.bodySize,opacity:.5},"&:hover svg, &:focus-visible svg":{opacity:.75}})),Wde=({label:e,description:t,onRemove:n})=>T(Fde,{children:[T("div",{children:[s(zde,{children:e}),s(X,{condition:Boolean(t),show:()=>s(jde,{children:t})})]}),s(Ude,{onClick:n,children:s(kZ,{titleAccess:"Remove"})})]}),Hde=C("ul")(({theme:e})=>({listStyleType:"none",display:"flex",flexWrap:"wrap",gap:e.spacing(1),padding:0,margin:0,marginBottom:"1rem !important"})),Vde=Hde,Gde="Enter",qde=C("form")({display:"flex",flexDirection:"column",height:"100%"}),Kde=C("div")({maxWidth:"470px"}),$1=C("p")(({theme:e})=>({marginBottom:e.spacing(1)})),a_=e=>({width:"100%",marginBottom:e.spacing(2)}),Yde=C("div")(({theme:e})=>({display:"grid",gridTemplateColumns:"1fr auto",gap:e.spacing(1),marginBottom:e.spacing(2)})),Xde=C("p")(({theme:e})=>({marginBottom:e.spacing(.5)})),Jde=C("div")({display:"flex",alignItems:"center",marginLeft:"-9px"}),Qde=C("div")({marginTop:"auto",display:"flex",justifyContent:"flex-end"}),Zde=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),AO=({children:e,handleSubmit:t,onCancel:n,contextName:r,contextDesc:o,legalValues:a,stickiness:i,setContextName:l,setContextDesc:c,setLegalValues:u,setStickiness:d,errors:f,mode:h,validateContext:m,setErrors:y,clearErrors:g})=>{const[v,b]=p.useState(""),[w,x]=p.useState(""),[E,A]=p.useState(!1),k=w.trim()&&!v.trim(),_=a.some(F=>F.value.trim()===v.trim());p.useEffect(()=>{y(F=>({...F,tag:k?"Value cannot be empty":_?"Duplicate value":void 0}))},[y,k,_]);const $=F=>{F.preventDefault(),t(F)},L=F=>{F.key===Gde&&(F.preventDefault(),E?P():t(F))},O=(F,U)=>F.value.toLowerCase().localeCompare(U.value.toLowerCase()),P=()=>{const F={value:v.trim(),description:w.trim()};F.value&&!_&&(b(""),x(""),u(U=>[...U,F].sort(O)))},D=F=>{u(U=>U.filter(Y=>Y.value!==F.value))};return T(qde,{onSubmit:$,children:[T(Kde,{children:[s($1,{children:"What is your context name?"}),s(_r,{sx:a_,label:"Context name",value:r,disabled:h==="Edit",onChange:F=>l(F.target.value.trim()),error:Boolean(f.name),errorText:f.name,onFocus:()=>g("name"),onBlur:m,autoFocus:!0}),s($1,{children:"What is this context for?"}),s(mn,{sx:a_,label:"Context description (optional)",variant:"outlined",multiline:!0,maxRows:4,value:o,size:"small",onChange:F=>c(F.target.value)}),s($1,{children:"Which values do you want to allow?"}),T(Yde,{children:[s(mn,{label:"Legal value (optional)",name:"value",sx:{gridColumn:1},value:v,error:Boolean(f.tag),helperText:f.tag,variant:"outlined",size:"small",onChange:F=>b(F.target.value),onKeyPress:F=>L(F),onBlur:()=>A(!1),onFocus:()=>A(!0),inputProps:{maxLength:100}}),s(mn,{label:"Value description (optional)",sx:{gridColumn:1},value:w,variant:"outlined",size:"small",onChange:F=>x(F.target.value),onKeyPress:F=>L(F),onBlur:()=>A(!1),onFocus:()=>A(!0),inputProps:{maxLength:100}}),s(Ze,{sx:{gridColumn:2},startIcon:s(Ta,{}),onClick:P,variant:"outlined",color:"primary",disabled:!v.trim()||_,children:"Add"})]}),s(Vde,{children:a.map(F=>s(Wde,{label:F.value,description:F.description,onRemove:()=>D(F)},F.value))}),s(Xde,{children:"Custom stickiness"}),T("p",{children:["By enabling stickiness on this context field you can use it together with the flexible-rollout strategy. This will guarantee a consistent behavior for specific values of this context field. PS! Not all client SDK's support this feature yet!"," ",s("a",{href:"https://docs.getunleash.io/reference/stickiness",target:"_blank",rel:"noreferrer",children:"Read more"})]}),T(Jde,{children:[s(Ii,{checked:i,value:i,onChange:()=>d(!i)}),s(ye,{children:i?"On":"Off"})]})]}),T(Qde,{children:[e,s(Zde,{onClick:n,children:"Cancel"})]})]})},_O=(e="",t="",n=[],r=!1)=>{const[o,a]=p.useState(e),[i,l]=p.useState(t),[c,u]=p.useState(n),[d,f]=p.useState(r),[h,m]=p.useState({}),{validateContextName:y}=$v();return p.useEffect(()=>{a(e)},[e]),p.useEffect(()=>{l(t)},[t]),p.useEffect(()=>{u(n)},[n.length]),p.useEffect(()=>{f(r)},[r]),{contextName:o,contextDesc:i,legalValues:c,stickiness:d,setContextName:a,setContextDesc:l,setLegalValues:u,setStickiness:f,getContextPayload:()=>({name:o,description:i,legalValues:c,stickiness:d}),validateContext:async()=>{if(o.length===0)return m(w=>({...w,name:"Name can not be empty."})),!1;try{return await y(o),!0}catch(w){return m(x=>({...x,name:ft(w)})),!1}},setErrors:m,clearErrors:w=>{m(w?x=>({...x,[w]:void 0}):{})},errors:h}},epe=()=>{p.useEffect(()=>{Jue()},[]);const{uiConfig:e}=Lt(),{setToastData:t,setToastApiError:n}=It(),r=dr("name"),{context:o,refetch:a}=Bde(r),{updateContext:i,loading:l}=$v(),c=lt(),{contextName:u,contextDesc:d,legalValues:f,stickiness:h,setContextName:m,setContextDesc:y,setLegalValues:g,setStickiness:v,getContextPayload:b,clearErrors:w,setErrors:x,errors:E}=_O(o==null?void 0:o.name,o==null?void 0:o.description,o==null?void 0:o.legalValues,o==null?void 0:o.stickiness);return s(Mr,{loading:l,title:"Edit context",description:`Context fields are a basic building block used in Unleash to control roll-out.
|
|
292
|
+
They can be used together with strategy constraints as part of the activation strategy evaluation.`,documentationLink:"https://docs.getunleash.io/reference/unleash-context#custom-context-fields",documentationLinkLabel:"Context fields documentation",formatApiCode:()=>`curl --location --request PUT '${e.unleashUrl}/api/admin/context/${r}' \\
|
|
293
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
294
|
+
--header 'Content-Type: application/json' \\
|
|
295
|
+
--data-raw '${JSON.stringify(b(),void 0,2)}'`,children:s(AO,{errors:E,handleSubmit:async $=>{$.preventDefault();const L=b();try{await i(L),a(),c("/context"),t({title:"Context information updated",type:"success"})}catch(O){n(ft(O))}},onCancel:()=>{c(jo)},contextName:u,setContextName:m,contextDesc:d,setContextDesc:y,legalValues:f,setLegalValues:g,stickiness:h,setStickiness:v,mode:"Edit",setErrors:x,clearErrors:w,children:s(Pl,{permission:h3})})})},RO=(e="",t="")=>{const[n,r]=p.useState(e),[o,a]=p.useState(t),[i,l]=p.useState({}),{validateTagName:c}=kv();return p.useEffect(()=>{r(e)},[e]),p.useEffect(()=>{a(t)},[t]),{tagName:n,tagDesc:o,setTagName:r,setTagDesc:a,getTagPayload:()=>({name:n,description:o}),clearErrors:()=>{l({})},validateNameUniqueness:async()=>{if(n.length===0)return l(h=>({...h,name:"Name can not be empty."})),!1;if(n.length<2)return l(h=>({...h,name:"Tag name length must be at least 2 characters long"})),!1;try{return await c(n),!0}catch(h){return l(m=>({...m,name:ft(h)})),!1}},errors:i}},tpe="Edit",yIe="Create",npe=C("form")(({theme:e})=>({display:"flex",flexDirection:"column",height:"100%"})),rpe=C("div")(({theme:e})=>({maxWidth:"400px"})),i_=C("p")(({theme:e})=>({marginBottom:e.spacing(1)})),ope=C(_r)(({theme:e})=>({width:"100%",marginBottom:e.spacing(2)})),ape=C(mn)(({theme:e})=>({width:"100%",marginBottom:e.spacing(2)})),ipe=C("div")(({theme:e})=>({marginTop:"auto",display:"flex",justifyContent:"flex-end"})),spe=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),PO=({children:e,handleSubmit:t,handleCancel:n,tagName:r,tagDesc:o,setTagName:a,setTagDesc:i,errors:l,mode:c,validateNameUniqueness:u,clearErrors:d})=>T(npe,{onSubmit:t,children:[T(rpe,{children:[s(i_,{children:"What is your tag name?"}),s(ope,{label:"Tag name",value:r,onChange:f=>a(Cs(f.target.value)),error:Boolean(l.name),errorText:l.name,onFocus:()=>d(),disabled:c===tpe,onBlur:u,autoFocus:!0}),s(i_,{children:"What is this tag for?"}),s(ape,{label:"Tag description",variant:"outlined",multiline:!0,maxRows:4,value:o,onChange:f=>i(f.target.value)})]}),T(ipe,{children:[e,s(spe,{onClick:n,children:"Cancel"})]})]}),lpe=(e,t={})=>{const n=async()=>{const u=Dt(`api/admin/tag-types/${e}`);return fetch(u,{method:"GET"}).then(yn("Tag data")).then(d=>d.json())},r=`api/admin/tag-types/${e}`,{data:o,error:a}=dn(r,n,{...t}),[i,l]=p.useState(!a&&!o),c=()=>{Vr(r)};return p.useEffect(()=>{l(!a&&!o)},[o,a]),{tagType:(o==null?void 0:o.tagType)||{name:"",description:""},error:a,loading:i,refetch:c,FEATURE_CACHE_KEY:r}},cpe=()=>{const{setToastData:e,setToastApiError:t}=It(),{uiConfig:n}=Lt(),r=lt(),o=dr("name"),{tagType:a}=lpe(o),{tagName:i,tagDesc:l,setTagName:c,setTagDesc:u,getTagPayload:d,errors:f,clearErrors:h}=RO(a==null?void 0:a.name,a==null?void 0:a.description),{updateTagType:m,loading:y}=kv();return s(Mr,{loading:y,title:"Edit tag type",description:"Tag types allow you to group tags together in the management UI",documentationLink:"https://docs.getunleash.io/",documentationLinkLabel:"Tags documentation",formatApiCode:()=>`curl --location --request PUT '${n.unleashUrl}/api/admin/tag-types/${o}' \\
|
|
296
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
297
|
+
--header 'Content-Type: application/json' \\
|
|
298
|
+
--data-raw '${JSON.stringify(d(),void 0,2)}'`,children:s(PO,{errors:f,handleSubmit:async w=>{w.preventDefault(),h();const x=d();try{await m(i,x),r("/tag-types"),e({title:"Tag type updated",type:"success"})}catch(E){t(ft(E))}},handleCancel:()=>{r(jo)},tagName:i,setTagName:c,tagDesc:l,setTagDesc:u,mode:"Edit",clearErrors:h,children:s(Pl,{permission:Sp})})})},upe=()=>{const{setToastData:e,setToastApiError:t}=It(),{uiConfig:n}=Lt(),r=lt(),{tagName:o,tagDesc:a,setTagName:i,setTagDesc:l,getTagPayload:c,validateNameUniqueness:u,errors:d,clearErrors:f}=RO(),{createTag:h,loading:m}=kv();return s(Mr,{loading:m,title:"Create tag type",description:"Tag types allow you to group tags together in the management UI",documentationLink:"https://docs.getunleash.io/reference/tags",documentationLinkLabel:"Tags documentation",formatApiCode:()=>`curl --location --request POST '${n.unleashUrl}/api/admin/tag-types' \\
|
|
299
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
300
|
+
--header 'Content-Type: application/json' \\
|
|
301
|
+
--data-raw '${JSON.stringify(c(),void 0,2)}'`,children:s(PO,{errors:d,handleSubmit:async b=>{if(b.preventDefault(),f(),await u()){const x=c();try{await h(x),r("/tag-types"),e({title:"Tag type created",confetti:!0,type:"success"})}catch(E){t(ft(E))}}},handleCancel:()=>{r(jo)},tagName:o,setTagName:i,tagDesc:a,setTagDesc:l,mode:"Create",clearErrors:f,validateNameUniqueness:u,children:s(mu,{name:"type",permission:Sp})})})},dpe=C("form")(()=>({display:"flex",flexDirection:"column",height:"100%"})),ppe=C("div")(()=>({maxWidth:"400px"})),O1=C("p")(({theme:e})=>({marginBottom:e.spacing(1)})),s_=C(_r)(({theme:e})=>({width:"100%",marginBottom:e.spacing(2)})),fpe=C(mn)(({theme:e})=>({width:"100%",marginBottom:e.spacing(2)})),hpe=C("div")(()=>({marginTop:"auto",display:"flex",justifyContent:"flex-end"})),mpe=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),gpe=({children:e,handleSubmit:t,handleCancel:n,projectId:r,projectName:o,projectDesc:a,setProjectId:i,setProjectName:l,setProjectDesc:c,errors:u,mode:d,validateProjectId:f,clearErrors:h})=>T(dpe,{onSubmit:t,children:[T(ppe,{children:[s(O1,{children:"What is your project Id?"}),s(s_,{label:"Project Id",value:r,onChange:m=>i(Cs(m.target.value)),error:Boolean(u.id),errorText:u.id,onFocus:()=>h(),onBlur:f,disabled:d==="Edit",autoFocus:!0,required:!0}),s(O1,{children:"What is your project name?"}),s(s_,{label:"Project name",value:o,onChange:m=>l(m.target.value),error:Boolean(u.name),errorText:u.name,onFocus:()=>h(),required:!0}),s(O1,{children:"What is your project description?"}),s(fpe,{label:"Project description",variant:"outlined",multiline:!0,maxRows:4,value:a,onChange:m=>c(m.target.value)})]}),T(hpe,{children:[e,s(mpe,{onClick:n,children:"Cancel"})]})]}),vpe=(e="",t="",n="")=>{const[r,o]=p.useState(e),[a,i]=p.useState(t),[l,c]=p.useState(n),[u,d]=p.useState({}),{validateId:f}=vC();p.useEffect(()=>{o(e)},[e]),p.useEffect(()=>{i(t)},[t]),p.useEffect(()=>{c(n)},[n]);const h=()=>({id:r,name:a,description:l});return{projectId:r,projectName:a,projectDesc:l,setProjectId:o,setProjectName:i,setProjectDesc:c,getProjectPayload:h,validateName:()=>a.length===0?(d(v=>({...v,name:"Name can not be empty."})),!1):!0,validateProjectId:async()=>{if(r.length===0)return d(v=>({...v,id:"Id can not be empty."})),!1;try{return await f(h()),!0}catch(v){return d(b=>({...b,id:ft(v)})),!1}},clearErrors:()=>{d({})},errors:u}},ype={features:[],environments:[],name:"",health:0,members:0,version:"1",description:"Default",favorite:!1,stats:{archivedCurrentWindow:0,archivedPastWindow:0,avgTimeToProdCurrentWindow:0,avgTimeToProdPastWindow:0,createdCurrentWindow:0,createdPastWindow:0,projectActivityCurrentWindow:0,projectActivityPastWindow:0,projectMembersAddedCurrentWindow:0}},qb=(e,t={})=>{const{KEY:n,fetcher:r}=vO(e),{data:o,error:a,mutate:i}=dn(n,r,t),l=p.useCallback(()=>{i()},[i]);return{project:o||ype,loading:!a&&!o,error:a,refetch:l}},bIe=e=>qb(e).project.name||e,bpe=()=>{const{uiConfig:e}=Lt(),{setToastData:t,setToastApiError:n}=It(),{hasAccess:r}=p.useContext(Gr),o=dr("projectId"),{project:a}=qb(o),i=lt(),{projectId:l,projectName:c,projectDesc:u,setProjectId:d,setProjectName:f,setProjectDesc:h,getProjectPayload:m,clearErrors:y,validateProjectId:g,validateName:v,errors:b}=vpe(o,a.name,a.description),w=()=>`curl --location --request PUT '${e.unleashUrl}/api/admin/projects/${o}' \\
|
|
302
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
303
|
+
--header 'Content-Type: application/json' \\
|
|
304
|
+
--data-raw '${JSON.stringify(m(),void 0,2)}'`,{refetch:x}=qb(o),{editProject:E,loading:A}=vC(),k=async L=>{L.preventDefault();const O=m();if(v())try{await E(o,O),x(),i(`/projects/${o}`),t({title:"Project information updated",type:"success"})}catch(D){n(ft(D))}},_=()=>{i(jo)},$=!r(Bb,l)&&s(Zt,{severity:"error",sx:{mb:4},children:"You do not have the required permissions to edit this project."});return T(Mr,{loading:A,title:"Edit project",description:"Projects allows you to group feature toggles together in the management UI.",documentationLink:"https://docs.getunleash.io/reference/projects",documentationLinkLabel:"Projects documentation",formatApiCode:w,children:[$,s(gpe,{errors:b,handleSubmit:k,handleCancel:_,projectId:l,setProjectId:d,projectName:c,setProjectName:f,projectDesc:u,setProjectDesc:h,mode:"Edit",clearErrors:y,validateProjectId:g,children:s(Pl,{permission:Bb,projectId:l})})]})},wpe=({editable:e,value:t,id:n,label:r,onChange:o,...a})=>{const{featureTypes:i}=nC(),l=i.map(c=>({key:c.id,label:c.name,title:c.description}));return l.some(c=>c.key===t)||l.push({key:t,label:t}),s(ke,{children:s(du,{disabled:!e,options:l,value:t,onChange:o,label:r,id:n,...a})})},Spe=(e=[],t)=>{let n=!1;const r=e.reduce((o,a)=>(a.permission===Fo&&(n=!0),a.project&&a.permission===t&&(o[a.project]=t),o),{});return o=>n||Boolean(r[o])},xpe=({enabled:e,value:t,onChange:n,filter:r,...o})=>{const{projects:a}=Bi();if(!e)return null;const i=c=>({key:c.id,label:c.name,title:c.description});let l;return r?l=a.filter(c=>r(c.id)).map(i):l=a.map(i),t&&!l.find(c=>c.key===t)&&l.push({key:t,label:t}),s(du,{label:"Project",options:l,value:t,onChange:n,...o})},Cpe=(e,t)=>{let n=e.data&&"permissions"in e.data?e.data.permissions:void 0;return n&&(t!=null&&t.maintenanceMode)&&(n=n.filter(r=>r.permission==="ADMIN")),n},bC=()=>{const e=tf(),{uiConfig:t}=Lt();return{permissions:Cpe(e,t),refetchPermissions:e.refetchAuth,loading:e.loading,error:e.error}},Epe=C("form")({display:"flex",flexDirection:"column",height:"100%"}),Tpe=C("div")({maxWidth:"400px"}),ah=C("p")(({theme:e})=>({marginBottom:e.spacing(1),color:e.palette.text.secondary})),l_=C(_r)(({theme:e})=>({width:"100%",marginBottom:e.spacing(2)})),kpe=C(Pi)(({theme:e})=>({width:"100%",marginBottom:e.spacing(2)})),c_=e=>({marginBottom:e.spacing(2),minWidth:"400px",[e.breakpoints.down("sm")]:{minWidth:"379px"}}),Ape=C("p")(({theme:e})=>({fontSize:e.fontSizes.smallBody,color:e.palette.text.secondary,top:"-13px",position:"relative"})),_pe=C("div")({marginTop:"auto",display:"flex",justifyContent:"flex-end"}),Rpe=C("div")(({theme:e})=>({display:"flex",alignItems:"center",marginTop:e.spacing(1)})),Ppe=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),Ipe=e=>({margin:e.spacing(1,0)}),IO=({children:e,type:t,name:n,description:r,project:o,setType:a,setName:i,setDescription:l,setProject:c,validateToggleName:u,setImpressionData:d,impressionData:f,handleSubmit:h,handleCancel:m,errors:y,mode:g,clearErrors:v})=>{const{featureTypes:b}=nC(),w=lt(),{permissions:x}=bC(),E=g!=="Edit",A=()=>{var k;return(k=b.find(_=>_.id===t))==null?void 0:k.description};return T(Epe,{onSubmit:h,children:[T(Tpe,{children:[s(ah,{children:"What would you like to call your toggle?"}),s(l_,{autoFocus:!0,disabled:g==="Edit",label:"Name",id:"feature-toggle-name",error:Boolean(y.name),errorText:y.name,onFocus:()=>v(),value:n,onChange:k=>i(Cs(k.target.value)),"data-testid":cee,onBlur:u}),s(ah,{children:"What kind of feature toggle do you want?"}),s(wpe,{sx:c_,value:t,onChange:a,label:"Toggle type",id:"feature-type-select",editable:!0,"data-testid":uee,IconComponent:Nb}),s(Ape,{children:A()}),s(X,{condition:E,show:s(ah,{children:"In which project do you want to save the toggle?"})}),s(xpe,{value:o,onChange:k=>{c(k),w(`/projects/${k}/create-toggle`,{replace:!0})},enabled:E,filter:Spe(x,wp),IconComponent:Nb,sx:c_}),s(ah,{children:"How would you describe your feature toggle?"}),s(l_,{multiline:!0,rows:4,label:"Description",placeholder:"A short description of the feature toggle",value:r,"data-testid":dee,onChange:k=>l(k.target.value)}),T(kpe,{children:[s(ye,{variant:"subtitle1",sx:Ipe,"data-loading":!0,component:"h2",children:"Impression Data"}),T("p",{children:["When you enable impression data for a feature toggle, your client SDKs will emit events you can listen for every time this toggle gets triggered. Learn more in"," ",s("a",{target:"_blank",rel:"noopener noreferrer",href:"https://docs.getunleash.io/advanced/impression_data",children:"the impression data documentation"})]}),s(Rpe,{children:s(Tr,{labelPlacement:"start",style:{marginLeft:0},control:s(Ii,{name:"impressionData",onChange:()=>d(!f),checked:f}),label:"Enable impression data"})})]})]}),T(_pe,{children:[e,s(Ppe,{onClick:m,children:"Cancel"})]})]})},gu=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0}),o=async w=>{const E=t("api/admin/features/validate",{method:"POST",body:JSON.stringify({name:w})});try{return await e(E.caller,E.id)}catch(A){throw A}},a=async w=>{const E=t("api/admin/constraints/validate",{method:"POST",body:JSON.stringify(w)});await e(E.caller,E.id)},i=async(w,x)=>{const E=`/api/admin/projects/${w}/features`,A=t(E,{method:"POST",body:JSON.stringify(x)});await e(A.caller,A.id)},l=p.useCallback(async(w,x,E)=>{const A=`api/admin/projects/${w}/features/${x}/environments/${E}/on`,k=t(A,{method:"POST"},"toggleFeatureEnvironmentOn");try{return await e(k.caller,k.id)}catch(_){throw _}},[t,e]),c=p.useCallback(async(w,x,E)=>{const A=`api/admin/projects/${w}/features/${x}/environments/${E}/off`,k=t(A,{method:"POST"},"toggleFeatureEnvironmentOff");try{return await e(k.caller,k.id)}catch(_){throw _}},[t,e]);return{validateFeatureToggleName:o,validateConstraint:a,createFeatureToggle:i,changeFeatureProject:async(w,x,E)=>{const A=`api/admin/projects/${w}/features/${x}/changeProject`,k=t(A,{method:"POST",body:JSON.stringify({newProjectId:E})});try{return await e(k.caller,k.id)}catch(_){throw _}},errors:n,toggleFeatureEnvironmentOn:l,toggleFeatureEnvironmentOff:c,addTagToFeature:async(w,x)=>{const E=`api/admin/features/${w}/tags`,A=t(E,{method:"POST",body:JSON.stringify({...x})});try{return await e(A.caller,A.id)}catch(k){throw k}},deleteTagFromFeature:async(w,x,E)=>{const A=`api/admin/features/${w}/tags/${x}/${E}`,k=t(A,{method:"DELETE"});try{return await e(k.caller,k.id)}catch(_){throw _}},archiveFeatureToggle:async(w,x)=>{const E=`api/admin/projects/${w}/features/${x}`,A=t(E,{method:"DELETE"});try{return await e(A.caller,A.id)}catch(k){throw k}},patchFeatureToggle:async(w,x,E)=>{const A=`api/admin/projects/${w}/features/${x}`,k=t(A,{method:"PATCH",body:JSON.stringify(E)});try{return await e(k.caller,k.id)}catch(_){throw _}},patchFeatureVariants:async(w,x,E)=>{const A=`api/admin/projects/${w}/features/${x}/variants`,k=t(A,{method:"PATCH",body:JSON.stringify(E)});try{return await e(k.caller,k.id)}catch(_){throw _}},patchFeatureEnvironmentVariants:async(w,x,E,A)=>{const k=`api/admin/projects/${w}/features/${x}/environments/${E}/variants`,_=t(k,{method:"PATCH",body:JSON.stringify(A)});try{return await e(_.caller,_.id)}catch($){throw $}},overrideVariantsInEnvironments:async(w,x,E,A)=>{const k=`api/admin/projects/${w}/features/${x}/variants-batch`,_=t(k,{method:"PUT",body:JSON.stringify({variants:E,environments:A})});try{return await e(_.caller,_.id)}catch($){throw $}},cloneFeatureToggle:async(w,x,E)=>{const A=`api/admin/projects/${w}/features/${x}/clone`,k=t(A,{method:"POST",body:JSON.stringify(E)});try{return await e(k.caller,k.id)}catch(_){throw _}},loading:r}},$O=(e="",t="release",n="default",r="",o=!1)=>{const a=dr("projectId"),i=Rl(),{validateFeatureToggleName:l}=gu(),c=i.get("name"),[u,d]=p.useState(t),[f,h]=p.useState(c||e),[m,y]=p.useState(a||n),[g,v]=p.useState(r),[b,w]=p.useState(o),[x,E]=p.useState({});return p.useEffect(()=>{d(t)},[t]),p.useEffect(()=>{f||h(c||e)},[f,e,c]),p.useEffect(()=>{y(a||n)},[n,a]),p.useEffect(()=>{v(r)},[r]),p.useEffect(()=>{w(o)},[o]),{type:u,setType:d,name:f,setName:h,project:m,setProject:y,description:g,setDescription:v,impressionData:b,setImpressionData:w,getTogglePayload:()=>({type:u,name:f,description:g,impressionData:b}),validateToggleName:async()=>{if(f.length===0)return E($=>({...$,name:"Name can not be empty."})),!1;try{return await l(f),!0}catch($){return E(L=>({...L,name:ft($)})),!1}},clearErrors:()=>{E({})},errors:x}},$pe=()=>{const{setToastData:e,setToastApiError:t}=It(),{setShowFeedback:n}=p.useContext(Ps),{uiConfig:r}=Lt(),o=lt(),{type:a,setType:i,name:l,setName:c,project:u,setProject:d,description:f,setDescription:h,validateToggleName:m,impressionData:y,setImpressionData:g,getTogglePayload:v,clearErrors:b,errors:w}=$O(),{createFeatureToggle:x,loading:E}=gu();return s(Mr,{loading:E,title:"Create feature toggle",description:`Feature toggles support different use cases, each with their own specific needs such as simple static routing or more complex routing.
|
|
305
|
+
The feature toggle is disabled when created and you decide when to enable`,documentationLink:"https://docs.getunleash.io/reference/feature-toggle-types",documentationLinkLabel:"Feature toggle types documentation",formatApiCode:()=>`curl --location --request POST '${r.unleashUrl}/api/admin/projects/${u}/features' \\
|
|
306
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
307
|
+
--header 'Content-Type: application/json' \\
|
|
308
|
+
--data-raw '${JSON.stringify(v(),void 0,2)}'`,children:s(IO,{type:a,name:l,project:u,description:f,setType:i,setName:c,setProject:d,setDescription:h,validateToggleName:m,setImpressionData:g,impressionData:y,errors:w,handleSubmit:async $=>{if($.preventDefault(),b(),await m()){const O=v();try{await x(u,O),o(`/projects/${u}/features/${l}`),e({title:"Toggle created successfully",text:"Now you can start using your toggle.",confetti:!0,type:"success"}),n(!0)}catch(P){t(ft(P))}}},handleCancel:()=>{o(jo)},mode:"Create",clearErrors:b,children:s(mu,{name:"feature toggle",permission:wp,projectId:u,"data-testid":pee})})})};/*!
|
|
309
|
+
* https://github.com/Starcounter-Jack/JSON-Patch
|
|
310
|
+
* (c) 2017-2022 Joachim Wester
|
|
311
|
+
* MIT licensed
|
|
312
|
+
*/var Ope=globalThis&&globalThis.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,o){r.__proto__=o}||function(r,o){for(var a in o)o.hasOwnProperty(a)&&(r[a]=o[a])},e(t,n)};return function(t,n){e(t,n);function r(){this.constructor=t}t.prototype=n===null?Object.create(n):(r.prototype=n.prototype,new r)}}(),Lpe=Object.prototype.hasOwnProperty;function Kb(e,t){return Lpe.call(e,t)}function Yb(e){if(Array.isArray(e)){for(var t=new Array(e.length),n=0;n<t.length;n++)t[n]=""+n;return t}if(Object.keys)return Object.keys(e);var r=[];for(var o in e)Kb(e,o)&&r.push(o);return r}function ko(e){switch(typeof e){case"object":return JSON.parse(JSON.stringify(e));case"undefined":return null;default:return e}}function Xb(e){for(var t=0,n=e.length,r;t<n;){if(r=e.charCodeAt(t),r>=48&&r<=57){t++;continue}return!1}return!0}function Vs(e){return e.indexOf("/")===-1&&e.indexOf("~")===-1?e:e.replace(/~/g,"~0").replace(/\//g,"~1")}function OO(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function Jb(e){if(e===void 0)return!0;if(e){if(Array.isArray(e)){for(var t=0,n=e.length;t<n;t++)if(Jb(e[t]))return!0}else if(typeof e=="object"){for(var r=Yb(e),o=r.length,a=0;a<o;a++)if(Jb(e[r[a]]))return!0}}return!1}function u_(e,t){var n=[e];for(var r in t){var o=typeof t[r]=="object"?JSON.stringify(t[r],null,2):t[r];typeof o<"u"&&n.push(r+": "+o)}return n.join(`
|
|
313
|
+
`)}var LO=function(e){Ope(t,e);function t(n,r,o,a,i){var l=this.constructor,c=e.call(this,u_(n,{name:r,index:o,operation:a,tree:i}))||this;return c.name=r,c.index=o,c.operation=a,c.tree=i,Object.setPrototypeOf(c,l.prototype),c.message=u_(n,{name:r,index:o,operation:a,tree:i}),c}return t}(Error),Kn=LO,Npe=ko,sc={add:function(e,t,n){return e[t]=this.value,{newDocument:n}},remove:function(e,t,n){var r=e[t];return delete e[t],{newDocument:n,removed:r}},replace:function(e,t,n){var r=e[t];return e[t]=this.value,{newDocument:n,removed:r}},move:function(e,t,n){var r=jm(n,this.path);r&&(r=ko(r));var o=ll(n,{op:"remove",path:this.from}).removed;return ll(n,{op:"add",path:this.path,value:o}),{newDocument:n,removed:r}},copy:function(e,t,n){var r=jm(n,this.from);return ll(n,{op:"add",path:this.path,value:ko(r)}),{newDocument:n}},test:function(e,t,n){return{newDocument:n,test:Tp(e[t],this.value)}},_get:function(e,t,n){return this.value=e[t],{newDocument:n}}},Mpe={add:function(e,t,n){return Xb(t)?e.splice(t,0,this.value):e[t]=this.value,{newDocument:n,index:t}},remove:function(e,t,n){var r=e.splice(t,1);return{newDocument:n,removed:r[0]}},replace:function(e,t,n){var r=e[t];return e[t]=this.value,{newDocument:n,removed:r}},move:sc.move,copy:sc.copy,test:sc.test,_get:sc._get};function jm(e,t){if(t=="")return e;var n={op:"_get",path:t};return ll(e,n),n.value}function ll(e,t,n,r,o,a){if(n===void 0&&(n=!1),r===void 0&&(r=!0),o===void 0&&(o=!0),a===void 0&&(a=0),n&&(typeof n=="function"?n(t,0,e,t.path):Um(t,0)),t.path===""){var i={newDocument:e};if(t.op==="add")return i.newDocument=t.value,i;if(t.op==="replace")return i.newDocument=t.value,i.removed=e,i;if(t.op==="move"||t.op==="copy")return i.newDocument=jm(e,t.from),t.op==="move"&&(i.removed=e),i;if(t.op==="test"){if(i.test=Tp(e,t.value),i.test===!1)throw new Kn("Test operation failed","TEST_OPERATION_FAILED",a,t,e);return i.newDocument=e,i}else{if(t.op==="remove")return i.removed=e,i.newDocument=null,i;if(t.op==="_get")return t.value=e,i;if(n)throw new Kn("Operation `op` property is not one of operations defined in RFC-6902","OPERATION_OP_INVALID",a,t,e);return i}}else{r||(e=ko(e));var l=t.path||"",c=l.split("/"),u=e,d=1,f=c.length,h=void 0,m=void 0,y=void 0;for(typeof n=="function"?y=n:y=Um;;){if(m=c[d],m&&m.indexOf("~")!=-1&&(m=OO(m)),o&&(m=="__proto__"||m=="prototype"&&d>0&&c[d-1]=="constructor"))throw new TypeError("JSON-Patch: modifying `__proto__` or `constructor/prototype` prop is banned for security reasons, if this was on purpose, please set `banPrototypeModifications` flag false and pass it to this function. More info in fast-json-patch README");if(n&&h===void 0&&(u[m]===void 0?h=c.slice(0,d).join("/"):d==f-1&&(h=t.path),h!==void 0&&y(t,0,e,h)),d++,Array.isArray(u)){if(m==="-")m=u.length;else{if(n&&!Xb(m))throw new Kn("Expected an unsigned base-10 integer value, making the new referenced value the array element with the zero-based index","OPERATION_PATH_ILLEGAL_ARRAY_INDEX",a,t,e);Xb(m)&&(m=~~m)}if(d>=f){if(n&&t.op==="add"&&m>u.length)throw new Kn("The specified index MUST NOT be greater than the number of elements in the array","OPERATION_VALUE_OUT_OF_BOUNDS",a,t,e);var i=Mpe[t.op].call(t,u,m,e);if(i.test===!1)throw new Kn("Test operation failed","TEST_OPERATION_FAILED",a,t,e);return i}}else if(d>=f){var i=sc[t.op].call(t,u,m,e);if(i.test===!1)throw new Kn("Test operation failed","TEST_OPERATION_FAILED",a,t,e);return i}if(u=u[m],n&&d<f&&(!u||typeof u!="object"))throw new Kn("Cannot perform operation at the desired path","OPERATION_PATH_UNRESOLVABLE",a,t,e)}}}function wC(e,t,n,r,o){if(r===void 0&&(r=!0),o===void 0&&(o=!0),n&&!Array.isArray(t))throw new Kn("Patch sequence must be an array","SEQUENCE_NOT_AN_ARRAY");r||(e=ko(e));for(var a=new Array(t.length),i=0,l=t.length;i<l;i++)a[i]=ll(e,t[i],n,!0,o,i),e=a[i].newDocument;return a.newDocument=e,a}function Dpe(e,t,n){var r=ll(e,t);if(r.test===!1)throw new Kn("Test operation failed","TEST_OPERATION_FAILED",n,t,e);return r.newDocument}function Um(e,t,n,r){if(typeof e!="object"||e===null||Array.isArray(e))throw new Kn("Operation is not an object","OPERATION_NOT_AN_OBJECT",t,e,n);if(sc[e.op]){if(typeof e.path!="string")throw new Kn("Operation `path` property is not a string","OPERATION_PATH_INVALID",t,e,n);if(e.path.indexOf("/")!==0&&e.path.length>0)throw new Kn('Operation `path` property must start with "/"',"OPERATION_PATH_INVALID",t,e,n);if((e.op==="move"||e.op==="copy")&&typeof e.from!="string")throw new Kn("Operation `from` property is not present (applicable in `move` and `copy` operations)","OPERATION_FROM_REQUIRED",t,e,n);if((e.op==="add"||e.op==="replace"||e.op==="test")&&e.value===void 0)throw new Kn("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_REQUIRED",t,e,n);if((e.op==="add"||e.op==="replace"||e.op==="test")&&Jb(e.value))throw new Kn("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED",t,e,n);if(n){if(e.op=="add"){var o=e.path.split("/").length,a=r.split("/").length;if(o!==a+1&&o!==a)throw new Kn("Cannot perform an `add` operation at the desired path","OPERATION_PATH_CANNOT_ADD",t,e,n)}else if(e.op==="replace"||e.op==="remove"||e.op==="_get"){if(e.path!==r)throw new Kn("Cannot perform the operation at a path that does not exist","OPERATION_PATH_UNRESOLVABLE",t,e,n)}else if(e.op==="move"||e.op==="copy"){var i={op:"_get",path:e.from,value:void 0},l=NO([i],n);if(l&&l.name==="OPERATION_PATH_UNRESOLVABLE")throw new Kn("Cannot perform the operation from a path that does not exist","OPERATION_FROM_UNRESOLVABLE",t,e,n)}}}else throw new Kn("Operation `op` property is not one of operations defined in RFC-6902","OPERATION_OP_INVALID",t,e,n)}function NO(e,t,n){try{if(!Array.isArray(e))throw new Kn("Patch sequence must be an array","SEQUENCE_NOT_AN_ARRAY");if(t)wC(ko(t),ko(e),n||!0);else{n=n||Um;for(var r=0;r<e.length;r++)n(e[r],r,t,void 0)}}catch(o){if(o instanceof Kn)return o;throw o}}function Tp(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){var n=Array.isArray(e),r=Array.isArray(t),o,a,i;if(n&&r){if(a=e.length,a!=t.length)return!1;for(o=a;o--!==0;)if(!Tp(e[o],t[o]))return!1;return!0}if(n!=r)return!1;var l=Object.keys(e);if(a=l.length,a!==Object.keys(t).length)return!1;for(o=a;o--!==0;)if(!t.hasOwnProperty(l[o]))return!1;for(o=a;o--!==0;)if(i=l[o],!Tp(e[i],t[i]))return!1;return!0}return e!==e&&t!==t}const Bpe=Object.freeze(Object.defineProperty({__proto__:null,JsonPatchError:Kn,_areEquals:Tp,applyOperation:ll,applyPatch:wC,applyReducer:Dpe,deepClone:Npe,getValueByPointer:jm,validate:NO,validator:Um},Symbol.toStringTag,{value:"Module"}));/*!
|
|
314
|
+
* https://github.com/Starcounter-Jack/JSON-Patch
|
|
315
|
+
* (c) 2017-2021 Joachim Wester
|
|
316
|
+
* MIT license
|
|
317
|
+
*/var SC=new WeakMap,Fpe=function(){function e(t){this.observers=new Map,this.obj=t}return e}(),zpe=function(){function e(t,n){this.callback=t,this.observer=n}return e}();function jpe(e){return SC.get(e)}function Upe(e,t){return e.observers.get(t)}function Wpe(e,t){e.observers.delete(t.callback)}function Hpe(e,t){t.unobserve()}function Vpe(e,t){var n=[],r,o=jpe(e);if(!o)o=new Fpe(e),SC.set(e,o);else{var a=Upe(o,t);r=a&&a.observer}if(r)return r;if(r={},o.value=ko(e),t){r.callback=t,r.next=null;var i=function(){Qb(r)},l=function(){clearTimeout(r.next),r.next=setTimeout(i)};typeof window<"u"&&(window.addEventListener("mouseup",l),window.addEventListener("keyup",l),window.addEventListener("mousedown",l),window.addEventListener("keydown",l),window.addEventListener("change",l))}return r.patches=n,r.object=e,r.unobserve=function(){Qb(r),clearTimeout(r.next),Wpe(o,r),typeof window<"u"&&(window.removeEventListener("mouseup",l),window.removeEventListener("keyup",l),window.removeEventListener("mousedown",l),window.removeEventListener("keydown",l),window.removeEventListener("change",l))},o.observers.set(t,new zpe(t,r)),r}function Qb(e,t){t===void 0&&(t=!1);var n=SC.get(e.object);xC(n.value,e.object,e.patches,"",t),e.patches.length&&wC(n.value,e.patches);var r=e.patches;return r.length>0&&(e.patches=[],e.callback&&e.callback(r)),r}function xC(e,t,n,r,o){if(t!==e){typeof t.toJSON=="function"&&(t=t.toJSON());for(var a=Yb(t),i=Yb(e),l=!1,c=i.length-1;c>=0;c--){var u=i[c],d=e[u];if(Kb(t,u)&&!(t[u]===void 0&&d!==void 0&&Array.isArray(t)===!1)){var f=t[u];typeof d=="object"&&d!=null&&typeof f=="object"&&f!=null&&Array.isArray(d)===Array.isArray(f)?xC(d,f,n,r+"/"+Vs(u),o):d!==f&&(o&&n.push({op:"test",path:r+"/"+Vs(u),value:ko(d)}),n.push({op:"replace",path:r+"/"+Vs(u),value:ko(f)}))}else Array.isArray(e)===Array.isArray(t)?(o&&n.push({op:"test",path:r+"/"+Vs(u),value:ko(d)}),n.push({op:"remove",path:r+"/"+Vs(u)}),l=!0):(o&&n.push({op:"test",path:r,value:e}),n.push({op:"replace",path:r,value:t}))}if(!(!l&&a.length==i.length))for(var c=0;c<a.length;c++){var u=a[c];!Kb(e,u)&&t[u]!==void 0&&n.push({op:"add",path:r+"/"+Vs(u),value:ko(t[u])})}}}function MO(e,t,n){n===void 0&&(n=!1);var r=[];return xC(e,t,r,"",n),r}const Gpe=Object.freeze(Object.defineProperty({__proto__:null,compare:MO,generate:Qb,observe:Vpe,unobserve:Hpe},Symbol.toStringTag,{value:"Module"}));Object.assign({},Bpe,Gpe,{JsonPatchError:LO,deepClone:ko,escapePathComponent:Vs,unescapePathComponent:OO});const qpe={environments:[],name:"",type:"",stale:!1,archived:!1,createdAt:"",lastSeenAt:"",project:"",variants:[],description:"",favorite:!1,impressionData:!1},bl=(e,t,n)=>{const r=Ype(e,t),{data:o,error:a,mutate:i}=dn(["useFeature",r],()=>Kpe(r),n),l=p.useCallback(()=>{i().catch(console.warn)},[i]);return{feature:(o==null?void 0:o.body)||qpe,refetchFeature:l,loading:!a&&!o,status:o==null?void 0:o.status,error:a}},Kpe=async e=>{const t=await fetch(e);return t.status===404?{status:404}:(t.ok||await yn("Feature toggle data")(t),{status:t.status,body:await t.json()})},Ype=(e,t)=>Dt(`api/admin/projects/${e}/features/${t}?variantEnvironments=true`),Xpe=()=>{const e=dr("projectId"),t=dr("featureId"),{setToastData:n,setToastApiError:r}=It(),{uiConfig:o}=Lt(),a=lt(),{patchFeatureToggle:i,loading:l}=gu(),{feature:c}=bl(e,t),{type:u,setType:d,name:f,setName:h,project:m,setProject:y,description:g,setDescription:v,impressionData:b,setImpressionData:w,clearErrors:x,errors:E}=$O(c==null?void 0:c.name,c==null?void 0:c.type,c==null?void 0:c.project,c==null?void 0:c.description,c==null?void 0:c.impressionData),A=()=>{const L={...c,type:u,description:g,impressionData:b};return MO(c,L)};return s(Mr,{loading:l,title:"Edit Feature toggle",description:`Feature toggles support different use cases, each with their own specific needs such as simple static routing or more complex routing.
|
|
318
|
+
The feature toggle is disabled when created and you decide when to enable`,documentationLink:"https://docs.getunleash.io/reference/feature-toggle-types",documentationLinkLabel:"Feature toggle types documentation",formatApiCode:()=>`curl --location --request PATCH '${o.unleashUrl}/api/admin/projects/${e}/features/${t}' \\
|
|
319
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
320
|
+
--header 'Content-Type: application/json' \\
|
|
321
|
+
--data-raw '${JSON.stringify(A(),void 0,2)}'`,children:s(IO,{type:u,name:f,project:m,description:g,setType:d,setName:h,setProject:y,setDescription:v,errors:E,handleSubmit:async L=>{L.preventDefault(),x();const O=A();try{await i(m,t,O),a(`/projects/${m}/features/${f}`),n({title:"Toggle updated successfully",type:"success"})}catch(P){r(ft(P))}},handleCancel:()=>{a(jo)},impressionData:b,setImpressionData:w,mode:"Edit",clearErrors:x,children:s(Pl,{permission:f3,projectId:m})})})},CC=(e,t={})=>{const n=Dt(`api/admin/metrics/applications/${e}`),r=async()=>fetch(n,{method:"GET"}).then(yn("Application")).then(d=>d.json()),o=`api/admin/metrics/applications/${e}`,{data:a,error:i}=dn(o,r,{...t}),[l,c]=p.useState(!i&&!a),u=()=>{Vr(o)};return p.useEffect(()=>{c(!i&&!a)},[a,i]),{application:a||{appName:e,color:"",createdAt:"2022-02-02T21:04:00.268Z",descriotion:"",instances:[],strategies:[],seenToggles:[],url:""},error:i,loading:l,refetchApplication:u,APPLICATION_CACHE_KEY:o}},Jpe=()=>{const{hasAccess:e}=p.useContext(Gr),t=dr("name"),{application:n}=CC(t),{locationSettings:r}=ii(),{instances:o,strategies:a,seenToggles:i}=n,l=({createUrl:u,name:d,permission:f})=>s(X,{condition:e(f),show:T(ba,{children:[s(Xi,{children:s(aA,{style:{color:"red"}})}),s(fn,{primary:s(ln,{to:`${u}`,children:d}),secondary:"Missing, want to create?"})]},`not_found_${d}`),elseShow:T(ba,{children:[s(Xi,{children:s(aA,{})}),s(fn,{primary:d,secondary:`Could not find feature toggle with name ${d}`})]},`not_found_${d}`)},`not_found_conditional_${d}`),c=({viewUrl:u,name:d,description:f,Icon:h,i:m})=>T(ba,{children:[s(Xi,{children:s(h,{})}),s(fn,{primary:s(ln,{to:`${u}/${d}`,style:{wordBreak:"break-all"},children:d}),secondary:f})]},`found_${d}-${m}`);return T(In,{container:!0,style:{margin:0},children:[T(In,{item:!0,xl:6,md:6,xs:12,children:[s(ye,{variant:"subtitle1",style:{padding:"1rem 0"},children:"Toggles"}),s(mo,{}),s(xa,{children:i.map(({name:u,description:d,notFound:f,project:h},m)=>s(X,{condition:f,show:l({createUrl:`/projects/default/create-toggle?name=${u}`,name:u,permission:wp}),elseShow:c({viewUrl:Nm(h,u),name:u,description:d,Icon:NZ,i:m})},`toggle_conditional_${u}`))})]}),T(In,{item:!0,xl:6,md:6,xs:12,children:[s(ye,{variant:"subtitle1",style:{padding:"1rem 0"},children:"Implemented strategies"}),s(mo,{}),s(xa,{children:a.map(({name:u,description:d,notFound:f},h)=>s(X,{condition:f,show:l({createUrl:"/strategies/create",name:u,permission:Rm}),elseShow:c({viewUrl:"/strategies",name:u,Icon:O4,description:d,i:h})},`strategies_conditional_${u}`))})]}),T(In,{item:!0,xl:12,md:12,children:[T(ye,{variant:"subtitle1",style:{padding:"1rem 0"},children:[o.length," Instances registered"]}),s(mo,{}),s(xa,{children:o.map(({instanceId:u,clientIp:d,lastSeen:f,sdkVersion:h})=>T(ba,{children:[s(Xi,{children:s(VZ,{})}),s(fn,{primary:s(X,{condition:Boolean(h),show:T("span",{children:[u," ",h]}),elseShow:s("span",{children:u})},`${u}_conditional`),secondary:T("span",{children:[d," last seen at"," ",s("small",{children:bv(f,r.locale)})]})})]},`${u}`))})]})]})},Qpe=["3d_rotation","ac_unit","access_alarm","access_alarms","access_time","accessibility","accessible","account_balance","account_balance_wallet","account_box","account_circle","adb","add","add_a_photo","add_alarm","add_alert","add_box","add_circle","add_circle_outline","add_location","add_shopping_cart","add_to_photos","add_to_queue","adjust","airline_seat_flat","airline_seat_flat_angled","airline_seat_individual_suite","airline_seat_legroom_extra","airline_seat_legroom_normal","airline_seat_legroom_reduced","airline_seat_recline_extra","airline_seat_recline_normal","airplanemode_active","airplanemode_inactive","airplay","airport_shuttle","alarm","alarm_add","alarm_off","alarm_on","album","all_inclusive","all_out","android","announcement","apps","archive","arrow_back","arrow_downward","arrow_drop_down","arrow_drop_down_circle","arrow_drop_up","arrow_forward","arrow_upward","art_track","aspect_ratio","assessment","assignment","assignment_ind","assignment_late","assignment_return","assignment_returned","assignment_turned_in","assistant","assistant_photo","attach_file","attach_money","attachment","audiotrack","autorenew","av_timer","backspace","backup","battery_alert","battery_charging_full","battery_full","battery_std","battery_unknown","beach_access","beenhere","block","bluetooth","bluetooth_audio","bluetooth_connected","bluetooth_disabled","bluetooth_searching","blur_circular","blur_linear","blur_off","blur_on","book","bookmark","bookmark_border","border_all","border_bottom","border_clear","border_color","border_horizontal","border_inner","border_left","border_outer","border_right","border_style","border_top","border_vertical","branding_watermark","brightness_1","brightness_2","brightness_3","brightness_4","brightness_5","brightness_6","brightness_7","brightness_auto","brightness_high","brightness_low","brightness_medium","broken_image","brush","bubble_chart","bug_report","build","burst_mode","business","business_center","cached","cake","call","call_end","call_made","call_merge","call_missed","call_missed_outgoing","call_received","call_split","call_to_action","camera","camera_alt","camera_enhance","camera_front","camera_rear","camera_roll","cancel","card_giftcard","card_membership","card_travel","casino","cast","cast_connected","center_focus_strong","center_focus_weak","change_history","chat","chat_bubble","chat_bubble_outline","check","check_box","check_box_outline_blank","check_circle","chevron_left","chevron_right","child_care","child_friendly","chrome_reader_mode","class","clear","clear_all","close","closed_caption","cloud","cloud_circle","cloud_done","cloud_download","cloud_off","cloud_queue","cloud_upload","code","collections","collections_bookmark","color_lens","colorize","comment","compare","compare_arrows","computer","confirmation_number","contact_mail","contact_phone","contacts","content_copy","content_cut","content_paste","control_point","control_point_duplicate","copyright","create","create_new_folder","credit_card","crop","crop_16_9","crop_3_2","crop_5_4","crop_7_5","crop_din","crop_free","crop_landscape","crop_original","crop_portrait","crop_rotate","crop_square","dashboard","data_usage","date_range","dehaze","delete","delete_forever","delete_sweep","description","desktop_mac","desktop_windows","details","developer_board","developer_mode","device_hub","devices","devices_other","dialer_sip","dialpad","directions","directions_bike","directions_boat","directions_bus","directions_car","directions_railway","directions_run","directions_subway","directions_transit","directions_walk","disc_full","dns","do_not_disturb","do_not_disturb_alt","do_not_disturb_off","do_not_disturb_on","dock","domain","done","done_all","donut_large","donut_small","drafts","drag_handle","drive_eta","dvr","edit","edit_location","eject","email","enhanced_encryption","equalizer","error","error_outline","euro_symbol","ev_station","event","event_available","event_busy","event_note","event_seat","exit_to_app","expand_less","expand_more","explicit","explore","exposure","exposure_neg_1","exposure_neg_2","exposure_plus_1","exposure_plus_2","exposure_zero","extension","face","fast_forward","fast_rewind","favorite","favorite_border","featured_play_list","featured_video","feedback","fiber_dvr","fiber_manual_record","fiber_new","fiber_pin","fiber_smart_record","file_download","file_upload","filter","filter_1","filter_2","filter_3","filter_4","filter_5","filter_6","filter_7","filter_8","filter_9","filter_9_plus","filter_b_and_w","filter_center_focus","filter_drama","filter_frames","filter_hdr","filter_list","filter_none","filter_tilt_shift","filter_vintage","find_in_page","find_replace","fingerprint","first_page","fitness_center","flag","flare","flash_auto","flash_off","flash_on","flight","flight_land","flight_takeoff","flip","flip_to_back","flip_to_front","folder","folder_open","folder_shared","folder_special","font_download","format_align_center","format_align_justify","format_align_left","format_align_right","format_bold","format_clear","format_color_fill","format_color_reset","format_color_text","format_indent_decrease","format_indent_increase","format_italic","format_line_spacing","format_list_bulleted","format_list_numbered","format_paint","format_quote","format_shapes","format_size","format_strikethrough","format_textdirection_l_to_r","format_textdirection_r_to_l","format_underlined","forum","forward","forward_10","forward_30","forward_5","free_breakfast","fullscreen","fullscreen_exit","functions","g_translate","gamepad","games","gavel","gesture","get_app","gif","golf_course","gps_fixed","gps_not_fixed","gps_off","grade","gradient","grain","graphic_eq","grid_off","grid_on","group","group_add","group_work","hd","hdr_off","hdr_on","hdr_strong","hdr_weak","headset","headset_mic","healing","hearing","help","help_outline","high_quality","highlight","highlight_off","history","home","hot_tub","hotel","hourglass_empty","hourglass_full","http","https","image","image_aspect_ratio","import_contacts","import_export","important_devices","inbox","indeterminate_check_box","info","info_outline","input","insert_chart","insert_comment","insert_drive_file","insert_emoticon","insert_invitation","insert_link","insert_photo","invert_colors","invert_colors_off","iso","keyboard","keyboard_arrow_down","keyboard_arrow_left","keyboard_arrow_right","keyboard_arrow_up","keyboard_backspace","keyboard_capslock","keyboard_hide","keyboard_return","keyboard_tab","keyboard_voice","kitchen","label","label_outline","landscape","language","laptop","laptop_chromebook","laptop_mac","laptop_windows","last_page","launch","layers","layers_clear","leak_add","leak_remove","lens","library_add","library_books","library_music","lightbulb_outline","line_style","line_weight","linear_scale","link","linked_camera","list","live_help","live_tv","local_activity","local_airport","local_atm","local_bar","local_cafe","local_car_wash","local_convenience_store","local_dining","local_drink","local_florist","local_gas_station","local_grocery_store","local_hospital","local_hotel","local_laundry_service","local_library","local_mall","local_movies","local_offer","local_parking","local_pharmacy","local_phone","local_pizza","local_play","local_post_office","local_printshop","local_see","local_shipping","local_taxi","location_city","location_disabled","location_off","location_on","location_searching","lock","lock_open","lock_outline","looks","looks_3","looks_4","looks_5","looks_6","looks_one","looks_two","loop","loupe","low_priority","loyalty","mail","mail_outline","map","markunread","markunread_mailbox","memory","menu","merge_type","message","mic","mic_none","mic_off","mms","mode_comment","mode_edit","monetization_on","money_off","monochrome_photos","mood","mood_bad","more","more_horiz","more_vert","motorcycle","mouse","move_to_inbox","movie","movie_creation","movie_filter","multiline_chart","music_note","music_video","my_location","nature","nature_people","navigate_before","navigate_next","navigation","near_me","network_cell","network_check","network_locked","network_wifi","new_releases","next_week","nfc","no_encryption","no_sim","not_interested","note","note_add","notifications","notifications_active","notifications_none","notifications_off","notifications_paused","offline_pin","ondemand_video","opacity","open_in_browser","open_in_new","open_with","pages","pageview","palette","pan_tool","panorama","panorama_fish_eye","panorama_horizontal","panorama_vertical","panorama_wide_angle","party_mode","pause","pause_circle_filled","pause_circle_outline","payment","people","people_outline","perm_camera_mic","perm_contact_calendar","perm_data_setting","perm_device_information","perm_identity","perm_media","perm_phone_msg","perm_scan_wifi","person","person_add","person_outline","person_pin","person_pin_circle","personal_video","pets","phone","phone_android","phone_bluetooth_speaker","phone_forwarded","phone_in_talk","phone_iphone","phone_locked","phone_missed","phone_paused","phonelink","phonelink_erase","phonelink_lock","phonelink_off","phonelink_ring","phonelink_setup","photo","photo_album","photo_camera","photo_filter","photo_library","photo_size_select_actual","photo_size_select_large","photo_size_select_small","picture_as_pdf","picture_in_picture","picture_in_picture_alt","pie_chart","pie_chart_outlined","pin_drop","place","play_arrow","play_circle_filled","play_circle_outline","play_for_work","playlist_add","playlist_add_check","playlist_play","plus_one","poll","polymer","pool","portable_wifi_off","portrait","power","power_input","power_settings_new","pregnant_woman","present_to_all","print","priority_high","public","publish","query_builder","question_answer","queue","queue_music","queue_play_next","radio","radio_button_checked","radio_button_unchecked","rate_review","receipt","recent_actors","record_voice_over","redeem","redo","refresh","remove","remove_circle","remove_circle_outline","remove_from_queue","remove_red_eye","remove_shopping_cart","reorder","repeat","repeat_one","replay","replay_10","replay_30","replay_5","reply","reply_all","report","report_problem","restaurant","restaurant_menu","restore","restore_page","ring_volume","room","room_service","rotate_90_degrees_ccw","rotate_left","rotate_right","rounded_corner","router","rowing","rss_feed","rv_hookup","satellite","save","scanner","schedule","school","screen_lock_landscape","screen_lock_portrait","screen_lock_rotation","screen_rotation","screen_share","sd_card","sd_storage","search","security","select_all","send","sentiment_dissatisfied","sentiment_neutral","sentiment_satisfied","sentiment_very_dissatisfied","sentiment_very_satisfied","settings","settings_applications","settings_backup_restore","settings_bluetooth","settings_brightness","settings_cell","settings_ethernet","settings_input_antenna","settings_input_component","settings_input_composite","settings_input_hdmi","settings_input_svideo","settings_overscan","settings_phone","settings_power","settings_remote","settings_system_daydream","settings_voice","share","shop","shop_two","shopping_basket","shopping_cart","short_text","show_chart","shuffle","signal_cellular_4_bar","signal_cellular_connected_no_internet_4_bar","signal_cellular_no_sim","signal_cellular_null","signal_cellular_off","signal_wifi_4_bar","signal_wifi_4_bar_lock","signal_wifi_off","sim_card","sim_card_alert","skip_next","skip_previous","slideshow","slow_motion_video","smartphone","smoke_free","smoking_rooms","sms","sms_failed","snooze","sort","sort_by_alpha","spa","space_bar","speaker","speaker_group","speaker_notes","speaker_notes_off","speaker_phone","spellcheck","star","star_border","star_half","stars","stay_current_landscape","stay_current_portrait","stay_primary_landscape","stay_primary_portrait","stop","stop_screen_share","storage","store","store_mall_directory","straighten","streetview","strikethrough_s","style","subdirectory_arrow_left","subdirectory_arrow_right","subject","subscriptions","subtitles","subway","supervisor_account","surround_sound","swap_calls","swap_horiz","swap_vert","swap_vertical_circle","switch_camera","switch_video","sync","sync_disabled","sync_problem","system_update","system_update_alt","tab","tab_unselected","tablet","tablet_android","tablet_mac","tag_faces","tap_and_play","terrain","text_fields","text_format","textsms","texture","theaters","thumb_down","thumb_up","thumbs_up_down","time_to_leave","timelapse","timeline","timer","timer_10","timer_3","timer_off","title","toc","today","toll","tonality","touch_app","toys","track_changes","traffic","train","tram","transfer_within_a_station","transform","translate","trending_down","trending_flat","trending_up","tune","turned_in","turned_in_not","tv","unarchive","undo","unfold_less","unfold_more","update","usb","verified_user","vertical_align_bottom","vertical_align_center","vertical_align_top","vibration","video_call","video_label","video_library","videocam","videocam_off","videogame_asset","view_agenda","view_array","view_carousel","view_column","view_comfy","view_compact","view_day","view_headline","view_list","view_module","view_quilt","view_stream","view_week","vignette","visibility","visibility_off","voice_chat","voicemail","volume_down","volume_mute","volume_off","volume_up","vpn_key","vpn_lock","wallpaper","warning","watch","watch_later","wb_auto","wb_cloudy","wb_incandescent","wb_iridescent","wb_sunny","wc","web","web_asset","weekend","whatshot","widgets","wifi","wifi_lock","wifi_tethering","work","wrap_text","youtube_searched_for","zoom_in","zoom_out","zoom_out_map"],DO=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0}),o="api/admin/metrics/applications";return{storeApplicationMetaData:async(l,c,u)=>{const d={};d[c]=u;const f=`${o}/${l}`,h=t(f,{method:"POST",body:JSON.stringify(d)});try{return await e(h.caller,h.id)}catch(m){throw m}},deleteApplication:async l=>{const c=`${o}/${encodeURIComponent(l)}`,u=t(c,{method:"DELETE"});try{return await e(u.caller,u.id)}catch(d){throw d}},errors:n,loading:r}},Zpe=({application:e})=>{const{storeApplicationMetaData:t}=DO(),{appName:n,icon:r,url:o,description:a}=e,{refetchApplication:i}=CC(n),[l,c]=p.useState(o||""),[u,d]=p.useState(a||""),{setToastData:f,setToastApiError:h}=It(),{classes:m}=ef(),y=async(g,v,b)=>{b==null||b.preventDefault();try{await t(n,g,v),i(),f({type:"success",title:"Updated Successfully",text:`${g} successfully updated`})}catch(w){h(ft(w))}};return s(In,{container:!0,style:{marginTop:"1rem"},children:T(In,{item:!0,sm:12,xs:12,className:m.contentSpacingY,children:[s(In,{item:!0,children:s(du,{name:"iconSelect",id:"selectIcon",label:"Icon",options:Qpe.map(g=>({key:g,label:g})),value:r||"apps",onChange:g=>y("icon",g)})}),s(In,{item:!0,children:s(mn,{value:l,onChange:g=>c(g.target.value),label:"Application URL",placeholder:"https://example.com",type:"url",variant:"outlined",size:"small",onBlur:g=>y("url",l,g)})}),s(In,{item:!0,children:s(mn,{value:u,label:"Description",variant:"outlined",size:"small",rows:2,onChange:g=>d(g.target.value),onBlur:g=>y("description",u,g)})})]})})},efe=({children:e,value:t,index:n})=>s("div",{role:"tabpanel",hidden:t!==n,id:`tabpanel-${n}`,"aria-labelledby":`tab-${n}`,children:t===n&&e}),tfe=({tabData:e,className:t="",navClass:n="",startingTab:r=0})=>{const[o,a]=p.useState(r),i=()=>e.map((c,u)=>s(EJ,{label:c.label,id:`tab-${u}`,"aria-controls":`tabpanel-${u}`,sx:{minWidth:{lg:160}}},`${c.label}_${u}`)),l=()=>e.map((c,u)=>s(efe,{value:o,index:u,children:c.component},u));return T(ke,{children:[s(pr,{className:n,elevation:0,sx:{backgroundColor:c=>c.palette.background.paper,borderBottom:"1px solid",borderBottomColor:c=>c.palette.grey[300],borderRadius:0},children:s(PQ,{value:o,onChange:(c,u)=>{a(u)},indicatorColor:"primary",textColor:"primary",centered:!0,children:i()})}),s("div",{className:t,children:l()})]})},nfe=()=>{const e=lt(),t=dr("name"),{application:n,loading:r}=CC(t),{appName:o,url:a,description:i,icon:l="apps",createdAt:c}=n,{hasAccess:u}=p.useContext(Gr),{deleteApplication:d}=DO(),{locationSettings:f}=ii(),{setToastData:h,setToastApiError:m}=It(),[y,g]=p.useState(!1),v=()=>{g(!y)},b=A=>Uc(A,f.locale),w=async A=>{A.preventDefault();try{await d(o),h({title:"Deleted Successfully",text:"Application deleted successfully",type:"success"}),e("/applications")}catch(k){m(ft(k))}},x=()=>s(Zn,{open:y,onClose:v,onClick:w,title:"Are you sure you want to delete this application?"}),E=[{label:"Application overview",component:s(Jpe,{})},{label:"Edit application",component:s(Zpe,{application:n})}];return r?T("div",{children:[s("p",{children:"Loading..."}),s(wK,{})]}):n?T(fr,{header:s(xn,{titleElement:T("span",{style:{display:"flex",alignItems:"center"},children:[s(iv,{style:{marginRight:"8px"},children:s(cx,{children:l||"apps"})}),o]}),title:o,actions:T(ke,{children:[s(X,{condition:Boolean(a),show:s(Yt,{component:go,href:a,size:"large",children:s(zZ,{titleAccess:a})})}),s(zo,{tooltipProps:{title:"Delete application"},onClick:v,permission:xA,children:"Delete"})]})}),children:[T("div",{children:[s(ye,{variant:"body1",children:i||""}),T(ye,{variant:"body2",children:["Created: ",s("strong",{children:b(c)})]})]}),s(X,{condition:u(xA),show:T("div",{children:[x(),s(tfe,{tabData:E})]})})]}):T("p",{children:["Application (",o,") not found"]})},rfe=()=>{const{applications:e,loading:t}=V3(),[n,r]=tu(),[o,a]=p.useState(n.get("search")||"");p.useEffect(()=>{const u={};o&&(u.search=o),r(u,{replace:!0})},[o,r]);const i=p.useMemo(()=>{const u=Yx(o,"i");return o?e==null?void 0:e.filter(d=>u.test(d.appName)):e},[e,o]),l=()=>s(ke,{children:T("section",{style:{textAlign:"center"},children:[s(QZ,{titleAccess:"Warning"})," ",s("br",{}),s("br",{}),"Oh snap, it does not seem like you have connected any applications. To connect your application to Unleash you will require a Client SDK.",s("br",{}),s("br",{}),"You can read more about how to use Unleash in your application in the"," ",s("a",{href:"https://docs.getunleash.io/docs/sdks/",children:"documentation."})]})});if(!i)return s(IV,{variant:"indeterminate"});let c=i.length<e.length?`${i.length} of ${e.length}`:e.length;return s(ke,{children:s(fr,{header:s(xn,{title:`Applications (${c})`,actions:s(Hr,{initialValue:o,onChange:a})}),children:s("div",{className:Ec.fullwidth,children:s(X,{condition:i.length>0,show:s(iC,{apps:i}),elseShow:s(X,{condition:t,show:s("div",{children:"...loading"}),elseShow:l()})})})})})},Il=(e={revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0})=>{const t=()=>{const l=Dt("api/admin/context");return fetch(l,{method:"GET"}).then(yn("Context variables")).then(c=>c.json())},n="api/admin/context",{data:r,mutate:o,error:a,isValidating:i}=dn(n,t,e);return{context:r||[],error:a,loading:i&&!a&&!r,refetchUnleashContext:o}},ofe=()=>{const e=cr("(max-width:700px)"),t=lt();return s(X,{condition:e,show:s(ur,{permission:Pm,onClick:()=>t("/context/create"),size:"large",tooltipProps:{title:"Add context type"},children:s(Ta,{})}),elseShow:s(zo,{onClick:()=>t("/context/create"),permission:Pm,color:"primary",variant:"contained",children:"New context field"})})},afe=({name:e,onDelete:t})=>{const n=lt();return T(ti,{children:[s(ur,{permission:h3,onClick:()=>n(`/context/edit/${e}`),"data-loading":!0,"aria-label":"edit",tooltipProps:{title:"Edit context field"},children:s(Za,{})}),s(ur,{permission:Ine,onClick:t,"data-loading":!0,"aria-label":"delete",tooltipProps:{title:"Delete context field"},children:s(Oo,{})})]})},ife=()=>{const[e,t]=p.useState(!1),[n,r]=p.useState(),{context:o,refetchUnleashContext:a,loading:i}=Il(),{removeContext:l}=$v(),{setToastData:c,setToastApiError:u}=It(),d=p.useMemo(()=>i?Array(5).fill({name:"Context name",description:"Context description when loading"}):o.map(({name:A,description:k,sortOrder:_})=>({name:A,description:k,sortOrder:_})).sort((A,k)=>A.sortOrder-k.sortOrder),[o,i]),f=p.useMemo(()=>[{id:"Icon",Cell:()=>s(_v,{icon:s(CZ,{color:"disabled"})}),disableGlobalFilter:!0},{Header:"Name",accessor:"name",width:"90%",Cell:({row:{original:{name:A,description:k}}})=>s(Is,{title:A,to:`/context/edit/${A}`,subtitle:k}),sortType:"alphanumeric"},{Header:"Actions",id:"Actions",align:"center",Cell:({row:{original:{name:A}}})=>s(afe,{name:A,onDelete:()=>{r(A),t(!0)}}),width:150,disableGlobalFilter:!0,disableSortBy:!0},{accessor:"description",disableSortBy:!0},{accessor:"sortOrder",disableGlobalFilter:!0,sortType:"number"}],[]),h=p.useMemo(()=>({sortBy:[{id:"name",desc:!1}],hiddenColumns:["description","sortOrder"]}),[]),m=async()=>{try{if(n===void 0)throw new Error;await l(n),a(),c({type:"success",title:"Successfully deleted context",text:"Your context is now deleted"})}catch(A){u(ft(A))}r(void 0),t(!1)},{getTableProps:y,getTableBodyProps:g,headerGroups:v,rows:b,prepareRow:w,state:{globalFilter:x},setGlobalFilter:E}=Kt.useTable({columns:f,data:d,initialState:h,sortTypes:Aa,autoResetGlobalFilter:!1,autoResetSortBy:!1,disableSortRemove:!0},Kt.useGlobalFilter,Kt.useSortBy);return T(fr,{isLoading:i,header:s(xn,{title:`Context fields (${b.length})`,actions:T(ke,{children:[s(Hr,{initialValue:x,onChange:E}),s(xn.Divider,{}),s(ofe,{})]})}),children:[s(Di,{value:x,children:T(Mi,{...y(),children:[s(Ni,{headerGroups:v}),s($i,{...g(),children:b.map(A=>(w(A),s(ai,{hover:!0,...A.getRowProps(),children:A.cells.map(k=>s(ei,{...k.getCellProps(),children:k.render("Cell")}))})))})]})}),s(X,{condition:b.length===0,show:s(X,{condition:(x==null?void 0:x.length)>0,show:T(Un,{children:["No contexts found matching “",x,"”"]}),elseShow:s(Un,{children:"No contexts available. Get started by adding one."})})}),s(Zn,{open:e,onClick:m,onClose:()=>{r(void 0),t(!1)},title:"Really delete context field"})]})},d_=()=>{const e=dr("featureId"),{features:t=[]}=Gx(),[n,r]=p.useState();return p.useEffect(()=>{const o=t.find(a=>a.name===e);r(o)},[t,e]),n!=null&&n.project?s(_l,{to:Nm(n.project,n.name),replace:!0}):null};function va(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];throw Error("[Immer] minified error nr: "+e+(n.length?" "+n.map(function(o){return"'"+o+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Vc(e){return!!e&&!!e[Lo]}function wl(e){var t;return!!e&&(function(n){if(!n||typeof n!="object")return!1;var r=Object.getPrototypeOf(n);if(r===null)return!0;var o=Object.hasOwnProperty.call(r,"constructor")&&r.constructor;return o===Object||typeof o=="function"&&Function.toString.call(o)===hfe}(e)||Array.isArray(e)||!!e[b_]||!!(!((t=e.constructor)===null||t===void 0)&&t[b_])||EC(e)||TC(e))}function kp(e,t,n){n===void 0&&(n=!1),vu(e)===0?(n?Object.keys:PC)(e).forEach(function(r){n&&typeof r=="symbol"||t(r,e[r],e)}):e.forEach(function(r,o){return t(o,r,e)})}function vu(e){var t=e[Lo];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:EC(e)?2:TC(e)?3:0}function Zb(e,t){return vu(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function sfe(e,t){return vu(e)===2?e.get(t):e[t]}function BO(e,t,n){var r=vu(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function lfe(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function EC(e){return pfe&&e instanceof Map}function TC(e){return ffe&&e instanceof Set}function Gs(e){return e.o||e.t}function kC(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=mfe(e);delete t[Lo];for(var n=PC(t),r=0;r<n.length;r++){var o=n[r],a=t[o];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(t[o]={configurable:!0,writable:!0,enumerable:a.enumerable,value:e[o]})}return Object.create(Object.getPrototypeOf(e),t)}function AC(e,t){return t===void 0&&(t=!1),_C(e)||Vc(e)||!wl(e)||(vu(e)>1&&(e.set=e.add=e.clear=e.delete=cfe),Object.freeze(e),t&&kp(e,function(n,r){return AC(r,!0)},!0)),e}function cfe(){va(2)}function _C(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Xa(e){var t=gfe[e];return t||va(18,e),t}function p_(){return Ap}function L1(e,t){t&&(Xa("Patches"),e.u=[],e.s=[],e.v=t)}function Wm(e){ew(e),e.p.forEach(ufe),e.p=null}function ew(e){e===Ap&&(Ap=e.l)}function f_(e){return Ap={p:[],l:Ap,h:e,m:!0,_:0}}function ufe(e){var t=e[Lo];t.i===0||t.i===1?t.j():t.O=!0}function N1(e,t){t._=t.p.length;var n=t.p[0],r=e!==void 0&&e!==n;return t.h.g||Xa("ES5").S(t,e,r),r?(n[Lo].P&&(Wm(t),va(4)),wl(e)&&(e=Hm(t,e),t.l||Vm(t,e)),t.u&&Xa("Patches").M(n[Lo].t,e,t.u,t.s)):e=Hm(t,n,[]),Wm(t),t.u&&t.v(t.u,t.s),e!==FO?e:void 0}function Hm(e,t,n){if(_C(t))return t;var r=t[Lo];if(!r)return kp(t,function(l,c){return h_(e,r,t,l,c,n)},!0),t;if(r.A!==e)return t;if(!r.P)return Vm(e,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var o=r.i===4||r.i===5?r.o=kC(r.k):r.o,a=o,i=!1;r.i===3&&(a=new Set(o),o.clear(),i=!0),kp(a,function(l,c){return h_(e,r,o,l,c,n,i)}),Vm(e,o,!1),n&&e.u&&Xa("Patches").N(r,n,e.u,e.s)}return r.o}function h_(e,t,n,r,o,a,i){if(Vc(o)){var l=Hm(e,o,a&&t&&t.i!==3&&!Zb(t.R,r)?a.concat(r):void 0);if(BO(n,r,l),!Vc(l))return;e.m=!1}else i&&n.add(o);if(wl(o)&&!_C(o)){if(!e.h.D&&e._<1)return;Hm(e,o),t&&t.A.l||Vm(e,o)}}function Vm(e,t,n){n===void 0&&(n=!1),!e.l&&e.h.D&&e.m&&AC(t,n)}function M1(e,t){var n=e[Lo];return(n?Gs(n):e)[t]}function m_(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function tw(e){e.P||(e.P=!0,e.l&&tw(e.l))}function D1(e){e.o||(e.o=kC(e.t))}function nw(e,t,n){var r=EC(t)?Xa("MapSet").F(t,n):TC(t)?Xa("MapSet").T(t,n):e.g?function(o,a){var i=Array.isArray(o),l={i:i?1:0,A:a?a.A:p_(),P:!1,I:!1,R:{},l:a,t:o,k:null,o:null,j:null,C:!1},c=l,u=rw;i&&(c=[l],u=yd);var d=Proxy.revocable(c,u),f=d.revoke,h=d.proxy;return l.k=h,l.j=f,h}(t,n):Xa("ES5").J(t,n);return(n?n.A:p_()).p.push(r),r}function dfe(e){return Vc(e)||va(22,e),function t(n){if(!wl(n))return n;var r,o=n[Lo],a=vu(n);if(o){if(!o.P&&(o.i<4||!Xa("ES5").K(o)))return o.t;o.I=!0,r=g_(n,a),o.I=!1}else r=g_(n,a);return kp(r,function(i,l){o&&sfe(o.t,i)===l||BO(r,i,t(l))}),a===3?new Set(r):r}(e)}function g_(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return kC(e)}var v_,Ap,RC=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",pfe=typeof Map<"u",ffe=typeof Set<"u",y_=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",FO=RC?Symbol.for("immer-nothing"):((v_={})["immer-nothing"]=!0,v_),b_=RC?Symbol.for("immer-draftable"):"__$immer_draftable",Lo=RC?Symbol.for("immer-state"):"__$immer_state",hfe=""+Object.prototype.constructor,PC=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,mfe=Object.getOwnPropertyDescriptors||function(e){var t={};return PC(e).forEach(function(n){t[n]=Object.getOwnPropertyDescriptor(e,n)}),t},gfe={},rw={get:function(e,t){if(t===Lo)return e;var n=Gs(e);if(!Zb(n,t))return function(o,a,i){var l,c=m_(a,i);return c?"value"in c?c.value:(l=c.get)===null||l===void 0?void 0:l.call(o.k):void 0}(e,n,t);var r=n[t];return e.I||!wl(r)?r:r===M1(e.t,t)?(D1(e),e.o[t]=nw(e.A.h,r,e)):r},has:function(e,t){return t in Gs(e)},ownKeys:function(e){return Reflect.ownKeys(Gs(e))},set:function(e,t,n){var r=m_(Gs(e),t);if(r!=null&&r.set)return r.set.call(e.k,n),!0;if(!e.P){var o=M1(Gs(e),t),a=o==null?void 0:o[Lo];if(a&&a.t===n)return e.o[t]=n,e.R[t]=!1,!0;if(lfe(n,o)&&(n!==void 0||Zb(e.t,t)))return!0;D1(e),tw(e)}return e.o[t]===n&&(n!==void 0||t in e.o)||Number.isNaN(n)&&Number.isNaN(e.o[t])||(e.o[t]=n,e.R[t]=!0),!0},deleteProperty:function(e,t){return M1(e.t,t)!==void 0||t in e.t?(e.R[t]=!1,D1(e),tw(e)):delete e.R[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var n=Gs(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.i!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},defineProperty:function(){va(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){va(12)}},yd={};kp(rw,function(e,t){yd[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),yd.deleteProperty=function(e,t){return yd.set.call(this,e,t,void 0)},yd.set=function(e,t,n){return rw.set.call(this,e[0],t,n,e[0])};var vfe=function(){function e(n){var r=this;this.g=y_,this.D=!0,this.produce=function(o,a,i){if(typeof o=="function"&&typeof a!="function"){var l=a;a=o;var c=r;return function(g){var v=this;g===void 0&&(g=l);for(var b=arguments.length,w=Array(b>1?b-1:0),x=1;x<b;x++)w[x-1]=arguments[x];return c.produce(g,function(E){var A;return(A=a).call.apply(A,[v,E].concat(w))})}}var u;if(typeof a!="function"&&va(6),i!==void 0&&typeof i!="function"&&va(7),wl(o)){var d=f_(r),f=nw(r,o,void 0),h=!0;try{u=a(f),h=!1}finally{h?Wm(d):ew(d)}return typeof Promise<"u"&&u instanceof Promise?u.then(function(g){return L1(d,i),N1(g,d)},function(g){throw Wm(d),g}):(L1(d,i),N1(u,d))}if(!o||typeof o!="object"){if((u=a(o))===void 0&&(u=o),u===FO&&(u=void 0),r.D&&AC(u,!0),i){var m=[],y=[];Xa("Patches").M(o,u,m,y),i(m,y)}return u}va(21,o)},this.produceWithPatches=function(o,a){if(typeof o=="function")return function(u){for(var d=arguments.length,f=Array(d>1?d-1:0),h=1;h<d;h++)f[h-1]=arguments[h];return r.produceWithPatches(u,function(m){return o.apply(void 0,[m].concat(f))})};var i,l,c=r.produce(o,a,function(u,d){i=u,l=d});return typeof Promise<"u"&&c instanceof Promise?c.then(function(u){return[u,i,l]}):[c,i,l]},typeof(n==null?void 0:n.useProxies)=="boolean"&&this.setUseProxies(n.useProxies),typeof(n==null?void 0:n.autoFreeze)=="boolean"&&this.setAutoFreeze(n.autoFreeze)}var t=e.prototype;return t.createDraft=function(n){wl(n)||va(8),Vc(n)&&(n=dfe(n));var r=f_(this),o=nw(this,n,void 0);return o[Lo].C=!0,ew(r),o},t.finishDraft=function(n,r){var o=n&&n[Lo],a=o.A;return L1(a,r),N1(void 0,a)},t.setAutoFreeze=function(n){this.D=n},t.setUseProxies=function(n){n&&!y_&&va(20),this.g=n},t.applyPatches=function(n,r){var o;for(o=r.length-1;o>=0;o--){var a=r[o];if(a.path.length===0&&a.op==="replace"){n=a.value;break}}o>-1&&(r=r.slice(o+1));var i=Xa("Patches").$;return Vc(n)?i(n,r):this.produce(n,function(l){return i(l,r)})},e}(),No=new vfe,yfe=No.produce;No.produceWithPatches.bind(No);No.setAutoFreeze.bind(No);No.setUseProxies.bind(No);No.applyPatches.bind(No);No.createDraft.bind(No);No.finishDraft.bind(No);const Ko=yfe,bfe=Nr("form")({display:"flex",flexDirection:"column",height:"100%",gap:"1rem"}),Gl=Nr("section")({marginBottom:"36px"}),ow=Nr("p")({marginBottom:"0.5rem"}),wfe=Nr("div")({maxWidth:"600px"}),Sfe=Nr("div")({marginTop:"auto",display:"flex",justifyContent:"flex-end"}),xfe=Nr("section")(({theme:e})=>({paddingTop:e.spacing(2),"& > *":{marginRight:e.spacing(1)}})),w_=Nr(mn)({width:"100%",marginBottom:"1rem",marginTop:"0px"}),Cfe=Nr(Tr)({paddingBottom:"16px"}),zO=Nr("h4")({marginBottom:"8px"}),Efe=Nr("div")({marginTop:"25px"}),Tfe=({type:e="text",sensitive:t=!1},n)=>t&&n===kfe||e==="textfield"?"text":e,kfe="*****",Afe=({definition:e,config:t,parametersErrors:n,setParameterValue:r})=>{const o=t.parameters[e.name]||"",a=Tfe(e,o),i=n[e.name];return s(Efe,{children:s(mn,{size:"small",style:{width:"100%"},minRows:e.type==="textfield"?9:0,multiline:e.type==="textfield",type:a,label:T(ke,{children:[e.displayName,e.required?s(ye,{component:"span",color:"error",children:"*"}):null]}),name:e.name,placeholder:e.placeholder||"",InputLabelProps:{shrink:!0},value:o,error:Boolean(i),onChange:r(e.name),variant:"outlined",helperText:e.description})})},_fe=({provider:e,config:t,parametersErrors:n,setParameterValue:r,editMode:o})=>e?T(jt.Fragment,{children:[s(zO,{children:"Parameters"}),o?T("p",{children:['Sensitive parameters will be masked with value "',s("i",{children:"*****"}),`". If you don't change the value they will not be updated when saving.`]}):null,e.parameters.map(a=>s(Afe,{definition:a,parametersErrors:n,config:t,setParameterValue:r},a.name))]}):null;var Gm={},Rfe={get exports(){return Gm},set exports(e){Gm=e}};(function(e,t){var n=200,r="__lodash_hash_undefined__",o=9007199254740991,a="[object Arguments]",i="[object Array]",l="[object Boolean]",c="[object Date]",u="[object Error]",d="[object Function]",f="[object GeneratorFunction]",h="[object Map]",m="[object Number]",y="[object Object]",g="[object Promise]",v="[object RegExp]",b="[object Set]",w="[object String]",x="[object Symbol]",E="[object WeakMap]",A="[object ArrayBuffer]",k="[object DataView]",_="[object Float32Array]",$="[object Float64Array]",L="[object Int8Array]",O="[object Int16Array]",P="[object Int32Array]",D="[object Uint8Array]",F="[object Uint8ClampedArray]",U="[object Uint16Array]",Y="[object Uint32Array]",V=/[\\^$.*+?()[\]{}|]/g,te=/\w*$/,Z=/^\[object .+?Constructor\]$/,W=/^(?:0|[1-9]\d*)$/,z={};z[a]=z[i]=z[A]=z[k]=z[l]=z[c]=z[_]=z[$]=z[L]=z[O]=z[P]=z[h]=z[m]=z[y]=z[v]=z[b]=z[w]=z[x]=z[D]=z[F]=z[U]=z[Y]=!0,z[u]=z[d]=z[E]=!1;var R=typeof Fa=="object"&&Fa&&Fa.Object===Object&&Fa,M=typeof self=="object"&&self&&self.Object===Object&&self,ee=R||M||Function("return this")(),re=t&&!t.nodeType&&t,Se=re&&!0&&e&&!e.nodeType&&e,ce=Se&&Se.exports===re;function Ce(H,oe){return H.set(oe[0],oe[1]),H}function xe(H,oe){return H.add(oe),H}function Ee(H,oe){for(var ge=-1,nt=H?H.length:0;++ge<nt&&oe(H[ge],ge,H)!==!1;);return H}function tt(H,oe){for(var ge=-1,nt=oe.length,er=H.length;++ge<nt;)H[er+ge]=oe[ge];return H}function me(H,oe,ge,nt){var er=-1,Pr=H?H.length:0;for(nt&&Pr&&(ge=H[++er]);++er<Pr;)ge=oe(ge,H[er],er,H);return ge}function Ge(H,oe){for(var ge=-1,nt=Array(H);++ge<H;)nt[ge]=oe(ge);return nt}function qe(H,oe){return H==null?void 0:H[oe]}function Be(H){var oe=!1;if(H!=null&&typeof H.toString!="function")try{oe=!!(H+"")}catch{}return oe}function he(H){var oe=-1,ge=Array(H.size);return H.forEach(function(nt,er){ge[++oe]=[er,nt]}),ge}function Et(H,oe){return function(ge){return H(oe(ge))}}function Ke(H){var oe=-1,ge=Array(H.size);return H.forEach(function(nt){ge[++oe]=nt}),ge}var ct=Array.prototype,Rt=Function.prototype,dt=Object.prototype,rt=ee["__core-js_shared__"],Nt=function(){var H=/[^.]+$/.exec(rt&&rt.keys&&rt.keys.IE_PROTO||"");return H?"Symbol(src)_1."+H:""}(),xt=Rt.toString,pe=dt.hasOwnProperty,Te=dt.toString,Xe=RegExp("^"+xt.call(pe).replace(V,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),De=ce?ee.Buffer:void 0,q=ee.Symbol,K=ee.Uint8Array,se=Et(Object.getPrototypeOf,Object),be=Object.create,Ae=dt.propertyIsEnumerable,mt=ct.splice,et=Object.getOwnPropertySymbols,ht=De?De.isBuffer:void 0,Xt=Et(Object.keys,Object),Mn=si(ee,"DataView"),pt=si(ee,"Map"),pn=si(ee,"Promise"),Vt=si(ee,"Set"),en=si(ee,"WeakMap"),Ft=si(Object,"create"),Hn=ci(Mn),br=ci(pt),ro=ci(pn),yo=ci(Vt),bo=ci(en),Rr=q?q.prototype:void 0,oo=Rr?Rr.valueOf:void 0;function Jn(H){var oe=-1,ge=H?H.length:0;for(this.clear();++oe<ge;){var nt=H[oe];this.set(nt[0],nt[1])}}function ao(){this.__data__=Ft?Ft(null):{}}function wr(H){return this.has(H)&&delete this.__data__[H]}function Bt(H){var oe=this.__data__;if(Ft){var ge=oe[H];return ge===r?void 0:ge}return pe.call(oe,H)?oe[H]:void 0}function Gt(H){var oe=this.__data__;return Ft?oe[H]!==void 0:pe.call(oe,H)}function jn(H,oe){var ge=this.__data__;return ge[H]=Ft&&oe===void 0?r:oe,this}Jn.prototype.clear=ao,Jn.prototype.delete=wr,Jn.prototype.get=Bt,Jn.prototype.has=Gt,Jn.prototype.set=jn;function hr(H){var oe=-1,ge=H?H.length:0;for(this.clear();++oe<ge;){var nt=H[oe];this.set(nt[0],nt[1])}}function Kr(){this.__data__=[]}function Yr(H){var oe=this.__data__,ge=Os(oe,H);if(ge<0)return!1;var nt=oe.length-1;return ge==nt?oe.pop():mt.call(oe,ge,1),!0}function pa(H){var oe=this.__data__,ge=Os(oe,H);return ge<0?void 0:oe[ge][1]}function ue(H){return Os(this.__data__,H)>-1}function ae(H,oe){var ge=this.__data__,nt=Os(ge,H);return nt<0?ge.push([H,oe]):ge[nt][1]=oe,this}hr.prototype.clear=Kr,hr.prototype.delete=Yr,hr.prototype.get=pa,hr.prototype.has=ue,hr.prototype.set=ae;function Fe(H){var oe=-1,ge=H?H.length:0;for(this.clear();++oe<ge;){var nt=H[oe];this.set(nt[0],nt[1])}}function ot(){this.__data__={hash:new Jn,map:new(pt||hr),string:new Jn}}function kt(H){return Ls(this,H).delete(H)}function Tn(H){return Ls(this,H).get(H)}function _n(H){return Ls(this,H).has(H)}function yt(H,oe){return Ls(this,H).set(H,oe),this}Fe.prototype.clear=ot,Fe.prototype.delete=kt,Fe.prototype.get=Tn,Fe.prototype.has=_n,Fe.prototype.set=yt;function Rn(H){this.__data__=new hr(H)}function ty(){this.__data__=new hr}function ny(H){return this.__data__.delete(H)}function ry(H){return this.__data__.get(H)}function df(H){return this.__data__.has(H)}function pf(H,oe){var ge=this.__data__;if(ge instanceof hr){var nt=ge.__data__;if(!pt||nt.length<n-1)return nt.push([H,oe]),this;ge=this.__data__=new Fe(nt)}return ge.set(H,oe),this}Rn.prototype.clear=ty,Rn.prototype.delete=ny,Rn.prototype.get=ry,Rn.prototype.has=df,Rn.prototype.set=pf;function oy(H,oe){var ge=Ns(H)||Ty(H)?Ge(H.length,String):[],nt=ge.length,er=!!nt;for(var Pr in H)(oe||pe.call(H,Pr))&&!(er&&(Pr=="length"||Sy(Pr,nt)))&&ge.push(Pr);return ge}function ff(H,oe,ge){var nt=H[oe];(!(pe.call(H,oe)&&yf(nt,ge))||ge===void 0&&!(oe in H))&&(H[oe]=ge)}function Os(H,oe){for(var ge=H.length;ge--;)if(yf(H[ge][0],oe))return ge;return-1}function hf(H,oe){return H&&gf(oe,Ds(oe),H)}function Eu(H,oe,ge,nt,er,Pr,Dr){var S;if(nt&&(S=Pr?nt(H,er,Pr,Dr):nt(H)),S!==void 0)return S;if(!Ms(H))return H;var N=Ns(H);if(N){if(S=by(H),!oe)return gy(H,S)}else{var B=li(H),j=B==d||B==f;if(Ru(H))return uy(H,oe);if(B==y||B==a||j&&!Pr){if(Be(H))return Pr?H:{};if(S=wy(j?{}:H),!oe)return vy(H,hf(S,H))}else{if(!z[B])return Pr?H:{};S=vf(H,B,Eu,oe)}}Dr||(Dr=new Rn);var J=Dr.get(H);if(J)return J;if(Dr.set(H,S),!N)var G=ge?yy(H):Ds(H);return Ee(G||H,function(Q,le){G&&(le=Q,Q=H[le]),ff(S,le,Eu(Q,oe,ge,nt,le,H,Dr))}),S}function ay(H){return Ms(H)?be(H):{}}function iy(H,oe,ge){var nt=oe(H);return Ns(H)?nt:tt(nt,ge(H))}function sy(H){return Te.call(H)}function ly(H){if(!Ms(H)||Cy(H))return!1;var oe=Ml(H)||Be(H)?Xe:Z;return oe.test(ci(H))}function cy(H){if(!Au(H))return Xt(H);var oe=[];for(var ge in Object(H))pe.call(H,ge)&&ge!="constructor"&&oe.push(ge);return oe}function uy(H,oe){if(oe)return H.slice();var ge=new H.constructor(H.length);return H.copy(ge),ge}function Tu(H){var oe=new H.constructor(H.byteLength);return new K(oe).set(new K(H)),oe}function dy(H,oe){var ge=oe?Tu(H.buffer):H.buffer;return new H.constructor(ge,H.byteOffset,H.byteLength)}function py(H,oe,ge){var nt=oe?ge(he(H),!0):he(H);return me(nt,Ce,new H.constructor)}function fy(H){var oe=new H.constructor(H.source,te.exec(H));return oe.lastIndex=H.lastIndex,oe}function mf(H,oe,ge){var nt=oe?ge(Ke(H),!0):Ke(H);return me(nt,xe,new H.constructor)}function hy(H){return oo?Object(oo.call(H)):{}}function my(H,oe){var ge=oe?Tu(H.buffer):H.buffer;return new H.constructor(ge,H.byteOffset,H.length)}function gy(H,oe){var ge=-1,nt=H.length;for(oe||(oe=Array(nt));++ge<nt;)oe[ge]=H[ge];return oe}function gf(H,oe,ge,nt){ge||(ge={});for(var er=-1,Pr=oe.length;++er<Pr;){var Dr=oe[er],S=nt?nt(ge[Dr],H[Dr],Dr,ge,H):void 0;ff(ge,Dr,S===void 0?H[Dr]:S)}return ge}function vy(H,oe){return gf(H,ku(H),oe)}function yy(H){return iy(H,Ds,ku)}function Ls(H,oe){var ge=H.__data__;return xy(oe)?ge[typeof oe=="string"?"string":"hash"]:ge.map}function si(H,oe){var ge=qe(H,oe);return ly(ge)?ge:void 0}var ku=et?Et(et,Object):Ay,li=sy;(Mn&&li(new Mn(new ArrayBuffer(1)))!=k||pt&&li(new pt)!=h||pn&&li(pn.resolve())!=g||Vt&&li(new Vt)!=b||en&&li(new en)!=E)&&(li=function(H){var oe=Te.call(H),ge=oe==y?H.constructor:void 0,nt=ge?ci(ge):void 0;if(nt)switch(nt){case Hn:return k;case br:return h;case ro:return g;case yo:return b;case bo:return E}return oe});function by(H){var oe=H.length,ge=H.constructor(oe);return oe&&typeof H[0]=="string"&&pe.call(H,"index")&&(ge.index=H.index,ge.input=H.input),ge}function wy(H){return typeof H.constructor=="function"&&!Au(H)?ay(se(H)):{}}function vf(H,oe,ge,nt){var er=H.constructor;switch(oe){case A:return Tu(H);case l:case c:return new er(+H);case k:return dy(H,nt);case _:case $:case L:case O:case P:case D:case F:case U:case Y:return my(H,nt);case h:return py(H,nt,ge);case m:case w:return new er(H);case v:return fy(H);case b:return mf(H,nt,ge);case x:return hy(H)}}function Sy(H,oe){return oe=oe??o,!!oe&&(typeof H=="number"||W.test(H))&&H>-1&&H%1==0&&H<oe}function xy(H){var oe=typeof H;return oe=="string"||oe=="number"||oe=="symbol"||oe=="boolean"?H!=="__proto__":H===null}function Cy(H){return!!Nt&&Nt in H}function Au(H){var oe=H&&H.constructor,ge=typeof oe=="function"&&oe.prototype||dt;return H===ge}function ci(H){if(H!=null){try{return xt.call(H)}catch{}try{return H+""}catch{}}return""}function Ey(H){return Eu(H,!0,!0)}function yf(H,oe){return H===oe||H!==H&&oe!==oe}function Ty(H){return Nl(H)&&pe.call(H,"callee")&&(!Ae.call(H,"callee")||Te.call(H)==a)}var Ns=Array.isArray;function _u(H){return H!=null&&bf(H.length)&&!Ml(H)}function Nl(H){return ky(H)&&_u(H)}var Ru=ht||_y;function Ml(H){var oe=Ms(H)?Te.call(H):"";return oe==d||oe==f}function bf(H){return typeof H=="number"&&H>-1&&H%1==0&&H<=o}function Ms(H){var oe=typeof H;return!!H&&(oe=="object"||oe=="function")}function ky(H){return!!H&&typeof H=="object"}function Ds(H){return _u(H)?oy(H):cy(H)}function Ay(){return[]}function _y(){return!1}e.exports=Ey})(Rfe,Gm);const IC=Gm;var $C={},Pfe=cn;Object.defineProperty($C,"__esModule",{value:!0});var Ov=$C.default=void 0,Ife=Pfe(Cn()),$fe=En,Ofe=(0,Ife.default)((0,$fe.jsx)("path",{d:"M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"}),"CheckBoxOutlineBlank");Ov=$C.default=Ofe;var OC={},Lfe=cn;Object.defineProperty(OC,"__esModule",{value:!0});var Lv=OC.default=void 0,Nfe=Lfe(Cn()),Mfe=En,Dfe=(0,Nfe.default)((0,Mfe.jsx)("path",{d:"M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"}),"CheckBox");Lv=OC.default=Dfe;const Bfe=C(go)(({theme:e})=>({cursor:"pointer",fontSize:e.fontSizes.bodySize})),LC=({isAllSelected:e,onClick:t})=>s(Me,{sx:{ml:3.5,my:.5},children:s(Bfe,{onClick:t,component:"button",underline:"hover",children:e?"Deselect all":"Select all"})}),ih="*",Ffe=Nr(Rs)(()=>({marginRight:"0.2em"})),zfe=({...e})=>s(pr,{elevation:8,...e}),B1=({options:e,selectedItems:t,onChange:n,error:r,onFocus:o,entityName:a,selectAllEnabled:i=!0,description:l,required:c})=>{const[u,d]=p.useState(t.includes(ih)),f=x=>s(mn,{...x,error:Boolean(r),helperText:r,variant:"outlined",label:`${ie(a)}s`,placeholder:`Select ${a}s to filter by`,onFocus:o,"data-testid":`select-${a}-input`}),h=t.length>0&&t.length===e.length&&t[0]!==ih,m=(x,E)=>{E?(d(!0),n([ih])):(d(!1),n(t.includes(ih)?[]:t))},y=()=>{const x=h?[]:e.map(({value:E})=>E);n(x)},g=(x,E,{selected:A})=>T("li",{...x,children:[s(Ffe,{icon:s(Ov,{fontSize:"small"}),checkedIcon:s(Lv,{fontSize:"small"}),checked:A}),E.label]}),v=({key:x,children:E})=>T(p.Fragment,{children:[s(X,{condition:e.length>2&&i,show:s(LC,{isAllSelected:h,onClick:y})}),E]},x),b=()=>s(Cfe,{"data-testid":`select-all-${a}s`,control:s(Rs,{checked:u,onChange:m}),label:`ALL current and future ${a}s`}),w=()=>T(ow,{children:["Selecting ",a,"(s) here will filter events so that your addon will only receive events that are tagged with one of your"," ",a,"s."]});return T(jt.Fragment,{children:[T(zO,{children:[ie(a),"s",c?s(ye,{component:"span",color:"error",children:"*"}):null]}),s(X,{condition:l!==void 0,show:s(ow,{children:l})}),s(X,{condition:i,show:s(w,{})}),s(X,{condition:i,show:s(b,{})}),s(av,{sx:{mb:8},disabled:u,multiple:!0,limitTags:2,options:e,disableCloseOnSelect:!0,getOptionLabel:({label:x})=>x,fullWidth:!0,groupBy:()=>"Select/Deselect all",renderGroup:v,PaperComponent:zfe,renderOption:g,renderInput:f,value:u?e:e.filter(x=>t.includes(x.value)),onChange:(x,E)=>{const A=E.map(({value:k})=>k);n(A)}})]})},jO=({editMode:e,provider:t,addon:n,fetch:r})=>{const{createAddon:o,updateAddon:a}=eO(),{setToastData:i,setToastApiError:l}=It(),c=lt(),u=au(),{projects:d}=Bi(),f=d.map(Z=>({value:Z.id,label:Z.name})),{environments:h}=uu(),m=h.map(Z=>({value:Z.name,label:Z.name})),y=t==null?void 0:t.events.map(Z=>({value:Z,label:Z})),{uiConfig:g}=Lt(),[v,b]=p.useState(n),[w,x]=p.useState({containsErrors:!1,parameters:{}}),E=e?"Update":"Create";let A=`${g.unleashUrl}/api/admin/addons${e?`/${v.id}`:""}`;const k=()=>`curl --location --request ${e?"PUT":"POST"} '${A}' \\
|
|
322
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
323
|
+
--header 'Content-Type: application/json' \\
|
|
324
|
+
--data-raw '${JSON.stringify(v,void 0,2)}'`;p.useEffect(()=>{t||r()},[r,t]),p.useEffect(()=>{b({...n})},[n.description,n.provider]),p.useEffect(()=>{t&&!v.provider&&b({...n,provider:t.name})},[t,n,v.provider]);const _=Z=>W=>{W.preventDefault(),b({...v,[Z]:W.target.value})},$=Z=>{Z.preventDefault(),b(({enabled:W})=>({...v,enabled:!W}))},L=Z=>W=>{W.preventDefault();const z=Cs(W.target.value)===""?void 0:W.target.value;b(Ko(R=>{R.parameters[Z]=z}))},O=Z=>{b(Ko(W=>{W.events=Z})),x(W=>({...W,events:void 0}))},P=Z=>{b(Ko(W=>{W.projects=Z})),x(W=>({...W,projects:void 0}))},D=Z=>{b(Ko(W=>{W.environments=Z})),x(W=>({...W,environments:void 0}))},F=()=>{c(jo)},U=async Z=>{if(Z.preventDefault(),!t)return;const W=IC(w);if(W.parameters={},W.containsErrors=!1,v.events.length===0&&(W.events="You must listen to at least one event",W.containsErrors=!0),t.parameters.forEach(z=>{const R=Cs(v.parameters[z.name]);z.required&&!R&&(W.parameters[z.name]="This field is required",W.containsErrors=!0)}),W.containsErrors){x(W);return}try{e?(await a(v),c("/addons"),i({type:"success",title:"Addon updated successfully"})):(await o(v),c("/addons"),i({type:"success",confetti:!0,title:"Addon created successfully"}))}catch(z){const R=ft(z);l(R),x({parameters:{},general:R,containsErrors:!0})}},{name:Y,description:V,documentationUrl:te="https://unleash.github.io/docs/addons"}=t||{};return s(Mr,{title:`${E} ${Y} addon`,description:V||"",documentationLink:te,documentationLinkLabel:"Addon documentation",formatApiCode:k,children:T(bfe,{onSubmit:U,children:[T(wfe,{children:[T(Gl,{children:[s(w_,{size:"small",label:"Provider",name:"provider",value:v.provider,disabled:!0,hidden:!0,variant:"outlined"}),s(Tr,{control:s(Ii,{checked:v.enabled,onClick:$}),label:v.enabled?"Enabled":"Disabled"})]}),T(Gl,{children:[s(ow,{children:"What is your addon description?"}),s(w_,{size:"small",style:{width:"80%"},minRows:4,multiline:!0,label:"Description",name:"description",placeholder:"",value:v.description,error:Boolean(w.description),helperText:w.description,onChange:_("description"),variant:"outlined"})]}),s(Gl,{children:s(B1,{options:y||[],selectedItems:v.events,onChange:O,entityName:"event",selectAllEnabled:!1,error:w.events,description:"Select what events you want your addon to be notified about.",required:!0})}),s(Gl,{children:s(B1,{options:f,selectedItems:v.projects||[],onChange:P,entityName:"project",selectAllEnabled:!0})}),s(Gl,{children:s(B1,{options:m,selectedItems:v.environments||[],onChange:D,entityName:"environment",selectAllEnabled:!0})}),s(Gl,{children:s(_fe,{provider:t,config:v,parametersErrors:w.parameters,editMode:e,setParameterValue:L})})]}),s(mo,{}),s(Sfe,{children:T(xfe,{theme:u,children:[s(zo,{type:"submit",color:"primary",variant:"contained",permission:e?Fb:m3,children:E}),s(Ze,{type:"button",onClick:F,children:"Cancel"})]})})]})})},UO={provider:"",description:"",enabled:!0,parameters:{},events:[],projects:[],environments:[]},jfe=()=>{const e=dr("providerId"),{providers:t,refetchAddons:n}=Av(),r=!1,o=t.find(i=>i.name===e),a={...IC(UO),provider:o?o.name:""};return s(jO,{editMode:r,provider:o,fetch:n,addon:a})},Ufe=()=>{const e=dr("addonId"),{providers:t,addons:n,refetchAddons:r}=Av(),o=!0,a=n.find(l=>l.id===Number(e))||{...IC(UO)},i=a?t.find(l=>l.name===a.provider):void 0;return s(jO,{editMode:o,provider:i,fetch:r,addon:a})},Wfe="_header_1nxx3_1",Hfe="_content_1nxx3_10",Vfe="_text_1nxx3_25",F1={header:Wfe,content:Hfe,text:Vfe},Gfe=()=>{const[e,t]=p.useState(!0),[n,r]=p.useState(""),[o,a]=p.useState(),[i,l]=p.useState(),{cloneFeatureToggle:c,validateFeatureToggleName:u}=gu(),d=dr("featureId"),f=dr("projectId"),{feature:h}=bl(f,d),m=lt(),y=w=>{const x=Cs(w.target.value);l(x)},g=()=>{t(w=>!w)},v=async()=>{try{return await u(i),a(void 0),!0}catch(w){a(ft(w))}return!1},b=async w=>{if(w.preventDefault(),!!await v())try{await c(f,d,{name:i,replaceGroupId:e}),m(Nm(f,i))}catch(E){r(ft(E))}};return!h||!h.name?s("span",{children:"Toggle not found"}):T(pr,{className:Ec.fullwidth,style:{overflow:"visible"},children:[s("div",{className:F1.header,children:T("h1",{children:["Copy ",d]})}),s(X,{condition:Boolean(n),show:s(Zt,{severity:"error",children:n})}),T("section",{className:F1.content,children:[T("p",{className:F1.text,children:["You are about to create a new feature toggle by cloning the configuration of feature toggle ",s(ln,{to:Nm(f,d),children:d}),". You must give the new feature toggle a unique name before you can proceed."]}),T("form",{onSubmit:b,children:[s(mn,{label:"Name",name:"name",value:i||"",onBlur:v,onChange:y,error:o!==void 0,helperText:o,variant:"outlined",size:"small","aria-required":!0,autoFocus:!0}),s(Tr,{control:s(Ii,{value:e,checked:e,onChange:g}),label:"Replace groupId"}),T(Ze,{type:"submit",color:"primary",variant:"contained",children:[s(L4,{})," Create from copy"]})]})]})]})},WO=()=>s(Zt,{severity:"error",children:"You need instance admin to access this section."}),qfe=C("li")(({theme:e})=>({padding:e.spacing(4),backgroundColor:e.palette.neutral.light,borderRadius:e.shape.borderRadiusLarge,fontSize:e.fontSizes.smallBody,"& code":{wordWrap:"break-word",whiteSpace:"pre-wrap",fontFamily:"monospace",lineHeight:"100%"}})),Kfe=({entry:e})=>{const t=JSON.parse(JSON.stringify(e));delete t.description,delete t.name,delete t.diffs;const n=JSON.stringify(t,null,2);return s(qfe,{children:s("div",{children:s("code",{children:n})})})};var aw={},Yfe={get exports(){return aw},set exports(e){aw=e}};(function(e,t){(function(n,r){var o=r(n);e.exports=o})(Fa,function(n){var r=["N","E","A","D"];function o($,L){$.super_=L,$.prototype=Object.create(L.prototype,{constructor:{value:$,enumerable:!1,writable:!0,configurable:!0}})}function a($,L){Object.defineProperty(this,"kind",{value:$,enumerable:!0}),L&&L.length&&Object.defineProperty(this,"path",{value:L,enumerable:!0})}function i($,L,O){i.super_.call(this,"E",$),Object.defineProperty(this,"lhs",{value:L,enumerable:!0}),Object.defineProperty(this,"rhs",{value:O,enumerable:!0})}o(i,a);function l($,L){l.super_.call(this,"N",$),Object.defineProperty(this,"rhs",{value:L,enumerable:!0})}o(l,a);function c($,L){c.super_.call(this,"D",$),Object.defineProperty(this,"lhs",{value:L,enumerable:!0})}o(c,a);function u($,L,O){u.super_.call(this,"A",$),Object.defineProperty(this,"index",{value:L,enumerable:!0}),Object.defineProperty(this,"item",{value:O,enumerable:!0})}o(u,a);function d($,L,O){var P=$.slice((O||L)+1||$.length);return $.length=L<0?$.length+L:L,$.push.apply($,P),$}function f($){var L=typeof $;return L!=="object"?L:$===Math?"math":$===null?"null":Array.isArray($)?"array":Object.prototype.toString.call($)==="[object Date]"?"date":typeof $.toString=="function"&&/^\/.*\//.test($.toString())?"regexp":"object"}function h($){var L=0;if($.length===0)return L;for(var O=0;O<$.length;O++){var P=$.charCodeAt(O);L=(L<<5)-L+P,L=L&L}return L}function m($){var L=0,O=f($);if(O==="array"){$.forEach(function(Y){L+=m(Y)});var P="[type: array, hash: "+L+"]";return L+h(P)}if(O==="object"){for(var D in $)if($.hasOwnProperty(D)){var F="[ type: object, key: "+D+", value hash: "+m($[D])+"]";L+=h(F)}return L}var U="[ type: "+O+" ; value: "+$+"]";return L+h(U)}function y($,L,O,P,D,F,U,Y){O=O||[],D=D||[],U=U||[];var V=D.slice(0);if(typeof F<"u"&&F!==null){if(P){if(typeof P=="function"&&P(V,F))return;if(typeof P=="object"){if(P.prefilter&&P.prefilter(V,F))return;if(P.normalize){var te=P.normalize(V,F,$,L);te&&($=te[0],L=te[1])}}}V.push(F)}f($)==="regexp"&&f(L)==="regexp"&&($=$.toString(),L=L.toString());var Z=typeof $,W=typeof L,z,R,M,ee,re=Z!=="undefined"||U&&U.length>0&&U[U.length-1].lhs&&Object.getOwnPropertyDescriptor(U[U.length-1].lhs,F),Se=W!=="undefined"||U&&U.length>0&&U[U.length-1].rhs&&Object.getOwnPropertyDescriptor(U[U.length-1].rhs,F);if(!re&&Se)O.push(new l(V,L));else if(!Se&&re)O.push(new c(V,$));else if(f($)!==f(L))O.push(new i(V,$,L));else if(f($)==="date"&&$-L!==0)O.push(new i(V,$,L));else if(Z==="object"&&$!==null&&L!==null){for(z=U.length-1;z>-1;--z)if(U[z].lhs===$){ee=!0;break}if(ee)$!==L&&O.push(new i(V,$,L));else{if(U.push({lhs:$,rhs:L}),Array.isArray($)){for(Y&&($.sort(function(xe,Ee){return m(xe)-m(Ee)}),L.sort(function(xe,Ee){return m(xe)-m(Ee)})),z=L.length-1,R=$.length-1;z>R;)O.push(new u(V,z,new l(void 0,L[z--])));for(;R>z;)O.push(new u(V,R,new c(void 0,$[R--])));for(;z>=0;--z)y($[z],L[z],O,P,V,z,U,Y)}else{var ce=Object.keys($),Ce=Object.keys(L);for(z=0;z<ce.length;++z)M=ce[z],ee=Ce.indexOf(M),ee>=0?(y($[M],L[M],O,P,V,M,U,Y),Ce[ee]=null):y($[M],void 0,O,P,V,M,U,Y);for(z=0;z<Ce.length;++z)M=Ce[z],M&&y(void 0,L[M],O,P,V,M,U,Y)}U.length=U.length-1}}else $!==L&&(Z==="number"&&isNaN($)&&isNaN(L)||O.push(new i(V,$,L)))}function g($,L,O,P,D){var F=[];if(y($,L,F,P,null,null,null,D),O)for(var U=0;U<F.length;++U)O(F[U]);return F}function v($,L,O,P,D,F,U){return y($,L,O,P,D,F,U,!0)}function b($,L,O,P){var D=P?function(U){U&&P.push(U)}:void 0,F=g($,L,D,O);return P||(F.length?F:void 0)}function w($,L,O,P){var D=P?function(U){U&&P.push(U)}:void 0,F=g($,L,D,O,!0);return P||(F.length?F:void 0)}function x($,L,O){if(O.path&&O.path.length){var P=$[L],D,F=O.path.length-1;for(D=0;D<F;D++)P=P[O.path[D]];switch(O.kind){case"A":x(P[O.path[D]],O.index,O.item);break;case"D":delete P[O.path[D]];break;case"E":case"N":P[O.path[D]]=O.rhs;break}}else switch(O.kind){case"A":x($[L],O.index,O.item);break;case"D":$=d($,L);break;case"E":case"N":$[L]=O.rhs;break}return $}function E($,L,O){if(typeof O>"u"&&L&&~r.indexOf(L.kind)&&(O=L),$&&O&&O.kind){for(var P=$,D=-1,F=O.path?O.path.length-1:0;++D<F;)typeof P[O.path[D]]>"u"&&(P[O.path[D]]=typeof O.path[D+1]<"u"&&typeof O.path[D+1]=="number"?[]:{}),P=P[O.path[D]];switch(O.kind){case"A":O.path&&typeof P[O.path[D]]>"u"&&(P[O.path[D]]=[]),x(O.path?P[O.path[D]]:P,O.index,O.item);break;case"D":delete P[O.path[D]];break;case"E":case"N":P[O.path[D]]=O.rhs;break}}}function A($,L,O){if(O.path&&O.path.length){var P=$[L],D,F=O.path.length-1;for(D=0;D<F;D++)P=P[O.path[D]];switch(O.kind){case"A":A(P[O.path[D]],O.index,O.item);break;case"D":P[O.path[D]]=O.lhs;break;case"E":P[O.path[D]]=O.lhs;break;case"N":delete P[O.path[D]];break}}else switch(O.kind){case"A":A($[L],O.index,O.item);break;case"D":$[L]=O.lhs;break;case"E":$[L]=O.lhs;break;case"N":$=d($,L);break}return $}function k($,L,O){if($&&L&&O&&O.kind){var P=$,D,F;for(F=O.path.length-1,D=0;D<F;D++)typeof P[O.path[D]]>"u"&&(P[O.path[D]]={}),P=P[O.path[D]];switch(O.kind){case"A":A(P[O.path[D]],O.index,O.item);break;case"D":P[O.path[D]]=O.lhs;break;case"E":P[O.path[D]]=O.lhs;break;case"N":delete P[O.path[D]];break}}}function _($,L,O){if($&&L){var P=function(D){(!O||O($,L,D))&&E($,L,D)};g($,L,P)}}return Object.defineProperties(b,{diff:{value:b,enumerable:!0},orderIndependentDiff:{value:w,enumerable:!0},observableDiff:{value:g,enumerable:!0},orderIndependentObservableDiff:{value:v,enumerable:!0},orderIndepHash:{value:m,enumerable:!0},applyDiff:{value:_,enumerable:!0},applyChange:{value:E,enumerable:!0},revertChange:{value:k,enumerable:!0},isConflict:{value:function(){return typeof $conflict<"u"},enumerable:!0}}),b.DeepDiff=b,n&&(n.DeepDiff=b),b})})(Yfe);const Xfe={A:" ",E:" ",D:"-",N:"+"},Nv=({entry:e})=>{const t=au(),n={A:{color:t.palette.code.edited},E:{color:t.palette.code.edited},D:{color:t.palette.code.diffSub},N:{color:t.palette.code.diffAdd}},r=e.data&&e.preData?aw.diff(e.preData,e.data):void 0,o=(l,c)=>{let u;return l.lhs!==void 0?u=T("div",{style:n.D,children:["- ",c,": ",JSON.stringify(l.lhs)]}):l.rhs!==void 0&&(u=T("div",{style:n.N,children:["+ ",c,": ",JSON.stringify(l.rhs)]})),u},a=(l,c)=>{var f;let u;const d=((f=l.path)==null?void 0:f.join("."))??l.index;return l.item?u=o(l.item,d):l.lhs!==void 0&&l.rhs!==void 0?u=T("div",{children:[T("div",{style:n.D,children:["- ",d,": ",JSON.stringify(l.lhs)]}),T("div",{style:n.N,children:["+ ",d,": ",JSON.stringify(l.rhs)]})]}):u=T("div",{style:n[l.kind],children:[Xfe[l.kind]," ",d,":"," ",JSON.stringify(l.rhs||l.item)]}),{key:d.toString(),value:s("div",{children:u},c)}};let i;if(r)i=r.map(a).sort((l,c)=>l.key.localeCompare(c.key)).map(({value:l})=>l);else{const l=e.data||e.preData;i=[s("div",{style:e.data?n.N:n.D,children:JSON.stringify(l,null,2)},0)]}return s("pre",{style:{overflowX:"auto",overflowY:"hidden"},tabIndex:0,children:s("code",{children:i.length===0?"(no changes)":i})})},Fs=C("dt")(({theme:e})=>({color:e.palette.text.secondary})),Jfe=C("strong")(({theme:e})=>({fontWeight:"inherit",color:e.palette.text.secondary})),Qfe=C("li")(({theme:e})=>({display:"grid",backgroundColor:e.palette.neutral.light,borderRadius:e.shape.borderRadiusLarge,padding:e.spacing(.5),[e.breakpoints.up("md")]:{gridTemplateColumns:"2fr 3fr"},"& dl":{display:"grid",gridTemplateColumns:"auto 1fr",alignContent:"start",gap:e.spacing(1),padding:e.spacing(2),[e.breakpoints.up("md")]:{padding:e.spacing(4)}}})),HO=C("div")(({theme:e})=>({backgroundColor:"white",overflowX:"auto",padding:e.spacing(2),borderBottomLeftRadius:e.shape.borderRadiusLarge,borderBottomRightRadius:e.shape.borderRadiusLarge,[e.breakpoints.up("md")]:{padding:e.spacing(4),borderRadius:0,borderTopRightRadius:e.shape.borderRadiusLarge,borderBottomRightRadius:e.shape.borderRadiusLarge},"& code":{wordWrap:"break-word",whiteSpace:"pre-wrap",fontFamily:"monospace",lineHeight:1.5,fontSize:e.fontSizes.smallBody}})),Zfe=({entry:e})=>{const{locationSettings:t}=ii(),n=bv(e.createdAt,t.locale);return T(Qfe,{children:[T("dl",{children:[s(Fs,{children:"Event id:"}),s("dd",{children:e.id}),s(Fs,{children:"Changed at:"}),s("dd",{children:n}),s(Fs,{children:"Event:"}),s("dd",{children:e.type}),s(Fs,{children:"Changed by:"}),s("dd",{title:e.createdBy,children:e.createdBy}),s(X,{condition:Boolean(e.project),show:T(ke,{children:[s(Fs,{children:"Project:"}),s("dd",{children:s(ln,{to:`/projects/${e.project}`,children:e.project})})]})}),s(X,{condition:Boolean(e.featureName),show:T(ke,{children:[s(Fs,{children:"Feature:"}),s("dd",{children:s(ln,{to:`/projects/${e.project}/features/${e.featureName}`,children:e.featureName})})]})}),s(X,{condition:Boolean(e.environment),show:T(ke,{children:[s(Fs,{children:"Environment:"}),s("dd",{children:e.environment})]})})]}),s(X,{condition:e.data||e.preData,show:T(HO,{children:[s(Jfe,{children:"Changes:"}),s(Nv,{entry:e})]})})]})},ehe=()=>{const[e,t]=nhe();return{eventSettings:e,setEventSettings:t}},the=()=>({showData:!1}),nhe=qx(`${Oi}:useEventSettings:v1`,the()),S_=Dt("api/admin/events/search"),rhe=(e,t,n)=>{const[r,o]=p.useState(),[a,i]=p.useState(0),[l,c]=p.useState(0),u=p.useMemo(()=>({project:e,feature:t,query:n,limit:50}),[e,t,n]),{data:d,error:f,isValidating:h}=dn([S_,u,l],()=>ohe(S_,{...u,offset:l}));p.useEffect(()=>{c(0),i(0),o(void 0)},[u]),p.useEffect(()=>{d&&(o(y=>[...(y==null?void 0:y.slice(0,l))||[],...d.events]),d.totalEvents&&i(d.totalEvents))},[d]);const m=p.useCallback(()=>{r&&!h&&c(r.length)},[r,h]);return{events:r,loading:!f&&!d,fetchNextPage:m,totalEvents:a,error:f}},ohe=(e,t)=>fetch(e,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)}).then(yn("Event history")).then(n=>n.json()),ahe=e=>{const t=p.useRef(null);return p.useEffect(()=>{if(t.current){const n=o=>{o[0].isIntersecting&&e()},r=new IntersectionObserver(n);return r.observe(t.current),()=>r.disconnect()}},[e]),t},ihe=Nr("ul")(({theme:e})=>({listStyleType:"none",margin:0,padding:0,display:"grid",gap:e.spacing(2)})),she=({title:e,project:t,feature:n,displayInline:r})=>{const[o,a]=p.useState(""),{events:i,totalEvents:l,fetchNextPage:c}=rhe(t,n,o),u=ahe(c),{eventSettings:d,setEventSettings:f}=ehe(),h=cr(ws.breakpoints.down("md")),[m,y]=p.useState();p.useEffect(()=>i&&y(i),[i]);const g=()=>{f(A=>({showData:!A.showData}))},v=s(Hr,{onChange:a,debounceTime:500}),b=s(Tr,{label:"Full events",control:s(Ii,{checked:d.showData,onChange:g,color:"primary"})});let E=`${(i==null?void 0:i.length)||0} of ${l||0}`;return T(fr,{disablePadding:r,disableBorder:r,header:s(xn,{title:`${e} (${E})`,actions:T(ke,{children:[b,!h&&v]}),children:h&&v}),children:[r&&s(Me,{sx:{mt:4}}),s(X,{condition:Boolean(m&&m.length===0),show:()=>s("p",{children:"No events found."})}),s(X,{condition:Boolean(m&&m.length>0),show:()=>s(ihe,{children:m==null?void 0:m.map(A=>s(X,{condition:d.showData,show:()=>s(Kfe,{entry:A}),elseShow:()=>s(Zfe,{entry:A})},A.id))})}),s("div",{ref:u})]})},lhe=()=>{const{hasAccess:e}=p.useContext(Gr);return s(X,{condition:e(Fo),show:()=>s(she,{title:"Event log"}),elseShow:s(WO,{})})},VO=(e="",t="",n=[])=>{const[r,o]=p.useState(e),[a,i]=p.useState(t),[l,c]=p.useState(n),[u,d]=p.useState({}),{strategies:f}=pu();return p.useEffect(()=>{o(e)},[e]),p.useEffect(()=>{i(t)},[t]),p.useEffect(()=>{c(n)},[JSON.stringify(n)]),{strategyName:r,strategyDesc:a,params:l,setStrategyName:o,setStrategyDesc:i,setParams:c,getStrategyPayload:()=>({name:r,description:a,parameters:l}),validateStrategyName:()=>r.length===0?(d(v=>({...v,name:"Name can not be empty."})),!1):f.some(v=>v.name===r)?(d(v=>({...v,name:"A strategy name with that name already exist"})),!1):!0,validateParams:()=>{let v=!0;for(const[b,w]of Object.entries(l))l.forEach((x,E)=>{x.name.length===0&&(d(A=>({...A,[`paramName${E}`]:"Name can not be empty"})),v=!1)});return v},setErrors:d,clearErrors:()=>{d({})},errors:u}},che=[{key:"string",label:"string"},{key:"percentage",label:"percentage"},{key:"list",label:"list"},{key:"number",label:"number"},{key:"boolean",label:"boolean"}],uhe=C("div")(({theme:e})=>({maxWidth:"400px",margin:e.spacing(2,0)})),dhe=C(mo)(({theme:e})=>({borderStyle:"dashed",margin:e.spacing(2,0,3,0),borderColor:e.palette.neutral.border})),phe=C("p")(({theme:e})=>({minWidth:"365px",width:"100%",marginBottom:e.spacing(2)})),fhe=C("div")(({theme:e})=>({display:"flex",alignItems:"center",marginBottom:e.spacing(2)})),hhe=C(_r)(({theme:e})=>({minWidth:"365px",width:"100%"})),mhe=C(du)(({theme:e})=>({minWidth:"365px",width:"100%",marginBottom:e.spacing(2)})),ghe=C(_r)(({theme:e})=>({minWidth:"365px",marginBottom:e.spacing(2)})),vhe=C(Tr)(({theme:e})=>({marginTop:e.spacing(-1)})),yhe=({set:e,input:t,index:n,params:r,setParams:o,errors:a})=>{const i=l=>{e({type:l})};return T(uhe,{children:[s(dhe,{}),s(X,{condition:n===0,show:T(phe,{children:["Parameters let you provide arguments to your strategy that it can access for evaluation. Read more in the"," ",s("a",{href:"https://docs.getunleash.io/reference/custom-activation-strategies#parameter-types",target:"_blank",rel:"noreferrer",children:"parameter types documentation"}),"."]})}),T(fhe,{children:[s(hhe,{autoFocus:!0,label:`Parameter name ${n+1}*`,onChange:l=>e({name:l.target.value}),value:t.name,error:Boolean(a==null?void 0:a[`paramName${n}`]),errorText:a==null?void 0:a[`paramName${n}`]}),s(_t,{title:"Remove parameter",arrow:!0,children:s(Yt,{onClick:()=>{o(r.filter((l,c)=>c!==n))},size:"large",children:s(Oo,{})})})]}),s(mhe,{label:"Type*",name:"type",options:che,value:t.type,onChange:i,id:`prop-type-${n}-select`}),s(ghe,{rows:2,multiline:!0,label:`Parameter name ${n+1} description`,onChange:({target:l})=>e({description:l.value}),value:t.description}),s(vhe,{control:s(Rs,{checked:Boolean(t.required),onChange:()=>e({required:!t.required})}),label:"Required"})]})},bhe=({input:e=[],updateParameter:t,setParams:n,errors:r})=>s("div",{style:{marginTop:"0.5rem"},children:e.map((o,a)=>s(yhe,{params:e,set:i=>t(a,i),index:a,input:e[a],setParams:n,errors:r},a))}),whe=C("form")(({theme:e})=>({display:"flex",flexDirection:"column",height:"100%"})),She=C("div")(({theme:e})=>({maxWidth:400})),x_=C("p")(({theme:e})=>({marginBottom:e.spacing(1)})),C_=C(_r)(({theme:e})=>({width:"100%",marginBottom:e.spacing(2)})),xhe=C(Ze)(({theme:e})=>({color:e.palette.primary.dark})),Che=C("div")(({theme:e})=>({marginTop:"auto",display:"flex",justifyContent:"flex-end"})),Ehe=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),GO=({children:e,handleSubmit:t,handleCancel:n,strategyName:r,strategyDesc:o,params:a,setParams:i,setStrategyName:l,validateStrategyName:c,setStrategyDesc:u,errors:d,mode:f,clearErrors:h})=>{const m=(g,v)=>{let b={...a[g]};a[g]=Object.assign({},b,v),i(w=>[...w])},y=()=>{i(g=>[...g,{name:"",type:"string",description:"",required:!1}])};return T(whe,{onSubmit:t,children:[T(She,{children:[s(x_,{children:"What would you like to call your strategy?"}),s(C_,{disabled:f==="Edit",autoFocus:!0,label:"Strategy name*",value:r,onChange:g=>l(Cs(g.target.value)),error:Boolean(d.name),errorText:d.name,onFocus:h,onBlur:c}),s(x_,{children:"What is your strategy description?"}),s(C_,{label:"Strategy description",value:o,onChange:g=>u(g.target.value),rows:2,multiline:!0}),s(bhe,{input:a,updateParameter:m,setParams:i,errors:d}),s(xhe,{onClick:g=>{g.preventDefault(),y()},variant:"outlined",color:"secondary",startIcon:s(Ta,{}),children:"Add parameter"})]}),T(Che,{children:[e,s(Ehe,{type:"button",onClick:n,children:"Cancel"})]})]})},The=()=>{const{setToastData:e,setToastApiError:t}=It(),{uiConfig:n}=Lt(),r=lt(),{strategyName:o,strategyDesc:a,params:i,setParams:l,setStrategyName:c,setStrategyDesc:u,getStrategyPayload:d,validateStrategyName:f,validateParams:h,clearErrors:m,setErrors:y,errors:g}=VO(),{createStrategy:v,loading:b}=dC(),{refetchStrategies:w}=pu();return s(Mr,{loading:b,title:"Create strategy type",description:`The strategy type and the parameters will be selectable when adding an activation strategy to a toggle in the environments.
|
|
325
|
+
The parameter defines the type of activation strategy. E.g. you can create a type 'Teams' and add a parameter 'List'. Then it's easy to add team names to the activation strategy`,documentationLink:"https://docs.getunleash.io/reference/custom-activation-strategies",documentationLinkLabel:"Custom strategies documentation",formatApiCode:()=>`curl --location --request POST '${n.unleashUrl}/api/admin/strategies' \\
|
|
326
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
327
|
+
--header 'Content-Type: application/json' \\
|
|
328
|
+
--data-raw '${JSON.stringify(d(),void 0,2)}'`,children:s(GO,{errors:g,handleSubmit:async k=>{if(m(),k.preventDefault(),f()&&h()){const $=d();try{await v($),w(),r(`/strategies/${o}`),e({title:"Strategy created",text:"Successfully created strategy",confetti:!0,type:"success"})}catch(L){t(ft(L))}}},handleCancel:()=>{r(jo)},strategyName:o,setStrategyName:c,validateStrategyName:f,strategyDesc:a,setStrategyDesc:u,params:i,setParams:l,mode:"Create",setErrors:y,clearErrors:m,children:s(mu,{name:"strategy",permission:Rm,children:"Create strategy"})})})},NC=e=>{const{data:t,error:n,mutate:r}=dn(e?Dt(`api/admin/strategies/${e}`):null,khe),o=p.useCallback(()=>{r().catch(console.warn)},[r]);return{strategyDefinition:t,refetchStrategy:o,loading:!n&&!t,error:n}},khe=e=>fetch(e).then(yn("Strategy")).then(t=>t.json()),Ahe=()=>{const{setToastData:e,setToastApiError:t}=It(),{uiConfig:n}=Lt(),r=lt(),o=dr("name"),{strategyDefinition:a}=NC(o),{strategyName:i,strategyDesc:l,params:c,setParams:u,setStrategyName:d,setStrategyDesc:f,getStrategyPayload:h,validateParams:m,clearErrors:y,setErrors:g,errors:v}=VO(a==null?void 0:a.name,a==null?void 0:a.description,a==null?void 0:a.parameters),{updateStrategy:b,loading:w}=dC(),{refetchStrategies:x}=pu();return s(Mr,{loading:w,title:"Edit strategy type",description:`The strategy type and the parameters will be selectable when adding an activation strategy to a toggle in the environments.
|
|
329
|
+
The parameter defines the type of activation strategy. E.g. you can create a type 'Teams' and add a parameter 'List'. Then it's easy to add team names to the activation strategy`,documentationLink:"https://docs.getunleash.io/reference/custom-activation-strategies",documentationLinkLabel:"Custom strategies documentation",formatApiCode:()=>`curl --location --request PUT '${n.unleashUrl}/api/admin/strategies/${o}' \\
|
|
330
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
331
|
+
--header 'Content-Type: application/json' \\
|
|
332
|
+
--data-raw '${JSON.stringify(h(),void 0,2)}'`,children:s(GO,{errors:v,handleSubmit:async _=>{if(y(),_.preventDefault(),m()){const $=h();try{await b($),r(`/strategies/${i}`),e({type:"success",title:"Success",text:"Successfully updated strategy"}),x()}catch(L){t(ft(L))}}},handleCancel:()=>{r(jo)},strategyName:i,setStrategyName:d,strategyDesc:l,setStrategyDesc:f,params:c,setParams:u,mode:"Edit",setErrors:g,clearErrors:y,children:s(Pl,{permission:mv})})})},_he=()=>{const{makeRequest:e,createRequest:t}=Nn({propagateErrors:!0});return{setSplashSeen:async r=>{const o=`api/admin/splash/${r}`,a=t(o,{method:"POST"});try{return await e(a.caller,a.id)}catch{console.log("An exception was caught and handled.")}}}},qO=()=>T(Zt,{severity:"warning",children:["Remember to update your Unleash client! New operators require new SDK versions. ",s(Rhe,{}),"."]}),Rhe=()=>s("a",{href:"https://docs.getunleash.io/reference/strategy-constraints#strategy-constraint-operators",target:"_blank",rel:"noreferrer",style:{color:"inherit"},children:"Read more"}),Phe=C("section")(({theme:e})=>({backgroundColor:e.palette.primary.light,minHeight:"100vh",padding:e.spacing(2),display:"grid",gap:e.spacing(2),alignItems:"center",alignContent:"center",justifyContent:"center",gridTemplateColumns:"minmax(0,auto)",fontWeight:e.fontWeight.thin})),Ihe=C("div")(({theme:e})=>({position:"relative",padding:e.spacing(4),borderRadius:e.spacing(1),backgroundColor:e.palette.primary.main,color:"white",[e.breakpoints.up("md")]:{padding:e.spacing(8)}})),$he=C("header")(({theme:e})=>({textAlign:"center"})),Ohe=C("h1")(({theme:e})=>({fontWeight:"inherit"})),Lhe=C(Yt)(({theme:e})=>({position:"absolute",top:0,right:0,color:"inherit"})),Nhe=C("p")(({theme:e})=>({maxWidth:e.spacing(64),margin:e.spacing(3,"auto",0,"auto")})),Mhe=C("div")(({theme:e})=>({margin:e.spacing(4,0),padding:e.spacing(4,0),borderTop:"1px solid",borderBottom:"1px solid",borderTopColor:e.palette.primary.light,borderBottomColor:e.palette.primary.light})),Dhe=C("ul")(({theme:e})=>({padding:e.spacing(2,0),[e.breakpoints.up("md")]:{padding:e.spacing(2,4)},"& li + li":{marginTop:e.spacing(.5)},"& strong":{padding:e.spacing(0,.5),fontSize:e.fontSizes.smallBody,fontWeight:"inherit",backgroundColor:"rgba(0, 0, 0, 0.2)"}})),Bhe=C("footer")(({theme:e})=>({display:"grid",gap:e.spacing(4),textAlign:"center",justifyItems:"center"})),Fhe=C("a")(({theme:e})=>({color:"inherit"})),zhe=()=>{const e=lt();return T(Phe,{children:[T(Ihe,{children:[T($he,{children:[s(Ohe,{children:"New strategy operators"}),s(Lhe,{onClick:()=>e("/"),size:"large",children:s(P4,{titleAccess:"Close"})}),s(Nhe,{children:"We've added some new feature strategy constraint operators. Fine-tune your feature targeting like never before."})]}),T(Mhe,{children:[s("p",{children:"For example:"}),T(Dhe,{children:[T("li",{children:[s("span",{children:"Toggle features at dates: "}),T("span",{children:[s("strong",{children:"DATE_BEFORE"})," ",s("strong",{children:"DATE_AFTER"})]})]}),T("li",{children:[s("span",{children:"Toggle features for versions: "}),T("span",{children:[s("strong",{children:"SEMVER_EQ"})," ",s("strong",{children:"SEMVER_GT"})," ",s("strong",{children:"SEMVER_LT"})]})]}),T("li",{children:[s("span",{children:"Toggle features for strings: "}),T("span",{children:[s("strong",{children:"STR_CONTAINS"})," ",s("strong",{children:"STR_ENDS_WITH"})," ",s("strong",{children:"STR_STARTS_WITH"})]})]}),T("li",{children:[s("span",{children:"Toggle features for numbers: "}),T("span",{children:[s("strong",{children:"NUM_GT"})," ",s("strong",{children:"NUM_GTE"})," ",s("strong",{children:"NUM_LT"})," ",s("strong",{children:"NUM_LTE"})]})]})]})]}),T(Bhe,{children:[T("p",{children:[T(Fhe,{href:"https://docs.getunleash.io/reference/strategy-constraints#numeric-operators",target:"_blank",rel:"noreferrer",children:["Read all about operators in our in-depth"," ",s("strong",{children:"docs"})]}),"."]}),s("p",{children:s(Ze,{sx:t=>({background:"white !important",color:t.palette.primary.main}),variant:"contained",component:ln,to:"/",children:"Fine, whatever, I have work to do!"})})]})]}),s(qO,{})]})},KO=()=>{const e=tf();return{splash:e.data&&"splash"in e.data?e.data.splash:void 0,refetchSplash:e.refetchAuth,loading:e.loading,error:e.error}},jhe=["operators"],Uhe=[],Whe=()=>{const e=dr("splashId"),t=Vhe(e),{refetchSplash:n}=KO(),{setSplashSeen:r}=_he();if(Hhe("Escape","/"),p.useEffect(()=>{e&&t&&r(e).then(()=>n()).catch(console.warn)},[e,t]),!t)return null;switch(e){case"operators":return s(zhe,{});default:return s(_l,{to:"/",replace:!0})}},Hhe=(e,t)=>{const n=lt();p.useEffect(()=>{const r=o=>{o.code===e&&n(t)};return window.addEventListener("keydown",r),()=>window.removeEventListener("keydown",r)},[e,t,n])},Vhe=e=>jhe.includes(e),YO=({onSubmit:e,onCancel:t,modal:n})=>{const{setToastData:r,setToastApiError:o}=It(),{uiConfig:a}=Lt(),{contextName:i,contextDesc:l,legalValues:c,stickiness:u,setContextName:d,setContextDesc:f,setLegalValues:h,setStickiness:m,getContextPayload:y,validateContext:g,clearErrors:v,setErrors:b,errors:w}=_O(),{createContext:x,loading:E}=$v(),{refetchUnleashContext:A}=Il();return s(Mr,{loading:E,title:"Create context",description:`Context fields are a basic building block used in Unleash to control roll-out.
|
|
333
|
+
They can be used together with strategy constraints as part of the activation strategy evaluation.`,documentationLink:"https://docs.getunleash.io/reference/unleash-context#custom-context-fields",documentationLinkLabel:"Context fields documentation",formatApiCode:()=>`curl --location --request POST '${a.unleashUrl}/api/admin/context' \\
|
|
334
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
335
|
+
--header 'Content-Type: application/json' \\
|
|
336
|
+
--data-raw '${JSON.stringify(y(),void 0,2)}'`,modal:n,children:s(AO,{errors:w,handleSubmit:async $=>{if($.preventDefault(),$.stopPropagation(),await g()){const O=y();try{await x(O),A(),r({title:"Context created",confetti:!0,type:"success"}),e()}catch(P){o(ft(P))}}},onCancel:t,contextName:i,setContextName:d,contextDesc:l,setContextDesc:f,legalValues:c,setLegalValues:h,stickiness:u,setStickiness:m,mode:"Create",validateContext:g,setErrors:b,clearErrors:v,children:s(mu,{name:"context",permission:Pm})})})},Ghe=()=>{const e=lt();return s(YO,{onSubmit:()=>e("/context"),onCancel:()=>e(jo)})},MC=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{createSegment:async c=>{const u=t(DC(),{method:"POST",body:JSON.stringify(c)});return e(u.caller,u.id)},deleteSegment:async c=>{const u=t(E_(c),{method:"DELETE"});return e(u.caller,u.id)},updateSegment:async(c,u)=>{const d=t(E_(c),{method:"PUT",body:JSON.stringify(u)});return e(d.caller,d.id)},setStrategySegments:async c=>{const u=t(qhe(),{method:"POST",body:JSON.stringify(c)});return e(u.caller,u.id)},errors:n,loading:r}},DC=()=>"api/admin/segments",E_=e=>`${DC()}/${e}`,qhe=()=>`${DC()}/strategies`,BC=e=>{const t=Boolean(e&&e.length===0),[n,r]=p.useState(t),{validateConstraint:o}=gu();return p.useEffect(()=>{if(!e)return;const a=e.map(i=>o(i));Promise.all(a).then(()=>r(!0)).catch(()=>r(!1))},[e]),n},$l=e=>{var l;const{uiConfig:t}=Lt(),n=Dt(e?`api/admin/segments/strategies/${e}`:"api/admin/segments"),{data:r,error:o,mutate:a}=Ev(Boolean((l=t.flags)==null?void 0:l.SE),[],n,()=>Khe(n),{refreshInterval:15*1e3}),i=p.useCallback(()=>{a().catch(console.warn)},[a]);return{segments:r,refetchSegments:i,loading:!o&&!r,error:o}},Khe=async e=>fetch(e).then(yn("Segments")).then(t=>t.json()).then(t=>t.segments),Yhe=(e,t)=>{const[n,r]=p.useState(),o=e!==t;return p.useEffect(()=>{r(void 0),e&&o&&Xhe(e).then(Jhe).then(r).catch(()=>r(void 0))},[e,o]),n},Xhe=e=>fetch(Dt("api/admin/segments/validate"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:e})}),Jhe=async e=>e.ok?void 0:(await e.json()).details[0].message,XO=(e="",t="",n=[])=>{const[r,o]=p.useState(e),[a,i]=p.useState(t),[l,c]=p.useState(n),[u,d]=p.useState({}),f=Yhe(r,e);return p.useEffect(()=>{o(e)},[e]),p.useEffect(()=>{i(t)},[t]),p.useEffect(()=>{c(n)},[JSON.stringify(n)]),p.useEffect(()=>{d(y=>({...y,name:f}))},[f]),{name:r,setName:o,description:a,setDescription:i,constraints:l,setConstraints:c,getSegmentPayload:()=>({name:r,description:a,constraints:l}),clearErrors:()=>{d({})},errors:u}},Qhe=C("div")(({theme:e})=>({display:"flex",flexDirection:"column",height:"100%"})),Zhe=C("div")(({theme:e})=>({maxWidth:"400px"})),T_=C("p")(({theme:e})=>({marginBottom:e.spacing(1)})),k_=C(_r)(({theme:e})=>({width:"100%",marginBottom:e.spacing(2)})),eme=C("div")(({theme:e})=>({marginTop:"auto",display:"flex",justifyContent:"flex-end"})),tme=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),nme=({children:e,name:t,description:n,setName:r,setDescription:o,errors:a,clearErrors:i,setCurrentStep:l})=>{const c=lt();return T(Qhe,{children:[T(Zhe,{children:[s(T_,{children:"What is the segment name?"}),s(k_,{label:"Segment name",value:t,onChange:u=>r(u.target.value),error:Boolean(a.name),errorText:a.name,autoFocus:!0,required:!0,"data-testid":fee}),s(T_,{children:"What is the segment description?"}),s(k_,{label:"Description (optional)",value:n,onChange:u=>o(u.target.value),error:Boolean(a.description),errorText:a.description,"data-testid":hee})]}),T(eme,{children:[s(Ze,{type:"button",variant:"contained",color:"primary",onClick:()=>l(2),disabled:t.length===0||Boolean(a.name),"data-testid":mee,children:"Next"}),s(tme,{type:"button",onClick:()=>{c("/segments")},children:"Cancel"})]})]})},A_=250,JO=C("div")({position:"absolute",top:0,right:0,bottom:0,height:"100vh",maxWidth:"98vw",overflow:"auto",boxShadow:"0 0 1rem rgba(0, 0, 0, 0.25)"}),rme=C(JO)({width:1300}),ome=C(Yt)(({theme:e})=>({zIndex:1,position:"absolute",top:e.spacing(3),right:e.spacing(3)})),QO=({open:e,onClose:t,label:n,children:r})=>s(Kp,{open:e,onClose:t,closeAfterTransition:!0,"aria-label":n,BackdropComponent:sx,BackdropProps:{timeout:A_},"data-testid":Iee,sx:{minHeight:"100vh"},children:s(ix,{timeout:A_,in:e,children:r})}),FC=e=>s(QO,{...e,children:s(rme,{children:e.children})}),__=e=>s(QO,{...e,children:T(JO,{children:[s(_t,{title:"Close",arrow:!0,describeChild:!0,children:s(ome,{onClick:e.onClose,children:s(fv,{})})}),e.children]})}),zC="NOT_IN",Mv="IN",jC="STR_ENDS_WITH",UC="STR_STARTS_WITH",WC="STR_CONTAINS",HC="NUM_EQ",VC="NUM_GT",GC="NUM_GTE",qC="NUM_LT",KC="NUM_LTE",Dv="DATE_AFTER",YC="DATE_BEFORE",XC="SEMVER_EQ",JC="SEMVER_GT",QC="SEMVER_LT",ame=[Mv,zC,WC,UC,jC,HC,VC,GC,qC,KC,YC,Dv,XC,JC,QC],xi=[WC,UC,jC],cl=[Mv,zC],Tc=[HC,VC,GC,qC,KC],Jo=[YC,Dv],kc=[XC,JC,QC],ZO=[...kc,...Jo,...Tc];[...xi,...cl];const ime=[...xi,...Jo,...ZO],wn=(e,t)=>e.some(n=>n===t),sme=C("div")(({theme:e})=>({padding:e.spacing(2),backgroundColor:e.palette.neutral.light})),lme=C("div")(({theme:e})=>({display:"flex",alignItems:"center",marginTop:e.spacing(2),borderTop:`1px solid ${e.palette.divider}`,width:"100%",padding:e.spacing(2)})),cme=C("div")({marginLeft:"auto"}),ume=C(Ze)(({theme:e})=>({marginRight:e.spacing(1),minWidth:"125px"})),dme=C(Ze)(({theme:e})=>({marginLeft:e.spacing(1),minWidth:"125px"})),pme=({localConstraint:e,children:t,triggerTransition:n,setAction:r,onSubmit:o})=>T(ke,{children:[T(sme,{children:[s(X,{condition:wn(ime,e.operator),show:s(qO,{})}),t]}),s(lme,{children:T(cme,{children:[s(ume,{type:"button",onClick:o,variant:"contained",color:"primary",children:"Save"}),s(dme,{onClick:()=>{r(TL),n()},children:"Cancel"})]})})]}),eL=({compact:e})=>s(Me,{sx:{backgroundColor:"primary.light",p:e?"1px":"2px",borderRadius:"50%",width:e?"18px":"24px",height:e?"18px":"24px",marginRight:"13px"},children:s(qZ,{sx:{fill:"white",display:"block",width:e?"16px":"20px",height:e?"16px":"20px"}})}),fme=(e,t)=>{const n=`To satisfy this constraint, values passed into the SDK as ${t} must`;if(e===Mv)return`${n} include:`;if(e===zC)return`${n} not include:`;if(e===jC)return`${n} end with:`;if(e===UC)return`${n} start with:`;if(e===WC)return`${n} contain:`;if(e===HC)return`${n} match:`;if(e===VC)return`${n} be greater than:`;if(e===GC)return`${n} be greater than or equal to:`;if(e===qC)return`${n} be less than:`;if(e===KC)return`${n} be less than or equal to:`;if(e===Dv)return`${n} be after the following date`;if(e===YC)return`${n} be before the following date:`;if(e===XC)return`${n} match the following version:`;if(e===JC)return`${n} be greater than the following version:`;if(e===QC)return`${n} be less than the following version:`},iw=e=>hme[e],hme={IN:"is one of",NOT_IN:"is not one of",STR_CONTAINS:"is a string that contains",STR_STARTS_WITH:"is a string that starts with",STR_ENDS_WITH:"is a string that ends with",NUM_EQ:"is a number equal to",NUM_GT:"is a number greater than",NUM_GTE:"is a number greater than or equal to",NUM_LT:"is a number less than",NUM_LTE:"is a number less than or equal to",DATE_BEFORE:"is a date before",DATE_AFTER:"is a date after",SEMVER_EQ:"is a SemVer equal to",SEMVER_GT:"is a SemVer greater than",SEMVER_LT:"is a SemVer less than"},mme=C("div")(({theme:e})=>({lineHeight:1.1,marginTop:-2,marginBottom:-10})),R_=C("div")(({theme:e})=>({fontSize:e.fontSizes.smallBody})),P_=C("div")(({theme:e})=>({fontSize:e.fontSizes.smallerBody,color:e.palette.neutral.main,overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"})),gme=C(Pi)(({theme:e})=>({[e.breakpoints.between(1101,1365)]:{width:"170px",marginRight:e.spacing(.5)}})),vme=C(bs,{shouldForwardProp:e=>e!=="separator"})(({theme:e,separator:t})=>t?{position:"relative",overflow:"visible",marginTop:e.spacing(2),"&:before":{content:'""',display:"block",position:"absolute",top:e.spacing(-1),left:0,right:0,borderTop:"1px solid",borderTopColor:e.palette.tertiary.contrast}}:{}),yme=C("div")(({theme:e})=>({lineHeight:1.2})),bme=({options:e,value:t,onChange:n})=>{const[r,o]=p.useState(!1);return T(gme,{variant:"outlined",size:"small",fullWidth:!0,children:[s(Yp,{htmlFor:"operator-select",children:"Operator"}),s(Xp,{id:"operator-select",name:"operator",label:"Operator",value:t,open:r,onOpen:()=>o(!0),onClose:()=>o(!1),onChange:l=>{n(l.target.value)},renderValue:()=>T(mme,{children:[s(R_,{children:t}),s(P_,{children:iw(t)})]}),children:e.map(l=>s(vme,{value:l,separator:wme(e,l),children:T(yme,{children:[s(R_,{children:l}),s(P_,{children:iw(l)})]})},l))})]})},wme=(e,t)=>t===e[0]?!1:Sme.some(n=>n[0]===t),Sme=[cl,xi,Tc,Jo,kc],_p="currentTime",tL=e=>ame.filter(t=>!(wn(Jo,t)&&e!==_p||!wn(Jo,t)&&e===_p)),sw=e=>p.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12.0033 3C10.6666 3 9.62387 4.15704 9.76236 5.48654L10.6238 13.7567C10.6974 14.4633 11.293 15 12.0033 15C12.7137 15 13.3093 14.4633 13.3829 13.7567L14.2443 5.48655C14.3828 4.15704 13.34 3 12.0033 3ZM12.0033 17C11.0368 17 10.2533 17.7835 10.2533 18.75C10.2533 19.7165 11.0368 20.5 12.0033 20.5C12.9698 20.5 13.7533 19.7165 13.7533 18.75C13.7533 17.7835 12.9698 17 12.0033 17Z"})),I_=e=>p.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M4.10831 2.60839C3.71687 2.23054 3.09322 2.23475 2.70696 2.62102C2.31643 3.01154 2.31643 3.64471 2.70696 4.03523L10.414 11.7423L10.6238 13.7566C10.6974 14.4631 11.293 14.9998 12.0033 14.9998C12.4551 14.9998 12.8605 14.7827 13.1147 14.4429L19.6775 21.0058C20.068 21.3963 20.7012 21.3963 21.0917 21.0058C21.478 20.6195 21.4822 19.9959 21.1044 19.6044C21.1001 19.6003 21.0958 19.5961 21.0916 19.5919L4.12102 2.62132C4.11674 2.61704 4.1125 2.61273 4.10831 2.60839ZM13.8264 9.4983L14.2443 5.4864C14.3828 4.15689 13.34 2.99985 12.0033 2.99985C10.6859 2.99985 9.65401 4.12375 9.7571 5.42898L13.8264 9.4983ZM12.0033 16.9998C11.0368 16.9998 10.2533 17.7834 10.2533 18.7498C10.2533 19.7163 11.0368 20.4998 12.0033 20.4998C12.9698 20.4998 13.7533 19.7163 13.7533 18.7498C13.7533 17.7834 12.9698 16.9998 12.0033 16.9998Z"})),nL=Nr(Yt)(({theme:e})=>({width:"28px",minWidth:"28px",maxWidth:"28px",height:"auto",backgroundColor:e.palette.tertiary.background,borderRadius:e.shape.borderRadius,padding:"0 1px 0",marginRight:"1rem","&:hover":{background:e.palette.tertiary.contrast[300]},[e.breakpoints.between(1101,1365)]:{marginRight:"0.5rem",alignItems:"center"}})),rL=Nr(Yt)(({theme:e})=>({width:"28px",minWidth:"28px",maxWidth:"28px",color:e.palette.primary.contrastText,backgroundColor:e.palette.primary.main,borderRadius:e.shape.borderRadius,marginRight:"1rem",padding:"0 1px 0","&:hover":{color:e.palette.primary.contrastText,backgroundColor:e.palette.primary.main},[e.breakpoints.between(1101,1365)]:{marginRight:"0.5rem",alignItems:"center"}})),lw=({darkmode:e,lightmode:t})=>{const{themeMode:n}=p.useContext(Ps);return s(X,{condition:n==="dark",show:e,elseShow:t})},xme=({localConstraint:e,setInvertedOperator:t})=>{const n=on();return s(_t,{title:Boolean(e.inverted)?"Remove negation":"Negate operator",arrow:!0,children:s(Me,{sx:{display:"flex",alignItems:"stretch"},children:s(X,{condition:Boolean(e.inverted),show:s(rL,{onClick:t,disableRipple:!0,children:s(lw,{darkmode:s(sw,{style:{fill:n.palette.background.paper}}),lightmode:s(sw,{})})}),elseShow:s(nL,{onClick:t,disableRipple:!0,children:s(lw,{darkmode:s(I_,{style:{fill:n.palette.background.paper}}),lightmode:s(I_,{})})})})})})},oL=e=>p.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("path",{d:"M5 18C5 18.55 5.45 19 6 19H18C18.55 19 19 18.55 19 18C19 17.45 18.55 17 18 17H6C5.45 17 5 17.45 5 18ZM9.5 12.8H14.5L15.16 14.4C15.31 14.76 15.66 15 16.05 15C16.74 15 17.2 14.29 16.93 13.66L13.05 4.69C12.87 4.27 12.46 4 12 4C11.54 4 11.13 4.27 10.95 4.69L7.07 13.66C6.8 14.29 7.27 15 7.96 15C8.35 15 8.7 14.76 8.85 14.4L9.5 12.8ZM12 5.98L13.87 11H10.13L12 5.98Z"})),Cme=e=>p.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M4.10831 2.60839C3.71687 2.23054 3.09322 2.23475 2.70696 2.62102C2.31643 3.01154 2.31643 3.64471 2.70696 4.03523L8.65871 9.98698L7.07 13.6598C6.8 14.2898 7.27 14.9998 7.96 14.9998C8.35 14.9998 8.7 14.7598 8.85 14.3998L9.5 12.7998H11.4716L15.6716 16.9998H6C5.45 16.9998 5 17.4498 5 17.9998C5 18.5498 5.45 18.9998 6 18.9998H17.6716L19.6775 21.0058C20.068 21.3963 20.7012 21.3963 21.0917 21.0058C21.478 20.6195 21.4822 19.9959 21.1044 19.6044C21.1001 19.6003 21.0958 19.5961 21.0916 19.5919L4.12102 2.62132C4.11674 2.61704 4.1125 2.61273 4.10831 2.60839ZM16.1235 11.7954L13.05 4.68985C12.87 4.26985 12.46 3.99985 12 3.99985C11.54 3.99985 11.13 4.26985 10.95 4.68985L10.3666 6.03851L11.5408 7.21265L12 5.97985L13.0045 8.67635L16.1235 11.7954Z"})),Eme=({localConstraint:e,setCaseInsensitive:t})=>s(_t,{title:Boolean(e.caseInsensitive)?"Make it case sensitive":"Make it case insensitive",arrow:!0,children:s(Me,{sx:{display:"flex",alignItems:"stretch"},children:s(X,{condition:Boolean(e.caseInsensitive),show:s(nL,{onClick:t,disableRipple:!0,children:s(Cme,{})}),elseShow:s(rL,{onClick:t,disableRipple:!0,children:s(oL,{})})})})}),Tme=C("div")(({theme:e})=>({marginLeft:"auto",whiteSpace:"nowrap",[e.breakpoints.down("sm")]:{display:"none"}})),aL=({onEdit:e,onDelete:t,disableDelete:n=!1,disableEdit:r=!1})=>{const o=e&&(i=>{i.stopPropagation(),e()}),a=t&&(i=>{i.stopPropagation(),t()});return T(Tme,{children:[s(X,{condition:Boolean(o)&&!r,show:s(_t,{title:"Edit constraint",arrow:!0,children:s(Yt,{type:"button",onClick:o,disabled:r,children:s(Za,{})})})}),s(X,{condition:Boolean(a)&&!n,show:s(_t,{title:"Delete constraint",arrow:!0,children:s(Yt,{type:"button",onClick:a,disabled:n,children:s(Oo,{})})})})]})},kme=C("div")(({theme:e})=>({display:"flex",alignItems:"center",width:"100%",[e.breakpoints.down("sm")]:{flexDirection:"column",alignItems:"center",position:"relative"}})),Ame=C("div")(({theme:e})=>({display:"flex",alignItems:"center",[e.breakpoints.down(770)]:{flexDirection:"column"}})),_me=C("div")(({theme:e})=>({[e.breakpoints.down(770)]:{marginTop:e.spacing(2)},display:"inline-flex"})),Rme=C("div")(({theme:e})=>({marginRight:e.spacing(2),width:"200px",[e.breakpoints.between(1101,1365)]:{width:"170px",marginRight:e.spacing(1)}})),Pme=C(du)(({theme:e})=>({marginRight:e.spacing(2),width:"200px",[e.breakpoints.between(1101,1365)]:{width:"170px",marginRight:e.spacing(1)}})),Ime=C("p")(({theme:e})=>({maxWidth:"400px",fontSize:e.fontSizes.smallBody,[e.breakpoints.down("xl")]:{display:"none"}})),$me=({compact:e,localConstraint:t,setLocalConstraint:n,setContextName:r,setOperator:o,onDelete:a,setInvertedOperator:i,setCaseInsensitive:l})=>{const{context:c}=Il(),{contextName:u,operator:d}=t,[f,h]=p.useState(!1),{uiConfig:m}=Lt(),y=Boolean(m.flags.caseInsensitiveInOperators);if(p.useEffect(()=>{u===_p&&!wn(Jo,d)?n(b=>({...b,operator:Dv,value:new Date().toISOString()})):u!==_p&&wn(Jo,d)&&o(Mv),wn(xi,d)||wn(cl,d)&&y?h(!0):h(!1)},[u,o,d,n,y]),!c)return null;const g=c.map(b=>({key:b.name,label:b.name})),v=b=>{wn(xi,b)||wn(cl,b)&&y?h(!0):h(!1),wn(Jo,b)?n(w=>({...w,operator:b,value:new Date().toISOString()})):o(b)};return T(kme,{children:[s(eL,{}),T(Ame,{children:[s("div",{children:s(Pme,{id:"context-field-select",name:"contextName",label:"Context Field",autoFocus:!0,options:g,value:u||"",onChange:r})}),T(_me,{children:[s(xme,{localConstraint:t,setInvertedOperator:i}),s(Rme,{children:s(bme,{options:tL(u),value:d,onChange:v})}),s(X,{condition:f,show:s(Eme,{localConstraint:t,setCaseInsensitive:l})})]})]}),s(X,{condition:!e,show:s(Ime,{children:fme(d,u)})}),s(aL,{onDelete:a,disableEdit:!0})]})},$_=e=>Ko(e,t=>{wn(ZO,e.operator)?delete t.values:delete t.value});var Ai={},Ome={get exports(){return Ai},set exports(e){Ai=e}};const Lme="2.0.0",Nme=256,Mme=Number.MAX_SAFE_INTEGER||9007199254740991,Dme=16;var Bv={SEMVER_SPEC_VERSION:Lme,MAX_LENGTH:Nme,MAX_SAFE_INTEGER:Mme,MAX_SAFE_COMPONENT_LENGTH:Dme};const Bme=typeof process=="object"&&process.env&&{}.NODE_DEBUG&&/\bsemver\b/i.test({}.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};var Fv=Bme;(function(e,t){const{MAX_SAFE_COMPONENT_LENGTH:n}=Bv,r=Fv;t=e.exports={};const o=t.re=[],a=t.src=[],i=t.t={};let l=0;const c=(u,d,f)=>{const h=l++;r(u,h,d),i[u]=h,a[h]=d,o[h]=new RegExp(d,f?"g":void 0)};c("NUMERICIDENTIFIER","0|[1-9]\\d*"),c("NUMERICIDENTIFIERLOOSE","[0-9]+"),c("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*"),c("MAINVERSION",`(${a[i.NUMERICIDENTIFIER]})\\.(${a[i.NUMERICIDENTIFIER]})\\.(${a[i.NUMERICIDENTIFIER]})`),c("MAINVERSIONLOOSE",`(${a[i.NUMERICIDENTIFIERLOOSE]})\\.(${a[i.NUMERICIDENTIFIERLOOSE]})\\.(${a[i.NUMERICIDENTIFIERLOOSE]})`),c("PRERELEASEIDENTIFIER",`(?:${a[i.NUMERICIDENTIFIER]}|${a[i.NONNUMERICIDENTIFIER]})`),c("PRERELEASEIDENTIFIERLOOSE",`(?:${a[i.NUMERICIDENTIFIERLOOSE]}|${a[i.NONNUMERICIDENTIFIER]})`),c("PRERELEASE",`(?:-(${a[i.PRERELEASEIDENTIFIER]}(?:\\.${a[i.PRERELEASEIDENTIFIER]})*))`),c("PRERELEASELOOSE",`(?:-?(${a[i.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${a[i.PRERELEASEIDENTIFIERLOOSE]})*))`),c("BUILDIDENTIFIER","[0-9A-Za-z-]+"),c("BUILD",`(?:\\+(${a[i.BUILDIDENTIFIER]}(?:\\.${a[i.BUILDIDENTIFIER]})*))`),c("FULLPLAIN",`v?${a[i.MAINVERSION]}${a[i.PRERELEASE]}?${a[i.BUILD]}?`),c("FULL",`^${a[i.FULLPLAIN]}$`),c("LOOSEPLAIN",`[v=\\s]*${a[i.MAINVERSIONLOOSE]}${a[i.PRERELEASELOOSE]}?${a[i.BUILD]}?`),c("LOOSE",`^${a[i.LOOSEPLAIN]}$`),c("GTLT","((?:<|>)?=?)"),c("XRANGEIDENTIFIERLOOSE",`${a[i.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),c("XRANGEIDENTIFIER",`${a[i.NUMERICIDENTIFIER]}|x|X|\\*`),c("XRANGEPLAIN",`[v=\\s]*(${a[i.XRANGEIDENTIFIER]})(?:\\.(${a[i.XRANGEIDENTIFIER]})(?:\\.(${a[i.XRANGEIDENTIFIER]})(?:${a[i.PRERELEASE]})?${a[i.BUILD]}?)?)?`),c("XRANGEPLAINLOOSE",`[v=\\s]*(${a[i.XRANGEIDENTIFIERLOOSE]})(?:\\.(${a[i.XRANGEIDENTIFIERLOOSE]})(?:\\.(${a[i.XRANGEIDENTIFIERLOOSE]})(?:${a[i.PRERELEASELOOSE]})?${a[i.BUILD]}?)?)?`),c("XRANGE",`^${a[i.GTLT]}\\s*${a[i.XRANGEPLAIN]}$`),c("XRANGELOOSE",`^${a[i.GTLT]}\\s*${a[i.XRANGEPLAINLOOSE]}$`),c("COERCE",`(^|[^\\d])(\\d{1,${n}})(?:\\.(\\d{1,${n}}))?(?:\\.(\\d{1,${n}}))?(?:$|[^\\d])`),c("COERCERTL",a[i.COERCE],!0),c("LONETILDE","(?:~>?)"),c("TILDETRIM",`(\\s*)${a[i.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",c("TILDE",`^${a[i.LONETILDE]}${a[i.XRANGEPLAIN]}$`),c("TILDELOOSE",`^${a[i.LONETILDE]}${a[i.XRANGEPLAINLOOSE]}$`),c("LONECARET","(?:\\^)"),c("CARETTRIM",`(\\s*)${a[i.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",c("CARET",`^${a[i.LONECARET]}${a[i.XRANGEPLAIN]}$`),c("CARETLOOSE",`^${a[i.LONECARET]}${a[i.XRANGEPLAINLOOSE]}$`),c("COMPARATORLOOSE",`^${a[i.GTLT]}\\s*(${a[i.LOOSEPLAIN]})$|^$`),c("COMPARATOR",`^${a[i.GTLT]}\\s*(${a[i.FULLPLAIN]})$|^$`),c("COMPARATORTRIM",`(\\s*)${a[i.GTLT]}\\s*(${a[i.LOOSEPLAIN]}|${a[i.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",c("HYPHENRANGE",`^\\s*(${a[i.XRANGEPLAIN]})\\s+-\\s+(${a[i.XRANGEPLAIN]})\\s*$`),c("HYPHENRANGELOOSE",`^\\s*(${a[i.XRANGEPLAINLOOSE]})\\s+-\\s+(${a[i.XRANGEPLAINLOOSE]})\\s*$`),c("STAR","(<|>)?=?\\s*\\*"),c("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),c("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")})(Ome,Ai);const Fme=["includePrerelease","loose","rtl"],zme=e=>e?typeof e!="object"?{loose:!0}:Fme.filter(t=>e[t]).reduce((t,n)=>(t[n]=!0,t),{}):{};var zv=zme;const O_=/^[0-9]+$/,iL=(e,t)=>{const n=O_.test(e),r=O_.test(t);return n&&r&&(e=+e,t=+t),e===t?0:n&&!r?-1:r&&!n?1:e<t?-1:1},jme=(e,t)=>iL(t,e);var sL={compareIdentifiers:iL,rcompareIdentifiers:jme};const sh=Fv,{MAX_LENGTH:L_,MAX_SAFE_INTEGER:lh}=Bv,{re:N_,t:M_}=Ai,Ume=zv,{compareIdentifiers:ql}=sL;let Wme=class Pa{constructor(t,n){if(n=Ume(n),t instanceof Pa){if(t.loose===!!n.loose&&t.includePrerelease===!!n.includePrerelease)return t;t=t.version}else if(typeof t!="string")throw new TypeError(`Invalid Version: ${t}`);if(t.length>L_)throw new TypeError(`version is longer than ${L_} characters`);sh("SemVer",t,n),this.options=n,this.loose=!!n.loose,this.includePrerelease=!!n.includePrerelease;const r=t.trim().match(n.loose?N_[M_.LOOSE]:N_[M_.FULL]);if(!r)throw new TypeError(`Invalid Version: ${t}`);if(this.raw=t,this.major=+r[1],this.minor=+r[2],this.patch=+r[3],this.major>lh||this.major<0)throw new TypeError("Invalid major version");if(this.minor>lh||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>lh||this.patch<0)throw new TypeError("Invalid patch version");r[4]?this.prerelease=r[4].split(".").map(o=>{if(/^[0-9]+$/.test(o)){const a=+o;if(a>=0&&a<lh)return a}return o}):this.prerelease=[],this.build=r[5]?r[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(t){if(sh("SemVer.compare",this.version,this.options,t),!(t instanceof Pa)){if(typeof t=="string"&&t===this.version)return 0;t=new Pa(t,this.options)}return t.version===this.version?0:this.compareMain(t)||this.comparePre(t)}compareMain(t){return t instanceof Pa||(t=new Pa(t,this.options)),ql(this.major,t.major)||ql(this.minor,t.minor)||ql(this.patch,t.patch)}comparePre(t){if(t instanceof Pa||(t=new Pa(t,this.options)),this.prerelease.length&&!t.prerelease.length)return-1;if(!this.prerelease.length&&t.prerelease.length)return 1;if(!this.prerelease.length&&!t.prerelease.length)return 0;let n=0;do{const r=this.prerelease[n],o=t.prerelease[n];if(sh("prerelease compare",n,r,o),r===void 0&&o===void 0)return 0;if(o===void 0)return 1;if(r===void 0)return-1;if(r===o)continue;return ql(r,o)}while(++n)}compareBuild(t){t instanceof Pa||(t=new Pa(t,this.options));let n=0;do{const r=this.build[n],o=t.build[n];if(sh("prerelease compare",n,r,o),r===void 0&&o===void 0)return 0;if(o===void 0)return 1;if(r===void 0)return-1;if(r===o)continue;return ql(r,o)}while(++n)}inc(t,n){switch(t){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",n);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",n);break;case"prepatch":this.prerelease.length=0,this.inc("patch",n),this.inc("pre",n);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",n),this.inc("pre",n);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let r=this.prerelease.length;for(;--r>=0;)typeof this.prerelease[r]=="number"&&(this.prerelease[r]++,r=-2);r===-1&&this.prerelease.push(0)}n&&(ql(this.prerelease[0],n)===0?isNaN(this.prerelease[1])&&(this.prerelease=[n,0]):this.prerelease=[n,0]);break;default:throw new Error(`invalid increment argument: ${t}`)}return this.format(),this.raw=this.version,this}};var no=Wme;const{MAX_LENGTH:Hme}=Bv,{re:D_,t:B_}=Ai,F_=no,Vme=zv,Gme=(e,t)=>{if(t=Vme(t),e instanceof F_)return e;if(typeof e!="string"||e.length>Hme||!(t.loose?D_[B_.LOOSE]:D_[B_.FULL]).test(e))return null;try{return new F_(e,t)}catch{return null}};var yu=Gme;const qme=yu,Kme=(e,t)=>{const n=qme(e,t);return n?n.version:null};var Yme=Kme;const Xme=yu,Jme=(e,t)=>{const n=Xme(e.trim().replace(/^[=v]+/,""),t);return n?n.version:null};var Qme=Jme;const z_=no,Zme=(e,t,n,r)=>{typeof n=="string"&&(r=n,n=void 0);try{return new z_(e instanceof z_?e.version:e,n).inc(t,r).version}catch{return null}};var ege=Zme;const j_=no,tge=(e,t,n)=>new j_(e,n).compare(new j_(t,n));var _a=tge;const nge=_a,rge=(e,t,n)=>nge(e,t,n)===0;var ZC=rge;const U_=yu,oge=ZC,age=(e,t)=>{if(oge(e,t))return null;{const n=U_(e),r=U_(t),o=n.prerelease.length||r.prerelease.length,a=o?"pre":"",i=o?"prerelease":"";for(const l in n)if((l==="major"||l==="minor"||l==="patch")&&n[l]!==r[l])return a+l;return i}};var ige=age;const sge=no,lge=(e,t)=>new sge(e,t).major;var cge=lge;const uge=no,dge=(e,t)=>new uge(e,t).minor;var pge=dge;const fge=no,hge=(e,t)=>new fge(e,t).patch;var mge=hge;const gge=yu,vge=(e,t)=>{const n=gge(e,t);return n&&n.prerelease.length?n.prerelease:null};var yge=vge;const bge=_a,wge=(e,t,n)=>bge(t,e,n);var Sge=wge;const xge=_a,Cge=(e,t)=>xge(e,t,!0);var Ege=Cge;const W_=no,Tge=(e,t,n)=>{const r=new W_(e,n),o=new W_(t,n);return r.compare(o)||r.compareBuild(o)};var e2=Tge;const kge=e2,Age=(e,t)=>e.sort((n,r)=>kge(n,r,t));var _ge=Age;const Rge=e2,Pge=(e,t)=>e.sort((n,r)=>Rge(r,n,t));var Ige=Pge;const $ge=_a,Oge=(e,t,n)=>$ge(e,t,n)>0;var jv=Oge;const Lge=_a,Nge=(e,t,n)=>Lge(e,t,n)<0;var t2=Nge;const Mge=_a,Dge=(e,t,n)=>Mge(e,t,n)!==0;var lL=Dge;const Bge=_a,Fge=(e,t,n)=>Bge(e,t,n)>=0;var n2=Fge;const zge=_a,jge=(e,t,n)=>zge(e,t,n)<=0;var r2=jge;const Uge=ZC,Wge=lL,Hge=jv,Vge=n2,Gge=t2,qge=r2,Kge=(e,t,n,r)=>{switch(t){case"===":return typeof e=="object"&&(e=e.version),typeof n=="object"&&(n=n.version),e===n;case"!==":return typeof e=="object"&&(e=e.version),typeof n=="object"&&(n=n.version),e!==n;case"":case"=":case"==":return Uge(e,n,r);case"!=":return Wge(e,n,r);case">":return Hge(e,n,r);case">=":return Vge(e,n,r);case"<":return Gge(e,n,r);case"<=":return qge(e,n,r);default:throw new TypeError(`Invalid operator: ${t}`)}};var cL=Kge;const Yge=no,Xge=yu,{re:ch,t:uh}=Ai,Jge=(e,t)=>{if(e instanceof Yge)return e;if(typeof e=="number"&&(e=String(e)),typeof e!="string")return null;t=t||{};let n=null;if(!t.rtl)n=e.match(ch[uh.COERCE]);else{let r;for(;(r=ch[uh.COERCERTL].exec(e))&&(!n||n.index+n[0].length!==e.length);)(!n||r.index+r[0].length!==n.index+n[0].length)&&(n=r),ch[uh.COERCERTL].lastIndex=r.index+r[1].length+r[2].length;ch[uh.COERCERTL].lastIndex=-1}return n===null?null:Xge(`${n[2]}.${n[3]||"0"}.${n[4]||"0"}`,t)};var Qge=Jge,z1,H_;function Zge(){return H_||(H_=1,z1=function(e){e.prototype[Symbol.iterator]=function*(){for(let t=this.head;t;t=t.next)yield t.value}}),z1}var eve=nn;nn.Node=Sl;nn.create=nn;function nn(e){var t=this;if(t instanceof nn||(t=new nn),t.tail=null,t.head=null,t.length=0,e&&typeof e.forEach=="function")e.forEach(function(o){t.push(o)});else if(arguments.length>0)for(var n=0,r=arguments.length;n<r;n++)t.push(arguments[n]);return t}nn.prototype.removeNode=function(e){if(e.list!==this)throw new Error("removing node which does not belong to this list");var t=e.next,n=e.prev;return t&&(t.prev=n),n&&(n.next=t),e===this.head&&(this.head=t),e===this.tail&&(this.tail=n),e.list.length--,e.next=null,e.prev=null,e.list=null,t};nn.prototype.unshiftNode=function(e){if(e!==this.head){e.list&&e.list.removeNode(e);var t=this.head;e.list=this,e.next=t,t&&(t.prev=e),this.head=e,this.tail||(this.tail=e),this.length++}};nn.prototype.pushNode=function(e){if(e!==this.tail){e.list&&e.list.removeNode(e);var t=this.tail;e.list=this,e.prev=t,t&&(t.next=e),this.tail=e,this.head||(this.head=e),this.length++}};nn.prototype.push=function(){for(var e=0,t=arguments.length;e<t;e++)nve(this,arguments[e]);return this.length};nn.prototype.unshift=function(){for(var e=0,t=arguments.length;e<t;e++)rve(this,arguments[e]);return this.length};nn.prototype.pop=function(){if(this.tail){var e=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,e}};nn.prototype.shift=function(){if(this.head){var e=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,e}};nn.prototype.forEach=function(e,t){t=t||this;for(var n=this.head,r=0;n!==null;r++)e.call(t,n.value,r,this),n=n.next};nn.prototype.forEachReverse=function(e,t){t=t||this;for(var n=this.tail,r=this.length-1;n!==null;r--)e.call(t,n.value,r,this),n=n.prev};nn.prototype.get=function(e){for(var t=0,n=this.head;n!==null&&t<e;t++)n=n.next;if(t===e&&n!==null)return n.value};nn.prototype.getReverse=function(e){for(var t=0,n=this.tail;n!==null&&t<e;t++)n=n.prev;if(t===e&&n!==null)return n.value};nn.prototype.map=function(e,t){t=t||this;for(var n=new nn,r=this.head;r!==null;)n.push(e.call(t,r.value,this)),r=r.next;return n};nn.prototype.mapReverse=function(e,t){t=t||this;for(var n=new nn,r=this.tail;r!==null;)n.push(e.call(t,r.value,this)),r=r.prev;return n};nn.prototype.reduce=function(e,t){var n,r=this.head;if(arguments.length>1)n=t;else if(this.head)r=this.head.next,n=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var o=0;r!==null;o++)n=e(n,r.value,o),r=r.next;return n};nn.prototype.reduceReverse=function(e,t){var n,r=this.tail;if(arguments.length>1)n=t;else if(this.tail)r=this.tail.prev,n=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var o=this.length-1;r!==null;o--)n=e(n,r.value,o),r=r.prev;return n};nn.prototype.toArray=function(){for(var e=new Array(this.length),t=0,n=this.head;n!==null;t++)e[t]=n.value,n=n.next;return e};nn.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,n=this.tail;n!==null;t++)e[t]=n.value,n=n.prev;return e};nn.prototype.slice=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var n=new nn;if(t<e||t<0)return n;e<0&&(e=0),t>this.length&&(t=this.length);for(var r=0,o=this.head;o!==null&&r<e;r++)o=o.next;for(;o!==null&&r<t;r++,o=o.next)n.push(o.value);return n};nn.prototype.sliceReverse=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var n=new nn;if(t<e||t<0)return n;e<0&&(e=0),t>this.length&&(t=this.length);for(var r=this.length,o=this.tail;o!==null&&r>t;r--)o=o.prev;for(;o!==null&&r>e;r--,o=o.prev)n.push(o.value);return n};nn.prototype.splice=function(e,t,...n){e>this.length&&(e=this.length-1),e<0&&(e=this.length+e);for(var r=0,o=this.head;o!==null&&r<e;r++)o=o.next;for(var a=[],r=0;o&&r<t;r++)a.push(o.value),o=this.removeNode(o);o===null&&(o=this.tail),o!==this.head&&o!==this.tail&&(o=o.prev);for(var r=0;r<n.length;r++)o=tve(this,o,n[r]);return a};nn.prototype.reverse=function(){for(var e=this.head,t=this.tail,n=e;n!==null;n=n.prev){var r=n.prev;n.prev=n.next,n.next=r}return this.head=t,this.tail=e,this};function tve(e,t,n){var r=t===e.head?new Sl(n,null,t,e):new Sl(n,t,t.next,e);return r.next===null&&(e.tail=r),r.prev===null&&(e.head=r),e.length++,r}function nve(e,t){e.tail=new Sl(t,e.tail,null,e),e.head||(e.head=e.tail),e.length++}function rve(e,t){e.head=new Sl(t,null,e.head,e),e.tail||(e.tail=e.head),e.length++}function Sl(e,t,n,r){if(!(this instanceof Sl))return new Sl(e,t,n,r);this.list=r,this.value=e,t?(t.next=this,this.prev=t):this.prev=null,n?(n.prev=this,this.next=n):this.next=null}try{Zge()(nn)}catch{}const ove=eve,Xs=Symbol("max"),hi=Symbol("length"),Kl=Symbol("lengthCalculator"),Fd=Symbol("allowStale"),al=Symbol("maxAge"),pi=Symbol("dispose"),V_=Symbol("noDisposeOnSet"),Er=Symbol("lruList"),ha=Symbol("cache"),uL=Symbol("updateAgeOnGet"),j1=()=>1;class ave{constructor(t){if(typeof t=="number"&&(t={max:t}),t||(t={}),t.max&&(typeof t.max!="number"||t.max<0))throw new TypeError("max must be a non-negative number");this[Xs]=t.max||1/0;const n=t.length||j1;if(this[Kl]=typeof n!="function"?j1:n,this[Fd]=t.stale||!1,t.maxAge&&typeof t.maxAge!="number")throw new TypeError("maxAge must be a number");this[al]=t.maxAge||0,this[pi]=t.dispose,this[V_]=t.noDisposeOnSet||!1,this[uL]=t.updateAgeOnGet||!1,this.reset()}set max(t){if(typeof t!="number"||t<0)throw new TypeError("max must be a non-negative number");this[Xs]=t||1/0,rd(this)}get max(){return this[Xs]}set allowStale(t){this[Fd]=!!t}get allowStale(){return this[Fd]}set maxAge(t){if(typeof t!="number")throw new TypeError("maxAge must be a non-negative number");this[al]=t,rd(this)}get maxAge(){return this[al]}set lengthCalculator(t){typeof t!="function"&&(t=j1),t!==this[Kl]&&(this[Kl]=t,this[hi]=0,this[Er].forEach(n=>{n.length=this[Kl](n.value,n.key),this[hi]+=n.length})),rd(this)}get lengthCalculator(){return this[Kl]}get length(){return this[hi]}get itemCount(){return this[Er].length}rforEach(t,n){n=n||this;for(let r=this[Er].tail;r!==null;){const o=r.prev;G_(this,t,r,n),r=o}}forEach(t,n){n=n||this;for(let r=this[Er].head;r!==null;){const o=r.next;G_(this,t,r,n),r=o}}keys(){return this[Er].toArray().map(t=>t.key)}values(){return this[Er].toArray().map(t=>t.value)}reset(){this[pi]&&this[Er]&&this[Er].length&&this[Er].forEach(t=>this[pi](t.key,t.value)),this[ha]=new Map,this[Er]=new ove,this[hi]=0}dump(){return this[Er].map(t=>qm(this,t)?!1:{k:t.key,v:t.value,e:t.now+(t.maxAge||0)}).toArray().filter(t=>t)}dumpLru(){return this[Er]}set(t,n,r){if(r=r||this[al],r&&typeof r!="number")throw new TypeError("maxAge must be a number");const o=r?Date.now():0,a=this[Kl](n,t);if(this[ha].has(t)){if(a>this[Xs])return Ac(this,this[ha].get(t)),!1;const c=this[ha].get(t).value;return this[pi]&&(this[V_]||this[pi](t,c.value)),c.now=o,c.maxAge=r,c.value=n,this[hi]+=a-c.length,c.length=a,this.get(t),rd(this),!0}const i=new ive(t,n,a,o,r);return i.length>this[Xs]?(this[pi]&&this[pi](t,n),!1):(this[hi]+=i.length,this[Er].unshift(i),this[ha].set(t,this[Er].head),rd(this),!0)}has(t){if(!this[ha].has(t))return!1;const n=this[ha].get(t).value;return!qm(this,n)}get(t){return U1(this,t,!0)}peek(t){return U1(this,t,!1)}pop(){const t=this[Er].tail;return t?(Ac(this,t),t.value):null}del(t){Ac(this,this[ha].get(t))}load(t){this.reset();const n=Date.now();for(let r=t.length-1;r>=0;r--){const o=t[r],a=o.e||0;if(a===0)this.set(o.k,o.v);else{const i=a-n;i>0&&this.set(o.k,o.v,i)}}}prune(){this[ha].forEach((t,n)=>U1(this,n,!1))}}const U1=(e,t,n)=>{const r=e[ha].get(t);if(r){const o=r.value;if(qm(e,o)){if(Ac(e,r),!e[Fd])return}else n&&(e[uL]&&(r.value.now=Date.now()),e[Er].unshiftNode(r));return o.value}},qm=(e,t)=>{if(!t||!t.maxAge&&!e[al])return!1;const n=Date.now()-t.now;return t.maxAge?n>t.maxAge:e[al]&&n>e[al]},rd=e=>{if(e[hi]>e[Xs])for(let t=e[Er].tail;e[hi]>e[Xs]&&t!==null;){const n=t.prev;Ac(e,t),t=n}},Ac=(e,t)=>{if(t){const n=t.value;e[pi]&&e[pi](n.key,n.value),e[hi]-=n.length,e[ha].delete(n.key),e[Er].removeNode(t)}};class ive{constructor(t,n,r,o,a){this.key=t,this.value=n,this.length=r,this.now=o,this.maxAge=a||0}}const G_=(e,t,n,r)=>{let o=n.value;qm(e,o)&&(Ac(e,n),e[Fd]||(o=void 0)),o&&t.call(r,o.value,o.key,e)};var sve=ave,W1,q_;function Ra(){if(q_)return W1;q_=1;class e{constructor(D,F){if(F=r(F),D instanceof e)return D.loose===!!F.loose&&D.includePrerelease===!!F.includePrerelease?D:new e(D.raw,F);if(D instanceof o)return this.raw=D.value,this.set=[[D]],this.format(),this;if(this.options=F,this.loose=!!F.loose,this.includePrerelease=!!F.includePrerelease,this.raw=D,this.set=D.split("||").map(U=>this.parseRange(U.trim())).filter(U=>U.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${D}`);if(this.set.length>1){const U=this.set[0];if(this.set=this.set.filter(Y=>!h(Y[0])),this.set.length===0)this.set=[U];else if(this.set.length>1){for(const Y of this.set)if(Y.length===1&&m(Y[0])){this.set=[Y];break}}}this.format()}format(){return this.range=this.set.map(D=>D.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(D){D=D.trim();const U=`parseRange:${Object.keys(this.options).join(",")}:${D}`,Y=n.get(U);if(Y)return Y;const V=this.options.loose,te=V?l[c.HYPHENRANGELOOSE]:l[c.HYPHENRANGE];D=D.replace(te,L(this.options.includePrerelease)),a("hyphen replace",D),D=D.replace(l[c.COMPARATORTRIM],u),a("comparator trim",D),D=D.replace(l[c.TILDETRIM],d),D=D.replace(l[c.CARETTRIM],f),D=D.split(/\s+/).join(" ");let Z=D.split(" ").map(M=>g(M,this.options)).join(" ").split(/\s+/).map(M=>$(M,this.options));V&&(Z=Z.filter(M=>(a("loose invalid filter",M,this.options),!!M.match(l[c.COMPARATORLOOSE])))),a("range list",Z);const W=new Map,z=Z.map(M=>new o(M,this.options));for(const M of z){if(h(M))return[M];W.set(M.value,M)}W.size>1&&W.has("")&&W.delete("");const R=[...W.values()];return n.set(U,R),R}intersects(D,F){if(!(D instanceof e))throw new TypeError("a Range is required");return this.set.some(U=>y(U,F)&&D.set.some(Y=>y(Y,F)&&U.every(V=>Y.every(te=>V.intersects(te,F)))))}test(D){if(!D)return!1;if(typeof D=="string")try{D=new i(D,this.options)}catch{return!1}for(let F=0;F<this.set.length;F++)if(O(this.set[F],D,this.options))return!0;return!1}}W1=e;const t=sve,n=new t({max:1e3}),r=zv,o=Uv(),a=Fv,i=no,{re:l,t:c,comparatorTrimReplace:u,tildeTrimReplace:d,caretTrimReplace:f}=Ai,h=P=>P.value==="<0.0.0-0",m=P=>P.value==="",y=(P,D)=>{let F=!0;const U=P.slice();let Y=U.pop();for(;F&&U.length;)F=U.every(V=>Y.intersects(V,D)),Y=U.pop();return F},g=(P,D)=>(a("comp",P,D),P=x(P,D),a("caret",P),P=b(P,D),a("tildes",P),P=A(P,D),a("xrange",P),P=_(P,D),a("stars",P),P),v=P=>!P||P.toLowerCase()==="x"||P==="*",b=(P,D)=>P.trim().split(/\s+/).map(F=>w(F,D)).join(" "),w=(P,D)=>{const F=D.loose?l[c.TILDELOOSE]:l[c.TILDE];return P.replace(F,(U,Y,V,te,Z)=>{a("tilde",P,U,Y,V,te,Z);let W;return v(Y)?W="":v(V)?W=`>=${Y}.0.0 <${+Y+1}.0.0-0`:v(te)?W=`>=${Y}.${V}.0 <${Y}.${+V+1}.0-0`:Z?(a("replaceTilde pr",Z),W=`>=${Y}.${V}.${te}-${Z} <${Y}.${+V+1}.0-0`):W=`>=${Y}.${V}.${te} <${Y}.${+V+1}.0-0`,a("tilde return",W),W})},x=(P,D)=>P.trim().split(/\s+/).map(F=>E(F,D)).join(" "),E=(P,D)=>{a("caret",P,D);const F=D.loose?l[c.CARETLOOSE]:l[c.CARET],U=D.includePrerelease?"-0":"";return P.replace(F,(Y,V,te,Z,W)=>{a("caret",P,Y,V,te,Z,W);let z;return v(V)?z="":v(te)?z=`>=${V}.0.0${U} <${+V+1}.0.0-0`:v(Z)?V==="0"?z=`>=${V}.${te}.0${U} <${V}.${+te+1}.0-0`:z=`>=${V}.${te}.0${U} <${+V+1}.0.0-0`:W?(a("replaceCaret pr",W),V==="0"?te==="0"?z=`>=${V}.${te}.${Z}-${W} <${V}.${te}.${+Z+1}-0`:z=`>=${V}.${te}.${Z}-${W} <${V}.${+te+1}.0-0`:z=`>=${V}.${te}.${Z}-${W} <${+V+1}.0.0-0`):(a("no pr"),V==="0"?te==="0"?z=`>=${V}.${te}.${Z}${U} <${V}.${te}.${+Z+1}-0`:z=`>=${V}.${te}.${Z}${U} <${V}.${+te+1}.0-0`:z=`>=${V}.${te}.${Z} <${+V+1}.0.0-0`),a("caret return",z),z})},A=(P,D)=>(a("replaceXRanges",P,D),P.split(/\s+/).map(F=>k(F,D)).join(" ")),k=(P,D)=>{P=P.trim();const F=D.loose?l[c.XRANGELOOSE]:l[c.XRANGE];return P.replace(F,(U,Y,V,te,Z,W)=>{a("xRange",P,U,Y,V,te,Z,W);const z=v(V),R=z||v(te),M=R||v(Z),ee=M;return Y==="="&&ee&&(Y=""),W=D.includePrerelease?"-0":"",z?Y===">"||Y==="<"?U="<0.0.0-0":U="*":Y&&ee?(R&&(te=0),Z=0,Y===">"?(Y=">=",R?(V=+V+1,te=0,Z=0):(te=+te+1,Z=0)):Y==="<="&&(Y="<",R?V=+V+1:te=+te+1),Y==="<"&&(W="-0"),U=`${Y+V}.${te}.${Z}${W}`):R?U=`>=${V}.0.0${W} <${+V+1}.0.0-0`:M&&(U=`>=${V}.${te}.0${W} <${V}.${+te+1}.0-0`),a("xRange return",U),U})},_=(P,D)=>(a("replaceStars",P,D),P.trim().replace(l[c.STAR],"")),$=(P,D)=>(a("replaceGTE0",P,D),P.trim().replace(l[D.includePrerelease?c.GTE0PRE:c.GTE0],"")),L=P=>(D,F,U,Y,V,te,Z,W,z,R,M,ee,re)=>(v(U)?F="":v(Y)?F=`>=${U}.0.0${P?"-0":""}`:v(V)?F=`>=${U}.${Y}.0${P?"-0":""}`:te?F=`>=${F}`:F=`>=${F}${P?"-0":""}`,v(z)?W="":v(R)?W=`<${+z+1}.0.0-0`:v(M)?W=`<${z}.${+R+1}.0-0`:ee?W=`<=${z}.${R}.${M}-${ee}`:P?W=`<${z}.${R}.${+M+1}-0`:W=`<=${W}`,`${F} ${W}`.trim()),O=(P,D,F)=>{for(let U=0;U<P.length;U++)if(!P[U].test(D))return!1;if(D.prerelease.length&&!F.includePrerelease){for(let U=0;U<P.length;U++)if(a(P[U].semver),P[U].semver!==o.ANY&&P[U].semver.prerelease.length>0){const Y=P[U].semver;if(Y.major===D.major&&Y.minor===D.minor&&Y.patch===D.patch)return!0}return!1}return!0};return W1}var H1,K_;function Uv(){if(K_)return H1;K_=1;const e=Symbol("SemVer ANY");class t{static get ANY(){return e}constructor(d,f){if(f=n(f),d instanceof t){if(d.loose===!!f.loose)return d;d=d.value}i("comparator",d,f),this.options=f,this.loose=!!f.loose,this.parse(d),this.semver===e?this.value="":this.value=this.operator+this.semver.version,i("comp",this)}parse(d){const f=this.options.loose?r[o.COMPARATORLOOSE]:r[o.COMPARATOR],h=d.match(f);if(!h)throw new TypeError(`Invalid comparator: ${d}`);this.operator=h[1]!==void 0?h[1]:"",this.operator==="="&&(this.operator=""),h[2]?this.semver=new l(h[2],this.options.loose):this.semver=e}toString(){return this.value}test(d){if(i("Comparator.test",d,this.options.loose),this.semver===e||d===e)return!0;if(typeof d=="string")try{d=new l(d,this.options)}catch{return!1}return a(d,this.operator,this.semver,this.options)}intersects(d,f){if(!(d instanceof t))throw new TypeError("a Comparator is required");if((!f||typeof f!="object")&&(f={loose:!!f,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new c(d.value,f).test(this.value);if(d.operator==="")return d.value===""?!0:new c(this.value,f).test(d.semver);const h=(this.operator===">="||this.operator===">")&&(d.operator===">="||d.operator===">"),m=(this.operator==="<="||this.operator==="<")&&(d.operator==="<="||d.operator==="<"),y=this.semver.version===d.semver.version,g=(this.operator===">="||this.operator==="<=")&&(d.operator===">="||d.operator==="<="),v=a(this.semver,"<",d.semver,f)&&(this.operator===">="||this.operator===">")&&(d.operator==="<="||d.operator==="<"),b=a(this.semver,">",d.semver,f)&&(this.operator==="<="||this.operator==="<")&&(d.operator===">="||d.operator===">");return h||m||y&&g||v||b}}H1=t;const n=zv,{re:r,t:o}=Ai,a=cL,i=Fv,l=no,c=Ra();return H1}const lve=Ra(),cve=(e,t,n)=>{try{t=new lve(t,n)}catch{return!1}return t.test(e)};var Wv=cve;const uve=Ra(),dve=(e,t)=>new uve(e,t).set.map(n=>n.map(r=>r.value).join(" ").trim().split(" "));var pve=dve;const fve=no,hve=Ra(),mve=(e,t,n)=>{let r=null,o=null,a=null;try{a=new hve(t,n)}catch{return null}return e.forEach(i=>{a.test(i)&&(!r||o.compare(i)===-1)&&(r=i,o=new fve(r,n))}),r};var gve=mve;const vve=no,yve=Ra(),bve=(e,t,n)=>{let r=null,o=null,a=null;try{a=new yve(t,n)}catch{return null}return e.forEach(i=>{a.test(i)&&(!r||o.compare(i)===1)&&(r=i,o=new vve(r,n))}),r};var wve=bve;const V1=no,Sve=Ra(),Y_=jv,xve=(e,t)=>{e=new Sve(e,t);let n=new V1("0.0.0");if(e.test(n)||(n=new V1("0.0.0-0"),e.test(n)))return n;n=null;for(let r=0;r<e.set.length;++r){const o=e.set[r];let a=null;o.forEach(i=>{const l=new V1(i.semver.version);switch(i.operator){case">":l.prerelease.length===0?l.patch++:l.prerelease.push(0),l.raw=l.format();case"":case">=":(!a||Y_(l,a))&&(a=l);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${i.operator}`)}}),a&&(!n||Y_(n,a))&&(n=a)}return n&&e.test(n)?n:null};var Cve=xve;const Eve=Ra(),Tve=(e,t)=>{try{return new Eve(e,t).range||"*"}catch{return null}};var kve=Tve;const Ave=no,dL=Uv(),{ANY:_ve}=dL,Rve=Ra(),Pve=Wv,X_=jv,J_=t2,Ive=r2,$ve=n2,Ove=(e,t,n,r)=>{e=new Ave(e,r),t=new Rve(t,r);let o,a,i,l,c;switch(n){case">":o=X_,a=Ive,i=J_,l=">",c=">=";break;case"<":o=J_,a=$ve,i=X_,l="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Pve(e,t,r))return!1;for(let u=0;u<t.set.length;++u){const d=t.set[u];let f=null,h=null;if(d.forEach(m=>{m.semver===_ve&&(m=new dL(">=0.0.0")),f=f||m,h=h||m,o(m.semver,f.semver,r)?f=m:i(m.semver,h.semver,r)&&(h=m)}),f.operator===l||f.operator===c||(!h.operator||h.operator===l)&&a(e,h.semver))return!1;if(h.operator===c&&i(e,h.semver))return!1}return!0};var o2=Ove;const Lve=o2,Nve=(e,t,n)=>Lve(e,t,">",n);var Mve=Nve;const Dve=o2,Bve=(e,t,n)=>Dve(e,t,"<",n);var Fve=Bve;const Q_=Ra(),zve=(e,t,n)=>(e=new Q_(e,n),t=new Q_(t,n),e.intersects(t));var jve=zve;const Uve=Wv,Wve=_a;var Hve=(e,t,n)=>{const r=[];let o=null,a=null;const i=e.sort((d,f)=>Wve(d,f,n));for(const d of i)Uve(d,t,n)?(a=d,o||(o=d)):(a&&r.push([o,a]),a=null,o=null);o&&r.push([o,null]);const l=[];for(const[d,f]of r)d===f?l.push(d):!f&&d===i[0]?l.push("*"):f?d===i[0]?l.push(`<=${f}`):l.push(`${d} - ${f}`):l.push(`>=${d}`);const c=l.join(" || "),u=typeof t.raw=="string"?t.raw:String(t);return c.length<u.length?c:t};const Z_=Ra(),zh=Uv(),{ANY:G1}=zh,od=Wv,a2=_a,Vve=(e,t,n={})=>{if(e===t)return!0;e=new Z_(e,n),t=new Z_(t,n);let r=!1;e:for(const o of e.set){for(const a of t.set){const i=Gve(o,a,n);if(r=r||i!==null,i)continue e}if(r)return!1}return!0},Gve=(e,t,n)=>{if(e===t)return!0;if(e.length===1&&e[0].semver===G1){if(t.length===1&&t[0].semver===G1)return!0;n.includePrerelease?e=[new zh(">=0.0.0-0")]:e=[new zh(">=0.0.0")]}if(t.length===1&&t[0].semver===G1){if(n.includePrerelease)return!0;t=[new zh(">=0.0.0")]}const r=new Set;let o,a;for(const m of e)m.operator===">"||m.operator===">="?o=eR(o,m,n):m.operator==="<"||m.operator==="<="?a=tR(a,m,n):r.add(m.semver);if(r.size>1)return null;let i;if(o&&a){if(i=a2(o.semver,a.semver,n),i>0)return null;if(i===0&&(o.operator!==">="||a.operator!=="<="))return null}for(const m of r){if(o&&!od(m,String(o),n)||a&&!od(m,String(a),n))return null;for(const y of t)if(!od(m,String(y),n))return!1;return!0}let l,c,u,d,f=a&&!n.includePrerelease&&a.semver.prerelease.length?a.semver:!1,h=o&&!n.includePrerelease&&o.semver.prerelease.length?o.semver:!1;f&&f.prerelease.length===1&&a.operator==="<"&&f.prerelease[0]===0&&(f=!1);for(const m of t){if(d=d||m.operator===">"||m.operator===">=",u=u||m.operator==="<"||m.operator==="<=",o){if(h&&m.semver.prerelease&&m.semver.prerelease.length&&m.semver.major===h.major&&m.semver.minor===h.minor&&m.semver.patch===h.patch&&(h=!1),m.operator===">"||m.operator===">="){if(l=eR(o,m,n),l===m&&l!==o)return!1}else if(o.operator===">="&&!od(o.semver,String(m),n))return!1}if(a){if(f&&m.semver.prerelease&&m.semver.prerelease.length&&m.semver.major===f.major&&m.semver.minor===f.minor&&m.semver.patch===f.patch&&(f=!1),m.operator==="<"||m.operator==="<="){if(c=tR(a,m,n),c===m&&c!==a)return!1}else if(a.operator==="<="&&!od(a.semver,String(m),n))return!1}if(!m.operator&&(a||o)&&i!==0)return!1}return!(o&&u&&!a&&i!==0||a&&d&&!o&&i!==0||h||f)},eR=(e,t,n)=>{if(!e)return t;const r=a2(e.semver,t.semver,n);return r>0?e:r<0||t.operator===">"&&e.operator===">="?t:e},tR=(e,t,n)=>{if(!e)return t;const r=a2(e.semver,t.semver,n);return r<0?e:r>0||t.operator==="<"&&e.operator==="<="?t:e};var qve=Vve;const q1=Ai,Kve=Bv,Yve=no,nR=sL,Xve=yu,Jve=Yme,Qve=Qme,Zve=ege,eye=ige,tye=cge,nye=pge,rye=mge,oye=yge,aye=_a,iye=Sge,sye=Ege,lye=e2,cye=_ge,uye=Ige,dye=jv,pye=t2,fye=ZC,hye=lL,mye=n2,gye=r2,vye=cL,yye=Qge,bye=Uv(),wye=Ra(),Sye=Wv,xye=pve,Cye=gve,Eye=wve,Tye=Cve,kye=kve,Aye=o2,_ye=Mve,Rye=Fve,Pye=jve,Iye=Hve,$ye=qve;var rR={parse:Xve,valid:Jve,clean:Qve,inc:Zve,diff:eye,major:tye,minor:nye,patch:rye,prerelease:oye,compare:aye,rcompare:iye,compareLoose:sye,compareBuild:lye,sort:cye,rsort:uye,gt:dye,lt:pye,eq:fye,neq:hye,gte:mye,lte:gye,cmp:vye,coerce:yye,Comparator:bye,Range:wye,satisfies:Sye,toComparators:xye,maxSatisfying:Cye,minSatisfying:Eye,minVersion:Tye,validRange:kye,outside:Aye,gtr:_ye,ltr:Rye,intersects:Pye,simplifyRange:Iye,subset:$ye,SemVer:Yve,re:q1.re,src:q1.src,tokens:q1.t,SEMVER_SPEC_VERSION:Kve.SEMVER_SPEC_VERSION,compareIdentifiers:nR.compareIdentifiers,rcompareIdentifiers:nR.rcompareIdentifiers};const Oye=e=>()=>{const t=Number(e);return typeof t!="number"||Number.isNaN(t)?[!1,"Value must be a number"]:[!0,""]},Lye=e=>()=>{const t=[!1,"Values must be a list of strings"];return!Array.isArray(e)||!e.every(n=>typeof n=="string")?t:[!0,""]},Nye=e=>()=>{const t=rR.clean(e)===e;return!rR.valid(e)||!t?[!1,"Value is not a valid semver. For example 1.2.4"]:[!0,""]},Mye=e=>()=>Kx(rf(e))?[!0,""]:[!1,"Value must be a valid date matching RFC3339"],dh=e=>Boolean(e)&&Array.isArray(e)&&e.length>0,cw="IN_OPERATORS_LEGAL_VALUES",pL="STRING_OPERATORS_LEGAL_VALUES",fL="NUM_OPERATORS_LEGAL_VALUES",hL="SEMVER_OPERATORS_LEGAL_VALUES",mL="DATE_OPERATORS_SINGLE_VALUE",gL="IN_OPERATORS_FREETEXT",vL="STRING_OPERATORS_FREETEXT",yL="NUM_OPERATORS_SINGLE_VALUE",bL="SEMVER_OPERATORS_SINGLE_VALUE",oR="NUMBER_VALIDATOR",aR="SEMVER_VALIDATOR",K1="STRING_ARRAY_VALIDATOR",iR="DATE_VALIDATOR",Dye=({contextDefinition:e,localConstraint:t})=>{const[n,r]=p.useState(cw),[o,a]=p.useState(K1),[i,l]=p.useState(""),c=p.useCallback(()=>{dh(e.legalValues)&&wn(cl,t.operator)?r(cw):dh(e.legalValues)&&wn(xi,t.operator)?r(pL):dh(e.legalValues)&&wn(Tc,t.operator)?r(fL):dh(e.legalValues)&&wn(kc,t.operator)?r(hL):wn(Jo,t.operator)?r(mL):wn(cl,t.operator)?r(gL):wn(xi,t.operator)?r(vL):wn(Tc,t.operator)?r(yL):wn(kc,t.operator)&&r(bL)},[t,e]),u=()=>{switch(o){case oR:return Oye(t.value);case K1:return Lye(t.values||[]);case aR:return Nye(t.value||"");case iR:return Mye(t.value||"")}},d=p.useCallback(f=>{wn(Tc,f)&&a(oR),wn([...xi,...cl],f)&&a(K1),wn(kc,f)&&a(aR),wn(Jo,f)&&a(iR)},[a]);return p.useEffect(()=>{d(t.operator)},[t.operator,t.value,t.values,d]),p.useEffect(()=>{c()},[e,t,c]),{input:n,error:i,validator:u(),setError:l}},Bye=C("h3")(({theme:e})=>({fontSize:e.fontSizes.bodySize,fontWeight:e.typography.fontWeightMedium,marginTop:e.spacing(2),marginBottom:e.spacing(.5)})),sf=({children:e,...t})=>s(Bye,{...t,children:e});function sR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Rp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?sR(Object(n),!0).forEach(function(r){Hv(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Hv(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Fye(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,a;for(a=0;a<r.length;a++)o=r[a],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function zye(e,t){if(e==null)return{};var n=Fye(e,t),r,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)r=a[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function jye(e,t){return Uye(e)||Wye(e,t)||Hye(e,t)||Vye()}function Uye(e){if(Array.isArray(e))return e}function Wye(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],o=!0,a=!1,i,l;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(r.push(i.value),!(t&&r.length===t));o=!0);}catch(c){a=!0,l=c}finally{try{!o&&n.return!=null&&n.return()}finally{if(a)throw l}}return r}}function Hye(e,t){if(e){if(typeof e=="string")return lR(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return lR(e,t)}}function lR(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Vye(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
337
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Gye={AD:"Andorra",AE:"United Arab Emirates",AF:"Afghanistan",AG:"Antigua and Barbuda",AI:"Anguilla",AL:"Albania",AM:"Armenia",AO:"Angola",AQ:"Antarctica",AR:"Argentina",AS:"American Samoa",AT:"Austria",AU:"Australia",AW:"Aruba",AX:"Åland Islands",AZ:"Azerbaijan",BA:"Bosnia and Herzegovina",BB:"Barbados",BD:"Bangladesh",BE:"Belgium",BF:"Burkina Faso",BG:"Bulgaria",BH:"Bahrain",BI:"Burundi",BJ:"Benin",BL:"Saint Barthélemy",BM:"Bermuda",BN:"Brunei",BO:"Bolivia",BQ:"Caribbean Netherlands",BR:"Brazil",BS:"Bahamas",BT:"Bhutan",BV:"Bouvet Island",BW:"Botswana",BY:"Belarus",BZ:"Belize",CA:"Canada",CC:"Cocos Islands",CD:"Democratic Republic of the Congo",CF:"Central African Republic",CG:"Republic of the Congo",CH:"Switzerland",CI:"Ivory Coast",CK:"Cook Islands",CL:"Chile",CM:"Cameroon",CN:"China",CO:"Colombia",CR:"Costa Rica",CU:"Cuba",CV:"Cabo Verde",CW:"Curaçao",CX:"Christmas Island",CY:"Cyprus",CZ:"Czechia",DE:"Germany",DJ:"Djibouti",DK:"Denmark",DM:"Dominica",DO:"Dominican Republic",DZ:"Algeria",EC:"Ecuador",EE:"Estonia",EG:"Egypt",EH:"Western Sahara",ER:"Eritrea",ES:"Spain",ET:"Ethiopia",FI:"Finland",FJ:"Fiji",FK:"Falkland Islands",FM:"Micronesia",FO:"Faroe Islands",FR:"France",GA:"Gabon",GB:"United Kingdom",GD:"Grenada",GE:"Georgia",GF:"French Guiana",GG:"Guernsey",GH:"Ghana",GI:"Gibraltar",GL:"Greenland",GM:"Gambia",GN:"Guinea",GP:"Guadeloupe",GQ:"Equatorial Guinea",GR:"Greece",GS:"South Georgia and the South Sandwich Islands",GT:"Guatemala",GU:"Guam",GW:"Guinea-Bissau",GY:"Guyana",HK:"Hong Kong",HM:"Heard Island and McDonald Islands",HN:"Honduras",HR:"Croatia",HT:"Haiti",HU:"Hungary",ID:"Indonesia",IE:"Ireland",IL:"Israel",IM:"Isle of Man",IN:"India",IO:"British Indian Ocean Territory",IQ:"Iraq",IR:"Iran",IS:"Iceland",IT:"Italy",JE:"Jersey",JM:"Jamaica",JO:"Jordan",JP:"Japan",KE:"Kenya",KG:"Kyrgyzstan",KH:"Cambodia",KI:"Kiribati",KM:"Comoros",KN:"Saint Kitts and Nevis",KP:"North Korea",KR:"South Korea",KW:"Kuwait",KY:"Cayman Islands",KZ:"Kazakhstan",LA:"Laos",LB:"Lebanon",LC:"Saint Lucia",LI:"Liechtenstein",LK:"Sri Lanka",LR:"Liberia",LS:"Lesotho",LT:"Lithuania",LU:"Luxembourg",LV:"Latvia",LY:"Libya",MA:"Morocco",MC:"Monaco",MD:"Moldova",ME:"Montenegro",MF:"Saint Martin",MG:"Madagascar",MH:"Marshall Islands",MK:"North Macedonia",ML:"Mali",MM:"Myanmar",MN:"Mongolia",MO:"Macao",MP:"Northern Mariana Islands",MQ:"Martinique",MR:"Mauritania",MS:"Montserrat",MT:"Malta",MU:"Mauritius",MV:"Maldives",MW:"Malawi",MX:"Mexico",MY:"Malaysia",MZ:"Mozambique",NA:"Namibia",NC:"New Caledonia",NE:"Niger",NF:"Norfolk Island",NG:"Nigeria",NI:"Nicaragua",NL:"Netherlands",NO:"Norway",NP:"Nepal",NR:"Nauru",NU:"Niue",NZ:"New Zealand",OM:"Oman",PA:"Panama",PE:"Peru",PF:"French Polynesia",PG:"Papua New Guinea",PH:"Philippines",PK:"Pakistan",PL:"Poland",PM:"Saint Pierre and Miquelon",PN:"Pitcairn",PR:"Puerto Rico",PS:"Palestine",PT:"Portugal",PW:"Palau",PY:"Paraguay",QA:"Qatar",RE:"Réunion",RO:"Romania",RS:"Serbia",RU:"Russia",RW:"Rwanda",SA:"Saudi Arabia",SB:"Solomon Islands",SC:"Seychelles",SD:"Sudan",SE:"Sweden",SG:"Singapore",SH:"Saint Helena, Ascension and Tristan da Cunha",SI:"Slovenia",SJ:"Svalbard and Jan Mayen",SK:"Slovakia",SL:"Sierra Leone",SM:"San Marino",SN:"Senegal",SO:"Somalia",SR:"Suriname",SS:"South Sudan",ST:"Sao Tome and Principe",SV:"El Salvador",SX:"Sint Maarten",SY:"Syria",SZ:"Eswatini",TC:"Turks and Caicos Islands",TD:"Chad",TF:"French Southern Territories",TG:"Togo",TH:"Thailand",TJ:"Tajikistan",TK:"Tokelau",TL:"Timor-Leste",TM:"Turkmenistan",TN:"Tunisia",TO:"Tonga",TR:"Türkiye",TT:"Trinidad and Tobago",TV:"Tuvalu",TW:"Taiwan",TZ:"Tanzania",UA:"Ukraine",UG:"Uganda",UM:"United States Minor Outlying Islands",US:"United States of America",UY:"Uruguay",UZ:"Uzbekistan",VA:"Holy See",VC:"Saint Vincent and the Grenadines",VE:"Venezuela",VG:"Virgin Islands (UK)",VI:"Virgin Islands (US)",VN:"Vietnam",VU:"Vanuatu",WF:"Wallis and Futuna",WS:"Samoa",YE:"Yemen",YT:"Mayotte",ZA:"South Africa",ZM:"Zambia",ZW:"Zimbabwe"},qye={"Africa/Abidjan":{u:0,c:["CI","BF","GH","GM","GN","IS","ML","MR","SH","SL","SN","TG"]},"Africa/Accra":{a:"Africa/Abidjan",c:["GH"],r:1},"Africa/Addis_Ababa":{a:"Africa/Nairobi",c:["ET"],r:1},"Africa/Algiers":{u:60,c:["DZ"]},"Africa/Asmara":{a:"Africa/Nairobi",c:["ER"],r:1},"Africa/Asmera":{a:"Africa/Nairobi",c:["ER"],r:1},"Africa/Bamako":{a:"Africa/Abidjan",c:["ML"],r:1},"Africa/Bangui":{a:"Africa/Lagos",c:["CF"],r:1},"Africa/Banjul":{a:"Africa/Abidjan",c:["GM"],r:1},"Africa/Bissau":{u:0,c:["GW"]},"Africa/Blantyre":{a:"Africa/Maputo",c:["MW"],r:1},"Africa/Brazzaville":{a:"Africa/Lagos",c:["CG"],r:1},"Africa/Bujumbura":{a:"Africa/Maputo",c:["BI"],r:1},"Africa/Cairo":{u:120,c:["EG"]},"Africa/Casablanca":{u:60,d:0,c:["MA"]},"Africa/Ceuta":{u:60,d:120,c:["ES"]},"Africa/Conakry":{a:"Africa/Abidjan",c:["GN"],r:1},"Africa/Dakar":{a:"Africa/Abidjan",c:["SN"],r:1},"Africa/Dar_es_Salaam":{a:"Africa/Nairobi",c:["TZ"],r:1},"Africa/Djibouti":{a:"Africa/Nairobi",c:["DJ"],r:1},"Africa/Douala":{a:"Africa/Lagos",c:["CM"],r:1},"Africa/El_Aaiun":{u:60,d:0,c:["EH"]},"Africa/Freetown":{a:"Africa/Abidjan",c:["SL"],r:1},"Africa/Gaborone":{a:"Africa/Maputo",c:["BW"],r:1},"Africa/Harare":{a:"Africa/Maputo",c:["ZW"],r:1},"Africa/Johannesburg":{u:120,c:["ZA","LS","SZ"]},"Africa/Juba":{u:120,c:["SS"]},"Africa/Kampala":{a:"Africa/Nairobi",c:["UG"],r:1},"Africa/Khartoum":{u:120,c:["SD"]},"Africa/Kigali":{a:"Africa/Maputo",c:["RW"],r:1},"Africa/Kinshasa":{a:"Africa/Lagos",c:["CD"],r:1},"Africa/Lagos":{u:60,c:["NG","AO","BJ","CD","CF","CG","CM","GA","GQ","NE"]},"Africa/Libreville":{a:"Africa/Lagos",c:["GA"],r:1},"Africa/Lome":{a:"Africa/Abidjan",c:["TG"],r:1},"Africa/Luanda":{a:"Africa/Lagos",c:["AO"],r:1},"Africa/Lubumbashi":{a:"Africa/Maputo",c:["CD"],r:1},"Africa/Lusaka":{a:"Africa/Maputo",c:["ZM"],r:1},"Africa/Malabo":{a:"Africa/Lagos",c:["GQ"],r:1},"Africa/Maputo":{u:120,c:["MZ","BI","BW","CD","MW","RW","ZM","ZW"]},"Africa/Maseru":{a:"Africa/Johannesburg",c:["LS"],r:1},"Africa/Mbabane":{a:"Africa/Johannesburg",c:["SZ"],r:1},"Africa/Mogadishu":{a:"Africa/Nairobi",c:["SO"],r:1},"Africa/Monrovia":{u:0,c:["LR"]},"Africa/Nairobi":{u:180,c:["KE","DJ","ER","ET","KM","MG","SO","TZ","UG","YT"]},"Africa/Ndjamena":{u:60,c:["TD"]},"Africa/Niamey":{a:"Africa/Lagos",c:["NE"],r:1},"Africa/Nouakchott":{a:"Africa/Abidjan",c:["MR"],r:1},"Africa/Ouagadougou":{a:"Africa/Abidjan",c:["BF"],r:1},"Africa/Porto-Novo":{a:"Africa/Lagos",c:["BJ"],r:1},"Africa/Sao_Tome":{u:0,c:["ST"]},"Africa/Timbuktu":{a:"Africa/Abidjan",c:["ML"],r:1},"Africa/Tripoli":{u:120,c:["LY"]},"Africa/Tunis":{u:60,c:["TN"]},"Africa/Windhoek":{u:120,c:["NA"]},"America/Adak":{u:-600,d:-540,c:["US"]},"America/Anchorage":{u:-540,d:-480,c:["US"]},"America/Anguilla":{a:"America/Puerto_Rico",c:["AI"],r:1},"America/Antigua":{a:"America/Puerto_Rico",c:["AG"],r:1},"America/Araguaina":{u:-180,c:["BR"]},"America/Argentina/Buenos_Aires":{u:-180,c:["AR"]},"America/Argentina/Catamarca":{u:-180,c:["AR"]},"America/Argentina/ComodRivadavia":{a:"America/Argentina/Catamarca",r:1},"America/Argentina/Cordoba":{u:-180,c:["AR"]},"America/Argentina/Jujuy":{u:-180,c:["AR"]},"America/Argentina/La_Rioja":{u:-180,c:["AR"]},"America/Argentina/Mendoza":{u:-180,c:["AR"]},"America/Argentina/Rio_Gallegos":{u:-180,c:["AR"]},"America/Argentina/Salta":{u:-180,c:["AR"]},"America/Argentina/San_Juan":{u:-180,c:["AR"]},"America/Argentina/San_Luis":{u:-180,c:["AR"]},"America/Argentina/Tucuman":{u:-180,c:["AR"]},"America/Argentina/Ushuaia":{u:-180,c:["AR"]},"America/Aruba":{a:"America/Puerto_Rico",c:["AW"],r:1},"America/Asuncion":{u:-240,d:-180,c:["PY"]},"America/Atikokan":{a:"America/Panama",c:["CA"],r:1},"America/Atka":{a:"America/Adak",r:1},"America/Bahia":{u:-180,c:["BR"]},"America/Bahia_Banderas":{u:-360,c:["MX"]},"America/Barbados":{u:-240,c:["BB"]},"America/Belem":{u:-180,c:["BR"]},"America/Belize":{u:-360,c:["BZ"]},"America/Blanc-Sablon":{a:"America/Puerto_Rico",c:["CA"],r:1},"America/Boa_Vista":{u:-240,c:["BR"]},"America/Bogota":{u:-300,c:["CO"]},"America/Boise":{u:-420,d:-360,c:["US"]},"America/Buenos_Aires":{a:"America/Argentina/Buenos_Aires",r:1},"America/Cambridge_Bay":{u:-420,d:-360,c:["CA"]},"America/Campo_Grande":{u:-240,c:["BR"]},"America/Cancun":{u:-300,c:["MX"]},"America/Caracas":{u:-240,c:["VE"]},"America/Catamarca":{a:"America/Argentina/Catamarca",r:1},"America/Cayenne":{u:-180,c:["GF"]},"America/Cayman":{a:"America/Panama",c:["KY"],r:1},"America/Chicago":{u:-360,d:-300,c:["US"]},"America/Chihuahua":{u:-360,c:["MX"]},"America/Ciudad_Juarez":{u:-420,d:-360,c:["MX"]},"America/Coral_Harbour":{a:"America/Panama",c:["CA"],r:1},"America/Cordoba":{a:"America/Argentina/Cordoba",r:1},"America/Costa_Rica":{u:-360,c:["CR"]},"America/Creston":{a:"America/Phoenix",c:["CA"],r:1},"America/Cuiaba":{u:-240,c:["BR"]},"America/Curacao":{a:"America/Puerto_Rico",c:["CW"],r:1},"America/Danmarkshavn":{u:0,c:["GL"]},"America/Dawson":{u:-420,c:["CA"]},"America/Dawson_Creek":{u:-420,c:["CA"]},"America/Denver":{u:-420,d:-360,c:["US"]},"America/Detroit":{u:-300,d:-240,c:["US"]},"America/Dominica":{a:"America/Puerto_Rico",c:["DM"],r:1},"America/Edmonton":{u:-420,d:-360,c:["CA"]},"America/Eirunepe":{u:-300,c:["BR"]},"America/El_Salvador":{u:-360,c:["SV"]},"America/Ensenada":{a:"America/Tijuana",r:1},"America/Fort_Nelson":{u:-420,c:["CA"]},"America/Fort_Wayne":{a:"America/Indiana/Indianapolis",r:1},"America/Fortaleza":{u:-180,c:["BR"]},"America/Glace_Bay":{u:-240,d:-180,c:["CA"]},"America/Godthab":{a:"America/Nuuk",r:1},"America/Goose_Bay":{u:-240,d:-180,c:["CA"]},"America/Grand_Turk":{u:-300,d:-240,c:["TC"]},"America/Grenada":{a:"America/Puerto_Rico",c:["GD"],r:1},"America/Guadeloupe":{a:"America/Puerto_Rico",c:["GP"],r:1},"America/Guatemala":{u:-360,c:["GT"]},"America/Guayaquil":{u:-300,c:["EC"]},"America/Guyana":{u:-240,c:["GY"]},"America/Halifax":{u:-240,d:-180,c:["CA"]},"America/Havana":{u:-300,d:-240,c:["CU"]},"America/Hermosillo":{u:-420,c:["MX"]},"America/Indiana/Indianapolis":{u:-300,d:-240,c:["US"]},"America/Indiana/Knox":{u:-360,d:-300,c:["US"]},"America/Indiana/Marengo":{u:-300,d:-240,c:["US"]},"America/Indiana/Petersburg":{u:-300,d:-240,c:["US"]},"America/Indiana/Tell_City":{u:-360,d:-300,c:["US"]},"America/Indiana/Vevay":{u:-300,d:-240,c:["US"]},"America/Indiana/Vincennes":{u:-300,d:-240,c:["US"]},"America/Indiana/Winamac":{u:-300,d:-240,c:["US"]},"America/Indianapolis":{a:"America/Indiana/Indianapolis",r:1},"America/Inuvik":{u:-420,d:-360,c:["CA"]},"America/Iqaluit":{u:-300,d:-240,c:["CA"]},"America/Jamaica":{u:-300,c:["JM"]},"America/Jujuy":{a:"America/Argentina/Jujuy",r:1},"America/Juneau":{u:-540,d:-480,c:["US"]},"America/Kentucky/Louisville":{u:-300,d:-240,c:["US"]},"America/Kentucky/Monticello":{u:-300,d:-240,c:["US"]},"America/Knox_IN":{a:"America/Indiana/Knox",r:1},"America/Kralendijk":{a:"America/Puerto_Rico",c:["BQ"],r:1},"America/La_Paz":{u:-240,c:["BO"]},"America/Lima":{u:-300,c:["PE"]},"America/Los_Angeles":{u:-480,d:-420,c:["US"]},"America/Louisville":{a:"America/Kentucky/Louisville",r:1},"America/Lower_Princes":{a:"America/Puerto_Rico",c:["SX"],r:1},"America/Maceio":{u:-180,c:["BR"]},"America/Managua":{u:-360,c:["NI"]},"America/Manaus":{u:-240,c:["BR"]},"America/Marigot":{a:"America/Puerto_Rico",c:["MF"],r:1},"America/Martinique":{u:-240,c:["MQ"]},"America/Matamoros":{u:-360,d:-300,c:["MX"]},"America/Mazatlan":{u:-420,c:["MX"]},"America/Mendoza":{a:"America/Argentina/Mendoza",r:1},"America/Menominee":{u:-360,d:-300,c:["US"]},"America/Merida":{u:-360,c:["MX"]},"America/Metlakatla":{u:-540,d:-480,c:["US"]},"America/Mexico_City":{u:-360,c:["MX"]},"America/Miquelon":{u:-180,d:-120,c:["PM"]},"America/Moncton":{u:-240,d:-180,c:["CA"]},"America/Monterrey":{u:-360,c:["MX"]},"America/Montevideo":{u:-180,c:["UY"]},"America/Montreal":{a:"America/Toronto",c:["CA"],r:1},"America/Montserrat":{a:"America/Puerto_Rico",c:["MS"],r:1},"America/Nassau":{a:"America/Toronto",c:["BS"],r:1},"America/New_York":{u:-300,d:-240,c:["US"]},"America/Nipigon":{a:"America/Toronto",c:["CA"],r:1},"America/Nome":{u:-540,d:-480,c:["US"]},"America/Noronha":{u:-120,c:["BR"]},"America/North_Dakota/Beulah":{u:-360,d:-300,c:["US"]},"America/North_Dakota/Center":{u:-360,d:-300,c:["US"]},"America/North_Dakota/New_Salem":{u:-360,d:-300,c:["US"]},"America/Nuuk":{u:-180,c:["GL"]},"America/Ojinaga":{u:-360,d:-300,c:["MX"]},"America/Panama":{u:-300,c:["PA","CA","KY"]},"America/Pangnirtung":{a:"America/Iqaluit",r:1},"America/Paramaribo":{u:-180,c:["SR"]},"America/Phoenix":{u:-420,c:["US","CA"]},"America/Port-au-Prince":{u:-300,d:-240,c:["HT"]},"America/Port_of_Spain":{a:"America/Puerto_Rico",c:["TT"],r:1},"America/Porto_Acre":{a:"America/Rio_Branco",r:1},"America/Porto_Velho":{u:-240,c:["BR"]},"America/Puerto_Rico":{u:-240,c:["PR","AG","CA","AI","AW","BL","BQ","CW","DM","GD","GP","KN","LC","MF","MS","SX","TT","VC","VG","VI"]},"America/Punta_Arenas":{u:-180,c:["CL"]},"America/Rainy_River":{a:"America/Winnipeg",r:1},"America/Rankin_Inlet":{u:-360,d:-300,c:["CA"]},"America/Recife":{u:-180,c:["BR"]},"America/Regina":{u:-360,c:["CA"]},"America/Resolute":{u:-360,d:-300,c:["CA"]},"America/Rio_Branco":{u:-300,c:["BR"]},"America/Rosario":{a:"America/Argentina/Cordoba",r:1},"America/Santa_Isabel":{a:"America/Tijuana",r:1},"America/Santarem":{u:-180,c:["BR"]},"America/Santiago":{u:-240,d:-180,c:["CL"]},"America/Santo_Domingo":{u:-240,c:["DO"]},"America/Sao_Paulo":{u:-180,c:["BR"]},"America/Scoresbysund":{u:-60,d:0,c:["GL"]},"America/Shiprock":{a:"America/Denver",r:1},"America/Sitka":{u:-540,d:-480,c:["US"]},"America/St_Barthelemy":{a:"America/Puerto_Rico",c:["BL"],r:1},"America/St_Johns":{u:-210,d:-150,c:["CA"]},"America/St_Kitts":{a:"America/Puerto_Rico",c:["KN"],r:1},"America/St_Lucia":{a:"America/Puerto_Rico",c:["LC"],r:1},"America/St_Thomas":{a:"America/Puerto_Rico",c:["VI"],r:1},"America/St_Vincent":{a:"America/Puerto_Rico",c:["VC"],r:1},"America/Swift_Current":{u:-360,c:["CA"]},"America/Tegucigalpa":{u:-360,c:["HN"]},"America/Thule":{u:-240,d:-180,c:["GL"]},"America/Thunder_Bay":{a:"America/Toronto",c:["CA"],r:1},"America/Tijuana":{u:-480,d:-420,c:["MX"]},"America/Toronto":{u:-300,d:-240,c:["CA","BS"]},"America/Tortola":{a:"America/Puerto_Rico",c:["VG"],r:1},"America/Vancouver":{u:-480,d:-420,c:["CA"]},"America/Virgin":{a:"America/Puerto_Rico",c:["VI"],r:1},"America/Whitehorse":{u:-420,c:["CA"]},"America/Winnipeg":{u:-360,d:-300,c:["CA"]},"America/Yakutat":{u:-540,d:-480,c:["US"]},"America/Yellowknife":{u:-420,d:-360,c:["CA"]},"Antarctica/Casey":{u:660,c:["AQ"]},"Antarctica/Davis":{u:420,c:["AQ"]},"Antarctica/DumontDUrville":{a:"Pacific/Port_Moresby",c:["AQ"],r:1},"Antarctica/Macquarie":{u:600,d:660,c:["AU"]},"Antarctica/Mawson":{u:300,c:["AQ"]},"Antarctica/McMurdo":{a:"Pacific/Auckland",c:["AQ"],r:1},"Antarctica/Palmer":{u:-180,c:["AQ"]},"Antarctica/Rothera":{u:-180,c:["AQ"]},"Antarctica/South_Pole":{a:"Pacific/Auckland",c:["AQ"],r:1},"Antarctica/Syowa":{a:"Asia/Riyadh",c:["AQ"],r:1},"Antarctica/Troll":{u:0,d:120,c:["AQ"]},"Antarctica/Vostok":{a:"Asia/Urumqi",c:["AQ"],r:1},"Arctic/Longyearbyen":{a:"Europe/Berlin",c:["SJ"],r:1},"Asia/Aden":{a:"Asia/Riyadh",c:["YE"],r:1},"Asia/Almaty":{u:360,c:["KZ"]},"Asia/Amman":{u:180,c:["JO"]},"Asia/Anadyr":{u:720,c:["RU"]},"Asia/Aqtau":{u:300,c:["KZ"]},"Asia/Aqtobe":{u:300,c:["KZ"]},"Asia/Ashgabat":{u:300,c:["TM"]},"Asia/Ashkhabad":{a:"Asia/Ashgabat",r:1},"Asia/Atyrau":{u:300,c:["KZ"]},"Asia/Baghdad":{u:180,c:["IQ"]},"Asia/Bahrain":{a:"Asia/Qatar",c:["BH"],r:1},"Asia/Baku":{u:240,c:["AZ"]},"Asia/Bangkok":{u:420,c:["TH","CX","KH","LA","VN"]},"Asia/Barnaul":{u:420,c:["RU"]},"Asia/Beirut":{u:120,d:180,c:["LB"]},"Asia/Bishkek":{u:360,c:["KG"]},"Asia/Brunei":{a:"Asia/Kuching",c:["BN"],r:1},"Asia/Calcutta":{a:"Asia/Kolkata",r:1},"Asia/Chita":{u:540,c:["RU"]},"Asia/Choibalsan":{u:480,c:["MN"]},"Asia/Chongqing":{a:"Asia/Shanghai",r:1},"Asia/Chungking":{a:"Asia/Shanghai",r:1},"Asia/Colombo":{u:330,c:["LK"]},"Asia/Dacca":{a:"Asia/Dhaka",r:1},"Asia/Damascus":{u:180,c:["SY"]},"Asia/Dhaka":{u:360,c:["BD"]},"Asia/Dili":{u:540,c:["TL"]},"Asia/Dubai":{u:240,c:["AE","OM","RE","SC","TF"]},"Asia/Dushanbe":{u:300,c:["TJ"]},"Asia/Famagusta":{u:120,d:180,c:["CY"]},"Asia/Gaza":{u:120,d:180,c:["PS"]},"Asia/Harbin":{a:"Asia/Shanghai",r:1},"Asia/Hebron":{u:120,d:180,c:["PS"]},"Asia/Ho_Chi_Minh":{u:420,c:["VN"]},"Asia/Hong_Kong":{u:480,c:["HK"]},"Asia/Hovd":{u:420,c:["MN"]},"Asia/Irkutsk":{u:480,c:["RU"]},"Asia/Istanbul":{a:"Europe/Istanbul",r:1},"Asia/Jakarta":{u:420,c:["ID"]},"Asia/Jayapura":{u:540,c:["ID"]},"Asia/Jerusalem":{u:120,d:180,c:["IL"]},"Asia/Kabul":{u:270,c:["AF"]},"Asia/Kamchatka":{u:720,c:["RU"]},"Asia/Karachi":{u:300,c:["PK"]},"Asia/Kashgar":{a:"Asia/Urumqi",c:["CN"],r:1},"Asia/Kathmandu":{u:345,c:["NP"]},"Asia/Katmandu":{a:"Asia/Kathmandu",r:1},"Asia/Khandyga":{u:540,c:["RU"]},"Asia/Kolkata":{u:330,c:["IN"]},"Asia/Krasnoyarsk":{u:420,c:["RU"]},"Asia/Kuala_Lumpur":{a:"Asia/Singapore",c:["MY"],r:1},"Asia/Kuching":{u:480,c:["MY","BN"]},"Asia/Kuwait":{a:"Asia/Riyadh",c:["KW"],r:1},"Asia/Macao":{a:"Asia/Macau",r:1},"Asia/Macau":{u:480,c:["MO"]},"Asia/Magadan":{u:660,c:["RU"]},"Asia/Makassar":{u:480,c:["ID"]},"Asia/Manila":{u:480,c:["PH"]},"Asia/Muscat":{a:"Asia/Dubai",c:["OM"],r:1},"Asia/Nicosia":{u:120,d:180,c:["CY"]},"Asia/Novokuznetsk":{u:420,c:["RU"]},"Asia/Novosibirsk":{u:420,c:["RU"]},"Asia/Omsk":{u:360,c:["RU"]},"Asia/Oral":{u:300,c:["KZ"]},"Asia/Phnom_Penh":{a:"Asia/Bangkok",c:["KH"],r:1},"Asia/Pontianak":{u:420,c:["ID"]},"Asia/Pyongyang":{u:540,c:["KP"]},"Asia/Qatar":{u:180,c:["QA","BH"]},"Asia/Qostanay":{u:360,c:["KZ"]},"Asia/Qyzylorda":{u:300,c:["KZ"]},"Asia/Rangoon":{a:"Asia/Yangon",c:["MM"],r:1},"Asia/Riyadh":{u:180,c:["SA","AQ","KW","YE"]},"Asia/Saigon":{a:"Asia/Ho_Chi_Minh",r:1},"Asia/Sakhalin":{u:660,c:["RU"]},"Asia/Samarkand":{u:300,c:["UZ"]},"Asia/Seoul":{u:540,c:["KR"]},"Asia/Shanghai":{u:480,c:["CN"]},"Asia/Singapore":{u:480,c:["SG","MY"]},"Asia/Srednekolymsk":{u:660,c:["RU"]},"Asia/Taipei":{u:480,c:["TW"]},"Asia/Tashkent":{u:300,c:["UZ"]},"Asia/Tbilisi":{u:240,c:["GE"]},"Asia/Tehran":{u:210,c:["IR"]},"Asia/Tel_Aviv":{a:"Asia/Jerusalem",r:1},"Asia/Thimbu":{a:"Asia/Thimphu",r:1},"Asia/Thimphu":{u:360,c:["BT"]},"Asia/Tokyo":{u:540,c:["JP"]},"Asia/Tomsk":{u:420,c:["RU"]},"Asia/Ujung_Pandang":{a:"Asia/Makassar",r:1},"Asia/Ulaanbaatar":{u:480,c:["MN"]},"Asia/Ulan_Bator":{a:"Asia/Ulaanbaatar",r:1},"Asia/Urumqi":{u:360,c:["CN","AQ"]},"Asia/Ust-Nera":{u:600,c:["RU"]},"Asia/Vientiane":{a:"Asia/Bangkok",c:["LA"],r:1},"Asia/Vladivostok":{u:600,c:["RU"]},"Asia/Yakutsk":{u:540,c:["RU"]},"Asia/Yangon":{u:390,c:["MM","CC"]},"Asia/Yekaterinburg":{u:300,c:["RU"]},"Asia/Yerevan":{u:240,c:["AM"]},"Atlantic/Azores":{u:-60,d:0,c:["PT"]},"Atlantic/Bermuda":{u:-240,d:-180,c:["BM"]},"Atlantic/Canary":{u:0,d:60,c:["ES"]},"Atlantic/Cape_Verde":{u:-60,c:["CV"]},"Atlantic/Faeroe":{a:"Atlantic/Faroe",r:1},"Atlantic/Faroe":{u:0,d:60,c:["FO"]},"Atlantic/Jan_Mayen":{a:"Europe/Berlin",c:["SJ"],r:1},"Atlantic/Madeira":{u:0,d:60,c:["PT"]},"Atlantic/Reykjavik":{a:"Africa/Abidjan",c:["IS"],r:1},"Atlantic/South_Georgia":{u:-120,c:["GS"]},"Atlantic/St_Helena":{a:"Africa/Abidjan",c:["SH"],r:1},"Atlantic/Stanley":{u:-180,c:["FK"]},"Australia/ACT":{a:"Australia/Sydney",r:1},"Australia/Adelaide":{u:570,d:630,c:["AU"]},"Australia/Brisbane":{u:600,c:["AU"]},"Australia/Broken_Hill":{u:570,d:630,c:["AU"]},"Australia/Canberra":{a:"Australia/Sydney",r:1},"Australia/Currie":{a:"Australia/Hobart",r:1},"Australia/Darwin":{u:570,c:["AU"]},"Australia/Eucla":{u:525,c:["AU"]},"Australia/Hobart":{u:600,d:660,c:["AU"]},"Australia/LHI":{a:"Australia/Lord_Howe",r:1},"Australia/Lindeman":{u:600,c:["AU"]},"Australia/Lord_Howe":{u:630,d:660,c:["AU"]},"Australia/Melbourne":{u:600,d:660,c:["AU"]},"Australia/NSW":{a:"Australia/Sydney",r:1},"Australia/North":{a:"Australia/Darwin",r:1},"Australia/Perth":{u:480,c:["AU"]},"Australia/Queensland":{a:"Australia/Brisbane",r:1},"Australia/South":{a:"Australia/Adelaide",r:1},"Australia/Sydney":{u:600,d:660,c:["AU"]},"Australia/Tasmania":{a:"Australia/Hobart",r:1},"Australia/Victoria":{a:"Australia/Melbourne",r:1},"Australia/West":{a:"Australia/Perth",r:1},"Australia/Yancowinna":{a:"Australia/Broken_Hill",r:1},"Brazil/Acre":{a:"America/Rio_Branco",r:1},"Brazil/DeNoronha":{a:"America/Noronha",r:1},"Brazil/East":{a:"America/Sao_Paulo",r:1},"Brazil/West":{a:"America/Manaus",r:1},CET:{u:60,d:120},CST6CDT:{u:-360,d:-300},"Canada/Atlantic":{a:"America/Halifax",r:1},"Canada/Central":{a:"America/Winnipeg",r:1},"Canada/Eastern":{a:"America/Toronto",c:["CA"],r:1},"Canada/Mountain":{a:"America/Edmonton",r:1},"Canada/Newfoundland":{a:"America/St_Johns",r:1},"Canada/Pacific":{a:"America/Vancouver",r:1},"Canada/Saskatchewan":{a:"America/Regina",r:1},"Canada/Yukon":{a:"America/Whitehorse",r:1},"Chile/Continental":{a:"America/Santiago",r:1},"Chile/EasterIsland":{a:"Pacific/Easter",r:1},Cuba:{a:"America/Havana",r:1},EET:{u:120,d:180},EST:{u:-300},EST5EDT:{u:-300,d:-240},Egypt:{a:"Africa/Cairo",r:1},Eire:{a:"Europe/Dublin",r:1},"Etc/GMT":{u:0},"Etc/GMT+0":{a:"Etc/GMT",r:1},"Etc/GMT+1":{u:-60},"Etc/GMT+10":{u:-600},"Etc/GMT+11":{u:-660},"Etc/GMT+12":{u:-720},"Etc/GMT+2":{u:-120},"Etc/GMT+3":{u:-180},"Etc/GMT+4":{u:-240},"Etc/GMT+5":{u:-300},"Etc/GMT+6":{u:-360},"Etc/GMT+7":{u:-420},"Etc/GMT+8":{u:-480},"Etc/GMT+9":{u:-540},"Etc/GMT-0":{a:"Etc/GMT",r:1},"Etc/GMT-1":{u:60},"Etc/GMT-10":{u:600},"Etc/GMT-11":{u:660},"Etc/GMT-12":{u:720},"Etc/GMT-13":{u:780},"Etc/GMT-14":{u:840},"Etc/GMT-2":{u:120},"Etc/GMT-3":{u:180},"Etc/GMT-4":{u:240},"Etc/GMT-5":{u:300},"Etc/GMT-6":{u:360},"Etc/GMT-7":{u:420},"Etc/GMT-8":{u:480},"Etc/GMT-9":{u:540},"Etc/GMT0":{a:"Etc/GMT",r:1},"Etc/Greenwich":{a:"Etc/GMT",r:1},"Etc/UCT":{a:"Etc/UTC",r:1},"Etc/UTC":{u:0},"Etc/Universal":{a:"Etc/UTC",r:1},"Etc/Zulu":{a:"Etc/UTC",r:1},"Europe/Amsterdam":{a:"Europe/Brussels",c:["NL"],r:1},"Europe/Andorra":{u:60,d:120,c:["AD"]},"Europe/Astrakhan":{u:240,c:["RU"]},"Europe/Athens":{u:120,d:180,c:["GR"]},"Europe/Belfast":{a:"Europe/London",c:["GB"],r:1},"Europe/Belgrade":{u:60,d:120,c:["RS","BA","HR","ME","MK","SI"]},"Europe/Berlin":{u:60,d:120,c:["DE","DK","NO","SE","SJ"]},"Europe/Bratislava":{a:"Europe/Prague",c:["SK"],r:1},"Europe/Brussels":{u:60,d:120,c:["BE","LU","NL"]},"Europe/Bucharest":{u:120,d:180,c:["RO"]},"Europe/Budapest":{u:60,d:120,c:["HU"]},"Europe/Busingen":{a:"Europe/Zurich",c:["DE"],r:1},"Europe/Chisinau":{u:120,d:180,c:["MD"]},"Europe/Copenhagen":{a:"Europe/Berlin",c:["DK"],r:1},"Europe/Dublin":{u:60,d:0,c:["IE"]},"Europe/Gibraltar":{u:60,d:120,c:["GI"]},"Europe/Guernsey":{a:"Europe/London",c:["GG"],r:1},"Europe/Helsinki":{u:120,d:180,c:["FI","AX"]},"Europe/Isle_of_Man":{a:"Europe/London",c:["IM"],r:1},"Europe/Istanbul":{u:180,c:["TR"]},"Europe/Jersey":{a:"Europe/London",c:["JE"],r:1},"Europe/Kaliningrad":{u:120,c:["RU"]},"Europe/Kiev":{a:"Europe/Kyiv",r:1},"Europe/Kirov":{u:180,c:["RU"]},"Europe/Kyiv":{u:120,d:180,c:["UA"]},"Europe/Lisbon":{u:0,d:60,c:["PT"]},"Europe/Ljubljana":{a:"Europe/Belgrade",c:["SI"],r:1},"Europe/London":{u:0,d:60,c:["GB","GG","IM","JE"]},"Europe/Luxembourg":{a:"Europe/Brussels",c:["LU"],r:1},"Europe/Madrid":{u:60,d:120,c:["ES"]},"Europe/Malta":{u:60,d:120,c:["MT"]},"Europe/Mariehamn":{a:"Europe/Helsinki",c:["AX"],r:1},"Europe/Minsk":{u:180,c:["BY"]},"Europe/Monaco":{a:"Europe/Paris",c:["MC"],r:1},"Europe/Moscow":{u:180,c:["RU"]},"Europe/Nicosia":{a:"Asia/Nicosia",r:1},"Europe/Oslo":{a:"Europe/Berlin",c:["NO","BV"],r:1},"Europe/Paris":{u:60,d:120,c:["FR","MC"]},"Europe/Podgorica":{a:"Europe/Belgrade",c:["ME"],r:1},"Europe/Prague":{u:60,d:120,c:["CZ","SK"]},"Europe/Riga":{u:120,d:180,c:["LV"]},"Europe/Rome":{u:60,d:120,c:["IT","SM","VA"]},"Europe/Samara":{u:240,c:["RU"]},"Europe/San_Marino":{a:"Europe/Rome",c:["SM"],r:1},"Europe/Sarajevo":{a:"Europe/Belgrade",c:["BA"],r:1},"Europe/Saratov":{u:240,c:["RU"]},"Europe/Simferopol":{u:180,c:["RU","UA"]},"Europe/Skopje":{a:"Europe/Belgrade",c:["MK"],r:1},"Europe/Sofia":{u:120,d:180,c:["BG"]},"Europe/Stockholm":{a:"Europe/Berlin",c:["SE"],r:1},"Europe/Tallinn":{u:120,d:180,c:["EE"]},"Europe/Tirane":{u:60,d:120,c:["AL"]},"Europe/Tiraspol":{a:"Europe/Chisinau",r:1},"Europe/Ulyanovsk":{u:240,c:["RU"]},"Europe/Uzhgorod":{a:"Europe/Kyiv",r:1},"Europe/Vaduz":{a:"Europe/Zurich",c:["LI"],r:1},"Europe/Vatican":{a:"Europe/Rome",c:["VA"],r:1},"Europe/Vienna":{u:60,d:120,c:["AT"]},"Europe/Vilnius":{u:120,d:180,c:["LT"]},"Europe/Volgograd":{u:180,c:["RU"]},"Europe/Warsaw":{u:60,d:120,c:["PL"]},"Europe/Zagreb":{a:"Europe/Belgrade",c:["HR"],r:1},"Europe/Zaporozhye":{a:"Europe/Kyiv",r:1},"Europe/Zurich":{u:60,d:120,c:["CH","DE","LI"]},Factory:{u:0},GB:{a:"Europe/London",c:["GB"],r:1},"GB-Eire":{a:"Europe/London",c:["GB"],r:1},GMT:{a:"Etc/GMT",r:1},"GMT+0":{a:"Etc/GMT",r:1},"GMT-0":{a:"Etc/GMT",r:1},GMT0:{a:"Etc/GMT",r:1},Greenwich:{a:"Etc/GMT",r:1},HST:{u:-600},Hongkong:{a:"Asia/Hong_Kong",r:1},Iceland:{a:"Africa/Abidjan",c:["IS"],r:1},"Indian/Antananarivo":{a:"Africa/Nairobi",c:["MG"],r:1},"Indian/Chagos":{u:360,c:["IO"]},"Indian/Christmas":{a:"Asia/Bangkok",c:["CX"],r:1},"Indian/Cocos":{a:"Asia/Yangon",c:["CC"],r:1},"Indian/Comoro":{a:"Africa/Nairobi",c:["KM"],r:1},"Indian/Kerguelen":{a:"Indian/Maldives",c:["TF","HM"],r:1},"Indian/Mahe":{a:"Asia/Dubai",c:["SC"],r:1},"Indian/Maldives":{u:300,c:["MV","TF"]},"Indian/Mauritius":{u:240,c:["MU"]},"Indian/Mayotte":{a:"Africa/Nairobi",c:["YT"],r:1},"Indian/Reunion":{a:"Asia/Dubai",c:["RE"],r:1},Iran:{a:"Asia/Tehran",r:1},Israel:{a:"Asia/Jerusalem",r:1},Jamaica:{a:"America/Jamaica",r:1},Japan:{a:"Asia/Tokyo",r:1},Kwajalein:{a:"Pacific/Kwajalein",r:1},Libya:{a:"Africa/Tripoli",r:1},MET:{u:60,d:120},MST:{u:-420},MST7MDT:{u:-420,d:-360},"Mexico/BajaNorte":{a:"America/Tijuana",r:1},"Mexico/BajaSur":{a:"America/Mazatlan",r:1},"Mexico/General":{a:"America/Mexico_City",r:1},NZ:{a:"Pacific/Auckland",c:["NZ"],r:1},"NZ-CHAT":{a:"Pacific/Chatham",r:1},Navajo:{a:"America/Denver",r:1},PRC:{a:"Asia/Shanghai",r:1},PST8PDT:{u:-480,d:-420},"Pacific/Apia":{u:780,c:["WS"]},"Pacific/Auckland":{u:720,d:780,c:["NZ","AQ"]},"Pacific/Bougainville":{u:660,c:["PG"]},"Pacific/Chatham":{u:765,d:825,c:["NZ"]},"Pacific/Chuuk":{a:"Pacific/Port_Moresby",c:["FM"],r:1},"Pacific/Easter":{u:-360,d:-300,c:["CL"]},"Pacific/Efate":{u:660,c:["VU"]},"Pacific/Enderbury":{a:"Pacific/Kanton",r:1},"Pacific/Fakaofo":{u:780,c:["TK"]},"Pacific/Fiji":{u:720,c:["FJ"]},"Pacific/Funafuti":{a:"Pacific/Tarawa",c:["TV"],r:1},"Pacific/Galapagos":{u:-360,c:["EC"]},"Pacific/Gambier":{u:-540,c:["PF"]},"Pacific/Guadalcanal":{u:660,c:["SB","FM"]},"Pacific/Guam":{u:600,c:["GU","MP"]},"Pacific/Honolulu":{u:-600,c:["US","UM"]},"Pacific/Johnston":{a:"Pacific/Honolulu",c:["UM"],r:1},"Pacific/Kanton":{u:780,c:["KI"]},"Pacific/Kiritimati":{u:840,c:["KI"]},"Pacific/Kosrae":{u:660,c:["FM"]},"Pacific/Kwajalein":{u:720,c:["MH"]},"Pacific/Majuro":{a:"Pacific/Tarawa",c:["MH"],r:1},"Pacific/Marquesas":{u:-570,c:["PF"]},"Pacific/Midway":{a:"Pacific/Pago_Pago",c:["UM"],r:1},"Pacific/Nauru":{u:720,c:["NR"]},"Pacific/Niue":{u:-660,c:["NU"]},"Pacific/Norfolk":{u:660,d:720,c:["NF"]},"Pacific/Noumea":{u:660,c:["NC"]},"Pacific/Pago_Pago":{u:-660,c:["AS","UM"]},"Pacific/Palau":{u:540,c:["PW"]},"Pacific/Pitcairn":{u:-480,c:["PN"]},"Pacific/Pohnpei":{a:"Pacific/Guadalcanal",c:["FM"],r:1},"Pacific/Ponape":{a:"Pacific/Guadalcanal",c:["FM"],r:1},"Pacific/Port_Moresby":{u:600,c:["PG","AQ","FM"]},"Pacific/Rarotonga":{u:-600,c:["CK"]},"Pacific/Saipan":{a:"Pacific/Guam",c:["MP"],r:1},"Pacific/Samoa":{a:"Pacific/Pago_Pago",c:["AS"],r:1},"Pacific/Tahiti":{u:-600,c:["PF"]},"Pacific/Tarawa":{u:720,c:["KI","MH","TV","UM","WF"]},"Pacific/Tongatapu":{u:780,c:["TO"]},"Pacific/Truk":{a:"Pacific/Port_Moresby",c:["FM"],r:1},"Pacific/Wake":{a:"Pacific/Tarawa",c:["UM"],r:1},"Pacific/Wallis":{a:"Pacific/Tarawa",c:["WF"],r:1},"Pacific/Yap":{a:"Pacific/Port_Moresby",c:["FM"],r:1},Poland:{a:"Europe/Warsaw",r:1},Portugal:{a:"Europe/Lisbon",r:1},ROC:{a:"Asia/Taipei",r:1},ROK:{a:"Asia/Seoul",r:1},Singapore:{a:"Asia/Singapore",c:["SG"],r:1},Turkey:{a:"Europe/Istanbul",r:1},UCT:{a:"Etc/UTC",r:1},"US/Alaska":{a:"America/Anchorage",r:1},"US/Aleutian":{a:"America/Adak",r:1},"US/Arizona":{a:"America/Phoenix",c:["US"],r:1},"US/Central":{a:"America/Chicago",r:1},"US/East-Indiana":{a:"America/Indiana/Indianapolis",r:1},"US/Eastern":{a:"America/New_York",r:1},"US/Hawaii":{a:"Pacific/Honolulu",c:["US"],r:1},"US/Indiana-Starke":{a:"America/Indiana/Knox",r:1},"US/Michigan":{a:"America/Detroit",r:1},"US/Mountain":{a:"America/Denver",r:1},"US/Pacific":{a:"America/Los_Angeles",r:1},"US/Samoa":{a:"Pacific/Pago_Pago",c:["AS"],r:1},UTC:{a:"Etc/UTC",r:1},Universal:{a:"Etc/UTC",r:1},"W-SU":{a:"Europe/Moscow",r:1},WET:{u:0,d:60},Zulu:{a:"Etc/UTC",r:1}},lf={countries:Gye,timezones:qye},Y1;function Kye(e,t){var n=e.countries[t];if(!n)return null;var r=Yye(e)[t]||{};return{id:t,name:n,timezones:r.current||[],allTimezones:r.all||[]}}function Yye(e){return Y1||(Y1=Xye(e)),Y1}function Xye(e){return Object.keys(e.timezones).reduce(function(t,n){var r=e.timezones[n],o=r.c,a=r.a,i=e.timezones[a]||{},l=o||i.c;return l&&l.forEach(function(c){t[c]||Object.assign(t,Hv({},c,{current:[],all:[]})),r.r===void 0&&t[c].current.push(n),t[c].all.push(n)}),t},{})}function Jye(e,t){var n=e.timezones[t];if(!n)return null;var r=n.a,o=r===void 0?null:r,a=o?e.timezones[o]:{},i=Rp(Rp({},a),e.timezones[t]),l=i.c||[],c=i.u,u=Number.isInteger(i.d)?i.d:c,d={name:t,countries:l,utcOffset:c,utcOffsetStr:cR(c),dstOffset:u,dstOffsetStr:cR(u),aliasOf:o};return n.r&&(d.deprecated=!0),d}function cR(e){var t=Math.floor(e/60),n=e%60,r=e<0?"-":"+";return"".concat(r).concat(uR(t),":").concat(uR(n))}function uR(e){var t=Math.abs(e),n=t<10?"0":"";return"".concat(n).concat(t)}var Qye=["allTimezones"],Zye=Object.keys(lf.timezones).length,uw={},zd={},wL=0;function e1e(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Object.keys(lf.countries).reduce(function(t,n){return Object.assign(t,Hv({},n,Vv(n,e)))},{})}function t1e(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Zye!==wL&&Object.keys(lf.timezones).forEach(Gv),i1e(zd,e)}function Vv(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return uw[e]||n1e(Kye(lf,e)),s1e(uw[e],t)}function n1e(e){e&&(uw[e.id]=e)}function Gv(e){return zd[e]||r1e(Jye(lf,e)),zd[e]?Rp({},zd[e]):null}function r1e(e){e&&(zd[e.name]=e,wL=Object.keys(e).length)}function SL(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=Gv(e)||{},r=n.countries||[];return r.map(function(o){return Vv(o,t)})}function o1e(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=SL(e,t),r=jye(n,1),o=r[0];return o||null}function a1e(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=Vv(e,t);if(!n)return null;var r=n.timezones||[];return r.map(Gv)}function i1e(e,t){var n=t||{},r=n.deprecated;return r===!0?e:Object.keys(e).reduce(function(o,a){return e[a].deprecated||Object.assign(o,Hv({},a,e[a])),o},{})}function s1e(e,t){if(!e)return null;var n=t||{},r=n.deprecated;e.allTimezones;var o=zye(e,Qye),a=r?e.allTimezones:e.timezones;return Rp(Rp({},o),{},{timezones:a})}var l1e={getCountry:Vv,getTimezone:Gv,getAllCountries:e1e,getAllTimezones:t1e,getTimezonesForCountry:a1e,getCountriesForTimezone:SL,getCountryForTimezone:o1e};const c1e=C("div")(({theme:e})=>({display:"flex",flexDirection:"row",marginBottom:e.spacing(1),alignItems:"center",gap:e.spacing(1)})),u1e=({setValue:e,value:t,error:n,setError:r})=>{const o=Object.values(l1e.getAllTimezones({deprecated:!1})).map(u=>({key:u.name,label:`${u.name}`,utcOffset:u.utcOffsetStr})),{timeZone:a}=Intl.DateTimeFormat().resolvedOptions(),[i,l]=p.useState(t||""),c=p.useMemo(()=>{const u=o.find(d=>d.key===a);return u!=null?`${u.key} (UTC ${u.utcOffset})`:"The time shown is in your local time zone according to your browser."},[o,a]);return t?T(ke,{children:[s(sf,{children:"Select a date"}),T(c1e,{children:[s(_r,{id:"date",label:"Date",type:"datetime-local",value:Que(i),onChange:u=>{r("");const d=xO(u.target.value),f=d==null?void 0:d.toISOString();f&&l(f),f&&e(f)},InputLabelProps:{shrink:!0},error:Boolean(n),errorText:n,required:!0}),s("p",{children:c})]})]}):null},Da=({text:e,maxWidth:t,maxLength:n,className:r,...o})=>s(X,{condition:((e==null?void 0:e.length)??0)>n,show:s(_t,{title:e,arrow:!0,children:s("span",{"data-loading":!0,className:r,style:{maxWidth:`${t}px`,textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap",display:"inline-block",verticalAlign:"middle"},...o,children:e})}),elseShow:s("span",{className:r,children:e})}),jd=e=>{const t=Number(ls(e));return Number.isFinite(t)?t:0},ls=e=>String(e??"").trim(),Qi=e=>ls(e).split(",").map(t=>t.trim()).filter(Boolean),xL=Li()(e=>({valueChip:{margin:"0 0.5rem 0.5rem 0"},chipValue:{whiteSpace:"pre"},inputContainer:{display:"flex",alignItems:"center",[e.breakpoints.down(700)]:{flexDirection:"column",alignItems:"flex-start"}},inputInnerContainer:{minWidth:"300px",[e.breakpoints.down(700)]:{minWidth:"100%"}},input:{width:"100%",margin:"1rem 0"},button:{marginLeft:"1rem",[e.breakpoints.down(700)]:{marginLeft:0,marginBottom:"0.5rem"}},valuesContainer:{marginTop:"1rem"}})),d1e="Enter",dR=({values:e,removeValue:t,setValues:n,error:r,setError:o})=>{const[a,i]=p.useState(""),{classes:l}=xL(),c=d=>{d.key===d1e&&(d.preventDefault(),u())},u=()=>{const d=f1e([...e,...Qi(a)]);d.length===0?o("values cannot be empty"):d.some(f=>f.length>100)?o("values cannot be longer than 100 characters"):(o(""),i(""),n(d))};return T("div",{children:[s(sf,{style:{marginBottom:0},children:"Set values (maximum 100 char length per value)"}),T("div",{className:l.inputContainer,children:[s("div",{className:l.inputInnerContainer,children:s(_r,{onKeyPress:c,label:"Values",name:"values",value:a,onFocus:()=>{o("")},onChange:d=>i(d.target.value),placeholder:"value1, value2, value3...",className:l.input,error:Boolean(r),errorText:r})}),s(Ze,{className:l.button,variant:"outlined",color:"secondary",onClick:()=>u(),children:"Add values"})]}),s("div",{className:l.valuesContainer,children:s(p1e,{values:e,removeValue:t})})]})},p1e=({values:e,removeValue:t})=>{const{classes:n}=xL();return s(ke,{children:e.map((r,o)=>s(To,{label:s(Da,{text:r,maxLength:35,maxWidth:"100",className:n.chipValue}),onDelete:()=>t(o),className:n.valueChip},`${r}-${o}`))})},f1e=e=>Array.from(new Set(e)),i2=({filter:e,setFilter:t})=>T("div",{style:{display:"flex",alignItems:"center"},children:[s("div",{style:{width:"300px"},children:s(mn,{label:"Search",name:"search",value:e,onChange:n=>t(n.target.value),placeholder:"Filter values",style:{width:"100%",margin:"1rem 0"},variant:"outlined",size:"small",InputProps:{startAdornment:s(o4,{position:"start",children:s(Sx,{})})}})}),s(X,{condition:Boolean(e),show:s(To,{style:{marginLeft:"1rem"},label:`filter active: ${e}`,onDelete:()=>t("")})})]}),h1e=Li()(e=>({container:{display:"inline-block",wordBreak:"break-word"},value:{lineHeight:1.33,fontSize:e.fontSizes.smallBody},description:{lineHeight:1.33,fontSize:e.fontSizes.smallerBody,color:e.palette.grey[700]}})),CL=({legal:e,control:t})=>{const{classes:n}=h1e();return s("div",{className:n.container,children:s(Tr,{value:e.value,control:t,label:T(ke,{children:[s("div",{className:n.value,children:e.value}),s("div",{className:n.description,children:e.description})]})})})},EL=(e,t)=>e.filter(n=>n.value.includes(t)),pR=e=>e.reduce((t,n)=>(t[n]||(t[n]=!0),t),{}),fR=({legalValues:e,values:t,setValues:n,error:r,setError:o})=>{const[a,i]=p.useState(""),l=EL(e,a),[c,u]=p.useState(()=>pR(t)),{classes:d}=ef();p.useEffect(()=>{u(pR(t))},[t,u]);const f=h=>{if(o(""),c[h]){const m=t.findIndex(g=>g===h),y=[...t];y.splice(m,1),n(y);return}n([...t,h])};return T(ke,{children:[s(sf,{children:"Select values from a predefined set"}),s(X,{condition:e.length>100,show:s(i2,{filter:a,setFilter:i})}),l.map(h=>s(CL,{legal:h,control:s(Rs,{checked:Boolean(c[h.value]),onChange:()=>f(h.value),name:h.value,color:"primary"})},h.value)),s(X,{condition:Boolean(r),show:s("p",{className:d.error,children:r})})]})},hR=({setValue:e,value:t,type:n,legalValues:r,error:o,setError:a})=>{const[i,l]=p.useState(""),{classes:c}=ef(),u=EL(r,i);return T(ke,{children:[T(sf,{children:["Add a single ",n.toLowerCase()," value"]}),s(X,{condition:Boolean(r.length>100),show:s(i2,{filter:i,setFilter:l})}),s(X,{condition:Boolean(r.length),show:s(Pi,{component:"fieldset",children:s(hx,{"aria-label":"selected-value",name:"selected",value:t,onChange:d=>{a(""),e(d.target.value)},children:u.map(d=>s(CL,{legal:d,control:s(ol,{})},d.value))})}),elseShow:s("p",{children:"No valid legal values available for this operator."})}),s(X,{condition:Boolean(o),show:s("p",{className:c.error,children:o})})]})},m1e=Li()(e=>({singleValueContainer:{maxWidth:"300px",marginTop:"-1rem"},singleValueInput:{width:"100%",margin:"1rem 0"}})),mR=({setValue:e,value:t,type:n,error:r,setError:o})=>{const{classes:a}=m1e();return T(ke,{children:[T(sf,{children:["Add a single ",n.toLowerCase()," value"]}),s("div",{className:a.singleValueContainer,children:s(_r,{label:n,name:"value",value:t||"",onChange:i=>{o(""),e(i.target.value.trim())},onFocus:()=>o(""),placeholder:`Enter a single ${n} value`,className:a.singleValueInput,error:Boolean(r),errorText:r})})]})},g1e=({input:e,contextDefinition:t,localConstraint:n,setValue:r,setValues:o,setError:a,removeValue:i,error:l})=>s(ke,{children:(()=>{var u;switch(e){case cw:return s(fR,{legalValues:t.legalValues||[],values:n.values||[],setValues:o,error:l,setError:a});case pL:return s(ke,{children:s(fR,{legalValues:t.legalValues||[],values:n.values||[],setValues:o,error:l,setError:a})});case fL:return s(ke,{children:s(hR,{setValue:r,value:n.value,type:"number",legalValues:((u=t.legalValues)==null?void 0:u.filter(d=>Number(d.value)))||[],error:l,setError:a})});case hL:return s(ke,{children:s(hR,{setValue:r,value:n.value,type:"semver",legalValues:t.legalValues||[],error:l,setError:a})});case mL:return s(u1e,{value:n.value,setValue:r,error:l,setError:a});case gL:return s(dR,{values:n.values||[],removeValue:i,setValues:o,error:l,setError:a});case vL:return s(ke,{children:s(dR,{values:n.values||[],removeValue:i,setValues:o,error:l,setError:a})});case yL:return s(mR,{setValue:r,value:n.value,type:"number",error:l,setError:a});case bL:return s(mR,{setValue:r,value:n.value,type:"semver",error:l,setError:a})}})()}),TL="cancel",gR="save",vR=(e,t)=>e.find(r=>r.name===t)||{name:"",description:"",createdAt:"",sortOrder:1,stickiness:!1},v1e=C("div")({padding:0,margin:0,width:"100%"}),y1e=C(nx)(({theme:e})=>({border:`1px solid ${e.palette.dividerAlternative}`,borderRadius:e.shape.borderRadiusMedium,backgroundColor:e.palette.constraintAccordion.editBackground,boxShadow:"none",margin:0,"& .expanded":{"&:before":{opacity:"0 !important"}}})),b1e=C(ox)(({theme:e})=>({border:"none",padding:e.spacing(.5,3),"&:hover .valuesExpandLabel":{textDecoration:"underline"}})),w1e=C(rx)(({theme:e})=>({borderTop:`1px dashed ${e.palette.divider}`,display:"flex",flexDirection:"column",padding:0})),S1e=({constraint:e,compact:t,onCancel:n,onSave:r,onDelete:o})=>{const[a,i]=p.useState($_(e)),{context:l}=Il(),[c,u]=p.useState(vR(l,a.contextName)),{validateConstraint:d}=gu(),[f,h]=p.useState(!1),[m,y]=p.useState("");p.useEffect(()=>{h(!0)},[]),p.useEffect(()=>{u(vR(l,a.contextName))},[a.contextName,l]);const g=p.useCallback(F=>{i(U=>({...U,contextName:F,values:[],value:""}))},[]),v=p.useCallback(F=>{i(U=>({...U,operator:F,values:[],value:""}))},[]),b=p.useCallback(F=>{i(U=>({...U,values:F}))},[]),w=p.useCallback(F=>{i(U=>({...U,value:F}))},[]),x=()=>{i(F=>({...F,inverted:!F.inverted}))},E=p.useCallback(()=>{i(F=>({...F,caseInsensitive:!F.caseInsensitive}))},[]),A=p.useCallback(F=>{const U=[...a.values];U.splice(F,1),b(U)},[a,b]),k=()=>{h(!1)},_=()=>{const F=Array.isArray(a.values)&&Boolean(a.values.length>0),U=Boolean(a.value);return F||U?(P(""),!0):(P("You must provide a value for the constraint"),!1)},$=async()=>{if(!_())return;const[U,Y]=O();if(U||P(Y),U)try{await d(a),P(""),y(gR),k();return}catch(V){P(ft(V))}},{input:L,validator:O,setError:P,error:D}=Dye({contextDefinition:c,localConstraint:a});return p.useEffect(()=>{P(""),i(F=>$_(F))},[a.operator,a.contextName,P]),s(v1e,{children:T(y1e,{expanded:f,TransitionProps:{onExited:()=>{m===TL?(y(""),n()):m===gR&&(y(""),r(a))}},children:[s(b1e,{children:s($me,{localConstraint:a,setLocalConstraint:i,setContextName:g,setOperator:v,action:m,compact:t,setInvertedOperator:x,setCaseInsensitive:E,onDelete:o})}),s(w1e,{children:s(pme,{localConstraint:a,setValues:b,setValue:w,triggerTransition:k,setAction:y,onSubmit:$,children:s(g1e,{setValues:b,setValue:w,setError:P,localConstraint:a,input:L,error:D,contextDefinition:c,removeValue:A})})})]})})},kL=(e,t)=>e.value&&e.contextName===_p?bv(e.value,t.locale):e.value,x1e=C(Da)({whiteSpace:"pre"}),C1e=C(To)(({theme:e})=>({margin:e.spacing(0,1,1,0)})),E1e=({values:e})=>{const[t,n]=p.useState("");return!e||e.length===0?null:T(ke,{children:[s(X,{condition:e.length>20,show:s(i2,{filter:t,setFilter:n})}),e.filter(r=>r.includes(t)).map((r,o)=>s(C1e,{label:s(x1e,{maxWidth:"400",text:r,maxLength:50})},`${r}-${o}`))]})},T1e=C("div")(({theme:e})=>({display:"flex",alignItems:"center",[e.breakpoints.down(600)]:{flexDirection:"column"}})),k1e=C("p")(({theme:e})=>({marginRight:e.spacing(1.5),[e.breakpoints.down(600)]:{marginBottom:e.spacing(1.5),marginRight:0}})),A1e=C(To)(({theme:e})=>({margin:e.spacing(0,1,1,0)})),_1e=({value:e,operator:t})=>e?T(T1e,{children:[T(k1e,{children:["Value must be ",t]})," ",s(A1e,{label:s(Da,{maxWidth:"400",text:e,maxLength:50})})]}):null,R1e=C("div")(({theme:e})=>({padding:e.spacing(2,0),maxHeight:"400px",overflowY:"auto"})),P1e=({constraint:e})=>{const{locationSettings:t}=ii();return s("div",{children:T(R1e,{children:[s(E1e,{values:e.values}),s(_1e,{value:kL(e,t),operator:e.operator})]})})},I1e=C("div")(({theme:e})=>({padding:e.spacing(.5,1.5),borderRadius:e.shape.borderRadius,backgroundColor:e.palette.constraintAccordion.operatorBackground,lineHeight:1.25})),$1e=C("div")(({theme:e})=>({fontSize:e.fontSizes.smallBody,lineHeight:17/14})),O1e=C("div")(({theme:e})=>({fontSize:e.fontSizes.smallerBody,color:e.palette.neutral.main})),L1e=({constraint:e,hasPrefix:t})=>{const n=e.operator,r=iw(e.operator);return T(I1e,{style:{borderTopLeftRadius:t?0:void 0,borderBottomLeftRadius:t?0:void 0,paddingLeft:t?0:void 0},children:[s($1e,{children:n}),s(O1e,{children:r})]})},AL=C("div")(({theme:e})=>({backgroundColor:e.palette.grey[200],width:24,display:"flex",alignItems:"center",justifyContent:"center",alignSelf:"stretch",color:e.palette.primary.main,marginLeft:e.spacing(1),borderRadius:e.shape.borderRadius})),N1e=C(AL)(()=>({marginLeft:0,borderTopRightRadius:0,borderBottomRightRadius:0})),yR=p.forwardRef(({isPrefix:e,...t},n)=>s(X,{condition:Boolean(e),show:()=>s(N1e,{ref:n,...t}),elseShow:()=>s(AL,{ref:n,...t})})),M1e=C("div")(({theme:e})=>({display:"flex",alignItems:"stretch",margin:"auto 0"})),D1e=C("div")(({theme:e})=>({minWidth:"152px",position:"relative",[e.breakpoints.down("sm")]:{paddingRight:0}})),B1e=({constraint:e})=>T(M1e,{children:[s(X,{condition:Boolean(e.inverted),show:s(_t,{title:"Operator is negated",arrow:!0,children:s(Me,{sx:{display:"flex"},children:s(yR,{isPrefix:!0,children:s(sw,{})})})})}),s(D1e,{children:s(L1e,{constraint:e,hasPrefix:Boolean(e.inverted)})}),s(X,{condition:!Boolean(e.caseInsensitive)&&wn(xi,e.operator),show:s(_t,{title:"Case sensitive is active",arrow:!0,children:s(yR,{children:s(oL,{})})})})]}),F1e=C(To)(({theme:e})=>({margin:"auto 0",marginLeft:e.spacing(1),[e.breakpoints.down("sm")]:{margin:e.spacing(1,0)}})),z1e=C("div")(({theme:e})=>({display:"flex",alignItems:"stretch",margin:"auto 0"})),j1e=({constraint:e,allowExpand:t})=>{const{locationSettings:n}=ii();return p.useEffect(()=>{t(!1)},[t]),s(z1e,{children:s(F1e,{label:kL(e,n)})})},U1e=C("span")(({theme:e})=>({display:"-webkit-box",WebkitLineClamp:2,WebkitBoxOrient:"vertical",overflow:"hidden",wordBreak:"break-word",fontSize:e.fontSizes.smallBody,margin:"auto 0",[e.breakpoints.down("sm")]:{margin:e.spacing(1,0),textAlign:"center"}})),W1e=C("div")(({theme:e})=>({display:"flex",alignItems:"stretch",margin:"auto 0"})),H1e=C("div")(({theme:e})=>({display:"flex",justifyContent:"stretch",margin:"auto 0",flexDirection:"column",marginLeft:e.spacing(1),[e.breakpoints.down("sm")]:{marginLeft:0}})),V1e=C("p")(({theme:e})=>({fontSize:e.fontSizes.smallBody,marginTop:e.spacing(.5),color:e.palette.primary.dark,[e.breakpoints.down("sm")]:{textAlign:"center"}})),G1e=({constraint:e,expanded:t,allowExpand:n,maxLength:r})=>{var l;const[o,a]=p.useState(!1),i=p.useMemo(()=>{var c;return(c=e==null?void 0:e.values)==null?void 0:c.map(u=>u).join(", ")},[e]);return p.useEffect(()=>{i&&(n(((i==null?void 0:i.length)??0)>r),a(((i==null?void 0:i.length)??0)>r))},[i,r,n,a]),s(W1e,{children:T(H1e,{children:[s(U1e,{children:i}),s(X,{condition:o,show:s(V1e,{className:"valuesExpandLabel",children:t?"View less":`View all (${(l=e==null?void 0:e.values)==null?void 0:l.length})`})})]})})},q1e=C("span")(({theme:e})=>({display:"-webkit-box",WebkitLineClamp:3,WebkitBoxOrient:"vertical",overflow:"hidden",maxWidth:"100px",minWidth:"100px",marginRight:"10px",marginTop:"auto",marginBottom:"auto",wordBreak:"break-word",fontSize:e.fontSizes.smallBody,[e.breakpoints.down(710)]:{textAlign:"center",padding:e.spacing(1,0),marginRight:"inherit",maxWidth:"inherit"}})),K1e=C("div")(({theme:e})=>({display:"flex",width:"100%",justifyContent:"space-between",borderRadius:e.spacing(1)})),Y1e=C("div")(({theme:e})=>({display:"flex",alignItems:"stretch",marginLeft:e.spacing(1),[e.breakpoints.down("sm")]:{marginLeft:0,flexDirection:"column",alignItems:"center",width:"100%"}})),X1e=({constraint:e,singleValue:t,allowExpand:n,expanded:r,maxLength:o=112})=>s(K1e,{children:T(Y1e,{children:[s(_t,{title:e.contextName,arrow:!0,children:s(q1e,{children:e.contextName})}),s(B1e,{constraint:e}),s(X,{condition:t,show:s(j1e,{constraint:e,allowExpand:n}),elseShow:s(G1e,{constraint:e,expanded:r,allowExpand:n,maxLength:o})})]})}),J1e=Nr("div")(({theme:e})=>({display:"flex",alignItems:"center",width:"100%",[e.breakpoints.down("sm")]:{flexDirection:"column",alignItems:"center",position:"relative"}})),Q1e=({constraint:e,onEdit:t,onDelete:n,singleValue:r,allowExpand:o,expanded:a,compact:i})=>T(J1e,{children:[s(eL,{compact:i}),s(X1e,{constraint:e,singleValue:r,allowExpand:o,expanded:a}),s(aL,{onEdit:t,onDelete:n})]}),Z1e=C(nx)(({theme:e})=>({border:`1px solid ${e.palette.dividerAlternative}`,borderRadius:e.shape.borderRadiusMedium,backgroundColor:e.palette.constraintAccordion.background,boxShadow:"none",margin:0,"& .root":{"&:before":{opacity:"0 !important"}}})),e0e=C(ox)(({theme:e})=>({"& .root":{border:"none",padding:e.spacing(.5,3),"&:hover .valuesExpandLabel":{textDecoration:"underline"}}})),t0e=C(rx)(({theme:e})=>({borderTop:`1px dashed ${e.palette.divider}`,display:"flex",flexDirection:"column"})),n0e=C("div")({display:"flex",flexDirection:"column",width:"100%"}),r0e=({constraint:e,onEdit:t,onDelete:n,sx:r=void 0,compact:o=!1,renderAfter:a})=>{const[i,l]=p.useState(!0),[c,u]=p.useState(!1),d=wn([...kc,...Tc,...Jo],e.operator);return T(Z1e,{expanded:c,sx:r,children:[s(e0e,{expandIcon:null,onClick:()=>{i&&u(!c)},sx:{cursor:i?"pointer":"default!important","&:hover":{cursor:i?"pointer":"default!important"}},children:T(n0e,{children:[s(Q1e,{constraint:e,onEdit:t,onDelete:n,singleValue:d,allowExpand:l,expanded:c,compact:o}),a]})}),s(t0e,{children:s(P1e,{constraint:e})})]})},o0e=({constraint:e,compact:t=!1,editing:n,onEdit:r,onCancel:o,onDelete:a,onSave:i})=>e?s(X,{condition:Boolean(n&&i),show:s(S1e,{constraint:e,onCancel:o,onSave:i,onDelete:a,compact:t}),elseShow:s(r0e,{constraint:e,onEdit:r,onDelete:a})}):null,a0e=e=>{const t=p.useRef(e??new WeakMap),[,n]=p.useState(0),r=p.useCallback((a,i)=>{t.current.set(a,i),n(l=>l+1)},[]),o=p.useCallback(a=>t.current.get(a),[]);return p.useMemo(()=>({set:r,get:o}),[r,o])},_L=e=>(X1.has(e)||(bR++,X1.set(e,bR)),X1.get(e)),X1=new WeakMap;let bR=0;const i0e=e=>{const t=tL(e)[0],n=wn(Jo,t)?new Date().toISOString():"";return{contextName:e,operator:t,value:n,values:[],caseInsensitive:!1,inverted:!1}},RL=C("div")(({theme:e})=>({padding:e.spacing(.75,1),color:e.palette.text.primary,fontSize:e.fontSizes.smallerBody,backgroundColor:e.palette.secondaryContainer,borderRadius:e.shape.borderRadius,position:"absolute",zIndex:e.zIndex.fab,top:"50%",left:e.spacing(2),transform:"translateY(-50%)",lineHeight:1})),s0e=C(RL)(({theme:e})=>({top:"50%",left:"50%",transform:"translate(-50%, -50%)",backgroundColor:e.palette.activityIndicators.primary,border:`1px solid ${e.palette.primary.border}`,borderRadius:e.shape.borderRadiusLarge,padding:e.spacing(.75,1.5)})),s2=({text:e})=>{const t=on();return s(Me,{sx:{height:t.spacing(e==="AND"?1:1.5),position:"relative",width:"100%"},children:s(X,{condition:e==="AND",show:()=>s(RL,{children:e}),elseShow:()=>s(s0e,{children:e})})})},PL="constraintAccordionListId",l0e=C("div")({width:"100%",display:"flex",flexDirection:"column"}),c0e=C(_t)(({theme:e})=>({marginLeft:e.spacing(.75),height:e.spacing(1.5)})),u0e=C(wx)(({theme:e})=>({fill:e.palette.tertiary.dark,[e.breakpoints.down(860)]:{display:"none"}})),d0e=C("p")(({theme:e})=>({marginBottom:e.spacing(1),color:e.palette.text.secondary})),p0e=C("div")(({theme:e})=>({marginTop:e.spacing(1),marginBottom:e.spacing(1),color:e.palette.text.secondary,display:"flex"})),qv=p.forwardRef(({constraints:e,setConstraints:t,showCreateButton:n,showLabel:r=!0},o)=>{const a=a0e(),{context:i}=Il(),l=t&&(m=>{const y=i0e(m);a.set(y,{editing:!0,new:!0}),t(g=>[...g,y])});p.useImperativeHandle(o,()=>({addConstraint:l}));const c=l&&(()=>{l(i[0].name)}),u=t&&(m=>{a.set(m,{editing:!0})}),d=t&&(m=>{const y=e[m];a.set(y,{}),t(Ko(g=>{g.splice(m,1)}))}),f=t&&((m,y)=>{a.set(y,{}),t(Ko(g=>{g[m]=y}))}),h=m=>{var g;const y=e[m];(g=a.get(y))!=null&&g.new&&(d==null||d(m)),a.set(y,{})};return i.length===0?null:T(l0e,{id:PL,children:[s(X,{condition:e&&e.length>0&&r,show:s(d0e,{children:"Constraints"})}),e.map((m,y)=>{var g;return T(p.Fragment,{children:[s(X,{condition:y>0,show:s(s2,{text:"AND"})}),s(o0e,{constraint:m,onEdit:u&&u.bind(null,m),onCancel:h.bind(null,y),onDelete:d&&d.bind(null,y),onSave:f&&f.bind(null,y),editing:Boolean((g=a.get(m))==null?void 0:g.editing),compact:!0})]},_L(m))}),s(X,{condition:Boolean(n&&c),show:T("div",{children:[T(p0e,{children:[s("p",{children:"Add any number of constraints"}),s(c0e,{title:"Help",arrow:!0,children:s("a",{href:"https://docs.getunleash.io/reference/strategy-constraints",target:"_blank",rel:"noopener noreferrer",children:s(u0e,{})})})]}),s(Ze,{type:"button",onClick:c,variant:"outlined",color:"secondary",children:"Add constraint"})]})})]})}),f0e=Li()(e=>({inputRoot:{height:48,borderTopLeftRadius:0,borderBottomLeftRadius:0,borderTopRightRadius:50,borderBottomRightRadius:50,"& fieldset":{borderColor:e.palette.grey[300],borderLeftColor:"transparent"},"&.Mui-focused .MuiOutlinedInput-notchedOutline":{borderWidth:1}}})),h0e=C("div")(({theme:e})=>({display:"flex",alignItems:"center",borderRadius:e.spacing(2),'& .MuiInputLabel-root[data-shrink="false"]':{top:3}})),m0e=C("div",{shouldForwardProp:e=>!e.startsWith("$")})(({theme:e,$disabled:t})=>({background:t?e.palette.primary.light:e.palette.featureSegmentSearchBackground,height:"48px",width:"48px",display:"flex",alignItems:"center",justifyContent:"center",paddingLeft:6,borderTopLeftRadius:"40px",borderBottomLeftRadius:"40px",color:e.palette.text.tertiaryContrast})),g0e=C(av)({flex:1}),IL=({label:e,options:t,value:n=[],onChange:r,disabled:o})=>{const{classes:a}=f0e(),i=l=>s(mn,{...l,variant:"outlined",label:e});return T(h0e,{children:[s(m0e,{$disabled:Boolean(o),"aria-hidden":!0,children:s(Sx,{})}),s(g0e,{classes:{inputRoot:a.inputRoot},options:t,value:n,popupIcon:s(TZ,{titleAccess:"Toggle"}),onChange:(l,c)=>r(c||[]),renderInput:i,getOptionLabel:l=>l.label,disabled:o,size:"small",multiple:!0})]})},Ol=()=>{const{uiConfig:e}=Lt();return{segmentValuesLimit:e.segmentValuesLimit,strategySegmentsLimit:e.strategySegmentsLimit}},v0e=()=>{const{segmentValuesLimit:e}=Ol();return typeof e>"u"?null:T(Zt,{severity:"warning",children:["Segments is an experimental feature, currently limited to at most"," ",e," values. ",s($L,{})]})},y0e=e=>{const{segmentValuesLimit:t}=Ol();return typeof t>"u"?null:T(Zt,{severity:"error",children:["Segments are limited to at most ",t," values. This segment currently has ",e.values," ",e.values===1?"value":"values","."]})},b0e=()=>{const{strategySegmentsLimit:e}=Ol();return typeof e>"u"?null:T(Zt,{severity:"warning",children:["Strategies are limited to ",e," segments."," ",s($L,{})]})},$L=()=>T(ke,{children:["Please"," ",s("a",{href:"https://slack.unleash.run",target:"_blank",rel:"noreferrer",style:{color:"inherit"},children:"get in touch"})," ","if you would like this limit increased."]}),OL="https://docs.getunleash.io/reference/segments",l2=e=>p.useMemo(()=>e.map(t=>t.values).reduce((t,n)=>t+((n==null?void 0:n.length)??0),0),[e]),w0e=C("div")(({theme:e})=>({display:"flex",flexDirection:"column",height:"100%"})),S0e=C("div")(({theme:e})=>({marginBottom:"1.5rem"})),J1=C("p")(({theme:e})=>({marginBottom:"1rem"})),x0e=C("div")(({theme:e})=>({marginTop:"1rem",borderBottom:`1px solid ${e.palette.grey[300]}`,paddingBottom:"2rem"})),C0e=C("div")(({theme:e})=>({marginTop:"1.5rem"})),E0e=C("div")(({theme:e})=>({display:"flex",flexDirection:"column",alignItems:"center",marginTop:e.spacing(12)})),T0e=C("p")(({theme:e})=>({fontSize:e.fontSizes.bodySize,color:e.palette.tertiary.dark,maxWidth:515,marginBottom:e.spacing(2.5),wordBreak:"break-word",whiteSpace:"normal",textAlign:"center"})),k0e=C("div")(({theme:e})=>({marginBlock:e.spacing(4)})),A0e=C("div")(({theme:e})=>({marginTop:"auto",display:"flex",justifyContent:"flex-end",borderTop:`1px solid ${e.palette.tertiary.contrast}`,paddingTop:e.spacing(2)})),_0e=C(Ze)(({theme:e})=>({marginRight:"auto"})),R0e=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),P0e=({children:e,constraints:t,setConstraints:n,setCurrentStep:r,mode:o})=>{const a=p.useRef(),i=lt(),{hasAccess:l}=p.useContext(Gr),{context:c=[]}=Il(),[u,d]=p.useState(!1),f=l2(t),h=o==="create"?gv:Hx,{segmentValuesLimit:m}=Ol(),y=Boolean(m&&f>m),g=c.map(b=>({value:b.name,label:b.name}));return T(ke,{children:[T(w0e,{children:[s(S0e,{children:s(v0e,{})}),T("div",{children:[s(J1,{children:"Select the context fields you want to include in the segment."}),s(J1,{children:"Use a predefined context field:"}),s(IL,{label:"Select a context",options:g,onChange:([b])=>{var w,x;(x=(w=a.current)==null?void 0:w.addConstraint)==null||x.call(w,b.value)}})]}),T(x0e,{children:[s(J1,{children:"...or add a new context field:"}),s(FC,{label:"Create new context",onClose:()=>d(!1),open:u,children:s(YO,{onSubmit:()=>d(!1),onCancel:()=>d(!1),modal:!0})}),s(zo,{permission:Pm,variant:"outlined",color:"primary",startIcon:s(Ta,{}),onClick:()=>d(!0),children:"Add context field"}),y&&s(C0e,{children:s(y0e,{values:f})})]}),s(X,{condition:t.length===0,show:s(E0e,{children:s(T0e,{children:"Start adding context fields by selecting an option from above, or you can create a new context field and use it right away"})})}),s(k0e,{children:s(qv,{ref:a,constraints:t,setConstraints:l(h)?n:void 0})})]}),T(A0e,{children:[s(_0e,{type:"button",onClick:()=>r(1),children:"Back"}),e,s(R0e,{type:"button",onClick:()=>{i("/segments")},children:"Cancel"})]})]})},I0e=C("div")(({theme:e})=>({display:"flex",position:"absolute",alignItems:"center",justifyContent:"center",top:30,left:0,right:TO,[e.breakpoints.down(1100)]:{right:0}})),$0e=C("div")(({theme:e})=>({position:"relative",borderRadius:10,background:e.palette.background.paper,padding:e.spacing(1,2.5),margin:"auto",display:"flex",alignItems:"center"})),O0e=C("span")(({theme:e})=>({marginRight:15,fontSize:e.fontSizes.smallBody})),L0e=C(OZ,{shouldForwardProp:e=>e!=="filled"})(({theme:e,filled:t})=>({fill:e.palette.primary.main,transition:"opacity 0.4s ease",opacity:t?1:.4,fontSize:t?20:17})),N0e=({total:e,current:t})=>{const n=Array.from({length:e}).map((r,o)=>o+1);return s(I0e,{children:T($0e,{children:[T(O0e,{children:["Step ",t," of ",e]}),n.map(r=>s(L0e,{filled:r===t},r))]})})},M0e=C("form")(({theme:e})=>({display:"flex",flexDirection:"column",height:"100%"})),LL=({children:e,name:t,description:n,constraints:r,setName:o,setDescription:a,setConstraints:i,handleSubmit:l,errors:c,clearErrors:u,mode:d})=>{const[h,m]=p.useState(1);return T(ke,{children:[s(N0e,{total:2,current:h}),T(M0e,{onSubmit:l,children:[s(X,{condition:h===1,show:s(nme,{name:t,description:n,setName:o,setDescription:a,errors:c,clearErrors:u,setCurrentStep:m})}),s(X,{condition:h===2,show:s(P0e,{constraints:r,setConstraints:i,setCurrentStep:m,mode:d,children:e})})]})]})},D0e=()=>{throw new Error("showFeedbackCES called outside feedbackCESContext")},B0e=()=>{throw new Error("hideFeedbackCES called outside feedbackCESContext")},c2=p.createContext({showFeedbackCES:D0e,hideFeedbackCES:B0e}),F0e=()=>{const{uiConfig:e}=Lt(),{setToastData:t,setToastApiError:n}=It(),{showFeedbackCES:r}=p.useContext(c2),o=lt(),{createSegment:a,loading:i}=MC(),{refetchSegments:l}=$l(),{name:c,setName:u,description:d,setDescription:f,constraints:h,setConstraints:m,getSegmentPayload:y,errors:g,clearErrors:v}=XO(),b=BC(h),{segmentValuesLimit:w}=Ol(),x=l2(h),E=Boolean(w&&x>w);return s(Mr,{loading:i,title:"Create segment",description:NL,documentationLink:OL,documentationLinkLabel:"Segments documentation",formatApiCode:()=>`curl --location --request POST '${e.unleashUrl}/api/admin/segments' \\
|
|
338
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
339
|
+
--header 'Content-Type: application/json' \\
|
|
340
|
+
--data-raw '${JSON.stringify(y(),void 0,2)}'`,children:s(LL,{handleSubmit:async _=>{_.preventDefault(),v();try{await a(y()),await l(),o("/segments/"),t({title:"Segment created",confetti:!0,type:"success"}),r({title:"How easy was it to create a segment?",text:"Please help us understand how we can improve segments",path:"/segments/create"})}catch($){n(ft($))}},name:c,setName:u,description:d,setDescription:f,constraints:h,setConstraints:m,errors:g,clearErrors:v,mode:"create",children:s(mu,{name:"segment",permission:gv,disabled:!b||E,"data-testid":gee})})})},NL=`
|
|
341
|
+
Segments make it easy for you to define which of your users should get access to a feature.
|
|
342
|
+
A segment is a reusable collection of constraints.
|
|
343
|
+
You can create and apply a segment when configuring activation strategies for a feature toggle or at any time from the segments page in the navigation menu.
|
|
344
|
+
`,z0e=e=>{const t=Dt(`api/admin/segments/${e}`),{data:n,error:r}=dn(t,()=>j0e(t)),o=p.useCallback(()=>{Vr(t).catch(console.warn)},[t]);return{segment:n,refetchSegment:o,loading:!r&&!n,error:r}},j0e=e=>fetch(e,{method:"GET"}).then(yn("Segment")).then(t=>t.json()),U0e=()=>{const e=dr("segmentId"),{segment:t}=z0e(Number(e)),{uiConfig:n}=Lt(),{setToastData:r,setToastApiError:o}=It(),a=lt(),{updateSegment:i,loading:l}=MC(),{refetchSegments:c}=$l(),{name:u,setName:d,description:f,setDescription:h,constraints:m,setConstraints:y,getSegmentPayload:g,errors:v,clearErrors:b}=XO(t==null?void 0:t.name,t==null?void 0:t.description,t==null?void 0:t.constraints),w=BC(m),x=l2(m),{segmentValuesLimit:E}=Ol(),A=Boolean(E&&x>E);return s(Mr,{loading:l,title:"Edit segment",description:NL,documentationLink:OL,documentationLinkLabel:"Segments documentation",formatApiCode:()=>`curl --location --request PUT '${n.unleashUrl}/api/admin/segments/${e}' \\
|
|
345
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
346
|
+
--header 'Content-Type: application/json' \\
|
|
347
|
+
--data-raw '${JSON.stringify(g(),void 0,2)}'`,children:s(LL,{handleSubmit:async $=>{if(t){$.preventDefault(),b();try{await i(t.id,g()),await c(),a("/segments/"),r({title:"Segment updated",type:"success"})}catch(L){o(ft(L))}}},name:u,setName:d,description:f,setDescription:h,constraints:m,setConstraints:y,errors:v,clearErrors:b,mode:"edit",children:s(Pl,{permission:Hx,disabled:!w||A,"data-testid":vee})})})},W0e=()=>{const{uiConfig:e}=Lt(),t=lt();return s(yO,{onClick:()=>t("/environments/create"),maxWidth:"700px",Icon:Ta,permission:Fo,disabled:!Boolean(e.flags.EEA),children:"New environment"})},H0e=(e,t,n)=>{const r=p.useRef(null);return p.useEffect(()=>{if(r.current)return r.current.dataset.index=String(e),V0e(r.current,t,(n==null?void 0:n.current)??void 0)},[e,t]),r},V0e=(e,t,n)=>{const r=f=>{ph&&t(Number(ph.dataset.index),Number(e.dataset.index),f)},o=n??e,a=f=>{f.target===o&&(e.draggable=!0)},i=()=>{e.draggable=!1},l=()=>{e.draggable=!0,ph=e},c=()=>{r(!1)},u=f=>{f.preventDefault()},d=()=>{r(!0),ph=null};return o.addEventListener("mouseenter",a),o.addEventListener("mouseleave",i),n&&e.addEventListener("mouseenter",i),e.addEventListener("dragstart",l),e.addEventListener("dragenter",c),e.addEventListener("dragover",u),e.addEventListener("drop",d),()=>{o.removeEventListener("mouseenter",a),o.removeEventListener("mouseleave",i),n&&e.removeEventListener("mouseenter",i),e.removeEventListener("dragstart",l),e.removeEventListener("dragenter",c),e.removeEventListener("dragover",u),e.removeEventListener("drop",d)}};let ph;const G0e=C(ai)(()=>({"&:hover":{".drag-handle .drag-icon":{display:"inherit",cursor:"grab"}}})),q0e=({row:e,moveListItem:t})=>{const{hasAccess:n}=p.useContext(Gr),r=p.useRef(null),{searchQuery:o}=su(),a=!o&&n(zb),i=H0e(e.index,t,r),l=(c,u)=>a&&c.column.isDragHandle?s(ei,{...c.getCellProps(),ref:u,className:"drag-handle",children:c.render("Cell")}):s(ei,{...c.getCellProps(),children:c.render("Cell")});return s(G0e,{hover:!0,ref:a?i:void 0,children:e.cells.map(c=>l(c,r))})},K0e=C(ye)(({theme:e})=>({fontWeight:"bold",fontSize:e.fontSizes.smallerBody})),Y0e=C(ye)(({theme:e})=>({fontSize:e.fontSizes.smallerBody})),wR=C(Io)(({theme:e})=>({marginLeft:e.spacing(1)})),X0e=({environment:e})=>{const{searchQuery:t}=su();return T(eo,{sx:n=>({[n.breakpoints.up("sm")]:{minWidth:"350px"}}),children:[s(yl,{search:t,children:e.name}),s(X,{condition:e.protected,show:s(wR,{color:"success",children:"Predefined"})}),s(X,{condition:!e.enabled,show:s(xv,{maxWidth:"270px",title:T(ke,{children:[s(K0e,{children:"Deprecated environment"}),s(Y0e,{children:"This environment is not auto-enabled for new projects. The project owner will need to manually enable it in the project."})]}),describeChild:!0,arrow:!0,children:s(wR,{color:"neutral",children:"Deprecated"})})})]})},fh=({permission:e,projectId:t,children:n,environmentId:r,tooltip:o,tooltipProps:a})=>{const{hasAccess:i}=p.useContext(Gr);let l;return t&&r?l=i(e,t,r):t?l=i(e,t):l=i(e),s(cu,{...a,title:Cv(l,o),children:n({hasAccess:l})})},J0e=C(l4)(({theme:e})=>({padding:e.spacing(1)})),jh=C(bs)(({theme:e})=>({borderRadius:e.shape.borderRadius})),Q0e=C(jh)(({theme:e})=>({color:e.palette.error.main})),Z0e=C(Lh)(({theme:e})=>({color:e.palette.error.main})),ebe=({environment:e,onEdit:t,onDeprecateToggle:n,onClone:r,onDelete:o})=>{const[a,i]=p.useState(null),l=Boolean(a),c=h=>{i(h.currentTarget)},u=()=>{i(null)},d=`environment-${e.name}-actions`,f=`${d}-menu`;return T(ke,{children:[s(_t,{title:"Environment actions",arrow:!0,describeChild:!0,children:s(Yt,{id:d,"aria-controls":l?f:void 0,"aria-haspopup":"true","aria-expanded":l?"true":void 0,onClick:c,type:"button",children:s(gC,{})})}),s(dx,{id:f,anchorEl:a,open:l,onClose:u,transformOrigin:{horizontal:"right",vertical:"top"},anchorOrigin:{horizontal:"right",vertical:"bottom"},disableScrollLock:!0,children:T(J0e,{"aria-labelledby":d,children:[s(fh,{permission:zb,children:({hasAccess:h})=>T(jh,{onClick:()=>{t(),u()},disabled:!h||e.protected,children:[s(Lh,{children:s(Za,{})}),s(fn,{children:s(ye,{variant:"body2",children:"Edit"})})]})}),s(fh,{permission:Fo,children:({hasAccess:h})=>T(jh,{onClick:()=>{r(),u()},disabled:!h,children:[s(Lh,{children:s(xZ,{})}),s(fn,{children:s(ye,{variant:"body2",children:"Clone"})})]})}),s(fh,{permission:zb,children:({hasAccess:h})=>T(jh,{onClick:()=>{n(),u()},disabled:!h||e.protected,children:[s(Lh,{children:s(X,{condition:e.enabled,show:s(XZ,{}),elseShow:s(JZ,{})})}),s(fn,{children:s(ye,{variant:"body2",children:e.enabled?"Deprecate":"Undeprecate"})})]})}),s(fh,{permission:Nne,children:({hasAccess:h})=>T(Q0e,{onClick:()=>{o(),u()},disabled:!h||e.protected,children:[s(Z0e,{children:s(Oo,{})}),s(fn,{children:s(ye,{variant:"body2",children:"Delete"})})]})})]})})]})},SR=(e,t)=>{var n;return Boolean((n=t==null?void 0:t.toLowerCase())==null?void 0:n.includes(e.toLowerCase()))},tbe=C("div")(({theme:e})=>({display:"flex",flexDirection:"column",color:e.palette.text.secondary,"& > span:first-of-type":{color:e.palette.text.primary}})),nbe=C("div")(({theme:e})=>({paddingLeft:e.spacing(1)})),rbe=C("div")(({theme:e})=>({display:"flex",marginBottom:e.spacing(3),"& > div:first-of-type":{width:"100%",maxWidth:e.spacing(50),marginRight:e.spacing(1)}})),obe=(e,t,n)=>T("li",{...e,children:[s(Rs,{icon:s(Ov,{fontSize:"small"}),checkedIcon:s(Lv,{fontSize:"small"}),style:{marginRight:8},checked:n}),T(tbe,{children:[s("span",{children:t.name}),s("span",{children:t.description})]})]}),abe=e=>s(nbe,{children:e.length>1?`${e.length} projects selected`:e[0].name}),ibe=({projects:e,setProjects:t})=>{const{projects:n}=Bi(),r=n.sort((c,u)=>c.name.localeCompare(u.name)).map(({id:c,name:u,description:d})=>({id:c,name:u,description:d})),o=r.filter(({id:c})=>e.includes(c)),a=e.length>0&&e.length===r.length,i=()=>{const c=a?[]:r.map(({id:u})=>u);t(c)};return s(rbe,{children:s(av,{size:"small",multiple:!0,limitTags:1,openOnFocus:!0,disableCloseOnSelect:!0,value:o,onChange:(c,u,d)=>{c.type==="keydown"&&c.key==="Backspace"&&d==="removeOption"||t(u.map(({id:f})=>f))},options:r,renderOption:(c,u,{selected:d})=>obe(c,u,d),filterOptions:(c,{inputValue:u})=>c.filter(({name:d,description:f})=>SR(u,d)||SR(u,f)),isOptionEqualToValue:(c,u)=>c.id===u.id,getOptionLabel:c=>c.name||c.description||"",renderInput:c=>s(mn,{...c,label:"Projects"}),renderTags:c=>abe(c),groupBy:()=>"Select/Deselect all",renderGroup:({key:c,children:u})=>T(p.Fragment,{children:[s(X,{condition:r.length>2,show:s(LC,{isAllSelected:a,onClick:i})}),u]},c)})})},ad="*",sbe=({...e})=>s(pr,{elevation:8,...e}),lbe=C(Rs)(({theme:e})=>({marginRight:e.spacing(.4)})),cbe=({options:e,defaultValue:t=[ad],onChange:n,disabled:r,error:o,onFocus:a})=>{const[i,l]=p.useState(typeof t=="string"?[t]:t),[c,u]=p.useState(typeof t=="string"||t.includes(ad)),d=i.length>0&&i.length===e.length&&i[0]!==ad,f=(v,b)=>{b?(u(!0),n([ad])):(u(!1),n(i.includes(ad)?[]:i))},h=()=>{const v=d?[]:e.map(({value:b})=>b);l(v),n(v)};return T(Me,{sx:{mt:-1,mb:3},children:[s(Me,{sx:{mt:1,mb:.25,ml:1.5},children:s(Tr,{disabled:r,"data-testid":"select-all-projects",control:s(Rs,{checked:r||c,onChange:f}),label:"ALL current and future projects"})}),s(av,{disabled:r||c,multiple:!0,limitTags:2,options:e,disableCloseOnSelect:!0,getOptionLabel:({label:v})=>v,groupBy:()=>"Select/Deselect all",renderGroup:({key:v,children:b})=>T(p.Fragment,{children:[s(X,{condition:e.length>2,show:s(LC,{isAllSelected:d,onClick:h})}),b]},v),fullWidth:!0,PaperComponent:sbe,renderOption:(v,b,{selected:w})=>T("li",{...v,children:[s(lbe,{icon:s(Ov,{fontSize:"small"}),checkedIcon:s(Lv,{fontSize:"small"}),checked:w}),b.label]}),renderInput:v=>s(mn,{...v,error:Boolean(o),helperText:o,variant:"outlined",label:"Projects",placeholder:"Select one or more projects",onFocus:a,"data-testid":"select-input"}),value:c||r?e:e.filter(v=>i.includes(v.value)),onChange:(v,b)=>{const w=b.map(({value:x})=>x);l(w),n(w)}})]})},ube=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{deleteToken:async i=>{const l=`api/admin/api-tokens/${i}`,c=t(l,{method:"DELETE"});try{return await e(c.caller,c.id)}catch(u){throw u}},createToken:async i=>{const c=t("api/admin/api-tokens",{method:"POST",body:JSON.stringify(i)});try{return await e(c.caller,c.id)}catch(u){throw u}},errors:n,loading:r}},dbe=C("form")(()=>({display:"flex",flexDirection:"column",height:"100%"})),Yl=C("p")(({theme:e})=>({display:"flex",color:e.palette.text.primary,marginBottom:e.spacing(1),"&:not(:first-of-type)":{marginTop:e.spacing(4)}})),Q1=C("p")(({theme:e})=>({color:e.palette.text.secondary,marginBottom:e.spacing(1)})),pbe=C(_r)(({theme:e})=>({width:"100%",maxWidth:e.spacing(50)})),fbe=C("div")(({theme:e})=>({padding:e.spacing(3),backgroundColor:e.palette.secondaryContainer,borderRadius:e.shape.borderRadiusMedium,marginTop:e.spacing(4)})),hbe=C("div")(({theme:e})=>({padding:e.spacing(0,4),"& > p:not(:first-of-type)":{marginTop:e.spacing(2)}})),mbe=C("div")(({theme:e})=>({marginTop:"auto",display:"flex",justifyContent:"flex-end",[e.breakpoints.down("sm")]:{marginTop:e.spacing(4)}})),gbe=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),vbe=({environment:e,open:t,setOpen:n,newToken:r})=>{const{environments:o,refetchEnvironments:a}=uu(),{cloneEnvironment:i,loading:l}=hu(),{createToken:c}=ube(),{projects:u}=Bi(),{setToastData:d,setToastApiError:f}=It(),{uiConfig:h}=Lt(),[m,y]=p.useState(`${e.name}_clone`),[g,v]=p.useState("development"),[b,w]=p.useState([]),[x,E]=p.useState(["*"]),[A,k]=p.useState(!0),[_,$]=p.useState("later"),[L,O]=p.useState({}),P=ee=>{O(re=>({...re,[ee]:void 0}))},D=(ee,re)=>{O(Se=>({...Se,[ee]:re}))};p.useEffect(()=>{y(F(e.name)),v("development"),w([]),E(["*"]),k(!0),$("later"),O({})},[e]);const F=ee=>{let re=`${ee}_clone`,Se=2;for(;!W(re);)re=`${e.name}_clone_${Se}`,Se++;return re},U=()=>({name:m,type:g,projects:b,clonePermissions:A}),Y=()=>({username:`${m}_token`,type:"CLIENT",environment:m,projects:x}),V=async ee=>{ee.preventDefault();try{if(await i(e.name,U()),_==="now"){const Se=await(await c(Y())).json();r(Se)}d({title:"Environment successfully cloned!",type:"success"}),a(),n(!1)}catch(re){f(ft(re))}},te=()=>`curl --location --request POST '${h.unleashUrl}/api/admin/environments/${e.name}/clone' \\
|
|
348
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
349
|
+
--header 'Content-Type: application/json' \\
|
|
350
|
+
--data-raw '${JSON.stringify(U(),void 0,2)}'`,Z=ee=>ee.length,W=ee=>!(o!=null&&o.some(re=>re.name===ee)),z=Z(m)&&W(m)&&x.length,R=ee=>{P("name"),W(ee)||D("name","An environment with that name already exists."),y(ee)},M=u.map(ee=>({value:ee.id,label:ee.name}));return s(FC,{open:t,onClose:()=>{n(!1)},label:`Clone ${e.name} environment`,children:s(Mr,{loading:l,modal:!0,title:`Clone ${e.name} environment`,description:"Cloning an environment will clone all feature toggles and their configuration (activation strategies, segments, status, etc) into a new environment.",documentationLink:"https://docs.getunleash.io/reference/environments#cloning-environments",documentationLinkLabel:"Cloning environments documentation",formatApiCode:te,children:T(dbe,{onSubmit:V,children:[T("div",{children:[s(Yl,{children:"What is your new environment name? (Can't be changed later)"}),s(pbe,{autoFocus:!0,label:"Environment name",error:Boolean(L.name),errorText:L.name,value:m,onChange:ee=>R(ee.target.value),required:!0}),s(Yl,{children:"What type of environment do you want to create?"}),s(SO,{onChange:ee=>v(ee.currentTarget.value),value:g}),T(Yl,{children:["Select which projects you want to clone the environment configuration in?",s(Dm,{tooltip:"The cloned environment will keep the feature toggle state for the selected projects, where it will be enabled by default."})]}),s(ibe,{projects:b,setProjects:w}),s(Yl,{children:"Keep the users permission for this environment?"}),s(Q1,{children:"If you turn it off, the permission for this environment across all projects and feature toggles will remain only for admin and editor roles."}),s(Tr,{label:A?"Yes":"No",control:s(Ii,{onChange:ee=>k(ee.target.checked),checked:A})}),T(fbe,{children:[s(Yl,{children:"API Token"}),T(Q1,{children:["In order to connect your SDKs to your newly cloned environment, you will also need an API token."," ",s(go,{href:"https://docs.getunleash.io/reference/api-tokens-and-client-keys",target:"_blank",children:"Read more about API tokens"}),"."]}),s(Pi,{children:T(hx,{value:_,onChange:ee=>$(ee.target.value),name:"api-token-generation",children:[s(Tr,{value:"later",control:s(ol,{}),label:"I want to generate an API token later"}),s(Tr,{value:"now",control:s(ol,{}),label:"Generate an API token now"})]})}),T(hbe,{children:[s(Q1,{children:"A new Server-side SDK (CLIENT) API token will be generated for the cloned environment, so you can get started right away."}),s(X,{condition:_==="now",show:T(ke,{children:[s(Yl,{children:"Which projects do you want this token to give access to?"}),s(cbe,{options:M,defaultValue:x,onChange:E,error:L.projects,onFocus:()=>P("projects")})]})})]})]})]}),T(mbe,{children:[s(Ze,{type:"submit",variant:"contained",color:"primary",disabled:!z,children:"Clone environment"}),s(gbe,{onClick:()=>{n(!1)},children:"Cancel"})]})]})})})};var u2={},ybe=cn;Object.defineProperty(u2,"__esModule",{value:!0});var ML=u2.default=void 0,bbe=ybe(Cn()),wbe=En,Sbe=(0,bbe.default)((0,wbe.jsx)("path",{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm-1 4 6 6v10c0 1.1-.9 2-2 2H7.99C6.89 23 6 22.1 6 21l.01-14c0-1.1.89-2 1.99-2h7zm-1 7h5.5L14 6.5V12z"}),"FileCopy");ML=u2.default=Sbe;const DL=({token:e})=>{const{setToastData:t}=It();return T("div",{style:{backgroundColor:"#efefef",padding:"2rem",borderRadius:"3px",margin:"0",marginTop:"1rem",display:"flex",justifyContent:"space-between",alignItems:"center",wordBreak:"break-all"},children:[e,s(_t,{title:"Copy token",arrow:!0,children:s(Yt,{onClick:()=>{EO(e)?t({type:"success",title:"Token copied to clipboard"}):t({type:"error",title:"Could not copy token"})},size:"large",children:s(ML,{})})})]})},xbe=({open:e,setOpen:t,token:n})=>T(Zn,{open:e,secondaryButtonText:"Close",onClose:(r,o)=>{o||t(!1)},title:"New API token created",children:[s(ye,{variant:"body1",children:"Your new token has been created successfully."}),T(ye,{variant:"body1",children:['You can also find it as "',s("strong",{children:n==null?void 0:n.username}),'" in the'," ",s(ln,{to:"/admin/api",children:"API access page"}),"."]}),s(DL,{token:(n==null?void 0:n.secret)||""})]}),Cbe=C(Me)(({theme:e})=>({display:"flex",alignItems:"center",justifyContent:"flex-end",paddingLeft:e.spacing(.5),minWidth:e.spacing(6.5)})),Ebe=C(Yt)(({theme:e})=>({padding:e.spacing(1.5,0),cursor:"inherit",transition:"color 0.2s ease-in-out",display:"none",color:e.palette.neutral.main})),Tbe=C(I4,{shouldForwardProp:e=>e!=="deprecated"})(({theme:e,deprecated:t})=>({color:t?e.palette.neutral.border:e.palette.primary.main})),BL=({environment:e})=>T(Cbe,{children:[s(Ebe,{size:"large",disableRipple:!0,className:"drag-icon",children:s(IZ,{titleAccess:"Drag to reorder"})}),s(Tbe,{deprecated:!e.enabled})]}),kbe=C(Mi)(({theme:e})=>({marginTop:e.spacing(3)})),Abe=C("p",{shouldForwardProp:e=>e!=="warning"})(({theme:e,warning:t})=>({color:t?e.palette.error.dark:e.palette.text.primary})),FL=({environment:e,warnEnabledToggles:t})=>{const n=p.useMemo(()=>[{id:"Icon",width:"1%",Cell:({row:{original:c}})=>s(BL,{environment:c})},{Header:"Name",accessor:"name",Cell:eo},{Header:"Type",accessor:"type",Cell:eo},{Header:"Visible in",accessor:c=>c.projectCount===1?"1 project":`${c.projectCount} projects`,Cell:({row:{original:c},value:u})=>T(eo,{children:[u,s(X,{condition:Boolean(t),show:s(Abe,{warning:Boolean(c.enabledToggleCount&&c.enabledToggleCount>0),children:c.enabledToggleCount===1?"1 toggle enabled":`${c.enabledToggleCount} toggles enabled`})})]})}],[t]),{getTableProps:r,getTableBodyProps:o,headerGroups:a,rows:i,prepareRow:l}=Kt.useTable({columns:n,data:[e],disableSortBy:!0});return T(kbe,{...r(),rowHeight:"compact",children:[s(Ni,{headerGroups:a}),s($i,{...o(),children:i.map(c=>(l(c),s(ai,{hover:!0,...c.getRowProps(),children:c.cells.map(u=>s(ei,{...u.getCellProps(),children:u.render("Cell")}))})))})]})},_be=({environment:e,open:t,setOpen:n,onConfirm:r})=>{const{enabled:o}=e,a=o?"Deprecate":"Undeprecate";return T(Zn,{title:`${a} environment?`,open:t,primaryButtonText:a,secondaryButtonText:"Close",onClick:r,onClose:()=>{n(!1)},children:[s(X,{condition:o,show:s(Zt,{severity:"info",children:"Deprecating an environment will mark it as deprecated. Deprecated environments are set as not visible by default for new projects. Project owners are still able to override this setting in the project. This environment will still be visible in any current projects."}),elseShow:s(Zt,{severity:"info",children:"Undeprecating an environment will no longer mark it as deprecated. An undeprecated environment will be set as visible by default for new projects."})}),s(FL,{environment:e})]})},Rbe=C("p")(({theme:e})=>({marginTop:e.spacing(3),marginBottom:e.spacing(1.5)})),Pbe=C(_r)(()=>({width:"100%"})),Ibe=({environment:e,open:t,setOpen:n,onConfirm:r})=>{const[o,a]=p.useState("");return p.useEffect(()=>{a("")},[t]),T(Zn,{title:"Delete environment?",open:t,primaryButtonText:"Delete environment",disabledPrimaryButton:e.name!==o,secondaryButtonText:"Close",onClick:r,onClose:()=>{n(!1)},children:[T(Zt,{severity:"error",children:[s("strong",{children:"Danger! This action is not reversible. Please proceed with caution."})," ","Deleting this environment will result in removing all strategies that are active in this environment across all feature toggles."]}),s(FL,{environment:e,warnEnabledToggles:!0}),T(Rbe,{children:["In order to delete this environment, please enter the id of the environment in the textfield below:"," ",s("strong",{children:e.name})]}),s(Pbe,{label:"Environment name",value:o,onChange:i=>a(i.target.value)})]})},$be=({environment:e})=>{const t=lt(),{setToastApiError:n,setToastData:r}=It(),{environments:o,refetchEnvironments:a}=uu(),{refetch:i}=yC(),{deleteEnvironment:l,toggleEnvironmentOn:c,toggleEnvironmentOff:u}=hu(),[d,f]=p.useState(!1),[h,m]=p.useState(!1),[y,g]=p.useState(!1),[v,b]=p.useState(!1),[w,x]=p.useState();return T(ti,{children:[s(ebe,{environment:e,onEdit:()=>t(`/environments/${e.name}`),onDeprecateToggle:()=>m(!0),onClone:()=>{o.length<zm?g(!0):r({type:"error",title:"Environment limit reached",text:`You have reached the maximum number of environments (${zm}). Please reach out if you need more.`})},onDelete:()=>f(!0)}),s(Ibe,{environment:e,open:d,setOpen:f,onConfirm:async()=>{try{await l(e.name),i(),r({type:"success",title:"Environment deleted",text:`You have successfully deleted the ${e.name} environment.`})}catch(k){n(ft(k))}finally{f(!1),await a()}}}),s(_be,{environment:e,open:h,setOpen:m,onConfirm:async()=>{try{e.enabled?(await u(e.name),r({type:"success",title:"Environment deprecated successfully"})):(await c(e.name),r({type:"success",title:"Environment undeprecated successfully"}))}catch(k){n(ft(k))}finally{m(!1),await a()}}}),s(vbe,{environment:e,open:y,setOpen:g,newToken:k=>{x(k),b(!0)}}),s(xbe,{open:v,setOpen:b,token:w})]})},Obe=C(Me)(({theme:e})=>({display:"flex",flexDirection:"column",justifyContent:"center",wordBreak:"break-word",padding:e.spacing(1,2)})),Lbe=C("span")(({theme:e})=>({overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:"1",lineClamp:"1"})),Nbe=C("span")(({theme:e})=>({color:e.palette.text.secondary,overflow:"hidden",textOverflow:"ellipsis",fontSize:"inherit",WebkitLineClamp:"1",lineClamp:"1",display:"-webkit-box",WebkitBoxOrient:"vertical"})),cs=({value:e,subtitle:t})=>{const{searchQuery:n}=su();return T(Obe,{children:[s(Lbe,{style:{WebkitLineClamp:Boolean(t)?1:2,lineClamp:Boolean(t)?1:2},"data-loading":!0,children:s(yl,{search:n,children:e})}),s(X,{condition:Boolean(t),show:()=>s(Nbe,{"data-loading":!0,children:s(yl,{search:n,children:t})})})]})},Mbe=C(Zt)(({theme:e})=>({marginBottom:e.spacing(4)})),Dbe=()=>{const{changeSortOrder:e}=hu(),{setToastApiError:t}=It(),{environments:n,mutateEnvironments:r}=uu(),o=p.useCallback(async(v,b,w=!1)=>{const x=[...n],E=x[v];if(x.splice(v,1),x.splice(b,0,E),await r(x),w)try{await e(que(x))}catch(A){t(ft(A))}},[e,n,r,t]),{getTableProps:a,getTableBodyProps:i,headerGroups:l,rows:c,prepareRow:u,state:{globalFilter:d},setGlobalFilter:f}=Kt.useTable({columns:Bbe,data:n,disableSortBy:!0},Kt.useGlobalFilter),m=T(ke,{children:[s(Hr,{initialValue:d,onChange:f}),s(xn.Divider,{}),s(W0e,{})]});let y=c.length;const g=s(xn,{title:`Environments (${y})`,actions:m});return T(fr,{header:g,children:[s(Mbe,{severity:"info",children:"This is the order of environments that you have today in each feature toggle. Rearranging them here will change also the order inside each feature toggle."}),s(Di,{value:d,children:T(Mi,{...a(),rowHeight:"compact",children:[s(Ni,{headerGroups:l}),s($i,{...i(),children:c.map(v=>(u(v),s(q0e,{row:v,moveListItem:o},v.original.name)))})]})}),s(X,{condition:c.length===0,show:s(X,{condition:(d==null?void 0:d.length)>0,show:T(Un,{children:["No environments found matching “",d,"”"]}),elseShow:s(Un,{children:"No environments available. Get started by adding one."})})})]})},Bbe=[{id:"Icon",width:"1%",Cell:({row:{original:e}})=>s(BL,{environment:e}),disableGlobalFilter:!0,isDragHandle:!0},{Header:"Name",accessor:"name",Cell:({row:{original:e}})=>s(X0e,{environment:e}),minWidth:350},{Header:"Type",accessor:"type",Cell:cs},{Header:"Visible in",accessor:e=>e.projectCount===1?"1 project":`${e.projectCount} projects`,Cell:eo},{Header:"API Tokens",accessor:e=>e.apiTokenCount===1?"1 token":`${e.apiTokenCount} tokens`,Cell:eo},{Header:"Actions",id:"Actions",align:"center",width:"1%",Cell:({row:{original:e}})=>s($be,{environment:e}),disableGlobalFilter:!0}],Fbe=()=>{const e=lt();return s(zo,{onClick:()=>e("/segments/create"),permission:gv,"data-testid":lee,children:"New segment"})},zbe=C("div")(({theme:e})=>({display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",margin:e.spacing(6),marginLeft:"auto",marginRight:"auto"})),jbe=C(ye)(({theme:e})=>({fontSize:e.fontSizes.mainHeader,marginBottom:e.spacing(2.5)})),Ube=C("p")(({theme:e})=>({fontSize:e.fontSizes.smallBody,color:e.palette.text.secondary,maxWidth:515,marginBottom:e.spacing(2.5),textAlign:"center"})),Wbe=C(ln)(({theme:e})=>({textDecoration:"none",color:e.palette.primary.main,fontWeight:e.fontWeight.bold})),Hbe=()=>{const{hasAccess:e}=p.useContext(Gr);return T(zbe,{children:[s(jbe,{children:"No segments yet!"}),s(Ube,{children:"Segment makes it easy for you to define who should be exposed to your feature. The segment is often a collection of constraints and can be reused."}),s(X,{condition:e(gv),show:s(Wbe,{to:"/segments/create",children:"Create your first segment"})})]})},Vbe=e=>{const t=Dt(`api/admin/segments/${e}/strategies`),{data:n,error:r}=dn(t,()=>Gbe(t)),o=p.useCallback(()=>{Vr(t).catch(console.warn)},[t]);return{strategies:n==null?void 0:n.strategies,refetchUsedSegments:o,loading:!r&&!n,error:r}},Gbe=e=>fetch(e,{method:"GET"}).then(yn("Strategies by segment")).then(t=>t.json()),qbe=C(_r)(({theme:e})=>({marginTop:e.spacing(2)})),Kbe=({segment:e,open:t,onClose:n,onRemove:r})=>{const[o,a]=p.useState(""),i=u=>a(u.currentTarget.value),l=()=>{n(),a("")},c="delete-segment-confirmation-form";return T(Zn,{title:"Are you sure you want to delete this segment?",open:t,primaryButtonText:"Delete segment",secondaryButtonText:"Cancel",onClick:()=>{r(),a("")},disabledPrimaryButton:(e==null?void 0:e.name)!==o,onClose:l,formId:c,children:[T("p",{children:["In order to delete this segment, please enter the name of the segment in the field below: ",s("strong",{children:e==null?void 0:e.name})]}),s("form",{id:c,children:s(qbe,{autoFocus:!0,onChange:i,value:o,label:"Segment name","data-testid":bee})})]})},Ybe=({strategyDefinition:e})=>s("p",{children:e==null?void 0:e.description}),Xbe=ote(ZX,e=>({root:{height:8},thumb:{height:24,width:24,backgroundColor:"#fff",border:"2px solid currentColor"},active:{},valueLabel:{},track:{height:8,borderRadius:e.shape.borderRadius},rail:{height:8,borderRadius:e.shape.borderRadius}})),Jbe=Li()(e=>({slider:{width:"100%",maxWidth:"100%"},margin:{height:e.spacing(3)}})),Qbe=[{value:0,label:"0%"},{value:25,label:"25%"},{value:50,label:"50%"},{value:75,label:"75%"},{value:100,label:"100%"}],zL=({name:e,value:t,onChange:n,disabled:r=!1})=>{const{classes:o}=Jbe(),a=i=>`${i}%`;return T("div",{className:o.slider,children:[s(ye,{id:"discrete-slider-always",variant:"h3",gutterBottom:!0,component:"h3",children:e}),s(Xbe,{min:0,max:100,value:t,getAriaValueText:a,"aria-labelledby":"discrete-slider-always",step:1,"data-testid":Cee,marks:Qbe,onChange:n,valueLabelDisplay:"on",disabled:r})]})},jL=({name:e,value:t="",label:n="",options:r,onChange:o,id:a,disabled:i=!1,className:l,classes:c,...u})=>T(Pi,{variant:"outlined",size:"small",classes:c,children:[s(Yp,{htmlFor:a,children:n}),s(Xp,{name:e,disabled:i,onChange:o,className:l,label:n,id:a,value:t,...u,children:(()=>r.map(f=>s(bs,{value:f.key,title:f.title||"","data-testid":`${V4}-${f.label}`,children:f.label},f.key)))()})]}),xR=[{key:"default",label:"default"},{key:"userId",label:"userId"},{key:"sessionId",label:"sessionId"},{key:"random",label:"random"}],Zbe=({updateParameter:e,parameters:t,context:n,editable:r=!0})=>{const o=u=>d=>{e(u,d)},a=(u,d)=>{e("rollout",d.toString())},l=(()=>xR.concat(n.filter(u=>u.stickiness).filter(u=>!xR.find(d=>d.key===u.name)).map(u=>({key:u.name,label:u.name}))))(),c=t.rollout!==void 0?jd(t.rollout):100;return T("div",{children:[s(zL,{name:"Rollout",value:c,disabled:!r,onChange:a}),s("br",{}),T("div",{children:[T(ye,{variant:"subtitle2",style:{marginBottom:"1rem",display:"flex",gap:"1ch"},component:"h2",children:["Stickiness",s(Dm,{tooltip:"Stickiness defines what parameter should be used to ensure that your users get consistency in features. By default unleash will use the first value present in the context in the order of userId, sessionId and random."})]}),s(jL,{id:"stickiness-select",name:"stickiness",label:"Stickiness",options:l,value:ls(t.stickiness),disabled:!r,"data-testid":Tee,onChange:u=>o("stickiness")(u.target.value)})," ",s("br",{}),s("br",{}),T(ye,{variant:"subtitle2",style:{marginBottom:"1rem",display:"flex",gap:"1ch"},component:"h2",children:["GroupId",s(Dm,{tooltip:"GroupId is used to ensure that different toggles will hash differently for the same user. The groupId defaults to feature toggle name, but you can override it to correlate rollout of multiple feature toggles."})]}),s(_r,{label:"groupId",id:"groupId-input",value:ls(t.groupId),disabled:!r,onChange:u=>o("groupId")(u.target.value),"data-testid":kee})]})]})},ewe=C("div")(({theme:e})=>({display:"grid",gap:e.spacing(1)})),twe=C("div")(({theme:e})=>({display:"flex",gap:e.spacing(1),flexWrap:"wrap"})),nwe=C("div")(({theme:e})=>({display:"flex",gap:e.spacing(1),alignItems:"start"})),UL=({name:e,list:t,setConfig:n,disabled:r,errors:o})=>{const[a,i]=p.useState(""),l="Enter",c=m=>{d(m)},u=m=>{(m==null?void 0:m.key)===l&&(d(m),m.preventDefault(),m.stopPropagation())},d=m=>{m.preventDefault();const y=m.target.value;if(y){const g=y.split(/,\s*/).filter(v=>!t.includes(v));if(g.length>0){const v=t.concat(g).filter(b=>b);n(e,v.join(","))}i("")}},f=m=>{t[m]=null,n(e,t.length===1?"":t.filter(Boolean).join(","))},h=m=>{i(m.currentTarget.value)};return T(ewe,{children:[T(ye,{variant:"subtitle2",component:"h2",children:["List of ",e]}),s(X,{condition:t.length>0,show:s(twe,{children:t.map((m,y)=>s(To,{label:s(Da,{maxWidth:"300",text:m,maxLength:50}),onDelete:r?void 0:()=>f(y),title:"Remove value"},y+m))})}),s(X,{condition:!r,show:T(nwe,{children:[s(mn,{error:Boolean(o.getFormError(e)),helperText:o.getFormError(e),name:"input_field",variant:"outlined",label:"Add items",id:"input-add-items",value:a,size:"small",placeholder:"",onBlur:c,onChange:h,onKeyDown:u,"data-testid":Aee}),s(Ze,{onClick:d,"data-testid":_ee,variant:"outlined",color:"secondary",startIcon:s(Ta,{}),children:"Add"})]})})]})},rwe=({editable:e,parameters:t,updateParameter:n,errors:r})=>s("div",{children:s(UL,{name:"userIds",list:Qi(t.userIds),disabled:!e,setConfig:n,errors:r})}),id=({text:e})=>e?s(Me,{sx:t=>({color:t.palette.text.secondary,fontSize:t.fontSizes.smallerBody,marginTop:t.spacing(1)}),children:e}):null,owe=({definition:e,parameters:t,updateParameter:n,editable:r,errors:o})=>{const{type:a,name:i,description:l,required:c}=e,u=t[i],d=o.getFormError(i),f=c?`${i} * `:i,h=b=>{n(i,b.target.value)},m=b=>{n(i,ls(b.target.value))},y=(b,w)=>{n(i,w.toString())},g=(b,w)=>{n(i,String(w))},v=(b,w)=>{n(b,Qi(w).join(","))};if(a==="percentage")return T("div",{children:[s(zL,{name:i,onChange:y,disabled:!r,value:jd(t[i]),minLabel:"off",maxLabel:"on"}),s(id,{text:l})]});if(a==="list")return T("div",{children:[s(UL,{name:i,list:Qi(t[i]),disabled:!r,setConfig:v,errors:o}),s(id,{text:l})]});if(a==="number")return T("div",{children:[s(mn,{error:Boolean(d),helperText:d,variant:"outlined",size:"small","aria-required":c,style:{width:"100%"},disabled:!r,label:f,onChange:h,value:u}),s(id,{text:l})]});if(a==="boolean"){const w=ls(t[i])==="true";return T("div",{children:[s(Tr,{label:i,control:s(Ii,{name:i,onChange:g,checked:w})}),s(id,{text:l})]})}return T("div",{children:[s(mn,{rows:1,placeholder:"",variant:"outlined",size:"small",style:{width:"100%"},"aria-required":c,disabled:!r,error:Boolean(d),helperText:d,name:i,label:f,onChange:m,value:ls(t[i])}),s(id,{text:l})]})},awe=Nr("div")(({theme:e})=>({display:"grid",gap:e.spacing(4)})),iwe=({parameters:e,strategyDefinition:t,updateParameter:n,editable:r,errors:o})=>!t||t.parameters.length===0?null:s(awe,{children:t.parameters.map((a,i)=>s("div",{children:s(owe,{definition:a,parameters:e,updateParameter:n,editable:r,errors:o})},i))}),swe=({hasAccess:e,strategy:t,strategyDefinition:n,setStrategy:r,validateParameter:o,errors:a})=>{const{context:i}=Il(),l=(c,u)=>{r(Ko(d=>{d.parameters=d.parameters??{},d.parameters[c]=u})),o(c,u)};switch(t.name){case"default":return s(Ybe,{strategyDefinition:n});case"flexibleRollout":return s(Zbe,{context:i,parameters:t.parameters??{},updateParameter:l,editable:e});case"userWithId":return s(rwe,{parameters:t.parameters??{},updateParameter:l,editable:e,errors:a});default:return s(iwe,{strategyDefinition:n,parameters:t.parameters??{},updateParameter:l,editable:e,errors:a})}},lwe=({projectId:e,featureId:t,environmentId:n,children:r})=>{const o=p2(e,t),{feature:a}=bl(e,t),i=s(ln,{to:o,style:{color:"inherit"},children:"feature toggle page"});return s(X,{condition:cwe(a,n),show:r,elseShow:T(Zt,{severity:"warning",children:["This feature toggle is currently disabled in the"," ",s("strong",{children:n})," environment. Any changes made here will not take effect until the toggle has been enabled on the ",i,"."]})})},cwe=(e,t)=>{const n=e.environments.find(r=>r.name===t);return n?n.enabled:!1},uwe=({projectId:e,environmentId:t,strategy:n,setStrategy:r})=>{const o=p.useMemo(()=>n.constraints??[],[n]),a=c=>{r(u=>({...u,constraints:c instanceof Function?c(o):c}))},i=Wc(g3,e,t),l=Wc(Wx,e,t);return s(qv,{constraints:o,setConstraints:l?a:void 0,showCreateButton:i})},dwe=C("span")(({theme:e})=>({display:"flex",alignItems:"center",gap:e.spacing(.5),paddingInlineStart:e.spacing(2),paddingInlineEnd:e.spacing(1),paddingBlockStart:e.spacing(.5),paddingBlockEnd:e.spacing(.5),borderRadius:"100rem",background:e.palette.featureStrategySegmentChipBackground,color:e.palette.text.tertiaryContrast})),CR=C("button")(({theme:e})=>({all:"unset",height:e.spacing(2),cursor:"pointer"})),pwe=C(ln)(({theme:e})=>({marginRight:e.spacing(1),color:"inherit",textDecoration:"none"})),Z1=e=>({fontSize:e.fontSizes.bodySize}),fwe=({segment:e,setSegments:t,preview:n,setPreview:r})=>{const o=()=>{t(c=>c.filter(u=>u.id!==e.id)),r(c=>c===e?void 0:c)},a=()=>{r(c=>c===e?void 0:e)},i=s(X,{condition:e===n,show:s(M4,{titleAccess:"Hide",sx:Z1}),elseShow:s(N4,{titleAccess:"Show",sx:Z1})}),l=e===n?"Hide segment constraints":"Preview segment constraints";return T(dwe,{children:[s(pwe,{to:`/segments/edit/${e.id}`,target:"_blank",children:e.name}),s(_t,{title:l,arrow:!0,children:s(CR,{type:"button",onClick:a,"aria-expanded":e===n,"aria-controls":PL,children:i})}),s(_t,{title:"Remove segment",arrow:!0,children:s(CR,{type:"button",onClick:o,children:s(RZ,{titleAccess:"Remove",sx:Z1})})})]})},hwe=C(nx)(({theme:e})=>({border:`1px solid ${e.palette.dividerAlternative}`,borderRadius:e.shape.borderRadiusMedium,backgroundColor:e.palette.background.paper,boxShadow:"none",margin:0,transition:"all 0.1s ease","&:before":{opacity:"0 !important"},"&.Mui-expanded":{backgroundColor:e.palette.neutral.light}})),mwe=C(ox)(({theme:e})=>({margin:e.spacing(0,.5),fontSize:e.typography.body2.fontSize,".MuiAccordionSummary-content":{display:"flex",alignItems:"center"}})),gwe=C(ln)(({theme:e})=>({textDecoration:"none",marginLeft:e.spacing(1),"&:hover":{textDecoration:"underline"}})),WL=({segment:e,isExpanded:t,headerContent:n,constraintList:r})=>{var i;const[o,a]=p.useState(t||!1);return T(hwe,{expanded:o,children:[T(mwe,{id:`segment-accordion-${e.id}`,children:[s($4,{color:"secondary",sx:{mr:1}}),s("span",{children:"Segment:"}),s(gwe,{to:`/segments/edit/${e.id}`,children:e.name}),s(X,{condition:Boolean(n),show:n}),s(X,{condition:!t,show:s(Ze,{size:"small",variant:"outlined",onClick:()=>a(l=>!l),sx:{my:0,ml:"auto",fontSize:l=>l.typography.body2.fontSize},children:o?"Close preview":"Preview"})})]}),s(rx,{sx:{pt:0},children:s(X,{condition:Boolean(r),show:r,elseShow:s(X,{condition:(((i=e==null?void 0:e.constraints)==null?void 0:i.length)||0)>0,show:s(qv,{constraints:e.constraints,showLabel:!1}),elseShow:s(ye,{children:"This segment has no constraints."})})})})]})},vwe=C("div")(({theme:e})=>({display:"flex",flexWrap:"wrap",gap:e.spacing(1)})),ywe=C("p")(({theme:e})=>({color:e.palette.text.secondary})),bwe=C("p")(({theme:e})=>({fontSize:e.fontSizes.smallerBody,padding:e.spacing(.75,1),display:"block",marginTop:"auto",marginBottom:"auto",alignItems:"center",borderRadius:e.shape.borderRadius,lineHeight:1,color:e.palette.text.primary,backgroundColor:e.palette.secondaryContainer})),wwe=({segments:e,setSegments:t})=>{const[n,r]=p.useState(),o=e.length-1;return e.length===0?null:T(ke,{children:[s(X,{condition:e&&e.length>0,show:s(ywe,{children:"Selected Segments"})}),s(vwe,{children:e.map((a,i)=>T(p.Fragment,{children:[s(fwe,{segment:a,setSegments:t,preview:n,setPreview:r}),s(X,{condition:i<o,show:s(bwe,{children:"AND"})})]},a.id))}),s(X,{condition:Boolean(n),show:()=>s(WL,{segment:n,isExpanded:!0})})]})},Swe=C(mo)(({theme:e})=>({fontSize:e.fontSizes.smallBody})),xwe=({segments:e,setSegments:t})=>{const{segments:n}=$l(),{strategySegmentsLimit:r}=Ol(),o=Boolean(r&&e.length>=r);if(!n||n.length===0)return null;const i=n.filter(c=>!e.find(u=>u.id===c.id)).map(c=>({value:String(c.id),label:c.name}));return T(ke,{children:[s(ye,{component:"h3",sx:{m:0},variant:"h3",children:"Segmentation"}),o&&s(b0e,{}),s("p",{children:"Add a predefined segment to constrain this feature toggle:"}),s(IL,{label:"Select segments",options:i,onChange:([c])=>{const u=n.find(d=>String(d.id)===c.value);u&&t(d=>[...d,u])},disabled:o}),s(wwe,{segments:e,setSegments:t}),s(Swe,{})]})},Cwe=(e,t)=>{const{type:n,required:r}=e;if(!(n!=="string"&&n!=="list"&&n!=="number")){if(r&&(typeof t>"u"||t===""))return"Field is required";if(n==="number"&&!Ewe(t))return"Not a valid number."}},Ewe=e=>typeof e>"u"||e===""||/^\d+$/.test(String(e)),Twe=({environment:e})=>T(Zt,{severity:"info",children:[s("strong",{children:"Change requests"})," are enabled",e?` for ${e}`:"",". Your changes needs to be approved before they will be live. All the changes you do now will be added into a draft that you can submit for review."]}),kwe="production",Awe=({open:e,onClose:t,onClick:n,label:r,loading:o})=>{const[a,i]=HL(),l=()=>{i(c=>({hide:!c.hide}))};return T(Zn,{title:"Changing production environment!",primaryButtonText:r,disabledPrimaryButton:o,secondaryButtonText:"Cancel",onClick:n,onClose:t,open:e,children:[s(Zt,{severity:"error",children:"WARNING. You are about to make changes to a production environment. These changes will affect your customers."}),s("p",{style:{marginTop:"1rem"},children:"Are you sure you want to proceed?"}),s(Tr,{label:"Don't show again",control:s(Rs,{checked:a.hide,onChange:l})})]})},_we=(e,t)=>{const[n]=HL(),r=e.environments.find(o=>o.name===t);return n.hide?!1:(r==null?void 0:r.type)===kwe},Rwe="useFeatureStrategyProdGuardSettings:v2",HL=qx(Rwe,{hide:!1}),Pwe=e=>({changeRequestInReviewOrApproved:n=>e?e.some(r=>r.environment===n&&wn(["In review","Approved"],r.state)):!1,alert:s(Zt,{sx:{margin:"1rem 0"},severity:"warning",children:"You currently have a change request in review for this environment. Adding a new change will add the change to the existing change request, and all existing approvals will be reset. Are you sure you want to continue?"})}),Iwe=(e,t,n,r={})=>{const{isEnterprise:o}=Lt();return Ev(o(),e,t,n,r)},$we=e=>fetch(e).then(yn("ChangeRequest")).then(t=>t.json()),Kv=e=>{const{data:t,error:n,mutate:r}=Iwe([],Dt(`api/admin/projects/${e}/change-requests/pending`),$we);return{data:t,loading:!n&&!t,refetch:r,error:n}},Owe=C("form")(({theme:e})=>({display:"grid",gap:e.spacing(2)})),e0=C("hr")(({theme:e})=>({width:"100%",height:"1px",margin:e.spacing(2,0),border:"none",background:e.palette.tertiary.light})),Lwe=C("div")(({theme:e})=>({display:"flex",justifyContent:"end",gap:e.spacing(2),paddingBottom:e.spacing(10)})),Nwe=({projectId:e,feature:t,environmentId:n,permission:r,onSubmit:o,loading:a,strategy:i,setStrategy:l,segments:c,setSegments:u,errors:d,isChangeRequest:f})=>{const[h,m]=p.useState(!1),y=BC(i.constraints),g=_we(t,n),v=Wc(r,e,n),{strategyDefinition:b}=NC(i==null?void 0:i.name),{data:w}=Kv(t.project),{changeRequestInReviewOrApproved:x,alert:E}=Pwe(w),A=x(n||""),k=A?"Add to existing change request":"Add change to draft",_=lt(),{uiConfig:$,error:L,loading:O}=Lt();if(L)throw L;if(O||!b)return null;const P=V=>b.parameters.find(te=>te.name===V),D=(V,te)=>{const Z=Cwe(P(V),te);return Z?(d.setFormError(V,Z),!1):(d.removeFormError(V),!0)},F=()=>b.parameters.map(V=>V.name).map(V=>{var te;return D(V,(te=i.parameters)==null?void 0:te[V])}).every(Boolean),U=()=>{_(p2(t.project,t.name))};return T(Owe,{onSubmit:async V=>{V.preventDefault(),F()&&(g&&!f?m(!0):o())},children:[s(X,{condition:A,show:E,elseShow:s(X,{condition:Boolean(f),show:s(Twe,{environment:n})})}),s(lwe,{projectId:t.project,featureId:t.name,environmentId:n,children:s(X,{condition:Boolean(f),show:T(Zt,{severity:"success",children:["This feature toggle is currently enabled in the"," ",s("strong",{children:n})," environment. Any changes made here will be available to users as soon as these changes are approved and applied."]}),elseShow:T(Zt,{severity:"success",children:["This feature toggle is currently enabled in the"," ",s("strong",{children:n})," environment. Any changes made here will be available to users as soon as you hit ",s("strong",{children:"save"}),"."]})})}),s(e0,{}),s(X,{condition:Boolean($.flags.SE),show:s(xwe,{segments:c,setSegments:u})}),s(uwe,{projectId:t.project,environmentId:n,strategy:i,setStrategy:l}),s(e0,{}),s(swe,{strategy:i,strategyDefinition:b,setStrategy:l,validateParameter:D,errors:d,hasAccess:v}),s(e0,{}),T(Lwe,{children:[s(zo,{permission:r,projectId:t.project,environmentId:n,variant:"contained",color:"primary",type:"submit",disabled:a||!y||d.hasFormErrors(),"data-testid":Ree,children:f?k:"Save strategy"}),s(Ze,{type:"button",color:"secondary",onClick:U,disabled:a,children:"Cancel"}),s(Awe,{open:h,onClose:()=>m(!1),onClick:o,loading:a,label:"Save strategy"})]})]})},ER=e=>{const t=new URLSearchParams(window.location.search).get(e);if(!t)throw new Error(`Missing required query param: ${e}`);return t},Mwe=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{addStrategyToFeature:async(c,u,d,f)=>{const h=`api/admin/projects/${c}/features/${u}/environments/${d}/strategies`,m=t(h,{method:"POST",body:JSON.stringify(f)},"addStrategyToFeature");return(await e(m.caller,m.id)).json()},updateStrategyOnFeature:async(c,u,d,f,h)=>{const m=`api/admin/projects/${c}/features/${u}/environments/${d}/strategies/${f}`,y=t(m,{method:"PUT",body:JSON.stringify(h)},"updateStrategyOnFeature");await e(y.caller,y.id)},deleteStrategyFromFeature:async(c,u,d,f)=>{const h=`api/admin/projects/${c}/features/${u}/environments/${d}/strategies/${f}`,m=t(h,{method:"DELETE"},"deleteStrategyFromFeature");await e(m.caller,m.id)},setStrategiesSortOrder:async(c,u,d,f)=>{const h=`api/admin/projects/${c}/features/${u}/environments/${d}/strategies/set-sort-order`,m=t(h,{method:"POST",body:JSON.stringify(f)},"setStrategiesSortOrderOnFeature");await e(m.caller,m.id)},loading:r,errors:n}},Dwe=()=>{const[e,t]=p.useState({}),n=p.useCallback(i=>e[i],[e]),r=p.useCallback((i,l)=>{t(Ko(c=>{c[i]=l}))},[t]),o=p.useCallback(i=>{t(Ko(l=>{delete l[i]}))},[t]),a=p.useCallback(()=>Object.values(e).some(Boolean),[e]);return{getFormError:n,setFormError:r,removeFormError:o,hasFormErrors:a}},Bwe=(e,t)=>{const n=t.parameters.map(r=>r.name);return Object.fromEntries(Object.entries(e).sort((r,o)=>n.indexOf(r[0])-n.indexOf(o[0])))};var TR=Object.prototype.hasOwnProperty;function kR(e,t,n){for(n of e.keys())if(Ud(n,t))return n}function Ud(e,t){var n,r,o;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&Ud(e[r],t[r]););return r===-1}if(n===Set){if(e.size!==t.size)return!1;for(r of e)if(o=r,o&&typeof o=="object"&&(o=kR(t,o),!o)||!t.has(o))return!1;return!0}if(n===Map){if(e.size!==t.size)return!1;for(r of e)if(o=r[0],o&&typeof o=="object"&&(o=kR(t,o),!o)||!Ud(r[1],t.get(o)))return!1;return!0}if(n===ArrayBuffer)e=new Uint8Array(e),t=new Uint8Array(t);else if(n===DataView){if((r=e.byteLength)===t.byteLength)for(;r--&&e.getInt8(r)===t.getInt8(r););return r===-1}if(ArrayBuffer.isView(e)){if((r=e.byteLength)===t.byteLength)for(;r--&&e[r]===t[r];);return r===-1}if(!n||typeof e=="object"){r=0;for(n in e)if(TR.call(e,n)&&++r&&!TR.call(t,n)||!(n in t)||!Ud(e[n],t[n]))return!1;return Object.keys(t).length===r}}return e!==e&&t!==t}const Fwe=({refresh:e,show:t,afterSubmitAction:n,data:r,cache:o})=>{const a=on(),i=cr(a.breakpoints.down("sm")),l=p.useMemo(()=>{const c={...Z4,padding:`${a.spacing(3)} ${a.spacing(4)}`,boxShadow:a.boxShadows.elevated,borderRadius:a.shape.borderRadiusLarge,backgroundColor:a.palette.background.paper,maxWidth:a.spacing(75),zIndex:a.zIndex.mobileStepper};return i?{...c,right:0,left:0,bottom:0,borderRadius:0}:c},[a,i]);return T(Rx,{mounted:t,start:l,enter:e3,children:[s(ye,{variant:"h5",sx:{my:2,mb:2},children:"Your data is stale"}),s(ye,{variant:"body1",sx:{my:2,mb:3},children:"The data you have been working on is stale, would you like to refresh your data? This may happen if someone has been making changes to the data while you were working."}),s(Nv,{entry:{preData:o,data:r}}),s(Ze,{sx:{mb:2},variant:"contained",color:"primary",onClick:()=>{e(),n()},children:"Refresh data"})]})},zwe=({unleashGetter:e,dataKey:t="",refetchFunctionKey:n="",options:r={},params:o=[""]})=>{const a=e(...o,{refreshInterval:5,...r});return{data:a[t],refetch:a[n]}},jwe=(e,t,n,r)=>{const{data:o,refetch:a}=zwe(e),[i,l]=p.useState(t||null),[c,u]=p.useState(!1),d=h=>{u(!1),l(h)},f=h=>h&&(r&&typeof r=="function"?r(h):h);return p.useEffect(()=>{i===null&&l(t)},[t]),p.useEffect(()=>{if(!i||!o)return;Ud(f(i),f(o))||u(!0)},[o]),{data:i,refetch:a,staleDataNotification:s(Fwe,{cache:f(i),data:f(o),refresh:()=>d(o),show:c,afterSubmitAction:n.afterSubmitAction}),forceRefreshCache:d}},Uwe=e=>{const t={...e};return delete t.lastSeenAt,t},d2=()=>{const{trackEvent:e}=ka(),{makeRequest:t,createRequest:n,errors:r,loading:o}=Nn({propagateErrors:!0});return{addChange:async(f,h,m)=>{e("change_request",{props:{eventType:"change added"}});const y=`api/admin/projects/${f}/environments/${h}/change-requests`,g=n(y,{method:"POST",body:JSON.stringify(m)});try{return(await t(g.caller,g.id)).json()}catch(v){throw v}},changeState:async(f,h,m)=>{e("change_request",{props:{eventType:m.state}});const y=`api/admin/projects/${f}/change-requests/${h}/state`,g=n(y,{method:"PUT",body:JSON.stringify(m)});try{return(await t(g.caller,g.id)).json()}catch(v){throw v}},discardChange:async(f,h,m)=>{const y=`api/admin/projects/${f}/change-requests/${h}/changes/${m}`,g=n(y,{method:"DELETE"});try{return await t(g.caller,g.id)}catch(v){throw v}},updateChangeRequestEnvironmentConfig:async({project:f,enabled:h,environment:m,requiredApprovals:y})=>{const g=`api/admin/projects/${f}/environments/${m}/change-requests/config`,v=n(g,{method:"PUT",body:JSON.stringify({changeRequestsEnabled:h,requiredApprovals:y})});try{return await t(v.caller,v.id)}catch(b){throw b}},discardDraft:async(f,h)=>{const m=`api/admin/projects/${f}/change-requests/${h}`,y=n(m,{method:"DELETE"});try{return await t(y.caller,y.id)}catch(g){throw g}},addComment:async(f,h,m)=>{e("change_request",{props:{eventType:"comment added"}});const y=`/api/admin/projects/${f}/change-requests/${h}/comments`,g=n(y,{method:"POST",body:JSON.stringify({text:m})});try{return await t(g.caller,g.id)}catch(v){throw v}},errors:r,loading:o}},wIe=()=>{const e=dr("projectId"),t=dr("featureId"),n=ER("environmentId"),r=ER("strategyId"),[o,a]=p.useState({}),[i,l]=p.useState([]),{updateStrategyOnFeature:c,loading:u}=Mwe(),{strategyDefinition:d}=NC(o.name),{setToastData:f,setToastApiError:h}=It(),m=Dwe(),{uiConfig:y}=Lt(),{unleashUrl:g}=y,v=lt(),{addChange:b}=d2(),{isChangeRequestConfigured:w}=of(e),{refetch:x}=Kv(e),{feature:E,refetchFeature:A}=bl(e,t),k=p.useRef(E),{data:_,staleDataNotification:$,forceRefreshCache:L}=jwe({unleashGetter:bl,params:[e,t],dataKey:"feature",refetchFunctionKey:"refetchFeature",options:{}},E,{afterSubmitAction:A},Uwe);p.useEffect(()=>{k.current.name===""&&E.name&&(L(E),k.current=E)},[E]);const{segments:O,refetchSegments:P}=$l(r);p.useEffect(()=>{const Y=_==null?void 0:_.environments.flatMap(V=>V.strategies).find(V=>V.id===r);a(V=>({...V,...Y}))},[r,_]),p.useEffect(()=>{O&&l(O)},[JSON.stringify(O)]);const D=async Y=>{await c(e,t,n,r,Y),await P(),f({title:"Strategy updated",type:"success",confetti:!0})},F=async Y=>{await b(e,n,{action:"updateStrategy",feature:t,payload:{...Y,id:r}}),f({title:"Change added to draft",type:"success",confetti:!0}),x()},U=async()=>{const Y=y!=null&&y.flags.SE?i:[],V=Wwe(o,Y);try{w(n)?await F(V):await D(V),A(),v(p2(e,t))}catch(te){h(ft(te))}};return!o.id||!d||!_?null:T(Mr,{modal:!0,title:Ep(o.name??""),description:Gwe,documentationLink:qwe,documentationLinkLabel:Kwe,formatApiCode:()=>Vwe(e,t,n,o,d,g),children:[s(Nwe,{projectId:e,feature:_,strategy:o,setStrategy:a,segments:i,setSegments:l,environmentId:n,onSubmit:U,loading:u,permission:Wx,errors:m,isChangeRequest:w(n)}),$]})},Wwe=(e,t)=>({name:e.name,constraints:e.constraints??[],parameters:e.parameters??{},segments:t.map(n=>n.id)}),p2=(e,t)=>`/projects/${e}/features/${t}`,Hwe=(e,t,n,r)=>{const o=new URLSearchParams({environmentId:n,strategyId:r});return`/projects/${e}/features/${t}/strategies/edit?${o}`},Vwe=(e,t,n,r,o,a)=>{if(!a)return"";const i={...r,parameters:Bwe(r.parameters??{},o)},l=`${a}/api/admin/projects/${e}/features/${t}/environments/${n}/strategies/${r.id}`,c=JSON.stringify(i,void 0,2);return`curl --location --request PUT '${l}' \\
|
|
351
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
352
|
+
--header 'Content-Type: application/json' \\
|
|
353
|
+
--data-raw '${c}'`},Gwe=`
|
|
354
|
+
An activation strategy will only run when a feature toggle is enabled and provides a way to control who will get access to the feature.
|
|
355
|
+
If any of a feature toggle's activation strategies returns true, the user will get access.
|
|
356
|
+
`,qwe="https://docs.getunleash.io/reference/activation-strategies",Kwe="Strategies documentation",Ywe=C("ul")({marginBottom:0}),Xwe=C(ln)(({theme:e})=>({textDecoration:"none",color:e.palette.primary.main,fontWeight:e.fontWeight.bold})),Jwe=({segment:e,open:t,onClose:n,strategies:r})=>T(Zn,{title:"You can't delete a segment that's currently in use",open:t,primaryButtonText:"OK",onClick:n,children:[T("p",{children:["The following feature toggles are using the"," ",s("strong",{children:e.name})," segment for their strategies:"]}),s(Ywe,{children:r==null?void 0:r.map(o=>s("li",{children:T(Xwe,{to:Hwe(o.projectId,o.featureName,o.environment,o.id),target:"_blank",rel:"noopener noreferrer",children:[o.featureName," ",Qwe(o)]})},o.id))})]}),Qwe=e=>e.strategyName?`(${Ep(e.strategyName)})`:"",Zwe=({segment:e,open:t,onClose:n,onRemove:r})=>{const{strategies:o,loading:a}=Vbe(e.id),i=(o==null?void 0:o.length)===0;return a?null:s(X,{condition:i,show:s(Kbe,{segment:e,open:t,onClose:n,onRemove:r}),elseShow:s(Jwe,{segment:e,open:t,onClose:n,strategies:o})})},eSe=({segment:e})=>{const{refetchSegments:t}=$l(),{deleteSegment:n}=MC(),{setToastData:r,setToastApiError:o}=It(),[a,i]=p.useState(!1),l=async()=>{try{await n(e.id),await t(),r({type:"success",title:"Successfully deleted segment"})}catch(c){o(ft(c))}finally{i(!1)}};return T(ke,{children:[s(ur,{onClick:()=>i(!0),permission:Fne,tooltipProps:{title:"Remove segment"},"data-testid":`${yee}_${e.name}`,children:s(Oo,{"data-loading":!0})}),s(X,{condition:a,show:()=>s(Zwe,{segment:e,open:a,onClose:()=>i(!1),onRemove:l})})]})},tSe=({segment:e})=>{const t=lt();return s(ur,{onClick:()=>t(`/segments/edit/${e.id}`),permission:Hx,tooltipProps:{title:"Edit segment"},children:s(Za,{"data-loading":!0})})},nSe=({segment:e})=>T(ti,{children:[s(tSe,{segment:e}),s(eSe,{segment:e})]}),rSe=()=>{const{segments:e,loading:t}=$l(),n=cr(ws.breakpoints.down("md")),[r]=p.useState({sortBy:[{id:"createdAt"}],hiddenColumns:["description"]}),o=p.useMemo(()=>e??Array(5).fill({name:"Segment name",description:"Segment descripton",createdAt:new Date().toISOString(),createdBy:"user"}),[e]),{getTableProps:a,getTableBodyProps:i,headerGroups:l,rows:c,prepareRow:u,state:{globalFilter:d},setGlobalFilter:f,setHiddenColumns:h}=Kt.useTable({initialState:r,columns:AR,data:o,sortTypes:Aa,autoResetGlobalFilter:!1,autoResetHiddenColumns:!1,autoResetSortBy:!1,disableSortRemove:!0,defaultColumn:{Cell:cs}},Kt.useGlobalFilter,Kt.useSortBy);return af([{condition:n,columns:["createdAt","createdBy"]}],h,AR),s(fr,{header:s(xn,{title:`Segments (${c.length})`,actions:T(ke,{children:[s(Hr,{initialValue:d,onChange:f}),s(xn.Divider,{}),s(Fbe,{})]})}),isLoading:t,children:s(X,{condition:!t&&o.length===0,show:s(Un,{children:s(Hbe,{})}),elseShow:()=>T(ke,{children:[s(Di,{value:d,children:T(Mi,{...a(),rowHeight:"standard",children:[s(Ni,{headerGroups:l}),s($i,{...i(),children:c.map(m=>(u(m),s(ai,{hover:!0,...m.getRowProps(),children:m.cells.map(y=>s(ei,{...y.getCellProps(),children:y.render("Cell")}))})))})]})}),s(X,{condition:c.length===0&&(d==null?void 0:d.length)>0,show:T(Un,{children:["No segments found matching “",d,"”"]})})]})})})},AR=[{id:"Icon",width:"1%",disableGlobalFilter:!0,disableSortBy:!0,Cell:()=>s(_v,{icon:s($4,{color:"disabled"})})},{Header:"Name",accessor:"name",width:"60%",Cell:({value:e,row:{original:t}})=>s(cs,{value:e,subtitle:t.description})},{Header:"Created at",accessor:"createdAt",minWidth:150,Cell:Cp,disableGlobalFilter:!0},{Header:"Created by",accessor:"createdBy",width:"25%"},{Header:"Actions",id:"Actions",align:"center",width:"1%",disableSortBy:!0,disableGlobalFilter:!0,Cell:({row:{original:e}})=>s(nSe,{segment:e})},{accessor:"description"}],oSe=e=>fetch(e).then(yn("Feature toggle archive")).then(t=>t.json()),aSe=e=>{const{data:t,error:n,mutate:r,isLoading:o}=dn(Dt(e?`/api/admin/archive/features/${e}`:"api/admin/features"),oSe,{refreshInterval:15e3});return{archivedFeatures:t==null?void 0:t.features,refetchArchived:r,loading:o,error:n}},iSe=({onRevive:e,onDelete:t,project:n})=>T(ti,{children:[s(ur,{onClick:e,projectId:n,permission:f3,tooltipProps:{title:"Revive feature toggle"},children:s(KZ,{})}),s(ur,{permission:Rne,projectId:n,tooltipProps:{title:"Delete feature toggle"},onClick:t,children:s(Oo,{})})]}),VL=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{reviveFeature:async i=>{const l=`api/admin/archive/revive/${i}`,c=t(l,{method:"POST"});return e(c.caller,c.id)},deleteFeature:async i=>{const l=`api/admin/archive/${i}`,c=t(l,{method:"DELETE"});return e(c.caller,c.id)},errors:n,loading:r}},sSe=({value:e})=>{const{locationSettings:t}=ii(),n=on();return e?s(eo,{children:s(_t,{title:`Archived on: ${Uc(e,t.locale)}`,arrow:!0,children:s(ye,{noWrap:!0,variant:"body2","data-loading":!0,children:s(wv,{date:new Date(e),title:"",live:!1})})})}):s(eo,{children:s(ye,{variant:"body2",color:n.palette.text.secondary,children:"not available"})})},lSe=C("p")(({theme:e})=>({marginTop:e.spacing(3)})),cSe=C(_r)(({theme:e})=>({marginTop:e.spacing(2),width:"100%"})),uSe=({deletedFeature:e,open:t,setOpen:n,refetch:r})=>{const[o,a]=p.useState(""),{setToastData:i,setToastApiError:l}=It(),{deleteFeature:c}=VL(),u=async()=>{try{if(!e)return;await c(e.name),await r(),i({type:"success",title:"Feature toggle deleted",text:`You have successfully deleted the ${e.name} feature toggle.`})}catch(h){l(ft(h))}finally{d()}},d=()=>{n(!1),a("")},f="delete-feature-toggle-confirmation-form";return T(Zn,{title:"Delete feature toggle?",open:t,primaryButtonText:"Delete feature toggle",secondaryButtonText:"Cancel",onClick:u,onClose:d,disabledPrimaryButton:(e==null?void 0:e.name)!==o,formId:f,children:[T(Zt,{severity:"warning",children:[s("b",{children:"Warning!"})," Before you delete a feature toggle, make sure all in-code references to that feature toggle have been removed. Otherwise, a new feature toggle with the same name could activate the old code paths."]}),T(lSe,{children:["In order to delete this feature toggle, please enter its name in the text field below: ",s("strong",{children:e==null?void 0:e.name})]}),s("form",{id:f,children:s(cSe,{autoFocus:!0,onChange:h=>{a(h.currentTarget.value)},value:o,placeholder:"<feature toggle name>",label:"Feature toggle name"})})]})},dSe=({archivedFeatures:e=[],loading:t,refetch:n,storedParams:r,setStoredParams:o,title:a,projectId:i})=>{const l=cr(ws.breakpoints.down("md")),c=cr(ws.breakpoints.down("lg")),{setToastData:u,setToastApiError:d}=It(),[f,h]=p.useState(!1),[m,y]=p.useState(),[g,v]=tu(),{reviveFeature:b}=VL(),[w,x]=p.useState(g.get("search")||""),E=p.useCallback(async V=>{try{await b(V),await n(),u({type:"success",title:"And we're back!",text:"The feature toggle has been revived."})}catch(te){d(ft(te))}},[n,b,d,u]),A=p.useMemo(()=>[{Header:"Seen",width:85,canSort:!0,Cell:_3,accessor:"lastSeenAt",align:"center"},{Header:"Type",accessor:"type",width:85,canSort:!0,Cell:$3,align:"center"},{Header:"Name",accessor:"name",searchable:!0,minWidth:100,Cell:({value:V,row:{original:te}})=>s(cs,{value:V,subtitle:te.description}),sortType:"alphanumeric"},{Header:"Created",accessor:"createdAt",width:150,Cell:Cp,sortType:"date"},{Header:"Archived",accessor:"archivedAt",width:150,Cell:sSe,sortType:"date"},...i?[]:[{Header:"Project ID",accessor:"project",sortType:"alphanumeric",filterName:"project",searchable:!0,maxWidth:170,Cell:({value:V})=>s(Is,{title:V,to:`/projects/${V}`})}],{Header:"State",accessor:"stale",Cell:D3,sortType:"boolean",maxWidth:120,filterName:"state",filterParsing:V=>V?"stale":"active"},{Header:"Actions",id:"Actions",align:"center",maxWidth:120,canSort:!1,Cell:({row:{original:V}})=>s(iSe,{project:V.project,onRevive:()=>E(V.name),onDelete:()=>{y(V),h(!0)}})},{accessor:"description",header:"Description",searchable:!0}],[i]),{data:k,getSearchText:_,getSearchContext:$}=Tv(A,w,e),L=p.useMemo(()=>t?H3:k,[k,t]),[O]=p.useState(()=>({sortBy:[{id:g.get("sort")||r.id,desc:g.has("order")?g.get("order")==="desc":r.desc}],hiddenColumns:["description"]})),{headerGroups:P,rows:D,state:{sortBy:F},prepareRow:U,setHiddenColumns:Y}=Kt.useTable({columns:A,data:L,initialState:O,sortTypes:Aa,autoResetHiddenColumns:!1,disableSortRemove:!0,autoResetSortBy:!1},Kt.useFlexLayout,Kt.useSortBy);return af([{condition:l,columns:["type","createdAt"]},{condition:c,columns:["lastSeenAt","stale"]}],Y,A),p.useEffect(()=>{if(t)return;const V={};V.sort=F[0].id,F[0].desc&&(V.order="desc"),w&&(V.search=w),v(V,{replace:!0}),o({id:F[0].id,desc:F[0].desc||!1})},[t,F,w]),T(fr,{isLoading:t,header:s(xn,{titleElement:`${a} (${D.length<L.length?`${D.length} of ${L.length}`:L.length})`,actions:s(Hr,{initialValue:w,onChange:x,hasFilters:!0,getSearchContext:$})}),children:[s(Di,{value:_(w),children:s(vv,{rows:D,headerGroups:P,prepareRow:U})}),s(X,{condition:D.length===0,show:()=>s(X,{condition:(w==null?void 0:w.length)>0,show:T(Un,{children:["No feature toggles found matching “",w,"”"]}),elseShow:s(Un,{children:"None of the feature toggles were archived yet."})})}),s(uSe,{deletedFeature:m,open:f,setOpen:h,refetch:n})]})},pSe={id:"createdAt"},{value:fSe,setValue:hSe}=lu("FeaturesArchiveTable:v1",pSe),mSe=()=>{O3("Archive");const{archivedFeatures:e=[],loading:t,refetchArchived:n}=aSe();return s(dSe,{title:"Archive",archivedFeatures:e,loading:t,storedParams:fSe,setStoredParams:hSe,refetch:n})},gSe=p.lazy(()=>import("./Playground-f8d65d33.js")),vSe=C(Ze)(({theme:e,selected:t})=>({"&.MuiButton-root":{cursor:"pointer",height:e.spacing(6.5),border:0,backgroundColor:t?e.palette.background.paper:"transparent",borderLeft:`${e.spacing(1)} solid ${t?e.palette.primary.main:"transparent"}`,borderRadius:e.shape.borderRadiusMedium,justifyContent:"start",transition:"background-color 0.2s ease",color:e.palette.text.primary,textAlign:"left",padding:e.spacing(2,4),fontSize:e.fontSizes.bodySize,fontWeight:t?e.fontWeight.bold:e.fontWeight.medium,lineHeight:1.2},"&:hover":{backgroundColor:e.palette.neutral.light},"&.Mui-disabled":{pointerEvents:"auto"},justifyContent:"space-between"})),ySe=({label:e,selected:t,onClick:n})=>s(vSe,{selected:Boolean(t),onClick:n,disableRipple:!0,disableElevation:!0,disableFocusRipple:!0,disableTouchRipple:!0,fullWidth:!0,children:e}),bSe=C("div")(({theme:e})=>({display:"flex",gap:e.spacing(3),[e.breakpoints.down("md")]:{flexDirection:"column"}})),wSe=C("div")(()=>({flexGrow:1,display:"flex",flexDirection:"column"})),SSe=C("div")(({theme:e})=>({display:"flex",flexDirection:"column",gap:e.spacing(1),width:e.spacing(30),flexShrink:0,[e.breakpoints.down("md")]:{width:"100%"}})),xSe=({tabs:e,value:t,onChange:n,children:r})=>T(bSe,{children:[s(SSe,{children:e.filter(o=>!o.hidden).map(o=>s(ySe,{label:o.label,selected:o.id===t,onClick:()=>n(o)},o.id))}),s(wSe,{children:r})]}),CSe=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{changePassword:async a=>{const i=t("api/admin/user/change-password",{method:"POST",body:JSON.stringify(a)});try{await e(i.caller,i.id)}catch(l){throw l}},errors:n,loading:r}},ESe=C("form")(({theme:e})=>({display:"flex",flexDirection:"column",gap:e.spacing(2),maxWidth:e.spacing(44)})),TSe=()=>{const[e,t]=p.useState(!1),{setToastData:n,setToastApiError:r}=It(),[o,a]=p.useState(!1),[i,l]=p.useState(),[c,u]=p.useState(""),[d,f]=p.useState(""),{changePassword:h}=CSe(),m=async y=>{if(y.preventDefault(),c===d){if(!o)l(uO);else{t(!0),l(void 0);try{await h({password:c,confirmPassword:d}),n({title:"Password changed successfully",text:"Now you can sign in using your new password.",type:"success"})}catch(g){const v=ft(g);l(v),r(v)}}t(!1)}};return s(fr,{isLoading:e,header:"Change password",children:T(ESe,{children:[s(dO,{password:c,callback:a,"data-loading":!0}),s(Hc,{"data-loading":!0,label:"Password",name:"password",value:c,error:Boolean(i),helperText:i,autoComplete:"new-password",onChange:y=>u(y.target.value)}),s(Hc,{"data-loading":!0,label:"Confirm password",name:"confirmPassword",value:d,autoComplete:"new-password",onChange:y=>f(y.target.value)}),s(fO,{"data-loading":!0,started:Boolean(c&&d),matchingPasswords:c===d}),s(Ze,{"data-loading":!0,variant:"contained",color:"primary",type:"submit",onClick:m,children:"Save"})]})})},kSe=10,f2=e=>{const{data:t,error:n,mutate:r}=dn(Dt(e?`api/admin/user-admin/${e}/pat`:"api/admin/user/tokens"),ASe);return{tokens:t?t.pats:void 0,loading:!n&&!t,refetchTokens:()=>r(),error:n}},ASe=e=>fetch(e).then(yn("Personal API Tokens")).then(t=>t.json()),GL=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{createPersonalAPIToken:async c=>{const u=t("api/admin/user/tokens",{method:"POST",body:JSON.stringify(c)});try{return await(await e(u.caller,u.id)).json()}catch(d){throw d}},deletePersonalAPIToken:async c=>{const u=t(`api/admin/user/tokens/${c}`,{method:"DELETE"});try{await e(u.caller,u.id)}catch(d){throw d}},createUserPersonalAPIToken:async(c,u)=>{const d=t(`api/admin/user-admin/${c}/pat`,{method:"POST",body:JSON.stringify(u)});try{return await(await e(d.caller,d.id)).json()}catch(f){throw f}},deleteUserPersonalAPIToken:async(c,u)=>{const d=t(`api/admin/user-admin/${c}/pat/${u}`,{method:"DELETE"});try{await e(d.caller,d.id)}catch(f){throw f}},errors:n,loading:r}},_Se=e=>{const t=new Date(e);return xp(t,"yyyy-MM-dd")},RSe=e=>{const t=new Date(e);return xp(t,"yyyy-MM-dd")+"T"+xp(t,"HH:mm")},PSe=({label:e,type:t="datetime",error:n,errorText:r,min:o,max:a,value:i,onChange:l,...c})=>{const u=t==="datetime"?RSe:_Se;return s(mn,{type:t==="datetime"?"datetime-local":"date",size:"small",variant:"outlined",label:e,error:n,helperText:r,value:u(i.toISOString()),onChange:f=>{const h=xO(f.target.value);l(h??i)},FormHelperTextProps:{["data-testid"]:G4},inputProps:{min:o&&u(o.toISOString()),max:a&&u(a.toISOString())},...c})},_R=C("p")(({theme:e})=>({color:e.palette.text.secondary,marginBottom:e.spacing(1)})),ISe=C(_r)(({theme:e})=>({width:"100%",maxWidth:e.spacing(50),marginBottom:e.spacing(2)})),$Se=C("div")(({theme:e,custom:t})=>({display:"flex",alignItems:t?"start":"center",gap:e.spacing(1.5),marginBottom:e.spacing(2),[e.breakpoints.down("sm")]:{flexDirection:"column",alignItems:"flex-start"}})),OSe=C(jL)(({theme:e})=>({minWidth:e.spacing(20),marginRight:e.spacing(.5),[e.breakpoints.down("sm")]:{width:e.spacing(50)}})),LSe=C(PSe)(({theme:e})=>({width:e.spacing(28),[e.breakpoints.down("sm")]:{width:e.spacing(50)}})),NSe=C(Zt)(({theme:e})=>({marginBottom:e.spacing(2),maxWidth:e.spacing(50)}));var qL=(e=>(e["7DAYS"]="7d",e["30DAYS"]="30d",e["60DAYS"]="60d",e.NEVER="never",e.CUSTOM="custom",e))(qL||{});const KL=[{key:"7d",days:7,label:"7 days"},{key:"30d",days:30,label:"30 days"},{key:"60d",days:60,label:"60 days"},{key:"never",label:"Never"},{key:"custom",label:"Custom"}],dw=e=>{const t=new Date,n=KL.find(({key:r})=>r===e);return e==="never"?t.setFullYear(t.getFullYear()+1e3):e==="custom"?t.setMinutes(t.getMinutes()+30):n!=null&&n.days&&t.setDate(t.getDate()+n.days),t},MSe=({description:e,setDescription:t,isDescriptionUnique:n,expiration:r,setExpiration:o,expiresAt:a,setExpiresAt:i,errors:l,setErrors:c})=>{const{locationSettings:u}=ii(),d=g=>{c(v=>({...v,[g]:void 0}))},f=(g,v)=>{c(b=>({...b,[g]:v}))};p.useEffect(()=>{d("expiresAt"),i(dw(r))},[r]);const h=g=>{d("description"),n&&!n(g)&&f("description","A token with that description already exists."),t(g)},m=r==="custom",y=a.getFullYear()>new Date().getFullYear()+100;return T(ke,{children:[s(_R,{children:"Describe what this token will be used for"}),s(ISe,{autoFocus:!0,label:"Description",error:Boolean(l.description),errorText:l.description,value:e,onChange:g=>h(g.target.value),required:!0}),s(_R,{children:"Token expiration date"}),T($Se,{custom:m,children:[s(OSe,{name:"expiration",id:"expiration",label:"Token will expire in",value:r,onChange:g=>o(g.target.value),options:KL}),s(X,{condition:m,show:()=>s(LSe,{label:"Date",value:a,onChange:g=>{d("expiresAt"),g<new Date&&f("expiresAt","Invalid date, must be in the future"),i(g)},min:new Date,error:Boolean(l.expiresAt),errorText:l.expiresAt,required:!0}),elseShow:s(X,{condition:y,show:T(ye,{variant:"body2",children:["The token will ",s("strong",{children:"never"})," ","expire!"]}),elseShow:()=>T(ye,{variant:"body2",children:["Token will expire on"," ",s("strong",{children:Uc(a,u.locale)})]})})})]}),s(X,{condition:y,show:s(NSe,{severity:"warning",children:"We strongly recommend that you set an expiration date for your token to help keep your information secure."})})]})},DSe=C("form")(()=>({display:"flex",flexDirection:"column",height:"100%"})),BSe=C("div")(({theme:e})=>({marginTop:"auto",display:"flex",justifyContent:"flex-end",[e.breakpoints.down("sm")]:{marginTop:e.spacing(4)}})),FSe=C(Ze)(({theme:e})=>({marginLeft:e.spacing(3)})),hh=qL["30DAYS"],zSe=({open:e,setOpen:t,newToken:n})=>{const{tokens:r,refetchTokens:o}=f2(),{createPersonalAPIToken:a,loading:i}=GL(),{setToastApiError:l}=It(),{uiConfig:c}=Lt(),[u,d]=p.useState(""),[f,h]=p.useState(hh),[m,y]=p.useState(dw(hh)),[g,v]=p.useState({});p.useEffect(()=>{d(""),h(hh),y(dw(hh)),v({})},[e]);const b=()=>({description:u,expiresAt:m}),w=async _=>{_.preventDefault();try{const $=await a(b());n($),o(),t(!1)}catch($){l(ft($))}},x=()=>`curl --location --request POST '${c.unleashUrl}/api/admin/user/tokens' \\
|
|
357
|
+
--header 'Authorization: INSERT_API_KEY' \\
|
|
358
|
+
--header 'Content-Type: application/json' \\
|
|
359
|
+
--data-raw '${JSON.stringify(b(),void 0,2)}'`,E=_=>_.length,A=_=>!(r!=null&&r.some($=>$.description===_)),k=E(u)&&A(u)&&m>new Date;return s(FC,{open:e,onClose:()=>{t(!1)},label:"Create personal API token",children:s(Mr,{loading:i,modal:!0,title:"Create personal API token",description:`Use personal API tokens to authenticate to the Unleash API as
|
|
360
|
+
yourself. A personal API token has the same access privileges as
|
|
361
|
+
your user.`,documentationLink:"https://docs.getunleash.io/reference/api-tokens-and-client-keys",documentationLinkLabel:"Tokens documentation",formatApiCode:x,children:T(DSe,{onSubmit:w,children:[s("div",{children:s(MSe,{description:u,setDescription:d,isDescriptionUnique:A,expiration:f,setExpiration:h,expiresAt:m,setExpiresAt:y,errors:g,setErrors:v})}),T(BSe,{children:[s(Ze,{type:"submit",variant:"contained",color:"primary",disabled:!k,children:"Create token"}),s(FSe,{onClick:()=>{t(!1)},children:"Cancel"})]})]})})})},jSe=({open:e,setOpen:t,token:n})=>{const{refetchTokens:r}=f2(),{deletePersonalAPIToken:o}=GL(),{setToastData:a,setToastApiError:i}=It();return s(Zn,{open:e,primaryButtonText:"Delete token",secondaryButtonText:"Cancel",onClick:async()=>{if(n)try{await o(n==null?void 0:n.id),r(),t(!1),a({title:"Token deleted successfully",type:"success"})}catch(c){i(ft(c))}},onClose:()=>{t(!1)},title:"Delete token?",children:T(ye,{children:['Any applications or scripts using this token "',s("strong",{children:n==null?void 0:n.description}),'" will no longer be able to access the Unleash API. You cannot undo this action.']})})},USe=C(Zt)(({theme:e})=>({marginBottom:e.spacing(3)})),WSe=({open:e,setOpen:t,token:n})=>T(Zn,{open:e,secondaryButtonText:"Close",onClose:(r,o)=>{o||t(!1)},title:"Personal API token created",children:[s(USe,{severity:"info",children:"Make sure to copy your personal API token now. You won't be able to see it again!"}),s(ye,{variant:"body1",children:"Your token:"}),s(DL,{token:(n==null?void 0:n.secret)||""})]}),YL=({value:e,live:t=!1,emptyText:n,title:r,dateFormat:o=Uc})=>{const{locationSettings:a}=ii();if(!e)return s(eo,{children:n});const i=o(e,a.locale);return s(eo,{children:s(_t,{title:(r==null?void 0:r(i))??i,arrow:!0,children:s(ye,{noWrap:!0,component:"span",variant:"body2","data-loading":!0,children:s(wv,{date:new Date(e),live:t,title:""})})})})},HSe=C(Zt)(({theme:e})=>({marginBottom:e.spacing(3)})),VSe=C("div")(({theme:e})=>({display:"flex",flexDirection:"column",alignItems:"center",padding:e.spacing(10,2)})),GSe=C(ye)(({theme:e})=>({fontSize:e.fontSizes.mainHeader,marginBottom:e.spacing(1.5)})),qSe=C(ye)(({theme:e})=>({color:e.palette.text.secondary,marginBottom:e.spacing(4.5)})),KSe=Array(15).fill({description:"Short description of the feature",type:"-",createdAt:new Date(2022,1,1),project:"projectID"}),YSe={id:"createdAt"},{value:RR,setValue:XSe}=lu("PersonalAPITokensTable:v1",YSe),JSe=()=>{const e=on(),t=cr(e.breakpoints.down("md")),n=cr(e.breakpoints.down("sm")),{tokens:r=[],loading:o}=f2(),[a,i]=tu(),[l]=p.useState(()=>({sortBy:[{id:a.get("sort")||RR.id,desc:a.has("order")?a.get("order")==="desc":RR.desc}],globalFilter:a.get("search")||""})),[c,u]=p.useState(l.globalFilter),[d,f]=p.useState(!1),[h,m]=p.useState(!1),[y,g]=p.useState(!1),[v,b]=p.useState(),[w,x]=p.useState(),E=p.useMemo(()=>[{Header:"Description",accessor:"description",Cell:cs,minWidth:100,searchable:!0},{Header:"Expires",accessor:"expiresAt",Cell:({value:U})=>new Date(U).getFullYear()>new Date().getFullYear()+100?s(eo,{children:"Never"}):s(Cp,{value:U}),sortType:"date",maxWidth:150},{Header:"Created",accessor:"createdAt",Cell:Cp,sortType:"date",maxWidth:150},{Header:"Last seen",accessor:"seenAt",Cell:YL,sortType:"date",maxWidth:150},{Header:"Actions",id:"Actions",align:"center",Cell:({row:{original:U}})=>s(ti,{children:s(_t,{title:"Delete token",arrow:!0,describeChild:!0,children:s("span",{children:s(Yt,{onClick:()=>{x(U),g(!0)},children:s(Oo,{})})})})}),maxWidth:100,disableSortBy:!0}],[x,g]),{data:A,getSearchText:k,getSearchContext:_}=Tv(E,c,r),$=p.useMemo(()=>(A==null?void 0:A.length)===0&&o?KSe:A,[A,o]),{headerGroups:L,rows:O,prepareRow:P,state:{sortBy:D},setHiddenColumns:F}=Kt.useTable({columns:E,data:$,initialState:l,sortTypes:Aa,autoResetHiddenColumns:!1,autoResetSortBy:!1,disableSortRemove:!0,disableMultiSort:!0},Kt.useSortBy,Kt.useFlexLayout);return af([{condition:n,columns:["expiresAt"]},{condition:t,columns:["createdAt"]}],F,E),p.useEffect(()=>{const U={};U.sort=D[0].id,D[0].desc&&(U.order="desc"),c&&(U.search=c),i(U,{replace:!0}),XSe({id:D[0].id,desc:D[0].desc||!1})},[D,c,i]),T(fr,{isLoading:o,header:s(xn,{title:`Personal API tokens (${O.length<$.length?`${O.length} of ${$.length}`:$.length})`,actions:T(ke,{children:[s(X,{condition:!t,show:T(ke,{children:[s(Hr,{initialValue:c,onChange:u,getSearchContext:_}),s(xn.Divider,{})]})}),s(Ze,{variant:"contained",color:"primary",disabled:r.length>=kSe,onClick:()=>f(!0),children:"New token"})]}),children:s(X,{condition:t,show:s(Hr,{initialValue:c,onChange:u,hasFilters:!0,getSearchContext:_})})}),children:[s(HSe,{severity:"info",children:"Use personal API tokens to authenticate to the Unleash API as yourself. A personal API token has the same access privileges as your user."}),s(Di,{value:k(c),children:s(vv,{rows:O,headerGroups:L,prepareRow:P})}),s(X,{condition:O.length===0,show:s(X,{condition:(c==null?void 0:c.length)>0,show:T(Un,{children:["No tokens found matching “",c,"”"]}),elseShow:T(VSe,{children:[s(GSe,{children:"You have no personal API tokens yet."}),s(qSe,{variant:"body2",children:"Need an API token for scripts or testing? Create a personal API token for quick access to the Unleash API."}),s(Ze,{variant:"outlined",onClick:()=>f(!0),children:"Create your first token"})]})})}),s(zSe,{open:d,setOpen:f,newToken:U=>{b(U),m(!0)}}),s(WSe,{open:h,setOpen:m,token:v}),s(jSe,{open:y,setOpen:g,token:w})]})},QSe=()=>{const{data:e,error:t,mutate:n}=dn(Dt("api/admin/user/profile"),ZSe);return{profile:e,loading:!t&&!e,refetchProfile:()=>n(),error:t}},ZSe=e=>fetch(e).then(yn("Profile")).then(t=>t.json());var h2={},exe=cn;Object.defineProperty(h2,"__esModule",{value:!0});var XL=h2.default=void 0,txe=exe(Cn()),nxe=En,rxe=(0,txe.default)((0,nxe.jsx)("path",{d:"M11 7h2v2h-2zm0 4h2v6h-2zm1-9C6.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-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"}),"InfoOutlined");XL=h2.default=rxe;var m2={},oxe=cn;Object.defineProperty(m2,"__esModule",{value:!0});var JL=m2.default=void 0,axe=oxe(Cn()),ixe=En,sxe=(0,axe.default)((0,ixe.jsx)("path",{d:"M20 6h-8l-2-2H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16.77c.68 0 1.23-.56 1.23-1.23V8c0-1.1-.9-2-2-2zm0 12H4V6h5.17l2 2H20v10zm-2-6H6v-2h12v2zm-4 4H6v-2h8v2z"}),"TopicOutlined");JL=m2.default=sxe;const lxe=C("div")(({theme:e})=>({display:"flex",flexDirection:"row",alignItems:"center",padding:e.spacing(6),borderRadius:e.shape.borderRadiusLarge,backgroundColor:e.palette.primary.main,color:e.palette.text.tertiaryContrast,marginBottom:e.spacing(3),boxShadow:e.boxShadows.primaryHeader})),cxe=C("div")(()=>({flexGrow:1})),uxe=C(ye)(({theme:e})=>({fontSize:e.spacing(3.75)})),dxe=C(Dx)(({theme:e})=>({width:e.spacing(9.5),height:e.spacing(9.5),marginRight:e.spacing(3)})),PR=C(ye)(({theme:e})=>({fontSize:e.fontSizes.mainHeader,marginBottom:e.spacing(3)})),pxe=C("div")(({theme:e})=>({display:"flex",flexDirection:"row","& > div > p":{marginBottom:e.spacing(1.5)}})),fxe=C(Io)(({theme:e})=>({cursor:"pointer",marginRight:e.spacing(1)})),hxe=C("div")(({theme:e})=>({width:"100%",height:"1px",backgroundColor:e.palette.divider,margin:e.spacing(3,0)})),mxe=C(Pi)(({theme:e})=>({marginTop:e.spacing(1.5),width:e.spacing(30)})),gxe=C(Yp)(({theme:e})=>({backgroundColor:e.palette.inputLabelBackground})),vxe=({user:e})=>{const{profile:t}=QSe(),n=lt(),{locationSettings:r,setLocationSettings:o}=ii(),[a,i]=p.useState(),[l,c]=p.useState(["en-US","en-GB","nb-NO","sv-SE","da-DK","en-IN","de","cs","pt-BR","fr-FR"]);p.useEffect(()=>{const d=l.find(f=>f.toLowerCase().includes(r.locale.toLowerCase()));i(d),d||c(f=>[...f,r.locale])},[r]);const u=d=>{const f=d.target.value;i(f),o({locale:f})};return T(ke,{children:[T(lxe,{children:[s(dxe,{user:e}),T(cxe,{children:[s(uxe,{children:e.name||e.username}),s(ye,{variant:"body1",children:e.email})]})]}),T(fr,{children:[s(PR,{children:"Access"}),T(pxe,{children:[T(Me,{sx:{width:"50%"},children:[s(ye,{variant:"body2",children:"Your root role"}),s(_t,{title:(t==null?void 0:t.rootRole.description)||"",arrow:!0,placement:"bottom-end",describeChild:!0,children:s(Io,{color:"success",icon:s(XL,{}),iconRight:!0,children:t==null?void 0:t.rootRole.name})})]}),T(Me,{children:[s(ye,{variant:"body2",children:"Projects"}),s(X,{condition:Boolean(t==null?void 0:t.projects.length),show:t==null?void 0:t.projects.map(d=>s(_t,{title:"View project",arrow:!0,placement:"bottom-end",describeChild:!0,children:s(fxe,{onClick:f=>{f.preventDefault(),n(`/projects/${d}`)},color:"secondary",icon:s(JL,{}),children:d})},d)),elseShow:s(_t,{title:"You are not assigned to any projects",arrow:!0,describeChild:!0,children:s(Io,{children:"No projects"})})})]})]}),s(hxe,{}),s(PR,{children:"Settings"}),s(ye,{variant:"body2",children:"This is the format used across the system for time and date"}),T(mxe,{variant:"outlined",size:"small",children:[s(gxe,{htmlFor:"locale-select",children:"Date/Time formatting"}),s(Xp,{id:"locale-select",value:a||"",native:!0,onChange:u,MenuProps:{style:{zIndex:9999}},children:l.map(d=>s("option",{value:d,children:d},d))})]})]})]})},yxe=()=>{const{user:e}=ca(),t=ia(),n=lt(),r=[{id:"profile",label:"Profile"},{id:"password",label:"Change password",path:"change-password"},{id:"pat",label:"Personal API tokens",path:"personal-api-tokens"}],o=c=>{n(c.path?`/profile/${c.path}`:"/profile",{replace:!0}),l(c.id)},a=()=>{const c=t.pathname;return(r.find(({path:d})=>d&&c.includes(d))||r[0]).id},[i,l]=p.useState(a());return p.useEffect(()=>{l(a())},[t]),T(xSe,{tabs:r,value:i,onChange:o,children:[s(X,{condition:i==="profile",show:s(vxe,{user:e})}),s(X,{condition:i==="password",show:s(TSe,{})}),s(X,{condition:i==="pat",show:s(JSe,{})})]})},bxe=p.lazy(()=>import("./CreateProject-f7ca75e0.js")),wxe=p.lazy(()=>import("./FeatureViewLazyExport-fe2a9be7.js")),Sxe=p.lazy(()=>import("./LazyAdminExport-9ff8d442.js")),xxe=p.lazy(()=>import("./LazyProjectExport-644ec52e.js")),Cxe=()=>s(_l,{to:"/admin/users",replace:!0}),Exe=()=>{const{uiConfig:e,isEnterprise:t}=Lt(),{signOnLog:n}=e.flags,{data:r,error:o,mutate:a}=Ev(n&&t(),{events:[]},Dt("api/admin/signons"),Txe);return p.useMemo(()=>({events:(r==null?void 0:r.events)??[],loading:!o&&!r,refetch:()=>a(),error:o}),[r,o,a])},Txe=e=>fetch(e).then(yn("Sign-On Log")).then(t=>t.json()),IR=C(Me)(()=>({display:"flex",justifyContent:"center"})),kxe=({row:e,value:t})=>{const{searchQuery:n}=su();return t?s(IR,{children:s(Io,{color:"success",children:"True"})}):s(IR,{children:s(xv,{arrow:!0,title:s(yl,{search:n,children:e.original.failure_reason}),children:s(Io,{color:"error",children:"False"})})})},Axe=C(Me)(()=>({display:"flex",justifyContent:"center"})),_xe=({onDelete:e})=>s(Axe,{children:s(ur,{"data-loading":!0,onClick:e,permission:Fo,tooltipProps:{title:"Remove event"},children:s(Oo,{})})}),Rxe=({event:e,open:t,setOpen:n,onConfirm:r})=>T(Zn,{title:"Delete event?",open:t,primaryButtonText:"Delete event",secondaryButtonText:"Cancel",onClick:()=>r(e),onClose:()=>{n(!1)},children:["You are about to delete event: ",T("strong",{children:["#",e==null?void 0:e.id]})]}),Pxe=()=>{const{loading:e,makeRequest:t,createRequest:n,errors:r}=Nn({propagateErrors:!0});return{removeEvent:async a=>{const i="removeEvent",l=n(`api/admin/signons/${a}`,{method:"DELETE"},i);await t(l.caller,l.id)},errors:r,loading:e}},Ixe={id:"created_at"},{value:$R,setValue:$xe}=lu("SignOnLogTable:v1",Ixe),Oxe=()=>{const{setToastData:e,setToastApiError:t}=It(),{events:n,loading:r,refetch:o}=Exe(),{removeEvent:a}=Pxe(),[i,l]=tu(),[c]=p.useState(()=>({sortBy:[{id:i.get("sort")||$R.id,desc:i.has("order")?i.get("order")==="desc":$R.desc}],hiddenColumns:["failure_reason"],globalFilter:i.get("search")||""})),[u,d]=p.useState(c.globalFilter),[f,h]=p.useState(!1),[m,y]=p.useState(),g=async P=>{try{await a(P.id),e({title:"Event has been deleted",type:"success"}),o(),h(!1)}catch(D){t(ft(D))}},v=cr(ws.breakpoints.down("sm")),b=cr(ws.breakpoints.down("md")),w=p.useMemo(()=>[{Header:"Created",accessor:"created_at",Cell:({value:P})=>s(YL,{value:P,dateFormat:bv}),sortType:"date",maxWidth:150},{Header:"Username",accessor:"username",minWidth:100,Cell:cs,searchable:!0},{Header:"Authentication",accessor:P=>P.auth_type==="simple"?"Password":P.auth_type.toUpperCase(),width:150,maxWidth:150,Cell:cs,searchable:!0,filterName:"auth"},{Header:"IP address",accessor:"ip",Cell:cs,searchable:!0},{Header:"Success",accessor:"successful",align:"center",Cell:kxe,filterName:"success",filterParsing:P=>P.toString()},{Header:"Actions",id:"Actions",align:"center",Cell:({row:{original:P}})=>s(_xe,{onDelete:()=>{y(P),h(!0)}}),width:150,disableSortBy:!0},{accessor:"failure_reason",Header:"Failure Reason",searchable:!0}],[]),{data:x,getSearchText:E,getSearchContext:A}=Tv(w,u,n),{headerGroups:k,rows:_,prepareRow:$,state:{sortBy:L},setHiddenColumns:O}=Kt.useTable({columns:w,data:x,initialState:c,sortTypes:Aa,autoResetHiddenColumns:!1,autoResetSortBy:!1,disableSortRemove:!0,disableMultiSort:!0,defaultColumn:{Cell:eo}},Kt.useSortBy,Kt.useFlexLayout);return af([{condition:v,columns:["role","seenAt"]},{condition:b,columns:["imageUrl","tokens","createdAt"]}],O,w),p.useEffect(()=>{const P={};P.sort=L[0].id,L[0].desc&&(P.order="desc"),u&&(P.search=u),l(P,{replace:!0}),$xe({id:L[0].id,desc:L[0].desc||!1})},[L,u,l]),T(fr,{isLoading:r,header:s(xn,{title:`Sign-on log (${_.length})`,actions:s(X,{condition:!b,show:s(Hr,{initialValue:u,onChange:d,hasFilters:!0,getSearchContext:A})}),children:s(X,{condition:b,show:s(Hr,{initialValue:u,onChange:d,hasFilters:!0,getSearchContext:A})})}),children:[s(Di,{value:E(u),children:s(vv,{rows:_,headerGroups:k,prepareRow:$})}),s(X,{condition:_.length===0,show:s(X,{condition:(u==null?void 0:u.length)>0,show:T(Un,{children:["No sign-on events found matching “",u,"”"]}),elseShow:s(Un,{children:"No sign-on events available."})})}),s(Rxe,{event:m,open:f,setOpen:h,onConfirm:g})]})},Lxe=()=>{const{hasAccess:e}=p.useContext(Gr);return s("div",{children:s(X,{condition:e(Fo),show:s(Oxe,{}),elseShow:s(WO,{})})})},Pp=[{path:"/splash/:splashId",title:"Unleash",component:Whe,type:"protected",menu:{},isStandalone:!0},{path:"/projects/create",parent:"/projects",title:"Create",component:bxe,type:"protected",enterprise:!0,menu:{}},{path:"/projects/:projectId/edit",parent:"/projects",title:":projectId",component:bpe,type:"protected",enterprise:!0,menu:{}},{path:"/projects/:projectId/archived",title:":projectId",parent:"/archive",component:Gue,type:"protected",menu:{}},{path:"/projects/:projectId/features/:featureId/:activeTab/copy",parent:"/projects/:projectId/features/:featureId/:activeTab",title:"Copy",component:Gfe,type:"protected",menu:{}},{path:"/projects/:projectId/features/:featureId/edit",parent:"/projects",title:"Edit feature",component:Xpe,type:"protected",menu:{}},{path:"/projects/:projectId/features/:featureId/*",parent:"/projects",title:"FeatureView",component:wxe,type:"protected",menu:{}},{path:"/projects/:projectId/create-toggle",parent:"/projects/:projectId/features",title:"Create feature toggle",component:$pe,type:"protected",menu:{}},{path:"/projects/:projectId/features2/:featureId",parent:"/features",title:":featureId",component:d_,type:"protected",menu:{}},{path:"/projects/:projectId/*",parent:"/projects",title:":projectId",component:xxe,flag:Ice,type:"protected",menu:{}},{path:"/projects",title:"Projects",component:Vue,type:"protected",menu:{mobile:!0}},{path:"/features/:activeTab/:featureId",parent:"/features",title:":featureId",component:d_,type:"protected",menu:{}},{path:"/features",title:"Feature toggles",component:Zie,type:"protected",menu:{mobile:!0}},{path:"/playground",title:"Playground",component:gSe,hidden:!1,type:"protected",menu:{mobile:!0}},{path:"/applications/:name",title:":name",parent:"/applications",component:nfe,type:"protected",menu:{}},{path:"/applications",title:"Applications",component:rfe,type:"protected",menu:{mobile:!0,advanced:!0}},{path:"/context/create",parent:"/context",title:"Create",component:Ghe,type:"protected",menu:{}},{path:"/context/edit/:name",parent:"/context",title:":name",component:epe,type:"protected",menu:{}},{path:"/context",title:"Context fields",component:ife,type:"protected",menu:{mobile:!0,advanced:!0}},{path:"/strategies/create",title:"Create",parent:"/strategies",component:The,type:"protected",menu:{}},{path:"/strategies/:name/edit",title:":name",parent:"/strategies",component:Ahe,type:"protected",menu:{}},{path:"/strategies/:name",title:":name",parent:"/strategies",component:Fse,type:"protected",menu:{}},{path:"/strategies",title:"Strategy types",component:ble,type:"protected",menu:{mobile:!0,advanced:!0}},{path:"/environments/create",title:"Environments",component:Lde,parent:"/environments",type:"protected",menu:{}},{path:"/environments/:id",title:"Edit",component:Dde,type:"protected",menu:{}},{path:"/environments",title:"Environments",component:Dbe,type:"protected",flag:$ce,menu:{mobile:!0,advanced:!0}},{path:"/tag-types/create",parent:"/tag-types",title:"Create",component:upe,type:"protected",menu:{}},{path:"/tag-types/edit/:name",parent:"/tag-types",title:":name",component:cpe,type:"protected",menu:{}},{path:"/tag-types",title:"Tag types",component:xle,type:"protected",menu:{mobile:!0,advanced:!0}},{path:"/addons/create/:providerId",parent:"/addons",title:"Create",component:jfe,type:"protected",menu:{}},{path:"/addons/edit/:addonId",parent:"/addons",title:"Edit",component:Ufe,type:"protected",menu:{}},{path:"/addons",title:"Addons",component:Ole,hidden:!1,type:"protected",menu:{mobile:!0,advanced:!0}},{path:"/segments/create",title:"Segments",component:F0e,hidden:!1,type:"protected",layout:"main",menu:{},flag:A1},{path:"/segments/edit/:segmentId",title:"Segments",component:U0e,hidden:!1,type:"protected",layout:"main",menu:{},flag:A1},{path:"/segments",title:"Segments",component:rSe,hidden:!1,type:"protected",menu:{mobile:!0,advanced:!0},flag:A1},{path:"/history",title:"Event log",component:lhe,type:"protected",menu:{adminSettings:!0}},{path:"/admin/signons",title:"Sign on log",component:Lxe,type:"protected",menu:{adminSettings:!0}},{path:"/archive",title:"Archived toggles",component:mSe,type:"protected",menu:{}},{path:"/admin",title:"Admin",component:Cxe,hidden:!1,type:"protected",menu:{}},{path:"/admin/*",title:"Admin",component:Sxe,hidden:!1,type:"protected",menu:{}},{path:"/profile/*",title:"Profile",component:yxe,type:"protected",menu:{}},{path:"/login",title:"Log in",component:Pce,type:"unprotected",hidden:!0,menu:{},isStandalone:!0},{path:"/new-user",title:"New user",hidden:!0,component:sue,type:"unprotected",menu:{},isStandalone:!0},{path:"/reset-password",title:"Reset password",hidden:!0,component:uue,type:"unprotected",menu:{},isStandalone:!0},{path:"/forgotten-password",title:"Forgotten password",hidden:!0,component:vue,type:"unprotected",menu:{},isStandalone:!0}],Nxe=[{path:"/history",title:"Event log",menu:{adminSettings:!0}},{path:"/admin/signons",title:"Sign-on log",menu:{adminSettings:!0},flag:"signOnLog"},{path:"/admin/users",title:"Users",menu:{adminSettings:!0}},{path:"/admin/groups",title:"Groups",menu:{adminSettings:!0},flag:Lce},{path:"/admin/roles",title:"Project roles",flag:Oce,menu:{adminSettings:!0}},{path:"/admin/auth",title:"Single sign-on",menu:{adminSettings:!0}},{path:"/admin/instance",title:"Instance stats",menu:{adminSettings:!0}},{path:"/admin/service-accounts",title:"Service accounts",menu:{adminSettings:!0,isEnterprise:!0}},{path:"/admin/network/*",title:"Network",menu:{adminSettings:!0},configFlag:"networkViewEnabled"},{path:"/admin/maintenance",title:"Maintenance",menu:{adminSettings:!0}},{path:"/admin/cors",title:"CORS origins",flag:"embedProxyFrontend",menu:{adminSettings:!0}},{path:"/admin/admin-invoices",title:"Billing & invoices",menu:{adminSettings:!0,isEnterprise:!0}}],Mxe=Pp.filter(e=>!e.hidden),Dxe=()=>{const e=Mxe.filter(o=>o.menu.advanced),t=Pp.filter(o=>o.menu.adminSettings),n=Pp.filter(o=>o.menu.mobile),r={mainNavRoutes:e,adminRoutes:t,mobileRoutes:n};return()=>r},OR=e=>e.map(t=>({path:t.path,flag:t.flag,title:t.title,menu:t.menu,configFlag:t.configFlag})),Bxe=Dxe(),Fxe=(e={})=>{const t=Dt("api/admin/notifications"),{data:n,error:r,mutate:o}=dn(t,zxe,e),a=p.useCallback(()=>{o().catch(console.warn)},[o]);return{notifications:n,error:r,loading:!r&&!n,refetchNotifications:a}},zxe=async e=>await(await fetch(e).then(yn("Notifications"))).json();var g2={},jxe=cn;Object.defineProperty(g2,"__esModule",{value:!0});var v2=g2.default=void 0,Uxe=jxe(Cn()),Wxe=En,Hxe=(0,Uxe.default)((0,Wxe.jsx)("path",{d:"M12 22c1.1 0 2-.9 2-2h-4c0 1.1.89 2 2 2zm6-6v-5c0-3.07-1.64-5.64-4.5-6.32V4c0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5v.68C7.63 5.36 6 7.92 6 11v5l-2 2v1h16v-1l-2-2z"}),"Notifications");v2=g2.default=Hxe;const Vxe=C(Me)(({theme:e})=>({padding:e.spacing(1,3),display:"flex",justifyContent:"space-between",alignItems:"center"})),Gxe=C(Me)(()=>({...Zp})),qxe=()=>s(ke,{children:T(Vxe,{children:[s(ye,{fontWeight:"bold",children:"Notifications"}),s(Gxe,{children:s(Yt,{children:s(Lx,{})})})]})}),Kxe=C(xa)(({theme:e})=>({padding:e.spacing(2,3)})),Yxe=({children:e})=>s(Kxe,{children:e}),Xxe=e=>p.createElement("svg",{width:18,height:14,viewBox:"0 0 18 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},p.createElement("path",{d:"M0.59 2.00016L2 0.590157L5.41 4.00016L4 5.41016L0.59 2.00016ZM13 11.5002L13 8.00016L7.41 8.00016L2 13.4102L0.59 12.0002L6.59 6.00016L13 6.00016L13 2.50016L17.5 7.00016L13 11.5002Z",fill:"currentColor"})),LR=C(Me,{shouldForwardProp:e=>e!=="readAt"})(({theme:e,readAt:t})=>({padding:e.spacing(.5),backgroundColor:t?e.palette.neutral.light:e.palette.secondary.light,width:"30px",height:"30px",display:"flex",justifyContent:"center",alignItems:"center",borderRadius:`${e.shape.borderRadius}px`,position:"absolute",top:3,left:7})),Jxe=C(ba)(({theme:e})=>({position:"relative",cursor:"pointer",margin:e.spacing(2,0),"&:not(:last-child)":{borderBottom:`2px solid ${e.palette.tertiary.contrast}`},width:"100%"})),Qxe=C(Me)(({theme:e})=>({marginLeft:e.spacing(4),display:"flex",flexDirection:"column",width:"100%"})),Zxe=C(Me)(({theme:e})=>({display:"flex",justifyContent:"flex-end",margin:e.spacing(1,0,1,0)})),eCe=C(ye,{shouldForwardProp:e=>e!=="readAt"})(({theme:e,readAt:t})=>({fontSize:e.fontSizes.smallBody,fontWeight:t?"normal":"bold",textDecoration:"none",color:"inherit"})),tCe=C(ye)(({theme:e})=>({fontSize:e.fontSizes.smallerBody,color:e.palette.neutral.main})),nCe=({notification:e,onNotificationClick:t})=>{const n=on(),{readAt:r}=e;return T(Jxe,{onClick:()=>t(e),children:[(a=>{if(a==="change-request")return s(LR,{readAt:Boolean(r),children:s(Xxe,{color:e.readAt?n.palette.neutral.main:n.palette.primary.main,style:{transform:"scale(0.8)"}})});if(a==="toggle")return s(LR,{readAt:Boolean(r),children:s(GZ,{sx:i=>({height:"20px",width:"20px",color:Boolean(r)?i.palette.neutral.main:i.palette.primary.main})})})})(e.notificationType)," ",T(Qxe,{children:[s(eCe,{readAt:Boolean(r),children:e.message}),s(Zxe,{children:s(tCe,{children:s(wv,{date:new Date(e.createdAt)})})})]})]})},rCe=C(Me)(()=>({display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"column",minHeight:"150px"})),oCe=C(v2)(({theme:e})=>({height:"30px",width:"30px",color:e.palette.neutral.main,marginBottom:e.spacing(1)})),aCe=()=>T(rCe,{children:[s(oCe,{}),s(ye,{color:"neutral.main",children:"No new notifications"})]}),iCe=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{loading:r,errors:n,markAsRead:async a=>{const l=t("api/admin/notifications/read",{method:"POST",body:JSON.stringify(a)});try{return(await e(l.caller,l.id)).json()}catch(c){throw c}}}},sCe=C(Me)(({theme:e})=>({display:"flex",gap:e.spacing(1),marginTop:e.spacing(.5)})),lCe=({id:e,localStorageKey:t,eventName:n})=>{var d;const{uiConfig:r}=Lt(),{value:o,setValue:a}=lu(`${r.baseUriPath}:${t}:v1:${e}`,{}),[i,l]=p.useState(o.value),{trackEvent:c}=ka();if(!((d=r==null?void 0:r.flags)!=null&&d.T)||Boolean(i))return null;const u=f=>{l(f),a({value:f}),c(n,{props:{eventType:e,wasHelpful:f==="yes"}})};return T(pr,{elevation:0,sx:{background:f=>f.palette.neutral.light,padding:f=>f.spacing(1.5,2),marginTop:f=>f.spacing(1.5)},children:["Was this information useful to you?",T(sCe,{children:[s(Ze,{size:"small",variant:i==="yes"?"contained":"outlined",sx:{padding:0},onClick:()=>u("yes"),disabled:Boolean(i),children:"Yes"}),s(Ze,{size:"small",variant:i==="no"?"contained":"outlined",sx:{padding:0},onClick:()=>u("no"),disabled:Boolean(i),children:"No"})]})]})},cCe=C(Me)(()=>({position:"relative"})),uCe=C(Me)(({theme:e})=>({backgroundColor:e.palette.neutral.light,padding:e.spacing(1,3),display:"flex",justifyContent:"center"})),dCe=C(ye)(({theme:e})=>({fontWeight:"bold",fontSize:e.fontSizes.smallBody,color:e.palette.primary.main,textAlign:"center"})),pCe=C(pr)(({theme:e})=>({minWidth:"400px",boxShadow:e.boxShadows.popup,borderRadius:`${e.shape.borderRadiusLarge}px`,position:"absolute",right:-20,top:60})),fCe=C(Me)(({theme:e})=>({backgroundColor:e.palette.primary.main,borderRadius:"100%",width:"7px",height:"7px",position:"absolute",top:7,right:4})),hCe=()=>{const[e,t]=p.useState(!1),{notifications:n,refetchNotifications:r}=Fxe({refreshInterval:15}),o=lt(),{markAsRead:a}=iCe(),{uiConfig:i}=Lt(),{trackEvent:l}=ka(),c=h=>{var m;h.link&&o(h.link),(m=i==null?void 0:i.flags)!=null&&m.T&&l("notifications",{props:{eventType:h.notificationType}}),t(!1);try{a({notifications:[h.id]})}catch(y){console.error("Error marking notification as read: ",y)}},u=()=>{try{n&&n.length>0&&(a({notifications:n.map(h=>h.id)}),r())}catch(h){console.error("Error marking all notification as read: ",h)}},d=n==null?void 0:n.filter(h=>h.readAt===null),f=Boolean(d&&d.length>0);return T(cCe,{children:[T(Yt,{onClick:()=>t(!e),children:[s(X,{condition:f,show:s(fCe,{})}),s(v2,{})]}),s(X,{condition:e,show:s(k$,{onClickAway:()=>t(!1),children:T(pCe,{children:[s(qxe,{}),s(X,{condition:f,show:s(uCe,{children:s(Ze,{onClick:u,children:T(dCe,{children:["Mark all as read (",d==null?void 0:d.length,")"]})})})})," ",s(X,{condition:(n==null?void 0:n.length)===0,show:s(aCe,{})}),s(Yxe,{children:n==null?void 0:n.map(h=>s(nCe,{notification:h,onNotificationClick:c},h.id))}),s(lCe,{eventName:"notifications",id:"useful",localStorageKey:"NotificationsUsefulPrompt"}),s("br",{})]})})})]})},NR=C(cW)(({theme:e})=>({backgroundColor:e.palette.headerBackground,padding:e.spacing(1),boxShadow:"none",position:"relative",zIndex:300})),MR=C(OV)(({theme:e})=>({display:"flex",alignItems:"center",maxWidth:1280,[e.breakpoints.down("md")]:{padding:"0"}})),DR=C("div")({marginLeft:"auto",display:"flex",alignItems:"center"}),mCe=C("nav")({display:"flex",alignItems:"center",flexGrow:1}),gCe=C(Zte)({width:"150px"}),vCe=C(Qte)({width:"150px"}),yCe=C("div")(({theme:e})=>({display:"flex",justifyContent:"center",marginLeft:e.spacing(3),"& a":{textDecoration:"none",color:"inherit",marginRight:e.spacing(3),display:"flex",alignItems:"center"}})),bCe=C("button")(({theme:e})=>({border:"none",background:"transparent",height:"100%",display:"flex",fontSize:e.fontSizes.bodySize,fontFamily:e.typography.fontFamily,alignItems:"center",color:"inherit",cursor:"pointer"})),BR=e=>({color:e.palette.neutral.main}),mh=C(ln)(({theme:e})=>hv(e)),wCe=C(Yt)(({theme:e})=>({...hv(e),borderRadius:100})),SCe=()=>{var _;const{onSetThemeMode:e,themeMode:t}=W4(),n=on(),r=Ss(),o=Ss(),[a,i]=p.useState(null),[l,c]=p.useState(null),[u,d]=p.useState(!1),{permissions:f}=bC(),{uiConfig:h,isOss:m}=Lt(),y=cr(n.breakpoints.down("md")),[g,v]=p.useState(!1),b=()=>v($=>!$),w=()=>i(null),x=()=>c(null);p.useEffect(()=>{(f==null?void 0:f.find(L=>L.permission===Fo))&&d(!0)},[f]);const E=Bxe(),A=$=>!$.menu.isEnterprise||!m(),k={mainNavRoutes:OR(E.mainNavRoutes).concat([{path:"/admin/api",title:"API access",menu:{}}]).filter(I1(h)),mobileRoutes:OR(E.mobileRoutes).filter(I1(h)),adminRoutes:Nxe.filter(I1(h)).filter(A).map($=>({...$,path:$.path.replace("/*","")}))};return y?s(NR,{position:"static",children:T(MR,{children:[s(_t,{title:"Menu",arrow:!0,children:s(Yt,{sx:{color:$=>$.palette.text.primary},onClick:b,"aria-controls":"header-drawer","aria-expanded":g,size:"large",children:s(o3,{})})}),s(_ne,{title:h.name,flags:h.flags,links:h.links,open:g,toggleDrawer:b,admin:u,routes:k}),s(DR,{children:s(bA,{})})]})}):s(NR,{position:"static",children:T(MR,{children:[s(mh,{to:"/",sx:Zp,"aria-label":"Home",children:s(lw,{darkmode:s(gCe,{"aria-label":"Unleash logo"}),lightmode:s(vCe,{"aria-label":"Unleash logo"})})}),T(mCe,{children:[T(yCe,{children:[s(mh,{to:"/projects",children:"Projects"}),s(mh,{to:"/features",children:"Feature toggles"}),s(mh,{to:"/playground",children:"Playground"}),T(bCe,{onClick:$=>c($.currentTarget),"aria-controls":l?o:void 0,"aria-expanded":Boolean(l),children:["Configure",s(Lb,{sx:BR})]}),s(EA,{id:o,options:k.mainNavRoutes,anchorEl:l,handleClose:x,style:{top:10}})]}),T(DR,{children:[s(X,{condition:Boolean(h.flags.ENABLE_DARK_MODE_SUPPORT),show:s(Tr,{control:s(Ii,{onChange:e,checked:t==="dark"}),label:"darkmode"})}),s(X,{condition:Boolean((_=h==null?void 0:h.flags)==null?void 0:_.notifications),show:s(hCe,{})}),s(_t,{title:"Documentation",arrow:!0,children:s(Yt,{href:"https://docs.getunleash.io/",target:"_blank",rel:"noopener noreferrer",size:"large",disableRipple:!0,sx:hv,children:s(Fx,{})})}),s(X,{condition:u,show:s(_t,{title:"Settings",arrow:!0,children:T(wCe,{onClick:$=>i($.currentTarget),"aria-controls":a?r:void 0,"aria-expanded":Boolean(a),size:"large",disableRipple:!0,children:[s(Lx,{}),s(Lb,{sx:BR})]})})}),s(EA,{id:r,options:k.adminRoutes,anchorEl:a,handleClose:w,style:{top:5,left:-100}})," ",s(bA,{})]})]})]})})},xCe=e=>{var n;const t=(n=e.versionInfo)==null?void 0:n.current;return t!=null&&t.enterprise?`${e.name} ${t.enterprise}`:t!=null&&t.oss?`${e.name} ${t.oss}`:`${e.name} ${e.version}`},CCe=e=>{var r,o;const t=(r=e.versionInfo)==null?void 0:r.latest,n=(o=e.versionInfo)==null?void 0:o.isLatest;if(t!=null&&t.enterprise&&!n)return`Upgrade available - Latest Enterprise release: ${t.enterprise}`;if(t!=null&&t.oss&&!n)return`Upgrade available - Latest OSS release: ${t.oss}`},Uh=C("h2")(({theme:e})=>({all:"unset",display:"block",margin:e.spacing(2,0),fontSize:e.fontSizes.bodySize,fontWeight:e.fontWeight.bold})),ECe=e=>{var a;const t=(a=e.uiConfig.versionInfo)==null?void 0:a.instanceId,n=xCe(e.uiConfig),r=e.uiConfig.environment,o=CCe(e.uiConfig);return T("section",{title:"API details",children:[T(Uh,{children:[n," ",s(X,{condition:Boolean(r),show:T("small",{children:["(",r,")"]})})]}),s(X,{condition:Boolean(o),show:T("small",{children:[o,s("br",{})]})}),s("br",{}),s("small",{children:e.uiConfig.slogan}),s("br",{}),s(X,{condition:Boolean(t),show:s("small",{children:`${t}`})})]})},TCe=C("footer")(({theme:e})=>({padding:e.spacing(4,8),width:"100%",flexGrow:1,zIndex:100,backgroundColor:e.palette.footerBackground})),t0=C(xa)({padding:0,margin:0}),Cr=C(ba)(({theme:e})=>({padding:0,margin:0,"& a":{textDecoration:"none",color:e.palette.text.primary}})),kCe=()=>{const{uiConfig:e}=Lt();return s(TCe,{children:T(In,{container:!0,justifyContent:"center",spacing:10,style:{marginBottom:0},children:[s(In,{item:!0,md:4,xs:12,children:s(ECe,{uiConfig:e})}),s(In,{item:!0,xs:12,md:"auto",children:T(In,{container:!0,spacing:7,direction:"row",children:[s(In,{item:!0,children:T("section",{title:"Unleash SDK",children:[s(Uh,{children:"Server SDKs"}),T(t0,{dense:!0,children:[s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/node",target:"_blank",children:"Node.js"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/java",target:"_blank",children:"Java"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/go",target:"_blank",children:"Go"})})})," ",s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/ruby",target:"_blank",children:"Ruby"})})})," ",s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/python",target:"_blank",children:"Python"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/dotnet",target:"_blank",children:".NET"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/php",target:"_blank",children:"PHP"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks",target:"_blank",children:"All SDKs"})})})]})]})}),s(In,{item:!0,children:T("section",{title:"Unleash SDK",children:[s(Uh,{children:"Frontend SDKs"}),T(t0,{dense:!0,children:[s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/unleash-proxy",target:"_blank",children:"Unleash Proxy"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/javascript-browser",target:"_blank",children:"JavaScript SDK"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/react",target:"_blank",children:"React SDK"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/ios-proxy",target:"_blank",children:"iOS SDK"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://docs.getunleash.io/reference/sdks/android-proxy",target:"_blank",children:"Android SDK"})})})]})]})}),s(In,{item:!0,children:T("section",{children:[s(Uh,{children:"About"}),T(t0,{dense:!0,children:[s(Cr,{children:s(fn,{primary:s("a",{href:"https://www.getunleash.io/",target:"_blank",children:"getunleash.io"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://twitter.com/getunleash",target:"_blank",children:"Twitter"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://www.linkedin.com/company/getunleash",target:"_blank",children:"LinkedIn"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://github.com/Unleash/unleash",target:"_blank",children:"GitHub"})})}),s(Cr,{children:s(fn,{primary:s("a",{href:"https://slack.unleash.run",target:"_blank",children:"Slack Community"})})})]})]})})]})})]})})},ACe=C(Zt)(({theme:e})=>({marginBottom:e.spacing(2)})),_Ce=C(ye)(({theme:e})=>({maxWidth:"800px"})),RCe=C("a")(({theme:e})=>({display:"block",marginTop:e.spacing(1),width:"100px"})),PCe=e=>!(!e||localStorage&&localStorage.getItem(e)),ICe=({toast:e})=>{const[t,n]=p.useState(!1);p.useEffect(()=>{n(PCe((e==null?void 0:e.id)||""))},[e==null?void 0:e.id]);const r=()=>{localStorage&&localStorage.setItem((e==null?void 0:e.id)||"","seen"),n(!1)};return e?s(X,{condition:t,show:T(ACe,{severity:e.severity,onClose:r,children:[s(_Ce,{variant:"body2",children:e.message}),s(RCe,{href:e.link,target:"_blank",rel:"noopener noreferrer",children:"View more"})]})}):null},$Ce=C("div")(({theme:e})=>({height:e.spacing(2.5),margin:e.spacing(2,0)})),OCe=C(MH)({"& > ol":{flexWrap:"nowrap","& > li:last-child":{minWidth:0}}}),FR=C("p")(ite),LCe=C(ln)(({theme:e})=>({"& > *":{maxWidth:e.spacing(25)}})),NCe=()=>{const{isAdmin:e}=p.useContext(Gr),t=ia(),n=t.pathname.split("/").filter(r=>r).filter(r=>r!=="create"&&r!=="edit"&&r!=="view"&&r!=="variants"&&r!=="logs"&&r!=="metrics"&&r!=="copy"&&r!=="features"&&r!=="features2"&&r!=="create-toggle"&&r!=="settings"&&r!=="profile");return s($Ce,{children:s(X,{condition:t.pathname.includes("admin")&&e||!t.pathname.includes("admin"),show:s(X,{condition:n.length>1,show:s(OCe,{"aria-label":"Breadcrumbs",children:n.map((r,o)=>{if(o===n.length-1)return s(FR,{children:r},r);let i="/";return n.forEach((l,c)=>{c!==o&&c<o?i+=l+"/":c===o&&(i+=l)}),s(LCe,{to:i,children:s(FR,{children:r})},r)})})})})})},MCe="/static/texture-c29e66c0.png",QL="skip-nav-target-id",DCe=()=>s("div",{id:QL}),BCe=C("a")(({theme:e})=>({position:"fixed",overflow:"hidden",zIndex:1e3,top:e.spacing(2.25),left:e.spacing(2.25),padding:e.spacing(1,2),whiteSpace:"nowrap",textDecoration:"none",background:e.palette.primary.dark,color:e.palette.primary.contrastText,borderRadius:e.shape.borderRadius,fontSize:e.fontSizes.smallBody,[e.breakpoints.down(960)]:{top:"0.8rem",left:"0.8rem"},"&:not(:focus):not(:active)":{clip:"rect(0 0 0 0)",clipPath:"inset(50%)",zIndex:-1,width:1,height:1,margin:-1,padding:0}})),FCe=()=>T(BCe,{href:`#${QL}`,children:["Skip to content ",s("span",{"aria-hidden":!0,children:"↓"})]}),zCe=({featureName:e,projectId:t,conflict:n,onNavigate:r,children:o})=>T(G$,{elevation:0,sx:a=>({marginTop:a.spacing(2),overflow:"hidden"}),children:[T(Me,{sx:a=>({backgroundColor:(Boolean(n),a.palette.neutral.light),borderRadius:i=>`${i.shape.borderRadiusLarge}px ${i.shape.borderRadiusLarge}px 0 0`,border:"1px solid",borderColor:i=>n?i.palette.warning.border:i.palette.tertiary.main,borderBottom:"none",overflow:"hidden"}),children:[s(X,{condition:Boolean(n),show:T(Zt,{severity:"warning",sx:{px:3,mb:2,"&.MuiAlert-standardWarning":{borderStyle:"none"}},children:[s("strong",{children:"Conflict!"})," ",n,"."]})}),T(Me,{sx:{display:"flex",pt:n?0:2,pb:2,px:3},children:[s(ye,{children:"Feature toggle name: "}),s(go,{component:ln,to:`/projects/${t}/features/${e}`,color:"primary",underline:"hover",sx:{marginLeft:1,"& :hover":{textDecoration:"underline"}},onClick:r,children:s("strong",{children:e})})]})]}),s(Me,{children:o})]}),jCe=e=>typeof e=="object"&&e!==null&&"name"in e;var UCe=200,y2="__lodash_hash_undefined__",WCe=1/0,ZL=9007199254740991,HCe="[object Arguments]",VCe="[object Function]",GCe="[object GeneratorFunction]",qCe="[object Symbol]",KCe=/[\\^$.*+?()[\]{}|]/g,YCe=/^\[object .+?Constructor\]$/,XCe=/^(?:0|[1-9]\d*)$/,JCe=typeof Fa=="object"&&Fa&&Fa.Object===Object&&Fa,QCe=typeof self=="object"&&self&&self.Object===Object&&self,b2=JCe||QCe||Function("return this")();function ZCe(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function e2e(e,t){var n=e?e.length:0;return!!n&&r2e(e,t,0)>-1}function t2e(e,t,n){for(var r=-1,o=e?e.length:0;++r<o;)if(n(t,e[r]))return!0;return!1}function eN(e,t){for(var n=-1,r=e?e.length:0,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}function w2(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}function n2e(e,t,n,r){for(var o=e.length,a=n+(r?1:-1);r?a--:++a<o;)if(t(e[a],a,e))return a;return-1}function r2e(e,t,n){if(t!==t)return n2e(e,o2e,n);for(var r=n-1,o=e.length;++r<o;)if(e[r]===t)return r;return-1}function o2e(e){return e!==e}function a2e(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function i2e(e){return function(t){return e(t)}}function s2e(e,t){return e.has(t)}function l2e(e,t){return e==null?void 0:e[t]}function c2e(e){var t=!1;if(e!=null&&typeof e.toString!="function")try{t=!!(e+"")}catch{}return t}function tN(e,t){return function(n){return e(t(n))}}var u2e=Array.prototype,d2e=Function.prototype,Yv=Object.prototype,n0=b2["__core-js_shared__"],zR=function(){var e=/[^.]+$/.exec(n0&&n0.keys&&n0.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),nN=d2e.toString,bu=Yv.hasOwnProperty,S2=Yv.toString,p2e=RegExp("^"+nN.call(bu).replace(KCe,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),jR=b2.Symbol,f2e=tN(Object.getPrototypeOf,Object),h2e=Yv.propertyIsEnumerable,m2e=u2e.splice,UR=jR?jR.isConcatSpreadable:void 0,pw=Object.getOwnPropertySymbols,WR=Math.max,g2e=oN(b2,"Map"),Ip=oN(Object,"create");function xl(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function v2e(){this.__data__=Ip?Ip(null):{}}function y2e(e){return this.has(e)&&delete this.__data__[e]}function b2e(e){var t=this.__data__;if(Ip){var n=t[e];return n===y2?void 0:n}return bu.call(t,e)?t[e]:void 0}function w2e(e){var t=this.__data__;return Ip?t[e]!==void 0:bu.call(t,e)}function S2e(e,t){var n=this.__data__;return n[e]=Ip&&t===void 0?y2:t,this}xl.prototype.clear=v2e;xl.prototype.delete=y2e;xl.prototype.get=b2e;xl.prototype.has=w2e;xl.prototype.set=S2e;function wu(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function x2e(){this.__data__=[]}function C2e(e){var t=this.__data__,n=Xv(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():m2e.call(t,n,1),!0}function E2e(e){var t=this.__data__,n=Xv(t,e);return n<0?void 0:t[n][1]}function T2e(e){return Xv(this.__data__,e)>-1}function k2e(e,t){var n=this.__data__,r=Xv(n,e);return r<0?n.push([e,t]):n[r][1]=t,this}wu.prototype.clear=x2e;wu.prototype.delete=C2e;wu.prototype.get=E2e;wu.prototype.has=T2e;wu.prototype.set=k2e;function Su(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function A2e(){this.__data__={hash:new xl,map:new(g2e||wu),string:new xl}}function _2e(e){return Jv(this,e).delete(e)}function R2e(e){return Jv(this,e).get(e)}function P2e(e){return Jv(this,e).has(e)}function I2e(e,t){return Jv(this,e).set(e,t),this}Su.prototype.clear=A2e;Su.prototype.delete=_2e;Su.prototype.get=R2e;Su.prototype.has=P2e;Su.prototype.set=I2e;function Km(e){var t=-1,n=e?e.length:0;for(this.__data__=new Su;++t<n;)this.add(e[t])}function $2e(e){return this.__data__.set(e,y2),this}function O2e(e){return this.__data__.has(e)}Km.prototype.add=Km.prototype.push=$2e;Km.prototype.has=O2e;function L2e(e,t){var n=x2(e)||aN(e)?a2e(e.length,String):[],r=n.length,o=!!r;for(var a in e)(t||bu.call(e,a))&&!(o&&(a=="length"||G2e(a,r)))&&n.push(a);return n}function Xv(e,t){for(var n=e.length;n--;)if(Z2e(e[n][0],t))return n;return-1}function N2e(e,t,n,r){var o=-1,a=e2e,i=!0,l=e.length,c=[],u=t.length;if(!l)return c;n&&(t=eN(t,i2e(n))),r?(a=t2e,i=!1):t.length>=UCe&&(a=s2e,i=!1,t=new Km(t));e:for(;++o<l;){var d=e[o],f=n?n(d):d;if(d=r||d!==0?d:0,i&&f===f){for(var h=u;h--;)if(t[h]===f)continue e;c.push(d)}else a(t,f,r)||c.push(d)}return c}function rN(e,t,n,r,o){var a=-1,i=e.length;for(n||(n=V2e),o||(o=[]);++a<i;){var l=e[a];t>0&&n(l)?t>1?rN(l,t-1,n,r,o):w2(o,l):r||(o[o.length]=l)}return o}function M2e(e,t,n){var r=t(e);return x2(e)?r:w2(r,n(e))}function D2e(e){if(!C2(e)||K2e(e))return!1;var t=sN(e)||c2e(e)?p2e:YCe;return t.test(Q2e(e))}function B2e(e){if(!C2(e))return X2e(e);var t=Y2e(e),n=[];for(var r in e)r=="constructor"&&(t||!bu.call(e,r))||n.push(r);return n}function F2e(e,t){return e=Object(e),z2e(e,t,function(n,r){return r in e})}function z2e(e,t,n){for(var r=-1,o=t.length,a={};++r<o;){var i=t[r],l=e[i];n(l,i)&&(a[i]=l)}return a}function j2e(e,t){return t=WR(t===void 0?e.length-1:t,0),function(){for(var n=arguments,r=-1,o=WR(n.length-t,0),a=Array(o);++r<o;)a[r]=n[t+r];r=-1;for(var i=Array(t+1);++r<t;)i[r]=n[r];return i[t]=a,ZCe(e,this,i)}}function U2e(e){return M2e(e,rEe,H2e)}function Jv(e,t){var n=e.__data__;return q2e(t)?n[typeof t=="string"?"string":"hash"]:n.map}function oN(e,t){var n=l2e(e,t);return D2e(n)?n:void 0}var W2e=pw?tN(pw,Object):cN,H2e=pw?function(e){for(var t=[];e;)w2(t,W2e(e)),e=f2e(e);return t}:cN;function V2e(e){return x2(e)||aN(e)||!!(UR&&e&&e[UR])}function G2e(e,t){return t=t??ZL,!!t&&(typeof e=="number"||XCe.test(e))&&e>-1&&e%1==0&&e<t}function q2e(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function K2e(e){return!!zR&&zR in e}function Y2e(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||Yv;return e===n}function X2e(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}function J2e(e){if(typeof e=="string"||nEe(e))return e;var t=e+"";return t=="0"&&1/e==-WCe?"-0":t}function Q2e(e){if(e!=null){try{return nN.call(e)}catch{}try{return e+""}catch{}}return""}function Z2e(e,t){return e===t||e!==e&&t!==t}function aN(e){return eEe(e)&&bu.call(e,"callee")&&(!h2e.call(e,"callee")||S2.call(e)==HCe)}var x2=Array.isArray;function iN(e){return e!=null&&tEe(e.length)&&!sN(e)}function eEe(e){return lN(e)&&iN(e)}function sN(e){var t=C2(e)?S2.call(e):"";return t==VCe||t==GCe}function tEe(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=ZL}function C2(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function lN(e){return!!e&&typeof e=="object"}function nEe(e){return typeof e=="symbol"||lN(e)&&S2.call(e)==qCe}function rEe(e){return iN(e)?L2e(e,!0):B2e(e)}var oEe=j2e(function(e,t){return e==null?{}:(t=eN(rN(t,1),J2e),F2e(e,N2e(U2e(e),t)))});function cN(){return[]}var aEe=oEe;const iEe=(e,t,n,r)=>{var i,l;return(l=(i=bl(t,n).feature)==null?void 0:i.environments.find(c=>c.name===r))==null?void 0:l.strategies.find(c=>"id"in e.payload&&c.id===e.payload.id)},r0=({change:e,project:t,feature:n,environmentName:r})=>{const o=iEe(e,t,n,r),a=e.action==="deleteStrategy"?void 0:e.payload;return s(HO,{children:s(Nv,{entry:{preData:aEe(o,"sortOrder"),data:a}})})},o0=({change:e,children:t})=>{const[n,r]=jt.useState(null),o=l=>{r(l.currentTarget)},a=()=>{r(null)},i=Boolean(n);return T(ke,{children:[s(lle,{strategyName:e.payload.name}),s(ye,{onMouseEnter:o,onMouseLeave:a,children:Ep(e.payload.name)}),s(dx,{id:String(e.id),sx:{pointerEvents:"none"},open:i,anchorEl:n,anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"},onClose:a,disableRestoreFocus:!0,children:t})]})},HR=({percentage:e,size:t="4rem"})=>{const n=on(),r={display:"block",borderRadius:"100%",transform:"rotate(-90deg)",height:t,width:t,background:n.palette.grey[200]},o=100/(2*Math.PI),a=2*o;return s("svg",{viewBox:`0 0 ${a} ${a}`,style:r,"aria-hidden":!0,children:s("circle",{r:o,cx:o,cy:o,fill:"none",stroke:n.palette.primary.light,strokeWidth:a,strokeDasharray:`${e} 100`})})},sEe=C("div")(({theme:e})=>({width:"100%",padding:e.spacing(2,3),borderRadius:e.shape.borderRadiusMedium,border:`1px solid ${e.palette.divider}`})),lEe=C("p")(({theme:e})=>({display:"inline",margin:e.spacing(.5,0),maxWidth:"95%",textAlign:"center",wordBreak:"break-word"})),cEe=C(To)(({theme:e})=>({margin:e.spacing(.5)})),a0=({value:e,text:t})=>s(sEe,{children:s(X,{condition:e.length===0,show:T("p",{children:["No ",t,"s added yet."]}),elseShow:T("div",{children:[T(lEe,{children:[e.length," ",e.length>1?`${t}s`:t," will get access."]}),e.map(n=>s(cEe,{label:s(Da,{maxWidth:"300",text:n,maxLength:50})},n))]})})}),uEe=({segments:e})=>!e||e.length===0?null:s(ke,{children:e.map((t,n)=>T(p.Fragment,{children:[s(X,{condition:n>0,show:s(s2,{text:"AND"})}),s(WL,{segment:t})]},t.id))}),VR=()=>s(Me,{sx:{px:3,color:"text.disabled"},children:"This strategy does not have constraints or parameters."}),zs=C(Me)(({theme:e})=>({padding:e.spacing(2,3),border:`1px solid ${e.palette.dividerAlternative}`,borderRadius:e.shape.borderRadiusMedium})),i0=C("span")(({theme:e})=>({color:e.palette.neutral.main})),GR=({strategy:e})=>{const{parameters:t,constraints:n=[]}=e,{strategies:r}=pu(),{uiConfig:o}=Lt(),{segments:a}=$l(),i=a==null?void 0:a.filter(f=>{var h;return(h=e.segments)==null?void 0:h.includes(f.id)}),l=r.find(f=>f.name===e.name),c=p.useMemo(()=>!t||l!=null&&l.editable?null:Object.keys(t).map(f=>{switch(f){case"rollout":case"Rollout":const h=jd(t[f]);return T(zs,{sx:{display:"flex",alignItems:"center"},children:[s(Me,{sx:{mr:2},children:s(HR,{percentage:h,size:"2rem"})}),T("div",{children:[s(To,{color:"success",variant:"outlined",size:"small",label:`${h}%`})," ","of your base"," ",n.length>0?"who match constraints":""," ","is included."]})]});case"userIds":case"UserIds":const m=Qi(t[f]);return s(a0,{value:m,text:"user"},f);case"hostNames":case"HostNames":const y=Qi(t[f]);return s(a0,{value:y,text:"host"},f);case"IPs":const g=Qi(t[f]);return s(a0,{value:g,text:"IP"},f);case"stickiness":case"groupId":return null;default:return null}}),[t,l,n]),u=p.useMemo(()=>{if(!t||!(l!=null&&l.editable))return null;const f=s(i0,{children:" is set to "});return l==null?void 0:l.parameters.map(h=>{const{type:m,name:y}={...h};if(!m||!y||t[y]===void 0)return null;const g=s(Da,{maxLength:15,maxWidth:"150",text:y});switch(h==null?void 0:h.type){case"list":const v=Qi(t[y]);return v.length>0?T(zs,{children:[g," ",T(i0,{children:["has ",v.length," ",v.length>1?"items":"item",":"," ",v.map(E=>s(To,{label:s(Da,{maxWidth:"300",text:E,maxLength:50}),sx:{mr:.5}},E))]})]}):null;case"percentage":const b=jd(t[y]);return t[y]!==""?T(zs,{sx:{display:"flex",alignItems:"center"},children:[s(Me,{sx:{mr:2},children:s(HR,{percentage:b,size:"2rem"})}),T("div",{children:[g,f,s(To,{color:"success",variant:"outlined",size:"small",label:`${b}%`})]})]}):null;case"boolean":return t[y]==="true"||t[y]==="false"?T(zs,{children:[s(Da,{maxLength:15,maxWidth:"150",text:y}),f,s(To,{color:t[y]==="true"?"success":"error",variant:"outlined",size:"small",label:t[y]})]}):null;case"string":const w=ls(t[y]);return typeof t[y]<"u"?T(zs,{children:[g,s(X,{condition:w==="",show:s(i0,{children:" is an empty string"}),elseShow:T(ke,{children:[f,s(Da,{maxWidth:"300",text:w,maxLength:50})]})})]}):null;case"number":const x=jd(t[y]);return t[y]!==""&&x!==void 0?T(zs,{children:[g,f,s(Da,{maxWidth:"300",text:String(x),maxLength:50})]}):null;case"default":return null}return null})},[t,l]);if(!t)return s(VR,{});const d=[Boolean(o.flags.SE)&&i&&i.length>0&&s(uEe,{segments:i}),n.length>0&&s(qv,{constraints:n,showLabel:!1}),e.name==="default"&&s(ke,{children:T(zs,{sx:{width:"100%"},children:["The standard strategy is"," ",s(To,{variant:"outlined",size:"small",color:"success",label:"ON"})," ","for all users."]})}),...c??[],...u??[]].filter(Boolean);return s(X,{condition:d.length>0,show:s(ke,{children:d.map((f,h)=>T(p.Fragment,{children:[s(X,{condition:h>0,show:s(s2,{text:"AND"})}),f]},h))}),elseShow:s(VR,{})})},uN=C(Me)({display:"flex",justifyContent:"space-between",alignItems:"center"}),dN=C(Me)(({theme:e})=>({display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:e.spacing(2)})),E2=C(Me)(({theme:e})=>({display:"flex",alignItems:"center",gap:e.spacing(1)})),dEe=({children:e,discard:t})=>T(dN,{children:[T(E2,{children:[s(ye,{sx:n=>({color:n.palette.success.dark}),children:"+ Adding strategy:"}),e]}),t]}),pEe=({children:e,discard:t})=>T(dN,{children:[T(E2,{children:[s(ye,{children:"Editing strategy:"}),e]}),t]}),fEe=({discard:e,children:t})=>T(uN,{children:[T(E2,{children:[s(ye,{sx:n=>({color:n.palette.error.main}),children:"- Deleting strategy"}),t]}),e]}),hEe=({enabled:e,discard:t})=>T(uN,{children:[T(Me,{sx:{display:"flex",alignItems:"center"},children:["New status:"," ",s(Io,{sx:n=>({marginLeft:n.spacing(1)}),color:e?"success":"error",children:e?" Enabled":"Disabled"})]}),t]}),mEe=C("div")(({theme:e})=>({overflowX:"auto","& code":{wordWrap:"break-word",whiteSpace:"pre-wrap",fontFamily:"monospace",lineHeight:1.5,fontSize:e.fontSizes.smallBody}})),gEe=({preData:e,data:t})=>s(mEe,{children:s(Nv,{entry:{preData:e,data:t}})}),vEe=C(Me)(({theme:e})=>({display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:e.spacing(2)})),yEe=C(Me)(({theme:e})=>({display:"flex",flexDirection:"column",gap:e.spacing(1)})),bEe=({feature:e,project:t,environment:n,change:r,discard:o})=>{var l;const{feature:a}=bl(t,e),i=(l=a.environments.find(({name:c})=>n===c))==null?void 0:l.variants;return T(vEe,{children:[T(yEe,{children:[s(ye,{children:"Updating variants:"}),s(gEe,{preData:i,data:r.payload.variants})]}),o]})},wEe=C(Me,{shouldForwardProp:e=>!e.startsWith("$")})(({theme:e,$hasConflict:t,$isInConflictFeature:n,$isAfterWarning:r,$isLast:o})=>({borderLeft:"1px solid",borderRight:"1px solid",borderTop:"1px solid",borderBottom:o?"1px solid":"none",borderRadius:o?`0 0
|
|
362
|
+
${e.shape.borderRadiusLarge}px ${e.shape.borderRadiusLarge}px`:0,borderColor:t||n?e.palette.warning.border:e.palette.dividerAlternative,borderTopColor:(t||r)&&!n?e.palette.warning.border:e.palette.dividerAlternative})),SEe=C(Zt)(({theme:e})=>({borderRadius:0,padding:e.spacing(0,2),"&.MuiAlert-standardWarning":{borderStyle:"none none solid none"}})),xEe=({index:e,change:t,feature:n,changeRequest:r,discard:o})=>{var a;return T(wEe,{$hasConflict:Boolean(t.conflict),$isInConflictFeature:Boolean(n.conflict),$isAfterWarning:Boolean((a=n.changes[e-1])==null?void 0:a.conflict),$isLast:e+1===n.changes.length,children:[s(X,{condition:Boolean(t.conflict)&&!n.conflict,show:T(SEe,{severity:"warning",children:[s("strong",{children:"Conflict!"})," This change can’t be applied."," ",t.conflict,"."]})}),T(Me,{sx:i=>({padding:i.spacing(3)}),children:[t.action==="updateEnabled"&&s(hEe,{enabled:t.payload.enabled,discard:o}),t.action==="addStrategy"&&T(ke,{children:[s(dEe,{discard:o,children:s(o0,{change:t,children:s(r0,{change:t,feature:n.name,environmentName:r.environment,project:r.project})})}),s(GR,{strategy:t.payload})]}),t.action==="deleteStrategy"&&s(fEe,{discard:o,children:jCe(t.payload)&&s(o0,{change:t,children:s(r0,{change:t,feature:n.name,environmentName:r.environment,project:r.project})})}),t.action==="updateStrategy"&&T(ke,{children:[s(pEe,{discard:o,children:s(o0,{change:t,children:s(r0,{change:t,feature:n.name,environmentName:r.environment,project:r.project})})}),s(GR,{strategy:t.payload})]}),t.action==="patchVariant"&&s(bEe,{feature:n.name,project:r.project,environment:r.environment,change:t,discard:o})]})]},_L(t))},T2=e=>e.features.flatMap(t=>t.changes).length,CEe=e=>{const{isChangeRequestConfigured:t}=of(e.project),n=t(e.environment),r=!["Cancelled","Applied"].includes(e.state),{user:o}=ca(),a=(o==null?void 0:o.id)===e.createdBy.id;return n&&r&&a&&T2(e)>1},EEe=C(go)(()=>({textDecoration:"none","&:hover, &:focus":{textDecoration:"underline"}})),TEe=({onDiscard:e})=>s(Me,{children:s(EEe,{onClick:e,children:"Discard"})}),kEe=({changeRequest:e,changeId:t,onPostDiscard:n})=>{const r=CEe(e),{discardChange:o}=d2(),{setToastData:a,setToastApiError:i}=It();return s(X,{condition:r,show:s(TEe,{onDiscard:(c=>async()=>{try{await o(e.project,e.id,c),a({title:"Change discarded from change request draft.",type:"success"}),n==null||n()}catch(u){i(ft(u))}})(t)})})},AEe=({changeRequest:e,onRefetch:t,onNavigate:n})=>{var r;return s(Me,{children:(r=e.features)==null?void 0:r.map(o=>s(zCe,{featureName:o.name,projectId:e.project,onNavigate:n,conflict:o.conflict,children:o.changes.map((a,i)=>s(xEe,{discard:s(kEe,{changeRequest:e,changeId:a.id,onPostDiscard:t}),index:i,changeRequest:e,change:a,feature:o},i))},o.name))})},qR=()=>s(Io,{color:"secondary",icon:s(_Z,{fontSize:"small"}),children:"Review required"}),_Ee=()=>s(Io,{color:"warning",children:"Draft"}),REe=({state:e})=>{switch(e){case"Draft":return s(_Ee,{});case"In review":return s(qR,{});case"Approved":return s(Io,{color:"success",icon:s(Am,{fontSize:"small"}),children:"Approved"});case"Applied":return s(Io,{color:"success",icon:s(Am,{fontSize:"small"}),children:"Applied"});case"Cancelled":return s(Io,{color:"error",icon:s(uv,{fontSize:"small"}),children:"Cancelled"});default:return s(qR,{})}},PEe=({onClick:e,count:t})=>T(Ze,{sx:{ml:"auto"},variant:"contained",onClick:e,children:["Submit change request (",t,")"]}),IEe=({environmentChangeRequest:e,onClose:t,onReview:n,onDiscard:r,children:o})=>{const a=on(),i=lt();return T(Me,{sx:{padding:3,border:"2px solid",mb:5,borderColor:l=>l.palette.secondaryContainer,borderRadius:l=>`${l.shape.borderRadiusLarge}px`},children:[T(Me,{sx:{display:"flex",alignItems:"end"},children:[T(Me,{sx:{display:"flex",alignItems:"center"},children:[s(I4,{sx:l=>({color:l.palette.primary.light,mr:.5})}),s(ye,{component:"span",variant:"h2",children:e.environment}),s(BEe,{}),s(FEe,{count:e.features.length})]}),s(Me,{sx:{ml:"auto"},children:s(REe,{state:e.state})})]}),s(mo,{sx:{my:3}}),s(ye,{variant:"body2",color:"text.secondary",children:"You request changes for these feature toggles:"}),o,T(Me,{sx:{display:"flex",mt:3},children:[s(X,{condition:(e==null?void 0:e.state)==="Draft",show:T(ke,{children:[s(PEe,{onClick:()=>n(e.id),count:T2(e)}),s(Ze,{sx:{ml:2},variant:"outlined",onClick:()=>r(e.id),children:"Discard changes"})]})}),s(X,{condition:e.state==="In review"||e.state==="Approved",show:s(ke,{children:T(DEe,{children:[s(MEe,{}),s(ye,{color:a.palette.success.dark,children:"Draft successfully sent to review"}),s(Ze,{sx:{marginLeft:2},variant:"outlined",onClick:()=>{t(),i(`/projects/${e.project}/change-requests/${e.id}`)},children:"View change request page"})]})})})]})]},e.id)},$Ee=C(wx)(({theme:e})=>({fontSize:e.fontSizes.mainHeader,marginLeft:"0.3rem",color:e.palette.grey[700]})),OEe=C("div")(({theme:e})=>({color:e.palette.text.secondary,fontSize:e.fontSizes.smallBody})),LEe=()=>s(xn,{actions:"",titleElement:T(ke,{children:[T(Me,{sx:{display:"flex",alignItems:"center"},children:["Review your changes",s(_t,{title:"Here you can see all the changes that you are suggesting and you can send them for review. You can still discard the changes after you sent them for review or even cancel the entire review if you need it",arrow:!0,children:s($Ee,{})})]}),s(OEe,{children:"Make sure you are sending the right changes to be reviewed"})]})}),KR=C(fr)(({theme:e})=>({height:"100vh",overflow:"auto",minWidth:"50vw",padding:e.spacing(6),[e.breakpoints.down("md")]:{padding:e.spacing(4,2)},"& .header":{padding:e.spacing(0,0,2,0)},"& .body":{padding:e.spacing(3,0,0,0)},borderRadius:`${e.spacing(1.5,0,0,1.5)} !important`})),NEe=C(Ze)(({theme:e})=>({marginTop:e.spacing(2),marginLeft:"auto"})),MEe=C(AZ)(({theme:e})=>({color:e.palette.success.main,height:"32px",width:"32px",marginRight:e.spacing(1)})),DEe=C(Me)(()=>({marginLeft:"auto",display:"flex",alignItems:"center"})),BEe=()=>s(ye,{component:"span",sx:{marginLeft:1.5,marginRight:1.5,color:"dividerAlternative"},children:"|"}),FEe=({count:e})=>T(Me,{children:[T(ye,{component:"span",variant:"body1",color:"text.secondary",children:["Updates:"," "]}),T(ye,{component:"span",sx:{fontWeight:"bold"},children:[e," ",e===1?"feature toggle":"feature toggles"]})]}),zEe=({open:e,project:t,onClose:n})=>{const{data:r,loading:o,refetch:a}=Kv(t),{changeState:i,discardDraft:l}=d2(),{setToastApiError:c}=It(),u=async f=>{try{await i(t,f,{state:"In review"}),a()}catch(h){c(ft(h))}},d=async f=>{try{await l(t,f),a()}catch(h){c(ft(h))}};return!o&&!r?s(__,{open:e,onClose:n,label:"Review changes",children:T(KR,{disableBorder:!0,header:s(xn,{titleElement:"Review your changes"}),children:["There are no changes to review.",s(NEe,{onClick:n,children:"Close"})]})}):s(__,{open:e,onClose:n,label:"Review changes",children:s(KR,{disableBorder:!0,header:s(LEe,{}),children:r==null?void 0:r.map(f=>s(IEe,{environmentChangeRequest:f,onClose:n,onReview:u,onDiscard:d,children:s(AEe,{changeRequest:f,onNavigate:n,onRefetch:a})},f.id))})})},jEe=C(Me)(({theme:e})=>({display:"flex",alignItems:"center",padding:e.spacing(1,0),[e.breakpoints.down("lg")]:{padding:e.spacing(1,2)},color:e.palette.warning.main})),UEe=C(Me)(({theme:e})=>({width:"1250px",marginLeft:"auto",marginRight:"auto",[e.breakpoints.down("lg")]:{width:"1024px"},[e.breakpoints.down(1024)]:{width:"100%",marginLeft:0,marginRight:0},[e.breakpoints.down("sm")]:{minWidth:"100%"}})),WEe=({changeRequest:e,onClick:t})=>s(UEe,{children:T(jEe,{children:[T(ye,{variant:"body2",sx:{mr:4},children:[s("strong",{children:"Change request mode"})," – You have changes"," ",s(X,{condition:Boolean(e.environment),show:T(ke,{children:["in ",T("strong",{children:[e.environment," "]})]})}),s(X,{condition:e.state==="Draft",show:"that need to be reviewed"}),s(X,{condition:e.state==="In review",show:"that are in review"}),s(X,{condition:e.state==="Approved",show:"that are approved. Adding more changes will clear the approvals and require a new review"})]}),T(Ze,{variant:"contained",onClick:t,sx:{ml:"auto"},children:["View changes (",T2(e),")"]})]})}),HEe=C(Me)(({theme:e})=>({position:"sticky",top:-1,zIndex:250,borderTop:`1px solid ${e.palette.warning.border}`,borderBottom:`1px solid ${e.palette.warning.border}`,backgroundColor:e.palette.warning.light})),VEe=({project:e})=>{const[t,n]=p.useState(!1),{data:r,loading:o}=Kv(e);return!o&&!r||(r==null?void 0:r.length)===0?null:T(HEe,{children:[r!=null&&r.length?r.filter(a=>["Draft","In review","Approved"].includes(a.state)).map(a=>s(WEe,{changeRequest:a,onClick:()=>{n(!0)}},a.id)):null,s(zEe,{project:e,open:t,onClose:()=>{n(!1)}})]})},GEe=C(In)(()=>({height:"100%",justifyContent:"space-between"})),qEe=C("main")(({theme:e})=>({margin:e.spacing(0,"auto"),overflow:"auto",flex:1,width:"100%",backgroundColor:e.palette.contentWrapper,position:"relative"})),KEe=C(In)(({theme:e})=>({width:"1250px",margin:"0 auto",[e.breakpoints.down("lg")]:{width:"1024px"},[e.breakpoints.down(1024)]:{width:"100%",marginLeft:0,marginRight:0},[e.breakpoints.down("sm")]:{minWidth:"100%"}})),YEe=C("img")(()=>({display:"block",position:"fixed",zIndex:0,bottom:0,right:0,width:400,pointerEvents:"none",userSelect:"none"})),XEe=C("div")(({theme:e})=>({height:"100%",padding:e.spacing(0,0,6.5,0),position:"relative",[e.breakpoints.down("md")]:{padding:e.spacing(0,1.5,6.5,1.5)},zIndex:200})),JEe=p.forwardRef(({children:e},t)=>{const{uiConfig:n}=Lt(),r=G3("projectId"),{isChangeRequestConfiguredInAnyEnv:o}=of(r||"");return T(ke,{children:[s(FCe,{}),s(SCe,{}),s(DCe,{}),T(GEe,{children:[T(qEe,{children:[s(X,{condition:Boolean(r&&o()),show:s(VEe,{project:r||""})}),s(KEe,{item:!0,xs:12,sm:12,my:2,children:T(XEe,{ref:t,children:[s(NCe,{}),s(ICe,{toast:n.toast}),e]})}),s(YEe,{src:Ys(MCe),alt:""})]}),s(kCe,{})]})]})}),QEe=({isStandalone:e,children:t})=>s(X,{condition:e===!0,show:t,elseShow:s(JEe,{children:t})}),ZEe=C("div")(({theme:e})=>({display:"flex",justifyContent:"center",alignItems:"center",minHeight:"100vh",padding:e.spacing(4),position:"fixed",inset:0,backgroundColor:e.palette.text.tertiaryContrast,width:"100%"})),eTe=C(p3)(({theme:e})=>({height:"80px"})),tTe=C("div")(({theme:e})=>({display:"flex",position:"relative"})),nTe=C("div")(({theme:e})=>({marginTop:e.spacing(4)})),rTe=C(Ze)(({theme:e})=>({height:"150px",width:"150px",position:"absolute",right:100,top:45})),oTe=()=>{const e=lt();return s(ZEe,{children:T("div",{children:[s(eTe,{}),s(tTe,{children:s(ye,{variant:"h1",style:{fontSize:"2rem"},children:"Ooops. That's a page we haven't toggled on yet."})}),T(nTe,{children:[s(Ze,{variant:"contained",color:"primary",onClick:()=>{e(jo)},children:"Go back"}),s(rTe,{onClick:()=>{e("/")},children:"Go home"})]})]})})},aTe=()=>{const{pathname:e,search:t}=ia(),r=`/login?redirect=${encodeURIComponent(e+t)}`;return s(_l,{to:r,replace:!0})},iTe=({route:e})=>{const{user:t}=ca();return!Boolean(t==null?void 0:t.id)&&e.type==="protected"?s(aTe,{}):s(e.component,{})},sTe=({children:e})=>{const{refetchUser:t}=ca();return s(bZ,{value:{onError:r=>{r instanceof U4&&r.status===401&&t()}},children:e})};function lTe(e,t,n){const r=/^localhost$|^127(?:\.[0-9]+){0,2}\.[0-9]+$|^(?:0*:)*?:?0*1$/.test(location.hostname)||location.protocol==="file:";if(!t.trackLocalhost&&r)return console.warn("[Plausible] Ignoring event because website is running locally");try{if(window.localStorage.plausible_ignore==="true")return console.warn('[Plausible] Ignoring event because "plausible_ignore" is set to "true" in localStorage')}catch{}const o={n:e,u:t.url,d:t.domain,r:t.referrer,w:t.deviceWidth,h:t.hashMode?1:0,p:n&&n.props?JSON.stringify(n.props):void 0},a=new XMLHttpRequest;a.open("POST",`${t.apiHost}/api/event`,!0),a.setRequestHeader("Content-Type","text/plain"),a.send(JSON.stringify(o)),a.onreadystatechange=()=>{a.readyState===4&&n&&n.callback&&n.callback()}}function cTe(e){const t=()=>({hashMode:!1,trackLocalhost:!1,url:location.href,domain:location.hostname,referrer:document.referrer||null,deviceWidth:window.innerWidth,apiHost:"https://plausible.io",...e}),n=(i,l,c)=>{lTe(i,{...t(),...c},l)},r=(i,l)=>{n("pageview",l,i)};return{trackEvent:n,trackPageview:r,enableAutoPageviews:()=>{const i=()=>r(),l=history.pushState;return l&&(history.pushState=function(c,u,d){l.apply(this,[c,u,d]),i()},addEventListener("popstate",i)),e&&e.hashMode&&addEventListener("hashchange",i),r(),function(){l&&(history.pushState=l,removeEventListener("popstate",i)),e&&e.hashMode&&removeEventListener("hashchange",i)}},enableAutoOutboundTracking:(i=document,l={subtree:!0,childList:!0,attributes:!0,attributeFilter:["href"]})=>{function c(m){n("Outbound Link: Click",{props:{url:this.href}}),typeof process<"u"&&process,setTimeout(()=>{location.href=this.href},150),m.preventDefault()}const u=new Set;function d(m){m instanceof HTMLAnchorElement?m.host!==location.host&&(m.addEventListener("click",c),u.add(m)):"querySelectorAll"in m&&m.querySelectorAll("a").forEach(d)}function f(m){m instanceof HTMLAnchorElement?(m.removeEventListener("click",c),u.delete(m)):"querySelectorAll"in m&&m.querySelectorAll("a").forEach(f)}const h=new MutationObserver(m=>{m.forEach(y=>{y.type==="attributes"?(f(y.target),d(y.target)):y.type==="childList"&&(y.addedNodes.forEach(d),y.removedNodes.forEach(f))})});return i.querySelectorAll("a").forEach(d),h.observe(i,l),function(){u.forEach(y=>{y.removeEventListener("click",c)}),u.clear(),h.disconnect()}}}}const uTe="https://plausible.getunleash.io",dTe="app.unleash-hosted.com",s0=!1,pTe=({children:e})=>{var l;const[t,n]=p.useState(null),o=(()=>{var c;try{const u=((c=document.querySelector('meta[name="uiFlags"]'))==null?void 0:c.content)||"{}";return JSON.parse(u)}catch{return{}}})(),{uiConfig:a}=Lt(),i=Boolean(((l=a==null?void 0:a.flags)==null?void 0:l.T)||o.T||s0);return p.useEffect(()=>{if(i)try{const c=cTe({domain:s0?void 0:dTe,apiHost:s0?"http://localhost:8000":uTe,trackLocalhost:!0});return n(()=>c),c.enableAutoPageviews()}catch(c){console.warn(c)}},[i]),s(q4.Provider,{value:t,children:e})},fTe=Li()(e=>({container:{maxWidth:"450px",background:e.palette.background.paper,boxShadow:"2px 2px 4px rgba(0,0,0,0.4)",zIndex:500,margin:"0 0.8rem",borderRadius:"12.5px",padding:"2rem"},innerContainer:{position:"relative"},starting:{opacity:0},headerContainer:{display:"flex",alignItems:"center"},confettiContainer:{position:"relative",maxWidth:"600px",margin:"0 auto",display:"flex"},textContainer:{marginLeft:"1rem",wordBreak:"break-word"},headerStyles:{fontWeight:"normal",margin:0,marginBottom:"0.5rem"},createdContainer:{display:"flex",alignItems:"center",flexDirection:"column"},anim:{animation:"$drop 10s 3s"},checkMark:{width:"65px",height:"65px"},buttonStyle:{position:"absolute",top:"-33px",right:"-33px"},"@keyframes drop":{"0%":{opacity:"0%",top:"0%"},"10%":{opacity:"100%"},"100%":{top:"100%"}}})),hTe=C("div")(({theme:e})=>({backgroundColor:e.palette.checkmarkBadge,width:"75px",height:"75px",borderRadius:"50px",display:"flex",justifyContent:"center",alignItems:"center",[e.breakpoints.down("sm")]:{width:"50px",height:"50px"}})),mTe=C(uv)(({theme:e})=>({color:e.palette.tertiary.background,width:"35px",height:"35px"})),gTe=C(Am)(({theme:e})=>({color:e.palette.tertiary.background,width:"35px",height:"35px"})),vTe=({type:e,className:t})=>s(hTe,{className:t,children:e==="error"?s(mTe,{titleAccess:"Error"}):s(gTe,{})}),yTe=({title:e,text:t,type:n,confetti:r})=>{const{setToast:o}=p.useContext(Ps),{classes:a}=fTe(),i=["#d13447","#ffbf00","#263672"],l=200,c=f=>Math.floor(Math.random()*f)+1,u=()=>new Array(l).fill(1).map((m,y)=>{const g=c(8),v=c(100),b={position:"absolute",width:`${g}px`,height:`${g*.4}px`,backgroundColor:i[c(2)],left:`${v}%`,transform:`rotate(${c(101)}deg)`,animationDelay:`${c(5)}s`,animationDuration:`${c(3)}s`,animationEase:`${c(2)}s`};return s("div",{style:b,className:Ca(a.starting,a.anim)},y)}),d=()=>{o(f=>({...f,show:!1}))};return s("div",{className:a.container,children:s("div",{className:a.innerContainer,children:T("div",{className:a.confettiContainer,children:[r&&u(),T("div",{className:a.createdContainer,children:[T("div",{className:a.headerContainer,children:[s("div",{children:s(vTe,{type:n,className:a.checkMark})}),T("div",{className:a.textContainer,children:[s("h3",{className:a.headerStyles,children:e}),s(X,{condition:Boolean(t),show:s("p",{"data-testid":Lee,children:t})})]})]}),s(_t,{title:"Close",arrow:!0,children:s(Yt,{onClick:d,className:a.buttonStyle,size:"large",children:s(fv,{})})})]})]})})})},bTe=()=>{const{toastData:e,setToast:t}=p.useContext(Ps),n=()=>{t(o=>({...o,show:!1}))};p.useEffect(()=>{if(!e.autoHideDuration)return;let o=setTimeout(()=>{n()},e.autoHideDuration);return()=>{clearTimeout(o)}},[e==null?void 0:e.show]);const r=p.useMemo(()=>({start:{...Z4,right:0,left:0,margin:"0 auto",maxWidth:"450px"},enter:e3,leave:cte}),[]);return s(JS,{children:s(Rx,{mounted:Boolean(e==null?void 0:e.show),start:r.start,enter:r.enter,leave:r.leave,children:s(yTe,{...e})})})},wTe=()=>{const{pathname:e}=ia(),{user:t}=ca(),{splash:n}=KO(),{uiConfig:r,loading:o}=Lt();if(!t||!n||!r||o||M5("/splash/:splashId",e)||t.isAPI)return null;const a=Uhe.find(i=>!STe(i,n));return a?s(_l,{to:`/splash/${a}`,replace:!0}):null},STe=(e,t)=>Boolean(t[e]),xTe=C($Z)(({theme:e})=>({height:"20px",width:"20px",marginRight:e.spacing(1)})),CTe=C("div")(({theme:e})=>({display:"flex",fontSize:e.fontSizes.smallBody,justifyContent:"center",alignItems:"center",color:e.palette.error.main,backgroundColor:e.palette.error.light,height:"65px",borderBottom:`1px solid ${e.palette.error.border}`,whiteSpace:"pre-wrap"})),ETe=()=>T(CTe,{children:[s(xTe,{}),s("b",{children:"Maintenance Mode! "}),s("p",{children:"During maintenance mode, any changes made will not be saved and you may receive an error. We apologize for any inconvenience this may cause."})]}),TTe=()=>{const e=`${Oi}:unleash-lastViewedProject`,[t,n]=p.useState(()=>gp(e));return p.useEffect(()=>{t&&zc(e,t)},[t,e]),{lastViewed:t,setLastViewed:n}},kTe=()=>{const{lastViewed:e}=TTe(),{projects:t,loading:n}=Bi(),r=lt(),o=p.useCallback(()=>t&&e?`/projects/${e}`:t&&!e&&t.length===1?`/projects/${t[0].id}`:"/projects",[e,t]),a=()=>{r(o(),{replace:!0})};return p.useEffect(()=>{a()},[o]),n?s(Fm,{}):null},ATe=C("div")(()=>({"& ul":{margin:0}})),_Te=()=>{const{authDetails:e}=fu(),{refetch:t}=Lt(),{user:n}=ca(),r=Boolean(e||n),{isOss:o,uiConfig:a}=Lt(),i=o()?Pp.filter(l=>!l.enterprise):Pp;return p.useEffect(()=>{r&&Boolean(n==null?void 0:n.id)&&t()},[e,n]),s(iee,{FallbackComponent:zee,children:s(sTe,{children:s(p.Suspense,{fallback:s(Fm,{}),children:s(pTe,{children:s(X,{condition:!r,show:s(Fm,{}),elseShow:T(ke,{children:[s(X,{condition:Boolean(a==null?void 0:a.maintenanceMode),show:s(ETe,{})}),T(ATe,{children:[s(bTe,{}),T(C9,{children:[i.map(l=>s(Rh,{path:l.path,element:s(QEe,{isStandalone:l.isStandalone===!0,children:s(iTe,{route:l})})},l.path)),s(Rh,{path:"/",element:s(kTe,{})}),s(Rh,{path:"*",element:s(oTe,{})})]}),s(yte,{openUrl:"http://feedback.unleash.run"}),s(wTe,{})]})]})})})})})})},RTe=()=>{const{pathname:e}=ia();return p.useEffect(()=>{PTe.some(t=>e.includes(t))||window.scrollTo(0,0)},[e]),null},PTe=["/admin/api","/admin/users","/admin/auth","/admin/roles"],ITe=({children:e})=>{const{permissions:t}=bC(),n=p.useMemo(()=>({isAdmin:$Te(t),hasAccess:OTe.bind(null,t)}),[t]);return s(Gr.Provider,{value:n,children:e})},$Te=e=>e?e.some(t=>t.permission===Fo):!1,OTe=(e,t,n,r)=>e?e.some(o=>LTe(o,t,n,r)):!1,LTe=(e,t,n,r)=>t?e.permission===Fo||e.permission===t&&(e.project===n||e.project==="*")&&(e.environment===r||e.environment==="*")||e.permission===t&&(e.project===n||e.project==="*")&&!Boolean(e.environment)?!0:e.permission===t&&e.project===void 0&&e.environment===null:(console.warn(`Missing permission for AccessProvider: ${t}`),!1),NTe=C("div")(({theme:e})=>({display:"flex",gap:e.spacing(2),alignItems:"center",margin:"0 auto"})),YR=C("span")(({theme:e})=>({width:"6.25rem",whiteSpace:"nowrap",color:e.palette.text.secondary,"&:first-of-type":{textAlign:"right"},[e.breakpoints.down("sm")]:{display:"none"}})),MTe=C("label")(({theme:e})=>({"& input":{clip:"rect(0 0 0 0)",clipPath:"inset(50%)",overflow:"hidden",position:"absolute",whiteSpace:"nowrap",width:1,height:1},"& span":{display:"grid",justifyContent:"center",alignItems:"center",background:e.palette.grey[300],width:"3rem",height:"3rem",borderRadius:"10rem",fontSize:"1.25rem",paddingBottom:2,userSelect:"none",cursor:"pointer"},"& input:checked + span":{fontWeight:e.fontWeight.bold,background:e.palette.primary.main,color:e.palette.text.tertiaryContrast},"& input:focus-visible + span":{outline:"2px solid",outlineOffset:2,outlineColor:e.palette.primary.main}})),DTe=({form:e,setForm:t})=>{const n=r=>{t(Ko(o=>{o.score=Number(r.target.value)}))};return T(NTe,{children:[s(YR,{children:"Very difficult"}),[1,2,3,4,5,6,7].map(r=>T(MTe,{children:[s("input",{type:"radio",name:"score",value:r,checked:e.score===r,onChange:n}),s("span",{children:r})]},r)),s(YR,{children:"Very easy"})]})},BTe=async e=>{if(!e.score)return;const t={source:"app:segments",data:{score:e.score,comment:e.comment,currentPage:e.path,openedManually:!1,customerType:"paying"}};await fetch("https://europe-west3-metrics-304612.cloudfunctions.net/docs-app-feedback",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)})},FTe=C("div")(({theme:e})=>({fontWeight:e.fontWeight.thin})),zTe=C("h1")(({theme:e})=>({all:"unset",display:"block",textAlign:"center",color:e.palette.text.secondary})),jTe=C("form")(({theme:e})=>({display:"grid",gap:e.spacing(6),gridTemplateColumns:"minmax(auto, 40rem)",justifyContent:"center"})),UTe=C("p")(({theme:e})=>({all:"unset",display:"block",marginTop:e.spacing(5),fontSize:e.spacing(3),textAlign:"center"})),WTe=C("label")(({theme:e})=>({display:"block",marginBottom:e.spacing(1)})),HTe=({state:e,onClose:t})=>{const[n,r]=p.useState(!1),{setToastData:o}=It(),[a,i]=p.useState({path:e.path}),l=u=>{i(Ko(d=>{d.comment=u.target.value}))};return T(FTe,{children:[s(zTe,{children:"Please help us improve"}),T(jTe,{onSubmit:async u=>{if(u.preventDefault(),!n)try{r(!0),await BTe(a),o({type:"success",title:"Feedback sent. Thank you!",confetti:!0}),t()}finally{r(!1)}},"aria-live":"polite",children:[s(UTe,{children:e.title}),s(DTe,{form:a,setForm:i}),T("div",{hidden:!a.score,children:[s(WTe,{htmlFor:"comment",children:e.text}),s(mn,{value:a.comment??"",onChange:l,multiline:!0,rows:3,variant:"outlined",fullWidth:!0})]}),s(Me,{hidden:!a.score,sx:{textAlign:"center"},children:s(Ze,{type:"submit",color:"primary",variant:"contained",sx:{minWidth:"15rem"},disabled:!a.score||n,children:"Send feedback"})})]})]})},VTe=C("div")(({theme:e})=>({pointerEvents:"none",display:"grid",padding:e.spacing(2),overflowY:"auto",alignItems:"center",justifyContent:"center",height:"100vh",width:"100vw"})),GTe=C("div")(({theme:e})=>({pointerEvents:"auto",position:"relative",padding:e.spacing(8),background:e.palette.background.paper,boxShadow:"0 0 1rem rgba(0, 0, 0, 0.25)",borderRadius:e.spacing(2),[e.breakpoints.down("md")]:{padding:e.spacing(4)}})),qTe=C("div")({all:"unset",position:"absolute",top:0,right:0}),KTe=C(P4)(({theme:e})=>({fontSize:"1.5rem",color:e.palette.inactiveIcon})),YTe=({state:e})=>{const{hideFeedbackCES:t}=p.useContext(c2),n=e&&s(HTe,{state:e,onClose:t});return s(Kp,{open:Boolean(e),onClose:t,"aria-label":e==null?void 0:e.title,children:s(VTe,{children:T(GTe,{children:[s(qTe,{children:s(Yt,{onClick:t,size:"large",children:s(KTe,{titleAccess:"Close"})})}),n]})})})},XTe=()=>{const{createFeedback:e}=r3(),{feedback:t}=Ix(),n=p.useCallback(o=>!!t&&t.some(a=>a.feedbackId===XR(o)),[t]),r=p.useCallback(o=>e({feedbackId:XR(o)}),[e]);return{isSeen:n,setSeen:r}},XR=e=>`ces${e.path}`,JTe=(e=window.location.hostname)=>e==="localhost",QTe=(e=window.location.hostname)=>e.endsWith(".getunleash.io")||e.endsWith(".unleash-hosted.com"),ZTe=(e=window.location.hostname)=>e.endsWith(".vercel.app"),eke=()=>QTe()||ZTe()||JTe(),tke=({children:e})=>{const[t,n]=p.useState(),{isSeen:r,setSeen:o}=XTe(),a=eke();p.useEffect(()=>{t&&o(t)},[t,o]);const i=p.useCallback(u=>{n(d=>{const f=u instanceof Function?u(d):u;return!a||!f||r(f)?void 0:f})},[a,r]),l=p.useCallback(()=>{n(void 0)},[n]),c=p.useMemo(()=>({showFeedbackCES:i,hideFeedbackCES:l}),[i,l]);return T(c2.Provider,{value:c,children:[e,s(YTe,{state:t})]})},nke=C("div")({clip:"rect(0 0 0 0)",clipPath:"inset(50%)",zIndex:-1,width:1,height:1,margin:-1,padding:0,overflow:"hidden"}),rke=({announcement:e})=>s(nke,{role:"status","aria-live":"polite","aria-atomic":!0,"data-testid":Oee,children:e}),oke=({children:e})=>{const[t,n]=p.useState(),r=p.useMemo(()=>({setAnnouncement:n}),[n]);return T(Vx.Provider,{value:r,children:[e,s(rke,{announcement:t})]})};var Ci=(e=>(e.UNASSIGNED="UNASSIGNED",e.TRIAL="TRIAL",e.ACTIVE="ACTIVE",e.EXPIRED="EXPIRED",e.CHURNED="CHURNED",e))(Ci||{}),lc=(e=>(e.PRO="Pro",e.COMPANY="Company",e.TEAM="Team",e.UNKNOWN="Unknown",e))(lc||{});const ake=(e,t,n)=>{const{data:r,error:o,mutate:a}=dn(e,t,n),i=p.useCallback(()=>{a().catch(console.warn)},[a]);return{data:r,error:o,refetch:i,loading:!o&&!r}},ike=()=>{const{uiConfig:e}=Lt(),{flags:{UNLEASH_CLOUD:t}}=e,{data:n,refetch:r,loading:o,error:a}=ake(["useInstanceStatus",t],()=>ske(t)),i=[lc.PRO,lc.COMPANY,lc.TEAM];return{instanceStatus:n,refetchInstanceStatus:r,refresh:async()=>{await fetch(Dt("api/instance/refresh"))},isBilling:i.includes((n==null?void 0:n.plan)??lc.UNKNOWN),loading:o,error:a}},ske=async e=>{if(!e)return JR;const t=await fetch(Dt("api/instance/status"));return t.ok?t.json():JR},JR={plan:lc.UNKNOWN},lke=10,cke=e=>(e==null?void 0:e.state)===Ci.TRIAL||(e==null?void 0:e.state)===Ci.EXPIRED||(e==null?void 0:e.state)===Ci.CHURNED,pN=e=>(e==null?void 0:e.state)===Ci.EXPIRED||(e==null?void 0:e.state)===Ci.CHURNED?!0:(e==null?void 0:e.state)===Ci.TRIAL&&(e!=null&&e.trialExpiry)?Moe(rf(e.trialExpiry)):!1,uke=e=>!e||e.state!==Ci.TRIAL||!e.trialExpiry?!1:t3(rf(e.trialExpiry),new Date)<=lke,QR=e=>Boolean(e&&e.state===Ci.EXPIRED&&!e.trialExtended),dke=C("aside")(({theme:e})=>({position:"relative",zIndex:1,display:"flex",alignItems:"center",justifyContent:"center",padding:e.spacing(1),gap:e.spacing(1),borderBottom:"1px solid",borderColor:e.palette.warning.border,background:e.palette.warning.light,color:e.palette.warning.dark})),fN=C("aside")(({theme:e})=>({position:"relative",zIndex:1,display:"flex",alignItems:"center",justifyContent:"center",padding:e.spacing(1),gap:e.spacing(1),borderBottom:"1px solid",borderColor:e.palette.info.border,background:e.palette.info.light,color:e.palette.info.dark})),pke=C(Ze)(({theme:e})=>({whiteSpace:"nowrap",minWidth:"8rem",marginLeft:e.spacing(2)})),fke=C(D4)(({theme:e})=>({color:e.palette.warning.main})),hN=C(Bd)(({theme:e})=>({color:e.palette.info.main})),hke=({instanceStatus:e})=>pN(e)?s(mke,{instanceStatus:e}):uke(e)?s(gke,{instanceStatus:e}):cke(e)?s(vke,{instanceStatus:e}):null,mke=({instanceStatus:e})=>T(dke,{"data-testid":Ax,children:[s(fke,{}),T(ye,{sx:t=>({fontSize:t.fontSizes.smallBody}),children:[s("strong",{children:"Warning!"})," Your free ",e.plan," trial has expired. ",s("strong",{children:"Upgrade trial"})," otherwise your"," ",s("strong",{children:"account will be deleted."})]}),s(k2,{})]}),gke=({instanceStatus:e})=>{const t=Noe(rf(e.trialExpiry),{roundingMethod:"floor"});return T(fN,{"data-testid":Ax,children:[s(hN,{}),T(ye,{sx:n=>({fontSize:n.fontSizes.smallBody}),children:[s("strong",{children:"Heads up!"})," You have"," ",s("strong",{children:t})," left of your free"," ",e.plan," trial."]}),s(k2,{})]})},vke=({instanceStatus:e})=>T(fN,{"data-testid":Ax,children:[s(hN,{}),T(ye,{sx:t=>({fontSize:t.fontSizes.smallBody}),children:[s("strong",{children:"Heads up!"})," You're currently on a free"," ",e.plan," trial account."]}),s(k2,{})]}),k2=()=>{const{hasAccess:e}=p.useContext(Gr),t=lt();return e(Fo)?s(pke,{onClick:()=>t("/admin/billing"),variant:"outlined",children:"Upgrade trial"}):null},yke=()=>{const{makeRequest:e,createRequest:t,errors:n,loading:r}=Nn({propagateErrors:!0});return{extendTrial:async()=>{const i=t("api/instance/extend",{method:"POST"},"extendTrial");await e(i.caller,i.id)},loading:r,errors:n}},bke=({instanceStatus:e,onExtendTrial:t})=>{const{hasAccess:n}=p.useContext(Gr),r=lt(),o=pN(e),[a,i]=p.useState(o),l=(c,u)=>{u||(i(!1),QR(e)&&t().catch(console.error))};return p.useEffect(()=>{i(o);const c=setInterval(()=>{i(o)},6e4);return()=>clearInterval(c)},[o]),n(Fo)?s(Zn,{open:a,primaryButtonText:"Upgrade trial",secondaryButtonText:QR(e)?"Extend trial (5 days)":"Remind me later",onClick:()=>{r("/admin/billing"),i(!1)},onClose:l,title:`Your free ${e.plan} trial has expired!`,children:T(ye,{children:[s("strong",{children:"Upgrade trial"})," otherwise your"," ",s("strong",{children:"account will be deleted."})]})}):s(Zn,{open:a,secondaryButtonText:"Remind me later",onClose:()=>{i(!1)},title:`Your free ${e.plan} trial has expired!`,children:T(ye,{children:["Please inform your admin to ",s("strong",{children:"Upgrade trial"})," or your ",s("strong",{children:"account will be deleted."})]})})},wke=({children:e})=>{const{instanceStatus:t,refetchInstanceStatus:n,isBilling:r}=ike(),{extendTrial:o}=yke(),{setToastApiError:a}=It(),i=on(),l=async()=>{try{await o(),await n()}catch(c){a(ft(c))}};return T("div",{style:{height:"100%",backgroundColor:i.palette.background.paper},children:[s(X,{condition:r&&Boolean(t),show:()=>T(ke,{children:[s(Ske,{instanceStatus:t}),s(bke,{instanceStatus:t,onExtendTrial:l})]})}),e]})},Ske=jt.memo(hke),xke=e=>{const t=gp("unleash-theme");if(t)return t;let n;return e&&(n=window.matchMedia("(prefers-color-scheme: dark)").matches),n?"dark":"light"},Cke=({children:e,darkmode:t=!1})=>{const[n,r]=p.useState(y4()),[o,a]=p.useState(!1),[i,l]=p.useState(xke(t)),c=jt.useMemo(()=>({setToast:r,toastData:n,showFeedback:o,setShowFeedback:a,themeMode:i,setThemeMode:l}),[n,o,i]);return s(Ps.Provider,{value:c,children:e})},Eke=({children:e})=>{const{uiConfig:t}=Lt();return t.flags?s(Cke,{darkmode:t.flags.ENABLE_DARK_MODE_SUPPORT||!1,children:e}):null},ZR=["http","https","mailto","tel"];function Tke(e){const t=(e||"").trim(),n=t.charAt(0);if(n==="#"||n==="/")return t;const r=t.indexOf(":");if(r===-1)return t;let o=-1;for(;++o<ZR.length;){const a=ZR[o];if(r===a.length&&t.slice(0,a.length).toLowerCase()===a)return t}return o=t.indexOf("?"),o!==-1&&r>o||(o=t.indexOf("#"),o!==-1&&r>o)?t:"javascript:void(0)"}/*!
|
|
363
|
+
* Determine if an object is a Buffer
|
|
364
|
+
*
|
|
365
|
+
* @author Feross Aboukhadijeh <https://feross.org>
|
|
366
|
+
* @license MIT
|
|
367
|
+
*/var mN=function(t){return t!=null&&t.constructor!=null&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t)};function Wd(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?eP(e.position):"start"in e||"end"in e?eP(e):"line"in e||"column"in e?fw(e):""}function fw(e){return tP(e&&e.line)+":"+tP(e&&e.column)}function eP(e){return fw(e&&e.start)+"-"+fw(e&&e.end)}function tP(e){return e&&typeof e=="number"?e:1}class ua extends Error{constructor(t,n,r){const o=[null,null];let a={start:{line:null,column:null},end:{line:null,column:null}};if(super(),typeof n=="string"&&(r=n,n=void 0),typeof r=="string"){const i=r.indexOf(":");i===-1?o[1]=r:(o[0]=r.slice(0,i),o[1]=r.slice(i+1))}n&&("type"in n||"position"in n?n.position&&(a=n.position):"start"in n||"end"in n?a=n:("line"in n||"column"in n)&&(a.start=n)),this.name=Wd(n)||"1:1",this.message=typeof t=="object"?t.message:t,this.stack="",typeof t=="object"&&t.stack&&(this.stack=t.stack),this.reason=this.message,this.fatal,this.line=a.start.line,this.column=a.start.column,this.position=a,this.source=o[0],this.ruleId=o[1],this.file,this.actual,this.expected,this.url,this.note}}ua.prototype.file="";ua.prototype.name="";ua.prototype.reason="";ua.prototype.message="";ua.prototype.stack="";ua.prototype.fatal=null;ua.prototype.column=null;ua.prototype.line=null;ua.prototype.source=null;ua.prototype.ruleId=null;ua.prototype.position=null;const $a={basename:kke,dirname:Ake,extname:_ke,join:Rke,sep:"/"};function kke(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');cf(e);let n=0,r=-1,o=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;o--;)if(e.charCodeAt(o)===47){if(a){n=o+1;break}}else r<0&&(a=!0,r=o+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let i=-1,l=t.length-1;for(;o--;)if(e.charCodeAt(o)===47){if(a){n=o+1;break}}else i<0&&(a=!0,i=o+1),l>-1&&(e.charCodeAt(o)===t.charCodeAt(l--)?l<0&&(r=o):(l=-1,r=i));return n===r?r=i:r<0&&(r=e.length),e.slice(n,r)}function Ake(e){if(cf(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.charCodeAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.charCodeAt(0)===47?"/":".":t===1&&e.charCodeAt(0)===47?"//":e.slice(0,t)}function _ke(e){cf(e);let t=e.length,n=-1,r=0,o=-1,a=0,i;for(;t--;){const l=e.charCodeAt(t);if(l===47){if(i){r=t+1;break}continue}n<0&&(i=!0,n=t+1),l===46?o<0?o=t:a!==1&&(a=1):o>-1&&(a=-1)}return o<0||n<0||a===0||a===1&&o===n-1&&o===r+1?"":e.slice(o,n)}function Rke(...e){let t=-1,n;for(;++t<e.length;)cf(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":Pke(n)}function Pke(e){cf(e);const t=e.charCodeAt(0)===47;let n=Ike(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.charCodeAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function Ike(e,t){let n="",r=0,o=-1,a=0,i=-1,l,c;for(;++i<=e.length;){if(i<e.length)l=e.charCodeAt(i);else{if(l===47)break;l=47}if(l===47){if(!(o===i-1||a===1))if(o!==i-1&&a===2){if(n.length<2||r!==2||n.charCodeAt(n.length-1)!==46||n.charCodeAt(n.length-2)!==46){if(n.length>2){if(c=n.lastIndexOf("/"),c!==n.length-1){c<0?(n="",r=0):(n=n.slice(0,c),r=n.length-1-n.lastIndexOf("/")),o=i,a=0;continue}}else if(n.length>0){n="",r=0,o=i,a=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(o+1,i):n=e.slice(o+1,i),r=i-o-1;o=i,a=0}else l===46&&a>-1?a++:a=-1}return n}function cf(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const $ke={cwd:Oke};function Oke(){return"/"}function hw(e){return e!==null&&typeof e=="object"&&e.href&&e.origin}function Lke(e){if(typeof e=="string")e=new URL(e);else if(!hw(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return Nke(e)}function Nke(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.charCodeAt(n)===37&&t.charCodeAt(n+1)===50){const r=t.charCodeAt(n+2);if(r===70||r===102){const o=new TypeError("File URL path must not include encoded / characters");throw o.code="ERR_INVALID_FILE_URL_PATH",o}}return decodeURIComponent(t)}const l0=["history","path","basename","stem","extname","dirname"];class gN{constructor(t){let n;t?typeof t=="string"||mN(t)?n={value:t}:hw(t)?n={path:t}:n=t:n={},this.data={},this.messages=[],this.history=[],this.cwd=$ke.cwd(),this.value,this.stored,this.result,this.map;let r=-1;for(;++r<l0.length;){const a=l0[r];a in n&&n[a]!==void 0&&(this[a]=a==="history"?[...n[a]]:n[a])}let o;for(o in n)l0.includes(o)||(this[o]=n[o])}get path(){return this.history[this.history.length-1]}set path(t){hw(t)&&(t=Lke(t)),u0(t,"path"),this.path!==t&&this.history.push(t)}get dirname(){return typeof this.path=="string"?$a.dirname(this.path):void 0}set dirname(t){nP(this.basename,"dirname"),this.path=$a.join(t||"",this.basename)}get basename(){return typeof this.path=="string"?$a.basename(this.path):void 0}set basename(t){u0(t,"basename"),c0(t,"basename"),this.path=$a.join(this.dirname||"",t)}get extname(){return typeof this.path=="string"?$a.extname(this.path):void 0}set extname(t){if(c0(t,"extname"),nP(this.dirname,"extname"),t){if(t.charCodeAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=$a.join(this.dirname,this.stem+(t||""))}get stem(){return typeof this.path=="string"?$a.basename(this.path,this.extname):void 0}set stem(t){u0(t,"stem"),c0(t,"stem"),this.path=$a.join(this.dirname||"",t+(this.extname||""))}toString(t){return(this.value||"").toString(t)}message(t,n,r){const o=new ua(t,n,r);return this.path&&(o.name=this.path+":"+o.name,o.file=this.path),o.fatal=!1,this.messages.push(o),o}info(t,n,r){const o=this.message(t,n,r);return o.fatal=null,o}fail(t,n,r){const o=this.message(t,n,r);throw o.fatal=!0,o}}function c0(e,t){if(e&&e.includes($a.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+$a.sep+"`")}function u0(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function nP(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function rP(e){if(e)throw e}var Wh=Object.prototype.hasOwnProperty,vN=Object.prototype.toString,oP=Object.defineProperty,aP=Object.getOwnPropertyDescriptor,iP=function(t){return typeof Array.isArray=="function"?Array.isArray(t):vN.call(t)==="[object Array]"},sP=function(t){if(!t||vN.call(t)!=="[object Object]")return!1;var n=Wh.call(t,"constructor"),r=t.constructor&&t.constructor.prototype&&Wh.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!r)return!1;var o;for(o in t);return typeof o>"u"||Wh.call(t,o)},lP=function(t,n){oP&&n.name==="__proto__"?oP(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},cP=function(t,n){if(n==="__proto__")if(Wh.call(t,n)){if(aP)return aP(t,n).value}else return;return t[n]},uP=function e(){var t,n,r,o,a,i,l=arguments[0],c=1,u=arguments.length,d=!1;for(typeof l=="boolean"&&(d=l,l=arguments[1]||{},c=2),(l==null||typeof l!="object"&&typeof l!="function")&&(l={});c<u;++c)if(t=arguments[c],t!=null)for(n in t)r=cP(l,n),o=cP(t,n),l!==o&&(d&&o&&(sP(o)||(a=iP(o)))?(a?(a=!1,i=r&&iP(r)?r:[]):i=r&&sP(r)?r:{},lP(l,{name:n,newValue:e(d,i,o)})):typeof o<"u"&&lP(l,{name:n,newValue:o}));return l};function mw(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function Mke(){const e=[],t={run:n,use:r};return t;function n(...o){let a=-1;const i=o.pop();if(typeof i!="function")throw new TypeError("Expected function as last argument, not "+i);l(null,...o);function l(c,...u){const d=e[++a];let f=-1;if(c){i(c);return}for(;++f<o.length;)(u[f]===null||u[f]===void 0)&&(u[f]=o[f]);o=u,d?Dke(d,l)(...u):i(null,...u)}}function r(o){if(typeof o!="function")throw new TypeError("Expected `middelware` to be a function, not "+o);return e.push(o),t}}function Dke(e,t){let n;return r;function r(...i){const l=e.length>i.length;let c;l&&i.push(o);try{c=e.apply(this,i)}catch(u){const d=u;if(l&&n)throw d;return o(d)}l||(c instanceof Promise?c.then(a,o):c instanceof Error?o(c):a(c))}function o(i,...l){n||(n=!0,t(i,...l))}function a(i){o(null,i)}}const Bke=bN().freeze(),yN={}.hasOwnProperty;function bN(){const e=Mke(),t=[];let n={},r,o=-1;return a.data=i,a.Parser=void 0,a.Compiler=void 0,a.freeze=l,a.attachers=t,a.use=c,a.parse=u,a.stringify=d,a.run=f,a.runSync=h,a.process=m,a.processSync=y,a;function a(){const g=bN();let v=-1;for(;++v<t.length;)g.use(...t[v]);return g.data(uP(!0,{},n)),g}function i(g,v){return typeof g=="string"?arguments.length===2?(f0("data",r),n[g]=v,a):yN.call(n,g)&&n[g]||null:g?(f0("data",r),n=g,a):n}function l(){if(r)return a;for(;++o<t.length;){const[g,...v]=t[o];if(v[0]===!1)continue;v[0]===!0&&(v[0]=void 0);const b=g.call(a,...v);typeof b=="function"&&e.use(b)}return r=!0,o=Number.POSITIVE_INFINITY,a}function c(g,...v){let b;if(f0("use",r),g!=null)if(typeof g=="function")A(g,...v);else if(typeof g=="object")Array.isArray(g)?E(g):x(g);else throw new TypeError("Expected usable value, not `"+g+"`");return b&&(n.settings=Object.assign(n.settings||{},b)),a;function w(k){if(typeof k=="function")A(k);else if(typeof k=="object")if(Array.isArray(k)){const[_,...$]=k;A(_,...$)}else x(k);else throw new TypeError("Expected usable value, not `"+k+"`")}function x(k){E(k.plugins),k.settings&&(b=Object.assign(b||{},k.settings))}function E(k){let _=-1;if(k!=null)if(Array.isArray(k))for(;++_<k.length;){const $=k[_];w($)}else throw new TypeError("Expected a list of plugins, not `"+k+"`")}function A(k,_){let $=-1,L;for(;++$<t.length;)if(t[$][0]===k){L=t[$];break}L?(mw(L[1])&&mw(_)&&(_=uP(!0,L[1],_)),L[1]=_):t.push([...arguments])}}function u(g){a.freeze();const v=sd(g),b=a.Parser;return d0("parse",b),dP(b,"parse")?new b(String(v),v).parse():b(String(v),v)}function d(g,v){a.freeze();const b=sd(v),w=a.Compiler;return p0("stringify",w),pP(g),dP(w,"compile")?new w(g,b).compile():w(g,b)}function f(g,v,b){if(pP(g),a.freeze(),!b&&typeof v=="function"&&(b=v,v=void 0),!b)return new Promise(w);w(null,b);function w(x,E){e.run(g,sd(v),A);function A(k,_,$){_=_||g,k?E(k):x?x(_):b(null,_,$)}}}function h(g,v){let b,w;return a.run(g,v,x),fP("runSync","run",w),b;function x(E,A){rP(E),b=A,w=!0}}function m(g,v){if(a.freeze(),d0("process",a.Parser),p0("process",a.Compiler),!v)return new Promise(b);b(null,v);function b(w,x){const E=sd(g);a.run(a.parse(E),E,(k,_,$)=>{if(k||!_||!$)A(k);else{const L=a.stringify(_,$);L==null||(jke(L)?$.value=L:$.result=L),A(k,$)}});function A(k,_){k||!_?x(k):w?w(_):v(null,_)}}}function y(g){let v;a.freeze(),d0("processSync",a.Parser),p0("processSync",a.Compiler);const b=sd(g);return a.process(b,w),fP("processSync","process",v),b;function w(x){v=!0,rP(x)}}}function dP(e,t){return typeof e=="function"&&e.prototype&&(Fke(e.prototype)||t in e.prototype)}function Fke(e){let t;for(t in e)if(yN.call(e,t))return!0;return!1}function d0(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Parser`")}function p0(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Compiler`")}function f0(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function pP(e){if(!mw(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function fP(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function sd(e){return zke(e)?e:new gN(e)}function zke(e){return Boolean(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function jke(e){return typeof e=="string"||mN(e)}function Uke(e,t){var{includeImageAlt:n=!0}=t||{};return wN(e,n)}function wN(e,t){return e&&typeof e=="object"&&(e.value||(t?e.alt:"")||"children"in e&&hP(e.children,t)||Array.isArray(e)&&hP(e,t))||""}function hP(e,t){for(var n=[],r=-1;++r<e.length;)n[r]=wN(e[r],t);return n.join("")}function ni(e,t,n,r){const o=e.length;let a=0,i;if(t<0?t=-t>o?0:o+t:t=t>o?o:t,n=n>0?n:0,r.length<1e4)i=Array.from(r),i.unshift(t,n),[].splice.apply(e,i);else for(n&&[].splice.apply(e,[t,n]);a<r.length;)i=r.slice(a,a+1e4),i.unshift(t,0),[].splice.apply(e,i),a+=1e4,t+=1e4}function Ho(e,t){return e.length>0?(ni(e,e.length,0,t),e):t}const mP={}.hasOwnProperty;function Wke(e){const t={};let n=-1;for(;++n<e.length;)Hke(t,e[n]);return t}function Hke(e,t){let n;for(n in t){const o=(mP.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let i;for(i in a){mP.call(o,i)||(o[i]=[]);const l=a[i];Vke(o[i],Array.isArray(l)?l:l?[l]:[])}}}function Vke(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);ni(e,0,0,r)}const Gke=/[!-/:-@[-`{-~\u00A1\u00A7\u00AB\u00B6\u00B7\u00BB\u00BF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/,Ba=$s(/[A-Za-z]/),gw=$s(/\d/),qke=$s(/[\dA-Fa-f]/),Ao=$s(/[\dA-Za-z]/),Kke=$s(/[!-/:-@[-`{-~]/),gP=$s(/[#-'*+\--9=?A-Z^-~]/);function vw(e){return e!==null&&(e<32||e===127)}function Qo(e){return e!==null&&(e<0||e===32)}function At(e){return e!==null&&e<-2}function ar(e){return e===-2||e===-1||e===32}const Yke=$s(/\s/),Xke=$s(Gke);function $s(e){return t;function t(n){return n!==null&&e.test(String.fromCharCode(n))}}function An(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let a=0;return i;function i(c){return ar(c)?(e.enter(n),l(c)):t(c)}function l(c){return ar(c)&&a++<o?(e.consume(c),l):(e.exit(n),t(c))}}const Jke={tokenize:Qke};function Qke(e){const t=e.attempt(this.parser.constructs.contentInitial,r,o);let n;return t;function r(l){if(l===null){e.consume(l);return}return e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),An(e,t,"linePrefix")}function o(l){return e.enter("paragraph"),a(l)}function a(l){const c=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=c),n=c,i(l)}function i(l){if(l===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(l);return}return At(l)?(e.consume(l),e.exit("chunkText"),a):(e.consume(l),i)}}const Zke={tokenize:eAe},vP={tokenize:tAe};function eAe(e){const t=this,n=[];let r=0,o,a,i;return l;function l(x){if(r<n.length){const E=n[r];return t.containerState=E[1],e.attempt(E[0].continuation,c,u)(x)}return u(x)}function c(x){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&w();const E=t.events.length;let A=E,k;for(;A--;)if(t.events[A][0]==="exit"&&t.events[A][1].type==="chunkFlow"){k=t.events[A][1].end;break}b(r);let _=E;for(;_<t.events.length;)t.events[_][1].end=Object.assign({},k),_++;return ni(t.events,A+1,0,t.events.slice(E)),t.events.length=_,u(x)}return l(x)}function u(x){if(r===n.length){if(!o)return h(x);if(o.currentConstruct&&o.currentConstruct.concrete)return y(x);t.interrupt=Boolean(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(vP,d,f)(x)}function d(x){return o&&w(),b(r),h(x)}function f(x){return t.parser.lazy[t.now().line]=r!==n.length,i=t.now().offset,y(x)}function h(x){return t.containerState={},e.attempt(vP,m,y)(x)}function m(x){return r++,n.push([t.currentConstruct,t.containerState]),h(x)}function y(x){if(x===null){o&&w(),b(0),e.consume(x);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{contentType:"flow",previous:a,_tokenizer:o}),g(x)}function g(x){if(x===null){v(e.exit("chunkFlow"),!0),b(0),e.consume(x);return}return At(x)?(e.consume(x),v(e.exit("chunkFlow")),r=0,t.interrupt=void 0,l):(e.consume(x),g)}function v(x,E){const A=t.sliceStream(x);if(E&&A.push(null),x.previous=a,a&&(a.next=x),a=x,o.defineSkip(x.start),o.write(A),t.parser.lazy[x.start.line]){let k=o.events.length;for(;k--;)if(o.events[k][1].start.offset<i&&(!o.events[k][1].end||o.events[k][1].end.offset>i))return;const _=t.events.length;let $=_,L,O;for(;$--;)if(t.events[$][0]==="exit"&&t.events[$][1].type==="chunkFlow"){if(L){O=t.events[$][1].end;break}L=!0}for(b(r),k=_;k<t.events.length;)t.events[k][1].end=Object.assign({},O),k++;ni(t.events,$+1,0,t.events.slice(_)),t.events.length=k}}function b(x){let E=n.length;for(;E-- >x;){const A=n[E];t.containerState=A[1],A[0].exit.call(t,e)}n.length=x}function w(){o.write([null]),a=void 0,o=void 0,t.containerState._closeFlow=void 0}}function tAe(e,t,n){return An(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function yP(e){if(e===null||Qo(e)||Yke(e))return 1;if(Xke(e))return 2}function A2(e,t,n){const r=[];let o=-1;for(;++o<e.length;){const a=e[o].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}const yw={name:"attention",tokenize:rAe,resolveAll:nAe};function nAe(e,t){let n=-1,r,o,a,i,l,c,u,d;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;c=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const f=Object.assign({},e[r][1].end),h=Object.assign({},e[n][1].start);bP(f,-c),bP(h,c),i={type:c>1?"strongSequence":"emphasisSequence",start:f,end:Object.assign({},e[r][1].end)},l={type:c>1?"strongSequence":"emphasisSequence",start:Object.assign({},e[n][1].start),end:h},a={type:c>1?"strongText":"emphasisText",start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},o={type:c>1?"strong":"emphasis",start:Object.assign({},i.start),end:Object.assign({},l.end)},e[r][1].end=Object.assign({},i.start),e[n][1].start=Object.assign({},l.end),u=[],e[r][1].end.offset-e[r][1].start.offset&&(u=Ho(u,[["enter",e[r][1],t],["exit",e[r][1],t]])),u=Ho(u,[["enter",o,t],["enter",i,t],["exit",i,t],["enter",a,t]]),u=Ho(u,A2(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),u=Ho(u,[["exit",a,t],["enter",l,t],["exit",l,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(d=2,u=Ho(u,[["enter",e[n][1],t],["exit",e[n][1],t]])):d=0,ni(e,r-1,n-r+3,u),n=r+u.length-d-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function rAe(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=yP(r);let a;return i;function i(c){return e.enter("attentionSequence"),a=c,l(c)}function l(c){if(c===a)return e.consume(c),l;const u=e.exit("attentionSequence"),d=yP(c),f=!d||d===2&&o||n.includes(c),h=!o||o===2&&d||n.includes(r);return u._open=Boolean(a===42?f:f&&(o||!h)),u._close=Boolean(a===42?h:h&&(d||!f)),t(c)}}function bP(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const oAe={name:"autolink",tokenize:aAe};function aAe(e,t,n){let r=1;return o;function o(y){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(y),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(y){return Ba(y)?(e.consume(y),i):gP(y)?u(y):n(y)}function i(y){return y===43||y===45||y===46||Ao(y)?l(y):u(y)}function l(y){return y===58?(e.consume(y),c):(y===43||y===45||y===46||Ao(y))&&r++<32?(e.consume(y),l):u(y)}function c(y){return y===62?(e.exit("autolinkProtocol"),m(y)):y===null||y===32||y===60||vw(y)?n(y):(e.consume(y),c)}function u(y){return y===64?(e.consume(y),r=0,d):gP(y)?(e.consume(y),u):n(y)}function d(y){return Ao(y)?f(y):n(y)}function f(y){return y===46?(e.consume(y),r=0,d):y===62?(e.exit("autolinkProtocol").type="autolinkEmail",m(y)):h(y)}function h(y){return(y===45||Ao(y))&&r++<63?(e.consume(y),y===45?h:f):n(y)}function m(y){return e.enter("autolinkMarker"),e.consume(y),e.exit("autolinkMarker"),e.exit("autolink"),t}}const Qv={tokenize:iAe,partial:!0};function iAe(e,t,n){return An(e,r,"linePrefix");function r(o){return o===null||At(o)?t(o):n(o)}}const SN={name:"blockQuote",tokenize:sAe,continuation:{tokenize:lAe},exit:cAe};function sAe(e,t,n){const r=this;return o;function o(i){if(i===62){const l=r.containerState;return l.open||(e.enter("blockQuote",{_container:!0}),l.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(i),e.exit("blockQuoteMarker"),a}return n(i)}function a(i){return ar(i)?(e.enter("blockQuotePrefixWhitespace"),e.consume(i),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(i))}}function lAe(e,t,n){return An(e,e.attempt(SN,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function cAe(e){e.exit("blockQuote")}const xN={name:"characterEscape",tokenize:uAe};function uAe(e,t,n){return r;function r(a){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(a),e.exit("escapeMarker"),o}function o(a){return Kke(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const wP=document.createElement("i");function _2(e){const t="&"+e+";";wP.innerHTML=t;const n=wP.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}const CN={name:"characterReference",tokenize:dAe};function dAe(e,t,n){const r=this;let o=0,a,i;return l;function l(f){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(f),e.exit("characterReferenceMarker"),c}function c(f){return f===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(f),e.exit("characterReferenceMarkerNumeric"),u):(e.enter("characterReferenceValue"),a=31,i=Ao,d(f))}function u(f){return f===88||f===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(f),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,i=qke,d):(e.enter("characterReferenceValue"),a=7,i=gw,d(f))}function d(f){let h;return f===59&&o?(h=e.exit("characterReferenceValue"),i===Ao&&!_2(r.sliceSerialize(h))?n(f):(e.enter("characterReferenceMarker"),e.consume(f),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)):i(f)&&o++<a?(e.consume(f),d):n(f)}}const SP={name:"codeFenced",tokenize:pAe,concrete:!0};function pAe(e,t,n){const r=this,o={tokenize:A,partial:!0},a={tokenize:E,partial:!0},i=this.events[this.events.length-1],l=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0;let c=0,u;return d;function d(k){return e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),u=k,f(k)}function f(k){return k===u?(e.consume(k),c++,f):(e.exit("codeFencedFenceSequence"),c<3?n(k):An(e,h,"whitespace")(k))}function h(k){return k===null||At(k)?v(k):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),m(k))}function m(k){return k===null||Qo(k)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),An(e,y,"whitespace")(k)):k===96&&k===u?n(k):(e.consume(k),m)}function y(k){return k===null||At(k)?v(k):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),g(k))}function g(k){return k===null||At(k)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),v(k)):k===96&&k===u?n(k):(e.consume(k),g)}function v(k){return e.exit("codeFencedFence"),r.interrupt?t(k):b(k)}function b(k){return k===null?x(k):At(k)?e.attempt(a,e.attempt(o,x,l?An(e,b,"linePrefix",l+1):b),x)(k):(e.enter("codeFlowValue"),w(k))}function w(k){return k===null||At(k)?(e.exit("codeFlowValue"),b(k)):(e.consume(k),w)}function x(k){return e.exit("codeFenced"),t(k)}function E(k,_,$){const L=this;return O;function O(D){return k.enter("lineEnding"),k.consume(D),k.exit("lineEnding"),P}function P(D){return L.parser.lazy[L.now().line]?$(D):_(D)}}function A(k,_,$){let L=0;return An(k,O,"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4);function O(F){return k.enter("codeFencedFence"),k.enter("codeFencedFenceSequence"),P(F)}function P(F){return F===u?(k.consume(F),L++,P):L<c?$(F):(k.exit("codeFencedFenceSequence"),An(k,D,"whitespace")(F))}function D(F){return F===null||At(F)?(k.exit("codeFencedFence"),_(F)):$(F)}}}const h0={name:"codeIndented",tokenize:hAe},fAe={tokenize:mAe,partial:!0};function hAe(e,t,n){const r=this;return o;function o(u){return e.enter("codeIndented"),An(e,a,"linePrefix",4+1)(u)}function a(u){const d=r.events[r.events.length-1];return d&&d[1].type==="linePrefix"&&d[2].sliceSerialize(d[1],!0).length>=4?i(u):n(u)}function i(u){return u===null?c(u):At(u)?e.attempt(fAe,i,c)(u):(e.enter("codeFlowValue"),l(u))}function l(u){return u===null||At(u)?(e.exit("codeFlowValue"),i(u)):(e.consume(u),l)}function c(u){return e.exit("codeIndented"),t(u)}}function mAe(e,t,n){const r=this;return o;function o(i){return r.parser.lazy[r.now().line]?n(i):At(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),o):An(e,a,"linePrefix",4+1)(i)}function a(i){const l=r.events[r.events.length-1];return l&&l[1].type==="linePrefix"&&l[2].sliceSerialize(l[1],!0).length>=4?t(i):At(i)?o(i):n(i)}}const gAe={name:"codeText",tokenize:bAe,resolve:vAe,previous:yAe};function vAe(e){let t=e.length-4,n=3,r,o;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)o===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(o=r):(r===t||e[r][1].type==="lineEnding")&&(e[o][1].type="codeTextData",r!==o+2&&(e[o][1].end=e[r-1][1].end,e.splice(o+2,r-o-2),t-=r-o-2,r=o+2),o=void 0);return e}function yAe(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function bAe(e,t,n){let r=0,o,a;return i;function i(f){return e.enter("codeText"),e.enter("codeTextSequence"),l(f)}function l(f){return f===96?(e.consume(f),r++,l):(e.exit("codeTextSequence"),c(f))}function c(f){return f===null?n(f):f===96?(a=e.enter("codeTextSequence"),o=0,d(f)):f===32?(e.enter("space"),e.consume(f),e.exit("space"),c):At(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),c):(e.enter("codeTextData"),u(f))}function u(f){return f===null||f===32||f===96||At(f)?(e.exit("codeTextData"),c(f)):(e.consume(f),u)}function d(f){return f===96?(e.consume(f),o++,d):o===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(f)):(a.type="codeTextData",u(f))}}function EN(e){const t={};let n=-1,r,o,a,i,l,c,u;for(;++n<e.length;){for(;n in t;)n=t[n];if(r=e[n],n&&r[1].type==="chunkFlow"&&e[n-1][1].type==="listItemPrefix"&&(c=r[1]._tokenizer.events,a=0,a<c.length&&c[a][1].type==="lineEndingBlank"&&(a+=2),a<c.length&&c[a][1].type==="content"))for(;++a<c.length&&c[a][1].type!=="content";)c[a][1].type==="chunkText"&&(c[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,wAe(e,n)),n=t[n],u=!0);else if(r[1]._container){for(a=n,o=void 0;a--&&(i=e[a],i[1].type==="lineEnding"||i[1].type==="lineEndingBlank");)i[0]==="enter"&&(o&&(e[o][1].type="lineEndingBlank"),i[1].type="lineEnding",o=a);o&&(r[1].end=Object.assign({},e[o][1].start),l=e.slice(o,n),l.unshift(r),ni(e,o,n-o+1,l))}}return!u}function wAe(e,t){const n=e[t][1],r=e[t][2];let o=t-1;const a=[],i=n._tokenizer||r.parser[n.contentType](n.start),l=i.events,c=[],u={};let d,f,h=-1,m=n,y=0,g=0;const v=[g];for(;m;){for(;e[++o][1]!==m;);a.push(o),m._tokenizer||(d=r.sliceStream(m),m.next||d.push(null),f&&i.defineSkip(m.start),m._isInFirstContentOfListItem&&(i._gfmTasklistFirstContentOfListItem=!0),i.write(d),m._isInFirstContentOfListItem&&(i._gfmTasklistFirstContentOfListItem=void 0)),f=m,m=m.next}for(m=n;++h<l.length;)l[h][0]==="exit"&&l[h-1][0]==="enter"&&l[h][1].type===l[h-1][1].type&&l[h][1].start.line!==l[h][1].end.line&&(g=h+1,v.push(g),m._tokenizer=void 0,m.previous=void 0,m=m.next);for(i.events=[],m?(m._tokenizer=void 0,m.previous=void 0):v.pop(),h=v.length;h--;){const b=l.slice(v[h],v[h+1]),w=a.pop();c.unshift([w,w+b.length-1]),ni(e,w,2,b)}for(h=-1;++h<c.length;)u[y+c[h][0]]=y+c[h][1],y+=c[h][1]-c[h][0]-1;return u}const SAe={tokenize:EAe,resolve:CAe},xAe={tokenize:TAe,partial:!0};function CAe(e){return EN(e),e}function EAe(e,t){let n;return r;function r(l){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),o(l)}function o(l){return l===null?a(l):At(l)?e.check(xAe,i,a)(l):(e.consume(l),o)}function a(l){return e.exit("chunkContent"),e.exit("content"),t(l)}function i(l){return e.consume(l),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,o}}function TAe(e,t,n){const r=this;return o;function o(i){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),An(e,a,"linePrefix")}function a(i){if(i===null||At(i))return n(i);const l=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&l&&l[1].type==="linePrefix"&&l[2].sliceSerialize(l[1],!0).length>=4?t(i):e.interrupt(r.parser.constructs.flow,n,t)(i)}}function TN(e,t,n,r,o,a,i,l,c){const u=c||Number.POSITIVE_INFINITY;let d=0;return f;function f(b){return b===60?(e.enter(r),e.enter(o),e.enter(a),e.consume(b),e.exit(a),h):b===null||b===41||vw(b)?n(b):(e.enter(r),e.enter(i),e.enter(l),e.enter("chunkString",{contentType:"string"}),g(b))}function h(b){return b===62?(e.enter(a),e.consume(b),e.exit(a),e.exit(o),e.exit(r),t):(e.enter(l),e.enter("chunkString",{contentType:"string"}),m(b))}function m(b){return b===62?(e.exit("chunkString"),e.exit(l),h(b)):b===null||b===60||At(b)?n(b):(e.consume(b),b===92?y:m)}function y(b){return b===60||b===62||b===92?(e.consume(b),m):m(b)}function g(b){return b===40?++d>u?n(b):(e.consume(b),g):b===41?d--?(e.consume(b),g):(e.exit("chunkString"),e.exit(l),e.exit(i),e.exit(r),t(b)):b===null||Qo(b)?d?n(b):(e.exit("chunkString"),e.exit(l),e.exit(i),e.exit(r),t(b)):vw(b)?n(b):(e.consume(b),b===92?v:g)}function v(b){return b===40||b===41||b===92?(e.consume(b),g):g(b)}}function kN(e,t,n,r,o,a){const i=this;let l=0,c;return u;function u(m){return e.enter(r),e.enter(o),e.consume(m),e.exit(o),e.enter(a),d}function d(m){return m===null||m===91||m===93&&!c||m===94&&!l&&"_hiddenFootnoteSupport"in i.parser.constructs||l>999?n(m):m===93?(e.exit(a),e.enter(o),e.consume(m),e.exit(o),e.exit(r),t):At(m)?(e.enter("lineEnding"),e.consume(m),e.exit("lineEnding"),d):(e.enter("chunkString",{contentType:"string"}),f(m))}function f(m){return m===null||m===91||m===93||At(m)||l++>999?(e.exit("chunkString"),d(m)):(e.consume(m),c=c||!ar(m),m===92?h:f)}function h(m){return m===91||m===92||m===93?(e.consume(m),l++,f):f(m)}}function AN(e,t,n,r,o,a){let i;return l;function l(h){return e.enter(r),e.enter(o),e.consume(h),e.exit(o),i=h===40?41:h,c}function c(h){return h===i?(e.enter(o),e.consume(h),e.exit(o),e.exit(r),t):(e.enter(a),u(h))}function u(h){return h===i?(e.exit(a),c(i)):h===null?n(h):At(h)?(e.enter("lineEnding"),e.consume(h),e.exit("lineEnding"),An(e,u,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),d(h))}function d(h){return h===i||h===null||At(h)?(e.exit("chunkString"),u(h)):(e.consume(h),h===92?f:d)}function f(h){return h===i||h===92?(e.consume(h),d):d(h)}}function Hd(e,t){let n;return r;function r(o){return At(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):ar(o)?An(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}function _c(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const kAe={name:"definition",tokenize:_Ae},AAe={tokenize:RAe,partial:!0};function _Ae(e,t,n){const r=this;let o;return a;function a(c){return e.enter("definition"),kN.call(r,e,i,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(c)}function i(c){return o=_c(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),c===58?(e.enter("definitionMarker"),e.consume(c),e.exit("definitionMarker"),Hd(e,TN(e,e.attempt(AAe,An(e,l,"whitespace"),An(e,l,"whitespace")),n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString"))):n(c)}function l(c){return c===null||At(c)?(e.exit("definition"),r.parser.defined.includes(o)||r.parser.defined.push(o),t(c)):n(c)}}function RAe(e,t,n){return r;function r(i){return Qo(i)?Hd(e,o)(i):n(i)}function o(i){return i===34||i===39||i===40?AN(e,An(e,a,"whitespace"),n,"definitionTitle","definitionTitleMarker","definitionTitleString")(i):n(i)}function a(i){return i===null||At(i)?t(i):n(i)}}const PAe={name:"hardBreakEscape",tokenize:IAe};function IAe(e,t,n){return r;function r(a){return e.enter("hardBreakEscape"),e.enter("escapeMarker"),e.consume(a),o}function o(a){return At(a)?(e.exit("escapeMarker"),e.exit("hardBreakEscape"),t(a)):n(a)}}const $Ae={name:"headingAtx",tokenize:LAe,resolve:OAe};function OAe(e,t){let n=e.length-2,r=3,o,a;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(o={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},a={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},ni(e,r,n-r+1,[["enter",o,t],["enter",a,t],["exit",a,t],["exit",o,t]])),e}function LAe(e,t,n){const r=this;let o=0;return a;function a(d){return e.enter("atxHeading"),e.enter("atxHeadingSequence"),i(d)}function i(d){return d===35&&o++<6?(e.consume(d),i):d===null||Qo(d)?(e.exit("atxHeadingSequence"),r.interrupt?t(d):l(d)):n(d)}function l(d){return d===35?(e.enter("atxHeadingSequence"),c(d)):d===null||At(d)?(e.exit("atxHeading"),t(d)):ar(d)?An(e,l,"whitespace")(d):(e.enter("atxHeadingText"),u(d))}function c(d){return d===35?(e.consume(d),c):(e.exit("atxHeadingSequence"),l(d))}function u(d){return d===null||d===35||Qo(d)?(e.exit("atxHeadingText"),l(d)):(e.consume(d),u)}}const NAe=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],xP=["pre","script","style","textarea"],MAe={name:"htmlFlow",tokenize:FAe,resolveTo:BAe,concrete:!0},DAe={tokenize:zAe,partial:!0};function BAe(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function FAe(e,t,n){const r=this;let o,a,i,l,c;return u;function u(M){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(M),d}function d(M){return M===33?(e.consume(M),f):M===47?(e.consume(M),y):M===63?(e.consume(M),o=3,r.interrupt?t:W):Ba(M)?(e.consume(M),i=String.fromCharCode(M),a=!0,g):n(M)}function f(M){return M===45?(e.consume(M),o=2,h):M===91?(e.consume(M),o=5,i="CDATA[",l=0,m):Ba(M)?(e.consume(M),o=4,r.interrupt?t:W):n(M)}function h(M){return M===45?(e.consume(M),r.interrupt?t:W):n(M)}function m(M){return M===i.charCodeAt(l++)?(e.consume(M),l===i.length?r.interrupt?t:P:m):n(M)}function y(M){return Ba(M)?(e.consume(M),i=String.fromCharCode(M),g):n(M)}function g(M){return M===null||M===47||M===62||Qo(M)?M!==47&&a&&xP.includes(i.toLowerCase())?(o=1,r.interrupt?t(M):P(M)):NAe.includes(i.toLowerCase())?(o=6,M===47?(e.consume(M),v):r.interrupt?t(M):P(M)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(M):a?w(M):b(M)):M===45||Ao(M)?(e.consume(M),i+=String.fromCharCode(M),g):n(M)}function v(M){return M===62?(e.consume(M),r.interrupt?t:P):n(M)}function b(M){return ar(M)?(e.consume(M),b):L(M)}function w(M){return M===47?(e.consume(M),L):M===58||M===95||Ba(M)?(e.consume(M),x):ar(M)?(e.consume(M),w):L(M)}function x(M){return M===45||M===46||M===58||M===95||Ao(M)?(e.consume(M),x):E(M)}function E(M){return M===61?(e.consume(M),A):ar(M)?(e.consume(M),E):w(M)}function A(M){return M===null||M===60||M===61||M===62||M===96?n(M):M===34||M===39?(e.consume(M),c=M,k):ar(M)?(e.consume(M),A):(c=null,_(M))}function k(M){return M===null||At(M)?n(M):M===c?(e.consume(M),$):(e.consume(M),k)}function _(M){return M===null||M===34||M===39||M===60||M===61||M===62||M===96||Qo(M)?E(M):(e.consume(M),_)}function $(M){return M===47||M===62||ar(M)?w(M):n(M)}function L(M){return M===62?(e.consume(M),O):n(M)}function O(M){return ar(M)?(e.consume(M),O):M===null||At(M)?P(M):n(M)}function P(M){return M===45&&o===2?(e.consume(M),Y):M===60&&o===1?(e.consume(M),V):M===62&&o===4?(e.consume(M),z):M===63&&o===3?(e.consume(M),W):M===93&&o===5?(e.consume(M),Z):At(M)&&(o===6||o===7)?e.check(DAe,z,D)(M):M===null||At(M)?D(M):(e.consume(M),P)}function D(M){return e.exit("htmlFlowData"),F(M)}function F(M){return M===null?R(M):At(M)?e.attempt({tokenize:U,partial:!0},F,R)(M):(e.enter("htmlFlowData"),P(M))}function U(M,ee,re){return Se;function Se(Ce){return M.enter("lineEnding"),M.consume(Ce),M.exit("lineEnding"),ce}function ce(Ce){return r.parser.lazy[r.now().line]?re(Ce):ee(Ce)}}function Y(M){return M===45?(e.consume(M),W):P(M)}function V(M){return M===47?(e.consume(M),i="",te):P(M)}function te(M){return M===62&&xP.includes(i.toLowerCase())?(e.consume(M),z):Ba(M)&&i.length<8?(e.consume(M),i+=String.fromCharCode(M),te):P(M)}function Z(M){return M===93?(e.consume(M),W):P(M)}function W(M){return M===62?(e.consume(M),z):M===45&&o===2?(e.consume(M),W):P(M)}function z(M){return M===null||At(M)?(e.exit("htmlFlowData"),R(M)):(e.consume(M),z)}function R(M){return e.exit("htmlFlow"),t(M)}}function zAe(e,t,n){return r;function r(o){return e.exit("htmlFlowData"),e.enter("lineEndingBlank"),e.consume(o),e.exit("lineEndingBlank"),e.attempt(Qv,t,n)}}const jAe={name:"htmlText",tokenize:UAe};function UAe(e,t,n){const r=this;let o,a,i,l;return c;function c(R){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(R),u}function u(R){return R===33?(e.consume(R),d):R===47?(e.consume(R),_):R===63?(e.consume(R),A):Ba(R)?(e.consume(R),O):n(R)}function d(R){return R===45?(e.consume(R),f):R===91?(e.consume(R),a="CDATA[",i=0,v):Ba(R)?(e.consume(R),E):n(R)}function f(R){return R===45?(e.consume(R),h):n(R)}function h(R){return R===null||R===62?n(R):R===45?(e.consume(R),m):y(R)}function m(R){return R===null||R===62?n(R):y(R)}function y(R){return R===null?n(R):R===45?(e.consume(R),g):At(R)?(l=y,Z(R)):(e.consume(R),y)}function g(R){return R===45?(e.consume(R),z):y(R)}function v(R){return R===a.charCodeAt(i++)?(e.consume(R),i===a.length?b:v):n(R)}function b(R){return R===null?n(R):R===93?(e.consume(R),w):At(R)?(l=b,Z(R)):(e.consume(R),b)}function w(R){return R===93?(e.consume(R),x):b(R)}function x(R){return R===62?z(R):R===93?(e.consume(R),x):b(R)}function E(R){return R===null||R===62?z(R):At(R)?(l=E,Z(R)):(e.consume(R),E)}function A(R){return R===null?n(R):R===63?(e.consume(R),k):At(R)?(l=A,Z(R)):(e.consume(R),A)}function k(R){return R===62?z(R):A(R)}function _(R){return Ba(R)?(e.consume(R),$):n(R)}function $(R){return R===45||Ao(R)?(e.consume(R),$):L(R)}function L(R){return At(R)?(l=L,Z(R)):ar(R)?(e.consume(R),L):z(R)}function O(R){return R===45||Ao(R)?(e.consume(R),O):R===47||R===62||Qo(R)?P(R):n(R)}function P(R){return R===47?(e.consume(R),z):R===58||R===95||Ba(R)?(e.consume(R),D):At(R)?(l=P,Z(R)):ar(R)?(e.consume(R),P):z(R)}function D(R){return R===45||R===46||R===58||R===95||Ao(R)?(e.consume(R),D):F(R)}function F(R){return R===61?(e.consume(R),U):At(R)?(l=F,Z(R)):ar(R)?(e.consume(R),F):P(R)}function U(R){return R===null||R===60||R===61||R===62||R===96?n(R):R===34||R===39?(e.consume(R),o=R,Y):At(R)?(l=U,Z(R)):ar(R)?(e.consume(R),U):(e.consume(R),o=void 0,te)}function Y(R){return R===o?(e.consume(R),V):R===null?n(R):At(R)?(l=Y,Z(R)):(e.consume(R),Y)}function V(R){return R===62||R===47||Qo(R)?P(R):n(R)}function te(R){return R===null||R===34||R===39||R===60||R===61||R===96?n(R):R===62||Qo(R)?P(R):(e.consume(R),te)}function Z(R){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(R),e.exit("lineEnding"),An(e,W,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function W(R){return e.enter("htmlTextData"),l(R)}function z(R){return R===62?(e.consume(R),e.exit("htmlTextData"),e.exit("htmlText"),t):n(R)}}const R2={name:"labelEnd",tokenize:KAe,resolveTo:qAe,resolveAll:GAe},WAe={tokenize:YAe},HAe={tokenize:XAe},VAe={tokenize:JAe};function GAe(e){let t=-1,n;for(;++t<e.length;)n=e[t][1],(n.type==="labelImage"||n.type==="labelLink"||n.type==="labelEnd")&&(e.splice(t+1,n.type==="labelImage"?4:2),n.type="data",t++);return e}function qAe(e,t){let n=e.length,r=0,o,a,i,l;for(;n--;)if(o=e[n][1],a){if(o.type==="link"||o.type==="labelLink"&&o._inactive)break;e[n][0]==="enter"&&o.type==="labelLink"&&(o._inactive=!0)}else if(i){if(e[n][0]==="enter"&&(o.type==="labelImage"||o.type==="labelLink")&&!o._balanced&&(a=n,o.type!=="labelLink")){r=2;break}}else o.type==="labelEnd"&&(i=n);const c={type:e[a][1].type==="labelLink"?"link":"image",start:Object.assign({},e[a][1].start),end:Object.assign({},e[e.length-1][1].end)},u={type:"label",start:Object.assign({},e[a][1].start),end:Object.assign({},e[i][1].end)},d={type:"labelText",start:Object.assign({},e[a+r+2][1].end),end:Object.assign({},e[i-2][1].start)};return l=[["enter",c,t],["enter",u,t]],l=Ho(l,e.slice(a+1,a+r+3)),l=Ho(l,[["enter",d,t]]),l=Ho(l,A2(t.parser.constructs.insideSpan.null,e.slice(a+r+4,i-3),t)),l=Ho(l,[["exit",d,t],e[i-2],e[i-1],["exit",u,t]]),l=Ho(l,e.slice(i+1)),l=Ho(l,[["exit",c,t]]),ni(e,a,e.length,l),e}function KAe(e,t,n){const r=this;let o=r.events.length,a,i;for(;o--;)if((r.events[o][1].type==="labelImage"||r.events[o][1].type==="labelLink")&&!r.events[o][1]._balanced){a=r.events[o][1];break}return l;function l(d){return a?a._inactive?u(d):(i=r.parser.defined.includes(_c(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(d),e.exit("labelMarker"),e.exit("labelEnd"),c):n(d)}function c(d){return d===40?e.attempt(WAe,t,i?t:u)(d):d===91?e.attempt(HAe,t,i?e.attempt(VAe,t,u):u)(d):i?t(d):u(d)}function u(d){return a._balanced=!0,n(d)}}function YAe(e,t,n){return r;function r(c){return e.enter("resource"),e.enter("resourceMarker"),e.consume(c),e.exit("resourceMarker"),Hd(e,o)}function o(c){return c===41?l(c):TN(e,a,n,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(c)}function a(c){return Qo(c)?Hd(e,i)(c):l(c)}function i(c){return c===34||c===39||c===40?AN(e,Hd(e,l),n,"resourceTitle","resourceTitleMarker","resourceTitleString")(c):l(c)}function l(c){return c===41?(e.enter("resourceMarker"),e.consume(c),e.exit("resourceMarker"),e.exit("resource"),t):n(c)}}function XAe(e,t,n){const r=this;return o;function o(i){return kN.call(r,e,a,n,"reference","referenceMarker","referenceString")(i)}function a(i){return r.parser.defined.includes(_c(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(i):n(i)}}function JAe(e,t,n){return r;function r(a){return e.enter("reference"),e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),o}function o(a){return a===93?(e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),e.exit("reference"),t):n(a)}}const QAe={name:"labelStartImage",tokenize:ZAe,resolveAll:R2.resolveAll};function ZAe(e,t,n){const r=this;return o;function o(l){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(l),e.exit("labelImageMarker"),a}function a(l){return l===91?(e.enter("labelMarker"),e.consume(l),e.exit("labelMarker"),e.exit("labelImage"),i):n(l)}function i(l){return l===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(l):t(l)}}const e_e={name:"labelStartLink",tokenize:t_e,resolveAll:R2.resolveAll};function t_e(e,t,n){const r=this;return o;function o(i){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(i),e.exit("labelMarker"),e.exit("labelLink"),a}function a(i){return i===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(i):t(i)}}const m0={name:"lineEnding",tokenize:n_e};function n_e(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),An(e,t,"linePrefix")}}const Hh={name:"thematicBreak",tokenize:r_e};function r_e(e,t,n){let r=0,o;return a;function a(c){return e.enter("thematicBreak"),o=c,i(c)}function i(c){return c===o?(e.enter("thematicBreakSequence"),l(c)):ar(c)?An(e,i,"whitespace")(c):r<3||c!==null&&!At(c)?n(c):(e.exit("thematicBreak"),t(c))}function l(c){return c===o?(e.consume(c),r++,l):(e.exit("thematicBreakSequence"),i(c))}}const so={name:"list",tokenize:i_e,continuation:{tokenize:s_e},exit:c_e},o_e={tokenize:u_e,partial:!0},a_e={tokenize:l_e,partial:!0};function i_e(e,t,n){const r=this,o=r.events[r.events.length-1];let a=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,i=0;return l;function l(m){const y=r.containerState.type||(m===42||m===43||m===45?"listUnordered":"listOrdered");if(y==="listUnordered"?!r.containerState.marker||m===r.containerState.marker:gw(m)){if(r.containerState.type||(r.containerState.type=y,e.enter(y,{_container:!0})),y==="listUnordered")return e.enter("listItemPrefix"),m===42||m===45?e.check(Hh,n,u)(m):u(m);if(!r.interrupt||m===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),c(m)}return n(m)}function c(m){return gw(m)&&++i<10?(e.consume(m),c):(!r.interrupt||i<2)&&(r.containerState.marker?m===r.containerState.marker:m===41||m===46)?(e.exit("listItemValue"),u(m)):n(m)}function u(m){return e.enter("listItemMarker"),e.consume(m),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||m,e.check(Qv,r.interrupt?n:d,e.attempt(o_e,h,f))}function d(m){return r.containerState.initialBlankLine=!0,a++,h(m)}function f(m){return ar(m)?(e.enter("listItemPrefixWhitespace"),e.consume(m),e.exit("listItemPrefixWhitespace"),h):n(m)}function h(m){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(m)}}function s_e(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Qv,o,a);function o(l){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,An(e,t,"listItemIndent",r.containerState.size+1)(l)}function a(l){return r.containerState.furtherBlankLines||!ar(l)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,i(l)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(a_e,t,i)(l))}function i(l){return r.containerState._closeFlow=!0,r.interrupt=void 0,An(e,e.attempt(so,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(l)}}function l_e(e,t,n){const r=this;return An(e,o,"listItemIndent",r.containerState.size+1);function o(a){const i=r.events[r.events.length-1];return i&&i[1].type==="listItemIndent"&&i[2].sliceSerialize(i[1],!0).length===r.containerState.size?t(a):n(a)}}function c_e(e){e.exit(this.containerState.type)}function u_e(e,t,n){const r=this;return An(e,o,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4+1);function o(a){const i=r.events[r.events.length-1];return!ar(a)&&i&&i[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const CP={name:"setextUnderline",tokenize:p_e,resolveTo:d_e};function d_e(e,t){let n=e.length,r,o,a;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(o=n)}else e[n][1].type==="content"&&e.splice(n,1),!a&&e[n][1].type==="definition"&&(a=n);const i={type:"setextHeading",start:Object.assign({},e[o][1].start),end:Object.assign({},e[e.length-1][1].end)};return e[o][1].type="setextHeadingText",a?(e.splice(o,0,["enter",i,t]),e.splice(a+1,0,["exit",e[r][1],t]),e[r][1].end=Object.assign({},e[a][1].end)):e[r][1]=i,e.push(["exit",i,t]),e}function p_e(e,t,n){const r=this;let o=r.events.length,a,i;for(;o--;)if(r.events[o][1].type!=="lineEnding"&&r.events[o][1].type!=="linePrefix"&&r.events[o][1].type!=="content"){i=r.events[o][1].type==="paragraph";break}return l;function l(d){return!r.parser.lazy[r.now().line]&&(r.interrupt||i)?(e.enter("setextHeadingLine"),e.enter("setextHeadingLineSequence"),a=d,c(d)):n(d)}function c(d){return d===a?(e.consume(d),c):(e.exit("setextHeadingLineSequence"),An(e,u,"lineSuffix")(d))}function u(d){return d===null||At(d)?(e.exit("setextHeadingLine"),t(d)):n(d)}}const f_e={tokenize:h_e};function h_e(e){const t=this,n=e.attempt(Qv,r,e.attempt(this.parser.constructs.flowInitial,o,An(e,e.attempt(this.parser.constructs.flow,o,e.attempt(SAe,o)),"linePrefix")));return n;function r(a){if(a===null){e.consume(a);return}return e.enter("lineEndingBlank"),e.consume(a),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(a){if(a===null){e.consume(a);return}return e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const m_e={resolveAll:RN()},g_e=_N("string"),v_e=_N("text");function _N(e){return{tokenize:t,resolveAll:RN(e==="text"?y_e:void 0)};function t(n){const r=this,o=this.parser.constructs[e],a=n.attempt(o,i,l);return i;function i(d){return u(d)?a(d):l(d)}function l(d){if(d===null){n.consume(d);return}return n.enter("data"),n.consume(d),c}function c(d){return u(d)?(n.exit("data"),a(d)):(n.consume(d),c)}function u(d){if(d===null)return!0;const f=o[d];let h=-1;if(f)for(;++h<f.length;){const m=f[h];if(!m.previous||m.previous.call(r,r.previous))return!0}return!1}}}function RN(e){return t;function t(n,r){let o=-1,a;for(;++o<=n.length;)a===void 0?n[o]&&n[o][1].type==="data"&&(a=o,o++):(!n[o]||n[o][1].type!=="data")&&(o!==a+2&&(n[a][1].end=n[o-1][1].end,n.splice(a+2,o-a-2),o=a+2),a=void 0);return e?e(n,r):n}}function y_e(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],o=t.sliceStream(r);let a=o.length,i=-1,l=0,c;for(;a--;){const u=o[a];if(typeof u=="string"){for(i=u.length;u.charCodeAt(i-1)===32;)l++,i--;if(i)break;i=-1}else if(u===-2)c=!0,l++;else if(u!==-1){a++;break}}if(l){const u={type:n===e.length||c||l<2?"lineSuffix":"hardBreakTrailing",start:{line:r.end.line,column:r.end.column-l,offset:r.end.offset-l,_index:r.start._index+a,_bufferIndex:a?i:r.start._bufferIndex+i},end:Object.assign({},r.end)};r.end=Object.assign({},u.start),r.start.offset===r.end.offset?Object.assign(r,u):(e.splice(n,0,["enter",u,t],["exit",u,t]),n+=2)}n++}return e}function b_e(e,t,n){let r=Object.assign(n?Object.assign({},n):{line:1,column:1,offset:0},{_index:0,_bufferIndex:-1});const o={},a=[];let i=[],l=[];const c={consume:w,enter:x,exit:E,attempt:_(A),check:_(k),interrupt:_(k,{interrupt:!0})},u={previous:null,code:null,containerState:{},events:[],parser:e,sliceStream:m,sliceSerialize:h,now:y,defineSkip:g,write:f};let d=t.tokenize.call(u,c);return t.resolveAll&&a.push(t),u;function f(P){return i=Ho(i,P),v(),i[i.length-1]!==null?[]:($(t,0),u.events=A2(a,u.events,u),u.events)}function h(P,D){return S_e(m(P),D)}function m(P){return w_e(i,P)}function y(){return Object.assign({},r)}function g(P){o[P.line]=P.column,O()}function v(){let P;for(;r._index<i.length;){const D=i[r._index];if(typeof D=="string")for(P=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===P&&r._bufferIndex<D.length;)b(D.charCodeAt(r._bufferIndex));else b(D)}}function b(P){d=d(P)}function w(P){At(P)?(r.line++,r.column=1,r.offset+=P===-3?2:1,O()):P!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===i[r._index].length&&(r._bufferIndex=-1,r._index++)),u.previous=P}function x(P,D){const F=D||{};return F.type=P,F.start=y(),u.events.push(["enter",F,u]),l.push(F),F}function E(P){const D=l.pop();return D.end=y(),u.events.push(["exit",D,u]),D}function A(P,D){$(P,D.from)}function k(P,D){D.restore()}function _(P,D){return F;function F(U,Y,V){let te,Z,W,z;return Array.isArray(U)?M(U):"tokenize"in U?M([U]):R(U);function R(ce){return Ce;function Ce(xe){const Ee=xe!==null&&ce[xe],tt=xe!==null&&ce.null,me=[...Array.isArray(Ee)?Ee:Ee?[Ee]:[],...Array.isArray(tt)?tt:tt?[tt]:[]];return M(me)(xe)}}function M(ce){return te=ce,Z=0,ce.length===0?V:ee(ce[Z])}function ee(ce){return Ce;function Ce(xe){return z=L(),W=ce,ce.partial||(u.currentConstruct=ce),ce.name&&u.parser.constructs.disable.null.includes(ce.name)?Se():ce.tokenize.call(D?Object.assign(Object.create(u),D):u,c,re,Se)(xe)}}function re(ce){return P(W,z),Y}function Se(ce){return z.restore(),++Z<te.length?ee(te[Z]):V}}}function $(P,D){P.resolveAll&&!a.includes(P)&&a.push(P),P.resolve&&ni(u.events,D,u.events.length-D,P.resolve(u.events.slice(D),u)),P.resolveTo&&(u.events=P.resolveTo(u.events,u))}function L(){const P=y(),D=u.previous,F=u.currentConstruct,U=u.events.length,Y=Array.from(l);return{restore:V,from:U};function V(){r=P,u.previous=D,u.currentConstruct=F,u.events.length=U,l=Y,O()}}function O(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function w_e(e,t){const n=t.start._index,r=t.start._bufferIndex,o=t.end._index,a=t.end._bufferIndex;let i;return n===o?i=[e[n].slice(r,a)]:(i=e.slice(n,o),r>-1&&(i[0]=i[0].slice(r)),a>0&&i.push(e[o].slice(0,a))),i}function S_e(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const a=e[n];let i;if(typeof a=="string")i=a;else switch(a){case-5:{i="\r";break}case-4:{i=`
|
|
368
|
+
`;break}case-3:{i=`\r
|
|
369
|
+
`;break}case-2:{i=t?" ":" ";break}case-1:{if(!t&&o)continue;i=" ";break}default:i=String.fromCharCode(a)}o=a===-2,r.push(i)}return r.join("")}const x_e={[42]:so,[43]:so,[45]:so,[48]:so,[49]:so,[50]:so,[51]:so,[52]:so,[53]:so,[54]:so,[55]:so,[56]:so,[57]:so,[62]:SN},C_e={[91]:kAe},E_e={[-2]:h0,[-1]:h0,[32]:h0},T_e={[35]:$Ae,[42]:Hh,[45]:[CP,Hh],[60]:MAe,[61]:CP,[95]:Hh,[96]:SP,[126]:SP},k_e={[38]:CN,[92]:xN},A_e={[-5]:m0,[-4]:m0,[-3]:m0,[33]:QAe,[38]:CN,[42]:yw,[60]:[oAe,jAe],[91]:e_e,[92]:[PAe,xN],[93]:R2,[95]:yw,[96]:gAe},__e={null:[yw,m_e]},R_e={null:[42,95]},P_e={null:[]},I_e=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:R_e,contentInitial:C_e,disable:P_e,document:x_e,flow:T_e,flowInitial:E_e,insideSpan:__e,string:k_e,text:A_e},Symbol.toStringTag,{value:"Module"}));function $_e(e={}){const t=Wke([I_e].concat(e.extensions||[])),n={defined:[],lazy:{},constructs:t,content:r(Jke),document:r(Zke),flow:r(f_e),string:r(g_e),text:r(v_e)};return n;function r(o){return a;function a(i){return b_e(n,o,i)}}}const EP=/[\0\t\n\r]/g;function O_e(){let e=1,t="",n=!0,r;return o;function o(a,i,l){const c=[];let u,d,f,h,m;for(a=t+a.toString(i),f=0,t="",n&&(a.charCodeAt(0)===65279&&f++,n=void 0);f<a.length;){if(EP.lastIndex=f,u=EP.exec(a),h=u&&u.index!==void 0?u.index:a.length,m=a.charCodeAt(h),!u){t=a.slice(f);break}if(m===10&&f===h&&r)c.push(-3),r=void 0;else switch(r&&(c.push(-5),r=void 0),f<h&&(c.push(a.slice(f,h)),e+=h-f),m){case 0:{c.push(65533),e++;break}case 9:{for(d=Math.ceil(e/4)*4,c.push(-2);e++<d;)c.push(-1);break}case 10:{c.push(-4),e=1;break}default:r=!0,e=1}f=h+1}return l&&(r&&c.push(-5),t&&c.push(t),c.push(null)),c}}function L_e(e){for(;!EN(e););return e}function PN(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCharCode(n)}const N_e=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function M_e(e){return e.replace(N_e,D_e)}function D_e(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),a=o===120||o===88;return PN(n.slice(a?2:1),a?16:10)}return _2(n)||e}const bw={}.hasOwnProperty,B_e=function(e,t,n){return typeof t!="string"&&(n=t,t=void 0),F_e(n)(L_e($_e(n).document().write(O_e()(e,t,!0))))};function F_e(e={}){const t=IN({transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:c(rt),autolinkProtocol:D,autolinkEmail:D,atxHeading:c(Ke),blockQuote:c(Ge),characterEscape:D,characterReference:D,codeFenced:c(qe),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:c(qe,u),codeText:c(Be,u),codeTextData:D,data:D,codeFlowValue:D,definition:c(he),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:c(Et),hardBreakEscape:c(ct),hardBreakTrailing:c(ct),htmlFlow:c(Rt,u),htmlFlowData:D,htmlText:c(Rt,u),htmlTextData:D,image:c(dt),label:u,link:c(rt),listItem:c(xt),listItemValue:g,listOrdered:c(Nt,y),listUnordered:c(Nt),paragraph:c(pe),reference:ce,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:c(Ke),strong:c(Te),thematicBreak:c(De)},exit:{atxHeading:f(),atxHeadingSequence:$,autolink:f(),autolinkEmail:me,autolinkProtocol:tt,blockQuote:f(),characterEscapeValue:F,characterReferenceMarkerHexadecimal:xe,characterReferenceMarkerNumeric:xe,characterReferenceValue:Ee,codeFenced:f(x),codeFencedFence:w,codeFencedFenceInfo:v,codeFencedFenceMeta:b,codeFlowValue:F,codeIndented:f(E),codeText:f(Z),codeTextData:F,data:F,definition:f(),definitionDestinationString:_,definitionLabelString:A,definitionTitleString:k,emphasis:f(),hardBreakEscape:f(Y),hardBreakTrailing:f(Y),htmlFlow:f(V),htmlFlowData:F,htmlText:f(te),htmlTextData:F,image:f(z),label:M,labelText:R,lineEnding:U,link:f(W),listItem:f(),listOrdered:f(),listUnordered:f(),paragraph:f(),referenceString:Ce,resourceDestinationString:ee,resourceTitleString:re,resource:Se,setextHeading:f(P),setextHeadingLineSequence:O,setextHeadingText:L,strong:f(),thematicBreak:f()}},e.mdastExtensions||[]),n={};return r;function r(q){let K={type:"root",children:[]};const se=[K],be=[],Ae=[],mt={stack:se,tokenStack:be,config:t,enter:d,exit:h,buffer:u,resume:m,setData:a,getData:i};let et=-1;for(;++et<q.length;)if(q[et][1].type==="listOrdered"||q[et][1].type==="listUnordered")if(q[et][0]==="enter")Ae.push(et);else{const ht=Ae.pop();et=o(q,ht,et)}for(et=-1;++et<q.length;){const ht=t[q[et][0]];bw.call(ht,q[et][1].type)&&ht[q[et][1].type].call(Object.assign({sliceSerialize:q[et][2].sliceSerialize},mt),q[et][1])}if(be.length>0){const ht=be[be.length-1];(ht[1]||TP).call(mt,void 0,ht[0])}for(K.position={start:l(q.length>0?q[0][1].start:{line:1,column:1,offset:0}),end:l(q.length>0?q[q.length-2][1].end:{line:1,column:1,offset:0})},et=-1;++et<t.transforms.length;)K=t.transforms[et](K)||K;return K}function o(q,K,se){let be=K-1,Ae=-1,mt=!1,et,ht,Xt,Mn;for(;++be<=se;){const pt=q[be];if(pt[1].type==="listUnordered"||pt[1].type==="listOrdered"||pt[1].type==="blockQuote"?(pt[0]==="enter"?Ae++:Ae--,Mn=void 0):pt[1].type==="lineEndingBlank"?pt[0]==="enter"&&(et&&!Mn&&!Ae&&!Xt&&(Xt=be),Mn=void 0):pt[1].type==="linePrefix"||pt[1].type==="listItemValue"||pt[1].type==="listItemMarker"||pt[1].type==="listItemPrefix"||pt[1].type==="listItemPrefixWhitespace"||(Mn=void 0),!Ae&&pt[0]==="enter"&&pt[1].type==="listItemPrefix"||Ae===-1&&pt[0]==="exit"&&(pt[1].type==="listUnordered"||pt[1].type==="listOrdered")){if(et){let pn=be;for(ht=void 0;pn--;){const Vt=q[pn];if(Vt[1].type==="lineEnding"||Vt[1].type==="lineEndingBlank"){if(Vt[0]==="exit")continue;ht&&(q[ht][1].type="lineEndingBlank",mt=!0),Vt[1].type="lineEnding",ht=pn}else if(!(Vt[1].type==="linePrefix"||Vt[1].type==="blockQuotePrefix"||Vt[1].type==="blockQuotePrefixWhitespace"||Vt[1].type==="blockQuoteMarker"||Vt[1].type==="listItemIndent"))break}Xt&&(!ht||Xt<ht)&&(et._spread=!0),et.end=Object.assign({},ht?q[ht][1].start:pt[1].end),q.splice(ht||be,0,["exit",et,pt[2]]),be++,se++}pt[1].type==="listItemPrefix"&&(et={type:"listItem",_spread:!1,start:Object.assign({},pt[1].start)},q.splice(be,0,["enter",et,pt[2]]),be++,se++,Xt=void 0,Mn=!0)}}return q[K][1]._spread=mt,se}function a(q,K){n[q]=K}function i(q){return n[q]}function l(q){return{line:q.line,column:q.column,offset:q.offset}}function c(q,K){return se;function se(be){d.call(this,q(be),be),K&&K.call(this,be)}}function u(){this.stack.push({type:"fragment",children:[]})}function d(q,K,se){return this.stack[this.stack.length-1].children.push(q),this.stack.push(q),this.tokenStack.push([K,se]),q.position={start:l(K.start)},q}function f(q){return K;function K(se){q&&q.call(this,se),h.call(this,se)}}function h(q,K){const se=this.stack.pop(),be=this.tokenStack.pop();if(be)be[0].type!==q.type&&(K?K.call(this,q,be[0]):(be[1]||TP).call(this,q,be[0]));else throw new Error("Cannot close `"+q.type+"` ("+Wd({start:q.start,end:q.end})+"): it’s not open");return se.position.end=l(q.end),se}function m(){return Uke(this.stack.pop())}function y(){a("expectingFirstListItemValue",!0)}function g(q){if(i("expectingFirstListItemValue")){const K=this.stack[this.stack.length-2];K.start=Number.parseInt(this.sliceSerialize(q),10),a("expectingFirstListItemValue")}}function v(){const q=this.resume(),K=this.stack[this.stack.length-1];K.lang=q}function b(){const q=this.resume(),K=this.stack[this.stack.length-1];K.meta=q}function w(){i("flowCodeInside")||(this.buffer(),a("flowCodeInside",!0))}function x(){const q=this.resume(),K=this.stack[this.stack.length-1];K.value=q.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),a("flowCodeInside")}function E(){const q=this.resume(),K=this.stack[this.stack.length-1];K.value=q.replace(/(\r?\n|\r)$/g,"")}function A(q){const K=this.resume(),se=this.stack[this.stack.length-1];se.label=K,se.identifier=_c(this.sliceSerialize(q)).toLowerCase()}function k(){const q=this.resume(),K=this.stack[this.stack.length-1];K.title=q}function _(){const q=this.resume(),K=this.stack[this.stack.length-1];K.url=q}function $(q){const K=this.stack[this.stack.length-1];if(!K.depth){const se=this.sliceSerialize(q).length;K.depth=se}}function L(){a("setextHeadingSlurpLineEnding",!0)}function O(q){const K=this.stack[this.stack.length-1];K.depth=this.sliceSerialize(q).charCodeAt(0)===61?1:2}function P(){a("setextHeadingSlurpLineEnding")}function D(q){const K=this.stack[this.stack.length-1];let se=K.children[K.children.length-1];(!se||se.type!=="text")&&(se=Xe(),se.position={start:l(q.start)},K.children.push(se)),this.stack.push(se)}function F(q){const K=this.stack.pop();K.value+=this.sliceSerialize(q),K.position.end=l(q.end)}function U(q){const K=this.stack[this.stack.length-1];if(i("atHardBreak")){const se=K.children[K.children.length-1];se.position.end=l(q.end),a("atHardBreak");return}!i("setextHeadingSlurpLineEnding")&&t.canContainEols.includes(K.type)&&(D.call(this,q),F.call(this,q))}function Y(){a("atHardBreak",!0)}function V(){const q=this.resume(),K=this.stack[this.stack.length-1];K.value=q}function te(){const q=this.resume(),K=this.stack[this.stack.length-1];K.value=q}function Z(){const q=this.resume(),K=this.stack[this.stack.length-1];K.value=q}function W(){const q=this.stack[this.stack.length-1];i("inReference")?(q.type+="Reference",q.referenceType=i("referenceType")||"shortcut",delete q.url,delete q.title):(delete q.identifier,delete q.label),a("referenceType")}function z(){const q=this.stack[this.stack.length-1];i("inReference")?(q.type+="Reference",q.referenceType=i("referenceType")||"shortcut",delete q.url,delete q.title):(delete q.identifier,delete q.label),a("referenceType")}function R(q){const K=this.stack[this.stack.length-2],se=this.sliceSerialize(q);K.label=M_e(se),K.identifier=_c(se).toLowerCase()}function M(){const q=this.stack[this.stack.length-1],K=this.resume(),se=this.stack[this.stack.length-1];a("inReference",!0),se.type==="link"?se.children=q.children:se.alt=K}function ee(){const q=this.resume(),K=this.stack[this.stack.length-1];K.url=q}function re(){const q=this.resume(),K=this.stack[this.stack.length-1];K.title=q}function Se(){a("inReference")}function ce(){a("referenceType","collapsed")}function Ce(q){const K=this.resume(),se=this.stack[this.stack.length-1];se.label=K,se.identifier=_c(this.sliceSerialize(q)).toLowerCase(),a("referenceType","full")}function xe(q){a("characterReferenceType",q.type)}function Ee(q){const K=this.sliceSerialize(q),se=i("characterReferenceType");let be;se?(be=PN(K,se==="characterReferenceMarkerNumeric"?10:16),a("characterReferenceType")):be=_2(K);const Ae=this.stack.pop();Ae.value+=be,Ae.position.end=l(q.end)}function tt(q){F.call(this,q);const K=this.stack[this.stack.length-1];K.url=this.sliceSerialize(q)}function me(q){F.call(this,q);const K=this.stack[this.stack.length-1];K.url="mailto:"+this.sliceSerialize(q)}function Ge(){return{type:"blockquote",children:[]}}function qe(){return{type:"code",lang:null,meta:null,value:""}}function Be(){return{type:"inlineCode",value:""}}function he(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Et(){return{type:"emphasis",children:[]}}function Ke(){return{type:"heading",depth:void 0,children:[]}}function ct(){return{type:"break"}}function Rt(){return{type:"html",value:""}}function dt(){return{type:"image",title:null,url:"",alt:null}}function rt(){return{type:"link",title:null,url:"",children:[]}}function Nt(q){return{type:"list",ordered:q.type==="listOrdered",start:null,spread:q._spread,children:[]}}function xt(q){return{type:"listItem",spread:q._spread,checked:null,children:[]}}function pe(){return{type:"paragraph",children:[]}}function Te(){return{type:"strong",children:[]}}function Xe(){return{type:"text",value:""}}function De(){return{type:"thematicBreak"}}}function IN(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?IN(e,r):z_e(e,r)}return e}function z_e(e,t){let n;for(n in t)if(bw.call(t,n)){const r=n==="canContainEols"||n==="transforms",a=(bw.call(e,n)?e[n]:void 0)||(e[n]=r?[]:{}),i=t[n];i&&(r?e[n]=[...a,...i]:Object.assign(a,i))}}function TP(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Wd({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Wd({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Wd({start:t.start,end:t.end})+") is still open")}function j_e(e){Object.assign(this,{Parser:n=>{const r=this.data("settings");return B_e(n,Object.assign({},r,e,{extensions:this.data("micromarkExtensions")||[],mdastExtensions:this.data("fromMarkdownExtensions")||[]}))}})}var vr=function(e,t,n){var r={type:String(e)};return n==null&&(typeof t=="string"||Array.isArray(t))?n=t:Object.assign(r,t),Array.isArray(n)?r.children=n:n!=null&&(r.value=String(n)),r};const Vh={}.hasOwnProperty;function U_e(e,t){const n=t.data||{};return"value"in t&&!(Vh.call(n,"hName")||Vh.call(n,"hProperties")||Vh.call(n,"hChildren"))?e.augment(t,vr("text",t.value)):e(t,"div",qr(e,t))}function $N(e,t,n){const r=t&&t.type;let o;if(!r)throw new Error("Expected node, got `"+t+"`");return Vh.call(e.handlers,r)?o=e.handlers[r]:e.passThrough&&e.passThrough.includes(r)?o=W_e:o=e.unknownHandler,(typeof o=="function"?o:U_e)(e,t,n)}function W_e(e,t){return"children"in t?{...t,children:qr(e,t)}:t}function qr(e,t){const n=[];if("children"in t){const r=t.children;let o=-1;for(;++o<r.length;){const a=$N(e,r[o],t);if(a){if(o&&r[o-1].type==="break"&&(!Array.isArray(a)&&a.type==="text"&&(a.value=a.value.replace(/^\s+/,"")),!Array.isArray(a)&&a.type==="element")){const i=a.children[0];i&&i.type==="text"&&(i.value=i.value.replace(/^\s+/,""))}Array.isArray(a)?n.push(...a):n.push(a)}}}return n}const ON=function(e){if(e==null)return q_e;if(typeof e=="string")return G_e(e);if(typeof e=="object")return Array.isArray(e)?H_e(e):V_e(e);if(typeof e=="function")return Zv(e);throw new Error("Expected function, string, or object as test")};function H_e(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=ON(e[n]);return Zv(r);function r(...o){let a=-1;for(;++a<t.length;)if(t[a].call(this,...o))return!0;return!1}}function V_e(e){return Zv(t);function t(n){let r;for(r in e)if(n[r]!==e[r])return!1;return!0}}function G_e(e){return Zv(t);function t(n){return n&&n.type===e}}function Zv(e){return t;function t(...n){return Boolean(e.call(this,...n))}}function q_e(){return!0}const K_e=!0,Y_e="skip",kP=!1,X_e=function(e,t,n,r){typeof t=="function"&&typeof n!="function"&&(r=n,n=t,t=null);const o=ON(t),a=r?-1:1;i(e,null,[])();function i(l,c,u){const d=typeof l=="object"&&l!==null?l:{};let f;return typeof d.type=="string"&&(f=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0,Object.defineProperty(h,"name",{value:"node ("+(d.type+(f?"<"+f+">":""))+")"})),h;function h(){let m=[],y,g,v;if((!t||o(l,c,u[u.length-1]||null))&&(m=J_e(n(l,u)),m[0]===kP))return m;if(l.children&&m[0]!==Y_e)for(g=(r?l.children.length:-1)+a,v=u.concat(l);g>-1&&g<l.children.length;){if(y=i(l.children[g],g,v)(),y[0]===kP)return y;g=typeof y[1]=="number"?y[1]:g+a}return m}}};function J_e(e){return Array.isArray(e)?e:typeof e=="number"?[K_e,e]:[e]}const P2=function(e,t,n,r){typeof t=="function"&&typeof n!="function"&&(r=n,n=t,t=null),X_e(e,t,o,r);function o(a,i){const l=i[i.length-1];return n(a,l?l.children.indexOf(a):null,l)}},LN=MN("start"),NN=MN("end");function MN(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};return{line:r.line||null,column:r.column||null,offset:r.offset>-1?r.offset:null}}}function Q_e(e){return!e||!e.position||!e.position.start||!e.position.start.line||!e.position.start.column||!e.position.end||!e.position.end.line||!e.position.end.column}const AP={}.hasOwnProperty;function Z_e(e){const t=Object.create(null);if(!e||!e.type)throw new Error("mdast-util-definitions expected node");return P2(e,"definition",r=>{const o=_P(r.identifier);o&&!AP.call(t,o)&&(t[o]=r)}),n;function n(r){const o=_P(r);return o&&AP.call(t,o)?t[o]:null}}function _P(e){return String(e||"").toUpperCase()}function xu(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const a=e.charCodeAt(n);let i="";if(a===37&&Ao(e.charCodeAt(n+1))&&Ao(e.charCodeAt(n+2)))o=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(i=String.fromCharCode(a));else if(a>55295&&a<57344){const l=e.charCodeAt(n+1);a<56320&&l>56319&&l<57344?(i=String.fromCharCode(a,l),o=1):i="�"}else i=String.fromCharCode(a);i&&(t.push(e.slice(r,n),encodeURIComponent(i)),r=n+o+1,i=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function bi(e,t){const n=[];let r=-1;for(t&&n.push(vr("text",`
|
|
370
|
+
`));++r<e.length;)r&&n.push(vr("text",`
|
|
371
|
+
`)),n.push(e[r]);return t&&e.length>0&&n.push(vr("text",`
|
|
372
|
+
`)),n}function eRe(e){let t=-1;const n=[];for(;++t<e.footnoteOrder.length;){const r=e.footnoteById[e.footnoteOrder[t].toUpperCase()];if(!r)continue;const o=qr(e,r),a=String(r.identifier),i=xu(a.toLowerCase());let l=0;const c=[];for(;++l<=e.footnoteCounts[a];){const f={type:"element",tagName:"a",properties:{href:"#"+e.clobberPrefix+"fnref-"+i+(l>1?"-"+l:""),dataFootnoteBackref:!0,className:["data-footnote-backref"],ariaLabel:e.footnoteBackLabel},children:[{type:"text",value:"↩"}]};l>1&&f.children.push({type:"element",tagName:"sup",children:[{type:"text",value:String(l)}]}),c.length>0&&c.push({type:"text",value:" "}),c.push(f)}const u=o[o.length-1];if(u&&u.type==="element"&&u.tagName==="p"){const f=u.children[u.children.length-1];f&&f.type==="text"?f.value+=" ":u.children.push({type:"text",value:" "}),u.children.push(...c)}else o.push(...c);const d={type:"element",tagName:"li",properties:{id:e.clobberPrefix+"fn-"+i},children:bi(o,!0)};r.position&&(d.position=r.position),n.push(d)}return n.length===0?null:{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:e.footnoteLabelTagName,properties:{...JSON.parse(JSON.stringify(e.footnoteLabelProperties)),id:"footnote-label"},children:[vr("text",e.footnoteLabel)]},{type:"text",value:`
|
|
373
|
+
`},{type:"element",tagName:"ol",properties:{},children:bi(n,!0)},{type:"text",value:`
|
|
374
|
+
`}]}}function tRe(e,t){return e(t,"blockquote",bi(qr(e,t),!0))}function nRe(e,t){return[e(t,"br"),vr("text",`
|
|
375
|
+
`)]}function rRe(e,t){const n=t.value?t.value+`
|
|
376
|
+
`:"",r=t.lang&&t.lang.match(/^[^ \t]+(?=[ \t]|$)/),o={};r&&(o.className=["language-"+r]);const a=e(t,"code",o,[vr("text",n)]);return t.meta&&(a.data={meta:t.meta}),e(t.position,"pre",[a])}function oRe(e,t){return e(t,"del",qr(e,t))}function aRe(e,t){return e(t,"em",qr(e,t))}function DN(e,t){const n=String(t.identifier),r=xu(n.toLowerCase()),o=e.footnoteOrder.indexOf(n);let a;o===-1?(e.footnoteOrder.push(n),e.footnoteCounts[n]=1,a=e.footnoteOrder.length):(e.footnoteCounts[n]++,a=o+1);const i=e.footnoteCounts[n];return e(t,"sup",[e(t.position,"a",{href:"#"+e.clobberPrefix+"fn-"+r,id:e.clobberPrefix+"fnref-"+r+(i>1?"-"+i:""),dataFootnoteRef:!0,ariaDescribedBy:"footnote-label"},[vr("text",String(a))])])}function iRe(e,t){const n=e.footnoteById;let r=1;for(;r in n;)r++;const o=String(r);return n[o]={type:"footnoteDefinition",identifier:o,children:[{type:"paragraph",children:t.children}],position:t.position},DN(e,{type:"footnoteReference",identifier:o,position:t.position})}function sRe(e,t){return e(t,"h"+t.depth,qr(e,t))}function lRe(e,t){return e.dangerous?e.augment(t,vr("raw",t.value)):null}function BN(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return vr("text","!["+t.alt+r);const o=qr(e,t),a=o[0];a&&a.type==="text"?a.value="["+a.value:o.unshift(vr("text","["));const i=o[o.length-1];return i&&i.type==="text"?i.value+=r:o.push(vr("text",r)),o}function cRe(e,t){const n=e.definition(t.identifier);if(!n)return BN(e,t);const r={src:xu(n.url||""),alt:t.alt};return n.title!==null&&n.title!==void 0&&(r.title=n.title),e(t,"img",r)}function uRe(e,t){const n={src:xu(t.url),alt:t.alt};return t.title!==null&&t.title!==void 0&&(n.title=t.title),e(t,"img",n)}function dRe(e,t){return e(t,"code",[vr("text",t.value.replace(/\r?\n|\r/g," "))])}function pRe(e,t){const n=e.definition(t.identifier);if(!n)return BN(e,t);const r={href:xu(n.url||"")};return n.title!==null&&n.title!==void 0&&(r.title=n.title),e(t,"a",r,qr(e,t))}function fRe(e,t){const n={href:xu(t.url)};return t.title!==null&&t.title!==void 0&&(n.title=t.title),e(t,"a",n,qr(e,t))}function hRe(e,t,n){const r=qr(e,t),o=n?mRe(n):FN(t),a={},i=[];if(typeof t.checked=="boolean"){let u;r[0]&&r[0].type==="element"&&r[0].tagName==="p"?u=r[0]:(u=e(null,"p",[]),r.unshift(u)),u.children.length>0&&u.children.unshift(vr("text"," ")),u.children.unshift(e(null,"input",{type:"checkbox",checked:t.checked,disabled:!0})),a.className=["task-list-item"]}let l=-1;for(;++l<r.length;){const u=r[l];(o||l!==0||u.type!=="element"||u.tagName!=="p")&&i.push(vr("text",`
|
|
377
|
+
`)),u.type==="element"&&u.tagName==="p"&&!o?i.push(...u.children):i.push(u)}const c=r[r.length-1];return c&&(o||!("tagName"in c)||c.tagName!=="p")&&i.push(vr("text",`
|
|
378
|
+
`)),e(t,"li",a,i)}function mRe(e){let t=e.spread;const n=e.children;let r=-1;for(;!t&&++r<n.length;)t=FN(n[r]);return Boolean(t)}function FN(e){const t=e.spread;return t??e.children.length>1}function gRe(e,t){const n={},r=t.ordered?"ol":"ul",o=qr(e,t);let a=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++a<o.length;){const i=o[a];if(i.type==="element"&&i.tagName==="li"&&i.properties&&Array.isArray(i.properties.className)&&i.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}return e(t,r,n,bi(o,!0))}function vRe(e,t){return e(t,"p",qr(e,t))}function yRe(e,t){return e.augment(t,vr("root",bi(qr(e,t))))}function bRe(e,t){return e(t,"strong",qr(e,t))}function wRe(e,t){const n=t.children;let r=-1;const o=t.align||[],a=[];for(;++r<n.length;){const i=n[r].children,l=r===0?"th":"td",c=[];let u=-1;const d=t.align?o.length:i.length;for(;++u<d;){const f=i[u];c.push(e(f,l,{align:o[u]},f?qr(e,f):[]))}a[r]=e(n[r],"tr",bi(c,!0))}return e(t,"table",bi([e(a[0].position,"thead",bi([a[0]],!0))].concat(a[1]?e({start:LN(a[1]),end:NN(a[a.length-1])},"tbody",bi(a.slice(1),!0)):[]),!0))}const RP=9,PP=32;function SRe(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const a=[];for(;r;)a.push(IP(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return a.push(IP(t.slice(o),o>0,!1)),a.join("")}function IP(e,t,n){let r=0,o=e.length;if(t){let a=e.codePointAt(r);for(;a===RP||a===PP;)r++,a=e.codePointAt(r)}if(n){let a=e.codePointAt(o-1);for(;a===RP||a===PP;)o--,a=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}function xRe(e,t){return e.augment(t,vr("text",SRe(String(t.value))))}function CRe(e,t){return e(t,"hr")}const ERe={blockquote:tRe,break:nRe,code:rRe,delete:oRe,emphasis:aRe,footnoteReference:DN,footnote:iRe,heading:sRe,html:lRe,imageReference:cRe,image:uRe,inlineCode:dRe,linkReference:pRe,link:fRe,listItem:hRe,list:gRe,paragraph:vRe,root:yRe,strong:bRe,table:wRe,text:xRe,thematicBreak:CRe,toml:gh,yaml:gh,definition:gh,footnoteDefinition:gh};function gh(){return null}const TRe={}.hasOwnProperty;function kRe(e,t){const n=t||{},r=n.allowDangerousHtml||!1,o={};return i.dangerous=r,i.clobberPrefix=n.clobberPrefix===void 0||n.clobberPrefix===null?"user-content-":n.clobberPrefix,i.footnoteLabel=n.footnoteLabel||"Footnotes",i.footnoteLabelTagName=n.footnoteLabelTagName||"h2",i.footnoteLabelProperties=n.footnoteLabelProperties||{className:["sr-only"]},i.footnoteBackLabel=n.footnoteBackLabel||"Back to content",i.definition=Z_e(e),i.footnoteById=o,i.footnoteOrder=[],i.footnoteCounts={},i.augment=a,i.handlers={...ERe,...n.handlers},i.unknownHandler=n.unknownHandler,i.passThrough=n.passThrough,P2(e,"footnoteDefinition",l=>{const c=String(l.identifier).toUpperCase();TRe.call(o,c)||(o[c]=l)}),i;function a(l,c){if(l&&"data"in l&&l.data){const u=l.data;u.hName&&(c.type!=="element"&&(c={type:"element",tagName:"",properties:{},children:[]}),c.tagName=u.hName),c.type==="element"&&u.hProperties&&(c.properties={...c.properties,...u.hProperties}),"children"in c&&c.children&&u.hChildren&&(c.children=u.hChildren)}if(l){const u="type"in l?l:{position:l};Q_e(u)||(c.position={start:LN(u),end:NN(u)})}return c}function i(l,c,u,d){return Array.isArray(u)&&(d=u,u={}),a(l,{type:"element",tagName:c,properties:u||{},children:d||[]})}}function zN(e,t){const n=kRe(e,t),r=$N(n,e,null),o=eRe(n);return o&&r.children.push(vr("text",`
|
|
379
|
+
`),o),Array.isArray(r)?{type:"root",children:r}:r}const ARe=function(e,t){return e&&"run"in e?RRe(e,t):PRe(e||t)},_Re=ARe;function RRe(e,t){return(n,r,o)=>{e.run(zN(n,t),r,a=>{o(a)})}}function PRe(e){return t=>zN(t,e)}class uf{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}uf.prototype.property={};uf.prototype.normal={};uf.prototype.space=null;function jN(e,t){const n={},r={};let o=-1;for(;++o<e.length;)Object.assign(n,e[o].property),Object.assign(r,e[o].normal);return new uf(n,r,t)}function ww(e){return e.toLowerCase()}class da{constructor(t,n){this.property=t,this.attribute=n}}da.prototype.space=null;da.prototype.boolean=!1;da.prototype.booleanish=!1;da.prototype.overloadedBoolean=!1;da.prototype.number=!1;da.prototype.commaSeparated=!1;da.prototype.spaceSeparated=!1;da.prototype.commaOrSpaceSeparated=!1;da.prototype.mustUseProperty=!1;da.prototype.defined=!1;let IRe=0;const Mt=Ll(),rr=Ll(),UN=Ll(),_e=Ll(),On=Ll(),Rc=Ll(),So=Ll();function Ll(){return 2**++IRe}const Sw=Object.freeze(Object.defineProperty({__proto__:null,boolean:Mt,booleanish:rr,commaOrSpaceSeparated:So,commaSeparated:Rc,number:_e,overloadedBoolean:UN,spaceSeparated:On},Symbol.toStringTag,{value:"Module"})),g0=Object.keys(Sw);class I2 extends da{constructor(t,n,r,o){let a=-1;if(super(t,n),$P(this,"space",o),typeof r=="number")for(;++a<g0.length;){const i=g0[a];$P(this,g0[a],(r&Sw[i])===Sw[i])}}}I2.prototype.defined=!0;function $P(e,t,n){n&&(e[t]=n)}const $Re={}.hasOwnProperty;function Cu(e){const t={},n={};let r;for(r in e.properties)if($Re.call(e.properties,r)){const o=e.properties[r],a=new I2(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[ww(r)]=r,n[ww(a.attribute)]=r}return new uf(t,n,e.space)}const WN=Cu({space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()},properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),HN=Cu({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function VN(e,t){return t in e?e[t]:t}function GN(e,t){return VN(e,t.toLowerCase())}const qN=Cu({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:GN,properties:{xmlns:null,xmlnsXLink:null}}),KN=Cu({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:rr,ariaAutoComplete:null,ariaBusy:rr,ariaChecked:rr,ariaColCount:_e,ariaColIndex:_e,ariaColSpan:_e,ariaControls:On,ariaCurrent:null,ariaDescribedBy:On,ariaDetails:null,ariaDisabled:rr,ariaDropEffect:On,ariaErrorMessage:null,ariaExpanded:rr,ariaFlowTo:On,ariaGrabbed:rr,ariaHasPopup:null,ariaHidden:rr,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:On,ariaLevel:_e,ariaLive:null,ariaModal:rr,ariaMultiLine:rr,ariaMultiSelectable:rr,ariaOrientation:null,ariaOwns:On,ariaPlaceholder:null,ariaPosInSet:_e,ariaPressed:rr,ariaReadOnly:rr,ariaRelevant:null,ariaRequired:rr,ariaRoleDescription:On,ariaRowCount:_e,ariaRowIndex:_e,ariaRowSpan:_e,ariaSelected:rr,ariaSetSize:_e,ariaSort:null,ariaValueMax:_e,ariaValueMin:_e,ariaValueNow:_e,ariaValueText:null,role:null}}),ORe=Cu({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:GN,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Rc,acceptCharset:On,accessKey:On,action:null,allow:null,allowFullScreen:Mt,allowPaymentRequest:Mt,allowUserMedia:Mt,alt:null,as:null,async:Mt,autoCapitalize:null,autoComplete:On,autoFocus:Mt,autoPlay:Mt,capture:Mt,charSet:null,checked:Mt,cite:null,className:On,cols:_e,colSpan:null,content:null,contentEditable:rr,controls:Mt,controlsList:On,coords:_e|Rc,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Mt,defer:Mt,dir:null,dirName:null,disabled:Mt,download:UN,draggable:rr,encType:null,enterKeyHint:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Mt,formTarget:null,headers:On,height:_e,hidden:Mt,high:_e,href:null,hrefLang:null,htmlFor:On,httpEquiv:On,id:null,imageSizes:null,imageSrcSet:null,inputMode:null,integrity:null,is:null,isMap:Mt,itemId:null,itemProp:On,itemRef:On,itemScope:Mt,itemType:On,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Mt,low:_e,manifest:null,max:null,maxLength:_e,media:null,method:null,min:null,minLength:_e,multiple:Mt,muted:Mt,name:null,nonce:null,noModule:Mt,noValidate:Mt,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:Mt,optimum:_e,pattern:null,ping:On,placeholder:null,playsInline:Mt,poster:null,preload:null,readOnly:Mt,referrerPolicy:null,rel:On,required:Mt,reversed:Mt,rows:_e,rowSpan:_e,sandbox:On,scope:null,scoped:Mt,seamless:Mt,selected:Mt,shape:null,size:_e,sizes:null,slot:null,span:_e,spellCheck:rr,src:null,srcDoc:null,srcLang:null,srcSet:null,start:_e,step:null,style:null,tabIndex:_e,target:null,title:null,translate:null,type:null,typeMustMatch:Mt,useMap:null,value:rr,width:_e,wrap:null,align:null,aLink:null,archive:On,axis:null,background:null,bgColor:null,border:_e,borderColor:null,bottomMargin:_e,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Mt,declare:Mt,event:null,face:null,frame:null,frameBorder:null,hSpace:_e,leftMargin:_e,link:null,longDesc:null,lowSrc:null,marginHeight:_e,marginWidth:_e,noResize:Mt,noHref:Mt,noShade:Mt,noWrap:Mt,object:null,profile:null,prompt:null,rev:null,rightMargin:_e,rules:null,scheme:null,scrolling:rr,standby:null,summary:null,text:null,topMargin:_e,valueType:null,version:null,vAlign:null,vLink:null,vSpace:_e,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Mt,disableRemotePlayback:Mt,prefix:null,property:null,results:_e,security:null,unselectable:null}}),LRe=Cu({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:VN,properties:{about:So,accentHeight:_e,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:_e,amplitude:_e,arabicForm:null,ascent:_e,attributeName:null,attributeType:null,azimuth:_e,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:_e,by:null,calcMode:null,capHeight:_e,className:On,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:_e,diffuseConstant:_e,direction:null,display:null,dur:null,divisor:_e,dominantBaseline:null,download:Mt,dx:null,dy:null,edgeMode:null,editable:null,elevation:_e,enableBackground:null,end:null,event:null,exponent:_e,externalResourcesRequired:null,fill:null,fillOpacity:_e,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Rc,g2:Rc,glyphName:Rc,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:_e,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:_e,horizOriginX:_e,horizOriginY:_e,id:null,ideographic:_e,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:_e,k:_e,k1:_e,k2:_e,k3:_e,k4:_e,kernelMatrix:So,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:_e,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:_e,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:_e,overlineThickness:_e,paintOrder:null,panose1:null,path:null,pathLength:_e,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:On,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:_e,pointsAtY:_e,pointsAtZ:_e,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:So,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:So,rev:So,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:So,requiredFeatures:So,requiredFonts:So,requiredFormats:So,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:_e,specularExponent:_e,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:_e,strikethroughThickness:_e,string:null,stroke:null,strokeDashArray:So,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:_e,strokeOpacity:_e,strokeWidth:null,style:null,surfaceScale:_e,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:So,tabIndex:_e,tableValues:null,target:null,targetX:_e,targetY:_e,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:So,to:null,transform:null,u1:null,u2:null,underlinePosition:_e,underlineThickness:_e,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:_e,values:null,vAlphabetic:_e,vMathematical:_e,vectorEffect:null,vHanging:_e,vIdeographic:_e,version:null,vertAdvY:_e,vertOriginX:_e,vertOriginY:_e,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:_e,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),NRe=/^data[-\w.:]+$/i,OP=/-[a-z]/g,MRe=/[A-Z]/g;function DRe(e,t){const n=ww(t);let r=t,o=da;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&NRe.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(OP,FRe);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!OP.test(a)){let i=a.replace(MRe,BRe);i.charAt(0)!=="-"&&(i="-"+i),t="data"+i}}o=I2}return new o(r,t)}function BRe(e){return"-"+e.toLowerCase()}function FRe(e){return e.charAt(1).toUpperCase()}const LP={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},zRe=jN([HN,WN,qN,KN,ORe],"html"),jRe=jN([HN,WN,qN,KN,LRe],"svg");function URe(e){if(e.allowedElements&&e.disallowedElements)throw new TypeError("Only one of `allowedElements` and `disallowedElements` should be defined");if(e.allowedElements||e.disallowedElements||e.allowElement)return t=>{P2(t,"element",(n,r,o)=>{const a=o;let i;if(e.allowedElements?i=!e.allowedElements.includes(n.tagName):e.disallowedElements&&(i=e.disallowedElements.includes(n.tagName)),!i&&e.allowElement&&typeof r=="number"&&(i=!e.allowElement(n,r,a)),i&&typeof r=="number")return e.unwrapDisallowed&&n.children?a.children.splice(r,1,...n.children):a.children.splice(r,1),r})}}function WRe(e){const t=e&&typeof e=="object"&&e.type==="text"?e.value||"":e;return typeof t=="string"&&t.replace(/[ \t\n\f\r]/g,"")===""}function HRe(e){return e.join(" ").trim()}function VRe(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}var NP=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,GRe=/\n/g,qRe=/^\s*/,KRe=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,YRe=/^:\s*/,XRe=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,JRe=/^[;\s]*/,QRe=/^\s+|\s+$/g,ZRe=`
|
|
380
|
+
`,MP="/",DP="*",Js="",ePe="comment",tPe="declaration",nPe=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function o(y){var g=y.match(GRe);g&&(n+=g.length);var v=y.lastIndexOf(ZRe);r=~v?y.length-v:r+y.length}function a(){var y={line:n,column:r};return function(g){return g.position=new i(y),u(),g}}function i(y){this.start=y,this.end={line:n,column:r},this.source=t.source}i.prototype.content=e;function l(y){var g=new Error(t.source+":"+n+":"+r+": "+y);if(g.reason=y,g.filename=t.source,g.line=n,g.column=r,g.source=e,!t.silent)throw g}function c(y){var g=y.exec(e);if(g){var v=g[0];return o(v),e=e.slice(v.length),g}}function u(){c(qRe)}function d(y){var g;for(y=y||[];g=f();)g!==!1&&y.push(g);return y}function f(){var y=a();if(!(MP!=e.charAt(0)||DP!=e.charAt(1))){for(var g=2;Js!=e.charAt(g)&&(DP!=e.charAt(g)||MP!=e.charAt(g+1));)++g;if(g+=2,Js===e.charAt(g-1))return l("End of comment missing");var v=e.slice(2,g-2);return r+=2,o(v),e=e.slice(g),r+=2,y({type:ePe,comment:v})}}function h(){var y=a(),g=c(KRe);if(g){if(f(),!c(YRe))return l("property missing ':'");var v=c(XRe),b=y({type:tPe,property:BP(g[0].replace(NP,Js)),value:v?BP(v[0].replace(NP,Js)):Js});return c(JRe),b}}function m(){var y=[];d(y);for(var g;g=h();)g!==!1&&(y.push(g),d(y));return y}return u(),m()};function BP(e){return e?e.replace(QRe,Js):Js}var rPe=nPe;function oPe(e,t){var n=null;if(!e||typeof e!="string")return n;for(var r,o=rPe(e),a=typeof t=="function",i,l,c=0,u=o.length;c<u;c++)r=o[c],i=r.property,l=r.value,a?t(i,l,r):l&&(n||(n={}),n[i]=l);return n}var aPe=oPe;const xw={}.hasOwnProperty,iPe=new Set(["table","thead","tbody","tfoot","tr"]);function YN(e,t){const n=[];let r=-1,o;for(;++r<t.children.length;)o=t.children[r],o.type==="element"?n.push(sPe(e,o,r,t)):o.type==="text"?(t.type!=="element"||!iPe.has(t.tagName)||!WRe(o))&&n.push(o.value):o.type==="raw"&&!e.options.skipHtml&&n.push(o.value);return n}function sPe(e,t,n,r){const o=e.options,a=e.schema,i=t.tagName,l={};let c=a,u;if(a.space==="html"&&i==="svg"&&(c=jRe,e.schema=c),t.properties)for(u in t.properties)xw.call(t.properties,u)&&cPe(l,u,t.properties[u],e);(i==="ol"||i==="ul")&&e.listDepth++;const d=YN(e,t);(i==="ol"||i==="ul")&&e.listDepth--,e.schema=a;const f=t.position||{start:{line:null,column:null,offset:null},end:{line:null,column:null,offset:null}},h=o.components&&xw.call(o.components,i)?o.components[i]:i,m=typeof h=="string"||h===jt.Fragment;if(!Y9.isValidElementType(h))throw new TypeError(`Component for name \`${i}\` not defined or is not renderable`);if(l.key=[i,f.start.line,f.start.column,n].join("-"),i==="a"&&o.linkTarget&&(l.target=typeof o.linkTarget=="function"?o.linkTarget(String(l.href||""),t.children,typeof l.title=="string"?l.title:null):o.linkTarget),i==="a"&&o.transformLinkUri&&(l.href=o.transformLinkUri(String(l.href||""),t.children,typeof l.title=="string"?l.title:null)),!m&&i==="code"&&r.type==="element"&&r.tagName!=="pre"&&(l.inline=!0),!m&&(i==="h1"||i==="h2"||i==="h3"||i==="h4"||i==="h5"||i==="h6")&&(l.level=Number.parseInt(i.charAt(1),10)),i==="img"&&o.transformImageUri&&(l.src=o.transformImageUri(String(l.src||""),String(l.alt||""),typeof l.title=="string"?l.title:null)),!m&&i==="li"&&r.type==="element"){const y=lPe(t);l.checked=y&&y.properties?Boolean(y.properties.checked):null,l.index=v0(r,t),l.ordered=r.tagName==="ol"}return!m&&(i==="ol"||i==="ul")&&(l.ordered=i==="ol",l.depth=e.listDepth),(i==="td"||i==="th")&&(l.align&&(l.style||(l.style={}),l.style.textAlign=l.align,delete l.align),m||(l.isHeader=i==="th")),!m&&i==="tr"&&r.type==="element"&&(l.isHeader=Boolean(r.tagName==="thead")),o.sourcePos&&(l["data-sourcepos"]=pPe(f)),!m&&o.rawSourcePos&&(l.sourcePosition=t.position),!m&&o.includeElementIndex&&(l.index=v0(r,t),l.siblingCount=v0(r)),m||(l.node=t),d.length>0?jt.createElement(h,l,d):jt.createElement(h,l)}function lPe(e){let t=-1;for(;++t<e.children.length;){const n=e.children[t];if(n.type==="element"&&n.tagName==="input")return n}return null}function v0(e,t){let n=-1,r=0;for(;++n<e.children.length&&e.children[n]!==t;)e.children[n].type==="element"&&r++;return r}function cPe(e,t,n,r){const o=DRe(r.schema,t);let a=n;a==null||a!==a||(Array.isArray(a)&&(a=o.commaSeparated?VRe(a):HRe(a)),o.property==="style"&&typeof a=="string"&&(a=uPe(a)),o.space&&o.property?e[xw.call(LP,o.property)?LP[o.property]:o.property]=a:o.attribute&&(e[o.attribute]=a))}function uPe(e){const t={};try{aPe(e,n)}catch{}return t;function n(r,o){const a=r.slice(0,4)==="-ms-"?`ms-${r.slice(4)}`:r;t[a.replace(/-([a-z])/g,dPe)]=o}}function dPe(e,t){return t.toUpperCase()}function pPe(e){return[e.start.line,":",e.start.column,"-",e.end.line,":",e.end.column].map(String).join("")}const FP={}.hasOwnProperty,fPe="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",vh={plugins:{to:"plugins",id:"change-plugins-to-remarkplugins"},renderers:{to:"components",id:"change-renderers-to-components"},astPlugins:{id:"remove-buggy-html-in-markdown-parser"},allowDangerousHtml:{id:"remove-buggy-html-in-markdown-parser"},escapeHtml:{id:"remove-buggy-html-in-markdown-parser"},source:{to:"children",id:"change-source-to-children"},allowNode:{to:"allowElement",id:"replace-allownode-allowedtypes-and-disallowedtypes"},allowedTypes:{to:"allowedElements",id:"replace-allownode-allowedtypes-and-disallowedtypes"},disallowedTypes:{to:"disallowedElements",id:"replace-allownode-allowedtypes-and-disallowedtypes"},includeNodeIndex:{to:"includeElementIndex",id:"change-includenodeindex-to-includeelementindex"}};function ey(e){for(const a in vh)if(FP.call(vh,a)&&FP.call(e,a)){const i=vh[a];console.warn(`[react-markdown] Warning: please ${i.to?`use \`${i.to}\` instead of`:"remove"} \`${a}\` (see <${fPe}#${i.id}> for more info)`),delete vh[a]}const t=Bke().use(j_e).use(e.remarkPlugins||[]).use(_Re,{...e.remarkRehypeOptions,allowDangerousHtml:!0}).use(e.rehypePlugins||[]).use(URe,e),n=new gN;typeof e.children=="string"?n.value=e.children:e.children!==void 0&&e.children!==null&&console.warn(`[react-markdown] Warning: please pass a string as \`children\` (not: \`${e.children}\`)`);const r=t.runSync(t.parse(n),n);if(r.type!=="root")throw new TypeError("Expected a `root` node");let o=jt.createElement(jt.Fragment,{},YN({options:e,schema:zRe,listDepth:0},r));return e.className&&(o=jt.createElement("div",{className:e.className},o)),o}ey.defaultProps={transformLinkUri:Tke};ey.propTypes={children:ut.string,className:ut.string,allowElement:ut.func,allowedElements:ut.arrayOf(ut.string),disallowedElements:ut.arrayOf(ut.string),unwrapDisallowed:ut.bool,remarkPlugins:ut.arrayOf(ut.oneOfType([ut.object,ut.func,ut.arrayOf(ut.oneOfType([ut.bool,ut.string,ut.object,ut.func,ut.arrayOf(ut.any)]))])),rehypePlugins:ut.arrayOf(ut.oneOfType([ut.object,ut.func,ut.arrayOf(ut.oneOfType([ut.bool,ut.string,ut.object,ut.func,ut.arrayOf(ut.any)]))])),sourcePos:ut.bool,rawSourcePos:ut.bool,skipHtml:ut.bool,includeElementIndex:ut.bool,transformLinkUri:ut.oneOfType([ut.func,ut.bool]),linkTarget:ut.oneOfType([ut.func,ut.string]),transformImageUri:ut.func,components:ut.object};const hPe=C(ey)(({theme:e})=>({"h1, h2, h3":{margin:e.spacing(2,0)}})),mPe=({open:e,setOpen:t,title:n,children:r})=>s(Zn,{title:n,open:e,secondaryButtonText:"Close",onClose:()=>{t(!1)},children:s(hPe,{children:r})}),gPe=C("aside",{shouldForwardProp:e=>e!=="variant"})(({theme:e,variant:t})=>({position:"relative",zIndex:1,display:"flex",alignItems:"center",justifyContent:"center",padding:e.spacing(1),gap:e.spacing(1),borderBottom:"1px solid",borderColor:e.palette[t].border,background:e.palette[t].light,color:e.palette[t].dark,fontSize:e.fontSizes.smallBody})),vPe=C("div",{shouldForwardProp:e=>e!=="variant"})(({theme:e,variant:t})=>({display:"flex",alignItems:"center",color:e.palette[t].main})),yPe={enabled:!0,message:"**Unleash v5 is finally here!** Check out what changed in the newest major release.",variant:"secondary",link:"dialog",linkText:"What's new?",plausibleEvent:"change_log_v5",dialog:`
|
|
381
|
+
## Unleash v5 🎉
|
|
382
|
+
**Unleash v5 is finally here!**
|
|
383
|
+
|
|
384
|
+
Check out what changed in the newest major release:
|
|
385
|
+
|
|
386
|
+
- An Amazing Feature
|
|
387
|
+
- Another Amazing Feature
|
|
388
|
+
- We'll save the best for last
|
|
389
|
+
- And the best is...
|
|
390
|
+
- **Unleash v5 is finally here!**
|
|
391
|
+
|
|
392
|
+
You can read more about it on our newest [blog post](https://www.getunleash.io/blog).`},bPe=()=>{const{uiConfig:e}=Lt(),[t,n]=p.useState(!1),{enabled:r,message:o,variant:a="neutral",icon:i,link:l,linkText:c="More info",plausibleEvent:u,dialogTitle:d,dialog:f}={...yPe,enabled:e.flags.messageBanner};return r?T(gPe,{variant:a,children:[s(vPe,{variant:a,children:s(SPe,{icon:i,variant:a})}),s(ey,{children:o}),s(xPe,{link:l,plausibleEvent:u,openDialog:()=>n(!0),children:c}),s(mPe,{open:t,setOpen:n,title:d||c,children:f})]}):null},wPe={warning:s(D4,{}),info:s(Bd,{}),error:s(uv,{}),success:s(Am,{}),neutral:s(Bd,{}),secondary:s(Bd,{})},SPe=({icon:e,variant:t})=>e==="none"?null:e?s(cx,{children:e}):wPe[t]??s(Bd,{}),xPe=({link:e,plausibleEvent:t,openDialog:n,children:r})=>{const o=lt(),a=ka();if(!e)return null;const i=e==="dialog",l=!e.startsWith("http"),c=()=>{t&&a.trackEvent("message_banner",{props:{event:t}})};return i?s(go,{onClick:()=>{c(),n()},children:r}):l?s(go,{onClick:()=>{c(),o(e)},children:r}):s(go,{href:e,target:"_blank",onClick:c,children:r})};fd.render(s(Eke,{children:s(ITe,{children:s(R9,{basename:Oi,children:s(oee,{children:s(oke,{children:s(tke,{children:T(wke,{children:[s(bPe,{}),s(RTe,{}),s(_Te,{})]})})})})})})}),document.getElementById("app"));export{bm as $,Zt as A,Io as B,X as C,HR as D,pu as E,ke as F,ls as G,Lt as H,_v as I,cle as J,lu as K,tu as L,Sv as M,cr as N,Is as O,dx as P,Tv as Q,cs as R,Ni as S,ye as T,af as U,Hr as V,Un as W,Di as X,vv as Y,Nn as Z,B$ as _,Me as a,Kv as a$,Ps as a0,pO as a1,It as a2,Il as a3,ft as a4,Pi as a5,Yp as a6,Xp as a7,bs as a8,Ze as a9,Ue as aA,Ve as aB,$e as aC,I as aD,ve as aE,He as aF,dr as aG,bl as aH,she as aI,ie as aJ,ur as aK,f3 as aL,ln as aM,Za as aN,Oae as aO,dn as aP,Dt as aQ,yn as aR,Vr as aS,of as aT,Mne as aU,GPe as aV,Oo as aW,zo as aX,Zn as aY,Mwe as aZ,d2 as a_,xO as aa,Que as ab,mn as ac,av as ad,Bi as ae,mo as af,Qg as ag,pr as ah,uv as ai,uu as aj,fr as ak,xn as al,Fm as am,sle as an,IZ as ao,Ep as ap,ca as aq,lt as ar,vpe as as,vC as at,Mr as au,gpe as av,mu as aw,CA as ax,jo as ay,je as az,mIe as b,vIe as b$,p2 as b0,kPe as b1,Ype as b2,Kpe as b3,qpe as b4,hIe as b5,g3 as b6,_t as b7,qPe as b8,xZ as b9,Z3 as bA,Dne as bB,go as bC,Ev as bD,Ta as bE,Rs as bF,y8 as bG,Ov as bH,Lv as bI,wle as bJ,ka as bK,IC as bL,kZ as bM,Dm as bN,O3 as bO,C9 as bP,Rh as bQ,FC as bR,wIe as bS,jL as bT,Tr as bU,_r as bV,Ii as bW,o4 as bX,I4 as bY,du as bZ,Bne as b_,px as ba,Lh as bb,jZ as bc,fn as bd,Hwe as be,Wx as bf,GR as bg,Gr as bh,G$ as bi,xa as bj,ba as bk,KPe as bl,In as bm,OZ as bn,au as bo,nx as bp,ox as bq,rx as br,Uie as bs,VPe as bt,ii as bu,Uc as bv,rf as bw,M4 as bx,N4 as by,gu as bz,Ye as c,cke as c$,Pwe as c0,su as c1,yl as c2,$ie as c3,Wc as c4,gIe as c5,MO as c6,ws as c7,Cp as c8,jt as c9,Uwe as cA,D4 as cB,xv as cC,zS as cD,na as cE,Dg as cF,m$ as cG,Ro as cH,TPe as cI,Hp as cJ,Wn as cK,xs as cL,sr as cM,ube as cN,iIe as cO,oIe as cP,WO as cQ,ti as cR,aIe as cS,G3 as cT,cbe as cU,Jue as cV,Fo as cW,tfe as cX,Ci as cY,pN as cZ,lc as c_,Ss as ca,hv as cb,qb as cc,Iwe as cd,sIe as ce,xpe as cf,aSe as cg,Kae as ch,EJ as ci,Die as cj,ia as ck,Cue as cl,wp as cm,L4 as cn,Rne as co,BZ as cp,PQ as cq,ER as cr,NC as cs,Dwe as ct,jwe as cu,Gwe as cv,qwe as cw,Kwe as cx,Nwe as cy,Wwe as cz,Kt as d,cn as d$,W3 as d0,ike as d1,i3 as d2,IJ as d3,QJ as d4,v4 as d5,_l as d6,Pl as d7,IPe as d8,SR as d9,hx as dA,kx as dB,j4 as dC,eee as dD,ML as dE,fZ as dF,Bce as dG,ef as dH,Ca as dI,dO as dJ,fO as dK,Cs as dL,uO as dM,Noe as dN,b7 as dO,_Pe as dP,EO as dQ,Nb as dR,BL as dS,Nue as dT,bIe as dU,X0e as dV,Bb as dW,dSe as dX,Zp as dY,_le as dZ,Cn as d_,Dx as da,RPe as db,PPe as dc,Rl as dd,yIe as de,$Pe as df,tpe as dg,OPe as dh,YL as di,DPe as dj,LPe as dk,NPe as dl,yO as dm,MPe as dn,l4 as dp,JL as dq,APe as dr,EPe as ds,yC as dt,qL as du,dw as dv,MSe as dw,DL as dx,kSe as dy,ol as dz,Aa as e,pIe as e$,En as e0,gC as e1,fh as e2,nIe as e3,fv as e4,Li as e5,Mie as e6,jie as e7,zie as e8,_3 as e9,T2 as eA,AEe as eB,lIe as eC,H3 as eD,zue as eE,UPe as eF,FPe as eG,zPe as eH,jPe as eI,WPe as eJ,HPe as eK,BPe as eL,eie as eM,dIe as eN,uIe as eO,xSe as eP,ut as eQ,Ot as eR,XPe as eS,QPe as eT,ZPe as eU,eIe as eV,JPe as eW,xue as eX,YPe as eY,$ne as eZ,Eue as e_,$3 as ea,Lie as eb,Xie as ec,Fh as ed,wx as ee,k$ as ef,lCe as eg,TTe as eh,wv as ei,Am as ej,t3 as ek,lae as el,cae as em,uae as en,dae as eo,pae as ep,Nae as eq,D3 as er,iv as es,REe as et,BEe as eu,Id as ev,AZ as ew,Xxe as ex,cIe as ey,kb as ez,T as f,wre as f0,nf as f1,w3 as f2,b3 as f3,xre as f4,fIe as f5,x3 as f6,Om as f7,$m as f8,$re as f9,Rre as fa,E3 as fb,Bre as fc,Ure as fd,IA as fe,jre as ff,Ere as fg,bp as fh,T3 as fi,Kx as fj,xp as fk,mA as fl,Fa as fm,wc as fn,OB as fo,IB as fp,Ys as fq,rIe as fr,Mi as g,$i as h,ai as i,s as j,ei as k,eo as l,Yt as m,Bd as n,P4 as o,s2 as p,r0e as q,p as r,C as s,_L as t,on as u,WL as v,To as w,Da as x,Qi as y,jd as z};
|