promptfoo 0.121.1 → 0.121.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/{accounts-BgNJDBE6.js → accounts-B0pgC1oV.js} +4 -4
- package/dist/src/{accounts-CMqkzrVf.js → accounts-Bm2D8Db9.js} +5 -5
- package/dist/src/{accounts-xrUGFA6n.js → accounts-CiBLOnA7.js} +4 -4
- package/dist/src/{accounts-Bx-x3bmW.cjs → accounts-gtkH-5KX.cjs} +4 -4
- package/dist/src/{agentic-utils-BKIN5PKu.js → agentic-utils-DS1g3GLF.js} +2 -2
- package/dist/src/{agents-CVIn-Utx.js → agents-9qiOy0ho.js} +6 -6
- package/dist/src/{agents-CXknwsFX.js → agents-CBr9A01V.js} +2 -2
- package/dist/src/{agents-aF4-T121.js → agents-CmvBq8LV.js} +6 -6
- package/dist/src/{agents-Dy2YpZpa.js → agents-D__IdAlg.js} +3 -3
- package/dist/src/{agents-B0f4HICh.cjs → agents-DbRtpYxR.cjs} +2 -2
- package/dist/src/{agents-C-dDThPK.js → agents-DgF2zDag.js} +2 -2
- package/dist/src/{agents-CErsqg5U.cjs → agents-Di9DKPzn.cjs} +6 -6
- package/dist/src/{agents-DeH4Gu94.js → agents-cLXA8a_8.js} +7 -7
- package/dist/src/{aimlapi-DHRKlBEA.js → aimlapi-B4rcnZgv.js} +9 -9
- package/dist/src/{aimlapi-tg0Gkcvr.cjs → aimlapi-BvlNH0gr.cjs} +9 -9
- package/dist/src/{aimlapi-BAGZDo5G.js → aimlapi-CnkC2HqE.js} +10 -10
- package/dist/src/{aimlapi-BNfTBexL.js → aimlapi-DHJU_kcV.js} +9 -9
- package/dist/src/app/assets/{index-BFCZg7hQ.js → index-4LKxG2CG.js} +84 -84
- package/dist/src/app/assets/{index-NCn4eVBv.css → index-C3zcsZFQ.css} +1 -1
- package/dist/src/app/assets/vendor-charts-BnDWwBlI.js +36 -0
- package/dist/src/app/index.html +3 -3
- package/dist/src/app/tsconfig.app.tsbuildinfo +1 -0
- package/dist/src/{audio-CHQ4r-RV.js → audio-Bkv46et0.js} +3 -3
- package/dist/src/{audio-BWeaWovU.cjs → audio-CGMyULza.cjs} +3 -3
- package/dist/src/{audio-tf_NBjlC.js → audio-ClI_AFre.js} +3 -3
- package/dist/src/{audio-BRODU0UK.js → audio-Dz3z7s3J.js} +4 -4
- package/dist/src/{base-DBtwl2FR.cjs → base-CGrhspbK.cjs} +2 -2
- package/dist/src/{base-fEDN28WM.js → base-CpjcHe4e.js} +2 -2
- package/dist/src/{base-B0tcrnq_.js → base-DLKtKMFh.js} +2 -2
- package/dist/src/{base-B4QJRyFS.js → base-Dy1V8--Z.js} +2 -2
- package/dist/src/{blobs-qTYm-1PY.js → blobs-BDbfYdrJ.js} +2 -2
- package/dist/src/{blobs-Bpg5rH6i.js → blobs-CBO20krR.js} +2 -2
- package/dist/src/{blobs-BAU-dXan.js → blobs-CMHN0Qcz.js} +2 -2
- package/dist/src/{blobs-DvS-O6be.cjs → blobs-D23XLin-.cjs} +2 -2
- package/dist/src/{cache-CG0SlR1d.js → cache-BVeDlD87.js} +74 -57
- package/dist/src/{cache-8XhNqPKW.js → cache-C4Nxf52C.js} +74 -57
- package/dist/src/{cache-Bbn1Nyrd.cjs → cache-CeUpFm3M.cjs} +2 -2
- package/dist/src/{cache-COish3-W.cjs → cache-Dh5WtQps.cjs} +74 -57
- package/dist/src/{cache-D3eqDYGU.js → cache-i1P6crbO.js} +74 -57
- package/dist/src/cache-n-RCJ-hL.js +6 -0
- package/dist/src/{chat-CRWNNq73.js → chat-BiKyneZl.js} +10 -8
- package/dist/src/{chat-2K608PeQ.cjs → chat-C1Qst7jL.cjs} +8 -8
- package/dist/src/{chat-CM_kyI8B.js → chat-C2jrdPMx.js} +8 -8
- package/dist/src/{chat-DaqekjFr.cjs → chat-CgF-J-Jj.cjs} +10 -8
- package/dist/src/{chat-DHMH-N64.js → chat-CzkrVDfz.js} +8 -8
- package/dist/src/{chat-BKm79wib.js → chat-DJIw17u0.js} +10 -8
- package/dist/src/{chat-CznLWr_D.js → chat-DqxYYtWA.js} +10 -8
- package/dist/src/{chat-DxysjBvt.js → chat-qmatte1u.js} +9 -9
- package/dist/src/{claude-agent-sdk-BLTu0WBO.js → claude-agent-sdk-Apiy0iaz.js} +8 -8
- package/dist/src/{claude-agent-sdk-D6_k9FKA.js → claude-agent-sdk-D2bJee9S.js} +8 -8
- package/dist/src/{claude-agent-sdk-CJH22shf.cjs → claude-agent-sdk-D9Z5Pr9X.cjs} +8 -8
- package/dist/src/{claude-agent-sdk-Dy5lT-Tx.js → claude-agent-sdk-DfCoW0E6.js} +9 -9
- package/dist/src/{cloud-DmE0EwsY.js → cloud-BBh91EUK.js} +1 -1
- package/dist/src/{cloud-Bc9526yV.js → cloud-C0dlstV_.js} +2 -2
- package/dist/src/{cloudflare-ai-C9r2sRhw.js → cloudflare-ai-8TDxHR0x.js} +9 -9
- package/dist/src/{cloudflare-ai-ICsOuD-z.js → cloudflare-ai-BxAGvfju.js} +10 -10
- package/dist/src/{cloudflare-ai-ClWSdor4.cjs → cloudflare-ai-CknbZ5LJ.cjs} +9 -9
- package/dist/src/{cloudflare-ai-CWWJCRim.js → cloudflare-ai-g7PB6VHR.js} +9 -9
- package/dist/src/{cloudflare-gateway-D6O7AlYb.js → cloudflare-gateway-B9HWA5wf.js} +11 -11
- package/dist/src/{cloudflare-gateway-C2_-KG5o.cjs → cloudflare-gateway-BSnDmHYo.cjs} +10 -10
- package/dist/src/{cloudflare-gateway-pXGHxJ47.js → cloudflare-gateway-CKDb4dJ8.js} +10 -10
- package/dist/src/{cloudflare-gateway-D6xFc5pa.js → cloudflare-gateway-CP9QEWYS.js} +10 -10
- package/dist/src/{cometapi-Bbjp5V4x.js → cometapi-BL9yvj_f.js} +10 -10
- package/dist/src/{cometapi-vY6aDZgo.cjs → cometapi-C4xSqeID.cjs} +10 -10
- package/dist/src/{cometapi-DkXrKi5z.js → cometapi-CUQq3H_a.js} +10 -10
- package/dist/src/{cometapi-BasUi7-_.js → cometapi-DFNiKmSz.js} +11 -11
- package/dist/src/{completion-C_P3ypkJ.js → completion-5MzrpJxT.js} +4 -4
- package/dist/src/{completion-CDOouNzq.cjs → completion-CM6oK8PS.cjs} +4 -4
- package/dist/src/{completion-C5rtR_9P.js → completion-DZ083F31.js} +4 -4
- package/dist/src/{completion-6Mx_iXxK.js → completion-qRoZAYRB.js} +4 -4
- package/dist/src/{docker-CZnqU1XV.js → docker-Bb5dcxr8.js} +9 -9
- package/dist/src/{docker-DzxyDPIj.js → docker-BvfL2BrW.js} +10 -10
- package/dist/src/{docker-BwsKwxFs.cjs → docker-DcF2pRrj.cjs} +9 -9
- package/dist/src/{docker-5KcG-_86.js → docker-ExVyLp0S.js} +9 -9
- package/dist/src/eval-B3r2CVXr.js +15 -0
- package/dist/src/{eval-DmFyWU7i.js → eval-Dg2nG4v2.js} +8 -8
- package/dist/src/evalResult-5xwYnECe.js +12 -0
- package/dist/src/evalResult-71lY93Kj.cjs +10 -0
- package/dist/src/{evalResult-CTG2AHOS.js → evalResult-BBRNtX4I.js} +5 -5
- package/dist/src/{evalResult-CDQiuUuf.js → evalResult-BDMqrapS.js} +5 -5
- package/dist/src/evalResult-Dx5P5cIv.js +10 -0
- package/dist/src/{evalResult-Dap2CekP.cjs → evalResult-fuaI8HkH.cjs} +5 -5
- package/dist/src/{evaluator-DPFRbFIL.js → evaluator-BhoWwp5b.js} +30 -26
- package/dist/src/evaluator-Jx6bRZV6.js +36 -0
- package/dist/src/{extractor-M67RUtg6.js → extractor-C0EVHewb.js} +5 -5
- package/dist/src/{extractor-YMU_Gvt8.js → extractor-D25qpmGX.js} +5 -5
- package/dist/src/{extractor-CFG6bcWJ.js → extractor-DReVID0K.js} +5 -5
- package/dist/src/{extractor-DX36oYEv.cjs → extractor-pYLLi3wS.cjs} +5 -5
- package/dist/src/{fetch-BxUk8odA.cjs → fetch-BPkYtG8K.cjs} +2 -2
- package/dist/src/fetch-BxNb_Lp3.js +5 -0
- package/dist/src/{fetch-60Gzydls.js → fetch-Cwxnd8zz.js} +2 -2
- package/dist/src/{fetch-BMv0O527.js → fetch-Dxpd4_sr.js} +3 -3
- package/dist/src/{fetch-4M3YRaqL.js → fetch-HaqdX7U1.js} +2 -2
- package/dist/src/{graders-CpdqD9PI.js → graders-BTeBGqjJ.js} +13 -13
- package/dist/src/graders-B_pgMLS2.js +34 -0
- package/dist/src/{graders-CHO8EPM4.js → graders-Bj_Odv7c.js} +13 -13
- package/dist/src/graders-DErokPDO.cjs +32 -0
- package/dist/src/{graders-R9rYUM0d.js → graders-DP7KFFo-.js} +13 -13
- package/dist/src/graders-DR_uNe54.js +32 -0
- package/dist/src/{graders-DOXycdlG.cjs → graders-DU49_J8Y.cjs} +13 -13
- package/dist/src/graders-w3176Wz-.js +32 -0
- package/dist/src/{image-gvmivTEe.js → image-B02ogr_b.js} +4 -4
- package/dist/src/{image-tL5hIOFh.js → image-B0h9VEMc.js} +3 -3
- package/dist/src/{image-DTedmQPg.cjs → image-BLmROtN3.cjs} +4 -4
- package/dist/src/{image-DJEvKveK.js → image-Bb4vWQLM.js} +3 -3
- package/dist/src/{image-CDLQOcqT.cjs → image-C1madmKh.cjs} +3 -3
- package/dist/src/{image-BmEZqVmk.js → image-CHfWvljl.js} +4 -4
- package/dist/src/{image-CBBVXWuT.js → image-DS-o-0ph.js} +4 -4
- package/dist/src/{image-pAX56tPG.js → image-Dpxa1Jt6.js} +4 -4
- package/dist/src/index.cjs +38 -34
- package/dist/src/index.d.cts +260 -0
- package/dist/src/index.d.ts +260 -0
- package/dist/src/index.js +38 -34
- package/dist/src/{knowledgeBase-CoU-UQBg.js → knowledgeBase-B3OoKIej.js} +6 -6
- package/dist/src/{knowledgeBase-CLJybhnF.js → knowledgeBase-CYTLHOt1.js} +7 -7
- package/dist/src/{knowledgeBase-DjWPVqSb.js → knowledgeBase-D33Ty2l6.js} +6 -6
- package/dist/src/{knowledgeBase-wkxuRFhA.cjs → knowledgeBase-DOO_BM9b.cjs} +6 -6
- package/dist/src/{litellm-B9Hysuri.js → litellm-AaeZcZQF.js} +12 -11
- package/dist/src/{litellm-NYpQ8RQu.cjs → litellm-I_hbp_dc.cjs} +11 -10
- package/dist/src/{litellm-ePxtr9F1.js → litellm-NbjknEh6.js} +11 -10
- package/dist/src/{litellm-CTfa0hqi.js → litellm-TrljxD9G.js} +11 -10
- package/dist/src/{luma-ray-BW9IRGIc.js → luma-ray-BS2_tY8L.js} +9 -9
- package/dist/src/{luma-ray-BE2mOt6N.js → luma-ray-DDsjcgZZ.js} +8 -8
- package/dist/src/{luma-ray-B0GGNRc1.cjs → luma-ray-Due0n7di.cjs} +8 -8
- package/dist/src/{luma-ray-Cm1KZBhs.js → luma-ray-f6I2fft-.js} +8 -8
- package/dist/src/main.js +33 -33
- package/dist/src/{messages-BLbWdsyt.js → messages-BS17jdMx.js} +7 -7
- package/dist/src/{messages-1JrJs91T.cjs → messages-Bs1kC7P4.cjs} +7 -7
- package/dist/src/{messages-1x9atZmP.js → messages-D0lx5qK7.js} +7 -7
- package/dist/src/{messages-D8EA0oDc.js → messages-ZJk778GH.js} +7 -7
- package/dist/src/{modelslab-X5-4LroM.js → modelslab-Bmni6skY.js} +8 -8
- package/dist/src/{modelslab-CqXBy3U8.js → modelslab-Bx9IrZfS.js} +9 -9
- package/dist/src/{modelslab-DcOSFwKh.cjs → modelslab-CoUX6Jc_.cjs} +8 -8
- package/dist/src/{modelslab-C1OLRmVX.js → modelslab-DRb74SP4.js} +8 -8
- package/dist/src/{nova-reel-BgS1ZWuK.js → nova-reel-BfPq-0Yk.js} +8 -8
- package/dist/src/{nova-reel-D9xfaMBs.cjs → nova-reel-C_QM18Xn.cjs} +8 -8
- package/dist/src/{nova-reel-D2ZkOSyr.js → nova-reel-D_W1tjMH.js} +9 -9
- package/dist/src/{nova-reel-DihqLeol.js → nova-reel-bgjxilYW.js} +8 -8
- package/dist/src/{nova-sonic-DezhVUYT.js → nova-sonic-CFb5GYhg.js} +5 -5
- package/dist/src/{nova-sonic-P-CdUMlV.js → nova-sonic-DIGQNR07.js} +5 -5
- package/dist/src/{nova-sonic-Q3BOJeig.js → nova-sonic-De1HW5fD.js} +6 -6
- package/dist/src/{nova-sonic-DVu3mMIy.cjs → nova-sonic-zfcljeRp.cjs} +5 -5
- package/dist/src/{openclaw-DAfWQn-o.cjs → openclaw-CSugPYAr.cjs} +169 -105
- package/dist/src/{openclaw-D1D_ej1z.js → openclaw-DiSz3I5L.js} +169 -106
- package/dist/src/{openclaw-BiSZPL7J.js → openclaw-DuvJKEW5.js} +168 -105
- package/dist/src/{openclaw-Bv1DINsX.js → openclaw-tiVYRtr-.js} +168 -105
- package/dist/src/{opencode-sdk-D95s6SnR.js → opencode-sdk-0j6rTWNb.js} +5 -5
- package/dist/src/{opencode-sdk-DxUPkLT7.js → opencode-sdk-B3CWY9h_.js} +4 -4
- package/dist/src/{opencode-sdk-CfaLN8PY.cjs → opencode-sdk-BL764Jdi.cjs} +4 -4
- package/dist/src/{opencode-sdk-C7m-wRfI.js → opencode-sdk-C2y6UkP2.js} +4 -4
- package/dist/src/{otlpReceiver-g3ByGaXs.js → otlpReceiver-C99PPb48.js} +4 -4
- package/dist/src/{otlpReceiver-Diec4cln.cjs → otlpReceiver-CGq6LspY.cjs} +4 -4
- package/dist/src/{otlpReceiver--AIRW_S4.js → otlpReceiver-CdNBdbsk.js} +4 -4
- package/dist/src/{otlpReceiver-Bn5wGB1v.js → otlpReceiver-D89fR-rC.js} +4 -4
- package/dist/src/providers-B7V0njNs.js +32 -0
- package/dist/src/providers-BEwbhv0X.js +30 -0
- package/dist/src/{providers-CFLy1_ji.js → providers-BlqUifFg.js} +54 -54
- package/dist/src/providers-CH3C7zf7.js +30 -0
- package/dist/src/{providers-CFu-TZl-.cjs → providers-CgKOSgTR.cjs} +53 -53
- package/dist/src/{providers-B3HvufyI.js → providers-D8lF1sqW.js} +53 -53
- package/dist/src/{providers-BKRJTjBz.js → providers-Dk_6ocUX.js} +53 -53
- package/dist/src/providers-zyB6k_38.cjs +31 -0
- package/dist/src/{quiverai-C2jVwbH1.js → quiverai-BbOUOn2L.js} +3 -3
- package/dist/src/{quiverai-CI6gYJVI.js → quiverai-CIaELU_m.js} +3 -3
- package/dist/src/{quiverai-CLkWkyZc.cjs → quiverai-PdShCPox.cjs} +3 -3
- package/dist/src/{quiverai-MHSxbmmZ.js → quiverai-uH-dcTIr.js} +4 -4
- package/dist/src/{responses-jxdehPkC.js → responses-CB2jwoAr.js} +7 -7
- package/dist/src/{responses-tD4Bd4dc.cjs → responses-D8SBTL64.cjs} +7 -7
- package/dist/src/{responses-BKqJmhhc.js → responses-DIR9Ud3j.js} +7 -7
- package/dist/src/{responses-CGw0DCzh.js → responses-WNGNYe3K.js} +7 -7
- package/dist/src/{sagemaker-BK4Zb993.js → sagemaker-CNBxx5CJ.js} +11 -11
- package/dist/src/{sagemaker-D2Q1c-sD.js → sagemaker-CemTFp2h.js} +11 -11
- package/dist/src/{sagemaker-CcQHM1jV.cjs → sagemaker-Cl28mZU2.cjs} +11 -11
- package/dist/src/{sagemaker-BfiWTmvn.js → sagemaker-YSyBXQQh.js} +12 -12
- package/dist/src/{scanner-J8CA3LsV.js → scanner-BsBlNXNn.js} +7 -7
- package/dist/src/server/index.js +39 -35
- package/dist/src/{server-B0PPuDw-.cjs → server-C_7Ax-hA.cjs} +3 -3
- package/dist/src/{server-DbFphssR.js → server-CqzrVGpF.js} +5 -5
- package/dist/src/{server-OAs3nBRT.js → server-CuxBbeSY.js} +4 -4
- package/dist/src/server-DA4Cyrrq.js +7 -0
- package/dist/src/server-Dulb-4-K.cjs +5 -0
- package/dist/src/{server-BC7XJFgr.js → server-VWgWb00X.js} +3 -3
- package/dist/src/{signal-BOTbd53Z.js → signal-4U3mfRvL.js} +2 -2
- package/dist/src/{store-Ub2vaGJ1.js → store-CXGFv4aR.js} +2 -2
- package/dist/src/store-CXS-Q_91.js +6 -0
- package/dist/src/{store-BSc-TF2w.cjs → store-DLlFCC4h.cjs} +2 -2
- package/dist/src/{store-DQLEjuEO.js → store-DXilxTl-.js} +2 -2
- package/dist/src/{store-D1tv90v3.js → store-Dim__MDd.js} +2 -2
- package/dist/src/store-eYkaKMwq.cjs +5 -0
- package/dist/src/{tables-5EvT_Bwn.js → tables-6YKwjN9-.js} +2 -2
- package/dist/src/{tables-xKANLRBD.js → tables-DLJPUdUE.js} +2 -2
- package/dist/src/{tables-C7K-XKWp.cjs → tables-DPi7wKeM.cjs} +2 -2
- package/dist/src/{tables-D36WTqKX.js → tables-gftXzE9I.js} +2 -2
- package/dist/src/telemetry-BpMfhthR.cjs +5 -0
- package/dist/src/{telemetry-C2YDkUQH.js → telemetry-CMrFgtPB.js} +3 -3
- package/dist/src/{telemetry-DMb2Mpfm.js → telemetry-Cps3mIU-.js} +3 -3
- package/dist/src/{telemetry-CbrnxHp_.cjs → telemetry-DaX14Chu.cjs} +3 -3
- package/dist/src/{telemetry-C15ziL8u.js → telemetry-Dthj_BbD.js} +3 -3
- package/dist/src/telemetry-Dw38hanS.js +7 -0
- package/dist/src/{transcription-DAtxHhAM.js → transcription-BNYURcXg.js} +6 -6
- package/dist/src/{transcription-LNZTNUUL.js → transcription-B_OdaHp7.js} +6 -6
- package/dist/src/{transcription-CL78qbOU.cjs → transcription-NLVG9MT1.cjs} +6 -6
- package/dist/src/{transcription-QHh3AH6Z.js → transcription-s6A-bNrZ.js} +7 -7
- package/dist/src/{transform-Cgi24fJ7.js → transform-D5HsjduX.js} +3 -3
- package/dist/src/{transform-DOcQeLld.cjs → transform-DuHvhZpj.cjs} +3 -3
- package/dist/src/{transform-DGxXocjk.js → transform-uAytVuyX.js} +3 -3
- package/dist/src/{transform-DGLazrMm.js → transform-vNucnNr0.js} +3 -3
- package/dist/src/{types-LJ0r3wbR.cjs → types-C_7nyzr1.cjs} +39 -11
- package/dist/src/{types-CH3Ge2sE.js → types-Cbd8uOMq.js} +39 -11
- package/dist/src/{types-CN_TZ2GJ.js → types-CzW2QFyi.js} +39 -11
- package/dist/src/{types-CLKiCBW3.js → types-DmyIJ-sR.js} +39 -11
- package/dist/src/{util-B7T3SiBS.js → util-B3xGByQh.js} +3 -3
- package/dist/src/{util-Yz-1aEhW.cjs → util-B9vlHIIh.cjs} +3 -7
- package/dist/src/{util-ZZH-3QZz.js → util-BHGHw5G1.js} +3 -3
- package/dist/src/{util-Dlz_Wvgm.js → util-BRYkYPTd.js} +3 -7
- package/dist/src/{util-6-GqIvzS.js → util-BV4XUC0n.js} +3 -3
- package/dist/src/{util-DaWTWKBK.js → util-Bv6uGDfH.js} +3 -3
- package/dist/src/{util-Db0a0AFH.cjs → util-BzMcevZc.cjs} +3 -3
- package/dist/src/{util-YT5HPZaS.js → util-C1CeHl-P.js} +3 -7
- package/dist/src/{util-C-PPYSMq.js → util-CMy69ZgQ.js} +3 -3
- package/dist/src/{util-CchiqXh_.cjs → util-DGNOS1db.cjs} +3 -3
- package/dist/src/{util-Betm42rL.js → util-Dnmk2mBQ.js} +3 -3
- package/dist/src/{util-5cB-L7U3.js → util-ZzmqNPlg.js} +3 -7
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +12 -12
- package/dist/src/app/assets/vendor-charts-CCl15Imd.js +0 -36
- package/dist/src/cache-BwsMSda7.js +0 -6
- package/dist/src/eval-17JizQIv.js +0 -15
- package/dist/src/evalResult-Cqj8pldJ.js +0 -12
- package/dist/src/evalResult-DvcJAWJU.cjs +0 -10
- package/dist/src/evalResult-Hftn-S_i.js +0 -10
- package/dist/src/evaluator-B2CFNt-P.js +0 -36
- package/dist/src/fetch-KV5kNASw.js +0 -5
- package/dist/src/graders-Bu0H9nXi.js +0 -32
- package/dist/src/graders-Cfhkvx-e.js +0 -34
- package/dist/src/graders-DClJVpGP.cjs +0 -32
- package/dist/src/graders-DcnJsrMO.js +0 -32
- package/dist/src/providers-C1rOSHiR.js +0 -32
- package/dist/src/providers-CxmDwEFf.cjs +0 -31
- package/dist/src/providers-Dodakqr0.js +0 -30
- package/dist/src/providers-GIQ2TcsA.js +0 -30
- package/dist/src/server-B1vi21hA.js +0 -7
- package/dist/src/server-Cm9Kai_h.cjs +0 -5
- package/dist/src/store-BNmZ1KAz.cjs +0 -5
- package/dist/src/store-BltJg2cd.js +0 -6
- package/dist/src/telemetry-5BCRNBbe.cjs +0 -5
- package/dist/src/telemetry-D4W5hboe.js +0 -7
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import{r as w,g as Qt,a as kc,b as wm,R as cx}from"./vendor-react-AtKqiNEf.js";function Sm(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=Sm(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Ze(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=Sm(e))&&(r&&(r+=" "),r+=t);return r}var ux="Invariant failed";function YR(e,t){if(!e)throw new Error(ux)}function oi(e){return e+.5|0}const $t=(e,t,n)=>Math.max(Math.min(e,n),t);function Dr(e){return $t(oi(e*2.55),0,255)}function Vt(e){return $t(oi(e*255),0,255)}function Ot(e){return $t(oi(e/2.55)/100,0,1)}function hf(e){return $t(oi(e*100),0,100)}const Ye={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},Cl=[..."0123456789ABCDEF"],fx=e=>Cl[e&15],dx=e=>Cl[(e&240)>>4]+Cl[e&15],Oi=e=>(e&240)>>4===(e&15),hx=e=>Oi(e.r)&&Oi(e.g)&&Oi(e.b)&&Oi(e.a);function px(e){var t=e.length,n;return e[0]==="#"&&(t===4||t===5?n={r:255&Ye[e[1]]*17,g:255&Ye[e[2]]*17,b:255&Ye[e[3]]*17,a:t===5?Ye[e[4]]*17:255}:(t===7||t===9)&&(n={r:Ye[e[1]]<<4|Ye[e[2]],g:Ye[e[3]]<<4|Ye[e[4]],b:Ye[e[5]]<<4|Ye[e[6]],a:t===9?Ye[e[7]]<<4|Ye[e[8]]:255})),n}const gx=(e,t)=>e<255?t(e):"";function mx(e){var t=hx(e)?fx:dx;return e?"#"+t(e.r)+t(e.g)+t(e.b)+gx(e.a,t):void 0}const vx=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function Om(e,t,n){const r=t*Math.min(n,1-n),i=(a,o=(a+e/30)%12)=>n-r*Math.max(Math.min(o-3,9-o,1),-1);return[i(0),i(8),i(4)]}function yx(e,t,n){const r=(i,a=(i+e/60)%6)=>n-n*t*Math.max(Math.min(a,4-a,1),0);return[r(5),r(3),r(1)]}function bx(e,t,n){const r=Om(e,1,.5);let i;for(t+n>1&&(i=1/(t+n),t*=i,n*=i),i=0;i<3;i++)r[i]*=1-t-n,r[i]+=t;return r}function xx(e,t,n,r,i){return e===i?(t-n)/r+(t<n?6:0):t===i?(n-e)/r+2:(e-t)/r+4}function Cc(e){const n=e.r/255,r=e.g/255,i=e.b/255,a=Math.max(n,r,i),o=Math.min(n,r,i),s=(a+o)/2;let l,c,u;return a!==o&&(u=a-o,c=s>.5?u/(2-a-o):u/(a+o),l=xx(n,r,i,u,a),l=l*60+.5),[l|0,c||0,s]}function Ec(e,t,n,r){return(Array.isArray(t)?e(t[0],t[1],t[2]):e(t,n,r)).map(Vt)}function Dc(e,t,n){return Ec(Om,e,t,n)}function _x(e,t,n){return Ec(bx,e,t,n)}function wx(e,t,n){return Ec(yx,e,t,n)}function Pm(e){return(e%360+360)%360}function Sx(e){const t=vx.exec(e);let n=255,r;if(!t)return;t[5]!==r&&(n=t[6]?Dr(+t[5]):Vt(+t[5]));const i=Pm(+t[2]),a=+t[3]/100,o=+t[4]/100;return t[1]==="hwb"?r=_x(i,a,o):t[1]==="hsv"?r=wx(i,a,o):r=Dc(i,a,o),{r:r[0],g:r[1],b:r[2],a:n}}function Ox(e,t){var n=Cc(e);n[0]=Pm(n[0]+t),n=Dc(n),e.r=n[0],e.g=n[1],e.b=n[2]}function Px(e){if(!e)return;const t=Cc(e),n=t[0],r=hf(t[1]),i=hf(t[2]);return e.a<255?`hsla(${n}, ${r}%, ${i}%, ${Ot(e.a)})`:`hsl(${n}, ${r}%, ${i}%)`}const pf={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},gf={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};function Mx(){const e={},t=Object.keys(gf),n=Object.keys(pf);let r,i,a,o,s;for(r=0;r<t.length;r++){for(o=s=t[r],i=0;i<n.length;i++)a=n[i],s=s.replace(a,pf[a]);a=parseInt(gf[o],16),e[s]=[a>>16&255,a>>8&255,a&255]}return e}let Pi;function Ax(e){Pi||(Pi=Mx(),Pi.transparent=[0,0,0,0]);const t=Pi[e.toLowerCase()];return t&&{r:t[0],g:t[1],b:t[2],a:t.length===4?t[3]:255}}const kx=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;function Cx(e){const t=kx.exec(e);let n=255,r,i,a;if(t){if(t[7]!==r){const o=+t[7];n=t[8]?Dr(o):$t(o*255,0,255)}return r=+t[1],i=+t[3],a=+t[5],r=255&(t[2]?Dr(r):$t(r,0,255)),i=255&(t[4]?Dr(i):$t(i,0,255)),a=255&(t[6]?Dr(a):$t(a,0,255)),{r,g:i,b:a,a:n}}}function Ex(e){return e&&(e.a<255?`rgba(${e.r}, ${e.g}, ${e.b}, ${Ot(e.a)})`:`rgb(${e.r}, ${e.g}, ${e.b})`)}const Wo=e=>e<=.0031308?e*12.92:Math.pow(e,1/2.4)*1.055-.055,Nn=e=>e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4);function Dx(e,t,n){const r=Nn(Ot(e.r)),i=Nn(Ot(e.g)),a=Nn(Ot(e.b));return{r:Vt(Wo(r+n*(Nn(Ot(t.r))-r))),g:Vt(Wo(i+n*(Nn(Ot(t.g))-i))),b:Vt(Wo(a+n*(Nn(Ot(t.b))-a))),a:e.a+n*(t.a-e.a)}}function Mi(e,t,n){if(e){let r=Cc(e);r[t]=Math.max(0,Math.min(r[t]+r[t]*n,t===0?360:1)),r=Dc(r),e.r=r[0],e.g=r[1],e.b=r[2]}}function Mm(e,t){return e&&Object.assign(t||{},e)}function mf(e){var t={r:0,g:0,b:0,a:255};return Array.isArray(e)?e.length>=3&&(t={r:e[0],g:e[1],b:e[2],a:255},e.length>3&&(t.a=Vt(e[3]))):(t=Mm(e,{r:0,g:0,b:0,a:1}),t.a=Vt(t.a)),t}function Tx(e){return e.charAt(0)==="r"?Cx(e):Sx(e)}let Am=class El{constructor(t){if(t instanceof El)return t;const n=typeof t;let r;n==="object"?r=mf(t):n==="string"&&(r=px(t)||Ax(t)||Tx(t)),this._rgb=r,this._valid=!!r}get valid(){return this._valid}get rgb(){var t=Mm(this._rgb);return t&&(t.a=Ot(t.a)),t}set rgb(t){this._rgb=mf(t)}rgbString(){return this._valid?Ex(this._rgb):void 0}hexString(){return this._valid?mx(this._rgb):void 0}hslString(){return this._valid?Px(this._rgb):void 0}mix(t,n){if(t){const r=this.rgb,i=t.rgb;let a;const o=n===a?.5:n,s=2*o-1,l=r.a-i.a,c=((s*l===-1?s:(s+l)/(1+s*l))+1)/2;a=1-c,r.r=255&c*r.r+a*i.r+.5,r.g=255&c*r.g+a*i.g+.5,r.b=255&c*r.b+a*i.b+.5,r.a=o*r.a+(1-o)*i.a,this.rgb=r}return this}interpolate(t,n){return t&&(this._rgb=Dx(this._rgb,t._rgb,n)),this}clone(){return new El(this.rgb)}alpha(t){return this._rgb.a=Vt(t),this}clearer(t){const n=this._rgb;return n.a*=1-t,this}greyscale(){const t=this._rgb,n=oi(t.r*.3+t.g*.59+t.b*.11);return t.r=t.g=t.b=n,this}opaquer(t){const n=this._rgb;return n.a*=1+t,this}negate(){const t=this._rgb;return t.r=255-t.r,t.g=255-t.g,t.b=255-t.b,this}lighten(t){return Mi(this._rgb,2,t),this}darken(t){return Mi(this._rgb,2,-t),this}saturate(t){return Mi(this._rgb,1,t),this}desaturate(t){return Mi(this._rgb,1,-t),this}rotate(t){return Ox(this._rgb,t),this}};function _t(){}const Ix=(()=>{let e=0;return()=>e++})();function H(e){return e==null}function me(e){if(Array.isArray&&Array.isArray(e))return!0;const t=Object.prototype.toString.call(e);return t.slice(0,7)==="[object"&&t.slice(-6)==="Array]"}function $(e){return e!==null&&Object.prototype.toString.call(e)==="[object Object]"}function Qe(e){return(typeof e=="number"||e instanceof Number)&&isFinite(+e)}function lt(e,t){return Qe(e)?e:t}function V(e,t){return typeof e>"u"?t:e}const jx=(e,t)=>typeof e=="string"&&e.endsWith("%")?parseFloat(e)/100:+e/t,km=(e,t)=>typeof e=="string"&&e.endsWith("%")?parseFloat(e)/100*t:+e;function le(e,t,n){if(e&&typeof e.call=="function")return e.apply(n,t)}function Y(e,t,n,r){let i,a,o;if(me(e))for(a=e.length,i=0;i<a;i++)t.call(n,e[i],i);else if($(e))for(o=Object.keys(e),a=o.length,i=0;i<a;i++)t.call(n,e[o[i]],o[i])}function sa(e,t){let n,r,i,a;if(!e||!t||e.length!==t.length)return!1;for(n=0,r=e.length;n<r;++n)if(i=e[n],a=t[n],i.datasetIndex!==a.datasetIndex||i.index!==a.index)return!1;return!0}function la(e){if(me(e))return e.map(la);if($(e)){const t=Object.create(null),n=Object.keys(e),r=n.length;let i=0;for(;i<r;++i)t[n[i]]=la(e[n[i]]);return t}return e}function Cm(e){return["__proto__","prototype","constructor"].indexOf(e)===-1}function Rx(e,t,n,r){if(!Cm(e))return;const i=t[e],a=n[e];$(i)&&$(a)?$r(i,a,r):t[e]=la(a)}function $r(e,t,n){const r=me(t)?t:[t],i=r.length;if(!$(e))return e;n=n||{};const a=n.merger||Rx;let o;for(let s=0;s<i;++s){if(o=r[s],!$(o))continue;const l=Object.keys(o);for(let c=0,u=l.length;c<u;++c)a(l[c],e,o,n)}return e}function Lr(e,t){return $r(e,t,{merger:Lx})}function Lx(e,t,n){if(!Cm(e))return;const r=t[e],i=n[e];$(r)&&$(i)?Lr(r,i):Object.prototype.hasOwnProperty.call(t,e)||(t[e]=la(i))}const vf={"":e=>e,x:e=>e.x,y:e=>e.y};function Nx(e){const t=e.split("."),n=[];let r="";for(const i of t)r+=i,r.endsWith("\\")?r=r.slice(0,-1)+".":(n.push(r),r="");return n}function Fx(e){const t=Nx(e);return n=>{for(const r of t){if(r==="")break;n=n&&n[r]}return n}}function Yt(e,t){return(vf[t]||(vf[t]=Fx(t)))(e)}function Tc(e){return e.charAt(0).toUpperCase()+e.slice(1)}const Wr=e=>typeof e<"u",Xt=e=>typeof e=="function",yf=(e,t)=>{if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;return!0};function Bx(e){return e.type==="mouseup"||e.type==="click"||e.type==="contextmenu"}const de=Math.PI,Re=2*de,zx=Re+de,ca=Number.POSITIVE_INFINITY,$x=de/180,$e=de/2,cn=de/4,bf=de*2/3,Em=Math.log10,vt=Math.sign;function Nr(e,t,n){return Math.abs(e-t)<n}function xf(e){const t=Math.round(e);e=Nr(e,t,e/1e3)?t:e;const n=Math.pow(10,Math.floor(Em(e))),r=e/n;return(r<=1?1:r<=2?2:r<=5?5:10)*n}function Wx(e){const t=[],n=Math.sqrt(e);let r;for(r=1;r<n;r++)e%r===0&&(t.push(r),t.push(e/r));return n===(n|0)&&t.push(n),t.sort((i,a)=>i-a).pop(),t}function qx(e){return typeof e=="symbol"||typeof e=="object"&&e!==null&&!(Symbol.toPrimitive in e||"toString"in e||"valueOf"in e)}function Hn(e){return!qx(e)&&!isNaN(parseFloat(e))&&isFinite(e)}function Ux(e,t){const n=Math.round(e);return n-t<=e&&n+t>=e}function Vx(e,t,n){let r,i,a;for(r=0,i=e.length;r<i;r++)a=e[r][n],isNaN(a)||(t.min=Math.min(t.min,a),t.max=Math.max(t.max,a))}function ht(e){return e*(de/180)}function Hx(e){return e*(180/de)}function _f(e){if(!Qe(e))return;let t=1,n=0;for(;Math.round(e*t)/t!==e;)t*=10,n++;return n}function Kx(e,t){const n=t.x-e.x,r=t.y-e.y,i=Math.sqrt(n*n+r*r);let a=Math.atan2(r,n);return a<-.5*de&&(a+=Re),{angle:a,distance:i}}function Dl(e,t){return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}function Yx(e,t){return(e-t+zx)%Re-de}function Ft(e){return(e%Re+Re)%Re}function ua(e,t,n,r){const i=Ft(e),a=Ft(t),o=Ft(n),s=Ft(a-i),l=Ft(o-i),c=Ft(i-a),u=Ft(i-o);return i===a||i===o||r&&a===o||s>l&&c<u}function We(e,t,n){return Math.max(t,Math.min(n,e))}function Xx(e){return We(e,-32768,32767)}function Tl(e,t,n,r=1e-6){return e>=Math.min(t,n)-r&&e<=Math.max(t,n)+r}function Ic(e,t,n){n=n||(o=>e[o]<t);let r=e.length-1,i=0,a;for(;r-i>1;)a=i+r>>1,n(a)?i=a:r=a;return{lo:i,hi:r}}const yn=(e,t,n,r)=>Ic(e,n,r?i=>{const a=e[i][t];return a<n||a===n&&e[i+1][t]===n}:i=>e[i][t]<n),Gx=(e,t,n)=>Ic(e,n,r=>e[r][t]>=n);function Zx(e,t,n){let r=0,i=e.length;for(;r<i&&e[r]<t;)r++;for(;i>r&&e[i-1]>n;)i--;return r>0||i<e.length?e.slice(r,i):e}const Dm=["push","pop","shift","splice","unshift"];function Qx(e,t){if(e._chartjs){e._chartjs.listeners.push(t);return}Object.defineProperty(e,"_chartjs",{configurable:!0,enumerable:!1,value:{listeners:[t]}}),Dm.forEach(n=>{const r="_onData"+Tc(n),i=e[n];Object.defineProperty(e,n,{configurable:!0,enumerable:!1,value(...a){const o=i.apply(this,a);return e._chartjs.listeners.forEach(s=>{typeof s[r]=="function"&&s[r](...a)}),o}})})}function wf(e,t){const n=e._chartjs;if(!n)return;const r=n.listeners,i=r.indexOf(t);i!==-1&&r.splice(i,1),!(r.length>0)&&(Dm.forEach(a=>{delete e[a]}),delete e._chartjs)}function Tm(e){const t=new Set(e);return t.size===e.length?e:Array.from(t)}const Im=(function(){return typeof window>"u"?function(e){return e()}:window.requestAnimationFrame})();function jm(e,t){let n=[],r=!1;return function(...i){n=i,r||(r=!0,Im.call(window,()=>{r=!1,e.apply(t,n)}))}}function Jx(e,t){let n;return function(...r){return t?(clearTimeout(n),n=setTimeout(e,t,r)):e.apply(this,r),t}}const e_=e=>e==="start"?"left":e==="end"?"right":"center",Sf=(e,t,n)=>e==="start"?t:e==="end"?n:(t+n)/2;function Rm(e,t,n){const r=t.length;let i=0,a=r;if(e._sorted){const{iScale:o,vScale:s,_parsed:l}=e,c=e.dataset&&e.dataset.options?e.dataset.options.spanGaps:null,u=o.axis,{min:f,max:d,minDefined:h,maxDefined:p}=o.getUserBounds();if(h){if(i=Math.min(yn(l,u,f).lo,n?r:yn(t,u,o.getPixelForValue(f)).lo),c){const m=l.slice(0,i+1).reverse().findIndex(g=>!H(g[s.axis]));i-=Math.max(0,m)}i=We(i,0,r-1)}if(p){let m=Math.max(yn(l,o.axis,d,!0).hi+1,n?0:yn(t,u,o.getPixelForValue(d),!0).hi+1);if(c){const g=l.slice(m-1).findIndex(v=>!H(v[s.axis]));m+=Math.max(0,g)}a=We(m,i,r)-i}else a=r-i}return{start:i,count:a}}function Lm(e){const{xScale:t,yScale:n,_scaleRanges:r}=e,i={xmin:t.min,xmax:t.max,ymin:n.min,ymax:n.max};if(!r)return e._scaleRanges=i,!0;const a=r.xmin!==t.min||r.xmax!==t.max||r.ymin!==n.min||r.ymax!==n.max;return Object.assign(r,i),a}const Ai=e=>e===0||e===1,Of=(e,t,n)=>-(Math.pow(2,10*(e-=1))*Math.sin((e-t)*Re/n)),Pf=(e,t,n)=>Math.pow(2,-10*e)*Math.sin((e-t)*Re/n)+1,Fr={linear:e=>e,easeInQuad:e=>e*e,easeOutQuad:e=>-e*(e-2),easeInOutQuad:e=>(e/=.5)<1?.5*e*e:-.5*(--e*(e-2)-1),easeInCubic:e=>e*e*e,easeOutCubic:e=>(e-=1)*e*e+1,easeInOutCubic:e=>(e/=.5)<1?.5*e*e*e:.5*((e-=2)*e*e+2),easeInQuart:e=>e*e*e*e,easeOutQuart:e=>-((e-=1)*e*e*e-1),easeInOutQuart:e=>(e/=.5)<1?.5*e*e*e*e:-.5*((e-=2)*e*e*e-2),easeInQuint:e=>e*e*e*e*e,easeOutQuint:e=>(e-=1)*e*e*e*e+1,easeInOutQuint:e=>(e/=.5)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2),easeInSine:e=>-Math.cos(e*$e)+1,easeOutSine:e=>Math.sin(e*$e),easeInOutSine:e=>-.5*(Math.cos(de*e)-1),easeInExpo:e=>e===0?0:Math.pow(2,10*(e-1)),easeOutExpo:e=>e===1?1:-Math.pow(2,-10*e)+1,easeInOutExpo:e=>Ai(e)?e:e<.5?.5*Math.pow(2,10*(e*2-1)):.5*(-Math.pow(2,-10*(e*2-1))+2),easeInCirc:e=>e>=1?e:-(Math.sqrt(1-e*e)-1),easeOutCirc:e=>Math.sqrt(1-(e-=1)*e),easeInOutCirc:e=>(e/=.5)<1?-.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1),easeInElastic:e=>Ai(e)?e:Of(e,.075,.3),easeOutElastic:e=>Ai(e)?e:Pf(e,.075,.3),easeInOutElastic(e){return Ai(e)?e:e<.5?.5*Of(e*2,.1125,.45):.5+.5*Pf(e*2-1,.1125,.45)},easeInBack(e){return e*e*((1.70158+1)*e-1.70158)},easeOutBack(e){return(e-=1)*e*((1.70158+1)*e+1.70158)+1},easeInOutBack(e){let t=1.70158;return(e/=.5)<1?.5*(e*e*(((t*=1.525)+1)*e-t)):.5*((e-=2)*e*(((t*=1.525)+1)*e+t)+2)},easeInBounce:e=>1-Fr.easeOutBounce(1-e),easeOutBounce(e){return e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375},easeInOutBounce:e=>e<.5?Fr.easeInBounce(e*2)*.5:Fr.easeOutBounce(e*2-1)*.5+.5};function jc(e){if(e&&typeof e=="object"){const t=e.toString();return t==="[object CanvasPattern]"||t==="[object CanvasGradient]"}return!1}function Mf(e){return jc(e)?e:new Am(e)}function qo(e){return jc(e)?e:new Am(e).saturate(.5).darken(.1).hexString()}const t_=["x","y","borderWidth","radius","tension"],n_=["color","borderColor","backgroundColor"];function r_(e){e.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0}),e.describe("animation",{_fallback:!1,_indexable:!1,_scriptable:t=>t!=="onProgress"&&t!=="onComplete"&&t!=="fn"}),e.set("animations",{colors:{type:"color",properties:n_},numbers:{type:"number",properties:t_}}),e.describe("animations",{_fallback:"animation"}),e.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>t|0}}}})}function i_(e){e.set("layout",{autoPadding:!0,padding:{top:0,right:0,bottom:0,left:0}})}const Af=new Map;function a_(e,t){t=t||{};const n=e+JSON.stringify(t);let r=Af.get(n);return r||(r=new Intl.NumberFormat(e,t),Af.set(n,r)),r}function Ja(e,t,n){return a_(t,n).format(e)}const o_={values(e){return me(e)?e:""+e},numeric(e,t,n){if(e===0)return"0";const r=this.chart.options.locale;let i,a=e;if(n.length>1){const c=Math.max(Math.abs(n[0].value),Math.abs(n[n.length-1].value));(c<1e-4||c>1e15)&&(i="scientific"),a=s_(e,n)}const o=Em(Math.abs(a)),s=isNaN(o)?1:Math.max(Math.min(-1*Math.floor(o),20),0),l={notation:i,minimumFractionDigits:s,maximumFractionDigits:s};return Object.assign(l,this.options.ticks.format),Ja(e,r,l)}};function s_(e,t){let n=t.length>3?t[2].value-t[1].value:t[1].value-t[0].value;return Math.abs(n)>=1&&e!==Math.floor(e)&&(n=e-Math.floor(e)),n}var Nm={formatters:o_};function l_(e){e.set("scale",{display:!0,offset:!1,reverse:!1,beginAtZero:!1,bounds:"ticks",clip:!0,grace:0,grid:{display:!0,lineWidth:1,drawOnChartArea:!0,drawTicks:!0,tickLength:8,tickWidth:(t,n)=>n.lineWidth,tickColor:(t,n)=>n.color,offset:!1},border:{display:!0,dash:[],dashOffset:0,width:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:Nm.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),e.route("scale.ticks","color","","color"),e.route("scale.grid","color","","borderColor"),e.route("scale.border","color","","borderColor"),e.route("scale.title","color","","color"),e.describe("scale",{_fallback:!1,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&t!=="callback"&&t!=="parser",_indexable:t=>t!=="borderDash"&&t!=="tickBorderDash"&&t!=="dash"}),e.describe("scales",{_fallback:"scale"}),e.describe("scale.ticks",{_scriptable:t=>t!=="backdropPadding"&&t!=="callback",_indexable:t=>t!=="backdropPadding"})}const An=Object.create(null),Il=Object.create(null);function Br(e,t){if(!t)return e;const n=t.split(".");for(let r=0,i=n.length;r<i;++r){const a=n[r];e=e[a]||(e[a]=Object.create(null))}return e}function Uo(e,t,n){return typeof t=="string"?$r(Br(e,t),n):$r(Br(e,""),t)}class c_{constructor(t,n){this.animation=void 0,this.backgroundColor="rgba(0,0,0,0.1)",this.borderColor="rgba(0,0,0,0.1)",this.color="#666",this.datasets={},this.devicePixelRatio=r=>r.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(r,i)=>qo(i.backgroundColor),this.hoverBorderColor=(r,i)=>qo(i.borderColor),this.hoverColor=(r,i)=>qo(i.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0,includeInvisible:!1},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(t),this.apply(n)}set(t,n){return Uo(this,t,n)}get(t){return Br(this,t)}describe(t,n){return Uo(Il,t,n)}override(t,n){return Uo(An,t,n)}route(t,n,r,i){const a=Br(this,t),o=Br(this,r),s="_"+n;Object.defineProperties(a,{[s]:{value:a[n],writable:!0},[n]:{enumerable:!0,get(){const l=this[s],c=o[i];return $(l)?Object.assign({},c,l):V(l,c)},set(l){this[s]=l}}})}apply(t){t.forEach(n=>n(this))}}var ae=new c_({_scriptable:e=>!e.startsWith("on"),_indexable:e=>e!=="events",hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}},[r_,i_,l_]);function u_(e){return!e||H(e.size)||H(e.family)?null:(e.style?e.style+" ":"")+(e.weight?e.weight+" ":"")+e.size+"px "+e.family}function kf(e,t,n,r,i){let a=t[i];return a||(a=t[i]=e.measureText(i).width,n.push(i)),a>r&&(r=a),r}function un(e,t,n){const r=e.currentDevicePixelRatio,i=n!==0?Math.max(n/2,.5):0;return Math.round((t-i)*r)/r+i}function Cf(e,t){!t&&!e||(t=t||e.getContext("2d"),t.save(),t.resetTransform(),t.clearRect(0,0,e.width,e.height),t.restore())}function jl(e,t,n,r){f_(e,t,n,r)}function f_(e,t,n,r,i){let a,o,s,l,c,u,f,d;const h=t.pointStyle,p=t.rotation,m=t.radius;let g=(p||0)*$x;if(h&&typeof h=="object"&&(a=h.toString(),a==="[object HTMLImageElement]"||a==="[object HTMLCanvasElement]")){e.save(),e.translate(n,r),e.rotate(g),e.drawImage(h,-h.width/2,-h.height/2,h.width,h.height),e.restore();return}if(!(isNaN(m)||m<=0)){switch(e.beginPath(),h){default:e.arc(n,r,m,0,Re),e.closePath();break;case"triangle":u=m,e.moveTo(n+Math.sin(g)*u,r-Math.cos(g)*m),g+=bf,e.lineTo(n+Math.sin(g)*u,r-Math.cos(g)*m),g+=bf,e.lineTo(n+Math.sin(g)*u,r-Math.cos(g)*m),e.closePath();break;case"rectRounded":c=m*.516,l=m-c,o=Math.cos(g+cn)*l,f=Math.cos(g+cn)*l,s=Math.sin(g+cn)*l,d=Math.sin(g+cn)*l,e.arc(n-f,r-s,c,g-de,g-$e),e.arc(n+d,r-o,c,g-$e,g),e.arc(n+f,r+s,c,g,g+$e),e.arc(n-d,r+o,c,g+$e,g+de),e.closePath();break;case"rect":if(!p){l=Math.SQRT1_2*m,u=l,e.rect(n-u,r-l,2*u,2*l);break}g+=cn;case"rectRot":f=Math.cos(g)*m,o=Math.cos(g)*m,s=Math.sin(g)*m,d=Math.sin(g)*m,e.moveTo(n-f,r-s),e.lineTo(n+d,r-o),e.lineTo(n+f,r+s),e.lineTo(n-d,r+o),e.closePath();break;case"crossRot":g+=cn;case"cross":f=Math.cos(g)*m,o=Math.cos(g)*m,s=Math.sin(g)*m,d=Math.sin(g)*m,e.moveTo(n-f,r-s),e.lineTo(n+f,r+s),e.moveTo(n+d,r-o),e.lineTo(n-d,r+o);break;case"star":f=Math.cos(g)*m,o=Math.cos(g)*m,s=Math.sin(g)*m,d=Math.sin(g)*m,e.moveTo(n-f,r-s),e.lineTo(n+f,r+s),e.moveTo(n+d,r-o),e.lineTo(n-d,r+o),g+=cn,f=Math.cos(g)*m,o=Math.cos(g)*m,s=Math.sin(g)*m,d=Math.sin(g)*m,e.moveTo(n-f,r-s),e.lineTo(n+f,r+s),e.moveTo(n+d,r-o),e.lineTo(n-d,r+o);break;case"line":o=Math.cos(g)*m,s=Math.sin(g)*m,e.moveTo(n-o,r-s),e.lineTo(n+o,r+s);break;case"dash":e.moveTo(n,r),e.lineTo(n+Math.cos(g)*m,r+Math.sin(g)*m);break;case!1:e.closePath();break}e.fill(),t.borderWidth>0&&e.stroke()}}function qr(e,t,n){return n=n||.5,!t||e&&e.x>t.left-n&&e.x<t.right+n&&e.y>t.top-n&&e.y<t.bottom+n}function Fm(e,t){e.save(),e.beginPath(),e.rect(t.left,t.top,t.right-t.left,t.bottom-t.top),e.clip()}function Bm(e){e.restore()}function d_(e,t,n,r,i){if(!t)return e.lineTo(n.x,n.y);if(i==="middle"){const a=(t.x+n.x)/2;e.lineTo(a,t.y),e.lineTo(a,n.y)}else i==="after"!=!!r?e.lineTo(t.x,n.y):e.lineTo(n.x,t.y);e.lineTo(n.x,n.y)}function h_(e,t,n,r){if(!t)return e.lineTo(n.x,n.y);e.bezierCurveTo(r?t.cp1x:t.cp2x,r?t.cp1y:t.cp2y,r?n.cp2x:n.cp1x,r?n.cp2y:n.cp1y,n.x,n.y)}function p_(e,t){t.translation&&e.translate(t.translation[0],t.translation[1]),H(t.rotation)||e.rotate(t.rotation),t.color&&(e.fillStyle=t.color),t.textAlign&&(e.textAlign=t.textAlign),t.textBaseline&&(e.textBaseline=t.textBaseline)}function g_(e,t,n,r,i){if(i.strikethrough||i.underline){const a=e.measureText(r),o=t-a.actualBoundingBoxLeft,s=t+a.actualBoundingBoxRight,l=n-a.actualBoundingBoxAscent,c=n+a.actualBoundingBoxDescent,u=i.strikethrough?(l+c)/2:c;e.strokeStyle=e.fillStyle,e.beginPath(),e.lineWidth=i.decorationWidth||2,e.moveTo(o,u),e.lineTo(s,u),e.stroke()}}function m_(e,t){const n=e.fillStyle;e.fillStyle=t.color,e.fillRect(t.left,t.top,t.width,t.height),e.fillStyle=n}function Ef(e,t,n,r,i,a={}){const o=me(t)?t:[t],s=a.strokeWidth>0&&a.strokeColor!=="";let l,c;for(e.save(),e.font=i.string,p_(e,a),l=0;l<o.length;++l)c=o[l],a.backdrop&&m_(e,a.backdrop),s&&(a.strokeColor&&(e.strokeStyle=a.strokeColor),H(a.strokeWidth)||(e.lineWidth=a.strokeWidth),e.strokeText(c,n,r,a.maxWidth)),e.fillText(c,n,r,a.maxWidth),g_(e,n,r,c,a),r+=Number(i.lineHeight);e.restore()}function Rl(e,t){const{x:n,y:r,w:i,h:a,radius:o}=t;e.arc(n+o.topLeft,r+o.topLeft,o.topLeft,1.5*de,de,!0),e.lineTo(n,r+a-o.bottomLeft),e.arc(n+o.bottomLeft,r+a-o.bottomLeft,o.bottomLeft,de,$e,!0),e.lineTo(n+i-o.bottomRight,r+a),e.arc(n+i-o.bottomRight,r+a-o.bottomRight,o.bottomRight,$e,0,!0),e.lineTo(n+i,r+o.topRight),e.arc(n+i-o.topRight,r+o.topRight,o.topRight,0,-$e,!0),e.lineTo(n+o.topLeft,r)}const v_=/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/,y_=/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/;function b_(e,t){const n=(""+e).match(v_);if(!n||n[1]==="normal")return t*1.2;switch(e=+n[2],n[3]){case"px":return e;case"%":e/=100;break}return t*e}const x_=e=>+e||0;function zm(e,t){const n={},r=$(t),i=r?Object.keys(t):t,a=$(e)?r?o=>V(e[o],e[t[o]]):o=>e[o]:()=>e;for(const o of i)n[o]=x_(a(o));return n}function $m(e){return zm(e,{top:"y",right:"x",bottom:"y",left:"x"})}function zr(e){return zm(e,["topLeft","topRight","bottomLeft","bottomRight"])}function Gt(e){const t=$m(e);return t.width=t.left+t.right,t.height=t.top+t.bottom,t}function pt(e,t){e=e||{},t=t||ae.font;let n=V(e.size,t.size);typeof n=="string"&&(n=parseInt(n,10));let r=V(e.style,t.style);r&&!(""+r).match(y_)&&(console.warn('Invalid font style specified: "'+r+'"'),r=void 0);const i={family:V(e.family,t.family),lineHeight:b_(V(e.lineHeight,t.lineHeight),n),size:n,style:r,weight:V(e.weight,t.weight),string:""};return i.string=u_(i),i}function ki(e,t,n,r){let i,a,o;for(i=0,a=e.length;i<a;++i)if(o=e[i],o!==void 0&&o!==void 0)return o}function __(e,t,n){const{min:r,max:i}=e,a=km(t,(i-r)/2),o=(s,l)=>n&&s===0?0:s+l;return{min:o(r,-Math.abs(a)),max:o(i,a)}}function jn(e,t){return Object.assign(Object.create(e),t)}function Rc(e,t=[""],n,r,i=()=>e[0]){const a=n||e;typeof r>"u"&&(r=Vm("_fallback",e));const o={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:e,_rootScopes:a,_fallback:r,_getTarget:i,override:s=>Rc([s,...e],t,a,r)};return new Proxy(o,{deleteProperty(s,l){return delete s[l],delete s._keys,delete e[0][l],!0},get(s,l){return qm(s,l,()=>C_(l,t,e,s))},getOwnPropertyDescriptor(s,l){return Reflect.getOwnPropertyDescriptor(s._scopes[0],l)},getPrototypeOf(){return Reflect.getPrototypeOf(e[0])},has(s,l){return Tf(s).includes(l)},ownKeys(s){return Tf(s)},set(s,l,c){const u=s._storage||(s._storage=i());return s[l]=u[l]=c,delete s._keys,!0}})}function Kn(e,t,n,r){const i={_cacheable:!1,_proxy:e,_context:t,_subProxy:n,_stack:new Set,_descriptors:Wm(e,r),setContext:a=>Kn(e,a,n,r),override:a=>Kn(e.override(a),t,n,r)};return new Proxy(i,{deleteProperty(a,o){return delete a[o],delete e[o],!0},get(a,o,s){return qm(a,o,()=>S_(a,o,s))},getOwnPropertyDescriptor(a,o){return a._descriptors.allKeys?Reflect.has(e,o)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(e,o)},getPrototypeOf(){return Reflect.getPrototypeOf(e)},has(a,o){return Reflect.has(e,o)},ownKeys(){return Reflect.ownKeys(e)},set(a,o,s){return e[o]=s,delete a[o],!0}})}function Wm(e,t={scriptable:!0,indexable:!0}){const{_scriptable:n=t.scriptable,_indexable:r=t.indexable,_allKeys:i=t.allKeys}=e;return{allKeys:i,scriptable:n,indexable:r,isScriptable:Xt(n)?n:()=>n,isIndexable:Xt(r)?r:()=>r}}const w_=(e,t)=>e?e+Tc(t):t,Lc=(e,t)=>$(t)&&e!=="adapters"&&(Object.getPrototypeOf(t)===null||t.constructor===Object);function qm(e,t,n){if(Object.prototype.hasOwnProperty.call(e,t)||t==="constructor")return e[t];const r=n();return e[t]=r,r}function S_(e,t,n){const{_proxy:r,_context:i,_subProxy:a,_descriptors:o}=e;let s=r[t];return Xt(s)&&o.isScriptable(t)&&(s=O_(t,s,e,n)),me(s)&&s.length&&(s=P_(t,s,e,o.isIndexable)),Lc(t,s)&&(s=Kn(s,i,a&&a[t],o)),s}function O_(e,t,n,r){const{_proxy:i,_context:a,_subProxy:o,_stack:s}=n;if(s.has(e))throw new Error("Recursion detected: "+Array.from(s).join("->")+"->"+e);s.add(e);let l=t(a,o||r);return s.delete(e),Lc(e,l)&&(l=Nc(i._scopes,i,e,l)),l}function P_(e,t,n,r){const{_proxy:i,_context:a,_subProxy:o,_descriptors:s}=n;if(typeof a.index<"u"&&r(e))return t[a.index%t.length];if($(t[0])){const l=t,c=i._scopes.filter(u=>u!==l);t=[];for(const u of l){const f=Nc(c,i,e,u);t.push(Kn(f,a,o&&o[e],s))}}return t}function Um(e,t,n){return Xt(e)?e(t,n):e}const M_=(e,t)=>e===!0?t:typeof e=="string"?Yt(t,e):void 0;function A_(e,t,n,r,i){for(const a of t){const o=M_(n,a);if(o){e.add(o);const s=Um(o._fallback,n,i);if(typeof s<"u"&&s!==n&&s!==r)return s}else if(o===!1&&typeof r<"u"&&n!==r)return null}return!1}function Nc(e,t,n,r){const i=t._rootScopes,a=Um(t._fallback,n,r),o=[...e,...i],s=new Set;s.add(r);let l=Df(s,o,n,a||n,r);return l===null||typeof a<"u"&&a!==n&&(l=Df(s,o,a,l,r),l===null)?!1:Rc(Array.from(s),[""],i,a,()=>k_(t,n,r))}function Df(e,t,n,r,i){for(;n;)n=A_(e,t,n,r,i);return n}function k_(e,t,n){const r=e._getTarget();t in r||(r[t]={});const i=r[t];return me(i)&&$(n)?n:i||{}}function C_(e,t,n,r){let i;for(const a of t)if(i=Vm(w_(a,e),n),typeof i<"u")return Lc(e,i)?Nc(n,r,e,i):i}function Vm(e,t){for(const n of t){if(!n)continue;const r=n[e];if(typeof r<"u")return r}}function Tf(e){let t=e._keys;return t||(t=e._keys=E_(e._scopes)),t}function E_(e){const t=new Set;for(const n of e)for(const r of Object.keys(n).filter(i=>!i.startsWith("_")))t.add(r);return Array.from(t)}function D_(e,t,n,r){const{iScale:i}=e,{key:a="r"}=this._parsing,o=new Array(r);let s,l,c,u;for(s=0,l=r;s<l;++s)c=s+n,u=t[c],o[s]={r:i.parse(Yt(u,a),c)};return o}const T_=Number.EPSILON||1e-14,Yn=(e,t)=>t<e.length&&!e[t].skip&&e[t],Hm=e=>e==="x"?"y":"x";function I_(e,t,n,r){const i=e.skip?t:e,a=t,o=n.skip?t:n,s=Dl(a,i),l=Dl(o,a);let c=s/(s+l),u=l/(s+l);c=isNaN(c)?0:c,u=isNaN(u)?0:u;const f=r*c,d=r*u;return{previous:{x:a.x-f*(o.x-i.x),y:a.y-f*(o.y-i.y)},next:{x:a.x+d*(o.x-i.x),y:a.y+d*(o.y-i.y)}}}function j_(e,t,n){const r=e.length;let i,a,o,s,l,c=Yn(e,0);for(let u=0;u<r-1;++u)if(l=c,c=Yn(e,u+1),!(!l||!c)){if(Nr(t[u],0,T_)){n[u]=n[u+1]=0;continue}i=n[u]/t[u],a=n[u+1]/t[u],s=Math.pow(i,2)+Math.pow(a,2),!(s<=9)&&(o=3/Math.sqrt(s),n[u]=i*o*t[u],n[u+1]=a*o*t[u])}}function R_(e,t,n="x"){const r=Hm(n),i=e.length;let a,o,s,l=Yn(e,0);for(let c=0;c<i;++c){if(o=s,s=l,l=Yn(e,c+1),!s)continue;const u=s[n],f=s[r];o&&(a=(u-o[n])/3,s[`cp1${n}`]=u-a,s[`cp1${r}`]=f-a*t[c]),l&&(a=(l[n]-u)/3,s[`cp2${n}`]=u+a,s[`cp2${r}`]=f+a*t[c])}}function L_(e,t="x"){const n=Hm(t),r=e.length,i=Array(r).fill(0),a=Array(r);let o,s,l,c=Yn(e,0);for(o=0;o<r;++o)if(s=l,l=c,c=Yn(e,o+1),!!l){if(c){const u=c[t]-l[t];i[o]=u!==0?(c[n]-l[n])/u:0}a[o]=s?c?vt(i[o-1])!==vt(i[o])?0:(i[o-1]+i[o])/2:i[o-1]:i[o]}j_(e,i,a),R_(e,a,t)}function Ci(e,t,n){return Math.max(Math.min(e,n),t)}function N_(e,t){let n,r,i,a,o,s=qr(e[0],t);for(n=0,r=e.length;n<r;++n)o=a,a=s,s=n<r-1&&qr(e[n+1],t),a&&(i=e[n],o&&(i.cp1x=Ci(i.cp1x,t.left,t.right),i.cp1y=Ci(i.cp1y,t.top,t.bottom)),s&&(i.cp2x=Ci(i.cp2x,t.left,t.right),i.cp2y=Ci(i.cp2y,t.top,t.bottom)))}function F_(e,t,n,r,i){let a,o,s,l;if(t.spanGaps&&(e=e.filter(c=>!c.skip)),t.cubicInterpolationMode==="monotone")L_(e,i);else{let c=r?e[e.length-1]:e[0];for(a=0,o=e.length;a<o;++a)s=e[a],l=I_(c,s,e[Math.min(a+1,o-(r?0:1))%o],t.tension),s.cp1x=l.previous.x,s.cp1y=l.previous.y,s.cp2x=l.next.x,s.cp2y=l.next.y,c=s}t.capBezierPoints&&N_(e,n)}function Fc(){return typeof window<"u"&&typeof document<"u"}function Bc(e){let t=e.parentNode;return t&&t.toString()==="[object ShadowRoot]"&&(t=t.host),t}function fa(e,t,n){let r;return typeof e=="string"?(r=parseInt(e,10),e.indexOf("%")!==-1&&(r=r/100*t.parentNode[n])):r=e,r}const eo=e=>e.ownerDocument.defaultView.getComputedStyle(e,null);function B_(e,t){return eo(e).getPropertyValue(t)}const z_=["top","right","bottom","left"];function Sn(e,t,n){const r={};n=n?"-"+n:"";for(let i=0;i<4;i++){const a=z_[i];r[a]=parseFloat(e[t+"-"+a+n])||0}return r.width=r.left+r.right,r.height=r.top+r.bottom,r}const $_=(e,t,n)=>(e>0||t>0)&&(!n||!n.shadowRoot);function W_(e,t){const n=e.touches,r=n&&n.length?n[0]:e,{offsetX:i,offsetY:a}=r;let o=!1,s,l;if($_(i,a,e.target))s=i,l=a;else{const c=t.getBoundingClientRect();s=r.clientX-c.left,l=r.clientY-c.top,o=!0}return{x:s,y:l,box:o}}function hn(e,t){if("native"in e)return e;const{canvas:n,currentDevicePixelRatio:r}=t,i=eo(n),a=i.boxSizing==="border-box",o=Sn(i,"padding"),s=Sn(i,"border","width"),{x:l,y:c,box:u}=W_(e,n),f=o.left+(u&&s.left),d=o.top+(u&&s.top);let{width:h,height:p}=t;return a&&(h-=o.width+s.width,p-=o.height+s.height),{x:Math.round((l-f)/h*n.width/r),y:Math.round((c-d)/p*n.height/r)}}function q_(e,t,n){let r,i;if(t===void 0||n===void 0){const a=e&&Bc(e);if(!a)t=e.clientWidth,n=e.clientHeight;else{const o=a.getBoundingClientRect(),s=eo(a),l=Sn(s,"border","width"),c=Sn(s,"padding");t=o.width-c.width-l.width,n=o.height-c.height-l.height,r=fa(s.maxWidth,a,"clientWidth"),i=fa(s.maxHeight,a,"clientHeight")}}return{width:t,height:n,maxWidth:r||ca,maxHeight:i||ca}}const Wt=e=>Math.round(e*10)/10;function U_(e,t,n,r){const i=eo(e),a=Sn(i,"margin"),o=fa(i.maxWidth,e,"clientWidth")||ca,s=fa(i.maxHeight,e,"clientHeight")||ca,l=q_(e,t,n);let{width:c,height:u}=l;if(i.boxSizing==="content-box"){const d=Sn(i,"border","width"),h=Sn(i,"padding");c-=h.width+d.width,u-=h.height+d.height}return c=Math.max(0,c-a.width),u=Math.max(0,r?c/r:u-a.height),c=Wt(Math.min(c,o,l.maxWidth)),u=Wt(Math.min(u,s,l.maxHeight)),c&&!u&&(u=Wt(c/2)),(t!==void 0||n!==void 0)&&r&&l.height&&u>l.height&&(u=l.height,c=Wt(Math.floor(u*r))),{width:c,height:u}}function If(e,t,n){const r=t||1,i=Wt(e.height*r),a=Wt(e.width*r);e.height=Wt(e.height),e.width=Wt(e.width);const o=e.canvas;return o.style&&(n||!o.style.height&&!o.style.width)&&(o.style.height=`${e.height}px`,o.style.width=`${e.width}px`),e.currentDevicePixelRatio!==r||o.height!==i||o.width!==a?(e.currentDevicePixelRatio=r,o.height=i,o.width=a,e.ctx.setTransform(r,0,0,r,0,0),!0):!1}const V_=(function(){let e=!1;try{const t={get passive(){return e=!0,!1}};Fc()&&(window.addEventListener("test",null,t),window.removeEventListener("test",null,t))}catch{}return e})();function jf(e,t){const n=B_(e,t),r=n&&n.match(/^(\d+)(\.\d+)?px$/);return r?+r[1]:void 0}function pn(e,t,n,r){return{x:e.x+n*(t.x-e.x),y:e.y+n*(t.y-e.y)}}function H_(e,t,n,r){return{x:e.x+n*(t.x-e.x),y:r==="middle"?n<.5?e.y:t.y:r==="after"?n<1?e.y:t.y:n>0?t.y:e.y}}function K_(e,t,n,r){const i={x:e.cp2x,y:e.cp2y},a={x:t.cp1x,y:t.cp1y},o=pn(e,i,n),s=pn(i,a,n),l=pn(a,t,n),c=pn(o,s,n),u=pn(s,l,n);return pn(c,u,n)}const Y_=function(e,t){return{x(n){return e+e+t-n},setWidth(n){t=n},textAlign(n){return n==="center"?n:n==="right"?"left":"right"},xPlus(n,r){return n-r},leftForLtr(n,r){return n-r}}},X_=function(){return{x(e){return e},setWidth(e){},textAlign(e){return e},xPlus(e,t){return e+t},leftForLtr(e,t){return e}}};function Vo(e,t,n){return e?Y_(t,n):X_()}function G_(e,t){let n,r;(t==="ltr"||t==="rtl")&&(n=e.canvas.style,r=[n.getPropertyValue("direction"),n.getPropertyPriority("direction")],n.setProperty("direction",t,"important"),e.prevTextDirection=r)}function Z_(e,t){t!==void 0&&(delete e.prevTextDirection,e.canvas.style.setProperty("direction",t[0],t[1]))}function Km(e){return e==="angle"?{between:ua,compare:Yx,normalize:Ft}:{between:Tl,compare:(t,n)=>t-n,normalize:t=>t}}function Rf({start:e,end:t,count:n,loop:r,style:i}){return{start:e%n,end:t%n,loop:r&&(t-e+1)%n===0,style:i}}function Q_(e,t,n){const{property:r,start:i,end:a}=n,{between:o,normalize:s}=Km(r),l=t.length;let{start:c,end:u,loop:f}=e,d,h;if(f){for(c+=l,u+=l,d=0,h=l;d<h&&o(s(t[c%l][r]),i,a);++d)c--,u--;c%=l,u%=l}return u<c&&(u+=l),{start:c,end:u,loop:f,style:e.style}}function J_(e,t,n){if(!n)return[e];const{property:r,start:i,end:a}=n,o=t.length,{compare:s,between:l,normalize:c}=Km(r),{start:u,end:f,loop:d,style:h}=Q_(e,t,n),p=[];let m=!1,g=null,v,y,b;const _=()=>l(i,b,v)&&s(i,b)!==0,x=()=>s(a,v)===0||l(a,b,v),S=()=>m||_(),O=()=>!m||x();for(let M=u,E=u;M<=f;++M)y=t[M%o],!y.skip&&(v=c(y[r]),v!==b&&(m=l(v,i,a),g===null&&S()&&(g=s(v,i)===0?M:E),g!==null&&O()&&(p.push(Rf({start:g,end:M,loop:d,count:o,style:h})),g=null),E=M,b=v));return g!==null&&p.push(Rf({start:g,end:f,loop:d,count:o,style:h})),p}function ew(e,t){const n=[],r=e.segments;for(let i=0;i<r.length;i++){const a=J_(r[i],e.points,t);a.length&&n.push(...a)}return n}function tw(e,t,n,r){let i=0,a=t-1;if(n&&!r)for(;i<t&&!e[i].skip;)i++;for(;i<t&&e[i].skip;)i++;for(i%=t,n&&(a+=i);a>i&&e[a%t].skip;)a--;return a%=t,{start:i,end:a}}function nw(e,t,n,r){const i=e.length,a=[];let o=t,s=e[t],l;for(l=t+1;l<=n;++l){const c=e[l%i];c.skip||c.stop?s.skip||(r=!1,a.push({start:t%i,end:(l-1)%i,loop:r}),t=o=c.stop?l:null):(o=l,s.skip&&(t=l)),s=c}return o!==null&&a.push({start:t%i,end:o%i,loop:r}),a}function rw(e,t){const n=e.points,r=e.options.spanGaps,i=n.length;if(!i)return[];const a=!!e._loop,{start:o,end:s}=tw(n,i,a,r);if(r===!0)return Lf(e,[{start:o,end:s,loop:a}],n,t);const l=s<o?s+i:s,c=!!e._fullLoop&&o===0&&s===i-1;return Lf(e,nw(n,o,l,c),n,t)}function Lf(e,t,n,r){return!r||!r.setContext||!n?t:iw(e,t,n,r)}function iw(e,t,n,r){const i=e._chart.getContext(),a=Nf(e.options),{_datasetIndex:o,options:{spanGaps:s}}=e,l=n.length,c=[];let u=a,f=t[0].start,d=f;function h(p,m,g,v){const y=s?-1:1;if(p!==m){for(p+=l;n[p%l].skip;)p-=y;for(;n[m%l].skip;)m+=y;p%l!==m%l&&(c.push({start:p%l,end:m%l,loop:g,style:v}),u=v,f=m%l)}}for(const p of t){f=s?f:p.start;let m=n[f%l],g;for(d=f+1;d<=p.end;d++){const v=n[d%l];g=Nf(r.setContext(jn(i,{type:"segment",p0:m,p1:v,p0DataIndex:(d-1)%l,p1DataIndex:d%l,datasetIndex:o}))),aw(g,u)&&h(f,d-1,p.loop,u),m=v,u=g}f<d-1&&h(f,d-1,p.loop,u)}return c}function Nf(e){return{backgroundColor:e.backgroundColor,borderCapStyle:e.borderCapStyle,borderDash:e.borderDash,borderDashOffset:e.borderDashOffset,borderJoinStyle:e.borderJoinStyle,borderWidth:e.borderWidth,borderColor:e.borderColor}}function aw(e,t){if(!t)return!1;const n=[],r=function(i,a){return jc(a)?(n.includes(a)||n.push(a),n.indexOf(a)):a};return JSON.stringify(e,r)!==JSON.stringify(t,r)}function Ei(e,t,n){return e.options.clip?e[n]:t[n]}function ow(e,t){const{xScale:n,yScale:r}=e;return n&&r?{left:Ei(n,t,"left"),right:Ei(n,t,"right"),top:Ei(r,t,"top"),bottom:Ei(r,t,"bottom")}:t}function sw(e,t){const n=t._clip;if(n.disabled)return!1;const r=ow(t,e.chartArea);return{left:n.left===!1?0:r.left-(n.left===!0?0:n.left),right:n.right===!1?e.width:r.right+(n.right===!0?0:n.right),top:n.top===!1?0:r.top-(n.top===!0?0:n.top),bottom:n.bottom===!1?e.height:r.bottom+(n.bottom===!0?0:n.bottom)}}class lw{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,n,r,i){const a=n.listeners[i],o=n.duration;a.forEach(s=>s({chart:t,initial:n.initial,numSteps:o,currentStep:Math.min(r-n.start,o)}))}_refresh(){this._request||(this._running=!0,this._request=Im.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let n=0;this._charts.forEach((r,i)=>{if(!r.running||!r.items.length)return;const a=r.items;let o=a.length-1,s=!1,l;for(;o>=0;--o)l=a[o],l._active?(l._total>r.duration&&(r.duration=l._total),l.tick(t),s=!0):(a[o]=a[a.length-1],a.pop());s&&(i.draw(),this._notify(i,r,t,"progress")),a.length||(r.running=!1,this._notify(i,r,t,"complete"),r.initial=!1),n+=a.length}),this._lastDate=t,n===0&&(this._running=!1)}_getAnims(t){const n=this._charts;let r=n.get(t);return r||(r={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},n.set(t,r)),r}listen(t,n,r){this._getAnims(t).listeners[n].push(r)}add(t,n){!n||!n.length||this._getAnims(t).items.push(...n)}has(t){return this._getAnims(t).items.length>0}start(t){const n=this._charts.get(t);n&&(n.running=!0,n.start=Date.now(),n.duration=n.items.reduce((r,i)=>Math.max(r,i._duration),0),this._refresh())}running(t){if(!this._running)return!1;const n=this._charts.get(t);return!(!n||!n.running||!n.items.length)}stop(t){const n=this._charts.get(t);if(!n||!n.items.length)return;const r=n.items;let i=r.length-1;for(;i>=0;--i)r[i].cancel();n.items=[],this._notify(t,n,Date.now(),"complete")}remove(t){return this._charts.delete(t)}}var wt=new lw;const Ff="transparent",cw={boolean(e,t,n){return n>.5?t:e},color(e,t,n){const r=Mf(e||Ff),i=r.valid&&Mf(t||Ff);return i&&i.valid?i.mix(r,n).hexString():t},number(e,t,n){return e+(t-e)*n}};class uw{constructor(t,n,r,i){const a=n[r];i=ki([t.to,i,a,t.from]);const o=ki([t.from,a,i]);this._active=!0,this._fn=t.fn||cw[t.type||typeof o],this._easing=Fr[t.easing]||Fr.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=n,this._prop=r,this._from=o,this._to=i,this._promises=void 0}active(){return this._active}update(t,n,r){if(this._active){this._notify(!1);const i=this._target[this._prop],a=r-this._start,o=this._duration-a;this._start=r,this._duration=Math.floor(Math.max(o,t.duration)),this._total+=a,this._loop=!!t.loop,this._to=ki([t.to,n,i,t.from]),this._from=ki([t.from,i,n])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const n=t-this._start,r=this._duration,i=this._prop,a=this._from,o=this._loop,s=this._to;let l;if(this._active=a!==s&&(o||n<r),!this._active){this._target[i]=s,this._notify(!0);return}if(n<0){this._target[i]=a;return}l=n/r%2,l=o&&l>1?2-l:l,l=this._easing(Math.min(1,Math.max(0,l))),this._target[i]=this._fn(a,s,l)}wait(){const t=this._promises||(this._promises=[]);return new Promise((n,r)=>{t.push({res:n,rej:r})})}_notify(t){const n=t?"res":"rej",r=this._promises||[];for(let i=0;i<r.length;i++)r[i][n]()}}class Ym{constructor(t,n){this._chart=t,this._properties=new Map,this.configure(n)}configure(t){if(!$(t))return;const n=Object.keys(ae.animation),r=this._properties;Object.getOwnPropertyNames(t).forEach(i=>{const a=t[i];if(!$(a))return;const o={};for(const s of n)o[s]=a[s];(me(a.properties)&&a.properties||[i]).forEach(s=>{(s===i||!r.has(s))&&r.set(s,o)})})}_animateOptions(t,n){const r=n.options,i=dw(t,r);if(!i)return[];const a=this._createAnimations(i,r);return r.$shared&&fw(t.options.$animations,r).then(()=>{t.options=r},()=>{}),a}_createAnimations(t,n){const r=this._properties,i=[],a=t.$animations||(t.$animations={}),o=Object.keys(n),s=Date.now();let l;for(l=o.length-1;l>=0;--l){const c=o[l];if(c.charAt(0)==="$")continue;if(c==="options"){i.push(...this._animateOptions(t,n));continue}const u=n[c];let f=a[c];const d=r.get(c);if(f)if(d&&f.active()){f.update(d,u,s);continue}else f.cancel();if(!d||!d.duration){t[c]=u;continue}a[c]=f=new uw(d,t,c,u),i.push(f)}return i}update(t,n){if(this._properties.size===0){Object.assign(t,n);return}const r=this._createAnimations(t,n);if(r.length)return wt.add(this._chart,r),!0}}function fw(e,t){const n=[],r=Object.keys(t);for(let i=0;i<r.length;i++){const a=e[r[i]];a&&a.active()&&n.push(a.wait())}return Promise.all(n)}function dw(e,t){if(!t)return;let n=e.options;if(!n){e.options=t;return}return n.$shared&&(e.options=n=Object.assign({},n,{$shared:!1,$animations:{}})),n}function Bf(e,t){const n=e&&e.options||{},r=n.reverse,i=n.min===void 0?t:0,a=n.max===void 0?t:0;return{start:r?a:i,end:r?i:a}}function hw(e,t,n){if(n===!1)return!1;const r=Bf(e,n),i=Bf(t,n);return{top:i.end,right:r.end,bottom:i.start,left:r.start}}function pw(e){let t,n,r,i;return $(e)?(t=e.top,n=e.right,r=e.bottom,i=e.left):t=n=r=i=e,{top:t,right:n,bottom:r,left:i,disabled:e===!1}}function Xm(e,t){const n=[],r=e._getSortedDatasetMetas(t);let i,a;for(i=0,a=r.length;i<a;++i)n.push(r[i].index);return n}function zf(e,t,n,r={}){const i=e.keys,a=r.mode==="single";let o,s,l,c;if(t===null)return;let u=!1;for(o=0,s=i.length;o<s;++o){if(l=+i[o],l===n){if(u=!0,r.all)continue;break}c=e.values[l],Qe(c)&&(a||t===0||vt(t)===vt(c))&&(t+=c)}return!u&&!r.all?0:t}function gw(e,t){const{iScale:n,vScale:r}=t,i=n.axis==="x"?"x":"y",a=r.axis==="x"?"x":"y",o=Object.keys(e),s=new Array(o.length);let l,c,u;for(l=0,c=o.length;l<c;++l)u=o[l],s[l]={[i]:u,[a]:e[u]};return s}function Ho(e,t){const n=e&&e.options.stacked;return n||n===void 0&&t.stack!==void 0}function mw(e,t,n){return`${e.id}.${t.id}.${n.stack||n.type}`}function vw(e){const{min:t,max:n,minDefined:r,maxDefined:i}=e.getUserBounds();return{min:r?t:Number.NEGATIVE_INFINITY,max:i?n:Number.POSITIVE_INFINITY}}function yw(e,t,n){const r=e[t]||(e[t]={});return r[n]||(r[n]={})}function $f(e,t,n,r){for(const i of t.getMatchingVisibleMetas(r).reverse()){const a=e[i.index];if(n&&a>0||!n&&a<0)return i.index}return null}function Wf(e,t){const{chart:n,_cachedMeta:r}=e,i=n._stacks||(n._stacks={}),{iScale:a,vScale:o,index:s}=r,l=a.axis,c=o.axis,u=mw(a,o,r),f=t.length;let d;for(let h=0;h<f;++h){const p=t[h],{[l]:m,[c]:g}=p,v=p._stacks||(p._stacks={});d=v[c]=yw(i,u,m),d[s]=g,d._top=$f(d,o,!0,r.type),d._bottom=$f(d,o,!1,r.type);const y=d._visualValues||(d._visualValues={});y[s]=g}}function Ko(e,t){const n=e.scales;return Object.keys(n).filter(r=>n[r].axis===t).shift()}function bw(e,t){return jn(e,{active:!1,dataset:void 0,datasetIndex:t,index:t,mode:"default",type:"dataset"})}function xw(e,t,n){return jn(e,{active:!1,dataIndex:t,parsed:void 0,raw:void 0,element:n,index:t,mode:"default",type:"data"})}function yr(e,t){const n=e.controller.index,r=e.vScale&&e.vScale.axis;if(r){t=t||e._parsed;for(const i of t){const a=i._stacks;if(!a||a[r]===void 0||a[r][n]===void 0)return;delete a[r][n],a[r]._visualValues!==void 0&&a[r]._visualValues[n]!==void 0&&delete a[r]._visualValues[n]}}}const Yo=e=>e==="reset"||e==="none",qf=(e,t)=>t?e:Object.assign({},e),_w=(e,t,n)=>e&&!t.hidden&&t._stacked&&{keys:Xm(n,!0),values:null};class ir{static defaults={};static datasetElementType=null;static dataElementType=null;constructor(t,n){this.chart=t,this._ctx=t.ctx,this.index=n,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){const t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=Ho(t.vScale,t),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(t){this.index!==t&&yr(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,n=this._cachedMeta,r=this.getDataset(),i=(f,d,h,p)=>f==="x"?d:f==="r"?p:h,a=n.xAxisID=V(r.xAxisID,Ko(t,"x")),o=n.yAxisID=V(r.yAxisID,Ko(t,"y")),s=n.rAxisID=V(r.rAxisID,Ko(t,"r")),l=n.indexAxis,c=n.iAxisID=i(l,a,o,s),u=n.vAxisID=i(l,o,a,s);n.xScale=this.getScaleForId(a),n.yScale=this.getScaleForId(o),n.rScale=this.getScaleForId(s),n.iScale=this.getScaleForId(c),n.vScale=this.getScaleForId(u)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const n=this._cachedMeta;return t===n.iScale?n.vScale:n.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&wf(this._data,this),t._stacked&&yr(t)}_dataCheck(){const t=this.getDataset(),n=t.data||(t.data=[]),r=this._data;if($(n)){const i=this._cachedMeta;this._data=gw(n,i)}else if(r!==n){if(r){wf(r,this);const i=this._cachedMeta;yr(i),i._parsed=[]}n&&Object.isExtensible(n)&&Qx(n,this),this._syncList=[],this._data=n}}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const n=this._cachedMeta,r=this.getDataset();let i=!1;this._dataCheck();const a=n._stacked;n._stacked=Ho(n.vScale,n),n.stack!==r.stack&&(i=!0,yr(n),n.stack=r.stack),this._resyncElements(t),(i||a!==n._stacked)&&(Wf(this,n._parsed),n._stacked=Ho(n.vScale,n))}configure(){const t=this.chart.config,n=t.datasetScopeKeys(this._type),r=t.getOptionScopes(this.getDataset(),n,!0);this.options=t.createResolver(r,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,n){const{_cachedMeta:r,_data:i}=this,{iScale:a,_stacked:o}=r,s=a.axis;let l=t===0&&n===i.length?!0:r._sorted,c=t>0&&r._parsed[t-1],u,f,d;if(this._parsing===!1)r._parsed=i,r._sorted=!0,d=i;else{me(i[t])?d=this.parseArrayData(r,i,t,n):$(i[t])?d=this.parseObjectData(r,i,t,n):d=this.parsePrimitiveData(r,i,t,n);const h=()=>f[s]===null||c&&f[s]<c[s];for(u=0;u<n;++u)r._parsed[u+t]=f=d[u],l&&(h()&&(l=!1),c=f);r._sorted=l}o&&Wf(this,d)}parsePrimitiveData(t,n,r,i){const{iScale:a,vScale:o}=t,s=a.axis,l=o.axis,c=a.getLabels(),u=a===o,f=new Array(i);let d,h,p;for(d=0,h=i;d<h;++d)p=d+r,f[d]={[s]:u||a.parse(c[p],p),[l]:o.parse(n[p],p)};return f}parseArrayData(t,n,r,i){const{xScale:a,yScale:o}=t,s=new Array(i);let l,c,u,f;for(l=0,c=i;l<c;++l)u=l+r,f=n[u],s[l]={x:a.parse(f[0],u),y:o.parse(f[1],u)};return s}parseObjectData(t,n,r,i){const{xScale:a,yScale:o}=t,{xAxisKey:s="x",yAxisKey:l="y"}=this._parsing,c=new Array(i);let u,f,d,h;for(u=0,f=i;u<f;++u)d=u+r,h=n[d],c[u]={x:a.parse(Yt(h,s),d),y:o.parse(Yt(h,l),d)};return c}getParsed(t){return this._cachedMeta._parsed[t]}getDataElement(t){return this._cachedMeta.data[t]}applyStack(t,n,r){const i=this.chart,a=this._cachedMeta,o=n[t.axis],s={keys:Xm(i,!0),values:n._stacks[t.axis]._visualValues};return zf(s,o,a.index,{mode:r})}updateRangeFromParsed(t,n,r,i){const a=r[n.axis];let o=a===null?NaN:a;const s=i&&r._stacks[n.axis];i&&s&&(i.values=s,o=zf(i,a,this._cachedMeta.index)),t.min=Math.min(t.min,o),t.max=Math.max(t.max,o)}getMinMax(t,n){const r=this._cachedMeta,i=r._parsed,a=r._sorted&&t===r.iScale,o=i.length,s=this._getOtherScale(t),l=_w(n,r,this.chart),c={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:u,max:f}=vw(s);let d,h;function p(){h=i[d];const m=h[s.axis];return!Qe(h[t.axis])||u>m||f<m}for(d=0;d<o&&!(!p()&&(this.updateRangeFromParsed(c,t,h,l),a));++d);if(a){for(d=o-1;d>=0;--d)if(!p()){this.updateRangeFromParsed(c,t,h,l);break}}return c}getAllParsedValues(t){const n=this._cachedMeta._parsed,r=[];let i,a,o;for(i=0,a=n.length;i<a;++i)o=n[i][t.axis],Qe(o)&&r.push(o);return r}getMaxOverflow(){return!1}getLabelAndValue(t){const n=this._cachedMeta,r=n.iScale,i=n.vScale,a=this.getParsed(t);return{label:r?""+r.getLabelForValue(a[r.axis]):"",value:i?""+i.getLabelForValue(a[i.axis]):""}}_update(t){const n=this._cachedMeta;this.update(t||"default"),n._clip=pw(V(this.options.clip,hw(n.xScale,n.yScale,this.getMaxOverflow())))}update(t){}draw(){const t=this._ctx,n=this.chart,r=this._cachedMeta,i=r.data||[],a=n.chartArea,o=[],s=this._drawStart||0,l=this._drawCount||i.length-s,c=this.options.drawActiveElementsOnTop;let u;for(r.dataset&&r.dataset.draw(t,a,s,l),u=s;u<s+l;++u){const f=i[u];f.hidden||(f.active&&c?o.push(f):f.draw(t,a))}for(u=0;u<o.length;++u)o[u].draw(t,a)}getStyle(t,n){const r=n?"active":"default";return t===void 0&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(r):this.resolveDataElementOptions(t||0,r)}getContext(t,n,r){const i=this.getDataset();let a;if(t>=0&&t<this._cachedMeta.data.length){const o=this._cachedMeta.data[t];a=o.$context||(o.$context=xw(this.getContext(),t,o)),a.parsed=this.getParsed(t),a.raw=i.data[t],a.index=a.dataIndex=t}else a=this.$context||(this.$context=bw(this.chart.getContext(),this.index)),a.dataset=i,a.index=a.datasetIndex=this.index;return a.active=!!n,a.mode=r,a}resolveDatasetElementOptions(t){return this._resolveElementOptions(this.datasetElementType.id,t)}resolveDataElementOptions(t,n){return this._resolveElementOptions(this.dataElementType.id,n,t)}_resolveElementOptions(t,n="default",r){const i=n==="active",a=this._cachedDataOpts,o=t+"-"+n,s=a[o],l=this.enableOptionSharing&&Wr(r);if(s)return qf(s,l);const c=this.chart.config,u=c.datasetElementScopeKeys(this._type,t),f=i?[`${t}Hover`,"hover",t,""]:[t,""],d=c.getOptionScopes(this.getDataset(),u),h=Object.keys(ae.elements[t]),p=()=>this.getContext(r,i,n),m=c.resolveNamedOptions(d,h,p,f);return m.$shared&&(m.$shared=l,a[o]=Object.freeze(qf(m,l))),m}_resolveAnimations(t,n,r){const i=this.chart,a=this._cachedDataOpts,o=`animation-${n}`,s=a[o];if(s)return s;let l;if(i.options.animation!==!1){const u=this.chart.config,f=u.datasetAnimationScopeKeys(this._type,n),d=u.getOptionScopes(this.getDataset(),f);l=u.createResolver(d,this.getContext(t,r,n))}const c=new Ym(i,l&&l.animations);return l&&l._cacheable&&(a[o]=Object.freeze(c)),c}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,n){return!n||Yo(t)||this.chart._animationsDisabled}_getSharedOptions(t,n){const r=this.resolveDataElementOptions(t,n),i=this._sharedOptions,a=this.getSharedOptions(r),o=this.includeOptions(n,a)||a!==i;return this.updateSharedOptions(a,n,r),{sharedOptions:a,includeOptions:o}}updateElement(t,n,r,i){Yo(i)?Object.assign(t,r):this._resolveAnimations(n,i).update(t,r)}updateSharedOptions(t,n,r){t&&!Yo(n)&&this._resolveAnimations(void 0,n).update(t,r)}_setStyle(t,n,r,i){t.active=i;const a=this.getStyle(n,i);this._resolveAnimations(n,r,i).update(t,{options:!i&&this.getSharedOptions(a)||a})}removeHoverStyle(t,n,r){this._setStyle(t,r,"active",!1)}setHoverStyle(t,n,r){this._setStyle(t,r,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const n=this._data,r=this._cachedMeta.data;for(const[s,l,c]of this._syncList)this[s](l,c);this._syncList=[];const i=r.length,a=n.length,o=Math.min(a,i);o&&this.parse(0,o),a>i?this._insertElements(i,a-i,t):a<i&&this._removeElements(a,i-a)}_insertElements(t,n,r=!0){const i=this._cachedMeta,a=i.data,o=t+n;let s;const l=c=>{for(c.length+=n,s=c.length-1;s>=o;s--)c[s]=c[s-n]};for(l(a),s=t;s<o;++s)a[s]=new this.dataElementType;this._parsing&&l(i._parsed),this.parse(t,n),r&&this.updateElements(a,t,n,"reset")}updateElements(t,n,r,i){}_removeElements(t,n){const r=this._cachedMeta;if(this._parsing){const i=r._parsed.splice(t,n);r._stacked&&yr(r,i)}r.data.splice(t,n)}_sync(t){if(this._parsing)this._syncList.push(t);else{const[n,r,i]=t;this[n](r,i)}this.chart._dataChanges.push([this.index,...t])}_onDataPush(){const t=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-t,t])}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1])}_onDataShift(){this._sync(["_removeElements",0,1])}_onDataSplice(t,n){n&&this._sync(["_removeElements",t,n]);const r=arguments.length-2;r&&this._sync(["_insertElements",t,r])}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length])}}function ww(e,t){if(!e._cache.$bar){const n=e.getMatchingVisibleMetas(t);let r=[];for(let i=0,a=n.length;i<a;i++)r=r.concat(n[i].controller.getAllParsedValues(e));e._cache.$bar=Tm(r.sort((i,a)=>i-a))}return e._cache.$bar}function Sw(e){const t=e.iScale,n=ww(t,e.type);let r=t._length,i,a,o,s;const l=()=>{o===32767||o===-32768||(Wr(s)&&(r=Math.min(r,Math.abs(o-s)||r)),s=o)};for(i=0,a=n.length;i<a;++i)o=t.getPixelForValue(n[i]),l();for(s=void 0,i=0,a=t.ticks.length;i<a;++i)o=t.getPixelForTick(i),l();return r}function Ow(e,t,n,r){const i=n.barThickness;let a,o;return H(i)?(a=t.min*n.categoryPercentage,o=n.barPercentage):(a=i*r,o=1),{chunk:a/r,ratio:o,start:t.pixels[e]-a/2}}function Pw(e,t,n,r){const i=t.pixels,a=i[e];let o=e>0?i[e-1]:null,s=e<i.length-1?i[e+1]:null;const l=n.categoryPercentage;o===null&&(o=a-(s===null?t.end-t.start:s-a)),s===null&&(s=a+a-o);const c=a-(a-Math.min(o,s))/2*l;return{chunk:Math.abs(s-o)/2*l/r,ratio:n.barPercentage,start:c}}function Mw(e,t,n,r){const i=n.parse(e[0],r),a=n.parse(e[1],r),o=Math.min(i,a),s=Math.max(i,a);let l=o,c=s;Math.abs(o)>Math.abs(s)&&(l=s,c=o),t[n.axis]=c,t._custom={barStart:l,barEnd:c,start:i,end:a,min:o,max:s}}function Gm(e,t,n,r){return me(e)?Mw(e,t,n,r):t[n.axis]=n.parse(e,r),t}function Uf(e,t,n,r){const i=e.iScale,a=e.vScale,o=i.getLabels(),s=i===a,l=[];let c,u,f,d;for(c=n,u=n+r;c<u;++c)d=t[c],f={},f[i.axis]=s||i.parse(o[c],c),l.push(Gm(d,f,a,c));return l}function Xo(e){return e&&e.barStart!==void 0&&e.barEnd!==void 0}function Aw(e,t,n){return e!==0?vt(e):(t.isHorizontal()?1:-1)*(t.min>=n?1:-1)}function kw(e){let t,n,r,i,a;return e.horizontal?(t=e.base>e.x,n="left",r="right"):(t=e.base<e.y,n="bottom",r="top"),t?(i="end",a="start"):(i="start",a="end"),{start:n,end:r,reverse:t,top:i,bottom:a}}function Cw(e,t,n,r){let i=t.borderSkipped;const a={};if(!i){e.borderSkipped=a;return}if(i===!0){e.borderSkipped={top:!0,right:!0,bottom:!0,left:!0};return}const{start:o,end:s,reverse:l,top:c,bottom:u}=kw(e);i==="middle"&&n&&(e.enableBorderRadius=!0,(n._top||0)===r?i=c:(n._bottom||0)===r?i=u:(a[Vf(u,o,s,l)]=!0,i=c)),a[Vf(i,o,s,l)]=!0,e.borderSkipped=a}function Vf(e,t,n,r){return r?(e=Ew(e,t,n),e=Hf(e,n,t)):e=Hf(e,t,n),e}function Ew(e,t,n){return e===t?n:e===n?t:e}function Hf(e,t,n){return e==="start"?t:e==="end"?n:e}function Dw(e,{inflateAmount:t},n){e.inflateAmount=t==="auto"?n===1?.33:0:t}class XR extends ir{static id="bar";static defaults={datasetElementType:!1,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:!0,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}};static overrides={scales:{_index_:{type:"category",offset:!0,grid:{offset:!0}},_value_:{type:"linear",beginAtZero:!0}}};parsePrimitiveData(t,n,r,i){return Uf(t,n,r,i)}parseArrayData(t,n,r,i){return Uf(t,n,r,i)}parseObjectData(t,n,r,i){const{iScale:a,vScale:o}=t,{xAxisKey:s="x",yAxisKey:l="y"}=this._parsing,c=a.axis==="x"?s:l,u=o.axis==="x"?s:l,f=[];let d,h,p,m;for(d=r,h=r+i;d<h;++d)m=n[d],p={},p[a.axis]=a.parse(Yt(m,c),d),f.push(Gm(Yt(m,u),p,o,d));return f}updateRangeFromParsed(t,n,r,i){super.updateRangeFromParsed(t,n,r,i);const a=r._custom;a&&n===this._cachedMeta.vScale&&(t.min=Math.min(t.min,a.min),t.max=Math.max(t.max,a.max))}getMaxOverflow(){return 0}getLabelAndValue(t){const n=this._cachedMeta,{iScale:r,vScale:i}=n,a=this.getParsed(t),o=a._custom,s=Xo(o)?"["+o.start+", "+o.end+"]":""+i.getLabelForValue(a[i.axis]);return{label:""+r.getLabelForValue(a[r.axis]),value:s}}initialize(){this.enableOptionSharing=!0,super.initialize();const t=this._cachedMeta;t.stack=this.getDataset().stack}update(t){const n=this._cachedMeta;this.updateElements(n.data,0,n.data.length,t)}updateElements(t,n,r,i){const a=i==="reset",{index:o,_cachedMeta:{vScale:s}}=this,l=s.getBasePixel(),c=s.isHorizontal(),u=this._getRuler(),{sharedOptions:f,includeOptions:d}=this._getSharedOptions(n,i);for(let h=n;h<n+r;h++){const p=this.getParsed(h),m=a||H(p[s.axis])?{base:l,head:l}:this._calculateBarValuePixels(h),g=this._calculateBarIndexPixels(h,u),v=(p._stacks||{})[s.axis],y={horizontal:c,base:m.base,enableBorderRadius:!v||Xo(p._custom)||o===v._top||o===v._bottom,x:c?m.head:g.center,y:c?g.center:m.head,height:c?g.size:Math.abs(m.size),width:c?Math.abs(m.size):g.size};d&&(y.options=f||this.resolveDataElementOptions(h,t[h].active?"active":i));const b=y.options||t[h].options;Cw(y,b,v,o),Dw(y,b,u.ratio),this.updateElement(t[h],h,y,i)}}_getStacks(t,n){const{iScale:r}=this._cachedMeta,i=r.getMatchingVisibleMetas(this._type).filter(u=>u.controller.options.grouped),a=r.options.stacked,o=[],s=this._cachedMeta.controller.getParsed(n),l=s&&s[r.axis],c=u=>{const f=u._parsed.find(h=>h[r.axis]===l),d=f&&f[u.vScale.axis];if(H(d)||isNaN(d))return!0};for(const u of i)if(!(n!==void 0&&c(u))&&((a===!1||o.indexOf(u.stack)===-1||a===void 0&&u.stack===void 0)&&o.push(u.stack),u.index===t))break;return o.length||o.push(void 0),o}_getStackCount(t){return this._getStacks(void 0,t).length}_getAxisCount(){return this._getAxis().length}getFirstScaleIdForIndexAxis(){const t=this.chart.scales,n=this.chart.options.indexAxis;return Object.keys(t).filter(r=>t[r].axis===n).shift()}_getAxis(){const t={},n=this.getFirstScaleIdForIndexAxis();for(const r of this.chart.data.datasets)t[V(this.chart.options.indexAxis==="x"?r.xAxisID:r.yAxisID,n)]=!0;return Object.keys(t)}_getStackIndex(t,n,r){const i=this._getStacks(t,r),a=n!==void 0?i.indexOf(n):-1;return a===-1?i.length-1:a}_getRuler(){const t=this.options,n=this._cachedMeta,r=n.iScale,i=[];let a,o;for(a=0,o=n.data.length;a<o;++a)i.push(r.getPixelForValue(this.getParsed(a)[r.axis],a));const s=t.barThickness;return{min:s||Sw(n),pixels:i,start:r._startPixel,end:r._endPixel,stackCount:this._getStackCount(),scale:r,grouped:t.grouped,ratio:s?1:t.categoryPercentage*t.barPercentage}}_calculateBarValuePixels(t){const{_cachedMeta:{vScale:n,_stacked:r,index:i},options:{base:a,minBarLength:o}}=this,s=a||0,l=this.getParsed(t),c=l._custom,u=Xo(c);let f=l[n.axis],d=0,h=r?this.applyStack(n,l,r):f,p,m;h!==f&&(d=h-f,h=f),u&&(f=c.barStart,h=c.barEnd-c.barStart,f!==0&&vt(f)!==vt(c.barEnd)&&(d=0),d+=f);const g=!H(a)&&!u?a:d;let v=n.getPixelForValue(g);if(this.chart.getDataVisibility(t)?p=n.getPixelForValue(d+h):p=v,m=p-v,Math.abs(m)<o){m=Aw(m,n,s)*o,f===s&&(v-=m/2);const y=n.getPixelForDecimal(0),b=n.getPixelForDecimal(1),_=Math.min(y,b),x=Math.max(y,b);v=Math.max(Math.min(v,x),_),p=v+m,r&&!u&&(l._stacks[n.axis]._visualValues[i]=n.getValueForPixel(p)-n.getValueForPixel(v))}if(v===n.getPixelForValue(s)){const y=vt(m)*n.getLineWidthForValue(s)/2;v+=y,m-=y}return{size:m,base:v,head:p,center:p+m/2}}_calculateBarIndexPixels(t,n){const r=n.scale,i=this.options,a=i.skipNull,o=V(i.maxBarThickness,1/0);let s,l;const c=this._getAxisCount();if(n.grouped){const u=a?this._getStackCount(t):n.stackCount,f=i.barThickness==="flex"?Pw(t,n,i,u*c):Ow(t,n,i,u*c),d=this.chart.options.indexAxis==="x"?this.getDataset().xAxisID:this.getDataset().yAxisID,h=this._getAxis().indexOf(V(d,this.getFirstScaleIdForIndexAxis())),p=this._getStackIndex(this.index,this._cachedMeta.stack,a?t:void 0)+h;s=f.start+f.chunk*p+f.chunk/2,l=Math.min(o,f.chunk*f.ratio)}else s=r.getPixelForValue(this.getParsed(t)[r.axis],t),l=Math.min(o,n.min*n.ratio);return{base:s-l/2,head:s+l/2,center:s,size:l}}draw(){const t=this._cachedMeta,n=t.vScale,r=t.data,i=r.length;let a=0;for(;a<i;++a)this.getParsed(a)[n.axis]!==null&&!r[a].hidden&&r[a].draw(this._ctx)}}function Tw(e,t,n){let r=1,i=1,a=0,o=0;if(t<Re){const s=e,l=s+t,c=Math.cos(s),u=Math.sin(s),f=Math.cos(l),d=Math.sin(l),h=(b,_,x)=>ua(b,s,l,!0)?1:Math.max(_,_*n,x,x*n),p=(b,_,x)=>ua(b,s,l,!0)?-1:Math.min(_,_*n,x,x*n),m=h(0,c,f),g=h($e,u,d),v=p(de,c,f),y=p(de+$e,u,d);r=(m-v)/2,i=(g-y)/2,a=-(m+v)/2,o=-(g+y)/2}return{ratioX:r,ratioY:i,offsetX:a,offsetY:o}}class Iw extends ir{static id="doughnut";static defaults={datasetElementType:!1,dataElementType:"arc",animation:{animateRotate:!0,animateScale:!1},animations:{numbers:{type:"number",properties:["circumference","endAngle","innerRadius","outerRadius","startAngle","x","y","offset","borderWidth","spacing"]}},cutout:"50%",rotation:0,circumference:360,radius:"100%",spacing:0,indexAxis:"r"};static descriptors={_scriptable:t=>t!=="spacing",_indexable:t=>t!=="spacing"&&!t.startsWith("borderDash")&&!t.startsWith("hoverBorderDash")};static overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const n=t.data,{labels:{pointStyle:r,textAlign:i,color:a,useBorderRadius:o,borderRadius:s}}=t.legend.options;return n.labels.length&&n.datasets.length?n.labels.map((l,c)=>{const f=t.getDatasetMeta(0).controller.getStyle(c);return{text:l,fillStyle:f.backgroundColor,fontColor:a,hidden:!t.getDataVisibility(c),lineDash:f.borderDash,lineDashOffset:f.borderDashOffset,lineJoin:f.borderJoinStyle,lineWidth:f.borderWidth,strokeStyle:f.borderColor,textAlign:i,pointStyle:r,borderRadius:o&&(s||f.borderRadius),index:c}}):[]}},onClick(t,n,r){r.chart.toggleDataVisibility(n.index),r.chart.update()}}}};constructor(t,n){super(t,n),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,n){const r=this.getDataset().data,i=this._cachedMeta;if(this._parsing===!1)i._parsed=r;else{let a=l=>+r[l];if($(r[t])){const{key:l="value"}=this._parsing;a=c=>+Yt(r[c],l)}let o,s;for(o=t,s=t+n;o<s;++o)i._parsed[o]=a(o)}}_getRotation(){return ht(this.options.rotation-90)}_getCircumference(){return ht(this.options.circumference)}_getRotationExtents(){let t=Re,n=-Re;for(let r=0;r<this.chart.data.datasets.length;++r)if(this.chart.isDatasetVisible(r)&&this.chart.getDatasetMeta(r).type===this._type){const i=this.chart.getDatasetMeta(r).controller,a=i._getRotation(),o=i._getCircumference();t=Math.min(t,a),n=Math.max(n,a+o)}return{rotation:t,circumference:n-t}}update(t){const n=this.chart,{chartArea:r}=n,i=this._cachedMeta,a=i.data,o=this.getMaxBorderWidth()+this.getMaxOffset(a)+this.options.spacing,s=Math.max((Math.min(r.width,r.height)-o)/2,0),l=Math.min(jx(this.options.cutout,s),1),c=this._getRingWeight(this.index),{circumference:u,rotation:f}=this._getRotationExtents(),{ratioX:d,ratioY:h,offsetX:p,offsetY:m}=Tw(f,u,l),g=(r.width-o)/d,v=(r.height-o)/h,y=Math.max(Math.min(g,v)/2,0),b=km(this.options.radius,y),_=Math.max(b*l,0),x=(b-_)/this._getVisibleDatasetWeightTotal();this.offsetX=p*b,this.offsetY=m*b,i.total=this.calculateTotal(),this.outerRadius=b-x*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-x*c,0),this.updateElements(a,0,a.length,t)}_circumference(t,n){const r=this.options,i=this._cachedMeta,a=this._getCircumference();return n&&r.animation.animateRotate||!this.chart.getDataVisibility(t)||i._parsed[t]===null||i.data[t].hidden?0:this.calculateCircumference(i._parsed[t]*a/Re)}updateElements(t,n,r,i){const a=i==="reset",o=this.chart,s=o.chartArea,c=o.options.animation,u=(s.left+s.right)/2,f=(s.top+s.bottom)/2,d=a&&c.animateScale,h=d?0:this.innerRadius,p=d?0:this.outerRadius,{sharedOptions:m,includeOptions:g}=this._getSharedOptions(n,i);let v=this._getRotation(),y;for(y=0;y<n;++y)v+=this._circumference(y,a);for(y=n;y<n+r;++y){const b=this._circumference(y,a),_=t[y],x={x:u+this.offsetX,y:f+this.offsetY,startAngle:v,endAngle:v+b,circumference:b,outerRadius:p,innerRadius:h};g&&(x.options=m||this.resolveDataElementOptions(y,_.active?"active":i)),v+=b,this.updateElement(_,y,x,i)}}calculateTotal(){const t=this._cachedMeta,n=t.data;let r=0,i;for(i=0;i<n.length;i++){const a=t._parsed[i];a!==null&&!isNaN(a)&&this.chart.getDataVisibility(i)&&!n[i].hidden&&(r+=Math.abs(a))}return r}calculateCircumference(t){const n=this._cachedMeta.total;return n>0&&!isNaN(t)?Re*(Math.abs(t)/n):0}getLabelAndValue(t){const n=this._cachedMeta,r=this.chart,i=r.data.labels||[],a=Ja(n._parsed[t],r.options.locale);return{label:i[t]||"",value:a}}getMaxBorderWidth(t){let n=0;const r=this.chart;let i,a,o,s,l;if(!t){for(i=0,a=r.data.datasets.length;i<a;++i)if(r.isDatasetVisible(i)){o=r.getDatasetMeta(i),t=o.data,s=o.controller;break}}if(!t)return 0;for(i=0,a=t.length;i<a;++i)l=s.resolveDataElementOptions(i),l.borderAlign!=="inner"&&(n=Math.max(n,l.borderWidth||0,l.hoverBorderWidth||0));return n}getMaxOffset(t){let n=0;for(let r=0,i=t.length;r<i;++r){const a=this.resolveDataElementOptions(r);n=Math.max(n,a.offset||0,a.hoverOffset||0)}return n}_getRingWeightOffset(t){let n=0;for(let r=0;r<t;++r)this.chart.isDatasetVisible(r)&&(n+=this._getRingWeight(r));return n}_getRingWeight(t){return Math.max(V(this.chart.data.datasets[t].weight,1),0)}_getVisibleDatasetWeightTotal(){return this._getRingWeightOffset(this.chart.data.datasets.length)||1}}class GR extends ir{static id="line";static defaults={datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1};static overrides={scales:{_index_:{type:"category"},_value_:{type:"linear"}}};initialize(){this.enableOptionSharing=!0,this.supportsDecimation=!0,super.initialize()}update(t){const n=this._cachedMeta,{dataset:r,data:i=[],_dataset:a}=n,o=this.chart._animationsDisabled;let{start:s,count:l}=Rm(n,i,o);this._drawStart=s,this._drawCount=l,Lm(n)&&(s=0,l=i.length),r._chart=this.chart,r._datasetIndex=this.index,r._decimated=!!a._decimated,r.points=i;const c=this.resolveDatasetElementOptions(t);this.options.showLine||(c.borderWidth=0),c.segment=this.options.segment,this.updateElement(r,void 0,{animated:!o,options:c},t),this.updateElements(i,s,l,t)}updateElements(t,n,r,i){const a=i==="reset",{iScale:o,vScale:s,_stacked:l,_dataset:c}=this._cachedMeta,{sharedOptions:u,includeOptions:f}=this._getSharedOptions(n,i),d=o.axis,h=s.axis,{spanGaps:p,segment:m}=this.options,g=Hn(p)?p:Number.POSITIVE_INFINITY,v=this.chart._animationsDisabled||a||i==="none",y=n+r,b=t.length;let _=n>0&&this.getParsed(n-1);for(let x=0;x<b;++x){const S=t[x],O=v?S:{};if(x<n||x>=y){O.skip=!0;continue}const M=this.getParsed(x),E=H(M[h]),j=O[d]=o.getPixelForValue(M[d],x),D=O[h]=a||E?s.getBasePixel():s.getPixelForValue(l?this.applyStack(s,M,l):M[h],x);O.skip=isNaN(j)||isNaN(D)||E,O.stop=x>0&&Math.abs(M[d]-_[d])>g,m&&(O.parsed=M,O.raw=c.data[x]),f&&(O.options=u||this.resolveDataElementOptions(x,S.active?"active":i)),v||this.updateElement(S,x,O,i),_=M}}getMaxOverflow(){const t=this._cachedMeta,n=t.dataset,r=n.options&&n.options.borderWidth||0,i=t.data||[];if(!i.length)return r;const a=i[0].size(this.resolveDataElementOptions(0)),o=i[i.length-1].size(this.resolveDataElementOptions(i.length-1));return Math.max(r,a,o)/2}draw(){const t=this._cachedMeta;t.dataset.updateControlPoints(this.chart.chartArea,t.iScale.axis),super.draw()}}class jw extends ir{static id="polarArea";static defaults={dataElementType:"arc",animation:{animateRotate:!0,animateScale:!0},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0};static overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const n=t.data;if(n.labels.length&&n.datasets.length){const{labels:{pointStyle:r,color:i}}=t.legend.options;return n.labels.map((a,o)=>{const l=t.getDatasetMeta(0).controller.getStyle(o);return{text:a,fillStyle:l.backgroundColor,strokeStyle:l.borderColor,fontColor:i,lineWidth:l.borderWidth,pointStyle:r,hidden:!t.getDataVisibility(o),index:o}})}return[]}},onClick(t,n,r){r.chart.toggleDataVisibility(n.index),r.chart.update()}}},scales:{r:{type:"radialLinear",angleLines:{display:!1},beginAtZero:!0,grid:{circular:!0},pointLabels:{display:!1},startAngle:0}}};constructor(t,n){super(t,n),this.innerRadius=void 0,this.outerRadius=void 0}getLabelAndValue(t){const n=this._cachedMeta,r=this.chart,i=r.data.labels||[],a=Ja(n._parsed[t].r,r.options.locale);return{label:i[t]||"",value:a}}parseObjectData(t,n,r,i){return D_.bind(this)(t,n,r,i)}update(t){const n=this._cachedMeta.data;this._updateRadius(),this.updateElements(n,0,n.length,t)}getMinMax(){const t=this._cachedMeta,n={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY};return t.data.forEach((r,i)=>{const a=this.getParsed(i).r;!isNaN(a)&&this.chart.getDataVisibility(i)&&(a<n.min&&(n.min=a),a>n.max&&(n.max=a))}),n}_updateRadius(){const t=this.chart,n=t.chartArea,r=t.options,i=Math.min(n.right-n.left,n.bottom-n.top),a=Math.max(i/2,0),o=Math.max(r.cutoutPercentage?a/100*r.cutoutPercentage:1,0),s=(a-o)/t.getVisibleDatasetCount();this.outerRadius=a-s*this.index,this.innerRadius=this.outerRadius-s}updateElements(t,n,r,i){const a=i==="reset",o=this.chart,l=o.options.animation,c=this._cachedMeta.rScale,u=c.xCenter,f=c.yCenter,d=c.getIndexAngle(0)-.5*de;let h=d,p;const m=360/this.countVisibleElements();for(p=0;p<n;++p)h+=this._computeAngle(p,i,m);for(p=n;p<n+r;p++){const g=t[p];let v=h,y=h+this._computeAngle(p,i,m),b=o.getDataVisibility(p)?c.getDistanceFromCenterForValue(this.getParsed(p).r):0;h=y,a&&(l.animateScale&&(b=0),l.animateRotate&&(v=y=d));const _={x:u,y:f,innerRadius:0,outerRadius:b,startAngle:v,endAngle:y,options:this.resolveDataElementOptions(p,g.active?"active":i)};this.updateElement(g,p,_,i)}}countVisibleElements(){const t=this._cachedMeta;let n=0;return t.data.forEach((r,i)=>{!isNaN(this.getParsed(i).r)&&this.chart.getDataVisibility(i)&&n++}),n}_computeAngle(t,n,r){return this.chart.getDataVisibility(t)?ht(this.resolveDataElementOptions(t,n).angle||r):0}}class ZR extends ir{static id="scatter";static defaults={datasetElementType:!1,dataElementType:"point",showLine:!1,fill:!1};static overrides={interaction:{mode:"point"},scales:{x:{type:"linear"},y:{type:"linear"}}};getLabelAndValue(t){const n=this._cachedMeta,r=this.chart.data.labels||[],{xScale:i,yScale:a}=n,o=this.getParsed(t),s=i.getLabelForValue(o.x),l=a.getLabelForValue(o.y);return{label:r[t]||"",value:"("+s+", "+l+")"}}update(t){const n=this._cachedMeta,{data:r=[]}=n,i=this.chart._animationsDisabled;let{start:a,count:o}=Rm(n,r,i);if(this._drawStart=a,this._drawCount=o,Lm(n)&&(a=0,o=r.length),this.options.showLine){this.datasetElementType||this.addElements();const{dataset:s,_dataset:l}=n;s._chart=this.chart,s._datasetIndex=this.index,s._decimated=!!l._decimated,s.points=r;const c=this.resolveDatasetElementOptions(t);c.segment=this.options.segment,this.updateElement(s,void 0,{animated:!i,options:c},t)}else this.datasetElementType&&(delete n.dataset,this.datasetElementType=!1);this.updateElements(r,a,o,t)}addElements(){const{showLine:t}=this.options;!this.datasetElementType&&t&&(this.datasetElementType=this.chart.registry.getElement("line")),super.addElements()}updateElements(t,n,r,i){const a=i==="reset",{iScale:o,vScale:s,_stacked:l,_dataset:c}=this._cachedMeta,u=this.resolveDataElementOptions(n,i),f=this.getSharedOptions(u),d=this.includeOptions(i,f),h=o.axis,p=s.axis,{spanGaps:m,segment:g}=this.options,v=Hn(m)?m:Number.POSITIVE_INFINITY,y=this.chart._animationsDisabled||a||i==="none";let b=n>0&&this.getParsed(n-1);for(let _=n;_<n+r;++_){const x=t[_],S=this.getParsed(_),O=y?x:{},M=H(S[p]),E=O[h]=o.getPixelForValue(S[h],_),j=O[p]=a||M?s.getBasePixel():s.getPixelForValue(l?this.applyStack(s,S,l):S[p],_);O.skip=isNaN(E)||isNaN(j)||M,O.stop=_>0&&Math.abs(S[h]-b[h])>v,g&&(O.parsed=S,O.raw=c.data[_]),d&&(O.options=f||this.resolveDataElementOptions(_,x.active?"active":i)),y||this.updateElement(x,_,O,i),b=S}this.updateSharedOptions(f,i,u)}getMaxOverflow(){const t=this._cachedMeta,n=t.data||[];if(!this.options.showLine){let s=0;for(let l=n.length-1;l>=0;--l)s=Math.max(s,n[l].size(this.resolveDataElementOptions(l))/2);return s>0&&s}const r=t.dataset,i=r.options&&r.options.borderWidth||0;if(!n.length)return i;const a=n[0].size(this.resolveDataElementOptions(0)),o=n[n.length-1].size(this.resolveDataElementOptions(n.length-1));return Math.max(i,a,o)/2}}function fn(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}class zc{static override(t){Object.assign(zc.prototype,t)}options;constructor(t){this.options=t||{}}init(){}formats(){return fn()}parse(){return fn()}format(){return fn()}add(){return fn()}diff(){return fn()}startOf(){return fn()}endOf(){return fn()}}var Rw={_date:zc};function Lw(e,t,n,r){const{controller:i,data:a,_sorted:o}=e,s=i._cachedMeta.iScale,l=e.dataset&&e.dataset.options?e.dataset.options.spanGaps:null;if(s&&t===s.axis&&t!=="r"&&o&&a.length){const c=s._reversePixels?Gx:yn;if(r){if(i._sharedOptions){const u=a[0],f=typeof u.getRange=="function"&&u.getRange(t);if(f){const d=c(a,t,n-f),h=c(a,t,n+f);return{lo:d.lo,hi:h.hi}}}}else{const u=c(a,t,n);if(l){const{vScale:f}=i._cachedMeta,{_parsed:d}=e,h=d.slice(0,u.lo+1).reverse().findIndex(m=>!H(m[f.axis]));u.lo-=Math.max(0,h);const p=d.slice(u.hi).findIndex(m=>!H(m[f.axis]));u.hi+=Math.max(0,p)}return u}}return{lo:0,hi:a.length-1}}function to(e,t,n,r,i){const a=e.getSortedVisibleDatasetMetas(),o=n[t];for(let s=0,l=a.length;s<l;++s){const{index:c,data:u}=a[s],{lo:f,hi:d}=Lw(a[s],t,o,i);for(let h=f;h<=d;++h){const p=u[h];p.skip||r(p,c,h)}}}function Nw(e){const t=e.indexOf("x")!==-1,n=e.indexOf("y")!==-1;return function(r,i){const a=t?Math.abs(r.x-i.x):0,o=n?Math.abs(r.y-i.y):0;return Math.sqrt(Math.pow(a,2)+Math.pow(o,2))}}function Go(e,t,n,r,i){const a=[];return!i&&!e.isPointInArea(t)||to(e,n,t,function(s,l,c){!i&&!qr(s,e.chartArea,0)||s.inRange(t.x,t.y,r)&&a.push({element:s,datasetIndex:l,index:c})},!0),a}function Fw(e,t,n,r){let i=[];function a(o,s,l){const{startAngle:c,endAngle:u}=o.getProps(["startAngle","endAngle"],r),{angle:f}=Kx(o,{x:t.x,y:t.y});ua(f,c,u)&&i.push({element:o,datasetIndex:s,index:l})}return to(e,n,t,a),i}function Bw(e,t,n,r,i,a){let o=[];const s=Nw(n);let l=Number.POSITIVE_INFINITY;function c(u,f,d){const h=u.inRange(t.x,t.y,i);if(r&&!h)return;const p=u.getCenterPoint(i);if(!(!!a||e.isPointInArea(p))&&!h)return;const g=s(t,p);g<l?(o=[{element:u,datasetIndex:f,index:d}],l=g):g===l&&o.push({element:u,datasetIndex:f,index:d})}return to(e,n,t,c),o}function Zo(e,t,n,r,i,a){return!a&&!e.isPointInArea(t)?[]:n==="r"&&!r?Fw(e,t,n,i):Bw(e,t,n,r,i,a)}function Kf(e,t,n,r,i){const a=[],o=n==="x"?"inXRange":"inYRange";let s=!1;return to(e,n,t,(l,c,u)=>{l[o]&&l[o](t[n],i)&&(a.push({element:l,datasetIndex:c,index:u}),s=s||l.inRange(t.x,t.y,i))}),r&&!s?[]:a}var zw={modes:{index(e,t,n,r){const i=hn(t,e),a=n.axis||"x",o=n.includeInvisible||!1,s=n.intersect?Go(e,i,a,r,o):Zo(e,i,a,!1,r,o),l=[];return s.length?(e.getSortedVisibleDatasetMetas().forEach(c=>{const u=s[0].index,f=c.data[u];f&&!f.skip&&l.push({element:f,datasetIndex:c.index,index:u})}),l):[]},dataset(e,t,n,r){const i=hn(t,e),a=n.axis||"xy",o=n.includeInvisible||!1;let s=n.intersect?Go(e,i,a,r,o):Zo(e,i,a,!1,r,o);if(s.length>0){const l=s[0].datasetIndex,c=e.getDatasetMeta(l).data;s=[];for(let u=0;u<c.length;++u)s.push({element:c[u],datasetIndex:l,index:u})}return s},point(e,t,n,r){const i=hn(t,e),a=n.axis||"xy",o=n.includeInvisible||!1;return Go(e,i,a,r,o)},nearest(e,t,n,r){const i=hn(t,e),a=n.axis||"xy",o=n.includeInvisible||!1;return Zo(e,i,a,n.intersect,r,o)},x(e,t,n,r){const i=hn(t,e);return Kf(e,i,"x",n.intersect,r)},y(e,t,n,r){const i=hn(t,e);return Kf(e,i,"y",n.intersect,r)}}};const Zm=["left","top","right","bottom"];function br(e,t){return e.filter(n=>n.pos===t)}function Yf(e,t){return e.filter(n=>Zm.indexOf(n.pos)===-1&&n.box.axis===t)}function xr(e,t){return e.sort((n,r)=>{const i=t?r:n,a=t?n:r;return i.weight===a.weight?i.index-a.index:i.weight-a.weight})}function $w(e){const t=[];let n,r,i,a,o,s;for(n=0,r=(e||[]).length;n<r;++n)i=e[n],{position:a,options:{stack:o,stackWeight:s=1}}=i,t.push({index:n,box:i,pos:a,horizontal:i.isHorizontal(),weight:i.weight,stack:o&&a+o,stackWeight:s});return t}function Ww(e){const t={};for(const n of e){const{stack:r,pos:i,stackWeight:a}=n;if(!r||!Zm.includes(i))continue;const o=t[r]||(t[r]={count:0,placed:0,weight:0,size:0});o.count++,o.weight+=a}return t}function qw(e,t){const n=Ww(e),{vBoxMaxWidth:r,hBoxMaxHeight:i}=t;let a,o,s;for(a=0,o=e.length;a<o;++a){s=e[a];const{fullSize:l}=s.box,c=n[s.stack],u=c&&s.stackWeight/c.weight;s.horizontal?(s.width=u?u*r:l&&t.availableWidth,s.height=i):(s.width=r,s.height=u?u*i:l&&t.availableHeight)}return n}function Uw(e){const t=$w(e),n=xr(t.filter(c=>c.box.fullSize),!0),r=xr(br(t,"left"),!0),i=xr(br(t,"right")),a=xr(br(t,"top"),!0),o=xr(br(t,"bottom")),s=Yf(t,"x"),l=Yf(t,"y");return{fullSize:n,leftAndTop:r.concat(a),rightAndBottom:i.concat(l).concat(o).concat(s),chartArea:br(t,"chartArea"),vertical:r.concat(i).concat(l),horizontal:a.concat(o).concat(s)}}function Xf(e,t,n,r){return Math.max(e[n],t[n])+Math.max(e[r],t[r])}function Qm(e,t){e.top=Math.max(e.top,t.top),e.left=Math.max(e.left,t.left),e.bottom=Math.max(e.bottom,t.bottom),e.right=Math.max(e.right,t.right)}function Vw(e,t,n,r){const{pos:i,box:a}=n,o=e.maxPadding;if(!$(i)){n.size&&(e[i]-=n.size);const f=r[n.stack]||{size:0,count:1};f.size=Math.max(f.size,n.horizontal?a.height:a.width),n.size=f.size/f.count,e[i]+=n.size}a.getPadding&&Qm(o,a.getPadding());const s=Math.max(0,t.outerWidth-Xf(o,e,"left","right")),l=Math.max(0,t.outerHeight-Xf(o,e,"top","bottom")),c=s!==e.w,u=l!==e.h;return e.w=s,e.h=l,n.horizontal?{same:c,other:u}:{same:u,other:c}}function Hw(e){const t=e.maxPadding;function n(r){const i=Math.max(t[r]-e[r],0);return e[r]+=i,i}e.y+=n("top"),e.x+=n("left"),n("right"),n("bottom")}function Kw(e,t){const n=t.maxPadding;function r(i){const a={left:0,top:0,right:0,bottom:0};return i.forEach(o=>{a[o]=Math.max(t[o],n[o])}),a}return r(e?["left","right"]:["top","bottom"])}function Tr(e,t,n,r){const i=[];let a,o,s,l,c,u;for(a=0,o=e.length,c=0;a<o;++a){s=e[a],l=s.box,l.update(s.width||t.w,s.height||t.h,Kw(s.horizontal,t));const{same:f,other:d}=Vw(t,n,s,r);c|=f&&i.length,u=u||d,l.fullSize||i.push(s)}return c&&Tr(i,t,n,r)||u}function Di(e,t,n,r,i){e.top=n,e.left=t,e.right=t+r,e.bottom=n+i,e.width=r,e.height=i}function Gf(e,t,n,r){const i=n.padding;let{x:a,y:o}=t;for(const s of e){const l=s.box,c=r[s.stack]||{placed:0,weight:1},u=s.stackWeight/c.weight||1;if(s.horizontal){const f=t.w*u,d=c.size||l.height;Wr(c.start)&&(o=c.start),l.fullSize?Di(l,i.left,o,n.outerWidth-i.right-i.left,d):Di(l,t.left+c.placed,o,f,d),c.start=o,c.placed+=f,o=l.bottom}else{const f=t.h*u,d=c.size||l.width;Wr(c.start)&&(a=c.start),l.fullSize?Di(l,a,i.top,d,n.outerHeight-i.bottom-i.top):Di(l,a,t.top+c.placed,d,f),c.start=a,c.placed+=f,a=l.right}}t.x=a,t.y=o}var Ti={addBox(e,t){e.boxes||(e.boxes=[]),t.fullSize=t.fullSize||!1,t.position=t.position||"top",t.weight=t.weight||0,t._layers=t._layers||function(){return[{z:0,draw(n){t.draw(n)}}]},e.boxes.push(t)},removeBox(e,t){const n=e.boxes?e.boxes.indexOf(t):-1;n!==-1&&e.boxes.splice(n,1)},configure(e,t,n){t.fullSize=n.fullSize,t.position=n.position,t.weight=n.weight},update(e,t,n,r){if(!e)return;const i=Gt(e.options.layout.padding),a=Math.max(t-i.width,0),o=Math.max(n-i.height,0),s=Uw(e.boxes),l=s.vertical,c=s.horizontal;Y(e.boxes,m=>{typeof m.beforeLayout=="function"&&m.beforeLayout()});const u=l.reduce((m,g)=>g.box.options&&g.box.options.display===!1?m:m+1,0)||1,f=Object.freeze({outerWidth:t,outerHeight:n,padding:i,availableWidth:a,availableHeight:o,vBoxMaxWidth:a/2/u,hBoxMaxHeight:o/2}),d=Object.assign({},i);Qm(d,Gt(r));const h=Object.assign({maxPadding:d,w:a,h:o,x:i.left,y:i.top},i),p=qw(l.concat(c),f);Tr(s.fullSize,h,f,p),Tr(l,h,f,p),Tr(c,h,f,p)&&Tr(l,h,f,p),Hw(h),Gf(s.leftAndTop,h,f,p),h.x+=h.w,h.y+=h.h,Gf(s.rightAndBottom,h,f,p),e.chartArea={left:h.left,top:h.top,right:h.left+h.w,bottom:h.top+h.h,height:h.h,width:h.w},Y(s.chartArea,m=>{const g=m.box;Object.assign(g,e.chartArea),g.update(h.w,h.h,{left:0,top:0,right:0,bottom:0})})}};class Jm{acquireContext(t,n){}releaseContext(t){return!1}addEventListener(t,n,r){}removeEventListener(t,n,r){}getDevicePixelRatio(){return 1}getMaximumSize(t,n,r,i){return n=Math.max(0,n||t.width),r=r||t.height,{width:n,height:Math.max(0,i?Math.floor(n/i):r)}}isAttached(t){return!0}updateConfig(t){}}class Yw extends Jm{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const ta="$chartjs",Xw={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},Zf=e=>e===null||e==="";function Gw(e,t){const n=e.style,r=e.getAttribute("height"),i=e.getAttribute("width");if(e[ta]={initial:{height:r,width:i,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",n.boxSizing=n.boxSizing||"border-box",Zf(i)){const a=jf(e,"width");a!==void 0&&(e.width=a)}if(Zf(r))if(e.style.height==="")e.height=e.width/(t||2);else{const a=jf(e,"height");a!==void 0&&(e.height=a)}return e}const ev=V_?{passive:!0}:!1;function Zw(e,t,n){e&&e.addEventListener(t,n,ev)}function Qw(e,t,n){e&&e.canvas&&e.canvas.removeEventListener(t,n,ev)}function Jw(e,t){const n=Xw[e.type]||e.type,{x:r,y:i}=hn(e,t);return{type:n,chart:t,native:e,x:r!==void 0?r:null,y:i!==void 0?i:null}}function da(e,t){for(const n of e)if(n===t||n.contains(t))return!0}function e1(e,t,n){const r=e.canvas,i=new MutationObserver(a=>{let o=!1;for(const s of a)o=o||da(s.addedNodes,r),o=o&&!da(s.removedNodes,r);o&&n()});return i.observe(document,{childList:!0,subtree:!0}),i}function t1(e,t,n){const r=e.canvas,i=new MutationObserver(a=>{let o=!1;for(const s of a)o=o||da(s.removedNodes,r),o=o&&!da(s.addedNodes,r);o&&n()});return i.observe(document,{childList:!0,subtree:!0}),i}const Ur=new Map;let Qf=0;function tv(){const e=window.devicePixelRatio;e!==Qf&&(Qf=e,Ur.forEach((t,n)=>{n.currentDevicePixelRatio!==e&&t()}))}function n1(e,t){Ur.size||window.addEventListener("resize",tv),Ur.set(e,t)}function r1(e){Ur.delete(e),Ur.size||window.removeEventListener("resize",tv)}function i1(e,t,n){const r=e.canvas,i=r&&Bc(r);if(!i)return;const a=jm((s,l)=>{const c=i.clientWidth;n(s,l),c<i.clientWidth&&n()},window),o=new ResizeObserver(s=>{const l=s[0],c=l.contentRect.width,u=l.contentRect.height;c===0&&u===0||a(c,u)});return o.observe(i),n1(e,a),o}function Qo(e,t,n){n&&n.disconnect(),t==="resize"&&r1(e)}function a1(e,t,n){const r=e.canvas,i=jm(a=>{e.ctx!==null&&n(Jw(a,e))},e);return Zw(r,t,i),i}class o1 extends Jm{acquireContext(t,n){const r=t&&t.getContext&&t.getContext("2d");return r&&r.canvas===t?(Gw(t,n),r):null}releaseContext(t){const n=t.canvas;if(!n[ta])return!1;const r=n[ta].initial;["height","width"].forEach(a=>{const o=r[a];H(o)?n.removeAttribute(a):n.setAttribute(a,o)});const i=r.style||{};return Object.keys(i).forEach(a=>{n.style[a]=i[a]}),n.width=n.width,delete n[ta],!0}addEventListener(t,n,r){this.removeEventListener(t,n);const i=t.$proxies||(t.$proxies={}),o={attach:e1,detach:t1,resize:i1}[n]||a1;i[n]=o(t,n,r)}removeEventListener(t,n){const r=t.$proxies||(t.$proxies={}),i=r[n];if(!i)return;({attach:Qo,detach:Qo,resize:Qo}[n]||Qw)(t,n,i),r[n]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,n,r,i){return U_(t,n,r,i)}isAttached(t){const n=t&&Bc(t);return!!(n&&n.isConnected)}}function s1(e){return!Fc()||typeof OffscreenCanvas<"u"&&e instanceof OffscreenCanvas?Yw:o1}class ar{static defaults={};static defaultRoutes=void 0;x;y;active=!1;options;$animations;tooltipPosition(t){const{x:n,y:r}=this.getProps(["x","y"],t);return{x:n,y:r}}hasValue(){return Hn(this.x)&&Hn(this.y)}getProps(t,n){const r=this.$animations;if(!n||!r)return this;const i={};return t.forEach(a=>{i[a]=r[a]&&r[a].active()?r[a]._to:this[a]}),i}}function l1(e,t){const n=e.options.ticks,r=c1(e),i=Math.min(n.maxTicksLimit||r,r),a=n.major.enabled?f1(t):[],o=a.length,s=a[0],l=a[o-1],c=[];if(o>i)return d1(t,c,a,o/i),c;const u=u1(a,t,i);if(o>0){let f,d;const h=o>1?Math.round((l-s)/(o-1)):null;for(Ii(t,c,u,H(h)?0:s-h,s),f=0,d=o-1;f<d;f++)Ii(t,c,u,a[f],a[f+1]);return Ii(t,c,u,l,H(h)?t.length:l+h),c}return Ii(t,c,u),c}function c1(e){const t=e.options.offset,n=e._tickSize(),r=e._length/n+(t?0:1),i=e._maxLength/n;return Math.floor(Math.min(r,i))}function u1(e,t,n){const r=h1(e),i=t.length/n;if(!r)return Math.max(i,1);const a=Wx(r);for(let o=0,s=a.length-1;o<s;o++){const l=a[o];if(l>i)return l}return Math.max(i,1)}function f1(e){const t=[];let n,r;for(n=0,r=e.length;n<r;n++)e[n].major&&t.push(n);return t}function d1(e,t,n,r){let i=0,a=n[0],o;for(r=Math.ceil(r),o=0;o<e.length;o++)o===a&&(t.push(e[o]),i++,a=n[i*r])}function Ii(e,t,n,r,i){const a=V(r,0),o=Math.min(V(i,e.length),e.length);let s=0,l,c,u;for(n=Math.ceil(n),i&&(l=i-r,n=l/Math.floor(l/n)),u=a;u<0;)s++,u=Math.round(a+s*n);for(c=Math.max(a,0);c<o;c++)c===u&&(t.push(e[c]),s++,u=Math.round(a+s*n))}function h1(e){const t=e.length;let n,r;if(t<2)return!1;for(r=e[0],n=1;n<t;++n)if(e[n]-e[n-1]!==r)return!1;return r}const p1=e=>e==="left"?"right":e==="right"?"left":e,Jf=(e,t,n)=>t==="top"||t==="left"?e[t]+n:e[t]-n,ed=(e,t)=>Math.min(t||e,e);function td(e,t){const n=[],r=e.length/t,i=e.length;let a=0;for(;a<i;a+=r)n.push(e[Math.floor(a)]);return n}function g1(e,t,n){const r=e.ticks.length,i=Math.min(t,r-1),a=e._startPixel,o=e._endPixel,s=1e-6;let l=e.getPixelForTick(i),c;if(!(n&&(r===1?c=Math.max(l-a,o-l):t===0?c=(e.getPixelForTick(1)-l)/2:c=(l-e.getPixelForTick(i-1))/2,l+=i<t?c:-c,l<a-s||l>o+s)))return l}function m1(e,t){Y(e,n=>{const r=n.gc,i=r.length/2;let a;if(i>t){for(a=0;a<i;++a)delete n.data[r[a]];r.splice(0,i)}})}function _r(e){return e.drawTicks?e.tickLength:0}function nd(e,t){if(!e.display)return 0;const n=pt(e.font,t),r=Gt(e.padding);return(me(e.text)?e.text.length:1)*n.lineHeight+r.height}function v1(e,t){return jn(e,{scale:t,type:"scale"})}function y1(e,t,n){return jn(e,{tick:n,index:t,type:"tick"})}function b1(e,t,n){let r=e_(e);return(n&&t!=="right"||!n&&t==="right")&&(r=p1(r)),r}function x1(e,t,n,r){const{top:i,left:a,bottom:o,right:s,chart:l}=e,{chartArea:c,scales:u}=l;let f=0,d,h,p;const m=o-i,g=s-a;if(e.isHorizontal()){if(h=Sf(r,a,s),$(n)){const v=Object.keys(n)[0],y=n[v];p=u[v].getPixelForValue(y)+m-t}else n==="center"?p=(c.bottom+c.top)/2+m-t:p=Jf(e,n,t);d=s-a}else{if($(n)){const v=Object.keys(n)[0],y=n[v];h=u[v].getPixelForValue(y)-g+t}else n==="center"?h=(c.left+c.right)/2-g+t:h=Jf(e,n,t);p=Sf(r,o,i),f=n==="left"?-$e:$e}return{titleX:h,titleY:p,maxWidth:d,rotation:f}}class or extends ar{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,n){return t}getUserBounds(){let{_userMin:t,_userMax:n,_suggestedMin:r,_suggestedMax:i}=this;return t=lt(t,Number.POSITIVE_INFINITY),n=lt(n,Number.NEGATIVE_INFINITY),r=lt(r,Number.POSITIVE_INFINITY),i=lt(i,Number.NEGATIVE_INFINITY),{min:lt(t,r),max:lt(n,i),minDefined:Qe(t),maxDefined:Qe(n)}}getMinMax(t){let{min:n,max:r,minDefined:i,maxDefined:a}=this.getUserBounds(),o;if(i&&a)return{min:n,max:r};const s=this.getMatchingVisibleMetas();for(let l=0,c=s.length;l<c;++l)o=s[l].controller.getMinMax(this,t),i||(n=Math.min(n,o.min)),a||(r=Math.max(r,o.max));return n=a&&n>r?r:n,r=i&&n>r?n:r,{min:lt(n,lt(r,n)),max:lt(r,lt(n,r))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}getLabelItems(t=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(t))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){le(this.options.beforeUpdate,[this])}update(t,n,r){const{beginAtZero:i,grace:a,ticks:o}=this.options,s=o.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=n,this._margins=r=Object.assign({left:0,right:0,top:0,bottom:0},r),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+r.left+r.right:this.height+r.top+r.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=__(this,a,i),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const l=s<this.ticks.length;this._convertTicksToLabels(l?td(this.ticks,s):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),o.display&&(o.autoSkip||o.source==="auto")&&(this.ticks=l1(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),l&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate()}configure(){let t=this.options.reverse,n,r;this.isHorizontal()?(n=this.left,r=this.right):(n=this.top,r=this.bottom,t=!t),this._startPixel=n,this._endPixel=r,this._reversePixels=t,this._length=r-n,this._alignToPixels=this.options.alignToPixels}afterUpdate(){le(this.options.afterUpdate,[this])}beforeSetDimensions(){le(this.options.beforeSetDimensions,[this])}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=0,this.right=this.width):(this.height=this.maxHeight,this.top=0,this.bottom=this.height),this.paddingLeft=0,this.paddingTop=0,this.paddingRight=0,this.paddingBottom=0}afterSetDimensions(){le(this.options.afterSetDimensions,[this])}_callHooks(t){this.chart.notifyPlugins(t,this.getContext()),le(this.options[t],[this])}beforeDataLimits(){this._callHooks("beforeDataLimits")}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits")}beforeBuildTicks(){this._callHooks("beforeBuildTicks")}buildTicks(){return[]}afterBuildTicks(){this._callHooks("afterBuildTicks")}beforeTickToLabelConversion(){le(this.options.beforeTickToLabelConversion,[this])}generateTickLabels(t){const n=this.options.ticks;let r,i,a;for(r=0,i=t.length;r<i;r++)a=t[r],a.label=le(n.callback,[a.value,r,t],this)}afterTickToLabelConversion(){le(this.options.afterTickToLabelConversion,[this])}beforeCalculateLabelRotation(){le(this.options.beforeCalculateLabelRotation,[this])}calculateLabelRotation(){const t=this.options,n=t.ticks,r=ed(this.ticks.length,t.ticks.maxTicksLimit),i=n.minRotation||0,a=n.maxRotation;let o=i,s,l,c;if(!this._isVisible()||!n.display||i>=a||r<=1||!this.isHorizontal()){this.labelRotation=i;return}const u=this._getLabelSizes(),f=u.widest.width,d=u.highest.height,h=We(this.chart.width-f,0,this.maxWidth);s=t.offset?this.maxWidth/r:h/(r-1),f+6>s&&(s=h/(r-(t.offset?.5:1)),l=this.maxHeight-_r(t.grid)-n.padding-nd(t.title,this.chart.options.font),c=Math.sqrt(f*f+d*d),o=Hx(Math.min(Math.asin(We((u.highest.height+6)/s,-1,1)),Math.asin(We(l/c,-1,1))-Math.asin(We(d/c,-1,1)))),o=Math.max(i,Math.min(a,o))),this.labelRotation=o}afterCalculateLabelRotation(){le(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){le(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:n,options:{ticks:r,title:i,grid:a}}=this,o=this._isVisible(),s=this.isHorizontal();if(o){const l=nd(i,n.options.font);if(s?(t.width=this.maxWidth,t.height=_r(a)+l):(t.height=this.maxHeight,t.width=_r(a)+l),r.display&&this.ticks.length){const{first:c,last:u,widest:f,highest:d}=this._getLabelSizes(),h=r.padding*2,p=ht(this.labelRotation),m=Math.cos(p),g=Math.sin(p);if(s){const v=r.mirror?0:g*f.width+m*d.height;t.height=Math.min(this.maxHeight,t.height+v+h)}else{const v=r.mirror?0:m*f.width+g*d.height;t.width=Math.min(this.maxWidth,t.width+v+h)}this._calculatePadding(c,u,g,m)}}this._handleMargins(),s?(this.width=this._length=n.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=n.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,n,r,i){const{ticks:{align:a,padding:o},position:s}=this.options,l=this.labelRotation!==0,c=s!=="top"&&this.axis==="x";if(this.isHorizontal()){const u=this.getPixelForTick(0)-this.left,f=this.right-this.getPixelForTick(this.ticks.length-1);let d=0,h=0;l?c?(d=i*t.width,h=r*n.height):(d=r*t.height,h=i*n.width):a==="start"?h=n.width:a==="end"?d=t.width:a!=="inner"&&(d=t.width/2,h=n.width/2),this.paddingLeft=Math.max((d-u+o)*this.width/(this.width-u),0),this.paddingRight=Math.max((h-f+o)*this.width/(this.width-f),0)}else{let u=n.height/2,f=t.height/2;a==="start"?(u=0,f=t.height):a==="end"&&(u=n.height,f=0),this.paddingTop=u+o,this.paddingBottom=f+o}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){le(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:n}=this.options;return n==="top"||n==="bottom"||t==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){this.beforeTickToLabelConversion(),this.generateTickLabels(t);let n,r;for(n=0,r=t.length;n<r;n++)H(t[n].label)&&(t.splice(n,1),r--,n--);this.afterTickToLabelConversion()}_getLabelSizes(){let t=this._labelSizes;if(!t){const n=this.options.ticks.sampleSize;let r=this.ticks;n<r.length&&(r=td(r,n)),this._labelSizes=t=this._computeLabelSizes(r,r.length,this.options.ticks.maxTicksLimit)}return t}_computeLabelSizes(t,n,r){const{ctx:i,_longestTextCache:a}=this,o=[],s=[],l=Math.floor(n/ed(n,r));let c=0,u=0,f,d,h,p,m,g,v,y,b,_,x;for(f=0;f<n;f+=l){if(p=t[f].label,m=this._resolveTickFontOptions(f),i.font=g=m.string,v=a[g]=a[g]||{data:{},gc:[]},y=m.lineHeight,b=_=0,!H(p)&&!me(p))b=kf(i,v.data,v.gc,b,p),_=y;else if(me(p))for(d=0,h=p.length;d<h;++d)x=p[d],!H(x)&&!me(x)&&(b=kf(i,v.data,v.gc,b,x),_+=y);o.push(b),s.push(_),c=Math.max(b,c),u=Math.max(_,u)}m1(a,n);const S=o.indexOf(c),O=s.indexOf(u),M=E=>({width:o[E]||0,height:s[E]||0});return{first:M(0),last:M(n-1),widest:M(S),highest:M(O),widths:o,heights:s}}getLabelForValue(t){return t}getPixelForValue(t,n){return NaN}getValueForPixel(t){}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const n=this._startPixel+t*this._length;return Xx(this._alignToPixels?un(this.chart,n,0):n)}getDecimalForPixel(t){const n=(t-this._startPixel)/this._length;return this._reversePixels?1-n:n}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:n}=this;return t<0&&n<0?n:t>0&&n>0?t:0}getContext(t){const n=this.ticks||[];if(t>=0&&t<n.length){const r=n[t];return r.$context||(r.$context=y1(this.getContext(),t,r))}return this.$context||(this.$context=v1(this.chart.getContext(),this))}_tickSize(){const t=this.options.ticks,n=ht(this.labelRotation),r=Math.abs(Math.cos(n)),i=Math.abs(Math.sin(n)),a=this._getLabelSizes(),o=t.autoSkipPadding||0,s=a?a.widest.width+o:0,l=a?a.highest.height+o:0;return this.isHorizontal()?l*r>s*i?s/r:l/i:l*i<s*r?l/r:s/i}_isVisible(){const t=this.options.display;return t!=="auto"?!!t:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(t){const n=this.axis,r=this.chart,i=this.options,{grid:a,position:o,border:s}=i,l=a.offset,c=this.isHorizontal(),f=this.ticks.length+(l?1:0),d=_r(a),h=[],p=s.setContext(this.getContext()),m=p.display?p.width:0,g=m/2,v=function(L){return un(r,L,m)};let y,b,_,x,S,O,M,E,j,D,A,N;if(o==="top")y=v(this.bottom),O=this.bottom-d,E=y-g,D=v(t.top)+g,N=t.bottom;else if(o==="bottom")y=v(this.top),D=t.top,N=v(t.bottom)-g,O=y+g,E=this.top+d;else if(o==="left")y=v(this.right),S=this.right-d,M=y-g,j=v(t.left)+g,A=t.right;else if(o==="right")y=v(this.left),j=t.left,A=v(t.right)-g,S=y+g,M=this.left+d;else if(n==="x"){if(o==="center")y=v((t.top+t.bottom)/2+.5);else if($(o)){const L=Object.keys(o)[0],F=o[L];y=v(this.chart.scales[L].getPixelForValue(F))}D=t.top,N=t.bottom,O=y+g,E=O+d}else if(n==="y"){if(o==="center")y=v((t.left+t.right)/2);else if($(o)){const L=Object.keys(o)[0],F=o[L];y=v(this.chart.scales[L].getPixelForValue(F))}S=y-g,M=S-d,j=t.left,A=t.right}const R=V(i.ticks.maxTicksLimit,f),T=Math.max(1,Math.ceil(f/R));for(b=0;b<f;b+=T){const L=this.getContext(b),F=a.setContext(L),oe=s.setContext(L),J=F.lineWidth,U=F.color,Me=oe.dash||[],se=oe.dashOffset,_e=F.tickWidth,re=F.tickColor,we=F.tickBorderDash||[],Se=F.tickBorderDashOffset;_=g1(this,b,l),_!==void 0&&(x=un(r,_,J),c?S=M=j=A=x:O=E=D=N=x,h.push({tx1:S,ty1:O,tx2:M,ty2:E,x1:j,y1:D,x2:A,y2:N,width:J,color:U,borderDash:Me,borderDashOffset:se,tickWidth:_e,tickColor:re,tickBorderDash:we,tickBorderDashOffset:Se}))}return this._ticksLength=f,this._borderValue=y,h}_computeLabelItems(t){const n=this.axis,r=this.options,{position:i,ticks:a}=r,o=this.isHorizontal(),s=this.ticks,{align:l,crossAlign:c,padding:u,mirror:f}=a,d=_r(r.grid),h=d+u,p=f?-u:h,m=-ht(this.labelRotation),g=[];let v,y,b,_,x,S,O,M,E,j,D,A,N="middle";if(i==="top")S=this.bottom-p,O=this._getXAxisLabelAlignment();else if(i==="bottom")S=this.top+p,O=this._getXAxisLabelAlignment();else if(i==="left"){const T=this._getYAxisLabelAlignment(d);O=T.textAlign,x=T.x}else if(i==="right"){const T=this._getYAxisLabelAlignment(d);O=T.textAlign,x=T.x}else if(n==="x"){if(i==="center")S=(t.top+t.bottom)/2+h;else if($(i)){const T=Object.keys(i)[0],L=i[T];S=this.chart.scales[T].getPixelForValue(L)+h}O=this._getXAxisLabelAlignment()}else if(n==="y"){if(i==="center")x=(t.left+t.right)/2-h;else if($(i)){const T=Object.keys(i)[0],L=i[T];x=this.chart.scales[T].getPixelForValue(L)}O=this._getYAxisLabelAlignment(d).textAlign}n==="y"&&(l==="start"?N="top":l==="end"&&(N="bottom"));const R=this._getLabelSizes();for(v=0,y=s.length;v<y;++v){b=s[v],_=b.label;const T=a.setContext(this.getContext(v));M=this.getPixelForTick(v)+a.labelOffset,E=this._resolveTickFontOptions(v),j=E.lineHeight,D=me(_)?_.length:1;const L=D/2,F=T.color,oe=T.textStrokeColor,J=T.textStrokeWidth;let U=O;o?(x=M,O==="inner"&&(v===y-1?U=this.options.reverse?"left":"right":v===0?U=this.options.reverse?"right":"left":U="center"),i==="top"?c==="near"||m!==0?A=-D*j+j/2:c==="center"?A=-R.highest.height/2-L*j+j:A=-R.highest.height+j/2:c==="near"||m!==0?A=j/2:c==="center"?A=R.highest.height/2-L*j:A=R.highest.height-D*j,f&&(A*=-1),m!==0&&!T.showLabelBackdrop&&(x+=j/2*Math.sin(m))):(S=M,A=(1-D)*j/2);let Me;if(T.showLabelBackdrop){const se=Gt(T.backdropPadding),_e=R.heights[v],re=R.widths[v];let we=A-se.top,Se=0-se.left;switch(N){case"middle":we-=_e/2;break;case"bottom":we-=_e;break}switch(O){case"center":Se-=re/2;break;case"right":Se-=re;break;case"inner":v===y-1?Se-=re:v>0&&(Se-=re/2);break}Me={left:Se,top:we,width:re+se.width,height:_e+se.height,color:T.backdropColor}}g.push({label:_,font:E,textOffset:A,options:{rotation:m,color:F,strokeColor:oe,strokeWidth:J,textAlign:U,textBaseline:N,translation:[x,S],backdrop:Me}})}return g}_getXAxisLabelAlignment(){const{position:t,ticks:n}=this.options;if(-ht(this.labelRotation))return t==="top"?"left":"right";let i="center";return n.align==="start"?i="left":n.align==="end"?i="right":n.align==="inner"&&(i="inner"),i}_getYAxisLabelAlignment(t){const{position:n,ticks:{crossAlign:r,mirror:i,padding:a}}=this.options,o=this._getLabelSizes(),s=t+a,l=o.widest.width;let c,u;return n==="left"?i?(u=this.right+a,r==="near"?c="left":r==="center"?(c="center",u+=l/2):(c="right",u+=l)):(u=this.right-s,r==="near"?c="right":r==="center"?(c="center",u-=l/2):(c="left",u=this.left)):n==="right"?i?(u=this.left+a,r==="near"?c="right":r==="center"?(c="center",u-=l/2):(c="left",u-=l)):(u=this.left+s,r==="near"?c="left":r==="center"?(c="center",u+=l/2):(c="right",u=this.right)):c="right",{textAlign:c,x:u}}_computeLabelArea(){if(this.options.ticks.mirror)return;const t=this.chart,n=this.options.position;if(n==="left"||n==="right")return{top:0,left:this.left,bottom:t.height,right:this.right};if(n==="top"||n==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:t.width}}drawBackground(){const{ctx:t,options:{backgroundColor:n},left:r,top:i,width:a,height:o}=this;n&&(t.save(),t.fillStyle=n,t.fillRect(r,i,a,o),t.restore())}getLineWidthForValue(t){const n=this.options.grid;if(!this._isVisible()||!n.display)return 0;const i=this.ticks.findIndex(a=>a.value===t);return i>=0?n.setContext(this.getContext(i)).lineWidth:0}drawGrid(t){const n=this.options.grid,r=this.ctx,i=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let a,o;const s=(l,c,u)=>{!u.width||!u.color||(r.save(),r.lineWidth=u.width,r.strokeStyle=u.color,r.setLineDash(u.borderDash||[]),r.lineDashOffset=u.borderDashOffset,r.beginPath(),r.moveTo(l.x,l.y),r.lineTo(c.x,c.y),r.stroke(),r.restore())};if(n.display)for(a=0,o=i.length;a<o;++a){const l=i[a];n.drawOnChartArea&&s({x:l.x1,y:l.y1},{x:l.x2,y:l.y2},l),n.drawTicks&&s({x:l.tx1,y:l.ty1},{x:l.tx2,y:l.ty2},{color:l.tickColor,width:l.tickWidth,borderDash:l.tickBorderDash,borderDashOffset:l.tickBorderDashOffset})}}drawBorder(){const{chart:t,ctx:n,options:{border:r,grid:i}}=this,a=r.setContext(this.getContext()),o=r.display?a.width:0;if(!o)return;const s=i.setContext(this.getContext(0)).lineWidth,l=this._borderValue;let c,u,f,d;this.isHorizontal()?(c=un(t,this.left,o)-o/2,u=un(t,this.right,s)+s/2,f=d=l):(f=un(t,this.top,o)-o/2,d=un(t,this.bottom,s)+s/2,c=u=l),n.save(),n.lineWidth=a.width,n.strokeStyle=a.color,n.beginPath(),n.moveTo(c,f),n.lineTo(u,d),n.stroke(),n.restore()}drawLabels(t){if(!this.options.ticks.display)return;const r=this.ctx,i=this._computeLabelArea();i&&Fm(r,i);const a=this.getLabelItems(t);for(const o of a){const s=o.options,l=o.font,c=o.label,u=o.textOffset;Ef(r,c,0,u,l,s)}i&&Bm(r)}drawTitle(){const{ctx:t,options:{position:n,title:r,reverse:i}}=this;if(!r.display)return;const a=pt(r.font),o=Gt(r.padding),s=r.align;let l=a.lineHeight/2;n==="bottom"||n==="center"||$(n)?(l+=o.bottom,me(r.text)&&(l+=a.lineHeight*(r.text.length-1))):l+=o.top;const{titleX:c,titleY:u,maxWidth:f,rotation:d}=x1(this,l,n,s);Ef(t,r.text,0,0,a,{color:r.color,maxWidth:f,rotation:d,textAlign:b1(s,n,i),textBaseline:"middle",translation:[c,u]})}draw(t){this._isVisible()&&(this.drawBackground(),this.drawGrid(t),this.drawBorder(),this.drawTitle(),this.drawLabels(t))}_layers(){const t=this.options,n=t.ticks&&t.ticks.z||0,r=V(t.grid&&t.grid.z,-1),i=V(t.border&&t.border.z,0);return!this._isVisible()||this.draw!==or.prototype.draw?[{z:n,draw:a=>{this.draw(a)}}]:[{z:r,draw:a=>{this.drawBackground(),this.drawGrid(a),this.drawTitle()}},{z:i,draw:()=>{this.drawBorder()}},{z:n,draw:a=>{this.drawLabels(a)}}]}getMatchingVisibleMetas(t){const n=this.chart.getSortedVisibleDatasetMetas(),r=this.axis+"AxisID",i=[];let a,o;for(a=0,o=n.length;a<o;++a){const s=n[a];s[r]===this.id&&(!t||s.type===t)&&i.push(s)}return i}_resolveTickFontOptions(t){const n=this.options.ticks.setContext(this.getContext(t));return pt(n.font)}_maxDigits(){const t=this._resolveTickFontOptions(0).lineHeight;return(this.isHorizontal()?this.width:this.height)/t}}class ji{constructor(t,n,r){this.type=t,this.scope=n,this.override=r,this.items=Object.create(null)}isForType(t){return Object.prototype.isPrototypeOf.call(this.type.prototype,t.prototype)}register(t){const n=Object.getPrototypeOf(t);let r;S1(n)&&(r=this.register(n));const i=this.items,a=t.id,o=this.scope+"."+a;if(!a)throw new Error("class does not have id: "+t);return a in i||(i[a]=t,_1(t,o,r),this.override&&ae.override(t.id,t.overrides)),o}get(t){return this.items[t]}unregister(t){const n=this.items,r=t.id,i=this.scope;r in n&&delete n[r],i&&r in ae[i]&&(delete ae[i][r],this.override&&delete An[r])}}function _1(e,t,n){const r=$r(Object.create(null),[n?ae.get(n):{},ae.get(t),e.defaults]);ae.set(t,r),e.defaultRoutes&&w1(t,e.defaultRoutes),e.descriptors&&ae.describe(t,e.descriptors)}function w1(e,t){Object.keys(t).forEach(n=>{const r=n.split("."),i=r.pop(),a=[e].concat(r).join("."),o=t[n].split("."),s=o.pop(),l=o.join(".");ae.route(a,i,l,s)})}function S1(e){return"id"in e&&"defaults"in e}class O1{constructor(){this.controllers=new ji(ir,"datasets",!0),this.elements=new ji(ar,"elements"),this.plugins=new ji(Object,"plugins"),this.scales=new ji(or,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,n,r){[...n].forEach(i=>{const a=r||this._getRegistryForType(i);r||a.isForType(i)||a===this.plugins&&i.id?this._exec(t,a,i):Y(i,o=>{const s=r||this._getRegistryForType(o);this._exec(t,s,o)})})}_exec(t,n,r){const i=Tc(t);le(r["before"+i],[],r),n[t](r),le(r["after"+i],[],r)}_getRegistryForType(t){for(let n=0;n<this._typedRegistries.length;n++){const r=this._typedRegistries[n];if(r.isForType(t))return r}return this.plugins}_get(t,n,r){const i=n.get(t);if(i===void 0)throw new Error('"'+t+'" is not a registered '+r+".");return i}}var dt=new O1;class P1{constructor(){this._init=void 0}notify(t,n,r,i){if(n==="beforeInit"&&(this._init=this._createDescriptors(t,!0),this._notify(this._init,t,"install")),this._init===void 0)return;const a=i?this._descriptors(t).filter(i):this._descriptors(t),o=this._notify(a,t,n,r);return n==="afterDestroy"&&(this._notify(a,t,"stop"),this._notify(this._init,t,"uninstall"),this._init=void 0),o}_notify(t,n,r,i){i=i||{};for(const a of t){const o=a.plugin,s=o[r],l=[n,i,a.options];if(le(s,l,o)===!1&&i.cancelable)return!1}return!0}invalidate(){H(this._cache)||(this._oldCache=this._cache,this._cache=void 0)}_descriptors(t){if(this._cache)return this._cache;const n=this._cache=this._createDescriptors(t);return this._notifyStateChanges(t),n}_createDescriptors(t,n){const r=t&&t.config,i=V(r.options&&r.options.plugins,{}),a=M1(r);return i===!1&&!n?[]:k1(t,a,i,n)}_notifyStateChanges(t){const n=this._oldCache||[],r=this._cache,i=(a,o)=>a.filter(s=>!o.some(l=>s.plugin.id===l.plugin.id));this._notify(i(n,r),t,"stop"),this._notify(i(r,n),t,"start")}}function M1(e){const t={},n=[],r=Object.keys(dt.plugins.items);for(let a=0;a<r.length;a++)n.push(dt.getPlugin(r[a]));const i=e.plugins||[];for(let a=0;a<i.length;a++){const o=i[a];n.indexOf(o)===-1&&(n.push(o),t[o.id]=!0)}return{plugins:n,localIds:t}}function A1(e,t){return!t&&e===!1?null:e===!0?{}:e}function k1(e,{plugins:t,localIds:n},r,i){const a=[],o=e.getContext();for(const s of t){const l=s.id,c=A1(r[l],i);c!==null&&a.push({plugin:s,options:C1(e.config,{plugin:s,local:n[l]},c,o)})}return a}function C1(e,{plugin:t,local:n},r,i){const a=e.pluginScopeKeys(t),o=e.getOptionScopes(r,a);return n&&t.defaults&&o.push(t.defaults),e.createResolver(o,i,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function Ll(e,t){const n=ae.datasets[e]||{};return((t.datasets||{})[e]||{}).indexAxis||t.indexAxis||n.indexAxis||"x"}function E1(e,t){let n=e;return e==="_index_"?n=t:e==="_value_"&&(n=t==="x"?"y":"x"),n}function D1(e,t){return e===t?"_index_":"_value_"}function rd(e){if(e==="x"||e==="y"||e==="r")return e}function T1(e){if(e==="top"||e==="bottom")return"x";if(e==="left"||e==="right")return"y"}function Nl(e,...t){if(rd(e))return e;for(const n of t){const r=n.axis||T1(n.position)||e.length>1&&rd(e[0].toLowerCase());if(r)return r}throw new Error(`Cannot determine type of '${e}' axis. Please provide 'axis' or 'position' option.`)}function id(e,t,n){if(n[t+"AxisID"]===e)return{axis:t}}function I1(e,t){if(t.data&&t.data.datasets){const n=t.data.datasets.filter(r=>r.xAxisID===e||r.yAxisID===e);if(n.length)return id(e,"x",n[0])||id(e,"y",n[0])}return{}}function j1(e,t){const n=An[e.type]||{scales:{}},r=t.scales||{},i=Ll(e.type,t),a=Object.create(null);return Object.keys(r).forEach(o=>{const s=r[o];if(!$(s))return console.error(`Invalid scale configuration for scale: ${o}`);if(s._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${o}`);const l=Nl(o,s,I1(o,e),ae.scales[s.type]),c=D1(l,i),u=n.scales||{};a[o]=Lr(Object.create(null),[{axis:l},s,u[l],u[c]])}),e.data.datasets.forEach(o=>{const s=o.type||e.type,l=o.indexAxis||Ll(s,t),u=(An[s]||{}).scales||{};Object.keys(u).forEach(f=>{const d=E1(f,l),h=o[d+"AxisID"]||d;a[h]=a[h]||Object.create(null),Lr(a[h],[{axis:d},r[h],u[f]])})}),Object.keys(a).forEach(o=>{const s=a[o];Lr(s,[ae.scales[s.type],ae.scale])}),a}function nv(e){const t=e.options||(e.options={});t.plugins=V(t.plugins,{}),t.scales=j1(e,t)}function rv(e){return e=e||{},e.datasets=e.datasets||[],e.labels=e.labels||[],e}function R1(e){return e=e||{},e.data=rv(e.data),nv(e),e}const ad=new Map,iv=new Set;function Ri(e,t){let n=ad.get(e);return n||(n=t(),ad.set(e,n),iv.add(n)),n}const wr=(e,t,n)=>{const r=Yt(t,n);r!==void 0&&e.add(r)};class L1{constructor(t){this._config=R1(t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=rv(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),nv(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return Ri(t,()=>[[`datasets.${t}`,""]])}datasetAnimationScopeKeys(t,n){return Ri(`${t}.transition.${n}`,()=>[[`datasets.${t}.transitions.${n}`,`transitions.${n}`],[`datasets.${t}`,""]])}datasetElementScopeKeys(t,n){return Ri(`${t}-${n}`,()=>[[`datasets.${t}.elements.${n}`,`datasets.${t}`,`elements.${n}`,""]])}pluginScopeKeys(t){const n=t.id,r=this.type;return Ri(`${r}-plugin-${n}`,()=>[[`plugins.${n}`,...t.additionalOptionScopes||[]]])}_cachedScopes(t,n){const r=this._scopeCache;let i=r.get(t);return(!i||n)&&(i=new Map,r.set(t,i)),i}getOptionScopes(t,n,r){const{options:i,type:a}=this,o=this._cachedScopes(t,r),s=o.get(n);if(s)return s;const l=new Set;n.forEach(u=>{t&&(l.add(t),u.forEach(f=>wr(l,t,f))),u.forEach(f=>wr(l,i,f)),u.forEach(f=>wr(l,An[a]||{},f)),u.forEach(f=>wr(l,ae,f)),u.forEach(f=>wr(l,Il,f))});const c=Array.from(l);return c.length===0&&c.push(Object.create(null)),iv.has(n)&&o.set(n,c),c}chartOptionScopes(){const{options:t,type:n}=this;return[t,An[n]||{},ae.datasets[n]||{},{type:n},ae,Il]}resolveNamedOptions(t,n,r,i=[""]){const a={$shared:!0},{resolver:o,subPrefixes:s}=od(this._resolverCache,t,i);let l=o;if(F1(o,n)){a.$shared=!1,r=Xt(r)?r():r;const c=this.createResolver(t,r,s);l=Kn(o,r,c)}for(const c of n)a[c]=l[c];return a}createResolver(t,n,r=[""],i){const{resolver:a}=od(this._resolverCache,t,r);return $(n)?Kn(a,n,void 0,i):a}}function od(e,t,n){let r=e.get(t);r||(r=new Map,e.set(t,r));const i=n.join();let a=r.get(i);return a||(a={resolver:Rc(t,n),subPrefixes:n.filter(s=>!s.toLowerCase().includes("hover"))},r.set(i,a)),a}const N1=e=>$(e)&&Object.getOwnPropertyNames(e).some(t=>Xt(e[t]));function F1(e,t){const{isScriptable:n,isIndexable:r}=Wm(e);for(const i of t){const a=n(i),o=r(i),s=(o||a)&&e[i];if(a&&(Xt(s)||N1(s))||o&&me(s))return!0}return!1}var B1="4.5.1";const z1=["top","bottom","left","right","chartArea"];function sd(e,t){return e==="top"||e==="bottom"||z1.indexOf(e)===-1&&t==="x"}function ld(e,t){return function(n,r){return n[e]===r[e]?n[t]-r[t]:n[e]-r[e]}}function cd(e){const t=e.chart,n=t.options.animation;t.notifyPlugins("afterRender"),le(n&&n.onComplete,[e],t)}function $1(e){const t=e.chart,n=t.options.animation;le(n&&n.onProgress,[e],t)}function av(e){return Fc()&&typeof e=="string"?e=document.getElementById(e):e&&e.length&&(e=e[0]),e&&e.canvas&&(e=e.canvas),e}const na={},ud=e=>{const t=av(e);return Object.values(na).filter(n=>n.canvas===t).pop()};function W1(e,t,n){const r=Object.keys(e);for(const i of r){const a=+i;if(a>=t){const o=e[i];delete e[i],(n>0||a>t)&&(e[a+n]=o)}}}function q1(e,t,n,r){return!n||e.type==="mouseout"?null:r?t:e}class U1{static defaults=ae;static instances=na;static overrides=An;static registry=dt;static version=B1;static getChart=ud;static register(...t){dt.add(...t),fd()}static unregister(...t){dt.remove(...t),fd()}constructor(t,n){const r=this.config=new L1(n),i=av(t),a=ud(i);if(a)throw new Error("Canvas is already in use. Chart with ID '"+a.id+"' must be destroyed before the canvas with ID '"+a.canvas.id+"' can be reused.");const o=r.createResolver(r.chartOptionScopes(),this.getContext());this.platform=new(r.platform||s1(i)),this.platform.updateConfig(r);const s=this.platform.acquireContext(i,o.aspectRatio),l=s&&s.canvas,c=l&&l.height,u=l&&l.width;if(this.id=Ix(),this.ctx=s,this.canvas=l,this.width=u,this.height=c,this._options=o,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new P1,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=Jx(f=>this.update(f),o.resizeDelay||0),this._dataChanges=[],na[this.id]=this,!s||!l){console.error("Failed to create chart: can't acquire context from the given item");return}wt.listen(this,"complete",cd),wt.listen(this,"progress",$1),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:n},width:r,height:i,_aspectRatio:a}=this;return H(t)?n&&a?a:i?r/i:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}get registry(){return dt}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():If(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return Cf(this.canvas,this.ctx),this}stop(){return wt.stop(this),this}resize(t,n){wt.running(this)?this._resizeBeforeDraw={width:t,height:n}:this._resize(t,n)}_resize(t,n){const r=this.options,i=this.canvas,a=r.maintainAspectRatio&&this.aspectRatio,o=this.platform.getMaximumSize(i,t,n,a),s=r.devicePixelRatio||this.platform.getDevicePixelRatio(),l=this.width?"resize":"attach";this.width=o.width,this.height=o.height,this._aspectRatio=this.aspectRatio,If(this,s,!0)&&(this.notifyPlugins("resize",{size:o}),le(r.onResize,[this,o],this),this.attached&&this._doResize(l)&&this.render())}ensureScalesHaveIDs(){const n=this.options.scales||{};Y(n,(r,i)=>{r.id=i})}buildOrUpdateScales(){const t=this.options,n=t.scales,r=this.scales,i=Object.keys(r).reduce((o,s)=>(o[s]=!1,o),{});let a=[];n&&(a=a.concat(Object.keys(n).map(o=>{const s=n[o],l=Nl(o,s),c=l==="r",u=l==="x";return{options:s,dposition:c?"chartArea":u?"bottom":"left",dtype:c?"radialLinear":u?"category":"linear"}}))),Y(a,o=>{const s=o.options,l=s.id,c=Nl(l,s),u=V(s.type,o.dtype);(s.position===void 0||sd(s.position,c)!==sd(o.dposition))&&(s.position=o.dposition),i[l]=!0;let f=null;if(l in r&&r[l].type===u)f=r[l];else{const d=dt.getScale(u);f=new d({id:l,type:u,ctx:this.ctx,chart:this}),r[f.id]=f}f.init(s,t)}),Y(i,(o,s)=>{o||delete r[s]}),Y(r,o=>{Ti.configure(this,o,o.options),Ti.addBox(this,o)})}_updateMetasets(){const t=this._metasets,n=this.data.datasets.length,r=t.length;if(t.sort((i,a)=>i.index-a.index),r>n){for(let i=n;i<r;++i)this._destroyDatasetMeta(i);t.splice(n,r-n)}this._sortedMetasets=t.slice(0).sort(ld("order","index"))}_removeUnreferencedMetasets(){const{_metasets:t,data:{datasets:n}}=this;t.length>n.length&&delete this._stacks,t.forEach((r,i)=>{n.filter(a=>a===r._dataset).length===0&&this._destroyDatasetMeta(i)})}buildOrUpdateControllers(){const t=[],n=this.data.datasets;let r,i;for(this._removeUnreferencedMetasets(),r=0,i=n.length;r<i;r++){const a=n[r];let o=this.getDatasetMeta(r);const s=a.type||this.config.type;if(o.type&&o.type!==s&&(this._destroyDatasetMeta(r),o=this.getDatasetMeta(r)),o.type=s,o.indexAxis=a.indexAxis||Ll(s,this.options),o.order=a.order||0,o.index=r,o.label=""+a.label,o.visible=this.isDatasetVisible(r),o.controller)o.controller.updateIndex(r),o.controller.linkScales();else{const l=dt.getController(s),{datasetElementType:c,dataElementType:u}=ae.datasets[s];Object.assign(l,{dataElementType:dt.getElement(u),datasetElementType:c&&dt.getElement(c)}),o.controller=new l(this,r),t.push(o.controller)}}return this._updateMetasets(),t}_resetElements(){Y(this.data.datasets,(t,n)=>{this.getDatasetMeta(n).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const n=this.config;n.update();const r=this._options=n.createResolver(n.chartOptionScopes(),this.getContext()),i=this._animationsDisabled=!r.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0})===!1)return;const a=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let o=0;for(let c=0,u=this.data.datasets.length;c<u;c++){const{controller:f}=this.getDatasetMeta(c),d=!i&&a.indexOf(f)===-1;f.buildOrUpdateElements(d),o=Math.max(+f.getMaxOverflow(),o)}o=this._minPadding=r.layout.autoPadding?o:0,this._updateLayout(o),i||Y(a,c=>{c.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(ld("z","_idx"));const{_active:s,_lastEvent:l}=this;l?this._eventHandler(l,!0):s.length&&this._updateHoverStyles(s,s,!0),this.render()}_updateScales(){Y(this.scales,t=>{Ti.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,n=new Set(Object.keys(this._listeners)),r=new Set(t.events);(!yf(n,r)||!!this._responsiveListeners!==t.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,n=this._getUniformDataChanges()||[];for(const{method:r,start:i,count:a}of n){const o=r==="_removeElements"?-a:a;W1(t,i,o)}}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const n=this.data.datasets.length,r=a=>new Set(t.filter(o=>o[0]===a).map((o,s)=>s+","+o.splice(1).join(","))),i=r(0);for(let a=1;a<n;a++)if(!yf(i,r(a)))return;return Array.from(i).map(a=>a.split(",")).map(a=>({method:a[1],start:+a[2],count:+a[3]}))}_updateLayout(t){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;Ti.update(this,this.width,this.height,t);const n=this.chartArea,r=n.width<=0||n.height<=0;this._layers=[],Y(this.boxes,i=>{r&&i.position==="chartArea"||(i.configure&&i.configure(),this._layers.push(...i._layers()))},this),this._layers.forEach((i,a)=>{i._idx=a}),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})!==!1){for(let n=0,r=this.data.datasets.length;n<r;++n)this.getDatasetMeta(n).controller.configure();for(let n=0,r=this.data.datasets.length;n<r;++n)this._updateDataset(n,Xt(t)?t({datasetIndex:n}):t);this.notifyPlugins("afterDatasetsUpdate",{mode:t})}}_updateDataset(t,n){const r=this.getDatasetMeta(t),i={meta:r,index:t,mode:n,cancelable:!0};this.notifyPlugins("beforeDatasetUpdate",i)!==!1&&(r.controller._update(n),i.cancelable=!1,this.notifyPlugins("afterDatasetUpdate",i))}render(){this.notifyPlugins("beforeRender",{cancelable:!0})!==!1&&(wt.has(this)?this.attached&&!wt.running(this)&&wt.start(this):(this.draw(),cd({chart:this})))}draw(){let t;if(this._resizeBeforeDraw){const{width:r,height:i}=this._resizeBeforeDraw;this._resizeBeforeDraw=null,this._resize(r,i)}if(this.clear(),this.width<=0||this.height<=0||this.notifyPlugins("beforeDraw",{cancelable:!0})===!1)return;const n=this._layers;for(t=0;t<n.length&&n[t].z<=0;++t)n[t].draw(this.chartArea);for(this._drawDatasets();t<n.length;++t)n[t].draw(this.chartArea);this.notifyPlugins("afterDraw")}_getSortedDatasetMetas(t){const n=this._sortedMetasets,r=[];let i,a;for(i=0,a=n.length;i<a;++i){const o=n[i];(!t||o.visible)&&r.push(o)}return r}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(!0)}_drawDatasets(){if(this.notifyPlugins("beforeDatasetsDraw",{cancelable:!0})===!1)return;const t=this.getSortedVisibleDatasetMetas();for(let n=t.length-1;n>=0;--n)this._drawDataset(t[n]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const n=this.ctx,r={meta:t,index:t.index,cancelable:!0},i=sw(this,t);this.notifyPlugins("beforeDatasetDraw",r)!==!1&&(i&&Fm(n,i),t.controller.draw(),i&&Bm(n),r.cancelable=!1,this.notifyPlugins("afterDatasetDraw",r))}isPointInArea(t){return qr(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,n,r,i){const a=zw.modes[n];return typeof a=="function"?a(this,t,r,i):[]}getDatasetMeta(t){const n=this.data.datasets[t],r=this._metasets;let i=r.filter(a=>a&&a._dataset===n).pop();return i||(i={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n&&n.order||0,index:t,_dataset:n,_parsed:[],_sorted:!1},r.push(i)),i}getContext(){return this.$context||(this.$context=jn(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const n=this.data.datasets[t];if(!n)return!1;const r=this.getDatasetMeta(t);return typeof r.hidden=="boolean"?!r.hidden:!n.hidden}setDatasetVisibility(t,n){const r=this.getDatasetMeta(t);r.hidden=!n}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,n,r){const i=r?"show":"hide",a=this.getDatasetMeta(t),o=a.controller._resolveAnimations(void 0,i);Wr(n)?(a.data[n].hidden=!r,this.update()):(this.setDatasetVisibility(t,r),o.update(a,{visible:r}),this.update(s=>s.datasetIndex===t?i:void 0))}hide(t,n){this._updateVisibility(t,n,!1)}show(t,n){this._updateVisibility(t,n,!0)}_destroyDatasetMeta(t){const n=this._metasets[t];n&&n.controller&&n.controller._destroy(),delete this._metasets[t]}_stop(){let t,n;for(this.stop(),wt.remove(this),t=0,n=this.data.datasets.length;t<n;++t)this._destroyDatasetMeta(t)}destroy(){this.notifyPlugins("beforeDestroy");const{canvas:t,ctx:n}=this;this._stop(),this.config.clearCache(),t&&(this.unbindEvents(),Cf(t,n),this.platform.releaseContext(n),this.canvas=null,this.ctx=null),delete na[this.id],this.notifyPlugins("afterDestroy")}toBase64Image(...t){return this.canvas.toDataURL(...t)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=!0}bindUserEvents(){const t=this._listeners,n=this.platform,r=(a,o)=>{n.addEventListener(this,a,o),t[a]=o},i=(a,o,s)=>{a.offsetX=o,a.offsetY=s,this._eventHandler(a)};Y(this.options.events,a=>r(a,i))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,n=this.platform,r=(l,c)=>{n.addEventListener(this,l,c),t[l]=c},i=(l,c)=>{t[l]&&(n.removeEventListener(this,l,c),delete t[l])},a=(l,c)=>{this.canvas&&this.resize(l,c)};let o;const s=()=>{i("attach",s),this.attached=!0,this.resize(),r("resize",a),r("detach",o)};o=()=>{this.attached=!1,i("resize",a),this._stop(),this._resize(0,0),r("attach",s)},n.isAttached(this.canvas)?s():o()}unbindEvents(){Y(this._listeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._listeners={},Y(this._responsiveListeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,n,r){const i=r?"set":"remove";let a,o,s,l;for(n==="dataset"&&(a=this.getDatasetMeta(t[0].datasetIndex),a.controller["_"+i+"DatasetHoverStyle"]()),s=0,l=t.length;s<l;++s){o=t[s];const c=o&&this.getDatasetMeta(o.datasetIndex).controller;c&&c[i+"HoverStyle"](o.element,o.datasetIndex,o.index)}}getActiveElements(){return this._active||[]}setActiveElements(t){const n=this._active||[],r=t.map(({datasetIndex:a,index:o})=>{const s=this.getDatasetMeta(a);if(!s)throw new Error("No dataset found at index "+a);return{datasetIndex:a,element:s.data[o],index:o}});!sa(r,n)&&(this._active=r,this._lastEvent=null,this._updateHoverStyles(r,n))}notifyPlugins(t,n,r){return this._plugins.notify(this,t,n,r)}isPluginEnabled(t){return this._plugins._cache.filter(n=>n.plugin.id===t).length===1}_updateHoverStyles(t,n,r){const i=this.options.hover,a=(l,c)=>l.filter(u=>!c.some(f=>u.datasetIndex===f.datasetIndex&&u.index===f.index)),o=a(n,t),s=r?t:a(t,n);o.length&&this.updateHoverStyle(o,i.mode,!1),s.length&&i.mode&&this.updateHoverStyle(s,i.mode,!0)}_eventHandler(t,n){const r={event:t,replay:n,cancelable:!0,inChartArea:this.isPointInArea(t)},i=o=>(o.options.events||this.options.events).includes(t.native.type);if(this.notifyPlugins("beforeEvent",r,i)===!1)return;const a=this._handleEvent(t,n,r.inChartArea);return r.cancelable=!1,this.notifyPlugins("afterEvent",r,i),(a||r.changed)&&this.render(),this}_handleEvent(t,n,r){const{_active:i=[],options:a}=this,o=n,s=this._getActiveElements(t,i,r,o),l=Bx(t),c=q1(t,this._lastEvent,r,l);r&&(this._lastEvent=null,le(a.onHover,[t,s,this],this),l&&le(a.onClick,[t,s,this],this));const u=!sa(s,i);return(u||n)&&(this._active=s,this._updateHoverStyles(s,i,n)),this._lastEvent=c,u}_getActiveElements(t,n,r,i){if(t.type==="mouseout")return[];if(!r)return n;const a=this.options.hover;return this.getElementsAtEventForMode(t,a.mode,a,i)}}function fd(){return Y(U1.instances,e=>e._plugins.invalidate())}function ov(e,t,n=t){e.lineCap=V(n.borderCapStyle,t.borderCapStyle),e.setLineDash(V(n.borderDash,t.borderDash)),e.lineDashOffset=V(n.borderDashOffset,t.borderDashOffset),e.lineJoin=V(n.borderJoinStyle,t.borderJoinStyle),e.lineWidth=V(n.borderWidth,t.borderWidth),e.strokeStyle=V(n.borderColor,t.borderColor)}function V1(e,t,n){e.lineTo(n.x,n.y)}function H1(e){return e.stepped?d_:e.tension||e.cubicInterpolationMode==="monotone"?h_:V1}function sv(e,t,n={}){const r=e.length,{start:i=0,end:a=r-1}=n,{start:o,end:s}=t,l=Math.max(i,o),c=Math.min(a,s),u=i<o&&a<o||i>s&&a>s;return{count:r,start:l,loop:t.loop,ilen:c<l&&!u?r+c-l:c-l}}function K1(e,t,n,r){const{points:i,options:a}=t,{count:o,start:s,loop:l,ilen:c}=sv(i,n,r),u=H1(a);let{move:f=!0,reverse:d}=r||{},h,p,m;for(h=0;h<=c;++h)p=i[(s+(d?c-h:h))%o],!p.skip&&(f?(e.moveTo(p.x,p.y),f=!1):u(e,m,p,d,a.stepped),m=p);return l&&(p=i[(s+(d?c:0))%o],u(e,m,p,d,a.stepped)),!!l}function Y1(e,t,n,r){const i=t.points,{count:a,start:o,ilen:s}=sv(i,n,r),{move:l=!0,reverse:c}=r||{};let u=0,f=0,d,h,p,m,g,v;const y=_=>(o+(c?s-_:_))%a,b=()=>{m!==g&&(e.lineTo(u,g),e.lineTo(u,m),e.lineTo(u,v))};for(l&&(h=i[y(0)],e.moveTo(h.x,h.y)),d=0;d<=s;++d){if(h=i[y(d)],h.skip)continue;const _=h.x,x=h.y,S=_|0;S===p?(x<m?m=x:x>g&&(g=x),u=(f*u+_)/++f):(b(),e.lineTo(_,x),p=S,f=0,m=g=x),v=x}b()}function Fl(e){const t=e.options,n=t.borderDash&&t.borderDash.length;return!e._decimated&&!e._loop&&!t.tension&&t.cubicInterpolationMode!=="monotone"&&!t.stepped&&!n?Y1:K1}function X1(e){return e.stepped?H_:e.tension||e.cubicInterpolationMode==="monotone"?K_:pn}function G1(e,t,n,r){let i=t._path;i||(i=t._path=new Path2D,t.path(i,n,r)&&i.closePath()),ov(e,t.options),e.stroke(i)}function Z1(e,t,n,r){const{segments:i,options:a}=t,o=Fl(t);for(const s of i)ov(e,a,s.style),e.beginPath(),o(e,t,s,{start:n,end:n+r-1})&&e.closePath(),e.stroke()}const Q1=typeof Path2D=="function";function J1(e,t,n,r){Q1&&!t.options.segment?G1(e,t,n,r):Z1(e,t,n,r)}class QR extends ar{static id="line";static defaults={borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:3,capBezierPoints:!0,cubicInterpolationMode:"default",fill:!1,spanGaps:!1,stepped:!1,tension:0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};static descriptors={_scriptable:!0,_indexable:t=>t!=="borderDash"&&t!=="fill"};constructor(t){super(),this.animated=!0,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,this._datasetIndex=void 0,t&&Object.assign(this,t)}updateControlPoints(t,n){const r=this.options;if((r.tension||r.cubicInterpolationMode==="monotone")&&!r.stepped&&!this._pointsUpdated){const i=r.spanGaps?this._loop:this._fullLoop;F_(this._points,r,t,i,n),this._pointsUpdated=!0}}set points(t){this._points=t,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=rw(this,this.options.segment))}first(){const t=this.segments,n=this.points;return t.length&&n[t[0].start]}last(){const t=this.segments,n=this.points,r=t.length;return r&&n[t[r-1].end]}interpolate(t,n){const r=this.options,i=t[n],a=this.points,o=ew(this,{property:n,start:i,end:i});if(!o.length)return;const s=[],l=X1(r);let c,u;for(c=0,u=o.length;c<u;++c){const{start:f,end:d}=o[c],h=a[f],p=a[d];if(h===p){s.push(h);continue}const m=Math.abs((i-h[n])/(p[n]-h[n])),g=l(h,p,m,r.stepped);g[n]=t[n],s.push(g)}return s.length===1?s[0]:s}pathSegment(t,n,r){return Fl(this)(t,this,n,r)}path(t,n,r){const i=this.segments,a=Fl(this);let o=this._loop;n=n||0,r=r||this.points.length-n;for(const s of i)o&=a(t,this,s,{start:n,end:n+r-1});return!!o}draw(t,n,r,i){const a=this.options||{};(this.points||[]).length&&a.borderWidth&&(t.save(),J1(t,this,r,i),t.restore()),this.animated&&(this._pointsUpdated=!1,this._path=void 0)}}function dd(e,t,n,r){const i=e.options,{[n]:a}=e.getProps([n],r);return Math.abs(t-a)<i.radius+i.hitRadius}class JR extends ar{static id="point";parsed;skip;stop;static defaults={borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};constructor(t){super(),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,t&&Object.assign(this,t)}inRange(t,n,r){const i=this.options,{x:a,y:o}=this.getProps(["x","y"],r);return Math.pow(t-a,2)+Math.pow(n-o,2)<Math.pow(i.hitRadius+i.radius,2)}inXRange(t,n){return dd(this,t,"x",n)}inYRange(t,n){return dd(this,t,"y",n)}getCenterPoint(t){const{x:n,y:r}=this.getProps(["x","y"],t);return{x:n,y:r}}size(t){t=t||this.options||{};let n=t.radius||0;n=Math.max(n,n&&t.hoverRadius||0);const r=n&&t.borderWidth||0;return(n+r)*2}draw(t,n){const r=this.options;this.skip||r.radius<.1||!qr(this,n,this.size(r)/2)||(t.strokeStyle=r.borderColor,t.lineWidth=r.borderWidth,t.fillStyle=r.backgroundColor,jl(t,r,this.x,this.y))}getRange(){const t=this.options||{};return t.radius+t.hitRadius}}function lv(e,t){const{x:n,y:r,base:i,width:a,height:o}=e.getProps(["x","y","base","width","height"],t);let s,l,c,u,f;return e.horizontal?(f=o/2,s=Math.min(n,i),l=Math.max(n,i),c=r-f,u=r+f):(f=a/2,s=n-f,l=n+f,c=Math.min(r,i),u=Math.max(r,i)),{left:s,top:c,right:l,bottom:u}}function qt(e,t,n,r){return e?0:We(t,n,r)}function eS(e,t,n){const r=e.options.borderWidth,i=e.borderSkipped,a=$m(r);return{t:qt(i.top,a.top,0,n),r:qt(i.right,a.right,0,t),b:qt(i.bottom,a.bottom,0,n),l:qt(i.left,a.left,0,t)}}function tS(e,t,n){const{enableBorderRadius:r}=e.getProps(["enableBorderRadius"]),i=e.options.borderRadius,a=zr(i),o=Math.min(t,n),s=e.borderSkipped,l=r||$(i);return{topLeft:qt(!l||s.top||s.left,a.topLeft,0,o),topRight:qt(!l||s.top||s.right,a.topRight,0,o),bottomLeft:qt(!l||s.bottom||s.left,a.bottomLeft,0,o),bottomRight:qt(!l||s.bottom||s.right,a.bottomRight,0,o)}}function nS(e){const t=lv(e),n=t.right-t.left,r=t.bottom-t.top,i=eS(e,n/2,r/2),a=tS(e,n/2,r/2);return{outer:{x:t.left,y:t.top,w:n,h:r,radius:a},inner:{x:t.left+i.l,y:t.top+i.t,w:n-i.l-i.r,h:r-i.t-i.b,radius:{topLeft:Math.max(0,a.topLeft-Math.max(i.t,i.l)),topRight:Math.max(0,a.topRight-Math.max(i.t,i.r)),bottomLeft:Math.max(0,a.bottomLeft-Math.max(i.b,i.l)),bottomRight:Math.max(0,a.bottomRight-Math.max(i.b,i.r))}}}}function Jo(e,t,n,r){const i=t===null,a=n===null,s=e&&!(i&&a)&&lv(e,r);return s&&(i||Tl(t,s.left,s.right))&&(a||Tl(n,s.top,s.bottom))}function rS(e){return e.topLeft||e.topRight||e.bottomLeft||e.bottomRight}function iS(e,t){e.rect(t.x,t.y,t.w,t.h)}function es(e,t,n={}){const r=e.x!==n.x?-t:0,i=e.y!==n.y?-t:0,a=(e.x+e.w!==n.x+n.w?t:0)-r,o=(e.y+e.h!==n.y+n.h?t:0)-i;return{x:e.x+r,y:e.y+i,w:e.w+a,h:e.h+o,radius:e.radius}}class eL extends ar{static id="bar";static defaults={borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};constructor(t){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,t&&Object.assign(this,t)}draw(t){const{inflateAmount:n,options:{borderColor:r,backgroundColor:i}}=this,{inner:a,outer:o}=nS(this),s=rS(o.radius)?Rl:iS;t.save(),(o.w!==a.w||o.h!==a.h)&&(t.beginPath(),s(t,es(o,n,a)),t.clip(),s(t,es(a,-n,o)),t.fillStyle=r,t.fill("evenodd")),t.beginPath(),s(t,es(a,n)),t.fillStyle=i,t.fill(),t.restore()}inRange(t,n,r){return Jo(this,t,n,r)}inXRange(t,n){return Jo(this,t,null,n)}inYRange(t,n){return Jo(this,null,t,n)}getCenterPoint(t){const{x:n,y:r,base:i,horizontal:a}=this.getProps(["x","y","base","horizontal"],t);return{x:a?(n+i)/2:n,y:a?r:(r+i)/2}}getRange(t){return t==="x"?this.width/2:this.height/2}}const Bl=["rgb(54, 162, 235)","rgb(255, 99, 132)","rgb(255, 159, 64)","rgb(255, 205, 86)","rgb(75, 192, 192)","rgb(153, 102, 255)","rgb(201, 203, 207)"],hd=Bl.map(e=>e.replace("rgb(","rgba(").replace(")",", 0.5)"));function cv(e){return Bl[e%Bl.length]}function uv(e){return hd[e%hd.length]}function aS(e,t){return e.borderColor=cv(t),e.backgroundColor=uv(t),++t}function oS(e,t){return e.backgroundColor=e.data.map(()=>cv(t++)),t}function sS(e,t){return e.backgroundColor=e.data.map(()=>uv(t++)),t}function lS(e){let t=0;return(n,r)=>{const i=e.getDatasetMeta(r).controller;i instanceof Iw?t=oS(n,t):i instanceof jw?t=sS(n,t):i&&(t=aS(n,t))}}function pd(e){let t;for(t in e)if(e[t].borderColor||e[t].backgroundColor)return!0;return!1}function cS(e){return e&&(e.borderColor||e.backgroundColor)}function uS(){return ae.borderColor!=="rgba(0,0,0,0.1)"||ae.backgroundColor!=="rgba(0,0,0,0.1)"}var tL={id:"colors",defaults:{enabled:!0,forceOverride:!1},beforeLayout(e,t,n){if(!n.enabled)return;const{data:{datasets:r},options:i}=e.config,{elements:a}=i,o=pd(r)||cS(i)||a&&pd(a)||uS();if(!n.forceOverride&&o)return;const s=lS(e);r.forEach(s)}};const Ir={average(e){if(!e.length)return!1;let t,n,r=new Set,i=0,a=0;for(t=0,n=e.length;t<n;++t){const s=e[t].element;if(s&&s.hasValue()){const l=s.tooltipPosition();r.add(l.x),i+=l.y,++a}}return a===0||r.size===0?!1:{x:[...r].reduce((s,l)=>s+l)/r.size,y:i/a}},nearest(e,t){if(!e.length)return!1;let n=t.x,r=t.y,i=Number.POSITIVE_INFINITY,a,o,s;for(a=0,o=e.length;a<o;++a){const l=e[a].element;if(l&&l.hasValue()){const c=l.getCenterPoint(),u=Dl(t,c);u<i&&(i=u,s=l)}}if(s){const l=s.tooltipPosition();n=l.x,r=l.y}return{x:n,y:r}}};function ft(e,t){return t&&(me(t)?Array.prototype.push.apply(e,t):e.push(t)),e}function St(e){return(typeof e=="string"||e instanceof String)&&e.indexOf(`
|
|
2
|
-
`)>-1?e.split(`
|
|
3
|
-
`):e}function fS(e,t){const{element:n,datasetIndex:r,index:i}=t,a=e.getDatasetMeta(r).controller,{label:o,value:s}=a.getLabelAndValue(i);return{chart:e,label:o,parsed:a.getParsed(i),raw:e.data.datasets[r].data[i],formattedValue:s,dataset:a.getDataset(),dataIndex:i,datasetIndex:r,element:n}}function gd(e,t){const n=e.chart.ctx,{body:r,footer:i,title:a}=e,{boxWidth:o,boxHeight:s}=t,l=pt(t.bodyFont),c=pt(t.titleFont),u=pt(t.footerFont),f=a.length,d=i.length,h=r.length,p=Gt(t.padding);let m=p.height,g=0,v=r.reduce((_,x)=>_+x.before.length+x.lines.length+x.after.length,0);if(v+=e.beforeBody.length+e.afterBody.length,f&&(m+=f*c.lineHeight+(f-1)*t.titleSpacing+t.titleMarginBottom),v){const _=t.displayColors?Math.max(s,l.lineHeight):l.lineHeight;m+=h*_+(v-h)*l.lineHeight+(v-1)*t.bodySpacing}d&&(m+=t.footerMarginTop+d*u.lineHeight+(d-1)*t.footerSpacing);let y=0;const b=function(_){g=Math.max(g,n.measureText(_).width+y)};return n.save(),n.font=c.string,Y(e.title,b),n.font=l.string,Y(e.beforeBody.concat(e.afterBody),b),y=t.displayColors?o+2+t.boxPadding:0,Y(r,_=>{Y(_.before,b),Y(_.lines,b),Y(_.after,b)}),y=0,n.font=u.string,Y(e.footer,b),n.restore(),g+=p.width,{width:g,height:m}}function dS(e,t){const{y:n,height:r}=t;return n<r/2?"top":n>e.height-r/2?"bottom":"center"}function hS(e,t,n,r){const{x:i,width:a}=r,o=n.caretSize+n.caretPadding;if(e==="left"&&i+a+o>t.width||e==="right"&&i-a-o<0)return!0}function pS(e,t,n,r){const{x:i,width:a}=n,{width:o,chartArea:{left:s,right:l}}=e;let c="center";return r==="center"?c=i<=(s+l)/2?"left":"right":i<=a/2?c="left":i>=o-a/2&&(c="right"),hS(c,e,t,n)&&(c="center"),c}function md(e,t,n){const r=n.yAlign||t.yAlign||dS(e,n);return{xAlign:n.xAlign||t.xAlign||pS(e,t,n,r),yAlign:r}}function gS(e,t){let{x:n,width:r}=e;return t==="right"?n-=r:t==="center"&&(n-=r/2),n}function mS(e,t,n){let{y:r,height:i}=e;return t==="top"?r+=n:t==="bottom"?r-=i+n:r-=i/2,r}function vd(e,t,n,r){const{caretSize:i,caretPadding:a,cornerRadius:o}=e,{xAlign:s,yAlign:l}=n,c=i+a,{topLeft:u,topRight:f,bottomLeft:d,bottomRight:h}=zr(o);let p=gS(t,s);const m=mS(t,l,c);return l==="center"?s==="left"?p+=c:s==="right"&&(p-=c):s==="left"?p-=Math.max(u,d)+i:s==="right"&&(p+=Math.max(f,h)+i),{x:We(p,0,r.width-t.width),y:We(m,0,r.height-t.height)}}function Li(e,t,n){const r=Gt(n.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-r.right:e.x+r.left}function yd(e){return ft([],St(e))}function vS(e,t,n){return jn(e,{tooltip:t,tooltipItems:n,type:"tooltip"})}function bd(e,t){const n=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return n?e.override(n):e}const fv={beforeTitle:_t,title(e){if(e.length>0){const t=e[0],n=t.chart.data.labels,r=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(r>0&&t.dataIndex<r)return n[t.dataIndex]}return""},afterTitle:_t,beforeBody:_t,beforeLabel:_t,label(e){if(this&&this.options&&this.options.mode==="dataset")return e.label+": "+e.formattedValue||e.formattedValue;let t=e.dataset.label||"";t&&(t+=": ");const n=e.formattedValue;return H(n)||(t+=n),t},labelColor(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{borderColor:n.borderColor,backgroundColor:n.backgroundColor,borderWidth:n.borderWidth,borderDash:n.borderDash,borderDashOffset:n.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{pointStyle:n.pointStyle,rotation:n.rotation}},afterLabel:_t,afterBody:_t,beforeFooter:_t,footer:_t,afterFooter:_t};function Ie(e,t,n,r){const i=e[t].call(n,r);return typeof i>"u"?fv[t].call(n,r):i}let xd=class extends ar{static positioners=Ir;constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const n=this.chart,r=this.options.setContext(this.getContext()),i=r.enabled&&n.options.animation&&r.animations,a=new Ym(this.chart,i);return i._cacheable&&(this._cachedAnimations=Object.freeze(a)),a}getContext(){return this.$context||(this.$context=vS(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,n){const{callbacks:r}=n,i=Ie(r,"beforeTitle",this,t),a=Ie(r,"title",this,t),o=Ie(r,"afterTitle",this,t);let s=[];return s=ft(s,St(i)),s=ft(s,St(a)),s=ft(s,St(o)),s}getBeforeBody(t,n){return yd(Ie(n.callbacks,"beforeBody",this,t))}getBody(t,n){const{callbacks:r}=n,i=[];return Y(t,a=>{const o={before:[],lines:[],after:[]},s=bd(r,a);ft(o.before,St(Ie(s,"beforeLabel",this,a))),ft(o.lines,Ie(s,"label",this,a)),ft(o.after,St(Ie(s,"afterLabel",this,a))),i.push(o)}),i}getAfterBody(t,n){return yd(Ie(n.callbacks,"afterBody",this,t))}getFooter(t,n){const{callbacks:r}=n,i=Ie(r,"beforeFooter",this,t),a=Ie(r,"footer",this,t),o=Ie(r,"afterFooter",this,t);let s=[];return s=ft(s,St(i)),s=ft(s,St(a)),s=ft(s,St(o)),s}_createItems(t){const n=this._active,r=this.chart.data,i=[],a=[],o=[];let s=[],l,c;for(l=0,c=n.length;l<c;++l)s.push(fS(this.chart,n[l]));return t.filter&&(s=s.filter((u,f,d)=>t.filter(u,f,d,r))),t.itemSort&&(s=s.sort((u,f)=>t.itemSort(u,f,r))),Y(s,u=>{const f=bd(t.callbacks,u);i.push(Ie(f,"labelColor",this,u)),a.push(Ie(f,"labelPointStyle",this,u)),o.push(Ie(f,"labelTextColor",this,u))}),this.labelColors=i,this.labelPointStyles=a,this.labelTextColors=o,this.dataPoints=s,s}update(t,n){const r=this.options.setContext(this.getContext()),i=this._active;let a,o=[];if(!i.length)this.opacity!==0&&(a={opacity:0});else{const s=Ir[r.position].call(this,i,this._eventPosition);o=this._createItems(r),this.title=this.getTitle(o,r),this.beforeBody=this.getBeforeBody(o,r),this.body=this.getBody(o,r),this.afterBody=this.getAfterBody(o,r),this.footer=this.getFooter(o,r);const l=this._size=gd(this,r),c=Object.assign({},s,l),u=md(this.chart,r,c),f=vd(r,c,u,this.chart);this.xAlign=u.xAlign,this.yAlign=u.yAlign,a={opacity:1,x:f.x,y:f.y,width:l.width,height:l.height,caretX:s.x,caretY:s.y}}this._tooltipItems=o,this.$context=void 0,a&&this._resolveAnimations().update(this,a),t&&r.external&&r.external.call(this,{chart:this.chart,tooltip:this,replay:n})}drawCaret(t,n,r,i){const a=this.getCaretPosition(t,r,i);n.lineTo(a.x1,a.y1),n.lineTo(a.x2,a.y2),n.lineTo(a.x3,a.y3)}getCaretPosition(t,n,r){const{xAlign:i,yAlign:a}=this,{caretSize:o,cornerRadius:s}=r,{topLeft:l,topRight:c,bottomLeft:u,bottomRight:f}=zr(s),{x:d,y:h}=t,{width:p,height:m}=n;let g,v,y,b,_,x;return a==="center"?(_=h+m/2,i==="left"?(g=d,v=g-o,b=_+o,x=_-o):(g=d+p,v=g+o,b=_-o,x=_+o),y=g):(i==="left"?v=d+Math.max(l,u)+o:i==="right"?v=d+p-Math.max(c,f)-o:v=this.caretX,a==="top"?(b=h,_=b-o,g=v-o,y=v+o):(b=h+m,_=b+o,g=v+o,y=v-o),x=b),{x1:g,x2:v,x3:y,y1:b,y2:_,y3:x}}drawTitle(t,n,r){const i=this.title,a=i.length;let o,s,l;if(a){const c=Vo(r.rtl,this.x,this.width);for(t.x=Li(this,r.titleAlign,r),n.textAlign=c.textAlign(r.titleAlign),n.textBaseline="middle",o=pt(r.titleFont),s=r.titleSpacing,n.fillStyle=r.titleColor,n.font=o.string,l=0;l<a;++l)n.fillText(i[l],c.x(t.x),t.y+o.lineHeight/2),t.y+=o.lineHeight+s,l+1===a&&(t.y+=r.titleMarginBottom-s)}}_drawColorBox(t,n,r,i,a){const o=this.labelColors[r],s=this.labelPointStyles[r],{boxHeight:l,boxWidth:c}=a,u=pt(a.bodyFont),f=Li(this,"left",a),d=i.x(f),h=l<u.lineHeight?(u.lineHeight-l)/2:0,p=n.y+h;if(a.usePointStyle){const m={radius:Math.min(c,l)/2,pointStyle:s.pointStyle,rotation:s.rotation,borderWidth:1},g=i.leftForLtr(d,c)+c/2,v=p+l/2;t.strokeStyle=a.multiKeyBackground,t.fillStyle=a.multiKeyBackground,jl(t,m,g,v),t.strokeStyle=o.borderColor,t.fillStyle=o.backgroundColor,jl(t,m,g,v)}else{t.lineWidth=$(o.borderWidth)?Math.max(...Object.values(o.borderWidth)):o.borderWidth||1,t.strokeStyle=o.borderColor,t.setLineDash(o.borderDash||[]),t.lineDashOffset=o.borderDashOffset||0;const m=i.leftForLtr(d,c),g=i.leftForLtr(i.xPlus(d,1),c-2),v=zr(o.borderRadius);Object.values(v).some(y=>y!==0)?(t.beginPath(),t.fillStyle=a.multiKeyBackground,Rl(t,{x:m,y:p,w:c,h:l,radius:v}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),Rl(t,{x:g,y:p+1,w:c-2,h:l-2,radius:v}),t.fill()):(t.fillStyle=a.multiKeyBackground,t.fillRect(m,p,c,l),t.strokeRect(m,p,c,l),t.fillStyle=o.backgroundColor,t.fillRect(g,p+1,c-2,l-2))}t.fillStyle=this.labelTextColors[r]}drawBody(t,n,r){const{body:i}=this,{bodySpacing:a,bodyAlign:o,displayColors:s,boxHeight:l,boxWidth:c,boxPadding:u}=r,f=pt(r.bodyFont);let d=f.lineHeight,h=0;const p=Vo(r.rtl,this.x,this.width),m=function(M){n.fillText(M,p.x(t.x+h),t.y+d/2),t.y+=d+a},g=p.textAlign(o);let v,y,b,_,x,S,O;for(n.textAlign=o,n.textBaseline="middle",n.font=f.string,t.x=Li(this,g,r),n.fillStyle=r.bodyColor,Y(this.beforeBody,m),h=s&&g!=="right"?o==="center"?c/2+u:c+2+u:0,_=0,S=i.length;_<S;++_){for(v=i[_],y=this.labelTextColors[_],n.fillStyle=y,Y(v.before,m),b=v.lines,s&&b.length&&(this._drawColorBox(n,t,_,p,r),d=Math.max(f.lineHeight,l)),x=0,O=b.length;x<O;++x)m(b[x]),d=f.lineHeight;Y(v.after,m)}h=0,d=f.lineHeight,Y(this.afterBody,m),t.y-=a}drawFooter(t,n,r){const i=this.footer,a=i.length;let o,s;if(a){const l=Vo(r.rtl,this.x,this.width);for(t.x=Li(this,r.footerAlign,r),t.y+=r.footerMarginTop,n.textAlign=l.textAlign(r.footerAlign),n.textBaseline="middle",o=pt(r.footerFont),n.fillStyle=r.footerColor,n.font=o.string,s=0;s<a;++s)n.fillText(i[s],l.x(t.x),t.y+o.lineHeight/2),t.y+=o.lineHeight+r.footerSpacing}}drawBackground(t,n,r,i){const{xAlign:a,yAlign:o}=this,{x:s,y:l}=t,{width:c,height:u}=r,{topLeft:f,topRight:d,bottomLeft:h,bottomRight:p}=zr(i.cornerRadius);n.fillStyle=i.backgroundColor,n.strokeStyle=i.borderColor,n.lineWidth=i.borderWidth,n.beginPath(),n.moveTo(s+f,l),o==="top"&&this.drawCaret(t,n,r,i),n.lineTo(s+c-d,l),n.quadraticCurveTo(s+c,l,s+c,l+d),o==="center"&&a==="right"&&this.drawCaret(t,n,r,i),n.lineTo(s+c,l+u-p),n.quadraticCurveTo(s+c,l+u,s+c-p,l+u),o==="bottom"&&this.drawCaret(t,n,r,i),n.lineTo(s+h,l+u),n.quadraticCurveTo(s,l+u,s,l+u-h),o==="center"&&a==="left"&&this.drawCaret(t,n,r,i),n.lineTo(s,l+f),n.quadraticCurveTo(s,l,s+f,l),n.closePath(),n.fill(),i.borderWidth>0&&n.stroke()}_updateAnimationTarget(t){const n=this.chart,r=this.$animations,i=r&&r.x,a=r&&r.y;if(i||a){const o=Ir[t.position].call(this,this._active,this._eventPosition);if(!o)return;const s=this._size=gd(this,t),l=Object.assign({},o,this._size),c=md(n,t,l),u=vd(t,l,c,n);(i._to!==u.x||a._to!==u.y)&&(this.xAlign=c.xAlign,this.yAlign=c.yAlign,this.width=s.width,this.height=s.height,this.caretX=o.x,this.caretY=o.y,this._resolveAnimations().update(this,u))}}_willRender(){return!!this.opacity}draw(t){const n=this.options.setContext(this.getContext());let r=this.opacity;if(!r)return;this._updateAnimationTarget(n);const i={width:this.width,height:this.height},a={x:this.x,y:this.y};r=Math.abs(r)<.001?0:r;const o=Gt(n.padding),s=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&s&&(t.save(),t.globalAlpha=r,this.drawBackground(a,t,i,n),G_(t,n.textDirection),a.y+=o.top,this.drawTitle(a,t,n),this.drawBody(a,t,n),this.drawFooter(a,t,n),Z_(t,n.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,n){const r=this._active,i=t.map(({datasetIndex:s,index:l})=>{const c=this.chart.getDatasetMeta(s);if(!c)throw new Error("Cannot find a dataset at index "+s);return{datasetIndex:s,element:c.data[l],index:l}}),a=!sa(r,i),o=this._positionChanged(i,n);(a||o)&&(this._active=i,this._eventPosition=n,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,n,r=!0){if(n&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const i=this.options,a=this._active||[],o=this._getActiveElements(t,a,n,r),s=this._positionChanged(o,t),l=n||!sa(o,a)||s;return l&&(this._active=o,(i.enabled||i.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,n))),l}_getActiveElements(t,n,r,i){const a=this.options;if(t.type==="mouseout")return[];if(!i)return n.filter(s=>this.chart.data.datasets[s.datasetIndex]&&this.chart.getDatasetMeta(s.datasetIndex).controller.getParsed(s.index)!==void 0);const o=this.chart.getElementsAtEventForMode(t,a.mode,a,r);return a.reverse&&o.reverse(),o}_positionChanged(t,n){const{caretX:r,caretY:i,options:a}=this,o=Ir[a.position].call(this,t,n);return o!==!1&&(r!==o.x||i!==o.y)}};var rL={id:"tooltip",_element:xd,positioners:Ir,afterInit(e,t,n){n&&(e.tooltip=new xd({chart:e,options:n}))},beforeUpdate(e,t,n){e.tooltip&&e.tooltip.initialize(n)},reset(e,t,n){e.tooltip&&e.tooltip.initialize(n)},afterDraw(e){const t=e.tooltip;if(t&&t._willRender()){const n={tooltip:t};if(e.notifyPlugins("beforeTooltipDraw",{...n,cancelable:!0})===!1)return;t.draw(e.ctx),e.notifyPlugins("afterTooltipDraw",n)}},afterEvent(e,t){if(e.tooltip){const n=t.replay;e.tooltip.handleEvent(t.event,n,t.inChartArea)&&(t.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(e,t)=>t.bodyFont.size,boxWidth:(e,t)=>t.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:fv},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:e=>e!=="filter"&&e!=="itemSort"&&e!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};const yS=(e,t,n,r)=>(typeof t=="string"?(n=e.push(t)-1,r.unshift({index:n,label:t})):isNaN(t)&&(n=null),n);function bS(e,t,n,r){const i=e.indexOf(t);if(i===-1)return yS(e,t,n,r);const a=e.lastIndexOf(t);return i!==a?n:i}const xS=(e,t)=>e===null?null:We(Math.round(e),0,t);function _d(e){const t=this.getLabels();return e>=0&&e<t.length?t[e]:e}class iL extends or{static id="category";static defaults={ticks:{callback:_d}};constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const n=this._addedLabels;if(n.length){const r=this.getLabels();for(const{index:i,label:a}of n)r[i]===a&&r.splice(i,1);this._addedLabels=[]}super.init(t)}parse(t,n){if(H(t))return null;const r=this.getLabels();return n=isFinite(n)&&r[n]===t?n:bS(r,t,V(n,t),this._addedLabels),xS(n,r.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let{min:r,max:i}=this.getMinMax(!0);this.options.bounds==="ticks"&&(t||(r=0),n||(i=this.getLabels().length-1)),this.min=r,this.max=i}buildTicks(){const t=this.min,n=this.max,r=this.options.offset,i=[];let a=this.getLabels();a=t===0&&n===a.length-1?a:a.slice(t,n+1),this._valueRange=Math.max(a.length-(r?0:1),1),this._startValue=this.min-(r?.5:0);for(let o=t;o<=n;o++)i.push({value:o});return i}getLabelForValue(t){return _d.call(this,t)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(t){return typeof t!="number"&&(t=this.parse(t)),t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}}function _S(e,t){const n=[],{bounds:i,step:a,min:o,max:s,precision:l,count:c,maxTicks:u,maxDigits:f,includeBounds:d}=e,h=a||1,p=u-1,{min:m,max:g}=t,v=!H(o),y=!H(s),b=!H(c),_=(g-m)/(f+1);let x=xf((g-m)/p/h)*h,S,O,M,E;if(x<1e-14&&!v&&!y)return[{value:m},{value:g}];E=Math.ceil(g/x)-Math.floor(m/x),E>p&&(x=xf(E*x/p/h)*h),H(l)||(S=Math.pow(10,l),x=Math.ceil(x*S)/S),i==="ticks"?(O=Math.floor(m/x)*x,M=Math.ceil(g/x)*x):(O=m,M=g),v&&y&&a&&Ux((s-o)/a,x/1e3)?(E=Math.round(Math.min((s-o)/x,u)),x=(s-o)/E,O=o,M=s):b?(O=v?o:O,M=y?s:M,E=c-1,x=(M-O)/E):(E=(M-O)/x,Nr(E,Math.round(E),x/1e3)?E=Math.round(E):E=Math.ceil(E));const j=Math.max(_f(x),_f(O));S=Math.pow(10,H(l)?j:l),O=Math.round(O*S)/S,M=Math.round(M*S)/S;let D=0;for(v&&(d&&O!==o?(n.push({value:o}),O<o&&D++,Nr(Math.round((O+D*x)*S)/S,o,wd(o,_,e))&&D++):O<o&&D++);D<E;++D){const A=Math.round((O+D*x)*S)/S;if(y&&A>s)break;n.push({value:A})}return y&&d&&M!==s?n.length&&Nr(n[n.length-1].value,s,wd(s,_,e))?n[n.length-1].value=s:n.push({value:s}):(!y||M===s)&&n.push({value:M}),n}function wd(e,t,{horizontal:n,minRotation:r}){const i=ht(r),a=(n?Math.sin(i):Math.cos(i))||.001,o=.75*t*(""+e).length;return Math.min(t/a,o)}class wS extends or{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,n){return H(t)||(typeof t=="number"||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:n,maxDefined:r}=this.getUserBounds();let{min:i,max:a}=this;const o=l=>i=n?i:l,s=l=>a=r?a:l;if(t){const l=vt(i),c=vt(a);l<0&&c<0?s(0):l>0&&c>0&&o(0)}if(i===a){let l=a===0?1:Math.abs(a*.05);s(a+l),t||o(i-l)}this.min=i,this.max=a}getTickLimit(){const t=this.options.ticks;let{maxTicksLimit:n,stepSize:r}=t,i;return r?(i=Math.ceil(this.max/r)-Math.floor(this.min/r)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${r} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),n=n||11),n&&(i=Math.min(n,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,n=t.ticks;let r=this.getTickLimit();r=Math.max(2,r);const i={maxTicks:r,bounds:t.bounds,min:t.min,max:t.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==!1},a=this._range||this,o=_S(i,a);return t.bounds==="ticks"&&Vx(o,this,"value"),t.reverse?(o.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),o}configure(){const t=this.ticks;let n=this.min,r=this.max;if(super.configure(),this.options.offset&&t.length){const i=(r-n)/Math.max(t.length-1,1)/2;n-=i,r+=i}this._startValue=n,this._endValue=r,this._valueRange=r-n}getLabelForValue(t){return Ja(t,this.chart.options.locale,this.options.ticks.format)}}class aL extends wS{static id="linear";static defaults={ticks:{callback:Nm.formatters.numeric}};determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=Qe(t)?t:0,this.max=Qe(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),n=t?this.width:this.height,r=ht(this.options.ticks.minRotation),i=(t?Math.sin(r):Math.cos(r))||.001,a=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,a.lineHeight/i))}getPixelForValue(t){return t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}const no={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},je=Object.keys(no);function Sd(e,t){return e-t}function Od(e,t){if(H(t))return null;const n=e._adapter,{parser:r,round:i,isoWeekday:a}=e._parseOpts;let o=t;return typeof r=="function"&&(o=r(o)),Qe(o)||(o=typeof r=="string"?n.parse(o,r):n.parse(o)),o===null?null:(i&&(o=i==="week"&&(Hn(a)||a===!0)?n.startOf(o,"isoWeek",a):n.startOf(o,i)),+o)}function Pd(e,t,n,r){const i=je.length;for(let a=je.indexOf(e);a<i-1;++a){const o=no[je[a]],s=o.steps?o.steps:Number.MAX_SAFE_INTEGER;if(o.common&&Math.ceil((n-t)/(s*o.size))<=r)return je[a]}return je[i-1]}function SS(e,t,n,r,i){for(let a=je.length-1;a>=je.indexOf(n);a--){const o=je[a];if(no[o].common&&e._adapter.diff(i,r,o)>=t-1)return o}return je[n?je.indexOf(n):0]}function OS(e){for(let t=je.indexOf(e)+1,n=je.length;t<n;++t)if(no[je[t]].common)return je[t]}function Md(e,t,n){if(!n)e[t]=!0;else if(n.length){const{lo:r,hi:i}=Ic(n,t),a=n[r]>=t?n[r]:n[i];e[a]=!0}}function PS(e,t,n,r){const i=e._adapter,a=+i.startOf(t[0].value,r),o=t[t.length-1].value;let s,l;for(s=a;s<=o;s=+i.add(s,1,r))l=n[s],l>=0&&(t[l].major=!0);return t}function Ad(e,t,n){const r=[],i={},a=t.length;let o,s;for(o=0;o<a;++o)s=t[o],i[s]=o,r.push({value:s,major:!1});return a===0||!n?r:PS(e,r,i,n)}class kd extends or{static id="time";static defaults={bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",callback:!1,major:{enabled:!1}}};constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,n={}){const r=t.time||(t.time={}),i=this._adapter=new Rw._date(t.adapters.date);i.init(n),Lr(r.displayFormats,i.formats()),this._parseOpts={parser:r.parser,round:r.round,isoWeekday:r.isoWeekday},super.init(t),this._normalized=n.normalized}parse(t,n){return t===void 0?null:Od(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this.options,n=this._adapter,r=t.time.unit||"day";let{min:i,max:a,minDefined:o,maxDefined:s}=this.getUserBounds();function l(c){!o&&!isNaN(c.min)&&(i=Math.min(i,c.min)),!s&&!isNaN(c.max)&&(a=Math.max(a,c.max))}(!o||!s)&&(l(this._getLabelBounds()),(t.bounds!=="ticks"||t.ticks.source!=="labels")&&l(this.getMinMax(!1))),i=Qe(i)&&!isNaN(i)?i:+n.startOf(Date.now(),r),a=Qe(a)&&!isNaN(a)?a:+n.endOf(Date.now(),r)+1,this.min=Math.min(i,a-1),this.max=Math.max(i+1,a)}_getLabelBounds(){const t=this.getLabelTimestamps();let n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;return t.length&&(n=t[0],r=t[t.length-1]),{min:n,max:r}}buildTicks(){const t=this.options,n=t.time,r=t.ticks,i=r.source==="labels"?this.getLabelTimestamps():this._generate();t.bounds==="ticks"&&i.length&&(this.min=this._userMin||i[0],this.max=this._userMax||i[i.length-1]);const a=this.min,o=this.max,s=Zx(i,a,o);return this._unit=n.unit||(r.autoSkip?Pd(n.minUnit,this.min,this.max,this._getLabelCapacity(a)):SS(this,s.length,n.minUnit,this.min,this.max)),this._majorUnit=!r.major.enabled||this._unit==="year"?void 0:OS(this._unit),this.initOffsets(i),t.reverse&&s.reverse(),Ad(this,s,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(t=>+t.value))}initOffsets(t=[]){let n=0,r=0,i,a;this.options.offset&&t.length&&(i=this.getDecimalForValue(t[0]),t.length===1?n=1-i:n=(this.getDecimalForValue(t[1])-i)/2,a=this.getDecimalForValue(t[t.length-1]),t.length===1?r=a:r=(a-this.getDecimalForValue(t[t.length-2]))/2);const o=t.length<3?.5:.25;n=We(n,0,o),r=We(r,0,o),this._offsets={start:n,end:r,factor:1/(n+1+r)}}_generate(){const t=this._adapter,n=this.min,r=this.max,i=this.options,a=i.time,o=a.unit||Pd(a.minUnit,n,r,this._getLabelCapacity(n)),s=V(i.ticks.stepSize,1),l=o==="week"?a.isoWeekday:!1,c=Hn(l)||l===!0,u={};let f=n,d,h;if(c&&(f=+t.startOf(f,"isoWeek",l)),f=+t.startOf(f,c?"day":o),t.diff(r,n,o)>1e5*s)throw new Error(n+" and "+r+" are too far apart with stepSize of "+s+" "+o);const p=i.ticks.source==="data"&&this.getDataTimestamps();for(d=f,h=0;d<r;d=+t.add(d,s,o),h++)Md(u,d,p);return(d===r||i.bounds==="ticks"||h===1)&&Md(u,d,p),Object.keys(u).sort(Sd).map(m=>+m)}getLabelForValue(t){const n=this._adapter,r=this.options.time;return r.tooltipFormat?n.format(t,r.tooltipFormat):n.format(t,r.displayFormats.datetime)}format(t,n){const i=this.options.time.displayFormats,a=this._unit,o=n||i[a];return this._adapter.format(t,o)}_tickFormatFunction(t,n,r,i){const a=this.options,o=a.ticks.callback;if(o)return le(o,[t,n,r],this);const s=a.time.displayFormats,l=this._unit,c=this._majorUnit,u=l&&s[l],f=c&&s[c],d=r[n],h=c&&f&&d&&d.major;return this._adapter.format(t,i||(h?f:u))}generateTickLabels(t){let n,r,i;for(n=0,r=t.length;n<r;++n)i=t[n],i.label=this._tickFormatFunction(i.value,n,t)}getDecimalForValue(t){return t===null?NaN:(t-this.min)/(this.max-this.min)}getPixelForValue(t){const n=this._offsets,r=this.getDecimalForValue(t);return this.getPixelForDecimal((n.start+r)*n.factor)}getValueForPixel(t){const n=this._offsets,r=this.getDecimalForPixel(t)/n.factor-n.end;return this.min+r*(this.max-this.min)}_getLabelSize(t){const n=this.options.ticks,r=this.ctx.measureText(t).width,i=ht(this.isHorizontal()?n.maxRotation:n.minRotation),a=Math.cos(i),o=Math.sin(i),s=this._resolveTickFontOptions(0).size;return{w:r*a+s*o,h:r*o+s*a}}_getLabelCapacity(t){const n=this.options.time,r=n.displayFormats,i=r[n.unit]||r.millisecond,a=this._tickFormatFunction(t,0,Ad(this,[t],this._majorUnit),i),o=this._getLabelSize(a),s=Math.floor(this.isHorizontal()?this.width/o.w:this.height/o.h)-1;return s>0?s:1}getDataTimestamps(){let t=this._cache.data||[],n,r;if(t.length)return t;const i=this.getMatchingVisibleMetas();if(this._normalized&&i.length)return this._cache.data=i[0].controller.getAllParsedValues(this);for(n=0,r=i.length;n<r;++n)t=t.concat(i[n].controller.getAllParsedValues(this));return this._cache.data=this.normalize(t)}getLabelTimestamps(){const t=this._cache.labels||[];let n,r;if(t.length)return t;const i=this.getLabels();for(n=0,r=i.length;n<r;++n)t.push(Od(this,i[n]));return this._cache.labels=this._normalized?t:this.normalize(t)}normalize(t){return Tm(t.sort(Sd))}}function Ni(e,t,n){let r=0,i=e.length-1,a,o,s,l;n?(t>=e[r].pos&&t<=e[i].pos&&({lo:r,hi:i}=yn(e,"pos",t)),{pos:a,time:s}=e[r],{pos:o,time:l}=e[i]):(t>=e[r].time&&t<=e[i].time&&({lo:r,hi:i}=yn(e,"time",t)),{time:a,pos:s}=e[r],{time:o,pos:l}=e[i]);const c=o-a;return c?s+(l-s)*(t-a)/c:s}class oL extends kd{static id="timeseries";static defaults=kd.defaults;constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(t);this._minPos=Ni(n,this.min),this._tableRange=Ni(n,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:n,max:r}=this,i=[],a=[];let o,s,l,c,u;for(o=0,s=t.length;o<s;++o)c=t[o],c>=n&&c<=r&&i.push(c);if(i.length<2)return[{time:n,pos:0},{time:r,pos:1}];for(o=0,s=i.length;o<s;++o)u=i[o+1],l=i[o-1],c=i[o],Math.round((u+l)/2)!==c&&a.push({time:c,pos:o/(s-1)});return a}_generate(){const t=this.min,n=this.max;let r=super.getDataTimestamps();return(!r.includes(t)||!r.length)&&r.splice(0,0,t),(!r.includes(n)||r.length===1)&&r.push(n),r.sort((i,a)=>i-a)}_getTimestampsForTable(){let t=this._cache.all||[];if(t.length)return t;const n=this.getDataTimestamps(),r=this.getLabelTimestamps();return n.length&&r.length?t=this.normalize(n.concat(r)):t=n.length?n:r,t=this._cache.all=t,t}getDecimalForValue(t){return(Ni(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const n=this._offsets,r=this.getDecimalForPixel(t)/n.factor-n.end;return Ni(this._table,r*this._tableRange+this._minPos,!0)}}var MS=["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"];function dv(e){if(typeof e!="string")return!1;var t=MS;return t.includes(e)}var AS=["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"],kS=new Set(AS);function hv(e){return typeof e!="string"?!1:kS.has(e)}function pv(e){return typeof e=="string"&&e.startsWith("data-")}function Xn(e){if(typeof e!="object"||e===null)return{};var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(hv(n)||pv(n))&&(t[n]=e[n]);return t}function $c(e){if(e==null)return null;if(w.isValidElement(e)&&typeof e.props=="object"&&e.props!==null){var t=e.props;return Xn(t)}return typeof e=="object"&&!Array.isArray(e)?Xn(e):null}function Gn(e){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(hv(n)||pv(n)||dv(n))&&(t[n]=e[n]);return t}var CS=["children","width","height","viewBox","className","style","title","desc"];function zl(){return zl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},zl.apply(null,arguments)}function ES(e,t){if(e==null)return{};var n,r,i=DS(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function DS(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var TS=w.forwardRef((e,t)=>{var{children:n,width:r,height:i,viewBox:a,className:o,style:s,title:l,desc:c}=e,u=ES(e,CS),f=a||{width:r,height:i,x:0,y:0},d=Ze("recharts-surface",o);return w.createElement("svg",zl({},Gn(u),{className:d,width:r,height:i,style:s,viewBox:"".concat(f.x," ").concat(f.y," ").concat(f.width," ").concat(f.height),ref:t}),w.createElement("title",null,l),w.createElement("desc",null,c),n)}),IS=["children","className"];function $l(){return $l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},$l.apply(null,arguments)}function jS(e,t){if(e==null)return{};var n,r,i=RS(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function RS(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var ro=w.forwardRef((e,t)=>{var{children:n,className:r}=e,i=jS(e,IS),a=Ze("recharts-layer",r);return w.createElement("g",$l({className:a},Gn(i),{ref:t}),n)}),LS=w.createContext(null);function ie(e){return function(){return e}}const Wl=Math.PI,ql=2*Wl,gn=1e-6,NS=ql-gn;function gv(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function FS(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return gv;const n=10**t;return function(r){this._+=r[0];for(let i=1,a=r.length;i<a;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}class BS{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?gv:FS(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,i){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+i}`}bezierCurveTo(t,n,r,i,a,o){this._append`C${+t},${+n},${+r},${+i},${this._x1=+a},${this._y1=+o}`}arcTo(t,n,r,i,a){if(t=+t,n=+n,r=+r,i=+i,a=+a,a<0)throw new Error(`negative radius: ${a}`);let o=this._x1,s=this._y1,l=r-t,c=i-n,u=o-t,f=s-n,d=u*u+f*f;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(d>gn)if(!(Math.abs(f*l-c*u)>gn)||!a)this._append`L${this._x1=t},${this._y1=n}`;else{let h=r-o,p=i-s,m=l*l+c*c,g=h*h+p*p,v=Math.sqrt(m),y=Math.sqrt(d),b=a*Math.tan((Wl-Math.acos((m+d-g)/(2*v*y)))/2),_=b/y,x=b/v;Math.abs(_-1)>gn&&this._append`L${t+_*u},${n+_*f}`,this._append`A${a},${a},0,0,${+(f*h>u*p)},${this._x1=t+x*l},${this._y1=n+x*c}`}}arc(t,n,r,i,a,o){if(t=+t,n=+n,r=+r,o=!!o,r<0)throw new Error(`negative radius: ${r}`);let s=r*Math.cos(i),l=r*Math.sin(i),c=t+s,u=n+l,f=1^o,d=o?i-a:a-i;this._x1===null?this._append`M${c},${u}`:(Math.abs(this._x1-c)>gn||Math.abs(this._y1-u)>gn)&&this._append`L${c},${u}`,r&&(d<0&&(d=d%ql+ql),d>NS?this._append`A${r},${r},0,1,${f},${t-s},${n-l}A${r},${r},0,1,${f},${this._x1=c},${this._y1=u}`:d>gn&&this._append`A${r},${r},0,${+(d>=Wl)},${f},${this._x1=t+r*Math.cos(a)},${this._y1=n+r*Math.sin(a)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}function mv(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new BS(t)}function Wc(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function vv(e){this._context=e}vv.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);break}}};function io(e){return new vv(e)}function yv(e){return e[0]}function bv(e){return e[1]}function xv(e,t){var n=ie(!0),r=null,i=io,a=null,o=mv(s);e=typeof e=="function"?e:e===void 0?yv:ie(e),t=typeof t=="function"?t:t===void 0?bv:ie(t);function s(l){var c,u=(l=Wc(l)).length,f,d=!1,h;for(r==null&&(a=i(h=o())),c=0;c<=u;++c)!(c<u&&n(f=l[c],c,l))===d&&((d=!d)?a.lineStart():a.lineEnd()),d&&a.point(+e(f,c,l),+t(f,c,l));if(h)return a=null,h+""||null}return s.x=function(l){return arguments.length?(e=typeof l=="function"?l:ie(+l),s):e},s.y=function(l){return arguments.length?(t=typeof l=="function"?l:ie(+l),s):t},s.defined=function(l){return arguments.length?(n=typeof l=="function"?l:ie(!!l),s):n},s.curve=function(l){return arguments.length?(i=l,r!=null&&(a=i(r)),s):i},s.context=function(l){return arguments.length?(l==null?r=a=null:a=i(r=l),s):r},s}function Fi(e,t,n){var r=null,i=ie(!0),a=null,o=io,s=null,l=mv(c);e=typeof e=="function"?e:e===void 0?yv:ie(+e),t=typeof t=="function"?t:ie(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?bv:ie(+n);function c(f){var d,h,p,m=(f=Wc(f)).length,g,v=!1,y,b=new Array(m),_=new Array(m);for(a==null&&(s=o(y=l())),d=0;d<=m;++d){if(!(d<m&&i(g=f[d],d,f))===v)if(v=!v)h=d,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),p=d-1;p>=h;--p)s.point(b[p],_[p]);s.lineEnd(),s.areaEnd()}v&&(b[d]=+e(g,d,f),_[d]=+t(g,d,f),s.point(r?+r(g,d,f):b[d],n?+n(g,d,f):_[d]))}if(y)return s=null,y+""||null}function u(){return xv().defined(i).curve(o).context(a)}return c.x=function(f){return arguments.length?(e=typeof f=="function"?f:ie(+f),r=null,c):e},c.x0=function(f){return arguments.length?(e=typeof f=="function"?f:ie(+f),c):e},c.x1=function(f){return arguments.length?(r=f==null?null:typeof f=="function"?f:ie(+f),c):r},c.y=function(f){return arguments.length?(t=typeof f=="function"?f:ie(+f),n=null,c):t},c.y0=function(f){return arguments.length?(t=typeof f=="function"?f:ie(+f),c):t},c.y1=function(f){return arguments.length?(n=f==null?null:typeof f=="function"?f:ie(+f),c):n},c.lineX0=c.lineY0=function(){return u().x(e).y(t)},c.lineY1=function(){return u().x(e).y(n)},c.lineX1=function(){return u().x(r).y(t)},c.defined=function(f){return arguments.length?(i=typeof f=="function"?f:ie(!!f),c):i},c.curve=function(f){return arguments.length?(o=f,a!=null&&(s=o(a)),c):o},c.context=function(f){return arguments.length?(f==null?a=s=null:s=o(a=f),c):a},c}class _v{constructor(t,n){this._context=t,this._x=n}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(t,n){switch(t=+t,n=+n,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,n,t,n):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+n)/2,t,this._y0,t,n);break}}this._x0=t,this._y0=n}}function zS(e){return new _v(e,!0)}function $S(e){return new _v(e,!1)}function ha(){}function pa(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 wv(e){this._context=e}wv.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:pa(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(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:pa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function WS(e){return new wv(e)}function Sv(e){this._context=e}Sv.prototype={areaStart:ha,areaEnd:ha,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);break}}},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:pa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function qS(e){return new Sv(e)}function Ov(e){this._context=e}Ov.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:pa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function US(e){return new Ov(e)}function Pv(e){this._context=e}Pv.prototype={areaStart:ha,areaEnd:ha,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 VS(e){return new Pv(e)}function Cd(e){return e<0?-1:1}function Ed(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(Cd(a)+Cd(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function Dd(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function ts(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 ga(e){this._context=e}ga.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:ts(this,this._t0,Dd(this,this._t0));break}(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,ts(this,Dd(this,n=Ed(this,e,t)),n);break;default:ts(this,this._t0,n=Ed(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function Mv(e){this._context=new Av(e)}(Mv.prototype=Object.create(ga.prototype)).point=function(e,t){ga.prototype.point.call(this,t,e)};function Av(e){this._context=e}Av.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 HS(e){return new ga(e)}function KS(e){return new Mv(e)}function kv(e){this._context=e}kv.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=Td(e),i=Td(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 Td(e){var t,n=e.length-1,r,i=new Array(n),a=new Array(n),o=new 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 YS(e){return new kv(e)}function ao(e,t){this._context=e,this._t=t}ao.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)}break}}this._x=e,this._y=t}};function XS(e){return new ao(e,.5)}function GS(e){return new ao(e,0)}function ZS(e){return new ao(e,1)}function kn(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 Ul(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function QS(e,t){return e[t]}function JS(e){const t=[];return t.key=e,t}function eO(){var e=ie([]),t=Ul,n=kn,r=QS;function i(a){var o=Array.from(e.apply(this,arguments),JS),s,l=o.length,c=-1,u;for(const f of a)for(s=0,++c;s<l;++s)(o[s][c]=[0,+r(f,o[s].key,c,a)]).data=f;for(s=0,u=Wc(t(o));s<l;++s)o[u[s]].index=s;return n(o,u),o}return i.keys=function(a){return arguments.length?(e=typeof a=="function"?a:ie(Array.from(a)),i):e},i.value=function(a){return arguments.length?(r=typeof a=="function"?a:ie(+a),i):r},i.order=function(a){return arguments.length?(t=a==null?Ul:typeof a=="function"?a:ie(Array.from(a)),i):t},i.offset=function(a){return arguments.length?(n=a??kn,i):n},i}function tO(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}kn(e,t)}}function nO(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}kn(e,t)}}function rO(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,l=0,c=0;s<o;++s){for(var u=e[t[s]],f=u[r][1]||0,d=u[r-1][1]||0,h=(f-d)/2,p=0;p<s;++p){var m=e[t[p]],g=m[r][1]||0,v=m[r-1][1]||0;h+=g-v}l+=f,c+=h*f}i[r-1][1]+=i[r-1][0]=n,l&&(n-=c/l)}i[r-1][1]+=i[r-1][0]=n,kn(e,t)}}var ns={},rs={},Id;function iO(){return Id||(Id=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n==="__proto__"}e.isUnsafeProperty=t})(rs)),rs}var is={},jd;function Cv(){return jd||(jd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){switch(typeof n){case"number":case"symbol":return!1;case"string":return n.includes(".")||n.includes("[")||n.includes("]")}}e.isDeepKey=t})(is)),is}var as={},Rd;function qc(){return Rd||(Rd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return typeof n=="string"||typeof n=="symbol"?n:Object.is(n?.valueOf?.(),-0)?"-0":String(n)}e.toKey=t})(as)),as}var os={},ss={},Ld;function aO(){return Ld||(Ld=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){if(n==null)return"";if(typeof n=="string")return n;if(Array.isArray(n))return n.map(t).join(",");const r=String(n);return r==="0"&&Object.is(Number(n),-0)?"-0":r}e.toString=t})(ss)),ss}var Nd;function Uc(){return Nd||(Nd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=aO(),n=qc();function r(i){if(Array.isArray(i))return i.map(n.toKey);if(typeof i=="symbol")return[i];i=t.toString(i);const a=[],o=i.length;if(o===0)return a;let s=0,l="",c="",u=!1;for(i.charCodeAt(0)===46&&(a.push(""),s++);s<o;){const f=i[s];c?f==="\\"&&s+1<o?(s++,l+=i[s]):f===c?c="":l+=f:u?f==='"'||f==="'"?c=f:f==="]"?(u=!1,a.push(l),l=""):l+=f:f==="["?(u=!0,l&&(a.push(l),l="")):f==="."?l&&(a.push(l),l=""):l+=f,s++}return l&&a.push(l),a}e.toPath=r})(os)),os}var Fd;function Vc(){return Fd||(Fd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=iO(),n=Cv(),r=qc(),i=Uc();function a(s,l,c){if(s==null)return c;switch(typeof l){case"string":{if(t.isUnsafeProperty(l))return c;const u=s[l];return u===void 0?n.isDeepKey(l)?a(s,i.toPath(l),c):c:u}case"number":case"symbol":{typeof l=="number"&&(l=r.toKey(l));const u=s[l];return u===void 0?c:u}default:{if(Array.isArray(l))return o(s,l,c);if(Object.is(l?.valueOf(),-0)?l="-0":l=String(l),t.isUnsafeProperty(l))return c;const u=s[l];return u===void 0?c:u}}}function o(s,l,c){if(l.length===0)return c;let u=s;for(let f=0;f<l.length;f++){if(u==null||t.isUnsafeProperty(l[f]))return c;u=u[l[f]]}return u===void 0?c:u}e.get=a})(ns)),ns}var ls,Bd;function oO(){return Bd||(Bd=1,ls=Vc().get),ls}var sO=oO();const Hc=Qt(sO);var lO=4;function Ut(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:lO,n=10**t,r=Math.round(e*n)/n;return Object.is(r,-0)?0:r}function Pe(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.reduce((i,a,o)=>{var s=n[o-1];return typeof s=="string"?i+s+a:s!==void 0?i+Ut(s)+a:i+a},"")}var Mt=e=>e===0?0:e>0?1:-1,sr=e=>typeof e=="number"&&e!=+e,Vr=e=>typeof e=="string"&&e.indexOf("%")===e.length-1,z=e=>(typeof e=="number"||e instanceof Number)&&!sr(e),Cn=e=>z(e)||typeof e=="string",cO=0,Vl=e=>{var t=++cO;return"".concat(e||"").concat(t)},Zn=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!z(t)&&typeof t!="string")return r;var a;if(Vr(t)){if(n==null)return r;var o=t.indexOf("%");a=n*parseFloat(t.slice(0,o))/100}else a=+t;return sr(a)&&(a=r),i&&n!=null&&a>n&&(a=n),a},Ev=e=>{if(!Array.isArray(e))return!1;for(var t=e.length,n={},r=0;r<t;r++)if(!n[String(e[r])])n[String(e[r])]=!0;else return!0;return!1};function Bi(e,t,n){return z(e)&&z(t)?Ut(e+n*(t-e)):t}function uO(e,t,n){if(!(!e||!e.length))return e.find(r=>r&&(typeof t=="function"?t(r):Hc(r,t))===n)}var ma=e=>e===null||typeof e>"u",Kc=e=>ma(e)?e:"".concat(e.charAt(0).toUpperCase()).concat(e.slice(1));function at(e){return e!=null}function lr(){}var Dv=e=>"radius"in e&&"startAngle"in e&&"endAngle"in e,fO=(e,t)=>{if(!e||typeof e=="function"||typeof e=="boolean")return null;var n=e;if(w.isValidElement(e)&&(n=e.props),typeof n!="object"&&typeof n!="function")return null;var r={};return Object.keys(n).forEach(i=>{dv(i)&&(r[i]=(a=>n[i](n,a)))}),r};function zd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function dO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?zd(Object(n),!0).forEach(function(r){hO(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zd(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function hO(e,t,n){return(t=pO(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pO(e){var t=gO(e,"string");return typeof t=="symbol"?t:t+""}function gO(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function si(e,t){var n=dO({},e),r=t,i=Object.keys(t),a=i.reduce((o,s)=>(o[s]===void 0&&r[s]!==void 0&&(o[s]=r[s]),o),n);return a}var cs={},us={},$d;function mO(){return $d||($d=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){const i=new Map;for(let a=0;a<n.length;a++){const o=n[a],s=r(o,a,n);i.has(s)||i.set(s,o)}return Array.from(i.values())}e.uniqBy=t})(us)),us}var fs={},Wd;function vO(){return Wd||(Wd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){return function(...i){return n.apply(this,i.slice(0,r))}}e.ary=t})(fs)),fs}var ds={},qd;function Yc(){return qd||(qd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n}e.identity=t})(ds)),ds}var hs={},ps={},gs={},Ud;function yO(){return Ud||(Ud=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return Number.isSafeInteger(n)&&n>=0}e.isLength=t})(gs)),gs}var Vd;function Tv(){return Vd||(Vd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=yO();function n(r){return r!=null&&typeof r!="function"&&t.isLength(r.length)}e.isArrayLike=n})(ps)),ps}var ms={},Hd;function bO(){return Hd||(Hd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return typeof n=="object"&&n!==null}e.isObjectLike=t})(ms)),ms}var Kd;function xO(){return Kd||(Kd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Tv(),n=bO();function r(i){return n.isObjectLike(i)&&t.isArrayLike(i)}e.isArrayLikeObject=r})(hs)),hs}var vs={},ys={},Yd;function _O(){return Yd||(Yd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Vc();function n(r){return function(i){return t.get(i,r)}}e.property=n})(ys)),ys}var bs={},xs={},_s={},ws={},Xd;function Iv(){return Xd||(Xd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n!==null&&(typeof n=="object"||typeof n=="function")}e.isObject=t})(ws)),ws}var Ss={},Gd;function jv(){return Gd||(Gd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n==null||typeof n!="object"&&typeof n!="function"}e.isPrimitive=t})(Ss)),Ss}var Os={},Zd;function Rv(){return Zd||(Zd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){return n===r||Number.isNaN(n)&&Number.isNaN(r)}e.isEqualsSameValueZero=t})(Os)),Os}var Qd;function wO(){return Qd||(Qd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Iv(),n=jv(),r=Rv();function i(u,f,d){return typeof d!="function"?i(u,f,()=>{}):a(u,f,function h(p,m,g,v,y,b){const _=d(p,m,g,v,y,b);return _!==void 0?!!_:a(p,m,h,b)},new Map)}function a(u,f,d,h){if(f===u)return!0;switch(typeof f){case"object":return o(u,f,d,h);case"function":return Object.keys(f).length>0?a(u,{...f},d,h):r.isEqualsSameValueZero(u,f);default:return t.isObject(u)?typeof f=="string"?f==="":!0:r.isEqualsSameValueZero(u,f)}}function o(u,f,d,h){if(f==null)return!0;if(Array.isArray(f))return l(u,f,d,h);if(f instanceof Map)return s(u,f,d,h);if(f instanceof Set)return c(u,f,d,h);const p=Object.keys(f);if(u==null||n.isPrimitive(u))return p.length===0;if(p.length===0)return!0;if(h?.has(f))return h.get(f)===u;h?.set(f,u);try{for(let m=0;m<p.length;m++){const g=p[m];if(!n.isPrimitive(u)&&!(g in u)||f[g]===void 0&&u[g]!==void 0||f[g]===null&&u[g]!==null||!d(u[g],f[g],g,u,f,h))return!1}return!0}finally{h?.delete(f)}}function s(u,f,d,h){if(f.size===0)return!0;if(!(u instanceof Map))return!1;for(const[p,m]of f.entries()){const g=u.get(p);if(d(g,m,p,u,f,h)===!1)return!1}return!0}function l(u,f,d,h){if(f.length===0)return!0;if(!Array.isArray(u))return!1;const p=new Set;for(let m=0;m<f.length;m++){const g=f[m];let v=!1;for(let y=0;y<u.length;y++){if(p.has(y))continue;const b=u[y];let _=!1;if(d(b,g,m,u,f,h)&&(_=!0),_){p.add(y),v=!0;break}}if(!v)return!1}return!0}function c(u,f,d,h){return f.size===0?!0:u instanceof Set?l([...u],[...f],d,h):!1}e.isMatchWith=i,e.isSetMatch=c})(_s)),_s}var Jd;function Lv(){return Jd||(Jd=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=wO();function n(r,i){return t.isMatchWith(r,i,()=>{})}e.isMatch=n})(xs)),xs}var Ps={},Ms={},As={},eh;function SO(){return eh||(eh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return Object.getOwnPropertySymbols(n).filter(r=>Object.prototype.propertyIsEnumerable.call(n,r))}e.getSymbols=t})(As)),As}var ks={},th;function Xc(){return th||(th=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n==null?n===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(n)}e.getTag=t})(ks)),ks}var Cs={},nh;function Nv(){return nh||(nh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t="[object RegExp]",n="[object String]",r="[object Number]",i="[object Boolean]",a="[object Arguments]",o="[object Symbol]",s="[object Date]",l="[object Map]",c="[object Set]",u="[object Array]",f="[object Function]",d="[object ArrayBuffer]",h="[object Object]",p="[object Error]",m="[object DataView]",g="[object Uint8Array]",v="[object Uint8ClampedArray]",y="[object Uint16Array]",b="[object Uint32Array]",_="[object BigUint64Array]",x="[object Int8Array]",S="[object Int16Array]",O="[object Int32Array]",M="[object BigInt64Array]",E="[object Float32Array]",j="[object Float64Array]";e.argumentsTag=a,e.arrayBufferTag=d,e.arrayTag=u,e.bigInt64ArrayTag=M,e.bigUint64ArrayTag=_,e.booleanTag=i,e.dataViewTag=m,e.dateTag=s,e.errorTag=p,e.float32ArrayTag=E,e.float64ArrayTag=j,e.functionTag=f,e.int16ArrayTag=S,e.int32ArrayTag=O,e.int8ArrayTag=x,e.mapTag=l,e.numberTag=r,e.objectTag=h,e.regexpTag=t,e.setTag=c,e.stringTag=n,e.symbolTag=o,e.uint16ArrayTag=y,e.uint32ArrayTag=b,e.uint8ArrayTag=g,e.uint8ClampedArrayTag=v})(Cs)),Cs}var Es={},rh;function OO(){return rh||(rh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return ArrayBuffer.isView(n)&&!(n instanceof DataView)}e.isTypedArray=t})(Es)),Es}var ih;function Fv(){return ih||(ih=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=SO(),n=Xc(),r=Nv(),i=jv(),a=OO();function o(u,f){return s(u,void 0,u,new Map,f)}function s(u,f,d,h=new Map,p=void 0){const m=p?.(u,f,d,h);if(m!==void 0)return m;if(i.isPrimitive(u))return u;if(h.has(u))return h.get(u);if(Array.isArray(u)){const g=new Array(u.length);h.set(u,g);for(let v=0;v<u.length;v++)g[v]=s(u[v],v,d,h,p);return Object.hasOwn(u,"index")&&(g.index=u.index),Object.hasOwn(u,"input")&&(g.input=u.input),g}if(u instanceof Date)return new Date(u.getTime());if(u instanceof RegExp){const g=new RegExp(u.source,u.flags);return g.lastIndex=u.lastIndex,g}if(u instanceof Map){const g=new Map;h.set(u,g);for(const[v,y]of u)g.set(v,s(y,v,d,h,p));return g}if(u instanceof Set){const g=new Set;h.set(u,g);for(const v of u)g.add(s(v,void 0,d,h,p));return g}if(typeof Buffer<"u"&&Buffer.isBuffer(u))return u.subarray();if(a.isTypedArray(u)){const g=new(Object.getPrototypeOf(u)).constructor(u.length);h.set(u,g);for(let v=0;v<u.length;v++)g[v]=s(u[v],v,d,h,p);return g}if(u instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&u instanceof SharedArrayBuffer)return u.slice(0);if(u instanceof DataView){const g=new DataView(u.buffer.slice(0),u.byteOffset,u.byteLength);return h.set(u,g),l(g,u,d,h,p),g}if(typeof File<"u"&&u instanceof File){const g=new File([u],u.name,{type:u.type});return h.set(u,g),l(g,u,d,h,p),g}if(typeof Blob<"u"&&u instanceof Blob){const g=new Blob([u],{type:u.type});return h.set(u,g),l(g,u,d,h,p),g}if(u instanceof Error){const g=structuredClone(u);return h.set(u,g),g.message=u.message,g.name=u.name,g.stack=u.stack,g.cause=u.cause,g.constructor=u.constructor,l(g,u,d,h,p),g}if(u instanceof Boolean){const g=new Boolean(u.valueOf());return h.set(u,g),l(g,u,d,h,p),g}if(u instanceof Number){const g=new Number(u.valueOf());return h.set(u,g),l(g,u,d,h,p),g}if(u instanceof String){const g=new String(u.valueOf());return h.set(u,g),l(g,u,d,h,p),g}if(typeof u=="object"&&c(u)){const g=Object.create(Object.getPrototypeOf(u));return h.set(u,g),l(g,u,d,h,p),g}return u}function l(u,f,d=u,h,p){const m=[...Object.keys(f),...t.getSymbols(f)];for(let g=0;g<m.length;g++){const v=m[g],y=Object.getOwnPropertyDescriptor(u,v);(y==null||y.writable)&&(u[v]=s(f[v],v,d,h,p))}}function c(u){switch(n.getTag(u)){case r.argumentsTag:case r.arrayTag:case r.arrayBufferTag:case r.dataViewTag:case r.booleanTag:case r.dateTag:case r.float32ArrayTag:case r.float64ArrayTag:case r.int8ArrayTag:case r.int16ArrayTag:case r.int32ArrayTag:case r.mapTag:case r.numberTag:case r.objectTag:case r.regexpTag:case r.setTag:case r.stringTag:case r.symbolTag:case r.uint8ArrayTag:case r.uint8ClampedArrayTag:case r.uint16ArrayTag:case r.uint32ArrayTag:return!0;default:return!1}}e.cloneDeepWith=o,e.cloneDeepWithImpl=s,e.copyProperties=l})(Ms)),Ms}var ah;function PO(){return ah||(ah=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Fv();function n(r){return t.cloneDeepWithImpl(r,void 0,r,new Map,void 0)}e.cloneDeep=n})(Ps)),Ps}var oh;function MO(){return oh||(oh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Lv(),n=PO();function r(i){return i=n.cloneDeep(i),a=>t.isMatch(a,i)}e.matches=r})(bs)),bs}var Ds={},Ts={},Is={},sh;function AO(){return sh||(sh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Fv(),n=Xc(),r=Nv();function i(a,o){return t.cloneDeepWith(a,(s,l,c,u)=>{const f=o?.(s,l,c,u);if(f!==void 0)return f;if(typeof a=="object"){if(n.getTag(a)===r.objectTag&&typeof a.constructor!="function"){const d={};return u.set(a,d),t.copyProperties(d,a,c,u),d}switch(Object.prototype.toString.call(a)){case r.numberTag:case r.stringTag:case r.booleanTag:{const d=new a.constructor(a?.valueOf());return t.copyProperties(d,a),d}case r.argumentsTag:{const d={};return t.copyProperties(d,a),d.length=a.length,d[Symbol.iterator]=a[Symbol.iterator],d}default:return}}})}e.cloneDeepWith=i})(Is)),Is}var lh;function kO(){return lh||(lh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=AO();function n(r){return t.cloneDeepWith(r)}e.cloneDeep=n})(Ts)),Ts}var js={},Rs={},ch;function Bv(){return ch||(ch=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=/^(?:0|[1-9]\d*)$/;function n(r,i=Number.MAX_SAFE_INTEGER){switch(typeof r){case"number":return Number.isInteger(r)&&r>=0&&r<i;case"symbol":return!1;case"string":return t.test(r)}}e.isIndex=n})(Rs)),Rs}var Ls={},uh;function CO(){return uh||(uh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Xc();function n(r){return r!==null&&typeof r=="object"&&t.getTag(r)==="[object Arguments]"}e.isArguments=n})(Ls)),Ls}var fh;function EO(){return fh||(fh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Cv(),n=Bv(),r=CO(),i=Uc();function a(o,s){let l;if(Array.isArray(s)?l=s:typeof s=="string"&&t.isDeepKey(s)&&o?.[s]==null?l=i.toPath(s):l=[s],l.length===0)return!1;let c=o;for(let u=0;u<l.length;u++){const f=l[u];if((c==null||!Object.hasOwn(c,f))&&!((Array.isArray(c)||r.isArguments(c))&&n.isIndex(f)&&f<c.length))return!1;c=c[f]}return!0}e.has=a})(js)),js}var dh;function DO(){return dh||(dh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Lv(),n=qc(),r=kO(),i=Vc(),a=EO();function o(s,l){switch(typeof s){case"object":{Object.is(s?.valueOf(),-0)&&(s="-0");break}case"number":{s=n.toKey(s);break}}return l=r.cloneDeep(l),function(c){const u=i.get(c,s);return u===void 0?a.has(c,s):l===void 0?u===void 0:t.isMatch(u,l)}}e.matchesProperty=o})(Ds)),Ds}var hh;function Gc(){return hh||(hh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Yc(),n=_O(),r=MO(),i=DO();function a(o){if(o==null)return t.identity;switch(typeof o){case"function":return o;case"object":return Array.isArray(o)&&o.length===2?i.matchesProperty(o[0],o[1]):r.matches(o);case"string":case"symbol":case"number":return n.property(o)}}e.iteratee=a})(vs)),vs}var ph;function TO(){return ph||(ph=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=mO(),n=vO(),r=Yc(),i=xO(),a=Gc();function o(s,l=r.identity){return i.isArrayLikeObject(s)?t.uniqBy(Array.from(s),n.ary(a.iteratee(l),1)):[]}e.uniqBy=o})(cs)),cs}var Ns,gh;function IO(){return gh||(gh=1,Ns=TO().uniqBy),Ns}var jO=IO();const mh=Qt(jO);function RO(e,t,n){return t===!0?mh(e,n):typeof t=="function"?mh(e,t):e}var Fs={exports:{}},Bs={},zs={exports:{}},$s={};var vh;function LO(){if(vh)return $s;vh=1;var e=kc();function t(f,d){return f===d&&(f!==0||1/f===1/d)||f!==f&&d!==d}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,i=e.useEffect,a=e.useLayoutEffect,o=e.useDebugValue;function s(f,d){var h=d(),p=r({inst:{value:h,getSnapshot:d}}),m=p[0].inst,g=p[1];return a(function(){m.value=h,m.getSnapshot=d,l(m)&&g({inst:m})},[f,h,d]),i(function(){return l(m)&&g({inst:m}),f(function(){l(m)&&g({inst:m})})},[f]),o(h),h}function l(f){var d=f.getSnapshot;f=f.value;try{var h=d();return!n(f,h)}catch{return!0}}function c(f,d){return d()}var u=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?c:s;return $s.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:u,$s}var yh;function NO(){return yh||(yh=1,zs.exports=LO()),zs.exports}var bh;function FO(){if(bh)return Bs;bh=1;var e=kc(),t=NO();function n(c,u){return c===u&&(c!==0||1/c===1/u)||c!==c&&u!==u}var r=typeof Object.is=="function"?Object.is:n,i=t.useSyncExternalStore,a=e.useRef,o=e.useEffect,s=e.useMemo,l=e.useDebugValue;return Bs.useSyncExternalStoreWithSelector=function(c,u,f,d,h){var p=a(null);if(p.current===null){var m={hasValue:!1,value:null};p.current=m}else m=p.current;p=s(function(){function v(S){if(!y){if(y=!0,b=S,S=d(S),h!==void 0&&m.hasValue){var O=m.value;if(h(O,S))return _=O}return _=S}if(O=_,r(b,S))return O;var M=d(S);return h!==void 0&&h(O,M)?(b=S,O):(b=S,_=M)}var y=!1,b,_,x=f===void 0?null:f;return[function(){return v(u())},x===null?void 0:function(){return v(x())}]},[u,f,d,h]);var g=i(c,p[0],p[1]);return o(function(){m.hasValue=!0,m.value=g},[g]),l(g),g},Bs}var xh;function BO(){return xh||(xh=1,Fs.exports=FO()),Fs.exports}var zO=BO(),Zc=w.createContext(null),$O=e=>e,Ke=()=>{var e=w.useContext(Zc);return e?e.store.dispatch:$O},ra=()=>{},WO=()=>ra,qO=(e,t)=>e===t;function K(e){var t=w.useContext(Zc),n=w.useMemo(()=>t?r=>{if(r!=null)return e(r)}:ra,[t,e]);return zO.useSyncExternalStoreWithSelector(t?t.subscription.addNestedSub:WO,t?t.store.getState:ra,t?t.store.getState:ra,n,qO)}function UO(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function VO(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function HO(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(n=>typeof n=="function")){const n=e.map(r=>typeof r=="function"?`function ${r.name||"unnamed"}()`:typeof r).join(", ");throw new TypeError(`${t}[${n}]`)}}var _h=e=>Array.isArray(e)?e:[e];function KO(e){const t=Array.isArray(e[0])?e[0]:e;return HO(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function YO(e,t){const n=[],{length:r}=e;for(let i=0;i<r;i++)n.push(e[i].apply(null,t));return n}var XO=class{constructor(e){this.value=e}deref(){return this.value}},GO=typeof WeakRef<"u"?WeakRef:XO,ZO=0,wh=1;function zi(){return{s:ZO,v:void 0,o:null,p:null}}function zv(e,t={}){let n=zi();const{resultEqualityCheck:r}=t;let i,a=0;function o(){let s=n;const{length:l}=arguments;for(let f=0,d=l;f<d;f++){const h=arguments[f];if(typeof h=="function"||typeof h=="object"&&h!==null){let p=s.o;p===null&&(s.o=p=new WeakMap);const m=p.get(h);m===void 0?(s=zi(),p.set(h,s)):s=m}else{let p=s.p;p===null&&(s.p=p=new Map);const m=p.get(h);m===void 0?(s=zi(),p.set(h,s)):s=m}}const c=s;let u;if(s.s===wh)u=s.v;else if(u=e.apply(null,arguments),a++,r){const f=i?.deref?.()??i;f!=null&&r(f,u)&&(u=f,a!==0&&a--),i=typeof u=="object"&&u!==null||typeof u=="function"?new GO(u):u}return c.s=wh,c.v=u,u}return o.clearCache=()=>{n=zi(),o.resetResultsCount()},o.resultsCount=()=>a,o.resetResultsCount=()=>{a=0},o}function QO(e,...t){const n=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,r=(...i)=>{let a=0,o=0,s,l={},c=i.pop();typeof c=="object"&&(l=c,c=i.pop()),UO(c,`createSelector expects an output function after the inputs, but received: [${typeof c}]`);const u={...n,...l},{memoize:f,memoizeOptions:d=[],argsMemoize:h=zv,argsMemoizeOptions:p=[]}=u,m=_h(d),g=_h(p),v=KO(i),y=f(function(){return a++,c.apply(null,arguments)},...m),b=h(function(){o++;const x=YO(v,arguments);return s=y.apply(null,x),s},...g);return Object.assign(b,{resultFunc:c,memoizedResultFunc:y,dependencies:v,dependencyRecomputations:()=>o,resetDependencyRecomputations:()=>{o=0},lastResult:()=>s,recomputations:()=>a,resetRecomputations:()=>{a=0},memoize:f,argsMemoize:h})};return Object.assign(r,{withTypes:()=>r}),r}var P=QO(zv),JO=Object.assign((e,t=P)=>{VO(e,`createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);const n=Object.keys(e),r=n.map(a=>e[a]);return t(r,(...a)=>a.reduce((o,s,l)=>(o[n[l]]=s,o),{}))},{withTypes:()=>JO}),Ws={},qs={},Us={},Sh;function eP(){return Sh||(Sh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(r){return typeof r=="symbol"?1:r===null?2:r===void 0?3:r!==r?4:0}const n=(r,i,a)=>{if(r!==i){const o=t(r),s=t(i);if(o===s&&o===0){if(r<i)return a==="desc"?1:-1;if(r>i)return a==="desc"?-1:1}return a==="desc"?s-o:o-s}return 0};e.compareValues=n})(Us)),Us}var Vs={},Hs={},Oh;function $v(){return Oh||(Oh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return typeof n=="symbol"||n instanceof Symbol}e.isSymbol=t})(Hs)),Hs}var Ph;function tP(){return Ph||(Ph=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=$v(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(a,o){return Array.isArray(a)?!1:typeof a=="number"||typeof a=="boolean"||a==null||t.isSymbol(a)?!0:typeof a=="string"&&(r.test(a)||!n.test(a))||o!=null&&Object.hasOwn(o,a)}e.isKey=i})(Vs)),Vs}var Mh;function nP(){return Mh||(Mh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=eP(),n=tP(),r=Uc();function i(a,o,s,l){if(a==null)return[];s=l?void 0:s,Array.isArray(a)||(a=Object.values(a)),Array.isArray(o)||(o=o==null?[null]:[o]),o.length===0&&(o=[null]),Array.isArray(s)||(s=s==null?[]:[s]),s=s.map(h=>String(h));const c=(h,p)=>{let m=h;for(let g=0;g<p.length&&m!=null;++g)m=m[p[g]];return m},u=(h,p)=>p==null||h==null?p:typeof h=="object"&&"key"in h?Object.hasOwn(p,h.key)?p[h.key]:c(p,h.path):typeof h=="function"?h(p):Array.isArray(h)?c(p,h):typeof p=="object"?p[h]:p,f=o.map(h=>(Array.isArray(h)&&h.length===1&&(h=h[0]),h==null||typeof h=="function"||Array.isArray(h)||n.isKey(h)?h:{key:h,path:r.toPath(h)}));return a.map(h=>({original:h,criteria:f.map(p=>u(p,h))})).slice().sort((h,p)=>{for(let m=0;m<f.length;m++){const g=t.compareValues(h.criteria[m],p.criteria[m],s[m]);if(g!==0)return g}return 0}).map(h=>h.original)}e.orderBy=i})(qs)),qs}var Ks={},Ah;function rP(){return Ah||(Ah=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r=1){const i=[],a=Math.floor(r),o=(s,l)=>{for(let c=0;c<s.length;c++){const u=s[c];Array.isArray(u)&&l<a?o(u,l+1):i.push(u)}};return o(n,0),i}e.flatten=t})(Ks)),Ks}var Ys={},kh;function Wv(){return kh||(kh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Bv(),n=Tv(),r=Iv(),i=Rv();function a(o,s,l){return r.isObject(l)&&(typeof s=="number"&&n.isArrayLike(l)&&t.isIndex(s)&&s<l.length||typeof s=="string"&&s in l)?i.isEqualsSameValueZero(l[s],o):!1}e.isIterateeCall=a})(Ys)),Ys}var Ch;function iP(){return Ch||(Ch=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=nP(),n=rP(),r=Wv();function i(a,...o){const s=o.length;return s>1&&r.isIterateeCall(a,o[0],o[1])?o=[]:s>2&&r.isIterateeCall(o[0],o[1],o[2])&&(o=[o[0]]),t.orderBy(a,n.flatten(o),["asc"])}e.sortBy=i})(Ws)),Ws}var Xs,Eh;function aP(){return Eh||(Eh=1,Xs=iP().sortBy),Xs}var oP=aP();const oo=Qt(oP);var qv=e=>e.legend.settings,sP=e=>e.legend.size,lP=e=>e.legend.payload;P([lP,qv],(e,t)=>{var{itemSorter:n}=t,r=e.flat(1);return n?oo(r,n):r});var $i=1;function cP(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],[t,n]=w.useState({height:0,left:0,top:0,width:0}),r=w.useCallback(i=>{if(i!=null){var a=i.getBoundingClientRect(),o={height:a.height,left:a.left,top:a.top,width:a.width};(Math.abs(o.height-t.height)>$i||Math.abs(o.left-t.left)>$i||Math.abs(o.top-t.top)>$i||Math.abs(o.width-t.width)>$i)&&n({height:o.height,left:o.left,top:o.top,width:o.width})}},[t.width,t.height,t.top,t.left,...e]);return[t,r]}function Oe(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var uP=typeof Symbol=="function"&&Symbol.observable||"@@observable",Dh=uP,Gs=()=>Math.random().toString(36).substring(7).split("").join("."),fP={INIT:`@@redux/INIT${Gs()}`,REPLACE:`@@redux/REPLACE${Gs()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${Gs()}`},va=fP;function Qc(e){if(typeof e!="object"||e===null)return!1;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||Object.getPrototypeOf(e)===null}function Uv(e,t,n){if(typeof e!="function")throw new Error(Oe(2));if(typeof t=="function"&&typeof n=="function"||typeof n=="function"&&typeof arguments[3]=="function")throw new Error(Oe(0));if(typeof t=="function"&&typeof n>"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(Oe(1));return n(Uv)(e,t)}let r=e,i=t,a=new Map,o=a,s=0,l=!1;function c(){o===a&&(o=new Map,a.forEach((g,v)=>{o.set(v,g)}))}function u(){if(l)throw new Error(Oe(3));return i}function f(g){if(typeof g!="function")throw new Error(Oe(4));if(l)throw new Error(Oe(5));let v=!0;c();const y=s++;return o.set(y,g),function(){if(v){if(l)throw new Error(Oe(6));v=!1,c(),o.delete(y),a=null}}}function d(g){if(!Qc(g))throw new Error(Oe(7));if(typeof g.type>"u")throw new Error(Oe(8));if(typeof g.type!="string")throw new Error(Oe(17));if(l)throw new Error(Oe(9));try{l=!0,i=r(i,g)}finally{l=!1}return(a=o).forEach(y=>{y()}),g}function h(g){if(typeof g!="function")throw new Error(Oe(10));r=g,d({type:va.REPLACE})}function p(){const g=f;return{subscribe(v){if(typeof v!="object"||v===null)throw new Error(Oe(11));function y(){const _=v;_.next&&_.next(u())}return y(),{unsubscribe:g(y)}},[Dh](){return this}}}return d({type:va.INIT}),{dispatch:d,subscribe:f,getState:u,replaceReducer:h,[Dh]:p}}function dP(e){Object.keys(e).forEach(t=>{const n=e[t];if(typeof n(void 0,{type:va.INIT})>"u")throw new Error(Oe(12));if(typeof n(void 0,{type:va.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Oe(13))})}function Vv(e){const t=Object.keys(e),n={};for(let a=0;a<t.length;a++){const o=t[a];typeof e[o]=="function"&&(n[o]=e[o])}const r=Object.keys(n);let i;try{dP(n)}catch(a){i=a}return function(o={},s){if(i)throw i;let l=!1;const c={};for(let u=0;u<r.length;u++){const f=r[u],d=n[f],h=o[f],p=d(h,s);if(typeof p>"u")throw s&&s.type,new Error(Oe(14));c[f]=p,l=l||p!==h}return l=l||r.length!==Object.keys(o).length,l?c:o}}function ya(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,n)=>(...r)=>t(n(...r)))}function hP(...e){return t=>(n,r)=>{const i=t(n,r);let a=()=>{throw new Error(Oe(15))};const o={getState:i.getState,dispatch:(l,...c)=>a(l,...c)},s=e.map(l=>l(o));return a=ya(...s)(i.dispatch),{...i,dispatch:a}}}function Hv(e){return Qc(e)&&"type"in e&&typeof e.type=="string"}var Kv=Symbol.for("immer-nothing"),Th=Symbol.for("immer-draftable"),Ce=Symbol.for("immer-state");function nt(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var qe=Object,Qn=qe.getPrototypeOf,ba="constructor",so="prototype",Hl="configurable",xa="enumerable",ia="writable",Hr="value",Et=e=>!!e&&!!e[Ce];function st(e){return e?Yv(e)||co(e)||!!e[Th]||!!e[ba]?.[Th]||uo(e)||fo(e):!1}var pP=qe[so][ba].toString(),Ih=new WeakMap;function Yv(e){if(!e||!Jc(e))return!1;const t=Qn(e);if(t===null||t===qe[so])return!0;const n=qe.hasOwnProperty.call(t,ba)&&t[ba];if(n===Object)return!0;if(!Wn(n))return!1;let r=Ih.get(n);return r===void 0&&(r=Function.toString.call(n),Ih.set(n,r)),r===pP}function lo(e,t,n=!0){li(e)===0?(n?Reflect.ownKeys(e):qe.keys(e)).forEach(i=>{t(i,e[i],e)}):e.forEach((r,i)=>t(i,r,e))}function li(e){const t=e[Ce];return t?t.type_:co(e)?1:uo(e)?2:fo(e)?3:0}var jh=(e,t,n=li(e))=>n===2?e.has(t):qe[so].hasOwnProperty.call(e,t),Kl=(e,t,n=li(e))=>n===2?e.get(t):e[t],_a=(e,t,n,r=li(e))=>{r===2?e.set(t,n):r===3?e.add(n):e[t]=n};function gP(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}var co=Array.isArray,uo=e=>e instanceof Map,fo=e=>e instanceof Set,Jc=e=>typeof e=="object",Wn=e=>typeof e=="function",Zs=e=>typeof e=="boolean";function mP(e){const t=+e;return Number.isInteger(t)&&String(t)===e}var Pt=e=>e.copy_||e.base_,eu=e=>e.modified_?e.copy_:e.base_;function Yl(e,t){if(uo(e))return new Map(e);if(fo(e))return new Set(e);if(co(e))return Array[so].slice.call(e);const n=Yv(e);if(t===!0||t==="class_only"&&!n){const r=qe.getOwnPropertyDescriptors(e);delete r[Ce];let i=Reflect.ownKeys(r);for(let a=0;a<i.length;a++){const o=i[a],s=r[o];s[ia]===!1&&(s[ia]=!0,s[Hl]=!0),(s.get||s.set)&&(r[o]={[Hl]:!0,[ia]:!0,[xa]:s[xa],[Hr]:e[o]})}return qe.create(Qn(e),r)}else{const r=Qn(e);if(r!==null&&n)return{...e};const i=qe.create(r);return qe.assign(i,e)}}function tu(e,t=!1){return ho(e)||Et(e)||!st(e)||(li(e)>1&&qe.defineProperties(e,{set:Wi,add:Wi,clear:Wi,delete:Wi}),qe.freeze(e),t&&lo(e,(n,r)=>{tu(r,!0)},!1)),e}function vP(){nt(2)}var Wi={[Hr]:vP};function ho(e){return e===null||!Jc(e)?!0:qe.isFrozen(e)}var wa="MapSet",Xl="Patches",Rh="ArrayMethods",Xv={};function En(e){const t=Xv[e];return t||nt(0,e),t}var Lh=e=>!!Xv[e],Kr,Gv=()=>Kr,yP=(e,t)=>({drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0,handledSet_:new Set,processedForPatches_:new Set,mapSetPlugin_:Lh(wa)?En(wa):void 0,arrayMethodsPlugin_:Lh(Rh)?En(Rh):void 0});function Nh(e,t){t&&(e.patchPlugin_=En(Xl),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Gl(e){Zl(e),e.drafts_.forEach(bP),e.drafts_=null}function Zl(e){e===Kr&&(Kr=e.parent_)}var Fh=e=>Kr=yP(Kr,e);function bP(e){const t=e[Ce];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function Bh(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];if(e!==void 0&&e!==n){n[Ce].modified_&&(Gl(t),nt(4)),st(e)&&(e=zh(t,e));const{patchPlugin_:i}=t;i&&i.generateReplacementPatches_(n[Ce].base_,e,t)}else e=zh(t,n);return xP(t,e,!0),Gl(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==Kv?e:void 0}function zh(e,t){if(ho(t))return t;const n=t[Ce];if(!n)return Sa(t,e.handledSet_,e);if(!po(n,e))return t;if(!n.modified_)return n.base_;if(!n.finalized_){const{callbacks_:r}=n;if(r)for(;r.length>0;)r.pop()(e);Jv(n,e)}return n.copy_}function xP(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&tu(t,n)}function Zv(e){e.finalized_=!0,e.scope_.unfinalizedDrafts_--}var po=(e,t)=>e.scope_===t,_P=[];function Qv(e,t,n,r){const i=Pt(e),a=e.type_;if(r!==void 0&&Kl(i,r,a)===t){_a(i,r,n,a);return}if(!e.draftLocations_){const s=e.draftLocations_=new Map;lo(i,(l,c)=>{if(Et(c)){const u=s.get(c)||[];u.push(l),s.set(c,u)}})}const o=e.draftLocations_.get(t)??_P;for(const s of o)_a(i,s,n,a)}function wP(e,t,n){e.callbacks_.push(function(i){const a=t;if(!a||!po(a,i))return;i.mapSetPlugin_?.fixSetContents(a);const o=eu(a);Qv(e,a.draft_??a,o,n),Jv(a,i)})}function Jv(e,t){if(e.modified_&&!e.finalized_&&(e.type_===3||e.type_===1&&e.allIndicesReassigned_||(e.assigned_?.size??0)>0)){const{patchPlugin_:r}=t;if(r){const i=r.getPath(e);i&&r.generatePatches_(e,i,t)}Zv(e)}}function SP(e,t,n){const{scope_:r}=e;if(Et(n)){const i=n[Ce];po(i,r)&&i.callbacks_.push(function(){aa(e);const o=eu(i);Qv(e,n,o,t)})}else st(n)&&e.callbacks_.push(function(){const a=Pt(e);e.type_===3?a.has(n)&&Sa(n,r.handledSet_,r):Kl(a,t,e.type_)===n&&r.drafts_.length>1&&(e.assigned_.get(t)??!1)===!0&&e.copy_&&Sa(Kl(e.copy_,t,e.type_),r.handledSet_,r)})}function Sa(e,t,n){return!n.immer_.autoFreeze_&&n.unfinalizedDrafts_<1||Et(e)||t.has(e)||!st(e)||ho(e)||(t.add(e),lo(e,(r,i)=>{if(Et(i)){const a=i[Ce];if(po(a,n)){const o=eu(a);_a(e,r,o,e.type_),Zv(a)}}else st(i)&&Sa(i,t,n)})),e}function OP(e,t){const n=co(e),r={type_:n?1:0,scope_:t?t.scope_:Gv(),modified_:!1,finalized_:!1,assigned_:void 0,parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1,callbacks_:void 0};let i=r,a=Oa;n&&(i=[r],a=Yr);const{revoke:o,proxy:s}=Proxy.revocable(i,a);return r.draft_=s,r.revoke_=o,[s,r]}var Oa={get(e,t){if(t===Ce)return e;let n=e.scope_.arrayMethodsPlugin_;const r=e.type_===1&&typeof t=="string";if(r&&n?.isArrayOperationMethod(t))return n.createMethodInterceptor(e,t);const i=Pt(e);if(!jh(i,t,e.type_))return PP(e,i,t);const a=i[t];if(e.finalized_||!st(a)||r&&e.operationMethod&&n?.isMutatingArrayMethod(e.operationMethod)&&mP(t))return a;if(a===Qs(e.base_,t)){aa(e);const o=e.type_===1?+t:t,s=Jl(e.scope_,a,e,o);return e.copy_[o]=s}return a},has(e,t){return t in Pt(e)},ownKeys(e){return Reflect.ownKeys(Pt(e))},set(e,t,n){const r=ey(Pt(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const i=Qs(Pt(e),t),a=i?.[Ce];if(a&&a.base_===n)return e.copy_[t]=n,e.assigned_.set(t,!1),!0;if(gP(n,i)&&(n!==void 0||jh(e.base_,t,e.type_)))return!0;aa(e),Ql(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_.set(t,!0),SP(e,t,n)),!0},deleteProperty(e,t){return aa(e),Qs(e.base_,t)!==void 0||t in e.base_?(e.assigned_.set(t,!1),Ql(e)):e.assigned_.delete(t),e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=Pt(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{[ia]:!0,[Hl]:e.type_!==1||t!=="length",[xa]:r[xa],[Hr]:n[t]}},defineProperty(){nt(11)},getPrototypeOf(e){return Qn(e.base_)},setPrototypeOf(){nt(12)}},Yr={};for(let e in Oa){let t=Oa[e];Yr[e]=function(){const n=arguments;return n[0]=n[0][0],t.apply(this,n)}}Yr.deleteProperty=function(e,t){return Yr.set.call(this,e,t,void 0)};Yr.set=function(e,t,n){return Oa.set.call(this,e[0],t,n,e[0])};function Qs(e,t){const n=e[Ce];return(n?Pt(n):e)[t]}function PP(e,t,n){const r=ey(t,n);return r?Hr in r?r[Hr]:r.get?.call(e.draft_):void 0}function ey(e,t){if(!(t in e))return;let n=Qn(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Qn(n)}}function Ql(e){e.modified_||(e.modified_=!0,e.parent_&&Ql(e.parent_))}function aa(e){e.copy_||(e.assigned_=new Map,e.copy_=Yl(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var MP=class{constructor(t){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!1,this.produce=(n,r,i)=>{if(Wn(n)&&!Wn(r)){const o=r;r=n;const s=this;return function(c=o,...u){return s.produce(c,f=>r.call(this,f,...u))}}Wn(r)||nt(6),i!==void 0&&!Wn(i)&&nt(7);let a;if(st(n)){const o=Fh(this),s=Jl(o,n,void 0);let l=!0;try{a=r(s),l=!1}finally{l?Gl(o):Zl(o)}return Nh(o,i),Bh(a,o)}else if(!n||!Jc(n)){if(a=r(n),a===void 0&&(a=n),a===Kv&&(a=void 0),this.autoFreeze_&&tu(a,!0),i){const o=[],s=[];En(Xl).generateReplacementPatches_(n,a,{patches_:o,inversePatches_:s}),i(o,s)}return a}else nt(1,n)},this.produceWithPatches=(n,r)=>{if(Wn(n))return(s,...l)=>this.produceWithPatches(s,c=>n(c,...l));let i,a;return[this.produce(n,r,(s,l)=>{i=s,a=l}),i,a]},Zs(t?.autoFreeze)&&this.setAutoFreeze(t.autoFreeze),Zs(t?.useStrictShallowCopy)&&this.setUseStrictShallowCopy(t.useStrictShallowCopy),Zs(t?.useStrictIteration)&&this.setUseStrictIteration(t.useStrictIteration)}createDraft(t){st(t)||nt(8),Et(t)&&(t=ot(t));const n=Fh(this),r=Jl(n,t,void 0);return r[Ce].isManual_=!0,Zl(n),r}finishDraft(t,n){const r=t&&t[Ce];(!r||!r.isManual_)&&nt(9);const{scope_:i}=r;return Nh(i,n),Bh(void 0,i)}setAutoFreeze(t){this.autoFreeze_=t}setUseStrictShallowCopy(t){this.useStrictShallowCopy_=t}setUseStrictIteration(t){this.useStrictIteration_=t}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(t,n){let r;for(r=n.length-1;r>=0;r--){const a=n[r];if(a.path.length===0&&a.op==="replace"){t=a.value;break}}r>-1&&(n=n.slice(r+1));const i=En(Xl).applyPatches_;return Et(t)?i(t,n):this.produce(t,a=>i(a,n))}};function Jl(e,t,n,r){const[i,a]=uo(t)?En(wa).proxyMap_(t,n):fo(t)?En(wa).proxySet_(t,n):OP(t,n);return(n?.scope_??Gv()).drafts_.push(i),a.callbacks_=n?.callbacks_??[],a.key_=r,n&&r!==void 0?wP(n,a,r):a.callbacks_.push(function(l){l.mapSetPlugin_?.fixSetContents(a);const{patchPlugin_:c}=l;a.modified_&&c&&c.generatePatches_(a,[],l)}),i}function ot(e){return Et(e)||nt(10,e),ty(e)}function ty(e){if(!st(e)||ho(e))return e;const t=e[Ce];let n,r=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=Yl(e,t.scope_.immer_.useStrictShallowCopy_),r=t.scope_.immer_.shouldUseStrictIteration()}else n=Yl(e,!0);return lo(n,(i,a)=>{_a(n,i,ty(a))},r),t&&(t.finalized_=!1),n}var AP=new MP,ny=AP.produce;function ry(e){return({dispatch:n,getState:r})=>i=>a=>typeof a=="function"?a(n,r,e):i(a)}var kP=ry(),CP=ry,EP=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?ya:ya.apply(null,arguments)};function Je(e,t){function n(...r){if(t){let i=t(...r);if(!i)throw new Error(Ve(0));return{type:e,payload:i.payload,..."meta"in i&&{meta:i.meta},..."error"in i&&{error:i.error}}}return{type:e,payload:r[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=r=>Hv(r)&&r.type===e,n}var iy=class jr extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,jr.prototype)}static get[Symbol.species](){return jr}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new jr(...t[0].concat(this)):new jr(...t.concat(this))}};function $h(e){return st(e)?ny(e,()=>{}):e}function qi(e,t,n){return e.has(t)?e.get(t):e.set(t,n(t)).get(t)}function DP(e){return typeof e=="boolean"}var TP=()=>function(t){const{thunk:n=!0,immutableCheck:r=!0,serializableCheck:i=!0,actionCreatorCheck:a=!0}=t??{};let o=new iy;return n&&(DP(n)?o.push(kP):o.push(CP(n.extraArgument))),o},ay="RTK_autoBatch",te=()=>e=>({payload:e,meta:{[ay]:!0}}),Wh=e=>t=>{setTimeout(t,e)},oy=(e={type:"raf"})=>t=>(...n)=>{const r=t(...n);let i=!0,a=!1,o=!1;const s=new Set,l=e.type==="tick"?queueMicrotask:e.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:Wh(10):e.type==="callback"?e.queueNotification:Wh(e.timeout),c=()=>{o=!1,a&&(a=!1,s.forEach(u=>u()))};return Object.assign({},r,{subscribe(u){const f=()=>i&&u(),d=r.subscribe(f);return s.add(u),()=>{d(),s.delete(u)}},dispatch(u){try{return i=!u?.meta?.[ay],a=!i,a&&(o||(o=!0,l(c))),r.dispatch(u)}finally{i=!0}}})},IP=e=>function(n){const{autoBatch:r=!0}=n??{};let i=new iy(e);return r&&i.push(oy(typeof r=="object"?r:void 0)),i};function jP(e){const t=TP(),{reducer:n=void 0,middleware:r,devTools:i=!0,preloadedState:a=void 0,enhancers:o=void 0}=e||{};let s;if(typeof n=="function")s=n;else if(Qc(n))s=Vv(n);else throw new Error(Ve(1));let l;typeof r=="function"?l=r(t):l=t();let c=ya;i&&(c=EP({trace:!1,...typeof i=="object"&&i}));const u=hP(...l),f=IP(u);let d=typeof o=="function"?o(f):f();const h=c(...d);return Uv(s,a,h)}function sy(e){const t={},n=[];let r;const i={addCase(a,o){const s=typeof a=="string"?a:a.type;if(!s)throw new Error(Ve(28));if(s in t)throw new Error(Ve(29));return t[s]=o,i},addAsyncThunk(a,o){return o.pending&&(t[a.pending.type]=o.pending),o.rejected&&(t[a.rejected.type]=o.rejected),o.fulfilled&&(t[a.fulfilled.type]=o.fulfilled),o.settled&&n.push({matcher:a.settled,reducer:o.settled}),i},addMatcher(a,o){return n.push({matcher:a,reducer:o}),i},addDefaultCase(a){return r=a,i}};return e(i),[t,n,r]}function RP(e){return typeof e=="function"}function LP(e,t){let[n,r,i]=sy(t),a;if(RP(e))a=()=>$h(e());else{const s=$h(e);a=()=>s}function o(s=a(),l){let c=[n[l.type],...r.filter(({matcher:u})=>u(l)).map(({reducer:u})=>u)];return c.filter(u=>!!u).length===0&&(c=[i]),c.reduce((u,f)=>{if(f)if(Et(u)){const h=f(u,l);return h===void 0?u:h}else{if(st(u))return ny(u,d=>f(d,l));{const d=f(u,l);if(d===void 0){if(u===null)return u;throw Error("A case reducer on a non-draftable value must not return undefined")}return d}}return u},s)}return o.getInitialState=a,o}var NP="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",FP=(e=21)=>{let t="",n=e;for(;n--;)t+=NP[Math.random()*64|0];return t},BP=Symbol.for("rtk-slice-createasyncthunk");function zP(e,t){return`${e}/${t}`}function $P({creators:e}={}){const t=e?.asyncThunk?.[BP];return function(r){const{name:i,reducerPath:a=i}=r;if(!i)throw new Error(Ve(11));const o=(typeof r.reducers=="function"?r.reducers(qP()):r.reducers)||{},s=Object.keys(o),l={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},c={addCase(b,_){const x=typeof b=="string"?b:b.type;if(!x)throw new Error(Ve(12));if(x in l.sliceCaseReducersByType)throw new Error(Ve(13));return l.sliceCaseReducersByType[x]=_,c},addMatcher(b,_){return l.sliceMatchers.push({matcher:b,reducer:_}),c},exposeAction(b,_){return l.actionCreators[b]=_,c},exposeCaseReducer(b,_){return l.sliceCaseReducersByName[b]=_,c}};s.forEach(b=>{const _=o[b],x={reducerName:b,type:zP(i,b),createNotation:typeof r.reducers=="function"};VP(_)?KP(x,_,c,t):UP(x,_,c)});function u(){const[b={},_=[],x=void 0]=typeof r.extraReducers=="function"?sy(r.extraReducers):[r.extraReducers],S={...b,...l.sliceCaseReducersByType};return LP(r.initialState,O=>{for(let M in S)O.addCase(M,S[M]);for(let M of l.sliceMatchers)O.addMatcher(M.matcher,M.reducer);for(let M of _)O.addMatcher(M.matcher,M.reducer);x&&O.addDefaultCase(x)})}const f=b=>b,d=new Map,h=new WeakMap;let p;function m(b,_){return p||(p=u()),p(b,_)}function g(){return p||(p=u()),p.getInitialState()}function v(b,_=!1){function x(O){let M=O[b];return typeof M>"u"&&_&&(M=qi(h,x,g)),M}function S(O=f){const M=qi(d,_,()=>new WeakMap);return qi(M,O,()=>{const E={};for(const[j,D]of Object.entries(r.selectors??{}))E[j]=WP(D,O,()=>qi(h,O,g),_);return E})}return{reducerPath:b,getSelectors:S,get selectors(){return S(x)},selectSlice:x}}const y={name:i,reducer:m,actions:l.actionCreators,caseReducers:l.sliceCaseReducersByName,getInitialState:g,...v(a),injectInto(b,{reducerPath:_,...x}={}){const S=_??a;return b.inject({reducerPath:S,reducer:m},x),{...y,...v(S,!0)}}};return y}}function WP(e,t,n,r){function i(a,...o){let s=t(a);return typeof s>"u"&&r&&(s=n()),e(s,...o)}return i.unwrapped=e,i}var Ne=$P();function qP(){function e(t,n){return{_reducerDefinitionType:"asyncThunk",payloadCreator:t,...n}}return e.withTypes=()=>e,{reducer(t){return Object.assign({[t.name](...n){return t(...n)}}[t.name],{_reducerDefinitionType:"reducer"})},preparedReducer(t,n){return{_reducerDefinitionType:"reducerWithPrepare",prepare:t,reducer:n}},asyncThunk:e}}function UP({type:e,reducerName:t,createNotation:n},r,i){let a,o;if("reducer"in r){if(n&&!HP(r))throw new Error(Ve(17));a=r.reducer,o=r.prepare}else a=r;i.addCase(e,a).exposeCaseReducer(t,a).exposeAction(t,o?Je(e,o):Je(e))}function VP(e){return e._reducerDefinitionType==="asyncThunk"}function HP(e){return e._reducerDefinitionType==="reducerWithPrepare"}function KP({type:e,reducerName:t},n,r,i){if(!i)throw new Error(Ve(18));const{payloadCreator:a,fulfilled:o,pending:s,rejected:l,settled:c,options:u}=n,f=i(e,a,u);r.exposeAction(t,f),o&&r.addCase(f.fulfilled,o),s&&r.addCase(f.pending,s),l&&r.addCase(f.rejected,l),c&&r.addMatcher(f.settled,c),r.exposeCaseReducer(t,{fulfilled:o||Ui,pending:s||Ui,rejected:l||Ui,settled:c||Ui})}function Ui(){}var YP="task",ly="listener",cy="completed",nu="cancelled",XP=`task-${nu}`,GP=`task-${cy}`,ec=`${ly}-${nu}`,ZP=`${ly}-${cy}`,go=class{constructor(e){this.code=e,this.message=`${YP} ${nu} (reason: ${e})`}name="TaskAbortError";message},ru=(e,t)=>{if(typeof e!="function")throw new TypeError(Ve(32))},Pa=()=>{},uy=(e,t=Pa)=>(e.catch(t),e),fy=(e,t)=>(e.addEventListener("abort",t,{once:!0}),()=>e.removeEventListener("abort",t)),On=e=>{if(e.aborted)throw new go(e.reason)};function dy(e,t){let n=Pa;return new Promise((r,i)=>{const a=()=>i(new go(e.reason));if(e.aborted){a();return}n=fy(e,a),t.finally(()=>n()).then(r,i)}).finally(()=>{n=Pa})}var QP=async(e,t)=>{try{return await Promise.resolve(),{status:"ok",value:await e()}}catch(n){return{status:n instanceof go?"cancelled":"rejected",error:n}}finally{t?.()}},Ma=e=>t=>uy(dy(e,t).then(n=>(On(e),n))),hy=e=>{const t=Ma(e);return n=>t(new Promise(r=>setTimeout(r,n)))},{assign:Un}=Object,qh={},mo="listenerMiddleware",JP=(e,t)=>{const n=r=>fy(e,()=>r.abort(e.reason));return(r,i)=>{ru(r);const a=new AbortController;n(a);const o=QP(async()=>{On(e),On(a.signal);const s=await r({pause:Ma(a.signal),delay:hy(a.signal),signal:a.signal});return On(a.signal),s},()=>a.abort(GP));return i?.autoJoin&&t.push(o.catch(Pa)),{result:Ma(e)(o),cancel(){a.abort(XP)}}}},eM=(e,t)=>{const n=async(r,i)=>{On(t);let a=()=>{};const s=[new Promise((l,c)=>{let u=e({predicate:r,effect:(f,d)=>{d.unsubscribe(),l([f,d.getState(),d.getOriginalState()])}});a=()=>{u(),c()}})];i!=null&&s.push(new Promise(l=>setTimeout(l,i,null)));try{const l=await dy(t,Promise.race(s));return On(t),l}finally{a()}};return(r,i)=>uy(n(r,i))},py=e=>{let{type:t,actionCreator:n,matcher:r,predicate:i,effect:a}=e;if(t)i=Je(t).match;else if(n)t=n.type,i=n.match;else if(r)i=r;else if(!i)throw new Error(Ve(21));return ru(a),{predicate:i,type:t,effect:a}},gy=Un(e=>{const{type:t,predicate:n,effect:r}=py(e);return{id:FP(),effect:r,type:t,predicate:n,pending:new Set,unsubscribe:()=>{throw new Error(Ve(22))}}},{withTypes:()=>gy}),Uh=(e,t)=>{const{type:n,effect:r,predicate:i}=py(t);return Array.from(e.values()).find(a=>(typeof n=="string"?a.type===n:a.predicate===i)&&a.effect===r)},tc=e=>{e.pending.forEach(t=>{t.abort(ec)})},tM=(e,t)=>()=>{for(const n of t.keys())tc(n);e.clear()},Vh=(e,t,n)=>{try{e(t,n)}catch(r){setTimeout(()=>{throw r},0)}},my=Un(Je(`${mo}/add`),{withTypes:()=>my}),nM=Je(`${mo}/removeAll`),vy=Un(Je(`${mo}/remove`),{withTypes:()=>vy}),rM=(...e)=>{console.error(`${mo}/error`,...e)},ci=(e={})=>{const t=new Map,n=new Map,r=h=>{const p=n.get(h)??0;n.set(h,p+1)},i=h=>{const p=n.get(h)??1;p===1?n.delete(h):n.set(h,p-1)},{extra:a,onError:o=rM}=e;ru(o);const s=h=>(h.unsubscribe=()=>t.delete(h.id),t.set(h.id,h),p=>{h.unsubscribe(),p?.cancelActive&&tc(h)}),l=h=>{const p=Uh(t,h)??gy(h);return s(p)};Un(l,{withTypes:()=>l});const c=h=>{const p=Uh(t,h);return p&&(p.unsubscribe(),h.cancelActive&&tc(p)),!!p};Un(c,{withTypes:()=>c});const u=async(h,p,m,g)=>{const v=new AbortController,y=eM(l,v.signal),b=[];try{h.pending.add(v),r(h),await Promise.resolve(h.effect(p,Un({},m,{getOriginalState:g,condition:(_,x)=>y(_,x).then(Boolean),take:y,delay:hy(v.signal),pause:Ma(v.signal),extra:a,signal:v.signal,fork:JP(v.signal,b),unsubscribe:h.unsubscribe,subscribe:()=>{t.set(h.id,h)},cancelActiveListeners:()=>{h.pending.forEach((_,x,S)=>{_!==v&&(_.abort(ec),S.delete(_))})},cancel:()=>{v.abort(ec),h.pending.delete(v)},throwIfCancelled:()=>{On(v.signal)}})))}catch(_){_ instanceof go||Vh(o,_,{raisedBy:"effect"})}finally{await Promise.all(b),v.abort(ZP),i(h),h.pending.delete(v)}},f=tM(t,n);return{middleware:h=>p=>m=>{if(!Hv(m))return p(m);if(my.match(m))return l(m.payload);if(nM.match(m)){f();return}if(vy.match(m))return c(m.payload);let g=h.getState();const v=()=>{if(g===qh)throw new Error(Ve(23));return g};let y;try{if(y=p(m),t.size>0){const b=h.getState(),_=Array.from(t.values());for(const x of _){let S=!1;try{S=x.predicate(m,b,g)}catch(O){S=!1,Vh(o,O,{raisedBy:"predicate"})}S&&u(x,m,h,v)}}}finally{g=qh}return y},startListening:l,stopListening:c,clearListeners:f}};function Ve(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var iM={layoutType:"horizontal",width:0,height:0,margin:{top:5,right:5,bottom:5,left:5},scale:1},yy=Ne({name:"chartLayout",initialState:iM,reducers:{setLayout(e,t){e.layoutType=t.payload},setChartSize(e,t){e.width=t.payload.width,e.height=t.payload.height},setMargin(e,t){var n,r,i,a;e.margin.top=(n=t.payload.top)!==null&&n!==void 0?n:0,e.margin.right=(r=t.payload.right)!==null&&r!==void 0?r:0,e.margin.bottom=(i=t.payload.bottom)!==null&&i!==void 0?i:0,e.margin.left=(a=t.payload.left)!==null&&a!==void 0?a:0},setScale(e,t){e.scale=t.payload}}}),{setMargin:aM,setLayout:lL,setChartSize:oM,setScale:sM}=yy.actions,lM=yy.reducer;function by(e,t,n){return Array.isArray(e)&&e&&t+n!==0?e.slice(t,n+1):e}function Q(e){return Number.isFinite(e)}function Zt(e){return typeof e=="number"&&e>0&&Number.isFinite(e)}function Hh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Hh(Object(n),!0).forEach(function(r){cM(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Hh(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function cM(e,t,n){return(t=uM(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function uM(e){var t=fM(e,"string");return typeof t=="symbol"?t:t+""}function fM(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ve(e,t,n){return ma(e)||ma(t)?n:Cn(t)?Hc(e,t,n):typeof t=="function"?t(e):n}var dM=(e,t,n)=>{if(t&&n){var{width:r,height:i}=n,{align:a,verticalAlign:o,layout:s}=t;if((s==="vertical"||s==="horizontal"&&o==="middle")&&a!=="center"&&z(e[a]))return qn(qn({},e),{},{[a]:e[a]+(r||0)});if((s==="horizontal"||s==="vertical"&&a==="center")&&o!=="middle"&&z(e[o]))return qn(qn({},e),{},{[o]:e[o]+(i||0)})}return e},Jt=(e,t)=>e==="horizontal"&&t==="xAxis"||e==="vertical"&&t==="yAxis"||e==="centric"&&t==="angleAxis"||e==="radial"&&t==="radiusAxis",hM=e=>{var t,n=e.length;if(!(n<=0)){var r=(t=e[0])===null||t===void 0?void 0:t.length;if(!(r==null||r<=0))for(var i=0;i<r;++i)for(var a=0,o=0,s=0;s<n;++s){var l=e[s],c=l?.[i];if(c!=null){var u=c[1],f=c[0],d=sr(u)?f:u;d>=0?(c[0]=a,a+=d,c[1]=a):(c[0]=o,o+=d,c[1]=o)}}}},pM=e=>{var t,n=e.length;if(!(n<=0)){var r=(t=e[0])===null||t===void 0?void 0:t.length;if(!(r==null||r<=0))for(var i=0;i<r;++i)for(var a=0,o=0;o<n;++o){var s=e[o],l=s?.[i];if(l!=null){var c=sr(l[1])?l[0]:l[1];c>=0?(l[0]=a,a+=c,l[1]=a):(l[0]=0,l[1]=0)}}}},gM={sign:hM,expand:tO,none:kn,silhouette:nO,wiggle:rO,positive:pM},mM=(e,t,n)=>{var r,i=(r=gM[n])!==null&&r!==void 0?r:kn,a=eO().keys(t).value((s,l)=>Number(ve(s,l,0))).order(Ul).offset(i),o=a(e);return o.forEach((s,l)=>{s.forEach((c,u)=>{var f=ve(e[u],t[l],0);Array.isArray(f)&&f.length===2&&z(f[0])&&z(f[1])&&(c[0]=f[0],c[1]=f[1])})}),o},vM=e=>{var t=e.flat(2).filter(z);return[Math.min(...t),Math.max(...t)]},yM=e=>[e[0]===1/0?0:e[0],e[1]===-1/0?0:e[1]],bM=(e,t,n)=>{if(e!=null)return yM(Object.keys(e).reduce((r,i)=>{var a=e[i];if(!a)return r;var{stackedData:o}=a,s=o.reduce((l,c)=>{var u=by(c,t,n),f=vM(u);return!Q(f[0])||!Q(f[1])?l:[Math.min(l[0],f[0]),Math.max(l[1],f[1])]},[1/0,-1/0]);return[Math.min(s[0],r[0]),Math.max(s[1],r[1])]},[1/0,-1/0]))},Kh=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Yh=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Xh=(e,t,n)=>{if(e&&e.scale&&e.scale.bandwidth){var r=e.scale.bandwidth();return r}if(e&&t&&t.length>=2){for(var i=oo(t,u=>u.coordinate),a=1/0,o=1,s=i.length;o<s;o++){var l=i[o],c=i[o-1];a=Math.min((l?.coordinate||0)-(c?.coordinate||0),a)}return a===1/0?0:a}return n?void 0:0};function Gh(e){var{tooltipEntrySettings:t,dataKey:n,payload:r,value:i,name:a}=e;return qn(qn({},t),{},{dataKey:n,payload:r,value:i,name:a})}var xM=(e,t)=>{if(t==="horizontal")return e.chartX;if(t==="vertical")return e.chartY},_M=(e,t)=>t==="centric"?e.angle:e.radius,en=e=>e.layout.width,tn=e=>e.layout.height,wM=e=>e.layout.scale,xy=e=>e.layout.margin,vo=P(e=>e.cartesianAxis.xAxis,e=>Object.values(e)),yo=P(e=>e.cartesianAxis.yAxis,e=>Object.values(e)),SM="data-recharts-item-index",OM="data-recharts-item-id",ui=60;function Zh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Vi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Zh(Object(n),!0).forEach(function(r){PM(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Zh(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function PM(e,t,n){return(t=MM(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function MM(e){var t=AM(e,"string");return typeof t=="symbol"?t:t+""}function AM(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var kM=e=>e.brush.height;function CM(e){var t=yo(e);return t.reduce((n,r)=>{if(r.orientation==="left"&&!r.mirror&&!r.hide){var i=typeof r.width=="number"?r.width:ui;return n+i}return n},0)}function EM(e){var t=yo(e);return t.reduce((n,r)=>{if(r.orientation==="right"&&!r.mirror&&!r.hide){var i=typeof r.width=="number"?r.width:ui;return n+i}return n},0)}function DM(e){var t=vo(e);return t.reduce((n,r)=>r.orientation==="top"&&!r.mirror&&!r.hide?n+r.height:n,0)}function TM(e){var t=vo(e);return t.reduce((n,r)=>r.orientation==="bottom"&&!r.mirror&&!r.hide?n+r.height:n,0)}var Ae=P([en,tn,xy,kM,CM,EM,DM,TM,qv,sP],(e,t,n,r,i,a,o,s,l,c)=>{var u={left:(n.left||0)+i,right:(n.right||0)+a},f={top:(n.top||0)+o,bottom:(n.bottom||0)+s},d=Vi(Vi({},f),u),h=d.bottom;d.bottom+=r,d=dM(d,l,c);var p=e-d.left-d.right,m=t-d.top-d.bottom;return Vi(Vi({brushBottom:h},d),{},{width:Math.max(p,0),height:Math.max(m,0)})}),IM=P(Ae,e=>({x:e.left,y:e.top,width:e.width,height:e.height}));P(en,tn,(e,t)=>({x:0,y:0,width:e,height:t}));var jM=w.createContext(null),fi=()=>w.useContext(jM)!=null,bo=e=>e.brush,iu=P([bo,Ae,xy],(e,t,n)=>({height:e.height,x:z(e.x)?e.x:t.left,y:z(e.y)?e.y:t.top+t.height+t.brushBottom-(n?.bottom||0),width:z(e.width)?e.width:t.width})),Js={},el={},tl={},Qh;function RM(){return Qh||(Qh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r,{signal:i,edges:a}={}){let o,s=null;const l=a!=null&&a.includes("leading"),c=a==null||a.includes("trailing"),u=()=>{s!==null&&(n.apply(o,s),o=void 0,s=null)},f=()=>{c&&u(),m()};let d=null;const h=()=>{d!=null&&clearTimeout(d),d=setTimeout(()=>{d=null,f()},r)},p=()=>{d!==null&&(clearTimeout(d),d=null)},m=()=>{p(),o=void 0,s=null},g=()=>{u()},v=function(...y){if(i?.aborted)return;o=this,s=y;const b=d==null;h(),l&&b&&u()};return v.schedule=h,v.cancel=m,v.flush=g,i?.addEventListener("abort",m,{once:!0}),v}e.debounce=t})(tl)),tl}var Jh;function LM(){return Jh||(Jh=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=RM();function n(r,i=0,a={}){typeof a!="object"&&(a={});const{leading:o=!1,trailing:s=!0,maxWait:l}=a,c=Array(2);o&&(c[0]="leading"),s&&(c[1]="trailing");let u,f=null;const d=t.debounce(function(...m){u=r.apply(this,m),f=null},i,{edges:c}),h=function(...m){return l!=null&&(f===null&&(f=Date.now()),Date.now()-f>=l)?(u=r.apply(this,m),f=Date.now(),d.cancel(),d.schedule(),u):(d.apply(this,m),u)},p=()=>(d.flush(),u);return h.cancel=d.cancel,h.flush=p,h}e.debounce=n})(el)),el}var ep;function NM(){return ep||(ep=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=LM();function n(r,i=0,a={}){const{leading:o=!0,trailing:s=!0}=a;return t.debounce(r,i,{leading:o,maxWait:i,trailing:s})}e.throttle=n})(Js)),Js}var nl,tp;function FM(){return tp||(tp=1,nl=NM().throttle),nl}var BM=FM();const zM=Qt(BM);var np=function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),a=2;a<r;a++)i[a-2]=arguments[a];if(typeof console<"u"&&console.warn&&(n===void 0&&console.warn("LogUtils requires an error message argument"),!t))if(n===void 0)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var o=0;console.warn(n.replace(/%s/g,()=>i[o++]))}},gt={width:"100%",height:"100%",debounce:0,minWidth:0,initialDimension:{width:-1,height:-1}},_y=(e,t,n)=>{var{width:r=gt.width,height:i=gt.height,aspect:a,maxHeight:o}=n,s=Vr(r)?e:Number(r),l=Vr(i)?t:Number(i);return a&&a>0&&(s?l=s/a:l&&(s=l*a),o&&l!=null&&l>o&&(l=o)),{calculatedWidth:s,calculatedHeight:l}},$M={width:0,height:0,overflow:"visible"},WM={width:0,overflowX:"visible"},qM={height:0,overflowY:"visible"},UM={},VM=e=>{var{width:t,height:n}=e,r=Vr(t),i=Vr(n);return r&&i?$M:r?WM:i?qM:UM};function HM(e){var{width:t,height:n,aspect:r}=e,i=t,a=n;return i===void 0&&a===void 0?(i=gt.width,a=gt.height):i===void 0?i=r&&r>0?void 0:gt.width:a===void 0&&(a=r&&r>0?void 0:gt.height),{width:i,height:a}}function nc(){return nc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},nc.apply(null,arguments)}function rp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ip(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?rp(Object(n),!0).forEach(function(r){KM(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rp(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function KM(e,t,n){return(t=YM(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function YM(e){var t=XM(e,"string");return typeof t=="symbol"?t:t+""}function XM(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var wy=w.createContext(gt.initialDimension);function GM(e){return Zt(e.width)&&Zt(e.height)}function Sy(e){var{children:t,width:n,height:r}=e,i=w.useMemo(()=>({width:n,height:r}),[n,r]);return GM(i)?w.createElement(wy.Provider,{value:i},t):null}var au=()=>w.useContext(wy),ZM=w.forwardRef((e,t)=>{var{aspect:n,initialDimension:r=gt.initialDimension,width:i,height:a,minWidth:o=gt.minWidth,minHeight:s,maxHeight:l,children:c,debounce:u=gt.debounce,id:f,className:d,onResize:h,style:p={}}=e,m=w.useRef(null),g=w.useRef();g.current=h,w.useImperativeHandle(t,()=>m.current);var[v,y]=w.useState({containerWidth:r.width,containerHeight:r.height}),b=w.useCallback((M,E)=>{y(j=>{var D=Math.round(M),A=Math.round(E);return j.containerWidth===D&&j.containerHeight===A?j:{containerWidth:D,containerHeight:A}})},[]);w.useEffect(()=>{if(m.current==null||typeof ResizeObserver>"u")return lr;var M=A=>{var N,R=A[0];if(R!=null){var{width:T,height:L}=R.contentRect;b(T,L),(N=g.current)===null||N===void 0||N.call(g,T,L)}};u>0&&(M=zM(M,u,{trailing:!0,leading:!1}));var E=new ResizeObserver(M),{width:j,height:D}=m.current.getBoundingClientRect();return b(j,D),E.observe(m.current),()=>{E.disconnect()}},[b,u]);var{containerWidth:_,containerHeight:x}=v;np(!n||n>0,"The aspect(%s) must be greater than zero.",n);var{calculatedWidth:S,calculatedHeight:O}=_y(_,x,{width:i,height:a,aspect:n,maxHeight:l});return np(S!=null&&S>0||O!=null&&O>0,`The width(%s) and height(%s) of chart should be greater than 0,
|
|
4
|
-
please check the style of container, or the props width(%s) and height(%s),
|
|
5
|
-
or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
|
|
6
|
-
height and width.`,S,O,i,a,o,s,n),w.createElement("div",{id:f?"".concat(f):void 0,className:Ze("recharts-responsive-container",d),style:ip(ip({},p),{},{width:i,height:a,minWidth:o,minHeight:s,maxHeight:l}),ref:m},w.createElement("div",{style:VM({width:i,height:a})},w.createElement(Sy,{width:S,height:O},c)))}),cL=w.forwardRef((e,t)=>{var n=au();if(Zt(n.width)&&Zt(n.height))return e.children;var{width:r,height:i}=HM({width:e.width,height:e.height,aspect:e.aspect}),{calculatedWidth:a,calculatedHeight:o}=_y(void 0,void 0,{width:r,height:i,aspect:e.aspect,maxHeight:e.maxHeight});return z(a)&&z(o)?w.createElement(Sy,{width:a,height:o},e.children):w.createElement(ZM,nc({},e,{width:r,height:i,ref:t}))}),ou=()=>{var e,t=fi(),n=K(IM),r=K(iu),i=(e=K(bo))===null||e===void 0?void 0:e.padding;return!t||!r||!i?n:{width:r.width-i.left-i.right,height:r.height-i.top-i.bottom,x:i.left,y:i.top}},QM={top:0,bottom:0,left:0,right:0,width:0,height:0,brushBottom:0},JM=()=>{var e;return(e=K(Ae))!==null&&e!==void 0?e:QM},eA=()=>K(en),tA=()=>K(tn),ce=e=>e.layout.layoutType,xo=()=>K(ce),Oy=e=>{var t=e.layout.layoutType;if(t==="centric"||t==="radial")return t},nA=()=>{var e=xo();return e!==void 0},di=e=>{var t=Ke(),n=fi(),{width:r,height:i}=e,a=au(),o=r,s=i;return a&&(o=a.width>0?a.width:r,s=a.height>0?a.height:i),w.useEffect(()=>{!n&&Zt(o)&&Zt(s)&&t(oM({width:o,height:s}))},[t,n,o,s]),null},rA=e=>{var{margin:t}=e,n=Ke();return w.useEffect(()=>{n(aM(t))},[n,t]),null},Py=Symbol.for("immer-nothing"),ap=Symbol.for("immer-draftable"),He=Symbol.for("immer-state");function rt(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Xr=Object.getPrototypeOf;function Jn(e){return!!e&&!!e[He]}function Dn(e){return e?My(e)||Array.isArray(e)||!!e[ap]||!!e.constructor?.[ap]||hi(e)||wo(e):!1}var iA=Object.prototype.constructor.toString(),op=new WeakMap;function My(e){if(!e||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);if(t===null||t===Object.prototype)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;if(n===Object)return!0;if(typeof n!="function")return!1;let r=op.get(n);return r===void 0&&(r=Function.toString.call(n),op.set(n,r)),r===iA}function Aa(e,t,n=!0){_o(e)===0?(n?Reflect.ownKeys(e):Object.keys(e)).forEach(i=>{t(i,e[i],e)}):e.forEach((r,i)=>t(i,r,e))}function _o(e){const t=e[He];return t?t.type_:Array.isArray(e)?1:hi(e)?2:wo(e)?3:0}function rc(e,t){return _o(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Ay(e,t,n){const r=_o(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function aA(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function hi(e){return e instanceof Map}function wo(e){return e instanceof Set}function mn(e){return e.copy_||e.base_}function ic(e,t){if(hi(e))return new Map(e);if(wo(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=My(e);if(t===!0||t==="class_only"&&!n){const r=Object.getOwnPropertyDescriptors(e);delete r[He];let i=Reflect.ownKeys(r);for(let a=0;a<i.length;a++){const o=i[a],s=r[o];s.writable===!1&&(s.writable=!0,s.configurable=!0),(s.get||s.set)&&(r[o]={configurable:!0,writable:!0,enumerable:s.enumerable,value:e[o]})}return Object.create(Xr(e),r)}else{const r=Xr(e);if(r!==null&&n)return{...e};const i=Object.create(r);return Object.assign(i,e)}}function su(e,t=!1){return So(e)||Jn(e)||!Dn(e)||(_o(e)>1&&Object.defineProperties(e,{set:Hi,add:Hi,clear:Hi,delete:Hi}),Object.freeze(e),t&&Object.values(e).forEach(n=>su(n,!0))),e}function oA(){rt(2)}var Hi={value:oA};function So(e){return e===null||typeof e!="object"?!0:Object.isFrozen(e)}var sA={};function Tn(e){const t=sA[e];return t||rt(0,e),t}var Gr;function ky(){return Gr}function lA(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function sp(e,t){t&&(Tn("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function ac(e){oc(e),e.drafts_.forEach(cA),e.drafts_=null}function oc(e){e===Gr&&(Gr=e.parent_)}function lp(e){return Gr=lA(Gr,e)}function cA(e){const t=e[He];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function cp(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return e!==void 0&&e!==n?(n[He].modified_&&(ac(t),rt(4)),Dn(e)&&(e=ka(t,e),t.parent_||Ca(t,e)),t.patches_&&Tn("Patches").generateReplacementPatches_(n[He].base_,e,t.patches_,t.inversePatches_)):e=ka(t,n,[]),ac(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==Py?e:void 0}function ka(e,t,n){if(So(t))return t;const r=e.immer_.shouldUseStrictIteration(),i=t[He];if(!i)return Aa(t,(a,o)=>up(e,i,t,a,o,n),r),t;if(i.scope_!==e)return t;if(!i.modified_)return Ca(e,i.base_,!0),i.base_;if(!i.finalized_){i.finalized_=!0,i.scope_.unfinalizedDrafts_--;const a=i.copy_;let o=a,s=!1;i.type_===3&&(o=new Set(a),a.clear(),s=!0),Aa(o,(l,c)=>up(e,i,a,l,c,n,s),r),Ca(e,a,!1),n&&e.patches_&&Tn("Patches").generatePatches_(i,n,e.patches_,e.inversePatches_)}return i.copy_}function up(e,t,n,r,i,a,o){if(i==null||typeof i!="object"&&!o)return;const s=So(i);if(!(s&&!o)){if(Jn(i)){const l=a&&t&&t.type_!==3&&!rc(t.assigned_,r)?a.concat(r):void 0,c=ka(e,i,l);if(Ay(n,r,c),Jn(c))e.canAutoFreeze_=!1;else return}else o&&n.add(i);if(Dn(i)&&!s){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1||t&&t.base_&&t.base_[r]===i&&s)return;ka(e,i),(!t||!t.scope_.parent_)&&typeof r!="symbol"&&(hi(n)?n.has(r):Object.prototype.propertyIsEnumerable.call(n,r))&&Ca(e,i)}}}function Ca(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&su(t,n)}function uA(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:ky(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let i=r,a=lu;n&&(i=[r],a=Zr);const{revoke:o,proxy:s}=Proxy.revocable(i,a);return r.draft_=s,r.revoke_=o,s}var lu={get(e,t){if(t===He)return e;const n=mn(e);if(!rc(n,t))return fA(e,n,t);const r=n[t];return e.finalized_||!Dn(r)?r:r===rl(e.base_,t)?(il(e),e.copy_[t]=lc(r,e)):r},has(e,t){return t in mn(e)},ownKeys(e){return Reflect.ownKeys(mn(e))},set(e,t,n){const r=Cy(mn(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const i=rl(mn(e),t),a=i?.[He];if(a&&a.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(aA(n,i)&&(n!==void 0||rc(e.base_,t)))return!0;il(e),sc(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty(e,t){return rl(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,il(e),sc(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=mn(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},defineProperty(){rt(11)},getPrototypeOf(e){return Xr(e.base_)},setPrototypeOf(){rt(12)}},Zr={};Aa(lu,(e,t)=>{Zr[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});Zr.deleteProperty=function(e,t){return Zr.set.call(this,e,t,void 0)};Zr.set=function(e,t,n){return lu.set.call(this,e[0],t,n,e[0])};function rl(e,t){const n=e[He];return(n?mn(n):e)[t]}function fA(e,t,n){const r=Cy(t,n);return r?"value"in r?r.value:r.get?.call(e.draft_):void 0}function Cy(e,t){if(!(t in e))return;let n=Xr(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Xr(n)}}function sc(e){e.modified_||(e.modified_=!0,e.parent_&&sc(e.parent_))}function il(e){e.copy_||(e.copy_=ic(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var dA=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!0,this.produce=(t,n,r)=>{if(typeof t=="function"&&typeof n!="function"){const a=n;n=t;const o=this;return function(l=a,...c){return o.produce(l,u=>n.call(this,u,...c))}}typeof n!="function"&&rt(6),r!==void 0&&typeof r!="function"&&rt(7);let i;if(Dn(t)){const a=lp(this),o=lc(t,void 0);let s=!0;try{i=n(o),s=!1}finally{s?ac(a):oc(a)}return sp(a,r),cp(i,a)}else if(!t||typeof t!="object"){if(i=n(t),i===void 0&&(i=t),i===Py&&(i=void 0),this.autoFreeze_&&su(i,!0),r){const a=[],o=[];Tn("Patches").generateReplacementPatches_(t,i,a,o),r(a,o)}return i}else rt(1,t)},this.produceWithPatches=(t,n)=>{if(typeof t=="function")return(o,...s)=>this.produceWithPatches(o,l=>t(l,...s));let r,i;return[this.produce(t,n,(o,s)=>{r=o,i=s}),r,i]},typeof e?.autoFreeze=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof e?.useStrictShallowCopy=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy),typeof e?.useStrictIteration=="boolean"&&this.setUseStrictIteration(e.useStrictIteration)}createDraft(e){Dn(e)||rt(8),Jn(e)&&(e=hA(e));const t=lp(this),n=lc(e,void 0);return n[He].isManual_=!0,oc(t),n}finishDraft(e,t){const n=e&&e[He];(!n||!n.isManual_)&&rt(9);const{scope_:r}=n;return sp(r,t),cp(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}setUseStrictIteration(e){this.useStrictIteration_=e}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const i=t[n];if(i.path.length===0&&i.op==="replace"){e=i.value;break}}n>-1&&(t=t.slice(n+1));const r=Tn("Patches").applyPatches_;return Jn(e)?r(e,t):this.produce(e,i=>r(i,t))}};function lc(e,t){const n=hi(e)?Tn("MapSet").proxyMap_(e,t):wo(e)?Tn("MapSet").proxySet_(e,t):uA(e,t);return(t?t.scope_:ky()).drafts_.push(n),n}function hA(e){return Jn(e)||rt(10,e),Ey(e)}function Ey(e){if(!Dn(e)||So(e))return e;const t=e[He];let n,r=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=ic(e,t.scope_.immer_.useStrictShallowCopy_),r=t.scope_.immer_.shouldUseStrictIteration()}else n=ic(e,!0);return Aa(n,(i,a)=>{Ay(n,i,Ey(a))},r),t&&(t.finalized_=!1),n}var pA=new dA;pA.produce;var gA={settings:{layout:"horizontal",align:"center",verticalAlign:"middle",itemSorter:"value"},size:{width:0,height:0},payload:[]},Dy=Ne({name:"legend",initialState:gA,reducers:{setLegendSize(e,t){e.size.width=t.payload.width,e.size.height=t.payload.height},setLegendSettings(e,t){e.settings.align=t.payload.align,e.settings.layout=t.payload.layout,e.settings.verticalAlign=t.payload.verticalAlign,e.settings.itemSorter=t.payload.itemSorter},addLegendPayload:{reducer(e,t){e.payload.push(t.payload)},prepare:te()},replaceLegendPayload:{reducer(e,t){var{prev:n,next:r}=t.payload,i=ot(e).payload.indexOf(n);i>-1&&(e.payload[i]=r)},prepare:te()},removeLegendPayload:{reducer(e,t){var n=ot(e).payload.indexOf(t.payload);n>-1&&e.payload.splice(n,1)},prepare:te()}}}),{setLegendSize:uL,setLegendSettings:fL,addLegendPayload:dL,replaceLegendPayload:hL,removeLegendPayload:pL}=Dy.actions,mA=Dy.reducer;function cc(){return cc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},cc.apply(null,arguments)}function fp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Sr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fp(Object(n),!0).forEach(function(r){vA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fp(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vA(e,t,n){return(t=yA(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function yA(e){var t=bA(e,"string");return typeof t=="symbol"?t:t+""}function bA(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function xA(e){return Array.isArray(e)&&Cn(e[0])&&Cn(e[1])?e.join(" ~ "):e}var Fn={separator:" : ",contentStyle:{margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},itemStyle:{display:"block",paddingTop:4,paddingBottom:4,color:"#000"},labelStyle:{},accessibilityLayer:!1},_A=e=>{var{separator:t=Fn.separator,contentStyle:n,itemStyle:r,labelStyle:i=Fn.labelStyle,payload:a,formatter:o,itemSorter:s,wrapperClassName:l,labelClassName:c,label:u,labelFormatter:f,accessibilityLayer:d=Fn.accessibilityLayer}=e,h=()=>{if(a&&a.length){var x={padding:0,margin:0},S=(s?oo(a,s):a).map((O,M)=>{if(O.type==="none")return null;var E=O.formatter||o||xA,{value:j,name:D}=O,A=j,N=D;if(E){var R=E(j,D,O,M,a);if(Array.isArray(R))[A,N]=R;else if(R!=null)A=R;else return null}var T=Sr(Sr({},Fn.itemStyle),{},{color:O.color||Fn.itemStyle.color},r);return w.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(M),style:T},Cn(N)?w.createElement("span",{className:"recharts-tooltip-item-name"},N):null,Cn(N)?w.createElement("span",{className:"recharts-tooltip-item-separator"},t):null,w.createElement("span",{className:"recharts-tooltip-item-value"},A),w.createElement("span",{className:"recharts-tooltip-item-unit"},O.unit||""))});return w.createElement("ul",{className:"recharts-tooltip-item-list",style:x},S)}return null},p=Sr(Sr({},Fn.contentStyle),n),m=Sr({margin:0},i),g=!ma(u),v=g?u:"",y=Ze("recharts-default-tooltip",l),b=Ze("recharts-tooltip-label",c);g&&f&&a!==void 0&&a!==null&&(v=f(u,a));var _=d?{role:"status","aria-live":"assertive"}:{};return w.createElement("div",cc({className:y,style:p},_),w.createElement("p",{className:b,style:m},w.isValidElement(v)?v:"".concat(v)),h())},Or="recharts-tooltip-wrapper",wA={visibility:"hidden"};function SA(e){var{coordinate:t,translateX:n,translateY:r}=e;return Ze(Or,{["".concat(Or,"-right")]:z(n)&&t&&z(t.x)&&n>=t.x,["".concat(Or,"-left")]:z(n)&&t&&z(t.x)&&n<t.x,["".concat(Or,"-bottom")]:z(r)&&t&&z(t.y)&&r>=t.y,["".concat(Or,"-top")]:z(r)&&t&&z(t.y)&&r<t.y})}function dp(e){var{allowEscapeViewBox:t,coordinate:n,key:r,offset:i,position:a,reverseDirection:o,tooltipDimension:s,viewBox:l,viewBoxDimension:c}=e;if(a&&z(a[r]))return a[r];var u=n[r]-s-(i>0?i:0),f=n[r]+i;if(t[r])return o[r]?u:f;var d=l[r];if(d==null)return 0;if(o[r]){var h=u,p=d;return h<p?Math.max(f,d):Math.max(u,d)}if(c==null)return 0;var m=f+s,g=d+c;return m>g?Math.max(u,d):Math.max(f,d)}function OA(e){var{translateX:t,translateY:n,useTranslate3d:r}=e;return{transform:r?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")}}function PA(e){var{allowEscapeViewBox:t,coordinate:n,offsetTop:r,offsetLeft:i,position:a,reverseDirection:o,tooltipBox:s,useTranslate3d:l,viewBox:c}=e,u,f,d;return s.height>0&&s.width>0&&n?(f=dp({allowEscapeViewBox:t,coordinate:n,key:"x",offset:i,position:a,reverseDirection:o,tooltipDimension:s.width,viewBox:c,viewBoxDimension:c.width}),d=dp({allowEscapeViewBox:t,coordinate:n,key:"y",offset:r,position:a,reverseDirection:o,tooltipDimension:s.height,viewBox:c,viewBoxDimension:c.height}),u=OA({translateX:f,translateY:d,useTranslate3d:l})):u=wA,{cssProperties:u,cssClasses:SA({translateX:f,translateY:d,coordinate:n})}}function hp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ki(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?hp(Object(n),!0).forEach(function(r){uc(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hp(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uc(e,t,n){return(t=MA(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function MA(e){var t=AA(e,"string");return typeof t=="symbol"?t:t+""}function AA(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}class kA extends w.PureComponent{constructor(){super(...arguments),uc(this,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0}}),uc(this,"handleKeyDown",t=>{if(t.key==="Escape"){var n,r,i,a;this.setState({dismissed:!0,dismissedAtCoordinate:{x:(n=(r=this.props.coordinate)===null||r===void 0?void 0:r.x)!==null&&n!==void 0?n:0,y:(i=(a=this.props.coordinate)===null||a===void 0?void 0:a.y)!==null&&i!==void 0?i:0}})}})}componentDidMount(){document.addEventListener("keydown",this.handleKeyDown)}componentWillUnmount(){document.removeEventListener("keydown",this.handleKeyDown)}componentDidUpdate(){var t,n;this.state.dismissed&&(((t=this.props.coordinate)===null||t===void 0?void 0:t.x)!==this.state.dismissedAtCoordinate.x||((n=this.props.coordinate)===null||n===void 0?void 0:n.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}render(){var{active:t,allowEscapeViewBox:n,animationDuration:r,animationEasing:i,children:a,coordinate:o,hasPayload:s,isAnimationActive:l,offset:c,position:u,reverseDirection:f,useTranslate3d:d,viewBox:h,wrapperStyle:p,lastBoundingBox:m,innerRef:g,hasPortalFromProps:v}=this.props,y=typeof c=="number"?c:c.x,b=typeof c=="number"?c:c.y,{cssClasses:_,cssProperties:x}=PA({allowEscapeViewBox:n,coordinate:o,offsetLeft:y,offsetTop:b,position:u,reverseDirection:f,tooltipBox:{height:m.height,width:m.width},useTranslate3d:d,viewBox:h}),S=v?{}:Ki(Ki({transition:l&&t?"transform ".concat(r,"ms ").concat(i):void 0},x),{},{pointerEvents:"none",visibility:!this.state.dismissed&&t&&s?"visible":"hidden",position:"absolute",top:0,left:0}),O=Ki(Ki({},S),{},{visibility:!this.state.dismissed&&t&&s?"visible":"hidden"},p);return w.createElement("div",{xmlns:"http://www.w3.org/1999/xhtml",tabIndex:-1,className:_,style:O,ref:g},a)}}var CA=()=>{var e;return(e=K(t=>t.rootProps.accessibilityLayer))!==null&&e!==void 0?e:!0};function fc(){return fc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},fc.apply(null,arguments)}function pp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function gp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?pp(Object(n),!0).forEach(function(r){EA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pp(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function EA(e,t,n){return(t=DA(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function DA(e){var t=TA(e,"string");return typeof t=="symbol"?t:t+""}function TA(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var mp={curveBasisClosed:qS,curveBasisOpen:US,curveBasis:WS,curveBumpX:zS,curveBumpY:$S,curveLinearClosed:VS,curveLinear:io,curveMonotoneX:HS,curveMonotoneY:KS,curveNatural:YS,curveStep:XS,curveStepAfter:ZS,curveStepBefore:GS},Ea=e=>Q(e.x)&&Q(e.y),vp=e=>e.base!=null&&Ea(e.base)&&Ea(e),Pr=e=>e.x,Mr=e=>e.y,IA=(e,t)=>{if(typeof e=="function")return e;var n="curve".concat(Kc(e));if((n==="curveMonotone"||n==="curveBump")&&t){var r=mp["".concat(n).concat(t==="vertical"?"Y":"X")];if(r)return r}return mp[n]||io},yp={connectNulls:!1,type:"linear"},jA=e=>{var{type:t=yp.type,points:n=[],baseLine:r,layout:i,connectNulls:a=yp.connectNulls}=e,o=IA(t,i),s=a?n.filter(Ea):n;if(Array.isArray(r)){var l,c=n.map((p,m)=>gp(gp({},p),{},{base:r[m]}));i==="vertical"?l=Fi().y(Mr).x1(Pr).x0(p=>p.base.x):l=Fi().x(Pr).y1(Mr).y0(p=>p.base.y);var u=l.defined(vp).curve(o),f=a?c.filter(vp):c;return u(f)}var d;i==="vertical"&&z(r)?d=Fi().y(Mr).x1(Pr).x0(r):z(r)?d=Fi().x(Pr).y1(Mr).y0(r):d=xv().x(Pr).y(Mr);var h=d.defined(Ea).curve(o);return h(s)},RA=e=>{var{className:t,points:n,path:r,pathRef:i}=e,a=xo();if((!n||!n.length)&&!r)return null;var o={type:e.type,points:e.points,baseLine:e.baseLine,layout:e.layout||a,connectNulls:e.connectNulls},s=n&&n.length?jA(o):r;return w.createElement("path",fc({},Xn(e),fO(e),{className:Ze("recharts-curve",t),d:s===null?void 0:s,ref:i}))},LA=["x","y","top","left","width","height","className"];function dc(){return dc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},dc.apply(null,arguments)}function bp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function NA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?bp(Object(n),!0).forEach(function(r){FA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bp(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function FA(e,t,n){return(t=BA(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function BA(e){var t=zA(e,"string");return typeof t=="symbol"?t:t+""}function zA(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function $A(e,t){if(e==null)return{};var n,r,i=WA(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function WA(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var qA=(e,t,n,r,i,a)=>"M".concat(e,",").concat(i,"v").concat(r,"M").concat(a,",").concat(t,"h").concat(n),UA=e=>{var{x:t=0,y:n=0,top:r=0,left:i=0,width:a=0,height:o=0,className:s}=e,l=$A(e,LA),c=NA({x:t,y:n,top:r,left:i,width:a,height:o},l);return!z(t)||!z(n)||!z(a)||!z(o)||!z(r)||!z(i)?null:w.createElement("path",dc({},Gn(c),{className:Ze("recharts-cross",s),d:qA(t,n,a,o,r,i)}))};function VA(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 xp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function _p(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?xp(Object(n),!0).forEach(function(r){HA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xp(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function HA(e,t,n){return(t=KA(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function KA(e){var t=YA(e,"string");return typeof t=="symbol"?t:t+""}function YA(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var XA=e=>e.replace(/([A-Z])/g,t=>"-".concat(t.toLowerCase())),GA=(e,t,n)=>e.map(r=>"".concat(XA(r)," ").concat(t,"ms ").concat(n)).join(","),ZA=(e,t)=>[Object.keys(e),Object.keys(t)].reduce((n,r)=>n.filter(i=>r.includes(i))),Qr=(e,t)=>Object.keys(t).reduce((n,r)=>_p(_p({},n),{},{[r]:e(r,t[r])}),{});function wp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function fe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?wp(Object(n),!0).forEach(function(r){QA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wp(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function QA(e,t,n){return(t=JA(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function JA(e){var t=ek(e,"string");return typeof t=="symbol"?t:t+""}function ek(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Da=(e,t,n)=>e+(t-e)*n,hc=e=>{var{from:t,to:n}=e;return t!==n},Ty=(e,t,n)=>{var r=Qr((i,a)=>{if(hc(a)){var[o,s]=e(a.from,a.to,a.velocity);return fe(fe({},a),{},{from:o,velocity:s})}return a},t);return n<1?Qr((i,a)=>hc(a)&&r[i]!=null?fe(fe({},a),{},{velocity:Da(a.velocity,r[i].velocity,n),from:Da(a.from,r[i].from,n)}):a,t):Ty(e,r,n-1)};function tk(e,t,n,r,i,a){var o,s=r.reduce((d,h)=>fe(fe({},d),{},{[h]:{from:e[h],velocity:0,to:t[h]}}),{}),l=()=>Qr((d,h)=>h.from,s),c=()=>!Object.values(s).filter(hc).length,u=null,f=d=>{o||(o=d);var h=d-o,p=h/n.dt;s=Ty(n,s,p),i(fe(fe(fe({},e),t),l())),o=d,c()||(u=a.setTimeout(f))};return()=>(u=a.setTimeout(f),()=>{var d;(d=u)===null||d===void 0||d()})}function nk(e,t,n,r,i,a,o){var s=null,l=i.reduce((f,d)=>{var h=e[d],p=t[d];return h==null||p==null?f:fe(fe({},f),{},{[d]:[h,p]})},{}),c,u=f=>{c||(c=f);var d=(f-c)/r,h=Qr((m,g)=>Da(...g,n(d)),l);if(a(fe(fe(fe({},e),t),h)),d<1)s=o.setTimeout(u);else{var p=Qr((m,g)=>Da(...g,n(1)),l);a(fe(fe(fe({},e),t),p))}};return()=>(s=o.setTimeout(u),()=>{var f;(f=s)===null||f===void 0||f()})}const rk=(e,t,n,r,i,a)=>{var o=ZA(e,t);return n==null?()=>(i(fe(fe({},e),t)),()=>{}):n.isStepper===!0?tk(e,t,n,o,i,a):nk(e,t,n,r,o,i,a)};var Ta=1e-4,Iy=(e,t)=>[0,3*e,3*t-6*e,3*e-3*t+1],jy=(e,t)=>e.map((n,r)=>n*t**r).reduce((n,r)=>n+r),Sp=(e,t)=>n=>{var r=Iy(e,t);return jy(r,n)},ik=(e,t)=>n=>{var r=Iy(e,t),i=[...r.map((a,o)=>a*o).slice(1),0];return jy(i,n)},ak=e=>{var t,n=e.split("(");if(n.length!==2||n[0]!=="cubic-bezier")return null;var r=(t=n[1])===null||t===void 0||(t=t.split(")")[0])===null||t===void 0?void 0:t.split(",");if(r==null||r.length!==4)return null;var i=r.map(a=>parseFloat(a));return[i[0],i[1],i[2],i[3]]},ok=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(n.length===1)switch(n[0]){case"linear":return[0,0,1,1];case"ease":return[.25,.1,.25,1];case"ease-in":return[.42,0,1,1];case"ease-out":return[.42,0,.58,1];case"ease-in-out":return[0,0,.58,1];default:{var i=ak(n[0]);if(i)return i}}return n.length===4?n:[0,0,1,1]},sk=(e,t,n,r)=>{var i=Sp(e,n),a=Sp(t,r),o=ik(e,n),s=c=>c>1?1:c<0?0:c,l=c=>{for(var u=c>1?1:c,f=u,d=0;d<8;++d){var h=i(f)-u,p=o(f);if(Math.abs(h-u)<Ta||p<Ta)return a(f);f=s(f-h/p)}return a(f)};return l.isStepper=!1,l},Op=function(){return sk(...ok(...arguments))},lk=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},{stiff:n=100,damping:r=8,dt:i=17}=t,a=(o,s,l)=>{var c=-(o-s)*n,u=l*r,f=l+(c-u)*i/1e3,d=l*i/1e3+o;return Math.abs(d-s)<Ta&&Math.abs(f)<Ta?[s,0]:[d,f]};return a.isStepper=!0,a.dt=i,a},ck=e=>{if(typeof e=="string")switch(e){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return Op(e);case"spring":return lk();default:if(e.split("(")[0]==="cubic-bezier")return Op(e)}return typeof e=="function"?e:null};function uk(e){var t,n=()=>null,r=!1,i=null,a=o=>{if(!r){if(Array.isArray(o)){if(!o.length)return;var s=o,[l,...c]=s;if(typeof l=="number"){i=e.setTimeout(a.bind(null,c),l);return}a(l),i=e.setTimeout(a.bind(null,c));return}typeof o=="string"&&(t=o,n(t)),typeof o=="object"&&(t=o,n(t)),typeof o=="function"&&o()}};return{stop:()=>{r=!0},start:o=>{r=!1,i&&(i(),i=null),a(o)},subscribe:o=>(n=o,()=>{n=()=>null}),getTimeoutController:()=>e}}class fk{setTimeout(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=performance.now(),i=null,a=o=>{o-r>=n?t(o):typeof requestAnimationFrame=="function"&&(i=requestAnimationFrame(a))};return i=requestAnimationFrame(a),()=>{i!=null&&cancelAnimationFrame(i)}}}function dk(){return uk(new fk)}var hk=w.createContext(dk);function pk(e,t){var n=w.useContext(hk);return w.useMemo(()=>t??n(e),[e,t,n])}var gk=()=>!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout),mk={isSsr:gk()},vk={begin:0,duration:1e3,easing:"ease",isActive:!0,canBegin:!0,onAnimationEnd:()=>{},onAnimationStart:()=>{}},Pp={t:0},al={t:1};function yk(e){var t=si(e,vk),{isActive:n,canBegin:r,duration:i,easing:a,begin:o,onAnimationEnd:s,onAnimationStart:l,children:c}=t,u=n==="auto"?!mk.isSsr:n,f=pk(t.animationId,t.animationManager),[d,h]=w.useState(u?Pp:al),p=w.useRef(null);return w.useEffect(()=>{u||h(al)},[u]),w.useEffect(()=>{if(!u||!r)return lr;var m=rk(Pp,al,ck(a),i,h,f.getTimeoutController()),g=()=>{p.current=m()};return f.start([l,o,g,i,s]),()=>{f.stop(),p.current&&p.current(),s()}},[u,r,i,a,o,l,s,f]),c(d.t)}function bk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"animation-",n=w.useRef(Vl(t)),r=w.useRef(e);return r.current!==e&&(n.current=Vl(t),r.current=e),n.current}var xk=["radius"],_k=["radius"],Mp,Ap,kp,Cp,Ep,Dp,Tp,Ip,jp,Rp;function Lp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Np(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Lp(Object(n),!0).forEach(function(r){wk(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Lp(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function wk(e,t,n){return(t=Sk(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Sk(e){var t=Ok(e,"string");return typeof t=="symbol"?t:t+""}function Ok(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ia(){return Ia=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ia.apply(null,arguments)}function Fp(e,t){if(e==null)return{};var n,r,i=Pk(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Pk(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function ct(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var Bp=(e,t,n,r,i)=>{var a=Ut(n),o=Ut(r),s=Math.min(Math.abs(a)/2,Math.abs(o)/2),l=o>=0?1:-1,c=a>=0?1:-1,u=o>=0&&a>=0||o<0&&a<0?1:0,f;if(s>0&&Array.isArray(i)){for(var d=[0,0,0,0],h=0,p=4;h<p;h++){var m,g=(m=i[h])!==null&&m!==void 0?m:0;d[h]=g>s?s:g}f=Pe(Mp||(Mp=ct(["M",",",""])),e,t+l*d[0]),d[0]>0&&(f+=Pe(Ap||(Ap=ct(["A ",",",",0,0,",",",",",""])),d[0],d[0],u,e+c*d[0],t)),f+=Pe(kp||(kp=ct(["L ",",",""])),e+n-c*d[1],t),d[1]>0&&(f+=Pe(Cp||(Cp=ct(["A ",",",",0,0,",`,
|
|
7
|
-
`,",",""])),d[1],d[1],u,e+n,t+l*d[1])),f+=Pe(Ep||(Ep=ct(["L ",",",""])),e+n,t+r-l*d[2]),d[2]>0&&(f+=Pe(Dp||(Dp=ct(["A ",",",",0,0,",`,
|
|
8
|
-
`,",",""])),d[2],d[2],u,e+n-c*d[2],t+r)),f+=Pe(Tp||(Tp=ct(["L ",",",""])),e+c*d[3],t+r),d[3]>0&&(f+=Pe(Ip||(Ip=ct(["A ",",",",0,0,",`,
|
|
9
|
-
`,",",""])),d[3],d[3],u,e,t+r-l*d[3])),f+="Z"}else if(s>0&&i===+i&&i>0){var v=Math.min(s,i);f=Pe(jp||(jp=ct(["M ",",",`
|
|
10
|
-
A `,",",",0,0,",",",",",`
|
|
11
|
-
L `,",",`
|
|
12
|
-
A `,",",",0,0,",",",",",`
|
|
13
|
-
L `,",",`
|
|
14
|
-
A `,",",",0,0,",",",",",`
|
|
15
|
-
L `,",",`
|
|
16
|
-
A `,",",",0,0,",",",","," Z"])),e,t+l*v,v,v,u,e+c*v,t,e+n-c*v,t,v,v,u,e+n,t+l*v,e+n,t+r-l*v,v,v,u,e+n-c*v,t+r,e+c*v,t+r,v,v,u,e,t+r-l*v)}else f=Pe(Rp||(Rp=ct(["M ",","," h "," v "," h "," Z"])),e,t,n,r,-n);return f},zp={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},Ry=e=>{var t=si(e,zp),n=w.useRef(null),[r,i]=w.useState(-1);w.useEffect(()=>{if(n.current&&n.current.getTotalLength)try{var F=n.current.getTotalLength();F&&i(F)}catch{}},[]);var{x:a,y:o,width:s,height:l,radius:c,className:u}=t,{animationEasing:f,animationDuration:d,animationBegin:h,isAnimationActive:p,isUpdateAnimationActive:m}=t,g=w.useRef(s),v=w.useRef(l),y=w.useRef(a),b=w.useRef(o),_=w.useMemo(()=>({x:a,y:o,width:s,height:l,radius:c}),[a,o,s,l,c]),x=bk(_,"rectangle-");if(a!==+a||o!==+o||s!==+s||l!==+l||s===0||l===0)return null;var S=Ze("recharts-rectangle",u);if(!m){var O=Gn(t),{radius:M}=O,E=Fp(O,xk);return w.createElement("path",Ia({},E,{x:Ut(a),y:Ut(o),width:Ut(s),height:Ut(l),radius:typeof c=="number"?c:void 0,className:S,d:Bp(a,o,s,l,c)}))}var j=g.current,D=v.current,A=y.current,N=b.current,R="0px ".concat(r===-1?1:r,"px"),T="".concat(r,"px 0px"),L=GA(["strokeDasharray"],d,typeof f=="string"?f:zp.animationEasing);return w.createElement(yk,{animationId:x,key:x,canBegin:r>0,duration:d,easing:f,isActive:m,begin:h},F=>{var oe=Bi(j,s,F),J=Bi(D,l,F),U=Bi(A,a,F),Me=Bi(N,o,F);n.current&&(g.current=oe,v.current=J,y.current=U,b.current=Me);var se;p?F>0?se={transition:L,strokeDasharray:T}:se={strokeDasharray:R}:se={strokeDasharray:T};var _e=Gn(t),{radius:re}=_e,we=Fp(_e,_k);return w.createElement("path",Ia({},we,{radius:typeof c=="number"?c:void 0,className:S,d:Bp(U,Me,oe,J,c),ref:n,style:Np(Np({},se),t.style)}))})};function $p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Wp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$p(Object(n),!0).forEach(function(r){Mk(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$p(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Mk(e,t,n){return(t=Ak(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ak(e){var t=kk(e,"string");return typeof t=="symbol"?t:t+""}function kk(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var ja=Math.PI/180,Ck=e=>e*180/Math.PI,Ue=(e,t,n,r)=>({x:e+Math.cos(-ja*r)*n,y:t+Math.sin(-ja*r)*n}),Ek=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(t-(r.left||0)-(r.right||0)),Math.abs(n-(r.top||0)-(r.bottom||0)))/2},Dk=(e,t)=>{var{x:n,y:r}=e,{x:i,y:a}=t;return Math.sqrt((n-i)**2+(r-a)**2)},Tk=(e,t)=>{var{x:n,y:r}=e,{cx:i,cy:a}=t,o=Dk({x:n,y:r},{x:i,y:a});if(o<=0)return{radius:o,angle:0};var s=(n-i)/o,l=Math.acos(s);return r>a&&(l=2*Math.PI-l),{radius:o,angle:Ck(l),angleInRadian:l}},Ik=e=>{var{startAngle:t,endAngle:n}=e,r=Math.floor(t/360),i=Math.floor(n/360),a=Math.min(r,i);return{startAngle:t-a*360,endAngle:n-a*360}},jk=(e,t)=>{var{startAngle:n,endAngle:r}=t,i=Math.floor(n/360),a=Math.floor(r/360),o=Math.min(i,a);return e+o*360},Rk=(e,t)=>{var{chartX:n,chartY:r}=e,{radius:i,angle:a}=Tk({x:n,y:r},t),{innerRadius:o,outerRadius:s}=t;if(i<o||i>s||i===0)return null;var{startAngle:l,endAngle:c}=Ik(t),u=a,f;if(l<=c){for(;u>c;)u-=360;for(;u<l;)u+=360;f=u>=l&&u<=c}else{for(;u>l;)u-=360;for(;u<c;)u+=360;f=u>=c&&u<=l}return f?Wp(Wp({},t),{},{radius:i,angle:jk(u,t)}):null};function Ly(e){var{cx:t,cy:n,radius:r,startAngle:i,endAngle:a}=e,o=Ue(t,n,r,i),s=Ue(t,n,r,a);return{points:[o,s],cx:t,cy:n,radius:r,startAngle:i,endAngle:a}}var qp,Up,Vp,Hp,Kp,Yp,Xp;function pc(){return pc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},pc.apply(null,arguments)}function bn(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var Lk=(e,t)=>{var n=Mt(t-e),r=Math.min(Math.abs(t-e),359.999);return n*r},Yi=e=>{var{cx:t,cy:n,radius:r,angle:i,sign:a,isExternal:o,cornerRadius:s,cornerIsExternal:l}=e,c=s*(o?1:-1)+r,u=Math.asin(s/c)/ja,f=l?i:i+a*u,d=Ue(t,n,c,f),h=Ue(t,n,r,f),p=l?i-a*u:i,m=Ue(t,n,c*Math.cos(u*ja),p);return{center:d,circleTangency:h,lineTangency:m,theta:u}},Ny=e=>{var{cx:t,cy:n,innerRadius:r,outerRadius:i,startAngle:a,endAngle:o}=e,s=Lk(a,o),l=a+s,c=Ue(t,n,i,a),u=Ue(t,n,i,l),f=Pe(qp||(qp=bn(["M ",",",`
|
|
17
|
-
A `,",",`,0,
|
|
18
|
-
`,",",`,
|
|
19
|
-
`,",",`
|
|
20
|
-
`])),c.x,c.y,i,i,+(Math.abs(s)>180),+(a>l),u.x,u.y);if(r>0){var d=Ue(t,n,r,a),h=Ue(t,n,r,l);f+=Pe(Up||(Up=bn(["L ",",",`
|
|
21
|
-
A `,",",`,0,
|
|
22
|
-
`,",",`,
|
|
23
|
-
`,","," Z"])),h.x,h.y,r,r,+(Math.abs(s)>180),+(a<=l),d.x,d.y)}else f+=Pe(Vp||(Vp=bn(["L ",","," Z"])),t,n);return f},Nk=e=>{var{cx:t,cy:n,innerRadius:r,outerRadius:i,cornerRadius:a,forceCornerRadius:o,cornerIsExternal:s,startAngle:l,endAngle:c}=e,u=Mt(c-l),{circleTangency:f,lineTangency:d,theta:h}=Yi({cx:t,cy:n,radius:i,angle:l,sign:u,cornerRadius:a,cornerIsExternal:s}),{circleTangency:p,lineTangency:m,theta:g}=Yi({cx:t,cy:n,radius:i,angle:c,sign:-u,cornerRadius:a,cornerIsExternal:s}),v=s?Math.abs(l-c):Math.abs(l-c)-h-g;if(v<0)return o?Pe(Hp||(Hp=bn(["M ",",",`
|
|
24
|
-
a`,",",",0,0,1,",`,0
|
|
25
|
-
a`,",",",0,0,1,",`,0
|
|
26
|
-
`])),d.x,d.y,a,a,a*2,a,a,-a*2):Ny({cx:t,cy:n,innerRadius:r,outerRadius:i,startAngle:l,endAngle:c});var y=Pe(Kp||(Kp=bn(["M ",",",`
|
|
27
|
-
A`,",",",0,0,",",",",",`
|
|
28
|
-
A`,",",",0,",",",",",",",`
|
|
29
|
-
A`,",",",0,0,",",",",",`
|
|
30
|
-
`])),d.x,d.y,a,a,+(u<0),f.x,f.y,i,i,+(v>180),+(u<0),p.x,p.y,a,a,+(u<0),m.x,m.y);if(r>0){var{circleTangency:b,lineTangency:_,theta:x}=Yi({cx:t,cy:n,radius:r,angle:l,sign:u,isExternal:!0,cornerRadius:a,cornerIsExternal:s}),{circleTangency:S,lineTangency:O,theta:M}=Yi({cx:t,cy:n,radius:r,angle:c,sign:-u,isExternal:!0,cornerRadius:a,cornerIsExternal:s}),E=s?Math.abs(l-c):Math.abs(l-c)-x-M;if(E<0&&a===0)return"".concat(y,"L").concat(t,",").concat(n,"Z");y+=Pe(Yp||(Yp=bn(["L",",",`
|
|
31
|
-
A`,",",",0,0,",",",",",`
|
|
32
|
-
A`,",",",0,",",",",",",",`
|
|
33
|
-
A`,",",",0,0,",",",",","Z"])),O.x,O.y,a,a,+(u<0),S.x,S.y,r,r,+(E>180),+(u>0),b.x,b.y,a,a,+(u<0),_.x,_.y)}else y+=Pe(Xp||(Xp=bn(["L",",","Z"])),t,n);return y},Fk={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},Bk=e=>{var t=si(e,Fk),{cx:n,cy:r,innerRadius:i,outerRadius:a,cornerRadius:o,forceCornerRadius:s,cornerIsExternal:l,startAngle:c,endAngle:u,className:f}=t;if(a<i||c===u)return null;var d=Ze("recharts-sector",f),h=a-i,p=Zn(o,h,0,!0),m;return p>0&&Math.abs(c-u)<360?m=Nk({cx:n,cy:r,innerRadius:i,outerRadius:a,cornerRadius:Math.min(p,h/2),forceCornerRadius:s,cornerIsExternal:l,startAngle:c,endAngle:u}):m=Ny({cx:n,cy:r,innerRadius:i,outerRadius:a,startAngle:c,endAngle:u}),w.createElement("path",pc({},Gn(t),{className:d,d:m}))};function zk(e,t,n){if(e==="horizontal")return[{x:t.x,y:n.top},{x:t.x,y:n.top+n.height}];if(e==="vertical")return[{x:n.left,y:t.y},{x:n.left+n.width,y:t.y}];if(Dv(t)){if(e==="centric"){var{cx:r,cy:i,innerRadius:a,outerRadius:o,angle:s}=t,l=Ue(r,i,a,s),c=Ue(r,i,o,s);return[{x:l.x,y:l.y},{x:c.x,y:c.y}]}return Ly(t)}}var ol={},sl={},ll={},Gp;function $k(){return Gp||(Gp=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=$v();function n(r){return t.isSymbol(r)?NaN:Number(r)}e.toNumber=n})(ll)),ll}var Zp;function Wk(){return Zp||(Zp=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=$k();function n(r){return r?(r=t.toNumber(r),r===1/0||r===-1/0?(r<0?-1:1)*Number.MAX_VALUE:r===r?r:0):r===0?r:0}e.toFinite=n})(sl)),sl}var Qp;function qk(){return Qp||(Qp=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Wv(),n=Wk();function r(i,a,o){o&&typeof o!="number"&&t.isIterateeCall(i,a,o)&&(a=o=void 0),i=n.toFinite(i),a===void 0?(a=i,i=0):a=n.toFinite(a),o=o===void 0?i<a?1:-1:n.toFinite(o);const s=Math.max(Math.ceil((a-i)/(o||1)),0),l=new Array(s);for(let c=0;c<s;c++)l[c]=i,i+=o;return l}e.range=r})(ol)),ol}var cl,Jp;function Uk(){return Jp||(Jp=1,cl=qk().range),cl}var Vk=Uk();const Fy=Qt(Vk);function Ht(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Hk(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function cu(e){let t,n,r;e.length!==2?(t=Ht,n=(s,l)=>Ht(e(s),l),r=(s,l)=>e(s)-l):(t=e===Ht||e===Hk?e:Kk,n=e,r=e);function i(s,l,c=0,u=s.length){if(c<u){if(t(l,l)!==0)return u;do{const f=c+u>>>1;n(s[f],l)<0?c=f+1:u=f}while(c<u)}return c}function a(s,l,c=0,u=s.length){if(c<u){if(t(l,l)!==0)return u;do{const f=c+u>>>1;n(s[f],l)<=0?c=f+1:u=f}while(c<u)}return c}function o(s,l,c=0,u=s.length){const f=i(s,l,c,u-1);return f>c&&r(s[f-1],l)>-r(s[f],l)?f-1:f}return{left:i,center:o,right:a}}function Kk(){return 0}function By(e){return e===null?NaN:+e}function*Yk(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const Xk=cu(Ht),pi=Xk.right;cu(By).center;class eg extends Map{constructor(t,n=Qk){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(tg(this,t))}has(t){return super.has(tg(this,t))}set(t,n){return super.set(Gk(this,t),n)}delete(t){return super.delete(Zk(this,t))}}function tg({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function Gk({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function Zk({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function Qk(e){return e!==null&&typeof e=="object"?e.valueOf():e}function Jk(e=Ht){if(e===Ht)return zy;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function zy(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const eC=Math.sqrt(50),tC=Math.sqrt(10),nC=Math.sqrt(2);function Ra(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),a=r/Math.pow(10,i),o=a>=eC?10:a>=tC?5:a>=nC?2:1;let s,l,c;return i<0?(c=Math.pow(10,-i)/o,s=Math.round(e*c),l=Math.round(t*c),s/c<e&&++s,l/c>t&&--l,c=-c):(c=Math.pow(10,i)*o,s=Math.round(e/c),l=Math.round(t/c),s*c<e&&++s,l*c>t&&--l),l<s&&.5<=n&&n<2?Ra(e,t,n*2):[s,l,c]}function gc(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,a,o]=r?Ra(t,e,n):Ra(e,t,n);if(!(a>=i))return[];const s=a-i+1,l=new Array(s);if(r)if(o<0)for(let c=0;c<s;++c)l[c]=(a-c)/-o;else for(let c=0;c<s;++c)l[c]=(a-c)*o;else if(o<0)for(let c=0;c<s;++c)l[c]=(i+c)/-o;else for(let c=0;c<s;++c)l[c]=(i+c)*o;return l}function mc(e,t,n){return t=+t,e=+e,n=+n,Ra(e,t,n)[2]}function vc(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?mc(t,e,n):mc(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function ng(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function rg(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function $y(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?zy:Jk(i);r>n;){if(r-n>600){const l=r-n+1,c=t-n+1,u=Math.log(l),f=.5*Math.exp(2*u/3),d=.5*Math.sqrt(u*f*(l-f)/l)*(c-l/2<0?-1:1),h=Math.max(n,Math.floor(t-c*f/l+d)),p=Math.min(r,Math.floor(t+(l-c)*f/l+d));$y(e,t,h,p,i)}const a=e[t];let o=n,s=r;for(Ar(e,n,t),i(e[r],a)>0&&Ar(e,n,r);o<s;){for(Ar(e,o,s),++o,--s;i(e[o],a)<0;)++o;for(;i(e[s],a)>0;)--s}i(e[n],a)===0?Ar(e,n,s):(++s,Ar(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function Ar(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function rC(e,t,n){if(e=Float64Array.from(Yk(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return rg(e);if(t>=1)return ng(e);var r,i=(r-1)*t,a=Math.floor(i),o=ng($y(e,a).subarray(0,a+1)),s=rg(e.subarray(a+1));return o+(s-o)*(i-a)}}function iC(e,t,n=By){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),s=+n(e[a+1],a+1,e);return o+(s-o)*(i-a)}}function aC(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=new Array(i);++r<i;)a[r]=e+r*n;return a}function tt(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Lt(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);break}}return this}const yc=Symbol("implicit");function uu(){var e=new eg,t=[],n=[],r=yc;function i(a){let o=e.get(a);if(o===void 0){if(r!==yc)return r;e.set(a,o=t.push(a)-1)}return n[o%n.length]}return i.domain=function(a){if(!arguments.length)return t.slice();t=[],e=new eg;for(const o of a)e.has(o)||e.set(o,t.push(o)-1);return i},i.range=function(a){return arguments.length?(n=Array.from(a),i):n.slice()},i.unknown=function(a){return arguments.length?(r=a,i):r},i.copy=function(){return uu(t,n).unknown(r)},tt.apply(i,arguments),i}function fu(){var e=uu().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,a,o,s=!1,l=0,c=0,u=.5;delete e.unknown;function f(){var d=t().length,h=i<r,p=h?i:r,m=h?r:i;a=(m-p)/Math.max(1,d-l+c*2),s&&(a=Math.floor(a)),p+=(m-p-a*(d-l))*u,o=a*(1-l),s&&(p=Math.round(p),o=Math.round(o));var g=aC(d).map(function(v){return p+a*v});return n(h?g.reverse():g)}return e.domain=function(d){return arguments.length?(t(d),f()):t()},e.range=function(d){return arguments.length?([r,i]=d,r=+r,i=+i,f()):[r,i]},e.rangeRound=function(d){return[r,i]=d,r=+r,i=+i,s=!0,f()},e.bandwidth=function(){return o},e.step=function(){return a},e.round=function(d){return arguments.length?(s=!!d,f()):s},e.padding=function(d){return arguments.length?(l=Math.min(1,c=+d),f()):l},e.paddingInner=function(d){return arguments.length?(l=Math.min(1,d),f()):l},e.paddingOuter=function(d){return arguments.length?(c=+d,f()):c},e.align=function(d){return arguments.length?(u=Math.max(0,Math.min(1,d)),f()):u},e.copy=function(){return fu(t(),[r,i]).round(s).paddingInner(l).paddingOuter(c).align(u)},tt.apply(f(),arguments)}function Wy(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return Wy(t())},e}function oC(){return Wy(fu.apply(null,arguments).paddingInner(1))}function du(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function qy(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function gi(){}var Jr=.7,La=1/Jr,Vn="\\s*([+-]?\\d+)\\s*",ei="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",yt="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",sC=/^#([0-9a-f]{3,8})$/,lC=new RegExp(`^rgb\\(${Vn},${Vn},${Vn}\\)$`),cC=new RegExp(`^rgb\\(${yt},${yt},${yt}\\)$`),uC=new RegExp(`^rgba\\(${Vn},${Vn},${Vn},${ei}\\)$`),fC=new RegExp(`^rgba\\(${yt},${yt},${yt},${ei}\\)$`),dC=new RegExp(`^hsl\\(${ei},${yt},${yt}\\)$`),hC=new RegExp(`^hsla\\(${ei},${yt},${yt},${ei}\\)$`),ig={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};du(gi,ti,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:ag,formatHex:ag,formatHex8:pC,formatHsl:gC,formatRgb:og,toString:og});function ag(){return this.rgb().formatHex()}function pC(){return this.rgb().formatHex8()}function gC(){return Uy(this).formatHsl()}function og(){return this.rgb().formatRgb()}function ti(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=sC.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?sg(t):n===3?new Le(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Xi(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Xi(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=lC.exec(e))?new Le(t[1],t[2],t[3],1):(t=cC.exec(e))?new Le(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=uC.exec(e))?Xi(t[1],t[2],t[3],t[4]):(t=fC.exec(e))?Xi(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=dC.exec(e))?ug(t[1],t[2]/100,t[3]/100,1):(t=hC.exec(e))?ug(t[1],t[2]/100,t[3]/100,t[4]):ig.hasOwnProperty(e)?sg(ig[e]):e==="transparent"?new Le(NaN,NaN,NaN,0):null}function sg(e){return new Le(e>>16&255,e>>8&255,e&255,1)}function Xi(e,t,n,r){return r<=0&&(e=t=n=NaN),new Le(e,t,n,r)}function mC(e){return e instanceof gi||(e=ti(e)),e?(e=e.rgb(),new Le(e.r,e.g,e.b,e.opacity)):new Le}function bc(e,t,n,r){return arguments.length===1?mC(e):new Le(e,t,n,r??1)}function Le(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}du(Le,bc,qy(gi,{brighter(e){return e=e==null?La:Math.pow(La,e),new Le(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Jr:Math.pow(Jr,e),new Le(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Le(Pn(this.r),Pn(this.g),Pn(this.b),Na(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:lg,formatHex:lg,formatHex8:vC,formatRgb:cg,toString:cg}));function lg(){return`#${xn(this.r)}${xn(this.g)}${xn(this.b)}`}function vC(){return`#${xn(this.r)}${xn(this.g)}${xn(this.b)}${xn((isNaN(this.opacity)?1:this.opacity)*255)}`}function cg(){const e=Na(this.opacity);return`${e===1?"rgb(":"rgba("}${Pn(this.r)}, ${Pn(this.g)}, ${Pn(this.b)}${e===1?")":`, ${e})`}`}function Na(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Pn(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function xn(e){return e=Pn(e),(e<16?"0":"")+e.toString(16)}function ug(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new it(e,t,n,r)}function Uy(e){if(e instanceof it)return new it(e.h,e.s,e.l,e.opacity);if(e instanceof gi||(e=ti(e)),!e)return new it;if(e instanceof it)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,l=(a+i)/2;return s?(t===a?o=(n-r)/s+(n<r)*6:n===a?o=(r-t)/s+2:o=(t-n)/s+4,s/=l<.5?a+i:2-a-i,o*=60):s=l>0&&l<1?0:o,new it(o,s,l,e.opacity)}function yC(e,t,n,r){return arguments.length===1?Uy(e):new it(e,t,n,r??1)}function it(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}du(it,yC,qy(gi,{brighter(e){return e=e==null?La:Math.pow(La,e),new it(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Jr:Math.pow(Jr,e),new it(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 Le(ul(e>=240?e-240:e+120,i,r),ul(e,i,r),ul(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new it(fg(this.h),Gi(this.s),Gi(this.l),Na(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(){const e=Na(this.opacity);return`${e===1?"hsl(":"hsla("}${fg(this.h)}, ${Gi(this.s)*100}%, ${Gi(this.l)*100}%${e===1?")":`, ${e})`}`}}));function fg(e){return e=(e||0)%360,e<0?e+360:e}function Gi(e){return Math.max(0,Math.min(1,e||0))}function ul(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const hu=e=>()=>e;function bC(e,t){return function(n){return e+n*t}}function xC(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function _C(e){return(e=+e)==1?Vy:function(t,n){return n-t?xC(t,n,e):hu(isNaN(t)?n:t)}}function Vy(e,t){var n=t-e;return n?bC(e,n):hu(isNaN(e)?t:e)}const dg=(function e(t){var n=_C(t);function r(i,a){var o=n((i=bc(i)).r,(a=bc(a)).r),s=n(i.g,a.g),l=n(i.b,a.b),c=Vy(i.opacity,a.opacity);return function(u){return i.r=o(u),i.g=s(u),i.b=l(u),i.opacity=c(u),i+""}}return r.gamma=e,r})(1);function wC(e,t){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 SC(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function OC(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),a=new Array(n),o;for(o=0;o<r;++o)i[o]=cr(e[o],t[o]);for(;o<n;++o)a[o]=t[o];return function(s){for(o=0;o<r;++o)a[o]=i[o](s);return a}}function PC(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Fa(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function MC(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=cr(e[i],t[i]):r[i]=t[i];return function(a){for(i in n)r[i]=n[i](a);return r}}var xc=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,fl=new RegExp(xc.source,"g");function AC(e){return function(){return e}}function kC(e){return function(t){return e(t)+""}}function CC(e,t){var n=xc.lastIndex=fl.lastIndex=0,r,i,a,o=-1,s=[],l=[];for(e=e+"",t=t+"";(r=xc.exec(e))&&(i=fl.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,l.push({i:o,x:Fa(r,i)})),n=fl.lastIndex;return n<t.length&&(a=t.slice(n),s[o]?s[o]+=a:s[++o]=a),s.length<2?l[0]?kC(l[0].x):AC(t):(t=l.length,function(c){for(var u=0,f;u<t;++u)s[(f=l[u]).i]=f.x(c);return s.join("")})}function cr(e,t){var n=typeof t,r;return t==null||n==="boolean"?hu(t):(n==="number"?Fa:n==="string"?(r=ti(t))?(t=r,dg):CC:t instanceof ti?dg:t instanceof Date?PC:SC(t)?wC:Array.isArray(t)?OC:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?MC:Fa)(e,t)}function pu(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function EC(e,t){t===void 0&&(t=e,e=cr);for(var n=0,r=t.length-1,i=t[0],a=new Array(r<0?0:r);n<r;)a[n]=e(i,i=t[++n]);return function(o){var s=Math.max(0,Math.min(r-1,Math.floor(o*=r)));return a[s](o-s)}}function DC(e){return function(){return e}}function Ba(e){return+e}var hg=[0,1];function ke(e){return e}function _c(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:DC(isNaN(t)?NaN:.5)}function TC(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function IC(e,t,n){var r=e[0],i=e[1],a=t[0],o=t[1];return i<r?(r=_c(i,r),a=n(o,a)):(r=_c(r,i),a=n(a,o)),function(s){return a(r(s))}}function jC(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),a=new Array(r),o=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++o<r;)i[o]=_c(e[o],e[o+1]),a[o]=n(t[o],t[o+1]);return function(s){var l=pi(e,s,1,r)-1;return a[l](i[l](s))}}function mi(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Oo(){var e=hg,t=hg,n=cr,r,i,a,o=ke,s,l,c;function u(){var d=Math.min(e.length,t.length);return o!==ke&&(o=TC(e[0],e[d-1])),s=d>2?jC:IC,l=c=null,f}function f(d){return d==null||isNaN(d=+d)?a:(l||(l=s(e.map(r),t,n)))(r(o(d)))}return f.invert=function(d){return o(i((c||(c=s(t,e.map(r),Fa)))(d)))},f.domain=function(d){return arguments.length?(e=Array.from(d,Ba),u()):e.slice()},f.range=function(d){return arguments.length?(t=Array.from(d),u()):t.slice()},f.rangeRound=function(d){return t=Array.from(d),n=pu,u()},f.clamp=function(d){return arguments.length?(o=d?!0:ke,u()):o!==ke},f.interpolate=function(d){return arguments.length?(n=d,u()):n},f.unknown=function(d){return arguments.length?(a=d,f):a},function(d,h){return r=d,i=h,u()}}function gu(){return Oo()(ke,ke)}function RC(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function za(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 er(e){return e=za(Math.abs(e)),e?e[1]:NaN}function LC(e,t){return function(n,r){for(var i=n.length,a=[],o=0,s=e[0],l=0;i>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),a.push(n.substring(i-=s,i+s)),!((l+=s+1)>r));)s=e[o=(o+1)%e.length];return a.reverse().join(t)}}function NC(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var FC=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ni(e){if(!(t=FC.exec(e)))throw new Error("invalid format: "+e);var t;return new mu({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]})}ni.prototype=mu.prototype;function mu(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+""}mu.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 BC(e){e: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 e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var $a;function zC(e,t){var n=za(e,t);if(!n)return $a=void 0,e.toPrecision(t);var r=n[0],i=n[1],a=i-($a=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,o=r.length;return a===o?r:a>o?r+new Array(a-o+1).join("0"):a>0?r.slice(0,a)+"."+r.slice(a):"0."+new Array(1-a).join("0")+za(e,Math.max(0,t+a-1))[0]}function pg(e,t){var n=za(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const gg={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:RC,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)=>pg(e*100,t),r:pg,s:zC,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function mg(e){return e}var vg=Array.prototype.map,yg=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function $C(e){var t=e.grouping===void 0||e.thousands===void 0?mg:LC(vg.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?mg:NC(vg.call(e.numerals,String)),o=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(f,d){f=ni(f);var h=f.fill,p=f.align,m=f.sign,g=f.symbol,v=f.zero,y=f.width,b=f.comma,_=f.precision,x=f.trim,S=f.type;S==="n"?(b=!0,S="g"):gg[S]||(_===void 0&&(_=12),x=!0,S="g"),(v||h==="0"&&p==="=")&&(v=!0,h="0",p="=");var O=(d&&d.prefix!==void 0?d.prefix:"")+(g==="$"?n:g==="#"&&/[boxX]/.test(S)?"0"+S.toLowerCase():""),M=(g==="$"?r:/[%p]/.test(S)?o:"")+(d&&d.suffix!==void 0?d.suffix:""),E=gg[S],j=/[defgprs%]/.test(S);_=_===void 0?6:/[gprs]/.test(S)?Math.max(1,Math.min(21,_)):Math.max(0,Math.min(20,_));function D(A){var N=O,R=M,T,L,F;if(S==="c")R=E(A)+R,A="";else{A=+A;var oe=A<0||1/A<0;if(A=isNaN(A)?l:E(Math.abs(A),_),x&&(A=BC(A)),oe&&+A==0&&m!=="+"&&(oe=!1),N=(oe?m==="("?m:s:m==="-"||m==="("?"":m)+N,R=(S==="s"&&!isNaN(A)&&$a!==void 0?yg[8+$a/3]:"")+R+(oe&&m==="("?")":""),j){for(T=-1,L=A.length;++T<L;)if(F=A.charCodeAt(T),48>F||F>57){R=(F===46?i+A.slice(T+1):A.slice(T))+R,A=A.slice(0,T);break}}}b&&!v&&(A=t(A,1/0));var J=N.length+A.length+R.length,U=J<y?new Array(y-J+1).join(h):"";switch(b&&v&&(A=t(U+A,U.length?y-R.length:1/0),U=""),p){case"<":A=N+A+R+U;break;case"=":A=N+U+A+R;break;case"^":A=U.slice(0,J=U.length>>1)+N+A+R+U.slice(J);break;default:A=U+N+A+R;break}return a(A)}return D.toString=function(){return f+""},D}function u(f,d){var h=Math.max(-8,Math.min(8,Math.floor(er(d)/3)))*3,p=Math.pow(10,-h),m=c((f=ni(f),f.type="f",f),{suffix:yg[8+h/3]});return function(g){return m(p*g)}}return{format:c,formatPrefix:u}}var Zi,vu,Hy;WC({thousands:",",grouping:[3],currency:["$",""]});function WC(e){return Zi=$C(e),vu=Zi.format,Hy=Zi.formatPrefix,Zi}function qC(e){return Math.max(0,-er(Math.abs(e)))}function UC(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(er(t)/3)))*3-er(Math.abs(e)))}function VC(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,er(t)-er(e))+1}function Ky(e,t,n,r){var i=vc(e,t,n),a;switch(r=ni(r??",f"),r.type){case"s":{var o=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(a=UC(i,o))&&(r.precision=a),Hy(r,o)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(a=VC(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=a-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(a=qC(i))&&(r.precision=a-(r.type==="%")*2);break}}return vu(r)}function nn(e){var t=e.domain;return e.ticks=function(n){var r=t();return gc(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return Ky(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,a=r.length-1,o=r[i],s=r[a],l,c,u=10;for(s<o&&(c=o,o=s,s=c,c=i,i=a,a=c);u-- >0;){if(c=mc(o,s,n),c===l)return r[i]=o,r[a]=s,t(r);if(c>0)o=Math.floor(o/c)*c,s=Math.ceil(s/c)*c;else if(c<0)o=Math.ceil(o*c)/c,s=Math.floor(s*c)/c;else break;l=c}return e},e}function Yy(){var e=gu();return e.copy=function(){return mi(e,Yy())},tt.apply(e,arguments),nn(e)}function Xy(e){var t;function n(r){return r==null||isNaN(r=+r)?t:r}return n.invert=n,n.domain=n.range=function(r){return arguments.length?(e=Array.from(r,Ba),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return Xy(e).unknown(t)},e=arguments.length?Array.from(e,Ba):[0,1],nn(n)}function Gy(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 bg(e){return Math.log(e)}function xg(e){return Math.exp(e)}function HC(e){return-Math.log(-e)}function KC(e){return-Math.exp(-e)}function YC(e){return isFinite(e)?+("1e"+e):e<0?0:e}function XC(e){return e===10?YC:e===Math.E?Math.exp:t=>Math.pow(e,t)}function GC(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 _g(e){return(t,n)=>-e(-t,n)}function yu(e){const t=e(bg,xg),n=t.domain;let r=10,i,a;function o(){return i=GC(r),a=XC(r),n()[0]<0?(i=_g(i),a=_g(a),e(HC,KC)):e(bg,xg),t}return t.base=function(s){return arguments.length?(r=+s,o()):r},t.domain=function(s){return arguments.length?(n(s),o()):n()},t.ticks=s=>{const l=n();let c=l[0],u=l[l.length-1];const f=u<c;f&&([c,u]=[u,c]);let d=i(c),h=i(u),p,m;const g=s==null?10:+s;let v=[];if(!(r%1)&&h-d<g){if(d=Math.floor(d),h=Math.ceil(h),c>0){for(;d<=h;++d)for(p=1;p<r;++p)if(m=d<0?p/a(-d):p*a(d),!(m<c)){if(m>u)break;v.push(m)}}else for(;d<=h;++d)for(p=r-1;p>=1;--p)if(m=d>0?p/a(-d):p*a(d),!(m<c)){if(m>u)break;v.push(m)}v.length*2<g&&(v=gc(c,u,g))}else v=gc(d,h,Math.min(h-d,g)).map(a);return f?v.reverse():v},t.tickFormat=(s,l)=>{if(s==null&&(s=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=ni(l)).precision==null&&(l.trim=!0),l=vu(l)),s===1/0)return l;const c=Math.max(1,r*s/t.ticks().length);return u=>{let f=u/a(Math.round(i(u)));return f*r<r-.5&&(f*=r),f<=c?l(u):""}},t.nice=()=>n(Gy(n(),{floor:s=>a(Math.floor(i(s))),ceil:s=>a(Math.ceil(i(s)))})),t}function Zy(){const e=yu(Oo()).domain([1,10]);return e.copy=()=>mi(e,Zy()).base(e.base()),tt.apply(e,arguments),e}function wg(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function Sg(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function bu(e){var t=1,n=e(wg(t),Sg(t));return n.constant=function(r){return arguments.length?e(wg(t=+r),Sg(t)):t},nn(n)}function Qy(){var e=bu(Oo());return e.copy=function(){return mi(e,Qy()).constant(e.constant())},tt.apply(e,arguments)}function Og(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function ZC(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function QC(e){return e<0?-e*e:e*e}function xu(e){var t=e(ke,ke),n=1;function r(){return n===1?e(ke,ke):n===.5?e(ZC,QC):e(Og(n),Og(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},nn(t)}function _u(){var e=xu(Oo());return e.copy=function(){return mi(e,_u()).exponent(e.exponent())},tt.apply(e,arguments),e}function JC(){return _u.apply(null,arguments).exponent(.5)}function Pg(e){return Math.sign(e)*e*e}function eE(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function Jy(){var e=gu(),t=[0,1],n=!1,r;function i(a){var o=eE(e(a));return isNaN(o)?r:n?Math.round(o):o}return i.invert=function(a){return e.invert(Pg(a))},i.domain=function(a){return arguments.length?(e.domain(a),i):e.domain()},i.range=function(a){return arguments.length?(e.range((t=Array.from(a,Ba)).map(Pg)),i):t.slice()},i.rangeRound=function(a){return i.range(a).round(!0)},i.round=function(a){return arguments.length?(n=!!a,i):n},i.clamp=function(a){return arguments.length?(e.clamp(a),i):e.clamp()},i.unknown=function(a){return arguments.length?(r=a,i):r},i.copy=function(){return Jy(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},tt.apply(i,arguments),nn(i)}function e0(){var e=[],t=[],n=[],r;function i(){var o=0,s=Math.max(1,t.length);for(n=new Array(s-1);++o<s;)n[o-1]=iC(e,o/s);return a}function a(o){return o==null||isNaN(o=+o)?r:t[pi(n,o)]}return a.invertExtent=function(o){var s=t.indexOf(o);return s<0?[NaN,NaN]:[s>0?n[s-1]:e[0],s<n.length?n[s]:e[e.length-1]]},a.domain=function(o){if(!arguments.length)return e.slice();e=[];for(let s of o)s!=null&&!isNaN(s=+s)&&e.push(s);return e.sort(Ht),i()},a.range=function(o){return arguments.length?(t=Array.from(o),i()):t.slice()},a.unknown=function(o){return arguments.length?(r=o,a):r},a.quantiles=function(){return n.slice()},a.copy=function(){return e0().domain(e).range(t).unknown(r)},tt.apply(a,arguments)}function t0(){var e=0,t=1,n=1,r=[.5],i=[0,1],a;function o(l){return l!=null&&l<=l?i[pi(r,l,0,n)]:a}function s(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return o}return o.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,s()):[e,t]},o.range=function(l){return arguments.length?(n=(i=Array.from(l)).length-1,s()):i.slice()},o.invertExtent=function(l){var c=i.indexOf(l);return c<0?[NaN,NaN]:c<1?[e,r[0]]:c>=n?[r[n-1],t]:[r[c-1],r[c]]},o.unknown=function(l){return arguments.length&&(a=l),o},o.thresholds=function(){return r.slice()},o.copy=function(){return t0().domain([e,t]).range(i).unknown(a)},tt.apply(nn(o),arguments)}function n0(){var e=[.5],t=[0,1],n,r=1;function i(a){return a!=null&&a<=a?t[pi(e,a,0,r)]:n}return i.domain=function(a){return arguments.length?(e=Array.from(a),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(a){return arguments.length?(t=Array.from(a),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(a){var o=t.indexOf(a);return[e[o-1],e[o]]},i.unknown=function(a){return arguments.length?(n=a,i):n},i.copy=function(){return n0().domain(e).range(t).unknown(n)},tt.apply(i,arguments)}const dl=new Date,hl=new Date;function he(e,t,n,r){function i(a){return e(a=arguments.length===0?new Date:new Date(+a)),a}return i.floor=a=>(e(a=new Date(+a)),a),i.ceil=a=>(e(a=new Date(a-1)),t(a,1),e(a),a),i.round=a=>{const o=i(a),s=i.ceil(a);return a-o<s-a?o:s},i.offset=(a,o)=>(t(a=new Date(+a),o==null?1:Math.floor(o)),a),i.range=(a,o,s)=>{const l=[];if(a=i.ceil(a),s=s==null?1:Math.floor(s),!(a<o)||!(s>0))return l;let c;do l.push(c=new Date(+a)),t(a,s),e(a);while(c<a&&a<o);return l},i.filter=a=>he(o=>{if(o>=o)for(;e(o),!a(o);)o.setTime(o-1)},(o,s)=>{if(o>=o)if(s<0)for(;++s<=0;)for(;t(o,-1),!a(o););else for(;--s>=0;)for(;t(o,1),!a(o););}),n&&(i.count=(a,o)=>(dl.setTime(+a),hl.setTime(+o),e(dl),e(hl),Math.floor(n(dl,hl))),i.every=a=>(a=Math.floor(a),!isFinite(a)||!(a>0)?null:a>1?i.filter(r?o=>r(o)%a===0:o=>i.count(0,o)%a===0):i)),i}const Wa=he(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Wa.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?he(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Wa);Wa.range;const At=1e3,Ge=At*60,kt=Ge*60,Dt=kt*24,wu=Dt*7,Mg=Dt*30,pl=Dt*365,_n=he(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*At)},(e,t)=>(t-e)/At,e=>e.getUTCSeconds());_n.range;const Su=he(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*At)},(e,t)=>{e.setTime(+e+t*Ge)},(e,t)=>(t-e)/Ge,e=>e.getMinutes());Su.range;const Ou=he(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Ge)},(e,t)=>(t-e)/Ge,e=>e.getUTCMinutes());Ou.range;const Pu=he(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*At-e.getMinutes()*Ge)},(e,t)=>{e.setTime(+e+t*kt)},(e,t)=>(t-e)/kt,e=>e.getHours());Pu.range;const Mu=he(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*kt)},(e,t)=>(t-e)/kt,e=>e.getUTCHours());Mu.range;const vi=he(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Ge)/Dt,e=>e.getDate()-1);vi.range;const Po=he(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Dt,e=>e.getUTCDate()-1);Po.range;const r0=he(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Dt,e=>Math.floor(e/Dt));r0.range;function Rn(e){return he(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*Ge)/wu)}const Mo=Rn(0),qa=Rn(1),tE=Rn(2),nE=Rn(3),tr=Rn(4),rE=Rn(5),iE=Rn(6);Mo.range;qa.range;tE.range;nE.range;tr.range;rE.range;iE.range;function Ln(e){return he(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/wu)}const Ao=Ln(0),Ua=Ln(1),aE=Ln(2),oE=Ln(3),nr=Ln(4),sE=Ln(5),lE=Ln(6);Ao.range;Ua.range;aE.range;oE.range;nr.range;sE.range;lE.range;const Au=he(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());Au.range;const ku=he(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());ku.range;const Tt=he(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());Tt.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:he(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)});Tt.range;const It=he(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());It.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:he(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)});It.range;function i0(e,t,n,r,i,a){const o=[[_n,1,At],[_n,5,5*At],[_n,15,15*At],[_n,30,30*At],[a,1,Ge],[a,5,5*Ge],[a,15,15*Ge],[a,30,30*Ge],[i,1,kt],[i,3,3*kt],[i,6,6*kt],[i,12,12*kt],[r,1,Dt],[r,2,2*Dt],[n,1,wu],[t,1,Mg],[t,3,3*Mg],[e,1,pl]];function s(c,u,f){const d=u<c;d&&([c,u]=[u,c]);const h=f&&typeof f.range=="function"?f:l(c,u,f),p=h?h.range(c,+u+1):[];return d?p.reverse():p}function l(c,u,f){const d=Math.abs(u-c)/f,h=cu(([,,g])=>g).right(o,d);if(h===o.length)return e.every(vc(c/pl,u/pl,f));if(h===0)return Wa.every(Math.max(vc(c,u,f),1));const[p,m]=o[d/o[h-1][2]<o[h][2]/d?h-1:h];return p.every(m)}return[s,l]}const[cE,uE]=i0(It,ku,Ao,r0,Mu,Ou),[fE,dE]=i0(Tt,Au,Mo,vi,Pu,Su);function gl(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 ml(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 kr(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function hE(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,a=e.days,o=e.shortDays,s=e.months,l=e.shortMonths,c=Cr(i),u=Er(i),f=Cr(a),d=Er(a),h=Cr(o),p=Er(o),m=Cr(s),g=Er(s),v=Cr(l),y=Er(l),b={a:F,A:oe,b:J,B:U,c:null,d:Tg,e:Tg,f:LE,g:HE,G:YE,H:IE,I:jE,j:RE,L:a0,m:NE,M:FE,p:Me,q:se,Q:Rg,s:Lg,S:BE,u:zE,U:$E,V:WE,w:qE,W:UE,x:null,X:null,y:VE,Y:KE,Z:XE,"%":jg},_={a:_e,A:re,b:we,B:Se,c:null,d:Ig,e:Ig,f:JE,g:cD,G:fD,H:GE,I:ZE,j:QE,L:s0,m:eD,M:tD,p:De,q:$o,Q:Rg,s:Lg,S:nD,u:rD,U:iD,V:aD,w:oD,W:sD,x:null,X:null,y:lD,Y:uD,Z:dD,"%":jg},x={a:j,A:D,b:A,B:N,c:R,d:Eg,e:Eg,f:CE,g:Cg,G:kg,H:Dg,I:Dg,j:PE,L:kE,m:OE,M:ME,p:E,q:SE,Q:DE,s:TE,S:AE,u:yE,U:bE,V:xE,w:vE,W:_E,x:T,X:L,y:Cg,Y:kg,Z:wE,"%":EE};b.x=S(n,b),b.X=S(r,b),b.c=S(t,b),_.x=S(n,_),_.X=S(r,_),_.c=S(t,_);function S(k,B){return function(W){var C=[],Te=-1,Z=0,Fe=k.length,Be,ln,df;for(W instanceof Date||(W=new Date(+W));++Te<Fe;)k.charCodeAt(Te)===37&&(C.push(k.slice(Z,Te)),(ln=Ag[Be=k.charAt(++Te)])!=null?Be=k.charAt(++Te):ln=Be==="e"?" ":"0",(df=B[Be])&&(Be=df(W,ln)),C.push(Be),Z=Te+1);return C.push(k.slice(Z,Te)),C.join("")}}function O(k,B){return function(W){var C=kr(1900,void 0,1),Te=M(C,k,W+="",0),Z,Fe;if(Te!=W.length)return null;if("Q"in C)return new Date(C.Q);if("s"in C)return new Date(C.s*1e3+("L"in C?C.L:0));if(B&&!("Z"in C)&&(C.Z=0),"p"in C&&(C.H=C.H%12+C.p*12),C.m===void 0&&(C.m="q"in C?C.q:0),"V"in C){if(C.V<1||C.V>53)return null;"w"in C||(C.w=1),"Z"in C?(Z=ml(kr(C.y,0,1)),Fe=Z.getUTCDay(),Z=Fe>4||Fe===0?Ua.ceil(Z):Ua(Z),Z=Po.offset(Z,(C.V-1)*7),C.y=Z.getUTCFullYear(),C.m=Z.getUTCMonth(),C.d=Z.getUTCDate()+(C.w+6)%7):(Z=gl(kr(C.y,0,1)),Fe=Z.getDay(),Z=Fe>4||Fe===0?qa.ceil(Z):qa(Z),Z=vi.offset(Z,(C.V-1)*7),C.y=Z.getFullYear(),C.m=Z.getMonth(),C.d=Z.getDate()+(C.w+6)%7)}else("W"in C||"U"in C)&&("w"in C||(C.w="u"in C?C.u%7:"W"in C?1:0),Fe="Z"in C?ml(kr(C.y,0,1)).getUTCDay():gl(kr(C.y,0,1)).getDay(),C.m=0,C.d="W"in C?(C.w+6)%7+C.W*7-(Fe+5)%7:C.w+C.U*7-(Fe+6)%7);return"Z"in C?(C.H+=C.Z/100|0,C.M+=C.Z%100,ml(C)):gl(C)}}function M(k,B,W,C){for(var Te=0,Z=B.length,Fe=W.length,Be,ln;Te<Z;){if(C>=Fe)return-1;if(Be=B.charCodeAt(Te++),Be===37){if(Be=B.charAt(Te++),ln=x[Be in Ag?B.charAt(Te++):Be],!ln||(C=ln(k,W,C))<0)return-1}else if(Be!=W.charCodeAt(C++))return-1}return C}function E(k,B,W){var C=c.exec(B.slice(W));return C?(k.p=u.get(C[0].toLowerCase()),W+C[0].length):-1}function j(k,B,W){var C=h.exec(B.slice(W));return C?(k.w=p.get(C[0].toLowerCase()),W+C[0].length):-1}function D(k,B,W){var C=f.exec(B.slice(W));return C?(k.w=d.get(C[0].toLowerCase()),W+C[0].length):-1}function A(k,B,W){var C=v.exec(B.slice(W));return C?(k.m=y.get(C[0].toLowerCase()),W+C[0].length):-1}function N(k,B,W){var C=m.exec(B.slice(W));return C?(k.m=g.get(C[0].toLowerCase()),W+C[0].length):-1}function R(k,B,W){return M(k,t,B,W)}function T(k,B,W){return M(k,n,B,W)}function L(k,B,W){return M(k,r,B,W)}function F(k){return o[k.getDay()]}function oe(k){return a[k.getDay()]}function J(k){return l[k.getMonth()]}function U(k){return s[k.getMonth()]}function Me(k){return i[+(k.getHours()>=12)]}function se(k){return 1+~~(k.getMonth()/3)}function _e(k){return o[k.getUTCDay()]}function re(k){return a[k.getUTCDay()]}function we(k){return l[k.getUTCMonth()]}function Se(k){return s[k.getUTCMonth()]}function De(k){return i[+(k.getUTCHours()>=12)]}function $o(k){return 1+~~(k.getUTCMonth()/3)}return{format:function(k){var B=S(k+="",b);return B.toString=function(){return k},B},parse:function(k){var B=O(k+="",!1);return B.toString=function(){return k},B},utcFormat:function(k){var B=S(k+="",_);return B.toString=function(){return k},B},utcParse:function(k){var B=O(k+="",!0);return B.toString=function(){return k},B}}}var Ag={"-":"",_:" ",0:"0"},ye=/^\s*\d+/,pE=/^%/,gE=/[\\^$*+?|[\]().{}]/g;function q(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",a=i.length;return r+(a<n?new Array(n-a+1).join(t)+i:i)}function mE(e){return e.replace(gE,"\\$&")}function Cr(e){return new RegExp("^(?:"+e.map(mE).join("|")+")","i")}function Er(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function vE(e,t,n){var r=ye.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function yE(e,t,n){var r=ye.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function bE(e,t,n){var r=ye.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function xE(e,t,n){var r=ye.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function _E(e,t,n){var r=ye.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function kg(e,t,n){var r=ye.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function Cg(e,t,n){var r=ye.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function wE(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 SE(e,t,n){var r=ye.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function OE(e,t,n){var r=ye.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Eg(e,t,n){var r=ye.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function PE(e,t,n){var r=ye.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Dg(e,t,n){var r=ye.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function ME(e,t,n){var r=ye.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function AE(e,t,n){var r=ye.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function kE(e,t,n){var r=ye.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function CE(e,t,n){var r=ye.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function EE(e,t,n){var r=pE.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function DE(e,t,n){var r=ye.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function TE(e,t,n){var r=ye.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function Tg(e,t){return q(e.getDate(),t,2)}function IE(e,t){return q(e.getHours(),t,2)}function jE(e,t){return q(e.getHours()%12||12,t,2)}function RE(e,t){return q(1+vi.count(Tt(e),e),t,3)}function a0(e,t){return q(e.getMilliseconds(),t,3)}function LE(e,t){return a0(e,t)+"000"}function NE(e,t){return q(e.getMonth()+1,t,2)}function FE(e,t){return q(e.getMinutes(),t,2)}function BE(e,t){return q(e.getSeconds(),t,2)}function zE(e){var t=e.getDay();return t===0?7:t}function $E(e,t){return q(Mo.count(Tt(e)-1,e),t,2)}function o0(e){var t=e.getDay();return t>=4||t===0?tr(e):tr.ceil(e)}function WE(e,t){return e=o0(e),q(tr.count(Tt(e),e)+(Tt(e).getDay()===4),t,2)}function qE(e){return e.getDay()}function UE(e,t){return q(qa.count(Tt(e)-1,e),t,2)}function VE(e,t){return q(e.getFullYear()%100,t,2)}function HE(e,t){return e=o0(e),q(e.getFullYear()%100,t,2)}function KE(e,t){return q(e.getFullYear()%1e4,t,4)}function YE(e,t){var n=e.getDay();return e=n>=4||n===0?tr(e):tr.ceil(e),q(e.getFullYear()%1e4,t,4)}function XE(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+q(t/60|0,"0",2)+q(t%60,"0",2)}function Ig(e,t){return q(e.getUTCDate(),t,2)}function GE(e,t){return q(e.getUTCHours(),t,2)}function ZE(e,t){return q(e.getUTCHours()%12||12,t,2)}function QE(e,t){return q(1+Po.count(It(e),e),t,3)}function s0(e,t){return q(e.getUTCMilliseconds(),t,3)}function JE(e,t){return s0(e,t)+"000"}function eD(e,t){return q(e.getUTCMonth()+1,t,2)}function tD(e,t){return q(e.getUTCMinutes(),t,2)}function nD(e,t){return q(e.getUTCSeconds(),t,2)}function rD(e){var t=e.getUTCDay();return t===0?7:t}function iD(e,t){return q(Ao.count(It(e)-1,e),t,2)}function l0(e){var t=e.getUTCDay();return t>=4||t===0?nr(e):nr.ceil(e)}function aD(e,t){return e=l0(e),q(nr.count(It(e),e)+(It(e).getUTCDay()===4),t,2)}function oD(e){return e.getUTCDay()}function sD(e,t){return q(Ua.count(It(e)-1,e),t,2)}function lD(e,t){return q(e.getUTCFullYear()%100,t,2)}function cD(e,t){return e=l0(e),q(e.getUTCFullYear()%100,t,2)}function uD(e,t){return q(e.getUTCFullYear()%1e4,t,4)}function fD(e,t){var n=e.getUTCDay();return e=n>=4||n===0?nr(e):nr.ceil(e),q(e.getUTCFullYear()%1e4,t,4)}function dD(){return"+0000"}function jg(){return"%"}function Rg(e){return+e}function Lg(e){return Math.floor(+e/1e3)}var Bn,c0,u0;hD({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 hD(e){return Bn=hE(e),c0=Bn.format,Bn.parse,u0=Bn.utcFormat,Bn.utcParse,Bn}function pD(e){return new Date(e)}function gD(e){return e instanceof Date?+e:+new Date(+e)}function Cu(e,t,n,r,i,a,o,s,l,c){var u=gu(),f=u.invert,d=u.domain,h=c(".%L"),p=c(":%S"),m=c("%I:%M"),g=c("%I %p"),v=c("%a %d"),y=c("%b %d"),b=c("%B"),_=c("%Y");function x(S){return(l(S)<S?h:s(S)<S?p:o(S)<S?m:a(S)<S?g:r(S)<S?i(S)<S?v:y:n(S)<S?b:_)(S)}return u.invert=function(S){return new Date(f(S))},u.domain=function(S){return arguments.length?d(Array.from(S,gD)):d().map(pD)},u.ticks=function(S){var O=d();return e(O[0],O[O.length-1],S??10)},u.tickFormat=function(S,O){return O==null?x:c(O)},u.nice=function(S){var O=d();return(!S||typeof S.range!="function")&&(S=t(O[0],O[O.length-1],S??10)),S?d(Gy(O,S)):u},u.copy=function(){return mi(u,Cu(e,t,n,r,i,a,o,s,l,c))},u}function mD(){return tt.apply(Cu(fE,dE,Tt,Au,Mo,vi,Pu,Su,_n,c0).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function vD(){return tt.apply(Cu(cE,uE,It,ku,Ao,Po,Mu,Ou,_n,u0).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function ko(){var e=0,t=1,n,r,i,a,o=ke,s=!1,l;function c(f){return f==null||isNaN(f=+f)?l:o(i===0?.5:(f=(a(f)-n)*i,s?Math.max(0,Math.min(1,f)):f))}c.domain=function(f){return arguments.length?([e,t]=f,n=a(e=+e),r=a(t=+t),i=n===r?0:1/(r-n),c):[e,t]},c.clamp=function(f){return arguments.length?(s=!!f,c):s},c.interpolator=function(f){return arguments.length?(o=f,c):o};function u(f){return function(d){var h,p;return arguments.length?([h,p]=d,o=f(h,p),c):[o(0),o(1)]}}return c.range=u(cr),c.rangeRound=u(pu),c.unknown=function(f){return arguments.length?(l=f,c):l},function(f){return a=f,n=f(e),r=f(t),i=n===r?0:1/(r-n),c}}function rn(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function f0(){var e=nn(ko()(ke));return e.copy=function(){return rn(e,f0())},Lt.apply(e,arguments)}function d0(){var e=yu(ko()).domain([1,10]);return e.copy=function(){return rn(e,d0()).base(e.base())},Lt.apply(e,arguments)}function h0(){var e=bu(ko());return e.copy=function(){return rn(e,h0()).constant(e.constant())},Lt.apply(e,arguments)}function Eu(){var e=xu(ko());return e.copy=function(){return rn(e,Eu()).exponent(e.exponent())},Lt.apply(e,arguments)}function yD(){return Eu.apply(null,arguments).exponent(.5)}function p0(){var e=[],t=ke;function n(r){if(r!=null&&!isNaN(r=+r))return t((pi(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let i of r)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(Ht),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,i)=>t(i/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(i,a)=>rC(e,a/r))},n.copy=function(){return p0(t).domain(e)},Lt.apply(n,arguments)}function Co(){var e=0,t=.5,n=1,r=1,i,a,o,s,l,c=ke,u,f=!1,d;function h(m){return isNaN(m=+m)?d:(m=.5+((m=+u(m))-a)*(r*m<r*a?s:l),c(f?Math.max(0,Math.min(1,m)):m))}h.domain=function(m){return arguments.length?([e,t,n]=m,i=u(e=+e),a=u(t=+t),o=u(n=+n),s=i===a?0:.5/(a-i),l=a===o?0:.5/(o-a),r=a<i?-1:1,h):[e,t,n]},h.clamp=function(m){return arguments.length?(f=!!m,h):f},h.interpolator=function(m){return arguments.length?(c=m,h):c};function p(m){return function(g){var v,y,b;return arguments.length?([v,y,b]=g,c=EC(m,[v,y,b]),h):[c(0),c(.5),c(1)]}}return h.range=p(cr),h.rangeRound=p(pu),h.unknown=function(m){return arguments.length?(d=m,h):d},function(m){return u=m,i=m(e),a=m(t),o=m(n),s=i===a?0:.5/(a-i),l=a===o?0:.5/(o-a),r=a<i?-1:1,h}}function g0(){var e=nn(Co()(ke));return e.copy=function(){return rn(e,g0())},Lt.apply(e,arguments)}function m0(){var e=yu(Co()).domain([.1,1,10]);return e.copy=function(){return rn(e,m0()).base(e.base())},Lt.apply(e,arguments)}function v0(){var e=bu(Co());return e.copy=function(){return rn(e,v0()).constant(e.constant())},Lt.apply(e,arguments)}function Du(){var e=xu(Co());return e.copy=function(){return rn(e,Du()).exponent(e.exponent())},Lt.apply(e,arguments)}function bD(){return Du.apply(null,arguments).exponent(.5)}const Rr=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:fu,scaleDiverging:g0,scaleDivergingLog:m0,scaleDivergingPow:Du,scaleDivergingSqrt:bD,scaleDivergingSymlog:v0,scaleIdentity:Xy,scaleImplicit:yc,scaleLinear:Yy,scaleLog:Zy,scaleOrdinal:uu,scalePoint:oC,scalePow:_u,scaleQuantile:e0,scaleQuantize:t0,scaleRadial:Jy,scaleSequential:f0,scaleSequentialLog:d0,scaleSequentialPow:Eu,scaleSequentialQuantile:p0,scaleSequentialSqrt:yD,scaleSequentialSymlog:h0,scaleSqrt:JC,scaleSymlog:Qy,scaleThreshold:n0,scaleTime:mD,scaleUtc:vD,tickFormat:Ky},Symbol.toStringTag,{value:"Module"}));var an=e=>e.chartData,xD=P([an],e=>{var t=e.chartData!=null?e.chartData.length-1:0;return{chartData:e.chartData,computedData:e.computedData,dataEndIndex:t,dataStartIndex:0}}),y0=(e,t,n,r)=>r?xD(e):an(e);function jt(e){if(Array.isArray(e)&&e.length===2){var[t,n]=e;if(Q(t)&&Q(n))return!0}return!1}function Ng(e,t,n){return n?e:[Math.min(e[0],t[0]),Math.max(e[1],t[1])]}function b0(e,t){if(t&&typeof e!="function"&&Array.isArray(e)&&e.length===2){var[n,r]=e,i,a;if(Q(n))i=n;else if(typeof n=="function")return;if(Q(r))a=r;else if(typeof r=="function")return;var o=[i,a];if(jt(o))return o}}function _D(e,t,n){if(!(!n&&t==null)){if(typeof e=="function"&&t!=null)try{var r=e(t,n);if(jt(r))return Ng(r,t,n)}catch{}if(Array.isArray(e)&&e.length===2){var[i,a]=e,o,s;if(i==="auto")t!=null&&(o=Math.min(...t));else if(z(i))o=i;else if(typeof i=="function")try{t!=null&&(o=i(t?.[0]))}catch{}else if(typeof i=="string"&&Kh.test(i)){var l=Kh.exec(i);if(l==null||l[1]==null||t==null)o=void 0;else{var c=+l[1];o=t[0]-c}}else o=t?.[0];if(a==="auto")t!=null&&(s=Math.max(...t));else if(z(a))s=a;else if(typeof a=="function")try{t!=null&&(s=a(t?.[1]))}catch{}else if(typeof a=="string"&&Yh.test(a)){var u=Yh.exec(a);if(u==null||u[1]==null||t==null)s=void 0;else{var f=+u[1];s=t[1]+f}}else s=t?.[1];var d=[o,s];if(jt(d))return t==null?d:Ng(d,t,n)}}}var ur=1e9,wD={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},Iu,ne=!0,et="[DecimalError] ",Mn=et+"Invalid argument: ",Tu=et+"Exponent out of range: ",fr=Math.floor,vn=Math.pow,SD=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,ze,ge=1e7,ee=7,x0=9007199254740991,Va=fr(x0/ee),I={};I.absoluteValue=I.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};I.comparedTo=I.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};I.decimalPlaces=I.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*ee;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};I.dividedBy=I.div=function(e){return Ct(this,new this.constructor(e))};I.dividedToIntegerBy=I.idiv=function(e){var t=this,n=t.constructor;return G(Ct(t,new n(e),0,1),n.precision)};I.equals=I.eq=function(e){return!this.cmp(e)};I.exponent=function(){return ue(this)};I.greaterThan=I.gt=function(e){return this.cmp(e)>0};I.greaterThanOrEqualTo=I.gte=function(e){return this.cmp(e)>=0};I.isInteger=I.isint=function(){return this.e>this.d.length-2};I.isNegative=I.isneg=function(){return this.s<0};I.isPositive=I.ispos=function(){return this.s>0};I.isZero=function(){return this.s===0};I.lessThan=I.lt=function(e){return this.cmp(e)<0};I.lessThanOrEqualTo=I.lte=function(e){return this.cmp(e)<1};I.logarithm=I.log=function(e){var t,n=this,r=n.constructor,i=r.precision,a=i+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(ze))throw Error(et+"NaN");if(n.s<1)throw Error(et+(n.s?"NaN":"-Infinity"));return n.eq(ze)?new r(0):(ne=!1,t=Ct(ri(n,a),ri(e,a),a),ne=!0,G(t,i))};I.minus=I.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?S0(t,e):_0(t,(e.s=-e.s,e))};I.modulo=I.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(et+"NaN");return n.s?(ne=!1,t=Ct(n,e,0,1).times(e),ne=!0,n.minus(t)):G(new r(n),i)};I.naturalExponential=I.exp=function(){return w0(this)};I.naturalLogarithm=I.ln=function(){return ri(this)};I.negated=I.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};I.plus=I.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?_0(t,e):S0(t,(e.s=-e.s,e))};I.precision=I.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Mn+e);if(t=ue(i)+1,r=i.d.length-1,n=r*ee+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};I.squareRoot=I.sqrt=function(){var e,t,n,r,i,a,o,s=this,l=s.constructor;if(s.s<1){if(!s.s)return new l(0);throw Error(et+"NaN")}for(e=ue(s),ne=!1,i=Math.sqrt(+s),i==0||i==1/0?(t=mt(s.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=fr((e+1)/2)-(e<0||e%2),i==1/0?t="5e"+e:(t=i.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),r=new l(t)):r=new l(i.toString()),n=l.precision,i=o=n+3;;)if(a=r,r=a.plus(Ct(s,a,o+2)).times(.5),mt(a.d).slice(0,o)===(t=mt(r.d)).slice(0,o)){if(t=t.slice(o-3,o+1),i==o&&t=="4999"){if(G(a,n+1,0),a.times(a).eq(s)){r=a;break}}else if(t!="9999")break;o+=4}return ne=!0,G(r,n)};I.times=I.mul=function(e){var t,n,r,i,a,o,s,l,c,u=this,f=u.constructor,d=u.d,h=(e=new f(e)).d;if(!u.s||!e.s)return new f(0);for(e.s*=u.s,n=u.e+e.e,l=d.length,c=h.length,l<c&&(a=d,d=h,h=a,o=l,l=c,c=o),a=[],o=l+c,r=o;r--;)a.push(0);for(r=c;--r>=0;){for(t=0,i=l+r;i>r;)s=a[i]+h[r]*d[i-r-1]+t,a[i--]=s%ge|0,t=s/ge|0;a[i]=(a[i]+t)%ge|0}for(;!a[--o];)a.pop();return t?++n:a.shift(),e.d=a,e.e=n,ne?G(e,f.precision):e};I.toDecimalPlaces=I.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(xt(e,0,ur),t===void 0?t=r.rounding:xt(t,0,8),G(n,e+ue(n)+1,t))};I.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=In(r,!0):(xt(e,0,ur),t===void 0?t=i.rounding:xt(t,0,8),r=G(new i(r),e+1,t),n=In(r,!0,e+1)),n};I.toFixed=function(e,t){var n,r,i=this,a=i.constructor;return e===void 0?In(i):(xt(e,0,ur),t===void 0?t=a.rounding:xt(t,0,8),r=G(new a(i),e+ue(i)+1,t),n=In(r.abs(),!1,e+ue(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)};I.toInteger=I.toint=function(){var e=this,t=e.constructor;return G(new t(e),ue(e)+1,t.rounding)};I.toNumber=function(){return+this};I.toPower=I.pow=function(e){var t,n,r,i,a,o,s=this,l=s.constructor,c=12,u=+(e=new l(e));if(!e.s)return new l(ze);if(s=new l(s),!s.s){if(e.s<1)throw Error(et+"Infinity");return s}if(s.eq(ze))return s;if(r=l.precision,e.eq(ze))return G(s,r);if(t=e.e,n=e.d.length-1,o=t>=n,a=s.s,o){if((n=u<0?-u:u)<=x0){for(i=new l(ze),t=Math.ceil(r/ee+4),ne=!1;n%2&&(i=i.times(s),Bg(i.d,t)),n=fr(n/2),n!==0;)s=s.times(s),Bg(s.d,t);return ne=!0,e.s<0?new l(ze).div(i):G(i,r)}}else if(a<0)throw Error(et+"NaN");return a=a<0&&e.d[Math.max(t,n)]&1?-1:1,s.s=1,ne=!1,i=e.times(ri(s,r+c)),ne=!0,i=w0(i),i.s=a,i};I.toPrecision=function(e,t){var n,r,i=this,a=i.constructor;return e===void 0?(n=ue(i),r=In(i,n<=a.toExpNeg||n>=a.toExpPos)):(xt(e,1,ur),t===void 0?t=a.rounding:xt(t,0,8),i=G(new a(i),e,t),n=ue(i),r=In(i,e<=n||n<=a.toExpNeg,e)),r};I.toSignificantDigits=I.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(xt(e,1,ur),t===void 0?t=r.rounding:xt(t,0,8)),G(new r(n),e,t)};I.toString=I.valueOf=I.val=I.toJSON=I[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=ue(e),n=e.constructor;return In(e,t<=n.toExpNeg||t>=n.toExpPos)};function _0(e,t){var n,r,i,a,o,s,l,c,u=e.constructor,f=u.precision;if(!e.s||!t.s)return t.s||(t=new u(e)),ne?G(t,f):t;if(l=e.d,c=t.d,o=e.e,i=t.e,l=l.slice(),a=o-i,a){for(a<0?(r=l,a=-a,s=c.length):(r=c,i=o,s=l.length),o=Math.ceil(f/ee),s=o>s?o+1:s+1,a>s&&(a=s,r.length=1),r.reverse();a--;)r.push(0);r.reverse()}for(s=l.length,a=c.length,s-a<0&&(a=s,r=c,c=l,l=r),n=0;a;)n=(l[--a]=l[a]+c[a]+n)/ge|0,l[a]%=ge;for(n&&(l.unshift(n),++i),s=l.length;l[--s]==0;)l.pop();return t.d=l,t.e=i,ne?G(t,f):t}function xt(e,t,n){if(e!==~~e||e<t||e>n)throw Error(Mn+e)}function mt(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=ee-r.length,n&&(a+=Bt(n)),a+=r;o=e[t],r=o+"",n=ee-r.length,n&&(a+=Bt(n))}else if(o===0)return"0";for(;o%10===0;)o/=10;return a+o}var Ct=(function(){function e(r,i){var a,o=0,s=r.length;for(r=r.slice();s--;)a=r[s]*i+o,r[s]=a%ge|0,o=a/ge|0;return o&&r.unshift(o),r}function t(r,i,a,o){var s,l;if(a!=o)l=a>o?1:-1;else for(s=l=0;s<a;s++)if(r[s]!=i[s]){l=r[s]>i[s]?1:-1;break}return l}function n(r,i,a){for(var o=0;a--;)r[a]-=o,o=r[a]<i[a]?1:0,r[a]=o*ge+r[a]-i[a];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,a,o){var s,l,c,u,f,d,h,p,m,g,v,y,b,_,x,S,O,M,E=r.constructor,j=r.s==i.s?1:-1,D=r.d,A=i.d;if(!r.s)return new E(r);if(!i.s)throw Error(et+"Division by zero");for(l=r.e-i.e,O=A.length,x=D.length,h=new E(j),p=h.d=[],c=0;A[c]==(D[c]||0);)++c;if(A[c]>(D[c]||0)&&--l,a==null?y=a=E.precision:o?y=a+(ue(r)-ue(i))+1:y=a,y<0)return new E(0);if(y=y/ee+2|0,c=0,O==1)for(u=0,A=A[0],y++;(c<x||u)&&y--;c++)b=u*ge+(D[c]||0),p[c]=b/A|0,u=b%A|0;else{for(u=ge/(A[0]+1)|0,u>1&&(A=e(A,u),D=e(D,u),O=A.length,x=D.length),_=O,m=D.slice(0,O),g=m.length;g<O;)m[g++]=0;M=A.slice(),M.unshift(0),S=A[0],A[1]>=ge/2&&++S;do u=0,s=t(A,m,O,g),s<0?(v=m[0],O!=g&&(v=v*ge+(m[1]||0)),u=v/S|0,u>1?(u>=ge&&(u=ge-1),f=e(A,u),d=f.length,g=m.length,s=t(f,m,d,g),s==1&&(u--,n(f,O<d?M:A,d))):(u==0&&(s=u=1),f=A.slice()),d=f.length,d<g&&f.unshift(0),n(m,f,g),s==-1&&(g=m.length,s=t(A,m,O,g),s<1&&(u++,n(m,O<g?M:A,g))),g=m.length):s===0&&(u++,m=[0]),p[c++]=u,s&&m[0]?m[g++]=D[_]||0:(m=[D[_]],g=1);while((_++<x||m[0]!==void 0)&&y--)}return p[0]||p.shift(),h.e=l,G(h,o?a+ue(h)+1:a)}})();function w0(e,t){var n,r,i,a,o,s,l=0,c=0,u=e.constructor,f=u.precision;if(ue(e)>16)throw Error(Tu+ue(e));if(!e.s)return new u(ze);for(ne=!1,s=f,o=new u(.03125);e.abs().gte(.1);)e=e.times(o),c+=5;for(r=Math.log(vn(2,c))/Math.LN10*2+5|0,s+=r,n=i=a=new u(ze),u.precision=s;;){if(i=G(i.times(e),s),n=n.times(++l),o=a.plus(Ct(i,n,s)),mt(o.d).slice(0,s)===mt(a.d).slice(0,s)){for(;c--;)a=G(a.times(a),s);return u.precision=f,t==null?(ne=!0,G(a,f)):a}a=o}}function ue(e){for(var t=e.e*ee,n=e.d[0];n>=10;n/=10)t++;return t}function vl(e,t,n){if(t>e.LN10.sd())throw ne=!0,n&&(e.precision=n),Error(et+"LN10 precision limit exceeded");return G(new e(e.LN10),t)}function Bt(e){for(var t="";e--;)t+="0";return t}function ri(e,t){var n,r,i,a,o,s,l,c,u,f=1,d=10,h=e,p=h.d,m=h.constructor,g=m.precision;if(h.s<1)throw Error(et+(h.s?"NaN":"-Infinity"));if(h.eq(ze))return new m(0);if(t==null?(ne=!1,c=g):c=t,h.eq(10))return t==null&&(ne=!0),vl(m,c);if(c+=d,m.precision=c,n=mt(p),r=n.charAt(0),a=ue(h),Math.abs(a)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)h=h.times(e),n=mt(h.d),r=n.charAt(0),f++;a=ue(h),r>1?(h=new m("0."+n),a++):h=new m(r+"."+n.slice(1))}else return l=vl(m,c+2,g).times(a+""),h=ri(new m(r+"."+n.slice(1)),c-d).plus(l),m.precision=g,t==null?(ne=!0,G(h,g)):h;for(s=o=h=Ct(h.minus(ze),h.plus(ze),c),u=G(h.times(h),c),i=3;;){if(o=G(o.times(u),c),l=s.plus(Ct(o,new m(i),c)),mt(l.d).slice(0,c)===mt(s.d).slice(0,c))return s=s.times(2),a!==0&&(s=s.plus(vl(m,c+2,g).times(a+""))),s=Ct(s,new m(f),c),m.precision=g,t==null?(ne=!0,G(s,g)):s;s=l,i+=2}}function Fg(e,t){var n,r,i;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(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(r,i),t){if(i-=r,n=n-r-1,e.e=fr(n/ee),e.d=[],r=(n+1)%ee,n<0&&(r+=ee),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=ee;r<i;)e.d.push(+t.slice(r,r+=ee));t=t.slice(r),r=ee-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),ne&&(e.e>Va||e.e<-Va))throw Error(Tu+n)}else e.s=0,e.e=0,e.d=[0];return e}function G(e,t,n){var r,i,a,o,s,l,c,u,f=e.d;for(o=1,a=f[0];a>=10;a/=10)o++;if(r=t-o,r<0)r+=ee,i=t,c=f[u=0];else{if(u=Math.ceil((r+1)/ee),a=f.length,u>=a)return e;for(c=a=f[u],o=1;a>=10;a/=10)o++;r%=ee,i=r-ee+o}if(n!==void 0&&(a=vn(10,o-i-1),s=c/a%10|0,l=t<0||f[u+1]!==void 0||c%a,l=n<4?(s||l)&&(n==0||n==(e.s<0?3:2)):s>5||s==5&&(n==4||l||n==6&&(r>0?i>0?c/vn(10,o-i):0:f[u-1])%10&1||n==(e.s<0?8:7))),t<1||!f[0])return l?(a=ue(e),f.length=1,t=t-a-1,f[0]=vn(10,(ee-t%ee)%ee),e.e=fr(-t/ee)||0):(f.length=1,f[0]=e.e=e.s=0),e;if(r==0?(f.length=u,a=1,u--):(f.length=u+1,a=vn(10,ee-r),f[u]=i>0?(c/vn(10,o-i)%vn(10,i)|0)*a:0),l)for(;;)if(u==0){(f[0]+=a)==ge&&(f[0]=1,++e.e);break}else{if(f[u]+=a,f[u]!=ge)break;f[u--]=0,a=1}for(r=f.length;f[--r]===0;)f.pop();if(ne&&(e.e>Va||e.e<-Va))throw Error(Tu+ue(e));return e}function S0(e,t){var n,r,i,a,o,s,l,c,u,f,d=e.constructor,h=d.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new d(e),ne?G(t,h):t;if(l=e.d,f=t.d,r=t.e,c=e.e,l=l.slice(),o=c-r,o){for(u=o<0,u?(n=l,o=-o,s=f.length):(n=f,r=c,s=l.length),i=Math.max(Math.ceil(h/ee),s)+2,o>i&&(o=i,n.length=1),n.reverse(),i=o;i--;)n.push(0);n.reverse()}else{for(i=l.length,s=f.length,u=i<s,u&&(s=i),i=0;i<s;i++)if(l[i]!=f[i]){u=l[i]<f[i];break}o=0}for(u&&(n=l,l=f,f=n,t.s=-t.s),s=l.length,i=f.length-s;i>0;--i)l[s++]=0;for(i=f.length;i>o;){if(l[--i]<f[i]){for(a=i;a&&l[--a]===0;)l[a]=ge-1;--l[a],l[i]+=ge}l[i]-=f[i]}for(;l[--s]===0;)l.pop();for(;l[0]===0;l.shift())--r;return l[0]?(t.d=l,t.e=r,ne?G(t,h):t):new d(0)}function In(e,t,n){var r,i=ue(e),a=mt(e.d),o=a.length;return t?(n&&(r=n-o)>0?a=a.charAt(0)+"."+a.slice(1)+Bt(r):o>1&&(a=a.charAt(0)+"."+a.slice(1)),a=a+(i<0?"e":"e+")+i):i<0?(a="0."+Bt(-i-1)+a,n&&(r=n-o)>0&&(a+=Bt(r))):i>=o?(a+=Bt(i+1-o),n&&(r=n-i-1)>0&&(a=a+"."+Bt(r))):((r=i+1)<o&&(a=a.slice(0,r)+"."+a.slice(r)),n&&(r=n-o)>0&&(i+1===o&&(a+="."),a+=Bt(r))),e.s<0?"-"+a:a}function Bg(e,t){if(e.length>t)return e.length=t,!0}function O0(e){var t,n,r;function i(a){var o=this;if(!(o instanceof i))return new i(a);if(o.constructor=i,a instanceof i){o.s=a.s,o.e=a.e,o.d=(a=a.d)?a.slice():a;return}if(typeof a=="number"){if(a*0!==0)throw Error(Mn+a);if(a>0)o.s=1;else if(a<0)a=-a,o.s=-1;else{o.s=0,o.e=0,o.d=[0];return}if(a===~~a&&a<1e7){o.e=0,o.d=[a];return}return Fg(o,a.toString())}else if(typeof a!="string")throw Error(Mn+a);if(a.charCodeAt(0)===45?(a=a.slice(1),o.s=-1):o.s=1,SD.test(a))Fg(o,a);else throw Error(Mn+a)}if(i.prototype=I,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=O0,i.config=i.set=OD,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 OD(e){if(!e||typeof e!="object")throw Error(et+"Object expected");var t,n,r,i=["precision",1,ur,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<i.length;t+=3)if((r=e[n=i[t]])!==void 0)if(fr(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(Mn+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(Mn+n+": "+r);return this}var Iu=O0(wD);ze=new Iu(1);const X=Iu;function P0(e){var t;return e===0?t=1:t=Math.floor(new X(e).abs().log(10).toNumber())+1,t}function M0(e,t,n){for(var r=new X(e),i=0,a=[];r.lt(t)&&i<1e5;)a.push(r.toNumber()),r=r.add(n),i++;return a}var A0=e=>{var[t,n]=e,[r,i]=[t,n];return t>n&&([r,i]=[n,t]),[r,i]},k0=(e,t,n)=>{if(e.lte(0))return new X(0);var r=P0(e.toNumber()),i=new X(10).pow(r),a=e.div(i),o=r!==1?.05:.1,s=new X(Math.ceil(a.div(o).toNumber())).add(n).mul(o),l=s.mul(i);return t?new X(l.toNumber()):new X(Math.ceil(l.toNumber()))},PD=(e,t,n)=>{var r=new X(1),i=new X(e);if(!i.isint()&&n){var a=Math.abs(e);a<1?(r=new X(10).pow(P0(e)-1),i=new X(Math.floor(i.div(r).toNumber())).mul(r)):a>1&&(i=new X(Math.floor(e)))}else e===0?i=new X(Math.floor((t-1)/2)):n||(i=new X(Math.floor(e)));for(var o=Math.floor((t-1)/2),s=[],l=0;l<t;l++)s.push(i.add(new X(l-o).mul(r)).toNumber());return s},C0=function(t,n,r,i){var a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((n-t)/(r-1)))return{step:new X(0),tickMin:new X(0),tickMax:new X(0)};var o=k0(new X(n).sub(t).div(r-1),i,a),s;t<=0&&n>=0?s=new X(0):(s=new X(t).add(n).div(2),s=s.sub(new X(s).mod(o)));var l=Math.ceil(s.sub(t).div(o).toNumber()),c=Math.ceil(new X(n).sub(s).div(o).toNumber()),u=l+c+1;return u>r?C0(t,n,r,i,a+1):(u<r&&(c=n>0?c+(r-u):c,l=n>0?l:l+(r-u)),{step:o,tickMin:s.sub(new X(l).mul(o)),tickMax:s.add(new X(c).mul(o))})},MD=function(t){var[n,r]=t,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,l]=A0([n,r]);if(s===-1/0||l===1/0){var c=l===1/0?[s,...Array(i-1).fill(1/0)]:[...Array(i-1).fill(-1/0),l];return n>r?c.reverse():c}if(s===l)return PD(s,i,a);var{step:u,tickMin:f,tickMax:d}=C0(s,l,o,a,0),h=M0(f,d.add(new X(.1).mul(u)),u);return n>r?h.reverse():h},AD=function(t,n){var[r,i]=t,a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,[o,s]=A0([r,i]);if(o===-1/0||s===1/0)return[r,i];if(o===s)return[o];var l=Math.max(n,2),c=k0(new X(s).sub(o).div(l-1),a,0),u=[...M0(new X(o),new X(s),c),s];return a===!1&&(u=u.map(f=>Math.round(f))),r>i?u.reverse():u},kD=e=>e.rootProps.barCategoryGap,Eo=e=>e.rootProps.stackOffset,E0=e=>e.rootProps.reverseStackOrder,ju=e=>e.options.chartName,Ru=e=>e.rootProps.syncId,D0=e=>e.rootProps.syncMethod,Lu=e=>e.options.eventEmitter,wn={grid:-100,barBackground:-50,area:100,cursorRectangle:200,bar:300,line:400,axis:500,scatter:600,activeBar:1e3,cursorLine:1100,activeDot:1200,label:2e3},dn={allowDecimals:!1,allowDataOverflow:!1,angleAxisId:0,reversed:!1,scale:"auto",tick:!0,type:"auto"},ut={allowDataOverflow:!1,allowDecimals:!1,allowDuplicatedCategory:!0,includeHidden:!1,radiusAxisId:0,reversed:!1,scale:"auto",tick:!0,tickCount:5,type:"auto"},Do=(e,t)=>{if(!(!e||!t))return e!=null&&e.reversed?[t[1],t[0]]:t};function T0(e,t,n){if(n!=="auto")return n;if(e!=null)return Jt(e,t)?"category":"number"}function zg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ha(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?zg(Object(n),!0).forEach(function(r){CD(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zg(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function CD(e,t,n){return(t=ED(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ED(e){var t=DD(e,"string");return typeof t=="symbol"?t:t+""}function DD(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var $g={allowDataOverflow:dn.allowDataOverflow,allowDecimals:dn.allowDecimals,allowDuplicatedCategory:!1,dataKey:void 0,domain:void 0,id:dn.angleAxisId,includeHidden:!1,name:void 0,reversed:dn.reversed,scale:dn.scale,tick:dn.tick,tickCount:void 0,ticks:void 0,type:dn.type,unit:void 0},Wg={allowDataOverflow:ut.allowDataOverflow,allowDecimals:ut.allowDecimals,allowDuplicatedCategory:ut.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:ut.radiusAxisId,includeHidden:ut.includeHidden,name:void 0,reversed:ut.reversed,scale:ut.scale,tick:ut.tick,tickCount:ut.tickCount,ticks:void 0,type:ut.type,unit:void 0},TD=(e,t)=>{if(t!=null)return e.polarAxis.angleAxis[t]},Nu=P([TD,Oy],(e,t)=>{var n;if(e!=null)return e;var r=(n=T0(t,"angleAxis",$g.type))!==null&&n!==void 0?n:"category";return Ha(Ha({},$g),{},{type:r})}),ID=(e,t)=>e.polarAxis.radiusAxis[t],Fu=P([ID,Oy],(e,t)=>{var n;if(e!=null)return e;var r=(n=T0(t,"radiusAxis",Wg.type))!==null&&n!==void 0?n:"category";return Ha(Ha({},Wg),{},{type:r})}),To=e=>e.polarOptions,Bu=P([en,tn,Ae],Ek),I0=P([To,Bu],(e,t)=>{if(e!=null)return Zn(e.innerRadius,t,0)}),j0=P([To,Bu],(e,t)=>{if(e!=null)return Zn(e.outerRadius,t,t*.8)}),jD=e=>{if(e==null)return[0,0];var{startAngle:t,endAngle:n}=e;return[t,n]},R0=P([To],jD);P([Nu,R0],Do);var L0=P([Bu,I0,j0],(e,t,n)=>{if(!(e==null||t==null||n==null))return[t,n]});P([Fu,L0],Do);var RD=P([ce,To,I0,j0,en,tn],(e,t,n,r,i,a)=>{if(!(e!=="centric"&&e!=="radial"||t==null||n==null||r==null)){var{cx:o,cy:s,startAngle:l,endAngle:c}=t;return{cx:Zn(o,i,i/2),cy:Zn(s,a,a/2),innerRadius:n,outerRadius:r,startAngle:l,endAngle:c,clockWise:!1}}}),be=(e,t)=>t,Io=(e,t,n)=>n;function N0(e){return e?.id}function F0(e,t,n){var{chartData:r=[]}=t,{allowDuplicatedCategory:i,dataKey:a}=n,o=new Map;return e.forEach(s=>{var l,c=(l=s.data)!==null&&l!==void 0?l:r;if(!(c==null||c.length===0)){var u=N0(s);c.forEach((f,d)=>{var h=a==null||i?d:String(ve(f,a,null)),p=ve(f,s.dataKey,0),m;o.has(h)?m=o.get(h):m={},Object.assign(m,{[u]:p}),o.set(h,m)})}}),Array.from(o.values())}function zu(e){return"stackId"in e&&e.stackId!=null&&e.dataKey!=null}var jo=(e,t)=>e===t?!0:e==null||t==null?!1:e[0]===t[0]&&e[1]===t[1];function Ro(e,t){return Array.isArray(e)&&Array.isArray(t)&&e.length===0&&t.length===0?!0:e===t}function LD(e,t){if(e.length===t.length){for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}return!1}var xe=e=>{var t=ce(e);return t==="horizontal"?"xAxis":t==="vertical"?"yAxis":t==="centric"?"angleAxis":"radiusAxis"},dr=e=>e.tooltip.settings.axisId;function ND(e){if(e in Rr)return Rr[e]();var t="scale".concat(Kc(e));if(t in Rr)return Rr[t]()}function qg(e){var t=e.ticks,n=e.bandwidth,r=e.range(),i=[Math.min(...r),Math.max(...r)];return{domain:()=>e.domain(),range:(function(a){function o(){return a.apply(this,arguments)}return o.toString=function(){return a.toString()},o})(()=>i),rangeMin:()=>i[0],rangeMax:()=>i[1],isInRange(a){var o=i[0],s=i[1];return o<=s?a>=o&&a<=s:a>=s&&a<=o},bandwidth:n?()=>n.call(e):void 0,ticks:t?a=>t.call(e,a):void 0,map:(a,o)=>{var s=e(a);if(s!=null){if(e.bandwidth&&o!==null&&o!==void 0&&o.position){var l=e.bandwidth();switch(o.position){case"middle":s+=l/2;break;case"end":s+=l;break}}return s}}}}function Ug(e,t,n){if(typeof e=="function")return qg(e.copy().domain(t).range(n));if(e!=null){var r=ND(e);if(r!=null)return r.domain(t).range(n),qg(r)}}var FD=(e,t)=>{if(t!=null)switch(e){case"linear":{if(!jt(t)){for(var n,r,i=0;i<t.length;i++){var a=t[i];Q(a)&&((n===void 0||a<n)&&(n=a),(r===void 0||a>r)&&(r=a))}return n!==void 0&&r!==void 0?[n,r]:void 0}return t}default:return t}};function Vg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ka(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Vg(Object(n),!0).forEach(function(r){BD(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Vg(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function BD(e,t,n){return(t=zD(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zD(e){var t=$D(e,"string");return typeof t=="symbol"?t:t+""}function $D(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var wc=[0,"auto"],WD={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:void 0,height:30,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"bottom",padding:{left:0,right:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"category",unit:void 0},qD=(e,t)=>e.cartesianAxis.xAxis[t],on=(e,t)=>{var n=qD(e,t);return n??WD},UD={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:wc,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"left",padding:{top:0,bottom:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"number",unit:void 0,width:ui},VD=(e,t)=>e.cartesianAxis.yAxis[t],sn=(e,t)=>{var n=VD(e,t);return n??UD},HD={domain:[0,"auto"],includeHidden:!1,reversed:!1,allowDataOverflow:!1,allowDuplicatedCategory:!1,dataKey:void 0,id:0,name:"",range:[64,64],scale:"auto",type:"number",unit:""},$u=(e,t)=>{var n=e.cartesianAxis.zAxis[t];return n??HD},Ee=(e,t,n)=>{switch(t){case"xAxis":return on(e,n);case"yAxis":return sn(e,n);case"zAxis":return $u(e,n);case"angleAxis":return Nu(e,n);case"radiusAxis":return Fu(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},KD=(e,t,n)=>{switch(t){case"xAxis":return on(e,n);case"yAxis":return sn(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},yi=(e,t,n)=>{switch(t){case"xAxis":return on(e,n);case"yAxis":return sn(e,n);case"angleAxis":return Nu(e,n);case"radiusAxis":return Fu(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},B0=e=>e.graphicalItems.cartesianItems.some(t=>t.type==="bar")||e.graphicalItems.polarItems.some(t=>t.type==="radialBar");function z0(e,t){return n=>{switch(e){case"xAxis":return"xAxisId"in n&&n.xAxisId===t;case"yAxis":return"yAxisId"in n&&n.yAxisId===t;case"zAxis":return"zAxisId"in n&&n.zAxisId===t;case"angleAxis":return"angleAxisId"in n&&n.angleAxisId===t;case"radiusAxis":return"radiusAxisId"in n&&n.radiusAxisId===t;default:return!1}}}var YD=e=>e.graphicalItems.cartesianItems,XD=P([be,Io],z0),$0=(e,t,n)=>e.filter(n).filter(r=>t?.includeHidden===!0?!0:!r.hide),bi=P([YD,Ee,XD],$0,{memoizeOptions:{resultEqualityCheck:Ro}}),W0=P([bi],e=>e.filter(t=>t.type==="area"||t.type==="bar").filter(zu)),q0=e=>e.filter(t=>!("stackId"in t)||t.stackId===void 0),GD=P([bi],q0),U0=e=>e.map(t=>t.data).filter(Boolean).flat(1),ZD=P([bi],U0,{memoizeOptions:{resultEqualityCheck:Ro}}),V0=(e,t)=>{var{chartData:n=[],dataStartIndex:r,dataEndIndex:i}=t;return e.length>0?e:n.slice(r,i+1)},Wu=P([ZD,y0],V0),H0=(e,t,n)=>t?.dataKey!=null?e.map(r=>({value:ve(r,t.dataKey)})):n.length>0?n.map(r=>r.dataKey).flatMap(r=>e.map(i=>({value:ve(i,r)}))):e.map(r=>({value:r})),Lo=P([Wu,Ee,bi],H0);function K0(e,t){switch(e){case"xAxis":return t.direction==="x";case"yAxis":return t.direction==="y";default:return!1}}function oa(e){if(Cn(e)||e instanceof Date){var t=Number(e);if(Q(t))return t}}function Hg(e){if(Array.isArray(e)){var t=[oa(e[0]),oa(e[1])];return jt(t)?t:void 0}var n=oa(e);if(n!=null)return[n,n]}function Rt(e){return e.map(oa).filter(at)}function QD(e,t,n){return!n||typeof t!="number"||sr(t)?[]:n.length?Rt(n.flatMap(r=>{var i=ve(e,r.dataKey),a,o;if(Array.isArray(i)?[a,o]=i:a=o=i,!(!Q(a)||!Q(o)))return[t-a,t+o]})):[]}var pe=e=>{var t=xe(e),n=dr(e);return yi(e,t,n)},xi=P([pe],e=>e?.dataKey),JD=P([W0,y0,pe],F0),Y0=(e,t,n,r)=>{var i={},a=t.reduce((o,s)=>{if(s.stackId==null)return o;var l=o[s.stackId];return l==null&&(l=[]),l.push(s),o[s.stackId]=l,o},i);return Object.fromEntries(Object.entries(a).map(o=>{var[s,l]=o,c=r?[...l].reverse():l,u=c.map(N0);return[s,{stackedData:mM(e,u,n),graphicalItems:c}]}))},eT=P([JD,W0,Eo,E0],Y0),X0=(e,t,n,r)=>{var{dataStartIndex:i,dataEndIndex:a}=t;if(r==null&&n!=="zAxis"){var o=bM(e,i,a);if(!(o!=null&&o[0]===0&&o[1]===0))return o}},tT=P([Ee],e=>e.allowDataOverflow),qu=e=>{var t;if(e==null||!("domain"in e))return wc;if(e.domain!=null)return e.domain;if("ticks"in e&&e.ticks!=null){if(e.type==="number"){var n=Rt(e.ticks);return[Math.min(...n),Math.max(...n)]}if(e.type==="category")return e.ticks.map(String)}return(t=e?.domain)!==null&&t!==void 0?t:wc},G0=P([Ee],qu),Z0=P([G0,tT],b0),nT=P([eT,an,be,Z0],X0,{memoizeOptions:{resultEqualityCheck:jo}}),Uu=e=>e.errorBars,rT=(e,t,n)=>e.flatMap(r=>t[r.id]).filter(Boolean).filter(r=>K0(n,r)),Ya=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n.filter(Boolean);if(i.length!==0){var a=i.flat(),o=Math.min(...a),s=Math.max(...a);return[o,s]}},Q0=(e,t,n,r,i)=>{var a,o;if(n.length>0&&e.forEach(s=>{n.forEach(l=>{var c,u,f=(c=r[l.id])===null||c===void 0?void 0:c.filter(v=>K0(i,v)),d=ve(s,(u=t.dataKey)!==null&&u!==void 0?u:l.dataKey),h=QD(s,d,f);if(h.length>=2){var p=Math.min(...h),m=Math.max(...h);(a==null||p<a)&&(a=p),(o==null||m>o)&&(o=m)}var g=Hg(d);g!=null&&(a=a==null?g[0]:Math.min(a,g[0]),o=o==null?g[1]:Math.max(o,g[1]))})}),t?.dataKey!=null&&e.forEach(s=>{var l=Hg(ve(s,t.dataKey));l!=null&&(a=a==null?l[0]:Math.min(a,l[0]),o=o==null?l[1]:Math.max(o,l[1]))}),Q(a)&&Q(o))return[a,o]},iT=P([Wu,Ee,GD,Uu,be],Q0,{memoizeOptions:{resultEqualityCheck:jo}});function aT(e){var{value:t}=e;if(Cn(t)||t instanceof Date)return t}var oT=(e,t,n)=>{var r=e.map(aT).filter(i=>i!=null);return n&&(t.dataKey==null||t.allowDuplicatedCategory&&Ev(r))?Fy(0,e.length):t.allowDuplicatedCategory?r:Array.from(new Set(r))},J0=e=>e.referenceElements.dots,hr=(e,t,n)=>e.filter(r=>r.ifOverflow==="extendDomain").filter(r=>t==="xAxis"?r.xAxisId===n:r.yAxisId===n),sT=P([J0,be,Io],hr),eb=e=>e.referenceElements.areas,lT=P([eb,be,Io],hr),tb=e=>e.referenceElements.lines,cT=P([tb,be,Io],hr),nb=(e,t)=>{if(e!=null){var n=Rt(e.map(r=>t==="xAxis"?r.x:r.y));if(n.length!==0)return[Math.min(...n),Math.max(...n)]}},uT=P(sT,be,nb),rb=(e,t)=>{if(e!=null){var n=Rt(e.flatMap(r=>[t==="xAxis"?r.x1:r.y1,t==="xAxis"?r.x2:r.y2]));if(n.length!==0)return[Math.min(...n),Math.max(...n)]}},fT=P([lT,be],rb);function dT(e){var t;if(e.x!=null)return Rt([e.x]);var n=(t=e.segment)===null||t===void 0?void 0:t.map(r=>r.x);return n==null||n.length===0?[]:Rt(n)}function hT(e){var t;if(e.y!=null)return Rt([e.y]);var n=(t=e.segment)===null||t===void 0?void 0:t.map(r=>r.y);return n==null||n.length===0?[]:Rt(n)}var ib=(e,t)=>{if(e!=null){var n=e.flatMap(r=>t==="xAxis"?dT(r):hT(r));if(n.length!==0)return[Math.min(...n),Math.max(...n)]}},pT=P([cT,be],ib),gT=P(uT,pT,fT,(e,t,n)=>Ya(e,n,t)),ab=(e,t,n,r,i,a,o,s)=>{if(n!=null)return n;var l=o==="vertical"&&s==="xAxis"||o==="horizontal"&&s==="yAxis",c=l?Ya(r,a,i):Ya(a,i);return _D(t,c,e.allowDataOverflow)},mT=P([Ee,G0,Z0,nT,iT,gT,ce,be],ab,{memoizeOptions:{resultEqualityCheck:jo}}),vT=[0,1],ob=(e,t,n,r,i,a,o)=>{if(!((e==null||n==null||n.length===0)&&o===void 0)){var{dataKey:s,type:l}=e,c=Jt(t,a);if(c&&s==null){var u;return Fy(0,(u=n?.length)!==null&&u!==void 0?u:0)}return l==="category"?oT(r,e,c):i==="expand"?vT:o}},Vu=P([Ee,ce,Wu,Lo,Eo,be,mT],ob);function yT(e){return e in Rr}var sb=(e,t,n)=>{if(e!=null){var{scale:r,type:i}=e;if(r==="auto")return i==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!t)?"point":i==="category"?"band":"linear";if(typeof r=="string"){var a="scale".concat(Kc(r));return yT(a)?a:"point"}}},pr=P([Ee,B0,ju],sb);function Hu(e,t,n,r){if(!(n==null||r==null))return typeof e.scale=="function"?Ug(e.scale,n,r):Ug(t,n,r)}var lb=(e,t,n)=>{var r=qu(t);if(!(n!=="auto"&&n!=="linear")){if(t!=null&&t.tickCount&&Array.isArray(r)&&(r[0]==="auto"||r[1]==="auto")&&jt(e))return MD(e,t.tickCount,t.allowDecimals);if(t!=null&&t.tickCount&&t.type==="number"&&jt(e))return AD(e,t.tickCount,t.allowDecimals)}},Ku=P([Vu,yi,pr],lb),cb=(e,t,n,r)=>{if(r!=="angleAxis"&&e?.type==="number"&&jt(t)&&Array.isArray(n)&&n.length>0){var i,a,o=t[0],s=(i=n[0])!==null&&i!==void 0?i:0,l=t[1],c=(a=n[n.length-1])!==null&&a!==void 0?a:0;return[Math.min(o,s),Math.max(l,c)]}return t},bT=P([Ee,Vu,Ku,be],cb),xT=P(Lo,Ee,(e,t)=>{if(!(!t||t.type!=="number")){var n=1/0,r=Array.from(Rt(e.map(f=>f.value))).sort((f,d)=>f-d),i=r[0],a=r[r.length-1];if(i==null||a==null)return 1/0;var o=a-i;if(o===0)return 1/0;for(var s=0;s<r.length-1;s++){var l=r[s],c=r[s+1];if(!(l==null||c==null)){var u=c-l;n=Math.min(n,u)}}return n/o}}),ub=P(xT,ce,kD,Ae,(e,t,n,r,i)=>i,(e,t,n,r,i)=>{if(!Q(e))return 0;var a=t==="vertical"?r.height:r.width;if(i==="gap")return e*a/2;if(i==="no-gap"){var o=Zn(n,e*a),s=e*a/2;return s-o-(s-o)/a*o}return 0}),_T=(e,t,n)=>{var r=on(e,t);return r==null||typeof r.padding!="string"?0:ub(e,"xAxis",t,n,r.padding)},wT=(e,t,n)=>{var r=sn(e,t);return r==null||typeof r.padding!="string"?0:ub(e,"yAxis",t,n,r.padding)},ST=P(on,_T,(e,t)=>{var n,r;if(e==null)return{left:0,right:0};var{padding:i}=e;return typeof i=="string"?{left:t,right:t}:{left:((n=i.left)!==null&&n!==void 0?n:0)+t,right:((r=i.right)!==null&&r!==void 0?r:0)+t}}),OT=P(sn,wT,(e,t)=>{var n,r;if(e==null)return{top:0,bottom:0};var{padding:i}=e;return typeof i=="string"?{top:t,bottom:t}:{top:((n=i.top)!==null&&n!==void 0?n:0)+t,bottom:((r=i.bottom)!==null&&r!==void 0?r:0)+t}}),PT=P([Ae,ST,iu,bo,(e,t,n)=>n],(e,t,n,r,i)=>{var{padding:a}=r;return i?[a.left,n.width-a.right]:[e.left+t.left,e.left+e.width-t.right]}),MT=P([Ae,ce,OT,iu,bo,(e,t,n)=>n],(e,t,n,r,i,a)=>{var{padding:o}=i;return a?[r.height-o.bottom,o.top]:t==="horizontal"?[e.top+e.height-n.bottom,e.top+n.top]:[e.top+n.top,e.top+e.height-n.bottom]}),_i=(e,t,n,r)=>{var i;switch(t){case"xAxis":return PT(e,n,r);case"yAxis":return MT(e,n,r);case"zAxis":return(i=$u(e,n))===null||i===void 0?void 0:i.range;case"angleAxis":return R0(e);case"radiusAxis":return L0(e,n);default:return}},fb=P([Ee,_i],Do),AT=P([pr,bT],FD),No=P([Ee,pr,AT,fb],Hu);P([bi,Uu,be],rT);function db(e,t){return e.id<t.id?-1:e.id>t.id?1:0}var Fo=(e,t)=>t,Bo=(e,t,n)=>n,kT=P(vo,Fo,Bo,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(db)),CT=P(yo,Fo,Bo,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(db)),hb=(e,t)=>({width:e.width,height:t.height}),ET=(e,t)=>{var n=typeof t.width=="number"?t.width:ui;return{width:n,height:e.height}};P(Ae,on,hb);var DT=(e,t,n)=>{switch(t){case"top":return e.top;case"bottom":return n-e.bottom;default:return 0}},TT=(e,t,n)=>{switch(t){case"left":return e.left;case"right":return n-e.right;default:return 0}},IT=P(tn,Ae,kT,Fo,Bo,(e,t,n,r,i)=>{var a={},o;return n.forEach(s=>{var l=hb(t,s);o==null&&(o=DT(t,r,e));var c=r==="top"&&!i||r==="bottom"&&i;a[s.id]=o-Number(c)*l.height,o+=(c?-1:1)*l.height}),a}),jT=P(en,Ae,CT,Fo,Bo,(e,t,n,r,i)=>{var a={},o;return n.forEach(s=>{var l=ET(t,s);o==null&&(o=TT(t,r,e));var c=r==="left"&&!i||r==="right"&&i;a[s.id]=o-Number(c)*l.width,o+=(c?-1:1)*l.width}),a}),RT=(e,t)=>{var n=on(e,t);if(n!=null)return IT(e,n.orientation,n.mirror)};P([Ae,on,RT,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:e.left,y:0}:{x:e.left,y:i}}});var LT=(e,t)=>{var n=sn(e,t);if(n!=null)return jT(e,n.orientation,n.mirror)};P([Ae,sn,LT,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:0,y:e.top}:{x:i,y:e.top}}});P(Ae,sn,(e,t)=>{var n=typeof t.width=="number"?t.width:ui;return{width:n,height:e.height}});var pb=(e,t,n,r)=>{if(n!=null){var{allowDuplicatedCategory:i,type:a,dataKey:o}=n,s=Jt(e,r),l=t.map(c=>c.value);if(o&&s&&a==="category"&&i&&Ev(l))return l}},Yu=P([ce,Lo,Ee,be],pb),gb=(e,t,n,r)=>{if(!(n==null||n.dataKey==null)){var{type:i,scale:a}=n,o=Jt(e,r);if(o&&(i==="number"||a!=="auto"))return t.map(s=>s.value)}},Xu=P([ce,Lo,yi,be],gb);P([ce,KD,pr,No,Yu,Xu,_i,Ku,be],(e,t,n,r,i,a,o,s,l)=>{if(t!=null){var c=Jt(e,l);return{angle:t.angle,interval:t.interval,minTickGap:t.minTickGap,orientation:t.orientation,tick:t.tick,tickCount:t.tickCount,tickFormatter:t.tickFormatter,ticks:t.ticks,type:t.type,unit:t.unit,axisType:l,categoricalDomain:a,duplicateDomain:i,isCategorical:c,niceTicks:s,range:o,realScaleType:n,scale:r}}});var NT=(e,t,n,r,i,a,o,s,l)=>{if(!(t==null||r==null)){var c=Jt(e,l),{type:u,ticks:f,tickCount:d}=t,h=n==="scaleBand"&&typeof r.bandwidth=="function"?r.bandwidth()/2:2,p=u==="category"&&r.bandwidth?r.bandwidth()/h:0;p=l==="angleAxis"&&a!=null&&a.length>=2?Mt(a[0]-a[1])*2*p:p;var m=f||i;return m?m.map((g,v)=>{var y=o?o.indexOf(g):g,b=r.map(y);return Q(b)?{index:v,coordinate:b+p,value:g,offset:p}:null}).filter(at):c&&s?s.map((g,v)=>{var y=r.map(g);return Q(y)?{coordinate:y+p,value:g,index:v,offset:p}:null}).filter(at):r.ticks?r.ticks(d).map((g,v)=>{var y=r.map(g);return Q(y)?{coordinate:y+p,value:g,index:v,offset:p}:null}).filter(at):r.domain().map((g,v)=>{var y=r.map(g);return Q(y)?{coordinate:y+p,value:o?o[g]:g,index:v,offset:p}:null}).filter(at)}};P([ce,yi,pr,No,Ku,_i,Yu,Xu,be],NT);var FT=(e,t,n,r,i,a,o)=>{if(!(t==null||n==null||r==null||r[0]===r[1])){var s=Jt(e,o),{tickCount:l}=t,c=0;return c=o==="angleAxis"&&r?.length>=2?Mt(r[0]-r[1])*2*c:c,s&&a?a.map((u,f)=>{var d=n.map(u);return Q(d)?{coordinate:d+c,value:u,index:f,offset:c}:null}).filter(at):n.ticks?n.ticks(l).map((u,f)=>{var d=n.map(u);return Q(d)?{coordinate:d+c,value:u,index:f,offset:c}:null}).filter(at):n.domain().map((u,f)=>{var d=n.map(u);return Q(d)?{coordinate:d+c,value:i?i[u]:u,index:f,offset:c}:null}).filter(at)}};P([ce,yi,No,_i,Yu,Xu,be],FT);P(Ee,No,(e,t)=>{if(!(e==null||t==null))return Ka(Ka({},e),{},{scale:t})});var BT=P([Ee,pr,Vu,fb],Hu);P((e,t,n)=>$u(e,n),BT,(e,t)=>{if(!(e==null||t==null))return Ka(Ka({},e),{},{scale:t})});var zT=P([ce,vo,yo],(e,t,n)=>{switch(e){case"horizontal":return t.some(r=>r.reversed)?"right-to-left":"left-to-right";case"vertical":return n.some(r=>r.reversed)?"bottom-to-top":"top-to-bottom";case"centric":case"radial":return"left-to-right";default:return}}),mb=e=>e.options.defaultTooltipEventType,vb=e=>e.options.validateTooltipEventTypes;function yb(e,t,n){if(e==null)return t;var r=e?"axis":"item";return n==null?t:n.includes(r)?r:t}function Gu(e,t){var n=mb(e),r=vb(e);return yb(t,n,r)}function $T(e){return K(t=>Gu(t,e))}var bb=(e,t)=>{var n,r=Number(t);if(!(sr(r)||t==null))return r>=0?e==null||(n=e[r])===null||n===void 0?void 0:n.value:void 0},WT=e=>e.tooltip.settings,zt={active:!1,index:null,dataKey:void 0,graphicalItemId:void 0,coordinate:void 0},qT={itemInteraction:{click:zt,hover:zt},axisInteraction:{click:zt,hover:zt},keyboardInteraction:zt,syncInteraction:{active:!1,index:null,dataKey:void 0,label:void 0,coordinate:void 0,sourceViewBox:void 0,graphicalItemId:void 0},tooltipItemPayloads:[],settings:{shared:void 0,trigger:"hover",axisId:0,active:!1,defaultIndex:void 0}},xb=Ne({name:"tooltip",initialState:qT,reducers:{addTooltipEntrySettings:{reducer(e,t){e.tooltipItemPayloads.push(t.payload)},prepare:te()},replaceTooltipEntrySettings:{reducer(e,t){var{prev:n,next:r}=t.payload,i=ot(e).tooltipItemPayloads.indexOf(n);i>-1&&(e.tooltipItemPayloads[i]=r)},prepare:te()},removeTooltipEntrySettings:{reducer(e,t){var n=ot(e).tooltipItemPayloads.indexOf(t.payload);n>-1&&e.tooltipItemPayloads.splice(n,1)},prepare:te()},setTooltipSettingsState(e,t){e.settings=t.payload},setActiveMouseOverItemIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.itemInteraction.hover.active=!0,e.itemInteraction.hover.index=t.payload.activeIndex,e.itemInteraction.hover.dataKey=t.payload.activeDataKey,e.itemInteraction.hover.graphicalItemId=t.payload.activeGraphicalItemId,e.itemInteraction.hover.coordinate=t.payload.activeCoordinate},mouseLeaveChart(e){e.itemInteraction.hover.active=!1,e.axisInteraction.hover.active=!1},mouseLeaveItem(e){e.itemInteraction.hover.active=!1},setActiveClickItemIndex(e,t){e.syncInteraction.active=!1,e.itemInteraction.click.active=!0,e.keyboardInteraction.active=!1,e.itemInteraction.click.index=t.payload.activeIndex,e.itemInteraction.click.dataKey=t.payload.activeDataKey,e.itemInteraction.click.graphicalItemId=t.payload.activeGraphicalItemId,e.itemInteraction.click.coordinate=t.payload.activeCoordinate},setMouseOverAxisIndex(e,t){e.syncInteraction.active=!1,e.axisInteraction.hover.active=!0,e.keyboardInteraction.active=!1,e.axisInteraction.hover.index=t.payload.activeIndex,e.axisInteraction.hover.dataKey=t.payload.activeDataKey,e.axisInteraction.hover.coordinate=t.payload.activeCoordinate},setMouseClickAxisIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.axisInteraction.click.active=!0,e.axisInteraction.click.index=t.payload.activeIndex,e.axisInteraction.click.dataKey=t.payload.activeDataKey,e.axisInteraction.click.coordinate=t.payload.activeCoordinate},setSyncInteraction(e,t){e.syncInteraction=t.payload},setKeyboardInteraction(e,t){e.keyboardInteraction.active=t.payload.active,e.keyboardInteraction.index=t.payload.activeIndex,e.keyboardInteraction.coordinate=t.payload.activeCoordinate}}}),{addTooltipEntrySettings:UT,replaceTooltipEntrySettings:VT,removeTooltipEntrySettings:HT,setTooltipSettingsState:KT,setActiveMouseOverItemIndex:Zu,mouseLeaveItem:_b,mouseLeaveChart:wb,setActiveClickItemIndex:Sb,setMouseOverAxisIndex:Ob,setMouseClickAxisIndex:YT,setSyncInteraction:Sc,setKeyboardInteraction:Oc}=xb.actions,XT=xb.reducer;function Kg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).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?Kg(Object(n),!0).forEach(function(r){GT(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Kg(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function GT(e,t,n){return(t=ZT(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ZT(e){var t=QT(e,"string");return typeof t=="symbol"?t:t+""}function QT(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function JT(e,t,n){return t==="axis"?n==="click"?e.axisInteraction.click:e.axisInteraction.hover:n==="click"?e.itemInteraction.click:e.itemInteraction.hover}function eI(e){return e.index!=null}var Pb=(e,t,n,r)=>{if(t==null)return zt;var i=JT(e,t,n);if(i==null)return zt;if(i.active)return i;if(e.keyboardInteraction.active)return e.keyboardInteraction;if(e.syncInteraction.active&&e.syncInteraction.index!=null)return e.syncInteraction;var a=e.settings.active===!0;if(eI(i)){if(a)return Qi(Qi({},i),{},{active:!0})}else if(r!=null)return{active:!0,coordinate:void 0,dataKey:void 0,index:r,graphicalItemId:void 0};return Qi(Qi({},zt),{},{coordinate:i.coordinate})};function tI(e){if(typeof e=="number")return Number.isFinite(e)?e:void 0;if(e instanceof Date){var t=e.valueOf();return Number.isFinite(t)?t:void 0}var n=Number(e);return Number.isFinite(n)?n:void 0}function nI(e,t){var n=tI(e),r=t[0],i=t[1];if(n===void 0)return!1;var a=Math.min(r,i),o=Math.max(r,i);return n>=a&&n<=o}function rI(e,t,n){if(n==null||t==null)return!0;var r=ve(e,t);return r==null||!jt(n)?!0:nI(r,n)}var Qu=(e,t,n,r)=>{var i=e?.index;if(i==null)return null;var a=Number(i);if(!Q(a))return i;var o=0,s=1/0;t.length>0&&(s=t.length-1);var l=Math.max(o,Math.min(a,s)),c=t[l];return c==null||rI(c,n,r)?String(l):null},Mb=(e,t,n,r,i,a,o)=>{if(a!=null){var s=o[0],l=s?.getPosition(a);if(l!=null)return l;var c=i?.[Number(a)];if(c)return n==="horizontal"?{x:c.coordinate,y:(r.top+t)/2}:{x:(r.left+e)/2,y:c.coordinate}}},Ab=(e,t,n,r)=>{if(t==="axis")return e.tooltipItemPayloads;if(e.tooltipItemPayloads.length===0)return[];var i;if(n==="hover"?i=e.itemInteraction.hover.graphicalItemId:i=e.itemInteraction.click.graphicalItemId,i==null&&r!=null){var a=e.tooltipItemPayloads[0];return a!=null?[a]:[]}return e.tooltipItemPayloads.filter(o=>{var s;return((s=o.settings)===null||s===void 0?void 0:s.graphicalItemId)===i})},kb=e=>e.options.tooltipPayloadSearcher,gr=e=>e.tooltip;function Yg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Xg(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Yg(Object(n),!0).forEach(function(r){iI(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yg(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function iI(e,t,n){return(t=aI(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function aI(e){var t=oI(e,"string");return typeof t=="symbol"?t:t+""}function oI(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function sI(e,t){return e??t}var Cb=(e,t,n,r,i,a,o)=>{if(!(t==null||a==null)){var{chartData:s,computedData:l,dataStartIndex:c,dataEndIndex:u}=n,f=[];return e.reduce((d,h)=>{var p,{dataDefinedOnItem:m,settings:g}=h,v=sI(m,s),y=Array.isArray(v)?by(v,c,u):v,b=(p=g?.dataKey)!==null&&p!==void 0?p:r,_=g?.nameKey,x;if(r&&Array.isArray(y)&&!Array.isArray(y[0])&&o==="axis"?x=uO(y,r,i):x=a(y,t,l,_),Array.isArray(x))x.forEach(O=>{var M=Xg(Xg({},g),{},{name:O.name,unit:O.unit,color:void 0,fill:void 0});d.push(Gh({tooltipEntrySettings:M,dataKey:O.dataKey,payload:O.payload,value:ve(O.payload,O.dataKey),name:O.name}))});else{var S;d.push(Gh({tooltipEntrySettings:g,dataKey:b,payload:x,value:ve(x,b),name:(S=ve(x,_))!==null&&S!==void 0?S:g?.name}))}return d},f)}},Ju=P([pe,B0,ju],sb),lI=P([e=>e.graphicalItems.cartesianItems,e=>e.graphicalItems.polarItems],(e,t)=>[...e,...t]),cI=P([xe,dr],z0),mr=P([lI,pe,cI],$0,{memoizeOptions:{resultEqualityCheck:Ro}}),uI=P([mr],e=>e.filter(zu)),fI=P([mr],U0,{memoizeOptions:{resultEqualityCheck:Ro}}),vr=P([fI,an],V0),dI=P([uI,an,pe],F0),ef=P([vr,pe,mr],H0),Eb=P([pe],qu),hI=P([pe],e=>e.allowDataOverflow),Db=P([Eb,hI],b0),pI=P([mr],e=>e.filter(zu)),gI=P([dI,pI,Eo,E0],Y0),mI=P([gI,an,xe,Db],X0),vI=P([mr],q0),yI=P([vr,pe,vI,Uu,xe],Q0,{memoizeOptions:{resultEqualityCheck:jo}}),bI=P([J0,xe,dr],hr),xI=P([bI,xe],nb),_I=P([eb,xe,dr],hr),wI=P([_I,xe],rb),SI=P([tb,xe,dr],hr),OI=P([SI,xe],ib),PI=P([xI,OI,wI],Ya),MI=P([pe,Eb,Db,mI,yI,PI,ce,xe],ab),wi=P([pe,ce,vr,ef,Eo,xe,MI],ob),AI=P([wi,pe,Ju],lb),kI=P([pe,wi,AI,xe],cb),Tb=e=>{var t=xe(e),n=dr(e),r=!1;return _i(e,t,n,r)},Ib=P([pe,Tb],Do),jb=P([pe,Ju,kI,Ib],Hu),CI=P([ce,ef,pe,xe],pb),EI=P([ce,ef,pe,xe],gb),DI=(e,t,n,r,i,a,o,s)=>{if(t){var{type:l}=t,c=Jt(e,s);if(r){var u=n==="scaleBand"&&r.bandwidth?r.bandwidth()/2:2,f=l==="category"&&r.bandwidth?r.bandwidth()/u:0;return f=s==="angleAxis"&&i!=null&&i?.length>=2?Mt(i[0]-i[1])*2*f:f,c&&o?o.map((d,h)=>{var p=r.map(d);return Q(p)?{coordinate:p+f,value:d,index:h,offset:f}:null}).filter(at):r.domain().map((d,h)=>{var p=r.map(d);return Q(p)?{coordinate:p+f,value:a?a[d]:d,index:h,offset:f}:null}).filter(at)}}},Nt=P([ce,pe,Ju,jb,Tb,CI,EI,xe],DI),tf=P([mb,vb,WT],(e,t,n)=>yb(n.shared,e,t)),Rb=e=>e.tooltip.settings.trigger,nf=e=>e.tooltip.settings.defaultIndex,Si=P([gr,tf,Rb,nf],Pb),Xa=P([Si,vr,xi,wi],Qu),Lb=P([Nt,Xa],bb),TI=P([Si],e=>{if(e)return e.dataKey});P([Si],e=>{if(e)return e.graphicalItemId});var Nb=P([gr,tf,Rb,nf],Ab),II=P([en,tn,ce,Ae,Nt,nf,Nb],Mb),jI=P([Si,II],(e,t)=>e!=null&&e.coordinate?e.coordinate:t),RI=P([Si],e=>{var t;return(t=e?.active)!==null&&t!==void 0?t:!1}),LI=P([Nb,Xa,an,xi,Lb,kb,tf],Cb);P([LI],e=>{if(e!=null){var t=e.map(n=>n.payload).filter(n=>n!=null);return Array.from(new Set(t))}});function Gg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Zg(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Gg(Object(n),!0).forEach(function(r){NI(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Gg(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function NI(e,t,n){return(t=FI(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function FI(e){var t=BI(e,"string");return typeof t=="symbol"?t:t+""}function BI(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var zI=()=>K(pe),$I=()=>{var e=zI(),t=K(Nt),n=K(jb);return Xh(!e||!n?void 0:Zg(Zg({},e),{},{scale:n}),t)};function Qg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function zn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Qg(Object(n),!0).forEach(function(r){WI(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Qg(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function WI(e,t,n){return(t=qI(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qI(e){var t=UI(e,"string");return typeof t=="symbol"?t:t+""}function UI(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var VI=(e,t,n,r)=>{var i=t.find(a=>a&&a.index===n);if(i){if(e==="horizontal")return{x:i.coordinate,y:r.chartY};if(e==="vertical")return{x:r.chartX,y:i.coordinate}}return{x:0,y:0}},HI=(e,t,n,r)=>{var i=t.find(c=>c&&c.index===n);if(i){if(e==="centric"){var a=i.coordinate,{radius:o}=r;return zn(zn(zn({},r),Ue(r.cx,r.cy,o,a)),{},{angle:a,radius:o})}var s=i.coordinate,{angle:l}=r;return zn(zn(zn({},r),Ue(r.cx,r.cy,s,l)),{},{angle:l,radius:s})}return{angle:0,clockWise:!1,cx:0,cy:0,endAngle:0,innerRadius:0,outerRadius:0,radius:0,startAngle:0,x:0,y:0}};function KI(e,t){var{chartX:n,chartY:r}=e;return n>=t.left&&n<=t.left+t.width&&r>=t.top&&r<=t.top+t.height}var Fb=(e,t,n,r,i)=>{var a,o=(a=t?.length)!==null&&a!==void 0?a:0;if(o<=1||e==null)return 0;if(r==="angleAxis"&&i!=null&&Math.abs(Math.abs(i[1]-i[0])-360)<=1e-6)for(var s=0;s<o;s++){var l,c,u,f,d,h=s>0?(l=n[s-1])===null||l===void 0?void 0:l.coordinate:(c=n[o-1])===null||c===void 0?void 0:c.coordinate,p=(u=n[s])===null||u===void 0?void 0:u.coordinate,m=s>=o-1?(f=n[0])===null||f===void 0?void 0:f.coordinate:(d=n[s+1])===null||d===void 0?void 0:d.coordinate,g=void 0;if(!(h==null||p==null||m==null))if(Mt(p-h)!==Mt(m-p)){var v=[];if(Mt(m-p)===Mt(i[1]-i[0])){g=m;var y=p+i[1]-i[0];v[0]=Math.min(y,(y+h)/2),v[1]=Math.max(y,(y+h)/2)}else{g=h;var b=m+i[1]-i[0];v[0]=Math.min(p,(b+p)/2),v[1]=Math.max(p,(b+p)/2)}var _=[Math.min(p,(g+p)/2),Math.max(p,(g+p)/2)];if(e>_[0]&&e<=_[1]||e>=v[0]&&e<=v[1]){var x;return(x=n[s])===null||x===void 0?void 0:x.index}}else{var S=Math.min(h,m),O=Math.max(h,m);if(e>(S+p)/2&&e<=(O+p)/2){var M;return(M=n[s])===null||M===void 0?void 0:M.index}}}else if(t)for(var E=0;E<o;E++){var j=t[E];if(j!=null){var D=t[E+1],A=t[E-1];if(E===0&&D!=null&&e<=(j.coordinate+D.coordinate)/2||E===o-1&&A!=null&&e>(j.coordinate+A.coordinate)/2||E>0&&E<o-1&&A!=null&&D!=null&&e>(j.coordinate+A.coordinate)/2&&e<=(j.coordinate+D.coordinate)/2)return j.index}}return-1},YI=()=>K(ju),rf=(e,t)=>t,Bb=(e,t,n)=>n,af=(e,t,n,r)=>r,XI=P(Nt,e=>oo(e,t=>t.coordinate)),of=P([gr,rf,Bb,af],Pb),sf=P([of,vr,xi,wi],Qu),GI=(e,t,n)=>{if(t!=null){var r=gr(e);return t==="axis"?n==="hover"?r.axisInteraction.hover.dataKey:r.axisInteraction.click.dataKey:n==="hover"?r.itemInteraction.hover.dataKey:r.itemInteraction.click.dataKey}},zb=P([gr,rf,Bb,af],Ab),Ga=P([en,tn,ce,Ae,Nt,af,zb],Mb),ZI=P([of,Ga],(e,t)=>{var n;return(n=e.coordinate)!==null&&n!==void 0?n:t}),$b=P([Nt,sf],bb),QI=P([zb,sf,an,xi,$b,kb,rf],Cb),JI=P([of,sf],(e,t)=>({isActive:e.active&&t!=null,activeIndex:t})),e2=(e,t,n,r,i,a,o)=>{if(!(!e||!n||!r||!i)&&KI(e,o)){var s=xM(e,t),l=Fb(s,a,i,n,r),c=VI(t,i,l,e);return{activeIndex:String(l),activeCoordinate:c}}},t2=(e,t,n,r,i,a,o)=>{if(!(!e||!r||!i||!a||!n)){var s=Rk(e,n);if(s){var l=_M(s,t),c=Fb(l,o,a,r,i),u=HI(t,a,c,s);return{activeIndex:String(c),activeCoordinate:u}}}},n2=(e,t,n,r,i,a,o,s)=>{if(!(!e||!t||!r||!i||!a))return t==="horizontal"||t==="vertical"?e2(e,t,r,i,a,o,s):t2(e,t,n,r,i,a,o)},r2=P(e=>e.zIndex.zIndexMap,(e,t)=>t,(e,t,n)=>n,(e,t,n)=>{if(t!=null){var r=e[t];if(r!=null)return n?r.panoramaElement:r.element}});P(e=>e.zIndex.zIndexMap,e=>{var t=Object.keys(e).map(r=>parseInt(r,10)).concat(Object.values(wn)),n=Array.from(new Set(t));return n.sort((r,i)=>r-i)},{memoizeOptions:{resultEqualityCheck:LD}});function Jg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function em(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Jg(Object(n),!0).forEach(function(r){i2(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jg(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function i2(e,t,n){return(t=a2(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a2(e){var t=o2(e,"string");return typeof t=="symbol"?t:t+""}function o2(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var s2={},l2={zIndexMap:Object.values(wn).reduce((e,t)=>em(em({},e),{},{[t]:{element:void 0,panoramaElement:void 0,consumers:0}}),s2)},c2=new Set(Object.values(wn));function u2(e){return c2.has(e)}var Wb=Ne({name:"zIndex",initialState:l2,reducers:{registerZIndexPortal:{reducer:(e,t)=>{var{zIndex:n}=t.payload;e.zIndexMap[n]?e.zIndexMap[n].consumers+=1:e.zIndexMap[n]={consumers:1,element:void 0,panoramaElement:void 0}},prepare:te()},unregisterZIndexPortal:{reducer:(e,t)=>{var{zIndex:n}=t.payload;e.zIndexMap[n]&&(e.zIndexMap[n].consumers-=1,e.zIndexMap[n].consumers<=0&&!u2(n)&&delete e.zIndexMap[n])},prepare:te()},registerZIndexPortalElement:{reducer:(e,t)=>{var{zIndex:n,element:r,isPanorama:i}=t.payload;e.zIndexMap[n]?i?e.zIndexMap[n].panoramaElement=r:e.zIndexMap[n].element=r:e.zIndexMap[n]={consumers:0,element:i?void 0:r,panoramaElement:i?r:void 0}},prepare:te()},unregisterZIndexPortalElement:{reducer:(e,t)=>{var{zIndex:n}=t.payload;e.zIndexMap[n]&&(t.payload.isPanorama?e.zIndexMap[n].panoramaElement=void 0:e.zIndexMap[n].element=void 0)},prepare:te()}}}),{registerZIndexPortal:f2,unregisterZIndexPortal:d2,registerZIndexPortalElement:gL,unregisterZIndexPortalElement:mL}=Wb.actions,h2=Wb.reducer;function p2(e){var{zIndex:t,children:n}=e,r=nA(),i=r&&t!==void 0&&t!==0,a=fi(),o=Ke();w.useLayoutEffect(()=>i?(o(f2({zIndex:t})),()=>{o(d2({zIndex:t}))}):lr,[o,t,i]);var s=K(l=>r2(l,t,a));return i?s?wm.createPortal(n,s):null:n}function Pc(){return Pc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Pc.apply(null,arguments)}function tm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ji(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?tm(Object(n),!0).forEach(function(r){g2(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tm(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function g2(e,t,n){return(t=m2(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function m2(e){var t=v2(e,"string");return typeof t=="symbol"?t:t+""}function v2(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function y2(e){var{cursor:t,cursorComp:n,cursorProps:r}=e;return w.isValidElement(t)?w.cloneElement(t,r):w.createElement(n,r)}function b2(e){var t,{coordinate:n,payload:r,index:i,offset:a,tooltipAxisBandSize:o,layout:s,cursor:l,tooltipEventType:c,chartName:u}=e,f=n,d=r,h=i;if(!l||!f||u!=="ScatterChart"&&c!=="axis")return null;var p,m,g;if(u==="ScatterChart")p=f,m=UA,g=wn.cursorLine;else if(u==="BarChart")p=VA(s,f,a,o),m=Ry,g=wn.cursorRectangle;else if(s==="radial"&&Dv(f)){var{cx:v,cy:y,radius:b,startAngle:_,endAngle:x}=Ly(f);p={cx:v,cy:y,startAngle:_,endAngle:x,innerRadius:b,outerRadius:b},m=Bk,g=wn.cursorLine}else p={points:zk(s,f,a)},m=RA,g=wn.cursorLine;var S=typeof l=="object"&&"className"in l?l.className:void 0,O=Ji(Ji(Ji(Ji({stroke:"#ccc",pointerEvents:"none"},a),p),$c(l)),{},{payload:d,payloadIndex:h,className:Ze("recharts-tooltip-cursor",S)});return w.createElement(p2,{zIndex:(t=e.zIndex)!==null&&t!==void 0?t:g},w.createElement(y2,{cursor:l,cursorComp:m,cursorProps:O}))}function x2(e){var t=$I(),n=JM(),r=xo(),i=YI();return t==null||n==null||r==null||i==null?null:w.createElement(b2,Pc({},e,{offset:n,layout:r,tooltipAxisBandSize:t,chartName:i}))}var lf=w.createContext(null),_2=()=>w.useContext(lf),yl={exports:{}},nm;function w2(){return nm||(nm=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(l,c,u){this.fn=l,this.context=c,this.once=u||!1}function a(l,c,u,f,d){if(typeof u!="function")throw new TypeError("The listener must be a function");var h=new i(u,f||l,d),p=n?n+c:c;return l._events[p]?l._events[p].fn?l._events[p]=[l._events[p],h]:l._events[p].push(h):(l._events[p]=h,l._eventsCount++),l}function o(l,c){--l._eventsCount===0?l._events=new r:delete l._events[c]}function s(){this._events=new r,this._eventsCount=0}s.prototype.eventNames=function(){var c=[],u,f;if(this._eventsCount===0)return c;for(f in u=this._events)t.call(u,f)&&c.push(n?f.slice(1):f);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(u)):c},s.prototype.listeners=function(c){var u=n?n+c:c,f=this._events[u];if(!f)return[];if(f.fn)return[f.fn];for(var d=0,h=f.length,p=new Array(h);d<h;d++)p[d]=f[d].fn;return p},s.prototype.listenerCount=function(c){var u=n?n+c:c,f=this._events[u];return f?f.fn?1:f.length:0},s.prototype.emit=function(c,u,f,d,h,p){var m=n?n+c:c;if(!this._events[m])return!1;var g=this._events[m],v=arguments.length,y,b;if(g.fn){switch(g.once&&this.removeListener(c,g.fn,void 0,!0),v){case 1:return g.fn.call(g.context),!0;case 2:return g.fn.call(g.context,u),!0;case 3:return g.fn.call(g.context,u,f),!0;case 4:return g.fn.call(g.context,u,f,d),!0;case 5:return g.fn.call(g.context,u,f,d,h),!0;case 6:return g.fn.call(g.context,u,f,d,h,p),!0}for(b=1,y=new Array(v-1);b<v;b++)y[b-1]=arguments[b];g.fn.apply(g.context,y)}else{var _=g.length,x;for(b=0;b<_;b++)switch(g[b].once&&this.removeListener(c,g[b].fn,void 0,!0),v){case 1:g[b].fn.call(g[b].context);break;case 2:g[b].fn.call(g[b].context,u);break;case 3:g[b].fn.call(g[b].context,u,f);break;case 4:g[b].fn.call(g[b].context,u,f,d);break;default:if(!y)for(x=1,y=new Array(v-1);x<v;x++)y[x-1]=arguments[x];g[b].fn.apply(g[b].context,y)}}return!0},s.prototype.on=function(c,u,f){return a(this,c,u,f,!1)},s.prototype.once=function(c,u,f){return a(this,c,u,f,!0)},s.prototype.removeListener=function(c,u,f,d){var h=n?n+c:c;if(!this._events[h])return this;if(!u)return o(this,h),this;var p=this._events[h];if(p.fn)p.fn===u&&(!d||p.once)&&(!f||p.context===f)&&o(this,h);else{for(var m=0,g=[],v=p.length;m<v;m++)(p[m].fn!==u||d&&!p[m].once||f&&p[m].context!==f)&&g.push(p[m]);g.length?this._events[h]=g.length===1?g[0]:g:o(this,h)}return this},s.prototype.removeAllListeners=function(c){var u;return c?(u=n?n+c:c,this._events[u]&&o(this,u)):(this._events=new r,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=n,s.EventEmitter=s,e.exports=s})(yl)),yl.exports}var S2=w2();const O2=Qt(S2);var ii=new O2,Mc="recharts.syncEvent.tooltip",rm="recharts.syncEvent.brush",P2={chartName:"",tooltipPayloadSearcher:()=>{},eventEmitter:void 0,defaultTooltipEventType:"axis"},qb=Ne({name:"options",initialState:P2,reducers:{createEventEmitter:e=>{e.eventEmitter==null&&(e.eventEmitter=Symbol("rechartsEventEmitter"))}}}),M2=qb.reducer,{createEventEmitter:A2}=qb.actions;function k2(e){return e.tooltip.syncInteraction}var C2={chartData:void 0,computedData:void 0,dataStartIndex:0,dataEndIndex:0},Ub=Ne({name:"chartData",initialState:C2,reducers:{setChartData(e,t){if(e.chartData=t.payload,t.payload==null){e.dataStartIndex=0,e.dataEndIndex=0;return}t.payload.length>0&&e.dataEndIndex!==t.payload.length-1&&(e.dataEndIndex=t.payload.length-1)},setComputedData(e,t){e.computedData=t.payload},setDataStartEndIndexes(e,t){var{startIndex:n,endIndex:r}=t.payload;n!=null&&(e.dataStartIndex=n),r!=null&&(e.dataEndIndex=r)}}}),{setChartData:E2,setDataStartEndIndexes:D2,setComputedData:T2}=Ub.actions,I2=Ub.reducer,j2=["x","y"];function im(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function $n(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?im(Object(n),!0).forEach(function(r){R2(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):im(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function R2(e,t,n){return(t=L2(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function L2(e){var t=N2(e,"string");return typeof t=="symbol"?t:t+""}function N2(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function F2(e,t){if(e==null)return{};var n,r,i=B2(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function B2(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function z2(){var e=K(Ru),t=K(Lu),n=Ke(),r=K(D0),i=K(Nt),a=xo(),o=ou(),s=K(l=>l.rootProps.className);w.useEffect(()=>{if(e==null)return lr;var l=(c,u,f)=>{if(t!==f&&e===c){if(r==="index"){var d;if(o&&u!==null&&u!==void 0&&(d=u.payload)!==null&&d!==void 0&&d.coordinate&&u.payload.sourceViewBox){var h=u.payload.coordinate,{x:p,y:m}=h,g=F2(h,j2),{x:v,y,width:b,height:_}=u.payload.sourceViewBox,x=$n($n({},g),{},{x:o.x+(b?(p-v)/b:0)*o.width,y:o.y+(_?(m-y)/_:0)*o.height});n($n($n({},u),{},{payload:$n($n({},u.payload),{},{coordinate:x})}))}else n(u);return}if(i!=null){var S;if(typeof r=="function"){var O={activeTooltipIndex:u.payload.index==null?void 0:Number(u.payload.index),isTooltipActive:u.payload.active,activeIndex:u.payload.index==null?void 0:Number(u.payload.index),activeLabel:u.payload.label,activeDataKey:u.payload.dataKey,activeCoordinate:u.payload.coordinate},M=r(i,O);S=i[M]}else r==="value"&&(S=i.find(L=>String(L.value)===u.payload.label));var{coordinate:E}=u.payload;if(S==null||u.payload.active===!1||E==null||o==null){n(Sc({active:!1,coordinate:void 0,dataKey:void 0,index:null,label:void 0,sourceViewBox:void 0,graphicalItemId:void 0}));return}var{x:j,y:D}=E,A=Math.min(j,o.x+o.width),N=Math.min(D,o.y+o.height),R={x:a==="horizontal"?S.coordinate:A,y:a==="horizontal"?N:S.coordinate},T=Sc({active:u.payload.active,coordinate:R,dataKey:u.payload.dataKey,index:String(S.index),label:u.payload.label,sourceViewBox:u.payload.sourceViewBox,graphicalItemId:u.payload.graphicalItemId});n(T)}}};return ii.on(Mc,l),()=>{ii.off(Mc,l)}},[s,n,t,e,r,i,a,o])}function $2(){var e=K(Ru),t=K(Lu),n=Ke();w.useEffect(()=>{if(e==null)return lr;var r=(i,a,o)=>{t!==o&&e===i&&n(D2(a))};return ii.on(rm,r),()=>{ii.off(rm,r)}},[n,t,e])}function W2(){var e=Ke();w.useEffect(()=>{e(A2())},[e]),z2(),$2()}function q2(e,t,n,r,i,a){var o=K(h=>GI(h,e,t)),s=K(Lu),l=K(Ru),c=K(D0),u=K(k2),f=u?.active,d=ou();w.useEffect(()=>{if(!f&&l!=null&&s!=null){var h=Sc({active:a,coordinate:n,dataKey:o,index:i,label:typeof r=="number"?String(r):r,sourceViewBox:d,graphicalItemId:void 0});ii.emit(Mc,l,h,s)}},[f,n,o,i,r,s,l,c,a,d])}function am(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function om(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?am(Object(n),!0).forEach(function(r){U2(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):am(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function U2(e,t,n){return(t=V2(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function V2(e){var t=H2(e,"string");return typeof t=="symbol"?t:t+""}function H2(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function K2(e){return e.dataKey}function Y2(e,t){return w.isValidElement(e)?w.cloneElement(e,t):typeof e=="function"?w.createElement(e,t):w.createElement(_A,t)}var sm=[],X2={allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",axisId:0,contentStyle:{},cursor:!0,filterNull:!0,includeHidden:!1,isAnimationActive:"auto",itemSorter:"name",itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,wrapperStyle:{}};function vL(e){var t,n,r=si(e,X2),{active:i,allowEscapeViewBox:a,animationDuration:o,animationEasing:s,content:l,filterNull:c,isAnimationActive:u,offset:f,payloadUniqBy:d,position:h,reverseDirection:p,useTranslate3d:m,wrapperStyle:g,cursor:v,shared:y,trigger:b,defaultIndex:_,portal:x,axisId:S}=r,O=Ke(),M=typeof _=="number"?String(_):_;w.useEffect(()=>{O(KT({shared:y,trigger:b,axisId:S,active:i,defaultIndex:M}))},[O,y,b,S,i,M]);var E=ou(),j=CA(),D=$T(y),{activeIndex:A,isActive:N}=(t=K(De=>JI(De,D,b,M)))!==null&&t!==void 0?t:{},R=K(De=>QI(De,D,b,M)),T=K(De=>$b(De,D,b,M)),L=K(De=>ZI(De,D,b,M)),F=R,oe=_2(),J=(n=i??N)!==null&&n!==void 0?n:!1,[U,Me]=cP([F,J]),se=D==="axis"?T:void 0;q2(D,b,L,se,A,J);var _e=x??oe;if(_e==null||E==null||D==null)return null;var re=F??sm;J||(re=sm),c&&re.length&&(re=RO(re.filter(De=>De.value!=null&&(De.hide!==!0||r.includeHidden)),d,K2));var we=re.length>0,Se=w.createElement(kA,{allowEscapeViewBox:a,animationDuration:o,animationEasing:s,isAnimationActive:u,active:J,coordinate:L,hasPayload:we,offset:f,position:h,reverseDirection:p,useTranslate3d:m,viewBox:E,wrapperStyle:g,lastBoundingBox:U,innerRef:Me,hasPortalFromProps:!!x},Y2(l,om(om({},r),{},{payload:re,label:se,active:J,activeIndex:A,coordinate:L,accessibilityLayer:j})));return w.createElement(w.Fragment,null,wm.createPortal(Se,_e),J&&w.createElement(x2,{cursor:v,tooltipEventType:D,coordinate:L,payload:re,index:A}))}var bl={},xl={},lm;function G2(){return lm||(lm=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){if(n.length===0)return;let i=n[0],a=r(i,0,n);for(let o=1;o<n.length;o++){const s=n[o],l=r(s,o,n);l>a&&(a=l,i=s)}return i}e.maxBy=t})(xl)),xl}var cm;function Z2(){return cm||(cm=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=G2(),n=Yc(),r=Gc();function i(a,o){if(a!=null)return t.maxBy(Array.from(a),r.iteratee(o??n.identity))}e.maxBy=i})(bl)),bl}var _l,um;function Q2(){return um||(um=1,_l=Z2().maxBy),_l}var J2=Q2();const ej=Qt(J2);var tj={radiusAxis:{},angleAxis:{}},Vb=Ne({name:"polarAxis",initialState:tj,reducers:{addRadiusAxis(e,t){e.radiusAxis[t.payload.id]=t.payload},removeRadiusAxis(e,t){delete e.radiusAxis[t.payload.id]},addAngleAxis(e,t){e.angleAxis[t.payload.id]=t.payload},removeAngleAxis(e,t){delete e.angleAxis[t.payload.id]}}}),{addRadiusAxis:yL,removeRadiusAxis:bL,addAngleAxis:xL,removeAngleAxis:_L}=Vb.actions,nj=Vb.reducer;function rj(e){var{tooltipEntrySettings:t}=e,n=Ke(),r=fi(),i=w.useRef(null);return w.useLayoutEffect(()=>{r||(i.current===null?n(UT(t)):i.current!==t&&n(VT({prev:i.current,next:t})),i.current=t)},[t,n,r]),w.useLayoutEffect(()=>()=>{i.current&&(n(HT(i.current)),i.current=null)},[n]),null}var wl,ij=()=>{var[e]=w.useState(()=>Vl("uid-"));return e},aj=(wl=cx.useId)!==null&&wl!==void 0?wl:ij;function oj(e,t){var n=aj();return t||(e?"".concat(e,"-").concat(n):n)}var sj=w.createContext(void 0),lj=e=>{var{id:t,type:n,children:r}=e,i=oj("recharts-".concat(n),t);return w.createElement(sj.Provider,{value:i},r(i))},cj={cartesianItems:[],polarItems:[]},Hb=Ne({name:"graphicalItems",initialState:cj,reducers:{addCartesianGraphicalItem:{reducer(e,t){e.cartesianItems.push(t.payload)},prepare:te()},replaceCartesianGraphicalItem:{reducer(e,t){var{prev:n,next:r}=t.payload,i=ot(e).cartesianItems.indexOf(n);i>-1&&(e.cartesianItems[i]=r)},prepare:te()},removeCartesianGraphicalItem:{reducer(e,t){var n=ot(e).cartesianItems.indexOf(t.payload);n>-1&&e.cartesianItems.splice(n,1)},prepare:te()},addPolarGraphicalItem:{reducer(e,t){e.polarItems.push(t.payload)},prepare:te()},removePolarGraphicalItem:{reducer(e,t){var n=ot(e).polarItems.indexOf(t.payload);n>-1&&e.polarItems.splice(n,1)},prepare:te()}}}),{addCartesianGraphicalItem:wL,replaceCartesianGraphicalItem:SL,removeCartesianGraphicalItem:OL,addPolarGraphicalItem:PL,removePolarGraphicalItem:ML}=Hb.actions,uj=Hb.reducer;function fm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function dm(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fm(Object(n),!0).forEach(function(r){fj(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fm(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function fj(e,t,n){return(t=dj(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function dj(e){var t=hj(e,"string");return typeof t=="symbol"?t:t+""}function hj(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var pj={xAxis:{},yAxis:{},zAxis:{}},Kb=Ne({name:"cartesianAxis",initialState:pj,reducers:{addXAxis:{reducer(e,t){e.xAxis[t.payload.id]=t.payload},prepare:te()},replaceXAxis:{reducer(e,t){var{prev:n,next:r}=t.payload;e.xAxis[n.id]!==void 0&&(n.id!==r.id&&delete e.xAxis[n.id],e.xAxis[r.id]=r)},prepare:te()},removeXAxis:{reducer(e,t){delete e.xAxis[t.payload.id]},prepare:te()},addYAxis:{reducer(e,t){e.yAxis[t.payload.id]=t.payload},prepare:te()},replaceYAxis:{reducer(e,t){var{prev:n,next:r}=t.payload;e.yAxis[n.id]!==void 0&&(n.id!==r.id&&delete e.yAxis[n.id],e.yAxis[r.id]=r)},prepare:te()},removeYAxis:{reducer(e,t){delete e.yAxis[t.payload.id]},prepare:te()},addZAxis:{reducer(e,t){e.zAxis[t.payload.id]=t.payload},prepare:te()},replaceZAxis:{reducer(e,t){var{prev:n,next:r}=t.payload;e.zAxis[n.id]!==void 0&&(n.id!==r.id&&delete e.zAxis[n.id],e.zAxis[r.id]=r)},prepare:te()},removeZAxis:{reducer(e,t){delete e.zAxis[t.payload.id]},prepare:te()},updateYAxisWidth(e,t){var{id:n,width:r}=t.payload,i=e.yAxis[n];if(i){var a,o=i.widthHistory||[];if(o.length===3&&o[0]===o[2]&&r===o[1]&&r!==i.width&&Math.abs(r-((a=o[0])!==null&&a!==void 0?a:0))<=1)return;var s=[...o,r].slice(-3);e.yAxis[n]=dm(dm({},i),{},{width:r,widthHistory:s})}}}}),{addXAxis:AL,replaceXAxis:kL,removeXAxis:CL,addYAxis:EL,replaceYAxis:DL,removeYAxis:TL,addZAxis:IL,replaceZAxis:jL,removeZAxis:RL,updateYAxisWidth:LL}=Kb.actions,gj=Kb.reducer,mj=e=>{var{computedData:t}=e,n=Ke();return w.useEffect(()=>(n(T2(t)),()=>{n(E2(void 0))}),[t,n]),null},hm={x:0,y:0,width:0,height:0,padding:{top:0,right:0,bottom:0,left:0}},Yb=Ne({name:"brush",initialState:hm,reducers:{setBrushSettings(e,t){return t.payload==null?hm:t.payload}}}),{setBrushSettings:NL}=Yb.actions,vj=Yb.reducer,yj={dots:[],areas:[],lines:[]},Xb=Ne({name:"referenceElements",initialState:yj,reducers:{addDot:(e,t)=>{e.dots.push(t.payload)},removeDot:(e,t)=>{var n=ot(e).dots.findIndex(r=>r===t.payload);n!==-1&&e.dots.splice(n,1)},addArea:(e,t)=>{e.areas.push(t.payload)},removeArea:(e,t)=>{var n=ot(e).areas.findIndex(r=>r===t.payload);n!==-1&&e.areas.splice(n,1)},addLine:(e,t)=>{e.lines.push(t.payload)},removeLine:(e,t)=>{var n=ot(e).lines.findIndex(r=>r===t.payload);n!==-1&&e.lines.splice(n,1)}}}),{addDot:FL,removeDot:BL,addArea:zL,removeArea:$L,addLine:WL,removeLine:qL}=Xb.actions,bj=Xb.reducer,xj={},Gb=Ne({name:"errorBars",initialState:xj,reducers:{addErrorBar:(e,t)=>{var{itemId:n,errorBar:r}=t.payload;e[n]||(e[n]=[]),e[n].push(r)},replaceErrorBar:(e,t)=>{var{itemId:n,prev:r,next:i}=t.payload;e[n]&&(e[n]=e[n].map(a=>a.dataKey===r.dataKey&&a.direction===r.direction?i:a))},removeErrorBar:(e,t)=>{var{itemId:n,errorBar:r}=t.payload;e[n]&&(e[n]=e[n].filter(i=>i.dataKey!==r.dataKey||i.direction!==r.direction))}}}),{addErrorBar:UL,replaceErrorBar:VL,removeErrorBar:HL}=Gb.actions,_j=Gb.reducer,Sl={exports:{}},Ol={};var pm;function wj(){if(pm)return Ol;pm=1;var e=kc();function t(l,c){return l===c&&(l!==0||1/l===1/c)||l!==l&&c!==c}var n=typeof Object.is=="function"?Object.is:t,r=e.useSyncExternalStore,i=e.useRef,a=e.useEffect,o=e.useMemo,s=e.useDebugValue;return Ol.useSyncExternalStoreWithSelector=function(l,c,u,f,d){var h=i(null);if(h.current===null){var p={hasValue:!1,value:null};h.current=p}else p=h.current;h=o(function(){function g(x){if(!v){if(v=!0,y=x,x=f(x),d!==void 0&&p.hasValue){var S=p.value;if(d(S,x))return b=S}return b=x}if(S=b,n(y,x))return S;var O=f(x);return d!==void 0&&d(S,O)?(y=x,S):(y=x,b=O)}var v=!1,y,b,_=u===void 0?null:u;return[function(){return g(c())},_===null?void 0:function(){return g(_())}]},[c,u,f,d]);var m=r(l,h[0],h[1]);return a(function(){p.hasValue=!0,p.value=m},[m]),s(m),m},Ol}var gm;function Sj(){return gm||(gm=1,Sl.exports=wj()),Sl.exports}Sj();function Oj(e){e()}function Pj(){let e=null,t=null;return{clear(){e=null,t=null},notify(){Oj(()=>{let n=e;for(;n;)n.callback(),n=n.next})},get(){const n=[];let r=e;for(;r;)n.push(r),r=r.next;return n},subscribe(n){let r=!0;const i=t={callback:n,next:null,prev:t};return i.prev?i.prev.next=i:e=i,function(){!r||e===null||(r=!1,i.next?i.next.prev=i.prev:t=i.prev,i.prev?i.prev.next=i.next:e=i.next)}}}}var mm={notify(){},get:()=>[]};function Mj(e,t){let n,r=mm,i=0,a=!1;function o(m){u();const g=r.subscribe(m);let v=!1;return()=>{v||(v=!0,g(),f())}}function s(){r.notify()}function l(){p.onStateChange&&p.onStateChange()}function c(){return a}function u(){i++,n||(n=e.subscribe(l),r=Pj())}function f(){i--,n&&i===0&&(n(),n=void 0,r.clear(),r=mm)}function d(){a||(a=!0,u())}function h(){a&&(a=!1,f())}const p={addNestedSub:o,notifyNestedSubs:s,handleChangeWrapper:l,isSubscribed:c,trySubscribe:d,tryUnsubscribe:h,getListeners:()=>r};return p}var Aj=()=>typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",kj=Aj(),Cj=()=>typeof navigator<"u"&&navigator.product==="ReactNative",Ej=Cj(),Dj=()=>kj||Ej?w.useLayoutEffect:w.useEffect,Tj=Dj(),Ij=Symbol.for("react-redux-context"),jj=typeof globalThis<"u"?globalThis:{};function Rj(){if(!w.createContext)return{};const e=jj[Ij]??=new Map;let t=e.get(w.createContext);return t||(t=w.createContext(null),e.set(w.createContext,t)),t}var Lj=Rj();function Nj(e){const{children:t,context:n,serverState:r,store:i}=e,a=w.useMemo(()=>{const l=Mj(i);return{store:i,subscription:l,getServerState:r?()=>r:void 0}},[i,r]),o=w.useMemo(()=>i.getState(),[i]);Tj(()=>{const{subscription:l}=a;return l.onStateChange=l.notifyNestedSubs,l.trySubscribe(),o!==i.getState()&&l.notifyNestedSubs(),()=>{l.tryUnsubscribe(),l.onStateChange=void 0}},[a,o]);const s=n||Lj;return w.createElement(s.Provider,{value:a},t)}var Fj=Nj,Bj=(e,t)=>t,cf=P([Bj,ce,RD,xe,Ib,Nt,XI,Ae],n2),uf=e=>{var t=e.currentTarget.getBoundingClientRect(),n=t.width/e.currentTarget.offsetWidth,r=t.height/e.currentTarget.offsetHeight;return{chartX:Math.round((e.clientX-t.left)/n),chartY:Math.round((e.clientY-t.top)/r)}},Zb=Je("mouseClick"),Qb=ci();Qb.startListening({actionCreator:Zb,effect:(e,t)=>{var n=e.payload,r=cf(t.getState(),uf(n));r?.activeIndex!=null&&t.dispatch(YT({activeIndex:r.activeIndex,activeDataKey:void 0,activeCoordinate:r.activeCoordinate}))}});var Ac=Je("mouseMove"),Jb=ci(),ea=null;Jb.startListening({actionCreator:Ac,effect:(e,t)=>{var n=e.payload;ea!==null&&cancelAnimationFrame(ea);var r=uf(n);ea=requestAnimationFrame(()=>{var i=t.getState(),a=Gu(i,i.tooltip.settings.shared);if(a==="axis"){var o=cf(i,r);o?.activeIndex!=null?t.dispatch(Ob({activeIndex:o.activeIndex,activeDataKey:void 0,activeCoordinate:o.activeCoordinate})):t.dispatch(wb())}ea=null})}});function zj(e,t){return t instanceof HTMLElement?"HTMLElement <".concat(t.tagName,' class="').concat(t.className,'">'):t===window?"global.window":e==="children"&&typeof t=="object"&&t!==null?"<<CHILDREN>>":t}var vm={accessibilityLayer:!0,barCategoryGap:"10%",barGap:4,barSize:void 0,className:void 0,maxBarSize:void 0,stackOffset:"none",syncId:void 0,syncMethod:"index",baseValue:void 0,reverseStackOrder:!1},ex=Ne({name:"rootProps",initialState:vm,reducers:{updateOptions:(e,t)=>{var n;e.accessibilityLayer=t.payload.accessibilityLayer,e.barCategoryGap=t.payload.barCategoryGap,e.barGap=(n=t.payload.barGap)!==null&&n!==void 0?n:vm.barGap,e.barSize=t.payload.barSize,e.maxBarSize=t.payload.maxBarSize,e.stackOffset=t.payload.stackOffset,e.syncId=t.payload.syncId,e.syncMethod=t.payload.syncMethod,e.className=t.payload.className,e.baseValue=t.payload.baseValue,e.reverseStackOrder=t.payload.reverseStackOrder}}}),$j=ex.reducer,{updateOptions:KL}=ex.actions,Wj=null,qj={updatePolarOptions:(e,t)=>t.payload},tx=Ne({name:"polarOptions",initialState:Wj,reducers:qj}),{updatePolarOptions:YL}=tx.actions,Uj=tx.reducer,nx=Je("keyDown"),rx=Je("focus"),ff=ci();ff.startListening({actionCreator:nx,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip,a=e.payload;if(!(a!=="ArrowRight"&&a!=="ArrowLeft"&&a!=="Enter")){var o=Qu(i,vr(n),xi(n),wi(n)),s=o==null?-1:Number(o);if(!(!Number.isFinite(s)||s<0)){var l=Nt(n);if(a==="Enter"){var c=Ga(n,"axis","hover",String(i.index));t.dispatch(Oc({active:!i.active,activeIndex:i.index,activeCoordinate:c}));return}var u=zT(n),f=u==="left-to-right"?1:-1,d=a==="ArrowRight"?1:-1,h=s+d*f;if(!(l==null||h>=l.length||h<0)){var p=Ga(n,"axis","hover",String(h));t.dispatch(Oc({active:!0,activeIndex:h.toString(),activeCoordinate:p}))}}}}}});ff.startListening({actionCreator:rx,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip;if(!i.active&&i.index==null){var a="0",o=Ga(n,"axis","hover",String(a));t.dispatch(Oc({active:!0,activeIndex:a,activeCoordinate:o}))}}}});var Xe=Je("externalEvent"),ix=ci(),Pl=new Map;ix.startListening({actionCreator:Xe,effect:(e,t)=>{var{handler:n,reactEvent:r}=e.payload;if(n!=null){r.persist();var i=r.type,a=Pl.get(i);a!==void 0&&cancelAnimationFrame(a);var o=requestAnimationFrame(()=>{try{var s=t.getState(),l={activeCoordinate:jI(s),activeDataKey:TI(s),activeIndex:Xa(s),activeLabel:Lb(s),activeTooltipIndex:Xa(s),isTooltipActive:RI(s)};n(l,r)}finally{Pl.delete(i)}});Pl.set(i,o)}}});var Vj=P([gr],e=>e.tooltipItemPayloads),Hj=P([Vj,(e,t)=>t,(e,t,n)=>n],(e,t,n)=>{if(t!=null){var r=e.find(a=>a.settings.graphicalItemId===n);if(r!=null){var{getPosition:i}=r;if(i!=null)return i(t)}}}),ax=Je("touchMove"),ox=ci();ox.startListening({actionCreator:ax,effect:(e,t)=>{var n=e.payload;if(!(n.touches==null||n.touches.length===0)){var r=t.getState(),i=Gu(r,r.tooltip.settings.shared);if(i==="axis"){var a=n.touches[0];if(a==null)return;var o=cf(r,uf({clientX:a.clientX,clientY:a.clientY,currentTarget:n.currentTarget}));o?.activeIndex!=null&&t.dispatch(Ob({activeIndex:o.activeIndex,activeDataKey:void 0,activeCoordinate:o.activeCoordinate}))}else if(i==="item"){var s,l=n.touches[0];if(document.elementFromPoint==null||l==null)return;var c=document.elementFromPoint(l.clientX,l.clientY);if(!c||!c.getAttribute)return;var u=c.getAttribute(SM),f=(s=c.getAttribute(OM))!==null&&s!==void 0?s:void 0,d=mr(r).find(m=>m.id===f);if(u==null||d==null||f==null)return;var{dataKey:h}=d,p=Hj(r,u,f);t.dispatch(Zu({activeDataKey:h,activeIndex:u,activeCoordinate:p,activeGraphicalItemId:f}))}}}});var Kj=Vv({brush:vj,cartesianAxis:gj,chartData:I2,errorBars:_j,graphicalItems:uj,layout:lM,legend:mA,options:M2,polarAxis:nj,polarOptions:Uj,referenceElements:bj,rootProps:$j,tooltip:XT,zIndex:h2}),Yj=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"Chart";return jP({reducer:Kj,preloadedState:t,middleware:r=>{var i;return r({serializableCheck:!1,immutableCheck:!["commonjs","es6","production"].includes((i="es6")!==null&&i!==void 0?i:"")}).concat([Qb.middleware,Jb.middleware,ff.middleware,ix.middleware,ox.middleware])},enhancers:r=>{var i=r;return typeof r=="function"&&(i=r()),i.concat(oy({type:"raf"}))},devTools:{serialize:{replacer:zj},name:"recharts-".concat(n)}})};function Xj(e){var{preloadedState:t,children:n,reduxStoreName:r}=e,i=fi(),a=w.useRef(null);if(i)return n;a.current==null&&(a.current=Yj(t,r));var o=Zc;return w.createElement(Fj,{context:o,store:a.current},n)}function Gj(){var e=Ke(),[t,n]=w.useState(null),r=K(wM);return w.useEffect(()=>{if(t!=null){var i=t.getBoundingClientRect(),a=i.width/t.offsetWidth;Q(a)&&a!==r&&e(sM(a))}},[t,e,r]),n}function ym(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Zj(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ym(Object(n),!0).forEach(function(r){Qj(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ym(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Qj(e,t,n){return(t=Jj(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Jj(e){var t=eR(e,"string");return typeof t=="symbol"?t:t+""}function eR(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Kt(){return Kt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Kt.apply(null,arguments)}var tR=()=>(W2(),null);function Za(e){if(typeof e=="number")return e;if(typeof e=="string"){var t=parseFloat(e);if(!Number.isNaN(t))return t}return 0}var nR=w.forwardRef((e,t)=>{var n,r,i=w.useRef(null),[a,o]=w.useState({containerWidth:Za((n=e.style)===null||n===void 0?void 0:n.width),containerHeight:Za((r=e.style)===null||r===void 0?void 0:r.height)}),s=w.useCallback((c,u)=>{o(f=>{var d=Math.round(c),h=Math.round(u);return f.containerWidth===d&&f.containerHeight===h?f:{containerWidth:d,containerHeight:h}})},[]),l=w.useCallback(c=>{if(typeof t=="function"&&t(c),c!=null&&typeof ResizeObserver<"u"){var{width:u,height:f}=c.getBoundingClientRect();s(u,f);var d=p=>{var m=p[0];if(m!=null){var{width:g,height:v}=m.contentRect;s(g,v)}},h=new ResizeObserver(d);h.observe(c),i.current=h}},[t,s]);return w.useEffect(()=>()=>{var c=i.current;c?.disconnect()},[s]),w.createElement(w.Fragment,null,w.createElement(di,{width:a.containerWidth,height:a.containerHeight}),w.createElement("div",Kt({ref:l},e)))}),rR=w.forwardRef((e,t)=>{var{width:n,height:r}=e,[i,a]=w.useState({containerWidth:Za(n),containerHeight:Za(r)}),o=w.useCallback((l,c)=>{a(u=>{var f=Math.round(l),d=Math.round(c);return u.containerWidth===f&&u.containerHeight===d?u:{containerWidth:f,containerHeight:d}})},[]),s=w.useCallback(l=>{if(typeof t=="function"&&t(l),l!=null){var{width:c,height:u}=l.getBoundingClientRect();o(c,u)}},[t,o]);return w.createElement(w.Fragment,null,w.createElement(di,{width:i.containerWidth,height:i.containerHeight}),w.createElement("div",Kt({ref:s},e)))}),iR=w.forwardRef((e,t)=>{var{width:n,height:r}=e;return w.createElement(w.Fragment,null,w.createElement(di,{width:n,height:r}),w.createElement("div",Kt({ref:t},e)))}),aR=w.forwardRef((e,t)=>{var{width:n,height:r}=e;return typeof n=="string"||typeof r=="string"?w.createElement(rR,Kt({},e,{ref:t})):typeof n=="number"&&typeof r=="number"?w.createElement(iR,Kt({},e,{width:n,height:r,ref:t})):w.createElement(w.Fragment,null,w.createElement(di,{width:n,height:r}),w.createElement("div",Kt({ref:t},e)))});function oR(e){return e?nR:aR}var sR=w.forwardRef((e,t)=>{var{children:n,className:r,height:i,onClick:a,onContextMenu:o,onDoubleClick:s,onMouseDown:l,onMouseEnter:c,onMouseLeave:u,onMouseMove:f,onMouseUp:d,onTouchEnd:h,onTouchMove:p,onTouchStart:m,style:g,width:v,responsive:y,dispatchTouchEvents:b=!0}=e,_=w.useRef(null),x=Ke(),[S,O]=w.useState(null),[M,E]=w.useState(null),j=Gj(),D=au(),A=D?.width>0?D.width:v,N=D?.height>0?D.height:i,R=w.useCallback(k=>{j(k),typeof t=="function"&&t(k),O(k),E(k),k!=null&&(_.current=k)},[j,t,O,E]),T=w.useCallback(k=>{x(Zb(k)),x(Xe({handler:a,reactEvent:k}))},[x,a]),L=w.useCallback(k=>{x(Ac(k)),x(Xe({handler:c,reactEvent:k}))},[x,c]),F=w.useCallback(k=>{x(wb()),x(Xe({handler:u,reactEvent:k}))},[x,u]),oe=w.useCallback(k=>{x(Ac(k)),x(Xe({handler:f,reactEvent:k}))},[x,f]),J=w.useCallback(()=>{x(rx())},[x]),U=w.useCallback(k=>{x(nx(k.key))},[x]),Me=w.useCallback(k=>{x(Xe({handler:o,reactEvent:k}))},[x,o]),se=w.useCallback(k=>{x(Xe({handler:s,reactEvent:k}))},[x,s]),_e=w.useCallback(k=>{x(Xe({handler:l,reactEvent:k}))},[x,l]),re=w.useCallback(k=>{x(Xe({handler:d,reactEvent:k}))},[x,d]),we=w.useCallback(k=>{x(Xe({handler:m,reactEvent:k}))},[x,m]),Se=w.useCallback(k=>{b&&x(ax(k)),x(Xe({handler:p,reactEvent:k}))},[x,b,p]),De=w.useCallback(k=>{x(Xe({handler:h,reactEvent:k}))},[x,h]),$o=oR(y);return w.createElement(lf.Provider,{value:S},w.createElement(LS.Provider,{value:M},w.createElement($o,{width:A??g?.width,height:N??g?.height,className:Ze("recharts-wrapper",r),style:Zj({position:"relative",cursor:"default",width:A,height:N},g),onClick:T,onContextMenu:Me,onDoubleClick:se,onFocus:J,onKeyDown:U,onMouseDown:_e,onMouseEnter:L,onMouseLeave:F,onMouseMove:oe,onMouseUp:re,onTouchEnd:De,onTouchMove:Se,onTouchStart:we,ref:R},w.createElement(tR,null),n)))}),Ml={},bm;function lR(){return bm||(bm=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Gc();function n(r,i){if(!r||!r.length)return 0;i!=null&&(i=t.iteratee(i));let a;for(let o=0;o<r.length;o++){const s=i?i(r[o]):r[o];s!==void 0&&(a===void 0?a=s:a+=s)}return a}e.sumBy=n})(Ml)),Ml}var Al,xm;function cR(){return xm||(xm=1,Al=lR().sumBy),Al}var uR=cR();const fR=Qt(uR);var dR=["sourceX","sourceY","sourceControlX","targetX","targetY","targetControlX","linkWidth"],hR=["className","style","children","id"];function rr(){return rr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},rr.apply(null,arguments)}function sx(e,t){if(e==null)return{};var n,r,i=pR(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function pR(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function _m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function bt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?_m(Object(n),!0).forEach(function(r){gR(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_m(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function gR(e,t,n){return(t=mR(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mR(e){var t=vR(e,"string");return typeof t=="symbol"?t:t+""}function vR(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var yR=(e,t)=>{var n=+e,r=t-n;return i=>n+r*i},zo=e=>e.y+e.dy/2,ai=e=>e&&e.value||0,Qa=(e,t)=>t.reduce((n,r)=>n+ai(e[r]),0),bR=(e,t,n)=>n.reduce((r,i)=>{var a=t[i];if(a==null)return r;var o=e[a.source];return o==null?r:r+zo(o)*ai(t[i])},0),xR=(e,t,n)=>n.reduce((r,i)=>{var a=t[i];if(a==null)return r;var o=e[a.target];return o==null?r:r+zo(o)*ai(t[i])},0),_R=(e,t)=>e.y-t.y,wR=(e,t)=>{for(var n=[],r=[],i=[],a=[],o=0,s=e.length;o<s;o++){var l=e[o];l?.source===t&&(i.push(l.target),a.push(o)),l?.target===t&&(n.push(l.source),r.push(o))}return{sourceNodes:n,sourceLinks:r,targetLinks:a,targetNodes:i}},lx=(e,t)=>{for(var{targetNodes:n}=t,r=0,i=n.length;r<i;r++){var a=n[r];if(a!=null){var o=e[a];o&&(o.depth=Math.max(t.depth+1,o.depth),lx(e,o))}}},SR=(e,t,n,r)=>{for(var i,a,{nodes:o,links:s}=e,l=o.map((v,y)=>{var b=wR(s,y);return bt(bt(bt({},v),b),{},{value:Math.max(Qa(s,b.sourceLinks),Qa(s,b.targetLinks)),depth:0})}),c=0,u=l.length;c<u;c++){var f=l[c];f!=null&&!f.sourceNodes.length&&lx(l,f)}var d=(i=(a=ej(l,v=>v.depth))===null||a===void 0?void 0:a.depth)!==null&&i!==void 0?i:0;if(d>=1)for(var h=(t-n)/d,p=0,m=l.length;p<m;p++){var g=l[p];g!=null&&(g.targetNodes.length||r==="justify"&&(g.depth=d),g.x=g.depth*h,g.dx=n)}return{tree:l,maxDepth:d}},OR=e=>{for(var t=[],n=0,r=e.length;n<r;n++){var i,a=e[n];a!=null&&(t[a.depth]||(t[a.depth]=[]),(i=t[a.depth])===null||i===void 0||i.push(a))}return t},PR=(e,t,n,r,i)=>{for(var a=Math.min(...e.map(g=>(t-(g.length-1)*n)/fR(g,ai))),o=0,s=e.length;o<s;o++){var l=e[o];if(l!=null)if(i==="top")for(var c=0,u=0,f=l.length;u<f;u++){var d=l[u];d!=null&&(d.dy=d.value*a,d.y=c,c+=d.dy+n)}else for(var h=0,p=l.length;h<p;h++){var m=l[h];m!=null&&(m.y=h,m.dy=m.value*a)}}return r.map(g=>bt(bt({},g),{},{dy:ai(g)*a}))},kl=function(t,n,r){for(var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,a=0,o=t.length;a<o;a++){var s=t[a];if(s!=null){var l=s.length;i&&s.sort(_R);for(var c=0,u=0;u<l;u++){var f=s[u];if(f!=null){var d=c-f.y;d>0&&(f.y+=d),c=f.y+f.dy+r}}c=n+r;for(var h=l-1;h>=0;h--){var p=s[h];if(p!=null){var m=p.y+p.dy+r-c;if(m>0)p.y-=m,c=p.y;else break}}}}},MR=(e,t,n,r)=>{for(var i=0,a=t.length;i<a;i++){var o=t[i];if(o!=null)for(var s=0,l=o.length;s<l;s++){var c=o[s];if(c!=null&&c.sourceLinks.length){var u=Qa(n,c.sourceLinks),f=bR(e,n,c.sourceLinks),d=f/u;c.y+=(d-zo(c))*r}}}},AR=(e,t,n,r)=>{for(var i=t.length-1;i>=0;i--){var a=t[i];if(a!=null)for(var o=0,s=a.length;o<s;o++){var l=a[o];if(l!=null&&l.targetLinks.length){var c=Qa(n,l.targetLinks),u=xR(e,n,l.targetLinks),f=u/c;l.y+=(f-zo(l))*r}}}},kR=(e,t)=>{for(var n=0,r=e.length;n<r;n++){var i=e[n];if(i!=null){var a=0,o=0;i.targetLinks.sort((m,g)=>{var v,y,b,_,x=(v=t[m])===null||v===void 0?void 0:v.target,S=(y=t[g])===null||y===void 0?void 0:y.target;if(x==null||S==null)return 0;var O=(b=e[x])===null||b===void 0?void 0:b.y,M=(_=e[S])===null||_===void 0?void 0:_.y;return O==null||M==null?0:O-M}),i.sourceLinks.sort((m,g)=>{var v,y,b,_,x=(v=t[m])===null||v===void 0?void 0:v.source,S=(y=t[g])===null||y===void 0?void 0:y.source;if(x==null||S==null)return 0;var O=(b=e[x])===null||b===void 0?void 0:b.y,M=(_=e[S])===null||_===void 0?void 0:_.y;return O==null||M==null?0:O-M});for(var s=0,l=i.targetLinks.length;s<l;s++){var c=i.targetLinks[s];if(c!=null){var u=t[c];u&&(u.sy=a,a+=u.dy)}}for(var f=0,d=i.sourceLinks.length;f<d;f++){var h=i.sourceLinks[f];if(h!=null){var p=t[h];p&&(p.ty=o,o+=p.dy)}}}}},CR=e=>{var{data:t,width:n,height:r,iterations:i,nodeWidth:a,nodePadding:o,sort:s,verticalAlign:l,align:c}=e,{links:u}=t,{tree:f}=SR(t,n,a,c),d=OR(f),h=PR(d,r,o,u,l);if(kl(d,r,o,s),l==="justify")for(var p=1,m=1;m<=i;m++)AR(f,d,h,p*=.99),kl(d,r,o,s),MR(f,d,h,p),kl(d,r,o,s);kR(f,h);var g=h;return{nodes:f,links:g}},ER=e=>({x:+e.x+ +e.width/2,y:+e.y+ +e.height/2}),DR=e=>"sourceX"in e?{x:(e.sourceX+e.targetX)/2,y:(e.sourceY+e.targetY)/2}:void 0,TR=(e,t,n)=>{var{payload:r}=e;if(t==="node")return{payload:r,name:ve(r,n,""),value:ve(r,"value")};if("source"in r&&r.source&&r.target){var i=ve(r.source,n,""),a=ve(r.target,n,"");return{payload:r,name:"".concat(i," - ").concat(a),value:ve(r,"value")}}},IR=(e,t,n,r)=>{if(!(t==null||typeof t!="string")&&!(n==null||typeof n!="object")){var i=t.split("-"),[a,o]=i,s=Hc(n,"".concat(a,"s[").concat(o,"]"));if(s){var l=TR(s,a,r);return l}}},jR={chartName:"Sankey",defaultTooltipEventType:"item",validateTooltipEventTypes:["item"],tooltipPayloadSearcher:IR,eventEmitter:void 0},RR=w.memo(e=>{var{dataKey:t,nameKey:n,stroke:r,strokeWidth:i,fill:a,name:o,data:s,id:l}=e,c={dataDefinedOnItem:s,getPosition:lr,settings:{stroke:r,strokeWidth:i,fill:a,dataKey:t,name:o,nameKey:n,hide:!1,type:void 0,color:a,unit:"",graphicalItemId:l}};return w.createElement(rj,{tooltipEntrySettings:c})});function LR(e,t){if(w.isValidElement(e))return w.cloneElement(e,t);if(typeof e=="function")return e(t);var{sourceX:n,sourceY:r,sourceControlX:i,targetX:a,targetY:o,targetControlX:s,linkWidth:l}=t,c=sx(t,dR);return w.createElement("path",rr({className:"recharts-sankey-link",d:`
|
|
34
|
-
M`.concat(n,",").concat(r,`
|
|
35
|
-
C`).concat(i,",").concat(r," ").concat(s,",").concat(o," ").concat(a,",").concat(o,`
|
|
36
|
-
`),fill:"none",stroke:"#333",strokeWidth:l,strokeOpacity:"0.2"},Xn(c)))}var NR=e=>{var{link:t,nodes:n,left:r,top:i,i:a,linkContent:o,linkCurvature:s}=e,{sy:l,ty:c,dy:u}=t,f=n[t.source],d=n[t.target];if(!(f==null||d==null)){var h=f.x+f.dx+r,p=d.x+r,m=yR(h,p),g=m(s),v=m(1-s),y=f.y+l+u/2+i,b=d.y+c+u/2+i,_=bt({sourceX:h,targetX:p,sourceY:y,targetY:b,sourceControlX:g,targetControlX:v,sourceRelativeY:l,targetRelativeY:c,linkWidth:u,index:a,payload:bt(bt({},t),{},{source:f,target:d})},$c(o));return _}};function FR(e){var{graphicalItemId:t,props:n,i:r,linkContent:i,onMouseEnter:a,onMouseLeave:o,onClick:s,dataKey:l}=e,c=DR(n),u="link-".concat(r),f=Ke(),d={onMouseEnter:h=>{f(Zu({activeIndex:u,activeDataKey:l,activeCoordinate:c,activeGraphicalItemId:t})),a(n,h)},onMouseLeave:h=>{f(_b()),o(n,h)},onClick:h=>{f(Sb({activeIndex:u,activeDataKey:l,activeCoordinate:c,activeGraphicalItemId:t})),s(n,h)}};return w.createElement(ro,d,LR(i,n))}function BR(e){var{graphicalItemId:t,modifiedLinks:n,links:r,linkContent:i,onMouseEnter:a,onMouseLeave:o,onClick:s,dataKey:l}=e;return w.createElement(ro,{className:"recharts-sankey-links",key:"recharts-sankey-links"},r.map((c,u)=>{var f=n[u];return f==null?null:w.createElement(FR,{graphicalItemId:t,key:"link-".concat(c.source,"-").concat(c.target,"-").concat(c.value),props:f,linkContent:i,i:u,onMouseEnter:a,onMouseLeave:o,onClick:s,dataKey:l})}))}function zR(e,t){return w.isValidElement(e)?w.cloneElement(e,t):typeof e=="function"?e(t):w.createElement(Ry,rr({className:"recharts-sankey-node",fill:"#0088fe",fillOpacity:"0.8"},Xn(t)))}var $R=e=>{var{node:t,nodeContent:n,top:r,left:i,i:a}=e,{x:o,y:s,dx:l,dy:c}=t,u=bt(bt({},$c(n)),{},{x:o+i,y:s+r,width:l,height:c,index:a,payload:t});return u};function WR(e){var{graphicalItemId:t,props:n,nodeContent:r,i,onMouseEnter:a,onMouseLeave:o,onClick:s,dataKey:l}=e,c=Ke(),u=ER(n),f="node-".concat(i),d={onMouseEnter:h=>{c(Zu({activeIndex:f,activeDataKey:l,activeCoordinate:u,activeGraphicalItemId:t})),a(n,h)},onMouseLeave:h=>{c(_b()),o(n,h)},onClick:h=>{c(Sb({activeIndex:f,activeDataKey:l,activeCoordinate:u,activeGraphicalItemId:t})),s(n,h)}};return w.createElement(ro,d,zR(r,n))}function qR(e){var{graphicalItemId:t,modifiedNodes:n,nodeContent:r,onMouseEnter:i,onMouseLeave:a,onClick:o,dataKey:s}=e;return w.createElement(ro,{className:"recharts-sankey-nodes",key:"recharts-sankey-nodes"},n.map((l,c)=>w.createElement(WR,{graphicalItemId:t,key:"node-".concat(l.index,"-").concat(l.x,"-").concat(l.y),props:l,nodeContent:r,i:c,onMouseEnter:i,onMouseLeave:a,onClick:o,dataKey:s})))}var UR={align:"justify",dataKey:"value",iterations:32,linkCurvature:.5,margin:{top:5,right:5,bottom:5,left:5},nameKey:"name",nodePadding:10,nodeWidth:10,sort:!0,verticalAlign:"justify"};function VR(e){var{className:t,style:n,children:r,id:i}=e,a=sx(e,hR),{link:o,dataKey:s,node:l,onMouseEnter:c,onMouseLeave:u,onClick:f,data:d,iterations:h,nodeWidth:p,nodePadding:m,sort:g,linkCurvature:v,margin:y,verticalAlign:b,align:_}=e,x=Xn(a),S=eA(),O=tA(),{links:M,modifiedLinks:E,modifiedNodes:j}=w.useMemo(()=>{var R,T,L,F;if(!d||!S||!O||S<=0||O<=0)return{nodes:[],links:[],modifiedLinks:[],modifiedNodes:[]};var oe=S-((R=y.left)!==null&&R!==void 0?R:0)-((T=y.right)!==null&&T!==void 0?T:0),J=O-((L=y.top)!==null&&L!==void 0?L:0)-((F=y.bottom)!==null&&F!==void 0?F:0),U=CR({data:d,width:oe,height:J,iterations:h,nodeWidth:p,nodePadding:m,sort:g,verticalAlign:b,align:_}),Me=y.top||0,se=y.left||0,_e=U.links.map((we,Se)=>NR({link:we,nodes:U.nodes,i:Se,top:Me,left:se,linkContent:o,linkCurvature:v})).filter(at),re=U.nodes.map((we,Se)=>$R({node:we,nodeContent:l,i:Se,top:Me,left:se}));return{nodes:U.nodes,links:U.links,modifiedLinks:_e,modifiedNodes:re}},[d,S,O,y,h,p,m,g,o,l,v,_,b]),D=w.useCallback((R,T,L)=>{c&&c(R,T,L)},[c]),A=w.useCallback((R,T,L)=>{u&&u(R,T,L)},[u]),N=w.useCallback((R,T,L)=>{f&&f(R,T,L)},[f]);return!Zt(S)||!Zt(O)||!d||!d.links||!d.nodes?null:w.createElement(w.Fragment,null,w.createElement(mj,{computedData:{links:E,nodes:j}}),w.createElement(TS,rr({},x,{width:S,height:O}),r,w.createElement(BR,{graphicalItemId:i,links:M,modifiedLinks:E,linkContent:o,dataKey:s,onMouseEnter:(R,T)=>D(R,"link",T),onMouseLeave:(R,T)=>A(R,"link",T),onClick:(R,T)=>N(R,"link",T)}),w.createElement(qR,{graphicalItemId:i,modifiedNodes:j,nodeContent:l,dataKey:s,onMouseEnter:(R,T)=>D(R,"node",T),onMouseLeave:(R,T)=>A(R,"node",T),onClick:(R,T)=>N(R,"node",T)})))}function HR(e){var t=si(e,UR),{width:n,height:r,style:i,className:a,id:o}=t,[s,l]=w.useState(null);return w.createElement(Xj,{preloadedState:{options:jR},reduxStoreName:a??"Sankey"},w.createElement(di,{width:n,height:r}),w.createElement(rA,{margin:t.margin}),w.createElement(sR,{className:a,style:i,width:n,height:r,responsive:!1,ref:c=>{c&&!s&&l(c)},onMouseEnter:void 0,onMouseLeave:void 0,onClick:void 0,onMouseMove:void 0,onMouseDown:void 0,onMouseUp:void 0,onContextMenu:void 0,onDoubleClick:void 0,onTouchStart:void 0,onTouchMove:void 0,onTouchEnd:void 0},w.createElement(lf.Provider,{value:s},w.createElement(lj,{id:o,type:"sankey"},c=>w.createElement(w.Fragment,null,w.createElement(RR,{dataKey:t.dataKey,nameKey:t.nameKey,stroke:t.stroke,strokeWidth:t.strokeWidth,fill:t.fill,name:t.name,data:t.data,id:c}),w.createElement(VR,rr({},t,{id:c})))))))}HR.displayName="Sankey";export{XR as B,U1 as C,GR as L,JR as P,cL as R,ZR as S,vL as T,iL as a,aL as b,Ze as c,eL as d,QR as e,tL as f,HR as g,Ry as h,YR as i,ro as j,rL as p};
|