@cloudhal/cli 0.2.0 → 0.3.1

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.
Files changed (165) hide show
  1. package/dist/assets/starters/blog/package.json +4 -4
  2. package/dist/assets/studio/assets/AccountPage-Bm5BeHWl.js +2 -0
  3. package/dist/assets/studio/assets/{ActivityPage-C0HlgSI5.js → ActivityPage-D8RUaugX.js} +2 -2
  4. package/dist/assets/studio/assets/{AgentModes-B81a2nUo.js → AgentModes-CP8u-uXl.js} +2 -2
  5. package/dist/assets/studio/assets/AgentsPage-CaH_5r7Z.js +2 -0
  6. package/dist/assets/studio/assets/AnalyticsPage-BmO0u8xD.js +3 -0
  7. package/dist/assets/studio/assets/ApprovalDialog-DXKCyEdf.js +2 -0
  8. package/dist/assets/studio/assets/ApprovalsPage-q-birvZ1.js +3 -0
  9. package/dist/assets/studio/assets/ArticleEditorPage-lHoUmERU.js +2 -0
  10. package/dist/assets/studio/assets/ArticlesPage-C4HQcyMZ.js +2 -0
  11. package/dist/assets/studio/assets/{AssetPage-ddWJt0hs.js → AssetPage-b0erj1AI.js} +2 -2
  12. package/dist/assets/studio/assets/{Audit-BCzf5vBq.js → Audit-DgbpP_nz.js} +2 -2
  13. package/dist/assets/studio/assets/AuditBadges-BEqBnWoz.js +2 -0
  14. package/dist/assets/studio/assets/{AuthLayout-Cidy_2Lu.js → AuthLayout-CXAGkrx9.js} +2 -2
  15. package/dist/assets/studio/assets/AutomationsPage-C4pRmT5O.js +2 -0
  16. package/dist/assets/studio/assets/{BlockSection-CnUXl5Sg.js → BlockSection-TZc72IgX.js} +2 -2
  17. package/dist/assets/studio/assets/{BodyChanges-M0zcsivC.js → BodyChanges-WuQnhlDk.js} +3 -3
  18. package/dist/assets/studio/assets/BuildPage-CtH9Zwbu.js +2 -0
  19. package/dist/assets/studio/assets/{CommandMenu-CH5CJ8Kg.js → CommandMenu-BVT-HHW0.js} +2 -2
  20. package/dist/assets/studio/assets/{CommentThreadControls-D04pICZT.js → CommentThreadControls-CXNj8JY7.js} +2 -2
  21. package/dist/assets/studio/assets/{CommentThreadPage-BP0N9T4z.js → CommentThreadPage-DyXjmoOu.js} +2 -2
  22. package/dist/assets/studio/assets/{CommenterPage-CeFR4pn4.js → CommenterPage-ClHD0q_d.js} +2 -2
  23. package/dist/assets/studio/assets/Comments-sU22Wp1j.js +2 -0
  24. package/dist/assets/studio/assets/CommentsPage-C7tWqq_I.js +2 -0
  25. package/dist/assets/studio/assets/{ConfirmDialog-DEHkMoTj.js → ConfirmDialog-DKmz4y5Q.js} +2 -2
  26. package/dist/assets/studio/assets/{Crumbs-Ci_RdgHU.js → Crumbs-DOM6tT0l.js} +2 -2
  27. package/dist/assets/studio/assets/{EditorLayout-DVegYcZT.js → EditorLayout-ieqpWD3O.js} +2 -2
  28. package/dist/assets/studio/assets/{EditorPreview-DsZG4-oJ.js → EditorPreview-BMn8JFyR.js} +2 -2
  29. package/dist/assets/studio/assets/{Elevation-Ca3Q8sk-.js → Elevation-B3H1KYdW.js} +2 -2
  30. package/dist/assets/studio/assets/{ElevationRequest-B0_Q_gVT.js → ElevationRequest-DiCnHA-N.js} +2 -2
  31. package/dist/assets/studio/assets/{ForgotPasswordPage-LNtBXfC8.js → ForgotPasswordPage-ClPZ6VQ0.js} +2 -2
  32. package/dist/assets/studio/assets/Gating-mRuy0Aw6.js +2 -0
  33. package/dist/assets/studio/assets/{GovernanceDialog-DR0m4Bhp.js → GovernanceDialog-BOsmZ9sA.js} +2 -2
  34. package/dist/assets/studio/assets/{InvitePage-CZ-4Clg6.js → InvitePage-DHe4I49a.js} +2 -2
  35. package/dist/assets/studio/assets/{ListToolbar-CE70usqf.js → ListToolbar-D0cz9A9i.js} +2 -2
  36. package/dist/assets/studio/assets/LoginPage-CaYvxxAx.js +2 -0
  37. package/dist/assets/studio/assets/{MediaPage-D7h4RBbB.js → MediaPage-cRqqqjDj.js} +2 -2
  38. package/dist/assets/studio/assets/{MediaPicker-DlJLkaGR.js → MediaPicker-zwukL6LF.js} +2 -2
  39. package/dist/assets/studio/assets/{MediaUpload-BpTyBTHG.js → MediaUpload-D_NqJMLl.js} +2 -2
  40. package/dist/assets/studio/assets/MembersPage-nFZuQGQj.js +2 -0
  41. package/dist/assets/studio/assets/{Menus-ChmyHrPc.js → Menus-DiSEzHBI.js} +2 -2
  42. package/dist/assets/studio/assets/NavigationPage-CnDJF3N5.js +2 -0
  43. package/dist/assets/studio/assets/{NewSiteDialog-D7SUMMY3.js → NewSiteDialog-B5ogDopi.js} +2 -2
  44. package/dist/assets/studio/assets/PageEditorPage-CWb1gYnd.js +5 -0
  45. package/dist/assets/studio/assets/PagesPage-B0efBfNw.js +2 -0
  46. package/dist/assets/studio/assets/{PasswordField-Cn0g88_l.js → PasswordField-CQUUxc5O.js} +2 -2
  47. package/dist/assets/studio/assets/{PreviewPanel-ChFoJD1H.js → PreviewPanel-DJfEXxjT.js} +2 -2
  48. package/dist/assets/studio/assets/{ProjectPage-e5BSkkda.js → ProjectPage-Bkk5B7Kk.js} +2 -2
  49. package/dist/assets/studio/assets/Readers-D8WTNlW_.js +3 -0
  50. package/dist/assets/studio/assets/RedirectDialog-CmFr73CR.js +2 -0
  51. package/dist/assets/studio/assets/RedirectsPage-CiYRLydI.js +2 -0
  52. package/dist/assets/studio/assets/{ReleaseApproval-gkciKrWx.js → ReleaseApproval-Cr8kHN7B.js} +2 -2
  53. package/dist/assets/studio/assets/ReleasePage-qOzPM_1T.js +2 -0
  54. package/dist/assets/studio/assets/ReleaseParts-BJCwLv3d.js +2 -0
  55. package/dist/assets/studio/assets/{ResetPasswordPage-DLpZlh7i.js → ResetPasswordPage-Bga7XJxi.js} +2 -2
  56. package/dist/assets/studio/assets/RocketLaunch.es-BTDML1jE.js +2 -0
  57. package/dist/assets/studio/assets/RowMenu-jMjMjIez.js +2 -0
  58. package/dist/assets/studio/assets/ScheduleCard-DzvtvUrB.js +2 -0
  59. package/dist/assets/studio/assets/{ScheduleDialog-B-QQ_Z3F.js → ScheduleDialog-BEIBEgNY.js} +2 -2
  60. package/dist/assets/studio/assets/{ScheduleHistoryPage-wv3pKfaZ.js → ScheduleHistoryPage-Cqvbso0N.js} +2 -2
  61. package/dist/assets/studio/assets/{ScheduleStatusBadge-DHGmEyDv.js → ScheduleStatusBadge-CvtbjKcE.js} +2 -2
  62. package/dist/assets/studio/assets/{SchedulerStalled-DUmZxbV4.js → SchedulerStalled-v8egx5_5.js} +2 -2
  63. package/dist/assets/studio/assets/Schedules-Bi_9IGap.js +3 -0
  64. package/dist/assets/studio/assets/SchedulesPage-AVUyMVLN.js +2 -0
  65. package/dist/assets/studio/assets/{ScopeBadge-DM2PO5Xk.js → ScopeBadge-CXRIKJV-.js} +2 -2
  66. package/dist/assets/studio/assets/{SectionCard-SzT8t6oM.js → SectionCard-253RWE03.js} +2 -2
  67. package/dist/assets/studio/assets/{Seo-CYyFHl3G.js → Seo-BAmAoHie.js} +2 -2
  68. package/dist/assets/studio/assets/{SeoPreview-tarmyT2Y.js → SeoPreview-BD_qXwU3.js} +2 -2
  69. package/dist/assets/studio/assets/{Settings-C407Vxml.js → Settings-PNFH1Q2d.js} +2 -2
  70. package/dist/assets/studio/assets/{SiteAccessField-D34vIaAo.js → SiteAccessField-B6rXWqPA.js} +2 -2
  71. package/dist/assets/studio/assets/SiteOverviewPage-BHlgtKxn.js +4 -0
  72. package/dist/assets/studio/assets/SiteSettingsPage-CK5oODPR.js +3 -0
  73. package/dist/assets/studio/assets/{SitesPage-B2QS2zaq.js → SitesPage-Bv9wYnBR.js} +3 -3
  74. package/dist/assets/studio/assets/{SkillsPage-BtFk0bBw.js → SkillsPage-CzzFsQCY.js} +3 -3
  75. package/dist/assets/studio/assets/SnapshotsPage-B38WZn18.js +2 -0
  76. package/dist/assets/studio/assets/{Status-BgB2wP8j.js → Status-Ck8cp5VU.js} +2 -2
  77. package/dist/assets/studio/assets/StatusActions-ClWdGpev.js +3 -0
  78. package/dist/assets/studio/assets/{TagsMigration-BggsWH7A.js → TagsMigration-DHPq_z7b.js} +2 -2
  79. package/dist/assets/studio/assets/{Taxonomy-CeQUBEeZ.js → Taxonomy-CDd52lEj.js} +2 -2
  80. package/dist/assets/studio/assets/TaxonomyPage-hmMDxUPP.js +2 -0
  81. package/dist/assets/studio/assets/TermEditorPage-rhF98Ssd.js +2 -0
  82. package/dist/assets/studio/assets/{TermPickers-cZIwRG5t.js → TermPickers-DzlmKYS_.js} +2 -2
  83. package/dist/assets/studio/assets/{Toast-BHyBhGXI.js → Toast-MSfrCjAr.js} +2 -2
  84. package/dist/assets/studio/assets/TranslationList-BOWeWTue.js +2 -0
  85. package/dist/assets/studio/assets/{TranslationsPage-MFJsWMgX.js → TranslationsPage-B0DP9mDX.js} +2 -2
  86. package/dist/assets/studio/assets/{api-Sbz4Rbu7.js → api-K4ZsoxSR.js} +2 -2
  87. package/dist/assets/studio/assets/{api-errors-FBnZYqCy.js → api-errors-MOGC4Qux.js} +2 -2
  88. package/dist/assets/studio/assets/{approvals-BB74ogKx.js → approvals-0AbtJUeH.js} +2 -2
  89. package/dist/assets/studio/assets/{ar-6o5tS7uI.js → ar-B7Q-Tnf1.js} +2 -2
  90. package/dist/assets/studio/assets/{charts-DL9SbRU8.js → charts-CcTdxwHf.js} +2 -2
  91. package/dist/assets/studio/assets/{clipboard-text-gd6s3n1bqse9zgt8-DXnAaY6R.js → clipboard-text-gd6s3n1bqse9zgt8-8cLlgBwE.js} +2 -2
  92. package/dist/assets/studio/assets/{collapsible-l8g94on4w7qfosmn-udgP1bfF.js → collapsible-l8g94on4w7qfosmn-B4g2i1uh.js} +2 -2
  93. package/dist/assets/studio/assets/{combobox-hdxtsm2gqcxxgfju-BzzDlvd3.js → combobox-hdxtsm2gqcxxgfju-DXYGsrSK.js} +2 -2
  94. package/dist/assets/studio/assets/{createToastManager-onmoqrmr8zo02rif-DtEv4lxV.js → createToastManager-onmoqrmr8zo02rif-DFnQWIYL.js} +2 -2
  95. package/dist/assets/studio/assets/{de-BN-GS_nX.js → de-DLXuL-X-.js} +2 -2
  96. package/dist/assets/studio/assets/{deleteLabels-DwQes2_M.js → deleteLabels-QAHG4PeV.js} +2 -2
  97. package/dist/assets/studio/assets/{dialog-glpnivujociqs9lh-BefDeRGC.js → dialog-glpnivujociqs9lh-B2sB0Q83.js} +2 -2
  98. package/dist/assets/studio/assets/dropdown-m53ji1d66mws89wh-CX3moquw.js +2 -0
  99. package/dist/assets/studio/assets/{editor-C9MhZu7g.js → editor-Bq67msVD.js} +2 -2
  100. package/dist/assets/studio/assets/{es-C1E3agwU.js → es-BygirbfZ.js} +2 -2
  101. package/dist/assets/studio/assets/{fa-VZyv0VcS.js → fa-CYekV1Xs.js} +2 -2
  102. package/dist/assets/studio/assets/{fr-IaaUvy1z.js → fr-D-Y48Px4.js} +2 -2
  103. package/dist/assets/studio/assets/{he-Ca3dnXtb.js → he-CfuQu8tf.js} +2 -2
  104. package/dist/assets/studio/assets/{hi-BXkaH5dy.js → hi-HzeORH2z.js} +2 -2
  105. package/dist/assets/studio/assets/{i18n-Cjiv6Esx.js → i18n-B-06kDA4.js} +3 -3
  106. package/dist/assets/studio/assets/{id-BuNEmn7g.js → id-AW4tXw9G.js} +2 -2
  107. package/dist/assets/studio/assets/index-BLFwX4Tg.css +2 -0
  108. package/dist/assets/studio/assets/index-DWzjnrnl.js +4 -0
  109. package/dist/assets/studio/assets/{it-DEB0m7yM.js → it-EGuJa8fC.js} +2 -2
  110. package/dist/assets/studio/assets/{ja-BJv09PXI.js → ja-JiIbNjTZ.js} +2 -2
  111. package/dist/assets/studio/assets/{ko-Cikp2ojH.js → ko-yEoxGMly.js} +2 -2
  112. package/dist/assets/studio/assets/{layer-dialog-j5ywmzs46ccg6oqy-DyWF5y24.js → layer-dialog-j5ywmzs46ccg6oqy-Dg9cqt2A.js} +2 -2
  113. package/dist/assets/studio/assets/{media-DqHiLqTz.js → media-BnpTZ1vj.js} +2 -2
  114. package/dist/assets/studio/assets/{nl-BiYEXj4B.js → nl-s9UiFHkp.js} +2 -2
  115. package/dist/assets/studio/assets/{pl-Iaem81Jv.js → pl-B9qa5oln.js} +2 -2
  116. package/dist/assets/studio/assets/{pt-BR-CM8N0OoK.js → pt-BR-B2hZUyrW.js} +2 -2
  117. package/dist/assets/studio/assets/{ru-2qsjd_Gm.js → ru-DYmqB5PL.js} +2 -2
  118. package/dist/assets/studio/assets/{schedules-api-B7c4AXSw.js → schedules-api-CZRkol2x.js} +2 -2
  119. package/dist/assets/studio/assets/{tag-input-ohfybx5dbxy3houy-DhZt3VBi.js → tag-input-ohfybx5dbxy3houy-0qdjxuFW.js} +2 -2
  120. package/dist/assets/studio/assets/{tr-BK-gVqHj.js → tr-COm1KgYY.js} +2 -2
  121. package/dist/assets/studio/assets/{uk-PoqqfkaM.js → uk-DdtNKfpf.js} +2 -2
  122. package/dist/assets/studio/assets/{useAnalyticsCard-MXajmsui.js → useAnalyticsCard-k_xTTAyd.js} +2 -2
  123. package/dist/assets/studio/assets/{useMe-z-wff5FW.js → useMe-Cx8D2_vf.js} +2 -2
  124. package/dist/assets/studio/assets/{usePaging-BiNrjkE2.js → usePaging-pE8aE7JW.js} +2 -2
  125. package/dist/assets/studio/assets/usePendingApprovals-B6g17X7P.js +2 -0
  126. package/dist/assets/studio/assets/{zh-Hans-BYiQm8Cr.js → zh-Hans-DCvEU7yR.js} +2 -2
  127. package/dist/assets/studio/index.html +24 -20
  128. package/package.json +11 -11
  129. package/dist/assets/studio/assets/AccountPage-Dzr5d8sk.js +0 -2
  130. package/dist/assets/studio/assets/AgentsPage-BzCOyX4g.js +0 -2
  131. package/dist/assets/studio/assets/AnalyticsPage-7yb7DBOH.js +0 -3
  132. package/dist/assets/studio/assets/ApprovalsPage-_tqc02mk.js +0 -3
  133. package/dist/assets/studio/assets/ArticleEditorPage-Bcb81dXC.js +0 -2
  134. package/dist/assets/studio/assets/ArticlesPage-152INxny.js +0 -2
  135. package/dist/assets/studio/assets/AuditBadges-C4sNtzf9.js +0 -2
  136. package/dist/assets/studio/assets/AutomationsPage-Dc6g5v_v.js +0 -2
  137. package/dist/assets/studio/assets/BuildPage-C1Nwy4dt.js +0 -2
  138. package/dist/assets/studio/assets/Comments-CnfKPS2z.js +0 -2
  139. package/dist/assets/studio/assets/CommentsPage-BlP_knlf.js +0 -2
  140. package/dist/assets/studio/assets/Gating-BdY3KxOv.js +0 -2
  141. package/dist/assets/studio/assets/LockSimple.es-D3HQqnoN.js +0 -2
  142. package/dist/assets/studio/assets/LoginPage-BfUjD7n3.js +0 -2
  143. package/dist/assets/studio/assets/MembersPage-BNu1FOBL.js +0 -2
  144. package/dist/assets/studio/assets/NavigationPage-C10U827y.js +0 -2
  145. package/dist/assets/studio/assets/PageEditorPage-DBJUAqjk.js +0 -5
  146. package/dist/assets/studio/assets/PagesPage-Bwm8b58m.js +0 -2
  147. package/dist/assets/studio/assets/Readers-CvhU7wCy.js +0 -3
  148. package/dist/assets/studio/assets/RedirectDialog-DCNKLV43.js +0 -2
  149. package/dist/assets/studio/assets/RedirectsPage-CR1Di-T6.js +0 -2
  150. package/dist/assets/studio/assets/ReleasePage-BRa167d9.js +0 -2
  151. package/dist/assets/studio/assets/ReleaseParts-BEMf510p.js +0 -2
  152. package/dist/assets/studio/assets/RowMenu-BTHdea9k.js +0 -2
  153. package/dist/assets/studio/assets/ScheduleCard-BQWUIwPX.js +0 -2
  154. package/dist/assets/studio/assets/Schedules-R6HfROIM.js +0 -3
  155. package/dist/assets/studio/assets/SchedulesPage-CIbzmMag.js +0 -2
  156. package/dist/assets/studio/assets/SiteOverviewPage-Bm0-f1bp.js +0 -4
  157. package/dist/assets/studio/assets/SiteSettingsPage-tq4SzyMQ.js +0 -3
  158. package/dist/assets/studio/assets/SnapshotsPage-cltqpJLv.js +0 -2
  159. package/dist/assets/studio/assets/StatusActions-tY-DY4Wa.js +0 -3
  160. package/dist/assets/studio/assets/TaxonomyPage-hm0h5Ug5.js +0 -2
  161. package/dist/assets/studio/assets/TermEditorPage-tRUgbC0f.js +0 -2
  162. package/dist/assets/studio/assets/TranslationList-Cc4K8uy_.js +0 -2
  163. package/dist/assets/studio/assets/index-Boved2Nz.js +0 -4
  164. package/dist/assets/studio/assets/index-DaI1wvdp.css +0 -2
  165. package/dist/assets/studio/assets/usePendingApprovals-BRHKM3-1.js +0 -2
@@ -1,4 +1,4 @@
1
- import{n as e,r as t}from"./rolldown-runtime-hePW80VL.js";import{n,t as r}from"./IconBase.es-BZDpYMnj.js";import{i,r as a}from"./react-CDCuUAOg.js";import{n as o,t as s}from"./button-pa1bq9b85hawg41a-BcGpLLER.js";import{t as c}from"./DirectionalIcon-BKKMj3KT.js";import{n as l}from"./skeleton-line-m9dyh126t9k07jvg-CHsT8Hs3.js";import{t as u}from"./Table.es-6S52tmK7.js";import{a as d,n as f,r as p,t as m}from"./StatTile-DyU32i8V.js";import{t as h}from"./table-yf8ul2e5nbemioi1-DNq9jhfh.js";import{a as g,n as _,r as v,t as y}from"./useChartPalette-DXG2lo2x.js";import{r as b}from"./analytics-range-BqKm9TTo.js";import{st as x}from"./index-Boved2Nz.js";var S=t(i(),1),C=new Map([[`bold`,S.createElement(S.Fragment,null,S.createElement(`path`,{d:`M232.49,160.49l-48,48a12,12,0,0,1-17-17L195,164H128A108.12,108.12,0,0,1,20,56a12,12,0,0,1,24,0,84.09,84.09,0,0,0,84,84h67l-27.52-27.51a12,12,0,0,1,17-17l48,48A12,12,0,0,1,232.49,160.49Z`}))],[`fill`,S.createElement(S.Fragment,null,S.createElement(`path`,{d:`M229.66,157.66l-48,48A8,8,0,0,1,168,200V160H128A104.11,104.11,0,0,1,24,56a8,8,0,0,1,16,0,88.1,88.1,0,0,0,88,88h40V104a8,8,0,0,1,13.66-5.66l48,48A8,8,0,0,1,229.66,157.66Z`}))],[`regular`,S.createElement(S.Fragment,null,S.createElement(`path`,{d:`M229.66,157.66l-48,48a8,8,0,0,1-11.32-11.32L204.69,160H128A104.11,104.11,0,0,1,24,56a8,8,0,0,1,16,0,88.1,88.1,0,0,0,88,88h76.69l-34.35-34.34a8,8,0,0,1,11.32-11.32l48,48A8,8,0,0,1,229.66,157.66Z`}))]]),w=S.forwardRef((e,t)=>S.createElement(r,{ref:t,...e,weights:C}));w.displayName=`ArrowBendDownRightIcon`;var T=w,E=function(e,t){return E=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},E(e,t)};function D(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);E(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var O=`12px sans-serif`,k=20,A=100,j=`007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N`;function ee(e){var t={};if(typeof JSON>`u`)return t;for(var n=0;n<e.length;n++){var r=String.fromCharCode(n+32);t[r]=(e.charCodeAt(n)-k)/A}return t}var te=ee(j),M={createCanvas:function(){return typeof document<`u`&&document.createElement(`canvas`)},measureText:(function(){var e,t;return function(n,r){if(!e){var i=M.createCanvas();e=i&&i.getContext(`2d`)}if(e)return t!==r&&(t=e.font=r||`12px sans-serif`),e.measureText(n);n||=``,r||=`12px sans-serif`;var a=/((?:\d+)?\.?\d*)px/.exec(r),o=a&&+a[1]||12,s=0;if(r.indexOf(`mono`)>=0)s=o*n.length;else for(var c=0;c<n.length;c++){var l=te[n[c]];s+=l==null?o:l*o}return{width:s}}})(),loadImage:function(e,t,n){var r=new Image;return r.onload=t,r.onerror=n,r.src=e,r},getTime:function(){return Date.now?Date.now():+new Date}};function ne(e){for(var t in M)M.hasOwnProperty(t)&&e[t]&&(M[t]=e[t])}var re=e({EPSILON:()=>rt,HashMap:()=>Xe,RADIAN_TO_DEGREE:()=>nt,assert:()=>He,assignProps:()=>ye,bind:()=>H,clone:()=>P,concatArray:()=>Ze,createCanvas:()=>be,createHashMap:()=>J,createObject:()=>Qe,curry:()=>Oe,defaults:()=>L,disableUserSelect:()=>$e,each:()=>z,eqNaN:()=>Le,extend:()=>I,filter:()=>Te,find:()=>Ee,guid:()=>ge,hasOwn:()=>et,indexOf:()=>R,inherits:()=>xe,isArray:()=>U,isArrayLike:()=>Ce,isBuiltInObject:()=>je,isDom:()=>Ne,isFunction:()=>W,isGradientObject:()=>Pe,isImagePatternObject:()=>Fe,isNumber:()=>Ae,isObject:()=>K,isPrimitive:()=>Ke,isRegExp:()=>Ie,isString:()=>G,isStringSafe:()=>ke,isTypedArray:()=>Me,keys:()=>V,logError:()=>_e,map:()=>B,merge:()=>F,mergeAll:()=>ve,mixin:()=>Se,noop:()=>tt,normalizeCssArray:()=>Ve,reduce:()=>we,retrieve:()=>Re,retrieve2:()=>q,retrieve3:()=>ze,setAsPrimitive:()=>Ge,slice:()=>Be,trim:()=>Ue}),ie=we([`Function`,`RegExp`,`Date`,`Error`,`CanvasGradient`,`CanvasPattern`,`Image`,`Canvas`],function(e,t){return e[`[object `+t+`]`]=!0,e},{}),ae=we([`Int8`,`Uint8`,`Uint8Clamped`,`Int16`,`Uint16`,`Int32`,`Uint32`,`Float32`,`Float64`],function(e,t){return e[`[object `+t+`Array]`]=!0,e},{}),oe=Object.prototype.toString,se=Array.prototype,ce=se.forEach,le=se.filter,ue=se.slice,de=se.map,fe=function(){}.constructor,N=fe?fe.prototype:null,pe=`__proto__`,me=2311,he=2**53-1;function ge(){return me>=he&&(me=0),me++}function _e(){var e=[...arguments];typeof console<`u`&&console.error.apply(console,e)}function P(e){if(typeof e!=`object`||!e)return e;var t=e,n=oe.call(e);if(n===`[object Array]`){if(!Ke(e)){t=[];for(var r=0,i=e.length;r<i;r++)t[r]=P(e[r])}}else if(ae[n]){if(!Ke(e)){var a=e.constructor;if(a.from)t=a.from(e);else{t=new a(e.length);for(var r=0,i=e.length;r<i;r++)t[r]=e[r]}}}else if(!ie[n]&&!Ke(e)&&!Ne(e))for(var o in t={},e)e.hasOwnProperty(o)&&o!==pe&&(t[o]=P(e[o]));return t}function F(e,t,n){if(!K(t)||!K(e))return n?P(t):e;for(var r in t)if(t.hasOwnProperty(r)&&r!==pe){var i=e[r],a=t[r];K(a)&&K(i)&&!U(a)&&!U(i)&&!Ne(a)&&!Ne(i)&&!je(a)&&!je(i)&&!Ke(a)&&!Ke(i)?F(i,a,n):(n||!(r in e))&&(e[r]=P(t[r]))}return e}function ve(e,t){for(var n=e[0],r=1,i=e.length;r<i;r++)n=F(n,e[r],t);return n}function I(e,t){if(Object.assign)Object.assign(e,t);else for(var n in t)t.hasOwnProperty(n)&&n!==pe&&(e[n]=t[n]);return e}function ye(e,t,n){e||={};for(var r=0;r<n.length;r++){var i=n[r];e[i]=t[i]}return e}function L(e,t,n){for(var r=V(t),i=0,a=r.length;i<a;i++){var o=r[i];(n?t[o]!=null:e[o]==null)&&(e[o]=t[o])}return e}var be=M.createCanvas;function R(e,t){if(e){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n}return-1}function xe(e,t){var n=e.prototype;function r(){}for(var i in r.prototype=t.prototype,e.prototype=new r,n)n.hasOwnProperty(i)&&(e.prototype[i]=n[i]);e.prototype.constructor=e,e.superClass=t}function Se(e,t,n){if(e=`prototype`in e?e.prototype:e,t=`prototype`in t?t.prototype:t,Object.getOwnPropertyNames)for(var r=Object.getOwnPropertyNames(t),i=0;i<r.length;i++){var a=r[i];a!==`constructor`&&(n?t[a]!=null:e[a]==null)&&(e[a]=t[a])}else L(e,t,n)}function Ce(e){return!e||typeof e==`string`?!1:typeof e.length==`number`}function z(e,t,n){if(e&&t){if(e.forEach&&e.forEach===ce)e.forEach(t,n);else if(e.length===+e.length)for(var r=0,i=e.length;r<i;r++)t.call(n,e[r],r,e);else for(var a in e)e.hasOwnProperty(a)&&t.call(n,e[a],a,e)}}function B(e,t,n){if(!e)return[];if(!t)return Be(e);if(e.map&&e.map===de)return e.map(t,n);for(var r=[],i=0,a=e.length;i<a;i++)r.push(t.call(n,e[i],i,e));return r}function we(e,t,n,r){if(e&&t){for(var i=0,a=e.length;i<a;i++)n=t.call(r,n,e[i],i,e);return n}}function Te(e,t,n){if(!e)return[];if(!t)return Be(e);if(e.filter&&e.filter===le)return e.filter(t,n);for(var r=[],i=0,a=e.length;i<a;i++)t.call(n,e[i],i,e)&&r.push(e[i]);return r}function Ee(e,t,n){if(e&&t){for(var r=0,i=e.length;r<i;r++)if(t.call(n,e[r],r,e))return e[r]}}function V(e){if(!e)return[];if(Object.keys)return Object.keys(e);var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}function De(e,t){var n=[...arguments].slice(2);return function(){return e.apply(t,n.concat(ue.call(arguments)))}}var H=N&&W(N.bind)?N.call.bind(N.bind):De;function Oe(e){var t=[...arguments].slice(1);return function(){return e.apply(this,t.concat(ue.call(arguments)))}}function U(e){return Array.isArray?Array.isArray(e):oe.call(e)===`[object Array]`}function W(e){return typeof e==`function`}function G(e){return typeof e==`string`}function ke(e){return oe.call(e)===`[object String]`}function Ae(e){return typeof e==`number`}function K(e){var t=typeof e;return t===`function`||!!e&&t===`object`}function je(e){return!!ie[oe.call(e)]}function Me(e){return!!ae[oe.call(e)]}function Ne(e){return typeof e==`object`&&typeof e.nodeType==`number`&&typeof e.ownerDocument==`object`}function Pe(e){return e.colorStops!=null}function Fe(e){return e.image!=null}function Ie(e){return oe.call(e)===`[object RegExp]`}function Le(e){return e!==e}function Re(){for(var e=[...arguments],t=0,n=e.length;t<n;t++)if(e[t]!=null)return e[t]}function q(e,t){return e??t}function ze(e,t,n){return e??t??n}function Be(e){var t=[...arguments].slice(1);return ue.apply(e,t)}function Ve(e){if(typeof e==`number`)return[e,e,e,e];var t=e.length;return t===2?[e[0],e[1],e[0],e[1]]:t===3?[e[0],e[1],e[2],e[1]]:e}function He(e,t){if(!e)throw Error(t)}function Ue(e){return e==null?null:typeof e.trim==`function`?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,``)}var We=`__ec_primitive__`;function Ge(e){e[We]=!0}function Ke(e){return e[We]}var qe=function(){function e(){this.data={}}return e.prototype.delete=function(e){var t=this.has(e);return t&&delete this.data[e],t},e.prototype.has=function(e){return this.data.hasOwnProperty(e)},e.prototype.get=function(e){return this.data[e]},e.prototype.set=function(e,t){return this.data[e]=t,this},e.prototype.keys=function(){return V(this.data)},e.prototype.forEach=function(e){var t=this.data;for(var n in t)t.hasOwnProperty(n)&&e(t[n],n)},e}(),Je=typeof Map==`function`;function Ye(){return Je?new Map:new qe}var Xe=function(){function e(t){var n=U(t);this.data=Ye();var r=this;t instanceof e?t.each(i):t&&z(t,i);function i(e,t){n?r.set(e,t):r.set(t,e)}}return e.prototype.hasKey=function(e){return this.data.has(e)},e.prototype.get=function(e){return this.data.get(e)},e.prototype.set=function(e,t){return this.data.set(e,t),t},e.prototype.each=function(e,t){this.data.forEach(function(n,r){e.call(t,n,r)})},e.prototype.keys=function(){var e=this.data.keys();return Je?Array.from(e):e},e.prototype.removeKey=function(e){this.data.delete(e)},e}();function J(e){return new Xe(e)}function Ze(e,t){for(var n=new e.constructor(e.length+t.length),r=0;r<e.length;r++)n[r]=e[r];for(var i=e.length,r=0;r<t.length;r++)n[r+i]=t[r];return n}function Qe(e,t){var n;if(Object.create)n=Object.create(e);else{var r=function(){};r.prototype=e,n=new r}return t&&I(n,t),n}function $e(e){var t=e.style;t.webkitUserSelect=`none`,t.userSelect=`none`,t.webkitTapHighlightColor=`rgba(0,0,0,0)`,t[`-webkit-touch-callout`]=`none`}function et(e,t){return e.hasOwnProperty(t)}function tt(){}var nt=180/Math.PI,rt=2**-52||2**-52,it=function(){function e(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return e}(),Y=new(function(){function e(){this.browser=new it,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<`u`}return e}());typeof wx==`object`&&typeof wx.getSystemInfoSync==`function`?(Y.wxa=!0,Y.touchEventsSupported=!0):typeof document>`u`&&typeof self<`u`?Y.worker=!0:!Y.hasGlobalWindow||`Deno`in window||typeof navigator<`u`&&typeof navigator.userAgent==`string`&&navigator.userAgent.indexOf(`Node.js`)>-1?(Y.node=!0,Y.svgSupported=!0):at(navigator.userAgent,Y);function at(e,t){var n=t.browser,r=e.match(/Firefox\/([\d.]+)/),i=e.match(/MSIE\s([\d.]+)/)||e.match(/Trident\/.+?rv:(([\d.]+))/),a=e.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(e);if(r&&(n.firefox=!0,n.version=r[1]),i&&(n.ie=!0,n.version=i[1]),a&&(n.edge=!0,n.version=a[1],n.newEdge=+a[1].split(`.`)[0]>18),o&&(n.weChat=!0),t.svgSupported=typeof SVGRect<`u`,t.touchEventsSupported=`ontouchstart`in window&&!n.ie&&!n.edge,t.pointerEventsSupported=`onpointerdown`in window&&(n.edge||n.ie&&+n.version>=11),t.domSupported=typeof document<`u`){var s=document.documentElement.style;t.transform3dSupported=(n.ie&&`transition`in s||n.edge||`WebKitCSSMatrix`in window&&`m11`in new WebKitCSSMatrix||`MozPerspective`in s)&&!(`OTransition`in s),t.transformSupported=t.transform3dSupported||n.ie&&+n.version>=9}}var ot=`.`,st=`___EC__COMPONENT__CONTAINER___`,ct=`___EC__EXTENDED_CLASS___`;function lt(e){var t={main:``,sub:``};if(e){var n=e.split(ot);t.main=n[0]||``,t.sub=n[1]||``}return t}function ut(e){He(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(e),`componentType "`+e+`" illegal`)}function dt(e){return!!(e&&e[ct])}function ft(e,t){e.$constructor=e,e.extend=function(e){var t=this,n;return pt(t)?n=function(e){D(t,e);function t(){return e.apply(this,arguments)||this}return t}(t):(n=function(){(e.$constructor||t).apply(this,arguments)},xe(n,this)),I(n.prototype,e),n[ct]=!0,n.extend=this.extend,n.superCall=_t,n.superApply=vt,n.superClass=t,n}}function pt(e){return W(e)&&/^class\s/.test(Function.prototype.toString.call(e))}function mt(e,t){e.extend=t.extend}var ht=Math.round(Math.random()*10);function gt(e){var t=[`__\0is_clz`,ht++].join(`_`);e.prototype[t]=!0,e.isInstance=function(e){return!!(e&&e[t])}}function _t(e,t){var n=[...arguments].slice(2);return this.superClass.prototype[t].apply(e,n)}function vt(e,t,n){return this.superClass.prototype[t].apply(e,n)}function yt(e){var t={};e.registerClass=function(e){var r=e.type||e.prototype.type;if(r){ut(r),e.prototype.type=r;var i=lt(r);if(!i.sub)t[i.main]=e;else if(i.sub!==st){var a=n(i);a[i.sub]=e}}return e},e.getClass=function(e,n,r){var i=t[e];if(i&&i[st]&&(i=n?i[n]:null),r&&!i)throw Error(n?`Component `+e+`.`+(n||``)+` is used but not imported.`:e+`.type should be specified.`);return i},e.getClassesByMainType=function(e){var n=lt(e),r=[],i=t[n.main];return i&&i[st]?z(i,function(e,t){t!==st&&r.push(e)}):r.push(i),r},e.hasClass=function(e){return!!t[lt(e).main]},e.getAllClassMainTypes=function(){var e=[];return z(t,function(t,n){e.push(n)}),e},e.hasSubTypes=function(e){var n=t[lt(e).main];return n&&n[st]};function n(e){var n=t[e.main];return(!n||!n[st])&&(n=t[e.main]={},n[st]=!0),n}}function bt(e,t){for(var n=0;n<e.length;n++)e[n][1]||(e[n][1]=e[n][0]);return t||=!1,function(n,r,i){for(var a={},o=0;o<e.length;o++){var s=e[o][1];if(!(r&&R(r,s)>=0||i&&R(i,s)<0)){var c=n.getShallow(s,t);c!=null&&(a[e[o][0]]=c)}}return a}}var xt=bt([[`fill`,`color`],[`shadowBlur`],[`shadowOffsetX`],[`shadowOffsetY`],[`opacity`],[`shadowColor`]]),St=function(){function e(){}return e.prototype.getAreaStyle=function(e,t){return xt(this,e,t)},e}(),Ct=function(){function e(e){this.value=e}return e}(),wt=function(){function e(){this._len=0}return e.prototype.insert=function(e){var t=new Ct(e);return this.insertEntry(t),t},e.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},e.prototype.remove=function(e){var t=e.prev,n=e.next;t?t.next=n:this.head=n,n?n.prev=t:this.tail=t,e.next=e.prev=null,this._len--},e.prototype.len=function(){return this._len},e.prototype.clear=function(){this.head=this.tail=null,this._len=0},e}(),Tt=function(){function e(e){this._list=new wt,this._maxSize=10,this._map={},this._maxSize=e}return e.prototype.put=function(e,t){var n=this._list,r=this._map,i=null;if(r[e]==null){var a=n.len(),o=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var s=n.head;n.remove(s),delete r[s.key],i=s.value,this._lastRemovedEntry=s}o?o.value=t:o=new Ct(t),o.key=e,n.insertEntry(o),r[e]=o}return i},e.prototype.get=function(e){var t=this._map[e],n=this._list;if(t!=null)return t!==n.tail&&(n.remove(t),n.insertEntry(t)),t.value},e.prototype.clear=function(){this._list.clear(),this._map={}},e.prototype.len=function(){return this._list.len()},e}(),Et=new Tt(50);function Dt(e){if(typeof e==`string`){var t=Et.get(e);return t&&t.image}return e}function Ot(e,t,n,r,i){if(!e)return t;if(typeof e==`string`){if(t&&t.__zrImageSrc===e||!n)return t;var a=Et.get(e),o={hostEl:n,cb:r,cbPayload:i};return a?(t=a.image,!At(t)&&a.pending.push(o)):(t=M.loadImage(e,kt,kt),t.__zrImageSrc=e,Et.put(e,t.__cachedImgObj={image:t,pending:[o]})),t}return e}function kt(){var e=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<e.pending.length;t++){var n=e.pending[t],r=n.cb;r&&r(this,n.cbPayload),n.hostEl.dirty()}e.pending.length=0}function At(e){return e&&e.width&&e.height}var jt=e({clone:()=>Bt,copy:()=>Pt,create:()=>Mt,identity:()=>Nt,invert:()=>zt,mul:()=>Ft,rotate:()=>Lt,scale:()=>Rt,translate:()=>It});function Mt(){return[1,0,0,1,0,0]}function Nt(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e[4]=0,e[5]=0,e}function Pt(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function Ft(e,t,n){var r=t[0]*n[0]+t[2]*n[1],i=t[1]*n[0]+t[3]*n[1],a=t[0]*n[2]+t[2]*n[3],o=t[1]*n[2]+t[3]*n[3],s=t[0]*n[4]+t[2]*n[5]+t[4],c=t[1]*n[4]+t[3]*n[5]+t[5];return e[0]=r,e[1]=i,e[2]=a,e[3]=o,e[4]=s,e[5]=c,e}function It(e,t,n){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4]+n[0],e[5]=t[5]+n[1],e}function Lt(e,t,n,r){r===void 0&&(r=[0,0]);var i=t[0],a=t[2],o=t[4],s=t[1],c=t[3],l=t[5],u=Math.sin(n),d=Math.cos(n);return e[0]=i*d+s*u,e[1]=-i*u+s*d,e[2]=a*d+c*u,e[3]=-a*u+d*c,e[4]=d*(o-r[0])+u*(l-r[1])+r[0],e[5]=d*(l-r[1])-u*(o-r[0])+r[1],e}function Rt(e,t,n){var r=n[0],i=n[1];return e[0]=t[0]*r,e[1]=t[1]*i,e[2]=t[2]*r,e[3]=t[3]*i,e[4]=t[4]*r,e[5]=t[5]*i,e}function zt(e,t){var n=t[0],r=t[2],i=t[4],a=t[1],o=t[3],s=t[5],c=n*o-a*r;return c?(c=1/c,e[0]=o*c,e[1]=-a*c,e[2]=-r*c,e[3]=n*c,e[4]=(r*s-o*i)*c,e[5]=(a*i-n*s)*c,e):null}function Bt(e){var t=Mt();return Pt(t,e),t}var Vt=e({add:()=>Kt,applyTransform:()=>dn,clone:()=>Wt,copy:()=>Ut,create:()=>Ht,dist:()=>on,distSquare:()=>cn,distance:()=>an,distanceSquare:()=>sn,div:()=>en,dot:()=>tn,len:()=>Yt,lenSquare:()=>Zt,length:()=>Xt,lengthSquare:()=>Qt,lerp:()=>un,max:()=>pn,min:()=>fn,mul:()=>$t,negate:()=>ln,normalize:()=>rn,scale:()=>nn,scaleAndAdd:()=>qt,set:()=>Gt,sub:()=>Jt});function Ht(e,t){return e??=0,t??=0,[e,t]}function Ut(e,t){return e[0]=t[0],e[1]=t[1],e}function Wt(e){return[e[0],e[1]]}function Gt(e,t,n){return e[0]=t,e[1]=n,e}function Kt(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e}function qt(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e}function Jt(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e}function Yt(e){return Math.sqrt(Zt(e))}var Xt=Yt;function Zt(e){return e[0]*e[0]+e[1]*e[1]}var Qt=Zt;function $t(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e}function en(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e}function tn(e,t){return e[0]*t[0]+e[1]*t[1]}function nn(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e}function rn(e,t){var n=Yt(t);return n===0?(e[0]=0,e[1]=0):(e[0]=t[0]/n,e[1]=t[1]/n),e}function an(e,t){return Math.sqrt((e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1]))}var on=an;function sn(e,t){return(e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1])}var cn=sn;function ln(e,t){return e[0]=-t[0],e[1]=-t[1],e}function un(e,t,n,r){return e[0]=t[0]+r*(n[0]-t[0]),e[1]=t[1]+r*(n[1]-t[1]),e}function dn(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[2]*i+n[4],e[1]=n[1]*r+n[3]*i+n[5],e}function fn(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e}function pn(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e}var mn=function(){function e(e,t){this.x=e||0,this.y=t||0}return e.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},e.prototype.clone=function(){return new e(this.x,this.y)},e.prototype.set=function(e,t){return this.x=e,this.y=t,this},e.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},e.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},e.prototype.scale=function(e){this.x*=e,this.y*=e},e.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},e.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},e.prototype.dot=function(e){return this.x*e.x+this.y*e.y},e.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},e.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},e.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},e.prototype.distance=function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},e.prototype.distanceSquare=function(e){var t=this.x-e.x,n=this.y-e.y;return t*t+n*n},e.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},e.prototype.transform=function(e){if(e){var t=this.x,n=this.y;return this.x=e[0]*t+e[2]*n+e[4],this.y=e[1]*t+e[3]*n+e[5],this}},e.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},e.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},e.set=function(e,t,n){e.x=t,e.y=n},e.copy=function(e,t){e.x=t.x,e.y=t.y},e.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},e.lenSquare=function(e){return e.x*e.x+e.y*e.y},e.dot=function(e,t){return e.x*t.x+e.y*t.y},e.add=function(e,t,n){e.x=t.x+n.x,e.y=t.y+n.y},e.sub=function(e,t,n){e.x=t.x-n.x,e.y=t.y-n.y},e.scale=function(e,t,n){e.x=t.x*n,e.y=t.y*n},e.scaleAndAdd=function(e,t,n,r){e.x=t.x+n.x*r,e.y=t.y+n.y*r},e.lerp=function(e,t,n,r){var i=1-r;e.x=i*t.x+r*n.x,e.y=i*t.y+r*n.y},e}(),hn=Math.min,gn=Math.max,_n=Math.abs,vn=[`x`,`y`],yn=[`width`,`height`],bn=new mn,xn=new mn,Sn=new mn,Cn=new mn,wn=Rn(),Tn=wn.minTv,En=wn.maxTv,Dn=[0,0],X=function(){function e(e,t,n,r){kn(this,e,t,n,r)}return e.set=function(e,t,n,r,i){return r<0&&(t+=r,r=-r),i<0&&(n+=i,i=-i),e.x=t,e.y=n,e.width=r,e.height=i,e},e.prototype.union=function(e){var t=hn(e.x,this.x),n=hn(e.y,this.y);this.width=isFinite(this.x)&&isFinite(this.width)?gn(e.x+e.width,this.x+this.width)-t:e.width,this.height=isFinite(this.y)&&isFinite(this.height)?gn(e.y+e.height,this.y+this.height)-n:e.height,this.x=t,this.y=n},e.prototype.applyTransform=function(t){e.applyTransform(this,this,t)},e.prototype.calculateTransform=function(e){return jn(Mt(),this,e)},e.prototype.intersect=function(t,n,r){return e.intersect(this,t,n,r)},e.intersect=function(t,n,r,i){r&&mn.set(r,0,0);var a=i&&i.outIntersectRect||null,o=i&&i.clamp;if(a&&(a.x=a.y=a.width=a.height=NaN),!t||!n)return!1;t instanceof e||(t=kn(Pn,t.x,t.y,t.width,t.height)),n instanceof e||(n=kn(Fn,n.x,n.y,n.width,n.height));var s=!!r;wn.reset(i,s);var c=wn.touchThreshold,l=t.x+c,u=t.x+t.width-c,d=t.y+c,f=t.y+t.height-c,p=n.x+c,m=n.x+n.width-c,h=n.y+c,g=n.y+n.height-c;if(l>u||d>f||p>m||h>g)return!1;var _=!(u<p||m<l||f<h||g<d);return(s||a)&&(Dn[0]=1/0,Dn[1]=0,Ln(l,u,p,m,0,s,a,o),Ln(d,f,h,g,1,s,a,o),s&&mn.copy(r,_?wn.useDir?wn.dirMinTv:Tn:En)),_},e.contain=function(e,t,n){return t>=e.x&&t<=e.x+e.width&&n>=e.y&&n<=e.y+e.height},e.prototype.contain=function(t,n){return e.contain(this,t,n)},e.prototype.clone=function(){return new e(this.x,this.y,this.width,this.height)},e.prototype.copy=function(e){An(this,e)},e.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},e.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},e.prototype.isZero=function(){return this.width===0||this.height===0},e.create=function(t){return new e(t?t.x:0,t?t.y:0,t?t.width:0,t?t.height:0)},e.copy=function(e,t){return e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height,e},e.applyTransform=function(e,t,n){if(!n){e!==t&&An(e,t);return}if(n[1]<1e-5&&n[1]>-1e-5&&n[2]<1e-5&&n[2]>-1e-5){var r=n[0],i=n[3],a=n[4],o=n[5];e.x=t.x*r+a,e.y=t.y*i+o,e.width=t.width*r,e.height=t.height*i,e.width<0&&(e.x+=e.width,e.width=-e.width),e.height<0&&(e.y+=e.height,e.height=-e.height);return}bn.x=Sn.x=t.x,bn.y=Cn.y=t.y,xn.x=Cn.x=t.x+t.width,xn.y=Sn.y=t.y+t.height,bn.transform(n),Cn.transform(n),xn.transform(n),Sn.transform(n),e.x=hn(bn.x,xn.x,Sn.x,Cn.x),e.y=hn(bn.y,xn.y,Sn.y,Cn.y);var s=gn(bn.x,xn.x,Sn.x,Cn.x),c=gn(bn.y,xn.y,Sn.y,Cn.y);e.width=s-e.x,e.height=c-e.y},e.calculateTransform=function(e,t,n){var r=n.width/t.width,i=n.height/t.height;return e=Nt(e||[]),It(e,e,Gt(In,-t.x,-t.y)),Rt(e,e,Gt(In,r,i)),It(e,e,Gt(In,n.x,n.y)),e},e}(),On=X.create,kn=X.set,An=X.copy,jn=X.calculateTransform,Mn=X.applyTransform,Nn=X.contain,Pn=new X(0,0,0,0),Fn=new X(0,0,0,0),In=[];function Ln(e,t,n,r,i,a,o,s){var c=_n(t-n),l=_n(r-e),u=hn(c,l),d=vn[i],f=vn[1-i],p=yn[i];t<n||r<e?c<l?(a&&(En[d]=-c),s&&(o[d]=t,o[p]=0)):(a&&(En[d]=l),s&&(o[d]=e,o[p]=0)):(o&&(o[d]=gn(e,n),o[p]=hn(t,r)-o[d]),a&&(u<Dn[0]||wn.useDir)&&(Dn[0]=hn(u,Dn[0]),(c<l||!wn.bidirectional)&&(Tn[d]=c,Tn[f]=0,wn.useDir&&wn.calcDirMTV()),(c>=l||!wn.bidirectional)&&(Tn[d]=-l,Tn[f]=0,wn.useDir&&wn.calcDirMTV())))}function Rn(){var e=0,t=new mn,n=new mn,r={minTv:new mn,maxTv:new mn,useDir:!1,dirMinTv:new mn,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(i,a){r.touchThreshold=0,i&&i.touchThreshold!=null&&(r.touchThreshold=gn(0,i.touchThreshold)),r.negativeSize=!1,a&&(r.minTv.set(1/0,1/0),r.maxTv.set(0,0),r.useDir=!1,i&&i.direction!=null&&(r.useDir=!0,r.dirMinTv.copy(r.minTv),n.copy(r.minTv),e=i.direction,r.bidirectional=i.bidirectional==null||!!i.bidirectional,r.bidirectional||t.set(Math.cos(e),Math.sin(e))))},calcDirMTV:function(){var a=r.minTv,o=r.dirMinTv,s=a.y*a.y+a.x*a.x,c=Math.sin(e),l=Math.cos(e),u=c*a.y+l*a.x;if(i(u)){i(a.x)&&i(a.y)&&o.set(0,0);return}if(n.x=s*l/u,n.y=s*c/u,i(n.x)&&i(n.y)){o.set(0,0);return}(r.bidirectional||t.dot(n)>0)&&n.len()<o.len()&&o.copy(n)}};function i(e){return _n(e)<1e-10}return r}function zn(e){Bn||=new Tt(100),e||=`12px sans-serif`;var t=Bn.get(e);return t||(t={font:e,strWidthCache:new Tt(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:M.measureText(`国`,e).width,asciiCharWidth:M.measureText(`a`,e).width},Bn.put(e,t)),t}var Bn;function Vn(e){if(!(Hn>=Un)){e||=`12px sans-serif`;for(var t=[],n=+new Date,r=0;r<=127;r++)t[r]=M.measureText(String.fromCharCode(r),e).width;var i=+new Date-n;return i>16?Hn=Un:i>2&&Hn++,t}}var Hn=0,Un=5;function Wn(e,t){return e.asciiWidthMapTried||=(e.asciiWidthMap=Vn(e.font),!0),0<=t&&t<=127?e.asciiWidthMap==null?e.asciiCharWidth:e.asciiWidthMap[t]:e.stWideCharWidth}function Gn(e,t){var n=e.strWidthCache,r=n.get(t);return r??(r=M.measureText(t,e.font).width,n.put(t,r)),r}function Kn(e,t,n,r){var i=Gn(zn(t),e),a=Xn(t);return new X(Jn(0,i,n),Yn(0,a,r),i,a)}function qn(e,t,n,r){var i=((e||``)+``).split(`
1
+ import{n as e,r as t}from"./rolldown-runtime-hePW80VL.js";import{n,t as r}from"./IconBase.es-BZDpYMnj.js";import{i,r as a}from"./react-CDCuUAOg.js";import{n as o,t as s}from"./button-pa1bq9b85hawg41a-BcGpLLER.js";import{t as c}from"./DirectionalIcon-BKKMj3KT.js";import{n as l}from"./skeleton-line-m9dyh126t9k07jvg-CHsT8Hs3.js";import{t as u}from"./Table.es-6S52tmK7.js";import{a as d,n as f,r as p,t as m}from"./StatTile-DyU32i8V.js";import{t as h}from"./table-yf8ul2e5nbemioi1-DNq9jhfh.js";import{a as g,n as _,r as v,t as y}from"./useChartPalette-DXG2lo2x.js";import{r as b}from"./analytics-range-BqKm9TTo.js";import{ot as x}from"./index-DWzjnrnl.js";var S=t(i(),1),C=new Map([[`bold`,S.createElement(S.Fragment,null,S.createElement(`path`,{d:`M232.49,160.49l-48,48a12,12,0,0,1-17-17L195,164H128A108.12,108.12,0,0,1,20,56a12,12,0,0,1,24,0,84.09,84.09,0,0,0,84,84h67l-27.52-27.51a12,12,0,0,1,17-17l48,48A12,12,0,0,1,232.49,160.49Z`}))],[`fill`,S.createElement(S.Fragment,null,S.createElement(`path`,{d:`M229.66,157.66l-48,48A8,8,0,0,1,168,200V160H128A104.11,104.11,0,0,1,24,56a8,8,0,0,1,16,0,88.1,88.1,0,0,0,88,88h40V104a8,8,0,0,1,13.66-5.66l48,48A8,8,0,0,1,229.66,157.66Z`}))],[`regular`,S.createElement(S.Fragment,null,S.createElement(`path`,{d:`M229.66,157.66l-48,48a8,8,0,0,1-11.32-11.32L204.69,160H128A104.11,104.11,0,0,1,24,56a8,8,0,0,1,16,0,88.1,88.1,0,0,0,88,88h76.69l-34.35-34.34a8,8,0,0,1,11.32-11.32l48,48A8,8,0,0,1,229.66,157.66Z`}))]]),w=S.forwardRef((e,t)=>S.createElement(r,{ref:t,...e,weights:C}));w.displayName=`ArrowBendDownRightIcon`;var T=w,E=function(e,t){return E=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},E(e,t)};function D(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);E(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var O=`12px sans-serif`,k=20,A=100,j=`007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N`;function ee(e){var t={};if(typeof JSON>`u`)return t;for(var n=0;n<e.length;n++){var r=String.fromCharCode(n+32);t[r]=(e.charCodeAt(n)-k)/A}return t}var te=ee(j),M={createCanvas:function(){return typeof document<`u`&&document.createElement(`canvas`)},measureText:(function(){var e,t;return function(n,r){if(!e){var i=M.createCanvas();e=i&&i.getContext(`2d`)}if(e)return t!==r&&(t=e.font=r||`12px sans-serif`),e.measureText(n);n||=``,r||=`12px sans-serif`;var a=/((?:\d+)?\.?\d*)px/.exec(r),o=a&&+a[1]||12,s=0;if(r.indexOf(`mono`)>=0)s=o*n.length;else for(var c=0;c<n.length;c++){var l=te[n[c]];s+=l==null?o:l*o}return{width:s}}})(),loadImage:function(e,t,n){var r=new Image;return r.onload=t,r.onerror=n,r.src=e,r},getTime:function(){return Date.now?Date.now():+new Date}};function ne(e){for(var t in M)M.hasOwnProperty(t)&&e[t]&&(M[t]=e[t])}var re=e({EPSILON:()=>rt,HashMap:()=>Xe,RADIAN_TO_DEGREE:()=>nt,assert:()=>He,assignProps:()=>ye,bind:()=>H,clone:()=>P,concatArray:()=>Ze,createCanvas:()=>be,createHashMap:()=>J,createObject:()=>Qe,curry:()=>Oe,defaults:()=>L,disableUserSelect:()=>$e,each:()=>z,eqNaN:()=>Le,extend:()=>I,filter:()=>Te,find:()=>Ee,guid:()=>ge,hasOwn:()=>et,indexOf:()=>R,inherits:()=>xe,isArray:()=>U,isArrayLike:()=>Ce,isBuiltInObject:()=>je,isDom:()=>Ne,isFunction:()=>W,isGradientObject:()=>Pe,isImagePatternObject:()=>Fe,isNumber:()=>Ae,isObject:()=>K,isPrimitive:()=>Ke,isRegExp:()=>Ie,isString:()=>G,isStringSafe:()=>ke,isTypedArray:()=>Me,keys:()=>V,logError:()=>_e,map:()=>B,merge:()=>F,mergeAll:()=>ve,mixin:()=>Se,noop:()=>tt,normalizeCssArray:()=>Ve,reduce:()=>we,retrieve:()=>Re,retrieve2:()=>q,retrieve3:()=>ze,setAsPrimitive:()=>Ge,slice:()=>Be,trim:()=>Ue}),ie=we([`Function`,`RegExp`,`Date`,`Error`,`CanvasGradient`,`CanvasPattern`,`Image`,`Canvas`],function(e,t){return e[`[object `+t+`]`]=!0,e},{}),ae=we([`Int8`,`Uint8`,`Uint8Clamped`,`Int16`,`Uint16`,`Int32`,`Uint32`,`Float32`,`Float64`],function(e,t){return e[`[object `+t+`Array]`]=!0,e},{}),oe=Object.prototype.toString,se=Array.prototype,ce=se.forEach,le=se.filter,ue=se.slice,de=se.map,fe=function(){}.constructor,N=fe?fe.prototype:null,pe=`__proto__`,me=2311,he=2**53-1;function ge(){return me>=he&&(me=0),me++}function _e(){var e=[...arguments];typeof console<`u`&&console.error.apply(console,e)}function P(e){if(typeof e!=`object`||!e)return e;var t=e,n=oe.call(e);if(n===`[object Array]`){if(!Ke(e)){t=[];for(var r=0,i=e.length;r<i;r++)t[r]=P(e[r])}}else if(ae[n]){if(!Ke(e)){var a=e.constructor;if(a.from)t=a.from(e);else{t=new a(e.length);for(var r=0,i=e.length;r<i;r++)t[r]=e[r]}}}else if(!ie[n]&&!Ke(e)&&!Ne(e))for(var o in t={},e)e.hasOwnProperty(o)&&o!==pe&&(t[o]=P(e[o]));return t}function F(e,t,n){if(!K(t)||!K(e))return n?P(t):e;for(var r in t)if(t.hasOwnProperty(r)&&r!==pe){var i=e[r],a=t[r];K(a)&&K(i)&&!U(a)&&!U(i)&&!Ne(a)&&!Ne(i)&&!je(a)&&!je(i)&&!Ke(a)&&!Ke(i)?F(i,a,n):(n||!(r in e))&&(e[r]=P(t[r]))}return e}function ve(e,t){for(var n=e[0],r=1,i=e.length;r<i;r++)n=F(n,e[r],t);return n}function I(e,t){if(Object.assign)Object.assign(e,t);else for(var n in t)t.hasOwnProperty(n)&&n!==pe&&(e[n]=t[n]);return e}function ye(e,t,n){e||={};for(var r=0;r<n.length;r++){var i=n[r];e[i]=t[i]}return e}function L(e,t,n){for(var r=V(t),i=0,a=r.length;i<a;i++){var o=r[i];(n?t[o]!=null:e[o]==null)&&(e[o]=t[o])}return e}var be=M.createCanvas;function R(e,t){if(e){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n}return-1}function xe(e,t){var n=e.prototype;function r(){}for(var i in r.prototype=t.prototype,e.prototype=new r,n)n.hasOwnProperty(i)&&(e.prototype[i]=n[i]);e.prototype.constructor=e,e.superClass=t}function Se(e,t,n){if(e=`prototype`in e?e.prototype:e,t=`prototype`in t?t.prototype:t,Object.getOwnPropertyNames)for(var r=Object.getOwnPropertyNames(t),i=0;i<r.length;i++){var a=r[i];a!==`constructor`&&(n?t[a]!=null:e[a]==null)&&(e[a]=t[a])}else L(e,t,n)}function Ce(e){return!e||typeof e==`string`?!1:typeof e.length==`number`}function z(e,t,n){if(e&&t){if(e.forEach&&e.forEach===ce)e.forEach(t,n);else if(e.length===+e.length)for(var r=0,i=e.length;r<i;r++)t.call(n,e[r],r,e);else for(var a in e)e.hasOwnProperty(a)&&t.call(n,e[a],a,e)}}function B(e,t,n){if(!e)return[];if(!t)return Be(e);if(e.map&&e.map===de)return e.map(t,n);for(var r=[],i=0,a=e.length;i<a;i++)r.push(t.call(n,e[i],i,e));return r}function we(e,t,n,r){if(e&&t){for(var i=0,a=e.length;i<a;i++)n=t.call(r,n,e[i],i,e);return n}}function Te(e,t,n){if(!e)return[];if(!t)return Be(e);if(e.filter&&e.filter===le)return e.filter(t,n);for(var r=[],i=0,a=e.length;i<a;i++)t.call(n,e[i],i,e)&&r.push(e[i]);return r}function Ee(e,t,n){if(e&&t){for(var r=0,i=e.length;r<i;r++)if(t.call(n,e[r],r,e))return e[r]}}function V(e){if(!e)return[];if(Object.keys)return Object.keys(e);var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}function De(e,t){var n=[...arguments].slice(2);return function(){return e.apply(t,n.concat(ue.call(arguments)))}}var H=N&&W(N.bind)?N.call.bind(N.bind):De;function Oe(e){var t=[...arguments].slice(1);return function(){return e.apply(this,t.concat(ue.call(arguments)))}}function U(e){return Array.isArray?Array.isArray(e):oe.call(e)===`[object Array]`}function W(e){return typeof e==`function`}function G(e){return typeof e==`string`}function ke(e){return oe.call(e)===`[object String]`}function Ae(e){return typeof e==`number`}function K(e){var t=typeof e;return t===`function`||!!e&&t===`object`}function je(e){return!!ie[oe.call(e)]}function Me(e){return!!ae[oe.call(e)]}function Ne(e){return typeof e==`object`&&typeof e.nodeType==`number`&&typeof e.ownerDocument==`object`}function Pe(e){return e.colorStops!=null}function Fe(e){return e.image!=null}function Ie(e){return oe.call(e)===`[object RegExp]`}function Le(e){return e!==e}function Re(){for(var e=[...arguments],t=0,n=e.length;t<n;t++)if(e[t]!=null)return e[t]}function q(e,t){return e??t}function ze(e,t,n){return e??t??n}function Be(e){var t=[...arguments].slice(1);return ue.apply(e,t)}function Ve(e){if(typeof e==`number`)return[e,e,e,e];var t=e.length;return t===2?[e[0],e[1],e[0],e[1]]:t===3?[e[0],e[1],e[2],e[1]]:e}function He(e,t){if(!e)throw Error(t)}function Ue(e){return e==null?null:typeof e.trim==`function`?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,``)}var We=`__ec_primitive__`;function Ge(e){e[We]=!0}function Ke(e){return e[We]}var qe=function(){function e(){this.data={}}return e.prototype.delete=function(e){var t=this.has(e);return t&&delete this.data[e],t},e.prototype.has=function(e){return this.data.hasOwnProperty(e)},e.prototype.get=function(e){return this.data[e]},e.prototype.set=function(e,t){return this.data[e]=t,this},e.prototype.keys=function(){return V(this.data)},e.prototype.forEach=function(e){var t=this.data;for(var n in t)t.hasOwnProperty(n)&&e(t[n],n)},e}(),Je=typeof Map==`function`;function Ye(){return Je?new Map:new qe}var Xe=function(){function e(t){var n=U(t);this.data=Ye();var r=this;t instanceof e?t.each(i):t&&z(t,i);function i(e,t){n?r.set(e,t):r.set(t,e)}}return e.prototype.hasKey=function(e){return this.data.has(e)},e.prototype.get=function(e){return this.data.get(e)},e.prototype.set=function(e,t){return this.data.set(e,t),t},e.prototype.each=function(e,t){this.data.forEach(function(n,r){e.call(t,n,r)})},e.prototype.keys=function(){var e=this.data.keys();return Je?Array.from(e):e},e.prototype.removeKey=function(e){this.data.delete(e)},e}();function J(e){return new Xe(e)}function Ze(e,t){for(var n=new e.constructor(e.length+t.length),r=0;r<e.length;r++)n[r]=e[r];for(var i=e.length,r=0;r<t.length;r++)n[r+i]=t[r];return n}function Qe(e,t){var n;if(Object.create)n=Object.create(e);else{var r=function(){};r.prototype=e,n=new r}return t&&I(n,t),n}function $e(e){var t=e.style;t.webkitUserSelect=`none`,t.userSelect=`none`,t.webkitTapHighlightColor=`rgba(0,0,0,0)`,t[`-webkit-touch-callout`]=`none`}function et(e,t){return e.hasOwnProperty(t)}function tt(){}var nt=180/Math.PI,rt=2**-52||2**-52,it=function(){function e(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return e}(),Y=new(function(){function e(){this.browser=new it,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<`u`}return e}());typeof wx==`object`&&typeof wx.getSystemInfoSync==`function`?(Y.wxa=!0,Y.touchEventsSupported=!0):typeof document>`u`&&typeof self<`u`?Y.worker=!0:!Y.hasGlobalWindow||`Deno`in window||typeof navigator<`u`&&typeof navigator.userAgent==`string`&&navigator.userAgent.indexOf(`Node.js`)>-1?(Y.node=!0,Y.svgSupported=!0):at(navigator.userAgent,Y);function at(e,t){var n=t.browser,r=e.match(/Firefox\/([\d.]+)/),i=e.match(/MSIE\s([\d.]+)/)||e.match(/Trident\/.+?rv:(([\d.]+))/),a=e.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(e);if(r&&(n.firefox=!0,n.version=r[1]),i&&(n.ie=!0,n.version=i[1]),a&&(n.edge=!0,n.version=a[1],n.newEdge=+a[1].split(`.`)[0]>18),o&&(n.weChat=!0),t.svgSupported=typeof SVGRect<`u`,t.touchEventsSupported=`ontouchstart`in window&&!n.ie&&!n.edge,t.pointerEventsSupported=`onpointerdown`in window&&(n.edge||n.ie&&+n.version>=11),t.domSupported=typeof document<`u`){var s=document.documentElement.style;t.transform3dSupported=(n.ie&&`transition`in s||n.edge||`WebKitCSSMatrix`in window&&`m11`in new WebKitCSSMatrix||`MozPerspective`in s)&&!(`OTransition`in s),t.transformSupported=t.transform3dSupported||n.ie&&+n.version>=9}}var ot=`.`,st=`___EC__COMPONENT__CONTAINER___`,ct=`___EC__EXTENDED_CLASS___`;function lt(e){var t={main:``,sub:``};if(e){var n=e.split(ot);t.main=n[0]||``,t.sub=n[1]||``}return t}function ut(e){He(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(e),`componentType "`+e+`" illegal`)}function dt(e){return!!(e&&e[ct])}function ft(e,t){e.$constructor=e,e.extend=function(e){var t=this,n;return pt(t)?n=function(e){D(t,e);function t(){return e.apply(this,arguments)||this}return t}(t):(n=function(){(e.$constructor||t).apply(this,arguments)},xe(n,this)),I(n.prototype,e),n[ct]=!0,n.extend=this.extend,n.superCall=_t,n.superApply=vt,n.superClass=t,n}}function pt(e){return W(e)&&/^class\s/.test(Function.prototype.toString.call(e))}function mt(e,t){e.extend=t.extend}var ht=Math.round(Math.random()*10);function gt(e){var t=[`__\0is_clz`,ht++].join(`_`);e.prototype[t]=!0,e.isInstance=function(e){return!!(e&&e[t])}}function _t(e,t){var n=[...arguments].slice(2);return this.superClass.prototype[t].apply(e,n)}function vt(e,t,n){return this.superClass.prototype[t].apply(e,n)}function yt(e){var t={};e.registerClass=function(e){var r=e.type||e.prototype.type;if(r){ut(r),e.prototype.type=r;var i=lt(r);if(!i.sub)t[i.main]=e;else if(i.sub!==st){var a=n(i);a[i.sub]=e}}return e},e.getClass=function(e,n,r){var i=t[e];if(i&&i[st]&&(i=n?i[n]:null),r&&!i)throw Error(n?`Component `+e+`.`+(n||``)+` is used but not imported.`:e+`.type should be specified.`);return i},e.getClassesByMainType=function(e){var n=lt(e),r=[],i=t[n.main];return i&&i[st]?z(i,function(e,t){t!==st&&r.push(e)}):r.push(i),r},e.hasClass=function(e){return!!t[lt(e).main]},e.getAllClassMainTypes=function(){var e=[];return z(t,function(t,n){e.push(n)}),e},e.hasSubTypes=function(e){var n=t[lt(e).main];return n&&n[st]};function n(e){var n=t[e.main];return(!n||!n[st])&&(n=t[e.main]={},n[st]=!0),n}}function bt(e,t){for(var n=0;n<e.length;n++)e[n][1]||(e[n][1]=e[n][0]);return t||=!1,function(n,r,i){for(var a={},o=0;o<e.length;o++){var s=e[o][1];if(!(r&&R(r,s)>=0||i&&R(i,s)<0)){var c=n.getShallow(s,t);c!=null&&(a[e[o][0]]=c)}}return a}}var xt=bt([[`fill`,`color`],[`shadowBlur`],[`shadowOffsetX`],[`shadowOffsetY`],[`opacity`],[`shadowColor`]]),St=function(){function e(){}return e.prototype.getAreaStyle=function(e,t){return xt(this,e,t)},e}(),Ct=function(){function e(e){this.value=e}return e}(),wt=function(){function e(){this._len=0}return e.prototype.insert=function(e){var t=new Ct(e);return this.insertEntry(t),t},e.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},e.prototype.remove=function(e){var t=e.prev,n=e.next;t?t.next=n:this.head=n,n?n.prev=t:this.tail=t,e.next=e.prev=null,this._len--},e.prototype.len=function(){return this._len},e.prototype.clear=function(){this.head=this.tail=null,this._len=0},e}(),Tt=function(){function e(e){this._list=new wt,this._maxSize=10,this._map={},this._maxSize=e}return e.prototype.put=function(e,t){var n=this._list,r=this._map,i=null;if(r[e]==null){var a=n.len(),o=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var s=n.head;n.remove(s),delete r[s.key],i=s.value,this._lastRemovedEntry=s}o?o.value=t:o=new Ct(t),o.key=e,n.insertEntry(o),r[e]=o}return i},e.prototype.get=function(e){var t=this._map[e],n=this._list;if(t!=null)return t!==n.tail&&(n.remove(t),n.insertEntry(t)),t.value},e.prototype.clear=function(){this._list.clear(),this._map={}},e.prototype.len=function(){return this._list.len()},e}(),Et=new Tt(50);function Dt(e){if(typeof e==`string`){var t=Et.get(e);return t&&t.image}return e}function Ot(e,t,n,r,i){if(!e)return t;if(typeof e==`string`){if(t&&t.__zrImageSrc===e||!n)return t;var a=Et.get(e),o={hostEl:n,cb:r,cbPayload:i};return a?(t=a.image,!At(t)&&a.pending.push(o)):(t=M.loadImage(e,kt,kt),t.__zrImageSrc=e,Et.put(e,t.__cachedImgObj={image:t,pending:[o]})),t}return e}function kt(){var e=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<e.pending.length;t++){var n=e.pending[t],r=n.cb;r&&r(this,n.cbPayload),n.hostEl.dirty()}e.pending.length=0}function At(e){return e&&e.width&&e.height}var jt=e({clone:()=>Bt,copy:()=>Pt,create:()=>Mt,identity:()=>Nt,invert:()=>zt,mul:()=>Ft,rotate:()=>Lt,scale:()=>Rt,translate:()=>It});function Mt(){return[1,0,0,1,0,0]}function Nt(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e[4]=0,e[5]=0,e}function Pt(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function Ft(e,t,n){var r=t[0]*n[0]+t[2]*n[1],i=t[1]*n[0]+t[3]*n[1],a=t[0]*n[2]+t[2]*n[3],o=t[1]*n[2]+t[3]*n[3],s=t[0]*n[4]+t[2]*n[5]+t[4],c=t[1]*n[4]+t[3]*n[5]+t[5];return e[0]=r,e[1]=i,e[2]=a,e[3]=o,e[4]=s,e[5]=c,e}function It(e,t,n){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4]+n[0],e[5]=t[5]+n[1],e}function Lt(e,t,n,r){r===void 0&&(r=[0,0]);var i=t[0],a=t[2],o=t[4],s=t[1],c=t[3],l=t[5],u=Math.sin(n),d=Math.cos(n);return e[0]=i*d+s*u,e[1]=-i*u+s*d,e[2]=a*d+c*u,e[3]=-a*u+d*c,e[4]=d*(o-r[0])+u*(l-r[1])+r[0],e[5]=d*(l-r[1])-u*(o-r[0])+r[1],e}function Rt(e,t,n){var r=n[0],i=n[1];return e[0]=t[0]*r,e[1]=t[1]*i,e[2]=t[2]*r,e[3]=t[3]*i,e[4]=t[4]*r,e[5]=t[5]*i,e}function zt(e,t){var n=t[0],r=t[2],i=t[4],a=t[1],o=t[3],s=t[5],c=n*o-a*r;return c?(c=1/c,e[0]=o*c,e[1]=-a*c,e[2]=-r*c,e[3]=n*c,e[4]=(r*s-o*i)*c,e[5]=(a*i-n*s)*c,e):null}function Bt(e){var t=Mt();return Pt(t,e),t}var Vt=e({add:()=>Kt,applyTransform:()=>dn,clone:()=>Wt,copy:()=>Ut,create:()=>Ht,dist:()=>on,distSquare:()=>cn,distance:()=>an,distanceSquare:()=>sn,div:()=>en,dot:()=>tn,len:()=>Yt,lenSquare:()=>Zt,length:()=>Xt,lengthSquare:()=>Qt,lerp:()=>un,max:()=>pn,min:()=>fn,mul:()=>$t,negate:()=>ln,normalize:()=>rn,scale:()=>nn,scaleAndAdd:()=>qt,set:()=>Gt,sub:()=>Jt});function Ht(e,t){return e??=0,t??=0,[e,t]}function Ut(e,t){return e[0]=t[0],e[1]=t[1],e}function Wt(e){return[e[0],e[1]]}function Gt(e,t,n){return e[0]=t,e[1]=n,e}function Kt(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e}function qt(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e}function Jt(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e}function Yt(e){return Math.sqrt(Zt(e))}var Xt=Yt;function Zt(e){return e[0]*e[0]+e[1]*e[1]}var Qt=Zt;function $t(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e}function en(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e}function tn(e,t){return e[0]*t[0]+e[1]*t[1]}function nn(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e}function rn(e,t){var n=Yt(t);return n===0?(e[0]=0,e[1]=0):(e[0]=t[0]/n,e[1]=t[1]/n),e}function an(e,t){return Math.sqrt((e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1]))}var on=an;function sn(e,t){return(e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1])}var cn=sn;function ln(e,t){return e[0]=-t[0],e[1]=-t[1],e}function un(e,t,n,r){return e[0]=t[0]+r*(n[0]-t[0]),e[1]=t[1]+r*(n[1]-t[1]),e}function dn(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[2]*i+n[4],e[1]=n[1]*r+n[3]*i+n[5],e}function fn(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e}function pn(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e}var mn=function(){function e(e,t){this.x=e||0,this.y=t||0}return e.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},e.prototype.clone=function(){return new e(this.x,this.y)},e.prototype.set=function(e,t){return this.x=e,this.y=t,this},e.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},e.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},e.prototype.scale=function(e){this.x*=e,this.y*=e},e.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},e.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},e.prototype.dot=function(e){return this.x*e.x+this.y*e.y},e.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},e.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},e.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},e.prototype.distance=function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},e.prototype.distanceSquare=function(e){var t=this.x-e.x,n=this.y-e.y;return t*t+n*n},e.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},e.prototype.transform=function(e){if(e){var t=this.x,n=this.y;return this.x=e[0]*t+e[2]*n+e[4],this.y=e[1]*t+e[3]*n+e[5],this}},e.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},e.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},e.set=function(e,t,n){e.x=t,e.y=n},e.copy=function(e,t){e.x=t.x,e.y=t.y},e.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},e.lenSquare=function(e){return e.x*e.x+e.y*e.y},e.dot=function(e,t){return e.x*t.x+e.y*t.y},e.add=function(e,t,n){e.x=t.x+n.x,e.y=t.y+n.y},e.sub=function(e,t,n){e.x=t.x-n.x,e.y=t.y-n.y},e.scale=function(e,t,n){e.x=t.x*n,e.y=t.y*n},e.scaleAndAdd=function(e,t,n,r){e.x=t.x+n.x*r,e.y=t.y+n.y*r},e.lerp=function(e,t,n,r){var i=1-r;e.x=i*t.x+r*n.x,e.y=i*t.y+r*n.y},e}(),hn=Math.min,gn=Math.max,_n=Math.abs,vn=[`x`,`y`],yn=[`width`,`height`],bn=new mn,xn=new mn,Sn=new mn,Cn=new mn,wn=Rn(),Tn=wn.minTv,En=wn.maxTv,Dn=[0,0],X=function(){function e(e,t,n,r){kn(this,e,t,n,r)}return e.set=function(e,t,n,r,i){return r<0&&(t+=r,r=-r),i<0&&(n+=i,i=-i),e.x=t,e.y=n,e.width=r,e.height=i,e},e.prototype.union=function(e){var t=hn(e.x,this.x),n=hn(e.y,this.y);this.width=isFinite(this.x)&&isFinite(this.width)?gn(e.x+e.width,this.x+this.width)-t:e.width,this.height=isFinite(this.y)&&isFinite(this.height)?gn(e.y+e.height,this.y+this.height)-n:e.height,this.x=t,this.y=n},e.prototype.applyTransform=function(t){e.applyTransform(this,this,t)},e.prototype.calculateTransform=function(e){return jn(Mt(),this,e)},e.prototype.intersect=function(t,n,r){return e.intersect(this,t,n,r)},e.intersect=function(t,n,r,i){r&&mn.set(r,0,0);var a=i&&i.outIntersectRect||null,o=i&&i.clamp;if(a&&(a.x=a.y=a.width=a.height=NaN),!t||!n)return!1;t instanceof e||(t=kn(Pn,t.x,t.y,t.width,t.height)),n instanceof e||(n=kn(Fn,n.x,n.y,n.width,n.height));var s=!!r;wn.reset(i,s);var c=wn.touchThreshold,l=t.x+c,u=t.x+t.width-c,d=t.y+c,f=t.y+t.height-c,p=n.x+c,m=n.x+n.width-c,h=n.y+c,g=n.y+n.height-c;if(l>u||d>f||p>m||h>g)return!1;var _=!(u<p||m<l||f<h||g<d);return(s||a)&&(Dn[0]=1/0,Dn[1]=0,Ln(l,u,p,m,0,s,a,o),Ln(d,f,h,g,1,s,a,o),s&&mn.copy(r,_?wn.useDir?wn.dirMinTv:Tn:En)),_},e.contain=function(e,t,n){return t>=e.x&&t<=e.x+e.width&&n>=e.y&&n<=e.y+e.height},e.prototype.contain=function(t,n){return e.contain(this,t,n)},e.prototype.clone=function(){return new e(this.x,this.y,this.width,this.height)},e.prototype.copy=function(e){An(this,e)},e.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},e.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},e.prototype.isZero=function(){return this.width===0||this.height===0},e.create=function(t){return new e(t?t.x:0,t?t.y:0,t?t.width:0,t?t.height:0)},e.copy=function(e,t){return e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height,e},e.applyTransform=function(e,t,n){if(!n){e!==t&&An(e,t);return}if(n[1]<1e-5&&n[1]>-1e-5&&n[2]<1e-5&&n[2]>-1e-5){var r=n[0],i=n[3],a=n[4],o=n[5];e.x=t.x*r+a,e.y=t.y*i+o,e.width=t.width*r,e.height=t.height*i,e.width<0&&(e.x+=e.width,e.width=-e.width),e.height<0&&(e.y+=e.height,e.height=-e.height);return}bn.x=Sn.x=t.x,bn.y=Cn.y=t.y,xn.x=Cn.x=t.x+t.width,xn.y=Sn.y=t.y+t.height,bn.transform(n),Cn.transform(n),xn.transform(n),Sn.transform(n),e.x=hn(bn.x,xn.x,Sn.x,Cn.x),e.y=hn(bn.y,xn.y,Sn.y,Cn.y);var s=gn(bn.x,xn.x,Sn.x,Cn.x),c=gn(bn.y,xn.y,Sn.y,Cn.y);e.width=s-e.x,e.height=c-e.y},e.calculateTransform=function(e,t,n){var r=n.width/t.width,i=n.height/t.height;return e=Nt(e||[]),It(e,e,Gt(In,-t.x,-t.y)),Rt(e,e,Gt(In,r,i)),It(e,e,Gt(In,n.x,n.y)),e},e}(),On=X.create,kn=X.set,An=X.copy,jn=X.calculateTransform,Mn=X.applyTransform,Nn=X.contain,Pn=new X(0,0,0,0),Fn=new X(0,0,0,0),In=[];function Ln(e,t,n,r,i,a,o,s){var c=_n(t-n),l=_n(r-e),u=hn(c,l),d=vn[i],f=vn[1-i],p=yn[i];t<n||r<e?c<l?(a&&(En[d]=-c),s&&(o[d]=t,o[p]=0)):(a&&(En[d]=l),s&&(o[d]=e,o[p]=0)):(o&&(o[d]=gn(e,n),o[p]=hn(t,r)-o[d]),a&&(u<Dn[0]||wn.useDir)&&(Dn[0]=hn(u,Dn[0]),(c<l||!wn.bidirectional)&&(Tn[d]=c,Tn[f]=0,wn.useDir&&wn.calcDirMTV()),(c>=l||!wn.bidirectional)&&(Tn[d]=-l,Tn[f]=0,wn.useDir&&wn.calcDirMTV())))}function Rn(){var e=0,t=new mn,n=new mn,r={minTv:new mn,maxTv:new mn,useDir:!1,dirMinTv:new mn,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(i,a){r.touchThreshold=0,i&&i.touchThreshold!=null&&(r.touchThreshold=gn(0,i.touchThreshold)),r.negativeSize=!1,a&&(r.minTv.set(1/0,1/0),r.maxTv.set(0,0),r.useDir=!1,i&&i.direction!=null&&(r.useDir=!0,r.dirMinTv.copy(r.minTv),n.copy(r.minTv),e=i.direction,r.bidirectional=i.bidirectional==null||!!i.bidirectional,r.bidirectional||t.set(Math.cos(e),Math.sin(e))))},calcDirMTV:function(){var a=r.minTv,o=r.dirMinTv,s=a.y*a.y+a.x*a.x,c=Math.sin(e),l=Math.cos(e),u=c*a.y+l*a.x;if(i(u)){i(a.x)&&i(a.y)&&o.set(0,0);return}if(n.x=s*l/u,n.y=s*c/u,i(n.x)&&i(n.y)){o.set(0,0);return}(r.bidirectional||t.dot(n)>0)&&n.len()<o.len()&&o.copy(n)}};function i(e){return _n(e)<1e-10}return r}function zn(e){Bn||=new Tt(100),e||=`12px sans-serif`;var t=Bn.get(e);return t||(t={font:e,strWidthCache:new Tt(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:M.measureText(`国`,e).width,asciiCharWidth:M.measureText(`a`,e).width},Bn.put(e,t)),t}var Bn;function Vn(e){if(!(Hn>=Un)){e||=`12px sans-serif`;for(var t=[],n=+new Date,r=0;r<=127;r++)t[r]=M.measureText(String.fromCharCode(r),e).width;var i=+new Date-n;return i>16?Hn=Un:i>2&&Hn++,t}}var Hn=0,Un=5;function Wn(e,t){return e.asciiWidthMapTried||=(e.asciiWidthMap=Vn(e.font),!0),0<=t&&t<=127?e.asciiWidthMap==null?e.asciiCharWidth:e.asciiWidthMap[t]:e.stWideCharWidth}function Gn(e,t){var n=e.strWidthCache,r=n.get(t);return r??(r=M.measureText(t,e.font).width,n.put(t,r)),r}function Kn(e,t,n,r){var i=Gn(zn(t),e),a=Xn(t);return new X(Jn(0,i,n),Yn(0,a,r),i,a)}function qn(e,t,n,r){var i=((e||``)+``).split(`
2
2
  `);if(i.length===1)return Kn(i[0],t,n,r);for(var a=new X(0,0,0,0),o=0;o<i.length;o++){var s=Kn(i[o],t,n,r);o===0?a.copy(s):a.union(s)}return a}function Jn(e,t,n,r){return n===`right`?r?e+=t:e-=t:n===`center`&&(r?e+=t/2:e-=t/2),e}function Yn(e,t,n,r){return n===`middle`?r?e+=t/2:e-=t/2:n===`bottom`&&(r?e+=t:e-=t),e}function Xn(e){return zn(e).stWideCharWidth}function Zn(e,t){return typeof e==`string`?e.lastIndexOf(`%`)>=0?parseFloat(e)/100*t:parseFloat(e):e}function Qn(e,t,n){var r=t.position||`inside`,i=t.distance==null?5:t.distance,a=n.height,o=n.width,s=a/2,c=n.x,l=n.y,u=`left`,d=`top`;if(r instanceof Array)c+=Zn(r[0],n.width),l+=Zn(r[1],n.height),u=null,d=null;else switch(r){case`left`:c-=i,l+=s,u=`right`,d=`middle`;break;case`right`:c+=i+o,l+=s,d=`middle`;break;case`top`:c+=o/2,l-=i,u=`center`,d=`bottom`;break;case`bottom`:c+=o/2,l+=a+i,u=`center`;break;case`inside`:c+=o/2,l+=s,u=`center`,d=`middle`;break;case`insideLeft`:c+=i,l+=s,d=`middle`;break;case`insideRight`:c+=o-i,l+=s,u=`right`,d=`middle`;break;case`insideTop`:c+=o/2,l+=i,u=`center`;break;case`insideBottom`:c+=o/2,l+=a-i,u=`center`,d=`bottom`;break;case`insideTopLeft`:c+=i,l+=i;break;case`insideTopRight`:c+=o-i,l+=i,u=`right`;break;case`insideBottomLeft`:c+=i,l+=a-i,d=`bottom`;break;case`insideBottomRight`:c+=o-i,l+=a-i,u=`right`,d=`bottom`}return e||={},e.x=c,e.y=l,e.align=u,e.verticalAlign=d,e}var $n=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function er(e,t,n,r,i){var a={};return tr(a,e,t,n,r,i),a.text}function tr(e,t,n,r,i,a){if(!n){e.text=``,e.isTruncated=!1;return}var o=(t+``).split(`
3
3
  `);a=nr(n,r,i,a);for(var s=!1,c={},l=0,u=o.length;l<u;l++)rr(c,o[l],a),o[l]=c.textLine,s||=c.isTruncated;e.text=o.join(`
4
4
  `),e.isTruncated=s}function nr(e,t,n,r){r||={};var i=I({},r);n=q(n,`...`),i.maxIterations=q(r.maxIterations,2);var a=i.minChar=q(r.minChar,0),o=i.fontMeasureInfo=zn(t),s=o.asciiCharWidth;i.placeholder=q(r.placeholder,``);for(var c=e=Math.max(0,e-1),l=0;l<a&&c>=s;l++)c-=s;var u=Gn(o,n);return u>c&&(n=``,u=0),c=e-u,i.ellipsis=n,i.ellipsisWidth=u,i.contentWidth=c,i.containerWidth=e,i}function rr(e,t,n){var r=n.containerWidth,i=n.contentWidth,a=n.fontMeasureInfo;if(!r){e.textLine=``,e.isTruncated=!1;return}var o=Gn(a,t);if(o<=r){e.textLine=t,e.isTruncated=!1;return}for(var s=0;;s++){if(o<=i||s>=n.maxIterations){t+=n.ellipsis;break}var c=s===0?ir(t,i,a):o>0?Math.floor(t.length*i/o):0;t=t.substr(0,c),o=Gn(a,t)}t===``&&(t=n.placeholder),e.textLine=t,e.isTruncated=!0}function ir(e,t,n){for(var r=0,i=0,a=e.length;i<a&&r<t;i++)r+=Wn(n,e.charCodeAt(i));return i}function ar(e,t,n,r){var i=vr(e),a=t.overflow,o=t.padding,s=o?o[1]+o[3]:0,c=o?o[0]+o[2]:0,l=t.font,u=a===`truncate`,d=Xn(l),f=q(t.lineHeight,d),p=t.lineOverflow===`truncate`,m=!1,h=t.width;h==null&&n!=null&&(h=n-s);var g=t.height;g==null&&r!=null&&(g=r-c);var _=h!=null&&(a===`break`||a===`breakAll`)?i?mr(i,t.font,h,a===`breakAll`,0).lines:[]:i?i.split(`
@@ -36,4 +36,4 @@ yyyy`);var r=Tc(t),i=n?`getUTC`:`get`,a=r[i+`FullYear`](),o=r[i+`Month`]()+1,s=r
36
36
  `:`<br/>`,m=l.join(p);this._showOrMove(a,function(){this._updateContentNotChangedOnAxis(e,s)?this._updatePosition(a,d,i[0],i[1],this._tooltipContent,s):this._showTooltipContent(a,m,s,Math.random()+``,i[0],i[1],d,null,u)})},t.prototype._showSeriesItemTooltip=function(e,t,n){var r=this._ecModel,i=Wl(t),a=i.seriesIndex,o=r.getSeriesByIndex(a),s=i.dataModel||o,c=i.dataIndex,l=i.dataType,u=s.getData(l),d=this._renderMode,f=e.positionDefault,p=CB([u.getItemModel(c),s,o&&(o.coordinateSystem||{}).model],this._tooltipModel,f?{position:f}:null),m=p.get(`trigger`);if(m==null||m===`item`){var h=s.getDataParams(c,l),g=new oy;h.marker=g.makeTooltipMarker(`item`,G_(h.color),d);var _=yv(s.formatTooltip(c,!1,l)),v=p.get(`order`),y=p.get(`valueFormatter`),b=_.frag,x=b?Zv(y?I({valueFormatter:y},b):b,g,d,v,r.get(`useUTC`),p.get(`textStyle`)):_.text,S=`item_`+s.name+`_`+c;this._showOrMove(p,function(){this._showTooltipContent(p,x,h,S,e.offsetX,e.offsetY,e.position,e.target,g)}),n({type:`showTip`,dataIndexInside:c,dataIndex:u.getRawIndex(c),seriesIndex:a,from:this.uid})}},t.prototype._showComponentItemTooltip=function(e,t,n){var r=this._renderMode===`html`,i=Wl(t),a=i.tooltipConfig.option||{},o=a.encodeHTMLContent;if(G(a)){var s=a;a={content:s,formatter:s},o=!0}o&&r&&a.content&&(a=P(a),a.content=Pg(a.content));var c=[a],l=this._ecModel.getComponent(i.componentMainType,i.componentIndex);l&&c.push(l),c.push({formatter:a.content});var u=e.positionDefault,d=CB(c,this._tooltipModel,u?{position:u}:null),f=d.get(`content`),p=Math.random()+``,m=new oy;this._showOrMove(d,function(){var n=P(d.get(`formatterParams`)||{});this._showTooltipContent(d,f,n,p,e.offsetX,e.offsetY,e.position,t,m)}),n({type:`showTip`,from:this.uid})},t.prototype._showTooltipContent=function(e,t,n,r,i,a,o,s,c){if(this._ticket=``,e.get(`showContent`)&&e.get(`show`)){var l=this._tooltipContent;l.setEnterable(e.get(`enterable`));var u=e.get(`formatter`);o||=e.get(`position`);var d=t,f=this._getNearestPoint([i,a],n,e.get(`trigger`),e.get(`borderColor`),e.get(`defaultBorderColor`,!0)).color;if(u){if(G(u)){var p=e.ecModel.get(`useUTC`),m=U(n)?n[0]:n,h=m&&m.axisType&&m.axisType.indexOf(`time`)>=0;d=u,h&&(d=g_(m.axisValue,d,p)),d=V_(d,n,!0)}else if(W(u)){var g=H(function(t,r){t===this._ticket&&(l.setContent(r,c,e,f,o),this._updatePosition(e,o,i,a,l,n,s))},this);this._ticket=r,d=u(n,r,g)}else d=u}l.setContent(d,c,e,f,o),l.show(e,f),this._updatePosition(e,o,i,a,l,n,s)}},t.prototype._getNearestPoint=function(e,t,n,r,i){if(n===`axis`||U(t))return{color:r||i};if(!U(t))return{color:r||t.color||t.borderColor}},t.prototype._updatePosition=function(e,t,n,r,i,a,o){var s=this._api.getWidth(),c=this._api.getHeight();t||=e.get(`position`);var l=i.getSize(),u=e.get(`align`),d=e.get(`verticalAlign`),f=o&&o.getBoundingRect().clone();if(o&&f.applyTransform(o.transform),W(t)&&(t=t([n,r],a,i.el,f,{viewSize:[s,c],contentSize:l.slice()})),U(t))n=oc(t[0],s),r=oc(t[1],c);else if(K(t)){var p=t;p.width=l[0],p.height=l[1];var m=Q_(p,{width:s,height:c});n=m.x,r=m.y,u=null,d=null}else if(G(t)&&o){var h=DB(t,f,l,e.get(`borderWidth`));n=h[0],r=h[1]}else{var h=TB(n,r,i,s,c,u?null:20,d?null:20);n=h[0],r=h[1]}if(u&&(n-=OB(u)?l[0]/2:u===`right`?l[0]:0),d&&(r-=OB(d)?l[1]/2:d===`bottom`?l[1]:0),eB(e)){var h=EB(n,r,i,s,c);n=h[0],r=h[1]}i.moveTo(n,r)},t.prototype._updateContentNotChangedOnAxis=function(e,t){var n=this._lastDataByCoordSys,r=this._cbParamsList,i=!!n&&n.length===e.length;return i&&z(n,function(n,a){var o=n.dataByAxis||[],s=(e[a]||{}).dataByAxis||[];i&&=o.length===s.length,i&&z(o,function(e,n){var a=s[n]||{},o=e.seriesDataIndices||[],c=a.seriesDataIndices||[];i=i&&e.value===a.value&&e.axisType===a.axisType&&e.axisId===a.axisId&&o.length===c.length,i&&z(o,function(e,t){var n=c[t];i=i&&e.seriesIndex===n.seriesIndex&&e.dataIndex===n.dataIndex}),r&&z(e.seriesDataIndices,function(e){var n=e.seriesIndex,a=t[n],o=r[n];a&&o&&o.data!==a.data&&(i=!1)})})}),this._lastDataByCoordSys=e,this._cbParamsList=t,!!i},t.prototype._hide=function(e){this._lastDataByCoordSys=null,this._cbParamsList=null,e({type:`hideTip`,from:this.uid})},t.prototype.dispose=function(e,t){!Y.node&&t.getDom()&&($w(this,`_updatePosition`),this._tooltipContent.dispose(),dR(`itemTooltip`,t),this._tooltipContent=null,this._tooltipModel=null,this._lastDataByCoordSys=null,this._cbParamsList=null)},t.type=`tooltip`,t}(sO);function CB(e,t,n){var r=t.ecModel,i;n?(i=new pm(n,r,r),i=new pm(t.option,i,r)):i=t;for(var a=e.length-1;a>=0;a--){var o=e[a];o&&(o instanceof pm&&(o=o.get(`tooltip`,!0)),G(o)&&(o={formatter:o}),o&&(i=new pm(o,i,r)))}return i}function wB(e,t){return e.dispatchAction||H(t.dispatchAction,t)}function TB(e,t,n,r,i,a,o){var s=n.getSize(),c=s[0],l=s[1];return a!=null&&(e+c+a+2>r?e-=c+a:e+=a),o!=null&&(t+l+o>i?t-=l+o:t+=o),[e,t]}function EB(e,t,n,r,i){var a=n.getSize(),o=a[0],s=a[1];return e=Math.min(e+o,r)-o,t=Math.min(t+s,i)-s,e=Math.max(e,0),t=Math.max(t,0),[e,t]}function DB(e,t,n,r){var i=n[0],a=n[1],o=Math.ceil(Math.SQRT2*r)+8,s=0,c=0,l=t.width,u=t.height;switch(e){case`inside`:s=t.x+l/2-i/2,c=t.y+u/2-a/2;break;case`top`:s=t.x+l/2-i/2,c=t.y-a-o;break;case`bottom`:s=t.x+l/2-i/2,c=t.y+u+o;break;case`left`:s=t.x-i-o,c=t.y+u/2-a/2;break;case`right`:s=t.x+l+o,c=t.y+u/2-a/2}return[s,c]}function OB(e){return e===`center`||e===`middle`}function kB(e,t,n){var r=_l(e).queryOptionMap,i=r.keys()[0];if(i&&i!==`series`){var a=bl(t,i,r.get(i),{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];if(a){var o=n.getViewOfComponentModel(a),s;if(o.group.traverse(function(t){var n=Wl(t).tooltipConfig;if(n&&n.name===e.name)return s=t,!0}),s)return{componentMainType:i,componentIndex:a.componentIndex,el:s}}}}function AB(e){Vj(ER),e.registerComponentModel($z),e.registerComponentView(SB),e.registerAction({type:`showTip`,event:`showTip`,update:`tooltip:manuallyShowTip`},tt),e.registerAction({type:`hideTip`,event:`hideTip`,update:`tooltip:manuallyHideTip`},tt)}var jB=[`rect`,`polygon`,`keep`,`clear`];function MB(e,t){var n=Kc(e?e.brush:[]);if(n.length){var r=[];z(n,function(e){var t=e.hasOwnProperty(`toolbox`)?e.toolbox:[];t instanceof Array&&(r=r.concat(t))});var i=e&&e.toolbox;U(i)&&(i=i[0]),i||(i={feature:{}},e.toolbox=[i]);var a=i.feature||(i.feature={}),o=a.brush||={},s=o.type||=[];s.push.apply(s,r),Ll(s,function(e){return e+``},null),t&&!s.length&&s.push.apply(s,jB)}}var NB=z;function PB(e){if(e){for(var t in e)if(e.hasOwnProperty(t))return!0}}function FB(e,t,n){var r={};return NB(t,function(t){var a=r[t]=i();NB(e[t],function(e,r){if(eI.isValidType(r)){var i={type:r,visual:e};n&&n(i,t),a[r]=new eI(i),r===`opacity`&&(i=P(i),i.type=`colorAlpha`,a.__hidden.__alphaForOpacity=new eI(i))}})}),r;function i(){var e=function(){};return e.prototype.__hidden=e.prototype,new e}}function IB(e,t,n){var r;z(n,function(e){t.hasOwnProperty(e)&&PB(t[e])&&(r=!0)}),r&&z(n,function(n){t.hasOwnProperty(n)&&PB(t[n])?e[n]=P(t[n]):delete e[n]})}function LB(e,t,n,r,i,a){var o={};z(e,function(e){o[e]=eI.prepareVisualTypes(t[e])});var s;function c(e){return UO(n,s,e)}function l(e,t){GO(n,s,e,t)}a==null?n.each(u):n.each([a],u);function u(e,u){s=a==null?e:u;var d=n.getRawDataItem(s);if(!(d&&d.visualMap===!1))for(var f=r.call(i,e),p=t[f],m=o[f],h=0,g=m.length;h<g;h++){var _=m[h];p[_]&&p[_].applyVisual(e,c,l)}}}function RB(e,t,n,r){var i={};return z(e,function(e){i[e]=eI.prepareVisualTypes(t[e])}),{progress:function(e,a){var o;r!=null&&(o=a.getDimensionIndex(r));function s(e){return UO(a,l,e)}function c(e,t){GO(a,l,e,t)}for(var l,u=a.getStore();(l=e.next())!=null;){var d=a.getRawDataItem(l);if(!(d&&d.visualMap===!1))for(var f=r==null?l:u.get(o,l),p=n(f),m=t[p],h=i[p],g=0,_=h.length;g<_;g++){var v=h[g];m[v]&&m[v].applyVisual(f,s,c)}}}}}function zB(e){var t=e.brushType,n={point:function(r){return BB[t].point(r,n,e)},rect:function(r){return BB[t].rect(r,n,e)}};return n}var BB={lineX:VB(0),lineY:VB(1),rect:{point:function(e,t,n){return e&&n.boundingRect.contain(e[0],e[1])},rect:function(e,t,n){return e&&n.boundingRect.intersect(e)}},polygon:{point:function(e,t,n){return e&&n.boundingRect.contain(e[0],e[1])&&zN(n.range,e[0],e[1])},rect:function(e,t,n){var r=n.range;if(!e||r.length<=1)return!1;var i=e.x,a=e.y,o=e.width,s=e.height,c=r[0];if(zN(r,i,a)||zN(r,i+o,a)||zN(r,i,a+s)||zN(r,i+o,a+s)||X.create(e).contain(c[0],c[1])||vp(i,a,i+o,a,r)||vp(i,a,i,a+s,r)||vp(i+o,a,i+o,a+s,r)||vp(i,a+s,i+o,a+s,r))return!0}}};function VB(e){var t=[`x`,`y`],n=[`width`,`height`];return{point:function(t,n,r){if(t){var i=r.range,a=t[e];return HB(a,i)}},rect:function(r,i,a){if(r){var o=a.range,s=[r[t[e]],r[t[e]]+r[n[e]]];return s[1]<s[0]&&s.reverse(),HB(s[0],o)||HB(s[1],o)||HB(o[0],s)||HB(o[1],s)}}}}function HB(e,t){return t[0]<=e&&e<=t[1]}var UB=[`inBrush`,`outOfBrush`],WB=`__ecBrushSelect`,GB=`__ecInBrushSelectEvent`;function KB(e){e.eachComponent({mainType:`brush`},function(t){(t.brushTargetManager=new Mz(t.option,e)).setInputRanges(t.areas,e)})}var qB=Ul(JB);function JB(e,t,n){var r=[],i,a;e.eachComponent({mainType:`brush`},function(e){n&&n.type===`takeGlobalCursor`&&e.setBrushOption(n.key===`brush`?n.brushOption:{brushType:!1})}),KB(e),e.eachComponent({mainType:`brush`},function(t,n){var o={brushId:t.id,brushIndex:n,brushName:t.name,areas:P(t.areas),selected:[]};r.push(o);var s=t.option,c=s.brushLink,l=[],u=[],d=[],f=!1;n||(i=s.throttleType,a=s.throttleDelay);var p=B(t.areas,function(e){var t=$B[e.brushType],n=L({boundingRect:t?t(e):void 0},e);return n.selectors=zB(n),n}),m=FB(t.option,UB,function(e){e.mappingMethod=`fixed`});U(c)&&z(c,function(e){l[e]=1});function h(e){return c===`all`||!!l[e]}function g(e){return!!e.length}e.eachSeries(function(e,t){var n=d[t]=[];e.subType===`parallel`?_(e,t):v(e,t,n)});function _(e,t){var n=e.coordinateSystem;f||=n.hasAxisBrushed(),h(t)&&n.eachActiveState(e.getData(),function(e,t){e===`active`&&(u[t]=1)})}function v(n,r,i){if(n.brushSelector&&!QB(t,r)&&(z(p,function(r){t.brushTargetManager.controlSeries(r,n,e)&&i.push(r),f||=g(i)}),h(r)&&g(i))){var a=n.getData();a.each(function(e){ZB(n,i,a,e)&&(u[e]=1)})}}e.eachSeries(function(e,t){var n={seriesId:e.id,seriesIndex:t,seriesName:e.name,dataIndex:[]};o.selected.push(n);var r=d[t],i=e.getData(),a=h(t)?function(e){return u[e]?(n.dataIndex.push(i.getRawIndex(e)),`inBrush`):`outOfBrush`}:function(t){return ZB(e,r,i,t)?(n.dataIndex.push(i.getRawIndex(t)),`inBrush`):`outOfBrush`};(h(t)?f:g(r))&&LB(UB,m,i,a)})}),YB(t,i,a,r,n)}function YB(e,t,n,r,i){if(i){var a=e.getZr();a[GB]||(a[WB]||(a[WB]=XB),Qw(a,WB,n,t)(e,r))}}function XB(e,t){if(!e.isDisposed()){var n=e.getZr();n[GB]=!0,e.dispatchAction({type:`brushSelect`,batch:t}),n[GB]=!1}}function ZB(e,t,n,r){for(var i=0,a=t.length;i<a;i++){var o=t[i];if(e.brushSelector(r,n,o.selectors,o))return!0}}function QB(e,t){var n=e.option.seriesIndex;return n!=null&&n!==`all`&&(U(n)?R(n,t)<0:t!==n)}var $B={rect:function(e){return eV(e.range)},polygon:function(e){for(var t,n=e.range,r=0,i=n.length;r<i;r++){t||=[El(),El()];var a=n[r];a[0]<t[0][0]&&(t[0][0]=a[0]),a[0]>t[0][1]&&(t[0][1]=a[0]),a[1]<t[1][0]&&(t[1][0]=a[1]),a[1]>t[1][1]&&(t[1][1]=a[1])}return t&&eV(t)}};function eV(e){return new X(e[0][0],e[1][0],e[0][1]-e[0][0],e[1][1]-e[1][0])}var tV=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.init=function(e,t){this.ecModel=e,this.api=t,this.model,(this._brushController=new KI(t.getZr())).on(`brush`,H(this._onBrush,this)).mount()},t.prototype.render=function(e,t,n,r){this.model=e,this._updateController(e,t,n,r)},t.prototype.updateTransform=function(e,t,n,r){KB(t),this._updateController(e,t,n,r)},t.prototype.updateVisual=function(e,t,n,r){this.updateTransform(e,t,n,r)},t.prototype.updateView=function(e,t,n,r){this._updateController(e,t,n,r)},t.prototype._updateController=function(e,t,n,r){(!r||r.$from!==e.id)&&this._brushController.setPanels(e.brushTargetManager.makePanelOpts(n)).enableBrush(e.brushOption).updateCovers(e.areas.slice())},t.prototype.dispose=function(){this._brushController.dispose()},t.prototype._onBrush=function(e){var t=this.model.id,n=this.model.brushTargetManager.setOutputRanges(e.areas,this.ecModel);(!e.isEnd||e.removeOnClick)&&this.api.dispatchAction({type:`brush`,brushId:t,areas:P(n),$from:t}),e.isEnd&&this.api.dispatchAction({type:`brushEnd`,brushId:t,areas:P(n),$from:t})},t.type=`brush`,t}(sO),nV=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.areas=[],n.brushOption={},n}return t.prototype.optionUpdated=function(e,t){var n=this.option;!t&&IB(n,e,[`inBrush`,`outOfBrush`]);var r=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:this.option.defaultOutOfBrushColor},r.hasOwnProperty(`liftZ`)||(r.liftZ=5)},t.prototype.setAreas=function(e){e&&(this.areas=B(e,function(e){return rV(this.option,e)},this))},t.prototype.setBrushOption=function(e){this.brushOption=rV(this.option,e),this.brushType=this.brushOption.brushType},t.type=`brush`,t.dependencies=[`geo`,`grid`,`xAxis`,`yAxis`,`parallel`,`series`],t.defaultOption={seriesIndex:`all`,brushType:`rect`,brushMode:`single`,transformable:!0,brushStyle:{borderWidth:1,color:Z.color.backgroundTint,borderColor:Z.color.borderTint},throttleType:`fixRate`,throttleDelay:0,removeOnClick:!0,z:1e4,defaultOutOfBrushColor:Z.color.disabled},t}(cv);function rV(e,t){return F({brushType:e.brushType,brushMode:e.brushMode,transformable:e.transformable,brushStyle:new pm(e.brushStyle).getItemStyle(),removeOnClick:e.removeOnClick,z:e.z},t,!0)}var iV=[`rect`,`polygon`,`lineX`,`lineY`,`keep`,`clear`],aV=function(e){D(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.render=function(e,t,n){var r,i,a;t.eachComponent({mainType:`brush`},function(e){r=e.brushType,i=e.brushOption.brushMode||`single`,a||=!!e.areas.length}),this._brushType=r,this._brushMode=i,z(e.get(`type`,!0),function(t){e.setIconStatus(t,(t===`keep`?i===`multiple`:t===`clear`?a:t===r)?`emphasis`:`normal`)})},t.prototype.updateView=function(e,t,n){this.render(e,t,n)},t.prototype.getIcons=function(){var e=this.model,t=e.get(`icon`,!0),n={};return z(e.get(`type`,!0),function(e){t[e]&&(n[e]=t[e])}),n},t.prototype.onclick=function(e,t,n){var r=this._brushType,i=this._brushMode;n===`clear`?(t.dispatchAction({type:`axisAreaSelect`,intervals:[]}),t.dispatchAction({type:`brush`,command:`clear`,areas:[]})):t.dispatchAction({type:`takeGlobalCursor`,key:`brush`,brushOption:{brushType:n===`keep`?r:r!==n&&n,brushMode:n===`keep`?i===`multiple`?`single`:`multiple`:i}})},t.getDefaultOption=function(e){return{show:!0,type:iV.slice(),icon:{rect:`M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13`,polygon:`M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2`,lineX:`M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4`,lineY:`M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4`,keep:`M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z`,clear:`M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2`},title:e.getLocaleModel().get([`toolbox`,`brush`,`title`])}},t}(YR);function oV(e){e.registerComponentView(tV),e.registerComponentModel(nV),e.registerPreprocessor(MB),e.registerVisual(e.PRIORITY.VISUAL.BRUSH,qB),e.registerAction({type:`brush`,event:`brush`,update:`updateVisual`},function(e,t){t.eachComponent({mainType:`brush`,query:e},function(t){t.setAreas(e.areas)})}),e.registerAction({type:`brushSelect`,event:`brushSelected`,update:`none`},tt),e.registerAction({type:`brushEnd`,event:`brushEnd`,update:`none`},tt),ZR(`brush`,aV)}function sV(e,t){if(!e)return!1;for(var n=U(e)?e:[e],r=0;r<n.length;r++)if(n[r]&&n[r][t])return!0;return!1}function cV(e){qc(e,`label`,[`show`])}var lV=ml(),uV=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.createdBySelf=!1,n.preventAutoZ=!0,n}return t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n),this._mergeOption(e,n,!1,!0)},t.prototype.isAnimationEnabled=function(){if(Y.node)return!1;var e=this.__hostSeries;return this.getShallow(`animation`)&&e&&e.isAnimationEnabled()},t.prototype.mergeOption=function(e,t){this._mergeOption(e,t,!1,!1)},t.prototype._mergeOption=function(e,t,n,r){var i=this.mainType;n||t.eachSeries(function(e){var n=e.get(this.mainType,!0),a=lV(e)[i];if(!n||!n.data){lV(e)[i]=null;return}a?a._mergeOption(n,t,!0):(r&&cV(n),z(n.data,function(e){e instanceof Array?(cV(e[0]),cV(e[1])):cV(e)}),a=this.createMarkerModelFromSeries(n,this,t),I(a,{mainType:this.mainType,seriesIndex:e.seriesIndex,name:e.name,createdBySelf:!0}),a.__hostSeries=e),lV(e)[i]=a},this)},t.prototype.formatTooltip=function(e,t,n){var r=this.getData(),i=this.getRawValue(e),a=r.getName(e);return Gv(`section`,{header:this.name,blocks:[Gv(`nameValue`,{name:a,value:i,noName:!a,noValue:i==null})]})},t.prototype.getData=function(){return this._data},t.prototype.setData=function(e){this._data=e},t.prototype.getDataParams=function(e,t){var n=vv.prototype.getDataParams.call(this,e,t),r=this.__hostSeries;return r&&(n.seriesId=r.id,n.seriesName=r.name,n.seriesType=r.subType),n},t.getMarkerModelFromSeries=function(e,t){return lV(e)[t]},t.type=`marker`,t.dependencies=[`series`,`grid`,`polar`,`geo`],t}(cv);Se(uV,vv.prototype);function dV(e){return!(isNaN(parseFloat(e.x))&&isNaN(parseFloat(e.y)))}function fV(e){return!isNaN(parseFloat(e.x))&&!isNaN(parseFloat(e.y))}function pV(e,t,n,r,i,a,o){var s=[],c=lg(t,i)?t.getCalculationInfo(`stackResultDimension`):i,l=bV(t,c,e),u=t.hostModel.indicesOfNearest(n,c,l)[0];s[a]=t.get(r,u),s[o]=t.get(c,u);var d=t.get(i,u),f=mc(t.get(i,u));return f=Math.min(f,20),f>=0&&(s[o]=+s[o].toFixed(f)),[s,d]}var mV={min:Oe(pV,`min`),max:Oe(pV,`max`),average:Oe(pV,`average`),median:Oe(pV,`median`)};function hV(e,t){if(t){var n=e.getData(),r=e.coordinateSystem,i=r&&r.dimensions;if(!fV(t)&&!U(t.coord)&&U(i)){var a=gV(t,n,r,e);if(t=P(t),t.type&&mV[t.type]&&a.baseAxis&&a.valueAxis){var o=R(i,a.baseAxis.dim),s=R(i,a.valueAxis.dim),c=mV[t.type](n,a.valueAxis.dim,a.baseDataDim,a.valueDataDim,o,s);t.coord=c[0],t.value=c[1]}else t.coord=[t.xAxis==null?t.radiusAxis:t.xAxis,t.yAxis==null?t.angleAxis:t.yAxis]}if(t.coord==null||!U(i)){t.coord=[];var l=e.getBaseAxis();if(l&&t.type&&mV[t.type]){var u=r.getOtherAxis(l);u&&(t.value=bV(n,n.mapDimension(u.dim),t.type))}}else for(var d=t.coord,f=0;f<2;f++)mV[d[f]]&&(d[f]=bV(n,n.mapDimension(i[f]),d[f]));return t}}function gV(e,t,n,r){var i={};return e.valueIndex!=null||e.valueDim!=null?(i.valueDataDim=e.valueIndex==null?e.valueDim:t.getDimension(e.valueIndex),i.valueAxis=n.getAxis(_V(r,i.valueDataDim)),i.baseAxis=n.getOtherAxis(i.valueAxis),i.baseDataDim=t.mapDimension(i.baseAxis.dim)):(i.baseAxis=r.getBaseAxis(),i.valueAxis=n.getOtherAxis(i.baseAxis),i.baseDataDim=t.mapDimension(i.baseAxis.dim),i.valueDataDim=t.mapDimension(i.valueAxis.dim)),i}function _V(e,t){var n=e.getData().getDimensionInfo(t);return n&&n.coordDim}function vV(e,t){return e&&e.containData&&t.coord&&!dV(t)?e.containData(t.coord):!0}function yV(e,t){return e?function(e,n,r,i){return ch(i<2?e.coord&&e.coord[i]:e.value,t[i])}:function(e,n,r,i){return ch(e.value,t[i])}}function bV(e,t,n){if(n===`average`){var r=0,i=0;return e.each(t,function(e,t){isNaN(e)||(r+=e,i++)}),r/i}return n===`median`?e.getMedian(t):e.getDataExtent(t)[+(n===`max`)]}var xV=ml(),SV=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.init=function(){this.markerGroupMap=J()},t.prototype.render=function(e,t,n){var r=this,i=this.markerGroupMap;i.each(function(e){xV(e).keep=!1}),t.eachSeries(function(e){var i=uV.getMarkerModelFromSeries(e,r.type);i&&r.renderSeries(e,i,t,n)}),i.each(function(e){!xV(e).keep&&r.group.remove(e.group)}),CV(t,i,this.type)},t.prototype.markKeep=function(e){xV(e).keep=!0},t.prototype.toggleBlurSeries=function(e,t){var n=this;z(e,function(e){var r=uV.getMarkerModelFromSeries(e,n.type);r&&r.getData().eachItemGraphicEl(function(e){e&&(t?Ru(e):zu(e))})})},t.type=`marker`,t}(sO);function CV(e,t,n){e.eachSeries(function(e){var r=uV.getMarkerModelFromSeries(e,n),i=t.get(e.id);if(r&&i&&i.group){var a=Mp(r),o=a.z,s=a.zlevel;Pp(i.group,o,s)}})}var wV=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.createMarkerModelFromSeries=function(e,n,r){return new t(e,n,r)},t.type=`markLine`,t.defaultOption={z:5,symbol:[`circle`,`arrow`],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:`item`},label:{show:!0,position:`end`,distance:5},lineStyle:{type:`dashed`},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:`linear`},t}(uV),TV=ml(),EV=function(e,t,n,r){var i=e.getData(),a;if(U(r))a=r;else{var o=r.type;if(o===`min`||o===`max`||o===`average`||o===`median`||r.xAxis!=null||r.yAxis!=null){var s=void 0,c=void 0;if(r.yAxis!=null||r.xAxis!=null)s=t.getAxis(r.yAxis==null?`x`:`y`),c=Re(r.yAxis,r.xAxis);else{var l=gV(r,i,t,e);s=l.valueAxis,c=bV(i,ug(i,l.valueDataDim),o)}var u=s.dim===`x`?0:1,d=1-u,f=P(r),p={coord:[]};f.type=null,f.coord=[],f.coord[d]=-1/0,p.coord[d]=1/0;var m=n.get(`precision`);m>=0&&Ae(c)&&(c=+c.toFixed(Math.min(m,20))),f.coord[u]=p.coord[u]=c,a=[f,p,{type:o,valueIndex:r.valueIndex,value:c}]}else a=[]}var h=[hV(e,a[0]),hV(e,a[1]),I({},a[2])];return h[2].type=h[2].type||null,F(h[2],h[0]),F(h[2],h[1]),h};function DV(e){return!isNaN(e)&&!isFinite(e)}function OV(e,t,n,r){var i=1-e,a=r.dimensions[e];return DV(t[i])&&DV(n[i])&&t[e]===n[e]&&r.getAxis(a).containData(t[e])}function kV(e,t){if(e.type===`cartesian2d`){var n=t[0].coord,r=t[1].coord;if(n&&r&&(OV(1,n,r,e)||OV(0,n,r,e)))return!0}return vV(e,t[0])&&vV(e,t[1])}function AV(e,t,n,r,i){var a=r.coordinateSystem,o=e.getItemModel(t),s,c=oc(o.get(`x`),i.getWidth()),l=oc(o.get(`y`),i.getHeight());if(!isNaN(c)&&!isNaN(l))s=[c,l];else{if(r.getMarkerPosition)s=r.getMarkerPosition(e.getValues(e.dimensions,t));else{var u=a.dimensions,d=e.get(u[0],t),f=e.get(u[1],t);s=a.dataToPoint([d,f])}if(mb(a,`cartesian2d`)){var p=a.getAxis(`x`),m=a.getAxis(`y`),u=a.dimensions;DV(e.get(u[0],t))?s[0]=p.toGlobalCoord(p.getExtent()[+!n]):DV(e.get(u[1],t))&&(s[1]=m.toGlobalCoord(m.getExtent()[+!n]))}isNaN(c)||(s[0]=c),isNaN(l)||(s[1]=l)}e.setItemLayout(t,s)}var jV=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.updateTransform=function(e,t,n){t.eachSeries(function(e){var t=uV.getMarkerModelFromSeries(e,`markLine`);if(t){var r=t.getData(),i=TV(t).from,a=TV(t).to;i.each(function(t){AV(i,t,!0,e,n),AV(a,t,!1,e,n)}),r.each(function(e){r.setItemLayout(e,[i.getItemLayout(e),a.getItemLayout(e)])}),this.markerGroupMap.get(e.id).updateLayout()}},this)},t.prototype.renderSeries=function(e,t,n,r){var i=e.coordinateSystem,a=e.id,o=e.getData(),s=this.markerGroupMap,c=s.get(a)||s.set(a,new EI);this.group.add(c.group);var l=MV(i,e,t),u=l.from,d=l.to,f=l.line;TV(t).from=u,TV(t).to=d,t.setData(f);var p=t.get(`symbol`),m=t.get(`symbolSize`),h=t.get(`symbolRotate`),g=t.get(`symbolOffset`);U(p)||(p=[p,p]),U(m)||(m=[m,m]),U(h)||(h=[h,h]),U(g)||(g=[g,g]),l.from.each(function(e){_(u,e,!0),_(d,e,!1)}),f.each(function(e){var t=f.getItemModel(e),n=t.getModel(`lineStyle`).getLineStyle();f.setItemLayout(e,[u.getItemLayout(e),d.getItemLayout(e)]);var r=t.get(`z2`);n.stroke??=u.getItemVisual(e,`style`).fill,f.setItemVisual(e,{z2:q(r,0),fromSymbolKeepAspect:u.getItemVisual(e,`symbolKeepAspect`),fromSymbolOffset:u.getItemVisual(e,`symbolOffset`),fromSymbolRotate:u.getItemVisual(e,`symbolRotate`),fromSymbolSize:u.getItemVisual(e,`symbolSize`),fromSymbol:u.getItemVisual(e,`symbol`),toSymbolKeepAspect:d.getItemVisual(e,`symbolKeepAspect`),toSymbolOffset:d.getItemVisual(e,`symbolOffset`),toSymbolRotate:d.getItemVisual(e,`symbolRotate`),toSymbolSize:d.getItemVisual(e,`symbolSize`),toSymbol:d.getItemVisual(e,`symbol`),style:n})}),c.updateData(f),l.line.eachItemGraphicEl(function(e){Wl(e).dataModel=t,e.traverse(function(e){Wl(e).dataModel=t})});function _(t,n,i){var a=t.getItemModel(n);AV(t,n,i,e,r);var s=a.getModel(`itemStyle`).getItemStyle();s.fill??=WO(o,`color`),t.setItemVisual(n,{symbolKeepAspect:a.get(`symbolKeepAspect`),symbolOffset:q(a.get(`symbolOffset`,!0),g[+!i]),symbolRotate:q(a.get(`symbolRotate`,!0),h[+!i]),symbolSize:q(a.get(`symbolSize`),m[+!i]),symbol:q(a.get(`symbol`,!0),p[+!i]),style:s})}this.markKeep(c),c.group.silent=t.get(`silent`)||e.get(`silent`)},t.type=`markLine`,t}(SV);function MV(e,t,n){var r=e?B(e&&e.dimensions,function(e){var n=t.getData();return I(I({},n.getDimensionInfo(n.mapDimension(e))||{}),{name:e,ordinalMeta:null})}):[{name:`value`,type:`float`}],i=new Wh(r,n),a=new Wh(r,n),o=new Wh([],n),s=B(n.get(`data`),Oe(EV,t,e,n));e&&(s=Te(s,Oe(kV,e)));var c=yV(!!e,r);return i.initData(B(s,function(e){return e[0]}),null,c),a.initData(B(s,function(e){return e[1]}),null,c),o.initData(B(s,function(e){return e[2]})),o.hasItemOption=!0,{from:i,to:a,line:o}}function NV(e){e.registerComponentModel(wV),e.registerComponentView(jV),e.registerPreprocessor(function(e){sV(e.series,`markLine`)&&(e.markLine=e.markLine||{})})}var PV={get:function(e,t,n){var r=P((FV[e]||{})[t]);return n&&U(r)?r[r.length-1]:r}},FV={color:{active:[`#006edd`,`#e0ffff`],inactive:[Z.color.transparent]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:[`circle`,`roundRect`,`diamond`],inactive:[`none`]},symbolSize:{active:[10,50],inactive:[0,0]}},IV=eI.mapVisual,LV=eI.eachVisual,RV=U,zV=z,BV=pc,VV=ac,HV=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.stateList=[`inRange`,`outOfRange`],n.replacableOptionKeys=[`inRange`,`outOfRange`,`target`,`controller`,`color`],n.layoutMode={type:`box`,ignoreSize:!0},n.dataBound=[-1/0,1/0],n.targetVisuals={},n.controllerVisuals={},n}return t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n)},t.prototype.optionUpdated=function(e,t){var n=this.option;!t&&IB(n,e,this.replacableOptionKeys),this.textStyleModel=this.getModel(`textStyle`),this.resetItemSize(),this.completeVisualOption()},t.prototype.resetVisual=function(e){var t=this.stateList;e=H(e,this),this.controllerVisuals=FB(this.option.controller,t,e),this.targetVisuals=FB(this.option.target,t,e)},t.prototype.getItemSymbol=function(){return null},t.prototype.getTargetSeriesIndices=function(){var e=this,t=this.option.seriesTargets;if(t){var n=[];return zV(t,function(t){if(t.seriesIndex!=null)n.push(t.seriesIndex);else if(t.seriesId!=null){var r;e.ecModel.eachSeries(function(e){e.id===t.seriesId&&(r=e)}),r&&n.push(r.componentIndex)}}),n}var r=this.option.seriesId,i=this.option.seriesIndex;i==null&&r==null&&(i=`all`);var a=bl(this.ecModel,`series`,{index:i,id:r},{useDefault:!1,enableAll:!0,enableNone:!1}).models;return B(a,function(e){return e.componentIndex})},t.prototype.eachTargetSeries=function(e,t){z(this.getTargetSeriesIndices(),function(n){var r=this.ecModel.getSeriesByIndex(n);r&&e.call(t,r)},this)},t.prototype.isTargetSeries=function(e){var t=!1;return this.eachTargetSeries(function(n){n===e&&(t=!0)}),t},t.prototype.formatValueText=function(e,t,n){var r=this.option,i=r.precision,a=this.dataBound,o=r.formatter,s;n||=[`<`,`>`],U(e)&&(e=e.slice(),s=!0);var c=t?e:s?[l(e[0]),l(e[1])]:l(e);return G(o)?o.replace(`{value}`,s?c[0]:c).replace(`{value2}`,s?c[1]:c):W(o)?s?o(e[0],e[1]):o(e):s?e[0]===a[0]?n[0]+` `+c[1]:e[1]===a[1]?n[1]+` `+c[0]:c[0]+` - `+c[1]:c;function l(e){return e===a[0]?`min`:e===a[1]?`max`:(+e).toFixed(Math.min(i,20))}},t.prototype.resetExtent=function(){var e=this.option,t=BV([e.min,e.max]);this._dataExtent=t},t.prototype.getDimension=function(e){var t=this,n=this.option.seriesTargets;if(n){var r=Ee(n,function(n){return n.seriesIndex!=null&&n.seriesIndex===e||n.seriesId!=null&&n.seriesId===t.ecModel.getSeriesByIndex(e).id});if(r)return r.dimension}return this.option.dimension},t.prototype.getDataDimensionIndex=function(e){var t=e.hostModel.seriesIndex,n=this.getDimension(t);if(n!=null)return e.getDimensionIndex(n);for(var r=e.dimensions,i=r.length-1;i>=0;i--){var a=r[i],o=e.getDimensionInfo(a);if(!o.isCalculationCoord)return o.storeDimIndex}},t.prototype.getExtent=function(){return this._dataExtent.slice()},t.prototype.completeVisualOption=function(){var e=this.ecModel,t=this.option,n={inRange:t.inRange,outOfRange:t.outOfRange},r=t.target||={},i=t.controller||={};F(r,n),F(i,n);var a=this.isCategory();o.call(this,r),o.call(this,i),s.call(this,r,`inRange`,`outOfRange`),c.call(this,i);function o(n){RV(t.color)&&!n.inRange&&(n.inRange={color:t.color.slice().reverse()}),n.inRange=n.inRange||{color:e.get(`gradientColor`)}}function s(e,t,n){var r=e[t],i=e[n];r&&!i&&(i=e[n]={},zV(r,function(e,t){if(eI.isValidType(t)){var n=PV.get(t,`inactive`,a);n!=null&&(i[t]=n,t===`color`&&!i.hasOwnProperty(`opacity`)&&!i.hasOwnProperty(`colorAlpha`)&&(i.opacity=[0,0]))}}))}function c(e){var t=(e.inRange||{}).symbol||(e.outOfRange||{}).symbol,n=(e.inRange||{}).symbolSize||(e.outOfRange||{}).symbolSize,r=this.get(`inactiveColor`),i=this.getItemSymbol()||`roundRect`;zV(this.stateList,function(o){var s=this.itemSize,c=e[o];c||=e[o]={color:a?r:[r]},c.symbol??(c.symbol=t&&P(t)||(a?i:[i])),c.symbolSize??(c.symbolSize=n&&P(n)||(a?s[0]:[s[0],s[0]])),c.symbol=IV(c.symbol,function(e){return e===`none`?i:e});var l=c.symbolSize;if(l!=null){var u=-1/0;LV(l,function(e){e>u&&(u=e)}),c.symbolSize=IV(l,function(e){return VV(e,[0,u],[0,s[0]],!0)})}},this)}},t.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get(`itemWidth`)),parseFloat(this.get(`itemHeight`))]},t.prototype.isCategory=function(){return!!this.option.categories},t.prototype.setSelected=function(e){},t.prototype.getSelected=function(){return null},t.prototype.getValueState=function(e){return null},t.prototype.getVisualMeta=function(e){return null},t.type=`visualMap`,t.dependencies=[`series`],t.defaultOption={show:!0,z:4,min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:`vertical`,backgroundColor:Z.color.transparent,borderColor:Z.color.borderTint,contentColor:Z.color.theme[0],inactiveColor:Z.color.disabled,borderWidth:0,padding:Z.size.m,textGap:10,precision:0,textStyle:{color:Z.color.secondary}},t}(cv),UV=[20,140],WV=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.optionUpdated=function(t,n){e.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(e){e.mappingMethod=`linear`,e.dataExtent=this.getExtent()}),this._resetRange()},t.prototype.resetItemSize=function(){e.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(t[0]==null||isNaN(t[0]))&&(t[0]=UV[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=UV[1])},t.prototype._resetRange=function(){var e=this.getExtent(),t=this.option.range;!t||t.auto?(e.auto=1,this.option.range=e):U(t)&&(t[0]>t[1]&&t.reverse(),t[0]=Math.max(t[0],e[0]),t[1]=Math.min(t[1],e[1]))},t.prototype.completeVisualOption=function(){e.prototype.completeVisualOption.apply(this,arguments),z(this.stateList,function(e){var t=this.option.controller[e].symbolSize;t&&t[0]!==t[1]&&(t[0]=t[1]/3)},this)},t.prototype.setSelected=function(e){this.option.range=e.slice(),this._resetRange()},t.prototype.getSelected=function(){var e=this.getExtent(),t=pc((this.get(`range`)||[]).slice());return t[0]>e[1]&&(t[0]=e[1]),t[1]>e[1]&&(t[1]=e[1]),t[0]<e[0]&&(t[0]=e[0]),t[1]<e[0]&&(t[1]=e[0]),t},t.prototype.getValueState=function(e){var t=this.option.range,n=this.getExtent(),r=q(this.option.unboundedRange,!0);return(r&&t[0]<=n[0]||t[0]<=e)&&(r&&t[1]>=n[1]||e<=t[1])?`inRange`:`outOfRange`},t.prototype.findTargetDataIndices=function(e){var t=[];return this.eachTargetSeries(function(n){var r=[],i=n.getData();i.each(this.getDataDimensionIndex(i),function(t,n){e[0]<=t&&t<=e[1]&&r.push(n)},this),t.push({seriesId:n.id,dataIndex:r})},this),t},t.prototype.getVisualMeta=function(e){var t=GV(this,`outOfRange`,this.getExtent()),n=GV(this,`inRange`,this.option.range.slice()),r=[];function i(t,n){r.push({value:t,color:e(t,n)})}for(var a=0,o=0,s=n.length,c=t.length;o<c&&(!n.length||t[o]<=n[0]);o++)t[o]<n[a]&&i(t[o],`outOfRange`);for(var l=1;a<s;a++,l=0)l&&r.length&&i(n[a],`outOfRange`),i(n[a],`inRange`);for(var l=1;o<c;o++)(!n.length||n[n.length-1]<t[o])&&(l&&=(r.length&&i(r[r.length-1].value,`outOfRange`),0),i(t[o],`outOfRange`));var u=r.length;return{stops:r,outerColors:[u?r[0].color:`transparent`,u?r[u-1].color:`transparent`]}},t.type=`visualMap.continuous`,t.defaultOption=bg(HV.defaultOption,{align:`auto`,calculable:!1,hoverLink:!0,realtime:!0,handleIcon:`path://M-11.39,9.77h0a3.5,3.5,0,0,1-3.5,3.5h-22a3.5,3.5,0,0,1-3.5-3.5h0a3.5,3.5,0,0,1,3.5-3.5h22A3.5,3.5,0,0,1-11.39,9.77Z`,handleSize:`120%`,handleStyle:{borderColor:Z.color.neutral00,borderWidth:1},indicatorIcon:`circle`,indicatorSize:`50%`,indicatorStyle:{borderColor:Z.color.neutral00,borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:Z.color.shadow}}),t}(HV);function GV(e,t,n){if(n[0]===n[1])return n.slice();for(var r=200,i=(n[1]-n[0])/r,a=n[0],o=[],s=0;s<=r&&a<n[1];s++)o.push(a),a+=i;return o.push(n[1]),o}var KV=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.autoPositionValues={left:1,right:1,top:1,bottom:1},n}return t.prototype.init=function(e,t){this.ecModel=e,this.api=t},t.prototype.render=function(e,t,n,r){if(this.visualMapModel=e,e.get(`show`)===!1){this.group.removeAll();return}this.doRender(e,t,n,r)},t.prototype.renderBackground=function(e){var t=this.visualMapModel,n=L_(t.get(`padding`)||0),r=e.getBoundingRect();e.add(new Es({z2:-1,silent:!0,shape:{x:r.x-n[3],y:r.y-n[0],width:r.width+n[3]+n[1],height:r.height+n[0]+n[2]},style:{fill:t.get(`backgroundColor`),stroke:t.get(`borderColor`),lineWidth:t.get(`borderWidth`)}}))},t.prototype.getControllerVisual=function(e,t,n){n||={};var r=n.forceState,i=this.visualMapModel,a={};t===`color`&&(a.color=i.get(`contentColor`));function o(e){return a[e]}function s(e,t){a[e]=t}var c=i.controllerVisuals[r||i.getValueState(e)];return z(eI.prepareVisualTypes(c),function(r){var i=c[r];n.convertOpacityToAlpha&&r===`opacity`&&(r=`colorAlpha`,i=c.__alphaForOpacity),eI.dependsOn(r,t)&&i&&i.applyVisual(e,o,s)}),a[t]},t.prototype.positionGroup=function(e){var t=this.visualMapModel,n=this.api,r=tv(t,n).refContainer;nv(e,t.getBoxLayoutParams(),r)},t.prototype.doRender=function(e,t,n,r){},t.type=`visualMap`,t}(sO),qV=[[`left`,`right`,`width`],[`top`,`bottom`,`height`]];function JV(e,t,n){var r=e.option,i=r.align;if(i!=null&&i!==`auto`)return i;for(var a={width:t.getWidth(),height:t.getHeight()},o=+(r.orient===`horizontal`),s=qV[o],c=[0,null,10],l={},u=0;u<3;u++)l[qV[1-o][u]]=c[u],l[s[u]]=u===2?n[0]:r[s[u]];var d=[[`x`,`width`,3],[`y`,`height`,0]][o],f=Q_(l,a,r.padding);return s[(f.margin[d[2]]||0)+f[d[0]]+f[d[1]]*.5<a[d[1]]*.5?0:1]}function YV(e,t){return z(e||[],function(e){e.dataIndex!=null&&(e.dataIndexInside=e.dataIndex,e.dataIndex=null),e.highlightKey=`visualMap`+(t?t.componentIndex:``)}),e}var XV=ac,ZV=z,QV=Math.min,$V=Math.max,eH=12,tH=6,nH=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n._shapes={},n._dataInterval=[],n._handleEnds=[],n._hoverLinkDataIndices=[],n}return t.prototype.init=function(t,n){e.prototype.init.call(this,t,n),this._hoverLinkFromSeriesMouseOver=H(this._hoverLinkFromSeriesMouseOver,this),this._hideIndicator=H(this._hideIndicator,this)},t.prototype.doRender=function(e,t,n,r){(!r||r.type!==`selectDataRange`||r.from!==this.uid)&&this._buildView()},t.prototype._buildView=function(){this.group.removeAll();var e=this.visualMapModel,t=this.group;this._orient=e.get(`orient`),this._useHandle=e.get(`calculable`),this._resetInterval(),this._renderBar(t);var n=e.get(`text`);this._renderEndsText(t,n,0),this._renderEndsText(t,n,1),this._updateView(!0),this.renderBackground(t),this._updateView(),this._enableHoverLinkToSeries(),this._enableHoverLinkFromSeries(),this.positionGroup(t)},t.prototype._renderEndsText=function(e,t,n){if(t){var r=t[1-n];r=r==null?``:r+``;var i=this.visualMapModel,a=i.get(`textGap`),o=i.itemSize,s=this._shapes.mainGroup,c=this._applyTransform([o[0]/2,n===0?-a:o[1]+a],s),l=this._applyTransform(n===0?`bottom`:`top`,s),u=this._orient,d=this.visualMapModel.textStyleModel;this.group.add(new js({style:Gp(d,{x:c[0],y:c[1],verticalAlign:d.get(`verticalAlign`)||(u===`horizontal`?`middle`:l),align:d.get(`align`)||(u===`horizontal`?l:`center`),text:r})}))}},t.prototype._renderBar=function(e){var t=this.visualMapModel,n=this._shapes,r=t.itemSize,i=this._orient,a=this._useHandle,o=JV(t,this.api,r),s=n.mainGroup=this._createBarGroup(o),c=new Fd;s.add(c),c.add(n.outOfRange=rH()),c.add(n.inRange=rH(null,a?oH(this._orient):null,H(this._dragHandle,this,`all`,!1),H(this._dragHandle,this,`all`,!0))),c.setClipPath(new Es({shape:{x:0,y:0,width:r[0],height:r[1],r:3}}));var l=t.textStyleModel.getTextRect(`国`),u=$V(l.width,l.height);a&&(n.handleThumbs=[],n.handleLabels=[],n.handleLabelPoints=[],this._createHandle(t,s,0,r,u,i),this._createHandle(t,s,1,r,u,i)),this._createIndicator(t,s,r,u,i),e.add(s)},t.prototype._createHandle=function(e,t,n,r,i,a){var o=H(this._dragHandle,this,n,!1),s=H(this._dragHandle,this,n,!0),c=Zn(e.get(`handleSize`),r[0]),l=Ey(e.get(`handleIcon`),-c/2,-c/2,c,c,null,!0),u=oH(this._orient);l.attr({cursor:u,draggable:!0,drift:o,ondragend:s,onmousemove:function(e){YT(e.event)}}),l.x=r[0]/2,l.useStyle(e.getModel(`handleStyle`).getItemStyle()),l.setStyle({strokeNoScale:!0,strokeFirst:!0}),l.style.lineWidth*=2,l.ensureState(`emphasis`).style=e.getModel([`emphasis`,`handleStyle`]).getItemStyle(),od(l,!0),t.add(l);var d=this.visualMapModel.textStyleModel,f=new js({cursor:u,draggable:!0,drift:o,onmousemove:function(e){YT(e.event)},ondragend:s,style:Gp(d,{x:0,y:0,text:``})});f.ensureState(`blur`).style={opacity:.1},f.stateTransition={duration:200},this.group.add(f);var p=[c,0],m=this._shapes;m.handleThumbs[n]=l,m.handleLabelPoints[n]=p,m.handleLabels[n]=f},t.prototype._createIndicator=function(e,t,n,r,i){var a=Zn(e.get(`indicatorSize`),n[0]),o=Ey(e.get(`indicatorIcon`),-a/2,-a/2,a,a,null,!0);o.attr({cursor:`move`,invisible:!0,silent:!0,x:n[0]/2});var s=e.getModel(`indicatorStyle`).getItemStyle();if(o instanceof vs){var c=o.style;o.useStyle(I({image:c.image,x:c.x,y:c.y,width:c.width,height:c.height},s))}else o.useStyle(s);t.add(o);var l=this.visualMapModel.textStyleModel,u=new js({silent:!0,invisible:!0,style:Gp(l,{x:0,y:0,text:``})});this.group.add(u);var d=[(i===`horizontal`?r/2:tH)+n[0]/2,0],f=this._shapes;f.indicator=o,f.indicatorLabel=u,f.indicatorLabelPoint=d,this._firstShowIndicator=!0},t.prototype._dragHandle=function(e,t,n,r){if(this._useHandle){if(this._dragging=!t,!t){var i=this._applyTransform([n,r],this._shapes.mainGroup,!0);this._updateInterval(e,i[1]),this._hideIndicator(),this._updateView()}t===!this.visualMapModel.get(`realtime`)&&this.api.dispatchAction({type:`selectDataRange`,from:this.uid,visualMapId:this.visualMapModel.id,selected:this._dataInterval.slice()}),t?!this._hovering&&this._clearHoverLinkToSeries():aH(this.visualMapModel)&&this._doHoverLinkToSeries(this._handleEnds[e],!1)}},t.prototype._resetInterval=function(){var e=this.visualMapModel,t=this._dataInterval=e.getSelected(),n=e.getExtent(),r=[0,e.itemSize[1]];this._handleEnds=[XV(t[0],n,r,!0),XV(t[1],n,r,!0)]},t.prototype._updateInterval=function(e,t){t||=0;var n=this.visualMapModel,r=this._handleEnds,i=[0,n.itemSize[1]];jI(t,r,i,e,0);var a=n.getExtent();this._dataInterval=[XV(r[0],i,a,!0),XV(r[1],i,a,!0)]},t.prototype._updateView=function(e){var t=this.visualMapModel,n=t.getExtent(),r=this._shapes,i=[0,t.itemSize[1]],a=e?i:this._handleEnds,o=this._createBarVisual(this._dataInterval,n,a,`inRange`),s=this._createBarVisual(n,n,i,`outOfRange`);r.inRange.setStyle({fill:o.barColor}).setShape(`points`,o.barPoints),r.outOfRange.setStyle({fill:s.barColor}).setShape(`points`,s.barPoints),this._updateHandle(a,o)},t.prototype._createBarVisual=function(e,t,n,r){var i={forceState:r,convertOpacityToAlpha:!0},a=this._makeColorGradient(e,i),o=[this.getControllerVisual(e[0],`symbolSize`,i),this.getControllerVisual(e[1],`symbolSize`,i)],s=this._createBarPoints(n,o);return{barColor:new Cf(0,0,0,1,a),barPoints:s,handlesColor:[a[0].color,a[a.length-1].color]}},t.prototype._makeColorGradient=function(e,t){var n=100,r=[],i=(e[1]-e[0])/n;r.push({color:this.getControllerVisual(e[0],`color`,t),offset:0});for(var a=1;a<n;a++){var o=e[0]+i*a;if(o>e[1])break;r.push({color:this.getControllerVisual(o,`color`,t),offset:a/n})}return r.push({color:this.getControllerVisual(e[1],`color`,t),offset:1}),r},t.prototype._createBarPoints=function(e,t){var n=this.visualMapModel.itemSize;return[[n[0]-t[0],e[0]],[n[0],e[0]],[n[0],e[1]],[n[0]-t[1],e[1]]]},t.prototype._createBarGroup=function(e){var t=this._orient,n=this.visualMapModel.get(`inverse`);return new Fd(t===`horizontal`&&!n?{scaleX:e===`bottom`?1:-1,rotation:Math.PI/2}:t===`horizontal`&&n?{scaleX:e===`bottom`?-1:1,rotation:-Math.PI/2}:t===`vertical`&&!n?{scaleX:e===`left`?1:-1,scaleY:-1}:{scaleX:e===`left`?1:-1})},t.prototype._updateHandle=function(e,t){if(this._useHandle){var n=this._shapes,r=this.visualMapModel,i=n.handleThumbs,a=n.handleLabels,o=r.itemSize,s=r.getExtent(),c=this._applyTransform(`left`,n.mainGroup);ZV([0,1],function(l){var u=i[l];u.setStyle(`fill`,t.handlesColor[l]),u.y=e[l];var d=XV(e[l],[0,o[1]],s,!0),f=this.getControllerVisual(d,`symbolSize`);u.scaleX=u.scaleY=f/o[0],u.x=o[0]-f/2;var p=up(n.handleLabelPoints[l],lp(u,this.group));if(this._orient===`horizontal`){var m=c===`left`||c===`top`?(o[0]-f)/2:(o[0]-f)/-2;p[1]+=m}a[l].setStyle({x:p[0],y:p[1],text:r.formatValueText(this._dataInterval[l]),verticalAlign:`middle`,align:this._orient===`vertical`?this._applyTransform(`left`,n.mainGroup):`center`})},this)}},t.prototype._showIndicator=function(e,t,n,r){var i=this.visualMapModel,a=i.getExtent(),o=i.itemSize,s=[0,o[1]],c=this._shapes,l=c.indicator;if(l){l.attr(`invisible`,!1);var u=this.getControllerVisual(e,`color`,{convertOpacityToAlpha:!0}),d=this.getControllerVisual(e,`symbolSize`),f=XV(e,a,s,!0),p=o[0]-d/2,m={x:l.x,y:l.y};l.y=f,l.x=p;var h=up(c.indicatorLabelPoint,lp(l,this.group)),g=c.indicatorLabel;g.attr(`invisible`,!1);var _=this._applyTransform(`left`,c.mainGroup),v=this._orient===`horizontal`;g.setStyle({text:(n||``)+i.formatValueText(t),verticalAlign:v?_:`middle`,align:v?`center`:_});var y={x:p,y:f,style:{fill:u}},b={style:{x:h[0],y:h[1]}};if(i.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var x={duration:100,easing:`cubicInOut`,additive:!0};l.x=m.x,l.y=m.y,l.animateTo(y,x),g.animateTo(b,x)}else l.attr(y),g.attr(b);this._firstShowIndicator=!1;var S=this._shapes.handleLabels;if(S)for(var C=0;C<S.length;C++)this.api.enterBlur(S[C])}},t.prototype._enableHoverLinkToSeries=function(){var e=this;this._shapes.mainGroup.on(`mousemove`,function(t){if(e._hovering=!0,!e._dragging){var n=e.visualMapModel.itemSize,r=e._applyTransform([t.offsetX,t.offsetY],e._shapes.mainGroup,!0,!0);r[1]=QV($V(0,r[1]),n[1]),e._doHoverLinkToSeries(r[1],0<=r[0]&&r[0]<=n[0])}}).on(`mouseout`,function(){e._hovering=!1,!e._dragging&&e._clearHoverLinkToSeries()})},t.prototype._enableHoverLinkFromSeries=function(){var e=this.api.getZr();this.visualMapModel.option.hoverLink?(e.on(`mouseover`,this._hoverLinkFromSeriesMouseOver,this),e.on(`mouseout`,this._hideIndicator,this)):this._clearHoverLinkFromSeries()},t.prototype._doHoverLinkToSeries=function(e,t){var n=this.visualMapModel,r=n.itemSize;if(n.option.hoverLink){var i=[0,r[1]],a=n.getExtent();e=QV($V(i[0],e),i[1]);var o=iH(n,a,i),s=[e-o,e+o],c=XV(e,i,a,!0),l=[XV(s[0],i,a,!0),XV(s[1],i,a,!0)];s[0]<i[0]&&(l[0]=-1/0),s[1]>i[1]&&(l[1]=1/0),t&&(l[0]===-1/0?this._showIndicator(c,l[1],`< `,o):l[1]===1/0?this._showIndicator(c,l[0],`> `,o):this._showIndicator(c,c,`≈ `,o));var u=this._hoverLinkDataIndices,d=[];(t||aH(n))&&(d=this._hoverLinkDataIndices=n.findTargetDataIndices(l));var f=fl(u,d);this._dispatchHighDown(`downplay`,YV(f[0],n)),this._dispatchHighDown(`highlight`,YV(f[1],n))}},t.prototype._hoverLinkFromSeriesMouseOver=function(e){var t;if(KO(e.target,function(e){var n=Wl(e);if(n.dataIndex!=null)return t=n,!0},!0),t){var n=this.ecModel.getSeriesByIndex(t.seriesIndex),r=this.visualMapModel;if(r.isTargetSeries(n)){var i=n.getData(t.dataType),a=i.getStore().get(r.getDataDimensionIndex(i),t.dataIndex);isNaN(a)||this._showIndicator(a,a)}}},t.prototype._hideIndicator=function(){var e=this._shapes;e.indicator&&e.indicator.attr(`invisible`,!0),e.indicatorLabel&&e.indicatorLabel.attr(`invisible`,!0);var t=this._shapes.handleLabels;if(t)for(var n=0;n<t.length;n++)this.api.leaveBlur(t[n])},t.prototype._clearHoverLinkToSeries=function(){this._hideIndicator();var e=this._hoverLinkDataIndices;this._dispatchHighDown(`downplay`,YV(e,this.visualMapModel)),e.length=0},t.prototype._clearHoverLinkFromSeries=function(){this._hideIndicator();var e=this.api.getZr();e.off(`mouseover`,this._hoverLinkFromSeriesMouseOver),e.off(`mouseout`,this._hideIndicator)},t.prototype._applyTransform=function(e,t,n,r){var i=lp(t,r?null:this.group);return U(e)?up(e,i,n):dp(e,i,n)},t.prototype._dispatchHighDown=function(e,t){t&&t.length&&this.api.dispatchAction({type:e,batch:t})},t.prototype.dispose=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},t.type=`visualMap.continuous`,t}(KV);function rH(e,t,n,r){return new lf({shape:{points:e},draggable:!!n,cursor:t,drift:n,onmousemove:function(e){YT(e.event)},ondragend:r})}function iH(e,t,n){var r=eH/2,i=e.get(`hoverLinkDataSize`);return i&&(r=XV(i,t,n,!0)/2),r}function aH(e){return!!(e.get(`hoverLinkOnHandle`)??e.get(`realtime`))}function oH(e){return e===`vertical`?`ns-resize`:`ew-resize`}var sH={type:`selectDataRange`,event:`dataRangeSelected`,update:`update`},cH=function(e,t){t.eachComponent({mainType:`visualMap`,query:e},function(t){t.setSelected(e.selected)})},lH=[{createOnAllSeries:!0,reset:function(e,t){var n=[];return t.eachComponent(`visualMap`,function(t){var r=e.pipelineContext;!t.isTargetSeries(e)||r&&r.large||n.push(RB(t.stateList,t.targetVisuals,H(t.getValueState,t),t.getDataDimensionIndex(e.getData())))}),n}},{createOnAllSeries:!0,reset:function(e,t){var n=e.getData(),r=[];t.eachComponent(`visualMap`,function(t){if(t.isTargetSeries(e)){var i=t.getVisualMeta(H(uH,null,e,t))||{stops:[],outerColors:[]},a=t.getDataDimensionIndex(n);a>=0&&(i.dimension=a,r.push(i))}}),e.getData().setVisual(`visualMeta`,r)}}];function uH(e,t,n,r){for(var i=t.targetVisuals[r],a=eI.prepareVisualTypes(i),o={color:WO(e.getData(),`color`)},s=0,c=a.length;s<c;s++){var l=a[s],u=i[l===`opacity`?`__alphaForOpacity`:l];u&&u.applyVisual(n,d,f)}return o.color;function d(e){return o[e]}function f(e,t){o[e]=t}}var dH=z;function fH(e){var t=e&&e.visualMap;U(t)||(t=t?[t]:[]),dH(t,function(e){if(e){pH(e,`splitList`)&&!pH(e,`pieces`)&&(e.pieces=e.splitList,delete e.splitList);var t=e.pieces;t&&U(t)&&dH(t,function(e){K(e)&&(pH(e,`start`)&&!pH(e,`min`)&&(e.min=e.start),pH(e,`end`)&&!pH(e,`max`)&&(e.max=e.end))})}})}function pH(e,t){return e&&e.hasOwnProperty&&e.hasOwnProperty(t)}var mH=!1;function hH(e){mH||(mH=!0,e.registerSubTypeDefaulter(`visualMap`,function(e){return!e.categories&&(!(e.pieces?e.pieces.length>0:e.splitNumber>0)||e.calculable)?`continuous`:`piecewise`}),e.registerAction(sH,cH),z(lH,function(t){e.registerVisual(e.PRIORITY.VISUAL.COMPONENT,t)}),e.registerPreprocessor(fH))}function gH(e){e.registerComponentModel(WV),e.registerComponentView(nH),hH(e)}var _H=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n._pieceList=[],n}return t.prototype.optionUpdated=function(t,n){e.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var r=this._mode=this._determineMode();this._pieceList=[],vH[this._mode].call(this,this._pieceList),this._resetSelected(t,n);var i=this.option.categories;this.resetVisual(function(e,t){r===`categories`?(e.mappingMethod=`category`,e.categories=P(i)):(e.dataExtent=this.getExtent(),e.mappingMethod=`piecewise`,e.pieceList=B(this._pieceList,function(e){return e=P(e),t!==`inRange`&&(e.visual=null),e}))})},t.prototype.completeVisualOption=function(){var t=this.option,n={},r=eI.listVisualTypes(),i=this.isCategory();z(t.pieces,function(e){z(r,function(t){e.hasOwnProperty(t)&&(n[t]=1)})}),z(n,function(e,n){var r=!1;z(this.stateList,function(e){r=r||a(t,e,n)||a(t.target,e,n)},this),!r&&z(this.stateList,function(e){(t[e]||(t[e]={}))[n]=PV.get(n,e===`inRange`?`active`:`inactive`,i)})},this);function a(e,t,n){return e&&e[t]&&e[t].hasOwnProperty(n)}e.prototype.completeVisualOption.apply(this,arguments)},t.prototype._resetSelected=function(e,t){var n=this.option,r=this._pieceList,i=(t?n:e).selected||{};if(n.selected=i,z(r,function(e,t){var n=this.getSelectedMapKey(e);i.hasOwnProperty(n)||(i[n]=!0)},this),n.selectedMode===`single`){var a=!1;z(r,function(e,t){var n=this.getSelectedMapKey(e);i[n]&&(a?i[n]=!1:a=!0)},this)}},t.prototype.getItemSymbol=function(){return this.get(`itemSymbol`)},t.prototype.getSelectedMapKey=function(e){return this._mode===`categories`?e.value+``:e.index+``},t.prototype.getPieceList=function(){return this._pieceList},t.prototype._determineMode=function(){var e=this.option;return e.pieces&&e.pieces.length>0?`pieces`:this.option.categories?`categories`:`splitNumber`},t.prototype.setSelected=function(e){this.option.selected=P(e)},t.prototype.getValueState=function(e){var t=eI.findPieceIndex(e,this._pieceList);return t==null?`outOfRange`:this.option.selected[this.getSelectedMapKey(this._pieceList[t])]?`inRange`:`outOfRange`},t.prototype.findTargetDataIndices=function(e){var t=[],n=this._pieceList;return this.eachTargetSeries(function(r){var i=[],a=r.getData();a.each(this.getDataDimensionIndex(a),function(t,r){eI.findPieceIndex(t,n)===e&&i.push(r)},this),t.push({seriesId:r.id,dataIndex:i})},this),t},t.prototype.getRepresentValue=function(e){var t;if(this.isCategory())t=e.value;else if(e.value!=null)t=e.value;else{var n=e.interval||[];t=n[0]===-1/0&&n[1]===1/0?0:(n[0]+n[1])/2}return t},t.prototype.getVisualMeta=function(e){if(this.isCategory())return;var t=[],n=[``,``],r=this;function i(i,a){var o=r.getRepresentValue({interval:i});a||=r.getValueState(o);var s=e(o,a);i[0]===-1/0?n[0]=s:i[1]===1/0?n[1]=s:t.push({value:i[0],color:s},{value:i[1],color:s})}var a=this._pieceList.slice();if(!a.length)a.push({interval:[-1/0,1/0]});else{var o=a[0].interval[0];o!==-1/0&&a.unshift({interval:[-1/0,o]}),o=a[a.length-1].interval[1],o!==1/0&&a.push({interval:[o,1/0]})}var s=-1/0;return z(a,function(e){var t=e.interval;t&&(t[0]>s&&i([s,t[0]],`outOfRange`),i(t.slice()),s=t[1])},this),{stops:t,outerColors:n}},t.type=`visualMap.piecewise`,t.defaultOption=bg(HV.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:`auto`,itemWidth:20,itemHeight:14,itemSymbol:`roundRect`,pieces:null,categories:null,splitNumber:5,selectedMode:`multiple`,itemGap:10,hoverLink:!0}),t}(HV),vH={splitNumber:function(e){var t=this.option,n=Math.min(t.precision,20),r=this.getExtent(),i=t.splitNumber;i=Math.max(parseInt(i,10),1),t.splitNumber=i;for(var a=(r[1]-r[0])/i;+a.toFixed(n)!==a&&n<5;)n++;t.precision=n,a=+a.toFixed(n),t.minOpen&&e.push({interval:[-1/0,r[0]],close:[0,0]});for(var o=0,s=r[0];o<i;s+=a,o++){var c=o===i-1?r[1]:s+a;e.push({interval:[s,c],close:[1,1]})}t.maxOpen&&e.push({interval:[r[1],1/0],close:[0,0]}),Ac(e),z(e,function(e,t){e.index=t,e.text=this.formatValueText(e.interval)},this)},categories:function(e){var t=this.option;z(t.categories,function(t){e.push({text:this.formatValueText(t,!0),value:t})},this),yH(t,e)},pieces:function(e){var t=this.option;z(t.pieces,function(t,n){K(t)||(t={value:t});var r={text:``,index:n};if(t.label!=null&&(r.text=t.label),t.hasOwnProperty(`value`)){var i=r.value=t.value;r.interval=[i,i],r.close=[1,1]}else{for(var a=r.interval=[],o=r.close=[0,0],s=[1,0,1],c=[-1/0,1/0],l=[],u=0;u<2;u++){for(var d=[[`gte`,`gt`,`min`],[`lte`,`lt`,`max`]][u],f=0;f<3&&a[u]==null;f++)a[u]=t[d[f]],o[u]=s[f],l[u]=f===2;a[u]??(a[u]=c[u])}l[0]&&a[1]===1/0&&(o[0]=0),l[1]&&a[0]===-1/0&&(o[1]=0),a[0]===a[1]&&o[0]&&o[1]&&(r.value=a[0])}r.visual=eI.retrieveVisuals(t),e.push(r)},this),yH(t,e),Ac(e),z(e,function(e){var t=e.close,n=[[`<`,`≤`][t[1]],[`>`,`≥`][t[0]]];e.text=e.text||this.formatValueText(e.value==null?e.interval:e.value,!1,n)},this)}};function yH(e,t){var n=e.inverse;(e.orient===`vertical`?!n:n)&&t.reverse()}var bH=function(e){D(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.doRender=function(){var e=this.group;e.removeAll();var t=this.visualMapModel,n=t.get(`textGap`),r=t.textStyleModel,i=this._getItemAlign(),a=t.itemSize,o=this._getViewData(),s=o.endsText,c=Re(t.get(`showLabel`,!0),!s),l=!t.get(`selectedMode`);s&&this._renderEndsText(e,s[0],a,c,i),z(o.viewPieceList,function(o){var s=o.piece,u=new Fd;u.onclick=H(this._onItemClick,this,s),this._enableHoverLink(u,o.indexInModelPieceList);var d=t.getRepresentValue(s);if(this._createItemSymbol(u,d,[0,0,a[0],a[1]],l),c){var f=this.visualMapModel.getValueState(d),p=r.get(`align`)||i;u.add(new js({style:Gp(r,{x:p===`right`?-n:a[0]+n,y:a[1]/2,text:s.text,verticalAlign:r.get(`verticalAlign`)||`middle`,align:p,opacity:q(r.get(`opacity`),f===`outOfRange`?.5:1)}),silent:l}))}e.add(u)},this),s&&this._renderEndsText(e,s[1],a,c,i),X_(t.get(`orient`),e,t.get(`itemGap`)),this.renderBackground(e),this.positionGroup(e)},t.prototype._enableHoverLink=function(e,t){var n=this;e.on(`mouseover`,function(){return r(`highlight`)}).on(`mouseout`,function(){return r(`downplay`)});var r=function(e){var r=n.visualMapModel;r.option.hoverLink&&n.api.dispatchAction({type:e,batch:YV(r.findTargetDataIndices(t),r)})}},t.prototype._getItemAlign=function(){var e=this.visualMapModel,t=e.option;if(t.orient===`vertical`)return JV(e,this.api,e.itemSize);var n=t.align;return(!n||n===`auto`)&&(n=`left`),n},t.prototype._renderEndsText=function(e,t,n,r,i){if(t){var a=new Fd,o=this.visualMapModel.textStyleModel;a.add(new js({style:Gp(o,{x:r?i===`right`?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:`middle`,align:r?i:`center`,text:t})})),e.add(a)}},t.prototype._getViewData=function(){var e=this.visualMapModel,t=B(e.getPieceList(),function(e,t){return{piece:e,indexInModelPieceList:t}}),n=e.get(`text`),r=e.get(`orient`),i=e.get(`inverse`);return(r===`horizontal`?i:!i)?t.reverse():n&&=n.slice().reverse(),{viewPieceList:t,endsText:n}},t.prototype._createItemSymbol=function(e,t,n,r){var i=Ey(this.getControllerVisual(t,`symbol`),n[0],n[1],n[2],n[3],this.getControllerVisual(t,`color`));i.silent=r,e.add(i)},t.prototype._onItemClick=function(e){var t=this.visualMapModel,n=t.option,r=n.selectedMode;if(r){var i=P(n.selected),a=t.getSelectedMapKey(e);r===`single`||r===!0?(i[a]=!0,z(i,function(e,t){i[t]=t===a})):i[a]=!i[a],this.api.dispatchAction({type:`selectDataRange`,from:this.uid,visualMapId:this.visualMapModel.id,selected:i})}},t.type=`visualMap.piecewise`,t}(KV);function xH(e){e.registerComponentModel(_H),e.registerComponentView(bH),hH(e)}function SH(e){Vj(gH),Vj(xH)}var CH={label:{enabled:!0},decal:{show:!1}},wH=ml(),TH=ml(),EH=Ul(DH);function DH(e,t){var n=e.getModel(`aria`);if(!n.get(`enabled`))return;var r=TH(e).scope||(TH(e).scope={}),i=P(CH);F(i.label,e.getLocaleModel().get(`aria`),!1),F(n.option,i,!1),a(),o();function a(){if(n.getModel(`decal`).get(`show`)){var t=J();e.eachSeries(function(e){e.isColorBySeries()||(wH(e).scope=t.get(e.type)||t.set(e.type,{}))}),e.eachSeries(function(t){if(W(t.enableAriaDecal)){t.enableAriaDecal();return}var n=t.getData();if(t.isColorBySeries()){var i=pv(t.ecModel,t.name,r,e.getSeriesCount()),a=n.getVisual(`decal`);n.setVisual(`decal`,u(a,i))}else{var o=t.getRawData(),s={},c=wH(t).scope;n.each(function(e){var t=n.getRawIndex(e);s[t]=e});var l=o.count();o.each(function(e){var r=s[e],i=o.getName(e)||e+``,a=pv(t.ecModel,i,c,l),d=n.getItemVisual(r,`decal`);n.setItemVisual(r,`decal`,u(d,a))})}function u(e,t){var n=e?I(I({},t),e):t;return n.dirty=!0,n}})}}function o(){var r=t.getZr().dom;if(r){var i=e.getLocaleModel().get(`aria`),a=n.getModel(`label`);if(a.option=L(a.option,i),a.get(`enabled`)){if(r.setAttribute(`role`,`img`),a.get(`description`)){r.setAttribute(`aria-label`,a.get(`description`));return}var o=e.getSeriesCount(),u=a.get([`data`,`maxCount`])||10,d=a.get([`series`,`maxCount`])||10,f=Math.min(o,d),p;if(!(o<1)){var m=c();p=m?s(a.get([`general`,`withTitle`]),{title:m}):a.get([`general`,`withoutTitle`]);var h=[],g=o>1?a.get([`series`,`multiple`,`prefix`]):a.get([`series`,`single`,`prefix`]);p+=s(g,{seriesCount:o}),e.eachSeries(function(e,t){if(t<f){var n=void 0,r=e.get(`name`)?`withName`:`withoutName`;n=o>1?a.get([`series`,`multiple`,r]):a.get([`series`,`single`,r]),n=s(n,{seriesId:e.seriesIndex,seriesName:e.get(`name`),seriesType:l(e.subType)});var i=e.getData();if(i.count()>u){var c=a.get([`data`,`partialData`]);n+=s(c,{displayCnt:u})}else n+=a.get([`data`,`allData`]);for(var d=a.get([`data`,`separator`,`middle`]),p=a.get([`data`,`separator`,`end`]),m=a.get([`data`,`excludeDimensionId`]),g=[],_=0;_<i.count();_++)if(_<u){var v=i.getName(_),y=m?Te(i.getValues(_),function(e,t){return R(m,t)===-1}):i.getValues(_),b=a.get([`data`,v?`withName`:`withoutName`]);g.push(s(b,{name:v,value:y.join(d)}))}n+=g.join(d)+p,h.push(n)}});var _=a.getModel([`series`,`multiple`,`separator`]),v=_.get(`middle`),y=_.get(`end`);p+=h.join(v)+y,r.setAttribute(`aria-label`,p)}}}}function s(e,t){if(!G(e))return e;var n=e;return z(t,function(e,t){n=n.replace(RegExp(`\\{\\s*`+t+`\\s*\\}`,`g`),e)}),n}function c(){var t=e.get(`title`);return t&&t.length&&(t=t[0]),t&&t.text}function l(t){var n=e.getLocaleModel().get([`series`,`typeNames`]);return n[t]||n.chart}}function OH(e){if(e&&e.aria){var t=e.aria;t.show!=null&&(t.enabled=t.show),t.label=t.label||{},z([`description`,`general`,`series`,`data`],function(e){t[e]!=null&&(t.label[e]=t[e])})}}function kH(e){e.registerPreprocessor(OH),e.registerVisual(e.PRIORITY.VISUAL.ARIA,EH)}var AH=e({createDimensions:()=>Gh,createList:()=>jH,createScale:()=>NH,createSymbol:()=>Ey,createTextStyle:()=>FH,dataStack:()=>MH,enableHoverEmphasis:()=>$u,getECData:()=>Wl,getLayoutRect:()=>Q_,mixinAxisModelCommonMethods:()=>PH});function jH(e){return pg(null,e)}var MH={isDimensionStacked:lg,enableDataStack:sg,getStackedDimension:ug};function NH(e,t){var n=t;t instanceof pm||(n=new pm(t));var r=mx(n),i=hx(n,r,!1);return e[1]<e[0]&&(e=e.slice().reverse()),aM(i,n,null,null,e),i}function PH(e){Se(e,Hj)}function FH(e,t){return t||={},Gp(e,null,null,t.state!==`normal`)}var IH=e({MAX_SAFE_INTEGER:()=>xc,asc:()=>pc,getPercentWithPrecision:()=>vc,getPixelPrecision:()=>gc,getPrecision:()=>mc,getPrecisionSafe:()=>hc,isNumeric:()=>Mc,isRadianAroundZero:()=>Cc,linearMap:()=>ac,nice:()=>Oc,numericToNumber:()=>jc,parseDate:()=>Tc,parsePercent:()=>oc,quantile:()=>kc,quantity:()=>Ec,quantityExponent:()=>Dc,reformIntervals:()=>Ac,remRadian:()=>Sc,round:()=>fc}),LH=e({format:()=>g_,parse:()=>Tc,roundTime:()=>y_}),RH=e({Arc:()=>bf,BezierCurve:()=>vf,BoundingRect:()=>X,Circle:()=>Ld,CompoundPath:()=>xf,Ellipse:()=>zd,Group:()=>Fd,Image:()=>vs,IncrementalDisplayable:()=>Ff,Line:()=>mf,LinearGradient:()=>Cf,Polygon:()=>lf,Polyline:()=>df,RadialGradient:()=>wf,Rect:()=>Es,Ring:()=>af,Sector:()=>nf,Text:()=>js,clipPointsByRect:()=>hp,clipRectByRect:()=>gp,createIcon:()=>_p,extendPath:()=>Qf,extendShape:()=>Xf,getShapeClass:()=>ep,getTransform:()=>lp,initProps:()=>Bf,makeImage:()=>np,makePath:()=>tp,mergePath:()=>ip,registerShape:()=>$f,resizePath:()=>ap,updateProps:()=>zf}),zH=e({addCommas:()=>F_,capitalFirst:()=>W_,encodeHTML:()=>Pg,formatTime:()=>U_,formatTpl:()=>V_,getTextRect:()=>P_,getTooltipMarker:()=>H_,normalizeCssArray:()=>L_,toCamelCase:()=>I_,truncateText:()=>er}),BH=e({bind:()=>H,clone:()=>P,curry:()=>Oe,defaults:()=>L,each:()=>z,extend:()=>I,filter:()=>Te,indexOf:()=>R,inherits:()=>xe,isArray:()=>U,isFunction:()=>W,isObject:()=>K,isString:()=>G,map:()=>B,merge:()=>F,reduce:()=>we});function VH(e){var t=cv.extend(e);return cv.registerClass(t),t}function HH(e){var t=sO.extend(e);return sO.registerClass(t),t}function UH(e){var t=dy.extend(e);return dy.registerClass(t),t}function WH(e){var t=ab.extend(e);return ab.registerClass(t),t}var GH=e({Axis:()=>QS,ChartView:()=>ab,ComponentModel:()=>cv,ComponentView:()=>sO,List:()=>Wh,Model:()=>pm,PRIORITY:()=>hA,SeriesModel:()=>dy,color:()=>li,connect:()=>fj,dataTool:()=>Rj,dependencies:()=>Zk,disConnect:()=>mj,disconnect:()=>pj,dispose:()=>hj,env:()=>Y,extendChartView:()=>WH,extendComponentModel:()=>VH,extendComponentView:()=>HH,extendSeriesModel:()=>UH,format:()=>zH,getCoordinateSystemDimensions:()=>Ej,getInstanceByDom:()=>gj,getInstanceById:()=>_j,getMap:()=>Fj,graphic:()=>RH,helper:()=>AH,init:()=>dj,innerDrawElementOnCanvas:()=>Fk,matrix:()=>jt,number:()=>IH,parseGeoJSON:()=>nP,parseGeoJson:()=>nP,registerAction:()=>wj,registerCoordinateSystem:()=>Tj,registerCustomSeries:()=>Dj,registerLayout:()=>Oj,registerLoading:()=>Mj,registerLocale:()=>Ug,registerMap:()=>Pj,registerPostInit:()=>xj,registerPostUpdate:()=>Sj,registerPreprocessor:()=>yj,registerProcessor:()=>bj,registerTheme:()=>vj,registerTransform:()=>Ij,registerUpdateLifecycle:()=>Cj,registerVisual:()=>kj,setCanvasCreator:()=>Nj,setPlatformAPI:()=>ne,throttle:()=>Zw,time:()=>LH,use:()=>Vj,util:()=>BH,vector:()=>Vt,version:()=>Xk,zrUtil:()=>re,zrender:()=>JE}),KH=Math.sin,qH=Math.cos,JH=Math.PI,YH=Math.PI*2,XH=180/JH,ZH=function(){function e(){}return e.prototype.reset=function(e){this._start=!0,this._d=[],this._str=``,this._p=10**(e||4)},e.prototype.moveTo=function(e,t){this._add(`M`,e,t)},e.prototype.lineTo=function(e,t){this._add(`L`,e,t)},e.prototype.bezierCurveTo=function(e,t,n,r,i,a){this._add(`C`,e,t,n,r,i,a)},e.prototype.quadraticCurveTo=function(e,t,n,r){this._add(`Q`,e,t,n,r)},e.prototype.arc=function(e,t,n,r,i,a){this.ellipse(e,t,n,n,0,r,i,a)},e.prototype.ellipse=function(e,t,n,r,i,a,o,s){var c=o-a,l=!s,u=Math.abs(c),d=Hi(u-YH)||(l?c>=YH:-c>=YH),f=c>0?c%YH:c%YH+YH,p=!1;p=d?!0:!Hi(u)&&f>=JH==!!l;var m=e+n*qH(a),h=t+r*KH(a);this._start&&this._add(`M`,m,h);var g=Math.round(i*XH);if(d){var _=1/this._p,v=(l?1:-1)*(YH-_);this._add(`A`,n,r,g,1,+l,e+n*qH(a+v),t+r*KH(a+v)),_>.01&&this._add(`A`,n,r,g,0,+l,m,h)}else{var y=e+n*qH(o),b=t+r*KH(o);this._add(`A`,n,r,g,+p,+l,y,b)}},e.prototype.rect=function(e,t,n,r){this._add(`M`,e,t),this._add(`l`,n,0),this._add(`l`,0,r),this._add(`l`,-n,0),this._add(`Z`)},e.prototype.closePath=function(){this._d.length>0&&this._add(`Z`)},e.prototype._add=function(e,t,n,r,i,a,o,s,c){for(var l=[],u=this._p,d=1;d<arguments.length;d++){var f=arguments[d];if(isNaN(f)){this._invalid=!0;return}l.push(Math.round(f*u)/u)}this._d.push(e+l.join(` `)),this._start=e===`Z`},e.prototype.generateStr=function(){this._str=this._invalid?``:this._d.join(``),this._d=[]},e.prototype.getStr=function(){return this._str},e}(),QH=`none`,$H=Math.round;function eU(e){var t=e.fill;return t!=null&&t!==QH}function tU(e){var t=e.stroke;return t!=null&&t!==QH}var nU=[`lineCap`,`miterLimit`,`lineJoin`],rU=B(nU,function(e){return`stroke-`+e.toLowerCase()});function iU(e,t,n,r){var i=t.opacity==null?1:t.opacity;if(n instanceof vs){e(`opacity`,i);return}if(eU(t)){var a=Bi(t.fill);e(`fill`,a.color);var o=t.fillOpacity==null?a.opacity*i:t.fillOpacity*a.opacity*i;(r||o<1)&&e(`fill-opacity`,o)}else e(`fill`,QH);if(tU(t)){var s=Bi(t.stroke);e(`stroke`,s.color);var c=t.strokeNoScale?n.getLineScale():1,l=c?(t.lineWidth||0)/c:0,u=t.strokeOpacity==null?s.opacity*i:t.strokeOpacity*s.opacity*i,d=t.strokeFirst;if((r||l!==1)&&e(`stroke-width`,l),(r||d)&&e(`paint-order`,d?`stroke`:`fill`),(r||u<1)&&e(`stroke-opacity`,u),t.lineDash){var f=uk(n),p=f[0],m=f[1];p&&(m=$H(m||0),e(`stroke-dasharray`,p.join(`,`)),(m||r)&&e(`stroke-dashoffset`,m))}else r&&e(`stroke-dasharray`,QH);for(var h=0;h<nU.length;h++){var g=nU[h];if(r||t[g]!==ls[g]){var _=t[g]||ls[g];_&&e(rU[h],_)}}}else r&&e(`stroke`,QH)}var aU=`http://www.w3.org/2000/svg`,oU=`http://www.w3.org/1999/xlink`,sU=`http://www.w3.org/2000/xmlns/`,cU=`http://www.w3.org/XML/1998/namespace`,lU=`ecmeta_`;function uU(e){return document.createElementNS(aU,e)}function dU(e,t,n,r,i){return{tag:e,attrs:n||{},children:r,text:i,key:t}}function fU(e,t){var n=[];if(t)for(var r in t){var i=t[r],a=r;i!==!1&&(i!==!0&&i!=null&&(a+=`="`+i+`"`),n.push(a))}return`<`+e+` `+n.join(` `)+`>`}function pU(e){return`</`+e+`>`}function mU(e,t){t||={};var n=t.newline?`
37
37
  `:``;function r(e){var t=e.children,i=e.tag,a=e.attrs,o=e.text;return fU(i,a)+(i===`style`?o||``:Pg(o))+(t?``+n+B(t,function(e){return r(e)}).join(n)+n:``)+pU(i)}return r(e)}function hU(e,t,n){n||={};var r=n.newline?`
38
38
  `:``,i=` {`+r,a=r+`}`,o=B(V(e),function(t){return t+i+B(V(e[t]),function(n){return n+`:`+e[t][n]+`;`}).join(r)+a}).join(r),s=B(V(t),function(e){return`@keyframes `+e+i+B(V(t[e]),function(n){return n+i+B(V(t[e][n]),function(r){var i=t[e][n][r];return r===`d`&&(i=`path("`+i+`")`),r+`:`+i+`;`}).join(r)+a}).join(r)+a}).join(r);return!o&&!s?``:[`<![CDATA[`,o,s,`]]>`].join(r)}function gU(e){return{zrId:e,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssStyleCache:{},cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function _U(e,t,n,r){return dU(`svg`,`root`,{width:e,height:t,xmlns:aU,"xmlns:xlink":oU,version:`1.1`,baseProfile:`full`,viewBox:r?`0 0 `+e+` `+t:!1},n)}var vU=0;function yU(){return vU++}var bU={cubicIn:`0.32,0,0.67,0`,cubicOut:`0.33,1,0.68,1`,cubicInOut:`0.65,0,0.35,1`,quadraticIn:`0.11,0,0.5,0`,quadraticOut:`0.5,1,0.89,1`,quadraticInOut:`0.45,0,0.55,1`,quarticIn:`0.5,0,0.75,0`,quarticOut:`0.25,1,0.5,1`,quarticInOut:`0.76,0,0.24,1`,quinticIn:`0.64,0,0.78,0`,quinticOut:`0.22,1,0.36,1`,quinticInOut:`0.83,0,0.17,1`,sinusoidalIn:`0.12,0,0.39,0`,sinusoidalOut:`0.61,1,0.88,1`,sinusoidalInOut:`0.37,0,0.63,1`,exponentialIn:`0.7,0,0.84,0`,exponentialOut:`0.16,1,0.3,1`,exponentialInOut:`0.87,0,0.13,1`,circularIn:`0.55,0,1,0.45`,circularOut:`0,0.55,0.45,1`,circularInOut:`0.85,0,0.15,1`},xU=`transform-origin`;function SU(e,t,n){var r=I({},e.shape);I(r,t),e.buildPath(n,r);var i=new ZH;return i.reset(ra(e)),n.rebuildPath(i,1),i.generateStr(),i.getStr()}function CU(e,t){var n=t.originX,r=t.originY;(n||r)&&(e[xU]=n+`px `+r+`px`)}var wU={fill:`fill`,opacity:`opacity`,lineWidth:`stroke-width`,lineDashOffset:`stroke-dashoffset`};function TU(e,t){var n=t.zrId+`-ani-`+t.cssAnimIdx++;return t.cssAnims[n]=e,n}function EU(e,t,n){var r=e.shape.paths,i={},a,o;if(z(r,function(e){var t=gU(n.zrId);t.animation=!0,OU(e,{},t,!0);var r=t.cssAnims,s=t.cssNodes,c=V(r),l=c.length;if(l){o=c[l-1];var u=r[o];for(var d in u){var f=u[d];i[d]=i[d]||{d:``},i[d].d+=f.d||``}for(var p in s){var m=s[p].animation;m.indexOf(o)>=0&&(a=m)}}}),a){t.d=!1;var s=TU(i,n);return a.replace(o,s)}}function DU(e){return G(e)?bU[e]?`cubic-bezier(`+bU[e]+`)`:si(e)?e:``:``}function OU(e,t,n,r){var i=e.animators,a=i.length,o=[];if(e instanceof xf){var s=EU(e,t,n);if(s)o.push(s);else if(!a)return}else if(!a)return;for(var c={},l=0;l<a;l++){var u=i[l],d=[u.getMaxTime()/1e3+`s`],f=DU(u.getClip().easing),p=u.getDelay();f?d.push(f):d.push(`linear`),p&&d.push(p/1e3+`s`),u.getLoop()&&d.push(`infinite`);var m=d.join(` `);c[m]=c[m]||[m,[]],c[m][1].push(u)}function h(i){var a=i[1],o=a.length,s={},c={},l={},u=`animation-timing-function`;function d(e,t,n){for(var r=e.getTracks(),i=e.getMaxTime(),a=0;a<r.length;a++){var o=r[a];if(o.needsAnimate()){var s=o.keyframes,c=o.propName;if(n&&(c=n(c)),c)for(var l=0;l<s.length;l++){var d=s[l],f=Math.round(d.time/i*100)+`%`,p=DU(d.easing),m=d.rawValue;(G(m)||Ae(m))&&(t[f]=t[f]||{},t[f][c]=d.rawValue,p&&(t[f][u]=p))}}}}for(var f=0;f<o;f++){var p=a[f],m=p.targetName;m?m===`shape`&&d(p,c):!r&&d(p,s)}for(var h in s){var g={};Nr(g,e),I(g,s[h]);var _=ia(g),v=s[h][u];l[h]=_?{transform:_}:{},CU(l[h],g),v&&(l[h][u]=v)}var y,b=!0;for(var h in c){l[h]=l[h]||{};var x=!y,v=c[h][u];x&&(y=new Vo);var S=y.len();y.reset(),l[h].d=SU(e,c[h],y);var C=y.len();if(!x&&S!==C){b=!1;break}v&&(l[h][u]=v)}if(!b)for(var h in l)delete l[h].d;if(!r)for(var f=0;f<o;f++){var p=a[f],m=p.targetName;m===`style`&&d(p,l,function(e){return wU[e]})}for(var w=V(l),T=!0,E,f=1;f<w.length;f++){var D=w[f-1],O=w[f];if(l[D][xU]!==l[O][xU]){T=!1;break}E=l[D][xU]}if(T&&E){for(var h in l)l[h][xU]&&delete l[h][xU];t[xU]=E}if(Te(w,function(e){return V(l[e]).length>0}).length)return TU(l,n)+` `+i[0]+` both`}for(var g in c){var s=h(c[g]);s&&o.push(s)}if(o.length){var _=n.zrId+`-cls-`+yU();n.cssNodes[`.`+_]={animation:o.join(`,`)},t.class=_}}function kU(e,t,n){if(!e.ignore){if(e.isSilent()){var r={"pointer-events":`none`};AU(r,t,n,!0)}else{var i=e.states.emphasis&&e.states.emphasis.style?e.states.emphasis.style:{},a=i.fill;if(!a){var o=e.style&&e.style.fill,s=e.states.select&&e.states.select.style&&e.states.select.style.fill,c=e.currentStates.indexOf(`select`)>=0&&s||o;c&&(a=Ri(c))}var l=i.lineWidth;if(l){var u=!i.strokeNoScale&&e.transform?e.transform[0]:1;l/=u}var r={cursor:`pointer`};a&&(r.fill=a),i.stroke&&(r.stroke=i.stroke),l&&(r[`stroke-width`]=l),AU(r,t,n,!0)}}}function AU(e,t,n,r){var i=JSON.stringify(e),a=n.cssStyleCache[i];a||(a=n.zrId+`-cls-`+yU(),n.cssStyleCache[i]=a,n.cssNodes[`.`+a+(r?`:hover`:``)]=e),t.class=t.class?t.class+` `+a:a}var jU=Math.round;function MU(e){return e&&G(e.src)}function NU(e){return e&&W(e.toDataURL)}function PU(e,t,n,r){iU(function(i,a){var o=i===`fill`||i===`stroke`;o&&ta(a)?YU(t,e,i,r):o&&Qi(a)?XU(n,e,i,r):e[i]=a,o&&r.ssr&&a===`none`&&(e[`pointer-events`]=`visible`)},t,n,!1),JU(n,e,r)}function FU(e,t){var n=oD(t);n&&(n.each(function(t,n){t!=null&&(e[(`ecmeta_`+n).toLowerCase()]=t+``)}),t.isSilent()&&(e[lU+`silent`]=`true`))}function IU(e){return Hi(e[0]-1)&&Hi(e[1])&&Hi(e[2])&&Hi(e[3]-1)}function LU(e){return Hi(e[4])&&Hi(e[5])}function RU(e,t,n){if(t&&!(LU(t)&&IU(t))){var r=n?10:1e4;e.transform=IU(t)?`translate(`+jU(t[4]*r)/r+` `+jU(t[5]*r)/r+`)`:Gi(t)}}function zU(e,t,n){for(var r=e.points,i=[],a=0;a<r.length;a++)i.push(jU(r[a][0]*n)/n),i.push(jU(r[a][1]*n)/n);t.points=i.join(` `)}function BU(e){return!e.smooth}function VU(e){var t=B(e,function(e){return typeof e==`string`?[e,e]:e});return function(e,n,r){for(var i=0;i<t.length;i++){var a=t[i],o=e[a[0]];o!=null&&(n[a[1]]=jU(o*r)/r)}}}var HU={circle:[VU([`cx`,`cy`,`r`])],polyline:[zU,BU],polygon:[zU,BU]};function UU(e){for(var t=e.animators,n=0;n<t.length;n++)if(t[n].targetName===`shape`)return!0;return!1}function WU(e,t){var n=e.style,r=e.shape,i=HU[e.type],a={},o=t.animation,s=`path`,c=e.style.strokePercent,l=t.compress&&ra(e)||4;if(i&&!t.willUpdate&&(!i[1]||i[1](r))&&!(o&&UU(e))&&!(c<1)){s=e.type;var u=10**l;i[0](r,a,u)}else{var d=!e.path||e.shapeChanged();e.path||e.createPathProxy();var f=e.path;d&&(f.beginPath(),e.buildPath(f,e.shape),e.pathUpdated());var p=f.getVersion(),m=e,h=m.__svgPathBuilder;(m.__svgPathVersion!==p||!h||c!==m.__svgPathStrokePercent)&&(h||=m.__svgPathBuilder=new ZH,h.reset(l),f.rebuildPath(h,c),h.generateStr(),m.__svgPathVersion=p,m.__svgPathStrokePercent=c),a.d=h.getStr()}return RU(a,e.transform),PU(a,n,e,t),FU(a,e),t.animation&&OU(e,a,t),t.emphasis&&kU(e,a,t),dU(s,e.id+``,a)}function GU(e,t){var n=e.style,r=n.image;if(r&&!G(r)&&(MU(r)?r=r.src:NU(r)&&(r=r.toDataURL())),r){var i=n.x||0,a=n.y||0,o=n.width,s=n.height,c={href:r,width:o,height:s};return i&&(c.x=i),a&&(c.y=a),RU(c,e.transform),PU(c,n,e,t),FU(c,e),t.animation&&OU(e,c,t),dU(`image`,e.id+``,c)}}function KU(e,t){var n=e.style,r=n.text;if(r!=null&&(r+=``),!(!r||isNaN(n.x)||isNaN(n.y))){var i=n.font||`12px sans-serif`,a=n.x||0,o=qi(n.y||0,Xn(i),n.textBaseline),s={"dominant-baseline":`central`,"text-anchor":Ki[n.textAlign]||n.textAlign};if(Ls(n)){var c=``,l=n.fontStyle,u=Fs(n.fontSize);if(!parseFloat(u))return;var d=n.fontFamily||`sans-serif`,f=n.fontWeight;c+=`font-size:`+u+`;font-family:`+d+`;`,l&&l!==`normal`&&(c+=`font-style:`+l+`;`),f&&f!==`normal`&&(c+=`font-weight:`+f+`;`),s.style=c}else s.style=`font: `+i;return r.match(/\s/)&&(s[`xml:space`]=`preserve`),a&&(s.x=a),o&&(s.y=o),RU(s,e.transform),PU(s,n,e,t),FU(s,e),t.animation&&OU(e,s,t),dU(`text`,e.id+``,s,void 0,r)}}function qU(e,t){if(e instanceof fs)return WU(e,t);if(e instanceof vs)return GU(e,t);if(e instanceof ms)return KU(e,t)}function JU(e,t,n){var r=e.style;if(Ji(r)){var i=Yi(e),a=n.shadowCache,o=a[i];if(!o){var s=e.getGlobalScale(),c=s[0],l=s[1];if(!c||!l)return;var u=r.shadowOffsetX||0,d=r.shadowOffsetY||0,f=r.shadowBlur,p=Bi(r.shadowColor),m=p.opacity,h=p.color,g=f/2/c,_=f/2/l,v=g+` `+_;o=n.zrId+`-s`+n.shadowIdx++,n.defs[o]=dU(`filter`,o,{id:o,x:`-100%`,y:`-100%`,width:`300%`,height:`300%`},[dU(`feDropShadow`,``,{dx:u/c,dy:d/l,stdDeviation:v,"flood-color":h,"flood-opacity":m})]),a[i]=o}t.filter=na(o)}}function YU(e,t,n,r){var i=e[n],a,o={gradientUnits:i.global?`userSpaceOnUse`:`objectBoundingBox`};if($i(i))a=`linearGradient`,o.x1=i.x,o.y1=i.y,o.x2=i.x2,o.y2=i.y2;else if(ea(i))a=`radialGradient`,o.cx=q(i.x,.5),o.cy=q(i.y,.5),o.r=q(i.r,.5);else return;for(var s=i.colorStops,c=[],l=0,u=s.length;l<u;++l){var d=Wi(s[l].offset)*100+`%`,f=s[l].color,p=Bi(f),m=p.color,h=p.opacity,g={offset:d};g[`stop-color`]=m,h<1&&(g[`stop-opacity`]=h),c.push(dU(`stop`,l+``,g))}var _=mU(dU(a,``,o,c)),v=r.gradientCache,y=v[_];y||(y=r.zrId+`-g`+r.gradientIdx++,v[_]=y,o.id=y,r.defs[y]=dU(a,y,o,c)),t[n]=na(y)}function XU(e,t,n,r){var i=e.style[n],a=e.getBoundingRect(),o={},s=i.repeat,c=s===`no-repeat`,l=s===`repeat-x`,u=s===`repeat-y`,d;if(Xi(i)){var f=i.imageWidth,p=i.imageHeight,m=void 0,h=i.image;if(G(h)?m=h:MU(h)?m=h.src:NU(h)&&(m=h.toDataURL()),typeof Image>`u`){var g=`Image width/height must been given explictly in svg-ssr renderer.`;He(f,g),He(p,g)}else if(f==null||p==null){var _=function(e,t){if(e){var n=e.elm,r=f||t.width,i=p||t.height;e.tag===`pattern`&&(l?(i=1,r/=a.width):u&&(r=1,i/=a.height)),e.attrs.width=r,e.attrs.height=i,n&&(n.setAttribute(`width`,r),n.setAttribute(`height`,i))}},v=Ot(m,null,e,function(e){c||_(S,e),_(d,e)});v&&v.width&&v.height&&(f||=v.width,p||=v.height)}d=dU(`image`,`img`,{href:m,width:f,height:p}),o.width=f,o.height=p}else i.svgElement&&(d=P(i.svgElement),o.width=i.svgWidth,o.height=i.svgHeight);if(d){var y,b;c?y=b=1:l?(b=1,y=o.width/a.width):u?(y=1,b=o.height/a.height):o.patternUnits=`userSpaceOnUse`,y!=null&&!isNaN(y)&&(o.width=y),b!=null&&!isNaN(b)&&(o.height=b);var x=ia(i);x&&(o.patternTransform=x);var S=dU(`pattern`,``,o,[d]),C=mU(S),w=r.patternCache,T=w[C];T||(T=r.zrId+`-p`+r.patternIdx++,w[C]=T,o.id=T,S=r.defs[T]=dU(`pattern`,T,o,[d])),t[n]=na(T)}}function ZU(e,t,n){var r=n.clipPathCache,i=n.defs,a=r[e.id];if(!a){a=n.zrId+`-c`+n.clipPathIdx++;var o={id:a};r[e.id]=a,i[a]=dU(`clipPath`,a,o,[WU(e,n)])}t[`clip-path`]=na(a)}function QU(e){return document.createTextNode(e)}function $U(e,t,n){e.insertBefore(t,n)}function eW(e,t){e.removeChild(t)}function tW(e,t){e.appendChild(t)}function nW(e){return e.parentNode}function rW(e){return e.nextSibling}function iW(e,t){e.textContent=t}var aW=58,oW=120,sW=dU(``,``);function cW(e){return e===void 0}function lW(e){return e!==void 0}function uW(e,t,n){for(var r={},i=t;i<=n;++i){var a=e[i].key;a!==void 0&&(r[a]=i)}return r}function dW(e,t){var n=e.key===t.key;return e.tag===t.tag&&n}function fW(e){var t,n=e.children,r=e.tag;if(lW(r)){var i=e.elm=uU(r);if(hW(sW,e),U(n))for(t=0;t<n.length;++t){var a=n[t];a!=null&&tW(i,fW(a))}else lW(e.text)&&!K(e.text)&&tW(i,QU(e.text))}else e.elm=QU(e.text);return e.elm}function pW(e,t,n,r,i){for(;r<=i;++r){var a=n[r];a!=null&&$U(e,fW(a),t)}}function mW(e,t,n,r){for(;n<=r;++n){var i=t[n];i!=null&&(lW(i.tag)?eW(nW(i.elm),i.elm):eW(e,i.elm))}}function hW(e,t){var n,r=t.elm,i=e&&e.attrs||{},a=t.attrs||{};if(i!==a){for(n in a){var o=a[n];i[n]!==o&&(o===!0?r.setAttribute(n,``):o===!1?r.removeAttribute(n):n===`style`?r.style.cssText=o:n.charCodeAt(0)===oW?n===`xmlns:xlink`||n===`xmlns`?r.setAttributeNS(sU,n,o):n.charCodeAt(3)===aW?r.setAttributeNS(cU,n,o):n.charCodeAt(5)===aW?r.setAttributeNS(oU,n,o):r.setAttribute(n,o):r.setAttribute(n,o))}for(n in i)n in a||r.removeAttribute(n)}}function gW(e,t,n){for(var r=0,i=0,a=t.length-1,o=t[0],s=t[a],c=n.length-1,l=n[0],u=n[c],d,f,p,m;r<=a&&i<=c;)o==null?o=t[++r]:s==null?s=t[--a]:l==null?l=n[++i]:u==null?u=n[--c]:dW(o,l)?(_W(o,l),o=t[++r],l=n[++i]):dW(s,u)?(_W(s,u),s=t[--a],u=n[--c]):dW(o,u)?(_W(o,u),$U(e,o.elm,rW(s.elm)),o=t[++r],u=n[--c]):dW(s,l)?(_W(s,l),$U(e,s.elm,o.elm),s=t[--a],l=n[++i]):(cW(d)&&(d=uW(t,r,a)),f=d[l.key],cW(f)?$U(e,fW(l),o.elm):(p=t[f],p.tag===l.tag?(_W(p,l),t[f]=void 0,$U(e,p.elm,o.elm)):$U(e,fW(l),o.elm)),l=n[++i]);(r<=a||i<=c)&&(r>a?(m=n[c+1]==null?null:n[c+1].elm,pW(e,m,n,i,c)):mW(e,t,r,a))}function _W(e,t){var n=t.elm=e.elm,r=e.children,i=t.children;e!==t&&(hW(e,t),cW(t.text)?lW(r)&&lW(i)?r!==i&&gW(n,r,i):lW(i)?(lW(e.text)&&iW(n,``),pW(n,null,i,0,i.length-1)):lW(r)?mW(n,r,0,r.length-1):lW(e.text)&&iW(n,``):e.text!==t.text&&(lW(r)&&mW(n,r,0,r.length-1),iW(n,t.text)))}function vW(e,t){if(dW(e,t))_W(e,t);else{var n=e.elm,r=nW(n);fW(t),r!==null&&($U(r,t.elm,rW(n)),mW(r,[e],0,0))}return t}var yW=0,bW=function(){function e(e,t,n){if(this.type=`svg`,this.configLayer=xW(`configLayer`),this.storage=t,this._opts=n=I({},n),this.root=e,this._id=`zr`+yW++,this._oldVNode=_U(n.width,n.height),e&&!n.ssr){var r=this._viewport=document.createElement(`div`);r.style.cssText=`position:relative;overflow:hidden`;var i=this._svgDom=this._oldVNode.elm=uU(`svg`);hW(null,this._oldVNode),r.appendChild(i),e.appendChild(r)}this.resize(n.width,n.height)}return e.prototype.getType=function(){return this.type},e.prototype.getViewportRoot=function(){return this._viewport},e.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},e.prototype.getSvgDom=function(){return this._svgDom},e.prototype.refresh=function(){if(this.root){var e=this.renderToVNode({willUpdate:!0});e.attrs.style=`position:absolute;left:0;top:0;user-select:none`,vW(this._oldVNode,e),this._oldVNode=e}},e.prototype.renderOneToVNode=function(e){return qU(e,gU(this._id))},e.prototype.renderToVNode=function(e){e||={};var t=this.storage.getDisplayList(!0),n=this._width,r=this._height,i=gU(this._id);i.animation=e.animation,i.willUpdate=e.willUpdate,i.compress=e.compress,i.emphasis=e.emphasis,i.ssr=this._opts.ssr;var a=[],o=this._bgVNode=SW(n,r,this._backgroundColor,i);o&&a.push(o);var s=e.compress?null:this._mainVNode=dU(`g`,`main`,{},[]);this._paintList(t,i,s?s.children:a),s&&a.push(s);var c=B(V(i.defs),function(e){return i.defs[e]});if(c.length&&a.push(dU(`defs`,`defs`,{},c)),e.animation){var l=hU(i.cssNodes,i.cssAnims,{newline:!0});if(l){var u=dU(`style`,`stl`,{},[],l);a.push(u)}}return _U(n,r,a,e.useViewBox)},e.prototype.renderToString=function(e){return e||={},mU(this.renderToVNode({animation:q(e.cssAnimation,!0),emphasis:q(e.cssEmphasis,!0),willUpdate:!1,compress:!0,useViewBox:q(e.useViewBox,!0)}),{newline:!0})},e.prototype.setBackgroundColor=function(e){this._backgroundColor=e},e.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},e.prototype._paintList=function(e,t,n){for(var r=e.length,i=[],a=0,o,s,c=0,l=0;l<r;l++){var u=e[l];if(!u.invisible){var d=u.__clipPaths,f=d&&d.length||0,p=s&&s.length||0,m=void 0;for(m=Math.max(f-1,p-1);m>=0&&!(d&&s&&d[m]===s[m]);m--);for(var h=p-1;h>m;h--)a--,o=i[a-1];for(var g=m+1;g<f;g++){var _={};ZU(d[g],_,t);var v=dU(`g`,`clip-g-`+c++,_,[]);(o?o.children:n).push(v),i[a++]=v,o=v}s=d;var y=qU(u,t);y&&(o?o.children:n).push(y)}}},e.prototype.resize=function(e,t){var n=this._opts,r=this.root,i=this._viewport;if(e!=null&&(n.width=e),t!=null&&(n.height=t),r&&i&&(i.style.display=`none`,e=ck(r,0,n),t=ck(r,1,n),i.style.display=``),this._width!==e||this._height!==t){if(this._width=e,this._height=t,i){var a=i.style;a.width=e+`px`,a.height=t+`px`}if(Qi(this._backgroundColor))this.refresh();else{var o=this._svgDom;o&&(o.setAttribute(`width`,e),o.setAttribute(`height`,t));var s=this._bgVNode&&this._bgVNode.elm;s&&(s.setAttribute(`width`,e),s.setAttribute(`height`,t))}}},e.prototype.getWidth=function(){return this._width},e.prototype.getHeight=function(){return this._height},e.prototype.dispose=function(){this.root&&(this.root.innerHTML=``),this._svgDom=this._viewport=this.storage=this._oldVNode=this._bgVNode=this._mainVNode=null},e.prototype.clear=function(){this._svgDom&&(this._svgDom.innerHTML=null),this._oldVNode=null},e.prototype.toDataURL=function(e){var t=this.renderToString(),n=`data:image/svg+xml;`;return e?(t=aa(t),t&&n+`base64,`+t):n+`charset=UTF-8,`+encodeURIComponent(t)},e}();function xW(e){return function(){}}function SW(e,t,n,r){var i;if(n&&n!==`none`){if(i=dU(`rect`,`bg`,{width:e,height:t,x:`0`,y:`0`}),ta(n))YU({fill:n},i.attrs,`fill`,r);else if(Qi(n))XU({style:{fill:n},dirty:tt,getBoundingRect:function(){return{width:e,height:t}}},i.attrs,`fill`,r);else{var a=Bi(n),o=a.color,s=a.opacity;i.attrs.fill=o,s<1&&(i.attrs[`fill-opacity`]=s)}}return i}function CW(e){e.registerPainter(`svg`,bW)}Vj([$x,MT,XF,DR,AB,SH,kH,NV,oV,Qz,CW]);function wW(e){return e?[...e.querySelectorAll(`[_echarts_instance_]`)].map(e=>gj(e)).filter(e=>e!==void 0&&!e.isDisposed()):[]}function TW(e){let t=(0,S.useRef)(null),n=_();return(0,S.useEffect)(()=>{let e=t.current;if(!e||typeof ResizeObserver>`u`)return;let n,r=-1,i=new ResizeObserver(t=>{let i=t[0]?.contentRect.width??0;i!==r&&(r=i,clearTimeout(n),n=setTimeout(()=>{for(let t of wW(e))t.resize()},50))});return i.observe(e),()=>{clearTimeout(n),i.disconnect()}},[]),(0,S.useEffect)(()=>{for(let r of wW(t.current))e&&r.setOption(e,{lazyUpdate:!0}),n&&r.setOption({animation:!1})}),t}var $=a(),EW=e=>e+new Date(e).getTimezoneOffset()*6e4,DW=e=>e-new Date(e).getTimezoneOffset()*6e4,OW={xAxis:{axisLabel:{hideOverlap:!0}}};function kW({series:e,granularity:t,locale:r,labels:i,type:a=`line`,height:o=280,incompleteAfter:c,compact:f=!1,loading:p=!1,now:m,className:_}){let C=(0,S.useMemo)(()=>d(r),[r]),w=y(),[T,E]=(0,S.useState)(`chart`),D=TW(OW),O=(0,S.useId)(),k=(0,S.useMemo)(()=>e.map((e,t)=>({name:e.name,color:w.series[t%w.series.length],data:e.points.map(([e,t])=>[EW(e),t])})),[e,w]),A=c===null?void 0:c??b(t,m),j=(0,S.useMemo)(()=>{let t=new Set;for(let n of e)for(let[e]of n.points)t.add(e);return[...t].sort((e,t)=>e-t)},[e]);return(0,$.jsxs)(`div`,{ref:D,className:n(`grid min-w-0 grid-cols-1 gap-3`,_),"data-testid":`analytics-timeseries`,children:[(0,$.jsxs)(`div`,{className:n(`flex min-w-0 flex-wrap items-center gap-x-4 gap-y-2`,f?`justify-end`:`justify-between`),children:[f?null:(0,$.jsx)(`div`,{className:`flex min-w-0 flex-wrap items-center gap-x-4 gap-y-1`,children:p?e.map(e=>(0,$.jsx)(v.SmallItem,{loading:!0},e.id)):e.map((e,t)=>(0,$.jsx)(v.SmallItem,{name:e.name,color:w.series[t%w.series.length],value:C.number(e.total??e.points.reduce((e,[,t])=>e+t,0))},e.id))}),(0,$.jsx)(s,{variant:`ghost`,size:`xs`,icon:T===`chart`?(0,$.jsx)(u,{size:14}):(0,$.jsx)(x,{size:14}),"aria-expanded":T===`table`,"aria-controls":O,disabled:p,onClick:()=>E(e=>e===`chart`?`table`:`chart`),children:T===`chart`?i.showTable:i.showChart})]}),T===`chart`&&p?(0,$.jsx)(`span`,{role:`status`,className:`sr-only`,children:i.loading}):null,T===`chart`?(0,$.jsx)(`div`,{"aria-hidden":p||void 0,className:`min-w-0`,children:(0,$.jsx)(g,{echarts:GH,type:a,data:k,gradient:a===`line`,height:o,isDarkMode:w.isDarkMode,loading:p,yAxisMinInterval:1,...f?{yAxisTickCount:2,xAxisTickCount:3}:{},xAxisTickFormat:e=>C.tick(DW(e),t),yAxisTickFormat:e=>C.compact(e),tooltipValueFormat:e=>C.number(e),tooltipTimestampFormat:e=>C.bucket(DW(e),t),tooltipFooter:i.timezone,tooltipFollowCursor:`x`,...A===void 0?{}:{incomplete:{after:EW(A)}},ariaDescription:i.description})}):null,(0,$.jsx)(`section`,{id:O,hidden:T!==`table`,"aria-label":i.description,tabIndex:T===`table`?0:-1,className:`max-h-80 min-w-0 overflow-auto rounded-lg ring ring-kumo-hairline`,children:T===`table`&&(0,$.jsxs)(h,{children:[(0,$.jsx)(`caption`,{className:`sr-only`,children:i.description}),(0,$.jsx)(h.Header,{children:(0,$.jsxs)(h.Row,{children:[(0,$.jsx)(h.Head,{children:i.time}),e.map(e=>(0,$.jsx)(h.Head,{className:`text-end whitespace-nowrap`,children:e.name},e.id))]})}),(0,$.jsx)(h.Body,{children:j.map(n=>(0,$.jsxs)(h.Row,{children:[(0,$.jsx)(h.Cell,{className:`whitespace-nowrap`,children:(0,$.jsx)(l,{as:`span`,children:C.bucket(n,t)})}),e.map(e=>{let t=e.points.find(([e])=>e===n)?.[1];return(0,$.jsx)(h.Cell,{className:`text-end whitespace-nowrap tabular-nums`,children:t===void 0?`—`:C.number(t)},e.id)})]},n))})]})}),T===`table`&&(0,$.jsx)(l,{variant:`secondary`,size:`xs`,children:i.timezone})]})}function AW({locale:e,labels:t,pageviews:n,visits:r,series:i,channels:a,redirects:s,href:u,loading:d=!1,empty:h}){if(h!=null&&h!==!1)return(0,$.jsx)($.Fragment,{children:h});let g=a.reduce((e,t)=>e+t.value,0);return(0,$.jsxs)(`div`,{className:`grid min-w-0 gap-5`,"data-testid":`readers-summary`,children:[(0,$.jsxs)(f,{label:t.figures,density:`compact`,children:[(0,$.jsx)(m,{label:t.pageviews,value:n.value,previous:n.previous??null,locale:e,loading:d,...t.describeDelta?{describeDelta:t.describeDelta}:{}}),(0,$.jsx)(m,{label:t.visits,value:r.value,previous:r.previous??null,locale:e,loading:d,...t.describeDelta?{describeDelta:t.describeDelta}:{}})]}),(0,$.jsx)(kW,{series:[{id:`pageviews`,name:t.pageviews,points:i}],granularity:`day`,type:`bar`,height:120,compact:!0,locale:e,labels:t.chart,loading:d}),(0,$.jsx)(p,{rows:a,locale:e,limit:3,total:g,showOther:!1,otherLabel:t.other,label:t.channels,loading:d}),s&&!d&&(0,$.jsxs)(`div`,{className:`flex min-w-0 items-start gap-2`,children:[(0,$.jsx)(`span`,{className:`flex h-lh shrink-0 items-center text-kumo-subtle`,"aria-hidden":!0,children:(0,$.jsx)(c,{icon:T,size:16})}),(0,$.jsx)(l,{variant:`secondary`,size:`sm`,children:s})]}),(0,$.jsx)(`div`,{className:`flex justify-start`,children:(0,$.jsx)(o,{variant:`ghost`,size:`sm`,href:u,icon:(0,$.jsx)(x,{size:16}),children:t.open})})]})}var jW=e({AnalyticsTimeseries:()=>kW,ReadersSummary:()=>AW});export{GH as i,kW as n,TW as r,jW as t};
39
- //# sourceMappingURL=charts-DL9SbRU8.js.map
39
+ //# sourceMappingURL=charts-CcTdxwHf.js.map
@@ -1,2 +1,2 @@
1
- import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t}from"./IconBase.es-BZDpYMnj.js";import{vr as n}from"./useBaseUiId-lg1teubxudgin0w2-CrAc3DRu.js";import{i as r,r as i}from"./react-CDCuUAOg.js";import{c as a,d as o,f as s,l as c,p as l,t as u,u as d}from"./button-pa1bq9b85hawg41a-BcGpLLER.js";import{g as f}from"./skeleton-line-m9dyh126t9k07jvg-CHsT8Hs3.js";import{n as p}from"./House.es-BQyZgbwu.js";import{a as m,i as h,n as g,o as _,r as v,t as y,u as b}from"./createToastManager-onmoqrmr8zo02rif-DtEv4lxV.js";import{r as x}from"./input-c8lv9ulv0kortliq-Cum0c7P1.js";var S=e(r(),1),C=i(),w=_(),T=1500,E={size:{sm:{classes:`text-xs`,buttonSize:`sm`,description:`Small clipboard text for compact UIs`},base:{classes:`text-sm`,buttonSize:`base`,description:`Default clipboard text size`},lg:{classes:`text-sm`,buttonSize:`lg`,description:`Large clipboard text for prominent display`}}},D={size:`lg`},O={slide:{initial:`pointer-events-none absolute inset-0 flex items-center justify-center opacity-0 translate-y-full`,animate:`translate-y-0 opacity-100`,end:`pointer-events-none absolute inset-0 flex items-center justify-center opacity-0 -translate-y-full`}};function k({size:e=D.size}={}){return t(`flex items-center overflow-hidden bg-kumo-base px-0 font-mono`,n(E.size,e,D.size).classes)}function A(){let{toasts:e}=b();return(0,C.jsx)(m,{className:`pointer-events-none fixed inset-0 isolate`,children:e.map(e=>{let n=e.updateKey??0;return(0,C.jsx)(g,{toast:e,className:`absolute`,children:(0,C.jsx)(h,{toast:e,className:t(`flex origin-[var(--transform-origin)] flex-col rounded-md bg-kumo-base px-3 py-1.5 font-sans text-xs text-kumo-default`,`shadow-lg outline outline-kumo-line`,n>0&&`animate-clipboard-toast-bump`),children:(0,C.jsx)(y,{})},n)},e.id)})})}function j({children:e}){return(0,C.jsx)(a,{children:(0,C.jsxs)(v,{toastManager:w,children:[(0,C.jsx)(A,{}),e]})})}var M=(0,S.forwardRef)(({text:e,textToCopy:r,className:i,size:a=D.size,onCopy:m,tooltip:h,labels:{copyAction:g=`Copy to clipboard`}={}},_)=>{let[v,y]=(0,S.useState)(!1),b=(0,S.useRef)(null),A=(0,S.useRef)(null),M=(0,S.useRef)(null),N=n(E.size,a,D.size),{text:P=`Copy`,copiedText:F=`Copied`,side:I=`top`}=h??{};(0,S.useEffect)(()=>()=>{A.current!==null&&clearTimeout(A.current)},[]);let L=(0,S.useCallback)(()=>{A.current!==null&&clearTimeout(A.current),A.current=setTimeout(()=>{y(!1),A.current=null},T)},[]),R=(0,S.useCallback)(async()=>{try{if(typeof navigator<`u`&&navigator.clipboard&&typeof navigator.clipboard.writeText==`function`)await navigator.clipboard.writeText(r??e);else if(typeof document<`u`){let t=document.createElement(`textarea`);t.value=r??e,t.setAttribute(`readonly`,``),t.style.position=`absolute`,t.style.left=`-9999px`,document.body.appendChild(t);let n=document.getSelection(),i=n?.rangeCount?n.getRangeAt(0):null;t.select();try{document.execCommand(`copy`)}finally{document.body.removeChild(t),i&&(n?.removeAllRanges(),n?.addRange(i))}}y(!0),h?M.current=w.add({id:M.current??void 0,description:F,positionerProps:{anchor:b.current,side:I,sideOffset:8},timeout:T,onClose(){M.current=null,y(!1)}}):L(),m?.()}catch(e){console.warn(`Clipboard copy failed`,e)}},[e,r,m,h,F,I,L]),z=(0,C.jsxs)(u,{ref:b,size:N.buttonSize,variant:`ghost`,className:t(`relative isolate overflow-hidden rounded-s-none rounded-e-[inherit] border-l! border-kumo-line! px-3 transition-all duration-200`,`focus:ring-kumo-focus/50 focus:ring-inset`,`focus-visible:ring-2 focus-visible:ring-kumo-brand focus-visible:ring-inset`),onClick:R,"aria-label":g,children:[(0,C.jsx)(`span`,{className:t(`flex items-center gap-1 transition-all duration-200`,v?O.slide.animate:O.slide.initial),children:(0,C.jsx)(f,{})}),(0,C.jsx)(`span`,{className:t(`flex items-center justify-center transition-all duration-200`,v?O.slide.end:O.slide.animate),children:(0,C.jsx)(p,{})})]});return(0,C.jsxs)(`div`,{ref:_,className:t(x({size:N.buttonSize}),k({size:a}),i),children:[(0,C.jsx)(`span`,{className:`grow truncate ps-4 pe-2`,children:e}),h?(0,C.jsx)(j,{children:(0,C.jsxs)(s,{disabled:v,onOpenChange:(e,t)=>{t.reason===`trigger-press`&&t.cancel()},children:[(0,C.jsx)(l,{render:z}),(0,C.jsx)(d,{children:(0,C.jsx)(o,{side:I,sideOffset:8,children:(0,C.jsx)(c,{className:t(`flex origin-[var(--transform-origin)] flex-col rounded-md bg-kumo-base px-3 py-1.5 text-xs text-kumo-default`,`shadow-md outline outline-kumo-line`),children:P})})})]})}):z,(0,C.jsx)(`span`,{className:`sr-only`,"aria-live":`polite`,children:v?F:``})]})});M.displayName=`ClipboardText`;export{M as t};
2
- //# sourceMappingURL=clipboard-text-gd6s3n1bqse9zgt8-DXnAaY6R.js.map
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t}from"./IconBase.es-BZDpYMnj.js";import{vr as n}from"./useBaseUiId-lg1teubxudgin0w2-CrAc3DRu.js";import{i as r,r as i}from"./react-CDCuUAOg.js";import{c as a,d as o,f as s,l as c,p as l,t as u,u as d}from"./button-pa1bq9b85hawg41a-BcGpLLER.js";import{g as f}from"./skeleton-line-m9dyh126t9k07jvg-CHsT8Hs3.js";import{n as p}from"./House.es-BQyZgbwu.js";import{a as m,i as h,n as g,o as _,r as v,t as y,u as b}from"./createToastManager-onmoqrmr8zo02rif-DFnQWIYL.js";import{r as x}from"./input-c8lv9ulv0kortliq-Cum0c7P1.js";var S=e(r(),1),C=i(),w=_(),T=1500,E={size:{sm:{classes:`text-xs`,buttonSize:`sm`,description:`Small clipboard text for compact UIs`},base:{classes:`text-sm`,buttonSize:`base`,description:`Default clipboard text size`},lg:{classes:`text-sm`,buttonSize:`lg`,description:`Large clipboard text for prominent display`}}},D={size:`lg`},O={slide:{initial:`pointer-events-none absolute inset-0 flex items-center justify-center opacity-0 translate-y-full`,animate:`translate-y-0 opacity-100`,end:`pointer-events-none absolute inset-0 flex items-center justify-center opacity-0 -translate-y-full`}};function k({size:e=D.size}={}){return t(`flex items-center overflow-hidden bg-kumo-base px-0 font-mono`,n(E.size,e,D.size).classes)}function A(){let{toasts:e}=b();return(0,C.jsx)(m,{className:`pointer-events-none fixed inset-0 isolate`,children:e.map(e=>{let n=e.updateKey??0;return(0,C.jsx)(g,{toast:e,className:`absolute`,children:(0,C.jsx)(h,{toast:e,className:t(`flex origin-[var(--transform-origin)] flex-col rounded-md bg-kumo-base px-3 py-1.5 font-sans text-xs text-kumo-default`,`shadow-lg outline outline-kumo-line`,n>0&&`animate-clipboard-toast-bump`),children:(0,C.jsx)(y,{})},n)},e.id)})})}function j({children:e}){return(0,C.jsx)(a,{children:(0,C.jsxs)(v,{toastManager:w,children:[(0,C.jsx)(A,{}),e]})})}var M=(0,S.forwardRef)(({text:e,textToCopy:r,className:i,size:a=D.size,onCopy:m,tooltip:h,labels:{copyAction:g=`Copy to clipboard`}={}},_)=>{let[v,y]=(0,S.useState)(!1),b=(0,S.useRef)(null),A=(0,S.useRef)(null),M=(0,S.useRef)(null),N=n(E.size,a,D.size),{text:P=`Copy`,copiedText:F=`Copied`,side:I=`top`}=h??{};(0,S.useEffect)(()=>()=>{A.current!==null&&clearTimeout(A.current)},[]);let L=(0,S.useCallback)(()=>{A.current!==null&&clearTimeout(A.current),A.current=setTimeout(()=>{y(!1),A.current=null},T)},[]),R=(0,S.useCallback)(async()=>{try{if(typeof navigator<`u`&&navigator.clipboard&&typeof navigator.clipboard.writeText==`function`)await navigator.clipboard.writeText(r??e);else if(typeof document<`u`){let t=document.createElement(`textarea`);t.value=r??e,t.setAttribute(`readonly`,``),t.style.position=`absolute`,t.style.left=`-9999px`,document.body.appendChild(t);let n=document.getSelection(),i=n?.rangeCount?n.getRangeAt(0):null;t.select();try{document.execCommand(`copy`)}finally{document.body.removeChild(t),i&&(n?.removeAllRanges(),n?.addRange(i))}}y(!0),h?M.current=w.add({id:M.current??void 0,description:F,positionerProps:{anchor:b.current,side:I,sideOffset:8},timeout:T,onClose(){M.current=null,y(!1)}}):L(),m?.()}catch(e){console.warn(`Clipboard copy failed`,e)}},[e,r,m,h,F,I,L]),z=(0,C.jsxs)(u,{ref:b,size:N.buttonSize,variant:`ghost`,className:t(`relative isolate overflow-hidden rounded-s-none rounded-e-[inherit] border-l! border-kumo-line! px-3 transition-all duration-200`,`focus:ring-kumo-focus/50 focus:ring-inset`,`focus-visible:ring-2 focus-visible:ring-kumo-brand focus-visible:ring-inset`),onClick:R,"aria-label":g,children:[(0,C.jsx)(`span`,{className:t(`flex items-center gap-1 transition-all duration-200`,v?O.slide.animate:O.slide.initial),children:(0,C.jsx)(f,{})}),(0,C.jsx)(`span`,{className:t(`flex items-center justify-center transition-all duration-200`,v?O.slide.end:O.slide.animate),children:(0,C.jsx)(p,{})})]});return(0,C.jsxs)(`div`,{ref:_,className:t(x({size:N.buttonSize}),k({size:a}),i),children:[(0,C.jsx)(`span`,{className:`grow truncate ps-4 pe-2`,children:e}),h?(0,C.jsx)(j,{children:(0,C.jsxs)(s,{disabled:v,onOpenChange:(e,t)=>{t.reason===`trigger-press`&&t.cancel()},children:[(0,C.jsx)(l,{render:z}),(0,C.jsx)(d,{children:(0,C.jsx)(o,{side:I,sideOffset:8,children:(0,C.jsx)(c,{className:t(`flex origin-[var(--transform-origin)] flex-col rounded-md bg-kumo-base px-3 py-1.5 text-xs text-kumo-default`,`shadow-md outline outline-kumo-line`),children:P})})})]})}):z,(0,C.jsx)(`span`,{className:`sr-only`,"aria-live":`polite`,children:v?F:``})]})});M.displayName=`ClipboardText`;export{M as t};
2
+ //# sourceMappingURL=clipboard-text-gd6s3n1bqse9zgt8-8cLlgBwE.js.map
@@ -1,2 +1,2 @@
1
- import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t}from"./IconBase.es-BZDpYMnj.js";import{C as n,Dt as r,Hn as i,Nt as a,S as o,Sn as s,Tn as c,_r as l,at as u,b as d,ct as f,gr as p,k as m,mr as h,pr as g,rr as _,st as v,t as y,w as b}from"./useBaseUiId-lg1teubxudgin0w2-CrAc3DRu.js";import{i as x,r as S}from"./react-CDCuUAOg.js";import{c as C,n as w}from"./useButton-h7s9aq1sfw6arawe-BbWTOEat.js";import{ct as T}from"./index-Boved2Nz.js";var E=e(x(),1);function D(e){let{open:t,defaultOpen:n=!1,onOpenChange:r,disabled:i}=e,[o,s]=C({controlled:t,default:n,name:`Collapsible`,state:`open`}),{mounted:c,setMounted:l,transitionStatus:p}=d(o,!0,!0),m=y(),[h,g]=E.useState(),_=h===null?void 0:h??m,v=u(e=>{let t=!o,n=f(a,e.nativeEvent);r(t,n),!n.isCanceled&&s(t)});return E.useMemo(()=>({defaultPanelId:m,disabled:i,handleTrigger:v,mounted:c,open:o,panelId:_,setMounted:l,setOpen:s,setPanelIdState:g,transitionStatus:p}),[m,i,v,c,o,_,l,s,g,p])}var O=E.createContext(void 0);O.displayName=`CollapsibleRootContext`;function k(){let e=E.useContext(O);if(e===void 0)throw Error(`Base UI: CollapsibleRootContext is missing. Collapsible parts must be placed within <Collapsible.Root>.`);return e}var A=`data-open`,j=`data-closed`,M=s,N=`data-panel-open`,P={[A]:``},F={[j]:``},I={open(e){return e?{[N]:``}:null}},L={open(e){return e?P:F}},R={height:void 0,width:void 0};function z(e){let{externalRef:t,hiddenUntilFound:i,id:a,keepMounted:s,mounted:c,onOpenChange:l,open:d,setMounted:p,setOpen:g,transitionStatus:y}=e,x=E.useRef(null),S=E.useRef(null),[C,w]=E.useState(R),T=E.useRef(R),D=E.useRef(!1),O=E.useRef(d),k=E.useRef(!1),[A,j]=E.useState(!1),N=E.useRef(null),P=h(t,x),F=m(d),I=o(x),L=!d&&!c,z=A?`idle`:y,V=d&&(O.current||k.current),U=!d&&c&&S.current===`css-animation`&&C.height===void 0&&C.width===void 0?T.current:C,W=i&&L&&S.current!==`css-animation`,G=u((e,t=!0)=>{t&&(T.current=e),w(e)}),K=u(()=>{N.current?.(),N.current=null}),q=u(e=>{K(),N.current=()=>{N.current=null,e()}}),J=u(()=>{d&&c&&S.current===`css-animation`&&(k.current=!0)});_(()=>{A&&y!==`starting`&&j(!1)},[A,y]),E.useEffect(()=>()=>{J(),K()},[J,K]),_(()=>{let e=x.current;if(!e)return;!d&&N.current&&K();let t=ee(e,V);if(S.current=t,d&&y===`idle`&&O.current&&t===`css-animation`){T.current=B(e);return}if(d&&y===`starting`){let n=D.current;if(D.current=!1,t===`none`){G(B(e)),j(!0);return}if(t===`css-transition`){let t=te(e);if(G(B(e)),!n)return t;let r=H(e,`transition-duration`,`0s`);return q(r),j(!0),t}G(B(e));let r=H(e,`animation-name`,`none`);if(!n){r();return}let i=H(e,`animation-duration`,`0s`);r(),q(i),j(!0);return}if(!d&&c&&(y===`idle`||y===`starting`)){if(O.current=!1,k.current=!1,t===`none`){G(R,!1),p(!1);return}G(B(e));return}if(y!==`ending`)return;if(t===`none`){p(!1);return}let n=B(e);if(!(n.height>0||n.width>0)){p(!1);return}G(n),t===`css-animation`&&H(e,`animation-name`,`none`)()},[c,d,K,G,p,q,V,y]),n({enabled:d&&c&&z===`idle`,open:!0,ref:x,onComplete(){d&&G(R,!1)}}),E.useEffect(()=>{if(d||!c||z!==`ending`||!x.current)return;let e=new AbortController,t=-1;function n(){F.current||(p(!1),G(R,!1))}return t=b.request(()=>{I(n,e.signal)}),()=>{b.cancel(t),e.abort()}},[F,c,d,z,I,G,p]),_(()=>{let e=x.current;e&&i&&L&&e.setAttribute(`hidden`,`until-found`)},[L,i]),E.useEffect(function(){let e=x.current;if(!e)return;function t(e){let t=f(r,e);l(!0,t),!t.isCanceled&&(D.current=!0,g(!0))}return v(e,`beforematch`,t)},[l,g]);let Y=s||i||c||d;return{height:U.height,props:{...W?{[M]:``}:void 0,hidden:L,id:a},ref:P,shouldPreventOpenAnimation:V,shouldRender:Y,transitionStatus:z,width:U.width}}function B(e){return{height:e.scrollHeight,width:e.scrollWidth}}function ee(e,t){let n=i(e).getComputedStyle(e),r=(n.animationName.split(`,`).map(e=>e.trim()).some(e=>e!==``&&e!==`none`)||t)&&V(n.animationDuration),a=V(n.transitionDuration);return r&&a?(l(`CSS transitions and CSS animations both detected on Collapsible or Accordion panel.`,`Only one of either animation type should be used.`),`css-transition`):a?`css-transition`:r?`css-animation`:`none`}function V(e){return e.split(`,`).map(e=>e.trim()).some(e=>e!==``&&Number.parseFloat(e)>0)}function H(e,t,n){let r=e.style.getPropertyValue(t),i=e.style.getPropertyPriority(t);return e.style.setProperty(t,n),()=>{if(r===``){e.style.removeProperty(t);return}e.style.setProperty(t,r,i)}}function te(e){let t={"justify-content":e.style.justifyContent,"align-items":e.style.alignItems,"align-content":e.style.alignContent,"justify-items":e.style.justifyItems};Object.keys(t).forEach(t=>{e.style.setProperty(t,`initial`,`important`)});function n(){Object.entries(t).forEach(([t,n])=>{if(n===``){e.style.removeProperty(t);return}e.style.setProperty(t,n)})}let r=b.request(n);return()=>{b.cancel(r),n()}}var U=S(),W={...L,...c},G=E.forwardRef(function(e,t){let{render:n,className:r,defaultOpen:i=!1,disabled:a=!1,onOpenChange:o,open:s,style:c,...l}=e,d=u(o),f=D({open:s,defaultOpen:i,onOpenChange:d,disabled:a}),m=E.useMemo(()=>({open:f.open,disabled:f.disabled,transitionStatus:f.transitionStatus}),[f.open,f.disabled,f.transitionStatus]),h=E.useMemo(()=>({...f,onOpenChange:d,state:m}),[f,d,m]),g=p(`div`,e,{state:m,ref:t,props:l,stateAttributesMapping:W});return(0,U.jsx)(O.Provider,{value:h,children:g})});G.displayName=`CollapsibleRoot`;var K={...I,...c},q=E.forwardRef(function(e,t){let{panelId:n,open:r,handleTrigger:i,state:a,disabled:o}=k(),{className:s,disabled:c=o,render:l,nativeButton:u=!0,style:d,...f}=e,{getButtonProps:m,buttonRef:h}=w({disabled:c,focusableWhenDisabled:!0,native:u});return p(`button`,e,{state:a,ref:[t,h],props:[{"aria-controls":r?n:void 0,"aria-expanded":r,onClick:i},f,m],stateAttributesMapping:K})});q.displayName=`CollapsibleTrigger`;var J=`--collapsible-panel-height`,Y=`--collapsible-panel-width`,X=E.forwardRef(function(e,t){let{className:n,hiddenUntilFound:r,keepMounted:i,render:a,id:o,style:s,...c}=e;E.useEffect(()=>{r&&i===!1&&l("The `keepMounted={false}` prop on `Collapsible.Panel` is ignored when `hiddenUntilFound` is enabled, since the panel must remain mounted while closed.")},[r,i]);let{defaultPanelId:u,mounted:d,onOpenChange:f,open:m,setMounted:h,setPanelIdState:v,setOpen:y,state:b,transitionStatus:x}=k(),S=r??!1,C=i??!1,w=o||void 0,T=w??u;_(()=>(v(e=>w??(e===null?void 0:e)),()=>{v(e=>e===w?null:e)}),[w,v]);let{height:D,props:O,ref:A,shouldPreventOpenAnimation:j,shouldRender:M,transitionStatus:N,width:P}=z({externalRef:t,hiddenUntilFound:S,id:T,keepMounted:C,mounted:d,onOpenChange:f,open:m,setMounted:h,setOpen:y,transitionStatus:x}),F={...b,transitionStatus:N},I=g(s,F),L=p(`div`,{...e,style:void 0},{state:F,ref:A,props:[O,{style:{[J]:D===void 0?`auto`:`${D}px`,[Y]:P===void 0?`auto`:`${P}px`}},c,I?{style:I}:void 0,j?{style:{animationName:`none`}}:void 0],stateAttributesMapping:W});return M?L:null});X.displayName=`CollapsiblePanel`;function Z({className:e,...t}){return(0,U.jsx)(G,{className:e,...t})}Z.displayName=`Collapsible.Root`;var Q=(0,E.forwardRef)(({className:e,...n},r)=>(0,U.jsx)(q,{ref:r,"data-kumo-component":`Collapsible`,"data-kumo-part":`trigger`,className:t(`cursor-pointer`,e),...n}));Q.displayName=`Collapsible.Trigger`;var $=(0,E.forwardRef)(({className:e,...t},n)=>(0,U.jsx)(X,{ref:n,className:e,...t}));$.displayName=`Collapsible.Panel`;var ne=(0,E.forwardRef)(({children:e,className:n},r)=>(0,U.jsxs)(q,{ref:r,"data-kumo-component":`Collapsible`,"data-kumo-part":`default-trigger`,className:t(`m-0 border-none bg-transparent p-0 shadow-none`,`flex cursor-pointer items-center gap-1 text-base font-medium text-kumo-default select-none`,n),children:[(0,U.jsx)(`span`,{children:e}),(0,U.jsx)(`span`,{className:`inline-grid w-4 shrink-0 place-items-center`,children:(0,U.jsx)(T,{"aria-hidden":!0,size:12,weight:`bold`,className:`block size-3 origin-center transition-transform duration-100 ease-out [[data-panel-open]_&]:rotate-180`})})]}));ne.displayName=`Collapsible.DefaultTrigger`;var re=(0,E.forwardRef)(({children:e,className:n,...r},i)=>(0,U.jsx)(X,{ref:i,className:t(`h-[var(--collapsible-panel-height)] overflow-hidden transition-[height,opacity] duration-100 ease-out data-ending-style:h-0 data-ending-style:opacity-0 data-starting-style:h-0 data-starting-style:opacity-0 [&[hidden]:not([hidden='until-found'])]:hidden`,n),...r,children:(0,U.jsx)(`div`,{className:`my-2 space-y-4 border-s-2 border-kumo-fill py-1 pe-1 ps-4`,children:e})}));re.displayName=`Collapsible.DefaultPanel`;var ie=Object.assign(Z,{Root:Z,Trigger:Q,Panel:$,DefaultTrigger:ne,DefaultPanel:re});export{ie as t};
2
- //# sourceMappingURL=collapsible-l8g94on4w7qfosmn-udgP1bfF.js.map
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t}from"./IconBase.es-BZDpYMnj.js";import{C as n,Dt as r,Hn as i,Nt as a,S as o,Sn as s,Tn as c,_r as l,at as u,b as d,ct as f,gr as p,k as m,mr as h,pr as g,rr as _,st as v,t as y,w as b}from"./useBaseUiId-lg1teubxudgin0w2-CrAc3DRu.js";import{i as x,r as S}from"./react-CDCuUAOg.js";import{c as C,n as w}from"./useButton-h7s9aq1sfw6arawe-BbWTOEat.js";import{st as T}from"./index-DWzjnrnl.js";var E=e(x(),1);function D(e){let{open:t,defaultOpen:n=!1,onOpenChange:r,disabled:i}=e,[o,s]=C({controlled:t,default:n,name:`Collapsible`,state:`open`}),{mounted:c,setMounted:l,transitionStatus:p}=d(o,!0,!0),m=y(),[h,g]=E.useState(),_=h===null?void 0:h??m,v=u(e=>{let t=!o,n=f(a,e.nativeEvent);r(t,n),!n.isCanceled&&s(t)});return E.useMemo(()=>({defaultPanelId:m,disabled:i,handleTrigger:v,mounted:c,open:o,panelId:_,setMounted:l,setOpen:s,setPanelIdState:g,transitionStatus:p}),[m,i,v,c,o,_,l,s,g,p])}var O=E.createContext(void 0);O.displayName=`CollapsibleRootContext`;function k(){let e=E.useContext(O);if(e===void 0)throw Error(`Base UI: CollapsibleRootContext is missing. Collapsible parts must be placed within <Collapsible.Root>.`);return e}var A=`data-open`,j=`data-closed`,M=s,N=`data-panel-open`,P={[A]:``},F={[j]:``},I={open(e){return e?{[N]:``}:null}},L={open(e){return e?P:F}},R={height:void 0,width:void 0};function z(e){let{externalRef:t,hiddenUntilFound:i,id:a,keepMounted:s,mounted:c,onOpenChange:l,open:d,setMounted:p,setOpen:g,transitionStatus:y}=e,x=E.useRef(null),S=E.useRef(null),[C,w]=E.useState(R),T=E.useRef(R),D=E.useRef(!1),O=E.useRef(d),k=E.useRef(!1),[A,j]=E.useState(!1),N=E.useRef(null),P=h(t,x),F=m(d),I=o(x),L=!d&&!c,z=A?`idle`:y,V=d&&(O.current||k.current),U=!d&&c&&S.current===`css-animation`&&C.height===void 0&&C.width===void 0?T.current:C,W=i&&L&&S.current!==`css-animation`,G=u((e,t=!0)=>{t&&(T.current=e),w(e)}),K=u(()=>{N.current?.(),N.current=null}),q=u(e=>{K(),N.current=()=>{N.current=null,e()}}),J=u(()=>{d&&c&&S.current===`css-animation`&&(k.current=!0)});_(()=>{A&&y!==`starting`&&j(!1)},[A,y]),E.useEffect(()=>()=>{J(),K()},[J,K]),_(()=>{let e=x.current;if(!e)return;!d&&N.current&&K();let t=ee(e,V);if(S.current=t,d&&y===`idle`&&O.current&&t===`css-animation`){T.current=B(e);return}if(d&&y===`starting`){let n=D.current;if(D.current=!1,t===`none`){G(B(e)),j(!0);return}if(t===`css-transition`){let t=te(e);if(G(B(e)),!n)return t;let r=H(e,`transition-duration`,`0s`);return q(r),j(!0),t}G(B(e));let r=H(e,`animation-name`,`none`);if(!n){r();return}let i=H(e,`animation-duration`,`0s`);r(),q(i),j(!0);return}if(!d&&c&&(y===`idle`||y===`starting`)){if(O.current=!1,k.current=!1,t===`none`){G(R,!1),p(!1);return}G(B(e));return}if(y!==`ending`)return;if(t===`none`){p(!1);return}let n=B(e);if(!(n.height>0||n.width>0)){p(!1);return}G(n),t===`css-animation`&&H(e,`animation-name`,`none`)()},[c,d,K,G,p,q,V,y]),n({enabled:d&&c&&z===`idle`,open:!0,ref:x,onComplete(){d&&G(R,!1)}}),E.useEffect(()=>{if(d||!c||z!==`ending`||!x.current)return;let e=new AbortController,t=-1;function n(){F.current||(p(!1),G(R,!1))}return t=b.request(()=>{I(n,e.signal)}),()=>{b.cancel(t),e.abort()}},[F,c,d,z,I,G,p]),_(()=>{let e=x.current;e&&i&&L&&e.setAttribute(`hidden`,`until-found`)},[L,i]),E.useEffect(function(){let e=x.current;if(!e)return;function t(e){let t=f(r,e);l(!0,t),!t.isCanceled&&(D.current=!0,g(!0))}return v(e,`beforematch`,t)},[l,g]);let Y=s||i||c||d;return{height:U.height,props:{...W?{[M]:``}:void 0,hidden:L,id:a},ref:P,shouldPreventOpenAnimation:V,shouldRender:Y,transitionStatus:z,width:U.width}}function B(e){return{height:e.scrollHeight,width:e.scrollWidth}}function ee(e,t){let n=i(e).getComputedStyle(e),r=(n.animationName.split(`,`).map(e=>e.trim()).some(e=>e!==``&&e!==`none`)||t)&&V(n.animationDuration),a=V(n.transitionDuration);return r&&a?(l(`CSS transitions and CSS animations both detected on Collapsible or Accordion panel.`,`Only one of either animation type should be used.`),`css-transition`):a?`css-transition`:r?`css-animation`:`none`}function V(e){return e.split(`,`).map(e=>e.trim()).some(e=>e!==``&&Number.parseFloat(e)>0)}function H(e,t,n){let r=e.style.getPropertyValue(t),i=e.style.getPropertyPriority(t);return e.style.setProperty(t,n),()=>{if(r===``){e.style.removeProperty(t);return}e.style.setProperty(t,r,i)}}function te(e){let t={"justify-content":e.style.justifyContent,"align-items":e.style.alignItems,"align-content":e.style.alignContent,"justify-items":e.style.justifyItems};Object.keys(t).forEach(t=>{e.style.setProperty(t,`initial`,`important`)});function n(){Object.entries(t).forEach(([t,n])=>{if(n===``){e.style.removeProperty(t);return}e.style.setProperty(t,n)})}let r=b.request(n);return()=>{b.cancel(r),n()}}var U=S(),W={...L,...c},G=E.forwardRef(function(e,t){let{render:n,className:r,defaultOpen:i=!1,disabled:a=!1,onOpenChange:o,open:s,style:c,...l}=e,d=u(o),f=D({open:s,defaultOpen:i,onOpenChange:d,disabled:a}),m=E.useMemo(()=>({open:f.open,disabled:f.disabled,transitionStatus:f.transitionStatus}),[f.open,f.disabled,f.transitionStatus]),h=E.useMemo(()=>({...f,onOpenChange:d,state:m}),[f,d,m]),g=p(`div`,e,{state:m,ref:t,props:l,stateAttributesMapping:W});return(0,U.jsx)(O.Provider,{value:h,children:g})});G.displayName=`CollapsibleRoot`;var K={...I,...c},q=E.forwardRef(function(e,t){let{panelId:n,open:r,handleTrigger:i,state:a,disabled:o}=k(),{className:s,disabled:c=o,render:l,nativeButton:u=!0,style:d,...f}=e,{getButtonProps:m,buttonRef:h}=w({disabled:c,focusableWhenDisabled:!0,native:u});return p(`button`,e,{state:a,ref:[t,h],props:[{"aria-controls":r?n:void 0,"aria-expanded":r,onClick:i},f,m],stateAttributesMapping:K})});q.displayName=`CollapsibleTrigger`;var J=`--collapsible-panel-height`,Y=`--collapsible-panel-width`,X=E.forwardRef(function(e,t){let{className:n,hiddenUntilFound:r,keepMounted:i,render:a,id:o,style:s,...c}=e;E.useEffect(()=>{r&&i===!1&&l("The `keepMounted={false}` prop on `Collapsible.Panel` is ignored when `hiddenUntilFound` is enabled, since the panel must remain mounted while closed.")},[r,i]);let{defaultPanelId:u,mounted:d,onOpenChange:f,open:m,setMounted:h,setPanelIdState:v,setOpen:y,state:b,transitionStatus:x}=k(),S=r??!1,C=i??!1,w=o||void 0,T=w??u;_(()=>(v(e=>w??(e===null?void 0:e)),()=>{v(e=>e===w?null:e)}),[w,v]);let{height:D,props:O,ref:A,shouldPreventOpenAnimation:j,shouldRender:M,transitionStatus:N,width:P}=z({externalRef:t,hiddenUntilFound:S,id:T,keepMounted:C,mounted:d,onOpenChange:f,open:m,setMounted:h,setOpen:y,transitionStatus:x}),F={...b,transitionStatus:N},I=g(s,F),L=p(`div`,{...e,style:void 0},{state:F,ref:A,props:[O,{style:{[J]:D===void 0?`auto`:`${D}px`,[Y]:P===void 0?`auto`:`${P}px`}},c,I?{style:I}:void 0,j?{style:{animationName:`none`}}:void 0],stateAttributesMapping:W});return M?L:null});X.displayName=`CollapsiblePanel`;function Z({className:e,...t}){return(0,U.jsx)(G,{className:e,...t})}Z.displayName=`Collapsible.Root`;var Q=(0,E.forwardRef)(({className:e,...n},r)=>(0,U.jsx)(q,{ref:r,"data-kumo-component":`Collapsible`,"data-kumo-part":`trigger`,className:t(`cursor-pointer`,e),...n}));Q.displayName=`Collapsible.Trigger`;var $=(0,E.forwardRef)(({className:e,...t},n)=>(0,U.jsx)(X,{ref:n,className:e,...t}));$.displayName=`Collapsible.Panel`;var ne=(0,E.forwardRef)(({children:e,className:n},r)=>(0,U.jsxs)(q,{ref:r,"data-kumo-component":`Collapsible`,"data-kumo-part":`default-trigger`,className:t(`m-0 border-none bg-transparent p-0 shadow-none`,`flex cursor-pointer items-center gap-1 text-base font-medium text-kumo-default select-none`,n),children:[(0,U.jsx)(`span`,{children:e}),(0,U.jsx)(`span`,{className:`inline-grid w-4 shrink-0 place-items-center`,children:(0,U.jsx)(T,{"aria-hidden":!0,size:12,weight:`bold`,className:`block size-3 origin-center transition-transform duration-100 ease-out [[data-panel-open]_&]:rotate-180`})})]}));ne.displayName=`Collapsible.DefaultTrigger`;var re=(0,E.forwardRef)(({children:e,className:n,...r},i)=>(0,U.jsx)(X,{ref:i,className:t(`h-[var(--collapsible-panel-height)] overflow-hidden transition-[height,opacity] duration-100 ease-out data-ending-style:h-0 data-ending-style:opacity-0 data-starting-style:h-0 data-starting-style:opacity-0 [&[hidden]:not([hidden='until-found'])]:hidden`,n),...r,children:(0,U.jsx)(`div`,{className:`my-2 space-y-4 border-s-2 border-kumo-fill py-1 pe-1 ps-4`,children:e})}));re.displayName=`Collapsible.DefaultPanel`;var ie=Object.assign(Z,{Root:Z,Trigger:Q,Panel:$,DefaultTrigger:ne,DefaultPanel:re});export{ie as t};
2
+ //# sourceMappingURL=collapsible-l8g94on4w7qfosmn-B4g2i1uh.js.map
@@ -1,2 +1,2 @@
1
- import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t}from"./IconBase.es-BZDpYMnj.js";import{C as n,Cn as r,Dn as i,Dt as a,I as o,L as s,Ot as c,St as l,Tn as u,Tt as d,Un as f,Ut as p,an as m,at as h,b as g,ct as _,dt as v,ft as y,gr as b,ir as x,j as S,or as C,r as w,rr as T,sr as E,tn as D,ut as O,vn as k,wt as A,yn as j}from"./useBaseUiId-lg1teubxudgin0w2-CrAc3DRu.js";import{i as M,n as N,r as P}from"./react-CDCuUAOg.js";import{_ as ee,g as F,v as I}from"./button-pa1bq9b85hawg41a-BcGpLLER.js";import{t as te}from"./inertValue-e0o6qvuef83v78fk-DAETOorM.js";import{i as L,n as ne}from"./resolveAriaLabelledBy-nc8mdie5shy87nsb-asx42i8W.js";import{g as R}from"./skeleton-line-m9dyh126t9k07jvg-CHsT8Hs3.js";import{l as re,n as ie,u as ae,v as oe,y as se}from"./useButton-h7s9aq1sfw6arawe-BbWTOEat.js";import{n as ce,o as le,r as z}from"./input-c8lv9ulv0kortliq-Cum0c7P1.js";import{n as ue,r as de,t as fe}from"./useClick-l0p0endoxrlp0ae5-Bbq8u-IC.js";import{a as B,f as pe,m as me,r as he,u as ge}from"./resolveValueLabel-hpmsash3ektitvnb-X_gYut6U.js";import{d as V,u as H}from"./composite-ab8dmdfoj6tmhcn1-DBTnwEaq.js";import{C as U,E as _e,S as W,T as G,_ as ve,a as ye,b as be,c as xe,d as Se,f as K,g as Ce,h as we,i as Te,l as Ee,m as De,n as Oe,o as ke,p as Ae,r as je,s as q,t as Me,u as Ne,v as Pe,x as Fe,y as J}from"./ComboboxEmpty-o0q20j2l2syar9kx-Bf-42bzQ.js";import{a as Ie,i as Le,r as Re}from"./ToolbarRootContext-eqk40r8uh4h6r211-DBIMpkd1.js";import{F as ze}from"./index-Boved2Nz.js";var Y=e(M(),1);function Be(e,t,n,r){if(e.baseUIHandlerPrevented)return;let i=D(e.nativeEvent),a=f(i)?i:null;(a===e.currentTarget||!r?.(a)&&!m(a))&&(e.preventDefault(),!n&&(t.context.inputRef.current?.focus(),t.state.openOnInputClick&&t.context.setOpen(!0,_(l,e.nativeEvent))))}var X=Y.forwardRef(function(e,t){let{render:n,className:i,nativeButton:o=!0,disabled:s=!1,id:c,style:l,...u}=e,{state:f,disabled:m,setTouched:g,setFocused:v,validationMode:y,validation:x}=oe(),{labelId:C}=se(),w=U(),T=w.useState(`selectionMode`),E=w.useState(`disabled`),A=w.useState(`readOnly`),j=w.useState(`required`),M=w.useState(`positionerElement`),N=w.useState(`listElement`),P=w.useState(`popupId`),ee=w.useState(`triggerProps`),F=w.useState(`inputInsidePopup`),I=w.useState(`id`),te=w.useState(`labelId`),L=w.useState(`open`),R=w.useState(`selectedValue`),ae=w.useState(`activeIndex`),ce=w.useState(`selectedIndex`),le=w.useState(`hasSelectedValue`),z=J(),ue=be(),de=S(),B=m||E||s,pe=G(),me=_e(w);re({id:F?c:void 0});let he=F?c??I:c,ge=ne(C,te),V;L&&F?V=P??De(I):L&&(V=N?.id);let H=Y.useRef(``);function W(e){H.current=e.pointerType}let{reference:ve}=Ie(z,{enabled:!L&&!A&&!E&&T===`single`,listRef:w.context.labelsRef,activeIndex:ae,selectedIndex:ce,onMatch(e){let t=w.context.valuesRef.current[e];t!==void 0&&w.context.setSelectedValue(t,_(a))}}),{reference:ye}=fe(z,{enabled:!E,event:`mousedown`}),{buttonRef:xe,getButtonProps:Se}=ie({native:o,disabled:B}),K={...f,readOnly:A,open:L,disabled:B,popupSide:me,listEmpty:pe,placeholder:T!==`none`&&!le},we=h(e=>{w.set(`triggerElement`,e)});return b(`button`,e,{ref:[t,xe,we],state:K,props:[ee,ye,ve,{id:he,tabIndex:F?0:-1,role:F?`combobox`:void 0,"aria-expanded":L,"aria-haspopup":F?`dialog`:`listbox`,"aria-controls":V,"aria-required":F&&j||void 0,"aria-readonly":F&&A||void 0,"aria-labelledby":ge,onPointerDown:W,onPointerEnter:W,onFocus(){v(!0),!B&&de.start(0,w.context.forceMount)},onBlur(e){if(!p(M,e.relatedTarget)&&(g(!0),v(!1),y===`onBlur`)){let e=T===`none`?ue:R;x.commit(e)}},onMouseDown(e){if(B||(F||z.set(`domReferenceElement`,e.currentTarget),w.context.forceMount(),H.current!==`touch`&&(w.context.inputRef.current?.focus(),F||e.preventDefault()),L))return;let t=k(e.currentTarget);function n(e){let t=w.state.triggerElement;if(!t)return;let n=D(e),r=w.state.positionerElement,i=w.state.listElement;p(t,n)||p(r,n)||p(i,n)||Le(e,t)||w.context.setOpen(!1,_(O,e))}F&&t.addEventListener(`mouseup`,n,{once:!0})},onKeyDown(e){(e.key===`ArrowDown`||e.key===`ArrowUp`)&&(r(e),w.context.setOpen(!0,_(d,e.nativeEvent)),w.context.inputRef.current?.focus())}},x.getValidationProps(B,u),Se],stateAttributesMapping:Ce})});X.displayName=`ComboboxTrigger`;var Z=Y.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e;return b(`span`,e,{ref:t,props:[{"aria-hidden":!0,children:`▼`},a]})});Z.displayName=`ComboboxIcon`;var Ve={...u,...i},He=Y.forwardRef(function(e,t){let{render:r,className:i,disabled:a=!1,nativeButton:o=!0,keepMounted:s=!1,style:l,...u}=e,{disabled:d}=oe(),f=U(),p=f.useState(`selectionMode`),m=f.useState(`disabled`),h=f.useState(`readOnly`),v=f.useState(`open`),x=f.useState(`selectedValue`),S=f.useState(`hasSelectionChips`),C=be(),w=!1;w=p===`none`?C!==``:p===`single`?x!=null:S;let T=d||m||a,{buttonRef:E,getButtonProps:D}=ie({native:o,disabled:T}),{mounted:O,transitionStatus:k,setMounted:j}=g(w),M={disabled:T,visible:w,open:v,transitionStatus:k};n({open:w,ref:f.context.clearRef,onComplete(){w||j(!1)}});let N=b(`button`,e,{state:M,ref:[t,E,f.context.clearRef],props:[{tabIndex:-1,children:`x`,onMouseDown(e){e.preventDefault()},onClick(e){if(T||h)return;let t=f.context.keyboardActiveRef.current?A:c;f.context.setInputValue(``,_(y,e.nativeEvent)),p===`none`?f.context.setIndices({activeIndex:null,type:t}):(f.context.setSelectedValue(Array.isArray(x)?[]:null,_(y,e.nativeEvent)),f.context.setIndices({activeIndex:null,selectedIndex:null,type:t})),f.context.inputRef.current?.focus()}},u,D],stateAttributesMapping:Ve});return s||O?N:null});He.displayName=`ComboboxClear`;var Q=P(),Ue=e(N(),1);function We(e){let{multiple:t=!1,defaultValue:n,value:r,onValueChange:i,autoComplete:a,...o}=e;return(0,Q.jsx)(Me,{...o,selectionMode:t?`multiple`:`single`,selectedValue:r,defaultSelectedValue:n,onSelectedValueChange:i,formAutoComplete:a})}function Ge(e){let{children:t,placeholder:n}=e,r=U(),i=r.useState(`itemToStringLabel`),a=r.useState(`selectedValue`),o=r.useState(`items`),s=r.useState(`selectionMode`)===`multiple`,c=r.useState(`hasSelectedValue`),l=!c&&n!=null&&t==null,u=r.useState(`hasNullItemLabel`,l),d=null;return d=typeof t==`function`?t(a):t??(!c&&n!=null&&!u?n:s&&Array.isArray(a)?ge(a,o,i):pe(a,o,i)),(0,Q.jsx)(Y.Fragment,{children:d})}var Ke=Y.forwardRef(function(e,t){let{selected:n}=Fe();return e.keepMounted||n?(0,Q.jsx)(qe,{...e,ref:t}):null});Ke.displayName=`ComboboxItemIndicator`;var qe=Y.memo(Y.forwardRef((e,t)=>{let{render:r,className:i,style:a,keepMounted:o,...s}=e,{selected:c}=Fe(),l=Y.useRef(null),{transitionStatus:d,setMounted:f}=g(c),p=b(`span`,e,{ref:[t,l],state:{selected:c,transitionStatus:d},props:[{"aria-hidden":!0,children:`✔️`},s],stateAttributesMapping:u});return n({batch:!0,enabled:!c,open:c,ref:l,onComplete(){c||f(!1)}}),p}));qe.displayName=`Inner`;var Je=Y.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e,o=U(),s=o.useState(`open`),c=o.useState(`hasSelectionChips`),[l,u]=Y.useState(void 0);s&&l!==void 0&&u(void 0);let d=Y.useRef([]),f=b(`div`,e,{ref:[t,o.context.chipsContainerRef],props:[c?{role:`toolbar`}:E,{onMouseDown(e){Be(e,o,o.state.disabled)}},a]}),p=Y.useMemo(()=>({highlightedChipIndex:l,setHighlightedChipIndex:u,chipsRef:d}),[l,u,d]);return(0,Q.jsx)(Oe.Provider,{value:p,children:(0,Q.jsx)(V,{elementsRef:d,children:f})})});Je.displayName=`ComboboxChips`;var Ye=Y.createContext(void 0);Ye.displayName=`ComboboxChipContext`;function Xe(){let e=Y.useContext(Ye);if(!e)throw Error(`Base UI: ComboboxChipContext is missing. ComboboxChip parts must be placed within <Combobox.Chip>.`);return e}var Ze=Y.forwardRef(function(e,t){let{render:n,className:i,style:o,...s}=e,c=U(),{setHighlightedChipIndex:l,chipsRef:u}=ve(),f=w(),p=c.useState(`disabled`),m=c.useState(`readOnly`),h=c.useState(`selectedValue`),{ref:g,index:v}=H();function y(e){let t=v,[n,i]=Ae(f);return e.key===n?(e.preventDefault(),t=v>0?v-1:void 0):e.key===i?(e.preventDefault(),t=v<u.current.length-1?v+1:void 0):e.key===`Backspace`||e.key===`Delete`?(t=we(v,h.length),r(e),c.context.setIndices({activeIndex:null,selectedIndex:null,type:A}),c.context.setSelectedValue(h.filter((e,t)=>t!==v),_(a,e.nativeEvent))):e.key===`Enter`||e.key===` `?(r(e),t=void 0):e.key===`ArrowDown`||e.key===`ArrowUp`?(r(e),c.context.setOpen(!0,_(d,e.nativeEvent)),t=void 0):e.key.length===1&&!e.ctrlKey&&!e.metaKey&&!e.altKey&&(t=void 0),t}let x=b(`div`,e,{ref:[t,g],state:{disabled:p},props:[{tabIndex:-1,"aria-disabled":p||void 0,"aria-readonly":m||void 0,onKeyDown(e){if(p||m)return;let t=y(e);Ue.flushSync(()=>{l(t)}),t===void 0?c.context.inputRef.current?.focus():u.current[t]?.focus()}},s]}),S=Y.useMemo(()=>({index:v}),[v]);return(0,Q.jsx)(Ye.Provider,{value:S,children:x})});Ze.displayName=`ComboboxChip`;var Qe=Y.forwardRef(function(e,t){let{render:n,className:i,disabled:a=!1,nativeButton:o=!0,style:s,...l}=e,u=U(),{index:d}=Xe(),f=u.useState(`disabled`),p=u.useState(`readOnly`),m=u.useState(`selectedValue`),h=u.useState(`isItemEqualToValue`),g=f||a,{buttonRef:y,getButtonProps:x}=ie({native:o,disabled:g||p,focusableWhenDisabled:!0}),S={disabled:g};function C(e){let t=u.state.activeIndex;if(t==null)return;let n=he(u.context.valuesRef.current,e,h);n!==-1&&t===n&&u.context.setIndices({activeIndex:null,type:u.context.keyboardActiveRef.current?A:c})}function w(e){let t=_(v,e.nativeEvent),n=m[d];return C(n),u.context.setSelectedValue(m.filter((e,t)=>t!==d),t),u.context.inputRef.current?.focus(),t}return b(`button`,e,{ref:[t,y],state:S,props:[{tabIndex:-1,onMouseDown(e){e.preventDefault()},onClick(e){w(e).isPropagationAllowed||e.stopPropagation()},onKeyDown(e){(e.key===`Enter`||e.key===` `)&&(w(e).isPropagationAllowed||r(e))}},l,x]})});Qe.displayName=`ComboboxChipRemove`;function $e(e,t){let{getValue:n,getLabel:r}=t,i=null;function a(){if(i===null){let t=new Map,r=e?B(e):C;for(let e of r){if(e==null)continue;let r=n(e);t.has(r)?ae(`Two items passed to createItems() derived the value ${String(r)}, so selection and label resolution cannot tell them apart: the first item wins the label and every item carrying the value renders as selected. Return a unique value from \`getValue\`.`):t.set(r,e)}i=t}return i}function o(e){return e==null?e:n(e)}return{data:e,value:o,hasValue(e,t){return K(a(),e,t)!==void 0},itemLabel:r,label(e,t,n){let i=K(a(),e,t);return i===void 0?me(e,n):r(i)}}}var et=Y.createContext(void 0);et.displayName=`ComboboxPortalContext`;function tt(){let e=Y.useContext(et);if(e===void 0)throw Error(`Base UI: <Combobox.Portal> is missing.`);return e}var nt=Y.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,i=U(),a=i.useState(`mounted`),o=i.useState(`forceMounted`);return a||n||o?(0,Q.jsx)(et.Provider,{value:n,children:(0,Q.jsx)(s,{ref:t,...r})}):null});nt.displayName=`ComboboxPortal`;var rt=Y.forwardRef(function(e,t){let{render:n,className:r,anchor:i,positionMethod:a,side:s,align:c,sideOffset:l,alignOffset:u,collisionBoundary:d=`clipping-ancestors`,collisionPadding:f,arrowPadding:p,sticky:m,disableAnchorTracking:g=!1,collisionAvoidance:_=o,style:v,...y}=e,b=U(),x=J(),S=tt(),C=b.useState(`modal`),w=b.useState(`open`),E=b.useState(`mounted`),D=b.useState(`openMethod`),O=b.useState(`positionerElement`),k=b.useState(`triggerElement`),A=b.useState(`inputElement`),j=b.useState(`inputGroupElement`),M=b.useState(`inputInsidePopup`),N=b.useState(`transitionStatus`),P=G(),F=ee({anchor:i??(M?k:j??A),floatingRootContext:x,positionMethod:a,mounted:E,side:s,sideOffset:l,align:c,alignOffset:u,arrowPadding:p,collisionBoundary:d,collisionPadding:f,sticky:m,disableAnchorTracking:g,keepMounted:S,collisionAvoidance:_,lazyFlip:!0});Re(w&&C,D===`touch`,O,k);let L={open:w,side:F.side,align:F.align,anchorHidden:F.anchorHidden,empty:P};T(()=>{b.set(`popupSide`,F.side)},[b,F.side]);let ne=h(e=>{b.set(`positionerElement`,e)}),R=I(e,L,{styles:F.positionerStyles,transitionStatus:N,props:y,refs:[t,ne],hidden:!E,inert:!w});return(0,Q.jsxs)(Se.Provider,{value:F,children:[E&&C&&(0,Q.jsx)(de,{inert:te(!w),cutout:j??A??k}),R]})});rt.displayName=`ComboboxPositioner`;var it={...j,...u},at=Y.forwardRef(function(e,t){let{render:r,className:i,style:a,initialFocus:o,finalFocus:s,...c}=e,l=U(),u=W(),d=J(),f=l.useState(`mounted`),m=l.useState(`open`),h=l.useState(`openMethod`),g=l.useState(`popupProps`),_=l.useState(`transitionStatus`),v=l.useState(`inputInsidePopup`),y=l.useState(`inputElement`),x=l.useState(`modal`),S=l.useState(`id`),C=G(),w=c.id??(v?De(S):void 0);T(()=>(l.set(`popupId`,l.context.popupRef.current?.id||w),()=>{l.set(`popupId`,void 0)}),[l,w]),n({open:m,ref:l.context.popupRef,onComplete(){m&&l.context.onOpenChangeComplete(!0)}});let E={open:m,side:u.side,align:u.align,anchorHidden:u.anchorHidden,transitionStatus:_,empty:C},O=b(`div`,e,{state:E,ref:[t,l.context.popupRef],props:[g,{id:w,role:v?`dialog`:`presentation`,onFocus(e){let t=D(e.nativeEvent);h!==`touch`&&(p(l.state.listElement,t)||t===e.currentTarget)&&l.context.inputRef.current?.focus()}},F(_),c],stateAttributesMapping:it}),k=o===void 0?v?e=>e===`touch`?l.context.popupRef.current:y:!1:o,A;A=s??(v?void 0:!1);let j=!v||x;return(0,Q.jsx)(ue,{context:d,disabled:!f,modal:j,openInteractionType:h,initialFocus:k,returnFocus:A,getInsideElements:()=>[l.context.startDismissRef.current,l.context.endDismissRef.current],children:(0,Q.jsxs)(Y.Fragment,{children:[O,j&&(0,Q.jsx)(xe,{ref:l.context.endDismissRef})]})})});at.displayName=`ComboboxPopup`,ce.size;var $=(0,Y.createContext)({size:`base`,hasError:!1});function ot({label:e,required:t,labelTooltip:n,description:r,error:i,children:a,size:o=`base`,...s}){let c=(0,Q.jsx)($.Provider,{value:{size:o,hasError:!!i},children:(0,Q.jsx)(We,{...s,required:t,children:a})});return e?(0,Q.jsx)(le,{label:e,required:t,labelTooltip:n,description:r,error:i?typeof i==`string`?{message:i,match:!0}:i:void 0,children:c}):c}function st({children:e,className:n,align:r=`start`,sideOffset:i=4,alignOffset:a,side:o,anchor:s,positionMethod:c,collisionAvoidance:l,collisionBoundary:u,collisionPadding:d,sticky:f,disableAnchorTracking:p,container:m}){let h=x();return(0,Q.jsx)(nt,{container:m??h??void 0,children:(0,Q.jsx)(rt,{className:``,align:r,sideOffset:i,alignOffset:a,side:o,anchor:s,positionMethod:c,collisionAvoidance:l,collisionBoundary:u,collisionPadding:d,sticky:f,disableAnchorTracking:p,children:(0,Q.jsx)(at,{className:t(`flex flex-col`,`max-h-[min(var(--available-height),24rem)] max-w-(--available-width) min-w-(--anchor-width) py-1.5`,`bg-kumo-base text-kumo-default`,`rounded-lg shadow-lg ring ring-kumo-line`,n),children:e})})})}var ct={xs:{padding:`pe-5`,iconSize:12,iconRight:`end-1`},sm:{padding:`pe-6`,iconSize:14,iconRight:`end-1.5`},base:{padding:`pe-8`,iconSize:16,iconRight:`end-2`},lg:{padding:`pe-10`,iconSize:18,iconRight:`end-3`}};function lt({className:e,render:n,...r}){let{size:i,hasError:a}=(0,Y.useContext)($),o=ct[i];return(0,Q.jsxs)(X,{"data-kumo-component":`Combobox`,"data-kumo-part":`trigger`,render:n,className:t(z({size:i,variant:a?`error`:`default`}),`relative flex items-center`,`data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50`,`data-[placeholder]:text-kumo-placeholder`,o.padding,e),children:[(0,Q.jsx)(Ge,{...r}),(0,Q.jsx)(Z,{className:t(`absolute top-1/2 flex -translate-y-1/2 items-center text-kumo-subtle`,o.iconRight),children:(0,Q.jsx)(L,{size:o.iconSize,className:`fill-current`})})]})}var ut={xs:{padding:`pe-7`,iconSize:12,clearRight:`end-5`,caretRight:`end-1`},sm:{padding:`pe-9`,iconSize:14,clearRight:`end-6`,caretRight:`end-1.5`},base:{padding:`pe-12`,iconSize:16,clearRight:`end-8`,caretRight:`end-2`},lg:{padding:`pe-14`,iconSize:18,clearRight:`end-9`,caretRight:`end-3`}};function dt({clearLabel:e=`Clear selection`,showOptionsLabel:n=`Show options`,...r}){let{size:i,hasError:a}=(0,Y.useContext)($),o=ut[i];return(0,Q.jsxs)(`div`,{className:t(`relative inline-block w-full`,`has-[:disabled]:cursor-not-allowed has-[:disabled]:opacity-50`,r.className),children:[(0,Q.jsx)(q,{...r,className:t(z({size:i,variant:a?`error`:`default`}),`w-full`,o.padding,`disabled:cursor-not-allowed`)}),(0,Q.jsx)(He,{"data-kumo-component":`Combobox`,"data-kumo-part":`clear`,"aria-label":e,className:t(`absolute top-1/2 flex -translate-y-1/2 cursor-pointer bg-transparent p-0`,`data-[disabled]:pointer-events-none data-[disabled]:opacity-0`,o.clearRight),children:(0,Q.jsx)(ze,{size:o.iconSize})}),(0,Q.jsx)(X,{"data-kumo-component":`Combobox`,"data-kumo-part":`trigger`,"aria-label":n,className:t(`absolute top-1/2 flex -translate-y-1/2 cursor-pointer items-center justify-center text-kumo-subtle`,`m-0 bg-transparent p-0`,o.caretRight),children:(0,Q.jsx)(Z,{className:`flex items-center`,children:(0,Q.jsx)(L,{size:o.iconSize,className:`fill-current`})})})]})}function ft({children:e,className:n,...r}){return(0,Q.jsxs)(Ee,{"data-kumo-component":`Combobox`,"data-kumo-part":`item`,...r,className:t(`group mx-1.5 grid grid-cols-[1fr_16px] gap-2 rounded px-2 py-1.5 text-base`,`cursor-pointer data-highlighted:bg-kumo-tint`,`data-[disabled]:cursor-not-allowed data-[disabled]:text-kumo-subtle data-[disabled]:opacity-60 data-[disabled]:data-highlighted:bg-transparent`,n),children:[(0,Q.jsx)(`div`,{className:`col-start-1`,children:e}),(0,Q.jsx)(Ke,{className:`col-start-2 flex items-center`,children:(0,Q.jsx)(R,{})})]})}function pt(e){return(0,Q.jsx)(Te,{...e,className:t(`mx-1.5 shrink-0 px-4 py-2 text-[0.925rem] leading-4 text-kumo-subtle empty:m-0 empty:p-0`),children:e.children??`No labels found.`})}function mt(e){return(0,Q.jsx)(q,{...e,className:t(z(),`mx-0 -mt-1.5 w-full shrink-0 rounded-b-none first:mb-2`,e.className)})}function ht({className:e,...n}){return(0,Q.jsx)(Ne,{...n,className:t(`min-h-0 flex-1 scroll-pt-2 scroll-pb-2 overflow-y-auto overscroll-contain`,e)})}function gt(e){return(0,Q.jsx)(ke,{...e,className:t(`mx-1.5 px-2 py-1.5 text-sm text-kumo-subtle`,e.className)})}function _t(e){return(0,Q.jsx)(ye,{...e,className:`mt-2 border-t border-kumo-hairline pt-2 first:mt-0 first:border-t-0 first:pt-0`})}function vt({removeLabel:e=`Remove`,...n}){return(0,Q.jsxs)(Ze,{...n,className:t(`flex items-center gap-2.5`,`h-6 pe-[3px] ps-2`,`rounded-sm ring-1 ring-kumo-hairline`,`bg-kumo-overlay`,`text-sm`),children:[n.children,(0,Q.jsx)(Qe,{"data-kumo-component":`Combobox`,"data-kumo-part":`chip-remove`,"aria-label":e,className:t(`cursor-pointer rounded-md p-1 hover:bg-kumo-fill-hover`,`flex bg-transparent`),children:(0,Q.jsx)(ze,{size:10})})]})}var yt={xs:`min-h-5`,sm:`min-h-6.5`,base:`min-h-9`,lg:`min-h-10`};function bt({placeholder:e,renderItem:n,className:r,inputSide:i=`right`,value:a}){let{size:o,hasError:s}=(0,Y.useContext)($),c=a,l=t=>(0,Q.jsx)(q,{placeholder:e,className:t});return(0,Q.jsxs)(Je,{className:t(z({size:o,variant:s?`error`:`default`}),`flex flex-col`,`gap-1 px-1.5 py-1`,yt[o],`h-auto`,`data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50`,r),children:[i===`top`&&l(`w-full border-0 bg-inherit px-2 py-1`),(0,Q.jsxs)(`div`,{className:`flex flex-1 flex-wrap items-center gap-1.5`,children:[c!==void 0&&c.length>0&&c.map(e=>n(e)),(0,Q.jsx)(Ge,{children:e=>c===void 0?(0,Q.jsx)(Y.Fragment,{children:e.map(e=>n(e))}):null}),i===`right`&&l(`min-w-[100px] flex-1 border-0 bg-inherit px-2 py-1`)]})]})}ot.displayName=`Combobox.Root`,st.displayName=`Combobox.Content`,lt.displayName=`Combobox.TriggerValue`,dt.displayName=`Combobox.TriggerInput`,ft.displayName=`Combobox.Item`,vt.displayName=`Combobox.Chip`,bt.displayName=`Combobox.TriggerMultipleWithInput`;var xt=Object.assign(ot,{Content:st,TriggerValue:lt,TriggerInput:dt,TriggerMultipleWithInput:bt,Chip:vt,Item:ft,Input:mt,Empty:pt,GroupLabel:gt,Group:_t,List:ht,Collection:je,Trigger:X,Value:Ge,Icon:Z,useFilter:Pe,createItems:$e});export{rt as i,at as n,nt as r,xt as t};
2
- //# sourceMappingURL=combobox-hdxtsm2gqcxxgfju-BzzDlvd3.js.map
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t}from"./IconBase.es-BZDpYMnj.js";import{C as n,Cn as r,Dn as i,Dt as a,I as o,L as s,Ot as c,St as l,Tn as u,Tt as d,Un as f,Ut as p,an as m,at as h,b as g,ct as _,dt as v,ft as y,gr as b,ir as x,j as S,or as C,r as w,rr as T,sr as E,tn as D,ut as O,vn as k,wt as A,yn as j}from"./useBaseUiId-lg1teubxudgin0w2-CrAc3DRu.js";import{i as M,n as N,r as P}from"./react-CDCuUAOg.js";import{_ as ee,g as F,v as I}from"./button-pa1bq9b85hawg41a-BcGpLLER.js";import{t as te}from"./inertValue-e0o6qvuef83v78fk-DAETOorM.js";import{i as L,n as ne}from"./resolveAriaLabelledBy-nc8mdie5shy87nsb-asx42i8W.js";import{g as R}from"./skeleton-line-m9dyh126t9k07jvg-CHsT8Hs3.js";import{l as re,n as ie,u as ae,v as oe,y as se}from"./useButton-h7s9aq1sfw6arawe-BbWTOEat.js";import{n as ce,o as le,r as z}from"./input-c8lv9ulv0kortliq-Cum0c7P1.js";import{n as ue,r as de,t as fe}from"./useClick-l0p0endoxrlp0ae5-Bbq8u-IC.js";import{a as B,f as pe,m as me,r as he,u as ge}from"./resolveValueLabel-hpmsash3ektitvnb-X_gYut6U.js";import{d as V,u as H}from"./composite-ab8dmdfoj6tmhcn1-DBTnwEaq.js";import{C as U,E as _e,S as W,T as G,_ as ve,a as ye,b as be,c as xe,d as Se,f as K,g as Ce,h as we,i as Te,l as Ee,m as De,n as Oe,o as ke,p as Ae,r as je,s as q,t as Me,u as Ne,v as Pe,x as Fe,y as J}from"./ComboboxEmpty-o0q20j2l2syar9kx-Bf-42bzQ.js";import{a as Ie,i as Le,r as Re}from"./ToolbarRootContext-eqk40r8uh4h6r211-DBIMpkd1.js";import{P as ze}from"./index-DWzjnrnl.js";var Y=e(M(),1);function Be(e,t,n,r){if(e.baseUIHandlerPrevented)return;let i=D(e.nativeEvent),a=f(i)?i:null;(a===e.currentTarget||!r?.(a)&&!m(a))&&(e.preventDefault(),!n&&(t.context.inputRef.current?.focus(),t.state.openOnInputClick&&t.context.setOpen(!0,_(l,e.nativeEvent))))}var X=Y.forwardRef(function(e,t){let{render:n,className:i,nativeButton:o=!0,disabled:s=!1,id:c,style:l,...u}=e,{state:f,disabled:m,setTouched:g,setFocused:v,validationMode:y,validation:x}=oe(),{labelId:C}=se(),w=U(),T=w.useState(`selectionMode`),E=w.useState(`disabled`),A=w.useState(`readOnly`),j=w.useState(`required`),M=w.useState(`positionerElement`),N=w.useState(`listElement`),P=w.useState(`popupId`),ee=w.useState(`triggerProps`),F=w.useState(`inputInsidePopup`),I=w.useState(`id`),te=w.useState(`labelId`),L=w.useState(`open`),R=w.useState(`selectedValue`),ae=w.useState(`activeIndex`),ce=w.useState(`selectedIndex`),le=w.useState(`hasSelectedValue`),z=J(),ue=be(),de=S(),B=m||E||s,pe=G(),me=_e(w);re({id:F?c:void 0});let he=F?c??I:c,ge=ne(C,te),V;L&&F?V=P??De(I):L&&(V=N?.id);let H=Y.useRef(``);function W(e){H.current=e.pointerType}let{reference:ve}=Ie(z,{enabled:!L&&!A&&!E&&T===`single`,listRef:w.context.labelsRef,activeIndex:ae,selectedIndex:ce,onMatch(e){let t=w.context.valuesRef.current[e];t!==void 0&&w.context.setSelectedValue(t,_(a))}}),{reference:ye}=fe(z,{enabled:!E,event:`mousedown`}),{buttonRef:xe,getButtonProps:Se}=ie({native:o,disabled:B}),K={...f,readOnly:A,open:L,disabled:B,popupSide:me,listEmpty:pe,placeholder:T!==`none`&&!le},we=h(e=>{w.set(`triggerElement`,e)});return b(`button`,e,{ref:[t,xe,we],state:K,props:[ee,ye,ve,{id:he,tabIndex:F?0:-1,role:F?`combobox`:void 0,"aria-expanded":L,"aria-haspopup":F?`dialog`:`listbox`,"aria-controls":V,"aria-required":F&&j||void 0,"aria-readonly":F&&A||void 0,"aria-labelledby":ge,onPointerDown:W,onPointerEnter:W,onFocus(){v(!0),!B&&de.start(0,w.context.forceMount)},onBlur(e){if(!p(M,e.relatedTarget)&&(g(!0),v(!1),y===`onBlur`)){let e=T===`none`?ue:R;x.commit(e)}},onMouseDown(e){if(B||(F||z.set(`domReferenceElement`,e.currentTarget),w.context.forceMount(),H.current!==`touch`&&(w.context.inputRef.current?.focus(),F||e.preventDefault()),L))return;let t=k(e.currentTarget);function n(e){let t=w.state.triggerElement;if(!t)return;let n=D(e),r=w.state.positionerElement,i=w.state.listElement;p(t,n)||p(r,n)||p(i,n)||Le(e,t)||w.context.setOpen(!1,_(O,e))}F&&t.addEventListener(`mouseup`,n,{once:!0})},onKeyDown(e){(e.key===`ArrowDown`||e.key===`ArrowUp`)&&(r(e),w.context.setOpen(!0,_(d,e.nativeEvent)),w.context.inputRef.current?.focus())}},x.getValidationProps(B,u),Se],stateAttributesMapping:Ce})});X.displayName=`ComboboxTrigger`;var Z=Y.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e;return b(`span`,e,{ref:t,props:[{"aria-hidden":!0,children:`▼`},a]})});Z.displayName=`ComboboxIcon`;var Ve={...u,...i},He=Y.forwardRef(function(e,t){let{render:r,className:i,disabled:a=!1,nativeButton:o=!0,keepMounted:s=!1,style:l,...u}=e,{disabled:d}=oe(),f=U(),p=f.useState(`selectionMode`),m=f.useState(`disabled`),h=f.useState(`readOnly`),v=f.useState(`open`),x=f.useState(`selectedValue`),S=f.useState(`hasSelectionChips`),C=be(),w=!1;w=p===`none`?C!==``:p===`single`?x!=null:S;let T=d||m||a,{buttonRef:E,getButtonProps:D}=ie({native:o,disabled:T}),{mounted:O,transitionStatus:k,setMounted:j}=g(w),M={disabled:T,visible:w,open:v,transitionStatus:k};n({open:w,ref:f.context.clearRef,onComplete(){w||j(!1)}});let N=b(`button`,e,{state:M,ref:[t,E,f.context.clearRef],props:[{tabIndex:-1,children:`x`,onMouseDown(e){e.preventDefault()},onClick(e){if(T||h)return;let t=f.context.keyboardActiveRef.current?A:c;f.context.setInputValue(``,_(y,e.nativeEvent)),p===`none`?f.context.setIndices({activeIndex:null,type:t}):(f.context.setSelectedValue(Array.isArray(x)?[]:null,_(y,e.nativeEvent)),f.context.setIndices({activeIndex:null,selectedIndex:null,type:t})),f.context.inputRef.current?.focus()}},u,D],stateAttributesMapping:Ve});return s||O?N:null});He.displayName=`ComboboxClear`;var Q=P(),Ue=e(N(),1);function We(e){let{multiple:t=!1,defaultValue:n,value:r,onValueChange:i,autoComplete:a,...o}=e;return(0,Q.jsx)(Me,{...o,selectionMode:t?`multiple`:`single`,selectedValue:r,defaultSelectedValue:n,onSelectedValueChange:i,formAutoComplete:a})}function Ge(e){let{children:t,placeholder:n}=e,r=U(),i=r.useState(`itemToStringLabel`),a=r.useState(`selectedValue`),o=r.useState(`items`),s=r.useState(`selectionMode`)===`multiple`,c=r.useState(`hasSelectedValue`),l=!c&&n!=null&&t==null,u=r.useState(`hasNullItemLabel`,l),d=null;return d=typeof t==`function`?t(a):t??(!c&&n!=null&&!u?n:s&&Array.isArray(a)?ge(a,o,i):pe(a,o,i)),(0,Q.jsx)(Y.Fragment,{children:d})}var Ke=Y.forwardRef(function(e,t){let{selected:n}=Fe();return e.keepMounted||n?(0,Q.jsx)(qe,{...e,ref:t}):null});Ke.displayName=`ComboboxItemIndicator`;var qe=Y.memo(Y.forwardRef((e,t)=>{let{render:r,className:i,style:a,keepMounted:o,...s}=e,{selected:c}=Fe(),l=Y.useRef(null),{transitionStatus:d,setMounted:f}=g(c),p=b(`span`,e,{ref:[t,l],state:{selected:c,transitionStatus:d},props:[{"aria-hidden":!0,children:`✔️`},s],stateAttributesMapping:u});return n({batch:!0,enabled:!c,open:c,ref:l,onComplete(){c||f(!1)}}),p}));qe.displayName=`Inner`;var Je=Y.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e,o=U(),s=o.useState(`open`),c=o.useState(`hasSelectionChips`),[l,u]=Y.useState(void 0);s&&l!==void 0&&u(void 0);let d=Y.useRef([]),f=b(`div`,e,{ref:[t,o.context.chipsContainerRef],props:[c?{role:`toolbar`}:E,{onMouseDown(e){Be(e,o,o.state.disabled)}},a]}),p=Y.useMemo(()=>({highlightedChipIndex:l,setHighlightedChipIndex:u,chipsRef:d}),[l,u,d]);return(0,Q.jsx)(Oe.Provider,{value:p,children:(0,Q.jsx)(V,{elementsRef:d,children:f})})});Je.displayName=`ComboboxChips`;var Ye=Y.createContext(void 0);Ye.displayName=`ComboboxChipContext`;function Xe(){let e=Y.useContext(Ye);if(!e)throw Error(`Base UI: ComboboxChipContext is missing. ComboboxChip parts must be placed within <Combobox.Chip>.`);return e}var Ze=Y.forwardRef(function(e,t){let{render:n,className:i,style:o,...s}=e,c=U(),{setHighlightedChipIndex:l,chipsRef:u}=ve(),f=w(),p=c.useState(`disabled`),m=c.useState(`readOnly`),h=c.useState(`selectedValue`),{ref:g,index:v}=H();function y(e){let t=v,[n,i]=Ae(f);return e.key===n?(e.preventDefault(),t=v>0?v-1:void 0):e.key===i?(e.preventDefault(),t=v<u.current.length-1?v+1:void 0):e.key===`Backspace`||e.key===`Delete`?(t=we(v,h.length),r(e),c.context.setIndices({activeIndex:null,selectedIndex:null,type:A}),c.context.setSelectedValue(h.filter((e,t)=>t!==v),_(a,e.nativeEvent))):e.key===`Enter`||e.key===` `?(r(e),t=void 0):e.key===`ArrowDown`||e.key===`ArrowUp`?(r(e),c.context.setOpen(!0,_(d,e.nativeEvent)),t=void 0):e.key.length===1&&!e.ctrlKey&&!e.metaKey&&!e.altKey&&(t=void 0),t}let x=b(`div`,e,{ref:[t,g],state:{disabled:p},props:[{tabIndex:-1,"aria-disabled":p||void 0,"aria-readonly":m||void 0,onKeyDown(e){if(p||m)return;let t=y(e);Ue.flushSync(()=>{l(t)}),t===void 0?c.context.inputRef.current?.focus():u.current[t]?.focus()}},s]}),S=Y.useMemo(()=>({index:v}),[v]);return(0,Q.jsx)(Ye.Provider,{value:S,children:x})});Ze.displayName=`ComboboxChip`;var Qe=Y.forwardRef(function(e,t){let{render:n,className:i,disabled:a=!1,nativeButton:o=!0,style:s,...l}=e,u=U(),{index:d}=Xe(),f=u.useState(`disabled`),p=u.useState(`readOnly`),m=u.useState(`selectedValue`),h=u.useState(`isItemEqualToValue`),g=f||a,{buttonRef:y,getButtonProps:x}=ie({native:o,disabled:g||p,focusableWhenDisabled:!0}),S={disabled:g};function C(e){let t=u.state.activeIndex;if(t==null)return;let n=he(u.context.valuesRef.current,e,h);n!==-1&&t===n&&u.context.setIndices({activeIndex:null,type:u.context.keyboardActiveRef.current?A:c})}function w(e){let t=_(v,e.nativeEvent),n=m[d];return C(n),u.context.setSelectedValue(m.filter((e,t)=>t!==d),t),u.context.inputRef.current?.focus(),t}return b(`button`,e,{ref:[t,y],state:S,props:[{tabIndex:-1,onMouseDown(e){e.preventDefault()},onClick(e){w(e).isPropagationAllowed||e.stopPropagation()},onKeyDown(e){(e.key===`Enter`||e.key===` `)&&(w(e).isPropagationAllowed||r(e))}},l,x]})});Qe.displayName=`ComboboxChipRemove`;function $e(e,t){let{getValue:n,getLabel:r}=t,i=null;function a(){if(i===null){let t=new Map,r=e?B(e):C;for(let e of r){if(e==null)continue;let r=n(e);t.has(r)?ae(`Two items passed to createItems() derived the value ${String(r)}, so selection and label resolution cannot tell them apart: the first item wins the label and every item carrying the value renders as selected. Return a unique value from \`getValue\`.`):t.set(r,e)}i=t}return i}function o(e){return e==null?e:n(e)}return{data:e,value:o,hasValue(e,t){return K(a(),e,t)!==void 0},itemLabel:r,label(e,t,n){let i=K(a(),e,t);return i===void 0?me(e,n):r(i)}}}var et=Y.createContext(void 0);et.displayName=`ComboboxPortalContext`;function tt(){let e=Y.useContext(et);if(e===void 0)throw Error(`Base UI: <Combobox.Portal> is missing.`);return e}var nt=Y.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,i=U(),a=i.useState(`mounted`),o=i.useState(`forceMounted`);return a||n||o?(0,Q.jsx)(et.Provider,{value:n,children:(0,Q.jsx)(s,{ref:t,...r})}):null});nt.displayName=`ComboboxPortal`;var rt=Y.forwardRef(function(e,t){let{render:n,className:r,anchor:i,positionMethod:a,side:s,align:c,sideOffset:l,alignOffset:u,collisionBoundary:d=`clipping-ancestors`,collisionPadding:f,arrowPadding:p,sticky:m,disableAnchorTracking:g=!1,collisionAvoidance:_=o,style:v,...y}=e,b=U(),x=J(),S=tt(),C=b.useState(`modal`),w=b.useState(`open`),E=b.useState(`mounted`),D=b.useState(`openMethod`),O=b.useState(`positionerElement`),k=b.useState(`triggerElement`),A=b.useState(`inputElement`),j=b.useState(`inputGroupElement`),M=b.useState(`inputInsidePopup`),N=b.useState(`transitionStatus`),P=G(),F=ee({anchor:i??(M?k:j??A),floatingRootContext:x,positionMethod:a,mounted:E,side:s,sideOffset:l,align:c,alignOffset:u,arrowPadding:p,collisionBoundary:d,collisionPadding:f,sticky:m,disableAnchorTracking:g,keepMounted:S,collisionAvoidance:_,lazyFlip:!0});Re(w&&C,D===`touch`,O,k);let L={open:w,side:F.side,align:F.align,anchorHidden:F.anchorHidden,empty:P};T(()=>{b.set(`popupSide`,F.side)},[b,F.side]);let ne=h(e=>{b.set(`positionerElement`,e)}),R=I(e,L,{styles:F.positionerStyles,transitionStatus:N,props:y,refs:[t,ne],hidden:!E,inert:!w});return(0,Q.jsxs)(Se.Provider,{value:F,children:[E&&C&&(0,Q.jsx)(de,{inert:te(!w),cutout:j??A??k}),R]})});rt.displayName=`ComboboxPositioner`;var it={...j,...u},at=Y.forwardRef(function(e,t){let{render:r,className:i,style:a,initialFocus:o,finalFocus:s,...c}=e,l=U(),u=W(),d=J(),f=l.useState(`mounted`),m=l.useState(`open`),h=l.useState(`openMethod`),g=l.useState(`popupProps`),_=l.useState(`transitionStatus`),v=l.useState(`inputInsidePopup`),y=l.useState(`inputElement`),x=l.useState(`modal`),S=l.useState(`id`),C=G(),w=c.id??(v?De(S):void 0);T(()=>(l.set(`popupId`,l.context.popupRef.current?.id||w),()=>{l.set(`popupId`,void 0)}),[l,w]),n({open:m,ref:l.context.popupRef,onComplete(){m&&l.context.onOpenChangeComplete(!0)}});let E={open:m,side:u.side,align:u.align,anchorHidden:u.anchorHidden,transitionStatus:_,empty:C},O=b(`div`,e,{state:E,ref:[t,l.context.popupRef],props:[g,{id:w,role:v?`dialog`:`presentation`,onFocus(e){let t=D(e.nativeEvent);h!==`touch`&&(p(l.state.listElement,t)||t===e.currentTarget)&&l.context.inputRef.current?.focus()}},F(_),c],stateAttributesMapping:it}),k=o===void 0?v?e=>e===`touch`?l.context.popupRef.current:y:!1:o,A;A=s??(v?void 0:!1);let j=!v||x;return(0,Q.jsx)(ue,{context:d,disabled:!f,modal:j,openInteractionType:h,initialFocus:k,returnFocus:A,getInsideElements:()=>[l.context.startDismissRef.current,l.context.endDismissRef.current],children:(0,Q.jsxs)(Y.Fragment,{children:[O,j&&(0,Q.jsx)(xe,{ref:l.context.endDismissRef})]})})});at.displayName=`ComboboxPopup`,ce.size;var $=(0,Y.createContext)({size:`base`,hasError:!1});function ot({label:e,required:t,labelTooltip:n,description:r,error:i,children:a,size:o=`base`,...s}){let c=(0,Q.jsx)($.Provider,{value:{size:o,hasError:!!i},children:(0,Q.jsx)(We,{...s,required:t,children:a})});return e?(0,Q.jsx)(le,{label:e,required:t,labelTooltip:n,description:r,error:i?typeof i==`string`?{message:i,match:!0}:i:void 0,children:c}):c}function st({children:e,className:n,align:r=`start`,sideOffset:i=4,alignOffset:a,side:o,anchor:s,positionMethod:c,collisionAvoidance:l,collisionBoundary:u,collisionPadding:d,sticky:f,disableAnchorTracking:p,container:m}){let h=x();return(0,Q.jsx)(nt,{container:m??h??void 0,children:(0,Q.jsx)(rt,{className:``,align:r,sideOffset:i,alignOffset:a,side:o,anchor:s,positionMethod:c,collisionAvoidance:l,collisionBoundary:u,collisionPadding:d,sticky:f,disableAnchorTracking:p,children:(0,Q.jsx)(at,{className:t(`flex flex-col`,`max-h-[min(var(--available-height),24rem)] max-w-(--available-width) min-w-(--anchor-width) py-1.5`,`bg-kumo-base text-kumo-default`,`rounded-lg shadow-lg ring ring-kumo-line`,n),children:e})})})}var ct={xs:{padding:`pe-5`,iconSize:12,iconRight:`end-1`},sm:{padding:`pe-6`,iconSize:14,iconRight:`end-1.5`},base:{padding:`pe-8`,iconSize:16,iconRight:`end-2`},lg:{padding:`pe-10`,iconSize:18,iconRight:`end-3`}};function lt({className:e,render:n,...r}){let{size:i,hasError:a}=(0,Y.useContext)($),o=ct[i];return(0,Q.jsxs)(X,{"data-kumo-component":`Combobox`,"data-kumo-part":`trigger`,render:n,className:t(z({size:i,variant:a?`error`:`default`}),`relative flex items-center`,`data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50`,`data-[placeholder]:text-kumo-placeholder`,o.padding,e),children:[(0,Q.jsx)(Ge,{...r}),(0,Q.jsx)(Z,{className:t(`absolute top-1/2 flex -translate-y-1/2 items-center text-kumo-subtle`,o.iconRight),children:(0,Q.jsx)(L,{size:o.iconSize,className:`fill-current`})})]})}var ut={xs:{padding:`pe-7`,iconSize:12,clearRight:`end-5`,caretRight:`end-1`},sm:{padding:`pe-9`,iconSize:14,clearRight:`end-6`,caretRight:`end-1.5`},base:{padding:`pe-12`,iconSize:16,clearRight:`end-8`,caretRight:`end-2`},lg:{padding:`pe-14`,iconSize:18,clearRight:`end-9`,caretRight:`end-3`}};function dt({clearLabel:e=`Clear selection`,showOptionsLabel:n=`Show options`,...r}){let{size:i,hasError:a}=(0,Y.useContext)($),o=ut[i];return(0,Q.jsxs)(`div`,{className:t(`relative inline-block w-full`,`has-[:disabled]:cursor-not-allowed has-[:disabled]:opacity-50`,r.className),children:[(0,Q.jsx)(q,{...r,className:t(z({size:i,variant:a?`error`:`default`}),`w-full`,o.padding,`disabled:cursor-not-allowed`)}),(0,Q.jsx)(He,{"data-kumo-component":`Combobox`,"data-kumo-part":`clear`,"aria-label":e,className:t(`absolute top-1/2 flex -translate-y-1/2 cursor-pointer bg-transparent p-0`,`data-[disabled]:pointer-events-none data-[disabled]:opacity-0`,o.clearRight),children:(0,Q.jsx)(ze,{size:o.iconSize})}),(0,Q.jsx)(X,{"data-kumo-component":`Combobox`,"data-kumo-part":`trigger`,"aria-label":n,className:t(`absolute top-1/2 flex -translate-y-1/2 cursor-pointer items-center justify-center text-kumo-subtle`,`m-0 bg-transparent p-0`,o.caretRight),children:(0,Q.jsx)(Z,{className:`flex items-center`,children:(0,Q.jsx)(L,{size:o.iconSize,className:`fill-current`})})})]})}function ft({children:e,className:n,...r}){return(0,Q.jsxs)(Ee,{"data-kumo-component":`Combobox`,"data-kumo-part":`item`,...r,className:t(`group mx-1.5 grid grid-cols-[1fr_16px] gap-2 rounded px-2 py-1.5 text-base`,`cursor-pointer data-highlighted:bg-kumo-tint`,`data-[disabled]:cursor-not-allowed data-[disabled]:text-kumo-subtle data-[disabled]:opacity-60 data-[disabled]:data-highlighted:bg-transparent`,n),children:[(0,Q.jsx)(`div`,{className:`col-start-1`,children:e}),(0,Q.jsx)(Ke,{className:`col-start-2 flex items-center`,children:(0,Q.jsx)(R,{})})]})}function pt(e){return(0,Q.jsx)(Te,{...e,className:t(`mx-1.5 shrink-0 px-4 py-2 text-[0.925rem] leading-4 text-kumo-subtle empty:m-0 empty:p-0`),children:e.children??`No labels found.`})}function mt(e){return(0,Q.jsx)(q,{...e,className:t(z(),`mx-0 -mt-1.5 w-full shrink-0 rounded-b-none first:mb-2`,e.className)})}function ht({className:e,...n}){return(0,Q.jsx)(Ne,{...n,className:t(`min-h-0 flex-1 scroll-pt-2 scroll-pb-2 overflow-y-auto overscroll-contain`,e)})}function gt(e){return(0,Q.jsx)(ke,{...e,className:t(`mx-1.5 px-2 py-1.5 text-sm text-kumo-subtle`,e.className)})}function _t(e){return(0,Q.jsx)(ye,{...e,className:`mt-2 border-t border-kumo-hairline pt-2 first:mt-0 first:border-t-0 first:pt-0`})}function vt({removeLabel:e=`Remove`,...n}){return(0,Q.jsxs)(Ze,{...n,className:t(`flex items-center gap-2.5`,`h-6 pe-[3px] ps-2`,`rounded-sm ring-1 ring-kumo-hairline`,`bg-kumo-overlay`,`text-sm`),children:[n.children,(0,Q.jsx)(Qe,{"data-kumo-component":`Combobox`,"data-kumo-part":`chip-remove`,"aria-label":e,className:t(`cursor-pointer rounded-md p-1 hover:bg-kumo-fill-hover`,`flex bg-transparent`),children:(0,Q.jsx)(ze,{size:10})})]})}var yt={xs:`min-h-5`,sm:`min-h-6.5`,base:`min-h-9`,lg:`min-h-10`};function bt({placeholder:e,renderItem:n,className:r,inputSide:i=`right`,value:a}){let{size:o,hasError:s}=(0,Y.useContext)($),c=a,l=t=>(0,Q.jsx)(q,{placeholder:e,className:t});return(0,Q.jsxs)(Je,{className:t(z({size:o,variant:s?`error`:`default`}),`flex flex-col`,`gap-1 px-1.5 py-1`,yt[o],`h-auto`,`data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50`,r),children:[i===`top`&&l(`w-full border-0 bg-inherit px-2 py-1`),(0,Q.jsxs)(`div`,{className:`flex flex-1 flex-wrap items-center gap-1.5`,children:[c!==void 0&&c.length>0&&c.map(e=>n(e)),(0,Q.jsx)(Ge,{children:e=>c===void 0?(0,Q.jsx)(Y.Fragment,{children:e.map(e=>n(e))}):null}),i===`right`&&l(`min-w-[100px] flex-1 border-0 bg-inherit px-2 py-1`)]})]})}ot.displayName=`Combobox.Root`,st.displayName=`Combobox.Content`,lt.displayName=`Combobox.TriggerValue`,dt.displayName=`Combobox.TriggerInput`,ft.displayName=`Combobox.Item`,vt.displayName=`Combobox.Chip`,bt.displayName=`Combobox.TriggerMultipleWithInput`;var xt=Object.assign(ot,{Content:st,TriggerValue:lt,TriggerInput:dt,TriggerMultipleWithInput:bt,Chip:vt,Item:ft,Input:mt,Empty:pt,GroupLabel:gt,Group:_t,List:ht,Collection:je,Trigger:X,Value:Ge,Icon:Z,useFilter:Pe,createItems:$e});export{rt as i,at as n,nt as r,xt as t};
2
+ //# sourceMappingURL=combobox-hdxtsm2gqcxxgfju-DXYGsrSK.js.map