@perses-dev/prometheus-plugin 0.50.2 → 0.51.0-beta.2
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/LICENSE +183 -183
- package/README.md +41 -0
- package/__mf/css/async/2341.dacad691.css +1 -0
- package/__mf/css/async/5263.dacad691.css +1 -0
- package/__mf/css/async/6759.dacad691.css +1 -0
- package/__mf/font/lato-all-300-normal.322bdf14.woff +0 -0
- package/__mf/font/lato-all-400-normal.63513b00.woff +0 -0
- package/__mf/font/lato-all-700-normal.bb27db94.woff +0 -0
- package/__mf/font/lato-all-900-normal.a27049a3.woff +0 -0
- package/__mf/font/lato-latin-300-normal.c5195215.woff2 +0 -0
- package/__mf/font/lato-latin-400-normal.b7ffde23.woff2 +0 -0
- package/__mf/font/lato-latin-700-normal.d5eb20bc.woff2 +0 -0
- package/__mf/font/lato-latin-900-normal.d884a71c.woff2 +0 -0
- package/__mf/font/lato-latin-ext-300-normal.abcc64a9.woff2 +0 -0
- package/__mf/font/lato-latin-ext-400-normal.6ebed106.woff2 +0 -0
- package/__mf/font/lato-latin-ext-700-normal.8697d1d5.woff2 +0 -0
- package/__mf/font/lato-latin-ext-900-normal.20a2b415.woff2 +0 -0
- package/__mf/js/622.f7592106.js +5 -0
- package/__mf/js/Prometheus.328aad7c.js +5 -0
- package/__mf/js/async/1465.3b5e12d5.js +1 -0
- package/__mf/js/async/1495.6c8b8071.js +1 -0
- package/__mf/js/async/1620.6376bd14.js +2 -0
- package/__mf/js/async/1620.6376bd14.js.LICENSE.txt +9 -0
- package/__mf/js/async/1864.df7c4beb.js +1 -0
- package/__mf/js/async/1950.704c331e.js +1 -0
- package/__mf/js/async/1964.95da06f6.js +2 -0
- package/__mf/js/async/1964.95da06f6.js.LICENSE.txt +9 -0
- package/__mf/js/async/1996.01084c88.js +2 -0
- package/__mf/js/async/1996.01084c88.js.LICENSE.txt +24 -0
- package/__mf/js/async/212.bd5d617a.js +1 -0
- package/__mf/js/async/2316.fec4907a.js +1 -0
- package/__mf/js/async/232.f3523a60.js +1 -0
- package/__mf/js/async/2569.daf868a6.js +10 -0
- package/__mf/js/async/2569.daf868a6.js.LICENSE.txt +27 -0
- package/__mf/js/async/2675.c3b73822.js +1 -0
- package/__mf/js/async/3224.23f0dccf.js +1 -0
- package/__mf/js/async/3355.a4dbcdb0.js +1 -0
- package/__mf/js/async/3436.97c926a4.js +1 -0
- package/__mf/js/async/3818.dde21d04.js +1 -0
- package/__mf/js/async/3871.6915e369.js +1 -0
- package/__mf/js/async/3960.129d5ef5.js +2 -0
- package/__mf/js/async/3960.129d5ef5.js.LICENSE.txt +8 -0
- package/__mf/js/async/4075.b77ca1c7.js +1 -0
- package/__mf/js/async/4238.8e4d29d5.js +1 -0
- package/__mf/js/async/4323.4266fd6a.js +1 -0
- package/__mf/js/async/4421.1bcc1637.js +1 -0
- package/__mf/js/async/4489.3361e7bc.js +29 -0
- package/__mf/js/async/4489.3361e7bc.js.LICENSE.txt +59 -0
- package/__mf/js/async/5214.027c4332.js +1 -0
- package/__mf/js/async/5345.8c2e4b4a.js +1 -0
- package/__mf/js/async/537.6911ea2e.js +1 -0
- package/__mf/js/async/5387.fd6e16d6.js +1 -0
- package/__mf/js/async/5654.ecb41aea.js +38 -0
- package/__mf/js/async/5724.6ee6ec51.js +1 -0
- package/__mf/js/async/5774.9b0b6be1.js +1 -0
- package/__mf/js/async/5790.2273e061.js +1 -0
- package/__mf/js/async/5913.9d30fd07.js +73 -0
- package/__mf/js/async/5913.9d30fd07.js.LICENSE.txt +19 -0
- package/__mf/js/async/5914.bd342d22.js +74 -0
- package/__mf/js/async/5981.40bed0d0.js +2 -0
- package/__mf/js/async/5981.40bed0d0.js.LICENSE.txt +8 -0
- package/__mf/js/async/6292.7b8efa78.js +1 -0
- package/__mf/js/async/6333.865a46e0.js +2 -0
- package/__mf/js/async/6333.865a46e0.js.LICENSE.txt +9 -0
- package/__mf/js/async/6377.ca974d89.js +2 -0
- package/__mf/js/async/6377.ca974d89.js.LICENSE.txt +32 -0
- package/__mf/js/async/6770.adb1c939.js +1 -0
- package/__mf/js/async/684.ca510333.js +1 -0
- package/__mf/js/async/694.f861d67c.js +1 -0
- package/__mf/js/async/7272.a763aa92.js +1 -0
- package/__mf/js/async/738.aca54e25.js +1 -0
- package/__mf/js/async/7740.0c5363fd.js +1 -0
- package/__mf/js/async/8265.b9e2c31e.js +1 -0
- package/__mf/js/async/8488.5237550f.js +1 -0
- package/__mf/js/async/8587.4891ea90.js +1 -0
- package/__mf/js/async/8610.8300df79.js +1 -0
- package/__mf/js/async/87.fdc843ac.js +1 -0
- package/__mf/js/async/8930.9fbbc975.js +1 -0
- package/__mf/js/async/8997.18901f45.js +28 -0
- package/__mf/js/async/9173.e8fbead5.js +2 -0
- package/__mf/js/async/9173.e8fbead5.js.LICENSE.txt +19 -0
- package/__mf/js/async/__federation_expose_PrometheusDatasource.f6f57299.js +1 -0
- package/__mf/js/async/__federation_expose_PrometheusExplorer.5fcf955a.js +1 -0
- package/__mf/js/async/__federation_expose_PrometheusLabelNamesVariable.86d0ad5a.js +1 -0
- package/__mf/js/async/__federation_expose_PrometheusLabelValuesVariable.b2893484.js +1 -0
- package/__mf/js/async/__federation_expose_PrometheusPromQLVariable.cd16f6e8.js +1 -0
- package/__mf/js/async/__federation_expose_PrometheusTimeSeriesQuery.eb9eefa6.js +1 -0
- package/__mf/js/main.154a5b65.js +1 -0
- package/lib/bootstrap.d.ts +2 -0
- package/lib/bootstrap.d.ts.map +1 -0
- package/lib/bootstrap.js +19 -0
- package/lib/bootstrap.js.map +1 -0
- package/lib/cjs/bootstrap.js +26 -0
- package/{dist → lib}/cjs/components/PromQLEditor.js +9 -7
- package/lib/cjs/components/TreeNode.js +492 -0
- package/{dist → lib}/cjs/components/promql/ast.js +21 -21
- package/lib/cjs/components/promql/functionSignatures.js +651 -0
- package/lib/cjs/components/promql/serialize.js +88 -0
- package/{dist → lib}/cjs/components/promql/utils.js +12 -1
- package/{dist/cjs/components/parse.js → lib/cjs/components/query.js} +37 -4
- package/lib/cjs/env.d.js +14 -0
- package/lib/cjs/explore/PrometheusExplorer.js +203 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/PrometheusMetricsFinder.js +268 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/display/MetricChip.js +61 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/display/list/MetricList.js +179 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/filter/FilterInputs.js +231 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/filter/FinderFilters.js +97 -0
- package/{dist/cjs/plugins/prometheus-time-series-query → lib/cjs/explore/PrometheusMetricsFinder}/index.js +1 -1
- package/lib/cjs/explore/PrometheusMetricsFinder/overview/MetricOverview.js +235 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/overview/tabs/JobTab.js +144 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/overview/tabs/OverviewTab.js +423 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/overview/tabs/SimilarTab.js +53 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/types.js +25 -0
- package/lib/cjs/explore/PrometheusMetricsFinder/utils.js +203 -0
- package/lib/cjs/explore/index.js +19 -0
- package/lib/cjs/getPluginModule.js +27 -0
- package/lib/cjs/index-federation.js +55 -0
- package/lib/cjs/index.js +28 -0
- package/{dist → lib}/cjs/model/api-types.js +1 -1
- package/{dist → lib}/cjs/model/prometheus-client.js +1 -1
- package/lib/cjs/plugins/PrometheusDatasourceEditor.js +109 -0
- package/lib/cjs/plugins/PrometheusLabelNamesVariable.js +34 -0
- package/lib/cjs/plugins/PrometheusLabelValuesVariable.js +38 -0
- package/lib/cjs/plugins/PrometheusPromQLVariable.js +42 -0
- package/lib/cjs/plugins/index.js +26 -0
- package/{dist → lib}/cjs/plugins/prometheus-datasource.js +9 -9
- package/{dist → lib}/cjs/plugins/prometheus-time-series-query/PrometheusTimeSeriesQueryEditor.js +11 -9
- package/{dist → lib}/cjs/plugins/prometheus-time-series-query/get-time-series-data.js +51 -29
- package/lib/cjs/plugins/prometheus-time-series-query/index.js +35 -0
- package/{dist → lib}/cjs/plugins/prometheus-variables.js +25 -101
- package/{dist → lib}/cjs/plugins/variable.js +1 -2
- package/lib/cjs/setup-tests.js +19 -0
- package/{dist → lib}/cjs/utils/utils.js +1 -2
- package/lib/components/PromQLEditor.d.ts.map +1 -0
- package/{dist → lib}/components/PromQLEditor.js +9 -7
- package/lib/components/PromQLEditor.js.map +1 -0
- package/lib/components/TreeNode.d.ts +15 -0
- package/lib/components/TreeNode.d.ts.map +1 -0
- package/lib/components/TreeNode.js +479 -0
- package/lib/components/TreeNode.js.map +1 -0
- package/lib/components/index.d.ts.map +1 -0
- package/lib/components/index.js.map +1 -0
- package/lib/components/promql/ast.d.ts.map +1 -0
- package/{dist → lib}/components/promql/ast.js +21 -21
- package/lib/components/promql/ast.js.map +1 -0
- package/{dist → lib}/components/promql/format.d.ts +1 -1
- package/lib/components/promql/format.d.ts.map +1 -0
- package/lib/components/promql/format.js.map +1 -0
- package/lib/components/promql/functionSignatures.d.ts +3 -0
- package/lib/components/promql/functionSignatures.d.ts.map +1 -0
- package/lib/components/promql/functionSignatures.js +643 -0
- package/lib/components/promql/functionSignatures.js.map +1 -0
- package/lib/components/promql/serialize.d.ts +4 -0
- package/lib/components/promql/serialize.d.ts.map +1 -0
- package/lib/components/promql/serialize.js +80 -0
- package/lib/components/promql/serialize.js.map +1 -0
- package/{dist → lib}/components/promql/utils.d.ts +1 -0
- package/lib/components/promql/utils.d.ts.map +1 -0
- package/{dist → lib}/components/promql/utils.js +9 -1
- package/lib/components/promql/utils.js.map +1 -0
- package/lib/components/query.d.ts +6 -0
- package/lib/components/query.d.ts.map +1 -0
- package/{dist/components/parse.js → lib/components/query.js} +27 -2
- package/lib/components/query.js.map +1 -0
- package/lib/env.d.js +15 -0
- package/lib/env.d.js.map +1 -0
- package/lib/explore/PrometheusExplorer.d.ts +3 -0
- package/lib/explore/PrometheusExplorer.d.ts.map +1 -0
- package/lib/explore/PrometheusExplorer.js +190 -0
- package/lib/explore/PrometheusExplorer.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/PrometheusMetricsFinder.d.ts +31 -0
- package/lib/explore/PrometheusMetricsFinder/PrometheusMetricsFinder.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/PrometheusMetricsFinder.js +244 -0
- package/lib/explore/PrometheusMetricsFinder/PrometheusMetricsFinder.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/display/MetricChip.d.ts +4 -0
- package/lib/explore/PrometheusMetricsFinder/display/MetricChip.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/display/MetricChip.js +53 -0
- package/lib/explore/PrometheusMetricsFinder/display/MetricChip.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/display/list/MetricList.d.ts +27 -0
- package/lib/explore/PrometheusMetricsFinder/display/list/MetricList.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/display/list/MetricList.js +158 -0
- package/lib/explore/PrometheusMetricsFinder/display/list/MetricList.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/filter/FilterInputs.d.ts +23 -0
- package/lib/explore/PrometheusMetricsFinder/filter/FilterInputs.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/filter/FilterInputs.js +209 -0
- package/lib/explore/PrometheusMetricsFinder/filter/FilterInputs.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/filter/FinderFilters.d.ts +13 -0
- package/lib/explore/PrometheusMetricsFinder/filter/FinderFilters.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/filter/FinderFilters.js +84 -0
- package/lib/explore/PrometheusMetricsFinder/filter/FinderFilters.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/index.d.ts +2 -0
- package/lib/explore/PrometheusMetricsFinder/index.d.ts.map +1 -0
- package/{dist/model/api-types.js → lib/explore/PrometheusMetricsFinder/index.js} +2 -2
- package/lib/explore/PrometheusMetricsFinder/index.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/overview/MetricOverview.d.ts +23 -0
- package/lib/explore/PrometheusMetricsFinder/overview/MetricOverview.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/overview/MetricOverview.js +214 -0
- package/lib/explore/PrometheusMetricsFinder/overview/MetricOverview.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/JobTab.d.ts +28 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/JobTab.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/JobTab.js +125 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/JobTab.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/OverviewTab.d.ts +25 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/OverviewTab.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/OverviewTab.js +399 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/OverviewTab.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/SimilarTab.d.ts +12 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/SimilarTab.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/SimilarTab.js +45 -0
- package/lib/explore/PrometheusMetricsFinder/overview/tabs/SimilarTab.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/types.d.ts +22 -0
- package/lib/explore/PrometheusMetricsFinder/types.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/types.js +17 -0
- package/lib/explore/PrometheusMetricsFinder/types.js.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/utils.d.ts +22 -0
- package/lib/explore/PrometheusMetricsFinder/utils.d.ts.map +1 -0
- package/lib/explore/PrometheusMetricsFinder/utils.js +185 -0
- package/lib/explore/PrometheusMetricsFinder/utils.js.map +1 -0
- package/lib/explore/index.d.ts +3 -0
- package/lib/explore/index.d.ts.map +1 -0
- package/lib/explore/index.js +4 -0
- package/lib/explore/index.js.map +1 -0
- package/lib/getPluginModule.d.ts +6 -0
- package/lib/getPluginModule.d.ts.map +1 -0
- package/lib/getPluginModule.js +16 -0
- package/lib/getPluginModule.js.map +1 -0
- package/lib/index-federation.d.ts +1 -0
- package/lib/index-federation.d.ts.map +1 -0
- package/lib/index-federation.js +15 -0
- package/{dist/components/index.js.map → lib/index-federation.js.map} +1 -1
- package/lib/index.d.ts +6 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +7 -0
- package/lib/index.js.map +1 -0
- package/{dist → lib}/model/api-types.d.ts +18 -1
- package/lib/model/api-types.d.ts.map +1 -0
- package/{dist/plugins/prometheus-time-series-query/index.js → lib/model/api-types.js} +3 -3
- package/lib/model/api-types.js.map +1 -0
- package/lib/model/index.d.ts.map +1 -0
- package/lib/model/index.js.map +1 -0
- package/lib/model/parse-sample-values.d.ts.map +1 -0
- package/lib/model/parse-sample-values.js.map +1 -0
- package/lib/model/prometheus-client.d.ts.map +1 -0
- package/{dist → lib}/model/prometheus-client.js +1 -1
- package/lib/model/prometheus-client.js.map +1 -0
- package/lib/model/prometheus-selectors.d.ts.map +1 -0
- package/lib/model/prometheus-selectors.js.map +1 -0
- package/lib/model/time.d.ts.map +1 -0
- package/lib/model/time.js.map +1 -0
- package/lib/plugins/MatcherEditor.d.ts.map +1 -0
- package/lib/plugins/MatcherEditor.js.map +1 -0
- package/lib/plugins/PrometheusDatasourceEditor.d.ts.map +1 -0
- package/lib/plugins/PrometheusDatasourceEditor.js +96 -0
- package/lib/plugins/PrometheusDatasourceEditor.js.map +1 -0
- package/lib/plugins/PrometheusLabelNamesVariable.d.ts +4 -0
- package/lib/plugins/PrometheusLabelNamesVariable.d.ts.map +1 -0
- package/lib/plugins/PrometheusLabelNamesVariable.js +26 -0
- package/lib/plugins/PrometheusLabelNamesVariable.js.map +1 -0
- package/lib/plugins/PrometheusLabelValuesVariable.d.ts +4 -0
- package/lib/plugins/PrometheusLabelValuesVariable.d.ts.map +1 -0
- package/lib/plugins/PrometheusLabelValuesVariable.js +30 -0
- package/lib/plugins/PrometheusLabelValuesVariable.js.map +1 -0
- package/lib/plugins/PrometheusPromQLVariable.d.ts +4 -0
- package/lib/plugins/PrometheusPromQLVariable.d.ts.map +1 -0
- package/lib/plugins/PrometheusPromQLVariable.js +34 -0
- package/lib/plugins/PrometheusPromQLVariable.js.map +1 -0
- package/lib/plugins/index.d.ts +10 -0
- package/lib/plugins/index.d.ts.map +1 -0
- package/lib/plugins/index.js +11 -0
- package/lib/plugins/index.js.map +1 -0
- package/lib/plugins/prometheus-datasource.d.ts.map +1 -0
- package/{dist → lib}/plugins/prometheus-datasource.js +9 -9
- package/lib/plugins/prometheus-datasource.js.map +1 -0
- package/lib/plugins/prometheus-time-series-query/PrometheusTimeSeriesQuery.d.ts.map +1 -0
- package/lib/plugins/prometheus-time-series-query/PrometheusTimeSeriesQuery.js.map +1 -0
- package/lib/plugins/prometheus-time-series-query/PrometheusTimeSeriesQueryEditor.d.ts.map +1 -0
- package/{dist → lib}/plugins/prometheus-time-series-query/PrometheusTimeSeriesQueryEditor.js +9 -7
- package/lib/plugins/prometheus-time-series-query/PrometheusTimeSeriesQueryEditor.js.map +1 -0
- package/lib/plugins/prometheus-time-series-query/get-time-series-data.d.ts.map +1 -0
- package/{dist → lib}/plugins/prometheus-time-series-query/get-time-series-data.js +51 -29
- package/lib/plugins/prometheus-time-series-query/get-time-series-data.js.map +1 -0
- package/lib/plugins/prometheus-time-series-query/index.d.ts +7 -0
- package/lib/plugins/prometheus-time-series-query/index.d.ts.map +1 -0
- package/lib/plugins/prometheus-time-series-query/index.js +20 -0
- package/lib/plugins/prometheus-time-series-query/index.js.map +1 -0
- package/lib/plugins/prometheus-time-series-query/query-editor-model.d.ts.map +1 -0
- package/lib/plugins/prometheus-time-series-query/query-editor-model.js.map +1 -0
- package/lib/plugins/prometheus-time-series-query/replace-prom-builtin-variables.d.ts.map +1 -0
- package/lib/plugins/prometheus-time-series-query/replace-prom-builtin-variables.js.map +1 -0
- package/lib/plugins/prometheus-time-series-query/time-series-query-model.d.ts.map +1 -0
- package/lib/plugins/prometheus-time-series-query/time-series-query-model.js.map +1 -0
- package/lib/plugins/prometheus-variables.d.ts +14 -0
- package/lib/plugins/prometheus-variables.d.ts.map +1 -0
- package/{dist → lib}/plugins/prometheus-variables.js +15 -98
- package/lib/plugins/prometheus-variables.js.map +1 -0
- package/lib/plugins/types.d.ts.map +1 -0
- package/lib/plugins/types.js.map +1 -0
- package/lib/plugins/variable.d.ts.map +1 -0
- package/{dist → lib}/plugins/variable.js +1 -2
- package/lib/plugins/variable.js.map +1 -0
- package/lib/setup-tests.d.ts +2 -0
- package/lib/setup-tests.d.ts.map +1 -0
- package/lib/setup-tests.js +17 -0
- package/{dist/utils/index.js.map → lib/setup-tests.js.map} +1 -1
- package/lib/test/setup-tests.d.ts.map +1 -0
- package/lib/test/setup-tests.js.map +1 -0
- package/lib/utils/index.d.ts.map +1 -0
- package/lib/utils/index.js.map +1 -0
- package/lib/utils/utils.d.ts.map +1 -0
- package/{dist → lib}/utils/utils.js +1 -2
- package/lib/utils/utils.js.map +1 -0
- package/mf-manifest.json +898 -0
- package/mf-stats.json +1004 -0
- package/package.json +99 -38
- package/dist/cjs/components/TreeNode.js +0 -147
- package/dist/cjs/index.js +0 -61
- package/dist/cjs/plugins/PrometheusDatasourceEditor.js +0 -626
- package/dist/components/PromQLEditor.d.ts.map +0 -1
- package/dist/components/PromQLEditor.js.map +0 -1
- package/dist/components/TreeNode.d.ts +0 -10
- package/dist/components/TreeNode.d.ts.map +0 -1
- package/dist/components/TreeNode.js +0 -139
- package/dist/components/TreeNode.js.map +0 -1
- package/dist/components/index.d.ts.map +0 -1
- package/dist/components/parse.d.ts +0 -5
- package/dist/components/parse.d.ts.map +0 -1
- package/dist/components/parse.js.map +0 -1
- package/dist/components/promql/ast.d.ts.map +0 -1
- package/dist/components/promql/ast.js.map +0 -1
- package/dist/components/promql/format.d.ts.map +0 -1
- package/dist/components/promql/format.js.map +0 -1
- package/dist/components/promql/utils.d.ts.map +0 -1
- package/dist/components/promql/utils.js.map +0 -1
- package/dist/index.d.ts +0 -8
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -24
- package/dist/index.js.map +0 -1
- package/dist/model/api-types.d.ts.map +0 -1
- package/dist/model/api-types.js.map +0 -1
- package/dist/model/index.d.ts.map +0 -1
- package/dist/model/index.js.map +0 -1
- package/dist/model/parse-sample-values.d.ts.map +0 -1
- package/dist/model/parse-sample-values.js.map +0 -1
- package/dist/model/prometheus-client.d.ts.map +0 -1
- package/dist/model/prometheus-client.js.map +0 -1
- package/dist/model/prometheus-selectors.d.ts.map +0 -1
- package/dist/model/prometheus-selectors.js.map +0 -1
- package/dist/model/time.d.ts.map +0 -1
- package/dist/model/time.js.map +0 -1
- package/dist/plugins/MatcherEditor.d.ts.map +0 -1
- package/dist/plugins/MatcherEditor.js.map +0 -1
- package/dist/plugins/PrometheusDatasourceEditor.d.ts.map +0 -1
- package/dist/plugins/PrometheusDatasourceEditor.js +0 -572
- package/dist/plugins/PrometheusDatasourceEditor.js.map +0 -1
- package/dist/plugins/prometheus-datasource.d.ts.map +0 -1
- package/dist/plugins/prometheus-datasource.js.map +0 -1
- package/dist/plugins/prometheus-time-series-query/PrometheusTimeSeriesQuery.d.ts.map +0 -1
- package/dist/plugins/prometheus-time-series-query/PrometheusTimeSeriesQuery.js.map +0 -1
- package/dist/plugins/prometheus-time-series-query/PrometheusTimeSeriesQueryEditor.d.ts.map +0 -1
- package/dist/plugins/prometheus-time-series-query/PrometheusTimeSeriesQueryEditor.js.map +0 -1
- package/dist/plugins/prometheus-time-series-query/get-time-series-data.d.ts.map +0 -1
- package/dist/plugins/prometheus-time-series-query/get-time-series-data.js.map +0 -1
- package/dist/plugins/prometheus-time-series-query/index.d.ts +0 -2
- package/dist/plugins/prometheus-time-series-query/index.d.ts.map +0 -1
- package/dist/plugins/prometheus-time-series-query/index.js.map +0 -1
- package/dist/plugins/prometheus-time-series-query/query-editor-model.d.ts.map +0 -1
- package/dist/plugins/prometheus-time-series-query/query-editor-model.js.map +0 -1
- package/dist/plugins/prometheus-time-series-query/replace-prom-builtin-variables.d.ts.map +0 -1
- package/dist/plugins/prometheus-time-series-query/replace-prom-builtin-variables.js.map +0 -1
- package/dist/plugins/prometheus-time-series-query/time-series-query-model.d.ts.map +0 -1
- package/dist/plugins/prometheus-time-series-query/time-series-query-model.js.map +0 -1
- package/dist/plugins/prometheus-variables.d.ts +0 -6
- package/dist/plugins/prometheus-variables.d.ts.map +0 -1
- package/dist/plugins/prometheus-variables.js.map +0 -1
- package/dist/plugins/types.d.ts.map +0 -1
- package/dist/plugins/types.js.map +0 -1
- package/dist/plugins/variable.d.ts.map +0 -1
- package/dist/plugins/variable.js.map +0 -1
- package/dist/test/setup-tests.d.ts.map +0 -1
- package/dist/test/setup-tests.js.map +0 -1
- package/dist/utils/index.d.ts.map +0 -1
- package/dist/utils/utils.d.ts.map +0 -1
- package/dist/utils/utils.js.map +0 -1
- package/plugin.json +0 -58
- /package/{dist → lib}/cjs/components/index.js +0 -0
- /package/{dist → lib}/cjs/components/promql/format.js +0 -0
- /package/{dist → lib}/cjs/model/index.js +0 -0
- /package/{dist → lib}/cjs/model/parse-sample-values.js +0 -0
- /package/{dist → lib}/cjs/model/prometheus-selectors.js +0 -0
- /package/{dist → lib}/cjs/model/time.js +0 -0
- /package/{dist → lib}/cjs/plugins/MatcherEditor.js +0 -0
- /package/{dist → lib}/cjs/plugins/prometheus-time-series-query/PrometheusTimeSeriesQuery.js +0 -0
- /package/{dist → lib}/cjs/plugins/prometheus-time-series-query/query-editor-model.js +0 -0
- /package/{dist → lib}/cjs/plugins/prometheus-time-series-query/replace-prom-builtin-variables.js +0 -0
- /package/{dist → lib}/cjs/plugins/prometheus-time-series-query/time-series-query-model.js +0 -0
- /package/{dist → lib}/cjs/plugins/types.js +0 -0
- /package/{dist → lib}/cjs/test/setup-tests.js +0 -0
- /package/{dist → lib}/cjs/utils/index.js +0 -0
- /package/{dist → lib}/components/PromQLEditor.d.ts +0 -0
- /package/{dist → lib}/components/index.d.ts +0 -0
- /package/{dist → lib}/components/index.js +0 -0
- /package/{dist → lib}/components/promql/ast.d.ts +0 -0
- /package/{dist → lib}/components/promql/format.js +0 -0
- /package/{dist → lib}/model/index.d.ts +0 -0
- /package/{dist → lib}/model/index.js +0 -0
- /package/{dist → lib}/model/parse-sample-values.d.ts +0 -0
- /package/{dist → lib}/model/parse-sample-values.js +0 -0
- /package/{dist → lib}/model/prometheus-client.d.ts +0 -0
- /package/{dist → lib}/model/prometheus-selectors.d.ts +0 -0
- /package/{dist → lib}/model/prometheus-selectors.js +0 -0
- /package/{dist → lib}/model/time.d.ts +0 -0
- /package/{dist → lib}/model/time.js +0 -0
- /package/{dist → lib}/plugins/MatcherEditor.d.ts +0 -0
- /package/{dist → lib}/plugins/MatcherEditor.js +0 -0
- /package/{dist → lib}/plugins/PrometheusDatasourceEditor.d.ts +0 -0
- /package/{dist → lib}/plugins/prometheus-datasource.d.ts +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/PrometheusTimeSeriesQuery.d.ts +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/PrometheusTimeSeriesQuery.js +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/PrometheusTimeSeriesQueryEditor.d.ts +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/get-time-series-data.d.ts +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/query-editor-model.d.ts +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/query-editor-model.js +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/replace-prom-builtin-variables.d.ts +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/replace-prom-builtin-variables.js +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/time-series-query-model.d.ts +0 -0
- /package/{dist → lib}/plugins/prometheus-time-series-query/time-series-query-model.js +0 -0
- /package/{dist → lib}/plugins/types.d.ts +0 -0
- /package/{dist → lib}/plugins/types.js +0 -0
- /package/{dist → lib}/plugins/variable.d.ts +0 -0
- /package/{dist → lib}/test/setup-tests.d.ts +0 -0
- /package/{dist → lib}/test/setup-tests.js +0 -0
- /package/{dist → lib}/utils/index.d.ts +0 -0
- /package/{dist → lib}/utils/index.js +0 -0
- /package/{dist → lib}/utils/utils.d.ts +0 -0
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/*! For license information please see 4489.3361e7bc.js.LICENSE.txt */
|
|
2
|
+
(self.webpackChunkPrometheus=self.webpackChunkPrometheus||[]).push([["4489"],{12577:function(e,t,n){"use strict";n.d(t,{Z:()=>g});var r=n(54538),o=n(90496),i=n(82267),a=n(67488),s=n(52054),l=n(78849),u=n(12709),c=n(51751),d=n(14662),p=n(16351),f=n(24246);let h=e=>{let{classes:t,inset:n,primary:r,secondary:o,dense:a}=e;return(0,i.Z)({root:["root",n&&"inset",a&&"dense",r&&o&&"multiline"],primary:["primary"],secondary:["secondary"]},d.L,t)},m=(0,u.ZP)("div",{name:"MuiListItemText",slot:"Root",overridesResolver:(e,t)=>{let{ownerState:n}=e;return[{[`& .${d.Z.primary}`]:t.primary},{[`& .${d.Z.secondary}`]:t.secondary},t.root,n.inset&&t.inset,n.primary&&n.secondary&&t.multiline,n.dense&&t.dense]}})({flex:"1 1 auto",minWidth:0,marginTop:4,marginBottom:4,[`.${a.Z.root}:where(& .${d.Z.primary})`]:{display:"block"},[`.${a.Z.root}:where(& .${d.Z.secondary})`]:{display:"block"},variants:[{props:({ownerState:e})=>e.primary&&e.secondary,style:{marginTop:6,marginBottom:6}},{props:({ownerState:e})=>e.inset,style:{paddingLeft:56}}]}),g=r.forwardRef(function(e,t){let n=(0,c.i)({props:e,name:"MuiListItemText"}),{children:i,className:a,disableTypography:u=!1,inset:d=!1,primary:g,primaryTypographyProps:v,secondary:y,secondaryTypographyProps:b,slots:x={},slotProps:w={},...C}=n,{dense:S}=r.useContext(l.Z),M=null!=g?g:i,k=y,E={...n,disableTypography:u,inset:d,primary:!!M,secondary:!!k,dense:S},D=h(E),T={slots:x,slotProps:{primary:v,secondary:b,...w}},[P,Z]=(0,p.Z)("root",{className:(0,o.Z)(D.root,a),elementType:m,externalForwardedProps:{...T,...C},ownerState:E,ref:t}),[O,j]=(0,p.Z)("primary",{className:D.primary,elementType:s.Z,externalForwardedProps:T,ownerState:E}),[R,N]=(0,p.Z)("secondary",{className:D.secondary,elementType:s.Z,externalForwardedProps:T,ownerState:E});return null==M||M.type===s.Z||u||(M=(0,f.jsx)(O,{variant:S?"body2":"body1",component:j?.variant?void 0:"span",...j,children:M})),null==k||k.type===s.Z||u||(k=(0,f.jsx)(R,{variant:"body2",color:"textSecondary",...N,children:k})),(0,f.jsxs)(P,{...Z,children:[M,k]})})},86332:function(e,t,n){"use strict";let r;n.r(t),n.d(t,{ErrorAlert:()=>ie,JSONEditor:()=>ix,INCREASE_NEARBY_SERIES_MULTIPLIER:()=>af,OptionsEditorGroup:()=>aI,DensitySelector:()=>rq,assembleTransform:()=>aC,clearHighlightedSeries:()=>as,getColorsForValues:()=>bA,ErrorBoundary:()=>it.ErrorBoundary,SeriesMarker:()=>i3,TimeRangeSelector:()=>vR,testChartsTheme:()=>y1,ChartsThemeContext:()=>eB,TextOverlay:()=>aL,hexToHSL:()=>bF,DEFAULT_COLUMN_HEIGHT:()=>re,useMousePosition:()=>iQ,NoDataOverlay:()=>aV,generateChartsTheme:()=>yQ,OptionsEditorGrid:()=>aF,OPTIMIZED_MODE_SERIES_LIMIT:()=>an,TOOLTIP_ADJUST_Y_POS_MULTIPLIER:()=>iV,DiscardChangesConfirmationDialog:()=>rR,getDateRange:()=>e4,EMPHASIZED_SERIES_DESCRIPTION:()=>iH,useChartsTheme:()=>eH,persesColumnsToTanstackColumns:()=>rn,mockChartsContext:()=>y2,Legend:()=>rw,TOOLTIP_DATE_FORMAT:()=>iG,TOOLTIP_MAX_WIDTH:()=>iI,dateFormatOptionsWithTimeZone:()=>iT,legacyCheckforNearbySeries:()=>av,ToolbarIconButton:()=>vA,PIN_TOOLTIP_HELP_TEXT:()=>i0,checkforNearbyTimeSeries:()=>ag,getTheme:()=>bp,PieChart:()=>bT,TooltipHeader:()=>at,TOOLTIP_BG_COLOR_FALLBACK:()=>iW,UNPIN_TOOLTIP_HELP_TEXT:()=>i1,DateTimeRangePicker:()=>vj,handleMoveUp:()=>oL,browser:()=>iY,getClosestTimestamp:()=>ad,formatWithTimeZone:()=>iP,batchDispatchNearbySeriesActions:()=>au,getFormattedAxis:()=>e3,useTimeZone:()=>iA,ChartsProvider:()=>e$,isWithinPercentageRange:()=>ax,TOOLTIP_MIN_WIDTH:()=>iF,StatusHistoryChart:()=>bj,TOOLTIP_LABELS_MAX_WIDTH:()=>iL,getYBuffer:()=>aw,DEFAULT_PINNED_CROSSHAIR:()=>ao,LineChartTooltip:()=>aM,FormatControls:()=>v_,TooltipContent:()=>i8,hslToHex:()=>bI,SHOW_FEWER_SERIES_LIMIT:()=>am,TimeChartTooltip:()=>cO,getClosestTimestampInFullDataset:()=>ap,getTableCellLayout:()=>rt,pointerEventsSupported:()=>iX,EChart:()=>e1,PINNED_CROSSHAIR_SERIES_NAME:()=>ar,SortSelector:()=>az,SnackbarProvider:()=>yY,Drawer:()=>o9,AlignSelector:()=>j,LinksEditor:()=>aZ,ValueMappingsEditor:()=>xt,TimeZoneContext:()=>iR,GaugeChart:()=>il,LineChart:()=>ak,SeriesLabelsStack:()=>i4,checkCrosshairPinnedStatus:()=>ac,StatChart:()=>aU,SeriesInfo:()=>i6,ColorPicker:()=>tV,Table:()=>rg,useSnackbar:()=>yX,InfoTooltip:()=>rV,TimeZoneProvider:()=>iN,LoadingOverlay:()=>a$,typography:()=>bc,Dialog:()=>rj,DropIndicator:()=>rY,TransformsEditor:()=>bk,OptionsEditorControl:()=>rz,TOOLTIP_PADDING:()=>i$,getFormattedAxisLabel:()=>iO,SortSelectorButtons:()=>aH,getTooltipStyles:()=>aS,useChartsContext:()=>ez,RefreshIntervalPicker:()=>bE,enableDataZoom:()=>ai,useDragAndDropMonitor:()=>oN,trackingEventName:()=>iK,combineSx:()=>t4,OptionsEditorColumn:()=>aA,getDateAndTime:()=>ij,ThresholdsEditor:()=>sn,DEFAULT_TOOLTIP_CONFIG:()=>iJ,handleMoveDown:()=>oV,DragButton:()=>o$,useId:()=>rI,ContentWithLegend:()=>rS,BarChart:()=>e6,getFormattedDate:()=>iZ,NEARBY_SERIES_DESCRIPTION:()=>iz,getColorForValue:()=>bN,isLegendItemVisuallySelected:()=>t7,getPointInGrid:()=>al,EMPTY_TOOLTIP_DATA:()=>iq,legacyGetNearbySeriesData:()=>ab,buildRelativeTimeOption:()=>yJ,SettingsAutocomplete:()=>rG,FontSizeSelector:()=>io,defaultCursorData:()=>iU,DYNAMIC_NEARBY_SERIES_MULTIPLIER:()=>ah,FALLBACK_COLOR:()=>bR,getNearbySeriesData:()=>ay,TOOLTIP_MAX_HEIGHT:()=>i_,YAxisLabel:()=>vL,TimeChart:()=>cj,FALLBACK_CHART_WIDTH:()=>iB,DragAndDropElement:()=>oA,getResponsiveValueSize:()=>iu,restoreChart:()=>aa,ModeSelector:()=>aR,TextField:()=>rM,DEFAULT_COLUMN_WIDTH:()=>n7,FormActions:()=>ia,OptionsColorPicker:()=>tz});var o,i,a,s,l,u,c=n(24246),d=n(54538),p=n.n(d),f=n(90496),h=n(82267),m=n(16838);function g(e){return d.Children.toArray(e).filter(e=>d.isValidElement(e))}var v=n(51640),y=n(12709),b=n(82319),x=n(90433),w=n(51751),C=n(44124),S=n(6749);function M(e){return(0,S.ZP)("MuiButtonGroup",e)}let k=(0,C.Z)("MuiButtonGroup",["root","contained","outlined","text","disableElevation","disabled","firstButton","fullWidth","horizontal","vertical","colorPrimary","colorSecondary","grouped","groupedHorizontal","groupedVertical","groupedText","groupedTextHorizontal","groupedTextVertical","groupedTextPrimary","groupedTextSecondary","groupedOutlined","groupedOutlinedHorizontal","groupedOutlinedVertical","groupedOutlinedPrimary","groupedOutlinedSecondary","groupedContained","groupedContainedHorizontal","groupedContainedVertical","groupedContainedPrimary","groupedContainedSecondary","lastButton","middleButton"]);var E=n(55720),D=n(71645);let T=e=>{let{classes:t,color:n,disabled:r,disableElevation:o,fullWidth:i,orientation:a,variant:s}=e,l={root:["root",s,a,i&&"fullWidth",o&&"disableElevation",`color${(0,v.Z)(n)}`],grouped:["grouped",`grouped${(0,v.Z)(a)}`,`grouped${(0,v.Z)(s)}`,`grouped${(0,v.Z)(s)}${(0,v.Z)(a)}`,`grouped${(0,v.Z)(s)}${(0,v.Z)(n)}`,r&&"disabled"],firstButton:["firstButton"],lastButton:["lastButton"],middleButton:["middleButton"]};return(0,h.Z)(l,M,t)},P=(0,y.ZP)("div",{name:"MuiButtonGroup",slot:"Root",overridesResolver:(e,t)=>{let{ownerState:n}=e;return[{[`& .${k.grouped}`]:t.grouped},{[`& .${k.grouped}`]:t[`grouped${(0,v.Z)(n.orientation)}`]},{[`& .${k.grouped}`]:t[`grouped${(0,v.Z)(n.variant)}`]},{[`& .${k.grouped}`]:t[`grouped${(0,v.Z)(n.variant)}${(0,v.Z)(n.orientation)}`]},{[`& .${k.grouped}`]:t[`grouped${(0,v.Z)(n.variant)}${(0,v.Z)(n.color)}`]},{[`& .${k.firstButton}`]:t.firstButton},{[`& .${k.lastButton}`]:t.lastButton},{[`& .${k.middleButton}`]:t.middleButton},t.root,t[n.variant],!0===n.disableElevation&&t.disableElevation,n.fullWidth&&t.fullWidth,"vertical"===n.orientation&&t.vertical]}})((0,b.Z)(({theme:e})=>({display:"inline-flex",borderRadius:(e.vars||e).shape.borderRadius,variants:[{props:{variant:"contained"},style:{boxShadow:(e.vars||e).shadows[2]}},{props:{disableElevation:!0},style:{boxShadow:"none"}},{props:{fullWidth:!0},style:{width:"100%"}},{props:{orientation:"vertical"},style:{flexDirection:"column",[`& .${k.lastButton},& .${k.middleButton}`]:{borderTopRightRadius:0,borderTopLeftRadius:0},[`& .${k.firstButton},& .${k.middleButton}`]:{borderBottomRightRadius:0,borderBottomLeftRadius:0}}},{props:{orientation:"horizontal"},style:{[`& .${k.firstButton},& .${k.middleButton}`]:{borderTopRightRadius:0,borderBottomRightRadius:0},[`& .${k.lastButton},& .${k.middleButton}`]:{borderTopLeftRadius:0,borderBottomLeftRadius:0}}},{props:{variant:"text",orientation:"horizontal"},style:{[`& .${k.firstButton},& .${k.middleButton}`]:{borderRight:e.vars?`1px solid rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:`1px solid ${"light"===e.palette.mode?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)"}`,[`&.${k.disabled}`]:{borderRight:`1px solid ${(e.vars||e).palette.action.disabled}`}}}},{props:{variant:"text",orientation:"vertical"},style:{[`& .${k.firstButton},& .${k.middleButton}`]:{borderBottom:e.vars?`1px solid rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:`1px solid ${"light"===e.palette.mode?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)"}`,[`&.${k.disabled}`]:{borderBottom:`1px solid ${(e.vars||e).palette.action.disabled}`}}}},...Object.entries(e.palette).filter((0,x.Z)()).flatMap(([t])=>[{props:{variant:"text",color:t},style:{[`& .${k.firstButton},& .${k.middleButton}`]:{borderColor:e.vars?`rgba(${e.vars.palette[t].mainChannel} / 0.5)`:(0,m.Fq)(e.palette[t].main,.5)}}}]),{props:{variant:"outlined",orientation:"horizontal"},style:{[`& .${k.firstButton},& .${k.middleButton}`]:{borderRightColor:"transparent","&:hover":{borderRightColor:"currentColor"}},[`& .${k.lastButton},& .${k.middleButton}`]:{marginLeft:-1}}},{props:{variant:"outlined",orientation:"vertical"},style:{[`& .${k.firstButton},& .${k.middleButton}`]:{borderBottomColor:"transparent","&:hover":{borderBottomColor:"currentColor"}},[`& .${k.lastButton},& .${k.middleButton}`]:{marginTop:-1}}},{props:{variant:"contained",orientation:"horizontal"},style:{[`& .${k.firstButton},& .${k.middleButton}`]:{borderRight:`1px solid ${(e.vars||e).palette.grey[400]}`,[`&.${k.disabled}`]:{borderRight:`1px solid ${(e.vars||e).palette.action.disabled}`}}}},{props:{variant:"contained",orientation:"vertical"},style:{[`& .${k.firstButton},& .${k.middleButton}`]:{borderBottom:`1px solid ${(e.vars||e).palette.grey[400]}`,[`&.${k.disabled}`]:{borderBottom:`1px solid ${(e.vars||e).palette.action.disabled}`}}}},...Object.entries(e.palette).filter((0,x.Z)(["dark"])).map(([t])=>({props:{variant:"contained",color:t},style:{[`& .${k.firstButton},& .${k.middleButton}`]:{borderColor:(e.vars||e).palette[t].dark}}}))],[`& .${k.grouped}`]:{minWidth:40,boxShadow:"none",props:{variant:"contained"},style:{"&:hover":{boxShadow:"none"}}}}))),Z=d.forwardRef(function(e,t){let n=(0,w.i)({props:e,name:"MuiButtonGroup"}),{children:r,className:o,color:i="primary",component:a="div",disabled:s=!1,disableElevation:l=!1,disableFocusRipple:u=!1,disableRipple:p=!1,fullWidth:h=!1,orientation:m="horizontal",size:v="medium",variant:y="outlined",...b}=n,x={...n,color:i,component:a,disabled:s,disableElevation:l,disableFocusRipple:u,disableRipple:p,fullWidth:h,orientation:m,size:v,variant:y},C=T(x),S=d.useMemo(()=>({className:C.grouped,color:i,disabled:s,disableElevation:l,disableFocusRipple:u,disableRipple:p,fullWidth:h,size:v,variant:y}),[i,s,l,u,p,h,v,y,C.grouped]),M=g(r),k=M.length,Z=e=>{let t=0===e,n=e===k-1;return t&&n?"":t?C.firstButton:n?C.lastButton:C.middleButton};return(0,c.jsx)(P,{as:a,role:"group",className:(0,f.Z)(C.root,o),ref:t,ownerState:x,...b,children:(0,c.jsx)(E.Z.Provider,{value:S,children:M.map((e,t)=>(0,c.jsx)(D.Z.Provider,{value:Z(t),children:e},t))})})});var O=n(48565);function j({onChange:e,value:t="left",...n}){let r=t=>{e(t)};return(0,c.jsxs)(Z,{"aria-label":"Alignement",...n,children:[(0,c.jsx)(O.Z,{onClick:()=>r("left"),variant:"left"===t?"contained":"outlined",children:"Left"},"left"),(0,c.jsx)(O.Z,{onClick:()=>r("center"),variant:"center"===t?"contained":"outlined",children:"Center"},"center"),(0,c.jsx)(O.Z,{onClick:()=>r("right"),variant:"right"===t?"contained":"outlined",children:"Right"},"right")]})}var R="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:"undefined"!=typeof self?self:{};function N(){if(ts)return ta;ts=1;let e=[{key:"ZiB",factor:11805916207174113e5},{key:"ZB",factor:1e21},{key:"YiB",factor:12089258196146292e8},{key:"YB",factor:1e24},{key:"TiB",factor:0x10000000000},{key:"TB",factor:1e12},{key:"PiB",factor:0x4000000000000},{key:"PB",factor:1e15},{key:"MiB",factor:1048576},{key:"MB",factor:1e6},{key:"KiB",factor:1024},{key:"KB",factor:1e3},{key:"GiB",factor:0x40000000},{key:"GB",factor:1e9},{key:"EiB",factor:0x1000000000000000},{key:"EB",factor:1e18},{key:"B",factor:1}];function t(e){return e.replace(/[-/\\^$*+?.()|[\]{}]/g,"\\$&")}return ta={unformat:function(n,r){let o;let i=I(),a=i.currentDelimiters(),s=i.currentCurrency().symbol,l=i.currentOrdinal(),u=i.getZeroFormat(),c=i.currentAbbreviations();if("string"==typeof n){if(function(e,t){if(!(e.indexOf(":")&&":"!==t.thousands))return!1;let n=e.split(":");if(3!==n.length)return!1;let r=+n[0],o=+n[1],i=+n[2];return!isNaN(r)&&!isNaN(o)&&!isNaN(i)}(n,a)){let e,t,r;t=+(e=n.split(":"))[0],r=+e[1],o=+e[2]+60*r+3600*t}else o=function(n,r,o="",i,a,s,l){let u;if(""!==n)return n===a?0:function n(r,o,i,a,s,l,u){if(!isNaN(+r))return+r;let c="",d=r.replace(/(^[^(]*)\((.*)\)([^)]*$)/,"$1$2$3");if(d!==r)return -1*n(d,o,i,a,s,l);for(let t=0;t<e.length;t++){let u=e[t];if((c=r.replace(RegExp(`([0-9 ])(${u.key})$`),"$1"))!==r)return n(c,o,i,a,s,l)*u.factor}if((c=r.replace("%",""))!==r)return n(c,o,i,a,s,l)/100;let p=parseFloat(r);if(isNaN(p))return;let f=a(p);if(f&&"."!==f&&(c=r.replace(RegExp(`${t(f)}$`),""))!==r)return n(c,o,i,a,s,l);let h={};Object.keys(l).forEach(e=>{h[l[e]]=e});let m=Object.keys(h).sort().reverse(),g=m.length;for(let e=0;e<g;e++){let t=m[e],u=h[t];if((c=r.replace(t,""))!==r){let e;switch(u){case"thousand":e=1e3;break;case"million":e=1e6;break;case"billion":e=1e9;break;case"trillion":e=1e12}return n(c,o,i,a,s,l)*e}}}(n.replace(o,"").replace(RegExp(`([0-9])${t(r.thousands)}([0-9])`,"g"),"$1$2").replace(r.decimal,"."),r,o,i,a,s)}(n,a,s,l,u,c)}else{if("number"!=typeof n)return;o=n}if(void 0!==o)return o}}}function A(){if(tu)return tl;tu=1;let e=N(),t=/^[a-z]{2,3}(-[a-zA-Z]{4})?(-([A-Z]{2}|[0-9]{3}))?$/,n={output:{type:"string",validValues:["currency","percent","byte","time","ordinal","number"]},base:{type:"string",validValues:["decimal","binary","general"],restriction:(e,t)=>"byte"===t.output,message:"`base` must be provided only when the output is `byte`",mandatory:e=>"byte"===e.output},characteristic:{type:"number",restriction:e=>e>=0,message:"value must be positive"},prefix:"string",postfix:"string",forceAverage:{type:"string",validValues:["trillion","billion","million","thousand"]},average:"boolean",lowPrecision:{type:"boolean",restriction:(e,t)=>!0===t.average,message:"`lowPrecision` must be provided only when the option `average` is set"},currencyPosition:{type:"string",validValues:["prefix","infix","postfix"]},currencySymbol:"string",totalLength:{type:"number",restrictions:[{restriction:e=>e>=0,message:"value must be positive"},{restriction:(e,t)=>!t.exponential,message:"`totalLength` is incompatible with `exponential`"}]},mantissa:{type:"number",restriction:e=>e>=0,message:"value must be positive"},optionalMantissa:"boolean",trimMantissa:"boolean",roundingFunction:"function",optionalCharacteristic:"boolean",thousandSeparated:"boolean",spaceSeparated:"boolean",spaceSeparatedCurrency:"boolean",spaceSeparatedAbbreviation:"boolean",abbreviations:{type:"object",children:{thousand:"string",million:"string",billion:"string",trillion:"string"}},negative:{type:"string",validValues:["sign","parenthesis"]},forceSign:"boolean",exponential:{type:"boolean"},prefixSymbol:{type:"boolean",restriction:(e,t)=>"percent"===t.output,message:"`prefixSymbol` can be provided only when the output is `percent`"}},r={languageTag:{type:"string",mandatory:!0,restriction:e=>e.match(t),message:"the language tag must follow the BCP 47 specification (see https://tools.ieft.org/html/bcp47)"},delimiters:{type:"object",children:{thousands:"string",decimal:"string",thousandsSize:"number"},mandatory:!0},abbreviations:{type:"object",children:{thousand:{type:"string",mandatory:!0},million:{type:"string",mandatory:!0},billion:{type:"string",mandatory:!0},trillion:{type:"string",mandatory:!0}},mandatory:!0},spaceSeparated:"boolean",spaceSeparatedCurrency:"boolean",ordinal:{type:"function",mandatory:!0},bytes:{type:"object",children:{binarySuffixes:"object",decimalSuffixes:"object"}},currency:{type:"object",children:{symbol:"string",position:"string",code:"string"},mandatory:!0},defaults:"format",ordinalFormat:"format",byteFormat:"format",percentageFormat:"format",currencyFormat:"format",timeDefaults:"format",formats:{type:"object",children:{fourDigits:{type:"format",mandatory:!0},fullWithTwoDecimals:{type:"format",mandatory:!0},fullWithTwoDecimalsNoCurrency:{type:"format",mandatory:!0},fullWithNoDecimals:{type:"format",mandatory:!0}}}};function o(t){return void 0!==e.unformat(t)}function i(e,t,r,o=!1){let a=Object.keys(e).map(o=>{if(!t[o])return console.error(`${r} Invalid key: ${o}`),!1;let a=e[o],s=t[o];if("string"==typeof s&&(s={type:s}),"format"===s.type){if(!i(a,n,`[Validate ${o}]`,!0))return!1}else if(typeof a!==s.type)return console.error(`${r} ${o} type mismatched: "${s.type}" expected, "${typeof a}" provided`),!1;if(s.restrictions&&s.restrictions.length){let t=s.restrictions.length;for(let n=0;n<t;n++){let{restriction:t,message:i}=s.restrictions[n];if(!t(a,e))return console.error(`${r} ${o} invalid value: ${i}`),!1}}return s.restriction&&!s.restriction(a,e)?(console.error(`${r} ${o} invalid value: ${s.message}`),!1):s.validValues&&-1===s.validValues.indexOf(a)?(console.error(`${r} ${o} invalid value: must be among ${JSON.stringify(s.validValues)}, "${a}" provided`),!1):!s.children||!!i(a,s.children,`[Validate ${o}]`)});return o||a.push(...Object.keys(t).map(n=>{let o=t[n];if("string"==typeof o&&(o={type:o}),o.mandatory){let t=o.mandatory;if("function"==typeof t&&(t=t(e)),t&&void 0===e[n])return console.error(`${r} Missing mandatory key "${n}"`),!1}return!0})),a.reduce((e,t)=>e&&t,!0)}function a(e){return i(e,n,"[Validate format]")}return tl={validate:function(e,t){let n=o(e),r=a(t);return n&&r},validateFormat:a,validateInput:o,validateLanguage:function(e){return i(e,r,"[Validate language]")}}}var F={parseFormat:function(e,t={}){var n,r,o,i,a;let s,l,u,c;return"string"!=typeof e?e:(!function(e,t){if(-1!==e.indexOf("$")){t.output="currency";return}if(-1!==e.indexOf("%")){t.output="percent";return}if(-1!==e.indexOf("bd")){t.output="byte",t.base="general";return}if(-1!==e.indexOf("b")){t.output="byte",t.base="binary";return}if(-1!==e.indexOf("d")){t.output="byte",t.base="decimal";return}if(-1!==e.indexOf(":")){t.output="time";return}-1!==e.indexOf("o")&&(t.output="ordinal")}(e=(l=(r=e=(s=(n=e).match(/^{([^}]*)}/))?(t.prefix=s[1],n.slice(s[0].length)):n).match(/{([^}]*)}$/))?(t.postfix=l[1],r.slice(0,-l[0].length)):r,t),(u=e.match(/[1-9]+[0-9]*/))&&(t.totalLength=+u[0]),(c=e.split(".")[0].match(/0+/))&&(t.characteristic=c[0].length),!function(e,t){if(-1!==e.indexOf(".")){let n=e.split(".")[0];t.optionalCharacteristic=-1===n.indexOf("0")}}(e,t),-1!==e.indexOf("a")&&(t.average=!0),-1!==(o=e).indexOf("K")?t.forceAverage="thousand":-1!==o.indexOf("M")?t.forceAverage="million":-1!==o.indexOf("B")?t.forceAverage="billion":-1!==o.indexOf("T")&&(t.forceAverage="trillion"),!function(e,t){let n=e.split(".")[1];if(n){let e=n.match(/0+/);e&&(t.mantissa=e[0].length)}}(e,t),(i=e).match(/\[\.]/)?t.optionalMantissa=!0:i.match(/\./)&&(t.optionalMantissa=!1),!function(e,t){let n=e.split(".")[1];n&&(t.trimMantissa=-1!==n.indexOf("["))}(e,t),-1!==e.indexOf(",")&&(t.thousandSeparated=!0),-1!==e.indexOf(" ")&&(t.spaceSeparated=!0,t.spaceSeparatedCurrency=!0,(t.average||t.forceAverage)&&(t.spaceSeparatedAbbreviation=!0)),(a=e).match(/^\+?\([^)]*\)$/)&&(t.negative="parenthesis"),a.match(/^\+?-/)&&(t.negative="sign"),e.match(/^\+/)&&(t.forceSign=!0),t)}};function I(){let e;if(td)return tc;td=1;let t=ti?to:(ti=1,to={languageTag:"en-US",delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},spaceSeparated:!1,ordinal:function(e){let t=e%10;return 1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th"},bytes:{binarySuffixes:["B","KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"],decimalSuffixes:["B","KB","MB","GB","TB","PB","EB","ZB","YB"]},currency:{symbol:"$",position:"prefix",code:"USD"},currencyFormat:{thousandSeparated:!0,totalLength:4,spaceSeparated:!0,spaceSeparatedCurrency:!0},formats:{fourDigits:{totalLength:4,spaceSeparated:!0},fullWithTwoDecimals:{output:"currency",thousandSeparated:!0,mantissa:2},fullWithTwoDecimalsNoCurrency:{thousandSeparated:!0,mantissa:2},fullWithNoDecimals:{output:"currency",thousandSeparated:!0,mantissa:0}}}),n=A(),r={},o={},i=null,a={};function s(){return o[e]}return r.languages=()=>Object.assign({},o),r.currentLanguage=()=>e,r.currentBytes=()=>s().bytes||{},r.currentCurrency=()=>s().currency,r.currentAbbreviations=()=>s().abbreviations,r.currentDelimiters=()=>s().delimiters,r.currentOrdinal=()=>s().ordinal,r.currentDefaults=()=>Object.assign({},s().defaults,a),r.currentOrdinalDefaultFormat=()=>Object.assign({},r.currentDefaults(),s().ordinalFormat),r.currentByteDefaultFormat=()=>Object.assign({},r.currentDefaults(),s().byteFormat),r.currentPercentageDefaultFormat=()=>Object.assign({},r.currentDefaults(),s().percentageFormat),r.currentCurrencyDefaultFormat=()=>Object.assign({},r.currentDefaults(),s().currencyFormat),r.currentTimeDefaultFormat=()=>Object.assign({},r.currentDefaults(),s().timeFormat),r.setDefaults=e=>{e=F.parseFormat(e),n.validateFormat(e)&&(a=e)},r.getZeroFormat=()=>i,r.setZeroFormat=e=>i="string"==typeof e?e:null,r.hasZeroFormat=()=>null!==i,r.languageData=e=>{if(e){if(o[e])return o[e];throw Error(`Unknown tag "${e}"`)}return s()},r.registerLanguage=(t,r=!1)=>{if(!n.validateLanguage(t))throw Error("Invalid language data");o[t.languageTag]=t,r&&(e=t.languageTag)},r.setLanguage=(n,r=t.languageTag)=>{if(!o[n]){let t=n.split("-")[0],i=Object.keys(o).find(e=>e.split("-")[0]===t);if(!o[i]){e=r;return}e=i;return}e=n},r.registerLanguage(t),e=t.languageTag,tc=r}var _={exports:{}};!function(e){var t,n=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,r=Math.ceil,o=Math.floor,i="[BigNumber Error] ",a=i+"Number primitive has more than 15 significant digits: ",s=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13];function l(e){var t=0|e;return e>0||e===t?t:t-1}function u(e){for(var t,n,r=1,o=e.length,i=e[0]+"";r<o;){for(n=14-(t=e[r++]+"").length;n--;t="0"+t);i+=t}for(o=i.length;48===i.charCodeAt(--o););return i.slice(0,o+1||1)}function c(e,t){var n,r,o=e.c,i=t.c,a=e.s,s=t.s,l=e.e,u=t.e;if(!a||!s)return null;if(n=o&&!o[0],r=i&&!i[0],n||r)return n?r?0:-s:a;if(a!=s)return a;if(n=a<0,r=l==u,!o||!i)return r?0:!o^n?1:-1;if(!r)return l>u^n?1:-1;for(a=0,s=(l=o.length)<(u=i.length)?l:u;a<s;a++)if(o[a]!=i[a])return o[a]>i[a]^n?1:-1;return l==u?0:l>u^n?1:-1}function d(e,t,n,r){if(e<t||e>n||e!==o(e))throw Error(i+(r||"Argument")+("number"==typeof e?e<t||e>n?" out of range: ":" not an integer: ":" not a primitive number: ")+String(e))}function p(e){var t=e.c.length-1;return l(e.e/14)==t&&e.c[t]%2!=0}function f(e,t){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(t<0?"e":"e+")+t}function h(e,t,n){var r,o;if(t<0){for(o=n+".";++t;o+=n);e=o+e}else if(r=e.length,++t>r){for(o=n,t-=r;--t;o+=n);e+=o}else t<r&&(e=e.slice(0,t)+"."+e.slice(t));return e}(t=function e(t){var m,g,v,y,b,x,w,C,S,M=_.prototype={constructor:_,toString:null,valueOf:null},k=new _(1),E=20,D=4,T=-7,P=21,Z=-1e7,O=1e7,j=!1,R=1,N=0,A={prefix:"",groupSize:3,secondaryGroupSize:0,groupSeparator:",",decimalSeparator:".",fractionGroupSize:0,fractionGroupSeparator:"\xa0",suffix:""},F="0123456789abcdefghijklmnopqrstuvwxyz",I=!0;function _(e,t){var r,i,s,l,u,c,p,f,h=this;if(!(h instanceof _))return new _(e,t);if(null==t){if(e&&!0===e._isBigNumber){h.s=e.s,!e.c||e.e>O?h.c=h.e=null:e.e<Z?h.c=[h.e=0]:(h.e=e.e,h.c=e.c.slice());return}if((c="number"==typeof e)&&0*e==0){if(h.s=1/e<0?(e=-e,-1):1,e===~~e){for(l=0,u=e;u>=10;u/=10,l++);l>O?h.c=h.e=null:(h.e=l,h.c=[e]);return}f=String(e)}else{if(!n.test(f=String(e)))return S(h,f,c);h.s=45==f.charCodeAt(0)?(f=f.slice(1),-1):1}(l=f.indexOf("."))>-1&&(f=f.replace(".","")),(u=f.search(/e/i))>0?(l<0&&(l=u),l+=+f.slice(u+1),f=f.substring(0,u)):l<0&&(l=f.length)}else{if(d(t,2,F.length,"Base"),10==t&&I)return B(h=new _(e),E+h.e+1,D);if(f=String(e),c="number"==typeof e){if(0*e!=0)return S(h,f,c,t);if(h.s=1/e<0?(f=f.slice(1),-1):1,_.DEBUG&&f.replace(/^0\.0*|\./,"").length>15)throw Error(a+e)}else h.s=45===f.charCodeAt(0)?(f=f.slice(1),-1):1;for(r=F.slice(0,t),l=u=0,p=f.length;u<p;u++)if(0>r.indexOf(i=f.charAt(u))){if("."==i){if(u>l){l=p;continue}}else if(!s&&(f==f.toUpperCase()&&(f=f.toLowerCase())||f==f.toLowerCase()&&(f=f.toUpperCase()))){s=!0,u=-1,l=0;continue}return S(h,String(e),c,t)}c=!1,(l=(f=C(f,t,10,h.s)).indexOf("."))>-1?f=f.replace(".",""):l=f.length}for(u=0;48===f.charCodeAt(u);u++);for(p=f.length;48===f.charCodeAt(--p););if(f=f.slice(u,++p)){if(p-=u,c&&_.DEBUG&&p>15&&(e>0x1fffffffffffff||e!==o(e)))throw Error(a+h.s*e);if((l=l-u-1)>O)h.c=h.e=null;else if(l<Z)h.c=[h.e=0];else{if(h.e=l,h.c=[],u=(l+1)%14,l<0&&(u+=14),u<p){for(u&&h.c.push(+f.slice(0,u)),p-=14;u<p;)h.c.push(+f.slice(u,u+=14));u=14-(f=f.slice(u)).length}else u-=p;for(;u--;f+="0");h.c.push(+f)}}else h.c=[h.e=0]}function L(e,t,n,r){var o,i,a,s,l;if(null==n?n=D:d(n,0,8),!e.c)return e.toString();if(o=e.c[0],a=e.e,null==t)l=u(e.c),l=1==r||2==r&&(a<=T||a>=P)?f(l,a):h(l,a,"0");else if(i=(e=B(new _(e),t,n)).e,s=(l=u(e.c)).length,1==r||2==r&&(t<=i||i<=T)){for(;s<t;l+="0",s++);l=f(l,i)}else if(t-=a,l=h(l,i,"0"),i+1>s){if(--t>0)for(l+=".";t--;l+="0");}else if((t+=i-s)>0)for(i+1==s&&(l+=".");t--;l+="0");return e.s<0&&o?"-"+l:l}function V(e,t){for(var n,r,o=1,i=new _(e[0]);o<e.length;o++)(r=new _(e[o])).s&&(n=c(i,r))!==t&&(0!==n||i.s!==t)||(i=r);return i}function $(e,t,n){for(var r=1,o=t.length;!t[--o];t.pop());for(o=t[0];o>=10;o/=10,r++);return(n=r+14*n-1)>O?e.c=e.e=null:n<Z?e.c=[e.e=0]:(e.e=n,e.c=t),e}function B(e,t,n,i){var a,l,u,c,d,p,f,h=e.c;if(h){e:{for(a=1,c=h[0];c>=10;c/=10,a++);if((l=t-a)<0)l+=14,u=t,f=o((d=h[p=0])/s[a-u-1]%10);else if((p=r((l+1)/14))>=h.length){if(i){for(;h.length<=p;h.push(0));d=f=0,a=1,l%=14,u=l-14+1}else break e}else{for(a=1,d=c=h[p];c>=10;c/=10,a++);l%=14,f=(u=l-14+a)<0?0:o(d/s[a-u-1]%10)}if(i=i||t<0||null!=h[p+1]||(u<0?d:d%s[a-u-1]),i=n<4?(f||i)&&(0==n||n==(e.s<0?3:2)):f>5||5==f&&(4==n||i||6==n&&(l>0?u>0?d/s[a-u]:0:h[p-1])%10&1||n==(e.s<0?8:7)),t<1||!h[0])return h.length=0,i?(t-=e.e+1,h[0]=s[(14-t%14)%14],e.e=-t||0):h[0]=e.e=0,e;if(0==l?(h.length=p,c=1,p--):(h.length=p+1,c=s[14-l],h[p]=u>0?o(d/s[a-u]%s[u])*c:0),i)for(;;){if(0==p){for(l=1,u=h[0];u>=10;u/=10,l++);for(u=h[0]+=c,c=1;u>=10;u/=10,c++);l!=c&&(e.e++,1e14==h[0]&&(h[0]=1));break}if(h[p]+=c,1e14!=h[p])break;h[p--]=0,c=1}for(l=h.length;0===h[--l];h.pop());}e.e>O?e.c=e.e=null:e.e<Z&&(e.c=[e.e=0])}return e}function z(e){var t,n=e.e;return null===n?e.toString():(t=u(e.c),t=n<=T||n>=P?f(t,n):h(t,n,"0"),e.s<0?"-"+t:t)}return _.clone=e,_.ROUND_UP=0,_.ROUND_DOWN=1,_.ROUND_CEIL=2,_.ROUND_FLOOR=3,_.ROUND_HALF_UP=4,_.ROUND_HALF_DOWN=5,_.ROUND_HALF_EVEN=6,_.ROUND_HALF_CEIL=7,_.ROUND_HALF_FLOOR=8,_.EUCLID=9,_.config=_.set=function(e){var t,n;if(null!=e){if("object"==typeof e){if(e.hasOwnProperty(t="DECIMAL_PLACES")&&(d(n=e[t],0,1e9,t),E=n),e.hasOwnProperty(t="ROUNDING_MODE")&&(d(n=e[t],0,8,t),D=n),e.hasOwnProperty(t="EXPONENTIAL_AT")&&((n=e[t])&&n.pop?(d(n[0],-1e9,0,t),d(n[1],0,1e9,t),T=n[0],P=n[1]):(d(n,-1e9,1e9,t),T=-(P=n<0?-n:n))),e.hasOwnProperty(t="RANGE")){if((n=e[t])&&n.pop)d(n[0],-1e9,-1,t),d(n[1],1,1e9,t),Z=n[0],O=n[1];else if(d(n,-1e9,1e9,t),n)Z=-(O=n<0?-n:n);else throw Error(i+t+" cannot be zero: "+n)}if(e.hasOwnProperty(t="CRYPTO")){if(!!(n=e[t])===n){if(n){if("undefined"!=typeof crypto&&crypto&&(crypto.getRandomValues||crypto.randomBytes))j=n;else throw j=!n,Error(i+"crypto unavailable")}else j=n}else throw Error(i+t+" not true or false: "+n)}if(e.hasOwnProperty(t="MODULO_MODE")&&(d(n=e[t],0,9,t),R=n),e.hasOwnProperty(t="POW_PRECISION")&&(d(n=e[t],0,1e9,t),N=n),e.hasOwnProperty(t="FORMAT")){if("object"==typeof(n=e[t]))A=n;else throw Error(i+t+" not an object: "+n)}if(e.hasOwnProperty(t="ALPHABET")){if("string"!=typeof(n=e[t])||/^.?$|[+\-.\s]|(.).*\1/.test(n))throw Error(i+t+" invalid: "+n);I="0123456789"==n.slice(0,10),F=n}}else throw Error(i+"Object expected: "+e)}return{DECIMAL_PLACES:E,ROUNDING_MODE:D,EXPONENTIAL_AT:[T,P],RANGE:[Z,O],CRYPTO:j,MODULO_MODE:R,POW_PRECISION:N,FORMAT:A,ALPHABET:F}},_.isBigNumber=function(e){if(!e||!0!==e._isBigNumber)return!1;if(!_.DEBUG)return!0;var t,n,r=e.c,a=e.e,s=e.s;e:if("[object Array]"==({}).toString.call(r)){if((1===s||-1===s)&&a>=-1e9&&a<=1e9&&a===o(a)){if(0===r[0]){if(0===a&&1===r.length)return!0;break e}if((t=(a+1)%14)<1&&(t+=14),String(r[0]).length==t){for(t=0;t<r.length;t++)if((n=r[t])<0||n>=1e14||n!==o(n))break e;if(0!==n)return!0}}}else if(null===r&&null===a&&(null===s||1===s||-1===s))return!0;throw Error(i+"Invalid BigNumber: "+e)},_.maximum=_.max=function(){return V(arguments,-1)},_.minimum=_.min=function(){return V(arguments,1)},_.random=(m=0x20000000000000*Math.random()&2097151?function(){return o(0x20000000000000*Math.random())}:function(){return(0x40000000*Math.random()|0)*8388608+(8388608*Math.random()|0)},function(e){var t,n,a,l,u,c=0,p=[],f=new _(k);if(null==e?e=E:d(e,0,1e9),l=r(e/14),j){if(crypto.getRandomValues){for(t=crypto.getRandomValues(new Uint32Array(l*=2));c<l;)(u=131072*t[c]+(t[c+1]>>>11))>=9e15?(n=crypto.getRandomValues(new Uint32Array(2)),t[c]=n[0],t[c+1]=n[1]):(p.push(u%1e14),c+=2);c=l/2}else if(crypto.randomBytes){for(t=crypto.randomBytes(l*=7);c<l;)(u=(31&t[c])*0x1000000000000+0x10000000000*t[c+1]+0x100000000*t[c+2]+0x1000000*t[c+3]+(t[c+4]<<16)+(t[c+5]<<8)+t[c+6])>=9e15?crypto.randomBytes(7).copy(t,c):(p.push(u%1e14),c+=7);c=l/7}else throw j=!1,Error(i+"crypto unavailable")}if(!j)for(;c<l;)(u=m())<9e15&&(p[c++]=u%1e14);for(l=p[--c],e%=14,l&&e&&(u=s[14-e],p[c]=o(l/u)*u);0===p[c];p.pop(),c--);if(c<0)p=[a=0];else{for(a=-1;0===p[0];p.splice(0,1),a-=14);for(c=1,u=p[0];u>=10;u/=10,c++);c<14&&(a-=14-c)}return f.e=a,f.c=p,f}),_.sum=function(){for(var e=1,t=arguments,n=new _(t[0]);e<t.length;)n=n.plus(t[e++]);return n},C=function(){var e="0123456789";function t(e,t,n,r){for(var o,i,a=[0],s=0,l=e.length;s<l;){for(i=a.length;i--;a[i]*=t);for(a[0]+=r.indexOf(e.charAt(s++)),o=0;o<a.length;o++)a[o]>n-1&&(null==a[o+1]&&(a[o+1]=0),a[o+1]+=a[o]/n|0,a[o]%=n)}return a.reverse()}return function(n,r,o,i,a){var s,l,c,d,p,f,m,g,v=n.indexOf("."),y=E,b=D;for(v>=0&&(d=N,N=0,n=n.replace(".",""),f=(g=new _(r)).pow(n.length-v),N=d,g.c=t(h(u(f.c),f.e,"0"),10,o,e),g.e=g.c.length),c=d=(m=t(n,r,o,a?(s=F,e):(s=e,F))).length;0==m[--d];m.pop());if(!m[0])return s.charAt(0);if(v<0?--c:(f.c=m,f.e=c,f.s=i,m=(f=w(f,g,y,b,o)).c,p=f.r,c=f.e),v=m[l=c+y+1],d=o/2,p=p||l<0||null!=m[l+1],p=b<4?(null!=v||p)&&(0==b||b==(f.s<0?3:2)):v>d||v==d&&(4==b||p||6==b&&1&m[l-1]||b==(f.s<0?8:7)),l<1||!m[0])n=p?h(s.charAt(1),-y,s.charAt(0)):s.charAt(0);else{if(m.length=l,p)for(--o;++m[--l]>o;)m[l]=0,l||(++c,m=[1].concat(m));for(d=m.length;!m[--d];);for(v=0,n="";v<=d;n+=s.charAt(m[v++]));n=h(n,c,s.charAt(0))}return n}}(),w=function(){function e(e,t,n){var r,o,i,a,s=0,l=e.length,u=t%1e7,c=t/1e7|0;for(e=e.slice();l--;)r=c*(i=e[l]%1e7)+(a=e[l]/1e7|0)*u,s=((o=u*i+r%1e7*1e7+s)/n|0)+(r/1e7|0)+c*a,e[l]=o%n;return s&&(e=[s].concat(e)),e}function t(e,t,n,r){var o,i;if(n!=r)i=n>r?1:-1;else for(o=i=0;o<n;o++)if(e[o]!=t[o]){i=e[o]>t[o]?1:-1;break}return i}function n(e,t,n,r){for(var o=0;n--;)e[n]-=o,o=+(e[n]<t[n]),e[n]=o*r+e[n]-t[n];for(;!e[0]&&e.length>1;e.splice(0,1));}return function(r,i,a,s,u){var c,d,p,f,h,m,g,v,y,b,x,w,C,S,M,k,E,D=r.s==i.s?1:-1,T=r.c,P=i.c;if(!T||!T[0]||!P||!P[0])return new _(r.s&&i.s&&(T?!P||T[0]!=P[0]:P)?T&&0==T[0]||!P?0*D:D/0:NaN);for(y=(v=new _(D)).c=[],D=a+(d=r.e-i.e)+1,u||(u=1e14,d=l(r.e/14)-l(i.e/14),D=D/14|0),p=0;P[p]==(T[p]||0);p++);if(P[p]>(T[p]||0)&&d--,D<0)y.push(1),f=!0;else{for(S=T.length,k=P.length,p=0,D+=2,(h=o(u/(P[0]+1)))>1&&(P=e(P,h,u),T=e(T,h,u),k=P.length,S=T.length),C=k,x=(b=T.slice(0,k)).length;x<k;b[x++]=0);E=[0].concat(E=P.slice()),M=P[0],P[1]>=u/2&&M++;do{if(h=0,(c=t(P,b,k,x))<0){if(w=b[0],k!=x&&(w=w*u+(b[1]||0)),(h=o(w/M))>1)for(h>=u&&(h=u-1),g=(m=e(P,h,u)).length,x=b.length;1==t(m,b,g,x);)h--,n(m,k<g?E:P,g,u),g=m.length,c=1;else 0==h&&(c=h=1),g=(m=P.slice()).length;if(g<x&&(m=[0].concat(m)),n(b,m,x,u),x=b.length,-1==c)for(;1>t(P,b,k,x);)h++,n(b,k<x?E:P,x,u),x=b.length}else 0===c&&(h++,b=[0]);y[p++]=h,b[0]?b[x++]=T[C]||0:(b=[T[C]],x=1)}while((C++<S||null!=b[0])&&D--);f=null!=b[0],y[0]||y.splice(0,1)}if(1e14==u){for(p=1,D=y[0];D>=10;D/=10,p++);B(v,a+(v.e=p+14*d-1)+1,s,f)}else v.e=d,v.r=+f;return v}}(),g=/^(-?)0([xbo])(?=\w[\w.]*$)/i,v=/^([^.]+)\.$/,y=/^\.([^.]+)$/,b=/^-?(Infinity|NaN)$/,x=/^\s*\+(?=[\w.])|^\s+|\s+$/g,S=function(e,t,n,r){var o,a=n?t:t.replace(x,"");if(b.test(a))e.s=isNaN(a)?null:a<0?-1:1;else{if(!n&&(a=a.replace(g,function(e,t,n){return o="x"==(n=n.toLowerCase())?16:"b"==n?2:8,r&&r!=o?e:t}),r&&(o=r,a=a.replace(v,"$1").replace(y,"0.$1")),t!=a))return new _(a,o);if(_.DEBUG)throw Error(i+"Not a"+(r?" base "+r:"")+" number: "+t);e.s=null}e.c=e.e=null},M.absoluteValue=M.abs=function(){var e=new _(this);return e.s<0&&(e.s=1),e},M.comparedTo=function(e,t){return c(this,new _(e,t))},M.decimalPlaces=M.dp=function(e,t){var n,r,o;if(null!=e)return d(e,0,1e9),null==t?t=D:d(t,0,8),B(new _(this),e+this.e+1,t);if(!(n=this.c))return null;if(r=((o=n.length-1)-l(this.e/14))*14,o=n[o])for(;o%10==0;o/=10,r--);return r<0&&(r=0),r},M.dividedBy=M.div=function(e,t){return w(this,new _(e,t),E,D)},M.dividedToIntegerBy=M.idiv=function(e,t){return w(this,new _(e,t),0,1)},M.exponentiatedBy=M.pow=function(e,t){var n,a,s,l,u,c,d,f,h,m=this;if((e=new _(e)).c&&!e.isInteger())throw Error(i+"Exponent not an integer: "+z(e));if(null!=t&&(t=new _(t)),c=e.e>14,!m.c||!m.c[0]||1==m.c[0]&&!m.e&&1==m.c.length||!e.c||!e.c[0])return h=new _(Math.pow(+z(m),c?e.s*(2-p(e)):+z(e))),t?h.mod(t):h;if(d=e.s<0,t){if(t.c?!t.c[0]:!t.s)return new _(NaN);(a=!d&&m.isInteger()&&t.isInteger())&&(m=m.mod(t))}else{if(e.e>9&&(m.e>0||m.e<-1||(0==m.e?m.c[0]>1||c&&m.c[1]>=24e7:m.c[0]<8e13||c&&m.c[0]<=9999975e7)))return l=m.s<0&&p(e)?-0:0,m.e>-1&&(l=1/l),new _(d?1/l:l);N&&(l=r(N/14+2))}for(c?(n=new _(.5),d&&(e.s=1),f=p(e)):f=(s=Math.abs(+z(e)))%2,h=new _(k);;){if(f){if(!(h=h.times(m)).c)break;l?h.c.length>l&&(h.c.length=l):a&&(h=h.mod(t))}if(s){if(0===(s=o(s/2)))break;f=s%2}else if(B(e=e.times(n),e.e+1,1),e.e>14)f=p(e);else{if(0==(s=+z(e)))break;f=s%2}m=m.times(m),l?m.c&&m.c.length>l&&(m.c.length=l):a&&(m=m.mod(t))}return a?h:(d&&(h=k.div(h)),t?h.mod(t):l?B(h,N,D,u):h)},M.integerValue=function(e){var t=new _(this);return null==e?e=D:d(e,0,8),B(t,t.e+1,e)},M.isEqualTo=M.eq=function(e,t){return 0===c(this,new _(e,t))},M.isFinite=function(){return!!this.c},M.isGreaterThan=M.gt=function(e,t){return c(this,new _(e,t))>0},M.isGreaterThanOrEqualTo=M.gte=function(e,t){return 1===(t=c(this,new _(e,t)))||0===t},M.isInteger=function(){return!!this.c&&l(this.e/14)>this.c.length-2},M.isLessThan=M.lt=function(e,t){return 0>c(this,new _(e,t))},M.isLessThanOrEqualTo=M.lte=function(e,t){return -1===(t=c(this,new _(e,t)))||0===t},M.isNaN=function(){return!this.s},M.isNegative=function(){return this.s<0},M.isPositive=function(){return this.s>0},M.isZero=function(){return!!this.c&&0==this.c[0]},M.minus=function(e,t){var n,r,o,i,a=this.s;if(t=(e=new _(e,t)).s,!a||!t)return new _(NaN);if(a!=t)return e.s=-t,this.plus(e);var s=this.e/14,u=e.e/14,c=this.c,d=e.c;if(!s||!u){if(!c||!d)return c?(e.s=-t,e):new _(d?this:NaN);if(!c[0]||!d[0])return d[0]?(e.s=-t,e):new _(c[0]?this:3==D?-0:0)}if(s=l(s),u=l(u),c=c.slice(),a=s-u){for((i=a<0)?(a=-a,o=c):(u=s,o=d),o.reverse(),t=a;t--;o.push(0));o.reverse()}else for(r=(i=(a=c.length)<(t=d.length))?a:t,a=t=0;t<r;t++)if(c[t]!=d[t]){i=c[t]<d[t];break}if(i&&(o=c,c=d,d=o,e.s=-e.s),(t=(r=d.length)-(n=c.length))>0)for(;t--;c[n++]=0);for(t=1e14-1;r>a;){if(c[--r]<d[r]){for(n=r;n&&!c[--n];c[n]=t);--c[n],c[r]+=1e14}c[r]-=d[r]}for(;0==c[0];c.splice(0,1),--u);return c[0]?$(e,c,u):(e.s=3==D?-1:1,e.c=[e.e=0],e)},M.modulo=M.mod=function(e,t){var n,r;return(e=new _(e,t),this.c&&e.s&&(!e.c||e.c[0]))?e.c&&(!this.c||this.c[0])?(9==R?(r=e.s,e.s=1,n=w(this,e,0,3),e.s=r,n.s*=r):n=w(this,e,0,R),(e=this.minus(n.times(e))).c[0]||1!=R||(e.s=this.s),e):new _(this):new _(NaN)},M.multipliedBy=M.times=function(e,t){var n,r,o,i,a,s,u,c,d,p,f,h,m,g=this.c,v=(e=new _(e,t)).c;if(!g||!v||!g[0]||!v[0])return this.s&&e.s&&(!g||g[0]||v)&&(!v||v[0]||g)?(e.s*=this.s,g&&v?(e.c=[0],e.e=0):e.c=e.e=null):e.c=e.e=e.s=null,e;for(r=l(this.e/14)+l(e.e/14),e.s*=this.s,(u=g.length)<(p=v.length)&&(m=g,g=v,v=m,o=u,u=p,p=o),o=u+p,m=[];o--;m.push(0));for(o=p;--o>=0;){for(n=0,f=v[o]%1e7,h=v[o]/1e7|0,i=o+(a=u);i>o;)s=h*(c=g[--a]%1e7)+(d=g[a]/1e7|0)*f,n=((c=f*c+s%1e7*1e7+m[i]+n)/1e14|0)+(s/1e7|0)+h*d,m[i--]=c%1e14;m[i]=n}return n?++r:m.splice(0,1),$(e,m,r)},M.negated=function(){var e=new _(this);return e.s=-e.s||null,e},M.plus=function(e,t){var n,r=this.s;if(t=(e=new _(e,t)).s,!r||!t)return new _(NaN);if(r!=t)return e.s=-t,this.minus(e);var o=this.e/14,i=e.e/14,a=this.c,s=e.c;if(!o||!i){if(!a||!s)return new _(r/0);if(!a[0]||!s[0])return s[0]?e:new _(a[0]?this:0*r)}if(o=l(o),i=l(i),a=a.slice(),r=o-i){for(r>0?(i=o,n=s):(r=-r,n=a),n.reverse();r--;n.push(0));n.reverse()}for((r=a.length)-(t=s.length)<0&&(n=s,s=a,a=n,t=r),r=0;t;)r=(a[--t]=a[t]+s[t]+r)/1e14|0,a[t]=1e14===a[t]?0:a[t]%1e14;return r&&(a=[r].concat(a),++i),$(e,a,i)},M.precision=M.sd=function(e,t){var n,r,o;if(null!=e&&!!e!==e)return d(e,1,1e9),null==t?t=D:d(t,0,8),B(new _(this),e,t);if(!(n=this.c))return null;if(r=14*(o=n.length-1)+1,o=n[o]){for(;o%10==0;o/=10,r--);for(o=n[0];o>=10;o/=10,r++);}return e&&this.e+1>r&&(r=this.e+1),r},M.shiftedBy=function(e){return d(e,-0x1fffffffffffff,0x1fffffffffffff),this.times("1e"+e)},M.squareRoot=M.sqrt=function(){var e,t,n,r,o,i=this.c,a=this.s,s=this.e,c=E+4,d=new _("0.5");if(1!==a||!i||!i[0])return new _(!a||a<0&&(!i||i[0])?NaN:i?this:1/0);if(0==(a=Math.sqrt(+z(this)))||a==1/0?(((t=u(i)).length+s)%2==0&&(t+="0"),a=Math.sqrt(+t),s=l((s+1)/2)-(s<0||s%2),n=new _(t=a==1/0?"5e"+s:(t=a.toExponential()).slice(0,t.indexOf("e")+1)+s)):n=new _(a+""),n.c[0]){for((a=(s=n.e)+c)<3&&(a=0);;)if(o=n,n=d.times(o.plus(w(this,o,c,1))),u(o.c).slice(0,a)===(t=u(n.c)).slice(0,a)){if(n.e<s&&--a,"9999"!=(t=t.slice(a-3,a+1))&&(r||"4999"!=t)){+t&&(+t.slice(1)||"5"!=t.charAt(0))||(B(n,n.e+E+2,1),e=!n.times(n).eq(this));break}if(!r&&(B(o,o.e+E+2,0),o.times(o).eq(this))){n=o;break}c+=4,a+=4,r=1}}return B(n,n.e+E+1,D,e)},M.toExponential=function(e,t){return null!=e&&(d(e,0,1e9),e++),L(this,e,t,1)},M.toFixed=function(e,t){return null!=e&&(d(e,0,1e9),e=e+this.e+1),L(this,e,t)},M.toFormat=function(e,t,n){var r;if(null==n)null!=e&&t&&"object"==typeof t?(n=t,t=null):e&&"object"==typeof e?(n=e,e=t=null):n=A;else if("object"!=typeof n)throw Error(i+"Argument not an object: "+n);if(r=this.toFixed(e,t),this.c){var o,a=r.split("."),s=+n.groupSize,l=+n.secondaryGroupSize,u=n.groupSeparator||"",c=a[0],d=a[1],p=this.s<0,f=p?c.slice(1):c,h=f.length;if(l&&(o=s,s=l,l=o,h-=o),s>0&&h>0){for(o=h%s||s,c=f.substr(0,o);o<h;o+=s)c+=u+f.substr(o,s);l>0&&(c+=u+f.slice(o)),p&&(c="-"+c)}r=d?c+(n.decimalSeparator||"")+((l=+n.fractionGroupSize)?d.replace(RegExp("\\d{"+l+"}\\B","g"),"$&"+(n.fractionGroupSeparator||"")):d):c}return(n.prefix||"")+r+(n.suffix||"")},M.toFraction=function(e){var t,n,r,o,a,l,c,d,p,f,h,m,g=this.c;if(null!=e&&(!(c=new _(e)).isInteger()&&(c.c||1!==c.s)||c.lt(k)))throw Error(i+"Argument "+(c.isInteger()?"out of range: ":"not an integer: ")+z(c));if(!g)return new _(this);for(t=new _(k),p=n=new _(k),r=d=new _(k),m=u(g),a=t.e=m.length-this.e-1,t.c[0]=s[(l=a%14)<0?14+l:l],e=!e||c.comparedTo(t)>0?a>0?t:p:c,l=O,O=1/0,c=new _(m),d.c[0]=0;f=w(c,t,0,1),1!=(o=n.plus(f.times(r))).comparedTo(e);)n=r,r=o,p=d.plus(f.times(o=p)),d=o,t=c.minus(f.times(o=t)),c=o;return o=w(e.minus(n),r,0,1),d=d.plus(o.times(p)),n=n.plus(o.times(r)),d.s=p.s=this.s,a*=2,h=1>w(p,r,a,D).minus(this).abs().comparedTo(w(d,n,a,D).minus(this).abs())?[p,r]:[d,n],O=l,h},M.toNumber=function(){return+z(this)},M.toPrecision=function(e,t){return null!=e&&d(e,1,1e9),L(this,e,t,2)},M.toString=function(e){var t,n=this,r=n.s,o=n.e;return null===o?r?(t="Infinity",r<0&&(t="-"+t)):t="NaN":(null==e?t=o<=T||o>=P?f(u(n.c),o):h(u(n.c),o,"0"):10===e&&I?t=h(u((n=B(new _(n),E+o+1,D)).c),n.e,"0"):(d(e,2,F.length,"Base"),t=C(h(u(n.c),o,"0"),10,e,r,!0)),r<0&&n.c[0]&&(t="-"+t)),t},M.valueOf=M.toJSON=function(){return z(this)},M._isBigNumber=!0,null!=t&&_.set(t),_}()).default=t.BigNumber=t,_.exports?_.exports=t:(e||(e="undefined"!=typeof self&&self?self:window),e.BigNumber=t)}(R);var L=_.exports;let V=I(),$=A(),B={trillion:1e12,billion:1e9,million:1e6,thousand:1e3},z={totalLength:0,characteristic:0,forceAverage:!1,average:!1,mantissa:-1,optionalMantissa:!0,thousandSeparated:!1,spaceSeparated:!1,negative:"sign",forceSign:!1,roundingFunction:Math.round,spaceSeparatedAbbreviation:!1},{binarySuffixes:H,decimalSuffixes:W}=V.currentBytes(),G={scale:1024,suffixes:W,marker:"bd"},U={scale:1024,suffixes:H,marker:"b"},q={scale:1e3,suffixes:W,marker:"d"};function Y(e,t,n){let r=t[0],o=Math.abs(e);if(o>=n){for(let i=1;i<t.length;++i){let a=Math.pow(n,i),s=Math.pow(n,i+1);if(o>=a&&o<s){r=t[i],e/=a;break}}r===t[0]&&(e/=Math.pow(n,t.length-1),r=t[t.length-1])}return{value:e,suffix:r}}function X(e){let t="";for(let n=0;n<e;n++)t+="0";return t}function K({instance:e,providedFormat:t,state:n=V,decimalSeparator:r,defaults:o=n.currentDefaults()}){let i=e._value;if(0===i&&n.hasZeroFormat())return n.getZeroFormat();if(!isFinite(i))return i.toString();let a=Object.assign({},z,o,t),s=a.totalLength,l=s?0:a.characteristic,u=a.optionalCharacteristic,c=a.forceAverage,d=a.lowPrecision,p=!!s||!!c||a.average,f=s?-1:p&&void 0===t.mantissa?0:a.mantissa,h=!s&&(void 0===t.optionalMantissa?-1===f:a.optionalMantissa),m=a.trimMantissa,g=a.thousandSeparated,v=a.spaceSeparated,y=a.negative,b=a.forceSign,x=a.exponential,w=a.roundingFunction,C="";if(p){let e=function({value:e,forceAverage:t,lowPrecision:n=!0,abbreviations:r,spaceSeparated:o=!1,totalLength:i=0,roundingFunction:a=Math.round}){let s="",l=Math.abs(e),u=-1;if(t&&r[t]&&B[t]?(s=r[t],e/=B[t]):l>=B.trillion||n&&1===a(l/B.trillion)?(s=r.trillion,e/=B.trillion):l<B.trillion&&l>=B.billion||n&&1===a(l/B.billion)?(s=r.billion,e/=B.billion):l<B.billion&&l>=B.million||n&&1===a(l/B.million)?(s=r.million,e/=B.million):(l<B.million&&l>=B.thousand||n&&1===a(l/B.thousand))&&(s=r.thousand,e/=B.thousand),s&&(s=(o?" ":"")+s),i){let t=e<0,n=e.toString().split(".")[0];u=Math.max(i-(t?n.length-1:n.length),0)}return{value:e,abbreviation:s,mantissaPrecision:u}}({value:i,forceAverage:c,lowPrecision:d,abbreviations:n.currentAbbreviations(),spaceSeparated:v,roundingFunction:w,totalLength:s});i=e.value,C+=e.abbreviation,s&&(f=e.mantissaPrecision)}if(x){let e=function({value:e,characteristicPrecision:t}){let[n,r]=e.toExponential().split("e"),o=+n;return t&&1<t&&(o*=Math.pow(10,t-1),r=(r=+r-(t-1))>=0?`+${r}`:r),{value:o,abbreviation:`e${r}`}}({value:i,characteristicPrecision:l});i=e.value,C=e.abbreviation+C}let S=function(e,t,n,r,o,i){if(-1===r)return e;let a=function(e,t,n=Math.round){return -1!==e.toString().indexOf("e")?function(e,t){let n=e.toString(),[r,o]=n.split("e"),[i,a=""]=r.split(".");if(+o>0)n=i+a+X(o-a.length);else{let e=".";e=0>+i?`-0${e}`:`0${e}`;let r=(X(-o-1)+Math.abs(i)+a).substr(0,t);r.length<t&&(r+=X(t-r.length)),n=e+r}return+o>0&&t>0&&(n+=`.${X(t)}`),n}(e,t):new L(n(+`${e}e+${t}`)/Math.pow(10,t)).toFixed(t)}(t,r,i),[s,l=""]=a.toString().split(".");if(l.match(/^0+$/)&&(n||o))return s;let u=l.match(/0+$/);return o&&u?`${s}.${l.toString().slice(0,u.index)}`:a.toString()}(i.toString(),i,h,f,m,w);if(S=function(e,t,n,r,o){let i=r.currentDelimiters(),a=i.thousands;o=o||i.decimal;let s=i.thousandsSize||3,l=e.toString(),u=l.split(".")[0],c=l.split(".")[1],d=t<0&&0===u.indexOf("-");return n&&(d&&(u=u.slice(1)),(function(e,t){let n=[],r=0;for(let o=e;o>0;o--)r===t&&(n.unshift(o),r=0),r++;return n})(u.length,s).forEach((e,t)=>{u=u.slice(0,e+t)+a+u.slice(e+t)}),d&&(u=`-${u}`)),l=c?u+o+c:u}(S=function(e,t,n,r){let o=e,[i,a]=o.toString().split(".");if(i.match(/^-?0$/)&&n)return a?`${i.replace("0","")}.${a}`:i.replace("0","");let s=t<0&&0===i.indexOf("-");if(s&&(i=i.slice(1),o=o.slice(1)),i.length<r){let e=r-i.length;for(let t=0;t<e;t++)o=`0${o}`}return s&&(o=`-${o}`),o.toString()}(S,i,u,l),i,g,n,r),(p||x)&&(S+=C),b||i<0){var M,k;M=S,S=0===(k=i)?M:0==+M?M.replace("-",""):k>0?`+${M}`:"sign"===y?M:`(${M.replace("-","")})`}return S}function Q(e,t){if(!e)return t;let n=Object.keys(e);return 1===n.length&&"output"===n[0]?t:e}function J(e,t,n){let r=new L(e._value),o=t;return n.isNumbro(t)&&(o=t._value),o=new L(o),e._value=r.minus(o).toNumber(),e}let ee=I(),et=A(),en=N(),er=(...e)=>(function(e,t={},n){if("string"==typeof t&&(t=F.parseFormat(t)),!$.validateFormat(t))return"ERROR: invalid format";let r=t.prefix||"",o=t.postfix||"",i=function(e,t,n){var r,o;switch(t.output){case"currency":return function(e,t,n){let r;let o=n.currentCurrency(),i=Object.assign({},t),a=Object.assign({},z,i),s="",l=!!a.totalLength||!!a.forceAverage||a.average,u=i.currencyPosition||o.position,c=i.currencySymbol||o.symbol,d=void 0!==a.spaceSeparatedCurrency?a.spaceSeparatedCurrency:a.spaceSeparated;void 0===i.lowPrecision&&(i.lowPrecision=!1),d&&(s=" "),"infix"===u&&(r=s+c+s);let p=K({instance:e,providedFormat:i,state:n,decimalSeparator:r});return"prefix"===u&&(p=e._value<0&&"sign"===a.negative?`-${s}${c}${p.slice(1)}`:e._value>0&&a.forceSign?`+${s}${c}${p.slice(1)}`:c+s+p),u&&"postfix"!==u||(p=p+(s=!a.spaceSeparatedAbbreviation&&l?"":s)+c),p}(e,t=Q(t,V.currentCurrencyDefaultFormat()),V);case"percent":let i,a,s;return i=(r=t=Q(t,V.currentPercentageDefaultFormat())).prefixSymbol,a=K({instance:n(100*e._value),providedFormat:r,state:V}),s=Object.assign({},z,r),i?`%${s.spaceSeparated?" ":""}${a}`:`${a}${s.spaceSeparated?" ":""}%`;case"byte":return function(e,t,n,r){let o=t.base||"binary",i=Object.assign({},z,t),{binarySuffixes:a,decimalSuffixes:s}=n.currentBytes(),l={general:{scale:1024,suffixes:s||W,marker:"bd"},binary:{scale:1024,suffixes:a||H,marker:"b"},decimal:{scale:1e3,suffixes:s||W,marker:"d"}}[o],{value:u,suffix:c}=Y(e._value,l.suffixes,l.scale),d=K({instance:r(u),providedFormat:t,state:n,defaults:n.currentByteDefaultFormat()});return`${d}${i.spaceSeparated?" ":""}${c}`}(e,t=Q(t,V.currentByteDefaultFormat()),V,n);case"time":let l,u,c;return t=Q(t,V.currentTimeDefaultFormat()),l=Math.floor(e._value/60/60),u=Math.floor((e._value-3600*l)/60),c=Math.round(e._value-3600*l-60*u),`${l}:${u<10?"0":""}${u}:${c<10?"0":""}${c}`;case"ordinal":let d,p,f,h;return o=t=Q(t,V.currentOrdinalDefaultFormat()),d=V.currentOrdinal(),p=Object.assign({},z,o),f=K({instance:e,providedFormat:o,state:V}),h=d(e._value),`${f}${p.spaceSeparated?" ":""}${h}`;default:return K({instance:e,providedFormat:t,numbro:n})}}(e,t,n);return(i=r+i)+o})(...e,ev),eo=(...e)=>(function(e){return Y(e._value,G.suffixes,G.scale).suffix})(...e,ev),ei=(...e)=>(function(e){return Y(e._value,U.suffixes,U.scale).suffix})(...e,ev),ea=(...e)=>(function(e){return Y(e._value,q.suffixes,q.scale).suffix})(...e,ev),es=Q,el=(e,t)=>{let n,r;return n=new L(e._value),r=t,ev.isNumbro(t)&&(r=t._value),r=new L(r),e._value=n.plus(r).toNumber(),e},eu=(e,t)=>J(e,t,ev),ec=(e,t)=>{let n,r;return n=new L(e._value),r=t,ev.isNumbro(t)&&(r=t._value),r=new L(r),e._value=n.times(r).toNumber(),e},ed=(e,t)=>{let n,r;return n=new L(e._value),r=t,ev.isNumbro(t)&&(r=t._value),r=new L(r),e._value=n.dividedBy(r).toNumber(),e},ep=(e,t)=>{let n;return n=t,ev.isNumbro(t)&&(n=t._value),e._value=n,e},ef=(e,t)=>{let n;return J(n=ev(e._value),t,ev),Math.abs(n._value)},eh=L;class em{constructor(e){this._value=e}clone(){return ev(this._value)}format(e={}){return er(this,e)}formatCurrency(e){return"string"==typeof e&&(e=F.parseFormat(e)),(e=es(e,ee.currentCurrencyDefaultFormat())).output="currency",er(this,e)}formatTime(e={}){return e.output="time",er(this,e)}binaryByteUnits(){return ei(this)}decimalByteUnits(){return ea(this)}byteUnits(){return eo(this)}difference(e){return ef(this,e)}add(e){return el(this,e)}subtract(e){return eu(this,e)}multiply(e){return ec(this,e)}divide(e){return ed(this,e)}set(e){return ep(this,eg(e))}value(){return this._value}valueOf(){return this._value}}function eg(e){let t=e;return ev.isNumbro(e)?t=e._value:"string"==typeof e?t=ev.unformat(e):isNaN(e)&&(t=NaN),t}function ev(e){return new em(eg(e))}ev.version="2.5.0",ev.isNumbro=function(e){return e instanceof em},ev.language=ee.currentLanguage,ev.registerLanguage=ee.registerLanguage,ev.setLanguage=ee.setLanguage,ev.languages=ee.languages,ev.languageData=ee.languageData,ev.zeroFormat=ee.setZeroFormat,ev.defaultFormat=ee.currentDefaults,ev.setDefaults=ee.setDefaults,ev.defaultCurrencyFormat=ee.currentCurrencyDefaultFormat,ev.validate=et.validate,ev.loadLanguagesInNode=e=>(function(e,t){e.forEach(e=>{let n;try{n=function(e){throw Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}(`../languages/${e}`)}catch(t){console.error(`Unable to load "${e}". No matching language file found.`)}n&&t.registerLanguage(n)})})(e,ev),ev.unformat=en.unformat,ev.BigNumber=eh;var ey=ev&&ev.__esModule&&Object.prototype.hasOwnProperty.call(ev,"default")?ev.default:ev;function eb(e){return"number"==typeof e}function ex(e){return e&&(e<0?e=0:e>20&&(e=20)),e}function ew(e,{shortValues:t,decimalPlaces:n}){if(!1===t||1e3>Math.abs(e)){let r={style:"unit",unit:"byte",unitDisplay:"long",useGrouping:!0};return eb(n)?(r.minimumFractionDigits=ex(n),r.maximumFractionDigits=ex(n)):!1!==t&&(r.maximumSignificantDigits=3),Intl.NumberFormat("en-US",r).format(e)}return ey(e).format({output:"byte",base:"decimal",spaceSeparated:!0,mantissa:eb(n)?n:2,trimMantissa:!eb(n),optionalMantissa:!eb(n)})}let eC="Percent",eS="Time";var eM=((tr={}).milliseconds="millisecond",tr.seconds="second",tr.minutes="minute",tr.hours="hour",tr.days="day",tr.weeks="week",tr.months="month",tr.years="year",tr);let ek={years:31536e3,months:2592e3,weeks:604800,days:86400,hours:3600,minutes:60,seconds:1,milliseconds:.001},eE=["years","months","weeks","days","hours","minutes","seconds","milliseconds"],eD="Throughput",eT={Time:{label:"Time",decimalPlaces:!0},Percent:{label:"percent",decimalPlaces:!0},Decimal:{label:"Decimal",decimalPlaces:!0,shortValues:!0},Bytes:{label:"Bytes",decimalPlaces:!0,shortValues:!0},Throughput:{label:"Throughput",decimalPlaces:!0}},eP={milliseconds:{group:eS,label:"Milliseconds"},seconds:{group:eS,label:"Seconds"},minutes:{group:eS,label:"Minutes"},hours:{group:eS,label:"Hours"},days:{group:eS,label:"Days"},weeks:{group:eS,label:"Weeks"},months:{group:eS,label:"Months"},years:{group:eS,label:"Years"},percent:{group:eC,label:"Percent (0-100)"},"percent-decimal":{group:eC,label:"Percent (0.0-1.0)"},"%":{disableSelectorOption:!0,group:eC,label:"%"},decimal:{group:"Decimal",label:"Decimal"},bytes:{group:"Bytes",label:"Bytes"},"bits/sec":{group:eD,label:"Bits/sec"},"bytes/sec":{group:eD,label:"Bytes/sec"},"counts/sec":{group:eD,label:"Counts/sec"},"events/sec":{group:eD,label:"Events/sec"},"messages/sec":{group:eD,label:"Messages/sec"},"ops/sec":{group:eD,label:"Ops/sec"},"packets/sec":{group:eD,label:"Packets/sec"},"reads/sec":{group:eD,label:"Reads/sec"},"requests/sec":{group:eD,label:"Requests/sec"},"records/sec":{group:eD,label:"Records/sec"},"rows/sec":{group:eD,label:"Rows/sec"},"writes/sec":{group:eD,label:"Writes/sec"}};function eZ(e,t){if(void 0===t)return e.toString();if("Bytes"===eO(t))return ew(e,t);if("Decimal"===eO(t))return function(e,{shortValues:t,decimalPlaces:n}){let r={style:"decimal",useGrouping:!0};return!1!==t&&(r.notation="compact"),eb(n)?(r.minimumFractionDigits=ex(n),r.maximumFractionDigits=ex(n)):!1!==t&&(r.maximumSignificantDigits=3),Intl.NumberFormat("en-US",r).format(e)}(e,t);if("Percent"===eO(t))return function(e,{unit:t,decimalPlaces:n}){let r={style:"percent",useGrouping:!0};return eb(n)?(r.minimumFractionDigits=ex(n),r.maximumFractionDigits=ex(n)):r.maximumSignificantDigits=3,"percent"===t&&(e/=100),Intl.NumberFormat("en-US",r).format(e)}(e,t);if("Time"===eO(t))return function(e,{unit:t,decimalPlaces:n}){var r;if(0===e)return"0s";let o=function(e,t){let n=e*ek[t],r=eE[0]||"years",o=r,i=n/ek[r];for(o of eE)if((i=n/ek[o])>=1)break;return{value:i,unit:o}}(e,t),i={style:"unit",unit:eM[o.unit],unitDisplay:"months"===(r=o.unit)||"years"===r?"long":"narrow"};return eb(n)?(i.minimumFractionDigits=ex(n),i.maximumFractionDigits=ex(n)):i.maximumSignificantDigits=3,Intl.NumberFormat("en-US",i).format(o.value)}(e,t);if("Throughput"===eO(t))return function(e,{unit:t,shortValues:n,decimalPlaces:r}){if("bytes/sec"===t){let t=1e3>Math.abs(e)?"sec":"s";return ew(e,{unit:"bytes",shortValues:n,decimalPlaces:r})+"/"+t}let o={style:"decimal",useGrouping:!0};return!1!==n&&(o.notation="compact"),eb(r)?(o.minimumFractionDigits=ex(r),o.maximumFractionDigits=ex(r)):!1!==n&&(o.maximumSignificantDigits=3),Intl.NumberFormat("en-US",o).format(e)+" "+t}(e,t);throw Error(`Unknown unit options ${t}`)}function eO(e){return eP[e.unit].group}function ej(e){return eT[eP[e.unit].group]}var eR=n(36232),eN=n(508),eA=n(65201),eF=n(99635),eI=n(23709),e_=n(67745),eL=n(50378),eV=n(36372);function e$(e){let{children:t,chartsTheme:n,enablePinning:r=!1}=e,[o,i]=(0,d.useState)(null),a=(0,d.useMemo)(()=>({chartsTheme:n,enablePinning:r,lastTooltipPinnedCoords:o,setLastTooltipPinnedCoords:i}),[n,r,o,i]);return(0,c.jsx)(eB.Provider,{value:a,children:t})}let eB=(0,d.createContext)(void 0);function ez(){let e=(0,d.useContext)(eB);if(void 0===e)throw Error("No ChartsThemeContext found. Did you forget a Provider?");return e}function eH(){return ez().chartsTheme}var eW=n(59161),eG=n(56141),eU=n.n(eG),eq=n(66726),eY=n.n(eq),eX=n(8890),eK=n(48906),eQ=n(27806);(0,eR.D)([eF.N,eK.N,eQ.N,eX.N,eA.N,eI.N,e_.N,eL.N]);let eJ=["click","dblclick","mousedown","mousemove","mouseup","mouseover","mouseout","globalout","contextmenu"],e0=["datazoom","downplay","highlight"],e1=(0,d.memo)(function({option:e,theme:t,renderer:n,sx:r,onEvents:o,_instance:i,syncGroup:a,onChartInitialized:s}){let l=(0,d.useRef)(e),u=(0,d.useRef)(e),p=(0,d.useRef)(null),f=(0,d.useRef)(null);return(0,d.useLayoutEffect)(()=>{if(null!==p.current&&null===f.current&&(f.current=(0,eW.S1)(p.current,t,{renderer:n??"canvas"}),void 0!==f.current))return f.current.setOption(l.current,!0),s?.(f.current),void 0!==i&&(i.current=f.current),()=>{null!==f.current&&(f.current.dispose(),f.current=null)}},[i,s,t,n]),(0,d.useEffect)(()=>{f.current&&a&&(f.current.group=a,(0,eW.$j)([f.current]))},[a,f]),(0,d.useEffect)(()=>{!(void 0===u.current||eU()(u.current,e))&&f.current&&(f.current.setOption(e,!0),u.current=e)},[e]),(0,d.useLayoutEffect)(()=>{let e=eY()(()=>{f.current&&f.current.resize()},200);return window.addEventListener("resize",e),e(),()=>{window.removeEventListener("resize",e)}},[]),(0,d.useEffect)(()=>{let e=f.current;if(e&&void 0!==o)return function(e,t){if(void 0!==t){for(let n in t)if(Object.prototype.hasOwnProperty.call(t,n)){let r=t[n]??null;r&&function(t,n){var r,o;"function"==typeof n&&((r=t,eJ.includes(r))?e.on(t,t=>n(t,e)):(o=t,e0.includes(o))?e.on(t,e=>n(e)):e.on(t,()=>n(null,e)))}(n,r)}}}(e,o),()=>{if(void 0!==e&&!0!==e.isDisposed())for(let t in o)e.off(t)}},[o]),(0,d.useEffect)(()=>{eY()(()=>{f.current&&f.current.resize()},200,{leading:!0})()},[r]),(0,c.jsx)(eV.Z,{ref:p,sx:r})});var e2=n(15409),e5=n.n(e2);function e3(e,t){return[e5()({type:"value",boundaryGap:[0,"10%"],axisLabel:{formatter:e=>eZ(e,t)}},e)]}function e4(e){if(0===e.length)return 36e5;let t=e[e.length-1];return void 0===e[0]||void 0===t?36e5:t-e[0]}function e6(e){let{width:t,height:n,data:r,format:o={unit:"decimal"},mode:i="value"}=e,a=eH(),s=(0,d.useMemo)(()=>{if(!r||!r.length)return a.noDataOption;let e=[];return r.map(t=>{e.push([t.label,t.value])}),{title:{show:!1},dataset:[{dimensions:["label","value"],source:e}],xAxis:e3({},o),yAxis:{type:"category",splitLine:{show:!1},axisLabel:{overflow:"truncate",width:t/3}},series:{type:"bar",label:{show:!0,position:"right",formatter:e=>e.data[1]?"percentage"===i?eZ(e.data[1],{unit:"percent",decimalPlaces:o.decimalPlaces}):eZ(e.data[1],o):void 0,barMinWidth:14,barCategoryGap:6},itemStyle:{borderRadius:4,color:a.echartsTheme[0]}},tooltip:{appendToBody:!0,confine:!0,formatter:e=>e.data[1]&&`<b>${e.name}</b>   ${eZ(e.data[1],o)}`},grid:{left:"5%",right:"5%"}}},[r,a,t,i,o]);return(0,c.jsx)(eV.Z,{style:{width:t,height:n},sx:{overflow:"auto"},children:(0,c.jsx)(e1,{sx:{minHeight:n,height:r?20*r.length:"100%"},option:s,theme:a.echartsTheme})})}(0,eR.D)([eN.N,eA.N,eF.N,eI.N,e_.N,eL.N]);var e8=n(25283),e9=n(75094),e7=n(8695);function te(){return(te=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function tt(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)t.indexOf(n=i[r])>=0||(o[n]=e[n]);return o}function tn(e){var t=(0,d.useRef)(e),n=(0,d.useRef)(function(e){t.current&&t.current(e)});return t.current=e,n.current}var tr,to,ti,ta,ts,tl,tu,tc,td,tp,tf=function(e,t,n){return void 0===t&&(t=0),void 0===n&&(n=1),e>n?n:e<t?t:e},th=function(e){return"touches"in e},tm=function(e){return e&&e.ownerDocument.defaultView||self},tg=function(e,t,n){var r=e.getBoundingClientRect(),o=th(t)?function(e,t){for(var n=0;n<e.length;n++)if(e[n].identifier===t)return e[n];return e[0]}(t.touches,n):t;return{left:tf((o.pageX-(r.left+tm(e).pageXOffset))/r.width),top:tf((o.pageY-(r.top+tm(e).pageYOffset))/r.height)}},tv=function(e){th(e)||e.preventDefault()},ty=d.memo(function(e){var t=e.onMove,n=e.onKey,r=tt(e,["onMove","onKey"]),o=(0,d.useRef)(null),i=tn(t),a=tn(n),s=(0,d.useRef)(null),l=(0,d.useRef)(!1),u=(0,d.useMemo)(function(){var e=function(e){tv(e),(th(e)?e.touches.length>0:e.buttons>0)&&o.current?i(tg(o.current,e,s.current)):n(!1)},t=function(){return n(!1)};function n(n){var r=l.current,i=tm(o.current),a=n?i.addEventListener:i.removeEventListener;a(r?"touchmove":"mousemove",e),a(r?"touchend":"mouseup",t)}return[function(e){var t=e.nativeEvent,r=o.current;if(r&&(tv(t),(!l.current||th(t))&&r)){if(th(t)){l.current=!0;var a=t.changedTouches||[];a.length&&(s.current=a[0].identifier)}r.focus(),i(tg(r,t,s.current)),n(!0)}},function(e){var t=e.which||e.keyCode;t<37||t>40||(e.preventDefault(),a({left:39===t?.05:37===t?-.05:0,top:40===t?.05:38===t?-.05:0}))},n]},[a,i]),c=u[0],p=u[1],f=u[2];return(0,d.useEffect)(function(){return f},[f]),d.createElement("div",te({},r,{onTouchStart:c,onMouseDown:c,className:"react-colorful__interactive",ref:o,onKeyDown:p,tabIndex:0,role:"slider"}))}),tb=function(e){return e.filter(Boolean).join(" ")},tx=function(e){var t=e.color,n=e.left,r=e.top,o=tb(["react-colorful__pointer",e.className]);return d.createElement("div",{className:o,style:{top:100*(void 0===r?.5:r)+"%",left:100*n+"%"}},d.createElement("div",{className:"react-colorful__pointer-fill",style:{backgroundColor:t}}))},tw=function(e,t,n){return void 0===t&&(t=0),void 0===n&&(n=Math.pow(10,t)),Math.round(n*e)/n},tC=function(e){return"#"===e[0]&&(e=e.substring(1)),e.length<6?{r:parseInt(e[0]+e[0],16),g:parseInt(e[1]+e[1],16),b:parseInt(e[2]+e[2],16),a:4===e.length?tw(parseInt(e[3]+e[3],16)/255,2):1}:{r:parseInt(e.substring(0,2),16),g:parseInt(e.substring(2,4),16),b:parseInt(e.substring(4,6),16),a:8===e.length?tw(parseInt(e.substring(6,8),16)/255,2):1}},tS=function(e){var t=e.s,n=e.v,r=e.a,o=(200-t)*n/100;return{h:tw(e.h),s:tw(o>0&&o<200?t*n/100/(o<=100?o:200-o)*100:0),l:tw(o/2),a:tw(r,2)}},tM=function(e){var t=tS(e);return"hsl("+t.h+", "+t.s+"%, "+t.l+"%)"},tk=function(e){var t=e.h,n=e.s,r=e.v,o=e.a;t=t/360*6,n/=100,r/=100;var i=Math.floor(t),a=r*(1-n),s=r*(1-(t-i)*n),l=r*(1-(1-t+i)*n),u=i%6;return{r:tw(255*[r,s,a,a,l,r][u]),g:tw(255*[l,r,r,s,a,a][u]),b:tw(255*[a,a,l,r,r,s][u]),a:tw(o,2)}},tE=function(e){var t=e.toString(16);return t.length<2?"0"+t:t},tD=function(e){var t=e.r,n=e.g,r=e.b,o=e.a,i=o<1?tE(tw(255*o)):"";return"#"+tE(t)+tE(n)+tE(r)+i},tT=function(e){var t=e.r,n=e.g,r=e.b,o=e.a,i=Math.max(t,n,r),a=i-Math.min(t,n,r),s=a?i===t?(n-r)/a:i===n?2+(r-t)/a:4+(t-n)/a:0;return{h:tw(60*(s<0?s+6:s)),s:tw(i?a/i*100:0),v:tw(i/255*100),a:o}},tP=d.memo(function(e){var t=e.hue,n=e.onChange,r=tb(["react-colorful__hue",e.className]);return d.createElement("div",{className:r},d.createElement(ty,{onMove:function(e){n({h:360*e.left})},onKey:function(e){n({h:tf(t+360*e.left,0,360)})},"aria-label":"Hue","aria-valuenow":tw(t),"aria-valuemax":"360","aria-valuemin":"0"},d.createElement(tx,{className:"react-colorful__hue-pointer",left:t/360,color:tM({h:t,s:100,v:100,a:1})})))}),tZ=d.memo(function(e){var t=e.hsva,n=e.onChange,r={backgroundColor:tM({h:t.h,s:100,v:100,a:1})};return d.createElement("div",{className:"react-colorful__saturation",style:r},d.createElement(ty,{onMove:function(e){n({s:100*e.left,v:100-100*e.top})},onKey:function(e){n({s:tf(t.s+100*e.left,0,100),v:tf(t.v-100*e.top,0,100)})},"aria-label":"Color","aria-valuetext":"Saturation "+tw(t.s)+"%, Brightness "+tw(t.v)+"%"},d.createElement(tx,{className:"react-colorful__saturation-pointer",top:1-t.v/100,left:t.s/100,color:tM(t)})))}),tO=function(e,t){if(e===t)return!0;for(var n in e)if(e[n]!==t[n])return!1;return!0},tj="undefined"!=typeof window?d.useLayoutEffect:d.useEffect,tR=new Map,tN=function(e){tj(function(){var t=e.current?e.current.ownerDocument:document;if(void 0!==t&&!tR.has(t)){var r=t.createElement("style");r.innerHTML='.react-colorful{position:relative;display:flex;flex-direction:column;width:200px;height:200px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.react-colorful__saturation{position:relative;flex-grow:1;border-color:transparent;border-bottom:12px solid #000;border-radius:8px 8px 0 0;background-image:linear-gradient(0deg,#000,transparent),linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.react-colorful__alpha-gradient,.react-colorful__pointer-fill{content:"";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;border-radius:inherit}.react-colorful__alpha-gradient,.react-colorful__saturation{box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}.react-colorful__alpha,.react-colorful__hue{position:relative;height:24px}.react-colorful__hue{background:linear-gradient(90deg,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red)}.react-colorful__last-control{border-radius:0 0 8px 8px}.react-colorful__interactive{position:absolute;left:0;top:0;right:0;bottom:0;border-radius:inherit;outline:none;touch-action:none}.react-colorful__pointer{position:absolute;z-index:1;box-sizing:border-box;width:28px;height:28px;transform:translate(-50%,-50%);background-color:#fff;border:2px solid #fff;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.2)}.react-colorful__interactive:focus .react-colorful__pointer{transform:translate(-50%,-50%) scale(1.1)}.react-colorful__alpha,.react-colorful__alpha-pointer{background-color:#fff;background-image:url(\'data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill-opacity=".05"><path d="M8 0h8v8H8zM0 8h8v8H0z"/></svg>\')}.react-colorful__saturation-pointer{z-index:3}.react-colorful__hue-pointer{z-index:2}',tR.set(t,r);var o=tp||n.nc;o&&r.setAttribute("nonce",o),t.head.appendChild(r)}},[])},tA=function(e){var t,n,r,o,i,a=e.className,s=e.colorModel,l=e.color,u=void 0===l?s.defaultColor:l,c=e.onChange,p=tt(e,["className","colorModel","color","onChange"]),f=(0,d.useRef)(null);tN(f);var h=(t=tn(c),r=(n=(0,d.useState)(function(){return s.toHsva(u)}))[0],o=n[1],i=(0,d.useRef)({color:u,hsva:r}),(0,d.useEffect)(function(){if(!s.equal(u,i.current.color)){var e=s.toHsva(u);i.current={hsva:e,color:u},o(e)}},[u,s]),(0,d.useEffect)(function(){var e;tO(r,i.current.hsva)||s.equal(e=s.fromHsva(r),i.current.color)||(i.current={hsva:r,color:e},t(e))},[r,s,t]),[r,(0,d.useCallback)(function(e){o(function(t){return Object.assign({},t,e)})},[])]),m=h[0],g=h[1],v=tb(["react-colorful",a]);return d.createElement("div",te({},p,{ref:f,className:v}),d.createElement(tZ,{hsva:m,onChange:g}),d.createElement(tP,{hue:m.h,onChange:g,className:"react-colorful__last-control"}))},tF={defaultColor:"000",toHsva:function(e){return tT(tC(e))},fromHsva:function(e){return tD(tk({h:e.h,s:e.s,v:e.v,a:1}))},equal:function(e,t){return e.toLowerCase()===t.toLowerCase()||tO(tC(e),tC(t))}},tI=function(e){return d.createElement(tA,te({},e,{colorModel:tF}))},t_=n(20791),tL=n(80354);let tV=({color:e,onChange:t,onClear:n,palette:r})=>{let[o,i]=(0,d.useState)(e),a=e=>{i(e),t?.(e)};return(0,c.jsxs)(e8.Z,{spacing:1,children:[(0,c.jsx)(tI,{color:e,onChange:a,style:{width:"100%"}}),(0,c.jsx)(e8.Z,{direction:"row",flexWrap:"wrap",justifyContent:"space-evenly",width:"200px",children:r&&r.map((e,t)=>(0,c.jsx)(e9.Z,{size:"small","aria-label":`change color to ${e}`,sx:{color:e},onClick:()=>a(e),children:(0,c.jsx)(t_.default,{})},t))}),(0,c.jsxs)(e8.Z,{direction:"row",gap:1,alignItems:"center",children:[(0,c.jsx)(e7.Z,{inputProps:{"aria-label":"enter hex color"},fullWidth:!0,value:o,onChange:e=>{let n=e.target.value.replace(/([^0-9A-F]+)/gi,"").substring(0,8);i(`#${n}`),t$(e.target.value)&&t?.(e.target.value)}}),n&&(0,c.jsx)(e9.Z,{onClick:n,children:(0,c.jsx)(tL.default,{})})]})]})},t$=(e,t)=>{let n=/^#?([0-9A-F]{3,8})$/i.exec(e),r=n&&n[1]?n[1].length:0;return 3===r||6===r||!!t&&4===r||!!t&&8===r};var tB=n(6714);function tz({label:e,color:t,onColorChange:n,onClear:r}){let[o,i]=(0,d.useState)(null),a=!!o,{thresholds:{defaultColor:s,palette:l}}=eH();return(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(tH,{size:"small","aria-label":`change ${e} color`,isSelected:a,iconColor:t,onClick:e=>{i(e.currentTarget)},children:(0,c.jsx)(t_.default,{})}),(0,c.jsx)(tB.ZP,{"data-testid":"options color picker",open:a,anchorEl:o,onClose:()=>{i(null)},slotProps:{paper:{sx:{padding:e=>e.spacing(2)}}},anchorOrigin:{vertical:"top",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"right"},children:(0,c.jsx)(tV,{color:t,palette:[s,...l],onChange:n,onClear:r})})]})}let tH=(0,y.ZP)(e9.Z,{shouldForwardProp:e=>"isSelected"!==e&&"iconColor"!==e})(({iconColor:e,isSelected:t})=>({backgroundColor:t&&e?`${e}3F`:"undefined",color:e}));var tW=n(94776),tG=n(8193),tU=n(75586),tq=n(83675),tY=n(73037),tX=n(14544),tK=n(16758),tQ=n(51183),tJ=n(78849),t0=n(3552);let t1=e=>{let{alignItems:t,classes:n,dense:r,disabled:o,disableGutters:i,divider:a,selected:s}=e,l=(0,h.Z)({root:["root",r&&"dense",!i&&"gutters",a&&"divider",o&&"disabled","flex-start"===t&&"alignItemsFlexStart",s&&"selected"]},t0.t,n);return{...n,...l}},t2=(0,y.ZP)(tX.Z,{shouldForwardProp:e=>(0,tY.Z)(e)||"classes"===e,name:"MuiListItemButton",slot:"Root",overridesResolver:(e,t)=>{let{ownerState:n}=e;return[t.root,n.dense&&t.dense,"flex-start"===n.alignItems&&t.alignItemsFlexStart,n.divider&&t.divider,!n.disableGutters&&t.gutters]}})((0,b.Z)(({theme:e})=>({display:"flex",flexGrow:1,justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",minWidth:0,boxSizing:"border-box",textAlign:"left",paddingTop:8,paddingBottom:8,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest}),"&:hover":{textDecoration:"none",backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${t0.Z.selected}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:(0,m.Fq)(e.palette.primary.main,e.palette.action.selectedOpacity),[`&.${t0.Z.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:(0,m.Fq)(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}},[`&.${t0.Z.selected}:hover`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:(0,m.Fq)(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:(0,m.Fq)(e.palette.primary.main,e.palette.action.selectedOpacity)}},[`&.${t0.Z.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`&.${t0.Z.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity},variants:[{props:({ownerState:e})=>e.divider,style:{borderBottom:`1px solid ${(e.vars||e).palette.divider}`,backgroundClip:"padding-box"}},{props:{alignItems:"flex-start"},style:{alignItems:"flex-start"}},{props:({ownerState:e})=>!e.disableGutters,style:{paddingLeft:16,paddingRight:16}},{props:({ownerState:e})=>e.dense,style:{paddingTop:4,paddingBottom:4}}]}))),t5=d.forwardRef(function(e,t){let n=(0,w.i)({props:e,name:"MuiListItemButton"}),{alignItems:r="center",autoFocus:o=!1,component:i="div",children:a,dense:s=!1,disableGutters:l=!1,divider:u=!1,focusVisibleClassName:p,selected:h=!1,className:m,...g}=n,v=d.useContext(tJ.Z),y=d.useMemo(()=>({dense:s||v.dense||!1,alignItems:r,disableGutters:l}),[r,v.dense,s,l]),b=d.useRef(null);(0,tK.Z)(()=>{o&&b.current&&b.current.focus()},[o]);let x={...n,alignItems:r,dense:y.dense,disableGutters:l,divider:u,selected:h},C=t1(x),S=(0,tQ.Z)(b,t);return(0,c.jsx)(tJ.Z.Provider,{value:y,children:(0,c.jsx)(t2,{ref:S,href:g.href||g.to,component:(g.href||g.to)&&"div"===i?"button":i,focusVisibleClassName:(0,f.Z)(C.focusVisible,p),ownerState:x,className:(0,f.Z)(C.root,m),...g,classes:C,children:a})})});var t3=n(12577);function t4(...e){return e.flatMap(e=>void 0===e?[]:Array.isArray(e)?e:[e])}let t6=(0,d.memo)(function({color:e,sx:t,...n}){return(0,c.jsx)(eV.Z,{...n,sx:t4({height:4,width:16,margin:e=>e.spacing(.5)},t),style:{backgroundColor:e}})}),t8=(0,d.forwardRef)(function({item:e,sx:t,truncateLabel:n,onClick:r,isVisuallySelected:o,onMouseOver:i,onMouseOut:a,index:s,...l},u){let[p,f]=(0,d.useState)(n);return(0,c.jsxs)(t5,{...l,role:"listitem",sx:t4({padding:0,cursor:"pointer"},t),dense:!0,onClick:t=>{r(t,e.id),e.onClick?.(t)},onMouseOver:t=>i?.(t,{id:e.id,index:s}),onMouseOut:t=>a?.(t,{id:e.id,index:s}),selected:o,ref:u,children:[(0,c.jsx)(eV.Z,{sx:{display:"flex",alignItems:"center"},children:(0,c.jsx)(t6,{color:e.color})}),(0,c.jsx)(t3.Z,{primary:e.label,primaryTypographyProps:{noWrap:p},onMouseOver:function(){n&&f(!1)},onMouseOut:function(){n&&f(!0)}})]})}),t9=(0,d.memo)(t8);function t7(e,t){return"ALL"!==t&&!!t[e.id]}function ne({items:e,height:t,width:n,selectedItems:r,onLegendItemClick:o,onItemMouseOver:i,onItemMouseOut:a}){let s=e.length>5;return(0,c.jsx)(tq.OO,{style:{height:t,width:n},data:e,itemContent:(e,t)=>(0,c.jsx)(t9,{item:t,index:e,truncateLabel:s,isVisuallySelected:t7(t,r),onClick:o,onMouseOver:i,onMouseOut:a,sx:{width:"100%",wordBreak:"break-word",overflow:"hidden"}},t.id),role:"list"})}function nt({height:e,items:t,selectedItems:n,onLegendItemClick:r,onItemMouseOver:o,onItemMouseOut:i}){return(0,c.jsx)(eV.Z,{component:"ul",sx:{width:"100%",height:e,padding:[0,1,0,0],overflowY:"scroll",margin:0},children:t.map((e,t)=>(0,c.jsx)(t9,{item:e,index:t,isVisuallySelected:t7(e,n),onMouseOver:o,onMouseOut:i,onClick:r,sx:{width:"auto",float:"left",paddingRight:1.5}},e.id))})}function nn(e,t){return"function"==typeof e?e(t):e}function nr(e,t){return n=>{t.setState(t=>({...t,[e]:nn(n,t[e])}))}}function no(e){return e instanceof Function}function ni(e,t,n){let r,o=[];return i=>{let a,s;n.key&&n.debug&&(a=Date.now());let l=e(i);if(!(l.length!==o.length||l.some((e,t)=>o[t]!==e)))return r;if(o=l,n.key&&n.debug&&(s=Date.now()),r=t(...l),null==n||null==n.onChange||n.onChange(r),n.key&&n.debug&&null!=n&&n.debug()){let e=Math.round((Date.now()-a)*100)/100,t=Math.round((Date.now()-s)*100)/100,r=t/16,o=(e,t)=>{for(e=String(e);e.length<t;)e=" "+e;return e};console.info(`%c⏱ ${o(t,5)} /${o(e,5)} ms`,`
|
|
3
|
+
font-size: .6rem;
|
|
4
|
+
font-weight: bold;
|
|
5
|
+
color: hsl(${Math.max(0,Math.min(120-120*r,120))}deg 100% 31%);`,null==n?void 0:n.key)}return r}}function na(e,t,n,r){return{debug:()=>{var n;return null!=(n=null==e?void 0:e.debugAll)?n:e[t]},key:!1,onChange:r}}let ns="debugHeaders";function nl(e,t,n){var r;let o={id:null!=(r=n.id)?r:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{let e=[],t=n=>{n.subHeaders&&n.subHeaders.length&&n.subHeaders.map(t),e.push(n)};return t(o),e},getContext:()=>({table:e,header:o,column:t})};return e._features.forEach(t=>{null==t.createHeader||t.createHeader(o,e)}),o}function nu(e,t,n,r){var o,i;let a=0,s=function(e,t){void 0===t&&(t=1),a=Math.max(a,t),e.filter(e=>e.getIsVisible()).forEach(e=>{var n;null!=(n=e.columns)&&n.length&&s(e.columns,t+1)},0)};s(e);let l=[],u=(e,t)=>{let o={depth:t,id:[r,`${t}`].filter(Boolean).join("_"),headers:[]},i=[];e.forEach(e=>{let a;let s=[...i].reverse()[0],l=e.column.depth===o.depth,u=!1;if(l&&e.column.parent?a=e.column.parent:(a=e.column,u=!0),s&&(null==s?void 0:s.column)===a)s.subHeaders.push(e);else{let o=nl(n,a,{id:[r,t,a.id,null==e?void 0:e.id].filter(Boolean).join("_"),isPlaceholder:u,placeholderId:u?`${i.filter(e=>e.column===a).length}`:void 0,depth:t,index:i.length});o.subHeaders.push(e),i.push(o)}o.headers.push(e),e.headerGroup=o}),l.push(o),t>0&&u(i,t-1)};u(t.map((e,t)=>nl(n,e,{depth:a,index:t})),a-1),l.reverse();let c=e=>e.filter(e=>e.column.getIsVisible()).map(e=>{let t=0,n=0,r=[0];return e.subHeaders&&e.subHeaders.length?(r=[],c(e.subHeaders).forEach(e=>{let{colSpan:n,rowSpan:o}=e;t+=n,r.push(o)})):t=1,n+=Math.min(...r),e.colSpan=t,e.rowSpan=n,{colSpan:t,rowSpan:n}});return c(null!=(o=null==(i=l[0])?void 0:i.headers)?o:[]),l}let nc=(e,t,n,r,o,i,a)=>{let s={id:t,index:r,original:n,depth:o,parentId:a,_valuesCache:{},_uniqueValuesCache:{},getValue:t=>{if(s._valuesCache.hasOwnProperty(t))return s._valuesCache[t];let n=e.getColumn(t);if(null!=n&&n.accessorFn)return s._valuesCache[t]=n.accessorFn(s.original,r),s._valuesCache[t]},getUniqueValues:t=>{if(s._uniqueValuesCache.hasOwnProperty(t))return s._uniqueValuesCache[t];let n=e.getColumn(t);return null!=n&&n.accessorFn?(n.columnDef.getUniqueValues?s._uniqueValuesCache[t]=n.columnDef.getUniqueValues(s.original,r):s._uniqueValuesCache[t]=[s.getValue(t)],s._uniqueValuesCache[t]):void 0},renderValue:t=>{var n;return null!=(n=s.getValue(t))?n:e.options.renderFallbackValue},subRows:null!=i?i:[],getLeafRows:()=>(function(e,t){let n=[],r=e=>{e.forEach(e=>{n.push(e);let o=t(e);null!=o&&o.length&&r(o)})};return r(e),n})(s.subRows,e=>e.subRows),getParentRow:()=>s.parentId?e.getRow(s.parentId,!0):void 0,getParentRows:()=>{let e=[],t=s;for(;;){let n=t.getParentRow();if(!n)break;e.push(n),t=n}return e.reverse()},getAllCells:ni(()=>[e.getAllLeafColumns()],t=>t.map(t=>(function(e,t,n,r){let o={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(r),renderValue:()=>{var t;return null!=(t=o.getValue())?t:e.options.renderFallbackValue},getContext:ni(()=>[e,n,t,o],(e,t,n,r)=>({table:e,column:t,row:n,cell:r,getValue:r.getValue,renderValue:r.renderValue}),na(e.options,"debugCells","cell.getContext"))};return e._features.forEach(r=>{null==r.createCell||r.createCell(o,n,t,e)},{}),o})(e,s,t,t.id)),na(e.options,"debugRows","getAllCells")),_getAllCellsByColumnId:ni(()=>[s.getAllCells()],e=>e.reduce((e,t)=>(e[t.column.id]=t,e),{}),na(e.options,"debugRows","getAllCellsByColumnId"))};for(let t=0;t<e._features.length;t++){let n=e._features[t];null==n||null==n.createRow||n.createRow(s,e)}return s},nd=(e,t,n)=>{var r,o;let i=null==n||null==(r=n.toString())?void 0:r.toLowerCase();return!!(null==(o=e.getValue(t))||null==(o=o.toString())||null==(o=o.toLowerCase())?void 0:o.includes(i))};nd.autoRemove=e=>nw(e);let np=(e,t,n)=>{var r;return!!(null==(r=e.getValue(t))||null==(r=r.toString())?void 0:r.includes(n))};np.autoRemove=e=>nw(e);let nf=(e,t,n)=>{var r;return(null==(r=e.getValue(t))||null==(r=r.toString())?void 0:r.toLowerCase())===(null==n?void 0:n.toLowerCase())};nf.autoRemove=e=>nw(e);let nh=(e,t,n)=>{var r;return null==(r=e.getValue(t))?void 0:r.includes(n)};nh.autoRemove=e=>nw(e);let nm=(e,t,n)=>!n.some(n=>{var r;return!(null!=(r=e.getValue(t))&&r.includes(n))});nm.autoRemove=e=>nw(e)||!(null!=e&&e.length);let ng=(e,t,n)=>n.some(n=>{var r;return null==(r=e.getValue(t))?void 0:r.includes(n)});ng.autoRemove=e=>nw(e)||!(null!=e&&e.length);let nv=(e,t,n)=>e.getValue(t)===n;nv.autoRemove=e=>nw(e);let ny=(e,t,n)=>e.getValue(t)==n;ny.autoRemove=e=>nw(e);let nb=(e,t,n)=>{let[r,o]=n,i=e.getValue(t);return i>=r&&i<=o};nb.resolveFilterValue=e=>{let[t,n]=e,r="number"!=typeof t?parseFloat(t):t,o="number"!=typeof n?parseFloat(n):n,i=null===t||Number.isNaN(r)?-1/0:r,a=null===n||Number.isNaN(o)?1/0:o;if(i>a){let e=i;i=a,a=e}return[i,a]},nb.autoRemove=e=>nw(e)||nw(e[0])&&nw(e[1]);let nx={includesString:nd,includesStringSensitive:np,equalsString:nf,arrIncludes:nh,arrIncludesAll:nm,arrIncludesSome:ng,equals:nv,weakEquals:ny,inNumberRange:nb};function nw(e){return null==e||""===e}function nC(e,t,n){return!!e&&!!e.autoRemove&&e.autoRemove(t,n)||void 0===t||"string"==typeof t&&!t}let nS={sum:(e,t,n)=>n.reduce((t,n)=>{let r=n.getValue(e);return t+("number"==typeof r?r:0)},0),min:(e,t,n)=>{let r;return n.forEach(t=>{let n=t.getValue(e);null!=n&&(r>n||void 0===r&&n>=n)&&(r=n)}),r},max:(e,t,n)=>{let r;return n.forEach(t=>{let n=t.getValue(e);null!=n&&(r<n||void 0===r&&n>=n)&&(r=n)}),r},extent:(e,t,n)=>{let r,o;return n.forEach(t=>{let n=t.getValue(e);null!=n&&(void 0===r?n>=n&&(r=o=n):(r>n&&(r=n),o<n&&(o=n)))}),[r,o]},mean:(e,t)=>{let n=0,r=0;if(t.forEach(t=>{let o=t.getValue(e);null!=o&&(o*=1)>=o&&(++n,r+=o)}),n)return r/n},median:(e,t)=>{if(!t.length)return;let n=t.map(t=>t.getValue(e));if(!(Array.isArray(n)&&n.every(e=>"number"==typeof e)))return;if(1===n.length)return n[0];let r=Math.floor(n.length/2),o=n.sort((e,t)=>e-t);return n.length%2!=0?o[r]:(o[r-1]+o[r])/2},unique:(e,t)=>Array.from(new Set(t.map(t=>t.getValue(e))).values()),uniqueCount:(e,t)=>new Set(t.map(t=>t.getValue(e))).size,count:(e,t)=>t.length},nM=()=>({left:[],right:[]}),nk={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},nE=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),nD=null;function nT(e){return"touchstart"===e.type}function nP(e,t){return t?"center"===t?e.getCenterVisibleLeafColumns():"left"===t?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}let nZ=()=>({pageIndex:0,pageSize:10}),nO=()=>({top:[],bottom:[]}),nj=(e,t,n,r,o)=>{var i;let a=o.getRow(t,!0);n?(a.getCanMultiSelect()||Object.keys(e).forEach(t=>delete e[t]),a.getCanSelect()&&(e[t]=!0)):delete e[t],r&&null!=(i=a.subRows)&&i.length&&a.getCanSelectSubRows()&&a.subRows.forEach(t=>nj(e,t.id,n,r,o))};function nR(e,t){let n=e.getState().rowSelection,r=[],o={},i=function(e,t){return e.map(e=>{var t;let a=nN(e,n);if(a&&(r.push(e),o[e.id]=e),null!=(t=e.subRows)&&t.length&&(e={...e,subRows:i(e.subRows)}),a)return e}).filter(Boolean)};return{rows:i(t.rows),flatRows:r,rowsById:o}}function nN(e,t){var n;return null!=(n=t[e.id])&&n}function nA(e,t,n){var r;if(!(null!=(r=e.subRows)&&r.length))return!1;let o=!0,i=!1;return e.subRows.forEach(e=>{if((!i||o)&&(e.getCanSelect()&&(nN(e,t)?i=!0:o=!1),e.subRows&&e.subRows.length)){let n=nA(e,t);"all"===n?i=!0:("some"===n&&(i=!0),o=!1)}}),o?"all":!!i&&"some"}let nF=/([0-9]+)/gm;function nI(e,t){return e===t?0:e>t?1:-1}function n_(e){return"number"==typeof e?isNaN(e)||e===1/0||e===-1/0?"":String(e):"string"==typeof e?e:""}function nL(e,t){let n=e.split(nF).filter(Boolean),r=t.split(nF).filter(Boolean);for(;n.length&&r.length;){let e=n.shift(),t=r.shift(),o=parseInt(e,10),i=parseInt(t,10),a=[o,i].sort();if(isNaN(a[0])){if(e>t)return 1;if(t>e)return -1;continue}if(isNaN(a[1]))return isNaN(o)?-1:1;if(o>i)return 1;if(i>o)return -1}return n.length-r.length}let nV={alphanumeric:(e,t,n)=>nL(n_(e.getValue(n)).toLowerCase(),n_(t.getValue(n)).toLowerCase()),alphanumericCaseSensitive:(e,t,n)=>nL(n_(e.getValue(n)),n_(t.getValue(n))),text:(e,t,n)=>nI(n_(e.getValue(n)).toLowerCase(),n_(t.getValue(n)).toLowerCase()),textCaseSensitive:(e,t,n)=>nI(n_(e.getValue(n)),n_(t.getValue(n))),datetime:(e,t,n)=>{let r=e.getValue(n),o=t.getValue(n);return r>o?1:r<o?-1:0},basic:(e,t,n)=>nI(e.getValue(n),t.getValue(n))},n$=[{createTable:e=>{e.getHeaderGroups=ni(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,o)=>{var i,a;let s=null!=(i=null==r?void 0:r.map(e=>n.find(t=>t.id===e)).filter(Boolean))?i:[],l=null!=(a=null==o?void 0:o.map(e=>n.find(t=>t.id===e)).filter(Boolean))?a:[];return nu(t,[...s,...n.filter(e=>!(null!=r&&r.includes(e.id))&&!(null!=o&&o.includes(e.id))),...l],e)},na(e.options,ns,"getHeaderGroups")),e.getCenterHeaderGroups=ni(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,o)=>nu(t,n=n.filter(e=>!(null!=r&&r.includes(e.id))&&!(null!=o&&o.includes(e.id))),e,"center"),na(e.options,ns,"getCenterHeaderGroups")),e.getLeftHeaderGroups=ni(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,r)=>{var o;return nu(t,null!=(o=null==r?void 0:r.map(e=>n.find(t=>t.id===e)).filter(Boolean))?o:[],e,"left")},na(e.options,ns,"getLeftHeaderGroups")),e.getRightHeaderGroups=ni(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,r)=>{var o;return nu(t,null!=(o=null==r?void 0:r.map(e=>n.find(t=>t.id===e)).filter(Boolean))?o:[],e,"right")},na(e.options,ns,"getRightHeaderGroups")),e.getFooterGroups=ni(()=>[e.getHeaderGroups()],e=>[...e].reverse(),na(e.options,ns,"getFooterGroups")),e.getLeftFooterGroups=ni(()=>[e.getLeftHeaderGroups()],e=>[...e].reverse(),na(e.options,ns,"getLeftFooterGroups")),e.getCenterFooterGroups=ni(()=>[e.getCenterHeaderGroups()],e=>[...e].reverse(),na(e.options,ns,"getCenterFooterGroups")),e.getRightFooterGroups=ni(()=>[e.getRightHeaderGroups()],e=>[...e].reverse(),na(e.options,ns,"getRightFooterGroups")),e.getFlatHeaders=ni(()=>[e.getHeaderGroups()],e=>e.map(e=>e.headers).flat(),na(e.options,ns,"getFlatHeaders")),e.getLeftFlatHeaders=ni(()=>[e.getLeftHeaderGroups()],e=>e.map(e=>e.headers).flat(),na(e.options,ns,"getLeftFlatHeaders")),e.getCenterFlatHeaders=ni(()=>[e.getCenterHeaderGroups()],e=>e.map(e=>e.headers).flat(),na(e.options,ns,"getCenterFlatHeaders")),e.getRightFlatHeaders=ni(()=>[e.getRightHeaderGroups()],e=>e.map(e=>e.headers).flat(),na(e.options,ns,"getRightFlatHeaders")),e.getCenterLeafHeaders=ni(()=>[e.getCenterFlatHeaders()],e=>e.filter(e=>{var t;return!(null!=(t=e.subHeaders)&&t.length)}),na(e.options,ns,"getCenterLeafHeaders")),e.getLeftLeafHeaders=ni(()=>[e.getLeftFlatHeaders()],e=>e.filter(e=>{var t;return!(null!=(t=e.subHeaders)&&t.length)}),na(e.options,ns,"getLeftLeafHeaders")),e.getRightLeafHeaders=ni(()=>[e.getRightFlatHeaders()],e=>e.filter(e=>{var t;return!(null!=(t=e.subHeaders)&&t.length)}),na(e.options,ns,"getRightLeafHeaders")),e.getLeafHeaders=ni(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(e,t,n)=>{var r,o,i,a,s,l;return[...null!=(r=null==(o=e[0])?void 0:o.headers)?r:[],...null!=(i=null==(a=t[0])?void 0:a.headers)?i:[],...null!=(s=null==(l=n[0])?void 0:l.headers)?s:[]].map(e=>e.getLeafHeaders()).flat()},na(e.options,ns,"getLeafHeaders"))}},{getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:nr("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(t=>({...t,[e.id]:null!=n?n:!e.getIsVisible()}))},e.getIsVisible=()=>{var n,r;let o=e.columns;return null==(n=o.length?o.some(e=>e.getIsVisible()):null==(r=t.getState().columnVisibility)?void 0:r[e.id])||n},e.getCanHide=()=>{var n,r;return(null==(n=e.columnDef.enableHiding)||n)&&(null==(r=t.options.enableHiding)||r)},e.getToggleVisibilityHandler=()=>t=>{null==e.toggleVisibility||e.toggleVisibility(t.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=ni(()=>[e.getAllCells(),t.getState().columnVisibility],e=>e.filter(e=>e.column.getIsVisible()),na(t.options,"debugRows","_getAllVisibleCells")),e.getVisibleCells=ni(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(e,t,n)=>[...e,...t,...n],na(t.options,"debugRows","getVisibleCells"))},createTable:e=>{let t=(t,n)=>ni(()=>[n(),n().filter(e=>e.getIsVisible()).map(e=>e.id).join("_")],e=>e.filter(e=>null==e.getIsVisible?void 0:e.getIsVisible()),na(e.options,"debugColumns",t));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=t=>null==e.options.onColumnVisibilityChange?void 0:e.options.onColumnVisibilityChange(t),e.resetColumnVisibility=t=>{var n;e.setColumnVisibility(t?{}:null!=(n=e.initialState.columnVisibility)?n:{})},e.toggleAllColumnsVisible=t=>{var n;t=null!=(n=t)?n:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((e,n)=>({...e,[n.id]:t||!(null!=n.getCanHide&&n.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(e=>!(null!=e.getIsVisible&&e.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(e=>null==e.getIsVisible?void 0:e.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>t=>{var n;e.toggleAllColumnsVisible(null==(n=t.target)?void 0:n.checked)}}},{getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:nr("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=ni(e=>[nP(t,e)],t=>t.findIndex(t=>t.id===e.id),na(t.options,"debugColumns","getIndex")),e.getIsFirstColumn=n=>{var r;return(null==(r=nP(t,n)[0])?void 0:r.id)===e.id},e.getIsLastColumn=n=>{var r;let o=nP(t,n);return(null==(r=o[o.length-1])?void 0:r.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>null==e.options.onColumnOrderChange?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:null!=(n=e.initialState.columnOrder)?n:[])},e._getOrderColumnsFn=ni(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(e,t,n)=>r=>{let o=[];if(null!=e&&e.length){let t=[...e],n=[...r];for(;n.length&&t.length;){let e=t.shift(),r=n.findIndex(t=>t.id===e);r>-1&&o.push(n.splice(r,1)[0])}o=[...o,...n]}else o=r;return function(e,t,n){if(!(null!=t&&t.length)||!n)return e;let r=e.filter(e=>!t.includes(e.id));return"remove"===n?r:[...t.map(t=>e.find(e=>e.id===t)).filter(Boolean),...r]}(o,t,n)},na(e.options,"debugTable","_getOrderColumnsFn"))}},{getInitialState:e=>({columnPinning:nM(),...e}),getDefaultOptions:e=>({onColumnPinningChange:nr("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{let r=e.getLeafColumns().map(e=>e.id).filter(Boolean);t.setColumnPinning(e=>{var t,o,i,a,s,l;return"right"===n?{left:(null!=(i=null==e?void 0:e.left)?i:[]).filter(e=>!(null!=r&&r.includes(e))),right:[...(null!=(a=null==e?void 0:e.right)?a:[]).filter(e=>!(null!=r&&r.includes(e))),...r]}:"left"===n?{left:[...(null!=(s=null==e?void 0:e.left)?s:[]).filter(e=>!(null!=r&&r.includes(e))),...r],right:(null!=(l=null==e?void 0:e.right)?l:[]).filter(e=>!(null!=r&&r.includes(e)))}:{left:(null!=(t=null==e?void 0:e.left)?t:[]).filter(e=>!(null!=r&&r.includes(e))),right:(null!=(o=null==e?void 0:e.right)?o:[]).filter(e=>!(null!=r&&r.includes(e)))}})},e.getCanPin=()=>e.getLeafColumns().some(e=>{var n,r,o;return(null==(n=e.columnDef.enablePinning)||n)&&(null==(r=null!=(o=t.options.enableColumnPinning)?o:t.options.enablePinning)||r)}),e.getIsPinned=()=>{let n=e.getLeafColumns().map(e=>e.id),{left:r,right:o}=t.getState().columnPinning,i=n.some(e=>null==r?void 0:r.includes(e)),a=n.some(e=>null==o?void 0:o.includes(e));return i?"left":!!a&&"right"},e.getPinnedIndex=()=>{var n,r;let o=e.getIsPinned();return o?null!=(n=null==(r=t.getState().columnPinning)||null==(r=r[o])?void 0:r.indexOf(e.id))?n:-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=ni(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(e,t,n)=>{let r=[...null!=t?t:[],...null!=n?n:[]];return e.filter(e=>!r.includes(e.column.id))},na(t.options,"debugRows","getCenterVisibleCells")),e.getLeftVisibleCells=ni(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(e,t)=>(null!=t?t:[]).map(t=>e.find(e=>e.column.id===t)).filter(Boolean).map(e=>({...e,position:"left"})),na(t.options,"debugRows","getLeftVisibleCells")),e.getRightVisibleCells=ni(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(e,t)=>(null!=t?t:[]).map(t=>e.find(e=>e.column.id===t)).filter(Boolean).map(e=>({...e,position:"right"})),na(t.options,"debugRows","getRightVisibleCells"))},createTable:e=>{e.setColumnPinning=t=>null==e.options.onColumnPinningChange?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,r;return e.setColumnPinning(t?nM():null!=(n=null==(r=e.initialState)?void 0:r.columnPinning)?n:nM())},e.getIsSomeColumnsPinned=t=>{var n,r,o;let i=e.getState().columnPinning;return t?!!(null==(n=i[t])?void 0:n.length):!!((null==(r=i.left)?void 0:r.length)||(null==(o=i.right)?void 0:o.length))},e.getLeftLeafColumns=ni(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(e,t)=>(null!=t?t:[]).map(t=>e.find(e=>e.id===t)).filter(Boolean),na(e.options,"debugColumns","getLeftLeafColumns")),e.getRightLeafColumns=ni(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(e,t)=>(null!=t?t:[]).map(t=>e.find(e=>e.id===t)).filter(Boolean),na(e.options,"debugColumns","getRightLeafColumns")),e.getCenterLeafColumns=ni(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(e,t,n)=>{let r=[...null!=t?t:[],...null!=n?n:[]];return e.filter(e=>!r.includes(e.id))},na(e.options,"debugColumns","getCenterLeafColumns"))}},{createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},{getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:nr("columnFilters",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{let n=t.getCoreRowModel().flatRows[0],r=null==n?void 0:n.getValue(e.id);return"string"==typeof r?nx.includesString:"number"==typeof r?nx.inNumberRange:"boolean"==typeof r||null!==r&&"object"==typeof r?nx.equals:Array.isArray(r)?nx.arrIncludes:nx.weakEquals},e.getFilterFn=()=>{var n,r;return no(e.columnDef.filterFn)?e.columnDef.filterFn:"auto"===e.columnDef.filterFn?e.getAutoFilterFn():null!=(n=null==(r=t.options.filterFns)?void 0:r[e.columnDef.filterFn])?n:nx[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,r,o;return(null==(n=e.columnDef.enableColumnFilter)||n)&&(null==(r=t.options.enableColumnFilters)||r)&&(null==(o=t.options.enableFilters)||o)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return null==(n=t.getState().columnFilters)||null==(n=n.find(t=>t.id===e.id))?void 0:n.value},e.getFilterIndex=()=>{var n,r;return null!=(n=null==(r=t.getState().columnFilters)?void 0:r.findIndex(t=>t.id===e.id))?n:-1},e.setFilterValue=n=>{t.setColumnFilters(t=>{var r,o;let i=e.getFilterFn(),a=null==t?void 0:t.find(t=>t.id===e.id),s=nn(n,a?a.value:void 0);if(nC(i,s,e))return null!=(r=null==t?void 0:t.filter(t=>t.id!==e.id))?r:[];let l={id:e.id,value:s};return a?null!=(o=null==t?void 0:t.map(t=>t.id===e.id?l:t))?o:[]:null!=t&&t.length?[...t,l]:[l]})}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{let n=e.getAllLeafColumns();null==e.options.onColumnFiltersChange||e.options.onColumnFiltersChange(e=>{var r;return null==(r=nn(t,e))?void 0:r.filter(e=>{let t=n.find(t=>t.id===e.id);return!(t&&nC(t.getFilterFn(),e.value,t))})})},e.resetColumnFilters=t=>{var n,r;e.setColumnFilters(t?[]:null!=(n=null==(r=e.initialState)?void 0:r.columnFilters)?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel)?e.getPreFilteredRowModel():e._getFilteredRowModel()}},{createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},{getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:nr("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;let r=null==(n=e.getCoreRowModel().flatRows[0])||null==(n=n._getAllCellsByColumnId()[t.id])?void 0:n.getValue();return"string"==typeof r||"number"==typeof r}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,r,o,i;return(null==(n=e.columnDef.enableGlobalFilter)||n)&&(null==(r=t.options.enableGlobalFilter)||r)&&(null==(o=t.options.enableFilters)||o)&&(null==(i=null==t.options.getColumnCanGlobalFilter?void 0:t.options.getColumnCanGlobalFilter(e))||i)&&!!e.accessorFn}},createTable:e=>{e.getGlobalAutoFilterFn=()=>nx.includesString,e.getGlobalFilterFn=()=>{var t,n;let{globalFilterFn:r}=e.options;return no(r)?r:"auto"===r?e.getGlobalAutoFilterFn():null!=(t=null==(n=e.options.filterFns)?void 0:n[r])?t:nx[r]},e.setGlobalFilter=t=>{null==e.options.onGlobalFilterChange||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},{getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:nr("sorting",e),isMultiSortEvent:e=>e.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{let n=t.getFilteredRowModel().flatRows.slice(10),r=!1;for(let t of n){let n=null==t?void 0:t.getValue(e.id);if("[object Date]"===Object.prototype.toString.call(n))return nV.datetime;if("string"==typeof n&&(r=!0,n.split(nF).length>1))return nV.alphanumeric}return r?nV.text:nV.basic},e.getAutoSortDir=()=>{let n=t.getFilteredRowModel().flatRows[0];return"string"==typeof(null==n?void 0:n.getValue(e.id))?"asc":"desc"},e.getSortingFn=()=>{var n,r;if(!e)throw Error();return no(e.columnDef.sortingFn)?e.columnDef.sortingFn:"auto"===e.columnDef.sortingFn?e.getAutoSortingFn():null!=(n=null==(r=t.options.sortingFns)?void 0:r[e.columnDef.sortingFn])?n:nV[e.columnDef.sortingFn]},e.toggleSorting=(n,r)=>{let o=e.getNextSortingOrder(),i=null!=n;t.setSorting(a=>{let s;let l=null==a?void 0:a.find(t=>t.id===e.id),u=null==a?void 0:a.findIndex(t=>t.id===e.id),c=[],d=i?n:"desc"===o;if("toggle"!=(s=null!=a&&a.length&&e.getCanMultiSort()&&r?l?"toggle":"add":null!=a&&a.length&&u!==a.length-1?"replace":l?"toggle":"replace")||i||o||(s="remove"),"add"===s){var p;(c=[...a,{id:e.id,desc:d}]).splice(0,c.length-(null!=(p=t.options.maxMultiSortColCount)?p:Number.MAX_SAFE_INTEGER))}else c="toggle"===s?a.map(t=>t.id===e.id?{...t,desc:d}:t):"remove"===s?a.filter(t=>t.id!==e.id):[{id:e.id,desc:d}];return c})},e.getFirstSortDir=()=>{var n,r;return(null!=(n=null!=(r=e.columnDef.sortDescFirst)?r:t.options.sortDescFirst)?n:"desc"===e.getAutoSortDir())?"desc":"asc"},e.getNextSortingOrder=n=>{var r,o;let i=e.getFirstSortDir(),a=e.getIsSorted();return a?(a===i||null!=(r=t.options.enableSortingRemoval)&&!r||!!n&&null!=(o=t.options.enableMultiRemove)&&!o)&&("desc"===a?"asc":"desc"):i},e.getCanSort=()=>{var n,r;return(null==(n=e.columnDef.enableSorting)||n)&&(null==(r=t.options.enableSorting)||r)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,r;return null!=(n=null!=(r=e.columnDef.enableMultiSort)?r:t.options.enableMultiSort)?n:!!e.accessorFn},e.getIsSorted=()=>{var n;let r=null==(n=t.getState().sorting)?void 0:n.find(t=>t.id===e.id);return!!r&&(r.desc?"desc":"asc")},e.getSortIndex=()=>{var n,r;return null!=(n=null==(r=t.getState().sorting)?void 0:r.findIndex(t=>t.id===e.id))?n:-1},e.clearSorting=()=>{t.setSorting(t=>null!=t&&t.length?t.filter(t=>t.id!==e.id):[])},e.getToggleSortingHandler=()=>{let n=e.getCanSort();return r=>{n&&(null==r.persist||r.persist(),null==e.toggleSorting||e.toggleSorting(void 0,!!e.getCanMultiSort()&&(null==t.options.isMultiSortEvent?void 0:t.options.isMultiSortEvent(r))))}}},createTable:e=>{e.setSorting=t=>null==e.options.onSortingChange?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,r;e.setSorting(t?[]:null!=(n=null==(r=e.initialState)?void 0:r.sorting)?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel)?e.getPreSortedRowModel():e._getSortedRowModel()}},{getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return null!=(t=null==(n=e.getValue())||null==n.toString?void 0:n.toString())?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:nr("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(t=>null!=t&&t.includes(e.id)?t.filter(t=>t!==e.id):[...null!=t?t:[],e.id])},e.getCanGroup=()=>{var n,r;return(null==(n=e.columnDef.enableGrouping)||n)&&(null==(r=t.options.enableGrouping)||r)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return null==(n=t.getState().grouping)?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return null==(n=t.getState().grouping)?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{let t=e.getCanGroup();return()=>{t&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{let n=t.getCoreRowModel().flatRows[0],r=null==n?void 0:n.getValue(e.id);return"number"==typeof r?nS.sum:"[object Date]"===Object.prototype.toString.call(r)?nS.extent:void 0},e.getAggregationFn=()=>{var n,r;if(!e)throw Error();return no(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:"auto"===e.columnDef.aggregationFn?e.getAutoAggregationFn():null!=(n=null==(r=t.options.aggregationFns)?void 0:r[e.columnDef.aggregationFn])?n:nS[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>null==e.options.onGroupingChange?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,r;e.setGrouping(t?[]:null!=(n=null==(r=e.initialState)?void 0:r.grouping)?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel)?e.getPreGroupedRowModel():e._getGroupedRowModel()},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];let r=t.getColumn(n);return null!=r&&r.columnDef.getGroupingValue?(e._groupingValuesCache[n]=r.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,r)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var t;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!(null!=(t=n.subRows)&&t.length)}}},{getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:nr("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var r,o;if(!t){e._queue(()=>{t=!0});return}if(null!=(r=null!=(o=e.options.autoResetAll)?o:e.options.autoResetExpanded)?r:!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=t=>null==e.options.onExpandedChange?void 0:e.options.onExpandedChange(t),e.toggleAllRowsExpanded=t=>{(null!=t?t:!e.getIsAllRowsExpanded())?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=t=>{var n,r;e.setExpanded(t?{}:null!=(n=null==(r=e.initialState)?void 0:r.expanded)?n:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(e=>e.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>t=>{null==t.persist||t.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{let t=e.getState().expanded;return!0===t||Object.values(t).some(Boolean)},e.getIsAllRowsExpanded=()=>{let t=e.getState().expanded;return"boolean"==typeof t?!0===t:!(!Object.keys(t).length||e.getRowModel().flatRows.some(e=>!e.getIsExpanded()))},e.getExpandedDepth=()=>{let t=0;return(!0===e.getState().expanded?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(e=>{let n=e.split(".");t=Math.max(t,n.length)}),t},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel)?e.getPreExpandedRowModel():e._getExpandedRowModel()},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(r=>{var o;let i=!0===r||!!(null!=r&&r[e.id]),a={};if(!0===r?Object.keys(t.getRowModel().rowsById).forEach(e=>{a[e]=!0}):a=r,n=null!=(o=n)?o:!i,!i&&n)return{...a,[e.id]:!0};if(i&&!n){let{[e.id]:t,...n}=a;return n}return r})},e.getIsExpanded=()=>{var n;let r=t.getState().expanded;return!!(null!=(n=null==t.options.getIsRowExpanded?void 0:t.options.getIsRowExpanded(e))?n:!0===r||(null==r?void 0:r[e.id]))},e.getCanExpand=()=>{var n,r,o;return null!=(n=null==t.options.getRowCanExpand?void 0:t.options.getRowCanExpand(e))?n:(null==(r=t.options.enableExpanding)||r)&&!!(null!=(o=e.subRows)&&o.length)},e.getIsAllParentsExpanded=()=>{let n=!0,r=e;for(;n&&r.parentId;)n=(r=t.getRow(r.parentId,!0)).getIsExpanded();return n},e.getToggleExpandedHandler=()=>{let t=e.getCanExpand();return()=>{t&&e.toggleExpanded()}}}},{getInitialState:e=>({...e,pagination:{...nZ(),...null==e?void 0:e.pagination}}),getDefaultOptions:e=>({onPaginationChange:nr("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var r,o;if(!t){e._queue(()=>{t=!0});return}if(null!=(r=null!=(o=e.options.autoResetAll)?o:e.options.autoResetPageIndex)?r:!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=t=>null==e.options.onPaginationChange?void 0:e.options.onPaginationChange(e=>nn(t,e)),e.resetPagination=t=>{var n;e.setPagination(t?nZ():null!=(n=e.initialState.pagination)?n:nZ())},e.setPageIndex=t=>{e.setPagination(n=>{let r=nn(t,n.pageIndex);return r=Math.max(0,Math.min(r,void 0===e.options.pageCount||-1===e.options.pageCount?Number.MAX_SAFE_INTEGER:e.options.pageCount-1)),{...n,pageIndex:r}})},e.resetPageIndex=t=>{var n,r;e.setPageIndex(t?0:null!=(n=null==(r=e.initialState)||null==(r=r.pagination)?void 0:r.pageIndex)?n:0)},e.resetPageSize=t=>{var n,r;e.setPageSize(t?10:null!=(n=null==(r=e.initialState)||null==(r=r.pagination)?void 0:r.pageSize)?n:10)},e.setPageSize=t=>{e.setPagination(e=>{let n=Math.max(1,nn(t,e.pageSize)),r=Math.floor(e.pageSize*e.pageIndex/n);return{...e,pageIndex:r,pageSize:n}})},e.setPageCount=t=>e.setPagination(n=>{var r;let o=nn(t,null!=(r=e.options.pageCount)?r:-1);return"number"==typeof o&&(o=Math.max(-1,o)),{...n,pageCount:o}}),e.getPageOptions=ni(()=>[e.getPageCount()],e=>{let t=[];return e&&e>0&&(t=[...Array(e)].fill(null).map((e,t)=>t)),t},na(e.options,"debugTable","getPageOptions")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{let{pageIndex:t}=e.getState().pagination,n=e.getPageCount();return -1===n||0!==n&&t<n-1},e.previousPage=()=>e.setPageIndex(e=>e-1),e.nextPage=()=>e.setPageIndex(e=>e+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel)?e.getPrePaginationRowModel():e._getPaginationRowModel(),e.getPageCount=()=>{var t;return null!=(t=e.options.pageCount)?t:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var t;return null!=(t=e.options.rowCount)?t:e.getPrePaginationRowModel().rows.length}}},{getInitialState:e=>({rowPinning:nO(),...e}),getDefaultOptions:e=>({onRowPinningChange:nr("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,r,o)=>{let i=r?e.getLeafRows().map(e=>{let{id:t}=e;return t}):[],a=new Set([...o?e.getParentRows().map(e=>{let{id:t}=e;return t}):[],e.id,...i]);t.setRowPinning(e=>{var t,r,o,i,s,l;return"bottom"===n?{top:(null!=(o=null==e?void 0:e.top)?o:[]).filter(e=>!(null!=a&&a.has(e))),bottom:[...(null!=(i=null==e?void 0:e.bottom)?i:[]).filter(e=>!(null!=a&&a.has(e))),...Array.from(a)]}:"top"===n?{top:[...(null!=(s=null==e?void 0:e.top)?s:[]).filter(e=>!(null!=a&&a.has(e))),...Array.from(a)],bottom:(null!=(l=null==e?void 0:e.bottom)?l:[]).filter(e=>!(null!=a&&a.has(e)))}:{top:(null!=(t=null==e?void 0:e.top)?t:[]).filter(e=>!(null!=a&&a.has(e))),bottom:(null!=(r=null==e?void 0:e.bottom)?r:[]).filter(e=>!(null!=a&&a.has(e)))}})},e.getCanPin=()=>{var n;let{enableRowPinning:r,enablePinning:o}=t.options;return"function"==typeof r?r(e):null==(n=null!=r?r:o)||n},e.getIsPinned=()=>{let n=[e.id],{top:r,bottom:o}=t.getState().rowPinning,i=n.some(e=>null==r?void 0:r.includes(e)),a=n.some(e=>null==o?void 0:o.includes(e));return i?"top":!!a&&"bottom"},e.getPinnedIndex=()=>{var n,r;let o=e.getIsPinned();if(!o)return -1;let i=null==(n="top"===o?t.getTopRows():t.getBottomRows())?void 0:n.map(e=>{let{id:t}=e;return t});return null!=(r=null==i?void 0:i.indexOf(e.id))?r:-1}},createTable:e=>{e.setRowPinning=t=>null==e.options.onRowPinningChange?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,r;return e.setRowPinning(t?nO():null!=(n=null==(r=e.initialState)?void 0:r.rowPinning)?n:nO())},e.getIsSomeRowsPinned=t=>{var n,r,o;let i=e.getState().rowPinning;return t?!!(null==(n=i[t])?void 0:n.length):!!((null==(r=i.top)?void 0:r.length)||(null==(o=i.bottom)?void 0:o.length))},e._getPinnedRows=(t,n,r)=>{var o;return(null==(o=e.options.keepPinnedRows)||o?(null!=n?n:[]).map(t=>{let n=e.getRow(t,!0);return n.getIsAllParentsExpanded()?n:null}):(null!=n?n:[]).map(e=>t.find(t=>t.id===e))).filter(Boolean).map(e=>({...e,position:r}))},e.getTopRows=ni(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,"top"),na(e.options,"debugRows","getTopRows")),e.getBottomRows=ni(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,"bottom"),na(e.options,"debugRows","getBottomRows")),e.getCenterRows=ni(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(e,t,n)=>{let r=new Set([...null!=t?t:[],...null!=n?n:[]]);return e.filter(e=>!r.has(e.id))},na(e.options,"debugRows","getCenterRows"))}},{getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:nr("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>null==e.options.onRowSelectionChange?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:null!=(n=e.initialState.rowSelection)?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=void 0!==t?t:!e.getIsAllRowsSelected();let r={...n},o=e.getPreGroupedRowModel().flatRows;return t?o.forEach(e=>{e.getCanSelect()&&(r[e.id]=!0)}):o.forEach(e=>{delete r[e.id]}),r})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{let r=void 0!==t?t:!e.getIsAllPageRowsSelected(),o={...n};return e.getRowModel().rows.forEach(t=>{nj(o,t.id,r,!0,e)}),o}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=ni(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?nR(e,n):{rows:[],flatRows:[],rowsById:{}},na(e.options,"debugTable","getSelectedRowModel")),e.getFilteredSelectedRowModel=ni(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?nR(e,n):{rows:[],flatRows:[],rowsById:{}},na(e.options,"debugTable","getFilteredSelectedRowModel")),e.getGroupedSelectedRowModel=ni(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?nR(e,n):{rows:[],flatRows:[],rowsById:{}},na(e.options,"debugTable","getGroupedSelectedRowModel")),e.getIsAllRowsSelected=()=>{let t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState(),r=!!(t.length&&Object.keys(n).length);return r&&t.some(e=>e.getCanSelect()&&!n[e.id])&&(r=!1),r},e.getIsAllPageRowsSelected=()=>{let t=e.getPaginationRowModel().flatRows.filter(e=>e.getCanSelect()),{rowSelection:n}=e.getState(),r=!!t.length;return r&&t.some(e=>!n[e.id])&&(r=!1),r},e.getIsSomeRowsSelected=()=>{var t;let n=Object.keys(null!=(t=e.getState().rowSelection)?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{let t=e.getPaginationRowModel().flatRows;return!e.getIsAllPageRowsSelected()&&t.filter(e=>e.getCanSelect()).some(e=>e.getIsSelected()||e.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,r)=>{let o=e.getIsSelected();t.setRowSelection(i=>{var a;if(n=void 0!==n?n:!o,e.getCanSelect()&&o===n)return i;let s={...i};return nj(s,e.id,n,null==(a=null==r?void 0:r.selectChildren)||a,t),s})},e.getIsSelected=()=>{let{rowSelection:n}=t.getState();return nN(e,n)},e.getIsSomeSelected=()=>{let{rowSelection:n}=t.getState();return"some"===nA(e,n)},e.getIsAllSubRowsSelected=()=>{let{rowSelection:n}=t.getState();return"all"===nA(e,n)},e.getCanSelect=()=>{var n;return"function"==typeof t.options.enableRowSelection?t.options.enableRowSelection(e):null==(n=t.options.enableRowSelection)||n},e.getCanSelectSubRows=()=>{var n;return"function"==typeof t.options.enableSubRowSelection?t.options.enableSubRowSelection(e):null==(n=t.options.enableSubRowSelection)||n},e.getCanMultiSelect=()=>{var n;return"function"==typeof t.options.enableMultiRowSelection?t.options.enableMultiRowSelection(e):null==(n=t.options.enableMultiRowSelection)||n},e.getToggleSelectedHandler=()=>{let t=e.getCanSelect();return n=>{var r;t&&e.toggleSelected(null==(r=n.target)?void 0:r.checked)}}}},{getDefaultColumnDef:()=>nk,getInitialState:e=>({columnSizing:{},columnSizingInfo:nE(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:nr("columnSizing",e),onColumnSizingInfoChange:nr("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,r,o;let i=t.getState().columnSizing[e.id];return Math.min(Math.max(null!=(n=e.columnDef.minSize)?n:nk.minSize,null!=(r=null!=i?i:e.columnDef.size)?r:nk.size),null!=(o=e.columnDef.maxSize)?o:nk.maxSize)},e.getStart=ni(e=>[e,nP(t,e),t.getState().columnSizing],(t,n)=>n.slice(0,e.getIndex(t)).reduce((e,t)=>e+t.getSize(),0),na(t.options,"debugColumns","getStart")),e.getAfter=ni(e=>[e,nP(t,e),t.getState().columnSizing],(t,n)=>n.slice(e.getIndex(t)+1).reduce((e,t)=>e+t.getSize(),0),na(t.options,"debugColumns","getAfter")),e.resetSize=()=>{t.setColumnSizing(t=>{let{[e.id]:n,...r}=t;return r})},e.getCanResize=()=>{var n,r;return(null==(n=e.columnDef.enableResizing)||n)&&(null==(r=t.options.enableColumnResizing)||r)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let t=0,n=e=>{if(e.subHeaders.length)e.subHeaders.forEach(n);else{var r;t+=null!=(r=e.column.getSize())?r:0}};return n(e),t},e.getStart=()=>{if(e.index>0){let t=e.headerGroup.headers[e.index-1];return t.getStart()+t.getSize()}return 0},e.getResizeHandler=n=>{let r=t.getColumn(e.column.id),o=null==r?void 0:r.getCanResize();return i=>{if(!r||!o||(null==i.persist||i.persist(),nT(i)&&i.touches&&i.touches.length>1))return;let a=e.getSize(),s=e?e.getLeafHeaders().map(e=>[e.column.id,e.column.getSize()]):[[r.id,r.getSize()]],l=nT(i)?Math.round(i.touches[0].clientX):i.clientX,u={},c=(e,n)=>{"number"==typeof n&&(t.setColumnSizingInfo(e=>{var r,o;let i="rtl"===t.options.columnResizeDirection?-1:1,a=(n-(null!=(r=null==e?void 0:e.startOffset)?r:0))*i,s=Math.max(a/(null!=(o=null==e?void 0:e.startSize)?o:0),-.999999);return e.columnSizingStart.forEach(e=>{let[t,n]=e;u[t]=Math.round(100*Math.max(n+n*s,0))/100}),{...e,deltaOffset:a,deltaPercentage:s}}),("onChange"===t.options.columnResizeMode||"end"===e)&&t.setColumnSizing(e=>({...e,...u})))},d=e=>c("move",e),p=e=>{c("end",e),t.setColumnSizingInfo(e=>({...e,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},f=n||"undefined"!=typeof document?document:null,h={moveHandler:e=>d(e.clientX),upHandler:e=>{null==f||f.removeEventListener("mousemove",h.moveHandler),null==f||f.removeEventListener("mouseup",h.upHandler),p(e.clientX)}},m={moveHandler:e=>(e.cancelable&&(e.preventDefault(),e.stopPropagation()),d(e.touches[0].clientX),!1),upHandler:e=>{var t;null==f||f.removeEventListener("touchmove",m.moveHandler),null==f||f.removeEventListener("touchend",m.upHandler),e.cancelable&&(e.preventDefault(),e.stopPropagation()),p(null==(t=e.touches[0])?void 0:t.clientX)}},g=!!function(){if("boolean"==typeof nD)return nD;let e=!1;try{let t=()=>{};window.addEventListener("test",t,{get passive(){return e=!0,!1}}),window.removeEventListener("test",t)}catch(t){e=!1}return nD=e}()&&{passive:!1};nT(i)?(null==f||f.addEventListener("touchmove",m.moveHandler,g),null==f||f.addEventListener("touchend",m.upHandler,g)):(null==f||f.addEventListener("mousemove",h.moveHandler,g),null==f||f.addEventListener("mouseup",h.upHandler,g)),t.setColumnSizingInfo(e=>({...e,startOffset:l,startSize:a,deltaOffset:0,deltaPercentage:0,columnSizingStart:s,isResizingColumn:r.id}))}}},createTable:e=>{e.setColumnSizing=t=>null==e.options.onColumnSizingChange?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>null==e.options.onColumnSizingInfoChange?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:null!=(n=e.initialState.columnSizing)?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?nE():null!=(n=e.initialState.columnSizingInfo)?n:nE())},e.getTotalSize=()=>{var t,n;return null!=(t=null==(n=e.getHeaderGroups()[0])?void 0:n.headers.reduce((e,t)=>e+t.getSize(),0))?t:0},e.getLeftTotalSize=()=>{var t,n;return null!=(t=null==(n=e.getLeftHeaderGroups()[0])?void 0:n.headers.reduce((e,t)=>e+t.getSize(),0))?t:0},e.getCenterTotalSize=()=>{var t,n;return null!=(t=null==(n=e.getCenterHeaderGroups()[0])?void 0:n.headers.reduce((e,t)=>e+t.getSize(),0))?t:0},e.getRightTotalSize=()=>{var t,n;return null!=(t=null==(n=e.getRightHeaderGroups()[0])?void 0:n.headers.reduce((e,t)=>e+t.getSize(),0))?t:0}}}];var nB=n(14968);let nz=(0,d.forwardRef)(function(e,t){return(0,c.jsx)(nB.Z,{...e,ref:t,sx:{backgroundColor:e=>e.palette.background.default,"&:hover":{backgroundColor:e=>(0,m.Fq)(e.palette.primary.main,e.palette.action.hoverOpacity)}}})});var nH=n(56174);let nW=(0,d.forwardRef)(function(e,t){return(0,c.jsx)(nH.Z,{...e,ref:t})});var nG=n(90190);let nU=(0,y.ZP)(nG.Z)(({theme:e})=>({tableLayout:"fixed",borderCollapse:"separate",backgroundColor:e.palette.background.default})),nq={compact:"small",standard:"medium",comfortable:"medium"},nY=(0,d.forwardRef)(function({density:e,...t},n){return(0,c.jsx)(nU,{...t,tabIndex:-1,size:nq[e],ref:n,sx:{width:"100%"}})});var nX=n(31889);let nK=(0,d.forwardRef)(function(e,t){return(0,c.jsx)(nX.Z,{...e,ref:t})});var nQ=n(52054),nJ=n(90247);let n0=(0,nJ.Z)((0,c.jsx)("path",{d:"M20 12l-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8 8-8z"}),"ArrowDownward");function n1(e){return(0,S.ZP)("MuiTableSortLabel",e)}let n2=(0,C.Z)("MuiTableSortLabel",["root","active","icon","iconDirectionDesc","iconDirectionAsc","directionDesc","directionAsc"]);var n5=n(16351);let n3=e=>{let{classes:t,direction:n,active:r}=e,o={root:["root",r&&"active",`direction${(0,v.Z)(n)}`],icon:["icon",`iconDirection${(0,v.Z)(n)}`]};return(0,h.Z)(o,n1,t)},n4=(0,y.ZP)(tX.Z,{name:"MuiTableSortLabel",slot:"Root",overridesResolver:(e,t)=>{let{ownerState:n}=e;return[t.root,n.active&&t.active]}})((0,b.Z)(({theme:e})=>({cursor:"pointer",display:"inline-flex",justifyContent:"flex-start",flexDirection:"inherit",alignItems:"center","&:focus":{color:(e.vars||e).palette.text.secondary},"&:hover":{color:(e.vars||e).palette.text.secondary,[`& .${n2.icon}`]:{opacity:.5}},[`&.${n2.active}`]:{color:(e.vars||e).palette.text.primary,[`& .${n2.icon}`]:{opacity:1,color:(e.vars||e).palette.text.secondary}}}))),n6=(0,y.ZP)("span",{name:"MuiTableSortLabel",slot:"Icon",overridesResolver:(e,t)=>{let{ownerState:n}=e;return[t.icon,t[`iconDirection${(0,v.Z)(n.direction)}`]]}})((0,b.Z)(({theme:e})=>({fontSize:18,marginRight:4,marginLeft:4,opacity:0,transition:e.transitions.create(["opacity","transform"],{duration:e.transitions.duration.shorter}),userSelect:"none",variants:[{props:{direction:"desc"},style:{transform:"rotate(0deg)"}},{props:{direction:"asc"},style:{transform:"rotate(180deg)"}}]}))),n8=d.forwardRef(function(e,t){let n=(0,w.i)({props:e,name:"MuiTableSortLabel"}),{active:r=!1,children:o,className:i,direction:a="asc",hideSortIcon:s=!1,IconComponent:l=n0,slots:u={},slotProps:d={},...p}=n,h={...n,active:r,direction:a,hideSortIcon:s,IconComponent:l},m=n3(h),g={slots:u,slotProps:d},[v,y]=(0,n5.Z)("root",{elementType:n4,externalForwardedProps:g,ownerState:h,className:(0,f.Z)(m.root,i),ref:t}),[b,x]=(0,n5.Z)("icon",{elementType:n6,externalForwardedProps:g,ownerState:h,className:m.icon});return(0,c.jsxs)(v,{disableRipple:!0,component:"span",...y,...p,children:[o,s&&!r?null:(0,c.jsx)(b,{as:l,...x})]})});var n9=n(96205);let n7=150,re=40;function rt(e,t,{isHeader:n,isLastColumn:r,isFirstColumn:o,defaultColumnHeight:i}={}){var a,s;let l=e.spacing(1),u=e.spacing(1.25),c=e.spacing(2),d=o?c:u,p=r?c:u,f=e.typography.body1.lineHeight,h=e.typography.body1.fontSize;"compact"===t&&(l=e.spacing(.5),u=e.spacing(.5),c=e.spacing(1),d=o?c:u,p=r?c:u,f=e.typography.body2.lineHeight,h=e.typography.body2.fontSize),"comfortable"===t&&(l=e.spacing(2),u=e.spacing(1.5),c=e.spacing(2),d=o?c:u,p=r?c:u,f=e.typography.body1.lineHeight,h=e.typography.body1.fontSize);let m=n||!i||"auto"===i?(a=f,s=l,("string"==typeof a?parseInt(a,10):a??0)+2*("string"==typeof s?parseInt(s,10):s)):i;return{padding:`${l} ${p} ${l} ${d}`,height:m,fontSize:h,lineHeight:f}}function rn(e){return e.map(({width:e,align:t,headerDescription:n,cellDescription:r,enableSorting:o,...i})=>({...i,..."auto"===e||void 0===e?{size:0,minSize:0,maxSize:0}:{size:e},enableSorting:!!o,meta:{align:t,headerDescription:n,cellDescription:r}}))}let rr=(0,y.ZP)(n9.Z)(({theme:e})=>({padding:0,backgroundColor:"inherit","&.MuiTableCell-head":{backgroundColor:e.palette.background.default},"&:focus-visible":{outline:`solid 1px ${e.palette.primary.main}`,outlineOffset:"-1px",borderRadius:0}}));function ro({children:e,density:t,variant:n,width:r,defaultColumnHeight:o,focusState:i="none",onFocusTrigger:a,isFirstColumn:s,isLastColumn:l,description:u,align:p,color:f,backgroundColor:h,...m}){let g=(0,tW.Z)(),v=(0,d.useRef)(),y="head"===n;(0,d.useEffect)(()=>{"trigger-focus"===i&&v.current&&v.current.focus()},[i]);let b=e=>{a?.(e)};return(0,c.jsx)(rr,{...m,tabIndex:"none"!==i?0:-1,onFocus:e=>{let t=e.currentTarget?.querySelector('a[href], button, input, textarea, select, details,[role="button"]');t&&t.focus()},onClick:b,onKeyUp:b,style:{width:r},sx:{position:"relative",borderBottom:y?`solid 1px ${g.palette.grey[100]}`:`solid 1px ${g.palette.grey[50]}`,"&:hover #original-cell":{position:"absolute",top:0,left:0,zIndex:10,width:"fit-content",minWidth:"100%",whiteSpace:"nowrap",overflow:"visible",backgroundColor:`${h??g.palette.background.default} !important`,outline:`solid 1px ${g.palette.info.main}`,outlineOffset:"-1px"}},ref:v,children:(0,c.jsx)(eV.Z,{id:"original-cell",sx:{...rt(g,t,{isHeader:y,isLastColumn:l,isFirstColumn:s,defaultColumnHeight:o}),position:"relative",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",flexDirection:"inherit"},style:{backgroundColor:h??"inherit",color:f??"inherit"},title:u,"aria-label":u,textAlign:p,children:e})})}function ri({onSort:e,sortDirection:t,nextSortDirection:n,children:r,...o}){let i=!!e,a=(0,c.jsx)(nQ.Z,{noWrap:!0,variant:"inherit",component:"div",color:"inherit",children:r}),s=!!t;return(0,c.jsx)(ro,{...o,children:i?(0,c.jsx)(n8,{onClick:e,direction:s?t:n,active:s,sx:{verticalAlign:"unset",maxWidth:"100%","&:focus-visible":{[`& .${n2.icon}`]:{opacity:s?1:.5}}},children:a}):a})}var ra=n(59019);let rs=(0,d.forwardRef)(function(e,t){return(0,c.jsx)(ra.Z,{...e,tabIndex:-1,ref:t})}),rl={row:0,column:0},ru=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"];function rc({width:e,height:t,density:n,defaultColumnWidth:r,defaultColumnHeight:o,onRowClick:i,onRowMouseOver:a,onRowMouseOut:s,rows:l,columns:u,headers:p,cellConfigs:f}){let h=(0,d.useRef)(null),m=(0,d.useRef)({startIndex:0,endIndex:0}),g=function({visibleRange:e,virtualTable:t,maxRows:n,maxColumns:r}){return function({maxRows:e,maxColumns:t,onActiveCellChange:n}){let[r,o]=(0,d.useState)(rl),[i,a]=(0,d.useState)(!1);return{activeCell:r,isActive:i,onTableKeyDown:(0,d.useCallback)(r=>{let i=r.key;(ru.includes(i)||"Home"===i||"End"===i||"PageDown"===i||"PageUp"===i)&&o(o=>{let a=o.row,s=o.column;"ArrowRight"===i&&s<t-1?(r.preventDefault(),s+=1):"ArrowLeft"===i&&s>0?(r.preventDefault(),s-=1):"ArrowDown"===i&&a<e-1?(r.preventDefault(),a+=1):"ArrowUp"===i&&a>0?(r.preventDefault(),a-=1):"Home"===i?(r.preventDefault(),a=0,s=0):"End"===i&&(r.preventDefault(),a=e-1,s=t-1);let l={column:s,row:a},u=n?.(r,o,l)||l;return u.row===o.row&&u.column===o.column?o:u})},[t,e,n]),onCellFocus:e=>{(e.column!==r.column||e.row!==r.row||!i)&&(a(!0),o(e))}}}({maxRows:n,maxColumns:r,onActiveCellChange:(r,o,i)=>{let a=r.key,s=i&&(o.column!==i.column||o.row!==i.row),l=i?.row??o.row;if("ArrowDown"===a&&s)(l-1<e.current.startIndex||l-1>e.current.endIndex)&&t.current?.scrollToIndex({index:l-1,align:"end"});else if("ArrowUp"===a&&s)(l-1<e.current.startIndex||l-1>e.current.endIndex)&&t.current?.scrollToIndex({index:l-1,align:"start"});else if(s&&("Home"===a||"End"===a))t.current?.scrollToIndex({index:Math.max(l-1,0),align:"start"});else if("PageDown"===a){r.preventDefault();let i=o.row;return i=Math.min(n-1,e.current.endIndex+1),t.current?.scrollToIndex({index:i-1,align:"start"}),{row:i,column:o.column}}else if("PageUp"===a){let n=o.row;return n=Math.max(0,e.current.startIndex-1),t.current?.scrollToIndex({index:n-1,align:"end"}),{row:n,column:o.column}}return i}})}({visibleRange:m,virtualTable:h,maxRows:l.length+1,maxColumns:u.length}),v=e=>e.row===g.activeCell.row&&e.column===g.activeCell.column?g.isActive?"trigger-focus":"focus-next":"none",y=(0,d.useMemo)(()=>({Scroller:rs,Table:t=>(0,c.jsx)(nY,{...t,width:e,density:n,onKeyDown:g.onTableKeyDown}),TableHead:nK,TableRow:({item:e,...t})=>{let r=l[t["data-index"]];if(!r)return null;let o={id:r.id,index:r.index};return(0,c.jsx)(nz,{...t,onClick:e=>i(e,r.id),density:n,onMouseOver:e=>{a?.(e,o)},onMouseOut:e=>{s?.(e,o)}})},TableBody:nW}),[n,g.onTableKeyDown,i,s,a,l,e]);return(0,c.jsx)(eV.Z,{style:{width:e,height:t},children:(0,c.jsx)(tq._n,{ref:h,totalCount:l.length,components:y,rangeChanged:e=>{m.current=e},fixedHeaderContent:()=>(0,c.jsx)(c.Fragment,{children:p.map(e=>(0,c.jsx)(nz,{density:n,children:e.headers.map((e,t,i)=>{var a,s,l,u,p;let f=e.column,h={row:0,column:t},m=f.getIsSorted(),y=f.getNextSortingOrder();return(0,c.jsx)(ri,{onSort:f.getCanSort()?f.getToggleSortingHandler():void 0,sortDirection:"string"==typeof m?m:void 0,nextSortDirection:"string"==typeof y?y:void 0,width:f.getSize()||r,defaultColumnHeight:o,align:f.columnDef.meta?.align,variant:"head",density:n,description:f.columnDef.meta?.headerDescription,focusState:v(h),onFocusTrigger:()=>g.onCellFocus(h),isFirstColumn:0===t,isLastColumn:t===i.length-1,children:(a=f.columnDef.header,s=e.getContext(),a?"function"==typeof(u=l=a)&&(()=>{let e=Object.getPrototypeOf(u);return e.prototype&&e.prototype.isReactComponent})()||"function"==typeof l||"object"==typeof(p=l)&&"symbol"==typeof p.$$typeof&&["react.memo","react.forward_ref"].includes(p.$$typeof.description)?d.createElement(a,s):a:null)},e.id)})},e.id))}),itemContent:e=>{let t=l[e];return t?(0,c.jsx)(c.Fragment,{children:t.getVisibleCells().map((t,i,a)=>{let s;let l={row:e+1,column:i},u=t.getContext(),d=f?.[u.cell.id],p=t.column.columnDef.cell,h="function"==typeof p?p(u):null,m=t.column.columnDef.meta?.cellDescription;return"function"==typeof m?s=m(u):m&&"string"==typeof h&&(s=h),(0,c.jsx)(ro,{"data-testid":t.id,title:s||d?.text||h,width:t.column.getSize()||r,defaultColumnHeight:o,align:t.column.columnDef.meta?.align,density:n,focusState:v(l),onFocusTrigger:()=>g.onCellFocus(l),isFirstColumn:0===i,isLastColumn:i===a.length-1,description:s,color:d?.textColor??void 0,backgroundColor:d?.backgroundColor??void 0,children:d?.text||h},t.id)})}):null}})})}var rd=n(82707);function rp({color:e,density:t,...n}){let r="compact"===t;return(0,c.jsx)(rd.Z,{size:r?"small":"medium",...n,focusRipple:!1,tabIndex:-1,sx:{color:e,padding:e=>e.spacing(r?.25:.5),position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)","&.Mui-checked":{color:e},"&.Mui-focusVisible":{background:e?(0,m.Fq)(e,.5):void 0},"& .MuiSvgIcon-root":{fontSize:r?16:18}}})}let rf=(e,t)=>`${t}`,rh={},rm=[];function rg({data:e,columns:t,cellConfigs:n,density:r="standard",defaultColumnWidth:o=n7,defaultColumnHeight:i="auto",checkboxSelection:a,onRowSelectionChange:s,onSortingChange:l,getCheckboxColor:u,getRowId:p=rf,rowSelection:f=rh,sorting:h=rm,rowSelectionVariant:m="standard",...g}){let v=(0,tW.Z)(),y=(0,d.useCallback)((e,t,n)=>{"standard"===m||n?t.toggleSelected():t.getIsSelected()&&!e.getIsAllRowsSelected()?e.toggleAllRowsSelected():s?.({[t.id]:!0})},[s,m]),b=(0,d.useCallback)((e,t,n)=>{let r=e.nativeEvent&&(e.nativeEvent instanceof MouseEvent||e.nativeEvent instanceof KeyboardEvent)?e.nativeEvent:void 0;y(t,n,!!r?.metaKey||!!r?.shiftKey)},[y]),x=(0,d.useMemo)(()=>({id:"checkboxRowSelect",size:28,header:({table:e})=>(0,c.jsx)(rp,{checked:e.getIsAllRowsSelected(),indeterminate:e.getIsSomeRowsSelected(),onChange:e.getToggleAllRowsSelectedHandler(),color:v.palette.text.primary,density:r}),cell:({row:e,table:t})=>(0,c.jsx)(rp,{checked:e.getIsSelected(),indeterminate:e.getIsSomeSelected(),onChange:n=>{b(n,t,e)},color:u?.(e.original),density:r}),enableSorting:!1}),[v.palette.text.primary,r,u,b]),w=function(e){let t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=d.useState(()=>({current:function(e){var t,n;let r=[...n$,...null!=(t=e._features)?t:[]],o={_features:r},i=o._features.reduce((e,t)=>Object.assign(e,null==t.getDefaultOptions?void 0:t.getDefaultOptions(o)),{}),a=e=>o.options.mergeOptions?o.options.mergeOptions(i,e):{...i,...e},s={...null!=(n=e.initialState)?n:{}};o._features.forEach(e=>{var t;s=null!=(t=null==e.getInitialState?void 0:e.getInitialState(s))?t:s});let l=[],u=!1,c={_features:r,options:{...i,...e},initialState:s,_queue:e=>{l.push(e),u||(u=!0,Promise.resolve().then(()=>{for(;l.length;)l.shift()();u=!1}).catch(e=>setTimeout(()=>{throw e})))},reset:()=>{o.setState(o.initialState)},setOptions:e=>{let t=nn(e,o.options);o.options=a(t)},getState:()=>o.options.state,setState:e=>{null==o.options.onStateChange||o.options.onStateChange(e)},_getRowId:(e,t,n)=>{var r;return null!=(r=null==o.options.getRowId?void 0:o.options.getRowId(e,t,n))?r:`${n?[n.id,t].join("."):t}`},getCoreRowModel:()=>(o._getCoreRowModel||(o._getCoreRowModel=o.options.getCoreRowModel(o)),o._getCoreRowModel()),getRowModel:()=>o.getPaginationRowModel(),getRow:(e,t)=>{let n=(t?o.getPrePaginationRowModel():o.getRowModel()).rowsById[e];if(!n&&!(n=o.getCoreRowModel().rowsById[e]))throw Error();return n},_getDefaultColumnDef:ni(()=>[o.options.defaultColumn],e=>{var t;return e=null!=(t=e)?t:{},{header:e=>{let t=e.header.column.columnDef;return t.accessorKey?t.accessorKey:t.accessorFn?t.id:null},cell:e=>{var t,n;return null!=(t=null==(n=e.renderValue())||null==n.toString?void 0:n.toString())?t:null},...o._features.reduce((e,t)=>Object.assign(e,null==t.getDefaultColumnDef?void 0:t.getDefaultColumnDef()),{}),...e}},na(e,"debugColumns","_getDefaultColumnDef")),_getColumnDefs:()=>o.options.columns,getAllColumns:ni(()=>[o._getColumnDefs()],e=>{let t=function(e,n,r){return void 0===r&&(r=0),e.map(e=>{let i=function(e,t,n,r){var o,i;let a;let s={...e._getDefaultColumnDef(),...t},l=s.accessorKey,u=null!=(o=null!=(i=s.id)?i:l?"function"==typeof String.prototype.replaceAll?l.replaceAll(".","_"):l.replace(/\./g,"_"):void 0)?o:"string"==typeof s.header?s.header:void 0;if(s.accessorFn?a=s.accessorFn:l&&(a=l.includes(".")?e=>{let t=e;for(let e of l.split(".")){var n;t=null==(n=t)?void 0:n[e]}return t}:e=>e[s.accessorKey]),!u)throw Error();let c={id:`${String(u)}`,accessorFn:a,parent:r,depth:n,columnDef:s,columns:[],getFlatColumns:ni(()=>[!0],()=>{var e;return[c,...null==(e=c.columns)?void 0:e.flatMap(e=>e.getFlatColumns())]},na(e.options,"debugColumns","column.getFlatColumns")),getLeafColumns:ni(()=>[e._getOrderColumnsFn()],e=>{var t;return null!=(t=c.columns)&&t.length?e(c.columns.flatMap(e=>e.getLeafColumns())):[c]},na(e.options,"debugColumns","column.getLeafColumns"))};for(let t of e._features)null==t.createColumn||t.createColumn(c,e);return c}(o,e,r,n);return i.columns=e.columns?t(e.columns,i,r+1):[],i})};return t(e)},na(e,"debugColumns","getAllColumns")),getAllFlatColumns:ni(()=>[o.getAllColumns()],e=>e.flatMap(e=>e.getFlatColumns()),na(e,"debugColumns","getAllFlatColumns")),_getAllFlatColumnsById:ni(()=>[o.getAllFlatColumns()],e=>e.reduce((e,t)=>(e[t.id]=t,e),{}),na(e,"debugColumns","getAllFlatColumnsById")),getAllLeafColumns:ni(()=>[o.getAllColumns(),o._getOrderColumnsFn()],(e,t)=>t(e.flatMap(e=>e.getLeafColumns())),na(e,"debugColumns","getAllLeafColumns")),getColumn:e=>o._getAllFlatColumnsById()[e]};Object.assign(o,c);for(let e=0;e<o._features.length;e++){let t=o._features[e];null==t||null==t.createTable||t.createTable(o)}return o}(t)})),[r,o]=d.useState(()=>n.current.initialState);return n.current.setOptions(t=>({...t,...e,state:{...r,...e.state},onStateChange:t=>{o(t),null==e.onStateChange||e.onStateChange(t)}})),n.current}({data:e,columns:(0,d.useMemo)(()=>{let e=rn(t);return a&&e.unshift(x),e},[x,a,t]),getRowId:p,getCoreRowModel:e=>ni(()=>[e.options.data],t=>{let n={rows:[],flatRows:[],rowsById:{}},r=function(t,o,i){void 0===o&&(o=0);let a=[];for(let l=0;l<t.length;l++){let u=nc(e,e._getRowId(t[l],l,i),t[l],l,o,void 0,null==i?void 0:i.id);if(n.flatRows.push(u),n.rowsById[u.id]=u,a.push(u),e.options.getSubRows){var s;u.originalSubRows=e.options.getSubRows(t[l],l),null!=(s=u.originalSubRows)&&s.length&&(u.subRows=r(u.originalSubRows,o+1,u))}}return a};return n.rows=r(t),n},na(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex())),getSortedRowModel:e=>ni(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,n)=>{if(!n.rows.length||!(null!=t&&t.length))return n;let r=e.getState().sorting,o=[],i=r.filter(t=>{var n;return null==(n=e.getColumn(t.id))?void 0:n.getCanSort()}),a={};i.forEach(t=>{let n=e.getColumn(t.id);n&&(a[t.id]={sortUndefined:n.columnDef.sortUndefined,invertSorting:n.columnDef.invertSorting,sortingFn:n.getSortingFn()})});let s=e=>{let t=e.map(e=>({...e}));return t.sort((e,t)=>{for(let r=0;r<i.length;r+=1){var n;let o=i[r],s=a[o.id],l=s.sortUndefined,u=null!=(n=null==o?void 0:o.desc)&&n,c=0;if(l){let n=e.getValue(o.id),r=t.getValue(o.id),i=void 0===n,a=void 0===r;if(i||a){if("first"===l)return i?-1:1;if("last"===l)return i?1:-1;c=i&&a?0:i?l:-l}}if(0===c&&(c=s.sortingFn(e,t,o.id)),0!==c)return u&&(c*=-1),s.invertSorting&&(c*=-1),c}return e.index-t.index}),t.forEach(e=>{var t;o.push(e),null!=(t=e.subRows)&&t.length&&(e.subRows=s(e.subRows))}),t};return{rows:s(n.rows),flatRows:o,rowsById:n.rowsById}},na(e.options,"debugTable","getSortedRowModel",()=>e._autoResetPageIndex())),enableRowSelection:!!a,onRowSelectionChange:e=>{let t="function"==typeof e?e(f):e;s?.(t)},onSortingChange:e=>{let t="function"==typeof e?e(h):e;l?.(t)},sortDescFirst:!0,state:{rowSelection:f,sorting:h}}),C=(0,d.useCallback)((e,t)=>{let n=w.getRow(t);y(w,n,e.metaKey||e.shiftKey)},[y,w]);return(0,c.jsx)(rc,{...g,density:r,defaultColumnWidth:o,defaultColumnHeight:i,onRowClick:C,rows:w.getRowModel().rows,columns:w.getAllFlatColumns(),headers:w.getHeaderGroups(),cellConfigs:n})}let rv=[{accessorKey:"label",header:"Name",enableSorting:!0,cell:({getValue:e})=>(0,c.jsx)("span",{title:e(),children:e()})}],ry=e=>e.id,rb=e=>e.color;function rx({items:e,selectedItems:t,onSelectedItemsChange:n,onItemMouseOver:r,onItemMouseOut:o,height:i,width:a,columns:s=[],sorting:l,onSortingChange:u}){let p=(0,d.useMemo)(()=>"string"!=typeof t?t:e.reduce((e,t,n)=>(e[ry(t,n)]=!0,e),{}),[t,e]),f=(0,d.useMemo)(()=>[...rv,...s],[s]);return(0,c.jsx)(rg,{height:i,width:a,rowSelection:p,onRowSelectionChange:n,onRowMouseOver:r,onRowMouseOut:o,sorting:l,onSortingChange:u,data:e,columns:f,density:"compact",defaultColumnWidth:"auto",getRowId:ry,getCheckboxColor:rb,checkboxSelection:!0,rowSelectionVariant:"legend"})}function rw({width:e,height:t,options:n,data:r,selectedItems:o,onSelectedItemsChange:i,onItemMouseOver:a,onItemMouseOut:s,tableProps:l}){let u;let d=(e,t)=>{let n=e.metaKey||e.shiftKey;i((0,tU.Uy)(o,e=>{if("ALL"===e)return{[t]:!0};let r=!!e[t];return n?(r?delete e[t]:e[t]=!0,e):r?"ALL":{[t]:!0}}))},p=(0,tG.bk)(n.mode),f=r.length>=500,h={height:t,items:r,selectedItems:o,onLegendItemClick:d,onItemMouseOver:a,onItemMouseOut:s};return(u="table"===p?(0,c.jsx)(rx,{...h,onSelectedItemsChange:i,width:e,...l}):"right"===n.position||f?(0,c.jsx)(ne,{...h,width:e,onLegendItemClick:d}):(0,c.jsx)(nt,{...h,onLegendItemClick:d}),"right"===n.position)?(0,c.jsx)(eV.Z,{style:{width:e,height:t},sx:{position:"absolute",top:0,right:0},children:u}):(0,c.jsx)(eV.Z,{style:{width:e,height:t},sx:{position:"absolute",bottom:0},children:u})}let rC={medium:{bottom:6,right:250},small:{bottom:4,right:150}};function rS({children:e,legendProps:t,width:n,height:r,spacing:o=0,legendSize:i,minChildrenWidth:a=100,minChildrenHeight:s=100}){let{content:l,legend:u,margin:d}=function({width:e,height:t,legendProps:n,legendSize:r,minChildrenHeight:o,minChildrenWidth:i,spacing:a,theme:s}){let l,u;let c=n?.options,d={legend:{show:!1,width:0,height:0},content:{width:e,height:t},margin:{right:0,bottom:0}};if(!c)return d;let{position:p}=c;if("list"===(0,tG.bk)(c.mode))l="right"===p?200:e,u=40,"right"===p?u=t:t>=300&&(u=100);else{let o=rt(s,"compact"),i=(n?.tableProps?.columns||[]).reduce((e,t)=>("number"==typeof t.width&&(e+=t.width),e),0);l="right"===p?rC[r].right+i:e;let a=Math.min(rC[r].bottom,n.data.length+1);u="bottom"===p?a*o.height:t}let f="right"===p?e-l-a:e,h="bottom"===p?t-u-a:t;return"right"===p&&f<i||"bottom"===p&&h<o?d:{legend:{width:l,height:u,show:!0},content:{width:f,height:h},margin:{right:"right"===p?a:0,bottom:"bottom"===p?a:0}}}({width:n,height:r,legendProps:t,minChildrenHeight:s,minChildrenWidth:a,spacing:o,theme:(0,tW.Z)(),legendSize:(0,tG.dT)(i)});return(0,c.jsxs)(eV.Z,{style:{width:n,height:r},sx:{position:"relative",overflow:"hidden"},children:[(0,c.jsx)(eV.Z,{style:{width:l.width,height:l.height},sx:{marginRight:`${d.right}px`,marginBottom:`${d.bottom}px`,overflow:"hidden"},children:"function"==typeof e?e({width:l.width,height:l.height}):e}),t&&u.show&&(0,c.jsx)(rw,{...t,height:u.height,width:u.width})]})}let rM=(0,d.forwardRef)(function({debounceMs:e=250,value:t,onChange:n,...r},o){let[i,a]=(0,d.useState)(t),s=(0,d.useCallback)(e=>{n?.(e)},[n]),l=(0,d.useMemo)(()=>eY()(s,e),[e,s]);return(0,c.jsx)(e7.Z,{ref:o,value:i,onChange:function(e){a(e.target.value),l(e.target.value)},...r})});rM.displayName="TextField";var rk=n(51602),rE=n(19978),rD=n(56873),rT=n(70616),rP=n(10763);let rZ=(0,y.ZP)("form")({overflowY:"auto",display:"flex",flexDirection:"column"}),rO=e=>({position:"absolute",top:e.spacing(.5),right:e.spacing(.5)}),rj=({children:e,...t})=>(0,c.jsx)(rD.Z,{...t,children:e});rj.Header=({children:e,onClose:t,...n})=>(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(rk.Z,{style:{textOverflow:"ellipsis",overflow:"hidden"},...n,children:e}),t&&(0,c.jsx)(e9.Z,{"aria-label":"Close",onClick:t,sx:rO,children:(0,c.jsx)(rP.default,{})})]}),rj.Form=rZ,rj.Content=({children:e,sx:t,...n})=>(0,c.jsx)(rE.Z,{dividers:!0,...n,sx:t4({minWidth:"500px",textWrap:"balance"},t),children:e}),rj.PrimaryButton=({children:e,...t})=>(0,c.jsx)(O.Z,{variant:"contained",type:"submit",...t,children:e}),rj.SecondaryButton=({children:e,...t})=>(0,c.jsx)(O.Z,{variant:"outlined",color:"secondary",...t,children:e}),rj.Actions=rT.Z;let rR=e=>{let{description:t,isOpen:n,onCancel:r,onDiscardChanges:o}=e;return(0,c.jsxs)(rj,{open:n,"aria-labelledby":"discard-dialog",children:[(0,c.jsx)(rj.Header,{children:"Discard Changes"}),(0,c.jsx)(rj.Content,{children:t}),(0,c.jsxs)(rj.Actions,{children:[(0,c.jsx)(O.Z,{variant:"contained",onClick:o,children:"Discard Changes"}),(0,c.jsx)(O.Z,{variant:"outlined",color:"secondary",onClick:r,children:"Cancel"})]})]})};var rN=n(90192),rA=n(23626),rF=n(39398);function rI(e){void 0===globalThis.useIdValue&&(globalThis.useIdValue=0);let t=(0,d.useRef)(void 0);return void 0===t.current&&(t.current=`${e}-${globalThis.useIdValue++}`),t.current}var r_=n(32964),rL=n(87143);let rV=({id:e,title:t,description:n,placement:r,children:o,enterDelay:i,enterNextDelay:a})=>{let s=(0,c.jsx)("span",{children:o});return(0,c.jsx)(rB,{arrow:!0,id:e,placement:r??"top",title:(0,c.jsx)(r$,{title:t,description:n}),enterDelay:i??500,enterNextDelay:a??500,children:s})},r$=({title:e,description:t})=>(0,c.jsxs)(c.Fragment,{children:[e&&(0,c.jsx)(nQ.Z,{variant:"body2",sx:e=>({color:e.palette.text.primary,fontWeight:e.typography.fontWeightMedium}),children:e}),(0,c.jsx)(nQ.Z,{variant:"caption",sx:e=>({color:e.palette.text.primary,whiteSpace:"pre-line"}),children:t})]}),rB=(0,y.ZP)(({className:e,...t})=>(0,c.jsx)(r_.Z,{...t,classes:{popper:e}}))(({theme:e})=>({[`& .${rL.Z.tooltip}`]:{backgroundColor:e.palette.background.tooltip,color:e.palette.text.primary,maxWidth:"300px",padding:e.spacing(1),boxShadow:e.shadows[1]},[`& .${rL.Z.arrow}`]:{color:e.palette.background.tooltip}})),rz=({label:e,control:t,description:n})=>{let r=rI("EditorSectionControl"),o=`${r}-control`;return(0,c.jsx)(rN.Z,{children:(0,c.jsxs)(e8.Z,{direction:"row",alignItems:"center",justifyContent:"space-between",children:[(0,c.jsxs)(e8.Z,{direction:"row",alignItems:"center",justifyContent:"center",children:[(0,c.jsx)(rA.Z,{htmlFor:o,children:e}),n&&(0,c.jsx)(rV,{description:n,enterDelay:100,children:(0,c.jsx)(e9.Z,{size:"small",sx:e=>({borderRadius:e.shape.borderRadius,padding:"4x",margin:"0 2px"}),children:(0,c.jsx)(rF.default,{"aria-describedby":"info-tooltip","aria-hidden":!1,fontSize:"inherit",sx:{color:e=>e.palette.grey[700]}})})})]}),(0,c.jsxs)(eV.Z,{sx:{width:"180px",textAlign:"right"},children:[" ",p().cloneElement(t,{id:o})]})]})})};var rH=n(11774),rW=n(57174);function rG({options:e,renderInput:t=e=>(0,c.jsx)(e7.Z,{...e}),...n}){let r=e=>e.label??e.id;return(0,c.jsx)(rH.Z,{isOptionEqualToValue:(e,t)=>e.id===t.id,getOptionDisabled:e=>!!e.disabled,getOptionLabel:r,options:e,renderInput:t,renderOption:({key:e,...t},n)=>(0,c.jsx)("li",{...t,children:(0,c.jsxs)("div",{children:[(0,c.jsx)(nQ.Z,{variant:"body1",component:"div",children:r(n)}),n.description&&(0,c.jsx)(nQ.Z,{variant:"body2",component:"div",sx:{color:e=>e.palette.text.secondary},children:n.description})]})},e),filterOptions:(0,rW.D)({stringify:e=>`${r(e)} ${e.description||""}`}),...n})}let rU=[{id:"compact",label:"Compact"},{id:"standard",label:"Standard"},{id:"comfortable",label:"Comfortable"}];function rq({onChange:e,value:t="standard"}){return(0,c.jsx)(rz,{label:"Density",control:(0,c.jsx)(rG,{value:rU.find(e=>e.id===t),options:rU,getOptionLabel:e=>e.label,onChange:(t,{id:n})=>{e(n)},disableClearable:!0})})}function rY(){return(0,c.jsxs)(e8.Z,{direction:"row",alignItems:"center",children:[(0,c.jsx)(eV.Z,{sx:{content:'""',width:8,height:8,boxSizing:"border-box",position:"absolute",backgroundColor:e=>e.palette.background.default,border:e=>`2px solid ${e.palette.info.main}`,borderRadius:"50%"}}),(0,c.jsx)(eV.Z,{sx:{content:'""',height:2,background:e=>e.palette.info.main,width:"100%"}})]})}function rX(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function rK(e,t){if(e){if("string"==typeof e)return rX(e,t);var n=({}).toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?rX(e,t):void 0}}function rQ(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){u=!0,o=e}finally{try{if(!l&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}(e,t)||rK(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var rJ=n(70501),r0="data-pdnd-honey-pot";function r1(e){return e instanceof Element&&e.hasAttribute(r0)}function r2(e){var t=rQ(document.elementsFromPoint(e.x,e.y),2),n=t[0],r=t[1];return n?r1(n)?null!=r?r:null:n:null}function r5(e){return(r5="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function r3(e,t,n){var r;return(r=function(e,t){if("object"!=r5(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=r5(r))return r;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==r5(r)?r:r+"")in e)?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function r6(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r4(Object(n),!0).forEach(function(t){r3(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r4(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function r8(e){var t,n,r,o,i={x:Math.min((o={x:Math.max((r={x:(n={x:Math.floor((t=e.client).x),y:Math.floor(t.y)}).x-1,y:n.y-1}).x,0),y:Math.max(r.y,0)}).x,window.innerWidth-2),y:Math.min(o.y,window.innerHeight-2)};return DOMRect.fromRect({x:i.x,y:i.y,width:2,height:2})}function r9(e){var t=e.clientRect;return{left:"".concat(t.left,"px"),top:"".concat(t.top,"px"),width:"".concat(t.width,"px"),height:"".concat(t.height,"px")}}function r7(e){return function(e){if(Array.isArray(e))return rX(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||rK(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function oe(e){var t=null;return function(){if(!t){for(var n=arguments.length,r=Array(n),o=0;o<n;o++)r[o]=arguments[o];t={result:e.apply(this,r)}}return t.result}}var ot=oe(function(){return navigator.userAgent.includes("Firefox")}),on=oe(function(){var e=navigator.userAgent;return e.includes("AppleWebKit")&&!e.includes("Chrome")}),or={isLeavingWindow:Symbol("leaving"),isEnteringWindow:Symbol("entering")};function oo(e){return{altKey:e.altKey,button:e.button,buttons:e.buttons,ctrlKey:e.ctrlKey,metaKey:e.metaKey,shiftKey:e.shiftKey,clientX:e.clientX,clientY:e.clientY,pageX:e.pageX,pageY:e.pageY}}!function(){if("undefined"!=typeof window){if(on()){var e=t();(0,rJ.bindAll)(window,[{type:"dragstart",listener:function(){e.enterCount=0,e.isOverWindow=!0}},{type:"drop",listener:n},{type:"dragend",listener:n},{type:"dragenter",listener:function(t){e.isOverWindow||0!==e.enterCount||(t[or.isEnteringWindow]=!0),e.isOverWindow=!0,e.enterCount++}},{type:"dragleave",listener:function(t){e.enterCount--,e.isOverWindow&&0===e.enterCount&&(t[or.isLeavingWindow]=!0,e.isOverWindow=!1)}}],{capture:!0})}}function t(){return{enterCount:0,isOverWindow:!1}}function n(){e=t()}}();var oi=(ly=function(e){return e()},lb=[],lx=null,(lw=function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];lb=t,!lx&&(lx=requestAnimationFrame(function(){lx=null,ly.apply(void 0,lb)}))}).cancel=function(){lx&&(cancelAnimationFrame(lx),lx=null)},lw),oa=(lC=null,{schedule:function(e){lC={frameId:requestAnimationFrame(function(){lC=null,e()}),fn:e}},flush:function(){lC&&(cancelAnimationFrame(lC.frameId),lC.fn(),lC=null)}}),os={isActive:!1};function ol(){return!os.isActive}function ou(e){var t,n=e.event,r=null===(t=e.current[0])||void 0===t?void 0:t.dropEffect;null!=r&&n.dataTransfer&&(n.dataTransfer.dropEffect=r)}var oc=function(e){var t,n,r=e.event,o=e.dragType,i=e.getDropTargetsOver,a=e.dispatchEvent;if(ol()){var s=function(e){var t=e.event,n=e.dragType,r=e.getDropTargetsOver,o=oo(t);if("external"===n.startedFrom)return{input:o,dropTargets:[]};var i=r({input:o,source:n.payload,target:t.target,current:[]});return{input:o,dropTargets:i}}({event:r,dragType:o,getDropTargetsOver:i});os.isActive=!0;var l={current:s};ou({event:r,current:s.dropTargets});var u=function(e){var t=e.source,n=e.initial,r=e.dispatchEvent,o={dropTargets:[]};function i(e){r(e),o={dropTargets:e.payload.location.current.dropTargets}}return{start:function(e){var r=e.nativeSetDragImage,a={current:n,previous:o,initial:n};i({eventName:"onGenerateDragPreview",payload:{source:t,location:a,nativeSetDragImage:r}}),oa.schedule(function(){i({eventName:"onDragStart",payload:{source:t,location:a}})})},dragUpdate:function(e){var r=e.current;oa.flush(),oi.cancel(),i({eventName:"onDropTargetChange",payload:{source:t,location:{initial:n,previous:o,current:r}}})},drag:function(e){var r=e.current;oi(function(){oa.flush(),i({eventName:"onDrag",payload:{source:t,location:{initial:n,previous:o,current:r}}})})},drop:function(e){var r=e.current,a=e.updatedSourcePayload;oa.flush(),oi.cancel(),i({eventName:"onDrop",payload:{source:null!=a?a:t,location:{current:r,previous:o,initial:n}}})}}}({source:o.payload,dispatchEvent:a,initial:s}),c=(0,rJ.bindAll)(window,[{type:"dragover",listener:function(e){p(e),u.drag({current:l.current})}},{type:"dragenter",listener:p},{type:"dragleave",listener:function(e){(function(e){var t=e.dragLeave,n=t.type,r=t.relatedTarget;return"dragleave"===n&&(on()?!!on()&&t.hasOwnProperty(or.isLeavingWindow):null==r||(ot()?"nodeName"in r&&r.ownerDocument!==document:r instanceof HTMLIFrameElement))})({dragLeave:e})&&(d({input:l.current.input,dropTargets:[]}),"external"===o.startedFrom&&f())}},{type:"drop",listener:function(e){if(l.current={dropTargets:l.current.dropTargets,input:oo(e)},!l.current.dropTargets.length){f();return}e.preventDefault(),ou({event:e,current:l.current.dropTargets}),u.drop({current:l.current,updatedSourcePayload:"external"===o.type?o.getDropPayload(e):null}),h()}},{type:"dragend",listener:function(e){l.current={dropTargets:l.current.dropTargets,input:oo(e)},f()}}].concat(r7([{type:"pointermove",listener:(n=0,function(){if(n<20){n++;return}t()})},{type:"pointerdown",listener:t=f}])),{capture:!0});u.start({nativeSetDragImage:r.dataTransfer?r.dataTransfer.setDragImage.bind(r.dataTransfer):null})}function d(e){var t=function(e){var t=e.current,n=e.next;if(t.length!==n.length)return!0;for(var r=0;r<t.length;r++)if(t[r].element!==n[r].element)return!0;return!1}({current:l.current.dropTargets,next:e.dropTargets});l.current=e,t&&u.dragUpdate({current:l.current})}function p(e){var t=oo(e),n=i({target:r1(e.target)?r2({x:t.clientX,y:t.clientY}):e.target,input:t,source:o.payload,current:l.current.dropTargets});n.length&&(e.preventDefault(),ou({event:e,current:n})),d({dropTargets:n,input:t})}function f(){l.current.dropTargets.length&&d({dropTargets:[],input:l.current.input}),u.drop({current:l.current,updatedSourcePayload:null}),h()}function h(){os.isActive=!1,c()}},od=new Map;function op(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(){t.forEach(function(e){return e()})}}function of(e,t){var n=t.attribute,r=t.value;return e.setAttribute(n,r),function(){return e.removeAttribute(n)}}function oh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function om(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?oh(Object(n),!0).forEach(function(t){r3(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oh(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function og(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return ov(e,void 0);var n=({}).toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ov(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw i}}}}function ov(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function oy(e){return e.slice(0).reverse()}function ob(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function ox(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}var ow=oe(function(){return navigator.userAgent.toLocaleLowerCase().includes("android")}),oC="text/plain",oS=new WeakMap,oM=(lS=null,{bindEvents:function(){return lS=null,(0,rJ.bind)(window,{type:"pointermove",listener:function(e){lS={x:e.clientX,y:e.clientY}},options:{capture:!0}})},getOnPostDispatch:function(){var e=null;return function(t){var n=t.eventName,r=t.payload;if("onDragStart"===n){var o,i,a,s,l,u=r.location.initial.input;o=({initial:null!==(l=lS)&&void 0!==l?l:{x:u.clientX,y:u.clientY}}).initial,(i=document.createElement("div")).setAttribute(r0,"true"),a=r8({client:o}),Object.assign(i.style,r6(r6({backgroundColor:"transparent",position:"fixed",padding:0,margin:0,boxSizing:"border-box"},r9({clientRect:a})),{},{pointerEvents:"auto",zIndex:0x7fffffff})),document.body.appendChild(i),s=(0,rJ.bind)(window,{type:"pointermove",listener:function(e){a=r8({client:{x:e.clientX,y:e.clientY}}),Object.assign(i.style,r9({clientRect:a}))},options:{capture:!0}}),e=function(e){var t,n,r,o=e.current;if(s(),n=(t={client:o,clientRect:a}).client,r=t.clientRect,n.x>=r.x&&n.x<=r.x+r.width&&n.y>=r.y&&n.y<=r.y+r.height){i.remove();return}function l(){u(),i.remove()}var u=(0,rJ.bindAll)(window,[{type:"pointerdown",listener:l},{type:"pointermove",listener:l},{type:"focusin",listener:l},{type:"focusout",listener:l},{type:"dragstart",listener:l},{type:"dragenter",listener:l},{type:"dragover",listener:l}],{capture:!0})}}if("onDrop"===n){var c,d=r.location.current.input;null===(c=e)||void 0===c||c({current:{x:d.clientX,y:d.clientY}}),e=null,lS=null}}}}),ok=function(e){var t=e.typeKey,n=e.mount,r=e.dispatchEventToSource,o=e.onPostDispatch,i=e.defaultDropEffect,a=function(){var e=new Set,t=null;function n(e){t&&(!e.canMonitor||e.canMonitor(t.canMonitorArgs))&&t.active.add(e)}return{dispatchEvent:function(r){var o=r.eventName,i=r.payload;if("onGenerateDragPreview"===o){t={canMonitorArgs:{initial:i.location.initial,source:i.source},active:new Set};var a,s=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return ob(e,void 0);var n=({}).toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ob(e,t):void 0}}(e))){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw i}}}}(e);try{for(s.s();!(a=s.n()).done;){var l=a.value;n(l)}}catch(e){s.e(e)}finally{s.f()}}if(t){for(var u=Array.from(t.active),c=0;c<u.length;c++){var d,p=u[c];t.active.has(p)&&(null===(d=p[o])||void 0===d||d.call(p,i))}"onDrop"===o&&(t.active.clear(),t=null)}},monitorForConsumers:function(r){var o=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ox(Object(n),!0).forEach(function(t){r3(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ox(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({},r);return e.add(o),n(o),function(){e.delete(o),t&&t.active.delete(o)}}}}(),s=function(e){var t=e.typeKey,n=e.defaultDropEffect,r=new WeakMap,o="data-drop-target-for-".concat(t),i="[".concat(o,"]");function a(e){var t,n=e.eventName,o=e.payload,i=og(o.location.current.dropTargets);try{for(i.s();!(t=i.n()).done;){var a,s=t.value,l=r.get(s.element),u=om(om({},o),{},{self:s});null==l||null===(a=l[n])||void 0===a||a.call(l,u)}}catch(e){i.e(e)}finally{i.f()}}var s={onGenerateDragPreview:a,onDrag:a,onDragStart:a,onDrop:a,onDropTargetChange:function(e){var t,n=e.payload,o=new Set(n.location.current.dropTargets.map(function(e){return e.element})),i=new Set,a=og(n.location.previous.dropTargets);try{for(a.s();!(t=a.n()).done;){var s,l,u=t.value;i.add(u.element);var c=r.get(u.element),d=o.has(u.element),p=om(om({},n),{},{self:u});null==c||null===(s=c.onDropTargetChange)||void 0===s||s.call(c,p),d||null==c||null===(l=c.onDragLeave)||void 0===l||l.call(c,p)}}catch(e){a.e(e)}finally{a.f()}var f,h=og(n.location.current.dropTargets);try{for(h.s();!(f=h.n()).done;){var m,g,v=f.value;if(!i.has(v.element)){var y=om(om({},n),{},{self:v}),b=r.get(v.element);null==b||null===(m=b.onDropTargetChange)||void 0===m||m.call(b,y),null==b||null===(g=b.onDragEnter)||void 0===g||g.call(b,y)}}}catch(e){h.e(e)}finally{h.f()}}};return{dropTargetForConsumers:function(e){return op(of(e.element,{attribute:o,value:"true"}),(r.set(e.element,e),function(){return r.delete(e.element)}))},getIsOver:function(e){var t=e.source,o=e.target,a=e.input,s=e.current,l=function e(t){var o,a,s,l,u=t.source,c=t.target,d=t.input,p=t.result,f=void 0===p?[]:p;if(null==c)return f;if(!(c instanceof Element))return c instanceof Node?e({source:u,target:c.parentElement,input:d,result:f}):f;var h=c.closest(i);if(null==h)return f;var m=r.get(h);if(null==m)return f;var g={input:d,source:u,element:m.element};if(m.canDrop&&!m.canDrop(g))return e({source:u,target:m.element.parentElement,input:d,result:f});var v=null!==(o=null===(a=m.getData)||void 0===a?void 0:a.call(m,g))&&void 0!==o?o:{},y=null!==(s=null===(l=m.getDropEffect)||void 0===l?void 0:l.call(m,g))&&void 0!==s?s:n,b={data:v,element:m.element,dropEffect:y,isActiveDueToStickiness:!1};return e({source:u,target:m.element.parentElement,input:d,result:[].concat(r7(f),[b])})}({source:t,target:o,input:a});if(l.length>=s.length)return l;for(var u=oy(s),c=oy(l),d=[],p=0;p<u.length;p++){var f,h=u[p],m=c[p];if(null!=m){d.push(m);continue}var g=d[p-1],v=u[p-1];if((null==g?void 0:g.element)!==(null==v?void 0:v.element))break;var y=r.get(h.element);if(!y)break;var b={input:a,source:t,element:y.element};if(y.canDrop&&!y.canDrop(b)||!(null!==(f=y.getIsSticky)&&void 0!==f&&f.call(y,b)))break;d.push(om(om({},h),{},{isActiveDueToStickiness:!0}))}return oy(d)},dispatchEvent:function(e){s[e.eventName](e)}}}({typeKey:t,defaultDropEffect:i});function l(e){null==r||r(e),s.dispatchEvent(e),a.dispatchEvent(e),null==o||o(e)}function u(e){oc({event:e.event,dragType:e.dragType,getDropTargetsOver:s.getIsOver,dispatchEvent:l})}return{registerUsage:function(){var e,r;return r=function(e){var t=e.typeKey,n=e.mount,r=od.get(t);if(r)return r.usageCount++,r;var o={typeKey:t,unmount:n(),usageCount:1};return od.set(t,o),o}(e={typeKey:t,mount:function(){return n({canStart:ol,start:u})}}),function(){r.usageCount--,!(r.usageCount>0)&&(r.unmount(),od.delete(e.typeKey))}},dropTarget:s.dropTargetForConsumers,monitor:a.monitorForConsumers}}({typeKey:"element",defaultDropEffect:"move",mount:function(e){return op(oM.bindEvents(),(0,rJ.bind)(document,{type:"dragstart",listener:function(t){if(e.canStart(t)&&!t.defaultPrevented&&t.dataTransfer){var n,r,o,i,a,s,l=t.target;if(!(l instanceof HTMLElement))return null;var u=oS.get(l);if(!u)return null;var c=oo(t),d={element:u.element,dragHandle:null!==(n=u.dragHandle)&&void 0!==n?n:null,input:c};if(u.canDrag&&!u.canDrag(d))return t.preventDefault(),null;if(u.dragHandle){var p=r2({x:c.clientX,y:c.clientY});if(!u.dragHandle.contains(p))return t.preventDefault(),null}var f=null!==(r=null===(o=u.getInitialDataForExternal)||void 0===o?void 0:o.call(u,d))&&void 0!==r?r:null;if(f)for(var h=0,m=Object.entries(f);h<m.length;h++){var g=rQ(m[h],2),v=g[0],y=g[1];t.dataTransfer.setData(v,null!=y?y:"")}!ow()||t.dataTransfer.types.includes(oC)||t.dataTransfer.types.includes("text/uri-list")||t.dataTransfer.setData(oC,"pdnd:android-fallback"),t.dataTransfer.setData("application/vnd.pdnd","");var b={element:u.element,dragHandle:null!==(i=u.dragHandle)&&void 0!==i?i:null,data:null!==(a=null===(s=u.getInitialData)||void 0===s?void 0:s.call(u,d))&&void 0!==a?a:{}};e.start({event:t,dragType:{type:"element",payload:b,startedFrom:"internal"}})}}}))},dispatchEventToSource:function(e){var t,n,r=e.eventName,o=e.payload;null===(t=oS.get(o.source.element))||void 0===t||null===(n=t[r])||void 0===n||n.call(t,o)},onPostDispatch:oM.getOnPostDispatch()}),oE=ok.dropTarget,oD=ok.monitor;function oT(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function oP(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?oT(Object(n),!0).forEach(function(t){r3(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oT(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var oZ={top:function(e,t){return Math.abs(t.y-e.top)},right:function(e,t){return Math.abs(e.right-t.x)},bottom:function(e,t){return Math.abs(e.bottom-t.y)},left:function(e,t){return Math.abs(t.x-e.left)}},oO=Symbol("closestEdge");function oj(e){var t;return null!==(t=e[oO])&&void 0!==t?t:null}let oR={type:"idle"};function oN({elements:e,accessKey:t,axis:n="vertical",onChange:r}){return(0,d.useEffect)(()=>oD({onDrop({location:o,source:i}){var a,s;let l=o.current.dropTargets[0];if(!l)return;let u=i.data,c=l.data,d=e.findIndex(e=>e[t]===u[t]),p=e.findIndex(e=>e[t]===c[t]);!(p<0)&&!(d<0)&&r(function(e){var t=e.list,n=e.startIndex,r=e.finishIndex;if(-1===n||-1===r)return Array.from(t);var o=Array.from(t),i=rQ(o.splice(n,1),1)[0];return o.splice(r,0,i),o}({list:(a={list:e,startIndex:d,indexOfTarget:p,closestEdgeOfTarget:oj(c),axis:n}).list,startIndex:s=a.startIndex,finishIndex:function(e){var t=e.startIndex,n=e.closestEdgeOfTarget,r=e.indexOfTarget,o=e.axis;if(-1===t||-1===r||t===r)return t;if(null==n)return r;var i="vertical"===o&&"bottom"===n||"horizontal"===o&&"right"===n;return t<r?i?r:r-1:i?r+1:r}({closestEdgeOfTarget:a.closestEdgeOfTarget,startIndex:s,indexOfTarget:a.indexOfTarget,axis:a.axis})}))}}),[t,n,e,r])}function oA({children:e,data:t}){let n=(0,d.useRef)(null),[r,o]=(0,d.useState)(oR);return(0,d.useEffect)(()=>{var e;let r=n.current;if(r)return op((e={element:r,getInitialData:()=>t,onDragStart(){o({type:"is-dragging"})},onDrop(){o(oR)}},op(ok.registerUsage(),(oS.set(e.element,e),function(){oS.delete(e.element)}),of(e.element,{attribute:"draggable",value:"true"}))),oE({element:r,canDrop:({source:e})=>e.element!==r,getData:({input:e})=>{var n,o,i,a,s,l,u,c,d;return a=(n={element:r,input:e,allowedEdges:["top","bottom"]}).element,s=n.input,l=n.allowedEdges,u={x:s.clientX,y:s.clientY},c=a.getBoundingClientRect(),d=null!==(o=null===(i=l.map(function(e){return{edge:e,value:oZ[e](c,u)}}).sort(function(e,t){return e.value-t.value})[0])||void 0===i?void 0:i.edge)&&void 0!==o?o:null,oP(oP({},t),{},r3({},oO,d))},getIsSticky:()=>!0,onDragEnter({self:e}){o({type:"is-dragging-over",closestEdge:oj(e.data)})},onDrag({self:e}){let t=oj(e.data);o(e=>"is-dragging-over"===e.type&&e.closestEdge===t?e:{type:"is-dragging-over",closestEdge:t})},onDragLeave(){o(oR)},onDrop(){o(oR)}}))},[t]),(0,c.jsxs)(e8.Z,{ref:n,spacing:1,style:{opacity:"is-dragging"===r.type?.5:"unset"},children:["is-dragging-over"===r.type&&"top"===r.closestEdge?(0,c.jsx)(rY,{}):null,e,"is-dragging-over"===r.type&&"bottom"===r.closestEdge?(0,c.jsx)(rY,{}):null]})}var oF=n(5549),oI=n(10517),o_=n(11682);function oL(e,t){let n=t.indexOf(e);if(0===n)return t;let r=[...t];return r.splice(n,1),r.splice(n-1,0,e),r}function oV(e,t){let n=t.indexOf(e);if(n===t.length-1)return t;let r=[...t];return r.splice(n,1),r.splice(n+1,0,e),r}let o$=(0,d.forwardRef)(function({onMoveUp:e,onMoveDown:t,onMoveLeft:n,onMoveRight:r,menuSx:o,...i},a){let[s,l]=(0,d.useState)(null),u=!!s;function p(e){l(null),e?.()}return(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(e9.Z,{...i,ref:a,"aria-label":"move","aria-haspopup":!0,"aria-expanded":u,size:"small",onClick:function(e){l(e.currentTarget)},children:(0,c.jsx)(o_.default,{})}),(e||t||n||r)&&(0,c.jsxs)(oF.Z,{id:"drag-button-menu",MenuListProps:{"aria-labelledby":"drag-button-menu"},anchorEl:s,open:u,onClose:()=>p(void 0),sx:o,children:[e&&(0,c.jsx)(oI.Z,{onClick:()=>p(e),children:"Move Up"}),t&&(0,c.jsx)(oI.Z,{onClick:()=>p(t),children:"Move Down"}),n&&(0,c.jsx)(oI.Z,{onClick:()=>p(n),children:"Move Left"}),r&&(0,c.jsx)(oI.Z,{onClick:()=>p(r),children:"Move Right"}),r&&(0,c.jsx)(oI.Z,{onClick:()=>p(r),children:"Move Right"})]})]})});var oB=n(76439),oz=n(6595),oH=n(49106),oW=n(41825),oG=n(94680),oU=n(77999),oq=n(42777),oY=n(24255);function oX(e,t,n){let r=function(e,t,n){let r;let o=t.getBoundingClientRect(),i=n&&n.getBoundingClientRect(),a=(0,oY.Z)(t);if(t.fakeTransform)r=t.fakeTransform;else{let e=a.getComputedStyle(t);r=e.getPropertyValue("-webkit-transform")||e.getPropertyValue("transform")}let s=0,l=0;if(r&&"none"!==r&&"string"==typeof r){let e=r.split("(")[1].split(")")[0].split(",");s=parseInt(e[4],10),l=parseInt(e[5],10)}return"left"===e?i?`translateX(${i.right+s-o.left}px)`:`translateX(${a.innerWidth+s-o.left}px)`:"right"===e?i?`translateX(-${o.right-i.left-s}px)`:`translateX(-${o.left+o.width-s}px)`:"up"===e?i?`translateY(${i.bottom+l-o.top}px)`:`translateY(${a.innerHeight+l-o.top}px)`:i?`translateY(-${o.top-i.top+o.height-l}px)`:`translateY(-${o.top+o.height-l}px)`}(e,t,"function"==typeof n?n():n);r&&(t.style.webkitTransform=r,t.style.transform=r)}let oK=d.forwardRef(function(e,t){let n=(0,tW.Z)(),r={enter:n.transitions.easing.easeOut,exit:n.transitions.easing.sharp},o={enter:n.transitions.duration.enteringScreen,exit:n.transitions.duration.leavingScreen},{addEndListener:i,appear:a=!0,children:s,container:l,direction:u="down",easing:p=r,in:f,onEnter:h,onEntered:m,onEntering:g,onExit:v,onExited:y,onExiting:b,style:x,timeout:w=o,TransitionComponent:C=oW.ZP,...S}=e,M=d.useRef(null),k=(0,tQ.Z)((0,oG.Z)(s),M,t),E=e=>t=>{e&&(void 0===t?e(M.current):e(M.current,t))},D=E((e,t)=>{oX(u,e,l),(0,oq.n)(e),h&&h(e,t)}),T=E((e,t)=>{let r=(0,oq.C)({timeout:w,style:x,easing:p},{mode:"enter"});e.style.webkitTransition=n.transitions.create("-webkit-transform",{...r}),e.style.transition=n.transitions.create("transform",{...r}),e.style.webkitTransform="none",e.style.transform="none",g&&g(e,t)}),P=E(m),Z=E(b),O=E(e=>{let t=(0,oq.C)({timeout:w,style:x,easing:p},{mode:"exit"});e.style.webkitTransition=n.transitions.create("-webkit-transform",t),e.style.transition=n.transitions.create("transform",t),oX(u,e,l),v&&v(e)}),j=E(e=>{e.style.webkitTransition="",e.style.transition="",y&&y(e)}),R=d.useCallback(()=>{M.current&&oX(u,M.current,l)},[u,l]);return d.useEffect(()=>{if(f||"down"===u||"right"===u)return;let e=(0,oU.Z)(()=>{M.current&&oX(u,M.current,l)}),t=(0,oY.Z)(M.current);return t.addEventListener("resize",e),()=>{e.clear(),t.removeEventListener("resize",e)}},[u,f,l]),d.useEffect(()=>{f||R()},[f,R]),(0,c.jsx)(C,{nodeRef:M,onEnter:D,onEntered:P,onEntering:T,onExit:O,onExited:j,onExiting:Z,addEndListener:e=>{i&&i(M.current,e)},appear:a,in:f,timeout:w,...S,children:(e,{ownerState:t,...n})=>d.cloneElement(s,{ref:k,style:{visibility:"exited"!==e||f?void 0:"hidden",...x,...s.props.style},...n})})});var oQ=n(28866);function oJ(e){return(0,S.ZP)("MuiDrawer",e)}(0,C.Z)("MuiDrawer",["root","docked","paper","anchorLeft","anchorRight","anchorTop","anchorBottom","paperAnchorLeft","paperAnchorRight","paperAnchorTop","paperAnchorBottom","paperAnchorDockedLeft","paperAnchorDockedRight","paperAnchorDockedTop","paperAnchorDockedBottom","modal"]);var o0=n(27834);let o1=(e,t)=>{let{ownerState:n}=e;return[t.root,("permanent"===n.variant||"persistent"===n.variant)&&t.docked,t.modal]},o2=e=>{let{classes:t,anchor:n,variant:r}=e,o={root:["root",`anchor${(0,v.Z)(n)}`],docked:[("permanent"===r||"persistent"===r)&&"docked"],modal:["modal"],paper:["paper",`paperAnchor${(0,v.Z)(n)}`,"temporary"!==r&&`paperAnchorDocked${(0,v.Z)(n)}`]};return(0,h.Z)(o,oJ,t)},o5=(0,y.ZP)(oH.Z,{name:"MuiDrawer",slot:"Root",overridesResolver:o1})((0,b.Z)(({theme:e})=>({zIndex:(e.vars||e).zIndex.drawer}))),o3=(0,y.ZP)("div",{shouldForwardProp:tY.Z,name:"MuiDrawer",slot:"Docked",skipVariantsResolver:!1,overridesResolver:o1})({flex:"0 0 auto"}),o4=(0,y.ZP)(oQ.Z,{name:"MuiDrawer",slot:"Paper",overridesResolver:(e,t)=>{let{ownerState:n}=e;return[t.paper,t[`paperAnchor${(0,v.Z)(n.anchor)}`],"temporary"!==n.variant&&t[`paperAnchorDocked${(0,v.Z)(n.anchor)}`]]}})((0,b.Z)(({theme:e})=>({overflowY:"auto",display:"flex",flexDirection:"column",height:"100%",flex:"1 0 auto",zIndex:(e.vars||e).zIndex.drawer,WebkitOverflowScrolling:"touch",position:"fixed",top:0,outline:0,variants:[{props:{anchor:"left"},style:{left:0}},{props:{anchor:"top"},style:{top:0,left:0,right:0,height:"auto",maxHeight:"100%"}},{props:{anchor:"right"},style:{right:0}},{props:{anchor:"bottom"},style:{top:"auto",left:0,bottom:0,right:0,height:"auto",maxHeight:"100%"}},{props:({ownerState:e})=>"left"===e.anchor&&"temporary"!==e.variant,style:{borderRight:`1px solid ${(e.vars||e).palette.divider}`}},{props:({ownerState:e})=>"top"===e.anchor&&"temporary"!==e.variant,style:{borderBottom:`1px solid ${(e.vars||e).palette.divider}`}},{props:({ownerState:e})=>"right"===e.anchor&&"temporary"!==e.variant,style:{borderLeft:`1px solid ${(e.vars||e).palette.divider}`}},{props:({ownerState:e})=>"bottom"===e.anchor&&"temporary"!==e.variant,style:{borderTop:`1px solid ${(e.vars||e).palette.divider}`}}]}))),o6={left:"right",right:"left",top:"down",bottom:"up"},o8=d.forwardRef(function(e,t){let n=(0,w.i)({props:e,name:"MuiDrawer"}),r=(0,tW.Z)(),o=(0,oz.V)(),i={enter:r.transitions.duration.enteringScreen,exit:r.transitions.duration.leavingScreen},{anchor:a="left",BackdropProps:s,children:l,className:u,elevation:p=16,hideBackdrop:h=!1,ModalProps:{BackdropProps:m,...g}={},onClose:v,open:y=!1,PaperProps:b={},SlideProps:x,TransitionComponent:C,transitionDuration:S=i,variant:M="temporary",slots:k={},slotProps:E={},...D}=n,T=d.useRef(!1);d.useEffect(()=>{T.current=!0},[]);let P=function({direction:e},t){return"rtl"===e&&["left","right"].includes(t)?o6[t]:t}({direction:o?"rtl":"ltr"},a),Z={...n,anchor:a,elevation:p,open:y,variant:M,...D},O=o2(Z),j={slots:{transition:C,...k},slotProps:{paper:b,transition:x,...E,backdrop:(0,o0.Z)(E.backdrop||{...s,...m},{transitionDuration:S})}},[R,N]=(0,n5.Z)("root",{ref:t,elementType:o5,className:(0,f.Z)(O.root,O.modal,u),shouldForwardComponentProp:!0,ownerState:Z,externalForwardedProps:{...j,...D,...g},additionalProps:{open:y,onClose:v,hideBackdrop:h,slots:{backdrop:j.slots.backdrop},slotProps:{backdrop:j.slotProps.backdrop}}}),[A,F]=(0,n5.Z)("paper",{elementType:o4,shouldForwardComponentProp:!0,className:(0,f.Z)(O.paper,b.className),ownerState:Z,externalForwardedProps:j,additionalProps:{elevation:"temporary"===M?p:0,square:!0}}),[I,_]=(0,n5.Z)("docked",{elementType:o3,ref:t,className:(0,f.Z)(O.root,O.docked,u),ownerState:Z,externalForwardedProps:j,additionalProps:D}),[L,V]=(0,n5.Z)("transition",{elementType:oK,ownerState:Z,externalForwardedProps:j,additionalProps:{in:y,direction:o6[P],timeout:S,appear:T.current}}),$=(0,c.jsx)(A,{...F,children:l});if("permanent"===M)return(0,c.jsx)(I,{..._,children:$});let B=(0,c.jsx)(L,{...V,children:$});return"persistent"===M?(0,c.jsx)(I,{..._,children:B}):(0,c.jsx)(R,{...N,children:B})}),o9=({anchor:e="right",isOpen:t,onClose:n,PaperProps:r,children:o,...i})=>{let a=(0,oB.Z)("(max-width:1080px)");return(0,c.jsx)(o8,{...i,open:t,onClose:n,anchor:e,PaperProps:{...r,sx:t4({width:a?"100%":"1080px",overflow:"hidden"},r?.sx)},children:o})};var o7=n(315);function ie(e){let{error:t}=e;return(0,c.jsx)(o7.Z,{severity:"error",children:t.message})}var it=n(68715);let ir=[{id:"default",label:"Default",value:void 0},{id:"12",label:"12",value:12},{id:"14",label:"14",value:14},{id:"16",label:"16",value:16},{id:"20",label:"20",value:20},{id:"24",label:"24",value:24},{id:"28",label:"28",value:28},{id:"32",label:"32",value:32},{id:"36",label:"36",value:36},{id:"40",label:"40",value:40},{id:"48",label:"48",value:48},{id:"56",label:"56",value:56},{id:"64",label:"64",value:64},{id:"72",label:"72",value:72},{id:"96",label:"96",value:96},{id:"128",label:"128",value:128},{id:"160",label:"160",value:160},{id:"192",label:"192",value:192}];function io({value:e,onChange:t}){return(0,c.jsx)(rz,{label:"Font Size",control:(0,c.jsx)(rG,{value:ir.find(t=>t.value===e),options:ir,getOptionLabel:e=>e.label,onChange:(e,{value:n})=>{t(n)},disableClearable:!0})})}var ii=n(79119);function ia({action:e,submitText:t="Save",cancelText:n="Cancel",isReadonly:r,isValid:o,onActionChange:i,onSubmit:a,onDelete:s,onCancel:l,...u}){return(0,c.jsx)(e8.Z,{direction:"row",gap:1,sx:{marginLeft:"auto"},...u,children:"read"===e?(0,c.jsxs)(c.Fragment,{children:[i&&(0,c.jsx)(O.Z,{disabled:r,variant:"contained",onClick:()=>i("update"),children:"Edit"}),s&&(0,c.jsx)(O.Z,{color:"error",disabled:r,variant:"outlined",onClick:s,children:"Delete"}),l&&(a||s)&&(0,c.jsx)(ii.Z,{orientation:"vertical",flexItem:!0,sx:{borderColor:e=>e.palette.grey["500"],"&.MuiDivider-root":{marginLeft:2,marginRight:1}}}),l&&(0,c.jsx)(O.Z,{color:"secondary",variant:"outlined",onClick:l,children:n})]}):(0,c.jsxs)(c.Fragment,{children:[a&&(0,c.jsx)(O.Z,{variant:"contained",disabled:!o,onClick:a,children:t}),l&&(0,c.jsx)(O.Z,{color:"secondary",variant:"outlined",onClick:l,children:n})]})})}var is=n(78846);function il(e){let{width:t,height:n,data:r,format:o,axisLine:i,max:a}=e,s=eH(),l=function(e,t){let n=(0,d.useRef)();return(void 0===n.current||!1===eU()(t,n.current.deps))&&(n.current={value:e(),deps:t}),n.current.value}(()=>{if(void 0===r.value)return s.noDataOption;let e=iu(r.value,o,t,n);return{title:{show:!1},tooltip:{show:!1},series:[{type:"gauge",center:["50%","65%"],radius:"86%",startAngle:200,endAngle:-20,min:0,max:a,silent:!0,progress:{show:!0,width:16,itemStyle:{color:"auto"}},pointer:{show:!1},axisLine:{lineStyle:{color:[[1,"rgba(127,127,127,0.35)"]],width:16}},axisTick:{show:!1,distance:0},splitLine:{show:!1},axisLabel:{show:!1,distance:-18,color:"#999",fontSize:12},anchor:{show:!1},title:{show:!1},detail:{show:!1},data:[{value:r.value}]},{type:"gauge",center:["50%","65%"],radius:"100%",startAngle:200,endAngle:-20,min:0,max:a,pointer:{show:!0,icon:t>170?"path://M12.8,0.7l12,40.1H0.7L12.8,0.7z":"none",length:10,width:5,offsetCenter:[0,"-49%"],itemStyle:{color:"auto"}},axisLine:i,axisTick:{show:!1},splitLine:{show:!1},axisLabel:{show:!1},detail:{show:!0,width:"60%",borderRadius:8,offsetCenter:[0,"-9%"],color:"inherit",fontSize:e,formatter:null===r.value?()=>"null":e=>eZ(e,o)},data:[{value:r.value,name:r.label,title:{show:!0,color:s.echartsTheme.textStyle?.color??"inherit",offsetCenter:[0,"55%"],overflow:"truncate",fontSize:12,width:.8*t}}]}]}},[r,t,n,s,o,i,a]);return(0,c.jsx)(e1,{sx:{width:t,height:n,padding:`${s.container.padding.default}px`},option:l,theme:s.echartsTheme})}function iu(e,t,n,r){let o=Math.min(n,r)/(("number"==typeof e?eZ(e,t):`${e}`).length??2)*.7;return`clamp(3px, ${o}px, 24px)`}(0,eR.D)([is.N,eA.N,eI.N,e_.N,eL.N]);var ic=n(46359),id=n(7749),ip=n(94197);let ih=(0,ip.Gv)({String:ip.pJ.string,Number:ip.pJ.number,"True False":ip.pJ.bool,PropertyName:ip.pJ.propertyName,Null:ip.pJ.null,", :":ip.pJ.separator,"[ ]":ip.pJ.squareBracket,"{ }":ip.pJ.brace}),im=id.WQ.deserialize({version:14,states:"$bOVQPOOOOQO'#Cb'#CbOnQPO'#CeOvQPO'#ClOOQO'#Cr'#CrQOQPOOOOQO'#Cg'#CgO}QPO'#CfO!SQPO'#CtOOQO,59P,59PO![QPO,59PO!aQPO'#CuOOQO,59W,59WO!iQPO,59WOVQPO,59QOqQPO'#CmO!nQPO,59`OOQO1G.k1G.kOVQPO'#CnO!vQPO,59aOOQO1G.r1G.rOOQO1G.l1G.lOOQO,59X,59XOOQO-E6k-E6kOOQO,59Y,59YOOQO-E6l-E6l",stateData:"#O~OeOS~OQSORSOSSOTSOWQO_ROgPO~OVXOgUO~O^[O~PVO[^O~O]_OVhX~OVaO~O]bO^iX~O^dO~O]_OVha~O]bO^ia~O",goto:"!kjPPPPPPkPPkqwPPPPk{!RPPP!XP!e!hXSOR^bQWQRf_TVQ_Q`WRg`QcZRicQTOQZRQe^RhbRYQR]R",nodeNames:"⚠ JsonText True False Null Number String } { Object Property PropertyName : , ] [ Array",maxTerm:25,nodeProps:[["isolate",-2,6,11,""],["openedBy",7,"{",14,"["],["closedBy",8,"}",15,"]"]],propSources:[ih],skippedNodes:[0],repeatNodeCount:2,tokenData:"(|~RaXY!WYZ!W]^!Wpq!Wrs!]|}$u}!O$z!Q!R%T!R![&c![!]&t!}#O&y#P#Q'O#Y#Z'T#b#c'r#h#i(Z#o#p(r#q#r(w~!]Oe~~!`Wpq!]qr!]rs!xs#O!]#O#P!}#P;'S!];'S;=`$o<%lO!]~!}Og~~#QXrs!]!P!Q!]#O#P!]#U#V!]#Y#Z!]#b#c!]#f#g!]#h#i!]#i#j#m~#pR!Q![#y!c!i#y#T#Z#y~#|R!Q![$V!c!i$V#T#Z$V~$YR!Q![$c!c!i$c#T#Z$c~$fR!Q![!]!c!i!]#T#Z!]~$rP;=`<%l!]~$zO]~~$}Q!Q!R%T!R![&c~%YRT~!O!P%c!g!h%w#X#Y%w~%fP!Q![%i~%nRT~!Q![%i!g!h%w#X#Y%w~%zR{|&T}!O&T!Q![&Z~&WP!Q![&Z~&`PT~!Q![&Z~&hST~!O!P%c!Q![&c!g!h%w#X#Y%w~&yO[~~'OO_~~'TO^~~'WP#T#U'Z~'^P#`#a'a~'dP#g#h'g~'jP#X#Y'm~'rOR~~'uP#i#j'x~'{P#`#a(O~(RP#`#a(U~(ZOS~~(^P#f#g(a~(dP#i#j(g~(jP#X#Y(m~(rOQ~~(wOW~~(|OV~",tokenizers:[0],topRules:{JsonText:[0,1]},tokenPrec:0});var ig=n(61262);let iv=()=>e=>{try{JSON.parse(e.state.doc.toString())}catch(i){var t,n;let r;if(!(i instanceof SyntaxError))throw i;let o=(t=i,n=e.state.doc,(r=t.message.match(/at position (\d+)/))?Math.min(+r[1],n.length):(r=t.message.match(/at line (\d+) column (\d+)/))?Math.min(n.line(+r[1]).from+ +r[2]-1,n.length):0);return[{from:o,message:i.message,severity:"error",to:o}]}return[]},iy=ig.qp.define({name:"json",parser:im.configure({props:[ig.uj.add({Object:(0,ig.tC)({except:/^\s*\}/}),Array:(0,ig.tC)({except:/^\s*\]/})}),ig.x0.add({"Object Array":ig.Dv})]}),languageData:{closeBrackets:{brackets:["[","{",'"']},indentOnInput:/^\s*[\}\]]$/}});var ib=n(68799);function ix(e){let t=(0,tW.Z)(),n="dark"===t.palette.mode,[r,o]=(0,d.useState)(()=>JSON.stringify(e.value,null,2)),[i,a]=(0,d.useState)(r);return(0,d.useEffect)(()=>{o(JSON.stringify(e.value,null,2))},[e.value]),(0,c.jsx)(ic.ZP,{...e,style:{border:`1px solid ${t.palette.divider}`},theme:n?"dark":"light",extensions:[new ig.ri(iy),(0,ib.ir)(iv()),(0,ib.Q2)()],value:r,onChange:e=>{o(e)},onBlur:()=>{i!==r&&void 0!==e.onChange&&(e.onChange(r),a(r))},placeholder:e.placeholder})}var iw=n(44811),iC=n(98857),iS=n(219),iM=n(17846),ik=n(55328),iE=n(4665),iD=n(20461);function iT(e,t){if(t){let n=t.toLowerCase();if("local"!==n&&"browser"!==n)return{...e,timeZone:"utc"===n?"UTC":t}}return e}function iP(e,t,n){let r=n?.toLowerCase();return n&&"local"!==r&&"browser"!==r?(0,iE.formatInTimeZone)(e,"utc"===r?"UTC":n,t):(0,iD.format)(e,t)}function iZ(e,t,n){let r=iT({hour:"numeric",minute:"numeric",hourCycle:"h23"},n);return t<=18e5?r.second="numeric":t>=864e5&&(r.month="numeric",r.day="numeric"),new Intl.DateTimeFormat(void 0,r).format(e).replace(/, /g," ")}function iO(e){return e>15768e7?"{yyyy}":e>63072e6?"{MMM} {yyyy}":e>432e6&&e<1577664e4?"{MM}/{dd}":e>1728e5&&e<=432e6?"{MM}/{dd} {HH}:{mm}":{year:"{yearStyle|{yyyy}}\n{monthStyle|{MMM}}",month:"{MMM}",day:"{MM}/{dd}"}}let ij=e=>{if(!e)return{formattedDate:"",formattedTime:""};let t=new Date(e);return{formattedDate:(0,iD.format)(t,"MMM dd, yyyy - "),formattedTime:(0,iD.format)(t,"HH:mm:ss")}},iR=(0,d.createContext)(void 0);function iN(e){let{children:t,timeZone:n}=e;return(0,c.jsx)(iR.Provider,{value:n,children:t})}function iA(){let e=(0,d.useContext)(iR);return{timeZone:e??"local",formatWithUserTimeZone:(t,n)=>iP(t,n,e),dateFormatOptionsWithUserTimeZone:t=>iT(t,e)}}let iF=375,iI=650,i_=650,iL=500,iV=.75,i$=8,iB=750,iz="nearby series showing in tooltip",iH="emphasized series showing as bold in tooltip",iW="#2E313E",iG=new Intl.DateTimeFormat(void 0,{year:"numeric",month:"short",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0}),iU={coords:{plotCanvas:{x:0,y:0},zrender:{x:0,y:0},target:null},chartWidth:0},iq=[],iY={ie:navigator.userAgent.match(/MSIE\s([\d.]+)/)||navigator.userAgent.match(/Trident\/.+?rv:(([\d.]+))/),edge:navigator.userAgent.match(/Edge?\/([\d.]+)/)},iX="onpointerdown"in window&&(iY.edge||iY.ie&&iY.ie[1]&&+iY.ie[1]>=11),iK=iX?"pointermove":"mousemove",iQ=()=>{let[e,t]=(0,d.useState)(null);return(0,d.useEffect)(()=>{let e=e=>t({page:{x:e.pageX,y:e.pageY},client:{x:e.clientX,y:e.clientY},plotCanvas:{x:e.zrX,y:e.zrY},target:e.target});return window.addEventListener(iK,e),()=>{window.removeEventListener(iK,e)}},[]),e},iJ={wrapLabels:!0,enablePinning:!0},i0="Click chart to pin",i1="Click chart to unpin";var i2=n(7444),i5=n(75276);function i3(e){let{markerColor:t,sx:n}=e;return(0,c.jsx)(eV.Z,{sx:t4({display:"inline-block",width:"11px",height:"11px",borderRadius:"2px",marginRight:1,verticalAlign:"top"},n),style:{backgroundColor:t}})}function i4(e){let{formattedY:t,markerColor:n,metricName:r,metricLabels:o}=e;return(0,c.jsxs)(e8.Z,{spacing:.5,children:[(0,c.jsxs)(eV.Z,{sx:e=>({display:"flex",height:"16px",flexDirection:"row",alignItems:"center",justifyContent:"left",color:e.palette.common.white,fontSize:"11px"}),children:[(0,c.jsx)(i3,{markerColor:n,sx:{marginTop:.25}}),(0,c.jsxs)(eV.Z,{component:"span",children:[r,(0,c.jsx)(eV.Z,{component:"span",sx:e=>({color:e.palette.common.white,fontWeight:700,paddingLeft:"2px"}),children:t})]})]}),(0,c.jsx)(ii.Z,{sx:e=>({borderColor:e.palette.grey["500"]})}),(0,c.jsx)(eV.Z,{sx:e=>({color:e.palette.common.white}),children:o.map(e=>{if(e){let[t,n]=e.split("="),r=void 0!==n?`${t}: `:t,o=void 0!==n?n.replace(/(^"|"$)/g,""):n;return(0,c.jsxs)(eV.Z,{sx:{display:"flex",gap:"4px"},children:[(0,c.jsx)(nQ.Z,{sx:{fontSize:"11px"},children:r}),(0,c.jsx)(nQ.Z,{sx:e=>({color:e.palette.common.white,fontWeight:700,fontSize:"11px"}),children:o})]},e)}})})]})}function i6(e){let{seriesName:t,formattedY:n,markerColor:r,totalSeries:o,emphasizeText:i=!1,wrapLabels:a=!0}=e,s=t.split("{"),l=(s[1]??t).replace(/[{}]/g,"").split(",");if(1===o&&l.length>1){let e=s[0]?`${s[0]}:`:"value:";return(0,c.jsx)(i4,{formattedY:n,metricName:e,metricLabels:l,markerColor:r})}let u=t.replace(/[,]/g,", ");return(0,c.jsxs)(eV.Z,{sx:{display:"table-row",paddingTop:.5},children:[(0,c.jsxs)(eV.Z,{sx:{display:"table-cell",maxWidth:"520px"},children:[(0,c.jsx)(i3,{markerColor:r,sx:{marginTop:.5}}),(0,c.jsx)(eV.Z,{component:"span",sx:e=>({display:"inline-block",width:"calc(100% - 20px)",minWidth:150,maxWidth:iL,overflow:"hidden",color:e.palette.common.white,fontWeight:i?e.typography.fontWeightBold:e.typography.fontWeightRegular,textOverflow:"ellipsis",whiteSpace:a?"normal":"nowrap"}),"aria-label":i?iH:iz,children:u})]}),(0,c.jsx)(eV.Z,{sx:e=>({display:"table-cell",paddingLeft:1.5,textAlign:"right",verticalAlign:"top",fontWeight:i?e.typography.fontWeightBold:e.typography.fontWeightRegular}),children:n})]})}function i8(e){let{series:t,wrapLabels:n}=e,r=(0,d.useMemo)(()=>null===t?null:t.sort((e,t)=>e.y>t.y?-1:1),[t]);return null===t||null===r?null:(0,c.jsx)(eV.Z,{sx:e=>({display:"table",padding:e.spacing(.5,2)}),children:r.map(({datumIdx:e,seriesIdx:t,seriesName:o,y:i,formattedY:a,markerColor:s,isClosestToCursor:l})=>{if(null===e||null===t)return null;let u=t.toString()+e.toString();return(0,c.jsx)(i6,{seriesName:o,y:i,formattedY:a,markerColor:s,totalSeries:r.length,wrapLabels:n,emphasizeText:l},u)})})}var i9=n(87895),i7=n(1889),ae=n(75186);let at=(0,d.memo)(function({nearbySeries:e,totalSeries:t,isTooltipPinned:n,showAllSeries:r,enablePinning:o=!0,onShowAllClick:i,onUnpinClick:a}){let s=e[0]?.date??null;if(null===s)return null;let l=o&&t>5;return(0,c.jsxs)(eV.Z,{sx:e=>({width:"100%",maxWidth:iI,padding:e.spacing(1.5,2,.5,2),backgroundColor:e.palette.designSystem?.grey[800]??iW,position:"sticky",top:0,left:0}),children:[(0,c.jsxs)(eV.Z,{sx:{width:"100%",display:"flex",justifyContent:"start",alignItems:"center",paddingBottom:.5},children:[(e=>{let{formattedTime:t,formattedDate:n}=ij(e);return(0,c.jsxs)(eV.Z,{children:[(0,c.jsx)(nQ.Z,{variant:"caption",sx:e=>({color:e.palette.common.white}),children:n}),(0,c.jsx)(nQ.Z,{variant:"caption",children:(0,c.jsx)("strong",{children:t})})]})})(s),(0,c.jsxs)(e8.Z,{direction:"row",gap:1,sx:{marginLeft:"auto"},children:[l&&(0,c.jsxs)(e8.Z,{direction:"row",gap:.5,alignItems:"center",sx:{textAlign:"right"},children:[(0,c.jsx)(nQ.Z,{sx:{fontSize:11},children:"Show All"}),(0,c.jsx)(i9.Z,{checked:r,size:"small",onChange:(e,t)=>{if(void 0!==i)return i(t)},sx:e=>({"& .MuiSwitch-switchBase":{color:e.palette.common.white},"& .MuiSwitch-track":{backgroundColor:e.palette.common.white}})})]}),o&&(0,c.jsxs)(e8.Z,{direction:"row",alignItems:"center",children:[(0,c.jsx)(nQ.Z,{sx:{marginRight:.5,fontSize:11,verticalAlign:"middle"},children:n?i1:i0}),n?(0,c.jsx)(i7.default,{onClick:()=>{void 0!==a&&a()},sx:{fontSize:16,cursor:"pointer"}}):(0,c.jsx)(ae.default,{sx:{fontSize:16}})]})]})]}),(0,c.jsx)(ii.Z,{sx:e=>({width:"100%",borderColor:e.palette.grey["500"]})})]})}),an=1e3,ar="Pinned Crosshair",ao={name:ar,type:"line",markLine:{data:[],lineStyle:{type:"dashed",width:2},emphasis:{lineStyle:{width:2,opacity:1}},blur:{lineStyle:{width:2,opacity:1}}}};function ai(e){let t=e._model;void 0!==t&&void 0!==t.option.toolbox&&t.option.toolbox.length>0&&"normal"===t.option.toolbox[0].feature.dataZoom.iconStatus.zoom&&e.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:!0})}function aa(e){e.dispatchAction({type:"restore"})}function as(e){void 0!==e.dispatchAction&&(e.dispatchAction({type:"unselect"}),e.dispatchAction({type:"downplay"}))}function al(e,t,n){if(void 0===n)return null;let r=[e,t];return n.containPixel("grid",r)?n.convertFromPixel("grid",r):null}function au(e,t,n,r,o,i){let a=i.length>0?i[i.length-1]:o[o.length-1];void 0!==a&&e.dispatchAction({type:"select",seriesIndex:a.seriesIndex,dataIndex:a.dataIndex,escapeConnect:!0}),e.dispatchAction({type:"downplay",seriesIndex:r}),n.length>0?e.dispatchAction({type:"highlight",seriesIndex:n,notBlur:!1,escapeConnect:!0}):(e.dispatchAction({type:"highlight",seriesIndex:t,notBlur:!0,escapeConnect:!0}),e.dispatchAction({type:"toggleSelect"}))}function ac(e){return e[e.length-1]?.name===ar}function ad(e,t){if(void 0===e||void 0===t)return null;let n=null,r=1/0;for(let[o]of e){let e=Math.abs(o-t);e<r&&(n=o,r=e)}return n}function ap(e,t){if(void 0===t)return null;let n=e.length,r=null;for(let o=0;o<n;o++){let i=n>0?e[o]:null;if(!i)break;r=ad(i.values,t)}return r}let af=5.5,ah=30,am=5;function ag(e,t,n,r,o,i){let a=[],s=n[0]??null,l=n[1]??null;if(null===s||null===l||void 0===o.dispatchAction||!Array.isArray(e))return a;let u=[],c=[],d=[],p=[],f=[],h=e.length,m=new Map,g=ad(e[0]?.values,s);if(null===g)return iq;for(let n=0;n<h;n++){let s=t[n];if(!s)break;let v=h>0?e[n]:null;if(!v)break;let y=v.values;if(void 0===y||!Array.isArray(y))break;let b=s.name?s.name.toString():"",x=s.color??"#000";if(Array.isArray(e))for(let e=0;e<y.length;e++){let t=y[e];if(void 0===t||!Array.isArray(t))break;let s=t[0],v=t[1];if(null!=v&&g===s&&l<=v+r&&l>=v-r){let t=ax({valueToCheck:l,baseValue:v,percentage:Math.max(h>am?2:5,100/h)});if(t){c.push(n);let t=m.get(v)??0;m.set(v,t+1),t>0&&f.push({seriesIndex:n,dataIndex:e,seriesName:b,yValue:v}),p.push({seriesIndex:n,dataIndex:e,seriesName:b,yValue:v})}else d.push(n),o.dispatchAction({type:"downplay",seriesIndex:n});let r=eZ(v,i);a.push({seriesIdx:n,datumIdx:e,seriesName:b,date:g,x:s,y:v,formattedY:r,markerColor:x.toString(),isClosestToCursor:t}),u.push(n)}}}return au(o,u,c,d,p,f),a}function av(e,t,n,r,o){let i=[],a=t[0]??null,s=t[1]??null;if(null===a||null===s)return i;let l=[],u=[],c=[],d=e.timeSeries.length;if(Array.isArray(e.xAxis)&&Array.isArray(e.timeSeries))for(let t=0;t<d;t++){let p=e.timeSeries[t];if(void 0===p||i.length>=an)break;let f=p.name?p.name.toString():"",h=p.color??"#000";if(Array.isArray(p.data))for(let m=0;m<p.data.length;m++){let g=e.xAxis[m]??0,v=p.data[m];if(null!=v&&a===m&&"-"!==v&&s<=v+n&&s>=v-n){let e=ax({valueToCheck:s,baseValue:v,percentage:Math.max(d>am?2:5,100/d)});e?u.push(t):(c.push(t),r?.dispatchAction!==void 0&&r.dispatchAction({type:"downplay",seriesIndex:t}));let n=g>0x174876e7ff?g:1e3*g,a=eZ(v,o);i.push({seriesIdx:t,datumIdx:m,seriesName:f,date:n,x:g,y:v,formattedY:a,markerColor:h.toString(),isClosestToCursor:e}),l.push(t)}}}return r?.dispatchAction!==void 0&&(r.dispatchAction({type:"downplay",seriesIndex:c}),u.length>0?r.dispatchAction({type:"highlight",seriesIndex:u,notBlur:!1,escapeConnect:!0}):r.dispatchAction({type:"highlight",seriesIndex:l,notBlur:!0,escapeConnect:!0})),i}function ay({mousePos:e,pinnedPos:t,data:n,seriesMapping:r,chart:o,format:i,showAllSeries:a=!1}){if(void 0===o||null===e)return iq;let s=!1;if(null!==e.target){let t=e.target.parentElement;if(null!==t){let e=t.parentElement;null!==e&&o.getDom()===e&&(s=!0)}}if(null!==t&&(e=t,s=!0),!1===s||null===n||void 0===o._model||void 0===e.plotCanvas.x||void 0===e.plotCanvas.y)return iq;let l=al(e.plotCanvas.x,e.plotCanvas.y,o);if(null!==l){let e=aw({yInterval:o._model.getComponent("yAxis").axis.scale._interval,totalSeries:n.length,showAllSeries:a});return ag(n,r,l,e,o,i)}return iq}function ab({mousePos:e,pinnedPos:t,chartData:n,chart:r,format:o,showAllSeries:i=!1}){if(void 0===r||null===e)return[];let a=!1;if(null!==e.target){let t=e.target.parentElement;if(null!==t){let e=t.parentElement;null!==e&&r.getDom()===e&&(a=!0)}}if(null!==t&&(e=t,a=!0),!1===a||void 0===r._model)return[];let s=aw({yInterval:r._model.getComponent("yAxis").axis.scale._interval,totalSeries:n.timeSeries.length,showAllSeries:i}),l=[e.plotCanvas.x??0,e.plotCanvas.y??0];if(r.containPixel("grid",l)){let e=r.convertFromPixel("grid",l);if(void 0!==e[0]&&void 0!==e[1])return av(n,e,s,r,o)}return[]}function ax({valueToCheck:e,baseValue:t,percentage:n}){let r=n/100*t;return e>=t-r&&e<=t+r}function aw({yInterval:e,totalSeries:t,showAllSeries:n=!1}){if(n)return 10*e;let r=.3*e;return t>am?Math.max(r,e*ah/t):Math.max(r,e*af)}function aC(e,t,n,r,o,i){let a;if(null===e||(null!==n&&(e=n),void 0===e.plotCanvas.x))return;let s=e.page.x,l=e.page.y+16;return i&&(s=s-(a=i.getBoundingClientRect()).left+i.scrollLeft,l=l-a.top+i.scrollTop),e.client.y+r+16>window.innerHeight&&(l-=r*iV,a&&l<a.top&&(l=i$/2)),e.plotCanvas.x>t-.9*o&&s>iI?`translate3d(${s-32}px, ${l}px, 0) translateX(-100%)`:`translate3d(${s+32}px, ${l}px, 0)`}function aS(e,t,n){return{minWidth:iF,maxWidth:iI,maxHeight:(n?n-i$:void 0)??i_,padding:0,position:"absolute",top:0,left:0,backgroundColor:e.palette.designSystem?.grey[800]??iW,borderRadius:"6px",color:"#fff",fontSize:"11px",visibility:"visible",opacity:1,transition:"all 0.1s ease-out",zIndex:null!==t?"auto":e.zIndex.tooltip,overflow:"hidden","&:hover":{overflowY:"auto"}}}let aM=(0,d.memo)(function({chartRef:e,chartData:t,enablePinning:n=!0,wrapLabels:r,format:o,onUnpinClick:i,pinnedPos:a,containerId:s}){let[l,u]=(0,d.useState)(!1),p=iQ(),{height:f,width:h,ref:m}=(0,i5.default)(),g=(0,d.useRef)(),v=null!==a&&n;if(null===p||null===p.target||null===a&&"CANVAS"!==p.target.tagName)return null;let y=e.current,b=y?.getWidth()??iB,x=ab({mousePos:p,chartData:t,pinnedPos:a,chart:y,format:o,showAllSeries:l});if(0===x.length)return null;let w=t.timeSeries.length,C=s?document.querySelector(s):void 0,S=C?C.getBoundingClientRect().height:void 0;return v||(g.current=aC(p,b,a,f??0,h??0,C)),(0,c.jsx)(i2.Z,{container:C,children:(0,c.jsx)(eV.Z,{ref:m,sx:e=>({minWidth:iF,maxWidth:iI,maxHeight:S??i_,padding:0,position:"absolute",top:0,left:0,backgroundColor:e.palette.designSystem?.grey[800]??iW,borderRadius:"6px",color:"#fff",fontSize:"11px",visibility:"visible",opacity:1,transition:"all 0.1s ease-out",zIndex:null!==a?"auto":e.zIndex.tooltip,overflow:"hidden","&:hover":{overflowY:"auto"}}),style:{transform:g.current,display:g.current?"block":"none"},children:(0,c.jsxs)(e8.Z,{spacing:.5,children:[(0,c.jsx)(at,{nearbySeries:x,totalSeries:w,enablePinning:n,isTooltipPinned:v,showAllSeries:l,onShowAllClick:e=>u(e),onUnpinClick:i}),(0,c.jsx)(i8,{series:x,wrapLabels:r})]})})})});(0,eR.D)([iw.N,eA.N,eK.N,iC.N,iS.N,iM.N,eI.N,ik.N,e_.N,eQ.N,eL.N]);let ak=(0,d.forwardRef)(function({height:e,data:t,yAxis:n,format:r,grid:o,legend:i,tooltipConfig:a=iJ,noDataVariant:s="message",syncGroup:l,onDataZoom:u,onDoubleClick:p,__experimentalEChartsOptionsOverride:f},h){let m=eH(),g=(0,d.useRef)(),[v,y]=(0,d.useState)(!0),[b,x]=(0,d.useState)(null),{timeZone:w}=iA(),[C,S]=(0,d.useState)(!1),[M,k]=(0,d.useState)(0);(0,d.useImperativeHandle)(h,()=>({highlightSeries({id:e}){g.current&&g.current.dispatchAction({type:"highlight",seriesId:e})},clearHighlightedSeries:()=>{g.current&&as(g.current)}}),[]);let E=(0,d.useMemo)(()=>({datazoom:e=>{if(void 0===u&&setTimeout(()=>{x(null)},10),void 0===u||void 0===e.batch[0])return;let n=e.batch[0].startValue??0,r=e.batch[0].endValue??t.xAxis.length-1,o=t.xAxis[n],i=t.xAxis[r];void 0!==o&&void 0!==i&&u({start:o,end:i,startIndex:n,endIndex:r})}}),[t,u,x]);void 0!==g.current&&ai(g.current);let{noDataOption:D}=m,T=(0,d.useMemo)(()=>{if(void 0===t.timeSeries)return{};if(null===t.timeSeries||0===t.timeSeries.length&&"message"===s)return D;let e=t.rangeMs??e4(t.xAxis),a={series:t.timeSeries,xAxis:{type:"category",data:t.xAxis,max:t.xAxisMax,axisLabel:{formatter:t=>iZ(t,e,w)}},yAxis:e3(n,r),animation:!1,tooltip:{show:!0,trigger:"axis",showContent:!1},axisPointer:{type:"line",z:0,triggerEmphasis:!1,triggerTooltip:!1,snap:!0},toolbox:{feature:{dataZoom:{icon:null,yAxisIndex:"none"}}},grid:o,legend:i};return f?f(a):a},[t,n,r,o,i,D,w,f,s]);return(0,c.jsxs)(eV.Z,{style:{height:e},onClick:e=>{a.enablePinning&&e.target instanceof HTMLCanvasElement&&x(t=>null===t?{page:{x:e.pageX,y:e.pageY},client:{x:e.clientX,y:e.clientY},plotCanvas:{x:e.nativeEvent.offsetX,y:e.nativeEvent.offsetY},target:e.target}:null)},onMouseDown:e=>{let{clientX:t}=e;S(!0),k(t)},onMouseMove:e=>{if(!(e.target instanceof HTMLCanvasElement))return;let{clientX:t}=e;C&&t-M>0&&y(!1)},onMouseUp:()=>{S(!1),k(0),y(!0)},onMouseLeave:()=>{null===b&&y(!1),void 0!==g.current&&as(g.current)},onMouseEnter:()=>{y(!0),void 0!==g.current&&ai(g.current)},onDoubleClick:e=>{x(null),void 0===p?void 0!==g.current&&aa(g.current):p(e)},children:[!0===v&&T.tooltip?.showContent===!1&&!0!==a.hidden&&(0,c.jsx)(aM,{chartRef:g,chartData:t,wrapLabels:a.wrapLabels,enablePinning:a.enablePinning,pinnedPos:b,format:r,onUnpinClick:()=>{x(null)},containerId:m.tooltipPortalContainerId}),(0,c.jsx)(e1,{sx:{width:"100%",height:"100%"},option:T,theme:m.echartsTheme,onEvents:E,_instance:g,syncGroup:l})]})});var aE=n(28797),aD=n(48137),aT=n(33755),aP=n(86396);function aZ({control:e,...t}){let{fields:n,append:r,remove:o}=(0,aD.useFieldArray)({control:e,name:"panelDefinition.spec.links"});return(0,c.jsxs)(e8.Z,{...t,gap:3,children:[n&&n.length>0?n.map((t,n)=>(0,c.jsxs)(d.Fragment,{children:[(0,c.jsxs)(e8.Z,{direction:"row",gap:1,alignItems:"center",children:[(0,c.jsx)(aO,{control:e,index:n}),(0,c.jsx)(e9.Z,{style:{width:"fit-content",height:"fit-content"},onClick:()=>o(n),children:(0,c.jsx)(aP.default,{})})]}),(0,c.jsx)(ii.Z,{})]},t.id)):(0,c.jsx)(nQ.Z,{variant:"subtitle1",mb:2,fontStyle:"italic",children:"No links defined"}),(0,c.jsx)(e9.Z,{style:{width:"fit-content",height:"fit-content"},onClick:()=>r({url:""}),children:(0,c.jsx)(aT.default,{})})]})}function aO({control:e,index:t}){return(0,c.jsxs)(e8.Z,{gap:2,flexGrow:1,children:[(0,c.jsxs)(e8.Z,{direction:"row",gap:2,children:[(0,c.jsx)(aD.Controller,{control:e,name:`panelDefinition.spec.links.${t}.url`,render:({field:e,fieldState:t})=>(0,c.jsx)(e7.Z,{...e,required:!0,fullWidth:!0,label:"URL",error:!!t.error,helperText:t.error?.message,onChange:t=>{e.onChange(t)}})}),(0,c.jsx)(aD.Controller,{control:e,name:`panelDefinition.spec.links.${t}.name`,render:({field:e,fieldState:t})=>(0,c.jsx)(e7.Z,{...e,fullWidth:!0,label:"Name",defaultValue:"",error:!!t.error,helperText:t.error?.message,onChange:t=>{e.onChange(t)}})}),(0,c.jsx)(aD.Controller,{control:e,name:`panelDefinition.spec.links.${t}.tooltip`,render:({field:e,fieldState:t})=>(0,c.jsx)(e7.Z,{...e,fullWidth:!0,label:"Tooltip",defaultValue:"",error:!!t.error,helperText:t.error?.message,onChange:t=>{e.onChange(t)}})})]}),(0,c.jsxs)(e8.Z,{gap:2,direction:"row",alignItems:"center",children:[(0,c.jsx)(aD.Controller,{control:e,name:`panelDefinition.spec.links.${t}.renderVariables`,render:({field:e})=>(0,c.jsx)(aE.Z,{label:"Render Variables",control:(0,c.jsx)(rd.Z,{...e,checked:e.value,onChange:t=>e.onChange(t.target.checked)})})}),(0,c.jsx)(aD.Controller,{control:e,name:`panelDefinition.spec.links.${t}.targetBlank`,render:({field:e})=>(0,c.jsx)(aE.Z,{label:"Open in new tab",control:(0,c.jsx)(rd.Z,{...e,checked:e.value,onChange:t=>e.onChange(t.target.checked)})})})]})]})}let aj=[{id:"value",label:"Value"},{id:"percentage",label:"Percentage"}];function aR({disablePercentageMode:e,onChange:t,value:n="value"}){return(0,c.jsx)(rz,{label:"Mode",control:(0,c.jsx)(rG,{value:aj.find(e=>e.id===n),options:aj,getOptionLabel:e=>e.label,getOptionDisabled:t=>"percentage"===t.id&&e,onChange:(e,{id:n})=>{t(n)},disableClearable:!0})})}var aN=n(38359);let aA=({children:e})=>(0,c.jsx)(aN.ZP,{item:!0,xs:4,children:(0,c.jsx)(e8.Z,{spacing:3,children:e})}),aF=({children:e})=>(0,c.jsx)(aN.ZP,{container:!0,spacing:8,children:e}),aI=({title:e,children:t,icon:n})=>(0,c.jsxs)(eV.Z,{children:[(0,c.jsxs)(eV.Z,{display:"flex",borderBottom:1,borderColor:"grey.300",marginBottom:e=>e.spacing(1),children:[(0,c.jsx)(nQ.Z,{variant:"overline",component:"h4",children:e}),n&&(0,c.jsx)(eV.Z,{sx:{marginLeft:"auto"},children:n})]}),(0,c.jsx)(e8.Z,{spacing:1,children:t})]});var a_=n(66224);function aL(e){let{message:t}=e;return(0,c.jsx)(e8.Z,{sx:{height:"100%",alignItems:"center",justifyContent:"center"},children:(0,c.jsx)(nQ.Z,{children:t})})}function aV(e){let{resource:t}=e;return(0,c.jsx)(aL,{message:`No ${t}`})}function a$(e){let{variant:t="rounded"}=e;return(0,c.jsx)(e8.Z,{sx:{height:"100%",alignItems:"center",justifyContent:"center",px:1},children:(0,c.jsx)(a_.Z,{variant:t,width:"100%",height:"30%","aria-label":"Loading..."})})}let aB=[{id:"asc",label:"Ascending"},{id:"desc",label:"Descending"}];function az({onChange:e,value:t="desc"}){return(0,c.jsx)(rz,{label:"Sort",control:(0,c.jsx)(rG,{value:aB.find(e=>e.id===t),options:aB,getOptionLabel:e=>e.label,onChange:(t,{id:n})=>{e(n)},disableClearable:!0})})}function aH({onChange:e,value:t,...n}){let r=t=>{e(t)};return(0,c.jsxs)(Z,{"aria-label":"Sort",...n,children:[(0,c.jsx)(O.Z,{onClick:()=>r(void 0),variant:void 0===t?"contained":"outlined",children:"None"}),(0,c.jsx)(O.Z,{onClick:()=>r("asc"),variant:"asc"===t?"contained":"outlined",children:"Asc"}),(0,c.jsx)(O.Z,{onClick:()=>r("desc"),variant:"desc"===t?"contained":"outlined",children:"Desc"})]})}function aW({text:e,fontWeight:t,width:n,height:o,lineHeight:i,maxSize:a,fontSizeOverride:s}){let l=function(){if(!r&&null===(r=document.createElement("canvas").getContext("2d")))throw Error("Canvas context is null.");return r}(),{echartsTheme:u}=eH();if(void 0!==s)return Number(s);let c=u.textStyle,d=Number(c?.fontSize)??12,p=c?.fontFamily??"Lato",f=`${t} ${d}px ${p}`;l.font=f;let h=Math.min(o/i,n/l.measureText(e).width*d);return a?Math.min(h,a):h}let aG=(e,t)=>null===e?"null":"number"==typeof e?eZ(e,t):void 0===e?"":e;(0,eR.D)([iw.N,eA.N,eF.N,eI.N,e_.N,eL.N]);let aU=e=>{let{width:t,height:n,data:r,sparkline:o,showSeriesName:i,format:a,valueFontSize:s}=e,l=eH(),u=r.color,p=aG(r.calculatedValue,a),f=l.container.padding.default,h=aW({text:r?.seriesData?.name??"",fontWeight:400,width:t,height:.125*n,lineHeight:1.2,maxSize:30}),m=i?1.2*h+f:0,g=t-2*f,v=n-m,y=aW({text:p,fontSizeOverride:s,fontWeight:700,width:o?g:.5*g,height:o?.25*v:.9*v,lineHeight:1.2}),b=1.2*y;h=Math.min(.7*y,h);let x=(0,d.useMemo)(()=>{if(void 0===r.seriesData)return l.noDataOption;let e=r.seriesData,t=[];if(void 0!==o){let n={type:"line",name:e.name,data:e.values,zlevel:1,symbol:"none",animation:!1,silent:!0},r=e5()(n,o);t.push(r)}return{title:{show:!1},grid:{show:!1,top:"35%",right:0,bottom:0,left:0,containLabel:!1},xAxis:{type:"time",show:!1,boundaryGap:!1},yAxis:{type:"value",show:!1,min:e=>e.min>=0&&e.min<=1?0:e.min},tooltip:{show:!1},series:t}},[r,l,o]),w=o?"auto":"center";return(0,c.jsxs)(eV.Z,{sx:{height:"100%",width:"100%",display:"flex",flexDirection:"column",justifyContent:w,alignItems:w},children:[i&&(0,c.jsx)(aq,{padding:f,fontSize:h,children:r.seriesData?.name}),(0,c.jsx)(aY,{variant:"h3",color:u,fontSize:y,padding:f,children:p}),void 0!==o&&(0,c.jsx)(e1,{sx:{width:"100%",height:n-m-b},option:x,theme:l.echartsTheme,renderer:"svg"})]})},aq=(0,y.ZP)(nQ.Z,{shouldForwardProp:e=>"padding"!==e&&"fontSize"!==e})(({theme:e,padding:t,fontSize:n})=>({color:e.palette.text.secondary,padding:`${t}px`,fontSize:`${n}px`,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"})),aY=(0,y.ZP)(nQ.Z,{shouldForwardProp:e=>"color"!==e&&"padding"!==e&&"fontSize"!==e&&"sparkline"!==e})(({theme:e,color:t,padding:n,fontSize:r,sparkline:o})=>({color:t??e.palette.text.primary,fontSize:`${r}px`,padding:o?`${n}px ${n}px 0 ${n}px`:` 0 ${n}px`,whiteSpace:"nowrap",lineHeight:1.2}));function aX(e){return(0,S.ZP)("MuiToggleButtonGroup",e)}let aK=(0,C.Z)("MuiToggleButtonGroup",["root","selected","horizontal","vertical","disabled","grouped","groupedHorizontal","groupedVertical","fullWidth","firstButton","lastButton","middleButton"]),aQ=d.createContext({}),aJ=d.createContext(void 0);function a0(e){return(0,S.ZP)("MuiToggleButton",e)}let a1=(0,C.Z)("MuiToggleButton",["root","disabled","selected","standard","primary","secondary","sizeSmall","sizeMedium","sizeLarge","fullWidth"]),a2=e=>{let{classes:t,orientation:n,fullWidth:r,disabled:o}=e,i={root:["root",n,r&&"fullWidth"],grouped:["grouped",`grouped${(0,v.Z)(n)}`,o&&"disabled"],firstButton:["firstButton"],lastButton:["lastButton"],middleButton:["middleButton"]};return(0,h.Z)(i,aX,t)},a5=(0,y.ZP)("div",{name:"MuiToggleButtonGroup",slot:"Root",overridesResolver:(e,t)=>{let{ownerState:n}=e;return[{[`& .${aK.grouped}`]:t.grouped},{[`& .${aK.grouped}`]:t[`grouped${(0,v.Z)(n.orientation)}`]},{[`& .${aK.firstButton}`]:t.firstButton},{[`& .${aK.lastButton}`]:t.lastButton},{[`& .${aK.middleButton}`]:t.middleButton},t.root,"vertical"===n.orientation&&t.vertical,n.fullWidth&&t.fullWidth]}})((0,b.Z)(({theme:e})=>({display:"inline-flex",borderRadius:(e.vars||e).shape.borderRadius,variants:[{props:{orientation:"vertical"},style:{flexDirection:"column",[`& .${aK.grouped}`]:{[`&.${aK.selected} + .${aK.grouped}.${aK.selected}`]:{borderTop:0,marginTop:0}},[`& .${aK.firstButton},& .${aK.middleButton}`]:{borderBottomLeftRadius:0,borderBottomRightRadius:0},[`& .${aK.lastButton},& .${aK.middleButton}`]:{marginTop:-1,borderTop:"1px solid transparent",borderTopLeftRadius:0,borderTopRightRadius:0},[`& .${aK.lastButton}.${a1.disabled},& .${aK.middleButton}.${a1.disabled}`]:{borderTop:"1px solid transparent"}}},{props:{fullWidth:!0},style:{width:"100%"}},{props:{orientation:"horizontal"},style:{[`& .${aK.grouped}`]:{[`&.${aK.selected} + .${aK.grouped}.${aK.selected}`]:{borderLeft:0,marginLeft:0}},[`& .${aK.firstButton},& .${aK.middleButton}`]:{borderTopRightRadius:0,borderBottomRightRadius:0},[`& .${aK.lastButton},& .${aK.middleButton}`]:{marginLeft:-1,borderLeft:"1px solid transparent",borderTopLeftRadius:0,borderBottomLeftRadius:0},[`& .${aK.lastButton}.${a1.disabled},& .${aK.middleButton}.${a1.disabled}`]:{borderLeft:"1px solid transparent"}}}]}))),a3=d.forwardRef(function(e,t){let n=(0,w.i)({props:e,name:"MuiToggleButtonGroup"}),{children:r,className:o,color:i="standard",disabled:a=!1,exclusive:s=!1,fullWidth:l=!1,onChange:u,orientation:p="horizontal",size:h="medium",value:m,...v}=n,y={...n,disabled:a,fullWidth:l,orientation:p,size:h},b=a2(y),x=d.useCallback((e,t)=>{let n;if(!u)return;let r=m&&m.indexOf(t);m&&r>=0?(n=m.slice()).splice(r,1):n=m?m.concat(t):[t],u(e,n)},[u,m]),C=d.useCallback((e,t)=>{u&&u(e,m===t?null:t)},[u,m]),S=d.useMemo(()=>({className:b.grouped,onChange:s?C:x,value:m,size:h,fullWidth:l,color:i,disabled:a}),[b.grouped,s,C,x,m,h,l,i,a]),M=g(r),k=M.length,E=e=>{let t=0===e,n=e===k-1;return t&&n?"":t?b.firstButton:n?b.lastButton:b.middleButton};return(0,c.jsx)(a5,{role:"group",className:(0,f.Z)(b.root,o),ref:t,ownerState:y,...v,children:(0,c.jsx)(aQ.Provider,{value:S,children:M.map((e,t)=>(0,c.jsx)(aJ.Provider,{value:E(t),children:e},t))})})});var a4=n(16819);let a6=e=>{let{classes:t,fullWidth:n,selected:r,disabled:o,size:i,color:a}=e,s={root:["root",r&&"selected",o&&"disabled",n&&"fullWidth",`size${(0,v.Z)(i)}`,a]};return(0,h.Z)(s,a0,t)},a8=(0,y.ZP)(tX.Z,{name:"MuiToggleButton",slot:"Root",overridesResolver:(e,t)=>{let{ownerState:n}=e;return[t.root,t[`size${(0,v.Z)(n.size)}`]]}})((0,b.Z)(({theme:e})=>({...e.typography.button,borderRadius:(e.vars||e).shape.borderRadius,padding:11,border:`1px solid ${(e.vars||e).palette.divider}`,color:(e.vars||e).palette.action.active,[`&.${a1.disabled}`]:{color:(e.vars||e).palette.action.disabled,border:`1px solid ${(e.vars||e).palette.action.disabledBackground}`},"&:hover":{textDecoration:"none",backgroundColor:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,m.Fq)(e.palette.text.primary,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},variants:[{props:{color:"standard"},style:{[`&.${a1.selected}`]:{color:(e.vars||e).palette.text.primary,backgroundColor:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.selectedOpacity})`:(0,m.Fq)(e.palette.text.primary,e.palette.action.selectedOpacity),"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:(0,m.Fq)(e.palette.text.primary,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.selectedOpacity})`:(0,m.Fq)(e.palette.text.primary,e.palette.action.selectedOpacity)}}}}},...Object.entries(e.palette).filter((0,x.Z)()).map(([t])=>({props:{color:t},style:{[`&.${a1.selected}`]:{color:(e.vars||e).palette[t].main,backgroundColor:e.vars?`rgba(${e.vars.palette[t].mainChannel} / ${e.vars.palette.action.selectedOpacity})`:(0,m.Fq)(e.palette[t].main,e.palette.action.selectedOpacity),"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette[t].mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:(0,m.Fq)(e.palette[t].main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette[t].mainChannel} / ${e.vars.palette.action.selectedOpacity})`:(0,m.Fq)(e.palette[t].main,e.palette.action.selectedOpacity)}}}}})),{props:{fullWidth:!0},style:{width:"100%"}},{props:{size:"small"},style:{padding:7,fontSize:e.typography.pxToRem(13)}},{props:{size:"large"},style:{padding:15,fontSize:e.typography.pxToRem(15)}}]}))),a9=d.forwardRef(function(e,t){var n;let{value:r,...o}=d.useContext(aQ),i=d.useContext(aJ),a=(0,a4.Z)({...o,selected:(n=e.value,void 0!==r&&void 0!==n&&(Array.isArray(r)?r.includes(n):n===r))},e),s=(0,w.i)({props:a,name:"MuiToggleButton"}),{children:l,className:u,color:p="standard",disabled:h=!1,disableFocusRipple:m=!1,fullWidth:g=!1,onChange:v,onClick:y,selected:b,size:x="medium",value:C,...S}=s,M={...s,color:p,disabled:h,disableFocusRipple:m,fullWidth:g,size:x},k=a6(M);return(0,c.jsx)(a8,{className:(0,f.Z)(o.className,k.root,u,i||""),disabled:h,focusRipple:!m,ref:t,onClick:e=>{(!y||(y(e,C),!e.defaultPrevented))&&v&&v(e,C)},onChange:v,value:C,ownerState:M,"aria-pressed":b,...S,children:l})}),a7=(0,n(79886).Z)();var se=n(22446);function st({inputRef:e,label:t,color:n,value:r,mode:o,onChange:i,onColorChange:a,onBlur:s,onDelete:l}){let[u,p]=(0,d.useState)(0);return(0,c.jsxs)(e8.Z,{flex:1,direction:"row",alignItems:"center",justifyContent:"space-between",spacing:1,children:[(0,c.jsx)(tz,{label:t,color:n,onColorChange:a}),(0,c.jsx)(rA.Z,{htmlFor:t,children:t}),(0,c.jsx)(e7.Z,{id:t,inputRef:e,type:"number",value:0===r?"":r,placeholder:"0",onChange:i,onBlur:s,onKeyDown:e=>{"Enter"===e.key&&(s(),p(u+1))},InputProps:{endAdornment:"percent"===o?(0,c.jsx)(eV.Z,{paddingX:1,children:"%"}):void 0}},u),(0,c.jsx)(e9.Z,{"aria-label":`delete threshold ${t}`,size:"small",onClick:l,children:(0,c.jsx)(se.default,{})})]})}function sn({thresholds:e,onChange:t,hideDefault:n,disablePercentMode:r}){let{thresholds:{defaultColor:o,palette:i}}=eH(),a=e?.defaultColor??o,[s,l]=(0,d.useState)(e?.steps);(0,d.useEffect)(()=>{l(e?.steps)},[e?.steps]);let u=(0,d.useRef)(null),p=(0,d.useRef)(!1);(0,d.useEffect)(()=>{u.current&&p.current&&(u.current?.focus(),p.current=!1)},[s?.length]);let f=(e,t)=>{l((0,tU.Uy)(s,n=>{let r=n?.[t];r&&(r.value=Number(e.target.value))}))},h=(n,r)=>{void 0!==e&&t((0,tU.Uy)(e,e=>{if(void 0!==e.steps){let t=e.steps[r];t&&(t.color=n)}}))},m=()=>{if(void 0!==s){let n=[...s];n.sort((e,t)=>e.value-t.value),void 0!==e&&t((0,tU.Uy)(e,e=>{e.steps=n}))}},g=n=>{void 0!==e&&t((0,tU.Uy)(e,e=>{e.steps&&e.steps.splice(n,1)}))};return(0,c.jsxs)(aI,{title:"Thresholds",icon:(0,c.jsx)(rV,{description:"Add threshold",children:(0,c.jsx)(e9.Z,{size:"small","aria-label":"add threshold",onClick:()=>{p.current=!0,void 0===e?t({steps:[{value:10}]}):e&&void 0===e.steps?t((0,tU.Uy)(e,e=>{e.steps=[{value:10}]})):t((0,tU.Uy)(e,e=>{let t=e.steps;if(t?.length){let e=t[t.length-1],n=i[t.length]??sr();t.push({color:n,value:(e?.value??0)+10})}else t&&t.push({value:10})}))},children:(0,c.jsx)(aT.default,{})})}),children:[(0,c.jsx)(rz,{label:"Mode",description:"Percentage means thresholds relative to min & max",control:(0,c.jsxs)(a3,{exclusive:!0,disabled:r,value:e?.mode??"absolute",onChange:(n,r)=>{let o="percent"===r?"percent":void 0;void 0!==e?t((0,tU.Uy)(e,e=>{e.mode=o})):t({mode:o})},sx:{height:"36px",marginLeft:"auto"},children:[(0,c.jsx)(a9,{"aria-label":"absolute",value:"absolute",sx:{fontWeight:500},children:"Absolute"}),(0,c.jsx)(a9,{"aria-label":"percent",value:"percent",sx:{fontWeight:500},children:"Percent"})]})}),s&&s.map((t,n)=>(0,c.jsx)(st,{inputRef:n===s.length-1?u:void 0,label:`T${n+1}`,color:t.color??i[n]??a,value:t.value,mode:e?.mode,onColorChange:e=>h(e,n),onChange:e=>{f(e,n)},onDelete:()=>{g(n)},onBlur:m},n)).reverse(),!n&&(0,c.jsxs)(a7,{flex:1,direction:"row",alignItems:"center",spacing:1,children:[(0,c.jsx)(tz,{label:"default",color:a,onColorChange:n=>{void 0!==e?t((0,tU.Uy)(e,e=>{e.defaultColor=n})):t({defaultColor:n})}}),(0,c.jsx)(nQ.Z,{children:"Default"})]})]})}let sr=()=>"#"+Math.floor(0x1000000*Math.random()).toString(16).padStart(6,"0");var so=n(70252);function si(e){return"number"==typeof e}function sa(e){return!!e&&"object"==typeof e&&"function"==typeof e.constructor&&(!0===e.isBigNumber&&"object"==typeof e.constructor.prototype&&!0===e.constructor.prototype.isBigNumber||"function"==typeof e.constructor.isDecimal&&!0===e.constructor.isDecimal(e))}function ss(e){return e&&"object"==typeof e&&!0===Object.getPrototypeOf(e).isComplex||!1}function sl(e){return e&&"object"==typeof e&&!0===Object.getPrototypeOf(e).isFraction||!1}function su(e){return e&&!0===e.constructor.prototype.isUnit||!1}function sc(e){return"string"==typeof e}var sd=Array.isArray;function sp(e){return e&&!0===e.constructor.prototype.isMatrix||!1}function sf(e){return Array.isArray(e)||sp(e)}function sh(e){return e&&e.isDenseMatrix&&!0===e.constructor.prototype.isMatrix||!1}function sm(e){return e&&e.isSparseMatrix&&!0===e.constructor.prototype.isMatrix||!1}function sg(e){return e&&!0===e.constructor.prototype.isRange||!1}function sv(e){return e&&!0===e.constructor.prototype.isIndex||!1}function sy(e){return"boolean"==typeof e}function sb(e){return e&&!0===e.constructor.prototype.isResultSet||!1}function sx(e){return e&&!0===e.constructor.prototype.isHelp||!1}function sw(e){return"function"==typeof e}function sC(e){return e instanceof Date}function sS(e){return e instanceof RegExp}function sM(e){return!!(e&&"object"==typeof e&&e.constructor===Object&&!ss(e)&&!sl(e))}function sk(e){return null===e}function sE(e){return void 0===e}function sD(e){return e&&!0===e.isAccessorNode&&!0===e.constructor.prototype.isNode||!1}function sT(e){return e&&!0===e.isArrayNode&&!0===e.constructor.prototype.isNode||!1}function sP(e){return e&&!0===e.isAssignmentNode&&!0===e.constructor.prototype.isNode||!1}function sZ(e){return e&&!0===e.isBlockNode&&!0===e.constructor.prototype.isNode||!1}function sO(e){return e&&!0===e.isConditionalNode&&!0===e.constructor.prototype.isNode||!1}function sj(e){return e&&!0===e.isConstantNode&&!0===e.constructor.prototype.isNode||!1}function sR(e){return e&&!0===e.isFunctionAssignmentNode&&!0===e.constructor.prototype.isNode||!1}function sN(e){return e&&!0===e.isFunctionNode&&!0===e.constructor.prototype.isNode||!1}function sA(e){return e&&!0===e.isIndexNode&&!0===e.constructor.prototype.isNode||!1}function sF(e){return e&&!0===e.isNode&&!0===e.constructor.prototype.isNode||!1}function sI(e){return e&&!0===e.isObjectNode&&!0===e.constructor.prototype.isNode||!1}function s_(e){return e&&!0===e.isOperatorNode&&!0===e.constructor.prototype.isNode||!1}function sL(e){return e&&!0===e.isParenthesisNode&&!0===e.constructor.prototype.isNode||!1}function sV(e){return e&&!0===e.isRangeNode&&!0===e.constructor.prototype.isNode||!1}function s$(e){return e&&!0===e.isSymbolNode&&!0===e.constructor.prototype.isNode||!1}function sB(e){return e&&!0===e.constructor.prototype.isChain||!1}function sz(e){var t=typeof e;return"object"===t?null===e?"null":Array.isArray(e)?"Array":e instanceof Date?"Date":e instanceof RegExp?"RegExp":sa(e)?"BigNumber":ss(e)?"Complex":sl(e)?"Fraction":sp(e)?"Matrix":su(e)?"Unit":sv(e)?"Index":sg(e)?"Range":sb(e)?"ResultSet":sF(e)?e.type:sB(e)?"Chain":sx(e)?"Help":"Object":"function"===t?"Function":t}function sH(e){var t=typeof e;if("number"===t||"string"===t||"boolean"===t||null==e)return e;if("function"==typeof e.clone)return e.clone();if(Array.isArray(e))return e.map(function(e){return sH(e)});if(e instanceof Date)return new Date(e.valueOf());if(sa(e))return e;if(e instanceof RegExp)throw TypeError("Cannot clone "+e);return sW(e,sH)}function sW(e,t){var n={};for(var r in e)sq(e,r)&&(n[r]=t(e[r]));return n}function sG(e,t){var n,r,o;if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;for(r=0,o=e.length;r<o;r++)if(!sG(e[r],t[r]))return!1;return!0}if("function"==typeof e)return e===t;if(!(e instanceof Object))return e===t;if(Array.isArray(t)||!(t instanceof Object))return!1;for(n in e)if(!(n in t)||!sG(e[n],t[n]))return!1;for(n in t)if(!(n in e))return!1;return!0}function sU(e,t,n){var r,o=!0;Object.defineProperty(e,t,{get:function(){return o&&(r=n(),o=!1),r},set:function(e){r=e,o=!1},configurable:!0,enumerable:!0})}function sq(e,t){return e&&Object.hasOwnProperty.call(e,t)}function sY(e){return Object.keys(e).map(t=>e[t])}var sX=n(8317);function sK(e,t,n,r){function o(r){var o=function(e,t){for(var n={},r=0;r<t.length;r++){var o=t[r],i=e[o];void 0!==i&&(n[o]=i)}return n}(r,t.map(sJ));return function(e,t,n){if(!t.filter(e=>{var t;return!((t=e)&&"?"===t[0])}).every(e=>void 0!==n[e])){var r=t.filter(e=>void 0===n[e]);throw Error('Cannot create function "'.concat(e,'", ')+"some dependencies are missing: ".concat(r.map(e=>'"'.concat(e,'"')).join(", "),"."))}}(e,t,r),n(o)}return o.isFactory=!0,o.fn=e,o.dependencies=t.slice().sort(),r&&(o.meta=r),o}function sQ(e){return"function"==typeof e&&"string"==typeof e.fn&&Array.isArray(e.dependencies)}function sJ(e){return e&&"?"===e[0]?e.slice(1):e}function s0(e){return"boolean"==typeof e||!!isFinite(e)&&e===Math.round(e)}function s1(e,t,n){var r="";if(n){if(n<1)throw Error("size must be in greater than 0");if(!s0(n))throw Error("size must be an integer");if(e>2**(n-1)-1||e<-(2**(n-1)))throw Error("Value must be in range [-2^".concat(n-1,", 2^").concat(n-1,"-1]"));if(!s0(e))throw Error("Value must be an integer");e<0&&(e+=2**n),r="i".concat(n)}var o="";return e<0&&(e=-e,o="-"),"".concat(o).concat({2:"0b",8:"0o",16:"0x"}[t]).concat(e.toString(t)).concat(r)}function s2(e,t){if("function"==typeof t)return t(e);if(e===1/0)return"Infinity";if(e===-1/0)return"-Infinity";if(isNaN(e))return"NaN";var n,r,o="auto";if(t&&(t.notation&&(o=t.notation),si(t)?n=t:si(t.precision)&&(n=t.precision),t.wordSize&&"number"!=typeof(r=t.wordSize)))throw Error('Option "wordSize" must be a number');switch(o){case"fixed":return function(e,t){if(isNaN(e)||!isFinite(e))return String(e);var n=s5(e),r="number"==typeof t?s4(n,n.exponent+1+t):n,o=r.coefficients,i=r.exponent+1,a=i+(t||0);return o.length<a&&(o=o.concat(s6(a-o.length))),i<0&&(o=s6(-i+1).concat(o),i=1),i<o.length&&o.splice(i,0,0===i?"0.":"."),r.sign+o.join("")}(e,n);case"exponential":return s3(e,n);case"engineering":return function(e,t){if(isNaN(e)||!isFinite(e))return String(e);var n=s4(s5(e),t),r=n.exponent,o=n.coefficients,i=r%3==0?r:r<0?r-3-r%3:r-r%3;if(si(t))for(;t>o.length||r-i+1>o.length;)o.push(0);else for(var a=Math.abs(r-i)-(o.length-1),s=0;s<a;s++)o.push(0);for(var l=Math.abs(r-i),u=1;l>0;)u++,l--;var c=o.slice(u).join(""),d=si(t)&&c.length||c.match(/[1-9]/)?"."+c:"",p=o.slice(0,u).join("")+d+"e"+(r>=0?"+":"")+i.toString();return n.sign+p}(e,n);case"bin":return s1(e,2,r);case"oct":return s1(e,8,r);case"hex":return s1(e,16,r);case"auto":return(function(e,t,n){if(isNaN(e)||!isFinite(e))return String(e);var r=n&&void 0!==n.lowerExp?n.lowerExp:-3,o=n&&void 0!==n.upperExp?n.upperExp:5,i=s5(e),a=t?s4(i,t):i;if(a.exponent<r||a.exponent>=o)return s3(e,t);var s=a.coefficients,l=a.exponent;s.length<t&&(s=s.concat(s6(t-s.length))),s=s.concat(s6(l-s.length+1+(s.length<t?t-s.length:0))),s=s6(-l).concat(s);var u=l>0?l:0;return u<s.length-1&&s.splice(u+1,0,"."),a.sign+s.join("")})(e,n,t&&t).replace(/((\.\d*?)(0+))($|e)/,function(){var e=arguments[2],t=arguments[4];return"."!==e?e+t:t});default:throw Error('Unknown notation "'+o+'". Choose "auto", "exponential", "fixed", "bin", "oct", or "hex.')}}function s5(e){var t=String(e).toLowerCase().match(/^(-?)(\d+\.?\d*)(e([+-]?\d+))?$/);if(!t)throw SyntaxError("Invalid number "+e);var n=t[1],r=t[2],o=parseFloat(t[4]||"0"),i=r.indexOf(".");o+=-1!==i?i-1:r.length-1;var a=r.replace(".","").replace(/^0*/,function(e){return o-=e.length,""}).replace(/0*$/,"").split("").map(function(e){return parseInt(e)});return 0===a.length&&(a.push(0),o++),{sign:n,coefficients:a,exponent:o}}function s3(e,t){if(isNaN(e)||!isFinite(e))return String(e);var n=s5(e),r=t?s4(n,t):n,o=r.coefficients,i=r.exponent;o.length<t&&(o=o.concat(s6(t-o.length)));var a=o.shift();return r.sign+a+(o.length>0?"."+o.join(""):"")+"e"+(i>=0?"+":"")+i}function s4(e,t){for(var n={sign:e.sign,coefficients:e.coefficients,exponent:e.exponent},r=n.coefficients;t<=0;)r.unshift(0),n.exponent++,t++;if(r.length>t&&r.splice(t,r.length-t)[0]>=5){var o=t-1;for(r[o]++;10===r[o];)r.pop(),0===o&&(r.unshift(0),n.exponent++,o++),o--,r[o]++}return n}function s6(e){for(var t=[],n=0;n<e;n++)t.push(0);return t}var s8=Number.EPSILON||2220446049250313e-31;function s9(e,t,n){if(null==n)return e===t;if(e===t)return!0;if(isNaN(e)||isNaN(t))return!1;if(isFinite(e)&&isFinite(t)){var r=Math.abs(e-t);return r<s8||r<=Math.max(Math.abs(e),Math.abs(t))*n}return!1}function s7(e,t,n){var r=new e.constructor(2),o="";if(n){if(n<1)throw Error("size must be in greater than 0");if(!s0(n))throw Error("size must be an integer");if(e.greaterThan(r.pow(n-1).sub(1))||e.lessThan(r.pow(n-1).mul(-1)))throw Error("Value must be in range [-2^".concat(n-1,", 2^").concat(n-1,"-1]"));if(!e.isInteger())throw Error("Value must be an integer");e.lessThan(0)&&(e=e.add(r.pow(n))),o="i".concat(n)}switch(t){case 2:return"".concat(e.toBinary()).concat(o);case 8:return"".concat(e.toOctal()).concat(o);case 16:return"".concat(e.toHexadecimal()).concat(o);default:throw Error("Base ".concat(t," not supported "))}}function le(e,t){return void 0!==t?e.toExponential(t-1):e.toExponential()}function lt(e,t){var n=function(e,t){var n;if("number"==typeof e)return s2(e,t);if(sa(e))return function(e,t){if("function"==typeof t)return t(e);if(!e.isFinite())return e.isNaN()?"NaN":e.gt(0)?"Infinity":"-Infinity";var n="auto";if(void 0!==t&&(t.notation&&(n=t.notation),"number"==typeof t?d=t:t.precision&&(d=t.precision),t.wordSize&&"number"!=typeof(p=t.wordSize)))throw Error('Option "wordSize" must be a number');switch(n){case"fixed":return r=e,o=d,r.toFixed(o);case"exponential":return le(e,d);case"engineering":return i=e,a=d,l=(s=i.e)%3==0?s:s<0?s-3-s%3:s-s%3,-1!==(c=(u=i.mul(Math.pow(10,-l))).toPrecision(a)).indexOf("e")&&(c=u.toString()),c+"e"+(s>=0?"+":"")+l.toString();case"bin":return s7(e,2,p);case"oct":return s7(e,8,p);case"hex":return s7(e,16,p);case"auto":var r,o,i,a,s,l,u,c,d,p,f,h=t&&void 0!==t.lowerExp?t.lowerExp:-3,m=t&&void 0!==t.upperExp?t.upperExp:5;if(e.isZero())return"0";var g=e.toSignificantDigits(d),v=g.e;return(v>=h&&v<m?g.toFixed():le(e,d)).replace(/((\.\d*?)(0+))($|e)/,function(){var e=arguments[2],t=arguments[4];return"."!==e?e+t:t});default:throw Error('Unknown notation "'+n+'". Choose "auto", "exponential", "fixed", "bin", "oct", or "hex.')}}(e,t);return(n=e)&&"object"==typeof n&&"number"==typeof n.s&&"number"==typeof n.n&&"number"==typeof n.d?t&&"decimal"===t.fraction?e.toString():e.s*e.n+"/"+e.d:Array.isArray(e)?function e(t,n){if(!Array.isArray(t))return lt(t,n);for(var r="[",o=t.length,i=0;i<o;i++)0!==i&&(r+=", "),r+=e(t[i],n);return r+"]"}(e,t):sc(e)?'"'+e+'"':"function"==typeof e?e.syntax?String(e.syntax):"function":e&&"object"==typeof e?"function"==typeof e.format?e.format(t):e&&e.toString(t)!==({}).toString()?e.toString(t):"{"+Object.keys(e).map(n=>'"'+n+'": '+lt(e[n],t)).join(", ")+"}":String(e)}(e,t);return t&&"object"==typeof t&&"truncate"in t&&n.length>t.truncate?n.substring(0,t.truncate-3)+"...":n}function ln(e,t,n){if(!(this instanceof ln))throw SyntaxError("Constructor must be called with the new operator");this.actual=e,this.expected=t,this.relation=n,this.message="Dimension mismatch ("+(Array.isArray(e)?"["+e.join(", ")+"]":e)+" "+(this.relation||"!=")+" "+(Array.isArray(t)?"["+t.join(", ")+"]":t)+")",this.stack=Error().stack}function lr(e,t,n){if(!(this instanceof lr))throw SyntaxError("Constructor must be called with the new operator");this.index=e,arguments.length<3?(this.min=0,this.max=t):(this.min=t,this.max=n),void 0!==this.min&&this.index<this.min?this.message="Index out of range ("+this.index+" < "+this.min+")":void 0!==this.max&&this.index>=this.max?this.message="Index out of range ("+this.index+" > "+(this.max-1)+")":this.message="Index out of range ("+this.index+")",this.stack=Error().stack}function lo(e){for(var t=[];Array.isArray(e);)t.push(e.length),e=e[0];return t}function li(e,t){if(0===t.length){if(Array.isArray(e))throw new ln(e.length,0)}else!function e(t,n,r){var o,i=t.length;if(i!==n[r])throw new ln(i,n[r]);if(r<n.length-1){var a=r+1;for(o=0;o<i;o++){if(!Array.isArray(t[o]))throw new ln(n.length-1,n.length,"<");e(t[o],n,a)}}else for(o=0;o<i;o++)if(Array.isArray(t[o]))throw new ln(n.length+1,n.length,">")}(e,t,0)}function la(e,t){if(!si(e)||!s0(e))throw TypeError("Index must be an integer (value: "+e+")");if(e<0||"number"==typeof t&&e>=t)throw new lr(e,t)}function ls(e,t,n){if(!Array.isArray(e)||!Array.isArray(t))throw TypeError("Array expected");if(0===t.length)throw Error("Resizing to scalar is not supported");return t.forEach(function(e){if(!si(e)||!s0(e)||e<0)throw TypeError("Invalid size, must contain positive integers (size: "+lt(t)+")")}),function e(t,n,r,o){var i,a,s=t.length,l=n[r],u=Math.min(s,l);if(t.length=l,r<n.length-1){var c=r+1;for(i=0;i<u;i++)Array.isArray(a=t[i])||(a=[a],t[i]=a),e(a,n,c,o);for(i=u;i<l;i++)a=[],t[i]=a,e(a,n,c,o)}else{for(i=0;i<u;i++)for(;Array.isArray(t[i]);)t[i]=t[i][0];for(i=u;i<l;i++)t[i]=o}}(e,t,0,void 0!==n?n:0),e}function ll(e,t){var n=lu(e),r=e.slice(),o=e.indexOf(-1);if(e.indexOf(-1,o+1)>=0)throw Error("More than one wildcard in sizes");if(o>=0){if(t%n==0)r[o]=-t/n;else throw Error("Could not replace wildcard, since "+t+" is no multiple of "+-n)}return r}function lu(e){return e.reduce((e,t)=>e*t,1)}function lc(e,t,n,r){var o=r||lo(e);if(n)for(var i=0;i<n;i++)e=[e],o.unshift(1);for(e=function e(t,n,r){var o,i;if(Array.isArray(t)){var a=r+1;for(o=0,i=t.length;o<i;o++)t[o]=e(t[o],n,a)}else for(var s=r;s<n;s++)t=[t];return t}(e,t,0);o.length<t;)o.push(1);return e}function ld(e,t){for(var n,r=0,o=0;o<e.length;o++){var i=e[o],a=Array.isArray(i);if(0===o&&a&&(r=i.length),a&&i.length!==r)return;var s=a?ld(i,t):t(i);if(void 0===n)n=s;else if(n!==s)return"mixed"}return n}function lp(e,t){return -1!==e.indexOf(t)}function lf(e,t,n,r){if(!(this instanceof lf))throw SyntaxError("Constructor must be called with the new operator");this.fn=e,this.count=t,this.min=n,this.max=r,this.message="Wrong number of arguments in function "+e+" ("+t+" provided, "+n+(null!=r?"-"+r:"")+" expected)",this.stack=Error().stack}ln.prototype=RangeError(),ln.prototype.constructor=RangeError,ln.prototype.name="DimensionError",ln.prototype.isDimensionError=!0,lr.prototype=RangeError(),lr.prototype.constructor=RangeError,lr.prototype.name="IndexError",lr.prototype.isIndexError=!0,lf.prototype=Error(),lf.prototype.constructor=Error,lf.prototype.name="ArgumentsError",lf.prototype.isArgumentsError=!0;var lh={epsilon:1e-12,matrix:"Matrix",number:"number",precision:64,predictable:!1,randomSeed:null},lm=["Matrix","Array"],lg=["number","BigNumber","Fraction"];function lv(e,t,n){var r;void 0!==e[t]&&(r=e[t],-1===n.indexOf(r))&&console.warn('Warning: Unknown value "'+e[t]+'" for configuration option "'+t+'". Available options: '+n.map(e=>JSON.stringify(e)).join(", ")+".")}var ly,lb,lx,lw,lC,lS,lM,lk,lE="0123456789abcdef",lD="2.3025850929940456840179914546843642076011014886287729760333279009675726096773524802359972050895982983419677840422862486334095254650828067566662873690987816894829072083255546808437998948262331985283935053089653777326288461633662222876982198867465436674744042432743651550489343149393914796194044002221051017141748003688084012647080685567743216228355220114804663715659121373450747856947683463616792101806445070648000277502684916746550586856935673420670581136429224554405758925724208241314695689016758940256776311356919292033376587141660230105703089634572075440370847469940168269282808481184289314848524948644871927809676271275775397027668605952496716674183485704422507197965004714951050492214776567636938662976979522110718264549734772662425709429322582798502585509785265383207606726317164309505995087807523710333101197857547331541421808427543863591778117054309827482385045648019095610299291824318237525357709750539565187697510374970888692180205189339507238539205144634197265287286965110862571492198849978748873771345686209167058",lT="3.1415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679821480865132823066470938446095505822317253594081284811174502841027019385211055596446229489549303819644288109756659334461284756482337867831652712019091456485669234603486104543266482133936072602491412737245870066063155881748815209209628292540917153643678925903600113305305488204665213841469519415116094330572703657595919530921861173819326117931051185480744623799627495673518857527248912279381830119491298336733624406566430860213949463952247371907021798609437027705392171762931767523846748184676694051320005681271452635608277857713427577896091736371787214684409012249534301465495853710507922796892589235420199561121290219608640344181598136297747713099605187072113499999983729780499510597317328160963185950244594553469083026425223082533446850352619311881710100031378387528865875332083814206171776691473035982534904287554687311595628638823537875937519577818577805321712268066130019278766111959092164201989380952572010654858632789",lP={precision:20,rounding:4,modulo:1,toExpNeg:-7,toExpPos:21,minE:-9e15,maxE:9e15,crypto:!1},lZ=!0,lO="[DecimalError] ",lj=lO+"Invalid argument: ",lR=lO+"Precision limit exceeded",lN=lO+"crypto unavailable",lA="[object Decimal]",lF=Math.floor,lI=Math.pow,l_=/^0b([01]+(\.[01]*)?|\.[01]+)(p[+-]?\d+)?$/i,lL=/^0x([0-9a-f]+(\.[0-9a-f]*)?|\.[0-9a-f]+)(p[+-]?\d+)?$/i,lV=/^0o([0-7]+(\.[0-7]*)?|\.[0-7]+)(p[+-]?\d+)?$/i,l$=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,lB=lD.length-1,lz=lT.length-1,lH={toStringTag:lA};function lW(e){var t,n,r,o=e.length-1,i="",a=e[0];if(o>0){for(i+=a,t=1;t<o;t++)(n=7-(r=e[t]+"").length)&&(i+=l2(n)),i+=r;(n=7-(r=(a=e[t])+"").length)&&(i+=l2(n))}else if(0===a)return"0";for(;a%10==0;)a/=10;return i+a}function lG(e,t,n){if(e!==~~e||e<t||e>n)throw Error(lj+e)}function lU(e,t,n,r){var o,i,a,s;for(i=e[0];i>=10;i/=10)--t;return--t<0?(t+=7,o=0):(o=Math.ceil((t+1)/7),t%=7),i=lI(10,7-t),s=e[o]%i|0,null==r?t<3?(0==t?s=s/100|0:1==t&&(s=s/10|0),a=n<4&&99999==s||n>3&&49999==s||5e4==s||0==s):a=(n<4&&s+1==i||n>3&&s+1==i/2)&&(e[o+1]/i/100|0)==lI(10,t-2)-1||(s==i/2||0==s)&&(e[o+1]/i/100|0)==0:t<4?(0==t?s=s/1e3|0:1==t?s=s/100|0:2==t&&(s=s/10|0),a=(r||n<4)&&9999==s||!r&&n>3&&4999==s):a=((r||n<4)&&s+1==i||!r&&n>3&&s+1==i/2)&&(e[o+1]/i/1e3|0)==lI(10,t-3)-1,a}function lq(e,t,n){for(var r,o,i=[0],a=0,s=e.length;a<s;){for(o=i.length;o--;)i[o]*=t;for(i[0]+=lE.indexOf(e.charAt(a++)),r=0;r<i.length;r++)i[r]>n-1&&(void 0===i[r+1]&&(i[r+1]=0),i[r+1]+=i[r]/n|0,i[r]%=n)}return i.reverse()}lH.absoluteValue=lH.abs=function(){var e=new this.constructor(this);return e.s<0&&(e.s=1),lX(e)},lH.ceil=function(){return lX(new this.constructor(this),this.e+1,2)},lH.clampedTo=lH.clamp=function(e,t){var n=this.constructor;if(e=new n(e),t=new n(t),!e.s||!t.s)return new n(NaN);if(e.gt(t))throw Error(lj+t);return 0>this.cmp(e)?e:this.cmp(t)>0?t:new n(this)},lH.comparedTo=lH.cmp=function(e){var t,n,r,o,i=this.d,a=(e=new this.constructor(e)).d,s=this.s,l=e.s;if(!i||!a)return s&&l?s!==l?s:i===a?0:!i^s<0?1:-1:NaN;if(!i[0]||!a[0])return i[0]?s:a[0]?-l:0;if(s!==l)return s;if(this.e!==e.e)return this.e>e.e^s<0?1:-1;for(t=0,n=(r=i.length)<(o=a.length)?r:o;t<n;++t)if(i[t]!==a[t])return i[t]>a[t]^s<0?1:-1;return r===o?0:r>o^s<0?1:-1},lH.cosine=lH.cos=function(){var e,t,n=this,r=n.constructor;return n.d?n.d[0]?(e=r.precision,t=r.rounding,r.precision=e+Math.max(n.e,n.sd())+7,r.rounding=1,n=function(e,t){var n,r,o;if(t.isZero())return t;(r=t.d.length)<32?o=(1/ut(4,n=Math.ceil(r/3))).toString():(n=16,o="2.3283064365386962890625e-10"),e.precision+=n,t=ue(e,1,t.times(o),new e(1));for(var i=n;i--;){var a=t.times(t);t=a.times(a).minus(a).times(8).plus(1)}return e.precision-=n,t}(r,un(r,n)),r.precision=e,r.rounding=t,lX(2==lk||3==lk?n.neg():n,e,t,!0)):new r(1):new r(NaN)},lH.cubeRoot=lH.cbrt=function(){var e,t,n,r,o,i,a,s,l,u,c=this.constructor;if(!this.isFinite()||this.isZero())return new c(this);for(lZ=!1,(i=this.s*lI(this.s*this,1/3))&&Math.abs(i)!=1/0?r=new c(i.toString()):(n=lW(this.d),(i=((e=this.e)-n.length+1)%3)&&(n+=1==i||-2==i?"0":"00"),i=lI(n,1/3),e=lF((e+1)/3)-(e%3==(e<0?-1:2)),(r=new c(n=i==1/0?"5e"+e:(n=i.toExponential()).slice(0,n.indexOf("e")+1)+e)).s=this.s),a=(e=c.precision)+3;;)if(r=lY((u=(l=(s=r).times(s).times(s)).plus(this)).plus(this).times(s),u.plus(l),a+2,1),lW(s.d).slice(0,a)===(n=lW(r.d)).slice(0,a)){if("9999"!=(n=n.slice(a-3,a+1))&&(o||"4999"!=n)){+n&&(+n.slice(1)||"5"!=n.charAt(0))||(lX(r,e+1,1),t=!r.times(r).times(r).eq(this));break}if(!o&&(lX(s,e+1,0),s.times(s).times(s).eq(this))){r=s;break}a+=4,o=1}return lZ=!0,lX(r,e,c.rounding,t)},lH.decimalPlaces=lH.dp=function(){var e,t=this.d,n=NaN;if(t){if(n=((e=t.length-1)-lF(this.e/7))*7,e=t[e])for(;e%10==0;e/=10)n--;n<0&&(n=0)}return n},lH.dividedBy=lH.div=function(e){return lY(this,new this.constructor(e))},lH.dividedToIntegerBy=lH.divToInt=function(e){var t=this.constructor;return lX(lY(this,new t(e),0,1,1),t.precision,t.rounding)},lH.equals=lH.eq=function(e){return 0===this.cmp(e)},lH.floor=function(){return lX(new this.constructor(this),this.e+1,3)},lH.greaterThan=lH.gt=function(e){return this.cmp(e)>0},lH.greaterThanOrEqualTo=lH.gte=function(e){var t=this.cmp(e);return 1==t||0===t},lH.hyperbolicCosine=lH.cosh=function(){var e,t,n,r,o,i=this,a=i.constructor,s=new a(1);if(!i.isFinite())return new a(i.s?1/0:NaN);if(i.isZero())return s;n=a.precision,r=a.rounding,a.precision=n+Math.max(i.e,i.sd())+4,a.rounding=1,(o=i.d.length)<32?t=(1/ut(4,e=Math.ceil(o/3))).toString():(e=16,t="2.3283064365386962890625e-10"),i=ue(a,1,i.times(t),new a(1),!0);for(var l,u=e,c=new a(8);u--;)l=i.times(i),i=s.minus(l.times(c.minus(l.times(c))));return lX(i,a.precision=n,a.rounding=r,!0)},lH.hyperbolicSine=lH.sinh=function(){var e,t,n,r,o=this,i=o.constructor;if(!o.isFinite()||o.isZero())return new i(o);if(t=i.precision,n=i.rounding,i.precision=t+Math.max(o.e,o.sd())+4,i.rounding=1,(r=o.d.length)<3)o=ue(i,2,o,o,!0);else{e=(e=1.4*Math.sqrt(r))>16?16:0|e,o=ue(i,2,o=o.times(1/ut(5,e)),o,!0);for(var a,s=new i(5),l=new i(16),u=new i(20);e--;)a=o.times(o),o=o.times(s.plus(a.times(l.times(a).plus(u))))}return i.precision=t,i.rounding=n,lX(o,t,n,!0)},lH.hyperbolicTangent=lH.tanh=function(){var e,t,n=this.constructor;return this.isFinite()?this.isZero()?new n(this):(e=n.precision,t=n.rounding,n.precision=e+7,n.rounding=1,lY(this.sinh(),this.cosh(),n.precision=e,n.rounding=t)):new n(this.s)},lH.inverseCosine=lH.acos=function(){var e=this,t=e.constructor,n=e.abs().cmp(1),r=t.precision,o=t.rounding;return -1!==n?0===n?e.isNeg()?l0(t,r,o):new t(0):new t(NaN):e.isZero()?l0(t,r+4,o).times(.5):(t.precision=r+6,t.rounding=1,e=new t(1).minus(e).div(e.plus(1)).sqrt().atan(),t.precision=r,t.rounding=o,e.times(2))},lH.inverseHyperbolicCosine=lH.acosh=function(){var e,t,n=this,r=n.constructor;return n.lte(1)?new r(n.eq(1)?0:NaN):n.isFinite()?(e=r.precision,t=r.rounding,r.precision=e+Math.max(Math.abs(n.e),n.sd())+4,r.rounding=1,lZ=!1,n=n.times(n).minus(1).sqrt().plus(n),lZ=!0,r.precision=e,r.rounding=t,n.ln()):new r(n)},lH.inverseHyperbolicSine=lH.asinh=function(){var e,t,n=this,r=n.constructor;return!n.isFinite()||n.isZero()?new r(n):(e=r.precision,t=r.rounding,r.precision=e+2*Math.max(Math.abs(n.e),n.sd())+6,r.rounding=1,lZ=!1,n=n.times(n).plus(1).sqrt().plus(n),lZ=!0,r.precision=e,r.rounding=t,n.ln())},lH.inverseHyperbolicTangent=lH.atanh=function(){var e,t,n,r,o=this,i=o.constructor;return o.isFinite()?o.e>=0?new i(o.abs().eq(1)?o.s/0:o.isZero()?o:NaN):(e=i.precision,t=i.rounding,Math.max(r=o.sd(),e)<-(2*o.e)-1)?lX(new i(o),e,t,!0):(i.precision=n=r-o.e,o=lY(o.plus(1),new i(1).minus(o),n+e,1),i.precision=e+4,i.rounding=1,o=o.ln(),i.precision=e,i.rounding=t,o.times(.5)):new i(NaN)},lH.inverseSine=lH.asin=function(){var e,t,n,r,o=this,i=o.constructor;return o.isZero()?new i(o):(t=o.abs().cmp(1),n=i.precision,r=i.rounding,-1!==t)?0===t?((e=l0(i,n+4,r).times(.5)).s=o.s,e):new i(NaN):(i.precision=n+6,i.rounding=1,o=o.div(new i(1).minus(o.times(o)).sqrt().plus(1)).atan(),i.precision=n,i.rounding=r,o.times(2))},lH.inverseTangent=lH.atan=function(){var e,t,n,r,o,i,a,s,l,u=this,c=u.constructor,d=c.precision,p=c.rounding;if(u.isFinite()){if(u.isZero())return new c(u);if(u.abs().eq(1)&&d+4<=lz)return(a=l0(c,d+4,p).times(.25)).s=u.s,a}else{if(!u.s)return new c(NaN);if(d+4<=lz)return(a=l0(c,d+4,p).times(.5)).s=u.s,a}for(c.precision=s=d+10,c.rounding=1,e=n=Math.min(28,s/7+2|0);e;--e)u=u.div(u.times(u).plus(1).sqrt().plus(1));for(lZ=!1,t=Math.ceil(s/7),r=1,l=u.times(u),a=new c(u),o=u;-1!==e;)if(o=o.times(l),i=a.minus(o.div(r+=2)),o=o.times(l),void 0!==(a=i.plus(o.div(r+=2))).d[t])for(e=t;a.d[e]===i.d[e]&&e--;);return n&&(a=a.times(2<<n-1)),lZ=!0,lX(a,c.precision=d,c.rounding=p,!0)},lH.isFinite=function(){return!!this.d},lH.isInteger=lH.isInt=function(){return!!this.d&&lF(this.e/7)>this.d.length-2},lH.isNaN=function(){return!this.s},lH.isNegative=lH.isNeg=function(){return this.s<0},lH.isPositive=lH.isPos=function(){return this.s>0},lH.isZero=function(){return!!this.d&&0===this.d[0]},lH.lessThan=lH.lt=function(e){return 0>this.cmp(e)},lH.lessThanOrEqualTo=lH.lte=function(e){return 1>this.cmp(e)},lH.logarithm=lH.log=function(e){var t,n,r,o,i,a,s,l,u=this.constructor,c=u.precision,d=u.rounding;if(null==e)e=new u(10),t=!0;else{if(n=(e=new u(e)).d,e.s<0||!n||!n[0]||e.eq(1))return new u(NaN);t=e.eq(10)}if(n=this.d,this.s<0||!n||!n[0]||this.eq(1))return new u(n&&!n[0]?-1/0:1!=this.s?NaN:n?0:1/0);if(t){if(n.length>1)i=!0;else{for(o=n[0];o%10==0;)o/=10;i=1!==o}}if(lZ=!1,lU((l=lY(a=l8(this,s=c+5),t?lJ(u,s+10):l8(e,s),s,1)).d,o=c,d))do if(s+=10,l=lY(a=l8(this,s),t?lJ(u,s+10):l8(e,s),s,1),!i){+lW(l.d).slice(o+1,o+15)+1==1e14&&(l=lX(l,c+1,0));break}while(lU(l.d,o+=10,d));return lZ=!0,lX(l,c,d)},lH.minus=lH.sub=function(e){var t,n,r,o,i,a,s,l,u,c,d,p,f=this.constructor;if(e=new f(e),!this.d||!e.d)return this.s&&e.s?this.d?e.s=-e.s:e=new f(e.d||this.s!==e.s?this:NaN):e=new f(NaN),e;if(this.s!=e.s)return e.s=-e.s,this.plus(e);if(u=this.d,p=e.d,s=f.precision,l=f.rounding,!u[0]||!p[0]){if(p[0])e.s=-e.s;else{if(!u[0])return new f(3===l?-0:0);e=new f(this)}return lZ?lX(e,s,l):e}if(n=lF(e.e/7),c=lF(this.e/7),u=u.slice(),i=c-n){for((d=i<0)?(t=u,i=-i,a=p.length):(t=p,n=c,a=u.length),i>(r=Math.max(Math.ceil(s/7),a)+2)&&(i=r,t.length=1),t.reverse(),r=i;r--;)t.push(0);t.reverse()}else{for((d=(r=u.length)<(a=p.length))&&(a=r),r=0;r<a;r++)if(u[r]!=p[r]){d=u[r]<p[r];break}i=0}for(d&&(t=u,u=p,p=t,e.s=-e.s),a=u.length,r=p.length-a;r>0;--r)u[a++]=0;for(r=p.length;r>i;){if(u[--r]<p[r]){for(o=r;o&&0===u[--o];)u[o]=1e7-1;--u[o],u[r]+=1e7}u[r]-=p[r]}for(;0===u[--a];)u.pop();for(;0===u[0];u.shift())--n;return u[0]?(e.d=u,e.e=lQ(u,n),lZ?lX(e,s,l):e):new f(3===l?-0:0)},lH.modulo=lH.mod=function(e){var t,n=this.constructor;return(e=new n(e),this.d&&e.s&&(!e.d||e.d[0]))?e.d&&(!this.d||this.d[0])?(lZ=!1,9==n.modulo?(t=lY(this,e.abs(),0,3,1),t.s*=e.s):t=lY(this,e,0,n.modulo,1),t=t.times(e),lZ=!0,this.minus(t)):lX(new n(this),n.precision,n.rounding):new n(NaN)},lH.naturalExponential=lH.exp=function(){return l6(this)},lH.naturalLogarithm=lH.ln=function(){return l8(this)},lH.negated=lH.neg=function(){var e=new this.constructor(this);return e.s=-e.s,lX(e)},lH.plus=lH.add=function(e){var t,n,r,o,i,a,s,l,u,c,d=this.constructor;if(e=new d(e),!this.d||!e.d)return this.s&&e.s?this.d||(e=new d(e.d||this.s===e.s?this:NaN)):e=new d(NaN),e;if(this.s!=e.s)return e.s=-e.s,this.minus(e);if(u=this.d,c=e.d,s=d.precision,l=d.rounding,!u[0]||!c[0])return c[0]||(e=new d(this)),lZ?lX(e,s,l):e;if(i=lF(this.e/7),r=lF(e.e/7),u=u.slice(),o=i-r){for(o<0?(n=u,o=-o,a=c.length):(n=c,r=i,a=u.length),o>(a=(i=Math.ceil(s/7))>a?i+1:a+1)&&(o=a,n.length=1),n.reverse();o--;)n.push(0);n.reverse()}for((a=u.length)-(o=c.length)<0&&(o=a,n=c,c=u,u=n),t=0;o;)t=(u[--o]=u[o]+c[o]+t)/1e7|0,u[o]%=1e7;for(t&&(u.unshift(t),++r),a=u.length;0==u[--a];)u.pop();return e.d=u,e.e=lQ(u,r),lZ?lX(e,s,l):e},lH.precision=lH.sd=function(e){var t;if(void 0!==e&&!!e!==e&&1!==e&&0!==e)throw Error(lj+e);return this.d?(t=l1(this.d),e&&this.e+1>t&&(t=this.e+1)):t=NaN,t},lH.round=function(){var e=this.constructor;return lX(new e(this),this.e+1,e.rounding)},lH.sine=lH.sin=function(){var e,t,n=this,r=n.constructor;return n.isFinite()?n.isZero()?new r(n):(e=r.precision,t=r.rounding,r.precision=e+Math.max(n.e,n.sd())+7,r.rounding=1,n=function(e,t){var n,r=t.d.length;if(r<3)return t.isZero()?t:ue(e,2,t,t);n=(n=1.4*Math.sqrt(r))>16?16:0|n,t=ue(e,2,t=t.times(1/ut(5,n)),t);for(var o,i=new e(5),a=new e(16),s=new e(20);n--;)o=t.times(t),t=t.times(i.plus(o.times(a.times(o).minus(s))));return t}(r,un(r,n)),r.precision=e,r.rounding=t,lX(lk>2?n.neg():n,e,t,!0)):new r(NaN)},lH.squareRoot=lH.sqrt=function(){var e,t,n,r,o,i,a=this.d,s=this.e,l=this.s,u=this.constructor;if(1!==l||!a||!a[0])return new u(!l||l<0&&(!a||a[0])?NaN:a?this:1/0);for(lZ=!1,0==(l=Math.sqrt(+this))||l==1/0?(((t=lW(a)).length+s)%2==0&&(t+="0"),l=Math.sqrt(t),s=lF((s+1)/2)-(s<0||s%2),r=new u(t=l==1/0?"5e"+s:(t=l.toExponential()).slice(0,t.indexOf("e")+1)+s)):r=new u(l.toString()),n=(s=u.precision)+3;;)if(r=(i=r).plus(lY(this,i,n+2,1)).times(.5),lW(i.d).slice(0,n)===(t=lW(r.d)).slice(0,n)){if("9999"!=(t=t.slice(n-3,n+1))&&(o||"4999"!=t)){+t&&(+t.slice(1)||"5"!=t.charAt(0))||(lX(r,s+1,1),e=!r.times(r).eq(this));break}if(!o&&(lX(i,s+1,0),i.times(i).eq(this))){r=i;break}n+=4,o=1}return lZ=!0,lX(r,s,u.rounding,e)},lH.tangent=lH.tan=function(){var e,t,n=this,r=n.constructor;return n.isFinite()?n.isZero()?new r(n):(e=r.precision,t=r.rounding,r.precision=e+10,r.rounding=1,(n=n.sin()).s=1,n=lY(n,new r(1).minus(n.times(n)).sqrt(),e+10,0),r.precision=e,r.rounding=t,lX(2==lk||4==lk?n.neg():n,e,t,!0)):new r(NaN)},lH.times=lH.mul=function(e){var t,n,r,o,i,a,s,l,u,c=this.constructor,d=this.d,p=(e=new c(e)).d;if(e.s*=this.s,!d||!d[0]||!p||!p[0])return new c(e.s&&(!d||d[0]||p)&&(!p||p[0]||d)?d&&p?0*e.s:e.s/0:NaN);for(n=lF(this.e/7)+lF(e.e/7),(l=d.length)<(u=p.length)&&(i=d,d=p,p=i,a=l,l=u,u=a),i=[],r=a=l+u;r--;)i.push(0);for(r=u;--r>=0;){for(t=0,o=l+r;o>r;)s=i[o]+p[r]*d[o-r-1]+t,i[o--]=s%1e7|0,t=s/1e7|0;i[o]=(i[o]+t)%1e7|0}for(;!i[--a];)i.pop();return t?++n:i.shift(),e.d=i,e.e=lQ(i,n),lZ?lX(e,c.precision,c.rounding):e},lH.toBinary=function(e,t){return ur(this,2,e,t)},lH.toDecimalPlaces=lH.toDP=function(e,t){var n=this,r=n.constructor;return(n=new r(n),void 0===e)?n:(lG(e,0,1e9),void 0===t?t=r.rounding:lG(t,0,8),lX(n,e+n.e+1,t))},lH.toExponential=function(e,t){var n,r=this,o=r.constructor;return void 0===e?n=lK(r,!0):(lG(e,0,1e9),void 0===t?t=o.rounding:lG(t,0,8),n=lK(r=lX(new o(r),e+1,t),!0,e+1)),r.isNeg()&&!r.isZero()?"-"+n:n},lH.toFixed=function(e,t){var n,r,o=this.constructor;return void 0===e?n=lK(this):(lG(e,0,1e9),void 0===t?t=o.rounding:lG(t,0,8),n=lK(r=lX(new o(this),e+this.e+1,t),!1,e+r.e+1)),this.isNeg()&&!this.isZero()?"-"+n:n},lH.toFraction=function(e){var t,n,r,o,i,a,s,l,u,c,d,p,f=this.d,h=this.constructor;if(!f)return new h(this);if(u=n=new h(1),r=l=new h(0),a=(i=(t=new h(r)).e=l1(f)-this.e-1)%7,t.d[0]=lI(10,a<0?7+a:a),null==e)e=i>0?t:u;else{if(!(s=new h(e)).isInt()||s.lt(u))throw Error(lj+s);e=s.gt(t)?i>0?t:u:s}for(lZ=!1,s=new h(lW(f)),c=h.precision,h.precision=i=14*f.length;d=lY(s,t,0,1,1),1!=(o=n.plus(d.times(r))).cmp(e);)n=r,r=o,o=u,u=l.plus(d.times(o)),l=o,o=t,t=s.minus(d.times(o)),s=o;return o=lY(e.minus(n),r,0,1,1),l=l.plus(o.times(u)),n=n.plus(o.times(r)),l.s=u.s=this.s,p=1>lY(u,r,i,1).minus(this).abs().cmp(lY(l,n,i,1).minus(this).abs())?[u,r]:[l,n],h.precision=c,lZ=!0,p},lH.toHexadecimal=lH.toHex=function(e,t){return ur(this,16,e,t)},lH.toNearest=function(e,t){var n=this,r=n.constructor;if(n=new r(n),null==e){if(!n.d)return n;e=new r(1),t=r.rounding}else{if(e=new r(e),void 0===t?t=r.rounding:lG(t,0,8),!n.d)return e.s?n:e;if(!e.d)return e.s&&(e.s=n.s),e}return e.d[0]?(lZ=!1,n=lY(n,e,0,t,1).times(e),lZ=!0,lX(n)):(e.s=n.s,n=e),n},lH.toNumber=function(){return+this},lH.toOctal=function(e,t){return ur(this,8,e,t)},lH.toPower=lH.pow=function(e){var t,n,r,o,i,a,s=this,l=s.constructor,u=+(e=new l(e));if(!s.d||!e.d||!s.d[0]||!e.d[0])return new l(lI(+s,u));if((s=new l(s)).eq(1))return s;if(r=l.precision,i=l.rounding,e.eq(1))return lX(s,r,i);if((t=lF(e.e/7))>=e.d.length-1&&(n=u<0?-u:u)<=0x1fffffffffffff)return o=l5(l,s,n,r),e.s<0?new l(1).div(o):lX(o,r,i);if((a=s.s)<0){if(t<e.d.length-1)return new l(NaN);if((1&e.d[t])==0&&(a=1),0==s.e&&1==s.d[0]&&1==s.d.length)return s.s=a,s}return(t=0!=(n=lI(+s,u))&&isFinite(n)?new l(n+"").e:lF(u*(Math.log("0."+lW(s.d))/Math.LN10+s.e+1)))>l.maxE+1||t<l.minE-1?new l(t>0?a/0:0):(lZ=!1,l.rounding=s.s=1,n=Math.min(12,(t+"").length),(o=l6(e.times(l8(s,r+n)),r)).d&&lU((o=lX(o,r+5,1)).d,r,i)&&(t=r+10,+lW((o=lX(l6(e.times(l8(s,t+n)),t),t+5,1)).d).slice(r+1,r+15)+1==1e14&&(o=lX(o,r+1,0))),o.s=a,lZ=!0,l.rounding=i,lX(o,r,i))},lH.toPrecision=function(e,t){var n,r=this,o=r.constructor;return void 0===e?n=lK(r,r.e<=o.toExpNeg||r.e>=o.toExpPos):(lG(e,1,1e9),void 0===t?t=o.rounding:lG(t,0,8),n=lK(r=lX(new o(r),e,t),e<=r.e||r.e<=o.toExpNeg,e)),r.isNeg()&&!r.isZero()?"-"+n:n},lH.toSignificantDigits=lH.toSD=function(e,t){var n=this.constructor;return void 0===e?(e=n.precision,t=n.rounding):(lG(e,1,1e9),void 0===t?t=n.rounding:lG(t,0,8)),lX(new n(this),e,t)},lH.toString=function(){var e=this.constructor,t=lK(this,this.e<=e.toExpNeg||this.e>=e.toExpPos);return this.isNeg()&&!this.isZero()?"-"+t:t},lH.truncated=lH.trunc=function(){return lX(new this.constructor(this),this.e+1,1)},lH.valueOf=lH.toJSON=function(){var e=this.constructor,t=lK(this,this.e<=e.toExpNeg||this.e>=e.toExpPos);return this.isNeg()?"-"+t:t};var lY=function(){function e(e,t,n){var r,o=0,i=e.length;for(e=e.slice();i--;)r=e[i]*t+o,e[i]=r%n|0,o=r/n|0;return o&&e.unshift(o),e}function t(e,t,n,r){var o,i;if(n!=r)i=n>r?1:-1;else for(o=i=0;o<n;o++)if(e[o]!=t[o]){i=e[o]>t[o]?1:-1;break}return i}function n(e,t,n,r){for(var o=0;n--;)e[n]-=o,o=+(e[n]<t[n]),e[n]=o*r+e[n]-t[n];for(;!e[0]&&e.length>1;)e.shift()}return function(r,o,i,a,s,l){var u,c,d,p,f,h,m,g,v,y,b,x,w,C,S,M,k,E,D,T,P=r.constructor,Z=r.s==o.s?1:-1,O=r.d,j=o.d;if(!O||!O[0]||!j||!j[0])return new P(r.s&&o.s&&(O?!j||O[0]!=j[0]:j)?O&&0==O[0]||!j?0*Z:Z/0:NaN);for(l?(f=1,c=r.e-o.e):(l=1e7,f=7,c=lF(r.e/f)-lF(o.e/f)),D=j.length,k=O.length,y=(v=new P(Z)).d=[],d=0;j[d]==(O[d]||0);d++);if(j[d]>(O[d]||0)&&c--,null==i?(C=i=P.precision,a=P.rounding):C=s?i+(r.e-o.e)+1:i,C<0)y.push(1),h=!0;else{if(C=C/f+2|0,d=0,1==D){for(p=0,j=j[0],C++;(d<k||p)&&C--;d++)S=p*l+(O[d]||0),y[d]=S/j|0,p=S%j|0;h=p||d<k}else{for((p=l/(j[0]+1)|0)>1&&(j=e(j,p,l),O=e(O,p,l),D=j.length,k=O.length),M=D,x=(b=O.slice(0,D)).length;x<D;)b[x++]=0;(T=j.slice()).unshift(0),E=j[0],j[1]>=l/2&&++E;do p=0,(u=t(j,b,D,x))<0?(w=b[0],D!=x&&(w=w*l+(b[1]||0)),(p=w/E|0)>1?(p>=l&&(p=l-1),g=(m=e(j,p,l)).length,x=b.length,1==(u=t(m,b,g,x))&&(p--,n(m,D<g?T:j,g,l))):(0==p&&(u=p=1),m=j.slice()),(g=m.length)<x&&m.unshift(0),n(b,m,x,l),-1==u&&(x=b.length,(u=t(j,b,D,x))<1&&(p++,n(b,D<x?T:j,x,l))),x=b.length):0===u&&(p++,b=[0]),y[d++]=p,u&&b[0]?b[x++]=O[M]||0:(b=[O[M]],x=1);while((M++<k||void 0!==b[0])&&C--);h=void 0!==b[0]}y[0]||y.shift()}if(1==f)v.e=c,lM=h;else{for(d=1,p=y[0];p>=10;p/=10)d++;v.e=d+c*f-1,lX(v,s?i+v.e+1:i,a,h)}return v}}();function lX(e,t,n,r){var o,i,a,s,l,u,c,d,p,f=e.constructor;e:if(null!=t){if(!(d=e.d))return e;for(o=1,s=d[0];s>=10;s/=10)o++;if((i=t-o)<0)i+=7,a=t,l=(c=d[p=0])/lI(10,o-a-1)%10|0;else if((p=Math.ceil((i+1)/7))>=(s=d.length)){if(r){for(;s++<=p;)d.push(0);c=l=0,o=1,i%=7,a=i-7+1}else break e}else{for(o=1,c=s=d[p];s>=10;s/=10)o++;i%=7,l=(a=i-7+o)<0?0:c/lI(10,o-a-1)%10|0}if(r=r||t<0||void 0!==d[p+1]||(a<0?c:c%lI(10,o-a-1)),u=n<4?(l||r)&&(0==n||n==(e.s<0?3:2)):l>5||5==l&&(4==n||r||6==n&&(i>0?a>0?c/lI(10,o-a):0:d[p-1])%10&1||n==(e.s<0?8:7)),t<1||!d[0])return d.length=0,u?(t-=e.e+1,d[0]=lI(10,(7-t%7)%7),e.e=-t||0):d[0]=e.e=0,e;if(0==i?(d.length=p,s=1,p--):(d.length=p+1,s=lI(10,7-i),d[p]=a>0?(c/lI(10,o-a)%lI(10,a)|0)*s:0),u)for(;;){if(0==p){for(i=1,a=d[0];a>=10;a/=10)i++;for(a=d[0]+=s,s=1;a>=10;a/=10)s++;i!=s&&(e.e++,1e7==d[0]&&(d[0]=1));break}if(d[p]+=s,1e7!=d[p])break;d[p--]=0,s=1}for(i=d.length;0===d[--i];)d.pop()}return lZ&&(e.e>f.maxE?(e.d=null,e.e=NaN):e.e<f.minE&&(e.e=0,e.d=[0])),e}function lK(e,t,n){if(!e.isFinite())return l9(e);var r,o=e.e,i=lW(e.d),a=i.length;return t?(n&&(r=n-a)>0?i=i.charAt(0)+"."+i.slice(1)+l2(r):a>1&&(i=i.charAt(0)+"."+i.slice(1)),i=i+(e.e<0?"e":"e+")+e.e):o<0?(i="0."+l2(-o-1)+i,n&&(r=n-a)>0&&(i+=l2(r))):o>=a?(i+=l2(o+1-a),n&&(r=n-o-1)>0&&(i=i+"."+l2(r))):((r=o+1)<a&&(i=i.slice(0,r)+"."+i.slice(r)),n&&(r=n-a)>0&&(o+1===a&&(i+="."),i+=l2(r))),i}function lQ(e,t){var n=e[0];for(t*=7;n>=10;n/=10)t++;return t}function lJ(e,t,n){if(t>lB)throw lZ=!0,n&&(e.precision=n),Error(lR);return lX(new e(lD),t,1,!0)}function l0(e,t,n){if(t>lz)throw Error(lR);return lX(new e(lT),t,n,!0)}function l1(e){var t=e.length-1,n=7*t+1;if(t=e[t]){for(;t%10==0;t/=10)n--;for(t=e[0];t>=10;t/=10)n++}return n}function l2(e){for(var t="";e--;)t+="0";return t}function l5(e,t,n,r){var o,i=new e(1),a=Math.ceil(r/7+4);for(lZ=!1;;){if(n%2&&uo((i=i.times(t)).d,a)&&(o=!0),0===(n=lF(n/2))){n=i.d.length-1,o&&0===i.d[n]&&++i.d[n];break}uo((t=t.times(t)).d,a)}return lZ=!0,i}function l3(e){return 1&e.d[e.d.length-1]}function l4(e,t,n){for(var r,o,i=new e(t[0]),a=0;++a<t.length;){if(!(o=new e(t[a])).s){i=o;break}((r=i.cmp(o))===n||0===r&&i.s===n)&&(i=o)}return i}function l6(e,t){var n,r,o,i,a,s,l,u=0,c=0,d=0,p=e.constructor,f=p.rounding,h=p.precision;if(!e.d||!e.d[0]||e.e>17)return new p(e.d?e.d[0]?e.s<0?0:1/0:1:e.s?e.s<0?0:e:0/0);for(null==t?(lZ=!1,l=h):l=t,s=new p(.03125);e.e>-2;)e=e.times(s),d+=5;for(l+=r=Math.log(lI(2,d))/Math.LN10*2+5|0,n=i=a=new p(1),p.precision=l;;){if(i=lX(i.times(e),l,1),n=n.times(++c),lW((s=a.plus(lY(i,n,l,1))).d).slice(0,l)===lW(a.d).slice(0,l)){for(o=d;o--;)a=lX(a.times(a),l,1);if(null!=t)return p.precision=h,a;if(!(u<3&&lU(a.d,l-r,f,u)))return lX(a,p.precision=h,f,lZ=!0);p.precision=l+=10,n=i=s=new p(1),c=0,u++}a=s}}function l8(e,t){var n,r,o,i,a,s,l,u,c,d,p,f=1,h=e,m=h.d,g=h.constructor,v=g.rounding,y=g.precision;if(h.s<0||!m||!m[0]||!h.e&&1==m[0]&&1==m.length)return new g(m&&!m[0]?-1/0:1!=h.s?NaN:m?0:h);if(null==t?(lZ=!1,c=y):c=t,g.precision=c+=10,r=(n=lW(m)).charAt(0),!(15e14>Math.abs(i=h.e)))return u=lJ(g,c+2,y).times(i+""),h=l8(new g(r+"."+n.slice(1)),c-10).plus(u),g.precision=y,null==t?lX(h,y,v,lZ=!0):h;for(;r<7&&1!=r||1==r&&n.charAt(1)>3;)r=(n=lW((h=h.times(e)).d)).charAt(0),f++;for(i=h.e,r>1?(h=new g("0."+n),i++):h=new g(r+"."+n.slice(1)),d=h,l=a=h=lY(h.minus(1),h.plus(1),c,1),p=lX(h.times(h),c,1),o=3;;){if(a=lX(a.times(p),c,1),lW((u=l.plus(lY(a,new g(o),c,1))).d).slice(0,c)===lW(l.d).slice(0,c)){if(l=l.times(2),0!==i&&(l=l.plus(lJ(g,c+2,y).times(i+""))),l=lY(l,new g(f),c,1),null!=t)return g.precision=y,l;if(!lU(l.d,c-10,v,s))return lX(l,g.precision=y,v,lZ=!0);g.precision=c+=10,u=a=h=lY(d.minus(1),d.plus(1),c,1),p=lX(h.times(h),c,1),o=s=1}l=u,o+=2}}function l9(e){return String(e.s*e.s/0)}function l7(e,t){var n,r,o;for((n=t.indexOf("."))>-1&&(t=t.replace(".","")),(r=t.search(/e/i))>0?(n<0&&(n=r),n+=+t.slice(r+1),t=t.substring(0,r)):n<0&&(n=t.length),r=0;48===t.charCodeAt(r);r++);for(o=t.length;48===t.charCodeAt(o-1);--o);if(t=t.slice(r,o)){if(o-=r,e.e=n=n-r-1,e.d=[],r=(n+1)%7,n<0&&(r+=7),r<o){for(r&&e.d.push(+t.slice(0,r)),o-=7;r<o;)e.d.push(+t.slice(r,r+=7));r=7-(t=t.slice(r)).length}else r-=o;for(;r--;)t+="0";e.d.push(+t),lZ&&(e.e>e.constructor.maxE?(e.d=null,e.e=NaN):e.e<e.constructor.minE&&(e.e=0,e.d=[0]))}else e.e=0,e.d=[0];return e}function ue(e,t,n,r,o){var i,a,s,l,u=e.precision,c=Math.ceil(u/7);for(lZ=!1,l=n.times(n),s=new e(r);;){if(a=lY(s.times(l),new e(t++*t++),u,1),s=o?r.plus(a):r.minus(a),r=lY(a.times(l),new e(t++*t++),u,1),void 0!==(a=s.plus(r)).d[c]){for(i=c;a.d[i]===s.d[i]&&i--;);if(-1==i)break}i=s,s=r,r=a,a=i}return lZ=!0,a.d.length=c+1,a}function ut(e,t){for(var n=e;--t;)n*=e;return n}function un(e,t){var n,r=t.s<0,o=l0(e,e.precision,1),i=o.times(.5);if((t=t.abs()).lte(i))return lk=r?4:1,t;if((n=t.divToInt(o)).isZero())lk=r?3:2;else{if((t=t.minus(n.times(o))).lte(i))return lk=l3(n)?r?2:3:r?4:1,t;lk=l3(n)?r?1:4:r?3:2}return t.minus(o).abs()}function ur(e,t,n,r){var o,i,a,s,l,u,c,d,p,f=e.constructor,h=void 0!==n;if(h?(lG(n,1,1e9),void 0===r?r=f.rounding:lG(r,0,8)):(n=f.precision,r=f.rounding),e.isFinite()){for(a=(c=lK(e)).indexOf("."),h?(o=2,16==t?n=4*n-3:8==t&&(n=3*n-2)):o=t,a>=0&&(c=c.replace(".",""),(p=new f(1)).e=c.length-a,p.d=lq(lK(p),10,o),p.e=p.d.length),i=l=(d=lq(c,10,o)).length;0==d[--l];)d.pop();if(d[0]){if(a<0?i--:((e=new f(e)).d=d,e.e=i,d=(e=lY(e,p,n,r,0,o)).d,i=e.e,u=lM),a=d[n],s=o/2,u=u||void 0!==d[n+1],u=r<4?(void 0!==a||u)&&(0===r||r===(e.s<0?3:2)):a>s||a===s&&(4===r||u||6===r&&1&d[n-1]||r===(e.s<0?8:7)),d.length=n,u)for(;++d[--n]>o-1;)d[n]=0,n||(++i,d.unshift(1));for(l=d.length;!d[l-1];--l);for(a=0,c="";a<l;a++)c+=lE.charAt(d[a]);if(h){if(l>1){if(16==t||8==t){for(a=16==t?4:3,--l;l%a;l++)c+="0";for(l=(d=lq(c,o,t)).length;!d[l-1];--l);for(a=1,c="1.";a<l;a++)c+=lE.charAt(d[a])}else c=c.charAt(0)+"."+c.slice(1)}c=c+(i<0?"p":"p+")+i}else if(i<0){for(;++i;)c="0"+c;c="0."+c}else if(++i>l)for(i-=l;i--;)c+="0";else i<l&&(c=c.slice(0,i)+"."+c.slice(i))}else c=h?"0p+0":"0";c=(16==t?"0x":2==t?"0b":8==t?"0o":"")+c}else c=l9(e);return e.s<0?"-"+c:c}function uo(e,t){if(e.length>t)return e.length=t,!0}function ui(e){return new this(e).abs()}function ua(e){return new this(e).acos()}function us(e){return new this(e).acosh()}function ul(e,t){return new this(e).plus(t)}function uu(e){return new this(e).asin()}function uc(e){return new this(e).asinh()}function ud(e){return new this(e).atan()}function up(e){return new this(e).atanh()}function uf(e,t){e=new this(e),t=new this(t);var n,r=this.precision,o=this.rounding,i=r+4;return e.s&&t.s?e.d||t.d?!t.d||e.isZero()?(n=t.s<0?l0(this,r,o):new this(0)).s=e.s:!e.d||t.isZero()?(n=l0(this,i,1).times(.5)).s=e.s:t.s<0?(this.precision=i,this.rounding=1,n=this.atan(lY(e,t,i,1)),t=l0(this,i,1),this.precision=r,this.rounding=o,n=e.s<0?n.minus(t):n.plus(t)):n=this.atan(lY(e,t,i,1)):(n=l0(this,i,1).times(t.s>0?.25:.75)).s=e.s:n=new this(NaN),n}function uh(e){return new this(e).cbrt()}function um(e){return lX(e=new this(e),e.e+1,2)}function ug(e,t,n){return new this(e).clamp(t,n)}function uv(e){if(!e||"object"!=typeof e)throw Error(lO+"Object expected");var t,n,r,o=!0===e.defaults,i=["precision",1,1e9,"rounding",0,8,"toExpNeg",-9e15,0,"toExpPos",0,9e15,"maxE",0,9e15,"minE",-9e15,0,"modulo",0,9];for(t=0;t<i.length;t+=3)if(n=i[t],o&&(this[n]=lP[n]),void 0!==(r=e[n])){if(lF(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(lj+n+": "+r)}if(n="crypto",o&&(this[n]=lP[n]),void 0!==(r=e[n])){if(!0===r||!1===r||0===r||1===r){if(r){if("undefined"!=typeof crypto&&crypto&&(crypto.getRandomValues||crypto.randomBytes))this[n]=!0;else throw Error(lN)}else this[n]=!1}else throw Error(lj+n+": "+r)}return this}function uy(e){return new this(e).cos()}function ub(e){return new this(e).cosh()}function ux(e,t){return new this(e).div(t)}function uw(e){return new this(e).exp()}function uC(e){return lX(e=new this(e),e.e+1,3)}function uS(){var e,t,n=new this(0);for(e=0,lZ=!1;e<arguments.length;)if(t=new this(arguments[e++]),t.d)n.d&&(n=n.plus(t.times(t)));else{if(t.s)return lZ=!0,new this(1/0);n=t}return lZ=!0,n.sqrt()}function uM(e){return e instanceof uW||e&&e.toStringTag===lA||!1}function uk(e){return new this(e).ln()}function uE(e,t){return new this(e).log(t)}function uD(e){return new this(e).log(2)}function uT(e){return new this(e).log(10)}function uP(){return l4(this,arguments,-1)}function uZ(){return l4(this,arguments,1)}function uO(e,t){return new this(e).mod(t)}function uj(e,t){return new this(e).mul(t)}function uR(e,t){return new this(e).pow(t)}function uN(e){var t,n,r,o,i=0,a=new this(1),s=[];if(void 0===e?e=this.precision:lG(e,1,1e9),r=Math.ceil(e/7),this.crypto){if(crypto.getRandomValues)for(t=crypto.getRandomValues(new Uint32Array(r));i<r;)(o=t[i])>=429e7?t[i]=crypto.getRandomValues(new Uint32Array(1))[0]:s[i++]=o%1e7;else if(crypto.randomBytes){for(t=crypto.randomBytes(r*=4);i<r;)(o=t[i]+(t[i+1]<<8)+(t[i+2]<<16)+((127&t[i+3])<<24))>=214e7?crypto.randomBytes(4).copy(t,i):(s.push(o%1e7),i+=4);i=r/4}else throw Error(lN)}else for(;i<r;)s[i++]=1e7*Math.random()|0;for(r=s[--i],e%=7,r&&e&&(o=lI(10,7-e),s[i]=(r/o|0)*o);0===s[i];i--)s.pop();if(i<0)n=0,s=[0];else{for(n=-1;0===s[0];n-=7)s.shift();for(r=1,o=s[0];o>=10;o/=10)r++;r<7&&(n-=7-r)}return a.e=n,a.d=s,a}function uA(e){return lX(e=new this(e),e.e+1,this.rounding)}function uF(e){return(e=new this(e)).d?e.d[0]?e.s:0*e.s:e.s||NaN}function uI(e){return new this(e).sin()}function u_(e){return new this(e).sinh()}function uL(e){return new this(e).sqrt()}function uV(e,t){return new this(e).sub(t)}function u$(){var e=0,t=arguments,n=new this(t[0]);for(lZ=!1;n.s&&++e<t.length;)n=n.plus(t[e]);return lZ=!0,lX(n,this.precision,this.rounding)}function uB(e){return new this(e).tan()}function uz(e){return new this(e).tanh()}function uH(e){return lX(e=new this(e),e.e+1,1)}lH[Symbol.for("nodejs.util.inspect.custom")]=lH.toString,lH[Symbol.toStringTag]="Decimal";var uW=lH.constructor=function e(t){var n,r,o;function i(e){var t,n,r;if(!(this instanceof i))return new i(e);if(this.constructor=i,uM(e)){this.s=e.s,lZ?!e.d||e.e>i.maxE?(this.e=NaN,this.d=null):e.e<i.minE?(this.e=0,this.d=[0]):(this.e=e.e,this.d=e.d.slice()):(this.e=e.e,this.d=e.d?e.d.slice():e.d);return}if("number"==(r=typeof e)){if(0===e){this.s=1/e<0?-1:1,this.e=0,this.d=[0];return}if(e<0?(e=-e,this.s=-1):this.s=1,e===~~e&&e<1e7){for(t=0,n=e;n>=10;n/=10)t++;lZ?t>i.maxE?(this.e=NaN,this.d=null):t<i.minE?(this.e=0,this.d=[0]):(this.e=t,this.d=[e]):(this.e=t,this.d=[e]);return}if(0*e!=0){e||(this.s=NaN),this.e=NaN,this.d=null;return}return l7(this,e.toString())}if("string"===r)return 45===(n=e.charCodeAt(0))?(e=e.slice(1),this.s=-1):(43===n&&(e=e.slice(1)),this.s=1),l$.test(e)?l7(this,e):function(e,t){var n,r,o,i,a,s,l,u,c;if(t.indexOf("_")>-1){if(t=t.replace(/(\d)_(?=\d)/g,"$1"),l$.test(t))return l7(e,t)}else if("Infinity"===t||"NaN"===t)return+t||(e.s=NaN),e.e=NaN,e.d=null,e;if(lL.test(t))n=16,t=t.toLowerCase();else if(l_.test(t))n=2;else if(lV.test(t))n=8;else throw Error(lj+t);for((i=t.search(/p/i))>0?(l=+t.slice(i+1),t=t.substring(2,i)):t=t.slice(2),a=(i=t.indexOf("."))>=0,r=e.constructor,a&&(i=(s=(t=t.replace(".","")).length)-i,o=l5(r,new r(n),i,2*i)),i=c=(u=lq(t,n,1e7)).length-1;0===u[i];--i)u.pop();return i<0?new r(0*e.s):(e.e=lQ(u,c),e.d=u,lZ=!1,a&&(e=lY(e,o,4*s)),l&&(e=e.times(54>Math.abs(l)?lI(2,l):uW.pow(2,l))),lZ=!0,e)}(this,e);if("bigint"===r)return e<0?(e=-e,this.s=-1):this.s=1,l7(this,e.toString());throw Error(lj+e)}if(i.prototype=lH,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.EUCLID=9,i.config=i.set=uv,i.clone=e,i.isDecimal=uM,i.abs=ui,i.acos=ua,i.acosh=us,i.add=ul,i.asin=uu,i.asinh=uc,i.atan=ud,i.atanh=up,i.atan2=uf,i.cbrt=uh,i.ceil=um,i.clamp=ug,i.cos=uy,i.cosh=ub,i.div=ux,i.exp=uw,i.floor=uC,i.hypot=uS,i.ln=uk,i.log=uE,i.log10=uT,i.log2=uD,i.max=uP,i.min=uZ,i.mod=uO,i.mul=uj,i.pow=uR,i.random=uN,i.round=uA,i.sign=uF,i.sin=uI,i.sinh=u_,i.sqrt=uL,i.sub=uV,i.sum=u$,i.tan=uB,i.tanh=uz,i.trunc=uH,void 0===t&&(t={}),t&&!0!==t.defaults)for(n=0,o=["precision","rounding","toExpNeg","toExpPos","maxE","minE","modulo","crypto"];n<o.length;)t.hasOwnProperty(r=o[n++])||(t[r]=this[r]);return i.config(t),i}(lP);lD=new uW(lD),lT=new uW(lT);var uG={createBigNumberClass:sK("BigNumber",["?on","config"],e=>{var{on:t,config:n}=e,r=uW.clone({precision:n.precision,modulo:uW.EUCLID});return r.prototype=Object.create(r.prototype),r.prototype.type="BigNumber",r.prototype.isBigNumber=!0,r.prototype.toJSON=function(){return{mathjs:"BigNumber",value:this.toString()}},r.fromJSON=function(e){return new r(e.value)},t&&t("config",function(e,t){e.precision!==t.precision&&r.config({precision:e.precision})}),r},{isClass:!0})},uU={createMatrixClass:sK("Matrix",[],()=>{function e(){if(!(this instanceof e))throw SyntaxError("Constructor must be called with the new operator")}return e.prototype.type="Matrix",e.prototype.isMatrix=!0,e.prototype.storage=function(){throw Error("Cannot invoke storage on a Matrix interface")},e.prototype.datatype=function(){throw Error("Cannot invoke datatype on a Matrix interface")},e.prototype.create=function(e,t){throw Error("Cannot invoke create on a Matrix interface")},e.prototype.subset=function(e,t,n){throw Error("Cannot invoke subset on a Matrix interface")},e.prototype.get=function(e){throw Error("Cannot invoke get on a Matrix interface")},e.prototype.set=function(e,t,n){throw Error("Cannot invoke set on a Matrix interface")},e.prototype.resize=function(e,t){throw Error("Cannot invoke resize on a Matrix interface")},e.prototype.reshape=function(e,t){throw Error("Cannot invoke reshape on a Matrix interface")},e.prototype.clone=function(){throw Error("Cannot invoke clone on a Matrix interface")},e.prototype.size=function(){throw Error("Cannot invoke size on a Matrix interface")},e.prototype.map=function(e,t){throw Error("Cannot invoke map on a Matrix interface")},e.prototype.forEach=function(e){throw Error("Cannot invoke forEach on a Matrix interface")},e.prototype[Symbol.iterator]=function(){throw Error("Cannot iterate a Matrix interface")},e.prototype.toArray=function(){throw Error("Cannot invoke toArray on a Matrix interface")},e.prototype.valueOf=function(){throw Error("Cannot invoke valueOf on a Matrix interface")},e.prototype.format=function(e){throw Error("Cannot invoke format on a Matrix interface")},e.prototype.toString=function(){throw Error("Cannot invoke toString on a Matrix interface")},e},{isClass:!0})},uq={MatrixDependencies:uU,createDenseMatrixClass:sK("DenseMatrix",["Matrix"],e=>{var{Matrix:t}=e;function n(e,t){if(!(this instanceof n))throw SyntaxError("Constructor must be called with the new operator");if(t&&!sc(t))throw Error("Invalid datatype: "+t);if(sp(e))"DenseMatrix"===e.type?(this._data=sH(e._data),this._size=sH(e._size)):(this._data=e.toArray(),this._size=e.size()),this._datatype=t||e._datatype;else if(e&&sd(e.data)&&sd(e.size))this._data=e.data,this._size=e.size,li(this._data,this._size),this._datatype=t||e.datatype;else if(sd(e))this._data=function e(t){for(var n=0,r=t.length;n<r;n++){var o=t[n];sd(o)?t[n]=e(o):o&&!0===o.isMatrix&&(t[n]=e(o.valueOf()))}return t}(e),this._size=lo(this._data),li(this._data,this._size),this._datatype=t;else if(e)throw TypeError("Unsupported type of data ("+sz(e)+")");else this._data=[],this._size=[0],this._datatype=t}function r(e,t,n){if(0===t.length){for(var r=e._data;sd(r);)r=r[0];return r}return e._size=t.slice(0),e._data=ls(e._data,e._size,n),e}function o(e,t,n){for(var o=e._size.slice(0),i=!1;o.length<t.length;)o.push(0),i=!0;for(var a=0,s=t.length;a<s;a++)t[a]>o[a]&&(o[a]=t[a],i=!0);i&&r(e,o,n)}return n.prototype=new t,n.prototype.createDenseMatrix=function(e,t){return new n(e,t)},n.prototype.type="DenseMatrix",n.prototype.isDenseMatrix=!0,n.prototype.getDataType=function(){return ld(this._data,sz)},n.prototype.storage=function(){return"dense"},n.prototype.datatype=function(){return this._datatype},n.prototype.create=function(e,t){return new n(e,t)},n.prototype.subset=function(e,t,r){switch(arguments.length){case 1:return function(e,t){if(!sv(t))throw TypeError("Invalid index");if(t.isScalar())return e.get(t.min());var r=t.size();if(r.length!==e._size.length)throw new ln(r.length,e._size.length);for(var o=t.min(),i=t.max(),a=0,s=e._size.length;a<s;a++)la(o[a],e._size[a]),la(i[a],e._size[a]);return new n(function e(t,n,r,o){var i=o===r-1,a=n.dimension(o);return i?a.map(function(e){return la(e,t.length),t[e]}).valueOf():a.map(function(i){return la(i,t.length),e(t[i],n,r,o+1)}).valueOf()}(e._data,t,r.length,0),e._datatype)}(this,e);case 2:case 3:return function(e,t,n,r){if(!t||!0!==t.isIndex)throw TypeError("Invalid index");var i,a=t.size(),s=t.isScalar();if(sp(n)?(i=n.size(),n=n.valueOf()):i=lo(n),s){if(0!==i.length)throw TypeError("Scalar expected");e.set(t.min(),n,r)}else{if(a.length<e._size.length)throw new ln(a.length,e._size.length,"<");if(i.length<a.length){for(var l=0,u=0;1===a[l]&&1===i[l];)l++;for(;1===a[l];)u++,l++;n=lc(n,a.length,u,i)}if(!sG(a,i))throw new ln(a,i,">");o(e,t.max().map(function(e){return e+1}),r);var c=a.length;(function e(t,n,r,o,i){var a=i===o-1,s=n.dimension(i);a?s.forEach(function(e,n){la(e),t[e]=r[n[0]]}):s.forEach(function(a,s){la(a),e(t[a],n,r[s[0]],o,i+1)})})(e._data,t,n,c,0)}return e}(this,e,t,r);default:throw SyntaxError("Wrong number of arguments")}},n.prototype.get=function(e){if(!sd(e))throw TypeError("Array expected");if(e.length!==this._size.length)throw new ln(e.length,this._size.length);for(var t=0;t<e.length;t++)la(e[t],this._size[t]);for(var n=this._data,r=0,o=e.length;r<o;r++){var i=e[r];la(i,n.length),n=n[i]}return n},n.prototype.set=function(e,t,n){if(!sd(e))throw TypeError("Array expected");if(e.length<this._size.length)throw new ln(e.length,this._size.length,"<");o(this,e.map(function(e){return e+1}),n);var r,i,a,s=this._data;for(r=0,i=e.length-1;r<i;r++)la(a=e[r],s.length),s=s[a];return la(a=e[e.length-1],s.length),s[a]=t,this},n.prototype.resize=function(e,t,n){if(!sf(e))throw TypeError("Array or Matrix expected");var o=e.valueOf().map(e=>Array.isArray(e)&&1===e.length?e[0]:e);return r(n?this.clone():this,o,t)},n.prototype.reshape=function(e,t){var n=t?this.clone():this;n._data=function(e,t){var n=function(e){if(!Array.isArray(e))return e;var t=[];return e.forEach(function e(n){Array.isArray(n)?n.forEach(e):t.push(n)}),t}(e),r=n.length;if(!Array.isArray(e)||!Array.isArray(t))throw TypeError("Array expected");if(0===t.length)throw new ln(0,r,"!=");var o=lu(t=ll(t,r));if(r!==o)throw new ln(o,r,"!=");try{return function(e,t){for(var n,r=e,o=t.length-1;o>0;o--){var i=t[o];n=[];for(var a=r.length/i,s=0;s<a;s++)n.push(r.slice(s*i,(s+1)*i));r=n}return r}(n,t)}catch(e){if(e instanceof ln)throw new ln(o,r,"!=");throw e}}(n._data,e);var r=n._size.reduce((e,t)=>e*t);return n._size=ll(e,r),n},n.prototype.clone=function(){return new n({data:sH(this._data),size:sH(this._size),datatype:this._datatype})},n.prototype.size=function(){return this._size.slice(0)},n.prototype.map=function(e){var t=this,r=function n(r,o){return sd(r)?r.map(function(e,t){return n(e,o.concat(t))}):e(r,o,t)}(this._data,[]),o=void 0!==this._datatype?ld(r,sz):void 0;return new n(r,o)},n.prototype.forEach=function(e){var t=this;!function n(r,o){sd(r)?r.forEach(function(e,t){n(e,o.concat(t))}):e(r,o,t)}(this._data,[])},n.prototype[Symbol.iterator]=function*(){var e=function* e(t,n){if(sd(t))for(var r=0;r<t.length;r++)yield*e(t[r],n.concat(r));else yield{value:t,index:n}};yield*e(this._data,[])},n.prototype.rows=function(){var e=[];if(2!==this.size().length)throw TypeError("Rows can only be returned for a 2D matrix.");for(var t of this._data)e.push(new n([t],this._datatype));return e},n.prototype.columns=function(){var e=this,t=[],r=this.size();if(2!==r.length)throw TypeError("Rows can only be returned for a 2D matrix.");for(var o=this._data,i=function(r){var i=o.map(e=>[e[r]]);t.push(new n(i,e._datatype))},a=0;a<r[1];a++)i(a);return t},n.prototype.toArray=function(){return sH(this._data)},n.prototype.valueOf=function(){return this._data},n.prototype.format=function(e){return lt(this._data,e)},n.prototype.toString=function(){return lt(this._data)},n.prototype.toJSON=function(){return{mathjs:"DenseMatrix",data:this._data,size:this._size,datatype:this._datatype}},n.prototype.diagonal=function(e){if(e){if(sa(e)&&(e=e.toNumber()),!si(e)||!s0(e))throw TypeError("The parameter k must be an integer number")}else e=0;for(var t=e>0?e:0,r=e<0?-e:0,o=Math.min(this._size[0]-r,this._size[1]-t),i=[],a=0;a<o;a++)i[a]=this._data[a+r][a+t];return new n({data:i,size:[o],datatype:this._datatype})},n.diagonal=function(e,t,r,o){if(!sd(e))throw TypeError("Array expected, size parameter");if(2!==e.length)throw Error("Only two dimensions matrix are supported");if(e=e.map(function(e){if(sa(e)&&(e=e.toNumber()),!si(e)||!s0(e)||e<1)throw Error("Size values must be positive integers");return e}),r){if(sa(r)&&(r=r.toNumber()),!si(r)||!s0(r))throw TypeError("The parameter k must be an integer number")}else r=0;var i,a=r>0?r:0,s=r<0?-r:0,l=e[0],u=e[1],c=Math.min(l-s,u-a);if(sd(t)){if(t.length!==c)throw Error("Invalid value array length");i=function(e){return t[e]}}else if(sp(t)){var d=t.size();if(1!==d.length||d[0]!==c)throw Error("Invalid matrix length");i=function(e){return t.get([e])}}else i=function(){return t};o||(o=sa(i(0))?i(0).mul(0):0);var p=[];if(e.length>0){p=ls(p,e,o);for(var f=0;f<c;f++)p[f+s][f+a]=i(f)}return new n({data:p,size:[l,u]})},n.fromJSON=function(e){return new n(e)},n.prototype.swapRows=function(e,t){if(!si(e)||!s0(e)||!si(t)||!s0(t))throw Error("Row index must be positive integers");if(2!==this._size.length)throw Error("Only two dimensional matrix is supported");return la(e,this._size[0]),la(t,this._size[0]),n._swapRows(e,t,this._data),this},n._swapRows=function(e,t,n){var r=n[e];n[e]=n[t],n[t]=r},n},{isClass:!0})};let uY=Math.cosh||function(e){return 1e-9>Math.abs(e)?1-e:(Math.exp(e)+Math.exp(-e))*.5},uX=Math.sinh||function(e){return 1e-9>Math.abs(e)?e:(Math.exp(e)-Math.exp(-e))*.5},uK=function(e){let t=Math.PI/4;if(-t>e||e>t)return Math.cos(e)-1;let n=e*e;return n*(n*(n*(n*(n*(n*(n*(n/20922789888e3-1/0x144c3b2800)+1/0x1c8cfc00)-1/3628800)+1/40320)-1/720)+1/24)-.5)},uQ=function(e,t){return((e=Math.abs(e))<(t=Math.abs(t))&&([e,t]=[t,e]),e<1e8)?Math.sqrt(e*e+t*t):(t/=e,e*Math.sqrt(1+t*t))},uJ=function(){throw SyntaxError("Invalid Param")};function u0(e,t){let n=Math.abs(e),r=Math.abs(t);return 0===e?Math.log(r):0===t?Math.log(n):n<3e3&&r<3e3?.5*Math.log(e*e+t*t):.5*Math.log((e*=.5)*e+(t*=.5)*t)+Math.LN2}let u1={re:0,im:0},u2=function(e,t){if(null==e)u1.re=u1.im=0;else if(void 0!==t)u1.re=e,u1.im=t;else switch(typeof e){case"object":if("im"in e&&"re"in e)u1.re=e.re,u1.im=e.im;else if("abs"in e&&"arg"in e){if(!isFinite(e.abs)&&isFinite(e.arg))return u5.INFINITY;u1.re=e.abs*Math.cos(e.arg),u1.im=e.abs*Math.sin(e.arg)}else if("r"in e&&"phi"in e){if(!isFinite(e.r)&&isFinite(e.phi))return u5.INFINITY;u1.re=e.r*Math.cos(e.phi),u1.im=e.r*Math.sin(e.phi)}else 2===e.length?(u1.re=e[0],u1.im=e[1]):uJ();break;case"string":u1.im=u1.re=0;let n=e.replace(/_/g,"").match(/\d+\.?\d*e[+-]?\d+|\d+\.?\d*|\.\d+|./g),r=1,o=0;null===n&&uJ();for(let e=0;e<n.length;e++){let t=n[e];" "===t||" "===t||"\n"===t||("+"===t?r++:"-"===t?o++:("i"===t||"I"===t?(r+o===0&&uJ()," "===n[e+1]||isNaN(n[e+1])?u1.im+=parseFloat((o%2?"-":"")+"1"):(u1.im+=parseFloat((o%2?"-":"")+n[e+1]),e++)):((r+o===0||isNaN(t))&&uJ(),"i"===n[e+1]||"I"===n[e+1]?(u1.im+=parseFloat((o%2?"-":"")+t),e++):u1.re+=parseFloat((o%2?"-":"")+t)),r=o=0))}r+o>0&&uJ();break;case"number":u1.im=0,u1.re=e;break;default:uJ()}return isNaN(u1.re)||isNaN(u1.im),u1};function u5(e,t){if(!(this instanceof u5))return new u5(e,t);let n=u2(e,t);this.re=n.re,this.im=n.im}u5.prototype={re:0,im:0,sign:function(){let e=uQ(this.re,this.im);return new u5(this.re/e,this.im/e)},add:function(e,t){let n=u2(e,t),r=this.isInfinite(),o=!(isFinite(n.re)&&isFinite(n.im));return r||o?r&&o?u5.NAN:u5.INFINITY:new u5(this.re+n.re,this.im+n.im)},sub:function(e,t){let n=u2(e,t),r=this.isInfinite(),o=!(isFinite(n.re)&&isFinite(n.im));return r||o?r&&o?u5.NAN:u5.INFINITY:new u5(this.re-n.re,this.im-n.im)},mul:function(e,t){let n=u2(e,t),r=this.isInfinite(),o=!(isFinite(n.re)&&isFinite(n.im)),i=0===this.re&&0===this.im,a=0===n.re&&0===n.im;return r&&a||o&&i?u5.NAN:r||o?u5.INFINITY:0===n.im&&0===this.im?new u5(this.re*n.re,0):new u5(this.re*n.re-this.im*n.im,this.re*n.im+this.im*n.re)},div:function(e,t){let n=u2(e,t),r=this.isInfinite(),o=!(isFinite(n.re)&&isFinite(n.im)),i=0===this.re&&0===this.im,a=0===n.re&&0===n.im;if(i&&a||r&&o)return u5.NAN;if(a||r)return u5.INFINITY;if(i||o)return u5.ZERO;if(0===n.im)return new u5(this.re/n.re,this.im/n.re);if(Math.abs(n.re)<Math.abs(n.im)){let e=n.re/n.im,t=n.re*e+n.im;return new u5((this.re*e+this.im)/t,(this.im*e-this.re)/t)}{let e=n.im/n.re,t=n.im*e+n.re;return new u5((this.re+this.im*e)/t,(this.im-this.re*e)/t)}},pow:function(e,t){let n=u2(e,t),r=0===this.re&&0===this.im;if(0===n.re&&0===n.im)return u5.ONE;if(0===n.im){if(0===this.im&&this.re>0)return new u5(Math.pow(this.re,n.re),0);if(0===this.re)switch((n.re%4+4)%4){case 0:return new u5(Math.pow(this.im,n.re),0);case 1:return new u5(0,Math.pow(this.im,n.re));case 2:return new u5(-Math.pow(this.im,n.re),0);case 3:return new u5(0,-Math.pow(this.im,n.re))}}if(r&&n.re>0)return u5.ZERO;let o=Math.atan2(this.im,this.re),i=u0(this.re,this.im),a=Math.exp(n.re*i-n.im*o),s=n.im*i+n.re*o;return new u5(a*Math.cos(s),a*Math.sin(s))},sqrt:function(){let e=this.re,t=this.im;if(0===t)return e>=0?new u5(Math.sqrt(e),0):new u5(0,Math.sqrt(-e));let n=Math.sqrt(.5*(uQ(e,t)+Math.abs(e))),r=Math.abs(t)/(2*n);return e>=0?new u5(n,t<0?-r:r):new u5(r,t<0?-n:n)},exp:function(){let e=Math.exp(this.re);return 0===this.im?new u5(e,0):new u5(e*Math.cos(this.im),e*Math.sin(this.im))},expm1:function(){let e=this.re,t=this.im;return new u5(Math.expm1(e)*Math.cos(t)+uK(t),Math.exp(e)*Math.sin(t))},log:function(){let e=this.re,t=this.im;return 0===t&&e>0?new u5(Math.log(e),0):new u5(u0(e,t),Math.atan2(t,e))},abs:function(){return uQ(this.re,this.im)},arg:function(){return Math.atan2(this.im,this.re)},sin:function(){let e=this.re,t=this.im;return new u5(Math.sin(e)*uY(t),Math.cos(e)*uX(t))},cos:function(){let e=this.re,t=this.im;return new u5(Math.cos(e)*uY(t),-Math.sin(e)*uX(t))},tan:function(){let e=2*this.re,t=2*this.im,n=Math.cos(e)+uY(t);return new u5(Math.sin(e)/n,uX(t)/n)},cot:function(){let e=2*this.re,t=2*this.im,n=Math.cos(e)-uY(t);return new u5(-Math.sin(e)/n,uX(t)/n)},sec:function(){let e=this.re,t=this.im,n=.5*uY(2*t)+.5*Math.cos(2*e);return new u5(Math.cos(e)*uY(t)/n,Math.sin(e)*uX(t)/n)},csc:function(){let e=this.re,t=this.im,n=.5*uY(2*t)-.5*Math.cos(2*e);return new u5(Math.sin(e)*uY(t)/n,-Math.cos(e)*uX(t)/n)},asin:function(){let e=this.re,t=this.im,n=new u5(t*t-e*e+1,-2*e*t).sqrt(),r=new u5(n.re-t,n.im+e).log();return new u5(r.im,-r.re)},acos:function(){let e=this.re,t=this.im,n=new u5(t*t-e*e+1,-2*e*t).sqrt(),r=new u5(n.re-t,n.im+e).log();return new u5(Math.PI/2-r.im,r.re)},atan:function(){let e=this.re,t=this.im;if(0===e){if(1===t)return new u5(0,1/0);if(-1===t)return new u5(0,-1/0)}let n=e*e+(1-t)*(1-t),r=new u5((1-t*t-e*e)/n,-2*e/n).log();return new u5(-.5*r.im,.5*r.re)},acot:function(){let e=this.re,t=this.im;if(0===t)return new u5(Math.atan2(1,e),0);let n=e*e+t*t;return 0!==n?new u5(e/n,-t/n).atan():new u5(0!==e?e/0:0,0!==t?-t/0:0).atan()},asec:function(){let e=this.re,t=this.im;if(0===e&&0===t)return new u5(0,1/0);let n=e*e+t*t;return 0!==n?new u5(e/n,-t/n).acos():new u5(0!==e?e/0:0,0!==t?-t/0:0).acos()},acsc:function(){let e=this.re,t=this.im;if(0===e&&0===t)return new u5(Math.PI/2,1/0);let n=e*e+t*t;return 0!==n?new u5(e/n,-t/n).asin():new u5(0!==e?e/0:0,0!==t?-t/0:0).asin()},sinh:function(){let e=this.re,t=this.im;return new u5(uX(e)*Math.cos(t),uY(e)*Math.sin(t))},cosh:function(){let e=this.re,t=this.im;return new u5(uY(e)*Math.cos(t),uX(e)*Math.sin(t))},tanh:function(){let e=2*this.re,t=2*this.im,n=uY(e)+Math.cos(t);return new u5(uX(e)/n,Math.sin(t)/n)},coth:function(){let e=2*this.re,t=2*this.im,n=uY(e)-Math.cos(t);return new u5(uX(e)/n,-Math.sin(t)/n)},csch:function(){let e=this.re,t=this.im,n=Math.cos(2*t)-uY(2*e);return new u5(-2*uX(e)*Math.cos(t)/n,2*uY(e)*Math.sin(t)/n)},sech:function(){let e=this.re,t=this.im,n=Math.cos(2*t)+uY(2*e);return new u5(2*uY(e)*Math.cos(t)/n,-2*uX(e)*Math.sin(t)/n)},asinh:function(){let e=this.im;this.im=-this.re,this.re=e;let t=this.asin();return this.re=-this.im,this.im=e,e=t.re,t.re=-t.im,t.im=e,t},acosh:function(){let e=this.acos();if(e.im<=0){let t=e.re;e.re=-e.im,e.im=t}else{let t=e.im;e.im=-e.re,e.re=t}return e},atanh:function(){let e=this.re,t=this.im,n=1-e,r=1+e,o=n*n+t*t,i=0!==o?new u5((r*n-t*t)/o,(t*n+r*t)/o):new u5(-1!==e?e/0:0,0!==t?t/0:0),a=i.re;return i.re=u0(i.re,i.im)/2,i.im=Math.atan2(i.im,a)/2,e>1&&0===t&&(i.im=-i.im),i},acoth:function(){let e=this.re,t=this.im;if(0===e&&0===t)return new u5(0,Math.PI/2);let n=e*e+t*t;return 0!==n?new u5(e/n,-t/n).atanh():new u5(0!==e?e/0:0,0!==t?-t/0:0).atanh()},acsch:function(){let e=this.re,t=this.im;if(0===t)return new u5(0!==e?Math.log(e+Math.sqrt(e*e+1)):1/0,0);let n=e*e+t*t;return 0!==n?new u5(e/n,-t/n).asinh():new u5(0!==e?e/0:0,0!==t?-t/0:0).asinh()},asech:function(){let e=this.re,t=this.im;if(this.isZero())return u5.INFINITY;let n=e*e+t*t;return 0!==n?new u5(e/n,-t/n).acosh():new u5(0!==e?e/0:0,0!==t?-t/0:0).acosh()},inverse:function(){if(this.isZero())return u5.INFINITY;if(this.isInfinite())return u5.ZERO;let e=this.re,t=this.im,n=e*e+t*t;return new u5(e/n,-t/n)},conjugate:function(){return new u5(this.re,-this.im)},neg:function(){return new u5(-this.re,-this.im)},ceil:function(e){return e=Math.pow(10,e||0),new u5(Math.ceil(this.re*e)/e,Math.ceil(this.im*e)/e)},floor:function(e){return e=Math.pow(10,e||0),new u5(Math.floor(this.re*e)/e,Math.floor(this.im*e)/e)},round:function(e){return e=Math.pow(10,e||0),new u5(Math.round(this.re*e)/e,Math.round(this.im*e)/e)},equals:function(e,t){let n=u2(e,t);return Math.abs(n.re-this.re)<=u5.EPSILON&&Math.abs(n.im-this.im)<=u5.EPSILON},clone:function(){return new u5(this.re,this.im)},toString:function(){let e=this.re,t=this.im,n="";return this.isNaN()?"NaN":this.isInfinite()?"Infinity":(Math.abs(e)<u5.EPSILON&&(e=0),Math.abs(t)<u5.EPSILON&&(t=0),0===t)?n+e:(0!==e?(n+=e,n+=" ",t<0?(t=-t,n+="-"):n+="+",n+=" "):t<0&&(t=-t,n+="-"),1!==t&&(n+=t),n+"i")},toVector:function(){return[this.re,this.im]},valueOf:function(){return 0===this.im?this.re:null},isNaN:function(){return isNaN(this.re)||isNaN(this.im)},isZero:function(){return 0===this.im&&0===this.re},isFinite:function(){return isFinite(this.re)&&isFinite(this.im)},isInfinite:function(){return!this.isFinite()}},u5.ZERO=new u5(0,0),u5.ONE=new u5(1,0),u5.I=new u5(0,1),u5.PI=new u5(Math.PI,0),u5.E=new u5(Math.E,0),u5.INFINITY=new u5(1/0,1/0),u5.NAN=new u5(NaN,NaN),u5.EPSILON=1e-15;var u3=sK("Complex",[],()=>(u5.prototype.type="Complex",u5.prototype.isComplex=!0,u5.prototype.toJSON=function(){return{mathjs:"Complex",re:this.re,im:this.im}},u5.prototype.toPolar=function(){return{r:this.abs(),phi:this.arg()}},u5.prototype.format=function(e){var t="",n=this.im,r=this.re,o=s2(this.re,e),i=s2(this.im,e),a=si(e)?e:e?e.precision:null;if(null!==a){var s=Math.pow(10,-a);Math.abs(r/n)<s&&(r=0),Math.abs(n/r)<s&&(n=0)}return 0===n?o:0===r?1===n?"i":-1===n?"-i":i+"i":n<0?-1===n?o+" - i":o+" - "+i.substring(1)+"i":1===n?o+" + i":o+" + "+i+"i"},u5.fromPolar=function(e){switch(arguments.length){case 1:var t=arguments[0];if("object"==typeof t)return u5(t);throw TypeError("Input has to be an object with r and phi keys.");case 2:var n=arguments[0],r=arguments[1];if(si(n)){if(su(r)&&r.hasBase("ANGLE")&&(r=r.toNumber("rad")),si(r))return new u5({r:n,phi:r});throw TypeError("Phi is not a number nor an angle unit.")}throw TypeError("Radius r is not a number.");default:throw SyntaxError("Wrong number of arguments in function fromPolar")}},u5.prototype.valueOf=u5.prototype.toString,u5.fromJSON=function(e){return new u5(e)},u5.compare=function(e,t){return e.re>t.re?1:e.re<t.re?-1:e.im>t.im?1:e.im<t.im?-1:0},u5),{isClass:!0}),u4={s:1,n:0,d:1};function u6(e,t){if(isNaN(e=parseInt(e,10)))throw cr();return e*t}function u8(e,t){if(0===t)throw cn();var n=Object.create(ct.prototype);n.s=e<0?-1:1;var r=ce(e=e<0?-e:e,t);return n.n=e/r,n.d=t/r,n}function u9(e){for(var t={},n=e,r=2,o=4;o<=n;){for(;n%r==0;)n/=r,t[r]=(t[r]||0)+1;o+=1+2*r++}return n!==e?n>1&&(t[n]=(t[n]||0)+1):t[e]=(t[e]||0)+1,t}var u7=function(e,t){var n,r=0,o=1,i=1,a=0,s=0,l=0,u=1,c=1,d=0,p=1,f=1,h=1;if(null==e);else if(void 0!==t){if(i=(r=e)*(o=t),r%1!=0||o%1!=0)throw co()}else switch(typeof e){case"object":if("d"in e&&"n"in e)r=e.n,o=e.d,"s"in e&&(r*=e.s);else if(0 in e)r=e[0],1 in e&&(o=e[1]);else throw cr();i=r*o;break;case"number":if(e<0&&(i=e,e=-e),e%1==0)r=e;else if(e>0){for(e>=1&&(c=Math.pow(10,Math.floor(1+Math.log(e)/Math.LN10)),e/=c);p<=1e7&&h<=1e7;){if(e===(n=(d+f)/(p+h))){p+h<=1e7?(r=d+f,o=p+h):h>p?(r=f,o=h):(r=d,o=p);break}e>n?(d+=f,p+=h):(f+=d,h+=p),p>1e7?(r=f,o=h):(r=d,o=p)}r*=c}else(isNaN(e)||isNaN(t))&&(o=r=NaN);break;case"string":if(null===(p=e.match(/\d+|./g)))throw cr();if("-"===p[d]?(i=-1,d++):"+"===p[d]&&d++,p.length===d+1?s=u6(p[d++],i):"."===p[d+1]||"."===p[d]?("."!==p[d]&&(a=u6(p[d++],i)),(++d+1===p.length||"("===p[d+1]&&")"===p[d+3]||"'"===p[d+1]&&"'"===p[d+3])&&(s=u6(p[d],i),u=Math.pow(10,p[d].length),d++),("("===p[d]&&")"===p[d+2]||"'"===p[d]&&"'"===p[d+2])&&(l=u6(p[d+1],i),c=Math.pow(10,p[d+1].length)-1,d+=3)):"/"===p[d+1]||":"===p[d+1]?(s=u6(p[d],i),u=u6(p[d+2],1),d+=3):"/"===p[d+3]&&" "===p[d+1]&&(a=u6(p[d],i),s=u6(p[d+2],i),u=u6(p[d+4],1),d+=5),p.length<=d){i=r=l+(o=u*c)*a+c*s;break}default:throw cr()}if(0===o)throw cn();u4.s=i<0?-1:1,u4.n=Math.abs(r),u4.d=Math.abs(o)};function ce(e,t){if(!e)return t;if(!t)return e;for(;;){if(!(e%=t))return t;if(!(t%=e))return e}}function ct(e,t){if(u7(e,t),!(this instanceof ct))return u8(u4.s*u4.n,u4.d);e=ce(u4.d,u4.n),this.s=u4.s,this.n=u4.n/e,this.d=u4.d/e}var cn=function(){return Error("Division by Zero")},cr=function(){return Error("Invalid argument")},co=function(){return Error("Parameters must be integer")};ct.prototype={s:1,n:0,d:1,abs:function(){return u8(this.n,this.d)},neg:function(){return u8(-this.s*this.n,this.d)},add:function(e,t){return u7(e,t),u8(this.s*this.n*u4.d+u4.s*this.d*u4.n,this.d*u4.d)},sub:function(e,t){return u7(e,t),u8(this.s*this.n*u4.d-u4.s*this.d*u4.n,this.d*u4.d)},mul:function(e,t){return u7(e,t),u8(this.s*u4.s*this.n*u4.n,this.d*u4.d)},div:function(e,t){return u7(e,t),u8(this.s*u4.s*this.n*u4.d,this.d*u4.n)},clone:function(){return u8(this.s*this.n,this.d)},mod:function(e,t){if(isNaN(this.n)||isNaN(this.d))return new ct(NaN);if(void 0===e)return u8(this.s*this.n%this.d,1);if(u7(e,t),0===u4.n&&0===this.d)throw cn();return u8(this.s*(u4.d*this.n)%(u4.n*this.d),u4.d*this.d)},gcd:function(e,t){return u7(e,t),u8(ce(u4.n,this.n)*ce(u4.d,this.d),u4.d*this.d)},lcm:function(e,t){return(u7(e,t),0===u4.n&&0===this.n)?u8(0,1):u8(u4.n*this.n,ce(u4.n,this.n)*ce(u4.d,this.d))},ceil:function(e){return(e=Math.pow(10,e||0),isNaN(this.n)||isNaN(this.d))?new ct(NaN):u8(Math.ceil(e*this.s*this.n/this.d),e)},floor:function(e){return(e=Math.pow(10,e||0),isNaN(this.n)||isNaN(this.d))?new ct(NaN):u8(Math.floor(e*this.s*this.n/this.d),e)},round:function(e){return(e=Math.pow(10,e||0),isNaN(this.n)||isNaN(this.d))?new ct(NaN):u8(Math.round(e*this.s*this.n/this.d),e)},roundTo:function(e,t){return u7(e,t),u8(this.s*Math.round(this.n*u4.d/(this.d*u4.n))*u4.n,u4.d)},inverse:function(){return u8(this.s*this.d,this.n)},pow:function(e,t){if(u7(e,t),1===u4.d)return u4.s<0?u8(Math.pow(this.s*this.d,u4.n),Math.pow(this.n,u4.n)):u8(Math.pow(this.s*this.n,u4.n),Math.pow(this.d,u4.n));if(this.s<0)return null;var n=u9(this.n),r=u9(this.d),o=1,i=1;for(var a in n)if("1"!==a){if("0"===a){o=0;break}if(n[a]*=u4.n,n[a]%u4.d!=0)return null;n[a]/=u4.d,o*=Math.pow(a,n[a])}for(var a in r)if("1"!==a){if(r[a]*=u4.n,r[a]%u4.d!=0)return null;r[a]/=u4.d,i*=Math.pow(a,r[a])}return u4.s<0?u8(i,o):u8(o,i)},equals:function(e,t){return u7(e,t),this.s*this.n*u4.d==u4.s*u4.n*this.d},compare:function(e,t){u7(e,t);var n=this.s*this.n*u4.d-u4.s*u4.n*this.d;return(0<n)-(n<0)},simplify:function(e){if(isNaN(this.n)||isNaN(this.d))return this;e=e||.001;for(var t=this.abs(),n=t.toContinued(),r=1;r<n.length;r++){for(var o=u8(n[r-1],1),i=r-2;i>=0;i--)o=o.inverse().add(n[i]);if(Math.abs(o.sub(t).valueOf())<e)return o.mul(this.s)}return this},divisible:function(e,t){return u7(e,t),!(!(u4.n*this.d)||this.n*u4.d%(u4.n*this.d))},valueOf:function(){return this.s*this.n/this.d},toFraction:function(e){var t,n="",r=this.n,o=this.d;return this.s<0&&(n+="-"),1===o?n+=r:(e&&(t=Math.floor(r/o))>0&&(n+=t,n+=" ",r%=o),n+=r,n+="/",n+=o),n},toLatex:function(e){var t,n="",r=this.n,o=this.d;return this.s<0&&(n+="-"),1===o?n+=r:(e&&(t=Math.floor(r/o))>0&&(n+=t,r%=o),n+="\\frac{",n+=r,n+="}{",n+=o,n+="}"),n},toContinued:function(){var e,t=this.n,n=this.d,r=[];if(isNaN(t)||isNaN(n))return r;do r.push(Math.floor(t/n)),e=t%n,t=n,n=e;while(1!==t);return r},toString:function(e){var t=this.n,n=this.d;if(isNaN(t)||isNaN(n))return"NaN";e=e||15;var r=function(e,t){for(;t%2==0;t/=2);for(;t%5==0;t/=5);if(1===t)return 0;for(var n=10%t,r=1;1!==n;r++)if(n=10*n%t,r>2e3)return 0;return r}(0,n),o=function(e,t,n){for(var r=1,o=function(e,t,n){for(var r=1;t>0;e=e*e%n,t>>=1)1&t&&(r=r*e%n);return r}(10,n,t),i=0;i<300;i++){if(r===o)return i;r=10*r%t,o=10*o%t}return 0}(0,n,r),i=this.s<0?"-":"";if(i+=t/n|0,t%=n,(t*=10)&&(i+="."),r){for(var a=o;a--;)i+=t/n|0,t%=n,t*=10;i+="(";for(var a=r;a--;)i+=t/n|0,t%=n,t*=10;i+=")"}else for(var a=e;t&&a--;)i+=t/n|0,t%=n,t*=10;return i}};var ci=sK("Fraction",[],()=>(ct.prototype.type="Fraction",ct.prototype.isFraction=!0,ct.prototype.toJSON=function(){return{mathjs:"Fraction",n:this.s*this.n,d:this.d}},ct.fromJSON=function(e){return new ct(e)},ct),{isClass:!0}),ca=n(27554);function cs(e,t){return!!e&&"object"==typeof e&&(!!sq(cu,t)||!(t in Object.prototype)&&!(t in Function.prototype))}function cl(e){return"object"==typeof e&&e&&e.constructor===Object}var cu={length:!0,name:!0},cc={toString:!0,valueOf:!0,toLocaleString:!0};class cd{constructor(e){this.wrappedObject=e}keys(){return Object.keys(this.wrappedObject)}get(e){return function(e,t){var n,r;if(cl(e)&&cs(e,t))return e[t];if("function"==typeof e[t]&&(n=e,r=t,!(null==n||"function"!=typeof n[r]||sq(n,r)&&Object.getPrototypeOf&&r in Object.getPrototypeOf(n))&&(sq(cc,r)||!(r in Object.prototype)&&!(r in Function.prototype))))throw Error('Cannot access method "'+t+'" as a property');throw Error('No access to property "'+t+'"')}(this.wrappedObject,e)}set(e,t){return!function(e,t,n){if(cl(e)&&cs(e,t))return e[t]=n;throw Error('No access to property "'+t+'"')}(this.wrappedObject,e,t),this}has(e){return e in this.wrappedObject}}function cp(e){return!!e&&(e instanceof Map||e instanceof cd||"function"==typeof e.set&&"function"==typeof e.get&&"function"==typeof e.keys&&"function"==typeof e.has)}var cf=function(){return cf=ca.create,ca};function ch(e){throw Error("Cannot convert value ".concat(e," into a BigNumber: no class 'BigNumber' provided"))}function cm(e){throw Error("Cannot convert value ".concat(e," into a Complex number: no class 'Complex' provided"))}function cg(e){throw Error("Cannot convert value ".concat(e," into a Fraction, no class 'Fraction' provided."))}var cv={BigNumberDependencies:uG,ComplexDependencies:{createComplexClass:u3},DenseMatrixDependencies:uq,FractionDependencies:{createFractionClass:ci},createTyped:sK("typed",["?BigNumber","?Complex","?DenseMatrix","?Fraction"],function(e){var{BigNumber:t,Complex:n,DenseMatrix:r,Fraction:o}=e,i=cf();return i.types=[{name:"number",test:si},{name:"Complex",test:ss},{name:"BigNumber",test:sa},{name:"Fraction",test:sl},{name:"Unit",test:su},{name:"string",test:sc},{name:"Chain",test:sB},{name:"Array",test:sd},{name:"Matrix",test:sp},{name:"DenseMatrix",test:sh},{name:"SparseMatrix",test:sm},{name:"Range",test:sg},{name:"Index",test:sv},{name:"boolean",test:sy},{name:"ResultSet",test:sb},{name:"Help",test:sx},{name:"function",test:sw},{name:"Date",test:sC},{name:"RegExp",test:sS},{name:"null",test:sk},{name:"undefined",test:sE},{name:"AccessorNode",test:sD},{name:"ArrayNode",test:sT},{name:"AssignmentNode",test:sP},{name:"BlockNode",test:sZ},{name:"ConditionalNode",test:sO},{name:"ConstantNode",test:sj},{name:"FunctionNode",test:sN},{name:"FunctionAssignmentNode",test:sR},{name:"IndexNode",test:sA},{name:"Node",test:sF},{name:"ObjectNode",test:sI},{name:"OperatorNode",test:s_},{name:"ParenthesisNode",test:sL},{name:"RangeNode",test:sV},{name:"SymbolNode",test:s$},{name:"Map",test:cp},{name:"Object",test:sM}],i.conversions=[{from:"number",to:"BigNumber",convert:function(e){if(t||ch(e),e.toExponential().replace(/e.*$/,"").replace(/^0\.?0*|\./,"").length>15)throw TypeError("Cannot implicitly convert a number with >15 significant digits to BigNumber (value: "+e+"). Use function bignumber(x) to convert to BigNumber.");return new t(e)}},{from:"number",to:"Complex",convert:function(e){return n||cm(e),new n(e,0)}},{from:"number",to:"string",convert:function(e){return e+""}},{from:"BigNumber",to:"Complex",convert:function(e){return n||cm(e),new n(e.toNumber(),0)}},{from:"Fraction",to:"BigNumber",convert:function(e){throw TypeError("Cannot implicitly convert a Fraction to BigNumber or vice versa. Use function bignumber(x) to convert to BigNumber or fraction(x) to convert to Fraction.")}},{from:"Fraction",to:"Complex",convert:function(e){return n||cm(e),new n(e.valueOf(),0)}},{from:"number",to:"Fraction",convert:function(e){o||cg(e);var t=new o(e);if(t.valueOf()!==e)throw TypeError("Cannot implicitly convert a number to a Fraction when there will be a loss of precision (value: "+e+"). Use function fraction(x) to convert to Fraction.");return t}},{from:"string",to:"number",convert:function(e){var t=Number(e);if(isNaN(t))throw Error('Cannot convert "'+e+'" to a number');return t}},{from:"string",to:"BigNumber",convert:function(e){t||ch(e);try{return new t(e)}catch(t){throw Error('Cannot convert "'+e+'" to BigNumber')}}},{from:"string",to:"Fraction",convert:function(e){o||cg(e);try{return new o(e)}catch(t){throw Error('Cannot convert "'+e+'" to Fraction')}}},{from:"string",to:"Complex",convert:function(e){n||cm(e);try{return new n(e)}catch(t){throw Error('Cannot convert "'+e+'" to Complex')}}},{from:"boolean",to:"number",convert:function(e){return+e}},{from:"boolean",to:"BigNumber",convert:function(e){return t||ch(e),new t(+e)}},{from:"boolean",to:"Fraction",convert:function(e){return o||cg(e),new o(+e)}},{from:"boolean",to:"string",convert:function(e){return String(e)}},{from:"Array",to:"Matrix",convert:function(e){return r||function(){throw Error("Cannot convert array into a Matrix: no class 'DenseMatrix' provided")}(),new r(e)}},{from:"Matrix",to:"Array",convert:function(e){return e.valueOf()}}],i})},cy="equalScalar",cb=sK(cy,["typed","config"],e=>{var{typed:t,config:n}=e;return t(cy,{"boolean, boolean":function(e,t){return e===t},"number, number":function(e,t){return s9(e,t,n.epsilon)},"BigNumber, BigNumber":function(e,t){return e.eq(t)||function(e,t,n){if(null==n)return e.eq(t);if(e.eq(t))return!0;if(e.isNaN()||t.isNaN())return!1;if(e.isFinite()&&t.isFinite()){var r=e.minus(t).abs();if(r.isZero())return!0;var o=e.constructor.max(e.abs(),t.abs());return r.lte(o.times(n))}return!1}(e,t,n.epsilon)},"Fraction, Fraction":function(e,t){return e.equals(t)},"Complex, Complex":function(e,t){var r;return r=n.epsilon,s9(e.re,t.re,r)&&s9(e.im,t.im,r)},"Unit, Unit":function(e,t){if(!e.equalBase(t))throw Error("Cannot compare units with different base");return this(e.value,t.value)}})});sK(cy,["typed","config"],e=>{var{typed:t,config:n}=e;return t(cy,{"number, number":function(e,t){return s9(e,t,n.epsilon)}})});var cx={typedDependencies:cv,createEqualScalar:cb},cw=sK("SparseMatrix",["typed","equalScalar","Matrix"],e=>{var{typed:t,equalScalar:n,Matrix:r}=e;function o(e,t){if(!(this instanceof o))throw SyntaxError("Constructor must be called with the new operator");if(t&&!sc(t))throw Error("Invalid datatype: "+t);if(sp(e)){var n,r,a;n=this,r=e,a=t,"SparseMatrix"===r.type?(n._values=r._values?sH(r._values):void 0,n._index=sH(r._index),n._ptr=sH(r._ptr),n._size=sH(r._size),n._datatype=a||r._datatype):i(n,r.valueOf(),a||r._datatype)}else if(e&&sd(e.index)&&sd(e.ptr)&&sd(e.size))this._values=e.values,this._index=e.index,this._ptr=e.ptr,this._size=e.size,this._datatype=t||e.datatype;else if(sd(e))i(this,e,t);else if(e)throw TypeError("Unsupported type of data ("+sz(e)+")");else this._values=[],this._index=[],this._ptr=[0],this._size=[0,0],this._datatype=t}function i(e,r,o){e._values=[],e._index=[],e._ptr=[],e._datatype=o;var i=r.length,a=0,s=n,l=0;if(sc(o)&&(s=t.find(n,[o,o])||n,l=t.convert(0,o)),i>0){var u=0;do{e._ptr.push(e._index.length);for(var c=0;c<i;c++){var d=r[c];if(sd(d)){if(0===u&&a<d.length&&(a=d.length),u<d.length){var p=d[u];s(p,l)||(e._values.push(p),e._index.push(c))}}else 0===u&&a<1&&(a=1),s(d,l)||(e._values.push(d),e._index.push(c))}u++}while(u<a)}e._ptr.push(e._index.length),e._size=[i,a]}function a(e,t,n,r){if(n-t==0)return n;for(var o=t;o<n;o++)if(r[o]===e)return o;return t}function s(e,t,n,r,o,i,a){o.splice(e,0,r),i.splice(e,0,t);for(var s=n+1;s<a.length;s++)a[s]++}function l(e,r,o,i){var a,s,l,u=i||0,c=n,d=0;sc(e._datatype)&&(c=t.find(n,[e._datatype,e._datatype])||n,d=t.convert(0,e._datatype),u=t.convert(u,e._datatype));var p=!c(u,d),f=e._size[0],h=e._size[1];if(o>h){for(s=h;s<o;s++)if(e._ptr[s]=e._values.length,p)for(a=0;a<f;a++)e._values.push(u),e._index.push(a);e._ptr[o]=e._values.length}else o<h&&(e._ptr.splice(o+1,h-o),e._values.splice(e._ptr[o],e._values.length),e._index.splice(e._ptr[o],e._index.length));if(h=o,r>f){if(p){var m=0;for(s=0;s<h;s++){e._ptr[s]=e._ptr[s]+m,l=e._ptr[s+1]+m;var g=0;for(a=f;a<r;a++,g++)e._values.splice(l+g,0,u),e._index.splice(l+g,0,a),m++}e._ptr[h]=e._values.length}}else if(r<f){var v=0;for(s=0;s<h;s++){e._ptr[s]=e._ptr[s]-v;var y=e._ptr[s],b=e._ptr[s+1]-v;for(l=y;l<b;l++)(a=e._index[l])>r-1&&(e._values.splice(l,1),e._index.splice(l,1),v++)}e._ptr[s]=e._values.length}return e._size[0]=r,e._size[1]=o,e}function u(e,t,n,r,o){var i,a,s=r[0],l=r[1],u=[];for(i=0;i<s;i++)for(a=0,u[i]=[];a<l;a++)u[i][a]=0;for(a=0;a<l;a++)for(var c=n[a],d=n[a+1],p=c;p<d;p++)u[i=t[p]][a]=e?o?sH(e[p]):e[p]:1;return u}return o.prototype=new r,o.prototype.createSparseMatrix=function(e,t){return new o(e,t)},o.prototype.type="SparseMatrix",o.prototype.isSparseMatrix=!0,o.prototype.getDataType=function(){return ld(this._values,sz)},o.prototype.storage=function(){return"sparse"},o.prototype.datatype=function(){return this._datatype},o.prototype.create=function(e,t){return new o(e,t)},o.prototype.density=function(){var e=this._size[0],t=this._size[1];return 0!==e&&0!==t?this._index.length/(e*t):0},o.prototype.subset=function(e,t,n){if(!this._values)throw Error("Cannot invoke subset on a Pattern only matrix");switch(arguments.length){case 1:return function(e,t){if(!sv(t))throw TypeError("Invalid index");if(t.isScalar())return e.get(t.min());var n,r,i,a,s=t.size();if(s.length!==e._size.length)throw new ln(s.length,e._size.length);var l=t.min(),u=t.max();for(n=0,r=e._size.length;n<r;n++)la(l[n],e._size[n]),la(u[n],e._size[n]);var c=e._values,d=e._index,p=e._ptr,f=t.dimension(0),h=t.dimension(1),m=[],g=[];f.forEach(function(e,t){g[e]=t[0],m[e]=!0});var v=c?[]:void 0,y=[],b=[];return h.forEach(function(e){for(b.push(y.length),i=p[e],a=p[e+1];i<a;i++)!0===m[n=d[i]]&&(y.push(g[n]),v&&v.push(c[i]))}),b.push(y.length),new o({values:v,index:y,ptr:b,size:s,datatype:e._datatype})}(this,e);case 2:case 3:return function(e,t,n,r){if(!t||!0!==t.isIndex)throw TypeError("Invalid index");var o,i=t.size(),a=t.isScalar();if(sp(n)?(o=n.size(),n=n.toArray()):o=lo(n),a){if(0!==o.length)throw TypeError("Scalar expected");e.set(t.min(),n,r)}else{if(1!==i.length&&2!==i.length)throw new ln(i.length,e._size.length,"<");if(o.length<i.length){for(var s=0,l=0;1===i[s]&&1===o[s];)s++;for(;1===i[s];)l++,s++;n=lc(n,i.length,l,o)}if(!sG(i,o))throw new ln(i,o,">");if(1===i.length)t.dimension(0).forEach(function(t,o){la(t),e.set([t,0],n[o[0]],r)});else{var u=t.dimension(0),c=t.dimension(1);u.forEach(function(t,o){la(t),c.forEach(function(i,a){la(i),e.set([t,i],n[o[0]][a[0]],r)})})}}return e}(this,e,t,n);default:throw SyntaxError("Wrong number of arguments")}},o.prototype.get=function(e){if(!sd(e))throw TypeError("Array expected");if(e.length!==this._size.length)throw new ln(e.length,this._size.length);if(!this._values)throw Error("Cannot invoke get on a Pattern only matrix");var t=e[0],n=e[1];la(t,this._size[0]),la(n,this._size[1]);var r=a(t,this._ptr[n],this._ptr[n+1],this._index);return r<this._ptr[n+1]&&this._index[r]===t?this._values[r]:0},o.prototype.set=function(e,r,o){if(!sd(e))throw TypeError("Array expected");if(e.length!==this._size.length)throw new ln(e.length,this._size.length);if(!this._values)throw Error("Cannot invoke set on a Pattern only matrix");var i=e[0],u=e[1],c=this._size[0],d=this._size[1],p=n,f=0;sc(this._datatype)&&(p=t.find(n,[this._datatype,this._datatype])||n,f=t.convert(0,this._datatype)),(i>c-1||u>d-1)&&(l(this,Math.max(i+1,c),Math.max(u+1,d),o),c=this._size[0],d=this._size[1]),la(i,c),la(u,d);var h=a(i,this._ptr[u],this._ptr[u+1],this._index);return h<this._ptr[u+1]&&this._index[h]===i?p(r,f)?function(e,t,n,r,o){n.splice(e,1),r.splice(e,1);for(var i=t+1;i<o.length;i++)o[i]--}(h,u,this._values,this._index,this._ptr):this._values[h]=r:s(h,i,u,r,this._values,this._index,this._ptr),this},o.prototype.resize=function(e,t,n){if(!sf(e))throw TypeError("Array or Matrix expected");var r=e.valueOf().map(e=>Array.isArray(e)&&1===e.length?e[0]:e);if(2!==r.length)throw Error("Only two dimensions matrix are supported");return r.forEach(function(e){if(!si(e)||!s0(e)||e<0)throw TypeError("Invalid size, must contain positive integers (size: "+lt(r)+")")}),l(n?this.clone():this,r[0],r[1],t)},o.prototype.reshape=function(e,t){if(!sd(e))throw TypeError("Array expected");if(2!==e.length)throw Error("Sparse matrices can only be reshaped in two dimensions");e.forEach(function(t){if(!si(t)||!s0(t)||t<=-2||0===t)throw TypeError("Invalid size, must contain positive integers or -1 (size: "+lt(e)+")")});var n=this._size[0]*this._size[1],r=(e=ll(e,n))[0]*e[1];if(n!==r)throw Error("Reshaping sparse matrix will result in the wrong number of elements");var o=t?this.clone():this;if(this._size[0]===e[0]&&this._size[1]===e[1])return o;for(var i=[],l=0;l<o._ptr.length;l++)for(var u=0;u<o._ptr[l+1]-o._ptr[l];u++)i.push(l);for(var c=o._values.slice(),d=o._index.slice(),p=0;p<o._index.length;p++){var f=d[p],h=i[p],m=f*o._size[1]+h;i[p]=m%e[1],d[p]=Math.floor(m/e[1])}o._values.length=0,o._index.length=0,o._ptr.length=e[1]+1,o._size=e.slice();for(var g=0;g<o._ptr.length;g++)o._ptr[g]=0;for(var v=0;v<c.length;v++){var y=d[v],b=i[v],x=c[v];s(a(y,o._ptr[b],o._ptr[b+1],o._index),y,b,x,o._values,o._index,o._ptr)}return o},o.prototype.clone=function(){return new o({values:this._values?sH(this._values):void 0,index:sH(this._index),ptr:sH(this._ptr),size:sH(this._size),datatype:this._datatype})},o.prototype.size=function(){return this._size.slice(0)},o.prototype.map=function(e,r){if(!this._values)throw Error("Cannot invoke map on a Pattern only matrix");var i=this;return function(e,r,i,a,s,l,u){var c=[],d=[],p=[],f=n,h=0;sc(e._datatype)&&(f=t.find(n,[e._datatype,e._datatype])||n,h=t.convert(0,e._datatype));for(var m=function(e,t,n){e=l(e,t,n),f(e,h)||(c.push(e),d.push(t))},g=0;g<=s;g++){p.push(c.length);var v=e._ptr[g],y=e._ptr[g+1];if(u)for(var b=v;b<y;b++){var x=e._index[b];x>=0&&x<=i&&m(e._values[b],x-r,g-a)}else{for(var w={},C=v;C<y;C++)w[e._index[C]]=e._values[C];for(var S=r;S<=i;S++)m(S in w?w[S]:0,S-r,g-a)}}return p.push(c.length),new o({values:c,index:d,ptr:p,size:[i-r+1,s-a+1]})}(this,0,this._size[0]-1,0,this._size[1]-1,function(t,n,r){return e(t,[n,r],i)},r)},o.prototype.forEach=function(e,t){if(!this._values)throw Error("Cannot invoke forEach on a Pattern only matrix");for(var n=this._size[0],r=this._size[1],o=0;o<r;o++){var i=this._ptr[o],a=this._ptr[o+1];if(t)for(var s=i;s<a;s++){var l=this._index[s];e(this._values[s],[l,o],this)}else{for(var u={},c=i;c<a;c++)u[this._index[c]]=this._values[c];for(var d=0;d<n;d++)e(d in u?u[d]:0,[d,o],this)}}},o.prototype[Symbol.iterator]=function*(){if(!this._values)throw Error("Cannot iterate a Pattern only matrix");for(var e=this._size[1],t=0;t<e;t++)for(var n=this._ptr[t],r=this._ptr[t+1],o=n;o<r;o++){var i=this._index[o];yield{value:this._values[o],index:[i,t]}}},o.prototype.toArray=function(){return u(this._values,this._index,this._ptr,this._size,!0)},o.prototype.valueOf=function(){return u(this._values,this._index,this._ptr,this._size,!1)},o.prototype.format=function(e){for(var t=this._size[0],n=this._size[1],r=this.density(),o="Sparse Matrix ["+lt(t,e)+" x "+lt(n,e)+"] density: "+lt(r,e)+"\n",i=0;i<n;i++)for(var a=this._ptr[i],s=this._ptr[i+1],l=a;l<s;l++)o+="\n ("+lt(this._index[l],e)+", "+lt(i,e)+") ==> "+(this._values?lt(this._values[l],e):"X");return o},o.prototype.toString=function(){return lt(this.toArray())},o.prototype.toJSON=function(){return{mathjs:"SparseMatrix",values:this._values,index:this._index,ptr:this._ptr,size:this._size,datatype:this._datatype}},o.prototype.diagonal=function(e){if(e){if(sa(e)&&(e=e.toNumber()),!si(e)||!s0(e))throw TypeError("The parameter k must be an integer number")}else e=0;var t=e>0?e:0,n=e<0?-e:0,r=this._size[0],i=this._size[1],a=Math.min(r-n,i-t),s=[],l=[],u=[];u[0]=0;for(var c=t;c<i&&s.length<a;c++)for(var d=this._ptr[c],p=this._ptr[c+1],f=d;f<p;f++){var h=this._index[f];if(h===c-t+n){s.push(this._values[f]),l[s.length-1]=h-n;break}}return u.push(s.length),new o({values:s,index:l,ptr:u,size:[a,1]})},o.fromJSON=function(e){return new o(e)},o.diagonal=function(e,r,i,a,s){if(!sd(e))throw TypeError("Array expected, size parameter");if(2!==e.length)throw Error("Only two dimensions matrix are supported");if(e=e.map(function(e){if(sa(e)&&(e=e.toNumber()),!si(e)||!s0(e)||e<1)throw Error("Size values must be positive integers");return e}),i){if(sa(i)&&(i=i.toNumber()),!si(i)||!s0(i))throw TypeError("The parameter k must be an integer number")}else i=0;var l,u=n,c=0;sc(s)&&(u=t.find(n,[s,s])||n,c=t.convert(0,s));var d=i>0?i:0,p=i<0?-i:0,f=e[0],h=e[1],m=Math.min(f-p,h-d);if(sd(r)){if(r.length!==m)throw Error("Invalid value array length");l=function(e){return r[e]}}else if(sp(r)){var g=r.size();if(1!==g.length||g[0]!==m)throw Error("Invalid matrix length");l=function(e){return r.get([e])}}else l=function(){return r};for(var v=[],y=[],b=[],x=0;x<h;x++){b.push(v.length);var w=x-d;if(w>=0&&w<m){var C=l(w);u(C,c)||(y.push(w+p),v.push(C))}}return b.push(v.length),new o({values:v,index:y,ptr:b,size:[f,h]})},o.prototype.swapRows=function(e,t){if(!si(e)||!s0(e)||!si(t)||!s0(t))throw Error("Row index must be positive integers");if(2!==this._size.length)throw Error("Only two dimensional matrix is supported");return la(e,this._size[0]),la(t,this._size[0]),o._swapRows(e,t,this._size[1],this._values,this._index,this._ptr),this},o._forEachRow=function(e,t,n,r,o){for(var i=r[e],a=r[e+1],s=i;s<a;s++)o(n[s],t[s])},o._swapRows=function(e,t,n,r,o,i){for(var s=0;s<n;s++){var l=i[s],u=i[s+1],c=a(e,l,u,o),d=a(t,l,u,o);if(c<u&&d<u&&o[c]===e&&o[d]===t){if(r){var p=r[c];r[c]=r[d],r[d]=p}continue}if(c<u&&o[c]===e&&(d>=u||o[d]!==t)){var f=r?r[c]:void 0;o.splice(d,0,t),r&&r.splice(d,0,f),o.splice(d<=c?c+1:c,1),r&&r.splice(d<=c?c+1:c,1);continue}if(d<u&&o[d]===t&&(c>=u||o[c]!==e)){var h=r?r[d]:void 0;o.splice(c,0,e),r&&r.splice(c,0,h),o.splice(c<=d?d+1:d,1),r&&r.splice(c<=d?d+1:d,1)}}},o},{isClass:!0}),cC="matrix",cS=sK(cC,["typed","Matrix","DenseMatrix","SparseMatrix"],e=>{var{typed:t,Matrix:n,DenseMatrix:r,SparseMatrix:o}=e;return t(cC,{"":function(){return i([])},string:function(e){return i([],e)},"string, string":function(e,t){return i([],e,t)},Array:function(e){return i(e)},Matrix:function(e){return i(e,e.storage())},"Array | Matrix, string":i,"Array | Matrix, string, string":i});function i(e,t,n){if("dense"===t||"default"===t||void 0===t)return new r(e,n);if("sparse"===t)return new o(e,n);throw TypeError("Unknown matrix type "+JSON.stringify(t)+".")}}),cM=sK("algorithm01",["typed"],e=>{var{typed:t}=e;return function(e,n,r,o){var i,a,s=e._data,l=e._size,u=e._datatype,c=n._values,d=n._index,p=n._ptr,f=n._size,h=n._datatype;if(l.length!==f.length)throw new ln(l.length,f.length);if(l[0]!==f[0]||l[1]!==f[1])throw RangeError("Dimension mismatch. Matrix A ("+l+") must match Matrix B ("+f+")");if(!c)throw Error("Cannot perform operation on Dense Matrix and Pattern Sparse Matrix");var m=l[0],g=l[1],v="string"==typeof u&&u===h?u:void 0,y=v?t.find(r,[v,v]):r,b=[];for(i=0;i<m;i++)b[i]=[];var x=[],w=[];for(a=0;a<g;a++){for(var C=a+1,S=p[a],M=p[a+1],k=S;k<M;k++)x[i=d[k]]=o?y(c[k],s[i][a]):y(s[i][a],c[k]),w[i]=C;for(i=0;i<m;i++)w[i]===C?b[i][a]=x[i]:b[i][a]=s[i][a]}return e.createDenseMatrix({data:b,size:[m,g],datatype:v})}}),ck=sK("algorithm04",["typed","equalScalar"],e=>{var{typed:t,equalScalar:n}=e;return function(e,r,o){var i,a,s,l,u,c,d=e._values,p=e._index,f=e._ptr,h=e._size,m=e._datatype,g=r._values,v=r._index,y=r._ptr,b=r._size,x=r._datatype;if(h.length!==b.length)throw new ln(h.length,b.length);if(h[0]!==b[0]||h[1]!==b[1])throw RangeError("Dimension mismatch. Matrix A ("+h+") must match Matrix B ("+b+")");var w=h[0],C=h[1],S=n,M=0,k=o;"string"==typeof m&&m===x&&(i=m,S=t.find(n,[i,i]),M=t.convert(0,i),k=t.find(o,[i,i]));var E=d&&g?[]:void 0,D=[],T=[],P=d&&g?[]:void 0,Z=d&&g?[]:void 0,O=[],j=[];for(s=0;s<C;s++){T[s]=D.length;var R=s+1;for(u=f[s],c=f[s+1],l=u;l<c;l++)a=p[l],D.push(a),O[a]=R,P&&(P[a]=d[l]);for(u=y[s],c=y[s+1],l=u;l<c;l++)if(O[a=v[l]]===R){if(P){var N=k(P[a],g[l]);S(N,M)?O[a]=null:P[a]=N}}else D.push(a),j[a]=R,Z&&(Z[a]=g[l]);if(P&&Z)for(l=T[s];l<D.length;)O[a=D[l]]===R?(E[l]=P[a],l++):j[a]===R?(E[l]=Z[a],l++):D.splice(l,1)}return T[C]=D.length,e.createSparseMatrix({values:E,index:D,ptr:T,size:[w,C],datatype:i})}}),cE=sK("algorithm10",["typed","DenseMatrix"],e=>{var{typed:t,DenseMatrix:n}=e;return function(e,r,o,i){var a,s=e._values,l=e._index,u=e._ptr,c=e._size,d=e._datatype;if(!s)throw Error("Cannot perform operation on Pattern Sparse Matrix and Scalar value");var p=c[0],f=c[1],h=o;"string"==typeof d&&(a=d,r=t.convert(r,a),h=t.find(o,[a,a]));for(var m=[],g=[],v=[],y=0;y<f;y++){for(var b=y+1,x=u[y],w=u[y+1],C=x;C<w;C++){var S=l[C];g[S]=s[C],v[S]=b}for(var M=0;M<p;M++)0===y&&(m[M]=[]),v[M]===b?m[M][y]=i?h(r,g[M]):h(g[M],r):m[M][y]=r}return new n({data:m,size:[p,f],datatype:a})}}),cD=sK("algorithm13",["typed"],e=>{var{typed:t}=e;return function(e,n,r){var o,i=e._data,a=e._size,s=e._datatype,l=n._data,u=n._size,c=n._datatype,d=[];if(a.length!==u.length)throw new ln(a.length,u.length);for(var p=0;p<a.length;p++){if(a[p]!==u[p])throw RangeError("Dimension mismatch. Matrix A ("+a+") must match Matrix B ("+u+")");d[p]=a[p]}var f=r;"string"==typeof s&&s===c&&(o=s,f=t.find(r,[o,o]));var h=d.length>0?function e(t,n,r,o,i,a){var s=[];if(n===r.length-1)for(var l=0;l<o;l++)s[l]=t(i[l],a[l]);else for(var u=0;u<o;u++)s[u]=e(t,n+1,r,r[n+1],i[u],a[u]);return s}(f,0,d,d[0],i,l):[];return e.createDenseMatrix({data:h,size:d,datatype:o})}}),cT=sK("algorithm14",["typed"],e=>{var{typed:t}=e;return function(e,n,r,o){var i,a=e._data,s=e._size,l=e._datatype,u=r;"string"==typeof l&&(i=l,n=t.convert(n,i),u=t.find(r,[i,i]));var c=s.length>0?function e(t,n,r,o,i,a,s){var l=[];if(n===r.length-1)for(var u=0;u<o;u++)l[u]=s?t(a,i[u]):t(i[u],a);else for(var c=0;c<o;c++)l[c]=e(t,n+1,r,r[n+1],i[c],a,s);return l}(u,0,s,s[0],a,n,o):[];return e.createDenseMatrix({data:c,size:sH(s),datatype:i})}});function cP(e,t){var n;if(!s0(e)||!s0(t))throw Error("Parameters in function gcd must be integer numbers");for(;0!==t;)n=e%t,e=t,t=n;return e<0?-e:e}cP.signature="number, number";let{gcd:cZ}=function e(t,n){var r,o,i,a=(0,so.Z)({},lh,n);if("function"!=typeof Object.create)throw Error("ES5 not supported by this JavaScript engine. Please load the es5-shim and es5-sham library for compatibility.");var s=(r={isNumber:si,isComplex:ss,isBigNumber:sa,isFraction:sl,isUnit:su,isString:sc,isArray:sd,isMatrix:sp,isCollection:sf,isDenseMatrix:sh,isSparseMatrix:sm,isRange:sg,isIndex:sv,isBoolean:sy,isResultSet:sb,isHelp:sx,isFunction:sw,isDate:sC,isRegExp:sS,isObject:sM,isNull:sk,isUndefined:sE,isAccessorNode:sD,isArrayNode:sT,isAssignmentNode:sP,isBlockNode:sZ,isConditionalNode:sO,isConstantNode:sj,isFunctionAssignmentNode:sR,isFunctionNode:sN,isIndexNode:sA,isNode:sF,isObjectNode:sI,isOperatorNode:s_,isParenthesisNode:sL,isRangeNode:sV,isSymbolNode:s$,isChain:sB},o=new sX,r.on=o.on.bind(o),r.off=o.off.bind(o),r.once=o.once.bind(o),r.emit=o.emit.bind(o),r);s.config=function(e,t){function n(n){if(!n)return sW(e,sH);var r=sW(e,sH);lv(n,"matrix",lm),lv(n,"number",lg),function e(t,n){if(Array.isArray(n))throw TypeError("Arrays are not supported by deepExtend");for(var r in n)if(sq(n,r)&&!(r in Object.prototype)&&!(r in Function.prototype)){if(n[r]&&n[r].constructor===Object)void 0===t[r]&&(t[r]={}),t[r]&&t[r].constructor===Object?e(t[r],n[r]):t[r]=n[r];else if(Array.isArray(n[r]))throw TypeError("Arrays are not supported by deepExtend");else t[r]=n[r]}return t}(e,n);var o=sW(e,sH);return t("config",o,r,sW(n,sH)),o}return n.MATRIX_OPTIONS=lm,n.NUMBER_OPTIONS=lg,Object.keys(lh).forEach(t=>{Object.defineProperty(n,t,{get:()=>e[t],enumerable:!0,configurable:!0})}),n}(a,s.emit),s.expression={transform:{},mathWithTransform:{config:s.config}};var l={},u=function(e,t,n,r){function o(e,t){t&&"function"==typeof t.transform?(n.expression.transform[e]=t.transform,sq(s,e)||(n.expression.mathWithTransform[e]=t.transform)):(delete n.expression.transform[e],sq(s,e)||(n.expression.mathWithTransform[e]=t))}function i(e){return"function"==typeof e&&"object"==typeof e.signatures}function a(e){return void 0!==e&&void 0!==e.meta&&!0===e.meta.isTransformFunction}var s={expression:!0,type:!0,docs:!0,error:!0,json:!0,chain:!0};return function(t,l){var u=arguments.length;if(1!==u&&2!==u)throw new lf("import",u,1,2);l||(l={});var c={};for(var d in!function e(t,n,r){if(Array.isArray(n))n.forEach(n=>e(t,n));else if("object"==typeof n)for(var o in n)sq(n,o)&&e(t,n[o],o);else if(sQ(n)||void 0!==r){var i=sQ(n)?a(n)?n.fn+".transform":n.fn:r;if(sq(t,i)&&t[i]!==n&&!l.silent)throw Error('Cannot import "'+i+'" twice');t[i]=n}else if(!l.silent)throw TypeError("Factory, Object, or Array expected")}(c,t),c)if(sq(c,d)){var p,f=c[d];if(sQ(f))!function(t,o){var l,u=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.fn;if(lp(u,"."))throw Error("Factory name should not contain a nested path. Name: "+JSON.stringify(u));var c=a(t)?n.expression.transform:n,d=u in n.expression.transform,p=sq(c,u)?c[u]:void 0,f=function(){var r={};t.dependencies.map(sJ).forEach(e=>{if(lp(e,"."))throw Error("Factory dependency should not contain a nested path. Name: "+JSON.stringify(e));"math"===e?r.math=n:"mathWithTransform"===e?r.mathWithTransform=n.expression.mathWithTransform:"classes"===e?r.classes=n:r[e]=n[e]});var a=t(r);if(a&&"function"==typeof a.transform)throw Error('Transforms cannot be attached to factory functions. Please create a separate function for it with exports.path="expression.transform"');if(void 0===p||o.override)return a;if(i(p)&&i(a))return e(p,a);if(o.silent)return p;throw Error('Cannot import "'+u+'": already exists')};t.meta&&!1===t.meta.lazy?c[u]=f():sU(c,u,f),p&&d?function(e){delete n.expression.transform[e],sq(s,e)?delete n.expression.mathWithTransform[e]:n.expression.mathWithTransform[e]=n[e]}(u):!a(t)&&(-1!==(l=t).fn.indexOf(".")||sq(s,l.fn)||l.meta&&l.meta.isClass)||sU(n.expression.mathWithTransform,u,()=>c[u]),r[u]=t,n.emit("import",u,f)}(f,l);else{if("function"==typeof(p=f)||"number"==typeof p||"string"==typeof p||"boolean"==typeof p||null===p||su(p)||ss(p)||sa(p)||sl(p)||sp(p)||Array.isArray(p))!function(t,a,s){var l;if(s.wrap&&"function"==typeof a&&(a=function(e){var t=function(){for(var t=[],r=0,o=arguments.length;r<o;r++){var i=arguments[r];t[r]=i&&i.valueOf()}return e.apply(n,t)};return e.transform&&(t.transform=e.transform),t}(a)),"function"==typeof(l=a)&&"string"==typeof l.signature&&(a=e(t,{[a.signature]:a})),i(n[t])&&i(a)){a=s.override?e(t,a.signatures):e(n[t],a),n[t]=a,delete r[t],o(t,a),n.emit("import",t,function(){return a});return}if(void 0===n[t]||s.override){n[t]=a,delete r[t],o(t,a),n.emit("import",t,function(){return a});return}if(!s.silent)throw Error('Cannot import "'+t+'": already exists')}(d,f,l);else if(!l.silent)throw TypeError("Factory, Object, or Array expected")}}}}(function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return s.typed.apply(s.typed,t)},0,s,l);return s.import=u,s.on("config",()=>{sY(l).forEach(e=>{e&&e.meta&&e.meta.recreateOnConfigChange&&u(e,{override:!0})})}),s.create=e.bind(null,t),s.factory=sK,s.import(sY((function e(t,n){for(var r in t)if(sq(t,r)){var o=t[r];"object"==typeof o&&null!==o?e(o,n):n[r]=o}}(t,i={}),i))),s.ArgumentsError=lf,s.DimensionError=ln,s.IndexError=lr,s}({gcdDependencies:{BigNumberDependencies:uG,DenseMatrixDependencies:uq,equalScalarDependencies:cx,matrixDependencies:{DenseMatrixDependencies:uq,MatrixDependencies:uU,SparseMatrixDependencies:{MatrixDependencies:uU,equalScalarDependencies:cx,typedDependencies:cv,createSparseMatrixClass:cw},typedDependencies:cv,createMatrix:cS},typedDependencies:cv,createGcd:sK("gcd",["typed","matrix","equalScalar","BigNumber","DenseMatrix"],e=>{var{typed:t,matrix:n,equalScalar:r,BigNumber:o,DenseMatrix:i}=e,a=cM({typed:t}),s=ck({typed:t,equalScalar:r}),l=cE({typed:t,DenseMatrix:i}),u=cD({typed:t}),c=cT({typed:t});return t("gcd",{"number, number":cP,"BigNumber, BigNumber":function(e,t){if(!e.isInt()||!t.isInt())throw Error("Parameters in function gcd must be integer numbers");for(var n=new o(0);!t.isZero();){var r=e.mod(t);e=t,t=r}return e.lt(n)?e.neg():e},"Fraction, Fraction":function(e,t){return e.gcd(t)},"SparseMatrix, SparseMatrix":function(e,t){return s(e,t,this)},"SparseMatrix, DenseMatrix":function(e,t){return a(t,e,this,!0)},"DenseMatrix, SparseMatrix":function(e,t){return a(e,t,this,!1)},"DenseMatrix, DenseMatrix":function(e,t){return u(e,t,this)},"Array, Array":function(e,t){return this(n(e),n(t)).valueOf()},"Array, Matrix":function(e,t){return this(n(e),t)},"Matrix, Array":function(e,t){return this(e,n(t))},"SparseMatrix, number | BigNumber":function(e,t){return l(e,t,this,!1)},"DenseMatrix, number | BigNumber":function(e,t){return c(e,t,this,!1)},"number | BigNumber, SparseMatrix":function(e,t){return l(t,e,this,!0)},"number | BigNumber, DenseMatrix":function(e,t){return c(t,e,this,!0)},"Array, number | BigNumber":function(e,t){return c(n(e),t,this,!1).valueOf()},"number | BigNumber, Array":function(e,t){return c(n(t),e,this,!0).valueOf()},"Array | Matrix | number | BigNumber, Array | Matrix | number | BigNumber, ...Array | Matrix | number | BigNumber":function(e,t,n){for(var r=this(e,t),o=0;o<n.length;o++)r=this(r,n[o]);return r}})})}}),cO=(0,d.memo)(function({containerId:e,chartRef:t,data:n,seriesMapping:r,enablePinning:o=!0,wrapLabels:i,format:a,onUnpinClick:s,pinnedPos:l}){let[u,p]=(0,d.useState)(!1),f=(0,d.useRef)(),h=iQ(),{height:m,width:g,ref:v}=(0,i5.default)(),y=null!==l&&o;if(null===h||null===h.target||null===n||null===l&&"CANVAS"!==h.target.tagName)return null;let b=t.current,x=b?.getWidth()??iB,w=e?document.querySelector(e):void 0,C=w?w.getBoundingClientRect().height:void 0;y||(f.current=aC(h,x,l,m??0,g??0,w));let S=ay({mousePos:h,data:n,seriesMapping:r,pinnedPos:l,chart:b,format:a,showAllSeries:u});if(0===S.length)return null;let M=n.length;return(0,c.jsx)(i2.Z,{container:w,children:(0,c.jsx)(eV.Z,{ref:v,sx:e=>aS(e,l,C),style:{transform:f.current},children:(0,c.jsxs)(e8.Z,{spacing:.5,children:[(0,c.jsx)(at,{nearbySeries:S,totalSeries:M,enablePinning:o,isTooltipPinned:y,showAllSeries:u,onShowAllClick:e=>p(e),onUnpinClick:s}),(0,c.jsx)(i8,{series:S,wrapLabels:i})]})})})});(0,eR.D)([iw.N,eN.N,eA.N,eF.N,eK.N,iC.N,iS.N,iM.N,eI.N,ik.N,e_.N,eL.N]);let cj=(0,d.forwardRef)(function({height:e,data:t,seriesMapping:n,timeScale:r,yAxis:o,format:i,grid:a,isStackedBar:s=!1,tooltipConfig:l=iJ,noDataVariant:u="message",syncGroup:p,onDataZoom:f,onDoubleClick:h,__experimentalEChartsOptionsOverride:m},g){let v;let{chartsTheme:y,enablePinning:b,lastTooltipPinnedCoords:x,setLastTooltipPinnedCoords:w}=ez(),C=l.enablePinning&&b,S=(0,d.useRef)(),[M,k]=(0,d.useState)(!0),[E,D]=(0,d.useState)(null),[T,P]=(0,d.useState)(null),[Z,O]=(0,d.useState)(!1),[j,R]=(0,d.useState)(0),{timeZone:N}=iA();if(void 0===r){let e=function(e){let t,n;let r=[];for(let t of e)if(t&&"timeRange"in t){if(void 0===t||void 0===t.timeRange||void 0===t.stepMs)continue;if(r.push(t.stepMs),void 0===n){n=t.timeRange;continue}t.timeRange.start<n.start&&(n.start=t.timeRange.start),t.timeRange.end>n.end&&(n.end=t.timeRange.end)}else if(t&&"values"in t){for(let e=0;e<t.values.length;e++){let r=t.values[e];if(void 0===r)continue;let[o]=r,i=new Date(o),a=new Date(o);if(void 0===n){n={start:i,end:a};continue}i<n.start&&(n.start=i),a>n.end&&(n.end=a)}if(void 0===n)return;let e=n.start.valueOf(),r=n.end.valueOf(),o=r-e;return{startMs:e,endMs:r,rangeMs:o,stepMs:10}}if(void 0===n)return;if(1===r.length)t=r[0];else{let e=cZ(...r);t=e<10?10:e}let o=n.start.valueOf(),i=n.end.valueOf();return{startMs:o,endMs:i,stepMs:t,rangeMs:i-o}}(t);if(void 0===e){let e=new Date,t=new Date(e);t.setFullYear(e.getFullYear()-5);let n=e.getTime(),r=t.getTime();v={startMs:r,endMs:n,stepMs:1,rangeMs:n-r}}else v=e}else v=r;(0,d.useImperativeHandle)(g,()=>({highlightSeries({name:e}){S.current&&S.current.dispatchAction({type:"highlight",seriesId:e})},clearHighlightedSeries:()=>{S.current&&as(S.current)}}),[]);let A=(0,d.useMemo)(()=>({datazoom:e=>{if(void 0===f&&setTimeout(()=>{D(null)},10),void 0===f||void 0===e.batch[0])return;let t=e.batch[0].startValue,n=e.batch[0].endValue;void 0!==t&&void 0!==n&&f({start:t,end:n})},finished:()=>{void 0!==S.current&&ai(S.current)}}),[f,D]),{noDataOption:F}=y,I=(0,d.useMemo)(()=>{if(null===t||0===t.length&&"message"===u)return F;let e=[],r="local"===N;t.map((t,n)=>{let o=t.values.map(([e,t])=>[r?e:(0,iE.toZonedTime)(e,N),null===t?"-":t]);e.push({id:n,source:[...o],dimensions:["time","value"]})});let l={dataset:e,series:b&&null!==T?[...n,T]:n,xAxis:{type:"time",min:r?v.startMs:(0,iE.toZonedTime)(v.startMs,N),max:r?v.endMs:(0,iE.toZonedTime)(v.endMs,N),axisLabel:{hideOverlap:!0,formatter:iO(v.rangeMs??0)},axisPointer:{snap:!1}},yAxis:e3(o,i),animation:!1,tooltip:{show:!0,showContent:s,trigger:s?"item":"axis",appendToBody:s},axisPointer:{type:"line",z:0,triggerEmphasis:!1,triggerTooltip:!1,snap:!1},toolbox:{feature:{dataZoom:{icon:null,yAxisIndex:"none"}}},grid:a};return m?m(l):l},[t,n,v,o,i,a,F,m,u,N,s,b,T]);return(0,d.useEffect)(()=>{null===E||null===x||eU()(x,E)||(D(null),null!==E&&null!==T&&P(null))},[x,n]),(0,c.jsxs)(eV.Z,{style:{height:e},onClick:e=>{let n=e.ctrlKey||e.metaKey;n&&e.preventDefault();let r=al(e.nativeEvent.offsetX,e.nativeEvent.offsetY,S.current);if(null!==r&&C&&e.target instanceof HTMLCanvasElement){let o={page:{x:e.pageX,y:e.pageY},client:{x:e.clientX,y:e.clientY},plotCanvas:{x:e.nativeEvent.offsetX,y:e.nativeEvent.offsetY},target:e.target};D(e=>null===e?o:(P(null),null)),P(e=>{if(null!==e)return null;{let e=r[0],n=ad(t[0]?.values,e);return e5()({},ao,{markLine:{data:[{xAxis:n}]}})}}),n||w(o)}},onMouseDown:e=>{let{clientX:t}=e;O(!0),R(t)},onMouseMove:e=>{if(!(e.target instanceof HTMLCanvasElement))return;let{clientX:t}=e;Z&&t-j>0&&k(!1)},onMouseUp:()=>{O(!1),R(0),k(!0)},onMouseLeave:()=>{null===E&&k(!1),void 0!==S.current&&as(S.current)},onMouseEnter:()=>{k(!0),void 0!==S.current&&ai(S.current)},onDoubleClick:e=>{D(null),void 0===h?void 0!==S.current&&aa(S.current):h(e)},children:[!0===M&&I.tooltip?.showContent===!1&&!0!==l.hidden&&(0,c.jsx)(cO,{containerId:y.tooltipPortalContainerId,chartRef:S,data:t,seriesMapping:n,wrapLabels:l.wrapLabels,enablePinning:C,pinnedPos:E,format:i,onUnpinClick:()=>{D(null),P(null)}}),(0,c.jsx)(e1,{sx:{width:"100%",height:"100%"},option:I,theme:y.echartsTheme,onEvents:A,_instance:S,syncGroup:p})]})});var cR=n(63767),cN=n(59986),cA=n(29085),cF=n(97784),cI=n(22179),c_=n(53126),cL=n(92994);function cV({props:e,name:t}){return(0,cI.Z)({props:e,name:t,defaultTheme:c_.Z,themeId:cL.Z})}let c$=["localeText"],cB=d.createContext(null),cz=function(e){let{localeText:t}=e,n=(0,cF.Z)(e,c$),{utils:r,localeText:o}=d.useContext(cB)??{utils:void 0,localeText:void 0},{children:i,dateAdapter:a,dateFormats:s,dateLibInstance:l,adapterLocale:u,localeText:p}=cV({props:n,name:"MuiLocalizationProvider"}),f=d.useMemo(()=>(0,so.Z)({},p,o,t),[p,o,t]),h=d.useMemo(()=>{if(!a)return r||null;let e=new a({locale:u,formats:s,instance:l});if(!e.isMUIAdapter)throw Error(["MUI X: The date adapter should be imported from `@mui/x-date-pickers` or `@mui/x-date-pickers-pro`, not from `@date-io`","For example, `import { AdapterDayjs } from '@mui/x-date-pickers/AdapterDayjs'` instead of `import AdapterDayjs from '@date-io/dayjs'`","More information on the installation documentation: https://mui.com/x/react-date-pickers/getting-started/#installation"].join(`
|
|
6
|
+
`));return e},[a,u,s,l,r]),m=d.useMemo(()=>h?{minDate:h.date("1900-01-01T00:00:00.000"),maxDate:h.date("2099-12-31T00:00:00.000")}:null,[h]),g=d.useMemo(()=>({utils:h,defaultDates:m,localeText:f}),[m,h,f]);return(0,c.jsx)(cB.Provider,{value:g,children:i})};var cH=n(23615),cW=n.n(cH);let cG={previousMonth:"Previous month",nextMonth:"Next month",openPreviousView:"Open previous view",openNextView:"Open next view",calendarViewSwitchingButtonAriaLabel:e=>"year"===e?"year view is open, switch to calendar view":"calendar view is open, switch to year view",start:"Start",end:"End",startDate:"Start date",startTime:"Start time",endDate:"End date",endTime:"End time",cancelButtonLabel:"Cancel",clearButtonLabel:"Clear",okButtonLabel:"OK",todayButtonLabel:"Today",datePickerToolbarTitle:"Select date",dateTimePickerToolbarTitle:"Select date & time",timePickerToolbarTitle:"Select time",dateRangePickerToolbarTitle:"Select date range",clockLabelText:(e,t,n,r)=>`Select ${e}. ${r||null!==t&&n.isValid(t)?`Selected time is ${r??n.format(t,"fullTime")}`:"No time selected"}`,hoursClockNumberText:e=>`${e} hours`,minutesClockNumberText:e=>`${e} minutes`,secondsClockNumberText:e=>`${e} seconds`,selectViewText:e=>`Select ${e}`,calendarWeekNumberHeaderLabel:"Week number",calendarWeekNumberHeaderText:"#",calendarWeekNumberAriaLabelText:e=>`Week ${e}`,calendarWeekNumberText:e=>`${e}`,openDatePickerDialogue:(e,t,n)=>n||null!==e&&t.isValid(e)?`Choose date, selected date is ${n??t.format(e,"fullDate")}`:"Choose date",openTimePickerDialogue:(e,t,n)=>n||null!==e&&t.isValid(e)?`Choose time, selected time is ${n??t.format(e,"fullTime")}`:"Choose time",fieldClearLabel:"Clear",timeTableLabel:"pick time",dateTableLabel:"pick date",fieldYearPlaceholder:e=>"Y".repeat(e.digitAmount),fieldMonthPlaceholder:e=>"letter"===e.contentType?"MMMM":"MM",fieldDayPlaceholder:()=>"DD",fieldWeekDayPlaceholder:e=>"letter"===e.contentType?"EEEE":"EE",fieldHoursPlaceholder:()=>"hh",fieldMinutesPlaceholder:()=>"mm",fieldSecondsPlaceholder:()=>"ss",fieldMeridiemPlaceholder:()=>"aa",year:"Year",month:"Month",day:"Day",weekDay:"Week day",hours:"Hours",minutes:"Minutes",seconds:"Seconds",meridiem:"Meridiem",empty:"Empty"};(0,so.Z)({},cG);let cU=()=>{let e=d.useContext(cB);if(null===e)throw Error("MUI X: Can not find the date and time pickers localization context.\nIt looks like you forgot to wrap your component in LocalizationProvider.\nThis can also happen if you are bundling multiple versions of the `@mui/x-date-pickers` package");if(null===e.utils)throw Error("MUI X: Can not find the date and time pickers adapter from its localization context.\nIt looks like you forgot to pass a `dateAdapter` to your LocalizationProvider.");let t=d.useMemo(()=>(0,so.Z)({},cG,e.localeText),[e.localeText]);return d.useMemo(()=>(0,so.Z)({},e,{localeText:t}),[e,t])},cq=()=>cU().utils,cY=()=>cU().defaultDates,cX=e=>{let t=cq(),n=d.useRef(void 0);return void 0===n.current&&(n.current=t.date(void 0,e)),n.current},cK=(e,t,n)=>{let r=t;return r=e.setHours(r,e.getHours(n)),r=e.setMinutes(r,e.getMinutes(n)),r=e.setSeconds(r,e.getSeconds(n)),r=e.setMilliseconds(r,e.getMilliseconds(n))},cQ=({date:e,disableFuture:t,disablePast:n,maxDate:r,minDate:o,isDateDisabled:i,utils:a,timezone:s})=>{let l=cK(a,a.date(void 0,s),e);n&&a.isBefore(o,l)&&(o=l),t&&a.isAfter(r,l)&&(r=l);let u=e,c=e;for(a.isBefore(e,o)&&(u=o,c=null),a.isAfter(e,r)&&(c&&(c=r),u=null);u||c;){if(u&&a.isAfter(u,r)&&(u=null),c&&a.isBefore(c,o)&&(c=null),u){if(!i(u))return u;u=a.addDays(u,1)}if(c){if(!i(c))return c;c=a.addDays(c,-1)}}return null},cJ=(e,t,n)=>null!=t&&e.isValid(t)?t:n,c0=(e,t)=>{let n=[e.startOfYear(t)];for(;n.length<12;){let t=n[n.length-1];n.push(e.addMonths(t,1))}return n},c1=(e,t,n)=>"date"===n?e.startOfDay(e.date(void 0,t)):e.date(void 0,t),c2=(e,t)=>{let n=e.setHours(e.date(),"am"===t?2:14);return e.format(n,"meridiem")},c5=["year","month","day"],c3=e=>c5.includes(e),c4=(e,t)=>{let n=e.startOfWeek(t);return[0,1,2,3,4,5,6].map(t=>e.addDays(n,t))};var c6=n(49408),c8=n(87716),c9=n(16052);let c7=(0,nJ.Z)((0,c.jsx)("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown"),de=(0,nJ.Z)((0,c.jsx)("path",{d:"M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z"}),"ArrowLeft"),dt=(0,nJ.Z)((0,c.jsx)("path",{d:"M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"}),"ArrowRight");(0,nJ.Z)((0,c.jsx)("path",{d:"M17 12h-5v5h5v-5zM16 1v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-1V1h-2zm3 18H5V8h14v11z"}),"Calendar"),(0,nJ.Z)((0,c.jsxs)(d.Fragment,{children:[(0,c.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),(0,c.jsx)("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Clock");let dn=(0,nJ.Z)((0,c.jsx)("path",{d:"M9 11H7v2h2v-2zm4 0h-2v2h2v-2zm4 0h-2v2h2v-2zm2-7h-1V2h-2v2H8V2H6v2H5c-1.11 0-1.99.9-1.99 2L3 20c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H5V9h14v11z"}),"DateRange"),dr=(0,nJ.Z)((0,c.jsxs)(d.Fragment,{children:[(0,c.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),(0,c.jsx)("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Time"),di=(0,nJ.Z)((0,c.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"}),"Clear"),da=()=>cU().localeText;function ds(e){return(0,S.ZP)("MuiDateTimePickerTabs",e)}(0,C.Z)("MuiDateTimePickerTabs",["root"]);let dl=e=>c3(e)?"date":"time",du=e=>"date"===e?"day":"hours",dc=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"]},ds,t)},dd=(0,y.ZP)(c8.Z,{name:"MuiDateTimePickerTabs",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({boxShadow:`0 -1px 0 0 inset ${(e.vars||e).palette.divider}`,"&:last-child":{boxShadow:`0 1px 0 0 inset ${(e.vars||e).palette.divider}`,[`& .${c9.Z.indicator}`]:{bottom:"auto",top:0}}})),dp=function(e){let t=cV({props:e,name:"MuiDateTimePickerTabs"}),{dateIcon:n=(0,c.jsx)(dn,{}),onViewChange:r,timeIcon:o=(0,c.jsx)(dr,{}),view:i,hidden:a="undefined"==typeof window||window.innerHeight<667,className:s,sx:l}=t,u=da(),p=dc(t);return a?null:(0,c.jsxs)(dd,{ownerState:t,variant:"fullWidth",value:dl(i),onChange:(e,t)=>{r(du(t))},className:(0,f.Z)(s,p.root),sx:l,children:[(0,c.jsx)(c6.Z,{value:"date","aria-label":u.dateTableLabel,icon:(0,c.jsx)(d.Fragment,{children:n})}),(0,c.jsx)(c6.Z,{value:"time","aria-label":u.timeTableLabel,icon:(0,c.jsx)(d.Fragment,{children:o})})]})};function df(e){return(0,S.ZP)("MuiPickersToolbarText",e)}let dh=(0,C.Z)("MuiPickersToolbarText",["root","selected"]),dm=["className","selected","value"],dg=e=>{let{classes:t,selected:n}=e;return(0,h.Z)({root:["root",n&&"selected"]},df,t)},dv=(0,y.ZP)(nQ.Z,{name:"MuiPickersToolbarText",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`&.${dh.selected}`]:t.selected}]})(({theme:e})=>({transition:e.transitions.create("color"),color:(e.vars||e).palette.text.secondary,[`&.${dh.selected}`]:{color:(e.vars||e).palette.text.primary}})),dy=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersToolbarText"}),{className:r,value:o}=n,i=(0,cF.Z)(n,dm),a=dg(n);return(0,c.jsx)(dv,(0,so.Z)({ref:t,className:(0,f.Z)(a.root,r),component:"span"},i,{children:o}))});function db(e){return(0,S.ZP)("MuiPickersToolbar",e)}let dx=(0,C.Z)("MuiPickersToolbar",["root","content"]),dw=["children","className","toolbarTitle","hidden","titleId","isLandscape","classes","landscapeDirection"],dC=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"],content:["content"]},db,t)},dS=(0,y.ZP)("div",{name:"MuiPickersToolbar",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({display:"flex",flexDirection:"column",alignItems:"flex-start",justifyContent:"space-between",padding:e.spacing(2,3),variants:[{props:{isLandscape:!0},style:{height:"auto",maxWidth:160,padding:16,justifyContent:"flex-start",flexWrap:"wrap"}}]})),dM=(0,y.ZP)("div",{name:"MuiPickersToolbar",slot:"Content",overridesResolver:(e,t)=>t.content})({display:"flex",flexWrap:"wrap",width:"100%",flex:1,justifyContent:"space-between",alignItems:"center",flexDirection:"row",variants:[{props:{isLandscape:!0},style:{justifyContent:"flex-start",alignItems:"flex-start",flexDirection:"column"}},{props:{isLandscape:!0,landscapeDirection:"row"},style:{flexDirection:"row"}}]}),dk=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersToolbar"}),{children:r,className:o,toolbarTitle:i,hidden:a,titleId:s}=n,l=(0,cF.Z)(n,dw),u=dC(n);return a?null:(0,c.jsxs)(dS,(0,so.Z)({ref:t,className:(0,f.Z)(u.root,o),ownerState:n},l,{children:[(0,c.jsx)(nQ.Z,{color:"text.secondary",variant:"overline",id:s,children:i}),(0,c.jsx)(dM,{className:u.content,ownerState:n,children:r})]}))}),dE=["align","className","selected","typographyClassName","value","variant","width"],dD=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"]},db,t)},dT=(0,y.ZP)(O.Z,{name:"MuiPickersToolbarButton",slot:"Root",overridesResolver:(e,t)=>t.root})({padding:0,minWidth:16,textTransform:"none"}),dP=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersToolbarButton"}),{align:r,className:o,selected:i,typographyClassName:a,value:s,variant:l,width:u}=n,d=(0,cF.Z)(n,dE),p=dD(n);return(0,c.jsx)(dT,(0,so.Z)({variant:"text",ref:t,className:(0,f.Z)(p.root,o)},u?{sx:{width:u}}:{},d,{children:(0,c.jsx)(dy,{align:r,className:a,variant:l,value:s,selected:i})}))});function dZ(e){return(0,S.ZP)("MuiDateTimePickerToolbar",e)}let dO=(0,C.Z)("MuiDateTimePickerToolbar",["root","dateContainer","timeContainer","timeDigitsContainer","separator","timeLabelReverse","ampmSelection","ampmLandscape","ampmLabel"]),dj=["hours","minutes","seconds"],dR=e=>dj.includes(e),dN=(e,t)=>e?t.getHours(e)>=12?"pm":"am":null,dA=(e,t,n)=>n&&(e>=12?"pm":"am")!==t?"am"===t?e-12:e+12:e,dF=(e,t,n,r)=>{let o=dA(r.getHours(e),t,n);return r.setHours(e,o)},dI=(e,t)=>3600*t.getHours(e)+60*t.getMinutes(e)+t.getSeconds(e),d_=(e,t)=>(n,r)=>e?t.isAfter(n,r):dI(n,t)>dI(r,t);function dL(e,t,n,r){let o=cq();return{meridiemMode:dN(e,o),handleMeridiemChange:d.useCallback(i=>{n(null==e?null:dF(e,i,!!t,o),r??"partial")},[t,e,n,r,o])}}let dV=["ampm","ampmInClock","value","onChange","view","isLandscape","onViewChange","toolbarFormat","toolbarPlaceholder","views","disabled","readOnly","toolbarVariant","toolbarTitle","className"],d$=e=>{let{classes:t,isLandscape:n,isRtl:r}=e;return(0,h.Z)({root:["root"],dateContainer:["dateContainer"],timeContainer:["timeContainer",r&&"timeLabelReverse"],timeDigitsContainer:["timeDigitsContainer",r&&"timeLabelReverse"],separator:["separator"],ampmSelection:["ampmSelection",n&&"ampmLandscape"],ampmLabel:["ampmLabel"]},dZ,t)},dB=(0,y.ZP)(dk,{name:"MuiDateTimePickerToolbar",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({paddingLeft:16,paddingRight:16,justifyContent:"space-around",position:"relative",variants:[{props:{toolbarVariant:"desktop"},style:{borderBottom:`1px solid ${(e.vars||e).palette.divider}`,[`& .${dx.content} .${dh.selected}`]:{color:(e.vars||e).palette.primary.main,fontWeight:e.typography.fontWeightBold}}},{props:{toolbarVariant:"desktop",isLandscape:!0},style:{borderRight:`1px solid ${(e.vars||e).palette.divider}`}},{props:{toolbarVariant:"desktop",isLandscape:!1},style:{paddingLeft:24,paddingRight:0}}]})),dz=(0,y.ZP)("div",{name:"MuiDateTimePickerToolbar",slot:"DateContainer",overridesResolver:(e,t)=>t.dateContainer})({display:"flex",flexDirection:"column",alignItems:"flex-start"}),dH=(0,y.ZP)("div",{name:"MuiDateTimePickerToolbar",slot:"TimeContainer",overridesResolver:(e,t)=>t.timeContainer})({display:"flex",flexDirection:"row",variants:[{props:{isRtl:!0},style:{flexDirection:"row-reverse"}},{props:{toolbarVariant:"desktop",isLandscape:!1},style:{gap:9,marginRight:4,alignSelf:"flex-end"}},{props:({isLandscape:e,toolbarVariant:t})=>e&&"desktop"!==t,style:{flexDirection:"column"}},{props:({isLandscape:e,toolbarVariant:t,isRtl:n})=>e&&"desktop"!==t&&n,style:{flexDirection:"column-reverse"}}]}),dW=(0,y.ZP)("div",{name:"MuiDateTimePickerToolbar",slot:"TimeDigitsContainer",overridesResolver:(e,t)=>t.timeDigitsContainer})({display:"flex",variants:[{props:{isRtl:!0},style:{flexDirection:"row-reverse"}},{props:{toolbarVariant:"desktop"},style:{gap:1.5}}]}),dG=(0,y.ZP)(dy,{name:"MuiDateTimePickerToolbar",slot:"Separator",overridesResolver:(e,t)=>t.separator})({margin:"0 4px 0 2px",cursor:"default",variants:[{props:{toolbarVariant:"desktop"},style:{margin:0}}]}),dU=(0,y.ZP)("div",{name:"MuiDateTimePickerToolbar",slot:"AmPmSelection",overridesResolver:(e,t)=>[{[`.${dO.ampmLabel}`]:t.ampmLabel},{[`&.${dO.ampmLandscape}`]:t.ampmLandscape},t.ampmSelection]})({display:"flex",flexDirection:"column",marginRight:"auto",marginLeft:12,[`& .${dO.ampmLabel}`]:{fontSize:17},variants:[{props:{isLandscape:!0},style:{margin:"4px 0 auto",flexDirection:"row",justifyContent:"space-around",width:"100%"}}]});function dq(e){let t=cV({props:e,name:"MuiDateTimePickerToolbar"}),{ampm:n,ampmInClock:r,value:o,onChange:i,view:a,isLandscape:s,onViewChange:l,toolbarFormat:u,toolbarPlaceholder:p="––",views:h,disabled:m,readOnly:g,toolbarVariant:v="mobile",toolbarTitle:y,className:b}=t,x=(0,cF.Z)(t,dV),w=(0,oz.V)(),C=(0,so.Z)({},t,{isRtl:w}),S=cq(),{meridiemMode:M,handleMeridiemChange:k}=dL(o,n,i),E=!!(n&&!r),D="desktop"===v,T=da(),P=d$(C),Z=y??T.dateTimePickerToolbarTitle,O=d.useMemo(()=>o?u?S.formatByString(o,u):S.format(o,"shortDate"):p,[o,u,p,S]);return(0,c.jsxs)(dB,(0,so.Z)({isLandscape:s,className:(0,f.Z)(P.root,b),toolbarTitle:Z},x,{ownerState:C,children:[(0,c.jsxs)(dz,{className:P.dateContainer,ownerState:C,children:[h.includes("year")&&(0,c.jsx)(dP,{tabIndex:-1,variant:"subtitle1",onClick:()=>l("year"),selected:"year"===a,value:o?S.format(o,"year"):"–"}),h.includes("day")&&(0,c.jsx)(dP,{tabIndex:-1,variant:D?"h5":"h4",onClick:()=>l("day"),selected:"day"===a,value:O})]}),(0,c.jsxs)(dH,{className:P.timeContainer,ownerState:C,children:[(0,c.jsxs)(dW,{className:P.timeDigitsContainer,ownerState:C,children:[h.includes("hours")&&(0,c.jsxs)(d.Fragment,{children:[(0,c.jsx)(dP,{variant:D?"h5":"h3",width:D&&!s?48:void 0,onClick:()=>l("hours"),selected:"hours"===a,value:o?n?S.format(o,"hours12h"):S.format(o,"hours24h"):"--"}),(0,c.jsx)(dG,{variant:D?"h5":"h3",value:":",className:P.separator,ownerState:C}),(0,c.jsx)(dP,{variant:D?"h5":"h3",width:D&&!s?48:void 0,onClick:()=>l("minutes"),selected:"minutes"===a||!h.includes("minutes")&&"hours"===a,value:o?S.format(o,"minutes"):"--",disabled:!h.includes("minutes")})]}),h.includes("seconds")&&(0,c.jsxs)(d.Fragment,{children:[(0,c.jsx)(dG,{variant:D?"h5":"h3",value:":",className:P.separator,ownerState:C}),(0,c.jsx)(dP,{variant:D?"h5":"h3",width:D&&!s?48:void 0,onClick:()=>l("seconds"),selected:"seconds"===a,value:o?S.format(o,"seconds"):"--"})]})]}),E&&!D&&(0,c.jsxs)(dU,{className:P.ampmSelection,ownerState:C,children:[(0,c.jsx)(dP,{variant:"subtitle2",selected:"am"===M,typographyClassName:P.ampmLabel,value:c2(S,"am"),onClick:g?void 0:()=>k("am"),disabled:m}),(0,c.jsx)(dP,{variant:"subtitle2",selected:"pm"===M,typographyClassName:P.ampmLabel,value:c2(S,"pm"),onClick:g?void 0:()=>k("pm"),disabled:m})]}),n&&D&&(0,c.jsx)(dP,{variant:"h5",onClick:()=>l("meridiem"),selected:"meridiem"===a,value:o&&M?c2(S,M):"--",width:48})]})]}))}let dY=({openTo:e,defaultOpenTo:t,views:n,defaultViews:r})=>{let o;let i=n??r;if(null!=e)o=e;else if(i.includes(t))o=t;else if(i.length>0)o=i[0];else throw Error("MUI X: The `views` prop must contain at least one view.");return{views:i,openTo:o}};var dX=n(5056),dK=n(25399);function dQ(e){return(0,S.ZP)("MuiPickersArrowSwitcher",e)}(0,C.Z)("MuiPickersArrowSwitcher",["root","spacer","button","previousIconButton","nextIconButton","leftArrowIcon","rightArrowIcon"]);let dJ=["children","className","slots","slotProps","isNextDisabled","isNextHidden","onGoToNext","nextLabel","isPreviousDisabled","isPreviousHidden","onGoToPrevious","previousLabel","labelId"],d0=["ownerState"],d1=["ownerState"],d2=(0,y.ZP)("div",{name:"MuiPickersArrowSwitcher",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex"}),d5=(0,y.ZP)("div",{name:"MuiPickersArrowSwitcher",slot:"Spacer",overridesResolver:(e,t)=>t.spacer})(({theme:e})=>({width:e.spacing(3)})),d3=(0,y.ZP)(e9.Z,{name:"MuiPickersArrowSwitcher",slot:"Button",overridesResolver:(e,t)=>t.button})({variants:[{props:{hidden:!0},style:{visibility:"hidden"}}]}),d4=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"],spacer:["spacer"],button:["button"],previousIconButton:["previousIconButton"],nextIconButton:["nextIconButton"],leftArrowIcon:["leftArrowIcon"],rightArrowIcon:["rightArrowIcon"]},dQ,t)},d6=d.forwardRef(function(e,t){let n=(0,oz.V)(),r=cV({props:e,name:"MuiPickersArrowSwitcher"}),{children:o,className:i,slots:a,slotProps:s,isNextDisabled:l,isNextHidden:u,onGoToNext:d,nextLabel:p,isPreviousDisabled:h,isPreviousHidden:m,onGoToPrevious:g,previousLabel:v,labelId:y}=r,b=(0,cF.Z)(r,dJ),x=d4(r),w=a?.previousIconButton??d3,C=(0,dK.Z)({elementType:w,externalSlotProps:s?.previousIconButton,additionalProps:{size:"medium",title:v,"aria-label":v,disabled:h,edge:"end",onClick:g},ownerState:(0,so.Z)({},r,{hidden:m}),className:(0,f.Z)(x.button,x.previousIconButton)}),S=a?.nextIconButton??d3,M=(0,dK.Z)({elementType:S,externalSlotProps:s?.nextIconButton,additionalProps:{size:"medium",title:p,"aria-label":p,disabled:l,edge:"start",onClick:d},ownerState:(0,so.Z)({},r,{hidden:u}),className:(0,f.Z)(x.button,x.nextIconButton)}),k=a?.leftArrowIcon??de,E=(0,dK.Z)({elementType:k,externalSlotProps:s?.leftArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:r,className:x.leftArrowIcon}),D=(0,cF.Z)(E,d0),T=a?.rightArrowIcon??dt,P=(0,dK.Z)({elementType:T,externalSlotProps:s?.rightArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:r,className:x.rightArrowIcon}),Z=(0,cF.Z)(P,d1);return(0,c.jsxs)(d2,(0,so.Z)({ref:t,className:(0,f.Z)(x.root,i),ownerState:r},b,{children:[(0,c.jsx)(w,(0,so.Z)({},C,{children:n?(0,c.jsx)(T,(0,so.Z)({},Z)):(0,c.jsx)(k,(0,so.Z)({},D))})),o?(0,c.jsx)(nQ.Z,{variant:"subtitle1",component:"span",id:y,children:o}):(0,c.jsx)(d5,{className:x.spacer,ownerState:r}),(0,c.jsx)(S,(0,so.Z)({},M,{children:n?(0,c.jsx)(k,(0,so.Z)({},D)):(0,c.jsx)(T,(0,so.Z)({},Z))}))]}))});var d8=n(81925),d9=n(9831);function d7({onChange:e,onViewChange:t,openTo:n,view:r,views:o,autoFocus:i,focusedView:a,onFocusedViewChange:s}){let l=d.useRef(n),u=d.useRef(o),c=d.useRef(o.includes(n)?n:o[0]),[p,f]=(0,d9.Z)({name:"useViews",state:"view",controlled:r,default:c.current}),h=d.useRef(i?p:null),[m,g]=(0,d9.Z)({name:"useViews",state:"focusedView",controlled:a,default:h.current});d.useEffect(()=>{(l.current&&l.current!==n||u.current&&u.current.some(e=>!o.includes(e)))&&(f(o.includes(n)?n:o[0]),u.current=o,l.current=n)},[n,f,p,o]);let v=o.indexOf(p),y=o[v-1]??null,b=o[v+1]??null,x=(0,d8.Z)((e,t)=>{t?g(e):g(t=>e===t?null:t),s?.(e,t)}),w=(0,d8.Z)(e=>{x(e,!0),e!==p&&(f(e),t&&t(e))}),C=(0,d8.Z)(()=>{b&&w(b)}),S=(0,d8.Z)((t,n,r)=>{let i="finish"===n,a=r?o.indexOf(r)<o.length-1:!!b;if(e(t,i&&a?"partial":n,r),r&&r!==p){let e=o[o.indexOf(r)+1];e&&w(e)}else i&&C()});return{view:p,setView:w,focusedView:m,setFocusedView:x,nextView:b,previousView:y,defaultView:o.includes(n)?n:o[0],goToNextView:C,setValueAndGoToNextView:S}}let pe=(0,y.ZP)("div")({overflow:"hidden",width:320,maxHeight:336,display:"flex",flexDirection:"column",margin:"0 auto"});function pt(e){return(0,S.ZP)("MuiTimeClock",e)}(0,C.Z)("MuiTimeClock",["root","arrowSwitcher"]);var pn=n(96858);let pr=110,po=110,pi=pr,pa=0,ps=pi-pr,pl=pa-po,pu=e=>180/Math.PI*e,pc=(e,t,n)=>{let r=t-pr,o=n-po,i=pu(Math.atan2(ps,pl)-Math.atan2(r,o));return{value:Math.floor((i=Math.round(i/e)*e%360)/e)||0,distance:Math.sqrt(r**2+o**2)}},pd=(e,t,n=1)=>{let{value:r}=pc(6*n,e,t);return r*n%60},pp=(e,t,n)=>{let{value:r,distance:o}=pc(30,e,t),i=r||12;return n?i%=12:o<74&&(i+=12,i%=24),i};function pf(e){return(0,S.ZP)("MuiClockPointer",e)}(0,C.Z)("MuiClockPointer",["root","thumb"]);let ph=["className","hasSelected","isInner","type","viewValue"],pm=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"],thumb:["thumb"]},pf,t)},pg=(0,y.ZP)("div",{name:"MuiClockPointer",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({width:2,backgroundColor:(e.vars||e).palette.primary.main,position:"absolute",left:"calc(50% - 1px)",bottom:"50%",transformOrigin:"center bottom 0px",variants:[{props:{shouldAnimate:!0},style:{transition:e.transitions.create(["transform","height"])}}]})),pv=(0,y.ZP)("div",{name:"MuiClockPointer",slot:"Thumb",overridesResolver:(e,t)=>t.thumb})(({theme:e})=>({width:4,height:4,backgroundColor:(e.vars||e).palette.primary.contrastText,borderRadius:"50%",position:"absolute",top:-21,left:"calc(50% - 18px)",border:`16px solid ${(e.vars||e).palette.primary.main}`,boxSizing:"content-box",variants:[{props:{hasSelected:!0},style:{backgroundColor:(e.vars||e).palette.primary.main}}]}));function py(e){let t;let n=cV({props:e,name:"MuiClockPointer"}),{className:r,isInner:o,type:i,viewValue:a}=n,s=(0,cF.Z)(n,ph),l=d.useRef(i);d.useEffect(()=>{l.current=i},[i]);let u=(0,so.Z)({},n,{shouldAnimate:l.current!==i}),p=pm(u);return(0,c.jsx)(pg,(0,so.Z)({style:(t=360/("hours"===i?12:60)*a,"hours"===i&&a>12&&(t-=360),{height:Math.round((o?.26:.4)*220),transform:`rotateZ(${t}deg)`}),className:(0,f.Z)(p.root,r),ownerState:u},s,{children:(0,c.jsx)(pv,{ownerState:u,className:p.thumb})}))}function pb(e){return(0,S.ZP)("MuiClock",e)}(0,C.Z)("MuiClock",["root","clock","wrapper","squareMask","pin","amButton","pmButton","meridiemText","selected"]);let px=e=>{let{classes:t,meridiemMode:n}=e;return(0,h.Z)({root:["root"],clock:["clock"],wrapper:["wrapper"],squareMask:["squareMask"],pin:["pin"],amButton:["amButton","am"===n&&"selected"],pmButton:["pmButton","pm"===n&&"selected"],meridiemText:["meridiemText"]},pb,t)},pw=(0,y.ZP)("div",{name:"MuiClock",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>({display:"flex",justifyContent:"center",alignItems:"center",margin:e.spacing(2)})),pC=(0,y.ZP)("div",{name:"MuiClock",slot:"Clock",overridesResolver:(e,t)=>t.clock})({backgroundColor:"rgba(0,0,0,.07)",borderRadius:"50%",height:220,width:220,flexShrink:0,position:"relative",pointerEvents:"none"}),pS=(0,y.ZP)("div",{name:"MuiClock",slot:"Wrapper",overridesResolver:(e,t)=>t.wrapper})({"&:focus":{outline:"none"}}),pM=(0,y.ZP)("div",{name:"MuiClock",slot:"SquareMask",overridesResolver:(e,t)=>t.squareMask})({width:"100%",height:"100%",position:"absolute",pointerEvents:"auto",outline:0,touchAction:"none",userSelect:"none",variants:[{props:{disabled:!1},style:{"@media (pointer: fine)":{cursor:"pointer",borderRadius:"50%"},"&:active":{cursor:"move"}}}]}),pk=(0,y.ZP)("div",{name:"MuiClock",slot:"Pin",overridesResolver:(e,t)=>t.pin})(({theme:e})=>({width:6,height:6,borderRadius:"50%",backgroundColor:(e.vars||e).palette.primary.main,position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"})),pE=(e,t)=>({zIndex:1,bottom:8,paddingLeft:4,paddingRight:4,width:36,variants:[{props:{meridiemMode:t},style:{backgroundColor:(e.vars||e).palette.primary.main,color:(e.vars||e).palette.primary.contrastText,"&:hover":{backgroundColor:(e.vars||e).palette.primary.light}}}]}),pD=(0,y.ZP)(e9.Z,{name:"MuiClock",slot:"AmButton",overridesResolver:(e,t)=>t.amButton})(({theme:e})=>(0,so.Z)({},pE(e,"am"),{position:"absolute",left:8})),pT=(0,y.ZP)(e9.Z,{name:"MuiClock",slot:"PmButton",overridesResolver:(e,t)=>t.pmButton})(({theme:e})=>(0,so.Z)({},pE(e,"pm"),{position:"absolute",right:8})),pP=(0,y.ZP)(nQ.Z,{name:"MuiClock",slot:"meridiemText",overridesResolver:(e,t)=>t.meridiemText})({overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"});function pZ(e){let t=cV({props:e,name:"MuiClock"}),{ampm:n,ampmInClock:r,autoFocus:o,children:i,value:a,handleMeridiemChange:s,isTimeDisabled:l,meridiemMode:u,minutesStep:p=1,onChange:h,selectedId:m,type:g,viewValue:v,viewRange:[y,b],disabled:x=!1,readOnly:w,className:C}=t,S=cq(),M=da(),k=d.useRef(!1),E=px(t),D=l(v,g),T=!n&&"hours"===g&&(v<1||v>12),P=(e,t)=>{!(x||w||l(e,g))&&h(e,t)},Z=(e,t)=>{let{offsetX:r,offsetY:o}=e;if(void 0===r){let t=e.target.getBoundingClientRect();r=e.changedTouches[0].clientX-t.left,o=e.changedTouches[0].clientY-t.top}P("seconds"===g||"minutes"===g?pd(r,o,p):pp(r,o,!!n),t)},O=e=>{k.current=!0,Z(e,"shallow")},j=d.useMemo(()=>"hours"===g||v%5==0,[g,v]),R="minutes"===g?p:1,N=d.useRef(null);(0,pn.Z)(()=>{o&&N.current.focus()},[o]);let A=e=>Math.max(y,Math.min(b,e)),F=e=>(e+(b+1))%(b+1);return(0,c.jsxs)(pw,{className:(0,f.Z)(E.root,C),children:[(0,c.jsxs)(pC,{className:E.clock,children:[(0,c.jsx)(pM,{onTouchMove:O,onTouchStart:O,onTouchEnd:e=>{k.current&&(Z(e,"finish"),k.current=!1),e.preventDefault()},onMouseUp:e=>{k.current&&(k.current=!1),Z(e.nativeEvent,"finish")},onMouseMove:e=>{e.buttons>0&&Z(e.nativeEvent,"shallow")},ownerState:{disabled:x},className:E.squareMask}),!D&&(0,c.jsxs)(d.Fragment,{children:[(0,c.jsx)(pk,{className:E.pin}),null!=a&&(0,c.jsx)(py,{type:g,viewValue:v,isInner:T,hasSelected:j})]}),(0,c.jsx)(pS,{"aria-activedescendant":m,"aria-label":M.clockLabelText(g,a,S,null==a?null:S.format(a,"fullTime")),ref:N,role:"listbox",onKeyDown:e=>{if(!k.current)switch(e.key){case"Home":P(y,"partial"),e.preventDefault();break;case"End":P(b,"partial"),e.preventDefault();break;case"ArrowUp":P(F(v+R),"partial"),e.preventDefault();break;case"ArrowDown":P(F(v-R),"partial"),e.preventDefault();break;case"PageUp":P(A(v+5),"partial"),e.preventDefault();break;case"PageDown":P(A(v-5),"partial"),e.preventDefault();break;case"Enter":case" ":P(v,"finish"),e.preventDefault()}},tabIndex:0,className:E.wrapper,children:i})]}),n&&r&&(0,c.jsxs)(d.Fragment,{children:[(0,c.jsx)(pD,{onClick:w?void 0:()=>s("am"),disabled:x||null===u,ownerState:t,className:E.amButton,title:c2(S,"am"),children:(0,c.jsx)(pP,{variant:"caption",className:E.meridiemText,children:c2(S,"am")})}),(0,c.jsx)(pT,{disabled:x||null===u,onClick:w?void 0:()=>s("pm"),ownerState:t,className:E.pmButton,title:c2(S,"pm"),children:(0,c.jsx)(pP,{variant:"caption",className:E.meridiemText,children:c2(S,"pm")})})]})]})}function pO(e){return(0,S.ZP)("MuiClockNumber",e)}let pj=(0,C.Z)("MuiClockNumber",["root","selected","disabled"]),pR=["className","disabled","index","inner","label","selected"],pN=e=>{let{classes:t,selected:n,disabled:r}=e;return(0,h.Z)({root:["root",n&&"selected",r&&"disabled"]},pO,t)},pA=(0,y.ZP)("span",{name:"MuiClockNumber",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`&.${pj.disabled}`]:t.disabled},{[`&.${pj.selected}`]:t.selected}]})(({theme:e})=>({height:36,width:36,position:"absolute",left:"calc((100% - 36px) / 2)",display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"50%",color:(e.vars||e).palette.text.primary,fontFamily:e.typography.fontFamily,"&:focused":{backgroundColor:(e.vars||e).palette.background.paper},[`&.${pj.selected}`]:{color:(e.vars||e).palette.primary.contrastText},[`&.${pj.disabled}`]:{pointerEvents:"none",color:(e.vars||e).palette.text.disabled},variants:[{props:{inner:!0},style:(0,so.Z)({},e.typography.body2,{color:(e.vars||e).palette.text.secondary})}]}));function pF(e){let t=cV({props:e,name:"MuiClockNumber"}),{className:n,disabled:r,index:o,inner:i,label:a,selected:s}=t,l=(0,cF.Z)(t,pR),u=pN(t),d=o%12/12*Math.PI*2-Math.PI/2,p=91*(i?.65:1),h=Math.round(Math.cos(d)*p),m=Math.round(Math.sin(d)*p);return(0,c.jsx)(pA,(0,so.Z)({className:(0,f.Z)(u.root,n),"aria-disabled":!!r||void 0,"aria-selected":!!s||void 0,role:"option",style:{transform:`translate(${h}px, ${m+92}px`},ownerState:t},l,{children:a}))}let pI=({ampm:e,value:t,getClockNumberText:n,isDisabled:r,selectedId:o,utils:i})=>{let a=t?i.getHours(t):null,s=[],l=+!!e,u=e?12:23,d=t=>null!==a&&(e?12===t?12===a||0===a:a===t||a-12===t:a===t);for(let t=l;t<=u;t+=1){let a=t.toString();0===t&&(a="00");let l=!e&&(0===t||t>12);a=i.formatNumber(a);let u=d(t);s.push((0,c.jsx)(pF,{id:u?o:void 0,index:t,inner:l,selected:u,disabled:r(t),label:a,"aria-label":n(a)},t))}return s},p_=({utils:e,value:t,isDisabled:n,getClockNumberText:r,selectedId:o})=>{let i=e.formatNumber;return[[5,i("05")],[10,i("10")],[15,i("15")],[20,i("20")],[25,i("25")],[30,i("30")],[35,i("35")],[40,i("40")],[45,i("45")],[50,i("50")],[55,i("55")],[0,i("00")]].map(([e,i],a)=>{let s=e===t;return(0,c.jsx)(pF,{label:i,id:s?o:void 0,index:a+1,inner:!1,disabled:n(e),selected:s,"aria-label":r(i)},e)})},pL=({timezone:e,value:t,defaultValue:n,referenceDate:r,onChange:o,valueManager:i})=>{let a;let s=cq(),l=d.useRef(n),u=t??l.current??i.emptyValue,c=d.useMemo(()=>i.getTimezone(s,u),[s,i,u]),p=(0,d8.Z)(e=>null==c?e:i.setTimezone(s,c,e));return a=e||c||(r?s.getTimezone(r):"default"),{value:d.useMemo(()=>i.setTimezone(s,a,u),[i,s,a,u]),handleValueChange:(0,d8.Z)((e,...t)=>{let n=p(e);o?.(n,...t)}),timezone:a}},pV=({name:e,timezone:t,value:n,defaultValue:r,referenceDate:o,onChange:i,valueManager:a})=>{let[s,l]=(0,d9.Z)({name:e,state:"value",controlled:n,default:r??a.emptyValue});return pL({timezone:t,value:s,defaultValue:void 0,referenceDate:o,onChange:(0,d8.Z)((e,...t)=>{l(e),i?.(e,...t)}),valueManager:a})},p$={year:1,month:2,day:3,hours:4,minutes:5,seconds:6,milliseconds:7},pB=e=>Math.max(...e.map(e=>p$[e.type]??1)),pz=(e,t,n)=>{if(t===p$.year)return e.startOfYear(n);if(t===p$.month)return e.startOfMonth(n);if(t===p$.day)return e.startOfDay(n);let r=n;return t<p$.minutes&&(r=e.setMinutes(r,0)),t<p$.seconds&&(r=e.setSeconds(r,0)),t<p$.milliseconds&&(r=e.setMilliseconds(r,0)),r},pH=({props:e,utils:t,granularity:n,timezone:r,getTodayDate:o})=>{let i=o?o():pz(t,n,c1(t,r));null!=e.minDate&&t.isAfterDay(e.minDate,i)&&(i=pz(t,n,e.minDate)),null!=e.maxDate&&t.isBeforeDay(e.maxDate,i)&&(i=pz(t,n,e.maxDate));let a=d_(e.disableIgnoringDatePartForTimeValidation??!1,t);return null!=e.minTime&&a(e.minTime,i)&&(i=pz(t,n,e.disableIgnoringDatePartForTimeValidation?e.minTime:cK(t,i,e.minTime))),null!=e.maxTime&&a(i,e.maxTime)&&(i=pz(t,n,e.disableIgnoringDatePartForTimeValidation?e.maxTime:cK(t,i,e.maxTime))),i},pW=(e,t)=>{let n=e.formatTokenMap[t];if(null==n)throw Error(`MUI X: The token "${t}" is not supported by the Date and Time Pickers.
|
|
7
|
+
Please try using another token or open an issue on https://github.com/mui/mui-x/issues/new/choose if you think it should be supported.`);return"string"==typeof n?{type:n,contentType:"meridiem"===n?"letter":"digit",maxLength:void 0}:{type:n.sectionType,contentType:n.contentType,maxLength:n.maxLength}},pG=e=>{switch(e){case"ArrowUp":return 1;case"ArrowDown":return -1;case"PageUp":return 5;case"PageDown":return -5;default:return 0}},pU=(e,t)=>{let n=[],r=e.date(void 0,"default"),o=e.startOfWeek(r),i=e.endOfWeek(r),a=o;for(;e.isBefore(a,i);)n.push(a),a=e.addDays(a,1);return n.map(n=>e.formatByString(n,t))},pq=(e,t,n,r)=>{switch(n){case"month":return c0(e,e.date(void 0,t)).map(t=>e.formatByString(t,r));case"weekDay":return pU(e,r);case"meridiem":{let n=e.date(void 0,t);return[e.startOfDay(n),e.endOfDay(n)].map(t=>e.formatByString(t,r))}default:return[]}},pY=["0","1","2","3","4","5","6","7","8","9"],pX=e=>{let t=e.date(void 0);return"0"===e.formatByString(e.setSeconds(t,0),"s")?pY:Array.from({length:10}).map((n,r)=>e.formatByString(e.setSeconds(t,r),"s"))},pK=(e,t)=>{if("0"===t[0])return e;let n=[],r="";for(let o=0;o<e.length;o+=1){r+=e[o];let i=t.indexOf(r);i>-1&&(n.push(i.toString()),r="")}return n.join("")},pQ=(e,t)=>"0"===t[0]?e:e.split("").map(e=>t[Number(e)]).join(""),pJ=(e,t)=>{let n=pK(e,t);return" "!==n&&!Number.isNaN(Number(n))},p0=(e,t)=>{let n=e;for(n=Number(n).toString();n.length<t;)n=`0${n}`;return n},p1=(e,t,n,r,o)=>{if("day"===o.type&&"digit-with-letter"===o.contentType){let r=e.setDate(n.longestMonth,t);return e.formatByString(r,o.format)}let i=t.toString();return o.hasLeadingZerosInInput&&(i=p0(i,o.maxLength)),pQ(i,r)},p2=(e,t,n,r,o,i,a,s)=>{let l=pG(r),u="Home"===r,c="End"===r,d=""===n.value||u||c;return"digit"===n.contentType||"digit-with-letter"===n.contentType?(()=>{let r=o[n.type]({currentDate:a,format:n.format,contentType:n.contentType}),p=t=>p1(e,t,r,i,n),f="minutes"===n.type&&s?.minutesStep?s.minutesStep:1,h=parseInt(pK(n.value,i),10)+l*f;if(d){if("year"===n.type&&!c&&!u)return e.formatByString(e.date(void 0,t),n.format);h=l>0||u?r.minimum:r.maximum}return p((h%f!=0&&((l<0||u)&&(h+=f-(f+h)%f),(l>0||c)&&(h-=h%f)),h>r.maximum)?r.minimum+(h-r.maximum-1)%(r.maximum-r.minimum+1):h<r.minimum?r.maximum-(r.minimum-h-1)%(r.maximum-r.minimum+1):h)})():(()=>{let r=pq(e,t,n.type,n.format);if(0===r.length)return n.value;if(d)return l>0||u?r[0]:r[r.length-1];let o=((r.indexOf(n.value)+l)%r.length+r.length)%r.length;return r[o]})()},p5=(e,t,n)=>{let r=e.value||e.placeholder,o="non-input"===t?e.hasLeadingZerosInFormat:e.hasLeadingZerosInInput;return"non-input"===t&&e.hasLeadingZerosInInput&&!e.hasLeadingZerosInFormat&&(r=Number(pK(r,n)).toString()),["input-rtl","input-ltr"].includes(t)&&"digit"===e.contentType&&!o&&1===r.length&&(r=`${r}\u200e`),"input-rtl"===t&&(r=`\u2068${r}\u2069`),r},p3=(e,t,n,r)=>e.formatByString(e.parse(t,n),r),p4=(e,t)=>4===e.formatByString(e.date(void 0,"system"),t).length,p6=(e,t,n,r)=>{if("digit"!==t)return!1;let o=e.date(void 0,"default");switch(n){case"year":if(p4(e,r))return"0001"===e.formatByString(e.setYear(o,1),r);return"01"===e.formatByString(e.setYear(o,2001),r);case"month":return e.formatByString(e.startOfYear(o),r).length>1;case"day":return e.formatByString(e.startOfMonth(o),r).length>1;case"weekDay":return e.formatByString(e.startOfWeek(o),r).length>1;case"hours":return e.formatByString(e.setHours(o,1),r).length>1;case"minutes":return e.formatByString(e.setMinutes(o,1),r).length>1;case"seconds":return e.formatByString(e.setSeconds(o,1),r).length>1;default:throw Error("Invalid section type")}},p8=(e,t,n)=>{let r=t.some(e=>"day"===e.type),o=[],i=[];for(let e=0;e<t.length;e+=1){let a=t[e];r&&"weekDay"===a.type||(o.push(a.format),i.push(p5(a,"non-input",n)))}let a=o.join(" "),s=i.join(" ");return e.parse(s,a)},p9=(e,t,n)=>{let r=e.date(void 0,n),o=e.endOfYear(r),i=e.endOfDay(r),{maxDaysInMonth:a,longestMonth:s}=c0(e,r).reduce((t,n)=>{let r=e.getDaysInMonth(n);return r>t.maxDaysInMonth?{maxDaysInMonth:r,longestMonth:n}:t},{maxDaysInMonth:0,longestMonth:null});return{year:({format:t})=>({minimum:0,maximum:p4(e,t)?9999:99}),month:()=>({minimum:1,maximum:e.getMonth(o)+1}),day:({currentDate:t})=>({minimum:1,maximum:null!=t&&e.isValid(t)?e.getDaysInMonth(t):a,longestMonth:s}),weekDay:({format:t,contentType:n})=>{if("digit"===n){let n=pU(e,t).map(Number);return{minimum:Math.min(...n),maximum:Math.max(...n)}}return{minimum:1,maximum:7}},hours:({format:n})=>{let o=e.getHours(i);return pK(e.formatByString(e.endOfDay(r),n),t)!==o.toString()?{minimum:1,maximum:Number(pK(e.formatByString(e.startOfDay(r),n),t))}:{minimum:0,maximum:o}},minutes:()=>({minimum:0,maximum:e.getMinutes(i)}),seconds:()=>({minimum:0,maximum:e.getSeconds(i)}),meridiem:()=>({minimum:0,maximum:1}),empty:()=>({minimum:0,maximum:0})}},p7=(e,t)=>{},fe=(e,t,n,r)=>{switch(t.type){case"year":return e.setYear(r,e.getYear(n));case"month":return e.setMonth(r,e.getMonth(n));case"weekDay":{let r=pU(e,t.format),o=e.formatByString(n,t.format),i=r.indexOf(o),a=r.indexOf(t.value);return e.addDays(n,a-i)}case"day":return e.setDate(r,e.getDate(n));case"meridiem":{let t=12>e.getHours(n),o=e.getHours(r);if(t&&o>=12)return e.addHours(r,-12);if(!t&&o<12)return e.addHours(r,12);return r}case"hours":return e.setHours(r,e.getHours(n));case"minutes":return e.setMinutes(r,e.getMinutes(n));case"seconds":return e.setSeconds(r,e.getSeconds(n));default:return r}},ft={year:1,month:2,day:3,weekDay:4,hours:5,minutes:6,seconds:7,meridiem:8,empty:9},fn=(e,t,n,r,o)=>[...n].sort((e,t)=>ft[e.type]-ft[t.type]).reduce((n,r)=>!o||r.modified?fe(e,r,t,n):n,r),fr=()=>navigator.userAgent.toLowerCase().includes("android"),fo=(e,t)=>{let n={};if(!t)return e.forEach((t,r)=>{let o=r===e.length-1?null:r+1;n[r]={leftIndex:0===r?null:r-1,rightIndex:o}}),{neighbors:n,startIndex:0,endIndex:e.length-1};let r={},o={},i=0,a=0,s=e.length-1;for(;s>=0;){-1===(a=e.findIndex((e,t)=>t>=i&&e.endSeparator?.includes(" ")&&" / "!==e.endSeparator))&&(a=e.length-1);for(let e=a;e>=i;e-=1)o[e]=s,r[s]=e,s-=1;i=a+1}return e.forEach((t,i)=>{let a=o[i],s=0===a?null:r[a-1],l=a===e.length-1?null:r[a+1];n[i]={leftIndex:s,rightIndex:l}}),{neighbors:n,startIndex:r[0],endIndex:r[e.length-1]}},fi=(e,t)=>{if(null==e)return null;if("all"===e)return"all";if("string"==typeof e){let n=t.findIndex(t=>t.type===e);return -1===n?null:n}return e},fa=(e,t)=>{if(e.value)switch(e.type){case"month":{if("digit"===e.contentType)return t.format(t.setMonth(t.date(),Number(e.value)-1),"month");let n=t.parse(e.value,e.format);return n?t.format(n,"month"):void 0}case"day":return"digit"===e.contentType?t.format(t.setDate(t.startOfYear(t.date()),Number(e.value)),"dayOfMonthFull"):e.value;default:return}},fs=(e,t)=>{if(e.value)switch(e.type){case"weekDay":if("letter"===e.contentType)return;return Number(e.value);case"meridiem":{let n=t.parse(`01:00 ${e.value}`,`${t.formats.hours12h}:${t.formats.minutes} ${e.format}`);if(n)return+(t.getHours(n)>=12);return}case"day":return"digit-with-letter"===e.contentType?parseInt(e.value,10):Number(e.value);case"month":{if("digit"===e.contentType)return Number(e.value);let n=t.parse(e.value,e.format);return n?t.getMonth(n)+1:void 0}default:return"letter"!==e.contentType?Number(e.value):void 0}},fl=["value","referenceDate"],fu={emptyValue:null,getTodayValue:c1,getInitialReferenceValue:e=>{let{value:t,referenceDate:n}=e,r=(0,cF.Z)(e,fl);return null!=t&&r.utils.isValid(t)?t:null!=n?n:pH(r)},cleanValue:(e,t)=>null!=t&&e.isValid(t)?t:null,areValuesEqual:(e,t,n)=>!(e.isValid(t)||null==t||e.isValid(n))&&null!=n||e.isEqual(t,n),isSameError:(e,t)=>e===t,hasError:e=>null!=e,defaultErrorState:null,getTimezone:(e,t)=>null!=t&&e.isValid(t)?e.getTimezone(t):null,setTimezone:(e,t,n)=>null==n?null:e.setTimezone(n,t)},fc={updateReferenceValue:(e,t,n)=>null!=t&&e.isValid(t)?t:n,getSectionsFromValue:(e,t,n,r)=>!e.isValid(t)&&n?n:r(t),getV7HiddenInputValueFromSections:e=>e.map(e=>`${e.startSeparator}${e.value||e.placeholder}${e.endSeparator}`).join(""),getV6InputValueFromSections:(e,t,n)=>{let r=e.map(e=>{let r=p5(e,n?"input-rtl":"input-ltr",t);return`${e.startSeparator}${r}${e.endSeparator}`}).join("");return n?`\u2066${r}\u2069`:r},getActiveDateManager:(e,t)=>({date:t.value,referenceDate:t.referenceValue,getSections:e=>e,getNewValuesFromNewActiveDate:n=>({value:n,referenceValue:null!=n&&e.isValid(n)?n:t.referenceValue})}),parseValueStr:(e,t,n)=>n(e.trim(),t)},fd=({value:e,referenceDate:t,utils:n,props:r,timezone:o})=>{let i=d.useMemo(()=>fu.getInitialReferenceValue({value:e,utils:n,props:r,referenceDate:t,granularity:p$.day,timezone:o,getTodayDate:()=>c1(n,o,"date")}),[]);return e??i},fp=["ampm","ampmInClock","autoFocus","slots","slotProps","value","defaultValue","referenceDate","disableIgnoringDatePartForTimeValidation","maxTime","minTime","disableFuture","disablePast","minutesStep","shouldDisableTime","showViewSwitcher","onChange","view","views","openTo","onViewChange","focusedView","onFocusedViewChange","className","disabled","readOnly","timezone"],ff=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"],arrowSwitcher:["arrowSwitcher"]},pt,t)},fh=(0,y.ZP)(pe,{name:"MuiTimeClock",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"column",position:"relative"}),fm=(0,y.ZP)(d6,{name:"MuiTimeClock",slot:"ArrowSwitcher",overridesResolver:(e,t)=>t.arrowSwitcher})({position:"absolute",right:12,top:15}),fg=["hours","minutes"],fv=d.forwardRef(function(e,t){let n=cq(),r=cV({props:e,name:"MuiTimeClock"}),{ampm:o=n.is12HourCycleInCurrentLocale(),ampmInClock:i=!1,autoFocus:a,slots:s,slotProps:l,value:u,defaultValue:p,referenceDate:h,disableIgnoringDatePartForTimeValidation:m=!1,maxTime:g,minTime:v,disableFuture:y,disablePast:b,minutesStep:x=1,shouldDisableTime:w,showViewSwitcher:C,onChange:S,view:M,views:k=fg,openTo:E,onViewChange:D,focusedView:T,onFocusedViewChange:P,className:Z,disabled:O,readOnly:j,timezone:R}=r,N=(0,cF.Z)(r,fp),{value:A,handleValueChange:F,timezone:I}=pV({name:"TimeClock",timezone:R,value:u,defaultValue:p,referenceDate:h,onChange:S,valueManager:fu}),_=fd({value:A,referenceDate:h,utils:n,props:r,timezone:I}),L=da(),V=cX(I),{view:$,setView:B,previousView:z,nextView:H,setValueAndGoToNextView:W}=d7({view:M,views:k,openTo:E,onViewChange:D,onChange:F,focusedView:T,onFocusedViewChange:P}),{meridiemMode:G,handleMeridiemChange:U}=dL(_,o,W),q=d.useCallback((e,t)=>{let r=d_(m,n),i="hours"===t||"minutes"===t&&k.includes("seconds"),a=({start:e,end:t})=>!(v&&r(v,t)||g&&r(e,g)||y&&r(e,V)||b&&r(V,i?t:e)),s=(e,r=1)=>{if(e%r!=0)return!1;if(w)switch(t){case"hours":return!w(n.setHours(_,e),"hours");case"minutes":return!w(n.setMinutes(_,e),"minutes");case"seconds":return!w(n.setSeconds(_,e),"seconds");default:return!1}return!0};switch(t){case"hours":{let t=dA(e,G,o),r=n.setHours(_,t);if(n.getHours(r)!==t)return!0;return!a({start:n.setSeconds(n.setMinutes(r,0),0),end:n.setSeconds(n.setMinutes(r,59),59)})||!s(t)}case"minutes":{let t=n.setMinutes(_,e);return!a({start:n.setSeconds(t,0),end:n.setSeconds(t,59)})||!s(e,x)}case"seconds":{let t=n.setSeconds(_,e);return!a({start:t,end:t})||!s(e)}default:throw Error("not supported")}},[o,_,m,g,G,v,x,w,n,y,b,V,k]),Y=(0,dX.Z)(),X=d.useMemo(()=>{switch($){case"hours":{let e;let t=(e,t)=>{let r=dA(e,G,o);W(n.setHours(_,r),t,"hours")},r=n.getHours(_);return e=o?r>12?[12,23]:[0,11]:[0,23],{onChange:t,viewValue:r,children:pI({value:A,utils:n,ampm:o,onChange:t,getClockNumberText:L.hoursClockNumberText,isDisabled:e=>O||q(e,"hours"),selectedId:Y}),viewRange:e}}case"minutes":{let e=n.getMinutes(_),t=(e,t)=>{W(n.setMinutes(_,e),t,"minutes")};return{viewValue:e,onChange:t,children:p_({utils:n,value:e,onChange:t,getClockNumberText:L.minutesClockNumberText,isDisabled:e=>O||q(e,"minutes"),selectedId:Y}),viewRange:[0,59]}}case"seconds":{let e=n.getSeconds(_),t=(e,t)=>{W(n.setSeconds(_,e),t,"seconds")};return{viewValue:e,onChange:t,children:p_({utils:n,value:e,onChange:t,getClockNumberText:L.secondsClockNumberText,isDisabled:e=>O||q(e,"seconds"),selectedId:Y}),viewRange:[0,59]}}default:throw Error("You must provide the type for ClockView")}},[$,n,A,o,L.hoursClockNumberText,L.minutesClockNumberText,L.secondsClockNumberText,G,W,_,q,Y,O]),K=ff(r);return(0,c.jsxs)(fh,(0,so.Z)({ref:t,className:(0,f.Z)(K.root,Z),ownerState:r},N,{children:[(0,c.jsx)(pZ,(0,so.Z)({autoFocus:a??!!T,ampmInClock:i&&k.includes("hours"),value:A,type:$,ampm:o,minutesStep:x,isTimeDisabled:q,meridiemMode:G,handleMeridiemChange:U,selectedId:Y,disabled:O,readOnly:j},X)),C&&(0,c.jsx)(fm,{className:K.arrowSwitcher,slots:s,slotProps:l,onGoToPrevious:()=>B(z),isPreviousDisabled:!z,previousLabel:L.openPreviousView,onGoToNext:()=>B(H),isNextDisabled:!H,nextLabel:L.openNextView,ownerState:r})]}))}),fy=({view:e,onViewChange:t,focusedView:n,onFocusedViewChange:r,views:o,value:i,defaultValue:a,referenceDate:s,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minTime:h,maxTime:m,shouldDisableTime:g,minutesStep:v,ampm:y,ampmInClock:b,slots:x,slotProps:w,readOnly:C,disabled:S,sx:M,autoFocus:k,showViewSwitcher:E,disableIgnoringDatePartForTimeValidation:D,timezone:T})=>(0,c.jsx)(fv,{view:e,onViewChange:t,focusedView:n&&dR(n)?n:null,onFocusedViewChange:r,views:o.filter(dR),value:i,defaultValue:a,referenceDate:s,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minTime:h,maxTime:m,shouldDisableTime:g,minutesStep:v,ampm:y,ampmInClock:b,slots:x,slotProps:w,readOnly:C,disabled:S,sx:M,autoFocus:k,showViewSwitcher:E,disableIgnoringDatePartForTimeValidation:D,timezone:T}),fb=({props:e,value:t,timezone:n,adapter:r})=>{if(null===t)return null;let{shouldDisableDate:o,shouldDisableMonth:i,shouldDisableYear:a,disablePast:s,disableFuture:l}=e,u=r.utils.date(void 0,n),c=cJ(r.utils,e.minDate,r.defaultDates.minDate),d=cJ(r.utils,e.maxDate,r.defaultDates.maxDate);switch(!0){case!r.utils.isValid(t):return"invalidDate";case!!(o&&o(t)):return"shouldDisableDate";case!!(i&&i(t)):return"shouldDisableMonth";case!!(a&&a(t)):return"shouldDisableYear";case!!(l&&r.utils.isAfterDay(t,u)):return"disableFuture";case!!(s&&r.utils.isBeforeDay(t,u)):return"disablePast";case!!(c&&r.utils.isBeforeDay(t,c)):return"minDate";case!!(d&&r.utils.isAfterDay(t,d)):return"maxDate";default:return null}};fb.valueManager=fu;let fx=({shouldDisableDate:e,shouldDisableMonth:t,shouldDisableYear:n,minDate:r,maxDate:o,disableFuture:i,disablePast:a,timezone:s})=>{let l=cU();return d.useCallback(u=>null!==fb({adapter:l,value:u,timezone:s,props:{shouldDisableDate:e,shouldDisableMonth:t,shouldDisableYear:n,minDate:r,maxDate:o,disableFuture:i,disablePast:a}}),[l,e,t,n,r,o,i,a,s])},fw=(e,t,n)=>(r,o)=>{switch(o.type){case"changeMonth":return(0,so.Z)({},r,{slideDirection:o.direction,currentMonth:o.newMonth,isMonthSwitchingAnimating:!e});case"changeMonthTimezone":{let e=o.newTimezone;if(n.getTimezone(r.currentMonth)===e)return r;let t=n.setTimezone(r.currentMonth,e);return n.getMonth(t)!==n.getMonth(r.currentMonth)&&(t=n.setMonth(t,n.getMonth(r.currentMonth))),(0,so.Z)({},r,{currentMonth:t})}case"finishMonthSwitchingAnimation":return(0,so.Z)({},r,{isMonthSwitchingAnimating:!1});case"changeFocusedDay":{if(null!=r.focusedDay&&null!=o.focusedDay&&n.isSameDay(o.focusedDay,r.focusedDay))return r;let i=null!=o.focusedDay&&!t&&!n.isSameMonth(r.currentMonth,o.focusedDay);return(0,so.Z)({},r,{focusedDay:o.focusedDay,isMonthSwitchingAnimating:i&&!e&&!o.withoutMonthSwitchingAnimation,currentMonth:i?n.startOfMonth(o.focusedDay):r.currentMonth,slideDirection:null!=o.focusedDay&&n.isAfterDay(o.focusedDay,r.currentMonth)?"left":"right"})}default:throw Error("missing support")}},fC=e=>{let{value:t,referenceDate:n,disableFuture:r,disablePast:o,disableSwitchToMonthOnDayFocus:i=!1,maxDate:a,minDate:s,onMonthChange:l,reduceAnimations:u,shouldDisableDate:c,timezone:p}=e,f=cq(),h=d.useRef(fw(!!u,i,f)).current,m=d.useMemo(()=>fu.getInitialReferenceValue({value:t,utils:f,timezone:p,props:e,referenceDate:n,granularity:p$.day}),[n,p]),[g,v]=d.useReducer(h,{isMonthSwitchingAnimating:!1,focusedDay:m,currentMonth:f.startOfMonth(m),slideDirection:"left"});d.useEffect(()=>{v({type:"changeMonthTimezone",newTimezone:f.getTimezone(m)})},[m,f]);let y=d.useCallback(e=>{v((0,so.Z)({type:"changeMonth"},e)),l&&l(e.newMonth)},[l]),b=d.useCallback(e=>{!f.isSameMonth(e,g.currentMonth)&&y({newMonth:f.startOfMonth(e),direction:f.isAfterDay(e,g.currentMonth)?"left":"right"})},[g.currentMonth,y,f]),x=fx({shouldDisableDate:c,minDate:s,maxDate:a,disableFuture:r,disablePast:o,timezone:p}),w=d.useCallback(()=>{v({type:"finishMonthSwitchingAnimation"})},[]);return{referenceDate:m,calendarState:g,changeMonth:b,changeFocusedDay:(0,d8.Z)((e,t)=>{x(e)||v({type:"changeFocusedDay",focusedDay:e,withoutMonthSwitchingAnimation:t})}),isDateDisabled:x,onMonthSwitchingAnimationEnd:w,handleChangeMonth:y}};var fS=n(16317),fM=n(69761);let fk=e=>(0,S.ZP)("MuiPickersFadeTransitionGroup",e);(0,C.Z)("MuiPickersFadeTransitionGroup",["root"]);let fE=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"]},fk,t)},fD=(0,y.ZP)(fS.Z,{name:"MuiPickersFadeTransitionGroup",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"block",position:"relative"});function fT(e){let t=cV({props:e,name:"MuiPickersFadeTransitionGroup"}),{children:n,className:r,reduceAnimations:o,transKey:i}=t,a=fE(t),s=(0,tW.Z)();return o?n:(0,c.jsx)(fD,{className:(0,f.Z)(a.root,r),children:(0,c.jsx)(fM.Z,{appear:!1,mountOnEnter:!0,unmountOnExit:!0,timeout:{appear:s.transitions.duration.enteringScreen,enter:s.transitions.duration.enteringScreen,exit:0},children:n},i)})}var fP=n(97048);function fZ(e){return(0,S.ZP)("MuiPickersDay",e)}let fO=(0,C.Z)("MuiPickersDay",["root","dayWithMargin","dayOutsideMonth","hiddenDaySpacingFiller","today","selected","disabled"]),fj=["autoFocus","className","day","disabled","disableHighlightToday","disableMargin","hidden","isAnimating","onClick","onDaySelect","onFocus","onBlur","onKeyDown","onMouseDown","onMouseEnter","outsideCurrentMonth","selected","showDaysOutsideCurrentMonth","children","today","isFirstVisibleCell","isLastVisibleCell"],fR=e=>{let{selected:t,disableMargin:n,disableHighlightToday:r,today:o,disabled:i,outsideCurrentMonth:a,showDaysOutsideCurrentMonth:s,classes:l}=e,u=a&&!s;return(0,h.Z)({root:["root",t&&!u&&"selected",i&&"disabled",!n&&"dayWithMargin",!r&&o&&"today",a&&s&&"dayOutsideMonth",u&&"hiddenDaySpacingFiller"],hiddenDaySpacingFiller:["hiddenDaySpacingFiller"]},fZ,l)},fN=({theme:e})=>(0,so.Z)({},e.typography.caption,{width:36,height:36,borderRadius:"50%",padding:0,backgroundColor:"transparent",transition:e.transitions.create("background-color",{duration:e.transitions.duration.short}),color:(e.vars||e).palette.text.primary,"@media (pointer: fine)":{"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,m.Fq)(e.palette.primary.main,e.palette.action.hoverOpacity)}},"&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.focusOpacity})`:(0,m.Fq)(e.palette.primary.main,e.palette.action.focusOpacity),[`&.${fO.selected}`]:{willChange:"background-color",backgroundColor:(e.vars||e).palette.primary.dark}},[`&.${fO.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,fontWeight:e.typography.fontWeightMedium,"&:hover":{willChange:"background-color",backgroundColor:(e.vars||e).palette.primary.dark}},[`&.${fO.disabled}:not(.${fO.selected})`]:{color:(e.vars||e).palette.text.disabled},[`&.${fO.disabled}&.${fO.selected}`]:{opacity:.6},variants:[{props:{disableMargin:!1},style:{margin:"0 2px"}},{props:{outsideCurrentMonth:!0,showDaysOutsideCurrentMonth:!0},style:{color:(e.vars||e).palette.text.secondary}},{props:{disableHighlightToday:!1,today:!0},style:{[`&:not(.${fO.selected})`]:{border:`1px solid ${(e.vars||e).palette.text.secondary}`}}}]}),fA=(e,t)=>{let{ownerState:n}=e;return[t.root,!n.disableMargin&&t.dayWithMargin,!n.disableHighlightToday&&n.today&&t.today,!n.outsideCurrentMonth&&n.showDaysOutsideCurrentMonth&&t.dayOutsideMonth,n.outsideCurrentMonth&&!n.showDaysOutsideCurrentMonth&&t.hiddenDaySpacingFiller]},fF=(0,y.ZP)(tX.Z,{name:"MuiPickersDay",slot:"Root",overridesResolver:fA})(fN),fI=(0,y.ZP)("div",{name:"MuiPickersDay",slot:"Root",overridesResolver:fA})(({theme:e})=>(0,so.Z)({},fN({theme:e}),{opacity:0,pointerEvents:"none"})),f_=()=>{},fL=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersDay"}),{autoFocus:r=!1,className:o,day:i,disabled:a=!1,disableHighlightToday:s=!1,disableMargin:l=!1,isAnimating:u,onClick:p,onDaySelect:h,onFocus:m=f_,onBlur:g=f_,onKeyDown:v=f_,onMouseDown:y=f_,onMouseEnter:b=f_,outsideCurrentMonth:x,selected:w=!1,showDaysOutsideCurrentMonth:C=!1,children:S,today:M=!1}=n,k=(0,cF.Z)(n,fj),E=(0,so.Z)({},n,{autoFocus:r,disabled:a,disableHighlightToday:s,disableMargin:l,selected:w,showDaysOutsideCurrentMonth:C,today:M}),D=fR(E),T=cq(),P=d.useRef(null),Z=(0,fP.Z)(P,t);return((0,pn.Z)(()=>{!r||a||u||x||P.current.focus()},[r,a,u,x]),x&&!C)?(0,c.jsx)(fI,{className:(0,f.Z)(D.root,D.hiddenDaySpacingFiller,o),ownerState:E,role:k.role}):(0,c.jsx)(fF,(0,so.Z)({className:(0,f.Z)(D.root,o),ref:Z,centerRipple:!0,disabled:a,tabIndex:w?0:-1,onKeyDown:e=>v(e,i),onFocus:e=>m(e,i),onBlur:e=>g(e,i),onMouseEnter:e=>b(e,i),onClick:e=>{a||h(i),x&&e.currentTarget.focus(),p&&p(e)},onMouseDown:e=>{y(e),x&&e.preventDefault()}},k,{ownerState:E,children:S||T.format(i,"dayOfMonth")}))}),fV=d.memo(fL);var f$=n(54652);function fB(e,t){return e.replace(RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}var fz=n(98683),fH=function(e,t){return e&&t&&t.split(" ").forEach(function(t){e.classList?e.classList.remove(t):"string"==typeof e.className?e.className=fB(e.className,t):e.setAttribute("class",fB(e.className&&e.className.baseVal||"",t))})},fW=function(e){function t(){for(var t,n=arguments.length,r=Array(n),o=0;o<n;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))||this).appliedClasses={appear:{},enter:{},exit:{}},t.onEnter=function(e,n){var r=t.resolveArguments(e,n),o=r[0],i=r[1];t.removeClasses(o,"exit"),t.addClass(o,i?"appear":"enter","base"),t.props.onEnter&&t.props.onEnter(e,n)},t.onEntering=function(e,n){var r=t.resolveArguments(e,n),o=r[0],i=r[1];t.addClass(o,i?"appear":"enter","active"),t.props.onEntering&&t.props.onEntering(e,n)},t.onEntered=function(e,n){var r=t.resolveArguments(e,n),o=r[0],i=r[1]?"appear":"enter";t.removeClasses(o,i),t.addClass(o,i,"done"),t.props.onEntered&&t.props.onEntered(e,n)},t.onExit=function(e){var n=t.resolveArguments(e)[0];t.removeClasses(n,"appear"),t.removeClasses(n,"enter"),t.addClass(n,"exit","base"),t.props.onExit&&t.props.onExit(e)},t.onExiting=function(e){var n=t.resolveArguments(e)[0];t.addClass(n,"exit","active"),t.props.onExiting&&t.props.onExiting(e)},t.onExited=function(e){var n=t.resolveArguments(e)[0];t.removeClasses(n,"exit"),t.addClass(n,"exit","done"),t.props.onExited&&t.props.onExited(e)},t.resolveArguments=function(e,n){return t.props.nodeRef?[t.props.nodeRef.current,e]:[e,n]},t.getClassNames=function(e){var n=t.props.classNames,r="string"==typeof n,o=r&&n?n+"-":"",i=r?""+o+e:n[e],a=r?i+"-active":n[e+"Active"],s=r?i+"-done":n[e+"Done"];return{baseClassName:i,activeClassName:a,doneClassName:s}},t}(0,f$.Z)(t,e);var n=t.prototype;return n.addClass=function(e,t,n){var r,o=this.getClassNames(t)[n+"ClassName"],i=this.getClassNames("enter").doneClassName;"appear"===t&&"done"===n&&i&&(o+=" "+i),"active"===n&&e&&(0,fz.Q)(e),o&&(this.appliedClasses[t][n]=o,r=o,e&&r&&r.split(" ").forEach(function(t){return function(e,t){if(e.classList)e.classList.add(t);else(e.classList?!(t&&e.classList.contains(t)):-1===(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" "))&&("string"==typeof e.className?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}(e,t)}))},n.removeClasses=function(e,t){var n=this.appliedClasses[t],r=n.base,o=n.active,i=n.done;this.appliedClasses[t]={},r&&fH(e,r),o&&fH(e,o),i&&fH(e,i)},n.render=function(){var e=this.props,t=(e.classNames,(0,cF.Z)(e,["classNames"]));return p().createElement(oW.ZP,(0,so.Z)({},t,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},t}(p().Component);fW.defaultProps={classNames:""},fW.propTypes={};let fG=e=>(0,S.ZP)("MuiPickersSlideTransition",e),fU=(0,C.Z)("MuiPickersSlideTransition",["root","slideEnter-left","slideEnter-right","slideEnterActive","slideExit","slideExitActiveLeft-left","slideExitActiveLeft-right"]),fq=["children","className","reduceAnimations","slideDirection","transKey","classes"],fY=e=>{let{classes:t,slideDirection:n}=e,r={root:["root"],exit:["slideExit"],enterActive:["slideEnterActive"],enter:[`slideEnter-${n}`],exitActive:[`slideExitActiveLeft-${n}`]};return(0,h.Z)(r,fG,t)},fX=(0,y.ZP)(fS.Z,{name:"MuiPickersSlideTransition",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`.${fU["slideEnter-left"]}`]:t["slideEnter-left"]},{[`.${fU["slideEnter-right"]}`]:t["slideEnter-right"]},{[`.${fU.slideEnterActive}`]:t.slideEnterActive},{[`.${fU.slideExit}`]:t.slideExit},{[`.${fU["slideExitActiveLeft-left"]}`]:t["slideExitActiveLeft-left"]},{[`.${fU["slideExitActiveLeft-right"]}`]:t["slideExitActiveLeft-right"]}]})(({theme:e})=>{let t=e.transitions.create("transform",{duration:e.transitions.duration.complex,easing:"cubic-bezier(0.35, 0.8, 0.4, 1)"});return{display:"block",position:"relative",overflowX:"hidden","& > *":{position:"absolute",top:0,right:0,left:0},[`& .${fU["slideEnter-left"]}`]:{willChange:"transform",transform:"translate(100%)",zIndex:1},[`& .${fU["slideEnter-right"]}`]:{willChange:"transform",transform:"translate(-100%)",zIndex:1},[`& .${fU.slideEnterActive}`]:{transform:"translate(0%)",transition:t},[`& .${fU.slideExit}`]:{transform:"translate(0%)"},[`& .${fU["slideExitActiveLeft-left"]}`]:{willChange:"transform",transform:"translate(-100%)",transition:t,zIndex:0},[`& .${fU["slideExitActiveLeft-right"]}`]:{willChange:"transform",transform:"translate(100%)",transition:t,zIndex:0}}}),fK=e=>(0,S.ZP)("MuiDayCalendar",e);(0,C.Z)("MuiDayCalendar",["root","header","weekDayLabel","loadingContainer","slideTransition","monthContainer","weekContainer","weekNumberLabel","weekNumber"]);let fQ=["parentProps","day","focusableDay","selectedDays","isDateDisabled","currentMonthNumber","isViewFocused"],fJ=["ownerState"],f0=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"],header:["header"],weekDayLabel:["weekDayLabel"],loadingContainer:["loadingContainer"],slideTransition:["slideTransition"],monthContainer:["monthContainer"],weekContainer:["weekContainer"],weekNumberLabel:["weekNumberLabel"],weekNumber:["weekNumber"]},fK,t)},f1=(0,y.ZP)("div",{name:"MuiDayCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({}),f2=(0,y.ZP)("div",{name:"MuiDayCalendar",slot:"Header",overridesResolver:(e,t)=>t.header})({display:"flex",justifyContent:"center",alignItems:"center"}),f5=(0,y.ZP)(nQ.Z,{name:"MuiDayCalendar",slot:"WeekDayLabel",overridesResolver:(e,t)=>t.weekDayLabel})(({theme:e})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:(e.vars||e).palette.text.secondary})),f3=(0,y.ZP)(nQ.Z,{name:"MuiDayCalendar",slot:"WeekNumberLabel",overridesResolver:(e,t)=>t.weekNumberLabel})(({theme:e})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:e.palette.text.disabled})),f4=(0,y.ZP)(nQ.Z,{name:"MuiDayCalendar",slot:"WeekNumber",overridesResolver:(e,t)=>t.weekNumber})(({theme:e})=>(0,so.Z)({},e.typography.caption,{width:36,height:36,padding:0,margin:"0 2px",color:e.palette.text.disabled,fontSize:"0.75rem",alignItems:"center",justifyContent:"center",display:"inline-flex"})),f6=(0,y.ZP)("div",{name:"MuiDayCalendar",slot:"LoadingContainer",overridesResolver:(e,t)=>t.loadingContainer})({display:"flex",justifyContent:"center",alignItems:"center",minHeight:240}),f8=(0,y.ZP)(function(e){let t=cV({props:e,name:"MuiPickersSlideTransition"}),{children:n,className:r,reduceAnimations:o,transKey:i}=t,a=(0,cF.Z)(t,fq),s=fY(t),l=(0,tW.Z)();if(o)return(0,c.jsx)("div",{className:(0,f.Z)(s.root,r),children:n});let u={exit:s.exit,enterActive:s.enterActive,enter:s.enter,exitActive:s.exitActive};return(0,c.jsx)(fX,{className:(0,f.Z)(s.root,r),childFactory:e=>d.cloneElement(e,{classNames:u}),role:"presentation",children:(0,c.jsx)(fW,(0,so.Z)({mountOnEnter:!0,unmountOnExit:!0,timeout:l.transitions.duration.complex,classNames:u},a,{children:n}),i)})},{name:"MuiDayCalendar",slot:"SlideTransition",overridesResolver:(e,t)=>t.slideTransition})({minHeight:240}),f9=(0,y.ZP)("div",{name:"MuiDayCalendar",slot:"MonthContainer",overridesResolver:(e,t)=>t.monthContainer})({overflow:"hidden"}),f7=(0,y.ZP)("div",{name:"MuiDayCalendar",slot:"WeekContainer",overridesResolver:(e,t)=>t.weekContainer})({margin:"2px 0",display:"flex",justifyContent:"center"});function he(e){let{parentProps:t,day:n,focusableDay:r,selectedDays:o,isDateDisabled:i,currentMonthNumber:a,isViewFocused:s}=e,l=(0,cF.Z)(e,fQ),{disabled:u,disableHighlightToday:p,isMonthSwitchingAnimating:f,showDaysOutsideCurrentMonth:h,slots:m,slotProps:g,timezone:v}=t,y=cq(),b=cX(v),x=null!==r&&y.isSameDay(n,r),w=o.some(e=>y.isSameDay(e,n)),C=y.isSameDay(n,b),S=m?.day??fV,M=(0,dK.Z)({elementType:S,externalSlotProps:g?.day,additionalProps:(0,so.Z)({disableHighlightToday:p,showDaysOutsideCurrentMonth:h,role:"gridcell",isAnimating:f,"data-timestamp":y.toJsDate(n).valueOf()},l),ownerState:(0,so.Z)({},t,{day:n,selected:w})}),k=(0,cF.Z)(M,fJ),E=d.useMemo(()=>u||i(n),[u,i,n]),D=d.useMemo(()=>y.getMonth(n)!==a,[y,n,a]),T=d.useMemo(()=>{let e=y.startOfMonth(y.setMonth(n,a));return h?y.isSameDay(n,y.startOfWeek(e)):y.isSameDay(n,e)},[a,n,h,y]),P=d.useMemo(()=>{let e=y.endOfMonth(y.setMonth(n,a));return h?y.isSameDay(n,y.endOfWeek(e)):y.isSameDay(n,e)},[a,n,h,y]);return(0,c.jsx)(S,(0,so.Z)({},k,{day:n,disabled:E,autoFocus:s&&x,today:C,outsideCurrentMonth:D,isFirstVisibleCell:T,isLastVisibleCell:P,selected:w,tabIndex:x?0:-1,"aria-selected":w,"aria-current":C?"date":void 0}))}function ht(e){let t=cV({props:e,name:"MuiDayCalendar"}),n=cq(),{onFocusedDayChange:r,className:o,currentMonth:i,selectedDays:a,focusedDay:s,loading:l,onSelectedDaysChange:u,onMonthSwitchingAnimationEnd:p,readOnly:h,reduceAnimations:m,renderLoading:g=()=>(0,c.jsx)("span",{children:"..."}),slideDirection:v,TransitionProps:y,disablePast:b,disableFuture:x,minDate:w,maxDate:C,shouldDisableDate:S,shouldDisableMonth:M,shouldDisableYear:k,dayOfWeekFormatter:E=e=>n.format(e,"weekdayShort").charAt(0).toUpperCase(),hasFocus:D,onFocusedViewChange:T,gridLabelId:P,displayWeekNumber:Z,fixedWeekNumber:O,autoFocus:j,timezone:R}=t,N=cX(R),A=f0(t),F=(0,oz.V)(),I=fx({shouldDisableDate:S,shouldDisableMonth:M,shouldDisableYear:k,minDate:w,maxDate:C,disablePast:b,disableFuture:x,timezone:R}),_=da(),[L,V]=(0,d9.Z)({name:"DayCalendar",state:"hasFocus",controlled:D,default:j??!1}),[$,B]=d.useState(()=>s||N),z=(0,d8.Z)(e=>{!h&&u(e)}),H=e=>{I(e)||(r(e),B(e),T?.(!0),V(!0))},W=(0,d8.Z)((e,t)=>{switch(e.key){case"ArrowUp":H(n.addDays(t,-7)),e.preventDefault();break;case"ArrowDown":H(n.addDays(t,7)),e.preventDefault();break;case"ArrowLeft":{let r=n.addDays(t,F?1:-1),o=n.addMonths(t,F?1:-1);H(cQ({utils:n,date:r,minDate:F?r:n.startOfMonth(o),maxDate:F?n.endOfMonth(o):r,isDateDisabled:I,timezone:R})||r),e.preventDefault();break}case"ArrowRight":{let r=n.addDays(t,F?-1:1),o=n.addMonths(t,F?-1:1);H(cQ({utils:n,date:r,minDate:F?n.startOfMonth(o):r,maxDate:F?r:n.endOfMonth(o),isDateDisabled:I,timezone:R})||r),e.preventDefault();break}case"Home":H(n.startOfWeek(t)),e.preventDefault();break;case"End":H(n.endOfWeek(t)),e.preventDefault();break;case"PageUp":H(n.addMonths(t,1)),e.preventDefault();break;case"PageDown":H(n.addMonths(t,-1)),e.preventDefault()}}),G=(0,d8.Z)((e,t)=>H(t)),U=(0,d8.Z)((e,t)=>{L&&n.isSameDay($,t)&&T?.(!1)}),q=n.getMonth(i),Y=n.getYear(i),X=d.useMemo(()=>a.filter(e=>!!e).map(e=>n.startOfDay(e)),[n,a]),K=`${Y}-${q}`,Q=d.useMemo(()=>d.createRef(),[K]),J=d.useMemo(()=>{let e=n.startOfMonth(i),t=n.endOfMonth(i);return I($)||n.isAfterDay($,t)||n.isBeforeDay($,e)?cQ({utils:n,date:$,minDate:e,maxDate:t,disablePast:b,disableFuture:x,isDateDisabled:I,timezone:R}):$},[i,x,b,$,I,n,R]),ee=d.useMemo(()=>{let e=n.getWeekArray(i),t=n.addMonths(i,1);for(;O&&e.length<O;){let r=n.getWeekArray(t),o=n.isSameDay(e[e.length-1][0],r[0][0]);r.slice(+!!o).forEach(t=>{e.length<O&&e.push(t)}),t=n.addMonths(t,1)}return e},[i,O,n]);return(0,c.jsxs)(f1,{role:"grid","aria-labelledby":P,className:A.root,children:[(0,c.jsxs)(f2,{role:"row",className:A.header,children:[Z&&(0,c.jsx)(f3,{variant:"caption",role:"columnheader","aria-label":_.calendarWeekNumberHeaderLabel,className:A.weekNumberLabel,children:_.calendarWeekNumberHeaderText}),c4(n,N).map((e,t)=>(0,c.jsx)(f5,{variant:"caption",role:"columnheader","aria-label":n.format(e,"weekday"),className:A.weekDayLabel,children:E(e)},t.toString()))]}),l?(0,c.jsx)(f6,{className:A.loadingContainer,children:g()}):(0,c.jsx)(f8,(0,so.Z)({transKey:K,onExited:p,reduceAnimations:m,slideDirection:v,className:(0,f.Z)(o,A.slideTransition)},y,{nodeRef:Q,children:(0,c.jsx)(f9,{ref:Q,role:"rowgroup",className:A.monthContainer,children:ee.map((e,r)=>(0,c.jsxs)(f7,{role:"row",className:A.weekContainer,"aria-rowindex":r+1,children:[Z&&(0,c.jsx)(f4,{className:A.weekNumber,role:"rowheader","aria-label":_.calendarWeekNumberAriaLabelText(n.getWeekNumber(e[0])),children:_.calendarWeekNumberText(n.getWeekNumber(e[0]))}),e.map((e,n)=>(0,c.jsx)(he,{parentProps:t,day:e,selectedDays:X,focusableDay:J,onKeyDown:W,onFocus:G,onBlur:U,onDaySelect:z,isDateDisabled:I,currentMonthNumber:q,isViewFocused:L,"aria-colindex":n+1},e.toString()))]},`week-${e[0]}`))})}))]})}function hn(e){return(0,S.ZP)("MuiPickersMonth",e)}let hr=(0,C.Z)("MuiPickersMonth",["root","monthButton","disabled","selected"]),ho=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","aria-label","monthsPerRow","slots","slotProps"],hi=e=>{let{disabled:t,selected:n,classes:r}=e;return(0,h.Z)({root:["root"],monthButton:["monthButton",t&&"disabled",n&&"selected"]},hn,r)},ha=(0,y.ZP)("div",{name:"MuiPickersMonth",slot:"Root",overridesResolver:(e,t)=>[t.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{monthsPerRow:4},style:{flexBasis:"25%"}}]}),hs=(0,y.ZP)("button",{name:"MuiPickersMonth",slot:"MonthButton",overridesResolver:(e,t)=>[t.monthButton,{[`&.${hr.disabled}`]:t.disabled},{[`&.${hr.selected}`]:t.selected}]})(({theme:e})=>(0,so.Z)({color:"unset",backgroundColor:"transparent",border:0,outline:0},e.typography.subtitle1,{margin:"8px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,m.Fq)(e.palette.action.active,e.palette.action.hoverOpacity)},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,m.Fq)(e.palette.action.active,e.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${hr.disabled}`]:{color:(e.vars||e).palette.text.secondary},[`&.${hr.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,"&:focus, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}}})),hl=d.memo(function(e){let t=cV({props:e,name:"MuiPickersMonth"}),{autoFocus:n,className:r,children:o,disabled:i,selected:a,value:s,tabIndex:l,onClick:u,onKeyDown:p,onFocus:h,onBlur:m,"aria-current":g,"aria-label":v,slots:y,slotProps:b}=t,x=(0,cF.Z)(t,ho),w=d.useRef(null),C=hi(t);(0,pn.Z)(()=>{n&&w.current?.focus()},[n]);let S=y?.monthButton??hs,M=(0,dK.Z)({elementType:S,externalSlotProps:b?.monthButton,additionalProps:{children:o,disabled:i,tabIndex:l,ref:w,type:"button",role:"radio","aria-current":g,"aria-checked":a,"aria-label":v,onClick:e=>u(e,s),onKeyDown:e=>p(e,s),onFocus:e=>h(e,s),onBlur:e=>m(e,s)},ownerState:t,className:C.monthButton});return(0,c.jsx)(ha,(0,so.Z)({className:(0,f.Z)(C.root,r),ownerState:t},x,{children:(0,c.jsx)(S,(0,so.Z)({},M))}))});function hu(e){return(0,S.ZP)("MuiMonthCalendar",e)}(0,C.Z)("MuiMonthCalendar",["root"]);let hc=["className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","shouldDisableMonth","readOnly","disableHighlightToday","autoFocus","onMonthFocus","hasFocus","onFocusedViewChange","monthsPerRow","timezone","gridLabelId","slots","slotProps"],hd=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"]},hu,t)},hp=(0,y.ZP)("div",{name:"MuiMonthCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexWrap:"wrap",alignContent:"stretch",padding:"0 4px",width:320,boxSizing:"border-box"}),hf=d.forwardRef(function(e,t){let n=function(e,t){let n=cq(),r=cY(),o=cV({props:e,name:t});return(0,so.Z)({disableFuture:!1,disablePast:!1},o,{minDate:cJ(n,o.minDate,r.minDate),maxDate:cJ(n,o.maxDate,r.maxDate)})}(e,"MuiMonthCalendar"),{className:r,value:o,defaultValue:i,referenceDate:a,disabled:s,disableFuture:l,disablePast:u,maxDate:p,minDate:h,onChange:m,shouldDisableMonth:g,readOnly:v,autoFocus:y=!1,onMonthFocus:b,hasFocus:x,onFocusedViewChange:w,monthsPerRow:C=3,timezone:S,gridLabelId:M,slots:k,slotProps:E}=n,D=(0,cF.Z)(n,hc),{value:T,handleValueChange:P,timezone:Z}=pV({name:"MonthCalendar",timezone:S,value:o,defaultValue:i,referenceDate:a,onChange:m,valueManager:fu}),O=cX(Z),j=(0,oz.V)(),R=cq(),N=d.useMemo(()=>fu.getInitialReferenceValue({value:T,utils:R,props:n,timezone:Z,referenceDate:a,granularity:p$.month}),[]),A=hd(n),F=d.useMemo(()=>R.getMonth(O),[R,O]),I=d.useMemo(()=>null!=T?R.getMonth(T):null,[T,R]),[_,L]=d.useState(()=>I||R.getMonth(N)),[V,$]=(0,d9.Z)({name:"MonthCalendar",state:"hasFocus",controlled:x,default:y??!1}),B=(0,d8.Z)(e=>{$(e),w&&w(e)}),z=d.useCallback(e=>{let t=R.startOfMonth(u&&R.isAfter(O,h)?O:h),n=R.startOfMonth(l&&R.isBefore(O,p)?O:p),r=R.startOfMonth(e);return!!(R.isBefore(r,t)||R.isAfter(r,n))||!!g&&g(r)},[l,u,p,h,O,g,R]),H=(0,d8.Z)((e,t)=>{!v&&P(R.setMonth(T??N,t))}),W=(0,d8.Z)(e=>{!z(R.setMonth(T??N,e))&&(L(e),B(!0),b&&b(e))});d.useEffect(()=>{L(e=>null!==I&&e!==I?I:e)},[I]);let G=(0,d8.Z)((e,t)=>{switch(e.key){case"ArrowUp":W((12+t-3)%12),e.preventDefault();break;case"ArrowDown":W((12+t+3)%12),e.preventDefault();break;case"ArrowLeft":W((12+t+(j?1:-1))%12),e.preventDefault();break;case"ArrowRight":W((12+t+(j?-1:1))%12),e.preventDefault()}}),U=(0,d8.Z)((e,t)=>{W(t)}),q=(0,d8.Z)((e,t)=>{_===t&&B(!1)});return(0,c.jsx)(hp,(0,so.Z)({ref:t,className:(0,f.Z)(A.root,r),ownerState:n,role:"radiogroup","aria-labelledby":M},D,{children:c0(R,T??N).map(e=>{let t=R.getMonth(e),n=R.format(e,"monthShort"),r=R.format(e,"month"),o=s||z(e);return(0,c.jsx)(hl,{selected:t===I,value:t,onClick:H,onKeyDown:G,autoFocus:V&&t===_,disabled:o,tabIndex:t!==_||o?-1:0,onFocus:U,onBlur:q,"aria-current":F===t?"date":void 0,"aria-label":r,monthsPerRow:C,slots:k,slotProps:E,children:n},n)})}))});function hh(e){return(0,S.ZP)("MuiPickersYear",e)}let hm=(0,C.Z)("MuiPickersYear",["root","yearButton","selected","disabled"]),hg=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","yearsPerRow","slots","slotProps"],hv=e=>{let{disabled:t,selected:n,classes:r}=e;return(0,h.Z)({root:["root"],yearButton:["yearButton",t&&"disabled",n&&"selected"]},hh,r)},hy=(0,y.ZP)("div",{name:"MuiPickersYear",slot:"Root",overridesResolver:(e,t)=>[t.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{yearsPerRow:4},style:{flexBasis:"25%"}}]}),hb=(0,y.ZP)("button",{name:"MuiPickersYear",slot:"YearButton",overridesResolver:(e,t)=>[t.yearButton,{[`&.${hm.disabled}`]:t.disabled},{[`&.${hm.selected}`]:t.selected}]})(({theme:e})=>(0,so.Z)({color:"unset",backgroundColor:"transparent",border:0,outline:0},e.typography.subtitle1,{margin:"6px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.focusOpacity})`:(0,m.Fq)(e.palette.action.active,e.palette.action.focusOpacity)},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:(0,m.Fq)(e.palette.action.active,e.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${hm.disabled}`]:{color:(e.vars||e).palette.text.secondary},[`&.${hm.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,"&:focus, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}}})),hx=d.memo(function(e){let t=cV({props:e,name:"MuiPickersYear"}),{autoFocus:n,className:r,children:o,disabled:i,selected:a,value:s,tabIndex:l,onClick:u,onKeyDown:p,onFocus:h,onBlur:m,"aria-current":g,slots:v,slotProps:y}=t,b=(0,cF.Z)(t,hg),x=d.useRef(null),w=hv(t);(0,pn.Z)(()=>{n&&x.current?.focus()},[n]);let C=v?.yearButton??hb,S=(0,dK.Z)({elementType:C,externalSlotProps:y?.yearButton,additionalProps:{children:o,disabled:i,tabIndex:l,ref:x,type:"button",role:"radio","aria-current":g,"aria-checked":a,onClick:e=>u(e,s),onKeyDown:e=>p(e,s),onFocus:e=>h(e,s),onBlur:e=>m(e,s)},ownerState:t,className:w.yearButton});return(0,c.jsx)(hy,(0,so.Z)({className:(0,f.Z)(w.root,r),ownerState:t},b,{children:(0,c.jsx)(C,(0,so.Z)({},S))}))});function hw(e){return(0,S.ZP)("MuiYearCalendar",e)}(0,C.Z)("MuiYearCalendar",["root"]);let hC=["autoFocus","className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","readOnly","shouldDisableYear","disableHighlightToday","onYearFocus","hasFocus","onFocusedViewChange","yearsOrder","yearsPerRow","timezone","gridLabelId","slots","slotProps"],hS=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"]},hw,t)},hM=(0,y.ZP)("div",{name:"MuiYearCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"row",flexWrap:"wrap",overflowY:"auto",height:"100%",padding:"0 4px",width:320,maxHeight:280,boxSizing:"border-box",position:"relative"}),hk=d.forwardRef(function(e,t){let n=function(e,t){let n=cq(),r=cY(),o=cV({props:e,name:t});return(0,so.Z)({disablePast:!1,disableFuture:!1},o,{yearsPerRow:o.yearsPerRow??3,minDate:cJ(n,o.minDate,r.minDate),maxDate:cJ(n,o.maxDate,r.maxDate)})}(e,"MuiYearCalendar"),{autoFocus:r,className:o,value:i,defaultValue:a,referenceDate:s,disabled:l,disableFuture:u,disablePast:p,maxDate:h,minDate:m,onChange:g,readOnly:v,shouldDisableYear:y,onYearFocus:b,hasFocus:x,onFocusedViewChange:w,yearsOrder:C="asc",yearsPerRow:S,timezone:M,gridLabelId:k,slots:E,slotProps:D}=n,T=(0,cF.Z)(n,hC),{value:P,handleValueChange:Z,timezone:O}=pV({name:"YearCalendar",timezone:M,value:i,defaultValue:a,referenceDate:s,onChange:g,valueManager:fu}),j=cX(O),R=(0,oz.V)(),N=cq(),A=d.useMemo(()=>fu.getInitialReferenceValue({value:P,utils:N,props:n,timezone:O,referenceDate:s,granularity:p$.year}),[]),F=hS(n),I=d.useMemo(()=>N.getYear(j),[N,j]),_=d.useMemo(()=>null!=P?N.getYear(P):null,[P,N]),[L,V]=d.useState(()=>_||N.getYear(A)),[$,B]=(0,d9.Z)({name:"YearCalendar",state:"hasFocus",controlled:x,default:r??!1}),z=(0,d8.Z)(e=>{B(e),w&&w(e)}),H=d.useCallback(e=>!!(p&&N.isBeforeYear(e,j)||u&&N.isAfterYear(e,j)||m&&N.isBeforeYear(e,m)||h&&N.isAfterYear(e,h))||!!y&&y(N.startOfYear(e)),[u,p,h,m,j,y,N]),W=(0,d8.Z)((e,t)=>{!v&&Z(N.setYear(P??A,t))}),G=(0,d8.Z)(e=>{H(N.setYear(P??A,e))||(V(e),z(!0),b?.(e))});d.useEffect(()=>{V(e=>null!==_&&e!==_?_:e)},[_]);let U="desc"!==C?+S:-1*S,q=R&&"asc"===C||!R&&"desc"===C?-1:1,Y=(0,d8.Z)((e,t)=>{switch(e.key){case"ArrowUp":G(t-U),e.preventDefault();break;case"ArrowDown":G(t+U),e.preventDefault();break;case"ArrowLeft":G(t-q),e.preventDefault();break;case"ArrowRight":G(t+q),e.preventDefault()}}),X=(0,d8.Z)((e,t)=>{G(t)}),K=(0,d8.Z)((e,t)=>{L===t&&z(!1)}),Q=d.useRef(null),J=(0,fP.Z)(t,Q);d.useEffect(()=>{if(r||null===Q.current)return;let e=Q.current.querySelector('[tabindex="0"]');if(!e)return;let t=e.offsetHeight,n=e.offsetTop,o=Q.current.clientHeight,i=Q.current.scrollTop;!(t>o)&&!(n<i)&&(Q.current.scrollTop=n+t-o/2-t/2)},[r]);let ee=N.getYearRange([m,h]);return"desc"===C&&ee.reverse(),(0,c.jsx)(hM,(0,so.Z)({ref:J,className:(0,f.Z)(F.root,o),ownerState:n,role:"radiogroup","aria-labelledby":k},T,{children:ee.map(e=>{let t=N.getYear(e),n=l||H(e);return(0,c.jsx)(hx,{selected:t===_,value:t,onClick:W,onKeyDown:Y,autoFocus:$&&t===L,disabled:n,tabIndex:t!==L||n?-1:0,onFocus:X,onBlur:K,"aria-current":I===t?"date":void 0,yearsPerRow:S,slots:E,slotProps:D,children:N.format(e,"year")},N.format(e,"year"))})}))}),hE=e=>(0,S.ZP)("MuiPickersCalendarHeader",e),hD=(0,C.Z)("MuiPickersCalendarHeader",["root","labelContainer","label","switchViewButton","switchViewIcon"]),hT=["slots","slotProps","currentMonth","disabled","disableFuture","disablePast","maxDate","minDate","onMonthChange","onViewChange","view","reduceAnimations","views","labelId","className","timezone","format"],hP=["ownerState"],hZ=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"],labelContainer:["labelContainer"],label:["label"],switchViewButton:["switchViewButton"],switchViewIcon:["switchViewIcon"]},hE,t)},hO=(0,y.ZP)("div",{name:"MuiPickersCalendarHeader",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",alignItems:"center",marginTop:12,marginBottom:4,paddingLeft:24,paddingRight:12,maxHeight:40,minHeight:40}),hj=(0,y.ZP)("div",{name:"MuiPickersCalendarHeader",slot:"LabelContainer",overridesResolver:(e,t)=>t.labelContainer})(({theme:e})=>(0,so.Z)({display:"flex",overflow:"hidden",alignItems:"center",cursor:"pointer",marginRight:"auto"},e.typography.body1,{fontWeight:e.typography.fontWeightMedium})),hR=(0,y.ZP)("div",{name:"MuiPickersCalendarHeader",slot:"Label",overridesResolver:(e,t)=>t.label})({marginRight:6}),hN=(0,y.ZP)(e9.Z,{name:"MuiPickersCalendarHeader",slot:"SwitchViewButton",overridesResolver:(e,t)=>t.switchViewButton})({marginRight:"auto",variants:[{props:{view:"year"},style:{[`.${hD.switchViewIcon}`]:{transform:"rotate(180deg)"}}}]}),hA=(0,y.ZP)(c7,{name:"MuiPickersCalendarHeader",slot:"SwitchViewIcon",overridesResolver:(e,t)=>t.switchViewIcon})(({theme:e})=>({willChange:"transform",transition:e.transitions.create("transform"),transform:"rotate(0deg)"})),hF=d.forwardRef(function(e,t){let n=da(),r=cq(),o=cV({props:e,name:"MuiPickersCalendarHeader"}),{slots:i,slotProps:a,currentMonth:s,disabled:l,disableFuture:u,disablePast:p,maxDate:h,minDate:m,onMonthChange:g,onViewChange:v,view:y,reduceAnimations:b,views:x,labelId:w,className:C,timezone:S,format:M=`${r.formats.month} ${r.formats.year}`}=o,k=(0,cF.Z)(o,hT),E=hZ(o),D=i?.switchViewButton??hN,T=(0,dK.Z)({elementType:D,externalSlotProps:a?.switchViewButton,additionalProps:{size:"small","aria-label":n.calendarViewSwitchingButtonAriaLabel(y)},ownerState:o,className:E.switchViewButton}),P=i?.switchViewIcon??hA,Z=(0,dK.Z)({elementType:P,externalSlotProps:a?.switchViewIcon,ownerState:o,className:E.switchViewIcon}),O=(0,cF.Z)(Z,hP),j=function(e,{disableFuture:t,maxDate:n,timezone:r}){let o=cq();return d.useMemo(()=>{let i=o.date(void 0,r),a=o.startOfMonth(t&&o.isBefore(i,n)?i:n);return!o.isAfter(a,e)},[t,n,e,o,r])}(s,{disableFuture:u,maxDate:h,timezone:S}),R=function(e,{disablePast:t,minDate:n,timezone:r}){let o=cq();return d.useMemo(()=>{let i=o.date(void 0,r),a=o.startOfMonth(t&&o.isAfter(i,n)?i:n);return!o.isBefore(a,e)},[t,n,e,o,r])}(s,{disablePast:p,minDate:m,timezone:S});if(1===x.length&&"year"===x[0])return null;let N=r.formatByString(s,M);return(0,c.jsxs)(hO,(0,so.Z)({},k,{ownerState:o,className:(0,f.Z)(E.root,C),ref:t,children:[(0,c.jsxs)(hj,{role:"presentation",onClick:()=>{if(1!==x.length&&v&&!l){if(2===x.length)v(x.find(e=>e!==y)||x[0]);else{let e=+(0===x.indexOf(y));v(x[e])}}},ownerState:o,"aria-live":"polite",className:E.labelContainer,children:[(0,c.jsx)(fT,{reduceAnimations:b,transKey:N,children:(0,c.jsx)(hR,{id:w,ownerState:o,className:E.label,children:N})}),x.length>1&&!l&&(0,c.jsx)(D,(0,so.Z)({},T,{children:(0,c.jsx)(P,(0,so.Z)({},O))}))]}),(0,c.jsx)(fM.Z,{in:"day"===y,appear:!b,enter:!b,children:(0,c.jsx)(d6,{slots:i,slotProps:a,onGoToPrevious:()=>g(r.addMonths(s,-1),"right"),isPreviousDisabled:R,previousLabel:n.previousMonth,onGoToNext:()=>g(r.addMonths(s,1),"left"),isNextDisabled:j,nextLabel:n.nextMonth})})]}))}),hI="undefined"!=typeof navigator&&navigator.userAgent.match(/android\s(\d+)|OS\s(\d+)/i),h_=hI&&hI[1]?parseInt(hI[1],10):null,hL=hI&&hI[2]?parseInt(hI[2],10):null,hV=h_&&h_<10||hL&&hL<13||!1,h$=()=>(0,oB.Z)("@media (prefers-reduced-motion: reduce)",{defaultMatches:!1})||hV,hB=e=>(0,S.ZP)("MuiDateCalendar",e);(0,C.Z)("MuiDateCalendar",["root","viewTransitionContainer"]);let hz=["autoFocus","onViewChange","value","defaultValue","referenceDate","disableFuture","disablePast","onChange","onYearChange","onMonthChange","reduceAnimations","shouldDisableDate","shouldDisableMonth","shouldDisableYear","view","views","openTo","className","disabled","readOnly","minDate","maxDate","disableHighlightToday","focusedView","onFocusedViewChange","showDaysOutsideCurrentMonth","fixedWeekNumber","dayOfWeekFormatter","slots","slotProps","loading","renderLoading","displayWeekNumber","yearsOrder","yearsPerRow","monthsPerRow","timezone"],hH=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"],viewTransitionContainer:["viewTransitionContainer"]},hB,t)},hW=(0,y.ZP)(pe,{name:"MuiDateCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"column",height:336}),hG=(0,y.ZP)(fT,{name:"MuiDateCalendar",slot:"ViewTransitionContainer",overridesResolver:(e,t)=>t.viewTransitionContainer})({}),hU=d.forwardRef(function(e,t){let n=cq(),r=(0,dX.Z)(),o=function(e,t){let n=cq(),r=cY(),o=h$(),i=cV({props:e,name:t});return(0,so.Z)({},i,{loading:i.loading??!1,disablePast:i.disablePast??!1,disableFuture:i.disableFuture??!1,openTo:i.openTo??"day",views:i.views??["year","day"],reduceAnimations:i.reduceAnimations??o,renderLoading:i.renderLoading??(()=>(0,c.jsx)("span",{children:"..."})),minDate:cJ(n,i.minDate,r.minDate),maxDate:cJ(n,i.maxDate,r.maxDate)})}(e,"MuiDateCalendar"),{autoFocus:i,onViewChange:a,value:s,defaultValue:l,referenceDate:u,disableFuture:p,disablePast:h,onChange:m,onYearChange:g,onMonthChange:v,reduceAnimations:y,shouldDisableDate:b,shouldDisableMonth:x,shouldDisableYear:w,view:C,views:S,openTo:M,className:k,disabled:E,readOnly:D,minDate:T,maxDate:P,disableHighlightToday:Z,focusedView:O,onFocusedViewChange:j,showDaysOutsideCurrentMonth:R,fixedWeekNumber:N,dayOfWeekFormatter:A,slots:F,slotProps:I,loading:_,renderLoading:L,displayWeekNumber:V,yearsOrder:$,yearsPerRow:B,monthsPerRow:z,timezone:H}=o,W=(0,cF.Z)(o,hz),{value:G,handleValueChange:U,timezone:q}=pV({name:"DateCalendar",timezone:H,value:s,defaultValue:l,referenceDate:u,onChange:m,valueManager:fu}),{view:Y,setView:X,focusedView:K,setFocusedView:Q,goToNextView:J,setValueAndGoToNextView:ee}=d7({view:C,views:S,openTo:M,onChange:U,onViewChange:a,autoFocus:i,focusedView:O,onFocusedViewChange:j}),{referenceDate:et,calendarState:en,changeFocusedDay:er,changeMonth:eo,handleChangeMonth:ei,isDateDisabled:ea,onMonthSwitchingAnimationEnd:es}=fC({value:G,referenceDate:u,reduceAnimations:y,onMonthChange:v,minDate:T,maxDate:P,shouldDisableDate:b,disablePast:h,disableFuture:p,timezone:q}),el=E&&G||T,eu=E&&G||P,ec=`${r}-grid-label`,ed=null!==K,ep=F?.calendarHeader??hF,ef=(0,dK.Z)({elementType:ep,externalSlotProps:I?.calendarHeader,additionalProps:{views:S,view:Y,currentMonth:en.currentMonth,onViewChange:X,onMonthChange:(e,t)=>ei({newMonth:e,direction:t}),minDate:el,maxDate:eu,disabled:E,disablePast:h,disableFuture:p,reduceAnimations:y,timezone:q,labelId:ec},ownerState:o}),eh=(0,d8.Z)(e=>{let t=n.startOfMonth(e),r=n.endOfMonth(e),o=ea(e)?cQ({utils:n,date:e,minDate:n.isBefore(T,t)?t:T,maxDate:n.isAfter(P,r)?r:P,disablePast:h,disableFuture:p,isDateDisabled:ea,timezone:q}):e;o?(ee(o,"finish"),v?.(t)):(J(),eo(t)),er(o,!0)}),em=(0,d8.Z)(e=>{let t=n.startOfYear(e),r=n.endOfYear(e),o=ea(e)?cQ({utils:n,date:e,minDate:n.isBefore(T,t)?t:T,maxDate:n.isAfter(P,r)?r:P,disablePast:h,disableFuture:p,isDateDisabled:ea,timezone:q}):e;o?(ee(o,"finish"),g?.(o)):(J(),eo(t)),er(o,!0)}),eg=(0,d8.Z)(e=>e?U(cK(n,e,G??et),"finish",Y):U(e,"finish",Y));d.useEffect(()=>{null!=G&&n.isValid(G)&&eo(G)},[G]);let ev=hH(o),ey={disablePast:h,disableFuture:p,maxDate:P,minDate:T},eb={disableHighlightToday:Z,readOnly:D,disabled:E,timezone:q,gridLabelId:ec,slots:F,slotProps:I},ex=d.useRef(Y);d.useEffect(()=>{ex.current!==Y&&(K===ex.current&&Q(Y,!0),ex.current=Y)},[K,Q,Y]);let ew=d.useMemo(()=>[G],[G]);return(0,c.jsxs)(hW,(0,so.Z)({ref:t,className:(0,f.Z)(ev.root,k),ownerState:o},W,{children:[(0,c.jsx)(ep,(0,so.Z)({},ef,{slots:F,slotProps:I})),(0,c.jsx)(hG,{reduceAnimations:y,className:ev.viewTransitionContainer,transKey:Y,ownerState:o,children:(0,c.jsxs)("div",{children:["year"===Y&&(0,c.jsx)(hk,(0,so.Z)({},ey,eb,{value:G,onChange:em,shouldDisableYear:w,hasFocus:ed,onFocusedViewChange:e=>Q("year",e),yearsOrder:$,yearsPerRow:B,referenceDate:et})),"month"===Y&&(0,c.jsx)(hf,(0,so.Z)({},ey,eb,{hasFocus:ed,className:k,value:G,onChange:eh,shouldDisableMonth:x,onFocusedViewChange:e=>Q("month",e),monthsPerRow:z,referenceDate:et})),"day"===Y&&(0,c.jsx)(ht,(0,so.Z)({},en,ey,eb,{onMonthSwitchingAnimationEnd:es,onFocusedDayChange:er,reduceAnimations:y,selectedDays:ew,onSelectedDaysChange:eg,shouldDisableDate:b,shouldDisableMonth:x,shouldDisableYear:w,hasFocus:ed,onFocusedViewChange:e=>Q("day",e),showDaysOutsideCurrentMonth:R,fixedWeekNumber:N,dayOfWeekFormatter:A,displayWeekNumber:V,loading:_,renderLoading:L}))]})})]}))}),hq=({view:e,onViewChange:t,views:n,focusedView:r,onFocusedViewChange:o,value:i,defaultValue:a,referenceDate:s,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minDate:h,maxDate:m,shouldDisableDate:g,shouldDisableMonth:v,shouldDisableYear:y,reduceAnimations:b,onMonthChange:x,monthsPerRow:w,onYearChange:C,yearsOrder:S,yearsPerRow:M,slots:k,slotProps:E,loading:D,renderLoading:T,disableHighlightToday:P,readOnly:Z,disabled:O,showDaysOutsideCurrentMonth:j,dayOfWeekFormatter:R,sx:N,autoFocus:A,fixedWeekNumber:F,displayWeekNumber:I,timezone:_})=>(0,c.jsx)(hU,{view:e,onViewChange:t,views:n.filter(c3),focusedView:r&&c3(r)?r:null,onFocusedViewChange:o,value:i,defaultValue:a,referenceDate:s,onChange:l,className:u,classes:d,disableFuture:p,disablePast:f,minDate:h,maxDate:m,shouldDisableDate:g,shouldDisableMonth:v,shouldDisableYear:y,reduceAnimations:b,onMonthChange:x,monthsPerRow:w,onYearChange:C,yearsOrder:S,yearsPerRow:M,slots:k,slotProps:E,loading:D,renderLoading:T,disableHighlightToday:P,readOnly:Z,disabled:O,showDaysOutsideCurrentMonth:j,dayOfWeekFormatter:R,sx:N,autoFocus:A,fixedWeekNumber:F,displayWeekNumber:I,timezone:_}),hY=({open:e,onOpen:t,onClose:n})=>{let r=d.useRef("boolean"==typeof e).current,[o,i]=d.useState(!1);return d.useEffect(()=>{if(r){if("boolean"!=typeof e)throw Error("You must not mix controlling and uncontrolled mode for `open` prop");i(e)}},[r,e]),{isOpen:o,setIsOpen:d.useCallback(e=>{r||i(e),e&&t&&t(),!e&&n&&n()},[r,t,n])}};function hX(e){let{props:t,validator:n,value:r,timezone:o,onError:i}=e,a=cU(),s=d.useRef(n.valueManager.defaultErrorState),l=n({adapter:a,value:r,timezone:o,props:t}),u=n.valueManager.hasError(l);return d.useEffect(()=>{i&&!n.valueManager.isSameError(l,s.current)&&i(l,r),s.current=l},[n,i,l,r]),{validationError:l,hasValidationError:u,getValidationErrorForNewValue:(0,d8.Z)(e=>n({adapter:a,value:e,timezone:o,props:t}))}}let hK=e=>{let{action:t,hasChanged:n,dateState:r,isControlled:o}=e,i=!o&&!r.hasBeenModifiedSinceMount;return"setValueFromField"===t.name||("setValueFromAction"===t.name?!!(i&&["accept","today","clear"].includes(t.pickerAction))||n(r.lastPublishedValue):("setValueFromView"===t.name&&"shallow"!==t.selectionState||"setValueFromShortcut"===t.name)&&(!!i||n(r.lastPublishedValue)))},hQ=e=>{let{action:t,hasChanged:n,dateState:r,isControlled:o,closeOnSelect:i}=e,a=!o&&!r.hasBeenModifiedSinceMount;return"setValueFromAction"===t.name?!!(a&&["accept","today","clear"].includes(t.pickerAction))||n(r.lastCommittedValue):"setValueFromView"===t.name&&"finish"===t.selectionState&&i?!!a||n(r.lastCommittedValue):"setValueFromShortcut"===t.name&&"accept"===t.changeImportance&&n(r.lastCommittedValue)},hJ=e=>{let{action:t,closeOnSelect:n}=e;return"setValueFromAction"===t.name||("setValueFromView"===t.name?"finish"===t.selectionState&&n:"setValueFromShortcut"===t.name&&"accept"===t.changeImportance)},h0=({props:e,valueManager:t,valueType:n,wrapperVariant:r,validator:o})=>{let{onAccept:i,onChange:a,value:s,defaultValue:l,closeOnSelect:u="desktop"===r,timezone:c,referenceDate:p}=e,{current:f}=d.useRef(l),{current:h}=d.useRef(void 0!==s),[m,g]=d.useState(c),v=cq(),y=cU(),{isOpen:b,setIsOpen:x}=hY(e),{timezone:w,value:C,handleValueChange:S}=pL({timezone:c,value:s,defaultValue:f,referenceDate:p,onChange:a,valueManager:t}),[M,k]=d.useState(()=>{let e;return{draft:e=void 0!==C?C:void 0!==f?f:t.emptyValue,lastPublishedValue:e,lastCommittedValue:e,lastControlledValue:s,hasBeenModifiedSinceMount:!1}}),E=t.getTimezone(v,M.draft);m!==c&&(g(c),c&&E&&c!==E&&k(e=>(0,so.Z)({},e,{draft:t.setTimezone(v,c,e.draft)})));let{getValidationErrorForNewValue:D}=hX({props:e,validator:o,timezone:w,value:M.draft,onError:e.onError}),T=(0,d8.Z)(e=>{let n={action:e,dateState:M,hasChanged:n=>!t.areValuesEqual(v,e.value,n),isControlled:h,closeOnSelect:u},r=hK(n),o=hQ(n),a=hJ(n);k(t=>(0,so.Z)({},t,{draft:e.value,lastPublishedValue:r?e.value:t.lastPublishedValue,lastCommittedValue:o?e.value:t.lastCommittedValue,hasBeenModifiedSinceMount:!0}));let s=null,l=()=>(s||(s={validationError:"setValueFromField"===e.name?e.context.validationError:D(e.value)},"setValueFromShortcut"!==e.name||(s.shortcut=e.shortcut)),s);r&&S(e.value,l()),o&&i&&i(e.value,l()),a&&x(!1)});if(M.lastControlledValue!==s){let e=t.areValuesEqual(v,M.draft,C);k(t=>(0,so.Z)({},t,{lastControlledValue:s},e?{}:{lastCommittedValue:C,lastPublishedValue:C,draft:C,hasBeenModifiedSinceMount:!0}))}let P=(0,d8.Z)(()=>{T({value:t.emptyValue,name:"setValueFromAction",pickerAction:"clear"})}),Z=(0,d8.Z)(()=>{T({value:M.lastPublishedValue,name:"setValueFromAction",pickerAction:"accept"})}),O=(0,d8.Z)(()=>{T({value:M.lastPublishedValue,name:"setValueFromAction",pickerAction:"dismiss"})}),j=(0,d8.Z)(()=>{T({value:M.lastCommittedValue,name:"setValueFromAction",pickerAction:"cancel"})}),R=(0,d8.Z)(()=>{T({value:t.getTodayValue(v,w,n),name:"setValueFromAction",pickerAction:"today"})}),N=(0,d8.Z)(e=>{e.preventDefault(),x(!0)}),A=(0,d8.Z)(e=>{e?.preventDefault(),x(!1)}),F=(0,d8.Z)((e,t="partial")=>T({name:"setValueFromView",value:e,selectionState:t})),I=(0,d8.Z)((e,t,n)=>T({name:"setValueFromShortcut",value:e,changeImportance:t,shortcut:n})),_=(0,d8.Z)((e,t)=>T({name:"setValueFromField",value:e,context:t})),L={onClear:P,onAccept:Z,onDismiss:O,onCancel:j,onSetToday:R,onOpen:N,onClose:A},V={value:M.draft,onChange:_},$=d.useMemo(()=>t.cleanValue(v,M.draft),[v,t,M.draft]),B=(0,so.Z)({},L,{value:$,onChange:F,onSelectShortcut:I,isValid:n=>{let r=o({adapter:y,value:n,timezone:w,props:e});return!t.hasError(r)}}),z=d.useMemo(()=>({onOpen:N,onClose:A,open:b}),[b,A,N]);return{open:b,fieldProps:V,viewProps:{value:$,onChange:F,onClose:A,open:b},layoutProps:B,actions:L,contextValue:z}},h1=["className","sx"],h2=({props:e,propsFromPickerValue:t,additionalViewProps:n,autoFocusView:r,rendererInterceptor:o,fieldRef:i})=>{let{onChange:a,open:s,onClose:l}=t,{view:u,views:c,openTo:p,onViewChange:f,viewRenderers:h,timezone:m}=e,g=(0,cF.Z)(e,h1),{view:v,setView:y,defaultView:b,focusedView:x,setFocusedView:w,setValueAndGoToNextView:C}=d7({view:u,views:c,openTo:p,onChange:a,onViewChange:f,autoFocus:r}),{hasUIView:S,viewModeLookup:M}=d.useMemo(()=>c.reduce((e,t)=>{let n;return n=null!=h[t]?"UI":"field",e.viewModeLookup[t]=n,"UI"===n&&(e.hasUIView=!0),e},{hasUIView:!1,viewModeLookup:{}}),[h,c]),k=d.useMemo(()=>c.reduce((e,t)=>null!=h[t]&&dR(t)?e+1:e,0),[h,c]),E=M[v],D=(0,d8.Z)(()=>"UI"===E),[T,P]=d.useState("UI"===E?v:null);return T!==v&&"UI"===M[v]&&P(v),(0,pn.Z)(()=>{"field"===E&&s&&(l(),setTimeout(()=>{i?.current?.setSelectedSections(v),i?.current?.focusField(v)}))},[v]),(0,pn.Z)(()=>{if(!s)return;let e=v;"field"===E&&null!=T&&(e=T),e!==b&&"UI"===M[e]&&"UI"===M[b]&&(e=b),e!==v&&y(e),w(e,!0)},[s]),{hasUIView:S,shouldRestoreFocus:D,layoutProps:{views:c,view:T,onViewChange:y},renderCurrentView:()=>{if(null==T)return null;let e=h[T];if(null==e)return null;let r=(0,so.Z)({},g,n,t,{views:c,timezone:m,onChange:C,view:T,onViewChange:y,focusedView:x,onFocusedViewChange:w,showViewSwitcher:k>1,timeViewsCount:k});return o?o(h,T,r):e(r)}}},h5=(e=document)=>{let t=e.activeElement;return t?t.shadowRoot?h5(t.shadowRoot):t:null};function h3(){return"undefined"==typeof window?"portrait":window.screen&&window.screen.orientation&&window.screen.orientation.angle?90===Math.abs(window.screen.orientation.angle)?"landscape":"portrait":window.orientation&&90===Math.abs(Number(window.orientation))?"landscape":"portrait"}let h4=(e,t)=>{var n;let[r,o]=d.useState(h3);return(0,pn.Z)(()=>{let e=()=>{o(h3())};return window.addEventListener("orientationchange",e),()=>{window.removeEventListener("orientationchange",e)}},[]),(Array.isArray(n=["hours","minutes","seconds"])?!n.every(t=>-1!==e.indexOf(t)):-1===e.indexOf(n))&&"landscape"===(t||r)},h6=({props:e,propsFromPickerValue:t,propsFromPickerViews:n,wrapperVariant:r})=>{let{orientation:o}=e,i=h4(n.views,o),a=(0,oz.V)();return{layoutProps:(0,so.Z)({},n,t,{isLandscape:i,isRtl:a,wrapperVariant:r,disabled:e.disabled,readOnly:e.readOnly})}},h8=({props:e,valueManager:t,valueType:n,wrapperVariant:r,additionalViewProps:o,validator:i,autoFocusView:a,rendererInterceptor:s,fieldRef:l})=>{let u=h0({props:e,valueManager:t,valueType:n,wrapperVariant:r,validator:i}),c=h2({props:e,additionalViewProps:o,autoFocusView:a,fieldRef:l,propsFromPickerValue:u.viewProps,rendererInterceptor:s}),p=h6({props:e,wrapperVariant:r,propsFromPickerValue:u.layoutProps,propsFromPickerViews:c.layoutProps}),f=function(e){let{props:t,pickerValueResponse:n}=e;return d.useMemo(()=>({value:n.viewProps.value,open:n.open,disabled:t.disabled??!1,readOnly:t.readOnly??!1}),[n.viewProps.value,n.open,t.disabled,t.readOnly])}({props:e,pickerValueResponse:u});return{open:u.open,actions:u.actions,fieldProps:u.fieldProps,renderCurrentView:c.renderCurrentView,hasUIView:c.hasUIView,shouldRestoreFocus:c.shouldRestoreFocus,layoutProps:p.layoutProps,contextValue:u.contextValue,ownerState:f}};function h9(e){return(0,S.ZP)("MuiPickersLayout",e)}let h7=(0,C.Z)("MuiPickersLayout",["root","landscape","contentWrapper","toolbar","actionBar","tabs","shortcuts"]),me=["onAccept","onClear","onCancel","onSetToday","actions"];function mt(e){let{onAccept:t,onClear:n,onCancel:r,onSetToday:o,actions:i}=e,a=(0,cF.Z)(e,me),s=da();if(null==i||0===i.length)return null;let l=i?.map(e=>{switch(e){case"clear":return c.jsx(O.Z,{onClick:n,children:s.clearButtonLabel},e);case"cancel":return c.jsx(O.Z,{onClick:r,children:s.cancelButtonLabel},e);case"accept":return c.jsx(O.Z,{onClick:t,children:s.okButtonLabel},e);case"today":return c.jsx(O.Z,{onClick:o,children:s.todayButtonLabel},e);default:return null}});return(0,c.jsx)(rT.Z,(0,so.Z)({},a,{children:l}))}var mn=n(71852),mr=n(2259),mo=n(52889);let mi=["items","changeImportance","isLandscape","onChange","isValid"],ma=["getValue"];function ms(e){let{items:t,changeImportance:n="accept",onChange:r,isValid:o}=e,i=(0,cF.Z)(e,mi);if(null==t||0===t.length)return null;let a=t.map(e=>{let{getValue:t}=e,i=(0,cF.Z)(e,ma),a=t({isValid:o});return(0,so.Z)({},i,{label:i.label,onClick:()=>{r(a,n,i)},disabled:!o(a)})});return(0,c.jsx)(mn.Z,(0,so.Z)({dense:!0,sx:[{maxHeight:336,maxWidth:200,overflow:"auto"},...Array.isArray(i.sx)?i.sx:[i.sx]]},i,{children:a.map(e=>(0,c.jsx)(mr.ZP,{children:(0,c.jsx)(mo.Z,(0,so.Z)({},e))},e.id??e.label))}))}let ml=e=>{let{classes:t,isLandscape:n}=e;return(0,h.Z)({root:["root",n&&"landscape"],contentWrapper:["contentWrapper"],toolbar:["toolbar"],actionBar:["actionBar"],tabs:["tabs"],landscape:["landscape"],shortcuts:["shortcuts"]},h9,t)},mu=e=>{let{wrapperVariant:t,onAccept:n,onClear:r,onCancel:o,onSetToday:i,view:a,views:s,onViewChange:l,value:u,onChange:d,onSelectShortcut:p,isValid:f,isLandscape:h,disabled:m,readOnly:g,children:v,slots:y,slotProps:b}=e,x=ml(e),w=y?.actionBar??mt,C=(0,dK.Z)({elementType:w,externalSlotProps:b?.actionBar,additionalProps:{onAccept:n,onClear:r,onCancel:o,onSetToday:i,actions:"desktop"===t?[]:["cancel","accept"]},className:x.actionBar,ownerState:(0,so.Z)({},e,{wrapperVariant:t})}),S=(0,c.jsx)(w,(0,so.Z)({},C)),M=y?.toolbar,k=(0,dK.Z)({elementType:M,externalSlotProps:b?.toolbar,additionalProps:{isLandscape:h,onChange:d,value:u,view:a,onViewChange:l,views:s,disabled:m,readOnly:g},className:x.toolbar,ownerState:(0,so.Z)({},e,{wrapperVariant:t})}),E=null!==k.view&&M?(0,c.jsx)(M,(0,so.Z)({},k)):null,D=y?.tabs,T=a&&D?(0,c.jsx)(D,(0,so.Z)({view:a,onViewChange:l,className:x.tabs},b?.tabs)):null,P=y?.shortcuts??ms,Z=(0,dK.Z)({elementType:P,externalSlotProps:b?.shortcuts,additionalProps:{isValid:f,isLandscape:h,onChange:p},className:x.shortcuts,ownerState:{isValid:f,isLandscape:h,onChange:p,wrapperVariant:t}});return{toolbar:E,content:v,tabs:T,actionBar:S,shortcuts:a&&P?(0,c.jsx)(P,(0,so.Z)({},Z)):null}},mc=e=>{let{isLandscape:t,classes:n}=e;return(0,h.Z)({root:["root",t&&"landscape"],contentWrapper:["contentWrapper"]},h9,n)},md=(0,y.ZP)("div",{name:"MuiPickersLayout",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"grid",gridAutoColumns:"max-content auto max-content",gridAutoRows:"max-content auto max-content",[`& .${h7.actionBar}`]:{gridColumn:"1 / 4",gridRow:3},variants:[{props:{isLandscape:!0},style:{[`& .${h7.toolbar}`]:{gridColumn:1,gridRow:"2 / 3"},[`.${h7.shortcuts}`]:{gridColumn:"2 / 4",gridRow:1}}},{props:{isLandscape:!0,isRtl:!0},style:{[`& .${h7.toolbar}`]:{gridColumn:3}}},{props:{isLandscape:!1},style:{[`& .${h7.toolbar}`]:{gridColumn:"2 / 4",gridRow:1},[`& .${h7.shortcuts}`]:{gridColumn:1,gridRow:"2 / 3"}}},{props:{isLandscape:!1,isRtl:!0},style:{[`& .${h7.shortcuts}`]:{gridColumn:3}}}]}),mp=(0,y.ZP)("div",{name:"MuiPickersLayout",slot:"ContentWrapper",overridesResolver:(e,t)=>t.contentWrapper})({gridColumn:2,gridRow:2,display:"flex",flexDirection:"column"}),mf=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersLayout"}),{toolbar:r,content:o,tabs:i,actionBar:a,shortcuts:s}=mu(n),{sx:l,className:u,isLandscape:p,wrapperVariant:h}=n,m=mc(n);return(0,c.jsxs)(md,{ref:t,sx:l,className:(0,f.Z)(m.root,u),ownerState:n,children:[p?s:r,p?r:s,(0,c.jsx)(mp,{className:m.contentWrapper,children:"desktop"===h?(0,c.jsxs)(d.Fragment,{children:[o,i]}):(0,c.jsxs)(d.Fragment,{children:[i,o]})}),a]})}),mh=["props","ref"],mm=(0,y.ZP)(mf)(({theme:e})=>({overflow:"hidden",minWidth:320,backgroundColor:(e.vars||e).palette.background.paper})),mg=e=>{let{props:t,ref:n}=e,r=(0,cF.Z)(e,mh),{localeText:o,slots:i,slotProps:a,className:s,sx:l,displayStaticWrapperAs:u,autoFocus:d}=t,{layoutProps:p,renderCurrentView:h}=h8((0,so.Z)({},r,{props:t,autoFocusView:d??!1,additionalViewProps:{},wrapperVariant:u})),m=i?.layout??mm;return{renderPicker:()=>(0,c.jsx)(cz,{localeText:o,children:(0,c.jsx)(m,(0,so.Z)({},p,a?.layout,{slots:i,slotProps:a,sx:[...Array.isArray(l)?l:[l],...Array.isArray(a?.layout?.sx)?a.layout.sx:[a?.layout?.sx]],className:(0,f.Z)(s,a?.layout?.className),ref:n,children:h()}))})}},mv=({adapter:e,value:t,timezone:n,props:r})=>{if(null===t)return null;let{minTime:o,maxTime:i,minutesStep:a,shouldDisableTime:s,disableIgnoringDatePartForTimeValidation:l=!1,disablePast:u,disableFuture:c}=r,d=e.utils.date(void 0,n),p=d_(l,e.utils);switch(!0){case!e.utils.isValid(t):return"invalidDate";case!!(o&&p(o,t)):return"minTime";case!!(i&&p(t,i)):return"maxTime";case!!(c&&e.utils.isAfter(t,d)):return"disableFuture";case!!(u&&e.utils.isBefore(t,d)):return"disablePast";case!!(s&&s(t,"hours")):return"shouldDisableTime-hours";case!!(s&&s(t,"minutes")):return"shouldDisableTime-minutes";case!!(s&&s(t,"seconds")):return"shouldDisableTime-seconds";case!!(a&&e.utils.getMinutes(t)%a!=0):return"minutesStep";default:return null}};mv.valueManager=fu;let my=({adapter:e,value:t,timezone:n,props:r})=>{let o=fb({adapter:e,value:t,timezone:n,props:r});return null!==o?o:mv({adapter:e,value:t,timezone:n,props:r})};my.valueManager=fu;let mb=d.forwardRef(function(e,t){let n=function(e,t){let n=cq(),r=cY(),o=cV({props:e,name:t}),i=o.ampm??n.is12HourCycleInCurrentLocale(),a=d.useMemo(()=>o.localeText?.toolbarTitle==null?o.localeText:(0,so.Z)({},o.localeText,{dateTimePickerToolbarTitle:o.localeText.toolbarTitle}),[o.localeText]);return(0,so.Z)({},o,dY({views:o.views,openTo:o.openTo,defaultViews:["year","day","hours","minutes"],defaultOpenTo:"day"}),{ampm:i,localeText:a,orientation:o.orientation??"portrait",disableIgnoringDatePartForTimeValidation:o.disableIgnoringDatePartForTimeValidation??!!(o.minDateTime||o.maxDateTime||o.disablePast||o.disableFuture),disableFuture:o.disableFuture??!1,disablePast:o.disablePast??!1,minDate:cJ(n,o.minDateTime??o.minDate,r.minDate),maxDate:cJ(n,o.maxDateTime??o.maxDate,r.maxDate),minTime:o.minDateTime??o.minTime,maxTime:o.maxDateTime??o.maxTime,slots:(0,so.Z)({toolbar:dq,tabs:dp},o.slots),slotProps:(0,so.Z)({},o.slotProps,{toolbar:(0,so.Z)({ampm:i},o.slotProps?.toolbar)})})}(e,"MuiStaticDateTimePicker"),r=n.displayStaticWrapperAs??"mobile",o=n.ampmInClock??"desktop"===r,i=(0,so.Z)({day:hq,month:hq,year:hq,hours:fy,minutes:fy,seconds:fy},n.viewRenderers),{renderPicker:a}=mg({props:(0,so.Z)({},n,{viewRenderers:i,displayStaticWrapperAs:r,ampmInClock:o,yearsPerRow:n.yearsPerRow??("mobile"===r?3:4),slotProps:(0,so.Z)({},n.slotProps,{tabs:(0,so.Z)({hidden:"desktop"===r},n.slotProps?.tabs),toolbar:(0,so.Z)({hidden:"desktop"===r,ampmInClock:o},n.slotProps?.toolbar)})}),valueManager:fu,valueType:"date-time",validator:my,ref:t});return a()});mb.propTypes={ampm:cW().bool,ampmInClock:cW().bool,autoFocus:cW().bool,className:cW().string,dayOfWeekFormatter:cW().func,defaultValue:cW().object,disabled:cW().bool,disableFuture:cW().bool,disableHighlightToday:cW().bool,disableIgnoringDatePartForTimeValidation:cW().bool,disablePast:cW().bool,displayStaticWrapperAs:cW().oneOf(["desktop","mobile"]),displayWeekNumber:cW().bool,fixedWeekNumber:cW().number,loading:cW().bool,localeText:cW().object,maxDate:cW().object,maxDateTime:cW().object,maxTime:cW().object,minDate:cW().object,minDateTime:cW().object,minTime:cW().object,minutesStep:cW().number,monthsPerRow:cW().oneOf([3,4]),onAccept:cW().func,onChange:cW().func,onClose:cW().func,onError:cW().func,onMonthChange:cW().func,onViewChange:cW().func,onYearChange:cW().func,openTo:cW().oneOf(["day","hours","minutes","month","seconds","year"]),orientation:cW().oneOf(["landscape","portrait"]),readOnly:cW().bool,reduceAnimations:cW().bool,referenceDate:cW().object,renderLoading:cW().func,shouldDisableDate:cW().func,shouldDisableMonth:cW().func,shouldDisableTime:cW().func,shouldDisableYear:cW().func,showDaysOutsideCurrentMonth:cW().bool,slotProps:cW().object,slots:cW().object,sx:cW().oneOfType([cW().arrayOf(cW().oneOfType([cW().func,cW().object,cW().bool])),cW().func,cW().object]),timezone:cW().string,value:cW().object,view:cW().oneOf(["day","hours","minutes","month","seconds","year"]),viewRenderers:cW().shape({day:cW().func,hours:cW().func,minutes:cW().func,month:cW().func,seconds:cW().func,year:cW().func}),views:cW().arrayOf(cW().oneOf(["day","hours","minutes","month","seconds","year"]).isRequired),yearsOrder:cW().oneOf(["asc","desc"]),yearsPerRow:cW().oneOf([3,4])};let mx=({utils:e,format:t})=>{let n=10,r=t,o=e.expandFormat(t);for(;o!==r;)if(r=o,o=e.expandFormat(r),(n-=1)<0)throw Error("MUI X: The format expansion seems to be in an infinite loop. Please open an issue with the format passed to the picker component.");return o},mw=({utils:e,expandedFormat:t})=>{let n=[],{start:r,end:o}=e.escapedCharacters,i=RegExp(`(\\${r}[^\\${o}]*\\${o})+`,"g"),a=null;for(;a=i.exec(t);)n.push({start:a.index,end:i.lastIndex-1});return n},mC=(e,t,n,r)=>{switch(n.type){case"year":return t.fieldYearPlaceholder({digitAmount:e.formatByString(e.date(void 0,"default"),r).length,format:r});case"month":return t.fieldMonthPlaceholder({contentType:n.contentType,format:r});case"day":return t.fieldDayPlaceholder({format:r});case"weekDay":return t.fieldWeekDayPlaceholder({contentType:n.contentType,format:r});case"hours":return t.fieldHoursPlaceholder({format:r});case"minutes":return t.fieldMinutesPlaceholder({format:r});case"seconds":return t.fieldSecondsPlaceholder({format:r});case"meridiem":return t.fieldMeridiemPlaceholder({format:r});default:return r}},mS=({utils:e,date:t,shouldRespectLeadingZeros:n,localeText:r,localizedDigits:o,now:i,token:a,startSeparator:s})=>{if(""===a)throw Error("MUI X: Should not call `commitToken` with an empty token");let l=pW(e,a),u=p6(e,l.contentType,l.type,a),c=n?u:"digit"===l.contentType,d=null!=t&&e.isValid(t),p=d?e.formatByString(t,a):"",f=null;if(c){if(u)f=""===p?e.formatByString(i,a).length:p.length;else{if(null==l.maxLength)throw Error(`MUI X: The token ${a} should have a 'maxDigitNumber' property on it's adapter`);f=l.maxLength,d&&(p=pQ(p0(pK(p,o),f),o))}}return(0,so.Z)({},l,{format:a,maxLength:f,value:p,placeholder:mC(e,r,l,a),hasLeadingZerosInFormat:u,hasLeadingZerosInInput:c,startSeparator:s,endSeparator:"",modified:!1})},mM=e=>{let{utils:t,expandedFormat:n,escapedParts:r}=e,o=t.date(void 0),i=[],a="",s=Object.keys(t.formatTokenMap).sort((e,t)=>t.length-e.length),l=/^([a-zA-Z]+)/,u=RegExp(`^(${s.join("|")})*$`),c=RegExp(`^(${s.join("|")})`),d=e=>r.find(t=>t.start<=e&&t.end>=e),p=0;for(;p<n.length;){let t=d(p),r=null!=t,s=l.exec(n.slice(p))?.[1];if(!r&&null!=s&&u.test(s)){let t=s;for(;t.length>0;){let n=c.exec(t)[1];t=t.slice(n.length),i.push(mS((0,so.Z)({},e,{now:o,token:n,startSeparator:a}))),a=""}p+=s.length}else{let e=n[p];r&&t?.start===p||t?.end===p||(0===i.length?a+=e:i[i.length-1].endSeparator+=e),p+=1}}return 0===i.length&&a.length>0&&i.push({type:"empty",contentType:"letter",maxLength:null,format:"",value:"",placeholder:"",hasLeadingZerosInFormat:!1,hasLeadingZerosInInput:!1,startSeparator:a,endSeparator:"",modified:!1}),i},mk=({isRtl:e,formatDensity:t,sections:n})=>n.map(n=>{let r=n=>{let r=n;return e&&null!==r&&r.includes(" ")&&(r=`\u2069${r}\u2066`),"spacious"===t&&["/",".","-"].includes(r)&&(r=` ${r} `),r};return n.startSeparator=r(n.startSeparator),n.endSeparator=r(n.endSeparator),n}),mE=e=>{let t=mx(e);e.isRtl&&e.enableAccessibleFieldDOMStructure&&(t=t.split(" ").reverse().join(" "));let n=mw((0,so.Z)({},e,{expandedFormat:t})),r=mM((0,so.Z)({},e,{expandedFormat:t,escapedParts:n}));return mk((0,so.Z)({},e,{sections:r}))},mD=e=>{let t=cq(),n=da(),r=cU(),o=(0,oz.V)(),{valueManager:i,fieldValueManager:a,valueType:s,validator:l,internalProps:u,internalProps:{value:c,defaultValue:p,referenceDate:f,onChange:h,format:m,formatDensity:g="dense",selectedSections:v,onSelectedSectionsChange:y,shouldRespectLeadingZeros:b=!1,timezone:x,enableAccessibleFieldDOMStructure:w=!1}}=e,{timezone:C,value:S,handleValueChange:M}=pL({timezone:x,value:c,defaultValue:p,referenceDate:f,onChange:h,valueManager:i}),k=d.useMemo(()=>pX(t),[t]),E=d.useMemo(()=>p9(t,k,C),[t,k,C]),D=d.useCallback((e,r=null)=>a.getSectionsFromValue(t,e,r,e=>mE({utils:t,localeText:n,localizedDigits:k,format:m,date:e,formatDensity:g,shouldRespectLeadingZeros:b,enableAccessibleFieldDOMStructure:w,isRtl:o})),[a,m,n,k,o,b,t,g,w]),[T,P]=d.useState(()=>{let e=D(S);p7(e,s);let n={sections:e,value:S,referenceValue:i.emptyValue,tempValueStrAndroid:null},r=pB(e),o=i.getInitialReferenceValue({referenceDate:f,value:S,utils:t,props:u,granularity:r,timezone:C});return(0,so.Z)({},n,{referenceValue:o})}),[Z,O]=(0,d9.Z)({controlled:v,default:null,name:"useField",state:"selectedSections"}),j=e=>{O(e),y?.(e)},R=d.useMemo(()=>fi(Z,T.sections),[Z,T.sections]),N="all"===R?0:R,A=({value:e,referenceValue:n,sections:o})=>{if(P(t=>(0,so.Z)({},t,{sections:o,value:e,referenceValue:n,tempValueStrAndroid:null})),i.areValuesEqual(t,T.value,e))return;let a={validationError:l({adapter:r,value:e,timezone:C,props:u})};M(e,a)},F=(e,t)=>{let n=[...T.sections];return n[e]=(0,so.Z)({},n[e],{value:t,modified:!0}),n};return d.useEffect(()=>{let e=D(T.value);p7(e,s),P(t=>(0,so.Z)({},t,{sections:e}))},[m,t.locale,o]),d.useEffect(()=>{let e;i.areValuesEqual(t,T.value,S)&&i.getTimezone(t,T.value)===i.getTimezone(t,S)||P(e=>(0,so.Z)({},e,{value:S,referenceValue:a.updateReferenceValue(t,S,e.referenceValue),sections:D(S)}))},[S]),{state:T,activeSectionIndex:N,parsedSelectedSections:R,setSelectedSections:j,clearValue:()=>{A({value:i.emptyValue,referenceValue:T.referenceValue,sections:D(i.emptyValue)})},clearActiveSection:()=>{if(null==N)return;let e=T.sections[N],n=a.getActiveDateManager(t,T,e),r=n.getSections(T.sections).filter(e=>""!==e.value).length===+(""!==e.value),o=F(N,""),i=r?null:t.getInvalidDate(),s=n.getNewValuesFromNewActiveDate(i);A((0,so.Z)({},s,{sections:o}))},updateSectionValue:({activeSection:e,newSectionValue:n,shouldGoToNextSection:r})=>{let o,i;r&&N<T.sections.length-1&&j(N+1);let s=a.getActiveDateManager(t,T,e),l=F(N,n),u=s.getSections(l),c=p8(t,u,k);if(null!=c&&t.isValid(c)){let e=fn(t,c,u,s.referenceDate,!0);o=s.getNewValuesFromNewActiveDate(e),i=!0}else o=s.getNewValuesFromNewActiveDate(c),i=(null!=c&&!t.isValid(c))!=(null!=s.date&&!t.isValid(s.date));return i?A((0,so.Z)({},o,{sections:l})):P(e=>(0,so.Z)({},e,o,{sections:l,tempValueStrAndroid:null}))},updateValueFromValueStr:e=>{let r=a.parseValueStr(e,T.referenceValue,(e,r)=>{let i=t.parse(e,m);if(null==i||!t.isValid(i))return null;let a=mE({utils:t,localeText:n,localizedDigits:k,format:m,date:i,formatDensity:g,shouldRespectLeadingZeros:b,enableAccessibleFieldDOMStructure:w,isRtl:o});return fn(t,i,a,r,!1)}),i=a.updateReferenceValue(t,r,T.referenceValue);A({value:r,referenceValue:i,sections:D(r,T.sections)})},setTempAndroidValueStr:e=>P(t=>(0,so.Z)({},t,{tempValueStrAndroid:e})),getSectionsFromValue:D,sectionsValueBoundaries:E,localizedDigits:k,timezone:C}},mT=e=>null!=e.saveQuery,mP=({sections:e,updateSectionValue:t,sectionsValueBoundaries:n,localizedDigits:r,setTempAndroidValueStr:o,timezone:i})=>{let a=cq(),[s,l]=d.useState(null),u=(0,d8.Z)(()=>l(null));d.useEffect(()=>{null!=s&&e[s.sectionIndex]?.type!==s.sectionType&&u()},[e,s,u]),d.useEffect(()=>{if(null!=s){let e=setTimeout(()=>u(),5e3);return()=>{clearTimeout(e)}}return()=>{}},[s,u]);let c=({keyPressed:t,sectionIndex:n},r,o)=>{let i=t.toLowerCase(),a=e[n];if(null!=s&&(!o||o(s.value))&&s.sectionIndex===n){let e=`${s.value}${i}`,t=r(e,a);if(!mT(t))return l({sectionIndex:n,value:e,sectionType:a.type}),t}let c=r(i,a);return mT(c)&&!c.saveQuery?(u(),null):(l({sectionIndex:n,value:i,sectionType:a.type}),mT(c))?null:c},p=e=>{let t=(e,t,n)=>{let r=t.filter(e=>e.toLowerCase().startsWith(n));return 0===r.length?{saveQuery:!1}:{sectionValue:r[0],shouldGoToNextSection:1===r.length}},n=(e,n,r,o)=>{let s=e=>pq(a,i,n.type,e);if("letter"===n.contentType)return t(n.format,s(n.format),e);if(r&&null!=o&&"letter"===pW(a,r).contentType){let n=s(r),i=t(r,n,e);return mT(i)?{saveQuery:!1}:(0,so.Z)({},i,{sectionValue:o(i.sectionValue,n)})}return{saveQuery:!1}};return c(e,(e,t)=>{switch(t.type){case"month":return n(e,t,a.formats.month,e=>p3(a,e,a.formats.month,t.format));case"weekDay":return n(e,t,a.formats.weekday,(e,t)=>t.indexOf(e).toString());case"meridiem":return n(e,t);default:return{saveQuery:!1}}})},f=e=>{let t=(e,t)=>{let o=pK(e,r),i=Number(o),s=n[t.type]({currentDate:null,format:t.format,contentType:t.contentType});if(i>s.maximum)return{saveQuery:!1};if(i<s.minimum)return{saveQuery:!0};let l=10*i>s.maximum||o.length===s.maximum.toString().length;return{sectionValue:p1(a,i,s,r,t),shouldGoToNextSection:l}};return c(e,(e,n)=>{if("digit"===n.contentType||"digit-with-letter"===n.contentType)return t(e,n);if("month"===n.type){let r=p6(a,"digit","month","MM"),o=t(e,{type:n.type,format:"MM",hasLeadingZerosInFormat:r,hasLeadingZerosInInput:!0,contentType:"digit",maxLength:2});if(mT(o))return o;let i=p3(a,o.sectionValue,"MM",n.format);return(0,so.Z)({},o,{sectionValue:i})}if("weekDay"===n.type){let r=t(e,n);if(mT(r))return r;let o=pU(a,n.format)[Number(r.sectionValue)-1];return(0,so.Z)({},r,{sectionValue:o})}return{saveQuery:!1}},e=>pJ(e,r))};return{applyCharacterEditing:(0,d8.Z)(n=>{let i=e[n.sectionIndex],a=pJ(n.keyPressed,r)?f((0,so.Z)({},n,{keyPressed:pQ(n.keyPressed,r)})):p(n);if(null==a){o(null);return}t({activeSection:i,newSectionValue:a.sectionValue,shouldGoToNextSection:a.shouldGoToNextSection})}),resetCharacterQuery:u}},mZ=e=>{let{internalProps:{disabled:t,readOnly:n=!1},forwardedProps:{sectionListRef:r,onBlur:o,onClick:i,onFocus:a,onInput:s,onPaste:l,focused:u,autoFocus:c=!1},fieldValueManager:p,applyCharacterEditing:f,resetCharacterQuery:h,setSelectedSections:m,parsedSelectedSections:g,state:v,clearActiveSection:y,clearValue:b,updateSectionValue:x,updateValueFromValueStr:w,sectionOrder:C,areAllSectionsEmpty:S,sectionsValueBoundaries:M}=e,k=d.useRef(null),E=(0,fP.Z)(r,k),D=da(),T=cq(),P=(0,dX.Z)(),[Z,O]=d.useState(!1),j=d.useMemo(()=>({syncSelectionToDOM:()=>{let e;if(!k.current)return;let t=document.getSelection();if(!t)return;if(null==g){t.rangeCount>0&&k.current.getRoot().contains(t.getRangeAt(0).startContainer)&&t.removeAllRanges(),Z&&k.current.getRoot().blur();return}if(!k.current.getRoot().contains(h5(document)))return;let n=new window.Range;e="all"===g?k.current.getRoot():"empty"===v.sections[g].type?k.current.getSectionContainer(g):k.current.getSectionContent(g),n.selectNodeContents(e),e.focus(),t.removeAllRanges(),t.addRange(n)},getActiveSectionIndexFromDOM:()=>{let e=h5(document);return e&&k.current&&k.current.getRoot().contains(e)?k.current.getSectionIndexFromDOMElement(e):null},focusField:(e=0)=>{if(!k.current||null!=j.getActiveSectionIndexFromDOM())return;let t=fi(e,v.sections);O(!0),k.current.getSectionContent(t).focus()},setSelectedSections:e=>{if(!k.current)return;let t=fi(e,v.sections);O(null!==("all"===t?0:t)),m(e)},isFieldFocused:()=>{let e=h5(document);return!!k.current&&k.current.getRoot().contains(e)}}),[g,m,v.sections,Z]),R=(0,d8.Z)(e=>{if(!k.current)return;let t=v.sections[e];k.current.getSectionContent(e).innerHTML=t.value||t.placeholder,j.syncSelectionToDOM()}),N=(0,d8.Z)((e,...t)=>{!e.isDefaultPrevented()&&k.current&&(O(!0),i?.(e,...t),"all"===g?setTimeout(()=>{let e=document.getSelection().getRangeAt(0).startOffset;if(0===e){m(C.startIndex);return}let t=0,n=0;for(;n<e&&t<v.sections.length;){let e=v.sections[t];t+=1,n+=`${e.startSeparator}${e.value||e.placeholder}${e.endSeparator}`.length}m(t-1)}):Z?k.current.getRoot().contains(e.target)||m(C.startIndex):(O(!0),m(C.startIndex)))}),A=(0,d8.Z)(e=>{if(s?.(e),!k.current||"all"!==g)return;let t=e.target.textContent??"";k.current.getRoot().innerHTML=v.sections.map(e=>`${e.startSeparator}${e.value||e.placeholder}${e.endSeparator}`).join(""),j.syncSelectionToDOM(),0===t.length||10===t.charCodeAt(0)?(h(),b(),m("all")):t.length>1?w(t):("all"===g&&m(0),f({keyPressed:t,sectionIndex:0}))}),F=(0,d8.Z)(e=>{if(l?.(e),n||"all"!==g){e.preventDefault();return}let t=e.clipboardData.getData("text");e.preventDefault(),h(),w(t)}),I=(0,d8.Z)((...e)=>{a?.(...e),!Z&&k.current&&(O(!0),null==k.current.getSectionIndexFromDOMElement(h5(document))&&m(C.startIndex))}),_=(0,d8.Z)((...e)=>{o?.(...e),setTimeout(()=>{if(!k.current)return;let e=h5(document);k.current.getRoot().contains(e)||(O(!1),m(null))})}),L=(0,d8.Z)(e=>t=>{!t.isDefaultPrevented()&&m(e)}),V=(0,d8.Z)(e=>{e.preventDefault()}),$=(0,d8.Z)(e=>()=>{m(e)}),B=(0,d8.Z)(e=>{if(e.preventDefault(),n||t||"number"!=typeof g)return;let r=v.sections[g],o=e.clipboardData.getData("text"),i=/^[a-zA-Z]+$/.test(o),a=/^[0-9]+$/.test(o),s=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(o);"letter"===r.contentType&&i||"digit"===r.contentType&&a||"digit-with-letter"===r.contentType&&s?(h(),x({activeSection:r,newSectionValue:o,shouldGoToNextSection:!0})):i||a||(h(),w(o))}),z=(0,d8.Z)(e=>{e.preventDefault(),e.dataTransfer.dropEffect="none"}),H=(0,d8.Z)(e=>{if(!k.current)return;let t=e.target,r=t.textContent??"",o=k.current.getSectionIndexFromDOMElement(t),i=v.sections[o];if(n||!k.current){R(o);return}if(0===r.length){if(""===i.value){R(o);return}let t=e.nativeEvent.inputType;if("insertParagraph"===t||"insertLineBreak"===t){R(o);return}h(),y();return}f({keyPressed:r,sectionIndex:o}),R(o)});(0,pn.Z)(()=>{if(Z&&k.current){if("all"===g)k.current.getRoot().focus();else if("number"==typeof g){let e=k.current.getSectionContent(g);e&&e.focus()}}},[g,Z]);let W=d.useMemo(()=>v.sections.reduce((e,t)=>(e[t.type]=M[t.type]({currentDate:null,contentType:t.contentType,format:t.format}),e),{}),[M,v.sections]),G="all"===g,U=d.useMemo(()=>v.sections.map((e,r)=>{let o=!G&&!t&&!n;return{container:{"data-sectionindex":r,onClick:L(r)},content:{tabIndex:G||r>0?-1:0,contentEditable:!G&&!t&&!n,role:"spinbutton",id:`${P}-${e.type}`,"aria-labelledby":`${P}-${e.type}`,"aria-readonly":n,"aria-valuenow":fs(e,T),"aria-valuemin":W[e.type].minimum,"aria-valuemax":W[e.type].maximum,"aria-valuetext":e.value?fa(e,T):D.empty,"aria-label":D[e.type],"aria-disabled":t,spellCheck:!o&&void 0,autoCapitalize:o?"off":void 0,autoCorrect:o?"off":void 0,[parseInt(d.version,10)>=17?"enterKeyHint":"enterkeyhint"]:o?"next":void 0,children:e.value||e.placeholder,onInput:H,onPaste:B,onFocus:$(r),onDragOver:z,onMouseUp:V,inputMode:"letter"===e.contentType?"text":"numeric"},before:{children:e.startSeparator},after:{children:e.endSeparator}}}),[v.sections,$,B,z,H,L,V,t,n,G,D,T,W,P]),q=(0,d8.Z)(e=>{w(e.target.value)}),Y=d.useMemo(()=>S?"":p.getV7HiddenInputValueFromSections(v.sections),[S,v.sections,p]);return d.useEffect(()=>{if(null==k.current)throw Error("MUI X: The `sectionListRef` prop has not been initialized by `PickersSectionList`\nYou probably tried to pass a component to the `textField` slot that contains an `<input />` element instead of a `PickersSectionList`.\n\nIf you want to keep using an `<input />` HTML element for the editing, please remove the `enableAccessibleFieldDOMStructure` prop from your picker or field component:\n\n<DatePicker slots={{ textField: MyCustomTextField }} />\n\nLearn more about the field accessible DOM structure on the MUI documentation: https://mui.com/x/react-date-pickers/fields/#fields-to-edit-a-single-element");c&&k.current&&k.current.getSectionContent(C.startIndex).focus()},[]),{interactions:j,returnedValue:{autoFocus:c,readOnly:n,focused:u??Z,sectionListRef:E,onBlur:_,onClick:N,onFocus:I,onInput:A,onPaste:F,enableAccessibleFieldDOMStructure:!0,elements:U,tabIndex:0===g?-1:0,contentEditable:G,value:Y,onChange:q,areAllSectionsEmpty:S}}},mO=e=>e.replace(/[\u2066\u2067\u2068\u2069]/g,""),mj=(e,t,n)=>{let r=0,o=+!!n,i=[];for(let a=0;a<e.length;a+=1){let s=e[a],l=p5(s,n?"input-rtl":"input-ltr",t),u=`${s.startSeparator}${l}${s.endSeparator}`,c=mO(u).length,d=u.length,p=mO(l),f=o+(""===p?0:l.indexOf(p[0]))+s.startSeparator.length,h=f+p.length;i.push((0,so.Z)({},s,{start:r,end:r+c,startInInput:f,endInInput:h})),r+=c,o+=d}return i},mR=e=>{let t=(0,oz.V)(),n=d.useRef(void 0),r=d.useRef(void 0),{forwardedProps:{onFocus:o,onClick:i,onPaste:a,onBlur:s,inputRef:l,placeholder:u},internalProps:{readOnly:c=!1,disabled:p=!1},parsedSelectedSections:f,activeSectionIndex:h,state:m,fieldValueManager:g,valueManager:v,applyCharacterEditing:y,resetCharacterQuery:b,updateSectionValue:x,updateValueFromValueStr:w,clearActiveSection:C,clearValue:S,setTempAndroidValueStr:M,setSelectedSections:k,getSectionsFromValue:E,areAllSectionsEmpty:D,localizedDigits:T}=e,P=d.useRef(null),Z=(0,fP.Z)(l,P),O=d.useMemo(()=>mj(m.sections,T,t),[m.sections,T,t]),j=d.useMemo(()=>({syncSelectionToDOM:()=>{if(!P.current)return;if(null==f){P.current.scrollLeft&&(P.current.scrollLeft=0);return}if(P.current!==h5(document))return;let e=P.current.scrollTop;if("all"===f)P.current.select();else{let e=O[f],t="empty"===e.type?e.startInInput-e.startSeparator.length:e.startInInput,n="empty"===e.type?e.endInInput+e.endSeparator.length:e.endInInput;(t!==P.current.selectionStart||n!==P.current.selectionEnd)&&P.current===h5(document)&&P.current.setSelectionRange(t,n),clearTimeout(r.current),r.current=setTimeout(()=>{P.current&&P.current===h5(document)&&P.current.selectionStart===P.current.selectionEnd&&(P.current.selectionStart!==t||P.current.selectionEnd!==n)&&j.syncSelectionToDOM()})}P.current.scrollTop=e},getActiveSectionIndexFromDOM:()=>{let e=P.current.selectionStart??0,t=P.current.selectionEnd??0;if(0===e&&0===t)return null;let n=e<=O[0].startInInput?1:O.findIndex(t=>t.startInInput-t.startSeparator.length>e);return -1===n?O.length-1:n-1},focusField:(e=0)=>{h5(document)!==P.current&&(P.current?.focus(),k(e))},setSelectedSections:e=>k(e),isFieldFocused:()=>P.current===h5(document)}),[P,f,O,k]),R=()=>{let e;let t=P.current.selectionStart??0;k(-1===(e=t<=O[0].startInInput?1:t>=O[O.length-1].endInInput?1:O.findIndex(e=>e.startInInput-e.startSeparator.length>t))?O.length-1:e-1)},N=(0,d8.Z)((...e)=>{o?.(...e);let t=P.current;clearTimeout(n.current),n.current=setTimeout(()=>{t&&t===P.current&&null==h&&(t.value.length&&Number(t.selectionEnd)-Number(t.selectionStart)===t.value.length?k("all"):R())})}),A=(0,d8.Z)((e,...t)=>{!e.isDefaultPrevented()&&(i?.(e,...t),R())}),F=(0,d8.Z)(e=>{if(a?.(e),e.preventDefault(),c||p)return;let t=e.clipboardData.getData("text");if("number"==typeof f){let e=m.sections[f],n=/^[a-zA-Z]+$/.test(t),r=/^[0-9]+$/.test(t),o=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(t);if("letter"===e.contentType&&n||"digit"===e.contentType&&r||"digit-with-letter"===e.contentType&&o){b(),x({activeSection:e,newSectionValue:t,shouldGoToNextSection:!0});return}if(n||r)return}b(),w(t)}),I=(0,d8.Z)((...e)=>{s?.(...e),k(null)}),_=(0,d8.Z)(e=>{let n;if(c)return;let r=e.target.value;if(""===r){b(),S();return}let o=e.nativeEvent.data,i=o&&o.length>1,a=i?o:r,s=mO(a);if("all"===f&&k(h),null==h||i){w(i?o:s);return}if("all"===f&&1===s.length)n=s;else{let e=mO(g.getV6InputValueFromSections(O,T,t)),r=-1,o=-1;for(let t=0;t<e.length;t+=1)-1===r&&e[t]!==s[t]&&(r=t),-1===o&&e[e.length-t-1]!==s[s.length-t-1]&&(o=t);let i=O[h];if(r<i.start||e.length-o-1>i.end)return;let a=s.length-e.length+i.end-mO(i.endSeparator||"").length;n=s.slice(i.start+mO(i.startSeparator||"").length,a)}if(0===n.length){fr()&&M(a),b(),C();return}y({keyPressed:n,sectionIndex:h})}),L=d.useMemo(()=>void 0!==u?u:g.getV6InputValueFromSections(E(v.emptyValue),T,t),[u,g,E,v.emptyValue,T,t]),V=d.useMemo(()=>m.tempValueStrAndroid??g.getV6InputValueFromSections(m.sections,T,t),[m.sections,g,m.tempValueStrAndroid,T,t]);d.useEffect(()=>(P.current&&P.current===h5(document)&&k("all"),()=>{clearTimeout(n.current),clearTimeout(r.current)}),[]);let $=d.useMemo(()=>null==h||"letter"===m.sections[h].contentType?"text":"numeric",[h,m.sections]);return{interactions:j,returnedValue:{readOnly:c,onBlur:I,onClick:A,onFocus:N,onPaste:F,inputRef:Z,enableAccessibleFieldDOMStructure:!1,placeholder:L,inputMode:$,autoComplete:"off",value:!(P.current&&P.current===h5(document))&&D?"":V,onChange:_}}},mN=e=>{let t=cq(),{internalProps:n,internalProps:{unstableFieldRef:r,minutesStep:o,enableAccessibleFieldDOMStructure:i=!1,disabled:a=!1,readOnly:s=!1},forwardedProps:{onKeyDown:l,error:u,clearable:c,onClear:p},fieldValueManager:f,valueManager:h,validator:m}=e,g=(0,oz.V)(),v=mD(e),{state:y,activeSectionIndex:b,parsedSelectedSections:x,setSelectedSections:w,clearValue:C,clearActiveSection:S,updateSectionValue:M,setTempAndroidValueStr:k,sectionsValueBoundaries:E,localizedDigits:D,timezone:T}=v,P=mP({sections:y.sections,updateSectionValue:M,sectionsValueBoundaries:E,localizedDigits:D,setTempAndroidValueStr:k,timezone:T}),{resetCharacterQuery:Z}=P,O=h.areValuesEqual(t,y.value,h.emptyValue),j=i?mZ:mR,R=d.useMemo(()=>fo(y.sections,g&&!i),[y.sections,g,i]),{returnedValue:N,interactions:A}=j((0,so.Z)({},e,v,P,{areAllSectionsEmpty:O,sectionOrder:R})),F=(0,d8.Z)(e=>{if(l?.(e),!a)switch(!0){case(e.ctrlKey||e.metaKey)&&"A"===String.fromCharCode(e.keyCode)&&!e.shiftKey&&!e.altKey:e.preventDefault(),w("all");break;case"ArrowRight"===e.key:if(e.preventDefault(),null==x)w(R.startIndex);else if("all"===x)w(R.endIndex);else{let e=R.neighbors[x].rightIndex;null!==e&&w(e)}break;case"ArrowLeft"===e.key:if(e.preventDefault(),null==x)w(R.endIndex);else if("all"===x)w(R.startIndex);else{let e=R.neighbors[x].leftIndex;null!==e&&w(e)}break;case"Delete"===e.key:if(e.preventDefault(),s)break;null==x||"all"===x?C():S(),Z();break;case["ArrowUp","ArrowDown","Home","End","PageUp","PageDown"].includes(e.key):{if(e.preventDefault(),s||null==b)break;"all"===x&&w(b);let n=y.sections[b],r=f.getActiveDateManager(t,y,n),i=p2(t,T,n,e.key,E,D,r.date,{minutesStep:o});M({activeSection:n,newSectionValue:i,shouldGoToNextSection:!1})}}});(0,pn.Z)(()=>{A.syncSelectionToDOM()});let{hasValidationError:I}=hX({props:n,validator:m,timezone:T,value:y.value,onError:n.onError}),_=d.useMemo(()=>void 0!==u?u:I,[I,u]);d.useEffect(()=>{_||null!=b||Z()},[y.referenceValue,b,_]),d.useEffect(()=>{null!=y.tempValueStrAndroid&&null!=b&&(Z(),S())},[y.sections]),d.useImperativeHandle(r,()=>({getSections:()=>y.sections,getActiveSectionIndex:A.getActiveSectionIndexFromDOM,setSelectedSections:A.setSelectedSections,focusField:A.focusField,isFieldFocused:A.isFieldFocused}));let L={onKeyDown:F,onClear:(0,d8.Z)((e,...t)=>{e.preventDefault(),p?.(e,...t),C(),A.isFieldFocused()?w(R.startIndex):A.focusField(0)}),error:_,clearable:!!(c&&!O&&!s&&!a)};return(0,so.Z)({},e.forwardedProps,L,{disabled:a,readOnly:s},N)},mA=["disablePast","disableFuture","minDate","maxDate","shouldDisableDate","shouldDisableMonth","shouldDisableYear"],mF=["disablePast","disableFuture","minTime","maxTime","shouldDisableTime","minutesStep","ampm","disableIgnoringDatePartForTimeValidation"],mI=["minDateTime","maxDateTime"];[...mA,...mF,...mI];let m_=["value","defaultValue","referenceDate","format","formatDensity","onChange","timezone","onError","shouldRespectLeadingZeros","selectedSections","onSelectedSectionsChange","unstableFieldRef","enableAccessibleFieldDOMStructure","disabled","readOnly","dateSeparator"],mL=(e,t)=>d.useMemo(()=>{let n=(0,so.Z)({},e),r={},o=e=>{n.hasOwnProperty(e)&&(r[e]=n[e],delete n[e])};return m_.forEach(o),"date"===t?mA.forEach(o):"time"===t?mF.forEach(o):"date-time"===t&&(mA.forEach(o),mF.forEach(o),mI.forEach(o)),{forwardedProps:n,internalProps:r}},[e,t]),mV=e=>{let t=cq(),n=cY(),r=e.ampm??t.is12HourCycleInCurrentLocale()?t.formats.keyboardDateTime12h:t.formats.keyboardDateTime24h;return(0,so.Z)({},e,{disablePast:e.disablePast??!1,disableFuture:e.disableFuture??!1,format:e.format??r,disableIgnoringDatePartForTimeValidation:!!(e.minDateTime||e.maxDateTime),minDate:cJ(t,e.minDateTime??e.minDate,n.minDate),maxDate:cJ(t,e.maxDateTime??e.maxDate,n.maxDate),minTime:e.minDateTime??e.minTime,maxTime:e.maxDateTime??e.maxTime})},m$=e=>{let{forwardedProps:t,internalProps:n}=mL(mV(e),"date-time");return mN({forwardedProps:t,internalProps:n,valueManager:fu,fieldValueManager:fc,validator:my,valueType:"date-time"})};var mB=n(76992);let mz=["clearable","onClear","InputProps","sx","slots","slotProps"],mH=["ownerState"],mW=e=>{let t=da(),{clearable:n,onClear:r,InputProps:o,sx:i,slots:a,slotProps:s}=e,l=(0,cF.Z)(e,mz),u=a?.clearButton??e9.Z,p=(0,dK.Z)({elementType:u,externalSlotProps:s?.clearButton,ownerState:{},className:"clearButton",additionalProps:{title:t.fieldClearLabel}}),f=(0,cF.Z)(p,mH),h=a?.clearIcon??di,m=(0,dK.Z)({elementType:h,externalSlotProps:s?.clearIcon,ownerState:{}});return(0,so.Z)({},l,{InputProps:(0,so.Z)({},o,{endAdornment:(0,c.jsxs)(d.Fragment,{children:[n&&(0,c.jsx)(mB.Z,{position:"end",sx:{marginRight:o?.endAdornment?-1:-1.5},children:(0,c.jsx)(u,(0,so.Z)({},f,{onClick:r,children:(0,c.jsx)(h,(0,so.Z)({fontSize:"small"},m))}))}),o?.endAdornment]})}),sx:[{"& .clearButton":{opacity:1},"@media (pointer: fine)":{"& .clearButton":{opacity:0},"&:hover, &:focus-within":{".clearButton":{opacity:1}}}},...Array.isArray(i)?i:[i]]})};var mG=n(68808),mU=n(32931);function mq(e){return(0,S.ZP)("MuiPickersTextField",e)}(0,C.Z)("MuiPickersTextField",["root","focused","disabled","error","required"]);var mY=n(36683);function mX(e){return(0,S.ZP)("MuiPickersInputBase",e)}let mK=(0,C.Z)("MuiPickersInputBase",["root","focused","disabled","error","notchedOutline","sectionContent","sectionBefore","sectionAfter","adornedStart","adornedEnd","input"]);function mQ(e){return(0,S.ZP)("MuiPickersOutlinedInput",e)}let mJ=(0,so.Z)({},mK,(0,C.Z)("MuiPickersOutlinedInput",["root","notchedOutline","input"])),m0=["children","className","label","notched","shrink"],m1=(0,y.ZP)("fieldset",{name:"MuiPickersOutlinedInput",slot:"NotchedOutline",overridesResolver:(e,t)=>t.notchedOutline})(({theme:e})=>{let t="light"===e.palette.mode?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%",borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}}),m2=(0,y.ZP)("span")(({theme:e})=>({fontFamily:e.typography.fontFamily,fontSize:"inherit"})),m5=(0,y.ZP)("legend")(({theme:e})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:{withLabel:!1},style:{padding:0,lineHeight:"11px",transition:e.transitions.create("width",{duration:150,easing:e.transitions.easing.easeOut})}},{props:{withLabel:!0},style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:e.transitions.create("max-width",{duration:50,easing:e.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}}},{props:{withLabel:!0,notched:!0},style:{maxWidth:"100%",transition:e.transitions.create("max-width",{duration:100,easing:e.transitions.easing.easeOut,delay:50})}}]}));function m3(e){let{className:t,label:n}=e,r=(0,cF.Z)(e,m0),o=null!=n&&""!==n,i=(0,so.Z)({},e,{withLabel:o});return(0,c.jsx)(m1,(0,so.Z)({"aria-hidden":!0,className:t},r,{ownerState:i,children:(0,c.jsx)(m5,{ownerState:i,children:o?(0,c.jsx)(m2,{children:n}):(0,c.jsx)(m2,{className:"notranslate",children:""})})}))}var m4=n(3150);function m6(e){return(0,S.ZP)("MuiPickersSectionList",e)}let m8=(0,C.Z)("MuiPickersSectionList",["root","section","sectionContent"]),m9=["slots","slotProps","elements","sectionListRef"],m7=(0,y.ZP)("div",{name:"MuiPickersSectionList",slot:"Root",overridesResolver:(e,t)=>t.root})({direction:"ltr /*! @noflip */",outline:"none"}),ge=(0,y.ZP)("span",{name:"MuiPickersSectionList",slot:"Section",overridesResolver:(e,t)=>t.section})({}),gt=(0,y.ZP)("span",{name:"MuiPickersSectionList",slot:"SectionSeparator",overridesResolver:(e,t)=>t.sectionSeparator})({whiteSpace:"pre"}),gn=(0,y.ZP)("span",{name:"MuiPickersSectionList",slot:"SectionContent",overridesResolver:(e,t)=>t.sectionContent})({outline:"none"}),gr=e=>{let{classes:t}=e;return(0,h.Z)({root:["root"],section:["section"],sectionContent:["sectionContent"]},m6,t)};function go(e){let{slots:t,slotProps:n,element:r,classes:o}=e,i=t?.section??ge,a=(0,dK.Z)({elementType:i,externalSlotProps:n?.section,externalForwardedProps:r.container,className:o.section,ownerState:{}}),s=t?.sectionContent??gn,l=(0,dK.Z)({elementType:s,externalSlotProps:n?.sectionContent,externalForwardedProps:r.content,additionalProps:{suppressContentEditableWarning:!0},className:o.sectionContent,ownerState:{}}),u=t?.sectionSeparator??gt,d=(0,dK.Z)({elementType:u,externalSlotProps:n?.sectionSeparator,externalForwardedProps:r.before,ownerState:{position:"before"}}),p=(0,dK.Z)({elementType:u,externalSlotProps:n?.sectionSeparator,externalForwardedProps:r.after,ownerState:{position:"after"}});return(0,c.jsxs)(i,(0,so.Z)({},a,{children:[(0,c.jsx)(u,(0,so.Z)({},d)),(0,c.jsx)(s,(0,so.Z)({},l)),(0,c.jsx)(u,(0,so.Z)({},p))]}))}let gi=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersSectionList"}),{slots:r,slotProps:o,elements:i,sectionListRef:a}=n,s=(0,cF.Z)(n,m9),l=gr(n),u=d.useRef(null),p=(0,fP.Z)(t,u),f=e=>{if(!u.current)throw Error(`MUI X: Cannot call sectionListRef.${e} before the mount of the component.`);return u.current};d.useImperativeHandle(a,()=>({getRoot:()=>f("getRoot"),getSectionContainer:e=>f("getSectionContainer").querySelector(`.${m8.section}[data-sectionindex="${e}"]`),getSectionContent:e=>f("getSectionContent").querySelector(`.${m8.section}[data-sectionindex="${e}"] .${m8.sectionContent}`),getSectionIndexFromDOMElement(e){let t=f("getSectionIndexFromDOMElement");if(null==e||!t.contains(e))return null;let n=null;return(e.classList.contains(m8.section)?n=e:e.classList.contains(m8.sectionContent)&&(n=e.parentElement),null==n)?null:Number(n.dataset.sectionindex)}}));let h=r?.root??m7,m=(0,dK.Z)({elementType:h,externalSlotProps:o?.root,externalForwardedProps:s,additionalProps:{ref:p,suppressContentEditableWarning:!0},className:l.root,ownerState:{}});return(0,c.jsx)(h,(0,so.Z)({},m,{children:m.contentEditable?i.map(({content:e,before:t,after:n})=>`${t.children}${e.children}${n.children}`).join(""):(0,c.jsx)(d.Fragment,{children:i.map((e,t)=>(0,c.jsx)(go,{slots:r,slotProps:o,element:e,classes:l},t))})}))}),ga=["elements","areAllSectionsEmpty","defaultValue","label","value","onChange","id","autoFocus","endAdornment","startAdornment","renderSuffix","slots","slotProps","contentEditable","tabIndex","onInput","onPaste","onKeyDown","fullWidth","name","readOnly","inputProps","inputRef","sectionListRef"],gs=e=>Math.round(1e5*e)/1e5,gl=(0,y.ZP)("div",{name:"MuiPickersInputBase",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>(0,so.Z)({},e.typography.body1,{color:(e.vars||e).palette.text.primary,cursor:"text",padding:0,display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",boxSizing:"border-box",letterSpacing:`${gs(.15/16)}em`,variants:[{props:{fullWidth:!0},style:{width:"100%"}}]})),gu=(0,y.ZP)(m7,{name:"MuiPickersInputBase",slot:"SectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})(({theme:e})=>({padding:"4px 0 5px",fontFamily:e.typography.fontFamily,fontSize:"inherit",lineHeight:"1.4375em",flexGrow:1,outline:"none",display:"flex",flexWrap:"nowrap",overflow:"hidden",letterSpacing:"inherit",width:"182px",variants:[{props:{isRtl:!0},style:{textAlign:"right /*! @noflip */"}},{props:{size:"small"},style:{paddingTop:1}},{props:{adornedStart:!1,focused:!1,filled:!1},style:{color:"currentColor",opacity:0}},{props:({adornedStart:e,focused:t,filled:n,label:r})=>!e&&!t&&!n&&null==r,style:e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:"light"===e.palette.mode?.42:.5}}]})),gc=(0,y.ZP)(ge,{name:"MuiPickersInputBase",slot:"Section",overridesResolver:(e,t)=>t.section})(({theme:e})=>({fontFamily:e.typography.fontFamily,fontSize:"inherit",letterSpacing:"inherit",lineHeight:"1.4375em",display:"inline-block",whiteSpace:"nowrap"})),gd=(0,y.ZP)(gn,{name:"MuiPickersInputBase",slot:"SectionContent",overridesResolver:(e,t)=>t.content})(({theme:e})=>({fontFamily:e.typography.fontFamily,lineHeight:"1.4375em",letterSpacing:"inherit",width:"fit-content",outline:"none"})),gp=(0,y.ZP)(gt,{name:"MuiPickersInputBase",slot:"Separator",overridesResolver:(e,t)=>t.separator})(()=>({whiteSpace:"pre",letterSpacing:"inherit"})),gf=(0,y.ZP)("input",{name:"MuiPickersInputBase",slot:"Input",overridesResolver:(e,t)=>t.hiddenInput})((0,so.Z)({},{border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"})),gh=e=>{let{focused:t,disabled:n,error:r,classes:o,fullWidth:i,readOnly:a,color:s,size:l,endAdornment:u,startAdornment:c}=e,d={root:["root",t&&!n&&"focused",n&&"disabled",a&&"readOnly",r&&"error",i&&"fullWidth",`color${(0,m4.Z)(s)}`,"small"===l&&"inputSizeSmall",!!c&&"adornedStart",!!u&&"adornedEnd"],notchedOutline:["notchedOutline"],input:["input"],sectionsContainer:["sectionsContainer"],sectionContent:["sectionContent"],sectionBefore:["sectionBefore"],sectionAfter:["sectionAfter"]};return(0,h.Z)(d,mX,o)},gm=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersInputBase"}),{elements:r,areAllSectionsEmpty:o,value:i,onChange:a,id:s,endAdornment:l,startAdornment:u,renderSuffix:p,slots:f,slotProps:h,contentEditable:m,tabIndex:g,onInput:v,onPaste:y,onKeyDown:b,name:x,readOnly:w,inputProps:C,inputRef:S,sectionListRef:M}=n,k=(0,cF.Z)(n,ga),E=d.useRef(null),D=(0,fP.Z)(t,E),T=(0,fP.Z)(C?.ref,S),P=(0,oz.V)(),Z=(0,mY.Z)();if(!Z)throw Error("MUI X: PickersInputBase should always be used inside a PickersTextField component");d.useEffect(()=>{Z&&Z.setAdornedStart(!!u)},[Z,u]),d.useEffect(()=>{Z&&(o?Z.onEmpty():Z.onFilled())},[Z,o]);let O=(0,so.Z)({},n,Z,{isRtl:P}),j=gh(O),R=f?.root||gl,N=(0,dK.Z)({elementType:R,externalSlotProps:h?.root,externalForwardedProps:k,additionalProps:{"aria-invalid":Z.error,ref:D},className:j.root,ownerState:O}),A=f?.input||gu;return(0,c.jsxs)(R,(0,so.Z)({},N,{children:[u,(0,c.jsx)(gi,{sectionListRef:M,elements:r,contentEditable:m,tabIndex:g,className:j.sectionsContainer,onFocus:e=>{if(Z.disabled){e.stopPropagation();return}Z.onFocus?.(e)},onBlur:Z.onBlur,onInput:v,onPaste:y,onKeyDown:b,slots:{root:A,section:gc,sectionContent:gd,sectionSeparator:gp},slotProps:{root:{ownerState:O},sectionContent:{className:mK.sectionContent},sectionSeparator:({position:e})=>({className:"before"===e?mK.sectionBefore:mK.sectionAfter})}}),l,p?p((0,so.Z)({},Z)):null,(0,c.jsx)(gf,(0,so.Z)({name:x,className:j.input,value:i,onChange:a,id:s,"aria-hidden":"true",tabIndex:-1,readOnly:w,required:Z.required,disabled:Z.disabled},C,{ref:T}))]}))}),gg=["label","autoFocus","ownerState","notched"],gv=(0,y.ZP)(gl,{name:"MuiPickersOutlinedInput",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>{let t="light"===e.palette.mode?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{padding:"0 14px",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${mJ.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${mJ.notchedOutline}`]:{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}},[`&.${mJ.focused} .${mJ.notchedOutline}`]:{borderStyle:"solid",borderWidth:2},[`&.${mJ.disabled}`]:{[`& .${mJ.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled},"*":{color:(e.vars||e).palette.action.disabled}},[`&.${mJ.error} .${mJ.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},variants:Object.keys((e.vars??e).palette).filter(t=>(e.vars??e).palette[t]?.main??!1).map(t=>({props:{color:t},style:{[`&.${mJ.focused}:not(.${mJ.error}) .${mJ.notchedOutline}`]:{borderColor:(e.vars||e).palette[t].main}}}))}}),gy=(0,y.ZP)(gu,{name:"MuiPickersOutlinedInput",slot:"SectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})({padding:"16.5px 0",variants:[{props:{size:"small"},style:{padding:"8.5px 0"}}]}),gb=e=>{let{classes:t}=e,n=(0,h.Z)({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},mQ,t);return(0,so.Z)({},t,n)},gx=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersOutlinedInput"}),{label:r,ownerState:o,notched:i}=n,a=(0,cF.Z)(n,gg),s=(0,mY.Z)(),l=(0,so.Z)({},n,o,s,{color:s?.color||"primary"}),u=gb(l);return(0,c.jsx)(gm,(0,so.Z)({slots:{root:gv,input:gy},renderSuffix:e=>(0,c.jsx)(m3,{shrink:!!(i||e.adornedStart||e.focused||e.filled),notched:!!(i||e.adornedStart||e.focused||e.filled),className:u.notchedOutline,label:null!=r&&""!==r&&s?.required?(0,c.jsxs)(d.Fragment,{children:[r," ","*"]}):r,ownerState:l})},a,{label:r,classes:u,ref:t}))});gx.muiName="Input";var gw=n(35315);function gC(e){return(0,S.ZP)("MuiPickersFilledInput",e)}let gS=(0,so.Z)({},mK,(0,C.Z)("MuiPickersFilledInput",["root","underline","input"])),gM=["label","autoFocus","disableUnderline","ownerState"],gk=(0,y.ZP)(gl,{name:"MuiPickersFilledInput",slot:"Root",overridesResolver:(e,t)=>t.root,shouldForwardProp:e=>(0,gw.x9)(e)&&"disableUnderline"!==e})(({theme:e})=>{let t="light"===e.palette.mode,n=t?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)";return{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:n,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:t?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)","@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:n}},[`&.${gS.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:n},[`&.${gS.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:t?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)"},variants:[...Object.keys((e.vars??e).palette).filter(t=>(e.vars??e).palette[t].main).map(t=>({props:{color:t,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[t]?.main}`}}})),{props:{disableUnderline:!1},style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${gS.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${gS.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`:t?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)"}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${gS.disabled}, .${gS.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${gS.disabled}:before`]:{borderBottomStyle:"dotted"}}},{props:({startAdornment:e})=>!!e,style:{paddingLeft:12}},{props:({endAdornment:e})=>!!e,style:{paddingRight:12}}]}}),gE=(0,y.ZP)(gu,{name:"MuiPickersFilledInput",slot:"sectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({startAdornment:e})=>!!e,style:{paddingLeft:0}},{props:({endAdornment:e})=>!!e,style:{paddingRight:0}},{props:{hiddenLabel:!0},style:{paddingTop:16,paddingBottom:17}},{props:{hiddenLabel:!0,size:"small"},style:{paddingTop:8,paddingBottom:9}}]}),gD=e=>{let{classes:t,disableUnderline:n}=e,r=(0,h.Z)({root:["root",!n&&"underline"],input:["input"]},gC,t);return(0,so.Z)({},t,r)},gT=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersFilledInput"}),{label:r,disableUnderline:o=!1,ownerState:i}=n,a=(0,cF.Z)(n,gM),s=(0,mY.Z)(),l=gD((0,so.Z)({},n,i,s,{color:s?.color||"primary"}));return(0,c.jsx)(gm,(0,so.Z)({slots:{root:gk,input:gE},slotProps:{root:{disableUnderline:o}}},a,{label:r,classes:l,ref:t}))});function gP(e){return(0,S.ZP)("MuiPickersFilledInput",e)}gT.muiName="Input";let gZ=(0,so.Z)({},mK,(0,C.Z)("MuiPickersInput",["root","input"])),gO=["label","autoFocus","disableUnderline","ownerState"],gj=(0,y.ZP)(gl,{name:"MuiPickersInput",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>{let t="light"===e.palette.mode?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(t=`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`),{"label + &":{marginTop:16},variants:[...Object.keys((e.vars??e).palette).filter(t=>(e.vars??e).palette[t].main).map(t=>({props:{color:t},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[t].main}`}}})),{props:{disableUnderline:!1},style:{"&::after":{background:"red",left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${gZ.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${gZ.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${t}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${gZ.disabled}, .${gZ.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${t}`}},[`&.${gZ.disabled}:before`]:{borderBottomStyle:"dotted"}}}]}}),gR=e=>{let{classes:t,disableUnderline:n}=e,r=(0,h.Z)({root:["root",!n&&"underline"],input:["input"]},gP,t);return(0,so.Z)({},t,r)},gN=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersInput"}),{label:r,disableUnderline:o=!1,ownerState:i}=n,a=(0,cF.Z)(n,gO),s=(0,mY.Z)(),l=gR((0,so.Z)({},n,i,s,{disableUnderline:o,color:s?.color||"primary"}));return(0,c.jsx)(gm,(0,so.Z)({slots:{root:gj}},a,{label:r,classes:l,ref:t}))});gN.muiName="Input";let gA=["onFocus","onBlur","className","color","disabled","error","variant","required","InputProps","inputProps","inputRef","sectionListRef","elements","areAllSectionsEmpty","onClick","onKeyDown","onKeyUp","onPaste","onInput","endAdornment","startAdornment","tabIndex","contentEditable","focused","value","onChange","fullWidth","id","name","helperText","FormHelperTextProps","label","InputLabelProps"],gF={standard:gN,filled:gT,outlined:gx},gI=(0,y.ZP)(rN.Z,{name:"MuiPickersTextField",slot:"Root",overridesResolver:(e,t)=>t.root})({}),g_=e=>{let{focused:t,disabled:n,classes:r,required:o}=e;return(0,h.Z)({root:["root",t&&!n&&"focused",n&&"disabled",o&&"required"]},mq,r)},gL=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiPickersTextField"}),{onFocus:r,onBlur:o,className:i,color:a="primary",disabled:s=!1,error:l=!1,variant:u="outlined",required:p=!1,InputProps:h,inputProps:m,inputRef:g,sectionListRef:v,elements:y,areAllSectionsEmpty:b,onClick:x,onKeyDown:w,onKeyUp:C,onPaste:S,onInput:M,endAdornment:k,startAdornment:E,tabIndex:D,contentEditable:T,focused:P,value:Z,onChange:O,fullWidth:j,id:R,name:N,helperText:A,FormHelperTextProps:F,label:I,InputLabelProps:_}=n,L=(0,cF.Z)(n,gA),V=d.useRef(null),$=(0,fP.Z)(t,V),B=(0,dX.Z)(R),z=A&&B?`${B}-helper-text`:void 0,H=I&&B?`${B}-label`:void 0,W=(0,so.Z)({},n,{color:a,disabled:s,error:l,focused:P,required:p,variant:u}),G=g_(W),U=gF[u];return(0,c.jsxs)(gI,(0,so.Z)({className:(0,f.Z)(G.root,i),ref:$,focused:P,onFocus:r,onBlur:o,disabled:s,variant:u,error:l,color:a,fullWidth:j,required:p,ownerState:W},L,{children:[(0,c.jsx)(mG.Z,(0,so.Z)({htmlFor:B,id:H},_,{children:I})),(0,c.jsx)(U,(0,so.Z)({elements:y,areAllSectionsEmpty:b,onClick:x,onKeyDown:w,onKeyUp:C,onInput:M,onPaste:S,endAdornment:k,startAdornment:E,tabIndex:D,contentEditable:T,value:Z,onChange:O,id:B,fullWidth:j,inputProps:m,inputRef:g,sectionListRef:v,label:I,name:N,role:"group","aria-labelledby":H,"aria-describedby":z,"aria-live":z?"polite":void 0},h)),A&&(0,c.jsx)(mU.Z,(0,so.Z)({id:z},F,{children:A}))]}))}),gV=["enableAccessibleFieldDOMStructure"],g$=["InputProps","readOnly"],gB=["onPaste","onKeyDown","inputMode","readOnly","InputProps","inputProps","inputRef"],gz=e=>{let{enableAccessibleFieldDOMStructure:t}=e,n=(0,cF.Z)(e,gV);if(t){let{InputProps:e,readOnly:t}=n,r=(0,cF.Z)(n,g$);return(0,so.Z)({},r,{InputProps:(0,so.Z)({},e??{},{readOnly:t})})}let{onPaste:r,onKeyDown:o,inputMode:i,readOnly:a,InputProps:s,inputProps:l,inputRef:u}=n,c=(0,cF.Z)(n,gB);return(0,so.Z)({},c,{InputProps:(0,so.Z)({},s??{},{readOnly:a}),inputProps:(0,so.Z)({},l??{},{inputMode:i,onPaste:r,onKeyDown:o,ref:u})})},gH=["slots","slotProps","InputProps","inputProps"],gW=d.forwardRef(function(e,t){let n=cV({props:e,name:"MuiDateTimeField"}),{slots:r,slotProps:o,InputProps:i,inputProps:a}=n,s=(0,cF.Z)(n,gH),l=r?.textField??(e.enableAccessibleFieldDOMStructure?gL:e7.Z),u=(0,dK.Z)({elementType:l,externalSlotProps:o?.textField,externalForwardedProps:s,ownerState:n,additionalProps:{ref:t}});u.inputProps=(0,so.Z)({},a,u.inputProps),u.InputProps=(0,so.Z)({},i,u.InputProps);let d=gz(m$(u)),p=mW((0,so.Z)({},d,{slots:r,slotProps:o}));return(0,c.jsx)(l,(0,so.Z)({},p))});var gG=n(29435),gU=n(32791),gq=n(14336),gY=n(22694),gX=n(5154),gK=n(39489),gQ=n(6341),gJ=n(13189),g0=n(35918),g1=n(89880),g2=n(58006),g5=n(16332),g3=n(71721),g4=n(61721),g6=n(28904),g8=n(7785),g9=n(38364),g7=n(18340),ve=n(20506),vt=n(74265),vn=n(26635),vr=n(41275),vo=n(14107),vi=n(50436),va=n(97912),vs=n(59250),vl=n(3303),vu=n(78374),vc=n(53743),vd=n(18070),vp=n(83709),vf=n(63200),vh=n(36292),vm=n(11136),vg=n(33518),vv=n(44138),vy=n(28140),vb=n(23033),vx=n(50007),vw=n(24575),vC=n(5149),vS=n(18874),vM=n(62511),vk=n(14257);let vE={y:{sectionType:"year",contentType:"digit",maxLength:4},yy:"year",yyy:{sectionType:"year",contentType:"digit",maxLength:4},yyyy:"year",M:{sectionType:"month",contentType:"digit",maxLength:2},MM:"month",MMMM:{sectionType:"month",contentType:"letter"},MMM:{sectionType:"month",contentType:"letter"},L:{sectionType:"month",contentType:"digit",maxLength:2},LL:"month",LLL:{sectionType:"month",contentType:"letter"},LLLL:{sectionType:"month",contentType:"letter"},d:{sectionType:"day",contentType:"digit",maxLength:2},dd:"day",do:{sectionType:"day",contentType:"digit-with-letter"},E:{sectionType:"weekDay",contentType:"letter"},EE:{sectionType:"weekDay",contentType:"letter"},EEE:{sectionType:"weekDay",contentType:"letter"},EEEE:{sectionType:"weekDay",contentType:"letter"},EEEEE:{sectionType:"weekDay",contentType:"letter"},i:{sectionType:"weekDay",contentType:"digit",maxLength:1},ii:"weekDay",iii:{sectionType:"weekDay",contentType:"letter"},iiii:{sectionType:"weekDay",contentType:"letter"},e:{sectionType:"weekDay",contentType:"digit",maxLength:1},ee:"weekDay",eee:{sectionType:"weekDay",contentType:"letter"},eeee:{sectionType:"weekDay",contentType:"letter"},eeeee:{sectionType:"weekDay",contentType:"letter"},eeeeee:{sectionType:"weekDay",contentType:"letter"},c:{sectionType:"weekDay",contentType:"digit",maxLength:1},cc:"weekDay",ccc:{sectionType:"weekDay",contentType:"letter"},cccc:{sectionType:"weekDay",contentType:"letter"},ccccc:{sectionType:"weekDay",contentType:"letter"},cccccc:{sectionType:"weekDay",contentType:"letter"},a:"meridiem",aa:"meridiem",aaa:"meridiem",H:{sectionType:"hours",contentType:"digit",maxLength:2},HH:"hours",h:{sectionType:"hours",contentType:"digit",maxLength:2},hh:"hours",m:{sectionType:"minutes",contentType:"digit",maxLength:2},mm:"minutes",s:{sectionType:"seconds",contentType:"digit",maxLength:2},ss:"seconds"},vD={year:"yyyy",month:"LLLL",monthShort:"MMM",dayOfMonth:"d",dayOfMonthFull:"do",weekday:"EEEE",weekdayShort:"EEEEEE",hours24h:"HH",hours12h:"hh",meridiem:"aa",minutes:"mm",seconds:"ss",fullDate:"PP",keyboardDate:"P",shortDate:"MMM d",normalDate:"d MMMM",normalDateWithWeekday:"EEE, MMM d",fullTime:"p",fullTime12h:"hh:mm aa",fullTime24h:"HH:mm",keyboardDateTime:"P p",keyboardDateTime12h:"P hh:mm aa",keyboardDateTime24h:"P HH:mm"};class vT{constructor(e){this.isMUIAdapter=!0,this.isTimezoneCompatible=!1,this.lib=void 0,this.locale=void 0,this.formats=void 0,this.formatTokenMap=vE,this.escapedCharacters={start:"'",end:"'"},this.longFormatters=void 0,this.date=e=>void 0===e?new Date:null===e?null:new Date(e),this.getInvalidDate=()=>new Date("Invalid Date"),this.getTimezone=()=>"default",this.setTimezone=e=>e,this.toJsDate=e=>e,this.getCurrentLocaleCode=()=>this.locale.code,this.is12HourCycleInCurrentLocale=()=>/a/.test(this.locale.formatLong.time({width:"short"})),this.expandFormat=e=>e.match(/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g).map(e=>{let t=e[0];return"p"===t||"P"===t?(0,this.longFormatters[t])(e,this.locale.formatLong):e}).join(""),this.formatNumber=e=>e,this.getDayOfWeek=e=>e.getDay()+1;let{locale:t,formats:n,longFormatters:r,lib:o}=e;this.locale=t,this.formats=(0,so.Z)({},vD,n),this.longFormatters=r,this.lib=o||"date-fns"}}class vP extends vT{constructor({locale:e,formats:t}={}){super({locale:e??vk._,formats:t,longFormatters:g2.G}),this.parse=(e,t)=>""===e?null:(0,vd.Qc)(e,t,new Date,{locale:this.locale}),this.isValid=e=>null!=e&&(0,vc.J)(e),this.format=(e,t)=>this.formatByString(e,this.formats[t]),this.formatByString=(e,t)=>(0,g5.WU)(e,t,{locale:this.locale}),this.isEqual=(e,t)=>null===e&&null===t||null!==e&&null!==t&&(0,vi.X)(e,t),this.isSameYear=(e,t)=>(0,vs.F)(e,t),this.isSameMonth=(e,t)=>(0,vl.x)(e,t),this.isSameDay=(e,t)=>(0,va.K)(e,t),this.isSameHour=(e,t)=>(0,vu.f)(e,t),this.isAfter=(e,t)=>(0,vr.A)(e,t),this.isAfterYear=(e,t)=>(0,vr.A)(e,(0,g1.w)(t)),this.isAfterDay=(e,t)=>(0,vr.A)(e,(0,gJ.i)(t)),this.isBefore=(e,t)=>(0,vo.R)(e,t),this.isBeforeYear=(e,t)=>(0,vo.R)(e,this.startOfYear(t)),this.isBeforeDay=(e,t)=>(0,vo.R)(e,this.startOfDay(t)),this.isWithinRange=(e,[t,n])=>(0,vM._)(e,{start:t,end:n}),this.startOfYear=e=>(0,vS.e)(e),this.startOfMonth=e=>(0,vx.N)(e),this.startOfWeek=e=>(0,vC.z)(e,{locale:this.locale}),this.startOfDay=e=>(0,vb.b)(e),this.endOfYear=e=>(0,g1.w)(e),this.endOfMonth=e=>(0,vw.V)(e),this.endOfWeek=e=>(0,g0.v)(e,{locale:this.locale}),this.endOfDay=e=>(0,gJ.i)(e),this.addYears=(e,t)=>(0,gQ.B)(e,t),this.addMonths=(e,t)=>(0,gK.z)(e,t),this.addWeeks=(e,t)=>(0,gX.j)(e,t),this.addDays=(e,t)=>(0,gG.E)(e,t),this.addHours=(e,t)=>(0,gY.T)(e,t),this.addMinutes=(e,t)=>(0,gq.m)(e,t),this.addSeconds=(e,t)=>(0,gU.v)(e,t),this.getYear=e=>(0,vn.S)(e),this.getMonth=e=>(0,g9.j)(e),this.getDate=e=>(0,g3._)(e),this.getHours=e=>(0,g6.p)(e),this.getMinutes=e=>(0,g8.q)(e),this.getSeconds=e=>(0,g7.C)(e),this.getMilliseconds=e=>(0,ve.p)(e),this.setYear=(e,t)=>(0,vy.M)(e,t),this.setMonth=(e,t)=>(0,vm.q)(e,t),this.setDate=(e,t)=>(0,vp.G)(e,t),this.setHours=(e,t)=>(0,vf.B)(e,t),this.setMinutes=(e,t)=>(0,vh.H)(e,t),this.setSeconds=(e,t)=>(0,vg.O)(e,t),this.setMilliseconds=(e,t)=>(0,vv.I)(e,t),this.getDaysInMonth=e=>(0,g4.N)(e),this.getWeekArray=e=>{let t=this.startOfWeek(this.startOfMonth(e)),n=this.endOfWeek(this.endOfMonth(e)),r=0,o=t,i=[];for(;this.isBefore(o,n);){let e=Math.floor(r/7);i[e]=i[e]||[],i[e].push(o),o=this.addDays(o,1),r+=1}return i},this.getWeekNumber=e=>(0,vt.Q)(e,{locale:this.locale}),this.getYearRange=([e,t])=>{let n=this.startOfYear(e),r=this.endOfYear(t),o=[],i=n;for(;this.isBefore(i,r);)o.push(i),i=this.addYears(i,1);return o}}}let vZ="yyyy-MM-dd HH:mm:ss";function vO(e,t){return e?(0,cA.s3)(e)?e.pastDuration:function(e,t,n){let r=iP(e.start,t,n),o=iP(e.end,t,n);return`${r} - ${o}`}(e,vZ,t):"Custom Time Range"}let vj=({initialTimeRange:e,onChange:t,onCancel:n})=>{let{formatWithUserTimeZone:r}=iA(),[o,i]=(0,d.useState)(e),[a,s]=(0,d.useState)({start:r(e.start,vZ),end:r(e.end,vZ)}),[l,u]=(0,d.useState)(!0),p=(e,t)=>{let n="string"==typeof e,o=n?e:r(e,vZ);s(e=>({...e,[t]:o})),n||i(n=>({...n,[t]:e}))},f=e=>{p(e,"start")},h=e=>{p(e,"end")},m=()=>{var e,t;let n={start:new Date(a.start),end:new Date(a.end)};if(e=n.start,t=n.end,(0,iD.isValid)(e)&&(0,iD.isValid)(t)?!!(0,iD.isBefore)(e,t)||(console.error("End Time is before Start Time"),!1):(console.error("Invalid Date"),!1))return i(n),n},g=()=>{let e=m();e&&t(e)};return(0,c.jsx)(cz,{dateAdapter:vP,children:(0,c.jsxs)(e8.Z,{spacing:2,sx:e=>({padding:e.spacing(1,0,2)}),children:[l&&(0,c.jsxs)(eV.Z,{sx:e=>({".MuiPickersLayout-contentWrapper":{backgroundColor:e.palette.background.default}}),children:[(0,c.jsx)(nQ.Z,{variant:"h3",padding:1,paddingLeft:2,children:"Select Start Time"}),(0,c.jsx)(mb,{displayStaticWrapperAs:"desktop",openTo:"day",disableHighlightToday:!0,value:e.start,onChange:e=>{null!==e&&f(e)},onAccept:()=>{u(!1)}})]}),!l&&(0,c.jsxs)(eV.Z,{sx:e=>({".MuiPickersLayout-contentWrapper":{backgroundColor:e.palette.background.default}}),children:[(0,c.jsx)(nQ.Z,{variant:"h3",padding:1,paddingLeft:2,children:"Select End Time"}),(0,c.jsx)(mb,{displayStaticWrapperAs:"desktop",openTo:"day",disableHighlightToday:!0,value:e.end,minDateTime:o.start,onChange:e=>{null!==e&&h(e)},onAccept:e=>{null!==e&&(u(!0),h(e))}})]}),(0,c.jsxs)(e8.Z,{direction:"row",alignItems:"center",gap:1,pl:1,pr:1,children:[(0,c.jsx)(it.ErrorBoundary,{FallbackComponent:ie,children:(0,c.jsx)(gW,{label:"Start Time",value:new Date(a.start),onChange:e=>{e&&f(e)},onBlur:()=>m(),format:vZ})}),(0,c.jsx)(it.ErrorBoundary,{FallbackComponent:ie,children:(0,c.jsx)(gW,{label:"End Time",value:new Date(a.end),onChange:e=>{e&&h(e)},onBlur:()=>m(),format:vZ})})]}),(0,c.jsxs)(e8.Z,{direction:"row",sx:{padding:e=>e.spacing(0,1)},gap:1,children:[(0,c.jsx)(O.Z,{variant:"contained",onClick:()=>g(),fullWidth:!0,children:"Apply"}),(0,c.jsx)(O.Z,{variant:"outlined",onClick:()=>n(),fullWidth:!0,children:"Cancel"})]})]})})};function vR({value:e,timeOptions:t,onChange:n,height:r,showCustomTimeRange:o=!0}){let{timeZone:i}=iA(),a=(0,d.useRef)(),[s,l]=(0,d.useState)(!1),u=(0,d.useMemo)(()=>(0,cA.s3)(e)?(0,cA.sG)(e):e,[e]),p=(0,d.useMemo)(()=>{var t;return{value:t=(0,cA.s3)(e)?void 0:e,display:vO(t,i)}},[e,i]),[f,h]=(0,d.useState)(!1);return(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(tB.ZP,{anchorEl:a.current,anchorOrigin:{vertical:"bottom",horizontal:"center"},open:s,onClose:()=>l(!1),sx:e=>({padding:e.spacing(2)}),children:(0,c.jsx)(vj,{initialTimeRange:u,onChange:e=>{n(e),l(!1),h(!1)},onCancel:()=>l(!1)})}),(0,c.jsx)(eV.Z,{ref:a,children:(0,c.jsxs)(cR.Z,{open:f,value:vO(e,i),onClick:()=>h(!f),IconComponent:cN.default,inputProps:{"aria-label":`Select time range. Currently set to ${e}`},sx:{".MuiSelect-icon":{marginTop:"1px",transform:"none"},".MuiSelect-select.MuiSelect-outlined.MuiInputBase-input":{paddingRight:"36px"},".MuiSelect-select":r?{lineHeight:r,paddingY:0}:{}},children:[t.map((e,t)=>(0,c.jsx)(oI.Z,{value:vO(e.value,i),onClick:()=>{n(e.value)},children:e.display},t)),o&&(0,c.jsx)(oI.Z,{value:vO(p.value,i),onClick:()=>l(!0),children:p.display})]})})]})}let vN=(0,y.ZP)(O.Z)(({theme:e})=>({padding:e.spacing(.5),minWidth:"auto"})),vA=(0,d.forwardRef)(function(e,t){return(0,c.jsx)(vN,{ref:t,variant:"outlined",color:"secondary",...e})}),vF=Object.entries(eP).map(([e,t])=>({id:e,...t})).filter(e=>!e.disableSelectorOption),vI=[{id:"default",label:"Default",decimalPlaces:void 0},{id:"0",label:"0",decimalPlaces:0},{id:"1",label:"1",decimalPlaces:1},{id:"2",label:"2",decimalPlaces:2},{id:"3",label:"3",decimalPlaces:3},{id:"4",label:"4",decimalPlaces:4}];function v_({value:e,onChange:t,disabled:n=!1}){var r;let o=!!ej(e).decimalPlaces,i=!!ej(e).shortValues,a=({decimalPlaces:n})=>{o&&t({...e,decimalPlaces:n})},s=eP[e.unit];return(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(rz,{label:"Short values",control:(0,c.jsx)(i9.Z,{checked:!!i&&!1!==e.shortValues,onChange:(n,r)=>{i&&t({...e,shortValues:r})},disabled:!i})}),(0,c.jsx)(rz,{label:"Unit",control:(0,c.jsx)(rG,{value:{id:e.unit,...s},options:vF,groupBy:e=>e.group,onChange:(e,n)=>{t({unit:n.id})},disableClearable:!0,disabled:n})}),(0,c.jsx)(rz,{label:"Decimals",control:(0,c.jsx)(rG,{value:(r=e.decimalPlaces,vI.find(e=>e.decimalPlaces===r)),options:vI,getOptionLabel:e=>e.label,onChange:(e,t)=>a(t),disabled:!o,disableClearable:!0})})]})}function vL({name:e,height:t}){return(0,c.jsx)(eV.Z,{style:{maxWidth:t,top:`calc(${t}px / 2)`},sx:{display:"inline-block",position:"absolute",transform:"translateX(-50%) rotate(-90deg)",transformOrigin:"top",textAlign:"center",zIndex:1},children:(0,c.jsx)(nQ.Z,{variant:"body1","aria-label":"y axis label",sx:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},children:e})})}var vV=n(6085);let v$=function(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=function e(t){var n,r,o="";if("string"==typeof t||"number"==typeof t)o+=t;else if("object"==typeof t){if(Array.isArray(t))for(n=0;n<t.length;n++)t[n]&&(r=e(t[n]))&&(o&&(o+=" "),o+=r);else for(n in t)t[n]&&(o&&(o+=" "),o+=n)}return o}(e))&&(r&&(r+=" "),r+=t);return r},vB={data:""},vz=e=>"object"==typeof window?((e?e.querySelector("#_goober"):window._goober)||Object.assign((e||document.head).appendChild(document.createElement("style")),{innerHTML:" ",id:"_goober"})).firstChild:e||vB,vH=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,vW=/\/\*[^]*?\*\/| +/g,vG=/\n+/g,vU=(e,t)=>{let n="",r="",o="";for(let i in e){let a=e[i];"@"==i[0]?"i"==i[1]?n=i+" "+a+";":r+="f"==i[1]?vU(a,i):i+"{"+vU(a,"k"==i[1]?"":t)+"}":"object"==typeof a?r+=vU(a,t?t.replace(/([^,])+/g,e=>i.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,t=>/&/.test(t)?t.replace(/&/g,e):e?e+" "+t:t)):i):null!=a&&(i=/^--/.test(i)?i:i.replace(/[A-Z]/g,"-$&").toLowerCase(),o+=vU.p?vU.p(i,a):i+":"+a+";")}return n+(t&&o?t+"{"+o+"}":o)+r},vq={},vY=e=>{if("object"==typeof e){let t="";for(let n in e)t+=n+vY(e[n]);return t}return e},vX=(e,t,n,r,o)=>{var i;let a=vY(e),s=vq[a]||(vq[a]=(e=>{let t=0,n=11;for(;t<e.length;)n=101*n+e.charCodeAt(t++)>>>0;return"go"+n})(a));if(!vq[s]){let t=a!==e?e:(e=>{let t,n,r=[{}];for(;t=vH.exec(e.replace(vW,""));)t[4]?r.shift():t[3]?(n=t[3].replace(vG," ").trim(),r.unshift(r[0][n]=r[0][n]||{})):r[0][t[1]]=t[2].replace(vG," ").trim();return r[0]})(e);vq[s]=vU(o?{["@keyframes "+s]:t}:t,n?"":"."+s)}let l=n&&vq.g?vq.g:null;return n&&(vq.g=vq[s]),i=vq[s],l?t.data=t.data.replace(l,i):-1===t.data.indexOf(i)&&(t.data=r?i+t.data:t.data+i),s},vK=(e,t,n)=>e.reduce((e,r,o)=>{let i=t[o];if(i&&i.call){let e=i(n),t=e&&e.props&&e.props.className||/^go/.test(e)&&e;i=t?"."+t:e&&"object"==typeof e?e.props?"":vU(e,""):!1===e?"":e}return e+r+(null==i?"":i)},"");function vQ(e){let t=this||{},n=e.call?e(t.p):e;return vX(n.unshift?n.raw?vK(n,[].slice.call(arguments,1),t.p):n.reduce((e,n)=>Object.assign(e,n&&n.call?n(t.p):n),{}):n,vz(t.target),t.g,t.o,t.k)}function vJ(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function v0(e,t,n){return t&&vJ(e.prototype,t),n&&vJ(e,n),e}function v1(){return(v1=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function v2(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function v5(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}function v3(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}vQ.bind({g:1}),vQ.bind({k:1});var v4=function(){return""},v6=p().createContext({enqueueSnackbar:v4,closeSnackbar:v4}),v8="@media (max-width:599.95px)",v9="@media (min-width:600px)",v7=function(e){return e.charAt(0).toUpperCase()+e.slice(1)},ye=function(e){return""+v7(e.vertical)+v7(e.horizontal)},yt=function(e){return!!e||0===e},yn="unmounted",yr="exited",yo="entering",yi="entered",ya="exiting",ys=function(e){function t(t){n=e.call(this,t)||this;var n,r,o=t.appear;return n.appearStatus=null,t.in?o?(r=yr,n.appearStatus=yo):r=yi:r=t.unmountOnExit||t.mountOnEnter?yn:yr,n.state={status:r},n.nextCallback=null,n}v2(t,e),t.getDerivedStateFromProps=function(e,t){return e.in&&t.status===yn?{status:yr}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==yo&&n!==yi&&(t=yo):(n===yo||n===yi)&&(t=ya)}this.updateStatus(!1,t)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var e=this.props.timeout,t=e,n=e;return null!=e&&"number"!=typeof e&&"string"!=typeof e&&(n=e.exit,t=e.enter),{exit:n,enter:t}},n.updateStatus=function(e,t){void 0===e&&(e=!1),null!==t?(this.cancelNextCallback(),t===yo?this.performEnter(e):this.performExit()):this.props.unmountOnExit&&this.state.status===yr&&this.setState({status:yn})},n.performEnter=function(e){var t=this,n=this.props.enter,r=this.getTimeouts();if(!e&&!n){this.safeSetState({status:yi},function(){t.props.onEntered&&t.props.onEntered(t.node,e)});return}this.props.onEnter&&this.props.onEnter(this.node,e),this.safeSetState({status:yo},function(){t.props.onEntering&&t.props.onEntering(t.node,e),t.onTransitionEnd(r.enter,function(){t.safeSetState({status:yi},function(){t.props.onEntered&&t.props.onEntered(t.node,e)})})})},n.performExit=function(){var e=this,t=this.props.exit,n=this.getTimeouts();if(!t){this.safeSetState({status:yr},function(){e.props.onExited&&e.props.onExited(e.node)});return}this.props.onExit&&this.props.onExit(this.node),this.safeSetState({status:ya},function(){e.props.onExiting&&e.props.onExiting(e.node),e.onTransitionEnd(n.exit,function(){e.safeSetState({status:yr},function(){e.props.onExited&&e.props.onExited(e.node)})})})},n.cancelNextCallback=function(){null!==this.nextCallback&&this.nextCallback.cancel&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},n.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(){n&&(n=!1,t.nextCallback=null,e())},this.nextCallback.cancel=function(){n=!1},this.nextCallback},n.onTransitionEnd=function(e,t){this.setNextCallback(t);var n=null==e&&!this.props.addEndListener;if(!this.node||n){setTimeout(this.nextCallback,0);return}this.props.addEndListener&&this.props.addEndListener(this.node,this.nextCallback),null!=e&&setTimeout(this.nextCallback,e)},n.render=function(){var e=this.state.status;if(e===yn)return null;var t=this.props;return(0,t.children)(e,v5(t,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]))},v0(t,[{key:"node",get:function(){var e,t=null===(e=this.props.nodeRef)||void 0===e?void 0:e.current;if(!t)throw Error("notistack - Custom snackbar is not refForwarding");return t}}]),t}(p().Component);function yl(){}function yu(e,t){"function"==typeof e?e(t):e&&(e.current=t)}function yc(e,t){return(0,d.useMemo)(function(){return null==e&&null==t?null:function(n){yu(e,n),yu(t,n)}},[e,t])}function yd(e){var t=e.timeout,n=e.style,r=void 0===n?{}:n,o=e.mode;return{duration:"object"==typeof t?t[o]||0:t,easing:r.transitionTimingFunction,delay:r.transitionDelay}}ys.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:yl,onEntering:yl,onEntered:yl,onExit:yl,onExiting:yl,onExited:yl};var yp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},yf=function(e){e.scrollTop=e.scrollTop},yh=function(e){return Math.round(e)+"ms"};function ym(e,t){void 0===e&&(e=["all"]);var n=t||{},r=n.duration,o=void 0===r?300:r,i=n.easing,a=void 0===i?yp.easeInOut:i,s=n.delay,l=void 0===s?0:s;return(Array.isArray(e)?e:[e]).map(function(e){return e+" "+("string"==typeof o?o:yh(o))+" "+a+" "+("string"==typeof l?l:yh(l))}).join(",")}function yg(e){return(e&&e.ownerDocument||document).defaultView||window}function yv(e,t){if(t){var n=function(e,t){var n,r=t.getBoundingClientRect(),o=yg(t);if(t.fakeTransform)n=t.fakeTransform;else{var i=o.getComputedStyle(t);n=i.getPropertyValue("-webkit-transform")||i.getPropertyValue("transform")}var a=0,s=0;if(n&&"none"!==n&&"string"==typeof n){var l=n.split("(")[1].split(")")[0].split(",");a=parseInt(l[4],10),s=parseInt(l[5],10)}switch(e){case"left":return"translateX("+(o.innerWidth+a-r.left)+"px)";case"right":return"translateX(-"+(r.left+r.width-a)+"px)";case"up":return"translateY("+(o.innerHeight+s-r.top)+"px)";default:return"translateY(-"+(r.top+r.height-s)+"px)"}}(e,t);n&&(t.style.webkitTransform=n,t.style.transform=n)}}var yy=(0,d.forwardRef)(function(e,t){var n=e.children,r=e.direction,o=void 0===r?"down":r,i=e.in,a=e.style,s=e.timeout,l=void 0===s?0:s,u=e.onEnter,c=e.onEntered,p=e.onExit,f=e.onExited,h=v5(e,["children","direction","in","style","timeout","onEnter","onEntered","onExit","onExited"]),m=(0,d.useRef)(null),g=yc(n.ref,m),v=yc(g,t),y=(0,d.useCallback)(function(){m.current&&yv(o,m.current)},[o]);return(0,d.useEffect)(function(){if(!i&&"down"!==o&&"right"!==o){var e=function(e,t){var n;function r(){for(var r=this,o=arguments.length,i=Array(o),a=0;a<o;a++)i[a]=arguments[a];clearTimeout(n),n=setTimeout(function(){e.apply(r,i)},t)}return void 0===t&&(t=166),r.clear=function(){clearTimeout(n)},r}(function(){m.current&&yv(o,m.current)}),t=yg(m.current);return t.addEventListener("resize",e),function(){e.clear(),t.removeEventListener("resize",e)}}},[o,i]),(0,d.useEffect)(function(){i||y()},[i,y]),(0,d.createElement)(ys,Object.assign({appear:!0,nodeRef:m,onEnter:function(e,t){yv(o,e),yf(e),u&&u(e,t)},onEntered:c,onEntering:function(e){var t=(null==a?void 0:a.transitionTimingFunction)||yp.easeOut,n=yd({timeout:l,mode:"enter",style:v1({},a,{transitionTimingFunction:t})});e.style.webkitTransition=ym("-webkit-transform",n),e.style.transition=ym("transform",n),e.style.webkitTransform="none",e.style.transform="none"},onExit:function(e){var t=(null==a?void 0:a.transitionTimingFunction)||yp.sharp,n=yd({timeout:l,mode:"exit",style:v1({},a,{transitionTimingFunction:t})});e.style.webkitTransition=ym("-webkit-transform",n),e.style.transition=ym("transform",n),yv(o,e),p&&p(e)},onExited:function(e){e.style.webkitTransition="",e.style.transition="",f&&f(e)},in:i,timeout:l},h),function(e,t){return(0,d.cloneElement)(n,v1({ref:v,style:v1({visibility:"exited"!==e||i?void 0:"hidden"},a,{},n.props.style)},t))})});yy.displayName="Slide";var yb=function(e){return p().createElement("svg",Object.assign({viewBox:"0 0 24 24",focusable:"false",style:{fontSize:20,marginInlineEnd:8,userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:"currentColor",flexShrink:0}},e))},yx={maxSnack:3,persist:!1,hideIconVariant:!1,disableWindowBlurListener:!1,variant:"default",autoHideDuration:5e3,iconVariant:{default:void 0,success:p().createElement(function(){return p().createElement(yb,null,p().createElement("path",{d:"M12 2C6.5 2 2 6.5 2 12S6.5 22 12 22 22 17.5 22 12 17.5 2 12 2M10 17L5 12L6.41\n 10.59L10 14.17L17.59 6.58L19 8L10 17Z"}))},null),warning:p().createElement(function(){return p().createElement(yb,null,p().createElement("path",{d:"M13,14H11V10H13M13,18H11V16H13M1,21H23L12,2L1,21Z"}))},null),error:p().createElement(function(){return p().createElement(yb,null,p().createElement("path",{d:"M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,\n 6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,\n 13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z"}))},null),info:p().createElement(function(){return p().createElement(yb,null,p().createElement("path",{d:"M13,9H11V7H13M13,17H11V11H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,\n 0 22,12A10,10 0 0,0 12,2Z"}))},null)},anchorOrigin:{vertical:"bottom",horizontal:"left"},TransitionComponent:yy,transitionDuration:{enter:225,exit:195}},yw=function(e,t){var n=function(e){return"number"==typeof e||null===e};return n(e)?e:n(t)?t:yx.autoHideDuration},yC=function(e,t){var n=function(e,t){return t.some(function(t){return typeof e===t})};return n(e,["string","number"])?e:n(e,["object"])?v1({},yx.transitionDuration,{},n(t,["object"])&&t,{},e):n(t,["string","number"])?t:n(t,["object"])?v1({},yx.transitionDuration,{},t):yx.transitionDuration};function yS(e){return Object.entries(e).reduce(function(e,t){var n,r=t[0],o=t[1];return v1({},e,((n={})[r]=vQ(o),n))},{})}var yM="notistack-CollapseWrapper",yk=yS({root:{height:0},entered:{height:"auto"}}),yE=(0,d.forwardRef)(function(e,t){var n=e.children,r=e.in,o=e.onExited,i=(0,d.useRef)(null),a=(0,d.useRef)(null),s=yc(t,a),l=function(){return i.current?i.current.clientHeight:0};return(0,d.createElement)(ys,{in:r,unmountOnExit:!0,onEnter:function(e){e.style.height="0px"},onEntered:function(e){e.style.height="auto"},onEntering:function(e){var t=l(),n=yd({timeout:175,mode:"enter"}),r=n.duration,o=n.easing;e.style.transitionDuration="string"==typeof r?r:r+"ms",e.style.height=t+"px",e.style.transitionTimingFunction=o||""},onExit:function(e){e.style.height=l()+"px"},onExited:o,onExiting:function(e){yf(e);var t=yd({timeout:175,mode:"exit"}),n=t.duration,r=t.easing;e.style.transitionDuration="string"==typeof n?n:n+"ms",e.style.height="0px",e.style.transitionTimingFunction=r||""},nodeRef:a,timeout:175},function(e,t){return(0,d.createElement)("div",Object.assign({ref:s,className:v$(yk.root,"entered"===e&&yk.entered),style:v1({pointerEvents:"all",overflow:"hidden",minHeight:"0px",transition:ym("height")},"entered"===e&&{overflow:"visible"},{},"exited"===e&&!r&&{visibility:"hidden"})},t),(0,d.createElement)("div",{ref:i,className:yM,style:{display:"flex",width:"100%"}},n))})});yE.displayName="Collapse";var yD={right:"left",left:"right",bottom:"up",top:"down"},yT=function(e){void 0===e&&(e={});var t={containerRoot:!0,containerAnchorOriginTopCenter:!0,containerAnchorOriginBottomCenter:!0,containerAnchorOriginTopRight:!0,containerAnchorOriginBottomRight:!0,containerAnchorOriginTopLeft:!0,containerAnchorOriginBottomLeft:!0};return Object.keys(e).filter(function(e){return!t[e]}).reduce(function(t,n){var r;return v1({},t,((r={})[n]=e[n],r))},{})},yP=function(){};function yZ(e,t){return e.reduce(function(e,n){return null==n?e:function(){for(var r=arguments.length,o=Array(r),i=0;i<r;i++)o[i]=arguments[i];var a=[].concat(o);t&&-1===a.indexOf(t)&&a.push(t),e.apply(this,a),n.apply(this,a)}},yP)}var yO="undefined"!=typeof window?d.useLayoutEffect:d.useEffect;function yj(e){var t=(0,d.useRef)(e);return yO(function(){t.current=e}),(0,d.useCallback)(function(){return t.current.apply(void 0,arguments)},[])}var yR=(0,d.forwardRef)(function(e,t){var n=e.children,r=e.className,o=e.autoHideDuration,i=e.disableWindowBlurListener,a=void 0!==i&&i,s=e.onClose,l=e.id,u=e.open,c=e.SnackbarProps,p=void 0===c?{}:c,f=(0,d.useRef)(),h=yj(function(){s&&s.apply(void 0,arguments)}),m=yj(function(e){s&&null!=e&&(f.current&&clearTimeout(f.current),f.current=setTimeout(function(){h(null,"timeout",l)},e))});(0,d.useEffect)(function(){return u&&m(o),function(){f.current&&clearTimeout(f.current)}},[u,o,m]);var g=function(){f.current&&clearTimeout(f.current)},v=(0,d.useCallback)(function(){null!=o&&m(.5*o)},[o,m]);return(0,d.useEffect)(function(){if(!a&&u)return window.addEventListener("focus",v),window.addEventListener("blur",g),function(){window.removeEventListener("focus",v),window.removeEventListener("blur",g)}},[a,v,u]),(0,d.createElement)("div",Object.assign({ref:t},p,{className:v$("notistack-Snackbar",r),onMouseEnter:function(e){p.onMouseEnter&&p.onMouseEnter(e),g()},onMouseLeave:function(e){p.onMouseLeave&&p.onMouseLeave(e),v()}}),n)});yR.displayName="Snackbar";var yN=yS({root:((o={display:"flex",flexWrap:"wrap",flexGrow:1})[v9]={flexGrow:"initial",minWidth:"288px"},o)}),yA=(0,d.forwardRef)(function(e,t){var n=e.className,r=v5(e,["className"]);return p().createElement("div",Object.assign({ref:t,className:v$(yN.root,n)},r))});yA.displayName="SnackbarContent";var yF=yS({root:{backgroundColor:"#313131",fontSize:"0.875rem",lineHeight:1.43,letterSpacing:"0.01071em",color:"#fff",alignItems:"center",padding:"6px 16px",borderRadius:"4px",boxShadow:"0px 3px 5px -1px rgba(0,0,0,0.2),0px 6px 10px 0px rgba(0,0,0,0.14),0px 1px 18px 0px rgba(0,0,0,0.12)"},lessPadding:{paddingLeft:"20px"},default:{backgroundColor:"#313131"},success:{backgroundColor:"#43a047"},error:{backgroundColor:"#d32f2f"},warning:{backgroundColor:"#ff9800"},info:{backgroundColor:"#2196f3"},message:{display:"flex",alignItems:"center",padding:"8px 0"},action:{display:"flex",alignItems:"center",marginLeft:"auto",paddingLeft:"16px",marginRight:"-8px"}}),yI="notistack-snackbar",y_=(0,d.forwardRef)(function(e,t){var n=e.id,r=e.message,o=e.action,i=e.iconVariant,a=e.variant,s=e.hideIconVariant,l=e.style,u=e.className,c=i[a],d=o;return"function"==typeof d&&(d=d(n)),p().createElement(yA,{ref:t,role:"alert","aria-describedby":yI,style:l,className:v$("notistack-MuiContent","notistack-MuiContent-"+a,yF.root,yF[a],u,!s&&c&&yF.lessPadding)},p().createElement("div",{id:yI,className:yF.message},s?null:c,r),d&&p().createElement("div",{className:yF.action},d))});y_.displayName="MaterialDesignContent";var yL=(0,d.memo)(y_),yV=yS({wrappedRoot:{width:"100%",position:"relative",transform:"translateX(0)",top:0,right:0,bottom:0,left:0,minWidth:"288px"}}),y$=function(e){var t,n=(0,d.useRef)(),r=(0,d.useState)(!0),o=r[0],i=r[1],a=yZ([e.snack.onClose,e.onClose]),s=(0,d.useCallback)(function(){n.current=setTimeout(function(){i(function(e){return!e})},125)},[]);(0,d.useEffect)(function(){return function(){n.current&&clearTimeout(n.current)}},[]);var l=e.snack,u=e.classes,c=e.Component,f=(0,d.useMemo)(function(){return yT(u)},[u]),h=l.open,m=l.SnackbarProps,g=l.TransitionComponent,v=l.TransitionProps,y=l.transitionDuration,b=l.disableWindowBlurListener,x=l.content,w=v5(l,["open","SnackbarProps","TransitionComponent","TransitionProps","transitionDuration","disableWindowBlurListener","content","entered","requestClose","onEnter","onEntered","onExit","onExited"]),C=v1({direction:"center"!==(t=w.anchorOrigin).horizontal?yD[t.horizontal]:yD[t.vertical],timeout:y},v),S=x;"function"==typeof S&&(S=S(w.id,w.message));var M=["onEnter","onEntered","onExit","onExited"].reduce(function(t,n){var r;return v1({},t,((r={})[n]=yZ([e.snack[n],e[n]],w.id),r))},{});return p().createElement(yE,{in:o,onExited:M.onExited},p().createElement(yR,{open:h,id:w.id,disableWindowBlurListener:b,autoHideDuration:w.autoHideDuration,className:v$(yV.wrappedRoot,f.root,f["anchorOrigin"+ye(w.anchorOrigin)]),SnackbarProps:m,onClose:a},p().createElement(g,Object.assign({},C,{appear:!0,in:h,onExit:M.onExit,onExited:s,onEnter:M.onEnter,onEntered:yZ([M.onEntered,function(){e.snack.requestClose&&a(null,"instructed",e.snack.id)}],w.id)}),S||p().createElement(void 0===c?yL:c,Object.assign({},w)))))},yB=20,yz=6,yH=2,yW="."+yM,yG=yS({root:((i={boxSizing:"border-box",display:"flex",maxHeight:"100%",position:"fixed",zIndex:1400,height:"auto",width:"auto",transition:ym(["top","right","bottom","left","max-width"],{duration:300,easing:"ease"}),pointerEvents:"none"})[yW]={padding:yz+"px 0px",transition:"padding 300ms ease 0ms"},i.maxWidth="calc(100% - "+2*yB+"px)",i[v8]={width:"100%",maxWidth:"calc(100% - 32px)"},i),rootDense:((a={})[yW]={padding:yH+"px 0px"},a),top:{top:yB-yz+"px",flexDirection:"column"},bottom:{bottom:yB-yz+"px",flexDirection:"column-reverse"},left:((s={left:yB+"px"})[v9]={alignItems:"flex-start"},s[v8]={left:"16px"},s),right:((l={right:yB+"px"})[v9]={alignItems:"flex-end"},l[v8]={right:"16px"},l),center:((u={left:"50%",transform:"translateX(-50%)"})[v9]={alignItems:"center"},u)}),yU=(0,d.memo)(function(e){var t=e.classes,n=void 0===t?{}:t,r=e.anchorOrigin,o=e.dense,i=e.children,a=v$("notistack-SnackbarContainer",yG[r.vertical],yG[r.horizontal],yG.root,n.containerRoot,n["containerAnchorOrigin"+ye(r)],o&&yG.rootDense);return p().createElement("div",{className:a},i)}),yq=function(e){return!("string"==typeof e||(0,d.isValidElement)(e))},yY=function(e){function t(t){var n;return(n=e.call(this,t)||this).enqueueSnackbar=function(e,t){if(void 0===t&&(t={}),null==e)throw Error("enqueueSnackbar called with invalid argument");var r,o=yq(e)?e:t,i=yq(e)?e.message:e,a=o.key,s=o.preventDuplicate,l=v5(o,["key","preventDuplicate"]),u=yt(a),c=u?a:new Date().getTime()+Math.random(),d=(r=n.props,function(e,t){return(void 0===t&&(t=!1),t)?v1({},yx[e],{},r[e],{},l[e]):"autoHideDuration"===e?yw(l.autoHideDuration,r.autoHideDuration):"transitionDuration"===e?yC(l.transitionDuration,r.transitionDuration):l[e]||r[e]||yx[e]}),p=v1({id:c},l,{message:i,open:!0,entered:!1,requestClose:!1,persist:d("persist"),action:d("action"),content:d("content"),variant:d("variant"),anchorOrigin:d("anchorOrigin"),disableWindowBlurListener:d("disableWindowBlurListener"),autoHideDuration:d("autoHideDuration"),hideIconVariant:d("hideIconVariant"),TransitionComponent:d("TransitionComponent"),transitionDuration:d("transitionDuration"),TransitionProps:d("TransitionProps",!0),iconVariant:d("iconVariant",!0),style:d("style",!0),SnackbarProps:d("SnackbarProps",!0),className:v$(n.props.className,l.className)});return p.persist&&(p.autoHideDuration=void 0),n.setState(function(e){if(void 0===s&&n.props.preventDuplicate||s){var t=function(e){return u?e.id===c:e.message===i},r=e.queue.findIndex(t)>-1,o=e.snacks.findIndex(t)>-1;if(r||o)return e}return n.handleDisplaySnack(v1({},e,{queue:[].concat(e.queue,[p])}))}),c},n.handleDisplaySnack=function(e){return e.snacks.length>=n.maxSnack?n.handleDismissOldest(e):n.processQueue(e)},n.processQueue=function(e){var t=e.queue,n=e.snacks;return t.length>0?v1({},e,{snacks:[].concat(n,[t[0]]),queue:t.slice(1,t.length)}):e},n.handleDismissOldest=function(e){if(e.snacks.some(function(e){return!e.open||e.requestClose}))return e;var t=!1,r=!1;e.snacks.reduce(function(e,t){return e+(t.open&&t.persist?1:0)},0)===n.maxSnack&&(r=!0);var o=e.snacks.map(function(e){return t||e.persist&&!r?v1({},e):(t=!0,e.entered)?(e.onClose&&e.onClose(null,"maxsnack",e.id),n.props.onClose&&n.props.onClose(null,"maxsnack",e.id),v1({},e,{open:!1})):v1({},e,{requestClose:!0})});return v1({},e,{snacks:o})},n.handleEnteredSnack=function(e,t,r){if(!yt(r))throw Error("handleEnteredSnack Cannot be called with undefined key");n.setState(function(e){return{snacks:e.snacks.map(function(e){return e.id===r?v1({},e,{entered:!0}):v1({},e)})}})},n.handleCloseSnack=function(e,t,r){n.props.onClose&&n.props.onClose(e,t,r);var o=void 0===r;n.setState(function(e){var t=e.snacks,n=e.queue;return{snacks:t.map(function(e){return o||e.id===r?e.entered?v1({},e,{open:!1}):v1({},e,{requestClose:!0}):v1({},e)}),queue:n.filter(function(e){return e.id!==r})}})},n.closeSnackbar=function(e){var t=n.state.snacks.find(function(t){return t.id===e});yt(e)&&t&&t.onClose&&t.onClose(null,"instructed",e),n.handleCloseSnack(null,"instructed",e)},n.handleExitedSnack=function(e,t){if(!yt(t))throw Error("handleExitedSnack Cannot be called with undefined key");n.setState(function(e){var r=n.processQueue(v1({},e,{snacks:e.snacks.filter(function(e){return e.id!==t})}));return 0===r.queue.length?r:n.handleDismissOldest(r)})},n.enqueueSnackbar,n.closeSnackbar,n.state={snacks:[],queue:[],contextValue:{enqueueSnackbar:n.enqueueSnackbar.bind(v3(n)),closeSnackbar:n.closeSnackbar.bind(v3(n))}},n}return v2(t,e),t.prototype.render=function(){var e=this,t=this.state.contextValue,n=this.props,r=n.domRoot,o=n.children,i=n.dense,a=void 0!==i&&i,s=n.Components,l=void 0===s?{}:s,u=n.classes,c=this.state.snacks.reduce(function(e,t){var n,r=ye(t.anchorOrigin),o=e[r]||[];return v1({},e,((n={})[r]=[].concat(o,[t]),n))},{}),d=Object.keys(c).map(function(t){var n=c[t],r=n[0];return p().createElement(yU,{key:t,dense:a,anchorOrigin:r.anchorOrigin,classes:u},n.map(function(t){return p().createElement(y$,{key:t.id,snack:t,classes:u,Component:l[t.variant],onClose:e.handleCloseSnack,onEnter:e.props.onEnter,onExit:e.props.onExit,onExited:yZ([e.handleExitedSnack,e.props.onExited],t.id),onEntered:yZ([e.handleEnteredSnack,e.props.onEntered],t.id)})}))});return p().createElement(v6.Provider,{value:t},o,r?(0,vV.createPortal)(d,r):d)},v0(t,[{key:"maxSnack",get:function(){return this.props.maxSnack||yx.maxSnack}}]),t}(d.Component);function yX(){let{enqueueSnackbar:e,closeSnackbar:t}=(0,d.useContext)(v6),n=yK(e,"error"),r=yK(e,"info"),o=yK(e,"warning"),i=yK(e,"success"),a=(0,d.useCallback)((e,t)=>n(e instanceof Error?e.message:`An unexpected error occurred: ${e}`,t),[n]);return{enqueueSnackbar:e,closeSnackbar:t,errorSnackbar:n,infoSnackbar:r,warningSnackbar:o,successSnackbar:i,exceptionSnackbar:a}}function yK(e,t){return(0,d.useCallback)((n,r)=>e(n,{...r,variant:t}),[e,t])}function yQ(e,t){let n=e.palette.text?.primary??"#222",r={title:{show:!1},textStyle:{color:n,fontFamily:e.typography.fontFamily,fontSize:12},grid:{top:5,right:20,bottom:0,left:20,containLabel:!0},color:["#56B4E9","#009E73","#0072B2","#CC79A7","#F0E442","#E69F00","#D55E00"],categoryAxis:{show:!0,axisLabel:{show:!0,color:n,margin:15},axisTick:{show:!1,length:6,lineStyle:{color:e.palette.grey[600]}},axisLine:{show:!0,lineStyle:{color:e.palette.grey[600]}},splitLine:{show:!0,lineStyle:{width:.5,color:e.palette.grey[300],opacity:.4}},splitArea:{show:!1,areaStyle:{color:[e.palette.grey[300]]}}},timeAxis:{show:!0,axisLabel:{show:!0,color:n,margin:15},axisTick:{show:!1,length:6,lineStyle:{color:e.palette.grey[600]}},axisLine:{show:!0,lineStyle:{color:e.palette.grey[600]}},splitLine:{show:!0,lineStyle:{width:.5,color:e.palette.grey[300],opacity:.4}},splitArea:{show:!1,areaStyle:{color:[e.palette.grey[300]]}}},valueAxis:{show:!0,axisLabel:{color:n,margin:12},axisLine:{show:!1},splitLine:{show:!0,lineStyle:{width:.5,color:e.palette.grey[300],opacity:.6}}},legend:{orient:"horizontal",textStyle:{color:n},pageTextStyle:{color:e.palette.grey[600]},pageIconColor:e?.palette?.action?.active,pageIconInactiveColor:e?.palette?.action?.disabled},toolbox:{show:!0,top:10,right:10,iconStyle:{borderColor:n}},tooltip:{backgroundColor:e.palette.designSystem?.grey[800],borderColor:e.palette.designSystem?.grey[800],textStyle:{color:"#fff",fontSize:11}},axisPointer:{lineStyle:{color:e.palette.grey[500]}},markLine:{symbol:"none",symbolSize:0,itemStyle:{color:e.palette.grey[500]},lineStyle:{type:"dashed",width:1}},line:{showSymbol:!1,symbol:"circle",symbolSize:4,smooth:!1,lineStyle:{width:1},emphasis:{lineStyle:{width:1.5}}},bar:{barMaxWidth:150,itemStyle:{borderWidth:0,borderRadius:0,borderColor:e.palette.grey[300]},label:{show:!1,color:n}},gauge:{detail:{fontSize:18,fontWeight:600,valueAnimation:!1},splitLine:{distance:0,length:4,lineStyle:{width:1}},splitNumber:12}};return e5()({echartsTheme:r,noDataOption:{title:{show:!0,textStyle:{color:n,fontSize:16,fontWeight:400},text:"No data",left:"center",top:"center"},xAxis:{show:!1},yAxis:{show:!1}},sparkline:{width:2,color:"#1976d2"},container:{padding:{default:parseInt(e.spacing(1.5),10)}},thresholds:{defaultColor:e.palette.success.main,palette:["#FFCC00",e.palette.warning.main,e.palette.error.main]}},t)}function yJ(e){return{value:{pastDuration:e},display:`Last ${(0,iD.formatDuration)((0,cA.Ib)(e),{delimiter:", "})}`}}var y0=n(28730);let y1=yQ((0,y0.Z)({}),{echartsTheme:{textStyle:{fontFamily:"Lato"},categoryAxis:{splitLine:{show:!1}},timeAxis:{splitLine:{show:!1}},bar:{barCategoryGap:2}}}),y2={chartsTheme:y1,enablePinning:!1,lastTooltipPinnedCoords:null,setLastTooltipPinnedCoords:()=>null};var y5=n(79602);let y3={defaultProps:{variant:"standard",severity:"success"},styleOverrides:{standardError:({theme:e})=>"dark"===e.palette.mode?{...e.typography.body1,backgroundColor:e.palette.error.dark,color:e.palette.error.light,[`& .${y5.Z.icon}`]:{color:e.palette.error.main}}:{...e.typography.body1,backgroundColor:e.palette.error.light,color:e.palette.error.dark,[`& .${y5.Z.icon}`]:{color:e.palette.error.main}},standardInfo:({theme:e})=>"dark"===e.palette.mode?{...e.typography.body1,backgroundColor:e.palette.info.dark,color:e.palette.info.light,[`& .${y5.Z.icon}`]:{color:e.palette.info.main}}:{...e.typography.body1,backgroundColor:e.palette.info.light,color:e.palette.info.dark,[`& .${y5.Z.icon}`]:{color:e.palette.info.main}},standardSuccess:({theme:e})=>"dark"===e.palette.mode?{...e.typography.body1,backgroundColor:e.palette.success.dark,color:e.palette.success.light,[`& .${y5.Z.icon}`]:{color:e.palette.success.main}}:{...e.typography.body1,backgroundColor:e.palette.success.light,color:e.palette.success.dark,[`& .${y5.Z.icon}`]:{color:e.palette.success.main}},standardWarning:({theme:e})=>"dark"===e.palette.mode?{...e.typography.body1,backgroundColor:e.palette.warning.dark,color:e.palette.warning.light,[`& .${y5.Z.icon}`]:{color:e.palette.warning.main}}:{...e.typography.body1,backgroundColor:e.palette.warning.light,color:e.palette.warning.dark,[`& .${y5.Z.icon}`]:{color:e.palette.warning.main}},root:{["& ."+n(757).Z.root]:{textDecoration:"underline"}}}},y4={50:"#F0F1F6",100:"#E1E3ED",150:"#D2D5E4",200:"#C3C7DB",300:"#A4ACC8",400:"#8690B6",500:"#717CA4",600:"#535D83",700:"#3E4662",800:"#2A2E42",850:"#1F2331",900:"#151721",950:"#0A0C10"},y6={50:"#E7F1FC",100:"#D0E3FA",150:"#B8D5F7",200:"#A1C7F5",300:"#72ABF0",400:"#438FEB",500:"#1473E6",600:"#105CB8",700:"#0C458A",800:"#082E5C",850:"#062345",900:"#04172E",950:"#020C17"},y8="#FFFFFF",y9=e=>{let t=y4["800"],n=y4["300"];return"light"===e?{navigation:t,accent:n,primary:y4["800"],secondary:y4["700"],disabled:y4["300"],link:y6["500"],linkHover:y6["600"]}:{navigation:t,accent:n,primary:y8,secondary:y4["50"],disabled:y4["600"],link:y6["400"],linkHover:y6["500"]}},y7=e=>{let t=y6["150"],n="rgba(21, 23, 33, 0.75)";return"light"===e?{navigation:t,overlay:n,default:y8,paper:y4["50"],code:y4["50"],tooltip:y4["100"],lighter:y4["50"],border:y4["100"]}:{navigation:t,overlay:n,default:y4["900"],paper:y4["850"],code:y4["800"],tooltip:y4["600"],lighter:y4["700"],border:y4["600"]}},be=e=>"light"===e?{50:y4["50"],100:y4["100"],200:y4["200"],300:y4["300"],400:y4["400"],500:y4["500"],600:y4["600"],700:y4["700"],800:y4["800"],900:y4["900"],950:y4["950"]}:{50:y4["950"],100:y4["900"],200:y4["800"],300:y4["700"],400:y4["600"],500:y4["500"],600:y4["400"],700:y4["300"],800:y4["200"],900:y4["100"],950:y4["50"]},bt=e=>"light"===e?{main:y6["500"],dark:y6["600"],light:y6["50"]}:{main:y6["400"],dark:y6["800"],light:y6["200"]},bn=e=>"light"===e?{main:y4["600"],dark:y4["900"],light:y4["100"]}:{main:y8,dark:y8,light:y8},br={50:"#EAF9F1",100:"#D5F2E3",150:"#C1ECD4",200:"#ACE5C6",300:"#82D9AA",400:"#59CC8D",500:"#2FBF71",600:"#26995A",700:"#1C7344",800:"#134C2D",850:"#0E3922",900:"#092617",950:"#05130B"},bo={50:"#FFF5E8",100:"#FFECD2",150:"#FFE2BB",200:"#FFD9A4",300:"#FFC577",400:"#FFB249",500:"#FF9F1C",600:"#CC7F16",700:"#995F11",800:"#66400B",850:"#4D3008",900:"#332006",950:"#1A1003"},bi={50:"#EFE9FD",100:"#E0D2FC",150:"#D0BCFA",200:"#C1A6F8",300:"#A179F5",400:"#824DF1",500:"#6320EE",600:"#4F1ABE",700:"#3B138F",800:"#280D5F",850:"#1E0A47",900:"#140630",950:"#0A0318"},ba={50:"#FDEDED",100:"#FBDADA",150:"#F9C8C8",200:"#F7B5B5",300:"#F29191",400:"#EE6C6C",500:"#EA4747",600:"#BD3939",700:"#902B2B",800:"#621D1D",850:"#4C1616",900:"#350F0F",950:"#1F0808"},bs=e=>"light"===e?{main:ba["500"],dark:ba["600"],light:ba["50"]}:{main:ba["400"],dark:ba["800"],light:ba["300"]},bl=e=>"light"===e?{main:br["500"],dark:br["700"],light:br["50"]}:{main:br["400"],dark:br["800"],light:br["300"]},bu=e=>"light"===e?{main:bo["500"],dark:bo["700"],light:bo["50"]}:{main:bo["400"],dark:bo["800"],light:bo["300"]},bc={fontFamily:'"Lato", sans-serif',fontWeightLight:300,fontWeightRegular:400,fontWeightMedium:700,fontWeightBold:900,h1:{fontSize:"1.5rem",fontWeight:700,lineHeight:"32px"},h2:{fontSize:"1.25rem",fontWeight:700,lineHeight:"28px"},h3:{fontSize:"1rem",fontWeight:700,lineHeight:"24px"},h4:{fontSize:"0.875rem",fontWeight:700,lineHeight:"22px"},h5:void 0,h6:void 0,body1:{fontSize:"0.875rem",fontWeight:400,lineHeight:"20px"},body2:{fontSize:"0.75rem",fontWeight:400,lineHeight:"18px"},subtitle1:{fontSize:"1rem",fontWeight:400,lineHeight:"24px",letterSpacing:"0.02rem"},subtitle2:{fontSize:"0.875rem",fontWeight:700,lineHeight:"22px",letterSpacing:"0.03rem",textTransform:"uppercase"},button:{fontSize:"0.875rem",fontWeight:700,lineHeight:"1.25rem",textTransform:"none",letterSpacing:"0.03rem"},caption:{fontSize:"0.6875rem",fontWeight:400,lineHeight:"16px"}},bd=({theme:e})=>({..."light"===e.palette.mode?{}:{backgroundImage:"unset",backgroundColor:e.palette.designSystem.grey[800]}});function bp(e,t={}){return(0,y0.Z)({palette:{mode:e,primary:bt(e),secondary:bn(e),grey:be(e),background:y7(e),text:y9(e),error:bs(e),warning:bu(e),info:bt(e),success:bl(e),common:{white:y8,black:"#000000"},designSystem:{blue:y6,green:br,grey:y4,orange:bo,purple:bi,red:ba}},typography:bc,mixins:{},components:bf,...t})}let bf={MuiAlert:y3,MuiFormControl:{defaultProps:{size:"small"}},MuiPaper:{styleOverrides:{root:({theme:e})=>({backgroundColor:e.palette.background.default})}},MuiTextField:{defaultProps:{size:"small"}},MuiDrawer:{styleOverrides:{paper:bd}},MuiDialog:{styleOverrides:{paper:bd}},MuiPopover:{styleOverrides:{paper:bd}}};var bh=n(84974),bm=n(12449),bg=n(28418),bv=n(57689);let by={JoinByColumnValue:"Join by column value",MergeColumns:"Merge columns",MergeIndexedColumns:"Merge indexed columns",MergeSeries:"Merge series"};function bb({value:e,onChange:t}){return(0,c.jsxs)(e8.Z,{direction:"row",children:[(0,c.jsx)(rH.Z,{freeSolo:!0,multiple:!0,id:"join-columns",sx:{width:"100%"},options:[],value:e.spec.columns??[],renderInput:e=>(0,c.jsx)(e7.Z,{...e,variant:"outlined",label:"Columns",required:!0}),onChange:(n,r)=>{t({...e,spec:{...e.spec,columns:r}})}}),(0,c.jsx)(aE.Z,{label:"Enabled",labelPlacement:"start",control:(0,c.jsx)(i9.Z,{value:!e.spec.disabled,checked:!e.spec.disabled,onChange:n=>t({...e,spec:{...e.spec,disabled:!n.target.checked}})})})]})}function bx({value:e,onChange:t}){return(0,c.jsxs)(e8.Z,{direction:"row",gap:1,alignItems:"center",children:[(0,c.jsx)(rH.Z,{freeSolo:!0,multiple:!0,id:"merge-columns-columns",sx:{width:"100%"},options:[],value:e.spec.columns??[],renderInput:e=>(0,c.jsx)(e7.Z,{...e,variant:"outlined",label:"Columns",required:!0}),onChange:(n,r)=>{t({...e,spec:{...e.spec,columns:r}})}}),(0,c.jsx)(rM,{id:"merge-columns-name",variant:"outlined",label:"Output Name",value:e.spec.name??"",sx:{width:"100%"},onChange:n=>{t({...e,spec:{...e.spec,name:n}})},required:!0}),(0,c.jsx)(aE.Z,{label:"Enabled",labelPlacement:"start",control:(0,c.jsx)(i9.Z,{value:!e.spec.disabled,checked:!e.spec.disabled,onChange:n=>t({...e,spec:{...e.spec,disabled:!n.target.checked}})})})]})}function bw({value:e,onChange:t}){return(0,c.jsxs)(e8.Z,{direction:"row",children:[(0,c.jsx)(rM,{id:"merge-indexed-columns",variant:"outlined",label:"Column",placeholder:"Example: 'value' for merging 'value #1', 'value #2' and 'value #...'",value:e.spec.column??"",sx:{width:"100%"},onChange:n=>{t({...e,spec:{...e.spec,column:n}})},required:!0}),(0,c.jsx)(aE.Z,{label:"Enabled",labelPlacement:"start",control:(0,c.jsx)(i9.Z,{value:!e.spec.disabled,checked:!e.spec.disabled,onChange:n=>t({...e,spec:{...e.spec,disabled:!n.target.checked}})})})]})}function bC({value:e,onChange:t}){return(0,c.jsx)(e8.Z,{direction:"row",children:(0,c.jsx)(aE.Z,{label:"Enabled",labelPlacement:"start",control:(0,c.jsx)(i9.Z,{value:!e.spec.disabled,checked:!e.spec.disabled,onChange:n=>t({...e,spec:{...e.spec,disabled:!n.target.checked}})})})})}function bS({value:e,onChange:t,...n}){return(0,c.jsxs)(e8.Z,{gap:2,sx:{width:"100%"},mt:1,...n,children:[(0,c.jsxs)(rM,{select:!0,label:"Kind",value:e.kind,onChange:n=>t({...e,kind:n}),children:[(0,c.jsx)(oI.Z,{value:"JoinByColumnValue",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Join by column value"}),(0,c.jsx)(nQ.Z,{variant:"caption",children:"Regroup rows with equal cell value in a column"})]})}),(0,c.jsx)(oI.Z,{value:"MergeColumns",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Merge columns"}),(0,c.jsx)(nQ.Z,{variant:"caption",children:"Multiple columns are merged to one column"})]})}),(0,c.jsx)(oI.Z,{value:"MergeIndexedColumns",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Merge indexed columns"}),(0,c.jsx)(nQ.Z,{variant:"caption",children:"Indexed columns are merged to one column"})]})}),(0,c.jsx)(oI.Z,{value:"MergeSeries",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Merge series"}),(0,c.jsx)(nQ.Z,{variant:"caption",children:"Series will be merged by their labels"})]})})]}),"JoinByColumnValue"===e.kind&&(0,c.jsx)(bb,{value:e,onChange:t}),"MergeColumns"===e.kind&&(0,c.jsx)(bx,{value:e,onChange:t}),"MergeIndexedColumns"===e.kind&&(0,c.jsx)(bw,{value:e,onChange:t}),"MergeSeries"===e.kind&&(0,c.jsx)(bC,{value:e,onChange:t})]})}function bM({index:e,value:t,isCollapsed:n,onChange:r,onCollapse:o,onDelete:i,...a}){return(0,c.jsxs)(e8.Z,{...a,children:[(0,c.jsxs)(e8.Z,{direction:"row",alignItems:"center",borderBottom:1,borderColor:e=>e.palette.divider,justifyContent:"space-between",gap:4,children:[(0,c.jsxs)(e8.Z,{direction:"row",gap:1,children:[(0,c.jsx)(e9.Z,{"data-testid":`transform-toggle#${e}`,size:"small",onClick:()=>o(!n),children:n?(0,c.jsx)(bh.default,{}):(0,c.jsx)(bm.default,{})}),(0,c.jsx)(nQ.Z,{variant:"overline",component:"h4",sx:{textTransform:"none"},children:t.kind?(0,c.jsx)("span",{children:(0,c.jsx)("strong",{children:by[t.kind]})}):(0,c.jsx)("strong",{children:"Select a transformation kind"})})]}),(0,c.jsxs)(e8.Z,{direction:"row",gap:1,children:[n&&(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(r_.Z,{title:t.spec?.disabled?"Enable transformation":"Disable transformation",placement:"top",children:(0,c.jsx)(e9.Z,{size:"small",sx:{marginLeft:"auto"},onClick:function(){r({...t,spec:{...t.spec,disabled:!t.spec?.disabled}})},children:t.spec?.disabled?(0,c.jsx)(bg.default,{}):(0,c.jsx)(bv.default,{})})}),(0,c.jsx)(ii.Z,{flexItem:!0,orientation:"vertical",variant:"middle"})]}),(0,c.jsx)(r_.Z,{title:"Remove transformation",placement:"top",children:(0,c.jsx)(e9.Z,{size:"small",sx:{marginLeft:"auto"},onClick:i,children:(0,c.jsx)(se.default,{})})})]})]}),!n&&(0,c.jsx)(bS,{value:t,onChange:r})]})}function bk({value:e,onChange:t,...n}){let[r,o]=(0,d.useState)(e.map(()=>!0));return(0,c.jsxs)(e8.Z,{gap:1,...n,children:[e.map((n,i)=>(0,c.jsx)(bM,{index:i,value:n,isCollapsed:r[i]??!0,onChange:n=>(function(n,r){let o=[...e];o[n]=r,t(o)})(i,n),onDelete:()=>(function(n){let r=[...e];r.splice(n,1),t(r),o(e=>(e.splice(n,1),[...e]))})(i),onCollapse:e=>{o(t=>(t[i]=e,[...t]))}},i)),(0,c.jsx)(O.Z,{variant:"contained",startIcon:(0,c.jsx)(aT.default,{}),sx:{marginTop:1},onClick:function(){let n=[...e];n.push({kind:"",spec:{}}),t(n),o(e=>(e.push(!1),[...e]))},children:"Add Transformation"})]})}function bE(e){let{value:t,onChange:n,timeOptions:r,height:o}=e,i=(0,d.useMemo)(()=>{if(t&&!r.some(e=>e.value.pastDuration===t))return(0,c.jsx)(oI.Z,{value:t,children:t})},[r,t]);return(0,c.jsx)(rN.Z,{children:(0,c.jsx)(eV.Z,{children:(0,c.jsxs)(cR.Z,{id:"refreshInterval",value:t,onChange:e=>{n(e.target.value)},inputProps:{"aria-label":`Select refresh interval. Currently set to ${t}`},sx:{".MuiSelect-select":o?{lineHeight:o,paddingY:0}:{}},children:[r.map((e,t)=>(0,c.jsx)(oI.Z,{value:e.value.pastDuration,children:e.display},t)),i]})})})}var bD=n(85731);function bT(e){let{width:t,height:n,data:r}=e,o=eH(),i={title:{text:"Referer of a Website",subtext:"Fake Data",left:"center"},tooltip:{trigger:"item",formatter:"{a} <br/>{b} : {c} ({d}%)"},axisLabel:{overflow:"truncate",width:t/3},series:[{name:"Access From",type:"pie",radius:"55%",label:!1,center:["40%","50%"],data:r,emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}}}],itemStyle:{borderRadius:2,color:o.echartsTheme[0]}};return(0,c.jsx)(eV.Z,{style:{width:t,height:n},sx:{overflow:"auto"},children:(0,c.jsx)(e1,{sx:{minHeight:n,height:r?16*r.length:"100%"},option:i,theme:o.echartsTheme})})}(0,eR.D)([bD.N,eA.N,eF.N,eI.N,e_.N,eL.N]);var bP=n(27835),bZ=n(943),bO=n(72116);(0,eR.D)([bP.N,bZ.N,eA.N,eF.N,eI.N,e_.N,eL.N]);let bj=e=>{var t;let{height:n,data:r,xAxisCategories:o,yAxisCategories:i,timeScale:a,colors:s}=e,{timeZone:l}=iA(),u=eH(),d=(0,tW.Z)(),p={tooltip:{appendToBody:!0,formatter:e=>(function({data:e,label:t,marker:n,xAxisCategories:r,yAxisCategories:o,theme:i}){let[a,s]=e,{formattedDate:l,formattedTime:u}=ij(r[a]),c=(0,bO.css)`
|
|
8
|
+
border-bottom: 1px solid ${i.palette.grey[500]};
|
|
9
|
+
padding-bottom: 8px;
|
|
10
|
+
`,d=(0,bO.css)`
|
|
11
|
+
display: flex;
|
|
12
|
+
justify-content: space-between;
|
|
13
|
+
padding-top: 8px;
|
|
14
|
+
`,p=(0,bO.css)`
|
|
15
|
+
margin-right: 16px;
|
|
16
|
+
`;return`
|
|
17
|
+
<div>
|
|
18
|
+
<div style="${c.styles}">${l} ${u}</div>
|
|
19
|
+
<div style="${d.styles}">
|
|
20
|
+
<div style="${p.styles}">
|
|
21
|
+
${n}
|
|
22
|
+
<strong>${o[s]}</strong>
|
|
23
|
+
</div>
|
|
24
|
+
<div>
|
|
25
|
+
${t}
|
|
26
|
+
</div>
|
|
27
|
+
</div>
|
|
28
|
+
</div>
|
|
29
|
+
`})({data:e.data.value,label:e.data.label,marker:e.marker,xAxisCategories:o,yAxisCategories:i,theme:d})},grid:{top:"5%",bottom:"5%"},xAxis:{type:"category",data:o,axisLine:{show:!1},splitArea:{show:!1},axisLabel:{hideOverlap:!0,formatter:(t=a?.rangeMs??0,function(e){let n=new Date(Number(e));return t>15768e7?iP(n,"yyy",l):t>63072e6?iP(n,"MMM yyy",l):t>864e6&&t<1577664e4?iP(n,"dd.MM",l):t>1728e5&&t<=864e6?iP(n,"dd.MM HH:mm",l):iP(n,"HH:mm",l)})}},yAxis:{type:"category",data:i,axisLine:{show:!1},splitArea:{show:!1,interval:0},splitLine:{show:!1},axisLabel:{interval:0}},visualMap:{show:!1,type:"piecewise",pieces:s},series:[{name:"Status history",type:"heatmap",coordinateSystem:"cartesian2d",data:r,label:{show:!1},itemStyle:{borderWidth:1,borderType:"solid",borderColor:"#ffffff"},emphasis:{itemStyle:{opacity:.5}}}]};return(0,c.jsx)(eV.Z,{style:{height:n},sx:{overflow:"auto"},children:(0,c.jsx)(e1,{sx:{width:"100%",height:n},option:p,theme:u.echartsTheme})})},bR="#1f77b4";function bN(e,t){t.match(/^#[0-9A-Fa-f]{6}$/)||(t=bR);try{let[n,r,o]=bF(t);if(isNaN(n)||isNaN(r)||isNaN(o))throw Error("Invalid HSL values");let i=String(e).split("").reduce((e,t)=>e+t.charCodeAt(0),0),a=Math.min(r+10,90),s=bI(Math.abs((n+i%6*60)%360),Math.min(Math.max(a,50),90),Math.min(Math.max(o+(i%2?15:-15),30),70));if(!s.match(/^#[0-9A-Fa-f]{6}$/))throw Error("Invalid generated color");return s}catch(e){return bR}}function bA(e,t){return t.length>=e.length?t.slice(0,e.length):e.map((e,n)=>n<t.length?t[n]||bR:bN(e,t[0]||bR))}function bF(e){let t=parseInt(e.slice(1,3),16)/255,n=parseInt(e.slice(3,5),16)/255,r=parseInt(e.slice(5,7),16)/255,o=Math.max(t,n,r),i=Math.min(t,n,r),a=0,s=0,l=(o+i)/2;if(o!==i){let e=o-i;switch(s=l>.5?e/(2-o-i):e/(o+i),o){case t:a=(n-r)/e+6*(n<r);break;case n:a=(r-t)/e+2;break;case r:a=(t-n)/e+4}a/=6}return[360*a,100*s,100*l]}function bI(e,t,n){let r=t*Math.min(n/=100,1-n)/100,o=t=>{let o=(t+e/30)%12;return Math.round(255*(n-r*Math.max(Math.min(o-3,9-o,1),-1))).toString(16).padStart(2,"0")};return`#${o(0)}${o(8)}${o(4)}`}var b_=n(11104),bL=n(4560),bV=n(38971),b$=n(93772),bB=n(6798);let bz=(e,t)=>e.filter(e=>t.includes(e)),bH=(e,t,n)=>{let r=e.keys[0];Array.isArray(t)?t.forEach((t,r)=>{n((t,n)=>{r<=e.keys.length-1&&(0===r?Object.assign(t,n):t[e.up(e.keys[r])]=n)},t)}):t&&"object"==typeof t?(Object.keys(t).length>e.keys.length?e.keys:bz(e.keys,Object.keys(t))).forEach(o=>{if(e.keys.includes(o)){let i=t[o];void 0!==i&&n((t,n)=>{r===o?Object.assign(t,n):t[e.up(o)]=n},i)}}):("number"==typeof t||"string"==typeof t)&&n((e,t)=>{Object.assign(e,t)},t)};function bW(e){return`--Grid-${e}Spacing`}function bG(e){return`--Grid-parent-${e}Spacing`}let bU="--Grid-columns",bq="--Grid-parent-columns",bY=({theme:e,ownerState:t})=>{let n={};return bH(e.breakpoints,t.size,(e,t)=>{let r={};"grow"===t&&(r={flexBasis:0,flexGrow:1,maxWidth:"100%"}),"auto"===t&&(r={flexBasis:"auto",flexGrow:0,flexShrink:0,maxWidth:"none",width:"auto"}),"number"==typeof t&&(r={flexGrow:0,flexBasis:"auto",width:`calc(100% * ${t} / var(${bq}) - (var(${bq}) - ${t}) * (var(${bG("column")}) / var(${bq})))`}),e(n,r)}),n},bX=({theme:e,ownerState:t})=>{let n={};return bH(e.breakpoints,t.offset,(e,t)=>{let r={};"auto"===t&&(r={marginLeft:"auto"}),"number"==typeof t&&(r={marginLeft:0===t?"0px":`calc(100% * ${t} / var(${bq}) + var(${bG("column")}) * ${t} / var(${bq}))`}),e(n,r)}),n},bK=({theme:e,ownerState:t})=>{if(!t.container)return{};let n={[bU]:12};return bH(e.breakpoints,t.columns,(e,t)=>{let r=t??12;e(n,{[bU]:r,"> *":{[bq]:r}})}),n},bQ=({theme:e,ownerState:t})=>{if(!t.container)return{};let n={};return bH(e.breakpoints,t.rowSpacing,(t,r)=>{let o="string"==typeof r?r:e.spacing?.(r);t(n,{[bW("row")]:o,"> *":{[bG("row")]:o}})}),n},bJ=({theme:e,ownerState:t})=>{if(!t.container)return{};let n={};return bH(e.breakpoints,t.columnSpacing,(t,r)=>{let o="string"==typeof r?r:e.spacing?.(r);t(n,{[bW("column")]:o,"> *":{[bG("column")]:o}})}),n},b0=({theme:e,ownerState:t})=>{if(!t.container)return{};let n={};return bH(e.breakpoints,t.direction,(e,t)=>{e(n,{flexDirection:t})}),n},b1=({ownerState:e})=>({minWidth:0,boxSizing:"border-box",...e.container&&{display:"flex",flexWrap:"wrap",...e.wrap&&"wrap"!==e.wrap&&{flexWrap:e.wrap},gap:`var(${bW("row")}) var(${bW("column")})`}}),b2=e=>{let t=[];return Object.entries(e).forEach(([e,n])=>{!1!==n&&void 0!==n&&t.push(`grid-${e}-${String(n)}`)}),t},b5=(e,t="xs")=>{function n(e){return void 0!==e&&("string"==typeof e&&!Number.isNaN(Number(e))||"number"==typeof e&&e>0)}if(n(e))return[`spacing-${t}-${String(e)}`];if("object"==typeof e&&!Array.isArray(e)){let t=[];return Object.entries(e).forEach(([e,r])=>{n(r)&&t.push(`spacing-${e}-${String(r)}`)}),t}return[]},b3=e=>void 0===e?[]:"object"==typeof e?Object.entries(e).map(([e,t])=>`direction-${e}-${t}`):[`direction-xs-${String(e)}`],b4=(0,bB.Z)(),b6=(0,bL.Z)("div",{name:"MuiGrid",slot:"Root",overridesResolver:(e,t)=>t.root});function b8(e){return(0,cI.Z)({props:e,name:"MuiGrid",defaultTheme:b4})}let b9=function(e={}){let{createStyledComponent:t=b6,useThemeProps:n=b8,useTheme:r=bV.Z,componentName:o="MuiGrid"}=e,i=(e,t)=>{let{container:n,direction:r,spacing:i,wrap:a,size:s}=e,l={root:["root",n&&"container","wrap"!==a&&`wrap-xs-${String(a)}`,...b3(r),...b2(s),...n?b5(i,t.breakpoints.keys[0]):[]]};return(0,h.Z)(l,e=>(0,S.ZP)(o,e),{})};function a(e,t,n=()=>!0){let r={};return null===e||(Array.isArray(e)?e.forEach((e,o)=>{null!==e&&n(e)&&t.keys[o]&&(r[t.keys[o]]=e)}):"object"==typeof e?Object.keys(e).forEach(t=>{let o=e[t];null!=o&&n(o)&&(r[t]=o)}):r[t.keys[0]]=e),r}let s=t(bK,bJ,bQ,bY,b0,b1,bX),l=d.forwardRef(function(e,t){let o=r(),l=n(e),u=(0,b$.Z)(l);!function(e,t){let n=[];void 0!==e.item&&(delete e.item,n.push("item")),void 0!==e.zeroMinWidth&&(delete e.zeroMinWidth,n.push("zeroMinWidth")),t.keys.forEach(t=>{void 0!==e[t]&&(n.push(t),delete e[t])})}(u,o.breakpoints);let{className:p,children:h,columns:m=12,container:g=!1,component:v="div",direction:y="row",wrap:b="wrap",size:x={},offset:w={},spacing:C=0,rowSpacing:S=C,columnSpacing:M=C,unstable_level:k=0,...E}=u,D=a(x,o.breakpoints,e=>!1!==e),T=a(w,o.breakpoints),P=e.columns??(k?void 0:m),Z=e.spacing??(k?void 0:C),O=e.rowSpacing??e.spacing??(k?void 0:S),j=e.columnSpacing??e.spacing??(k?void 0:M),R={...u,level:k,columns:P,container:g,direction:y,wrap:b,spacing:Z,rowSpacing:O,columnSpacing:j,size:D,offset:T},N=i(R,o);return(0,c.jsx)(s,{ref:t,as:v,ownerState:R,className:(0,f.Z)(N.root,p),...E,children:d.Children.map(h,e=>d.isValidElement(e)&&(0,b_.Z)(e,["Grid"])&&g&&e.props.container?d.cloneElement(e,{unstable_level:e.props?.unstable_level??k+1}):e)})});return l.muiName="Grid",l}({createStyledComponent:(0,y.ZP)("div",{name:"MuiGrid2",slot:"Root",overridesResolver:(e,t)=>{let{ownerState:n}=e;return[t.root,n.container&&t.container]}}),componentName:"MuiGrid2",useThemeProps:e=>(0,w.i)({props:e,name:"MuiGrid2"}),useTheme:tW.Z}),b7=({mapping:e,onChange:t,...n})=>{switch(e.kind){case"Value":return(0,c.jsx)(e8.Z,{gap:1,direction:"row",...n,children:(0,c.jsx)(e7.Z,{label:"Value",placeholder:"Exact value",value:e.spec?.value??"",onChange:n=>t({...e,spec:{...e.spec,value:n.target.value}}),fullWidth:!0})});case"Range":return(0,c.jsxs)(e8.Z,{gap:1,direction:"row",...n,children:[(0,c.jsx)(e7.Z,{label:"From",placeholder:"Start of range",value:e.spec?.from??"",onChange:n=>t({...e,spec:{...e.spec,from:""===n.target.value?void 0:+n.target.value}}),fullWidth:!0}),(0,c.jsx)(e7.Z,{label:"To",placeholder:"End of range (inclusive)",value:e.spec?.to??"",onChange:n=>t({...e,spec:{...e.spec,to:""===n.target.value?void 0:+n.target.value}}),fullWidth:!0})]});case"Regex":return(0,c.jsx)(e8.Z,{gap:1,direction:"row",...n,children:(0,c.jsx)(e7.Z,{label:"Regular Expression",placeholder:"JavaScript regular expression",value:e.spec?.pattern??"",onChange:n=>t({...e,spec:{...e.spec,pattern:n.target.value}}),fullWidth:!0})});case"Misc":return(0,c.jsx)(e8.Z,{gap:1,direction:"row",...n,children:(0,c.jsxs)(e7.Z,{select:!0,label:"Value",value:e.spec?.value??"",onChange:n=>t({...e,spec:{value:n.target.value}}),SelectProps:{renderValue:e=>{switch(e){case"empty":return"Empty";case"null":return"Null";case"NaN":return"NaN";case"true":return"True";case"false":return"False";default:return String(e)}}},fullWidth:!0,children:[(0,c.jsx)(oI.Z,{value:"empty",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Empty"}),(0,c.jsx)(nQ.Z,{variant:"caption",children:"Matches empty string"})]})}),(0,c.jsx)(oI.Z,{value:"null",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Null"}),(0,c.jsx)(nQ.Z,{variant:"caption",children:"Matches null or undefined"})]})}),(0,c.jsx)(oI.Z,{value:"NaN",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"NaN"}),(0,c.jsx)(nQ.Z,{variant:"caption",children:"Matches Not a Number value"})]})}),(0,c.jsx)(oI.Z,{value:"true",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"True"}),(0,c.jsx)(nQ.Z,{variant:"caption",children:"Matches true boolean"})]})}),(0,c.jsx)(oI.Z,{value:"false",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"False"}),(0,c.jsx)(nQ.Z,{variant:"caption",children:"Matches false boolean"})]})})]})});default:return null}},xe=({mapping:e,onChange:t,onDelete:n,...r})=>{let o=n=>{t({...e,spec:{...e.spec,result:{...e.spec.result,color:n}}})};return(0,c.jsxs)(b9,{container:!0,spacing:2,...r,children:[(0,c.jsx)(b9,{size:{xs:5},children:(0,c.jsxs)(e8.Z,{direction:"row",gap:1,width:"100%",children:[(0,c.jsxs)(e7.Z,{select:!0,label:"Type",value:e.kind,onChange:n=>t({...e,kind:n.target.value}),required:!0,sx:{width:"120px"},children:[(0,c.jsx)(oI.Z,{value:"Value",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Value"}),"Value"!==e.kind&&(0,c.jsx)(nQ.Z,{variant:"caption",children:"Matches an exact text value"})]})}),(0,c.jsx)(oI.Z,{value:"Range",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Range"}),"Range"!==e.kind&&(0,c.jsx)(nQ.Z,{variant:"caption",children:"Matches against a numerical range"})]})}),(0,c.jsx)(oI.Z,{value:"Regex",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Regex"}),"Regex"!==e.kind&&(0,c.jsx)(nQ.Z,{variant:"caption",children:"Matches against a regular expression"})]})}),(0,c.jsx)(oI.Z,{value:"Misc",children:(0,c.jsxs)(e8.Z,{children:[(0,c.jsx)(nQ.Z,{children:"Misc"}),"Misc"!==e.kind&&(0,c.jsx)(nQ.Z,{variant:"caption",children:"Matches against empty, null and NaN values"})]})})]}),(0,c.jsx)(b7,{width:"100%",mapping:e,onChange:n=>t({...e,...n})})]})}),(0,c.jsx)(b9,{size:{xs:4},children:(0,c.jsx)(e7.Z,{label:"Display text",value:e.spec?.result?.value??"",onChange:n=>t({...e,spec:{...e.spec,result:{...e.spec?.result,value:n.target.value}}}),fullWidth:!0})}),(0,c.jsx)(b9,{size:{xs:1},children:(0,c.jsx)(e8.Z,{direction:"row",justifyContent:"center",gap:1,children:e.spec?.result?.color?(0,c.jsx)(tz,{label:"Color",color:e.spec.result.color??"#000",onColorChange:o,onClear:()=>o(void 0)}):(0,c.jsx)(e9.Z,{onClick:()=>o("#000"),children:(0,c.jsx)(aT.default,{})})})}),(0,c.jsx)(b9,{size:{xs:1},textAlign:"end",children:(0,c.jsx)(r_.Z,{title:"Remove mapping settings",placement:"top",children:(0,c.jsx)(e9.Z,{size:"small",sx:{marginLeft:"auto"},onClick:n,children:(0,c.jsx)(se.default,{})})})})]})},xt=({mappings:e,onChange:t})=>{let[n,r]=(0,d.useState)(e);return(0,c.jsxs)(e8.Z,{spacing:1,children:[(0,c.jsxs)(b9,{container:!0,spacing:2,children:[(0,c.jsx)(b9,{size:{xs:5},children:(0,c.jsx)(nQ.Z,{variant:"subtitle1",children:"Condition"})}),(0,c.jsx)(b9,{size:{xs:4},children:(0,c.jsx)(nQ.Z,{variant:"subtitle1",children:"Display Text"})}),(0,c.jsx)(b9,{size:{xs:1},textAlign:"center",children:(0,c.jsx)(nQ.Z,{variant:"subtitle1",children:"Color"})}),(0,c.jsx)(b9,{size:{xs:1}})]}),(0,c.jsx)(e8.Z,{gap:1.5,divider:(0,c.jsx)(ii.Z,{flexItem:!0,orientation:"horizontal"}),children:n.map((e,o)=>(0,c.jsx)(xe,{mapping:e,onChange:e=>(function(e,o){let i=[...n];i[e]=o,r(i),t(i)})(o,e),onDelete:()=>(function(e){let o=[...n];o.splice(e,1),r(o),t(o)})(o)},o))}),(0,c.jsx)(O.Z,{variant:"contained",startIcon:(0,c.jsx)(aT.default,{}),sx:{marginTop:1},onClick:function(){let e=[...n];e.push({kind:"Value",spec:{result:{value:""}}}),r(e),t(e)},children:"Add value mappings"})]})}},8193:function(e,t,n){"use strict";n.d(t,{BL:()=>l,Jj:()=>c,bk:()=>d,dT:()=>p,kx:()=>s,vo:()=>a,zx:()=>u});let r=["bottom","right"],o=["list","table"],i=["small","medium"];function a(e){return r.includes(e)}function s(e){return o.includes(e)}function l(e){return i.includes(e)}let u={position:"bottom",mode:"list",size:"medium"};function c(e){return void 0===e?u.position:a(e)?e:u.position}function d(e){return e&&s(e)?e:u.mode}function p(e){return e&&l(e)?e:u.size}},49966:function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.bindAll=void 0;var o=n(63778);function i(e){return void 0===e?void 0:"boolean"==typeof e?{capture:e}:e}t.bindAll=function(e,t,n){var a=t.map(function(t){var a=null==n?t:r(r({},t),{options:r(r({},i(n)),i(t.options))});return(0,o.bind)(e,a)});return function(){a.forEach(function(e){return e()})}}},63778:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.bind=void 0,t.bind=function(e,t){var n=t.type,r=t.listener,o=t.options;return e.addEventListener(n,r,o),function(){e.removeEventListener(n,r,o)}}},70501:function(e,t,n){"use strict";t.bindAll=t.bind=void 0;var r=n(63778);Object.defineProperty(t,"bind",{enumerable:!0,get:function(){return r.bind}});var o=n(49966);Object.defineProperty(t,"bindAll",{enumerable:!0,get:function(){return o.bindAll}})},82545:function(e,t,n){var r=n(81822)(n(77400),"DataView");e.exports=r},96586:function(e,t,n){var r=n(57753),o=n(82452),i=n(22115),a=n(38256),s=n(67426);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}l.prototype.clear=r,l.prototype.delete=o,l.prototype.get=i,l.prototype.has=a,l.prototype.set=s,e.exports=l},36301:function(e,t,n){var r=n(63663),o=n(72470),i=n(66165),a=n(71873),s=n(52556);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}l.prototype.clear=r,l.prototype.delete=o,l.prototype.get=i,l.prototype.has=a,l.prototype.set=s,e.exports=l},44538:function(e,t,n){var r=n(81822)(n(77400),"Map");e.exports=r},74554:function(e,t,n){var r=n(39448),o=n(7738),i=n(66575),a=n(7238),s=n(38738);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}l.prototype.clear=r,l.prototype.delete=o,l.prototype.get=i,l.prototype.has=a,l.prototype.set=s,e.exports=l},64825:function(e,t,n){var r=n(81822)(n(77400),"Promise");e.exports=r},46151:function(e,t,n){var r=n(81822)(n(77400),"Set");e.exports=r},52485:function(e,t,n){var r=n(74554),o=n(38639),i=n(88379);function a(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++t<n;)this.add(e[t])}a.prototype.add=a.prototype.push=o,a.prototype.has=i,e.exports=a},23694:function(e,t,n){var r=n(36301),o=n(7354),i=n(5863),a=n(12367),s=n(90748),l=n(97569);function u(e){var t=this.__data__=new r(e);this.size=t.size}u.prototype.clear=o,u.prototype.delete=i,u.prototype.get=a,u.prototype.has=s,u.prototype.set=l,e.exports=u},96539:function(e,t,n){var r=n(77400).Symbol;e.exports=r},59942:function(e,t,n){var r=n(77400).Uint8Array;e.exports=r},66902:function(e,t,n){var r=n(81822)(n(77400),"WeakMap");e.exports=r},79349:function(e){e.exports=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}},10263:function(e){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,o=0,i=[];++n<r;){var a=e[n];t(a,n,e)&&(i[o++]=a)}return i}},98213:function(e,t,n){var r=n(24701),o=n(2900),i=n(19785),a=n(43854),s=n(42383),l=n(48519),u=Object.prototype.hasOwnProperty;e.exports=function(e,t){var n=i(e),c=!n&&o(e),d=!n&&!c&&a(e),p=!n&&!c&&!d&&l(e),f=n||c||d||p,h=f?r(e.length,String):[],m=h.length;for(var g in e)(t||u.call(e,g))&&!(f&&("length"==g||d&&("offset"==g||"parent"==g)||p&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||s(g,m)))&&h.push(g);return h}},97141:function(e){e.exports=function(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}},90756:function(e){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}},73140:function(e,t,n){var r=n(88799),o=n(85638);e.exports=function(e,t,n){(void 0===n||o(e[t],n))&&(void 0!==n||t in e)||r(e,t,n)}},71928:function(e,t,n){var r=n(88799),o=n(85638),i=Object.prototype.hasOwnProperty;e.exports=function(e,t,n){var a=e[t];i.call(e,t)&&o(a,n)&&(void 0!==n||t in e)||r(e,t,n)}},93382:function(e,t,n){var r=n(85638);e.exports=function(e,t){for(var n=e.length;n--;)if(r(e[n][0],t))return n;return -1}},88799:function(e,t,n){var r=n(42630);e.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},80158:function(e,t,n){var r=n(11611),o=Object.create,i=function(){function e(){}return function(t){if(!r(t))return{};if(o)return o(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();e.exports=i},49819:function(e,t,n){var r=n(18911)();e.exports=r},11324:function(e,t,n){var r=n(97141),o=n(19785);e.exports=function(e,t,n){var i=t(e);return o(e)?i:r(i,n(e))}},99736:function(e,t,n){var r=n(96539),o=n(34840),i=n(21258),a=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":a&&a in Object(e)?o(e):i(e)}},55829:function(e,t,n){var r=n(99736),o=n(92360);e.exports=function(e){return o(e)&&"[object Arguments]"==r(e)}},32866:function(e,t,n){var r=n(12772),o=n(92360);e.exports=function e(t,n,i,a,s){return t===n||(null!=t&&null!=n&&(o(t)||o(n))?r(t,n,i,a,e,s):t!=t&&n!=n)}},12772:function(e,t,n){var r=n(23694),o=n(27042),i=n(370),a=n(39584),s=n(3533),l=n(19785),u=n(43854),c=n(48519),d="[object Arguments]",p="[object Array]",f="[object Object]",h=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,m,g,v){var y=l(e),b=l(t),x=y?p:s(e),w=b?p:s(t);x=x==d?f:x,w=w==d?f:w;var C=x==f,S=w==f,M=x==w;if(M&&u(e)){if(!u(t))return!1;y=!0,C=!1}if(M&&!C)return v||(v=new r),y||c(e)?o(e,t,n,m,g,v):i(e,t,x,n,m,g,v);if(!(1&n)){var k=C&&h.call(e,"__wrapped__"),E=S&&h.call(t,"__wrapped__");if(k||E){var D=k?e.value():e,T=E?t.value():t;return v||(v=new r),g(D,T,n,m,v)}}return!!M&&(v||(v=new r),a(e,t,n,m,g,v))}},46729:function(e,t,n){var r=n(28338),o=n(99678),i=n(11611),a=n(76532),s=/^\[object .+?Constructor\]$/,l=Object.prototype,u=Function.prototype.toString,c=l.hasOwnProperty,d=RegExp("^"+u.call(c).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!i(e)||o(e))&&(r(e)?d:s).test(a(e))}},26972:function(e,t,n){var r=n(99736),o=n(84194),i=n(92360),a={};a["[object Float32Array]"]=a["[object Float64Array]"]=a["[object Int8Array]"]=a["[object Int16Array]"]=a["[object Int32Array]"]=a["[object Uint8Array]"]=a["[object Uint8ClampedArray]"]=a["[object Uint16Array]"]=a["[object Uint32Array]"]=!0,a["[object Arguments]"]=a["[object Array]"]=a["[object ArrayBuffer]"]=a["[object Boolean]"]=a["[object DataView]"]=a["[object Date]"]=a["[object Error]"]=a["[object Function]"]=a["[object Map]"]=a["[object Number]"]=a["[object Object]"]=a["[object RegExp]"]=a["[object Set]"]=a["[object String]"]=a["[object WeakMap]"]=!1,e.exports=function(e){return i(e)&&o(e.length)&&!!a[r(e)]}},20186:function(e,t,n){var r=n(56016),o=n(50962),i=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return o(e);var t=[];for(var n in Object(e))i.call(e,n)&&"constructor"!=n&&t.push(n);return t}},59464:function(e,t,n){var r=n(11611),o=n(56016),i=n(21586),a=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return i(e);var t=o(e),n=[];for(var s in e)"constructor"==s&&(t||!a.call(e,s))||n.push(s);return n}},40015:function(e,t,n){var r=n(23694),o=n(73140),i=n(49819),a=n(68867),s=n(11611),l=n(53893),u=n(97494);e.exports=function e(t,n,c,d,p){t!==n&&i(n,function(i,l){if(p||(p=new r),s(i))a(t,n,l,c,e,d,p);else{var f=d?d(u(t,l),i,l+"",t,n,p):void 0;void 0===f&&(f=i),o(t,l,f)}},l)}},68867:function(e,t,n){var r=n(73140),o=n(2734),i=n(63428),a=n(37561),s=n(97635),l=n(2900),u=n(19785),c=n(36468),d=n(43854),p=n(28338),f=n(11611),h=n(40861),m=n(48519),g=n(97494),v=n(89328);e.exports=function(e,t,n,y,b,x,w){var C=g(e,n),S=g(t,n),M=w.get(S);if(M){r(e,n,M);return}var k=x?x(C,S,n+"",e,t,w):void 0,E=void 0===k;if(E){var D=u(S),T=!D&&d(S),P=!D&&!T&&m(S);k=S,D||T||P?u(C)?k=C:c(C)?k=a(C):T?(E=!1,k=o(S,!0)):P?(E=!1,k=i(S,!0)):k=[]:h(S)||l(S)?(k=C,l(C)?k=v(C):(!f(C)||p(C))&&(k=s(S))):E=!1}E&&(w.set(S,k),b(k,S,y,x,w),w.delete(S)),r(e,n,k)}},1197:function(e,t,n){var r=n(31137),o=n(11871),i=n(63132);e.exports=function(e,t){return i(o(e,t,r),e+"")}},54459:function(e,t,n){var r=n(551),o=n(42630),i=n(31137),a=o?function(e,t){return o(e,"toString",{configurable:!0,enumerable:!1,value:r(t),writable:!0})}:i;e.exports=a},24701:function(e){e.exports=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}},74833:function(e,t,n){var r=n(56127),o=/^\s+/;e.exports=function(e){return e?e.slice(0,r(e)+1).replace(o,""):e}},39334:function(e){e.exports=function(e){return function(t){return e(t)}}},65581:function(e){e.exports=function(e,t){return e.has(t)}},95825:function(e,t,n){var r=n(59942);e.exports=function(e){var t=new e.constructor(e.byteLength);return new r(t).set(new r(e)),t}},2734:function(e,t,n){e=n.nmd(e);var r=n(77400),o=t&&!t.nodeType&&t,i=o&&e&&!e.nodeType&&e,a=i&&i.exports===o?r.Buffer:void 0,s=a?a.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var n=e.length,r=s?s(n):new e.constructor(n);return e.copy(r),r}},63428:function(e,t,n){var r=n(95825);e.exports=function(e,t){var n=t?r(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}},37561:function(e){e.exports=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}},35159:function(e,t,n){var r=n(71928),o=n(88799);e.exports=function(e,t,n,i){var a=!n;n||(n={});for(var s=-1,l=t.length;++s<l;){var u=t[s],c=i?i(n[u],e[u],u,n,e):void 0;void 0===c&&(c=e[u]),a?o(n,u,c):r(n,u,c)}return n}},64937:function(e,t,n){var r=n(77400)["__core-js_shared__"];e.exports=r},7270:function(e,t,n){var r=n(1197),o=n(57535);e.exports=function(e){return r(function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,s=i>2?n[2]:void 0;for(a=e.length>3&&"function"==typeof a?(i--,a):void 0,s&&o(n[0],n[1],s)&&(a=i<3?void 0:a,i=1),t=Object(t);++r<i;){var l=n[r];l&&e(t,l,r,a)}return t})}},18911:function(e){e.exports=function(e){return function(t,n,r){for(var o=-1,i=Object(t),a=r(t),s=a.length;s--;){var l=a[e?s:++o];if(!1===n(i[l],l,i))break}return t}}},42630:function(e,t,n){var r=n(81822),o=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=o},27042:function(e,t,n){var r=n(52485),o=n(90756),i=n(65581);e.exports=function(e,t,n,a,s,l){var u=1&n,c=e.length,d=t.length;if(c!=d&&!(u&&d>c))return!1;var p=l.get(e),f=l.get(t);if(p&&f)return p==t&&f==e;var h=-1,m=!0,g=2&n?new r:void 0;for(l.set(e,t),l.set(t,e);++h<c;){var v=e[h],y=t[h];if(a)var b=u?a(y,v,h,t,e,l):a(v,y,h,e,t,l);if(void 0!==b){if(b)continue;m=!1;break}if(g){if(!o(t,function(e,t){if(!i(g,t)&&(v===e||s(v,e,n,a,l)))return g.push(t)})){m=!1;break}}else if(!(v===y||s(v,y,n,a,l))){m=!1;break}}return l.delete(e),l.delete(t),m}},370:function(e,t,n){var r=n(96539),o=n(59942),i=n(85638),a=n(27042),s=n(19383),l=n(43735),u=r?r.prototype:void 0,c=u?u.valueOf:void 0;e.exports=function(e,t,n,r,u,d,p){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)break;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":if(e.byteLength!=t.byteLength||!d(new o(e),new o(t)))break;return!0;case"[object Boolean]":case"[object Date]":case"[object Number]":return i(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var f=s;case"[object Set]":var h=1&r;if(f||(f=l),e.size!=t.size&&!h)break;var m=p.get(e);if(m)return m==t;r|=2,p.set(e,t);var g=a(f(e),f(t),r,u,d,p);return p.delete(e),g;case"[object Symbol]":if(c)return c.call(e)==c.call(t)}return!1}},39584:function(e,t,n){var r=n(51385),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,i,a,s){var l=1&n,u=r(e),c=u.length;if(c!=r(t).length&&!l)return!1;for(var d=c;d--;){var p=u[d];if(!(l?p in t:o.call(t,p)))return!1}var f=s.get(e),h=s.get(t);if(f&&h)return f==t&&h==e;var m=!0;s.set(e,t),s.set(t,e);for(var g=l;++d<c;){var v=e[p=u[d]],y=t[p];if(i)var b=l?i(y,v,p,t,e,s):i(v,y,p,e,t,s);if(!(void 0===b?v===y||a(v,y,n,i,s):b)){m=!1;break}g||(g="constructor"==p)}if(m&&!g){var x=e.constructor,w=t.constructor;x!=w&&"constructor"in e&&"constructor"in t&&!("function"==typeof x&&x instanceof x&&"function"==typeof w&&w instanceof w)&&(m=!1)}return s.delete(e),s.delete(t),m}},39120:function(e,t,n){var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;e.exports=r},51385:function(e,t,n){var r=n(11324),o=n(83080),i=n(50098);e.exports=function(e){return r(e,i,o)}},95899:function(e,t,n){var r=n(54479);e.exports=function(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}},81822:function(e,t,n){var r=n(46729),o=n(15371);e.exports=function(e,t){var n=o(e,t);return r(n)?n:void 0}},2173:function(e,t,n){var r=n(58023)(Object.getPrototypeOf,Object);e.exports=r},34840:function(e,t,n){var r=n(96539),o=Object.prototype,i=o.hasOwnProperty,a=o.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=i.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var o=a.call(e);return r&&(t?e[s]=n:delete e[s]),o}},83080:function(e,t,n){var r=n(10263),o=n(15937),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(e){return null==e?[]:r(a(e=Object(e)),function(t){return i.call(e,t)})}:o;e.exports=s},3533:function(e,t,n){var r=n(82545),o=n(44538),i=n(64825),a=n(46151),s=n(66902),l=n(99736),u=n(76532),c="[object Map]",d="[object Promise]",p="[object Set]",f="[object WeakMap]",h="[object DataView]",m=u(r),g=u(o),v=u(i),y=u(a),b=u(s),x=l;(r&&x(new r(new ArrayBuffer(1)))!=h||o&&x(new o)!=c||i&&x(i.resolve())!=d||a&&x(new a)!=p||s&&x(new s)!=f)&&(x=function(e){var t=l(e),n="[object Object]"==t?e.constructor:void 0,r=n?u(n):"";if(r)switch(r){case m:return h;case g:return c;case v:return d;case y:return p;case b:return f}return t}),e.exports=x},15371:function(e){e.exports=function(e,t){return null==e?void 0:e[t]}},57753:function(e,t,n){var r=n(35718);e.exports=function(){this.__data__=r?r(null):{},this.size=0}},82452:function(e){e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}},22115:function(e,t,n){var r=n(35718),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(r){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return o.call(t,e)?t[e]:void 0}},38256:function(e,t,n){var r=n(35718),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return r?void 0!==t[e]:o.call(t,e)}},67426:function(e,t,n){var r=n(35718);e.exports=function(e,t){var n=this.__data__;return this.size+=+!this.has(e),n[e]=r&&void 0===t?"__lodash_hash_undefined__":t,this}},97635:function(e,t,n){var r=n(80158),o=n(2173),i=n(56016);e.exports=function(e){return"function"!=typeof e.constructor||i(e)?{}:r(o(e))}},42383:function(e){var t=/^(?:0|[1-9]\d*)$/;e.exports=function(e,n){var r=typeof e;return!!(n=null==n?0x1fffffffffffff:n)&&("number"==r||"symbol"!=r&&t.test(e))&&e>-1&&e%1==0&&e<n}},57535:function(e,t,n){var r=n(85638),o=n(80068),i=n(42383),a=n(11611);e.exports=function(e,t,n){if(!a(n))return!1;var s=typeof t;return("number"==s?!!(o(n)&&i(t,n.length)):"string"==s&&t in n)&&r(n[t],e)}},54479:function(e){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},99678:function(e,t,n){var r,o=n(64937),i=(r=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";e.exports=function(e){return!!i&&i in e}},56016:function(e){var t=Object.prototype;e.exports=function(e){var n=e&&e.constructor;return e===("function"==typeof n&&n.prototype||t)}},63663:function(e){e.exports=function(){this.__data__=[],this.size=0}},72470:function(e,t,n){var r=n(93382),o=Array.prototype.splice;e.exports=function(e){var t=this.__data__,n=r(t,e);return!(n<0)&&(n==t.length-1?t.pop():o.call(t,n,1),--this.size,!0)}},66165:function(e,t,n){var r=n(93382);e.exports=function(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}},71873:function(e,t,n){var r=n(93382);e.exports=function(e){return r(this.__data__,e)>-1}},52556:function(e,t,n){var r=n(93382);e.exports=function(e,t){var n=this.__data__,o=r(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}},39448:function(e,t,n){var r=n(96586),o=n(36301),i=n(44538);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(i||o),string:new r}}},7738:function(e,t,n){var r=n(95899);e.exports=function(e){var t=r(this,e).delete(e);return this.size-=+!!t,t}},66575:function(e,t,n){var r=n(95899);e.exports=function(e){return r(this,e).get(e)}},7238:function(e,t,n){var r=n(95899);e.exports=function(e){return r(this,e).has(e)}},38738:function(e,t,n){var r=n(95899);e.exports=function(e,t){var n=r(this,e),o=n.size;return n.set(e,t),this.size+=+(n.size!=o),this}},19383:function(e){e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}},35718:function(e,t,n){var r=n(81822)(Object,"create");e.exports=r},50962:function(e,t,n){var r=n(58023)(Object.keys,Object);e.exports=r},21586:function(e){e.exports=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}},18125:function(e,t,n){e=n.nmd(e);var r=n(39120),o=t&&!t.nodeType&&t,i=o&&e&&!e.nodeType&&e,a=i&&i.exports===o&&r.process,s=function(){try{var e=i&&i.require&&i.require("util").types;if(e)return e;return a&&a.binding&&a.binding("util")}catch(e){}}();e.exports=s},21258:function(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},58023:function(e){e.exports=function(e,t){return function(n){return e(t(n))}}},11871:function(e,t,n){var r=n(79349),o=Math.max;e.exports=function(e,t,n){return t=o(void 0===t?e.length-1:t,0),function(){for(var i=arguments,a=-1,s=o(i.length-t,0),l=Array(s);++a<s;)l[a]=i[t+a];a=-1;for(var u=Array(t+1);++a<t;)u[a]=i[a];return u[t]=n(l),r(e,this,u)}}},77400:function(e,t,n){var r=n(39120),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();e.exports=i},97494:function(e){e.exports=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}},38639:function(e){e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},88379:function(e){e.exports=function(e){return this.__data__.has(e)}},43735:function(e){e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}},63132:function(e,t,n){var r=n(54459),o=n(49591)(r);e.exports=o},49591:function(e){var t=Date.now;e.exports=function(e){var n=0,r=0;return function(){var o=t(),i=16-(o-r);if(r=o,i>0){if(++n>=800)return arguments[0]}else n=0;return e.apply(void 0,arguments)}}},7354:function(e,t,n){var r=n(36301);e.exports=function(){this.__data__=new r,this.size=0}},5863:function(e){e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},12367:function(e){e.exports=function(e){return this.__data__.get(e)}},90748:function(e){e.exports=function(e){return this.__data__.has(e)}},97569:function(e,t,n){var r=n(36301),o=n(44538),i=n(74554);e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var a=n.__data__;if(!o||a.length<199)return a.push([e,t]),this.size=++n.size,this;n=this.__data__=new i(a)}return n.set(e,t),this.size=n.size,this}},76532:function(e){var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},56127:function(e){var t=/\s/;e.exports=function(e){for(var n=e.length;n--&&t.test(e.charAt(n)););return n}},551:function(e){e.exports=function(e){return function(){return e}}},66726:function(e,t,n){var r=n(11611),o=n(82846),i=n(91936),a=Math.max,s=Math.min;e.exports=function(e,t,n){var l,u,c,d,p,f,h=0,m=!1,g=!1,v=!0;if("function"!=typeof e)throw TypeError("Expected a function");function y(t){var n=l,r=u;return l=u=void 0,h=t,d=e.apply(r,n)}function b(e){var n=e-f,r=e-h;return void 0===f||n>=t||n<0||g&&r>=c}function x(){var e,n,r,i=o();if(b(i))return w(i);p=setTimeout(x,(e=i-f,n=i-h,r=t-e,g?s(r,c-n):r))}function w(e){return(p=void 0,v&&l)?y(e):(l=u=void 0,d)}function C(){var e,n=o(),r=b(n);if(l=arguments,u=this,f=n,r){if(void 0===p)return h=e=f,p=setTimeout(x,t),m?y(e):d;if(g)return clearTimeout(p),p=setTimeout(x,t),y(f)}return void 0===p&&(p=setTimeout(x,t)),d}return t=i(t)||0,r(n)&&(m=!!n.leading,c=(g="maxWait"in n)?a(i(n.maxWait)||0,t):c,v="trailing"in n?!!n.trailing:v),C.cancel=function(){void 0!==p&&clearTimeout(p),h=0,l=f=u=p=void 0},C.flush=function(){return void 0===p?d:w(o())},C}},85638:function(e){e.exports=function(e,t){return e===t||e!=e&&t!=t}},31137:function(e){e.exports=function(e){return e}},2900:function(e,t,n){var r=n(55829),o=n(92360),i=Object.prototype,a=i.hasOwnProperty,s=i.propertyIsEnumerable,l=r(function(){return arguments}())?r:function(e){return o(e)&&a.call(e,"callee")&&!s.call(e,"callee")};e.exports=l},19785:function(e){var t=Array.isArray;e.exports=t},80068:function(e,t,n){var r=n(28338),o=n(84194);e.exports=function(e){return null!=e&&o(e.length)&&!r(e)}},36468:function(e,t,n){var r=n(80068),o=n(92360);e.exports=function(e){return o(e)&&r(e)}},43854:function(e,t,n){e=n.nmd(e);var r=n(77400),o=n(57714),i=t&&!t.nodeType&&t,a=i&&e&&!e.nodeType&&e,s=a&&a.exports===i?r.Buffer:void 0,l=s?s.isBuffer:void 0;e.exports=l||o},56141:function(e,t,n){var r=n(32866);e.exports=function(e,t){return r(e,t)}},28338:function(e,t,n){var r=n(99736),o=n(11611);e.exports=function(e){if(!o(e))return!1;var t=r(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},84194:function(e){e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=0x1fffffffffffff}},11611:function(e){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},92360:function(e){e.exports=function(e){return null!=e&&"object"==typeof e}},40861:function(e,t,n){var r=n(99736),o=n(2173),i=n(92360),a=Object.prototype,s=Function.prototype.toString,l=a.hasOwnProperty,u=s.call(Object);e.exports=function(e){if(!i(e)||"[object Object]"!=r(e))return!1;var t=o(e);if(null===t)return!0;var n=l.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&s.call(n)==u}},55193:function(e,t,n){var r=n(99736),o=n(92360);e.exports=function(e){return"symbol"==typeof e||o(e)&&"[object Symbol]"==r(e)}},48519:function(e,t,n){var r=n(26972),o=n(39334),i=n(18125),a=i&&i.isTypedArray,s=a?o(a):r;e.exports=s},50098:function(e,t,n){var r=n(98213),o=n(20186),i=n(80068);e.exports=function(e){return i(e)?r(e):o(e)}},53893:function(e,t,n){var r=n(98213),o=n(59464),i=n(80068);e.exports=function(e){return i(e)?r(e,!0):o(e)}},15409:function(e,t,n){var r=n(40015),o=n(7270)(function(e,t,n){r(e,t,n)});e.exports=o},82846:function(e,t,n){var r=n(77400);e.exports=function(){return r.Date.now()}},15937:function(e){e.exports=function(){return[]}},57714:function(e){e.exports=function(){return!1}},91936:function(e,t,n){var r=n(74833),o=n(11611),i=n(55193),a=0/0,s=/^[-+]0x[0-9a-f]+$/i,l=/^0b[01]+$/i,u=/^0o[0-7]+$/i,c=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(i(e))return a;if(o(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=r(e);var n=l.test(e);return n||u.test(e)?c(e.slice(2),n?2:8):s.test(e)?a:+e}},89328:function(e,t,n){var r=n(35159),o=n(53893);e.exports=function(e){return r(e,o(e))}},59986:function(e,t,n){"use strict";t.default=void 0;var r,o=(r=n(30265))&&r.__esModule?r:{default:r};t.default=(0,o.default)("M19,19H5V8H19M16,1V3H8V1H6V3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3H18V1M17,12H12V17H17V12Z","Calendar")},11682:function(e,t,n){"use strict";t.default=void 0;var r,o=(r=n(30265))&&r.__esModule?r:{default:r};t.default=(0,o.default)("M7,19V17H9V19H7M11,19V17H13V19H11M15,19V17H17V19H15M7,15V13H9V15H7M11,15V13H13V15H11M15,15V13H17V15H15M7,11V9H9V11H7M11,11V9H13V11H11M15,11V9H17V11H15M7,7V5H9V7H7M11,7V5H13V7H11M15,7V5H17V7H15Z","Drag")},28418:function(e,t,n){"use strict";t.default=void 0;var r,o=(r=n(30265))&&r.__esModule?r:{default:r};t.default=(0,o.default)("M2,5.27L3.28,4L20,20.72L18.73,22L15.65,18.92C14.5,19.3 13.28,19.5 12,19.5C7,19.5 2.73,16.39 1,12C1.69,10.24 2.79,8.69 4.19,7.46L2,5.27M12,9A3,3 0 0,1 15,12C15,12.35 14.94,12.69 14.83,13L11,9.17C11.31,9.06 11.65,9 12,9M12,4.5C17,4.5 21.27,7.61 23,12C22.18,14.08 20.79,15.88 19,17.19L17.58,15.76C18.94,14.82 20.06,13.54 20.82,12C19.17,8.64 15.76,6.5 12,6.5C10.91,6.5 9.84,6.68 8.84,7L7.3,5.47C8.74,4.85 10.33,4.5 12,4.5M3.18,12C4.83,15.36 8.24,17.5 12,17.5C12.69,17.5 13.37,17.43 14,17.29L11.72,15C10.29,14.85 9.15,13.71 9,12.28L5.6,8.87C4.61,9.72 3.78,10.78 3.18,12Z","EyeOffOutline")},57689:function(e,t,n){"use strict";t.default=void 0;var r,o=(r=n(30265))&&r.__esModule?r:{default:r};t.default=(0,o.default)("M12,9A3,3 0 0,1 15,12A3,3 0 0,1 12,15A3,3 0 0,1 9,12A3,3 0 0,1 12,9M12,4.5C17,4.5 21.27,7.61 23,12C21.27,16.39 17,19.5 12,19.5C7,19.5 2.73,16.39 1,12C2.73,7.61 7,4.5 12,4.5M3.18,12C4.83,15.36 8.24,17.5 12,17.5C15.76,17.5 19.17,15.36 20.82,12C19.17,8.64 15.76,6.5 12,6.5C8.24,6.5 4.83,8.64 3.18,12Z","EyeOutline")},86396:function(e,t,n){"use strict";t.default=void 0;var r,o=(r=n(30265))&&r.__esModule?r:{default:r};t.default=(0,o.default)("M19,13H5V11H19V13Z","Minus")},1889:function(e,t,n){"use strict";t.default=void 0;var r,o=(r=n(30265))&&r.__esModule?r:{default:r};t.default=(0,o.default)("M16,12V4H17V2H7V4H8V12L6,14V16H11.2V22H12.8V16H18V14L16,12Z","Pin")},68715:function(e,t,n){!function(e,t){"use strict";var n=function(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach(function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}}),t.default=e,Object.freeze(t)}(t);function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}var o={error:null},i=function(e){function t(){for(var t,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];return(t=e.call.apply(e,[this].concat(r))||this).state=o,t.resetErrorBoundary=function(){for(var e,n=arguments.length,r=Array(n),o=0;o<n;o++)r[o]=arguments[o];null==t.props.onReset||(e=t.props).onReset.apply(e,r),t.reset()},t}t.prototype=Object.create(e.prototype),t.prototype.constructor=t,r(t,e),t.getDerivedStateFromError=function(e){return{error:e}};var i=t.prototype;return i.reset=function(){this.setState(o)},i.componentDidCatch=function(e,t){var n,r;null==(n=(r=this.props).onError)||n.call(r,e,t)},i.componentDidUpdate=function(e,t){var n,r,o,i,a=this.state.error,s=this.props.resetKeys;null!==a&&null!==t.error&&(void 0===(n=e.resetKeys)&&(n=[]),void 0===(r=s)&&(r=[]),n.length!==r.length||n.some(function(e,t){return!Object.is(e,r[t])}))&&(null==(o=(i=this.props).onResetKeysChange)||o.call(i,e.resetKeys,s),this.reset())},i.render=function(){var e=this.state.error,t=this.props,r=t.fallbackRender,o=t.FallbackComponent,i=t.fallback;if(null!==e){var a={error:e,resetErrorBoundary:this.resetErrorBoundary};if(n.isValidElement(i))return i;if("function"==typeof r)return r(a);if(o)return n.createElement(o,a);else throw Error("react-error-boundary requires either a fallback, fallbackRender, or FallbackComponent prop")}return this.props.children},t}(n.Component);e.ErrorBoundary=i,e.useErrorHandler=function(e){var t=n.useState(null),r=t[0],o=t[1];if(null!=e)throw e;if(null!=r)throw r;return o},e.withErrorBoundary=function(e,t){var r=function(r){return n.createElement(i,t,n.createElement(e,r))},o=e.displayName||e.name||"Unknown";return r.displayName="withErrorBoundary("+o+")",r},Object.defineProperty(e,"__esModule",{value:!0})}(t,n(54538))},8317:function(e){function t(){}t.prototype={on:function(e,t,n){var r=this.e||(this.e={});return(r[e]||(r[e]=[])).push({fn:t,ctx:n}),this},once:function(e,t,n){var r=this;function o(){r.off(e,o),t.apply(n,arguments)}return o._=t,this.on(e,o,n)},emit:function(e){for(var t=[].slice.call(arguments,1),n=((this.e||(this.e={}))[e]||[]).slice(),r=0,o=n.length;r<o;r++)n[r].fn.apply(n[r].ctx,t);return this},off:function(e,t){var n=this.e||(this.e={}),r=n[e],o=[];if(r&&t)for(var i=0,a=r.length;i<a;i++)r[i].fn!==t&&r[i].fn._!==t&&o.push(r[i]);return o.length?n[e]=o:delete n[e],this}},e.exports=t,e.exports.TinyEmitter=t},27554:function(e){"use strict";var t;t=function(){function e(){return!0}function t(){return!1}function n(){}return function r(){var o=[{name:"number",test:function(e){return"number"==typeof e}},{name:"string",test:function(e){return"string"==typeof e}},{name:"boolean",test:function(e){return"boolean"==typeof e}},{name:"Function",test:function(e){return"function"==typeof e}},{name:"Array",test:Array.isArray},{name:"Date",test:function(e){return e instanceof Date}},{name:"RegExp",test:function(e){return e instanceof RegExp}},{name:"Object",test:function(e){return"object"==typeof e&&null!==e&&e.constructor===Object}},{name:"null",test:function(e){return null===e}},{name:"undefined",test:function(e){return void 0===e}}],i={name:"any",test:e},a=[],s=[],l={types:o,conversions:s,ignore:a};function u(e){var t=F(l.types,function(t){return t.name===e});if(t)return t;if("any"===e)return i;var n=F(l.types,function(t){return t.name.toLowerCase()===e.toLowerCase()});throw TypeError('Unknown type "'+e+'"'+(n?'. Did you mean "'+n.name+'"?':""))}function c(e){return e===i?999:l.types.indexOf(e)}function d(e){var t=F(l.types,function(t){return t.test(e)});if(t)return t.name;throw TypeError("Value has unknown type. Value: "+e)}function p(e){return e.map(function(e){var t=e.types.map(y);return(e.restParam?"...":"")+t.join("|")}).join(",")}function f(e){var t=N(e);return!!t&&t.restParam}function h(e){return e.types.some(function(e){return null!=e.conversion})}function m(t){if(!t||0===t.types.length)return e;if(1===t.types.length)return u(t.types[0].name).test;if(2===t.types.length){var n=u(t.types[0].name).test,r=u(t.types[1].name).test;return function(e){return n(e)||r(e)}}var o=t.types.map(function(e){return u(e.name).test});return function(e){for(var t=0;t<o.length;t++)if(o[t](e))return!0;return!1}}function g(e,t){return t<e.params.length?e.params[t]:f(e.params)?N(e.params):null}function v(e,t,n){var r=g(e,t);return(r?n?r.types.filter(b):r.types:[]).map(y)}function y(e){return e.name}function b(e){return null===e.conversion||void 0===e.conversion}function x(e,t){var n=function(e){for(var t={},n=0;n<e.length;n++)t[e[n]]=!0;return Object.keys(t)}(I(e,function(e){return v(e,t,!1)}));return -1!==n.indexOf("any")?["any"]:n}function w(e,t,n){var r,o,i,a=e||"unnamed",s=n;for(i=0;i<t.length;i++){var l=s.filter(function(e){var n=m(g(e,i));return(i<e.params.length||f(e.params))&&n(t[i])});if(0===l.length){if((o=x(s,i)).length>0){var u=d(t[i]);return(r=TypeError("Unexpected type of argument in function "+a+" (expected: "+o.join(" or ")+", actual: "+u+", index: "+i+")")).data={category:"wrongType",fn:a,index:i,actual:u,expected:o},r}}else s=l}var c=s.map(function(e){return f(e.params)?1/0:e.params.length});if(t.length<Math.min.apply(null,c))return(r=TypeError("Too few arguments in function "+a+" (expected: "+(o=x(s,i)).join(" or ")+", index: "+t.length+")")).data={category:"tooFewArgs",fn:a,index:t.length,expected:o},r;var p=Math.max.apply(null,c);return t.length>p?(r=TypeError("Too many arguments in function "+a+" (expected: "+p+", actual: "+t.length+")")).data={category:"tooManyArgs",fn:a,index:t.length,expectedLength:p}:(r=TypeError('Arguments of type "'+t.join(", ")+'" do not match any of the defined signatures of function '+a+".")).data={category:"mismatch",actual:t.map(d)},r}function C(e){for(var t=999,n=0;n<e.types.length;n++)b(e.types[n])&&(t=Math.min(t,e.types[n].typeIndex));return t}function S(e){for(var t=999,n=0;n<e.types.length;n++)b(e.types[n])||(t=Math.min(t,e.types[n].conversionIndex));return t}function M(e,t){var n,r,o=Math.min(e.params.length,t.params.length);if(0!=(r=e.params.some(h)-t.params.some(h)))return r;for(n=0;n<o;n++)if(0!=(r=h(e.params[n])-h(t.params[n])))return r;for(n=0;n<o;n++)if(0!==(r=function(e,t){var n;return 0!=(n=e.restParam-t.restParam)||0!=(n=h(e)-h(t))||0!=(n=C(e)-C(t))?n:S(e)-S(t)}(e.params[n],t.params[n])))return r;return e.params.length-t.params.length}function k(e){var t,n,r,o,i=[],a=[];switch(e.types.forEach(function(e){e.conversion&&(i.push(u(e.conversion.from).test),a.push(e.conversion.convert))}),a.length){case 0:return function(e){return e};case 1:return t=i[0],r=a[0],function(e){return t(e)?r(e):e};case 2:return t=i[0],n=i[1],r=a[0],o=a[1],function(e){return t(e)?r(e):n(e)?o(e):e};default:return function(e){for(var t=0;t<a.length;t++)if(i[t](e))return a[t](e);return e}}}function E(e,t){return function e(n,r,o){if(!(r<n.length))return[o.map(function(e,t){return{types:e,restParam:t===n.length-1&&f(n)}})];var i,a=n[r],s=t?a.types.filter(b):a.types;if(a.restParam){var l=s.filter(b);i=l.length<s.length?[l,s]:[s]}else i=s.map(function(e){return[e]});return I(i,function(t){return e(n,r+1,o.concat([t]))})}(e,0,[])}function D(e,r){if(0===Object.keys(r).length)throw SyntaxError("No signatures provided");var o,i=[];Object.keys(r).map(function(e){var t,n,o;return t=r[e],n=l.conversions,o=[],(""!==e.trim()&&(o=e.split(",").map(Z).map(function(e,t,r){var o,i,a,s,l,d,p,f,h=(o=n,i=l=((s=0===e.indexOf("..."))?e.length>3?e.slice(3):"any":e).split("|").map(Z).filter(O).filter(P),a={},o.forEach(function(e){-1!==i.indexOf(e.from)||-1===i.indexOf(e.to)||a[e.from]||(a[e.from]=e)}),d=Object.keys(a).map(function(e){return a[e]}),p=l.map(function(e){var t=u(e);return{name:e,typeIndex:c(t),test:t.test,conversion:null,conversionIndex:-1}}),f=d.map(function(e){var t=u(e.from);return{name:e.from,typeIndex:c(t),test:t.test,conversion:e,conversionIndex:n.indexOf(e)}}),{types:p.concat(f),restParam:s});if(h.restParam&&t!==r.length-1)throw SyntaxError('Unexpected rest parameter "'+e+'": only allowed for the last parameter');return h})),o.some(R))?null:{params:o,fn:t}}).filter(j).forEach(function(e){var t=F(i,function(t){return function(e,t){for(var n=Math.max(e.params.length,t.params.length),r=0;r<n;r++)if(!function(e,t){for(var n,r=0;r<e.length;r++)if(n=e[r],-1!==t.indexOf(n))return!0;return!1}(v(e,r,!0),v(t,r,!0)))return!1;var o=e.params.length,i=t.params.length,a=f(e.params),s=f(t.params);return a?s?o===i:i>=o:s?o>=i:o===i}(t,e)});if(t)throw TypeError('Conflicting signatures "'+p(t.params)+'" and "'+p(e.params)+'".');i.push(e)});var a=I(i,function(e){return(e?E(e.params,!1):[]).map(function(t){return{params:t,fn:e.fn}})}).filter(j);a.sort(M);var s=a[0]&&a[0].params.length<=2&&!f(a[0].params),d=a[1]&&a[1].params.length<=2&&!f(a[1].params),g=a[2]&&a[2].params.length<=2&&!f(a[2].params),y=a[3]&&a[3].params.length<=2&&!f(a[3].params),b=a[4]&&a[4].params.length<=2&&!f(a[4].params),x=a[5]&&a[5].params.length<=2&&!f(a[5].params),w=a.map(function(e){return function(e){var t,n,r;if(f(e)){var o,i=(t=(o=e).slice(0,o.length-1).map(m)).length,a=m(N(e)),s=function(e){for(var t=i;t<e.length;t++)if(!a(e[t]))return!1;return!0};return function(e){for(var n=0;n<t.length;n++)if(!t[n](e[n]))return!1;return s(e)&&e.length>=i+1}}return 0===e.length?function(e){return 0===e.length}:1===e.length?(n=m(e[0]),function(e){return n(e[0])&&1===e.length}):2===e.length?(n=m(e[0]),r=m(e[1]),function(e){return n(e[0])&&r(e[1])&&2===e.length}):(t=e.map(m),function(e){for(var n=0;n<t.length;n++)if(!t[n](e[n]))return!1;return e.length===t.length})}(e.params)}),C=s?m(a[0].params[0]):t,S=d?m(a[1].params[0]):t,D=g?m(a[2].params[0]):t,T=y?m(a[3].params[0]):t,_=b?m(a[4].params[0]):t,L=x?m(a[5].params[0]):t,V=s?m(a[0].params[1]):t,$=d?m(a[1].params[1]):t,B=g?m(a[2].params[1]):t,z=y?m(a[3].params[1]):t,H=b?m(a[4].params[1]):t,W=x?m(a[5].params[1]):t,G=a.map(function(e){return function(e,t){var n=t;if(e.some(h)){var r=f(e),o=e.map(k);n=function(){for(var e=[],n=r?arguments.length-1:arguments.length,i=0;i<n;i++)e[i]=o[i](arguments[i]);return r&&(e[n]=arguments[n].map(o[n])),t.apply(this,e)}}var i=n;if(f(e)){var a=e.length-1;i=function(){return n.apply(this,A(arguments,0,a).concat([A(arguments,a)]))}}return i}(e.params,e.fn)}),U=s?G[0]:n,q=d?G[1]:n,Y=g?G[2]:n,X=y?G[3]:n,K=b?G[4]:n,Q=x?G[5]:n,J=s?a[0].params.length:-1,ee=d?a[1].params.length:-1,et=g?a[2].params.length:-1,en=y?a[3].params.length:-1,er=b?a[4].params.length:-1,eo=x?a[5].params.length:-1,ei=6*!!(s&&d&&g&&y&&b&&x),ea=a.length,es=function(){for(var t=ei;t<ea;t++)if(w[t](arguments))return G[t].apply(this,arguments);return l.onMismatch(e,arguments,a)},el=function e(t,n){return arguments.length===J&&C(t)&&V(n)?U.apply(e,arguments):arguments.length===ee&&S(t)&&$(n)?q.apply(e,arguments):arguments.length===et&&D(t)&&B(n)?Y.apply(e,arguments):arguments.length===en&&T(t)&&z(n)?X.apply(e,arguments):arguments.length===er&&_(t)&&H(n)?K.apply(e,arguments):arguments.length===eo&&L(t)&&W(n)?Q.apply(e,arguments):es.apply(e,arguments)};try{Object.defineProperty(el,"name",{value:e})}catch(e){}return el.signatures=(o={},a.forEach(function(e){e.params.some(h)||E(e.params,!0).forEach(function(t){o[p(t)]=e.fn})}),o),el}function T(e,t,n){throw w(e,t,n)}function P(e){return -1===l.ignore.indexOf(e)}function Z(e){return e.trim()}function O(e){return!!e}function j(e){return null!==e}function R(e){return 0===e.types.length}function N(e){return e[e.length-1]}function A(e,t,n){return Array.prototype.slice.call(e,t,n)}function F(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return e[n]}function I(e,t){return Array.prototype.concat.apply([],e.map(t))}function _(e){for(var t="",n=0;n<e.length;n++){var r=e[n];if(("object"==typeof r.signatures||"string"==typeof r.signature)&&""!==r.name){if(""===t)t=r.name;else if(t!==r.name){var o=Error("Function names do not match (expected: "+t+", actual: "+r.name+")");throw o.data={actual:r.name,expected:t},o}}}return t}function L(e){var t,n={};function r(e,r){if(n.hasOwnProperty(e)&&r!==n[e])throw(t=Error('Signature "'+e+'" is defined twice')).data={signature:e},t}for(var o=0;o<e.length;o++){var i=e[o];if("object"==typeof i.signatures)for(var a in i.signatures)i.signatures.hasOwnProperty(a)&&(r(a,i.signatures[a]),n[a]=i.signatures[a]);else if("string"==typeof i.signature)r(i.signature,i),n[i.signature]=i;else throw(t=TypeError("Function is no typed-function (index: "+o+")")).data={index:o},t}return n}return(l=D("typed",{"string, Object":D,Object:function(e){var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(e[n]);return D(_(t),e)},"...Function":function(e){return D(_(e),L(e))},"string, ...Function":function(e,t){return D(e,L(t))}})).create=r,l.types=o,l.conversions=s,l.ignore=a,l.onMismatch=T,l.throwMismatchError=T,l.createError=w,l.convert=function(e,t){var n=d(e);if(t===n)return e;for(var r=0;r<l.conversions.length;r++){var o=l.conversions[r];if(o.from===n&&o.to===t)return o.convert(e)}throw Error("Cannot convert from "+n+" to "+t)},l.find=function(e,t){if(!e.signatures)throw TypeError("Function is no typed-function");if("string"==typeof t){n=t.split(",");for(var n,r=0;r<n.length;r++)n[r]=n[r].trim()}else if(Array.isArray(t))n=t;else throw TypeError("String array or a comma separated string expected");var o=n.join(","),i=e.signatures[o];if(i)return i;throw TypeError("Signature not found (signature: "+(e.name||"unnamed")+"("+n.join(", ")+"))")},l.addType=function(e,t){if(!e||"string"!=typeof e.name||"function"!=typeof e.test)throw TypeError("Object with properties {name: string, test: function} expected");if(!1!==t){for(var n=0;n<l.types.length;n++)if("Object"===l.types[n].name){l.types.splice(n,0,e);return}}l.types.push(e)},l.addConversion=function(e){if(!e||"string"!=typeof e.from||"string"!=typeof e.to||"function"!=typeof e.convert)throw TypeError("Object with properties {from: string, to: string, convert: function} expected");l.conversions.push(e)},l}()},"function"==typeof define&&define.amd?define([],t):e.exports=t()}}]);
|