@js-smart/react-kit 5.12.0-beta.3 → 5.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.cjs +75 -0
- package/{react-kit/src/index.ts → index.d.ts} +9 -16
- package/index.js +6255 -0
- package/lib/components/CenteredCircularProgress.d.ts +7 -0
- package/lib/components/ConfirmationDialog.d.ts +11 -0
- package/lib/components/DismissibleAlert.d.ts +17 -0
- package/lib/components/NextLink.d.ts +17 -0
- package/lib/components/OpenInNewIconLink.d.ts +17 -0
- package/lib/components/ReactIf.d.ts +36 -0
- package/lib/components/buttons/CancelButton.d.ts +28 -0
- package/lib/components/buttons/DeleteButton.d.ts +16 -0
- package/lib/components/buttons/EditIconButton.d.ts +8 -0
- package/lib/components/buttons/ExcelButton.d.ts +26 -0
- package/lib/components/buttons/GoBackButton.d.ts +10 -0
- package/lib/components/buttons/HistoryButton.d.ts +28 -0
- package/lib/components/buttons/LoadingSuccessButton.d.ts +28 -0
- package/lib/components/buttons/ManageButton.d.ts +14 -0
- package/lib/components/buttons/SuccessButton.d.ts +28 -0
- package/lib/components/snack-bar/AppSnackBar.d.ts +6 -0
- package/lib/components/snack-bar/QuerySnackBar.d.ts +18 -0
- package/lib/components/table/TablePaginationActions.d.ts +9 -0
- package/lib/components/tabs/TabPanel.d.ts +12 -0
- package/lib/config/fetch/FetchClient.d.ts +58 -0
- package/lib/config/fetch/FetchClientTypes.d.ts +39 -0
- package/lib/config/fetch/FetchInterceptor.d.ts +21 -0
- package/lib/constants/AppConstants.d.ts +15 -0
- package/lib/constants/HttpConstants.d.ts +13 -0
- package/lib/types/ProgressState.d.ts +7 -0
- package/lib/utils/BooleanUtils.d.ts +7 -0
- package/{react-kit/src/lib/utils/CssUtils.ts → lib/utils/CssUtils.d.ts} +1 -3
- package/lib/utils/DateUtils.d.ts +22 -0
- package/lib/utils/NumberUtils.d.ts +7 -0
- package/lib/utils/ProgressStateUtils.d.ts +38 -0
- package/lib/utils/StringUtils.d.ts +7 -0
- package/lib/utils/UrlUtils.d.ts +11 -0
- package/package.json +44 -98
- package/.editorconfig +0 -13
- package/.eslintignore +0 -1
- package/.eslintrc.json +0 -41
- package/.github/copilot-instructions.md +0 -11
- package/.github/workflows/build.yml +0 -45
- package/.github/workflows/release.yml +0 -65
- package/.prettierignore +0 -5
- package/.prettierrc +0 -9
- package/.vscode/extensions.json +0 -7
- package/CHANGELOG.md +0 -24
- package/CODE_OF_CONDUCT.md +0 -128
- package/FUNDING.yml +0 -1
- package/LICENSE +0 -21
- package/README.md +0 -1
- package/apps/react-kit-demo/.eslintrc.json +0 -22
- package/apps/react-kit-demo/index.html +0 -16
- package/apps/react-kit-demo/project.json +0 -9
- package/apps/react-kit-demo/public/favicon.ico +0 -0
- package/apps/react-kit-demo/src/app/Home.tsx +0 -17
- package/apps/react-kit-demo/src/app/all-books/AllBooks.tsx +0 -68
- package/apps/react-kit-demo/src/app/app.module.scss +0 -1
- package/apps/react-kit-demo/src/app/app.tsx +0 -29
- package/apps/react-kit-demo/src/app/buttons/ButtonsDemo.tsx +0 -58
- package/apps/react-kit-demo/src/app/dialog/DialogDemo.tsx +0 -23
- package/apps/react-kit-demo/src/app/links/LinksDemo.tsx +0 -20
- package/apps/react-kit-demo/src/app/progress-bar/CenterCircularProgressDemo.tsx +0 -10
- package/apps/react-kit-demo/src/app/react-if/ReactIfDemo.tsx +0 -44
- package/apps/react-kit-demo/src/app/snack-bar/SnackBarDemo.tsx +0 -35
- package/apps/react-kit-demo/src/assets/.gitkeep +0 -0
- package/apps/react-kit-demo/src/constants/ApiConstants.ts +0 -7
- package/apps/react-kit-demo/src/constants/DialogMode.ts +0 -2
- package/apps/react-kit-demo/src/constants/HttpConstants.ts +0 -18
- package/apps/react-kit-demo/src/constants/StateConstants.ts +0 -2
- package/apps/react-kit-demo/src/main.tsx +0 -17
- package/apps/react-kit-demo/src/routes/Routes.tsx +0 -55
- package/apps/react-kit-demo/src/services/BookService.ts +0 -21
- package/apps/react-kit-demo/src/styles.scss +0 -36
- package/apps/react-kit-demo/src/theme.ts +0 -46
- package/apps/react-kit-demo/src/types/Book.ts +0 -8
- package/apps/react-kit-demo/src/utils/CssUtils.ts +0 -13
- package/apps/react-kit-demo/tsconfig.app.json +0 -18
- package/apps/react-kit-demo/tsconfig.json +0 -21
- package/apps/react-kit-demo/tsconfig.spec.json +0 -28
- package/apps/react-kit-demo/vite.config.ts +0 -50
- package/nx.json +0 -52
- package/react-kit/.babelrc +0 -12
- package/react-kit/.eslintrc.json +0 -18
- package/react-kit/README.md +0 -7
- package/react-kit/package-lock.json +0 -1330
- package/react-kit/package.json +0 -45
- package/react-kit/project.json +0 -10
- package/react-kit/src/lib/components/CenteredCircularProgress.tsx +0 -15
- package/react-kit/src/lib/components/ConfirmationDialog.tsx +0 -28
- package/react-kit/src/lib/components/DismissibleAlert.tsx +0 -60
- package/react-kit/src/lib/components/NextLink.tsx +0 -26
- package/react-kit/src/lib/components/OpenInNewIconLink.tsx +0 -42
- package/react-kit/src/lib/components/ReactIf.tsx +0 -53
- package/react-kit/src/lib/components/buttons/CancelButton.tsx +0 -45
- package/react-kit/src/lib/components/buttons/DeleteButton.tsx +0 -35
- package/react-kit/src/lib/components/buttons/EditIconButton.tsx +0 -23
- package/react-kit/src/lib/components/buttons/ExcelButton.tsx +0 -43
- package/react-kit/src/lib/components/buttons/GoBackButton.tsx +0 -22
- package/react-kit/src/lib/components/buttons/HistoryButton.tsx +0 -45
- package/react-kit/src/lib/components/buttons/LoadingSuccessButton.tsx +0 -53
- package/react-kit/src/lib/components/buttons/ManageButton.tsx +0 -31
- package/react-kit/src/lib/components/buttons/SuccessButton.tsx +0 -44
- package/react-kit/src/lib/components/snack-bar/AppSnackBar.tsx +0 -46
- package/react-kit/src/lib/components/snack-bar/QuerySnackBar.tsx +0 -62
- package/react-kit/src/lib/components/table/TablePaginationActions.tsx +0 -58
- package/react-kit/src/lib/components/tabs/TabPanel.tsx +0 -26
- package/react-kit/src/lib/constants/AppConstants.ts +0 -17
- package/react-kit/src/lib/types/ProgressState.ts +0 -7
- package/react-kit/src/lib/utils/BooleanUtils.ts +0 -13
- package/react-kit/src/lib/utils/DateUtils.ts +0 -43
- package/react-kit/src/lib/utils/NumberUtils.ts +0 -12
- package/react-kit/src/lib/utils/ProgressStateUtils.ts +0 -68
- package/react-kit/src/lib/utils/StringUtils.ts +0 -14
- package/react-kit/src/lib/utils/UrlUtils.ts +0 -19
- package/react-kit/src/lib/utils/fetchClient.ts +0 -64
- package/react-kit/src/tests/buttons/CancelButton.test.tsx +0 -69
- package/react-kit/src/tests/buttons/DeleteButton.test.tsx +0 -63
- package/react-kit/src/tests/buttons/EditIconButton.test.tsx +0 -34
- package/react-kit/src/tests/buttons/HistoryButton.test.tsx +0 -46
- package/react-kit/src/tests/buttons/LoadingSuccessButton.test.tsx +0 -53
- package/react-kit/src/tests/buttons/ManageButton.test.tsx +0 -49
- package/react-kit/src/tests/buttons/SuccessButton.test.tsx +0 -46
- package/react-kit/src/tests/snack-bar/AppSnackBar.test.tsx +0 -54
- package/react-kit/src/tests/utils/BooleanUtils.test.ts +0 -35
- package/react-kit/src/tests/utils/CssUtils.test.ts +0 -17
- package/react-kit/src/tests/utils/DateUtils.test.ts +0 -46
- package/react-kit/src/tests/utils/NumberUtils.test.ts +0 -19
- package/react-kit/src/tests/utils/ProgressStateUtils.test.ts +0 -131
- package/react-kit/src/tests/utils/StringUtils.test.ts +0 -33
- package/react-kit/src/tests/utils/UrlUtils.test.ts +0 -19
- package/react-kit/tsconfig.json +0 -22
- package/react-kit/tsconfig.lib.json +0 -24
- package/react-kit/tsconfig.spec.json +0 -27
- package/react-kit/vite.config.ts +0 -72
- package/release.sh +0 -28
- package/tsconfig.base.json +0 -22
- package/vitest.workspace.js +0 -3
- package/vitest.workspace.ts +0 -1
package/index.cjs
ADDED
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";var oo=Object.defineProperty;var so=(e,t,n)=>t in e?oo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var Me=(e,t,n)=>so(e,typeof t!="symbol"?t+"":t,n);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=require("react/jsx-runtime"),$=require("@mui/material"),se=require("react"),io=require("@emotion/styled"),ao=require("@emotion/react"),Sr=require("react-router-dom"),tn=require("date-fns");function co(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Se=co(se),xn=e=>e,lo=()=>{let e=xn;return{configure(t){e=t},generate(t){return e(t)},reset(){e=xn}}},uo=lo();function Oe(e,...t){const n=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(r=>n.searchParams.append("args[]",r)),`Minified MUI error #${e}; visit ${n} for the full message.`}function De(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":Oe(7));return e.charAt(0).toUpperCase()+e.slice(1)}function fo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ut={exports:{}},ft={exports:{}},H={};/** @license React v16.13.1
|
|
2
|
+
* react-is.production.min.js
|
|
3
|
+
*
|
|
4
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the MIT license found in the
|
|
7
|
+
* LICENSE file in the root directory of this source tree.
|
|
8
|
+
*/var Pn;function ho(){if(Pn)return H;Pn=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,u=e?Symbol.for("react.async_mode"):60111,f=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,y=e?Symbol.for("react.memo"):60115,g=e?Symbol.for("react.lazy"):60116,l=e?Symbol.for("react.block"):60121,b=e?Symbol.for("react.fundamental"):60117,k=e?Symbol.for("react.responder"):60118,x=e?Symbol.for("react.scope"):60119;function E(_){if(typeof _=="object"&&_!==null){var N=_.$$typeof;switch(N){case t:switch(_=_.type,_){case u:case f:case r:case s:case o:case h:return _;default:switch(_=_&&_.$$typeof,_){case a:case d:case g:case y:case i:return _;default:return N}}case n:return N}}}function T(_){return E(_)===f}return H.AsyncMode=u,H.ConcurrentMode=f,H.ContextConsumer=a,H.ContextProvider=i,H.Element=t,H.ForwardRef=d,H.Fragment=r,H.Lazy=g,H.Memo=y,H.Portal=n,H.Profiler=s,H.StrictMode=o,H.Suspense=h,H.isAsyncMode=function(_){return T(_)||E(_)===u},H.isConcurrentMode=T,H.isContextConsumer=function(_){return E(_)===a},H.isContextProvider=function(_){return E(_)===i},H.isElement=function(_){return typeof _=="object"&&_!==null&&_.$$typeof===t},H.isForwardRef=function(_){return E(_)===d},H.isFragment=function(_){return E(_)===r},H.isLazy=function(_){return E(_)===g},H.isMemo=function(_){return E(_)===y},H.isPortal=function(_){return E(_)===n},H.isProfiler=function(_){return E(_)===s},H.isStrictMode=function(_){return E(_)===o},H.isSuspense=function(_){return E(_)===h},H.isValidElementType=function(_){return typeof _=="string"||typeof _=="function"||_===r||_===f||_===s||_===o||_===h||_===m||typeof _=="object"&&_!==null&&(_.$$typeof===g||_.$$typeof===y||_.$$typeof===i||_.$$typeof===a||_.$$typeof===d||_.$$typeof===b||_.$$typeof===k||_.$$typeof===x||_.$$typeof===l)},H.typeOf=E,H}var Y={};/** @license React v16.13.1
|
|
9
|
+
* react-is.development.js
|
|
10
|
+
*
|
|
11
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
12
|
+
*
|
|
13
|
+
* This source code is licensed under the MIT license found in the
|
|
14
|
+
* LICENSE file in the root directory of this source tree.
|
|
15
|
+
*/var Nn;function mo(){return Nn||(Nn=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,u=e?Symbol.for("react.async_mode"):60111,f=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,y=e?Symbol.for("react.memo"):60115,g=e?Symbol.for("react.lazy"):60116,l=e?Symbol.for("react.block"):60121,b=e?Symbol.for("react.fundamental"):60117,k=e?Symbol.for("react.responder"):60118,x=e?Symbol.for("react.scope"):60119;function E(C){return typeof C=="string"||typeof C=="function"||C===r||C===f||C===s||C===o||C===h||C===m||typeof C=="object"&&C!==null&&(C.$$typeof===g||C.$$typeof===y||C.$$typeof===i||C.$$typeof===a||C.$$typeof===d||C.$$typeof===b||C.$$typeof===k||C.$$typeof===x||C.$$typeof===l)}function T(C){if(typeof C=="object"&&C!==null){var _e=C.$$typeof;switch(_e){case t:var lt=C.type;switch(lt){case u:case f:case r:case s:case o:case h:return lt;default:var On=lt&<.$$typeof;switch(On){case a:case d:case g:case y:case i:return On;default:return _e}}case n:return _e}}}var _=u,N=f,v=a,I=i,F=t,c=d,A=r,P=g,M=y,re=n,ee=s,ie=o,ue=h,Ne=!1;function je(C){return Ne||(Ne=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),w(C)||T(C)===u}function w(C){return T(C)===f}function O(C){return T(C)===a}function W(C){return T(C)===i}function L(C){return typeof C=="object"&&C!==null&&C.$$typeof===t}function R(C){return T(C)===d}function V(C){return T(C)===r}function j(C){return T(C)===g}function B(C){return T(C)===y}function U(C){return T(C)===n}function q(C){return T(C)===s}function z(C){return T(C)===o}function le(C){return T(C)===h}Y.AsyncMode=_,Y.ConcurrentMode=N,Y.ContextConsumer=v,Y.ContextProvider=I,Y.Element=F,Y.ForwardRef=c,Y.Fragment=A,Y.Lazy=P,Y.Memo=M,Y.Portal=re,Y.Profiler=ee,Y.StrictMode=ie,Y.Suspense=ue,Y.isAsyncMode=je,Y.isConcurrentMode=w,Y.isContextConsumer=O,Y.isContextProvider=W,Y.isElement=L,Y.isForwardRef=R,Y.isFragment=V,Y.isLazy=j,Y.isMemo=B,Y.isPortal=U,Y.isProfiler=q,Y.isStrictMode=z,Y.isSuspense=le,Y.isValidElementType=E,Y.typeOf=T}()),Y}var In;function wr(){return In||(In=1,process.env.NODE_ENV==="production"?ft.exports=ho():ft.exports=mo()),ft.exports}/*
|
|
16
|
+
object-assign
|
|
17
|
+
(c) Sindre Sorhus
|
|
18
|
+
@license MIT
|
|
19
|
+
*/var Ft,$n;function go(){if($n)return Ft;$n=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},a=0;a<10;a++)i["_"+String.fromCharCode(a)]=a;var u=Object.getOwnPropertyNames(i).map(function(d){return i[d]});if(u.join("")!=="0123456789")return!1;var f={};return"abcdefghijklmnopqrst".split("").forEach(function(d){f[d]=d}),Object.keys(Object.assign({},f)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Ft=o()?Object.assign:function(s,i){for(var a,u=r(s),f,d=1;d<arguments.length;d++){a=Object(arguments[d]);for(var h in a)t.call(a,h)&&(u[h]=a[h]);if(e){f=e(a);for(var m=0;m<f.length;m++)n.call(a,f[m])&&(u[f[m]]=a[f[m]])}}return u},Ft}var Vt,Rn;function dn(){if(Rn)return Vt;Rn=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return Vt=e,Vt}var Ut,Dn;function vr(){return Dn||(Dn=1,Ut=Function.call.bind(Object.prototype.hasOwnProperty)),Ut}var zt,jn;function po(){if(jn)return zt;jn=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=dn(),n={},r=vr();e=function(s){var i="Warning: "+s;typeof console<"u"&&console.error(i);try{throw new Error(i)}catch{}}}function o(s,i,a,u,f){if(process.env.NODE_ENV!=="production"){for(var d in s)if(r(s,d)){var h;try{if(typeof s[d]!="function"){var m=Error((u||"React class")+": "+a+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof s[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw m.name="Invariant Violation",m}h=s[d](i,d,u,a,null,t)}catch(g){h=g}if(h&&!(h instanceof Error)&&e((u||"React class")+": type specification of "+a+" `"+d+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof h+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),h instanceof Error&&!(h.message in n)){n[h.message]=!0;var y=f?f():"";e("Failed "+a+" type: "+h.message+(y??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},zt=o,zt}var Kt,Mn;function yo(){if(Mn)return Kt;Mn=1;var e=wr(),t=go(),n=dn(),r=vr(),o=po(),s=function(){};process.env.NODE_ENV!=="production"&&(s=function(a){var u="Warning: "+a;typeof console<"u"&&console.error(u);try{throw new Error(u)}catch{}});function i(){return null}return Kt=function(a,u){var f=typeof Symbol=="function"&&Symbol.iterator,d="@@iterator";function h(w){var O=w&&(f&&w[f]||w[d]);if(typeof O=="function")return O}var m="<<anonymous>>",y={array:k("array"),bigint:k("bigint"),bool:k("boolean"),func:k("function"),number:k("number"),object:k("object"),string:k("string"),symbol:k("symbol"),any:x(),arrayOf:E,element:T(),elementType:_(),instanceOf:N,node:c(),objectOf:I,oneOf:v,oneOfType:F,shape:P,exact:M};function g(w,O){return w===O?w!==0||1/w===1/O:w!==w&&O!==O}function l(w,O){this.message=w,this.data=O&&typeof O=="object"?O:{},this.stack=""}l.prototype=Error.prototype;function b(w){if(process.env.NODE_ENV!=="production")var O={},W=0;function L(V,j,B,U,q,z,le){if(U=U||m,z=z||B,le!==n){if(u){var C=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 C.name="Invariant Violation",C}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var _e=U+":"+B;!O[_e]&&W<3&&(s("You are manually calling a React.PropTypes validation function for the `"+z+"` prop on `"+U+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),O[_e]=!0,W++)}}return j[B]==null?V?j[B]===null?new l("The "+q+" `"+z+"` is marked as required "+("in `"+U+"`, but its value is `null`.")):new l("The "+q+" `"+z+"` is marked as required in "+("`"+U+"`, but its value is `undefined`.")):null:w(j,B,U,q,z)}var R=L.bind(null,!1);return R.isRequired=L.bind(null,!0),R}function k(w){function O(W,L,R,V,j,B){var U=W[L],q=ie(U);if(q!==w){var z=ue(U);return new l("Invalid "+V+" `"+j+"` of type "+("`"+z+"` supplied to `"+R+"`, expected ")+("`"+w+"`."),{expectedType:w})}return null}return b(O)}function x(){return b(i)}function E(w){function O(W,L,R,V,j){if(typeof w!="function")return new l("Property `"+j+"` of component `"+R+"` has invalid PropType notation inside arrayOf.");var B=W[L];if(!Array.isArray(B)){var U=ie(B);return new l("Invalid "+V+" `"+j+"` of type "+("`"+U+"` supplied to `"+R+"`, expected an array."))}for(var q=0;q<B.length;q++){var z=w(B,q,R,V,j+"["+q+"]",n);if(z instanceof Error)return z}return null}return b(O)}function T(){function w(O,W,L,R,V){var j=O[W];if(!a(j)){var B=ie(j);return new l("Invalid "+R+" `"+V+"` of type "+("`"+B+"` supplied to `"+L+"`, expected a single ReactElement."))}return null}return b(w)}function _(){function w(O,W,L,R,V){var j=O[W];if(!e.isValidElementType(j)){var B=ie(j);return new l("Invalid "+R+" `"+V+"` of type "+("`"+B+"` supplied to `"+L+"`, expected a single ReactElement type."))}return null}return b(w)}function N(w){function O(W,L,R,V,j){if(!(W[L]instanceof w)){var B=w.name||m,U=je(W[L]);return new l("Invalid "+V+" `"+j+"` of type "+("`"+U+"` supplied to `"+R+"`, expected ")+("instance of `"+B+"`."))}return null}return b(O)}function v(w){if(!Array.isArray(w))return process.env.NODE_ENV!=="production"&&(arguments.length>1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function O(W,L,R,V,j){for(var B=W[L],U=0;U<w.length;U++)if(g(B,w[U]))return null;var q=JSON.stringify(w,function(le,C){var _e=ue(C);return _e==="symbol"?String(C):C});return new l("Invalid "+V+" `"+j+"` of value `"+String(B)+"` "+("supplied to `"+R+"`, expected one of "+q+"."))}return b(O)}function I(w){function O(W,L,R,V,j){if(typeof w!="function")return new l("Property `"+j+"` of component `"+R+"` has invalid PropType notation inside objectOf.");var B=W[L],U=ie(B);if(U!=="object")return new l("Invalid "+V+" `"+j+"` of type "+("`"+U+"` supplied to `"+R+"`, expected an object."));for(var q in B)if(r(B,q)){var z=w(B,q,R,V,j+"."+q,n);if(z instanceof Error)return z}return null}return b(O)}function F(w){if(!Array.isArray(w))return process.env.NODE_ENV!=="production"&&s("Invalid argument supplied to oneOfType, expected an instance of array."),i;for(var O=0;O<w.length;O++){var W=w[O];if(typeof W!="function")return s("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+Ne(W)+" at index "+O+"."),i}function L(R,V,j,B,U){for(var q=[],z=0;z<w.length;z++){var le=w[z],C=le(R,V,j,B,U,n);if(C==null)return null;C.data&&r(C.data,"expectedType")&&q.push(C.data.expectedType)}var _e=q.length>0?", expected one of type ["+q.join(", ")+"]":"";return new l("Invalid "+B+" `"+U+"` supplied to "+("`"+j+"`"+_e+"."))}return b(L)}function c(){function w(O,W,L,R,V){return re(O[W])?null:new l("Invalid "+R+" `"+V+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return b(w)}function A(w,O,W,L,R){return new l((w||"React class")+": "+O+" type `"+W+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+R+"`.")}function P(w){function O(W,L,R,V,j){var B=W[L],U=ie(B);if(U!=="object")return new l("Invalid "+V+" `"+j+"` of type `"+U+"` "+("supplied to `"+R+"`, expected `object`."));for(var q in w){var z=w[q];if(typeof z!="function")return A(R,V,j,q,ue(z));var le=z(B,q,R,V,j+"."+q,n);if(le)return le}return null}return b(O)}function M(w){function O(W,L,R,V,j){var B=W[L],U=ie(B);if(U!=="object")return new l("Invalid "+V+" `"+j+"` of type `"+U+"` "+("supplied to `"+R+"`, expected `object`."));var q=t({},W[L],w);for(var z in q){var le=w[z];if(r(w,z)&&typeof le!="function")return A(R,V,j,z,ue(le));if(!le)return new l("Invalid "+V+" `"+j+"` key `"+z+"` supplied to `"+R+"`.\nBad object: "+JSON.stringify(W[L],null," ")+`
|
|
20
|
+
Valid keys: `+JSON.stringify(Object.keys(w),null," "));var C=le(B,z,R,V,j+"."+z,n);if(C)return C}return null}return b(O)}function re(w){switch(typeof w){case"number":case"string":case"undefined":return!0;case"boolean":return!w;case"object":if(Array.isArray(w))return w.every(re);if(w===null||a(w))return!0;var O=h(w);if(O){var W=O.call(w),L;if(O!==w.entries){for(;!(L=W.next()).done;)if(!re(L.value))return!1}else for(;!(L=W.next()).done;){var R=L.value;if(R&&!re(R[1]))return!1}}else return!1;return!0;default:return!1}}function ee(w,O){return w==="symbol"?!0:O?O["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&O instanceof Symbol:!1}function ie(w){var O=typeof w;return Array.isArray(w)?"array":w instanceof RegExp?"object":ee(O,w)?"symbol":O}function ue(w){if(typeof w>"u"||w===null)return""+w;var O=ie(w);if(O==="object"){if(w instanceof Date)return"date";if(w instanceof RegExp)return"regexp"}return O}function Ne(w){var O=ue(w);switch(O){case"array":case"object":return"an "+O;case"boolean":case"date":case"regexp":return"a "+O;default:return O}}function je(w){return!w.constructor||!w.constructor.name?m:w.constructor.name}return y.checkPropTypes=o,y.resetWarningCache=o.resetWarningCache,y.PropTypes=y,y},Kt}var Ht,Ln;function _o(){if(Ln)return Ht;Ln=1;var e=dn();function t(){}function n(){}return n.resetWarningCache=t,Ht=function(){function r(i,a,u,f,d,h){if(h!==e){var m=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 m.name="Invariant Violation",m}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Ht}var Bn;function bo(){if(Bn)return ut.exports;if(Bn=1,process.env.NODE_ENV!=="production"){var e=wr(),t=!0;ut.exports=yo()(e.isElement,t)}else ut.exports=_o()();return ut.exports}var So=bo();const K=fo(So);function kr(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=kr(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Tr(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=kr(e))&&(r&&(r+=" "),r+=t);return r}function wo(e,t,n=void 0){const r={};for(const o in e){const s=e[o];let i="",a=!0;for(let u=0;u<s.length;u+=1){const f=s[u];f&&(i+=(a===!0?"":" ")+t(f),a=!1,n&&n[f]&&(i+=" "+n[f]))}r[o]=i}return r}var dt={exports:{}},G={};/**
|
|
21
|
+
* @license React
|
|
22
|
+
* react-is.production.js
|
|
23
|
+
*
|
|
24
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
25
|
+
*
|
|
26
|
+
* This source code is licensed under the MIT license found in the
|
|
27
|
+
* LICENSE file in the root directory of this source tree.
|
|
28
|
+
*/var Wn;function vo(){if(Wn)return G;Wn=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.consumer"),i=Symbol.for("react.context"),a=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),m=Symbol.for("react.view_transition"),y=Symbol.for("react.client.reference");function g(l){if(typeof l=="object"&&l!==null){var b=l.$$typeof;switch(b){case e:switch(l=l.type,l){case n:case o:case r:case u:case f:case m:return l;default:switch(l=l&&l.$$typeof,l){case i:case a:case h:case d:return l;case s:return l;default:return b}}case t:return b}}}return G.ContextConsumer=s,G.ContextProvider=i,G.Element=e,G.ForwardRef=a,G.Fragment=n,G.Lazy=h,G.Memo=d,G.Portal=t,G.Profiler=o,G.StrictMode=r,G.Suspense=u,G.SuspenseList=f,G.isContextConsumer=function(l){return g(l)===s},G.isContextProvider=function(l){return g(l)===i},G.isElement=function(l){return typeof l=="object"&&l!==null&&l.$$typeof===e},G.isForwardRef=function(l){return g(l)===a},G.isFragment=function(l){return g(l)===n},G.isLazy=function(l){return g(l)===h},G.isMemo=function(l){return g(l)===d},G.isPortal=function(l){return g(l)===t},G.isProfiler=function(l){return g(l)===o},G.isStrictMode=function(l){return g(l)===r},G.isSuspense=function(l){return g(l)===u},G.isSuspenseList=function(l){return g(l)===f},G.isValidElementType=function(l){return typeof l=="string"||typeof l=="function"||l===n||l===o||l===r||l===u||l===f||typeof l=="object"&&l!==null&&(l.$$typeof===h||l.$$typeof===d||l.$$typeof===i||l.$$typeof===s||l.$$typeof===a||l.$$typeof===y||l.getModuleId!==void 0)},G.typeOf=g,G}var J={};/**
|
|
29
|
+
* @license React
|
|
30
|
+
* react-is.development.js
|
|
31
|
+
*
|
|
32
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
33
|
+
*
|
|
34
|
+
* This source code is licensed under the MIT license found in the
|
|
35
|
+
* LICENSE file in the root directory of this source tree.
|
|
36
|
+
*/var Fn;function ko(){return Fn||(Fn=1,process.env.NODE_ENV!=="production"&&function(){function e(l){if(typeof l=="object"&&l!==null){var b=l.$$typeof;switch(b){case t:switch(l=l.type,l){case r:case s:case o:case f:case d:case y:return l;default:switch(l=l&&l.$$typeof,l){case a:case u:case m:case h:return l;case i:return l;default:return b}}case n:return b}}}var t=Symbol.for("react.transitional.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),a=Symbol.for("react.context"),u=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),y=Symbol.for("react.view_transition"),g=Symbol.for("react.client.reference");J.ContextConsumer=i,J.ContextProvider=a,J.Element=t,J.ForwardRef=u,J.Fragment=r,J.Lazy=m,J.Memo=h,J.Portal=n,J.Profiler=s,J.StrictMode=o,J.Suspense=f,J.SuspenseList=d,J.isContextConsumer=function(l){return e(l)===i},J.isContextProvider=function(l){return e(l)===a},J.isElement=function(l){return typeof l=="object"&&l!==null&&l.$$typeof===t},J.isForwardRef=function(l){return e(l)===u},J.isFragment=function(l){return e(l)===r},J.isLazy=function(l){return e(l)===m},J.isMemo=function(l){return e(l)===h},J.isPortal=function(l){return e(l)===n},J.isProfiler=function(l){return e(l)===s},J.isStrictMode=function(l){return e(l)===o},J.isSuspense=function(l){return e(l)===f},J.isSuspenseList=function(l){return e(l)===d},J.isValidElementType=function(l){return typeof l=="string"||typeof l=="function"||l===r||l===s||l===o||l===f||l===d||typeof l=="object"&&l!==null&&(l.$$typeof===m||l.$$typeof===h||l.$$typeof===a||l.$$typeof===i||l.$$typeof===u||l.$$typeof===g||l.getModuleId!==void 0)},J.typeOf=e}()),J}var Vn;function To(){return Vn||(Vn=1,process.env.NODE_ENV==="production"?dt.exports=vo():dt.exports=ko()),dt.exports}var vt=To();function ve(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 Er(e){if(Se.isValidElement(e)||vt.isValidElementType(e)||!ve(e))return e;const t={};return Object.keys(e).forEach(n=>{t[n]=Er(e[n])}),t}function de(e,t,n={clone:!0}){const r=n.clone?{...e}:e;return ve(e)&&ve(t)&&Object.keys(t).forEach(o=>{Se.isValidElement(t[o])||vt.isValidElementType(t[o])?r[o]=t[o]:ve(t[o])&&Object.prototype.hasOwnProperty.call(e,o)&&ve(e[o])?r[o]=de(e[o],t[o],n):n.clone?r[o]=ve(t[o])?Er(t[o]):t[o]:r[o]=t[o]}),r}function et(e,t){return t?de(e,t,{clone:!1}):e}const Pe=process.env.NODE_ENV!=="production"?K.oneOfType([K.number,K.string,K.object,K.array]):{};function Un(e,t){if(!e.containerQueries)return t;const n=Object.keys(t).filter(r=>r.startsWith("@container")).sort((r,o)=>{var i,a;const s=/min-width:\s*([0-9.]+)/;return+(((i=r.match(s))==null?void 0:i[1])||0)-+(((a=o.match(s))==null?void 0:a[1])||0)});return n.length?n.reduce((r,o)=>{const s=t[o];return delete r[o],r[o]=s,r},{...t}):t}function Eo(e,t){return t==="@"||t.startsWith("@")&&(e.some(n=>t.startsWith(`@${n}`))||!!t.match(/^@\d/))}function Ao(e,t){const n=t.match(/^@([^/]+)?\/?(.+)?$/);if(!n){if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The provided shorthand ${`(${t})`} is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.
|
|
37
|
+
For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:Oe(18,`(${t})`));return null}const[,r,o]=n,s=Number.isNaN(+r)?r||0:+r;return e.containerQueries(o).up(s)}function Co(e){const t=(s,i)=>s.replace("@media",i?`@container ${i}`:"@container");function n(s,i){s.up=(...a)=>t(e.breakpoints.up(...a),i),s.down=(...a)=>t(e.breakpoints.down(...a),i),s.between=(...a)=>t(e.breakpoints.between(...a),i),s.only=(...a)=>t(e.breakpoints.only(...a),i),s.not=(...a)=>{const u=t(e.breakpoints.not(...a),i);return u.includes("not all and")?u.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):u}}const r={},o=s=>(n(r,s),r);return n(o),{...e,containerQueries:o}}const Pt={xs:0,sm:600,md:900,lg:1200,xl:1536},zn={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${Pt[e]}px)`},Oo={containerQueries:e=>({up:t=>{let n=typeof t=="number"?t:Pt[t]||t;return typeof n=="number"&&(n=`${n}px`),e?`@container ${e} (min-width:${n})`:`@container (min-width:${n})`}})};function Te(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||zn;return t.reduce((i,a,u)=>(i[s.up(s.keys[u])]=n(t[u]),i),{})}if(typeof t=="object"){const s=r.breakpoints||zn;return Object.keys(t).reduce((i,a)=>{if(Eo(s.keys,a)){const u=Ao(r.containerQueries?r:Oo,a);u&&(i[u]=n(t[a],a))}else if(Object.keys(s.values||Pt).includes(a)){const u=s.up(a);i[u]=n(t[a],a)}else{const u=a;i[u]=t[u]}return i},{})}return n(t)}function xo(e={}){var n;return((n=e.keys)==null?void 0:n.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function Kn(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function Nt(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function kt(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=Nt(e,n)||r,t&&(o=t(o,r,e)),o}function oe(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const a=i[t],u=i.theme,f=Nt(u,r)||{};return Te(i,a,h=>{let m=kt(f,o,h);return h===m&&typeof h=="string"&&(m=kt(f,o,`${t}${h==="default"?"":De(h)}`,h)),n===!1?m:{[n]:m}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:Pe}:{},s.filterProps=[t],s}function Po(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const No={m:"margin",p:"padding"},Io={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Hn={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},$o=Po(e=>{if(e.length>2)if(Hn[e])e=Hn[e];else return[e];const[t,n]=e.split(""),r=No[t],o=Io[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),It=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],$t=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Ro=[...It,...$t];function it(e,t,n,r){const o=Nt(e,t,!0)??n;return typeof o=="number"||typeof o=="string"?s=>typeof s=="string"?s:(process.env.NODE_ENV!=="production"&&typeof s!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${s}.`),typeof o=="string"?o.startsWith("var(")&&s===0?0:o.startsWith("var(")&&s===1?o:`calc(${s} * ${o})`:o*s):Array.isArray(o)?s=>{if(typeof s=="string")return s;const i=Math.abs(s);process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>o.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(o)}.`,`${i} > ${o.length-1}, you need to add the missing values.`].join(`
|
|
38
|
+
`)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(`
|
|
39
|
+
`)));const a=o[i];return s>=0?a:typeof a=="number"?-a:typeof a=="string"&&a.startsWith("var(")?`calc(-1 * ${a})`:`-${a}`}:typeof o=="function"?o:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${o}) is invalid.`,"It should be a number, an array or a function."].join(`
|
|
40
|
+
`)),()=>{})}function hn(e){return it(e,"spacing",8,"spacing")}function at(e,t){return typeof t=="string"||t==null?t:e(t)}function Do(e,t){return n=>e.reduce((r,o)=>(r[o]=at(t,n),r),{})}function jo(e,t,n,r){if(!t.includes(n))return null;const o=$o(n),s=Do(o,r),i=e[n];return Te(e,i,s)}function Ar(e,t){const n=hn(e.theme);return Object.keys(e).map(r=>jo(e,t,r,n)).reduce(et,{})}function te(e){return Ar(e,It)}te.propTypes=process.env.NODE_ENV!=="production"?It.reduce((e,t)=>(e[t]=Pe,e),{}):{};te.filterProps=It;function ne(e){return Ar(e,$t)}ne.propTypes=process.env.NODE_ENV!=="production"?$t.reduce((e,t)=>(e[t]=Pe,e),{}):{};ne.filterProps=$t;process.env.NODE_ENV!=="production"&&Ro.reduce((e,t)=>(e[t]=Pe,e),{});function Rt(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?et(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function me(e){return typeof e!="number"?e:`${e}px solid`}function ye(e,t){return oe({prop:e,themeKey:"borders",transform:t})}const Mo=ye("border",me),Lo=ye("borderTop",me),Bo=ye("borderRight",me),Wo=ye("borderBottom",me),Fo=ye("borderLeft",me),Vo=ye("borderColor"),Uo=ye("borderTopColor"),zo=ye("borderRightColor"),Ko=ye("borderBottomColor"),Ho=ye("borderLeftColor"),Yo=ye("outline",me),qo=ye("outlineColor"),Dt=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=it(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:at(t,r)});return Te(e,e.borderRadius,n)}return null};Dt.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:Pe}:{};Dt.filterProps=["borderRadius"];Rt(Mo,Lo,Bo,Wo,Fo,Vo,Uo,zo,Ko,Ho,Dt,Yo,qo);const jt=e=>{if(e.gap!==void 0&&e.gap!==null){const t=it(e.theme,"spacing",8,"gap"),n=r=>({gap:at(t,r)});return Te(e,e.gap,n)}return null};jt.propTypes=process.env.NODE_ENV!=="production"?{gap:Pe}:{};jt.filterProps=["gap"];const Mt=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=it(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:at(t,r)});return Te(e,e.columnGap,n)}return null};Mt.propTypes=process.env.NODE_ENV!=="production"?{columnGap:Pe}:{};Mt.filterProps=["columnGap"];const Lt=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=it(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:at(t,r)});return Te(e,e.rowGap,n)}return null};Lt.propTypes=process.env.NODE_ENV!=="production"?{rowGap:Pe}:{};Lt.filterProps=["rowGap"];const Go=oe({prop:"gridColumn"}),Jo=oe({prop:"gridRow"}),Xo=oe({prop:"gridAutoFlow"}),Qo=oe({prop:"gridAutoColumns"}),Zo=oe({prop:"gridAutoRows"}),es=oe({prop:"gridTemplateColumns"}),ts=oe({prop:"gridTemplateRows"}),ns=oe({prop:"gridTemplateAreas"}),rs=oe({prop:"gridArea"});Rt(jt,Mt,Lt,Go,Jo,Xo,Qo,Zo,es,ts,ns,rs);function Ye(e,t){return t==="grey"?t:e}const os=oe({prop:"color",themeKey:"palette",transform:Ye}),ss=oe({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Ye}),is=oe({prop:"backgroundColor",themeKey:"palette",transform:Ye});Rt(os,ss,is);function fe(e){return e<=1&&e!==0?`${e*100}%`:e}const as=oe({prop:"width",transform:fe}),mn=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var o,s,i,a,u;const r=((i=(s=(o=e.theme)==null?void 0:o.breakpoints)==null?void 0:s.values)==null?void 0:i[n])||Pt[n];return r?((u=(a=e.theme)==null?void 0:a.breakpoints)==null?void 0:u.unit)!=="px"?{maxWidth:`${r}${e.theme.breakpoints.unit}`}:{maxWidth:r}:{maxWidth:fe(n)}};return Te(e,e.maxWidth,t)}return null};mn.filterProps=["maxWidth"];const cs=oe({prop:"minWidth",transform:fe}),ls=oe({prop:"height",transform:fe}),us=oe({prop:"maxHeight",transform:fe}),fs=oe({prop:"minHeight",transform:fe});oe({prop:"size",cssProperty:"width",transform:fe});oe({prop:"size",cssProperty:"height",transform:fe});const ds=oe({prop:"boxSizing"});Rt(as,mn,cs,ls,us,fs,ds);const Bt={border:{themeKey:"borders",transform:me},borderTop:{themeKey:"borders",transform:me},borderRight:{themeKey:"borders",transform:me},borderBottom:{themeKey:"borders",transform:me},borderLeft:{themeKey:"borders",transform:me},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:me},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Dt},color:{themeKey:"palette",transform:Ye},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Ye},backgroundColor:{themeKey:"palette",transform:Ye},p:{style:ne},pt:{style:ne},pr:{style:ne},pb:{style:ne},pl:{style:ne},px:{style:ne},py:{style:ne},padding:{style:ne},paddingTop:{style:ne},paddingRight:{style:ne},paddingBottom:{style:ne},paddingLeft:{style:ne},paddingX:{style:ne},paddingY:{style:ne},paddingInline:{style:ne},paddingInlineStart:{style:ne},paddingInlineEnd:{style:ne},paddingBlock:{style:ne},paddingBlockStart:{style:ne},paddingBlockEnd:{style:ne},m:{style:te},mt:{style:te},mr:{style:te},mb:{style:te},ml:{style:te},mx:{style:te},my:{style:te},margin:{style:te},marginTop:{style:te},marginRight:{style:te},marginBottom:{style:te},marginLeft:{style:te},marginX:{style:te},marginY:{style:te},marginInline:{style:te},marginInlineStart:{style:te},marginInlineEnd:{style:te},marginBlock:{style:te},marginBlockStart:{style:te},marginBlockEnd:{style:te},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:jt},rowGap:{style:Lt},columnGap:{style:Mt},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:fe},maxWidth:{style:mn},minWidth:{transform:fe},height:{transform:fe},maxHeight:{transform:fe},minHeight:{transform:fe},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function hs(...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 ms(e,t){return typeof e=="function"?e(t):e}function gs(){function e(n,r,o,s){const i={[n]:r,theme:o},a=s[n];if(!a)return{[n]:r};const{cssProperty:u=n,themeKey:f,transform:d,style:h}=a;if(r==null)return null;if(f==="typography"&&r==="inherit")return{[n]:r};const m=Nt(o,f)||{};return h?h(i):Te(i,r,g=>{let l=kt(m,d,g);return g===l&&typeof g=="string"&&(l=kt(m,d,`${n}${g==="default"?"":De(g)}`,g)),u===!1?l:{[u]:l}})}function t(n){const{sx:r,theme:o={},nested:s}=n||{};if(!r)return null;const i=o.unstable_sxConfig??Bt;function a(u){let f=u;if(typeof u=="function")f=u(o);else if(typeof u!="object")return u;if(!f)return null;const d=xo(o.breakpoints),h=Object.keys(d);let m=d;return Object.keys(f).forEach(y=>{const g=ms(f[y],o);if(g!=null)if(typeof g=="object")if(i[y])m=et(m,e(y,g,o,i));else{const l=Te({theme:o},g,b=>({[y]:b}));hs(l,g)?m[y]=t({sx:g,theme:o,nested:!0}):m=et(m,l)}else m=et(m,e(y,g,o,i))}),!s&&o.modularCssLayers?{"@layer sx":Un(o,Kn(h,m))}:Un(o,Kn(h,m))}return Array.isArray(r)?r.map(a):a(r)}return t}const qe=gs();qe.filterProps=["sx"];function ps(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 ys={animationIterationCount:1,aspectRatio: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,scale: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};function _s(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var bs=/[A-Z]|^ms/g,Ss=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Cr=function(t){return t.charCodeAt(1)===45},Yn=function(t){return t!=null&&typeof t!="boolean"},Yt=_s(function(e){return Cr(e)?e:e.replace(bs,"-$&").toLowerCase()}),qn=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(Ss,function(r,o,s){return Ce={name:o,styles:s,next:Ce},o})}return ys[t]!==1&&!Cr(t)&&typeof n=="number"&&n!==0?n+"px":n};function Tt(e,t,n){if(n==null)return"";var r=n;if(r.__emotion_styles!==void 0)return r;switch(typeof n){case"boolean":return"";case"object":{var o=n;if(o.anim===1)return Ce={name:o.name,styles:o.styles,next:Ce},o.name;var s=n;if(s.styles!==void 0){var i=s.next;if(i!==void 0)for(;i!==void 0;)Ce={name:i.name,styles:i.styles,next:Ce},i=i.next;var a=s.styles+";";return a}return ws(e,t,n)}}var u=n;return u}function ws(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=Tt(e,t,n[o])+";";else for(var s in n){var i=n[s];if(typeof i!="object"){var a=i;Yn(a)&&(r+=Yt(s)+":"+qn(s,a)+";")}else if(Array.isArray(i)&&typeof i[0]=="string"&&t==null)for(var u=0;u<i.length;u++)Yn(i[u])&&(r+=Yt(s)+":"+qn(s,i[u])+";");else{var f=Tt(e,t,i);switch(s){case"animation":case"animationName":{r+=Yt(s)+":"+f+";";break}default:r+=s+"{"+f+"}"}}}return r}var Gn=/label:\s*([^\s;{]+)\s*(;|$)/g,Ce;function vs(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var r=!0,o="";Ce=void 0;var s=e[0];if(s==null||s.raw===void 0)r=!1,o+=Tt(n,t,s);else{var i=s;o+=i[0]}for(var a=1;a<e.length;a++)if(o+=Tt(n,t,e[a]),r){var u=s;o+=u[a]}Gn.lastIndex=0;for(var f="",d;(d=Gn.exec(o))!==null;)f+="-"+d[1];var h=ps(o)+f;return{name:h,styles:o,next:Ce}}/**
|
|
41
|
+
* @mui/styled-engine v7.2.0
|
|
42
|
+
*
|
|
43
|
+
* @license MIT
|
|
44
|
+
* This source code is licensed under the MIT license found in the
|
|
45
|
+
* LICENSE file in the root directory of this source tree.
|
|
46
|
+
*/function ks(e,t){const n=io(e,t);return process.env.NODE_ENV!=="production"?(...r)=>{const o=typeof e=="string"?`"${e}"`:"component";return r.length===0?console.error([`MUI: Seems like you called \`styled(${o})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
|
|
47
|
+
`)):r.some(s=>s===void 0)&&console.error(`MUI: the styled(${o})(...args) API requires all its args to be defined.`),n(...r)}:n}function Ts(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const Jn=[];function Re(e){return Jn[0]=e,vs(Jn)}const Es=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)=>({...n,[r.key]:r.val}),{})};function As(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5,...o}=e,s=Es(t),i=Object.keys(s);function a(m){return`@media (min-width:${typeof t[m]=="number"?t[m]:m}${n})`}function u(m){return`@media (max-width:${(typeof t[m]=="number"?t[m]:m)-r/100}${n})`}function f(m,y){const g=i.indexOf(y);return`@media (min-width:${typeof t[m]=="number"?t[m]:m}${n}) and (max-width:${(g!==-1&&typeof t[i[g]]=="number"?t[i[g]]:y)-r/100}${n})`}function d(m){return i.indexOf(m)+1<i.length?f(m,i[i.indexOf(m)+1]):a(m)}function h(m){const y=i.indexOf(m);return y===0?a(i[1]):y===i.length-1?u(i[y]):f(m,i[i.indexOf(m)+1]).replace("@media","@media not all and")}return{keys:i,values:s,up:a,down:u,between:f,only:d,not:h,unit:n,...o}}const Cs={borderRadius:4};function Or(e=8,t=hn({spacing:e})){if(e.mui)return e;const n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function Os(e,t){var r;const n=this;if(n.vars){if(!((r=n.colorSchemes)!=null&&r[e])||typeof n.getColorSchemeSelector!="function")return{};let o=n.getColorSchemeSelector(e);return o==="&"?t:((o.includes("data-")||o.includes("."))&&(o=`*:where(${o.replace(/\s*&$/,"")}) &`),{[o]:t})}return n.palette.mode===e?t:{}}function gn(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={},...i}=e,a=As(n),u=Or(o);let f=de({breakpoints:a,direction:"ltr",components:{},palette:{mode:"light",...r},spacing:u,shape:{...Cs,...s}},i);return f=Co(f),f.applyStyles=Os,f=t.reduce((d,h)=>de(d,h),f),f.unstable_sxConfig={...Bt,...i==null?void 0:i.unstable_sxConfig},f.unstable_sx=function(h){return qe({sx:h,theme:this})},f}function xs(e){return Object.keys(e).length===0}function Ps(e=null){const t=Se.useContext(ao.ThemeContext);return!t||xs(t)?e:t}const Ns=gn();function Is(e=Ns){return Ps(e)}const $s={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function pn(e,t,n="Mui"){const r=$s[t];return r?`${n}-${r}`:`${uo.generate(e)}-${t}`}function Rs(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=pn(e,o,n)}),r}function xr(e,t=""){return e.displayName||e.name||t}function Xn(e,t,n){const r=xr(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Ds(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return xr(e,"Component");if(typeof e=="object")switch(e.$$typeof){case vt.ForwardRef:return Xn(e,e.render,"ForwardRef");case vt.Memo:return Xn(e,e.type,"memo");default:return}}}function Pr(e){const{variants:t,...n}=e,r={variants:t,style:Re(n),isProcessed:!0};return r.style===n||t&&t.forEach(o=>{typeof o.style!="function"&&(o.style=Re(o.style))}),r}const js=gn();function qt(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function Ie(e,t){return t&&e&&typeof e=="object"&&e.styles&&!e.styles.startsWith("@layer")&&(e.styles=`@layer ${t}{${String(e.styles)}}`),e}function Ms(e){return e?(t,n)=>n[e]:null}function Ls(e,t,n){e.theme=Vs(e.theme)?n:e.theme[t]||e.theme}function gt(e,t,n){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(o=>gt(e,o,n));if(Array.isArray(r==null?void 0:r.variants)){let o;if(r.isProcessed)o=n?Ie(r.style,n):r.style;else{const{variants:s,...i}=r;o=n?Ie(Re(i),n):i}return Nr(e,r.variants,[o],n)}return r!=null&&r.isProcessed?n?Ie(Re(r.style),n):r.style:n?Ie(Re(r),n):r}function Nr(e,t,n=[],r=void 0){var s;let o;e:for(let i=0;i<t.length;i+=1){const a=t[i];if(typeof a.props=="function"){if(o??(o={...e,...e.ownerState,ownerState:e.ownerState}),!a.props(o))continue}else for(const u in a.props)if(e[u]!==a.props[u]&&((s=e.ownerState)==null?void 0:s[u])!==a.props[u])continue e;typeof a.style=="function"?(o??(o={...e,...e.ownerState,ownerState:e.ownerState}),n.push(r?Ie(Re(a.style(o)),r):a.style(o))):n.push(r?Ie(Re(a.style),r):a.style)}return n}function Bs(e={}){const{themeId:t,defaultTheme:n=js,rootShouldForwardProp:r=qt,slotShouldForwardProp:o=qt}=e;function s(a){Ls(a,t,n)}return(a,u={})=>{Ts(a,N=>N.filter(v=>v!==qe));const{name:f,slot:d,skipVariantsResolver:h,skipSx:m,overridesResolver:y=Ms(Ir(d)),...g}=u,l=f&&f.startsWith("Mui")||d?"components":"custom",b=h!==void 0?h:d&&d!=="Root"&&d!=="root"||!1,k=m||!1;let x=qt;d==="Root"||d==="root"?x=r:d?x=o:Us(a)&&(x=void 0);const E=ks(a,{shouldForwardProp:x,label:Fs(f,d),...g}),T=N=>{if(N.__emotion_real===N)return N;if(typeof N=="function")return function(I){return gt(I,N,I.theme.modularCssLayers?l:void 0)};if(ve(N)){const v=Pr(N);return function(F){return v.variants?gt(F,v,F.theme.modularCssLayers?l:void 0):F.theme.modularCssLayers?Ie(v.style,l):v.style}}return N},_=(...N)=>{const v=[],I=N.map(T),F=[];if(v.push(s),f&&y&&F.push(function(M){var ue,Ne;const ee=(Ne=(ue=M.theme.components)==null?void 0:ue[f])==null?void 0:Ne.styleOverrides;if(!ee)return null;const ie={};for(const je in ee)ie[je]=gt(M,ee[je],M.theme.modularCssLayers?"theme":void 0);return y(M,ie)}),f&&!b&&F.push(function(M){var ie,ue;const re=M.theme,ee=(ue=(ie=re==null?void 0:re.components)==null?void 0:ie[f])==null?void 0:ue.variants;return ee?Nr(M,ee,[],M.theme.modularCssLayers?"theme":void 0):null}),k||F.push(qe),Array.isArray(I[0])){const P=I.shift(),M=new Array(v.length).fill(""),re=new Array(F.length).fill("");let ee;ee=[...M,...P,...re],ee.raw=[...M,...P.raw,...re],v.unshift(ee)}const c=[...v,...I,...F],A=E(...c);return a.muiName&&(A.muiName=a.muiName),process.env.NODE_ENV!=="production"&&(A.displayName=Ws(f,d,a)),A};return E.withConfig&&(_.withConfig=E.withConfig),_}}function Ws(e,t,n){return e?`${e}${De(t||"")}`:`Styled(${Ds(n)})`}function Fs(e,t){let n;return process.env.NODE_ENV!=="production"&&e&&(n=`${e}-${Ir(t||"Root")}`),n}function Vs(e){for(const t in e)return!1;return!0}function Us(e){return typeof e=="string"&&e.charCodeAt(0)>96}function Ir(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}function nn(e,t,n=!1){const r={...t};for(const o in e)if(Object.prototype.hasOwnProperty.call(e,o)){const s=o;if(s==="components"||s==="slots")r[s]={...e[s],...r[s]};else if(s==="componentsProps"||s==="slotProps"){const i=e[s],a=t[s];if(!a)r[s]=i||{};else if(!i)r[s]=a;else{r[s]={...a};for(const u in i)if(Object.prototype.hasOwnProperty.call(i,u)){const f=u;r[s][f]=nn(i[f],a[f],n)}}}else s==="className"&&n&&t.className?r.className=Tr(e==null?void 0:e.className,t==null?void 0:t.className):s==="style"&&n&&t.style?r.style={...e==null?void 0:e.style,...t==null?void 0:t.style}:r[s]===void 0&&(r[s]=e[s])}return r}function zs(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function yn(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(e<t||e>n)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),zs(e,t,n)}function Ks(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)),process.env.NODE_ENV!=="production"&&e.length!==e.trim().length&&console.error(`MUI: The color: "${e}" is invalid. Make sure the color input doesn't contain leading/trailing space.`),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 xe(e){if(e.type)return e;if(e.charAt(0)==="#")return xe(Ks(e));const t=e.indexOf("("),n=e.substring(0,t);if(!["rgb","rgba","hsl","hsla","color"].includes(n))throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
|
|
48
|
+
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:Oe(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"].includes(o))throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space.
|
|
49
|
+
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:Oe(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}const Hs=e=>{const t=xe(e);return t.values.slice(0,3).map((n,r)=>t.type.includes("hsl")&&r!==0?`${n}%`:n).join(" ")},Qe=(e,t)=>{try{return Hs(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function Wt(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.includes("rgb")?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.includes("hsl")&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.includes("color")?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function $r(e){e=xe(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(f,d=(f+n/30)%12)=>o-s*Math.max(Math.min(d-3,9-d,1),-1);let a="rgb";const u=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(a+="a",u.push(t[3])),Wt({type:a,values:u})}function rn(e){e=xe(e);let t=e.type==="hsl"||e.type==="hsla"?xe($r(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 Qn(e,t){const n=rn(e),r=rn(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function Ys(e,t){return e=xe(e),t=yn(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,Wt(e)}function ht(e,t,n){try{return Ys(e,t)}catch{return e}}function _n(e,t){if(e=xe(e),t=yn(t),e.type.includes("hsl"))e.values[2]*=1-t;else if(e.type.includes("rgb")||e.type.includes("color"))for(let n=0;n<3;n+=1)e.values[n]*=1-t;return Wt(e)}function X(e,t,n){try{return _n(e,t)}catch{return e}}function bn(e,t){if(e=xe(e),t=yn(t),e.type.includes("hsl"))e.values[2]+=(100-e.values[2])*t;else if(e.type.includes("rgb"))for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.includes("color"))for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return Wt(e)}function Q(e,t,n){try{return bn(e,t)}catch{return e}}function qs(e,t=.15){return rn(e)>.5?_n(e,t):bn(e,t)}function mt(e,t,n){try{return qs(e,t)}catch{return e}}const Gs=Se.createContext(void 0);process.env.NODE_ENV!=="production"&&(K.node,K.object);function Js(e){const{theme:t,name:n,props:r}=e;if(!t||!t.components||!t.components[n])return r;const o=t.components[n];return o.defaultProps?nn(o.defaultProps,r,t.components.mergeClassNameAndStyle):!o.styleOverrides&&!o.variants?nn(o,r,t.components.mergeClassNameAndStyle):r}function Xs({props:e,name:t}){const n=Se.useContext(Gs);return Js({props:e,name:t,theme:{components:n}})}const Zn={theme:void 0};function Qs(e){let t,n;return function(o){let s=t;return(s===void 0||o.theme!==n)&&(Zn.theme=o.theme,s=Pr(e(Zn)),t=s,n=o.theme),s}}function Zs(e=""){function t(...r){if(!r.length)return"";const o=r[0];return typeof o=="string"&&!o.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, var(--${e?`${e}-`:""}${o}${t(...r.slice(1))})`:`, ${o}`}return(r,...o)=>`var(--${e?`${e}-`:""}${r}${t(...o)})`}const er=(e,t,n,r=[])=>{let o=e;t.forEach((s,i)=>{i===t.length-1?Array.isArray(o)?o[Number(s)]=n:o&&typeof o=="object"&&(o[s]=n):o&&typeof o=="object"&&(o[s]||(o[s]=r.includes(s)?[]:{}),o=o[s])})},ei=(e,t,n)=>{function r(o,s=[],i=[]){Object.entries(o).forEach(([a,u])=>{(!n||n&&!n([...s,a]))&&u!=null&&(typeof u=="object"&&Object.keys(u).length>0?r(u,[...s,a],Array.isArray(u)?[...i,a]:i):t([...s,a],u,i))})}r(e)},ti=(e,t)=>typeof t=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(r=>e.includes(r))||e[e.length-1].toLowerCase().includes("opacity")?t:`${t}px`:t;function Gt(e,t){const{prefix:n,shouldSkipGeneratingVar:r}=t||{},o={},s={},i={};return ei(e,(a,u,f)=>{if((typeof u=="string"||typeof u=="number")&&(!r||!r(a,u))){const d=`--${n?`${n}-`:""}${a.join("-")}`,h=ti(a,u);Object.assign(o,{[d]:h}),er(s,a,`var(${d})`,f),er(i,a,`var(${d}, ${h})`,f)}},a=>a[0]==="vars"),{css:o,vars:s,varsWithDefaults:i}}function ni(e,t={}){const{getSelector:n=b,disableCssColorScheme:r,colorSchemeSelector:o}=t,{colorSchemes:s={},components:i,defaultColorScheme:a="light",...u}=e,{vars:f,css:d,varsWithDefaults:h}=Gt(u,t);let m=h;const y={},{[a]:g,...l}=s;if(Object.entries(l||{}).forEach(([E,T])=>{const{vars:_,css:N,varsWithDefaults:v}=Gt(T,t);m=de(m,v),y[E]={css:N,vars:_}}),g){const{css:E,vars:T,varsWithDefaults:_}=Gt(g,t);m=de(m,_),y[a]={css:E,vars:T}}function b(E,T){var N,v;let _=o;if(o==="class"&&(_=".%s"),o==="data"&&(_="[data-%s]"),o!=null&&o.startsWith("data-")&&!o.includes("%s")&&(_=`[${o}="%s"]`),E){if(_==="media")return e.defaultColorScheme===E?":root":{[`@media (prefers-color-scheme: ${((v=(N=s[E])==null?void 0:N.palette)==null?void 0:v.mode)||E})`]:{":root":T}};if(_)return e.defaultColorScheme===E?`:root, ${_.replace("%s",String(E))}`:_.replace("%s",String(E))}return":root"}return{vars:m,generateThemeVars:()=>{let E={...f};return Object.entries(y).forEach(([,{vars:T}])=>{E=de(E,T)}),E},generateStyleSheets:()=>{var I,F;const E=[],T=e.defaultColorScheme||"light";function _(c,A){Object.keys(A).length&&E.push(typeof c=="string"?{[c]:{...A}}:c)}_(n(void 0,{...d}),d);const{[T]:N,...v}=y;if(N){const{css:c}=N,A=(F=(I=s[T])==null?void 0:I.palette)==null?void 0:F.mode,P=!r&&A?{colorScheme:A,...c}:{...c};_(n(T,{...P}),P)}return Object.entries(v).forEach(([c,{css:A}])=>{var re,ee;const P=(ee=(re=s[c])==null?void 0:re.palette)==null?void 0:ee.mode,M=!r&&P?{colorScheme:P,...A}:{...A};_(n(c,{...M}),M)}),E}}}function ri(e){return function(n){return e==="media"?(process.env.NODE_ENV!=="production"&&n!=="light"&&n!=="dark"&&console.error(`MUI: @media (prefers-color-scheme) supports only 'light' or 'dark', but receive '${n}'.`),`@media (prefers-color-scheme: ${n})`):e?e.startsWith("data-")&&!e.includes("%s")?`[${e}="${n}"] &`:e==="class"?`.${n} &`:e==="data"?`[data-${n}] &`:`${e.replace("%s",n)} &`:"&"}}const nt={black:"#000",white:"#fff"},oi={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"},Le={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},Be={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},Je={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},We={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},Fe={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},Ve={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function Rr(){return{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:nt.white,default:nt.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}}}const si=Rr();function Dr(){return{text:{primary:nt.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:nt.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}}}const tr=Dr();function nr(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=bn(e.main,o):t==="dark"&&(e.dark=_n(e.main,s)))}function ii(e="light"){return e==="dark"?{main:We[200],light:We[50],dark:We[400]}:{main:We[700],light:We[400],dark:We[800]}}function ai(e="light"){return e==="dark"?{main:Le[200],light:Le[50],dark:Le[400]}:{main:Le[500],light:Le[300],dark:Le[700]}}function ci(e="light"){return e==="dark"?{main:Be[500],light:Be[300],dark:Be[700]}:{main:Be[700],light:Be[400],dark:Be[800]}}function li(e="light"){return e==="dark"?{main:Fe[400],light:Fe[300],dark:Fe[700]}:{main:Fe[700],light:Fe[500],dark:Fe[900]}}function ui(e="light"){return e==="dark"?{main:Ve[400],light:Ve[300],dark:Ve[700]}:{main:Ve[800],light:Ve[500],dark:Ve[900]}}function fi(e="light"){return e==="dark"?{main:Je[400],light:Je[300],dark:Je[700]}:{main:"#ed6c02",light:Je[500],dark:Je[900]}}function Sn(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2,...o}=e,s=e.primary||ii(t),i=e.secondary||ai(t),a=e.error||ci(t),u=e.info||li(t),f=e.success||ui(t),d=e.warning||fi(t);function h(l){const b=Qn(l,tr.text.primary)>=n?tr.text.primary:si.text.primary;if(process.env.NODE_ENV!=="production"){const k=Qn(l,b);k<3&&console.error([`MUI: The contrast ratio of ${k}:1 for ${b} on ${l}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(`
|
|
50
|
+
`))}return b}const m=({color:l,name:b,mainShade:k=500,lightShade:x=300,darkShade:E=700})=>{if(l={...l},!l.main&&l[k]&&(l.main=l[k]),!l.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${b?` (${b})`:""} provided to augmentColor(color) is invalid.
|
|
51
|
+
The color object needs to have a \`main\` property or a \`${k}\` property.`:Oe(11,b?` (${b})`:"",k));if(typeof l.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${b?` (${b})`:""} provided to augmentColor(color) is invalid.
|
|
52
|
+
\`color.main\` should be a string, but \`${JSON.stringify(l.main)}\` was provided instead.
|
|
53
|
+
|
|
54
|
+
Did you intend to use one of the following approaches?
|
|
55
|
+
|
|
56
|
+
import { green } from "@mui/material/colors";
|
|
57
|
+
|
|
58
|
+
const theme1 = createTheme({ palette: {
|
|
59
|
+
primary: green,
|
|
60
|
+
} });
|
|
61
|
+
|
|
62
|
+
const theme2 = createTheme({ palette: {
|
|
63
|
+
primary: { main: green[500] },
|
|
64
|
+
} });`:Oe(12,b?` (${b})`:"",JSON.stringify(l.main)));return nr(l,"light",x,r),nr(l,"dark",E,r),l.contrastText||(l.contrastText=h(l.main)),l};let y;return t==="light"?y=Rr():t==="dark"&&(y=Dr()),process.env.NODE_ENV!=="production"&&(y||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),de({common:{...nt},mode:t,primary:m({color:s,name:"primary"}),secondary:m({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:m({color:a,name:"error"}),warning:m({color:d,name:"warning"}),info:m({color:u,name:"info"}),success:m({color:f,name:"success"}),grey:oi,contrastThreshold:n,getContrastText:h,augmentColor:m,tonalOffset:r,...y},o)}function di(e){const t={};return Object.entries(e).forEach(r=>{const[o,s]=r;typeof s=="object"&&(t[o]=`${s.fontStyle?`${s.fontStyle} `:""}${s.fontVariant?`${s.fontVariant} `:""}${s.fontWeight?`${s.fontWeight} `:""}${s.fontStretch?`${s.fontStretch} `:""}${s.fontSize||""}${s.lineHeight?`/${s.lineHeight} `:""}${s.fontFamily||""}`)}),t}function hi(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function mi(e){return Math.round(e*1e5)/1e5}const rr={textTransform:"uppercase"},or='"Roboto", "Helvetica", "Arial", sans-serif';function gi(e,t){const{fontFamily:n=or,fontSize:r=14,fontWeightLight:o=300,fontWeightRegular:s=400,fontWeightMedium:i=500,fontWeightBold:a=700,htmlFontSize:u=16,allVariants:f,pxToRem:d,...h}=typeof t=="function"?t(e):t;process.env.NODE_ENV!=="production"&&(typeof r!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof u!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const m=r/14,y=d||(b=>`${b/u*m}rem`),g=(b,k,x,E,T)=>({fontFamily:n,fontWeight:b,fontSize:y(k),lineHeight:x,...n===or?{letterSpacing:`${mi(E/k)}em`}:{},...T,...f}),l={h1:g(o,96,1.167,-1.5),h2:g(o,60,1.2,-.5),h3:g(s,48,1.167,0),h4:g(s,34,1.235,.25),h5:g(s,24,1.334,0),h6:g(i,20,1.6,.15),subtitle1:g(s,16,1.75,.15),subtitle2:g(i,14,1.57,.1),body1:g(s,16,1.5,.15),body2:g(s,14,1.43,.15),button:g(i,14,1.75,.4,rr),caption:g(s,12,1.66,.4),overline:g(s,12,2.66,1,rr),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return de({htmlFontSize:u,pxToRem:y,fontFamily:n,fontSize:r,fontWeightLight:o,fontWeightRegular:s,fontWeightMedium:i,fontWeightBold:a,...l},h,{clone:!1})}const pi=.2,yi=.14,_i=.12;function Z(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${pi})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${yi})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${_i})`].join(",")}const bi=["none",Z(0,2,1,-1,0,1,1,0,0,1,3,0),Z(0,3,1,-2,0,2,2,0,0,1,5,0),Z(0,3,3,-2,0,3,4,0,0,1,8,0),Z(0,2,4,-1,0,4,5,0,0,1,10,0),Z(0,3,5,-1,0,5,8,0,0,1,14,0),Z(0,3,5,-1,0,6,10,0,0,1,18,0),Z(0,4,5,-2,0,7,10,1,0,2,16,1),Z(0,5,5,-3,0,8,10,1,0,3,14,2),Z(0,5,6,-3,0,9,12,1,0,3,16,2),Z(0,6,6,-3,0,10,14,1,0,4,18,3),Z(0,6,7,-4,0,11,15,1,0,4,20,3),Z(0,7,8,-4,0,12,17,2,0,5,22,4),Z(0,7,8,-4,0,13,19,2,0,5,24,4),Z(0,7,9,-4,0,14,21,2,0,5,26,4),Z(0,8,9,-5,0,15,22,2,0,6,28,5),Z(0,8,10,-5,0,16,24,2,0,6,30,5),Z(0,8,11,-5,0,17,26,2,0,6,32,5),Z(0,9,11,-5,0,18,28,2,0,7,34,6),Z(0,9,12,-6,0,19,29,2,0,7,36,6),Z(0,10,13,-6,0,20,31,3,0,8,38,7),Z(0,10,13,-6,0,21,33,3,0,8,40,7),Z(0,10,14,-6,0,22,35,3,0,8,42,7),Z(0,11,14,-7,0,23,36,3,0,9,44,8),Z(0,11,15,-7,0,24,38,3,0,9,46,8)],Si={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)"},wi={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function sr(e){return`${Math.round(e)}ms`}function vi(e){if(!e)return 0;const t=e/36;return Math.min(Math.round((4+15*t**.25+t/5)*10),3e3)}function ki(e){const t={...Si,...e.easing},n={...wi,...e.duration};return{getAutoHeightDuration:vi,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:a=t.easeInOut,delay:u=0,...f}=s;if(process.env.NODE_ENV!=="production"){const d=m=>typeof m=="string",h=m=>!Number.isNaN(parseFloat(m));!d(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!h(i)&&!d(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),d(a)||console.error('MUI: Argument "easing" must be a string.'),!h(u)&&!d(u)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(`
|
|
65
|
+
`)),Object.keys(f).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(f).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(d=>`${d} ${typeof i=="string"?i:sr(i)} ${a} ${typeof u=="string"?u:sr(u)}`).join(",")},...e,easing:t,duration:n}}const Ti={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function Ei(e){return ve(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function jr(e={}){const t={...e};function n(r){const o=Object.entries(r);for(let s=0;s<o.length;s++){const[i,a]=o[s];!Ei(a)||i.startsWith("unstable_")?delete r[i]:ve(a)&&(r[i]={...a},n(r[i]))}}return n(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
|
|
66
|
+
|
|
67
|
+
const theme = ${JSON.stringify(t,null,2)};
|
|
68
|
+
|
|
69
|
+
theme.breakpoints = createBreakpoints(theme.breakpoints || {});
|
|
70
|
+
theme.transitions = createTransitions(theme.transitions || {});
|
|
71
|
+
|
|
72
|
+
export default theme;`}function on(e={},...t){const{breakpoints:n,mixins:r={},spacing:o,palette:s={},transitions:i={},typography:a={},shape:u,...f}=e;if(e.vars&&e.generateThemeVars===void 0)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name or follow the [docs](https://mui.com/material-ui/customization/css-theme-variables/usage/) to enable the feature.":Oe(20));const d=Sn(s),h=gn(e);let m=de(h,{mixins:hi(h.breakpoints,r),palette:d,shadows:bi.slice(),typography:gi(d,a),transitions:ki(i),zIndex:{...Ti}});if(m=de(m,f),m=t.reduce((y,g)=>de(y,g),m),process.env.NODE_ENV!=="production"){const y=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],g=(l,b)=>{let k;for(k in l){const x=l[k];if(y.includes(k)&&Object.keys(x).length>0){if(process.env.NODE_ENV!=="production"){const E=pn("",k);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${k}\` internal state.`,"You can not override it like this: ",JSON.stringify(l,null,2),"",`Instead, you need to use the '&.${E}' syntax:`,JSON.stringify({root:{[`&.${E}`]:x}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
|
|
73
|
+
`))}l[k]={}}}};Object.keys(m.components).forEach(l=>{const b=m.components[l].styleOverrides;b&&l.startsWith("Mui")&&g(b,l)})}return m.unstable_sxConfig={...Bt,...f==null?void 0:f.unstable_sxConfig},m.unstable_sx=function(g){return qe({sx:g,theme:this})},m.toRuntimeSource=jr,m}function Ai(e){let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,Math.round(t*10)/1e3}const Ci=[...Array(25)].map((e,t)=>{if(t===0)return"none";const n=Ai(t);return`linear-gradient(rgba(255 255 255 / ${n}), rgba(255 255 255 / ${n}))`});function Mr(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function Lr(e){return e==="dark"?Ci:[]}function Oi(e){const{palette:t={mode:"light"},opacity:n,overlays:r,...o}=e,s=Sn(t);return{palette:s,opacity:{...Mr(s.mode),...n},overlays:r||Lr(s.mode),...o}}function xi(e){var t;return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|modularCssLayers|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||e[0]==="palette"&&!!((t=e[1])!=null&&t.match(/(mode|contrastThreshold|tonalOffset)/))}const Pi=e=>[...[...Array(25)].map((t,n)=>`--${e?`${e}-`:""}overlays-${n}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],Ni=e=>(t,n)=>{const r=e.rootSelector||":root",o=e.colorSchemeSelector;let s=o;if(o==="class"&&(s=".%s"),o==="data"&&(s="[data-%s]"),o!=null&&o.startsWith("data-")&&!o.includes("%s")&&(s=`[${o}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const i={};return Pi(e.cssVarPrefix).forEach(a=>{i[a]=n[a],delete n[a]}),s==="media"?{[r]:n,"@media (prefers-color-scheme: dark)":{[r]:i}}:s?{[s.replace("%s",t)]:i,[`${r}, ${s.replace("%s",t)}`]:n}:{[r]:{...n,...i}}}if(s&&s!=="media")return`${r}, ${s.replace("%s",String(t))}`}else if(t){if(s==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[r]:n}};if(s)return s.replace("%s",String(t))}return r};function Ii(e,t){t.forEach(n=>{e[n]||(e[n]={})})}function p(e,t,n){!e[t]&&n&&(e[t]=n)}function Ze(e){return typeof e!="string"||!e.startsWith("hsl")?e:$r(e)}function we(e,t){`${t}Channel`in e||(e[`${t}Channel`]=Qe(Ze(e[t]),`MUI: Can't create \`palette.${t}Channel\` because \`palette.${t}\` is not one of these formats: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().
|
|
74
|
+
To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function $i(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const be=e=>{try{return e()}catch{}},Ri=(e="mui")=>Zs(e);function Jt(e,t,n,r){if(!t)return;t=t===!0?{}:t;const o=r==="dark"?"dark":"light";if(!n){e[r]=Oi({...t,palette:{mode:o,...t==null?void 0:t.palette}});return}const{palette:s,...i}=on({...n,palette:{mode:o,...t==null?void 0:t.palette}});return e[r]={...t,palette:s,opacity:{...Mr(o),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||Lr(o)},i}function Di(e={},...t){const{colorSchemes:n={light:!0},defaultColorScheme:r,disableCssColorScheme:o=!1,cssVarPrefix:s="mui",shouldSkipGeneratingVar:i=xi,colorSchemeSelector:a=n.light&&n.dark?"media":void 0,rootSelector:u=":root",...f}=e,d=Object.keys(n)[0],h=r||(n.light&&d!=="light"?"light":d),m=Ri(s),{[h]:y,light:g,dark:l,...b}=n,k={...b};let x=y;if((h==="dark"&&!("dark"in n)||h==="light"&&!("light"in n))&&(x=!0),!x)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${h}\` option is either missing or invalid.`:Oe(21,h));const E=Jt(k,x,f,h);g&&!k.light&&Jt(k,g,void 0,"light"),l&&!k.dark&&Jt(k,l,void 0,"dark");let T={defaultColorScheme:h,...E,cssVarPrefix:s,colorSchemeSelector:a,rootSelector:u,getCssVar:m,colorSchemes:k,font:{...di(E.typography),...E.font},spacing:$i(f.spacing)};Object.keys(T.colorSchemes).forEach(F=>{const c=T.colorSchemes[F].palette,A=P=>{const M=P.split("-"),re=M[1],ee=M[2];return m(P,c[re][ee])};if(c.mode==="light"&&(p(c.common,"background","#fff"),p(c.common,"onBackground","#000")),c.mode==="dark"&&(p(c.common,"background","#000"),p(c.common,"onBackground","#fff")),Ii(c,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),c.mode==="light"){p(c.Alert,"errorColor",X(c.error.light,.6)),p(c.Alert,"infoColor",X(c.info.light,.6)),p(c.Alert,"successColor",X(c.success.light,.6)),p(c.Alert,"warningColor",X(c.warning.light,.6)),p(c.Alert,"errorFilledBg",A("palette-error-main")),p(c.Alert,"infoFilledBg",A("palette-info-main")),p(c.Alert,"successFilledBg",A("palette-success-main")),p(c.Alert,"warningFilledBg",A("palette-warning-main")),p(c.Alert,"errorFilledColor",be(()=>c.getContrastText(c.error.main))),p(c.Alert,"infoFilledColor",be(()=>c.getContrastText(c.info.main))),p(c.Alert,"successFilledColor",be(()=>c.getContrastText(c.success.main))),p(c.Alert,"warningFilledColor",be(()=>c.getContrastText(c.warning.main))),p(c.Alert,"errorStandardBg",Q(c.error.light,.9)),p(c.Alert,"infoStandardBg",Q(c.info.light,.9)),p(c.Alert,"successStandardBg",Q(c.success.light,.9)),p(c.Alert,"warningStandardBg",Q(c.warning.light,.9)),p(c.Alert,"errorIconColor",A("palette-error-main")),p(c.Alert,"infoIconColor",A("palette-info-main")),p(c.Alert,"successIconColor",A("palette-success-main")),p(c.Alert,"warningIconColor",A("palette-warning-main")),p(c.AppBar,"defaultBg",A("palette-grey-100")),p(c.Avatar,"defaultBg",A("palette-grey-400")),p(c.Button,"inheritContainedBg",A("palette-grey-300")),p(c.Button,"inheritContainedHoverBg",A("palette-grey-A100")),p(c.Chip,"defaultBorder",A("palette-grey-400")),p(c.Chip,"defaultAvatarColor",A("palette-grey-700")),p(c.Chip,"defaultIconColor",A("palette-grey-700")),p(c.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),p(c.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),p(c.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),p(c.LinearProgress,"primaryBg",Q(c.primary.main,.62)),p(c.LinearProgress,"secondaryBg",Q(c.secondary.main,.62)),p(c.LinearProgress,"errorBg",Q(c.error.main,.62)),p(c.LinearProgress,"infoBg",Q(c.info.main,.62)),p(c.LinearProgress,"successBg",Q(c.success.main,.62)),p(c.LinearProgress,"warningBg",Q(c.warning.main,.62)),p(c.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.11)`),p(c.Slider,"primaryTrack",Q(c.primary.main,.62)),p(c.Slider,"secondaryTrack",Q(c.secondary.main,.62)),p(c.Slider,"errorTrack",Q(c.error.main,.62)),p(c.Slider,"infoTrack",Q(c.info.main,.62)),p(c.Slider,"successTrack",Q(c.success.main,.62)),p(c.Slider,"warningTrack",Q(c.warning.main,.62));const P=mt(c.background.default,.8);p(c.SnackbarContent,"bg",P),p(c.SnackbarContent,"color",be(()=>c.getContrastText(P))),p(c.SpeedDialAction,"fabHoverBg",mt(c.background.paper,.15)),p(c.StepConnector,"border",A("palette-grey-400")),p(c.StepContent,"border",A("palette-grey-400")),p(c.Switch,"defaultColor",A("palette-common-white")),p(c.Switch,"defaultDisabledColor",A("palette-grey-100")),p(c.Switch,"primaryDisabledColor",Q(c.primary.main,.62)),p(c.Switch,"secondaryDisabledColor",Q(c.secondary.main,.62)),p(c.Switch,"errorDisabledColor",Q(c.error.main,.62)),p(c.Switch,"infoDisabledColor",Q(c.info.main,.62)),p(c.Switch,"successDisabledColor",Q(c.success.main,.62)),p(c.Switch,"warningDisabledColor",Q(c.warning.main,.62)),p(c.TableCell,"border",Q(ht(c.divider,1),.88)),p(c.Tooltip,"bg",ht(c.grey[700],.92))}if(c.mode==="dark"){p(c.Alert,"errorColor",Q(c.error.light,.6)),p(c.Alert,"infoColor",Q(c.info.light,.6)),p(c.Alert,"successColor",Q(c.success.light,.6)),p(c.Alert,"warningColor",Q(c.warning.light,.6)),p(c.Alert,"errorFilledBg",A("palette-error-dark")),p(c.Alert,"infoFilledBg",A("palette-info-dark")),p(c.Alert,"successFilledBg",A("palette-success-dark")),p(c.Alert,"warningFilledBg",A("palette-warning-dark")),p(c.Alert,"errorFilledColor",be(()=>c.getContrastText(c.error.dark))),p(c.Alert,"infoFilledColor",be(()=>c.getContrastText(c.info.dark))),p(c.Alert,"successFilledColor",be(()=>c.getContrastText(c.success.dark))),p(c.Alert,"warningFilledColor",be(()=>c.getContrastText(c.warning.dark))),p(c.Alert,"errorStandardBg",X(c.error.light,.9)),p(c.Alert,"infoStandardBg",X(c.info.light,.9)),p(c.Alert,"successStandardBg",X(c.success.light,.9)),p(c.Alert,"warningStandardBg",X(c.warning.light,.9)),p(c.Alert,"errorIconColor",A("palette-error-main")),p(c.Alert,"infoIconColor",A("palette-info-main")),p(c.Alert,"successIconColor",A("palette-success-main")),p(c.Alert,"warningIconColor",A("palette-warning-main")),p(c.AppBar,"defaultBg",A("palette-grey-900")),p(c.AppBar,"darkBg",A("palette-background-paper")),p(c.AppBar,"darkColor",A("palette-text-primary")),p(c.Avatar,"defaultBg",A("palette-grey-600")),p(c.Button,"inheritContainedBg",A("palette-grey-800")),p(c.Button,"inheritContainedHoverBg",A("palette-grey-700")),p(c.Chip,"defaultBorder",A("palette-grey-700")),p(c.Chip,"defaultAvatarColor",A("palette-grey-300")),p(c.Chip,"defaultIconColor",A("palette-grey-300")),p(c.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),p(c.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),p(c.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),p(c.LinearProgress,"primaryBg",X(c.primary.main,.5)),p(c.LinearProgress,"secondaryBg",X(c.secondary.main,.5)),p(c.LinearProgress,"errorBg",X(c.error.main,.5)),p(c.LinearProgress,"infoBg",X(c.info.main,.5)),p(c.LinearProgress,"successBg",X(c.success.main,.5)),p(c.LinearProgress,"warningBg",X(c.warning.main,.5)),p(c.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.13)`),p(c.Slider,"primaryTrack",X(c.primary.main,.5)),p(c.Slider,"secondaryTrack",X(c.secondary.main,.5)),p(c.Slider,"errorTrack",X(c.error.main,.5)),p(c.Slider,"infoTrack",X(c.info.main,.5)),p(c.Slider,"successTrack",X(c.success.main,.5)),p(c.Slider,"warningTrack",X(c.warning.main,.5));const P=mt(c.background.default,.98);p(c.SnackbarContent,"bg",P),p(c.SnackbarContent,"color",be(()=>c.getContrastText(P))),p(c.SpeedDialAction,"fabHoverBg",mt(c.background.paper,.15)),p(c.StepConnector,"border",A("palette-grey-600")),p(c.StepContent,"border",A("palette-grey-600")),p(c.Switch,"defaultColor",A("palette-grey-300")),p(c.Switch,"defaultDisabledColor",A("palette-grey-600")),p(c.Switch,"primaryDisabledColor",X(c.primary.main,.55)),p(c.Switch,"secondaryDisabledColor",X(c.secondary.main,.55)),p(c.Switch,"errorDisabledColor",X(c.error.main,.55)),p(c.Switch,"infoDisabledColor",X(c.info.main,.55)),p(c.Switch,"successDisabledColor",X(c.success.main,.55)),p(c.Switch,"warningDisabledColor",X(c.warning.main,.55)),p(c.TableCell,"border",X(ht(c.divider,1),.68)),p(c.Tooltip,"bg",ht(c.grey[700],.92))}we(c.background,"default"),we(c.background,"paper"),we(c.common,"background"),we(c.common,"onBackground"),we(c,"divider"),Object.keys(c).forEach(P=>{const M=c[P];P!=="tonalOffset"&&M&&typeof M=="object"&&(M.main&&p(c[P],"mainChannel",Qe(Ze(M.main))),M.light&&p(c[P],"lightChannel",Qe(Ze(M.light))),M.dark&&p(c[P],"darkChannel",Qe(Ze(M.dark))),M.contrastText&&p(c[P],"contrastTextChannel",Qe(Ze(M.contrastText))),P==="text"&&(we(c[P],"primary"),we(c[P],"secondary")),P==="action"&&(M.active&&we(c[P],"active"),M.selected&&we(c[P],"selected")))})}),T=t.reduce((F,c)=>de(F,c),T);const _={prefix:s,disableCssColorScheme:o,shouldSkipGeneratingVar:i,getSelector:Ni(T)},{vars:N,generateThemeVars:v,generateStyleSheets:I}=ni(T,_);return T.vars=N,Object.entries(T.colorSchemes[T.defaultColorScheme]).forEach(([F,c])=>{T[F]=c}),T.generateThemeVars=v,T.generateStyleSheets=I,T.generateSpacing=function(){return Or(f.spacing,hn(this))},T.getColorSchemeSelector=ri(a),T.spacing=T.generateSpacing(),T.shouldSkipGeneratingVar=i,T.unstable_sxConfig={...Bt,...f==null?void 0:f.unstable_sxConfig},T.unstable_sx=function(c){return qe({sx:c,theme:this})},T.toRuntimeSource=jr,T}function ir(e,t,n){e.colorSchemes&&n&&(e.colorSchemes[t]={...n!==!0&&n,palette:Sn({...n===!0?{}:n.palette,mode:t})})}function ji(e={},...t){const{palette:n,cssVariables:r=!1,colorSchemes:o=n?void 0:{light:!0},defaultColorScheme:s=n==null?void 0:n.mode,...i}=e,a=s||"light",u=o==null?void 0:o[a],f={...o,...n?{[a]:{...typeof u!="boolean"&&u,palette:n}}:void 0};if(r===!1){if(!("colorSchemes"in e))return on(e,...t);let d=n;"palette"in e||f[a]&&(f[a]!==!0?d=f[a].palette:a==="dark"&&(d={mode:"dark"}));const h=on({...e,palette:d},...t);return h.defaultColorScheme=a,h.colorSchemes=f,h.palette.mode==="light"&&(h.colorSchemes.light={...f.light!==!0&&f.light,palette:h.palette},ir(h,"dark",f.dark)),h.palette.mode==="dark"&&(h.colorSchemes.dark={...f.dark!==!0&&f.dark,palette:h.palette},ir(h,"light",f.light)),h}return!n&&!("light"in f)&&a==="light"&&(f.light=!0),Di({...i,colorSchemes:f,defaultColorScheme:a,...typeof r!="boolean"&&r},...t)}const Br=ji(),Wr="$$material";function Mi(){const e=Is(Br);return process.env.NODE_ENV!=="production"&&Se.useDebugValue(e),e[Wr]||e}function Li(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const Bi=e=>Li(e)&&e!=="classes",Wi=Bs({themeId:Wr,defaultTheme:Br,rootShouldForwardProp:Bi}),Fi=Qs;process.env.NODE_ENV!=="production"&&(K.node,K.object.isRequired);function Vi(e){return Xs(e)}function Ui(e){return pn("MuiSvgIcon",e)}Rs("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const zi=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${De(t)}`,`fontSize${De(n)}`]};return wo(o,Ui,r)},Ki=Wi("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${De(n.color)}`],t[`fontSize${De(n.fontSize)}`]]}})(Fi(({theme:e})=>{var t,n,r,o,s,i,a,u,f,d,h,m,y,g;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(o=(t=e.transitions)==null?void 0:t.create)==null?void 0:o.call(t,"fill",{duration:(r=(n=(e.vars??e).transitions)==null?void 0:n.duration)==null?void 0:r.shorter}),variants:[{props:l=>!l.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((i=(s=e.typography)==null?void 0:s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((u=(a=e.typography)==null?void 0:a.pxToRem)==null?void 0:u.call(a,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((d=(f=e.typography)==null?void 0:f.pxToRem)==null?void 0:d.call(f,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,l])=>l&&l.main).map(([l])=>{var b,k;return{props:{color:l},style:{color:(k=(b=(e.vars??e).palette)==null?void 0:b[l])==null?void 0:k.main}}}),{props:{color:"action"},style:{color:(m=(h=(e.vars??e).palette)==null?void 0:h.action)==null?void 0:m.active}},{props:{color:"disabled"},style:{color:(g=(y=(e.vars??e).palette)==null?void 0:y.action)==null?void 0:g.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Et=Se.forwardRef(function(t,n){const r=Vi({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:a="svg",fontSize:u="medium",htmlColor:f,inheritViewBox:d=!1,titleAccess:h,viewBox:m="0 0 24 24",...y}=r,g=Se.isValidElement(o)&&o.type==="svg",l={...r,color:i,component:a,fontSize:u,instanceFontSize:t.fontSize,inheritViewBox:d,viewBox:m,hasSvgAsChild:g},b={};d||(b.viewBox=m);const k=zi(l);return S.jsxs(Ki,{as:a,className:Tr(k.root,s),focusable:"false",color:f,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:n,...b,...y,...g&&o.props,ownerState:l,children:[g?o.props.children:o,h?S.jsx("title",{children:h}):null]})});process.env.NODE_ENV!=="production"&&(Et.propTypes={children:K.node,classes:K.object,className:K.string,color:K.oneOfType([K.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),K.string]),component:K.elementType,fontSize:K.oneOfType([K.oneOf(["inherit","large","medium","small"]),K.string]),htmlColor:K.string,inheritViewBox:K.bool,shapeRendering:K.string,sx:K.oneOfType([K.arrayOf(K.oneOfType([K.func,K.object,K.bool])),K.func,K.object]),titleAccess:K.string,viewBox:K.string});Et.muiName="SvgIcon";function he(e,t){function n(r,o){return S.jsx(Et,{"data-testid":process.env.NODE_ENV!=="production"?`${t}Icon`:void 0,ref:o,...r,children:e})}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Et.muiName,Se.memo(Se.forwardRef(n))}const Hi=he(S.jsx("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 8"}),"Undo");function Yi(e){return S.jsx($.Button,{name:e.name,"data-cy":e.dataCy??"cancel-button",className:e.className,sx:e.sx,startIcon:e.startIcon??S.jsx(Hi,{}),variant:e.variant??"contained",color:e.color??"secondary",type:e.type??"button",onClick:()=>e.onClick(),children:e.children??e.name})}const qi=he(S.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zm2.46-7.12 1.41-1.41L12 12.59l2.12-2.12 1.41 1.41L13.41 14l2.12 2.12-1.41 1.41L12 15.41l-2.12 2.12-1.41-1.41L10.59 14zM15.5 4l-1-1h-5l-1 1H5v2h14V4z"}),"DeleteForever");function Gi(e){return S.jsx($.Button,{"data-cy":e.dataCy??"delete-button",loading:e.loading??!1,loadingPosition:e.loadingPosition??"start",startIcon:e.startIcon??S.jsx(qi,{}),name:e.name,variant:e.variant??"contained",color:e.color??"error",sx:{m:1},type:e.type??"button",onClick:e.onClick,children:e.label?e.label:"Delete"})}const Ji=he(S.jsx("path",{d:"M3 17.25V21h3.75L17.81 9.94l-3.75-3.75zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.996.996 0 0 0-1.41 0l-1.83 1.83 3.75 3.75z"}),"Edit");function Xi(e){return S.jsx($.Tooltip,{title:e.tooltipTitle,children:S.jsx($.IconButton,{sx:{pt:0,pb:0},color:e.color??"primary",onClick:()=>e.onClick(!0),"aria-label":e.tooltipTitle,children:S.jsx(Ji,{})})})}function Qi(e){return S.jsx($.Button,{"data-cy":e.dataCy??"excel-button",style:{borderRadius:"20px"},className:e.className,name:e.name,sx:e.sx,startIcon:e.startIcon,variant:"contained",color:"success",type:e.type??"button",onClick:()=>e.onClick(),children:e.children??e.name})}const Zi=he(S.jsx("path",{d:"M11.67 3.87 9.9 2.1 0 12l9.9 9.9 1.77-1.77L3.54 12z"}),"ArrowBackIos");function ea(e){return S.jsx($.Tooltip,{title:"Go Back to Previous Page",children:S.jsxs($.IconButton,{name:e.name,color:e.color??"primary",onClick:()=>e.navigate(-1),children:[S.jsx(Zi,{}),e.children]})})}const ta=he(S.jsx("path",{d:"M13 3c-4.97 0-9 4.03-9 9H1l3.89 3.89.07.14L9 12H6c0-3.87 3.13-7 7-7s7 3.13 7 7-3.13 7-7 7c-1.93 0-3.68-.79-4.94-2.06l-1.42 1.42C8.27 19.99 10.51 21 13 21c4.97 0 9-4.03 9-9s-4.03-9-9-9m-1 5v5l4.28 2.54.72-1.21-3.5-2.08V8z"}),"History");function na(e){return S.jsx($.Button,{name:e.name,"data-cy":e.dataCy??"history-button",className:e.className,sx:e.sx??{p:1,m:1},startIcon:e.startIcon??S.jsx(ta,{}),variant:e.variant??"contained",color:e.color??"primary",type:e.type??"button",onClick:()=>e.onClick(),children:e.children??e.name})}const ra=he(S.jsx("path",{d:"M17 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V7zm-5 16c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3m3-10H5V5h10z"}),"Save"),oa={backgroundColor:"$primary-color",color:"var(--white-color)",margin:"20px"};function sa(e){return S.jsx($.Button,{name:e.name,"data-cy":e.dataCy??"loading-success-button",variant:e.variant??"contained",color:e.color??"success",loadingPosition:"start",startIcon:e.startIcon??S.jsx(ra,{}),loading:e.loading,type:e.type??"button",style:oa,sx:e.sx,onClick:e.onClick,children:e.children??e.name})}const ia=he(S.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-.61zM12 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.6"}),"Settings");function aa(e){return S.jsx($.Button,{name:e.name,"data-cy":e.dataCy??"manage-button",className:e.className,onClick:()=>e.onClick(),variant:e.variant??"contained",color:e.color??"primary",size:e.size??"large",startIcon:e.startIcon??S.jsx(ia,{}),children:e.children?e.children:"Manage"})}function ca(e){return S.jsx($.Button,{name:e.name,"data-cy":e.dataCy??"success-button",className:e.className,sx:e.sx,startIcon:e.startIcon,variant:e.variant??"contained",color:e.color??"success",type:e.type??"button",onClick:()=>e.onClick(),children:e.children??e.name})}const wn=he(S.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"),la=e=>{const[t,n]=se.useState(!1);se.useEffect(()=>{n(e.open)},[e.open,e.progressState]);const r=S.jsx($.IconButton,{size:"small","aria-label":"close",color:"inherit",onClick:()=>n(!1),children:S.jsx(wn,{fontSize:"small"})});return S.jsxs(S.Fragment,{children:[S.jsx($.Snackbar,{anchorOrigin:{vertical:"bottom",horizontal:"center"},open:t&&e.progressState.isSuccess,autoHideDuration:e.autoHideDuration??3e3,onClose:()=>n(!1),children:S.jsx($.Alert,{variant:"filled",severity:"success",sx:{width:"100%"},action:r,children:e.progressState.message})}),S.jsx($.Snackbar,{anchorOrigin:{vertical:"bottom",horizontal:"center"},open:t&&e.progressState.isError,TransitionComponent:$.Slide,autoHideDuration:e.autoHideDuration??3e3,onClose:()=>n(!1),children:S.jsx($.Alert,{variant:"filled",sx:{width:"100%"},severity:"error",action:r,children:e.progressState.message})})]})},ua=e=>{const[t,n]=se.useState(!1);se.useEffect(()=>{n(e.open)},[e.open,e]);const r=S.jsx($.IconButton,{size:"small","aria-label":"close",color:"inherit",onClick:()=>n(!1),children:S.jsx(wn,{fontSize:"small"})});return S.jsxs(S.Fragment,{children:[S.jsx($.Snackbar,{anchorOrigin:{vertical:"bottom",horizontal:"center"},open:t&&e.isSuccess,autoHideDuration:e.autoHideDuration??3e3,onClose:()=>n(!1),children:S.jsx($.Alert,{variant:"filled",severity:"success",sx:{width:"100%"},action:r,children:e.message})}),S.jsx($.Snackbar,{anchorOrigin:{vertical:"bottom",horizontal:"center"},open:t&&e.isError,TransitionComponent:$.Slide,autoHideDuration:e.autoHideDuration??3e3,onClose:()=>n(!1),children:S.jsx($.Alert,{variant:"filled",sx:{width:"100%"},severity:"error",action:r,children:e.message})})]})};function fa(){return S.jsx("div",{style:{margin:"1.5rem"},className:"app-flex-justify-center",children:S.jsx($.CircularProgress,{})})}function da(e){const{onClose:t,title:n,message:r,open:o,...s}=e;return S.jsxs($.Dialog,{sx:{"& .MuiDialog-paper":{width:"80%",maxHeight:435}},maxWidth:"xs",open:o,...s,children:[S.jsx($.DialogTitle,{children:n??"Confirm"}),S.jsx($.DialogContent,{dividers:!0,children:r}),S.jsxs($.DialogActions,{children:[S.jsx($.Button,{autoFocus:!0,onClick:()=>t("No"),children:"Cancel"}),S.jsx($.Button,{onClick:()=>t("Yes"),children:"Yes"})]})]})}function ha(e){const[t,n]=se.useState(!0),[r]=se.useState(e.dismissible??!0),[o]=se.useState(e.dismissOnTimeOut??!0),[s]=se.useState(e.dismissTimeOut??5e3);return setTimeout(()=>{n(o?!1:t)},s),S.jsx("span",{children:t&&S.jsx($.Alert,{action:r?S.jsx($.IconButton,{"aria-label":"close",color:"inherit",size:"small",onClick:()=>{n(!1)},children:S.jsx(wn,{fontSize:"inherit"})}):null,style:{margin:"20px"},...e,children:e.message})})}function ma(e){return S.jsx($.Link,{component:Sr.Link,to:e.href,className:"next-btn-link",underline:"hover",children:e.linkText??e.children})}const ga=he(S.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-2zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3z"}),"OpenInNew");function pa(e){return S.jsxs($.Link,{component:Sr.Link,to:e.href,target:e.target||"_blank",rel:"noreferrer",className:"next-btn-link",underline:"hover",children:[e.linkText??e.children,S.jsx($.Icon,{sx:{fontSize:"1.1rem",mx:.75,verticalAlign:"middle",display:"inline-flex"},component:ga})]})}function ya(e){const{condition:t,children:n,else:r}=e;return t?typeof n=="function"?n():n:r?typeof r=="function"?r():r:null}const ar=he(S.jsx("path",{d:"M18.41 16.59 13.82 12l4.59-4.59L17 6l-6 6 6 6zM6 6h2v12H6z"}),"FirstPage"),cr=he(S.jsx("path",{d:"M15.41 16.59 10.83 12l4.58-4.59L14 6l-6 6 6 6z"}),"KeyboardArrowLeft"),lr=he(S.jsx("path",{d:"M8.59 16.59 13.17 12 8.59 7.41 10 6l6 6-6 6z"}),"KeyboardArrowRight"),ur=he(S.jsx("path",{d:"M5.59 7.41 10.18 12l-4.59 4.59L7 18l6-6-6-6zM16 6h2v12h-2z"}),"LastPage");function _a(e){const t=Mi(),{count:n,page:r,rowsPerPage:o,onPageChange:s}=e,i=d=>{s(d,0)},a=d=>{s(d,r-1)},u=d=>{s(d,r+1)},f=d=>{s(d,Math.max(0,Math.ceil(n/o)-1))};return S.jsxs($.Box,{sx:{flexShrink:0,ml:2.5},children:[S.jsx($.IconButton,{onClick:i,disabled:r===0,"aria-label":"first page",children:t.direction==="rtl"?S.jsx(ur,{}):S.jsx(ar,{})}),S.jsx($.IconButton,{onClick:a,disabled:r===0,"aria-label":"previous page",children:t.direction==="rtl"?S.jsx(lr,{}):S.jsx(cr,{})}),S.jsx($.IconButton,{onClick:u,disabled:r>=Math.ceil(n/o)-1,"aria-label":"next page",children:t.direction==="rtl"?S.jsx(cr,{}):S.jsx(lr,{})}),S.jsx($.IconButton,{onClick:f,disabled:r>=Math.ceil(n/o)-1,"aria-label":"last page",children:t.direction==="rtl"?S.jsx(ar,{}):S.jsx(ur,{})})]})}function ba(e){const{children:t,index:n,...r}=e;return S.jsx("div",{className:"tabPanel",role:"tabpanel",id:`vertical-tabpanel-${n}`,"aria-labelledby":`vertical-tab-${n}`,...r,children:S.jsx($.Box,{sx:{p:3},children:S.jsx($.Typography,{component:"span",children:t})})})}function Sa(e){return{id:`vertical-tab-${e}`,"aria-controls":`vertical-tabpanel-${e}`}}class At{open(t){window.location.href=t}reload(){window.location.reload()}getCurrentHref(){return window.location.href}getPath(){const t=window.location;return t.pathname+(t.search||"")+(t.hash||"")}getOrigin(){return window.origin}}const fr=2e3,Ue=console;class wa{constructor(t,n,r,o=fr,s=!0){this._callback=t,this._client_id=n,this._url=r,this._interval=o||fr,this._stopOnError=s;const i=r.indexOf("/",r.indexOf("//")+2);this._frame_origin=r.substring(0,i),this._frame=window.document.createElement("iframe"),this._frame.style.visibility="hidden",this._frame.style.position="absolute",this._frame.style.display="none",this._frame.width=0,this._frame.height=0,this._frame.src=r}load(){return new Promise(t=>{this._frame.onload=()=>{t()},window.document.body.appendChild(this._frame),this._boundMessageEvent=this._message.bind(this),window.addEventListener("message",this._boundMessageEvent,!1)})}_message(t){t.origin===this._frame_origin&&t.source===this._frame.contentWindow&&(t.data==="error"?(Ue.error("CheckSessionIFrame: error message from check session op iframe"),this._stopOnError&&this.stop()):t.data==="changed"?(Ue.debug(t),Ue.debug("CheckSessionIFrame: changed message from check session op iframe"),this.stop(),this._callback()):Ue.debug("CheckSessionIFrame: "+t.data+" message from check session op iframe"))}start(t){Ue.debug("CheckSessionIFrame.start :"+t),this.stop();const n=()=>{this._frame.contentWindow.postMessage(this._client_id+" "+t,this._frame_origin)};n(),this._timer=window.setInterval(n,this._interval)}stop(){this._timer&&(Ue.debug("CheckSessionIFrame.stop"),window.clearInterval(this._timer),this._timer=null)}}const D={service_worker_not_supported_by_browser:"service_worker_not_supported_by_browser",token_acquired:"token_acquired",logout_from_another_tab:"logout_from_another_tab",logout_from_same_tab:"logout_from_same_tab",token_renewed:"token_renewed",token_timer:"token_timer",loginAsync_begin:"loginAsync_begin",loginAsync_error:"loginAsync_error",loginCallbackAsync_begin:"loginCallbackAsync_begin",loginCallbackAsync_end:"loginCallbackAsync_end",loginCallbackAsync_error:"loginCallbackAsync_error",refreshTokensAsync_begin:"refreshTokensAsync_begin",refreshTokensAsync:"refreshTokensAsync",refreshTokensAsync_end:"refreshTokensAsync_end",refreshTokensAsync_error:"refreshTokensAsync_error",refreshTokensAsync_silent_error:"refreshTokensAsync_silent_error",tryKeepExistingSessionAsync_begin:"tryKeepExistingSessionAsync_begin",tryKeepExistingSessionAsync_end:"tryKeepExistingSessionAsync_end",tryKeepExistingSessionAsync_error:"tryKeepExistingSessionAsync_error",silentLoginAsync_begin:"silentLoginAsync_begin",silentLoginAsync:"silentLoginAsync",silentLoginAsync_end:"silentLoginAsync_end",silentLoginAsync_error:"silentLoginAsync_error",syncTokensAsync_begin:"syncTokensAsync_begin",syncTokensAsync_lock_not_available:"syncTokensAsync_lock_not_available",syncTokensAsync_end:"syncTokensAsync_end",syncTokensAsync_error:"syncTokensAsync_error",tokensInvalidAndWaitingActionsToRefresh:"tokensInvalidAndWaitingActionsToRefresh"},ge=(e,t=sessionStorage)=>{const n=l=>(t[`oidc.${e}`]=JSON.stringify({tokens:null,status:l}),Promise.resolve()),r=async()=>{if(!t[`oidc.${e}`])return t[`oidc.${e}`]=JSON.stringify({tokens:null,status:null}),{tokens:null,status:null};const l=JSON.parse(t[`oidc.${e}`]);return Promise.resolve({tokens:l.tokens,status:l.status})},o=l=>{t[`oidc.${e}`]=JSON.stringify({tokens:l})},s=async l=>{t[`oidc.session_state.${e}`]=l},i=async()=>t[`oidc.session_state.${e}`],a=l=>{t[`oidc.nonce.${e}`]=l.nonce},u=l=>{t[`oidc.jwk.${e}`]=JSON.stringify(l)},f=()=>JSON.parse(t[`oidc.jwk.${e}`]),d=async()=>({nonce:t[`oidc.nonce.${e}`]}),h=async l=>{t[`oidc.dpop_nonce.${e}`]=l},m=()=>t[`oidc.dpop_nonce.${e}`],y=()=>t[`oidc.${e}`]?JSON.stringify({tokens:JSON.parse(t[`oidc.${e}`]).tokens}):null,g={};return{clearAsync:n,initAsync:r,setTokens:o,getTokens:y,setSessionStateAsync:s,getSessionStateAsync:i,setNonceAsync:a,getNonceAsync:d,setLoginParams:l=>{g[e]=l,t[`oidc.login.${e}`]=JSON.stringify(l)},getLoginParams:()=>{const l=t[`oidc.login.${e}`];return l?(g[e]||(g[e]=JSON.parse(l)),g[e]):(console.warn(`storage[oidc.login.${e}] is empty, you should have an bad OIDC or code configuration somewhere.`),null)},getStateAsync:async()=>t[`oidc.state.${e}`],setStateAsync:async l=>{t[`oidc.state.${e}`]=l},getCodeVerifierAsync:async()=>t[`oidc.code_verifier.${e}`],setCodeVerifierAsync:async l=>{t[`oidc.code_verifier.${e}`]=l},setDemonstratingProofOfPossessionNonce:h,getDemonstratingProofOfPossessionNonce:m,setDemonstratingProofOfPossessionJwkAsync:u,getDemonstratingProofOfPossessionJwkAsync:f}};var rt=(e=>(e.AutomaticBeforeTokenExpiration="AutomaticBeforeTokensExpiration",e.AutomaticOnlyWhenFetchExecuted="AutomaticOnlyWhenFetchExecuted",e))(rt||{});const va=e=>decodeURIComponent(Array.prototype.map.call(atob(e),t=>"%"+("00"+t.charCodeAt(0).toString(16)).slice(-2)).join("")),ka=e=>JSON.parse(va(e.replaceAll(/-/g,"+").replaceAll(/_/g,"/"))),dr=e=>{try{return e&&Ta(e,".")===2?ka(e.split(".")[1]):null}catch(t){console.warn(t)}return null},Ta=(e,t)=>e.split(t).length-1,sn={access_token_or_id_token_invalid:"access_token_or_id_token_invalid",access_token_invalid:"access_token_invalid",id_token_invalid:"id_token_invalid"};function Ea(e,t,n){if(e.issuedAt){if(typeof e.issuedAt=="string")return parseInt(e.issuedAt,10)}else return t&&t.iat?t.iat:n&&n.iat?n.iat:new Date().getTime()/1e3;return e.issuedAt}const vn=(e,t=null,n)=>{if(!e)return null;let r;const o=typeof e.expiresIn=="string"?parseInt(e.expiresIn,10):e.expiresIn;e.accessTokenPayload!==void 0?r=e.accessTokenPayload:r=dr(e.accessToken);let s;t!=null&&"idToken"in t&&!("idToken"in e)?s=t.idToken:s=e.idToken;const i=e.idTokenPayload?e.idTokenPayload:dr(s),a=i&&i.exp?i.exp:Number.MAX_VALUE,u=r&&r.exp?r.exp:e.issuedAt+o;e.issuedAt=Ea(e,r,i);let f;e.expiresAt?f=e.expiresAt:n===sn.access_token_invalid?f=u:n===sn.id_token_invalid?f=a:f=a<u?a:u;const d={...e,idTokenPayload:i,accessTokenPayload:r,expiresAt:f,idToken:s};if(t!=null&&"refreshToken"in t&&!("refreshToken"in e)){const h=t.refreshToken;return{...d,refreshToken:h}}return d},kn=(e,t,n)=>{if(!e)return null;if(!e.issued_at){const o=new Date().getTime()/1e3;e.issued_at=o}const r={accessToken:e.access_token,expiresIn:e.expires_in,idToken:e.id_token,scope:e.scope,tokenType:e.token_type,issuedAt:e.issued_at};return"refresh_token"in e&&(r.refreshToken=e.refresh_token),e.accessTokenPayload!==void 0&&(r.accessTokenPayload=e.accessTokenPayload),e.idTokenPayload!==void 0&&(r.idTokenPayload=e.idTokenPayload),vn(r,t,n)},tt=(e,t)=>{const n=new Date().getTime()/1e3,r=t-n;return Math.round(r-e)},hr=(e,t=0)=>e?tt(t,e.expiresAt)>0:!1,Fr=async(e,t=200,n=50)=>{let r=n;if(!e.getTokens())return null;for(;!hr(e.getTokens(),e.configuration.refresh_time_before_tokens_expiration_in_second)&&r>0;){if(e.configuration.token_automatic_renew_mode==rt.AutomaticOnlyWhenFetchExecuted){await e.renewTokensAsync({});break}else await Tn({milliseconds:t});r=r-1}return{isTokensValid:hr(e.getTokens()),tokens:e.getTokens(),numberWaited:r-n}},Vr=(e,t,n)=>{if(e.idTokenPayload){const r=e.idTokenPayload;if(n.issuer!==r.iss)return{isValid:!1,reason:`Issuer does not match (oidcServerConfiguration issuer) ${n.issuer} !== (idTokenPayload issuer) ${r.iss}`};const o=new Date().getTime()/1e3;if(r.exp&&r.exp<o)return{isValid:!1,reason:`Token expired (idTokenPayload exp) ${r.exp} < (currentTimeUnixSecond) ${o}`};const s=60*60*24*7;if(r.iat&&r.iat+s<o)return{isValid:!1,reason:`Token is used from too long time (idTokenPayload iat + timeInSevenDays) ${r.iat+s} < (currentTimeUnixSecond) ${o}`};if(r.nonce&&r.nonce!==t)return{isValid:!1,reason:`Nonce does not match (idTokenPayload nonce) ${r.nonce} !== (nonce) ${t}`}}return{isValid:!0,reason:""}},Ge=function(){const e=typeof window>"u"?global:window;return{setTimeout:setTimeout.bind(e),clearTimeout:clearTimeout.bind(e),setInterval:setInterval.bind(e),clearInterval:clearInterval.bind(e)}}(),Xt="7.25.14";let mr=null,Ct;const Tn=({milliseconds:e})=>new Promise(t=>Ge.setTimeout(t,e)),Ur=(e="/")=>{try{Ct=new AbortController,fetch(`${e}OidcKeepAliveServiceWorker.json?minSleepSeconds=150`,{signal:Ct.signal}).catch(t=>{console.log(t)}),Tn({milliseconds:150*1e3}).then(Ur)}catch(t){console.log(t)}},Qt=()=>{Ct&&Ct.abort()},zr=e=>{const t=sessionStorage.getItem(`oidc.tabId.${e}`);if(t)return t;const n=globalThis.crypto.randomUUID();return sessionStorage.setItem(`oidc.tabId.${e}`,n),n},ae=e=>t=>new Promise(function(n,r){const o=new MessageChannel;o.port1.onmessage=function(s){s!=null&&s.data.error?r(s.data.error):n(s.data),o.port1.close(),o.port2.close()},e.active.postMessage({...t,tabId:zr(t.configurationName)},[o.port2])}),pe=async(e,t)=>{const n=e.service_worker_relative_url;if(typeof window>"u"||typeof navigator>"u"||!navigator.serviceWorker||!n||e.service_worker_activate()===!1)return null;const r=`${n}?v=${Xt}`;let o=null;e.service_worker_register?o=await e.service_worker_register(n):o=await navigator.serviceWorker.register(r,{updateViaCache:"none"}),o.addEventListener("updatefound",()=>{const v=o.installing;Qt(),v==null||v.addEventListener("statechange",()=>{v.state==="installed"&&navigator.serviceWorker.controller&&(Qt(),console.log("New SW waiting – skipWaiting()"),v.postMessage({type:"SKIP_WAITING"}))})}),navigator.serviceWorker.addEventListener("controllerchange",()=>{console.log("SW controller changed – reloading page"),Qt(),window.location.reload()});try{await navigator.serviceWorker.ready,navigator.serviceWorker.controller||await ae(o)({type:"claim"})}catch(v){return console.warn(`Failed init ServiceWorker ${v.toString()}`),null}const s=async v=>ae(o)({type:"clear",data:{status:v},configurationName:t}),i=async(v,I,F)=>{const c=await ae(o)({type:"init",data:{oidcServerConfiguration:v,where:I,oidcConfiguration:{token_renew_mode:F.token_renew_mode,service_worker_convert_all_requests_to_cors:F.service_worker_convert_all_requests_to_cors}},configurationName:t}),A=c.version;return A!==Xt&&console.warn(`Service worker ${A} version mismatch with js client version ${Xt}, unregistering and reloading`),{tokens:kn(c.tokens,null,F.token_renew_mode),status:c.status}},a=(v="/")=>{mr==null&&(mr="not_null",Ur(v))},u=v=>ae(o)({type:"setSessionState",data:{sessionState:v},configurationName:t}),f=async()=>(await ae(o)({type:"getSessionState",data:null,configurationName:t})).sessionState,d=v=>(sessionStorage[`oidc.nonce.${t}`]=v.nonce,ae(o)({type:"setNonce",data:{nonce:v},configurationName:t})),h=async(v=!0)=>{let I=(await ae(o)({type:"getNonce",data:null,configurationName:t})).nonce;return I||(I=sessionStorage[`oidc.nonce.${t}`],console.warn("nonce not found in service worker, using sessionStorage"),v&&(await d(I),I=(await h(!1)).nonce)),{nonce:I}},m={},y=v=>{m[t]=v,localStorage[`oidc.login.${t}`]=JSON.stringify(v)},g=()=>{const v=localStorage[`oidc.login.${t}`];return m[t]||(m[t]=JSON.parse(v)),m[t]},l=async v=>{await ae(o)({type:"setDemonstratingProofOfPossessionNonce",data:{demonstratingProofOfPossessionNonce:v},configurationName:t})},b=async()=>(await ae(o)({type:"getDemonstratingProofOfPossessionNonce",data:null,configurationName:t})).demonstratingProofOfPossessionNonce,k=async v=>{const I=JSON.stringify(v);await ae(o)({type:"setDemonstratingProofOfPossessionJwk",data:{demonstratingProofOfPossessionJwkJson:I},configurationName:t})},x=async()=>{const v=await ae(o)({type:"getDemonstratingProofOfPossessionJwk",data:null,configurationName:t});return v.demonstratingProofOfPossessionJwkJson?JSON.parse(v.demonstratingProofOfPossessionJwkJson):null},E=async(v=!0)=>{let I=(await ae(o)({type:"getState",data:null,configurationName:t})).state;return I||(I=sessionStorage[`oidc.state.${t}`],console.warn("state not found in service worker, using sessionStorage"),v&&(await T(I),I=await E(!1))),I},T=async v=>(sessionStorage[`oidc.state.${t}`]=v,ae(o)({type:"setState",data:{state:v},configurationName:t})),_=async(v=!0)=>{let I=(await ae(o)({type:"getCodeVerifier",data:null,configurationName:t})).codeVerifier;return I||(I=sessionStorage[`oidc.code_verifier.${t}`],console.warn("codeVerifier not found in service worker, using sessionStorage"),v&&(await N(I),I=await _(!1))),I},N=async v=>(sessionStorage[`oidc.code_verifier.${t}`]=v,ae(o)({type:"setCodeVerifier",data:{codeVerifier:v},configurationName:t}));return{clearAsync:s,initAsync:i,startKeepAliveServiceWorker:()=>a(e.service_worker_keep_alive_path),setSessionStateAsync:u,getSessionStateAsync:f,setNonceAsync:d,getNonceAsync:h,setLoginParams:y,getLoginParams:g,getStateAsync:E,setStateAsync:T,getCodeVerifierAsync:_,setCodeVerifierAsync:N,setDemonstratingProofOfPossessionNonce:l,getDemonstratingProofOfPossessionNonce:b,setDemonstratingProofOfPossessionJwkAsync:k,getDemonstratingProofOfPossessionJwkAsync:x}},He={},Aa=(e,t=window.sessionStorage,n)=>{if(!He[e]&&t){const o=t.getItem(e);o&&(He[e]=JSON.parse(o))}const r=1e3*n;return He[e]&&He[e].timestamp+r>Date.now()?He[e].result:null},Ca=(e,t,n=window.sessionStorage)=>{const r=Date.now();He[e]={result:t,timestamp:r},n&&n.setItem(e,JSON.stringify({result:t,timestamp:r}))};function Kr(e){return new TextEncoder().encode(e)}function Hr(e){return btoa(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+/g,"")}function Oa(e){return encodeURIComponent(e).replace(/%([0-9A-F]{2})/g,function(t,n){return String.fromCharCode(parseInt(n,16))})}const En=e=>{let t="";return e.forEach(function(n){t+=String.fromCharCode(n)}),Hr(t)};function gr(e){return Hr(Oa(e))}const xa={importKeyAlgorithm:{name:"ECDSA",namedCurve:"P-256",hash:{name:"ES256"}},signAlgorithm:{name:"ECDSA",hash:{name:"SHA-256"}},generateKeyAlgorithm:{name:"ECDSA",namedCurve:"P-256"},digestAlgorithm:{name:"SHA-256"},jwtHeaderAlgorithm:"ES256"},Pa=e=>async(t,n,r,o,s="dpop+jwt")=>{switch(t=Object.assign({},t),n.typ=s,n.alg=o.jwtHeaderAlgorithm,n.alg){case"ES256":n.jwk={kty:t.kty,crv:t.crv,x:t.x,y:t.y};break;case"RS256":n.jwk={kty:t.kty,n:t.n,e:t.e,kid:n.kid};break;default:throw new Error("Unknown or not implemented JWS algorithm")}const i={protected:gr(JSON.stringify(n)),payload:gr(JSON.stringify(r))},a=o.importKeyAlgorithm,u=!0,f=["sign"],d=await e.crypto.subtle.importKey("jwk",t,a,u,f),h=Kr(`${i.protected}.${i.payload}`),m=o.signAlgorithm,y=await e.crypto.subtle.sign(m,d,h);return i.signature=En(new Uint8Array(y)),`${i.protected}.${i.payload}.${i.signature}`},Na={sign:Pa},Ia=e=>async t=>{const n=t,r=!0,o=["sign","verify"],s=await e.crypto.subtle.generateKey(n,r,o);return await e.crypto.subtle.exportKey("jwk",s.privateKey)},$a=e=>{const t=Object.assign({},e);return delete t.d,t.key_ops=["verify"],t},Ra={generate:Ia,neuter:$a},Da=e=>async(t,n)=>{let r;switch(t.kty){case"EC":r='{"crv":"CRV","kty":"EC","x":"X","y":"Y"}'.replace("CRV",t.crv).replace("X",t.x).replace("Y",t.y);break;case"RSA":r='{"e":"E","kty":"RSA","n":"N"}'.replace("E",t.e).replace("N",t.n);break;default:throw new Error("Unknown or not implemented JWK type")}const o=await e.crypto.subtle.digest(n,Kr(r));return En(new Uint8Array(o))},ja={thumbprint:Da},Ma=e=>async t=>await Ra.generate(e)(t),Yr=e=>t=>async(n,r="POST",o,s={})=>{const i={jti:btoa(La()),htm:r,htu:o,iat:Math.round(Date.now()/1e3),...s},a=await ja.thumbprint(e)(n,t.digestAlgorithm);return await Na.sign(e)(n,{kid:a},i,t)},La=()=>{const e="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx",t="0123456789abcdef";let n=0,r="";for(let o=0;o<36;o++)e[o]!=="-"&&e[o]!=="4"&&(n=Math.random()*16|0),e[o]==="x"?r+=t[n]:e[o]==="y"?(n&=3,n|=8,r+=t[n]):r+=e[o];return r},qr=()=>{const e=typeof window<"u"&&!!window.crypto,t=e&&!!window.crypto.subtle;return{hasCrypto:e,hasSubtleCrypto:t}},an="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",Ba=e=>{const t=[];for(let n=0;n<e.byteLength;n+=1){const r=e[n]%an.length;t.push(an[r])}return t.join("")},cn=e=>{const t=new Uint8Array(e),{hasCrypto:n}=qr();if(n)window.crypto.getRandomValues(t);else for(let r=0;r<e;r+=1)t[r]=Math.random()*an.length|0;return Ba(t)};function Wa(e){const t=new ArrayBuffer(e.length),n=new Uint8Array(t);for(let r=0;r<e.length;r++)n[r]=e.charCodeAt(r);return n}function Gr(e){return new Promise((t,n)=>{crypto.subtle.digest("SHA-256",Wa(e)).then(r=>t(En(new Uint8Array(r))),r=>n(r))})}const Fa=e=>{if(e.length<43||e.length>128)return Promise.reject(new Error("Invalid code length."));const{hasSubtleCrypto:t}=qr();return t?Gr(e):Promise.reject(new Error("window.crypto.subtle is unavailable."))},Va=60*60,Ua=e=>async(t,n=Va,r=window.sessionStorage,o=1e4)=>{const s=`${t}/.well-known/openid-configuration`,i=`oidc.server:${t}`,a=Aa(i,r,n);if(a)return new un(a);const u=await ct(e)(s,{},o);if(u.status!==200)return null;const f=await u.json();return Ca(i,f,r),new un(f)},ct=e=>async(t,n={},r=1e4,o=0)=>{let s;try{const i=new AbortController;setTimeout(()=>i.abort(),r),s=await e(t,{...n,signal:i.signal})}catch(i){if(i.name==="AbortError"||i.message==="Network request failed"){if(o<=1)return await ct(e)(t,n,r,o+1);throw i}else throw console.error(i.message),i}return s},ln={refresh_token:"refresh_token",access_token:"access_token"},pr=e=>async(t,n,r=ln.refresh_token,o,s={},i=1e4)=>{const a={token:n,token_type_hint:r,client_id:o};for(const[d,h]of Object.entries(s))a[d]===void 0&&(a[d]=h);const u=[];for(const d in a){const h=encodeURIComponent(d),m=encodeURIComponent(a[d]);u.push(`${h}=${m}`)}const f=u.join("&");return(await ct(e)(t,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"},body:f},i)).status!==200?{success:!1}:{success:!0}},za=e=>async(t,n,r,o,s={},i,a=1e4)=>{for(const[y,g]of Object.entries(r))n[y]===void 0&&(n[y]=g);const u=[];for(const y in n){const g=encodeURIComponent(y),l=encodeURIComponent(n[y]);u.push(`${g}=${l}`)}const f=u.join("&"),d=await ct(e)(t,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded;charset=UTF-8",...s},body:f},a);if(d.status!==200)return{success:!1,status:d.status,demonstratingProofOfPossessionNonce:null};const h=await d.json();let m=null;return d.headers.has(Ot)&&(m=d.headers.get(Ot)),{success:!0,status:d.status,data:kn(h,o,i),demonstratingProofOfPossessionNonce:m}},Ka=(e,t)=>async(n,r)=>{r=r?{...r}:{};const o=cn(128),s=await Fa(o);await e.setCodeVerifierAsync(o),await e.setStateAsync(r.state),r.code_challenge=s,r.code_challenge_method="S256";let i="";if(r)for(const[a,u]of Object.entries(r))i===""?i+="?":i+="&",i+=`${a}=${encodeURIComponent(u)}`;t.open(`${n}${i}`)},Ot="DPoP-Nonce",Ha=e=>async(t,n,r,o,s=1e4)=>{n=n?{...n}:{},n.code_verifier=await e.getCodeVerifierAsync();const i=[];for(const h in n){const m=encodeURIComponent(h),y=encodeURIComponent(n[h]);i.push(`${m}=${y}`)}const a=i.join("&"),u=await ct(fetch)(t,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded;charset=UTF-8",...r},body:a},s);if(await Promise.all([e.setCodeVerifierAsync(null),e.setStateAsync(null)]),u.status!==200)return{success:!1,status:u.status};let f=null;u.headers.has(Ot)&&(f=u.headers.get(Ot));const d=await u.json();return{success:!0,data:{state:n.state,tokens:kn(d,null,o),demonstratingProofOfPossessionNonce:f}}};async function yr(e,t,n,r=null){const o=a=>{e.tokens=a},{tokens:s,status:i}=await pt(e)(o,0,0,t,n,r);return await pe(e.configuration,e.configurationName)||await ge(e.configurationName,e.configuration.storage).setTokens(e.tokens),e.tokens?s:(await e.destroyAsync(i),null)}async function Jr(e,t=!1,n=null,r=null){const o=e.configuration,s=`${o.client_id}_${e.configurationName}_${o.authority}`;let i;const a=await pe(e.configuration,e.configurationName);if((o==null?void 0:o.storage)===(window==null?void 0:window.sessionStorage)&&!a||!navigator.locks)i=await yr(e,t,n,r);else{let u="retry";for(;u==="retry";)u=await navigator.locks.request(s,{ifAvailable:!0},async f=>f?await yr(e,t,n,r):(e.publishEvent(ke.eventNames.syncTokensAsync_lock_not_available,{lock:"lock not available"}),"retry"));i=u}return i?(e.timeoutId&&(e.timeoutId=ot(e,e.tokens.expiresAt,n,r)),e.tokens):null}const ot=(e,t,n=null,r=null)=>{const o=e.configuration.refresh_time_before_tokens_expiration_in_second;return e.timeoutId&&Ge.clearTimeout(e.timeoutId),Ge.setTimeout(async()=>{const s={timeLeft:tt(o,t)};e.publishEvent(ke.eventNames.token_timer,s),await Jr(e,!1,n,r)},1e3)},Ee={FORCE_REFRESH:"FORCE_REFRESH",SESSION_LOST:"SESSION_LOST",NOT_CONNECTED:"NOT_CONNECTED",TOKENS_VALID:"TOKENS_VALID",TOKEN_UPDATED_BY_ANOTHER_TAB_TOKENS_VALID:"TOKEN_UPDATED_BY_ANOTHER_TAB_TOKENS_VALID",LOGOUT_FROM_ANOTHER_TAB:"LOGOUT_FROM_ANOTHER_TAB",REQUIRE_SYNC_TOKENS:"REQUIRE_SYNC_TOKENS"},Ya=e=>async(t,n,r,o=!1)=>{const s={nonce:null};if(!r)return{tokens:null,status:"NOT_CONNECTED",nonce:s};let i=s;const a=await e.initAsync(t.authority,t.authority_configuration),u=await pe(t,n);if(u){const{status:d,tokens:h}=await u.initAsync(a,"syncTokensAsync",t);if(d==="LOGGED_OUT")return{tokens:null,status:"LOGOUT_FROM_ANOTHER_TAB",nonce:s};if(d==="SESSIONS_LOST")return{tokens:null,status:"SESSIONS_LOST",nonce:s};if(!d||!h)return{tokens:null,status:"REQUIRE_SYNC_TOKENS",nonce:s};if(h.issuedAt!==r.issuedAt){const m=tt(t.refresh_time_before_tokens_expiration_in_second,h.expiresAt)>0?"TOKEN_UPDATED_BY_ANOTHER_TAB_TOKENS_VALID":"TOKEN_UPDATED_BY_ANOTHER_TAB_TOKENS_INVALID",y=await u.getNonceAsync();return{tokens:h,status:m,nonce:y}}i=await u.getNonceAsync()}else{const d=ge(n,t.storage??sessionStorage),h=await d.initAsync();let{tokens:m}=h;const{status:y}=h;if(m&&(m=vn(m,e.tokens,t.token_renew_mode)),m){if(y==="SESSIONS_LOST")return{tokens:null,status:"SESSIONS_LOST",nonce:s};if(m.issuedAt!==r.issuedAt){const g=tt(t.refresh_time_before_tokens_expiration_in_second,m.expiresAt)>0?"TOKEN_UPDATED_BY_ANOTHER_TAB_TOKENS_VALID":"TOKEN_UPDATED_BY_ANOTHER_TAB_TOKENS_INVALID",l=await d.getNonceAsync();return{tokens:m,status:g,nonce:l}}}else return{tokens:null,status:"LOGOUT_FROM_ANOTHER_TAB",nonce:s};i=await d.getNonceAsync()}const f=tt(t.refresh_time_before_tokens_expiration_in_second,r.expiresAt)>0?"TOKENS_VALID":"TOKENS_INVALID";return o?{tokens:r,status:"FORCE_REFRESH",nonce:i}:{tokens:r,status:f,nonce:i}},pt=e=>async(t,n=0,r=0,o=!1,s=null,i=null)=>{if(!navigator.onLine&&document.hidden)return{tokens:e.tokens,status:"GIVE_UP"};let a=6;const u=5,f=5;for(;!navigator.onLine&&a>0;)await Tn({milliseconds:1e3}),a--,e.publishEvent(D.refreshTokensAsync,{message:`wait because navigator is offline try ${a}`});const d=document.hidden,h=d?n:n+1,m=d?r+1:r;if(n>=u||r>=f)return t(null),e.publishEvent(D.refreshTokensAsync_error,{message:"refresh token"}),{tokens:null,status:"SESSION_LOST"};s||(s={});const y=e.configuration,g=(b,k=null,x=null)=>An(e.configurationName,e.configuration,e.publishEvent.bind(e))(b,k,x),l=async()=>{try{let b;const k=await pe(y,e.configurationName);k?b=k.getLoginParams():b=ge(e.configurationName,y.storage).getLoginParams();const x=await g({...b.extras,...s,prompt:"none",scope:i});return x?x.error?(t(null),e.publishEvent(D.refreshTokensAsync_error,{message:"refresh token silent"}),{tokens:null,status:"SESSION_LOST"}):(t(x.tokens),e.publishEvent(ke.eventNames.token_renewed,{}),{tokens:x.tokens,status:"LOGGED"}):(t(null),e.publishEvent(D.refreshTokensAsync_error,{message:"refresh token silent not active"}),{tokens:null,status:"SESSION_LOST"})}catch(b){return console.error(b),e.publishEvent(D.refreshTokensAsync_silent_error,{message:"exceptionSilent",exception:b.message}),await pt(e)(t,h,m,o,s,i)}};try{const{status:b,tokens:k,nonce:x}=await Ya(e)(y,e.configurationName,e.tokens,o);switch(b){case Ee.SESSION_LOST:return t(null),e.publishEvent(D.refreshTokensAsync_error,{message:"refresh token session lost"}),{tokens:null,status:"SESSION_LOST"};case Ee.NOT_CONNECTED:return t(null),{tokens:null,status:null};case Ee.TOKENS_VALID:return t(k),{tokens:k,status:"LOGGED_IN"};case Ee.TOKEN_UPDATED_BY_ANOTHER_TAB_TOKENS_VALID:return t(k),e.publishEvent(ke.eventNames.token_renewed,{reason:"TOKEN_UPDATED_BY_ANOTHER_TAB_TOKENS_VALID"}),{tokens:k,status:"LOGGED_IN"};case Ee.LOGOUT_FROM_ANOTHER_TAB:return t(null),e.publishEvent(D.logout_from_another_tab,{status:"session syncTokensAsync"}),{tokens:null,status:"LOGGED_OUT"};case Ee.REQUIRE_SYNC_TOKENS:return y.token_automatic_renew_mode==rt.AutomaticOnlyWhenFetchExecuted&&Ee.FORCE_REFRESH!==b?(e.publishEvent(D.tokensInvalidAndWaitingActionsToRefresh,{}),{tokens:e.tokens,status:"GIVE_UP"}):(e.publishEvent(D.refreshTokensAsync_begin,{tryNumber:n}),await l());default:{if(y.token_automatic_renew_mode==rt.AutomaticOnlyWhenFetchExecuted&&Ee.FORCE_REFRESH!==b)return e.publishEvent(D.tokensInvalidAndWaitingActionsToRefresh,{}),{tokens:e.tokens,status:"GIVE_UP"};if(e.publishEvent(D.refreshTokensAsync_begin,{refreshToken:k.refreshToken,status:b,tryNumber:n,backgroundTry:r}),!k.refreshToken)return await l();const E=y.client_id,T=y.redirect_uri,_=y.authority,N={...y.token_request_extras?y.token_request_extras:{}};for(const[v,I]of Object.entries(s))v.endsWith(":token_request")&&(N[v.replace(":token_request","")]=I);return await(async()=>{const v={client_id:E,redirect_uri:T,grant_type:"refresh_token",refresh_token:k.refreshToken},I=await e.initAsync(_,y.authority_configuration),F=document.hidden?1e4:3e4*10,c=I.tokenEndpoint,A={};y.demonstrating_proof_of_possession&&(A.DPoP=await e.generateDemonstrationOfProofOfPossessionAsync(k.accessToken,c,"POST"));const P=await za(e.getFetch())(c,v,N,k,A,y.token_renew_mode,F);if(P.success){const{isValid:M,reason:re}=Vr(P.data,x.nonce,I);if(!M)return t(null),e.publishEvent(D.refreshTokensAsync_error,{message:`refresh token return not valid tokens, reason: ${re}`}),{tokens:null,status:"SESSION_LOST"};if(t(P.data),P.demonstratingProofOfPossessionNonce){const ee=await pe(y,e.configurationName);ee?await ee.setDemonstratingProofOfPossessionNonce(P.demonstratingProofOfPossessionNonce):await ge(e.configurationName,y.storage).setDemonstratingProofOfPossessionNonce(P.demonstratingProofOfPossessionNonce)}return e.publishEvent(D.refreshTokensAsync_end,{success:P.success}),e.publishEvent(ke.eventNames.token_renewed,{reason:"REFRESH_TOKEN"}),{tokens:P.data,status:"LOGGED_IN"}}else return e.publishEvent(D.refreshTokensAsync_silent_error,{message:"bad request",tokenResponse:P}),P.status>=400&&P.status<500?(t(null),e.publishEvent(D.refreshTokensAsync_error,{message:`session lost: ${P.status}`}),{tokens:null,status:"SESSION_LOST"}):await pt(e)(t,h,m,o,s,i)})()}}}catch(b){return console.error(b),e.publishEvent(D.refreshTokensAsync_silent_error,{message:"exception",exception:b.message}),new Promise((k,x)=>{setTimeout(()=>{pt(e)(t,h,m,o,s,i).then(k).catch(x)},1e3)})}},An=(e,t,n)=>(r=null,o=null,s=null)=>{if(!t.silent_redirect_uri||!t.silent_login_uri)return Promise.resolve(null);try{n(D.silentLoginAsync_begin,{});let i="";if(o&&(r==null&&(r={}),r.state=o),s!=null&&(r==null&&(r={}),r.scope=s),r!=null)for(const[h,m]of Object.entries(r))i===""?i=`?${encodeURIComponent(h)}=${encodeURIComponent(m)}`:i+=`&${encodeURIComponent(h)}=${encodeURIComponent(m)}`;const a=t.silent_login_uri+i,u=a.indexOf("/",a.indexOf("//")+2),f=a.substring(0,u),d=document.createElement("iframe");return d.width="0px",d.height="0px",d.id=`${e}_oidc_iframe`,d.setAttribute("src",a),document.body.appendChild(d),new Promise((h,m)=>{let y=!1;const g=()=>{window.removeEventListener("message",l),d.remove(),y=!0},l=b=>{if(b.origin===f&&b.source===d.contentWindow){const k=`${e}_oidc_tokens:`,x=`${e}_oidc_error:`,E=`${e}_oidc_exception:`,T=b.data;if(T&&typeof T=="string"&&!y){if(T.startsWith(k)){const _=JSON.parse(b.data.replace(k,""));n(D.silentLoginAsync_end,{}),h(_),g()}else if(T.startsWith(x)){const _=JSON.parse(b.data.replace(x,""));n(D.silentLoginAsync_error,_),h({error:"oidc_"+_.error,tokens:null,sessionState:null}),g()}else if(T.startsWith(E)){const _=JSON.parse(b.data.replace(E,""));n(D.silentLoginAsync_error,_),m(new Error(_.error)),g()}}}};try{window.addEventListener("message",l);const b=t.silent_login_timeout;setTimeout(()=>{y||(g(),n(D.silentLoginAsync_error,{reason:"timeout"}),m(new Error("timeout")))},b)}catch(b){g(),n(D.silentLoginAsync_error,b),m(b)}})}catch(i){throw n(D.silentLoginAsync_error,i),i}},qa=(e,t,n,r,o)=>(s=null,i=void 0)=>{s={...s};const a=(u,f,d)=>An(t,n,r.bind(o))(u,f,d);return(async()=>{o.timeoutId&&Ge.clearTimeout(o.timeoutId);let u;s&&"state"in s&&(u=s.state,delete s.state);try{const f=n.extras?{...n.extras,...s}:s,d=await a({...f,prompt:"none"},u,i);if(d)return o.tokens=d.tokens,r(D.token_acquired,{}),o.timeoutId=ot(o,o.tokens.expiresAt,s,i),{}}catch(f){return f}})()},Ga=(e,t,n)=>(r,o,s,i=!1)=>{const a=(u,f=void 0,d=void 0)=>An(e.configurationName,n,e.publishEvent.bind(e))(u,f,d);return new Promise((u,f)=>{if(n.silent_login_uri&&n.silent_redirect_uri&&n.monitor_session&&r&&s&&!i){const d=()=>{e.checkSessionIFrame.stop();const h=e.tokens;if(h===null)return;const m=h.idToken,y=h.idTokenPayload;return a({prompt:"none",id_token_hint:m,scope:n.scope||"openid"}).then(g=>{if(g.error)throw new Error(g.error);const l=g.tokens.idTokenPayload;if(y.sub===l.sub){const b=g.sessionState;e.checkSessionIFrame.start(g.sessionState),y.sid===l.sid?console.debug("SessionMonitor._callback: Same sub still logged in at OP, restarting check session iframe; session_state:",b):console.debug("SessionMonitor._callback: Same sub still logged in at OP, session state has changed, restarting check session iframe; session_state:",b)}else console.debug("SessionMonitor._callback: Different subject signed into OP:",l.sub)}).catch(async g=>{console.warn("SessionMonitor._callback: Silent login failed, logging out other tabs:",g);for(const[,l]of Object.entries(t))await l.logoutOtherTabAsync(n.client_id,y.sub)})};e.checkSessionIFrame=new wa(d,o,r),e.checkSessionIFrame.load().then(()=>{e.checkSessionIFrame.start(s),u(e.checkSessionIFrame)}).catch(h=>{f(h)})}else u(null)})},Ja=e=>!!(e.os==="iOS"&&e.osVersion.startsWith("12")||e.os==="Mac OS X"&&e.osVersion.startsWith("10_15_6")),Xa=e=>{const t=e.appVersion,n=e.userAgent,r="-";let o=r;const s=[{s:"Windows 10",r:/(Windows 10.0|Windows NT 10.0)/},{s:"Windows 8.1",r:/(Windows 8.1|Windows NT 6.3)/},{s:"Windows 8",r:/(Windows 8|Windows NT 6.2)/},{s:"Windows 7",r:/(Windows 7|Windows NT 6.1)/},{s:"Windows Vista",r:/Windows NT 6.0/},{s:"Windows Server 2003",r:/Windows NT 5.2/},{s:"Windows XP",r:/(Windows NT 5.1|Windows XP)/},{s:"Windows 2000",r:/(Windows NT 5.0|Windows 2000)/},{s:"Windows ME",r:/(Win 9x 4.90|Windows ME)/},{s:"Windows 98",r:/(Windows 98|Win98)/},{s:"Windows 95",r:/(Windows 95|Win95|Windows_95)/},{s:"Windows NT 4.0",r:/(Windows NT 4.0|WinNT4.0|WinNT|Windows NT)/},{s:"Windows CE",r:/Windows CE/},{s:"Windows 3.11",r:/Win16/},{s:"Android",r:/Android/},{s:"Open BSD",r:/OpenBSD/},{s:"Sun OS",r:/SunOS/},{s:"Chrome OS",r:/CrOS/},{s:"Linux",r:/(Linux|X11(?!.*CrOS))/},{s:"iOS",r:/(iPhone|iPad|iPod)/},{s:"Mac OS X",r:/Mac OS X/},{s:"Mac OS",r:/(Mac OS|MacPPC|MacIntel|Mac_PowerPC|Macintosh)/},{s:"QNX",r:/QNX/},{s:"UNIX",r:/UNIX/},{s:"BeOS",r:/BeOS/},{s:"OS/2",r:/OS\/2/},{s:"Search Bot",r:/(nuhk|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask Jeeves\/Teoma|ia_archiver)/}];for(const a in s){const u=s[a];if(u.r.test(n)){o=u.s;break}}let i=r;switch(/Windows/.test(o)&&(i=/Windows (.*)/.exec(o)[1],o="Windows"),o){case"Mac OS":case"Mac OS X":case"Android":i=/(?:Android|Mac OS|Mac OS X|MacPPC|MacIntel|Mac_PowerPC|Macintosh) ([._\d]+)/.exec(n)[1];break;case"iOS":{const a=/OS (\d+)_(\d+)_?(\d+)?/.exec(t);a!=null&&a.length>2&&(i=a[1]+"."+a[2]+"."+(parseInt(a[3])|0));break}}return{os:o,osVersion:i}};function Qa(){const e=navigator.userAgent;let t,n=e.match(/(opera|chrome|safari|firefox|msie|trident(?=\/))\/?\s*(\d+)/i)||[];if(/trident/i.test(n[1]))return t=/\brv[ :]+(\d+)/g.exec(e)||[],{name:"ie",version:t[1]||""};if(n[1]==="Chrome"&&(t=e.match(/\bOPR|Edge\/(\d+)/),t!=null)){let r=t[1];if(!r){const o=e.split(t[0]+"/");o.length>1&&(r=o[1])}return{name:"opera",version:r}}return n=n[2]?[n[1],n[2]]:[navigator.appName,navigator.appVersion,"-?"],(t=e.match(/version\/(\d+)/i))!=null&&n.splice(1,1,t[1]),{name:n[0].toLowerCase(),version:n[1]}}const Za=()=>{const{name:e,version:t}=Qa();if(e==="chrome"&&parseInt(t)<=70||e==="opera"&&(!t||parseInt(t.split(".")[0])<80)||e==="ie")return!1;const n=Xa(navigator);return!Ja(n)},ec=async e=>{let t;if(e.tokens!=null)return!1;e.publishEvent(D.tryKeepExistingSessionAsync_begin,{});try{const n=e.configuration,r=await e.initAsync(n.authority,n.authority_configuration);if(t=await pe(n,e.configurationName),t){const{tokens:o}=await t.initAsync(r,"tryKeepExistingSessionAsync",n);if(o){t.startKeepAliveServiceWorker(),e.tokens=o;const s=t.getLoginParams(e.configurationName);e.timeoutId=ot(e,e.tokens.expiresAt,s.extras,s.scope);const i=await t.getSessionStateAsync();return await e.startCheckSessionAsync(r.checkSessionIframe,n.client_id,i),n.preload_user_info&&await e.userInfoAsync(),e.publishEvent(D.tryKeepExistingSessionAsync_end,{success:!0,message:"tokens inside ServiceWorker are valid"}),!0}e.publishEvent(D.tryKeepExistingSessionAsync_end,{success:!1,message:"no exiting session found"})}else{n.service_worker_relative_url&&e.publishEvent(D.service_worker_not_supported_by_browser,{message:"service worker is not supported by this browser"});const o=ge(e.configurationName,n.storage??sessionStorage),{tokens:s}=await o.initAsync();if(s){e.tokens=vn(s,null,n.token_renew_mode);const i=o.getLoginParams();e.timeoutId=ot(e,e.tokens.expiresAt,i.extras,i.scope);const a=await o.getSessionStateAsync();return await e.startCheckSessionAsync(r.checkSessionIframe,n.client_id,a),n.preload_user_info&&await e.userInfoAsync(),e.publishEvent(D.tryKeepExistingSessionAsync_end,{success:!0,message:"tokens inside storage are valid"}),!0}}return e.publishEvent(D.tryKeepExistingSessionAsync_end,{success:!1,message:t?"service worker sessions not retrieved":"session storage sessions not retrieved"}),!1}catch(n){return console.error(n),t&&await t.clearAsync(),e.publishEvent(D.tryKeepExistingSessionAsync_error,"tokens inside ServiceWorker are invalid"),!1}},Xr=e=>{const t=e.match(/^([a-z][\w-]+\:)\/\/(([^:\/?#]*)(?:\:([0-9]+))?)([\/]{0,1}[^?#]*)(\?[^#]*|)(#.*|)$/);if(!t)throw new Error("Invalid URL");let n=t[6],r=t[7];if(r){const o=r.split("?");o.length===2&&(r=o[0],n=o[1])}return n.startsWith("?")&&(n=n.slice(1)),t&&{href:e,protocol:t[1],host:t[2],hostname:t[3],port:t[4],path:t[5],search:n,hash:r}},Xe=e=>{const t=Xr(e);let{path:n}=t;n.endsWith("/")&&(n=n.slice(0,-1));let{hash:r}=t;return r==="#_=_"&&(r=""),r&&(n+=r),n},xt=e=>{const t=Xr(e),{search:n}=t;return tc(n)},tc=e=>{const t={};let n,r,o;const s=e.split("&");for(r=0,o=s.length;r<o;r++)n=s[r].split("="),t[decodeURIComponent(n[0])]=decodeURIComponent(n[1]);return t},nc=(e,t,n,r,o)=>(s=void 0,i=null,a=!1,u=void 0)=>{const f=i;return i={...i},(async()=>{const d=s||o.getPath();if("state"in i||(i.state=cn(16)),n(D.loginAsync_begin,{}),i)for(const h of Object.keys(i))h.endsWith(":token_request")&&delete i[h];try{const h=a?t.silent_redirect_uri:t.redirect_uri;u||(u=t.scope);const m=t.extras?{...t.extras,...i}:i;m.nonce||(m.nonce=cn(12));const y={nonce:m.nonce},g=await pe(t,e),l=await r(t.authority,t.authority_configuration);let b;if(g)g.setLoginParams({callbackPath:d,extras:f,scope:u}),await g.initAsync(l,"loginAsync",t),await g.setNonceAsync(y),g.startKeepAliveServiceWorker(),b=g;else{const x=ge(e,t.storage??sessionStorage);x.setLoginParams({callbackPath:d,extras:f,scope:u}),await x.setNonceAsync(y),b=x}const k={client_id:t.client_id,redirect_uri:h,scope:u,response_type:"code",...m};await Ka(b,o)(l.authorizationEndpoint,k)}catch(h){throw n(D.loginAsync_error,h),h}})()},rc=e=>async(t=!1)=>{try{e.publishEvent(D.loginCallbackAsync_begin,{});const n=e.configuration,r=n.client_id,o=t?n.silent_redirect_uri:n.redirect_uri,s=n.authority,i=n.token_request_timeout,a=await e.initAsync(s,n.authority_configuration),u=e.location.getCurrentHref(),f=xt(u),d=f.session_state,h=await pe(n,e.configurationName);let m,y,g,l;if(h)await h.initAsync(a,"loginCallbackAsync",n),await h.setSessionStateAsync(d),y=await h.getNonceAsync(),g=h.getLoginParams(),l=await h.getStateAsync(),h.startKeepAliveServiceWorker(),m=h;else{const c=ge(e.configurationName,n.storage??sessionStorage);await c.setSessionStateAsync(d),y=await c.getNonceAsync(),g=c.getLoginParams(),l=await c.getStateAsync(),m=c}if(f.error||f.error_description)throw new Error(`Error from OIDC server: ${f.error} - ${f.error_description}`);if(f.iss&&f.iss!==a.issuer)throw console.error(),new Error(`Issuer not valid (expected: ${a.issuer}, received: ${f.iss})`);if(f.state&&f.state!==l)throw new Error(`State not valid (expected: ${l}, received: ${f.state})`);const b={code:f.code,grant_type:"authorization_code",client_id:n.client_id,redirect_uri:o},k={};if(n.token_request_extras)for(const[c,A]of Object.entries(n.token_request_extras))k[c]=A;if(g!=null&&g.extras)for(const[c,A]of Object.entries(g.extras))c.endsWith(":token_request")&&(k[c.replace(":token_request","")]=A);const x=a.tokenEndpoint,E={};if(n.demonstrating_proof_of_possession)if(h)E.DPoP=`DPOP_SECURED_BY_OIDC_SERVICE_WORKER_${e.configurationName}`;else{const c=await Ma(window)(n.demonstrating_proof_of_possession_configuration.generateKeyAlgorithm);await ge(e.configurationName,n.storage).setDemonstratingProofOfPossessionJwkAsync(c),E.DPoP=await Yr(window)(n.demonstrating_proof_of_possession_configuration)(c,"POST",x)}const T=await Ha(m)(x,{...b,...k},E,e.configuration.token_renew_mode,i);if(!T.success)throw new Error("Token request failed");let _;const N=T.data.tokens,v=T.data.demonstratingProofOfPossessionNonce;if(T.data.state!==k.state)throw new Error("state is not valid");const{isValid:I,reason:F}=Vr(N,y.nonce,a);if(!I)throw new Error(`Tokens are not OpenID valid, reason: ${F}`);if(h){if(N.refreshToken&&!N.refreshToken.includes("SECURED_BY_OIDC_SERVICE_WORKER"))throw new Error("Refresh token should be hidden by service worker");if(v&&N!=null&&N.accessToken.includes("SECURED_BY_OIDC_SERVICE_WORKER"))throw new Error("Demonstration of proof of possession require Access token not hidden by service worker")}if(h)await h.initAsync(a,"syncTokensAsync",n),_=h.getLoginParams(),v&&await h.setDemonstratingProofOfPossessionNonce(v);else{const c=ge(e.configurationName,n.storage);_=c.getLoginParams(),v&&await c.setDemonstratingProofOfPossessionNonce(v)}return await e.startCheckSessionAsync(a.checkSessionIframe,r,d,t),e.publishEvent(D.loginCallbackAsync_end,{}),{tokens:N,state:"request.state",callbackPath:_.callbackPath,scope:f.scope,extras:_.extras}}catch(n){throw console.error(n),e.publishEvent(D.loginCallbackAsync_error,n),n}},_r={access_token:"access_token",refresh_token:"refresh_token"},Zt=(e,t)=>{const n={};if(e){for(const[r,o]of Object.entries(e))if(r.endsWith(t)){const s=r.replace(t,"");n[s]=o}return n}return n},oc=e=>{const t={};if(e){for(const[n,r]of Object.entries(e))n.includes(":")||(t[n]=r);return t}return t},sc=e=>async t=>{Ge.clearTimeout(e.timeoutId),e.timeoutId=null,e.checkSessionIFrame&&e.checkSessionIFrame.stop();const n=await pe(e.configuration,e.configurationName);n?await n.clearAsync(t):await ge(e.configurationName,e.configuration.storage).clearAsync(t),e.tokens=null,e.userInfo=null},ic=(e,t,n,r,o)=>async(s=void 0,i=null)=>{var a,u;const f=e.configuration,d=await e.initAsync(f.authority,f.authority_configuration);s&&typeof s!="string"&&(s=void 0,r.warn("callbackPathOrUrl path is not a string"));const h=s??o.getPath();let m=!1;s&&(m=s.includes("https://")||s.includes("http://"));const y=m?s:o.getOrigin()+h,g=e.tokens?e.tokens.idToken:"";try{const x=d.revocationEndpoint;if(x){const E=[],T=e.tokens?e.tokens.accessToken:null;if(T&&f.logout_tokens_to_invalidate.includes(_r.access_token)){const N=Zt(i,":revoke_access_token"),v=pr(n)(x,T,ln.access_token,f.client_id,N);E.push(v)}const _=e.tokens?e.tokens.refreshToken:null;if(_&&f.logout_tokens_to_invalidate.includes(_r.refresh_token)){const N=Zt(i,":revoke_refresh_token"),v=pr(n)(x,_,ln.refresh_token,f.client_id,N);E.push(v)}E.length>0&&await Promise.all(E)}}catch(x){r.warn("logoutAsync: error when revoking tokens, if the error persist, you ay configure property logout_tokens_to_invalidate from configuration to avoid this error"),r.warn(x)}const l=((u=(a=e.tokens)==null?void 0:a.idTokenPayload)==null?void 0:u.sub)??null;await e.destroyAsync("LOGGED_OUT");for(const[,x]of Object.entries(t))x!==e?await e.logoutSameTabAsync(e.configuration.client_id,l):e.publishEvent(D.logout_from_same_tab,{});const b=Zt(i,":oidc");if(b&&b.no_reload==="true")return;const k=oc(i);if(d.endSessionEndpoint){"id_token_hint"in k||(k.id_token_hint=g),!("post_logout_redirect_uri"in k)&&s!==null&&(k.post_logout_redirect_uri=y);let x="";for(const[E,T]of Object.entries(k))T!=null&&(x===""?x+="?":x+="&",x+=`${E}=${encodeURIComponent(T)}`);o.open(`${d.endSessionEndpoint}${x}`)}else o.reload()},Qr=(e,t,n=!1)=>async(...r)=>{var o;const[s,i,...a]=r,u=i?{...i}:{method:"GET"};let f=new Headers;u.headers&&(f=u.headers instanceof Headers?u.headers:new Headers(u.headers));const d={getTokens:()=>t.tokens,configuration:{token_automatic_renew_mode:t.configuration.token_automatic_renew_mode,refresh_time_before_tokens_expiration_in_second:t.configuration.refresh_time_before_tokens_expiration_in_second},renewTokensAsync:t.renewTokensAsync.bind(t)},h=await Fr(d),m=(o=h==null?void 0:h.tokens)==null?void 0:o.accessToken;if(f.has("Accept")||f.set("Accept","application/json"),m){if(t.configuration.demonstrating_proof_of_possession&&n){const g=await t.generateDemonstrationOfProofOfPossessionAsync(m,s.toString(),u.method);f.set("Authorization",`DPoP ${m}`),f.set("DPoP",g)}else f.set("Authorization",`Bearer ${m}`);u.credentials||(u.credentials="same-origin")}const y={...u,headers:f};return await e(s,y,...a)},ac=e=>async(t=!1,n=!1)=>{if(e.userInfo!=null&&!t)return e.userInfo;const r=e.configuration,o=(await e.initAsync(r.authority,r.authority_configuration)).userInfoEndpoint,s=await(async()=>{const i=await Qr(fetch,e,n)(o);return i.status!==200?null:i.json()})();return e.userInfo=s,s},cc=()=>fetch;class un{constructor(t){this.authorizationEndpoint=t.authorization_endpoint,this.tokenEndpoint=t.token_endpoint,this.revocationEndpoint=t.revocation_endpoint,this.userInfoEndpoint=t.userinfo_endpoint,this.checkSessionIframe=t.check_session_iframe,this.issuer=t.issuer,this.endSessionEndpoint=t.end_session_endpoint}}const $e={},lc=(e,t=new At)=>(n,r="default")=>($e[r]||($e[r]=new ke(n,r,e,t)),$e[r]),uc=async e=>{const{parsedTokens:t,callbackPath:n,extras:r,scope:o}=await e.loginCallbackAsync();return e.timeoutId=ot(e,t.expiresAt,r,o),{callbackPath:n}},fc=e=>Math.floor(Math.random()*e),fn=class Zr{constructor(t,n="default",r,o=new At){this.initPromise=null,this.tryKeepExistingSessionPromise=null,this.loginPromise=null,this.loginCallbackPromise=null,this.loginCallbackWithAutoTokensRenewPromise=null,this.userInfoPromise=null,this.renewTokensPromise=null,this.logoutPromise=null;let s=t.silent_login_uri;t.silent_redirect_uri&&!t.silent_login_uri&&(s=`${t.silent_redirect_uri.replace("-callback","").replace("callback","")}-login`);let i=t.refresh_time_before_tokens_expiration_in_second??120;i>60&&(i=i-Math.floor(Math.random()*40)),this.location=o??new At,this.configuration={...t,silent_login_uri:s,token_automatic_renew_mode:t.token_automatic_renew_mode??rt.AutomaticBeforeTokenExpiration,monitor_session:t.monitor_session??!1,refresh_time_before_tokens_expiration_in_second:i,silent_login_timeout:t.silent_login_timeout??12e3,token_renew_mode:t.token_renew_mode??sn.access_token_or_id_token_invalid,demonstrating_proof_of_possession:t.demonstrating_proof_of_possession??!1,authority_timeout_wellknowurl_in_millisecond:t.authority_timeout_wellknowurl_in_millisecond??1e4,logout_tokens_to_invalidate:t.logout_tokens_to_invalidate??["access_token","refresh_token"],service_worker_activate:t.service_worker_activate??Za,demonstrating_proof_of_possession_configuration:t.demonstrating_proof_of_possession_configuration??xa,preload_user_info:t.preload_user_info??!1},this.getFetch=r??cc,this.configurationName=n,this.tokens=null,this.userInfo=null,this.events=[],this.timeoutId=null,this.loginCallbackWithAutoTokensRenewAsync.bind(this),this.initAsync.bind(this),this.loginCallbackAsync.bind(this),this.subscribeEvents.bind(this),this.removeEventSubscription.bind(this),this.publishEvent.bind(this),this.destroyAsync.bind(this),this.logoutAsync.bind(this),this.renewTokensAsync.bind(this),this.initAsync(this.configuration.authority,this.configuration.authority_configuration)}subscribeEvents(t){const n=fc(9999999999999).toString();return this.events.push({id:n,func:t}),n}removeEventSubscription(t){const n=this.events.filter(r=>r.id!==t);this.events=n}publishEvent(t,n){this.events.forEach(r=>{r.func(t,n)})}static get(t="default"){const n=typeof process>"u";if(!Object.prototype.hasOwnProperty.call($e,t)&&n)throw Error(`OIDC library does seem initialized.
|
|
75
|
+
Please checkout that you are using OIDC hook inside a <OidcProvider configurationName="${t}"></OidcProvider> component.`);return $e[t]}_silentLoginCallbackFromIFrame(){if(this.configuration.silent_redirect_uri&&this.configuration.silent_login_uri){const t=this.location,n=xt(t.getCurrentHref());window.parent.postMessage(`${this.configurationName}_oidc_tokens:${JSON.stringify({tokens:this.tokens,sessionState:n.session_state})}`,t.getOrigin())}}_silentLoginErrorCallbackFromIFrame(t=null){if(this.configuration.silent_redirect_uri&&this.configuration.silent_login_uri){const n=this.location,r=xt(n.getCurrentHref());r.error?window.parent.postMessage(`${this.configurationName}_oidc_error:${JSON.stringify({error:r.error})}`,n.getOrigin()):window.parent.postMessage(`${this.configurationName}_oidc_exception:${JSON.stringify({error:t==null?"":t.toString()})}`,n.getOrigin())}}async silentLoginCallbackAsync(){try{await this.loginCallbackAsync(!0),this._silentLoginCallbackFromIFrame()}catch(t){console.error(t),this._silentLoginErrorCallbackFromIFrame(t)}}async initAsync(t,n){if(this.initPromise!==null)return this.initPromise;const r=async()=>{if(n!=null)return new un({authorization_endpoint:n.authorization_endpoint,end_session_endpoint:n.end_session_endpoint,revocation_endpoint:n.revocation_endpoint,token_endpoint:n.token_endpoint,userinfo_endpoint:n.userinfo_endpoint,check_session_iframe:n.check_session_iframe,issuer:n.issuer});const o=await pe(this.configuration,this.configurationName)?window.sessionStorage:null;return await Ua(this.getFetch())(t,this.configuration.authority_time_cache_wellknowurl_in_second??60*60,o,this.configuration.authority_timeout_wellknowurl_in_millisecond)};return this.initPromise=r(),this.initPromise.finally(()=>{this.initPromise=null})}async tryKeepExistingSessionAsync(){return this.tryKeepExistingSessionPromise!==null?this.tryKeepExistingSessionPromise:(this.tryKeepExistingSessionPromise=ec(this),this.tryKeepExistingSessionPromise.finally(()=>{this.tryKeepExistingSessionPromise=null}))}async startCheckSessionAsync(t,n,r,o=!1){await Ga(this,$e,this.configuration)(t,n,r,o)}async loginAsync(t=void 0,n=null,r=!1,o=void 0,s=!1){return this.logoutPromise&&await this.logoutPromise,this.loginPromise!==null?this.loginPromise:(s?this.loginPromise=qa(window,this.configurationName,this.configuration,this.publishEvent.bind(this),this)(n,o):this.loginPromise=nc(this.configurationName,this.configuration,this.publishEvent.bind(this),this.initAsync.bind(this),this.location)(t,n,r,o),this.loginPromise.finally(()=>{this.loginPromise=null}))}async loginCallbackAsync(t=!1){if(this.loginCallbackPromise!==null)return this.loginCallbackPromise;const n=async()=>{const r=await rc(this)(t),o=r.tokens;return this.tokens=o,await pe(this.configuration,this.configurationName)||ge(this.configurationName,this.configuration.storage).setTokens(o),this.publishEvent(Zr.eventNames.token_acquired,o),this.configuration.preload_user_info&&await this.userInfoAsync(),{parsedTokens:o,state:r.state,callbackPath:r.callbackPath,scope:r.scope,extras:r.extras}};return this.loginCallbackPromise=n(),this.loginCallbackPromise.finally(()=>{this.loginCallbackPromise=null})}async generateDemonstrationOfProofOfPossessionAsync(t,n,r,o={}){const s=this.configuration,i={ath:await Gr(t),...o};if(await pe(s,this.configurationName))return`DPOP_SECURED_BY_OIDC_SERVICE_WORKER_${this.configurationName}#tabId=${zr(this.configurationName)}`;const a=ge(this.configurationName,s.storage),u=await a.getDemonstratingProofOfPossessionJwkAsync(),f=a.getDemonstratingProofOfPossessionNonce();return f&&(i.nonce=f),await Yr(window)(s.demonstrating_proof_of_possession_configuration)(u,r,n,i)}loginCallbackWithAutoTokensRenewAsync(){return this.loginCallbackWithAutoTokensRenewPromise!==null?this.loginCallbackWithAutoTokensRenewPromise:(this.loginCallbackWithAutoTokensRenewPromise=uc(this),this.loginCallbackWithAutoTokensRenewPromise.finally(()=>{this.loginCallbackWithAutoTokensRenewPromise=null}))}userInfoAsync(t=!1,n=!1){return this.userInfoPromise!==null?this.userInfoPromise:(this.userInfoPromise=ac(this)(t,n),this.userInfoPromise.finally(()=>{this.userInfoPromise=null}))}async renewTokensAsync(t=null,n=null){if(this.renewTokensPromise!==null)return this.renewTokensPromise;if(this.timeoutId)return Ge.clearTimeout(this.timeoutId),this.renewTokensPromise=Jr(this,!0,t,n),this.renewTokensPromise.finally(()=>{this.renewTokensPromise=null})}async destroyAsync(t){return await sc(this)(t)}async logoutSameTabAsync(t,n){this.configuration.monitor_session&&this.configuration.client_id===t&&n&&this.tokens&&this.tokens.idTokenPayload&&this.tokens.idTokenPayload.sub===n&&(await this.destroyAsync("LOGGED_OUT"),this.publishEvent(D.logout_from_same_tab,{mmessage:"SessionMonitor",sub:n}))}async logoutOtherTabAsync(t,n){this.configuration.monitor_session&&this.configuration.client_id===t&&n&&this.tokens&&this.tokens.idTokenPayload&&this.tokens.idTokenPayload.sub===n&&(await this.destroyAsync("LOGGED_OUT"),this.publishEvent(D.logout_from_another_tab,{message:"SessionMonitor",sub:n}))}async logoutAsync(t=void 0,n=null){return this.logoutPromise?this.logoutPromise:(this.logoutPromise=ic(this,$e,this.getFetch(),console,this.location)(t,n),this.logoutPromise.finally(()=>{this.logoutPromise=null}))}};fn.getOrCreate=(e,t)=>(n,r="default")=>lc(e,t)(n,r),fn.eventNames=D;let ke=fn;const yt=class eo{constructor(t){this._oidc=t}subscribeEvents(t){return this._oidc.subscribeEvents(t)}removeEventSubscription(t){this._oidc.removeEventSubscription(t)}publishEvent(t,n){this._oidc.publishEvent(t,n)}static get(t="default"){return new eo(ke.get(t))}tryKeepExistingSessionAsync(){return this._oidc.tryKeepExistingSessionAsync()}loginAsync(t=void 0,n=null,r=!1,o=void 0,s=!1){return this._oidc.loginAsync(t,n,r,o,s)}logoutAsync(t=void 0,n=null){return this._oidc.logoutAsync(t,n)}silentLoginCallbackAsync(){return this._oidc.silentLoginCallbackAsync()}renewTokensAsync(t=null,n=null){return this._oidc.renewTokensAsync(t,n)}loginCallbackAsync(){return this._oidc.loginCallbackWithAutoTokensRenewAsync()}get tokens(){return this._oidc.tokens}get configuration(){return this._oidc.configuration}async generateDemonstrationOfProofOfPossessionAsync(t,n,r,o={}){return this._oidc.generateDemonstrationOfProofOfPossessionAsync(t,n,r,o)}async getValidTokenAsync(t=200,n=50){const r=this._oidc,o={getTokens:()=>r.tokens,configuration:{token_automatic_renew_mode:r.configuration.token_automatic_renew_mode,refresh_time_before_tokens_expiration_in_second:r.configuration.refresh_time_before_tokens_expiration_in_second},renewTokensAsync:r.renewTokensAsync.bind(r)};return Fr(o,t,n)}fetchWithTokens(t,n=!1){return Qr(t,this._oidc,n)}async userInfoAsync(t=!1,n=!1){return this._oidc.userInfoAsync(t,n)}userInfo(){return this._oidc.userInfo}};yt.getOrCreate=(e,t=new At)=>(n,r="default")=>new yt(ke.getOrCreate(e,t)(n,r)),yt.eventNames=ke.eventNames;let ce=yt;const dc=()=>S.jsx("div",{className:"oidc-authenticating",children:S.jsxs("div",{className:"oidc-authenticating__container",children:[S.jsx("h1",{className:"oidc-authenticating__title",children:"Error authentication"}),S.jsx("p",{className:"oidc-authenticating__content",children:"An error occurred during authentication."})]})}),hc=()=>Math.random().toString(36).slice(2,8),mc=(e,t)=>(n,r)=>{if(typeof e.CustomEvent=="function")return new e.CustomEvent(n,r);const o=r||{bubbles:!1,cancelable:!1,detail:void 0},s=t.createEvent("CustomEvent");return s.initCustomEvent(n,o.bubbles,o.cancelable,o.detail),s.prototype=e.Event.prototype,s},gc=(e,t,n)=>({replaceState:(r,o)=>{const s=n(),i=o||e.history.state;e.history.replaceState({key:s,state:i},null,r),e.dispatchEvent(t("popstate"))}}),pc=()=>gc(window,mc(window,document),hc),yc=()=>S.jsx("div",{className:"oidc-callback",children:S.jsxs("div",{className:"oidc-callback__container",children:[S.jsx("h1",{className:"oidc-callback__title",children:"Authentication complete"}),S.jsx("p",{className:"oidc-callback__content",children:"You will be redirected to your application."})]})}),_c=({callBackError:e,callBackSuccess:t,configurationName:n,withCustomHistory:r})=>{const[o,s]=se.useState(!1);se.useEffect(()=>{let u=!0;return(async()=>{const f=ce.get;try{const{callbackPath:d}=await f(n).loginCallbackAsync();(r?r():pc()).replaceState(d||"/")}catch(d){u&&(console.warn(d),s(!0))}})(),()=>{u=!1}},[]);const i=e||dc,a=t||yc;return o?S.jsx(i,{configurationName:n}):S.jsx(a,{configurationName:n})},bc=({configurationName:e})=>(se.useEffect(()=>{(async()=>{ce.get(e).silentLoginCallbackAsync()})().catch(t=>{console.error("Error during silent login callback:",t)})},[e]),null),Sc=({configurationName:e})=>{const t=xt(window.location.href),n=ce.get,r=n(e);let o=null;for(const[s,i]of Object.entries(t))s==="state"||s==="scope"||(o===null&&(o={}),o[s]=i);return se.useEffect(()=>{r.tokens||r.loginAsync(null,o,!0,t.scope)},[]),S.jsx(S.Fragment,{})},wc=({callbackErrorComponent:e,callbackSuccessComponent:t,redirect_uri:n,silent_redirect_uri:r,silent_login_uri:o,children:s,configurationName:i,withCustomHistory:a=null})=>{const u=window?Xe(window.location.href):"",[f,d]=se.useState(u);se.useEffect(()=>{const m=()=>d(Xe(window.location.href));return m(),window.addEventListener("popstate",m,!1),()=>window.removeEventListener("popstate",m,!1)},[]);const h=Xe(n);if(r&&f===Xe(r))return S.jsx(bc,{configurationName:i});if(o&&f===Xe(o))return S.jsx(Sc,{configurationName:i});switch(f){case h:return S.jsx(_c,{callBackError:e,callBackSuccess:t,configurationName:i,withCustomHistory:a});default:return S.jsx(S.Fragment,{children:s})}};se.memo(wc);const to="default",en=(e,t)=>{let n=!1;return e(t)&&(n=e(t).tokens!=null),n},vc=(e=to)=>{const t=ce.get,[n,r]=se.useState(en(t,e));return se.useEffect(()=>{let o=!0;const s=t(e);r(en(t,e));const i=s.subscribeEvents((a,u)=>{(a===ce.eventNames.logout_from_another_tab||a===ce.eventNames.logout_from_same_tab||a===ce.eventNames.token_acquired)&&o&&r(en(t,e))});return()=>{o=!1,s.removeEventSubscription(i)}},[e]),{login:(o=void 0,s=void 0,i=!1,a=void 0)=>t(e).loginAsync(o,s,!1,a,i),logout:(o=void 0,s=void 0)=>t(e).logoutAsync(o,s),renewTokens:async(o=void 0)=>{const s=await t(e).renewTokensAsync(o);return{accessToken:s.accessToken,accessTokenPayload:s.accessTokenPayload,idToken:s.idToken,idTokenPayload:s.idTokenPayload}},isAuthenticated:n}},no={idToken:null,idTokenPayload:null},kc=e=>{const t=ce.get,n=t(e);if(n.tokens){const r=n.tokens;return{idToken:r.idToken,idTokenPayload:r.idTokenPayload}}return no},Tc=(e=to)=>{const t=ce.get,[n,r]=se.useState(kc(e));return se.useEffect(()=>{let o=!0;const s=t(e);if(s.tokens){const a=s.tokens;r({idToken:a.idToken,idTokenPayload:a.idTokenPayload})}const i=s.subscribeEvents((a,u)=>{if((a===ce.eventNames.token_renewed||a===ce.eventNames.token_acquired||a===ce.eventNames.logout_from_another_tab||a===ce.eventNames.logout_from_same_tab||a===ce.eventNames.refreshTokensAsync_error||a===ce.eventNames.syncTokensAsync_error)&&o){const f=s.tokens;r(f!=null?{idToken:f.idToken,idTokenPayload:f.idTokenPayload}:no)}});return()=>{o=!1,s.removeEventSubscription(i)}},[e]),n},ro=401,_t=403,bt=404,St=405,wt=409,Ec=500,Ac=501,Cc=502,Oc=503,xc=504,Pc=505,Nc=e=>{const{idToken:t}=Tc(),{login:n}=vc();return st.interceptors.request.use(r=>(t&&(r.headers={...r.headers,Authorization:`Bearer ${t}`}),r.headers={"Content-Type":"application/json",...r.headers},r)),st.interceptors.response.use(r=>r,r=>{const o=r.statusCode;if(o===ro){n().then(s=>s);return}(async()=>{if(o===_t){const u=r.response?await ze(r.response):null,f=(u==null?void 0:u.message)||Ke(_t),d=Ae(r,_t,f,r.response);return console.error("Access Forbidden:",f),Promise.reject(d)}if(o===bt){const u=r.response?await ze(r.response):null,f=(u==null?void 0:u.message)||Ke(bt),d=Ae(r,bt,f,r.response);return console.error("Resource Not Found:",f),Promise.reject(d)}if(o===St){const u=r.response?await ze(r.response):null,f=(u==null?void 0:u.message)||Ke(St),d=Ae(r,St,f,r.response);return Promise.reject(d)}if(o===wt){const u=r.response?await ze(r.response):null,f=(u==null?void 0:u.message)||Ke(wt),d=Ae(r,wt,f,r.response);return Promise.reject(d)}if(o&&o>=500&&o<=599){const u=r.response?await ze(r.response):null,f=(u==null?void 0:u.message)||Ke(o),d=Ae(r,o,f,r.response);return console.error(`Server Error (${o}):`,f),Promise.reject(d)}if(!r.response){const u=Ae(r,0,"Network error. Please check your connection and try again.");return console.error("Network Error:",r.message),Promise.reject(u)}const s=r.response?await ze(r.response):null,i=(s==null?void 0:s.message)||r.message||Ke(o||0),a=Ae(r,o||0,i,r.response);return console.error(`HTTP Error (${o}):`,i),Promise.reject(a)})()}),e.children},ze=async e=>{const t=e.headers.get("content-type");return t!=null&&t.includes("application/json")?await e.json():t!=null&&t.includes("text/")?await e.text():await e.blob()},Ke=e=>{switch(e){case ro:return"Authentication required. Please log in again.";case _t:return"Access denied. You do not have permission to access this resource.";case bt:return"The requested resource was not found.";case St:return"Method not allowed. This operation is not supported.";case wt:return"Conflict. The request conflicts with the current state of the resource.";case Ec:return"Internal server error. Please try again later.";case Ac:return"Not implemented. This feature is not available.";case Cc:return"Bad gateway. The server received an invalid response.";case Oc:return"Service unavailable. The server is temporarily unavailable.";case xc:return"Gateway timeout. The request timed out.";case Pc:return"HTTP version not supported.";default:return"An unexpected error occurred."}},Ae=(e,t,n,r,o)=>{const s=new Error(n);return s.statusCode=t,s.originalError=e,s.response=r,s.request=o,s},Ic=(e,t,n)=>{const r=t.startsWith("http")?t:`${e}${t}`;if(!n)return r;const o=new URL(r);return Object.entries(n).forEach(([s,i])=>{i!=null&&o.searchParams.append(s,String(i))}),o.toString()},$c=async e=>{const t=e.headers.get("content-type");return t!=null&&t.includes("application/json")?await e.json():t!=null&&t.includes("text/")?await e.text():await e.blob()};class Rc{constructor(t=void 0){Me(this,"baseURL");Me(this,"requestInterceptors",[]);Me(this,"responseInterceptors",[]);Me(this,"errorInterceptors",[]);Me(this,"interceptors",{request:{use:t=>{this.requestInterceptors.push(t)}},response:{use:(t,n)=>{t&&this.responseInterceptors.push(t),n&&this.errorInterceptors.push(n)}}});this.baseURL=t}async get(t,n){return this.executeRequest({...n,method:"GET",url:t})}async post(t,n,r){const o=n?JSON.stringify(n):void 0;return this.executeRequest({...r,method:"POST",url:t,body:o})}async put(t,n,r){const o=n?JSON.stringify(n):void 0;return this.executeRequest({...r,method:"PUT",url:t,body:o})}async delete(t,n){return this.executeRequest({...n,method:"DELETE",url:t})}async patch(t,n,r){const o=n?JSON.stringify(n):void 0;return this.executeRequest({...r,method:"PATCH",url:t,body:o})}async request(t){return this.executeRequest(t)}async executeRequest(t){let n=t;for(const a of this.requestInterceptors)n=await a(n);const{url:r,params:o,...s}=n,i=Ic(this.baseURL,r||"",o);try{const a=await fetch(i,s);let d={data:await $c(a),status:a.status,statusText:a.statusText,headers:a.headers,config:n};for(const h of this.responseInterceptors)d=await h(d);return d}catch(a){let u=Ae(a,0,"Network error. Please check your connection and try again.");for(const f of this.errorInterceptors){const d=await f(u);d!==void 0&&(u=d)}throw u}}}const br=new Rc,st=Object.assign(async(e,t)=>(await br.request({...t,method:"GET",url:e})).data,br);function Dc(e){return typeof e=="boolean"?e:typeof e=="string"?e.toLowerCase()==="true":!1}function jc(e){return getComputedStyle(document.documentElement).getPropertyValue(e).trim()}var Cn=(e=>(e.SYSTEM_TIME_ZONE="America/New_York",e.SYSTEM_LOCALE="en-US",e.SYSTEM_DATE_FORMAT="MM/dd/yyyy",e.SYSTEM_DATE_TIME_FORMAT="MM/dd/yyyy hh:mm:ss a",e.ISO_DATE_FORMAT="yyyy-MM-dd",e[e.SYSTEM_COOKIE_TIMEOUT_HOURS=24]="SYSTEM_COOKIE_TIMEOUT_HOURS",e[e.SYSTEM_COOKIE_TIMEOUT_MILLI_SECONDS=36e5]="SYSTEM_COOKIE_TIMEOUT_MILLI_SECONDS",e))(Cn||{});const Mc=()=>{const e=+new Date;return new Date(e+Cn.SYSTEM_COOKIE_TIMEOUT_MILLI_SECONDS)},Lc=e=>tn.format(new Date(e),Cn.ISO_DATE_FORMAT),Bc=(e,t)=>e?tn.format(tn.parseISO(e),t):"";function Wc(e){if(typeof e=="string")return Number.parseInt(e,10)}const Fc=()=>({isLoading:!1,isSuccess:!1,isError:!1,isComplete:!1,message:""}),Vc=e=>({...e,isLoading:!0,isSuccess:!1,isError:!1,message:""}),Uc=(e,t)=>({...e,isLoading:!1,isSuccess:!0,isError:!1,isComplete:!0,message:t||""}),zc=(e,t)=>({...e,isLoading:!1,isSuccess:!1,isError:!0,isComplete:!0,message:t||""});function Kc(e){return e==null?!0:typeof e=="string"?e.trim()==="":!1}const Hc=e=>{try{return decodeURIComponent(e)!==e}catch{return!1}};exports.AppSnackBar=la;exports.CancelButton=Yi;exports.CenteredCircularProgress=fa;exports.ConfirmDialog=da;exports.DeleteButton=Gi;exports.DismissibleAlert=ha;exports.EditIconButton=Xi;exports.ExcelButton=Qi;exports.FetchClient=st;exports.FetchInterceptor=Nc;exports.GoBackButton=ea;exports.HistoryButton=na;exports.LoadingSuccessButton=sa;exports.ManageButton=aa;exports.NextLink=ma;exports.OpenInNewIconLink=pa;exports.QuerySnackBar=ua;exports.ReactIf=ya;exports.SuccessButton=ca;exports.TabPanel=ba;exports.TablePaginationActions=_a;exports.a11yProps=Sa;exports.convertToIsoDate=Lc;exports.fetchClient=st;exports.formatDate=Bc;exports.getCssVariable=jc;exports.httpClient=st;exports.initializeState=Fc;exports.isBlankOrEmpty=Kc;exports.isEncoded=Hc;exports.markError=zc;exports.markLoading=Vc;exports.markSuccess=Uc;exports.parseBoolean=Dc;exports.parseNumber=Wc;exports.setCookieExpirationDate=Mc;
|
|
@@ -1,37 +1,30 @@
|
|
|
1
|
-
// Export all buttons
|
|
2
1
|
export { CancelButton } from './lib/components/buttons/CancelButton';
|
|
3
2
|
export { DeleteButton } from './lib/components/buttons/DeleteButton';
|
|
3
|
+
export { EditIconButton } from './lib/components/buttons/EditIconButton';
|
|
4
|
+
export { ExcelButton } from './lib/components/buttons/ExcelButton';
|
|
4
5
|
export { GoBackButton } from './lib/components/buttons/GoBackButton';
|
|
5
6
|
export { HistoryButton } from './lib/components/buttons/HistoryButton';
|
|
6
7
|
export { LoadingSuccessButton } from './lib/components/buttons/LoadingSuccessButton';
|
|
7
8
|
export { ManageButton } from './lib/components/buttons/ManageButton';
|
|
8
9
|
export { SuccessButton } from './lib/components/buttons/SuccessButton';
|
|
9
|
-
export { ExcelButton } from './lib/components/buttons/ExcelButton';
|
|
10
|
-
export { EditIconButton } from './lib/components/buttons/EditIconButton';
|
|
11
|
-
|
|
12
|
-
// Export snackbar components
|
|
13
10
|
export { AppSnackBar } from './lib/components/snack-bar/AppSnackBar';
|
|
14
11
|
export { QuerySnackBar } from './lib/components/snack-bar/QuerySnackBar';
|
|
15
|
-
|
|
16
|
-
// Export all other components
|
|
17
|
-
export { TablePaginationActions } from './lib/components/table/TablePaginationActions';
|
|
18
|
-
export { TabPanel, a11yProps } from './lib/components/tabs/TabPanel';
|
|
19
|
-
export { NextLink } from './lib/components/NextLink';
|
|
20
12
|
export { CenteredCircularProgress } from './lib/components/CenteredCircularProgress';
|
|
21
13
|
export { ConfirmDialog } from './lib/components/ConfirmationDialog';
|
|
22
14
|
export { DismissibleAlert } from './lib/components/DismissibleAlert';
|
|
15
|
+
export { NextLink } from './lib/components/NextLink';
|
|
23
16
|
export { OpenInNewIconLink } from './lib/components/OpenInNewIconLink';
|
|
24
17
|
export { ReactIf } from './lib/components/ReactIf';
|
|
25
|
-
|
|
26
|
-
|
|
18
|
+
export { TablePaginationActions } from './lib/components/table/TablePaginationActions';
|
|
19
|
+
export { a11yProps, TabPanel } from './lib/components/tabs/TabPanel';
|
|
20
|
+
export { FetchClient as fetchClient, FetchClient, FetchClient as httpClient } from './lib/config/fetch/FetchClient';
|
|
21
|
+
export * from './lib/config/fetch/FetchClientTypes';
|
|
22
|
+
export { FetchInterceptor } from './lib/config/fetch/FetchInterceptor';
|
|
27
23
|
export * from './lib/utils/BooleanUtils';
|
|
24
|
+
export * from './lib/utils/CssUtils';
|
|
28
25
|
export * from './lib/utils/DateUtils';
|
|
29
26
|
export * from './lib/utils/NumberUtils';
|
|
30
27
|
export * from './lib/utils/ProgressStateUtils';
|
|
31
28
|
export * from './lib/utils/StringUtils';
|
|
32
29
|
export * from './lib/utils/UrlUtils';
|
|
33
|
-
export * from './lib/utils/fetchClient';
|
|
34
|
-
export * from './lib/utils/CssUtils';
|
|
35
|
-
|
|
36
|
-
// Export all types
|
|
37
30
|
export * from './lib/types/ProgressState';
|