cartethyia 2.5.3 → 2.5.6
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/.env.example +13 -4
- package/README.md +2 -2
- package/dist/dashboard/assets/{BannedPage-hfCzi-Ux.js → BannedPage-CADDq4IU.js} +1 -1
- package/dist/dashboard/assets/BannedPage-CADDq4IU.js.gz +0 -0
- package/dist/dashboard/assets/CliToolDetailPage-_z1hID7E.js +1 -0
- package/dist/dashboard/assets/CliToolDetailPage-_z1hID7E.js.gz +0 -0
- package/dist/dashboard/assets/{CliToolsPage-DEDyKBlC.js → CliToolsPage-DuO1Z7dq.js} +1 -1
- package/dist/dashboard/assets/CliToolsPage-DuO1Z7dq.js.gz +0 -0
- package/dist/dashboard/assets/CombosPage-DNEPi3xU.js +1 -0
- package/dist/dashboard/assets/CombosPage-DNEPi3xU.js.gz +0 -0
- package/dist/dashboard/assets/{ConsoleLogPage-bsLuZmYH.js → ConsoleLogPage-BVdpfiz1.js} +1 -1
- package/dist/dashboard/assets/ConsoleLogPage-BVdpfiz1.js.gz +0 -0
- package/dist/dashboard/assets/{CustomizationPage-_UWhwziJ.js → CustomizationPage-BR5HHvbi.js} +1 -1
- package/dist/dashboard/assets/CustomizationPage-BR5HHvbi.js.gz +0 -0
- package/dist/dashboard/assets/HealthEventsModal-mUfcknqm.js +1 -0
- package/dist/dashboard/assets/HealthEventsModal-mUfcknqm.js.gz +0 -0
- package/dist/dashboard/assets/{LoginPage-DDVIfZGW.js → LoginPage-V5faV9V2.js} +1 -1
- package/dist/dashboard/assets/LoginPage-V5faV9V2.js.gz +0 -0
- package/dist/dashboard/assets/ModelPicker-C7pDb41R.js +1 -0
- package/dist/dashboard/assets/ModelPicker-C7pDb41R.js.gz +0 -0
- package/dist/dashboard/assets/OverviewPage-BDu20Jdx.js +1 -0
- package/dist/dashboard/assets/OverviewPage-BDu20Jdx.js.gz +0 -0
- package/dist/dashboard/assets/ProviderDetailPage-Dllr_aFO.js +3 -0
- package/dist/dashboard/assets/ProviderDetailPage-Dllr_aFO.js.gz +0 -0
- package/dist/dashboard/assets/ProvidersPage-uPiGVTTK.js +1 -0
- package/dist/dashboard/assets/ProvidersPage-uPiGVTTK.js.gz +0 -0
- package/dist/dashboard/assets/ProxyPage-BaUkO-4O.js +7 -0
- package/dist/dashboard/assets/ProxyPage-BaUkO-4O.js.gz +0 -0
- package/dist/dashboard/assets/QuotaPage-o0IFAsFb.js +1 -0
- package/dist/dashboard/assets/QuotaPage-o0IFAsFb.js.gz +0 -0
- package/dist/dashboard/assets/SettingsPage-CYWqbXjp.js +1 -0
- package/dist/dashboard/assets/SettingsPage-CYWqbXjp.js.gz +0 -0
- package/dist/dashboard/assets/{SetupPage-D6pmQ86L.js → SetupPage-UB690SE2.js} +1 -1
- package/dist/dashboard/assets/SetupPage-UB690SE2.js.gz +0 -0
- package/dist/dashboard/assets/{SortableList-DWvKiuSl.js → SortableList-BLujdX7N.js} +1 -1
- package/dist/dashboard/assets/SortableList-BLujdX7N.js.gz +0 -0
- package/dist/dashboard/assets/{StudioPage-CmkUrgdj.js → StudioPage-D5C2raAc.js} +3 -3
- package/dist/dashboard/assets/StudioPage-D5C2raAc.js.gz +0 -0
- package/dist/dashboard/assets/UsagePage-8uIcxa1W.js +56 -0
- package/dist/dashboard/assets/UsagePage-8uIcxa1W.js.gz +0 -0
- package/dist/dashboard/assets/api-keys-DQYLQxpW.js +1 -0
- package/dist/dashboard/assets/api-keys-DQYLQxpW.js.gz +0 -0
- package/dist/dashboard/assets/app-CX_Z8cMs.css +2 -0
- package/dist/dashboard/assets/app-CX_Z8cMs.css.gz +0 -0
- package/dist/dashboard/assets/{assert-NHwYq95t.js → assert-C9FD_JwJ.js} +1 -1
- package/dist/dashboard/assets/assert-C9FD_JwJ.js.gz +0 -0
- package/dist/dashboard/assets/{badge-6uzDDvqs.js → badge-CR72dasT.js} +1 -1
- package/dist/dashboard/assets/badge-CR72dasT.js.gz +0 -0
- package/dist/dashboard/assets/{banner-4_WNg2WZ.js → banner-CI9_eSfO.js} +1 -1
- package/dist/dashboard/assets/banner-CI9_eSfO.js.gz +0 -0
- package/dist/dashboard/assets/{card--AtFedAq.js → card-DS7CQEsO.js} +1 -1
- package/dist/dashboard/assets/card-DS7CQEsO.js.gz +0 -0
- package/dist/dashboard/assets/{cli-tools-B3e7dx3N.js → cli-tools-CNqzrfdb.js} +1 -1
- package/dist/dashboard/assets/cli-tools-CNqzrfdb.js.gz +0 -0
- package/dist/dashboard/assets/{clipboard-button-NreUx6c8.js → clipboard-button-611pSsaX.js} +1 -1
- package/dist/dashboard/assets/clipboard-button-611pSsaX.js.gz +0 -0
- package/dist/dashboard/assets/{fingerprint-pattern-BWuHtbW4.js → concurrency-BDF0ok7y.js} +1 -1
- package/dist/dashboard/assets/concurrency-BDF0ok7y.js.gz +0 -0
- package/dist/dashboard/assets/database-Dz9N3zGd.js +1 -0
- package/dist/dashboard/assets/database-Dz9N3zGd.js.gz +0 -0
- package/dist/dashboard/assets/dialog-k37exjNt.js +1 -0
- package/dist/dashboard/assets/dialog-k37exjNt.js.gz +0 -0
- package/dist/dashboard/assets/drawer-CX7N8ucR.js +1 -0
- package/dist/dashboard/assets/drawer-CX7N8ucR.js.gz +0 -0
- package/dist/dashboard/assets/entry-B9Xvtnfj.js +1 -0
- package/dist/dashboard/assets/entry-B9Xvtnfj.js.gz +0 -0
- package/dist/dashboard/assets/entry-CTP8AyiS.js +1 -0
- package/dist/dashboard/assets/entry-CTP8AyiS.js.gz +0 -0
- package/dist/dashboard/assets/entry-DxBHnauy.js +4 -0
- package/dist/dashboard/assets/entry-DxBHnauy.js.gz +0 -0
- package/dist/dashboard/assets/{github-badge-D_eM3IgG.js → github-badge-sltk1qUi.js} +1 -1
- package/dist/dashboard/assets/github-badge-sltk1qUi.js.gz +0 -0
- package/dist/dashboard/assets/{index-BydyKaDz.js → index-CmxZr14F.js} +2 -2
- package/dist/dashboard/assets/index-CmxZr14F.js.gz +0 -0
- package/dist/dashboard/assets/{inline-BcNGF8Gr.js → inline-BhY2sSnO.js} +1 -1
- package/dist/dashboard/assets/inline-BhY2sSnO.js.gz +0 -0
- package/dist/dashboard/assets/{input-BG41et9G.js → input-V1umFiBk.js} +1 -1
- package/dist/dashboard/assets/input-V1umFiBk.js.gz +0 -0
- package/dist/dashboard/assets/layout-BBOYycyS.js +1 -0
- package/dist/dashboard/assets/layout-BBOYycyS.js.gz +0 -0
- package/dist/dashboard/assets/{list-row-Gh_W4OR_.js → list-row-1zzZYM0B.js} +1 -1
- package/dist/dashboard/assets/list-row-1zzZYM0B.js.gz +0 -0
- package/dist/dashboard/assets/{live-BJGYRBnR.js → live-BivGfuUs.js} +1 -1
- package/dist/dashboard/assets/live-BivGfuUs.js.gz +0 -0
- package/dist/dashboard/assets/model-bans-CmffjLuG.js +1 -0
- package/dist/dashboard/assets/model-bans-CmffjLuG.js.gz +0 -0
- package/dist/dashboard/assets/{mutation-BkoLM5Ba.js → mutation-46P0oWMe.js} +1 -1
- package/dist/dashboard/assets/mutation-46P0oWMe.js.gz +0 -0
- package/dist/dashboard/assets/numbers-DkfMR5Qs.js +2 -0
- package/dist/dashboard/assets/numbers-DkfMR5Qs.js.gz +0 -0
- package/dist/dashboard/assets/{query-keys-D7wX2vM5.js → query-keys-BFhGpwR1.js} +1 -1
- package/dist/dashboard/assets/query-keys-BFhGpwR1.js.gz +0 -0
- package/dist/dashboard/assets/{routing-CcusqXA7.js → routing-CAb4F37R.js} +1 -1
- package/dist/dashboard/assets/routing-CAb4F37R.js.gz +0 -0
- package/dist/dashboard/assets/{select-BO6h8yNv.js → select-BYR_5K2c.js} +2 -2
- package/dist/dashboard/assets/select-BYR_5K2c.js.gz +0 -0
- package/dist/dashboard/assets/{settings-mpmXTgUa.js → settings-DNX9sydi.js} +1 -1
- package/dist/dashboard/assets/settings-DNX9sydi.js.gz +0 -0
- package/dist/dashboard/assets/{stack-DwLmjUFK.js → stack-BHTfXdz_.js} +1 -1
- package/dist/dashboard/assets/stack-BHTfXdz_.js.gz +0 -0
- package/dist/dashboard/assets/{state-DYdQmdAl.js → state-mPDRlQkl.js} +1 -1
- package/dist/dashboard/assets/state-mPDRlQkl.js.gz +0 -0
- package/dist/dashboard/assets/switch-DOmJxg7H.js +1 -0
- package/dist/dashboard/assets/switch-DOmJxg7H.js.gz +0 -0
- package/dist/dashboard/assets/terminal-0_IjPWTk.js +1 -0
- package/dist/dashboard/assets/terminal-0_IjPWTk.js.gz +0 -0
- package/dist/dashboard/assets/tokens-COzario9.js +1 -0
- package/dist/dashboard/assets/tokens-COzario9.js.gz +0 -0
- package/dist/dashboard/assets/use-modal-focus-By7oJoGd.js +1 -0
- package/dist/dashboard/assets/use-modal-focus-By7oJoGd.js.gz +0 -0
- package/dist/dashboard/assets/{useMutation-w4u4CVue.js → useMutation-Dem0lXQj.js} +1 -1
- package/dist/dashboard/assets/useMutation-Dem0lXQj.js.gz +0 -0
- package/dist/dashboard/assets/zap-C4EeVW4q.js +1 -0
- package/dist/dashboard/assets/zap-C4EeVW4q.js.gz +0 -0
- package/dist/dashboard/donation/qris-risun-marke.png +0 -0
- package/dist/dashboard/index.html +1 -1
- package/dist/dashboard/index.html.gz +0 -0
- package/dist/dashboard/precompressed-assets.json +57 -57
- package/migrations/README.md +52 -52
- package/migrations/lite-sqlite3/0000_baseline.sql +2 -2
- package/package.json +96 -95
- package/scripts/cli/admin.ts +125 -0
- package/scripts/cli/autostart.ts +237 -0
- package/scripts/cli/{ui/background.ts → background.ts} +1 -1
- package/scripts/cli/{command/console-menu.ts → console-menu.ts} +275 -248
- package/scripts/cli/doctor.ts +37 -0
- package/scripts/cli/{support/env.ts → env.ts} +99 -99
- package/scripts/cli/{gateway/spawn.ts → gateway.ts} +112 -24
- package/scripts/cli/instance.ts +224 -0
- package/scripts/cli/main.ts +88 -18
- package/scripts/cli/{support/platform.ts → platform.ts} +64 -64
- package/scripts/cli/port.ts +100 -0
- package/scripts/cli/{support/services.ts → services.ts} +88 -88
- package/scripts/cli/{command/setup.ts → setup.ts} +35 -34
- package/scripts/cli/{command/start.ts → start.ts} +10 -5
- package/scripts/cli/{support/startup-signal.ts → startup-signal.ts} +23 -23
- package/scripts/cli/tray/index.ts +62 -12
- package/scripts/cli/{command/tray.ts → tray.ts} +208 -208
- package/scripts/cli/update.ts +40 -0
- package/scripts/cli/version.ts +67 -0
- package/scripts/cli/{ui/wordmark.ts → wordmark.ts} +58 -58
- package/src/boot/app.ts +11 -7
- package/src/boot/dependencies.ts +50 -19
- package/src/boot/timeout.ts +2 -13
- package/src/config/cooldowns.ts +186 -138
- package/src/config/network.ts +8 -14
- package/src/config/providers.ts +7 -10
- package/src/config/runtime.ts +76 -76
- package/src/config/security.ts +15 -0
- package/src/config/spec.ts +52 -7
- package/src/config/telemetry.ts +26 -0
- package/src/config/timeouts.ts +0 -6
- package/src/console/admin/model-abuse/contracts.ts +28 -6
- package/src/console/admin/model-abuse/routes.ts +56 -3
- package/src/console/api-keys/bucket-spend.ts +15 -4
- package/src/console/api-keys/contracts.ts +410 -414
- package/src/console/api-keys/routes.ts +881 -880
- package/src/console/auth/credentials.ts +3 -3
- package/src/console/auth/setup-service.ts +2 -2
- package/src/console/backup/contracts.ts +15 -2
- package/src/console/backup/export-endpoint.ts +6 -2
- package/src/console/backup/nine-router.ts +2 -5
- package/src/console/backup/service.ts +4 -0
- package/src/console/backup/store.ts +192 -29
- package/src/console/backup/validate.ts +3 -45
- package/src/console/cli-tools/fs-ops.ts +487 -487
- package/src/console/console-router-guards.ts +1 -1
- package/src/console/console-router.ts +8 -0
- package/src/console/data-management/contracts.ts +100 -0
- package/src/console/data-management/operations.ts +234 -0
- package/src/console/data-management/routes.ts +103 -0
- package/src/console/domain-registration.ts +45 -1
- package/src/console/observability/contracts.ts +524 -485
- package/src/console/observability/live.ts +22 -0
- package/src/console/observability/store.ts +1138 -1018
- package/src/console/observability/usage-dimensions.ts +4 -4
- package/src/console/providers/catalog/catalog-projections.ts +6 -7
- package/src/console/providers/catalog/contracts.ts +6 -0
- package/src/console/providers/catalog/model-operations.ts +5 -2
- package/src/console/providers/catalog/provider-operations.ts +24 -4
- package/src/console/providers/catalog/public-model-store.ts +8 -11
- package/src/console/providers/catalog/routes.ts +7 -0
- package/src/console/providers/catalog/store.ts +1553 -1532
- package/src/console/providers/oauth/routes.ts +8 -12
- package/src/console/quota/account-quota-shared.ts +52 -39
- package/src/console/quota/account-quota-tenant.ts +6 -6
- package/src/console/quota/quota-view.ts +1 -1
- package/src/console/quota/refresh.ts +441 -429
- package/src/console/remote-support/contracts.ts +61 -0
- package/src/console/remote-support/routes.ts +65 -0
- package/src/console/remote-support/service.ts +207 -0
- package/src/console/response-compression.ts +0 -3
- package/src/console/routing/pools/import-parse.ts +206 -0
- package/src/console/routing/pools/operations.ts +543 -501
- package/src/console/routing/pools/probe-result.ts +3 -2
- package/src/console/routing/pools/probe-verdict.ts +132 -132
- package/src/console/routing/pools/routes.ts +181 -164
- package/src/console/routing/pools/store.ts +8 -8
- package/src/console/settings/contracts.ts +95 -2
- package/src/console/settings/store.ts +81 -3
- package/src/console/shared/cursor.ts +8 -8
- package/src/console/shared/errors.ts +1 -3
- package/src/console/updates/routes.ts +16 -0
- package/src/main.ts +10 -0
- package/src/network/http2-bidi.ts +2 -4
- package/src/network/pool/agent.ts +478 -478
- package/src/network/pool/selector.ts +5 -4
- package/src/network/retry.ts +1 -2
- package/src/network/ssrf.ts +5 -4
- package/src/observability/event-compaction.ts +317 -0
- package/src/observability/event-day-index.ts +440 -0
- package/src/observability/event-log.ts +155 -6
- package/src/observability/logger.ts +6 -6
- package/src/observability/payload-capture.ts +158 -33
- package/src/observability/payload-store.ts +82 -61
- package/src/observability/redaction.ts +5 -6
- package/src/observability/request-notify.ts +43 -0
- package/src/observability/telemetry-status.ts +8 -9
- package/src/observability/token-speed.ts +5 -4
- package/src/persistence/db-mode.ts +7 -7
- package/src/persistence/health-event-flush.ts +36 -0
- package/src/persistence/readiness.ts +1 -1
- package/src/persistence/schema.ts +75 -29
- package/src/persistence/shared-cache.ts +1 -2
- package/src/persistence/stores/api-key-store.ts +18 -6
- package/src/persistence/stores/share-store.ts +4 -3
- package/src/persistence/stores/telemetry-store.ts +33 -11
- package/src/protocol/canonical-model.ts +11 -3
- package/src/protocol/codecs.ts +139 -6
- package/src/protocol/gateway-error.ts +6 -4
- package/src/protocol/image-clamp.ts +19 -1
- package/src/protocol/registry.ts +8 -0
- package/src/protocol/request/chat.ts +21 -1
- package/src/protocol/request/codex.ts +10 -1
- package/src/protocol/request/gemini.ts +9 -2
- package/src/protocol/request/messages.ts +18 -7
- package/src/protocol/request/responses.ts +9 -1
- package/src/protocol/response/chat.ts +34 -4
- package/src/protocol/response/codex.ts +7 -4
- package/src/protocol/response/dsml.ts +140 -28
- package/src/protocol/response/responses.ts +11 -5
- package/src/protocol/stream-error-frames.ts +4 -5
- package/src/providers/adapters/compatible-adapter.ts +3 -0
- package/src/providers/authentication/jwt-validator.ts +9 -10
- package/src/providers/authentication/oauth-refresh-service.ts +9 -11
- package/src/providers/bundled-discovery-providers.ts +122 -119
- package/src/providers/configured-openai-providers.ts +4 -4
- package/src/providers/default-registry.ts +5 -4
- package/src/providers/discovery/catalog/catalog-blob.ts +18 -18
- package/src/providers/discovery/catalog/catalog-format.ts +3 -6
- package/src/providers/discovery/models-dev-catalog.ts +354 -354
- package/src/providers/discovery/openai-model-discovery.ts +5 -0
- package/src/providers/discovery/openrouter-free-roster.ts +15 -17
- package/src/providers/discovery/probe-phases.ts +4 -4
- package/src/providers/discovery/probe-wire.ts +6 -13
- package/src/providers/discovery/probing-service.ts +1117 -1045
- package/src/providers/integrations/alibabacp/alibabacp.ts +1 -1
- package/src/providers/integrations/antigravity/antigravity-quota.ts +5 -7
- package/src/providers/integrations/buddy/buddy-chat-shared.ts +23 -2
- package/src/providers/integrations/buddy/buddy-checkin.ts +1 -4
- package/src/providers/integrations/buddy/buddy-cli-headers.ts +23 -6
- package/src/providers/integrations/buddy/buddy-conversation-headers.ts +0 -1
- package/src/providers/integrations/buddy/buddy-identity.ts +52 -0
- package/src/providers/integrations/buddy/buddy-media.ts +2 -2
- package/src/providers/integrations/buddy/buddy-usage-store.ts +3 -4
- package/src/providers/integrations/buddy/codebuddy/quota.ts +2 -13
- package/src/providers/integrations/buddy/codebuddy/shared.ts +118 -115
- package/src/providers/integrations/buddy/workbuddy/quota.ts +0 -11
- package/src/providers/integrations/buddy/workbuddy/shared.ts +5 -2
- package/src/providers/integrations/claude/claude.ts +608 -608
- package/src/providers/integrations/cline/cline-quota.ts +27 -20
- package/src/providers/integrations/cline/cline.ts +537 -539
- package/src/providers/integrations/codex/codex-headers.ts +25 -39
- package/src/providers/integrations/codex/codex-oauth.ts +1 -1
- package/src/providers/integrations/codex/codex.ts +2 -29
- package/src/providers/integrations/commandcode/commandcode.ts +674 -675
- package/src/providers/integrations/commandcode/discovery.ts +117 -116
- package/src/providers/integrations/cursor/cursor-auth.ts +418 -418
- package/src/providers/integrations/cursor/cursor-quota.ts +309 -0
- package/src/providers/integrations/cursor/cursor-request.ts +616 -471
- package/src/providers/integrations/cursor/cursor-session-manager.ts +319 -281
- package/src/providers/integrations/cursor/cursor.ts +1333 -960
- package/src/providers/integrations/cursor/protocol/messages.ts +25 -0
- package/src/providers/integrations/factory/factory-models.ts +3 -5
- package/src/providers/integrations/factory/factory.ts +8 -1
- package/src/providers/integrations/gemini.ts +6 -1
- package/src/providers/integrations/grok/grok-install-id.ts +2 -3
- package/src/providers/integrations/grok/grok-quota.ts +279 -177
- package/src/providers/integrations/grok/grok-ratelimit-store.ts +73 -0
- package/src/providers/integrations/grok/grok-ratelimit.ts +218 -0
- package/src/providers/integrations/grok/grok.ts +6 -7
- package/src/providers/integrations/hermes.ts +14 -18
- package/src/providers/integrations/kiro/kiro-discovery.ts +1 -1
- package/src/providers/integrations/kiro/kiro.ts +1 -1
- package/src/providers/integrations/mistral.ts +6 -6
- package/src/providers/integrations/opencode/fingerprint.ts +3 -3
- package/src/providers/integrations/opencode/provider.ts +19 -20
- package/src/providers/integrations/qoder/qoder-catalog.ts +450 -450
- package/src/providers/integrations/qoder/qoder-oauth.ts +388 -310
- package/src/providers/integrations/qoder/qoder-quota.ts +192 -0
- package/src/providers/integrations/qoder/qoder.ts +884 -865
- package/src/providers/integrations/shared/connect.ts +6 -6
- package/src/providers/integrations/trae/trae-catalog.ts +1 -2
- package/src/providers/integrations/trae/trae-quota.ts +384 -0
- package/src/providers/integrations/trae/trae.ts +2 -2
- package/src/providers/integrations/zcode/oauth.ts +6 -1
- package/src/providers/operations/account-health-service.ts +75 -27
- package/src/providers/operations/account-reset-service.ts +1 -1
- package/src/providers/operations/client-versions.ts +6 -6
- package/src/providers/operations/custom-cli-headers.ts +3 -4
- package/src/providers/operations/provider-catalog-seeder.ts +95 -95
- package/src/providers/operations/provider-catalog-service.ts +3 -4
- package/src/providers/provider-contracts.ts +7 -0
- package/src/providers/provider-metadata.ts +10 -8
- package/src/providers/provider-registry.ts +6 -7
- package/src/providers/provider-usage.ts +1 -1
- package/src/providers/quota/quota-support.ts +8 -0
- package/src/security/abuse.ts +15 -10
- package/src/security/access-control.ts +144 -146
- package/src/security/admission/contracts.ts +11 -0
- package/src/security/admission/in-memory-store.ts +4 -3
- package/src/security/admission/lease-sweep.ts +6 -6
- package/src/security/admission/reasons.ts +5 -1
- package/src/security/admission/redis-store.ts +211 -210
- package/src/security/admission/service.ts +4 -0
- package/src/security/api-key-auth.ts +27 -17
- package/src/security/ip-boundary.ts +155 -15
- package/src/security/model-abuse.ts +366 -94
- package/src/security/outbound-headers.ts +3 -4
- package/src/shared/sleep.ts +4 -0
- package/src/transport/dispatch/attempt-finalize.ts +47 -5
- package/src/transport/dispatch/attempt-loop.ts +531 -530
- package/src/transport/dispatch/generation.ts +6 -0
- package/src/transport/dispatch/proxy-request.ts +24 -1
- package/src/transport/dispatch/ratelimit-capture.ts +37 -0
- package/src/transport/dispatch/stream-bridge.ts +1 -3
- package/src/transport/dispatch/streaming/finalize.ts +1 -1
- package/src/transport/dispatch/streaming/stream.ts +19 -6
- package/src/transport/dispatch/upstream.ts +9 -0
- package/src/transport/failure-policy.ts +162 -8
- package/src/transport/guards/auth-guard.ts +7 -4
- package/src/transport/guards/concurrency-guard.ts +0 -5
- package/src/transport/guards/error-lifecycle.ts +13 -6
- package/src/transport/guards/pipeline.ts +15 -3
- package/src/transport/guards/request-context.ts +8 -2
- package/src/transport/request/inflight.ts +5 -6
- package/src/transport/request/preparer.ts +9 -8
- package/src/transport/request/state.ts +21 -8
- package/src/transport/request/tenant-preferences.ts +60 -0
- package/src/transport/routing/admission.ts +4 -0
- package/src/transport/routing/route-catalog.ts +65 -10
- package/src/transport/routing/route-model.ts +46 -14
- package/src/transport/routing/router.ts +21 -14
- package/src/transport/surface/completion.ts +2 -3
- package/src/transport/surface/dialects.ts +5 -6
- package/src/transport/surface/responses/encode.ts +38 -0
- package/src/transport/surface/responses/parse.ts +4 -0
- package/src/transport/translation/capabilities.ts +2 -3
- package/src/transport/translation/quirks.ts +3 -3
- package/src/workers/buddy-growth-tasks.ts +5 -10
- package/src/workers/daily-checkin.ts +17 -23
- package/src/workers/quota-refresh-sweep.ts +26 -26
- package/dist/dashboard/assets/BannedPage-hfCzi-Ux.js.gz +0 -0
- package/dist/dashboard/assets/CliToolDetailPage-DLGqYEwI.js +0 -1
- package/dist/dashboard/assets/CliToolDetailPage-DLGqYEwI.js.gz +0 -0
- package/dist/dashboard/assets/CliToolsPage-DEDyKBlC.js.gz +0 -0
- package/dist/dashboard/assets/CombosPage-CfuYiQ8Z.js +0 -1
- package/dist/dashboard/assets/CombosPage-CfuYiQ8Z.js.gz +0 -0
- package/dist/dashboard/assets/ConsoleLogPage-bsLuZmYH.js.gz +0 -0
- package/dist/dashboard/assets/CustomizationPage-_UWhwziJ.js.gz +0 -0
- package/dist/dashboard/assets/HealthEventsModal-Cjfc5WFS.js +0 -1
- package/dist/dashboard/assets/HealthEventsModal-Cjfc5WFS.js.gz +0 -0
- package/dist/dashboard/assets/LoginPage-DDVIfZGW.js.gz +0 -0
- package/dist/dashboard/assets/ModelPicker-CWkTUtpX.js +0 -1
- package/dist/dashboard/assets/ModelPicker-CWkTUtpX.js.gz +0 -0
- package/dist/dashboard/assets/OverviewPage-B53YYMng.js +0 -1
- package/dist/dashboard/assets/OverviewPage-B53YYMng.js.gz +0 -0
- package/dist/dashboard/assets/ProviderDetailPage-B0KaAQf0.js +0 -3
- package/dist/dashboard/assets/ProviderDetailPage-B0KaAQf0.js.gz +0 -0
- package/dist/dashboard/assets/ProvidersPage-Dx31DgIO.js +0 -1
- package/dist/dashboard/assets/ProvidersPage-Dx31DgIO.js.gz +0 -0
- package/dist/dashboard/assets/ProxyPage-BpnR4kXT.js +0 -7
- package/dist/dashboard/assets/ProxyPage-BpnR4kXT.js.gz +0 -0
- package/dist/dashboard/assets/QuotaPage-BpOQCnun.js +0 -1
- package/dist/dashboard/assets/QuotaPage-BpOQCnun.js.gz +0 -0
- package/dist/dashboard/assets/SettingsPage-DV1eo2J_.js +0 -1
- package/dist/dashboard/assets/SettingsPage-DV1eo2J_.js.gz +0 -0
- package/dist/dashboard/assets/SetupPage-D6pmQ86L.js.gz +0 -0
- package/dist/dashboard/assets/SortableList-DWvKiuSl.js.gz +0 -0
- package/dist/dashboard/assets/StudioPage-CmkUrgdj.js.gz +0 -0
- package/dist/dashboard/assets/UsagePage-B47uOydr.js +0 -56
- package/dist/dashboard/assets/UsagePage-B47uOydr.js.gz +0 -0
- package/dist/dashboard/assets/api-keys-uNywYlfv.js +0 -1
- package/dist/dashboard/assets/api-keys-uNywYlfv.js.gz +0 -0
- package/dist/dashboard/assets/app-DxivpfYG.css +0 -2
- package/dist/dashboard/assets/app-DxivpfYG.css.gz +0 -0
- package/dist/dashboard/assets/assert-NHwYq95t.js.gz +0 -0
- package/dist/dashboard/assets/badge-6uzDDvqs.js.gz +0 -0
- package/dist/dashboard/assets/banner-4_WNg2WZ.js.gz +0 -0
- package/dist/dashboard/assets/card--AtFedAq.js.gz +0 -0
- package/dist/dashboard/assets/cli-tools-B3e7dx3N.js.gz +0 -0
- package/dist/dashboard/assets/clipboard-button-NreUx6c8.js.gz +0 -0
- package/dist/dashboard/assets/dialog-BtpsJU98.js +0 -1
- package/dist/dashboard/assets/dialog-BtpsJU98.js.gz +0 -0
- package/dist/dashboard/assets/download-A0SW9OCW.js +0 -1
- package/dist/dashboard/assets/download-A0SW9OCW.js.gz +0 -0
- package/dist/dashboard/assets/drawer-WwwtzihF.js +0 -1
- package/dist/dashboard/assets/drawer-WwwtzihF.js.gz +0 -0
- package/dist/dashboard/assets/entry-CkryrIea.js +0 -4
- package/dist/dashboard/assets/entry-CkryrIea.js.gz +0 -0
- package/dist/dashboard/assets/entry-TJIye_jT.js +0 -1
- package/dist/dashboard/assets/entry-TJIye_jT.js.gz +0 -0
- package/dist/dashboard/assets/entry-jy9_4-Ke.js +0 -1
- package/dist/dashboard/assets/entry-jy9_4-Ke.js.gz +0 -0
- package/dist/dashboard/assets/fingerprint-pattern-BWuHtbW4.js.gz +0 -0
- package/dist/dashboard/assets/github-badge-D_eM3IgG.js.gz +0 -0
- package/dist/dashboard/assets/index-BydyKaDz.js.gz +0 -0
- package/dist/dashboard/assets/inline-BcNGF8Gr.js.gz +0 -0
- package/dist/dashboard/assets/input-BG41et9G.js.gz +0 -0
- package/dist/dashboard/assets/layout-C8mer_Ak.js +0 -1
- package/dist/dashboard/assets/layout-C8mer_Ak.js.gz +0 -0
- package/dist/dashboard/assets/list-row-Gh_W4OR_.js.gz +0 -0
- package/dist/dashboard/assets/live-BJGYRBnR.js.gz +0 -0
- package/dist/dashboard/assets/model-bans-DeVLDA7I.js +0 -1
- package/dist/dashboard/assets/model-bans-DeVLDA7I.js.gz +0 -0
- package/dist/dashboard/assets/mutation-BkoLM5Ba.js.gz +0 -0
- package/dist/dashboard/assets/numbers-Bs4LOOuf.js +0 -2
- package/dist/dashboard/assets/numbers-Bs4LOOuf.js.gz +0 -0
- package/dist/dashboard/assets/query-keys-D7wX2vM5.js.gz +0 -0
- package/dist/dashboard/assets/routing-CcusqXA7.js.gz +0 -0
- package/dist/dashboard/assets/select-BO6h8yNv.js.gz +0 -0
- package/dist/dashboard/assets/settings-mpmXTgUa.js.gz +0 -0
- package/dist/dashboard/assets/sparkles-BRaRUxAU.js +0 -1
- package/dist/dashboard/assets/sparkles-BRaRUxAU.js.gz +0 -0
- package/dist/dashboard/assets/stack-DwLmjUFK.js.gz +0 -0
- package/dist/dashboard/assets/state-DYdQmdAl.js.gz +0 -0
- package/dist/dashboard/assets/switch-CidSfbG7.js +0 -1
- package/dist/dashboard/assets/switch-CidSfbG7.js.gz +0 -0
- package/dist/dashboard/assets/terminal-Bd4ee8TA.js +0 -1
- package/dist/dashboard/assets/terminal-Bd4ee8TA.js.gz +0 -0
- package/dist/dashboard/assets/tokens-DDxMbSRL.js +0 -1
- package/dist/dashboard/assets/tokens-DDxMbSRL.js.gz +0 -0
- package/dist/dashboard/assets/use-presence-BSZEBx7U.js +0 -1
- package/dist/dashboard/assets/use-presence-BSZEBx7U.js.gz +0 -0
- package/dist/dashboard/assets/useMutation-w4u4CVue.js.gz +0 -0
- package/scripts/cli/command/admin.ts +0 -65
- package/scripts/cli/command/doctor.ts +0 -257
- package/scripts/cli/command/update.ts +0 -23
- package/scripts/cli/gateway/drain-token.ts +0 -78
- package/scripts/cli/gateway/instance-lock.ts +0 -105
- package/scripts/cli/gateway/stop.ts +0 -51
- package/scripts/cli/support/bun.ts +0 -27
- package/scripts/cli/support/version.ts +0 -37
- /package/dist/dashboard/assets/{app-CafWtVXA.js → app-BIt446yE.js} +0 -0
- /package/dist/dashboard/assets/{app-CafWtVXA.js.gz → app-BIt446yE.js.gz} +0 -0
- /package/scripts/cli/{ui/prompt.ts → prompt.ts} +0 -0
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import{a as e,i as t,n,o as r,r as i,t as a}from"./jsx-runtime-CXUMngI_.js";import{i as o}from"./terminal-0_IjPWTk.js";import{i as s,n as c,r as l,t as u}from"./drawer-CX7N8ucR.js";import{a as d,i as f,t as p}from"./model-bans-CmffjLuG.js";import{E as m,O as h,T as g,c as _,h as v,i as y,m as b,n as x,r as S,s as C,t as w}from"./numbers-DkfMR5Qs.js";import{t as T}from"./circle-check-BU3v_mFW.js";import{t as E}from"./cog-CdWhsajs.js";import{t as D}from"./database-Dz9N3zGd.js";import{t as O}from"./eye-off-Bk5g2luF.js";import{t as k}from"./eye-C_hawfH4.js";import{t as A}from"./image-BPaouViG.js";import{n as j,r as M,t as N}from"./state-mPDRlQkl.js";import{t as ee}from"./log-in-BmRjy60c.js";import{i as te}from"./use-modal-focus-By7oJoGd.js";import{t as ne}from"./route-CNSNj9Zm.js";import{t as re}from"./scaling-nWE4Cx8f.js";import{t as ie}from"./wrench-B6E1oEuY.js";import{S as ae}from"./assert-C9FD_JwJ.js";import{l as oe,o as se}from"./query-keys-BFhGpwR1.js";import{F as ce,I as le,M as ue,N as de,P as fe,_ as pe,it as me,lt as he,m as P,tt as ge}from"./entry-DxBHnauy.js";import{t as _e}from"./use-reduced-motion-C4B0R6Sz.js";import{n as ve,r as ye,t as be}from"./card-DS7CQEsO.js";import{n as xe}from"./download-dRFo5_Wu.js";import{a as Se,m as Ce,o as we,p as Te,t as Ee,u as De}from"./tokens-COzario9.js";import{t as Oe}from"./select-BYR_5K2c.js";import{t as ke}from"./stack-BHTfXdz_.js";import{n as Ae}from"./inline-BhY2sSnO.js";import{r as je,t as Me}from"./layout-BBOYycyS.js";import{n as Ne}from"./privacy-mode-GM8bej85.js";import{t as Pe}from"./use-timeout-BwcBBRrT.js";import{t as Fe}from"./banner-CI9_eSfO.js";import{r as Ie,t as Le}from"./live-BivGfuUs.js";var Re=n(`arrow-up-from-line`,[[`path`,{d:`m18 9-6-6-6 6`,key:`kcunyi`}],[`path`,{d:`M12 3v14`,key:`7cf3v8`}],[`path`,{d:`M5 21h14`,key:`11awu3`}]]),ze=n(`coins`,[[`path`,{d:`M13.744 17.736a6 6 0 1 1-7.48-7.48`,key:`bq4yh3`}],[`path`,{d:`M15 6h1v4`,key:`11y1tn`}],[`path`,{d:`m6.134 14.768.866-.5 2 3.464`,key:`17snzx`}],[`circle`,{cx:`16`,cy:`8`,r:`6`,key:`14bfc9`}]]),Be=n(`dollar-sign`,[[`line`,{x1:`12`,x2:`12`,y1:`2`,y2:`22`,key:`7eqyqh`}],[`path`,{d:`M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6`,key:`1b0p4s`}]]),Ve=n(`radio`,[[`path`,{d:`M16.247 7.761a6 6 0 0 1 0 8.478`,key:`1fwjs5`}],[`path`,{d:`M19.075 4.933a10 10 0 0 1 0 14.134`,key:`ehdyv1`}],[`path`,{d:`M4.925 19.067a10 10 0 0 1 0-14.134`,key:`1q22gi`}],[`path`,{d:`M7.753 16.239a6 6 0 0 1 0-8.478`,key:`r2q7qm`}],[`circle`,{cx:`12`,cy:`12`,r:`2`,key:`1c9p78`}]]),He=t(((e,t)=>{t.exports=Array.isArray})),Ue=t(((e,t)=>{t.exports=typeof global==`object`&&global&&global.Object===Object&&global})),We=t(((e,t)=>{var n=Ue(),r=typeof self==`object`&&self&&self.Object===Object&&self;t.exports=n||r||Function(`return this`)()})),Ge=t(((e,t)=>{t.exports=We().Symbol})),Ke=t(((e,t)=>{var n=Ge(),r=Object.prototype,i=r.hasOwnProperty,a=r.toString,o=n?n.toStringTag:void 0;function s(e){var t=i.call(e,o),n=e[o];try{e[o]=void 0;var r=!0}catch{}var s=a.call(e);return r&&(t?e[o]=n:delete e[o]),s}t.exports=s})),qe=t(((e,t)=>{var n=Object.prototype.toString;function r(e){return n.call(e)}t.exports=r})),Je=t(((e,t)=>{var n=Ge(),r=Ke(),i=qe(),a=`[object Null]`,o=`[object Undefined]`,s=n?n.toStringTag:void 0;function c(e){return e==null?e===void 0?o:a:s&&s in Object(e)?r(e):i(e)}t.exports=c})),Ye=t(((e,t)=>{function n(e){return typeof e==`object`&&!!e}t.exports=n})),Xe=t(((e,t)=>{var n=Je(),r=Ye(),i=`[object Symbol]`;function a(e){return typeof e==`symbol`||r(e)&&n(e)==i}t.exports=a})),Ze=t(((e,t)=>{var n=He(),r=Xe(),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;function o(e,t){if(n(e))return!1;var o=typeof e;return o==`number`||o==`symbol`||o==`boolean`||e==null||r(e)?!0:a.test(e)||!i.test(e)||t!=null&&e in Object(t)}t.exports=o})),Qe=t(((e,t)=>{function n(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}t.exports=n})),$e=t(((e,t)=>{var n=Je(),r=Qe(),i=`[object AsyncFunction]`,a=`[object Function]`,o=`[object GeneratorFunction]`,s=`[object Proxy]`;function c(e){if(!r(e))return!1;var t=n(e);return t==a||t==o||t==i||t==s}t.exports=c})),et=t(((e,t)=>{t.exports=We()[`__core-js_shared__`]})),tt=t(((e,t)=>{var n=et(),r=function(){var e=/[^.]+$/.exec(n&&n.keys&&n.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``}();function i(e){return!!r&&r in e}t.exports=i})),nt=t(((e,t)=>{var n=Function.prototype.toString;function r(e){if(e!=null){try{return n.call(e)}catch{}try{return e+``}catch{}}return``}t.exports=r})),rt=t(((e,t)=>{var n=$e(),r=tt(),i=Qe(),a=nt(),o=/[\\^$.*+?()[\]{}|]/g,s=/^\[object .+?Constructor\]$/,c=Function.prototype,l=Object.prototype,u=c.toString,d=l.hasOwnProperty,f=RegExp(`^`+u.call(d).replace(o,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`);function p(e){return!i(e)||r(e)?!1:(n(e)?f:s).test(a(e))}t.exports=p})),it=t(((e,t)=>{function n(e,t){return e?.[t]}t.exports=n})),at=t(((e,t)=>{var n=rt(),r=it();function i(e,t){var i=r(e,t);return n(i)?i:void 0}t.exports=i})),ot=t(((e,t)=>{t.exports=at()(Object,`create`)})),st=t(((e,t)=>{var n=ot();function r(){this.__data__=n?n(null):{},this.size=0}t.exports=r})),ct=t(((e,t)=>{function n(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}t.exports=n})),lt=t(((e,t)=>{var n=ot(),r=`__lodash_hash_undefined__`,i=Object.prototype.hasOwnProperty;function a(e){var t=this.__data__;if(n){var a=t[e];return a===r?void 0:a}return i.call(t,e)?t[e]:void 0}t.exports=a})),ut=t(((e,t)=>{var n=ot(),r=Object.prototype.hasOwnProperty;function i(e){var t=this.__data__;return n?t[e]!==void 0:r.call(t,e)}t.exports=i})),dt=t(((e,t)=>{var n=ot(),r=`__lodash_hash_undefined__`;function i(e,t){var i=this.__data__;return this.size+=+!this.has(e),i[e]=n&&t===void 0?r:t,this}t.exports=i})),ft=t(((e,t)=>{var n=st(),r=ct(),i=lt(),a=ut(),o=dt();function s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}s.prototype.clear=n,s.prototype.delete=r,s.prototype.get=i,s.prototype.has=a,s.prototype.set=o,t.exports=s})),pt=t(((e,t)=>{function n(){this.__data__=[],this.size=0}t.exports=n})),mt=t(((e,t)=>{function n(e,t){return e===t||e!==e&&t!==t}t.exports=n})),ht=t(((e,t)=>{var n=mt();function r(e,t){for(var r=e.length;r--;)if(n(e[r][0],t))return r;return-1}t.exports=r})),gt=t(((e,t)=>{var n=ht(),r=Array.prototype.splice;function i(e){var t=this.__data__,i=n(t,e);return i<0?!1:(i==t.length-1?t.pop():r.call(t,i,1),--this.size,!0)}t.exports=i})),_t=t(((e,t)=>{var n=ht();function r(e){var t=this.__data__,r=n(t,e);return r<0?void 0:t[r][1]}t.exports=r})),vt=t(((e,t)=>{var n=ht();function r(e){return n(this.__data__,e)>-1}t.exports=r})),yt=t(((e,t)=>{var n=ht();function r(e,t){var r=this.__data__,i=n(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this}t.exports=r})),bt=t(((e,t)=>{var n=pt(),r=gt(),i=_t(),a=vt(),o=yt();function s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}s.prototype.clear=n,s.prototype.delete=r,s.prototype.get=i,s.prototype.has=a,s.prototype.set=o,t.exports=s})),xt=t(((e,t)=>{t.exports=at()(We(),`Map`)})),St=t(((e,t)=>{var n=ft(),r=bt(),i=xt();function a(){this.size=0,this.__data__={hash:new n,map:new(i||r),string:new n}}t.exports=a})),Ct=t(((e,t)=>{function n(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}t.exports=n})),wt=t(((e,t)=>{var n=Ct();function r(e,t){var r=e.__data__;return n(t)?r[typeof t==`string`?`string`:`hash`]:r.map}t.exports=r})),Tt=t(((e,t)=>{var n=wt();function r(e){var t=n(this,e).delete(e);return this.size-=+!!t,t}t.exports=r})),Et=t(((e,t)=>{var n=wt();function r(e){return n(this,e).get(e)}t.exports=r})),Dt=t(((e,t)=>{var n=wt();function r(e){return n(this,e).has(e)}t.exports=r})),Ot=t(((e,t)=>{var n=wt();function r(e,t){var r=n(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this}t.exports=r})),kt=t(((e,t)=>{var n=St(),r=Tt(),i=Et(),a=Dt(),o=Ot();function s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}s.prototype.clear=n,s.prototype.delete=r,s.prototype.get=i,s.prototype.has=a,s.prototype.set=o,t.exports=s})),At=t(((e,t)=>{var n=kt(),r=`Expected a function`;function i(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(r);var a=function(){var n=arguments,r=t?t.apply(this,n):n[0],i=a.cache;if(i.has(r))return i.get(r);var o=e.apply(this,n);return a.cache=i.set(r,o)||i,o};return a.cache=new(i.Cache||n),a}i.Cache=n,t.exports=i})),jt=t(((e,t)=>{var n=At(),r=500;function i(e){var t=n(e,function(e){return i.size===r&&i.clear(),e}),i=t.cache;return t}t.exports=i})),Mt=t(((e,t)=>{var n=jt(),r=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g;t.exports=n(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(``),e.replace(r,function(e,n,r,a){t.push(r?a.replace(i,`$1`):n||e)}),t})})),Nt=t(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}t.exports=n})),Pt=t(((e,t)=>{var n=Ge(),r=Nt(),i=He(),a=Xe(),o=1/0,s=n?n.prototype:void 0,c=s?s.toString:void 0;function l(e){if(typeof e==`string`)return e;if(i(e))return r(e,l)+``;if(a(e))return c?c.call(e):``;var t=e+``;return t==`0`&&1/e==-o?`-0`:t}t.exports=l})),Ft=t(((e,t)=>{var n=Pt();function r(e){return e==null?``:n(e)}t.exports=r})),It=t(((e,t)=>{var n=He(),r=Ze(),i=Mt(),a=Ft();function o(e,t){return n(e)?e:r(e,t)?[e]:i(a(e))}t.exports=o})),Lt=t(((e,t)=>{var n=Xe(),r=1/0;function i(e){if(typeof e==`string`||n(e))return e;var t=e+``;return t==`0`&&1/e==-r?`-0`:t}t.exports=i})),Rt=t(((e,t)=>{var n=It(),r=Lt();function i(e,t){t=n(t,e);for(var i=0,a=t.length;e!=null&&i<a;)e=e[r(t[i++])];return i&&i==a?e:void 0}t.exports=i})),zt=t(((e,t)=>{var n=Rt();function r(e,t,r){var i=e==null?void 0:n(e,t);return i===void 0?r:i}t.exports=r})),Bt=t(((e,t)=>{function n(e){return e==null}t.exports=n})),Vt=t(((e,t)=>{var n=Je(),r=He(),i=Ye(),a=`[object String]`;function o(e){return typeof e==`string`||!r(e)&&i(e)&&n(e)==a}t.exports=o})),Ht=t((e=>{var t=Symbol.for(`react.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.provider`),s=Symbol.for(`react.context`),c=Symbol.for(`react.server_context`),l=Symbol.for(`react.forward_ref`),u=Symbol.for(`react.suspense`),d=Symbol.for(`react.suspense_list`),f=Symbol.for(`react.memo`),p=Symbol.for(`react.lazy`);function m(e){if(typeof e==`object`&&e){var m=e.$$typeof;switch(m){case t:switch(e=e.type,e){case r:case a:case i:case u:case d:return e;default:switch(e&&=e.$$typeof,e){case c:case s:case l:case p:case f:case o:return e;default:return m}}case n:return m}}}e.isFragment=function(e){return m(e)===r}})),Ut=t(((e,t)=>{t.exports=Ht()})),Wt=t(((e,t)=>{var n=Je(),r=Ye(),i=`[object Number]`;function a(e){return typeof e==`number`||r(e)&&n(e)==i}t.exports=a})),Gt=t(((e,t)=>{var n=Wt();function r(e){return n(e)&&e!=+e}t.exports=r})),Kt=r(Vt()),qt=r(Gt()),Jt=r(zt()),Yt=r(Wt()),F=r(Bt()),Xt=function(e){return e===0?0:e>0?1:-1},Zt=function(e){return(0,Kt.default)(e)&&e.indexOf(`%`)===e.length-1},I=function(e){return(0,Yt.default)(e)&&!(0,qt.default)(e)},Qt=function(e){return(0,F.default)(e)},L=function(e){return I(e)||(0,Kt.default)(e)},$t=0,en=function(e){var t=++$t;return`${e||``}${t}`},tn=function(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,r=arguments.length>3&&arguments[3]!==void 0&&arguments[3];if(!I(e)&&!(0,Kt.default)(e))return n;var i;if(Zt(e)){var a=e.indexOf(`%`);i=t*parseFloat(e.slice(0,a))/100}else i=+e;return(0,qt.default)(i)&&(i=n),r&&i>t&&(i=t),i},nn=function(e){if(!e)return null;var t=Object.keys(e);return t&&t.length?e[t[0]]:null},rn=function(e){if(!Array.isArray(e))return!1;for(var t=e.length,n={},r=0;r<t;r++)if(!n[e[r]])n[e[r]]=!0;else return!0;return!1},an=function(e,t){return I(e)&&I(t)?function(n){return e+n*(t-e)}:function(){return t}};function on(e,t,n){return!e||!e.length?null:e.find(function(e){return e&&(typeof t==`function`?t(e):(0,Jt.default)(e,t))===n})}var sn=function(e,t){return I(e)&&I(t)?e-t:(0,Kt.default)(e)&&(0,Kt.default)(t)?e.localeCompare(t):e instanceof Date&&t instanceof Date?e.getTime()-t.getTime():String(e).localeCompare(String(t))};function cn(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}var R=r(i()),ln=r(Qe());function un(e){"@babel/helpers - typeof";return un=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},un(e)}var dn=[`viewBox`,`children`],fn=`aria-activedescendant.aria-atomic.aria-autocomplete.aria-busy.aria-checked.aria-colcount.aria-colindex.aria-colspan.aria-controls.aria-current.aria-describedby.aria-details.aria-disabled.aria-errormessage.aria-expanded.aria-flowto.aria-haspopup.aria-hidden.aria-invalid.aria-keyshortcuts.aria-label.aria-labelledby.aria-level.aria-live.aria-modal.aria-multiline.aria-multiselectable.aria-orientation.aria-owns.aria-placeholder.aria-posinset.aria-pressed.aria-readonly.aria-relevant.aria-required.aria-roledescription.aria-rowcount.aria-rowindex.aria-rowspan.aria-selected.aria-setsize.aria-sort.aria-valuemax.aria-valuemin.aria-valuenow.aria-valuetext.className.color.height.id.lang.max.media.method.min.name.style.target.width.role.tabIndex.accentHeight.accumulate.additive.alignmentBaseline.allowReorder.alphabetic.amplitude.arabicForm.ascent.attributeName.attributeType.autoReverse.azimuth.baseFrequency.baselineShift.baseProfile.bbox.begin.bias.by.calcMode.capHeight.clip.clipPath.clipPathUnits.clipRule.colorInterpolation.colorInterpolationFilters.colorProfile.colorRendering.contentScriptType.contentStyleType.cursor.cx.cy.d.decelerate.descent.diffuseConstant.direction.display.divisor.dominantBaseline.dur.dx.dy.edgeMode.elevation.enableBackground.end.exponent.externalResourcesRequired.fill.fillOpacity.fillRule.filter.filterRes.filterUnits.floodColor.floodOpacity.focusable.fontFamily.fontSize.fontSizeAdjust.fontStretch.fontStyle.fontVariant.fontWeight.format.from.fx.fy.g1.g2.glyphName.glyphOrientationHorizontal.glyphOrientationVertical.glyphRef.gradientTransform.gradientUnits.hanging.horizAdvX.horizOriginX.href.ideographic.imageRendering.in2.in.intercept.k1.k2.k3.k4.k.kernelMatrix.kernelUnitLength.kerning.keyPoints.keySplines.keyTimes.lengthAdjust.letterSpacing.lightingColor.limitingConeAngle.local.markerEnd.markerHeight.markerMid.markerStart.markerUnits.markerWidth.mask.maskContentUnits.maskUnits.mathematical.mode.numOctaves.offset.opacity.operator.order.orient.orientation.origin.overflow.overlinePosition.overlineThickness.paintOrder.panose1.pathLength.patternContentUnits.patternTransform.patternUnits.pointerEvents.pointsAtX.pointsAtY.pointsAtZ.preserveAlpha.preserveAspectRatio.primitiveUnits.r.radius.refX.refY.renderingIntent.repeatCount.repeatDur.requiredExtensions.requiredFeatures.restart.result.rotate.rx.ry.seed.shapeRendering.slope.spacing.specularConstant.specularExponent.speed.spreadMethod.startOffset.stdDeviation.stemh.stemv.stitchTiles.stopColor.stopOpacity.strikethroughPosition.strikethroughThickness.string.stroke.strokeDasharray.strokeDashoffset.strokeLinecap.strokeLinejoin.strokeMiterlimit.strokeOpacity.strokeWidth.surfaceScale.systemLanguage.tableValues.targetX.targetY.textAnchor.textDecoration.textLength.textRendering.to.transform.u1.u2.underlinePosition.underlineThickness.unicode.unicodeBidi.unicodeRange.unitsPerEm.vAlphabetic.values.vectorEffect.version.vertAdvY.vertOriginX.vertOriginY.vHanging.vIdeographic.viewTarget.visibility.vMathematical.widths.wordSpacing.writingMode.x1.x2.x.xChannelSelector.xHeight.xlinkActuate.xlinkArcrole.xlinkHref.xlinkRole.xlinkShow.xlinkTitle.xlinkType.xmlBase.xmlLang.xmlns.xmlnsXlink.xmlSpace.y1.y2.y.yChannelSelector.z.zoomAndPan.ref.key.angle`.split(`.`),pn=[`points`,`pathLength`],mn={svg:dn,polygon:pn,polyline:pn},hn=`dangerouslySetInnerHTML.onCopy.onCopyCapture.onCut.onCutCapture.onPaste.onPasteCapture.onCompositionEnd.onCompositionEndCapture.onCompositionStart.onCompositionStartCapture.onCompositionUpdate.onCompositionUpdateCapture.onFocus.onFocusCapture.onBlur.onBlurCapture.onChange.onChangeCapture.onBeforeInput.onBeforeInputCapture.onInput.onInputCapture.onReset.onResetCapture.onSubmit.onSubmitCapture.onInvalid.onInvalidCapture.onLoad.onLoadCapture.onError.onErrorCapture.onKeyDown.onKeyDownCapture.onKeyPress.onKeyPressCapture.onKeyUp.onKeyUpCapture.onAbort.onAbortCapture.onCanPlay.onCanPlayCapture.onCanPlayThrough.onCanPlayThroughCapture.onDurationChange.onDurationChangeCapture.onEmptied.onEmptiedCapture.onEncrypted.onEncryptedCapture.onEnded.onEndedCapture.onLoadedData.onLoadedDataCapture.onLoadedMetadata.onLoadedMetadataCapture.onLoadStart.onLoadStartCapture.onPause.onPauseCapture.onPlay.onPlayCapture.onPlaying.onPlayingCapture.onProgress.onProgressCapture.onRateChange.onRateChangeCapture.onSeeked.onSeekedCapture.onSeeking.onSeekingCapture.onStalled.onStalledCapture.onSuspend.onSuspendCapture.onTimeUpdate.onTimeUpdateCapture.onVolumeChange.onVolumeChangeCapture.onWaiting.onWaitingCapture.onAuxClick.onAuxClickCapture.onClick.onClickCapture.onContextMenu.onContextMenuCapture.onDoubleClick.onDoubleClickCapture.onDrag.onDragCapture.onDragEnd.onDragEndCapture.onDragEnter.onDragEnterCapture.onDragExit.onDragExitCapture.onDragLeave.onDragLeaveCapture.onDragOver.onDragOverCapture.onDragStart.onDragStartCapture.onDrop.onDropCapture.onMouseDown.onMouseDownCapture.onMouseEnter.onMouseLeave.onMouseMove.onMouseMoveCapture.onMouseOut.onMouseOutCapture.onMouseOver.onMouseOverCapture.onMouseUp.onMouseUpCapture.onSelect.onSelectCapture.onTouchCancel.onTouchCancelCapture.onTouchEnd.onTouchEndCapture.onTouchMove.onTouchMoveCapture.onTouchStart.onTouchStartCapture.onPointerDown.onPointerDownCapture.onPointerMove.onPointerMoveCapture.onPointerUp.onPointerUpCapture.onPointerCancel.onPointerCancelCapture.onPointerEnter.onPointerEnterCapture.onPointerLeave.onPointerLeaveCapture.onPointerOver.onPointerOverCapture.onPointerOut.onPointerOutCapture.onGotPointerCapture.onGotPointerCaptureCapture.onLostPointerCapture.onLostPointerCaptureCapture.onScroll.onScrollCapture.onWheel.onWheelCapture.onAnimationStart.onAnimationStartCapture.onAnimationEnd.onAnimationEndCapture.onAnimationIteration.onAnimationIterationCapture.onTransitionEnd.onTransitionEndCapture`.split(`.`),gn=function(e,t){if(!e||typeof e==`function`||typeof e==`boolean`)return null;var n=e;if((0,R.isValidElement)(e)&&(n=e.props),!(0,ln.default)(n))return null;var r={};return Object.keys(n).forEach(function(e){hn.includes(e)&&(r[e]=t||function(t){return n[e](n,t)})}),r},_n=function(e,t,n){return function(r){return e(t,n,r),null}},vn=function(e,t,n){if(!(0,ln.default)(e)||un(e)!==`object`)return null;var r=null;return Object.keys(e).forEach(function(i){var a=e[i];hn.includes(i)&&typeof a==`function`&&(r||={},r[i]=_n(a,t,n))}),r},z=r($e()),yn=Ut(),bn=[`children`],xn=[`children`];function Sn(e,t){if(e==null)return{};var n=Cn(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Cn(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function wn(e){"@babel/helpers - typeof";return wn=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},wn(e)}var Tn={click:`onClick`,mousedown:`onMouseDown`,mouseup:`onMouseUp`,mouseover:`onMouseOver`,mousemove:`onMouseMove`,mouseout:`onMouseOut`,mouseenter:`onMouseEnter`,mouseleave:`onMouseLeave`,touchcancel:`onTouchCancel`,touchend:`onTouchEnd`,touchmove:`onTouchMove`,touchstart:`onTouchStart`,contextmenu:`onContextMenu`,dblclick:`onDoubleClick`},En=function(e){return typeof e==`string`?e:e?e.displayName||e.name||`Component`:``},Dn=null,On=null,kn=function e(t){if(t===Dn&&Array.isArray(On))return On;var n=[];return R.Children.forEach(t,function(t){(0,F.default)(t)||((0,yn.isFragment)(t)?n=n.concat(e(t.props.children)):n.push(t))}),On=n,Dn=t,n};function An(e,t){var n=[],r=[];return r=Array.isArray(t)?t.map(function(e){return En(e)}):[En(t)],kn(e).forEach(function(e){var t=(0,Jt.default)(e,`type.displayName`)||(0,Jt.default)(e,`type.name`);r.indexOf(t)!==-1&&n.push(e)}),n}function jn(e,t){var n=An(e,t);return n&&n[0]}var Mn=function(e){if(!e||!e.props)return!1;var t=e.props,n=t.width,r=t.height;return!(!I(n)||n<=0||!I(r)||r<=0)},Nn=`a.altGlyph.altGlyphDef.altGlyphItem.animate.animateColor.animateMotion.animateTransform.circle.clipPath.color-profile.cursor.defs.desc.ellipse.feBlend.feColormatrix.feComponentTransfer.feComposite.feConvolveMatrix.feDiffuseLighting.feDisplacementMap.feDistantLight.feFlood.feFuncA.feFuncB.feFuncG.feFuncR.feGaussianBlur.feImage.feMerge.feMergeNode.feMorphology.feOffset.fePointLight.feSpecularLighting.feSpotLight.feTile.feTurbulence.filter.font.font-face.font-face-format.font-face-name.font-face-url.foreignObject.g.glyph.glyphRef.hkern.image.line.lineGradient.marker.mask.metadata.missing-glyph.mpath.path.pattern.polygon.polyline.radialGradient.rect.script.set.stop.style.svg.switch.symbol.text.textPath.title.tref.tspan.use.view.vkern`.split(`.`),Pn=function(e){return e&&e.type&&(0,Kt.default)(e.type)&&Nn.indexOf(e.type)>=0},Fn=function(e){return e&&wn(e)===`object`&&`clipDot`in e},In=function(e,t,n,r){var i=mn?.[r]??[];return t.startsWith(`data-`)||!(0,z.default)(e)&&(r&&i.includes(t)||fn.includes(t))||n&&hn.includes(t)},B=function(e,t,n){if(!e||typeof e==`function`||typeof e==`boolean`)return null;var r=e;if((0,R.isValidElement)(e)&&(r=e.props),!(0,ln.default)(r))return null;var i={};return Object.keys(r).forEach(function(e){In(r?.[e],e,t,n)&&(i[e]=r[e])}),i},Ln=function e(t,n){if(t===n)return!0;var r=R.Children.count(t);if(r!==R.Children.count(n))return!1;if(r===0)return!0;if(r===1)return Rn(Array.isArray(t)?t[0]:t,Array.isArray(n)?n[0]:n);for(var i=0;i<r;i++){var a=t[i],o=n[i];if(Array.isArray(a)||Array.isArray(o)){if(!e(a,o))return!1}else if(!Rn(a,o))return!1}return!0},Rn=function(e,t){if((0,F.default)(e)&&(0,F.default)(t))return!0;if(!(0,F.default)(e)&&!(0,F.default)(t)){var n=e.props||{},r=n.children,i=Sn(n,bn),a=t.props||{},o=a.children,s=Sn(a,xn);return r&&o?cn(i,s)&&Ln(r,o):!r&&!o&&cn(i,s)}return!1},zn=function(e,t){var n=[],r={};return kn(e).forEach(function(e,i){if(Pn(e))n.push(e);else if(e){var a=En(e.type),o=t[a]||{},s=o.handler,c=o.once;if(s&&(!c||!r[a])){var l=s(e,a,i);n.push(l),r[a]=!0}}}),n},Bn=function(e){var t=e&&e.type;return t&&Tn[t]?Tn[t]:null},Vn=function(e,t){return kn(t).indexOf(e)},Hn=[`children`,`width`,`height`,`viewBox`,`className`,`style`,`title`,`desc`];function Un(){return Un=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Un.apply(this,arguments)}function Wn(e,t){if(e==null)return{};var n=Gn(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Gn(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Kn(e){var t=e.children,n=e.width,r=e.height,i=e.viewBox,a=e.className,o=e.style,s=e.title,c=e.desc,l=Wn(e,Hn),u=i||{width:n,height:r,x:0,y:0},d=v(`recharts-surface`,a);return R.createElement(`svg`,Un({},B(l,!0,`svg`),{className:d,width:n,height:r,style:o,viewBox:`${u.x} ${u.y} ${u.width} ${u.height}`}),R.createElement(`title`,null,s),R.createElement(`desc`,null,c),t)}var qn=[`children`,`className`];function Jn(){return Jn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Jn.apply(this,arguments)}function Yn(e,t){if(e==null)return{};var n=Xn(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Xn(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var V=R.forwardRef(function(e,t){var n=e.children,r=e.className,i=Yn(e,qn),a=v(`recharts-layer`,r);return R.createElement(`g`,Jn({className:a},B(i,!0),{ref:t}),n)}),Zn=t(((e,t)=>{function n(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(i);++r<i;)a[r]=e[r+t];return a}t.exports=n})),Qn=t(((e,t)=>{var n=Zn();function r(e,t,r){var i=e.length;return r=r===void 0?i:r,!t&&r>=i?e:n(e,t,r)}t.exports=r})),$n=t(((e,t)=>{var n=RegExp(`[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]`);function r(e){return n.test(e)}t.exports=r})),er=t(((e,t)=>{function n(e){return e.split(``)}t.exports=n})),tr=t(((e,t)=>{var n=`\\ud800-\\udfff`,r=`\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff`,i=`\\ufe0e\\ufe0f`,a=`[`+n+`]`,o=`[`+r+`]`,s=`\\ud83c[\\udffb-\\udfff]`,c=`(?:`+o+`|`+s+`)`,l=`[^`+n+`]`,u=`(?:\\ud83c[\\udde6-\\uddff]){2}`,d=`[\\ud800-\\udbff][\\udc00-\\udfff]`,f=`\\u200d`,p=c+`?`,m=`[`+i+`]?`,h=`(?:`+f+`(?:`+[l,u,d].join(`|`)+`)`+m+p+`)*`,g=m+p+h,_=`(?:`+[l+o+`?`,o,u,d,a].join(`|`)+`)`,v=RegExp(s+`(?=`+s+`)|`+_+g,`g`);function y(e){return e.match(v)||[]}t.exports=y})),nr=t(((e,t)=>{var n=er(),r=$n(),i=tr();function a(e){return r(e)?i(e):n(e)}t.exports=a})),rr=t(((e,t)=>{var n=Qn(),r=$n(),i=nr(),a=Ft();function o(e){return function(t){t=a(t);var o=r(t)?i(t):void 0,s=o?o[0]:t.charAt(0),c=o?n(o,1).join(``):t.slice(1);return s[e]()+c}}t.exports=o})),ir=t(((e,t)=>{t.exports=rr()(`toUpperCase`)}));function H(e){return function(){return e}}var ar=Math.cos,or=Math.sin,sr=Math.sqrt,cr=Math.PI;cr/2;var lr=2*cr,ur=Math.PI,dr=2*ur,fr=1e-6,pr=dr-fr;function mr(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function hr(e){let t=Math.floor(e);if(!(t>=0))throw Error(`invalid digits: ${e}`);if(t>15)return mr;let n=10**t;return function(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=Math.round(arguments[t]*n)/n+e[t]}}var gr=class{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._=``,this._append=e==null?mr:hr(e)}moveTo(e,t){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,t){this._append`L${this._x1=+e},${this._y1=+t}`}quadraticCurveTo(e,t,n,r){this._append`Q${+e},${+t},${this._x1=+n},${this._y1=+r}`}bezierCurveTo(e,t,n,r,i,a){this._append`C${+e},${+t},${+n},${+r},${this._x1=+i},${this._y1=+a}`}arcTo(e,t,n,r,i){if(e=+e,t=+t,n=+n,r=+r,i=+i,i<0)throw Error(`negative radius: ${i}`);let a=this._x1,o=this._y1,s=n-e,c=r-t,l=a-e,u=o-t,d=l*l+u*u;if(this._x1===null)this._append`M${this._x1=e},${this._y1=t}`;else if(d>fr){if(!(Math.abs(u*s-c*l)>fr)||!i)this._append`L${this._x1=e},${this._y1=t}`;else{let f=n-a,p=r-o,m=s*s+c*c,h=f*f+p*p,g=Math.sqrt(m),_=Math.sqrt(d),v=i*Math.tan((ur-Math.acos((m+d-h)/(2*g*_)))/2),y=v/_,b=v/g;Math.abs(y-1)>fr&&this._append`L${e+y*l},${t+y*u}`,this._append`A${i},${i},0,0,${+(u*f>l*p)},${this._x1=e+b*s},${this._y1=t+b*c}`}}}arc(e,t,n,r,i,a){if(e=+e,t=+t,n=+n,a=!!a,n<0)throw Error(`negative radius: ${n}`);let o=n*Math.cos(r),s=n*Math.sin(r),c=e+o,l=t+s,u=1^a,d=a?r-i:i-r;this._x1===null?this._append`M${c},${l}`:(Math.abs(this._x1-c)>fr||Math.abs(this._y1-l)>fr)&&this._append`L${c},${l}`,n&&(d<0&&(d=d%dr+dr),d>pr?this._append`A${n},${n},0,1,${u},${e-o},${t-s}A${n},${n},0,1,${u},${this._x1=c},${this._y1=l}`:d>fr&&this._append`A${n},${n},0,${+(d>=ur)},${u},${this._x1=e+n*Math.cos(i)},${this._y1=t+n*Math.sin(i)}`)}rect(e,t,n,r){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}};gr.prototype;function _r(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{let e=Math.floor(n);if(!(e>=0))throw RangeError(`invalid digits: ${n}`);t=e}return e},()=>new gr(t)}Array.prototype.slice;function vr(e){return typeof e==`object`&&`length`in e?e:Array.from(e)}function yr(e){this._context=e}yr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}};function br(e){return new yr(e)}function xr(e){return e[0]}function Sr(e){return e[1]}function Cr(e,t){var n=H(!0),r=null,i=br,a=null,o=_r(s);e=typeof e==`function`?e:e===void 0?xr:H(e),t=typeof t==`function`?t:t===void 0?Sr:H(t);function s(s){var c,l=(s=vr(s)).length,u,d=!1,f;for(r??(a=i(f=o())),c=0;c<=l;++c)!(c<l&&n(u=s[c],c,s))===d&&((d=!d)?a.lineStart():a.lineEnd()),d&&a.point(+e(u,c,s),+t(u,c,s));if(f)return a=null,f+``||null}return s.x=function(t){return arguments.length?(e=typeof t==`function`?t:H(+t),s):e},s.y=function(e){return arguments.length?(t=typeof e==`function`?e:H(+e),s):t},s.defined=function(e){return arguments.length?(n=typeof e==`function`?e:H(!!e),s):n},s.curve=function(e){return arguments.length?(i=e,r!=null&&(a=i(r)),s):i},s.context=function(e){return arguments.length?(e==null?r=a=null:a=i(r=e),s):r},s}function wr(e,t,n){var r=null,i=H(!0),a=null,o=br,s=null,c=_r(l);e=typeof e==`function`?e:e===void 0?xr:H(+e),t=typeof t==`function`?t:H(t===void 0?0:+t),n=typeof n==`function`?n:n===void 0?Sr:H(+n);function l(l){var u,d,f,p=(l=vr(l)).length,m,h=!1,g,_=Array(p),v=Array(p);for(a??(s=o(g=c())),u=0;u<=p;++u){if(!(u<p&&i(m=l[u],u,l))===h){if(h=!h)d=u,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),f=u-1;f>=d;--f)s.point(_[f],v[f]);s.lineEnd(),s.areaEnd()}}h&&(_[u]=+e(m,u,l),v[u]=+t(m,u,l),s.point(r?+r(m,u,l):_[u],n?+n(m,u,l):v[u]))}if(g)return s=null,g+``||null}function u(){return Cr().defined(i).curve(o).context(a)}return l.x=function(t){return arguments.length?(e=typeof t==`function`?t:H(+t),r=null,l):e},l.x0=function(t){return arguments.length?(e=typeof t==`function`?t:H(+t),l):e},l.x1=function(e){return arguments.length?(r=e==null?null:typeof e==`function`?e:H(+e),l):r},l.y=function(e){return arguments.length?(t=typeof e==`function`?e:H(+e),n=null,l):t},l.y0=function(e){return arguments.length?(t=typeof e==`function`?e:H(+e),l):t},l.y1=function(e){return arguments.length?(n=e==null?null:typeof e==`function`?e:H(+e),l):n},l.lineX0=l.lineY0=function(){return u().x(e).y(t)},l.lineY1=function(){return u().x(e).y(n)},l.lineX1=function(){return u().x(r).y(t)},l.defined=function(e){return arguments.length?(i=typeof e==`function`?e:H(!!e),l):i},l.curve=function(e){return arguments.length?(o=e,a!=null&&(s=o(a)),l):o},l.context=function(e){return arguments.length?(e==null?a=s=null:s=o(a=e),l):a},l}var Tr=class{constructor(e,t){this._context=e,this._x=t}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,t,e,t):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+t)/2,e,this._y0,e,t)}this._x0=e,this._y0=t}};function Er(e){return new Tr(e,!0)}function Dr(e){return new Tr(e,!1)}var Or={draw(e,t){let n=sr(t/cr);e.moveTo(n,0),e.arc(0,0,n,0,lr)}},kr={draw(e,t){let n=sr(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},Ar=sr(1/3),jr=Ar*2,Mr={draw(e,t){let n=sr(t/jr),r=n*Ar;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},Nr={draw(e,t){let n=sr(t),r=-n/2;e.rect(r,r,n,n)}},Pr=.8908130915292852,Fr=or(cr/10)/or(7*cr/10),Ir=or(lr/10)*Fr,Lr=-ar(lr/10)*Fr,Rr={draw(e,t){let n=sr(t*Pr),r=Ir*n,i=Lr*n;e.moveTo(0,-n),e.lineTo(r,i);for(let t=1;t<5;++t){let a=lr*t/5,o=ar(a),s=or(a);e.lineTo(s*n,-o*n),e.lineTo(o*r-s*i,s*r+o*i)}e.closePath()}},zr=sr(3),Br={draw(e,t){let n=-sr(t/(zr*3));e.moveTo(0,n*2),e.lineTo(-zr*n,-n),e.lineTo(zr*n,-n),e.closePath()}},Vr=-.5,Hr=sr(3)/2,Ur=1/sr(12),Wr=(Ur/2+1)*3,Gr={draw(e,t){let n=sr(t/Wr),r=n/2,i=n*Ur,a=r,o=n*Ur+n,s=-a,c=o;e.moveTo(r,i),e.lineTo(a,o),e.lineTo(s,c),e.lineTo(Vr*r-Hr*i,Hr*r+Vr*i),e.lineTo(Vr*a-Hr*o,Hr*a+Vr*o),e.lineTo(Vr*s-Hr*c,Hr*s+Vr*c),e.lineTo(Vr*r+Hr*i,Vr*i-Hr*r),e.lineTo(Vr*a+Hr*o,Vr*o-Hr*a),e.lineTo(Vr*s+Hr*c,Vr*c-Hr*s),e.closePath()}};function Kr(e,t){let n=null,r=_r(i);e=typeof e==`function`?e:H(e||Or),t=typeof t==`function`?t:H(t===void 0?64:+t);function i(){let i;if(n||=i=r(),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),i)return n=null,i+``||null}return i.type=function(t){return arguments.length?(e=typeof t==`function`?t:H(t),i):e},i.size=function(e){return arguments.length?(t=typeof e==`function`?e:H(+e),i):t},i.context=function(e){return arguments.length?(n=e??null,i):n},i}function qr(){}function Jr(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function Yr(e){this._context=e}Yr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Jr(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Jr(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Xr(e){return new Yr(e)}function Zr(e){this._context=e}Zr.prototype={areaStart:qr,areaEnd:qr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:Jr(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Qr(e){return new Zr(e)}function $r(e){this._context=e}$r.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:Jr(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ei(e){return new $r(e)}function ti(e){this._context=e}ti.prototype={areaStart:qr,areaEnd:qr,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function ni(e){return new ti(e)}function ri(e){return e<0?-1:1}function ii(e,t,n){var r=e._x1-e._x0,i=t-e._x1,a=(e._y1-e._y0)/(r||i<0&&-0),o=(n-e._y1)/(i||r<0&&-0),s=(a*i+o*r)/(r+i);return(ri(a)+ri(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function ai(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function oi(e,t,n){var r=e._x0,i=e._y0,a=e._x1,o=e._y1,s=(a-r)/3;e._context.bezierCurveTo(r+s,i+s*t,a-s,o-s*n,a,o)}function si(e){this._context=e}si.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:oi(this,this._t0,ai(this,this._t0))}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,e!==this._x1||t!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,oi(this,ai(this,n=ii(this,e,t)),n);break;default:oi(this,this._t0,n=ii(this,e,t))}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function ci(e){this._context=new li(e)}(ci.prototype=Object.create(si.prototype)).point=function(e,t){si.prototype.point.call(this,t,e)};function li(e){this._context=e}li.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,i,a){this._context.bezierCurveTo(t,e,r,n,a,i)}};function ui(e){return new si(e)}function di(e){return new ci(e)}function fi(e){this._context=e}fi.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n){if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=pi(e),i=pi(t),a=0,o=1;o<n;++a,++o)this._context.bezierCurveTo(r[0][a],i[0][a],r[1][a],i[1][a],e[o],t[o])}(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function pi(e){var t,n=e.length-1,r,i=Array(n),a=Array(n),o=Array(n);for(i[0]=0,a[0]=2,o[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,a[t]=4,o[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,a[n-1]=7,o[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/a[t-1],a[t]-=r,o[t]-=r*o[t-1];for(i[n-1]=o[n-1]/a[n-1],t=n-2;t>=0;--t)i[t]=(o[t]-i[t+1])/a[t];for(a[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)a[t]=2*e[t+1]-i[t+1];return[i,a]}function mi(e){return new fi(e)}function hi(e,t){this._context=e,this._t=t}hi.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}}this._x=e,this._y=t}};function gi(e){return new hi(e,.5)}function _i(e){return new hi(e,0)}function vi(e){return new hi(e,1)}function yi(e,t){if((o=e.length)>1)for(var n=1,r,i,a=e[t[0]],o,s=a.length;n<o;++n)for(i=a,a=e[t[n]],r=0;r<s;++r)a[r][1]+=a[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function bi(e){for(var t=e.length,n=Array(t);--t>=0;)n[t]=t;return n}function xi(e,t){return e[t]}function Si(e){let t=[];return t.key=e,t}function Ci(){var e=H([]),t=bi,n=yi,r=xi;function i(i){var a=Array.from(e.apply(this,arguments),Si),o,s=a.length,c=-1,l;for(let e of i)for(o=0,++c;o<s;++o)(a[o][c]=[0,+r(e,a[o].key,c,i)]).data=e;for(o=0,l=vr(t(a));o<s;++o)a[l[o]].index=o;return n(a,l),a}return i.keys=function(t){return arguments.length?(e=typeof t==`function`?t:H(Array.from(t)),i):e},i.value=function(e){return arguments.length?(r=typeof e==`function`?e:H(+e),i):r},i.order=function(e){return arguments.length?(t=e==null?bi:typeof e==`function`?e:H(Array.from(e)),i):t},i.offset=function(e){return arguments.length?(n=e??yi,i):n},i}function wi(e,t){if((r=e.length)>0){for(var n,r,i=0,a=e[0].length,o;i<a;++i){for(o=n=0;n<r;++n)o+=e[n][i][1]||0;if(o)for(n=0;n<r;++n)e[n][i][1]/=o}yi(e,t)}}function Ti(e,t){if((i=e.length)>0){for(var n=0,r=e[t[0]],i,a=r.length;n<a;++n){for(var o=0,s=0;o<i;++o)s+=e[o][n][1]||0;r[n][1]+=r[n][0]=-s/2}yi(e,t)}}function Ei(e,t){if((o=e.length)>0&&(a=(i=e[t[0]]).length)>0){for(var n=0,r=1,i,a,o;r<a;++r){for(var s=0,c=0,l=0;s<o;++s){for(var u=e[t[s]],d=u[r][1]||0,f=(d-(u[r-1][1]||0))/2,p=0;p<s;++p){var m=e[t[p]],h=m[r][1]||0,g=m[r-1][1]||0;f+=h-g}c+=d,l+=f*d}i[r-1][1]+=i[r-1][0]=n,c&&(n-=l/c)}i[r-1][1]+=i[r-1][0]=n,yi(e,t)}}var Di=r(ir());function Oi(e){"@babel/helpers - typeof";return Oi=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Oi(e)}var ki=[`type`,`size`,`sizeType`];function Ai(){return Ai=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ai.apply(this,arguments)}function ji(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 Mi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?ji(Object(n),!0).forEach(function(t){Ni(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ji(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Ni(e,t,n){return t=Pi(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Pi(e){var t=Fi(e,`string`);return Oi(t)==`symbol`?t:t+``}function Fi(e,t){if(Oi(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Oi(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Ii(e,t){if(e==null)return{};var n=Li(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Li(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var Ri={symbolCircle:Or,symbolCross:kr,symbolDiamond:Mr,symbolSquare:Nr,symbolStar:Rr,symbolTriangle:Br,symbolWye:Gr},zi=Math.PI/180,Bi=function(e){return Ri[`symbol${(0,Di.default)(e)}`]||Or},Vi=function(e,t,n){if(t===`area`)return e;switch(n){case`cross`:return 5*e*e/9;case`diamond`:return .5*e*e/Math.sqrt(3);case`square`:return e*e;case`star`:var r=18*zi;return 1.25*e*e*(Math.tan(r)-Math.tan(r*2)*Math.tan(r)**2);case`triangle`:return Math.sqrt(3)*e*e/4;case`wye`:return(21-10*Math.sqrt(3))*e*e/8;default:return Math.PI*e*e/4}},Hi=function(e,t){Ri[`symbol${(0,Di.default)(e)}`]=t},Ui=function(e){var t=e.type,n=t===void 0?`circle`:t,r=e.size,i=r===void 0?64:r,a=e.sizeType,o=a===void 0?`area`:a,s=Mi(Mi({},Ii(e,ki)),{},{type:n,size:i,sizeType:o}),c=function(){var e=Bi(n);return Kr().type(e).size(Vi(i,o,n))()},l=s.className,u=s.cx,d=s.cy,f=B(s,!0);return u===+u&&d===+d&&i===+i?R.createElement(`path`,Ai({},f,{className:v(`recharts-symbols`,l),transform:`translate(${u}, ${d})`,d:c()})):null};Ui.registerSymbol=Hi;function Wi(e){"@babel/helpers - typeof";return Wi=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Wi(e)}function Gi(){return Gi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Gi.apply(this,arguments)}function Ki(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 qi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Ki(Object(n),!0).forEach(function(t){ia(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ki(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Ji(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function Yi(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,aa(r.key),r)}}function Xi(e,t,n){return t&&Yi(e.prototype,t),n&&Yi(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Zi(e,t,n){return t=ta(t),Qi(e,ea()?Reflect.construct(t,n||[],ta(e).constructor):t.apply(e,n))}function Qi(e,t){if(t&&(Wi(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return $i(e)}function $i(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function ea(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ea=function(){return!!e})()}function ta(e){return ta=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ta(e)}function na(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ra(e,t)}function ra(e,t){return ra=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},ra(e,t)}function ia(e,t,n){return t=aa(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function aa(e){var t=oa(e,`string`);return Wi(t)==`symbol`?t:t+``}function oa(e,t){if(Wi(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Wi(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var sa=32,ca=function(e){function t(){return Ji(this,t),Zi(this,t,arguments)}return na(t,e),Xi(t,[{key:`renderIcon`,value:function(e){var t=this.props.inactiveColor,n=sa/2,r=sa/6,i=sa/3,a=e.inactive?t:e.color;if(e.type===`plainline`)return R.createElement(`line`,{strokeWidth:4,fill:`none`,stroke:a,strokeDasharray:e.payload.strokeDasharray,x1:0,y1:n,x2:sa,y2:n,className:`recharts-legend-icon`});if(e.type===`line`)return R.createElement(`path`,{strokeWidth:4,fill:`none`,stroke:a,d:`M0,${n}h${i}
|
|
2
|
+
A${r},${r},0,1,1,${2*i},${n}
|
|
3
|
+
H${sa}M${2*i},${n}
|
|
4
|
+
A${r},${r},0,1,1,${i},${n}`,className:`recharts-legend-icon`});if(e.type===`rect`)return R.createElement(`path`,{stroke:`none`,fill:a,d:`M0,${sa/8}h${sa}v${sa*3/4}h${-sa}z`,className:`recharts-legend-icon`});if(R.isValidElement(e.legendIcon)){var o=qi({},e);return delete o.legendIcon,R.cloneElement(e.legendIcon,o)}return R.createElement(Ui,{fill:a,cx:n,cy:n,size:sa,sizeType:`diameter`,type:e.type})}},{key:`renderItems`,value:function(){var e=this,t=this.props,n=t.payload,r=t.iconSize,i=t.layout,a=t.formatter,o=t.inactiveColor,s={x:0,y:0,width:sa,height:sa},c={display:i===`horizontal`?`inline-block`:`block`,marginRight:10},l={display:`inline-block`,verticalAlign:`middle`,marginRight:4};return n.map(function(t,n){var i=t.formatter||a,u=v(ia(ia({"recharts-legend-item":!0},`legend-item-${n}`,!0),`inactive`,t.inactive));if(t.type===`none`)return null;var d=(0,z.default)(t.value)?null:t.value;(0,z.default)(t.value);var f=t.inactive?o:t.color;return R.createElement(`li`,Gi({className:u,style:c,key:`legend-item-${n}`},vn(e.props,t,n)),R.createElement(Kn,{width:r,height:r,viewBox:s,style:l},e.renderIcon(t)),R.createElement(`span`,{className:`recharts-legend-item-text`,style:{color:f}},i?i(d,t,n):d))})}},{key:`render`,value:function(){var e=this.props,t=e.payload,n=e.layout,r=e.align;if(!t||!t.length)return null;var i={padding:0,margin:0,textAlign:n===`horizontal`?r:`left`};return R.createElement(`ul`,{className:`recharts-default-legend`,style:i},this.renderItems())}}])}(R.PureComponent);ia(ca,`displayName`,`Legend`),ia(ca,`defaultProps`,{iconSize:14,layout:`horizontal`,align:`center`,verticalAlign:`middle`,inactiveColor:`#ccc`});var la=t(((e,t)=>{var n=bt();function r(){this.__data__=new n,this.size=0}t.exports=r})),ua=t(((e,t)=>{function n(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}t.exports=n})),da=t(((e,t)=>{function n(e){return this.__data__.get(e)}t.exports=n})),fa=t(((e,t)=>{function n(e){return this.__data__.has(e)}t.exports=n})),pa=t(((e,t)=>{var n=bt(),r=xt(),i=kt(),a=200;function o(e,t){var o=this.__data__;if(o instanceof n){var s=o.__data__;if(!r||s.length<a-1)return s.push([e,t]),this.size=++o.size,this;o=this.__data__=new i(s)}return o.set(e,t),this.size=o.size,this}t.exports=o})),ma=t(((e,t)=>{var n=bt(),r=la(),i=ua(),a=da(),o=fa(),s=pa();function c(e){var t=this.__data__=new n(e);this.size=t.size}c.prototype.clear=r,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=o,c.prototype.set=s,t.exports=c})),ha=t(((e,t)=>{function n(e){return this.__data__.set(e,`__lodash_hash_undefined__`),this}t.exports=n})),ga=t(((e,t)=>{function n(e){return this.__data__.has(e)}t.exports=n})),_a=t(((e,t)=>{var n=kt(),r=ha(),i=ga();function a(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new n;++t<r;)this.add(e[t])}a.prototype.add=a.prototype.push=r,a.prototype.has=i,t.exports=a})),va=t(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}t.exports=n})),ya=t(((e,t)=>{function n(e,t){return e.has(t)}t.exports=n})),ba=t(((e,t)=>{var n=_a(),r=va(),i=ya(),a=1,o=2;function s(e,t,s,c,l,u){var d=s&a,f=e.length,p=t.length;if(f!=p&&!(d&&p>f))return!1;var m=u.get(e),h=u.get(t);if(m&&h)return m==t&&h==e;var g=-1,_=!0,v=s&o?new n:void 0;for(u.set(e,t),u.set(t,e);++g<f;){var y=e[g],b=t[g];if(c)var x=d?c(b,y,g,t,e,u):c(y,b,g,e,t,u);if(x!==void 0){if(x)continue;_=!1;break}if(v){if(!r(t,function(e,t){if(!i(v,t)&&(y===e||l(y,e,s,c,u)))return v.push(t)})){_=!1;break}}else if(!(y===b||l(y,b,s,c,u))){_=!1;break}}return u.delete(e),u.delete(t),_}t.exports=s})),xa=t(((e,t)=>{t.exports=We().Uint8Array})),Sa=t(((e,t)=>{function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}t.exports=n})),Ca=t(((e,t)=>{function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}t.exports=n})),wa=t(((e,t)=>{var n=Ge(),r=xa(),i=mt(),a=ba(),o=Sa(),s=Ca(),c=1,l=2,u=`[object Boolean]`,d=`[object Date]`,f=`[object Error]`,p=`[object Map]`,m=`[object Number]`,h=`[object RegExp]`,g=`[object Set]`,_=`[object String]`,v=`[object Symbol]`,y=`[object ArrayBuffer]`,b=`[object DataView]`,x=n?n.prototype:void 0,S=x?x.valueOf:void 0;function C(e,t,n,x,C,w,T){switch(n){case b:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case y:return!(e.byteLength!=t.byteLength||!w(new r(e),new r(t)));case u:case d:case m:return i(+e,+t);case f:return e.name==t.name&&e.message==t.message;case h:case _:return e==t+``;case p:var E=o;case g:var D=x&c;if(E||=s,e.size!=t.size&&!D)return!1;var O=T.get(e);if(O)return O==t;x|=l,T.set(e,t);var k=a(E(e),E(t),x,C,w,T);return T.delete(e),k;case v:if(S)return S.call(e)==S.call(t)}return!1}t.exports=C})),Ta=t(((e,t)=>{function n(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}t.exports=n})),Ea=t(((e,t)=>{var n=Ta(),r=He();function i(e,t,i){var a=t(e);return r(e)?a:n(a,i(e))}t.exports=i})),Da=t(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length,i=0,a=[];++n<r;){var o=e[n];t(o,n,e)&&(a[i++]=o)}return a}t.exports=n})),Oa=t(((e,t)=>{function n(){return[]}t.exports=n})),ka=t(((e,t)=>{var n=Da(),r=Oa(),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols;t.exports=a?function(e){return e==null?[]:(e=Object(e),n(a(e),function(t){return i.call(e,t)}))}:r})),Aa=t(((e,t)=>{function n(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}t.exports=n})),ja=t(((e,t)=>{var n=Je(),r=Ye(),i=`[object Arguments]`;function a(e){return r(e)&&n(e)==i}t.exports=a})),Ma=t(((e,t)=>{var n=ja(),r=Ye(),i=Object.prototype,a=i.hasOwnProperty,o=i.propertyIsEnumerable;t.exports=n(function(){return arguments}())?n:function(e){return r(e)&&a.call(e,`callee`)&&!o.call(e,`callee`)}})),Na=t(((e,t)=>{function n(){return!1}t.exports=n})),Pa=t(((e,t)=>{var n=We(),r=Na(),i=typeof e==`object`&&e&&!e.nodeType&&e,a=i&&typeof t==`object`&&t&&!t.nodeType&&t,o=a&&a.exports===i?n.Buffer:void 0;t.exports=(o?o.isBuffer:void 0)||r})),Fa=t(((e,t)=>{var n=/^(?:0|[1-9]\d*)$/;function r(e,t){var r=typeof e;return t??=9007199254740991,!!t&&(r==`number`||r!=`symbol`&&n.test(e))&&e>-1&&e%1==0&&e<t}t.exports=r})),Ia=t(((e,t)=>{function n(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=9007199254740991}t.exports=n})),La=t(((e,t)=>{var n=Je(),r=Ia(),i=Ye(),a=`[object Arguments]`,o=`[object Array]`,s=`[object Boolean]`,c=`[object Date]`,l=`[object Error]`,u=`[object Function]`,d=`[object Map]`,f=`[object Number]`,p=`[object Object]`,m=`[object RegExp]`,h=`[object Set]`,g=`[object String]`,_=`[object WeakMap]`,v=`[object ArrayBuffer]`,y=`[object DataView]`,b=`[object Float32Array]`,x=`[object Float64Array]`,S=`[object Int8Array]`,C=`[object Int16Array]`,w=`[object Int32Array]`,T=`[object Uint8Array]`,E=`[object Uint8ClampedArray]`,D=`[object Uint16Array]`,O=`[object Uint32Array]`,k={};k[b]=k[x]=k[S]=k[C]=k[w]=k[T]=k[E]=k[D]=k[O]=!0,k[a]=k[o]=k[v]=k[s]=k[y]=k[c]=k[l]=k[u]=k[d]=k[f]=k[p]=k[m]=k[h]=k[g]=k[_]=!1;function A(e){return i(e)&&r(e.length)&&!!k[n(e)]}t.exports=A})),Ra=t(((e,t)=>{function n(e){return function(t){return e(t)}}t.exports=n})),za=t(((e,t)=>{var n=Ue(),r=typeof e==`object`&&e&&!e.nodeType&&e,i=r&&typeof t==`object`&&t&&!t.nodeType&&t,a=i&&i.exports===r&&n.process;t.exports=function(){try{return i&&i.require&&i.require(`util`).types||a&&a.binding&&a.binding(`util`)}catch{}}()})),Ba=t(((e,t)=>{var n=La(),r=Ra(),i=za(),a=i&&i.isTypedArray;t.exports=a?r(a):n})),Va=t(((e,t)=>{var n=Aa(),r=Ma(),i=He(),a=Pa(),o=Fa(),s=Ba(),c=Object.prototype.hasOwnProperty;function l(e,t){var l=i(e),u=!l&&r(e),d=!l&&!u&&a(e),f=!l&&!u&&!d&&s(e),p=l||u||d||f,m=p?n(e.length,String):[],h=m.length;for(var g in e)(t||c.call(e,g))&&!(p&&(g==`length`||d&&(g==`offset`||g==`parent`)||f&&(g==`buffer`||g==`byteLength`||g==`byteOffset`)||o(g,h)))&&m.push(g);return m}t.exports=l})),Ha=t(((e,t)=>{var n=Object.prototype;function r(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||n)}t.exports=r})),Ua=t(((e,t)=>{function n(e,t){return function(n){return e(t(n))}}t.exports=n})),Wa=t(((e,t)=>{t.exports=Ua()(Object.keys,Object)})),Ga=t(((e,t)=>{var n=Ha(),r=Wa(),i=Object.prototype.hasOwnProperty;function a(e){if(!n(e))return r(e);var t=[];for(var a in Object(e))i.call(e,a)&&a!=`constructor`&&t.push(a);return t}t.exports=a})),Ka=t(((e,t)=>{var n=$e(),r=Ia();function i(e){return e!=null&&r(e.length)&&!n(e)}t.exports=i})),qa=t(((e,t)=>{var n=Va(),r=Ga(),i=Ka();function a(e){return i(e)?n(e):r(e)}t.exports=a})),Ja=t(((e,t)=>{var n=Ea(),r=ka(),i=qa();function a(e){return n(e,i,r)}t.exports=a})),Ya=t(((e,t)=>{var n=Ja(),r=1,i=Object.prototype.hasOwnProperty;function a(e,t,a,o,s,c){var l=a&r,u=n(e),d=u.length;if(d!=n(t).length&&!l)return!1;for(var f=d;f--;){var p=u[f];if(!(l?p in t:i.call(t,p)))return!1}var m=c.get(e),h=c.get(t);if(m&&h)return m==t&&h==e;var g=!0;c.set(e,t),c.set(t,e);for(var _=l;++f<d;){p=u[f];var v=e[p],y=t[p];if(o)var b=l?o(y,v,p,t,e,c):o(v,y,p,e,t,c);if(!(b===void 0?v===y||s(v,y,a,o,c):b)){g=!1;break}_||=p==`constructor`}if(g&&!_){var x=e.constructor,S=t.constructor;x!=S&&`constructor`in e&&`constructor`in t&&!(typeof x==`function`&&x instanceof x&&typeof S==`function`&&S instanceof S)&&(g=!1)}return c.delete(e),c.delete(t),g}t.exports=a})),Xa=t(((e,t)=>{t.exports=at()(We(),`DataView`)})),Za=t(((e,t)=>{t.exports=at()(We(),`Promise`)})),Qa=t(((e,t)=>{t.exports=at()(We(),`Set`)})),$a=t(((e,t)=>{t.exports=at()(We(),`WeakMap`)})),eo=t(((e,t)=>{var n=Xa(),r=xt(),i=Za(),a=Qa(),o=$a(),s=Je(),c=nt(),l=`[object Map]`,u=`[object Object]`,d=`[object Promise]`,f=`[object Set]`,p=`[object WeakMap]`,m=`[object DataView]`,h=c(n),g=c(r),_=c(i),v=c(a),y=c(o),b=s;(n&&b(new n(new ArrayBuffer(1)))!=m||r&&b(new r)!=l||i&&b(i.resolve())!=d||a&&b(new a)!=f||o&&b(new o)!=p)&&(b=function(e){var t=s(e),n=t==u?e.constructor:void 0,r=n?c(n):``;if(r)switch(r){case h:return m;case g:return l;case _:return d;case v:return f;case y:return p}return t}),t.exports=b})),to=t(((e,t)=>{var n=ma(),r=ba(),i=wa(),a=Ya(),o=eo(),s=He(),c=Pa(),l=Ba(),u=1,d=`[object Arguments]`,f=`[object Array]`,p=`[object Object]`,m=Object.prototype.hasOwnProperty;function h(e,t,h,g,_,v){var y=s(e),b=s(t),x=y?f:o(e),S=b?f:o(t);x=x==d?p:x,S=S==d?p:S;var C=x==p,w=S==p,T=x==S;if(T&&c(e)){if(!c(t))return!1;y=!0,C=!1}if(T&&!C)return v||=new n,y||l(e)?r(e,t,h,g,_,v):i(e,t,x,h,g,_,v);if(!(h&u)){var E=C&&m.call(e,`__wrapped__`),D=w&&m.call(t,`__wrapped__`);if(E||D){var O=E?e.value():e,k=D?t.value():t;return v||=new n,_(O,k,h,g,v)}}return T?(v||=new n,a(e,t,h,g,_,v)):!1}t.exports=h})),no=t(((e,t)=>{var n=to(),r=Ye();function i(e,t,a,o,s){return e===t?!0:e==null||t==null||!r(e)&&!r(t)?e!==e&&t!==t:n(e,t,a,o,i,s)}t.exports=i})),ro=t(((e,t)=>{var n=ma(),r=no(),i=1,a=2;function o(e,t,o,s){var c=o.length,l=c,u=!s;if(e==null)return!l;for(e=Object(e);c--;){var d=o[c];if(u&&d[2]?d[1]!==e[d[0]]:!(d[0]in e))return!1}for(;++c<l;){d=o[c];var f=d[0],p=e[f],m=d[1];if(u&&d[2]){if(p===void 0&&!(f in e))return!1}else{var h=new n;if(s)var g=s(p,m,f,e,t,h);if(!(g===void 0?r(m,p,i|a,s,h):g))return!1}}return!0}t.exports=o})),io=t(((e,t)=>{var n=Qe();function r(e){return e===e&&!n(e)}t.exports=r})),ao=t(((e,t)=>{var n=io(),r=qa();function i(e){for(var t=r(e),i=t.length;i--;){var a=t[i],o=e[a];t[i]=[a,o,n(o)]}return t}t.exports=i})),oo=t(((e,t)=>{function n(e,t){return function(n){return n!=null&&n[e]===t&&(t!==void 0||e in Object(n))}}t.exports=n})),so=t(((e,t)=>{var n=ro(),r=ao(),i=oo();function a(e){var t=r(e);return t.length==1&&t[0][2]?i(t[0][0],t[0][1]):function(r){return r===e||n(r,e,t)}}t.exports=a})),co=t(((e,t)=>{function n(e,t){return e!=null&&t in Object(e)}t.exports=n})),lo=t(((e,t)=>{var n=It(),r=Ma(),i=He(),a=Fa(),o=Ia(),s=Lt();function c(e,t,c){t=n(t,e);for(var l=-1,u=t.length,d=!1;++l<u;){var f=s(t[l]);if(!(d=e!=null&&c(e,f)))break;e=e[f]}return d||++l!=u?d:(u=e==null?0:e.length,!!u&&o(u)&&a(f,u)&&(i(e)||r(e)))}t.exports=c})),uo=t(((e,t)=>{var n=co(),r=lo();function i(e,t){return e!=null&&r(e,t,n)}t.exports=i})),fo=t(((e,t)=>{var n=no(),r=zt(),i=uo(),a=Ze(),o=io(),s=oo(),c=Lt(),l=1,u=2;function d(e,t){return a(e)&&o(t)?s(c(e),t):function(a){var o=r(a,e);return o===void 0&&o===t?i(a,e):n(t,o,l|u)}}t.exports=d})),po=t(((e,t)=>{function n(e){return e}t.exports=n})),mo=t(((e,t)=>{function n(e){return function(t){return t?.[e]}}t.exports=n})),ho=t(((e,t)=>{var n=Rt();function r(e){return function(t){return n(t,e)}}t.exports=r})),go=t(((e,t)=>{var n=mo(),r=ho(),i=Ze(),a=Lt();function o(e){return i(e)?n(a(e)):r(e)}t.exports=o})),_o=t(((e,t)=>{var n=so(),r=fo(),i=po(),a=He(),o=go();function s(e){return typeof e==`function`?e:e==null?i:typeof e==`object`?a(e)?r(e[0],e[1]):n(e):o(e)}t.exports=s})),vo=t(((e,t)=>{function n(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a<i;)if(t(e[a],a,e))return a;return-1}t.exports=n})),yo=t(((e,t)=>{function n(e){return e!==e}t.exports=n})),bo=t(((e,t)=>{function n(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}t.exports=n})),xo=t(((e,t)=>{var n=vo(),r=yo(),i=bo();function a(e,t,a){return t===t?i(e,t,a):n(e,r,a)}t.exports=a})),So=t(((e,t)=>{var n=xo();function r(e,t){return!!(e!=null&&e.length)&&n(e,t,0)>-1}t.exports=r})),Co=t(((e,t)=>{function n(e,t,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}t.exports=n})),wo=t(((e,t)=>{function n(){}t.exports=n})),To=t(((e,t)=>{var n=Qa(),r=wo(),i=Ca();t.exports=n&&1/i(new n([,-0]))[1]==1/0?function(e){return new n(e)}:r})),Eo=t(((e,t)=>{var n=_a(),r=So(),i=Co(),a=ya(),o=To(),s=Ca(),c=200;function l(e,t,l){var u=-1,d=r,f=e.length,p=!0,m=[],h=m;if(l)p=!1,d=i;else if(f>=c){var g=t?null:o(e);if(g)return s(g);p=!1,d=a,h=new n}else h=t?[]:m;outer:for(;++u<f;){var _=e[u],v=t?t(_):_;if(_=l||_!==0?_:0,p&&v===v){for(var y=h.length;y--;)if(h[y]===v)continue outer;t&&h.push(v),m.push(_)}else d(h,v,l)||(h!==m&&h.push(v),m.push(_))}return m}t.exports=l})),Do=r(t(((e,t)=>{var n=_o(),r=Eo();function i(e,t){return e&&e.length?r(e,n(t,2)):[]}t.exports=i}))());function Oo(e,t,n){return t===!0?(0,Do.default)(e,n):(0,z.default)(t)?(0,Do.default)(e,t):e}function ko(e){"@babel/helpers - typeof";return ko=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},ko(e)}var Ao=[`ref`];function jo(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 Mo(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?jo(Object(n),!0).forEach(function(t){Uo(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jo(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function No(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function Po(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,Wo(r.key),r)}}function Fo(e,t,n){return t&&Po(e.prototype,t),n&&Po(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Io(e,t,n){return t=Bo(t),Lo(e,zo()?Reflect.construct(t,n||[],Bo(e).constructor):t.apply(e,n))}function Lo(e,t){if(t&&(ko(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return Ro(e)}function Ro(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function zo(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(zo=function(){return!!e})()}function Bo(e){return Bo=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Bo(e)}function Vo(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Ho(e,t)}function Ho(e,t){return Ho=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Ho(e,t)}function Uo(e,t,n){return t=Wo(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Wo(e){var t=Go(e,`string`);return ko(t)==`symbol`?t:t+``}function Go(e,t){if(ko(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(ko(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Ko(e,t){if(e==null)return{};var n=qo(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function qo(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Jo(e){return e.value}function Yo(e,t){if(R.isValidElement(e))return R.cloneElement(e,t);if(typeof e==`function`)return R.createElement(e,t);t.ref;var n=Ko(t,Ao);return R.createElement(ca,n)}var Xo=1,Zo=function(e){function t(){var e;No(this,t);var n=[...arguments];return e=Io(this,t,[].concat(n)),Uo(e,`lastBoundingBox`,{width:-1,height:-1}),e}return Vo(t,e),Fo(t,[{key:`componentDidMount`,value:function(){this.updateBBox()}},{key:`componentDidUpdate`,value:function(){this.updateBBox()}},{key:`getBBox`,value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var e=this.wrapperNode.getBoundingClientRect();return e.height=this.wrapperNode.offsetHeight,e.width=this.wrapperNode.offsetWidth,e}return null}},{key:`updateBBox`,value:function(){var e=this.props.onBBoxUpdate,t=this.getBBox();t?(Math.abs(t.width-this.lastBoundingBox.width)>Xo||Math.abs(t.height-this.lastBoundingBox.height)>Xo)&&(this.lastBoundingBox.width=t.width,this.lastBoundingBox.height=t.height,e&&e(t)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,e&&e(null))}},{key:`getBBoxSnapshot`,value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?Mo({},this.lastBoundingBox):{width:0,height:0}}},{key:`getDefaultPosition`,value:function(e){var t=this.props,n=t.layout,r=t.align,i=t.verticalAlign,a=t.margin,o=t.chartWidth,s=t.chartHeight,c,l;if(!e||(e.left===void 0||e.left===null)&&(e.right===void 0||e.right===null)){if(r===`center`&&n===`vertical`){var u=this.getBBoxSnapshot();c={left:((o||0)-u.width)/2}}else c=r===`right`?{right:a&&a.right||0}:{left:a&&a.left||0}}if(!e||(e.top===void 0||e.top===null)&&(e.bottom===void 0||e.bottom===null)){if(i===`middle`){var d=this.getBBoxSnapshot();l={top:((s||0)-d.height)/2}}else l=i===`bottom`?{bottom:a&&a.bottom||0}:{top:a&&a.top||0}}return Mo(Mo({},c),l)}},{key:`render`,value:function(){var e=this,t=this.props,n=t.content,r=t.width,i=t.height,a=t.wrapperStyle,o=t.payloadUniqBy,s=t.payload,c=Mo(Mo({position:`absolute`,width:r||`auto`,height:i||`auto`},this.getDefaultPosition(a)),a);return R.createElement(`div`,{className:`recharts-legend-wrapper`,style:c,ref:function(t){e.wrapperNode=t}},Yo(n,Mo(Mo({},this.props),{},{payload:Oo(s,o,Jo)})))}}],[{key:`getWithHeight`,value:function(e,t){var n=Mo(Mo({},this.defaultProps),e.props).layout;return n===`vertical`&&I(e.props.height)?{height:e.props.height}:n===`horizontal`?{width:e.props.width||t}:null}}])}(R.PureComponent);Uo(Zo,`displayName`,`Legend`),Uo(Zo,`defaultProps`,{iconSize:14,layout:`horizontal`,align:`center`,verticalAlign:`bottom`});var Qo=t(((e,t)=>{var n=Ge(),r=Ma(),i=He(),a=n?n.isConcatSpreadable:void 0;function o(e){return i(e)||r(e)||!!(a&&e&&e[a])}t.exports=o})),$o=t(((e,t)=>{var n=Ta(),r=Qo();function i(e,t,a,o,s){var c=-1,l=e.length;for(a||=r,s||=[];++c<l;){var u=e[c];t>0&&a(u)?t>1?i(u,t-1,a,o,s):n(s,u):o||(s[s.length]=u)}return s}t.exports=i})),es=t(((e,t)=>{function n(e){return function(t,n,r){for(var i=-1,a=Object(t),o=r(t),s=o.length;s--;){var c=o[e?s:++i];if(n(a[c],c,a)===!1)break}return t}}t.exports=n})),ts=t(((e,t)=>{t.exports=es()()})),ns=t(((e,t)=>{var n=ts(),r=qa();function i(e,t){return e&&n(e,t,r)}t.exports=i})),rs=t(((e,t)=>{var n=Ka();function r(e,t){return function(r,i){if(r==null)return r;if(!n(r))return e(r,i);for(var a=r.length,o=t?a:-1,s=Object(r);(t?o--:++o<a)&&i(s[o],o,s)!==!1;);return r}}t.exports=r})),is=t(((e,t)=>{var n=ns();t.exports=rs()(n)})),as=t(((e,t)=>{var n=is(),r=Ka();function i(e,t){var i=-1,a=r(e)?Array(e.length):[];return n(e,function(e,n,r){a[++i]=t(e,n,r)}),a}t.exports=i})),os=t(((e,t)=>{function n(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}t.exports=n})),ss=t(((e,t)=>{var n=Xe();function r(e,t){if(e!==t){var r=e!==void 0,i=e===null,a=e===e,o=n(e),s=t!==void 0,c=t===null,l=t===t,u=n(t);if(!c&&!u&&!o&&e>t||o&&s&&l&&!c&&!u||i&&s&&l||!r&&l||!a)return 1;if(!i&&!o&&!u&&e<t||u&&r&&a&&!i&&!o||c&&r&&a||!s&&a||!l)return-1}return 0}t.exports=r})),cs=t(((e,t)=>{var n=ss();function r(e,t,r){for(var i=-1,a=e.criteria,o=t.criteria,s=a.length,c=r.length;++i<s;){var l=n(a[i],o[i]);if(l)return i>=c?l:l*(r[i]==`desc`?-1:1)}return e.index-t.index}t.exports=r})),ls=t(((e,t)=>{var n=Nt(),r=Rt(),i=_o(),a=as(),o=os(),s=Ra(),c=cs(),l=po(),u=He();function d(e,t,d){t=t.length?n(t,function(e){return u(e)?function(t){return r(t,e.length===1?e[0]:e)}:e}):[l];var f=-1;return t=n(t,s(i)),o(a(e,function(e,r,i){return{criteria:n(t,function(t){return t(e)}),index:++f,value:e}}),function(e,t){return c(e,t,d)})}t.exports=d})),us=t(((e,t)=>{function n(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)}t.exports=n})),ds=t(((e,t)=>{var n=us(),r=Math.max;function i(e,t,i){return t=r(t===void 0?e.length-1:t,0),function(){for(var a=arguments,o=-1,s=r(a.length-t,0),c=Array(s);++o<s;)c[o]=a[t+o];o=-1;for(var l=Array(t+1);++o<t;)l[o]=a[o];return l[t]=i(c),n(e,this,l)}}t.exports=i})),fs=t(((e,t)=>{function n(e){return function(){return e}}t.exports=n})),ps=t(((e,t)=>{var n=at();t.exports=function(){try{var e=n(Object,`defineProperty`);return e({},``,{}),e}catch{}}()})),ms=t(((e,t)=>{var n=fs(),r=ps(),i=po();t.exports=r?function(e,t){return r(e,`toString`,{configurable:!0,enumerable:!1,value:n(t),writable:!0})}:i})),hs=t(((e,t)=>{var n=Date.now;function r(e){var t=0,r=0;return function(){var i=n(),a=16-(i-r);if(r=i,a>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}t.exports=r})),gs=t(((e,t)=>{var n=ms();t.exports=hs()(n)})),_s=t(((e,t)=>{var n=po(),r=ds(),i=gs();function a(e,t){return i(r(e,t,n),e+``)}t.exports=a})),vs=t(((e,t)=>{var n=mt(),r=Ka(),i=Fa(),a=Qe();function o(e,t,o){if(!a(o))return!1;var s=typeof t;return(s==`number`?r(o)&&i(t,o.length):s==`string`&&t in o)?n(o[t],e):!1}t.exports=o})),ys=r(t(((e,t)=>{var n=$o(),r=ls(),i=_s(),a=vs();t.exports=i(function(e,t){if(e==null)return[];var i=t.length;return i>1&&a(e,t[0],t[1])?t=[]:i>2&&a(t[0],t[1],t[2])&&(t=[t[0]]),r(e,n(t,1),[])})}))());function bs(e){"@babel/helpers - typeof";return bs=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},bs(e)}function xs(){return xs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},xs.apply(this,arguments)}function Ss(e,t){return Ds(e)||Es(e,t)||ws(e,t)||Cs()}function Cs(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
5
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ws(e,t){if(e){if(typeof e==`string`)return Ts(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ts(e,t)}}function Ts(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Es(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function Ds(e){if(Array.isArray(e))return e}function Os(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 ks(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Os(Object(n),!0).forEach(function(t){As(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Os(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function As(e,t,n){return t=js(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function js(e){var t=Ms(e,`string`);return bs(t)==`symbol`?t:t+``}function Ms(e,t){if(bs(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(bs(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Ns(e){return Array.isArray(e)&&L(e[0])&&L(e[1])?e.join(` ~ `):e}var Ps=function(e){var t=e.separator,n=t===void 0?` : `:t,r=e.contentStyle,i=r===void 0?{}:r,a=e.itemStyle,o=a===void 0?{}:a,s=e.labelStyle,c=s===void 0?{}:s,l=e.payload,u=e.formatter,d=e.itemSorter,f=e.wrapperClassName,p=e.labelClassName,m=e.label,h=e.labelFormatter,g=e.accessibilityLayer,_=g!==void 0&&g,y=function(){if(l&&l.length){var e={padding:0,margin:0},t=(d?(0,ys.default)(l,d):l).map(function(e,t){if(e.type===`none`)return null;var r=ks({display:`block`,paddingTop:4,paddingBottom:4,color:e.color||`#000`},o),i=e.formatter||u||Ns,a=e.value,s=e.name,c=a,d=s;if(i&&c!=null&&d!=null){var f=i(a,s,e,t,l);if(Array.isArray(f)){var p=Ss(f,2);c=p[0],d=p[1]}else c=f}return R.createElement(`li`,{className:`recharts-tooltip-item`,key:`tooltip-item-${t}`,style:r},L(d)?R.createElement(`span`,{className:`recharts-tooltip-item-name`},d):null,L(d)?R.createElement(`span`,{className:`recharts-tooltip-item-separator`},n):null,R.createElement(`span`,{className:`recharts-tooltip-item-value`},c),R.createElement(`span`,{className:`recharts-tooltip-item-unit`},e.unit||``))});return R.createElement(`ul`,{className:`recharts-tooltip-item-list`,style:e},t)}return null},b=ks({margin:0,padding:10,backgroundColor:`#fff`,border:`1px solid #ccc`,whiteSpace:`nowrap`},i),x=ks({margin:0},c),S=!(0,F.default)(m),C=S?m:``,w=v(`recharts-default-tooltip`,f),T=v(`recharts-tooltip-label`,p);S&&h&&l!=null&&(C=h(m,l));var E=_?{role:`status`,"aria-live":`assertive`}:{};return R.createElement(`div`,xs({className:w,style:b},E),R.createElement(`p`,{className:T,style:x},R.isValidElement(C)?C:`${C}`),y())};function Fs(e){"@babel/helpers - typeof";return Fs=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Fs(e)}function Is(e,t,n){return t=Ls(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ls(e){var t=Rs(e,`string`);return Fs(t)==`symbol`?t:t+``}function Rs(e,t){if(Fs(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Fs(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var zs=`recharts-tooltip-wrapper`,Bs={visibility:`hidden`};function Vs(e){var t=e.coordinate,n=e.translateX,r=e.translateY;return v(zs,Is(Is(Is(Is({},`${zs}-right`,I(n)&&t&&I(t.x)&&n>=t.x),`${zs}-left`,I(n)&&t&&I(t.x)&&n<t.x),`${zs}-bottom`,I(r)&&t&&I(t.y)&&r>=t.y),`${zs}-top`,I(r)&&t&&I(t.y)&&r<t.y))}function Hs(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.key,i=e.offsetTopLeft,a=e.position,o=e.reverseDirection,s=e.tooltipDimension,c=e.viewBox,l=e.viewBoxDimension;if(a&&I(a[r]))return a[r];var u=n[r]-s-i,d=n[r]+i;return t[r]?o[r]?u:d:o[r]?u<c[r]?Math.max(d,c[r]):Math.max(u,c[r]):d+s>c[r]+l?Math.max(u,c[r]):Math.max(d,c[r])}function Us(e){var t=e.translateX,n=e.translateY;return{transform:e.useTranslate3d?`translate3d(${t}px, ${n}px, 0)`:`translate(${t}px, ${n}px)`}}function Ws(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.offsetTopLeft,i=e.position,a=e.reverseDirection,o=e.tooltipBox,s=e.useTranslate3d,c=e.viewBox,l,u,d;return o.height>0&&o.width>0&&n?(u=Hs({allowEscapeViewBox:t,coordinate:n,key:`x`,offsetTopLeft:r,position:i,reverseDirection:a,tooltipDimension:o.width,viewBox:c,viewBoxDimension:c.width}),d=Hs({allowEscapeViewBox:t,coordinate:n,key:`y`,offsetTopLeft:r,position:i,reverseDirection:a,tooltipDimension:o.height,viewBox:c,viewBoxDimension:c.height}),l=Us({translateX:u,translateY:d,useTranslate3d:s})):l=Bs,{cssProperties:l,cssClasses:Vs({translateX:u,translateY:d,coordinate:n})}}function Gs(e){"@babel/helpers - typeof";return Gs=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Gs(e)}function Ks(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 qs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Ks(Object(n),!0).forEach(function(t){ic(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ks(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Js(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function Ys(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,ac(r.key),r)}}function Xs(e,t,n){return t&&Ys(e.prototype,t),n&&Ys(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Zs(e,t,n){return t=tc(t),Qs(e,ec()?Reflect.construct(t,n||[],tc(e).constructor):t.apply(e,n))}function Qs(e,t){if(t&&(Gs(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return $s(e)}function $s(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function ec(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ec=function(){return!!e})()}function tc(e){return tc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},tc(e)}function nc(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&rc(e,t)}function rc(e,t){return rc=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},rc(e,t)}function ic(e,t,n){return t=ac(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ac(e){var t=oc(e,`string`);return Gs(t)==`symbol`?t:t+``}function oc(e,t){if(Gs(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Gs(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var sc=1,cc=function(e){function t(){var e;Js(this,t);var n=[...arguments];return e=Zs(this,t,[].concat(n)),ic(e,`state`,{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),ic(e,`handleKeyDown`,function(t){t.key===`Escape`&&e.setState({dismissed:!0,dismissedAtCoordinate:{x:e.props.coordinate?.x??0,y:e.props.coordinate?.y??0}})}),e}return nc(t,e),Xs(t,[{key:`updateBBox`,value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var e=this.wrapperNode.getBoundingClientRect();(Math.abs(e.width-this.state.lastBoundingBox.width)>sc||Math.abs(e.height-this.state.lastBoundingBox.height)>sc)&&this.setState({lastBoundingBox:{width:e.width,height:e.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:`componentDidMount`,value:function(){document.addEventListener(`keydown`,this.handleKeyDown),this.updateBBox()}},{key:`componentWillUnmount`,value:function(){document.removeEventListener(`keydown`,this.handleKeyDown)}},{key:`componentDidUpdate`,value:function(){this.props.active&&this.updateBBox(),this.state.dismissed&&(this.props.coordinate?.x!==this.state.dismissedAtCoordinate.x||this.props.coordinate?.y!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:`render`,value:function(){var e=this,t=this.props,n=t.active,r=t.allowEscapeViewBox,i=t.animationDuration,a=t.animationEasing,o=t.children,s=t.coordinate,c=t.hasPayload,l=t.isAnimationActive,u=t.offset,d=t.position,f=t.reverseDirection,p=t.useTranslate3d,m=t.viewBox,h=t.wrapperStyle,g=Ws({allowEscapeViewBox:r,coordinate:s,offsetTopLeft:u,position:d,reverseDirection:f,tooltipBox:this.state.lastBoundingBox,useTranslate3d:p,viewBox:m}),_=g.cssClasses,v=g.cssProperties,y=qs(qs({transition:l&&n?`transform ${i}ms ${a}`:void 0},v),{},{pointerEvents:`none`,visibility:!this.state.dismissed&&n&&c?`visible`:`hidden`,position:`absolute`,top:0,left:0},h);return R.createElement(`div`,{tabIndex:-1,className:_,style:y,ref:function(t){e.wrapperNode=t}},o)}}])}(R.PureComponent),lc={isSsr:function(){return!(typeof window<`u`&&window.document&&window.document.createElement&&window.setTimeout)}(),get:function(e){return lc[e]},set:function(e,t){if(typeof e==`string`)lc[e]=t;else{var n=Object.keys(e);n&&n.length&&n.forEach(function(t){lc[t]=e[t]})}}};function uc(e){"@babel/helpers - typeof";return uc=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},uc(e)}function dc(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 fc(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?dc(Object(n),!0).forEach(function(t){Cc(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dc(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function pc(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function mc(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,wc(r.key),r)}}function hc(e,t,n){return t&&mc(e.prototype,t),n&&mc(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function gc(e,t,n){return t=bc(t),_c(e,yc()?Reflect.construct(t,n||[],bc(e).constructor):t.apply(e,n))}function _c(e,t){if(t&&(uc(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return vc(e)}function vc(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function yc(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(yc=function(){return!!e})()}function bc(e){return bc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},bc(e)}function xc(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Sc(e,t)}function Sc(e,t){return Sc=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Sc(e,t)}function Cc(e,t,n){return t=wc(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function wc(e){var t=Tc(e,`string`);return uc(t)==`symbol`?t:t+``}function Tc(e,t){if(uc(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(uc(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Ec(e){return e.dataKey}function Dc(e,t){return R.isValidElement(e)?R.cloneElement(e,t):typeof e==`function`?R.createElement(e,t):R.createElement(Ps,t)}var Oc=function(e){function t(){return pc(this,t),gc(this,t,arguments)}return xc(t,e),hc(t,[{key:`render`,value:function(){var e=this,t=this.props,n=t.active,r=t.allowEscapeViewBox,i=t.animationDuration,a=t.animationEasing,o=t.content,s=t.coordinate,c=t.filterNull,l=t.isAnimationActive,u=t.offset,d=t.payload,f=t.payloadUniqBy,p=t.position,m=t.reverseDirection,h=t.useTranslate3d,g=t.viewBox,_=t.wrapperStyle,v=d??[];c&&v.length&&(v=Oo(d.filter(function(t){return t.value!=null&&(t.hide!==!0||e.props.includeHidden)}),f,Ec));var y=v.length>0;return R.createElement(cc,{allowEscapeViewBox:r,animationDuration:i,animationEasing:a,isAnimationActive:l,active:n,coordinate:s,hasPayload:y,offset:u,position:p,reverseDirection:m,useTranslate3d:h,viewBox:g,wrapperStyle:_},Dc(o,fc(fc({},this.props),{},{payload:v})))}}])}(R.PureComponent);Cc(Oc,`displayName`,`Tooltip`),Cc(Oc,`defaultProps`,{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:`ease`,contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!lc.isSsr,itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:` : `,trigger:`hover`,useTranslate3d:!1,viewBox:{x:0,y:0,height:0,width:0},wrapperStyle:{}});var kc=t(((e,t)=>{var n=We();t.exports=function(){return n.Date.now()}})),Ac=t(((e,t)=>{var n=/\s/;function r(e){for(var t=e.length;t--&&n.test(e.charAt(t)););return t}t.exports=r})),jc=t(((e,t)=>{var n=Ac(),r=/^\s+/;function i(e){return e&&e.slice(0,n(e)+1).replace(r,``)}t.exports=i})),Mc=t(((e,t)=>{var n=jc(),r=Qe(),i=Xe(),a=NaN,o=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,c=/^0o[0-7]+$/i,l=parseInt;function u(e){if(typeof e==`number`)return e;if(i(e))return a;if(r(e)){var t=typeof e.valueOf==`function`?e.valueOf():e;e=r(t)?t+``:t}if(typeof e!=`string`)return e===0?e:+e;e=n(e);var u=s.test(e);return u||c.test(e)?l(e.slice(2),u?2:8):o.test(e)?a:+e}t.exports=u})),Nc=t(((e,t)=>{var n=Qe(),r=kc(),i=Mc(),a=`Expected a function`,o=Math.max,s=Math.min;function c(e,t,c){var l,u,d,f,p,m,h=0,g=!1,_=!1,v=!0;if(typeof e!=`function`)throw TypeError(a);t=i(t)||0,n(c)&&(g=!!c.leading,_=`maxWait`in c,d=_?o(i(c.maxWait)||0,t):d,v=`trailing`in c?!!c.trailing:v);function y(t){var n=l,r=u;return l=u=void 0,h=t,f=e.apply(r,n),f}function b(e){return h=e,p=setTimeout(C,t),g?y(e):f}function x(e){var n=e-m,r=e-h,i=t-n;return _?s(i,d-r):i}function S(e){var n=e-m,r=e-h;return m===void 0||n>=t||n<0||_&&r>=d}function C(){var e=r();if(S(e))return w(e);p=setTimeout(C,x(e))}function w(e){return p=void 0,v&&l?y(e):(l=u=void 0,f)}function T(){p!==void 0&&clearTimeout(p),h=0,l=m=u=p=void 0}function E(){return p===void 0?f:w(r())}function D(){var e=r(),n=S(e);if(l=arguments,u=this,m=e,n){if(p===void 0)return b(m);if(_)return clearTimeout(p),p=setTimeout(C,t),y(m)}return p===void 0&&(p=setTimeout(C,t)),f}return D.cancel=T,D.flush=E,D}t.exports=c})),Pc=r(t(((e,t)=>{var n=Nc(),r=Qe(),i=`Expected a function`;function a(e,t,a){var o=!0,s=!0;if(typeof e!=`function`)throw TypeError(i);return r(a)&&(o=`leading`in a?!!a.leading:o,s=`trailing`in a?!!a.trailing:s),n(e,t,{leading:o,maxWait:t,trailing:s})}t.exports=a}))());function Fc(e){"@babel/helpers - typeof";return Fc=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Fc(e)}function Ic(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 Lc(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Ic(Object(n),!0).forEach(function(t){Rc(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ic(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Rc(e,t,n){return t=zc(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zc(e){var t=Bc(e,`string`);return Fc(t)==`symbol`?t:t+``}function Bc(e,t){if(Fc(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Fc(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Vc(e,t){return Kc(e)||Gc(e,t)||Uc(e,t)||Hc()}function Hc(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
6
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Uc(e,t){if(e){if(typeof e==`string`)return Wc(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Wc(e,t)}}function Wc(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Gc(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function Kc(e){if(Array.isArray(e))return e}var qc=(0,R.forwardRef)(function(e,t){var n=e.aspect,r=e.initialDimension,i=r===void 0?{width:-1,height:-1}:r,a=e.width,o=a===void 0?`100%`:a,s=e.height,c=s===void 0?`100%`:s,l=e.minWidth,u=l===void 0?0:l,d=e.minHeight,f=e.maxHeight,p=e.children,m=e.debounce,h=m===void 0?0:m,g=e.id,_=e.className,y=e.onResize,b=e.style,x=b===void 0?{}:b,S=(0,R.useRef)(null),C=(0,R.useRef)();C.current=y,(0,R.useImperativeHandle)(t,function(){return Object.defineProperty(S.current,"current",{get:function(){return console.warn(`The usage of ref.current.current is deprecated and will no longer be supported.`),S.current},configurable:!0})});var w=Vc((0,R.useState)({containerWidth:i.width,containerHeight:i.height}),2),T=w[0],E=w[1],D=(0,R.useCallback)(function(e,t){E(function(n){var r=Math.round(e),i=Math.round(t);return n.containerWidth===r&&n.containerHeight===i?n:{containerWidth:r,containerHeight:i}})},[]);(0,R.useEffect)(function(){var e=function(e){var t,n=e[0].contentRect,r=n.width,i=n.height;D(r,i),(t=C.current)==null||t.call(C,r,i)};h>0&&(e=(0,Pc.default)(e,h,{trailing:!0,leading:!1}));var t=new ResizeObserver(e),n=S.current.getBoundingClientRect(),r=n.width,i=n.height;return D(r,i),t.observe(S.current),function(){t.disconnect()}},[D,h]);var O=(0,R.useMemo)(function(){var e=T.containerWidth,t=T.containerHeight;if(e<0||t<0)return null;Zt(o)||Zt(c);var r=Zt(o)?e:o,i=Zt(c)?t:c;n&&n>0&&(r?i=r/n:i&&(r=i*n),f&&i>f&&(i=f));var a=!Array.isArray(p)&&En(p.type).endsWith(`Chart`);return R.Children.map(p,function(e){return R.isValidElement(e)?(0,R.cloneElement)(e,Lc({width:r,height:i},a?{style:Lc({height:`100%`,width:`100%`,maxHeight:i,maxWidth:r},e.props.style)}:{})):e})},[n,p,c,f,d,u,T,o]);return R.createElement(`div`,{id:g?`${g}`:void 0,className:v(`recharts-responsive-container`,_),style:Lc(Lc({},x),{},{width:o,height:c,minWidth:u,minHeight:d,maxHeight:f}),ref:S},O)}),Jc=function(e){return null};Jc.displayName=`Cell`;function Yc(e){"@babel/helpers - typeof";return Yc=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Yc(e)}function Xc(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 Zc(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Xc(Object(n),!0).forEach(function(t){Qc(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xc(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Qc(e,t,n){return t=$c(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $c(e){var t=el(e,`string`);return Yc(t)==`symbol`?t:t+``}function el(e,t){if(Yc(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Yc(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var tl={widthCache:{},cacheCount:0},nl=2e3,rl={position:`absolute`,top:`-20000px`,left:0,padding:0,margin:0,border:`none`,whiteSpace:`pre`},il=`recharts_measurement_span`;function al(e){var t=Zc({},e);return Object.keys(t).forEach(function(e){t[e]||delete t[e]}),t}var ol=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(e==null||lc.isSsr)return{width:0,height:0};var n=al(t),r=JSON.stringify({text:e,copyStyle:n});if(tl.widthCache[r])return tl.widthCache[r];try{var i=document.getElementById(il);i||(i=document.createElement(`span`),i.setAttribute(`id`,il),i.setAttribute(`aria-hidden`,`true`),document.body.appendChild(i));var a=Zc(Zc({},rl),n);Object.assign(i.style,a),i.textContent=`${e}`;var o=i.getBoundingClientRect(),s={width:o.width,height:o.height};return tl.widthCache[r]=s,++tl.cacheCount>nl&&(tl.cacheCount=0,tl.widthCache={}),s}catch{return{width:0,height:0}}},sl=function(e){return{top:e.top+window.scrollY-document.documentElement.clientTop,left:e.left+window.scrollX-document.documentElement.clientLeft}};function cl(e){"@babel/helpers - typeof";return cl=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},cl(e)}function ll(e,t){return ml(e)||pl(e,t)||dl(e,t)||ul()}function ul(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
7
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function dl(e,t){if(e){if(typeof e==`string`)return fl(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return fl(e,t)}}function fl(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function pl(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function ml(e){if(Array.isArray(e))return e}function hl(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function gl(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,vl(r.key),r)}}function _l(e,t,n){return t&&gl(e.prototype,t),n&&gl(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function vl(e){var t=yl(e,`string`);return cl(t)==`symbol`?t:t+``}function yl(e,t){if(cl(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(cl(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var bl=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,xl=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,Sl=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,Cl=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,wl={cm:96/2.54,mm:96/25.4,pt:96/72,pc:16,in:96,Q:96/101.6,px:1},Tl=Object.keys(wl),El=`NaN`;function Dl(e,t){return e*wl[t]}var Ol=function(){function e(t,n){hl(this,e),this.num=t,this.unit=n,this.num=t,this.unit=n,Number.isNaN(t)&&(this.unit=``),n!==``&&!Sl.test(n)&&(this.num=NaN,this.unit=``),Tl.includes(n)&&(this.num=Dl(t,n),this.unit=`px`)}return _l(e,[{key:`add`,value:function(t){return this.unit===t.unit?new e(this.num+t.num,this.unit):new e(NaN,``)}},{key:`subtract`,value:function(t){return this.unit===t.unit?new e(this.num-t.num,this.unit):new e(NaN,``)}},{key:`multiply`,value:function(t){return this.unit!==``&&t.unit!==``&&this.unit!==t.unit?new e(NaN,``):new e(this.num*t.num,this.unit||t.unit)}},{key:`divide`,value:function(t){return this.unit!==``&&t.unit!==``&&this.unit!==t.unit?new e(NaN,``):new e(this.num/t.num,this.unit||t.unit)}},{key:`toString`,value:function(){return`${this.num}${this.unit}`}},{key:`isNaN`,value:function(){return Number.isNaN(this.num)}}],[{key:`parse`,value:function(t){var n=ll(Cl.exec(t)??[],3),r=n[1],i=n[2];return new e(parseFloat(r),i??``)}}])}();function kl(e){if(e.includes(El))return El;for(var t=e;t.includes(`*`)||t.includes(`/`);){var n=ll(bl.exec(t)??[],4),r=n[1],i=n[2],a=n[3],o=Ol.parse(r??``),s=Ol.parse(a??``),c=i===`*`?o.multiply(s):o.divide(s);if(c.isNaN())return El;t=t.replace(bl,c.toString())}for(;t.includes(`+`)||/.-\d+(?:\.\d+)?/.test(t);){var l=ll(xl.exec(t)??[],4),u=l[1],d=l[2],f=l[3],p=Ol.parse(u??``),m=Ol.parse(f??``),h=d===`+`?p.add(m):p.subtract(m);if(h.isNaN())return El;t=t.replace(xl,h.toString())}return t}var Al=/\(([^()]*)\)/;function jl(e){for(var t=e;t.includes(`(`);){var n=ll(Al.exec(t),2)[1];t=t.replace(Al,kl(n))}return t}function Ml(e){var t=e.replace(/\s+/g,``);return t=jl(t),t=kl(t),t}function Nl(e){try{return Ml(e)}catch{return El}}function Pl(e){var t=Nl(e.slice(5,-1));return t===El?``:t}var Fl=[`x`,`y`,`lineHeight`,`capHeight`,`scaleToFit`,`textAnchor`,`verticalAnchor`,`fill`],Il=[`dx`,`dy`,`angle`,`className`,`breakAll`];function Ll(){return Ll=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ll.apply(this,arguments)}function Rl(e,t){if(e==null)return{};var n=zl(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function zl(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Bl(e,t){return Gl(e)||Wl(e,t)||Hl(e,t)||Vl()}function Vl(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
8
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Hl(e,t){if(e){if(typeof e==`string`)return Ul(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ul(e,t)}}function Ul(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Wl(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function Gl(e){if(Array.isArray(e))return e}var Kl=/[ \f\n\r\t\v\u2028\u2029]+/,ql=function(e){var t=e.children,n=e.breakAll,r=e.style;try{var i=[];return(0,F.default)(t)||(i=n?t.toString().split(``):t.toString().split(Kl)),{wordsWithComputedWidth:i.map(function(e){return{word:e,width:ol(e,r).width}}),spaceWidth:n?0:ol(`\xA0`,r).width}}catch{return null}},Jl=function(e,t,n,r,i){var a=e.maxLines,o=e.children,s=e.style,c=e.breakAll,l=I(a),u=o,d=function(){return(arguments.length>0&&arguments[0]!==void 0?arguments[0]:[]).reduce(function(e,t){var a=t.word,o=t.width,s=e[e.length-1];if(s&&(r==null||i||s.width+o+n<Number(r)))s.words.push(a),s.width+=o+n;else{var c={words:[a],width:o};e.push(c)}return e},[])},f=d(t),p=function(e){return e.reduce(function(e,t){return e.width>t.width?e:t})};if(!l)return f;for(var m=`…`,h=function(e){var t=ql({breakAll:c,style:s,children:u.slice(0,e)+m}).wordsWithComputedWidth,n=d(t);return[n.length>a||p(n).width>Number(r),n]},g=0,_=u.length-1,v=0,y;g<=_&&v<=u.length-1;){var b=Math.floor((g+_)/2),x=Bl(h(b-1),2),S=x[0],C=x[1],w=Bl(h(b),1)[0];if(!S&&!w&&(g=b+1),S&&w&&(_=b-1),!S&&w){y=C;break}v++}return y||f},Yl=function(e){return[{words:(0,F.default)(e)?[]:e.toString().split(Kl)}]},Xl=function(e){var t=e.width,n=e.scaleToFit,r=e.children,i=e.style,a=e.breakAll,o=e.maxLines;if((t||n)&&!lc.isSsr){var s,c,l=ql({breakAll:a,children:r,style:i});if(l){var u=l.wordsWithComputedWidth,d=l.spaceWidth;s=u,c=d}else return Yl(r);return Jl({breakAll:a,children:r,maxLines:o,style:i},s,c,t,n)}return Yl(r)},Zl=`#808080`,Ql=function(e){var t=e.x,n=t===void 0?0:t,r=e.y,i=r===void 0?0:r,a=e.lineHeight,o=a===void 0?`1em`:a,s=e.capHeight,c=s===void 0?`0.71em`:s,l=e.scaleToFit,u=l!==void 0&&l,d=e.textAnchor,f=d===void 0?`start`:d,p=e.verticalAnchor,m=p===void 0?`end`:p,h=e.fill,g=h===void 0?Zl:h,_=Rl(e,Fl),y=(0,R.useMemo)(function(){return Xl({breakAll:_.breakAll,children:_.children,maxLines:_.maxLines,scaleToFit:u,style:_.style,width:_.width})},[_.breakAll,_.children,_.maxLines,u,_.style,_.width]),b=_.dx,x=_.dy,S=_.angle,C=_.className,w=_.breakAll,T=Rl(_,Il);if(!L(n)||!L(i))return null;var E=n+(I(b)?b:0),D=i+(I(x)?x:0),O;switch(m){case`start`:O=Pl(`calc(${c})`);break;case`middle`:O=Pl(`calc(${(y.length-1)/2} * -${o} + (${c} / 2))`);break;default:O=Pl(`calc(${y.length-1} * -${o})`)}var k=[];if(u){var A=y[0].width,j=_.width;k.push(`scale(${(I(j)?j/A:1)/A})`)}return S&&k.push(`rotate(${S}, ${E}, ${D})`),k.length&&(T.transform=k.join(` `)),R.createElement(`text`,Ll({},B(T,!0),{x:E,y:D,className:v(`recharts-text`,C),textAnchor:f,fill:g.includes(`url`)?Zl:g}),y.map(function(e,t){var n=e.words.join(w?``:` `);return R.createElement(`tspan`,{x:E,dy:t===0?O:o,key:`${n}-${t}`},n)}))};function $l(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function eu(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function tu(e){let t,n,r;e.length===2?(t=e===$l||e===eu?e:nu,n=e,r=e):(t=$l,n=(t,n)=>$l(e(t),n),r=(t,n)=>e(t)-n);function i(e,r,i=0,a=e.length){if(i<a){if(t(r,r)!==0)return a;do{let t=i+a>>>1;n(e[t],r)<0?i=t+1:a=t}while(i<a)}return i}function a(e,r,i=0,a=e.length){if(i<a){if(t(r,r)!==0)return a;do{let t=i+a>>>1;n(e[t],r)<=0?i=t+1:a=t}while(i<a)}return i}function o(e,t,n=0,a=e.length){let o=i(e,t,n,a-1);return o>n&&r(e[o-1],t)>-r(e[o],t)?o-1:o}return{left:i,center:o,right:a}}function nu(){return 0}function ru(e){return e===null?NaN:+e}function*iu(e,t){if(t===void 0)for(let t of e)t!=null&&(t=+t)>=t&&(yield t);else{let n=-1;for(let r of e)(r=t(r,++n,e))!=null&&(r=+r)>=r&&(yield r)}}var au=tu($l),ou=au.right;au.left,tu(ru).center;var su=class extends Map{constructor(e,t=du){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:t}}),e!=null)for(let[t,n]of e)this.set(t,n)}get(e){return super.get(cu(this,e))}has(e){return super.has(cu(this,e))}set(e,t){return super.set(lu(this,e),t)}delete(e){return super.delete(uu(this,e))}};function cu({_intern:e,_key:t},n){let r=t(n);return e.has(r)?e.get(r):n}function lu({_intern:e,_key:t},n){let r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function uu({_intern:e,_key:t},n){let r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function du(e){return typeof e==`object`&&e?e.valueOf():e}function fu(e=$l){if(e===$l)return pu;if(typeof e!=`function`)throw TypeError(`compare is not a function`);return(t,n)=>{let r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function pu(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:+(e>t))}var mu=Math.sqrt(50),hu=Math.sqrt(10),gu=Math.sqrt(2);function _u(e,t,n){let r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),a=r/10**i,o=a>=mu?10:a>=hu?5:a>=gu?2:1,s,c,l;return i<0?(l=10**-i/o,s=Math.round(e*l),c=Math.round(t*l),s/l<e&&++s,c/l>t&&--c,l=-l):(l=10**i*o,s=Math.round(e/l),c=Math.round(t/l),s*l<e&&++s,c*l>t&&--c),c<s&&.5<=n&&n<2?_u(e,t,n*2):[s,c,l]}function vu(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];let r=t<e,[i,a,o]=r?_u(t,e,n):_u(e,t,n);if(!(a>=i))return[];let s=a-i+1,c=Array(s);if(r){if(o<0)for(let e=0;e<s;++e)c[e]=(a-e)/-o;else for(let e=0;e<s;++e)c[e]=(a-e)*o}else if(o<0)for(let e=0;e<s;++e)c[e]=(i+e)/-o;else for(let e=0;e<s;++e)c[e]=(i+e)*o;return c}function yu(e,t,n){return t=+t,e=+e,n=+n,_u(e,t,n)[2]}function bu(e,t,n){t=+t,e=+e,n=+n;let r=t<e,i=r?yu(t,e,n):yu(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function xu(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n<t||n===void 0&&t>=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n<i||n===void 0&&i>=i)&&(n=i)}return n}function Su(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n>t||n===void 0&&t>=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}return n}function Cu(e,t,n=0,r=1/0,i){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(i=i===void 0?pu:fu(i);r>n;){if(r-n>600){let a=r-n+1,o=t-n+1,s=Math.log(a),c=.5*Math.exp(2*s/3),l=.5*Math.sqrt(s*c*(a-c)/a)*(o-a/2<0?-1:1),u=Math.max(n,Math.floor(t-o*c/a+l)),d=Math.min(r,Math.floor(t+(a-o)*c/a+l));Cu(e,t,u,d,i)}let a=e[t],o=n,s=r;for(wu(e,n,t),i(e[r],a)>0&&wu(e,n,r);o<s;){for(wu(e,o,s),++o,--s;i(e[o],a)<0;)++o;for(;i(e[s],a)>0;)--s}i(e[n],a)===0?wu(e,n,s):(++s,wu(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function wu(e,t,n){let r=e[t];e[t]=e[n],e[n]=r}function Tu(e,t,n){if(e=Float64Array.from(iu(e,n)),(r=e.length)&&!isNaN(t=+t)){if(t<=0||r<2)return Su(e);if(t>=1)return xu(e);var r,i=(r-1)*t,a=Math.floor(i),o=xu(Cu(e,a).subarray(0,a+1));return o+(Su(e.subarray(a+1))-o)*(i-a)}}function Eu(e,t,n=ru){if((r=e.length)&&!isNaN(t=+t)){if(t<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,i=(r-1)*t,a=Math.floor(i),o=+n(e[a],a,e);return o+(+n(e[a+1],a+1,e)-o)*(i-a)}}function Du(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,a=Array(i);++r<i;)a[r]=e+r*n;return a}function Ou(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}function ku(e,t){switch(arguments.length){case 0:break;case 1:typeof e==`function`?this.interpolator(e):this.range(e);break;default:this.domain(e),typeof t==`function`?this.interpolator(t):this.range(t)}return this}var Au=Symbol(`implicit`);function ju(){var e=new su,t=[],n=[],r=Au;function i(i){let a=e.get(i);if(a===void 0){if(r!==Au)return r;e.set(i,a=t.push(i)-1)}return n[a%n.length]}return i.domain=function(n){if(!arguments.length)return t.slice();t=[],e=new su;for(let r of n)e.has(r)||e.set(r,t.push(r)-1);return i},i.range=function(e){return arguments.length?(n=Array.from(e),i):n.slice()},i.unknown=function(e){return arguments.length?(r=e,i):r},i.copy=function(){return ju(t,n).unknown(r)},Ou.apply(i,arguments),i}function Mu(){var e=ju().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,a,o,s=!1,c=0,l=0,u=.5;delete e.unknown;function d(){var e=t().length,d=i<r,f=d?i:r,p=d?r:i;a=(p-f)/Math.max(1,e-c+l*2),s&&(a=Math.floor(a)),f+=(p-f-a*(e-c))*u,o=a*(1-c),s&&(f=Math.round(f),o=Math.round(o));var m=Du(e).map(function(e){return f+a*e});return n(d?m.reverse():m)}return e.domain=function(e){return arguments.length?(t(e),d()):t()},e.range=function(e){return arguments.length?([r,i]=e,r=+r,i=+i,d()):[r,i]},e.rangeRound=function(e){return[r,i]=e,r=+r,i=+i,s=!0,d()},e.bandwidth=function(){return o},e.step=function(){return a},e.round=function(e){return arguments.length?(s=!!e,d()):s},e.padding=function(e){return arguments.length?(c=Math.min(1,l=+e),d()):c},e.paddingInner=function(e){return arguments.length?(c=Math.min(1,e),d()):c},e.paddingOuter=function(e){return arguments.length?(l=+e,d()):l},e.align=function(e){return arguments.length?(u=Math.max(0,Math.min(1,e)),d()):u},e.copy=function(){return Mu(t(),[r,i]).round(s).paddingInner(c).paddingOuter(l).align(u)},Ou.apply(d(),arguments)}function Nu(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return Nu(t())},e}function Pu(){return Nu(Mu.apply(null,arguments).paddingInner(1))}function Fu(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Iu(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Lu(){}var Ru=.7,zu=1/Ru,Bu=`\\s*([+-]?\\d+)\\s*`,Vu=`\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*`,Hu=`\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*`,Uu=/^#([0-9a-f]{3,8})$/,Wu=RegExp(`^rgb\\(${Bu},${Bu},${Bu}\\)$`),Gu=RegExp(`^rgb\\(${Hu},${Hu},${Hu}\\)$`),Ku=RegExp(`^rgba\\(${Bu},${Bu},${Bu},${Vu}\\)$`),qu=RegExp(`^rgba\\(${Hu},${Hu},${Hu},${Vu}\\)$`),Ju=RegExp(`^hsl\\(${Vu},${Hu},${Hu}\\)$`),Yu=RegExp(`^hsla\\(${Vu},${Hu},${Hu},${Vu}\\)$`),Xu={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Fu(Lu,td,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Zu,formatHex:Zu,formatHex8:Qu,formatHsl:$u,formatRgb:ed,toString:ed});function Zu(){return this.rgb().formatHex()}function Qu(){return this.rgb().formatHex8()}function $u(){return md(this).formatHsl()}function ed(){return this.rgb().formatRgb()}function td(e){var t,n;return e=(e+``).trim().toLowerCase(),(t=Uu.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?nd(t):n===3?new od(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?rd(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?rd(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=Wu.exec(e))?new od(t[1],t[2],t[3],1):(t=Gu.exec(e))?new od(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=Ku.exec(e))?rd(t[1],t[2],t[3],t[4]):(t=qu.exec(e))?rd(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=Ju.exec(e))?pd(t[1],t[2]/100,t[3]/100,1):(t=Yu.exec(e))?pd(t[1],t[2]/100,t[3]/100,t[4]):Xu.hasOwnProperty(e)?nd(Xu[e]):e===`transparent`?new od(NaN,NaN,NaN,0):null}function nd(e){return new od(e>>16&255,e>>8&255,e&255,1)}function rd(e,t,n,r){return r<=0&&(e=t=n=NaN),new od(e,t,n,r)}function id(e){return e instanceof Lu||(e=td(e)),e?(e=e.rgb(),new od(e.r,e.g,e.b,e.opacity)):new od}function ad(e,t,n,r){return arguments.length===1?id(e):new od(e,t,n,r??1)}function od(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}Fu(od,ad,Iu(Lu,{brighter(e){return e=e==null?zu:zu**+e,new od(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Ru:Ru**+e,new od(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new od(dd(this.r),dd(this.g),dd(this.b),ud(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:sd,formatHex:sd,formatHex8:cd,formatRgb:ld,toString:ld}));function sd(){return`#${fd(this.r)}${fd(this.g)}${fd(this.b)}`}function cd(){return`#${fd(this.r)}${fd(this.g)}${fd(this.b)}${fd((isNaN(this.opacity)?1:this.opacity)*255)}`}function ld(){let e=ud(this.opacity);return`${e===1?`rgb(`:`rgba(`}${dd(this.r)}, ${dd(this.g)}, ${dd(this.b)}${e===1?`)`:`, ${e})`}`}function ud(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function dd(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function fd(e){return e=dd(e),(e<16?`0`:``)+e.toString(16)}function pd(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new gd(e,t,n,r)}function md(e){if(e instanceof gd)return new gd(e.h,e.s,e.l,e.opacity);if(e instanceof Lu||(e=td(e)),!e)return new gd;if(e instanceof gd)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),a=Math.max(t,n,r),o=NaN,s=a-i,c=(a+i)/2;return s?(o=t===a?(n-r)/s+(n<r)*6:n===a?(r-t)/s+2:(t-n)/s+4,s/=c<.5?a+i:2-a-i,o*=60):s=c>0&&c<1?0:o,new gd(o,s,c,e.opacity)}function hd(e,t,n,r){return arguments.length===1?md(e):new gd(e,t,n,r??1)}function gd(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}Fu(gd,hd,Iu(Lu,{brighter(e){return e=e==null?zu:zu**+e,new gd(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Ru:Ru**+e,new gd(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new od(yd(e>=240?e-240:e+120,i,r),yd(e,i,r),yd(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new gd(_d(this.h),vd(this.s),vd(this.l),ud(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){let e=ud(this.opacity);return`${e===1?`hsl(`:`hsla(`}${_d(this.h)}, ${vd(this.s)*100}%, ${vd(this.l)*100}%${e===1?`)`:`, ${e})`}`}}));function _d(e){return e=(e||0)%360,e<0?e+360:e}function vd(e){return Math.max(0,Math.min(1,e||0))}function yd(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}var bd=e=>()=>e;function xd(e,t){return function(n){return e+n*t}}function Sd(e,t,n){return e**=+n,t=t**+n-e,n=1/n,function(r){return(e+r*t)**+n}}function Cd(e){return(e=+e)==1?wd:function(t,n){return n-t?Sd(t,n,e):bd(isNaN(t)?n:t)}}function wd(e,t){var n=t-e;return n?xd(e,n):bd(isNaN(e)?t:e)}var Td=(function e(t){var n=Cd(t);function r(e,t){var r=n((e=ad(e)).r,(t=ad(t)).r),i=n(e.g,t.g),a=n(e.b,t.b),o=wd(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=i(t),e.b=a(t),e.opacity=o(t),e+``}}return r.gamma=e,r})(1);function Ed(e,t){t||=[];var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(a){for(i=0;i<n;++i)r[i]=e[i]*(1-a)+t[i]*a;return r}}function Dd(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function Od(e,t){for(var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=Array(r),a=Array(n),o=0;o<r;++o)i[o]=Ld(e[o],t[o]);for(;o<n;++o)a[o]=t[o];return function(e){for(o=0;o<r;++o)a[o]=i[o](e);return a}}function kd(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Ad(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function jd(e,t){var n={},r={},i;for(i in(typeof e!=`object`||!e)&&(e={}),(typeof t!=`object`||!t)&&(t={}),t)i in e?n[i]=Ld(e[i],t[i]):r[i]=t[i];return function(e){for(i in n)r[i]=n[i](e);return r}}var Md=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Nd=new RegExp(Md.source,`g`);function Pd(e){return function(){return e}}function Fd(e){return function(t){return e(t)+``}}function Id(e,t){var n=Md.lastIndex=Nd.lastIndex=0,r,i,a,o=-1,s=[],c=[];for(e+=``,t+=``;(r=Md.exec(e))&&(i=Nd.exec(t));)(a=i.index)>n&&(a=t.slice(n,a),s[o]?s[o]+=a:s[++o]=a),(r=r[0])===(i=i[0])?s[o]?s[o]+=i:s[++o]=i:(s[++o]=null,c.push({i:o,x:Ad(r,i)})),n=Nd.lastIndex;return n<t.length&&(a=t.slice(n),s[o]?s[o]+=a:s[++o]=a),s.length<2?c[0]?Fd(c[0].x):Pd(t):(t=c.length,function(e){for(var n=0,r;n<t;++n)s[(r=c[n]).i]=r.x(e);return s.join(``)})}function Ld(e,t){var n=typeof t,r;return t==null||n===`boolean`?bd(t):(n===`number`?Ad:n===`string`?(r=td(t))?(t=r,Td):Id:t instanceof td?Td:t instanceof Date?kd:Dd(t)?Ed:Array.isArray(t)?Od:typeof t.valueOf!=`function`&&typeof t.toString!=`function`||isNaN(t)?jd:Ad)(e,t)}function Rd(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function zd(e,t){t===void 0&&(t=e,e=Ld);for(var n=0,r=t.length-1,i=t[0],a=Array(r<0?0:r);n<r;)a[n]=e(i,i=t[++n]);return function(e){var t=Math.max(0,Math.min(r-1,Math.floor(e*=r)));return a[t](e-t)}}function Bd(e){return function(){return e}}function Vd(e){return+e}var Hd=[0,1];function Ud(e){return e}function Wd(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:Bd(isNaN(t)?NaN:.5)}function Gd(e,t){var n;return e>t&&(n=e,e=t,t=n),function(n){return Math.max(e,Math.min(t,n))}}function Kd(e,t,n){var r=e[0],i=e[1],a=t[0],o=t[1];return i<r?(r=Wd(i,r),a=n(o,a)):(r=Wd(r,i),a=n(a,o)),function(e){return a(r(e))}}function qd(e,t,n){var r=Math.min(e.length,t.length)-1,i=Array(r),a=Array(r),o=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++o<r;)i[o]=Wd(e[o],e[o+1]),a[o]=n(t[o],t[o+1]);return function(t){var n=ou(e,t,1,r)-1;return a[n](i[n](t))}}function Jd(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Yd(){var e=Hd,t=Hd,n=Ld,r,i,a,o=Ud,s,c,l;function u(){var n=Math.min(e.length,t.length);return o!==Ud&&(o=Gd(e[0],e[n-1])),s=n>2?qd:Kd,c=l=null,d}function d(i){return i==null||isNaN(i=+i)?a:(c||=s(e.map(r),t,n))(r(o(i)))}return d.invert=function(n){return o(i((l||=s(t,e.map(r),Ad))(n)))},d.domain=function(t){return arguments.length?(e=Array.from(t,Vd),u()):e.slice()},d.range=function(e){return arguments.length?(t=Array.from(e),u()):t.slice()},d.rangeRound=function(e){return t=Array.from(e),n=Rd,u()},d.clamp=function(e){return arguments.length?(o=e?!0:Ud,u()):o!==Ud},d.interpolate=function(e){return arguments.length?(n=e,u()):n},d.unknown=function(e){return arguments.length?(a=e,d):a},function(e,t){return r=e,i=t,u()}}function Xd(){return Yd()(Ud,Ud)}function Zd(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString(`en`).replace(/,/g,``):e.toString(10)}function Qd(e,t){if(!isFinite(e)||e===0)return null;var n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf(`e`),r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function $d(e){return e=Qd(Math.abs(e)),e?e[1]:NaN}function ef(e,t){return function(n,r){for(var i=n.length,a=[],o=0,s=e[0],c=0;i>0&&s>0&&(c+s+1>r&&(s=Math.max(1,r-c)),a.push(n.substring(i-=s,i+s)),!((c+=s+1)>r));)s=e[o=(o+1)%e.length];return a.reverse().join(t)}}function tf(e){return function(t){return t.replace(/[0-9]/g,function(t){return e[+t]})}}var nf=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function rf(e){if(!(t=nf.exec(e)))throw Error(`invalid format: `+e);var t;return new af({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}rf.prototype=af.prototype;function af(e){this.fill=e.fill===void 0?` `:e.fill+``,this.align=e.align===void 0?`>`:e.align+``,this.sign=e.sign===void 0?`-`:e.sign+``,this.symbol=e.symbol===void 0?``:e.symbol+``,this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?``:e.type+``}af.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?`0`:``)+(this.width===void 0?``:Math.max(1,this.width|0))+(this.comma?`,`:``)+(this.precision===void 0?``:`.`+Math.max(0,this.precision|0))+(this.trim?`~`:``)+this.type};function of(e){out:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case`.`:r=i=n;break;case`0`:r===0&&(r=n),i=n;break;default:if(!+e[n])break out;r>0&&(r=0)}return r>0?e.slice(0,r)+e.slice(i+1):e}var sf;function cf(e,t){var n=Qd(e,t);if(!n)return sf=void 0,e.toPrecision(t);var r=n[0],i=n[1],a=i-(sf=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,o=r.length;return a===o?r:a>o?r+Array(a-o+1).join(`0`):a>0?r.slice(0,a)+`.`+r.slice(a):`0.`+Array(1-a).join(`0`)+Qd(e,Math.max(0,t+a-1))[0]}function lf(e,t){var n=Qd(e,t);if(!n)return e+``;var r=n[0],i=n[1];return i<0?`0.`+Array(-i).join(`0`)+r:r.length>i+1?r.slice(0,i+1)+`.`+r.slice(i+1):r+Array(i-r.length+2).join(`0`)}var uf={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+``,d:Zd,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>lf(e*100,t),r:lf,s:cf,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function df(e){return e}var ff=Array.prototype.map,pf=[`y`,`z`,`a`,`f`,`p`,`n`,`µ`,`m`,``,`k`,`M`,`G`,`T`,`P`,`E`,`Z`,`Y`];function mf(e){var t=e.grouping===void 0||e.thousands===void 0?df:ef(ff.call(e.grouping,Number),e.thousands+``),n=e.currency===void 0?``:e.currency[0]+``,r=e.currency===void 0?``:e.currency[1]+``,i=e.decimal===void 0?`.`:e.decimal+``,a=e.numerals===void 0?df:tf(ff.call(e.numerals,String)),o=e.percent===void 0?`%`:e.percent+``,s=e.minus===void 0?`−`:e.minus+``,c=e.nan===void 0?`NaN`:e.nan+``;function l(e,l){e=rf(e);var u=e.fill,d=e.align,f=e.sign,p=e.symbol,m=e.zero,h=e.width,g=e.comma,_=e.precision,v=e.trim,y=e.type;y===`n`?(g=!0,y=`g`):uf[y]||(_===void 0&&(_=12),v=!0,y=`g`),(m||u===`0`&&d===`=`)&&(m=!0,u=`0`,d=`=`);var b=(l&&l.prefix!==void 0?l.prefix:``)+(p===`$`?n:p===`#`&&/[boxX]/.test(y)?`0`+y.toLowerCase():``),x=(p===`$`?r:/[%p]/.test(y)?o:``)+(l&&l.suffix!==void 0?l.suffix:``),S=uf[y],C=/[defgprs%]/.test(y);_=_===void 0?6:/[gprs]/.test(y)?Math.max(1,Math.min(21,_)):Math.max(0,Math.min(20,_));function w(e){var n=b,r=x,o,l,p;if(y===`c`)r=S(e)+r,e=``;else{e=+e;var w=e<0||1/e<0;if(e=isNaN(e)?c:S(Math.abs(e),_),v&&(e=of(e)),w&&+e==0&&f!==`+`&&(w=!1),n=(w?f===`(`?f:s:f===`-`||f===`(`?``:f)+n,r=(y===`s`&&!isNaN(e)&&sf!==void 0?pf[8+sf/3]:``)+r+(w&&f===`(`?`)`:``),C){for(o=-1,l=e.length;++o<l;)if(p=e.charCodeAt(o),48>p||p>57){r=(p===46?i+e.slice(o+1):e.slice(o))+r,e=e.slice(0,o);break}}}g&&!m&&(e=t(e,1/0));var T=n.length+e.length+r.length,E=T<h?Array(h-T+1).join(u):``;switch(g&&m&&(e=t(E+e,E.length?h-r.length:1/0),E=``),d){case`<`:e=n+e+r+E;break;case`=`:e=n+E+e+r;break;case`^`:e=E.slice(0,T=E.length>>1)+n+e+r+E.slice(T);break;default:e=E+n+e+r}return a(e)}return w.toString=function(){return e+``},w}function u(e,t){var n=Math.max(-8,Math.min(8,Math.floor($d(t)/3)))*3,r=10**-n,i=l((e=rf(e),e.type=`f`,e),{suffix:pf[8+n/3]});return function(e){return i(r*e)}}return{format:l,formatPrefix:u}}var hf,gf,_f;vf({thousands:`,`,grouping:[3],currency:[`$`,``]});function vf(e){return hf=mf(e),gf=hf.format,_f=hf.formatPrefix,hf}function yf(e){return Math.max(0,-$d(Math.abs(e)))}function bf(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor($d(t)/3)))*3-$d(Math.abs(e)))}function xf(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,$d(t)-$d(e))+1}function Sf(e,t,n,r){var i=bu(e,t,n),a;switch(r=rf(r??`,f`),r.type){case`s`:var o=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(a=bf(i,o))&&(r.precision=a),_f(r,o);case``:case`e`:case`g`:case`p`:case`r`:r.precision==null&&!isNaN(a=xf(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=a-(r.type===`e`));break;case`f`:case`%`:r.precision==null&&!isNaN(a=yf(i))&&(r.precision=a-(r.type===`%`)*2)}return gf(r)}function Cf(e){var t=e.domain;return e.ticks=function(e){var n=t();return vu(n[0],n[n.length-1],e??10)},e.tickFormat=function(e,n){var r=t();return Sf(r[0],r[r.length-1],e??10,n)},e.nice=function(n){n??=10;var r=t(),i=0,a=r.length-1,o=r[i],s=r[a],c,l,u=10;for(s<o&&(l=o,o=s,s=l,l=i,i=a,a=l);u-->0;){if(l=yu(o,s,n),l===c)return r[i]=o,r[a]=s,t(r);if(l>0)o=Math.floor(o/l)*l,s=Math.ceil(s/l)*l;else if(l<0)o=Math.ceil(o*l)/l,s=Math.floor(s*l)/l;else break;c=l}return e},e}function wf(){var e=Xd();return e.copy=function(){return Jd(e,wf())},Ou.apply(e,arguments),Cf(e)}function Tf(e){var t;function n(e){return e==null||isNaN(e=+e)?t:e}return n.invert=n,n.domain=n.range=function(t){return arguments.length?(e=Array.from(t,Vd),n):e.slice()},n.unknown=function(e){return arguments.length?(t=e,n):t},n.copy=function(){return Tf(e).unknown(t)},e=arguments.length?Array.from(e,Vd):[0,1],Cf(n)}function Ef(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],a=e[r],o;return a<i&&(o=n,n=r,r=o,o=i,i=a,a=o),e[n]=t.floor(i),e[r]=t.ceil(a),e}function Df(e){return Math.log(e)}function Of(e){return Math.exp(e)}function kf(e){return-Math.log(-e)}function Af(e){return-Math.exp(-e)}function jf(e){return isFinite(e)?+(`1e`+e):e<0?0:e}function Mf(e){return e===10?jf:e===Math.E?Math.exp:t=>e**+t}function Nf(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function Pf(e){return(t,n)=>-e(-t,n)}function Ff(e){let t=e(Df,Of),n=t.domain,r=10,i,a;function o(){return i=Nf(r),a=Mf(r),n()[0]<0?(i=Pf(i),a=Pf(a),e(kf,Af)):e(Df,Of),t}return t.base=function(e){return arguments.length?(r=+e,o()):r},t.domain=function(e){return arguments.length?(n(e),o()):n()},t.ticks=e=>{let t=n(),o=t[0],s=t[t.length-1],c=s<o;c&&([o,s]=[s,o]);let l=i(o),u=i(s),d,f,p=e==null?10:+e,m=[];if(!(r%1)&&u-l<p){if(l=Math.floor(l),u=Math.ceil(u),o>0){for(;l<=u;++l)for(d=1;d<r;++d)if(f=l<0?d/a(-l):d*a(l),!(f<o)){if(f>s)break;m.push(f)}}else for(;l<=u;++l)for(d=r-1;d>=1;--d)if(f=l>0?d/a(-l):d*a(l),!(f<o)){if(f>s)break;m.push(f)}m.length*2<p&&(m=vu(o,s,p))}else m=vu(l,u,Math.min(u-l,p)).map(a);return c?m.reverse():m},t.tickFormat=(e,n)=>{if(e??=10,n??=r===10?`s`:`,`,typeof n!=`function`&&(!(r%1)&&(n=rf(n)).precision==null&&(n.trim=!0),n=gf(n)),e===1/0)return n;let o=Math.max(1,r*e/t.ticks().length);return e=>{let t=e/a(Math.round(i(e)));return t*r<r-.5&&(t*=r),t<=o?n(e):``}},t.nice=()=>n(Ef(n(),{floor:e=>a(Math.floor(i(e))),ceil:e=>a(Math.ceil(i(e)))})),t}function If(){let e=Ff(Yd()).domain([1,10]);return e.copy=()=>Jd(e,If()).base(e.base()),Ou.apply(e,arguments),e}function Lf(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function Rf(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function zf(e){var t=1,n=e(Lf(t),Rf(t));return n.constant=function(n){return arguments.length?e(Lf(t=+n),Rf(t)):t},Cf(n)}function Bf(){var e=zf(Yd());return e.copy=function(){return Jd(e,Bf()).constant(e.constant())},Ou.apply(e,arguments)}function Vf(e){return function(t){return t<0?-((-t)**+e):t**+e}}function Hf(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function Uf(e){return e<0?-e*e:e*e}function Wf(e){var t=e(Ud,Ud),n=1;function r(){return n===1?e(Ud,Ud):n===.5?e(Hf,Uf):e(Vf(n),Vf(1/n))}return t.exponent=function(e){return arguments.length?(n=+e,r()):n},Cf(t)}function Gf(){var e=Wf(Yd());return e.copy=function(){return Jd(e,Gf()).exponent(e.exponent())},Ou.apply(e,arguments),e}function Kf(){return Gf.apply(null,arguments).exponent(.5)}function qf(e){return Math.sign(e)*e*e}function Jf(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function Yf(){var e=Xd(),t=[0,1],n=!1,r;function i(t){var i=Jf(e(t));return isNaN(i)?r:n?Math.round(i):i}return i.invert=function(t){return e.invert(qf(t))},i.domain=function(t){return arguments.length?(e.domain(t),i):e.domain()},i.range=function(n){return arguments.length?(e.range((t=Array.from(n,Vd)).map(qf)),i):t.slice()},i.rangeRound=function(e){return i.range(e).round(!0)},i.round=function(e){return arguments.length?(n=!!e,i):n},i.clamp=function(t){return arguments.length?(e.clamp(t),i):e.clamp()},i.unknown=function(e){return arguments.length?(r=e,i):r},i.copy=function(){return Yf(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},Ou.apply(i,arguments),Cf(i)}function Xf(){var e=[],t=[],n=[],r;function i(){var r=0,i=Math.max(1,t.length);for(n=Array(i-1);++r<i;)n[r-1]=Eu(e,r/i);return a}function a(e){return e==null||isNaN(e=+e)?r:t[ou(n,e)]}return a.invertExtent=function(r){var i=t.indexOf(r);return i<0?[NaN,NaN]:[i>0?n[i-1]:e[0],i<n.length?n[i]:e[e.length-1]]},a.domain=function(t){if(!arguments.length)return e.slice();e=[];for(let n of t)n!=null&&!isNaN(n=+n)&&e.push(n);return e.sort($l),i()},a.range=function(e){return arguments.length?(t=Array.from(e),i()):t.slice()},a.unknown=function(e){return arguments.length?(r=e,a):r},a.quantiles=function(){return n.slice()},a.copy=function(){return Xf().domain(e).range(t).unknown(r)},Ou.apply(a,arguments)}function Zf(){var e=0,t=1,n=1,r=[.5],i=[0,1],a;function o(e){return e!=null&&e<=e?i[ou(r,e,0,n)]:a}function s(){var i=-1;for(r=Array(n);++i<n;)r[i]=((i+1)*t-(i-n)*e)/(n+1);return o}return o.domain=function(n){return arguments.length?([e,t]=n,e=+e,t=+t,s()):[e,t]},o.range=function(e){return arguments.length?(n=(i=Array.from(e)).length-1,s()):i.slice()},o.invertExtent=function(a){var o=i.indexOf(a);return o<0?[NaN,NaN]:o<1?[e,r[0]]:o>=n?[r[n-1],t]:[r[o-1],r[o]]},o.unknown=function(e){return arguments.length&&(a=e),o},o.thresholds=function(){return r.slice()},o.copy=function(){return Zf().domain([e,t]).range(i).unknown(a)},Ou.apply(Cf(o),arguments)}function Qf(){var e=[.5],t=[0,1],n,r=1;function i(i){return i!=null&&i<=i?t[ou(e,i,0,r)]:n}return i.domain=function(n){return arguments.length?(e=Array.from(n),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(n){return arguments.length?(t=Array.from(n),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(n){var r=t.indexOf(n);return[e[r-1],e[r]]},i.unknown=function(e){return arguments.length?(n=e,i):n},i.copy=function(){return Qf().domain(e).range(t).unknown(n)},Ou.apply(i,arguments)}var $f=new Date,ep=new Date;function U(e,t,n,r){function i(t){return e(t=arguments.length===0?new Date:new Date(+t)),t}return i.floor=t=>(e(t=new Date(+t)),t),i.ceil=n=>(e(n=new Date(n-1)),t(n,1),e(n),n),i.round=e=>{let t=i(e),n=i.ceil(e);return e-t<n-e?t:n},i.offset=(e,n)=>(t(e=new Date(+e),n==null?1:Math.floor(n)),e),i.range=(n,r,a)=>{let o=[];if(n=i.ceil(n),a=a==null?1:Math.floor(a),!(n<r)||!(a>0))return o;let s;do o.push(s=new Date(+n)),t(n,a),e(n);while(s<n&&n<r);return o},i.filter=n=>U(t=>{if(t>=t)for(;e(t),!n(t);)t.setTime(t-1)},(e,r)=>{if(e>=e){if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););}}),n&&(i.count=(t,r)=>($f.setTime(+t),ep.setTime(+r),e($f),e(ep),Math.floor(n($f,ep))),i.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?i.filter(r?t=>r(t)%e===0:t=>i.count(0,t)%e===0):i)),i}var tp=U(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);tp.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?U(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):tp),tp.range;var np=1e3,rp=np*60,ip=rp*60,ap=ip*24,op=ap*7,sp=ap*30,cp=ap*365,lp=U(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*np)},(e,t)=>(t-e)/np,e=>e.getUTCSeconds());lp.range;var up=U(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*np)},(e,t)=>{e.setTime(+e+t*rp)},(e,t)=>(t-e)/rp,e=>e.getMinutes());up.range;var dp=U(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*rp)},(e,t)=>(t-e)/rp,e=>e.getUTCMinutes());dp.range;var fp=U(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*np-e.getMinutes()*rp)},(e,t)=>{e.setTime(+e+t*ip)},(e,t)=>(t-e)/ip,e=>e.getHours());fp.range;var pp=U(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*ip)},(e,t)=>(t-e)/ip,e=>e.getUTCHours());pp.range;var mp=U(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*rp)/ap,e=>e.getDate()-1);mp.range;var hp=U(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ap,e=>e.getUTCDate()-1);hp.range;var gp=U(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ap,e=>Math.floor(e/ap));gp.range;function _p(e){return U(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(e,t)=>{e.setDate(e.getDate()+t*7)},(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*rp)/op)}var vp=_p(0),yp=_p(1),bp=_p(2),xp=_p(3),Sp=_p(4),Cp=_p(5),wp=_p(6);vp.range,yp.range,bp.range,xp.range,Sp.range,Cp.range,wp.range;function Tp(e){return U(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t*7)},(e,t)=>(t-e)/op)}var Ep=Tp(0),Dp=Tp(1),Op=Tp(2),kp=Tp(3),Ap=Tp(4),jp=Tp(5),Mp=Tp(6);Ep.range,Dp.range,Op.range,kp.range,Ap.range,jp.range,Mp.range;var Np=U(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());Np.range;var Pp=U(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());Pp.range;var Fp=U(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());Fp.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:U(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)}),Fp.range;var Ip=U(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());Ip.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:U(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)}),Ip.range;function Lp(e,t,n,r,i,a){let o=[[lp,1,np],[lp,5,5*np],[lp,15,15*np],[lp,30,30*np],[a,1,rp],[a,5,5*rp],[a,15,15*rp],[a,30,30*rp],[i,1,ip],[i,3,3*ip],[i,6,6*ip],[i,12,12*ip],[r,1,ap],[r,2,2*ap],[n,1,op],[t,1,sp],[t,3,3*sp],[e,1,cp]];function s(e,t,n){let r=t<e;r&&([e,t]=[t,e]);let i=n&&typeof n.range==`function`?n:c(e,t,n),a=i?i.range(e,+t+1):[];return r?a.reverse():a}function c(t,n,r){let i=Math.abs(n-t)/r,a=tu(([,,e])=>e).right(o,i);if(a===o.length)return e.every(bu(t/cp,n/cp,r));if(a===0)return tp.every(Math.max(bu(t,n,r),1));let[s,c]=o[i/o[a-1][2]<o[a][2]/i?a-1:a];return s.every(c)}return[s,c]}var[Rp,zp]=Lp(Ip,Pp,Ep,gp,pp,dp),[Bp,Vp]=Lp(Fp,Np,vp,mp,fp,up);function Hp(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function Up(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function Wp(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function Gp(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,a=e.days,o=e.shortDays,s=e.months,c=e.shortMonths,l=Zp(i),u=Qp(i),d=Zp(a),f=Qp(a),p=Zp(o),m=Qp(o),h=Zp(s),g=Qp(s),_=Zp(c),v=Qp(c),y={a:N,A:ee,b:te,B:ne,c:null,d:ym,e:ym,f:wm,g:Fm,G:Lm,H:bm,I:xm,j:Sm,L:Cm,m:Tm,M:Em,p:re,q:ie,Q:oh,s:sh,S:Dm,u:Om,U:km,V:jm,w:Mm,W:Nm,x:null,X:null,y:Pm,Y:Im,Z:Rm,"%":ah},b={a:ae,A:oe,b:se,B:ce,c:null,d:zm,e:zm,f:Wm,g:th,G:rh,H:Bm,I:Vm,j:Hm,L:Um,m:Gm,M:Km,p:le,q:ue,Q:oh,s:sh,S:qm,u:Jm,U:Ym,V:Zm,w:Qm,W:$m,x:null,X:null,y:eh,Y:nh,Z:ih,"%":ah},x={a:E,A:D,b:O,B:k,c:A,d:lm,e:lm,f:hm,g:am,G:im,H:dm,I:dm,j:um,L:mm,m:cm,M:fm,p:T,q:sm,Q:_m,s:vm,S:pm,u:em,U:tm,V:nm,w:$p,W:rm,x:j,X:M,y:am,Y:im,Z:om,"%":gm};y.x=S(n,y),y.X=S(r,y),y.c=S(t,y),b.x=S(n,b),b.X=S(r,b),b.c=S(t,b);function S(e,t){return function(n){var r=[],i=-1,a=0,o=e.length,s,c,l;for(n instanceof Date||(n=new Date(+n));++i<o;)e.charCodeAt(i)===37&&(r.push(e.slice(a,i)),(c=Kp[s=e.charAt(++i)])==null?c=s===`e`?` `:`0`:s=e.charAt(++i),(l=t[s])&&(s=l(n,c)),r.push(s),a=i+1);return r.push(e.slice(a,i)),r.join(``)}}function C(e,t){return function(n){var r=Wp(1900,void 0,1),i=w(r,e,n+=``,0),a,o;if(i!=n.length)return null;if(`Q`in r)return new Date(r.Q);if(`s`in r)return new Date(r.s*1e3+(`L`in r?r.L:0));if(t&&!(`Z`in r)&&(r.Z=0),`p`in r&&(r.H=r.H%12+r.p*12),r.m===void 0&&(r.m=`q`in r?r.q:0),`V`in r){if(r.V<1||r.V>53)return null;`w`in r||(r.w=1),`Z`in r?(a=Up(Wp(r.y,0,1)),o=a.getUTCDay(),a=o>4||o===0?Dp.ceil(a):Dp(a),a=hp.offset(a,(r.V-1)*7),r.y=a.getUTCFullYear(),r.m=a.getUTCMonth(),r.d=a.getUTCDate()+(r.w+6)%7):(a=Hp(Wp(r.y,0,1)),o=a.getDay(),a=o>4||o===0?yp.ceil(a):yp(a),a=mp.offset(a,(r.V-1)*7),r.y=a.getFullYear(),r.m=a.getMonth(),r.d=a.getDate()+(r.w+6)%7)}else(`W`in r||`U`in r)&&(`w`in r||(r.w=`u`in r?r.u%7:+(`W`in r)),o=`Z`in r?Up(Wp(r.y,0,1)).getUTCDay():Hp(Wp(r.y,0,1)).getDay(),r.m=0,r.d=`W`in r?(r.w+6)%7+r.W*7-(o+5)%7:r.w+r.U*7-(o+6)%7);return`Z`in r?(r.H+=r.Z/100|0,r.M+=r.Z%100,Up(r)):Hp(r)}}function w(e,t,n,r){for(var i=0,a=t.length,o=n.length,s,c;i<a;){if(r>=o)return-1;if(s=t.charCodeAt(i++),s===37){if(s=t.charAt(i++),c=x[s in Kp?t.charAt(i++):s],!c||(r=c(e,n,r))<0)return-1}else if(s!=n.charCodeAt(r++))return-1}return r}function T(e,t,n){var r=l.exec(t.slice(n));return r?(e.p=u.get(r[0].toLowerCase()),n+r[0].length):-1}function E(e,t,n){var r=p.exec(t.slice(n));return r?(e.w=m.get(r[0].toLowerCase()),n+r[0].length):-1}function D(e,t,n){var r=d.exec(t.slice(n));return r?(e.w=f.get(r[0].toLowerCase()),n+r[0].length):-1}function O(e,t,n){var r=_.exec(t.slice(n));return r?(e.m=v.get(r[0].toLowerCase()),n+r[0].length):-1}function k(e,t,n){var r=h.exec(t.slice(n));return r?(e.m=g.get(r[0].toLowerCase()),n+r[0].length):-1}function A(e,n,r){return w(e,t,n,r)}function j(e,t,r){return w(e,n,t,r)}function M(e,t,n){return w(e,r,t,n)}function N(e){return o[e.getDay()]}function ee(e){return a[e.getDay()]}function te(e){return c[e.getMonth()]}function ne(e){return s[e.getMonth()]}function re(e){return i[+(e.getHours()>=12)]}function ie(e){return 1+~~(e.getMonth()/3)}function ae(e){return o[e.getUTCDay()]}function oe(e){return a[e.getUTCDay()]}function se(e){return c[e.getUTCMonth()]}function ce(e){return s[e.getUTCMonth()]}function le(e){return i[+(e.getUTCHours()>=12)]}function ue(e){return 1+~~(e.getUTCMonth()/3)}return{format:function(e){var t=S(e+=``,y);return t.toString=function(){return e},t},parse:function(e){var t=C(e+=``,!1);return t.toString=function(){return e},t},utcFormat:function(e){var t=S(e+=``,b);return t.toString=function(){return e},t},utcParse:function(e){var t=C(e+=``,!0);return t.toString=function(){return e},t}}}var Kp={"-":``,_:` `,0:`0`},qp=/^\s*\d+/,Jp=/^%/,Yp=/[\\^$*+?|[\]().{}]/g;function W(e,t,n){var r=e<0?`-`:``,i=(r?-e:e)+``,a=i.length;return r+(a<n?Array(n-a+1).join(t)+i:i)}function Xp(e){return e.replace(Yp,`\\$&`)}function Zp(e){return RegExp(`^(?:`+e.map(Xp).join(`|`)+`)`,`i`)}function Qp(e){return new Map(e.map((e,t)=>[e.toLowerCase(),t]))}function $p(e,t,n){var r=qp.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function em(e,t,n){var r=qp.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function tm(e,t,n){var r=qp.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function nm(e,t,n){var r=qp.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function rm(e,t,n){var r=qp.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function im(e,t,n){var r=qp.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function am(e,t,n){var r=qp.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function om(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||`00`)),n+r[0].length):-1}function sm(e,t,n){var r=qp.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function cm(e,t,n){var r=qp.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function lm(e,t,n){var r=qp.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function um(e,t,n){var r=qp.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function dm(e,t,n){var r=qp.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function fm(e,t,n){var r=qp.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function pm(e,t,n){var r=qp.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function mm(e,t,n){var r=qp.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function hm(e,t,n){var r=qp.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function gm(e,t,n){var r=Jp.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function _m(e,t,n){var r=qp.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function vm(e,t,n){var r=qp.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function ym(e,t){return W(e.getDate(),t,2)}function bm(e,t){return W(e.getHours(),t,2)}function xm(e,t){return W(e.getHours()%12||12,t,2)}function Sm(e,t){return W(1+mp.count(Fp(e),e),t,3)}function Cm(e,t){return W(e.getMilliseconds(),t,3)}function wm(e,t){return Cm(e,t)+`000`}function Tm(e,t){return W(e.getMonth()+1,t,2)}function Em(e,t){return W(e.getMinutes(),t,2)}function Dm(e,t){return W(e.getSeconds(),t,2)}function Om(e){var t=e.getDay();return t===0?7:t}function km(e,t){return W(vp.count(Fp(e)-1,e),t,2)}function Am(e){var t=e.getDay();return t>=4||t===0?Sp(e):Sp.ceil(e)}function jm(e,t){return e=Am(e),W(Sp.count(Fp(e),e)+(Fp(e).getDay()===4),t,2)}function Mm(e){return e.getDay()}function Nm(e,t){return W(yp.count(Fp(e)-1,e),t,2)}function Pm(e,t){return W(e.getFullYear()%100,t,2)}function Fm(e,t){return e=Am(e),W(e.getFullYear()%100,t,2)}function Im(e,t){return W(e.getFullYear()%1e4,t,4)}function Lm(e,t){var n=e.getDay();return e=n>=4||n===0?Sp(e):Sp.ceil(e),W(e.getFullYear()%1e4,t,4)}function Rm(e){var t=e.getTimezoneOffset();return(t>0?`-`:(t*=-1,`+`))+W(t/60|0,`0`,2)+W(t%60,`0`,2)}function zm(e,t){return W(e.getUTCDate(),t,2)}function Bm(e,t){return W(e.getUTCHours(),t,2)}function Vm(e,t){return W(e.getUTCHours()%12||12,t,2)}function Hm(e,t){return W(1+hp.count(Ip(e),e),t,3)}function Um(e,t){return W(e.getUTCMilliseconds(),t,3)}function Wm(e,t){return Um(e,t)+`000`}function Gm(e,t){return W(e.getUTCMonth()+1,t,2)}function Km(e,t){return W(e.getUTCMinutes(),t,2)}function qm(e,t){return W(e.getUTCSeconds(),t,2)}function Jm(e){var t=e.getUTCDay();return t===0?7:t}function Ym(e,t){return W(Ep.count(Ip(e)-1,e),t,2)}function Xm(e){var t=e.getUTCDay();return t>=4||t===0?Ap(e):Ap.ceil(e)}function Zm(e,t){return e=Xm(e),W(Ap.count(Ip(e),e)+(Ip(e).getUTCDay()===4),t,2)}function Qm(e){return e.getUTCDay()}function $m(e,t){return W(Dp.count(Ip(e)-1,e),t,2)}function eh(e,t){return W(e.getUTCFullYear()%100,t,2)}function th(e,t){return e=Xm(e),W(e.getUTCFullYear()%100,t,2)}function nh(e,t){return W(e.getUTCFullYear()%1e4,t,4)}function rh(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Ap(e):Ap.ceil(e),W(e.getUTCFullYear()%1e4,t,4)}function ih(){return`+0000`}function ah(){return`%`}function oh(e){return+e}function sh(e){return Math.floor(e/1e3)}var ch,lh,uh;dh({dateTime:`%x, %X`,date:`%-m/%-d/%Y`,time:`%-I:%M:%S %p`,periods:[`AM`,`PM`],days:[`Sunday`,`Monday`,`Tuesday`,`Wednesday`,`Thursday`,`Friday`,`Saturday`],shortDays:[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`],months:[`January`,`February`,`March`,`April`,`May`,`June`,`July`,`August`,`September`,`October`,`November`,`December`],shortMonths:[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`]});function dh(e){return ch=Gp(e),lh=ch.format,ch.parse,uh=ch.utcFormat,ch.utcParse,ch}function fh(e){return new Date(e)}function ph(e){return e instanceof Date?+e:+new Date(+e)}function mh(e,t,n,r,i,a,o,s,c,l){var u=Xd(),d=u.invert,f=u.domain,p=l(`.%L`),m=l(`:%S`),h=l(`%I:%M`),g=l(`%I %p`),_=l(`%a %d`),v=l(`%b %d`),y=l(`%B`),b=l(`%Y`);function x(e){return(c(e)<e?p:s(e)<e?m:o(e)<e?h:a(e)<e?g:r(e)<e?i(e)<e?_:v:n(e)<e?y:b)(e)}return u.invert=function(e){return new Date(d(e))},u.domain=function(e){return arguments.length?f(Array.from(e,ph)):f().map(fh)},u.ticks=function(t){var n=f();return e(n[0],n[n.length-1],t??10)},u.tickFormat=function(e,t){return t==null?x:l(t)},u.nice=function(e){var n=f();return(!e||typeof e.range!=`function`)&&(e=t(n[0],n[n.length-1],e??10)),e?f(Ef(n,e)):u},u.copy=function(){return Jd(u,mh(e,t,n,r,i,a,o,s,c,l))},u}function hh(){return Ou.apply(mh(Bp,Vp,Fp,Np,vp,mp,fp,up,lp,lh).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function gh(){return Ou.apply(mh(Rp,zp,Ip,Pp,Ep,hp,pp,dp,lp,uh).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function _h(){var e=0,t=1,n,r,i,a,o=Ud,s=!1,c;function l(e){return e==null||isNaN(e=+e)?c:o(i===0?.5:(e=(a(e)-n)*i,s?Math.max(0,Math.min(1,e)):e))}l.domain=function(o){return arguments.length?([e,t]=o,n=a(e=+e),r=a(t=+t),i=n===r?0:1/(r-n),l):[e,t]},l.clamp=function(e){return arguments.length?(s=!!e,l):s},l.interpolator=function(e){return arguments.length?(o=e,l):o};function u(e){return function(t){var n,r;return arguments.length?([n,r]=t,o=e(n,r),l):[o(0),o(1)]}}return l.range=u(Ld),l.rangeRound=u(Rd),l.unknown=function(e){return arguments.length?(c=e,l):c},function(o){return a=o,n=o(e),r=o(t),i=n===r?0:1/(r-n),l}}function vh(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function yh(){var e=Cf(_h()(Ud));return e.copy=function(){return vh(e,yh())},ku.apply(e,arguments)}function bh(){var e=Ff(_h()).domain([1,10]);return e.copy=function(){return vh(e,bh()).base(e.base())},ku.apply(e,arguments)}function xh(){var e=zf(_h());return e.copy=function(){return vh(e,xh()).constant(e.constant())},ku.apply(e,arguments)}function Sh(){var e=Wf(_h());return e.copy=function(){return vh(e,Sh()).exponent(e.exponent())},ku.apply(e,arguments)}function Ch(){return Sh.apply(null,arguments).exponent(.5)}function wh(){var e=[],t=Ud;function n(n){if(n!=null&&!isNaN(n=+n))return t((ou(e,n,1)-1)/(e.length-1))}return n.domain=function(t){if(!arguments.length)return e.slice();e=[];for(let n of t)n!=null&&!isNaN(n=+n)&&e.push(n);return e.sort($l),n},n.interpolator=function(e){return arguments.length?(t=e,n):t},n.range=function(){return e.map((n,r)=>t(r/(e.length-1)))},n.quantiles=function(t){return Array.from({length:t+1},(n,r)=>Tu(e,r/t))},n.copy=function(){return wh(t).domain(e)},ku.apply(n,arguments)}function Th(){var e=0,t=.5,n=1,r=1,i,a,o,s,c,l=Ud,u,d=!1,f;function p(e){return isNaN(e=+e)?f:(e=.5+((e=+u(e))-a)*(r*e<r*a?s:c),l(d?Math.max(0,Math.min(1,e)):e))}p.domain=function(l){return arguments.length?([e,t,n]=l,i=u(e=+e),a=u(t=+t),o=u(n=+n),s=i===a?0:.5/(a-i),c=a===o?0:.5/(o-a),r=a<i?-1:1,p):[e,t,n]},p.clamp=function(e){return arguments.length?(d=!!e,p):d},p.interpolator=function(e){return arguments.length?(l=e,p):l};function m(e){return function(t){var n,r,i;return arguments.length?([n,r,i]=t,l=zd(e,[n,r,i]),p):[l(0),l(.5),l(1)]}}return p.range=m(Ld),p.rangeRound=m(Rd),p.unknown=function(e){return arguments.length?(f=e,p):f},function(l){return u=l,i=l(e),a=l(t),o=l(n),s=i===a?0:.5/(a-i),c=a===o?0:.5/(o-a),r=a<i?-1:1,p}}function Eh(){var e=Cf(Th()(Ud));return e.copy=function(){return vh(e,Eh())},ku.apply(e,arguments)}function Dh(){var e=Ff(Th()).domain([.1,1,10]);return e.copy=function(){return vh(e,Dh()).base(e.base())},ku.apply(e,arguments)}function Oh(){var e=zf(Th());return e.copy=function(){return vh(e,Oh()).constant(e.constant())},ku.apply(e,arguments)}function kh(){var e=Wf(Th());return e.copy=function(){return vh(e,kh()).exponent(e.exponent())},ku.apply(e,arguments)}function Ah(){return kh.apply(null,arguments).exponent(.5)}var jh=e({scaleBand:()=>Mu,scaleDiverging:()=>Eh,scaleDivergingLog:()=>Dh,scaleDivergingPow:()=>kh,scaleDivergingSqrt:()=>Ah,scaleDivergingSymlog:()=>Oh,scaleIdentity:()=>Tf,scaleImplicit:()=>Au,scaleLinear:()=>wf,scaleLog:()=>If,scaleOrdinal:()=>ju,scalePoint:()=>Pu,scalePow:()=>Gf,scaleQuantile:()=>Xf,scaleQuantize:()=>Zf,scaleRadial:()=>Yf,scaleSequential:()=>yh,scaleSequentialLog:()=>bh,scaleSequentialPow:()=>Sh,scaleSequentialQuantile:()=>wh,scaleSequentialSqrt:()=>Ch,scaleSequentialSymlog:()=>xh,scaleSqrt:()=>Kf,scaleSymlog:()=>Bf,scaleThreshold:()=>Qf,scaleTime:()=>hh,scaleUtc:()=>gh,tickFormat:()=>Sf}),Mh=t(((e,t)=>{var n=Xe();function r(e,t,r){for(var i=-1,a=e.length;++i<a;){var o=e[i],s=t(o);if(s!=null&&(c===void 0?s===s&&!n(s):r(s,c)))var c=s,l=o}return l}t.exports=r})),Nh=t(((e,t)=>{function n(e,t){return e>t}t.exports=n})),Ph=t(((e,t)=>{var n=Mh(),r=Nh(),i=po();function a(e){return e&&e.length?n(e,i,r):void 0}t.exports=a})),Fh=t(((e,t)=>{function n(e,t){return e<t}t.exports=n})),Ih=t(((e,t)=>{var n=Mh(),r=Fh(),i=po();function a(e){return e&&e.length?n(e,i,r):void 0}t.exports=a})),Lh=t(((e,t)=>{var n=Nt(),r=_o(),i=as(),a=He();function o(e,t){return(a(e)?n:i)(e,r(t,3))}t.exports=o})),Rh=t(((e,t)=>{var n=$o(),r=Lh();function i(e,t){return n(r(e,t),1)}t.exports=i})),zh=t(((e,t)=>{var n=no();function r(e,t){return n(e,t)}t.exports=r})),Bh=t(((e,t)=>{(function(e){var n=1e9,r={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:`2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286`},i=!0,a=`[DecimalError] `,o=a+`Invalid argument: `,s=a+`Exponent out of range: `,c=Math.floor,l=Math.pow,u=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,d,f=1e7,p=7,m=9007199254740991,h=c(m/p),g={};g.absoluteValue=g.abs=function(){var e=new this.constructor(this);return e.s&&=1,e},g.comparedTo=g.cmp=function(e){var t,n,r,i,a=this;if(e=new a.constructor(e),a.s!==e.s)return a.s||-e.s;if(a.e!==e.e)return a.e>e.e^a.s<0?1:-1;for(r=a.d.length,i=e.d.length,t=0,n=r<i?r:i;t<n;++t)if(a.d[t]!==e.d[t])return a.d[t]>e.d[t]^a.s<0?1:-1;return r===i?0:r>i^a.s<0?1:-1},g.decimalPlaces=g.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*p;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n},g.dividedBy=g.div=function(e){return b(this,new this.constructor(e))},g.dividedToIntegerBy=g.idiv=function(e){var t=this,n=t.constructor;return D(b(t,new n(e),0,1),n.precision)},g.equals=g.eq=function(e){return!this.cmp(e)},g.exponent=function(){return S(this)},g.greaterThan=g.gt=function(e){return this.cmp(e)>0},g.greaterThanOrEqualTo=g.gte=function(e){return this.cmp(e)>=0},g.isInteger=g.isint=function(){return this.e>this.d.length-2},g.isNegative=g.isneg=function(){return this.s<0},g.isPositive=g.ispos=function(){return this.s>0},g.isZero=function(){return this.s===0},g.lessThan=g.lt=function(e){return this.cmp(e)<0},g.lessThanOrEqualTo=g.lte=function(e){return this.cmp(e)<1},g.logarithm=g.log=function(e){var t,n=this,r=n.constructor,o=r.precision,s=o+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(d))throw Error(a+`NaN`);if(n.s<1)throw Error(a+(n.s?`NaN`:`-Infinity`));return n.eq(d)?new r(0):(i=!1,t=b(T(n,s),T(e,s),s),i=!0,D(t,o))},g.minus=g.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?O(t,e):_(t,(e.s=-e.s,e))},g.modulo=g.mod=function(e){var t,n=this,r=n.constructor,o=r.precision;if(e=new r(e),!e.s)throw Error(a+`NaN`);return n.s?(i=!1,t=b(n,e,0,1).times(e),i=!0,n.minus(t)):D(new r(n),o)},g.naturalExponential=g.exp=function(){return x(this)},g.naturalLogarithm=g.ln=function(){return T(this)},g.negated=g.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e},g.plus=g.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?_(t,e):O(t,(e.s=-e.s,e))},g.precision=g.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(o+e);if(t=S(i)+1,r=i.d.length-1,n=r*p+1,r=i.d[r],r){for(;r%10==0;r/=10)n--;for(r=i.d[0];r>=10;r/=10)n++}return e&&t>n?t:n},g.squareRoot=g.sqrt=function(){var e,t,n,r,o,s,l,u=this,d=u.constructor;if(u.s<1){if(!u.s)return new d(0);throw Error(a+`NaN`)}for(e=S(u),i=!1,o=Math.sqrt(+u),o==0||o==1/0?(t=y(u.d),(t.length+e)%2==0&&(t+=`0`),o=Math.sqrt(t),e=c((e+1)/2)-(e<0||e%2),o==1/0?t=`5e`+e:(t=o.toExponential(),t=t.slice(0,t.indexOf(`e`)+1)+e),r=new d(t)):r=new d(o.toString()),n=d.precision,o=l=n+3;;)if(s=r,r=s.plus(b(u,s,l+2)).times(.5),y(s.d).slice(0,l)===(t=y(r.d)).slice(0,l)){if(t=t.slice(l-3,l+1),o==l&&t==`4999`){if(D(s,n+1,0),s.times(s).eq(u)){r=s;break}}else if(t!=`9999`)break;l+=4}return i=!0,D(r,n)},g.times=g.mul=function(e){var t,n,r,a,o,s,c,l,u,d=this,p=d.constructor,m=d.d,h=(e=new p(e)).d;if(!d.s||!e.s)return new p(0);for(e.s*=d.s,n=d.e+e.e,l=m.length,u=h.length,l<u&&(o=m,m=h,h=o,s=l,l=u,u=s),o=[],s=l+u,r=s;r--;)o.push(0);for(r=u;--r>=0;){for(t=0,a=l+r;a>r;)c=o[a]+h[r]*m[a-r-1]+t,o[a--]=c%f|0,t=c/f|0;o[a]=(o[a]+t)%f|0}for(;!o[--s];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,i?D(e,p.precision):e},g.toDecimalPlaces=g.todp=function(e,t){var r=this,i=r.constructor;return r=new i(r),e===void 0?r:(v(e,0,n),t===void 0?t=i.rounding:v(t,0,8),D(r,e+S(r)+1,t))},g.toExponential=function(e,t){var r,i=this,a=i.constructor;return e===void 0?r=k(i,!0):(v(e,0,n),t===void 0?t=a.rounding:v(t,0,8),i=D(new a(i),e+1,t),r=k(i,!0,e+1)),r},g.toFixed=function(e,t){var r,i,a=this,o=a.constructor;return e===void 0?k(a):(v(e,0,n),t===void 0?t=o.rounding:v(t,0,8),i=D(new o(a),e+S(a)+1,t),r=k(i.abs(),!1,e+S(i)+1),a.isneg()&&!a.isZero()?`-`+r:r)},g.toInteger=g.toint=function(){var e=this,t=e.constructor;return D(new t(e),S(e)+1,t.rounding)},g.toNumber=function(){return+this},g.toPower=g.pow=function(e){var t,n,r,o,s,l,u=this,f=u.constructor,h=12,g=+(e=new f(e));if(!e.s)return new f(d);if(u=new f(u),!u.s){if(e.s<1)throw Error(a+`Infinity`);return u}if(u.eq(d))return u;if(r=f.precision,e.eq(d))return D(u,r);if(t=e.e,n=e.d.length-1,l=t>=n,s=u.s,!l){if(s<0)throw Error(a+`NaN`)}else if((n=g<0?-g:g)<=m){for(o=new f(d),t=Math.ceil(r/p+4),i=!1;n%2&&(o=o.times(u),A(o.d,t)),n=c(n/2),n!==0;)u=u.times(u),A(u.d,t);return i=!0,e.s<0?new f(d).div(o):D(o,r)}return s=s<0&&e.d[Math.max(t,n)]&1?-1:1,u.s=1,i=!1,o=e.times(T(u,r+h)),i=!0,o=x(o),o.s=s,o},g.toPrecision=function(e,t){var r,i,a=this,o=a.constructor;return e===void 0?(r=S(a),i=k(a,r<=o.toExpNeg||r>=o.toExpPos)):(v(e,1,n),t===void 0?t=o.rounding:v(t,0,8),a=D(new o(a),e,t),r=S(a),i=k(a,e<=r||r<=o.toExpNeg,e)),i},g.toSignificantDigits=g.tosd=function(e,t){var r=this,i=r.constructor;return e===void 0?(e=i.precision,t=i.rounding):(v(e,1,n),t===void 0?t=i.rounding:v(t,0,8)),D(new i(r),e,t)},g.toString=g.valueOf=g.val=g.toJSON=function(){var e=this,t=S(e),n=e.constructor;return k(e,t<=n.toExpNeg||t>=n.toExpPos)};function _(e,t){var n,r,a,o,s,c,l,u,d=e.constructor,m=d.precision;if(!e.s||!t.s)return t.s||(t=new d(e)),i?D(t,m):t;if(l=e.d,u=t.d,s=e.e,a=t.e,l=l.slice(),o=s-a,o){for(o<0?(r=l,o=-o,c=u.length):(r=u,a=s,c=l.length),s=Math.ceil(m/p),c=s>c?s+1:c+1,o>c&&(o=c,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(c=l.length,o=u.length,c-o<0&&(o=c,r=u,u=l,l=r),n=0;o;)n=(l[--o]=l[o]+u[o]+n)/f|0,l[o]%=f;for(n&&(l.unshift(n),++a),c=l.length;l[--c]==0;)l.pop();return t.d=l,t.e=a,i?D(t,m):t}function v(e,t,n){if(e!==~~e||e<t||e>n)throw Error(o+e)}function y(e){var t,n,r,i=e.length-1,a=``,o=e[0];if(i>0){for(a+=o,t=1;t<i;t++)r=e[t]+``,n=p-r.length,n&&(a+=w(n)),a+=r;o=e[t],r=o+``,n=p-r.length,n&&(a+=w(n))}else if(o===0)return`0`;for(;o%10==0;)o/=10;return a+o}var b=(function(){function e(e,t){var n,r=0,i=e.length;for(e=e.slice();i--;)n=e[i]*t+r,e[i]=n%f|0,r=n/f|0;return r&&e.unshift(r),e}function t(e,t,n,r){var i,a;if(n!=r)a=n>r?1:-1;else for(i=a=0;i<n;i++)if(e[i]!=t[i]){a=e[i]>t[i]?1:-1;break}return a}function n(e,t,n){for(var r=0;n--;)e[n]-=r,r=+(e[n]<t[n]),e[n]=r*f+e[n]-t[n];for(;!e[0]&&e.length>1;)e.shift()}return function(r,i,o,s){var c,l,u,d,m,h,g,_,v,y,b,x,C,w,T,E,O,k,A=r.constructor,j=r.s==i.s?1:-1,M=r.d,N=i.d;if(!r.s)return new A(r);if(!i.s)throw Error(a+`Division by zero`);for(l=r.e-i.e,O=N.length,T=M.length,g=new A(j),_=g.d=[],u=0;N[u]==(M[u]||0);)++u;if(N[u]>(M[u]||0)&&--l,x=o==null?o=A.precision:s?o+(S(r)-S(i))+1:o,x<0)return new A(0);if(x=x/p+2|0,u=0,O==1)for(d=0,N=N[0],x++;(u<T||d)&&x--;u++)C=d*f+(M[u]||0),_[u]=C/N|0,d=C%N|0;else{for(d=f/(N[0]+1)|0,d>1&&(N=e(N,d),M=e(M,d),O=N.length,T=M.length),w=O,v=M.slice(0,O),y=v.length;y<O;)v[y++]=0;k=N.slice(),k.unshift(0),E=N[0],N[1]>=f/2&&++E;do d=0,c=t(N,v,O,y),c<0?(b=v[0],O!=y&&(b=b*f+(v[1]||0)),d=b/E|0,d>1?(d>=f&&(d=f-1),m=e(N,d),h=m.length,y=v.length,c=t(m,v,h,y),c==1&&(d--,n(m,O<h?k:N,h))):(d==0&&(c=d=1),m=N.slice()),h=m.length,h<y&&m.unshift(0),n(v,m,y),c==-1&&(y=v.length,c=t(N,v,O,y),c<1&&(d++,n(v,O<y?k:N,y))),y=v.length):c===0&&(d++,v=[0]),_[u++]=d,c&&v[0]?v[y++]=M[w]||0:(v=[M[w]],y=1);while((w++<T||v[0]!==void 0)&&x--)}return _[0]||_.shift(),g.e=l,D(g,s?o+S(g)+1:o)}})();function x(e,t){var n,r,a,o,c,u,f=0,p=0,m=e.constructor,h=m.precision;if(S(e)>16)throw Error(s+S(e));if(!e.s)return new m(d);for(t==null?(i=!1,u=h):u=t,c=new m(.03125);e.abs().gte(.1);)e=e.times(c),p+=5;for(r=Math.log(l(2,p))/Math.LN10*2+5|0,u+=r,n=a=o=new m(d),m.precision=u;;){if(a=D(a.times(e),u),n=n.times(++f),c=o.plus(b(a,n,u)),y(c.d).slice(0,u)===y(o.d).slice(0,u)){for(;p--;)o=D(o.times(o),u);return m.precision=h,t==null?(i=!0,D(o,h)):o}o=c}}function S(e){for(var t=e.e*p,n=e.d[0];n>=10;n/=10)t++;return t}function C(e,t,n){if(t>e.LN10.sd())throw i=!0,n&&(e.precision=n),Error(a+`LN10 precision limit exceeded`);return D(new e(e.LN10),t)}function w(e){for(var t=``;e--;)t+=`0`;return t}function T(e,t){var n,r,o,s,c,l,u,f,p,m=1,h=10,g=e,_=g.d,v=g.constructor,x=v.precision;if(g.s<1)throw Error(a+(g.s?`NaN`:`-Infinity`));if(g.eq(d))return new v(0);if(t==null?(i=!1,f=x):f=t,g.eq(10))return t??(i=!0),C(v,f);if(f+=h,v.precision=f,n=y(_),r=n.charAt(0),s=S(g),Math.abs(s)<0x5543df729c000){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)g=g.times(e),n=y(g.d),r=n.charAt(0),m++;s=S(g),r>1?(g=new v(`0.`+n),s++):g=new v(r+`.`+n.slice(1))}else return u=C(v,f+2,x).times(s+``),g=T(new v(r+`.`+n.slice(1)),f-h).plus(u),v.precision=x,t==null?(i=!0,D(g,x)):g;for(l=c=g=b(g.minus(d),g.plus(d),f),p=D(g.times(g),f),o=3;;){if(c=D(c.times(p),f),u=l.plus(b(c,new v(o),f)),y(u.d).slice(0,f)===y(l.d).slice(0,f))return l=l.times(2),s!==0&&(l=l.plus(C(v,f+2,x).times(s+``))),l=b(l,new v(m),f),v.precision=x,t==null?(i=!0,D(l,x)):l;l=u,o+=2}}function E(e,t){var n,r,a;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;t.charCodeAt(r)===48;)++r;for(a=t.length;t.charCodeAt(a-1)===48;)--a;if(t=t.slice(r,a),t){if(a-=r,n=n-r-1,e.e=c(n/p),e.d=[],r=(n+1)%p,n<0&&(r+=p),r<a){for(r&&e.d.push(+t.slice(0,r)),a-=p;r<a;)e.d.push(+t.slice(r,r+=p));t=t.slice(r),r=p-t.length}else r-=a;for(;r--;)t+=`0`;if(e.d.push(+t),i&&(e.e>h||e.e<-h))throw Error(s+n)}else e.s=0,e.e=0,e.d=[0];return e}function D(e,t,n){var r,a,o,u,d,m,g,_,v=e.d;for(u=1,o=v[0];o>=10;o/=10)u++;if(r=t-u,r<0)r+=p,a=t,g=v[_=0];else{if(_=Math.ceil((r+1)/p),o=v.length,_>=o)return e;for(g=o=v[_],u=1;o>=10;o/=10)u++;r%=p,a=r-p+u}if(n!==void 0&&(o=l(10,u-a-1),d=g/o%10|0,m=t<0||v[_+1]!==void 0||g%o,m=n<4?(d||m)&&(n==0||n==(e.s<0?3:2)):d>5||d==5&&(n==4||m||n==6&&(r>0?a>0?g/l(10,u-a):0:v[_-1])%10&1||n==(e.s<0?8:7))),t<1||!v[0])return m?(o=S(e),v.length=1,t=t-o-1,v[0]=l(10,(p-t%p)%p),e.e=c(-t/p)||0):(v.length=1,v[0]=e.e=e.s=0),e;if(r==0?(v.length=_,o=1,_--):(v.length=_+1,o=l(10,p-r),v[_]=a>0?(g/l(10,u-a)%l(10,a)|0)*o:0),m)for(;;)if(_==0){(v[0]+=o)==f&&(v[0]=1,++e.e);break}else{if(v[_]+=o,v[_]!=f)break;v[_--]=0,o=1}for(r=v.length;v[--r]===0;)v.pop();if(i&&(e.e>h||e.e<-h))throw Error(s+S(e));return e}function O(e,t){var n,r,a,o,s,c,l,u,d,m,h=e.constructor,g=h.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new h(e),i?D(t,g):t;if(l=e.d,m=t.d,r=t.e,u=e.e,l=l.slice(),s=u-r,s){for(d=s<0,d?(n=l,s=-s,c=m.length):(n=m,r=u,c=l.length),a=Math.max(Math.ceil(g/p),c)+2,s>a&&(s=a,n.length=1),n.reverse(),a=s;a--;)n.push(0);n.reverse()}else{for(a=l.length,c=m.length,d=a<c,d&&(c=a),a=0;a<c;a++)if(l[a]!=m[a]){d=l[a]<m[a];break}s=0}for(d&&(n=l,l=m,m=n,t.s=-t.s),c=l.length,a=m.length-c;a>0;--a)l[c++]=0;for(a=m.length;a>s;){if(l[--a]<m[a]){for(o=a;o&&l[--o]===0;)l[o]=f-1;--l[o],l[a]+=f}l[a]-=m[a]}for(;l[--c]===0;)l.pop();for(;l[0]===0;l.shift())--r;return l[0]?(t.d=l,t.e=r,i?D(t,g):t):new h(0)}function k(e,t,n){var r,i=S(e),a=y(e.d),o=a.length;return t?(n&&(r=n-o)>0?a=a.charAt(0)+`.`+a.slice(1)+w(r):o>1&&(a=a.charAt(0)+`.`+a.slice(1)),a=a+(i<0?`e`:`e+`)+i):i<0?(a=`0.`+w(-i-1)+a,n&&(r=n-o)>0&&(a+=w(r))):i>=o?(a+=w(i+1-o),n&&(r=n-i-1)>0&&(a=a+`.`+w(r))):((r=i+1)<o&&(a=a.slice(0,r)+`.`+a.slice(r)),n&&(r=n-o)>0&&(i+1===o&&(a+=`.`),a+=w(r))),e.s<0?`-`+a:a}function A(e,t){if(e.length>t)return e.length=t,!0}function j(e){var t,n,r;function i(e){var t=this;if(!(t instanceof i))return new i(e);if(t.constructor=i,e instanceof i){t.s=e.s,t.e=e.e,t.d=(e=e.d)?e.slice():e;return}if(typeof e==`number`){if(e*0!=0)throw Error(o+e);if(e>0)t.s=1;else if(e<0)e=-e,t.s=-1;else{t.s=0,t.e=0,t.d=[0];return}if(e===~~e&&e<1e7){t.e=0,t.d=[e];return}return E(t,e.toString())}if(typeof e!=`string`)throw Error(o+e);if(e.charCodeAt(0)===45?(e=e.slice(1),t.s=-1):t.s=1,u.test(e))E(t,e);else throw Error(o+e)}if(i.prototype=g,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.clone=j,i.config=i.set=M,e===void 0&&(e={}),e)for(r=[`precision`,`rounding`,`toExpNeg`,`toExpPos`,`LN10`],t=0;t<r.length;)e.hasOwnProperty(n=r[t++])||(e[n]=this[n]);return i.config(e),i}function M(e){if(!e||typeof e!=`object`)throw Error(a+`Object expected`);var t,r,i,s=[`precision`,1,n,`rounding`,0,8,`toExpNeg`,-1/0,0,`toExpPos`,0,1/0];for(t=0;t<s.length;t+=3)if((i=e[r=s[t]])!==void 0){if(c(i)===i&&i>=s[t+1]&&i<=s[t+2])this[r]=i;else throw Error(o+r+`: `+i)}if((i=e[r=`LN10`])!==void 0){if(i==Math.LN10)this[r]=new this(i);else throw Error(o+r+`: `+i)}return this}r=j(r),r.default=r.Decimal=r,d=new r(1),typeof define==`function`&&define.amd?define(function(){return r}):t!==void 0&&t.exports?t.exports=r:(e||=typeof self<`u`&&self&&self.self==self?self:Function(`return this`)(),e.Decimal=r)})(e)}));function Vh(e){return Gh(e)||Wh(e)||Uh(e)||Hh()}function Hh(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
9
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Uh(e,t){if(e){if(typeof e==`string`)return Kh(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Kh(e,t)}}function Wh(e){if(typeof Symbol<`u`&&Symbol.iterator in Object(e))return Array.from(e)}function Gh(e){if(Array.isArray(e))return Kh(e)}function Kh(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var qh=function(e){return e},Jh={"@@functional/placeholder":!0},Yh=function(e){return e===Jh},Xh=function(e){return function t(){return arguments.length===0||arguments.length===1&&Yh(arguments.length<=0?void 0:arguments[0])?t:e.apply(void 0,arguments)}},Zh=function e(t,n){return t===1?n:Xh(function(){var r=[...arguments],i=r.filter(function(e){return e!==Jh}).length;return i>=t?n.apply(void 0,r):e(t-i,Xh(function(){var e=[...arguments],t=r.map(function(t){return Yh(t)?e.shift():t});return n.apply(void 0,Vh(t).concat(e))}))})},Qh=function(e){return Zh(e.length,e)},$h=function(e,t){for(var n=[],r=e;r<t;++r)n[r-e]=r;return n},eg=Qh(function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map(function(e){return t[e]}).map(e)}),tg=function(){var e=[...arguments];if(!e.length)return qh;var t=e.reverse(),n=t[0],r=t.slice(1);return function(){return r.reduce(function(e,t){return t(e)},n.apply(void 0,arguments))}},ng=function(e){return Array.isArray(e)?e.reverse():e.split(``).reverse.join(``)},rg=function(e){var t=null,n=null;return function(){var r=[...arguments];return t&&r.every(function(e,n){return e===t[n]})?n:(t=r,n=e.apply(void 0,r),n)}},G=r(Bh());function ig(e){return e===0?1:Math.floor(new G.default(e).abs().log(10).toNumber())+1}function ag(e,t,n){for(var r=new G.default(e),i=0,a=[];r.lt(t)&&i<1e5;)a.push(r.toNumber()),r=r.add(n),i++;return a}var og={rangeStep:ag,getDigitCount:ig,interpolateNumber:Qh(function(e,t,n){var r=+e;return r+n*(+t-r)}),uninterpolateNumber:Qh(function(e,t,n){var r=t-+e;return r||=1/0,(n-e)/r}),uninterpolateTruncation:Qh(function(e,t,n){var r=t-+e;return r||=1/0,Math.max(0,Math.min(1,(n-e)/r))})};function sg(e){return ug(e)||lg(e)||pg(e)||cg()}function cg(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
10
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function lg(e){if(typeof Symbol<`u`&&Symbol.iterator in Object(e))return Array.from(e)}function ug(e){if(Array.isArray(e))return mg(e)}function dg(e,t){return gg(e)||hg(e,t)||pg(e,t)||fg()}function fg(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
11
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function pg(e,t){if(e){if(typeof e==`string`)return mg(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return mg(e,t)}}function mg(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function hg(e,t){if(!(typeof Symbol>`u`||!(Symbol.iterator in Object(e)))){var n=[],r=!0,i=!1,a=void 0;try{for(var o=e[Symbol.iterator](),s;!(r=(s=o.next()).done)&&(n.push(s.value),!(t&&n.length===t));r=!0);}catch(e){i=!0,a=e}finally{try{!r&&o.return!=null&&o.return()}finally{if(i)throw a}}return n}}function gg(e){if(Array.isArray(e))return e}function _g(e){var t=dg(e,2),n=t[0],r=t[1],i=n,a=r;return n>r&&(i=r,a=n),[i,a]}function vg(e,t,n){if(e.lte(0))return new G.default(0);var r=og.getDigitCount(e.toNumber()),i=new G.default(10).pow(r),a=e.div(i),o=r===1?.1:.05,s=new G.default(Math.ceil(a.div(o).toNumber())).add(n).mul(o).mul(i);return t?s:new G.default(Math.ceil(s))}function yg(e,t,n){var r=1,i=new G.default(e);if(!i.isint()&&n){var a=Math.abs(e);a<1?(r=new G.default(10).pow(og.getDigitCount(e)-1),i=new G.default(Math.floor(i.div(r).toNumber())).mul(r)):a>1&&(i=new G.default(Math.floor(e)))}else e===0?i=new G.default(Math.floor((t-1)/2)):n||(i=new G.default(Math.floor(e)));var o=Math.floor((t-1)/2);return tg(eg(function(e){return i.add(new G.default(e-o).mul(r)).toNumber()}),$h)(0,t)}function bg(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(n-1)))return{step:new G.default(0),tickMin:new G.default(0),tickMax:new G.default(0)};var a=vg(new G.default(t).sub(e).div(n-1),r,i),o;e<=0&&t>=0?o=new G.default(0):(o=new G.default(e).add(t).div(2),o=o.sub(new G.default(o).mod(a)));var s=Math.ceil(o.sub(e).div(a).toNumber()),c=Math.ceil(new G.default(t).sub(o).div(a).toNumber()),l=s+c+1;return l>n?bg(e,t,n,r,i+1):(l<n&&(c=t>0?c+(n-l):c,s=t>0?s:s+(n-l)),{step:a,tickMin:o.sub(new G.default(s).mul(a)),tickMax:o.add(new G.default(c).mul(a))})}function xg(e){var t=dg(e,2),n=t[0],r=t[1],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=Math.max(i,2),s=dg(_g([n,r]),2),c=s[0],l=s[1];if(c===-1/0||l===1/0){var u=l===1/0?[c].concat(sg($h(0,i-1).map(function(){return 1/0}))):[].concat(sg($h(0,i-1).map(function(){return-1/0})),[l]);return n>r?ng(u):u}if(c===l)return yg(c,i,a);var d=bg(c,l,o,a),f=d.step,p=d.tickMin,m=d.tickMax,h=og.rangeStep(p,m.add(new G.default(.1).mul(f)),f);return n>r?ng(h):h}function Sg(e,t){var n=dg(e,2),r=n[0],i=n[1],a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=dg(_g([r,i]),2),s=o[0],c=o[1];if(s===-1/0||c===1/0)return[r,i];if(s===c)return[s];var l=Math.max(t,2),u=vg(new G.default(c).sub(s).div(l-1),a,0),d=[].concat(sg(og.rangeStep(new G.default(s),new G.default(c).sub(new G.default(.99).mul(u)),u)),[c]);return r>i?ng(d):d}var Cg=rg(xg),wg=rg(Sg),Tg=`Invariant failed`;function Eg(e,t){if(!e)throw Error(Tg)}var Dg=[`offset`,`layout`,`width`,`dataKey`,`data`,`dataPointFormatter`,`xAxis`,`yAxis`];function Og(e){"@babel/helpers - typeof";return Og=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Og(e)}function kg(){return kg=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},kg.apply(this,arguments)}function Ag(e,t){return Fg(e)||Pg(e,t)||Mg(e,t)||jg()}function jg(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
12
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Mg(e,t){if(e){if(typeof e==`string`)return Ng(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ng(e,t)}}function Ng(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Pg(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function Fg(e){if(Array.isArray(e))return e}function Ig(e,t){if(e==null)return{};var n=Lg(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Lg(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Rg(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function zg(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,Yg(r.key),r)}}function Bg(e,t,n){return t&&zg(e.prototype,t),n&&zg(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Vg(e,t,n){return t=Gg(t),Hg(e,Wg()?Reflect.construct(t,n||[],Gg(e).constructor):t.apply(e,n))}function Hg(e,t){if(t&&(Og(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return Ug(e)}function Ug(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function Wg(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Wg=function(){return!!e})()}function Gg(e){return Gg=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Gg(e)}function Kg(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&qg(e,t)}function qg(e,t){return qg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},qg(e,t)}function Jg(e,t,n){return t=Yg(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Yg(e){var t=Xg(e,`string`);return Og(t)==`symbol`?t:t+``}function Xg(e,t){if(Og(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Og(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var Zg=function(e){function t(){return Rg(this,t),Vg(this,t,arguments)}return Kg(t,e),Bg(t,[{key:`render`,value:function(){var e=this.props,t=e.offset,n=e.layout,r=e.width,i=e.dataKey,a=e.data,o=e.dataPointFormatter,s=e.xAxis,c=e.yAxis,l=B(Ig(e,Dg),!1);this.props.direction===`x`&&s.type!==`number`&&Eg(!1);var u=a.map(function(e){var a=o(e,i),u=a.x,d=a.y,f=a.value,p=a.errorVal;if(!p)return null;var m=[],h,g;if(Array.isArray(p)){var _=Ag(p,2);h=_[0],g=_[1]}else h=g=p;if(n===`vertical`){var v=s.scale,y=d+t,b=y+r,x=y-r,S=v(f-h),C=v(f+g);m.push({x1:C,y1:b,x2:C,y2:x}),m.push({x1:S,y1:y,x2:C,y2:y}),m.push({x1:S,y1:b,x2:S,y2:x})}else if(n===`horizontal`){var w=c.scale,T=u+t,E=T-r,D=T+r,O=w(f-h),k=w(f+g);m.push({x1:E,y1:k,x2:D,y2:k}),m.push({x1:T,y1:O,x2:T,y2:k}),m.push({x1:E,y1:O,x2:D,y2:O})}return R.createElement(V,kg({className:`recharts-errorBar`,key:`bar-${m.map(function(e){return`${e.x1}-${e.x2}-${e.y1}-${e.y2}`})}`},l),m.map(function(e){return R.createElement(`line`,kg({},e,{key:`line-${e.x1}-${e.x2}-${e.y1}-${e.y2}`}))}))});return R.createElement(V,{className:`recharts-errorBars`},u)}}])}(R.Component);Jg(Zg,`defaultProps`,{stroke:`black`,strokeWidth:1.5,width:5,offset:0,layout:`horizontal`}),Jg(Zg,`displayName`,`ErrorBar`);function Qg(e){"@babel/helpers - typeof";return Qg=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Qg(e)}function $g(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function e_(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?$g(Object(n),!0).forEach(function(t){t_(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$g(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function t_(e,t,n){return t=n_(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function n_(e){var t=r_(e,`string`);return Qg(t)==`symbol`?t:t+``}function r_(e,t){if(Qg(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Qg(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var i_=function(e){var t=e.children,n=e.formattedGraphicalItems,r=e.legendWidth,i=e.legendContent,a=jn(t,Zo);if(!a)return null;var o=Zo.defaultProps,s=o===void 0?{}:e_(e_({},o),a.props),c=a.props&&a.props.payload?a.props&&a.props.payload:i===`children`?(n||[]).reduce(function(e,t){var n=t.item,r=t.props,i=r.sectors||r.data||[];return e.concat(i.map(function(e){return{type:a.props.iconType||n.props.legendType,value:e.name,color:e.fill,payload:e}}))},[]):(n||[]).map(function(e){var t=e.item,n=t.type.defaultProps,r=n===void 0?{}:e_(e_({},n),t.props),i=r.dataKey,a=r.name,o=r.legendType;return{inactive:r.hide,dataKey:i,type:s.iconType||o||`square`,color:C_(t),value:a||i,payload:r}});return e_(e_(e_({},s),Zo.getWithHeight(a,r)),{},{payload:c,item:a})},a_=r(Ph()),o_=r(Ih()),s_=r(Rh()),c_=r(zh());function l_(e){"@babel/helpers - typeof";return l_=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},l_(e)}function u_(e){return m_(e)||p_(e)||f_(e)||d_()}function d_(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
13
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function f_(e,t){if(e){if(typeof e==`string`)return h_(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return h_(e,t)}}function p_(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function m_(e){if(Array.isArray(e))return h_(e)}function h_(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function g_(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function K(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?g_(Object(n),!0).forEach(function(t){__(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g_(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function __(e,t,n){return t=v_(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function v_(e){var t=y_(e,`string`);return l_(t)==`symbol`?t:t+``}function y_(e,t){if(l_(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(l_(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function b_(e,t,n){return(0,F.default)(e)||(0,F.default)(t)?n:L(t)?(0,Jt.default)(e,t,n):(0,z.default)(t)?t(e):n}function x_(e,t,n,r){var i=(0,s_.default)(e,function(e){return b_(e,t)});if(n===`number`){var a=i.filter(function(e){return I(e)||parseFloat(e)});return a.length?[(0,o_.default)(a),(0,a_.default)(a)]:[1/0,-1/0]}return(r?i.filter(function(e){return!(0,F.default)(e)}):i).map(function(e){return L(e)||e instanceof Date?e:``})}var S_=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0,i=-1,a=t?.length??0;if(a<=1)return 0;if(r&&r.axisType===`angleAxis`&&Math.abs(Math.abs(r.range[1]-r.range[0])-360)<=1e-6)for(var o=r.range,s=0;s<a;s++){var c=s>0?n[s-1].coordinate:n[a-1].coordinate,l=n[s].coordinate,u=s>=a-1?n[0].coordinate:n[s+1].coordinate,d=void 0;if(Xt(l-c)!==Xt(u-l)){var f=[];if(Xt(u-l)===Xt(o[1]-o[0])){d=u;var p=l+o[1]-o[0];f[0]=Math.min(p,(p+c)/2),f[1]=Math.max(p,(p+c)/2)}else{d=c;var m=u+o[1]-o[0];f[0]=Math.min(l,(m+l)/2),f[1]=Math.max(l,(m+l)/2)}var h=[Math.min(l,(d+l)/2),Math.max(l,(d+l)/2)];if(e>h[0]&&e<=h[1]||e>=f[0]&&e<=f[1]){i=n[s].index;break}}else{var g=Math.min(c,u),_=Math.max(c,u);if(e>(g+l)/2&&e<=(_+l)/2){i=n[s].index;break}}}else for(var v=0;v<a;v++)if(v===0&&e<=(t[v].coordinate+t[v+1].coordinate)/2||v>0&&v<a-1&&e>(t[v].coordinate+t[v-1].coordinate)/2&&e<=(t[v].coordinate+t[v+1].coordinate)/2||v===a-1&&e>(t[v].coordinate+t[v-1].coordinate)/2){i=t[v].index;break}return i},C_=function(e){var t,n=e.type.displayName,r=(t=e.type)!=null&&t.defaultProps?K(K({},e.type.defaultProps),e.props):e.props,i=r.stroke,a=r.fill,o;switch(n){case`Line`:o=i;break;case`Area`:case`Radar`:o=i&&i!==`none`?i:a;break;default:o=a}return o},w_=function(e){var t=e.barSize,n=e.totalSize,r=e.stackGroups,i=r===void 0?{}:r;if(!i)return{};for(var a={},o=Object.keys(i),s=0,c=o.length;s<c;s++)for(var l=i[o[s]].stackGroups,u=Object.keys(l),d=0,f=u.length;d<f;d++){var p=l[u[d]],m=p.items,h=p.cateAxisId,g=m.filter(function(e){return En(e.type).indexOf(`Bar`)>=0});if(g&&g.length){var _=g[0].type.defaultProps,v=_===void 0?g[0].props:K(K({},_),g[0].props),y=v.barSize,b=v[h];a[b]||(a[b]=[]);var x=(0,F.default)(y)?t:y;a[b].push({item:g[0],stackList:g.slice(1),barSize:(0,F.default)(x)?void 0:tn(x,n,0)})}}return a},T_=function(e){var t=e.barGap,n=e.barCategoryGap,r=e.bandSize,i=e.sizeList,a=i===void 0?[]:i,o=e.maxBarSize,s=a.length;if(s<1)return null;var c=tn(t,r,0,!0),l,u=[];if(a[0].barSize===+a[0].barSize){var d=!1,f=r/s,p=a.reduce(function(e,t){return e+t.barSize||0},0);p+=(s-1)*c,p>=r&&(p-=(s-1)*c,c=0),p>=r&&f>0&&(d=!0,f*=.9,p=s*f);var m={offset:((r-p)/2>>0)-c,size:0};l=a.reduce(function(e,t){var n={item:t.item,position:{offset:m.offset+m.size+c,size:d?f:t.barSize}},r=[].concat(u_(e),[n]);return m=r[r.length-1].position,t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:m})}),r},u)}else{var h=tn(n,r,0,!0);r-2*h-(s-1)*c<=0&&(c=0);var g=(r-2*h-(s-1)*c)/s;g>1&&(g>>=0);var _=o===+o?Math.min(g,o):g;l=a.reduce(function(e,t,n){var r=[].concat(u_(e),[{item:t.item,position:{offset:h+(g+c)*n+(g-_)/2,size:_}}]);return t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:r[r.length-1].position})}),r},u)}return l},E_=function(e,t,n,r){var i=n.children,a=n.width,o=n.margin,s=i_({children:i,legendWidth:a-(o.left||0)-(o.right||0)});if(s){var c=r||{},l=c.width,u=c.height,d=s.align,f=s.verticalAlign,p=s.layout;if((p===`vertical`||p===`horizontal`&&f===`middle`)&&d!==`center`&&I(e[d]))return K(K({},e),{},__({},d,e[d]+(l||0)));if((p===`horizontal`||p===`vertical`&&d===`center`)&&f!==`middle`&&I(e[f]))return K(K({},e),{},__({},f,e[f]+(u||0)))}return e},D_=function(e,t,n){return(0,F.default)(t)?!0:e===`horizontal`?t===`yAxis`:e===`vertical`||n===`x`?t===`xAxis`:n!==`y`||t===`yAxis`},O_=function(e,t,n,r,i){var a=t.props.children,o=An(a,Zg).filter(function(e){return D_(r,i,e.props.direction)});if(o&&o.length){var s=o.map(function(e){return e.props.dataKey});return e.reduce(function(e,t){var r=b_(t,n);if((0,F.default)(r))return e;var i=Array.isArray(r)?[(0,o_.default)(r),(0,a_.default)(r)]:[r,r],a=s.reduce(function(e,n){var r=b_(t,n,0),a=i[0]-Math.abs(Array.isArray(r)?r[0]:r),o=i[1]+Math.abs(Array.isArray(r)?r[1]:r);return[Math.min(a,e[0]),Math.max(o,e[1])]},[1/0,-1/0]);return[Math.min(a[0],e[0]),Math.max(a[1],e[1])]},[1/0,-1/0])}return null},k_=function(e,t,n,r,i){var a=t.map(function(t){return O_(e,t,n,i,r)}).filter(function(e){return!(0,F.default)(e)});return a&&a.length?a.reduce(function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]},[1/0,-1/0]):null},A_=function(e,t,n,r,i){var a=t.map(function(t){var a=t.props.dataKey;return n===`number`&&a&&O_(e,t,a,r)||x_(e,a,n,i)});if(n===`number`)return a.reduce(function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]},[1/0,-1/0]);var o={};return a.reduce(function(e,t){for(var n=0,r=t.length;n<r;n++)o[t[n]]||(o[t[n]]=!0,e.push(t[n]));return e},[])},j_=function(e,t){return e===`horizontal`&&t===`xAxis`||e===`vertical`&&t===`yAxis`||e===`centric`&&t===`angleAxis`||e===`radial`&&t===`radiusAxis`},M_=function(e,t,n,r){if(r)return e.map(function(e){return e.coordinate});var i,a,o=e.map(function(e){return e.coordinate===t&&(i=!0),e.coordinate===n&&(a=!0),e.coordinate});return i||o.push(t),a||o.push(n),o},N_=function(e,t,n){if(!e)return null;var r=e.scale,i=e.duplicateDomain,a=e.type,o=e.range,s=e.realScaleType===`scaleBand`?r.bandwidth()/2:2,c=(t||n)&&a===`category`&&r.bandwidth?r.bandwidth()/s:0;return c=e.axisType===`angleAxis`&&o?.length>=2?Xt(o[0]-o[1])*2*c:c,t&&(e.ticks||e.niceTicks)?(e.ticks||e.niceTicks).map(function(e){return{coordinate:r(i?i.indexOf(e):e)+c,value:e,offset:c}}).filter(function(e){return!(0,qt.default)(e.coordinate)}):e.isCategorical&&e.categoricalDomain?e.categoricalDomain.map(function(e,t){return{coordinate:r(e)+c,value:e,index:t,offset:c}}):r.ticks&&!n?r.ticks(e.tickCount).map(function(e){return{coordinate:r(e)+c,value:e,offset:c}}):r.domain().map(function(e,t){return{coordinate:r(e)+c,value:i?i[e]:e,index:t,offset:c}})},P_=new WeakMap,F_=function(e,t){if(typeof t!=`function`)return e;P_.has(e)||P_.set(e,new WeakMap);var n=P_.get(e);if(n.has(t))return n.get(t);var r=function(){e.apply(void 0,arguments),t.apply(void 0,arguments)};return n.set(t,r),r},I_=function(e,t,n){var r=e.scale,i=e.type,a=e.layout,o=e.axisType;if(r===`auto`)return a===`radial`&&o===`radiusAxis`?{scale:Mu(),realScaleType:`band`}:a===`radial`&&o===`angleAxis`?{scale:wf(),realScaleType:`linear`}:i===`category`&&t&&(t.indexOf(`LineChart`)>=0||t.indexOf(`AreaChart`)>=0||t.indexOf(`ComposedChart`)>=0&&!n)?{scale:Pu(),realScaleType:`point`}:i===`category`?{scale:Mu(),realScaleType:`band`}:{scale:wf(),realScaleType:`linear`};if((0,Kt.default)(r)){var s=`scale${(0,Di.default)(r)}`;return{scale:(jh[s]||Pu)(),realScaleType:jh[s]?s:`point`}}return(0,z.default)(r)?{scale:r}:{scale:Pu(),realScaleType:`point`}},L_=1e-4,R_=function(e){var t=e.domain();if(!(!t||t.length<=2)){var n=t.length,r=e.range(),i=Math.min(r[0],r[1])-L_,a=Math.max(r[0],r[1])+L_,o=e(t[0]),s=e(t[n-1]);(o<i||o>a||s<i||s>a)&&e.domain([t[0],t[n-1]])}},z_=function(e,t){if(!e)return null;for(var n=0,r=e.length;n<r;n++)if(e[n].item===t)return e[n].position;return null},B_=function(e,t){if(!t||t.length!==2||!I(t[0])||!I(t[1]))return e;var n=Math.min(t[0],t[1]),r=Math.max(t[0],t[1]),i=[e[0],e[1]];return(!I(e[0])||e[0]<n)&&(i[0]=n),(!I(e[1])||e[1]>r)&&(i[1]=r),i[0]>r&&(i[0]=r),i[1]<n&&(i[1]=n),i},V_={sign:function(e){var t=e.length;if(!(t<=0))for(var n=0,r=e[0].length;n<r;++n)for(var i=0,a=0,o=0;o<t;++o){var s=(0,qt.default)(e[o][n][1])?e[o][n][0]:e[o][n][1];s>=0?(e[o][n][0]=i,e[o][n][1]=i+s,i=e[o][n][1]):(e[o][n][0]=a,e[o][n][1]=a+s,a=e[o][n][1])}},expand:wi,none:yi,silhouette:Ti,wiggle:Ei,positive:function(e){var t=e.length;if(!(t<=0))for(var n=0,r=e[0].length;n<r;++n)for(var i=0,a=0;a<t;++a){var o=(0,qt.default)(e[a][n][1])?e[a][n][0]:e[a][n][1];o>=0?(e[a][n][0]=i,e[a][n][1]=i+o,i=e[a][n][1]):(e[a][n][0]=0,e[a][n][1]=0)}}},H_=function(e,t,n){var r=t.map(function(e){return e.props.dataKey}),i=V_[n];return Ci().keys(r).value(function(e,t){return+b_(e,t,0)}).order(bi).offset(i)(e)},U_=function(e,t,n,r,i,a){if(!e)return null;var o=(a?t.reverse():t).reduce(function(e,t){var i,a=(i=t.type)!=null&&i.defaultProps?K(K({},t.type.defaultProps),t.props):t.props,o=a.stackId;if(a.hide)return e;var s=a[n],c=e[s]||{hasStack:!1,stackGroups:{}};if(L(o)){var l=c.stackGroups[o]||{numericAxisId:n,cateAxisId:r,items:[]};l.items.push(t),c.hasStack=!0,c.stackGroups[o]=l}else c.stackGroups[en(`_stackId_`)]={numericAxisId:n,cateAxisId:r,items:[t]};return K(K({},e),{},__({},s,c))},{});return Object.keys(o).reduce(function(t,a){var s=o[a];return s.hasStack&&(s.stackGroups=Object.keys(s.stackGroups).reduce(function(t,a){var o=s.stackGroups[a];return K(K({},t),{},__({},a,{numericAxisId:n,cateAxisId:r,items:o.items,stackedData:H_(e,o.items,i)}))},{})),K(K({},t),{},__({},a,s))},{})},W_=function(e,t){var n=t.realScaleType,r=t.type,i=t.tickCount,a=t.originalDomain,o=t.allowDecimals,s=n||t.scale;if(s!==`auto`&&s!==`linear`)return null;if(i&&r===`number`&&a&&(a[0]===`auto`||a[1]===`auto`)){var c=e.domain();if(!c.length)return null;var l=Cg(c,i,o);return e.domain([(0,o_.default)(l),(0,a_.default)(l)]),{niceTicks:l}}return i&&r===`number`?{niceTicks:wg(e.domain(),i,o)}:null};function G_(e){var t=e.axis,n=e.ticks,r=e.bandSize,i=e.entry,a=e.index,o=e.dataKey;if(t.type===`category`){if(!t.allowDuplicatedCategory&&t.dataKey&&!(0,F.default)(i[t.dataKey])){var s=on(n,`value`,i[t.dataKey]);if(s)return s.coordinate+r/2}return n[a]?n[a].coordinate+r/2:null}var c=b_(i,(0,F.default)(o)?t.dataKey:o);return(0,F.default)(c)?null:t.scale(c)}var K_=function(e){var t=e.axis,n=e.ticks,r=e.offset,i=e.bandSize,a=e.entry,o=e.index;if(t.type===`category`)return n[o]?n[o].coordinate+r:null;var s=b_(a,t.dataKey,t.domain[o]);return(0,F.default)(s)?null:t.scale(s)-i/2+r},q_=function(e){var t=e.numericAxis,n=t.scale.domain();if(t.type===`number`){var r=Math.min(n[0],n[1]),i=Math.max(n[0],n[1]);return r<=0&&i>=0?0:i<0?i:r}return n[0]},J_=function(e,t){var n,r=((n=e.type)!=null&&n.defaultProps?K(K({},e.type.defaultProps),e.props):e.props).stackId;if(L(r)){var i=t[r];if(i){var a=i.items.indexOf(e);return a>=0?i.stackedData[a]:null}}return null},Y_=function(e){return e.reduce(function(e,t){return[(0,o_.default)(t.concat([e[0]]).filter(I)),(0,a_.default)(t.concat([e[1]]).filter(I))]},[1/0,-1/0])},X_=function(e,t,n){return Object.keys(e).reduce(function(r,i){var a=e[i].stackedData.reduce(function(e,r){var i=Y_(r.slice(t,n+1));return[Math.min(e[0],i[0]),Math.max(e[1],i[1])]},[1/0,-1/0]);return[Math.min(a[0],r[0]),Math.max(a[1],r[1])]},[1/0,-1/0]).map(function(e){return e===1/0||e===-1/0?0:e})},Z_=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Q_=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,$_=function(e,t,n){if((0,z.default)(e))return e(t,n);if(!Array.isArray(e))return t;var r=[];if(I(e[0]))r[0]=n?e[0]:Math.min(e[0],t[0]);else if(Z_.test(e[0])){var i=+Z_.exec(e[0])[1];r[0]=t[0]-i}else r[0]=(0,z.default)(e[0])?e[0](t[0]):t[0];if(I(e[1]))r[1]=n?e[1]:Math.max(e[1],t[1]);else if(Q_.test(e[1])){var a=+Q_.exec(e[1])[1];r[1]=t[1]+a}else r[1]=(0,z.default)(e[1])?e[1](t[1]):t[1];return r},ev=function(e,t,n){if(e&&e.scale&&e.scale.bandwidth){var r=e.scale.bandwidth();if(!n||r>0)return r}if(e&&t&&t.length>=2){for(var i=(0,ys.default)(t,function(e){return e.coordinate}),a=1/0,o=1,s=i.length;o<s;o++){var c=i[o],l=i[o-1];a=Math.min((c.coordinate||0)-(l.coordinate||0),a)}return a===1/0?0:a}return n?void 0:0},tv=function(e,t,n){return!e||!e.length||(0,c_.default)(e,(0,Jt.default)(n,`type.defaultProps.domain`))?t:e},nv=function(e,t){var n=e.type.defaultProps?K(K({},e.type.defaultProps),e.props):e.props,r=n.dataKey,i=n.name,a=n.unit,o=n.formatter,s=n.tooltipType,c=n.chartType,l=n.hide;return K(K({},B(e,!1)),{},{dataKey:r,unit:a,formatter:o,name:i||r,color:C_(e),value:b_(t,r),type:s,payload:t,chartType:c,hide:l})};function rv(e){"@babel/helpers - typeof";return rv=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},rv(e)}function iv(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 av(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?iv(Object(n),!0).forEach(function(t){ov(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):iv(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ov(e,t,n){return t=sv(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function sv(e){var t=cv(e,`string`);return rv(t)==`symbol`?t:t+``}function cv(e,t){if(rv(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(rv(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var lv=Math.PI/180,uv=function(e){return e*180/Math.PI},dv=function(e,t,n,r){return{x:e+Math.cos(-lv*r)*n,y:t+Math.sin(-lv*r)*n}},fv=function(e,t){var n=e.x,r=e.y,i=t.x,a=t.y;return Math.sqrt((n-i)**2+(r-a)**2)},pv=function(e,t){var n=e.x,r=e.y,i=t.cx,a=t.cy,o=fv({x:n,y:r},{x:i,y:a});if(o<=0)return{radius:o};var s=(n-i)/o,c=Math.acos(s);return r>a&&(c=2*Math.PI-c),{radius:o,angle:uv(c),angleInRadian:c}},mv=function(e){var t=e.startAngle,n=e.endAngle,r=Math.floor(t/360),i=Math.floor(n/360),a=Math.min(r,i);return{startAngle:t-a*360,endAngle:n-a*360}},hv=function(e,t){var n=t.startAngle,r=t.endAngle,i=Math.floor(n/360),a=Math.floor(r/360);return e+Math.min(i,a)*360},gv=function(e,t){var n=e.x,r=e.y,i=pv({x:n,y:r},t),a=i.radius,o=i.angle,s=t.innerRadius,c=t.outerRadius;if(a<s||a>c)return!1;if(a===0)return!0;var l=mv(t),u=l.startAngle,d=l.endAngle,f=o,p;if(u<=d){for(;f>d;)f-=360;for(;f<u;)f+=360;p=f>=u&&f<=d}else{for(;f>u;)f-=360;for(;f<d;)f+=360;p=f>=d&&f<=u}return p?av(av({},t),{},{radius:a,angle:hv(f,t)}):null};function _v(e){"@babel/helpers - typeof";return _v=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},_v(e)}var vv=[`offset`];function yv(e){return Cv(e)||Sv(e)||xv(e)||bv()}function bv(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
14
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xv(e,t){if(e){if(typeof e==`string`)return wv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return wv(e,t)}}function Sv(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function Cv(e){if(Array.isArray(e))return wv(e)}function wv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Tv(e,t){if(e==null)return{};var n=Ev(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Ev(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Dv(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 q(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Dv(Object(n),!0).forEach(function(t){Ov(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Dv(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Ov(e,t,n){return t=kv(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kv(e){var t=Av(e,`string`);return _v(t)==`symbol`?t:t+``}function Av(e,t){if(_v(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(_v(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function jv(){return jv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jv.apply(this,arguments)}var Mv=function(e){var t=e.value,n=e.formatter,r=(0,F.default)(e.children)?t:e.children;return(0,z.default)(n)?n(r):r},Nv=function(e,t){return Xt(t-e)*Math.min(Math.abs(t-e),360)},Pv=function(e,t,n){var r=e.position,i=e.viewBox,a=e.offset,o=e.className,s=i,c=s.cx,l=s.cy,u=s.innerRadius,d=s.outerRadius,f=s.startAngle,p=s.endAngle,m=s.clockWise,h=(u+d)/2,g=Nv(f,p),_=g>=0?1:-1,y,b;r===`insideStart`?(y=f+_*a,b=m):r===`insideEnd`?(y=p-_*a,b=!m):r===`end`&&(y=p+_*a,b=m),b=g<=0?b:!b;var x=dv(c,l,h,y),S=dv(c,l,h,y+(b?1:-1)*359),C=`M${x.x},${x.y}
|
|
15
|
+
A${h},${h},0,1,${+!b},
|
|
16
|
+
${S.x},${S.y}`,w=(0,F.default)(e.id)?en(`recharts-radial-line-`):e.id;return R.createElement(`text`,jv({},n,{dominantBaseline:`central`,className:v(`recharts-radial-bar-label`,o)}),R.createElement(`defs`,null,R.createElement(`path`,{id:w,d:C})),R.createElement(`textPath`,{xlinkHref:`#${w}`},t))},Fv=function(e){var t=e.viewBox,n=e.offset,r=e.position,i=t,a=i.cx,o=i.cy,s=i.innerRadius,c=i.outerRadius,l=(i.startAngle+i.endAngle)/2;if(r===`outside`){var u=dv(a,o,c+n,l),d=u.x;return{x:d,y:u.y,textAnchor:d>=a?`start`:`end`,verticalAnchor:`middle`}}if(r===`center`)return{x:a,y:o,textAnchor:`middle`,verticalAnchor:`middle`};if(r===`centerTop`)return{x:a,y:o,textAnchor:`middle`,verticalAnchor:`start`};if(r===`centerBottom`)return{x:a,y:o,textAnchor:`middle`,verticalAnchor:`end`};var f=dv(a,o,(s+c)/2,l);return{x:f.x,y:f.y,textAnchor:`middle`,verticalAnchor:`middle`}},Iv=function(e){var t=e.viewBox,n=e.parentViewBox,r=e.offset,i=e.position,a=t,o=a.x,s=a.y,c=a.width,l=a.height,u=l>=0?1:-1,d=u*r,f=u>0?`end`:`start`,p=u>0?`start`:`end`,m=c>=0?1:-1,h=m*r,g=m>0?`end`:`start`,_=m>0?`start`:`end`;if(i===`top`)return q(q({},{x:o+c/2,y:s-u*r,textAnchor:`middle`,verticalAnchor:f}),n?{height:Math.max(s-n.y,0),width:c}:{});if(i===`bottom`)return q(q({},{x:o+c/2,y:s+l+d,textAnchor:`middle`,verticalAnchor:p}),n?{height:Math.max(n.y+n.height-(s+l),0),width:c}:{});if(i===`left`){var v={x:o-h,y:s+l/2,textAnchor:g,verticalAnchor:`middle`};return q(q({},v),n?{width:Math.max(v.x-n.x,0),height:l}:{})}if(i===`right`){var y={x:o+c+h,y:s+l/2,textAnchor:_,verticalAnchor:`middle`};return q(q({},y),n?{width:Math.max(n.x+n.width-y.x,0),height:l}:{})}var b=n?{width:c,height:l}:{};return i===`insideLeft`?q({x:o+h,y:s+l/2,textAnchor:_,verticalAnchor:`middle`},b):i===`insideRight`?q({x:o+c-h,y:s+l/2,textAnchor:g,verticalAnchor:`middle`},b):i===`insideTop`?q({x:o+c/2,y:s+d,textAnchor:`middle`,verticalAnchor:p},b):i===`insideBottom`?q({x:o+c/2,y:s+l-d,textAnchor:`middle`,verticalAnchor:f},b):i===`insideTopLeft`?q({x:o+h,y:s+d,textAnchor:_,verticalAnchor:p},b):i===`insideTopRight`?q({x:o+c-h,y:s+d,textAnchor:g,verticalAnchor:p},b):i===`insideBottomLeft`?q({x:o+h,y:s+l-d,textAnchor:_,verticalAnchor:f},b):i===`insideBottomRight`?q({x:o+c-h,y:s+l-d,textAnchor:g,verticalAnchor:f},b):(0,ln.default)(i)&&(I(i.x)||Zt(i.x))&&(I(i.y)||Zt(i.y))?q({x:o+tn(i.x,c),y:s+tn(i.y,l),textAnchor:`end`,verticalAnchor:`end`},b):q({x:o+c/2,y:s+l/2,textAnchor:`middle`,verticalAnchor:`middle`},b)},Lv=function(e){return`cx`in e&&I(e.cx)};function Rv(e){var t=e.offset,n=t===void 0?5:t,r=Tv(e,vv),i=q({offset:n},r),a=i.viewBox,o=i.position,s=i.value,c=i.children,l=i.content,u=i.className,d=u===void 0?``:u,f=i.textBreakAll;if(!a||(0,F.default)(s)&&(0,F.default)(c)&&!(0,R.isValidElement)(l)&&!(0,z.default)(l))return null;if((0,R.isValidElement)(l))return(0,R.cloneElement)(l,i);var p;if((0,z.default)(l)){if(p=(0,R.createElement)(l,i),(0,R.isValidElement)(p))return p}else p=Mv(i);var m=Lv(a),h=B(i,!0);if(m&&(o===`insideStart`||o===`insideEnd`||o===`end`))return Pv(i,p,h);var g=m?Fv(i):Iv(i);return R.createElement(Ql,jv({className:v(`recharts-label`,d)},h,g,{breakAll:f}),p)}Rv.displayName=`Label`;var zv=function(e){var t=e.cx,n=e.cy,r=e.angle,i=e.startAngle,a=e.endAngle,o=e.r,s=e.radius,c=e.innerRadius,l=e.outerRadius,u=e.x,d=e.y,f=e.top,p=e.left,m=e.width,h=e.height,g=e.clockWise,_=e.labelViewBox;if(_)return _;if(I(m)&&I(h)){if(I(u)&&I(d))return{x:u,y:d,width:m,height:h};if(I(f)&&I(p))return{x:f,y:p,width:m,height:h}}return I(u)&&I(d)?{x:u,y:d,width:0,height:0}:I(t)&&I(n)?{cx:t,cy:n,startAngle:i||r||0,endAngle:a||r||0,innerRadius:c||0,outerRadius:l||s||o||0,clockWise:g}:e.viewBox?e.viewBox:{}},Bv=function(e,t){return e?e===!0?R.createElement(Rv,{key:`label-implicit`,viewBox:t}):L(e)?R.createElement(Rv,{key:`label-implicit`,viewBox:t,value:e}):(0,R.isValidElement)(e)?e.type===Rv?(0,R.cloneElement)(e,{key:`label-implicit`,viewBox:t}):R.createElement(Rv,{key:`label-implicit`,content:e,viewBox:t}):(0,z.default)(e)?R.createElement(Rv,{key:`label-implicit`,content:e,viewBox:t}):(0,ln.default)(e)?R.createElement(Rv,jv({viewBox:t},e,{key:`label-implicit`})):null:null};Rv.parseViewBox=zv,Rv.renderCallByParent=function(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!e||!e.children&&n&&!e.label)return null;var r=e.children,i=zv(e),a=An(r,Rv).map(function(e,n){return(0,R.cloneElement)(e,{viewBox:t||i,key:`label-${n}`})});return n?[Bv(e.label,t||i)].concat(yv(a)):a};var Vv=r(t(((e,t)=>{function n(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}t.exports=n}))());function Hv(e){"@babel/helpers - typeof";return Hv=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Hv(e)}var Uv=[`valueAccessor`],Wv=[`data`,`dataKey`,`clockWise`,`id`,`textBreakAll`];function Gv(e){return Yv(e)||Jv(e)||qv(e)||Kv()}function Kv(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
17
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qv(e,t){if(e){if(typeof e==`string`)return Xv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Xv(e,t)}}function Jv(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function Yv(e){if(Array.isArray(e))return Xv(e)}function Xv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Zv(){return Zv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Zv.apply(this,arguments)}function Qv(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 $v(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Qv(Object(n),!0).forEach(function(t){ey(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Qv(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ey(e,t,n){return t=ty(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ty(e){var t=ny(e,`string`);return Hv(t)==`symbol`?t:t+``}function ny(e,t){if(Hv(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Hv(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function ry(e,t){if(e==null)return{};var n=iy(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function iy(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var ay=function(e){return Array.isArray(e.value)?(0,Vv.default)(e.value):e.value};function oy(e){var t=e.valueAccessor,n=t===void 0?ay:t,r=ry(e,Uv),i=r.data,a=r.dataKey,o=r.clockWise,s=r.id,c=r.textBreakAll,l=ry(r,Wv);return!i||!i.length?null:R.createElement(V,{className:`recharts-label-list`},i.map(function(e,t){var r=(0,F.default)(a)?n(e,t):b_(e&&e.payload,a),i=(0,F.default)(s)?{}:{id:`${s}-${t}`};return R.createElement(Rv,Zv({},B(e,!0),l,i,{parentViewBox:e.parentViewBox,value:r,textBreakAll:c,viewBox:Rv.parseViewBox((0,F.default)(o)?e:$v($v({},e),{},{clockWise:o})),key:`label-${t}`,index:t}))}))}oy.displayName=`LabelList`;function sy(e,t){return e?e===!0?R.createElement(oy,{key:`labelList-implicit`,data:t}):R.isValidElement(e)||(0,z.default)(e)?R.createElement(oy,{key:`labelList-implicit`,data:t,content:e}):(0,ln.default)(e)?R.createElement(oy,Zv({data:t},e,{key:`labelList-implicit`})):null:null}function cy(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!e||!e.children&&n&&!e.label)return null;var r=e.children,i=An(r,oy).map(function(e,n){return(0,R.cloneElement)(e,{data:t,key:`labelList-${n}`})});return n?[sy(e.label,t)].concat(Gv(i)):i}oy.renderCallByParent=cy;function ly(e){"@babel/helpers - typeof";return ly=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},ly(e)}function uy(){return uy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},uy.apply(this,arguments)}function dy(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 fy(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?dy(Object(n),!0).forEach(function(t){py(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dy(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function py(e,t,n){return t=my(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function my(e){var t=hy(e,`string`);return ly(t)==`symbol`?t:t+``}function hy(e,t){if(ly(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(ly(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var gy=function(e,t){return Xt(t-e)*Math.min(Math.abs(t-e),359.999)},_y=function(e){var t=e.cx,n=e.cy,r=e.radius,i=e.angle,a=e.sign,o=e.isExternal,s=e.cornerRadius,c=e.cornerIsExternal,l=s*(o?1:-1)+r,u=Math.asin(s/l)/lv,d=c?i:i+a*u,f=dv(t,n,l,d),p=dv(t,n,r,d),m=c?i-a*u:i;return{center:f,circleTangency:p,lineTangency:dv(t,n,l*Math.cos(u*lv),m),theta:u}},vy=function(e){var t=e.cx,n=e.cy,r=e.innerRadius,i=e.outerRadius,a=e.startAngle,o=e.endAngle,s=gy(a,o),c=a+s,l=dv(t,n,i,a),u=dv(t,n,i,c),d=`M ${l.x},${l.y}
|
|
18
|
+
A ${i},${i},0,
|
|
19
|
+
${+(Math.abs(s)>180)},${+(a>c)},
|
|
20
|
+
${u.x},${u.y}
|
|
21
|
+
`;if(r>0){var f=dv(t,n,r,a),p=dv(t,n,r,c);d+=`L ${p.x},${p.y}
|
|
22
|
+
A ${r},${r},0,
|
|
23
|
+
${+(Math.abs(s)>180)},${+(a<=c)},
|
|
24
|
+
${f.x},${f.y} Z`}else d+=`L ${t},${n} Z`;return d},yy=function(e){var t=e.cx,n=e.cy,r=e.innerRadius,i=e.outerRadius,a=e.cornerRadius,o=e.forceCornerRadius,s=e.cornerIsExternal,c=e.startAngle,l=e.endAngle,u=Xt(l-c),d=_y({cx:t,cy:n,radius:i,angle:c,sign:u,cornerRadius:a,cornerIsExternal:s}),f=d.circleTangency,p=d.lineTangency,m=d.theta,h=_y({cx:t,cy:n,radius:i,angle:l,sign:-u,cornerRadius:a,cornerIsExternal:s}),g=h.circleTangency,_=h.lineTangency,v=h.theta,y=s?Math.abs(c-l):Math.abs(c-l)-m-v;if(y<0)return o?`M ${p.x},${p.y}
|
|
25
|
+
a${a},${a},0,0,1,${a*2},0
|
|
26
|
+
a${a},${a},0,0,1,${-a*2},0
|
|
27
|
+
`:vy({cx:t,cy:n,innerRadius:r,outerRadius:i,startAngle:c,endAngle:l});var b=`M ${p.x},${p.y}
|
|
28
|
+
A${a},${a},0,0,${+(u<0)},${f.x},${f.y}
|
|
29
|
+
A${i},${i},0,${+(y>180)},${+(u<0)},${g.x},${g.y}
|
|
30
|
+
A${a},${a},0,0,${+(u<0)},${_.x},${_.y}
|
|
31
|
+
`;if(r>0){var x=_y({cx:t,cy:n,radius:r,angle:c,sign:u,isExternal:!0,cornerRadius:a,cornerIsExternal:s}),S=x.circleTangency,C=x.lineTangency,w=x.theta,T=_y({cx:t,cy:n,radius:r,angle:l,sign:-u,isExternal:!0,cornerRadius:a,cornerIsExternal:s}),E=T.circleTangency,D=T.lineTangency,O=T.theta,k=s?Math.abs(c-l):Math.abs(c-l)-w-O;if(k<0&&a===0)return`${b}L${t},${n}Z`;b+=`L${D.x},${D.y}
|
|
32
|
+
A${a},${a},0,0,${+(u<0)},${E.x},${E.y}
|
|
33
|
+
A${r},${r},0,${+(k>180)},${+(u>0)},${S.x},${S.y}
|
|
34
|
+
A${a},${a},0,0,${+(u<0)},${C.x},${C.y}Z`}else b+=`L${t},${n}Z`;return b},by={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},xy=function(e){var t=fy(fy({},by),e),n=t.cx,r=t.cy,i=t.innerRadius,a=t.outerRadius,o=t.cornerRadius,s=t.forceCornerRadius,c=t.cornerIsExternal,l=t.startAngle,u=t.endAngle,d=t.className;if(a<i||l===u)return null;var f=v(`recharts-sector`,d),p=a-i,m=tn(o,p,0,!0),h=m>0&&Math.abs(l-u)<360?yy({cx:n,cy:r,innerRadius:i,outerRadius:a,cornerRadius:Math.min(m,p/2),forceCornerRadius:s,cornerIsExternal:c,startAngle:l,endAngle:u}):vy({cx:n,cy:r,innerRadius:i,outerRadius:a,startAngle:l,endAngle:u});return R.createElement(`path`,uy({},B(t,!0),{className:f,d:h,role:`img`}))};function Sy(e){"@babel/helpers - typeof";return Sy=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Sy(e)}function Cy(){return Cy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Cy.apply(this,arguments)}function wy(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 Ty(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?wy(Object(n),!0).forEach(function(t){Ey(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wy(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Ey(e,t,n){return t=Dy(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Dy(e){var t=Oy(e,`string`);return Sy(t)==`symbol`?t:t+``}function Oy(e,t){if(Sy(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Sy(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var ky={curveBasisClosed:Qr,curveBasisOpen:ei,curveBasis:Xr,curveBumpX:Er,curveBumpY:Dr,curveLinearClosed:ni,curveLinear:br,curveMonotoneX:ui,curveMonotoneY:di,curveNatural:mi,curveStep:gi,curveStepAfter:vi,curveStepBefore:_i},Ay=function(e){return e.x===+e.x&&e.y===+e.y},jy=function(e){return e.x},My=function(e){return e.y},Ny=function(e,t){if((0,z.default)(e))return e;var n=`curve${(0,Di.default)(e)}`;return(n===`curveMonotone`||n===`curveBump`)&&t?ky[`${n}${t===`vertical`?`Y`:`X`}`]:ky[n]||br},Py=function(e){var t=e.type,n=t===void 0?`linear`:t,r=e.points,i=r===void 0?[]:r,a=e.baseLine,o=e.layout,s=e.connectNulls,c=s!==void 0&&s,l=Ny(n,o),u=c?i.filter(function(e){return Ay(e)}):i,d;if(Array.isArray(a)){var f=c?a.filter(function(e){return Ay(e)}):a,p=u.map(function(e,t){return Ty(Ty({},e),{},{base:f[t]})});return d=o===`vertical`?wr().y(My).x1(jy).x0(function(e){return e.base.x}):wr().x(jy).y1(My).y0(function(e){return e.base.y}),d.defined(Ay).curve(l),d(p)}return d=o===`vertical`&&I(a)?wr().y(My).x1(jy).x0(a):I(a)?wr().x(jy).y1(My).y0(a):Cr().x(jy).y(My),d.defined(Ay).curve(l),d(u)},Fy=function(e){var t=e.className,n=e.points,r=e.path,i=e.pathRef;if((!n||!n.length)&&!r)return null;var a=n&&n.length?Py(e):r;return R.createElement(`path`,Cy({},B(e,!1),gn(e),{className:v(`recharts-curve`,t),d:a,ref:i}))},Iy=t(((e,t)=>{t.exports=`SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED`})),Ly=t(((e,t)=>{var n=Iy();function r(){}function i(){}i.resetWarningCache=r,t.exports=function(){function e(e,t,r,i,a,o){if(o!==n){var s=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name=`Invariant Violation`,s}}e.isRequired=e;function t(){return e}var a={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:r};return a.PropTypes=a,a}})),Ry=t(((e,t)=>{t.exports=Ly()()})),{getOwnPropertyNames:zy,getOwnPropertySymbols:By}=Object,{hasOwnProperty:Vy}=Object.prototype;function Hy(e,t){return function(n,r,i){return e(n,r,i)&&t(n,r,i)}}function Uy(e){return function(t,n,r){if(!t||!n||typeof t!=`object`||typeof n!=`object`)return e(t,n,r);let{cache:i}=r,a=i.get(t),o=i.get(n);if(a&&o)return a===n&&o===t;i.set(t,n),i.set(n,t);let s=e(t,n,r);return i.delete(t),i.delete(n),s}}function Wy(e){return e?.[Symbol.toStringTag]}function Gy(e){return zy(e).concat(By(e))}var Ky=Object.hasOwn||((e,t)=>Vy.call(e,t));function qy(e,t){return e===t||!e&&!t&&e!==e&&t!==t}var Jy=`__v`,Yy=`__o`,Xy=`_owner`,Zy=typeof Float16Array<`u`,{getOwnPropertyDescriptor:Qy,keys:$y}=Object;function eb(e,t){return e.byteLength===t.byteLength&&pb(new Uint8Array(e),new Uint8Array(t))}function tb(e,t,n){let r=e.length;if(t.length!==r)return!1;for(;r-->0;)if(!n.equals(e[r],t[r],r,r,e,t,n))return!1;return!0}function nb(e,t){return e.byteLength===t.byteLength&&pb(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function rb(e,t){return qy(e.getTime(),t.getTime())}function ib(e,t,n){return e.name===t.name&&e.message===t.message&&e.stack===t.stack&&n.equals(e.cause,t.cause,`cause`,`cause`,e,t,n)}function ab(e,t){return e===t}function ob(e,t,n){let r=e.size;if(r!==t.size)return!1;if(!r)return!0;let i=Array(r),a=e.entries(),o,s,c=0;for(;(o=a.next())&&!o.done;){let r=t.entries(),a=!1,l=0;for(;(s=r.next())&&!s.done;){if(i[l]){l++;continue}let r=o.value,u=s.value;if(n.equals(r[0],u[0],c,l,e,t,n)&&n.equals(r[1],u[1],r[0],u[0],e,t,n)){a=i[l]=!0;break}l++}if(!a)return!1;c++}return!0}var sb=qy;function cb(e,t,n){let r=$y(e),i=r.length;if($y(t).length!==i)return!1;for(;i-->0;)if(!_b(e,t,n,r[i]))return!1;return!0}function lb(e,t,n){let r=Gy(e),i=r.length;if(Gy(t).length!==i)return!1;let a,o,s;for(;i-->0;)if(a=r[i],!_b(e,t,n,a)||(o=Qy(e,a),s=Qy(t,a),(o||s)&&(!o||!s||o.configurable!==s.configurable||o.enumerable!==s.enumerable||o.writable!==s.writable)))return!1;return!0}function ub(e,t){return qy(e.valueOf(),t.valueOf())}function db(e,t){return e.source===t.source&&e.flags===t.flags}function fb(e,t,n){let r=e.size;if(r!==t.size)return!1;if(!r)return!0;let i=Array(r),a=e.values(),o,s;for(;(o=a.next())&&!o.done;){let r=t.values(),a=!1,c=0;for(;(s=r.next())&&!s.done;){if(!i[c]&&n.equals(o.value,s.value,o.value,s.value,e,t,n)){a=i[c]=!0;break}c++}if(!a)return!1}return!0}function pb(e,t){let n=e.length;if(t.length!==n||e.byteOffset!==t.byteOffset)return!1;if(e instanceof Float64Array||e instanceof Float32Array||Zy&&e instanceof Float16Array){for(;n-->0;)if(e[n]!==t[n]&&(e[n]===e[n]||t[n]===t[n]))return!1;return!0}for(;n-->0;)if(e[n]!==t[n])return!1;return!0}function mb(e,t){return e.href===t.href||e.protocol===t.protocol&&e.username===t.username&&e.password===t.password&&e.host===t.host&&e.pathname===t.pathname&&e.hash===t.hash&&hb(e.searchParams,t.searchParams)}function hb(e,t){let n=e.toString(),r=t.toString();return n===r||gb(n)===gb(r)}function gb(e){return e.split(`&`).sort().join(`&`)}function _b(e,t,n,r){return(r===Xy||r===Yy||r===Jy)&&(e.$$typeof||t.$$typeof)?!0:Ky(t,r)&&n.equals(e[r],t[r],r,r,e,t,n)}var vb=`[object ArrayBuffer]`,yb=`[object Arguments]`,bb=`[object Boolean]`,xb=`[object DataView]`,Sb=`[object Date]`,Cb=`[object Error]`,wb=`[object Map]`,Tb=`[object Number]`,Eb=`[object Object]`,Db=`[object RegExp]`,Ob=`[object Set]`,kb=`[object String]`,Ab={"[object Int8Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Int16Array]":!0,"[object Uint16Array]":!0,"[object Int32Array]":!0,"[object Uint32Array]":!0,"[object Float16Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0,"[object BigInt64Array]":!0,"[object BigUint64Array]":!0},jb=`[object URL]`,Mb=Object.prototype.toString;function Nb({areArrayBuffersEqual:e,areArraysEqual:t,areDataViewsEqual:n,areDatesEqual:r,areErrorsEqual:i,areFunctionsEqual:a,areMapsEqual:o,areNumbersEqual:s,areObjectsEqual:c,arePrimitiveWrappersEqual:l,areRegExpsEqual:u,areSetsEqual:d,areTypedArraysEqual:f,areUrlsEqual:p,unknownTagComparators:m}){return function(h,g,_){if(h===g)return!0;if(h==null||g==null)return!1;let v=typeof h;if(v!==typeof g)return!1;if(v!==`object`)return v===`number`?s(h,g,_):v===`function`&&a(h,g,_);let y=h.constructor;if(y!==g.constructor)return!1;if(y===Object)return c(h,g,_);if(Array.isArray(h))return t(h,g,_);if(y===Date)return r(h,g,_);if(y===RegExp)return u(h,g,_);if(y===Map)return o(h,g,_);if(y===Set)return d(h,g,_);let b=Mb.call(h);if(b===Sb)return r(h,g,_);if(b===Db)return u(h,g,_);if(b===wb)return o(h,g,_);if(b===Ob)return d(h,g,_);if(b===Eb)return typeof h.then!=`function`&&typeof g.then!=`function`&&c(h,g,_);if(b===jb)return p(h,g,_);if(b===Cb)return i(h,g,_);if(b===yb)return c(h,g,_);if(Ab[b])return f(h,g,_);if(b===vb)return e(h,g,_);if(b===xb)return n(h,g,_);if(b===bb||b===Tb||b===kb)return l(h,g,_);if(m){let e=m[b];if(!e){let t=Wy(h);t&&(e=m[t])}if(e)return e(h,g,_)}return!1}}function Pb({circular:e,createCustomConfig:t,strict:n}){let r={areArrayBuffersEqual:eb,areArraysEqual:n?lb:tb,areDataViewsEqual:nb,areDatesEqual:rb,areErrorsEqual:n?Hy(ib,lb):Hy(ib,cb),areFunctionsEqual:ab,areMapsEqual:n?Hy(ob,lb):ob,areNumbersEqual:sb,areObjectsEqual:n?lb:cb,arePrimitiveWrappersEqual:ub,areRegExpsEqual:db,areSetsEqual:n?Hy(fb,lb):fb,areTypedArraysEqual:n?Hy(pb,lb):pb,areUrlsEqual:mb,unknownTagComparators:void 0};if(t&&(r=Object.assign({},r,t(r))),e){let e=Uy(r.areArraysEqual),t=Uy(r.areErrorsEqual),n=Uy(r.areMapsEqual),i=Uy(r.areObjectsEqual),a=Uy(r.areSetsEqual);r=Object.assign({},r,{areArraysEqual:e,areErrorsEqual:t,areMapsEqual:n,areObjectsEqual:i,areSetsEqual:a})}return r}function Fb(e){return function(t,n,r,i,a,o,s){return e(t,n,s)}}function Ib({circular:e,comparator:t,createState:n,equals:r,strict:i}){if(n)return function(a,o){let{cache:s=e?new WeakMap:void 0,meta:c}=n();return t(a,o,{cache:s,equals:r,meta:c,strict:i})};if(e)return function(e,n){return t(e,n,{cache:new WeakMap,equals:r,meta:void 0,strict:i})};let a={cache:void 0,equals:r,meta:void 0,strict:i};return function(e,n){return t(e,n,a)}}var Lb=Rb();Rb({strict:!0}),Rb({circular:!0}),Rb({circular:!0,strict:!0}),Rb({createInternalComparator:()=>qy}),Rb({strict:!0,createInternalComparator:()=>qy}),Rb({circular:!0,createInternalComparator:()=>qy}),Rb({circular:!0,createInternalComparator:()=>qy,strict:!0});function Rb(e={}){let{circular:t=!1,createInternalComparator:n,createState:r,strict:i=!1}=e,a=Nb(Pb(e));return Ib({circular:t,comparator:a,createState:r,equals:n?n(a):Fb(a),strict:i})}function zb(e){typeof requestAnimationFrame<`u`&&requestAnimationFrame(e)}function Bb(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=-1;requestAnimationFrame(function r(i){n<0&&(n=i),i-n>t?(e(i),n=-1):zb(r)})}function Vb(e){"@babel/helpers - typeof";return Vb=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Vb(e)}function Hb(e){return qb(e)||Kb(e)||Wb(e)||Ub()}function Ub(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
35
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Wb(e,t){if(e){if(typeof e==`string`)return Gb(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Gb(e,t)}}function Gb(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Kb(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function qb(e){if(Array.isArray(e))return e}function Jb(){var e={},t=function(){return null},n=!1,r=function r(i){if(!n){if(Array.isArray(i)){if(!i.length)return;var a=Hb(i),o=a[0],s=a.slice(1);if(typeof o==`number`){Bb(r.bind(null,s),o);return}r(o),Bb(r.bind(null,s));return}Vb(i)===`object`&&(e=i,t(e)),typeof i==`function`&&i()}};return{stop:function(){n=!0},start:function(e){n=!1,r(e)},subscribe:function(e){return t=e,function(){t=function(){return null}}}}}function Yb(e){"@babel/helpers - typeof";return Yb=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Yb(e)}function Xb(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 Zb(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Xb(Object(n),!0).forEach(function(t){Qb(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xb(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Qb(e,t,n){return t=$b(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $b(e){var t=ex(e,`string`);return Yb(t)===`symbol`?t:String(t)}function ex(e,t){if(Yb(e)!==`object`||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Yb(r)!==`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var tx=function(e,t){return[Object.keys(e),Object.keys(t)].reduce(function(e,t){return e.filter(function(e){return t.includes(e)})})},nx=function(e){return e},rx=function(e){return e.replace(/([A-Z])/g,function(e){return`-${e.toLowerCase()}`})},ix=function(e,t){return Object.keys(t).reduce(function(n,r){return Zb(Zb({},n),{},Qb({},r,e(r,t[r])))},{})},ax=function(e,t,n){return e.map(function(e){return`${rx(e)} ${t}ms ${n}`}).join(`,`)};function ox(e,t){return lx(e)||cx(e,t)||fx(e,t)||sx()}function sx(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
36
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cx(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function lx(e){if(Array.isArray(e))return e}function ux(e){return mx(e)||px(e)||fx(e)||dx()}function dx(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
37
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function fx(e,t){if(e){if(typeof e==`string`)return hx(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return hx(e,t)}}function px(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function mx(e){if(Array.isArray(e))return hx(e)}function hx(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var gx=1e-4,_x=function(e,t){return[0,3*e,3*t-6*e,3*e-3*t+1]},vx=function(e,t){return e.map(function(e,n){return e*t**+n}).reduce(function(e,t){return e+t})},yx=function(e,t){return function(n){return vx(_x(e,t),n)}},bx=function(e,t){return function(n){var r=_x(e,t);return vx([].concat(ux(r.map(function(e,t){return e*t}).slice(1)),[0]),n)}},xx=function(){var e=[...arguments],t=e[0],n=e[1],r=e[2],i=e[3];if(e.length===1)switch(e[0]){case`linear`:t=0,n=0,r=1,i=1;break;case`ease`:t=.25,n=.1,r=.25,i=1;break;case`ease-in`:t=.42,n=0,r=1,i=1;break;case`ease-out`:t=.42,n=0,r=.58,i=1;break;case`ease-in-out`:t=0,n=0,r=.58,i=1;break;default:var a=e[0].split(`(`);if(a[0]===`cubic-bezier`&&a[1].split(`)`)[0].split(`,`).length===4){var o=ox(a[1].split(`)`)[0].split(`,`).map(function(e){return parseFloat(e)}),4);t=o[0],n=o[1],r=o[2],i=o[3]}}[t,r,n,i].every(function(e){return typeof e==`number`&&e>=0&&e<=1});var s=yx(t,r),c=yx(n,i),l=bx(t,r),u=function(e){return e>1?1:e<0?0:e},d=function(e){for(var t=e>1?1:e,n=t,r=0;r<8;++r){var i=s(n)-t,a=l(n);if(Math.abs(i-t)<gx||a<gx)return c(n);n=u(n-i/a)}return c(n)};return d.isStepper=!1,d},Sx=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=e.stiff,n=t===void 0?100:t,r=e.damping,i=r===void 0?8:r,a=e.dt,o=a===void 0?17:a,s=function(e,t,r){var a=r+(-(e-t)*n-r*i)*o/1e3,s=r*o/1e3+e;return Math.abs(s-t)<gx&&Math.abs(a)<gx?[t,0]:[s,a]};return s.isStepper=!0,s.dt=o,s},Cx=function(){var e=[...arguments][0];if(typeof e==`string`)switch(e){case`ease`:case`ease-in-out`:case`ease-out`:case`ease-in`:case`linear`:return xx(e);case`spring`:return Sx();default:if(e.split(`(`)[0]===`cubic-bezier`)return xx(e)}return typeof e==`function`?e:null};function wx(e){"@babel/helpers - typeof";return wx=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},wx(e)}function Tx(e){return Ox(e)||Dx(e)||Ix(e)||Ex()}function Ex(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
38
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Dx(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function Ox(e){if(Array.isArray(e))return Lx(e)}function kx(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 Ax(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?kx(Object(n),!0).forEach(function(t){jx(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kx(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function jx(e,t,n){return t=Mx(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Mx(e){var t=Nx(e,`string`);return wx(t)===`symbol`?t:String(t)}function Nx(e,t){if(wx(e)!==`object`||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(wx(r)!==`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Px(e,t){return zx(e)||Rx(e,t)||Ix(e,t)||Fx()}function Fx(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
39
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ix(e,t){if(e){if(typeof e==`string`)return Lx(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Lx(e,t)}}function Lx(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Rx(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function zx(e){if(Array.isArray(e))return e}var Bx=function(e,t,n){return e+(t-e)*n},Vx=function(e){return e.from!==e.to},Hx=function e(t,n,r){var i=ix(function(e,n){if(Vx(n)){var r=Px(t(n.from,n.to,n.velocity),2),i=r[0],a=r[1];return Ax(Ax({},n),{},{from:i,velocity:a})}return n},n);return r<1?ix(function(e,t){return Vx(t)?Ax(Ax({},t),{},{velocity:Bx(t.velocity,i[e].velocity,r),from:Bx(t.from,i[e].from,r)}):t},n):e(t,i,r-1)},Ux=(function(e,t,n,r,i){var a=tx(e,t),o=a.reduce(function(n,r){return Ax(Ax({},n),{},jx({},r,[e[r],t[r]]))},{}),s=a.reduce(function(n,r){return Ax(Ax({},n),{},jx({},r,{from:e[r],velocity:0,to:t[r]}))},{}),c=-1,l,u,d=function(){return null},f=function(){return ix(function(e,t){return t.from},s)},p=function(){return!Object.values(s).filter(Vx).length};return d=n.isStepper?function(r){l||=r;var a=(r-l)/n.dt;s=Hx(n,s,a),i(Ax(Ax(Ax({},e),t),f(s))),l=r,p()||(c=requestAnimationFrame(d))}:function(a){u||=a;var s=(a-u)/r,l=ix(function(e,t){return Bx.apply(void 0,Tx(t).concat([n(s)]))},o);if(i(Ax(Ax(Ax({},e),t),l)),s<1)c=requestAnimationFrame(d);else{var f=ix(function(e,t){return Bx.apply(void 0,Tx(t).concat([n(1)]))},o);i(Ax(Ax(Ax({},e),t),f))}},function(){return requestAnimationFrame(d),function(){cancelAnimationFrame(c)}}}),J=r(Ry());function Wx(e){"@babel/helpers - typeof";return Wx=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Wx(e)}var Gx=[`children`,`begin`,`duration`,`attributeName`,`easing`,`isActive`,`steps`,`from`,`to`,`canBegin`,`onAnimationEnd`,`shouldReAnimate`,`onAnimationReStart`];function Kx(e,t){if(e==null)return{};var n=qx(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function qx(e,t){if(e==null)return{};for(var n={},r=Object.keys(e),i,a=0;a<r.length;a++)i=r[a],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function Jx(e){return Qx(e)||Zx(e)||Xx(e)||Yx()}function Yx(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
40
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Xx(e,t){if(e){if(typeof e==`string`)return $x(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return $x(e,t)}}function Zx(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function Qx(e){if(Array.isArray(e))return $x(e)}function $x(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function eS(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 tS(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?eS(Object(n),!0).forEach(function(t){nS(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):eS(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function nS(e,t,n){return t=oS(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rS(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function iS(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,oS(r.key),r)}}function aS(e,t,n){return t&&iS(e.prototype,t),n&&iS(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function oS(e){var t=sS(e,`string`);return Wx(t)===`symbol`?t:String(t)}function sS(e,t){if(Wx(e)!==`object`||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Wx(r)!==`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function cS(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&lS(e,t)}function lS(e,t){return lS=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},lS(e,t)}function uS(e){var t=pS();return function(){var n=mS(e),r;if(t){var i=mS(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return dS(this,r)}}function dS(e,t){if(t&&(Wx(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return fS(e)}function fS(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function pS(){if(typeof Reflect>`u`||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy==`function`)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function mS(e){return mS=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},mS(e)}var hS=function(e){cS(n,e);var t=uS(n);function n(e,r){var i;rS(this,n),i=t.call(this,e,r);var a=i.props,o=a.isActive,s=a.attributeName,c=a.from,l=a.to,u=a.steps,d=a.children,f=a.duration;if(i.handleStyleChange=i.handleStyleChange.bind(fS(i)),i.changeStyle=i.changeStyle.bind(fS(i)),!o||f<=0)return i.state={style:{}},typeof d==`function`&&(i.state={style:l}),dS(i);if(u&&u.length)i.state={style:u[0].style};else if(c){if(typeof d==`function`)return i.state={style:c},dS(i);i.state={style:s?nS({},s,c):c}}else i.state={style:{}};return i}return aS(n,[{key:`componentDidMount`,value:function(){var e=this.props,t=e.isActive,n=e.canBegin;this.mounted=!0,t&&n&&this.runAnimation(this.props)}},{key:`componentDidUpdate`,value:function(e){var t=this.props,n=t.isActive,r=t.canBegin,i=t.attributeName,a=t.shouldReAnimate,o=t.to,s=t.from,c=this.state.style;if(r){if(!n){var l={style:i?nS({},i,o):o};this.state&&c&&(i&&c[i]!==o||!i&&c!==o)&&this.setState(l);return}if(!(Lb(e.to,o)&&e.canBegin&&e.isActive)){var u=!e.canBegin||!e.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var d=u||a?s:e.to;if(this.state&&c){var f={style:i?nS({},i,d):d};(i&&c[i]!==d||!i&&c!==d)&&this.setState(f)}this.runAnimation(tS(tS({},this.props),{},{from:d,begin:0}))}}}},{key:`componentWillUnmount`,value:function(){this.mounted=!1;var e=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&=(this.manager.stop(),null),this.stopJSAnimation&&this.stopJSAnimation(),e&&e()}},{key:`handleStyleChange`,value:function(e){this.changeStyle(e)}},{key:`changeStyle`,value:function(e){this.mounted&&this.setState({style:e})}},{key:`runJSAnimation`,value:function(e){var t=this,n=e.from,r=e.to,i=e.duration,a=e.easing,o=e.begin,s=e.onAnimationEnd,c=e.onAnimationStart,l=Ux(n,r,Cx(a),i,this.changeStyle);this.manager.start([c,o,function(){t.stopJSAnimation=l()},i,s])}},{key:`runStepAnimation`,value:function(e){var t=this,n=e.steps,r=e.begin,i=e.onAnimationStart,a=n[0],o=a.style,s=a.duration,c=s===void 0?0:s;return this.manager.start([i].concat(Jx(n.reduce(function(e,r,i){if(i===0)return e;var a=r.duration,o=r.easing,s=o===void 0?`ease`:o,c=r.style,l=r.properties,u=r.onAnimationEnd,d=i>0?n[i-1]:r,f=l||Object.keys(c);if(typeof s==`function`||s===`spring`)return[].concat(Jx(e),[t.runJSAnimation.bind(t,{from:d.style,to:c,duration:a,easing:s}),a]);var p=ax(f,a,s),m=tS(tS(tS({},d.style),c),{},{transition:p});return[].concat(Jx(e),[m,a,u]).filter(nx)},[o,Math.max(c,r)])),[e.onAnimationEnd]))}},{key:`runAnimation`,value:function(e){this.manager||=Jb();var t=e.begin,n=e.duration,r=e.attributeName,i=e.to,a=e.easing,o=e.onAnimationStart,s=e.onAnimationEnd,c=e.steps,l=e.children,u=this.manager;if(this.unSubscribe=u.subscribe(this.handleStyleChange),typeof a==`function`||typeof l==`function`||a===`spring`){this.runJSAnimation(e);return}if(c.length>1){this.runStepAnimation(e);return}var d=r?nS({},r,i):i,f=ax(Object.keys(d),n,a);u.start([o,t,tS(tS({},d),{},{transition:f}),n,s])}},{key:`render`,value:function(){var e=this.props,t=e.children;e.begin;var n=e.duration;e.attributeName,e.easing;var r=e.isActive;e.steps,e.from,e.to,e.canBegin,e.onAnimationEnd,e.shouldReAnimate,e.onAnimationReStart;var i=Kx(e,Gx),a=R.Children.count(t),o=this.state.style;if(typeof t==`function`)return t(o);if(!r||a===0||n<=0)return t;var s=function(e){var t=e.props,n=t.style,r=n===void 0?{}:n,a=t.className;return(0,R.cloneElement)(e,tS(tS({},i),{},{style:tS(tS({},r),o),className:a}))};return a===1?s(R.Children.only(t)):R.createElement(`div`,null,R.Children.map(t,function(e){return s(e)}))}}]),n}(R.PureComponent);hS.displayName=`Animate`,hS.defaultProps={begin:0,duration:1e3,from:``,to:``,attributeName:``,easing:`ease`,isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}},hS.propTypes={from:J.default.oneOfType([J.default.object,J.default.string]),to:J.default.oneOfType([J.default.object,J.default.string]),attributeName:J.default.string,duration:J.default.number,begin:J.default.number,easing:J.default.oneOfType([J.default.string,J.default.func]),steps:J.default.arrayOf(J.default.shape({duration:J.default.number.isRequired,style:J.default.object.isRequired,easing:J.default.oneOfType([J.default.oneOf([`ease`,`ease-in`,`ease-out`,`ease-in-out`,`linear`]),J.default.func]),properties:J.default.arrayOf(`string`),onAnimationEnd:J.default.func})),children:J.default.oneOfType([J.default.node,J.default.func]),isActive:J.default.bool,canBegin:J.default.bool,onAnimationEnd:J.default.func,shouldReAnimate:J.default.bool,onAnimationStart:J.default.func,onAnimationReStart:J.default.func};var gS=hS;function _S(e){"@babel/helpers - typeof";return _S=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},_S(e)}function vS(){return vS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vS.apply(this,arguments)}function yS(e,t){return wS(e)||CS(e,t)||xS(e,t)||bS()}function bS(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
41
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xS(e,t){if(e){if(typeof e==`string`)return SS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return SS(e,t)}}function SS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function CS(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function wS(e){if(Array.isArray(e))return e}function TS(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 ES(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?TS(Object(n),!0).forEach(function(t){DS(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):TS(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function DS(e,t,n){return t=OS(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function OS(e){var t=kS(e,`string`);return _S(t)==`symbol`?t:t+``}function kS(e,t){if(_S(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(_S(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var AS=function(e,t,n,r,i){var a=Math.min(Math.abs(n)/2,Math.abs(r)/2),o=r>=0?1:-1,s=n>=0?1:-1,c=+(r>=0&&n>=0||r<0&&n<0),l;if(a>0&&i instanceof Array){for(var u=[0,0,0,0],d=0,f=4;d<f;d++)u[d]=i[d]>a?a:i[d];l=`M${e},${t+o*u[0]}`,u[0]>0&&(l+=`A ${u[0]},${u[0]},0,0,${c},${e+s*u[0]},${t}`),l+=`L ${e+n-s*u[1]},${t}`,u[1]>0&&(l+=`A ${u[1]},${u[1]},0,0,${c},
|
|
42
|
+
${e+n},${t+o*u[1]}`),l+=`L ${e+n},${t+r-o*u[2]}`,u[2]>0&&(l+=`A ${u[2]},${u[2]},0,0,${c},
|
|
43
|
+
${e+n-s*u[2]},${t+r}`),l+=`L ${e+s*u[3]},${t+r}`,u[3]>0&&(l+=`A ${u[3]},${u[3]},0,0,${c},
|
|
44
|
+
${e},${t+r-o*u[3]}`),l+=`Z`}else if(a>0&&i===+i&&i>0){var p=Math.min(a,i);l=`M ${e},${t+o*p}
|
|
45
|
+
A ${p},${p},0,0,${c},${e+s*p},${t}
|
|
46
|
+
L ${e+n-s*p},${t}
|
|
47
|
+
A ${p},${p},0,0,${c},${e+n},${t+o*p}
|
|
48
|
+
L ${e+n},${t+r-o*p}
|
|
49
|
+
A ${p},${p},0,0,${c},${e+n-s*p},${t+r}
|
|
50
|
+
L ${e+s*p},${t+r}
|
|
51
|
+
A ${p},${p},0,0,${c},${e},${t+r-o*p} Z`}else l=`M ${e},${t} h ${n} v ${r} h ${-n} Z`;return l},jS=function(e,t){if(!e||!t)return!1;var n=e.x,r=e.y,i=t.x,a=t.y,o=t.width,s=t.height;if(Math.abs(o)>0&&Math.abs(s)>0){var c=Math.min(i,i+o),l=Math.max(i,i+o),u=Math.min(a,a+s),d=Math.max(a,a+s);return n>=c&&n<=l&&r>=u&&r<=d}return!1},MS={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:`ease`},NS=function(e){var t=ES(ES({},MS),e),n=(0,R.useRef)(),r=yS((0,R.useState)(-1),2),i=r[0],a=r[1];(0,R.useEffect)(function(){if(n.current&&n.current.getTotalLength)try{var e=n.current.getTotalLength();e&&a(e)}catch{}},[]);var o=t.x,s=t.y,c=t.width,l=t.height,u=t.radius,d=t.className,f=t.animationEasing,p=t.animationDuration,m=t.animationBegin,h=t.isAnimationActive,g=t.isUpdateAnimationActive;if(o!==+o||s!==+s||c!==+c||l!==+l||c===0||l===0)return null;var _=v(`recharts-rectangle`,d);return g?R.createElement(gS,{canBegin:i>0,from:{width:c,height:l,x:o,y:s},to:{width:c,height:l,x:o,y:s},duration:p,animationEasing:f,isActive:g},function(e){var r=e.width,a=e.height,o=e.x,s=e.y;return R.createElement(gS,{canBegin:i>0,from:`0px ${i===-1?1:i}px`,to:`${i}px 0px`,attributeName:`strokeDasharray`,begin:m,duration:p,isActive:h,easing:f},R.createElement(`path`,vS({},B(t,!0),{className:_,d:AS(o,s,r,a,u),ref:n})))}):R.createElement(`path`,vS({},B(t,!0),{className:_,d:AS(o,s,c,l,u)}))};function PS(){return PS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},PS.apply(this,arguments)}var FS=function(e){var t=e.cx,n=e.cy,r=e.r,i=e.className,a=v(`recharts-dot`,i);return t===+t&&n===+n&&r===+r?R.createElement(`circle`,PS({},B(e,!1),gn(e),{className:a,cx:t,cy:n,r})):null};function IS(e){"@babel/helpers - typeof";return IS=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},IS(e)}var LS=[`x`,`y`,`top`,`left`,`width`,`height`,`className`];function RS(){return RS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},RS.apply(this,arguments)}function zS(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 BS(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?zS(Object(n),!0).forEach(function(t){VS(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zS(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function VS(e,t,n){return t=HS(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function HS(e){var t=US(e,`string`);return IS(t)==`symbol`?t:t+``}function US(e,t){if(IS(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(IS(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function WS(e,t){if(e==null)return{};var n=GS(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function GS(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var KS=function(e,t,n,r,i,a){return`M${e},${i}v${r}M${a},${t}h${n}`},qS=function(e){var t=e.x,n=t===void 0?0:t,r=e.y,i=r===void 0?0:r,a=e.top,o=a===void 0?0:a,s=e.left,c=s===void 0?0:s,l=e.width,u=l===void 0?0:l,d=e.height,f=d===void 0?0:d,p=e.className,m=WS(e,LS),h=BS({x:n,y:i,top:o,left:c,width:u,height:f},m);return!I(n)||!I(i)||!I(u)||!I(f)||!I(o)||!I(c)?null:R.createElement(`path`,RS({},B(h,!0),{className:v(`recharts-cross`,p),d:KS(n,i,u,f,o,c)}))},JS=t(((e,t)=>{t.exports=Ua()(Object.getPrototypeOf,Object)})),YS=t(((e,t)=>{var n=Je(),r=JS(),i=Ye(),a=`[object Object]`,o=Function.prototype,s=Object.prototype,c=o.toString,l=s.hasOwnProperty,u=c.call(Object);function d(e){if(!i(e)||n(e)!=a)return!1;var t=r(e);if(t===null)return!0;var o=l.call(t,`constructor`)&&t.constructor;return typeof o==`function`&&o instanceof o&&c.call(o)==u}t.exports=d})),XS=t(((e,t)=>{var n=Je(),r=Ye(),i=`[object Boolean]`;function a(e){return e===!0||e===!1||r(e)&&n(e)==i}t.exports=a}));function ZS(e){"@babel/helpers - typeof";return ZS=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},ZS(e)}function QS(){return QS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},QS.apply(this,arguments)}function $S(e,t){return iC(e)||rC(e,t)||tC(e,t)||eC()}function eC(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
52
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function tC(e,t){if(e){if(typeof e==`string`)return nC(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return nC(e,t)}}function nC(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function rC(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function iC(e){if(Array.isArray(e))return e}function aC(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 oC(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?aC(Object(n),!0).forEach(function(t){sC(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):aC(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function sC(e,t,n){return t=cC(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cC(e){var t=lC(e,`string`);return ZS(t)==`symbol`?t:t+``}function lC(e,t){if(ZS(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(ZS(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var uC=function(e,t,n,r,i){var a=n-r,o=`M ${e},${t}`;return o+=`L ${e+n},${t}`,o+=`L ${e+n-a/2},${t+i}`,o+=`L ${e+n-a/2-r},${t+i}`,o+=`L ${e},${t} Z`,o},dC={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:`ease`},fC=function(e){var t=oC(oC({},dC),e),n=(0,R.useRef)(),r=$S((0,R.useState)(-1),2),i=r[0],a=r[1];(0,R.useEffect)(function(){if(n.current&&n.current.getTotalLength)try{var e=n.current.getTotalLength();e&&a(e)}catch{}},[]);var o=t.x,s=t.y,c=t.upperWidth,l=t.lowerWidth,u=t.height,d=t.className,f=t.animationEasing,p=t.animationDuration,m=t.animationBegin,h=t.isUpdateAnimationActive;if(o!==+o||s!==+s||c!==+c||l!==+l||u!==+u||c===0&&l===0||u===0)return null;var g=v(`recharts-trapezoid`,d);return h?R.createElement(gS,{canBegin:i>0,from:{upperWidth:0,lowerWidth:0,height:u,x:o,y:s},to:{upperWidth:c,lowerWidth:l,height:u,x:o,y:s},duration:p,animationEasing:f,isActive:h},function(e){var r=e.upperWidth,a=e.lowerWidth,o=e.height,s=e.x,c=e.y;return R.createElement(gS,{canBegin:i>0,from:`0px ${i===-1?1:i}px`,to:`${i}px 0px`,attributeName:`strokeDasharray`,begin:m,duration:p,easing:f},R.createElement(`path`,QS({},B(t,!0),{className:g,d:uC(s,c,r,a,o),ref:n})))}):R.createElement(`g`,null,R.createElement(`path`,QS({},B(t,!0),{className:g,d:uC(o,s,c,l,u)})))},pC=r(YS()),mC=r(XS()),hC=[`option`,`shapeType`,`propTransformer`,`activeClassName`,`isActive`];function gC(e){"@babel/helpers - typeof";return gC=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},gC(e)}function _C(e,t){if(e==null)return{};var n=vC(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function vC(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function yC(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 bC(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?yC(Object(n),!0).forEach(function(t){xC(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yC(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function xC(e,t,n){return t=SC(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function SC(e){var t=CC(e,`string`);return gC(t)==`symbol`?t:t+``}function CC(e,t){if(gC(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(gC(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function wC(e,t){return bC(bC({},t),e)}function TC(e,t){return e===`symbols`}function EC(e){var t=e.shapeType,n=e.elementProps;switch(t){case`rectangle`:return R.createElement(NS,n);case`trapezoid`:return R.createElement(fC,n);case`sector`:return R.createElement(xy,n);case`symbols`:if(TC(t,n))return R.createElement(Ui,n);break;default:return null}}function DC(e){return(0,R.isValidElement)(e)?e.props:e}function OC(e){var t=e.option,n=e.shapeType,r=e.propTransformer,i=r===void 0?wC:r,a=e.activeClassName,o=a===void 0?`recharts-active-shape`:a,s=e.isActive,c=_C(e,hC),l;if((0,R.isValidElement)(t))l=(0,R.cloneElement)(t,bC(bC({},c),DC(t)));else if((0,z.default)(t))l=t(c);else if((0,pC.default)(t)&&!(0,mC.default)(t)){var u=i(t,c);l=R.createElement(EC,{shapeType:n,elementProps:u})}else{var d=c;l=R.createElement(EC,{shapeType:n,elementProps:d})}return s?R.createElement(V,{className:o},l):l}function kC(e,t){return t!=null&&`trapezoids`in e.props}function AC(e,t){return t!=null&&`sectors`in e.props}function jC(e,t){return t!=null&&`points`in e.props}function MC(e,t){var n,r,i=e.x===(t==null||(n=t.labelViewBox)==null?void 0:n.x)||e.x===t.x,a=e.y===(t==null||(r=t.labelViewBox)==null?void 0:r.y)||e.y===t.y;return i&&a}function NC(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function PC(e,t){var n=e.x===t.x,r=e.y===t.y,i=e.z===t.z;return n&&r&&i}function FC(e,t){var n;return kC(e,t)?n=MC:AC(e,t)?n=NC:jC(e,t)&&(n=PC),n}function IC(e,t){var n;return kC(e,t)?n=`trapezoids`:AC(e,t)?n=`sectors`:jC(e,t)&&(n=`points`),n}function LC(e,t){if(kC(e,t)){var n;return(n=t.tooltipPayload)==null||(n=n[0])==null||(n=n.payload)==null?void 0:n.payload}if(AC(e,t)){var r;return(r=t.tooltipPayload)==null||(r=r[0])==null||(r=r.payload)==null?void 0:r.payload}return jC(e,t)?t.payload:{}}function RC(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,i=IC(n,t),a=LC(n,t),o=r.filter(function(e,r){var o=(0,c_.default)(a,e),s=n.props[i].filter(function(e){return FC(n,t)(e,t)}),c=r===n.props[i].indexOf(s[s.length-1]);return o&&c});return r.indexOf(o[o.length-1])}var zC=t(((e,t)=>{var n=Math.ceil,r=Math.max;function i(e,t,i,a){for(var o=-1,s=r(n((t-e)/(i||1)),0),c=Array(s);s--;)c[a?s:++o]=e,e+=i;return c}t.exports=i})),BC=t(((e,t)=>{var n=Mc(),r=1/0,i=17976931348623157e292;function a(e){return e?(e=n(e),e===r||e===-r?(e<0?-1:1)*i:e===e?e:0):e===0?e:0}t.exports=a})),VC=t(((e,t)=>{var n=zC(),r=vs(),i=BC();function a(e){return function(t,a,o){return o&&typeof o!=`number`&&r(t,a,o)&&(a=o=void 0),t=i(t),a===void 0?(a=t,t=0):a=i(a),o=o===void 0?t<a?1:-1:i(o),n(t,a,o,e)}}t.exports=a})),HC=t(((e,t)=>{t.exports=VC()()}));function UC(e){"@babel/helpers - typeof";return UC=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},UC(e)}function WC(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 GC(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?WC(Object(n),!0).forEach(function(t){KC(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):WC(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function KC(e,t,n){return t=qC(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qC(e){var t=JC(e,`string`);return UC(t)==`symbol`?t:t+``}function JC(e,t){if(UC(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(UC(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var YC=[`Webkit`,`Moz`,`O`,`ms`],XC=function(e,t){if(!e)return null;var n=e.replace(/(\w)/,function(e){return e.toUpperCase()}),r=YC.reduce(function(e,r){return GC(GC({},e),{},KC({},r+n,t))},{});return r[e]=t,r},ZC=r(HC());function QC(e){"@babel/helpers - typeof";return QC=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},QC(e)}function $C(){return $C=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},$C.apply(this,arguments)}function ew(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 tw(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?ew(Object(n),!0).forEach(function(t){fw(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ew(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function nw(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function rw(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,pw(r.key),r)}}function iw(e,t,n){return t&&rw(e.prototype,t),n&&rw(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function aw(e,t,n){return t=lw(t),ow(e,cw()?Reflect.construct(t,n||[],lw(e).constructor):t.apply(e,n))}function ow(e,t){if(t&&(QC(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return sw(e)}function sw(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function cw(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(cw=function(){return!!e})()}function lw(e){return lw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},lw(e)}function uw(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&dw(e,t)}function dw(e,t){return dw=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},dw(e,t)}function fw(e,t,n){return t=pw(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pw(e){var t=mw(e,`string`);return QC(t)==`symbol`?t:t+``}function mw(e,t){if(QC(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(QC(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var hw=function(e){var t=e.data,n=e.startIndex,r=e.endIndex,i=e.x,a=e.width,o=e.travellerWidth;if(!t||!t.length)return{};var s=t.length,c=Pu().domain((0,ZC.default)(0,s)).range([i,i+a-o]),l=c.domain().map(function(e){return c(e)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:c(n),endX:c(r),scale:c,scaleValues:l}},gw=function(e){return e.changedTouches&&!!e.changedTouches.length},_w=function(e){function t(e){var n;return nw(this,t),n=aw(this,t,[e]),fw(n,`handleDrag`,function(e){n.leaveTimer&&(clearTimeout(n.leaveTimer),n.leaveTimer=null),n.state.isTravellerMoving?n.handleTravellerMove(e):n.state.isSlideMoving&&n.handleSlideDrag(e)}),fw(n,`handleTouchMove`,function(e){e.changedTouches!=null&&e.changedTouches.length>0&&n.handleDrag(e.changedTouches[0])}),fw(n,`handleDragEnd`,function(){n.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var e=n.props,t=e.endIndex,r=e.onDragEnd,i=e.startIndex;r?.({endIndex:t,startIndex:i})}),n.detachDragEndListener()}),fw(n,`handleLeaveWrapper`,function(){(n.state.isTravellerMoving||n.state.isSlideMoving)&&(n.leaveTimer=window.setTimeout(n.handleDragEnd,n.props.leaveTimeOut))}),fw(n,`handleEnterSlideOrTraveller`,function(){n.setState({isTextActive:!0})}),fw(n,`handleLeaveSlideOrTraveller`,function(){n.setState({isTextActive:!1})}),fw(n,`handleSlideDragStart`,function(e){var t=gw(e)?e.changedTouches[0]:e;n.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:t.pageX}),n.attachDragEndListener()}),n.travellerDragStartHandlers={startX:n.handleTravellerDragStart.bind(n,`startX`),endX:n.handleTravellerDragStart.bind(n,`endX`)},n.state={},n}return uw(t,e),iw(t,[{key:`componentWillUnmount`,value:function(){this.leaveTimer&&=(clearTimeout(this.leaveTimer),null),this.detachDragEndListener()}},{key:`getIndex`,value:function(e){var n=e.startX,r=e.endX,i=this.state.scaleValues,a=this.props,o=a.gap,s=a.data.length-1,c=Math.min(n,r),l=Math.max(n,r),u=t.getIndexInRange(i,c),d=t.getIndexInRange(i,l);return{startIndex:u-u%o,endIndex:d===s?s:d-d%o}}},{key:`getTextOfTick`,value:function(e){var t=this.props,n=t.data,r=t.tickFormatter,i=t.dataKey,a=b_(n[e],i,e);return(0,z.default)(r)?r(a,e):a}},{key:`attachDragEndListener`,value:function(){window.addEventListener(`mouseup`,this.handleDragEnd,!0),window.addEventListener(`touchend`,this.handleDragEnd,!0),window.addEventListener(`mousemove`,this.handleDrag,!0)}},{key:`detachDragEndListener`,value:function(){window.removeEventListener(`mouseup`,this.handleDragEnd,!0),window.removeEventListener(`touchend`,this.handleDragEnd,!0),window.removeEventListener(`mousemove`,this.handleDrag,!0)}},{key:`handleSlideDrag`,value:function(e){var t=this.state,n=t.slideMoveStartX,r=t.startX,i=t.endX,a=this.props,o=a.x,s=a.width,c=a.travellerWidth,l=a.startIndex,u=a.endIndex,d=a.onChange,f=e.pageX-n;f>0?f=Math.min(f,o+s-c-i,o+s-c-r):f<0&&(f=Math.max(f,o-r,o-i));var p=this.getIndex({startX:r+f,endX:i+f});(p.startIndex!==l||p.endIndex!==u)&&d&&d(p),this.setState({startX:r+f,endX:i+f,slideMoveStartX:e.pageX})}},{key:`handleTravellerDragStart`,value:function(e,t){var n=gw(t)?t.changedTouches[0]:t;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:e,brushMoveStartX:n.pageX}),this.attachDragEndListener()}},{key:`handleTravellerMove`,value:function(e){var t=this.state,n=t.brushMoveStartX,r=t.movingTravellerId,i=t.endX,a=t.startX,o=this.state[r],s=this.props,c=s.x,l=s.width,u=s.travellerWidth,d=s.onChange,f=s.gap,p=s.data,m={startX:this.state.startX,endX:this.state.endX},h=e.pageX-n;h>0?h=Math.min(h,c+l-u-o):h<0&&(h=Math.max(h,c-o)),m[r]=o+h;var g=this.getIndex(m),_=g.startIndex,v=g.endIndex,y=function(){var e=p.length-1;return r===`startX`&&(i>a?_%f===0:v%f===0)||i<a&&v===e||r===`endX`&&(i>a?v%f===0:_%f===0)||i>a&&v===e};this.setState(fw(fw({},r,o+h),`brushMoveStartX`,e.pageX),function(){d&&y()&&d(g)})}},{key:`handleTravellerMoveKeyboard`,value:function(e,t){var n=this,r=this.state,i=r.scaleValues,a=r.startX,o=r.endX,s=this.state[t],c=i.indexOf(s);if(c!==-1){var l=c+e;if(!(l===-1||l>=i.length)){var u=i[l];t===`startX`&&u>=o||t===`endX`&&u<=a||this.setState(fw({},t,u),function(){n.props.onChange(n.getIndex({startX:n.state.startX,endX:n.state.endX}))})}}}},{key:`renderBackground`,value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,i=e.height,a=e.fill,o=e.stroke;return R.createElement(`rect`,{stroke:o,fill:a,x:t,y:n,width:r,height:i})}},{key:`renderPanorama`,value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,i=e.height,a=e.data,o=e.children,s=e.padding,c=R.Children.only(o);return c?R.cloneElement(c,{x:t,y:n,width:r,height:i,margin:s,compact:!0,data:a}):null}},{key:`renderTravellerLayer`,value:function(e,n){var r=this,i=this.props,a=i.y,o=i.travellerWidth,s=i.height,c=i.traveller,l=i.ariaLabel,u=i.data,d=i.startIndex,f=i.endIndex,p=Math.max(e,this.props.x),m=tw(tw({},B(this.props,!1)),{},{x:p,y:a,width:o,height:s}),h=l||`Min value: ${u[d]?.name}, Max value: ${u[f]?.name}`;return R.createElement(V,{tabIndex:0,role:`slider`,"aria-label":h,"aria-valuenow":e,className:`recharts-brush-traveller`,onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[n],onTouchStart:this.travellerDragStartHandlers[n],onKeyDown:function(e){[`ArrowLeft`,`ArrowRight`].includes(e.key)&&(e.preventDefault(),e.stopPropagation(),r.handleTravellerMoveKeyboard(e.key===`ArrowRight`?1:-1,n))},onFocus:function(){r.setState({isTravellerFocused:!0})},onBlur:function(){r.setState({isTravellerFocused:!1})},style:{cursor:`col-resize`}},t.renderTraveller(c,m))}},{key:`renderSlide`,value:function(e,t){var n=this.props,r=n.y,i=n.height,a=n.stroke,o=n.travellerWidth,s=Math.min(e,t)+o,c=Math.max(Math.abs(t-e)-o,0);return R.createElement(`rect`,{className:`recharts-brush-slide`,onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:`move`},stroke:`none`,fill:a,fillOpacity:.2,x:s,y:r,width:c,height:i})}},{key:`renderText`,value:function(){var e=this.props,t=e.startIndex,n=e.endIndex,r=e.y,i=e.height,a=e.travellerWidth,o=e.stroke,s=this.state,c=s.startX,l=s.endX,u=5,d={pointerEvents:`none`,fill:o};return R.createElement(V,{className:`recharts-brush-texts`},R.createElement(Ql,$C({textAnchor:`end`,verticalAnchor:`middle`,x:Math.min(c,l)-u,y:r+i/2},d),this.getTextOfTick(t)),R.createElement(Ql,$C({textAnchor:`start`,verticalAnchor:`middle`,x:Math.max(c,l)+a+u,y:r+i/2},d),this.getTextOfTick(n)))}},{key:`render`,value:function(){var e=this.props,t=e.data,n=e.className,r=e.children,i=e.x,a=e.y,o=e.width,s=e.height,c=e.alwaysShowText,l=this.state,u=l.startX,d=l.endX,f=l.isTextActive,p=l.isSlideMoving,m=l.isTravellerMoving,h=l.isTravellerFocused;if(!t||!t.length||!I(i)||!I(a)||!I(o)||!I(s)||o<=0||s<=0)return null;var g=v(`recharts-brush`,n),_=R.Children.count(r)===1,y=XC(`userSelect`,`none`);return R.createElement(V,{className:g,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:y},this.renderBackground(),_&&this.renderPanorama(),this.renderSlide(u,d),this.renderTravellerLayer(u,`startX`),this.renderTravellerLayer(d,`endX`),(f||p||m||h||c)&&this.renderText())}}],[{key:`renderDefaultTraveller`,value:function(e){var t=e.x,n=e.y,r=e.width,i=e.height,a=e.stroke,o=Math.floor(n+i/2)-1;return R.createElement(R.Fragment,null,R.createElement(`rect`,{x:t,y:n,width:r,height:i,fill:a,stroke:`none`}),R.createElement(`line`,{x1:t+1,y1:o,x2:t+r-1,y2:o,fill:`none`,stroke:`#fff`}),R.createElement(`line`,{x1:t+1,y1:o+2,x2:t+r-1,y2:o+2,fill:`none`,stroke:`#fff`}))}},{key:`renderTraveller`,value:function(e,n){return R.isValidElement(e)?R.cloneElement(e,n):(0,z.default)(e)?e(n):t.renderDefaultTraveller(n)}},{key:`getDerivedStateFromProps`,value:function(e,t){var n=e.data,r=e.width,i=e.x,a=e.travellerWidth,o=e.updateId,s=e.startIndex,c=e.endIndex;if(n!==t.prevData||o!==t.prevUpdateId)return tw({prevData:n,prevTravellerWidth:a,prevUpdateId:o,prevX:i,prevWidth:r},n&&n.length?hw({data:n,width:r,x:i,travellerWidth:a,startIndex:s,endIndex:c}):{scale:null,scaleValues:null});if(t.scale&&(r!==t.prevWidth||i!==t.prevX||a!==t.prevTravellerWidth)){t.scale.range([i,i+r-a]);var l=t.scale.domain().map(function(e){return t.scale(e)});return{prevData:n,prevTravellerWidth:a,prevUpdateId:o,prevX:i,prevWidth:r,startX:t.scale(e.startIndex),endX:t.scale(e.endIndex),scaleValues:l}}return null}},{key:`getIndexInRange`,value:function(e,t){for(var n=e.length,r=0,i=n-1;i-r>1;){var a=Math.floor((r+i)/2);e[a]>t?i=a:r=a}return t>=e[i]?i:r}}])}(R.PureComponent);fw(_w,`displayName`,`Brush`),fw(_w,`defaultProps`,{height:40,travellerWidth:5,gap:1,fill:`#fff`,stroke:`#666`,padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1});var vw=t(((e,t)=>{var n=is();function r(e,t){var r;return n(e,function(e,n,i){return r=t(e,n,i),!r}),!!r}t.exports=r})),yw=t(((e,t)=>{var n=va(),r=_o(),i=vw(),a=He(),o=vs();function s(e,t,s){var c=a(e)?n:i;return s&&o(e,t,s)&&(t=void 0),c(e,r(t,3))}t.exports=s})),bw=function(e,t){var n=e.alwaysShow,r=e.ifOverflow;return n&&(r=`extendDomain`),r===t},xw=t(((e,t)=>{var n=ps();function r(e,t,r){t==`__proto__`&&n?n(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}t.exports=r})),Sw=t(((e,t)=>{var n=xw(),r=ns(),i=_o();function a(e,t){var a={};return t=i(t,3),r(e,function(e,r,i){n(a,r,t(e,r,i))}),a}t.exports=a})),Cw=t(((e,t)=>{function n(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}t.exports=n})),ww=t(((e,t)=>{var n=is();function r(e,t){var r=!0;return n(e,function(e,n,i){return r=!!t(e,n,i),r}),r}t.exports=r})),Tw=t(((e,t)=>{var n=Cw(),r=ww(),i=_o(),a=He(),o=vs();function s(e,t,s){var c=a(e)?n:r;return s&&o(e,t,s)&&(t=void 0),c(e,i(t,3))}t.exports=s})),Ew=[`x`,`y`];function Dw(e){"@babel/helpers - typeof";return Dw=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Dw(e)}function Ow(){return Ow=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ow.apply(this,arguments)}function kw(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 Aw(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?kw(Object(n),!0).forEach(function(t){jw(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kw(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function jw(e,t,n){return t=Mw(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Mw(e){var t=Nw(e,`string`);return Dw(t)==`symbol`?t:t+``}function Nw(e,t){if(Dw(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Dw(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Pw(e,t){if(e==null)return{};var n=Fw(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Fw(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Iw(e,t){var n=e.x,r=e.y,i=Pw(e,Ew),a=`${n}`,o=parseInt(a,10),s=`${r}`,c=parseInt(s,10),l=`${t.height||i.height}`,u=parseInt(l,10),d=`${t.width||i.width}`,f=parseInt(d,10);return Aw(Aw(Aw(Aw(Aw({},t),i),o?{x:o}:{}),c?{y:c}:{}),{},{height:u,width:f,name:t.name,radius:t.radius})}function Lw(e){return R.createElement(OC,Ow({shapeType:`rectangle`,propTransformer:Iw,activeClassName:`recharts-active-bar`},e))}var Rw=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(n,r){if(typeof e==`number`)return e;var i=I(n)||Qt(n);return i?e(n,r):(!i&&Eg(!1),t)}},zw=[`value`,`background`],Bw;function Vw(e){"@babel/helpers - typeof";return Vw=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Vw(e)}function Hw(e,t){if(e==null)return{};var n=Uw(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Uw(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Ww(){return Ww=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ww.apply(this,arguments)}function Gw(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Y(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Gw(Object(n),!0).forEach(function(t){nT(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Gw(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Kw(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function qw(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,rT(r.key),r)}}function Jw(e,t,n){return t&&qw(e.prototype,t),n&&qw(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Yw(e,t,n){return t=$w(t),Xw(e,Qw()?Reflect.construct(t,n||[],$w(e).constructor):t.apply(e,n))}function Xw(e,t){if(t&&(Vw(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return Zw(e)}function Zw(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function Qw(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Qw=function(){return!!e})()}function $w(e){return $w=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},$w(e)}function eT(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&tT(e,t)}function tT(e,t){return tT=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},tT(e,t)}function nT(e,t,n){return t=rT(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rT(e){var t=iT(e,`string`);return Vw(t)==`symbol`?t:t+``}function iT(e,t){if(Vw(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Vw(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var aT=function(e){function t(){var e;Kw(this,t);var n=[...arguments];return e=Yw(this,t,[].concat(n)),nT(e,`state`,{isAnimationFinished:!1}),nT(e,`id`,en(`recharts-bar-`)),nT(e,`handleAnimationEnd`,function(){var t=e.props.onAnimationEnd;e.setState({isAnimationFinished:!0}),t&&t()}),nT(e,`handleAnimationStart`,function(){var t=e.props.onAnimationStart;e.setState({isAnimationFinished:!1}),t&&t()}),e}return eT(t,e),Jw(t,[{key:`renderRectanglesStatically`,value:function(e){var t=this,n=this.props,r=n.shape,i=n.dataKey,a=n.activeIndex,o=n.activeBar,s=B(this.props,!1);return e&&e.map(function(e,n){var c=n===a,l=c?o:r,u=Y(Y(Y({},s),e),{},{isActive:c,option:l,index:n,dataKey:i,onAnimationStart:t.handleAnimationStart,onAnimationEnd:t.handleAnimationEnd});return R.createElement(V,Ww({className:`recharts-bar-rectangle`},vn(t.props,e,n),{key:`rectangle-${e?.x}-${e?.y}-${e?.value}-${n}`}),R.createElement(Lw,u))})}},{key:`renderRectanglesWithAnimation`,value:function(){var e=this,t=this.props,n=t.data,r=t.layout,i=t.isAnimationActive,a=t.animationBegin,o=t.animationDuration,s=t.animationEasing,c=t.animationId,l=this.state.prevData;return R.createElement(gS,{begin:a,duration:o,isActive:i,easing:s,from:{t:0},to:{t:1},key:`bar-${c}`,onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(t){var i=t.t,a=n.map(function(e,t){var n=l&&l[t];if(n){var a=an(n.x,e.x),o=an(n.y,e.y),s=an(n.width,e.width),c=an(n.height,e.height);return Y(Y({},e),{},{x:a(i),y:o(i),width:s(i),height:c(i)})}if(r===`horizontal`){var u=an(0,e.height)(i);return Y(Y({},e),{},{y:e.y+e.height-u,height:u})}var d=an(0,e.width)(i);return Y(Y({},e),{},{width:d})});return R.createElement(V,null,e.renderRectanglesStatically(a))})}},{key:`renderRectangles`,value:function(){var e=this.props,t=e.data,n=e.isAnimationActive,r=this.state.prevData;return n&&t&&t.length&&(!r||!(0,c_.default)(r,t))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(t)}},{key:`renderBackground`,value:function(){var e=this,t=this.props,n=t.data,r=t.dataKey,i=t.activeIndex,a=B(this.props.background,!1);return n.map(function(t,n){t.value;var o=t.background,s=Hw(t,zw);if(!o)return null;var c=Y(Y(Y(Y(Y({},s),{},{fill:`#eee`},o),a),vn(e.props,t,n)),{},{onAnimationStart:e.handleAnimationStart,onAnimationEnd:e.handleAnimationEnd,dataKey:r,index:n,className:`recharts-bar-background-rectangle`});return R.createElement(Lw,Ww({key:`background-bar-${n}`,option:e.props.background,isActive:n===i},c))})}},{key:`renderErrorBar`,value:function(e,t){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var n=this.props,r=n.data,i=n.xAxis,a=n.yAxis,o=n.layout,s=n.children,c=An(s,Zg);if(!c)return null;var l=o===`vertical`?r[0].height/2:r[0].width/2,u=function(e,t){var n=Array.isArray(e.value)?e.value[1]:e.value;return{x:e.x,y:e.y,value:n,errorVal:b_(e,t)}},d={clipPath:e?`url(#clipPath-${t})`:null};return R.createElement(V,d,c.map(function(e){return R.cloneElement(e,{key:`error-bar-${t}-${e.props.dataKey}`,data:r,xAxis:i,yAxis:a,layout:o,offset:l,dataPointFormatter:u})}))}},{key:`render`,value:function(){var e=this.props,t=e.hide,n=e.data,r=e.className,i=e.xAxis,a=e.yAxis,o=e.left,s=e.top,c=e.width,l=e.height,u=e.isAnimationActive,d=e.background,f=e.id;if(t||!n||!n.length)return null;var p=this.state.isAnimationFinished,m=v(`recharts-bar`,r),h=i&&i.allowDataOverflow,g=a&&a.allowDataOverflow,_=h||g,y=(0,F.default)(f)?this.id:f;return R.createElement(V,{className:m},h||g?R.createElement(`defs`,null,R.createElement(`clipPath`,{id:`clipPath-${y}`},R.createElement(`rect`,{x:h?o:o-c/2,y:g?s:s-l/2,width:h?c:c*2,height:g?l:l*2}))):null,R.createElement(V,{className:`recharts-bar-rectangles`,clipPath:_?`url(#clipPath-${y})`:null},d?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(_,y),(!u||p)&&oy.renderCallByParent(this.props,n))}}],[{key:`getDerivedStateFromProps`,value:function(e,t){return e.animationId===t.prevAnimationId?e.data===t.curData?null:{curData:e.data}:{prevAnimationId:e.animationId,curData:e.data,prevData:t.curData}}}])}(R.PureComponent);Bw=aT,nT(aT,`displayName`,`Bar`),nT(aT,`defaultProps`,{xAxisId:0,yAxisId:0,legendType:`rect`,minPointSize:0,hide:!1,data:[],layout:`vertical`,activeBar:!1,isAnimationActive:!lc.isSsr,animationBegin:0,animationDuration:400,animationEasing:`ease`}),nT(aT,`getComposedData`,function(e){var t=e.props,n=e.item,r=e.barPosition,i=e.bandSize,a=e.xAxis,o=e.yAxis,s=e.xAxisTicks,c=e.yAxisTicks,l=e.stackedData,u=e.dataStartIndex,d=e.displayedData,f=e.offset,p=z_(r,n);if(!p)return null;var m=t.layout,h=n.type.defaultProps,g=h===void 0?n.props:Y(Y({},h),n.props),_=g.dataKey,v=g.children,y=g.minPointSize,b=m===`horizontal`?o:a,x=l?b.scale.domain():null,S=q_({numericAxis:b}),C=An(v,Jc);return Y({data:d.map(function(e,t){var r,d,f,h,g,v;l?r=B_(l[u+t],x):(r=b_(e,_),Array.isArray(r)||(r=[S,r]));var b=Rw(y,Bw.defaultProps.minPointSize)(r[1],t);if(m===`horizontal`){var w=[o.scale(r[0]),o.scale(r[1])],T=w[0],E=w[1];d=K_({axis:a,ticks:s,bandSize:i,offset:p.offset,entry:e,index:t}),f=E??T??void 0,h=p.size;var D=T-E;if(g=Number.isNaN(D)?0:D,v={x:d,y:o.y,width:h,height:o.height},Math.abs(b)>0&&Math.abs(g)<Math.abs(b)){var O=Xt(g||b)*(Math.abs(b)-Math.abs(g));f-=O,g+=O}}else{var k=[a.scale(r[0]),a.scale(r[1])],A=k[0],j=k[1];if(d=A,f=K_({axis:o,ticks:c,bandSize:i,offset:p.offset,entry:e,index:t}),h=j-A,g=p.size,v={x:a.x,y:f,width:a.width,height:g},Math.abs(b)>0&&Math.abs(h)<Math.abs(b)){var M=Xt(h||b)*(Math.abs(b)-Math.abs(h));h+=M}}return Y(Y(Y({},e),{},{x:d,y:f,width:h,height:g,value:l?r:r[1],payload:e,background:v},C&&C[t]&&C[t].props),{},{tooltipPayload:[nv(n,e)],tooltipPosition:{x:d+h/2,y:f+g/2}})}),layout:m},f)});var oT=r(Sw()),sT=r(Tw());function cT(e){"@babel/helpers - typeof";return cT=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},cT(e)}function lT(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function uT(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,hT(r.key),r)}}function dT(e,t,n){return t&&uT(e.prototype,t),n&&uT(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function fT(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 pT(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?fT(Object(n),!0).forEach(function(t){mT(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fT(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function mT(e,t,n){return t=hT(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function hT(e){var t=gT(e,`string`);return cT(t)==`symbol`?t:t+``}function gT(e,t){if(cT(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(cT(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var _T=function(e,t,n,r,i){var a=e.width,o=e.height,s=e.layout,c=e.children,l=Object.keys(t),u={left:n.left,leftMirror:n.left,right:a-n.right,rightMirror:a-n.right,top:n.top,topMirror:n.top,bottom:o-n.bottom,bottomMirror:o-n.bottom},d=!!jn(c,aT);return l.reduce(function(a,o){var c=t[o],l=c.orientation,f=c.domain,p=c.padding,m=p===void 0?{}:p,h=c.mirror,g=c.reversed,_=`${l}${h?`Mirror`:``}`,v,y,b,x,S;if(c.type===`number`&&(c.padding===`gap`||c.padding===`no-gap`)){var C=f[1]-f[0],w=1/0,T=c.categoricalDomain.sort(sn);if(T.forEach(function(e,t){t>0&&(w=Math.min((e||0)-(T[t-1]||0),w))}),Number.isFinite(w)){var E=w/C,D=c.layout===`vertical`?n.height:n.width;if(c.padding===`gap`&&(v=E*D/2),c.padding===`no-gap`){var O=tn(e.barCategoryGap,E*D),k=E*D/2;v=k-O-(k-O)/D*O}}}y=r===`xAxis`?[n.left+(m.left||0)+(v||0),n.left+n.width-(m.right||0)-(v||0)]:r===`yAxis`?s===`horizontal`?[n.top+n.height-(m.bottom||0),n.top+(m.top||0)]:[n.top+(m.top||0)+(v||0),n.top+n.height-(m.bottom||0)-(v||0)]:c.range,g&&(y=[y[1],y[0]]);var A=I_(c,i,d),j=A.scale,M=A.realScaleType;j.domain(f).range(y),R_(j);var N=W_(j,pT(pT({},c),{},{realScaleType:M}));r===`xAxis`?(S=l===`top`&&!h||l===`bottom`&&h,b=n.left,x=u[_]-S*c.height):r===`yAxis`&&(S=l===`left`&&!h||l===`right`&&h,b=u[_]-S*c.width,x=n.top);var ee=pT(pT(pT({},c),N),{},{realScaleType:M,x:b,y:x,scale:j,width:r===`xAxis`?n.width:c.width,height:r===`yAxis`?n.height:c.height});return ee.bandSize=ev(ee,N),!c.hide&&r===`xAxis`?u[_]+=(S?-1:1)*ee.height:c.hide||(u[_]+=(S?-1:1)*ee.width),pT(pT({},a),{},mT({},o,ee))},{})},vT=function(e,t){var n=e.x,r=e.y,i=t.x,a=t.y;return{x:Math.min(n,i),y:Math.min(r,a),width:Math.abs(i-n),height:Math.abs(a-r)}},yT=function(e){var t=e.x1,n=e.y1,r=e.x2,i=e.y2;return vT({x:t,y:n},{x:r,y:i})},bT=function(){function e(t){lT(this,e),this.scale=t}return dT(e,[{key:`domain`,get:function(){return this.scale.domain}},{key:`range`,get:function(){return this.scale.range}},{key:`rangeMin`,get:function(){return this.range()[0]}},{key:`rangeMax`,get:function(){return this.range()[1]}},{key:`bandwidth`,get:function(){return this.scale.bandwidth}},{key:`apply`,value:function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.bandAware,r=t.position;if(e!==void 0){if(r)switch(r){case`start`:return this.scale(e);case`middle`:var i=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+i;case`end`:var a=this.bandwidth?this.bandwidth():0;return this.scale(e)+a;default:return this.scale(e)}if(n){var o=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+o}return this.scale(e)}}},{key:`isInRange`,value:function(e){var t=this.range(),n=t[0],r=t[t.length-1];return n<=r?e>=n&&e<=r:e>=r&&e<=n}}],[{key:`create`,value:function(t){return new e(t)}}])}();mT(bT,`EPS`,1e-4);var xT=function(e){var t=Object.keys(e).reduce(function(t,n){return pT(pT({},t),{},mT({},n,bT.create(e[n])))},{});return pT(pT({},t),{},{apply:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.bandAware,i=n.position;return(0,oT.default)(e,function(e,n){return t[n].apply(e,{bandAware:r,position:i})})},isInRange:function(e){return(0,sT.default)(e,function(e,n){return t[n].isInRange(e)})}})};function ST(e){return(e%180+180)%180}var CT=function(e){var t=e.width,n=e.height,r=ST(arguments.length>1&&arguments[1]!==void 0?arguments[1]:0)*Math.PI/180,i=Math.atan(n/t),a=r>i&&r<Math.PI-i?n/Math.sin(r):t/Math.cos(r);return Math.abs(a)},wT=t(((e,t)=>{var n=_o(),r=Ka(),i=qa();function a(e){return function(t,a,o){var s=Object(t);if(!r(t)){var c=n(a,3);t=i(t),a=function(e){return c(s[e],e,s)}}var l=e(t,a,o);return l>-1?s[c?t[l]:l]:void 0}}t.exports=a})),TT=t(((e,t)=>{var n=BC();function r(e){var t=n(e),r=t%1;return t===t?r?t-r:t:0}t.exports=r})),ET=t(((e,t)=>{var n=vo(),r=_o(),i=TT(),a=Math.max;function o(e,t,o){var s=e==null?0:e.length;if(!s)return-1;var c=o==null?0:i(o);return c<0&&(c=a(s+c,0)),n(e,r(t,3),c)}t.exports=o})),DT=t(((e,t)=>{t.exports=wT()(ET())})),OT=(0,r(At()).default)(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return[`l`,e.left,`t`,e.top,`w`,e.width,`h`,e.height].join(``)}),kT=r(DT()),AT=(0,R.createContext)(void 0),jT=(0,R.createContext)(void 0),MT=(0,R.createContext)(void 0),NT=(0,R.createContext)({}),PT=(0,R.createContext)(void 0),FT=(0,R.createContext)(0),IT=(0,R.createContext)(0),LT=function(e){var t=e.state,n=t.xAxisMap,r=t.yAxisMap,i=t.offset,a=e.clipPathId,o=e.children,s=e.width,c=e.height,l=OT(i);return R.createElement(AT.Provider,{value:n},R.createElement(jT.Provider,{value:r},R.createElement(NT.Provider,{value:i},R.createElement(MT.Provider,{value:l},R.createElement(PT.Provider,{value:a},R.createElement(FT.Provider,{value:c},R.createElement(IT.Provider,{value:s},o)))))))},RT=function(){return(0,R.useContext)(PT)},zT=function(e){var t=(0,R.useContext)(AT);t??Eg(!1);var n=t[e];return n??Eg(!1),n},BT=function(){return nn((0,R.useContext)(AT))},VT=function(){var e=(0,R.useContext)(jT);return(0,kT.default)(e,function(e){return(0,sT.default)(e.domain,Number.isFinite)})||nn(e)},HT=function(e){var t=(0,R.useContext)(jT);t??Eg(!1);var n=t[e];return n??Eg(!1),n},UT=function(){return(0,R.useContext)(MT)},WT=function(){return(0,R.useContext)(NT)},GT=function(){return(0,R.useContext)(IT)},KT=function(){return(0,R.useContext)(FT)},qT=r(yw());function JT(e){"@babel/helpers - typeof";return JT=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},JT(e)}function YT(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function XT(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,cE(r.key),r)}}function ZT(e,t,n){return t&&XT(e.prototype,t),n&&XT(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function QT(e,t,n){return t=nE(t),$T(e,tE()?Reflect.construct(t,n||[],nE(e).constructor):t.apply(e,n))}function $T(e,t){if(t&&(JT(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return eE(e)}function eE(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function tE(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(tE=function(){return!!e})()}function nE(e){return nE=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},nE(e)}function rE(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&iE(e,t)}function iE(e,t){return iE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},iE(e,t)}function aE(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 oE(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?aE(Object(n),!0).forEach(function(t){sE(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):aE(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function sE(e,t,n){return t=cE(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cE(e){var t=lE(e,`string`);return JT(t)==`symbol`?t:t+``}function lE(e,t){if(JT(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(JT(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function uE(e,t){return hE(e)||mE(e,t)||fE(e,t)||dE()}function dE(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
53
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function fE(e,t){if(e){if(typeof e==`string`)return pE(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return pE(e,t)}}function pE(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function mE(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function hE(e){if(Array.isArray(e))return e}function gE(){return gE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},gE.apply(this,arguments)}var _E=function(e,t){return R.isValidElement(e)?R.cloneElement(e,t):(0,z.default)(e)?e(t):R.createElement(`line`,gE({},t,{className:`recharts-reference-line-line`}))},vE=function(e,t,n,r,i,a,o,s,c){var l=i.x,u=i.y,d=i.width,f=i.height;if(n){var p=c.y,m=e.y.apply(p,{position:a});if(bw(c,`discard`)&&!e.y.isInRange(m))return null;var h=[{x:l+d,y:m},{x:l,y:m}];return s===`left`?h.reverse():h}if(t){var g=c.x,_=e.x.apply(g,{position:a});if(bw(c,`discard`)&&!e.x.isInRange(_))return null;var v=[{x:_,y:u+f},{x:_,y:u}];return o===`top`?v.reverse():v}if(r){var y=c.segment.map(function(t){return e.apply(t,{position:a})});return bw(c,`discard`)&&(0,qT.default)(y,function(t){return!e.isInRange(t)})?null:y}return null};function yE(e){var t=e.x,n=e.y,r=e.segment,i=e.xAxisId,a=e.yAxisId,o=e.shape,s=e.className;e.alwaysShow;var c=RT(),l=zT(i),u=HT(a),d=UT();if(!c||!d)return null;var f=vE(xT({x:l.scale,y:u.scale}),L(t),L(n),r&&r.length===2,d,e.position,l.orientation,u.orientation,e);if(!f)return null;var p=uE(f,2),m=p[0],h=m.x,g=m.y,_=p[1],y=_.x,b=_.y,x=oE(oE({clipPath:bw(e,`hidden`)?`url(#${c})`:void 0},B(e,!0)),{},{x1:h,y1:g,x2:y,y2:b});return R.createElement(V,{className:v(`recharts-reference-line`,s)},_E(o,x),Rv.renderCallByParent(e,yT({x1:h,y1:g,x2:y,y2:b})))}var bE=function(e){function t(){return YT(this,t),QT(this,t,arguments)}return rE(t,e),ZT(t,[{key:`render`,value:function(){return R.createElement(yE,this.props)}}])}(R.Component);sE(bE,`displayName`,`ReferenceLine`),sE(bE,`defaultProps`,{isFront:!1,ifOverflow:`discard`,xAxisId:0,yAxisId:0,fill:`none`,stroke:`#ccc`,fillOpacity:1,strokeWidth:1,position:`middle`});function xE(){return xE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},xE.apply(this,arguments)}function SE(e){"@babel/helpers - typeof";return SE=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},SE(e)}function CE(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 wE(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?CE(Object(n),!0).forEach(function(t){FE(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CE(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function TE(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function EE(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,IE(r.key),r)}}function DE(e,t,n){return t&&EE(e.prototype,t),n&&EE(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function OE(e,t,n){return t=ME(t),kE(e,jE()?Reflect.construct(t,n||[],ME(e).constructor):t.apply(e,n))}function kE(e,t){if(t&&(SE(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return AE(e)}function AE(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function jE(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(jE=function(){return!!e})()}function ME(e){return ME=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ME(e)}function NE(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&PE(e,t)}function PE(e,t){return PE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},PE(e,t)}function FE(e,t,n){return t=IE(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function IE(e){var t=LE(e,`string`);return SE(t)==`symbol`?t:t+``}function LE(e,t){if(SE(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(SE(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var RE=function(e){var t=e.x,n=e.y,r=e.xAxis,i=e.yAxis,a=xT({x:r.scale,y:i.scale}),o=a.apply({x:t,y:n},{bandAware:!0});return bw(e,`discard`)&&!a.isInRange(o)?null:o},zE=function(e){function t(){return TE(this,t),OE(this,t,arguments)}return NE(t,e),DE(t,[{key:`render`,value:function(){var e=this.props,n=e.x,r=e.y,i=e.r;e.alwaysShow;var a=e.clipPathId,o=L(n),s=L(r);if(!o||!s)return null;var c=RE(this.props);if(!c)return null;var l=c.x,u=c.y,d=this.props,f=d.shape,p=d.className,m=wE(wE({clipPath:bw(this.props,`hidden`)?`url(#${a})`:void 0},B(this.props,!0)),{},{cx:l,cy:u});return R.createElement(V,{className:v(`recharts-reference-dot`,p)},t.renderDot(f,m),Rv.renderCallByParent(this.props,{x:l-i,y:u-i,width:2*i,height:2*i}))}}])}(R.Component);FE(zE,`displayName`,`ReferenceDot`),FE(zE,`defaultProps`,{isFront:!1,ifOverflow:`discard`,xAxisId:0,yAxisId:0,r:10,fill:`#fff`,stroke:`#ccc`,fillOpacity:1,strokeWidth:1}),FE(zE,`renderDot`,function(e,t){return R.isValidElement(e)?R.cloneElement(e,t):(0,z.default)(e)?e(t):R.createElement(FS,xE({},t,{cx:t.cx,cy:t.cy,className:`recharts-reference-dot-dot`}))});function BE(){return BE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},BE.apply(this,arguments)}function VE(e){"@babel/helpers - typeof";return VE=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},VE(e)}function HE(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function UE(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?HE(Object(n),!0).forEach(function(t){eD(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):HE(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function WE(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function GE(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,tD(r.key),r)}}function KE(e,t,n){return t&&GE(e.prototype,t),n&&GE(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function qE(e,t,n){return t=ZE(t),JE(e,XE()?Reflect.construct(t,n||[],ZE(e).constructor):t.apply(e,n))}function JE(e,t){if(t&&(VE(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return YE(e)}function YE(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function XE(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(XE=function(){return!!e})()}function ZE(e){return ZE=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ZE(e)}function QE(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&$E(e,t)}function $E(e,t){return $E=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},$E(e,t)}function eD(e,t,n){return t=tD(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tD(e){var t=nD(e,`string`);return VE(t)==`symbol`?t:t+``}function nD(e,t){if(VE(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(VE(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var rD=function(e,t,n,r,i){var a=i.x1,o=i.x2,s=i.y1,c=i.y2,l=i.xAxis,u=i.yAxis;if(!l||!u)return null;var d=xT({x:l.scale,y:u.scale}),f={x:e?d.x.apply(a,{position:`start`}):d.x.rangeMin,y:n?d.y.apply(s,{position:`start`}):d.y.rangeMin},p={x:t?d.x.apply(o,{position:`end`}):d.x.rangeMax,y:r?d.y.apply(c,{position:`end`}):d.y.rangeMax};return bw(i,`discard`)&&(!d.isInRange(f)||!d.isInRange(p))?null:vT(f,p)},iD=function(e){function t(){return WE(this,t),qE(this,t,arguments)}return QE(t,e),KE(t,[{key:`render`,value:function(){var e=this.props,n=e.x1,r=e.x2,i=e.y1,a=e.y2,o=e.className;e.alwaysShow;var s=e.clipPathId,c=L(n),l=L(r),u=L(i),d=L(a),f=this.props.shape;if(!c&&!l&&!u&&!d&&!f)return null;var p=rD(c,l,u,d,this.props);if(!p&&!f)return null;var m=bw(this.props,`hidden`)?`url(#${s})`:void 0;return R.createElement(V,{className:v(`recharts-reference-area`,o)},t.renderRect(f,UE(UE({clipPath:m},B(this.props,!0)),p)),Rv.renderCallByParent(this.props,p))}}])}(R.Component);eD(iD,`displayName`,`ReferenceArea`),eD(iD,`defaultProps`,{isFront:!1,ifOverflow:`discard`,xAxisId:0,yAxisId:0,r:10,fill:`#ccc`,fillOpacity:.5,stroke:`none`,strokeWidth:1}),eD(iD,`renderRect`,function(e,t){return R.isValidElement(e)?R.cloneElement(e,t):(0,z.default)(e)?e(t):R.createElement(NS,BE({},t,{className:`recharts-reference-area-rect`}))});function aD(e,t,n){if(t<1)return[];if(t===1&&n===void 0)return e;for(var r=[],i=0;i<e.length;i+=t)if(n===void 0||n(e[i])===!0)r.push(e[i]);else return;return r}function oD(e,t,n){return CT({width:e.width+t.width,height:e.height+t.height},n)}function sD(e,t,n){var r=n===`width`,i=e.x,a=e.y,o=e.width,s=e.height;return t===1?{start:r?i:a,end:r?i+o:a+s}:{start:r?i+o:a+s,end:r?i:a}}function cD(e,t,n,r,i){if(e*t<e*r||e*t>e*i)return!1;var a=n();return e*(t-e*a/2-r)>=0&&e*(t+e*a/2-i)<=0}function lD(e,t){return aD(e,t+1)}function uD(e,t,n,r,i){for(var a=(r||[]).slice(),o=t.start,s=t.end,c=0,l=1,u=o,d=function(){var t=r?.[c];if(t===void 0)return{v:aD(r,l)};var a=c,d,f=function(){return d===void 0&&(d=n(t,a)),d},p=t.coordinate,m=c===0||cD(e,p,f,u,s);m||(c=0,u=o,l+=1),m&&(u=p+e*(f()/2+i),c+=l)},f;l<=a.length;)if(f=d(),f)return f.v;return[]}function dD(e){"@babel/helpers - typeof";return dD=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},dD(e)}function fD(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 pD(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?fD(Object(n),!0).forEach(function(t){mD(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fD(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function mD(e,t,n){return t=hD(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function hD(e){var t=gD(e,`string`);return dD(t)==`symbol`?t:t+``}function gD(e,t){if(dD(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(dD(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function _D(e,t,n,r,i){for(var a=(r||[]).slice(),o=a.length,s=t.start,c=t.end,l=function(t){var r=a[t],l,u=function(){return l===void 0&&(l=n(r,t)),l};if(t===o-1){var d=e*(r.coordinate+e*u()/2-c);a[t]=r=pD(pD({},r),{},{tickCoord:d>0?r.coordinate-d*e:r.coordinate})}else a[t]=r=pD(pD({},r),{},{tickCoord:r.coordinate});cD(e,r.tickCoord,u,s,c)&&(c=r.tickCoord-e*(u()/2+i),a[t]=pD(pD({},r),{},{isShow:!0}))},u=o-1;u>=0;u--)l(u);return a}function vD(e,t,n,r,i,a){var o=(r||[]).slice(),s=o.length,c=t.start,l=t.end;if(a){var u=r[s-1],d=n(u,s-1),f=e*(u.coordinate+e*d/2-l);o[s-1]=u=pD(pD({},u),{},{tickCoord:f>0?u.coordinate-f*e:u.coordinate}),cD(e,u.tickCoord,function(){return d},c,l)&&(l=u.tickCoord-e*(d/2+i),o[s-1]=pD(pD({},u),{},{isShow:!0}))}for(var p=a?s-1:s,m=function(t){var r=o[t],a,s=function(){return a===void 0&&(a=n(r,t)),a};if(t===0){var u=e*(r.coordinate-e*s()/2-c);o[t]=r=pD(pD({},r),{},{tickCoord:u<0?r.coordinate-u*e:r.coordinate})}else o[t]=r=pD(pD({},r),{},{tickCoord:r.coordinate});cD(e,r.tickCoord,s,c,l)&&(c=r.tickCoord+e*(s()/2+i),o[t]=pD(pD({},r),{},{isShow:!0}))},h=0;h<p;h++)m(h);return o}function yD(e,t,n){var r=e.tick,i=e.ticks,a=e.viewBox,o=e.minTickGap,s=e.orientation,c=e.interval,l=e.tickFormatter,u=e.unit,d=e.angle;if(!i||!i.length||!r)return[];if(I(c)||lc.isSsr)return lD(i,typeof c==`number`&&I(c)?c:0);var f=[],p=s===`top`||s===`bottom`?`width`:`height`,m=u&&p===`width`?ol(u,{fontSize:t,letterSpacing:n}):{width:0,height:0},h=function(e,r){var i=(0,z.default)(l)?l(e.value,r):e.value;return p===`width`?oD(ol(i,{fontSize:t,letterSpacing:n}),m,d):ol(i,{fontSize:t,letterSpacing:n})[p]},g=i.length>=2?Xt(i[1].coordinate-i[0].coordinate):1,_=sD(a,g,p);return c===`equidistantPreserveStart`?uD(g,_,h,i,o):(f=c===`preserveStart`||c===`preserveStartEnd`?vD(g,_,h,i,o,c===`preserveStartEnd`):_D(g,_,h,i,o),f.filter(function(e){return e.isShow}))}var bD=[`viewBox`],xD=[`viewBox`],SD=[`ticks`];function CD(e){"@babel/helpers - typeof";return CD=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},CD(e)}function wD(){return wD=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wD.apply(this,arguments)}function TD(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function X(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?TD(Object(n),!0).forEach(function(t){RD(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):TD(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ED(e,t){if(e==null)return{};var n=DD(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function DD(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function OD(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function kD(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,zD(r.key),r)}}function AD(e,t,n){return t&&kD(e.prototype,t),n&&kD(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function jD(e,t,n){return t=FD(t),MD(e,PD()?Reflect.construct(t,n||[],FD(e).constructor):t.apply(e,n))}function MD(e,t){if(t&&(CD(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return ND(e)}function ND(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function PD(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(PD=function(){return!!e})()}function FD(e){return FD=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},FD(e)}function ID(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&LD(e,t)}function LD(e,t){return LD=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},LD(e,t)}function RD(e,t,n){return t=zD(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zD(e){var t=BD(e,`string`);return CD(t)==`symbol`?t:t+``}function BD(e,t){if(CD(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(CD(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var VD=function(e){function t(e){var n;return OD(this,t),n=jD(this,t,[e]),n.state={fontSize:``,letterSpacing:``},n}return ID(t,e),AD(t,[{key:`shouldComponentUpdate`,value:function(e,t){var n=e.viewBox,r=ED(e,bD),i=this.props,a=i.viewBox,o=ED(i,xD);return!cn(n,a)||!cn(r,o)||!cn(t,this.state)}},{key:`componentDidMount`,value:function(){var e=this.layerReference;if(e){var t=e.getElementsByClassName(`recharts-cartesian-axis-tick-value`)[0];t&&this.setState({fontSize:window.getComputedStyle(t).fontSize,letterSpacing:window.getComputedStyle(t).letterSpacing})}}},{key:`getTickLineCoord`,value:function(e){var t=this.props,n=t.x,r=t.y,i=t.width,a=t.height,o=t.orientation,s=t.tickSize,c=t.mirror,l=t.tickMargin,u,d,f,p,m,h,g=c?-1:1,_=e.tickSize||s,v=I(e.tickCoord)?e.tickCoord:e.coordinate;switch(o){case`top`:u=d=e.coordinate,p=r+ +!c*a,f=p-g*_,h=f-g*l,m=v;break;case`left`:f=p=e.coordinate,d=n+ +!c*i,u=d-g*_,m=u-g*l,h=v;break;case`right`:f=p=e.coordinate,d=n+ +c*i,u=d+g*_,m=u+g*l,h=v;break;default:u=d=e.coordinate,p=r+ +c*a,f=p+g*_,h=f+g*l,m=v}return{line:{x1:u,y1:f,x2:d,y2:p},tick:{x:m,y:h}}}},{key:`getTickTextAnchor`,value:function(){var e=this.props,t=e.orientation,n=e.mirror,r;switch(t){case`left`:r=n?`start`:`end`;break;case`right`:r=n?`end`:`start`;break;default:r=`middle`}return r}},{key:`getTickVerticalAnchor`,value:function(){var e=this.props,t=e.orientation,n=e.mirror,r=`end`;switch(t){case`left`:case`right`:r=`middle`;break;case`top`:r=n?`start`:`end`;break;default:r=n?`end`:`start`}return r}},{key:`renderAxisLine`,value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,i=e.height,a=e.orientation,o=e.mirror,s=e.axisLine,c=X(X(X({},B(this.props,!1)),B(s,!1)),{},{fill:`none`});if(a===`top`||a===`bottom`){var l=+(a===`top`&&!o||a===`bottom`&&o);c=X(X({},c),{},{x1:t,y1:n+l*i,x2:t+r,y2:n+l*i})}else{var u=+(a===`left`&&!o||a===`right`&&o);c=X(X({},c),{},{x1:t+u*r,y1:n,x2:t+u*r,y2:n+i})}return R.createElement(`line`,wD({},c,{className:v(`recharts-cartesian-axis-line`,(0,Jt.default)(s,`className`))}))}},{key:`renderTicks`,value:function(e,n,r){var i=this,a=this.props,o=a.tickLine,s=a.stroke,c=a.tick,l=a.tickFormatter,u=a.unit,d=yD(X(X({},this.props),{},{ticks:e}),n,r),f=this.getTickTextAnchor(),p=this.getTickVerticalAnchor(),m=B(this.props,!1),h=B(c,!1),g=X(X({},m),{},{fill:`none`},B(o,!1)),_=d.map(function(e,n){var r=i.getTickLineCoord(e),a=r.line,_=r.tick,y=X(X(X(X({textAnchor:f,verticalAnchor:p},m),{},{stroke:`none`,fill:s},h),_),{},{index:n,payload:e,visibleTicksCount:d.length,tickFormatter:l});return R.createElement(V,wD({className:`recharts-cartesian-axis-tick`,key:`tick-${e.value}-${e.coordinate}-${e.tickCoord}`},vn(i.props,e,n)),o&&R.createElement(`line`,wD({},g,a,{className:v(`recharts-cartesian-axis-tick-line`,(0,Jt.default)(o,`className`))})),c&&t.renderTickItem(c,y,`${(0,z.default)(l)?l(e.value,n):e.value}${u||``}`))});return R.createElement(`g`,{className:`recharts-cartesian-axis-ticks`},_)}},{key:`render`,value:function(){var e=this,t=this.props,n=t.axisLine,r=t.width,i=t.height,a=t.ticksGenerator,o=t.className;if(t.hide)return null;var s=this.props,c=s.ticks,l=ED(s,SD),u=c;return(0,z.default)(a)&&(u=c&&c.length>0?a(this.props):a(l)),r<=0||i<=0||!u||!u.length?null:R.createElement(V,{className:v(`recharts-cartesian-axis`,o),ref:function(t){e.layerReference=t}},n&&this.renderAxisLine(),this.renderTicks(u,this.state.fontSize,this.state.letterSpacing),Rv.renderCallByParent(this.props))}}],[{key:`renderTickItem`,value:function(e,t,n){var r,i=v(t.className,`recharts-cartesian-axis-tick-value`);return r=R.isValidElement(e)?R.cloneElement(e,X(X({},t),{},{className:i})):(0,z.default)(e)?e(X(X({},t),{},{className:i})):R.createElement(Ql,wD({},t,{className:`recharts-cartesian-axis-tick-value`}),n),r}}])}(R.Component);RD(VD,`displayName`,`CartesianAxis`),RD(VD,`defaultProps`,{x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:`bottom`,ticks:[],stroke:`#666`,tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:`preserveEnd`});var HD=[`x1`,`y1`,`x2`,`y2`,`key`],UD=[`offset`];function WD(e){"@babel/helpers - typeof";return WD=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},WD(e)}function GD(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 KD(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?GD(Object(n),!0).forEach(function(t){qD(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):GD(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function qD(e,t,n){return t=JD(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function JD(e){var t=YD(e,`string`);return WD(t)==`symbol`?t:t+``}function YD(e,t){if(WD(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(WD(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function XD(){return XD=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},XD.apply(this,arguments)}function ZD(e,t){if(e==null)return{};var n=QD(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function QD(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var $D=function(e){var t=e.fill;if(!t||t===`none`)return null;var n=e.fillOpacity,r=e.x,i=e.y,a=e.width,o=e.height,s=e.ry;return R.createElement(`rect`,{x:r,y:i,ry:s,width:a,height:o,stroke:`none`,fill:t,fillOpacity:n,className:`recharts-cartesian-grid-bg`})};function eO(e,t){var n;if(R.isValidElement(e))n=R.cloneElement(e,t);else if((0,z.default)(e))n=e(t);else{var r=t.x1,i=t.y1,a=t.x2,o=t.y2,s=t.key,c=B(ZD(t,HD),!1);c.offset;var l=ZD(c,UD);n=R.createElement(`line`,XD({},l,{x1:r,y1:i,x2:a,y2:o,fill:`none`,key:s}))}return n}function tO(e){var t=e.x,n=e.width,r=e.horizontal,i=r===void 0||r,a=e.horizontalPoints;if(!i||!a||!a.length)return null;var o=a.map(function(r,a){return eO(i,KD(KD({},e),{},{x1:t,y1:r,x2:t+n,y2:r,key:`line-${a}`,index:a}))});return R.createElement(`g`,{className:`recharts-cartesian-grid-horizontal`},o)}function nO(e){var t=e.y,n=e.height,r=e.vertical,i=r===void 0||r,a=e.verticalPoints;if(!i||!a||!a.length)return null;var o=a.map(function(r,a){return eO(i,KD(KD({},e),{},{x1:r,y1:t,x2:r,y2:t+n,key:`line-${a}`,index:a}))});return R.createElement(`g`,{className:`recharts-cartesian-grid-vertical`},o)}function rO(e){var t=e.horizontalFill,n=e.fillOpacity,r=e.x,i=e.y,a=e.width,o=e.height,s=e.horizontalPoints,c=e.horizontal;if(!(c===void 0||c)||!t||!t.length)return null;var l=s.map(function(e){return Math.round(e+i-i)}).sort(function(e,t){return e-t});i!==l[0]&&l.unshift(0);var u=l.map(function(e,s){var c=l[s+1]?l[s+1]-e:i+o-e;if(c<=0)return null;var u=s%t.length;return R.createElement(`rect`,{key:`react-${s}`,y:e,x:r,height:c,width:a,stroke:`none`,fill:t[u],fillOpacity:n,className:`recharts-cartesian-grid-bg`})});return R.createElement(`g`,{className:`recharts-cartesian-gridstripes-horizontal`},u)}function iO(e){var t=e.vertical,n=t===void 0||t,r=e.verticalFill,i=e.fillOpacity,a=e.x,o=e.y,s=e.width,c=e.height,l=e.verticalPoints;if(!n||!r||!r.length)return null;var u=l.map(function(e){return Math.round(e+a-a)}).sort(function(e,t){return e-t});a!==u[0]&&u.unshift(0);var d=u.map(function(e,t){var n=u[t+1]?u[t+1]-e:a+s-e;if(n<=0)return null;var l=t%r.length;return R.createElement(`rect`,{key:`react-${t}`,x:e,y:o,width:n,height:c,stroke:`none`,fill:r[l],fillOpacity:i,className:`recharts-cartesian-grid-bg`})});return R.createElement(`g`,{className:`recharts-cartesian-gridstripes-vertical`},d)}var aO=function(e,t){var n=e.xAxis,r=e.width,i=e.height,a=e.offset;return M_(yD(KD(KD(KD({},VD.defaultProps),n),{},{ticks:N_(n,!0),viewBox:{x:0,y:0,width:r,height:i}})),a.left,a.left+a.width,t)},oO=function(e,t){var n=e.yAxis,r=e.width,i=e.height,a=e.offset;return M_(yD(KD(KD(KD({},VD.defaultProps),n),{},{ticks:N_(n,!0),viewBox:{x:0,y:0,width:r,height:i}})),a.top,a.top+a.height,t)},sO={horizontal:!0,vertical:!0,horizontalPoints:[],verticalPoints:[],stroke:`#ccc`,fill:`none`,verticalFill:[],horizontalFill:[]};function cO(e){var t=GT(),n=KT(),r=WT(),i=KD(KD({},e),{},{stroke:e.stroke??sO.stroke,fill:e.fill??sO.fill,horizontal:e.horizontal??sO.horizontal,horizontalFill:e.horizontalFill??sO.horizontalFill,vertical:e.vertical??sO.vertical,verticalFill:e.verticalFill??sO.verticalFill,x:I(e.x)?e.x:r.left,y:I(e.y)?e.y:r.top,width:I(e.width)?e.width:r.width,height:I(e.height)?e.height:r.height}),a=i.x,o=i.y,s=i.width,c=i.height,l=i.syncWithTicks,u=i.horizontalValues,d=i.verticalValues,f=BT(),p=VT();if(!I(s)||s<=0||!I(c)||c<=0||!I(a)||a!==+a||!I(o)||o!==+o)return null;var m=i.verticalCoordinatesGenerator||aO,h=i.horizontalCoordinatesGenerator||oO,g=i.horizontalPoints,_=i.verticalPoints;if((!g||!g.length)&&(0,z.default)(h)){var v=u&&u.length,y=h({yAxis:p?KD(KD({},p),{},{ticks:v?u:p.ticks}):void 0,width:t,height:n,offset:r},v?!0:l);`${WD(y)}`,Array.isArray(y)&&(g=y)}if((!_||!_.length)&&(0,z.default)(m)){var b=d&&d.length,x=m({xAxis:f?KD(KD({},f),{},{ticks:b?d:f.ticks}):void 0,width:t,height:n,offset:r},b?!0:l);`${WD(x)}`,Array.isArray(x)&&(_=x)}return R.createElement(`g`,{className:`recharts-cartesian-grid`},R.createElement($D,{fill:i.fill,fillOpacity:i.fillOpacity,x:i.x,y:i.y,width:i.width,height:i.height,ry:i.ry}),R.createElement(tO,XD({},i,{offset:r,horizontalPoints:g,xAxis:f,yAxis:p})),R.createElement(nO,XD({},i,{offset:r,verticalPoints:_,xAxis:f,yAxis:p})),R.createElement(rO,XD({},i,{horizontalPoints:g})),R.createElement(iO,XD({},i,{verticalPoints:_})))}cO.displayName=`CartesianGrid`;var lO=[`layout`,`type`,`stroke`,`connectNulls`,`isRange`,`ref`],uO=[`key`],dO;function fO(e){"@babel/helpers - typeof";return fO=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},fO(e)}function pO(e,t){if(e==null)return{};var n=mO(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function mO(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function hO(){return hO=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hO.apply(this,arguments)}function gO(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 _O(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?gO(Object(n),!0).forEach(function(t){OO(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gO(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function vO(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function yO(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,kO(r.key),r)}}function bO(e,t,n){return t&&yO(e.prototype,t),n&&yO(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function xO(e,t,n){return t=TO(t),SO(e,wO()?Reflect.construct(t,n||[],TO(e).constructor):t.apply(e,n))}function SO(e,t){if(t&&(fO(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return CO(e)}function CO(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function wO(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(wO=function(){return!!e})()}function TO(e){return TO=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},TO(e)}function EO(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&DO(e,t)}function DO(e,t){return DO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},DO(e,t)}function OO(e,t,n){return t=kO(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kO(e){var t=AO(e,`string`);return fO(t)==`symbol`?t:t+``}function AO(e,t){if(fO(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(fO(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var jO=function(e){function t(){var e;vO(this,t);var n=[...arguments];return e=xO(this,t,[].concat(n)),OO(e,`state`,{isAnimationFinished:!0}),OO(e,`id`,en(`recharts-area-`)),OO(e,`handleAnimationEnd`,function(){var t=e.props.onAnimationEnd;e.setState({isAnimationFinished:!0}),(0,z.default)(t)&&t()}),OO(e,`handleAnimationStart`,function(){var t=e.props.onAnimationStart;e.setState({isAnimationFinished:!1}),(0,z.default)(t)&&t()}),e}return EO(t,e),bO(t,[{key:`renderDots`,value:function(e,n,r){var i=this.props.isAnimationActive,a=this.state.isAnimationFinished;if(i&&!a)return null;var o=this.props,s=o.dot,c=o.points,l=o.dataKey,u=B(this.props,!1),d=B(s,!0),f=c.map(function(e,n){var r=_O(_O(_O({key:`dot-${n}`,r:3},u),d),{},{index:n,cx:e.x,cy:e.y,dataKey:l,value:e.value,payload:e.payload,points:c});return t.renderDotItem(s,r)}),p={clipPath:e?`url(#clipPath-${n?``:`dots-`}${r})`:null};return R.createElement(V,hO({className:`recharts-area-dots`},p),f)}},{key:`renderHorizontalRect`,value:function(e){var t=this.props,n=t.baseLine,r=t.points,i=t.strokeWidth,a=r[0].x,o=r[r.length-1].x,s=e*Math.abs(a-o),c=(0,a_.default)(r.map(function(e){return e.y||0}));return I(n)&&typeof n==`number`?c=Math.max(n,c):n&&Array.isArray(n)&&n.length&&(c=Math.max((0,a_.default)(n.map(function(e){return e.y||0})),c)),I(c)?R.createElement(`rect`,{x:a<o?a:a-s,y:0,width:s,height:Math.floor(c+(i?parseInt(`${i}`,10):1))}):null}},{key:`renderVerticalRect`,value:function(e){var t=this.props,n=t.baseLine,r=t.points,i=t.strokeWidth,a=r[0].y,o=r[r.length-1].y,s=e*Math.abs(a-o),c=(0,a_.default)(r.map(function(e){return e.x||0}));return I(n)&&typeof n==`number`?c=Math.max(n,c):n&&Array.isArray(n)&&n.length&&(c=Math.max((0,a_.default)(n.map(function(e){return e.x||0})),c)),I(c)?R.createElement(`rect`,{x:0,y:a<o?a:a-s,width:c+(i?parseInt(`${i}`,10):1),height:Math.floor(s)}):null}},{key:`renderClipRect`,value:function(e){return this.props.layout===`vertical`?this.renderVerticalRect(e):this.renderHorizontalRect(e)}},{key:`renderAreaStatically`,value:function(e,t,n,r){var i=this.props,a=i.layout,o=i.type,s=i.stroke,c=i.connectNulls,l=i.isRange;i.ref;var u=pO(i,lO);return R.createElement(V,{clipPath:n?`url(#clipPath-${r})`:null},R.createElement(Fy,hO({},B(u,!0),{points:e,connectNulls:c,type:o,baseLine:t,layout:a,stroke:`none`,className:`recharts-area-area`})),s!==`none`&&R.createElement(Fy,hO({},B(this.props,!1),{className:`recharts-area-curve`,layout:a,type:o,connectNulls:c,fill:`none`,points:e})),s!==`none`&&l&&R.createElement(Fy,hO({},B(this.props,!1),{className:`recharts-area-curve`,layout:a,type:o,connectNulls:c,fill:`none`,points:t})))}},{key:`renderAreaWithAnimation`,value:function(e,t){var n=this,r=this.props,i=r.points,a=r.baseLine,o=r.isAnimationActive,s=r.animationBegin,c=r.animationDuration,l=r.animationEasing,u=r.animationId,d=this.state,f=d.prevPoints,p=d.prevBaseLine;return R.createElement(gS,{begin:s,duration:c,isActive:o,easing:l,from:{t:0},to:{t:1},key:`area-${u}`,onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(r){var o=r.t;if(f){var s=f.length/i.length,c=i.map(function(e,t){var n=Math.floor(t*s);if(f[n]){var r=f[n],i=an(r.x,e.x),a=an(r.y,e.y);return _O(_O({},e),{},{x:i(o),y:a(o)})}return e}),l=I(a)&&typeof a==`number`?an(p,a)(o):(0,F.default)(a)||(0,qt.default)(a)?an(p,0)(o):a.map(function(e,t){var n=Math.floor(t*s);if(p[n]){var r=p[n],i=an(r.x,e.x),a=an(r.y,e.y);return _O(_O({},e),{},{x:i(o),y:a(o)})}return e});return n.renderAreaStatically(c,l,e,t)}return R.createElement(V,null,R.createElement(`defs`,null,R.createElement(`clipPath`,{id:`animationClipPath-${t}`},n.renderClipRect(o))),R.createElement(V,{clipPath:`url(#animationClipPath-${t})`},n.renderAreaStatically(i,a,e,t)))})}},{key:`renderArea`,value:function(e,t){var n=this.props,r=n.points,i=n.baseLine,a=n.isAnimationActive,o=this.state,s=o.prevPoints,c=o.prevBaseLine,l=o.totalLength;return a&&r&&r.length&&(!s&&l>0||!(0,c_.default)(s,r)||!(0,c_.default)(c,i))?this.renderAreaWithAnimation(e,t):this.renderAreaStatically(r,i,e,t)}},{key:`render`,value:function(){var e=this.props,t=e.hide,n=e.dot,r=e.points,i=e.className,a=e.top,o=e.left,s=e.xAxis,c=e.yAxis,l=e.width,u=e.height,d=e.isAnimationActive,f=e.id;if(t||!r||!r.length)return null;var p=this.state.isAnimationFinished,m=r.length===1,h=v(`recharts-area`,i),g=s&&s.allowDataOverflow,_=c&&c.allowDataOverflow,y=g||_,b=(0,F.default)(f)?this.id:f,x=B(n,!1)??{r:3,strokeWidth:2},S=x.r,C=S===void 0?3:S,w=x.strokeWidth,T=w===void 0?2:w,E=(Fn(n)?n:{}).clipDot,D=E===void 0||E,O=C*2+T;return R.createElement(V,{className:h},g||_?R.createElement(`defs`,null,R.createElement(`clipPath`,{id:`clipPath-${b}`},R.createElement(`rect`,{x:g?o:o-l/2,y:_?a:a-u/2,width:g?l:l*2,height:_?u:u*2})),!D&&R.createElement(`clipPath`,{id:`clipPath-dots-${b}`},R.createElement(`rect`,{x:o-O/2,y:a-O/2,width:l+O,height:u+O}))):null,m?null:this.renderArea(y,b),(n||m)&&this.renderDots(y,D,b),(!d||p)&&oy.renderCallByParent(this.props,r))}}],[{key:`getDerivedStateFromProps`,value:function(e,t){return e.animationId===t.prevAnimationId?e.points!==t.curPoints||e.baseLine!==t.curBaseLine?{curPoints:e.points,curBaseLine:e.baseLine}:null:{prevAnimationId:e.animationId,curPoints:e.points,curBaseLine:e.baseLine,prevPoints:t.curPoints,prevBaseLine:t.curBaseLine}}}])}(R.PureComponent);dO=jO,OO(jO,`displayName`,`Area`),OO(jO,`defaultProps`,{stroke:`#3182bd`,fill:`#3182bd`,fillOpacity:.6,xAxisId:0,yAxisId:0,legendType:`line`,connectNulls:!1,points:[],dot:!1,activeDot:!0,hide:!1,isAnimationActive:!lc.isSsr,animationBegin:0,animationDuration:1500,animationEasing:`ease`}),OO(jO,`getBaseValue`,function(e,t,n,r){var i=e.layout,a=e.baseValue,o=t.props.baseValue??a;if(I(o)&&typeof o==`number`)return o;var s=i===`horizontal`?r:n,c=s.scale.domain();if(s.type===`number`){var l=Math.max(c[0],c[1]),u=Math.min(c[0],c[1]);return o===`dataMin`?u:o===`dataMax`||l<0?l:Math.max(Math.min(c[0],c[1]),0)}return o===`dataMin`?c[0]:o===`dataMax`?c[1]:c[0]}),OO(jO,`getComposedData`,function(e){var t=e.props,n=e.item,r=e.xAxis,i=e.yAxis,a=e.xAxisTicks,o=e.yAxisTicks,s=e.bandSize,c=e.dataKey,l=e.stackedData,u=e.dataStartIndex,d=e.displayedData,f=e.offset,p=t.layout,m=l&&l.length,h=dO.getBaseValue(t,n,r,i),g=p===`horizontal`,_=!1,v=d.map(function(e,t){var n;m?n=l[u+t]:(n=b_(e,c),Array.isArray(n)?_=!0:n=[h,n]);var d=n[1]==null||m&&b_(e,c)==null;return g?{x:G_({axis:r,ticks:a,bandSize:s,entry:e,index:t}),y:d?null:i.scale(n[1]),value:n,payload:e}:{x:d?null:r.scale(n[1]),y:G_({axis:i,ticks:o,bandSize:s,entry:e,index:t}),value:n,payload:e}});return _O({points:v,baseLine:m||_?v.map(function(e){var t=Array.isArray(e.value)?e.value[0]:null;return g?{x:e.x,y:t!=null&&e.y!=null?i.scale(t):null}:{x:t==null?null:r.scale(t),y:e.y}}):g?i.scale(h):r.scale(h),layout:p,isRange:_},f)}),OO(jO,`renderDotItem`,function(e,t){var n;if(R.isValidElement(e))n=R.cloneElement(e,t);else if((0,z.default)(e))n=e(t);else{var r=v(`recharts-area-dot`,typeof e==`boolean`?``:e.className),i=t.key,a=pO(t,uO);n=R.createElement(FS,hO({},a,{key:i,className:r}))}return n});function MO(e){"@babel/helpers - typeof";return MO=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},MO(e)}function NO(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function PO(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,WO(r.key),r)}}function FO(e,t,n){return t&&PO(e.prototype,t),n&&PO(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function IO(e,t,n){return t=BO(t),LO(e,zO()?Reflect.construct(t,n||[],BO(e).constructor):t.apply(e,n))}function LO(e,t){if(t&&(MO(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return RO(e)}function RO(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function zO(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(zO=function(){return!!e})()}function BO(e){return BO=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},BO(e)}function VO(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&HO(e,t)}function HO(e,t){return HO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},HO(e,t)}function UO(e,t,n){return t=WO(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function WO(e){var t=GO(e,`string`);return MO(t)==`symbol`?t:t+``}function GO(e,t){if(MO(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(MO(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function KO(){return KO=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},KO.apply(this,arguments)}function qO(e){var t=e.xAxisId,n=GT(),r=KT(),i=zT(t);return i==null?null:R.createElement(VD,KO({},i,{className:v(`recharts-${i.axisType} ${i.axisType}`,i.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(e){return N_(e,!0)}}))}var JO=function(e){function t(){return NO(this,t),IO(this,t,arguments)}return VO(t,e),FO(t,[{key:`render`,value:function(){return R.createElement(qO,this.props)}}])}(R.Component);UO(JO,`displayName`,`XAxis`),UO(JO,`defaultProps`,{allowDecimals:!0,hide:!1,orientation:`bottom`,width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:`category`,padding:{left:0,right:0},allowDataOverflow:!1,scale:`auto`,reversed:!1,allowDuplicatedCategory:!0});function YO(e){"@babel/helpers - typeof";return YO=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},YO(e)}function XO(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function ZO(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,sk(r.key),r)}}function QO(e,t,n){return t&&ZO(e.prototype,t),n&&ZO(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function $O(e,t,n){return t=rk(t),ek(e,nk()?Reflect.construct(t,n||[],rk(e).constructor):t.apply(e,n))}function ek(e,t){if(t&&(YO(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return tk(e)}function tk(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function nk(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(nk=function(){return!!e})()}function rk(e){return rk=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},rk(e)}function ik(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ak(e,t)}function ak(e,t){return ak=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},ak(e,t)}function ok(e,t,n){return t=sk(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function sk(e){var t=ck(e,`string`);return YO(t)==`symbol`?t:t+``}function ck(e,t){if(YO(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(YO(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function lk(){return lk=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},lk.apply(this,arguments)}var uk=function(e){var t=e.yAxisId,n=GT(),r=KT(),i=HT(t);return i==null?null:R.createElement(VD,lk({},i,{className:v(`recharts-${i.axisType} ${i.axisType}`,i.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(e){return N_(e,!0)}}))},dk=function(e){function t(){return XO(this,t),$O(this,t,arguments)}return ik(t,e),QO(t,[{key:`render`,value:function(){return R.createElement(uk,this.props)}}])}(R.Component);ok(dk,`displayName`,`YAxis`),ok(dk,`defaultProps`,{allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:`left`,width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:`number`,padding:{top:0,bottom:0},allowDataOverflow:!1,scale:`auto`,reversed:!1});function fk(e){return gk(e)||hk(e)||mk(e)||pk()}function pk(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
54
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function mk(e,t){if(e){if(typeof e==`string`)return _k(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _k(e,t)}}function hk(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function gk(e){if(Array.isArray(e))return _k(e)}function _k(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var vk=function(e,t,n,r,i){var a=An(e,bE),o=An(e,zE),s=[].concat(fk(a),fk(o)),c=An(e,iD),l=`${r}Id`,u=r[0],d=t;if(s.length&&(d=s.reduce(function(e,t){if(t.props[l]===n&&bw(t.props,`extendDomain`)&&I(t.props[u])){var r=t.props[u];return[Math.min(e[0],r),Math.max(e[1],r)]}return e},d)),c.length){var f=`${u}1`,p=`${u}2`;d=c.reduce(function(e,t){if(t.props[l]===n&&bw(t.props,`extendDomain`)&&I(t.props[f])&&I(t.props[p])){var r=t.props[f],i=t.props[p];return[Math.min(e[0],r,i),Math.max(e[1],r,i)]}return e},d)}return i&&i.length&&(d=i.reduce(function(e,t){return I(t)?[Math.min(e[0],t),Math.max(e[1],t)]:e},d)),d},yk=new(r(t(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=`~`;function i(){}Object.create&&(i.prototype=Object.create(null),new i().__proto__||(r=!1));function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function o(e,t,n,i,o){if(typeof n!=`function`)throw TypeError(`The listener must be a function`);var s=new a(n,i||e,o),c=r?r+t:t;return e._events[c]?e._events[c].fn?e._events[c]=[e._events[c],s]:e._events[c].push(s):(e._events[c]=s,e._eventsCount++),e}function s(e,t){--e._eventsCount===0?e._events=new i:delete e._events[t]}function c(){this._events=new i,this._eventsCount=0}c.prototype.eventNames=function(){var e=[],t,i;if(this._eventsCount===0)return e;for(i in t=this._events)n.call(t,i)&&e.push(r?i.slice(1):i);return Object.getOwnPropertySymbols?e.concat(Object.getOwnPropertySymbols(t)):e},c.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,a=n.length,o=Array(a);i<a;i++)o[i]=n[i].fn;return o},c.prototype.listenerCount=function(e){var t=r?r+e:e,n=this._events[t];return n?n.fn?1:n.length:0},c.prototype.emit=function(e,t,n,i,a,o){var s=r?r+e:e;if(!this._events[s])return!1;var c=this._events[s],l=arguments.length,u,d;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),l){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,i),!0;case 5:return c.fn.call(c.context,t,n,i,a),!0;case 6:return c.fn.call(c.context,t,n,i,a,o),!0}for(d=1,u=Array(l-1);d<l;d++)u[d-1]=arguments[d];c.fn.apply(c.context,u)}else{var f=c.length,p;for(d=0;d<f;d++)switch(c[d].once&&this.removeListener(e,c[d].fn,void 0,!0),l){case 1:c[d].fn.call(c[d].context);break;case 2:c[d].fn.call(c[d].context,t);break;case 3:c[d].fn.call(c[d].context,t,n);break;case 4:c[d].fn.call(c[d].context,t,n,i);break;default:if(!u)for(p=1,u=Array(l-1);p<l;p++)u[p-1]=arguments[p];c[d].fn.apply(c[d].context,u)}}return!0},c.prototype.on=function(e,t,n){return o(this,e,t,n,!1)},c.prototype.once=function(e,t,n){return o(this,e,t,n,!0)},c.prototype.removeListener=function(e,t,n,i){var a=r?r+e:e;if(!this._events[a])return this;if(!t)return s(this,a),this;var o=this._events[a];if(o.fn)o.fn===t&&(!i||o.once)&&(!n||o.context===n)&&s(this,a);else{for(var c=0,l=[],u=o.length;c<u;c++)(o[c].fn!==t||i&&!o[c].once||n&&o[c].context!==n)&&l.push(o[c]);l.length?this._events[a]=l.length===1?l[0]:l:s(this,a)}return this},c.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&s(this,t)):(this._events=new i,this._eventsCount=0),this},c.prototype.off=c.prototype.removeListener,c.prototype.addListener=c.prototype.on,c.prefixed=r,c.EventEmitter=c,t!==void 0&&(t.exports=c)}))())).default,bk=`recharts.syncMouseEvents`;function xk(e){"@babel/helpers - typeof";return xk=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},xk(e)}function Sk(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function Ck(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,Ek(r.key),r)}}function wk(e,t,n){return t&&Ck(e.prototype,t),n&&Ck(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Tk(e,t,n){return t=Ek(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ek(e){var t=Dk(e,`string`);return xk(t)==`symbol`?t:t+``}function Dk(e,t){if(xk(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(xk(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var Ok=function(){function e(){Sk(this,e),Tk(this,`activeIndex`,0),Tk(this,`coordinateList`,[]),Tk(this,`layout`,`horizontal`)}return wk(e,[{key:`setDetails`,value:function(e){var t=e.coordinateList,n=t===void 0?null:t,r=e.container,i=r===void 0?null:r,a=e.layout,o=a===void 0?null:a,s=e.offset,c=s===void 0?null:s,l=e.mouseHandlerCallback,u=l===void 0?null:l;this.coordinateList=n??this.coordinateList??[],this.container=i??this.container,this.layout=o??this.layout,this.offset=c??this.offset,this.mouseHandlerCallback=u??this.mouseHandlerCallback,this.activeIndex=Math.min(Math.max(this.activeIndex,0),this.coordinateList.length-1)}},{key:`focus`,value:function(){this.spoofMouse()}},{key:`keyboardEvent`,value:function(e){if(this.coordinateList.length!==0)switch(e.key){case`ArrowRight`:if(this.layout!==`horizontal`)return;this.activeIndex=Math.min(this.activeIndex+1,this.coordinateList.length-1),this.spoofMouse();break;case`ArrowLeft`:if(this.layout!==`horizontal`)return;this.activeIndex=Math.max(this.activeIndex-1,0),this.spoofMouse()}}},{key:`setIndex`,value:function(e){this.activeIndex=e}},{key:`spoofMouse`,value:function(){if(this.layout===`horizontal`&&this.coordinateList.length!==0){var e=this.container.getBoundingClientRect(),t=e.x,n=e.y,r=e.height,i=this.coordinateList[this.activeIndex].coordinate,a=window?.scrollX||0,o=window?.scrollY||0,s=t+i+a,c=n+this.offset.top+r/2+o;this.mouseHandlerCallback({pageX:s,pageY:c})}}}])}();function kk(e,t,n){if(n===`number`&&t===!0&&Array.isArray(e)){var r=e?.[0],i=e?.[1];if(r&&i&&I(r)&&I(i))return!0}return!1}function Ak(e,t,n,r){var i=r/2;return{stroke:`none`,fill:`#ccc`,x:e===`horizontal`?t.x-i:n.left+.5,y:e===`horizontal`?n.top+.5:t.y-i,width:e===`horizontal`?r:n.width-1,height:e===`horizontal`?n.height-1:r}}function jk(e){var t=e.cx,n=e.cy,r=e.radius,i=e.startAngle,a=e.endAngle;return{points:[dv(t,n,r,i),dv(t,n,r,a)],cx:t,cy:n,radius:r,startAngle:i,endAngle:a}}function Mk(e,t,n){var r,i,a,o;if(e===`horizontal`)r=t.x,a=r,i=n.top,o=n.top+n.height;else if(e===`vertical`)i=t.y,o=i,r=n.left,a=n.left+n.width;else if(t.cx!=null&&t.cy!=null){if(e===`centric`){var s=t.cx,c=t.cy,l=t.innerRadius,u=t.outerRadius,d=t.angle,f=dv(s,c,l,d),p=dv(s,c,u,d);r=f.x,i=f.y,a=p.x,o=p.y}else return jk(t)}return[{x:r,y:i},{x:a,y:o}]}function Nk(e){"@babel/helpers - typeof";return Nk=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Nk(e)}function Pk(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 Fk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Pk(Object(n),!0).forEach(function(t){Ik(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pk(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Ik(e,t,n){return t=Lk(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Lk(e){var t=Rk(e,`string`);return Nk(t)==`symbol`?t:t+``}function Rk(e,t){if(Nk(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Nk(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function zk(e){var t=e.element,n=e.tooltipEventType,r=e.isActive,i=e.activeCoordinate,a=e.activePayload,o=e.offset,s=e.activeTooltipIndex,c=e.tooltipAxisBandSize,l=e.layout,u=e.chartName,d=t.props.cursor??t.type.defaultProps?.cursor;if(!t||!d||!r||!i||u!==`ScatterChart`&&n!==`axis`)return null;var f,p=Fy;if(u===`ScatterChart`)f=i,p=qS;else if(u===`BarChart`)f=Ak(l,i,o,c),p=NS;else if(l===`radial`){var m=jk(i),h=m.cx,g=m.cy,_=m.radius;f={cx:h,cy:g,startAngle:m.startAngle,endAngle:m.endAngle,innerRadius:_,outerRadius:_},p=xy}else f={points:Mk(l,i,o)},p=Fy;var y=Fk(Fk(Fk(Fk({stroke:`#ccc`,pointerEvents:`none`},o),f),B(d,!1)),{},{payload:a,payloadIndex:s,className:v(`recharts-tooltip-cursor`,d.className)});return(0,R.isValidElement)(d)?(0,R.cloneElement)(d,y):(0,R.createElement)(p,y)}var Bk=[`item`],Vk=[`children`,`className`,`width`,`height`,`style`,`compact`,`title`,`desc`];function Hk(e){"@babel/helpers - typeof";return Hk=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Hk(e)}function Uk(){return Uk=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Uk.apply(this,arguments)}function Wk(e,t){return qk(e)||Kk(e,t)||cA(e,t)||Gk()}function Gk(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
55
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Kk(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function qk(e){if(Array.isArray(e))return e}function Jk(e,t){if(e==null)return{};var n=Yk(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Yk(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Xk(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function Zk(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,pA(r.key),r)}}function Qk(e,t,n){return t&&Zk(e.prototype,t),n&&Zk(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function $k(e,t,n){return t=rA(t),eA(e,nA()?Reflect.construct(t,n||[],rA(e).constructor):t.apply(e,n))}function eA(e,t){if(t&&(Hk(t)===`object`||typeof t==`function`))return t;if(t!==void 0)throw TypeError(`Derived constructors may only return object or undefined`);return tA(e)}function tA(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function nA(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(nA=function(){return!!e})()}function rA(e){return rA=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},rA(e)}function iA(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function`);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&aA(e,t)}function aA(e,t){return aA=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},aA(e,t)}function oA(e){return uA(e)||lA(e)||cA(e)||sA()}function sA(){throw TypeError(`Invalid attempt to spread non-iterable instance.
|
|
56
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cA(e,t){if(e){if(typeof e==`string`)return dA(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(e);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return dA(e,t)}}function lA(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function uA(e){if(Array.isArray(e))return dA(e)}function dA(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function fA(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 Z(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?fA(Object(n),!0).forEach(function(t){Q(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fA(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Q(e,t,n){return t=pA(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pA(e){var t=mA(e,`string`);return Hk(t)==`symbol`?t:t+``}function mA(e,t){if(Hk(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Hk(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var hA={xAxis:[`bottom`,`top`],yAxis:[`left`,`right`]},gA={width:`100%`,height:`100%`},_A={x:0,y:0};function vA(e){return e}var yA=function(e,t){return t===`horizontal`?e.x:t===`vertical`?e.y:t===`centric`?e.angle:e.radius},bA=function(e,t,n,r){var i=t.find(function(e){return e&&e.index===n});if(i){if(e===`horizontal`)return{x:i.coordinate,y:r.y};if(e===`vertical`)return{x:r.x,y:i.coordinate};if(e===`centric`){var a=i.coordinate,o=r.radius;return Z(Z(Z({},r),dv(r.cx,r.cy,o,a)),{},{angle:a,radius:o})}var s=i.coordinate,c=r.angle;return Z(Z(Z({},r),dv(r.cx,r.cy,s,c)),{},{angle:c,radius:s})}return _A},xA=function(e,t){var n=t.graphicalItems,r=t.dataStartIndex,i=t.dataEndIndex,a=(n??[]).reduce(function(e,t){var n=t.props.data;return n&&n.length?[].concat(oA(e),oA(n)):e},[]);return a.length>0?a:e&&e.length&&I(r)&&I(i)?e.slice(r,i+1):[]};function SA(e){return e===`number`?[0,`auto`]:void 0}var CA=function(e,t,n,r){var i=e.graphicalItems,a=e.tooltipAxis,o=xA(t,e);return n<0||!i||!i.length||n>=o.length?null:i.reduce(function(i,s){var c=s.props.data??t;c&&e.dataStartIndex+e.dataEndIndex!==0&&e.dataEndIndex-e.dataStartIndex>=n&&(c=c.slice(e.dataStartIndex,e.dataEndIndex+1));var l=a.dataKey&&!a.allowDuplicatedCategory?on(c===void 0?o:c,a.dataKey,r):c&&c[n]||o[n];return l?[].concat(oA(i),[nv(s,l)]):i},[])},wA=function(e,t,n,r){var i=r||{x:e.chartX,y:e.chartY},a=yA(i,n),o=e.orderedTooltipTicks,s=e.tooltipAxis,c=e.tooltipTicks,l=S_(a,o,c,s);if(l>=0&&c){var u=c[l]&&c[l].value;return{activeTooltipIndex:l,activeLabel:u,activePayload:CA(e,t,l,u),activeCoordinate:bA(n,o,l,i)}}return null},TA=function(e,t){var n=t.axes,r=t.graphicalItems,i=t.axisType,a=t.axisIdKey,o=t.stackGroups,s=t.dataStartIndex,c=t.dataEndIndex,l=e.layout,u=e.children,d=e.stackOffset,f=j_(l,i);return n.reduce(function(t,n){var p=n.type.defaultProps===void 0?n.props:Z(Z({},n.type.defaultProps),n.props),m=p.type,h=p.dataKey,g=p.allowDataOverflow,_=p.allowDuplicatedCategory,v=p.scale,y=p.ticks,b=p.includeHidden,x=p[a];if(t[x])return t;var S=xA(e.data,{graphicalItems:r.filter(function(e){return(a in e.props?e.props[a]:e.type.defaultProps?.[a])===x}),dataStartIndex:s,dataEndIndex:c}),C=S.length,w,T,E;kk(p.domain,g,m)&&(w=$_(p.domain,null,g),f&&(m===`number`||v!==`auto`)&&(E=x_(S,h,`category`)));var D=SA(m);if(!w||w.length===0){var O=p.domain??D;if(h){if(w=x_(S,h,m),m===`category`&&f){var k=rn(w);_&&k?(T=w,w=(0,ZC.default)(0,C)):_||(w=tv(O,w,n).reduce(function(e,t){return e.indexOf(t)>=0?e:[].concat(oA(e),[t])},[]))}else if(m===`category`)w=_?w.filter(function(e){return e!==``&&!(0,F.default)(e)}):tv(O,w,n).reduce(function(e,t){return e.indexOf(t)>=0||t===``||(0,F.default)(t)?e:[].concat(oA(e),[t])},[]);else if(m===`number`){var A=k_(S,r.filter(function(e){var t=a in e.props?e.props[a]:e.type.defaultProps?.[a],n=`hide`in e.props?e.props.hide:e.type.defaultProps?.hide;return t===x&&(b||!n)}),h,i,l);A&&(w=A)}f&&(m===`number`||v!==`auto`)&&(E=x_(S,h,`category`))}else w=f?(0,ZC.default)(0,C):o&&o[x]&&o[x].hasStack&&m===`number`?d===`expand`?[0,1]:X_(o[x].stackGroups,s,c):A_(S,r.filter(function(e){var t=a in e.props?e.props[a]:e.type.defaultProps[a],n=`hide`in e.props?e.props.hide:e.type.defaultProps.hide;return t===x&&(b||!n)}),m,l,!0);if(m===`number`)w=vk(u,w,x,i,y),O&&(w=$_(O,w,g));else if(m===`category`&&O){var j=O;w.every(function(e){return j.indexOf(e)>=0})&&(w=j)}}return Z(Z({},t),{},Q({},x,Z(Z({},p),{},{axisType:i,domain:w,categoricalDomain:E,duplicateDomain:T,originalDomain:p.domain??D,isCategorical:f,layout:l})))},{})},EA=function(e,t){var n=t.graphicalItems,r=t.Axis,i=t.axisType,a=t.axisIdKey,o=t.stackGroups,s=t.dataStartIndex,c=t.dataEndIndex,l=e.layout,u=e.children,d=xA(e.data,{graphicalItems:n,dataStartIndex:s,dataEndIndex:c}),f=d.length,p=j_(l,i),m=-1;return n.reduce(function(e,t){var h=(t.type.defaultProps===void 0?t.props:Z(Z({},t.type.defaultProps),t.props))[a],g=SA(`number`);if(!e[h]){m++;var _;return p?_=(0,ZC.default)(0,f):o&&o[h]&&o[h].hasStack?(_=X_(o[h].stackGroups,s,c),_=vk(u,_,h,i)):(_=$_(g,A_(d,n.filter(function(e){var t=a in e.props?e.props[a]:e.type.defaultProps?.[a],n=`hide`in e.props?e.props.hide:e.type.defaultProps?.hide;return t===h&&!n}),`number`,l),r.defaultProps.allowDataOverflow),_=vk(u,_,h,i)),Z(Z({},e),{},Q({},h,Z(Z({axisType:i},r.defaultProps),{},{hide:!0,orientation:(0,Jt.default)(hA,`${i}.${m%2}`,null),domain:_,originalDomain:g,isCategorical:p,layout:l})))}return e},{})},DA=function(e,t){var n=t.axisType,r=n===void 0?`xAxis`:n,i=t.AxisComp,a=t.graphicalItems,o=t.stackGroups,s=t.dataStartIndex,c=t.dataEndIndex,l=e.children,u=`${r}Id`,d=An(l,i),f={};return d&&d.length?f=TA(e,{axes:d,graphicalItems:a,axisType:r,axisIdKey:u,stackGroups:o,dataStartIndex:s,dataEndIndex:c}):a&&a.length&&(f=EA(e,{Axis:i,graphicalItems:a,axisType:r,axisIdKey:u,stackGroups:o,dataStartIndex:s,dataEndIndex:c})),f},OA=function(e){var t=nn(e),n=N_(t,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:(0,ys.default)(n,function(e){return e.coordinate}),tooltipAxis:t,tooltipAxisBandSize:ev(t,n)}},kA=function(e){var t=e.children,n=e.defaultShowTooltip,r=jn(t,_w),i=0,a=0;return e.data&&e.data.length!==0&&(a=e.data.length-1),r&&r.props&&(r.props.startIndex>=0&&(i=r.props.startIndex),r.props.endIndex>=0&&(a=r.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:i,dataEndIndex:a,activeTooltipIndex:-1,isTooltipActive:!!n}},AA=function(e){return!e||!e.length?!1:e.some(function(e){var t=En(e&&e.type);return t&&t.indexOf(`Bar`)>=0})},jA=function(e){return e===`horizontal`?{numericAxisName:`yAxis`,cateAxisName:`xAxis`}:e===`vertical`?{numericAxisName:`xAxis`,cateAxisName:`yAxis`}:e===`centric`?{numericAxisName:`radiusAxis`,cateAxisName:`angleAxis`}:{numericAxisName:`angleAxis`,cateAxisName:`radiusAxis`}},MA=function(e,t){var n=e.props,r=e.graphicalItems,i=e.xAxisMap,a=i===void 0?{}:i,o=e.yAxisMap,s=o===void 0?{}:o,c=n.width,l=n.height,u=n.children,d=n.margin||{},f=jn(u,_w),p=jn(u,Zo),m=Object.keys(s).reduce(function(e,t){var n=s[t],r=n.orientation;return!n.mirror&&!n.hide?Z(Z({},e),{},Q({},r,e[r]+n.width)):e},{left:d.left||0,right:d.right||0}),h=Z(Z({},Object.keys(a).reduce(function(e,t){var n=a[t],r=n.orientation;return!n.mirror&&!n.hide?Z(Z({},e),{},Q({},r,(0,Jt.default)(e,`${r}`)+n.height)):e},{top:d.top||0,bottom:d.bottom||0})),m),g=h.bottom;f&&(h.bottom+=f.props.height||_w.defaultProps.height),p&&t&&(h=E_(h,r,n,t));var _=c-h.left-h.right,v=l-h.top-h.bottom;return Z(Z({brushBottom:g},h),{},{width:Math.max(_,0),height:Math.max(v,0)})},NA=function(e,t){if(t===`xAxis`)return e[t].width;if(t===`yAxis`)return e[t].height},PA=function(e){var t=e.chartName,n=e.GraphicalChild,r=e.defaultTooltipEventType,i=r===void 0?`axis`:r,a=e.validateTooltipEventTypes,o=a===void 0?[`axis`]:a,s=e.axisComponents,c=e.legendContent,l=e.formatAxisMap,u=e.defaultProps,d=function(e,t){var n=t.graphicalItems,r=t.stackGroups,i=t.offset,a=t.updateId,o=t.dataStartIndex,c=t.dataEndIndex,l=e.barSize,u=e.layout,d=e.barGap,f=e.barCategoryGap,p=e.maxBarSize,m=jA(u),h=m.numericAxisName,g=m.cateAxisName,_=AA(n),v=[];return n.forEach(function(n,m){var y=xA(e.data,{graphicalItems:[n],dataStartIndex:o,dataEndIndex:c}),b=n.type.defaultProps===void 0?n.props:Z(Z({},n.type.defaultProps),n.props),x=b.dataKey,S=b.maxBarSize,C=b[`${h}Id`],w=b[`${g}Id`],T=s.reduce(function(e,n){var r=t[`${n.axisType}Map`],i=b[`${n.axisType}Id`];!(r&&r[i]||n.axisType===`zAxis`)&&Eg(!1);var a=r[i];return Z(Z({},e),{},Q(Q({},n.axisType,a),`${n.axisType}Ticks`,N_(a)))},{}),E=T[g],D=T[`${g}Ticks`],O=r&&r[C]&&r[C].hasStack&&J_(n,r[C].stackGroups),k=En(n.type).indexOf(`Bar`)>=0,A=ev(E,D),j=[],M=_&&w_({barSize:l,stackGroups:r,totalSize:NA(T,g)});if(k){var N=(0,F.default)(S)?p:S,ee=ev(E,D,!0)??N??0;j=T_({barGap:d,barCategoryGap:f,bandSize:ee===A?A:ee,sizeList:M[w],maxBarSize:N}),ee!==A&&(j=j.map(function(e){return Z(Z({},e),{},{position:Z(Z({},e.position),{},{offset:e.position.offset-ee/2})})}))}var te=n&&n.type&&n.type.getComposedData;te&&v.push({props:Z(Z({},te(Z(Z({},T),{},{displayedData:y,props:e,dataKey:x,item:n,bandSize:A,barPosition:j,offset:i,stackedData:O,layout:u,dataStartIndex:o,dataEndIndex:c}))),{},Q(Q(Q({key:n.key||`item-${m}`},h,T[h]),g,T[g]),`animationId`,a)),childIndex:Vn(n,e.children),item:n})}),v},f=function(e,r){var i=e.props,a=e.dataStartIndex,o=e.dataEndIndex,c=e.updateId;if(!Mn({props:i}))return null;var u=i.children,f=i.layout,p=i.stackOffset,m=i.data,h=i.reverseStackOrder,g=jA(f),_=g.numericAxisName,v=g.cateAxisName,y=An(u,n),b=U_(m,y,`${_}Id`,`${v}Id`,p,h),x=s.reduce(function(e,t){var n=`${t.axisType}Map`;return Z(Z({},e),{},Q({},n,DA(i,Z(Z({},t),{},{graphicalItems:y,stackGroups:t.axisType===_&&b,dataStartIndex:a,dataEndIndex:o}))))},{}),S=MA(Z(Z({},x),{},{props:i,graphicalItems:y}),r?.legendBBox);Object.keys(x).forEach(function(e){x[e]=l(i,x[e],S,e.replace(`Map`,``),t)});var C=x[`${v}Map`],w=OA(C);return Z(Z({formattedGraphicalItems:d(i,Z(Z({},x),{},{dataStartIndex:a,dataEndIndex:o,updateId:c,graphicalItems:y,stackGroups:b,offset:S})),graphicalItems:y,offset:S,stackGroups:b},w),x)},p=function(e){function n(e){var r;return Xk(this,n),r=$k(this,n,[e]),Q(r,`eventEmitterSymbol`,Symbol(`rechartsEventEmitter`)),Q(r,`accessibilityManager`,new Ok),Q(r,`handleLegendBBoxUpdate`,function(e){if(e){var t=r.state,n=t.dataStartIndex,i=t.dataEndIndex,a=t.updateId;r.setState(Z({legendBBox:e},f({props:r.props,dataStartIndex:n,dataEndIndex:i,updateId:a},Z(Z({},r.state),{},{legendBBox:e}))))}}),Q(r,`handleReceiveSyncEvent`,function(e,t,n){if(r.props.syncId===e){if(n===r.eventEmitterSymbol&&typeof r.props.syncMethod!=`function`)return;r.applySyncEvent(t)}}),Q(r,`handleBrushChange`,function(e){var t=e.startIndex,n=e.endIndex;if(t!==r.state.dataStartIndex||n!==r.state.dataEndIndex){var i=r.state.updateId;r.setState(function(){return Z({dataStartIndex:t,dataEndIndex:n},f({props:r.props,dataStartIndex:t,dataEndIndex:n,updateId:i},r.state))}),r.triggerSyncEvent({dataStartIndex:t,dataEndIndex:n})}}),Q(r,`handleMouseEnter`,function(e){var t=r.getMouseInfo(e);if(t){var n=Z(Z({},t),{},{isTooltipActive:!0});r.setState(n),r.triggerSyncEvent(n);var i=r.props.onMouseEnter;(0,z.default)(i)&&i(n,e)}}),Q(r,`triggeredAfterMouseMove`,function(e){var t=r.getMouseInfo(e),n=t?Z(Z({},t),{},{isTooltipActive:!0}):{isTooltipActive:!1};r.setState(n),r.triggerSyncEvent(n);var i=r.props.onMouseMove;(0,z.default)(i)&&i(n,e)}),Q(r,`handleItemMouseEnter`,function(e){r.setState(function(){return{isTooltipActive:!0,activeItem:e,activePayload:e.tooltipPayload,activeCoordinate:e.tooltipPosition||{x:e.cx,y:e.cy}}})}),Q(r,`handleItemMouseLeave`,function(){r.setState(function(){return{isTooltipActive:!1}})}),Q(r,`handleMouseMove`,function(e){e.persist(),r.throttleTriggeredAfterMouseMove(e)}),Q(r,`handleMouseLeave`,function(e){r.throttleTriggeredAfterMouseMove.cancel();var t={isTooltipActive:!1};r.setState(t),r.triggerSyncEvent(t);var n=r.props.onMouseLeave;(0,z.default)(n)&&n(t,e)}),Q(r,`handleOuterEvent`,function(e){var t=Bn(e),n=(0,Jt.default)(r.props,`${t}`);t&&(0,z.default)(n)&&n((/.*touch.*/i.test(t)?r.getMouseInfo(e.changedTouches[0]):r.getMouseInfo(e))??{},e)}),Q(r,`handleClick`,function(e){var t=r.getMouseInfo(e);if(t){var n=Z(Z({},t),{},{isTooltipActive:!0});r.setState(n),r.triggerSyncEvent(n);var i=r.props.onClick;(0,z.default)(i)&&i(n,e)}}),Q(r,`handleMouseDown`,function(e){var t=r.props.onMouseDown;(0,z.default)(t)&&t(r.getMouseInfo(e),e)}),Q(r,`handleMouseUp`,function(e){var t=r.props.onMouseUp;(0,z.default)(t)&&t(r.getMouseInfo(e),e)}),Q(r,`handleTouchMove`,function(e){e.changedTouches!=null&&e.changedTouches.length>0&&r.throttleTriggeredAfterMouseMove(e.changedTouches[0])}),Q(r,`handleTouchStart`,function(e){e.changedTouches!=null&&e.changedTouches.length>0&&r.handleMouseDown(e.changedTouches[0])}),Q(r,`handleTouchEnd`,function(e){e.changedTouches!=null&&e.changedTouches.length>0&&r.handleMouseUp(e.changedTouches[0])}),Q(r,`handleDoubleClick`,function(e){var t=r.props.onDoubleClick;(0,z.default)(t)&&t(r.getMouseInfo(e),e)}),Q(r,`handleContextMenu`,function(e){var t=r.props.onContextMenu;(0,z.default)(t)&&t(r.getMouseInfo(e),e)}),Q(r,`triggerSyncEvent`,function(e){r.props.syncId!==void 0&&yk.emit(bk,r.props.syncId,e,r.eventEmitterSymbol)}),Q(r,`applySyncEvent`,function(e){var t=r.props,n=t.layout,i=t.syncMethod,a=r.state.updateId,o=e.dataStartIndex,s=e.dataEndIndex;if(e.dataStartIndex!==void 0||e.dataEndIndex!==void 0)r.setState(Z({dataStartIndex:o,dataEndIndex:s},f({props:r.props,dataStartIndex:o,dataEndIndex:s,updateId:a},r.state)));else if(e.activeTooltipIndex!==void 0){var c=e.chartX,l=e.chartY,u=e.activeTooltipIndex,d=r.state,p=d.offset,m=d.tooltipTicks;if(!p)return;if(typeof i==`function`)u=i(m,e);else if(i===`value`){u=-1;for(var h=0;h<m.length;h++)if(m[h].value===e.activeLabel){u=h;break}}var g=Z(Z({},p),{},{x:p.left,y:p.top}),_=Math.min(c,g.x+g.width),v=Math.min(l,g.y+g.height),y=m[u]&&m[u].value,b=CA(r.state,r.props.data,u),x=m[u]?{x:n===`horizontal`?m[u].coordinate:_,y:n===`horizontal`?v:m[u].coordinate}:_A;r.setState(Z(Z({},e),{},{activeLabel:y,activeCoordinate:x,activePayload:b,activeTooltipIndex:u}))}else r.setState(e)}),Q(r,`renderCursor`,function(e){var n=r.state,i=n.isTooltipActive,a=n.activeCoordinate,o=n.activePayload,s=n.offset,c=n.activeTooltipIndex,l=n.tooltipAxisBandSize,u=r.getTooltipEventType(),d=e.props.active??i,f=r.props.layout,p=e.key||`_recharts-cursor`;return R.createElement(zk,{key:p,activeCoordinate:a,activePayload:o,activeTooltipIndex:c,chartName:t,element:e,isActive:d,layout:f,offset:s,tooltipAxisBandSize:l,tooltipEventType:u})}),Q(r,`renderPolarAxis`,function(e,t,n){var i=(0,Jt.default)(e,`type.axisType`),a=(0,Jt.default)(r.state,`${i}Map`),o=e.type.defaultProps,s=o===void 0?e.props:Z(Z({},o),e.props),c=a&&a[s[`${i}Id`]];return(0,R.cloneElement)(e,Z(Z({},c),{},{className:v(i,c.className),key:e.key||`${t}-${n}`,ticks:N_(c,!0)}))}),Q(r,`renderPolarGrid`,function(e){var t=e.props,n=t.radialLines,i=t.polarAngles,a=t.polarRadius,o=r.state,s=o.radiusAxisMap,c=o.angleAxisMap,l=nn(s),u=nn(c),d=u.cx,f=u.cy,p=u.innerRadius,m=u.outerRadius;return(0,R.cloneElement)(e,{polarAngles:Array.isArray(i)?i:N_(u,!0).map(function(e){return e.coordinate}),polarRadius:Array.isArray(a)?a:N_(l,!0).map(function(e){return e.coordinate}),cx:d,cy:f,innerRadius:p,outerRadius:m,key:e.key||`polar-grid`,radialLines:n})}),Q(r,`renderLegend`,function(){var e=r.state.formattedGraphicalItems,t=r.props,n=t.children,i=t.width,a=t.height,o=r.props.margin||{},s=i_({children:n,formattedGraphicalItems:e,legendWidth:i-(o.left||0)-(o.right||0),legendContent:c});if(!s)return null;var l=s.item,u=Jk(s,Bk);return(0,R.cloneElement)(l,Z(Z({},u),{},{chartWidth:i,chartHeight:a,margin:o,onBBoxUpdate:r.handleLegendBBoxUpdate}))}),Q(r,`renderTooltip`,function(){var e=r.props,t=e.children,n=e.accessibilityLayer,i=jn(t,Oc);if(!i)return null;var a=r.state,o=a.isTooltipActive,s=a.activeCoordinate,c=a.activePayload,l=a.activeLabel,u=a.offset,d=i.props.active??o;return(0,R.cloneElement)(i,{viewBox:Z(Z({},u),{},{x:u.left,y:u.top}),active:d,label:l,payload:d?c:[],coordinate:s,accessibilityLayer:n})}),Q(r,`renderBrush`,function(e){var t=r.props,n=t.margin,i=t.data,a=r.state,o=a.offset,s=a.dataStartIndex,c=a.dataEndIndex,l=a.updateId;return(0,R.cloneElement)(e,{key:e.key||`_recharts-brush`,onChange:F_(r.handleBrushChange,e.props.onChange),data:i,x:I(e.props.x)?e.props.x:o.left,y:I(e.props.y)?e.props.y:o.top+o.height+o.brushBottom-(n.bottom||0),width:I(e.props.width)?e.props.width:o.width,startIndex:s,endIndex:c,updateId:`brush-${l}`})}),Q(r,`renderReferenceElement`,function(e,t,n){if(!e)return null;var i=r.clipPathId,a=r.state,o=a.xAxisMap,s=a.yAxisMap,c=a.offset,l=e.type.defaultProps||{},u=e.props,d=u.xAxisId,f=d===void 0?l.xAxisId:d,p=u.yAxisId,m=p===void 0?l.yAxisId:p;return(0,R.cloneElement)(e,{key:e.key||`${t}-${n}`,xAxis:o[f],yAxis:s[m],viewBox:{x:c.left,y:c.top,width:c.width,height:c.height},clipPathId:i})}),Q(r,`renderActivePoints`,function(e){var t=e.item,r=e.activePoint,i=e.basePoint,a=e.childIndex,o=e.isRange,s=[],c=t.props.key,l=t.item.type.defaultProps===void 0?t.item.props:Z(Z({},t.item.type.defaultProps),t.item.props),u=l.activeDot,d=l.dataKey,f=Z(Z({index:a,dataKey:d,cx:r.x,cy:r.y,r:4,fill:C_(t.item),strokeWidth:2,stroke:`#fff`,payload:r.payload,value:r.value},B(u,!1)),gn(u));return s.push(n.renderActiveDot(u,f,`${c}-activePoint-${a}`)),i?s.push(n.renderActiveDot(u,Z(Z({},f),{},{cx:i.x,cy:i.y}),`${c}-basePoint-${a}`)):o&&s.push(null),s}),Q(r,`renderGraphicChild`,function(e,t,n){var i=r.filterFormatItem(e,t,n);if(!i)return null;var a=r.getTooltipEventType(),o=r.state,s=o.isTooltipActive,c=o.tooltipAxis,l=o.activeTooltipIndex,u=o.activeLabel,d=r.props.children,f=jn(d,Oc),p=i.props,m=p.points,h=p.isRange,g=p.baseLine,_=i.item.type.defaultProps===void 0?i.item.props:Z(Z({},i.item.type.defaultProps),i.item.props),v=_.activeDot,y=_.hide,b=_.activeBar,x=_.activeShape,S=!!(!y&&s&&f&&(v||b||x)),C={};a!==`axis`&&f&&f.props.trigger===`click`?C={onClick:F_(r.handleItemMouseEnter,e.props.onClick)}:a!==`axis`&&(C={onMouseLeave:F_(r.handleItemMouseLeave,e.props.onMouseLeave),onMouseEnter:F_(r.handleItemMouseEnter,e.props.onMouseEnter)});var w=(0,R.cloneElement)(e,Z(Z({},i.props),C));function T(e){return typeof c.dataKey==`function`?c.dataKey(e.payload):null}if(S){if(l>=0){var E,D;if(c.dataKey&&!c.allowDuplicatedCategory){var O=typeof c.dataKey==`function`?T:`payload.${c.dataKey.toString()}`;E=on(m,O,u),D=h&&g&&on(g,O,u)}else E=m?.[l],D=h&&g&&g[l];if(x||b){var k=e.props.activeIndex===void 0?l:e.props.activeIndex;return[(0,R.cloneElement)(e,Z(Z(Z({},i.props),C),{},{activeIndex:k})),null,null]}if(!(0,F.default)(E))return[w].concat(oA(r.renderActivePoints({item:i,activePoint:E,basePoint:D,childIndex:l,isRange:h})))}else{var A=(r.getItemByXY(r.state.activeCoordinate)??{graphicalItem:w}).graphicalItem,j=A.item,M=j===void 0?e:j,N=A.childIndex,ee=Z(Z(Z({},i.props),C),{},{activeIndex:N});return[(0,R.cloneElement)(M,ee),null,null]}}return h?[w,null,null]:[w,null]}),Q(r,`renderCustomized`,function(e,t,n){return(0,R.cloneElement)(e,Z(Z({key:`recharts-customized-${n}`},r.props),r.state))}),Q(r,`renderMap`,{CartesianGrid:{handler:vA,once:!0},ReferenceArea:{handler:r.renderReferenceElement},ReferenceLine:{handler:vA},ReferenceDot:{handler:r.renderReferenceElement},XAxis:{handler:vA},YAxis:{handler:vA},Brush:{handler:r.renderBrush,once:!0},Bar:{handler:r.renderGraphicChild},Line:{handler:r.renderGraphicChild},Area:{handler:r.renderGraphicChild},Radar:{handler:r.renderGraphicChild},RadialBar:{handler:r.renderGraphicChild},Scatter:{handler:r.renderGraphicChild},Pie:{handler:r.renderGraphicChild},Funnel:{handler:r.renderGraphicChild},Tooltip:{handler:r.renderCursor,once:!0},PolarGrid:{handler:r.renderPolarGrid,once:!0},PolarAngleAxis:{handler:r.renderPolarAxis},PolarRadiusAxis:{handler:r.renderPolarAxis},Customized:{handler:r.renderCustomized}}),r.clipPathId=`${e.id??en(`recharts`)}-clip`,r.throttleTriggeredAfterMouseMove=(0,Pc.default)(r.triggeredAfterMouseMove,e.throttleDelay??1e3/60),r.state={},r}return iA(n,e),Qk(n,[{key:`componentDidMount`,value:function(){this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:this.props.margin.left??0,top:this.props.margin.top??0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:`displayDefaultTooltip`,value:function(){var e=this.props,t=e.children,n=e.data,r=e.height,i=e.layout,a=jn(t,Oc);if(a){var o=a.props.defaultIndex;if(!(typeof o!=`number`||o<0||o>this.state.tooltipTicks.length-1)){var s=this.state.tooltipTicks[o]&&this.state.tooltipTicks[o].value,c=CA(this.state,n,o,s),l=this.state.tooltipTicks[o].coordinate,u=(this.state.offset.top+r)/2,d=i===`horizontal`?{x:l,y:u}:{y:l,x:u},f=this.state.formattedGraphicalItems.find(function(e){return e.item.type.name===`Scatter`});f&&(d=Z(Z({},d),f.props.points[o].tooltipPosition),c=f.props.points[o].tooltipPayload);var p={activeTooltipIndex:o,isTooltipActive:!0,activeLabel:s,activePayload:c,activeCoordinate:d};this.setState(p),this.renderCursor(a),this.accessibilityManager.setIndex(o)}}}},{key:`getSnapshotBeforeUpdate`,value:function(e,t){return this.props.accessibilityLayer?(this.state.tooltipTicks!==t.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==e.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==e.margin&&this.accessibilityManager.setDetails({offset:{left:this.props.margin.left??0,top:this.props.margin.top??0}}),null):null}},{key:`componentDidUpdate`,value:function(e){Ln([jn(e.children,Oc)],[jn(this.props.children,Oc)])||this.displayDefaultTooltip()}},{key:`componentWillUnmount`,value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:`getTooltipEventType`,value:function(){var e=jn(this.props.children,Oc);if(e&&typeof e.props.shared==`boolean`){var t=e.props.shared?`axis`:`item`;return o.indexOf(t)>=0?t:i}return i}},{key:`getMouseInfo`,value:function(e){if(!this.container)return null;var t=this.container,n=t.getBoundingClientRect(),r=sl(n),i={chartX:Math.round(e.pageX-r.left),chartY:Math.round(e.pageY-r.top)},a=n.width/t.offsetWidth||1,o=this.inRange(i.chartX,i.chartY,a);if(!o)return null;var s=this.state,c=s.xAxisMap,l=s.yAxisMap,u=this.getTooltipEventType(),d=wA(this.state,this.props.data,this.props.layout,o);if(u!==`axis`&&c&&l){var f=nn(c).scale,p=nn(l).scale,m=f&&f.invert?f.invert(i.chartX):null,h=p&&p.invert?p.invert(i.chartY):null;return Z(Z({},i),{},{xValue:m,yValue:h},d)}return d?Z(Z({},i),d):null}},{key:`inRange`,value:function(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,r=this.props.layout,i=e/n,a=t/n;if(r===`horizontal`||r===`vertical`){var o=this.state.offset;return i>=o.left&&i<=o.left+o.width&&a>=o.top&&a<=o.top+o.height?{x:i,y:a}:null}var s=this.state,c=s.angleAxisMap,l=s.radiusAxisMap;if(c&&l){var u=nn(c);return gv({x:i,y:a},u)}return null}},{key:`parseEventsOfWrapper`,value:function(){var e=this.props.children,t=this.getTooltipEventType(),n=jn(e,Oc),r={};return n&&t===`axis`&&(r=n.props.trigger===`click`?{onClick:this.handleClick}:{onMouseEnter:this.handleMouseEnter,onDoubleClick:this.handleDoubleClick,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd,onContextMenu:this.handleContextMenu}),Z(Z({},gn(this.props,this.handleOuterEvent)),r)}},{key:`addListener`,value:function(){yk.on(bk,this.handleReceiveSyncEvent)}},{key:`removeListener`,value:function(){yk.removeListener(bk,this.handleReceiveSyncEvent)}},{key:`filterFormatItem`,value:function(e,t,n){for(var r=this.state.formattedGraphicalItems,i=0,a=r.length;i<a;i++){var o=r[i];if(o.item===e||o.props.key===e.key||t===En(o.item.type)&&n===o.childIndex)return o}return null}},{key:`renderClipPath`,value:function(){var e=this.clipPathId,t=this.state.offset,n=t.left,r=t.top,i=t.height,a=t.width;return R.createElement(`defs`,null,R.createElement(`clipPath`,{id:e},R.createElement(`rect`,{x:n,y:r,height:i,width:a})))}},{key:`getXScales`,value:function(){var e=this.state.xAxisMap;return e?Object.entries(e).reduce(function(e,t){var n=Wk(t,2),r=n[0],i=n[1];return Z(Z({},e),{},Q({},r,i.scale))},{}):null}},{key:`getYScales`,value:function(){var e=this.state.yAxisMap;return e?Object.entries(e).reduce(function(e,t){var n=Wk(t,2),r=n[0],i=n[1];return Z(Z({},e),{},Q({},r,i.scale))},{}):null}},{key:`getXScaleByAxisId`,value:function(e){var t;return(t=this.state.xAxisMap)==null||(t=t[e])==null?void 0:t.scale}},{key:`getYScaleByAxisId`,value:function(e){var t;return(t=this.state.yAxisMap)==null||(t=t[e])==null?void 0:t.scale}},{key:`getItemByXY`,value:function(e){var t=this.state,n=t.formattedGraphicalItems,r=t.activeItem;if(n&&n.length)for(var i=0,a=n.length;i<a;i++){var o=n[i],s=o.props,c=o.item,l=c.type.defaultProps===void 0?c.props:Z(Z({},c.type.defaultProps),c.props),u=En(c.type);if(u===`Bar`){var d=(s.data||[]).find(function(t){return jS(e,t)});if(d)return{graphicalItem:o,payload:d}}else if(u===`RadialBar`){var f=(s.data||[]).find(function(t){return gv(e,t)});if(f)return{graphicalItem:o,payload:f}}else if(kC(o,r)||AC(o,r)||jC(o,r)){var p=RC({graphicalItem:o,activeTooltipItem:r,itemData:l.data}),m=l.activeIndex===void 0?p:l.activeIndex;return{graphicalItem:Z(Z({},o),{},{childIndex:m}),payload:jC(o,r)?l.data[p]:o.props.data[p]}}}return null}},{key:`render`,value:function(){var e=this;if(!Mn(this))return null;var t=this.props,n=t.children,r=t.className,i=t.width,a=t.height,o=t.style,s=t.compact,c=t.title,l=t.desc,u=B(Jk(t,Vk),!1);if(s)return R.createElement(LT,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},R.createElement(Kn,Uk({},u,{width:i,height:a,title:c,desc:l}),this.renderClipPath(),zn(n,this.renderMap)));this.props.accessibilityLayer&&(u.tabIndex=this.props.tabIndex??0,u.role=this.props.role??`application`,u.onKeyDown=function(t){e.accessibilityManager.keyboardEvent(t)},u.onFocus=function(){e.accessibilityManager.focus()});var d=this.parseEventsOfWrapper();return R.createElement(LT,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},R.createElement(`div`,Uk({className:v(`recharts-wrapper`,r),style:Z({position:`relative`,cursor:`default`,width:i,height:a},o)},d,{ref:function(t){e.container=t}}),R.createElement(Kn,Uk({},u,{width:i,height:a,title:c,desc:l,style:gA}),this.renderClipPath(),zn(n,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])}(R.Component);Q(p,`displayName`,t),Q(p,`defaultProps`,Z({layout:`horizontal`,stackOffset:`none`,barCategoryGap:`10%`,barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:`index`},u)),Q(p,`getDerivedStateFromProps`,function(e,t){var n=e.dataKey,r=e.data,i=e.children,a=e.width,o=e.height,s=e.layout,c=e.stackOffset,l=e.margin,u=t.dataStartIndex,d=t.dataEndIndex;if(t.updateId===void 0){var p=kA(e);return Z(Z(Z({},p),{},{updateId:0},f(Z(Z({props:e},p),{},{updateId:0}),t)),{},{prevDataKey:n,prevData:r,prevWidth:a,prevHeight:o,prevLayout:s,prevStackOffset:c,prevMargin:l,prevChildren:i})}if(n!==t.prevDataKey||r!==t.prevData||a!==t.prevWidth||o!==t.prevHeight||s!==t.prevLayout||c!==t.prevStackOffset||!cn(l,t.prevMargin)){var m=kA(e),h={chartX:t.chartX,chartY:t.chartY,isTooltipActive:t.isTooltipActive},g=Z(Z({},wA(t,r,s)),{},{updateId:t.updateId+1}),_=Z(Z(Z({},m),h),g);return Z(Z(Z({},_),f(Z({props:e},_),t)),{},{prevDataKey:n,prevData:r,prevWidth:a,prevHeight:o,prevLayout:s,prevStackOffset:c,prevMargin:l,prevChildren:i})}if(!Ln(i,t.prevChildren)){var v=jn(i,_w),y=v?v.props?.startIndex??u:u,b=v?v.props?.endIndex??d:d,x=y!==u||b!==d,S=!(0,F.default)(r)&&!x?t.updateId:t.updateId+1;return Z(Z({updateId:S},f(Z(Z({props:e},t),{},{updateId:S,dataStartIndex:y,dataEndIndex:b}),t)),{},{prevChildren:i,dataStartIndex:y,dataEndIndex:b})}return null}),Q(p,`renderActiveDot`,function(e,t,n){var r=(0,R.isValidElement)(e)?(0,R.cloneElement)(e,t):(0,z.default)(e)?e(t):R.createElement(FS,t);return R.createElement(V,{className:`recharts-active-dot`,key:n},r)});var m=(0,R.forwardRef)(function(e,t){return R.createElement(p,Uk({},e,{ref:t}))});return m.displayName=p.displayName,m}({chartName:`AreaChart`,GraphicalChild:jO,axisComponents:[{axisType:`xAxis`,AxisComp:JO},{axisType:`yAxis`,AxisComp:dk}],formatAxisMap:_T}),FA=[{minutes:60,label:`1 hour`},{minutes:360,label:`6 hours`},{minutes:720,label:`12 hours`},{minutes:1440,label:`1 day`},{minutes:10080,label:`7 days`},{minutes:null,label:`Permanent`}],IA=FA[0];function LA(e,t){if(e)return e;let n=t===void 0?-1:t.indexOf(`/`);return n>0?t?.slice(0,n):void 0}var RA=`Cartethyia Probe`;function zA(e){return e?e.userAgent===RA:!1}function BA(e){return e?zA(e)?`Probe`:e.apiKeyLabel?e.apiKeyLabel:e.apiKeyId?`${e.apiKeyId.slice(0,8)}…`:`—`:`—`}function VA(e){return e?e.clientName?e.clientName:e.userAgent?e.userAgent:zA(e)?`Provider test`:`—`:`—`}function HA(e){if(e.includes(`:`))return`${e.split(`:`).slice(0,2).join(`:`)}:…`;let t=e.split(`.`);return t.length===4?`${t.slice(0,3).join(`.`)}.x`:`…`}var UA=[`1h`,`6h`,`12h`,`24h`,`7d`,`30d`,`all`],WA={200:`OK`,400:`Bad Request`,401:`Unauthorized`,403:`Forbidden`,404:`Not Found`,409:`Conflict`,413:`Payload Too Large`,415:`Unsupported Media Type`,422:`Unprocessable Entity`,429:`Too Many Requests`,499:`Client Closed Request`,500:`Internal Server Error`,501:`Not Implemented`,502:`Bad Gateway`,503:`Service Unavailable`,504:`Gateway Timeout`};function GA(e){let t=WA[e];return t===void 0?String(e):`${e} ${t}`}var KA={200:`OK`,400:`BAD`,401:`AUTH`,403:`DENY`,404:`MISS`,409:`CONFL`,413:`LARGE`,415:`TYPE`,422:`UNPRO`,429:`RATE`,499:`ABORT`,500:`ERR`,501:`TODO`,502:`GATE`,503:`DOWN`,504:`TIME`};function qA(e){let t=KA[e];return t===void 0?String(e):`${e} ${t}`}function JA(e){return e===200?`ok`:e===499?`warn`:e>=400?`err`:`warn`}function YA(e,t,n,r){let i={timeZone:n,hourCycle:`h23`,month:`2-digit`,day:`2-digit`,hour:`2-digit`,minute:`2-digit`};r&&(i.year=`numeric`,i.timeZoneName=`shortOffset`);let a={};for(let n of new Intl.DateTimeFormat(t,i).formatToParts(e))a[n.type]=n.value;return a}var XA=`Asia/Jakarta`;function ZA(e,t,n=XA){let r=new Date(e);if(Number.isNaN(r.getTime()))return e;let i=YA(r,t,n,!1);return`${i.month??``}-${i.day??``} ${i.hour??``}:${i.minute??``}`}function QA(e,t,n=XA){let r=new Date(e);if(Number.isNaN(r.getTime()))return e;let i=YA(r,t,n,!0);return`${i.year??``}-${i.month??``}-${i.day??``} ${i.hour??``}:${i.minute??``} ${i.timeZoneName??``}`}var $=a(),$A=274;function ej(e){if(typeof e==`string`){let t=e.trim();if(t.startsWith(`{`)||t.startsWith(`[`))try{let t=JSON.parse(e);return{text:JSON.stringify(t,null,2),bytes:new TextEncoder().encode(e).byteLength}}catch{return{text:e,bytes:new TextEncoder().encode(e).byteLength}}return{text:e,bytes:new TextEncoder().encode(e).byteLength}}return{text:JSON.stringify(e,null,2),bytes:new TextEncoder().encode(JSON.stringify(e)).byteLength}}var tj={"1h":`Last 1 Hour`,"6h":`Last 6 Hours`,"12h":`Last 12 Hours`,"24h":`Last 24 Hours`,"7d":`Last 7 Days`,"30d":`Last 30 Days`,all:`All retained`},nj=UA.map(e=>({value:e,label:tj[e]??e}));function rj(e){return tj[e]??e}function ij(e,t,n){let r=rj(e);if(t||n===void 0)return r;let i=n.inputTokens+n.outputTokens;return`${r} · ${y(n.requests)} calls · ${De(i)} tokens · avg ${S(n.avgDurationMs)}`}function aj(e){return e!==null&&UA.includes(e)?e:`24h`}function oj(e){return e===`tokens`||e===`cached`?e:`requests`}function sj(e){if(e===null)return Ee;if(e===`auto`)return-1;let t=Number(e);return Number.isInteger(t)&&t>=0&&t<=Se?t:Ee}function cj(e){return e!==null&&ae.includes(e)?e:`model`}function lj(e){return e==null||!Number.isFinite(e)?`—`:e===0?`$0.00`:e<.01?`$${e.toFixed(4)}`:`$${e.toFixed(2)}`}function uj(e){return e==null||!Number.isFinite(e)?`—`:`${x(e)} CR`}function dj(e){return e==null||!Number.isFinite(e)||e<=0?`—`:`${(e>=100?Math.round(e):Math.round(e*10)/10).toLocaleString(`en-US`)} tok/s`}function fj(e){let t=new Date(e);return Number.isNaN(t.getTime())?e:t.toLocaleTimeString(`en-GB`,{hour:`2-digit`,minute:`2-digit`,second:`2-digit`})}function pj(e){switch(e){case`chat`:return`OpenAI Completions`;case`messages`:return`Anthropic Messages`;case`responses`:return`OpenAI Responses`;case`completion`:return`OpenAI Completions`;default:return e||`—`}}var mj=[{key:`request`,bit:1,label:`Client request`,icon:ee},{key:`providerRequest`,bit:2,label:`Provider request`,icon:ne},{key:`providerResponse`,bit:4,label:`Provider response`,icon:me},{key:`clientResponse`,bit:8,label:`Client response`,icon:T}];function hj(e,t=Date.now()){let n=new Date(e).getTime();if(Number.isNaN(n))return`—`;let r=Math.max(0,t-n),i=6e4,a=60*i,o=24*a,s=7*o;if(r<a){let e=Math.max(0,Math.floor(r/i));return e<=1?`just now`:`${e}m ago`}if(r<o){let e=Math.floor(r/a);return e<=1?`1h ago`:`${e}h ago`}if(r<s){let e=Math.floor(r/o);return e<=1?`1d ago`:`${e}d ago`}let c=Math.floor(r/s);return c<=1?`1w ago`:`${c}w ago`}function gj(e,t){if(t!==void 0){let e=t>=500||t>=400&&t!==499?`err`:t===200?`ok`:`warn`;return{code:qA(t),tone:e}}switch(e){case`completed`:return{code:qA(200),tone:`ok`};case`failed`:return{code:qA(500),tone:`err`};case`cancelled`:return{code:qA(499),tone:`warn`};case`truncated`:return{code:qA(502),tone:`err`};default:return{code:e,tone:`warn`}}}function _j(e,t){if(t!==void 0)return GA(t);switch(e){case`completed`:return GA(200);case`failed`:return GA(500);case`cancelled`:return GA(499);case`truncated`:return GA(502);default:return e}}function vj(e,t,n){if(n===499||e===`cancelled`)return`499 · client aborted the request (${t??`cancelled`}) — not a gateway error`;if(n===200||e===`completed`)return`200 · request succeeded`;let r=_j(e,n);return t?`${r} · ${t}`:r}function yj({status:e,errorKind:t,httpStatus:n}){let[r,i]=(0,R.useState)(!1),a=gj(e,n),o=vj(e,t,n);return(0,$.jsxs)(`span`,{className:`relative inline-block`,children:[(0,$.jsx)(`button`,{type:`button`,onClick:()=>i(e=>!e),onMouseEnter:()=>i(!0),onMouseLeave:()=>i(!1),"aria-expanded":r,"aria-label":o,title:o,className:b(`font-mono font-bold tabular-nums bg-transparent border border-transparent`,`rounded-chip cursor-pointer px-2 py-0 text-[inherit]`),style:{color:Cj[a.tone]},children:a.code}),r?(0,$.jsx)(`span`,{role:`status`,className:`absolute top-full z-30 mt-1.5 left-0 whitespace-normal min-w-110 max-w-140 border border-inner-border rounded-control bg-popover-bg shadow-popout px-5 py-4 font-sans font-normal text-badge leading-snug text-text-secondary`,children:o}):null]})}function bj(e){let t={transport_closed:`request was cancelled by client`,transport_unavailable:`upstream stream failed or ended before completion`,timeout:`request timed out before a response was received`,deadline_exceeded:`upstream stream stalled past the deadline`,invalid_request:`request was rejected as invalid`,internal_error:`the gateway was misconfigured for this request`,provider_error:`upstream provider returned an error`,platform_unavailable:`upstream provider was unavailable`,proxy_unreachable:`network proxy was unreachable`,proxy_auth_required:`network proxy rejected the credential`,quota_exceeded:`a rate limit or budget was exhausted`,authentication_failed:`upstream rejected the credential`,capacity_exhausted:`the API key's concurrency limit was reached`,provider_capacity_exhausted:`every account was at its max-inflight ceiling`,upstream_queued:`the upstream queued this request; retry after the stated interval`,model_not_found:`no route served this model`,context_length_exceeded:`the request exceeded the model's context window`,capability_unsupported:`the route does not support this request`,admission_unavailable:`gateway dependencies were unavailable`,unknown_error:`the upstream failure could not be classified`,accounts_unavailable:`no account for this route was available`,accounts_rate_limited:`every account for this route is rate limited or cooling down`,ambiguous_model:`the model id matched more than one route`,invalid_pool_limits:`the network pool limits were rejected`,max_connections_exceeded:`the connection ceiling was reached`,proxy_pool_capacity_exceeded:`the proxy pool had no free slot`,proxy_pool_cooldown:`the proxy pool is cooling down`,proxy_pool_unavailable:`no usable proxy pool was available`,proxy_pool_unhealthy:`the selected proxy pool could not establish a tunnel`,slug_reserved:`that slug is reserved by the gateway`,tenant_capacity_exhausted:`the tenant concurrency ceiling was reached`,tls_rejected:`the upstream TLS handshake was rejected`,tool_call_loop_detected:`the request looped on the same tool call`,tunnel_setup_failed:`the tunnel could not be established`,unsupported_field:`the request carried a field this route rejects`,shutting_down:`the gateway was draining for a restart`,restart_for_update:`the gateway was restarting for an update; retry shortly`,upstream_not_found:`the upstream route did not exist`,request_too_large:`the request body exceeded the size limit`,proxy_pool_provider_capacity_exceeded:`this provider reached its ceiling on the selected proxy pool`,proxy_pool_blocked:`the proxy pool refused this destination`,policy_rejected:`gateway policy refused this request`,link_not_found:`that share link does not exist`,link_expired:`that share link has expired`,link_revoked:`that share link was revoked`,link_disabled:`that share link is disabled`,invalid_sequence:`the request arrived out of sequence`,invalid_lifecycle:`the request is not valid in its current state`,unsupported_media_type:`the request's content type is not accepted`,upstream_conflict:`upstream reported a conflict`,upstream_unprocessable:`upstream could not process the request`,overloaded:`the gateway was overloaded; retry shortly`,client_router_denied:`the client router denied this request`,model_abuse_banned:`this address is banned for this key after repeated invalid model requests`};return e&&t[e]?t[e]:e?e.replaceAll(`_`,` `):`request failed`}function xj(e){return e===`cartethyia`?`Gateway`:e===`upstream`?`Upstream`:e===`network`?`Network`:``}function Sj(e,t,n,r){if(e===`cancelled`){let e=xj(n),r=bj(t);return e?`Cancelled 499 · ${e}: ${r} — not a gateway error`:`Cancelled 499: ${r} — not a gateway error`}let i=gj(e,r).code.split(` `,1)[0]??e,a=xj(n),o=bj(t);return a?`${o} · ${i} · ${a}`:`${o} · ${i}`}var Cj={ok:`var(--green)`,err:`var(--red)`,warn:`var(--orange)`};function wj({options:e,value:t,onChange:n,ariaLabel:r}){return(0,$.jsx)(`div`,{role:`tablist`,"aria-label":r,className:`flex flex-wrap gap-2 min-w-0`,children:e.map(e=>(0,$.jsx)(_,{role:`tab`,"aria-selected":t===e.id,variant:t===e.id?`primary`:`secondary`,size:`sm`,onClick:()=>n(e.id),children:e.label},e.id))})}function Tj({label:e,wide:t,onToggleWide:n}){return(0,$.jsx)(_,{size:`icon`,variant:`ghost`,"aria-label":t?`Restore ${e} width`:`Widen ${e}`,"aria-pressed":t,title:t?`Restore width`:`Widen`,icon:t?(0,$.jsx)(f,{size:14}):(0,$.jsx)(te,{size:14}),onClick:n})}var Ej=200;function Dj({status:e,count:t,pressed:n,onToggle:r}){let i=GA(e),a=JA(e);return(0,$.jsxs)(`button`,{type:`button`,className:`inline-flex items-center gap-2.5 min-h-10.5 px-3 py-0.5 border rounded-chip bg-surface-1 font-sans text-micro font-semibold leading-none whitespace-nowrap cursor-pointer ${n?`border-current`:`border-inner-border text-text-secondary hover:border-current`} ${a===`ok`?`text-green`:a===`warn`?`text-orange`:`text-red`} ${n?``:`hover:bg-surface-muted`}`,"data-tone":a,"aria-pressed":n,"aria-label":`Filter ${i}: ${y(t)} requests`,title:`Show ${y(t)} requests with HTTP ${i}`,onClick:()=>r(e),children:[(0,$.jsx)(`span`,{children:i}),(0,$.jsxs)(`span`,{className:`font-mono tabular-nums opacity-65`,"aria-hidden":`true`,children:[`· `,y(t)]})]})}function Oj({counts:e,active:t,onToggle:n}){let[r,i]=(0,R.useState)(!1),a=(0,R.useRef)(null),o=e.filter(e=>e.count>0),s=o.filter(e=>e.status===Ej),c=o.filter(e=>e.status!==Ej),l=c.reduce((e,t)=>e+t.count,0),u=c.some(e=>e.status===t);return(0,R.useEffect)(()=>{if(!r)return;let e=e=>{a.current&&!a.current.contains(e.target)&&i(!1)},t=e=>{e.key===`Escape`&&i(!1)};return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[r]),o.length===0?null:(0,$.jsxs)(`div`,{className:`inline-flex items-center flex-wrap gap-2`,role:`group`,"aria-label":`Filter requests by HTTP status`,children:[s.map(e=>(0,$.jsx)(Dj,{status:e.status,count:e.count,pressed:t===e.status,onToggle:n},e.status)),c.length>0?(0,$.jsxs)(`div`,{ref:a,className:`relative`,children:[(0,$.jsxs)(`button`,{type:`button`,className:`inline-flex items-center gap-2.5 min-h-10.5 px-3 py-0.5 border rounded-chip bg-surface-1 font-sans text-micro font-semibold leading-none whitespace-nowrap cursor-pointer ${u?`border-current`:`border-inner-border text-text-secondary hover:border-current hover:bg-surface-muted`} ${u?JA(t??0)===`ok`?`text-green`:JA(t??0)===`warn`?`text-orange`:`text-red`:``}`,"data-tone":u?JA(t??0):void 0,"aria-pressed":u,"aria-expanded":r,"aria-haspopup":`menu`,"aria-label":`More statuses: ${y(l)} requests across ${c.length}`,onClick:()=>i(e=>!e),children:[(0,$.jsx)(`span`,{children:`More`}),(0,$.jsxs)(`span`,{className:`font-mono tabular-nums opacity-65`,"aria-hidden":`true`,children:[`· `,y(l)]}),(0,$.jsx)(he,{size:10,"aria-hidden":`true`,className:b(`transition-transform`,r&&`rotate-180`)})]}),r?(0,$.jsx)(`div`,{role:`menu`,"aria-label":`Other HTTP statuses`,className:`absolute top-full z-50 mt-1 right-0 min-w-90 flex flex-col gap-1 border border-inner-border rounded-control bg-popover-bg shadow-popout p-2`,children:c.map(e=>(0,$.jsx)(`div`,{role:`none`,className:`[&>button]:w-full [&>button]:justify-between`,children:(0,$.jsx)(Dj,{status:e.status,count:e.count,pressed:t===e.status,onToggle:e=>{n(e),i(!1)}})},e.status))}):null]}):null]})}function kj({period:e,metric:t}){let n=de(e),r=_e(),i=(0,R.useMemo)(()=>(n.data?.buckets??[]).map(e=>({...e,total:e.input+e.output})),[n.data]),a=t===`requests`?`requests`:t===`cached`?`cached`:`total`,o=i.some(e=>e[a]>0);return n.isPending&&!o?(0,$.jsx)(M,{label:`Loading chart…`}):n.isError&&!o?(0,$.jsx)(j,{message:`Failed to load chart data.`,onRetry:()=>void n.refetch()}):o?(0,$.jsx)(`div`,{className:`usage-panel-body h-113.5 w-full`,children:(0,$.jsx)(qc,{width:`100%`,height:`100%`,children:(0,$.jsxs)(PA,{data:i,margin:{top:8,right:8,left:-14,bottom:0},children:[(0,$.jsx)(`defs`,{children:(0,$.jsxs)(`linearGradient`,{id:`usageChartFill`,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[(0,$.jsx)(`stop`,{offset:`0%`,stopColor:`var(--accent)`,stopOpacity:.45}),(0,$.jsx)(`stop`,{offset:`100%`,stopColor:`var(--accent)`,stopOpacity:.02})]})}),(0,$.jsx)(cO,{stroke:`var(--inner-border)`,strokeDasharray:`3 3`,vertical:!1}),(0,$.jsx)(JO,{dataKey:`t`,tick:{fontSize:10,fill:`var(--text-tertiary)`},tickFormatter:e=>ZA(e),axisLine:!1,tickLine:!1,minTickGap:28}),(0,$.jsx)(dk,{tick:{fontSize:10,fill:`var(--text-tertiary)`},axisLine:!1,tickLine:!1,tickFormatter:e=>De(e),width:48}),(0,$.jsx)(Oc,{contentStyle:{background:`var(--surface-2)`,border:`1px solid var(--inner-border)`,borderRadius:12,fontSize:12,color:`var(--text-primary)`},formatter:e=>[y(Number(e)),t],labelFormatter:e=>QA(String(e))}),(0,$.jsx)(jO,{type:`monotone`,dataKey:a,stroke:`var(--accent)`,strokeWidth:2,fill:`url(#usageChartFill)`,isAnimationActive:!r,animationDuration:250})]})})}):(0,$.jsx)(N,{title:`No usage for this period`,message:`Route requests to populate the usage.`})}function Aj({period:e,dimension:t,onDimensionChange:n,wide:r,onToggleWide:i}){let a=ue(e,t),o=pe(),s=(0,R.useMemo)(()=>new Map((o.data??[]).map(e=>[e.providerId,e.label||e.displayName])),[o.data]),c=a.data?.dimension===t?a.data.rows:[],l=c.length>0?Math.max(...c.map(e=>e.total)):1,u=c.reduce((e,t)=>e+t.requests,0),d=c.reduce((e,t)=>e+t.errors,0),f=(()=>{if(a.isPending&&c.length===0)return`Loading…`;if(c.length===0)return`No traffic in this period`;let e=Math.max(0,u-d),t=u>0?Math.round(e/u*100):0,n=c.length===1?`group`:`groups`;return`${c.length} ${n} · ${y(u)} hits · ${t}% ok`})();return(0,$.jsxs)(be,{className:r?`col-span-full`:``,children:[(0,$.jsx)(ye,{title:`Breakdown`,subtitle:f,icon:(0,$.jsx)(ie,{size:16}),leading:(0,$.jsx)(Tj,{label:`Breakdown`,wide:r,onToggleWide:i}),action:(0,$.jsx)(wj,{ariaLabel:`Breakdown dimension`,value:t,onChange:n,options:[{id:`model`,label:`Model`},{id:`provider`,label:`Provider`},{id:`client`,label:`Client`},{id:`client_ip`,label:`Client IP`},{id:`key`,label:`Key`}]})}),(0,$.jsx)(ve,{style:{height:`${$A}px`},children:a.isPending&&c.length===0?(0,$.jsx)(M,{label:`Loading breakdown…`}):a.isError&&c.length===0?(0,$.jsx)(j,{message:`Failed to load breakdown.`,onRetry:()=>void a.refetch()}):c.length===0?(0,$.jsx)(N,{title:`No usage for this period`,message:`Route requests to populate the breakdown.`}):(0,$.jsx)(`div`,{className:`scroll-region flex h-full flex-col gap-4 pr-1`,children:c.map(e=>{let n=l>0?Math.max(2,e.total/l*100):2,r=t===`provider`?s.get(e.name)??e.name:t===`key`?e.label??`${e.name.slice(0,8)}…`:e.name,i=Math.max(0,e.requests-e.errors);return(0,$.jsxs)(`div`,{title:`${r} · ${y(e.requests)} hits · ${y(i)} ok · ${y(e.total)} tokens · ${lj(e.costUsd)}`,className:`relative shrink-0 overflow-hidden rounded-control border border-inner-border bg-surface-2`,children:[(0,$.jsx)(`div`,{"aria-hidden":`true`,className:`absolute inset-0 bg-[linear-gradient(to_right,color-mix(in_srgb,var(--accent)_20%,transparent),transparent)]`,style:{width:`${n}%`}}),(0,$.jsxs)(`div`,{className:`relative flex items-center justify-between gap-4 px-6 py-5`,children:[(0,$.jsx)(`span`,{className:`truncate font-mono tabular-nums min-w-0 flex-1 text-badge font-semibold`,children:r}),` `,(0,$.jsxs)(`span`,{className:`font-mono tabular-nums shrink-0 text-micro text-text-secondary`,children:[y(e.requests),` hit · `,y(i),` ok`]}),(0,$.jsx)(`span`,{className:`shrink-0 text-badge font-bold text-orange`,children:lj(e.costUsd)}),(0,$.jsx)(`span`,{className:`shrink-0 text-badge font-bold text-purple`,children:De(e.total)})]})]},e.name)})})})]})}function jj({title:e,meta:t,icon:n,tone:r,last:i}){return(0,$.jsxs)(`div`,{className:`flex gap-5 min-w-0`,children:[(0,$.jsxs)(`div`,{className:`flex flex-col items-center shrink-0`,children:[(0,$.jsx)(`span`,{"aria-hidden":`true`,className:`grid place-items-center w-11 h-11 rounded-pill`,style:{color:r??`var(--accent)`,background:`color-mix(in srgb, ${r??`var(--accent)`} 16%, var(--surface-2))`},children:n}),i?null:(0,$.jsx)(`span`,{"aria-hidden":`true`,className:`w-1 flex-1 min-h-7 bg-inner-border`})]}),(0,$.jsxs)(`div`,{className:`min-w-0 flex-1`,style:{paddingBottom:i?0:`12px`},children:[(0,$.jsx)(`div`,{className:`text-caption font-bold`,children:e}),(0,$.jsx)(`div`,{className:`select-text mt-1 whitespace-pre-line text-badge text-text-secondary [overflow-wrap:anywhere] break-words`,children:t})]})]})}function Mj({requestId:e,onClose:t}){let n=fe(e),r=n.data,i=P(r?.providerId),a=e=>{let t=e?.accountId;return t?(i.data??[]).find(e=>e.id===t)?.label||`${t.slice(0,8)}…`:`—`},o=r?.apiKeyLabel??(r?.apiKeyId?`${r.apiKeyId.slice(0,8)}…`:`—`),s=r?.userAgent===`Cartethyia Probe`?`Probe`:o,[l,f]=(0,R.useState)(!1),[v,x]=(0,R.useState)(null),[E,O]=(0,R.useState)(!1),[k,M]=(0,R.useState)(!1),N=p(),te=Pe(),re=()=>{navigator.clipboard?.writeText(r?.requestId??``),f(!0),te(()=>f(!1),1500)},ae=(e,t)=>{let n=typeof t==`string`?t:JSON.stringify(t,null,2);navigator.clipboard?.writeText(n),x(e),te(()=>x(null),1500)},ce=async()=>{if(r){O(!0);try{let e=await se(`/system/usage/requests/${encodeURIComponent(r.requestId)}/download`);xe(`telemetry-${r.requestId}.json`,JSON.stringify(e,null,2),`application/json`)}catch(e){C.error(oe(e,`Could not download telemetry.`))}finally{O(!1)}}},le=async(e=IA)=>{if(r?.clientIp){M(!1);try{let t=await N.mutateAsync({ip:r.clientIp,apiKeyId:r.apiKeyId??null,minutes:e.minutes});C.success(`Banned ${r.clientIp}${t.ban.apiKeyId?` for this key`:` for every key`} — ${e.label}.`)}catch(e){C.error(oe(e,`Could not ban the address.`))}}},ue=(0,R.useMemo)(()=>[`request`,`clientResponse`,`providerRequest`,`providerResponse`].map(e=>{let t=r?.payloads?.[e];if(t===void 0)return{kind:e,text:null,bytes:null};try{let n=ej(t);return{kind:e,text:n.text,bytes:n.bytes}}catch{return{kind:e,text:null,bytes:null}}}),[r?.payloads]),de=e=>ue.find(t=>t.kind===e)??{kind:e,text:null,bytes:null};return(0,$.jsx)(u,{open:e!==null,onClose:t,title:`Request Detail`,children:n.isPending?(0,$.jsxs)(ke,{gap:`12px`,children:[(0,$.jsx)(`div`,{className:`animate-pulse h-12 w-[66%] rounded-inset bg-surface-2`}),(0,$.jsx)(`div`,{className:`animate-pulse h-48 rounded-control bg-surface-2`}),(0,$.jsx)(`div`,{className:`animate-pulse h-48 rounded-control bg-surface-2`})]}):n.isError||!r?(0,$.jsx)(j,{compact:!0,message:oe(n.error,`Failed to load request detail.`),onRetry:()=>void n.refetch()}):(0,$.jsxs)(ke,{gap:`12px`,children:[(0,$.jsxs)(`div`,{className:`flex items-center gap-4 rounded-control border border-inner-border bg-surface-2 px-6 py-4 min-w-0`,children:[(0,$.jsxs)(`span`,{className:`select-text font-mono tabular-nums min-w-0 flex-1 [overflow-wrap:anywhere] break-words text-badge`,title:r.requestId,children:[`request_id `,r.requestId]}),(0,$.jsx)(_,{variant:`ghost`,size:`sm`,icon:l?(0,$.jsx)(h,{size:12}):(0,$.jsx)(m,{size:12}),"aria-label":`Copy request ID`,title:`Copy request ID`,onClick:re,className:`shrink-0 p-1.5`})]}),(0,$.jsxs)(`div`,{className:`grid grid-cols-2 gap-2`,children:[(0,$.jsxs)(`div`,{className:`relative w-full`,children:[(0,$.jsxs)(`div`,{className:`flex w-full`,children:[(0,$.jsx)(_,{variant:`secondary`,size:`sm`,icon:(0,$.jsx)(d,{size:13}),disabled:!r.clientIp||N.isPending,title:r.clientIp?`Ban ${r.clientIp} for this API key for ${IA.label}`:`No client IP recorded for this request`,onClick:()=>void le(),className:`min-w-0 flex-1 rounded-r-none`,children:`Banned User`}),(0,$.jsx)(`button`,{type:`button`,disabled:!r.clientIp||N.isPending,"aria-haspopup":`menu`,"aria-expanded":k,"aria-label":`Choose how long to ban this user`,title:`Choose how long to ban this user`,onClick:()=>M(e=>!e),className:`grid place-items-center px-2 border border-l-0 border-inner-border rounded-r-control bg-surface-1 text-text-secondary hover:bg-surface-muted hover:text-text-primary cursor-pointer disabled:opacity-50 disabled:cursor-not-allowed`,children:(0,$.jsx)(he,{size:12,"aria-hidden":`true`})})]}),k?(0,$.jsxs)(`div`,{role:`menu`,"aria-label":`Ban duration`,className:`absolute bottom-full left-0 z-50 mb-1 min-w-36 flex flex-col gap-0.5 border border-inner-border rounded-control bg-popover-bg shadow-popout p-1.5`,children:[FA.map(e=>(0,$.jsx)(`button`,{type:`button`,role:`menuitem`,onClick:()=>void le(e),className:`px-2.5 py-1.5 text-left text-caption text-text-secondary rounded-inset hover:bg-hover-bg hover:text-text-primary cursor-pointer whitespace-nowrap`,children:e.label},e.label)),(0,$.jsx)(`p`,{className:`px-2.5 pb-0.5 pt-1.5 text-micro leading-snug text-text-tertiary`,children:`Scoped to this request's API key. Other keys from this IP are unaffected.`})]}):null]}),(0,$.jsx)(_,{variant:`secondary`,size:`sm`,icon:(0,$.jsx)(g,{size:13}),disabled:E,title:`Download all captured telemetry for this request as JSON`,onClick:()=>void ce(),className:`w-full`,children:`Download telemetry`})]}),r.errorKind?(0,$.jsxs)(Fe,{tone:`danger`,live:`alert`,className:`flex flex-col gap-2 [overflow-wrap:anywhere] break-words`,children:[(0,$.jsx)(`strong`,{className:`text-caption`,children:Sj(r.status,r.errorKind,r.errorOrigin,r.httpStatus)}),(0,$.jsx)(`span`,{className:`font-mono tabular-nums text-text-tertiary text-micro [overflow-wrap:anywhere]`,children:r.errorKind})]}):null,(0,$.jsxs)(`section`,{className:`border border-inner-border rounded-control overflow-hidden`,children:[(0,$.jsx)(`div`,{className:`border-b border-inner-border px-6 py-5 text-caption font-bold`,children:`Flow and Detail`}),(0,$.jsxs)(`div`,{className:`flex flex-col p-6`,children:[(0,$.jsx)(jj,{icon:(0,$.jsx)(ee,{size:13}),title:`Client request in`,meta:`Client IP : ${r.clientIp??`—`}\n${r.clientName??`—`} · ${r.userAgent??`—`} · ${r.surface??`—`} · ${r.mode===`stream`?`streaming`:`non-streaming`}`}),(0,$.jsx)(jj,{icon:(0,$.jsx)(ne,{size:13}),title:`Gateway`,meta:`${S(r.durationMs)} total · TTFT ${S(r.ttfbMs)} · ${dj(r.tokensPerSec)} · ${r.cachedTokens===void 0?`—`:y(r.cachedTokens)} from cache`}),(0,$.jsx)(jj,{icon:(0,$.jsx)(me,{size:13}),title:`Upstream · ${r.providerId??`—`}`,meta:`${[a(r),r.model??`—`].filter(e=>e!==`—`).join(` · `)||`—`}\nApi Key : ${s}\nProxy : ${r.proxy??`direct`}`}),(0,$.jsx)(jj,{icon:(0,$.jsx)(T,{size:13}),last:!0,title:`Response out`,meta:`${gj(r.status,r.httpStatus).code}${de(`clientResponse`).bytes===null?``:` · ${w(de(`clientResponse`).bytes)}`}${r.estimatedCost?` · ${lj(r.estimatedCost)}`:``}`,tone:Cj[gj(r.status,r.httpStatus).tone]})]})]}),(()=>{let e=r.payloadSignals,t=[{label:`Tool calls`,value:e?.toolCalls??`—`,icon:ie},{label:`Images`,value:e?.images??`—`,icon:A},{label:`Attachments`,value:e?.attachments??`—`,icon:c}];return(0,$.jsx)(`section`,{"aria-label":`Session signals`,className:`signal-grid grid gap-4 border border-inner-border rounded-control p-5 bg-surface-2`,children:t.map(({label:e,value:t,icon:n})=>(0,$.jsxs)(`div`,{className:`flex items-center gap-3.5 min-w-0 text-text-secondary`,children:[(0,$.jsx)(n,{size:14,"aria-hidden":`true`,className:`shrink-0 text-accent`}),(0,$.jsxs)(`span`,{className:`min-w-0 [overflow-wrap:anywhere] text-badge`,children:[e,`: `,(0,$.jsx)(`strong`,{className:`text-text-primary`,children:t})]})]},e))})})(),[[`request`,`1. Client Request (Input)`,r.payloads?.request,ee],[`providerRequest`,`2. Provider Request (Translated)`,r.payloads?.providerRequest,ne],[`providerResponse`,`3. Provider Response (Raw)`,r.payloads?.providerResponse,me],[`clientResponse`,`4. Client Response (Final)`,r.payloads?.clientResponse,T]].map(([e,t,n,r])=>(0,$.jsxs)(`details`,{className:`rounded-control border border-inner-border bg-surface-2 overflow-hidden`,children:[(0,$.jsxs)(`summary`,{className:`flex items-center justify-between gap-4 cursor-pointer px-6 py-5 text-caption font-bold`,children:[(0,$.jsxs)(`span`,{className:`inline-flex items-center gap-3.5 min-w-0`,children:[(0,$.jsx)(r,{size:14,className:b(`shrink-0`,e===`request`?`text-accent`:`text-green`)}),(0,$.jsx)(`span`,{className:`[overflow-wrap:anywhere] break-words`,children:t})]}),(0,$.jsx)(`span`,{className:`font-mono tabular-nums shrink-0 text-text-tertiary text-micro font-medium`,children:w(de(e).bytes)})]}),n===void 0?(0,$.jsxs)(`div`,{className:`flex items-start gap-5 border-t border-inner-border bg-surface-1 px-6 py-7`,children:[(0,$.jsx)(D,{size:15,className:`shrink-0 text-text-tertiary mt-0.5`}),(0,$.jsxs)(`div`,{className:`min-w-0 flex flex-col gap-1.5`,children:[(0,$.jsx)(`strong`,{className:`text-caption text-text-secondary`,children:`No payload captured`}),(0,$.jsxs)(`span`,{className:`text-badge text-text-tertiary [overflow-wrap:anywhere] break-words`,children:[t,` is unavailable for this request.`]})]})]}):(0,$.jsxs)($.Fragment,{children:[(0,$.jsx)(`div`,{className:`flex justify-end border-t border-inner-border pt-2.5 px-4`,children:(0,$.jsx)(_,{variant:`ghost`,size:`sm`,icon:v===e?(0,$.jsx)(h,{size:11}):(0,$.jsx)(m,{size:11}),"aria-label":`Copy ${t}`,title:`Copy ${t}`,onClick:()=>ae(e,n),className:`p-1`})}),(0,$.jsx)(`pre`,{className:`select-text font-mono tabular-nums max-h-128 overflow-auto whitespace-pre-wrap [overflow-wrap:break-word] break-words m-0 border-t border-inner-border pt-4 px-6 pb-6 text-micro text-text-secondary`,children:de(e).text})]})]},e))]})})}function Nj({count:e,uniqueIps:t,live:n}){let r=e,i=t,a=r===1?`request`:`requests`,o=i===1?`IP`:`IPs`,s;return s=n?r===null||i===null?`Waiting for the first in-flight snapshot`:`${r} ${a} executing right now from ${i} unique client ${o} — all clients combined, not a summary of the table below`:`Live feed disconnected — last seen value`,(0,$.jsxs)(`span`,{title:s,className:`inline-flex items-center gap-3 text-badge text-text-secondary whitespace-nowrap`,children:[(0,$.jsx)(`span`,{"aria-hidden":`true`,className:`w-3.5 h-3.5 rounded-[50%] shrink-0`,style:{background:n?`var(--success)`:`var(--text-tertiary)`,boxShadow:n?`0 0 6px var(--success)`:`none`}}),(0,$.jsx)(`span`,{className:`font-mono tabular-nums font-bold text-text-primary`,children:r===null||i===null?`In-flight unavailable`:`${r} in flight · ${i} ${o}`})]})}var Pj=(0,R.createContext)({count:null,uniqueIps:null,live:!1});function Fj({children:e}){let t=Le(),n=(0,R.useMemo)(()=>({count:t.count,uniqueIps:t.uniqueIps,live:t.live}),[t.count,t.uniqueIps,t.live]);return(0,$.jsx)(Pj.Provider,{value:n,children:e})}function Ij(){let e=(0,R.useContext)(Pj);return(0,$.jsx)(Nj,{count:e.count,uniqueIps:e.uniqueIps,live:e.live})}function Lj({pending:e,requests:t}){let n=(0,R.useContext)(Pj);return(0,$.jsx)(je,{label:`Requests`,fit:!0,value:e?`…`:y(t),detail:n.count===null||n.uniqueIps===null?`In-flight unavailable`:`${n.count} in flight from ${n.uniqueIps} IPs`,icon:(0,$.jsx)(o,{size:13})})}function Rj({pending:e,avgMs:t,p50Ms:n,p95Ms:r,p99Ms:i,latencySampleCount:a,resolveSampleCount:o,periodLabel:s}){if(e)return null;let c=`Resolve — average time from request arrival to just before the upstream is called (credential, admission, pool slot, preparation). Not response latency. ${s} · ${y(o??0)} requests with a resolve measurement.`,l=(e,t)=>`${e} — the ${t} of total request duration (arrival to final byte), nearest rank. ${s} · from ${y(a??0)} requests.`,u=[{label:`Resolve`,value:t,title:c},{label:`P50`,value:n,title:l(`P50`,`median`)},{label:`P95`,value:r,title:l(`P95`,`95th percentile`)},{label:`P99`,value:i,title:l(`P99`,`99th percentile`)}];return(0,$.jsxs)(`div`,{role:`group`,"aria-label":`Routing latency summary`,className:`flex flex-wrap items-center gap-x-6 gap-y-3 border-b border-inner-border px-6 py-5 text-badge`,children:[(0,$.jsx)(ne,{size:12,"aria-hidden":`true`,className:`shrink-0 text-text-secondary`}),u.map(e=>(0,$.jsxs)(`span`,{title:e.title,className:`inline-flex items-baseline gap-1.5 font-mono tabular-nums leading-none text-caption`,children:[(0,$.jsx)(`span`,{className:`font-semibold tracking-label uppercase text-text-tertiary`,children:e.label}),(0,$.jsx)(`span`,{className:`font-semibold text-text-secondary`,children:S(e.value)})]},e.label))]})}function zj({label:e,value:t,scale:n,onChange:r}){let i=t==null||!Number.isFinite(t)?null:Te(t);if(i===null||i>=Se)return null;let a=n===-1?Math.min(i+1,Se):n>=Se?-1:n+1,o=n===-1?we[i]?.suffix??`raw`:n>=Se?`raw`:we[n]?.suffix??`raw`,s=a===-1?`default unit`:a>=Se?`exact count`:we[a]?.suffix;return(0,$.jsxs)(`button`,{type:`button`,"aria-label":`${e}: currently ${o}, switch to ${s}`,title:`Show ${s}`,onClick:()=>r(a),className:`font-mono tabular-nums inline-flex items-center gap-2 px-3.5 py-1.5 border border-inner-border rounded-pill bg-surface-2 text-text-secondary cursor-pointer text-micro font-bold tracking-[0.04em] leading-[1]`,children:[(0,$.jsx)(re,{size:11,"aria-hidden":`true`}),o]})}function Bj(e,t,n){let r=new URLSearchParams(e);return r.set(t,n),r}function Vj(e,t){let n=new Set(e);return n.has(t)?n.delete(t):n.add(t),n}function Hj(){let[e,t]=ge(),n=aj(e.get(`period`)),r=oj(e.get(`metric`)),i=cj(e.get(`dim`)),a=sj(e.get(`scale`)),[c,u]=(0,R.useState)(()=>new Set),d=(e,t)=>{e(e=>Vj(e,t))},[f,p]=(0,R.useState)(null),{enabled:m,setEnabled:h}=Ne(),[g,v]=(0,R.useState)(()=>{try{return localStorage.getItem(`cartethyia:usage:hide-provider`)===`true`}catch{return!1}}),b=()=>{v(e=>{let t=!e;try{localStorage.setItem(`cartethyia:usage:hide-provider`,String(t))}catch{}return t})},x=le(n),C=pe(),w=(0,R.useMemo)(()=>new Map((C.data??[]).map(e=>[e.providerId,e.label||e.displayName])),[C.data]),[T,A]=(0,R.useState)(50),[ee,te]=(0,R.useState)(null),ne=ce(n,T,ee);Ie();let re=(0,R.useRef)(0),[ie,ae]=(0,R.useState)(`startedAt`),[oe,se]=(0,R.useState)(`desc`),ue=e=>{ae(t=>t===e?(se(e=>e===`asc`?`desc`:`asc`),t):(se(e===`model`?`asc`:`desc`),e))},de=(0,R.useRef)(new Set),[fe,me]=(0,R.useState)(new Set);(0,R.useEffect)(()=>{let e=ne.data?.items??[];if(e.length===0)return;let t=de.current;if(t.size===0){for(let n of e)t.add(n.requestId);return}let n=new Set;for(let r of e)t.has(r.requestId)||(t.add(r.requestId),n.add(r.requestId));if(n.size>0){me(e=>new Set([...e,...n]));let e=window.setTimeout(()=>{me(e=>{let t=new Set(e);for(let e of n)t.delete(e);return t})},3e3);return()=>window.clearTimeout(e)}},[ne.data?.items]);let he=e=>{let t=e.currentTarget;re.current=t.scrollTop,t.scrollHeight-t.scrollTop-t.clientHeight<40&&!ne.isFetching&&_e.length>=T&&T<500&&A(e=>e+50)},P=x.data?.totals,_e=(0,R.useMemo)(()=>{let e=[...ne.data?.items??[]],t=oe===`asc`?1:-1,n=e=>typeof e==`number`&&Number.isFinite(e)?e:-1;return e.sort((e,r)=>{switch(ie){case`model`:return`${e.providerId??``}/${e.model??``}`.localeCompare(`${r.providerId??``}/${r.model??``}`)*t||e.startedAt.localeCompare(r.startedAt)*-1;case`status`:return((e.httpStatus??0)-(r.httpStatus??0))*t||e.startedAt.localeCompare(r.startedAt)*-1;case`tokens`:return((e.totalTokens??0)-(r.totalTokens??0))*t||e.startedAt.localeCompare(r.startedAt)*-1;case`tps`:return(n(e.tokensPerSec)-n(r.tokensPerSec))*t||e.startedAt.localeCompare(r.startedAt)*-1;case`ttft`:return(n(e.ttfbMs)-n(r.ttfbMs))*t||e.startedAt.localeCompare(r.startedAt)*-1;case`duration`:return(n(e.durationMs)-n(r.durationMs))*t||e.startedAt.localeCompare(r.startedAt)*-1;default:return e.startedAt.localeCompare(r.startedAt)*t}}),e},[ne.data?.items,ie,oe]);(0,R.useLayoutEffect)(()=>{let e=document.getElementById(`usage-requests-scroll`);e!==null&&(e.scrollTop=Math.min(re.current,e.scrollHeight))},[_e.length]);let xe=()=>{re.current=0},Se=e=>{xe(),A(50),te(t=>t===e?null:e)},we=(e,n)=>{t(t=>Bj(t,e,n),{replace:!0})},Te=e=>{t(t=>{let n=new URLSearchParams(t);return e===Ee?n.delete(`scale`):e===-1?n.set(`scale`,`auto`):n.set(`scale`,String(e)),n},{replace:!0})};return(0,$.jsx)(Fj,{children:(0,$.jsxs)(ke,{gap:`16px`,children:[(0,$.jsxs)(be,{children:[(0,$.jsx)(ye,{title:`Usage`,subtitle:ij(n,x.isPending,P),icon:(0,$.jsx)(o,{size:16})}),(0,$.jsxs)(ve,{className:`flex flex-col gap-8`,children:[(0,$.jsxs)(`div`,{className:`metric-grid grid gap-7 w-full min-w-0`,children:[(0,$.jsx)(Lj,{pending:x.isPending,requests:P?.requests}),(0,$.jsx)(je,{label:`Input tokens`,fit:!0,value:x.isPending?`…`:Ce(P?.inputTokens,a),detail:`Prompt tokens`,tone:`accent`,action:(0,$.jsx)(zj,{label:`Input tokens scale`,value:P?.inputTokens,scale:a,onChange:Te})}),(0,$.jsx)(je,{label:`Cached tokens`,fit:!0,value:x.isPending?`…`:Ce(P?.cachedTokens,a),detail:x.isPending?`Cache hit rate`:`${P?.cacheHitRate===void 0?0:Math.round(P.cacheHitRate*10)/10}% cache hit rate`,tone:`purple`,icon:(0,$.jsx)(D,{size:13}),action:(0,$.jsx)(zj,{label:`Cached tokens scale`,value:P?.cachedTokens,scale:a,onChange:Te})}),(0,$.jsx)(je,{label:`Output tokens`,fit:!0,value:x.isPending?`…`:Ce(P?.outputTokens,a),detail:`Completion tokens`,icon:(0,$.jsx)(Re,{size:13}),action:(0,$.jsx)(zj,{label:`Output tokens scale`,value:P?.outputTokens,scale:a,onChange:Te})}),(0,$.jsx)(je,{label:`Est. cost`,value:x.isPending?`…`:lj(P?.estimatedCostUsd),detail:`Estimated not billing`,tone:`orange`,icon:(0,$.jsx)(Be,{size:13})})]}),(0,$.jsxs)(`div`,{className:`grid grid-cols-2 gap-8 w-full min-w-0 max-medium:grid-cols-1`,children:[(0,$.jsx)(Aj,{period:n,dimension:i,onDimensionChange:e=>we(`dim`,e),wide:c.has(`breakdown`),onToggleWide:()=>d(u,`breakdown`)}),(0,$.jsxs)(be,{className:c.has(`traffic`)?`col-span-full`:``,children:[(0,$.jsx)(ye,{title:`Traffic`,subtitle:`Requests per bucket · ${rj(n)}`,icon:(0,$.jsx)(Ve,{size:16}),leading:(0,$.jsx)(Tj,{label:`Traffic`,wide:c.has(`traffic`),onToggleWide:()=>d(u,`traffic`)}),action:(0,$.jsxs)(Ae,{gap:`6px`,className:`flex-wrap`,children:[(0,$.jsx)(wj,{ariaLabel:`Traffic metric`,value:r,onChange:e=>we(`metric`,e),options:[{id:`requests`,label:`Requests`},{id:`tokens`,label:`Tokens`},{id:`cached`,label:`Cached`}]}),(0,$.jsx)(Oe,{"aria-label":`Period`,value:n,size:`sm`,className:`w-auto min-w-46 shrink-0 grow-0 basis-auto`,onValueChange:e=>we(`period`,e),options:nj.map(e=>({value:e.value,label:e.label}))})]})}),(0,$.jsx)(ve,{children:(0,$.jsx)(kj,{period:n,metric:r})})]})]})]})]}),(0,$.jsxs)(be,{children:[(0,$.jsx)(ye,{title:`Requests`,subtitle:`Most recent first · ${_e.length} entries · open a row to inspect`,subtitleAddon:(0,$.jsx)(Oj,{counts:P?.statusCounts??[],active:ee,onToggle:Se}),icon:(0,$.jsx)(o,{size:16}),action:(0,$.jsxs)(Ae,{gap:`12px`,align:`center`,className:`flex-wrap`,children:[(0,$.jsx)(_,{variant:`ghost`,size:`sm`,icon:g?(0,$.jsx)(O,{size:13}):(0,$.jsx)(k,{size:13}),onClick:b,title:g?`Show real provider names`:`Mask provider names as Mysterious`,className:`text-badge h-13 px-4 py-0 text-text-secondary`,children:g?`Provider masked`:`Mask provider`}),(0,$.jsx)(_,{variant:`ghost`,size:`sm`,icon:m?(0,$.jsx)(O,{size:13}):(0,$.jsx)(k,{size:13}),onClick:()=>h(!m),title:m?`Show client addresses`:`Hide client addresses`,className:`text-badge h-13 px-4 py-0 text-text-secondary`,children:m?`IP masked`:`Mask IP`}),(0,$.jsx)(Ij,{})]})}),(0,$.jsx)(ve,{className:`p-0`,children:ne.isPending&&_e.length===0?(0,$.jsx)(M,{compact:!0,label:`Loading requests…`}):ne.isError&&_e.length===0?(0,$.jsx)(j,{compact:!0,message:`Could not load recent requests.`,onRetry:()=>void ne.refetch()}):_e.length===0?(0,$.jsx)(N,{compact:!0,title:`No requests recorded for this period`,message:`Route requests through the gateway to populate the table.`,icon:(0,$.jsx)(o,{size:20})}):(0,$.jsxs)(`div`,{id:`usage-requests-scroll`,className:`rounded-control border border-inner-border bg-surface-1`,children:[(0,$.jsx)(Rj,{pending:x.isPending,avgMs:P?.avgResolveMs,p50Ms:P?.latencyP50Ms,p95Ms:P?.latencyP95Ms,p99Ms:P?.latencyP99Ms,latencySampleCount:P?.latencySampleCount,resolveSampleCount:P?.resolveSampleCount,periodLabel:rj(n)}),(0,$.jsx)(Me,{maxHeight:445,onScroll:he,headers:[{key:`startedAt`,label:`Time`,sortable:!0},{key:`model`,label:`Provider/model`,sortable:!0},{key:`apiKey`,label:`API Key`},{key:`status`,label:`Status`,sortable:!0},{key:`tokens`,label:`Tokens`,sortable:!0},{key:`tps`,label:`TPS`,sortable:!0},{key:`ttft`,label:`TTFT`,sortable:!0},{key:`duration`,label:`Done`,sortable:!0}],sortKey:ie,sortDirection:oe,onSort:e=>ue(e),children:_e.map(e=>{let t=fe.has(e.requestId),n=e.estimatedCost===void 0?`—`:lj(e.estimatedCost),r=LA(e.providerId,e.model);return(0,$.jsxs)(`tr`,{onClick:()=>p(e.requestId),className:`cursor-pointer transition-colors`,style:{background:t?`color-mix(in srgb, var(--accent) 14%, transparent)`:void 0},children:[(0,$.jsxs)(`td`,{className:`text-badge text-text-tertiary whitespace-nowrap`,children:[(0,$.jsx)(`div`,{children:fj(e.startedAt)}),(0,$.jsx)(`div`,{className:`text-micro mt-0.5`,children:hj(e.startedAt)})]}),(0,$.jsxs)(`td`,{className:`max-w-105`,children:[(0,$.jsx)(`div`,{className:`flex items-center gap-3 min-w-0`,children:(0,$.jsx)(`span`,{className:`truncate text-caption font-semibold`,title:r??`—`,children:g?`Mysterious`:r?w.get(r)??r:`—`})}),(0,$.jsx)(`div`,{className:`truncate font-mono text-badge text-text-tertiary mt-px`,title:e.model??`—`,children:g&&e.model&&e.model.includes(`/`)?e.model.slice(e.model.indexOf(`/`)+1):e.model??`—`}),e.reportedModel?(0,$.jsxs)(`div`,{className:`flex items-center gap-1.5 mt-px min-w-0 text-micro text-text-tertiary`,title:`Reported by upstream: ${e.reportedModel}`,children:[(0,$.jsx)(E,{size:10,"aria-hidden":`true`,className:`shrink-0`}),(0,$.jsx)(`span`,{className:`truncate font-mono`,children:e.reportedModel})]}):null]}),(0,$.jsxs)(`td`,{className:`max-w-70`,children:[(0,$.jsx)(`div`,{className:`truncate text-caption font-semibold`,title:BA(e),children:BA(e)}),(0,$.jsx)(`div`,{className:`truncate font-mono text-badge text-text-tertiary mt-px`,title:VA(e),children:VA(e)}),(0,$.jsx)(`div`,{className:`truncate font-mono text-badge text-text-tertiary mt-px`,title:m&&e.clientIp?`Client IP masked`:e.clientIp??`—`,children:e.clientIp?m?HA(e.clientIp):e.clientIp:`—`})]}),(0,$.jsxs)(`td`,{className:`whitespace-nowrap text-badge`,children:[(0,$.jsxs)(`div`,{children:[(0,$.jsx)(`span`,{className:`font-mono tabular-nums inline-block min-w-[13ch] text-text-secondary`,children:e.mode===`stream`?`streaming`:`non-streaming`}),` `,(0,$.jsx)(yj,{status:e.status,errorKind:e.errorKind,httpStatus:e.httpStatus})]}),(0,$.jsx)(`div`,{className:`flex items-center gap-2.5 mt-px`,"aria-label":`Captured payload stages`,children:mj.map(({key:t,bit:n,label:r,icon:i})=>{let a=e.payloadStages!==void 0&&(e.payloadStages&n)!==0;return(0,$.jsx)(`span`,{title:a?`${r} · captured`:`${r} · not captured`,className:a?`text-accent`:`text-text-tertiary opacity-45`,children:(0,$.jsx)(i,{size:11,"aria-hidden":`true`})},t)})}),(0,$.jsx)(`div`,{className:`truncate font-mono text-badge text-text-tertiary mt-px max-w-110`,title:pj(e.surface),children:pj(e.surface)})]}),(0,$.jsxs)(`td`,{className:`font-mono text-badge whitespace-nowrap text-right tabular-nums`,children:[(0,$.jsxs)(`div`,{className:`flex gap-6 justify-end`,children:[(0,$.jsxs)(`span`,{className:`inline-flex items-center gap-2 text-text-secondary`,children:[(0,$.jsx)(l,{size:10,"aria-label":`Input tokens`}),` IN `,y(e.inputTokens)]}),(0,$.jsxs)(`span`,{className:`inline-flex items-center gap-2 text-text-secondary`,children:[(0,$.jsx)(s,{size:10,"aria-label":`Output tokens`}),` OUT `,y(e.outputTokens)]})]}),(0,$.jsxs)(`div`,{className:`flex gap-6 justify-end mt-0.5 text-text-tertiary`,title:e.estimatedCost===void 0?`Unpriced model — no catalog rate`:void 0,children:[(0,$.jsxs)(`span`,{className:`inline-flex items-center gap-2`,children:[(0,$.jsx)(D,{size:10,"aria-label":`Cached tokens`}),` CACHED `,y(e.cachedTokens??0)]}),(0,$.jsxs)(`span`,{className:`inline-flex items-center gap-2`,children:[(0,$.jsx)(Be,{size:10,"aria-label":`Estimated cost`}),` COST `,n]}),e.creditUsed===void 0?null:(0,$.jsxs)(`span`,{className:`inline-flex items-center gap-2`,title:`Provider-billed credits for this turn`,children:[(0,$.jsx)(ze,{size:10,"aria-label":`Credits used`}),` `,uj(e.creditUsed)]})]})]}),(0,$.jsx)(`td`,{className:`font-mono text-caption text-right text-text-secondary whitespace-nowrap`,children:dj(e.tokensPerSec)}),(0,$.jsxs)(`td`,{className:`font-mono text-caption text-right text-text-secondary`,children:[(0,$.jsx)(`div`,{children:S(e.ttfbMs)}),e.resolveMs===void 0?null:(0,$.jsxs)(`div`,{className:`text-micro mt-0.5 text-text-tertiary`,title:`Gateway-side time before the upstream dispatch began`,children:[`(`,S(e.resolveMs),`)`]})]}),(0,$.jsx)(`td`,{className:`font-mono text-caption text-right text-text-secondary`,children:S(e.durationMs)})]},e.requestId)})})]})})]}),(0,$.jsx)(Mj,{requestId:f,onClose:()=>p(null)})]})})}export{Hj as default,hj as formatAgo,uj as formatCredit,pj as surfaceFamilyLabel,Vj as toggleInSet,Bj as withParam};
|