buckaroo-js-core 0.8.5 → 0.11.7

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 (244) hide show
  1. package/LICENSE +24 -12
  2. package/README.md +55 -51
  3. package/dist/index.cjs.js +114 -0
  4. package/dist/index.cjs.js.map +1 -0
  5. package/dist/index.es.js +60790 -0
  6. package/dist/index.es.js.map +1 -0
  7. package/dist/index.esm.js +60790 -0
  8. package/dist/index.esm.js.map +1 -0
  9. package/dist/jest.setup.d.ts +0 -0
  10. package/dist/src/SampleComponent.d.ts +10 -0
  11. package/{buckaroo_js → dist/src}/baked_data/colorMap.d.ts +0 -1
  12. package/dist/src/baked_data/olympic-winners.d.ts +12 -0
  13. package/dist/src/components/BuckarooInfiniteWidget.flash.test.d.ts +1 -0
  14. package/dist/src/components/BuckarooStaticTable.d.ts +26 -0
  15. package/dist/src/components/BuckarooWidgetInfinite.d.ts +38 -0
  16. package/{buckaroo_js → dist/src}/components/ColumnsEditor.d.ts +5 -8
  17. package/{buckaroo_js → dist/src}/components/CommandUtils.d.ts +8 -5
  18. package/dist/src/components/DCFCell.d.ts +19 -0
  19. package/dist/src/components/DFViewerParts/ChartCell.d.ts +43 -0
  20. package/dist/src/components/DFViewerParts/DFViewerConfigs.d.ts +5 -0
  21. package/dist/src/components/DFViewerParts/DFViewerDataHelper.d.ts +20 -0
  22. package/dist/src/components/DFViewerParts/DFViewerInfinite.d.ts +43 -0
  23. package/dist/src/components/DFViewerParts/DFViewerInfinite.flash.test.d.ts +1 -0
  24. package/dist/src/components/DFViewerParts/DFViewerInfinite.test.d.ts +1 -0
  25. package/dist/src/components/DFViewerParts/DFWhole.d.ts +173 -0
  26. package/{buckaroo_js → dist/src}/components/DFViewerParts/Displayer.d.ts +20 -5
  27. package/dist/src/components/DFViewerParts/HistogramCell.d.ts +29 -0
  28. package/dist/src/components/DFViewerParts/HistogramCell.hooks.test.d.ts +1 -0
  29. package/dist/src/components/DFViewerParts/OtherRenderers.d.ts +5 -0
  30. package/dist/src/components/DFViewerParts/RowCache.d.ts +61 -0
  31. package/dist/src/components/DFViewerParts/RowCache.test.d.ts +1 -0
  32. package/dist/src/components/DFViewerParts/RowStore.d.ts +22 -0
  33. package/dist/src/components/DFViewerParts/RowStore.test.d.ts +1 -0
  34. package/dist/src/components/DFViewerParts/RowStoreGc.d.ts +22 -0
  35. package/dist/src/components/DFViewerParts/RowStoreGc.test.d.ts +1 -0
  36. package/dist/src/components/DFViewerParts/SeriesSummaryTooltip.d.ts +13 -0
  37. package/dist/src/components/DFViewerParts/SmartRowCache.d.ts +83 -0
  38. package/dist/src/components/DFViewerParts/SmartRowCache.test.d.ts +23 -0
  39. package/dist/src/components/DFViewerParts/Styler.d.ts +33 -0
  40. package/dist/src/components/DFViewerParts/TableInfinite.d.ts +10 -0
  41. package/dist/src/components/DFViewerParts/ViewRegistry.d.ts +21 -0
  42. package/dist/src/components/DFViewerParts/ViewRegistry.test.d.ts +1 -0
  43. package/dist/src/components/DFViewerParts/Views.d.ts +53 -0
  44. package/dist/src/components/DFViewerParts/Views.test.d.ts +1 -0
  45. package/dist/src/components/DFViewerParts/autocleaning.toggle.integration.test.d.ts +27 -0
  46. package/dist/src/components/DFViewerParts/gridUtils.d.ts +81 -0
  47. package/dist/src/components/DFViewerParts/gridUtils.test.d.ts +1 -0
  48. package/dist/src/components/DFViewerParts/resolveDFData.d.ts +29 -0
  49. package/dist/src/components/DFViewerParts/resolveDFData.test.d.ts +1 -0
  50. package/dist/src/components/DFViewerParts/xorqWindow.dom.test.d.ts +1 -0
  51. package/dist/src/components/DFViewerParts/xorqWindow.test.d.ts +1 -0
  52. package/{buckaroo_js → dist/src}/components/DependentTabs.d.ts +8 -13
  53. package/dist/src/components/MessageBox.d.ts +8 -0
  54. package/{buckaroo_js → dist/src}/components/OperationDetail.d.ts +4 -6
  55. package/dist/src/components/OperationExamples.d.ts +8 -0
  56. package/{buckaroo_js → dist/src}/components/OperationUtils.d.ts +1 -1
  57. package/dist/src/components/Operations.d.ts +14 -0
  58. package/dist/src/components/Operations.test.d.ts +4 -0
  59. package/dist/src/components/OperationsList.d.ts +9 -0
  60. package/dist/src/components/OperationsList.test.d.ts +0 -0
  61. package/dist/src/components/StatusBar.d.ts +15 -0
  62. package/{buckaroo_js → dist/src}/components/WidgetTypes.d.ts +3 -4
  63. package/dist/src/components/useColorScheme.d.ts +7 -0
  64. package/dist/src/components/utils.d.ts +299 -0
  65. package/dist/src/index.d.ts +59 -0
  66. package/dist/src/stories/BuckarooWidgetTest.stories.d.ts +12 -0
  67. package/dist/src/stories/ChartCell.stories.d.ts +20 -0
  68. package/dist/src/stories/ColumnsEditor.stories.d.ts +17 -0
  69. package/dist/src/stories/DFViewer.stories.d.ts +26 -0
  70. package/dist/src/stories/DFViewerInfiniteRaw.stories.d.ts +24 -0
  71. package/dist/src/stories/DFViewerInfiniteShadow.stories.d.ts +31 -0
  72. package/dist/src/stories/HistogramCell.stories.d.ts +18 -0
  73. package/dist/src/stories/InheritEdgeCases.stories.d.ts +12 -0
  74. package/dist/src/stories/InheritPinnedRows.stories.d.ts +13 -0
  75. package/dist/src/stories/MessageBox.stories.d.ts +26 -0
  76. package/dist/src/stories/OperationViewer.stories.d.ts +24 -0
  77. package/dist/src/stories/OperationsList.stories.d.ts +19 -0
  78. package/dist/src/stories/OutsideParamsInconsistency.stories.d.ts +16 -0
  79. package/dist/src/stories/PinnedRowsDynamic.stories.d.ts +12 -0
  80. package/dist/src/stories/PinnedRowsRace.stories.d.ts +12 -0
  81. package/dist/src/stories/PinnedRowsTranscriptReplayer.stories.d.ts +13 -0
  82. package/dist/src/stories/RawAGGrid.stories.d.ts +17 -0
  83. package/dist/src/stories/SmallDFScroll.stories.d.ts +11 -0
  84. package/dist/src/stories/StatusBar.stories.d.ts +19 -0
  85. package/dist/src/stories/StoryUtils.d.ts +13 -0
  86. package/dist/src/stories/Styling.stories.d.ts +15 -0
  87. package/dist/src/stories/StylingIssues.stories.d.ts +54 -0
  88. package/dist/src/stories/ThemeCustomization.stories.d.ts +22 -0
  89. package/dist/src/stories/UseMemoExamples.stories.d.ts +12 -0
  90. package/dist/src/stories/WeirdTypes.stories.d.ts +17 -0
  91. package/dist/src/test-utils/agGridSpy.d.ts +50 -0
  92. package/dist/src/widgetUtils.d.ts +1 -0
  93. package/dist/style.css +1 -0
  94. package/package.json +109 -98
  95. package/.prettierrc +0 -16
  96. package/CHANGELOG.md +0 -23
  97. package/buckaroo_js/baked_data/colorMap.d.ts.map +0 -1
  98. package/buckaroo_js/baked_data/colorMap.js +0 -520
  99. package/buckaroo_js/baked_data/colorMap.js.map +0 -1
  100. package/buckaroo_js/baked_data/staticData.d.ts +0 -124
  101. package/buckaroo_js/baked_data/staticData.d.ts.map +0 -1
  102. package/buckaroo_js/baked_data/staticData.js +0 -459
  103. package/buckaroo_js/baked_data/staticData.js.map +0 -1
  104. package/buckaroo_js/components/ColumnsEditor.d.ts.map +0 -1
  105. package/buckaroo_js/components/ColumnsEditor.js +0 -68
  106. package/buckaroo_js/components/ColumnsEditor.js.map +0 -1
  107. package/buckaroo_js/components/CommandUtils.d.ts.map +0 -1
  108. package/buckaroo_js/components/CommandUtils.js +0 -17
  109. package/buckaroo_js/components/CommandUtils.js.map +0 -1
  110. package/buckaroo_js/components/DCFCell.d.ts +0 -28
  111. package/buckaroo_js/components/DCFCell.d.ts.map +0 -1
  112. package/buckaroo_js/components/DCFCell.js +0 -120
  113. package/buckaroo_js/components/DCFCell.js.map +0 -1
  114. package/buckaroo_js/components/DFViewerParts/DFViewer.d.ts +0 -29
  115. package/buckaroo_js/components/DFViewerParts/DFViewer.d.ts.map +0 -1
  116. package/buckaroo_js/components/DFViewerParts/DFViewer.js +0 -163
  117. package/buckaroo_js/components/DFViewerParts/DFViewer.js.map +0 -1
  118. package/buckaroo_js/components/DFViewerParts/DFWhole.d.ts +0 -111
  119. package/buckaroo_js/components/DFViewerParts/DFWhole.d.ts.map +0 -1
  120. package/buckaroo_js/components/DFViewerParts/DFWhole.js +0 -17
  121. package/buckaroo_js/components/DFViewerParts/DFWhole.js.map +0 -1
  122. package/buckaroo_js/components/DFViewerParts/Displayer.d.ts.map +0 -1
  123. package/buckaroo_js/components/DFViewerParts/Displayer.js +0 -220
  124. package/buckaroo_js/components/DFViewerParts/Displayer.js.map +0 -1
  125. package/buckaroo_js/components/DFViewerParts/HistogramCell.d.ts +0 -20
  126. package/buckaroo_js/components/DFViewerParts/HistogramCell.d.ts.map +0 -1
  127. package/buckaroo_js/components/DFViewerParts/HistogramCell.js +0 -184
  128. package/buckaroo_js/components/DFViewerParts/HistogramCell.js.map +0 -1
  129. package/buckaroo_js/components/DFViewerParts/OtherRenderers.d.ts +0 -7
  130. package/buckaroo_js/components/DFViewerParts/OtherRenderers.d.ts.map +0 -1
  131. package/buckaroo_js/components/DFViewerParts/OtherRenderers.js +0 -29
  132. package/buckaroo_js/components/DFViewerParts/OtherRenderers.js.map +0 -1
  133. package/buckaroo_js/components/DFViewerParts/SeriesSummaryTooltip.d.ts +0 -5
  134. package/buckaroo_js/components/DFViewerParts/SeriesSummaryTooltip.d.ts.map +0 -1
  135. package/buckaroo_js/components/DFViewerParts/SeriesSummaryTooltip.js +0 -18
  136. package/buckaroo_js/components/DFViewerParts/SeriesSummaryTooltip.js.map +0 -1
  137. package/buckaroo_js/components/DFViewerParts/gridUtils.d.ts +0 -24
  138. package/buckaroo_js/components/DFViewerParts/gridUtils.d.ts.map +0 -1
  139. package/buckaroo_js/components/DFViewerParts/gridUtils.js +0 -230
  140. package/buckaroo_js/components/DFViewerParts/gridUtils.js.map +0 -1
  141. package/buckaroo_js/components/DependentTabs.d.ts.map +0 -1
  142. package/buckaroo_js/components/DependentTabs.js +0 -108
  143. package/buckaroo_js/components/DependentTabs.js.map +0 -1
  144. package/buckaroo_js/components/OperationDetail.d.ts.map +0 -1
  145. package/buckaroo_js/components/OperationDetail.js +0 -144
  146. package/buckaroo_js/components/OperationDetail.js.map +0 -1
  147. package/buckaroo_js/components/OperationUtils.d.ts.map +0 -1
  148. package/buckaroo_js/components/OperationUtils.js +0 -14
  149. package/buckaroo_js/components/OperationUtils.js.map +0 -1
  150. package/buckaroo_js/components/Operations.d.ts +0 -24
  151. package/buckaroo_js/components/Operations.d.ts.map +0 -1
  152. package/buckaroo_js/components/Operations.js +0 -209
  153. package/buckaroo_js/components/Operations.js.map +0 -1
  154. package/buckaroo_js/components/StatusBar.d.ts +0 -12
  155. package/buckaroo_js/components/StatusBar.d.ts.map +0 -1
  156. package/buckaroo_js/components/StatusBar.js +0 -155
  157. package/buckaroo_js/components/StatusBar.js.map +0 -1
  158. package/buckaroo_js/components/WidgetTypes.d.ts.map +0 -1
  159. package/buckaroo_js/components/WidgetTypes.js +0 -3
  160. package/buckaroo_js/components/WidgetTypes.js.map +0 -1
  161. package/buckaroo_js/components/bakedOperationDefaults.d.ts +0 -5
  162. package/buckaroo_js/components/bakedOperationDefaults.d.ts.map +0 -1
  163. package/buckaroo_js/components/bakedOperationDefaults.js +0 -15
  164. package/buckaroo_js/components/bakedOperationDefaults.js.map +0 -1
  165. package/buckaroo_js/components/utils.d.ts +0 -294
  166. package/buckaroo_js/components/utils.d.ts.map +0 -1
  167. package/buckaroo_js/components/utils.js +0 -143
  168. package/buckaroo_js/components/utils.js.map +0 -1
  169. package/buckaroo_js/extension.d.ts +0 -2
  170. package/buckaroo_js/extension.d.ts.map +0 -1
  171. package/buckaroo_js/extension.js +0 -20
  172. package/buckaroo_js/extension.js.map +0 -1
  173. package/buckaroo_js/index.d.ts +0 -24
  174. package/buckaroo_js/index.d.ts.map +0 -1
  175. package/buckaroo_js/index.js +0 -44
  176. package/buckaroo_js/index.js.map +0 -1
  177. package/buckaroo_js/vendor/RechartExtra.d.ts +0 -38
  178. package/buckaroo_js/vendor/RechartExtra.d.ts.map +0 -1
  179. package/buckaroo_js/vendor/RechartExtra.js +0 -17
  180. package/buckaroo_js/vendor/RechartExtra.js.map +0 -1
  181. package/buckaroo_js/vendor/RechartTooltip.d.ts +0 -82
  182. package/buckaroo_js/vendor/RechartTooltip.d.ts.map +0 -1
  183. package/buckaroo_js/vendor/RechartTooltip.js +0 -231
  184. package/buckaroo_js/vendor/RechartTooltip.js.map +0 -1
  185. package/codecov.yml +0 -16
  186. package/eslint.config.mjs +0 -88
  187. package/examples/App.tsx +0 -160
  188. package/examples/CodeBlock.tsx +0 -27
  189. package/examples/CodePenButton.tsx +0 -72
  190. package/examples/ReadmeBlock.tsx +0 -11
  191. package/examples/app.css +0 -29
  192. package/examples/ex/ColumnsEditorEx.tsx +0 -5
  193. package/examples/ex/CommandViewerEx.tsx +0 -18
  194. package/examples/ex/DFViewerEx.tsx +0 -3
  195. package/examples/ex/DFViewerEx_large.tsx +0 -266
  196. package/examples/ex/DFViewerEx_real_summary.tsx +0 -18
  197. package/examples/ex/DFViewerEx_short_data.tsx +0 -22
  198. package/examples/ex/DFViewerEx_string_index.tsx +0 -1012
  199. package/examples/ex/HistogramEx.tsx +0 -41
  200. package/examples/ex/StatusBarEx.tsx +0 -46
  201. package/examples/ex/WidgetDCFCellEx.tsx +0 -6
  202. package/examples/example.css +0 -20
  203. package/examples/index-iframe.hnottml +0 -24
  204. package/examples/index-react18.tsx +0 -8
  205. package/examples/index.html +0 -20
  206. package/examples/jsx-loader.ts +0 -16
  207. package/examples/tsconfig.json +0 -31
  208. package/index.d.ts +0 -2
  209. package/index.d.ts.map +0 -1
  210. package/index.js +0 -7
  211. package/index.js.map +0 -1
  212. package/jest.config.js +0 -24
  213. package/screen-animation.gif +0 -0
  214. package/src/buckaroo_js/baked_data/colorMap.ts +0 -523
  215. package/src/buckaroo_js/baked_data/staticData.ts +0 -503
  216. package/src/buckaroo_js/components/ColumnsEditor.tsx +0 -66
  217. package/src/buckaroo_js/components/CommandUtils.ts +0 -40
  218. package/src/buckaroo_js/components/DCFCell.tsx +0 -175
  219. package/src/buckaroo_js/components/DFViewerParts/DFViewer.tsx +0 -215
  220. package/src/buckaroo_js/components/DFViewerParts/DFWhole.ts +0 -190
  221. package/src/buckaroo_js/components/DFViewerParts/Displayer.ts +0 -218
  222. package/src/buckaroo_js/components/DFViewerParts/OtherRenderers.tsx +0 -28
  223. package/src/buckaroo_js/components/DFViewerParts/SeriesSummaryTooltip.tsx +0 -20
  224. package/src/buckaroo_js/components/DFViewerParts/gridUtils.ts +0 -291
  225. package/src/buckaroo_js/components/DependentTabs.tsx +0 -134
  226. package/src/buckaroo_js/components/OperationDetail.tsx +0 -203
  227. package/src/buckaroo_js/components/OperationUtils.ts +0 -33
  228. package/src/buckaroo_js/components/Operations.tsx +0 -243
  229. package/src/buckaroo_js/components/StatusBar.tsx +0 -190
  230. package/src/buckaroo_js/components/WidgetTypes.tsx +0 -42
  231. package/src/buckaroo_js/components/bakedOperationDefaults.ts +0 -14
  232. package/src/buckaroo_js/components/utils.ts +0 -60
  233. package/src/buckaroo_js/extension.ts +0 -15
  234. package/src/buckaroo_js/index.ts +0 -32
  235. package/src/buckaroo_js/style/dcf-npm.css +0 -244
  236. package/src/buckaroo_js/style/icons/arrow-down-short-dark.svg +0 -4
  237. package/src/buckaroo_js/style/icons/arrow-down-short.svg +0 -4
  238. package/src/buckaroo_js/style/icons/arrow-up-short-dark.svg +0 -4
  239. package/src/buckaroo_js/style/icons/arrow-up-short.svg +0 -4
  240. package/src/buckaroo_js/style/icons/filter-dark.svg +0 -3
  241. package/src/buckaroo_js/style/icons/filter.svg +0 -3
  242. package/src/index.tsx +0 -3
  243. package/tsconfig.json +0 -41
  244. package/webpack.config.ts +0 -98
@@ -0,0 +1,114 @@
1
+ "use strict";var FE=Object.defineProperty;var OE=(e,t,r)=>t in e?FE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var vt=(e,t,r)=>OE(e,typeof t!="symbol"?t+"":t,r);Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const M=require("react/jsx-runtime"),v=require("react"),ma=require("react-dom");var Vw=typeof global=="object"&&global&&global.Object===Object&&global,ME=typeof self=="object"&&self&&self.Object===Object&&self,Pr=Vw||ME||Function("return this")(),Jt=Pr.Symbol,Uw=Object.prototype,DE=Uw.hasOwnProperty,kE=Uw.toString,zo=Jt?Jt.toStringTag:void 0;function IE(e){var t=DE.call(e,zo),r=e[zo];try{e[zo]=void 0;var n=!0}catch{}var i=kE.call(e);return n&&(t?e[zo]=r:delete e[zo]),i}var _E=Object.prototype,LE=_E.toString;function BE(e){return LE.call(e)}var zE="[object Null]",NE="[object Undefined]",Nm=Jt?Jt.toStringTag:void 0;function Rr(e){return e==null?e===void 0?NE:zE:Nm&&Nm in Object(e)?IE(e):BE(e)}function Nt(e){return e!=null&&typeof e=="object"}var $E="[object Symbol]";function Zc(e){return typeof e=="symbol"||Nt(e)&&Rr(e)==$E}function Qc(e,t){for(var r=-1,n=e==null?0:e.length,i=Array(n);++r<n;)i[r]=t(e[r],r,e);return i}var He=Array.isArray,$m=Jt?Jt.prototype:void 0,Hm=$m?$m.toString:void 0;function Kw(e){if(typeof e=="string")return e;if(He(e))return Qc(e,Kw)+"";if(Zc(e))return Hm?Hm.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var HE=/\s/;function GE(e){for(var t=e.length;t--&&HE.test(e.charAt(t)););return t}var WE=/^\s+/;function jE(e){return e&&e.slice(0,GE(e)+1).replace(WE,"")}function Ft(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Gm=NaN,VE=/^[-+]0x[0-9a-f]+$/i,UE=/^0b[01]+$/i,KE=/^0o[0-7]+$/i,qE=parseInt;function YE(e){if(typeof e=="number")return e;if(Zc(e))return Gm;if(Ft(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Ft(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=jE(e);var r=UE.test(e);return r||KE.test(e)?qE(e.slice(2),r?2:8):VE.test(e)?Gm:+e}var Wm=1/0,JE=17976931348623157e292;function XE(e){if(!e)return e===0?e:0;if(e=YE(e),e===Wm||e===-Wm){var t=e<0?-1:1;return t*JE}return e===e?e:0}function qw(e){var t=XE(e),r=t%1;return t===t?r?t-r:t:0}function eu(e){return e}var ZE="[object AsyncFunction]",QE="[object Function]",eT="[object GeneratorFunction]",tT="[object Proxy]";function _g(e){if(!Ft(e))return!1;var t=Rr(e);return t==QE||t==eT||t==ZE||t==tT}var rd=Pr["__core-js_shared__"],jm=function(){var e=/[^.]+$/.exec(rd&&rd.keys&&rd.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function rT(e){return!!jm&&jm in e}var nT=Function.prototype,iT=nT.toString;function ti(e){if(e!=null){try{return iT.call(e)}catch{}try{return e+""}catch{}}return""}var oT=/[\\^$.*+?()[\]{}|]/g,sT=/^\[object .+?Constructor\]$/,aT=Function.prototype,lT=Object.prototype,cT=aT.toString,uT=lT.hasOwnProperty,dT=RegExp("^"+cT.call(uT).replace(oT,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function hT(e){if(!Ft(e)||rT(e))return!1;var t=_g(e)?dT:sT;return t.test(ti(e))}function fT(e,t){return e==null?void 0:e[t]}function ri(e,t){var r=fT(e,t);return hT(r)?r:void 0}var yh=ri(Pr,"WeakMap"),Vm=Object.create,gT=function(){function e(){}return function(t){if(!Ft(t))return{};if(Vm)return Vm(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();function pT(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function mT(){}function Yw(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var vT=800,yT=16,bT=Date.now;function CT(e){var t=0,r=0;return function(){var n=bT(),i=yT-(n-r);if(r=n,i>0){if(++t>=vT)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function wT(e){return function(){return e}}var Pl=function(){try{var e=ri(Object,"defineProperty");return e({},"",{}),e}catch{}}(),ST=Pl?function(e,t){return Pl(e,"toString",{configurable:!0,enumerable:!1,value:wT(t),writable:!0})}:eu,xT=CT(ST);function AT(e,t){for(var r=-1,n=e==null?0:e.length;++r<n&&t(e[r],r,e)!==!1;);return e}function Jw(e,t,r,n){for(var i=e.length,o=r+-1;++o<i;)if(t(e[o],o,e))return o;return-1}function PT(e){return e!==e}function RT(e,t,r){for(var n=r-1,i=e.length;++n<i;)if(e[n]===t)return n;return-1}function Lg(e,t,r){return t===t?RT(e,t,r):Jw(e,PT,r)}function Xw(e,t){var r=e==null?0:e.length;return!!r&&Lg(e,t,0)>-1}var ET=9007199254740991,TT=/^(?:0|[1-9]\d*)$/;function tu(e,t){var r=typeof e;return t=t??ET,!!t&&(r=="number"||r!="symbol"&&TT.test(e))&&e>-1&&e%1==0&&e<t}function Bg(e,t,r){t=="__proto__"&&Pl?Pl(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function va(e,t){return e===t||e!==e&&t!==t}var FT=Object.prototype,OT=FT.hasOwnProperty;function ru(e,t,r){var n=e[t];(!(OT.call(e,t)&&va(n,r))||r===void 0&&!(t in e))&&Bg(e,t,r)}function ya(e,t,r,n){var i=!r;r||(r={});for(var o=-1,s=t.length;++o<s;){var a=t[o],l=void 0;l===void 0&&(l=e[a]),i?Bg(r,a,l):ru(r,a,l)}return r}var Um=Math.max;function MT(e,t,r){return t=Um(t===void 0?e.length-1:t,0),function(){for(var n=arguments,i=-1,o=Um(n.length-t,0),s=Array(o);++i<o;)s[i]=n[t+i];i=-1;for(var a=Array(t+1);++i<t;)a[i]=n[i];return a[t]=r(s),pT(e,this,a)}}function zg(e,t){return xT(MT(e,t,eu),e+"")}var DT=9007199254740991;function Ng(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=DT}function un(e){return e!=null&&Ng(e.length)&&!_g(e)}function kT(e,t,r){if(!Ft(r))return!1;var n=typeof t;return(n=="number"?un(r)&&tu(t,r.length):n=="string"&&t in r)?va(r[t],e):!1}function IT(e){return zg(function(t,r){var n=-1,i=r.length,o=i>1?r[i-1]:void 0,s=i>2?r[2]:void 0;for(o=e.length>3&&typeof o=="function"?(i--,o):void 0,s&&kT(r[0],r[1],s)&&(o=i<3?void 0:o,i=1),t=Object(t);++n<i;){var a=r[n];a&&e(t,a,n,o)}return t})}var _T=Object.prototype;function $g(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||_T;return e===r}function LT(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var BT="[object Arguments]";function Km(e){return Nt(e)&&Rr(e)==BT}var Zw=Object.prototype,zT=Zw.hasOwnProperty,NT=Zw.propertyIsEnumerable,vs=Km(function(){return arguments}())?Km:function(e){return Nt(e)&&zT.call(e,"callee")&&!NT.call(e,"callee")};function $T(){return!1}var Qw=typeof exports=="object"&&exports&&!exports.nodeType&&exports,qm=Qw&&typeof module=="object"&&module&&!module.nodeType&&module,HT=qm&&qm.exports===Qw,Ym=HT?Pr.Buffer:void 0,GT=Ym?Ym.isBuffer:void 0,ys=GT||$T,WT="[object Arguments]",jT="[object Array]",VT="[object Boolean]",UT="[object Date]",KT="[object Error]",qT="[object Function]",YT="[object Map]",JT="[object Number]",XT="[object Object]",ZT="[object RegExp]",QT="[object Set]",eF="[object String]",tF="[object WeakMap]",rF="[object ArrayBuffer]",nF="[object DataView]",iF="[object Float32Array]",oF="[object Float64Array]",sF="[object Int8Array]",aF="[object Int16Array]",lF="[object Int32Array]",cF="[object Uint8Array]",uF="[object Uint8ClampedArray]",dF="[object Uint16Array]",hF="[object Uint32Array]",Me={};Me[iF]=Me[oF]=Me[sF]=Me[aF]=Me[lF]=Me[cF]=Me[uF]=Me[dF]=Me[hF]=!0;Me[WT]=Me[jT]=Me[rF]=Me[VT]=Me[nF]=Me[UT]=Me[KT]=Me[qT]=Me[YT]=Me[JT]=Me[XT]=Me[ZT]=Me[QT]=Me[eF]=Me[tF]=!1;function fF(e){return Nt(e)&&Ng(e.length)&&!!Me[Rr(e)]}function nu(e){return function(t){return e(t)}}var e2=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ns=e2&&typeof module=="object"&&module&&!module.nodeType&&module,gF=ns&&ns.exports===e2,nd=gF&&Vw.process,ln=function(){try{var e=ns&&ns.require&&ns.require("util").types;return e||nd&&nd.binding&&nd.binding("util")}catch{}}(),Jm=ln&&ln.isTypedArray,Hg=Jm?nu(Jm):fF,pF=Object.prototype,mF=pF.hasOwnProperty;function t2(e,t){var r=He(e),n=!r&&vs(e),i=!r&&!n&&ys(e),o=!r&&!n&&!i&&Hg(e),s=r||n||i||o,a=s?LT(e.length,String):[],l=a.length;for(var c in e)(t||mF.call(e,c))&&!(s&&(c=="length"||i&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||tu(c,l)))&&a.push(c);return a}function r2(e,t){return function(r){return e(t(r))}}var vF=r2(Object.keys,Object),yF=Object.prototype,bF=yF.hasOwnProperty;function CF(e){if(!$g(e))return vF(e);var t=[];for(var r in Object(e))bF.call(e,r)&&r!="constructor"&&t.push(r);return t}function Xt(e){return un(e)?t2(e):CF(e)}function wF(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var SF=Object.prototype,xF=SF.hasOwnProperty;function AF(e){if(!Ft(e))return wF(e);var t=$g(e),r=[];for(var n in e)n=="constructor"&&(t||!xF.call(e,n))||r.push(n);return r}function ba(e){return un(e)?t2(e,!0):AF(e)}var PF=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,RF=/^\w*$/;function Gg(e,t){if(He(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||Zc(e)?!0:RF.test(e)||!PF.test(e)||t!=null&&e in Object(t)}var bs=ri(Object,"create");function EF(){this.__data__=bs?bs(null):{},this.size=0}function TF(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var FF="__lodash_hash_undefined__",OF=Object.prototype,MF=OF.hasOwnProperty;function DF(e){var t=this.__data__;if(bs){var r=t[e];return r===FF?void 0:r}return MF.call(t,e)?t[e]:void 0}var kF=Object.prototype,IF=kF.hasOwnProperty;function _F(e){var t=this.__data__;return bs?t[e]!==void 0:IF.call(t,e)}var LF="__lodash_hash_undefined__";function BF(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=bs&&t===void 0?LF:t,this}function Gn(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Gn.prototype.clear=EF;Gn.prototype.delete=TF;Gn.prototype.get=DF;Gn.prototype.has=_F;Gn.prototype.set=BF;function zF(){this.__data__=[],this.size=0}function iu(e,t){for(var r=e.length;r--;)if(va(e[r][0],t))return r;return-1}var NF=Array.prototype,$F=NF.splice;function HF(e){var t=this.__data__,r=iu(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():$F.call(t,r,1),--this.size,!0}function GF(e){var t=this.__data__,r=iu(t,e);return r<0?void 0:t[r][1]}function WF(e){return iu(this.__data__,e)>-1}function jF(e,t){var r=this.__data__,n=iu(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function jr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}jr.prototype.clear=zF;jr.prototype.delete=HF;jr.prototype.get=GF;jr.prototype.has=WF;jr.prototype.set=jF;var Cs=ri(Pr,"Map");function VF(){this.size=0,this.__data__={hash:new Gn,map:new(Cs||jr),string:new Gn}}function UF(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function ou(e,t){var r=e.__data__;return UF(t)?r[typeof t=="string"?"string":"hash"]:r.map}function KF(e){var t=ou(this,e).delete(e);return this.size-=t?1:0,t}function qF(e){return ou(this,e).get(e)}function YF(e){return ou(this,e).has(e)}function JF(e,t){var r=ou(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}function Vr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Vr.prototype.clear=VF;Vr.prototype.delete=KF;Vr.prototype.get=qF;Vr.prototype.has=YF;Vr.prototype.set=JF;var XF="Expected a function";function Wg(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(XF);var r=function(){var n=arguments,i=t?t.apply(this,n):n[0],o=r.cache;if(o.has(i))return o.get(i);var s=e.apply(this,n);return r.cache=o.set(i,s)||o,s};return r.cache=new(Wg.Cache||Vr),r}Wg.Cache=Vr;var ZF=500;function QF(e){var t=Wg(e,function(n){return r.size===ZF&&r.clear(),n}),r=t.cache;return t}var eO=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,tO=/\\(\\)?/g,rO=QF(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(eO,function(r,n,i,o){t.push(i?o.replace(tO,"$1"):n||r)}),t});function nO(e){return e==null?"":Kw(e)}function su(e,t){return He(e)?e:Gg(e,t)?[e]:rO(nO(e))}function Ca(e){if(typeof e=="string"||Zc(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function jg(e,t){t=su(t,e);for(var r=0,n=t.length;e!=null&&r<n;)e=e[Ca(t[r++])];return r&&r==n?e:void 0}function ws(e,t,r){var n=e==null?void 0:jg(e,t);return n===void 0?r:n}function Vg(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}var Xm=Jt?Jt.isConcatSpreadable:void 0;function iO(e){return He(e)||vs(e)||!!(Xm&&e&&e[Xm])}function oO(e,t,r,n,i){var o=-1,s=e.length;for(r||(r=iO),i||(i=[]);++o<s;){var a=e[o];r(a)&&Vg(i,a)}return i}var Ug=r2(Object.getPrototypeOf,Object),sO="[object Object]",aO=Function.prototype,lO=Object.prototype,n2=aO.toString,cO=lO.hasOwnProperty,uO=n2.call(Object);function dO(e){if(!Nt(e)||Rr(e)!=sO)return!1;var t=Ug(e);if(t===null)return!0;var r=cO.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&n2.call(r)==uO}function hO(){this.__data__=new jr,this.size=0}function fO(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function gO(e){return this.__data__.get(e)}function pO(e){return this.__data__.has(e)}var mO=200;function vO(e,t){var r=this.__data__;if(r instanceof jr){var n=r.__data__;if(!Cs||n.length<mO-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new Vr(n)}return r.set(e,t),this.size=r.size,this}function lr(e){var t=this.__data__=new jr(e);this.size=t.size}lr.prototype.clear=hO;lr.prototype.delete=fO;lr.prototype.get=gO;lr.prototype.has=pO;lr.prototype.set=vO;function yO(e,t){return e&&ya(t,Xt(t),e)}function bO(e,t){return e&&ya(t,ba(t),e)}var i2=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Zm=i2&&typeof module=="object"&&module&&!module.nodeType&&module,CO=Zm&&Zm.exports===i2,Qm=CO?Pr.Buffer:void 0,ev=Qm?Qm.allocUnsafe:void 0;function o2(e,t){if(t)return e.slice();var r=e.length,n=ev?ev(r):new e.constructor(r);return e.copy(n),n}function s2(e,t){for(var r=-1,n=e==null?0:e.length,i=0,o=[];++r<n;){var s=e[r];t(s,r,e)&&(o[i++]=s)}return o}function a2(){return[]}var wO=Object.prototype,SO=wO.propertyIsEnumerable,tv=Object.getOwnPropertySymbols,Kg=tv?function(e){return e==null?[]:(e=Object(e),s2(tv(e),function(t){return SO.call(e,t)}))}:a2;function xO(e,t){return ya(e,Kg(e),t)}var AO=Object.getOwnPropertySymbols,l2=AO?function(e){for(var t=[];e;)Vg(t,Kg(e)),e=Ug(e);return t}:a2;function PO(e,t){return ya(e,l2(e),t)}function c2(e,t,r){var n=t(e);return He(e)?n:Vg(n,r(e))}function bh(e){return c2(e,Xt,Kg)}function u2(e){return c2(e,ba,l2)}var Ch=ri(Pr,"DataView"),wh=ri(Pr,"Promise"),wi=ri(Pr,"Set"),rv="[object Map]",RO="[object Object]",nv="[object Promise]",iv="[object Set]",ov="[object WeakMap]",sv="[object DataView]",EO=ti(Ch),TO=ti(Cs),FO=ti(wh),OO=ti(wi),MO=ti(yh),or=Rr;(Ch&&or(new Ch(new ArrayBuffer(1)))!=sv||Cs&&or(new Cs)!=rv||wh&&or(wh.resolve())!=nv||wi&&or(new wi)!=iv||yh&&or(new yh)!=ov)&&(or=function(e){var t=Rr(e),r=t==RO?e.constructor:void 0,n=r?ti(r):"";if(n)switch(n){case EO:return sv;case TO:return rv;case FO:return nv;case OO:return iv;case MO:return ov}return t});var DO=Object.prototype,kO=DO.hasOwnProperty;function IO(e){var t=e.length,r=new e.constructor(t);return t&&typeof e[0]=="string"&&kO.call(e,"index")&&(r.index=e.index,r.input=e.input),r}var Rl=Pr.Uint8Array;function qg(e){var t=new e.constructor(e.byteLength);return new Rl(t).set(new Rl(e)),t}function _O(e,t){var r=t?qg(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}var LO=/\w*$/;function BO(e){var t=new e.constructor(e.source,LO.exec(e));return t.lastIndex=e.lastIndex,t}var av=Jt?Jt.prototype:void 0,lv=av?av.valueOf:void 0;function zO(e){return lv?Object(lv.call(e)):{}}function d2(e,t){var r=t?qg(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}var NO="[object Boolean]",$O="[object Date]",HO="[object Map]",GO="[object Number]",WO="[object RegExp]",jO="[object Set]",VO="[object String]",UO="[object Symbol]",KO="[object ArrayBuffer]",qO="[object DataView]",YO="[object Float32Array]",JO="[object Float64Array]",XO="[object Int8Array]",ZO="[object Int16Array]",QO="[object Int32Array]",eM="[object Uint8Array]",tM="[object Uint8ClampedArray]",rM="[object Uint16Array]",nM="[object Uint32Array]";function iM(e,t,r){var n=e.constructor;switch(t){case KO:return qg(e);case NO:case $O:return new n(+e);case qO:return _O(e,r);case YO:case JO:case XO:case ZO:case QO:case eM:case tM:case rM:case nM:return d2(e,r);case HO:return new n;case GO:case VO:return new n(e);case WO:return BO(e);case jO:return new n;case UO:return zO(e)}}function h2(e){return typeof e.constructor=="function"&&!$g(e)?gT(Ug(e)):{}}var oM="[object Map]";function sM(e){return Nt(e)&&or(e)==oM}var cv=ln&&ln.isMap,aM=cv?nu(cv):sM,lM="[object Set]";function cM(e){return Nt(e)&&or(e)==lM}var uv=ln&&ln.isSet,uM=uv?nu(uv):cM,dM=1,hM=2,fM=4,f2="[object Arguments]",gM="[object Array]",pM="[object Boolean]",mM="[object Date]",vM="[object Error]",g2="[object Function]",yM="[object GeneratorFunction]",bM="[object Map]",CM="[object Number]",p2="[object Object]",wM="[object RegExp]",SM="[object Set]",xM="[object String]",AM="[object Symbol]",PM="[object WeakMap]",RM="[object ArrayBuffer]",EM="[object DataView]",TM="[object Float32Array]",FM="[object Float64Array]",OM="[object Int8Array]",MM="[object Int16Array]",DM="[object Int32Array]",kM="[object Uint8Array]",IM="[object Uint8ClampedArray]",_M="[object Uint16Array]",LM="[object Uint32Array]",Fe={};Fe[f2]=Fe[gM]=Fe[RM]=Fe[EM]=Fe[pM]=Fe[mM]=Fe[TM]=Fe[FM]=Fe[OM]=Fe[MM]=Fe[DM]=Fe[bM]=Fe[CM]=Fe[p2]=Fe[wM]=Fe[SM]=Fe[xM]=Fe[AM]=Fe[kM]=Fe[IM]=Fe[_M]=Fe[LM]=!0;Fe[vM]=Fe[g2]=Fe[PM]=!1;function is(e,t,r,n,i,o){var s,a=t&dM,l=t&hM,c=t&fM;if(s!==void 0)return s;if(!Ft(e))return e;var u=He(e);if(u){if(s=IO(e),!a)return Yw(e,s)}else{var d=or(e),h=d==g2||d==yM;if(ys(e))return o2(e,a);if(d==p2||d==f2||h&&!i){if(s=l||h?{}:h2(e),!a)return l?PO(e,bO(s,e)):xO(e,yO(s,e))}else{if(!Fe[d])return i?e:{};s=iM(e,d,a)}}o||(o=new lr);var f=o.get(e);if(f)return f;o.set(e,s),uM(e)?e.forEach(function(p){s.add(is(p,t,r,p,e,o))}):aM(e)&&e.forEach(function(p,y){s.set(y,is(p,t,r,y,e,o))});var g=c?l?u2:bh:l?ba:Xt,m=u?void 0:g(e);return AT(m||e,function(p,y){m&&(y=p,p=e[y]),ru(s,y,is(p,t,r,y,e,o))}),s}var BM=4;function fo(e){return is(e,BM)}var zM=1,NM=4;function $M(e){return is(e,zM|NM)}var HM="__lodash_hash_undefined__";function GM(e){return this.__data__.set(e,HM),this}function WM(e){return this.__data__.has(e)}function ki(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new Vr;++t<r;)this.add(e[t])}ki.prototype.add=ki.prototype.push=GM;ki.prototype.has=WM;function jM(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}function Yg(e,t){return e.has(t)}var VM=1,UM=2;function m2(e,t,r,n,i,o){var s=r&VM,a=e.length,l=t.length;if(a!=l&&!(s&&l>a))return!1;var c=o.get(e),u=o.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,f=r&UM?new ki:void 0;for(o.set(e,t),o.set(t,e);++d<a;){var g=e[d],m=t[d];if(n)var p=s?n(m,g,d,t,e,o):n(g,m,d,e,t,o);if(p!==void 0){if(p)continue;h=!1;break}if(f){if(!jM(t,function(y,w){if(!Yg(f,w)&&(g===y||i(g,y,r,n,o)))return f.push(w)})){h=!1;break}}else if(!(g===m||i(g,m,r,n,o))){h=!1;break}}return o.delete(e),o.delete(t),h}function KM(e){var t=-1,r=Array(e.size);return e.forEach(function(n,i){r[++t]=[i,n]}),r}function Jg(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var qM=1,YM=2,JM="[object Boolean]",XM="[object Date]",ZM="[object Error]",QM="[object Map]",eD="[object Number]",tD="[object RegExp]",rD="[object Set]",nD="[object String]",iD="[object Symbol]",oD="[object ArrayBuffer]",sD="[object DataView]",dv=Jt?Jt.prototype:void 0,id=dv?dv.valueOf:void 0;function aD(e,t,r,n,i,o,s){switch(r){case sD:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case oD:return!(e.byteLength!=t.byteLength||!o(new Rl(e),new Rl(t)));case JM:case XM:case eD:return va(+e,+t);case ZM:return e.name==t.name&&e.message==t.message;case tD:case nD:return e==t+"";case QM:var a=KM;case rD:var l=n&qM;if(a||(a=Jg),e.size!=t.size&&!l)return!1;var c=s.get(e);if(c)return c==t;n|=YM,s.set(e,t);var u=m2(a(e),a(t),n,i,o,s);return s.delete(e),u;case iD:if(id)return id.call(e)==id.call(t)}return!1}var lD=1,cD=Object.prototype,uD=cD.hasOwnProperty;function dD(e,t,r,n,i,o){var s=r&lD,a=bh(e),l=a.length,c=bh(t),u=c.length;if(l!=u&&!s)return!1;for(var d=l;d--;){var h=a[d];if(!(s?h in t:uD.call(t,h)))return!1}var f=o.get(e),g=o.get(t);if(f&&g)return f==t&&g==e;var m=!0;o.set(e,t),o.set(t,e);for(var p=s;++d<l;){h=a[d];var y=e[h],w=t[h];if(n)var b=s?n(w,y,h,t,e,o):n(y,w,h,e,t,o);if(!(b===void 0?y===w||i(y,w,r,n,o):b)){m=!1;break}p||(p=h=="constructor")}if(m&&!p){var x=e.constructor,C=t.constructor;x!=C&&"constructor"in e&&"constructor"in t&&!(typeof x=="function"&&x instanceof x&&typeof C=="function"&&C instanceof C)&&(m=!1)}return o.delete(e),o.delete(t),m}var hD=1,hv="[object Arguments]",fv="[object Array]",Ba="[object Object]",fD=Object.prototype,gv=fD.hasOwnProperty;function gD(e,t,r,n,i,o){var s=He(e),a=He(t),l=s?fv:or(e),c=a?fv:or(t);l=l==hv?Ba:l,c=c==hv?Ba:c;var u=l==Ba,d=c==Ba,h=l==c;if(h&&ys(e)){if(!ys(t))return!1;s=!0,u=!1}if(h&&!u)return o||(o=new lr),s||Hg(e)?m2(e,t,r,n,i,o):aD(e,t,l,r,n,i,o);if(!(r&hD)){var f=u&&gv.call(e,"__wrapped__"),g=d&&gv.call(t,"__wrapped__");if(f||g){var m=f?e.value():e,p=g?t.value():t;return o||(o=new lr),i(m,p,r,n,o)}}return h?(o||(o=new lr),dD(e,t,r,n,i,o)):!1}function au(e,t,r,n,i){return e===t?!0:e==null||t==null||!Nt(e)&&!Nt(t)?e!==e&&t!==t:gD(e,t,r,n,au,i)}var pD=1,mD=2;function vD(e,t,r,n){var i=r.length,o=i;if(e==null)return!o;for(e=Object(e);i--;){var s=r[i];if(s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<o;){s=r[i];var a=s[0],l=e[a],c=s[1];if(s[2]){if(l===void 0&&!(a in e))return!1}else{var u=new lr,d;if(!(d===void 0?au(c,l,pD|mD,n,u):d))return!1}}return!0}function v2(e){return e===e&&!Ft(e)}function yD(e){for(var t=Xt(e),r=t.length;r--;){var n=t[r],i=e[n];t[r]=[n,i,v2(i)]}return t}function y2(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}function bD(e){var t=yD(e);return t.length==1&&t[0][2]?y2(t[0][0],t[0][1]):function(r){return r===e||vD(r,e,t)}}function CD(e,t){return e!=null&&t in Object(e)}function b2(e,t,r){t=su(t,e);for(var n=-1,i=t.length,o=!1;++n<i;){var s=Ca(t[n]);if(!(o=e!=null&&r(e,s)))break;e=e[s]}return o||++n!=i?o:(i=e==null?0:e.length,!!i&&Ng(i)&&tu(s,i)&&(He(e)||vs(e)))}function wD(e,t){return e!=null&&b2(e,t,CD)}var SD=1,xD=2;function AD(e,t){return Gg(e)&&v2(t)?y2(Ca(e),t):function(r){var n=ws(r,e);return n===void 0&&n===t?wD(r,e):au(t,n,SD|xD)}}function PD(e){return function(t){return t==null?void 0:t[e]}}function RD(e){return function(t){return jg(t,e)}}function ED(e){return Gg(e)?PD(Ca(e)):RD(e)}function wa(e){return typeof e=="function"?e:e==null?eu:typeof e=="object"?He(e)?AD(e[0],e[1]):bD(e):ED(e)}function TD(e){return function(t,r,n){for(var i=-1,o=Object(t),s=n(t),a=s.length;a--;){var l=s[++i];if(r(o[l],l,o)===!1)break}return t}}var C2=TD();function FD(e,t){return e&&C2(e,t,Xt)}function OD(e,t){return function(r,n){if(r==null)return r;if(!un(r))return e(r,n);for(var i=r.length,o=-1,s=Object(r);++o<i&&n(s[o],o,s)!==!1;);return r}}var w2=OD(FD);function Sh(e,t,r){(r!==void 0&&!va(e[t],r)||r===void 0&&!(t in e))&&Bg(e,t,r)}function Xg(e){return Nt(e)&&un(e)}function xh(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function MD(e){return ya(e,ba(e))}function DD(e,t,r,n,i,o,s){var a=xh(e,r),l=xh(t,r),c=s.get(l);if(c){Sh(e,r,c);return}var u=o?o(a,l,r+"",e,t,s):void 0,d=u===void 0;if(d){var h=He(l),f=!h&&ys(l),g=!h&&!f&&Hg(l);u=l,h||f||g?He(a)?u=a:Xg(a)?u=Yw(a):f?(d=!1,u=o2(l,!0)):g?(d=!1,u=d2(l,!0)):u=[]:dO(l)||vs(l)?(u=a,vs(a)?u=MD(a):(!Ft(a)||_g(a))&&(u=h2(l))):d=!1}d&&(s.set(l,u),i(u,l,n,o,s),s.delete(l)),Sh(e,r,u)}function S2(e,t,r,n,i){e!==t&&C2(t,function(o,s){if(i||(i=new lr),Ft(o))DD(e,t,s,r,S2,n,i);else{var a=n?n(xh(e,s),o,s+"",e,t,i):void 0;a===void 0&&(a=o),Sh(e,s,a)}},ba)}var kD=200;function ID(e,t,r,n){var i=-1,o=Xw,s=!0,a=e.length,l=[],c=t.length;if(!a)return l;t.length>=kD&&(o=Yg,s=!1,t=new ki(t));e:for(;++i<a;){var u=e[i],d=u;if(u=u!==0?u:0,s&&d===d){for(var h=c;h--;)if(t[h]===d)continue e;l.push(u)}else o(t,d,n)||l.push(u)}return l}function _D(e,t){var r=[];return w2(e,function(n,i,o){t(n,i,o)&&r.push(n)}),r}function LD(e,t){var r=He(e)?s2:_D;return r(e,wa(t))}function BD(e){return function(t,r,n){var i=Object(t);if(!un(t)){var o=wa(r);t=Xt(t),r=function(a){return o(i[a],a,i)}}var s=e(t,r,n);return s>-1?i[o?t[s]:s]:void 0}}var zD=Math.max;function ND(e,t,r){var n=e==null?0:e.length;if(!n)return-1;var i=r==null?0:qw(r);return i<0&&(i=zD(n+i,0)),Jw(e,wa(t),i)}var El=BD(ND);function $D(e,t){var r=-1,n=un(e)?Array(e.length):[];return w2(e,function(i,o,s){n[++r]=t(i,o,s)}),n}function Rt(e,t){var r=He(e)?Qc:$D;return r(e,wa(t))}function x2(e){for(var t=-1,r=e==null?0:e.length,n={};++t<r;){var i=e[t];n[i[0]]=i[1]}return n}var HD=Object.prototype,GD=HD.hasOwnProperty;function WD(e,t){return e!=null&&GD.call(e,t)}function Ss(e,t){return e!=null&&b2(e,t,WD)}var jD="[object String]";function A2(e){return typeof e=="string"||!He(e)&&Nt(e)&&Rr(e)==jD}function VD(e,t){return Qc(t,function(r){return e[r]})}function UD(e){return e==null?[]:VD(e,Xt(e))}var KD=Math.max;function Ii(e,t,r,n){e=un(e)?e:UD(e),r=r?qw(r):0;var i=e.length;return r<0&&(r=KD(i+r,0)),A2(e)?r<=i&&e.indexOf(t,r)>-1:!!i&&Lg(e,t,r)>-1}function P2(e,t,r){var n=e==null?0:e.length;if(!n)return-1;var i=0;return Lg(e,t,i)}var qD="[object Boolean]";function YD(e){return e===!0||e===!1||Nt(e)&&Rr(e)==qD}var JD="[object Date]";function XD(e){return Nt(e)&&Rr(e)==JD}var pv=ln&&ln.isDate,ZD=pv?nu(pv):XD;function QD(e,t){return au(e,t)}function ek(e,t){for(var r,n=-1,i=e.length;++n<i;){var o=t(e[n]);o!==void 0&&(r=r===void 0?o:r+o)}return r}var mv=IT(function(e,t,r){S2(e,t,r)});function tk(e,t,r,n){if(!Ft(e))return e;t=su(t,e);for(var i=-1,o=t.length,s=o-1,a=e;a!=null&&++i<o;){var l=Ca(t[i]),c=r;if(l==="__proto__"||l==="constructor"||l==="prototype")return e;if(i!=s){var u=a[l];c=void 0,c===void 0&&(c=Ft(u)?u:tu(t[i+1])?[]:{})}ru(a,l,c),a=a[l]}return e}function rk(e,t,r){for(var n=-1,i=t.length,o={};++n<i;){var s=t[n],a=jg(e,s);r(a,s)&&tk(o,su(s,e),a)}return o}function nk(e,t){if(e==null)return{};var r=Qc(u2(e),function(n){return[n]});return t=wa(t),rk(e,r,function(n,i){return t(n,i[0])})}function ik(e){return e&&e.length?ek(e,eu):0}var ok=1/0,sk=wi&&1/Jg(new wi([,-0]))[1]==ok?function(e){return new wi(e)}:mT,ak=200;function lk(e,t,r){var n=-1,i=Xw,o=e.length,s=!0,a=[],l=a;if(o>=ak){var c=sk(e);if(c)return Jg(c);s=!1,i=Yg,l=new ki}else l=a;e:for(;++n<o;){var u=e[n],d=u;if(u=u!==0?u:0,s&&d===d){for(var h=l.length;h--;)if(l[h]===d)continue e;a.push(u)}else i(l,d,r)||(l!==a&&l.push(d),a.push(u))}return a}var ck=zg(function(e){return lk(oO(e,1,Xg))}),uk=zg(function(e,t){return Xg(e)?ID(e,t):[]});function dk(e,t,r){for(var n=-1,i=e.length,o=t.length,s={};++n<i;){var a=n<o?t[n]:void 0;r(s,e[n],a)}return s}function hk(e,t){return dk(e||[],t||[],ru)}const fk=(e,t)=>fetch(e).then(async n=>{const i=await n.json();t(i)}),gk=e=>({symbol:e});function R2(e,t,r){return e.map(n=>n===t?r:n)}function E2(e,t,r){return e.map((n,i)=>i===t?r:n)}function T2(e,t,r){const n=fo(e);return n[t]=r,n}const F2=(e,t=[])=>nk(e,r=>![null,void 0,...t].includes(r)),pk=(e,t,r,n)=>e.map(o=>o.field===t?{...o,...r}:{...o,...n}),mk=(e,t,r)=>e.map(i=>i.field===t?{...i,...r}:{...i}),O2=Object.freeze(Object.defineProperty({__proto__:null,objWithoutNull:F2,replaceAtIdx:E2,replaceAtKey:T2,replaceAtMatch:mk,replaceInArr:R2,requestDf:fk,sym:gk,updateAtMatch:pk},Symbol.toStringTag,{value:"Module"})),vk=({command:e,setCommand:t,columns:r,commandPatterns:n})=>{if(e===void 0)return M.jsx("span",{});const i=e[0].symbol,o=n[i];if(He(o)){if(QD(o,[null]))return M.jsx("div",{className:"operation-detail"});{const s=o;return M.jsx("div",{className:"operation-detail",children:M.jsx(yk,{command:e,fullPattern:s,setCommand:t,columns:r})})}}else return M.jsxs("h2",{children:["unknown command ",i]})},yk=({command:e,fullPattern:t,setCommand:r,columns:n})=>{const i=o=>{const s=o[0],a=e[s],l=c=>{const u=E2(e,s,c);r(u)};return M.jsx("div",{children:M.jsx(bk,{argProps:o,renderKey:s,val:a,setter:l,columns:n})},s)};return M.jsx("div",{className:"arg-getters",children:t.map(i)})},bk=({argProps:e,val:t,setter:r,columns:n,renderKey:i})=>{const[o,s,a,l]=e,c=u=>r(u.target.value);if(a==="enum"&&He(l))return M.jsxs("fieldset",{children:[M.jsxs("label",{children:[" ",s," "]}),M.jsx("select",{defaultValue:t,onChange:c,children:l.map(u=>M.jsx("option",{value:u,children:u},u))})]},i);if(a==="type")if(l==="integer"){const u=d=>r(parseInt(d.target.value));return M.jsxs("fieldset",{children:[M.jsxs("label",{children:[" ",s," "]}),M.jsx("input",{type:"number",defaultValue:t,step:"1",onChange:u})]},i)}else if(l==="float"){const u=d=>r(parseFloat(d.target.value));return M.jsxs("fieldset",{children:[M.jsxs("label",{children:[" ",s," "]}),M.jsx("input",{type:"number",step:"0.01",defaultValue:t,onChange:u})]},i)}else if(l==="string"){const u=d=>r(d.target.value);return M.jsxs("fieldset",{children:[M.jsxs("label",{children:[" ",s," "]}),M.jsx("input",{type:"text",defaultValue:t,onChange:u})]},i)}else return M.jsxs("fieldset",{children:[M.jsxs("label",{children:[" ",s," "]}),M.jsx("input",{value:"dont know"})]},i);else if(a==="colEnum"){const u=n.map(d=>{const h=g=>{const m=g.target.value;if(A2(m)){const p=T2(t,d,m);r(F2(p,["null"]))}},f=ws(t,d,"null");return He(l)?M.jsx("td",{children:M.jsx("select",{defaultValue:f,onChange:h,children:l.map(g=>M.jsx("option",{value:g,children:g},g))})},i+d):M.jsx("h3",{children:" arg error"})});return M.jsx("div",{className:"col-enum",children:M.jsxs("table",{children:[M.jsx("thead",{children:M.jsx("tr",{children:n.map(d=>M.jsx("th",{children:d},d))})}),M.jsx("tbody",{children:M.jsx("tr",{children:u})})]})},i)}else return M.jsx("h3",{children:" unknown argtype "})},Ck={symbol:"df"},wk={dropcol:[null],fillna:[[3,"fillVal","type","integer"]],remove_outliers:[[3,"tail","type","float"]],search:[[3,"needle","type","string"]],resample:[[3,"frequency","enum",["daily","weekly","monthly"]],[4,"colMap","colEnum",["null","sum","mean","count"]]]},M2=Object.freeze(Object.defineProperty({__proto__:null,bakedArgSpecs:wk,symDf:Ck},Symbol.toStringTag,{value:"Module"})),Sk=(e,t)=>t>e.length?"no-key":e[t][0].symbol+t.toString(),xk=({operations:e,setOperations:t,activeKey:r,setActiveKey:n})=>{const i=s=>{const a=[...e];a.splice(s,1),t(a)},o=s=>{const a=[...e],l=a[s],c={...l[0]};c.meta&&(delete c.meta.auto_clean,Object.keys(c.meta).length===0&&delete c.meta),a[s]=[c,...l.slice(1)],t(a)};return M.jsx("div",{className:"operations-list",children:e.map((s,a)=>{var u,d;const l=Sk(e,a),c=((u=s[0].meta)==null?void 0:u.auto_clean)===!0;return M.jsxs("div",{className:`operation-item default-operation ${r===l?"active":""} ${c?"auto_clean":""}`,onClick:()=>n(l),children:[M.jsxs("div",{className:"operation-content",children:[M.jsx("span",{className:"symbol",children:s[0].symbol}),M.jsx("span",{className:"arg",children:s[2]}),((d=s[0].meta)==null?void 0:d.clean_strategy)&&M.jsxs("span",{className:"clean-strategy",children:["Strategy: ",s[0].meta.clean_strategy]}),c&&M.jsx("button",{className:"preserve-button",onClick:h=>{h.stopPropagation(),o(a)},title:"Preserve this cleaning operation",children:"preserve"})]}),M.jsx("button",{className:"delete-button",onClick:h=>{h.stopPropagation(),i(a)},children:"×"})]},a)})})},Ak=({column:e,addOperationCb:t,defaultArgs:r})=>{const n=i=>()=>{const o=r[i];t(R2(o,"col",e))};return M.jsxs("div",{className:"operation-adder",children:[M.jsxs("span",{className:"column-name",children:[" Column: ",e]}),M.jsx("fieldset",{children:Xt(r).map(i=>M.jsxs("button",{onClick:n(i),children:[" ",i," "]},i))})]})},Zg=({operations:e,setOperations:t,activeColumn:r,allColumns:n,command_config:i})=>{const o=(y,w)=>w[0].symbol+y.toString(),s=Rt(Array.from(e.entries()),([y,w])=>{const b={};return b[o(y,w)]=w,b}),a=mv({},...s),l=Rt(Array.from(e.entries()),([y,w])=>{const b={};return b[o(y,w)]=y,b}),c=mv({},...l),[u,d]=v.useState("");function h(y){return w=>{const b=c[y],x=e.map((C,S)=>S===b?w:C);console.log("about to call setOperations",y,w),t(x)}}const f=y=>Rt(Array.from(y.entries()),([w,b])=>b[0].symbol+w.toString()),g=y=>{const w=[...e,y];t(w);const b=f(w)[w.length-1];b!==void 0&&d(b)},{argspecs:m,defaultArgs:p}=i;return M.jsxs("div",{className:"operations-viewer",children:[M.jsx(Ak,{column:r,addOperationCb:g,defaultArgs:p}),M.jsxs("div",{className:"operations-box",children:[M.jsx("h4",{children:" Operations "}),M.jsx(xk,{operations:e,activeKey:u,setActiveKey:d,setOperations:t})]}),u&&M.jsx(vk,{command:a[u],setCommand:h(u),columns:n,commandPatterns:m})]})},D2=["chart","histogram","linkify","Base64PNGImageDisplayer","SVGDisplayer"];function Pk({filledOperations:e,style:t}){const n={...{margin:"0",textAlign:"left"},...t};return M.jsx("div",{className:"command-displayer",style:{width:"100%"},children:M.jsx("pre",{style:n,children:JSON.stringify(e)})})}function vv({style:e,generatedPyCode:t}){const n={...{margin:"0",textAlign:"left"},...e};return M.jsx("div",{className:"python-displayer",style:{width:"100%"},children:M.jsx("pre",{style:n,children:t})})}function yv({currentTab:e,_setTab:t,tabName:r}){return M.jsx("li",{onClick:()=>{t(r)},className:e===r?"active":"",children:r})}function Qg({filledOperations:e,operation_result:t}){const[r,n]=v.useState("DataFrame"),i={height:"45vh"};return M.jsxs("div",{className:"dependent-tabs",style:{width:"100%"},children:[M.jsxs("ul",{className:"tabs",children:[M.jsx(yv,{currentTab:r,_setTab:n,tabName:"Python"}),M.jsx(yv,{currentTab:r,_setTab:n,tabName:"Operations"})]}),M.jsxs("div",{className:"output-area",children:[t.transform_error?M.jsxs("div",{children:[M.jsx("h2",{children:" error "}),M.jsx(vv,{style:i,generatedPyCode:t.transform_error})]}):M.jsx("span",{}),{Operations:M.jsx(Pk,{style:i,filledOperations:e}),Python:M.jsx(vv,{style:i,generatedPyCode:t.generated_py_code})}[r]]})]})}var Wn=class{constructor(){this.allSyncListeners=new Map,this.allAsyncListeners=new Map,this.globalSyncListeners=new Set,this.globalAsyncListeners=new Set,this.asyncFunctionsQueue=[],this.scheduled=!1,this.firedEvents={}}setFrameworkOverrides(e){this.frameworkOverrides=e}getListeners(e,t,r){const n=t?this.allAsyncListeners:this.allSyncListeners;let i=n.get(e);return!i&&r&&(i=new Set,n.set(e,i)),i}noRegisteredListenersExist(){return this.allSyncListeners.size===0&&this.allAsyncListeners.size===0&&this.globalSyncListeners.size===0&&this.globalAsyncListeners.size===0}addEventListener(e,t,r=!1){this.getListeners(e,r,!0).add(t)}removeEventListener(e,t,r=!1){const n=this.getListeners(e,r,!1);n&&(n.delete(t),n.size===0&&(r?this.allAsyncListeners:this.allSyncListeners).delete(e))}addGlobalListener(e,t=!1){this.getGlobalListeners(t).add(e)}removeGlobalListener(e,t=!1){this.getGlobalListeners(t).delete(e)}dispatchEvent(e){const t=e;this.dispatchToListeners(t,!0),this.dispatchToListeners(t,!1),this.firedEvents[t.type]=!0}dispatchEventOnce(e){this.firedEvents[e.type]||this.dispatchEvent(e)}dispatchToListeners(e,t){const r=e.type;if(t&&"event"in e){const a=e.event;a instanceof Event&&(e.eventPath=a.composedPath())}const{frameworkOverrides:n}=this,i=a=>{const l=n?()=>n.wrapIncoming(a):a;t?this.dispatchAsync(l):l()},o=this.getListeners(r,t,!1);if(((o==null?void 0:o.size)??0)>0){const a=new Set(o);for(const l of a)o!=null&&o.has(l)&&i(()=>l(e))}const s=this.getGlobalListeners(t);if(s.size>0){const a=new Set(s);for(const l of a)i(()=>l(r,e))}}getGlobalListeners(e){return e?this.globalAsyncListeners:this.globalSyncListeners}dispatchAsync(e){if(this.asyncFunctionsQueue.push(e),!this.scheduled){const t=()=>{window.setTimeout(this.flushAsyncQueue.bind(this),0)};this.frameworkOverrides?this.frameworkOverrides.wrapIncoming(t):t(),this.scheduled=!0}}flushAsyncQueue(){this.scheduled=!1;const e=this.asyncFunctionsQueue.slice();this.asyncFunctionsQueue=[],e.forEach(t=>t())}};function Rk(e,t){return t}function k2(e){return(e==null?void 0:e.getLocaleTextFunc())??Rk}function dn(e,t,r){r==null||typeof r=="string"&&r==""?I2(e,t):Er(e,t,r)}function Er(e,t,r){e.setAttribute(_2(t),r.toString())}function I2(e,t){e.removeAttribute(_2(t))}function _2(e){return`aria-${e}`}function _i(e,t){t?e.setAttribute("role",t):e.removeAttribute("role")}function Ek(e){let t;return e==="asc"?t="ascending":e==="desc"?t="descending":e==="mixed"?t="other":t="none",t}function Tk(e){return e.getAttribute("aria-label")}function lu(e,t){dn(e,"label",t)}function Ah(e,t){dn(e,"labelledby",t)}function L2(e,t){dn(e,"live",t)}function Fk(e,t){dn(e,"atomic",t)}function Ok(e,t){dn(e,"relevant",t)}function B2(e,t){dn(e,"hidden",t)}function Ph(e,t){Er(e,"expanded",t)}function Mk(e,t){Er(e,"setsize",t)}function Dk(e,t){Er(e,"posinset",t)}function kk(e,t){Er(e,"rowcount",t)}function Ik(e,t){Er(e,"rowindex",t)}function _k(e,t){Er(e,"colcount",t)}function z2(e,t){Er(e,"colindex",t)}function Lk(e,t){Er(e,"colspan",t)}function Bk(e,t){Er(e,"sort",t)}function zk(e){I2(e,"sort")}function Rh(e,t){dn(e,"selected",t)}function Nk(e,t){dn(e,"controls",t.id),Ah(t,e.id)}function N2(e,t){return t===void 0?e("ariaIndeterminate","indeterminate"):t===!0?e("ariaChecked","checked"):e("ariaUnchecked","unchecked")}var od,sd,ad,ld,Eh,Th,cd;function ep(){return od===void 0&&(od=/^((?!chrome|android).)*safari/i.test(navigator.userAgent)),od}function $2(){return sd===void 0&&(sd=/(firefox)/i.test(navigator.userAgent)),sd}function H2(){return ad===void 0&&(ad=/(Mac|iPhone|iPod|iPad)/i.test(navigator.platform)),ad}function Dn(){return ld===void 0&&(ld=/iPad|iPhone|iPod/.test(navigator.platform)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1),ld}function bv(e){if(!e)return null;const t=e.tabIndex,r=e.getAttribute("tabIndex");return t===-1&&(r===null||r===""&&!$2())?null:t.toString()}function $k(){if(cd!==void 0)return cd;if(!document.body)return-1;let e=1e6;const t=$2()?6e6:1e9,r=document.createElement("div");for(document.body.appendChild(r);;){const n=e*2;if(r.style.height=n+"px",n>t||r.clientHeight!==n)break;e=n}return document.body.removeChild(r),cd=e,e}function Hk(){return Th==null&&G2(),Th}function G2(){const e=document.body,t=document.createElement("div");t.style.width=t.style.height="100px",t.style.opacity="0",t.style.overflow="scroll",t.style.msOverflowStyle="scrollbar",t.style.position="absolute",e.appendChild(t);let r=t.offsetWidth-t.clientWidth;r===0&&t.clientWidth===0&&(r=null),t.parentNode&&t.parentNode.removeChild(t),r!=null&&(Th=r,Eh=r===0)}function W2(){return Eh==null&&G2(),Eh}var Gk="[tabindex], input, select, button, textarea, [href]",j2="[disabled], .ag-disabled:not(.ag-button), .ag-disabled *";function tp(e){const t=Element.prototype.matches||Element.prototype.msMatchesSelector,n=t.call(e,"input, select, button, textarea"),i=t.call(e,j2),o=Sr(e);return n&&!i&&o}function Je(e,t,r={}){const{skipAriaHidden:n}=r;e.classList.toggle("ag-hidden",!t),n||B2(e,!t)}function Wk(e,t,r={}){const{skipAriaHidden:n}=r;e.classList.toggle("ag-invisible",!t),n||B2(e,!t)}function xs(e,t){const r="disabled",n=t?o=>o.setAttribute(r,""):o=>o.removeAttribute(r);n(e);const i=e.querySelectorAll("input")??[];for(const o of i)n(o)}function kn(e,t,r){let n=0;for(;e;){if(e.classList.contains(t))return!0;if(e=e.parentElement,typeof r=="number"){if(++n>r)break}else if(e===r)break}return!1}function go(e){const{height:t,width:r,borderTopWidth:n,borderRightWidth:i,borderBottomWidth:o,borderLeftWidth:s,paddingTop:a,paddingRight:l,paddingBottom:c,paddingLeft:u,marginTop:d,marginRight:h,marginBottom:f,marginLeft:g,boxSizing:m}=window.getComputedStyle(e);return{height:parseFloat(t||"0"),width:parseFloat(r||"0"),borderTopWidth:parseFloat(n||"0"),borderRightWidth:parseFloat(i||"0"),borderBottomWidth:parseFloat(o||"0"),borderLeftWidth:parseFloat(s||"0"),paddingTop:parseFloat(a||"0"),paddingRight:parseFloat(l||"0"),paddingBottom:parseFloat(c||"0"),paddingLeft:parseFloat(u||"0"),marginTop:parseFloat(d||"0"),marginRight:parseFloat(h||"0"),marginBottom:parseFloat(f||"0"),marginLeft:parseFloat(g||"0"),boxSizing:m}}function rp(e){const t=go(e);return t.boxSizing==="border-box"?t.height-t.paddingTop-t.paddingBottom:t.height}function As(e){const t=go(e);return t.boxSizing==="border-box"?t.width-t.paddingLeft-t.paddingRight:t.width}function V2(e){const{height:t,marginBottom:r,marginTop:n}=go(e);return Math.floor(t+r+n)}function Tl(e){const{width:t,marginLeft:r,marginRight:n}=go(e);return Math.floor(t+r+n)}function U2(e){const t=e.getBoundingClientRect(),{borderTopWidth:r,borderLeftWidth:n,borderRightWidth:i,borderBottomWidth:o}=go(e);return{top:t.top+(r||0),left:t.left+(n||0),right:t.right+(i||0),bottom:t.bottom+(o||0)}}function Fl(e,t){let r=e.scrollLeft;return t&&(r=Math.abs(r)),r}function Ol(e,t,r){r&&(t*=-1),e.scrollLeft=t}function hn(e){for(;e&&e.firstChild;)e.removeChild(e.firstChild)}function jn(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function K2(e){return!!e.offsetParent}function Sr(e){const t=e;return t.checkVisibility?t.checkVisibility({checkVisibilityCSS:!0}):!(!K2(e)||window.getComputedStyle(e).visibility!=="visible")}function np(e){const t=document.createElement("div");return t.innerHTML=(e||"").trim(),t.firstChild}function jk(e){return e.clientWidth<e.scrollWidth}function Vk(e){return e.clientHeight<e.scrollHeight}function Ml(e,t){t==="flex"?(e.style.removeProperty("width"),e.style.removeProperty("minWidth"),e.style.removeProperty("maxWidth"),e.style.flex="1 1 auto"):yr(e,t)}function yr(e,t){t=ip(t),e.style.width=t,e.style.maxWidth=t,e.style.minWidth=t}function os(e,t){t=ip(t),e.style.height=t,e.style.maxHeight=t,e.style.minHeight=t}function ip(e){return typeof e=="number"?`${e}px`:e}function q2(e){return e instanceof Node||e instanceof HTMLElement}function Si(e,t,r){r==null||r===""?e.removeAttribute(t):e.setAttribute(t,r.toString())}function fn(e,t,r){const i=i1(e).ResizeObserver,o=i?new i(r):null;return o==null||o.observe(t),()=>o==null?void 0:o.disconnect()}function Ur(e,t){const r=i1(e);r.requestAnimationFrame?r.requestAnimationFrame(t):r.webkitRequestAnimationFrame?r.webkitRequestAnimationFrame(t):r.setTimeout(t,0)}var Y2="data-ref",ud;function Cv(){return ud??(ud=document.createTextNode(" ")),ud.cloneNode()}function lt(e){const{attrs:t,children:r,cls:n,ref:i,role:o,tag:s}=e,a=document.createElement(s);if(n&&(a.className=n),i&&a.setAttribute(Y2,i),o&&a.setAttribute("role",o),t)for(const l of Object.keys(t))a.setAttribute(l,t[l]);if(r)if(typeof r=="string")a.textContent=r;else{let l=!0;for(const c of r)c&&(typeof c=="string"?(a.appendChild(document.createTextNode(c)),l=!1):(l&&(a.appendChild(Cv()),l=!1),a.append(lt(c)),a.appendChild(Cv())))}return a}var wv={};function op(e,t){wv[t]||(e(),wv[t]=!0)}function Vn(e,t,...r){e.get("debug")&&console.log("AG Grid: "+t,...r)}function Uk(e,...t){op(()=>console.warn("AG Grid: "+e,...t),e+(t==null?void 0:t.join("")))}function ss(e,...t){op(()=>console.error("AG Grid: "+e,...t),e+(t==null?void 0:t.join("")))}var Kk={pending:!1,funcs:[]},qk={pending:!1,funcs:[]};function Fh(e,t="setTimeout",r){const n=t==="raf"?qk:Kk;if(n.funcs.push(e),n.pending)return;n.pending=!0;const i=()=>{const o=n.funcs.slice();n.funcs.length=0,n.pending=!1,o.forEach(s=>s())};t==="raf"?Ur(r,i):window.setTimeout(i,0)}function kr(e,t,r){let n;return function(...i){const o=this;window.clearTimeout(n),n=window.setTimeout(function(){e.isAlive()&&t.apply(o,i)},r)}}function Sv(e,t){let r=0;return function(...n){const i=this,o=Date.now();o-r<t||(r=o,e.apply(i,n))}}function Yk(e,t,r=100,n){const i=Date.now();let o=null,s=!1;const a=()=>{const l=Date.now()-i>r;(e()||l)&&(t(),s=!0,o!=null&&(window.clearInterval(o),o=null))};a(),s||(o=window.setInterval(a,10))}function on(e){return e==null||e===""?null:e}function ie(e){return e!=null&&e!==""}function Xe(e){return!ie(e)}function Oh(e){return e!=null&&typeof e.toString=="function"?e.toString():null}function sp(e,t){const r=e?JSON.stringify(e):null,n=t?JSON.stringify(t):null;return r===n}function Jk(e,t,r=!1){const n=e==null,i=t==null;if(e&&e.toNumber&&(e=e.toNumber()),t&&t.toNumber&&(t=t.toNumber()),n&&i)return 0;if(n)return-1;if(i)return 1;function o(s,a){return s>a?1:s<a?-1:0}if(typeof e!="string"||!r)return o(e,t);try{return e.localeCompare(t)}catch{return o(e,t)}}var J2="https://www.ag-grid.com",he="33.3.2",xv=2e3,Av=100,X2="_version_",Z2=`${J2}/javascript-data-grid`;function Xk(e){Z2=e}function Q2(e,t,r){return[rI(e,t,r)]}function ap(e,t,r,n){e(`error #${t}`,...Q2(t,r,n))}function Zk(e){if(!e)return String(e);const t={};for(const r of Object.keys(e))typeof e[r]!="object"&&typeof e[r]!="function"&&(t[r]=e[r]);return JSON.stringify(t)}function Qk(e){let t=e;return e instanceof Error?t=e.toString():typeof e=="object"&&(t=Zk(e)),t}function Mh(e,t){return`${e}?${t.toString()}`}function eI(e,t,r){const n=Array.from(t.entries()).sort((o,s)=>s[1].length-o[1].length);let i=Mh(e,t);for(const[o,s]of n){if(o===X2)continue;const a=i.length-r;if(a<=0)break;const l="...",c=a+l.length,u=s.length-c>Av?s.slice(0,s.length-c)+l:s.slice(0,Av)+l;t.set(o,u),i=Mh(e,t)}return i}function tI(e,t){const r=new URLSearchParams;if(r.append(X2,he),t)for(const o of Object.keys(t))r.append(o,Qk(t[o]));const n=`${Z2}/errors/${e}`,i=Mh(n,r);return i.length<=xv?i:eI(n,r,xv)}var rI=(e,t,r)=>{const n=tI(e,t);return`${r?r+`
2
+ `:""}Visit ${n}${r?"":`
3
+ Alternatively register the ValidationModule to see the full message in the console.`}`};function Q(...e){ap(Uk,e[0],e[1])}function _e(...e){ap(ss,e[0],e[1])}function Zo(e,t,r){ap(ss,e,t,r)}function nI(e,t){const r=t[0];return`error #${r} `+Q2(r,t[1],e).join(" ")}function e1(...e){return nI(void 0,e)}function t1(e,t){return e.get("rowModelType")===t}function xt(e,t){return t1(e,"clientSide")}function po(e,t){return t1(e,"serverSide")}function pt(e,t){return e.get("domLayout")===t}function In(e){return kl(e)!==void 0}function r1(e){return typeof e.get("getRowHeight")=="function"}function iI(e,t){return t?!e.get("enableStrictPivotColumnOrder"):e.get("maintainColumnOrder")}function Un(e,t,r=!1,n){const{gos:i,environment:o}=e;if(n==null&&(n=o.getDefaultRowHeight()),r1(i)){if(r)return{height:n,estimated:!0};const l={node:t,data:t.data},c=i.getCallback("getRowHeight")(l);if(Dh(c))return c===0&&Q(23),{height:Math.max(1,c),estimated:!1}}if(t.detail&&i.get("masterDetail"))return oI(i);const s=i.get("rowHeight");return{height:s&&Dh(s)?s:n,estimated:!1}}function oI(e){if(e.get("detailRowAutoHeight"))return{height:1,estimated:!1};const t=e.get("detailRowHeight");return Dh(t)?{height:t,estimated:!1}:{height:300,estimated:!1}}function as(e){const{environment:t,gos:r}=e,n=r.get("rowHeight");if(!n||Xe(n))return t.getDefaultRowHeight();const i=t.refreshRowHeightVariable();return i!==-1?i:(Q(24),t.getDefaultRowHeight())}function Dh(e){return!isNaN(e)&&typeof e=="number"&&isFinite(e)}function n1(e,t,r){const n=t[e.getDomDataKey()];return n?n[r]:void 0}function Li(e,t,r,n){const i=e.getDomDataKey();let o=t[i];Xe(o)&&(o={},t[i]=o),o[r]=n}function gt(e){const{gos:t,eGridDiv:r}=e;let n=null;const i=t.get("getDocument");return i&&ie(i)?n=i():r&&(n=r.ownerDocument),n&&ie(n)?n:document}function i1(e){return gt(e).defaultView||window}function Ps(e){return e.eGridDiv.getRootNode()}function Ke(e){return Ps(e).activeElement}function lp(e){let t=null,r=null;try{t=gt(e).fullscreenElement}catch{}finally{t||(t=Ps(e));const n=t.querySelector("body");n?r=n:t instanceof ShadowRoot?r=t:t instanceof Document?r=t==null?void 0:t.documentElement:r=t}return r}function sI(e){const t=lp(e);return(t==null?void 0:t.clientWidth)??(window.innerHeight||-1)}function aI(e){const t=lp(e);return(t==null?void 0:t.clientHeight)??(window.innerHeight||-1)}function lI(e,t,r){const i=e.getBoundingClientRect().height,o=sI(r)-2,s=aI(r)-2;if(!e.offsetParent)return;const l=U2(e.offsetParent),{clientY:c,clientX:u}=t;let d=c-l.top-i/2,h=u-l.left-10;const f=gt(r),g=f.defaultView||window,m=g.pageYOffset||f.documentElement.scrollTop,p=g.pageXOffset||f.documentElement.scrollLeft;o>0&&h+e.clientWidth>o+p&&(h=o+p-e.clientWidth),h<0&&(h=0),s>0&&d+e.clientHeight>s+m&&(d=s+m-e.clientHeight),d<0&&(d=0),e.style.left=`${h}px`,e.style.top=`${d}px`}function o1(e){const t=Ke(e);return t===null||t===gt(e).body}function xi(e){return e.get("ensureDomOrder")?!1:e.get("animateRows")}function s1(e){return!(e.get("paginateChildRows")||e.get("groupHideOpenParents")||pt(e,"print"))}function gr(e){const t=e.get("autoGroupColumnDef");return!(t!=null&&t.comparator)&&!e.get("treeData")}function kh(e){const t=e.get("groupAggFiltering");if(typeof t=="function")return e.getCallback("groupAggFiltering");if(t===!0)return()=>!0}function a1(e,t){return t?!1:e.get("groupDisplayType")==="groupRows"}function cI(e,t,r){return!!t.group&&!t.footer&&a1(e,r)}function Rs(e){const t=e.getCallback("getRowId");return t===void 0?t:r=>{let n=t(r);return typeof n!="string"&&(op(()=>Q(25,{id:n}),"getRowIdString"),n=String(n)),n}}function uI(e){const t=e.get("maxConcurrentDatasourceRequests");return t>0?t:void 0}function Ai(e){return(e==null?void 0:e.checkboxes)??!0}function fl(e){return(e==null?void 0:e.mode)==="multiRow"&&(e.headerCheckbox??!0)}function Dl(e){if(typeof e=="object")return e.checkboxLocation??"selectionColumn"}function dd(e){return(e==null?void 0:e.hideDisabledCheckboxes)??!1}function dI(e){return typeof e.get("rowSelection")!="string"}function Es(e){const t=e.get("cellSelection");return t!==void 0?!!t:e.get("enableRangeSelection")}function l1(e){const t=e.get("rowSelection")??"single";if(typeof t=="string"){const r=e.get("suppressRowClickSelection"),n=e.get("suppressRowDeselection");return r&&n?!1:r?"enableDeselection":n?"enableSelection":!0}return t.mode==="singleRow"||t.mode==="multiRow"?t.enableClickSelection??!1:!1}function hI(e){const t=l1(e);return t===!0||t==="enableSelection"}function fI(e){const t=l1(e);return t===!0||t==="enableDeselection"}function Ih(e){const t=e.get("rowSelection");return typeof t=="string"?e.get("isRowSelectable"):t==null?void 0:t.isRowSelectable}function kl(e){const t="beanName"in e&&e.beanName==="gos"?e.get("rowSelection"):e.rowSelection;if(typeof t=="string")switch(t){case"multiple":return"multiRow";case"single":return"singleRow";default:return}switch(t==null?void 0:t.mode){case"multiRow":case"singleRow":return t.mode;default:return}}function Il(e){return kl(e)==="multiRow"}function gI(e){const t=e.get("rowSelection");return typeof t=="string"?e.get("rowMultiSelectWithClick"):(t==null?void 0:t.enableSelectionWithoutKeys)??!1}function _l(e){const t=e.get("rowSelection");if(typeof t=="string"){const r=e.get("groupSelectsChildren"),n=e.get("groupSelectsFiltered");return r&&n?"filteredDescendants":r?"descendants":"self"}return(t==null?void 0:t.mode)==="multiRow"?t.groupSelects:void 0}function c1(e,t=!0){const r=e.get("rowSelection");return typeof r!="object"?t?"all":void 0:r.mode==="multiRow"?r.selectAll:"all"}function Ts(e){const t=_l(e);return t==="descendants"||t==="filteredDescendants"}function Pv(e){const t=e.get("rowSelection");return typeof t=="object"&&t.masterSelects||"self"}function hd(e){return e.isModuleRegistered("SetFilter")&&!e.get("suppressSetFilterByDefault")}function Bt(e){return e.get("columnMenu")==="legacy"}function pI(e){return!Bt(e)}function mI(e){return!e||e.length<2?e:"on"+e[0].toUpperCase()+e.substring(1)}function vI(e,t,r){typeof e!="object"&&(e={});const n={...e};return r.forEach(i=>{const o=t[i];typeof o<"u"&&(n[i]=o)}),n}function yI(e,t){if(!e)return;const r={};let n=!1;if(Object.keys(e).forEach(s=>{r[s]=e[s],n=!0}),!n)return;const i={type:"gridOptionsChanged",options:r};t.dispatchEvent(i);const o={type:"componentStateChanged",...r};t.dispatchEvent(o)}function pe(e,t){return e.addGridCommonParams(t)}function bI(e){return e.get("treeData")?e.get("treeDataParentIdField")?"treeSelfRef":e.get("treeDataChildrenField")?"treeNested":"treePath":"group"}var u1="__ag_Grid_Stop_Propagation",CI=["touchstart","touchend","touchmove","touchcancel","scroll"],wI=["wheel"],fd={};function Kn(e){e[u1]=!0}function Lr(e){return e[u1]===!0}var d1=(()=>{const e={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return r=>{if(typeof fd[r]=="boolean")return fd[r];const n=document.createElement(e[r]||"div");return r="on"+r,fd[r]=r in n}})();function h1(e,t,r){let n=t;for(;n;){const i=n1(e,n,r);if(i)return i;n=n.parentElement}return null}function SI(e,t){return!t||!e?!1:AI(t).indexOf(e)>=0}function xI(e){const t=[];let r=e.target;for(;r;)t.push(r),r=r.parentElement;return t}function AI(e){const t=e;return t.path?t.path:t.composedPath?t.composedPath():xI(t)}function PI(e,t,r,n){const i=f1(r);let o;i!=null&&(o={passive:i}),e&&e.addEventListener&&e.addEventListener(t,r,n,o)}var f1=e=>{const t=CI.includes(e),r=wI.includes(e);if(t)return!0;if(r)return!1},q=class{constructor(){this.destroyFunctions=[],this.destroyed=!1,this.__v_skip=!0,this.propertyListenerId=0,this.lastChangeSetIdLookup={},this.isAlive=()=>!this.destroyed}preWireBeans(e){this.beans=e,this.stubContext=e.context,this.eventSvc=e.eventSvc,this.gos=e.gos}destroy(){const{destroyFunctions:e}=this;for(let t=0;t<e.length;t++)e[t]();e.length=0,this.destroyed=!0,this.dispatchLocalEvent({type:"destroyed"})}addEventListener(e,t,r){this.localEventService||(this.localEventService=new Wn),this.localEventService.addEventListener(e,t,r)}removeEventListener(e,t,r){var n;(n=this.localEventService)==null||n.removeEventListener(e,t,r)}dispatchLocalEvent(e){var t;(t=this.localEventService)==null||t.dispatchEvent(e)}addManagedElementListeners(e,t){return this._setupListeners(e,t)}addManagedEventListeners(e){return this._setupListeners(this.eventSvc,e)}addManagedListeners(e,t){return this._setupListeners(e,t)}_setupListeners(e,t){const r=[];for(const n of Object.keys(t)){const i=t[n];i&&r.push(this._setupListener(e,n,i))}return r}_setupListener(e,t,r){if(this.destroyed)return()=>null;let n;return RI(e)?(e.__addEventListener(t,r),n=()=>(e.__removeEventListener(t,r),null)):(e instanceof HTMLElement?PI(this.beans.frameworkOverrides,e,t,r):e.addEventListener(t,r),n=()=>(e.removeEventListener(t,r),null)),this.destroyFunctions.push(n),()=>(n(),this.destroyFunctions=this.destroyFunctions.filter(i=>i!==n),null)}setupGridOptionListener(e,t){const{gos:r}=this;r.addPropertyEventListener(e,t);const n=()=>(r.removePropertyEventListener(e,t),null);return this.destroyFunctions.push(n),()=>(n(),this.destroyFunctions=this.destroyFunctions.filter(i=>i!==n),null)}addManagedPropertyListener(e,t){return this.destroyed?()=>null:this.setupGridOptionListener(e,t)}addManagedPropertyListeners(e,t){if(this.destroyed)return;const r=e.join("-")+this.propertyListenerId++,n=i=>{if(i.changeSet){if(i.changeSet&&i.changeSet.id===this.lastChangeSetIdLookup[r])return;this.lastChangeSetIdLookup[r]=i.changeSet.id}const o={type:"gridPropertyChanged",changeSet:i.changeSet,source:i.source};t(o)};e.forEach(i=>this.setupGridOptionListener(i,n))}getLocaleTextFunc(){return k2(this.beans.localeSvc)}addDestroyFunc(e){this.isAlive()?this.destroyFunctions.push(e):e()}createOptionalManagedBean(e,t){return e?this.createManagedBean(e,t):void 0}createManagedBean(e,t){const r=this.createBean(e,t);return this.addDestroyFunc(this.destroyBean.bind(this,e,t)),r}createBean(e,t,r){return(t||this.stubContext).createBean(e,r)}destroyBean(e,t){return(t||this.stubContext).destroyBean(e)}destroyBeans(e,t){return(t||this.stubContext).destroyBeans(e)}};function RI(e){return e.__addEventListener!==void 0}var EI=new Set(["__proto__","constructor","prototype"]);function TI(e,t){if(e!=null){if(Array.isArray(e)){for(let r=0;r<e.length;r++)t(r.toString(),e[r]);return}for(const r of Object.keys(e))t(r,e[r])}}function Et(e,t,r=!0,n=!1){ie(t)&&TI(t,(i,o)=>{if(EI.has(i))return;let s=e[i];s!==o&&(n&&s==null&&o!=null&&typeof o=="object"&&o.constructor===Object&&(s={},e[i]=s),Rv(o)&&Rv(s)&&!Array.isArray(s)?Et(s,o,r,n):(r||o!==void 0)&&(e[i]=o))})}function ls(e,t,r){if(!t||!e)return;if(!r)return e[t];const n=t.split(".");let i=e;for(let o=0;o<n.length;o++){if(i==null)return;i=i[n[o]]}return i}function Rv(e){return typeof e=="object"&&e!==null}var FI=/[&<>"']/g,OI={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function Sa(e){return(e==null?void 0:e.toString().toString())??null}function gl(e){var t;return((t=Sa(e))==null?void 0:t.replace(FI,r=>OI[r]))??null}var MI={resizable:!0,sortable:!0},DI=0;function g1(){return DI++}function $r(e){return e instanceof cu}var cu=class extends q{constructor(e,t,r,n){super(),this.colDef=e,this.userProvidedColDef=t,this.colId=r,this.primary=n,this.isColumn=!0,this.instanceId=g1(),this.autoHeaderHeight=null,this.moving=!1,this.menuVisible=!1,this.lastLeftPinned=!1,this.firstRightPinned=!1,this.filterActive=!1,this.colEventSvc=new Wn,this.tooltipEnabled=!1,this.rowGroupActive=!1,this.pivotActive=!1,this.aggregationActive=!1,this.flex=null,this.colIdSanitised=gl(r)}destroy(){var e;super.destroy(),(e=this.beans.rowSpanSvc)==null||e.deregister(this)}getInstanceId(){return this.instanceId}setState(){const{colDef:e,beans:{sortSvc:t,pinnedCols:r,colFlex:n}}=this;t==null||t.initCol(this);const i=e.hide;i!==void 0?this.visible=!i:this.visible=!e.initialHide,r==null||r.initCol(this),n==null||n.initCol(this)}setColDef(e,t,r){var i;const n=e.spanRows!==this.colDef.spanRows;this.colDef=e,this.userProvidedColDef=t,this.initMinAndMaxWidths(),this.initDotNotation(),this.initTooltip(),n&&((i=this.beans.rowSpanSvc)==null||i.deregister(this),this.initRowSpan()),this.dispatchColEvent("colDefChanged",r)}getUserProvidedColDef(){return this.userProvidedColDef}getParent(){return this.parent}getOriginalParent(){return this.originalParent}postConstruct(){this.setState(),this.initMinAndMaxWidths(),this.resetActualWidth("gridInitializing"),this.initDotNotation(),this.initTooltip(),this.initRowSpan()}initDotNotation(){const{gos:e,colDef:{field:t,tooltipField:r}}=this,n=e.get("suppressFieldDotNotation");this.fieldContainsDots=ie(t)&&t.indexOf(".")>=0&&!n,this.tooltipFieldContainsDots=ie(r)&&r.indexOf(".")>=0&&!n}initMinAndMaxWidths(){const e=this.colDef;this.minWidth=e.minWidth??this.beans.environment.getDefaultColumnMinWidth(),this.maxWidth=e.maxWidth??Number.MAX_SAFE_INTEGER}initTooltip(){var e;(e=this.beans.tooltipSvc)==null||e.initCol(this)}initRowSpan(){var e;this.colDef.spanRows&&((e=this.beans.rowSpanSvc)==null||e.register(this))}resetActualWidth(e){const t=this.calculateColInitialWidth(this.colDef);this.setActualWidth(t,e,!0)}calculateColInitialWidth(e){let t;const r=e.width,n=e.initialWidth;return r!=null?t=r:n!=null?t=n:t=200,Math.max(Math.min(t,this.maxWidth),this.minWidth)}isEmptyGroup(){return!1}isRowGroupDisplayed(e){var t;return((t=this.beans.showRowGroupCols)==null?void 0:t.isRowGroupDisplayed(this,e))??!1}isPrimary(){return this.primary}isFilterAllowed(){return!!this.colDef.filter}isFieldContainsDots(){return this.fieldContainsDots}isTooltipEnabled(){return this.tooltipEnabled}isTooltipFieldContainsDots(){return this.tooltipFieldContainsDots}getHighlighted(){return this.highlighted}__addEventListener(e,t){this.colEventSvc.addEventListener(e,t)}__removeEventListener(e,t){this.colEventSvc.removeEventListener(e,t)}addEventListener(e,t){var n,i,o;this.frameworkEventListenerService=(i=(n=this.beans.frameworkOverrides).createLocalEventListenerWrapper)==null?void 0:i.call(n,this.frameworkEventListenerService,this.colEventSvc);const r=((o=this.frameworkEventListenerService)==null?void 0:o.wrap(e,t))??t;this.colEventSvc.addEventListener(e,r)}removeEventListener(e,t){var n;const r=((n=this.frameworkEventListenerService)==null?void 0:n.unwrap(e,t))??t;this.colEventSvc.removeEventListener(e,r)}createColumnFunctionCallbackParams(e){return pe(this.gos,{node:e,data:e.data,column:this,colDef:this.colDef})}isSuppressNavigable(e){var t;return((t=this.beans.cellNavigation)==null?void 0:t.isSuppressNavigable(this,e))??!1}isCellEditable(e){var t;return((t=this.beans.editSvc)==null?void 0:t.isCellEditable(this,e))??!1}isSuppressFillHandle(){return!!this.colDef.suppressFillHandle}isAutoHeight(){return!!this.colDef.autoHeight}isAutoHeaderHeight(){return!!this.colDef.autoHeaderHeight}isRowDrag(e){return this.isColumnFunc(e,this.colDef.rowDrag)}isDndSource(e){return this.isColumnFunc(e,this.colDef.dndSource)}isCellCheckboxSelection(e){var t;return((t=this.beans.selectionSvc)==null?void 0:t.isCellCheckboxSelection(this,e))??!1}isSuppressPaste(e){var t;return this.isColumnFunc(e,((t=this.colDef)==null?void 0:t.suppressPaste)??null)}isResizable(){return!!this.getColDefValue("resizable")}getColDefValue(e){return this.colDef[e]??MI[e]}isColumnFunc(e,t){if(typeof t=="boolean")return t;if(typeof t=="function"){const r=this.createColumnFunctionCallbackParams(e);return t(r)}return!1}createColumnEvent(e,t){return pe(this.gos,{type:e,column:this,columns:[this],source:t})}isMoving(){return this.moving}getSort(){return this.sort}isSortable(){return!!this.getColDefValue("sortable")}isSortAscending(){return this.sort==="asc"}isSortDescending(){return this.sort==="desc"}isSortNone(){return Xe(this.sort)}isSorting(){return ie(this.sort)}getSortIndex(){return this.sortIndex}isMenuVisible(){return this.menuVisible}getAggFunc(){return this.aggFunc}getLeft(){return this.left}getOldLeft(){return this.oldLeft}getRight(){return this.left+this.actualWidth}setLeft(e,t){this.oldLeft=this.left,this.left!==e&&(this.left=e,this.dispatchColEvent("leftChanged",t))}isFilterActive(){return this.filterActive}isHovered(){var e;return Q(261),!!((e=this.beans.colHover)!=null&&e.isHovered(this))}setFirstRightPinned(e,t){this.firstRightPinned!==e&&(this.firstRightPinned=e,this.dispatchColEvent("firstRightPinnedChanged",t))}setLastLeftPinned(e,t){this.lastLeftPinned!==e&&(this.lastLeftPinned=e,this.dispatchColEvent("lastLeftPinnedChanged",t))}isFirstRightPinned(){return this.firstRightPinned}isLastLeftPinned(){return this.lastLeftPinned}isPinned(){return this.pinned==="left"||this.pinned==="right"}isPinnedLeft(){return this.pinned==="left"}isPinnedRight(){return this.pinned==="right"}getPinned(){return this.pinned}setVisible(e,t){const r=e===!0;this.visible!==r&&(this.visible=r,this.dispatchColEvent("visibleChanged",t)),this.dispatchStateUpdatedEvent("hide")}isVisible(){return this.visible}isSpanHeaderHeight(){return!this.getColDef().suppressSpanHeaderHeight}getColumnGroupPaddingInfo(){let e=this.getParent();if(!e||!e.isPadding())return{numberOfParents:0,isSpanningTotal:!1};const t=e.getPaddingLevel()+1;let r=!0;for(;e;){if(!e.isPadding()){r=!1;break}e=e.getParent()}return{numberOfParents:t,isSpanningTotal:r}}getColDef(){return this.colDef}getDefinition(){return this.colDef}getColumnGroupShow(){return this.colDef.columnGroupShow}getColId(){return this.colId}getId(){return this.colId}getUniqueId(){return this.colId}getActualWidth(){return this.actualWidth}getAutoHeaderHeight(){return this.autoHeaderHeight}setAutoHeaderHeight(e){const t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}createBaseColDefParams(e){return pe(this.gos,{node:e,data:e.data,colDef:this.colDef,column:this})}getColSpan(e){if(Xe(this.colDef.colSpan))return 1;const t=this.createBaseColDefParams(e),r=this.colDef.colSpan(t);return Math.max(r,1)}getRowSpan(e){if(Xe(this.colDef.rowSpan))return 1;const t=this.createBaseColDefParams(e),r=this.colDef.rowSpan(t);return Math.max(r,1)}setActualWidth(e,t,r=!1){e=Math.max(e,this.minWidth),e=Math.min(e,this.maxWidth),this.actualWidth!==e&&(this.actualWidth=e,this.flex!=null&&t!=="flex"&&t!=="gridInitializing"&&(this.flex=null),r||this.fireColumnWidthChangedEvent(t)),this.dispatchStateUpdatedEvent("width")}fireColumnWidthChangedEvent(e){this.dispatchColEvent("widthChanged",e)}isGreaterThanMax(e){return e>this.maxWidth}getMinWidth(){return this.minWidth}getMaxWidth(){return this.maxWidth}getFlex(){return this.flex}isRowGroupActive(){return this.rowGroupActive}isPivotActive(){return this.pivotActive}isAnyFunctionActive(){return this.isPivotActive()||this.isRowGroupActive()||this.isValueActive()}isAnyFunctionAllowed(){return this.isAllowPivot()||this.isAllowRowGroup()||this.isAllowValue()}isValueActive(){return this.aggregationActive}isAllowPivot(){return this.colDef.enablePivot===!0}isAllowValue(){return this.colDef.enableValue===!0}isAllowRowGroup(){return this.colDef.enableRowGroup===!0}dispatchColEvent(e,t,r){const n=this.createColumnEvent(e,t);r&&Et(n,r),this.colEventSvc.dispatchEvent(n)}dispatchStateUpdatedEvent(e){this.colEventSvc.dispatchEvent({type:"columnStateUpdated",key:e})}};function ht(e){return e instanceof pl}var pl=class extends q{constructor(e,t,r,n){super(),this.colGroupDef=e,this.groupId=t,this.padding=r,this.level=n,this.isColumn=!1,this.expandable=!1,this.instanceId=g1(),this.expandableListenerRemoveCallback=null,this.expanded=!!(e!=null&&e.openByDefault)}destroy(){this.expandableListenerRemoveCallback&&this.reset(null,void 0),super.destroy()}reset(e,t){this.colGroupDef=e,this.level=t,this.originalParent=null,this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback(),this.children=void 0,this.expandable=void 0}getInstanceId(){return this.instanceId}getOriginalParent(){return this.originalParent}getLevel(){return this.level}isVisible(){return this.children?this.children.some(e=>e.isVisible()):!1}isPadding(){return this.padding}setExpanded(e){this.expanded=e===void 0?!1:e,this.dispatchLocalEvent({type:"expandedChanged"})}isExpandable(){return this.expandable}isExpanded(){return this.expanded}getGroupId(){return this.groupId}getId(){return this.getGroupId()}setChildren(e){this.children=e}getChildren(){return this.children}getColGroupDef(){return this.colGroupDef}getLeafColumns(){const e=[];return this.addLeafColumns(e),e}forEachLeafColumn(e){if(this.children)for(const t of this.children)$r(t)?e(t):ht(t)&&t.forEachLeafColumn(e)}addLeafColumns(e){this.children&&this.children.forEach(t=>{$r(t)?e.push(t):ht(t)&&t.addLeafColumns(e)})}getColumnGroupShow(){const e=this.colGroupDef;if(e)return e.columnGroupShow}setupExpandable(){this.setExpandable(),this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback();const e=this.onColumnVisibilityChanged.bind(this);this.getLeafColumns().forEach(t=>t.__addEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=()=>{this.getLeafColumns().forEach(t=>t.__removeEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=null}}setExpandable(){if(this.isPadding())return;let e=!1,t=!1,r=!1;const n=this.findChildrenRemovingPadding();for(let o=0,s=n.length;o<s;o++){const a=n[o];if(!a.isVisible())continue;const l=a.getColumnGroupShow();l==="open"?(e=!0,r=!0):l==="closed"?(t=!0,r=!0):(e=!0,t=!0)}const i=e&&t&&r;this.expandable!==i&&(this.expandable=i,this.dispatchLocalEvent({type:"expandableChanged"}))}findChildrenRemovingPadding(){const e=[],t=r=>{r.forEach(n=>{ht(n)&&n.isPadding()?t(n.children):e.push(n)})};return t(this.children),e}onColumnVisibilityChanged(){this.setExpandable()}},kI={numericColumn:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"},rightAligned:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"}};function Ev(e,t,r){const n={},i=e.gos;return Object.assign(n,i.get("defaultColGroupDef")),Object.assign(n,t),i.validateColDef(n,r),n}var II=class{constructor(){this.existingKeys={}}addExistingKeys(e){for(let t=0;t<e.length;t++)this.existingKeys[e[t]]=!0}getUniqueKey(e,t){e=Oh(e);let r=0;for(;;){let n=e??t;if(n?r!==0&&(n+="_"+r):n=r,!this.existingKeys[n]){const i=String(n);return e&&r>0&&Q(273,{providedId:e,usedId:i}),this.existingKeys[i]=!0,i}r++}}},Tv=Object.freeze([]);function Ee(e){if(e!=null&&e.length)return e[e.length-1]}function mo(e,t,r){return e==null&&t==null?!0:e!=null&&t!=null&&e.length===t.length&&e.every((n,i)=>r?r(n,t[i]):t[i]===n)}function za(e,t){if(e)for(const r of e)t(r)}function Zt(e,t){const r=e.indexOf(t);r>=0&&e.splice(r,1)}function Fv(e,t,r){for(let n=0;n<t.length;n++)Zt(e,t[n]);for(let n=t.length-1;n>=0;n--)e.splice(r,0,t[n])}var uu="ag-Grid-AutoColumn",p1="ag-Grid-SelectionColumn",m1="ag-Grid-RowNumbersColumn";function _I(e){const t=[],r=n=>{for(let i=0;i<n.length;i++){const o=n[i];$r(o)?t.push(o):ht(o)&&r(o.getChildren())}};return r(e),t}function Mr(e){return e.reduce((t,r)=>t+r.getActualWidth(),0)}function Ll(e,t,r){const n={};if(!t)return;Br(null,t,o=>{n[o.getInstanceId()]=o}),r&&Br(null,r,o=>{n[o.getInstanceId()]=null});const i=Object.values(n).filter(o=>o!=null);e.context.destroyBeans(i)}function v1(e){return e.getId().startsWith(uu)}function xa(e){const t=typeof e=="string"?e:"getColId"in e?e.getColId():e.colId;return(t==null?void 0:t.startsWith(p1))??!1}function Pi(e){const t=typeof e=="string"?e:"getColId"in e?e.getColId():e.colId;return(t==null?void 0:t.startsWith(m1))??!1}function Bl(e){let t=[];return e instanceof Array?t=e:typeof e=="string"&&(t=e.split(",")),t}function LI(e,t){return mo(e,t,(r,n)=>r.getColId()===n.getColId())}function BI(e){e.map={},e.list.forEach(t=>e.map[t.getId()]=t)}function Ri(e){return e==="gridOptionsUpdated"?"gridOptionsChanged":e}function y1(e,t){const r=e===t,n=e.getColDef()===t,i=e.getColId()==t;return r||n||i}var zI=(e,t)=>(r,n)=>{const i={value1:void 0,value2:void 0};let o=!1;return e&&(e[r]!==void 0&&(i.value1=e[r],o=!0),ie(n)&&e[n]!==void 0&&(i.value2=e[n],o=!0)),!o&&t&&(t[r]!==void 0&&(i.value1=t[r]),ie(n)&&t[n]!==void 0&&(i.value2=t[n])),i};function NI(e,t=null,r,n,i){const o=new II,{existingCols:s,existingGroups:a,existingColKeys:l}=$I(n);o.addExistingKeys(l);const c=b1(e,t,0,r,s,o,a,i),{colGroupSvc:u}=e,d=(u==null?void 0:u.findMaxDepth(c,0))??0,h=u?u.balanceColumnTree(c,0,d,o):c;return Br(null,h,(g,m)=>{ht(g)&&g.setupExpandable(),g.originalParent=m}),{columnTree:h,treeDepth:d}}function $I(e){const t=[],r=[],n=[];return e&&Br(null,e,i=>{if(ht(i)){const o=i;r.push(o)}else{const o=i;n.push(o.getId()),t.push(o)}}),{existingCols:t,existingGroups:r,existingColKeys:n}}function b1(e,t,r,n,i,o,s,a){if(!t)return[];const{colGroupSvc:l}=e,c=new Array(t.length);for(let u=0;u<c.length;u++){const d=t[u];l&&UI(d)?c[u]=l.createProvidedColumnGroup(n,d,r,i,o,s,a):c[u]=HI(e,n,d,i,o,a)}return c}function HI(e,t,r,n,i,o){var l;const s=WI(r,n);s&&(n==null||n.splice(s.idx,1));let a=s==null?void 0:s.column;if(a){const c=_h(e,r,a.getColId());a.setColDef(c,r,o),GI(e,a,c,o)}else{const c=i.getUniqueKey(r.colId,r.field),u=_h(e,r,c);a=new cu(u,r,c,t),e.context.createBean(a)}return(l=e.dataTypeSvc)==null||l.addColumnListeners(a),a}function C1(e,t,r,n,i,o,s,a){const{sortSvc:l,pinnedCols:c,colFlex:u}=e;r!==void 0&&t.setVisible(!r,a),l&&(l.updateColSort(t,n,a),i!==void 0&&l.setColSortIndex(t,i)),o!==void 0&&(c==null||c.setColPinned(t,o)),s!==void 0&&(u==null||u.setColFlex(t,s))}function GI(e,t,r,n){C1(e,t,r.hide,r.sort,r.sortIndex,r.pinned,r.flex,n);const i=t.getFlex();if(!(i!=null&&i>0))if(r.width!=null)t.setActualWidth(r.width,n);else{const o=t.getActualWidth();t.setActualWidth(o,n)}}function WI(e,t){if(t)for(let r=0;r<t.length;r++){const n=t[r].getUserProvidedColDef();if(!n)continue;if(e.colId!=null){if(t[r].getId()===e.colId)return{idx:r,column:t[r]};continue}if(e.field!=null){if(n.field===e.field)return{idx:r,column:t[r]};continue}if(n===e)return{idx:r,column:t[r]}}}function _h(e,t,r,n){const{gos:i,dataTypeSvc:o}=e,s={},a=i.get("defaultColDef");Et(s,a,!1,!0);const l=jI(e,s,t,r);l&&VI(e,l,s),Et(s,t,!1,!0);const c=i.get("autoGroupColumnDef"),u=gr(i);return t.rowGroup&&c&&u&&Et(s,{sort:c.sort,initialSort:c.initialSort},!1,!0),o==null||o.validateColDef(s),i.validateColDef(s,r,n),s}function jI(e,t,r,n){var s;const i=(s=e.dataTypeSvc)==null?void 0:s.updateColDefAndGetColumnType(t,r,n),o=r.type??i??t.type;return t.type=o,o?Bl(o):void 0}function VI(e,t,r){if(!t.length)return;const n=Object.assign({},kI),i=e.gos.get("columnTypes")||{};for(const o of Object.keys(i)){const s=i[o];o in n?Q(34,{key:o}):(s.type&&Q(35),n[o]=s)}t.forEach(o=>{const s=n[o.trim()];s?Et(r,s,!1,!0):Q(36,{t:o})})}function UI(e){return e.children!==void 0}function Br(e,t,r){if(t)for(let n=0;n<t.length;n++){const i=t[n];ht(i)&&Br(i,i.getChildren(),r),r(i,e)}}function w1(e,t){const r=[],n=[],i=[];return e.forEach(s=>{const a=s.getColDef().lockPosition;a==="right"?i.push(s):a==="left"||a===!0?r.push(s):n.push(s)}),t.get("enableRtl")?[...i,...n,...r]:[...r,...n,...i]}function S1(e,t){let r=!0;return Br(null,t,n=>{if(!ht(n))return;const i=n,o=i.getColGroupDef();if(!(o&&o.marryChildren))return;const a=[];i.getLeafColumns().forEach(h=>{const f=e.indexOf(h);a.push(f)});const l=Math.max.apply(Math,a),c=Math.min.apply(Math,a),u=l-c,d=i.getLeafColumns().length-1;u>d&&(r=!1)}),r}function x1(e,t){if(!e||e.length==0)return;const r=t(e[0]);for(let n=1;n<e.length;n++)if(r!==t(e[n]))return;return r}function A1(e,t,r){if(!t.length)return;const n=t.length===1?t[0]:null,i=x1(t,o=>o.getPinned());e.dispatchEvent({type:"columnPinned",pinned:i??null,columns:t,column:n,source:r})}function KI(e,t,r){if(!t.length)return;const n=t.length===1?t[0]:null,i=x1(t,o=>o.isVisible());e.dispatchEvent({type:"columnVisible",visible:i,columns:t,column:n,source:r})}function qI(e,t,r,n){e.dispatchEvent({type:t,columns:r,column:r&&r.length==1?r[0]:null,source:n})}function Bi(e,t,r,n,i=null){t!=null&&t.length&&e.dispatchEvent({type:"columnResized",columns:t,column:t.length===1?t[0]:null,flexColumns:i,finished:r,source:n})}function cp(e,t,r){var C;const{colModel:n,rowGroupColsSvc:i,pivotColsSvc:o,autoColSvc:s,selectionColSvc:a,colAnimation:l,visibleCols:c,pivotResultCols:u,environment:d,valueColsSvc:h,eventSvc:f,gos:g}=e,m=n.getColDefCols()??[],p=a==null?void 0:a.getColumns();if(!(m!=null&&m.length)&&!(p!=null&&p.length))return!1;if(t!=null&&t.state&&!t.state.forEach)return Q(32),!1;const y=(S,A,P,E,O)=>{if(!S)return;const R=zI(A,t.defaultState),T=R("flex").value1;if(C1(e,S,R("hide").value1,R("sort").value1,R("sortIndex").value1,R("pinned").value1,T,r),T==null){const F=R("width").value1;if(F!=null){const I=S.getColDef().minWidth??d.getDefaultColumnMinWidth();I!=null&&F>=I&&S.setActualWidth(F,r)}}O||!S.isPrimary()||(h==null||h.syncColumnWithState(S,r,R),i==null||i.syncColumnWithState(S,r,R,P),o==null||o.syncColumnWithState(S,r,R,E))},w=(S,A,P)=>{var L,$;const E=P1(e,r),O=A.slice(),R={},T={},F=[],I=[],k=[];let B=0;const N=(i==null?void 0:i.columns.slice())??[],z=(o==null?void 0:o.columns.slice())??[];S.forEach(H=>{const V=H.colId;if(V.startsWith(uu)){F.push(H),k.push(H);return}if(xa(V)){I.push(H),k.push(H);return}const Y=P(V);Y?(y(Y,H,R,T,!1),Zt(O,Y)):(k.push(H),B+=1)});const W=H=>y(H,null,R,T,!1);O.forEach(W),i==null||i.sortColumns(Mv.bind(i,R,N)),o==null||o.sortColumns(Mv.bind(o,T,z)),n.refreshCols(!1);const D=(H,V,X=[])=>{V.forEach(Y=>{const re=H(Y.colId);Zt(X,re),y(re,Y,null,null,!0)}),X.forEach(W)};return D(H=>(s==null?void 0:s.getColumn(H))??null,F,(L=s==null?void 0:s.getColumns())==null?void 0:L.slice()),D(H=>(a==null?void 0:a.getColumn(H))??null,I,($=a==null?void 0:a.getColumns())==null?void 0:$.slice()),JI(t,n,g),c.refresh(r),f.dispatchEvent({type:"columnEverythingChanged",source:r}),E(),{unmatchedAndAutoStates:k,unmatchedCount:B}};l==null||l.start();let{unmatchedAndAutoStates:b,unmatchedCount:x}=w(t.state||[],m,S=>n.getColDefCol(S));if(b.length>0||ie(t.defaultState)){const S=((C=u==null?void 0:u.getPivotResultCols())==null?void 0:C.list)??[];x=w(b,S,A=>(u==null?void 0:u.getPivotResultCol(A))??null).unmatchedCount}return l==null||l.finish(),x===0}function P1(e,t){const{rowGroupColsSvc:r,pivotColsSvc:n,valueColsSvc:i,colModel:o,sortSvc:s,eventSvc:a}=e,l={rowGroupColumns:(r==null?void 0:r.columns.slice())??[],pivotColumns:(n==null?void 0:n.columns.slice())??[],valueColumns:(i==null?void 0:i.columns.slice())??[]},c=Ov(e),u={};return c.forEach(d=>{u[d.colId]=d}),()=>{const d=(S,A,P,E)=>{const O=A.map(E),R=P.map(E);if(mo(O,R))return;const F=new Set(A);P.forEach(k=>{F.delete(k)||F.add(k)});const I=[...F];a.dispatchEvent({type:S,columns:I,column:I.length===1?I[0]:null,source:t})},h=S=>{const A=[];return o.forAllCols(P=>{const E=u[P.getColId()];E&&S(E,P)&&A.push(P)}),A},f=S=>S.getColId();d("columnRowGroupChanged",l.rowGroupColumns,(r==null?void 0:r.columns)??[],f),d("columnPivotChanged",l.pivotColumns,(n==null?void 0:n.columns)??[],f);const m=h((S,A)=>{const P=S.aggFunc!=null,E=P!=A.isValueActive(),O=P&&S.aggFunc!=A.getAggFunc();return E||O});m.length>0&&qI(a,"columnValueChanged",m,t),Bi(a,h((S,A)=>S.width!=A.getActualWidth()),!0,t),A1(a,h((S,A)=>S.pinned!=A.getPinned()),t),KI(a,h((S,A)=>S.hide==A.isVisible()),t);const x=h((S,A)=>S.sort!=A.getSort()||S.sortIndex!=A.getSortIndex());x.length>0&&(s==null||s.dispatchSortChangedEvents(t,x));const C=Ov(e);ZI(c,C,t,o,a)}}function Ov(e){const{colModel:t,rowGroupColsSvc:r,pivotColsSvc:n}=e,i=t.getColDefCols();if(Xe(i)||!t.isAlive())return[];const o=r==null?void 0:r.columns,s=n==null?void 0:n.columns,a=[],l=u=>{const d=u.isRowGroupActive()&&o?o.indexOf(u):null,h=u.isPivotActive()&&s?s.indexOf(u):null,f=u.isValueActive()?u.getAggFunc():null,g=u.getSort()!=null?u.getSort():null,m=u.getSortIndex()!=null?u.getSortIndex():null;a.push({colId:u.getColId(),width:u.getActualWidth(),hide:!u.isVisible(),pinned:u.getPinned(),sort:g,sortIndex:m,aggFunc:f,rowGroup:u.isRowGroupActive(),rowGroupIndex:d,pivot:u.isPivotActive(),pivotIndex:h,flex:u.getFlex()??null})};t.forAllCols(u=>l(u));const c=new Map(t.getCols().map((u,d)=>[u.getColId(),d]));return a.sort((u,d)=>{const h=c.has(u.colId)?c.get(u.colId):-1,f=c.has(d.colId)?c.get(d.colId):-1;return h-f}),a}function YI(e){const t=(g,m)=>g??m??null,r=e.getColDef(),n=t(r.sort,r.initialSort),i=t(r.sortIndex,r.initialSortIndex),o=t(r.hide,r.initialHide),s=t(r.pinned,r.initialPinned),a=t(r.width,r.initialWidth),l=t(r.flex,r.initialFlex);let c=t(r.rowGroupIndex,r.initialRowGroupIndex),u=t(r.rowGroup,r.initialRowGroup);c==null&&(u==null||u==!1)&&(c=null,u=null);let d=t(r.pivotIndex,r.initialPivotIndex),h=t(r.pivot,r.initialPivot);d==null&&(h==null||h==!1)&&(d=null,h=null);const f=t(r.aggFunc,r.initialAggFunc);return{colId:e.getColId(),sort:n,sortIndex:i,hide:o,pinned:s,width:a,flex:l,rowGroup:u,rowGroupIndex:c,pivot:h,pivotIndex:d,aggFunc:f}}function JI(e,t,r){if(!e.applyOrder||!e.state)return;const n=[];e.state.forEach(i=>{i.colId!=null&&n.push(i.colId)}),XI(t.cols,n,t,r)}function XI(e,t,r,n){if(e==null)return;let i=[];const o={};t.forEach(a=>{if(o[a])return;const l=e.map[a];l&&(i.push(l),o[a]=!0)});let s=0;if(e.list.forEach(a=>{const l=a.getColId();if(o[l]!=null)return;l.startsWith(uu)?i.splice(s++,0,a):i.push(a)}),i=w1(i,n),!S1(i,r.getColTree())){Q(39);return}e.list=i}function ZI(e,t,r,n,i){const o={};t.forEach(u=>o[u.colId]=u);const s={};e.forEach(u=>{o[u.colId]&&(s[u.colId]=!0)});const a=e.filter(u=>s[u.colId]),l=t.filter(u=>s[u.colId]),c=[];l.forEach((u,d)=>{const h=a&&a[d];if(h&&h.colId!==u.colId){const f=n.getCol(h.colId);f&&c.push(f)}}),c.length&&i.dispatchEvent({type:"columnMoved",columns:c,column:c.length===1?c[0]:null,finished:!0,source:r})}var Mv=(e,t,r,n)=>{const i=e[r.getId()],o=e[n.getId()],s=i!=null,a=o!=null;if(s&&a)return i-o;if(s)return-1;if(a)return 1;const l=t.indexOf(r),c=t.indexOf(n),u=l>=0,d=c>=0;return u&&d?l-c:u?-1:1},QI=class extends q{constructor(){super(...arguments),this.beanName="colModel",this.pivotMode=!1,this.ready=!1,this.changeEventsDispatching=!1}postConstruct(){this.pivotMode=this.gos.get("pivotMode"),this.addManagedPropertyListeners(["groupDisplayType","treeData","treeDataDisplayType","groupHideOpenParents"],e=>this.refreshAll(Ri(e.source))),this.addManagedPropertyListeners(["defaultColDef","defaultColGroupDef","columnTypes","suppressFieldDotNotation"],this.recreateColumnDefs.bind(this)),this.addManagedPropertyListener("pivotMode",e=>this.setPivotMode(this.gos.get("pivotMode"),Ri(e.source)))}createColsFromColDefs(e){var w,b,x;const{beans:t}=this,{valueCache:r,colAutosize:n,rowGroupColsSvc:i,pivotColsSvc:o,valueColsSvc:s,visibleCols:a,colViewport:l,eventSvc:c}=t,u=this.colDefs?P1(t,e):void 0;r==null||r.expire();const d=(w=this.colDefCols)==null?void 0:w.list,h=(b=this.colDefCols)==null?void 0:b.tree,f=NI(t,this.colDefs,!0,h,e);Ll(t,(x=this.colDefCols)==null?void 0:x.tree,f.columnTree);const g=f.columnTree,m=f.treeDepth,p=_I(g),y={};p.forEach(C=>y[C.getId()]=C),this.colDefCols={tree:g,treeDepth:m,list:p,map:y},i==null||i.extractCols(e,d),o==null||o.extractCols(e,d),s==null||s.extractCols(e,d),this.ready=!0,this.refreshCols(!0),a.refresh(e),l.checkViewportColumns(),c.dispatchEvent({type:"columnEverythingChanged",source:e}),u&&(this.changeEventsDispatching=!0,u(),this.changeEventsDispatching=!1),c.dispatchEvent({type:"newColumnsLoaded",source:e}),e==="gridInitializing"&&(n==null||n.applyAutosizeStrategy())}refreshCols(e){var m;if(!this.colDefCols)return;const t=(m=this.cols)==null?void 0:m.tree;this.saveColOrder();const{autoColSvc:r,selectionColSvc:n,rowNumbersSvc:i,quickFilter:o,pivotResultCols:s,showRowGroupCols:a,rowAutoHeight:l,visibleCols:c,colViewport:u,eventSvc:d}=this.beans,h=this.selectCols(s,this.colDefCols);this.createColumnsForService([r,n,i],h);const f=iI(this.gos,this.showingPivotResult);(!e||f)&&this.restoreColOrder(h),this.positionLockedCols(h),a==null||a.refresh(),o==null||o.refreshCols(),this.setColSpanActive(),l==null||l.setAutoHeightActive(h),c.clear(),u.clear(),!mo(t,this.cols.tree)&&d.dispatchEvent({type:"gridColumnsChanged"})}createColumnsForService(e,t){for(const r of e)r&&(r.createColumns(t,n=>{this.lastOrder=n(this.lastOrder),this.lastPivotOrder=n(this.lastPivotOrder)}),r.addColumns(t))}selectCols(e,t){const r=(e==null?void 0:e.getPivotResultCols())??null;this.showingPivotResult=r!=null;const{map:n,list:i,tree:o,treeDepth:s}=r??t;return this.cols={list:i.slice(),map:{...n},tree:o.slice(),treeDepth:s},r&&(r.list.some(l=>{var c;return((c=this.cols)==null?void 0:c.map[l.getColId()])!==void 0})||(this.lastPivotOrder=null)),this.cols}getColsToShow(){var n;if(!this.cols)return[];const e=this.isPivotMode()&&!this.showingPivotResult,t=(n=this.beans.valueColsSvc)==null?void 0:n.columns;return this.cols.list.filter(i=>{const o=v1(i);if(e){const s=t==null?void 0:t.includes(i);return o||s}else return o||i.isVisible()})}refreshAll(e){this.ready&&(this.refreshCols(!1),this.beans.visibleCols.refresh(e))}setColsVisible(e,t=!1,r){cp(this.beans,{state:e.map(n=>({colId:typeof n=="string"?n:n.getColId(),hide:!t}))},r)}restoreColOrder(e){const t=this.showingPivotResult?this.lastPivotOrder:this.lastOrder;if(!t)return;const r=t.filter(d=>e.map[d.getId()]!=null);if(r.length===0)return;if(r.length===e.list.length){e.list=r;return}const n=d=>{const h=d.getOriginalParent();return h?h.getChildren().length>1?!0:n(h):!1};if(!r.some(d=>n(d))){const d=new Set(r);for(const h of e.list)d.has(h)||r.push(h);e.list=r;return}const i=new Map;for(let d=0;d<r.length;d++){const h=r[d];i.set(h,d)}const o=e.list.filter(d=>!i.has(d));if(o.length===0){e.list=r;return}const s=(d,h)=>{const f=h?h.getOriginalParent():d.getOriginalParent();if(!f)return null;let g=null,m=null;for(const p of f.getChildren())if(!(p===h||p===d)){if(p instanceof cu){const y=i.get(p);if(y==null)continue;(g==null||g<y)&&(g=y,m=p);continue}p.forEachLeafColumn(y=>{const w=i.get(y);w!=null&&(g==null||g<w)&&(g=w,m=y)})}return m??s(d,f)},a=[],l=new Map;for(const d of o){const h=s(d,null);if(h==null){a.push(d);continue}const f=l.get(h);f===void 0?l.set(h,d):Array.isArray(f)?f.push(d):l.set(h,[f,d])}const c=new Array(e.list.length);let u=c.length-1;for(let d=a.length-1;d>=0;d--)c[u--]=a[d];for(let d=r.length-1;d>=0;d--){const h=r[d],f=l.get(h);if(f)if(Array.isArray(f))for(let g=f.length-1;g>=0;g--){const m=f[g];c[u--]=m}else c[u--]=f;c[u--]=h}e.list=c}positionLockedCols(e){e.list=w1(e.list,this.gos)}saveColOrder(){var e,t;this.showingPivotResult?this.lastPivotOrder=((e=this.cols)==null?void 0:e.list)??null:this.lastOrder=((t=this.cols)==null?void 0:t.list)??null}getColumnDefs(){var e,t;return this.colDefCols?(t=this.beans.colDefFactory)==null?void 0:t.getColumnDefs(this.colDefCols.list,this.showingPivotResult,this.lastOrder,((e=this.cols)==null?void 0:e.list)??[]):void 0}setColSpanActive(){var e;this.colSpanActive=!!((e=this.cols)!=null&&e.list.some(t=>t.getColDef().colSpan!=null))}isPivotMode(){return this.pivotMode}setPivotMode(e,t){if(e===this.pivotMode||(this.pivotMode=e,!this.ready))return;this.refreshCols(!1);const{visibleCols:r,eventSvc:n}=this.beans;r.refresh(t),n.dispatchEvent({type:"columnPivotModeChanged"})}isPivotActive(){var t;const e=(t=this.beans.pivotColsSvc)==null?void 0:t.columns;return this.pivotMode&&!!(e!=null&&e.length)}recreateColumnDefs(e){var r;if(!this.cols)return;(r=this.beans.autoColSvc)==null||r.updateColumns(e);const t=Ri(e.source);this.createColsFromColDefs(t)}setColumnDefs(e,t){this.colDefs=e,this.createColsFromColDefs(t)}destroy(){var e;Ll(this.beans,(e=this.colDefCols)==null?void 0:e.tree),super.destroy()}getColTree(){var e;return((e=this.cols)==null?void 0:e.tree)??[]}getColDefColTree(){var e;return((e=this.colDefCols)==null?void 0:e.tree)??[]}getColDefCols(){var e;return((e=this.colDefCols)==null?void 0:e.list)??null}getCols(){var e;return((e=this.cols)==null?void 0:e.list)??[]}forAllCols(e){var i,o,s,a;const{pivotResultCols:t,autoColSvc:r,selectionColSvc:n}=this.beans;za((i=this.colDefCols)==null?void 0:i.list,e),za((o=r==null?void 0:r.columns)==null?void 0:o.list,e),za((s=n==null?void 0:n.columns)==null?void 0:s.list,e),za((a=t==null?void 0:t.getPivotResultCols())==null?void 0:a.list,e)}getColsForKeys(e){return e?e.map(t=>this.getCol(t)).filter(t=>t!=null):[]}getColDefCol(e){var t;return(t=this.colDefCols)!=null&&t.list?this.getColFromCollection(e,this.colDefCols):null}getCol(e){return e==null?null:this.getColFromCollection(e,this.cols)}getColById(e){var t;return((t=this.cols)==null?void 0:t.map[e])??null}getColFromCollection(e,t){var i,o;if(t==null)return null;const{map:r,list:n}=t;if(typeof e=="string"&&r[e])return r[e];for(let s=0;s<n.length;s++)if(y1(n[s],e))return n[s];return((i=this.beans.autoColSvc)==null?void 0:i.getColumn(e))??((o=this.beans.selectionColSvc)==null?void 0:o.getColumn(e))??null}},e_=class{constructor(){this.existingIds={}}getInstanceIdForKey(e){const t=this.existingIds[e];let r;return typeof t!="number"?r=0:r=t+1,this.existingIds[e]=r,r}},vo=class extends q{};function Aa(e,t,r){return r&&e.addDestroyFunc(()=>t.destroyBean(r)),r??e}var Pa=class{constructor(e){this.cssClassStates={},this.getGui=e}toggleCss(e,t){var n;if(!e)return;if(e.indexOf(" ")>=0){const i=(e||"").split(" ");if(i.length>1){i.forEach(o=>this.toggleCss(o,t));return}}this.cssClassStates[e]!==t&&e.length&&((n=this.getGui())==null||n.classList.toggle(e,t),this.cssClassStates[e]=t)}},t_=0,fe=null,ct=class extends q{constructor(e,t){super(),this.suppressDataRefValidation=!1,this.displayed=!0,this.visible=!0,this.compId=t_++,this.cssManager=new Pa(()=>this.eGui),this.componentSelectors=new Map((t??[]).map(r=>[r.selector,r])),e&&this.setTemplate(e)}preConstruct(){var t,r,n;this.wireTemplate(this.getGui());const e="component-"+((r=(t=Object.getPrototypeOf(this))==null?void 0:t.constructor)==null?void 0:r.name);(n=this.css)==null||n.forEach(i=>this.beans.environment.addGlobalCSS(i,e))}wireTemplate(e,t){e&&this.gos&&(this.applyElementsToComponent(e),this.createChildComponentsFromTags(e,t))}getCompId(){return this.compId}getDataRefAttribute(e){return e.getAttribute?e.getAttribute(Y2):null}applyElementsToComponent(e,t,r,n=null){if(t===void 0&&(t=this.getDataRefAttribute(e)),t){const i=this[t];if(i===fe)this[t]=n??e;else{const o=r&&r[t];if(!this.suppressDataRefValidation&&!o)throw new Error(`data-ref: ${t} on ${this.constructor.name} with ${i}`)}}}createChildComponentsFromTags(e,t){const r=[];for(const n of e.childNodes??[])r.push(n);r.forEach(n=>{if(!(n instanceof HTMLElement))return;const i=this.createComponentFromElement(n,o=>{const s=o.getGui();if(s)for(const a of n.attributes??[])s.setAttribute(a.name,a.value)},t);if(i){if(i.addItems&&n.children.length){this.createChildComponentsFromTags(n,t);const o=Array.prototype.slice.call(n.children);i.addItems(o)}this.swapComponentForNode(i,e,n)}else n.childNodes&&this.createChildComponentsFromTags(n,t)})}createComponentFromElement(e,t,r){const n=e.nodeName,i=this.getDataRefAttribute(e),o=n.indexOf("AG-")===0,s=o?this.componentSelectors.get(n):null;let a=null;if(s){const l=r&&i?r[i]:void 0;a=new s.component(l),a.setParentComponent(this),this.createBean(a,null,t)}else if(o)throw new Error(`selector: ${n}`);return this.applyElementsToComponent(e,i,r,a),a}swapComponentForNode(e,t,r){const n=e.getGui();t.replaceChild(n,r),t.insertBefore(document.createComment(r.nodeName),n),this.addDestroyFunc(this.destroyBean.bind(this,e))}activateTabIndex(e){const t=this.gos.get("tabIndex");e||(e=[]),e.length||e.push(this.getGui()),e.forEach(r=>r.setAttribute("tabindex",t.toString()))}setTemplate(e,t,r){let n;typeof e=="string"||e==null?n=np(e):n=lt(e),this.setTemplateFromElement(n,t,r)}setTemplateFromElement(e,t,r,n=!1){if(this.eGui=e,this.suppressDataRefValidation=n,t)for(let i=0;i<t.length;i++){const o=t[i];this.componentSelectors.set(o.selector,o)}this.wireTemplate(e,r)}getGui(){return this.eGui}getFocusableElement(){return this.eGui}getAriaElement(){return this.getFocusableElement()}setParentComponent(e){this.parentComponent=e}getParentComponent(){return this.parentComponent}setGui(e){this.eGui=e}queryForHtmlElement(e){return this.eGui.querySelector(e)}getContainerAndElement(e,t){let r=t;return e==null?null:(r||(r=this.eGui),q2(e)?{element:e,parent:r}:{element:e.getGui(),parent:r})}prependChild(e,t){const{element:r,parent:n}=this.getContainerAndElement(e,t)||{};!r||!n||n.insertAdjacentElement("afterbegin",r)}appendChild(e,t){const{element:r,parent:n}=this.getContainerAndElement(e,t)||{};!r||!n||n.appendChild(r)}isDisplayed(){return this.displayed}setVisible(e,t={}){if(e!==this.visible){this.visible=e;const{skipAriaHidden:r}=t;Wk(this.eGui,e,{skipAriaHidden:r})}}setDisplayed(e,t={}){if(e!==this.displayed){this.displayed=e;const{skipAriaHidden:r}=t;Je(this.eGui,e,{skipAriaHidden:r});const n={type:"displayChanged",visible:this.displayed};this.dispatchLocalEvent(n)}}destroy(){this.parentComponent&&(this.parentComponent=void 0),super.destroy()}addGuiEventListener(e,t,r){this.eGui.addEventListener(e,t,r),this.addDestroyFunc(()=>this.eGui.removeEventListener(e,t))}addCss(e){this.cssManager.toggleCss(e,!0)}removeCss(e){this.cssManager.toggleCss(e,!1)}toggleCss(e,t){this.cssManager.toggleCss(e,t)}registerCSS(e){this.css||(this.css=[]),this.css.push(e)}},Ie=class Qo{constructor(t){this.status=0,this.resolution=null,this.waiters=[],t(r=>this.onDone(r),r=>this.onReject(r))}static all(t){return t.length?new Qo(r=>{let n=t.length;const i=new Array(n);t.forEach((o,s)=>{o.then(a=>{i[s]=a,n--,n===0&&r(i)})})}):Qo.resolve()}static resolve(t=null){return new Qo(r=>r(t))}then(t){return new Qo(r=>{this.status===1?r(t(this.resolution)):this.waiters.push(n=>r(t(n)))})}onDone(t){this.status=1,this.resolution=t,this.waiters.forEach(r=>r(t))}onReject(t){}};function r_(e){return e?e.prototype&&"getGui"in e.prototype:!1}function R1(e,t,r,n){const{name:i}=r;let o,s,a,l,c,u;if(t){const d=t,h=d[i+"Selector"],f=h?h(n):null,g=m=>{typeof m=="string"?o=m:m!=null&&m!==!0&&(e.isFrameworkComponent(m)?a=m:s=m)};f?(g(f.component),l=f.params,c=f.popup,u=f.popupPosition):g(d[i])}return{compName:o,jsComp:s,fwComp:a,paramsFromSelector:l,popupFromSelector:c,popupPositionFromSelector:u}}var n_=class extends q{constructor(){super(...arguments),this.beanName="userCompFactory"}wireBeans(e){this.agCompUtils=e.agCompUtils,this.registry=e.registry,this.frameworkCompWrapper=e.frameworkCompWrapper,this.gridOptions=e.gridOptions}getCompDetailsFromGridOptions(e,t,r,n=!1){return this.getCompDetails(this.gridOptions,e,t,r,n)}getCompDetails(e,t,r,n,i=!1){var w;const{name:o,cellRenderer:s}=t;let{compName:a,jsComp:l,fwComp:c,paramsFromSelector:u,popupFromSelector:d,popupPositionFromSelector:h}=R1(this.beans.frameworkOverrides,e,t,n),f;const g=b=>{const x=this.registry.getUserComponent(o,b);x&&(l=x.componentFromFramework?void 0:x.component,c=x.componentFromFramework?x.component:void 0,f=x.params)};if(a!=null&&g(a),l==null&&c==null&&r!=null&&g(r),l&&s&&!r_(l)&&(l=(w=this.agCompUtils)==null?void 0:w.adaptFunction(t,l)),!l&&!c){const{validation:b}=this.beans;i&&(a!==r||!r)?a?b!=null&&b.isProvidedUserComp(a)||_e(50,{compName:a}):r?b||_e(260,{...this.gos.getModuleErrorParams(),propName:o,compName:r}):_e(216,{name:o}):r&&!b&&_e(146,{comp:r});return}const m=this.mergeParams(e,t,n,u,f),p=l==null,y=l??c;return{componentFromFramework:p,componentClass:y,params:m,type:t,popupFromSelector:d,popupPositionFromSelector:h,newAgStackInstance:()=>this.newAgStackInstance(y,p,m,t)}}newAgStackInstance(e,t,r,n){var a;const i=!t;let o;i?o=new e:o=this.frameworkCompWrapper.wrap(e,n.mandatoryMethods,n.optionalMethods,n),this.createBean(o);const s=(a=o.init)==null?void 0:a.call(o,r);return s==null?Ie.resolve(o):s.then(()=>o)}mergeParams(e,t,r,n=null,i){const o={...r,...i},s=e,a=s&&s[t.name+"Params"];if(typeof a=="function"){const l=a(r);Et(o,l)}else typeof a=="object"&&Et(o,a);return Et(o,n),o}},i_={name:"dragAndDropImageComponent",mandatoryMethods:["setIcon","setLabel"]},o_={name:"headerComponent",optionalMethods:["refresh"]},s_={name:"innerHeaderComponent"},a_={name:"innerHeaderGroupComponent"},l_={name:"headerGroupComponent"},c_={name:"cellRenderer",optionalMethods:["refresh","afterGuiAttached"],cellRenderer:!0},u_={name:"loadingCellRenderer",cellRenderer:!0},d_={name:"loadingOverlayComponent",optionalMethods:["refresh"]},h_={name:"noRowsOverlayComponent",optionalMethods:["refresh"]},f_={name:"tooltipComponent"},up={name:"filter",mandatoryMethods:["isFilterActive","doesFilterPass","getModel","setModel"],optionalMethods:["afterGuiAttached","afterGuiDetached","onNewRowsLoaded","getModelAsString","onFloatingFilterChanged","onAnyFilterChanged","refresh"]},g_={name:"floatingFilterComponent",mandatoryMethods:["onParentModelChanged"],optionalMethods:["afterGuiAttached","refresh"]},p_={name:"fullWidthCellRenderer",optionalMethods:["refresh","afterGuiAttached"],cellRenderer:!0},m_={name:"loadingCellRenderer",cellRenderer:!0},v_={name:"groupRowRenderer",optionalMethods:["afterGuiAttached"],cellRenderer:!0},y_={name:"detailCellRenderer",optionalMethods:["refresh"],cellRenderer:!0};function b_(e,t){return e.getCompDetailsFromGridOptions(i_,"agDragAndDropImage",t,!0)}function C_(e,t,r){return e.getCompDetails(t,o_,"agColumnHeader",r)}function w_(e,t,r){return e.getCompDetails(t,s_,void 0,r)}function S_(e,t){const r=t.columnGroup.getColGroupDef();return e.getCompDetails(r,l_,"agColumnGroupHeader",t)}function x_(e,t,r){return e.getCompDetails(t,a_,void 0,r)}function A_(e,t){return e.getCompDetailsFromGridOptions(p_,void 0,t,!0)}function P_(e,t){return e.getCompDetailsFromGridOptions(m_,"agLoadingCellRenderer",t,!0)}function R_(e,t){return e.getCompDetailsFromGridOptions(v_,"agGroupRowRenderer",t,!0)}function E_(e,t){return e.getCompDetailsFromGridOptions(y_,"agDetailCellRenderer",t,!0)}function Dv(e,t,r){return e.getCompDetails(t,c_,void 0,r)}function T_(e,t,r){return e.getCompDetails(t,u_,"agSkeletonCellRenderer",r,!0)}function F_(e,t,r,n){return e.getCompDetails(t,up,n,r,!0)}function O_(e,t){return e.getCompDetailsFromGridOptions(d_,"agLoadingOverlay",t,!0)}function M_(e,t){return e.getCompDetailsFromGridOptions(h_,"agNoRowsOverlay",t,!0)}function D_(e,t){return e.getCompDetails(t.colDef,f_,"agTooltipComponent",t,!0)}function k_(e,t,r,n){return e.getCompDetails(t,g_,n,r)}function I_(e,t){return R1(e,t,up)}function __(e,t,r){return e.mergeParams(t,up,r)}function kv(e){const t=e;return t!=null&&t.getFrameworkComponentInstance!=null?t.getFrameworkComponentInstance():e}var E1=new Set,zl={},_n={},ml,T1=!1,F1=!1,L_=!1;function B_(e){const[t,r]=e.version.split(".")||[],[n,i]=ml.split(".")||[];return t===n&&r===i}function z_(e){ml||(ml=e.version);const t=r=>`You are using incompatible versions of AG Grid modules. Major and minor versions should always match across modules. ${r} Please update all modules to the same version.`;if(e.version?B_(e)||ss(t(`'${e.moduleName}' is version ${e.version} but the other modules are version ${ml}.`)):ss(t(`'${e.moduleName}' is incompatible.`)),e.validate){const r=e.validate();r.isValid||ss(`${r.message}`)}}function Fs(e,t,r=!1){r||(T1=!0),z_(e);const n=e.rowModels??["all"];E1.add(e);let i;t!==void 0?(F1=!0,_n[t]===void 0&&(_n[t]={}),i=_n[t]):i=zl,n.forEach(o=>{i[o]===void 0&&(i[o]={}),i[o][e.moduleName]=e}),e.dependsOn&&e.dependsOn.forEach(o=>Fs(o,t,r))}function N_(e){delete _n[e]}function Lh(e,t,r){const n=i=>{var o,s,a;return!!((o=zl[i])!=null&&o[e])||!!((a=(s=_n[t])==null?void 0:s[i])!=null&&a[e])};return n(r)||n("all")}function O1(){return F1}function $_(e,t){const r=_n[e]??{};return[...Object.values(zl.all??{}),...Object.values(r.all??{}),...Object.values(zl[t]??{}),...Object.values(r[t]??{})]}function H_(){return new Set(E1)}function G_(e,t){const r=_n[e]??{};return[...Object.values(r.all??{}),...Object.values(r[t]??{})]}function W_(){return T1}function j_(){return L_}var V_=class{static register(e){Fs(e,void 0)}static registerModules(e){e.forEach(t=>Fs(t,void 0))}},U_=class{constructor(e){this.beans={},this.createdBeans=[],this.destroyed=!1,!(!e||!e.beanClasses)&&(this.beanDestroyComparator=e.beanDestroyComparator,this.init(e))}init(e){var t;for(const r of Object.keys(e.providedBeanInstances))this.beans[r]=e.providedBeanInstances[r];e.beanClasses.forEach(r=>{const n=new r;n.beanName?this.beans[n.beanName]=n:console.error(`Bean ${r.name} is missing beanName`),this.createdBeans.push(n)}),(t=e.derivedBeans)==null||t.forEach(r=>{const{beanName:n,bean:i}=r(this);this.beans[n]=i,this.createdBeans.push(i)}),e.beanInitComparator&&this.createdBeans.sort(e.beanInitComparator),this.initBeans(this.createdBeans)}getBeanInstances(){return Object.values(this.beans)}createBean(e,t){if(!e)throw Error("null bean");return this.initBeans([e],t),e}initBeans(e,t){e.forEach(r=>{var n,i;(n=r.preWireBeans)==null||n.call(r,this.beans),(i=r.wireBeans)==null||i.call(r,this.beans)}),e.forEach(r=>{var n;return(n=r.preConstruct)==null?void 0:n.call(r)}),t&&e.forEach(t),e.forEach(r=>{var n;return(n=r.postConstruct)==null?void 0:n.call(r)})}getBeans(){return this.beans}getBean(e){return this.beans[e]}destroy(){if(this.destroyed)return;this.destroyed=!0;const e=this.getBeanInstances();this.beanDestroyComparator&&e.sort(this.beanDestroyComparator),this.destroyBeans(e),this.beans={},this.createdBeans=[]}destroyBean(e){var t;(t=e==null?void 0:e.destroy)==null||t.call(e)}destroyBeans(e){if(e)for(let t=0;t<e.length;t++)this.destroyBean(e[t]);return[]}isDestroyed(){return this.destroyed}},K_=class extends U_{init(e){this.gridId=e.gridId,this.beans.context=this,this.destroyCallback=e.destroyCallback,super.init(e)}destroy(){var e;super.destroy(),N_(this.gridId),(e=this.destroyCallback)==null||e.call(this)}getGridId(){return this.gridId}},q_="ag-column-first",Y_="ag-column-last";function M1(e,t,r,n){return Xe(e)?[]:X_(e.headerClass,e,t,r,n)}function D1(e,t,r){e.toggleCss(q_,r.isColAtEdge(t,"first")),e.toggleCss(Y_,r.isColAtEdge(t,"last"))}function J_(e,t,r,n){return pe(t,{colDef:e,column:r,columnGroup:n})}function X_(e,t,r,n,i){if(Xe(e))return[];let o;if(typeof e=="function"){const s=J_(t,r,n,i);o=e(s)}else o=e;return typeof o=="string"?[o]:Array.isArray(o)?[...o]:[]}function Ra(e){return!!(e.rowPinned&&e.pinnedSibling)}function Wt(e,t,r,n){const i=t==="top";if(!r)return Wt(e,t,i?e.getPinnedTopRow(0):e.getPinnedBottomRow(0),n);if(!n){const l=i?e.getPinnedTopRowCount():e.getPinnedBottomRowCount();return Wt(e,t,r,i?e.getPinnedTopRow(l-1):e.getPinnedBottomRow(l-1))}let o=!1,s=!1;const a=[];return e.forEachPinnedRow(t,l=>{if(l===r&&!o){o=!0,a.push(l);return}if(o&&l===n){s=!0,a.push(l);return}o&&!s&&a.push(l)}),a}var j={BACKSPACE:"Backspace",TAB:"Tab",ENTER:"Enter",ESCAPE:"Escape",SPACE:" ",LEFT:"ArrowLeft",UP:"ArrowUp",RIGHT:"ArrowRight",DOWN:"ArrowDown",DELETE:"Delete",F2:"F2",PAGE_UP:"PageUp",PAGE_DOWN:"PageDown",PAGE_HOME:"Home",PAGE_END:"End",A:"KeyA",C:"KeyC",D:"KeyD",V:"KeyV",X:"KeyX",Y:"KeyY",Z:"KeyZ"},Bh=!1,Nl=0;function Z_(e){Nl>0||(e.addEventListener("keydown",$l),e.addEventListener("mousedown",$l))}function Q_(e){Nl>0||(e.removeEventListener("keydown",$l),e.removeEventListener("mousedown",$l))}function $l(e){const t=Bh,r=e.type==="keydown";r&&(e.ctrlKey||e.metaKey||e.altKey)||t!==r&&(Bh=r)}function eL(e){const t=gt(e);return Z_(t),Nl++,()=>{Nl--,Q_(t)}}function tL(){return Bh}function Ei(e,t,r=!1){const n=Gk;let i=j2;t&&(i+=", "+t),r&&(i+=', [tabindex="-1"]');const o=Array.prototype.slice.apply(e.querySelectorAll(n)).filter(l=>Sr(l)),s=Array.prototype.slice.apply(e.querySelectorAll(i));return s.length?((l,c)=>l.filter(u=>c.indexOf(u)===-1))(o,s):o}function qn(e,t=!1,r=!1,n=!1){const i=Ei(e,n?".ag-tab-guard":null,r),o=t?Ee(i):i[0];return o?(o.focus({preventScroll:!0}),!0):!1}function yo(e,t,r,n){const i=Ei(t,r?':not([tabindex="-1"])':null),o=Ke(e);let s;r?s=i.findIndex(l=>l.contains(o)):s=i.indexOf(o);const a=s+(n?-1:1);return a<0||a>=i.length?null:i[a]}function k1(e,t=5){let r=0;for(;e&&bv(e)===null&&++r<=t;)e=e.parentElement;return bv(e)===null?null:e}function Ln(e){var t;return e.gos.get("suppressHeaderFocus")||!!((t=e.overlays)!=null&&t.isExclusive())}function dp(e){var t;return e.gos.get("suppressCellFocus")||!!((t=e.overlays)!=null&&t.isExclusive())}function Os(e,t,r=!1){const n=e.ctrlsSvc.get("gridCtrl");return!r&&n.focusNextInnerContainer(t)?!0:((r||!t&&!n.isDetailGrid())&&n.forceFocusOutOfContainer(t),!1)}function rL(e,t=!1){return e===j.DELETE?!0:!t&&e===j.BACKSPACE?H2():!1}var nL=class extends q{constructor(e,t,r,n){super(),this.cellCtrl=e,this.rowNode=r,this.rowCtrl=n,this.beans=t}init(){this.eGui=this.cellCtrl.eGui}onKeyDown(e){const t=e.key;switch(t){case j.ENTER:this.onEnterKeyDown(e);break;case j.F2:this.onF2KeyDown(e);break;case j.ESCAPE:this.onEscapeKeyDown(e);break;case j.TAB:this.onTabKeyDown(e);break;case j.BACKSPACE:case j.DELETE:this.onBackspaceOrDeleteKeyDown(t,e);break;case j.DOWN:case j.UP:case j.RIGHT:case j.LEFT:this.onNavigationKeyDown(e,t);break}}onNavigationKeyDown(e,t){var r;if(!this.cellCtrl.editing){if(e.shiftKey&&this.cellCtrl.isRangeSelectionEnabled())this.onShiftRangeSelect(e);else{const n=this.cellCtrl.getFocusedCellPosition();(r=this.beans.navigation)==null||r.navigateToNextCell(e,t,n,!0)}e.preventDefault()}}onShiftRangeSelect(e){const{rangeSvc:t,navigation:r}=this.beans;if(!t)return;const n=t.extendLatestRangeInDirection(e);n&&(r==null||r.ensureCellVisible(n))}onTabKeyDown(e){var t;(t=this.beans.navigation)==null||t.onTabKeyDown(this.cellCtrl,e)}onBackspaceOrDeleteKeyDown(e,t){var l;const{cellCtrl:r,beans:n,rowNode:i}=this,{gos:o,rangeSvc:s,eventSvc:a}=n;if(!r.editing){if(a.dispatchEvent({type:"keyShortcutChangedCellStart"}),rL(e,o.get("enableCellEditingOnBackspace"))){if(s&&Es(o))s.clearCellRangeCellValues({dispatchWrapperEvents:!0,wrapperEventSource:"deleteKey"});else if(r.isCellEditable()){const{column:c}=r,u=this.beans.valueSvc.getDeleteValue(c,i);i.setDataValue(c,u,"cellClear")}}else(l=n.editSvc)==null||l.startRowOrCellEdit(r,e,t);a.dispatchEvent({type:"keyShortcutChangedCellEnd"})}}onEnterKeyDown(e){var n,i,o;const{cellCtrl:t,beans:r}=this;if(t.editing||this.rowCtrl.editing)(n=this.beans.editSvc)==null||n.stopRowOrCellEdit(t,!1,!1,e.shiftKey);else if(r.gos.get("enterNavigatesVertically")){const s=e.shiftKey?j.UP:j.DOWN;(i=r.navigation)==null||i.navigateToNextCell(null,s,t.cellPosition,!1)}else(o=r.editSvc)==null||o.startRowOrCellEdit(t,j.ENTER,e),t.editing&&e.preventDefault()}onF2KeyDown(e){var n;const{cellCtrl:t,beans:r}=this;t.editing||(n=r.editSvc)==null||n.startRowOrCellEdit(t,j.F2,e)}onEscapeKeyDown(e){var n;const{cellCtrl:t,beans:r}=this;t.editing&&((n=r.editSvc)==null||n.stopRowOrCellEdit(t,!0))}processCharacter(e){var i;if(e.target!==this.eGui||this.cellCtrl.editing)return;const n=e.key;n===j.SPACE?this.onSpaceKeyDown(e):(i=this.beans.editSvc)!=null&&i.startRowOrCellEdit(this.cellCtrl,n,e)&&e.preventDefault()}onSpaceKeyDown(e){var r;const{gos:t}=this.beans;!this.cellCtrl.editing&&In(t)&&((r=this.beans.selectionSvc)==null||r.handleSelectionEvent(e,this.rowNode,"spaceKey")),e.preventDefault()}destroy(){super.destroy()}},iL=class extends q{constructor(e,t,r){super(),this.cellCtrl=e,this.column=r,this.beans=t}onMouseEvent(e,t){if(!Lr(t))switch(e){case"click":this.onCellClicked(t);break;case"mousedown":case"touchstart":this.onMouseDown(t);break;case"dblclick":this.onCellDoubleClicked(t);break;case"mouseout":this.onMouseOut(t);break;case"mouseover":this.onMouseOver(t);break}}onCellClicked(e){var c;if((c=this.beans.touchSvc)!=null&&c.handleCellDoubleClick(this,e))return;const{eventSvc:t,rangeSvc:r,gos:n,editSvc:i}=this.beans,o=e.ctrlKey||e.metaKey;r&&o&&r.getCellRangeCount(this.cellCtrl.cellPosition)>1&&r.intersectLastRange(!0);const s=this.cellCtrl.createEvent(e,"cellClicked");t.dispatchEvent(s);const a=this.column.getColDef();a.onCellClicked&&window.setTimeout(()=>{this.beans.frameworkOverrides.wrapOutgoing(()=>{a.onCellClicked(s)})},0),(n.get("singleClickEdit")||a.singleClickEdit)&&!n.get("suppressClickEdit")&&!(e.shiftKey&&(r==null?void 0:r.getCellRanges().length)!=0)&&(i==null||i.startRowOrCellEdit(this.cellCtrl,void 0,e))}onCellDoubleClicked(e){const{column:t,beans:r,cellCtrl:n}=this,{eventSvc:i,frameworkOverrides:o,gos:s,editSvc:a}=r,l=t.getColDef(),c=n.createEvent(e,"cellDoubleClicked");i.dispatchEvent(c),typeof l.onCellDoubleClicked=="function"&&window.setTimeout(()=>{o.wrapOutgoing(()=>{l.onCellDoubleClicked(c)})},0),!s.get("singleClickEdit")&&!s.get("suppressClickEdit")&&(a==null||a.startRowOrCellEdit(n,null,e))}onMouseDown(e){const{ctrlKey:t,metaKey:r,shiftKey:n}=e,i=e.target,{cellCtrl:o,beans:s}=this,{eventSvc:a,rangeSvc:l,rowNumbersSvc:c,focusSvc:u,gos:d}=s;if(this.isRightClickInExistingRange(e))return;const h=l&&!l.isEmpty(),f=this.containsWidget(i),{cellPosition:g}=o,m=Pi(g.column);if(c&&m&&!c.handleMouseDownOnCell(g,e)){l&&e.preventDefault(),e.stopImmediatePropagation();return}if(!n||!h){const y=d.get("enableCellTextSelection")&&e.defaultPrevented,w=(ep()||y)&&!o.editing&&!tp(i)&&!f;o.focusCell(w)}if(n&&h&&!u.isCellFocused(g)){e.preventDefault();const p=u.getFocusedCell();if(p){const{column:y,rowIndex:w,rowPinned:b}=p,x=s.rowRenderer.getRowByPosition({rowIndex:w,rowPinned:b}),C=x==null?void 0:x.getCellCtrl(y);C!=null&&C.editing&&C.stopEditing(),u.setFocusedCell({column:y,rowIndex:w,rowPinned:b,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0})}}if(!f){if(l)if(m&&e.preventDefault(),n)l.extendLatestRangeToCell(g);else{const p=t||r;l.setRangeToCell(g,p)}a.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseDown"))}}isRightClickInExistingRange(e){const{rangeSvc:t}=this.beans;if(t){const r=t.isCellInAnyRange(this.cellCtrl.cellPosition),n=e.button===2||e.ctrlKey&&this.beans.gos.get("allowContextMenuWithControlKey");if(r&&n)return!0}return!1}containsWidget(e){return kn(e,"ag-selection-checkbox",3)||kn(e,"ag-drag-handle",3)}onMouseOut(e){if(this.mouseStayingInsideCell(e))return;const{eventSvc:t,colHover:r}=this.beans;t.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseOut")),r==null||r.clearMouseOver()}onMouseOver(e){if(this.mouseStayingInsideCell(e))return;const{eventSvc:t,colHover:r}=this.beans;t.dispatchEvent(this.cellCtrl.createEvent(e,"cellMouseOver")),r==null||r.setMouseOver([this.column])}mouseStayingInsideCell(e){if(!e.target||!e.relatedTarget)return!1;const t=this.cellCtrl.eGui,r=t.contains(e.target),n=t.contains(e.relatedTarget);return r&&n}destroy(){super.destroy()}},oL=class extends q{constructor(e,t){super(),this.cellCtrl=e,this.beans=t,this.column=e.column,this.rowNode=e.rowNode}setupRowSpan(){this.rowSpan=this.column.getRowSpan(this.rowNode),this.addManagedListeners(this.beans.eventSvc,{newColumnsLoaded:()=>this.onNewColumnsLoaded()})}init(){this.eSetLeft=this.cellCtrl.getRootElement(),this.eContent=this.cellCtrl.eGui;const e=this.cellCtrl.getCellSpan();if(e||(this.setupColSpan(),this.setupRowSpan()),this.onLeftChanged(),this.onWidthChanged(),e||this._legacyApplyRowSpan(),e){const t=this.refreshSpanHeight.bind(this,e);t(),this.addManagedListeners(this.beans.eventSvc,{paginationChanged:t,recalculateRowBounds:t,pinnedHeightChanged:t})}}refreshSpanHeight(e){const t=e.getCellHeight();t!=null&&(this.eContent.style.height=`${t}px`)}onNewColumnsLoaded(){const e=this.column.getRowSpan(this.rowNode);this.rowSpan!==e&&(this.rowSpan=e,this._legacyApplyRowSpan(!0))}onDisplayColumnsChanged(){const e=this.getColSpanningList();mo(this.colsSpanning,e)||(this.colsSpanning=e,this.onWidthChanged(),this.onLeftChanged())}setupColSpan(){this.column.getColDef().colSpan!=null&&(this.colsSpanning=this.getColSpanningList(),this.addManagedListeners(this.beans.eventSvc,{displayedColumnsChanged:this.onDisplayColumnsChanged.bind(this),displayedColumnsWidthChanged:this.onWidthChanged.bind(this)}))}onWidthChanged(){if(!this.eContent)return;const e=this.getCellWidth();this.eContent.style.width=`${e}px`}getCellWidth(){return this.colsSpanning?this.colsSpanning.reduce((e,t)=>e+t.getActualWidth(),0):this.column.getActualWidth()}getColSpanningList(){const{column:e,rowNode:t}=this,r=e.getColSpan(t),n=[];if(r===1)n.push(e);else{let i=e;const o=e.getPinned();for(let s=0;i&&s<r&&(n.push(i),i=this.beans.visibleCols.getColAfter(i),!(!i||Xe(i)||o!==i.getPinned()));s++);}return n}onLeftChanged(){if(!this.eSetLeft)return;const e=this.modifyLeftForPrintLayout(this.getCellLeft());this.eSetLeft.style.left=e+"px"}getCellLeft(){let e;return this.beans.gos.get("enableRtl")&&this.colsSpanning?e=Ee(this.colsSpanning):e=this.column,e.getLeft()}modifyLeftForPrintLayout(e){if(!this.cellCtrl.printLayout||this.column.getPinned()==="left")return e;const{visibleCols:t}=this.beans,r=t.getColsLeftWidth();if(this.column.getPinned()==="right"){const n=t.bodyWidth;return r+n+(e||0)}return r+(e||0)}_legacyApplyRowSpan(e){if(this.rowSpan===1&&!e)return;const r=as(this.beans)*this.rowSpan;this.eContent.style.height=`${r}px`,this.eContent.style.zIndex="1"}destroy(){super.destroy()}},sL="ag-cell",aL="ag-cell-auto-height",lL="ag-cell-normal-height",cL="ag-cell-focus",uL="ag-cell-first-right-pinned",dL="ag-cell-last-left-pinned",hL="ag-cell-not-inline-editing",fL="ag-cell-wrap-text",Hl="cellCtrl";function I1(e,t){return h1(e,t,Hl)}var gL=0,vl=class extends q{constructor(e,t,r,n){super(),this.column=e,this.rowNode=t,this.rowCtrl=n,this.rangeFeature=void 0,this.rowResizeFeature=void 0,this.positionFeature=void 0,this.customStyleFeature=void 0,this.tooltipFeature=void 0,this.mouseListener=void 0,this.keyboardListener=void 0,this.suppressRefreshCell=!1,this.onCompAttachedFuncs=[],this.onEditorAttachedFuncs=[],this.focusEventWhileNotReady=null,this.hasBeenFocused=!1,this.beans=r;const{colId:i}=e;this.instanceId=i+"-"+gL++,this.createCellPosition(),this.updateAndFormatValue(!1)}addFeatures(){var n;const{beans:e}=this;this.positionFeature=new oL(this,e),this.customStyleFeature=(n=e.cellStyles)==null?void 0:n.createCellCustomStyleFeature(this,e),this.mouseListener=new iL(this,e,this.column),this.keyboardListener=new nL(this,e,this.rowNode,this.rowCtrl),this.column.isTooltipEnabled()&&this.enableTooltipFeature();const{rangeSvc:t}=e;t&&Es(e.gos)&&(this.rangeFeature=t.createCellRangeFeature(e,this)),Pi(this.column)&&(this.rowResizeFeature=this.beans.rowNumbersSvc.createRowNumbersRowResizerFeature(e,this))}isCellSpanning(){return!1}getCellSpan(){}removeFeatures(){const e=this.beans.context;this.positionFeature=e.destroyBean(this.positionFeature),this.customStyleFeature=e.destroyBean(this.customStyleFeature),this.mouseListener=e.destroyBean(this.mouseListener),this.keyboardListener=e.destroyBean(this.keyboardListener),this.rangeFeature=e.destroyBean(this.rangeFeature),this.rowResizeFeature=e.destroyBean(this.rowResizeFeature),this.disableTooltipFeature()}enableTooltipFeature(e,t){var r;this.tooltipFeature=(r=this.beans.tooltipSvc)==null?void 0:r.enableCellTooltipFeature(this,e,t)}disableTooltipFeature(){this.tooltipFeature=this.beans.context.destroyBean(this.tooltipFeature)}setComp(e,t,r,n,i,o,s){var a,l,c,u,d,h,f;this.comp=e,this.eGui=t,this.printLayout=i,s??(s=this),this.addDomData(s),this.addFeatures(),s.addDestroyFunc(()=>this.removeFeatures()),this.onSuppressCellFocusChanged(this.beans.gos.get("suppressCellFocus")),this.setupFocus(),this.applyStaticCssClasses(),this.setWrapText(),this.onFirstRightPinnedChanged(),this.onLastLeftPinnedChanged(),this.onColumnHover(),this.setupControlComps(),this.setupAutoHeight(n,s),this.refreshFirstAndLastStyles(),this.refreshAriaColIndex(),(a=this.positionFeature)==null||a.init(),(l=this.customStyleFeature)==null||l.setComp(e),(c=this.tooltipFeature)==null||c.refreshTooltip(),(u=this.keyboardListener)==null||u.init(),(d=this.rangeFeature)==null||d.setComp(e),(h=this.rowResizeFeature)==null||h.refreshRowResizer(),o&&this.isCellEditable()?(f=this.beans.editSvc)==null||f.startEditing(this):this.showValue(!1,!0),this.onCompAttachedFuncs.length&&(this.onCompAttachedFuncs.forEach(g=>g()),this.onCompAttachedFuncs=[])}setupAutoHeight(e,t){var r;this.isAutoHeight=((r=this.beans.rowAutoHeight)==null?void 0:r.setupCellAutoHeight(this,e,t))??!1}getCellAriaRole(){return this.column.getColDef().cellAriaRole??"gridcell"}isCellRenderer(){const e=this.column.getColDef();return e.cellRenderer!=null||e.cellRendererSelector!=null}getValueToDisplay(){return this.valueFormatted??this.value}showValue(e,t){var d,h,f;const{beans:r,column:n,rowNode:i,rangeFeature:o}=this,{userCompFactory:s}=r,a=this.getValueToDisplay();let l;const c=i.stub&&((d=i.groupData)==null?void 0:d[n.getId()])==null,u=n.getColDef();if(c||this.isCellRenderer()){const g=this.createCellRendererParams();!c||Pi(n)?l=Dv(s,u,g):l=T_(s,u,g)}if(!l&&!c&&((h=r.findSvc)!=null&&h.isMatch(i,n))){const g=this.createCellRendererParams();l=Dv(s,{...n.getColDef(),cellRenderer:"agFindCellRenderer"},g)}this.comp.setRenderDetails(l,a,e),!t&&o&&Ur(r,()=>o==null?void 0:o.refreshHandle()),(f=this.rowResizeFeature)==null||f.refreshRowResizer()}setupControlComps(){const e=this.column.getColDef();this.includeSelection=this.isIncludeControl(this.isCheckboxSelection(e),!0),this.includeRowDrag=this.isIncludeControl(e.rowDrag),this.includeDndSource=this.isIncludeControl(e.dndSource),this.comp.setIncludeSelection(this.includeSelection),this.comp.setIncludeDndSource(this.includeDndSource),this.comp.setIncludeRowDrag(this.includeRowDrag)}isForceWrapper(){return this.beans.gos.get("enableCellTextSelection")||this.column.isAutoHeight()}isIncludeControl(e,t=!1){return(this.rowNode.rowPinned==null||t&&Ra(this.rowNode))&&!!e}isCheckboxSelection(e){const{rowSelection:t,groupDisplayType:r}=this.beans.gridOptions,n=Dl(t),i=xa(this.column);return r==="custom"&&n!=="selectionColumn"&&i?!1:e.checkboxSelection||i&&typeof t=="object"&&Ai(t)}refreshShouldDestroy(){const e=this.column.getColDef(),t=this.includeSelection!=this.isIncludeControl(this.isCheckboxSelection(e),!0),r=this.includeRowDrag!=this.isIncludeControl(e.rowDrag),n=this.includeDndSource!=this.isIncludeControl(e.dndSource),i=this.isAutoHeight!=this.column.isAutoHeight();return t||r||n||i}onPopupEditorClosed(){var e;this.editing&&((e=this.beans.editSvc)==null||e.stopRowOrCellEdit(this))}stopEditing(e=!1){var t;return((t=this.beans.editSvc)==null?void 0:t.stopEditing(this,e))??!1}createCellRendererParams(){const{value:e,valueFormatted:t,column:r,rowNode:n,comp:i,eGui:o,beans:{valueSvc:s,gos:a}}=this;return pe(a,{value:e,valueFormatted:t,getValue:()=>s.getValueForDisplay(r,n).value,setValue:c=>s.setValue(n,r,c),formatValue:this.formatValue.bind(this),data:n.data,node:n,pinned:r.getPinned(),colDef:r.getColDef(),column:r,refreshCell:this.refreshCell.bind(this),eGridCell:o,eParentOfValue:i.getParentOfValue(),registerRowDragger:(c,u,d,h)=>this.registerRowDragger(c,u,h),setTooltip:(c,u)=>{var d;a.assertModuleRegistered("Tooltip",3),this.tooltipFeature&&this.disableTooltipFeature(),this.enableTooltipFeature(c,u),(d=this.tooltipFeature)==null||d.refreshTooltip()}})}onCellChanged(e){e.column===this.column&&this.refreshCell({})}refreshOrDestroyCell(e){var t;this.refreshShouldDestroy()?(t=this.rowCtrl)==null||t.recreateCell(this):this.refreshCell(e)}refreshCell(e){var c,u,d,h,f,g;if(this.suppressRefreshCell||this.editing)return;const t=this.column.getColDef(),r=e!=null&&!!e.newData,n=e!=null&&!!e.suppressFlash,i=t.field==null&&t.valueGetter==null&&t.showRowGroup==null,o=e&&e.forceRefresh||i||r,s=!!this.comp,a=this.updateAndFormatValue(s),l=o||a;if(s){if(l){this.showValue(r,!1);const m=(c=this.beans.filterManager)==null?void 0:c.isSuppressFlashingCellsBecauseFiltering();!n&&!m&&t.enableCellChangeFlash&&((u=this.beans.cellFlashSvc)==null||u.flashCell(this)),(d=this.customStyleFeature)==null||d.applyUserStyles(),(h=this.customStyleFeature)==null||h.applyClassesFromColDef()}(f=this.tooltipFeature)==null||f.refreshTooltip(),(g=this.customStyleFeature)==null||g.applyCellClassRules()}}isCellEditable(){return this.column.isCellEditable(this.rowNode)}formatValue(e){return this.callValueFormatter(e)??e}callValueFormatter(e){return this.beans.valueSvc.formatValue(this.column,this.rowNode,e)}updateAndFormatValue(e){const t=this.value,r=this.valueFormatted,{value:n,valueFormatted:i}=this.beans.valueSvc.getValueForDisplay(this.column,this.rowNode,!0);return this.value=n,this.valueFormatted=i,e?!this.valuesAreEqual(t,this.value)||this.valueFormatted!=r:!0}valuesAreEqual(e,t){const r=this.column.getColDef();return r.equals?r.equals(e,t):e===t}addDomData(e){const t=this.eGui;Li(this.beans.gos,t,Hl,this),e.addDestroyFunc(()=>Li(this.beans.gos,t,Hl,null))}createEvent(e,t){const{rowNode:r,column:n,value:i,beans:o}=this;return pe(o.gos,{type:t,node:r,data:r.data,value:i,column:n,colDef:n.getColDef(),rowPinned:r.rowPinned,event:e,rowIndex:r.rowIndex})}processCharacter(e){var t;(t=this.keyboardListener)==null||t.processCharacter(e)}onKeyDown(e){var t;(t=this.keyboardListener)==null||t.onKeyDown(e)}onMouseEvent(e,t){var r;(r=this.mouseListener)==null||r.onMouseEvent(e,t)}getColSpanningList(){return this.positionFeature.getColSpanningList()}onLeftChanged(){var e;this.comp&&((e=this.positionFeature)==null||e.onLeftChanged())}onDisplayedColumnsChanged(){this.eGui&&(this.refreshAriaColIndex(),this.refreshFirstAndLastStyles())}refreshFirstAndLastStyles(){const{comp:e,column:t,beans:r}=this;D1(e,t,r.visibleCols)}refreshAriaColIndex(){const e=this.beans.visibleCols.getAriaColIndex(this.column);z2(this.eGui,e)}onWidthChanged(){var e;return(e=this.positionFeature)==null?void 0:e.onWidthChanged()}getRowPosition(){const{rowIndex:e,rowPinned:t}=this.cellPosition;return{rowIndex:e,rowPinned:t}}updateRangeBordersIfRangeCount(){var e;this.comp&&((e=this.rangeFeature)==null||e.updateRangeBordersIfRangeCount())}onCellSelectionChanged(){var e;this.comp&&((e=this.rangeFeature)==null||e.onCellSelectionChanged())}isRangeSelectionEnabled(){return this.rangeFeature!=null}focusCell(e=!1){this.beans.focusSvc.setFocusedCell({...this.getFocusedCellPosition(),forceBrowserFocus:e})}restoreFocus(e=!1){if(!this.comp||this.editing||!this.isCellFocused()||!this.beans.focusSvc.shouldTakeFocus())return;const t=()=>{if(!this.isAlive())return;const r=this.comp.getFocusableElement();this.isCellFocused()&&r.focus({preventScroll:!0})};if(e){setTimeout(t,0);return}t()}onRowIndexChanged(){var e,t;this.createCellPosition(),this.onCellFocused(),this.restoreFocus(),(e=this.rangeFeature)==null||e.onCellSelectionChanged(),(t=this.rowResizeFeature)==null||t.refreshRowResizer()}onSuppressCellFocusChanged(e){const t=this.eGui;t&&(Pi(this.column)&&(e=!0),Si(t,"tabindex",e?void 0:-1))}onFirstRightPinnedChanged(){if(!this.comp)return;const e=this.column.isFirstRightPinned();this.comp.toggleCss(uL,e)}onLastLeftPinnedChanged(){if(!this.comp)return;const e=this.column.isLastLeftPinned();this.comp.toggleCss(dL,e)}checkCellFocused(){return this.beans.focusSvc.isCellFocused(this.cellPosition)}isCellFocused(){const e=this.checkCellFocused();return this.hasBeenFocused||(this.hasBeenFocused=e),e}setupFocus(){this.restoreFocus(!0),this.onCellFocused(this.focusEventWhileNotReady??void 0)}onCellFocused(e){var i;const{beans:t}=this;if(dp(t))return;if(!this.comp){e&&(this.focusEventWhileNotReady=e);return}const r=this.isCellFocused();if(this.comp.toggleCss(cL,r),r&&e&&e.forceBrowserFocus){let o=this.comp.getFocusableElement();if(this.editing){const s=Ei(o,null,!0);s.length&&(o=s[0])}o.focus({preventScroll:!!e.preventScrollOnBrowserFocus})}const n=t.gos.get("editType")==="fullRow";!r&&!n&&this.editing&&((i=t.editSvc)==null||i.stopRowOrCellEdit(this)),r&&this.rowCtrl.announceDescription()}createCellPosition(){const{rowIndex:e,rowPinned:t}=this.rowNode;this.cellPosition={rowIndex:e,rowPinned:on(t),column:this.column}}setInlineEditingCss(){var e;(e=this.beans.editSvc)==null||e.setInlineEditingCss(this.rowCtrl)}applyStaticCssClasses(){const{comp:e}=this;e.toggleCss(sL,!0),e.toggleCss(hL,!0);const t=this.column.isAutoHeight()==!0;e.toggleCss(aL,t),e.toggleCss(lL,!t)}onColumnHover(){var e;(e=this.beans.colHover)==null||e.onCellColumnHover(this.column,this.comp)}onColDefChanged(){var e;this.comp&&(this.column.isTooltipEnabled()?(this.disableTooltipFeature(),this.enableTooltipFeature()):this.disableTooltipFeature(),this.setWrapText(),this.editing?(e=this.beans.editSvc)==null||e.handleColDefChanged(this):this.refreshOrDestroyCell({forceRefresh:!0,suppressFlash:!0}))}setWrapText(){const e=this.column.getColDef().wrapText==!0;this.comp.toggleCss(fL,e)}dispatchCellContextMenuEvent(e){const t=this.column.getColDef(),r=this.createEvent(e,"cellContextMenu"),{beans:n}=this;n.eventSvc.dispatchEvent(r),t.onCellContextMenu&&window.setTimeout(()=>{n.frameworkOverrides.wrapOutgoing(()=>{t.onCellContextMenu(r)})},0)}getCellRenderer(){var e;return((e=this.comp)==null?void 0:e.getCellRenderer())??null}destroy(){this.onCompAttachedFuncs=[],this.onEditorAttachedFuncs=[],this.isCellFocused()&&this.hasBrowserFocus()&&this.beans.focusSvc.attemptToRecoverFocus(),super.destroy()}hasBrowserFocus(){var e;return((e=this.eGui)==null?void 0:e.contains(Ke(this.beans)))??!1}createSelectionCheckbox(){var t;const e=(t=this.beans.selectionSvc)==null?void 0:t.createCheckboxSelectionComponent();if(e)return this.beans.context.createBean(e),e.init({rowNode:this.rowNode,column:this.column}),e}createDndSource(){const e=this.beans.registry.createDynamicBean("dndSourceComp",!1,this.rowNode,this.column,this.eGui);return e&&this.beans.context.createBean(e),e}registerRowDragger(e,t,r){if(this.customRowDragComp){this.customRowDragComp.setDragElement(e,t);return}const n=this.createRowDragComp(e,t,r);n&&(this.customRowDragComp=n,this.addDestroyFunc(()=>{this.beans.context.destroyBean(n),this.customRowDragComp=null}))}createRowDragComp(e,t,r){var i;const n=(i=this.beans.rowDragSvc)==null?void 0:i.createRowDragCompForCell(this.rowNode,this.column,()=>this.value,e,t,r);if(n)return this.beans.context.createBean(n),n}cellEditorAttached(){this.onEditorAttachedFuncs.forEach(e=>e()),this.onEditorAttachedFuncs=[]}setFocusedCellPosition(e){}getFocusedCellPosition(){return this.cellPosition}refreshAriaRowIndex(){}getRootElement(){return this.eGui}},_1="__ag_grid_instance";function L1(e,t){t[_1]=e.gridInstanceId}function Ms(e,t){return pL(e,t.target)}function pL(e,t){let r=t;for(;r;){const n=r[_1];if(ie(n))return n===e.gridInstanceId;r=r.parentElement}return!1}function mL(e,t){var r;return((r=I1(e,t.target))==null?void 0:r.getFocusedCellPosition())??null}var vL=class extends q{constructor(){super(...arguments),this.beanName="dragAndDrop",this.dragSourceAndParamsList=[],this.dropTargets=[]}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.dragSvc=e.dragSvc,this.environment=e.environment,this.userCompFactory=e.userCompFactory}addDragSource(e,t=!1){const r={eElement:e.eElement,dragStartPixels:e.dragStartPixels,onDragStart:this.onDragStart.bind(this,e),onDragStop:this.onDragStop.bind(this),onDragging:this.onDragging.bind(this),onDragCancel:this.onDragCancel.bind(this),includeTouch:t};this.dragSourceAndParamsList.push({params:r,dragSource:e}),this.dragSvc.addDragSource(r)}getDragAndDropImageComponent(){const{dragAndDropImageComp:e}=this;return!e||!e.comp?null:e.comp}removeDragSource(e){const{dragSourceAndParamsList:t,dragSvc:r}=this,n=t.find(i=>i.dragSource===e);n&&(r.removeDragSource(n.params),Zt(t,n))}destroy(){const{dragSourceAndParamsList:e,dragSvc:t,dropTargets:r}=this;e.forEach(n=>t.removeDragSource(n.params)),e.length=0,r.length=0,this.clearDragAndDropProperties(),super.destroy()}nudge(){this.dragging&&this.onDragging(this.eventLastTime,!0)}onDragStart(e,t){var r;this.dragging=!0,this.dragSource=e,this.eventLastTime=t,this.dragItem=e.getDragItem(),(r=e.onDragStarted)==null||r.call(e),this.createDragAndDropImageComponent()}onDragStop(e){var r,n;(n=(r=this.dragSource)==null?void 0:r.onDragStopped)==null||n.call(r);const{lastDropTarget:t}=this;if(t!=null&&t.onDragStop){const i=this.createDropTargetEvent(t,e,null,null,!1);t.onDragStop(i)}this.clearDragAndDropProperties()}onDragCancel(){var r;const{dragSource:e,lastDropTarget:t}=this;(r=e==null?void 0:e.onDragCancelled)==null||r.call(e),t!=null&&t.onDragCancel&&t.onDragCancel(this.createDropTargetEvent(t,this.eventLastTime,null,null,!1)),this.clearDragAndDropProperties()}clearDragAndDropProperties(){this.eventLastTime=null,this.dragging=!1,this.lastDropTarget=void 0,this.dragItem=null,this.dragSource=null,this.removeDragAndDropImageComponent()}onDragging(e,t=!1){var u,d;const r=this.getHorizontalDirection(e),n=this.getVerticalDirection(e);this.eventLastTime=e,this.positionDragAndDropImageComp(e);const i=this.dropTargets.filter(h=>this.isMouseOnDropTarget(e,h)),o=this.findCurrentDropTarget(e,i),{lastDropTarget:s,dragSource:a,dragAndDropImageComp:l,dragItem:c}=this;if(o!==s){if(this.leaveLastTargetIfExists(e,r,n,t),s!==null&&o===null&&((u=a==null?void 0:a.onGridExit)==null||u.call(a,c)),s===null&&o!==null&&((d=a==null?void 0:a.onGridEnter)==null||d.call(a,c)),this.enterDragTargetIfExists(o,e,r,n,t),o&&l){const{comp:h,promise:f}=l;h?h.setIcon(o.getIconName?o.getIconName():null,!1):f.then(g=>{g&&g.setIcon(o.getIconName?o.getIconName():null,!1)})}this.lastDropTarget=o}else if(o&&o.onDragging){const h=this.createDropTargetEvent(o,e,r,n,t);o.onDragging(h)}}getAllContainersFromDropTarget(e){const t=e.getSecondaryContainers?e.getSecondaryContainers():null,r=[[e.getContainer()]];return t?r.concat(t):r}isMouseOnDropTarget(e,t){const r=this.getAllContainersFromDropTarget(t);let n=!1;const i=(a,l)=>{for(const c of l){const{width:u,height:d,left:h,right:f,top:g,bottom:m}=c.getBoundingClientRect();if(u===0||d===0)return!1;const p=a.clientX>=h&&a.clientX<f,y=a.clientY>=g&&a.clientY<m;if(!p||!y)return!1}return!0};for(const a of r)if(i(e,a)){n=!0;break}const{eElement:o,type:s}=this.dragSource;return t.targetContainsSource&&!t.getContainer().contains(o)?!1:n&&t.isInterestedIn(s,o)}findCurrentDropTarget(e,t){const r=t.length;if(r===0)return null;if(r===1)return t[0];const i=Ps(this.beans).elementsFromPoint(e.clientX,e.clientY);for(const o of i)for(const s of t)if(this.getAllContainersFromDropTarget(s).flatMap(l=>l).indexOf(o)!==-1)return s;return null}enterDragTargetIfExists(e,t,r,n,i){if(e&&e.onDragEnter){const o=this.createDropTargetEvent(e,t,r,n,i);e.onDragEnter(o)}}leaveLastTargetIfExists(e,t,r,n){const{lastDropTarget:i}=this;if(!i)return;if(i.onDragLeave){const s=this.createDropTargetEvent(i,e,t,r,n);i.onDragLeave(s)}const o=this.getDragAndDropImageComponent();o&&o.setIcon(null,!1)}addDropTarget(e){this.dropTargets.push(e)}removeDropTarget(e){this.dropTargets=this.dropTargets.filter(t=>t.getContainer()!==e.getContainer())}hasExternalDropZones(){return this.dropTargets.some(e=>e.external)}findExternalZone(e){return this.dropTargets.filter(r=>r.external).find(r=>r.getContainer()===e.getContainer())||null}isDropZoneWithinThisGrid(e){const r=this.ctrlsSvc.getGridBodyCtrl().eGridBody,{dropZoneTarget:n}=e;return r.contains(n)}getHorizontalDirection(e){var n;const t=(n=this.eventLastTime)==null?void 0:n.clientX,r=e.clientX;return t===r?null:t>r?"left":"right"}getVerticalDirection(e){var n;const t=(n=this.eventLastTime)==null?void 0:n.clientY,r=e.clientY;return t===r?null:t>r?"up":"down"}createDropTargetEvent(e,t,r,n,i){const o=e.getContainer(),s=o.getBoundingClientRect(),{dragItem:a,dragSource:l,gos:c}=this,u=t.clientX-s.left,d=t.clientY-s.top;return pe(c,{event:t,x:u,y:d,vDirection:n,hDirection:r,dragSource:l,fromNudge:i,dragItem:a,dropZoneTarget:o})}positionDragAndDropImageComp(e){const t=this.getDragAndDropImageComponent();t&&lI(t.getGui(),e,this.beans)}removeDragAndDropImageComponent(){var t;const{dragAndDropImageComp:e}=this;if(e){const{comp:r}=e;if(r){const n=r.getGui();(t=this.dragAndDropImageParent)==null||t.removeChild(n),this.destroyBean(r)}}this.dragAndDropImageComp=null}createDragAndDropImageComponent(){const{dragSource:e,gos:t,userCompFactory:r}=this;if(!e)return;const n=b_(r,pe(t,{dragSource:e}));if(!n)return;const i=n.newAgStackInstance();this.dragAndDropImageComp={promise:i},i.then(o=>{!o||!this.isAlive()||(this.processDragAndDropImageComponent(o),this.dragAndDropImageComp.comp=o)})}processDragAndDropImageComponent(e){const{dragSource:t,environment:r}=this;if(!t)return;const n=e.getGui();n.style.setProperty("position","absolute"),n.style.setProperty("z-index","9999"),L1(this.gos,n),r.applyThemeClasses(n),e.setIcon(null,!1);let{dragItemName:i}=t;typeof i=="function"&&(i=i()),e.setLabel(i||""),n.style.top="20px",n.style.left="20px";const o=lp(this.beans);this.dragAndDropImageParent=o,o?o.appendChild(n):Q(54)}registerGridDropTarget(e,t){const r={getContainer:e,isInterestedIn:n=>n===1||n===0,getIconName:()=>"notAllowed"};this.addDropTarget(r),t.addDestroyFunc(()=>this.removeDropTarget(r))}};function yL(e,t){const r=e.column===t.column,n=e.rowPinned===t.rowPinned,i=e.rowIndex===t.rowIndex;return r&&n&&i}function bL(e,t){switch(e.rowPinned){case"top":if(t.rowPinned!=="top")return!0;break;case"bottom":if(t.rowPinned!=="bottom")return!1;break;default:if(ie(t.rowPinned))return t.rowPinned!=="top";break}return e.rowIndex<t.rowIndex}function CL(e){let t=0,r;const{pinnedRowModel:n,rowModel:i,pageBounds:o}=e;return n!=null&&n.getPinnedTopRowCount()?r="top":i.getRowCount()?(r=null,t=o.getFirstRow()):n!=null&&n.getPinnedBottomRowCount()&&(r="bottom"),r===void 0?null:{rowIndex:t,rowPinned:r}}function wL(e){let t,r=null;const{pinnedRowModel:n,pageBounds:i}=e,o=n==null?void 0:n.getPinnedBottomRowCount(),s=n==null?void 0:n.getPinnedTopRowCount();return o?(r="bottom",t=o-1):e.rowModel.getRowCount()?(r=null,t=i.getLastRow()):s&&(r="top",t=s-1),t===void 0?null:{rowIndex:t,rowPinned:r}}function B1(e,t){var r,n;switch(t.rowPinned){case"top":return(r=e.pinnedRowModel)==null?void 0:r.getPinnedTopRow(t.rowIndex);case"bottom":return(n=e.pinnedRowModel)==null?void 0:n.getPinnedBottomRow(t.rowIndex);default:return e.rowModel.getRow(t.rowIndex)}}function Na(e,t){var i;const r=(i=e.spannedRowRenderer)==null?void 0:i.getCellByPosition(t);if(r)return r;const n=e.rowRenderer.getRowByPosition(t);return n?n.getCellCtrl(t.column):null}function Gl(e,t){const{rowIndex:r,rowPinned:n}=t,{pageBounds:i,pinnedRowModel:o,rowModel:s}=e;if(r===0)return n==="top"?null:n==="bottom"&&s.isRowsToRender()?{rowIndex:i.getLastRow(),rowPinned:null}:o!=null&&o.isRowsToRender("top")?{rowIndex:o.getPinnedTopRowCount()-1,rowPinned:"top"}:null;const a=n?void 0:s.getRow(r);return z1(e,a,!0)??{rowIndex:r-1,rowPinned:n}}function Iv(e,t){const{rowIndex:r,rowPinned:n}=t,{pageBounds:i,pinnedRowModel:o,rowModel:s}=e;if(SL(e,t))return n==="bottom"?null:n==="top"&&s.isRowsToRender()?{rowIndex:i.getFirstRow(),rowPinned:null}:o!=null&&o.isRowsToRender("bottom")?{rowIndex:0,rowPinned:"bottom"}:null;const a=n?void 0:s.getRow(r);return z1(e,a)??{rowIndex:r+1,rowPinned:n}}function z1(e,t,r){const{gos:n,rowRenderer:i}=e;if(!(t!=null&&t.sticky)||!s1(n))return;const o=r?i.getStickyTopRowCtrls():i.getStickyBottomRowCtrls();let s;for(let a=0;a<o.length;a++)if(o[a].rowNode.rowIndex===t.rowIndex){s=o[a+(r?-1:1)];break}return s?{rowIndex:s.rowNode.rowIndex,rowPinned:null}:void 0}function SL(e,t){const{rowPinned:r,rowIndex:n}=t,{pinnedRowModel:i,pageBounds:o}=e;return r==="top"?((i==null?void 0:i.getPinnedTopRowCount())??0)-1<=n:r==="bottom"?((i==null?void 0:i.getPinnedBottomRowCount())??0)-1<=n:o.getLastRow()<=n}var Wl=class{constructor(e,t){this.active=!0,this.nodeIdsToColumns={},this.mapToItems={},this.keepingColumns=e,this.pathRoot={rowNode:t,children:null},this.mapToItems[t.id]=this.pathRoot}depthFirstSearchChangedPath(e,t){const{rowNode:r,children:n}=e;if(n)for(let i=0;i<n.length;++i)this.depthFirstSearchChangedPath(n[i],t);t(r)}depthFirstSearchEverything(e,t,r){const n=e.childrenAfterGroup;if(n)for(let i=0,o=n.length;i<o;++i){const s=n[i];s.childrenAfterGroup?this.depthFirstSearchEverything(s,t,r):r&&t(s)}t(e)}forEachChangedNodeDepthFirst(e,t=!1,r=!1){this.active&&!r?this.depthFirstSearchChangedPath(this.pathRoot,e):this.depthFirstSearchEverything(this.pathRoot.rowNode,e,t)}executeFromRootNode(e){e(this.pathRoot.rowNode)}createPathItems(e){let t=e,r=0;for(;!this.mapToItems[t.id];){const n={rowNode:t,children:null};this.mapToItems[t.id]=n,r++,t=t.parent}return r}populateColumnsMap(e,t){if(!this.keepingColumns||!t)return;let r=e;for(;r;)this.nodeIdsToColumns[r.id]||(this.nodeIdsToColumns[r.id]={}),t.forEach(n=>this.nodeIdsToColumns[r.id][n.getId()]=!0),r=r.parent}linkPathItems(e,t){let r=e;for(let n=0;n<t;n++){const i=this.mapToItems[r.id],o=this.mapToItems[r.parent.id];o.children||(o.children=[]),o.children.push(i),r=r.parent}}addParentNode(e,t){if(!e||e.isRowPinned())return;const r=this.createPathItems(e);this.linkPathItems(e,r),this.populateColumnsMap(e,t)}canSkip(e){return this.active&&!this.mapToItems[e.id]}getValueColumnsForNode(e,t){if(!this.keepingColumns)return t;const r=this.nodeIdsToColumns[e.id];return t.filter(i=>r[i.getId()])}getNotValueColumnsForNode(e,t){if(!this.keepingColumns)return null;const r=this.nodeIdsToColumns[e.id];return t.filter(i=>!r[i.getId()])}};function N1(e,t,r){if(r===0)return!1;const n=Math.abs(e.clientX-t.clientX),i=Math.abs(e.clientY-t.clientY);return Math.max(n,i)<=r}var xL=class extends q{constructor(){super(...arguments),this.beanName="dragSvc",this.dragEndFunctions=[],this.dragSources=[]}destroy(){const{dragSources:e}=this;e.forEach(this.removeListener.bind(this)),e.length=0,super.destroy()}removeListener(e){const t=e.dragSource.eElement,r=e.mouseDownListener;if(t.removeEventListener("mousedown",r),e.touchEnabled){const n=e.touchStartListener;t.removeEventListener("touchstart",n,{passive:!0})}}removeDragSource(e){const{dragSources:t}=this,r=t.find(n=>n.dragSource===e);r&&(this.removeListener(r),Zt(t,r))}addDragSource(e){const t=this.onMouseDown.bind(this,e),{eElement:r,includeTouch:n,stopPropagationForTouch:i}=e;r.addEventListener("mousedown",t);let o=null;const s=this.gos.get("suppressTouch");n&&!s&&(o=a=>{tp(a.target)||(i&&a.stopPropagation(),this.onTouchStart(e,a))},r.addEventListener("touchstart",o,{passive:!1})),this.dragSources.push({dragSource:e,mouseDownListener:t,touchStartListener:o,touchEnabled:!!n})}onTouchStart(e,t){this.currentDragParams=e,this.dragging=!1;const r=t.touches[0];this.touchLastTime=r,this.touchStart=r;const n=l=>this.onTouchMove(l,e.eElement),i=l=>this.onTouchUp(l,e.eElement),o=l=>{l.cancelable&&l.preventDefault()},s=t.target,a=[{target:Ps(this.beans),type:"touchmove",listener:o,options:{passive:!1}},{target:s,type:"touchmove",listener:n,options:{passive:!0}},{target:s,type:"touchend",listener:i,options:{passive:!0}},{target:s,type:"touchcancel",listener:i,options:{passive:!0}}];this.addTemporaryEvents(a),e.dragStartPixels===0&&this.onCommonMove(r,this.touchStart,e.eElement)}onMouseDown(e,t){const r=t;if(e.skipMouseEvent&&e.skipMouseEvent(t)||r._alreadyProcessedByDragService||(r._alreadyProcessedByDragService=!0,t.button!==0))return;this.shouldPreventMouseEvent(t)&&t.preventDefault(),this.currentDragParams=e,this.dragging=!1,this.mouseStartEvent=t,this.startTarget=t.target;const n=c=>this.onMouseMove(c,e.eElement),i=c=>this.onMouseUp(c,e.eElement),o=c=>c.preventDefault(),s=c=>{c.key===j.ESCAPE&&this.cancelDrag(e.eElement)},a=Ps(this.beans),l=[{target:a,type:"mousemove",listener:n},{target:a,type:"mouseup",listener:i},{target:a,type:"contextmenu",listener:o},{target:a,type:"keydown",listener:s}];this.addTemporaryEvents(l),e.dragStartPixels===0&&this.onMouseMove(t,e.eElement)}addTemporaryEvents(e){e.forEach(t=>{const{target:r,type:n,listener:i,options:o}=t;r.addEventListener(n,i,o)}),this.dragEndFunctions.push(()=>{e.forEach(t=>{const{target:r,type:n,listener:i,options:o}=t;r.removeEventListener(n,i,o)})})}isEventNearStartEvent(e,t){const{dragStartPixels:r}=this.currentDragParams,n=ie(r)?r:4;return N1(e,t,n)}getFirstActiveTouch(e){for(let t=0;t<e.length;t++)if(e[t].identifier===this.touchStart.identifier)return e[t];return null}onCommonMove(e,t,r){var n;if(!this.dragging){if(this.isEventNearStartEvent(e,t))return;if(this.dragging=!0,this.eventSvc.dispatchEvent({type:"dragStarted",target:r}),this.currentDragParams.onDragStart(t),!this.currentDragParams){this.dragging=!1;return}this.currentDragParams.onDragging(t)}(n=this.currentDragParams)==null||n.onDragging(e)}onTouchMove(e,t){const r=this.getFirstActiveTouch(e.touches);r&&this.onCommonMove(r,this.touchStart,t)}onMouseMove(e,t){var r;ep()&&((r=gt(this.beans).getSelection())==null||r.removeAllRanges()),this.shouldPreventMouseEvent(e)&&e.preventDefault(),this.onCommonMove(e,this.mouseStartEvent,t)}shouldPreventMouseEvent(e){const{gos:t}=this,r=t.get("enableCellTextSelection"),n=e.type==="mousemove",i=o=>{const s=o.target,a=s==null?void 0:s.tagName.toLocaleLowerCase();return!!(a!=null&&a.match("^a$|textarea|input|select|button"))};return r&&n&&e.cancelable&&Ms(t,e)&&!i(e)}onTouchUp(e,t){let r=this.getFirstActiveTouch(e.changedTouches);r||(r=this.touchLastTime),this.onUpCommon(r,t)}onMouseUp(e,t){this.onUpCommon(e,t)}onUpCommon(e,t){this.dragging&&(this.dragging=!1,this.currentDragParams.onDragStop(e),this.eventSvc.dispatchEvent({type:"dragStopped",target:t})),this.resetDragProperties()}cancelDrag(e){var t,r;this.eventSvc.dispatchEvent({type:"dragCancelled",target:e}),(r=(t=this.currentDragParams)==null?void 0:t.onDragCancel)==null||r.call(t),this.resetDragProperties()}resetDragProperties(){this.mouseStartEvent=null,this.startTarget=null,this.touchStart=null,this.touchLastTime=null,this.currentDragParams=null;const{dragEndFunctions:e}=this;e.forEach(t=>t()),e.length=0}};function $1(e,t){return e+"_"+t}function je(e){return e instanceof H1}var H1=class extends q{constructor(e,t,r,n){super(),this.providedColumnGroup=e,this.groupId=t,this.partId=r,this.pinned=n,this.isColumn=!1,this.displayedChildren=[],this.autoHeaderHeight=null,this.parent=null}reset(){this.parent=null,this.children=null,this.displayedChildren=null}getParent(){return this.parent}getUniqueId(){return $1(this.groupId,this.partId)}isEmptyGroup(){return this.displayedChildren.length===0}isMoving(){const e=this.getProvidedColumnGroup().getLeafColumns();return!e||e.length===0?!1:e.every(t=>t.isMoving())}checkLeft(){if(this.displayedChildren.forEach(e=>{je(e)&&e.checkLeft()}),this.displayedChildren.length>0)if(this.gos.get("enableRtl")){const t=Ee(this.displayedChildren).getLeft();this.setLeft(t)}else{const e=this.displayedChildren[0].getLeft();this.setLeft(e)}else this.setLeft(null)}getLeft(){return this.left}getOldLeft(){return this.oldLeft}setLeft(e){this.oldLeft=this.left,this.left!==e&&(this.left=e,this.dispatchLocalEvent({type:"leftChanged"}))}getPinned(){return this.pinned}getGroupId(){return this.groupId}getPartId(){return this.partId}getActualWidth(){var t;let e=0;return(t=this.displayedChildren)==null||t.forEach(r=>{e+=r.getActualWidth()}),e}isResizable(){if(!this.displayedChildren)return!1;let e=!1;return this.displayedChildren.forEach(t=>{t.isResizable()&&(e=!0)}),e}getMinWidth(){let e=0;return this.displayedChildren.forEach(t=>{e+=t.getMinWidth()}),e}addChild(e){this.children||(this.children=[]),this.children.push(e)}getDisplayedChildren(){return this.displayedChildren}getLeafColumns(){const e=[];return this.addLeafColumns(e),e}getDisplayedLeafColumns(){const e=[];return this.addDisplayedLeafColumns(e),e}getDefinition(){return this.providedColumnGroup.getColGroupDef()}getColGroupDef(){return this.providedColumnGroup.getColGroupDef()}isPadding(){return this.providedColumnGroup.isPadding()}isExpandable(){return this.providedColumnGroup.isExpandable()}isExpanded(){return this.providedColumnGroup.isExpanded()}setExpanded(e){this.providedColumnGroup.setExpanded(e)}isAutoHeaderHeight(){var e;return!!((e=this.getColGroupDef())!=null&&e.autoHeaderHeight)}getAutoHeaderHeight(){return this.autoHeaderHeight}setAutoHeaderHeight(e){const t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}addDisplayedLeafColumns(e){this.displayedChildren.forEach(t=>{$r(t)?e.push(t):je(t)&&t.addDisplayedLeafColumns(e)})}addLeafColumns(e){this.children.forEach(t=>{$r(t)?e.push(t):je(t)&&t.addLeafColumns(e)})}getChildren(){return this.children}getColumnGroupShow(){return this.providedColumnGroup.getColumnGroupShow()}getProvidedColumnGroup(){return this.providedColumnGroup}getPaddingLevel(){const e=this.getParent();return!this.isPadding()||!e||!e.isPadding()?0:1+e.getPaddingLevel()}calculateDisplayedColumns(){this.displayedChildren=[];let e=this;for(;e!=null&&e.isPadding();)e=e.getParent();if(!(e?e.getProvidedColumnGroup().isExpandable():!1)){this.displayedChildren=this.children,this.dispatchLocalEvent({type:"displayedChildrenChanged"});return}this.children.forEach(r=>{if(je(r)&&(!r.displayedChildren||!r.displayedChildren.length))return;switch(r.getColumnGroupShow()){case"open":e.getProvidedColumnGroup().isExpanded()&&this.displayedChildren.push(r);break;case"closed":e.getProvidedColumnGroup().isExpanded()||this.displayedChildren.push(r);break;default:this.displayedChildren.push(r);break}}),this.dispatchLocalEvent({type:"displayedChildrenChanged"})}},zh="row-group-",hp="t-",fp="b-",AL=0,Yn=class{constructor(e){this.master=!1,this.detail=void 0,this.rowIndex=null,this.key=null,this.sourceRowIndex=-1,this.childrenMapped={},this.treeNode=null,this.treeNodeFlags=0,this.displayed=!1,this.rowTop=null,this.oldRowTop=null,this.selectable=!0,this.__objectId=AL++,this.alreadyRendered=!1,this.highlighted=null,this.hovered=!1,this.__selected=!1,this.beans=e}setData(e){this.setDataCommon(e,!1)}updateData(e){this.setDataCommon(e,!0)}setDataCommon(e,t){var l,c,u;const{valueCache:r,selectionSvc:n,eventSvc:i}=this.beans,o=this.data;this.data=e,r==null||r.onDataChanged(),this.updateDataOnDetailNode(),n==null||n.updateRowSelectable(this),this.resetQuickFilterAggregateText();const s=this.createDataChangedEvent(e,o,t);if((l=this.__localEventService)==null||l.dispatchEvent(s),this.sibling){this.sibling.data=e;const d=this.sibling.createDataChangedEvent(e,o,t);(c=this.sibling.__localEventService)==null||c.dispatchEvent(d)}i.dispatchEvent({type:"rowNodeDataChanged",node:this});const a=this.pinnedSibling;a&&(a.data=e,(u=a.__localEventService)==null||u.dispatchEvent(a.createDataChangedEvent(e,o,t)),i.dispatchEvent({type:"rowNodeDataChanged",node:a}))}updateDataOnDetailNode(){this.detailNode&&(this.detailNode.data=this.data)}createDataChangedEvent(e,t,r){return{type:"dataChanged",node:this,oldData:t,newData:e,update:r}}getRowIndexString(){return this.rowIndex==null?(_e(13),null):this.rowPinned==="top"?hp+this.rowIndex:this.rowPinned==="bottom"?fp+this.rowIndex:this.rowIndex.toString()}setDataAndId(e,t){var s,a;const{selectionSvc:r}=this.beans,n=(s=r==null?void 0:r.createDaemonNode)==null?void 0:s.call(r,this),i=this.data;this.data=e,this.updateDataOnDetailNode(),this.setId(t),r&&(r.updateRowSelectable(this),r.syncInRowNode(this,n));const o=this.createDataChangedEvent(e,i,!1);(a=this.__localEventService)==null||a.dispatchEvent(o)}setId(e){var r;const t=Rs(this.beans.gos);if(t)if(this.data){const n=((r=this.parent)==null?void 0:r.getRoute())??[];this.id=t({data:this.data,parentKeys:n.length>0?n:void 0,level:this.level,rowPinned:this.rowPinned}),this.id.startsWith(zh)&&_e(14,{groupPrefix:zh})}else this.id=void 0;else this.id=e}setRowTop(e){this.oldRowTop=this.rowTop,this.rowTop!==e&&(this.rowTop=e,this.dispatchRowEvent("topChanged"),this.setDisplayed(e!==null))}clearRowTopAndRowIndex(){this.oldRowTop=null,this.setRowTop(null),this.setRowIndex(null)}setHovered(e){this.hovered=e}isHovered(){return this.hovered}setRowHeight(e,t=!1){this.rowHeight=e,this.rowHeightEstimated=t,this.dispatchRowEvent("heightChanged")}setExpanded(e,t,r){var n;(n=this.beans.expansionSvc)==null||n.setExpanded(this,e,t,r)}setDataValue(e,t,r){const{colModel:n,valueSvc:i,gos:o,selectionSvc:s}=this.beans,a=typeof e!="string"?e:n.getCol(e)??n.getColDefCol(e);if(!a)return!1;const l=i.getValueForDisplay(a,this).value;if(o.get("readOnlyEdit")){const{beans:{eventSvc:h},data:f,rowIndex:g,rowPinned:m}=this;return h.dispatchEvent({type:"cellEditRequest",event:null,rowIndex:g,rowPinned:m,column:a,colDef:a.colDef,data:f,node:this,oldValue:l,newValue:t,value:t,source:r}),!1}const c=i.setValue(this,a,t,r);this.dispatchCellChangedEvent(a,t,l);const u=s==null?void 0:s.updateRowSelectable(this),d=this.pinnedSibling;return d&&(c&&d.dispatchCellChangedEvent(a,t,l),d.selectable=u??!0),c}updateHasChildren(){let e=this.group&&!this.footer||this.childrenAfterGroup&&this.childrenAfterGroup.length>0;const{rowChildrenSvc:t}=this.beans;t&&(e=t.getHasChildrenValue(this)),e!==this.__hasChildren&&(this.__hasChildren=!!e,this.dispatchRowEvent("hasChildrenChanged"))}hasChildren(){return this.__hasChildren==null&&this.updateHasChildren(),this.__hasChildren}dispatchCellChangedEvent(e,t,r){var i;const n={type:"cellChanged",node:this,column:e,newValue:t,oldValue:r};(i=this.__localEventService)==null||i.dispatchEvent(n)}resetQuickFilterAggregateText(){this.quickFilterAggregateText=null}isExpandable(){var e;return((e=this.beans.expansionSvc)==null?void 0:e.isExpandable(this))??!1}isSelected(){return this.footer?this.sibling.isSelected():this.rowPinned&&this.pinnedSibling?this.pinnedSibling.isSelected():this.__selected}depthFirstSearch(e){var t;(t=this.childrenAfterGroup)==null||t.forEach(r=>r.depthFirstSearch(e)),e(this)}dispatchRowEvent(e){var t;(t=this.__localEventService)==null||t.dispatchEvent({type:e,node:this})}setSelected(e,t=!1,r="api"){var n;(n=this.beans.selectionSvc)==null||n.setNodesSelected({nodes:[this],newValue:e,clearSelection:t,source:r})}isRowPinned(){return!!this.rowPinned}__addEventListener(e,t){this.__localEventService||(this.__localEventService=new Wn),this.__localEventService.addEventListener(e,t)}__removeEventListener(e,t){this.removeLocalListener(e,t)}addEventListener(e,t){var n,i,o,s;(n=this.beans.validation)==null||n.checkRowEvents(e),this.__localEventService||(this.__localEventService=new Wn),this.frameworkEventListenerService=(o=(i=this.beans.frameworkOverrides).createLocalEventListenerWrapper)==null?void 0:o.call(i,this.frameworkEventListenerService,this.__localEventService);const r=((s=this.frameworkEventListenerService)==null?void 0:s.wrap(e,t))??t;this.__localEventService.addEventListener(e,r)}removeEventListener(e,t){var n;const r=((n=this.frameworkEventListenerService)==null?void 0:n.unwrap(e,t))??t;this.removeLocalListener(e,r)}removeLocalListener(e,t){var r,n;(r=this.__localEventService)==null||r.removeEventListener(e,t),(n=this.__localEventService)!=null&&n.noRegisteredListenersExist()&&(this.__localEventService=null)}isFullWidthCell(){if(Q(61),this.detail)return!0;const e=this.beans.gos.getCallback("isFullWidthRow");return e?e({rowNode:this}):!1}getRoute(){if(this.level===-1)return[];if(this.key==null)return;const e=[];let t=this;for(;t&&t.key!=null;)e.push(t.key),t=t.parent;return e.reverse()}setFirstChild(e){this.firstChild!==e&&(this.firstChild=e,this.dispatchRowEvent("firstChildChanged"))}setDisplayed(e){this.displayed!==e&&(this.displayed=e,this.dispatchRowEvent("displayedChanged"))}setRowIndex(e){this.rowIndex!==e&&(this.rowIndex=e,this.dispatchRowEvent("rowIndexChanged"))}setAllChildrenCount(e){this.allChildrenCount!==e&&(this.allChildrenCount=e,this.dispatchRowEvent("allChildrenCountChanged"))}setUiLevel(e){this.uiLevel!==e&&(this.uiLevel=e,this.dispatchRowEvent("uiLevelChanged"))}getFirstChild(){var e;return this.childStore?this.childStore.getFirstNode():((e=this.childrenAfterSort)==null?void 0:e[0])??null}};function PL(e,t,r){return pe(t,{type:r,node:e,data:e.data,rowIndex:e.rowIndex,rowPinned:e.rowPinned})}var RL=new Set(["__localEventService","__objectId","sticky","__autoHeights","__checkAutoHeightsDebounced","childStore"]);function EL(e,t){const r=new Yn(t);return Object.keys(e).forEach(n=>{RL.has(n)||(r[n]=e[n])}),r.oldRowTop=null,r}var TL={tag:"div",cls:"ag-filter"},FL=class extends ct{constructor(e,t){super(TL),this.column=e,this.source=t,this.filterWrapper=null}postConstruct(){this.createFilter(!0),this.addManagedEventListeners({filterDestroyed:this.onFilterDestroyed.bind(this)})}hasFilter(){return!!this.filterWrapper}getFilter(){var e;return((e=this.filterWrapper)==null?void 0:e.filterPromise)??null}afterInit(){var e,t;return((t=(e=this.filterWrapper)==null?void 0:e.filterPromise)==null?void 0:t.then(()=>{}))??Ie.resolve()}afterGuiAttached(e){var t,r;(r=(t=this.filterWrapper)==null?void 0:t.filterPromise)==null||r.then(n=>{var i;(i=n==null?void 0:n.afterGuiAttached)==null||i.call(n,e)})}afterGuiDetached(){var e,t;(t=(e=this.filterWrapper)==null?void 0:e.filterPromise)==null||t.then(r=>{var n;(n=r==null?void 0:r.afterGuiDetached)==null||n.call(r)})}createFilter(e){var n,i;const{column:t,source:r}=this;this.filterWrapper=((n=this.beans.filterManager)==null?void 0:n.getOrCreateFilterWrapper(t))??null,(i=this.filterWrapper)!=null&&i.filterPromise&&this.filterWrapper.filterPromise.then(o=>{const s=o.getGui();ie(s)||Q(69,{guiFromFilter:s}),this.appendChild(s),e&&this.eventSvc.dispatchEvent({type:"filterOpened",column:t,source:r,eGui:this.getGui()})})}onFilterDestroyed(e){(e.source==="api"||e.source==="paramsUpdated")&&e.column.getId()===this.column.getId()&&this.beans.colModel.getColDefCol(this.column)&&(hn(this.getGui()),this.createFilter())}destroy(){this.filterWrapper=null,super.destroy()}},G1="ag-resizer-wrapper",Jr=(e,t)=>({tag:"div",ref:`${e}Resizer`,cls:`ag-resizer ag-resizer-${t}`}),OL={tag:"div",cls:G1,children:[Jr("eTopLeft","topLeft"),Jr("eTop","top"),Jr("eTopRight","topRight"),Jr("eRight","right"),Jr("eBottomRight","bottomRight"),Jr("eBottom","bottom"),Jr("eBottomLeft","bottomLeft"),Jr("eLeft","left")]},ML=class extends q{constructor(e,t){super(),this.element=e,this.dragStartPosition={x:0,y:0},this.position={x:0,y:0},this.lastSize={width:-1,height:-1},this.positioned=!1,this.resizersAdded=!1,this.resizeListeners=[],this.boundaryEl=null,this.isResizing=!1,this.isMoving=!1,this.resizable={},this.movable=!1,this.currentResizer=null,this.config=Object.assign({},{popup:!1},t)}wireBeans(e){this.popupSvc=e.popupSvc,this.dragSvc=e.dragSvc}center(){const{clientHeight:e,clientWidth:t}=this.offsetParent,r=t/2-this.getWidth()/2,n=e/2-this.getHeight()/2;this.offsetElement(r,n)}initialisePosition(){if(this.positioned)return;const{centered:e,forcePopupParentAsOffsetParent:t,minWidth:r,width:n,minHeight:i,height:o,x:s,y:a}=this.config;this.offsetParent||this.setOffsetParent();let l=0,c=0;const u=Sr(this.element);if(u){const d=this.findBoundaryElement(),h=window.getComputedStyle(d);if(h.minWidth!=null){const f=d.offsetWidth-this.element.offsetWidth;c=parseInt(h.minWidth,10)-f}if(h.minHeight!=null){const f=d.offsetHeight-this.element.offsetHeight;l=parseInt(h.minHeight,10)-f}}if(this.minHeight=i||l,this.minWidth=r||c,n&&this.setWidth(n),o&&this.setHeight(o),(!n||!o)&&this.refreshSize(),e)this.center();else if(s||a)this.offsetElement(s,a);else if(u&&t){let d=this.boundaryEl,h=!0;if(d||(d=this.findBoundaryElement(),h=!1),d){const f=parseFloat(d.style.top),g=parseFloat(d.style.left);h?this.offsetElement(isNaN(g)?0:g,isNaN(f)?0:f):this.setPosition(g,f)}}this.positioned=!!this.offsetParent}isPositioned(){return this.positioned}getPosition(){return this.position}setMovable(e,t){var n,i;if(!this.config.popup||e===this.movable)return;this.movable=e;const r=this.moveElementDragListener||{eElement:t,onDragStart:this.onMoveStart.bind(this),onDragging:this.onMove.bind(this),onDragStop:this.onMoveEnd.bind(this)};e?((n=this.dragSvc)==null||n.addDragSource(r),this.moveElementDragListener=r):((i=this.dragSvc)==null||i.removeDragSource(r),this.moveElementDragListener=void 0)}setResizable(e){if(this.clearResizeListeners(),e?this.addResizers():this.removeResizers(),typeof e=="boolean"){if(e===!1)return;e={topLeft:e,top:e,topRight:e,right:e,bottomRight:e,bottom:e,bottomLeft:e,left:e}}Object.keys(e).forEach(t=>{var s;const n=!!e[t],i=this.getResizerElement(t),o={dragStartPixels:0,eElement:i,onDragStart:a=>this.onResizeStart(a,t),onDragging:this.onResize.bind(this),onDragStop:a=>this.onResizeEnd(a,t)};(n||!this.isAlive()&&!n)&&(n?((s=this.dragSvc)==null||s.addDragSource(o),this.resizeListeners.push(o),i.style.pointerEvents="all"):i.style.pointerEvents="none",this.resizable[t]=n)})}removeSizeFromEl(){this.element.style.removeProperty("height"),this.element.style.removeProperty("width"),this.element.style.removeProperty("flex")}restoreLastSize(){this.element.style.flex="0 0 auto";const{height:e,width:t}=this.lastSize;t!==-1&&(this.element.style.width=`${t}px`),e!==-1&&(this.element.style.height=`${e}px`)}getHeight(){return this.element.offsetHeight}setHeight(e){const{popup:t}=this.config,r=this.element;let n=!1;if(typeof e=="string"&&e.indexOf("%")!==-1)os(r,e),e=V2(r),n=!0;else if(e=Math.max(this.minHeight,e),this.positioned){const i=this.getAvailableHeight();i&&e>i&&(e=i)}this.getHeight()!==e&&(n?(r.style.maxHeight="unset",r.style.minHeight="unset"):t?os(r,e):(r.style.height=`${e}px`,r.style.flex="0 0 auto",this.lastSize.height=typeof e=="number"?e:parseFloat(e)))}getAvailableHeight(){const{popup:e,forcePopupParentAsOffsetParent:t}=this.config;this.positioned||this.initialisePosition();const{clientHeight:r}=this.offsetParent;if(!r)return null;const n=this.element.getBoundingClientRect(),i=this.offsetParent.getBoundingClientRect(),o=e?this.position.y:n.top,s=e?0:i.top;let a=0;if(t){const c=this.element.parentElement;if(c){const{bottom:u}=c.getBoundingClientRect();a=u-n.bottom}}return r+s-o-a}getWidth(){return this.element.offsetWidth}setWidth(e){const t=this.element,{popup:r}=this.config;let n=!1;if(typeof e=="string"&&e.indexOf("%")!==-1)yr(t,e),e=Tl(t),n=!0;else if(this.positioned){e=Math.max(this.minWidth,e);const{clientWidth:i}=this.offsetParent,o=r?this.position.x:this.element.getBoundingClientRect().left;i&&e+o>i&&(e=i-o)}this.getWidth()!==e&&(n?(t.style.maxWidth="unset",t.style.minWidth="unset"):this.config.popup?yr(t,e):(t.style.width=`${e}px`,t.style.flex=" unset",this.lastSize.width=typeof e=="number"?e:parseFloat(e)))}offsetElement(e=0,t=0){var i;const{forcePopupParentAsOffsetParent:r}=this.config,n=r?this.boundaryEl:this.element;n&&((i=this.popupSvc)==null||i.positionPopup({ePopup:n,keepWithinBounds:!0,skipObserver:this.movable||this.isResizable(),updatePosition:()=>({x:e,y:t})}),this.setPosition(parseFloat(n.style.left),parseFloat(n.style.top)))}constrainSizeToAvailableHeight(e){var r;if(!this.config.forcePopupParentAsOffsetParent)return;const t=()=>{const n=this.getAvailableHeight();this.element.style.setProperty("max-height",`${n}px`)};e&&this.popupSvc?this.resizeObserverSubscriber=fn(this.beans,(r=this.popupSvc)==null?void 0:r.getPopupParent(),t):(this.element.style.removeProperty("max-height"),this.resizeObserverSubscriber&&(this.resizeObserverSubscriber(),this.resizeObserverSubscriber=void 0))}setPosition(e,t){this.position.x=e,this.position.y=t}updateDragStartPosition(e,t){this.dragStartPosition={x:e,y:t}}calculateMouseMovement(e){const{e:t,isLeft:r,isTop:n,anywhereWithin:i,topBuffer:o}=e,s=t.clientX-this.dragStartPosition.x,a=t.clientY-this.dragStartPosition.y,l=this.shouldSkipX(t,!!r,!!i,s)?0:s,c=this.shouldSkipY(t,!!n,o,a)?0:a;return{movementX:l,movementY:c}}shouldSkipX(e,t,r,n){const i=this.element.getBoundingClientRect(),o=this.offsetParent.getBoundingClientRect(),s=this.boundaryEl.getBoundingClientRect(),a=this.config.popup?this.position.x:i.left;let l=a<=0&&o.left>=e.clientX||o.right<=e.clientX&&o.right<=s.right;return l?!0:(t?l=n<0&&e.clientX>a+o.left||n>0&&e.clientX<a+o.left:r?l=n<0&&e.clientX>s.right||n>0&&e.clientX<a+o.left:l=n<0&&e.clientX>s.right||n>0&&e.clientX<s.right,l)}shouldSkipY(e,t,r=0,n){const i=this.element.getBoundingClientRect(),o=this.offsetParent.getBoundingClientRect(),s=this.boundaryEl.getBoundingClientRect(),a=this.config.popup?this.position.y:i.top;let l=a<=0&&o.top>=e.clientY||o.bottom<=e.clientY&&o.bottom<=s.bottom;return l?!0:(t?l=n<0&&e.clientY>a+o.top+r||n>0&&e.clientY<a+o.top:l=n<0&&e.clientY>s.bottom||n>0&&e.clientY<s.bottom,l)}createResizeMap(){const e=t=>({element:this.element.querySelector(`[data-ref=${t}Resizer]`)});this.resizerMap={topLeft:e("eTopLeft"),top:e("eTop"),topRight:e("eTopRight"),right:e("eRight"),bottomRight:e("eBottomRight"),bottom:e("eBottom"),bottomLeft:e("eBottomLeft"),left:e("eLeft")}}addResizers(){if(this.resizersAdded)return;const e=this.element;e&&(e.appendChild(lt(OL)),this.createResizeMap(),this.resizersAdded=!0)}removeResizers(){this.resizerMap=void 0;const e=this.element.querySelector(`.${G1}`);e&&this.element.removeChild(e),this.resizersAdded=!1}getResizerElement(e){return this.resizerMap[e].element}onResizeStart(e,t){this.boundaryEl=this.findBoundaryElement(),this.positioned||this.initialisePosition(),this.currentResizer={isTop:!!t.match(/top/i),isRight:!!t.match(/right/i),isBottom:!!t.match(/bottom/i),isLeft:!!t.match(/left/i)},this.element.classList.add("ag-resizing"),this.resizerMap[t].element.classList.add("ag-active");const{popup:r,forcePopupParentAsOffsetParent:n}=this.config;!r&&!n&&this.applySizeToSiblings(this.currentResizer.isBottom||this.currentResizer.isTop),this.isResizing=!0,this.updateDragStartPosition(e.clientX,e.clientY)}getSiblings(){const t=this.element.parentElement;return t?Array.prototype.slice.call(t.children).filter(r=>!r.classList.contains("ag-hidden")):null}getMinSizeOfSiblings(){const e=this.getSiblings()||[];let t=0,r=0;for(let n=0;n<e.length;n++){const i=e[n],o=!!i.style.flex&&i.style.flex!=="0 0 auto";if(i===this.element)continue;let s=this.minHeight||0,a=this.minWidth||0;if(o){const l=window.getComputedStyle(i);l.minHeight&&(s=parseInt(l.minHeight,10)),l.minWidth&&(a=parseInt(l.minWidth,10))}else s=i.offsetHeight,a=i.offsetWidth;t+=s,r+=a}return{height:t,width:r}}applySizeToSiblings(e){let t=null;const r=this.getSiblings();if(r){for(let n=0;n<r.length;n++){const i=r[n];i!==t&&(e?i.style.height=`${i.offsetHeight}px`:i.style.width=`${i.offsetWidth}px`,i.style.flex="0 0 auto",i===this.element&&(t=r[n+1]))}t&&(t.style.removeProperty("height"),t.style.removeProperty("min-height"),t.style.removeProperty("max-height"),t.style.flex="1 1 auto")}}isResizable(){return Object.values(this.resizable).some(e=>e)}onResize(e){if(!this.isResizing||!this.currentResizer)return;const{popup:t,forcePopupParentAsOffsetParent:r}=this.config,{isTop:n,isRight:i,isBottom:o,isLeft:s}=this.currentResizer,a=i||s,l=o||n,{movementX:c,movementY:u}=this.calculateMouseMovement({e,isLeft:s,isTop:n}),d=this.position.x,h=this.position.y;let f=0,g=0;if(a&&c){const m=s?-1:1,p=this.getWidth(),y=p+c*m;let w=!1;s&&(f=p-y,(d+f<=0||y<=this.minWidth)&&(w=!0,f=0)),w||this.setWidth(y)}if(l&&u){const m=n?-1:1,p=this.getHeight(),y=p+u*m;let w=!1;n?(g=p-y,(h+g<=0||y<=this.minHeight)&&(w=!0,g=0)):!this.config.popup&&!this.config.forcePopupParentAsOffsetParent&&p<y&&this.getMinSizeOfSiblings().height+y>this.element.parentElement.offsetHeight&&(w=!0),w||this.setHeight(y)}this.updateDragStartPosition(e.clientX,e.clientY),((t||r)&&f||g)&&this.offsetElement(d+f,h+g)}onResizeEnd(e,t){this.isResizing=!1,this.currentResizer=null,this.boundaryEl=null,this.element.classList.remove("ag-resizing"),this.resizerMap[t].element.classList.remove("ag-active"),this.dispatchLocalEvent({type:"resize"})}refreshSize(){const e=this.element;this.config.popup&&(this.config.width||this.setWidth(e.offsetWidth),this.config.height||this.setHeight(e.offsetHeight))}onMoveStart(e){this.boundaryEl=this.findBoundaryElement(),this.positioned||this.initialisePosition(),this.isMoving=!0,this.element.classList.add("ag-moving"),this.updateDragStartPosition(e.clientX,e.clientY)}onMove(e){if(!this.isMoving)return;const{x:t,y:r}=this.position;let n;this.config.calculateTopBuffer&&(n=this.config.calculateTopBuffer());const{movementX:i,movementY:o}=this.calculateMouseMovement({e,isTop:!0,anywhereWithin:!0,topBuffer:n});this.offsetElement(t+i,r+o),this.updateDragStartPosition(e.clientX,e.clientY)}onMoveEnd(){this.isMoving=!1,this.boundaryEl=null,this.element.classList.remove("ag-moving")}setOffsetParent(){this.config.forcePopupParentAsOffsetParent&&this.popupSvc?this.offsetParent=this.popupSvc.getPopupParent():this.offsetParent=this.element.offsetParent}findBoundaryElement(){let e=this.element;for(;e;){if(window.getComputedStyle(e).position!=="static")return e;e=e.parentElement}return this.element}clearResizeListeners(){var e;for(;this.resizeListeners.length;){const t=this.resizeListeners.pop();(e=this.dragSvc)==null||e.removeDragSource(t)}}destroy(){var e;super.destroy(),this.moveElementDragListener&&((e=this.dragSvc)==null||e.removeDragSource(this.moveElementDragListener)),this.constrainSizeToAvailableHeight(!1),this.clearResizeListeners(),this.removeResizers()}},DL="ag-focus-managed",bo=class extends q{constructor(e,t={}){super(),this.eFocusable=e,this.callbacks=t,this.callbacks={shouldStopEventPropagation:()=>!1,onTabKeyDown:r=>{if(r.defaultPrevented)return;const n=yo(this.beans,this.eFocusable,!1,r.shiftKey);n&&(n.focus(),r.preventDefault())},...t}}postConstruct(){const{eFocusable:e,callbacks:{onFocusIn:t,onFocusOut:r}}=this;e.classList.add(DL),this.addKeyDownListeners(e),t&&this.addManagedElementListeners(e,{focusin:t}),r&&this.addManagedElementListeners(e,{focusout:r})}addKeyDownListeners(e){this.addManagedElementListeners(e,{keydown:t=>{if(t.defaultPrevented||Lr(t))return;const{callbacks:r}=this;if(r.shouldStopEventPropagation(t)){Kn(t);return}t.key===j.TAB?r.onTabKeyDown(t):r.handleKeyDown&&r.handleKeyDown(t)}})}},W1={applyFilter:"Apply",clearFilter:"Clear",resetFilter:"Reset",cancelFilter:"Cancel",textFilter:"Text Filter",numberFilter:"Number Filter",dateFilter:"Date Filter",setFilter:"Set Filter",filterOoo:"Filter...",empty:"Choose one",equals:"Equals",notEqual:"Does not equal",lessThan:"Less than",greaterThan:"Greater than",inRange:"Between",inRangeStart:"From",inRangeEnd:"To",lessThanOrEqual:"Less than or equal to",greaterThanOrEqual:"Greater than or equal to",contains:"Contains",notContains:"Does not contain",startsWith:"Begins with",endsWith:"Ends with",blank:"Blank",notBlank:"Not blank",before:"Before",after:"After",andCondition:"AND",orCondition:"OR",dateFormatOoo:"yyyy-mm-dd"};function j1(e,t){const{debounceMs:r}=e;return jl(e)?(r!=null&&Q(71),0):r??t}function jl(e){var t;return(((t=e.buttons)==null?void 0:t.indexOf("apply"))??-1)>=0}var kL=class extends ct{constructor(e){super(),this.filterNameKey=e,this.applyActive=!1,this.hidePopup=null,this.debouncePending=!1,this.appliedModel=null,this.eFilterBody=fe,this.buttonListeners=[],this.defaultDebounceMs=0}postConstruct(){this.resetTemplate(),this.createManagedBean(new bo(this.getFocusableElement(),{handleKeyDown:this.handleKeyDown.bind(this)})),this.positionableFeature=new ML(this.getPositionableElement(),{forcePopupParentAsOffsetParent:!0}),this.createBean(this.positionableFeature)}handleKeyDown(e){}getFilterTitle(){return this.translate(this.filterNameKey)}isFilterActive(){return!!this.appliedModel}resetTemplate(e){let t=this.getGui();t==null||t.removeEventListener("submit",this.onFormSubmit);const r={tag:"form",cls:"ag-filter-wrapper",children:[{tag:"div",ref:"eFilterBody",cls:`ag-filter-body-wrapper ag-${this.getCssIdentifier()}-body-wrapper`,children:[this.createBodyTemplate()]}]};this.setTemplate(r,this.getAgComponents(),e),t=this.getGui(),t==null||t.addEventListener("submit",this.onFormSubmit)}isReadOnly(){return!!this.params.readOnly}init(e){this.setParams(e),this.resetUiToDefaults(!0).then(()=>{this.updateUiVisibility(),this.setupOnBtApplyDebounce()})}setParams(e){this.params=e,this.applyActive=jl(e),this.resetButtonsPanel(e)}updateParams(e){this.params=e,this.applyActive=jl(e),this.resetUiToActiveModel(this.getModel(),()=>{this.updateUiVisibility(),this.setupOnBtApplyDebounce()})}resetButtonsPanel(e,t){const{buttons:r,readOnly:n}=t??{},{buttons:i,readOnly:o}=e;if(n===o&&sp(r,i))return;const s=i&&i.length>0&&!this.isReadOnly();if(this.eButtonsPanel?(hn(this.eButtonsPanel),this.buttonListeners.forEach(c=>c()),this.buttonListeners=[]):s&&(this.eButtonsPanel=lt({tag:"div",cls:"ag-filter-apply-panel"})),!s){this.eButtonsPanel&&jn(this.eButtonsPanel);return}const a=document.createDocumentFragment(),l=c=>{let u;const d=c?this.translate(`${c}Filter`):void 0;switch(c){case"apply":u=g=>this.onBtApply(!1,!1,g);break;case"clear":u=()=>this.onBtClear();break;case"reset":u=()=>this.onBtReset();break;case"cancel":u=g=>{this.onBtCancel(g)};break;default:Q(75);return}const f=lt({tag:"button",attrs:{type:c==="apply"?"submit":"button"},ref:`${c}FilterButton`,cls:"ag-button ag-standard-button ag-filter-apply-panel-button",children:d});this.buttonListeners.push(...this.addManagedElementListeners(f,{click:u})),a.append(f)};i.forEach(c=>l(c)),this.eButtonsPanel.append(a),this.getGui().appendChild(this.eButtonsPanel)}setupOnBtApplyDebounce(){const e=j1(this.params,this.defaultDebounceMs),t=kr(this,this.checkApplyDebounce.bind(this),e);this.onBtApplyDebounce=()=>{this.debouncePending=!0,t()}}checkApplyDebounce(){this.debouncePending&&(this.debouncePending=!1,this.onBtApply())}getModel(){return this.appliedModel??null}setModel(e){return(e!=null?this.setModelIntoUi(e):this.resetUiToDefaults()).then(()=>{this.updateUiVisibility(),this.applyModel("api")})}onBtCancel(e){this.resetUiToActiveModel(this.getModel(),()=>{this.handleCancelEnd(e)})}handleCancelEnd(e){this.params.closeOnApply&&this.close(e)}resetUiToActiveModel(e,t){const r=()=>{this.onUiChanged(!1,"prevent"),t==null||t()};e!=null?this.setModelIntoUi(e).then(r):this.resetUiToDefaults().then(r)}onBtClear(){this.resetUiToDefaults().then(()=>this.onUiChanged())}onBtReset(){this.onBtClear(),this.onBtApply()}applyModel(e="api"){const t=this.getModelFromUi();if(!this.isModelValid(t))return!1;const r=this.appliedModel;return this.appliedModel=t,!this.areModelsEqual(r,t)}isModelValid(e){return!0}onFormSubmit(e){e.preventDefault()}onBtApply(e=!1,t=!1,r){r&&r.preventDefault(),this.applyModel(t?"rowDataUpdated":"ui")&&this.params.filterChangedCallback({afterFloatingFilter:e,afterDataChange:t,source:"columnFilter"});const{closeOnApply:n}=this.params;n&&this.applyActive&&!e&&!t&&this.close(r)}onNewRowsLoaded(){}close(e){if(!this.hidePopup)return;const t=e,r=t&&t.key;let n;(r==="Enter"||r==="Space")&&(n={keyboardEvent:t}),this.hidePopup(n),this.hidePopup=null}onUiChanged(e=!1,t){if(this.updateUiVisibility(),this.params.filterModifiedCallback(),this.applyActive&&!this.isReadOnly()){const r=this.isModelValid(this.getModelFromUi()),n=this.queryForHtmlElement('[data-ref="applyFilterButton"]');n&&xs(n,!r)}e&&!t||t==="immediately"?this.onBtApply(e):(!this.applyActive&&!t||t==="debounce")&&this.onBtApplyDebounce()}afterGuiAttached(e){e&&(this.hidePopup=e.hidePopup),this.refreshFilterResizer(e==null?void 0:e.container)}refreshFilterResizer(e){const{positionableFeature:t,gos:r}=this;if(!t||e==="toolPanel")return;e==="floatingFilter"||e==="columnFilter"?(t.restoreLastSize(),t.setResizable(r.get("enableRtl")?{bottom:!0,bottomLeft:!0,left:!0}:{bottom:!0,bottomRight:!0,right:!0})):(t.removeSizeFromEl(),t.setResizable(!1)),t.constrainSizeToAvailableHeight(!0)}afterGuiDetached(){var e;this.checkApplyDebounce(),(e=this.positionableFeature)==null||e.constrainSizeToAvailableHeight(!1)}refresh(e){const t=this.params;return this.params=e,this.resetButtonsPanel(e,t),!0}destroy(){const e=this.getGui();e&&e.removeEventListener("submit",this.onFormSubmit),this.hidePopup=null,this.positionableFeature&&(this.positionableFeature=this.destroyBean(this.positionableFeature)),this.appliedModel=null,super.destroy()}translate(e){return this.getLocaleTextFunc()(e,W1[e])}getCellValue(e){return this.params.getValue(e)}getPositionableElement(){return this.eFilterBody}};function IL(e,t,r){if(t==null)return null;let n=null;const{compName:i,jsComp:o,fwComp:s}=I_(e,t);return i?n={agSetColumnFilter:"agSetColumnFloatingFilter",agMultiColumnFilter:"agMultiColumnFloatingFilter",agGroupColumnFilter:"agGroupColumnFloatingFilter",agNumberColumnFilter:"agNumberColumnFloatingFilter",agDateColumnFilter:"agDateColumnFloatingFilter",agTextColumnFilter:"agTextColumnFloatingFilter"}[i]:o==null&&s==null&&t.filter===!0&&(n=r()),n}var yl={AUTO_HEIGHT:"ag-layout-auto-height",NORMAL:"ag-layout-normal",PRINT:"ag-layout-print"},gp=class extends q{constructor(e){super(),this.view=e}postConstruct(){this.addManagedPropertyListener("domLayout",this.updateLayoutClasses.bind(this)),this.updateLayoutClasses()}updateLayoutClasses(){const e=this.gos.get("domLayout"),t={autoHeight:e==="autoHeight",normal:e==="normal",print:e==="print"},r=t.autoHeight?yl.AUTO_HEIGHT:t.print?yl.PRINT:yl.NORMAL;this.view.updateLayoutClasses(r,t)}},Xr="Viewport",_v="fakeVScrollComp",Lv=["fakeHScrollComp","centerHeader","topCenter","bottomCenter","stickyTopCenter","stickyBottomCenter"],Bv=100,gd=150,_L=class extends q{constructor(e){super(),this.clearRetryListenerFncs=[],this.lastScrollSource=[null,null],this.scrollLeft=-1,this.nextScrollTop=-1,this.scrollTop=-1,this.lastOffsetHeight=-1,this.lastScrollTop=-1,this.lastIsHorizontalScrollShowing=!1,this.scrollTimer=0,this.isVerticalPositionInvalidated=!0,this.isHorizontalPositionInvalidated=!0,this.eBodyViewport=e,this.resetLastHScrollDebounced=kr(this,()=>this.lastScrollSource[1]=null,gd),this.resetLastVScrollDebounced=kr(this,()=>this.lastScrollSource[0]=null,gd)}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.animationFrameSvc=e.animationFrameSvc,this.visibleCols=e.visibleCols}destroy(){super.destroy(),this.clearRetryListenerFncs=[],window.clearTimeout(this.scrollTimer)}postConstruct(){this.enableRtl=this.gos.get("enableRtl");const e=this.invalidateVerticalScroll.bind(this),t=this.invalidateHorizontalScroll.bind(this);this.addManagedEventListeners({displayedColumnsWidthChanged:this.onDisplayedColumnsWidthChanged.bind(this),gridSizeChanged:e,scrollGapChanged:t}),this.addManagedElementListeners(this.eBodyViewport,{scroll:e}),this.ctrlsSvc.whenReady(this,r=>{this.centerRowsCtrl=r.center,this.onDisplayedColumnsWidthChanged(),this.addScrollListener()})}invalidateHorizontalScroll(){this.isHorizontalPositionInvalidated=!0}invalidateVerticalScroll(){this.isVerticalPositionInvalidated=!0}addScrollListener(){this.addHorizontalScrollListeners(),this.addVerticalScrollListeners()}addHorizontalScrollListeners(){this.addManagedElementListeners(this.centerRowsCtrl.eViewport,{scroll:this.onHScroll.bind(this,Xr)});for(const e of Lv){const t=this.ctrlsSvc.get(e);this.registerScrollPartner(t,this.onHScroll.bind(this,e))}}addVerticalScrollListeners(){const e=this.ctrlsSvc.get("fakeVScrollComp"),t=this.gos.get("debounceVerticalScrollbar"),r=t?kr(this,this.onVScroll.bind(this,Xr),Bv):this.onVScroll.bind(this,Xr),n=t?kr(this,this.onVScroll.bind(this,_v),Bv):this.onVScroll.bind(this,_v);this.addManagedElementListeners(this.eBodyViewport,{scroll:r}),this.registerScrollPartner(e,n)}registerScrollPartner(e,t){e.onScrollCallback(t)}onDisplayedColumnsWidthChanged(){this.enableRtl&&this.horizontallyScrollHeaderCenterAndFloatingCenter()}horizontallyScrollHeaderCenterAndFloatingCenter(e){this.centerRowsCtrl!=null&&(e===void 0&&(e=this.centerRowsCtrl.getCenterViewportScrollLeft()),this.setScrollLeftForAllContainersExceptCurrent(Math.abs(e)))}setScrollLeftForAllContainersExceptCurrent(e){for(const t of[...Lv,Xr]){if(this.lastScrollSource[1]===t)continue;const r=this.getViewportForSource(t);Ol(r,e,this.enableRtl)}}getViewportForSource(e){return e===Xr?this.centerRowsCtrl.eViewport:this.ctrlsSvc.get(e).eViewport}isControllingScroll(e,t){return this.lastScrollSource[t]==null?(t===0?this.lastScrollSource[0]=e:this.lastScrollSource[1]=e,!0):this.lastScrollSource[t]===e}onHScroll(e){if(!this.isControllingScroll(e,1))return;const t=this.centerRowsCtrl.eViewport,{scrollLeft:r}=t;if(this.shouldBlockScrollUpdate(1,r,!0))return;const n=Fl(this.getViewportForSource(e),this.enableRtl);this.doHorizontalScroll(n),this.resetLastHScrollDebounced()}onVScroll(e){if(!this.isControllingScroll(e,0))return;let t;if(e===Xr?t=this.eBodyViewport.scrollTop:t=this.ctrlsSvc.get("fakeVScrollComp").getScrollPosition(),this.shouldBlockScrollUpdate(0,t,!0))return;const{animationFrameSvc:r}=this;r==null||r.setScrollTop(t),this.nextScrollTop=t,e===Xr?this.ctrlsSvc.get("fakeVScrollComp").setScrollPosition(t):this.eBodyViewport.scrollTop=t,r!=null&&r.active?r.schedule():this.scrollGridIfNeeded(!0),this.resetLastVScrollDebounced()}doHorizontalScroll(e){const t=this.ctrlsSvc.get("fakeHScrollComp").getScrollPosition();this.scrollLeft===e&&e===t||(this.scrollLeft=e,this.fireScrollEvent(1),this.horizontallyScrollHeaderCenterAndFloatingCenter(e),this.centerRowsCtrl.onHorizontalViewportChanged(!0))}fireScrollEvent(e){const t={type:"bodyScroll",direction:e===1?"horizontal":"vertical",left:this.scrollLeft,top:this.scrollTop};this.eventSvc.dispatchEvent(t),window.clearTimeout(this.scrollTimer),this.scrollTimer=window.setTimeout(()=>{this.scrollTimer=0,this.eventSvc.dispatchEvent({...t,type:"bodyScrollEnd"})},gd)}shouldBlockScrollUpdate(e,t,r=!1){return r&&!Dn()?!1:e===0?this.shouldBlockVerticalScroll(t):this.shouldBlockHorizontalScroll(t)}shouldBlockVerticalScroll(e){const t=rp(this.eBodyViewport),{scrollHeight:r}=this.eBodyViewport;return e<0||e+t>r}shouldBlockHorizontalScroll(e){const t=this.centerRowsCtrl.getCenterWidth(),{scrollWidth:r}=this.centerRowsCtrl.eViewport;if(this.enableRtl){if(e>0)return!0}else if(e<0)return!0;return Math.abs(e)+t>r}redrawRowsAfterScroll(){this.fireScrollEvent(0)}checkScrollLeft(){this.scrollLeft!==this.centerRowsCtrl.getCenterViewportScrollLeft()&&this.onHScroll(Xr)}scrollGridIfNeeded(e=!1){const t=this.scrollTop!=this.nextScrollTop;return t&&(this.scrollTop=this.nextScrollTop,e&&this.invalidateVerticalScroll(),this.redrawRowsAfterScroll()),t}setHorizontalScrollPosition(e,t=!1){const n=this.centerRowsCtrl.eViewport.scrollWidth-this.centerRowsCtrl.getCenterWidth();!t&&this.shouldBlockScrollUpdate(1,e)&&(this.enableRtl?e=e>0?0:n:e=Math.min(Math.max(e,0),n)),Ol(this.centerRowsCtrl.eViewport,Math.abs(e),this.enableRtl),this.doHorizontalScroll(e)}setVerticalScrollPosition(e){this.invalidateVerticalScroll(),this.eBodyViewport.scrollTop=e}getVScrollPosition(){if(!this.isVerticalPositionInvalidated){const{lastOffsetHeight:r,lastScrollTop:n}=this;return{top:n,bottom:n+r}}this.isVerticalPositionInvalidated=!1;const{scrollTop:e,offsetHeight:t}=this.eBodyViewport;return this.lastScrollTop=e,this.lastOffsetHeight=t,{top:e,bottom:e+t}}getApproximateVScollPosition(){return this.lastScrollTop>=0&&this.lastOffsetHeight>=0?{top:this.scrollTop,bottom:this.scrollTop+this.lastOffsetHeight}:this.getVScrollPosition()}getHScrollPosition(){return this.centerRowsCtrl.getHScrollPosition()}isHorizontalScrollShowing(){return this.isHorizontalPositionInvalidated&&(this.lastIsHorizontalScrollShowing=this.centerRowsCtrl.isHorizontalScrollShowing(),this.isHorizontalPositionInvalidated=!1),this.lastIsHorizontalScrollShowing}scrollHorizontally(e){const t=this.centerRowsCtrl.eViewport.scrollLeft;return this.setHorizontalScrollPosition(t+e),this.centerRowsCtrl.eViewport.scrollLeft-t}scrollToTop(){this.eBodyViewport.scrollTop=0}ensureNodeVisible(e,t=null){const{rowModel:r}=this.beans,n=r.getRowCount();let i=-1;for(let o=0;o<n;o++){const s=r.getRow(o);if(typeof e=="function"){if(s&&e(s)){i=o;break}}else if(e===s||e===s.data){i=o;break}}i>=0&&this.ensureIndexVisible(i,t)}ensureIndexVisible(e,t,r=0){if(pt(this.gos,"print"))return;const{rowModel:n}=this.beans,i=n.getRowCount();if(typeof e!="number"||e<0||e>=i){Q(88,{index:e});return}this.clearRetryListeners();const{frameworkOverrides:o,pageBounds:s,rowContainerHeight:a,rowRenderer:l}=this.beans;o.wrapIncoming(()=>{var g,m;const c=this.ctrlsSvc.getGridBodyCtrl(),u=n.getRow(e);let d,h,f=0;this.invalidateVerticalScroll();do{const{stickyTopHeight:p,stickyBottomHeight:y}=c,w=u.rowTop,b=u.rowHeight,x=s.getPixelOffset(),C=u.rowTop-x,S=C+u.rowHeight,A=this.getVScrollPosition(),P=a.divStretchOffset,E=A.top+P,O=A.bottom+P,R=O-E,T=a.getScrollPositionForPixel(C),F=a.getScrollPositionForPixel(S-R),I=Math.min((T+F)/2,C),k=E+p>C,B=O-y<S;let N=null;t==="top"?N=T-p:t==="bottom"?N=F+y:t==="middle"?N=I:k?N=T-p:B&&(N=F+y),N!==null&&(this.setVerticalScrollPosition(N),l.redraw({afterScroll:!0})),d=w!==u.rowTop||b!==u.rowHeight,h=p!==c.stickyTopHeight||y!==c.stickyBottomHeight,f++}while((d||h)&&f<10);if((g=this.animationFrameSvc)==null||g.flushAllFrames(),r<10&&(u!=null&&u.stub||!((m=this.beans.rowAutoHeight)!=null&&m.areRowsMeasured()))){const p=this.getVScrollPosition().top;this.clearRetryListenerFncs=this.addManagedEventListeners({bodyScroll:()=>{const y=this.getVScrollPosition().top;p!==y&&this.clearRetryListeners()},modelUpdated:()=>{this.clearRetryListeners(),!(e>=n.getRowCount())&&this.ensureIndexVisible(e,t,r+1)}})}})}clearRetryListeners(){this.clearRetryListenerFncs.forEach(e=>e()),this.clearRetryListenerFncs=[]}ensureColumnVisible(e,t="auto"){const{colModel:r,frameworkOverrides:n}=this.beans,i=r.getCol(e);if(!i||i.isPinned()||!this.visibleCols.isColDisplayed(i))return;const o=this.getPositionedHorizontalScroll(i,t);n.wrapIncoming(()=>{var s;o!==null&&this.centerRowsCtrl.setCenterViewportScrollLeft(o),this.centerRowsCtrl.onHorizontalViewportChanged(),(s=this.animationFrameSvc)==null||s.flushAllFrames()})}getPositionedHorizontalScroll(e,t){const{columnBeforeStart:r,columnAfterEnd:n}=this.isColumnOutsideViewport(e),i=this.centerRowsCtrl.getCenterWidth()<e.getActualWidth(),o=this.centerRowsCtrl.getCenterWidth(),s=this.enableRtl;let a=(s?r:n)||i,l=s?n:r;t!=="auto"&&(a=t==="start",l=t==="end");const c=t==="middle";if(a||l||c){const{colLeft:u,colMiddle:d,colRight:h}=this.getColumnBounds(e);return c?d-o/2:a?s?h:u:s?u-o:h-o}return null}isColumnOutsideViewport(e){const{start:t,end:r}=this.getViewportBounds(),{colLeft:n,colRight:i}=this.getColumnBounds(e),o=this.enableRtl,s=o?t>i:r<i,a=o?r<n:t>n;return{columnBeforeStart:s,columnAfterEnd:a}}getColumnBounds(e){const t=this.enableRtl,r=this.visibleCols.bodyWidth,n=e.getActualWidth(),i=e.getLeft(),o=t?-1:1,s=t?r-i:i,a=s+n*o,l=s+n/2*o;return{colLeft:s,colMiddle:l,colRight:a}}getViewportBounds(){const e=this.centerRowsCtrl.getCenterWidth(),t=this.centerRowsCtrl.getCenterViewportScrollLeft(),r=t,n=e+t;return{start:r,end:n,width:e}}},pp=class extends q{constructor(e,t=!1){super(),this.callback=e,this.addSpacer=t}postConstruct(){const e=this.setWidth.bind(this);this.addManagedPropertyListener("domLayout",e),this.addManagedEventListeners({columnContainerWidthChanged:e,displayedColumnsChanged:e,leftPinnedWidthChanged:e}),this.addSpacer&&this.addManagedEventListeners({rightPinnedWidthChanged:e,scrollVisibilityChanged:e,scrollbarWidthChanged:e}),this.setWidth()}setWidth(){const e=pt(this.gos,"print"),{visibleCols:t,scrollVisibleSvc:r}=this.beans,n=t.bodyWidth,i=t.getColsLeftWidth(),o=t.getDisplayedColumnsRightWidth();let s;e?s=n+i+o:(s=n,this.addSpacer&&(this.gos.get("enableRtl")?i:o)===0&&r.verticalScrollShowing&&(s+=r.getScrollbarWidth())),this.callback(s)}},LL=class extends q{constructor(e){super(),this.centerContainerCtrl=e}wireBeans(e){this.scrollVisibleSvc=e.scrollVisibleSvc}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCtrl=e.gridBodyCtrl,this.listenForResize()}),this.addManagedEventListeners({scrollbarWidthChanged:this.onScrollbarWidthChanged.bind(this)}),this.addManagedPropertyListeners(["alwaysShowHorizontalScroll","alwaysShowVerticalScroll"],()=>{this.checkViewportAndScrolls()})}listenForResize(){const{beans:e,centerContainerCtrl:t,gridBodyCtrl:r}=this,n=()=>{Ur(e,()=>{this.onCenterViewportResized()})};t.registerViewportResizeListener(n),r.registerBodyViewportResizeListener(n)}onScrollbarWidthChanged(){this.checkViewportAndScrolls()}onCenterViewportResized(){if(this.scrollVisibleSvc.updateScrollGap(),this.centerContainerCtrl.isViewportInTheDOMTree()){const{pinnedCols:e,colFlex:t}=this.beans;e==null||e.keepPinnedColumnsNarrowerThanViewport(),this.checkViewportAndScrolls();const r=this.centerContainerCtrl.getCenterWidth();r!==this.centerWidth&&(this.centerWidth=r,t==null||t.refreshFlexedColumns({viewportWidth:this.centerWidth,updateBodyWidths:!0,fireResizedEvent:!0}))}else this.bodyHeight=0}checkViewportAndScrolls(){this.updateScrollVisibleService(),this.checkBodyHeight(),this.onHorizontalViewportChanged(),this.gridBodyCtrl.scrollFeature.checkScrollLeft()}getBodyHeight(){return this.bodyHeight}checkBodyHeight(){const e=this.gridBodyCtrl.eBodyViewport,t=rp(e);this.bodyHeight!==t&&(this.bodyHeight=t,this.eventSvc.dispatchEvent({type:"bodyHeightChanged"}))}updateScrollVisibleService(){this.updateScrollVisibleServiceImpl(),setTimeout(this.updateScrollVisibleServiceImpl.bind(this),500)}updateScrollVisibleServiceImpl(){const e={horizontalScrollShowing:this.centerContainerCtrl.isHorizontalScrollShowing(),verticalScrollShowing:this.gridBodyCtrl.isVerticalScrollShowing()};this.scrollVisibleSvc.setScrollsVisible(e)}onHorizontalViewportChanged(){const e=this.centerContainerCtrl.getCenterWidth(),t=this.centerContainerCtrl.getViewportScrollLeft();this.beans.colViewport.setScrollPosition(e,t)}};function V1(e,t,r,n,i,o){if(r==null&&t==null)return;const s={},a={},l=(c,u)=>{c.split(" ").forEach(d=>{d.trim()!=""&&u(d)})};if(r){const c=Object.keys(r);for(let u=0;u<c.length;u++){const d=c[u],h=r[d];let f;typeof h=="string"?f=e?e.evaluate(h,n):!0:typeof h=="function"&&(f=h(n)),l(d,g=>{f?s[g]=!0:a[g]=!0})}}t&&o&&Object.keys(t).forEach(c=>l(c,u=>{s[u]||(a[u]=!0)})),o&&Object.keys(a).forEach(o),Object.keys(s).forEach(i)}function zv(e){if(e.group)return e.level;const t=e.parent;return t?t.level+1:0}var BL=0,Vl="renderedRow",Nh=class extends q{constructor(e,t,r,n,i){var o;super(),this.rowNode=e,this.useAnimationFrameForCreate=n,this.printLayout=i,this.allRowGuis=[],this.active=!0,this.centerCellCtrls={list:[],map:{}},this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}},this.slideInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.fadeInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.rowDragComps=[],this.lastMouseDownOnDragger=!1,this.emptyStyle={},this.updateColumnListsPending=!1,this.rowId=null,this.businessKey=null,this.beans=t,this.gos=t.gos,this.paginationPage=((o=t.pagination)==null?void 0:o.getCurrentPage())??0,this.suppressRowTransform=this.gos.get("suppressRowTransform"),this.instanceId=e.id+"-"+BL++,this.rowId=gl(e.id),this.initRowBusinessKey(),this.rowFocused=t.focusSvc.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned),this.rowLevel=zv(this.rowNode),this.setRowType(),this.setAnimateFlags(r),this.rowStyles=this.processStylesFromGridOptions(),this.addListeners()}initRowBusinessKey(){this.businessKeyForNodeFunc=this.gos.get("getBusinessKeyForNode"),this.updateRowBusinessKey()}updateRowBusinessKey(){if(typeof this.businessKeyForNodeFunc!="function")return;const e=this.businessKeyForNodeFunc(this.rowNode);this.businessKey=gl(e)}updateGui(e,t){e==="left"?this.leftGui=t:e==="right"?this.rightGui=t:e==="fullWidth"?this.fullWidthGui=t:this.centerGui=t}setComp(e,t,r,n){var d;const{context:i,focusSvc:o}=this.beans;n=Aa(this,i,n);const s={rowComp:e,element:t,containerType:r,compBean:n};this.allRowGuis.push(s),this.updateGui(r,s),this.initialiseRowComp(s);const a=this.rowNode,l=this.rowType==="FullWidthLoading"||a.stub,c=!a.data&&this.beans.rowModel.getType()==="infinite";!l&&!c&&!a.rowPinned&&this.beans.rowRenderer.dispatchFirstDataRenderedEvent();const u=(d=this.fullWidthGui)==null?void 0:d.element;u&&!this.editing&&o.isRowFocused(a.rowIndex,a.rowPinned)&&o.shouldTakeFocus()&&setTimeout(()=>u.focus({preventScroll:!0}),0)}unsetComp(e){this.allRowGuis=this.allRowGuis.filter(t=>t.containerType!==e),this.updateGui(e,void 0)}isCacheable(){return this.rowType==="FullWidthDetail"&&this.gos.get("keepDetailRows")}setCached(e){const t=e?"none":"";this.allRowGuis.forEach(r=>r.element.style.display=t)}initialiseRowComp(e){const t=this.gos;this.onSuppressCellFocusChanged(this.beans.gos.get("suppressCellFocus")),this.listenOnDomOrder(e),this.onRowHeightChanged(e),this.updateRowIndexes(e),this.setFocusedClasses(e),this.setStylesFromGridOptions(!1,e),In(t)&&this.rowNode.selectable&&this.onRowSelected(e),this.updateColumnLists(!this.useAnimationFrameForCreate);const r=e.rowComp;this.getInitialRowClasses(e.containerType).forEach(i=>r.toggleCss(i,!0)),this.executeSlideAndFadeAnimations(e),this.rowNode.group&&Ph(e.element,this.rowNode.expanded==!0),this.setRowCompRowId(r),this.setRowCompRowBusinessKey(r),Li(t,e.element,Vl,this),e.compBean.addDestroyFunc(()=>Li(t,e.element,Vl,null)),this.useAnimationFrameForCreate?this.beans.animationFrameSvc.createTask(this.addHoverFunctionality.bind(this,e),this.rowNode.rowIndex,"p2",!1):this.addHoverFunctionality(e),this.isFullWidth()&&this.setupFullWidth(e),t.get("rowDragEntireRow")&&this.addRowDraggerToRow(e),this.useAnimationFrameForCreate&&this.beans.animationFrameSvc.addDestroyTask(()=>{this.isAlive()&&e.rowComp.toggleCss("ag-after-created",!0)}),this.executeProcessRowPostCreateFunc()}setRowCompRowBusinessKey(e){this.businessKey!=null&&e.setRowBusinessKey(this.businessKey)}setRowCompRowId(e){const t=gl(this.rowNode.id);this.rowId=t,t!=null&&e.setRowId(t)}executeSlideAndFadeAnimations(e){const{containerType:t}=e;this.slideInAnimation[t]&&(Fh(()=>{this.onTopChanged()}),this.slideInAnimation[t]=!1),this.fadeInAnimation[t]&&(Fh(()=>{e.rowComp.toggleCss("ag-opacity-zero",!1)}),this.fadeInAnimation[t]=!1)}addRowDraggerToRow(e){var n;const t=(n=this.beans.rowDragSvc)==null?void 0:n.createRowDragCompForRow(this.rowNode,e.element);if(!t)return;const r=this.createBean(t,this.beans.context);this.rowDragComps.push(r),e.compBean.addDestroyFunc(()=>{this.rowDragComps=this.rowDragComps.filter(i=>i!==r),this.destroyBean(r,this.beans.context)})}setupFullWidth(e){const t=this.getPinnedForContainer(e.containerType),r=this.createFullWidthCompDetails(e.element,t);e.rowComp.showFullWidth(r)}getFullWidthCellRenderers(){var e,t;return this.gos.get("embedFullWidthRows")?this.allRowGuis.map(r=>{var n;return(n=r==null?void 0:r.rowComp)==null?void 0:n.getFullWidthCellRenderer()}):[(t=(e=this.fullWidthGui)==null?void 0:e.rowComp)==null?void 0:t.getFullWidthCellRenderer()]}executeProcessRowPostCreateFunc(){const e=this.gos.getCallback("processRowPostCreate");if(!e||!this.areAllContainersReady())return;const t={eRow:this.centerGui.element,ePinnedLeftRow:this.leftGui?this.leftGui.element:void 0,ePinnedRightRow:this.rightGui?this.rightGui.element:void 0,node:this.rowNode,rowIndex:this.rowNode.rowIndex,addRenderedRowListener:this.addEventListener.bind(this)};e(t)}areAllContainersReady(){const{leftGui:e,centerGui:t,rightGui:r,beans:{visibleCols:n}}=this,i=!!e||!n.isPinningLeft(),o=!!t,s=!!r||!n.isPinningRight();return i&&o&&s}isNodeFullWidthCell(){if(this.rowNode.detail)return!0;const e=this.beans.gos.getCallback("isFullWidthRow");return e?e({rowNode:this.rowNode}):!1}setRowType(){const e=this.rowNode.stub&&!this.gos.get("suppressServerSideFullWidthLoadingRow")&&!this.gos.get("groupHideOpenParents"),t=this.isNodeFullWidthCell(),r=this.gos.get("masterDetail")&&this.rowNode.detail,n=this.beans.colModel.isPivotMode(),i=cI(this.gos,this.rowNode,n);e?this.rowType="FullWidthLoading":r?this.rowType="FullWidthDetail":t?this.rowType="FullWidth":i?this.rowType="FullWidthGroup":this.rowType="Normal"}updateColumnLists(e=!1,t=!1){if(this.isFullWidth())return;const{animationFrameSvc:r}=this.beans;if(!(r!=null&&r.active)||e||this.printLayout){this.updateColumnListsImpl(t);return}this.updateColumnListsPending||(r.createTask(()=>{this.active&&this.updateColumnListsImpl(!0)},this.rowNode.rowIndex,"p1",!1),this.updateColumnListsPending=!0)}getNewCellCtrl(e){var r;if(!((r=this.beans.rowSpanSvc)!=null&&r.isCellSpanning(e,this.rowNode)))return new vl(e,this.rowNode,this.beans,this)}isCorrectCtrlForSpan(e){var t;return!((t=this.beans.rowSpanSvc)!=null&&t.isCellSpanning(e.column,this.rowNode))}createCellCtrls(e,t,r=null){const n={list:[],map:{}},i=(c,u,d)=>{d!=null?n.list.splice(d,0,u):n.list.push(u),n.map[c]=u},o=[];for(const c of t){const u=c.getInstanceId();let d=e.map[u];d&&!this.isCorrectCtrlForSpan(d)&&(d.destroy(),d=void 0),d||(d=this.getNewCellCtrl(c)),d&&i(u,d)}for(const c of e.list){const u=c.column.getInstanceId();if(n.map[u]!=null)continue;!this.isCellEligibleToBeRemoved(c,r)?o.push([u,c]):c.destroy()}if(o.length)for(const[c,u]of o){const d=n.list.findIndex(f=>f.column.getLeft()>u.column.getLeft()),h=d===-1?void 0:Math.max(d-1,0);i(c,u,h)}const{focusSvc:s,visibleCols:a}=this.beans,l=s.getFocusedCell();if(l&&l.column.getPinned()==r){const c=l.column.getInstanceId();if(!n.map[c]&&a.allCols.includes(l.column)){const d=this.createFocusedCellCtrl();if(d){const h=n.list.findIndex(g=>g.column.getLeft()>d.column.getLeft()),f=h===-1?void 0:Math.max(h-1,0);i(c,d,f)}}}return n}createFocusedCellCtrl(){const{focusSvc:e,rowSpanSvc:t}=this.beans,r=e.getFocusedCell();if(!r)return;const n=t==null?void 0:t.getCellSpan(r.column,this.rowNode);if(n){if(n.firstNode!==this.rowNode||!n.doesSpanContain(r))return}else if(!e.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned))return;return this.getNewCellCtrl(r.column)}updateColumnListsImpl(e){this.updateColumnListsPending=!1,this.createAllCellCtrls(),this.setCellCtrls(e)}setCellCtrls(e){this.allRowGuis.forEach(t=>{const r=this.getCellCtrlsForContainer(t.containerType);t.rowComp.setCellCtrls(r,e)})}getCellCtrlsForContainer(e){switch(e){case"left":return this.leftCellCtrls.list;case"right":return this.rightCellCtrls.list;case"fullWidth":return[];case"center":return this.centerCellCtrls.list}}createAllCellCtrls(){const e=this.beans.colViewport,t=this.beans.visibleCols;if(this.printLayout)this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,t.allCols),this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}};else{const r=e.getColsWithinViewport(this.rowNode);this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,r);const n=t.getLeftColsForRow(this.rowNode);this.leftCellCtrls=this.createCellCtrls(this.leftCellCtrls,n,"left");const i=t.getRightColsForRow(this.rowNode);this.rightCellCtrls=this.createCellCtrls(this.rightCellCtrls,i,"right")}}isCellEligibleToBeRemoved(e,t){const{column:i}=e;if(i.getPinned()!=t||!this.isCorrectCtrlForSpan(e))return!0;const{editing:o}=e,{visibleCols:s}=this.beans,a=e.isCellFocused();return o||a?!(s.allCols.indexOf(i)>=0):!0}getDomOrder(){return this.gos.get("ensureDomOrder")||pt(this.gos,"print")}listenOnDomOrder(e){const t=()=>{e.rowComp.setDomOrder(this.getDomOrder())};e.compBean.addManagedPropertyListeners(["domLayout","ensureDomOrder"],t)}setAnimateFlags(e){if(this.rowNode.sticky||!e)return;const t=ie(this.rowNode.oldRowTop),{visibleCols:r}=this.beans,n=r.isPinningLeft(),i=r.isPinningRight();if(t){const{slideInAnimation:o}=this;if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows")){o.fullWidth=!0;return}o.center=!0,o.left=n,o.right=i}else{const{fadeInAnimation:o}=this;if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows")){o.fullWidth=!0;return}o.center=!0,o.left=n,o.right=i}}isFullWidth(){return this.rowType!=="Normal"}refreshFullWidth(){const e=(s,a)=>s?s.rowComp.refreshFullWidth(()=>this.createFullWidthCompDetails(s.element,a).params):!0,t=e(this.fullWidthGui,null),r=e(this.centerGui,null),n=e(this.leftGui,"left"),i=e(this.rightGui,"right");return t&&r&&n&&i}addListeners(){var e;this.addManagedListeners(this.rowNode,{heightChanged:()=>this.onRowHeightChanged(),rowSelected:()=>this.onRowSelected(),rowIndexChanged:this.onRowIndexChanged.bind(this),topChanged:this.onTopChanged.bind(this),...((e=this.beans.expansionSvc)==null?void 0:e.getRowExpandedListeners(this))??{}}),this.rowNode.detail&&this.addManagedListeners(this.rowNode.parent,{dataChanged:this.onRowNodeDataChanged.bind(this)}),this.addManagedListeners(this.rowNode,{dataChanged:this.onRowNodeDataChanged.bind(this),cellChanged:this.postProcessCss.bind(this),rowHighlightChanged:this.onRowNodeHighlightChanged.bind(this),draggingChanged:this.postProcessRowDragging.bind(this),uiLevelChanged:this.onUiLevelChanged.bind(this),rowPinned:this.onRowPinned.bind(this)}),this.addManagedListeners(this.beans.eventSvc,{paginationPixelOffsetChanged:this.onPaginationPixelOffsetChanged.bind(this),heightScaleChanged:this.onTopChanged.bind(this),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),virtualColumnsChanged:this.onVirtualColumnsChanged.bind(this),cellFocused:this.onCellFocusChanged.bind(this),cellFocusCleared:this.onCellFocusChanged.bind(this),paginationChanged:this.onPaginationChanged.bind(this),modelUpdated:this.refreshFirstAndLastRowStyles.bind(this),columnMoved:()=>this.updateColumnLists()}),this.beans.rowSpanSvc&&this.addManagedListeners(this.beans.rowSpanSvc,{spannedCellsUpdated:({pinned:t})=>{t&&!this.rowNode.rowPinned||this.updateColumnLists()}}),this.addDestroyFunc(()=>{this.rowDragComps=this.destroyBeans(this.rowDragComps,this.beans.context),this.tooltipFeature=this.destroyBean(this.tooltipFeature,this.beans.context)}),this.addManagedPropertyListeners(["rowStyle","getRowStyle","rowClass","getRowClass","rowClassRules"],this.postProcessCss.bind(this)),this.addManagedPropertyListener("rowDragEntireRow",()=>{if(this.gos.get("rowDragEntireRow")){this.allRowGuis.forEach(r=>{this.addRowDraggerToRow(r)});return}this.rowDragComps=this.destroyBeans(this.rowDragComps,this.beans.context)}),this.addListenersForCellComps()}addListenersForCellComps(){this.addManagedListeners(this.rowNode,{rowIndexChanged:()=>{this.getAllCellCtrls().forEach(e=>e.onRowIndexChanged())},cellChanged:e=>{this.getAllCellCtrls().forEach(t=>t.onCellChanged(e))}})}onRowPinned(){for(const e of this.allRowGuis)e.rowComp.toggleCss("ag-row-pinned-source",!!this.rowNode.pinnedSibling)}onRowNodeDataChanged(e){if(this.isFullWidth()!==!!this.isNodeFullWidthCell()){this.beans.rowRenderer.redrawRow(this.rowNode);return}if(this.isFullWidth()){this.refreshFullWidth()||this.beans.rowRenderer.redrawRow(this.rowNode);return}this.getAllCellCtrls().forEach(r=>r.refreshCell({suppressFlash:!e.update,newData:!e.update})),this.allRowGuis.forEach(r=>{this.setRowCompRowId(r.rowComp),this.updateRowBusinessKey(),this.setRowCompRowBusinessKey(r.rowComp)}),this.onRowSelected(),this.postProcessCss()}postProcessCss(){this.setStylesFromGridOptions(!0),this.postProcessClassesFromGridOptions(),this.postProcessRowClassRules(),this.postProcessRowDragging()}onRowNodeHighlightChanged(){const e=this.rowNode.highlighted;this.allRowGuis.forEach(t=>{const r=e==="Above",n=e==="Below";t.rowComp.toggleCss("ag-row-highlight-above",r),t.rowComp.toggleCss("ag-row-highlight-below",n)})}postProcessRowDragging(){const e=this.rowNode.dragging;this.allRowGuis.forEach(t=>t.rowComp.toggleCss("ag-row-dragging",e))}onDisplayedColumnsChanged(){var e;this.updateColumnLists(!0),(e=this.beans.rowAutoHeight)==null||e.requestCheckAutoHeight()}onVirtualColumnsChanged(){this.updateColumnLists(!1,!0)}getRowPosition(){return{rowPinned:on(this.rowNode.rowPinned),rowIndex:this.rowNode.rowIndex}}onKeyboardNavigate(e){const t=this.findFullWidthInfoForEvent(e);if(!t)return;const{rowGui:r,column:n}=t;if(!(r.element===e.target))return;const s=this.rowNode,{focusSvc:a,navigation:l}=this.beans,c=a.getFocusedCell(),u={rowIndex:s.rowIndex,rowPinned:s.rowPinned,column:(c==null?void 0:c.column)??n};l==null||l.navigateToNextCell(e,e.key,u,!0),e.preventDefault()}onTabKeyDown(e){var a;if(e.defaultPrevented||Lr(e))return;const t=this.allRowGuis.find(l=>l.element.contains(e.target)),r=t?t.element:null,n=r===e.target,i=Ke(this.beans);let o=!1;r&&i&&(o=r.contains(i)&&i.classList.contains("ag-cell"));let s=null;!n&&!o&&(s=yo(this.beans,r,!1,e.shiftKey)),(this.isFullWidth()&&n||!s)&&((a=this.beans.navigation)==null||a.onTabKeyDown(this,e))}getFullWidthElement(){return this.fullWidthGui?this.fullWidthGui.element:null}getRowYPosition(){var t;const e=(t=this.allRowGuis.find(r=>Sr(r.element)))==null?void 0:t.element;return e?e.getBoundingClientRect().top:0}onSuppressCellFocusChanged(e){const t=this.isFullWidth()&&e?void 0:-1;this.allRowGuis.forEach(r=>{Si(r.element,"tabindex",t)})}onFullWidthRowFocused(e){var i,o,s;const t=this.rowNode,r=e?this.isFullWidth()&&e.rowIndex===t.rowIndex&&e.rowPinned==t.rowPinned:!1;let n;if(this.fullWidthGui)n=this.fullWidthGui.element;else{const a=this.beans.colModel.getCol(e==null?void 0:e.column),l=a==null?void 0:a.pinned;l?n=l==="right"?(i=this.rightGui)==null?void 0:i.element:(o=this.leftGui)==null?void 0:o.element:n=(s=this.centerGui)==null?void 0:s.element}n&&(n.classList.toggle("ag-full-width-focus",r),r&&(e!=null&&e.forceBrowserFocus)&&n.focus({preventScroll:!0}))}recreateCell(e){this.centerCellCtrls=this.removeCellCtrl(this.centerCellCtrls,e),this.leftCellCtrls=this.removeCellCtrl(this.leftCellCtrls,e),this.rightCellCtrls=this.removeCellCtrl(this.rightCellCtrls,e),e.destroy(),this.updateColumnLists()}removeCellCtrl(e,t){const r={list:[],map:{}};return e.list.forEach(n=>{n!==t&&(r.list.push(n),r.map[n.column.getInstanceId()]=n)}),r}onMouseEvent(e,t){switch(e){case"dblclick":this.onRowDblClick(t);break;case"click":this.onRowClick(t);break;case"touchstart":case"mousedown":this.onRowMouseDown(t);break}}createRowEvent(e,t){const{rowNode:r}=this;return pe(this.gos,{type:e,node:r,data:r.data,rowIndex:r.rowIndex,rowPinned:r.rowPinned,event:t})}createRowEventWithSource(e,t){const r=this.createRowEvent(e,t);return r.source=this,r}onRowDblClick(e){Lr(e)||this.beans.eventSvc.dispatchEvent(this.createRowEventWithSource("rowDoubleClicked",e))}findFullWidthInfoForEvent(e){if(!e)return;const t=this.findFullWidthRowGui(e.target),r=this.getColumnForFullWidth(t);if(!(!t||!r))return{rowGui:t,column:r}}findFullWidthRowGui(e){return this.allRowGuis.find(t=>t.element.contains(e))}getColumnForFullWidth(e){const{visibleCols:t}=this.beans;switch(e==null?void 0:e.containerType){case"center":return t.centerCols[0];case"left":return t.leftCols[0];case"right":return t.rightCols[0];default:return t.allCols[0]}}onRowMouseDown(e){if(this.lastMouseDownOnDragger=kn(e.target,"ag-row-drag",3),!this.isFullWidth())return;const t=this.rowNode,{rangeSvc:r,focusSvc:n}=this.beans;r==null||r.removeAllCellRanges();const i=this.findFullWidthInfoForEvent(e);if(!i)return;const{rowGui:o,column:s}=i,a=o.element,l=e.target;let c=e.defaultPrevented||ep();a&&a.contains(l)&&tp(l)&&(c=!1),n.setFocusedCell({rowIndex:t.rowIndex,column:s,rowPinned:t.rowPinned,forceBrowserFocus:c})}onRowClick(e){if(Lr(e)||this.lastMouseDownOnDragger)return;const{eventSvc:r,selectionSvc:n}=this.beans;r.dispatchEvent(this.createRowEventWithSource("rowClicked",e)),n==null||n.handleSelectionEvent(e,this.rowNode,"rowClicked")}setupDetailRowAutoHeight(e){var t;this.rowType==="FullWidthDetail"&&((t=this.beans.masterDetailSvc)==null||t.setupDetailRowAutoHeight(this,e))}createFullWidthCompDetails(e,t){const{gos:r,rowNode:n}=this,i=pe(r,{fullWidth:!0,data:n.data,node:n,value:n.key,valueFormatted:n.key,eGridCell:e,eParentOfValue:e,pinned:t,addRenderedRowListener:this.addEventListener.bind(this),registerRowDragger:(s,a,l,c)=>this.addFullWidthRowDragging(s,a,l,c),setTooltip:(s,a)=>{r.assertModuleRegistered("Tooltip",3),this.refreshRowTooltip(s,a)}}),o=this.beans.userCompFactory;switch(this.rowType){case"FullWidthDetail":return E_(o,i);case"FullWidthGroup":{const{value:s,valueFormatted:a}=this.beans.valueSvc.getValueForDisplay(void 0,this.rowNode,!0);return i.value=s,i.valueFormatted=a,R_(o,i)}case"FullWidthLoading":return P_(o,i);default:return A_(o,i)}}refreshRowTooltip(e,t){var r;this.fullWidthGui&&(this.tooltipFeature=(r=this.beans.tooltipSvc)==null?void 0:r.refreshRowTooltip(this.tooltipFeature,this,e,t))}addFullWidthRowDragging(e,t,r="",n){const{rowDragSvc:i,context:o}=this.beans;if(!i||!this.isFullWidth())return;const s=i.createRowDragComp(()=>r,this.rowNode,void 0,e,t,n);this.createBean(s,o),this.addDestroyFunc(()=>{this.destroyBean(s,o)})}onUiLevelChanged(){const e=zv(this.rowNode);if(this.rowLevel!=e){const t="ag-row-level-"+e,r="ag-row-level-"+this.rowLevel;this.allRowGuis.forEach(n=>{n.rowComp.toggleCss(t,!0),n.rowComp.toggleCss(r,!1)})}this.rowLevel=e}isFirstRowOnPage(){return this.rowNode.rowIndex===this.beans.pageBounds.getFirstRow()}isLastRowOnPage(){return this.rowNode.rowIndex===this.beans.pageBounds.getLastRow()}refreshFirstAndLastRowStyles(){const e=this.isFirstRowOnPage(),t=this.isLastRowOnPage();this.firstRowOnPage!==e&&(this.firstRowOnPage=e,this.allRowGuis.forEach(r=>r.rowComp.toggleCss("ag-row-first",e))),this.lastRowOnPage!==t&&(this.lastRowOnPage=t,this.allRowGuis.forEach(r=>r.rowComp.toggleCss("ag-row-last",t)))}getAllCellCtrls(){return this.leftCellCtrls.list.length===0&&this.rightCellCtrls.list.length===0?this.centerCellCtrls.list:[...this.centerCellCtrls.list,...this.leftCellCtrls.list,...this.rightCellCtrls.list]}postProcessClassesFromGridOptions(){var t;const e=[];(t=this.beans.rowStyleSvc)==null||t.processClassesFromGridOptions(e,this.rowNode),e.length&&e.forEach(r=>{this.allRowGuis.forEach(n=>n.rowComp.toggleCss(r,!0))})}postProcessRowClassRules(){var e;(e=this.beans.rowStyleSvc)==null||e.processRowClassRules(this.rowNode,t=>{this.allRowGuis.forEach(r=>r.rowComp.toggleCss(t,!0))},t=>{this.allRowGuis.forEach(r=>r.rowComp.toggleCss(t,!1))})}setStylesFromGridOptions(e,t){e&&(this.rowStyles=this.processStylesFromGridOptions()),this.forEachGui(t,r=>r.rowComp.setUserStyles(this.rowStyles))}getPinnedForContainer(e){return e==="left"||e==="right"?e:null}getInitialRowClasses(e){var a,l;const t=this.getPinnedForContainer(e),r=this.isFullWidth(),{rowNode:n,beans:i}=this,o=[];o.push("ag-row"),o.push(this.rowFocused?"ag-row-focus":"ag-row-no-focus"),this.fadeInAnimation[e]&&o.push("ag-opacity-zero"),o.push(n.rowIndex%2===0?"ag-row-even":"ag-row-odd"),n.isRowPinned()&&(o.push("ag-row-pinned"),(a=i.pinnedRowModel)!=null&&a.isManual()&&o.push("ag-row-pinned-manual")),!n.isRowPinned()&&n.pinnedSibling&&o.push("ag-row-pinned-source"),n.isSelected()&&o.push("ag-row-selected"),n.footer&&o.push("ag-row-footer"),o.push("ag-row-level-"+this.rowLevel),n.stub&&o.push("ag-row-loading"),r&&o.push("ag-full-width-row"),(l=i.expansionSvc)==null||l.addExpandedCss(o,n),n.dragging&&o.push("ag-row-dragging");const{rowStyleSvc:s}=i;return s&&(s.processClassesFromGridOptions(o,n),s.preProcessRowClassRules(o,n)),o.push(this.printLayout?"ag-row-position-relative":"ag-row-position-absolute"),this.isFirstRowOnPage()&&o.push("ag-row-first"),this.isLastRowOnPage()&&o.push("ag-row-last"),r&&(t==="left"&&o.push("ag-cell-last-left-pinned"),t==="right"&&o.push("ag-cell-first-right-pinned")),o}processStylesFromGridOptions(){var e;return((e=this.beans.rowStyleSvc)==null?void 0:e.processStylesFromGridOptions(this.rowNode))??this.emptyStyle}onRowSelected(e){var t;(t=this.beans.selectionSvc)==null||t.onRowCtrlSelected(this,r=>{(r===this.centerGui||r===this.fullWidthGui)&&this.announceDescription()},e)}announceDescription(){var e;(e=this.beans.selectionSvc)==null||e.announceAriaRowSelection(this.rowNode)}addHoverFunctionality(e){if(!this.active)return;const{element:t,compBean:r}=e,{rowNode:n,beans:i,gos:o}=this;r.addManagedListeners(t,{mouseenter:()=>n.dispatchRowEvent("mouseEnter"),mouseleave:()=>n.dispatchRowEvent("mouseLeave")}),r.addManagedListeners(n,{mouseEnter:()=>{var s;!((s=i.dragSvc)!=null&&s.dragging)&&!o.get("suppressRowHoverHighlight")&&(t.classList.add("ag-row-hover"),n.setHovered(!0))},mouseLeave:()=>{this.resetHoveredStatus(t)}})}resetHoveredStatus(e){const t=e?[e]:this.allRowGuis.map(r=>r.element);for(const r of t)r.classList.remove("ag-row-hover");this.rowNode.setHovered(!1)}roundRowTopToBounds(e){const t=this.beans.ctrlsSvc.getScrollFeature().getApproximateVScollPosition(),r=this.applyPaginationOffset(t.top,!0)-100,n=this.applyPaginationOffset(t.bottom,!0)+100;return Math.min(Math.max(r,e),n)}forEachGui(e,t){e?t(e):this.allRowGuis.forEach(t)}isRowRendered(){return this.allRowGuis.length>0}onRowHeightChanged(e){if(this.rowNode.rowHeight==null)return;const t=this.rowNode.rowHeight,r=this.beans.environment.getDefaultRowHeight(),i=r1(this.gos)?Un(this.beans,this.rowNode).height:void 0,o=i?`${Math.min(r,i)-2}px`:void 0;this.forEachGui(e,s=>{s.element.style.height=`${t}px`,o&&s.element.style.setProperty("--ag-line-height",o)})}destroyFirstPass(e=!1){var n;this.active=!1;const{rowNode:t}=this;if(!e&&xi(this.gos)&&!t.sticky)if(t.rowTop!=null){const o=this.roundRowTopToBounds(t.rowTop);this.setRowTop(o)}else this.allRowGuis.forEach(o=>o.rowComp.toggleCss("ag-opacity-zero",!0));(n=this.fullWidthGui)!=null&&n.element.contains(Ke(this.beans))&&this.beans.focusSvc.attemptToRecoverFocus(),t.setHovered(!1);const r=this.createRowEvent("virtualRowRemoved");this.dispatchLocalEvent(r),this.beans.eventSvc.dispatchEvent(r),super.destroy()}destroySecondPass(){var t;this.allRowGuis.length=0,(t=this.beans.editSvc)==null||t.stopRowEditing(this);const e=r=>(r.list.forEach(n=>n.destroy()),{list:[],map:{}});this.centerCellCtrls=e(this.centerCellCtrls),this.leftCellCtrls=e(this.leftCellCtrls),this.rightCellCtrls=e(this.rightCellCtrls)}setFocusedClasses(e){this.forEachGui(e,t=>{t.rowComp.toggleCss("ag-row-focus",this.rowFocused),t.rowComp.toggleCss("ag-row-no-focus",!this.rowFocused)})}onCellFocusChanged(){const{focusSvc:e,editSvc:t}=this.beans,r=e.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned);r!==this.rowFocused&&(this.rowFocused=r,this.setFocusedClasses()),!r&&this.editing&&(t==null||t.stopRowEditing(this,!1))}onPaginationChanged(){var t;const e=((t=this.beans.pagination)==null?void 0:t.getCurrentPage())??0;this.paginationPage!==e&&(this.paginationPage=e,this.onTopChanged()),this.refreshFirstAndLastRowStyles()}onTopChanged(){this.setRowTop(this.rowNode.rowTop)}onPaginationPixelOffsetChanged(){this.onTopChanged()}applyPaginationOffset(e,t=!1){if(this.rowNode.isRowPinned()||this.rowNode.sticky)return e;const r=this.beans.pageBounds.getPixelOffset();return e+r*(t?1:-1)}setRowTop(e){if(!this.printLayout&&ie(e)){const t=this.applyPaginationOffset(e),i=`${this.rowNode.isRowPinned()||this.rowNode.sticky?t:this.beans.rowContainerHeight.getRealPixelPosition(t)}px`;this.setRowTopStyle(i)}}getInitialRowTop(e){return this.suppressRowTransform?this.getInitialRowTopShared(e):void 0}getInitialTransform(e){return this.suppressRowTransform?void 0:`translateY(${this.getInitialRowTopShared(e)})`}getInitialRowTopShared(e){if(this.printLayout)return"";const t=this.rowNode;let r;if(t.sticky)r=t.stickyRowTop;else{const n=this.slideInAnimation[e]?this.roundRowTopToBounds(t.oldRowTop):t.rowTop,i=this.applyPaginationOffset(n);r=t.isRowPinned()?i:this.beans.rowContainerHeight.getRealPixelPosition(i)}return r+"px"}setRowTopStyle(e){this.allRowGuis.forEach(t=>this.suppressRowTransform?t.rowComp.setTop(e):t.rowComp.setTransform(`translateY(${e})`))}getCellCtrl(e,t=!1){let r=null;return this.getAllCellCtrls().forEach(n=>{n.column==e&&(r=n)}),r!=null||t||this.getAllCellCtrls().forEach(n=>{n.getColSpanningList().indexOf(e)>=0&&(r=n)}),r}onRowIndexChanged(){this.rowNode.rowIndex!=null&&(this.onCellFocusChanged(),this.updateRowIndexes(),this.postProcessCss())}updateRowIndexes(e){var o,s;const t=this.rowNode.getRowIndexString();if(t===null)return;const r=(((o=this.beans.ctrlsSvc.getHeaderRowContainerCtrl())==null?void 0:o.getRowCount())??0)+(((s=this.beans.filterManager)==null?void 0:s.getHeaderRowCount())??0),n=this.rowNode.rowIndex%2===0,i=r+this.rowNode.rowIndex+1;this.forEachGui(e,a=>{a.rowComp.setRowIndex(t),a.rowComp.toggleCss("ag-row-even",n),a.rowComp.toggleCss("ag-row-odd",!n),Ik(a.element,i)})}};function U1(e){var r;return e.altKey||e.ctrlKey||e.metaKey?!1:((r=e.key)==null?void 0:r.length)===1}function Nv(e,t,r,n,i){const o=n?n.getColDef().suppressKeyboardEvent:void 0;if(!o)return!1;const s=pe(e,{event:t,editing:i,column:n,node:r,data:r.data,colDef:n.getColDef()});return!!(o&&o(s))}function zL(e){const{pinnedRowModel:t,rowModel:r}=e,[n,i]=[(t==null?void 0:t.isEmpty("top"))??!0,(t==null?void 0:t.isEmpty("bottom"))??!0],o=n?null:"top";let s,a;i?(s=null,a=r.getRowCount()-1):(s="bottom",a=(t==null?void 0:t.getPinnedBottomRowCount())??-1);const{visibleCols:l,rangeSvc:c}=e,u=l.allCols;!c||!(u!=null&&u.length)||c.setCellRange({rowStartIndex:0,rowStartPinned:o,rowEndIndex:a,rowEndPinned:s})}var NL=65,$L=67,HL=86,GL=68,WL=90,jL=89;function VL(e){const{keyCode:t}=e;let r;switch(t){case NL:r=j.A;break;case $L:r=j.C;break;case HL:r=j.V;break;case GL:r=j.D;break;case WL:r=j.Z;break;case jL:r=j.Y;break;default:r=e.code}return r}var UL=class extends q{constructor(e){super(),this.element=e}postConstruct(){var e;this.addKeyboardListeners(),this.addMouseListeners(),(e=this.beans.touchSvc)==null||e.mockRowContextMenu(this)}addKeyboardListeners(){const e="keydown",t=this.processKeyboardEvent.bind(this,e);this.addManagedElementListeners(this.element,{[e]:t})}addMouseListeners(){["dblclick","contextmenu","mouseover","mouseout","click",d1("touchstart")?"touchstart":"mousedown"].forEach(r=>{const n=this.processMouseEvent.bind(this,r);this.addManagedElementListeners(this.element,{[r]:n})})}processMouseEvent(e,t){var i;if(!Ms(this.gos,t)||Lr(t))return;const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);e==="contextmenu"?(r!=null&&r.column&&r.dispatchCellContextMenuEvent(t),(i=this.beans.contextMenuSvc)==null||i.handleContextMenuMouseEvent(t,void 0,n,r)):(r&&r.onMouseEvent(e,t),n&&n.onMouseEvent(e,t))}getControlsForEventTarget(e){const{gos:t}=this;return{cellCtrl:I1(t,e),rowCtrl:h1(t,e,Vl)}}processKeyboardEvent(e,t){const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);t.defaultPrevented||(r?this.processCellKeyboardEvent(r,e,t):n&&n.isFullWidth()&&this.processFullWidthRowKeyboardEvent(n,e,t))}processCellKeyboardEvent(e,t,r){var a;const{rowNode:n,column:i,editing:o}=e;!Nv(this.gos,r,n,i,o)&&t==="keydown"&&(!o&&((a=this.beans.navigation)!=null&&a.handlePageScrollingKey(r))||e.onKeyDown(r),this.doGridOperations(r,e.editing),U1(r)&&e.processCharacter(r)),t==="keydown"&&this.eventSvc.dispatchEvent(e.createEvent(r,"cellKeyDown"))}processFullWidthRowKeyboardEvent(e,t,r){const{rowNode:n}=e,{focusSvc:i,navigation:o}=this.beans,s=i.getFocusedCell(),a=s&&s.column;if(!Nv(this.gos,r,n,a,!1)){const c=r.key;if(t==="keydown")switch(c){case j.PAGE_HOME:case j.PAGE_END:case j.PAGE_UP:case j.PAGE_DOWN:o==null||o.handlePageScrollingKey(r,!0);break;case j.LEFT:case j.RIGHT:if(!this.gos.get("embedFullWidthRows"))break;case j.UP:case j.DOWN:e.onKeyboardNavigate(r);break;case j.TAB:e.onTabKeyDown(r);break}}t==="keydown"&&this.eventSvc.dispatchEvent(e.createRowEvent("cellKeyDown",r))}doGridOperations(e,t){if(!e.ctrlKey&&!e.metaKey||t||!Ms(this.gos,e))return;const r=VL(e),{clipboardSvc:n,undoRedo:i}=this.beans;if(r===j.A)return this.onCtrlAndA(e);if(r===j.C)return this.onCtrlAndC(n,e);if(r===j.D)return this.onCtrlAndD(n,e);if(r===j.V)return this.onCtrlAndV(n,e);if(r===j.X)return this.onCtrlAndX(n,e);if(r===j.Y)return this.onCtrlAndY(i);if(r===j.Z)return this.onCtrlAndZ(i,e)}onCtrlAndA(e){const{beans:{rowModel:t,rangeSvc:r,selectionSvc:n},gos:i}=this;r&&Es(i)&&t.isRowsToRender()?zL(this.beans):n&&(n==null||n.selectAllRowNodes({source:"keyboardSelectAll",selectAll:c1(i)})),e.preventDefault()}onCtrlAndC(e,t){if(!e||this.gos.get("enableCellTextSelection"))return;const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);r!=null&&r.editing||n!=null&&n.editing||(t.preventDefault(),e.copyToClipboard())}onCtrlAndX(e,t){if(!e||this.gos.get("enableCellTextSelection")||this.gos.get("suppressCutToClipboard"))return;const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);r!=null&&r.editing||n!=null&&n.editing||(t.preventDefault(),e.cutToClipboard(void 0,"ui"))}onCtrlAndV(e,t){const{cellCtrl:r,rowCtrl:n}=this.getControlsForEventTarget(t.target);r!=null&&r.editing||n!=null&&n.editing||e&&!this.gos.get("suppressClipboardPaste")&&e.pasteFromClipboard()}onCtrlAndD(e,t){e&&!this.gos.get("suppressClipboardPaste")&&e.copyRangeDown(),t.preventDefault()}onCtrlAndZ(e,t){!this.gos.get("undoRedoCellEditing")||!e||(t.preventDefault(),t.shiftKey?e.redo("ui"):e.undo("ui"))}onCtrlAndY(e){e==null||e.redo("ui")}},K1=class extends q{constructor(e,t){super(),this.eContainer=e,this.eViewport=t}postConstruct(){this.addManagedEventListeners({rowContainerHeightChanged:this.onHeightChanged.bind(this,this.beans.rowContainerHeight)})}onHeightChanged(e){const t=e.uiContainerHeight,r=t!=null?`${t}px`:"";this.eContainer.style.height=r,this.eViewport&&(this.eViewport.style.height=r)}},$a=e=>e.topRowCtrls,Ha=e=>e.getStickyTopRowCtrls(),Ga=e=>e.getStickyBottomRowCtrls(),Wa=e=>e.bottomRowCtrls,ja=e=>e.allRowCtrls,pd=e=>e.getCtrls("top"),md=e=>e.getCtrls("center"),vd=e=>e.getCtrls("bottom"),KL={center:{type:"center",name:"center-cols",getRowCtrls:ja,getSpannedRowCtrls:md},left:{type:"left",name:"pinned-left-cols",pinnedType:"left",getRowCtrls:ja,getSpannedRowCtrls:md},right:{type:"right",name:"pinned-right-cols",pinnedType:"right",getRowCtrls:ja,getSpannedRowCtrls:md},fullWidth:{type:"fullWidth",name:"full-width",fullWidth:!0,getRowCtrls:ja},topCenter:{type:"center",name:"floating-top",getRowCtrls:$a,getSpannedRowCtrls:pd},topLeft:{type:"left",name:"pinned-left-floating",container:"ag-pinned-left-floating-top",pinnedType:"left",getRowCtrls:$a,getSpannedRowCtrls:pd},topRight:{type:"right",name:"pinned-right-floating",container:"ag-pinned-right-floating-top",pinnedType:"right",getRowCtrls:$a,getSpannedRowCtrls:pd},topFullWidth:{type:"fullWidth",name:"floating-top-full-width",fullWidth:!0,getRowCtrls:$a},stickyTopCenter:{type:"center",name:"sticky-top",getRowCtrls:Ha},stickyTopLeft:{type:"left",name:"pinned-left-sticky-top",container:"ag-pinned-left-sticky-top",pinnedType:"left",getRowCtrls:Ha},stickyTopRight:{type:"right",name:"pinned-right-sticky-top",container:"ag-pinned-right-sticky-top",pinnedType:"right",getRowCtrls:Ha},stickyTopFullWidth:{type:"fullWidth",name:"sticky-top-full-width",fullWidth:!0,getRowCtrls:Ha},stickyBottomCenter:{type:"center",name:"sticky-bottom",getRowCtrls:Ga},stickyBottomLeft:{type:"left",name:"pinned-left-sticky-bottom",container:"ag-pinned-left-sticky-bottom",pinnedType:"left",getRowCtrls:Ga},stickyBottomRight:{type:"right",name:"pinned-right-sticky-bottom",container:"ag-pinned-right-sticky-bottom",pinnedType:"right",getRowCtrls:Ga},stickyBottomFullWidth:{type:"fullWidth",name:"sticky-bottom-full-width",fullWidth:!0,getRowCtrls:Ga},bottomCenter:{type:"center",name:"floating-bottom",getRowCtrls:Wa,getSpannedRowCtrls:vd},bottomLeft:{type:"left",name:"pinned-left-floating-bottom",container:"ag-pinned-left-floating-bottom",pinnedType:"left",getRowCtrls:Wa,getSpannedRowCtrls:vd},bottomRight:{type:"right",name:"pinned-right-floating-bottom",container:"ag-pinned-right-floating-bottom",pinnedType:"right",getRowCtrls:Wa,getSpannedRowCtrls:vd},bottomFullWidth:{type:"fullWidth",name:"floating-bottom-full-width",fullWidth:!0,getRowCtrls:Wa}};function q1(e){return`ag-${Ea(e).name}-viewport`}function bl(e){const t=Ea(e);return t.container??`ag-${t.name}-container`}function qL(e){return`ag-${Ea(e).name}-spanned-cells-container`}function Ea(e){return KL[e]}var YL=["topCenter","topLeft","topRight"],JL=["bottomCenter","bottomLeft","bottomRight"],XL=["center","left","right"],ZL=["center","left","right","fullWidth"],QL=["stickyTopCenter","stickyBottomCenter","center","topCenter","bottomCenter"],e3=["left","bottomLeft","topLeft","stickyTopLeft","stickyBottomLeft"],t3=["right","bottomRight","topRight","stickyTopRight","stickyBottomRight"],Y1=["stickyTopCenter","stickyTopLeft","stickyTopRight"],J1=["stickyBottomCenter","stickyBottomLeft","stickyBottomRight"],r3=[...Y1,"stickyTopFullWidth",...J1,"stickyBottomFullWidth"],n3=[...YL,...JL,...XL,...Y1,...J1],i3=class extends q{constructor(e){super(),this.name=e,this.visible=!0,this.EMPTY_CTRLS=[],this.options=Ea(e)}postConstruct(){this.enableRtl=this.gos.get("enableRtl"),this.forContainers(["center"],()=>{this.viewportSizeFeature=this.createManagedBean(new LL(this)),this.addManagedEventListeners({stickyTopOffsetChanged:this.onStickyTopOffsetChanged.bind(this)})})}onStickyTopOffsetChanged(e){this.comp.setOffsetTop(`${e.offset}px`)}registerWithCtrlsService(){this.options.fullWidth||this.beans.ctrlsSvc.register(this.name,this)}forContainers(e,t){e.indexOf(this.name)>=0&&t()}setComp(e,t,r,n){this.comp=e,this.eContainer=t,this.eSpannedContainer=r,this.eViewport=n,this.createManagedBean(new UL(this.eViewport??this.eContainer)),this.addPreventScrollWhileDragging(),this.listenOnDomOrder();const{pinnedCols:i,rangeSvc:o}=this.beans,s=()=>this.onPinnedWidthChanged();this.forContainers(e3,()=>{this.pinnedWidthFeature=this.createOptionalManagedBean(i==null?void 0:i.createPinnedWidthFeature(!0,this.eContainer,this.eSpannedContainer)),this.addManagedEventListeners({leftPinnedWidthChanged:s})}),this.forContainers(t3,()=>{this.pinnedWidthFeature=this.createOptionalManagedBean(i==null?void 0:i.createPinnedWidthFeature(!1,this.eContainer,this.eSpannedContainer)),this.addManagedEventListeners({rightPinnedWidthChanged:s})}),this.forContainers(ZL,()=>this.createManagedBean(new K1(this.eContainer,this.name==="center"?n:void 0))),o&&this.forContainers(n3,()=>this.createManagedBean(o.createDragListenerFeature(this.eContainer))),this.forContainers(QL,()=>this.createManagedBean(new pp(a=>this.comp.setContainerWidth(`${a}px`)))),this.visible=this.isContainerVisible(),this.addListeners(),this.registerWithCtrlsService()}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}addListeners(){const{spannedRowRenderer:e,gos:t}=this.beans,r=this.onDisplayedColumnsChanged.bind(this);this.addManagedEventListeners({displayedColumnsChanged:r,displayedColumnsWidthChanged:r,displayedRowsChanged:n=>this.onDisplayedRowsChanged(n.afterScroll)}),r(),this.onDisplayedRowsChanged(),e&&this.options.getSpannedRowCtrls&&t.get("enableCellSpan")&&this.addManagedListeners(e,{spannedRowsUpdated:()=>{const n=this.options.getSpannedRowCtrls(e);n&&this.comp.setSpannedRowCtrls(n,!1)}})}listenOnDomOrder(){if(r3.indexOf(this.name)>=0){this.comp.setDomOrder(!0);return}const t=()=>{const r=this.gos.get("ensureDomOrder"),n=pt(this.gos,"print");this.comp.setDomOrder(r||n)};this.addManagedPropertyListener("domLayout",t),t()}onDisplayedColumnsChanged(){this.forContainers(["center"],()=>this.onHorizontalViewportChanged())}addPreventScrollWhileDragging(){const{dragSvc:e}=this.beans;if(!e)return;const t=r=>{e.dragging&&r.cancelable&&r.preventDefault()};this.eContainer.addEventListener("touchmove",t,{passive:!1}),this.addDestroyFunc(()=>this.eContainer.removeEventListener("touchmove",t))}onHorizontalViewportChanged(e=!1){const t=this.getCenterWidth(),r=this.getCenterViewportScrollLeft();this.beans.colViewport.setScrollPosition(t,r,e)}hasHorizontalScrollGap(){return this.eContainer.clientWidth-this.eViewport.clientWidth<0}hasVerticalScrollGap(){return this.eContainer.clientHeight-this.eViewport.clientHeight<0}getCenterWidth(){return As(this.eViewport)}getCenterViewportScrollLeft(){return Fl(this.eViewport,this.enableRtl)}registerViewportResizeListener(e){const t=fn(this.beans,this.eViewport,e);this.addDestroyFunc(()=>t())}isViewportInTheDOMTree(){return K2(this.eViewport)}getViewportScrollLeft(){return Fl(this.eViewport,this.enableRtl)}isHorizontalScrollShowing(){return this.gos.get("alwaysShowHorizontalScroll")||jk(this.eViewport)}setHorizontalScroll(e){this.comp.setHorizontalScroll(e)}getHScrollPosition(){return{left:this.eViewport.scrollLeft,right:this.eViewport.scrollLeft+this.eViewport.offsetWidth}}setCenterViewportScrollLeft(e){Ol(this.eViewport,e,this.enableRtl)}isContainerVisible(){return!(this.options.pinnedType!=null)||!!this.pinnedWidthFeature&&this.pinnedWidthFeature.getWidth()>0}onPinnedWidthChanged(){const e=this.isContainerVisible();this.visible!=e&&(this.visible=e,this.onDisplayedRowsChanged())}onDisplayedRowsChanged(e=!1){const t=this.options.getRowCtrls(this.beans.rowRenderer);if(!this.visible||t.length===0){this.comp.setRowCtrls({rowCtrls:this.EMPTY_CTRLS});return}const r=pt(this.gos,"print"),i=this.gos.get("embedFullWidthRows")||r,o=t.filter(s=>{const a=s.isFullWidth();return this.options.fullWidth?!i&&a:i||!a});this.comp.setRowCtrls({rowCtrls:o,useFlushSync:e})}},o3="ag-force-vertical-scroll",s3="ag-selectable",a3="ag-column-moving",l3=class extends q{constructor(){super(...arguments),this.stickyTopHeight=0,this.stickyBottomHeight=0}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.colModel=e.colModel,this.scrollVisibleSvc=e.scrollVisibleSvc,this.pinnedRowModel=e.pinnedRowModel,this.filterManager=e.filterManager,this.rowGroupColsSvc=e.rowGroupColsSvc}setComp(e,t,r,n,i,o,s){var a,l;this.comp=e,this.eGridBody=t,this.eBodyViewport=r,this.eTop=n,this.eBottom=i,this.eStickyTop=o,this.eStickyBottom=s,this.eCenterColsViewport=r.querySelector(`.${q1("center")}`),this.eFullWidthContainer=r.querySelector(`.${bl("fullWidth")}`),this.eStickyTopFullWidthContainer=o.querySelector(`.${bl("stickyTopFullWidth")}`),this.eStickyBottomFullWidthContainer=s.querySelector(`.${bl("stickyBottomFullWidth")}`),this.setCellTextSelection(this.gos.get("enableCellTextSelection")),this.addManagedPropertyListener("enableCellTextSelection",c=>this.setCellTextSelection(c.currentValue)),this.createManagedBean(new gp(this.comp)),this.scrollFeature=this.createManagedBean(new _L(r)),(a=this.beans.rowDragSvc)==null||a.setupRowDrag(r,this),this.setupRowAnimationCssClass(),this.addEventListeners(),this.addFocusListeners([n,r,i,o,s]),this.setGridRootRole(),this.onGridColumnsChanged(),this.addBodyViewportListener(),this.setFloatingHeights(),this.disableBrowserDragging(),this.addStopEditingWhenGridLosesFocus(),this.updateScrollingClasses(),(l=this.filterManager)==null||l.setupAdvFilterHeaderComp(n),this.ctrlsSvc.register("gridBodyCtrl",this)}addEventListeners(){const e=this.setFloatingHeights.bind(this),t=this.setGridRootRole.bind(this),r=this.toggleRowResizeStyles.bind(this);this.addManagedEventListeners({gridColumnsChanged:this.onGridColumnsChanged.bind(this),scrollVisibilityChanged:this.onScrollVisibilityChanged.bind(this),scrollGapChanged:this.updateScrollingClasses.bind(this),pinnedRowDataChanged:e,pinnedHeightChanged:e,pinnedRowsChanged:e,headerHeightChanged:this.setStickyTopOffsetTop.bind(this),columnRowGroupChanged:t,columnPivotChanged:t,rowResizeStarted:r,rowResizeEnded:r}),this.addManagedPropertyListener("treeData",t)}toggleRowResizeStyles(e){const t=e.type==="rowResizeStarted";this.eBodyViewport.classList.toggle("ag-prevent-animation",t)}onGridColumnsChanged(){const e=this.beans.colModel.getCols();this.comp.setColumnCount(e.length)}onScrollVisibilityChanged(){const{scrollVisibleSvc:e}=this,t=e.verticalScrollShowing;this.setVerticalScrollPaddingVisible(t),this.setStickyWidth(t),this.setStickyBottomOffsetBottom();const r=t&&e.getScrollbarWidth()||0,n=W2()?16:0,i=`calc(100% + ${r+n}px)`;Ur(this.beans,()=>this.comp.setBodyViewportWidth(i)),this.updateScrollingClasses()}setGridRootRole(){const{rowGroupColsSvc:e,colModel:t}=this;let r=this.gos.get("treeData");if(!r){const n=t.isPivotMode();r=(e?e.columns.length:0)>=(n?2:1)}this.comp.setGridRootRole(r?"treegrid":"grid")}addFocusListeners(e){e.forEach(t=>{this.addManagedElementListeners(t,{focusin:r=>{const{target:n}=r,i=kn(n,"ag-root",t);t.classList.toggle("ag-has-focus",!i)},focusout:r=>{const{target:n,relatedTarget:i}=r,o=t.contains(i),s=kn(i,"ag-root",t);kn(n,"ag-root",t)||(!o||s)&&t.classList.remove("ag-has-focus")}})})}setColumnMovingCss(e){this.comp.setColumnMovingCss(a3,e)}setCellTextSelection(e=!1){this.comp.setCellSelectableCss(s3,e)}updateScrollingClasses(){const{eGridBody:{classList:e},scrollVisibleSvc:t}=this;e.toggle("ag-body-vertical-content-no-gap",!t.verticalScrollGap),e.toggle("ag-body-horizontal-content-no-gap",!t.horizontalScrollGap)}disableBrowserDragging(){this.addManagedElementListeners(this.eGridBody,{dragstart:e=>{if(e.target instanceof HTMLImageElement)return e.preventDefault(),!1}})}addStopEditingWhenGridLosesFocus(){var e;(e=this.beans.editSvc)==null||e.addStopEditingWhenGridLosesFocus([this.eBodyViewport,this.eBottom,this.eTop,this.eStickyTop,this.eStickyBottom])}updateRowCount(){var i,o;const e=(((i=this.ctrlsSvc.getHeaderRowContainerCtrl())==null?void 0:i.getRowCount())??0)+(((o=this.filterManager)==null?void 0:o.getHeaderRowCount())??0),{rowModel:t}=this.beans,r=t.isLastRowIndexKnown()?t.getRowCount():-1,n=r===-1?-1:e+r;this.comp.setRowCount(n)}registerBodyViewportResizeListener(e){this.comp.registerBodyViewportResizeListener(e)}setVerticalScrollPaddingVisible(e){const t=e?"scroll":"hidden";this.comp.setPinnedTopBottomOverflowY(t)}isVerticalScrollShowing(){const e=this.gos.get("alwaysShowVerticalScroll"),t=e?o3:null,r=pt(this.gos,"normal");return this.comp.setAlwaysVerticalScrollClass(t,e),e||r&&Vk(this.eBodyViewport)}setupRowAnimationCssClass(){const{rowContainerHeight:e,environment:t}=this.beans;let r=t.sizesMeasured;const n=()=>{const i=r&&xi(this.gos)&&!e.stretching,o=i?"ag-row-animation":"ag-row-no-animation";this.comp.setRowAnimationCssOnBodyViewport(o,i)};n(),this.addManagedEventListeners({heightScaleChanged:n}),this.addManagedPropertyListener("animateRows",n),this.addManagedEventListeners({gridStylesChanged:()=>{!r&&t.sizesMeasured&&(r=!0,n())}})}addBodyViewportListener(){const{eBodyViewport:e,eStickyTop:t,eStickyBottom:r,eTop:n,eBottom:i,beans:{popupSvc:o,touchSvc:s}}=this,a=this.onBodyViewportContextMenu.bind(this);this.addManagedElementListeners(e,{contextmenu:a}),s==null||s.mockBodyContextMenu(this,a),this.addManagedElementListeners(e,{wheel:this.onBodyViewportWheel.bind(this,o)});const l=this.onStickyWheel.bind(this);for(const u of[t,r,n,i])this.addManagedElementListeners(u,{wheel:l});const c=this.onHorizontalWheel.bind(this);for(const u of["left","right","topLeft","topRight","bottomLeft","bottomRight"])this.addManagedElementListeners(this.ctrlsSvc.get(u).eContainer,{wheel:c});this.addFullWidthContainerWheelListener()}addFullWidthContainerWheelListener(){this.addManagedElementListeners(this.eFullWidthContainer,{wheel:e=>this.onFullWidthContainerWheel(e)})}onFullWidthContainerWheel(e){const{deltaX:t,deltaY:r,shiftKey:n}=e;(n||Math.abs(t)>Math.abs(r))&&Ms(this.gos,e)&&this.scrollGridBodyToMatchEvent(e)}onStickyWheel(e){const{deltaY:t}=e;e.preventDefault(),this.scrollVertically(t)}onHorizontalWheel(e){const{deltaX:t,deltaY:r,shiftKey:n}=e;(n||Math.abs(t)>Math.abs(r))&&this.scrollGridBodyToMatchEvent(e)}scrollGridBodyToMatchEvent(e){const{deltaX:t,deltaY:r}=e;e.preventDefault(),this.eCenterColsViewport.scrollBy({left:t||r})}onBodyViewportContextMenu(e,t,r){var i;if(!e&&!r)return;this.gos.get("preventDefaultOnContextMenu")&&(e||r).preventDefault();const{target:n}=e||t;(n===this.eBodyViewport||n===this.ctrlsSvc.get("center").eViewport)&&((i=this.beans.contextMenuSvc)==null||i.showContextMenu({mouseEvent:e,touchEvent:r,value:null,anchorToElement:this.eGridBody,source:"ui"}))}onBodyViewportWheel(e,t){this.gos.get("suppressScrollWhenPopupsAreOpen")&&e!=null&&e.hasAnchoredPopup()&&t.preventDefault()}scrollVertically(e){const t=this.eBodyViewport.scrollTop;return this.scrollFeature.setVerticalScrollPosition(t+e),this.eBodyViewport.scrollTop-t}setFloatingHeights(){const{pinnedRowModel:e,beans:{environment:t}}=this,r=e==null?void 0:e.getPinnedTopTotalHeight(),n=e==null?void 0:e.getPinnedBottomTotalHeight(),i=t.getPinnedRowBorderWidth(),o=t.getRowBorderWidth(),s=i-o,a=r?s+r:0,l=n?s+n:0;this.comp.setTopHeight(a),this.comp.setBottomHeight(l),this.comp.setTopInvisible(a<=0),this.comp.setBottomInvisible(l<=0),this.setStickyTopOffsetTop(),this.setStickyBottomOffsetBottom()}setStickyTopHeight(e=0){this.comp.setStickyTopHeight(`${e}px`),this.stickyTopHeight=e}setStickyBottomHeight(e=0){this.comp.setStickyBottomHeight(`${e}px`),this.stickyBottomHeight=e}setStickyWidth(e){if(!e)this.comp.setStickyTopWidth("100%"),this.comp.setStickyBottomWidth("100%");else{const t=this.scrollVisibleSvc.getScrollbarWidth();this.comp.setStickyTopWidth(`calc(100% - ${t}px)`),this.comp.setStickyBottomWidth(`calc(100% - ${t}px)`)}}setStickyTopOffsetTop(){var i,o;const t=this.ctrlsSvc.get("gridHeaderCtrl").headerHeight+(((i=this.filterManager)==null?void 0:i.getHeaderHeight())??0),r=((o=this.pinnedRowModel)==null?void 0:o.getPinnedTopTotalHeight())??0;let n=0;t>0&&(n+=t),r>0&&(n+=r),n>0&&(n+=1),this.comp.setStickyTopTop(`${n}px`)}setStickyBottomOffsetBottom(){const{pinnedRowModel:e,scrollVisibleSvc:t,comp:r}=this,n=(e==null?void 0:e.getPinnedBottomTotalHeight())??0,o=t.horizontalScrollShowing&&t.getScrollbarWidth()||0,s=n+o;r.setStickyBottomBottom(`${s}px`)}},X1=class extends ct{constructor(e,t){super(),this.direction=t,this.eViewport=fe,this.eContainer=fe,this.hideTimeout=0,this.setTemplate(e)}postConstruct(){this.addManagedEventListeners({scrollVisibilityChanged:this.onScrollVisibilityChanged.bind(this)}),this.onScrollVisibilityChanged(),this.toggleCss("ag-apple-scrollbar",H2()||Dn())}destroy(){super.destroy(),window.clearTimeout(this.hideTimeout)}initialiseInvisibleScrollbar(){this.invisibleScrollbar===void 0&&(this.invisibleScrollbar=W2(),this.invisibleScrollbar&&(this.hideAndShowInvisibleScrollAsNeeded(),this.addActiveListenerToggles()))}addActiveListenerToggles(){const e=this.getGui(),t=()=>this.toggleCss("ag-scrollbar-active",!0),r=()=>this.toggleCss("ag-scrollbar-active",!1);this.addManagedListeners(e,{mouseenter:t,mousedown:t,touchstart:t,mouseleave:r,touchend:r})}onScrollVisibilityChanged(){this.invisibleScrollbar===void 0&&this.initialiseInvisibleScrollbar(),Ur(this.beans,()=>this.setScrollVisible())}hideAndShowInvisibleScrollAsNeeded(){this.addManagedEventListeners({bodyScroll:e=>{e.direction===this.direction&&(this.hideTimeout&&(window.clearTimeout(this.hideTimeout),this.hideTimeout=0),this.toggleCss("ag-scrollbar-scrolling",!0))},bodyScrollEnd:()=>{this.hideTimeout=window.setTimeout(()=>{this.toggleCss("ag-scrollbar-scrolling",!1),this.hideTimeout=0},400)}})}attemptSettingScrollPosition(e){const t=this.eViewport;Yk(()=>Sr(t),()=>this.setScrollPosition(e),100)}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}},c3={tag:"div",cls:"ag-body-horizontal-scroll",attrs:{"aria-hidden":"true"},children:[{tag:"div",ref:"eLeftSpacer",cls:"ag-horizontal-left-spacer"},{tag:"div",ref:"eViewport",cls:"ag-body-horizontal-scroll-viewport",children:[{tag:"div",ref:"eContainer",cls:"ag-body-horizontal-scroll-container"}]},{tag:"div",ref:"eRightSpacer",cls:"ag-horizontal-right-spacer"}]},u3=class extends X1{constructor(){super(c3,"horizontal"),this.eLeftSpacer=fe,this.eRightSpacer=fe,this.setScrollVisibleDebounce=0}wireBeans(e){this.visibleCols=e.visibleCols,this.scrollVisibleSvc=e.scrollVisibleSvc}postConstruct(){super.postConstruct();const e=this.setFakeHScrollSpacerWidths.bind(this);this.addManagedEventListeners({displayedColumnsChanged:e,displayedColumnsWidthChanged:e,pinnedRowDataChanged:this.refreshCompBottom.bind(this)}),this.addManagedPropertyListener("domLayout",e),this.beans.ctrlsSvc.register("fakeHScrollComp",this),this.createManagedBean(new pp(t=>this.eContainer.style.width=`${t}px`)),this.addManagedPropertyListeners(["suppressHorizontalScroll"],this.onScrollVisibilityChanged.bind(this))}destroy(){window.clearTimeout(this.setScrollVisibleDebounce),super.destroy()}initialiseInvisibleScrollbar(){this.invisibleScrollbar===void 0&&(this.enableRtl=this.gos.get("enableRtl"),super.initialiseInvisibleScrollbar(),this.invisibleScrollbar&&this.refreshCompBottom())}refreshCompBottom(){var t;if(!this.invisibleScrollbar)return;const e=((t=this.beans.pinnedRowModel)==null?void 0:t.getPinnedBottomTotalHeight())??0;this.getGui().style.bottom=`${e}px`}onScrollVisibilityChanged(){super.onScrollVisibilityChanged(),this.setFakeHScrollSpacerWidths()}setFakeHScrollSpacerWidths(){const e=this.scrollVisibleSvc.verticalScrollShowing;let t=this.visibleCols.getDisplayedColumnsRightWidth();const r=!this.enableRtl&&e,n=this.scrollVisibleSvc.getScrollbarWidth();r&&(t+=n),yr(this.eRightSpacer,t),this.eRightSpacer.classList.toggle("ag-scroller-corner",t<=n);let i=this.visibleCols.getColsLeftWidth();this.enableRtl&&e&&(i+=n),yr(this.eLeftSpacer,i),this.eLeftSpacer.classList.toggle("ag-scroller-corner",i<=n)}setScrollVisible(){const e=this.scrollVisibleSvc.horizontalScrollShowing,t=this.invisibleScrollbar,r=this.gos.get("suppressHorizontalScroll"),n=e&&this.scrollVisibleSvc.getScrollbarWidth()||0,o=r?0:n===0&&t?16:n,s=()=>{this.setScrollVisibleDebounce=0,this.toggleCss("ag-scrollbar-invisible",t),os(this.getGui(),o),os(this.eViewport,o),os(this.eContainer,o),o||this.eContainer.style.setProperty("min-height","1px"),this.setVisible(e,{skipAriaHidden:!0})};window.clearTimeout(this.setScrollVisibleDebounce),e?this.setScrollVisibleDebounce=window.setTimeout(s,100):s()}getScrollPosition(){return Fl(this.eViewport,this.enableRtl)}setScrollPosition(e){Sr(this.eViewport)||this.attemptSettingScrollPosition(e),Ol(this.eViewport,e,this.enableRtl)}},d3={tag:"div",cls:"ag-body-vertical-scroll",attrs:{"aria-hidden":"true"},children:[{tag:"div",ref:"eViewport",cls:"ag-body-vertical-scroll-viewport",children:[{tag:"div",ref:"eContainer",cls:"ag-body-vertical-scroll-container"}]}]},h3=class extends X1{constructor(){super(d3,"vertical")}postConstruct(){super.postConstruct(),this.createManagedBean(new K1(this.eContainer));const{ctrlsSvc:e}=this.beans;e.register("fakeVScrollComp",this),this.addManagedEventListeners({rowContainerHeightChanged:this.onRowContainerHeightChanged.bind(this,e)})}setScrollVisible(){const{scrollVisibleSvc:e}=this.beans,t=e.verticalScrollShowing,r=this.invisibleScrollbar,n=t&&e.getScrollbarWidth()||0,i=n===0&&r?16:n;this.toggleCss("ag-scrollbar-invisible",r),yr(this.getGui(),i),yr(this.eViewport,i),yr(this.eContainer,i),this.setDisplayed(t,{skipAriaHidden:!0})}onRowContainerHeightChanged(e){const r=e.getGridBodyCtrl().eBodyViewport,n=this.getScrollPosition(),i=r.scrollTop;n!=i&&this.setScrollPosition(i,!0)}getScrollPosition(){return this.eViewport.scrollTop}setScrollPosition(e,t){!t&&!Sr(this.eViewport)&&this.attemptSettingScrollPosition(e),this.eViewport.scrollTop=e}};function f3(e){return e.cols?e.cols.treeDepth+1:-1}function pr(e){var t;return((t=e.ctrlsSvc.getHeaderRowContainerCtrl())==null?void 0:t.getRowCount())??0}function mp(e){const t=[],r=e.ctrlsSvc.getHeaderRowContainerCtrls();for(const n of r){if(!n)continue;const i=n.getGroupRowCount()||0;for(let o=0;o<i;o++){const s=n.getGroupRowCtrlAtIndex(o),a=t[o];if(s){const l=g3(e,s);(a==null||l>a)&&(t[o]=l)}}}return t}function g3(e,t){let n=e.colModel.isPivotMode()?m3(e):Q1(e);const i=t.getHeaderCellCtrls();for(const o of i){const{column:s}=o,a=s.getAutoHeaderHeight();a!=null&&a>n&&s.isAutoHeaderHeight()&&(n=a)}return n}function vp(e){let r=e.colModel.isPivotMode()?p3(e):du(e);return e.colModel.forAllCols(n=>{const i=n.getAutoHeaderHeight();i!=null&&i>r&&n.isAutoHeaderHeight()&&(r=i)}),r}function du(e){return e.gos.get("headerHeight")??e.environment.getDefaultHeaderHeight()}function Z1(e){return e.gos.get("floatingFiltersHeight")??du(e)}function Q1(e){return e.gos.get("groupHeaderHeight")??du(e)}function p3(e){return e.gos.get("pivotHeaderHeight")??du(e)}function m3(e){return e.gos.get("pivotGroupHeaderHeight")??Q1(e)}var v3=class extends q{setComp(e,t,r){this.comp=e,this.eGui=t;const{beans:n}=this,{headerNavigation:i,touchSvc:o,ctrlsSvc:s}=n;i&&this.createManagedBean(new bo(r,{onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addManagedEventListeners({columnPivotModeChanged:this.onPivotModeChanged.bind(this,n),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this,n)}),this.onPivotModeChanged(n),this.setupHeaderHeight();const a=this.onHeaderContextMenu.bind(this);this.addManagedElementListeners(this.eGui,{contextmenu:a}),o==null||o.mockHeaderContextMenu(this,a),s.register("gridHeaderCtrl",this)}setupHeaderHeight(){const e=this.setHeaderHeight.bind(this);e(),this.addManagedPropertyListeners(["headerHeight","pivotHeaderHeight","groupHeaderHeight","pivotGroupHeaderHeight","floatingFiltersHeight"],e),this.addManagedEventListeners({displayedColumnsChanged:e,columnHeaderHeightChanged:e,columnGroupHeaderHeightChanged:()=>Ur(this.beans,()=>e()),gridStylesChanged:e,advancedFilterEnabledChanged:e})}setHeaderHeight(){var o;const{beans:e}=this;let t=0;const r=mp(e).reduce((s,a)=>s+a,0),n=vp(e);if((o=e.filterManager)!=null&&o.hasFloatingFilters()&&(t+=Z1(e)),t+=r,t+=n,this.headerHeight===t)return;this.headerHeight=t;const i=`${t+1}px`;this.comp.setHeightAndMinHeight(i),this.eventSvc.dispatchEvent({type:"headerHeightChanged"})}onPivotModeChanged(e){const t=e.colModel.isPivotMode();this.comp.toggleCss("ag-pivot-on",t),this.comp.toggleCss("ag-pivot-off",!t)}onDisplayedColumnsChanged(e){const r=e.visibleCols.allCols.some(n=>n.isSpanHeaderHeight());this.comp.toggleCss("ag-header-allow-overflow",r)}onTabKeyDown(e){const t=this.gos.get("enableRtl"),r=e.shiftKey,n=r!==t?"LEFT":"RIGHT",{beans:i}=this,{headerNavigation:o,focusSvc:s}=i;(o.navigateHorizontally(n,!0,e)||!r&&s.focusOverlay(!1)||Os(i,r,!0))&&e.preventDefault()}handleKeyDown(e){let t=null;const{headerNavigation:r}=this.beans;switch(e.key){case j.LEFT:t="LEFT";case j.RIGHT:{ie(t)||(t="RIGHT"),r.navigateHorizontally(t,!1,e)&&e.preventDefault();break}case j.UP:t="UP";case j.DOWN:{ie(t)||(t="DOWN"),r.navigateVertically(t,null,e)&&e.preventDefault();break}default:return}}onFocusOut(e){const{relatedTarget:t}=e,{eGui:r,beans:n}=this;!t&&r.contains(Ke(n))||r.contains(t)||(n.focusSvc.focusedHeader=null)}onHeaderContextMenu(e,t,r){var s;const{menuSvc:n,ctrlsSvc:i}=this.beans;if(!e&&!r||!(n!=null&&n.isHeaderContextMenuEnabled()))return;const{target:o}=e??t;(o===this.eGui||o===((s=i.getHeaderRowContainerCtrl())==null?void 0:s.eViewport))&&n.showHeaderContextMenu(void 0,e,r)}},yp=class extends q{constructor(e,t,r,n){super(),this.columnOrGroup=e,this.eCell=t,this.colsSpanning=n,this.columnOrGroup=e,this.ariaEl=t.querySelector("[role=columnheader]")||t,this.beans=r}setColsSpanning(e){this.colsSpanning=e,this.onLeftChanged()}getColumnOrGroup(){const{beans:e,colsSpanning:t}=this;return e.gos.get("enableRtl")&&t?Ee(t):this.columnOrGroup}postConstruct(){const e=this.onLeftChanged.bind(this);this.addManagedListeners(this.columnOrGroup,{leftChanged:e}),this.setLeftFirstTime(),this.addManagedEventListeners({displayedColumnsWidthChanged:e}),this.addManagedPropertyListener("domLayout",e)}setLeftFirstTime(){const{gos:e,colAnimation:t}=this.beans,r=e.get("suppressColumnMoveAnimation"),n=ie(this.columnOrGroup.getOldLeft());(t==null?void 0:t.isActive())&&n&&!r?this.animateInLeft():this.onLeftChanged()}animateInLeft(){const e=this.getColumnOrGroup(),t=this.modifyLeftForPrintLayout(e,e.getOldLeft()),r=this.modifyLeftForPrintLayout(e,e.getLeft());this.setLeft(t),this.actualLeft=r,this.beans.colAnimation.executeNextVMTurn(()=>{this.actualLeft===r&&this.setLeft(r)})}onLeftChanged(){const e=this.getColumnOrGroup(),t=e.getLeft();this.actualLeft=this.modifyLeftForPrintLayout(e,t),this.setLeft(this.actualLeft)}modifyLeftForPrintLayout(e,t){const{gos:r,visibleCols:n}=this.beans;if(!pt(r,"print")||e.getPinned()==="left")return t;const o=n.getColsLeftWidth();if(e.getPinned()==="right"){const s=n.bodyWidth;return o+s+t}return o+t}setLeft(e){if(ie(e)&&(this.eCell.style.left=`${e}px`),je(this.columnOrGroup)){const t=this.columnOrGroup.getLeafColumns();if(!t.length)return;t.length>1&&Lk(this.ariaEl,t.length)}}},y3=0,eS="headerCtrl",bp=class extends q{constructor(e,t){super(),this.column=e,this.rowCtrl=t,this.resizeToggleTimeout=0,this.resizeMultiplier=1,this.resizeFeature=null,this.lastFocusEvent=null,this.dragSource=null,this.instanceId=e.getUniqueId()+"-"+y3++}postConstruct(){const e=this.refreshTabIndex.bind(this);this.addManagedPropertyListeners(["suppressHeaderFocus"],e),this.addManagedEventListeners({overlayExclusiveChanged:e})}shouldStopEventPropagation(e){const{headerRowIndex:t,column:r}=this.beans.focusSvc.focusedHeader,n=r.getDefinition(),i=n&&n.suppressHeaderKeyboardEvent;if(!ie(i))return!1;const o=pe(this.gos,{colDef:n,column:r,headerRowIndex:t,event:e});return!!i(o)}getWrapperHasFocus(){return Ke(this.beans)===this.eGui}setGui(e,t){this.eGui=e,this.addDomData(t),t.addManagedListeners(this.beans.eventSvc,{displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this)}),t.addManagedElementListeners(this.eGui,{focus:this.onGuiFocus.bind(this)}),this.onDisplayedColumnsChanged(),this.refreshTabIndex()}refreshHeaderStyles(){const e=this.column.getDefinition();if(!e)return;const{headerStyle:t}=e;let r;if(typeof t=="function"){const n=this.getHeaderClassParams();r=t(n)}else r=t;r&&this.comp.setUserStyles(r)}onGuiFocus(){this.eventSvc.dispatchEvent({type:"headerFocused",column:this.column})}setupAutoHeight(e){const{wrapperElement:t,checkMeasuringCallback:r,compBean:n}=e,{beans:i}=this,o=d=>{if(!this.isAlive()||!n.isAlive())return;const{paddingTop:h,paddingBottom:f,borderBottomWidth:g,borderTopWidth:m}=go(this.eGui),p=h+f+g+m,w=t.offsetHeight+p;if(d<5){const b=gt(i),x=!b||!b.contains(t),C=w==0;if(x||C){Fh(()=>o(d+1),"raf",i);return}}this.setColHeaderHeight(this.column,w)};let s=!1,a;const l=()=>{const d=this.column.isAutoHeaderHeight();d&&!s&&c(),!d&&s&&u()},c=()=>{s=!0,o(0),this.comp.toggleCss("ag-header-cell-auto-height",!0),a=fn(this.beans,t,()=>o(0))},u=()=>{s=!1,a&&a(),this.comp.toggleCss("ag-header-cell-auto-height",!1),a=void 0};l(),n.addDestroyFunc(()=>u()),n.addManagedListeners(this.column,{widthChanged:()=>s&&o(0)}),n.addManagedEventListeners({sortChanged:()=>{s&&window.setTimeout(()=>o(0))}}),r&&r(l)}onDisplayedColumnsChanged(){const{comp:e,column:t,beans:r,eGui:n}=this;!e||!t||!n||(D1(e,t,r.visibleCols),z2(n,r.visibleCols.getAriaColIndex(t)))}addResizeAndMoveKeyboardListeners(e){e.addManagedListeners(this.eGui,{keydown:this.onGuiKeyDown.bind(this),keyup:this.onGuiKeyUp.bind(this)})}refreshTabIndex(){const e=Ln(this.beans);this.eGui&&Si(this.eGui,"tabindex",e?null:"-1")}onGuiKeyDown(e){var o;const t=Ke(this.beans),r=e.key===j.LEFT||e.key===j.RIGHT;if(this.isResizing&&(e.preventDefault(),e.stopImmediatePropagation()),t!==this.eGui||!e.shiftKey&&!e.altKey||((this.isResizing||r)&&(e.preventDefault(),e.stopImmediatePropagation()),!r))return;const i=e.key===j.LEFT!==this.gos.get("enableRtl")?"left":"right";if(e.altKey){this.isResizing=!0,this.resizeMultiplier+=1;const s=this.getViewportAdjustedResizeDiff(e);this.resizeHeader(s,e.shiftKey),(o=this.resizeFeature)==null||o.toggleColumnResizing(!0)}else this.moveHeader(i)}moveHeader(e){var t;(t=this.beans.colMoves)==null||t.moveHeader(e,this.eGui,this.column,this.rowCtrl.pinned,this)}getViewportAdjustedResizeDiff(e){const t=this.getResizeDiff(e),{pinnedCols:r}=this.beans;return r?r.getHeaderResizeDiff(t,this.column):t}getResizeDiff(e){const{gos:t,column:r}=this;let n=e.key===j.LEFT!==t.get("enableRtl");const i=r.getPinned(),o=t.get("enableRtl");return i&&o!==(i==="right")&&(n=!n),(n?-1:1)*this.resizeMultiplier}onGuiKeyUp(){this.isResizing&&(this.resizeToggleTimeout&&(window.clearTimeout(this.resizeToggleTimeout),this.resizeToggleTimeout=0),this.isResizing=!1,this.resizeMultiplier=1,this.resizeToggleTimeout=window.setTimeout(()=>{var e;(e=this.resizeFeature)==null||e.toggleColumnResizing(!1)},150))}handleKeyDown(e){const t=this.getWrapperHasFocus();switch(e.key){case j.PAGE_DOWN:case j.PAGE_UP:case j.PAGE_HOME:case j.PAGE_END:t&&e.preventDefault()}}addDomData(e){const t=eS,{eGui:r,gos:n}=this;Li(n,r,t,this),e.addDestroyFunc(()=>Li(n,r,t,null))}focus(e){const{eGui:t}=this;return t?(this.lastFocusEvent=e||null,t.focus(),!0):!1}focusThis(){this.beans.focusSvc.focusedHeader={headerRowIndex:this.rowCtrl.rowIndex,column:this.column}}removeDragSource(){var e;this.dragSource&&((e=this.beans.dragAndDrop)==null||e.removeDragSource(this.dragSource),this.dragSource=null)}handleContextMenuMouseEvent(e,t,r){const n=e??t,{menuSvc:i,gos:o}=this.beans;o.get("preventDefaultOnContextMenu")&&n.preventDefault(),i!=null&&i.isHeaderContextMenuEnabled(r)&&i.showHeaderContextMenu(r,e,t),this.dispatchColumnMouseEvent("columnHeaderContextMenu",r)}dispatchColumnMouseEvent(e,t){this.eventSvc.dispatchEvent({type:e,column:t})}setColHeaderHeight(e,t){if(!e.setAutoHeaderHeight(t))return;const{eventSvc:r}=this;e.isColumn?r.dispatchEvent({type:"columnHeaderHeightChanged",column:e,columns:[e],source:"autosizeColumnHeaderHeight"}):r.dispatchEvent({type:"columnGroupHeaderHeightChanged",columnGroup:e,source:"autosizeColumnGroupHeaderHeight"})}clearComponent(){this.removeDragSource(),this.resizeFeature=null,this.comp=null,this.eGui=null}destroy(){super.destroy(),this.column=null,this.lastFocusEvent=null,this.rowCtrl=null}},b3=class extends bp{constructor(){super(...arguments),this.refreshFunctions={},this.userHeaderClasses=new Set,this.ariaDescriptionProperties=new Map}setComp(e,t,r,n,i){this.comp=e;const{rowCtrl:o,column:s,beans:a}=this,{colResize:l,context:c,colHover:u,rangeSvc:d}=a,h=Aa(this,c,i);this.setGui(t,h),this.updateState(),this.setupWidth(h),this.setupMovingCss(h),this.setupMenuClass(h),this.setupSortableClass(h),this.setupWrapTextClass(),this.refreshSpanHeaderHeight(),this.setupAutoHeight({wrapperElement:n,checkMeasuringCallback:g=>this.setRefreshFunction("measuring",g),compBean:h}),this.addColumnHoverListener(h),this.setupFilterClass(h),this.setupStylesFromColDef(),this.setupClassesFromColDef(),this.setupTooltip(),this.addActiveHeaderMouseListeners(h),this.setupSelectAll(h),this.setupUserComp(),this.refreshAria(),l?this.resizeFeature=h.createManagedBean(l.createResizeFeature(o.pinned,s,r,e,this)):Je(r,!1),u==null||u.createHoverFeature(h,[s],t),d==null||d.createRangeHighlightFeature(h,s,e),h.createManagedBean(new yp(s,t,a)),h.createManagedBean(new bo(t,{shouldStopEventPropagation:g=>this.shouldStopEventPropagation(g),onTabKeyDown:()=>null,handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addResizeAndMoveKeyboardListeners(h),h.addManagedPropertyListeners(["suppressMovableColumns","suppressMenuHide","suppressAggFuncInHeader","enableAdvancedFilter"],()=>this.refresh()),h.addManagedListeners(s,{colDefChanged:()=>this.refresh()}),h.addManagedListeners(s,{headerHighlightChanged:this.onHeaderHighlightChanged.bind(this)});const f=()=>this.checkDisplayName();h.addManagedEventListeners({columnValueChanged:f,columnRowGroupChanged:f,columnPivotChanged:f,headerHeightChanged:this.onHeaderHeightChanged.bind(this)}),h.addDestroyFunc(()=>{this.refreshFunctions={},this.selectAllFeature=null,this.dragSourceElement=void 0,this.userCompDetails=null,this.userHeaderClasses.clear(),this.ariaDescriptionProperties.clear(),this.clearComponent()})}resizeHeader(e,t){var r;(r=this.beans.colResize)==null||r.resizeHeader(this.column,e,t)}getHeaderClassParams(){const{column:e,beans:t}=this,r=e.colDef;return pe(t.gos,{colDef:r,column:e,floatingFilter:!1})}setupUserComp(){const e=this.lookupUserCompDetails();e&&this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setUserCompDetails(e)}lookupUserCompDetails(){const e=this.createParams(),t=this.column.getColDef();return C_(this.beans.userCompFactory,t,e)}createParams(){const{menuSvc:e,sortSvc:t,colFilter:r,gos:n}=this.beans;return pe(n,{column:this.column,displayName:this.displayName,enableSorting:this.column.isSortable(),enableMenu:this.menuEnabled,enableFilterButton:this.openFilterEnabled&&!!(e!=null&&e.isHeaderFilterButtonEnabled(this.column)),enableFilterIcon:!!r&&(!this.openFilterEnabled||Bt(this.gos)),showColumnMenu:(o,s)=>{e==null||e.showColumnMenu({column:this.column,buttonElement:o,positionBy:"button",onClosedCallback:s})},showColumnMenuAfterMouseClick:(o,s)=>{e==null||e.showColumnMenu({column:this.column,mouseEvent:o,positionBy:"mouse",onClosedCallback:s})},showFilter:o=>{e==null||e.showFilterMenu({column:this.column,buttonElement:o,containerType:"columnFilter",positionBy:"button"})},progressSort:o=>{t==null||t.progressSort(this.column,!!o,"uiColumnSorted")},setSort:(o,s)=>{t==null||t.setSortForColumn(this.column,o,!!s,"uiColumnSorted")},eGridHeader:this.eGui,setTooltip:(o,s)=>{n.assertModuleRegistered("Tooltip",3),this.setupTooltip(o,s)}})}setupSelectAll(e){const{selectionSvc:t}=this.beans;t&&(this.selectAllFeature=e.createManagedBean(t.createSelectAllFeature(this.column)),this.selectAllFeature.setComp(this))}getSelectAllGui(){var e;return(e=this.selectAllFeature)==null?void 0:e.getCheckboxGui()}handleKeyDown(e){var t;super.handleKeyDown(e),e.key===j.SPACE&&((t=this.selectAllFeature)==null||t.onSpaceKeyDown(e)),e.key===j.ENTER&&this.onEnterKeyDown(e),e.key===j.DOWN&&e.altKey&&this.showMenuOnKeyPress(e,!1)}onEnterKeyDown(e){var t;e.ctrlKey||e.metaKey?this.showMenuOnKeyPress(e,!0):this.sortable&&((t=this.beans.sortSvc)==null||t.progressSort(this.column,e.shiftKey,"uiColumnSorted"))}showMenuOnKeyPress(e,t){const r=this.comp.getUserCompInstance();$v(r)&&r.onMenuKeyboardShortcut(t)&&e.preventDefault()}onFocusIn(e){this.eGui.contains(e.relatedTarget)||(this.focusThis(),this.announceAriaDescription()),tL()&&this.setActiveHeader(!0)}onFocusOut(e){this.eGui.contains(e.relatedTarget)||this.setActiveHeader(!1)}setupTooltip(e,t){var r;this.tooltipFeature=(r=this.beans.tooltipSvc)==null?void 0:r.setupHeaderTooltip(this.tooltipFeature,this,e,t)}setupStylesFromColDef(){this.setRefreshFunction("headerStyles",this.refreshHeaderStyles.bind(this)),this.refreshHeaderStyles()}setupClassesFromColDef(){const e=()=>{const t=this.column.getColDef(),r=M1(t,this.gos,this.column,null),n=this.userHeaderClasses;this.userHeaderClasses=new Set(r),r.forEach(i=>{n.has(i)?n.delete(i):this.comp.toggleCss(i,!0)}),n.forEach(i=>this.comp.toggleCss(i,!1))};this.setRefreshFunction("headerClasses",e),e()}setDragSource(e){var t;this.dragSourceElement=e,this.removeDragSource(),!(!e||!this.draggable)&&(this.dragSource=((t=this.beans.colMoves)==null?void 0:t.setDragSourceForHeader(e,this.column,this.displayName))??null)}updateState(){const{menuSvc:e}=this.beans;this.menuEnabled=!!(e!=null&&e.isColumnMenuInHeaderEnabled(this.column)),this.openFilterEnabled=!!(e!=null&&e.isFilterMenuInHeaderEnabled(this.column)),this.sortable=this.column.isSortable(),this.displayName=this.calculateDisplayName(),this.draggable=this.workOutDraggable()}setRefreshFunction(e,t){this.refreshFunctions[e]=t}refresh(){this.updateState(),this.refreshHeaderComp(),this.refreshAria(),Object.values(this.refreshFunctions).forEach(e=>e())}refreshHeaderComp(){const e=this.lookupUserCompDetails();if(!e)return;(this.comp.getUserCompInstance()!=null&&this.userCompDetails.componentClass==e.componentClass?this.attemptHeaderCompRefresh(e.params):!1)?this.setDragSource(this.dragSourceElement):this.setCompDetails(e)}attemptHeaderCompRefresh(e){const t=this.comp.getUserCompInstance();return!t||!t.refresh?!1:t.refresh(e)}calculateDisplayName(){return this.beans.colNames.getDisplayNameForColumn(this.column,"header",!0)}checkDisplayName(){this.displayName!==this.calculateDisplayName()&&this.refresh()}workOutDraggable(){const e=this.column.getColDef();return!!(!this.gos.get("suppressMovableColumns")&&!e.suppressMovable&&!e.lockPosition)||!!e.enableRowGroup||!!e.enablePivot}setupWidth(e){const t=()=>{const r=this.column.getActualWidth();this.comp.setWidth(`${r}px`)};e.addManagedListeners(this.column,{widthChanged:t}),t()}setupMovingCss(e){const t=()=>{this.comp.toggleCss("ag-header-cell-moving",this.column.isMoving())};e.addManagedListeners(this.column,{movingChanged:t}),t()}setupMenuClass(e){const t=()=>{var r;(r=this.comp)==null||r.toggleCss("ag-column-menu-visible",this.column.isMenuVisible())};e.addManagedListeners(this.column,{menuVisibleChanged:t}),t()}setupSortableClass(e){const t=()=>{this.comp.toggleCss("ag-header-cell-sortable",!!this.sortable)};t(),this.setRefreshFunction("updateSortable",t),e.addManagedEventListeners({sortChanged:this.refreshAriaSort.bind(this)})}setupFilterClass(e){const t=()=>{const r=this.column.isFilterActive();this.comp.toggleCss("ag-header-cell-filtered",r),this.refreshAria()};e.addManagedListeners(this.column,{filterActiveChanged:t}),t()}setupWrapTextClass(){const e=()=>{const t=!!this.column.getColDef().wrapHeaderText;this.comp.toggleCss("ag-header-cell-wrap-text",t)};e(),this.setRefreshFunction("wrapText",e)}onHeaderHighlightChanged(){const e=this.column.getHighlighted(),t=e===0,r=e===1;this.comp.toggleCss("ag-header-highlight-before",t),this.comp.toggleCss("ag-header-highlight-after",r)}onDisplayedColumnsChanged(){super.onDisplayedColumnsChanged(),this.isAlive()&&this.onHeaderHeightChanged()}onHeaderHeightChanged(){this.refreshSpanHeaderHeight()}refreshSpanHeaderHeight(){const{eGui:e,column:t,comp:r,beans:n}=this,i=mp(this.beans),o=i.reduce((u,d)=>u+=d,0)===0;if(r.toggleCss("ag-header-parent-hidden",o),!t.isSpanHeaderHeight()){e.style.removeProperty("top"),e.style.removeProperty("height"),r.toggleCss("ag-header-span-height",!1),r.toggleCss("ag-header-span-total",!1);return}const{numberOfParents:s,isSpanningTotal:a}=this.column.getColumnGroupPaddingInfo();r.toggleCss("ag-header-span-height",s>0);const l=vp(n);if(s===0){r.toggleCss("ag-header-span-total",!1),e.style.setProperty("top","0px"),e.style.setProperty("height",`${l}px`);return}r.toggleCss("ag-header-span-total",a);let c=0;for(let u=0;u<s;u++)c+=i[i.length-1-u];e.style.setProperty("top",`${-c}px`),e.style.setProperty("height",`${l+c}px`)}refreshAriaSort(){var e;if(this.sortable){const t=this.getLocaleTextFunc(),r=((e=this.beans.sortSvc)==null?void 0:e.getDisplaySortForColumn(this.column))||null;this.comp.setAriaSort(Ek(r)),this.setAriaDescriptionProperty("sort",t("ariaSortableColumn","Press ENTER to sort"))}else this.comp.setAriaSort(),this.setAriaDescriptionProperty("sort",null)}refreshAriaMenu(){if(this.menuEnabled){const e=this.getLocaleTextFunc();this.setAriaDescriptionProperty("menu",e("ariaMenuColumn","Press ALT DOWN to open column menu"))}else this.setAriaDescriptionProperty("menu",null)}refreshAriaFilterButton(){if(this.openFilterEnabled&&!Bt(this.gos)){const e=this.getLocaleTextFunc();this.setAriaDescriptionProperty("filterButton",e("ariaFilterColumn","Press CTRL ENTER to open filter"))}else this.setAriaDescriptionProperty("filterButton",null)}refreshAriaFiltered(){const e=this.getLocaleTextFunc();this.column.isFilterActive()?this.setAriaDescriptionProperty("filter",e("ariaColumnFiltered","Column Filtered")):this.setAriaDescriptionProperty("filter",null)}setAriaDescriptionProperty(e,t){t!=null?this.ariaDescriptionProperties.set(e,t):this.ariaDescriptionProperties.delete(e)}announceAriaDescription(){var t;if(!this.eGui.contains(Ke(this.beans)))return;const e=Array.from(this.ariaDescriptionProperties.keys()).sort((r,n)=>r==="filter"?-1:n.charCodeAt(0)-r.charCodeAt(0)).map(r=>this.ariaDescriptionProperties.get(r)).join(". ");(t=this.beans.ariaAnnounce)==null||t.announceValue(e,"columnHeader")}refreshAria(){this.refreshAriaSort(),this.refreshAriaMenu(),this.refreshAriaFilterButton(),this.refreshAriaFiltered()}addColumnHoverListener(e){var t;(t=this.beans.colHover)==null||t.addHeaderColumnHoverListener(e,this.comp,this.column)}addActiveHeaderMouseListeners(e){const t=i=>this.handleMouseOverChange(i.type==="mouseenter"),r=()=>{this.setActiveHeader(!0),this.dispatchColumnMouseEvent("columnHeaderClicked",this.column)},n=i=>this.handleContextMenuMouseEvent(i,void 0,this.column);e.addManagedListeners(this.eGui,{mouseenter:t,mouseleave:t,click:r,contextmenu:n})}handleMouseOverChange(e){this.setActiveHeader(e),this.eventSvc.dispatchEvent({type:e?"columnHeaderMouseOver":"columnHeaderMouseLeave",column:this.column})}setActiveHeader(e){this.comp.toggleCss("ag-header-active",e)}getAnchorElementForMenu(e){const t=this.comp.getUserCompInstance();return $v(t)?t.getAnchorElementForMenu(e):this.eGui}destroy(){this.tooltipFeature=this.destroyBean(this.tooltipFeature),super.destroy()}};function $v(e){return typeof(e==null?void 0:e.getAnchorElementForMenu)=="function"&&typeof e.onMenuKeyboardShortcut=="function"}var C3=0,yd=class extends q{constructor(e,t,r){super(),this.rowIndex=e,this.pinned=t,this.type=r,this.instanceId=C3++,this.allCtrls=[];const n=r=="group"?"ag-header-row-column-group":r=="filter"?"ag-header-row-column-filter":"ag-header-row-column";this.headerRowClass=`ag-header-row ${n}`}postConstruct(){this.isPrintLayout=pt(this.gos,"print"),this.isEnsureDomOrder=this.gos.get("ensureDomOrder")}areCellsRendered(){return this.comp?this.allCtrls.every(e=>e.eGui!=null):!1}setComp(e,t,r=!0){this.comp=e,t=Aa(this,this.beans.context,t),r&&(this.onRowHeightChanged(),this.onVirtualColumnsChanged()),this.setWidth(),this.addEventListeners(t)}getAriaRowIndex(){return this.rowIndex+1}addEventListeners(e){const t=this.onRowHeightChanged.bind(this),r=this.onDisplayedColumnsChanged.bind(this);e.addManagedEventListeners({columnResized:this.setWidth.bind(this),displayedColumnsChanged:r,virtualColumnsChanged:n=>this.onVirtualColumnsChanged(n.afterScroll),columnGroupHeaderHeightChanged:t,columnHeaderHeightChanged:t,gridStylesChanged:t,advancedFilterEnabledChanged:t}),e.addManagedPropertyListener("domLayout",r),e.addManagedPropertyListener("ensureDomOrder",n=>this.isEnsureDomOrder=n.currentValue),e.addManagedPropertyListeners(["headerHeight","pivotHeaderHeight","groupHeaderHeight","pivotGroupHeaderHeight","floatingFiltersHeight"],t)}onDisplayedColumnsChanged(){this.isPrintLayout=pt(this.gos,"print"),this.onVirtualColumnsChanged(),this.setWidth(),this.onRowHeightChanged()}setWidth(){const e=this.getWidthForRow();this.comp.setWidth(`${e}px`)}getWidthForRow(){const{visibleCols:e}=this.beans;return this.isPrintLayout?this.pinned!=null?0:e.getContainerWidth("right")+e.getContainerWidth("left")+e.getContainerWidth(null):e.getContainerWidth(this.pinned)}onRowHeightChanged(){const{topOffset:e,rowHeight:t}=this.getTopAndHeight();this.comp.setTop(e+"px"),this.comp.setHeight(t+"px")}getTopAndHeight(){const{filterManager:e}=this.beans,t=[],r=mp(this.beans),n=vp(this.beans);t.push(...r),t.push(n),e!=null&&e.hasFloatingFilters()&&t.push(Z1(this.beans));let i=0;for(let s=0;s<this.rowIndex;s++)i+=t[s];const o=t[this.rowIndex];return{topOffset:i,rowHeight:o}}onVirtualColumnsChanged(e=!1){const t=this.getUpdatedHeaderCtrls(),r=this.isEnsureDomOrder||this.isPrintLayout;this.comp.setHeaderCtrls(t,r,e)}getUpdatedHeaderCtrls(){const e=this.ctrlsById;this.ctrlsById=new Map;const t=this.getColumnsInViewport();for(const n of t)this.recycleAndCreateHeaderCtrls(n,this.ctrlsById,e);const r=n=>{const{focusSvc:i,visibleCols:o}=this.beans;return i.isHeaderWrapperFocused(n)?o.isVisible(n.column):!1};if(e)for(const[n,i]of e)r(i)?this.ctrlsById.set(n,i):this.destroyBean(i);return this.allCtrls=Array.from(this.ctrlsById.values()),this.allCtrls}getHeaderCellCtrls(){return this.allCtrls}recycleAndCreateHeaderCtrls(e,t,r){if(e.isEmptyGroup())return;const n=e.getUniqueId();let i;if(r&&(i=r.get(n),r.delete(n)),i&&i.column!=e&&(this.destroyBean(i),i=void 0),i==null)switch(this.type){case"filter":{i=this.createBean(this.beans.registry.createDynamicBean("headerFilterCellCtrl",!0,e,this));break}case"group":i=this.createBean(this.beans.registry.createDynamicBean("headerGroupCellCtrl",!0,e,this));break;default:i=this.createBean(new b3(e,this));break}t.set(n,i)}getColumnsInViewport(){return this.isPrintLayout?this.getColumnsInViewportPrintLayout():this.getColumnsInViewportNormalLayout()}getColumnsInViewportPrintLayout(){if(this.pinned!=null)return[];let e=[];const t=this.getActualDepth(),{colViewport:r}=this.beans;return["left",null,"right"].forEach(n=>{const i=r.getHeadersToRender(n,t);e=e.concat(i)}),e}getActualDepth(){return this.type=="filter"?this.rowIndex-1:this.rowIndex}getColumnsInViewportNormalLayout(){return this.beans.colViewport.getHeadersToRender(this.pinned,this.getActualDepth())}focusHeader(e,t){const r=this.allCtrls.find(i=>i.column==e);return r?r.focus(t):!1}destroy(){this.allCtrls=this.destroyBeans(this.allCtrls),this.ctrlsById=void 0,super.destroy()}},w3=class extends q{constructor(e){super(),this.pinned=e,this.hidden=!1,this.includeFloatingFilter=!1,this.groupsRowCtrls=[]}setComp(e,t){this.comp=e,this.eViewport=t;const{pinnedCols:r,ctrlsSvc:n,colModel:i,colMoves:o,filterManager:s}=this.beans;this.setupCenterWidth(),r==null||r.setupHeaderPinnedWidth(this),this.setupDragAndDrop(o,this.eViewport);const a=this.onDisplayedColumnsChanged.bind(this,s);this.addManagedEventListeners({gridColumnsChanged:this.onGridColumnsChanged.bind(this),displayedColumnsChanged:a,advancedFilterEnabledChanged:a});const l=`${typeof this.pinned=="string"?this.pinned:"center"}Header`;n.register(l,this),i.ready&&this.refresh()}getAllCtrls(){const e=[...this.groupsRowCtrls];return this.columnsRowCtrl&&e.push(this.columnsRowCtrl),this.filtersRowCtrl&&e.push(this.filtersRowCtrl),e}refresh(e=!1){const{focusSvc:t,colModel:r,filterManager:n}=this.beans;let i=0;const o=t.getFocusHeaderToUseAfterRefresh(),s=()=>{const u=f3(r)-1;this.groupsRowCtrls=this.destroyBeans(this.groupsRowCtrls);for(let d=0;d<u;d++){const h=this.createBean(new yd(i++,this.pinned,"group"));this.groupsRowCtrls.push(h)}},a=()=>{const u=i++,d=!this.hidden&&(this.columnsRowCtrl==null||!e||this.columnsRowCtrl.rowIndex!==u);(d||this.hidden)&&(this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl)),d&&(this.columnsRowCtrl=this.createBean(new yd(u,this.pinned,"column")))},l=()=>{this.includeFloatingFilter=!!(n!=null&&n.hasFloatingFilters())&&!this.hidden;const u=()=>{this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl)};if(!this.includeFloatingFilter){u();return}const d=i++;if(this.filtersRowCtrl){const h=this.filtersRowCtrl.rowIndex!==d;(!e||h)&&u()}this.filtersRowCtrl||(this.filtersRowCtrl=this.createBean(new yd(d,this.pinned,"filter")))};s(),a(),l();const c=this.getAllCtrls();this.comp.setCtrls(c),this.restoreFocusOnHeader(t,o)}getHeaderCtrlForColumn(e){const t=r=>r==null?void 0:r.getHeaderCellCtrls().find(n=>n.column===e);if($r(e))return t(this.columnsRowCtrl);if(this.groupsRowCtrls.length!==0)for(let r=0;r<this.groupsRowCtrls.length;r++){const n=t(this.groupsRowCtrls[r]);if(n)return n}}getHtmlElementForColumnHeader(e){var t;return((t=this.getHeaderCtrlForColumn(e))==null?void 0:t.eGui)??null}getRowType(e){var t;return(t=this.getAllCtrls()[e])==null?void 0:t.type}focusHeader(e,t,r){const i=this.getAllCtrls()[e];return i?i.focusHeader(t,r):!1}getGroupRowCount(){return this.groupsRowCtrls.length}getGroupRowCtrlAtIndex(e){return this.groupsRowCtrls[e]}getRowCount(){return this.groupsRowCtrls.length+(this.columnsRowCtrl?1:0)+(this.filtersRowCtrl?1:0)}setHorizontalScroll(e){this.comp.setViewportScrollLeft(e)}onScrollCallback(e){this.addManagedElementListeners(this.eViewport,{scroll:e})}destroy(){this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl),this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl),this.groupsRowCtrls=this.destroyBeans(this.groupsRowCtrls),super.destroy()}setupDragAndDrop(e,t){const r=e==null?void 0:e.createBodyDropTarget(this.pinned,t);r&&this.createManagedBean(r)}restoreFocusOnHeader(e,t){if(!t)return;const{column:r}=t;r.getPinned()==this.pinned&&e.focusHeaderPosition({headerPosition:t})}onGridColumnsChanged(){this.refresh(!0)}onDisplayedColumnsChanged(e){const t=!!(e!=null&&e.hasFloatingFilters())&&!this.hidden;this.includeFloatingFilter!==t&&this.refresh(!0)}setupCenterWidth(){this.pinned==null&&this.createManagedBean(new pp(e=>this.comp.setCenterWidth(`${e}px`),!0))}},S3=class extends q{constructor(){super(...arguments),this.beanName="menuSvc"}postConstruct(){const{enterpriseMenuFactory:e,filterMenuFactory:t}=this.beans;this.activeMenuFactory=e??t}showColumnMenu(e){this.showColumnMenuCommon(this.activeMenuFactory,e,"columnMenu")}showFilterMenu(e){const{enterpriseMenuFactory:t,filterMenuFactory:r}=this.beans,n=t&&Bt(this.gos)?t:r;this.showColumnMenuCommon(n,e,e.containerType,!0)}showHeaderContextMenu(e,t,r){var n;(n=this.activeMenuFactory)==null||n.showMenuAfterContextMenuEvent(e,t,r)}hidePopupMenu(){var e,t;(e=this.beans.contextMenuSvc)==null||e.hideActiveMenu(),(t=this.activeMenuFactory)==null||t.hideActiveMenu()}isColumnMenuInHeaderEnabled(e){var r;const{suppressHeaderMenuButton:t}=e.getColDef();return!t&&!!((r=this.activeMenuFactory)!=null&&r.isMenuEnabled(e))&&(Bt(this.gos)||!!this.beans.enterpriseMenuFactory)}isFilterMenuInHeaderEnabled(e){var t;return!e.getColDef().suppressHeaderFilterButton&&!!((t=this.beans.filterManager)!=null&&t.isFilterAllowed(e))}isHeaderContextMenuEnabled(e){const t=e&&$r(e)?e.getColDef():e==null?void 0:e.getColGroupDef();return!(t!=null&&t.suppressHeaderContextMenu)&&this.gos.get("columnMenu")==="new"}isHeaderMenuButtonAlwaysShowEnabled(){return this.isSuppressMenuHide()}isHeaderMenuButtonEnabled(){const e=!this.isSuppressMenuHide();return!(Dn()&&e)}isHeaderFilterButtonEnabled(e){return this.isFilterMenuInHeaderEnabled(e)&&!Bt(this.gos)&&!this.isFloatingFilterButtonDisplayed(e)}isFilterMenuItemEnabled(e){var t;return!!((t=this.beans.filterManager)!=null&&t.isFilterAllowed(e))&&!Bt(this.gos)&&!this.isFilterMenuInHeaderEnabled(e)&&!this.isFloatingFilterButtonDisplayed(e)}isFloatingFilterButtonEnabled(e){return!e.getColDef().suppressFloatingFilterButton}isFloatingFilterButtonDisplayed(e){return!!e.getColDef().floatingFilter&&this.isFloatingFilterButtonEnabled(e)}isSuppressMenuHide(){const e=this.gos,t=e.get("suppressMenuHide");return Bt(e)?e.exists("suppressMenuHide")?t:!1:t}showColumnMenuCommon(e,t,r,n){const{positionBy:i,onClosedCallback:o}=t,s=t.column;if(i==="button"){const{buttonElement:a}=t;e==null||e.showMenuAfterButtonClick(s,a,r,o,n)}else if(i==="mouse"){const{mouseEvent:a}=t;e==null||e.showMenuAfterMouseEvent(s,a,r,o,n)}else if(s){const a=this.beans,l=a.ctrlsSvc;l.getScrollFeature().ensureColumnVisible(s,"auto"),Ur(a,()=>{var u;const c=(u=l.getHeaderRowContainerCtrl(s.getPinned()))==null?void 0:u.getHeaderCtrlForColumn(s);c&&(e==null||e.showMenuAfterButtonClick(s,c.getAnchorElementForMenu(n),r,o,n))})}}};function Hv(e,t,r){e.menuVisible!==t&&(e.menuVisible=t,e.dispatchColEvent("menuVisibleChanged",r))}var tS=class extends ct{constructor(){super()}},x3={tag:"span",cls:"ag-overlay-loading-center",attrs:{"aria-live":"polite","aria-atomic":"true"}},A3=class extends tS{init(){var t;const e=on((t=this.gos.get("overlayLoadingTemplate"))==null?void 0:t.trim());if(this.setTemplate(e??x3),!e){const r=this.getLocaleTextFunc();setTimeout(()=>{this.getGui().textContent=r("loadingOoo","Loading...")})}}},P3={tag:"span",cls:"ag-overlay-no-rows-center"},R3=class extends tS{init(){var t;const e=on((t=this.gos.get("overlayNoRowsTemplate"))==null?void 0:t.trim());if(this.setTemplate(e??P3),!e){const r=this.getLocaleTextFunc();setTimeout(()=>{this.getGui().textContent=r("noRowsToShow","No Rows To Show")})}}};function E3(e,t,r){const n=Co(e,t,r);if(n){const{className:o}=n;if(typeof o=="string"&&o.indexOf("ag-icon")>-1||typeof o=="object"&&o["ag-icon"])return n}const i=lt({tag:"span"});return i.appendChild(n),i}function Co(e,t,r){var o;let n=null;e==="smallDown"?Q(262):e==="smallLeft"?Q(263):e==="smallRight"&&Q(264);const i=r&&r.getColDef().icons;if(i&&(n=i[e]),t.gos&&!n){const s=t.gos.get("icons");s&&(n=s[e])}if(n){let s;if(typeof n=="function")s=n();else if(typeof n=="string")s=n;else{Q(38,{iconName:e});return}if(typeof s=="string")return np(s);if(q2(s))return s;Q(133,{iconName:e});return}else{const s=t.registry.getIcon(e);return s||(o=t.validation)==null||o.validateIcon(e),lt({tag:"span",cls:`ag-icon ag-icon-${s??e}`,role:"presentation",attrs:{unselectable:"on"}})}}var T3=".ag-dnd-ghost{align-items:center;background-color:var(--ag-drag-and-drop-image-background-color);border:var(--ag-drag-and-drop-image-border);border-radius:var(--ag-border-radius);box-shadow:var(--ag-drag-and-drop-image-shadow);color:var(--ag-text-color);cursor:move;display:flex;font-weight:500;gap:var(--ag-cell-widget-spacing);height:var(--ag-header-height);overflow:hidden;padding-left:var(--ag-cell-horizontal-padding);padding-right:var(--ag-cell-horizontal-padding);text-overflow:ellipsis;transform:translateY(calc(var(--ag-spacing)*2));white-space:nowrap}",F3={tag:"div",children:[{tag:"div",ref:"eGhost",cls:"ag-dnd-ghost ag-unselectable",children:[{tag:"span",ref:"eIcon",cls:"ag-dnd-ghost-icon ag-shake-left-to-right"},{tag:"div",ref:"eLabel",cls:"ag-dnd-ghost-label"}]}]},O3=class extends ct{constructor(){super(),this.dragSource=null,this.eIcon=fe,this.eLabel=fe,this.eGhost=fe,this.registerCSS(T3)}postConstruct(){const e=t=>E3(t,this.beans,null);this.dropIconMap={pinned:e("columnMovePin"),hide:e("columnMoveHide"),move:e("columnMoveMove"),left:e("columnMoveLeft"),right:e("columnMoveRight"),group:e("columnMoveGroup"),aggregate:e("columnMoveValue"),pivot:e("columnMovePivot"),notAllowed:e("dropNotAllowed")}}init(e){this.dragSource=e.dragSource,this.setTemplate(F3),this.beans.environment.applyThemeClasses(this.eGhost)}destroy(){this.dragSource=null,super.destroy()}setIcon(e,t){const{eIcon:r,dragSource:n,dropIconMap:i,gos:o}=this;hn(r);let s=null;e||(e=n!=null&&n.getDefaultIconName?n.getDefaultIconName():"notAllowed"),s=i[e],r.classList.toggle("ag-shake-left-to-right",t),!(s===i.hide&&o.get("suppressDragLeaveHidesColumns"))&&s&&r.appendChild(s)}setLabel(e){this.eLabel.textContent=e}},M3=".ag-label{white-space:nowrap}:where(.ag-ltr) .ag-label{margin-right:var(--ag-spacing)}:where(.ag-rtl) .ag-label{margin-left:var(--ag-spacing)}:where(.ag-label-align-right) .ag-label{order:1}:where(.ag-ltr) :where(.ag-label-align-right) .ag-label{margin-left:var(--ag-spacing)}:where(.ag-rtl) :where(.ag-label-align-right) .ag-label{margin-right:var(--ag-spacing)}.ag-label-align-right>*{flex:none}.ag-label-align-top{align-items:flex-start;flex-direction:column;>*{align-self:stretch}}.ag-label-ellipsis{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:where(.ag-label-align-top) .ag-label{margin-bottom:calc(var(--ag-spacing)*.5)}",D3=class extends ct{constructor(e,t,r){super(t,r),this.labelSeparator="",this.labelAlignment="left",this.disabled=!1,this.label="",this.config=e||{},this.registerCSS(M3)}postConstruct(){this.addCss("ag-labeled"),this.eLabel.classList.add("ag-label");const{labelSeparator:e,label:t,labelWidth:r,labelAlignment:n,disabled:i}=this.config;i!=null&&this.setDisabled(i),e!=null&&this.setLabelSeparator(e),t!=null&&this.setLabel(t),r!=null&&this.setLabelWidth(r),this.setLabelAlignment(n||this.labelAlignment),this.refreshLabel()}refreshLabel(){const{label:e,eLabel:t}=this;hn(t),typeof e=="string"?t.innerText=e+this.labelSeparator:e&&t.appendChild(e),e===""?(Je(t,!1),_i(t,"presentation")):(Je(t,!0),_i(t,null))}setLabelSeparator(e){return this.labelSeparator===e?this:(this.labelSeparator=e,this.label!=null&&this.refreshLabel(),this)}getLabelId(){const e=this.eLabel;return e.id=e.id||`ag-${this.getCompId()}-label`,e.id}getLabel(){return this.label}setLabel(e){return this.label===e?this:(this.label=e,this.refreshLabel(),this)}setLabelAlignment(e){const r=this.getGui().classList;return r.toggle("ag-label-align-left",e==="left"),r.toggle("ag-label-align-right",e==="right"),r.toggle("ag-label-align-top",e==="top"),this}setLabelEllipsis(e){return this.eLabel.classList.toggle("ag-label-ellipsis",e),this}setLabelWidth(e){return this.label==null?this:(Ml(this.eLabel,e),this)}setDisabled(e){e=!!e;const t=this.getGui();return xs(t,e),t.classList.toggle("ag-disabled",e),this.disabled=e,this}isDisabled(){return!!this.disabled}},rS=class extends D3{constructor(e,t,r,n){super(e,t,r),this.className=n}postConstruct(){super.postConstruct();const{width:e,value:t,onValueChange:r}=this.config;e!=null&&this.setWidth(e),t!=null&&this.setValue(t),r!=null&&this.onValueChange(r),this.className&&this.addCss(this.className),this.refreshAriaLabelledBy()}setLabel(e){return super.setLabel(e),this.refreshAriaLabelledBy(),this}refreshAriaLabelledBy(){const e=this.getAriaElement(),t=this.getLabelId(),r=this.getLabel();r==null||r==""||Tk(e)!==null?Ah(e,""):Ah(e,t??"")}setAriaLabel(e){return lu(this.getAriaElement(),e),this.refreshAriaLabelledBy(),this}onValueChange(e){return this.addManagedListeners(this,{fieldValueChanged:()=>e(this.getValue())}),this}getWidth(){return this.getGui().clientWidth}setWidth(e){return yr(this.getGui(),e),this}getPreviousValue(){return this.previousValue}getValue(){return this.value}setValue(e,t){return this.value===e?this:(this.previousValue=this.value,this.value=e,t||this.dispatchLocalEvent({type:"fieldValueChanged"}),this)}};function k3(e){return{tag:"div",role:"presentation",children:[{tag:"div",ref:"eLabel",cls:"ag-input-field-label"},{tag:"div",ref:"eWrapper",cls:"ag-wrapper ag-input-wrapper",role:"presentation",children:[{tag:e,ref:"eInput",cls:"ag-input-field-input"}]}]}}var pi=class extends rS{constructor(e,t,r="text",n="input"){super(e,(e==null?void 0:e.template)??k3(n),[],t),this.inputType=r,this.displayFieldTag=n,this.eLabel=fe,this.eWrapper=fe,this.eInput=fe}postConstruct(){super.postConstruct(),this.setInputType();const{eLabel:e,eWrapper:t,eInput:r,className:n}=this;e.classList.add(`${n}-label`),t.classList.add(`${n}-input-wrapper`),r.classList.add(`${n}-input`),this.addCss("ag-input-field"),r.id=r.id||`ag-${this.getCompId()}-input`;const{inputName:i,inputWidth:o}=this.config;i!=null&&this.setInputName(i),o!=null&&this.setInputWidth(o),this.addInputListeners(),this.activateTabIndex([r])}addInputListeners(){this.addManagedElementListeners(this.eInput,{input:e=>this.setValue(e.target.value)})}setInputType(){this.displayFieldTag==="input"&&this.eInput.setAttribute("type",this.inputType)}getInputElement(){return this.eInput}setInputWidth(e){return Ml(this.eWrapper,e),this}setInputName(e){return this.getInputElement().setAttribute("name",e),this}getFocusableElement(){return this.eInput}setMaxLength(e){const t=this.eInput;return t.maxLength=e,this}setInputPlaceholder(e){return Si(this.eInput,"placeholder",e),this}setInputAriaLabel(e){return lu(this.eInput,e),this.refreshAriaLabelledBy(),this}setDisabled(e){return xs(this.eInput,e),super.setDisabled(e)}setAutoComplete(e){if(e===!0)Si(this.eInput,"autocomplete",null);else{const t=typeof e=="string"?e:"off";Si(this.eInput,"autocomplete",t)}return this}},Cp=class extends pi{constructor(e,t="ag-checkbox",r="checkbox"){super(e,t,r),this.labelAlignment="right",this.selected=!1,this.readOnly=!1,this.passive=!1}postConstruct(){super.postConstruct();const{readOnly:e,passive:t}=this.config;typeof e=="boolean"&&this.setReadOnly(e),typeof t=="boolean"&&this.setPassive(t)}addInputListeners(){this.addManagedElementListeners(this.eInput,{click:this.onCheckboxClick.bind(this)}),this.addManagedElementListeners(this.eLabel,{click:this.toggle.bind(this)})}getNextValue(){return this.selected===void 0?!0:!this.selected}setPassive(e){this.passive=e}isReadOnly(){return this.readOnly}setReadOnly(e){this.eWrapper.classList.toggle("ag-disabled",e),this.eInput.disabled=e,this.readOnly=e}setDisabled(e){return this.eWrapper.classList.toggle("ag-disabled",e),super.setDisabled(e)}toggle(){if(this.eInput.disabled)return;const e=this.isSelected(),t=this.getNextValue();this.passive?this.dispatchChange(t,e):this.setValue(t)}getValue(){return this.isSelected()}setValue(e,t){return this.refreshSelectedClass(e),this.setSelected(e,t),this}setName(e){const t=this.getInputElement();return t.name=e,this}isSelected(){return this.selected}setSelected(e,t){if(this.isSelected()===e)return;this.previousValue=this.isSelected(),e=this.selected=typeof e=="boolean"?e:void 0;const r=this.eInput;r.checked=e,r.indeterminate=e===void 0,t||this.dispatchChange(this.selected,this.previousValue)}dispatchChange(e,t,r){this.dispatchLocalEvent({type:"fieldValueChanged",selected:e,previousValue:t,event:r});const n=this.getInputElement();this.eventSvc.dispatchEvent({type:"checkboxChanged",id:n.id,name:n.name,selected:e,previousValue:t})}onCheckboxClick(e){if(this.passive||this.eInput.disabled)return;const t=this.isSelected(),r=this.selected=e.target.checked;this.refreshSelectedClass(r),this.dispatchChange(r,t,e)}refreshSelectedClass(e){const t=this.eWrapper.classList;t.toggle("ag-checked",e===!0),t.toggle("ag-indeterminate",e==null)}},nS={selector:"AG-CHECKBOX",component:Cp},I3=".ag-checkbox-cell{height:100%}",_3={tag:"div",cls:"ag-cell-wrapper ag-checkbox-cell",role:"presentation",children:[{tag:"ag-checkbox",ref:"eCheckbox",role:"presentation"}]},L3=class extends ct{constructor(){super(_3,[nS]),this.eCheckbox=fe,this.registerCSS(I3)}init(e){this.refresh(e);const{eCheckbox:t,beans:r}=this,n=t.getInputElement();n.setAttribute("tabindex","-1"),L2(n,"polite"),this.addManagedListeners(n,{click:i=>{if(Kn(i),t.isDisabled())return;const o=t.getValue();this.onCheckboxChanged(o)},dblclick:i=>{Kn(i)}}),this.addManagedElementListeners(e.eGridCell,{keydown:i=>{if(i.key===j.SPACE&&!t.isDisabled()){e.eGridCell===Ke(r)&&t.toggle();const o=t.getValue();this.onCheckboxChanged(o),i.preventDefault()}}})}refresh(e){return this.params=e,this.updateCheckbox(e),!0}updateCheckbox(e){let t,r=!0;const{value:n,column:i,node:o}=e;if(o.group&&i)if(typeof n=="boolean")t=n;else{const d=i.getColId();d.startsWith(uu)?t=n==null||n===""?void 0:n==="true":o.aggData&&o.aggData[d]!==void 0?t=n??void 0:r=!1}else t=n??void 0;const{eCheckbox:s}=this;if(!r){s.setDisplayed(!1);return}s.setValue(t);const a=e.disabled??!(i!=null&&i.isCellEditable(o));s.setDisabled(a);const l=this.getLocaleTextFunc(),c=N2(l,t),u=a?c:`${l("ariaToggleCellValue","Press SPACE to toggle cell value")} (${c})`;s.setInputAriaLabel(u)}onCheckboxChanged(e){const{eventSvc:t,params:r}=this,{column:n,node:i,value:o}=r,s={column:n,colDef:n.getColDef(),data:i.data,node:i,rowIndex:i.rowIndex,rowPinned:i.rowPinned,value:o};t.dispatchEvent({type:"cellEditingStarted",...s});const a=i.setDataValue(n,e,"edit");t.dispatchEvent({type:"cellEditingStopped",...s,oldValue:o,newValue:e,valueChanged:a}),a||this.updateCheckbox(r)}},Gv=class{constructor(e,t){this.beans=e,this.floating=t,this.all=new Set,this.visible=new Set,this.order=[],this.queued=new Set}size(){return this.visible.size}add(e){const{all:t,visible:r,order:n}=this;t.has(e)||(t.add(e),r.add(e),n.push(e),this.sort())}delete(e){this.all.delete(e),this.visible.delete(e),this.queued.delete(e.id),Zt(this.order,e)}has(e){return this.visible.has(e)}forEach(e){this.order.forEach(e)}getByIndex(e){return this.order[e]}getById(e){for(const t of this.visible)if(t.id==e)return t}clear(){const{all:e,visible:t,order:r,queued:n}=this;e.clear(),n.clear(),t.clear(),r.length=0}sort(){const{sortSvc:e,rowNodeSorter:t}=this.beans,r=(e==null?void 0:e.getSortOptions())??[],n=N3(this.order);if(this.order.sort((o,s)=>{var a,l;return(((a=o.pinnedSibling)==null?void 0:a.rowIndex)??0)-(((l=s.pinnedSibling)==null?void 0:l.rowIndex)??0)}),this.order=(t==null?void 0:t.doFullSort(this.order,r))??this.order,!n)return;const i=this.beans.gos.get("grandTotalRow");i==="bottom"||i==="pinnedBottom"?this.order.push(n):this.order.unshift(n)}hide(e){const{all:t,visible:r}=this;t.forEach(n=>e(n)?r.delete(n):r.add(n)),this.order=Array.from(r),this.sort()}queue(e){this.queued.add(e)}unqueue(e){this.queued.delete(e)}forEachQueued(e){this.queued.forEach(e)}};function iS(e){var r;if(e.level===-1)return!0;const t=e.parent;return(r=t==null?void 0:t.childrenAfterSort)!=null&&r.some(n=>n==e)?iS(t):!1}function bd(e,t){const{gos:r,rowModel:n,filterManager:i}=e;return po(r)?!n.getRowNode(t.id):i!=null&&i.isAnyFilterPresent()?!iS(t):r.get("pivotMode")?!t.group:!1}function B3(e){return!!e.footer&&e.level===-1}function z3(e){return!!e.pinnedSibling&&B3(e.pinnedSibling)}function N3(e){var r;const t=e.findIndex(z3);if(t>-1)return(r=e.splice(t,1))==null?void 0:r[0]}var $3=class extends q{postConstruct(){const{gos:e,beans:t}=this;this.top=new Gv(t,"top"),this.bottom=new Gv(t,"bottom");const r=i=>bd(t,i.pinnedSibling),n=()=>{const i=e.get("isRowPinned");i&&t.rowModel.forEachNode(o=>this.pinRow(o,i(o)),!0),this.refreshRowPositions(),this.dispatchRowPinnedEvents()};this.addManagedEventListeners({gridStylesChanged:this.onGridStylesChanges.bind(this),modelUpdated:()=>{this.tryToEmptyQueues(),this.pinGrandTotalRow(),this.forContainers(i=>i.hide(r)),this.refreshRowPositions(),this.dispatchRowPinnedEvents()},columnRowGroupChanged:()=>{this.forContainers(G3),this.refreshRowPositions()},rowNodeDataChanged:({node:i})=>{const o=e.get("isRowPinnable");((o==null?void 0:o(i))??!0)||this.pinRow(i,null)},firstDataRendered:n}),this.addManagedPropertyListener("pivotMode",()=>{this.forContainers(i=>i.hide(r)),this.dispatchRowPinnedEvents()}),this.addManagedPropertyListener("grandTotalRow",({currentValue:i})=>{this._grandTotalPinned=i==="pinnedBottom"?"bottom":i==="pinnedTop"?"top":null}),this.addManagedPropertyListener("isRowPinned",n)}destroy(){this.reset(!1),super.destroy()}reset(e=!0){this.forContainers(t=>{const r=[];t.forEach(n=>r.push(n)),r.forEach(n=>this.pinRow(n,null)),t.clear()}),e&&this.dispatchRowPinnedEvents()}pinRow(e,t,r){var s;if(e.footer&&e.level>-1)return;if(e.footer&&e.level===-1){this._grandTotalPinned=t,xt(this.gos,this.beans.rowModel)&&this.beans.rowModel.refreshModel({step:"map"});return}const n=e.rowPinned??((s=e.pinnedSibling)==null?void 0:s.rowPinned);if(n!=null&&t!=null&&t!=n){const a=e.rowPinned?e:e.pinnedSibling,l=e.rowPinned?e.pinnedSibling:e;this.pinRow(a,null,r),this.pinRow(l,t,r);return}const o=r&&W3(this.beans,e,r);if(o){o.forEach(a=>this.pinRow(a,t));return}if(t==null){const a=e.rowPinned?e:e.pinnedSibling,l=this.findPinnedRowNode(a);if(!l)return;l.delete(a);const c=a.pinnedSibling;Cd(a),this.refreshRowPositions(t),this.dispatchRowPinnedEvents(c)}else{const a=Wv(this.beans,e,t),l=this.getContainer(t);l.add(a),bd(this.beans,e)&&l.hide(c=>bd(this.beans,c.pinnedSibling)),this.refreshRowPositions(t),this.dispatchRowPinnedEvents(e)}}isManual(){return!0}isEmpty(e){return this.getContainer(e).size()===0}isRowsToRender(e){return!this.isEmpty(e)}ensureRowHeightsValid(){let e=!1,t=0;const r=n=>{if(n.rowHeightEstimated){const i=Un(this.beans,n);n.setRowTop(t),n.setRowHeight(i.height),t+=i.height,e=!0}};return this.bottom.forEach(r),t=0,this.top.forEach(r),this.eventSvc.dispatchEvent({type:"pinnedHeightChanged"}),e}getPinnedTopTotalHeight(){const e=this.top.size();if(e===0)return 0;const t=this.top.getByIndex(e-1);return t===void 0?0:t.rowTop+t.rowHeight}getPinnedBottomTotalHeight(){const e=this.bottom.size();if(e===0)return 0;const t=this.bottom.getByIndex(e-1);return t===void 0?0:t.rowTop+t.rowHeight}getPinnedTopRowCount(){return this.top.size()}getPinnedBottomRowCount(){return this.bottom.size()}getPinnedTopRow(e){return this.top.getByIndex(e)}getPinnedBottomRow(e){return this.bottom.getByIndex(e)}getPinnedRowById(e,t){return this.getContainer(t).getById(e)}forEachPinnedRow(e,t){this.getContainer(e).forEach(t)}getPinnedState(){const e=t=>{const r=[];return this.forEachPinnedRow(t,n=>r.push(n.pinnedSibling.id)),r};return{top:e("top"),bottom:e("bottom")}}setPinnedState(e){this.forContainers((t,r)=>{for(const n of e[r]){const i=this.beans.rowModel.getRowNode(n);i?this.pinRow(i,r):t.queue(n)}})}getGrandTotalPinned(){return this._grandTotalPinned}setGrandTotalPinned(e){this._grandTotalPinned=e}tryToEmptyQueues(){this.forContainers((e,t)=>{const r=new Set;e.forEachQueued(n=>{const i=this.beans.rowModel.getRowNode(n);i&&r.add(i)});for(const n of r)e.unqueue(n.id),this.pinRow(n,t)})}pinGrandTotalRow(){var o;const e=this.beans.rowModel;if(!xt(this.gos))return;const t=(o=e.rootNode)==null?void 0:o.sibling;if(!t)return;const r=this._grandTotalPinned,n=t.pinnedSibling,i=n&&this.findPinnedRowNode(n);if(r){if(i&&i.floating!==r&&(i.delete(n),Cd(n)),!i||i.floating!==r){const s=Wv(this.beans,t,r);this.getContainer(r).add(s)}}else{if(!i)return;i.delete(n),Cd(n)}}onGridStylesChanges(e){if(e.rowHeightChanged){const t=r=>{r.setRowHeight(r.rowHeight,!0)};this.forContainers(r=>r.forEach(t))}}getContainer(e){return e==="top"?this.top:this.bottom}findPinnedRowNode(e){if(this.top.has(e))return this.top;if(this.bottom.has(e))return this.bottom}refreshRowPositions(e){const t=r=>H3(this.beans,r);return e==null?this.forContainers(t):t(this.getContainer(e))}forContainers(e){e(this.top,"top"),e(this.bottom,"bottom")}dispatchRowPinnedEvents(e){this.eventSvc.dispatchEvent({type:"pinnedRowsChanged"}),e==null||e.dispatchRowEvent("rowPinned")}};function H3(e,t){let r=0;t.forEach((n,i)=>{n.setRowTop(r),(n.rowHeightEstimated||n.rowHeight==null)&&n.setRowHeight(Un(e,n).height),n.setRowIndex(i),r+=n.rowHeight})}function Wv(e,t,r){if(t.pinnedSibling)return t.pinnedSibling;const n=EL(t,e);n.setRowTop(null),n.setRowIndex(null),n.rowPinned=r;const i=r==="top"?hp:fp;return n.id=`${i}${r}-${t.id}`,n.pinnedSibling=t,t.pinnedSibling=n,n}function Cd(e){if(!e.pinnedSibling)return;e.rowPinned=null,e.setRowTop(null),e.setRowIndex(null);const t=e.pinnedSibling;e.pinnedSibling=void 0,t&&(t.pinnedSibling=void 0,t.rowPinned=null)}function G3(e){const t=new Set;e.forEach(r=>{r.group&&t.add(r)}),t.forEach(r=>{e.delete(r)})}function W3(e,t,r){const{rowSpanSvc:n}=e,i=(r&&(n==null?void 0:n.isCellSpanning(r,t)))??!1;if(r&&i){const o=n==null?void 0:n.getCellSpan(r,t);if(o)return Array.from(o.spannedNodes)}}var j3=class extends q{constructor(){super(...arguments),this.nextId=0,this.pinnedTopRows={cache:{},order:[]},this.pinnedBottomRows={cache:{},order:[]}}postConstruct(){const e=this.gos;this.setPinnedRowData(e.get("pinnedTopRowData"),"top"),this.setPinnedRowData(e.get("pinnedBottomRowData"),"bottom"),this.addManagedPropertyListener("pinnedTopRowData",t=>this.setPinnedRowData(t.currentValue,"top")),this.addManagedPropertyListener("pinnedBottomRowData",t=>this.setPinnedRowData(t.currentValue,"bottom")),this.addManagedEventListeners({gridStylesChanged:this.onGridStylesChanges.bind(this)})}reset(){}isEmpty(e){return this.getCache(e).order.length===0}isRowsToRender(e){return!this.isEmpty(e)}isManual(){return!1}pinRow(e,t){}onGridStylesChanges(e){if(e.rowHeightChanged){const t=r=>{r.setRowHeight(r.rowHeight,!0)};No(this.pinnedBottomRows,t),No(this.pinnedTopRows,t)}}ensureRowHeightsValid(){let e=!1,t=0;const r=n=>{if(n.rowHeightEstimated){const i=Un(this.beans,n);n.setRowTop(t),n.setRowHeight(i.height),t+=i.height,e=!0}};return No(this.pinnedBottomRows,r),t=0,No(this.pinnedTopRows,r),this.eventSvc.dispatchEvent({type:"pinnedHeightChanged"}),e}setPinnedRowData(e,t){this.updateNodesFromRowData(e,t),this.eventSvc.dispatchEvent({type:"pinnedRowDataChanged"})}updateNodesFromRowData(e,t){const r=this.getCache(t);if(e===void 0){r.order.length=0,r.cache={};return}const n=Rs(this.gos),i=t==="top"?hp:fp,o=new Set(r.order),s=[],a=new Set;let l=0,c=-1;for(const u of e){const d=(n==null?void 0:n({data:u,level:0,rowPinned:t}))??i+this.nextId++;if(a.has(d)){Q(96,{id:d,data:u});continue}c++,a.add(d),s.push(d);const h=cs(r,d);if(h!==void 0)h.data!==u&&h.updateData(u),l+=this.setRowTopAndRowIndex(h,l,c),o.delete(d);else{const f=new Yn(this.beans);f.id=d,f.data=u,f.rowPinned=t,l+=this.setRowTopAndRowIndex(f,l,c),r.cache[d]=f,r.order.push(d)}}o.forEach(u=>{var d;(d=cs(r,u))==null||d.clearRowTopAndRowIndex(),delete r.cache[u]}),r.order=s}setRowTopAndRowIndex(e,t,r){return e.setRowTop(t),e.setRowHeight(Un(this.beans,e).height),e.setRowIndex(r),e.rowHeight}getPinnedTopTotalHeight(){return jv(this.pinnedTopRows)}getPinnedBottomTotalHeight(){return jv(this.pinnedBottomRows)}getPinnedTopRowCount(){return Hh(this.pinnedTopRows)}getPinnedBottomRowCount(){return Hh(this.pinnedBottomRows)}getPinnedTopRow(e){return $h(this.pinnedTopRows,e)}getPinnedBottomRow(e){return $h(this.pinnedBottomRows,e)}getPinnedRowById(e,t){return cs(this.getCache(t),e)}forEachPinnedRow(e,t){return No(this.getCache(e),t)}getCache(e){return e==="top"?this.pinnedTopRows:this.pinnedBottomRows}getPinnedState(){return{top:[],bottom:[]}}setPinnedState(){}getGrandTotalPinned(){}setGrandTotalPinned(){}};function jv(e){const t=Hh(e);if(t===0)return 0;const r=$h(e,t-1);return r===void 0?0:r.rowTop+r.rowHeight}function cs(e,t){return e.cache[t]}function $h(e,t){return cs(e,e.order[t])}function No(e,t){e.order.forEach((r,n)=>{const i=cs(e,r);i&&t(i,n)})}function Hh(e){return e.order.length}var V3=class extends q{constructor(){super(...arguments),this.beanName="pinnedRowModel"}postConstruct(){const e=()=>{const t=this.gos.get("enableRowPinning");this.inner&&this.destroyBean(this.inner),this.inner=this.createManagedBean(t?new $3:new j3)};this.addManagedPropertyListener("enableRowPinning",e),e()}reset(){return this.inner.reset()}isEmpty(e){return this.inner.isEmpty(e)}isManual(){return this.inner.isManual()}isRowsToRender(e){return this.inner.isRowsToRender(e)}pinRow(e,t,r){return this.inner.pinRow(e,t,r)}ensureRowHeightsValid(){return this.inner.ensureRowHeightsValid()}getPinnedRowById(e,t){return this.inner.getPinnedRowById(e,t)}getPinnedTopTotalHeight(){return this.inner.getPinnedTopTotalHeight()}getPinnedBottomTotalHeight(){return this.inner.getPinnedBottomTotalHeight()}getPinnedTopRowCount(){return this.inner.getPinnedTopRowCount()}getPinnedBottomRowCount(){return this.inner.getPinnedBottomRowCount()}getPinnedTopRow(e){return this.inner.getPinnedTopRow(e)}getPinnedBottomRow(e){return this.inner.getPinnedBottomRow(e)}forEachPinnedRow(e,t){return this.inner.forEachPinnedRow(e,t)}getPinnedState(){return this.inner.getPinnedState()}setPinnedState(e){return this.inner.setPinnedState(e)}setGrandTotalPinned(e){return this.inner.setGrandTotalPinned(e)}getGrandTotalPinned(){return this.inner.getGrandTotalPinned()}},U3="ROOT_NODE_ID",K3=class extends q{constructor(){super(...arguments),this.nextId=0,this.allNodesMap={},this.rootNode=null}get treeData(){return!1}getRowNode(e){return this.allNodesMap[e]}extractRowData(){var e,t;return(t=(e=this.rootNode)==null?void 0:e.allLeafChildren)==null?void 0:t.map(r=>r.data)}activate(e){this.rootNode=e,e.group=!0,e.level=-1,e.id=U3,e.allLeafChildren=[],e.childrenAfterGroup=[],e.childrenAfterSort=[],e.childrenAfterAggFilter=[],e.childrenAfterFilter=[],this.updateRootSiblingArrays(e)}deactivate(){this.rootNode&&(this.allNodesMap={},this.rootNode=null)}destroy(){super.destroy(),this.allNodesMap={},this.rootNode=null}setNewRowData(e){const t=this.rootNode;t&&(this.dispatchRowDataUpdateStartedEvent(e),t.childrenAfterFilter=null,t.childrenAfterGroup=null,t.childrenAfterAggFilter=null,t.childrenAfterSort=null,t.childrenMapped=null,t.updateHasChildren(),this.allNodesMap={},this.nextId=0,this.loadNewRowData(e),this.updateRootSiblingArrays(t))}updateRootSiblingArrays(e){const t=e.sibling;t&&(t.childrenAfterFilter=e.childrenAfterFilter,t.childrenAfterGroup=e.childrenAfterGroup,t.childrenAfterAggFilter=e.childrenAfterAggFilter,t.childrenAfterSort=e.childrenAfterSort,t.childrenMapped=e.childrenMapped,t.allLeafChildren=e.allLeafChildren)}loadNewRowData(e){this.rootNode.allLeafChildren=(e==null?void 0:e.map((t,r)=>this.createRowNode(t,r)))??[]}setImmutableRowData(e,t){var g;const r=Rs(this.gos),n=!this.gos.get("suppressMaintainUnsortedOrder"),i=e.changedRowNodes,o=new Set,s=this.rootNode,a=s.allLeafChildren,l=a.length;let c=!1,u=!1,d=!1,h=!1;for(let m=0,p=-1,y=t.length;m<y;m++){const w=t[m];let b=this.getRowNode(r({data:w,level:0}));if(!b)c=!0,b=this.createRowNode(w,-1),i.add(b);else{if(n){const x=b.sourceRowIndex;h||(h=x<=p||c),p=x}b.data!==w&&(d=!0,b.updateData(w),i.update(b))}o.add(b)}const f=[];for(let m=0;m<l;m++){const p=a[m];o.has(p)||(u=!0,p.isSelected()&&f.push(p),p.pinnedSibling&&((g=this.beans.pinnedRowModel)==null||g.pinRow(p.pinnedSibling,null)),this.rowNodeDeleted(p),i.remove(p))}if(c||u||h){const m=new Array(o.size);let p=0;if(!n)for(let w=0;w<l;++w){const b=a[w];o.delete(b)&&(b.sourceRowIndex=p,m[p++]=b)}for(const w of o)w.sourceRowIndex=p,m[p++]=w;s.allLeafChildren=m;const y=s.sibling;y&&(y.allLeafChildren=m),e.rowNodesOrderChanged||(e.rowNodesOrderChanged=h)}(c||u||h||d)&&(this.deselectNodes(f),e.rowDataUpdated=!0)}rowNodeDeleted(e){e.clearRowTopAndRowIndex();const t=e.id,r=this.allNodesMap;r[t]===e&&delete r[t]}updateRowData(e,t){this.dispatchRowDataUpdateStartedEvent(e.add);const r={changedRowNodes:t,rowNodeTransaction:{remove:[],update:[],add:[]},rowsInserted:!1},n=[],i=Rs(this.gos);return this.executeRemove(i,e,r,n),this.executeUpdate(i,e,r,n),this.executeAdd(e,r),this.deselectNodes(n),r}executeAdd(e,t){const r=e.add;if(!(r!=null&&r.length))return;let n=this.rootNode.allLeafChildren,i=n.length;if(typeof e.addIndex=="number"&&(i=this.sanitizeAddIndex(e.addIndex),i>0&&this.gos.get("treeData")&&this.gos.get("getDataPath")))for(let d=0;d<n.length;d++){const h=n[d];if((h==null?void 0:h.rowIndex)==i-1){i=d+1;break}}const o=r.length,s=t.changedRowNodes,a=new Array(o);for(let u=0;u<o;u++){const d=this.createRowNode(r[u],i+u);s.add(d),a[u]=d}const l=this.rootNode;if(i<n.length){const u=n.slice(0,i),d=n.slice(i,n.length),h=u.length+a.length;for(let f=0,g=d.length;f<g;++f)d[f].sourceRowIndex=h+f;n=[...u,...a,...d],t.rowsInserted=!0}else n=n.concat(a);l.allLeafChildren=n;const c=l.sibling;c&&(c.allLeafChildren=n),t.rowNodeTransaction.add=a}executeRemove(e,t,{changedRowNodes:r,rowNodeTransaction:n},i){var c,u;const{remove:o}=t;if(!(o!=null&&o.length))return;const s={};o.forEach(d=>{var f;const h=this.lookupRowNode(e,d);h&&(h.isSelected()&&i.push(h),h.pinnedSibling&&((f=this.beans.pinnedRowModel)==null||f.pinRow(h.pinnedSibling,null)),h.clearRowTopAndRowIndex(),s[h.id]=!0,delete this.allNodesMap[h.id],n.remove.push(h),r.remove(h))});const a=this.rootNode;a.allLeafChildren=((c=a.allLeafChildren)==null?void 0:c.filter(d=>!s[d.id]))??null,(u=a.allLeafChildren)==null||u.forEach((d,h)=>{d.sourceRowIndex=h});const l=a.sibling;l&&(l.allLeafChildren=a.allLeafChildren)}executeUpdate(e,t,{changedRowNodes:r,rowNodeTransaction:n},i){const{update:o}=t;o!=null&&o.length&&o.forEach(s=>{const a=this.lookupRowNode(e,s);a&&(a.updateData(s),!a.selectable&&a.isSelected()&&i.push(a),n.update.push(a),r.update(a))})}dispatchRowDataUpdateStartedEvent(e){this.eventSvc.dispatchEvent({type:"rowDataUpdateStarted",firstRowData:e!=null&&e.length?e[0]:null})}deselectNodes(e){var i;const t="rowDataChanged",r=this.beans.selectionSvc,n=e.length>0;n&&(r==null||r.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,source:t})),(i=r==null?void 0:r.updateGroupsFromChildrenSelections)==null||i.call(r,t),n&&this.eventSvc.dispatchEvent({type:"selectionChanged",source:t,selectedNodes:(r==null?void 0:r.getSelectedNodes())??null,serverSideState:null})}sanitizeAddIndex(e){var r;const t=((r=this.rootNode.allLeafChildren)==null?void 0:r.length)??0;return e<0||e>=t||Number.isNaN(e)?t:Math.ceil(e)}createRowNode(e,t){const r=new Yn(this.beans);return r.parent=this.rootNode,r.level=0,r.group=!1,r.expanded=!1,r.sourceRowIndex=t,r.setDataAndId(e,String(this.nextId)),this.allNodesMap[r.id]&&Q(2,{nodeId:r.id}),this.allNodesMap[r.id]=r,this.nextId++,r}lookupRowNode(e,t){var n,i;let r;if(e){const o=e({data:t,level:0});if(r=this.allNodesMap[o],!r)return _e(4,{id:o}),null}else if(r=(i=(n=this.rootNode)==null?void 0:n.allLeafChildren)==null?void 0:i.find(o=>o.data===t),!r)return _e(5,{data:t}),null;return r||null}},q3={tag:"div",cls:"ag-selection-checkbox",role:"presentation",children:[{tag:"ag-checkbox",ref:"eCheckbox",role:"presentation"}]},Y3=class extends ct{constructor(){super(q3,[nS]),this.eCheckbox=fe}postConstruct(){this.eCheckbox.setPassive(!0)}getCheckboxId(){return this.eCheckbox.getInputElement().id}onDataChanged(){this.onSelectionChanged()}onSelectableChanged(){this.showOrHideSelect()}onSelectionChanged(){const e=this.getLocaleTextFunc(),{rowNode:t,eCheckbox:r}=this,n=t.isSelected(),i=N2(e,n),[o,s]=t.selectable?["ariaRowToggleSelection","Press Space to toggle row selection"]:["ariaRowSelectionDisabled","Row Selection is disabled for this row"],a=e(o,s);r.setValue(n,!0),r.setInputAriaLabel(`${a} (${i})`)}init(e){if(this.rowNode=e.rowNode,this.column=e.column,this.overrides=e.overrides,this.onSelectionChanged(),this.addManagedListeners(this.eCheckbox.getInputElement(),{dblclick:Kn,click:n=>{var i;Kn(n),(i=this.beans.selectionSvc)==null||i.handleSelectionEvent(n,this.rowNode,"checkboxSelected")}}),this.addManagedListeners(this.rowNode,{rowSelected:this.onSelectionChanged.bind(this),dataChanged:this.onDataChanged.bind(this),selectableChanged:this.onSelectableChanged.bind(this)}),this.addManagedPropertyListener("rowSelection",({currentValue:n,previousValue:i})=>{const o=typeof n=="object"?dd(n):void 0,s=typeof i=="object"?dd(i):void 0;o!==s&&this.onSelectableChanged()}),Ih(this.gos)||typeof this.getIsVisible()=="function"){const n=this.showOrHideSelect.bind(this);this.addManagedEventListeners({displayedColumnsChanged:n}),this.addManagedListeners(this.rowNode,{dataChanged:n,cellChanged:n}),this.showOrHideSelect()}this.eCheckbox.getInputElement().setAttribute("tabindex","-1")}showOrHideSelect(){const{column:e,rowNode:t,overrides:r,gos:n}=this;let i=t.selectable;const o=this.getIsVisible();if(i)if(typeof o=="function"){const l=r==null?void 0:r.callbackParams;if(!e)i=o({...l,node:t,data:t.data});else{const c=e.createColumnFunctionCallbackParams(t);i=o({...l,...c})}}else i=o??!1;const s=n.get("rowSelection");if(s&&typeof s!="string"?!dd(s):e==null?void 0:e.getColDef().showDisabledCheckboxes){this.eCheckbox.setDisabled(!i),this.setVisible(!0),this.setDisplayed(!0);return}if(r!=null&&r.removeHidden){this.setDisplayed(i);return}this.setVisible(i)}getIsVisible(){var r,n;const e=this.overrides;if(e)return e.isVisible;const t=this.gos.get("rowSelection");return t&&typeof t!="string"?Ai(t):(n=(r=this.column)==null?void 0:r.getColDef())==null?void 0:n.checkboxSelection}},J3=class{constructor(e,t){this.rowModel=e,this.pinnedRowModel=t,this.selectAll=!1,this.rootId=null,this.endId=null,this.cachedRange=[]}reset(){this.rootId=null,this.endId=null,this.cachedRange.length=0}setRoot(e){this.rootId=e.id,this.endId=null,this.cachedRange.length=0}setEndRange(e){this.endId=e.id,this.cachedRange.length=0}getRange(){if(this.cachedRange.length===0){const e=this.getRoot(),t=this.getEnd();if(e==null||t==null)return this.cachedRange;this.cachedRange=this.getNodesInRange(e,t)??[]}return this.cachedRange}isInRange(e){return this.rootId===null?!1:this.getRange().some(t=>t.id===e.id)}getRoot(e){if(this.rootId)return this.getRowNode(this.rootId);if(e)return this.setRoot(e),e}getEnd(){if(this.endId)return this.getRowNode(this.endId)}getRowNode(e){let t;const{rowModel:r,pinnedRowModel:n}=this;return t??(t=r.getRowNode(e)),n!=null&&n.isManual()&&(t??(t=n.getPinnedRowById(e,"top")),t??(t=n.getPinnedRowById(e,"bottom"))),t}truncate(e){const t=this.getRange();if(t.length===0)return{keep:[],discard:[]};const r=t[0].id===this.rootId,n=t.findIndex(i=>i.id===e.id);if(n>-1){const i=t.slice(0,n),o=t.slice(n+1);return this.setEndRange(e),r?{keep:i,discard:o}:{keep:o,discard:i}}else return{keep:t,discard:[]}}extend(e,t=!1){const r=this.getRoot();if(r==null){const i=this.getRange().slice();return t&&e.depthFirstSearch(o=>!o.group&&i.push(o)),i.push(e),this.setRoot(e),{keep:i,discard:[]}}const n=this.getNodesInRange(r,e);if(!n)return this.setRoot(e),{keep:[e],discard:[]};if(n.find(i=>i.id===this.endId))return this.setEndRange(e),{keep:this.getRange(),discard:[]};{const i=this.getRange().slice();return this.setEndRange(e),{keep:this.getRange(),discard:i}}}getNodesInRange(e,t){const{pinnedRowModel:r,rowModel:n}=this;if(!(r!=null&&r.isManual()))return n.getNodesInRangeForSelection(e,t);if(e.rowPinned==="top"&&!t.rowPinned)return Wt(r,"top",e,void 0).concat(n.getNodesInRangeForSelection(n.getRow(0),t)??[]);if(e.rowPinned==="bottom"&&!t.rowPinned){const i=Wt(r,"bottom",void 0,e),o=n.getRowCount(),s=n.getRow(o-1);return(n.getNodesInRangeForSelection(t,s)??[]).concat(i)}if(!e.rowPinned&&!t.rowPinned)return n.getNodesInRangeForSelection(e,t);if(e.rowPinned==="top"&&t.rowPinned==="top")return Wt(r,"top",e,t);if(e.rowPinned==="bottom"&&t.rowPinned==="top"){const i=Wt(r,"top",t,void 0),o=Wt(r,"bottom",void 0,e),s=n.getRow(0),a=n.getRow(n.getRowCount()-1);return i.concat(n.getNodesInRangeForSelection(s,a)??[]).concat(o)}if(!e.rowPinned&&t.rowPinned==="top")return Wt(r,"top",t,void 0).concat(n.getNodesInRangeForSelection(n.getRow(0),e)??[]);if(e.rowPinned==="top"&&t.rowPinned==="bottom"){const i=Wt(r,"top",e,void 0),o=Wt(r,"bottom",void 0,t),s=n.getRow(0),a=n.getRow(n.getRowCount()-1);return i.concat(n.getNodesInRangeForSelection(s,a)??[]).concat(o)}if(e.rowPinned==="bottom"&&t.rowPinned==="bottom")return Wt(r,"bottom",e,t);if(!e.rowPinned&&t.rowPinned==="bottom"){const i=Wt(r,"bottom",void 0,t),o=n.getRow(n.getRowCount());return(n.getNodesInRangeForSelection(e,o)??[]).concat(i)}return null}},X3=class extends q{constructor(e){super(),this.column=e,this.cbSelectAllVisible=!1,this.processingEventFromCheckbox=!1}onSpaceKeyDown(e){const t=this.cbSelectAll;t.isDisplayed()&&!t.getGui().contains(Ke(this.beans))&&(e.preventDefault(),t.setValue(!t.getValue()))}getCheckboxGui(){return this.cbSelectAll.getGui()}setComp(e){this.headerCellCtrl=e;const t=this.createManagedBean(new Cp);this.cbSelectAll=t,t.addCss("ag-header-select-all"),_i(t.getGui(),"presentation"),this.showOrHideSelectAll();const r=this.updateStateOfCheckbox.bind(this);this.addManagedEventListeners({newColumnsLoaded:()=>this.showOrHideSelectAll(),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),selectionChanged:r,paginationChanged:r,modelUpdated:r}),this.addManagedPropertyListener("rowSelection",({currentValue:n,previousValue:i})=>{const o=s=>typeof s=="string"||!s||s.mode==="singleRow"?void 0:s.selectAll;o(n)!==o(i)&&this.showOrHideSelectAll(),this.updateStateOfCheckbox()}),this.addManagedListeners(t,{fieldValueChanged:this.onCbSelectAll.bind(this)}),t.getInputElement().setAttribute("tabindex","-1"),this.refreshSelectAllLabel()}onDisplayedColumnsChanged(e){this.isAlive()&&this.showOrHideSelectAll(e.source==="uiColumnMoved")}showOrHideSelectAll(e=!1){const t=this.isCheckboxSelection();this.cbSelectAllVisible=t,this.cbSelectAll.setDisplayed(t),t&&(this.checkRightRowModelType("selectAllCheckbox"),this.checkSelectionType("selectAllCheckbox"),this.updateStateOfCheckbox()),this.refreshSelectAllLabel(e)}updateStateOfCheckbox(){if(!this.cbSelectAllVisible||this.processingEventFromCheckbox)return;this.processingEventFromCheckbox=!0;const e=this.getSelectAllMode(),t=this.beans.selectionSvc,r=this.cbSelectAll,n=t.getSelectAllState(e);r.setValue(n);const i=t.hasNodesToSelect(e);r.setDisabled(!i),this.refreshSelectAllLabel(),this.processingEventFromCheckbox=!1}refreshSelectAllLabel(e=!1){const t=this.getLocaleTextFunc(),{headerCellCtrl:r,cbSelectAll:n,cbSelectAllVisible:i}=this,s=n.getValue()?t("ariaChecked","checked"):t("ariaUnchecked","unchecked"),a=t("ariaRowSelectAll","Press Space to toggle all rows selection");r.setAriaDescriptionProperty("selectAll",i?`${a} (${s})`:null),n.setInputAriaLabel(t("ariaHeaderSelection","Column with Header Selection")),e||r.announceAriaDescription()}checkSelectionType(e){return Il(this.gos)?!0:(Q(128,{feature:e}),!1)}checkRightRowModelType(e){const{gos:t,rowModel:r}=this.beans;return xt(t)||po(t)?!0:(Q(129,{feature:e,rowModel:r.getType()}),!1)}onCbSelectAll(){if(this.processingEventFromCheckbox||!this.cbSelectAllVisible)return;const e=this.cbSelectAll.getValue(),t=this.getSelectAllMode();let r="uiSelectAll";t==="currentPage"?r="uiSelectAllCurrentPage":t==="filtered"&&(r="uiSelectAllFiltered");const n={source:r,selectAll:t},i=this.beans.selectionSvc;e?i.selectAllRowNodes(n):i.deselectAllRowNodes(n)}isCheckboxSelection(){var c;const{column:e,gos:t,beans:r}=this,n=t.get("rowSelection"),i=e.getColDef(),{headerCheckboxSelection:o}=i;let s=!1;const a=typeof n=="object";if(a){const u=xa(e),d=v1(e);(Dl(n)==="autoGroupColumn"&&d||u&&((c=r.selectionColSvc)!=null&&c.isSelectionColumnEnabled()))&&(s=fl(n))}else typeof o=="function"?s=o(pe(t,{column:e,colDef:i})):s=!!o;const l=a?"headerCheckbox":"headerCheckboxSelection";return s&&this.checkRightRowModelType(l)&&this.checkSelectionType(l)}getSelectAllMode(){const e=c1(this.gos,!1);if(e)return e;const{headerCheckboxSelectionCurrentPageOnly:t,headerCheckboxSelectionFilteredOnly:r}=this.column.getColDef();return t?"currentPage":r?"filtered":"all"}},Z3=class extends q{postConstruct(){const{gos:e,beans:t}=this;this.selectionCtx=new J3(t.rowModel,t.pinnedRowModel),this.addManagedPropertyListeners(["isRowSelectable","rowSelection"],()=>{const r=Ih(e);r!==this.isRowSelectable&&(this.isRowSelectable=r,this.updateSelectable())}),this.isRowSelectable=Ih(e)}destroy(){super.destroy(),this.selectionCtx.reset()}createCheckboxSelectionComponent(){return new Y3}createSelectAllFeature(e){return new X3(e)}isMultiSelect(){return Il(this.gos)}onRowCtrlSelected(e,t,r){const n=!!e.rowNode.isSelected();e.forEachGui(r,i=>{i.rowComp.toggleCss("ag-row-selected",n);const o=i.element;Rh(o,n),o.contains(Ke(this.beans))&&t(i)})}announceAriaRowSelection(e){var i;if(this.isRowSelectionBlocked(e))return;const t=e.isSelected();if(!e.selectable)return;const n=this.getLocaleTextFunc()(t?"ariaRowDeselect":"ariaRowSelect",`Press SPACE to ${t?"deselect":"select"} this row`);(i=this.beans.ariaAnnounce)==null||i.announceValue(n,"rowSelection")}isRowSelectionBlocked(e){return!e.selectable||e.rowPinned&&!Ra(e)||!In(this.gos)}updateRowSelectable(e,t){var n;const r=((n=this.isRowSelectable)==null?void 0:n.call(this,e))??!0;return this.setRowSelectable(e,r,t),r}setRowSelectable(e,t,r){if(e.selectable!==t){if(e.selectable=t,e.dispatchRowEvent("selectableChanged"),r)return;if(Ts(this.gos)){const i=this.calculateSelectedFromChildren(e);this.setNodesSelected({nodes:[e],newValue:i??!1,source:"selectableChanged"});return}e.isSelected()&&!e.selectable&&this.setNodesSelected({nodes:[e],newValue:!1,source:"selectableChanged"})}}calculateSelectedFromChildren(e){var n;let t=!1,r=!1;if(!((n=e.childrenAfterGroup)!=null&&n.length))return e.selectable?e.__selected:null;for(let i=0;i<e.childrenAfterGroup.length;i++){const o=e.childrenAfterGroup[i];let s=o.isSelected();if(!o.selectable){const a=this.calculateSelectedFromChildren(o);if(a===null)continue;s=a}switch(s){case!0:t=!0;break;case!1:r=!0;break;default:return}}if(!(t&&r))return t?!0:r?!1:e.selectable?e.__selected:null}selectRowNode(e,t,r,n="api"){const i=!e.selectable&&t,o=e.__selected===t;if(i||o)return!1;e.__selected=t,e.dispatchRowEvent("rowSelected");const s=e.sibling;s&&s.footer&&s.__localEventService&&s.dispatchRowEvent("rowSelected");const a=e.pinnedSibling;return a&&a.rowPinned&&a.__localEventService&&a.dispatchRowEvent("rowSelected"),this.eventSvc.dispatchEvent({...PL(e,this.gos,"rowSelected"),event:r||null,source:n}),!0}isCellCheckboxSelection(e,t){const r=this.gos.get("rowSelection");if(r&&typeof r!="string"){const n=xa(e)&&Ai(r);return e.isColumnFunc(t,n)}else return e.isColumnFunc(t,e.colDef.checkboxSelection)}inferNodeSelections(e,t,r,n){const{gos:i,selectionCtx:o}=this,s=e.isSelected(),a=Ts(i),l=hI(i),c=fI(i),u=this.isMultiSelect(),d=n==="rowClicked";if(d&&!(l||c))return null;if(t&&r&&u){const h=o.getRoot();if(h)if(h.isSelected()){const f=o.isInRange(e)?o.truncate(e):o.extend(e,a);return{deselect:f.discard,select:f.keep,reset:!1}}else{const f=o.extend(e,a);return{select:[],deselect:f.keep,reset:!1}}else return null}else if(t&&u){const h=o.selectAll?this.beans.rowModel.getRow(0):void 0,f=o.getRoot(h),g=o.isInRange(e)?o.truncate(e):o.extend(e,a);return{select:g.keep,deselect:g.discard,reset:o.selectAll||!!(f&&!f.isSelected())}}else if(r){if(d){const h=!s;return h&&!l||!h&&!c?null:(o.setRoot(e),{node:e,newValue:h,clearSelection:!1})}return o.setRoot(e),{node:e,newValue:!s,clearSelection:!u}}else{o.setRoot(e);const h=gI(i),f=_l(i)==="filteredDescendants",g=d&&(!h||!l);if(f&&s===void 0&&xt(i))return{node:e,newValue:!1,clearSelection:!u||g};if(d){const m=s?!h:l;return m===s&&!g||m&&!l||!m&&!c?null:{node:e,newValue:m,clearSelection:!u||g,keepDescendants:e.group&&a}}return{node:e,newValue:!s,clearSelection:!u||g}}}},Q3=class extends Cp{constructor(e){super(e,"ag-radio-button","radio")}isSelected(){return this.eInput.checked}toggle(){this.eInput.disabled||this.isSelected()||this.setValue(!0)}addInputListeners(){super.addInputListeners(),this.addManagedEventListeners({checkboxChanged:this.onChange.bind(this)})}onChange(e){const t=this.eInput;e.selected&&e.name&&t.name&&t.name===e.name&&e.id&&t.id!==e.id&&this.setValue(!1,!0)}},oS=class extends pi{constructor(e,t="ag-text-field",r="text"){super(e,t,r)}postConstruct(){super.postConstruct(),this.config.allowedCharPattern&&this.preventDisallowedCharacters()}setValue(e,t){const r=this.eInput;return r.value!==e&&(r.value=ie(e)?e:""),super.setValue(e,t)}setStartValue(e){this.setValue(e,!0)}preventDisallowedCharacters(){const e=new RegExp(`[${this.config.allowedCharPattern}]`),t=r=>{U1(r)&&r.key&&!e.test(r.key)&&r.preventDefault()};this.addManagedListeners(this.eInput,{keydown:t,paste:r=>{var i;const n=(i=r.clipboardData)==null?void 0:i.getData("text");n&&n.split("").some(o=>!e.test(o))&&r.preventDefault()}})}};function Vv(e,t){return e.toString().padStart(t,"0")}function Uv(e,t=!0,r="-"){if(!e)return null;let n=[e.getFullYear(),e.getMonth()+1,e.getDate()].map(i=>Vv(i,2)).join(r);return t&&(n+=" "+[e.getHours(),e.getMinutes(),e.getSeconds()].map(i=>Vv(i,2)).join(":")),n}function Kv(e){if(!e)return null;const[t,r]=e.split(" ");if(!t)return null;const n=t.split("-").map(d=>parseInt(d,10));if(n.filter(d=>!isNaN(d)).length!==3)return null;const[i,o,s]=n,a=new Date(i,o-1,s);if(a.getFullYear()!==i||a.getMonth()!==o-1||a.getDate()!==s)return null;if(!r||r==="00:00:00")return a;const[l,c,u]=r.split(":").map(d=>parseInt(d,10));return l>=0&&l<24&&a.setHours(l),c>=0&&c<60&&a.setMinutes(c),u>=0&&u<60&&a.setSeconds(u),a}var eB=1e3,tB=1e3,qv=100,Yv,Va=!1,rB=class extends q{constructor(e,t){super(),this.tooltipCtrl=e,this.getTooltipValue=t,this.interactionEnabled=!1,this.isInteractingWithTooltip=!1,this.state=0,this.tooltipInstanceCount=0,this.tooltipMouseTrack=!1}wireBeans(e){this.popupSvc=e.popupSvc,this.userCompFactory=e.userCompFactory}postConstruct(){this.gos.get("tooltipInteraction")&&(this.interactionEnabled=!0),this.tooltipTrigger=this.getTooltipTrigger(),this.tooltipMouseTrack=this.gos.get("tooltipMouseTrack");const e=this.tooltipCtrl.getGui();this.tooltipTrigger===0&&this.addManagedListeners(e,{mouseenter:this.onMouseEnter.bind(this),mouseleave:this.onMouseLeave.bind(this)}),this.tooltipTrigger===1&&this.addManagedListeners(e,{focusin:this.onFocusIn.bind(this),focusout:this.onFocusOut.bind(this)}),this.addManagedListeners(e,{mousemove:this.onMouseMove.bind(this)}),this.interactionEnabled||this.addManagedListeners(e,{mousedown:this.onMouseDown.bind(this),keydown:this.onKeyDown.bind(this)})}getGridOptionsTooltipDelay(e){const t=this.gos.get(e);return Math.max(200,t)}getTooltipDelay(e){var t,r,n,i;return e==="show"?((r=(t=this.tooltipCtrl).getTooltipShowDelayOverride)==null?void 0:r.call(t))??this.getGridOptionsTooltipDelay("tooltipShowDelay"):((i=(n=this.tooltipCtrl).getTooltipHideDelayOverride)==null?void 0:i.call(n))??this.getGridOptionsTooltipDelay("tooltipHideDelay")}destroy(){this.setToDoNothing(),super.destroy()}getTooltipTrigger(){const e=this.gos.get("tooltipTrigger");return!e||e==="hover"?0:1}onMouseEnter(e){this.interactionEnabled&&this.interactiveTooltipTimeoutId&&(this.unlockService(),this.startHideTimeout()),!Dn()&&(Va?this.showTooltipTimeoutId=window.setTimeout(()=>{this.prepareToShowTooltip(e)},qv):this.prepareToShowTooltip(e))}onMouseMove(e){this.lastMouseEvent&&(this.lastMouseEvent=e),this.tooltipMouseTrack&&this.state===2&&this.tooltipComp&&this.positionTooltip()}onMouseDown(){this.setToDoNothing()}onMouseLeave(){this.interactionEnabled?this.lockService():this.setToDoNothing()}onFocusIn(){this.prepareToShowTooltip()}onFocusOut(e){var i;const t=e.relatedTarget,r=this.tooltipCtrl.getGui(),n=(i=this.tooltipComp)==null?void 0:i.getGui();this.isInteractingWithTooltip||r.contains(t)||this.interactionEnabled&&(n!=null&&n.contains(t))||this.setToDoNothing()}onKeyDown(){this.isInteractingWithTooltip&&(this.isInteractingWithTooltip=!1),this.setToDoNothing()}prepareToShowTooltip(e){if(this.state!=0||Va)return;let t=0;e&&(t=this.isLastTooltipHiddenRecently()?200:this.getTooltipDelay("show")),this.lastMouseEvent=e||null,this.showTooltipTimeoutId=window.setTimeout(this.showTooltip.bind(this),t),this.state=1}isLastTooltipHiddenRecently(){return Date.now()-Yv<eB}setToDoNothing(e){!e&&this.state===2&&this.hideTooltip(),this.onBodyScrollEventCallback&&(this.onBodyScrollEventCallback(),this.onBodyScrollEventCallback=void 0),this.onColumnMovedEventCallback&&(this.onColumnMovedEventCallback(),this.onColumnMovedEventCallback=void 0),this.onDocumentKeyDownCallback&&(this.onDocumentKeyDownCallback(),this.onDocumentKeyDownCallback=void 0),this.clearTimeouts(),this.state=0,this.lastMouseEvent=null}showTooltip(){var s,a,l,c,u,d,h;const e=this.getTooltipValue(),t=this.tooltipCtrl;if(!ie(e)||t.shouldDisplayTooltip&&!t.shouldDisplayTooltip()){this.setToDoNothing();return}const r=(s=t.getRowNode)==null?void 0:s.call(t),n=pe(this.gos,{location:((a=t.getLocation)==null?void 0:a.call(t))??"UNKNOWN",colDef:(l=t.getColDef)==null?void 0:l.call(t),column:(c=t.getColumn)==null?void 0:c.call(t),rowIndex:(u=t.getRowIndex)==null?void 0:u.call(t),node:r,data:r==null?void 0:r.data,value:e,valueFormatted:(d=t.getValueFormatted)==null?void 0:d.call(t),hideTooltipCallback:()=>this.hideTooltip(!0),...((h=t.getAdditionalParams)==null?void 0:h.call(t))??{}});this.state=2,this.tooltipInstanceCount++;const i=this.newTooltipComponentCallback.bind(this,this.tooltipInstanceCount),o=D_(this.userCompFactory,n);o==null||o.newAgStackInstance().then(i)}hideTooltip(e){!e&&this.isInteractingWithTooltip||(this.tooltipComp&&(this.destroyTooltipComp(),Yv=Date.now()),this.eventSvc.dispatchEvent({type:"tooltipHide",parentGui:this.tooltipCtrl.getGui()}),e&&(this.isInteractingWithTooltip=!1),this.setToDoNothing(!0))}newTooltipComponentCallback(e,t){var s;if(this.state!==2||this.tooltipInstanceCount!==e){this.destroyBean(t);return}const n=t.getGui();this.tooltipComp=t,n.classList.contains("ag-tooltip")||n.classList.add("ag-tooltip-custom"),this.tooltipTrigger===0&&n.classList.add("ag-tooltip-animate"),this.interactionEnabled&&n.classList.add("ag-tooltip-interactive");const i=this.getLocaleTextFunc(),o=(s=this.popupSvc)==null?void 0:s.addPopup({eChild:n,ariaLabel:i("ariaLabelTooltip","Tooltip")});if(o&&(this.tooltipPopupDestroyFunc=o.hideFunc),this.positionTooltip(),this.tooltipTrigger===1){const a=()=>this.setToDoNothing();[this.onBodyScrollEventCallback,this.onColumnMovedEventCallback]=this.addManagedEventListeners({bodyScroll:a,columnMoved:a})}this.interactionEnabled&&([this.tooltipMouseEnterListener,this.tooltipMouseLeaveListener]=this.addManagedElementListeners(n,{mouseenter:this.onTooltipMouseEnter.bind(this),mouseleave:this.onTooltipMouseLeave.bind(this)}),[this.onDocumentKeyDownCallback]=this.addManagedElementListeners(gt(this.beans),{keydown:a=>{n.contains(a==null?void 0:a.target)||this.onKeyDown()}}),this.tooltipTrigger===1&&([this.tooltipFocusInListener,this.tooltipFocusOutListener]=this.addManagedElementListeners(n,{focusin:this.onTooltipFocusIn.bind(this),focusout:this.onTooltipFocusOut.bind(this)}))),this.eventSvc.dispatchEvent({type:"tooltipShow",tooltipGui:n,parentGui:this.tooltipCtrl.getGui()}),this.startHideTimeout()}onTooltipMouseEnter(){this.isInteractingWithTooltip=!0,this.unlockService()}onTooltipMouseLeave(){this.isTooltipFocused()||(this.isInteractingWithTooltip=!1,this.lockService())}onTooltipFocusIn(){this.isInteractingWithTooltip=!0}isTooltipFocused(){var r;const e=(r=this.tooltipComp)==null?void 0:r.getGui(),t=Ke(this.beans);return!!e&&e.contains(t)}onTooltipFocusOut(e){const t=this.tooltipCtrl.getGui();this.isTooltipFocused()||(this.isInteractingWithTooltip=!1,t.contains(e.relatedTarget)?this.startHideTimeout():this.hideTooltip())}positionTooltip(){var t,r;const e={type:"tooltip",ePopup:this.tooltipComp.getGui(),nudgeY:18,skipObserver:this.tooltipMouseTrack};this.lastMouseEvent?(t=this.popupSvc)==null||t.positionPopupUnderMouseEvent({...e,mouseEvent:this.lastMouseEvent}):(r=this.popupSvc)==null||r.positionPopupByComponent({...e,eventSource:this.tooltipCtrl.getGui(),position:"under",keepWithinBounds:!0,nudgeY:5})}destroyTooltipComp(){this.tooltipComp.getGui().classList.add("ag-tooltip-hiding");const e=this.tooltipPopupDestroyFunc,t=this.tooltipComp,r=this.tooltipTrigger===0?tB:0;window.setTimeout(()=>{e(),this.destroyBean(t)},r),this.clearTooltipListeners(),this.tooltipPopupDestroyFunc=void 0,this.tooltipComp=void 0}clearTooltipListeners(){[this.tooltipMouseEnterListener,this.tooltipMouseLeaveListener,this.tooltipFocusInListener,this.tooltipFocusOutListener].forEach(e=>{e&&e()}),this.tooltipMouseEnterListener=this.tooltipMouseLeaveListener=this.tooltipFocusInListener=this.tooltipFocusOutListener=null}lockService(){Va=!0,this.interactiveTooltipTimeoutId=window.setTimeout(()=>{this.unlockService(),this.setToDoNothing()},qv)}unlockService(){Va=!1,this.clearInteractiveTimeout()}startHideTimeout(){this.clearHideTimeout(),this.hideTooltipTimeoutId=window.setTimeout(this.hideTooltip.bind(this),this.getTooltipDelay("hide"))}clearShowTimeout(){this.showTooltipTimeoutId&&(window.clearTimeout(this.showTooltipTimeoutId),this.showTooltipTimeoutId=void 0)}clearHideTimeout(){this.hideTooltipTimeoutId&&(window.clearTimeout(this.hideTooltipTimeoutId),this.hideTooltipTimeoutId=void 0)}clearInteractiveTimeout(){this.interactiveTooltipTimeoutId&&(window.clearTimeout(this.interactiveTooltipTimeoutId),this.interactiveTooltipTimeoutId=void 0)}clearTimeouts(){this.clearShowTimeout(),this.clearHideTimeout(),this.clearInteractiveTimeout()}};function wd(e){return e.get("tooltipShowMode")==="whenTruncated"}function Cl(e){return()=>{const t=e();return t?t.scrollWidth>t.clientWidth:!0}}var nB=class extends q{constructor(e,t){super(),this.ctrl=e,t&&(this.beans=t)}postConstruct(){this.refreshTooltip()}setBrowserTooltip(e){const t="title",r=this.ctrl.getGui();r&&(e!=null&&e!=""?r.setAttribute(t,e):r.removeAttribute(t))}updateTooltipText(){const{getTooltipValue:e}=this.ctrl;e&&(this.tooltip=e())}createTooltipFeatureIfNeeded(){this.tooltipManager==null&&(this.tooltipManager=this.createBean(new rB(this.ctrl,()=>this.tooltip),this.beans.context))}setTooltipAndRefresh(e){this.tooltip=e,this.refreshTooltip()}refreshTooltip(){this.browserTooltips=this.beans.gos.get("enableBrowserTooltips"),this.updateTooltipText(),this.browserTooltips?(this.setBrowserTooltip(this.tooltip),this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context)):(this.setBrowserTooltip(null),this.createTooltipFeatureIfNeeded())}destroy(){this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context),super.destroy()}},iB=class extends ct{constructor(e="default",t=!1){super({tag:"div",cls:`ag-list ag-${e}-list`}),this.cssIdentifier=e,this.unFocusable=t,this.activeClass="ag-active-item",this.options=[],this.itemEls=[]}postConstruct(){const e=this.getGui();this.addManagedElementListeners(e,{mouseleave:()=>this.clearHighlighted()}),!this.unFocusable&&this.addManagedElementListeners(e,{keydown:this.handleKeyDown.bind(this)})}handleKeyDown(e){const t=e.key;switch(t){case j.ENTER:if(!this.highlightedEl)this.setValue(this.getValue());else{const r=this.itemEls.indexOf(this.highlightedEl);this.setValueByIndex(r)}break;case j.DOWN:case j.UP:e.preventDefault(),this.navigate(t);break;case j.PAGE_DOWN:case j.PAGE_UP:case j.PAGE_HOME:case j.PAGE_END:e.preventDefault(),this.navigateToPage(t);break}}navigate(e){const t=e===j.DOWN;let r;const{itemEls:n,highlightedEl:i}=this;if(!i)r=n[t?0:n.length-1];else{let s=n.indexOf(i)+(t?1:-1);s=Math.min(Math.max(s,0),n.length-1),r=n[s]}this.highlightItem(r)}navigateToPage(e){const{itemEls:t,highlightedEl:r}=this;if(!r||t.length===0)return;const n=t.indexOf(r),i=this.options.length-1,o=t[0].clientHeight,s=Math.floor(this.getGui().clientHeight/o);let a=-1;e===j.PAGE_HOME?a=0:e===j.PAGE_END?a=i:e===j.PAGE_DOWN?a=Math.min(n+s,i):e===j.PAGE_UP&&(a=Math.max(n-s,0)),a!==-1&&this.highlightItem(t[a])}addOptions(e){return e.forEach(t=>this.addOption(t)),this}addOption(e){const{value:t,text:r}=e,n=r??t;return this.options.push({value:t,text:n}),this.renderOption(t,n),this.updateIndices(),this}clearOptions(){this.options=[],this.reset(!0),this.itemEls.forEach(e=>{jn(e)}),this.itemEls=[],this.refreshAriaRole()}refreshAriaRole(){const e=this.getGui();_i(e,this.options.length===0?"presentation":"listbox")}updateIndices(){const e=this.getGui().querySelectorAll(".ag-list-item");this.refreshAriaRole(),e.forEach((t,r)=>{Dk(t,r+1),Mk(t,e.length)})}renderOption(e,t){const r=lt({tag:"div",cls:`ag-list-item ag-${this.cssIdentifier}-list-item`,attrs:{role:"option"}}),n=lt({tag:"span",children:t});r.appendChild(n),this.unFocusable||(r.tabIndex=-1),this.itemEls.push(r),this.addManagedListeners(r,{mouseover:()=>this.highlightItem(r),mousedown:i=>{i.preventDefault(),i.stopPropagation(),this.setValue(e)}}),this.createOptionalManagedBean(this.beans.registry.createDynamicBean("tooltipFeature",!1,{getTooltipValue:()=>t,getGui:()=>r,getLocation:()=>"UNKNOWN",shouldDisplayTooltip:()=>n.scrollWidth>n.clientWidth})),this.getGui().appendChild(r)}setValue(e,t){if(this.value===e)return this.fireItemSelected(),this;if(e==null)return this.reset(t),this;const r=this.options.findIndex(n=>n.value===e);if(r!==-1){const n=this.options[r];this.value=n.value,this.displayValue=n.text,this.highlightItem(this.itemEls[r]),t||this.fireChangeEvent()}return this}setValueByIndex(e){return this.setValue(this.options[e].value)}getValue(){return this.value}getDisplayValue(){return this.displayValue}refreshHighlighted(){this.clearHighlighted();const e=this.options.findIndex(t=>t.value===this.value);e!==-1&&this.highlightItem(this.itemEls[e])}reset(e){this.value=null,this.displayValue=null,this.clearHighlighted(),e||this.fireChangeEvent()}highlightItem(e){if(!Sr(e))return;this.clearHighlighted(),this.highlightedEl=e,e.classList.add(this.activeClass),Rh(e,!0);const t=this.getGui(),{scrollTop:r,clientHeight:n}=t,{offsetTop:i,offsetHeight:o}=e;(i+o>r+n||i<r)&&e.scrollIntoView({block:"nearest"}),this.unFocusable||e.focus()}clearHighlighted(){const e=this.highlightedEl;!e||!Sr(e)||(e.classList.remove(this.activeClass),Rh(e,!1),this.highlightedEl=null)}fireChangeEvent(){this.dispatchLocalEvent({type:"fieldValueChanged"}),this.fireItemSelected()}fireItemSelected(){this.dispatchLocalEvent({type:"selectedItem"})}},oB=".ag-picker-field-display{flex:1 1 auto}.ag-picker-field{align-items:center;display:flex}.ag-picker-field-icon{border:0;cursor:pointer;display:flex;margin:0;padding:0}.ag-picker-field-wrapper{background-color:var(--ag-picker-button-background-color);border:var(--ag-picker-button-border);border-radius:5px;min-height:max(var(--ag-list-item-height),calc(var(--ag-spacing)*4));overflow:hidden;&:disabled{opacity:.5}&.ag-picker-has-focus,&:focus-within{background-color:var(--ag-picker-button-focus-background-color);border:var(--ag-picker-button-focus-border);box-shadow:var(--ag-focus-shadow)}}",sB={tag:"div",cls:"ag-picker-field",role:"presentation",children:[{tag:"div",ref:"eLabel"},{tag:"div",ref:"eWrapper",cls:"ag-wrapper ag-picker-field-wrapper ag-picker-collapsed",children:[{tag:"div",ref:"eDisplayField",cls:"ag-picker-field-display"},{tag:"div",ref:"eIcon",cls:"ag-picker-field-icon",attrs:{"aria-hidden":"true"}}]}]},aB=class extends rS{constructor(e){if(super(e,(e==null?void 0:e.template)||sB,(e==null?void 0:e.agComponents)||[],e==null?void 0:e.className),this.isPickerDisplayed=!1,this.skipClick=!1,this.pickerGap=4,this.hideCurrentPicker=null,this.eLabel=fe,this.eWrapper=fe,this.eDisplayField=fe,this.eIcon=fe,this.registerCSS(oB),this.ariaRole=e==null?void 0:e.ariaRole,this.onPickerFocusIn=this.onPickerFocusIn.bind(this),this.onPickerFocusOut=this.onPickerFocusOut.bind(this),!e)return;const{pickerGap:t,maxPickerHeight:r,variableWidth:n,minPickerWidth:i,maxPickerWidth:o}=e;t!=null&&(this.pickerGap=t),this.variableWidth=!!n,r!=null&&this.setPickerMaxHeight(r),i!=null&&this.setPickerMinWidth(i),o!=null&&this.setPickerMaxWidth(o)}postConstruct(){super.postConstruct(),this.setupAria();const e=`ag-${this.getCompId()}-display`;this.eDisplayField.setAttribute("id",e);const t=this.getAriaElement();this.addManagedElementListeners(t,{keydown:this.onKeyDown.bind(this)}),this.addManagedElementListeners(this.eLabel,{mousedown:this.onLabelOrWrapperMouseDown.bind(this)}),this.addManagedElementListeners(this.eWrapper,{mousedown:this.onLabelOrWrapperMouseDown.bind(this)});const{pickerIcon:r,inputWidth:n}=this.config;if(r){const i=Co(r,this.beans);i&&this.eIcon.appendChild(i)}n!=null&&this.setInputWidth(n)}setupAria(){const e=this.getAriaElement();e.setAttribute("tabindex",this.gos.get("tabIndex").toString()),Ph(e,!1),this.ariaRole&&_i(e,this.ariaRole)}onLabelOrWrapperMouseDown(e){if(e){const t=this.getFocusableElement();if(t!==this.eWrapper&&(e==null?void 0:e.target)===t)return;e.preventDefault(),this.getFocusableElement().focus()}if(this.skipClick){this.skipClick=!1;return}this.isDisabled()||(this.isPickerDisplayed?this.hidePicker():this.showPicker())}onKeyDown(e){switch(e.key){case j.UP:case j.DOWN:case j.ENTER:case j.SPACE:e.preventDefault(),this.onLabelOrWrapperMouseDown();break;case j.ESCAPE:this.isPickerDisplayed&&(e.preventDefault(),e.stopPropagation(),this.hideCurrentPicker&&this.hideCurrentPicker());break}}showPicker(){this.isPickerDisplayed=!0,this.pickerComponent||(this.pickerComponent=this.createPickerComponent());const e=this.pickerComponent.getGui();e.addEventListener("focusin",this.onPickerFocusIn),e.addEventListener("focusout",this.onPickerFocusOut),this.hideCurrentPicker=this.renderAndPositionPicker(),this.toggleExpandedStyles(!0)}renderAndPositionPicker(){const e=this.pickerComponent.getGui();this.gos.get("suppressScrollWhenPopupsAreOpen")||([this.destroyMouseWheelFunc]=this.addManagedEventListeners({bodyScroll:()=>{this.hidePicker()}}));const t=this.getLocaleTextFunc(),{config:{pickerAriaLabelKey:r,pickerAriaLabelValue:n,modalPicker:i=!0},maxPickerHeight:o,minPickerWidth:s,maxPickerWidth:a,variableWidth:l,beans:c,eWrapper:u}=this,d={modal:i,eChild:e,closeOnEsc:!0,closedCallback:()=>{const m=o1(c);this.beforeHidePicker(),m&&this.isAlive()&&this.getFocusableElement().focus()},ariaLabel:t(r,n),anchorToElement:u};e.style.position="absolute";const h=c.popupSvc,f=h.addPopup(d);l?(s&&(e.style.minWidth=s),e.style.width=ip(Tl(u)),a&&(e.style.maxWidth=a)):Ml(e,a??Tl(u));const g=o??`${rp(h.getPopupParent())}px`;return e.style.setProperty("max-height",g),this.alignPickerToComponent(),f.hideFunc}alignPickerToComponent(){if(!this.pickerComponent)return;const{pickerGap:e,config:{pickerType:t},beans:{popupSvc:r,gos:n},eWrapper:i,pickerComponent:o}=this,s=n.get("enableRtl")?"right":"left";r.positionPopupByComponent({type:t,eventSource:i,ePopup:o.getGui(),position:"under",alignSide:s,keepWithinBounds:!0,nudgeY:e})}beforeHidePicker(){this.destroyMouseWheelFunc&&(this.destroyMouseWheelFunc(),this.destroyMouseWheelFunc=void 0),this.toggleExpandedStyles(!1);const e=this.pickerComponent.getGui();e.removeEventListener("focusin",this.onPickerFocusIn),e.removeEventListener("focusout",this.onPickerFocusOut),this.isPickerDisplayed=!1,this.pickerComponent=void 0,this.hideCurrentPicker=null}toggleExpandedStyles(e){if(!this.isAlive())return;const t=this.getAriaElement();Ph(t,e);const r=this.eWrapper.classList;r.toggle("ag-picker-expanded",e),r.toggle("ag-picker-collapsed",!e)}onPickerFocusIn(){this.togglePickerHasFocus(!0)}onPickerFocusOut(e){var t;(t=this.pickerComponent)!=null&&t.getGui().contains(e.relatedTarget)||this.togglePickerHasFocus(!1)}togglePickerHasFocus(e){this.pickerComponent&&this.eWrapper.classList.toggle("ag-picker-has-focus",e)}hidePicker(){var e;(e=this.hideCurrentPicker)==null||e.call(this)}setInputWidth(e){return Ml(this.eWrapper,e),this}getFocusableElement(){return this.eWrapper}setPickerGap(e){return this.pickerGap=e,this}setPickerMinWidth(e){return typeof e=="number"&&(e=`${e}px`),this.minPickerWidth=e??void 0,this}setPickerMaxWidth(e){return typeof e=="number"&&(e=`${e}px`),this.maxPickerWidth=e??void 0,this}setPickerMaxHeight(e){return typeof e=="number"&&(e=`${e}px`),this.maxPickerHeight=e??void 0,this}destroy(){this.hidePicker(),super.destroy()}},lB=".ag-select{align-items:center;display:flex;&.ag-disabled{opacity:.5}}:where(.ag-select){.ag-picker-field-wrapper{cursor:default}&.ag-disabled .ag-picker-field-wrapper:focus{box-shadow:none}&:not(.ag-cell-editor,.ag-label-align-top){min-height:var(--ag-list-item-height)}.ag-picker-field-display{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ag-picker-field-icon{align-items:center;display:flex}}:where(.ag-ltr) :where(.ag-select){.ag-picker-field-wrapper{padding-left:calc(var(--ag-cell-horizontal-padding)/2);padding-right:var(--ag-spacing)}}:where(.ag-rtl) :where(.ag-select){.ag-picker-field-wrapper{padding-left:var(--ag-spacing);padding-right:calc(var(--ag-cell-horizontal-padding)/2)}}",cB=class extends aB{constructor(e){super({pickerAriaLabelKey:"ariaLabelSelectField",pickerAriaLabelValue:"Select Field",pickerType:"ag-list",className:"ag-select",pickerIcon:"selectOpen",ariaRole:"combobox",...e}),this.registerCSS(lB)}postConstruct(){this.tooltipFeature=this.createOptionalManagedBean(this.beans.registry.createDynamicBean("tooltipFeature",!1,{shouldDisplayTooltip:Cl(()=>this.eDisplayField),getGui:()=>this.getGui()})),super.postConstruct(),this.createListComponent(),this.eWrapper.tabIndex=this.gos.get("tabIndex");const{options:e,value:t,placeholder:r}=this.config;e!=null&&this.addOptions(e),t!=null&&this.setValue(t,!0),r&&t==null&&(this.eDisplayField.textContent=r),this.addManagedElementListeners(this.eWrapper,{focusout:this.onWrapperFocusOut.bind(this)})}onWrapperFocusOut(e){this.eWrapper.contains(e.relatedTarget)||this.hidePicker()}createListComponent(){const e=this.createBean(new iB("select",!0));this.listComponent=e,e.setParentComponent(this);const t=e.getAriaElement(),r=`ag-select-list-${e.getCompId()}`;t.setAttribute("id",r),Nk(this.getAriaElement(),t),e.addManagedElementListeners(e.getGui(),{mousedown:n=>{n==null||n.preventDefault()}}),e.addManagedListeners(e,{selectedItem:()=>{this.hidePicker(),this.dispatchLocalEvent({type:"selectedItem"})},fieldValueChanged:()=>{this.listComponent&&(this.setValue(this.listComponent.getValue(),!1,!0),this.hidePicker())}})}createPickerComponent(){return this.listComponent}onKeyDown(e){var r;const{key:t}=e;switch(t===j.TAB&&this.hidePicker(),t){case j.ENTER:case j.UP:case j.DOWN:case j.PAGE_UP:case j.PAGE_DOWN:case j.PAGE_HOME:case j.PAGE_END:e.preventDefault(),this.isPickerDisplayed?(r=this.listComponent)==null||r.handleKeyDown(e):super.onKeyDown(e);break;case j.ESCAPE:super.onKeyDown(e);break;case j.SPACE:this.isPickerDisplayed?e.preventDefault():super.onKeyDown(e);break}}showPicker(){const e=this.listComponent;e&&(super.showPicker(),e.refreshHighlighted())}addOptions(e){return e.forEach(t=>this.addOption(t)),this}addOption(e){return this.listComponent.addOption(e),this}clearOptions(){var e;return(e=this.listComponent)==null||e.clearOptions(),this.setValue(void 0,!0),this}setValue(e,t,r){const{listComponent:n,config:{placeholder:i},eDisplayField:o,tooltipFeature:s}=this;if(this.value===e||!n)return this;if(r||n.setValue(e,!0),n.getValue()===this.getValue())return this;let l=n.getDisplayValue();return l==null&&i&&(l=i),o.textContent=l,s==null||s.setTooltipAndRefresh(l??null),super.setValue(e,t)}destroy(){this.listComponent=this.destroyBean(this.listComponent),super.destroy()}},Sd={TAB_GUARD:"ag-tab-guard",TAB_GUARD_TOP:"ag-tab-guard-top",TAB_GUARD_BOTTOM:"ag-tab-guard-bottom"},uB=class extends q{constructor(e){super(),this.skipTabGuardFocus=!1,this.forcingFocusOut=!1,this.allowFocus=!1;const{comp:t,eTopGuard:r,eBottomGuard:n,focusTrapActive:i,forceFocusOutWhenTabGuardsAreEmpty:o,isFocusableContainer:s,focusInnerElement:a,onFocusIn:l,onFocusOut:c,shouldStopEventPropagation:u,onTabKeyDown:d,handleKeyDown:h,isEmpty:f,eFocusableElement:g}=e;this.comp=t,this.eTopGuard=r,this.eBottomGuard=n,this.providedFocusInnerElement=a,this.eFocusableElement=g,this.focusTrapActive=!!i,this.forceFocusOutWhenTabGuardsAreEmpty=!!o,this.isFocusableContainer=!!s,this.providedFocusIn=l,this.providedFocusOut=c,this.providedShouldStopEventPropagation=u,this.providedOnTabKeyDown=d,this.providedHandleKeyDown=h,this.providedIsEmpty=f}postConstruct(){this.createManagedBean(new bo(this.eFocusableElement,{shouldStopEventPropagation:()=>this.shouldStopEventPropagation(),onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e),onFocusIn:e=>this.onFocusIn(e),onFocusOut:e=>this.onFocusOut(e)})),this.activateTabGuards(),[this.eTopGuard,this.eBottomGuard].forEach(e=>this.addManagedElementListeners(e,{focus:this.onFocus.bind(this)}))}handleKeyDown(e){this.providedHandleKeyDown&&this.providedHandleKeyDown(e)}tabGuardsAreActive(){return!!this.eTopGuard&&this.eTopGuard.hasAttribute("tabIndex")}shouldStopEventPropagation(){return this.providedShouldStopEventPropagation?this.providedShouldStopEventPropagation():!1}activateTabGuards(){if(this.forcingFocusOut)return;const e=this.gos.get("tabIndex");this.comp.setTabIndex(e.toString())}deactivateTabGuards(){this.comp.setTabIndex()}onFocus(e){if(this.isFocusableContainer&&!this.eFocusableElement.contains(e.relatedTarget)&&!this.allowFocus){this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard);return}if(this.skipTabGuardFocus){this.skipTabGuardFocus=!1;return}if(this.forceFocusOutWhenTabGuardsAreEmpty&&(this.providedIsEmpty?this.providedIsEmpty():Ei(this.eFocusableElement,".ag-tab-guard").length===0)){this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard);return}if(this.isFocusableContainer&&this.eFocusableElement.contains(e.relatedTarget))return;const t=e.target===this.eBottomGuard;!(this.providedFocusInnerElement?this.providedFocusInnerElement(t):this.focusInnerElement(t))&&this.forceFocusOutWhenTabGuardsAreEmpty&&this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard)}findNextElementOutsideAndFocus(e){var l;const t=gt(this.beans),r=Ei(t.body,null,!0),n=r.indexOf(e?this.eTopGuard:this.eBottomGuard);if(n===-1)return;let i,o;e?(i=0,o=n):(i=n+1,o=r.length);const s=r.slice(i,o),a=this.gos.get("tabIndex");s.sort((c,u)=>{const d=parseInt(c.getAttribute("tabindex")||"0"),h=parseInt(u.getAttribute("tabindex")||"0");return h===a?1:d===a?-1:d===0?1:h===0?-1:d-h}),(l=s[e?s.length-1:0])==null||l.focus()}onFocusIn(e){this.focusTrapActive||this.forcingFocusOut||(this.providedFocusIn&&this.providedFocusIn(e),this.isFocusableContainer||this.deactivateTabGuards())}onFocusOut(e){this.focusTrapActive||(this.providedFocusOut&&this.providedFocusOut(e),this.eFocusableElement.contains(e.relatedTarget)||this.activateTabGuards())}onTabKeyDown(e){if(this.providedOnTabKeyDown){this.providedOnTabKeyDown(e);return}if(this.focusTrapActive||e.defaultPrevented)return;const t=this.tabGuardsAreActive();t&&this.deactivateTabGuards();const r=this.getNextFocusableElement(e.shiftKey);t&&setTimeout(()=>this.activateTabGuards(),0),r&&(r.focus(),e.preventDefault())}focusInnerElement(e=!1){const t=Ei(this.eFocusableElement);return this.tabGuardsAreActive()&&(t.splice(0,1),t.splice(t.length-1,1)),t.length?(t[e?t.length-1:0].focus({preventScroll:!0}),!0):!1}getNextFocusableElement(e){return yo(this.beans,this.eFocusableElement,!1,e)}forceFocusOutOfContainer(e=!1){if(this.forcingFocusOut)return;const t=e?this.eTopGuard:this.eBottomGuard;this.activateTabGuards(),this.skipTabGuardFocus=!0,this.forcingFocusOut=!0,t.focus(),window.setTimeout(()=>{this.forcingFocusOut=!1,this.activateTabGuards()})}isTabGuard(e,t){return e===this.eTopGuard&&!t||e===this.eBottomGuard&&(t??!0)}setAllowFocus(e){this.allowFocus=e}},dB=class extends ct{isPopup(){return!0}setParentComponent(e){e.addCss("ag-has-popup"),super.setParentComponent(e)}destroy(){const e=this.parentComponent;e&&e.isAlive()&&e.getGui().classList.remove("ag-has-popup"),super.destroy()}},wn=class{constructor(e,t=!1){this.DOUBLE_TAP_MILLIS=500,this.destroyFuncs=[],this.touching=!1,this.localEventService=new Wn,this.preventMouseClick=t;const r=this.onTouchStart.bind(this),n=this.onTouchMove.bind(this),i=this.onTouchEnd.bind(this);e.addEventListener("touchstart",r,{passive:!0}),e.addEventListener("touchmove",n,{passive:!0}),e.addEventListener("touchend",i,{passive:!1}),this.destroyFuncs.push(()=>{e.removeEventListener("touchstart",r,{passive:!0}),e.removeEventListener("touchmove",n,{passive:!0}),e.removeEventListener("touchend",i,{passive:!1})})}getActiveTouch(e){for(let t=0;t<e.length;t++)if(e[t].identifier===this.touchStart.identifier)return e[t];return null}addEventListener(e,t){this.localEventService.addEventListener(e,t)}removeEventListener(e,t){this.localEventService.removeEventListener(e,t)}onTouchStart(e){if(this.touching)return;this.touchStart=e.touches[0],this.touching=!0,this.moved=!1;const t=this.touchStart;window.setTimeout(()=>{const r=this.touchStart===t;if(this.touching&&r&&!this.moved){this.moved=!0;const n={type:"longTap",touchStart:this.touchStart,touchEvent:e};this.localEventService.dispatchEvent(n)}},500)}onTouchMove(e){if(!this.touching)return;const t=this.getActiveTouch(e.touches);if(!t)return;!N1(t,this.touchStart,4)&&(this.moved=!0)}onTouchEnd(e){if(this.touching){if(!this.moved){const t={type:"tap",touchStart:this.touchStart};this.localEventService.dispatchEvent(t),this.checkForDoubleTap()}this.preventMouseClick&&e.cancelable&&e.preventDefault(),this.touching=!1}}checkForDoubleTap(){const e=Date.now();if(this.lastTapTime&&this.lastTapTime>0)if(e-this.lastTapTime>this.DOUBLE_TAP_MILLIS){const r={type:"doubleTap",touchStart:this.touchStart};this.localEventService.dispatchEvent(r),this.lastTapTime=null}else this.lastTapTime=e;else this.lastTapTime=e}destroy(){this.destroyFuncs.forEach(e=>e())}},sS=class{constructor(e="javascript"){this.frameworkName=e,this.renderingEngine="vanilla",this.batchFrameworkComps=!1,this.wrapIncoming=t=>t(),this.wrapOutgoing=t=>t(),this.baseDocLink=`${J2}/${this.frameworkName}-data-grid`,Xk(this.baseDocLink)}setInterval(e,t){return new Ie(r=>{r(window.setInterval(e,t))})}addEventListener(e,t,r,n){let i={};if(typeof n=="object"?i=n:typeof n=="boolean"&&(i={capture:n}),i.passive==null){const o=f1(t);o!=null&&(i.passive=o)}e.addEventListener(t,r,i)}frameworkComponent(e){return null}isFrameworkComponent(e){return!1}getDocLink(e){return`${this.baseDocLink}${e?`/${e}`:""}`}};function hB(e){return{beanName:"gridApi",bean:e.getBean("apiFunctionSvc").api}}var fB=["licenseManager","environment","eventSvc","gos","paginationAutoPageSizeSvc","apiFunctionSvc","gridApi","registry","agCompUtils","userCompFactory","rowContainerHeight","horizontalResizeSvc","localeSvc","pinnedRowModel","dragSvc","colGroupSvc","visibleCols","popupSvc","selectionSvc","colFilter","quickFilter","filterManager","colModel","headerNavigation","pageBounds","pagination","pageBoundsListener","rowSpanSvc","stickyRowSvc","rowRenderer","expressionSvc","alignedGridsSvc","navigation","valueCache","valueSvc","autoWidthCalc","filterMenuFactory","dragAndDrop","focusSvc","cellNavigation","cellStyles","scrollVisibleSvc","sortSvc","colHover","colAnimation","autoColSvc","selectionColSvc","changeDetectionSvc","animationFrameSvc","undoRedo","colDefFactory","rowStyleSvc","rowNodeBlockLoader","rowNodeSorter","ctrlsSvc","pinnedCols","dataTypeSvc","syncSvc","overlays","stateSvc","expansionSvc","apiEventSvc","ariaAnnounce","menuSvc","colMoves","colAutosize","colFlex","colResize","pivotColsSvc","valueColsSvc","rowGroupColsSvc","funcColsSvc","colNames","colViewport","pivotResultCols","showRowGroupCols","validation"],Jv=Object.fromEntries(fB.map((e,t)=>[e,t]));function gB(e,t){const r=(e.beanName?Jv[e.beanName]:void 0)??Number.MAX_SAFE_INTEGER,n=(t.beanName?Jv[t.beanName]:void 0)??Number.MAX_SAFE_INTEGER;return r-n}function pB(e,t){return(e==null?void 0:e.beanName)==="gridDestroySvc"?-1:(t==null?void 0:t.beanName)==="gridDestroySvc"?1:0}var mB=class extends q{constructor(){super(...arguments),this.additionalFocusableContainers=new Set}setComp(e,t,r){this.view=e,this.eGridHostDiv=t,this.eGui=r,this.eGui.setAttribute("grid-id",this.beans.context.getGridId());const{dragAndDrop:n,ctrlsSvc:i}=this.beans;n==null||n.registerGridDropTarget(()=>this.eGui,this),L1(this.gos,t),this.createManagedBean(new gp(this.view)),this.view.setRtlClass(this.gos.get("enableRtl")?"ag-rtl":"ag-ltr");const o=fn(this.beans,this.eGridHostDiv,this.onGridSizeChanged.bind(this));this.addDestroyFunc(()=>o()),i.register("gridCtrl",this)}isDetailGrid(){var t;const e=k1(this.getGui());return((t=e==null?void 0:e.getAttribute("row-id"))==null?void 0:t.startsWith("detail"))||!1}getOptionalSelectors(){var t,r,n,i;const e=this.beans;return{paginationSelector:(t=e.pagination)==null?void 0:t.getPaginationSelector(),gridHeaderDropZonesSelector:e.registry.getSelector("AG-GRID-HEADER-DROP-ZONES"),sideBarSelector:(r=e.sideBar)==null?void 0:r.getSelector(),statusBarSelector:(n=e.registry)==null?void 0:n.getSelector("AG-STATUS-BAR"),watermarkSelector:(i=e.licenseManager)==null?void 0:i.getWatermarkSelector()}}onGridSizeChanged(){this.eventSvc.dispatchEvent({type:"gridSizeChanged",clientWidth:this.eGridHostDiv.clientWidth,clientHeight:this.eGridHostDiv.clientHeight})}destroyGridUi(){this.view.destroyGridUi()}getGui(){return this.eGui}setResizeCursor(e){this.view.setCursor(e?"ew-resize":null)}disableUserSelect(e){this.view.setUserSelect(e?"none":null)}focusNextInnerContainer(e){const t=this.getFocusableContainers(),{indexWithFocus:r,nextIndex:n}=this.getNextFocusableIndex(t,e);if(n<0||n>=t.length)return!1;if(n===0){if(r>0){const{visibleCols:i,focusSvc:o}=this.beans,s=i.allCols,a=Ee(s);if(o.focusGridView({column:a,backwards:!0}))return!0}return!1}return this.focusContainer(t[n],e)}focusInnerElement(e){const t=this.gos.getCallback("focusGridInnerElement");if(t&&t({fromBottom:!!e}))return!0;const r=this.getFocusableContainers(),{focusSvc:n,visibleCols:i}=this.beans,o=i.allCols;if(e){if(r.length>1)return this.focusContainer(Ee(r),e);const s=Ee(o);if(n.focusGridView({column:s,backwards:e}))return!0}if(this.gos.get("headerHeight")===0||Ln(this.beans)){if(n.focusGridView({column:o[0],backwards:e}))return!0;for(let s=1;s<r.length;s++)if(qn(r[s].getGui(),e))return!0;return!1}return n.focusFirstHeader()}forceFocusOutOfContainer(e=!1){this.view.forceFocusOutOfContainer(e)}addFocusableContainer(e){this.additionalFocusableContainers.add(e)}removeFocusableContainer(e){this.additionalFocusableContainers.delete(e)}allowFocusForNextCoreContainer(e){var o;const t=this.view.getFocusableContainers(),{nextIndex:r,indexWithFocus:n}=this.getNextFocusableIndex(t,e);if(n===-1||r<0||r>=t.length)return;const i=t[r];(o=i.setAllowFocus)==null||o.call(i,!0),setTimeout(()=>{var s;(s=i.setAllowFocus)==null||s.call(i,!1)})}isFocusable(){var t,r;const e=this.beans;return!dp(e)||!Ln(e)||!!((r=(t=e.sideBar)==null?void 0:t.comp)!=null&&r.isDisplayed())}getNextFocusableIndex(e,t){const r=Ke(this.beans),n=e.findIndex(o=>o.getGui().contains(r)),i=n+(t?-1:1);return{indexWithFocus:n,nextIndex:i}}focusContainer(e,t){var n,i;(n=e.setAllowFocus)==null||n.call(e,!0);const r=qn(e.getGui(),t,!1,!0);return(i=e.setAllowFocus)==null||i.call(e,!1),r}getFocusableContainers(){return[...this.view.getFocusableContainers(),...this.additionalFocusableContainers]}destroy(){this.additionalFocusableContainers.clear(),super.destroy()}},le=(e,t)=>{for(const r of Object.keys(t))t[r]=e;return t},Xv={dispatchEvent:"CommunityCore",...le("CommunityCore",{destroy:0,getGridId:0,getGridOption:0,isDestroyed:0,setGridOption:0,updateGridOptions:0,isModuleRegistered:0}),...le("GridState",{getState:0}),...le("SharedRowSelection",{setNodesSelected:0,selectAll:0,deselectAll:0,selectAllFiltered:0,deselectAllFiltered:0,selectAllOnCurrentPage:0,deselectAllOnCurrentPage:0,getSelectedNodes:0,getSelectedRows:0}),...le("RowApi",{redrawRows:0,setRowNodeExpanded:0,getRowNode:0,addRenderedRowListener:0,getRenderedNodes:0,forEachNode:0,getFirstDisplayedRowIndex:0,getLastDisplayedRowIndex:0,getDisplayedRowAtIndex:0,getDisplayedRowCount:0}),...le("ScrollApi",{getVerticalPixelRange:0,getHorizontalPixelRange:0,ensureColumnVisible:0,ensureIndexVisible:0,ensureNodeVisible:0}),...le("KeyboardNavigation",{getFocusedCell:0,clearFocusedCell:0,setFocusedCell:0,tabToNextCell:0,tabToPreviousCell:0,setFocusedHeader:0}),...le("EventApi",{addEventListener:0,addGlobalListener:0,removeEventListener:0,removeGlobalListener:0}),...le("ValueCache",{expireValueCache:0}),...le("CellApi",{getCellValue:0}),...le("SharedMenu",{showColumnMenu:0,hidePopupMenu:0}),...le("Sort",{onSortChanged:0}),...le("PinnedRow",{getPinnedTopRowCount:0,getPinnedBottomRowCount:0,getPinnedTopRow:0,getPinnedBottomRow:0,forEachPinnedRow:0}),...le("Overlay",{showLoadingOverlay:0,showNoRowsOverlay:0,hideOverlay:0}),...le("RenderApi",{setGridAriaProperty:0,refreshCells:0,refreshHeader:0,isAnimationFrameQueueEmpty:0,flushAllAnimationFrames:0,getSizesForCurrentTheme:0,getCellRendererInstances:0}),...le("HighlightChanges",{flashCells:0}),...le("RowDrag",{addRowDropZone:0,removeRowDropZone:0,getRowDropZoneParams:0}),...le("ColumnApi",{getColumnDefs:0,getColumnDef:0,getDisplayNameForColumn:0,getColumn:0,getColumns:0,applyColumnState:0,getColumnState:0,resetColumnState:0,isPinning:0,isPinningLeft:0,isPinningRight:0,getDisplayedColAfter:0,getDisplayedColBefore:0,setColumnsVisible:0,setColumnsPinned:0,getAllGridColumns:0,getDisplayedLeftColumns:0,getDisplayedCenterColumns:0,getDisplayedRightColumns:0,getAllDisplayedColumns:0,getAllDisplayedVirtualColumns:0}),...le("ColumnAutoSize",{sizeColumnsToFit:0,autoSizeColumns:0,autoSizeAllColumns:0}),...le("ColumnGroup",{setColumnGroupOpened:0,getColumnGroup:0,getProvidedColumnGroup:0,getDisplayNameForColumnGroup:0,getColumnGroupState:0,setColumnGroupState:0,resetColumnGroupState:0,getLeftDisplayedColumnGroups:0,getCenterDisplayedColumnGroups:0,getRightDisplayedColumnGroups:0,getAllDisplayedColumnGroups:0}),...le("ColumnMove",{moveColumnByIndex:0,moveColumns:0}),...le("ColumnResize",{setColumnWidths:0}),...le("ColumnHover",{isColumnHovered:0}),...le("EditCore",{getCellEditorInstances:0,getEditingCells:0,stopEditing:0,startEditingCell:0}),...le("UndoRedoEdit",{undoCellEditing:0,redoCellEditing:0,getCurrentUndoSize:0,getCurrentRedoSize:0}),...le("FilterCore",{isAnyFilterPresent:0,onFilterChanged:0}),...le("ColumnFilter",{isColumnFilterPresent:0,getColumnFilterInstance:0,destroyFilter:0,setFilterModel:0,getFilterModel:0,getColumnFilterModel:0,setColumnFilterModel:0,showColumnFilter:0}),...le("QuickFilter",{isQuickFilterPresent:0,getQuickFilter:0,resetQuickFilter:0}),...le("Find",{findGetActiveMatch:0,findGetTotalMatches:0,findGoTo:0,findNext:0,findPrevious:0,findGetNumMatches:0,findGetParts:0,findClearActive:0,findRefresh:0}),...le("Pagination",{paginationIsLastPageFound:0,paginationGetPageSize:0,paginationGetCurrentPage:0,paginationGetTotalPages:0,paginationGetRowCount:0,paginationGoToNextPage:0,paginationGoToPreviousPage:0,paginationGoToFirstPage:0,paginationGoToLastPage:0,paginationGoToPage:0}),...le("CsrmSsrmSharedApi",{expandAll:0,collapseAll:0,onRowHeightChanged:0}),...le("SsrmInfiniteSharedApi",{setRowCount:0,getCacheBlockState:0,isLastRowIndexKnown:0}),...le("ClientSideRowModelApi",{onGroupExpandedOrCollapsed:0,refreshClientSideRowModel:0,isRowDataEmpty:0,forEachLeafNode:0,forEachNodeAfterFilter:0,forEachNodeAfterFilterAndSort:0,resetRowHeights:0,applyTransaction:0,applyTransactionAsync:0,flushAsyncTransactions:0,getBestCostNodeSelection:0}),...le("CsvExport",{getDataAsCsv:0,exportDataAsCsv:0}),...le("InfiniteRowModel",{refreshInfiniteCache:0,purgeInfiniteCache:0,getInfiniteRowCount:0}),...le("AdvancedFilter",{getAdvancedFilterModel:0,setAdvancedFilterModel:0,showAdvancedFilterBuilder:0,hideAdvancedFilterBuilder:0}),...le("IntegratedCharts",{getChartModels:0,getChartRef:0,getChartImageDataURL:0,downloadChart:0,openChartToolPanel:0,closeChartToolPanel:0,createRangeChart:0,createPivotChart:0,createCrossFilterChart:0,updateChart:0,restoreChart:0}),...le("Clipboard",{copyToClipboard:0,cutToClipboard:0,copySelectedRowsToClipboard:0,copySelectedRangeToClipboard:0,copySelectedRangeDown:0,pasteFromClipboard:0}),...le("ExcelExport",{getDataAsExcel:0,exportDataAsExcel:0,getSheetDataForExcel:0,getMultipleSheetsAsExcel:0,exportMultipleSheetsAsExcel:0}),...le("SharedMasterDetail",{addDetailGridInfo:0,removeDetailGridInfo:0,getDetailGridInfo:0,forEachDetailGridInfo:0}),...le("ContextMenu",{showContextMenu:0}),...le("ColumnMenu",{showColumnChooser:0,hideColumnChooser:0}),...le("CellSelection",{getCellRanges:0,addCellRange:0,clearRangeSelection:0,clearCellSelection:0}),...le("SharedRowGrouping",{setRowGroupColumns:0,removeRowGroupColumns:0,addRowGroupColumns:0,getRowGroupColumns:0,moveRowGroupColumn:0}),...le("SharedAggregation",{addAggFuncs:0,clearAggFuncs:0,setColumnAggFunc:0}),...le("SharedPivot",{isPivotMode:0,getPivotResultColumn:0,setValueColumns:0,getValueColumns:0,removeValueColumns:0,addValueColumns:0,setPivotColumns:0,removePivotColumns:0,addPivotColumns:0,getPivotColumns:0,setPivotResultColumns:0,getPivotResultColumns:0}),...le("ServerSideRowModelApi",{getServerSideSelectionState:0,setServerSideSelectionState:0,applyServerSideTransaction:0,applyServerSideTransactionAsync:0,applyServerSideRowData:0,retryServerSideLoads:0,flushServerSideAsyncTransactions:0,refreshServerSide:0,getServerSideGroupLevelState:0}),...le("SideBar",{isSideBarVisible:0,setSideBarVisible:0,setSideBarPosition:0,openToolPanel:0,closeToolPanel:0,getOpenedToolPanel:0,refreshToolPanel:0,isToolPanelShowing:0,getToolPanelInstance:0,getSideBar:0}),...le("StatusBar",{getStatusPanel:0})},xd={isDestroyed:()=>!0,destroy(){},preConstruct(){},postConstruct(){},preWireBeans(){},wireBeans(){}},vB=(e,t)=>e.eventSvc.dispatchEvent(t),aS=class{};Reflect.defineProperty(aS,"name",{value:"GridApi"});var yB=class extends q{constructor(){super(),this.beanName="apiFunctionSvc",this.api=new aS,this.fns={...xd,dispatchEvent:vB},this.preDestroyLink="";const{api:e}=this;for(const t of Object.keys(Xv))e[t]=this.makeApi(t)[t]}postConstruct(){this.preDestroyLink=this.beans.frameworkOverrides.getDocLink("grid-lifecycle/#grid-pre-destroyed")}addFunction(e,t){var i;const{fns:r,beans:n}=this;r!==xd&&(r[e]=((i=n==null?void 0:n.validation)==null?void 0:i.validateApiFunction(e,t))??t)}makeApi(e){return{[e]:(...t)=>{const{beans:r,fns:{[e]:n}}=this;return n?n(r,...t):this.apiNotFound(e)}}}apiNotFound(e){const{beans:t,gos:r,preDestroyLink:n}=this;if(!t)Q(26,{fnName:e,preDestroyLink:n});else{const i=Xv[e];r.assertModuleRegistered(i,`api.${e}`)&&Q(27,{fnName:e,module:i})}}destroy(){super.destroy(),this.fns=xd,this.beans=null}};function bB(e){return e.context.getGridId()}function CB(e){e.gridDestroySvc.destroy()}function wB(e){return e.gridDestroySvc.destroyCalled}function SB(e,t){return e.gos.get(t)}function xB(e,t,r){lS(e,{[t]:r})}function lS(e,t){e.gos.updateGridOptions({options:t})}function AB(e,t){const r=t.replace(/Module$/,"");return e.gos.isModuleRegistered(r)}var PB=class extends q{constructor(){super(...arguments),this.beanName="horizontalResizeSvc"}addResizeBar(e){const t={dragStartPixels:e.dragStartPixels||0,eElement:e.eResizeBar,onDragStart:this.onDragStart.bind(this,e),onDragStop:this.onDragStop.bind(this,e),onDragging:this.onDragging.bind(this,e),onDragCancel:this.onDragStop.bind(this,e),includeTouch:!0,stopPropagationForTouch:!0},{dragSvc:r}=this.beans;return r.addDragSource(t),()=>r.removeDragSource(t)}onDragStart(e,t){this.dragStartX=t.clientX,this.setResizeIcons();const r=t instanceof MouseEvent&&t.shiftKey===!0;e.onResizeStart(r)}setResizeIcons(){const e=this.beans.ctrlsSvc.get("gridCtrl");e.setResizeCursor(!0),e.disableUserSelect(!0)}onDragStop(e){e.onResizeEnd(this.resizeAmount),this.resetIcons()}resetIcons(){const e=this.beans.ctrlsSvc.get("gridCtrl");e.setResizeCursor(!1),e.disableUserSelect(!1)}onDragging(e,t){this.resizeAmount=t.clientX-this.dragStartX,e.onResizing(this.resizeAmount)}},cS={moduleName:"Drag",version:he,beans:[xL]},RB={moduleName:"SharedDragAndDrop",version:he,beans:[vL],dependsOn:[cS],userComponents:{agDragAndDropImage:O3},icons:{columnMovePin:"pin",columnMoveHide:"eye-slash",columnMoveMove:"arrows",columnMoveLeft:"left",columnMoveRight:"right",columnMoveGroup:"group",columnMoveValue:"aggregation",columnMovePivot:"pivot",dropNotAllowed:"not-allowed",rowDrag:"grip"}},EB={moduleName:"HorizontalResize",version:he,beans:[PB],dependsOn:[cS]},TB=":where(.ag-ltr) :where(.ag-column-moving){.ag-cell,.ag-header-cell,.ag-spanned-cell-wrapper{transition:left .2s}.ag-header-group-cell{transition:left .2s,width .2s}}:where(.ag-rtl) :where(.ag-column-moving){.ag-cell,.ag-header-cell,.ag-spanned-cell-wrapper{transition:right .2s}.ag-header-group-cell{transition:right .2s,width .2s}}",FB=class extends q{constructor(){super(...arguments),this.beanName="colAnimation",this.executeNextFuncs=[],this.executeLaterFuncs=[],this.active=!1,this.activeNext=!1,this.suppressAnimation=!1,this.animationThreadCount=0}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>this.gridBodyCtrl=e.gridBodyCtrl)}isActive(){return this.active&&!this.suppressAnimation}setSuppressAnimation(e){this.suppressAnimation=e}start(){if(this.active)return;const{gos:e}=this;e.get("suppressColumnMoveAnimation")||e.get("enableRtl")||(this.ensureAnimationCssClassPresent(),this.active=!0,this.activeNext=!0)}finish(){this.active&&this.flush(()=>this.activeNext=!1,()=>this.active=!1)}executeNextVMTurn(e){this.activeNext?this.executeNextFuncs.push(e):e()}executeLaterVMTurn(e){this.active?this.executeLaterFuncs.push(e):e()}ensureAnimationCssClassPresent(){this.animationThreadCount++;const e=this.animationThreadCount,{gridBodyCtrl:t}=this;t.setColumnMovingCss(!0),this.executeLaterFuncs.push(()=>{this.animationThreadCount===e&&t.setColumnMovingCss(!1)})}flush(e,t){const{executeNextFuncs:r,executeLaterFuncs:n}=this;if(r.length===0&&n.length===0){e(),t();return}const i=o=>{for(;o.length;){const s=o.pop();s&&s()}};this.beans.frameworkOverrides.wrapIncoming(()=>{window.setTimeout(()=>{e(),i(r)},0),window.setTimeout(()=>{t(),i(n)},200)})}};function OB(e,t,r){var n;(n=e.colMoves)==null||n.moveColumnByIndex(t,r,"api")}function MB(e,t,r){var n;(n=e.colMoves)==null||n.moveColumns(t,r,"api")}var DB=class extends q{constructor(e){super(),this.pinned=e,this.columnsToAggregate=[],this.columnsToGroup=[],this.columnsToPivot=[]}onDragEnter(e){if(this.clearColumnsList(),this.gos.get("functionsReadOnly"))return;const t=e.dragItem.columns;t&&t.forEach(r=>{r.isPrimary()&&(r.isAnyFunctionActive()||(r.isAllowValue()?this.columnsToAggregate.push(r):r.isAllowRowGroup()?this.columnsToGroup.push(r):r.isAllowPivot()&&this.columnsToPivot.push(r)))})}getIconName(){return this.columnsToAggregate.length+this.columnsToGroup.length+this.columnsToPivot.length>0?this.pinned?"pinned":"move":null}onDragLeave(e){this.clearColumnsList()}clearColumnsList(){this.columnsToAggregate.length=0,this.columnsToGroup.length=0,this.columnsToPivot.length=0}onDragging(e){}onDragStop(e){const{valueColsSvc:t,rowGroupColsSvc:r,pivotColsSvc:n}=this.beans;this.columnsToAggregate.length>0&&(t==null||t.addColumns(this.columnsToAggregate,"toolPanelDragAndDrop")),this.columnsToGroup.length>0&&(r==null||r.addColumns(this.columnsToGroup,"toolPanelDragAndDrop")),this.columnsToPivot.length>0&&(n==null||n.addColumns(this.columnsToPivot,"toolPanelDragAndDrop"))}onDragCancel(){this.clearColumnsList()}};function kB(e,t){!t||t.length<=1||t.filter(n=>e.indexOf(n)<0).length>0||t.sort((n,i)=>{const o=e.indexOf(n),s=e.indexOf(i);return o-s})}function uS(e){const{isFromHeader:t,fromLeft:r,xPosition:n,fromEnter:i,fakeEvent:o,pinned:s,gos:a,colModel:l,colMoves:c,visibleCols:u}=e;let{allMovingColumns:d}=e;if(t){const C=[];d.forEach(S=>{var E;let A=null,P=S.getParent();for(;P!=null&&P.getDisplayedLeafColumns().length===1;)A=P,P=P.getParent();A!=null?(!!((E=A.getColGroupDef())!=null&&E.marryChildren)?A.getProvidedColumnGroup().getLeafColumns():A.getLeafColumns()).forEach(T=>{C.includes(T)||C.push(T)}):C.includes(S)||C.push(S)}),d=C}const h=d.slice();kB(l.getCols(),h);const f=BB({movingCols:h,draggingRight:r,xPosition:n,pinned:s,gos:a,colModel:l,visibleCols:u}),g=IB(h,l);if(f.length===0)return;const m=f[0];let p=g!==null&&!i;if(t&&(p=g!==null),p&&!o&&(!r&&m>=g||r&&m<=g))return;const y=u.allCols,w=[];let b=null;for(let C=0;C<f.length;C++){const S=f[C],A=c.getProposedColumnOrder(h,S);if(!c.doesOrderPassRules(A))continue;const P=A.filter(O=>y.includes(O));if(b===null)b=P;else if(!mo(P,b))break;const E=_B(A);w.push({move:S,fragCount:E})}if(w.length===0)return;w.sort((C,S)=>C.fragCount-S.fragCount);const x=w[0].move;if(!(x>l.getCols().length-d.length))return{columns:d,toIndex:x}}function dS(e){const{columns:t,toIndex:r}=uS(e)||{},{finished:n,colMoves:i}=e;return!t||r==null?null:(i.moveColumns(t,r,"uiColumnMoved",n),n?null:{columns:t,toIndex:r})}function IB(e,t){const r=t.getCols(),n=e.map(l=>r.indexOf(l)).sort((l,c)=>l-c),i=n[0];return Ee(n)-i!==n.length-1?null:i}function _B(e){function t(n){const i=[];let o=n.getOriginalParent();for(;o!=null;)i.push(o),o=o.getOriginalParent();return i}let r=0;for(let n=0;n<e.length-1;n++){let i=t(e[n]),o=t(e[n+1]);[i,o]=i.length>o.length?[i,o]:[o,i],i.forEach(s=>{o.indexOf(s)===-1&&r++})}return r}function LB(e,t){switch(t){case"left":return e.leftCols;case"right":return e.rightCols;default:return e.centerCols}}function BB(e){const{movingCols:t,draggingRight:r,xPosition:n,pinned:i,gos:o,colModel:s,visibleCols:a}=e;if(o.get("suppressMovableColumns")||t.some(b=>b.getColDef().suppressMovable))return[];const c=LB(a,i),u=s.getCols(),d=c.filter(b=>t.includes(b)),h=c.filter(b=>!t.includes(b)),f=u.filter(b=>!t.includes(b));let g=0,m=n;if(r){let b=0;d.forEach(x=>b+=x.getActualWidth()),m-=b}if(m>0){for(let b=0;b<h.length;b++){const x=h[b];if(m-=x.getActualWidth(),m<0)break;g++}r&&g++}let p;if(g>0){const b=h[g-1];p=f.indexOf(b)+1}else p=f.indexOf(h[0]),p===-1&&(p=0);const y=[p],w=(b,x)=>b-x;if(r){let b=p+1;const x=u.length-1;for(;b<=x;)y.push(b),b++;y.sort(w)}else{let b=p;const x=u.length-1;let C=u[b];for(;b<=x&&c.indexOf(C)<0;)b++,y.push(b),C=u[b];b=p-1;const S=0;for(;b>=S;)y.push(b),b--;y.sort(w).reverse()}return y}function Gh(e){var c;const{pinned:t,fromKeyboard:r,gos:n,ctrlsSvc:i,useHeaderRow:o,skipScrollPadding:s}=e;let a=(c=i.getHeaderRowContainerCtrl(t))==null?void 0:c.eViewport,{x:l}=e;return a?(r&&(l-=a.getBoundingClientRect().left),n.get("enableRtl")&&(o&&(a=a.querySelector(".ag-header-row")),l=a.clientWidth-l),t==null&&!s&&(l+=i.get("center").getCenterViewportScrollLeft()),l):0}function Ad(e,t){for(const r of e)r.moving=t,r.dispatchColEvent("movingChanged","uiColumnMoved")}var Zv=7,Wh=100,Ua=Wh/2,zB=5,NB=100,$B=class extends q{constructor(e){super(),this.pinned=e,this.needToMoveLeft=!1,this.needToMoveRight=!1,this.lastMovedInfo=null,this.isCenterContainer=!ie(e)}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCon=e.gridBodyCtrl})}getIconName(){const{pinned:e,lastDraggingEvent:t}=this,{dragItem:r}=t||{},n=(r==null?void 0:r.columns)??[];for(const i of n){const o=i.getPinned();if(i.getColDef().lockPinned){if(o==e)return"move";continue}const s=r==null?void 0:r.containerType;if(s===e||!e)return"move";if(e&&(!o||s!==e))return"pinned"}return"notAllowed"}onDragEnter(e){const t=e.dragItem,r=t.columns;if(e.dragSource.type===0)this.setColumnsVisible(r,!0,"uiColumnDragged");else{const i=t.visibleState,o=(r||[]).filter(s=>i[s.getId()]);this.setColumnsVisible(o,!0,"uiColumnDragged")}this.gos.get("suppressMoveWhenColumnDragging")||this.attemptToPinColumns(r,this.pinned),this.onDragging(e,!0,!0)}onDragging(e=this.lastDraggingEvent,t=!1,r=!1,n=!1){const{gos:i,ctrlsSvc:o}=this.beans,s=i.get("suppressMoveWhenColumnDragging");if(n&&!s){this.finishColumnMoving();return}if(this.lastDraggingEvent=e,!e||!n&&Xe(e.hDirection))return;const a=Gh({x:e.x,pinned:this.pinned,gos:i,ctrlsSvc:o});t||this.checkCenterForScrolling(a),s?this.handleColumnDragWhileSuppressingMovement(e,t,r,a,n):this.handleColumnDragWhileAllowingMovement(e,t,r,a,n)}onDragLeave(){this.ensureIntervalCleared(),this.clearHighlighted(),this.updateDragItemContainerType(),this.lastMovedInfo=null}onDragStop(){this.onDragging(this.lastDraggingEvent,!1,!0,!0),this.ensureIntervalCleared(),this.lastMovedInfo=null}onDragCancel(){this.clearHighlighted(),this.ensureIntervalCleared(),this.lastMovedInfo=null}setColumnsVisible(e,t,r){if(!e)return;const n=e.filter(i=>!i.getColDef().lockVisible);this.beans.colModel.setColsVisible(n,t,r)}finishColumnMoving(){this.clearHighlighted();const e=this.lastMovedInfo;if(!e)return;const{columns:t,toIndex:r}=e;this.beans.colMoves.moveColumns(t,r,"uiColumnMoved",!0)}updateDragItemContainerType(){const{lastDraggingEvent:e}=this;if(this.gos.get("suppressMoveWhenColumnDragging")||!e)return;const t=e.dragItem;t&&(t.containerType=this.pinned)}handleColumnDragWhileSuppressingMovement(e,t,r,n,i){const o=this.getAllMovingColumns(e,!0);if(i){const s=this.isAttemptingToPin(o);s&&this.attemptToPinColumns(o,void 0,!0);const{fromLeft:a,xPosition:l}=this.getNormalisedXPositionInfo(o,s)||{};if(a==null||l==null){this.finishColumnMoving();return}this.moveColumnsAfterHighlight({allMovingColumns:o,xPosition:l,fromEnter:t,fakeEvent:r,fromLeft:a})}else{if(!this.beans.dragAndDrop.isDropZoneWithinThisGrid(e))return;this.highlightHoveredColumn(o,n)}}handleColumnDragWhileAllowingMovement(e,t,r,n,i){const o=this.getAllMovingColumns(e),s=this.normaliseDirection(e.hDirection)==="right",a=e.dragSource.type===1,l=this.getMoveColumnParams({allMovingColumns:o,isFromHeader:a,xPosition:n,fromLeft:s,fromEnter:t,fakeEvent:r}),c=dS({...l,finished:i});c&&(this.lastMovedInfo=c)}getAllMovingColumns(e,t=!1){const r=e.dragSource.getDragItem();let n=null;t?(n=r.columnsInSplit,n||(n=r.columns)):n=r.columns;const i=o=>o.getColDef().lockPinned?o.getPinned()==this.pinned:!0;return n?n.filter(i):[]}getMoveColumnParams(e){const{allMovingColumns:t,isFromHeader:r,xPosition:n,fromLeft:i,fromEnter:o,fakeEvent:s}=e,{gos:a,colModel:l,colMoves:c,visibleCols:u}=this.beans;return{allMovingColumns:t,isFromHeader:r,fromLeft:i,xPosition:n,pinned:this.pinned,fromEnter:o,fakeEvent:s,gos:a,colModel:l,colMoves:c,visibleCols:u}}highlightHoveredColumn(e,t){var u;const{gos:r,colModel:n}=this.beans,i=r.get("enableRtl"),o=n.getCols().filter(d=>d.isVisible()&&d.getPinned()===this.pinned);let s=null,a=null,l=null;for(const d of o){if(a=d.getActualWidth(),s=this.getNormalisedColumnLeft(d,0,i),s!=null){const h=s+a;if(s<=t&&h>=t){l=d;break}}s=null,a=null}if(l)e.indexOf(l)!==-1&&(l=null);else{for(let d=o.length-1;d>=0;d--){const h=o[d],f=o[d].getParent();if(!f){l=h;break}const g=f==null?void 0:f.getDisplayedLeafColumns();if(g.length){l=Ee(g);break}}if(!l)return;s=this.getNormalisedColumnLeft(l,0,i),a=l.getActualWidth()}if(((u=this.lastHighlightedColumn)==null?void 0:u.column)!==l&&this.clearHighlighted(),l==null||s==null||a==null)return;let c;t-s<a/2!==i?c=0:c=1,Qv(l,c),this.lastHighlightedColumn={column:l,position:c}}getNormalisedXPositionInfo(e,t){const{gos:r,visibleCols:n}=this.beans,i=r.get("enableRtl"),{firstMovingCol:o,column:s,position:a}=this.getColumnMoveAndTargetInfo(e,t,i);if(!o||!s||a==null)return;const l=n.allCols,c=l.indexOf(o),u=l.indexOf(s),d=a===0!==i,h=c<u||c===u&&!d;let f=0;if(d?h&&(f-=1):h||(f+=1),u+f===c)return;const g=l[u+f];if(!g)return;const m=this.getNormalisedColumnLeft(g,20,i);return{fromLeft:h,xPosition:m}}getColumnMoveAndTargetInfo(e,t,r){const n=this.lastHighlightedColumn||{},{firstMovingCol:i,lastMovingCol:o}=HB(e);if(!i||!o||n.column||!t)return{firstMovingCol:i,...n};const a=this.getPinDirection()==="left";return{firstMovingCol:i,position:a?1:0,column:a!==r?i:o}}normaliseDirection(e){if(this.gos.get("enableRtl"))switch(e){case"left":return"right";case"right":return"left"}return e}getNormalisedColumnLeft(e,t,r){const{gos:n,ctrlsSvc:i}=this.beans,o=e.getLeft();if(o==null)return null;const s=e.getActualWidth();return Gh({x:r?o+s-t:o+t,pinned:e.getPinned(),useHeaderRow:r,skipScrollPadding:!0,gos:n,ctrlsSvc:i})}isAttemptingToPin(e){const t=this.needToMoveLeft||this.needToMoveRight,r=this.failedMoveAttempts>Zv;return t&&r||e.some(n=>n.getPinned()!==this.pinned)}moveColumnsAfterHighlight(e){const{allMovingColumns:t,xPosition:r,fromEnter:n,fakeEvent:i,fromLeft:o}=e,s=this.getMoveColumnParams({allMovingColumns:t,isFromHeader:!0,xPosition:r,fromLeft:o,fromEnter:n,fakeEvent:i}),{columns:a,toIndex:l}=uS(s)||{};a&&l!=null&&(this.lastMovedInfo={columns:a,toIndex:l}),this.finishColumnMoving()}clearHighlighted(){const{lastHighlightedColumn:e}=this;e&&(Qv(e.column,null),this.lastHighlightedColumn=null)}checkCenterForScrolling(e){if(!this.isCenterContainer)return;const t=this.beans.ctrlsSvc.get("center"),r=t.getCenterViewportScrollLeft(),n=r+t.getCenterWidth();let i,o;this.gos.get("enableRtl")?(i=e<r+Ua,o=e>n-Ua):(o=e<r+Ua,i=e>n-Ua),this.needToMoveRight=i,this.needToMoveLeft=o,o||i?this.ensureIntervalStarted():this.ensureIntervalCleared()}ensureIntervalStarted(){var e;this.movingIntervalId||(this.intervalCount=0,this.failedMoveAttempts=0,this.movingIntervalId=window.setInterval(this.moveInterval.bind(this),NB),(e=this.beans.dragAndDrop.getDragAndDropImageComponent())==null||e.setIcon(this.needToMoveLeft?"left":"right",!0))}ensureIntervalCleared(){var e;this.movingIntervalId&&(window.clearInterval(this.movingIntervalId),this.movingIntervalId=null,this.failedMoveAttempts=0,(e=this.beans.dragAndDrop.getDragAndDropImageComponent())==null||e.setIcon(this.getIconName(),!1))}moveInterval(){var n,i;let e;this.intervalCount++,e=10+this.intervalCount*zB,e>Wh&&(e=Wh);let t=null;const r=this.gridBodyCon.scrollFeature;if(this.needToMoveLeft?t=r.scrollHorizontally(-e):this.needToMoveRight&&(t=r.scrollHorizontally(e)),t!==0)this.onDragging(this.lastDraggingEvent),this.failedMoveAttempts=0;else{this.failedMoveAttempts++;const{pinnedCols:o,dragAndDrop:s,gos:a}=this.beans;if(this.failedMoveAttempts<=Zv+1||!o)return;if((n=s.getDragAndDropImageComponent())==null||n.setIcon("pinned",!1),!a.get("suppressMoveWhenColumnDragging")){const l=(i=this.lastDraggingEvent)==null?void 0:i.dragItem.columns;this.attemptToPinColumns(l,void 0,!0)}}}getPinDirection(){if(this.needToMoveLeft||this.pinned==="left")return"left";if(this.needToMoveRight||this.pinned==="right")return"right"}attemptToPinColumns(e,t,r=!1){const n=(e||[]).filter(s=>!s.getColDef().lockPinned);if(!n.length)return 0;r&&(t=this.getPinDirection());const{pinnedCols:i,dragAndDrop:o}=this.beans;return i==null||i.setColsPinned(n,t,"uiColumnDragged"),r&&o.nudge(),n.length}destroy(){super.destroy(),this.lastDraggingEvent=null,this.clearHighlighted(),this.lastMovedInfo=null}};function Qv(e,t){e.highlighted!==t&&(e.highlighted=t,e.dispatchColEvent("headerHighlightChanged","uiColumnMoved"))}function HB(e){const t=e.length;let r,n;for(let i=0;i<t;i++){if(!r){const o=e[i];o.getLeft()!=null&&(r=o)}if(!n){const o=e[t-1-i];o.getLeft()!=null&&(n=o)}if(r&&n)break}return{firstMovingCol:r,lastMovingCol:n}}var GB=class extends q{constructor(e,t){super(),this.pinned=e,this.eContainer=t}postConstruct(){const{ctrlsSvc:e,dragAndDrop:t}=this.beans,r=this.pinned;e.whenReady(this,n=>{let i;const o=n.gridBodyCtrl.eBodyViewport;switch(r){case"left":i=[[o,n.left.eContainer],[n.bottomLeft.eContainer],[n.topLeft.eContainer]];break;case"right":i=[[o,n.right.eContainer],[n.bottomRight.eContainer],[n.topRight.eContainer]];break;default:i=[[o,n.center.eViewport],[n.bottomCenter.eViewport],[n.topCenter.eViewport]];break}this.eSecondaryContainers=i}),this.moveColumnFeature=this.createManagedBean(new $B(r)),this.bodyDropPivotTarget=this.createManagedBean(new DB(r)),t.addDropTarget(this),this.addDestroyFunc(()=>t.removeDropTarget(this))}isInterestedIn(e){return e===1||e===0&&this.gos.get("allowDragFromColumnsToolPanel")}getSecondaryContainers(){return this.eSecondaryContainers}getContainer(){return this.eContainer}getIconName(){return this.currentDropListener.getIconName()}isDropColumnInPivotMode(e){return this.beans.colModel.isPivotMode()&&e.dragSource.type===0}onDragEnter(e){this.currentDropListener=this.isDropColumnInPivotMode(e)?this.bodyDropPivotTarget:this.moveColumnFeature,this.currentDropListener.onDragEnter(e)}onDragLeave(e){this.currentDropListener.onDragLeave(e)}onDragging(e){this.currentDropListener.onDragging(e)}onDragStop(e){this.currentDropListener.onDragStop(e)}onDragCancel(){this.currentDropListener.onDragCancel()}},WB=class extends q{constructor(){super(...arguments),this.beanName="colMoves"}moveColumnByIndex(e,t,r){const n=this.beans.colModel.getCols();if(!n)return;const i=n[e];this.moveColumns([i],t,r)}moveColumns(e,t,r,n=!0){const{colModel:i,colAnimation:o,visibleCols:s,eventSvc:a}=this.beans,l=i.getCols();if(!l)return;if(t>l.length-e.length){Q(30,{toIndex:t});return}o==null||o.start();const c=i.getColsForKeys(e);this.doesMovePassRules(c,t)&&(Fv(i.getCols(),c,t),s.refresh(r),a.dispatchEvent({type:"columnMoved",columns:c,column:c.length===1?c[0]:null,toIndex:t,finished:n,source:r})),o==null||o.finish()}doesMovePassRules(e,t){const r=this.getProposedColumnOrder(e,t);return this.doesOrderPassRules(r)}doesOrderPassRules(e){const{colModel:t,gos:r}=this.beans;return!(!S1(e,t.getColTree())||!(i=>{const o=c=>c?c==="left"||c===!0?-1:1:0,s=r.get("enableRtl");let a=s?1:-1,l=!0;return i.forEach(c=>{const u=o(c.getColDef().lockPosition);s?u>a&&(l=!1):u<a&&(l=!1),a=u}),l})(e))}getProposedColumnOrder(e,t){const n=this.beans.colModel.getCols().slice();return Fv(n,e,t),n}createBodyDropTarget(e,t){return new GB(e,t)}moveHeader(e,t,r,n,i){const{ctrlsSvc:o,gos:s,colModel:a,visibleCols:l,focusSvc:c}=this.beans,u=t.getBoundingClientRect(),d=u.left,h=je(r),f=h?u.width:r.getActualWidth(),g=e==="left"!==s.get("enableRtl"),m=Gh({x:g?d-20:d+f+20,pinned:n,fromKeyboard:!0,gos:s,ctrlsSvc:o}),p=c.focusedHeader;dS({allMovingColumns:h?r.getLeafColumns():[r],isFromHeader:!0,fromLeft:e==="right",xPosition:m,pinned:n,fromEnter:!1,fakeEvent:!1,gos:s,colModel:a,colMoves:this,visibleCols:l,finished:!0});let y;if(h){const w=r.getDisplayedLeafColumns();y=g?w[0]:Ee(w)}else y=r;if(o.getScrollFeature().ensureColumnVisible(y,"auto"),(!i.isAlive()||s.get("ensureDomOrder"))&&p){let w;if(h){const b=r.getGroupId(),x=r.getLeafColumns();if(!x.length)return;const C=x[0].getParent();if(!C)return;w=jB(C,b)}else w=r;w&&c.focusHeaderPosition({headerPosition:{...p,column:w}})}}setDragSourceForHeader(e,t,r){const{gos:n,colModel:i,dragAndDrop:o,visibleCols:s}=this.beans;let a=!n.get("suppressDragLeaveHidesColumns");const l=je(t),c=l?t.getProvidedColumnGroup().getLeafColumns():[t],d={type:1,eElement:e,getDefaultIconName:()=>a?"hide":"notAllowed",getDragItem:l?()=>UB(t,s.allCols):()=>VB(t),dragItemName:r,onDragStarted:()=>{a=!n.get("suppressDragLeaveHidesColumns"),Ad(c,!0)},onDragStopped:()=>Ad(c,!1),onDragCancelled:()=>Ad(c,!1),onGridEnter:h=>{if(a){const{columns:f=[],visibleState:g}=h??{},m=l?y=>!g||g[y.getColId()]:()=>!0,p=f.filter(y=>!y.getColDef().lockVisible&&m(y));i.setColsVisible(p,!0,"uiColumnMoved")}},onGridExit:h=>{var f;if(a){const g=((f=h==null?void 0:h.columns)==null?void 0:f.filter(m=>!m.getColDef().lockVisible))||[];i.setColsVisible(g,!1,"uiColumnMoved")}}};return o.addDragSource(d,!0),d}};function jB(e,t){for(;e;){if(e.getGroupId()===t)return e;e=e.getParent()}}function VB(e){const t={};return t[e.getId()]=e.isVisible(),{columns:[e],visibleState:t,containerType:e.pinned}}function UB(e,t){var a;const r=e.getProvidedColumnGroup().getLeafColumns(),n={};r.forEach(l=>n[l.getId()]=l.isVisible());const i=[];t.forEach(l=>{r.indexOf(l)>=0&&(i.push(l),Zt(r,l))}),r.forEach(l=>i.push(l));const o=[],s=e.getLeafColumns();for(const l of i)s.indexOf(l)!==-1&&o.push(l);return{columns:i,columnsInSplit:o,visibleState:n,containerType:(a=o[0])==null?void 0:a.pinned}}var KB={moduleName:"ColumnMove",version:he,beans:[WB,FB],apiFunctions:{moveColumnByIndex:OB,moveColumns:MB},dependsOn:[RB],css:[TB]},qB=class extends q{constructor(){super(...arguments),this.beanName="autoWidthCalc"}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.centerRowContainerCtrl=e.center})}getPreferredWidthForColumn(e,t){const r=this.getHeaderCellForColumn(e);if(!r)return-1;const n=this.beans.rowRenderer.getAllCellsNotSpanningForColumn(e);return t||n.push(r),this.getPreferredWidthForElements(n)}getPreferredWidthForColumnGroup(e){const t=this.getHeaderCellForColumn(e);return t?this.getPreferredWidthForElements([t]):-1}getPreferredWidthForElements(e,t){const r=document.createElement("form");r.style.position="fixed";const n=this.centerRowContainerCtrl.eContainer;e.forEach(o=>this.cloneItemIntoDummy(o,r)),n.appendChild(r);const i=r.offsetWidth;return n.removeChild(r),t=t??this.gos.get("autoSizePadding"),i+t}getHeaderCellForColumn(e){let t=null;return this.beans.ctrlsSvc.getHeaderRowContainerCtrls().forEach(r=>{const n=r.getHtmlElementForColumnHeader(e);n!=null&&(t=n)}),t}cloneItemIntoDummy(e,t){const r=e.cloneNode(!0);r.style.width="",r.style.position="static",r.style.left="";const n=document.createElement("div"),i=n.classList;["ag-header-cell","ag-header-group-cell"].some(a=>r.classList.contains(a))?(i.add("ag-header","ag-header-row"),n.style.position="static"):i.add("ag-row");let s=e.parentElement;for(;s;){if(["ag-header-row","ag-row"].some(l=>s.classList.contains(l))){for(let l=0;l<s.classList.length;l++){const c=s.classList[l];c!="ag-row-position-absolute"&&i.add(c)}break}s=s.parentElement}n.appendChild(r),t.appendChild(n)}},hS={moduleName:"AutoWidth",version:he,beans:[qB]};function YB(e,t,r=!0,n="api"){var i;(i=e.colResize)==null||i.setColumnWidths(t,!1,r,n)}var JB=class extends q{constructor(e,t,r,n){super(),this.comp=e,this.eResize=t,this.pinned=r,this.columnGroup=n}postConstruct(){if(!this.columnGroup.isResizable()){this.comp.setResizableDisplayed(!1);return}const{horizontalResizeSvc:e,gos:t,colAutosize:r}=this.beans,n=e.addResizeBar({eResizeBar:this.eResize,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this,!1),onResizeEnd:this.onResizing.bind(this,!0)});this.addDestroyFunc(n),!t.get("suppressAutoSize")&&r&&this.addDestroyFunc(r.addColumnGroupResize(this.eResize,this.columnGroup,()=>this.resizeLeafColumnsToFit("uiColumnResized")))}onResizeStart(e){const{columnsToResize:t,resizeStartWidth:r,resizeRatios:n,groupAfterColumns:i,groupAfterStartWidth:o,groupAfterRatios:s}=this.getInitialValues(e);this.resizeCols=t,this.resizeStartWidth=r,this.resizeRatios=n,this.resizeTakeFromCols=i,this.resizeTakeFromStartWidth=o,this.resizeTakeFromRatios=s,this.toggleColumnResizing(!0)}onResizing(e,t,r="uiColumnResized"){const n=this.normaliseDragChange(t),i=this.resizeStartWidth+n;this.resizeColumnsFromLocalValues(i,r,e)}getInitialValues(e){var l;const t=c=>c.reduce((u,d)=>u+d.getActualWidth(),0),r=(c,u)=>c.map(d=>d.getActualWidth()/u),n=this.getColumnsToResize(),i=t(n),o=r(n,i),s={columnsToResize:n,resizeStartWidth:i,resizeRatios:o};let a=null;if(e&&(a=((l=this.beans.colGroupSvc)==null?void 0:l.getGroupAtDirection(this.columnGroup,"After"))??null),a){const c=a.getDisplayedLeafColumns(),u=s.groupAfterColumns=c.filter(h=>h.isResizable()),d=s.groupAfterStartWidth=t(u);s.groupAfterRatios=r(u,d)}else s.groupAfterColumns=void 0,s.groupAfterStartWidth=void 0,s.groupAfterRatios=void 0;return s}resizeLeafColumnsToFit(e){const t=this.beans.autoWidthCalc.getPreferredWidthForColumnGroup(this.columnGroup),r=this.getInitialValues();t>r.resizeStartWidth&&this.resizeColumns(r,t,e,!0)}resizeColumnsFromLocalValues(e,t,r=!0){if(!this.resizeCols||!this.resizeRatios)return;const n={columnsToResize:this.resizeCols,resizeStartWidth:this.resizeStartWidth,resizeRatios:this.resizeRatios,groupAfterColumns:this.resizeTakeFromCols,groupAfterStartWidth:this.resizeTakeFromStartWidth,groupAfterRatios:this.resizeTakeFromRatios};this.resizeColumns(n,e,t,r)}resizeColumns(e,t,r,n=!0){var d;const{columnsToResize:i,resizeStartWidth:o,resizeRatios:s,groupAfterColumns:a,groupAfterStartWidth:l,groupAfterRatios:c}=e,u=[];if(u.push({columns:i,ratios:s,width:t}),a){const h=t-o;u.push({columns:a,ratios:c,width:l-h})}(d=this.beans.colResize)==null||d.resizeColumnSets({resizeSets:u,finished:n,source:r}),n&&this.toggleColumnResizing(!1)}toggleColumnResizing(e){this.comp.toggleCss("ag-column-resizing",e)}getColumnsToResize(){return this.columnGroup.getDisplayedLeafColumns().filter(t=>t.isResizable())}normaliseDragChange(e){let t=e;return this.gos.get("enableRtl")?this.pinned!=="left"&&(t*=-1):this.pinned==="right"&&(t*=-1),t}destroy(){super.destroy(),this.resizeCols=void 0,this.resizeRatios=void 0,this.resizeTakeFromCols=void 0,this.resizeTakeFromRatios=void 0}},XB=class extends q{constructor(e,t,r,n,i){super(),this.pinned=e,this.column=t,this.eResize=r,this.comp=n,this.ctrl=i}postConstruct(){const e=[];let t,r;const n=()=>{if(Je(this.eResize,t),!t)return;const{horizontalResizeSvc:s,colAutosize:a}=this.beans,l=s.addResizeBar({eResizeBar:this.eResize,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this,!1),onResizeEnd:this.onResizing.bind(this,!0)});e.push(l),r&&a&&e.push(a.addColumnAutosize(this.eResize,this.column))},i=()=>{e.forEach(s=>s()),e.length=0},o=()=>{const s=this.column.isResizable(),a=!this.gos.get("suppressAutoSize")&&!this.column.getColDef().suppressAutoSize;(s!==t||a!==r)&&(t=s,r=a,i(),n())};o(),this.addDestroyFunc(i),this.ctrl.setRefreshFunction("resize",o)}onResizing(e,t){const{column:r,lastResizeAmount:n,resizeStartWidth:i,beans:o}=this,s=this.normaliseResizeAmount(t),a=i+s,l=[{key:r,newWidth:a}],{pinnedCols:c,ctrlsSvc:u,colResize:d}=o;if(this.column.getPinned()){const h=(c==null?void 0:c.leftWidth)??0,f=(c==null?void 0:c.rightWidth)??0,g=As(u.getGridBodyCtrl().eBodyViewport)-50;if(h+f+(s-n)>g)return}this.lastResizeAmount=s,d==null||d.setColumnWidths(l,this.resizeWithShiftKey,e,"uiColumnResized"),e&&this.toggleColumnResizing(!1)}onResizeStart(e){this.resizeStartWidth=this.column.getActualWidth(),this.lastResizeAmount=0,this.resizeWithShiftKey=e,this.toggleColumnResizing(!0)}toggleColumnResizing(e){this.comp.toggleCss("ag-column-resizing",e)}normaliseResizeAmount(e){let t=e;const r=this.pinned!=="left",n=this.pinned==="right";return this.gos.get("enableRtl")?r&&(t*=-1):n&&(t*=-1),t}},ZB=class extends q{constructor(){super(...arguments),this.beanName="colResize"}setColumnWidths(e,t,r,n){const i=[],{colModel:o,gos:s,visibleCols:a}=this.beans;e.forEach(l=>{const c=o.getColDefCol(l.key)||o.getCol(l.key);if(!c)return;if(i.push({width:l.newWidth,ratios:[1],columns:[c]}),s.get("colResizeDefault")==="shift"&&(t=!t),t){const d=a.getColAfter(c);if(!d)return;const h=c.getActualWidth()-l.newWidth,f=d.getActualWidth()+h;i.push({width:f,ratios:[1],columns:[d]})}}),i.length!==0&&this.resizeColumnSets({resizeSets:i,finished:r,source:n})}resizeColumnSets(e){const{resizeSets:t,finished:r,source:n}=e;if(!(!t||t.every(u=>QB(u)))){if(r){const u=t&&t.length>0?t[0].columns:null;Bi(this.eventSvc,u,r,n)}return}const o=[],s=[];t.forEach(u=>{const{width:d,columns:h,ratios:f}=u,g={},m={};h.forEach(w=>s.push(w));let p=!0,y=0;for(;p;){if(y++,y>1e3){_e(31);break}p=!1;const w=[];let b=0,x=d;h.forEach((S,A)=>{if(m[S.getId()])x-=g[S.getId()];else{w.push(S);const E=f[A];b+=E}});const C=1/b;w.forEach((S,A)=>{const P=A===w.length-1;let E;P?E=x:(E=Math.round(f[A]*d*C),x-=E);const O=S.getMinWidth(),R=S.getMaxWidth();E<O?(E=O,m[S.getId()]=!0,p=!0):R>0&&E>R&&(E=R,m[S.getId()]=!0,p=!0),g[S.getId()]=E})}h.forEach(w=>{const b=g[w.getId()];w.getActualWidth()!==b&&(w.setActualWidth(b,n),o.push(w))})});const a=o.length>0;let l=[];if(a){const{colFlex:u,visibleCols:d,colViewport:h}=this.beans;l=(u==null?void 0:u.refreshFlexedColumns({resizingCols:s,skipSetLeft:!0}))??[],d.setLeftValues(n),d.updateBodyWidths(),h.checkViewportColumns()}const c=s.concat(l);(a||r)&&Bi(this.eventSvc,c,r,n,l)}resizeHeader(e,t,r){if(!e.isResizable())return;const n=e.getActualWidth(),i=e.getMinWidth(),o=e.getMaxWidth(),s=Math.min(Math.max(n+t,i),o);this.setColumnWidths([{key:e,newWidth:s}],r,!0,"uiColumnResized")}createResizeFeature(e,t,r,n,i){return new XB(e,t,r,n,i)}createGroupResizeFeature(e,t,r,n){return new JB(e,t,r,n)}};function QB(e){const{columns:t,width:r}=e;let n=0,i=0,o=!0;t.forEach(l=>{const c=l.getMinWidth();n+=c||0;const u=l.getMaxWidth();u>0?i+=u:o=!1});const s=r>=n,a=!o||r<=i;return s&&a}var e8={moduleName:"ColumnResize",version:he,beans:[ZB],apiFunctions:{setColumnWidths:YB},dependsOn:[EB,hS]},t8=class extends q{constructor(e,t){super(),this.removeChildListenersFuncs=[],this.columnGroup=t,this.comp=e}postConstruct(){this.addListenersToChildrenColumns(),this.addManagedListeners(this.columnGroup,{displayedChildrenChanged:this.onDisplayedChildrenChanged.bind(this)}),this.onWidthChanged(),this.addDestroyFunc(this.removeListenersOnChildrenColumns.bind(this))}addListenersToChildrenColumns(){this.removeListenersOnChildrenColumns();const e=this.onWidthChanged.bind(this);this.columnGroup.getLeafColumns().forEach(t=>{t.__addEventListener("widthChanged",e),t.__addEventListener("visibleChanged",e),this.removeChildListenersFuncs.push(()=>{t.__removeEventListener("widthChanged",e),t.__removeEventListener("visibleChanged",e)})})}removeListenersOnChildrenColumns(){this.removeChildListenersFuncs.forEach(e=>e()),this.removeChildListenersFuncs=[]}onDisplayedChildrenChanged(){this.addListenersToChildrenColumns(),this.onWidthChanged()}onWidthChanged(){const e=this.columnGroup.getActualWidth();this.comp.setWidth(`${e}px`),this.comp.toggleCss("ag-hidden",e===0)}},r8=class extends bp{constructor(){super(...arguments),this.onSuppressColMoveChange=()=>{!this.isAlive()||this.isSuppressMoving()?this.removeDragSource():this.dragSource||this.setDragSource(this.eGui)}}setComp(e,t,r,n,i){const{column:o,beans:s}=this,{context:a,colNames:l,colHover:c,rangeSvc:u,colResize:d}=s;this.comp=e,i=Aa(this,a,i),this.setGui(t,i),this.displayName=l.getDisplayNameForColumnGroup(o,"header"),this.refreshHeaderStyles(),this.addClasses(),this.setupMovingCss(i),this.setupExpandable(i),this.setupTooltip(),this.setupAutoHeight({wrapperElement:n,compBean:i}),this.setupUserComp(),this.addHeaderMouseListeners(i),this.addManagedPropertyListener("groupHeaderHeight",this.refreshMaxHeaderHeight.bind(this)),this.refreshMaxHeaderHeight();const h=this.rowCtrl.pinned,f=o.getProvidedColumnGroup().getLeafColumns();c==null||c.createHoverFeature(i,f,t),u==null||u.createRangeHighlightFeature(i,o,e),i.createManagedBean(new yp(o,t,s)),i.createManagedBean(new t8(e,o)),d?this.resizeFeature=i.createManagedBean(d.createGroupResizeFeature(e,r,h,o)):e.setResizableDisplayed(!1),i.createManagedBean(new bo(t,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:()=>{},handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)})),this.addHighlightListeners(i,f),i.addManagedPropertyListener("suppressMovableColumns",this.onSuppressColMoveChange),this.addResizeAndMoveKeyboardListeners(i),i.addDestroyFunc(()=>this.clearComponent())}getHeaderClassParams(){const{column:e,beans:t}=this,r=e.getDefinition();return pe(t.gos,{colDef:r,columnGroup:e,floatingFilter:!1})}refreshMaxHeaderHeight(){const{gos:e,comp:t}=this,r=e.get("groupHeaderHeight");r!=null?r===0?t.setHeaderWrapperHidden(!0):t.setHeaderWrapperMaxHeight(r):(t.setHeaderWrapperHidden(!1),t.setHeaderWrapperMaxHeight(null))}addHighlightListeners(e,t){if(this.beans.gos.get("suppressMoveWhenColumnDragging"))for(const r of t)e.addManagedListeners(r,{headerHighlightChanged:this.onLeafColumnHighlightChanged.bind(this,r)})}onLeafColumnHighlightChanged(e){const t=this.column.getDisplayedLeafColumns(),r=t[0]===e,n=Ee(t)===e;if(!r&&!n)return;const i=e.getHighlighted(),o=!!this.rowCtrl.getHeaderCellCtrls().find(l=>l.column.isMoving());let s=!1,a=!1;if(o){const l=this.beans.gos.get("enableRtl"),c=i===1,u=i===0;r&&(l?a=c:s=u),n&&(l?s=u:a=c)}this.comp.toggleCss("ag-header-highlight-before",s),this.comp.toggleCss("ag-header-highlight-after",a)}resizeHeader(e,t){const{resizeFeature:r}=this;if(!r)return;const n=r.getInitialValues(t);r.resizeColumns(n,n.resizeStartWidth+e,"uiColumnResized",!0)}resizeLeafColumnsToFit(e){var t;(t=this.resizeFeature)==null||t.resizeLeafColumnsToFit(e)}setupUserComp(){const{colGroupSvc:e,userCompFactory:t,gos:r,enterpriseMenuFactory:n}=this.beans,i=this.column,o=i.getProvidedColumnGroup(),s=pe(r,{displayName:this.displayName,columnGroup:i,setExpanded:l=>{e.setColumnGroupOpened(o,l,"gridInitializing")},setTooltip:(l,c)=>{r.assertModuleRegistered("Tooltip",3),this.setupTooltip(l,c)},showColumnMenu:(l,c)=>n==null?void 0:n.showMenuAfterButtonClick(o,l,"columnMenu",c),showColumnMenuAfterMouseClick:(l,c)=>n==null?void 0:n.showMenuAfterMouseEvent(o,l,"columnMenu",c),eGridHeader:this.eGui}),a=S_(t,s);a&&this.comp.setUserCompDetails(a)}addHeaderMouseListeners(e){const t=i=>this.handleMouseOverChange(i.type==="mouseenter"),r=()=>this.dispatchColumnMouseEvent("columnHeaderClicked",this.column.getProvidedColumnGroup()),n=i=>this.handleContextMenuMouseEvent(i,void 0,this.column.getProvidedColumnGroup());e.addManagedListeners(this.eGui,{mouseenter:t,mouseleave:t,click:r,contextmenu:n})}handleMouseOverChange(e){this.eventSvc.dispatchEvent({type:e?"columnHeaderMouseOver":"columnHeaderMouseLeave",column:this.column.getProvidedColumnGroup()})}setupTooltip(e,t){var r;this.tooltipFeature=(r=this.beans.tooltipSvc)==null?void 0:r.setupHeaderGroupTooltip(this.tooltipFeature,this,e,t)}setupExpandable(e){const t=this.column.getProvidedColumnGroup();this.refreshExpanded();const r=this.refreshExpanded.bind(this);e.addManagedListeners(t,{expandedChanged:r,expandableChanged:r})}refreshExpanded(){const{column:e}=this;this.expandable=e.isExpandable();const t=e.isExpanded();this.expandable?this.comp.setAriaExpanded(t?"true":"false"):this.comp.setAriaExpanded(void 0),this.refreshHeaderStyles()}addClasses(){const{column:e}=this,t=e.getColGroupDef(),r=M1(t,this.gos,null,e);e.isPadding()?(r.push("ag-header-group-cell-no-group"),e.getLeafColumns().every(i=>i.isSpanHeaderHeight())&&r.push("ag-header-span-height")):(r.push("ag-header-group-cell-with-group"),t!=null&&t.wrapHeaderText&&r.push("ag-header-cell-wrap-text")),r.forEach(n=>this.comp.toggleCss(n,!0))}setupMovingCss(e){const{column:t}=this,n=t.getProvidedColumnGroup().getLeafColumns(),i=()=>this.comp.toggleCss("ag-header-cell-moving",t.isMoving());n.forEach(o=>{e.addManagedListeners(o,{movingChanged:i})}),i()}onFocusIn(e){this.eGui.contains(e.relatedTarget)||this.focusThis()}handleKeyDown(e){super.handleKeyDown(e);const t=this.getWrapperHasFocus();if(!(!this.expandable||!t)&&e.key===j.ENTER){const r=this.column,n=!r.isExpanded();this.beans.colGroupSvc.setColumnGroupOpened(r.getProvidedColumnGroup(),n,"uiColumnExpanded")}}setDragSource(e){var t;!this.isAlive()||this.isSuppressMoving()||(this.removeDragSource(),e&&(this.dragSource=((t=this.beans.colMoves)==null?void 0:t.setDragSourceForHeader(e,this.column,this.displayName))??null))}isSuppressMoving(){return this.gos.get("suppressMovableColumns")||this.column.getLeafColumns().some(e=>e.getColDef().suppressMovable||e.getColDef().lockPosition)}destroy(){this.tooltipFeature=this.destroyBean(this.tooltipFeature),super.destroy()}};function n8(e,t,r){var n;(n=e.colGroupSvc)==null||n.setColumnGroupOpened(t,r,"api")}function i8(e,t,r){var n;return((n=e.colGroupSvc)==null?void 0:n.getColumnGroup(t,r))??null}function o8(e,t){var r;return((r=e.colGroupSvc)==null?void 0:r.getProvidedColGroup(t))??null}function s8(e,t,r){return e.colNames.getDisplayNameForColumnGroup(t,r)||""}function a8(e){var t;return((t=e.colGroupSvc)==null?void 0:t.getColumnGroupState())??[]}function l8(e,t){var r;(r=e.colGroupSvc)==null||r.setColumnGroupState(t,"api")}function c8(e){var t;(t=e.colGroupSvc)==null||t.resetColumnGroupState("api")}function u8(e){return e.visibleCols.treeLeft}function d8(e){return e.visibleCols.treeCenter}function h8(e){return e.visibleCols.treeRight}function f8(e){return e.visibleCols.getAllTrees()}function g8(e,t){for(let r=0;r<t.length;r++){const n=e.indexOf(t[r]);n>=0&&(e[n]=e[e.length-1],e.pop())}}var p8=class extends q{constructor(){super(...arguments),this.beanName="visibleCols",this.colsAndGroupsMap={},this.leftCols=[],this.rightCols=[],this.centerCols=[],this.allCols=[],this.bodyWidth=0,this.leftWidth=0,this.rightWidth=0,this.isBodyWidthDirty=!0}refresh(e,t=!1){const{colFlex:r,colModel:n,colGroupSvc:i,colViewport:o,selectionColSvc:s}=this.beans;t||this.buildTrees(n,i),i==null||i.updateOpenClosedVisibility(),this.leftCols=Pd(this.treeLeft),this.centerCols=Pd(this.treeCenter),this.rightCols=Pd(this.treeRight),s==null||s.refreshVisibility(this.leftCols,this.centerCols,this.rightCols),this.joinColsAriaOrder(n),this.joinCols(),this.setLeftValues(e),this.autoHeightCols=this.allCols.filter(a=>a.isAutoHeight()),r==null||r.refreshFlexedColumns(),this.updateBodyWidths(),o.checkViewportColumns(!1),this.setFirstRightAndLastLeftPinned(n,this.leftCols,this.rightCols,e),this.eventSvc.dispatchEvent({type:"displayedColumnsChanged",source:e})}updateBodyWidths(){const e=Mr(this.centerCols),t=Mr(this.leftCols),r=Mr(this.rightCols);this.isBodyWidthDirty=this.bodyWidth!==e,(this.bodyWidth!==e||this.leftWidth!==t||this.rightWidth!==r)&&(this.bodyWidth=e,this.leftWidth=t,this.rightWidth=r,this.eventSvc.dispatchEvent({type:"columnContainerWidthChanged"}),this.eventSvc.dispatchEvent({type:"displayedColumnsWidthChanged"}))}setLeftValues(e){this.setLeftValuesOfCols(e),this.setLeftValuesOfGroups()}setFirstRightAndLastLeftPinned(e,t,r,n){let i,o;this.gos.get("enableRtl")?(i=t?t[0]:null,o=r?Ee(r):null):(i=t?Ee(t):null,o=r?r[0]:null),e.getCols().forEach(s=>{s.setLastLeftPinned(s===i,n),s.setFirstRightPinned(s===o,n)})}buildTrees(e,t){const r=e.getColsToShow(),n=r.filter(l=>l.getPinned()=="left"),i=r.filter(l=>l.getPinned()=="right"),o=r.filter(l=>l.getPinned()!="left"&&l.getPinned()!="right"),s=new e_,a=l=>t?t.createColumnGroups(l):l.columns;this.treeLeft=a({columns:n,idCreator:s,pinned:"left",oldDisplayedGroups:this.treeLeft}),this.treeRight=a({columns:i,idCreator:s,pinned:"right",oldDisplayedGroups:this.treeRight}),this.treeCenter=a({columns:o,idCreator:s,pinned:null,oldDisplayedGroups:this.treeCenter}),this.updateColsAndGroupsMap()}clear(){this.leftCols=[],this.rightCols=[],this.centerCols=[],this.allCols=[],this.ariaOrderColumns=[]}joinColsAriaOrder(e){const t=e.getCols(),r=[],n=[],i=[];for(const o of t){const s=o.getPinned();s?s===!0||s==="left"?r.push(o):i.push(o):n.push(o)}this.ariaOrderColumns=r.concat(n).concat(i)}getAriaColIndex(e){let t;return je(e)?t=e.getLeafColumns()[0]:t=e,this.ariaOrderColumns.indexOf(t)+1}setLeftValuesOfGroups(){[this.treeLeft,this.treeRight,this.treeCenter].forEach(e=>{e.forEach(t=>{je(t)&&t.checkLeft()})})}setLeftValuesOfCols(e){const{colModel:t}=this.beans;if(!t.getColDefCols())return;const n=t.getCols().slice(0),i=this.gos.get("enableRtl");[this.leftCols,this.rightCols,this.centerCols].forEach(o=>{if(i){let s=Mr(o);o.forEach(a=>{s-=a.getActualWidth(),a.setLeft(s,e)})}else{let s=0;o.forEach(a=>{a.setLeft(s,e),s+=a.getActualWidth()})}g8(n,o)}),n.forEach(o=>{o.setLeft(null,e)})}joinCols(){this.gos.get("enableRtl")?this.allCols=this.rightCols.concat(this.centerCols).concat(this.leftCols):this.allCols=this.leftCols.concat(this.centerCols).concat(this.rightCols)}getAllTrees(){return this.treeLeft&&this.treeRight&&this.treeCenter?this.treeLeft.concat(this.treeCenter).concat(this.treeRight):null}isColDisplayed(e){return this.allCols.indexOf(e)>=0}getLeftColsForRow(e){const{leftCols:t,beans:{colModel:r}}=this;return r.colSpanActive?this.getColsForRow(e,t):t}getRightColsForRow(e){const{rightCols:t,beans:{colModel:r}}=this;return r.colSpanActive?this.getColsForRow(e,t):t}getColsForRow(e,t,r,n){const i=[];let o=null;for(let s=0;s<t.length;s++){const a=t[s],l=t.length-s,c=Math.min(a.getColSpan(e),l),u=[a];if(c>1){const h=c-1;for(let f=1;f<=h;f++)u.push(t[s+f]);s+=h}let d;r?(d=!1,u.forEach(h=>{r(h)&&(d=!0)})):d=!0,d&&(i.length===0&&o&&(n&&n(a))&&i.push(o),i.push(a)),o=a}return i}getContainerWidth(e){switch(e){case"left":return this.leftWidth;case"right":return this.rightWidth;default:return this.bodyWidth}}getColBefore(e){const t=this.allCols,r=t.indexOf(e);return r>0?t[r-1]:null}isPinningLeft(){return this.leftCols.length>0}isPinningRight(){return this.rightCols.length>0}updateColsAndGroupsMap(){this.colsAndGroupsMap={};const e=t=>{this.colsAndGroupsMap[t.getUniqueId()]=t};Bn(this.treeCenter,!1,e),Bn(this.treeLeft,!1,e),Bn(this.treeRight,!1,e)}isVisible(e){return this.colsAndGroupsMap[e.getUniqueId()]===e}getFirstColumn(){const e=this.gos.get("enableRtl"),t=["leftCols","centerCols","rightCols"];e&&t.reverse();for(let r=0;r<t.length;r++){const n=this[t[r]];if(n.length)return e?Ee(n):n[0]}return null}getColAfter(e){const t=this.allCols,r=t.indexOf(e);return r<t.length-1?t[r+1]:null}getColsLeftWidth(){return Mr(this.leftCols)}getDisplayedColumnsRightWidth(){return Mr(this.rightCols)}isColAtEdge(e,t){const r=this.allCols;if(!r.length)return!1;const n=t==="first";let i;if(je(e)){const o=e.getDisplayedLeafColumns();if(!o.length)return!1;i=n?o[0]:Ee(o)}else i=e;return(n?r[0]:Ee(r))===i}};function Bn(e,t,r){if(e)for(let n=0;n<e.length;n++){const i=e[n];if(je(i)){const o=t?i.getDisplayedChildren():i.getChildren();Bn(o,t,r)}r(i)}}function Pd(e){const t=[];return Bn(e,!0,r=>{$r(r)&&t.push(r)}),t}var m8=class extends q{constructor(){super(...arguments),this.beanName="colGroupSvc"}getColumnGroupState(){const e=[],t=this.beans.colModel.getColTree();return Br(null,t,r=>{ht(r)&&e.push({groupId:r.getGroupId(),open:r.isExpanded()})}),e}resetColumnGroupState(e){const t=this.beans.colModel.getColDefColTree();if(!t)return;const r=[];Br(null,t,n=>{if(ht(n)){const i=n.getColGroupDef(),o={groupId:n.getGroupId(),open:i?i.openByDefault:void 0};r.push(o)}}),this.setColumnGroupState(r,e)}setColumnGroupState(e,t){const{colModel:r,colAnimation:n,visibleCols:i,eventSvc:o}=this.beans;if(!r.getColTree().length)return;n==null||n.start();const a=[];e.forEach(l=>{const c=l.groupId,u=l.open,d=this.getProvidedColGroup(c);d&&d.isExpanded()!==u&&(d.setExpanded(u),a.push(d))}),i.refresh(t,!0),a.length&&o.dispatchEvent({type:"columnGroupOpened",columnGroup:a.length===1?a[0]:void 0,columnGroups:a}),n==null||n.finish()}setColumnGroupOpened(e,t,r){let n;ht(e)?n=e.getId():n=e||"",this.setColumnGroupState([{groupId:n,open:t}],r)}getProvidedColGroup(e){let t=null;return Br(null,this.beans.colModel.getColTree(),r=>{ht(r)&&r.getId()===e&&(t=r)}),t}getGroupAtDirection(e,t){const r=e.getProvidedColumnGroup().getLevel()+e.getPaddingLevel(),n=e.getDisplayedLeafColumns(),i=t==="After"?Ee(n):n[0],o=`getCol${t}`;for(;;){const s=this.beans.visibleCols[o](i);if(!s)return null;const a=this.getColGroupAtLevel(s,r);if(a!==e)return a}}getColGroupAtLevel(e,t){let r=e.getParent(),n,i;for(;n=r.getProvidedColumnGroup().getLevel(),i=r.getPaddingLevel(),!(n+i<=t);)r=r.getParent();return r}updateOpenClosedVisibility(){const e=this.beans.visibleCols.getAllTrees();Bn(e,!1,t=>{je(t)&&t.calculateDisplayedColumns()})}getColumnGroup(e,t){if(!e)return null;if(je(e))return e;const r=this.beans.visibleCols.getAllTrees(),n=typeof t=="number";let i=null;return Bn(r,!1,o=>{if(je(o)){const s=o;let a;n?a=e===s.getGroupId()&&t===s.getPartId():a=e===s.getGroupId(),a&&(i=s)}}),i}createColumnGroups(e){const{columns:t,idCreator:r,pinned:n,oldDisplayedGroups:i,isStandaloneStructure:o}=e,s=this.mapOldGroupsById(i),a=[];let l=t;for(;l.length;){const c=l;l=[];let u=0;const d=h=>{const f=u;u=h;const g=c[f],p=(je(g)?g.getProvidedColumnGroup():g).getOriginalParent();if(p==null){for(let w=f;w<h;w++)a.push(c[w]);return}const y=this.createColumnGroup(p,r,s,n,o);for(let w=f;w<h;w++)y.addChild(c[w]);l.push(y)};for(let h=1;h<c.length;h++){const f=c[h],m=(je(f)?f.getProvidedColumnGroup():f).getOriginalParent(),p=c[u],w=(je(p)?p.getProvidedColumnGroup():p).getOriginalParent();m!==w&&d(h)}u<c.length&&d(c.length)}return o||this.setupParentsIntoCols(a,null),a}createProvidedColumnGroup(e,t,r,n,i,o,s){const a=i.getUniqueKey(t.groupId||null,null),l=Ev(this.beans,t,a),c=new pl(l,a,!1,r);this.createBean(c);const u=this.findExistingGroup(t,o);u&&o.splice(u.idx,1);const d=u==null?void 0:u.group;d&&c.setExpanded(d.isExpanded());const h=b1(this.beans,l.children,r+1,e,n,i,o,s);return c.setChildren(h),c}balanceColumnTree(e,t,r,n){const i=[];for(let o=0;o<e.length;o++){const s=e[o];if(ht(s)){const a=s,l=this.balanceColumnTree(a.getChildren(),t+1,r,n);a.setChildren(l),i.push(a)}else{let a,l;for(let c=r-1;c>=t;c--){const u=n.getUniqueKey(null,null),d=Ev(this.beans,null,u),h=new pl(d,u,!0,t);this.createBean(h),l&&l.setChildren([h]),l=h,a||(a=l)}if(a&&l)if(i.push(a),e.some(u=>ht(u))){l.setChildren([s]);continue}else{l.setChildren(e);break}i.push(s)}}return i}findDepth(e){let t=0,r=e;for(;r&&r[0]&&ht(r[0]);)t++,r=r[0].getChildren();return t}findMaxDepth(e,t){let r=t;for(let n=0;n<e.length;n++){const i=e[n];if(ht(i)){const o=i,s=this.findMaxDepth(o.getChildren(),t+1);r<s&&(r=s)}}return r}balanceTreeForAutoCols(e,t){const r=[];return e.forEach(n=>{let i=n;for(let o=t-1;o>=0;o--){const s=new pl(null,`FAKE_PATH_${n.getId()}}_${o}`,!0,o);this.createBean(s),s.setChildren([i]),i.originalParent=s,i=s}t===0&&(n.originalParent=null),r.push(i)}),r}findExistingGroup(e,t){if(e.groupId!=null)for(let n=0;n<t.length;n++){const i=t[n];if(i.getColGroupDef()&&i.getId()===e.groupId)return{idx:n,group:i}}}createColumnGroup(e,t,r,n,i){const o=e.getGroupId(),s=t.getInstanceIdForKey(o),a=$1(o,s);let l=r[a];return l&&l.getProvidedColumnGroup()!==e&&(l=null),ie(l)?l.reset():(l=new H1(e,o,s,n),i||this.createBean(l)),l}mapOldGroupsById(e){const t={},r=n=>{n.forEach(i=>{if(je(i)){const o=i;t[i.getUniqueId()]=o,r(o.getChildren())}})};return e&&r(e),t}setupParentsIntoCols(e,t){e.forEach(r=>{if(r.parent=t,je(r)){const n=r;this.setupParentsIntoCols(n.getChildren(),n)}})}},v8={moduleName:"ColumnGroup",version:he,dynamicBeans:{headerGroupCellCtrl:r8},beans:[m8],apiFunctions:{getAllDisplayedColumnGroups:f8,getCenterDisplayedColumnGroups:d8,getColumnGroup:i8,getColumnGroupState:a8,getDisplayNameForColumnGroup:s8,getLeftDisplayedColumnGroups:u8,getProvidedColumnGroup:o8,getRightDisplayedColumnGroups:h8,resetColumnGroupState:c8,setColumnGroupOpened:n8,setColumnGroupState:l8}},y8={moduleName:"CheckboxCellRenderer",version:he,userComponents:{agCheckboxCellRenderer:L3}},b8=class extends q{constructor(){super(...arguments),this.beanName="colFlex"}refreshFlexedColumns(e={}){const t=e.source??"flex";e.viewportWidth!=null&&(this.flexViewportWidth=e.viewportWidth);const r=this.flexViewportWidth;if(!r)return[];const{visibleCols:n}=this.beans,i=n.centerCols;let o=-1;if(e.resizingCols){const g=new Set(e.resizingCols);for(let m=i.length-1;m>=0;m--)if(g.has(i[m])){o=m;break}}let s=!1;const a=i.map((g,m)=>{const p=g.getFlex(),y=p!=null&&p>0&&m>o;return s||(s=y),{col:g,isFlex:y,flex:Math.max(0,p??0),initialSize:g.getActualWidth(),min:g.getMinWidth(),max:g.getMaxWidth(),targetSize:0}});if(!s)return[];let l=a.length,c=a.reduce((g,m)=>g+m.flex,0),u=r;const d=(g,m)=>{g.frozenSize=m,g.col.setActualWidth(m,t),u-=m,c-=g.flex,l-=1},h=g=>g.frozenSize!=null;for(const g of a)g.isFlex||d(g,g.initialSize);for(;l>0;){const g=Math.round(c<1?u*c:u);let m,p=0,y=0;for(const x of a){if(h(x))continue;m=x,y+=g*(x.flex/c);const C=y-p,S=Math.round(C);x.targetSize=S,p+=S}m&&(m.targetSize+=g-p);let w=0;for(const x of a){if(h(x))continue;const C=x.targetSize,S=Math.min(Math.max(C,x.min),x.max);w+=S-C,x.violationType=S===C?void 0:S<C?"max":"min",x.targetSize=S}const b=w===0?"all":w>0?"min":"max";for(const x of a)h(x)||(b==="all"||x.violationType===b)&&d(x,x.targetSize)}e.skipSetLeft||n.setLeftValues(t),e.updateBodyWidths&&n.updateBodyWidths();const f=a.filter(g=>g.isFlex&&!g.violationType).map(g=>g.col);if(e.fireResizedEvent){const g=a.filter(p=>p.initialSize!==p.frozenSize).map(p=>p.col),m=a.filter(p=>p.flex).map(p=>p.col);Bi(this.eventSvc,g,!0,t,m)}return f}initCol(e){const{flex:t,initialFlex:r}=e.colDef;t!==void 0?e.flex=t:r!==void 0&&(e.flex=r)}setColFlex(e,t){e.flex=t??null,e.dispatchStateUpdatedEvent("flex")}},C8=class extends q{constructor(){super(...arguments),this.beanName="dataTypeSvc",this.dataTypeDefinitions={},this.isPendingInference=!1,this.isColumnTypeOverrideInDataTypeDefinitions=!1,this.columnStateUpdatesPendingInference={},this.columnStateUpdateListenerDestroyFuncs=[]}wireBeans(e){this.colModel=e.colModel}postConstruct(){this.processDataTypeDefinitions(),this.addManagedPropertyListener("dataTypeDefinitions",e=>{this.processDataTypeDefinitions(),this.colModel.recreateColumnDefs(e)})}processDataTypeDefinitions(){const e=this.getDefaultDataTypes(),t={};this.dataTypeDefinitions=t;const r={};this.formatValueFuncs=r;const n=s=>a=>{const{column:l,node:c,value:u}=a;let d=l.getColDef().valueFormatter;return d===s.groupSafeValueFormatter&&(d=s.valueFormatter),this.beans.valueSvc.formatValue(l,c,u,d)};for(const s of Object.keys(e)){const a=e[s],l={...a,groupSafeValueFormatter:ry(a,this.gos)};t[s]=l,r[s]=n(l)}const i=this.gos.get("dataTypeDefinitions")??{},o={};this.dataTypeMatchers=o;for(const s of Object.keys(i)){const a=i[s],l=this.processDataTypeDefinition(a,i,[s],e);l&&(t[s]=l,a.dataTypeMatcher&&(o[s]=a.dataTypeMatcher),r[s]=n(l))}this.checkObjectValueHandlers(e),["dateString","text","number","boolean","date"].forEach(s=>{const a=o[s];a&&delete o[s],o[s]=a??e[s].dataTypeMatcher})}processDataTypeDefinition(e,t,r,n){let i;const o=e.extendsDataType;if(e.columnTypes&&(this.isColumnTypeOverrideInDataTypeDefinitions=!0),e.extendsDataType===e.baseDataType){let s=n[o];const a=t[o];if(s&&a&&(s=a),!ty(e,s,o))return;i=ey(s,e)}else{if(r.includes(o)){Q(44);return}const s=t[o];if(!ty(e,s,o))return;const a=this.processDataTypeDefinition(s,t,[...r,o],n);if(!a)return;i=ey(a,e)}return{...i,groupSafeValueFormatter:ry(i,this.gos)}}updateColDefAndGetColumnType(e,t,r){let{cellDataType:n}=t;const{field:i}=t;if(n===void 0&&(n=e.cellDataType),(n==null||n===!0)&&(n=this.canInferCellDataType(e,t)?this.inferCellDataType(i,r):!1),!n){e.cellDataType=!1;return}const o=this.dataTypeDefinitions[n];if(!o){Q(47,{cellDataType:n});return}return e.cellDataType=n,o.groupSafeValueFormatter&&(e.valueFormatter=o.groupSafeValueFormatter),o.valueParser&&(e.valueParser=o.valueParser),o.suppressDefaultProperties||this.setColDefPropertiesForBaseDataType(e,n,o,r),o.columnTypes}addColumnListeners(e){if(!this.isPendingInference)return;const t=this.columnStateUpdatesPendingInference[e.getColId()];if(!t)return;const r=n=>{t.add(n.key)};e.__addEventListener("columnStateUpdated",r),this.columnStateUpdateListenerDestroyFuncs.push(()=>e.__removeEventListener("columnStateUpdated",r))}canInferCellDataType(e,t){const{gos:r}=this;if(!xt(r))return!1;const n={cellRenderer:!0,valueGetter:!0,valueParser:!0,refData:!0};if(Rd(t,n))return!1;const i=t.type===null?e.type:t.type;if(i){const o=r.get("columnTypes")??{};if(Bl(i).some(a=>{const l=o[a.trim()];return l&&Rd(l,n)}))return!1}return!Rd(e,n)}inferCellDataType(e,t){if(!e)return;let r;const n=this.getInitialData();if(n){const i=e.indexOf(".")>=0&&!this.gos.get("suppressFieldDotNotation");r=ls(n,e,i)}else this.initWaitForRowData(t);if(r!=null)return Object.keys(this.dataTypeMatchers).find(i=>this.dataTypeMatchers[i](r))??"object"}getInitialData(){var t;const e=this.gos.get("rowData");if(e!=null&&e.length)return e[0];if(this.initialData)return this.initialData;{const r=(t=this.beans.rowModel.rootNode)==null?void 0:t.allLeafChildren;if(r!=null&&r.length)return r[0].data}return null}initWaitForRowData(e){if(this.columnStateUpdatesPendingInference[e]=new Set,this.isPendingInference)return;this.isPendingInference=!0;const t=this.isColumnTypeOverrideInDataTypeDefinitions,{colAutosize:r,eventSvc:n}=this.beans;t&&r&&(r.shouldQueueResizeOperations=!0);const[i]=this.addManagedEventListeners({rowDataUpdateStarted:o=>{const{firstRowData:s}=o;s&&(i==null||i(),this.isPendingInference=!1,this.processColumnsPendingInference(s,t),this.columnStateUpdatesPendingInference={},t&&(r==null||r.processResizeOperations()),n.dispatchEvent({type:"dataTypesInferred"}))}})}processColumnsPendingInference(e,t){this.initialData=e;const r=[];this.destroyColumnStateUpdateListeners();const n={},i={};for(const o of Object.keys(this.columnStateUpdatesPendingInference)){const s=this.columnStateUpdatesPendingInference[o],a=this.colModel.getCol(o);if(!a)return;const l=a.getColDef();if(!this.resetColDefIntoCol(a,"cellDataTypeInferred"))return;const c=a.getColDef();if(t&&c.type&&c.type!==l.type){const u=S8(a,s);u.rowGroup&&u.rowGroupIndex==null&&(n[o]=u),u.pivot&&u.pivotIndex==null&&(i[o]=u),r.push(u)}}t&&r.push(...this.generateColumnStateForRowGroupAndPivotIndexes(n,i)),r.length&&cp(this.beans,{state:r},"cellDataTypeInferred"),this.initialData=null}generateColumnStateForRowGroupAndPivotIndexes(e,t){const r={},{rowGroupColsSvc:n,pivotColsSvc:i}=this.beans;return n==null||n.restoreColumnOrder(r,e),i==null||i.restoreColumnOrder(r,t),Object.values(r)}resetColDefIntoCol(e,t){const r=e.getUserProvidedColDef();if(!r)return!1;const n=_h(this.beans,r,e.getColId());return e.setColDef(n,r,t),!0}checkObjectValueHandlers(e){const t=this.dataTypeDefinitions.object,r=e.object;this.hasObjectValueParser=t.valueParser!==r.valueParser,this.hasObjectValueFormatter=t.valueFormatter!==r.valueFormatter}getDateStringTypeDefinition(e){const{dateString:t}=this.dataTypeDefinitions;return e?this.getDataTypeDefinition(e)??t:t}getDateParserFunction(e){return this.getDateStringTypeDefinition(e).dateParser}getDateFormatterFunction(e){return this.getDateStringTypeDefinition(e).dateFormatter}getDataTypeDefinition(e){const t=e.getColDef();if(t.cellDataType)return this.dataTypeDefinitions[t.cellDataType]}getBaseDataType(e){var t;return(t=this.getDataTypeDefinition(e))==null?void 0:t.baseDataType}checkType(e,t){var n;if(t==null)return!0;const r=(n=this.getDataTypeDefinition(e))==null?void 0:n.dataTypeMatcher;return r?r(t):!0}validateColDef(e){const t=r=>Q(48,{property:r});if(e.cellDataType==="object"){const{object:r}=this.dataTypeDefinitions;e.valueFormatter===r.groupSafeValueFormatter&&!this.hasObjectValueFormatter&&t("Formatter"),e.editable&&e.valueParser===r.valueParser&&!this.hasObjectValueParser&&t("Parser")}}getFormatValue(e){return this.formatValueFuncs[e]}isColPendingInference(e){return this.isPendingInference&&!!this.columnStateUpdatesPendingInference[e]}setColDefPropertiesForBaseDataType(e,t,r,n){var o;const i=this.formatValueFuncs[t];switch(r.baseDataType){case"number":{e.cellEditor="agNumberCellEditor";break}case"boolean":{e.cellEditor="agCheckboxCellEditor",e.cellRenderer="agCheckboxCellRenderer",e.getFindText=()=>null,e.suppressKeyboardEvent=s=>!!s.colDef.editable&&s.event.key===j.SPACE;break}case"date":{e.cellEditor="agDateCellEditor",e.keyCreator=i;break}case"dateString":{e.cellEditor="agDateStringCellEditor",e.keyCreator=i;break}case"object":{e.cellEditorParams={useFormatter:!0},e.comparator=(s,a)=>{const l=this.colModel.getColDefCol(n),c=l==null?void 0:l.getColDef();if(!l||!c)return 0;const u=s==null?"":i({column:l,node:null,value:s}),d=a==null?"":i({column:l,node:null,value:a});return u===d?0:u>d?1:-1},e.keyCreator=i;break}}(o=this.beans.filterManager)==null||o.setColDefPropertiesForDataType(e,r,i)}getDefaultDataTypes(){const e=r=>!!r.match("^\\d{4}-\\d{2}-\\d{2}$"),t=this.getLocaleTextFunc();return{number:{baseDataType:"number",valueParser:r=>{var n,i;return((i=(n=r.newValue)==null?void 0:n.trim)==null?void 0:i.call(n))===""?null:Number(r.newValue)},valueFormatter:r=>r.value==null?"":typeof r.value!="number"||isNaN(r.value)?t("invalidNumber","Invalid Number"):String(r.value),dataTypeMatcher:r=>typeof r=="number"},text:{baseDataType:"text",valueParser:r=>r.newValue===""?null:Oh(r.newValue),dataTypeMatcher:r=>typeof r=="string"},boolean:{baseDataType:"boolean",valueParser:r=>{var n,i;return r.newValue==null?r.newValue:((i=(n=r.newValue)==null?void 0:n.trim)==null?void 0:i.call(n))===""?null:String(r.newValue).toLowerCase()==="true"},valueFormatter:r=>r.value==null?"":String(r.value),dataTypeMatcher:r=>typeof r=="boolean"},date:{baseDataType:"date",valueParser:r=>Kv(r.newValue==null?null:String(r.newValue)),valueFormatter:r=>r.value==null?"":!(r.value instanceof Date)||isNaN(r.value.getTime())?t("invalidDate","Invalid Date"):Uv(r.value,!1)??"",dataTypeMatcher:r=>r instanceof Date},dateString:{baseDataType:"dateString",dateParser:r=>Kv(r)??void 0,dateFormatter:r=>Uv(r??null,!1)??void 0,valueParser:r=>e(String(r.newValue))?r.newValue:null,valueFormatter:r=>e(String(r.value))?r.value:"",dataTypeMatcher:r=>typeof r=="string"&&e(r)},object:{baseDataType:"object",valueParser:()=>null,valueFormatter:r=>Oh(r.value)??""}}}destroyColumnStateUpdateListeners(){this.columnStateUpdateListenerDestroyFuncs.forEach(e=>e()),this.columnStateUpdateListenerDestroyFuncs=[]}destroy(){this.dataTypeDefinitions={},this.dataTypeMatchers={},this.formatValueFuncs={},this.columnStateUpdatesPendingInference={},this.destroyColumnStateUpdateListeners(),super.destroy()}};function ey(e,t){const r={...e,...t};return e.columnTypes&&t.columnTypes&&t.appendColumnTypes&&(r.columnTypes=[...Bl(e.columnTypes),...Bl(t.columnTypes)]),r}function ty(e,t,r){return t?t.baseDataType!==e.baseDataType?(Q(46),!1):!0:(Q(45,{parentCellDataType:r}),!1)}function ry(e,t){if(e.valueFormatter)return r=>{var n,i;if((n=r.node)!=null&&n.group){const o=(r.colDef.pivotValueColumn??r.column).getAggFunc();if(o){if(o==="first"||o==="last")return e.valueFormatter(r);if(e.baseDataType==="number"&&o!=="count"){if(typeof r.value=="number")return e.valueFormatter(r);if(typeof r.value=="object"){if(!r.value)return;if("toNumber"in r.value)return e.valueFormatter({...r,value:r.value.toNumber()});if("value"in r.value)return e.valueFormatter({...r,value:r.value.value})}}return}if(t.get("groupDisplayType")==="groupRows"&&!t.get("treeData"))return}else if(t.get("groupHideOpenParents")&&r.column.isRowGroupActive()&&typeof r.value=="string"&&!((i=e.dataTypeMatcher)!=null&&i.call(e,r.value)))return;return e.valueFormatter(r)}}function w8(e,t,r,n){if(!t[r])return!1;const i=e[r];return i===null?(t[r]=!1,!1):n===void 0?!!i:i===n}function Rd(e,t){return[["cellRenderer","agSparklineCellRenderer"],["valueGetter",void 0],["valueParser",void 0],["refData",void 0]].some(([r,n])=>w8(e,t,r,n))}function S8(e,t){const r=YI(e);return t.forEach(n=>{delete r[n],n==="rowGroup"?delete r.rowGroupIndex:n==="pivot"&&delete r.pivotIndex}),r}var x8={moduleName:"DataType",version:he,beans:[C8],dependsOn:[y8]},A8={moduleName:"ColumnFlex",version:he,beans:[b8]};function P8(e){if(!e||e==null)return null;const t=/([a-z])([A-Z])/g,r=/([A-Z]+)([A-Z])([a-z])/g;return e.replace(t,"$1 $2").replace(r,"$1 $2$3").replace(/\./g," ").split(" ").map(i=>i.substring(0,1).toUpperCase()+(i.length>1?i.substring(1,i.length):"")).join(" ")}var R8=class extends q{constructor(){super(...arguments),this.beanName="colNames"}getDisplayNameForColumn(e,t,r=!1){if(!e)return null;const n=this.getHeaderName(e.getColDef(),e,null,null,t),{aggColNameSvc:i}=this.beans;return r&&i?i.getHeaderName(e,n):n}getDisplayNameForProvidedColumnGroup(e,t,r){const n=t==null?void 0:t.getColGroupDef();return n?this.getHeaderName(n,null,e,t,r):null}getDisplayNameForColumnGroup(e,t){return this.getDisplayNameForProvidedColumnGroup(e,e.getProvidedColumnGroup(),t)}getHeaderName(e,t,r,n,i){var s;const o=e.headerValueGetter;if(o){const a=pe(this.gos,{colDef:e,column:t,columnGroup:r,providedColumnGroup:n,location:i});return typeof o=="function"?o(a):typeof o=="string"?((s=this.beans.expressionSvc)==null?void 0:s.evaluate(o,a))??null:""}else{if(e.headerName!=null)return e.headerName;if(e.field)return P8(e.field)}return""}},E8=class extends q{constructor(){super(...arguments),this.beanName="colViewport",this.colsWithinViewport=[],this.headerColsWithinViewport=[],this.colsWithinViewportHash="",this.rowsOfHeadersToRenderLeft={},this.rowsOfHeadersToRenderRight={},this.rowsOfHeadersToRenderCenter={}}wireBeans(e){this.visibleCols=e.visibleCols,this.colModel=e.colModel}postConstruct(){this.suppressColumnVirtualisation=this.gos.get("suppressColumnVirtualisation")}setScrollPosition(e,t,r=!1){const{visibleCols:n}=this,i=n.isBodyWidthDirty;if(!(e===this.scrollWidth&&t===this.scrollPosition&&!i)){if(this.scrollWidth=e,this.scrollPosition=t,n.isBodyWidthDirty=!0,this.gos.get("enableRtl")){const s=n.bodyWidth;this.viewportLeft=s-t-e,this.viewportRight=s-t}else this.viewportLeft=t,this.viewportRight=e+t;this.colModel.ready&&this.checkViewportColumns(r)}}getHeadersToRender(e,t){let r;switch(e){case"left":r=this.rowsOfHeadersToRenderLeft[t];break;case"right":r=this.rowsOfHeadersToRenderRight[t];break;default:r=this.rowsOfHeadersToRenderCenter[t];break}return r||[]}extractViewportColumns(){const e=this.visibleCols.centerCols;this.isColumnVirtualisationSuppressed()?(this.colsWithinViewport=e,this.headerColsWithinViewport=e):(this.colsWithinViewport=e.filter(this.isColumnInRowViewport.bind(this)),this.headerColsWithinViewport=e.filter(this.isColumnInHeaderViewport.bind(this)))}isColumnVirtualisationSuppressed(){return this.suppressColumnVirtualisation||this.viewportRight===0}clear(e){this.rowsOfHeadersToRenderLeft={},this.rowsOfHeadersToRenderRight={},this.rowsOfHeadersToRenderCenter={},e||(this.colsWithinViewportHash="")}isColumnInHeaderViewport(e){return e.isAutoHeaderHeight()||T8(e)?!0:this.isColumnInRowViewport(e)}isColumnInRowViewport(e){if(e.isAutoHeight())return!0;const t=e.getLeft()||0,r=t+e.getActualWidth(),n=this.viewportLeft-200,i=this.viewportRight+200,o=t<n&&r<n,s=t>i&&r>i;return!o&&!s}getViewportColumns(){const{leftCols:e,rightCols:t}=this.visibleCols;return this.colsWithinViewport.concat(e).concat(t)}getColsWithinViewport(e){if(!this.colModel.colSpanActive)return this.colsWithinViewport;const t=o=>{const s=o.getLeft();return ie(s)&&s>this.viewportLeft},r=this.isColumnVirtualisationSuppressed()?void 0:this.isColumnInRowViewport.bind(this),{visibleCols:n}=this,i=n.centerCols;return n.getColsForRow(e,i,r,t)}checkViewportColumns(e=!1){this.extractViewport()&&this.eventSvc.dispatchEvent({type:"virtualColumnsChanged",afterScroll:e})}calculateHeaderRows(){this.clear(!0);const e={},{leftCols:t,rightCols:r,treeLeft:n,treeRight:i,treeCenter:o}=this.visibleCols;this.headerColsWithinViewport.concat(t).concat(r).forEach(l=>e[l.getId()]=!0);const a=(l,c,u)=>{let d=!1;for(let h=0;h<l.length;h++){const f=l[h];let g=!1;if($r(f))g=e[f.getId()]===!0;else{const p=f.getDisplayedChildren();p&&(g=a(p,c,u+1))}g&&(d=!0,c[u]||(c[u]=[]),c[u].push(f))}return d};a(n,this.rowsOfHeadersToRenderLeft,0),a(i,this.rowsOfHeadersToRenderRight,0),a(o,this.rowsOfHeadersToRenderCenter,0)}extractViewport(){const e=n=>`${n.getId()}-${n.getPinned()||"normal"}`;this.extractViewportColumns();const t=this.getViewportColumns().map(e).join("#"),r=this.colsWithinViewportHash!==t;return r&&(this.colsWithinViewportHash=t,this.calculateHeaderRows()),r}};function T8(e){for(;e;){if(e.isAutoHeaderHeight())return!0;e=e.getParent()}return!1}var F8=class extends q{constructor(){super(...arguments),this.beanName="agCompUtils"}adaptFunction(e,t){if(!e.cellRenderer)return null;class r{refresh(){return!1}getGui(){return this.eGui}init(i){const o=t(i),s=typeof o;if(s==="string"||s==="number"||s==="boolean"){this.eGui=np("<span>"+o+"</span>");return}if(o==null){this.eGui=lt({tag:"span"});return}this.eGui=o}}return r}},O8={moduleName:"CellRendererFunction",version:he,beans:[F8]},M8=class extends q{constructor(){super(...arguments),this.beanName="registry",this.agGridDefaults={},this.agGridDefaultParams={},this.jsComps={},this.dynamicBeans={},this.selectors={},this.icons={}}postConstruct(){const e=this.gos.get("components");if(e!=null)for(const t of Object.keys(e))this.jsComps[t]=e[t]}registerModule(e){const{icons:t,userComponents:r,dynamicBeans:n,selectors:i}=e;if(r){const o=(s,a,l)=>{this.agGridDefaults[s]=a,l&&(this.agGridDefaultParams[s]=l)};for(const s of Object.keys(r)){const a=r[s];typeof a=="object"?o(s,a.classImp,a.params):o(s,a)}}if(n)for(const o of Object.keys(n))this.dynamicBeans[o]=n[o];if(i==null||i.forEach(o=>{this.selectors[o.selector]=o}),t)for(const o of Object.keys(t))this.icons[o]=t[o]}getUserComponent(e,t){var a;const r=(l,c,u)=>({componentFromFramework:c,component:l,params:u}),{frameworkOverrides:n}=this.beans,i=n.frameworkComponent(t,this.gos.get("components"));if(i!=null)return r(i,!0);const o=this.jsComps[t];if(o){const l=n.isFrameworkComponent(o);return r(o,l)}const s=this.agGridDefaults[t];return s?r(s,!1,this.agGridDefaultParams[t]):((a=this.beans.validation)==null||a.missingUserComponent(e,t,this.agGridDefaults,this.jsComps),null)}createDynamicBean(e,t,...r){const n=this.dynamicBeans[e];if(n==null){if(t)throw new Error(e1(256));return}return new n(...r)}getSelector(e){return this.selectors[e]}getIcon(e){return this.icons[e]}},D8=23,k8=class extends q{constructor(){super(...arguments),this.beanName="ctrlsSvc",this.params={},this.ready=!1,this.readyCallbacks=[]}postConstruct(){var e,t;this.addEventListener("ready",()=>{this.updateReady(),this.ready&&(this.readyCallbacks.forEach(r=>r(this.params)),this.readyCallbacks.length=0)},((t=(e=this.beans.frameworkOverrides).runWhenReadyAsync)==null?void 0:t.call(e))??!1)}updateReady(){const e=Object.values(this.params);this.ready=e.length===D8&&e.every(t=>(t==null?void 0:t.isAlive())??!1)}whenReady(e,t){this.ready?t(this.params):this.readyCallbacks.push(t),e.addDestroyFunc(()=>{const r=this.readyCallbacks.indexOf(t);r>=0&&this.readyCallbacks.splice(r,1)})}register(e,t){this.params[e]=t,this.updateReady(),this.ready&&this.dispatchLocalEvent({type:"ready"}),t.addDestroyFunc(()=>{this.updateReady()})}get(e){return this.params[e]}getGridBodyCtrl(){return this.params.gridBodyCtrl}getHeaderRowContainerCtrls(){const{leftHeader:e,centerHeader:t,rightHeader:r}=this.params;return[e,r,t]}getHeaderRowContainerCtrl(e){const t=this.params;switch(e){case"left":return t.leftHeader;case"right":return t.rightHeader;default:return t.centerHeader}}getScrollFeature(){return this.getGridBodyCtrl().scrollFeature}},I8=':where(.ag-root-wrapper,.ag-popup,.ag-dnd-ghost,.ag-chart),:where(.ag-root-wrapper,.ag-popup,.ag-dnd-ghost,.ag-chart) :where([class^=ag-]){box-sizing:border-box;&:after,&:before{box-sizing:border-box}&:where(div,span,label):focus-visible{box-shadow:inset var(--ag-focus-shadow);outline:none}}:where(.ag-root-wrapper,.ag-popup,.ag-dnd-ghost,.ag-chart) :where([class^=ag-]) ::-ms-clear{display:none}.ag-aria-description-container{border:0;z-index:9999;clip:rect(1px,1px,1px,1px);height:1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.ag-hidden{display:none!important}.ag-invisible{visibility:hidden!important}.ag-unselectable{-webkit-user-select:none;-moz-user-select:none;user-select:none}.ag-selectable{-webkit-user-select:text;-moz-user-select:text;user-select:text}.ag-tab-guard{display:block;height:0;position:absolute;width:0}:where(.ag-virtual-list-viewport) .ag-tab-guard{position:sticky}.ag-tab-guard-top{top:1px}.ag-tab-guard-bottom{bottom:1px}.ag-shake-left-to-right{animation-direction:alternate;animation-duration:.2s;animation-iteration-count:infinite;animation-name:ag-shake-left-to-right}@keyframes ag-shake-left-to-right{0%{padding-left:6px;padding-right:2px}to{padding-left:2px;padding-right:6px}}.ag-body-horizontal-scroll-viewport,.ag-body-vertical-scroll-viewport,.ag-body-viewport,.ag-center-cols-viewport,.ag-floating-bottom-viewport,.ag-floating-top-viewport,.ag-header-viewport,.ag-sticky-bottom-viewport,.ag-sticky-top-viewport,.ag-virtual-list-viewport{flex:1 1 auto;height:100%;min-width:0;overflow:hidden;position:relative}.ag-viewport{position:relative}.ag-spanning-container{position:absolute;top:0;z-index:1}.ag-body-viewport,.ag-center-cols-viewport,.ag-floating-bottom-viewport,.ag-floating-top-viewport,.ag-header-viewport,.ag-sticky-bottom-viewport,.ag-sticky-top-viewport{overflow-x:auto;-ms-overflow-style:none!important;scrollbar-width:none!important;&::-webkit-scrollbar{display:none!important}}.ag-body-viewport{display:flex;overflow-x:hidden;&:where(.ag-layout-normal){overflow-y:auto;-webkit-overflow-scrolling:touch}}.ag-floating-bottom-container,.ag-floating-top-container,.ag-sticky-bottom-container,.ag-sticky-top-container{min-height:1px}.ag-center-cols-viewport{min-height:100%;width:100%}.ag-body-horizontal-scroll-viewport{overflow-x:scroll}.ag-body-vertical-scroll-viewport{overflow-y:scroll}.ag-virtual-list-viewport{overflow:auto;width:100%}.ag-body-container,.ag-body-horizontal-scroll-container,.ag-body-vertical-scroll-container,.ag-center-cols-container,.ag-floating-bottom-container,.ag-floating-bottom-full-width-container,.ag-floating-top-container,.ag-full-width-container,.ag-header-container,.ag-pinned-left-cols-container,.ag-pinned-right-cols-container,.ag-sticky-bottom-container,.ag-sticky-top-container,.ag-virtual-list-container{position:relative}.ag-floating-bottom-container,.ag-floating-top-container,.ag-header-container,.ag-pinned-left-floating-bottom,.ag-pinned-left-floating-top,.ag-pinned-right-floating-bottom,.ag-pinned-right-floating-top,.ag-sticky-bottom-container,.ag-sticky-top-container{height:100%;white-space:nowrap}.ag-center-cols-container,.ag-pinned-right-cols-container{display:block}.ag-body-horizontal-scroll-container{height:100%}.ag-body-vertical-scroll-container{width:100%}.ag-floating-bottom-full-width-container,.ag-floating-top-full-width-container,.ag-full-width-container,.ag-sticky-bottom-full-width-container,.ag-sticky-top-full-width-container{pointer-events:none;position:absolute;top:0}:where(.ag-ltr) .ag-floating-bottom-full-width-container,:where(.ag-ltr) .ag-floating-top-full-width-container,:where(.ag-ltr) .ag-full-width-container,:where(.ag-ltr) .ag-sticky-bottom-full-width-container,:where(.ag-ltr) .ag-sticky-top-full-width-container{left:0}:where(.ag-rtl) .ag-floating-bottom-full-width-container,:where(.ag-rtl) .ag-floating-top-full-width-container,:where(.ag-rtl) .ag-full-width-container,:where(.ag-rtl) .ag-sticky-bottom-full-width-container,:where(.ag-rtl) .ag-sticky-top-full-width-container{right:0}.ag-full-width-container{width:100%}.ag-floating-bottom-full-width-container,.ag-floating-top-full-width-container{display:inline-block;height:100%;overflow:hidden;width:100%}.ag-virtual-list-container{overflow:hidden}.ag-body{display:flex;flex:1 1 auto;flex-direction:row!important;min-height:0;position:relative}.ag-body-horizontal-scroll,.ag-body-vertical-scroll{display:flex;min-height:0;min-width:0;position:relative;&:where(.ag-scrollbar-invisible){bottom:0;position:absolute;&:where(.ag-apple-scrollbar){opacity:0;transition:opacity .4s;visibility:hidden;&:where(.ag-scrollbar-scrolling,.ag-scrollbar-active){opacity:1;visibility:visible}}}}.ag-body-horizontal-scroll{width:100%;&:where(.ag-scrollbar-invisible){left:0;right:0}}.ag-body-vertical-scroll{height:100%;&:where(.ag-scrollbar-invisible){top:0;z-index:10}}:where(.ag-ltr) .ag-body-vertical-scroll{&:where(.ag-scrollbar-invisible){right:0}}:where(.ag-rtl) .ag-body-vertical-scroll{&:where(.ag-scrollbar-invisible){left:0}}.ag-force-vertical-scroll{overflow-y:scroll!important}.ag-horizontal-left-spacer,.ag-horizontal-right-spacer{height:100%;min-width:0;overflow-x:scroll;&:where(.ag-scroller-corner){overflow-x:hidden}}:where(.ag-row-animation) .ag-row{transition:transform .4s,top .4s,opacity .2s;&:where(.ag-after-created){transition:transform .4s,top .4s,height .4s,opacity .2s}}:where(.ag-row-animation.ag-prevent-animation) .ag-row{transition:none!important;&:where(.ag-row.ag-after-created){transition:none!important}}:where(.ag-row-no-animation) .ag-row{transition:none}.ag-row-loading{align-items:center;display:flex}.ag-row-position-absolute{position:absolute}.ag-row-position-relative{position:relative}.ag-full-width-row{overflow:hidden;pointer-events:all}.ag-row-inline-editing{z-index:1}.ag-row-dragging{z-index:2}.ag-stub-cell{align-items:center;display:flex}.ag-cell{display:inline-block;height:100%;position:absolute;white-space:nowrap;&:focus-visible{box-shadow:none}}.ag-cell-value{flex:1 1 auto}.ag-cell-value,.ag-group-value{overflow:hidden;text-overflow:ellipsis}.ag-cell-wrap-text{white-space:normal;word-break:break-word}:where(.ag-cell) .ag-icon{display:inline-block;vertical-align:middle}.ag-floating-top{display:flex;overflow:hidden;position:relative;white-space:nowrap;width:100%}:where(.ag-floating-top:not(.ag-invisible)){border-bottom:var(--ag-pinned-row-border)}.ag-floating-bottom{display:flex;overflow:hidden;position:relative;white-space:nowrap;width:100%}:where(.ag-floating-bottom:not(.ag-invisible)){border-top:var(--ag-pinned-row-border)}.ag-sticky-bottom,.ag-sticky-top{background-color:var(--ag-background-color);display:flex;height:0;overflow:hidden;position:absolute;width:100%;z-index:1}.ag-opacity-zero{opacity:0!important}.ag-cell-label-container{align-items:center;display:flex;flex-direction:row-reverse;height:100%;justify-content:space-between;width:100%}:where(.ag-right-aligned-header){.ag-cell-label-container{flex-direction:row}.ag-header-cell-text{text-align:end}}.ag-column-group-icons{display:block;>*{cursor:pointer}}:where(.ag-ltr){direction:ltr;.ag-body,.ag-body-horizontal-scroll,.ag-body-viewport,.ag-floating-bottom,.ag-floating-top,.ag-header,.ag-sticky-bottom,.ag-sticky-top{flex-direction:row}}:where(.ag-rtl){direction:rtl;text-align:right;.ag-body,.ag-body-horizontal-scroll,.ag-body-viewport,.ag-floating-bottom,.ag-floating-top,.ag-header,.ag-sticky-bottom,.ag-sticky-top{flex-direction:row-reverse}.ag-icon-contracted,.ag-icon-expanded,.ag-icon-tree-closed{display:block}}:where(.ag-rtl){.ag-icon-contracted,.ag-icon-expanded,.ag-icon-tree-closed{transform:rotate(180deg)}}:where(.ag-rtl){.ag-icon-contracted,.ag-icon-expanded,.ag-icon-tree-closed{transform:rotate(-180deg)}}.ag-measurement-container{height:0;overflow:hidden;visibility:hidden;width:0}.ag-measurement-element-border{display:inline-block;&:before{border-left:var(--ag-internal-measurement-border);content:"";display:block}}.ag-group{position:relative;width:100%}.ag-group-title-bar{align-items:center;display:flex;padding:var(--ag-spacing)}.ag-group-title{display:inline;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:where(.ag-group-title-bar) .ag-group-title{cursor:default}.ag-group-toolbar{align-items:center;display:flex;padding:var(--ag-spacing)}.ag-group-container{display:flex}.ag-disabled .ag-group-container{pointer-events:none}.ag-disabled-group-container,.ag-disabled-group-title-bar{opacity:.5}.ag-group-container-horizontal{flex-flow:row wrap}.ag-group-container-vertical{flex-direction:column}.ag-group-title-bar-icon{cursor:pointer;flex:none}:where(.ag-ltr) .ag-group-title-bar-icon{margin-right:var(--ag-spacing)}:where(.ag-rtl) .ag-group-title-bar-icon{margin-left:var(--ag-spacing)}:where(.ag-group-item-alignment-stretch) .ag-group-item{align-items:stretch}:where(.ag-group-item-alignment-start) .ag-group-item{align-items:flex-start}:where(.ag-group-item-alignment-end) .ag-group-item{align-items:flex-end}.ag-popup-child{top:0;z-index:5;&:where(:not(.ag-tooltip-custom)){box-shadow:var(--ag-popup-shadow)}}.ag-popup-editor{position:absolute;-webkit-user-select:none;-moz-user-select:none;user-select:none}.ag-large-text-input{display:block}:where(.ag-ltr) .ag-row:not(.ag-row-level-0) .ag-pivot-leaf-group{margin-left:var(--ag-row-group-indent-size)}:where(.ag-rtl) .ag-row:not(.ag-row-level-0) .ag-pivot-leaf-group{margin-right:var(--ag-row-group-indent-size)}:where(.ag-ltr) .ag-row-group-leaf-indent{margin-left:calc(var(--ag-cell-widget-spacing) + var(--ag-icon-size))}:where(.ag-rtl) .ag-row-group-leaf-indent{margin-right:calc(var(--ag-cell-widget-spacing) + var(--ag-icon-size))}.ag-value-change-delta{padding:0 2px}.ag-value-change-delta-up{color:var(--ag-value-change-delta-up-color)}.ag-value-change-delta-down{color:var(--ag-value-change-delta-down-color)}.ag-value-change-value{background-color:transparent;border-radius:1px;padding-left:1px;padding-right:1px;transition:background-color 1s}.ag-value-change-value-highlight{background-color:var(--ag-value-change-value-highlight-background-color);transition:background-color .1s}.ag-cell-data-changed{background-color:var(--ag-value-change-value-highlight-background-color)!important}.ag-cell-data-changed-animation{background-color:transparent}.ag-cell-highlight{background-color:var(--ag-range-selection-highlight-color)!important}.ag-row,.ag-spanned-row{color:var(--ag-cell-text-color);font-family:var(--ag-cell-font-family);font-size:var(--ag-data-font-size);white-space:nowrap;--ag-internal-content-line-height:calc(min(var(--ag-row-height), var(--ag-line-height, 1000px)) - var(--ag-internal-row-border-width, 1px) - 2px)}.ag-row{background-color:var(--ag-background-color);border-bottom:var(--ag-row-border);height:var(--ag-row-height);width:100%}:where(.ag-body-vertical-content-no-gap>div>div>div,.ag-body-vertical-content-no-gap>div>div>div>div)>.ag-row-last{border-bottom-color:transparent}.ag-sticky-bottom{border-top:var(--ag-row-border);box-sizing:content-box!important}.ag-group-contracted,.ag-group-expanded{cursor:pointer}.ag-cell,.ag-full-width-row .ag-cell-wrapper.ag-row-group{border:1px solid transparent;line-height:var(--ag-internal-content-line-height);-webkit-font-smoothing:subpixel-antialiased}:where(.ag-ltr) .ag-cell{border-right:var(--ag-column-border)}:where(.ag-rtl) .ag-cell{border-left:var(--ag-column-border)}.ag-spanned-cell-wrapper{background-color:var(--ag-background-color);position:absolute}.ag-spanned-cell-wrapper>.ag-spanned-cell{display:block;position:relative}:where(.ag-ltr) :where(.ag-body-horizontal-content-no-gap) .ag-column-last{border-right-color:transparent}:where(.ag-rtl) :where(.ag-body-horizontal-content-no-gap) .ag-column-last{border-left-color:transparent}.ag-cell-wrapper{align-items:center;display:flex;>:where(:not(.ag-cell-value,.ag-group-value)){align-items:center;display:flex;height:var(--ag-internal-content-line-height)}&:where(.ag-row-group){align-items:flex-start}:where(.ag-full-width-row) &:where(.ag-row-group){align-items:center;height:100%}}:where(.ag-ltr) .ag-cell-wrapper{padding-left:calc(var(--ag-indentation-level)*var(--ag-row-group-indent-size))}:where(.ag-rtl) .ag-cell-wrapper{padding-right:calc(var(--ag-indentation-level)*var(--ag-row-group-indent-size))}:where(.ag-cell-wrap-text:not(.ag-cell-auto-height)) .ag-cell-wrapper{align-items:normal;height:100%;:where(.ag-cell-value){height:100%}}:where(.ag-ltr) .ag-row>.ag-cell-wrapper.ag-row-group{padding-left:calc(var(--ag-cell-horizontal-padding) + var(--ag-row-group-indent-size)*var(--ag-indentation-level))}:where(.ag-rtl) .ag-row>.ag-cell-wrapper.ag-row-group{padding-right:calc(var(--ag-cell-horizontal-padding) + var(--ag-row-group-indent-size)*var(--ag-indentation-level))}.ag-cell-focus:not(.ag-cell-range-selected):focus-within,.ag-cell-range-single-cell,.ag-cell-range-single-cell.ag-cell-range-handle,.ag-context-menu-open .ag-cell-focus:not(.ag-cell-range-selected),.ag-context-menu-open .ag-full-width-row.ag-row-focus .ag-cell-wrapper.ag-row-group,.ag-full-width-row.ag-row-focus:focus .ag-cell-wrapper.ag-row-group{border:1px solid;border-color:var(--ag-range-selection-border-color);border-style:var(--ag-range-selection-border-style);outline:initial}.ag-full-width-row.ag-row-focus:focus{box-shadow:none}:where(.ag-ltr) .ag-group-contracted,:where(.ag-ltr) .ag-group-expanded,:where(.ag-ltr) .ag-row-drag,:where(.ag-ltr) .ag-selection-checkbox{margin-right:var(--ag-cell-widget-spacing)}:where(.ag-rtl) .ag-group-contracted,:where(.ag-rtl) .ag-group-expanded,:where(.ag-rtl) .ag-row-drag,:where(.ag-rtl) .ag-selection-checkbox{margin-left:var(--ag-cell-widget-spacing)}:where(.ag-ltr) .ag-group-child-count{margin-left:3px}:where(.ag-rtl) .ag-group-child-count{margin-right:3px}.ag-row-highlight-above:after,.ag-row-highlight-below:after{background-color:var(--ag-range-selection-border-color);content:"";height:1px;position:absolute;width:calc(100% - 1px)}:where(.ag-ltr) .ag-row-highlight-above:after,:where(.ag-ltr) .ag-row-highlight-below:after{left:1px}:where(.ag-rtl) .ag-row-highlight-above:after,:where(.ag-rtl) .ag-row-highlight-below:after{right:1px}.ag-row-highlight-above:after{top:0}.ag-row-highlight-below:after{bottom:0}.ag-row-odd{background-color:var(--ag-odd-row-background-color)}.ag-row-selected:before{background-color:var(--ag-selected-row-background-color);content:"";display:block;inset:0;pointer-events:none;position:absolute}.ag-row-hover.ag-full-width-row.ag-row-group:before,.ag-row-hover:not(.ag-full-width-row):before{background-color:var(--ag-row-hover-color);content:"";display:block;inset:0;pointer-events:none;position:absolute}.ag-row-hover.ag-row-selected:before{background-color:var(--ag-row-hover-color);background-image:linear-gradient(var(--ag-selected-row-background-color),var(--ag-selected-row-background-color))}.ag-row.ag-full-width-row.ag-row-group>*{position:relative}.ag-column-hover{background-color:var(--ag-column-hover-color)}.ag-header-range-highlight{background-color:var(--ag-range-header-highlight-color)}.ag-right-aligned-cell{font-variant-numeric:tabular-nums}:where(.ag-ltr) .ag-right-aligned-cell{text-align:right}:where(.ag-rtl) .ag-right-aligned-cell{text-align:left}.ag-right-aligned-cell .ag-cell-value,.ag-right-aligned-cell .ag-group-value{margin-left:auto}:where(.ag-ltr) .ag-cell:not(.ag-cell-inline-editing),:where(.ag-ltr) .ag-full-width-row .ag-cell-wrapper.ag-row-group{padding-left:calc(var(--ag-cell-horizontal-padding) - 1px + var(--ag-row-group-indent-size)*var(--ag-indentation-level));padding-right:calc(var(--ag-cell-horizontal-padding) - 1px)}:where(.ag-rtl) .ag-cell:not(.ag-cell-inline-editing),:where(.ag-rtl) .ag-full-width-row .ag-cell-wrapper.ag-row-group{padding-left:calc(var(--ag-cell-horizontal-padding) - 1px);padding-right:calc(var(--ag-cell-horizontal-padding) - 1px + var(--ag-row-group-indent-size)*var(--ag-indentation-level))}.ag-row>.ag-cell-wrapper{padding-left:calc(var(--ag-cell-horizontal-padding) - 1px);padding-right:calc(var(--ag-cell-horizontal-padding) - 1px)}.ag-row-dragging{cursor:move;opacity:.5}.ag-details-row{background-color:var(--ag-background-color);padding:calc(var(--ag-spacing)*3.75)}.ag-layout-auto-height,.ag-layout-print{.ag-center-cols-container,.ag-center-cols-viewport{min-height:150px}}.ag-overlay-loading-wrapper{background-color:var(--ag-modal-overlay-background-color)}.ag-skeleton-container{align-content:center;height:100%;width:100%}.ag-skeleton-effect{animation:ag-skeleton-loading 1.5s ease-in-out .5s infinite;background-color:var(--ag-row-loading-skeleton-effect-color);border-radius:.25rem;height:1em;width:100%}:where(.ag-ltr) .ag-right-aligned-cell .ag-skeleton-effect{margin-left:auto}:where(.ag-rtl) .ag-right-aligned-cell .ag-skeleton-effect{margin-right:auto}@keyframes ag-skeleton-loading{0%{opacity:1}50%{opacity:.4}to{opacity:1}}.ag-loading{align-items:center;display:flex;height:100%}:where(.ag-ltr) .ag-loading{padding-left:var(--ag-cell-horizontal-padding)}:where(.ag-rtl) .ag-loading{padding-right:var(--ag-cell-horizontal-padding)}:where(.ag-ltr) .ag-loading-icon{padding-right:var(--ag-cell-widget-spacing)}:where(.ag-rtl) .ag-loading-icon{padding-left:var(--ag-cell-widget-spacing)}.ag-icon-loading{animation-duration:1s;animation-iteration-count:infinite;animation-name:spin;animation-timing-function:linear}@keyframes spin{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}.ag-input-wrapper,.ag-picker-field-wrapper{align-items:center;display:flex;flex:1 1 auto;line-height:normal;position:relative}.ag-input-field{align-items:center;display:flex;flex-direction:row}.ag-input-field-input:where(:not([type=checkbox],[type=radio])){flex:1 1 auto;min-width:0;width:100%}.ag-header{background-color:var(--ag-header-background-color);border-bottom:var(--ag-header-row-border);color:var(--ag-header-text-color);display:flex;font-family:var(--ag-header-font-family);font-size:var(--ag-header-font-size);font-weight:var(--ag-header-font-weight);overflow:hidden;white-space:nowrap;width:100%}.ag-header-row{height:var(--ag-header-height);position:absolute}.ag-floating-filter-button-button,.ag-header-cell-filter-button,.ag-header-cell-menu-button,.ag-header-expand-icon,.ag-panel-title-bar-button,:where(.ag-header-cell-sortable) .ag-header-cell-label{cursor:pointer}:where(.ag-ltr) .ag-header-expand-icon{margin-left:4px}:where(.ag-rtl) .ag-header-expand-icon{margin-right:4px}.ag-header-row:where(:not(:first-child)){:where(.ag-header-cell:not(.ag-header-span-height.ag-header-span-total,.ag-header-parent-hidden),.ag-header-group-cell.ag-header-group-cell-with-group){border-top:var(--ag-header-row-border)}}.ag-header-row:where(:not(.ag-header-row-column-group)){overflow:hidden}:where(.ag-header.ag-header-allow-overflow) .ag-header-row{overflow:visible}.ag-header-cell{display:inline-flex;overflow:hidden}.ag-header-group-cell{contain:paint;display:flex}.ag-header-cell,.ag-header-group-cell{align-items:center;gap:var(--ag-cell-widget-spacing);height:100%;padding:0 var(--ag-cell-horizontal-padding);position:absolute}@property --ag-internal-moving-color{syntax:"<color>";inherits:false;initial-value:transparent}@property --ag-internal-hover-color{syntax:"<color>";inherits:false;initial-value:transparent}.ag-header-cell:where(:not(.ag-floating-filter)),.ag-header-group-cell{&:before{background-image:linear-gradient(var(--ag-internal-hover-color),var(--ag-internal-hover-color)),linear-gradient(var(--ag-internal-moving-color),var(--ag-internal-moving-color));content:"";inset:0;position:absolute;--ag-internal-moving-color:transparent;--ag-internal-hover-color:transparent;transition:--ag-internal-moving-color var(--ag-header-cell-background-transition-duration),--ag-internal-hover-color var(--ag-header-cell-background-transition-duration)}&:where(:hover):before{--ag-internal-hover-color:var(--ag-header-cell-hover-background-color)}&:where(.ag-header-cell-moving):before{--ag-internal-moving-color:var(--ag-header-cell-moving-background-color);--ag-internal-hover-color:var(--ag-header-cell-hover-background-color)}}:where(.ag-header-cell:not(.ag-floating-filter) *,.ag-header-group-cell *){position:relative;z-index:1}.ag-header-cell-menu-button:where(:not(.ag-header-menu-always-show)){opacity:0;transition:opacity .2s}.ag-header-cell-filter-button,:where(.ag-header-cell.ag-header-active) .ag-header-cell-menu-button{opacity:1}.ag-header-cell-label,.ag-header-group-cell-label{align-items:center;align-self:stretch;display:flex;flex:1 1 auto;overflow:hidden;padding:5px 0}:where(.ag-ltr) .ag-sort-indicator-icon{padding-left:var(--ag-spacing)}:where(.ag-rtl) .ag-sort-indicator-icon{padding-right:var(--ag-spacing)}.ag-header-cell-label{text-overflow:ellipsis}.ag-header-group-cell-label.ag-sticky-label{flex:none;max-width:100%;overflow:visible;position:sticky}:where(.ag-ltr) .ag-header-group-cell-label.ag-sticky-label{left:var(--ag-cell-horizontal-padding)}:where(.ag-rtl) .ag-header-group-cell-label.ag-sticky-label{right:var(--ag-cell-horizontal-padding)}.ag-header-cell-text,.ag-header-group-text{overflow:hidden;text-overflow:ellipsis}.ag-header-cell-text{word-break:break-word}.ag-header-cell-comp-wrapper{width:100%}:where(.ag-header-group-cell) .ag-header-cell-comp-wrapper{display:flex}:where(.ag-header-cell:not(.ag-header-cell-auto-height)) .ag-header-cell-comp-wrapper{align-items:center;display:flex;height:100%}.ag-header-cell-wrap-text .ag-header-cell-comp-wrapper{white-space:normal}.ag-header-cell-comp-wrapper-limited-height>*{overflow:hidden}:where(.ag-right-aligned-header) .ag-header-cell-label{flex-direction:row-reverse}:where(.ag-ltr) :where(.ag-header-cell:not(.ag-right-aligned-header)){.ag-header-label-icon,.ag-header-menu-icon{margin-left:var(--ag-spacing)}}:where(.ag-rtl) :where(.ag-header-cell:not(.ag-right-aligned-header)){.ag-header-label-icon,.ag-header-menu-icon{margin-right:var(--ag-spacing)}}:where(.ag-ltr) :where(.ag-header-cell.ag-right-aligned-header){.ag-header-label-icon,.ag-header-menu-icon{margin-right:var(--ag-spacing)}}:where(.ag-rtl) :where(.ag-header-cell.ag-right-aligned-header){.ag-header-label-icon,.ag-header-menu-icon{margin-left:var(--ag-spacing)}}.ag-header-cell:after,.ag-header-group-cell:where(:not(.ag-header-span-height.ag-header-group-cell-no-group)):after{content:"";height:var(--ag-header-column-border-height);position:absolute;top:calc(50% - var(--ag-header-column-border-height)*.5);z-index:1}:where(.ag-ltr) .ag-header-cell:after,:where(.ag-ltr) .ag-header-group-cell:where(:not(.ag-header-span-height.ag-header-group-cell-no-group)):after{border-right:var(--ag-header-column-border);right:0}:where(.ag-rtl) .ag-header-cell:after,:where(.ag-rtl) .ag-header-group-cell:where(:not(.ag-header-span-height.ag-header-group-cell-no-group)):after{border-left:var(--ag-header-column-border);left:0}.ag-header-highlight-after:after,.ag-header-highlight-before:after{background-color:var(--ag-accent-color);content:"";height:100%;position:absolute;width:1px}:where(.ag-ltr) .ag-header-highlight-before:after{left:0}:where(.ag-rtl) .ag-header-highlight-before:after{right:0}:where(.ag-ltr) .ag-header-highlight-after:after{right:0;:where(.ag-pinned-left-header) &{right:1px}}:where(.ag-rtl) .ag-header-highlight-after:after{left:0;:where(.ag-pinned-left-header) &{left:1px}}.ag-header-cell-resize{align-items:center;cursor:ew-resize;display:flex;height:100%;position:absolute;top:0;width:8px;z-index:2;&:after{background-color:var(--ag-header-column-resize-handle-color);content:"";height:var(--ag-header-column-resize-handle-height);position:absolute;top:calc(50% - var(--ag-header-column-resize-handle-height)*.5);width:var(--ag-header-column-resize-handle-width);z-index:1}}:where(.ag-ltr) .ag-header-cell-resize{right:-3px;&:after{left:calc(50% - var(--ag-header-column-resize-handle-width))}}:where(.ag-rtl) .ag-header-cell-resize{left:-3px;&:after{right:calc(50% - var(--ag-header-column-resize-handle-width))}}:where(.ag-header-cell.ag-header-span-height) .ag-header-cell-resize:after{height:calc(100% - var(--ag-spacing)*4);top:calc(var(--ag-spacing)*2)}.ag-header-group-cell-no-group:where(.ag-header-span-height){display:none}.ag-sort-indicator-container{display:flex;gap:var(--ag-spacing)}.ag-layout-print{&.ag-body{display:block;height:unset}&.ag-root-wrapper{display:inline-block}.ag-body-horizontal-scroll,.ag-body-vertical-scroll{display:none}&.ag-force-vertical-scroll{overflow-y:visible!important}}@media print{.ag-root-wrapper.ag-layout-print{display:table;.ag-body-horizontal-scroll-viewport,.ag-body-viewport,.ag-center-cols-container,.ag-center-cols-viewport,.ag-root,.ag-root-wrapper-body,.ag-virtual-list-viewport{display:block!important;height:auto!important;overflow:hidden!important}.ag-cell,.ag-row{-moz-column-break-inside:avoid;break-inside:avoid}}}ag-grid,ag-grid-angular{display:block}.ag-chart,.ag-dnd-ghost,.ag-popup,.ag-root-wrapper{cursor:default;line-height:normal;white-space:normal;-webkit-font-smoothing:antialiased;background-color:var(--ag-background-color);color:var(--ag-text-color);color-scheme:var(--ag-browser-color-scheme);font-family:var(--ag-font-family);font-size:var(--ag-font-size);--ag-indentation-level:0}.ag-root-wrapper{border:var(--ag-wrapper-border);border-radius:var(--ag-wrapper-border-radius);display:flex;flex-direction:column;overflow:hidden;position:relative;&.ag-layout-normal{height:100%}}.ag-root-wrapper-body{display:flex;flex-direction:row;&.ag-layout-normal{flex:1 1 auto;height:0;min-height:0}}.ag-root{display:flex;flex-direction:column;position:relative;&.ag-layout-auto-height,&.ag-layout-normal{flex:1 1 auto;overflow:hidden;width:0}&.ag-layout-normal{height:100%}}.ag-drag-handle{color:var(--ag-drag-handle-color);cursor:grab}.ag-list-item,.ag-virtual-list-item{height:var(--ag-list-item-height)}.ag-virtual-list-item{position:absolute;width:100%}.ag-select-list{background-color:var(--ag-picker-list-background-color);border:var(--ag-picker-list-border);border-radius:var(--ag-border-radius);box-shadow:var(--ag-dropdown-shadow);overflow:hidden auto}.ag-list-item{align-items:center;display:flex;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;&.ag-active-item{background-color:var(--ag-row-hover-color)}}.ag-select-list-item{cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none;:where(span){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}}:where(.ag-ltr) .ag-select-list-item{padding-left:calc(var(--ag-cell-horizontal-padding)/2)}:where(.ag-rtl) .ag-select-list-item{padding-right:calc(var(--ag-cell-horizontal-padding)/2)}.ag-list-item-hovered:after{background-color:var(--ag-accent-color);content:"";height:1px;left:0;position:absolute;right:0}.ag-item-highlight-top:after{top:0}.ag-item-highlight-bottom:after{bottom:0}:where(.ag-icon):before{align-items:center;background-color:currentcolor;color:inherit;content:"";display:flex;font-family:inherit;font-size:var(--ag-icon-size);font-style:normal;font-variant:normal;height:var(--ag-icon-size);justify-content:center;line-height:var(--ag-icon-size);-webkit-mask-size:contain;mask-size:contain;text-transform:none;width:var(--ag-icon-size)}.ag-icon{background-position:50%;background-repeat:no-repeat;background-size:contain;color:var(--ag-icon-color);display:block;height:var(--ag-icon-size);position:relative;-webkit-user-select:none;-moz-user-select:none;user-select:none;width:var(--ag-icon-size)}.ag-column-select-column-group-readonly,.ag-column-select-column-readonly,.ag-disabled,[disabled]{.ag-icon{opacity:.5}&.ag-icon-grip{opacity:.35}}.ag-column-select-column-readonly{&.ag-icon-grip,.ag-icon-grip{opacity:.35}}.ag-chart-menu-icon,.ag-chart-settings-next,.ag-chart-settings-prev,.ag-column-group-icons,.ag-column-select-header-icon,.ag-filter-toolpanel-expand,.ag-floating-filter-button-button,.ag-group-title-bar-icon,.ag-header-cell-filter-button,.ag-header-cell-menu-button,.ag-header-expand-icon,.ag-panel-title-bar-button,.ag-panel-title-bar-button-icon,.ag-set-filter-group-icons,:where(.ag-group-contracted) .ag-icon,:where(.ag-group-expanded) .ag-icon{background-color:var(--ag-icon-button-background-color);border-radius:var(--ag-icon-button-border-radius);box-shadow:0 0 0 var(--ag-icon-button-background-spread) var(--ag-icon-button-background-color);color:var(--ag-icon-button-color);&:hover{background-color:var(--ag-icon-button-hover-background-color);box-shadow:0 0 0 var(--ag-icon-button-background-spread) var(--ag-icon-button-hover-background-color);color:var(--ag-icon-button-hover-color)}}.ag-filter-active{background-image:linear-gradient(var(--ag-icon-button-active-background-color),var(--ag-icon-button-active-background-color));border-radius:1px;outline:solid var(--ag-icon-button-background-spread) var(--ag-icon-button-active-background-color);position:relative;&:after{background-color:var(--ag-accent-color);border-radius:50%;content:"";height:6px;position:absolute;top:-1px;width:6px}:where(.ag-icon-filter){clip-path:path("M8,0C8,4.415 11.585,8 16,8L16,16L0,16L0,0L8,0Z");color:var(--ag-icon-button-active-color)}}:where(.ag-ltr) .ag-filter-active{&:after{right:-1px}}:where(.ag-rtl) .ag-filter-active{&:after{left:-1px}}.ag-menu{background-color:var(--ag-menu-background-color);border:var(--ag-menu-border);border-radius:var(--ag-border-radius);box-shadow:var(--ag-menu-shadow);color:var(--ag-menu-text-color);max-height:100%;overflow-y:auto}.ag-menu,.ag-resizer{position:absolute;-webkit-user-select:none;-moz-user-select:none;user-select:none}.ag-resizer{pointer-events:none;z-index:1}:where(.ag-resizer){&.ag-resizer-topLeft{cursor:nwse-resize;height:5px;left:0;top:0;width:5px}&.ag-resizer-top{cursor:ns-resize;height:5px;left:5px;right:5px;top:0}&.ag-resizer-topRight{cursor:nesw-resize;height:5px;right:0;top:0;width:5px}&.ag-resizer-right{bottom:5px;cursor:ew-resize;right:0;top:5px;width:5px}&.ag-resizer-bottomRight{bottom:0;cursor:nwse-resize;height:5px;right:0;width:5px}&.ag-resizer-bottom{bottom:0;cursor:ns-resize;height:5px;left:5px;right:5px}&.ag-resizer-bottomLeft{bottom:0;cursor:nesw-resize;height:5px;left:0;width:5px}&.ag-resizer-left{bottom:5px;cursor:ew-resize;left:0;top:5px;width:5px}}',Gw,Ww,wp=typeof window!="object"||!((Ww=(Gw=window==null?void 0:window.document)==null?void 0:Gw.fonts)!=null&&Ww.forEach),zi=(e,t,r,n,i,o)=>{if(wp)return;n&&(e=`@layer ${CSS.escape(n)} { ${e} }`);let s=Ti.map.get(t);if(s||(s=[],Ti.map.set(t,s)),s.find(u=>u.css===e))return;const a=document.createElement("style");o&&a.setAttribute("nonce",o),a.dataset.agGlobalCss=r,a.textContent=e;const l={css:e,el:a,priority:i};let c;for(const u of s){if(u.priority>i)break;c=u}if(c){c.el.insertAdjacentElement("afterend",a);const u=s.indexOf(c);s.splice(u+1,0,l)}else t.insertBefore(a,t.querySelector(":not(title, meta)")),s.push(l)},fS=(e,t,r)=>{zi(I8,e,"core",t,0,r),Array.from(H_()).sort((n,i)=>n.moduleName.localeCompare(i.moduleName)).forEach(n=>{var i;return(i=n.css)==null?void 0:i.forEach(o=>zi(o,e,`module-${n.moduleName}`,t,0,r))})},_8=e=>{Ti.grids.add(e)},L8=e=>{if(Ti.grids.delete(e),Ti.grids.size===0){Ti.map=new WeakMap;for(const t of document.head.querySelectorAll("style[data-ag-global-css]"))t.remove()}},ny,Ti=(ny=typeof window=="object"?window:{}).agStyleInjectionState??(ny.agStyleInjectionState={map:new WeakMap,grids:new Set}),Ot=e=>new gS(e),Qr="$default",B8=0,gS=class{constructor({feature:e,params:t,modeParams:r={},css:n,cssImports:i}){this.feature=e,this.css=n,this.cssImports=i,this.modeParams={[Qr]:{...r[Qr]??{},...t??{}},...r}}use(e,t,r){let n=this._inject;if(n==null){let{css:i}=this;if(i){const o=`ag-theme-${this.feature??"part"}-${++B8}`;typeof i=="function"&&(i=i()),i=`:where(.${o}) {
4
+ ${i}
5
+ }
6
+ `;for(const s of this.cssImports??[])i=`@import url(${JSON.stringify(s)});
7
+ ${i}`;n={css:i,class:o}}else n=!1;this._inject=n}return n&&e&&zi(n.css,e,n.class,t,1,r),n?n.class:!1}},z8=e=>e.replace(/[A-Z]/g,t=>`-${t}`).toLowerCase(),pS=e=>`--ag-${z8(e)}`,xr=e=>`var(${pS(e)})`,N8=(e,t,r)=>Math.max(t,Math.min(r,e)),$8=e=>{const t=new Map;return r=>{const n=r;return t.has(n)||t.set(n,e(r)),t.get(n)}},_t=e=>({ref:"accentColor",mix:e}),jt=e=>({ref:"foregroundColor",mix:e}),Ct=e=>({ref:"foregroundColor",mix:e,onto:"backgroundColor"}),H8=e=>({ref:"foregroundColor",mix:e,onto:"headerBackgroundColor"}),bt={ref:"backgroundColor"},$o={ref:"foregroundColor"},it={ref:"accentColor"},Ds={backgroundColor:"#fff",foregroundColor:"#181d1f",borderColor:jt(.15),chromeBackgroundColor:Ct(.02),browserColorScheme:"light"},G8={...Ds,textColor:$o,accentColor:"#2196f3",invalidColor:"#e02525",wrapperBorder:!0,rowBorder:!0,headerRowBorder:!0,footerRowBorder:{ref:"rowBorder"},columnBorder:{style:"solid",width:1,color:"transparent"},headerColumnBorder:!1,headerColumnBorderHeight:"100%",pinnedColumnBorder:!0,pinnedRowBorder:!0,sidePanelBorder:!0,sideBarPanelWidth:250,sideBarBackgroundColor:{ref:"chromeBackgroundColor"},sideButtonBarBackgroundColor:{ref:"sideBarBackgroundColor"},sideButtonBarTopPadding:0,sideButtonSelectedUnderlineWidth:2,sideButtonSelectedUnderlineColor:"transparent",sideButtonSelectedUnderlineTransitionDuration:0,sideButtonBackgroundColor:"transparent",sideButtonTextColor:{ref:"textColor"},sideButtonHoverBackgroundColor:{ref:"sideButtonBackgroundColor"},sideButtonHoverTextColor:{ref:"sideButtonTextColor"},sideButtonSelectedBackgroundColor:bt,sideButtonSelectedTextColor:{ref:"sideButtonTextColor"},sideButtonBorder:"solid 1px transparent",sideButtonSelectedBorder:!0,sideButtonLeftPadding:{ref:"spacing"},sideButtonRightPadding:{ref:"spacing"},sideButtonVerticalPadding:{calc:"spacing * 3"},fontFamily:["-apple-system","BlinkMacSystemFont","Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue","sans-serif"],headerBackgroundColor:{ref:"chromeBackgroundColor"},headerFontFamily:{ref:"fontFamily"},cellFontFamily:{ref:"fontFamily"},headerFontWeight:500,headerFontSize:{ref:"fontSize"},dataFontSize:{ref:"fontSize"},headerTextColor:{ref:"textColor"},headerCellHoverBackgroundColor:"transparent",headerCellMovingBackgroundColor:{ref:"headerCellHoverBackgroundColor"},headerCellBackgroundTransitionDuration:"0.2s",cellTextColor:{ref:"textColor"},subtleTextColor:{ref:"textColor",mix:.5},rangeSelectionBorderStyle:"solid",rangeSelectionBorderColor:it,rangeSelectionBackgroundColor:_t(.2),rangeSelectionChartBackgroundColor:"#0058FF1A",rangeSelectionChartCategoryBackgroundColor:"#00FF841A",rangeSelectionHighlightColor:_t(.5),rangeHeaderHighlightColor:H8(.08),rowNumbersSelectedColor:_t(.5),rowHoverColor:_t(.08),columnHoverColor:_t(.05),selectedRowBackgroundColor:_t(.12),modalOverlayBackgroundColor:{ref:"backgroundColor",mix:.66},oddRowBackgroundColor:bt,borderRadius:4,wrapperBorderRadius:8,cellHorizontalPadding:{calc:"spacing * 2 * cellHorizontalPaddingScale"},cellWidgetSpacing:{calc:"spacing * 1.5"},cellHorizontalPaddingScale:1,rowGroupIndentSize:{calc:"cellWidgetSpacing + iconSize"},valueChangeDeltaUpColor:"#43a047",valueChangeDeltaDownColor:"#e53935",valueChangeValueHighlightBackgroundColor:"#16a08580",spacing:8,fontSize:14,rowHeight:{calc:"max(iconSize, dataFontSize) + spacing * 3.25 * rowVerticalPaddingScale"},rowVerticalPaddingScale:1,headerHeight:{calc:"max(iconSize, dataFontSize) + spacing * 4 * headerVerticalPaddingScale"},headerVerticalPaddingScale:1,popupShadow:"0 0 16px #00000026",cardShadow:"0 1px 4px 1px #00000018",dropdownShadow:{ref:"cardShadow"},dragAndDropImageBackgroundColor:bt,dragAndDropImageBorder:!0,dragAndDropImageShadow:{ref:"popupShadow"},dragHandleColor:jt(.7),focusShadow:{spread:3,color:_t(.5)},headerColumnResizeHandleHeight:"30%",headerColumnResizeHandleWidth:2,headerColumnResizeHandleColor:{ref:"borderColor"},widgetContainerHorizontalPadding:{calc:"spacing * 1.5"},widgetContainerVerticalPadding:{calc:"spacing * 1.5"},widgetHorizontalSpacing:{calc:"spacing * 1.5"},widgetVerticalSpacing:{ref:"spacing"},listItemHeight:{calc:"max(iconSize, dataFontSize) + widgetVerticalSpacing"},iconSize:16,iconColor:"inherit",iconButtonColor:{ref:"iconColor"},iconButtonBackgroundColor:"transparent",iconButtonBackgroundSpread:4,iconButtonBorderRadius:1,iconButtonHoverColor:{ref:"iconButtonColor"},iconButtonHoverBackgroundColor:jt(.1),iconButtonActiveColor:it,iconButtonActiveBackgroundColor:_t(.28),iconButtonActiveIndicatorColor:it,toggleButtonWidth:28,toggleButtonHeight:18,toggleButtonOnBackgroundColor:it,toggleButtonOffBackgroundColor:Ct(.3),toggleButtonSwitchBackgroundColor:bt,toggleButtonSwitchInset:2,menuBorder:{color:jt(.2)},menuBackgroundColor:Ct(.03),menuTextColor:Ct(.95),menuShadow:{ref:"popupShadow"},menuSeparatorColor:{ref:"borderColor"},setFilterIndentSize:{ref:"iconSize"},chartMenuPanelWidth:260,chartMenuLabelColor:jt(.8),dialogShadow:{ref:"popupShadow"},cellEditingBorder:{color:it},cellEditingShadow:{ref:"cardShadow"},dialogBorder:{color:jt(.2)},panelBackgroundColor:bt,panelTitleBarBackgroundColor:{ref:"headerBackgroundColor"},panelTitleBarIconColor:{ref:"headerTextColor"},panelTitleBarTextColor:{ref:"headerTextColor"},panelTitleBarFontWeight:{ref:"headerFontWeight"},panelTitleBarBorder:!0,columnSelectIndentSize:{ref:"iconSize"},toolPanelSeparatorBorder:!0,tooltipBackgroundColor:{ref:"chromeBackgroundColor"},tooltipTextColor:{ref:"textColor"},tooltipBorder:!0,columnDropCellBackgroundColor:jt(.07),columnDropCellTextColor:{ref:"textColor"},columnDropCellDragHandleColor:{ref:"textColor"},columnDropCellBorder:{color:jt(.13)},selectCellBackgroundColor:jt(.07),selectCellBorder:{color:jt(.13)},advancedFilterBuilderButtonBarBorder:!0,advancedFilterBuilderIndentSize:{calc:"spacing * 2 + iconSize"},advancedFilterBuilderJoinPillColor:"#f08e8d",advancedFilterBuilderColumnPillColor:"#a6e194",advancedFilterBuilderOptionPillColor:"#f3c08b",advancedFilterBuilderValuePillColor:"#85c0e4",findMatchColor:$o,findMatchBackgroundColor:"#ffff00",findActiveMatchColor:$o,findActiveMatchBackgroundColor:"#ffa500",filterToolPanelGroupIndent:{ref:"spacing"},rowLoadingSkeletonEffectColor:jt(.15),statusBarLabelColor:$o,statusBarLabelFontWeight:500,statusBarValueColor:$o,statusBarValueFontWeight:500,pinnedSourceRowTextColor:{ref:"textColor"},pinnedSourceRowBackgroundColor:{ref:"backgroundColor"},pinnedSourceRowFontWeight:600,pinnedRowFontWeight:600,pinnedRowBackgroundColor:{ref:"backgroundColor"},pinnedRowTextColor:{ref:"textColor"}},mS=":where(.ag-button){background:none;border:none;color:inherit;cursor:pointer;font-family:inherit;font-size:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0;text-indent:inherit;text-shadow:inherit;text-transform:inherit;word-spacing:inherit;&:disabled{cursor:default}&:focus-visible{box-shadow:var(--ag-focus-shadow);outline:none}}.ag-standard-button{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--ag-button-background-color);border:var(--ag-button-border);border-radius:var(--ag-button-border-radius);color:var(--ag-button-text-color);cursor:pointer;font-weight:var(--ag-button-font-weight);padding:var(--ag-button-vertical-padding) var(--ag-button-horizontal-padding);&:hover{background-color:var(--ag-button-hover-background-color);border:var(--ag-button-hover-border);color:var(--ag-button-hover-text-color)}&:active{background-color:var(--ag-button-active-background-color);border:var(--ag-button-active-border);color:var(--ag-button-active-text-color)}&:disabled{background-color:var(--ag-button-disabled-background-color);border:var(--ag-button-disabled-border);color:var(--ag-button-disabled-text-color)}}",vS={buttonTextColor:"inherit",buttonFontWeight:"normal",buttonBackgroundColor:"transparent",buttonBorder:!1,buttonBorderRadius:{ref:"borderRadius"},buttonHorizontalPadding:{calc:"spacing * 2"},buttonVerticalPadding:{ref:"spacing"},buttonHoverTextColor:{ref:"buttonTextColor"},buttonHoverBackgroundColor:{ref:"buttonBackgroundColor"},buttonHoverBorder:{ref:"buttonBorder"},buttonActiveTextColor:{ref:"buttonHoverTextColor"},buttonActiveBackgroundColor:{ref:"buttonHoverBackgroundColor"},buttonActiveBorder:{ref:"buttonHoverBorder"},buttonDisabledTextColor:{ref:"inputDisabledTextColor"},buttonDisabledBackgroundColor:{ref:"inputDisabledBackgroundColor"},buttonDisabledBorder:{ref:"inputDisabledBorder"}},W8=()=>Ot({feature:"buttonStyle",params:{...vS,buttonBackgroundColor:bt,buttonBorder:!0,buttonHoverBackgroundColor:{ref:"rowHoverColor"},buttonActiveBorder:{color:it}},css:mS}),j8=W8(),V8=()=>Ot({feature:"buttonStyle",params:{...vS,buttonBackgroundColor:bt,buttonBorder:{color:it},buttonFontWeight:600,buttonTextColor:it,buttonHoverBackgroundColor:{ref:"rowHoverColor"},buttonActiveBackgroundColor:it,buttonActiveTextColor:bt},css:mS}),U8=V8(),K8=".ag-column-drop-vertical-empty-message{align-items:center;border:1px dashed;border-color:var(--ag-border-color);display:flex;inset:0;justify-content:center;margin:calc(var(--ag-spacing)*1.5) calc(var(--ag-spacing)*2);overflow:hidden;padding:calc(var(--ag-spacing)*2);position:absolute}",q8=()=>Ot({feature:"columnDropStyle",css:K8}),Sp=q8(),Y8=["colorScheme","color","length","scale","borderStyle","border","shadow","image","fontFamily","fontWeight","duration"],J8=$8(e=>(e=e.toLowerCase(),Y8.find(t=>e.endsWith(t.toLowerCase()))??"length")),hu=e=>typeof e=="object"&&(e!=null&&e.ref)?xr(e.ref):typeof e=="string"?e:typeof e=="number"?String(e):!1,xp=e=>{if(typeof e=="string")return e;if(e&&"ref"in e){const t=xr(e.ref);return e.mix==null?t:`color-mix(in srgb, ${e.onto?xr(e.onto):"transparent"}, ${t} ${N8(e.mix*100,0,100)}%)`}return!1},X8=hu,mi=e=>typeof e=="string"?e:typeof e=="number"?`${e}px`:e&&"calc"in e?`calc(${e.calc.replace(/ ?[*/+] ?/g," $& ").replace(/-?\b[a-z][a-z0-9]*\b(?![-(])/gi,r=>r[0]==="-"?r:` ${xr(r)} `)})`:e&&"ref"in e?xr(e.ref):!1,Z8=hu,Q8=(e,t)=>typeof e=="string"?e:e===!0?"solid 1px var(--ag-border-color)":e===!1?t==="columnBorder"?"solid 1px transparent":"none":e&&"ref"in e?xr(e.ref):yS(e.style??"solid")+" "+mi(e.width??1)+" "+xp(e.color??{ref:"borderColor"}),ez=e=>typeof e=="string"?e:e===!1?"none":e&&"ref"in e?xr(e.ref):[mi(e.offsetX??0),mi(e.offsetY??0),mi(e.radius??0),mi(e.spread??0),xp(e.color??{ref:"foregroundColor"})].join(" "),yS=hu,bS=e=>typeof e=="string"?e.includes(",")?e:iy(e):e&&"googleFont"in e?bS(e.googleFont):e&&"ref"in e?xr(e.ref):Array.isArray(e)?e.map(t=>(typeof t=="object"&&"googleFont"in t&&(t=t.googleFont),iy(t))).join(", "):!1,iy=e=>/^[\w-]+$|\w\(/.test(e)?e:JSON.stringify(e),tz=hu,CS=e=>typeof e=="string"?e:e&&"url"in e?`url(${JSON.stringify(e.url)})`:e&&"svg"in e?CS({url:`data:image/svg+xml,${encodeURIComponent(e.svg)}`}):e&&"ref"in e?xr(e.ref):!1,rz=(e,t)=>typeof e=="string"?e:typeof e=="number"?(e>=10&&_e(104,{value:e,param:t}),`${e}s`):e&&"ref"in e?xr(e.ref):!1,nz={color:xp,colorScheme:X8,length:mi,scale:Z8,border:Q8,borderStyle:yS,shadow:ez,image:CS,fontFamily:bS,fontWeight:tz,duration:rz},iz=(e,t)=>{const r=J8(e);return nz[r](t,e)},wS=()=>new SS().withPart(j8).withPart(Sp),SS=class xS{constructor(t=[]){this.parts=t}withPart(t){return typeof t=="function"&&(t=t()),t instanceof gS?new xS([...this.parts,t]):(Zo(259,{part:t},"Invalid part"),this)}withoutPart(t){return this.withPart(Ot({feature:t}))}withParams(t,r=Qr){return this.withPart(Ot({modeParams:{[r]:t}}))}_startUse({styleContainer:t,cssLayer:r,nonce:n,loadThemeGoogleFonts:i}){if(wp)return;sz(),fS(t,r,n);const o=oz(this);if(o.length>0)for(const s of o)i&&lz(s,n);for(const s of this.parts)s.use(t,r,n)}_getCssClass(){return this._cssClassCache??(this._cssClassCache=oy(this.parts).map(t=>t.use(void 0,void 0,void 0)).filter(Boolean).join(" "))}_getModeParams(){let t=this._paramsCache;if(!t){const r={[Qr]:{...G8}};for(const n of oy(this.parts))for(const i of Object.keys(n.modeParams)){const o=n.modeParams[i];if(o){const s=r[i]??(r[i]={}),a=new Set;for(const l of Object.keys(o)){const c=o[l];c!==void 0&&(s[l]=c,a.add(l))}if(i===Qr)for(const l of Object.keys(r)){const c=r[l];if(l!==Qr)for(const u of a)delete c[u]}}}this._paramsCache=t=r}return t}_getPerGridCss(t){const r="##SELECTOR##";let n=this._paramsCssCache;if(!n){let i="",o="";const s=this._getModeParams();for(const l of Object.keys(s)){const c=s[l];if(l!==Qr){const d=`:where([data-ag-theme-mode="${typeof CSS=="object"?CSS.escape(l):l}"]) & {
8
+ `;i+=d,o+=d}for(const u of Object.keys(c).sort()){const d=c[u],h=iz(u,d);if(h===!1)_e(107,{key:u,value:d});else{const f=pS(u),g=f.replace("--ag-","--ag-inherited-");i+=` ${f}: var(${g}, ${h});
9
+ `,o+=` ${g}: var(${f});
10
+ `}}l!==Qr&&(i+=`}
11
+ `,o+=`}
12
+ `)}let a=`${r} {
13
+ ${i}}
14
+ `;a+=`:has(> ${r}):not(${r}) {
15
+ ${o}}
16
+ `,this._paramsCssCache=n=a}return n.replaceAll(r,`:where(.${t})`)}},oy=e=>{const t=new Map;for(const n of e)t.set(n.feature,n);const r=[];for(const n of e)(!n.feature||t.get(n.feature)===n)&&r.push(n);return r},oz=e=>{const t=new Set,r=o=>{if(Array.isArray(o))o.forEach(r);else{const s=o==null?void 0:o.googleFont;typeof s=="string"&&t.add(s)}};return Object.values(e._getModeParams()).flatMap(o=>Object.values(o)).forEach(r),Array.from(t).sort()},sy=!1,sz=()=>{if(!sy){sy=!0;for(const e of Array.from(document.head.querySelectorAll('style[data-ag-scope="legacy"]')))e.remove()}},az=new Set,lz=async(e,t)=>{az.add(e);const r=`@import url('https://${cz}/css2?family=${encodeURIComponent(e)}:wght@100;200;300;400;500;600;700;800;900&display=swap');
17
+ `;zi(r,document.head,`googleFont:${e}`,void 0,0,t)},cz="fonts.googleapis.com",uz='.ag-checkbox-input-wrapper,.ag-radio-button-input-wrapper{background-color:var(--ag-checkbox-unchecked-background-color);border:solid var(--ag-checkbox-border-width) var(--ag-checkbox-unchecked-border-color);flex:none;height:var(--ag-icon-size);position:relative;width:var(--ag-icon-size);:where(input){-webkit-appearance:none;-moz-appearance:none;appearance:none;cursor:pointer;display:block;height:var(--ag-icon-size);margin:0;opacity:0;width:var(--ag-icon-size)}&:after{content:"";display:block;inset:0;-webkit-mask-position:center;mask-position:center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;pointer-events:none;position:absolute}&:where(.ag-checked){background-color:var(--ag-checkbox-checked-background-color);border-color:var(--ag-checkbox-checked-border-color);&:after{background-color:var(--ag-checkbox-checked-shape-color)}}&:where(:focus-within,:active){box-shadow:var(--ag-focus-shadow)}&:where(.ag-disabled){filter:grayscale();opacity:.5}}.ag-checkbox-input-wrapper{border-radius:var(--ag-checkbox-border-radius);&:where(.ag-checked):after{-webkit-mask-image:var(--ag-checkbox-checked-shape-image);mask-image:var(--ag-checkbox-checked-shape-image)}&:where(.ag-indeterminate){background-color:var(--ag-checkbox-indeterminate-background-color);border-color:var(--ag-checkbox-indeterminate-border-color);&:after{background-color:var(--ag-checkbox-indeterminate-shape-color);-webkit-mask-image:var(--ag-checkbox-indeterminate-shape-image);mask-image:var(--ag-checkbox-indeterminate-shape-image)}}}.ag-radio-button-input-wrapper{border-radius:100%;&:where(.ag-checked):after{-webkit-mask-image:var(--ag-radio-checked-shape-image);mask-image:var(--ag-radio-checked-shape-image)}}',dz=()=>Ot({feature:"checkboxStyle",params:{checkboxBorderWidth:1,checkboxBorderRadius:{ref:"borderRadius"},checkboxUncheckedBackgroundColor:bt,checkboxUncheckedBorderColor:Ct(.3),checkboxCheckedBackgroundColor:it,checkboxCheckedBorderColor:{ref:"checkboxCheckedBackgroundColor"},checkboxCheckedShapeImage:{svg:'<svg xmlns="http://www.w3.org/2000/svg" width="10" height="7" fill="none"><path stroke="#000" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.75" d="M1 3.5 3.5 6l5-5"/></svg>'},checkboxCheckedShapeColor:bt,checkboxIndeterminateBackgroundColor:Ct(.3),checkboxIndeterminateBorderColor:{ref:"checkboxIndeterminateBackgroundColor"},checkboxIndeterminateShapeImage:{svg:'<svg xmlns="http://www.w3.org/2000/svg" width="10" height="2" fill="none"><rect width="10" height="2" fill="#000" rx="1"/></svg>'},checkboxIndeterminateShapeColor:bt,radioCheckedShapeImage:{svg:'<svg xmlns="http://www.w3.org/2000/svg" width="6" height="6" fill="none"><circle cx="3" cy="3" r="3" fill="#000"/></svg>'}},css:uz}),AS=dz(),hz=()=>Ot({feature:"colorScheme",params:Ds}),fz=hz(),Ap=()=>({...Ds,backgroundColor:"hsl(217, 0%, 17%)",foregroundColor:"#FFF",chromeBackgroundColor:Ct(.05),rowHoverColor:_t(.15),selectedRowBackgroundColor:_t(.2),menuBackgroundColor:Ct(.1),browserColorScheme:"dark",popupShadow:"0 0px 20px #000A",cardShadow:"0 1px 4px 1px #000A",advancedFilterBuilderJoinPillColor:"#7a3a37",advancedFilterBuilderColumnPillColor:"#355f2d",advancedFilterBuilderOptionPillColor:"#5a3168",advancedFilterBuilderValuePillColor:"#374c86",findMatchColor:bt,findActiveMatchColor:bt,checkboxUncheckedBorderColor:Ct(.4),toggleButtonOffBackgroundColor:Ct(.4)}),gz=()=>Ot({feature:"colorScheme",params:Ap()}),pz=gz(),mz=()=>({...Ap(),backgroundColor:"#1f2836"}),vz=()=>Ot({feature:"colorScheme",params:Ds,modeParams:{light:Ds,dark:Ap(),"dark-blue":mz()}}),PS=vz(),yz=`.ag-icon-aggregation:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M24 6H8v2l8 8-8 8v2h16v-2H11l8-8-8-8h13z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-arrows:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M7.515 11.171 2.687 16l4.828 4.829-1.414 1.414L-.142 16l6.243-6.243zm16.97 0 1.414-1.414L32.142 16l-6.243 6.243-1.414-1.414L29.313 16zM16.028 13.2l2.829 2.828-2.829 2.829-2.828-2.829zm-4.857 11.285L16 29.313l4.829-4.828 1.414 1.414L16 32.142l-6.243-6.243zm0-16.97L9.757 6.101 16-.142l6.243 6.243-1.414 1.414L16 2.687z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-asc:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m5.333 16 1.88 1.88 7.453-7.44v16.227h2.667V10.44l7.44 7.453L26.666 16 15.999 5.333 5.332 16z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-cancel:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M16 2.667A13.32 13.32 0 0 0 2.667 16c0 7.373 5.96 13.333 13.333 13.333S29.333 23.373 29.333 16 23.373 2.667 16 2.667m6.667 18.12-1.88 1.88L16 17.88l-4.787 4.787-1.88-1.88L14.12 16l-4.787-4.787 1.88-1.88L16 14.12l4.787-4.787 1.88 1.88L17.88 16z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-chart:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Echart%3C/title%3E%3Cg fill='%23000' fill-rule='nonzero'%3E%3Cpath d='M14 7h4v18h-4zM8 17h4v8H8zM20 13h4v12h-4z'/%3E%3C/g%3E%3C/svg%3E")}.ag-icon-color-picker:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M23.907 17.587 10.574 4.254l-1.88 1.88 3.173 3.173-8.28 8.28 10.16 10.16zm-16.547 0 6.387-6.387 6.387 6.387zm18.387 2s-2.667 2.893-2.667 4.667c0 1.467 1.2 2.667 2.667 2.667s2.667-1.2 2.667-2.667c0-1.773-2.667-4.667-2.667-4.667' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-columns:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M26 25H6V7h20zM12 11H8v12h4zm6 0h-4v12h4zm6 12V11h-4v12z' style='fill-rule:nonzero' transform='translate(0 -1)'/%3E%3C/svg%3E")}.ag-icon-contracted:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m12 6 10 10-10 10-2-2 8-8-8-8z'/%3E%3C/svg%3E")}.ag-icon-copy:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M22 1.333H6A2.675 2.675 0 0 0 3.333 4v18.667H6V4h16zm4 5.334H11.333a2.675 2.675 0 0 0-2.667 2.667v18.667c0 1.467 1.2 2.667 2.667 2.667H26c1.467 0 2.667-1.2 2.667-2.667V9.334c0-1.467-1.2-2.667-2.667-2.667M26 28H11.333V9.333H26z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-cross:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M15.984 13.894 27.05 2.828l2.122 2.122-11.066 11.066 11.066 11.066-2.122 2.12-11.066-11.066L4.918 29.202l-2.12-2.12 11.066-11.066L2.798 4.95l2.12-2.122z'/%3E%3C/svg%3E")}.ag-icon-csv:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M384 131.9c-7.753-8.433-110.425-128.473-114.9-133L48-.1C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48zm-35.9 2.1H257V27.9zM30 479V27h200l1 105c0 13.3-1.3 29 12 29h111l1 318z' style='fill-rule:nonzero' transform='matrix(.06285 0 0 .06285 3.934 -.054)'/%3E%3Cpath d='M.688-.226a.2.2 0 0 1-.017.074.28.28 0 0 1-.145.14.412.412 0 0 1-.234.013.28.28 0 0 1-.202-.168.468.468 0 0 1-.04-.19q0-.086.025-.155a.319.319 0 0 1 .182-.191.4.4 0 0 1 .134-.025q.087 0 .155.035a.3.3 0 0 1 .104.085.17.17 0 0 1 .036.097.06.06 0 0 1-.018.044.06.06 0 0 1-.042.019.06.06 0 0 1-.042-.013.2.2 0 0 1-.031-.046.2.2 0 0 0-.066-.079.16.16 0 0 0-.095-.027.17.17 0 0 0-.142.068.3.3 0 0 0-.053.193.4.4 0 0 0 .023.139.2.2 0 0 0 .067.083.2.2 0 0 0 .1.027q.063 0 .106-.031a.2.2 0 0 0 .065-.091.2.2 0 0 1 .023-.046q.014-.018.044-.018a.06.06 0 0 1 .044.018.06.06 0 0 1 .019.045' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 7.122 25.977)'/%3E%3Cpath d='M.622-.215a.2.2 0 0 1-.033.117.23.23 0 0 1-.098.081.4.4 0 0 1-.153.029.34.34 0 0 1-.175-.04.23.23 0 0 1-.079-.077.17.17 0 0 1-.031-.093q0-.027.019-.045a.06.06 0 0 1 .046-.019.06.06 0 0 1 .039.014.1.1 0 0 1 .027.044.3.3 0 0 0 .03.057q.015.023.044.038.03.015.076.015.065 0 .105-.03a.09.09 0 0 0 .04-.075.08.08 0 0 0-.022-.058.14.14 0 0 0-.056-.034 1 1 0 0 0-.092-.025.7.7 0 0 1-.129-.042.2.2 0 0 1-.083-.066.17.17 0 0 1-.03-.104q0-.058.032-.105a.2.2 0 0 1 .093-.07.4.4 0 0 1 .144-.025q.066 0 .114.016a.3.3 0 0 1 .08.044.2.2 0 0 1 .046.057q.015.03.015.058a.07.07 0 0 1-.018.046.06.06 0 0 1-.046.021q-.025 0-.038-.012a.2.2 0 0 1-.028-.041.2.2 0 0 0-.047-.063Q.387-.625.326-.625a.15.15 0 0 0-.09.025q-.035.024-.035.059 0 .021.012.037a.1.1 0 0 0 .032.027.4.4 0 0 0 .111.036q.06.015.11.031.048.018.083.042a.2.2 0 0 1 .054.062.2.2 0 0 1 .019.091' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 13.339 25.977)'/%3E%3Cpath d='m.184-.633.162.48.163-.483q.013-.038.019-.053a.062.062 0 0 1 .061-.039q.018 0 .034.009a.1.1 0 0 1 .025.025q.009.015.009.031L.654-.64l-.007.025-.009.024-.173.468-.019.051a.2.2 0 0 1-.021.042.1.1 0 0 1-.033.03.1.1 0 0 1-.049.012.1.1 0 0 1-.05-.011A.1.1 0 0 1 .26-.03a.2.2 0 0 1-.021-.042L.22-.123.05-.587.041-.612.033-.638.03-.662q0-.025.02-.046a.07.07 0 0 1 .05-.02q.037 0 .053.023.015.023.031.072' style='fill-rule:nonzero' transform='matrix(8.39799 0 0 12.455 18.94 25.977)'/%3E%3C/svg%3E")}.ag-icon-cut:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M13.775 15.198 3.835 2.945a1.501 1.501 0 0 1 2.33-1.89l14.997 18.488A6.003 6.003 0 0 1 29.657 25c0 3.311-2.688 6-6 6s-6-2.689-6-6c0-1.335.437-2.569 1.176-3.566l-3.127-3.855-3.001 3.7A5.97 5.97 0 0 1 14 25c0 3.311-2.689 6-6 6s-6-2.689-6-6a6.003 6.003 0 0 1 8.315-5.536zm9.882 6.702a3.1 3.1 0 0 0-3.1 3.1c0 1.711 1.389 3.1 3.1 3.1s3.1-1.389 3.1-3.1-1.389-3.1-3.1-3.1M8 21.95a3.05 3.05 0 1 0 .001 6.101A3.05 3.05 0 0 0 8 21.95m9.63-11.505 1.932 2.381 8.015-9.881a1.5 1.5 0 0 0-2.329-1.89z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-desc:before,.ag-icon-down:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m26.667 16-1.88-1.88-7.453 7.44V5.333h-2.667V21.56l-7.44-7.453L5.334 16l10.667 10.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-excel:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M384 131.9c-7.753-8.433-110.425-128.473-114.9-133L48-.1C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48zm-35.9 2.1H257V27.9zM30 479V27h200l1 105c0 13.3-1.3 29 12 29h111l1 318z' style='fill-rule:nonzero' transform='matrix(.06285 0 0 .06285 3.934 -.054)'/%3E%3Cpath d='m.052-.139.16-.234-.135-.208a.4.4 0 0 1-.028-.052.1.1 0 0 1-.01-.042.05.05 0 0 1 .018-.037.07.07 0 0 1 .045-.016q.03 0 .047.018a1 1 0 0 1 .047.066l.107.174.115-.174.024-.038.019-.026.021-.015a.1.1 0 0 1 .027-.005.06.06 0 0 1 .044.016.05.05 0 0 1 .018.039q0 .033-.038.089l-.141.211.152.234a.3.3 0 0 1 .03.051.1.1 0 0 1 .009.038.1.1 0 0 1-.008.031.1.1 0 0 1-.024.023.1.1 0 0 1-.034.008.1.1 0 0 1-.035-.008.1.1 0 0 1-.023-.022L.427-.067.301-.265l-.134.204-.022.034-.016.019a.1.1 0 0 1-.022.015.1.1 0 0 1-.03.005.06.06 0 0 1-.044-.016.06.06 0 0 1-.017-.047q0-.036.036-.088' style='fill-rule:nonzero' transform='matrix(17.82892 0 0 16.50777 10.371 25.928)'/%3E%3C/svg%3E")}.ag-icon-expanded:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M20 26 10 16 20 6l2 2-8 8 8 8z'/%3E%3C/svg%3E")}.ag-icon-eye-slash:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Eeye-slash%3C/title%3E%3Cpath fill='%23000' fill-rule='nonzero' d='M8.95 10.364 7 8.414 8.414 7l2.32 2.32A13.2 13.2 0 0 1 16.5 8c5.608 0 10.542 3.515 12.381 8.667L29 17l-.119.333a13 13 0 0 1-4.255 5.879l1.466 1.466-1.414 1.414-1.754-1.753A13.2 13.2 0 0 1 16.5 26c-5.608 0-10.542-3.515-12.381-8.667L4 17l.119-.333a13 13 0 0 1 4.83-6.303m1.445 1.445A11.02 11.02 0 0 0 6.148 17c1.646 4.177 5.728 7 10.352 7 1.76 0 3.441-.409 4.94-1.146l-1.878-1.878A5.06 5.06 0 0 1 16.5 22c-2.789 0-5.05-2.239-5.05-5 0-1.158.398-2.223 1.065-3.07zm1.855-.974 1.794 1.795A5.07 5.07 0 0 1 16.5 12c2.789 0 5.05 2.239 5.05 5 0 .9-.24 1.745-.661 2.474l2.305 2.306A11 11 0 0 0 26.852 17c-1.646-4.177-5.728-7-10.352-7-1.495 0-2.933.295-4.25.835'/%3E%3C/svg%3E")}.ag-icon-eye:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M16.5 23c4.624 0 8.706-2.823 10.352-7-1.646-4.177-5.728-7-10.352-7s-8.706 2.823-10.352 7c1.646 4.177 5.728 7 10.352 7M4.119 15.667C5.958 10.515 10.892 7 16.5 7s10.542 3.515 12.381 8.667L29 16l-.119.333C27.042 21.485 22.108 25 16.5 25S5.958 21.485 4.119 16.333L4 16zM16.5 21c2.789 0 5.049-2.239 5.049-5s-2.26-5-5.049-5-5.049 2.239-5.049 5 2.26 5 5.049 5' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-filter:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m28 8-8 8v5l-6 6V16L6 8V6h22zM9 8l7 7v7l2-2v-5l7-7z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-first:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M24.273 22.12 18.153 16l6.12-6.12L22.393 8l-8 8 8 8zM7.727 8h2.667v16H7.727z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-group:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M14 7v1H9V7zm0-3v1H5.001V4zm-7 7H5v-1h2zm0-3H5V7h2zM3 5H1V4h2zm11 5v1H9v-1zm-7 4H5v-1h2zm7-1v1H9v-1z' style='fill-rule:nonzero' transform='matrix(2 0 0 2 0 -2)'/%3E%3C/svg%3E")}.ag-icon-last:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m7.727 9.88 6.12 6.12-6.12 6.12L9.607 24l8-8-8-8zM21.607 8h2.667v16h-2.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-left:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M26.667 14.667H10.44l7.453-7.453L16 5.334 5.333 16.001 16 26.668l1.88-1.88-7.44-7.453h16.227z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-linked:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M5.2 16a4.136 4.136 0 0 1 4.133-4.133h5.333V9.334H9.333a6.67 6.67 0 0 0-6.667 6.667 6.67 6.67 0 0 0 6.667 6.667h5.333v-2.533H9.333A4.136 4.136 0 0 1 5.2 16.002zm5.467 1.333h10.667v-2.667H10.667zm12-8h-5.333v2.533h5.333a4.136 4.136 0 0 1 4.133 4.133 4.136 4.136 0 0 1-4.133 4.133h-5.333v2.533h5.333a6.67 6.67 0 0 0 6.667-6.667 6.67 6.67 0 0 0-6.667-6.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-loading:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M17 29h-2v-8h2zm-3.586-9L7 26.414 5.586 25 12 18.586zm13 5L25 26.414 18.586 20 20 18.586zM29 17h-8v-2h8zm-18 0H3v-2h8zm2.414-5L12 13.414 5.586 7 7 5.586zm13-5L20 13.414 18.586 12 25 5.586zM17 11h-2V3h2z' style='fill-rule:nonzero' transform='translate(-3.692 -3.692)scale(1.23077)'/%3E%3C/svg%3E")}.ag-icon-maximize:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M14 30H2V18h2.828v7.05l8.254-8.252 2.12 2.12-8.252 8.254H14zm4-28h12v12h-2.828V6.95l-8.254 8.252-2.12-2.12 8.252-8.254H18z'/%3E%3C/svg%3E")}.ag-icon-menu:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M20 13H0v-2h20zm0-6H0V5h20zm0-6H0v-2h20z' style='fill-rule:nonzero' transform='translate(6 9)'/%3E%3C/svg%3E")}.ag-icon-menu-alt:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='%23000' d='M16 19a3 3 0 1 0 0-6 3 3 0 0 0 0 6M16 11a3 3 0 1 0 0-6 3 3 0 0 0 0 6M16 27a3 3 0 1 0 0-6 3 3 0 0 0 0 6'/%3E%3C/svg%3E")}.ag-icon-minimize:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M2 18h12v12h-2.828v-7.05l-8.254 8.252-2.12-2.12 8.252-8.254H2zm28-4H18V2h2.828v7.05L29.082.798l2.12 2.12-8.252 8.254H30z'/%3E%3C/svg%3E")}.ag-icon-minus:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M6.572 6.572a13.32 13.32 0 0 0 0 18.856 13.32 13.32 0 0 0 18.856 0 13.32 13.32 0 0 0 0-18.856 13.32 13.32 0 0 0-18.856 0m17.527 8.099v2.658H7.901v-2.658z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-next:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M10.94 6 9.06 7.88 17.167 16 9.06 24.12 10.94 26l10-10z' style='fill-rule:nonzero' transform='translate(1)'/%3E%3C/svg%3E")}.ag-icon-none:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ctitle%3Enone%3C/title%3E%3Cg fill='%23000' fill-rule='nonzero'%3E%3Cpath d='M23.708 14.645 16 6.939l-7.708 7.706 1.416 1.416L16 9.767l6.292 6.294zM23.708 20.355 16 28.061l-7.708-7.706 1.416-1.416L16 25.233l6.292-6.294z'/%3E%3C/g%3E%3C/svg%3E")}.ag-icon-not-allowed:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M16 2.667C8.64 2.667 2.667 8.64 2.667 16S8.64 29.333 16 29.333 29.333 23.36 29.333 16 23.36 2.667 16 2.667M5.333 16c0-5.893 4.773-10.667 10.667-10.667 2.467 0 4.733.84 6.533 2.253L7.586 22.533A10.54 10.54 0 0 1 5.333 16M16 26.667c-2.467 0-4.733-.84-6.533-2.253L24.414 9.467A10.54 10.54 0 0 1 26.667 16c0 5.893-4.773 10.667-10.667 10.667' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-paste:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M25.334 4H19.76C19.2 2.453 17.733 1.333 16 1.333S12.8 2.453 12.24 4H6.667A2.675 2.675 0 0 0 4 6.667V28c0 1.467 1.2 2.667 2.667 2.667h18.667c1.467 0 2.667-1.2 2.667-2.667V6.667C28.001 5.2 26.801 4 25.334 4M16 4c.733 0 1.333.6 1.333 1.333s-.6 1.333-1.333 1.333-1.333-.6-1.333-1.333S15.267 4 16 4m9.333 24H6.666V6.667h2.667v4h13.333v-4h2.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-pin:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m10.78 19.777-4.668-4.666s.032-1 .67-1.87c1.366-1.86 4.052-1.96 6.056-1.572l3.158-3.108c-.7-2.342 3.352-5.046 3.352-5.046l9.166 9.168q-.334.447-.67.894c-1.074 1.426-2.538 2.63-4.272 2.338l-3.32 3.218c.046.344.042.03.118 1.152.144 2.13-.64 4.324-2.632 5.34l-.746.364-4.798-4.798-7.292 7.294-1.416-1.416zm8.24-13.672c-.688.568-1.416 1.45-1.024 2.072l.49.722-4.986 4.988c-1.988-.506-4.346-.636-5.156.614l9.02 9.032q.14-.099.272-.21c1.226-1.08.764-3.04.498-4.9l4.79-4.79s1.47.938 2.936-.776l-6.79-6.79q-.026.019-.05.038' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-pivot:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M25.128 2.002c2.56.096 4.772 2.292 4.87 4.87a712 712 0 0 1 0 18.256c-.096 2.56-2.292 4.772-4.87 4.87a712 712 0 0 1-18.256 0c-2.558-.096-4.772-2.29-4.87-4.87a712 712 0 0 1 0-18.256c.096-2.56 2.292-4.772 4.87-4.87a712 712 0 0 1 18.256 0m2.966 7.954H9.892v18.136c5.086.13 10.18.098 15.264-.096 1.48-.094 2.746-1.35 2.84-2.84.192-5.064.226-10.134.098-15.2M3.968 24.1q.015.528.036 1.056c.094 1.484 1.354 2.746 2.84 2.84l1.012.036V24.1zM22 15.414l-.292.294-1.416-1.416L23 11.586l2.708 2.706-1.416 1.416-.292-.294v3.592c-.032 2.604-2.246 4.892-4.872 4.992L15.414 24l.294.292-1.416 1.416L11.586 23l2.706-2.708 1.416 1.416-.322.32c3.372.03 6.578-.164 6.614-3.034zM3.88 18.038c.002 1.346.012 2.694.038 4.04h3.938v-4.04zm.05-6.062a681 681 0 0 0-.044 4.042h3.97v-4.042zm5.962-7.99Q8.449 3.999 7.006 4c-1.57.02-2.946 1.348-3.004 2.922q-.02 1.517-.042 3.034h3.896v-2.02h2.036zm14.244-.016v3.966h3.898q-.017-.546-.038-1.092c-.094-1.48-1.35-2.746-2.84-2.84q-.51-.019-1.02-.034m-8.14-.054q-2.035.022-4.07.048v3.972h4.07zm6.106.008a213 213 0 0 0-4.07-.022v4.034h4.07z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-plus:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M6.572 6.572a13.32 13.32 0 0 0 0 18.856 13.32 13.32 0 0 0 18.856 0 13.32 13.32 0 0 0 0-18.856 13.32 13.32 0 0 0-18.856 0m17.527 8.099v2.658h-6.77v6.77h-2.658v-6.77h-6.77v-2.658h6.77v-6.77h2.658v6.77z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-previous:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M21.94 7.88 20.06 6l-10 10 10 10 1.88-1.88L13.833 16z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-right:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m16 5.333-1.88 1.88 7.44 7.453H5.333v2.667H21.56l-7.44 7.453 1.88 1.88 10.667-10.667L16 5.332z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-save:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M15.708 2.355 8 10.061.292 2.355 1.708.939 8 7.233 14.292.939z' style='fill-rule:nonzero' transform='translate(8 14)'/%3E%3Cpath d='M5 26h22v2H5zM15 4h2v18h-2z'/%3E%3C/svg%3E")}.ag-icon-small-down:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M7.334 10.667 16 21.334l8.667-10.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-small-left:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M21.333 7.334 10.666 16l10.667 8.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-small-right:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M10.667 24.666 21.334 16 10.667 7.333z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-small-up:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M7.334 21.333 16 10.666l8.667 10.667z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-tick:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M11.586 22.96 27.718 6.828 29.84 8.95 11.586 27.202 2.4 18.016l2.12-2.122z'/%3E%3C/svg%3E")}.ag-icon-tree-closed:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m11.94 6-1.88 1.88L18.167 16l-8.107 8.12L11.94 26l10-10z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-tree-indeterminate:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M6 13.5h20v3H6z'/%3E%3C/svg%3E")}.ag-icon-tree-open:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M24.12 9.06 16 17.167 7.88 9.06 6 10.94l10 10 10-10z' style='fill-rule:nonzero' transform='translate(0 1)'/%3E%3C/svg%3E")}.ag-icon-unlinked:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M22.667 9.333h-5.333v2.533h5.333a4.136 4.136 0 0 1 4.133 4.133c0 1.907-1.307 3.507-3.08 3.973l1.947 1.947c2.173-1.107 3.667-3.32 3.667-5.92a6.67 6.67 0 0 0-6.667-6.667zm-1.334 5.334h-2.92l2.667 2.667h.253zM2.667 5.693 6.814 9.84A6.65 6.65 0 0 0 2.667 16a6.67 6.67 0 0 0 6.667 6.667h5.333v-2.533H9.334a4.136 4.136 0 0 1-4.133-4.133c0-2.12 1.613-3.867 3.68-4.093l2.76 2.76h-.973v2.667h3.64l3.027 3.027v2.307h2.307l5.347 5.333 1.68-1.68L4.362 4.002 2.669 5.695z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-up:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='m5.333 16 1.88 1.88 7.453-7.44v16.227h2.667V10.44l7.44 7.453L26.666 16 15.999 5.333 5.332 16z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-grip:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' xml:space='preserve' style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2' viewBox='0 0 32 32'%3E%3Cpath d='M8 24H6v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zM8 18H6v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zm6 0h-2v-4h2zM8 12H6V8h2zm6 0h-2V8h2zm6 0h-2V8h2zm6 0h-2V8h2z' style='fill-rule:nonzero'/%3E%3C/svg%3E")}.ag-icon-settings:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='%23000' d='M30 8h-4.1c-.5-2.3-2.5-4-4.9-4s-4.4 1.7-4.9 4H2v2h14.1c.5 2.3 2.5 4 4.9 4s4.4-1.7 4.9-4H30zm-9 4c-1.7 0-3-1.3-3-3s1.3-3 3-3 3 1.3 3 3-1.3 3-3 3M2 24h4.1c.5 2.3 2.5 4 4.9 4s4.4-1.7 4.9-4H30v-2H15.9c-.5-2.3-2.5-4-4.9-4s-4.4 1.7-4.9 4H2zm9-4c1.7 0 3 1.3 3 3s-1.3 3-3 3-3-1.3-3-3 1.3-3 3-3'/%3E%3C/svg%3E")}.ag-icon-column-arrow:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M11 4a1 1 0 0 1 1 1v22a1 1 0 1 1-2 0V5a1 1 0 0 1 1-1' clip-rule='evenodd'/%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M2 13a1 1 0 0 1 1-1h23.5a1 1 0 1 1 0 2H3a1 1 0 0 1-1-1' clip-rule='evenodd'/%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='M2 4h18v24H2zm2 2v20h14V6zM26.793 13 23 9.207l1.414-1.414L29.621 13l-5.207 5.207L23 16.793z' clip-rule='evenodd'/%3E%3C/svg%3E")}.ag-icon-un-pin:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' fill-rule='evenodd' d='m6.112 15.111 3.272 3.271 1.436-1.402-2.476-2.479c.81-1.25 3.168-1.12 5.156-.614l4.986-4.988-.49-.722c-.392-.622.336-1.504 1.024-2.072l.008-.007.01-.006.032-.025 1.447 1.447 1.432-1.397-2.601-2.602s-4.052 2.704-3.352 5.046l-3.158 3.108c-2.004-.388-4.69-.288-6.056 1.572-.638.87-.67 1.87-.67 1.87m.581 11.582.014.014 5.502-5.501 4.783 4.783.746-.364c1.992-1.016 2.776-3.21 2.632-5.34-.055-.805-.068-.87-.088-.97-.008-.04-.017-.085-.03-.182l3.32-3.218c1.734.292 3.198-.912 4.272-2.338q.337-.447.67-.894l-.001-.001-.007-.007-.007-.007-.007-.007-3.87-3.87 1.585-1.584-1.414-1.414-14.381 14.38-1.237 1.209-5.69 5.687 1.417 1.416zM23.21 10.206l2.65 2.651c-1.465 1.714-2.935.776-2.935.776l-4.79 4.79q.041.291.087.583c.257 1.676.513 3.35-.585 4.317a4 4 0 0 1-.272.21l-3.739-3.744z' clip-rule='evenodd'/%3E%3C/svg%3E")}.ag-icon-pinned-top:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='m16.708 10.878 8.708 8.706L24 21l-6.292-6.294V27h-2V14.706L9.416 21 8 19.584q4.348-4.344 8.691-8.69zM25 6H8v2h17z'/%3E%3C/svg%3E")}.ag-icon-pinned-bottom:before{mask-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' fill='none' viewBox='0 0 32 32'%3E%3Cpath fill='currentColor' d='M16.708 22.122 8 13.416 9.416 12l6.292 6.294V6h2v12.294L24 12l1.416 1.416-8.691 8.69zM7.416 28h17v-2h-17z'/%3E%3C/svg%3E")}`,bz=Ot({feature:"iconSet",css:yz}),RS={aggregation:'<path d="M18 7V4H6l6 8-6 8h12v-3"/>',arrows:'<polyline points="5 9 2 12 5 15"/><polyline points="9 5 12 2 15 5"/><polyline points="15 19 12 22 9 19"/><polyline points="19 9 22 12 19 15"/><line x1="2" x2="22" y1="12" y2="12"/><line x1="12" x2="12" y1="2" y2="22"/>',asc:'<path d="m5 12 7-7 7 7"/><path d="M12 19V5"/>',cancel:'<path d="m18 6-12 12"/><path d="m6 6 12 12"/>',chart:'<line x1="18" x2="18" y1="20" y2="10"/><line x1="12" x2="12" y1="20" y2="4"/><line x1="6" x2="6" y1="20" y2="14"/>',"color-picker":'<path d="m19 11-8-8-8.6 8.6a2 2 0 0 0 0 2.8l5.2 5.2c.8.8 2 .8 2.8 0L19 11Z"/><path d="m5 2 5 5"/><path d="M2 13h15"/><path d="M22 20a2 2 0 1 1-4 0c0-1.6 1.7-2.4 2-4 .3 1.6 2 2.4 2 4Z"/>',columns:'<path d="M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18"/>',contracted:'<path d="m9 18 6-6-6-6"/>',copy:'<rect width="14" height="14" x="8" y="8" rx="2" ry="2"/><path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"/>',cross:'<path d="M18 6 6 18"/><path d="m6 6 12 12"/>',csv:'<path d="M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z"/><polyline points="14 2 14 8 20 8"/><path d="M8 13h2"/><path d="M8 17h2"/><path d="M14 13h2"/><path d="M14 17h2"/>',cut:'<circle cx="6" cy="6" r="3"/><path d="M8.12 8.12 12 12"/><path d="M20 4 8.12 15.88"/><circle cx="6" cy="18" r="3"/><path d="M14.8 14.8 20 20"/>',desc:'<path d="M12 5v14"/><path d="m19 12-7 7-7-7"/>',down:'<path d="M12 5v14"/><path d="m19 12-7 7-7-7"/>',excel:'<path d="M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z"/><polyline points="14 2 14 8 20 8"/><path d="M8 13h2"/><path d="M8 17h2"/><path d="M14 13h2"/><path d="M14 17h2"/>',expanded:'<path d="m15 18-6-6 6-6"/>',"eye-slash":'<path d="M9.88 9.88a3 3 0 1 0 4.24 4.24"/><path d="M10.73 5.08A10.43 10.43 0 0 1 12 5c7 0 10 7 10 7a13.16 13.16 0 0 1-1.67 2.68"/><path d="M6.61 6.61A13.526 13.526 0 0 0 2 12s3 7 10 7a9.74 9.74 0 0 0 5.39-1.61"/><line x1="2" x2="22" y1="2" y2="22"/>',eye:'<path d="M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z"/><circle cx="12" cy="12" r="3"/>',filter:'<path d="M3 6h18"/><path d="M7 12h10"/><path d="M10 18h4"/>',first:'<path d="m17 18-6-6 6-6"/><path d="M7 6v12"/>',group:'<path d="M16 12H3"/><path d="M16 18H3"/><path d="M10 6H3"/><path d="M21 18V8a2 2 0 0 0-2-2h-5"/><path d="m16 8-2-2 2-2"/>',last:'<path d="m7 18 6-6-6-6"/><path d="M17 6v12"/>',left:'<path d="m12 19-7-7 7-7"/><path d="M19 12H5"/>',linked:'<path d="M9 17H7A5 5 0 0 1 7 7h2"/><path d="M15 7h2a5 5 0 1 1 0 10h-2"/><line x1="8" x2="16" y1="12" y2="12"/>',loading:'<line x1="12" x2="12" y1="2" y2="6"/><line x1="12" x2="12" y1="18" y2="22"/><line x1="4.93" x2="7.76" y1="4.93" y2="7.76"/><line x1="16.24" x2="19.07" y1="16.24" y2="19.07"/><line x1="2" x2="6" y1="12" y2="12"/><line x1="18" x2="22" y1="12" y2="12"/><line x1="4.93" x2="7.76" y1="19.07" y2="16.24"/><line x1="16.24" x2="19.07" y1="7.76" y2="4.93"/>',maximize:'<polyline points="15 3 21 3 21 9"/><polyline points="9 21 3 21 3 15"/><line x1="21" x2="14" y1="3" y2="10"/><line x1="3" x2="10" y1="21" y2="14"/>',menu:'<line x1="4" x2="20" y1="12" y2="12"/><line x1="4" x2="20" y1="6" y2="6"/><line x1="4" x2="20" y1="18" y2="18"/>',"menu-alt":'<circle cx="12" cy="5" r="0.75" fill="#D9D9D9"/><circle cx="12" cy="12" r="0.75" fill="#D9D9D9"/><circle cx="12" cy="19" r="0.75" fill="#D9D9D9"/>',minimize:'<polyline points="4 14 10 14 10 20"/><polyline points="20 10 14 10 14 4"/><line x1="14" x2="21" y1="10" y2="3"/><line x1="3" x2="10" y1="21" y2="14"/>',minus:'<circle cx="12" cy="12" r="10"/><path d="M8 12h8"/>',next:'<path d="m9 18 6-6-6-6"/>',none:'<path d="m7 15 5 5 5-5"/><path d="m7 9 5-5 5 5"/>',"not-allowed":'<circle cx="12" cy="12" r="10"/><path d="m4.9 4.9 14.2 14.2"/>',paste:'<path d="M15 2H9a1 1 0 0 0-1 1v2c0 .6.4 1 1 1h6c.6 0 1-.4 1-1V3c0-.6-.4-1-1-1Z"/><path d="M8 4H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2M16 4h2a2 2 0 0 1 2 2v2M11 14h10"/><path d="m17 10 4 4-4 4"/>',pin:'<line x1="12" x2="12" y1="17" y2="22"/><path d="M5 17h14v-1.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V6h1a2 2 0 0 0 0-4H8a2 2 0 0 0 0 4h1v4.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24Z"/>',pivot:'<path d="M15 3v18"/><rect width="18" height="18" x="3" y="3" rx="2"/><path d="M21 9H3"/><path d="M21 15H3"/>',plus:'<circle cx="12" cy="12" r="10"/><path d="M8 12h8"/><path d="M12 8v8"/>',previous:'<path d="m15 18-6-6 6-6"/>',right:'<path d="M5 12h14"/><path d="m12 5 7 7-7 7"/>',save:'<path d="M12 17V3"/><path d="m6 11 6 6 6-6"/><path d="M19 21H5"/>',"small-left":'<path d="m15 18-6-6 6-6"/>',"small-right":'<path d="m9 18 6-6-6-6"/>',tick:'<path d="M20 6 9 17l-5-5"/>',"tree-closed":'<path d="m9 18 6-6-6-6"/>',"tree-indeterminate":'<path d="M5 12h14"/>',"tree-open":'<path d="m6 9 6 6 6-6"/>',unlinked:'<path d="M9 17H7A5 5 0 0 1 7 7"/><path d="M15 7h2a5 5 0 0 1 4 8"/><line x1="8" x2="12" y1="12" y2="12"/><line x1="2" x2="22" y1="2" y2="22"/>',up:'<path d="m5 12 7-7 7 7"/><path d="M12 19V5"/>',grip:'<circle cx="5" cy="8" r="0.5"/><circle cx="12" cy="8" r="0.5"/><circle cx="19" cy="8" r="0.5"/><circle cx="5" cy="16" r="0.5"/><circle cx="12" cy="16" r="0.5"/><circle cx="19" cy="16" r="0.5"/><g stroke="none" fill="currentColor"><circle cx="5" cy="8" r="1"/><circle cx="12" cy="8" r="1"/><circle cx="19" cy="8" r="1"/><circle cx="5" cy="16" r="1"/><circle cx="12" cy="16" r="1"/><circle cx="19" cy="16" r="1"/></g>',settings:'<path d="M20 7h-9"/><path d="M14 17H5"/><circle cx="17" cy="17" r="3"/><circle cx="7" cy="7" r="3"/>'},ES={"column-arrow":'<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="none" viewBox="0 0 32 32"><path fill-rule="evenodd" clip-rule="evenodd" d="M0 26C0 28.2092 1.79086 30 4 30H14C16.2091 30 18 28.2092 18 26V15H25.8786L24.4394 16.4393C23.8536 17.0251 23.8536 17.9749 24.4394 18.5607C25.0252 19.1464 25.9748 19.1464 26.5606 18.5607L30.5606 14.5607C31.1464 13.9749 31.1464 13.0251 30.5606 12.4393L26.5606 8.43934C25.9748 7.85356 25.0252 7.85356 24.4394 8.43934C23.8536 9.02512 23.8536 9.97488 24.4394 10.5607L25.8786 12H18V6C18 3.79086 16.2091 2 14 2H4C1.79086 2 0 3.79086 0 6V26ZM14 5H10.5V12H15V6C15 5.44772 14.5523 5 14 5ZM4 5H7.5V12H3V6C3 5.44772 3.44772 5 4 5ZM10.5 15H15V26C15 26.5522 14.5523 27 14 27H10.5V15ZM4 27H7.5V15H3V26C3 26.5522 3.44772 27 4 27Z" fill="currentColor"/></svg>',"small-down":'<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="black" stroke="none" viewBox="0 0 32 32"><path d="M7.334 10.667 16 21.334l8.667-10.667H7.334Z"/></svg>',"small-up":'<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="black" stroke="none" viewBox="0 0 32 32"><path d="M7.334 21.333 16 10.666l8.667 10.667H7.334Z"/></svg>',"pinned-top":'<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="none" viewBox="0 0 16 16"><path fill="currentColor" d="M12.53 3.72A.75.75 0 0 1 12 5H4a.75.75 0 0 1 0-1.5h8a.75.75 0 0 1 .53.22ZM3.269 10.744a.75.75 0 0 1 .2-.524l4-4a.75.75 0 0 1 1.06 0l4 4a.75.75 0 1 1-1.06 1.06L8.75 8.56V14a.75.75 0 0 1-1.5 0V8.56l-2.72 2.72a.75.75 0 0 1-1.26-.536Z"/></svg>',"pinned-bottom":'<svg xmlns="http://www.w3.org/2000/svg" fill="none" class="ag-icon" viewBox="0 0 16 16"><path fill="currentColor" d="M3.47 12.28A.75.75 0 0 1 4 11h8a.75.75 0 0 1 0 1.5H4a.75.75 0 0 1-.53-.22ZM12.731 5.256a.75.75 0 0 1-.2.524l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 1 1 1.06-1.06l2.72 2.72V2a.75.75 0 0 1 1.5 0v5.44l2.72-2.72a.75.75 0 0 1 1.26.536Z"/></svg>',"un-pin":'<svg xmlns="http://www.w3.org/2000/svg" fill="none" class="ag-icon" viewBox="0 0 16 16"><path fill="currentColor" d="M8 11a.75.75 0 0 0-.75.75v3.333a.75.75 0 1 0 1.5 0V11.75A.75.75 0 0 0 8 11Z"/><path fill="currentColor" d="M13.11 1.436a.75.75 0 0 0-1.22-.872l-10 14a.75.75 0 1 0 1.22.872L5.207 12.5h7.376a.75.75 0 0 0 .75-.75v-1.174a2.08 2.08 0 0 0-1.153-1.863l-1.185-.599-.005-.002a.58.58 0 0 1-.323-.522V5.165a2.083 2.083 0 0 0 1.854-2.904l.589-.825Zm-3.943 5.52v.634a2.08 2.08 0 0 0 1.153 1.863l1.185.6.005.002a.58.58 0 0 1 .323.522V11H6.28l2.887-4.044ZM9.277 1H5.25a2.084 2.084 0 0 0-.083 4.165v1.676l1.5-2.132v-.292a.75.75 0 0 0-.75-.75H5.25a.584.584 0 0 1 0-1.167h2.972L9.277 1Z"/></svg>'},Cz=(e={})=>{let t="";for(const r of[...Object.keys(RS),...Object.keys(ES)]){const n=wz(r,e.strokeWidth);t+=`.ag-icon-${r}::before { mask-image: url('data:image/svg+xml,${encodeURIComponent(n)}'); }
18
+ `}return t},wz=(e,t=1.5)=>{const r=ES[e];if(r)return r;const n=RS[e];if(!n)throw new Error(`Missing icon data for ${e}`);return`<svg xmlns="http://www.w3.org/2000/svg" class="ag-icon" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke="black" stroke-width="${t}" viewBox="0 0 24 24"><style>* { vector-effect: non-scaling-stroke; }</style>`+n+"</svg>"},Sz=(e={})=>Ot({feature:"iconSet",css:()=>Cz(e)}),xz=Sz(),Az=':where(.ag-input-field-input[type=number]:not(.ag-number-field-input-stepper)){-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield;&::-webkit-inner-spin-button,&::-webkit-outer-spin-button{-webkit-appearance:none;appearance:none;margin:0}}.ag-input-field-input:where(input:not([type]),input[type=text],input[type=number],input[type=tel],input[type=date],input[type=datetime-local],textarea){background-color:var(--ag-input-background-color);border:var(--ag-input-border);border-radius:var(--ag-input-border-radius);color:var(--ag-input-text-color);font-family:inherit;font-size:inherit;line-height:inherit;margin:0;min-height:var(--ag-input-height);padding:0;&:where(:disabled){background-color:var(--ag-input-disabled-background-color);border:var(--ag-input-disabled-border);color:var(--ag-input-disabled-text-color)}&:where(:focus){background-color:var(--ag-input-focus-background-color);border:var(--ag-input-focus-border);box-shadow:var(--ag-input-focus-shadow);color:var(--ag-input-focus-text-color);outline:none}&:where(:invalid){background-color:var(--ag-input-invalid-background-color);border:var(--ag-input-invalid-border);color:var(--ag-input-invalid-text-color)}&:where(.invalid){background-color:var(--ag-input-invalid-background-color);border:var(--ag-input-invalid-border);color:var(--ag-input-invalid-text-color)}&::-moz-placeholder{color:var(--ag-input-placeholder-text-color)}&::placeholder{color:var(--ag-input-placeholder-text-color)}}:where(.ag-ltr) .ag-input-field-input:where(input:not([type]),input[type=text],input[type=number],input[type=tel],input[type=date],input[type=datetime-local],textarea){padding-left:var(--ag-input-padding-start)}:where(.ag-rtl) .ag-input-field-input:where(input:not([type]),input[type=text],input[type=number],input[type=tel],input[type=date],input[type=datetime-local],textarea){padding-right:var(--ag-input-padding-start)}:where(.ag-column-select-header-filter-wrapper,.ag-filter-toolpanel-search,.ag-mini-filter,.ag-filter-filter){.ag-input-wrapper:before{background-color:currentcolor;color:var(--ag-input-icon-color);content:"";display:block;height:12px;-webkit-mask-image:url("data:image/svg+xml;charset=utf-8;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMiIgaGVpZ2h0PSIxMiIgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIHN0cm9rZS13aWR0aD0iMS41Ij48cGF0aCBkPSJNNS4zIDlhMy43IDMuNyAwIDEgMCAwLTcuNSAzLjcgMy43IDAgMCAwIDAgNy41Wk0xMC41IDEwLjUgOC4zIDguMiIvPjwvc3ZnPg==");mask-image:url("data:image/svg+xml;charset=utf-8;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMiIgaGVpZ2h0PSIxMiIgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIHN0cm9rZS13aWR0aD0iMS41Ij48cGF0aCBkPSJNNS4zIDlhMy43IDMuNyAwIDEgMCAwLTcuNSAzLjcgMy43IDAgMCAwIDAgNy41Wk0xMC41IDEwLjUgOC4zIDguMiIvPjwvc3ZnPg==");-webkit-mask-position:center;mask-position:center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;opacity:.5;position:absolute;width:12px}}:where(.ag-ltr) :where(.ag-column-select-header-filter-wrapper,.ag-filter-toolpanel-search,.ag-mini-filter,.ag-filter-filter){.ag-input-wrapper:before{margin-left:var(--ag-spacing)}.ag-number-field-input,.ag-text-field-input{padding-left:calc(var(--ag-spacing)*1.5 + 12px)}}:where(.ag-rtl) :where(.ag-column-select-header-filter-wrapper,.ag-filter-toolpanel-search,.ag-mini-filter,.ag-filter-filter){.ag-input-wrapper:before{margin-right:var(--ag-spacing)}.ag-number-field-input,.ag-text-field-input{padding-right:calc(var(--ag-spacing)*1.5 + 12px)}}',Pz=".ag-input-field-input:where(input:not([type]),input[type=text],input[type=number],input[type=tel],input[type=date],input[type=datetime-local],textarea){&:focus{box-shadow:var(--ag-focus-shadow)}}",Rz={inputBackgroundColor:"transparent",inputBorder:!1,inputBorderRadius:0,inputTextColor:{ref:"textColor"},inputPlaceholderTextColor:{ref:"inputTextColor",mix:.5},inputPaddingStart:0,inputHeight:{calc:"max(iconSize, fontSize) + spacing * 2"},inputFocusBackgroundColor:{ref:"inputBackgroundColor"},inputFocusBorder:{ref:"inputBorder"},inputFocusShadow:"none",inputFocusTextColor:{ref:"inputTextColor"},inputDisabledBackgroundColor:{ref:"inputBackgroundColor"},inputDisabledBorder:{ref:"inputBorder"},inputDisabledTextColor:{ref:"inputTextColor"},inputInvalidBackgroundColor:{ref:"inputBackgroundColor"},inputInvalidBorder:{ref:"inputBorder"},inputInvalidTextColor:{ref:"inputTextColor"},inputIconColor:{ref:"inputTextColor"},pickerButtonBorder:!1,pickerButtonFocusBorder:{ref:"inputFocusBorder"},pickerButtonBackgroundColor:{ref:"backgroundColor"},pickerButtonFocusBackgroundColor:{ref:"backgroundColor"},pickerListBorder:!1,pickerListBackgroundColor:{ref:"backgroundColor"}},Ez=()=>Ot({feature:"inputStyle",params:{...Rz,inputBackgroundColor:bt,inputBorder:!0,inputBorderRadius:{ref:"borderRadius"},inputPaddingStart:{ref:"spacing"},inputFocusBorder:{color:it},inputFocusShadow:{ref:"focusShadow"},inputDisabledBackgroundColor:Ct(.06),inputDisabledTextColor:{ref:"textColor",mix:.5},inputInvalidBorder:{color:{ref:"invalidColor"}},pickerButtonBorder:!0,pickerListBorder:!0},css:()=>Az+Pz}),TS=Ez(),FS='.ag-tabs-header{background-color:var(--ag-tab-bar-background-color);border-bottom:var(--ag-tab-bar-border);display:flex;flex:1;gap:var(--ag-tab-spacing);padding:var(--ag-tab-bar-top-padding) var(--ag-tab-bar-horizontal-padding) 0}.ag-tabs-header-wrapper{display:flex}.ag-tabs-close-button-wrapper{align-items:center;border:0;display:flex;padding:var(--ag-spacing)}:where(.ag-ltr) .ag-tabs-close-button-wrapper{border-right:1px solid var(--ag-border-color)}:where(.ag-rtl) .ag-tabs-close-button-wrapper{border-left:1px solid var(--ag-border-color)}.ag-tabs-close-button{background-color:unset;border:0;cursor:pointer;padding:0}.ag-tab{align-items:center;background-color:var(--ag-tab-background-color);border-left:var(--ag-tab-selected-border-width) solid transparent;border-right:var(--ag-tab-selected-border-width) solid transparent;color:var(--ag-tab-text-color);cursor:pointer;display:flex;flex:1;justify-content:center;padding:var(--ag-tab-top-padding) var(--ag-tab-horizontal-padding) var(--ag-tab-bottom-padding);position:relative;&:hover{background-color:var(--ag-tab-hover-background-color);color:var(--ag-tab-hover-text-color)}&.ag-tab-selected{background-color:var(--ag-tab-selected-background-color);color:var(--ag-tab-selected-text-color)}&:after{background-color:var(--ag-tab-selected-underline-color);bottom:0;content:"";display:block;height:var(--ag-tab-selected-underline-width);left:0;opacity:0;position:absolute;right:0;transition:opacity var(--ag-tab-selected-underline-transition-duration)}&.ag-tab-selected:after{opacity:1}}:where(.ag-ltr) .ag-tab{&.ag-tab-selected{&:where(:not(:first-of-type)){border-left-color:var(--ag-tab-selected-border-color)}&:where(:not(:last-of-type)){border-right-color:var(--ag-tab-selected-border-color)}}}:where(.ag-rtl) .ag-tab{&.ag-tab-selected{&:where(:not(:first-of-type)){border-right-color:var(--ag-tab-selected-border-color)}&:where(:not(:last-of-type)){border-left-color:var(--ag-tab-selected-border-color)}}}',OS={tabBarBackgroundColor:"transparent",tabBarHorizontalPadding:0,tabBarTopPadding:0,tabBackgroundColor:"transparent",tabTextColor:{ref:"textColor"},tabHorizontalPadding:{ref:"spacing"},tabTopPadding:{ref:"spacing"},tabBottomPadding:{ref:"spacing"},tabSpacing:"0",tabHoverBackgroundColor:{ref:"tabBackgroundColor"},tabHoverTextColor:{ref:"tabTextColor"},tabSelectedBackgroundColor:{ref:"tabBackgroundColor"},tabSelectedTextColor:{ref:"tabTextColor"},tabSelectedBorderWidth:1,tabSelectedBorderColor:"transparent",tabSelectedUnderlineColor:"transparent",tabSelectedUnderlineWidth:0,tabSelectedUnderlineTransitionDuration:0,tabBarBorder:!1},Tz=()=>Ot({feature:"tabStyle",params:{...OS,tabBarBorder:!0,tabBarBackgroundColor:jt(.05),tabTextColor:{ref:"textColor",mix:.7},tabSelectedTextColor:{ref:"textColor"},tabHoverTextColor:{ref:"textColor"},tabSelectedBorderColor:{ref:"borderColor"},tabSelectedBackgroundColor:bt},css:FS}),Fz=Tz(),Oz=()=>Ot({feature:"tabStyle",params:{...OS,tabBarBorder:!0,tabBarBackgroundColor:{ref:"chromeBackgroundColor"},tabHoverTextColor:it,tabSelectedTextColor:it,tabSelectedUnderlineColor:it,tabSelectedUnderlineWidth:2,tabSelectedUnderlineTransitionDuration:"0.3s"},css:FS}),Mz=Oz(),Dz=()=>wS().withPart(AS).withPart(PS).withPart(xz).withPart(Fz).withPart(TS).withPart(Sp).withParams({fontFamily:[{googleFont:"IBM Plex Sans"},"-apple-system","BlinkMacSystemFont","Segoe UI","Roboto","Oxygen-Sans","Ubuntu"]}),kz=Dz(),Iz=()=>wS().withPart(U8).withPart(AS).withPart(PS).withPart(bz).withPart(Mz).withPart(TS).withPart(Sp).withParams({accentColor:"#2196f3",selectedRowBackgroundColor:_t(.3),inputFocusBorder:{color:_t(.4)},focusShadow:{radius:2,spread:1.6,color:_t(.4)},iconButtonHoverBackgroundColor:"transparent",iconButtonActiveBackgroundColor:"transparent",checkboxUncheckedBorderColor:Ct(.45),checkboxIndeterminateBackgroundColor:Ct(.45),checkboxIndeterminateBorderColor:Ct(.45),checkboxBorderWidth:2,checkboxBorderRadius:2,fontSize:13,dataFontSize:14,headerFontWeight:700,borderRadius:3,wrapperBorderRadius:3,tabSelectedUnderlineColor:it,tabSelectedBorderWidth:0,tabSelectedUnderlineTransitionDuration:.3,sideButtonSelectedUnderlineColor:it,sideButtonSelectedUnderlineWidth:2,sideButtonSelectedUnderlineTransitionDuration:.3,sideButtonBorder:!1,sideButtonSelectedBorder:!1,sideButtonBarTopPadding:{calc:"spacing * 3"},sideButtonSelectedBackgroundColor:"transparent",sideButtonHoverTextColor:it,iconButtonHoverColor:it,toggleButtonWidth:28,toggleButtonHeight:18,toggleButtonSwitchInset:1,toggleButtonOffBackgroundColor:Ct(.45)}),MS=Iz(),_z={cssName:"--ag-cell-horizontal-padding",changeKey:"cellHorizontalPaddingChanged",defaultValue:16},Lz={cssName:"--ag-indentation-level",changeKey:"indentationLevelChanged",defaultValue:0,noWarn:!0,cacheDefault:!0},Bz={cssName:"--ag-row-group-indent-size",changeKey:"rowGroupIndentSizeChanged",defaultValue:0},ay={cssName:"--ag-row-height",changeKey:"rowHeightChanged",defaultValue:42},ly={cssName:"--ag-header-height",changeKey:"headerHeightChanged",defaultValue:48},cy={cssName:"--ag-list-item-height",changeKey:"listItemHeightChanged",defaultValue:24},Ed={cssName:"--ag-row-border",changeKey:"rowBorderWidthChanged",defaultValue:1,border:!0},uy={cssName:"--ag-pinned-row-border",changeKey:"pinnedRowBorderWidthChanged",defaultValue:1,border:!0},zz=0,Nz=class extends q{constructor(){super(...arguments),this.beanName="environment",this.sizeEls=new Map,this.lastKnownValues=new Map,this.sizesMeasured=!1,this.paramsClass=`ag-theme-params-${++zz}`,this.globalCSS=[]}wireBeans(e){const{eGridDiv:t,gridOptions:r}=e;this.eGridDiv=t,this.eStyleContainer=r.themeStyleContainer??(t.getRootNode()===document?document.head:t),this.cssLayer=r.themeCssLayer,this.styleNonce=r.styleNonce}postConstruct(){this.addManagedPropertyListener("theme",()=>this.handleThemeGridOptionChange()),this.handleThemeGridOptionChange(),this.addManagedPropertyListener("rowHeight",()=>this.refreshRowHeightVariable()),this.getSizeEl(ay),this.getSizeEl(ly),this.getSizeEl(cy),this.getSizeEl(Ed),this.getSizeEl(uy),this.refreshRowBorderWidthVariable(),this.addDestroyFunc(()=>L8(this)),this.mutationObserver=new MutationObserver(()=>{this.fireGridStylesChangedEvent("themeChanged")}),this.addDestroyFunc(()=>this.mutationObserver.disconnect())}getPinnedRowBorderWidth(){return this.getCSSVariablePixelValue(uy)}getRowBorderWidth(){return this.getCSSVariablePixelValue(Ed)}getDefaultRowHeight(){return this.getCSSVariablePixelValue(ay)}getDefaultHeaderHeight(){return this.getCSSVariablePixelValue(ly)}getDefaultCellHorizontalPadding(){return this.getCSSVariablePixelValue(_z)}getCellPaddingLeft(){const e=this.getDefaultCellHorizontalPadding(),t=this.getCSSVariablePixelValue(Lz),r=this.getCSSVariablePixelValue(Bz);return e-1+r*t}getCellPadding(){const e=this.getDefaultCellHorizontalPadding()-1;return this.getCellPaddingLeft()+e}getDefaultColumnMinWidth(){return Math.min(36,this.getDefaultRowHeight())}getDefaultListItemHeight(){return this.getCSSVariablePixelValue(cy)}applyThemeClasses(e){const{gridTheme:t}=this;let r="";if(t)r=`${this.paramsClass} ${t._getCssClass()}`;else{this.mutationObserver.disconnect();let n=this.eGridDiv;for(;n;){let i=!1;for(const o of Array.from(n.classList))o.startsWith("ag-theme-")&&(i=!0,r=r?`${r} ${o}`:o);i&&this.mutationObserver.observe(n,{attributes:!0,attributeFilter:["class"]}),n=n.parentElement}}for(const n of Array.from(e.classList))n.startsWith("ag-theme-")&&e.classList.remove(n);if(r){const n=e.className;e.className=n+(n?" ":"")+r}}refreshRowHeightVariable(){const{eGridDiv:e}=this,t=e.style.getPropertyValue("--ag-line-height").trim(),r=this.gos.get("rowHeight");if(r==null||isNaN(r)||!isFinite(r))return t!==null&&e.style.setProperty("--ag-line-height",null),-1;const n=`${r}px`;return t!=n?(e.style.setProperty("--ag-line-height",n),r):t!=""?parseFloat(t):-1}addGlobalCSS(e,t){this.gridTheme?zi(e,this.eStyleContainer,t,this.cssLayer,0,this.styleNonce):this.globalCSS.push([e,t])}getCSSVariablePixelValue(e){const t=this.lastKnownValues.get(e);if(t!=null)return t;const r=this.measureSizeEl(e);return r==="detached"||r==="no-styles"?(e.cacheDefault&&this.lastKnownValues.set(e,e.defaultValue),e.defaultValue):(this.lastKnownValues.set(e,r),r)}measureSizeEl(e){const t=this.getSizeEl(e);if(t.offsetParent==null)return"detached";const r=t.offsetWidth;return r===Td?"no-styles":(this.sizesMeasured=!0,r)}getMeasurementContainer(){let e=this.eMeasurementContainer;return e||(e=this.eMeasurementContainer=lt({tag:"div",cls:"ag-measurement-container"}),this.eGridDiv.appendChild(e)),e}getSizeEl(e){let t=this.sizeEls.get(e);if(t)return t;const r=this.getMeasurementContainer();t=lt({tag:"div"});const{border:n,noWarn:i}=e;n?(t.className="ag-measurement-element-border",t.style.setProperty("--ag-internal-measurement-border",`var(${e.cssName}, solid ${Td}px)`)):t.style.width=`var(${e.cssName}, ${Td}px)`,r.appendChild(t),this.sizeEls.set(e,t);let o=this.measureSizeEl(e);o==="no-styles"&&!i&&Q(9,{variable:e});const s=fn(this.beans,t,()=>{const a=this.measureSizeEl(e);a==="detached"||a==="no-styles"||(this.lastKnownValues.set(e,a),a!==o&&(o=a,this.fireGridStylesChangedEvent(e.changeKey)))});return this.addDestroyFunc(()=>s()),t}fireGridStylesChangedEvent(e){e==="rowBorderWidthChanged"&&this.refreshRowBorderWidthVariable(),this.eventSvc.dispatchEvent({type:"gridStylesChanged",[e]:!0})}refreshRowBorderWidthVariable(){const e=this.getCSSVariablePixelValue(Ed);this.eGridDiv.style.setProperty("--ag-internal-row-border-width",`${e}px`)}handleThemeGridOptionChange(){const{gos:e,eGridDiv:t,globalCSS:r,gridTheme:n}=this,i=e.get("theme");let o;if(i==="legacy")o=void 0;else{const s=i??kz;s instanceof SS?o=s:_e(240,{theme:s})}if(o!==n){if(o){_8(this),fS(this.eStyleContainer,this.cssLayer,this.styleNonce);for(const[a,l]of r)zi(a,this.eStyleContainer,l,this.cssLayer,0,this.styleNonce);r.length=0}this.gridTheme=o,o==null||o._startUse({loadThemeGoogleFonts:e.get("loadThemeGoogleFonts"),styleContainer:this.eStyleContainer,cssLayer:this.cssLayer,nonce:this.styleNonce});let s=this.eParamsStyle;if(!s){s=this.eParamsStyle=lt({tag:"style"});const a=this.gos.get("styleNonce");a&&s.setAttribute("nonce",a),t.appendChild(s)}wp||(s.textContent=(o==null?void 0:o._getPerGridCss(this.paramsClass))||""),this.applyThemeClasses(t),this.fireGridStylesChangedEvent("themeChanged")}o&&getComputedStyle(this.getMeasurementContainer()).getPropertyValue("--ag-legacy-styles-loaded")&&_e(i?106:239)}},Td=15538,$z=class extends q{constructor(){super(...arguments),this.beanName="eventSvc",this.globalSvc=new Wn}postConstruct(){const{globalListener:e,globalSyncListener:t}=this.beans;e&&this.addGlobalListener(e,!0),t&&this.addGlobalListener(t,!1)}addEventListener(e,t,r){this.globalSvc.addEventListener(e,t,r)}removeEventListener(e,t,r){this.globalSvc.removeEventListener(e,t,r)}addGlobalListener(e,t=!1){this.globalSvc.addGlobalListener(e,t)}removeGlobalListener(e,t=!1){this.globalSvc.removeGlobalListener(e,t)}dispatchLocalEvent(){}dispatchEvent(e){this.globalSvc.dispatchEvent(pe(this.gos,e))}dispatchEventOnce(e){this.globalSvc.dispatchEventOnce(pe(this.gos,e))}};function DS(e){return e?e.getLeafColumns().some(t=>t.isSpanHeaderHeight()):!1}function jh(e,t){let r;if(je(e)&&DS(e)&&e.isPadding()){const n=e;r=n.getLeafColumns()[0];let i=r;for(;i!==n;)t++,i=i.getParent()}return{column:r||e,headerRowIndex:t}}var Hz=class extends q{constructor(){super(...arguments),this.beanName="headerNavigation",this.currentHeaderRowWithoutSpan=-1}postConstruct(){const e=this.beans;e.ctrlsSvc.whenReady(this,r=>{this.gridBodyCon=r.gridBodyCtrl});const t=gt(e);this.addManagedElementListeners(t,{mousedown:()=>{this.currentHeaderRowWithoutSpan=-1}})}getHeaderPositionForColumn(e,t){let r;const{colModel:n,colGroupSvc:i,ctrlsSvc:o}=this.beans;if(typeof e=="string"?(r=n.getCol(e),r||(r=(i==null?void 0:i.getColumnGroup(e))??null)):r=e,!r)return null;const s=o.getHeaderRowContainerCtrl(),a=s==null?void 0:s.getAllCtrls(),l=Ee(a||[]).type==="filter",c=pr(this.beans)-1;let u=-1,d=r;for(;d;)u++,d=d.getParent();let h=u;return t&&l&&h===c-1&&h++,h===-1?null:{headerRowIndex:h,column:r}}navigateVertically(e,t,r){const n=this.beans.focusSvc;if(t||(t=n.focusedHeader),!t)return!1;const{headerRowIndex:i}=t,o=t.column,s=pr(this.beans),a=e==="UP",l=this.getHeaderRowType(i);let{headerRowIndex:c,column:u,headerRowIndexWithoutSpan:d}=a?Gz(l,o,i):Wz(l,o,i),h=!1;return c<0&&(c=0,u=o,h=!0),c>=s?(c=-1,this.currentHeaderRowWithoutSpan=-1):d!==void 0&&(this.currentHeaderRowWithoutSpan=d),!h&&!u?!1:n.focusHeaderPosition({headerPosition:{headerRowIndex:c,column:u},allowUserOverride:!0,event:r})}navigateHorizontally(e,t=!1,r){const{focusSvc:n,gos:i}=this.beans,o=n.focusedHeader;let s,a;this.currentHeaderRowWithoutSpan!==-1?o.headerRowIndex=this.currentHeaderRowWithoutSpan:this.currentHeaderRowWithoutSpan=o.headerRowIndex,e==="LEFT"!==i.get("enableRtl")?(a="Before",s=this.findHeader(o,a)):(a="After",s=this.findHeader(o,a));const l=i.getCallback("tabToNextHeader");if(t&&l){const c=n.focusHeaderPositionFromUserFunc({userFunc:l,headerPosition:s,direction:a});if(c){const{headerRowIndex:u}=n.focusedHeader||{};u!=null&&u!=o.headerRowIndex&&(this.currentHeaderRowWithoutSpan=u)}return c}return s||!t?n.focusHeaderPosition({headerPosition:s,direction:a,fromTab:t,allowUserOverride:!0,event:r}):this.focusNextHeaderRow(o,a,r)}focusNextHeaderRow(e,t,r){const n=e.headerRowIndex;let i=null,o;const s=this.beans;if(t==="Before"?n>0&&(o=n-1,this.currentHeaderRowWithoutSpan-=1,i=this.findColAtEdgeForHeaderRow(o,"end")):(o=n+1,this.currentHeaderRowWithoutSpan<pr(s)?this.currentHeaderRowWithoutSpan+=1:this.currentHeaderRowWithoutSpan=-1,i=this.findColAtEdgeForHeaderRow(o,"start")),!i)return!1;const{column:a,headerRowIndex:l}=jh(i.column,i==null?void 0:i.headerRowIndex);return s.focusSvc.focusHeaderPosition({headerPosition:{column:a,headerRowIndex:l},direction:t,fromTab:!0,allowUserOverride:!0,event:r})}scrollToColumn(e,t="After"){if(e.getPinned())return;let r;if(je(e)){const n=e.getDisplayedLeafColumns();r=t==="Before"?Ee(n):n[0]}else r=e;this.gridBodyCon.scrollFeature.ensureColumnVisible(r)}findHeader(e,t){let r,n;const{colGroupSvc:i,visibleCols:o}=this.beans;if(je(e.column)?r=(i==null?void 0:i.getGroupAtDirection(e.column,t))??void 0:(n=`getCol${t}`,r=o[n](e.column)),!r)return;const{headerRowIndex:s}=e;if(this.getHeaderRowType(s)!=="filter"){const c=[r];for(;r.getParent();)r=r.getParent(),c.push(r);r=c[Math.max(0,c.length-1-s)]}const{column:a,headerRowIndex:l}=jh(r,s);return{column:a,headerRowIndex:l}}getHeaderRowType(e){const t=this.beans.ctrlsSvc.getHeaderRowContainerCtrl();if(t)return t.getRowType(e)}findColAtEdgeForHeaderRow(e,t){const{visibleCols:r,ctrlsSvc:n,colGroupSvc:i}=this.beans,o=r.allCols,s=o[t==="start"?0:o.length-1];if(!s)return;const a=n.getHeaderRowContainerCtrl(s.getPinned()),l=a==null?void 0:a.getRowType(e);if(l=="group"){const c=i==null?void 0:i.getColGroupAtLevel(s,e);return{headerRowIndex:e,column:c}}return{headerRowIndex:l==null?-1:e,column:s}}};function Gz(e,t,r){const n=e==="filter",i=e==="column";let o=n?t:t.getParent(),s=r-1,a=s;if(i&&DS(t.getParent())){for(;o&&o.isPadding();)o=o.getParent(),s--;a=s,s<0&&(o=t,s=r,a=void 0)}return{column:o,headerRowIndex:s,headerRowIndexWithoutSpan:a}}function Wz(e,t,r,n="After"){let i=t,o=r+1;const s=o;if(e==="group"){const a=t.getDisplayedLeafColumns(),l=n==="After"?a[0]:Ee(a),c=[];let u=l;for(;u.getParent()!==t;)u=u.getParent(),c.push(u);if(i=l,l.isSpanHeaderHeight())for(let d=c.length-1;d>=0;d--){const h=c[d];if(!h.isPadding()){i=h;break}o++}else i=Ee(c),i||(i=l)}return{column:i,headerRowIndex:o,headerRowIndexWithoutSpan:s}}var jz=class extends q{constructor(){super(...arguments),this.beanName="focusSvc",this.focusFallbackTimeout=null,this.needsFocusRestored=!1}wireBeans(e){this.colModel=e.colModel,this.visibleCols=e.visibleCols,this.rowRenderer=e.rowRenderer,this.navigation=e.navigation,this.filterManager=e.filterManager,this.overlays=e.overlays}postConstruct(){const e=this.clearFocusedCell.bind(this);this.addManagedEventListeners({columnPivotModeChanged:e,newColumnsLoaded:this.onColumnEverythingChanged.bind(this),columnGroupOpened:e,columnRowGroupChanged:e}),this.addDestroyFunc(eL(this.beans))}attemptToRecoverFocus(){this.needsFocusRestored=!0,this.focusFallbackTimeout!=null&&clearTimeout(this.focusFallbackTimeout),this.focusFallbackTimeout=window.setTimeout(this.setFocusRecovered.bind(this),100)}setFocusRecovered(){this.needsFocusRestored=!1,this.focusFallbackTimeout!=null&&(clearTimeout(this.focusFallbackTimeout),this.focusFallbackTimeout=null)}shouldTakeFocus(){return this.gos.get("suppressFocusAfterRefresh")?(this.setFocusRecovered(),!1):this.needsFocusRestored?(this.setFocusRecovered(),!0):this.doesRowOrCellHaveBrowserFocus()}onColumnEverythingChanged(){if(!this.focusedCell)return;const e=this.focusedCell.column,t=this.colModel.getCol(e.getId());e!==t&&this.clearFocusedCell()}getFocusCellToUseAfterRefresh(){const{gos:e,focusedCell:t}=this;return e.get("suppressFocusAfterRefresh")||e.get("suppressCellFocus")||!t||!this.doesRowOrCellHaveBrowserFocus()?null:t}getFocusHeaderToUseAfterRefresh(){return this.gos.get("suppressFocusAfterRefresh")||!this.focusedHeader||!this.isDomDataPresentInHierarchy(Ke(this.beans),eS)?null:this.focusedHeader}doesRowOrCellHaveBrowserFocus(){const e=Ke(this.beans);return this.isDomDataPresentInHierarchy(e,Hl)?!0:this.isDomDataPresentInHierarchy(e,Vl)}isDomDataPresentInHierarchy(e,t){let r=e;for(;r;){if(n1(this.gos,r,t))return!0;r=r.parentNode}return!1}getFocusedCell(){return this.focusedCell}getFocusEventParams(e){const{rowIndex:t,rowPinned:r,column:n}=e,i={rowIndex:t,rowPinned:r,column:n,isFullWidthCell:!1},o=this.rowRenderer.getRowByPosition({rowIndex:t,rowPinned:r});return o&&(i.isFullWidthCell=o.isFullWidth()),i}clearFocusedCell(){if(this.focusedCell==null)return;const e=this.getFocusEventParams(this.focusedCell);this.focusedCell=null,this.eventSvc.dispatchEvent({type:"cellFocusCleared",...e})}setFocusedCell(e){this.setFocusRecovered();const{column:t,rowIndex:r,rowPinned:n,forceBrowserFocus:i=!1,preventScrollOnBrowserFocus:o=!1}=e,s=this.colModel.getCol(t);if(!s){this.focusedCell=null;return}this.focusedCell={rowIndex:r,rowPinned:on(n),column:s},this.eventSvc.dispatchEvent({type:"cellFocused",...this.getFocusEventParams(this.focusedCell),forceBrowserFocus:i,preventScrollOnBrowserFocus:o})}isCellFocused(e){return this.focusedCell==null?!1:yL(e,this.focusedCell)}isHeaderWrapperFocused(e){if(this.focusedHeader==null)return!1;const{column:t,rowCtrl:{rowIndex:r,pinned:n}}=e,{column:i,headerRowIndex:o}=this.focusedHeader;return t===i&&r===o&&n==i.getPinned()}focusHeaderPosition(e){var l;if(this.setFocusRecovered(),Ln(this.beans))return!1;const{direction:t,fromTab:r,allowUserOverride:n,event:i,fromCell:o,rowWithoutSpanValue:s}=e;let{headerPosition:a}=e;if(o&&((l=this.filterManager)!=null&&l.isAdvFilterHeaderActive()))return this.focusAdvancedFilter(a);if(n){const c=this.focusedHeader,u=pr(this.beans);if(r){const d=this.gos.getCallback("tabToNextHeader");d&&(a=this.getHeaderPositionFromUserFunc({userFunc:d,direction:t,currentPosition:c,headerPosition:a,headerRowCount:u}))}else{const d=this.gos.getCallback("navigateToNextHeader");if(d&&i){const h={key:i.key,previousHeaderPosition:c,nextHeaderPosition:a,headerRowCount:u,event:i};a=d(h)}}}return a?this.focusProvidedHeaderPosition({headerPosition:a,direction:t,event:i,fromCell:o,rowWithoutSpanValue:s}):!1}focusHeaderPositionFromUserFunc(e){if(Ln(this.beans))return!1;const{userFunc:t,headerPosition:r,direction:n,event:i}=e,o=this.focusedHeader,s=pr(this.beans),a=this.getHeaderPositionFromUserFunc({userFunc:t,direction:n,currentPosition:o,headerPosition:r,headerRowCount:s});return!!a&&this.focusProvidedHeaderPosition({headerPosition:a,direction:n,event:i})}getHeaderPositionFromUserFunc(e){const{userFunc:t,direction:r,currentPosition:n,headerPosition:i,headerRowCount:o}=e,a=t({backwards:r==="Before",previousHeaderPosition:n,nextHeaderPosition:i,headerRowCount:o});return a===!0?n:a===!1?null:a}focusProvidedHeaderPosition(e){const{headerPosition:t,direction:r,fromCell:n,rowWithoutSpanValue:i,event:o}=e,{column:s,headerRowIndex:a}=t,{filterManager:l,ctrlsSvc:c,headerNavigation:u}=this.beans;if(a===-1)return l!=null&&l.isAdvFilterHeaderActive()?this.focusAdvancedFilter(t):this.focusGridView({column:s,event:o});u==null||u.scrollToColumn(s,r);const d=c.getHeaderRowContainerCtrl(s.getPinned()),h=(d==null?void 0:d.focusHeader(t.headerRowIndex,s,o))||!1;return u&&h&&(i!=null||n)&&(u.currentHeaderRowWithoutSpan=i??-1),h}focusFirstHeader(){var n;if((n=this.overlays)!=null&&n.isExclusive()&&this.focusOverlay())return!0;let e=this.visibleCols.allCols[0];if(!e)return!1;const{colGroupSvc:t}=this.beans;t&&e.getParent()&&(e=t.getColGroupAtLevel(e,0));const r=jh(e,0);return this.focusHeaderPosition({headerPosition:r,rowWithoutSpanValue:0})}focusLastHeader(e){var n;if((n=this.overlays)!=null&&n.isExclusive()&&this.focusOverlay(!0))return!0;const t=pr(this.beans)-1,r=Ee(this.visibleCols.allCols);return this.focusHeaderPosition({headerPosition:{headerRowIndex:t,column:r},rowWithoutSpanValue:-1,event:e})}focusPreviousFromFirstCell(e){var t;return(t=this.filterManager)!=null&&t.isAdvFilterHeaderActive()?this.focusAdvancedFilter(null):this.focusLastHeader(e)}isAnyCellFocused(){return!!this.focusedCell}isRowFocused(e,t){return this.focusedCell==null?!1:this.focusedCell.rowIndex===e&&this.focusedCell.rowPinned===on(t)}focusOverlay(e){var r,n;const t=((r=this.overlays)==null?void 0:r.isVisible())&&((n=this.overlays.eWrapper)==null?void 0:n.getGui());return!!t&&qn(t,e)}focusGridView(e){var o,s,a,l,c,u;const{backwards:t=!1,canFocusOverlay:r=!0,event:n}=e;if((o=this.overlays)!=null&&o.isExclusive())return r&&this.focusOverlay(t);if(dp(this.beans))return t&&!Ln(this.beans)?this.focusLastHeader():r&&this.focusOverlay(t)?!0:t?!1:Os(this.beans,t);const i=t?wL(this.beans):CL(this.beans);if(i){const d=e.column??((s=this.focusedHeader)==null?void 0:s.column),{rowIndex:h,rowPinned:f}=i,g=B1(this.beans,i);if(!d||!g||h==null)return!1;if(d.isSuppressNavigable(g)){const m=this.gos.get("enableRtl");let p;return!n||n.key===j.TAB?p=m?j.LEFT:j.RIGHT:p=n.key,(a=this.beans.navigation)==null||a.navigateToNextCell(null,p,{rowIndex:h,column:d,rowPinned:f||null},!0),!0}if((l=this.navigation)==null||l.ensureCellVisible({rowIndex:h,column:d,rowPinned:f}),t){const m=this.rowRenderer.getRowByPosition(i);if(m!=null&&m.isFullWidth()&&((c=this.navigation)!=null&&c.tryToFocusFullWidthRow(i,t)))return!0}return this.setFocusedCell({rowIndex:h,column:d,rowPinned:on(f),forceBrowserFocus:!0}),(u=this.beans.rangeSvc)==null||u.setRangeToCell({rowIndex:h,rowPinned:f,column:d}),!0}return!!(r&&this.focusOverlay(t)||t&&this.focusLastHeader())}focusAdvancedFilter(e){var t;return this.advFilterFocusColumn=e==null?void 0:e.column,((t=this.beans.advancedFilter)==null?void 0:t.getCtrl().focusHeaderComp())??!1}focusNextFromAdvancedFilter(e,t){var n;const r=(t?void 0:this.advFilterFocusColumn)??((n=this.visibleCols.allCols)==null?void 0:n[0]);return e?this.focusHeaderPosition({headerPosition:{column:r,headerRowIndex:pr(this.beans)-1}}):this.focusGridView({column:r})}clearAdvancedFilterColumn(){this.advFilterFocusColumn=void 0}},Vz=class extends q{constructor(){super(...arguments),this.beanName="scrollVisibleSvc"}wireBeans(e){this.ctrlsSvc=e.ctrlsSvc,this.colAnimation=e.colAnimation}postConstruct(){this.getScrollbarWidth(),this.addManagedEventListeners({displayedColumnsChanged:this.updateScrollVisible.bind(this),displayedColumnsWidthChanged:this.updateScrollVisible.bind(this)})}updateScrollVisible(){const{colAnimation:e}=this;e!=null&&e.isActive()?e.executeLaterVMTurn(()=>{e.executeLaterVMTurn(()=>this.updateScrollVisibleImpl())}):this.updateScrollVisibleImpl()}updateScrollVisibleImpl(){var r;const e=this.ctrlsSvc.get("center");if(!e||(r=this.colAnimation)!=null&&r.isActive())return;const t={horizontalScrollShowing:e.isHorizontalScrollShowing(),verticalScrollShowing:this.verticalScrollShowing};this.setScrollsVisible(t),this.updateScrollGap()}updateScrollGap(){const e=this.ctrlsSvc.get("center"),t=e.hasHorizontalScrollGap(),r=e.hasVerticalScrollGap();(this.horizontalScrollGap!==t||this.verticalScrollGap!==r)&&(this.horizontalScrollGap=t,this.verticalScrollGap=r,this.eventSvc.dispatchEvent({type:"scrollGapChanged"}))}setScrollsVisible(e){(this.horizontalScrollShowing!==e.horizontalScrollShowing||this.verticalScrollShowing!==e.verticalScrollShowing)&&(this.horizontalScrollShowing=e.horizontalScrollShowing,this.verticalScrollShowing=e.verticalScrollShowing,this.eventSvc.dispatchEvent({type:"scrollVisibilityChanged"}))}getScrollbarWidth(){if(this.scrollbarWidth==null){const e=this.gos.get("scrollbarWidth"),r=typeof e=="number"&&e>=0?e:Hk();r!=null&&(this.scrollbarWidth=r,this.eventSvc.dispatchEvent({type:"scrollbarWidthChanged"}))}return this.scrollbarWidth}},Uz=class extends q{constructor(){super(...arguments),this.beanName="gridDestroySvc",this.destroyCalled=!1}destroy(){var n;if(this.destroyCalled)return;const{stateSvc:e,ctrlsSvc:t,context:r}=this.beans;this.eventSvc.dispatchEvent({type:"gridPreDestroyed",state:(e==null?void 0:e.getState())??{}}),this.destroyCalled=!0,(n=t.get("gridCtrl"))==null||n.destroyGridUi(),r.destroy(),super.destroy()}},Kz=new Set(["gridPreDestroyed","fillStart","pasteStart"]),qz={suppressContextMenu:!1,preventDefaultOnContextMenu:!1,allowContextMenuWithControlKey:!1,suppressMenuHide:!0,enableBrowserTooltips:!1,tooltipTrigger:"hover",tooltipShowDelay:2e3,tooltipHideDelay:1e4,tooltipMouseTrack:!1,tooltipShowMode:"standard",tooltipInteraction:!1,copyHeadersToClipboard:!1,copyGroupHeadersToClipboard:!1,clipboardDelimiter:" ",suppressCopyRowsToClipboard:!1,suppressCopySingleCellRanges:!1,suppressLastEmptyLineOnPaste:!1,suppressClipboardPaste:!1,suppressClipboardApi:!1,suppressCutToClipboard:!1,maintainColumnOrder:!1,enableStrictPivotColumnOrder:!1,suppressFieldDotNotation:!1,allowDragFromColumnsToolPanel:!1,suppressMovableColumns:!1,suppressColumnMoveAnimation:!1,suppressMoveWhenColumnDragging:!1,suppressDragLeaveHidesColumns:!1,suppressRowGroupHidesColumns:!1,suppressAutoSize:!1,autoSizePadding:20,skipHeaderOnAutoSize:!1,singleClickEdit:!1,suppressClickEdit:!1,readOnlyEdit:!1,stopEditingWhenCellsLoseFocus:!1,enterNavigatesVertically:!1,enterNavigatesVerticallyAfterEdit:!1,enableCellEditingOnBackspace:!1,undoRedoCellEditing:!1,undoRedoCellEditingLimit:10,suppressCsvExport:!1,suppressExcelExport:!1,cacheQuickFilter:!1,includeHiddenColumnsInQuickFilter:!1,excludeChildrenWhenTreeDataFiltering:!1,enableAdvancedFilter:!1,includeHiddenColumnsInAdvancedFilter:!1,enableCharts:!1,masterDetail:!1,keepDetailRows:!1,keepDetailRowsCount:10,detailRowAutoHeight:!1,tabIndex:0,rowBuffer:10,valueCache:!1,valueCacheNeverExpires:!1,enableCellExpressions:!1,suppressTouch:!1,suppressFocusAfterRefresh:!1,suppressBrowserResizeObserver:!1,suppressPropertyNamesCheck:!1,suppressChangeDetection:!1,debug:!1,suppressLoadingOverlay:!1,suppressNoRowsOverlay:!1,pagination:!1,paginationPageSize:100,paginationPageSizeSelector:!0,paginationAutoPageSize:!1,paginateChildRows:!1,suppressPaginationPanel:!1,pivotMode:!1,pivotPanelShow:"never",pivotDefaultExpanded:0,pivotSuppressAutoColumn:!1,suppressExpandablePivotGroups:!1,functionsReadOnly:!1,suppressAggFuncInHeader:!1,alwaysAggregateAtRootLevel:!1,aggregateOnlyChangedColumns:!1,suppressAggFilteredOnly:!1,removePivotHeaderRowWhenSingleValueColumn:!1,animateRows:!0,cellFlashDuration:500,cellFadeDuration:1e3,allowShowChangeAfterFilter:!1,domLayout:"normal",ensureDomOrder:!1,enableRtl:!1,suppressColumnVirtualisation:!1,suppressMaxRenderedRowRestriction:!1,suppressRowVirtualisation:!1,rowDragManaged:!1,suppressRowDrag:!1,suppressMoveWhenRowDragging:!1,rowDragEntireRow:!1,rowDragMultiRow:!1,embedFullWidthRows:!1,groupDisplayType:"singleColumn",groupDefaultExpanded:0,groupMaintainOrder:!1,groupSelectsChildren:!1,groupSuppressBlankHeader:!1,groupSelectsFiltered:!1,showOpenedGroup:!1,groupRemoveSingleChildren:!1,groupRemoveLowestSingleChildren:!1,groupHideOpenParents:!1,groupAllowUnbalanced:!1,rowGroupPanelShow:"never",suppressMakeColumnVisibleAfterUnGroup:!1,treeData:!1,rowGroupPanelSuppressSort:!1,suppressGroupRowsSticky:!1,rowModelType:"clientSide",asyncTransactionWaitMillis:50,suppressModelUpdateAfterUpdateTransaction:!1,cacheOverflowSize:1,infiniteInitialRowCount:1,serverSideInitialRowCount:1,cacheBlockSize:100,maxBlocksInCache:-1,maxConcurrentDatasourceRequests:2,blockLoadDebounceMillis:0,purgeClosedRowNodes:!1,serverSideSortAllLevels:!1,serverSideOnlyRefreshFilteredGroups:!1,serverSidePivotResultFieldSeparator:"_",viewportRowModelPageSize:5,viewportRowModelBufferSize:5,alwaysShowHorizontalScroll:!1,alwaysShowVerticalScroll:!1,debounceVerticalScrollbar:!1,suppressHorizontalScroll:!1,suppressScrollOnNewData:!1,suppressScrollWhenPopupsAreOpen:!1,suppressAnimationFrame:!1,suppressMiddleClickScrolls:!1,suppressPreventDefaultOnMouseWheel:!1,rowMultiSelectWithClick:!1,suppressRowDeselection:!1,suppressRowClickSelection:!1,suppressCellFocus:!1,suppressHeaderFocus:!1,suppressMultiRangeSelection:!1,enableCellTextSelection:!1,enableRangeSelection:!1,enableRangeHandle:!1,enableFillHandle:!1,fillHandleDirection:"xy",suppressClearOnFillReduction:!1,accentedSort:!1,unSortIcon:!1,suppressMultiSort:!1,alwaysMultiSort:!1,suppressMaintainUnsortedOrder:!1,suppressRowHoverHighlight:!1,suppressRowTransform:!1,columnHoverHighlight:!1,deltaSort:!1,enableGroupEdit:!1,groupLockGroupColumns:0,serverSideEnableClientSideSort:!1,suppressServerSideFullWidthLoadingRow:!1,pivotMaxGeneratedColumns:-1,columnMenu:"new",reactiveCustomComponents:!0,suppressSetFilterByDefault:!1,rowNumbers:!1},Ho=(e,t)=>({tag:"span",ref:`eSort${e}`,cls:`ag-sort-indicator-icon ag-sort-${t} ag-hidden`,attrs:{"aria-hidden":"true"}}),Yz={tag:"span",cls:"ag-sort-indicator-container",children:[Ho("Order","order"),Ho("Asc","ascending-icon"),Ho("Desc","descending-icon"),Ho("Mixed","mixed-icon"),Ho("None","none-icon")]},Pp=class extends ct{constructor(e){super(),this.eSortOrder=fe,this.eSortAsc=fe,this.eSortDesc=fe,this.eSortMixed=fe,this.eSortNone=fe,e||this.setTemplate(Yz)}attachCustomElements(e,t,r,n,i){this.eSortOrder=e,this.eSortAsc=t,this.eSortDesc=r,this.eSortMixed=n,this.eSortNone=i}setupSort(e,t=!1){if(this.column=e,this.suppressOrder=t,this.setupMultiSortIndicator(),!e.isSortable()&&!e.getColDef().showRowGroup)return;this.addInIcon("sortAscending",this.eSortAsc,e),this.addInIcon("sortDescending",this.eSortDesc,e),this.addInIcon("sortUnSort",this.eSortNone,e);const r=this.updateIcons.bind(this),n=this.onSortChanged.bind(this);this.addManagedPropertyListener("unSortIcon",r),this.addManagedEventListeners({newColumnsLoaded:r,sortChanged:n,columnRowGroupChanged:n}),this.onSortChanged()}addInIcon(e,t,r){if(t==null)return;const n=Co(e,this.beans,r);n&&t.appendChild(n)}onSortChanged(){this.updateIcons(),this.suppressOrder||this.updateSortOrder()}updateIcons(){const{eSortAsc:e,eSortDesc:t,eSortNone:r,column:n,gos:i,beans:o}=this,s=o.sortSvc.getDisplaySortForColumn(n);if(e&&Je(e,s==="asc",{skipAriaHidden:!0}),t&&Je(t,s==="desc",{skipAriaHidden:!0}),r){const a=!n.getColDef().unSortIcon&&!i.get("unSortIcon"),l=s==null;Je(r,!a&&l,{skipAriaHidden:!0})}}setupMultiSortIndicator(){const{eSortMixed:e,column:t,gos:r}=this;this.addInIcon("sortUnSort",e,t);const n=t.getColDef().showRowGroup;gr(r)&&n&&(this.addManagedEventListeners({sortChanged:this.updateMultiSortIndicator.bind(this),columnRowGroupChanged:this.updateMultiSortIndicator.bind(this)}),this.updateMultiSortIndicator())}updateMultiSortIndicator(){const{eSortMixed:e,beans:t,column:r}=this;if(e){const n=t.sortSvc.getDisplaySortForColumn(r)==="mixed";Je(e,n,{skipAriaHidden:!0})}}updateSortOrder(){const{eSortOrder:e,column:t,beans:{sortSvc:r}}=this;if(!e)return;const n=r.getColumnsWithSortingOrdered(),i=r.getDisplaySortIndexForColumn(t)??-1,o=n.some(a=>r.getDisplaySortIndexForColumn(a)??!1),s=i>=0&&o;Je(e,s,{skipAriaHidden:!0}),i>=0?e.textContent=(i+1).toString():hn(e)}},Jz={selector:"AG-SORT-INDICATOR",component:Pp},Xz=["asc","desc",null],Zz=class extends q{constructor(){super(...arguments),this.beanName="sortSvc"}progressSort(e,t,r){const n=this.getNextSortDirection(e);this.setSortForColumn(e,n,t,r)}progressSortFromEvent(e,t){const n=this.gos.get("multiSortKey")==="ctrl"?t.ctrlKey||t.metaKey:t.shiftKey;this.progressSort(e,n,"uiColumnSorted")}setSortForColumn(e,t,r,n){var u;t!=="asc"&&t!=="desc"&&(t=null);const{gos:i,showRowGroupCols:o}=this.beans,s=gr(i);let a=[e];if(s&&e.getColDef().showRowGroup){const d=(u=o==null?void 0:o.getSourceColumnsForGroupColumn)==null?void 0:u.call(o,e),h=d==null?void 0:d.filter(f=>f.isSortable());h&&(a=[e,...h])}a.forEach(d=>this.setColSort(d,t,n));const l=(r||i.get("alwaysMultiSort"))&&!i.get("suppressMultiSort"),c=[];if(!l){const d=this.clearSortBarTheseColumns(a,n);c.push(...d)}this.updateSortIndex(e),c.push(...a),this.dispatchSortChangedEvents(n,c)}updateSortIndex(e){const{gos:t,colModel:r,showRowGroupCols:n}=this.beans,i=gr(t),o=n==null?void 0:n.getShowRowGroupCol(e.getId()),s=i&&o||e,a=this.getColumnsWithSortingOrdered();r.forAllCols(u=>this.setColSortIndex(u,null));const l=a.filter(u=>i&&u.getColDef().showRowGroup?!1:u!==s);(s.getSort()?[...l,s]:l).forEach((u,d)=>this.setColSortIndex(u,d))}onSortChanged(e,t){this.dispatchSortChangedEvents(e,t)}isSortActive(){let e=!1;return this.beans.colModel.forAllCols(t=>{t.getSort()&&(e=!0)}),e}dispatchSortChangedEvents(e,t){const r={type:"sortChanged",source:e};t&&(r.columns=t),this.eventSvc.dispatchEvent(r)}clearSortBarTheseColumns(e,t){const r=[];return this.beans.colModel.forAllCols(n=>{e.includes(n)||(n.getSort()&&r.push(n),this.setColSort(n,void 0,t))}),r}getNextSortDirection(e){const t=e.getColDef().sortingOrder??this.gos.get("sortingOrder")??Xz,r=t.indexOf(e.getSort()),n=r<0,i=r==t.length-1;return n||i?t[0]:t[r+1]}getIndexedSortMap(){const{gos:e,colModel:t,showRowGroupCols:r,rowGroupColsSvc:n}=this.beans;let i=[];if(t.forAllCols(c=>{c.getSort()&&i.push(c)}),t.isPivotMode()){const c=gr(e);i=i.filter(u=>{const d=!!u.getAggFunc(),h=!u.isPrimary(),f=c?r==null?void 0:r.getShowRowGroupCol(u.getId()):u.getColDef().showRowGroup;return d||h||f})}const o=(n==null?void 0:n.columns.filter(c=>!!c.getSort()))??[],s={};i.forEach((c,u)=>s[c.getId()]=u),i.sort((c,u)=>{const d=c.getSortIndex(),h=u.getSortIndex();if(d!=null&&h!=null)return d-h;if(d==null&&h==null){const f=s[c.getId()],g=s[u.getId()];return f>g?1:-1}else return h==null?-1:1});const a=gr(e)&&!!o.length;a&&(i=[...new Set(i.map(c=>(r==null?void 0:r.getShowRowGroupCol(c.getId()))??c))]);const l=new Map;return i.forEach((c,u)=>l.set(c,u)),a&&o.forEach(c=>{const u=r.getShowRowGroupCol(c.getId());l.set(c,l.get(u))}),l}getColumnsWithSortingOrdered(){return[...this.getIndexedSortMap().entries()].sort(([,e],[,t])=>e-t).map(([e])=>e)}getSortModel(){return this.getColumnsWithSortingOrdered().filter(e=>e.getSort()).map(e=>({sort:e.getSort(),colId:e.getId()}))}getSortOptions(){return this.getColumnsWithSortingOrdered().filter(e=>e.getSort()).map(e=>({sort:e.getSort(),column:e}))}canColumnDisplayMixedSort(e){const t=gr(this.gos),r=!!e.getColDef().showRowGroup;return t&&r}getDisplaySortForColumn(e){var s;const t=(s=this.beans.showRowGroupCols)==null?void 0:s.getSourceColumnsForGroupColumn(e);if(!this.canColumnDisplayMixedSort(e)||!(t!=null&&t.length))return e.getSort();const n=e.getColDef().field!=null||!!e.getColDef().valueGetter?[e,...t]:t,i=n[0].getSort();return n.every(a=>a.getSort()==i)?i:"mixed"}getDisplaySortIndexForColumn(e){return this.getIndexedSortMap().get(e)}setupHeader(e,t,r){let n=0;e.addManagedListeners(t,{movingChanged:()=>{n=Date.now()}}),r&&e.addManagedElementListeners(r,{click:o=>{const s=t.isMoving(),l=Date.now()-n<50;s||l||this.progressSortFromEvent(t,o)}});const i=()=>{var s;const o=t.getSort();if(e.toggleCss("ag-header-cell-sorted-asc",o==="asc"),e.toggleCss("ag-header-cell-sorted-desc",o==="desc"),e.toggleCss("ag-header-cell-sorted-none",!o),t.getColDef().showRowGroup){const a=(s=this.beans.showRowGroupCols)==null?void 0:s.getSourceColumnsForGroupColumn(t),c=!(a==null?void 0:a.every(u=>t.getSort()==u.getSort()));e.toggleCss("ag-header-cell-sorted-mixed",c)}};e.addManagedEventListeners({sortChanged:i,columnRowGroupChanged:i})}initCol(e){const{sort:t,initialSort:r,sortIndex:n,initialSortIndex:i}=e.colDef;t!==void 0?(t==="asc"||t==="desc")&&(e.sort=t):(r==="asc"||r==="desc")&&(e.sort=r),n!==void 0?n!==null&&(e.sortIndex=n):i!==null&&(e.sortIndex=i)}updateColSort(e,t,r){t!==void 0&&(t==="desc"||t==="asc"?this.setColSort(e,t,r):this.setColSort(e,void 0,r))}setColSort(e,t,r){e.sort!==t&&(e.sort=t,e.dispatchColEvent("sortChanged",r)),e.dispatchStateUpdatedEvent("sort")}setColSortIndex(e,t){e.sortIndex=t,e.dispatchStateUpdatedEvent("sortIndex")}createSortIndicator(e){return new Pp(e)}getSortIndicatorSelector(){return Jz}},Fd={agSetColumnFilter:"SetFilter",agSetColumnFloatingFilter:"SetFilter",agMultiColumnFilter:"MultiFilter",agMultiColumnFloatingFilter:"MultiFilter",agGroupColumnFilter:"GroupFilter",agGroupColumnFloatingFilter:"GroupFilter",agGroupCellRenderer:"GroupCellRenderer",agGroupRowRenderer:"GroupCellRenderer",agRichSelect:"RichSelect",agRichSelectCellEditor:"RichSelect",agDetailCellRenderer:"SharedMasterDetail",agSparklineCellRenderer:"Sparklines",agDragAndDropImage:"SharedDragAndDrop",agColumnHeader:"ColumnHeaderComp",agColumnGroupHeader:"ColumnGroupHeaderComp",agSortIndicator:"Sort",agAnimateShowChangeCellRenderer:"HighlightChanges",agAnimateSlideCellRenderer:"HighlightChanges",agLoadingCellRenderer:"LoadingCellRenderer",agSkeletonCellRenderer:"SkeletonCellRenderer",agCheckboxCellRenderer:"CheckboxCellRenderer",agLoadingOverlay:"Overlay",agNoRowsOverlay:"Overlay",agTooltipComponent:"Tooltip",agReadOnlyFloatingFilter:"CustomFilter",agTextColumnFilter:"TextFilter",agNumberColumnFilter:"NumberFilter",agDateColumnFilter:"DateFilter",agDateInput:"DateFilter",agTextColumnFloatingFilter:"TextFilter",agNumberColumnFloatingFilter:"NumberFilter",agDateColumnFloatingFilter:"DateFilter",agCellEditor:"TextEditor",agSelectCellEditor:"SelectEditor",agTextCellEditor:"TextEditor",agNumberCellEditor:"NumberEditor",agDateCellEditor:"DateEditor",agDateStringCellEditor:"DateEditor",agCheckboxCellEditor:"CheckboxEditor",agLargeTextCellEditor:"LargeTextEditor",agMenuItem:"MenuItem",agColumnsToolPanel:"ColumnsToolPanel",agFiltersToolPanel:"FiltersToolPanel",agAggregationComponent:"StatusBar",agSelectedRowCountComponent:"StatusBar",agTotalRowCountComponent:"StatusBar",agFilteredRowCountComponent:"StatusBar",agTotalAndFilteredRowCountComponent:"StatusBar",agFindCellRenderer:"Find"},Qz={aggFunc:"SharedAggregation",autoHeight:"RowAutoHeight",cellClass:"CellStyle",cellClassRules:"CellStyle",cellEditor:({cellEditor:e,editable:t})=>t?typeof e=="string"?Fd[e]??"CustomEditor":"CustomEditor":null,cellRenderer:({cellRenderer:e})=>typeof e!="string"?null:Fd[e],cellStyle:"CellStyle",columnChooserParams:"ColumnMenu",contextMenuItems:"ContextMenu",dndSource:"DragAndDrop",dndSourceOnRowDrag:"DragAndDrop",editable:({editable:e,cellEditor:t})=>e&&!t?"TextEditor":null,enableCellChangeFlash:"HighlightChanges",enablePivot:"SharedPivot",enableRowGroup:"SharedRowGrouping",enableValue:"SharedAggregation",filter:({filter:e})=>e&&typeof e!="string"&&typeof e!="boolean"?"CustomFilter":typeof e=="string"?Fd[e]??"ColumnFilter":"ColumnFilter",floatingFilter:"ColumnFilter",getQuickFilterText:"QuickFilter",headerTooltip:"Tooltip",mainMenuItems:"ColumnMenu",menuTabs:e=>{var r;const t=["columnsMenuTab","generalMenuTab"];return(r=e.menuTabs)!=null&&r.some(n=>t.includes(n))?"ColumnMenu":null},pivot:"SharedPivot",pivotIndex:"SharedPivot",rowDrag:"RowDrag",rowGroup:"SharedRowGrouping",rowGroupIndex:"SharedRowGrouping",tooltipField:"Tooltip",tooltipValueGetter:"Tooltip",spanRows:"CellSpan"},eN={alignedGrids:"AlignedGrids",allowContextMenuWithControlKey:"ContextMenu",autoSizeStrategy:"ColumnAutoSize",cellSelection:"CellSelection",columnHoverHighlight:"ColumnHover",datasource:"InfiniteRowModel",doesExternalFilterPass:"ExternalFilter",editType:"EditCore",enableAdvancedFilter:"AdvancedFilter",enableCellSpan:"CellSpan",enableCharts:"IntegratedCharts",enableRangeSelection:"CellSelection",enableRowPinning:"PinnedRow",findSearchValue:"Find",getContextMenuItems:"ContextMenu",getLocaleText:"Locale",getMainMenuItems:"ColumnMenu",getRowClass:"RowStyle",getRowStyle:"RowStyle",groupTotalRow:"SharedRowGrouping",grandTotalRow:"SharedRowGrouping",initialState:"GridState",isExternalFilterPresent:"ExternalFilter",isRowPinnable:"PinnedRow",localeText:"Locale",masterDetail:"SharedMasterDetail",pagination:"Pagination",pinnedBottomRowData:"PinnedRow",pinnedTopRowData:"PinnedRow",pivotMode:"SharedPivot",pivotPanelShow:"RowGroupingPanel",quickFilterText:"QuickFilter",rowClass:"RowStyle",rowClassRules:"RowStyle",rowData:"ClientSideRowModel",rowDragManaged:"RowDrag",rowGroupPanelShow:"RowGroupingPanel",rowNumbers:"RowNumbers",rowSelection:"SharedRowSelection",rowStyle:"RowStyle",serverSideDatasource:"ServerSideRowModel",sideBar:"SideBar",statusBar:"StatusBar",treeData:"SharedTreeData",undoRedoCellEditing:"UndoRedoEdit",valueCache:"ValueCache",viewportDatasource:"ViewportRowModel"},tN=0,rN=0,nN=class extends q{constructor(){super(...arguments),this.beanName="gos",this.domDataKey="__AG_"+Math.random().toString(),this.gridInstanceId=rN++,this.gridReadyFired=!1,this.queueEvents=[],this.propEventSvc=new Wn,this.globalEventHandlerFactory=e=>(t,r)=>{if(!this.isAlive())return;const n=Kz.has(t);if(n&&!e||!n&&e)return;const i=(o,s)=>{const a=this.gridOptions[mI(o)];typeof a=="function"&&this.beans.frameworkOverrides.wrapOutgoing(()=>a(s))};if(this.gridReadyFired)i(t,r);else if(t==="gridReady"){i(t,r),this.gridReadyFired=!0;for(const o of this.queueEvents)i(o.eventName,o.event);this.queueEvents=[]}else this.queueEvents.push({eventName:t,event:r})}}wireBeans(e){this.gridOptions=e.gridOptions,this.validation=e.validation,this.api=e.gridApi,this.gridId=e.context.getGridId()}get gridOptionsContext(){return this.gridOptions.context}postConstruct(){this.validateGridOptions(this.gridOptions),this.eventSvc.addGlobalListener(this.globalEventHandlerFactory().bind(this),!0),this.eventSvc.addGlobalListener(this.globalEventHandlerFactory(!0).bind(this),!1),this.propEventSvc.setFrameworkOverrides(this.beans.frameworkOverrides),this.addManagedEventListeners({gridOptionsChanged:({options:e})=>{this.updateGridOptions({options:e,force:!0,source:"gridOptionsUpdated"})}})}destroy(){super.destroy(),this.queueEvents=[]}get(e){return this.gridOptions[e]??qz[e]}getCallback(e){return this.mergeGridCommonParams(this.gridOptions[e])}exists(e){return ie(this.gridOptions[e])}mergeGridCommonParams(e){return e&&(r=>e(this.addGridCommonParams(r)))}updateGridOptions({options:e,force:t,source:r="api"}){const n={id:tN++,properties:[]},i=[],{gridOptions:o,validation:s}=this;for(const a of Object.keys(e)){const l=e[a];s==null||s.warnOnInitialPropertyUpdate(r,a);const c=t||typeof l=="object"&&r==="api",u=o[a];if(c||u!==l){o[a]=l;const d={type:a,currentValue:l,previousValue:u,changeSet:n,source:r};i.push(d)}}this.validateGridOptions(this.gridOptions),n.properties=i.map(a=>a.type),i.forEach(a=>{Vn(this,`Updated property ${a.type} from`,a.previousValue," to ",a.currentValue),this.propEventSvc.dispatchEvent(a)})}addPropertyEventListener(e,t){this.propEventSvc.addEventListener(e,t)}removePropertyEventListener(e,t){this.propEventSvc.removeEventListener(e,t)}getDomDataKey(){return this.domDataKey}addGridCommonParams(e){return e.api=this.api,e.context=this.gridOptionsContext,e}validateOptions(e,t){for(const r of Object.keys(e)){const n=e[r];if(n==null||n===!1)continue;let i=t[r];typeof i=="function"&&(i=i(e,this.gridOptions,this.beans)),i&&this.assertModuleRegistered(i,r)}}validateGridOptions(e){var t;this.validateOptions(e,eN),(t=this.validation)==null||t.processGridOptions(e)}validateColDef(e,t,r){var n,i;(r||!((n=this.beans.dataTypeSvc)!=null&&n.isColPendingInference(t)))&&(this.validateOptions(e,Qz),(i=this.validation)==null||i.validateColDef(e))}assertModuleRegistered(e,t){const r=Array.isArray(e)?e.some(n=>this.isModuleRegistered(n)):this.isModuleRegistered(e);return r||_e(200,{...this.getModuleErrorParams(),moduleName:e,reasonOrId:t}),r}getModuleErrorParams(){return{gridId:this.gridId,gridScoped:O1(),rowModelType:this.get("rowModelType"),isUmd:j_()}}isModuleRegistered(e){return Lh(e,this.gridId,this.get("rowModelType"))}};function kS(e){const t={"aria-hidden":"true"};return{tag:"div",cls:"ag-cell-label-container",role:"presentation",children:[{tag:"span",ref:"eMenu",cls:"ag-header-icon ag-header-cell-menu-button",attrs:t},{tag:"span",ref:"eFilterButton",cls:"ag-header-icon ag-header-cell-filter-button",attrs:t},{tag:"div",ref:"eLabel",cls:"ag-header-cell-label",role:"presentation",children:[{tag:"span",ref:"eText",cls:"ag-header-cell-text"},{tag:"span",ref:"eFilter",cls:"ag-header-icon ag-header-label-icon ag-filter-icon",attrs:t},e?{tag:"ag-sort-indicator",ref:"eSortIndicator"}:null]}]}}var iN=kS(!0),oN=kS(!1),sN=class extends ct{constructor(){super(...arguments),this.eFilter=fe,this.eFilterButton=fe,this.eSortIndicator=fe,this.eMenu=fe,this.eLabel=fe,this.eText=fe,this.eSortOrder=fe,this.eSortAsc=fe,this.eSortDesc=fe,this.eSortMixed=fe,this.eSortNone=fe,this.isLoadingInnerComponent=!1}refresh(e){var r,n,i;const t=this.params;if(this.params=e,this.workOutTemplate(e,!!((r=this.beans)!=null&&r.sortSvc))!=this.currentTemplate||this.workOutShowMenu()!=this.currentShowMenu||e.enableSorting!=this.currentSort||this.currentSuppressMenuHide!=null&&this.shouldSuppressMenuHide()!=this.currentSuppressMenuHide||t.enableFilterButton!=e.enableFilterButton||t.enableFilterIcon!=e.enableFilterIcon)return!1;if(this.innerHeaderComponent){const o={...e};Et(o,e.innerHeaderComponentParams),(i=(n=this.innerHeaderComponent).refresh)==null||i.call(n,o)}else this.setDisplayName(e);return!0}workOutTemplate(e,t){const r=e.template;return r?r!=null&&r.trim?r.trim():r:t?iN:oN}init(e){this.params=e;const{sortSvc:t,touchSvc:r,rowNumbersSvc:n,userCompFactory:i}=this.beans,o=t==null?void 0:t.getSortIndicatorSelector();this.currentTemplate=this.workOutTemplate(e,!!o),this.setTemplate(this.currentTemplate,o?[o]:void 0),r==null||r.setupForHeader(this),this.setMenu(),this.setupSort(),n==null||n.setupForHeader(this),this.setupFilterIcon(),this.setupFilterButton(),this.workOutInnerHeaderComponent(i,e),this.setDisplayName(e)}workOutInnerHeaderComponent(e,t){const r=w_(e,t,t);r&&(this.isLoadingInnerComponent=!0,r.newAgStackInstance().then(n=>{this.isLoadingInnerComponent=!1,n&&(this.isAlive()?(this.innerHeaderComponent=n,this.eText&&this.eText.appendChild(n.getGui())):this.destroyBean(n))}))}setDisplayName(e){const{displayName:t}=e,r=this.currentDisplayName;this.currentDisplayName=t,!(!this.eText||r===t||this.innerHeaderComponent||this.isLoadingInnerComponent)&&(this.eText.textContent=Sa(t))}addInIcon(e,t,r){const n=Co(e,this.beans,r);n&&t.appendChild(n)}workOutShowMenu(){var e;return this.params.enableMenu&&!!((e=this.beans.menuSvc)!=null&&e.isHeaderMenuButtonEnabled())}shouldSuppressMenuHide(){var e;return!!((e=this.beans.menuSvc)!=null&&e.isHeaderMenuButtonAlwaysShowEnabled())}setMenu(){if(!this.eMenu)return;if(this.currentShowMenu=this.workOutShowMenu(),!this.currentShowMenu){jn(this.eMenu),this.eMenu=void 0;return}const{gos:e,eMenu:t,params:r}=this,n=Bt(e);this.addInIcon(n?"menu":"menuAlt",t,r.column),t.classList.toggle("ag-header-menu-icon",!n);const i=this.shouldSuppressMenuHide();this.currentSuppressMenuHide=i,this.addManagedElementListeners(t,{click:()=>this.showColumnMenu(this.eMenu)}),this.toggleMenuAlwaysShow(i)}toggleMenuAlwaysShow(e){var t;(t=this.eMenu)==null||t.classList.toggle("ag-header-menu-always-show",e)}showColumnMenu(e){const{currentSuppressMenuHide:t,params:r}=this;t||this.toggleMenuAlwaysShow(!0),r.showColumnMenu(e,()=>{t||this.toggleMenuAlwaysShow(!1)})}onMenuKeyboardShortcut(e){var l;const{params:t,gos:r,beans:n,eMenu:i,eFilterButton:o}=this,s=t.column,a=Bt(r);if(e&&!a){if((l=n.menuSvc)!=null&&l.isFilterMenuInHeaderEnabled(s))return t.showFilter(o??i??this.getGui()),!0}else if(t.enableMenu)return this.showColumnMenu(i??o??this.getGui()),!0;return!1}setupSort(){const{sortSvc:e}=this.beans;if(!e)return;const{enableSorting:t,column:r}=this.params;if(this.currentSort=t,!this.eSortIndicator){this.eSortIndicator=this.createBean(e.createSortIndicator(!0));const{eSortIndicator:n,eSortOrder:i,eSortAsc:o,eSortDesc:s,eSortMixed:a,eSortNone:l}=this;n.attachCustomElements(i,o,s,a,l)}this.eSortIndicator.setupSort(r),this.currentSort&&e.setupHeader(this,r,this.eLabel)}setupFilterIcon(){const{eFilter:e,params:t}=this;if(!e)return;const r=()=>{const n=t.column.isFilterActive();Je(e,n,{skipAriaHidden:!0})};this.configureFilter(t.enableFilterIcon,e,r,"filterActive")}setupFilterButton(){const{eFilterButton:e,params:t}=this;if(!e)return;this.configureFilter(t.enableFilterButton,e,this.onFilterChangedButton.bind(this),"filter")?this.addManagedElementListeners(e,{click:()=>t.showFilter(e)}):this.eFilterButton=void 0}configureFilter(e,t,r,n){if(!e)return jn(t),!1;const i=this.params.column;return this.addInIcon(n,t,i),this.addManagedListeners(i,{filterChanged:r}),r(),!0}onFilterChangedButton(){const e=this.params.column.isFilterActive();this.eFilterButton.classList.toggle("ag-filter-active",e)}getAnchorElementForMenu(e){const{eFilterButton:t,eMenu:r}=this;return e?t??r??this.getGui():r??t??this.getGui()}destroy(){super.destroy(),this.innerHeaderComponent&&(this.destroyBean(this.innerHeaderComponent),this.innerHeaderComponent=void 0)}},aN={tag:"div",cls:"ag-header-group-cell-label",role:"presentation",children:[{tag:"span",ref:"agLabel",cls:"ag-header-group-text",role:"presentation"},{tag:"span",ref:"agOpened",cls:"ag-header-icon ag-header-expand-icon ag-header-expand-icon-expanded"},{tag:"span",ref:"agClosed",cls:"ag-header-icon ag-header-expand-icon ag-header-expand-icon-collapsed"}]},lN=class extends ct{constructor(){super(aN),this.agOpened=fe,this.agClosed=fe,this.agLabel=fe,this.isLoadingInnerComponent=!1}init(e){const{userCompFactory:t,touchSvc:r}=this.beans;this.params=e,this.checkWarnings(),this.workOutInnerHeaderGroupComponent(t,e),this.setupLabel(e),this.addGroupExpandIcon(e),this.setupExpandIcons(),r==null||r.setupForHeaderGroup(this)}checkWarnings(){this.params.template&&Q(89)}workOutInnerHeaderGroupComponent(e,t){const r=x_(e,t,t);r&&(this.isLoadingInnerComponent=!0,r.newAgStackInstance().then(n=>{this.isLoadingInnerComponent=!1,n&&(this.isAlive()?(this.innerHeaderGroupComponent=n,this.agLabel.appendChild(n.getGui())):this.destroyBean(n))}))}setupExpandIcons(){const{agOpened:e,agClosed:t,params:{columnGroup:r},beans:n}=this;this.addInIcon("columnGroupOpened",e),this.addInIcon("columnGroupClosed",t);const i=l=>{if(Lr(l))return;const c=!r.isExpanded();n.colGroupSvc.setColumnGroupOpened(r.getProvidedColumnGroup(),c,"uiColumnExpanded")};this.addTouchAndClickListeners(n,t,i),this.addTouchAndClickListeners(n,e,i);const o=l=>{Kn(l)};this.addManagedElementListeners(t,{dblclick:o}),this.addManagedElementListeners(e,{dblclick:o}),this.addManagedElementListeners(this.getGui(),{dblclick:i}),this.updateIconVisibility();const s=r.getProvidedColumnGroup(),a=this.updateIconVisibility.bind(this);this.addManagedListeners(s,{expandedChanged:a,expandableChanged:a})}addTouchAndClickListeners(e,t,r){var n;(n=e.touchSvc)==null||n.setupForHeaderGroupElement(this,t,r),this.addManagedElementListeners(t,{click:r})}updateIconVisibility(){const{agOpened:e,agClosed:t,params:{columnGroup:r}}=this;if(r.isExpandable()){const n=r.isExpanded();Je(e,n),Je(t,!n)}else Je(e,!1),Je(t,!1)}addInIcon(e,t){const r=Co(e,this.beans,null);r&&t.appendChild(r)}addGroupExpandIcon(e){if(!e.columnGroup.isExpandable()){const{agOpened:t,agClosed:r}=this;Je(t,!1),Je(r,!1);return}}setupLabel(e){var i;const{displayName:t,columnGroup:r}=e,n=this.innerHeaderGroupComponent||this.isLoadingInnerComponent;ie(t)&&!n&&(this.agLabel.textContent=Sa(t)),this.toggleCss("ag-sticky-label",!((i=r.getColGroupDef())!=null&&i.suppressStickyLabel))}destroy(){super.destroy(),this.innerHeaderGroupComponent&&(this.destroyBean(this.innerHeaderGroupComponent),this.innerHeaderGroupComponent=void 0)}},cN={moduleName:"ColumnHeaderComp",version:he,userComponents:{agColumnHeader:sN},icons:{menu:"menu",menuAlt:"menu-alt"}},uN={moduleName:"ColumnGroupHeaderComp",version:he,userComponents:{agColumnGroupHeader:lN},icons:{columnGroupOpened:"expanded",columnGroupClosed:"contracted"}},dN=class extends q{constructor(){super(...arguments),this.beanName="animationFrameSvc",this.p1={list:[],sorted:!1},this.p2={list:[],sorted:!1},this.f1={list:[],sorted:!1},this.destroyTasks=[],this.ticking=!1,this.scrollGoingDown=!0,this.lastScrollTop=0,this.taskCount=0}setScrollTop(e){this.scrollGoingDown=e>=this.lastScrollTop,e===0&&(this.scrollGoingDown=!0),this.lastScrollTop=e}postConstruct(){this.active=!this.gos.get("suppressAnimationFrame"),this.batchFrameworkComps=this.beans.frameworkOverrides.batchFrameworkComps}verify(){this.active===!1&&Q(92)}createTask(e,t,r,n){this.verify();let i=r;n&&this.batchFrameworkComps&&(i="f1");const o={task:e,index:t,createOrder:++this.taskCount};this.addTaskToList(this[i],o),this.schedule()}addTaskToList(e,t){e.list.push(t),e.sorted=!1}sortTaskList(e){if(e.sorted)return;const t=this.scrollGoingDown?1:-1;e.list.sort((r,n)=>r.index!==n.index?t*(n.index-r.index):n.createOrder-r.createOrder),e.sorted=!0}addDestroyTask(e){this.verify(),this.destroyTasks.push(e),this.schedule()}executeFrame(e){const{p1:t,p2:r,f1:n,destroyTasks:i,beans:o}=this,{ctrlsSvc:s,frameworkOverrides:a}=o,l=t.list,c=r.list,u=n.list,d=Date.now();let h=0;const f=e<=0,g=s.getScrollFeature();for(;f||h<e;){if(!g.scrollGridIfNeeded()){let p;if(l.length)this.sortTaskList(t),p=l.pop().task;else if(c.length)this.sortTaskList(r),p=c.pop().task;else if(u.length)a.wrapOutgoing(()=>{for(;(f||h<e)&&!g.scrollGridIfNeeded();){if(u.length)this.sortTaskList(n),p=u.pop().task,p();else break;h=Date.now()-d}}),p=()=>{};else if(i.length)p=i.pop();else break;p()}h=Date.now()-d}l.length||c.length||u.length||i.length?this.requestFrame():this.ticking=!1}flushAllFrames(){this.active&&this.executeFrame(-1)}schedule(){this.active&&(this.ticking||(this.ticking=!0,this.requestFrame()))}requestFrame(){const e=this.executeFrame.bind(this,60);Ur(this.beans,e)}isQueueEmpty(){return!this.ticking}},hN={moduleName:"AnimationFrame",version:he,beans:[dN]},fN=class extends q{constructor(){super(...arguments),this.beanName="touchSvc"}mockBodyContextMenu(e,t){this.mockContextMenu(e,e.eBodyViewport,t)}mockHeaderContextMenu(e,t){this.mockContextMenu(e,e.eGui,t)}mockRowContextMenu(e){if(!Dn())return;const t=(r,n,i)=>{var a;const{rowCtrl:o,cellCtrl:s}=e.getControlsForEventTarget((i==null?void 0:i.target)??null);s!=null&&s.column&&s.dispatchCellContextMenuEvent(i??null),(a=this.beans.contextMenuSvc)==null||a.handleContextMenuMouseEvent(void 0,i,o,s)};this.mockContextMenu(e,e.element,t)}handleCellDoubleClick(e,t){return(()=>{if(!Dn()||d1("dblclick"))return!1;const n=Date.now(),i=n-e.lastIPadMouseClickEvent<200;return e.lastIPadMouseClickEvent=n,i})()?(e.onCellDoubleClicked(t),t.preventDefault(),!0):!1}setupForHeader(e){const{gos:t,sortSvc:r,menuSvc:n}=this.beans;if(t.get("suppressTouch"))return;const{params:i,eMenu:o,eFilterButton:s}=e,a=new wn(e.getGui(),!0),l=e.shouldSuppressMenuHide(),c=l&&ie(o)&&i.enableMenu,u=c?new wn(o,!0):a;if(i.enableMenu||n!=null&&n.isHeaderContextMenuEnabled(i.column)){const d=c?"tap":"longTap",h=f=>i.showColumnMenuAfterMouseClick(f.touchStart);e.addManagedListeners(u,{[d]:h})}if(i.enableSorting){const d=h=>{const f=h.touchStart.target;l&&(o!=null&&o.contains(f)||s!=null&&s.contains(f))||r==null||r.progressSort(i.column,!1,"uiColumnSorted")};e.addManagedListeners(a,{tap:d})}if(i.enableFilterButton&&s){const d=new wn(s,!0);e.addManagedListeners(d,{tap:()=>i.showFilter(s)}),e.addDestroyFunc(()=>d.destroy())}e.addDestroyFunc(()=>a.destroy()),c&&e.addDestroyFunc(()=>u.destroy())}setupForHeaderGroup(e){var r;const t=e.params;if((r=this.beans.menuSvc)!=null&&r.isHeaderContextMenuEnabled(t.columnGroup.getProvidedColumnGroup())){const n=new wn(t.eGridHeader,!0),i=o=>t.showColumnMenuAfterMouseClick(o.touchStart);e.addManagedListeners(n,{longTap:i}),e.addDestroyFunc(()=>n.destroy())}}setupForHeaderGroupElement(e,t,r){const n=new wn(t,!0);e.addManagedListeners(n,{tap:r}),e.addDestroyFunc(()=>n.destroy())}mockContextMenu(e,t,r){if(!Dn())return;const n=new wn(t),i=o=>{Ms(this.gos,o.touchEvent)&&r(void 0,o.touchStart,o.touchEvent)};e.addManagedListeners(n,{longTap:i}),e.addDestroyFunc(()=>n.destroy())}},gN={moduleName:"Touch",version:he,beans:[fN]},pN=class extends q{constructor(){super(...arguments),this.beanName="cellNavigation"}wireBeans(e){this.rowSpanSvc=e.rowSpanSvc}getNextCellToFocus(e,t,r=!1){return r?this.getNextCellToFocusWithCtrlPressed(e,t):this.getNextCellToFocusWithoutCtrlPressed(e,t)}getNextCellToFocusWithCtrlPressed(e,t){const r=e===j.UP,n=e===j.DOWN,i=e===j.LEFT;let o,s;const{pageBounds:a,gos:l,visibleCols:c}=this.beans;if(r||n)s=r?a.getFirstRow():a.getLastRow(),o=t.column;else{const u=l.get("enableRtl");s=t.rowIndex,o=(i!==u?c.allCols:[...c.allCols].reverse()).find(h=>this.isCellGoodToFocusOn({rowIndex:s,rowPinned:null,column:h}))}return o?{rowIndex:s,rowPinned:null,column:o}:null}getNextCellToFocusWithoutCtrlPressed(e,t){let r=t,n=!1;for(;!n;){switch(e){case j.UP:r=this.getCellAbove(r);break;case j.DOWN:r=this.getCellBelow(r);break;case j.RIGHT:r=this.gos.get("enableRtl")?this.getCellToLeft(r):this.getCellToRight(r);break;case j.LEFT:r=this.gos.get("enableRtl")?this.getCellToRight(r):this.getCellToLeft(r);break;default:r=null,Q(8,{key:e});break}r?n=this.isCellGoodToFocusOn(r):n=!0}return r}isCellGoodToFocusOn(e){const t=e.column;let r;const{pinnedRowModel:n,rowModel:i}=this.beans;switch(e.rowPinned){case"top":r=n==null?void 0:n.getPinnedTopRow(e.rowIndex);break;case"bottom":r=n==null?void 0:n.getPinnedBottomRow(e.rowIndex);break;default:r=i.getRow(e.rowIndex);break}return r?!this.isSuppressNavigable(t,r):!1}getCellToLeft(e){if(!e)return null;const t=this.beans.visibleCols.getColBefore(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getCellToRight(e){if(!e)return null;const t=this.beans.visibleCols.getColAfter(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getCellBelow(e){var n;if(!e)return null;const t=((n=this.rowSpanSvc)==null?void 0:n.getCellEnd(e))??e,r=Iv(this.beans,t);return r?{rowIndex:r.rowIndex,column:e.column,rowPinned:r.rowPinned}:null}getCellAbove(e){var n;if(!e)return null;const t=((n=this.rowSpanSvc)==null?void 0:n.getCellStart(e))??e,r=Gl(this.beans,{rowIndex:t.rowIndex,rowPinned:t.rowPinned});return r?{rowIndex:r.rowIndex,column:e.column,rowPinned:r.rowPinned}:null}getNextTabbedCell(e,t){return t?this.getNextTabbedCellBackwards(e):this.getNextTabbedCellForwards(e)}getNextTabbedCellForwards(e){const{visibleCols:t,pagination:r}=this.beans,n=t.allCols;let i=e.rowIndex,o=e.rowPinned,s=t.getColAfter(e.column);if(!s){s=n[0];const a=Iv(this.beans,e);if(Xe(a)||!a.rowPinned&&!((r==null?void 0:r.isRowInPage(a.rowIndex))??!0))return null;i=a?a.rowIndex:null,o=a?a.rowPinned:null}return{rowIndex:i,column:s,rowPinned:o}}getNextTabbedCellBackwards(e){const{beans:t}=this,{visibleCols:r,pagination:n}=t,i=r.allCols;let o=e.rowIndex,s=e.rowPinned,a=r.getColBefore(e.column);if(!a){a=Ee(i);const l=Gl(t,{rowIndex:e.rowIndex,rowPinned:e.rowPinned});if(Xe(l)||!l.rowPinned&&!((n==null?void 0:n.isRowInPage(l.rowIndex))??!0))return null;o=l?l.rowIndex:null,s=l?l.rowPinned:null}return{rowIndex:o,column:a,rowPinned:s}}isSuppressNavigable(e,t){const{suppressNavigable:r}=e.colDef;if(typeof r=="boolean")return r;if(typeof r=="function"){const n=e.createColumnFunctionCallbackParams(t);return r(n)}return!1}};function mN(e){return e.focusSvc.getFocusedCell()}function vN(e){return e.focusSvc.clearFocusedCell()}function yN(e,t,r,n){e.focusSvc.setFocusedCell({rowIndex:t,column:r,rowPinned:n,forceBrowserFocus:!0})}function bN(e,t){var r;return((r=e.navigation)==null?void 0:r.tabToNextCell(!1,t))??!1}function CN(e,t){var r;return((r=e.navigation)==null?void 0:r.tabToNextCell(!0,t))??!1}function wN(e,t,r=!1){var i;const n=(i=e.headerNavigation)==null?void 0:i.getHeaderPositionForColumn(t,r);n&&e.focusSvc.focusHeaderPosition({headerPosition:n})}var SN=class extends q{constructor(){super(),this.beanName="navigation",this.onPageDown=Sv(this.onPageDown,100),this.onPageUp=Sv(this.onPageUp,100)}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridBodyCon=e.gridBodyCtrl})}handlePageScrollingKey(e,t=!1){const r=e.key,n=e.altKey,i=e.ctrlKey||e.metaKey,o=!!this.beans.rangeSvc&&e.shiftKey,s=mL(this.gos,e);let a=!1;switch(r){case j.PAGE_HOME:case j.PAGE_END:!i&&!n&&(this.onHomeOrEndKey(r),a=!0);break;case j.LEFT:case j.RIGHT:case j.UP:case j.DOWN:if(!s)return!1;i&&!n&&!o&&(this.onCtrlUpDownLeftRight(r,s),a=!0);break;case j.PAGE_DOWN:case j.PAGE_UP:!i&&!n&&(a=this.handlePageUpDown(r,s,t));break}return a&&e.preventDefault(),a}handlePageUpDown(e,t,r){return r&&(t=this.beans.focusSvc.getFocusedCell()),t?(e===j.PAGE_UP?this.onPageUp(t):this.onPageDown(t),!0):!1}navigateTo(e){const{scrollIndex:t,scrollType:r,scrollColumn:n,focusIndex:i,focusColumn:o}=e,{scrollFeature:s}=this.gridBodyCon;ie(n)&&!n.isPinned()&&s.ensureColumnVisible(n),ie(t)&&s.ensureIndexVisible(t,r),e.isAsync||s.ensureIndexVisible(i);const{focusSvc:a,rangeSvc:l}=this.beans;a.setFocusedCell({rowIndex:i,column:o,rowPinned:null,forceBrowserFocus:!0}),l==null||l.setRangeToCell({rowIndex:i,rowPinned:null,column:o})}onPageDown(e){const t=this.beans,r=Od(t),n=this.getViewportHeight(),{pageBounds:i,rowModel:o,rowAutoHeight:s}=t,a=i.getPixelOffset(),l=r.top+n,c=o.getRowIndexAtPixel(l+a);s!=null&&s.active?this.navigateToNextPageWithAutoHeight(e,c):this.navigateToNextPage(e,c)}onPageUp(e){const t=this.beans,r=Od(t),{pageBounds:n,rowModel:i,rowAutoHeight:o}=t,s=n.getPixelOffset(),a=r.top,l=i.getRowIndexAtPixel(a+s);o!=null&&o.active?this.navigateToNextPageWithAutoHeight(e,l,!0):this.navigateToNextPage(e,l,!0)}navigateToNextPage(e,t,r=!1){const{pageBounds:n,rowModel:i}=this.beans,o=this.getViewportHeight(),s=n.getFirstRow(),a=n.getLastRow(),l=n.getPixelOffset(),c=i.getRow(e.rowIndex),u=r?(c==null?void 0:c.rowHeight)-o-l:o-l,d=(c==null?void 0:c.rowTop)+u;let h=i.getRowIndexAtPixel(d+l);if(h===e.rowIndex){const g=r?-1:1;t=h=e.rowIndex+g}let f;r?(f="bottom",h<s&&(h=s),t<s&&(t=s)):(f="top",h>a&&(h=a),t>a&&(t=a)),this.isRowTallerThanView(i.getRow(h))&&(t=h,f="top"),this.navigateTo({scrollIndex:t,scrollType:f,scrollColumn:null,focusIndex:h,focusColumn:e.column})}navigateToNextPageWithAutoHeight(e,t,r=!1){this.navigateTo({scrollIndex:t,scrollType:r?"bottom":"top",scrollColumn:null,focusIndex:t,focusColumn:e.column}),setTimeout(()=>{const n=this.getNextFocusIndexForAutoHeight(e,r);this.navigateTo({scrollIndex:t,scrollType:r?"bottom":"top",scrollColumn:null,focusIndex:n,focusColumn:e.column,isAsync:!0})},50)}getNextFocusIndexForAutoHeight(e,t=!1){const r=t?-1:1,n=this.getViewportHeight(),{pageBounds:i,rowModel:o}=this.beans,s=i.getLastRow();let a=0,l=e.rowIndex;for(;l>=0&&l<=s;){const c=o.getRow(l);if(c){const u=c.rowHeight??0;if(a+u>n)break;a+=u}l+=r}return Math.max(0,Math.min(l,s))}getViewportHeight(){const e=this.beans,t=Od(e),r=this.beans.scrollVisibleSvc.getScrollbarWidth();let n=t.bottom-t.top;return e.ctrlsSvc.get("center").isHorizontalScrollShowing()&&(n-=r),n}isRowTallerThanView(e){if(!e)return!1;const t=e.rowHeight;return typeof t!="number"?!1:t>this.getViewportHeight()}onCtrlUpDownLeftRight(e,t){const r=this.beans.cellNavigation.getNextCellToFocus(e,t,!0),{rowIndex:n}=r,i=r.column;this.navigateTo({scrollIndex:n,scrollType:null,scrollColumn:i,focusIndex:n,focusColumn:i})}onHomeOrEndKey(e){const t=e===j.PAGE_HOME,{visibleCols:r,pageBounds:n,rowModel:i}=this.beans,o=r.allCols,s=t?n.getFirstRow():n.getLastRow(),a=i.getRow(s);if(!a)return;const l=(t?o:[...o].reverse()).find(c=>!c.isSuppressNavigable(a));l&&this.navigateTo({scrollIndex:s,scrollType:null,scrollColumn:l,focusIndex:s,focusColumn:l})}onTabKeyDown(e,t){const r=t.shiftKey,n=this.tabToNextCellCommon(e,r,t),i=this.beans,{ctrlsSvc:o,pageBounds:s,focusSvc:a,gos:l}=i;if(n!==!1){n?t.preventDefault():n===null&&o.get("gridCtrl").allowFocusForNextCoreContainer(r);return}if(r){const{rowIndex:c,rowPinned:u}=e.getRowPosition();(u?c===0:c===s.getFirstRow())&&(l.get("headerHeight")===0||Ln(i)?Os(i,!0,!0):(t.preventDefault(),a.focusPreviousFromFirstCell(t)))}else e instanceof vl&&e.focusCell(!0),(!r&&a.focusOverlay(!1)||Os(i,r))&&t.preventDefault()}tabToNextCell(e,t){const r=this.beans,{focusSvc:n,rowRenderer:i}=r,o=n.getFocusedCell();if(!o)return!1;let s=Na(r,o);return!s&&(s=i.getRowByPosition(o),!s||!s.isFullWidth())?!1:!!this.tabToNextCellCommon(s,e,t)}tabToNextCellCommon(e,t,r){let n=e.editing;if(!n&&e instanceof vl){const s=e.rowCtrl;s&&(n=s.editing)}let i;return n?this.gos.get("editType")==="fullRow"?i=this.moveToNextEditingRow(e,t,r):i=this.moveToNextEditingCell(e,t,r):i=this.moveToNextCellNotEditing(e,t,r),i===null?i:i||!!this.beans.focusSvc.focusedHeader}moveToNextEditingCell(e,t,r=null){var o;const n=e.cellPosition;e.eGui.focus(),e.stopEditing();const i=this.findNextCellToFocusOn(n,t,!0);return i===!1?null:i==null?!1:((o=this.beans.editSvc)==null||o.startEditing(i,null,!0,r),i.focusCell(!1),!0)}moveToNextEditingRow(e,t,r=null){const n=e.cellPosition,i=this.findNextCellToFocusOn(n,t,!0);if(i===!1)return null;if(i==null)return!1;const o=i.cellPosition,s=this.isCellEditable(n),a=this.isCellEditable(o),l=o&&n.rowIndex===o.rowIndex&&n.rowPinned===o.rowPinned,{editSvc:c,rowEditSvc:u}=this.beans;if(s&&(c==null||c.setFocusOutOnEditor(e)),!l){const d=e.rowCtrl;c==null||c.stopRowEditing(d);const h=i.rowCtrl;u==null||u.startEditing(h,void 0,void 0,r)}return a?(c==null||c.setFocusInOnEditor(i),i.focusCell()):i.focusCell(!0),!0}moveToNextCellNotEditing(e,t,r){const n=this.beans.visibleCols.allCols;let i;if(e instanceof Nh){if(i={...e.getRowPosition(),column:t?n[0]:Ee(n)},this.gos.get("embedFullWidthRows")&&r){const s=e.findFullWidthInfoForEvent(r);s&&(i.column=s.column)}}else i=e.getFocusedCellPosition();const o=this.findNextCellToFocusOn(i,t,!1);if(o===!1)return null;if(o instanceof vl)o.focusCell(!0);else if(o)return this.tryToFocusFullWidthRow(o,t);return ie(o)}findNextCellToFocusOn(e,t,r){let n=e;const i=this.beans,{cellNavigation:o,gos:s,focusSvc:a,rowRenderer:l,rangeSvc:c}=i;for(;;){e!==n&&(e=n),t||(n=this.getLastCellOfColSpan(n)),n=o.getNextTabbedCell(n,t);const u=s.getCallback("tabToNextCell");if(ie(u)){const g=u({backwards:t,editing:r,previousCellPosition:e,nextCellPosition:n||null});if(g===!0)n=e;else{if(g===!1)return!1;n={rowIndex:g.rowIndex,column:g.column,rowPinned:g.rowPinned}}}if(!n)return null;if(n.rowIndex<0){const f=pr(i);return a.focusHeaderPosition({headerPosition:{headerRowIndex:f+n.rowIndex,column:n.column},fromCell:!0}),null}const d=s.get("editType")==="fullRow";if(r&&!d&&!this.isCellEditable(n))continue;this.ensureCellVisible(n);const h=Na(i,n);if(!h){const f=l.getRowByPosition(n);if(!f||!f.isFullWidth()||r)continue;return{...f.getRowPosition(),column:n==null?void 0:n.column}}if(!o.isSuppressNavigable(h.column,h.rowNode))return h.setFocusedCellPosition(n),c==null||c.setRangeToCell(n),h}}isCellEditable(e){const t=this.lookupRowNodeForCell(e);return t?e.column.isCellEditable(t):!1}lookupRowNodeForCell({rowIndex:e,rowPinned:t}){const{pinnedRowModel:r,rowModel:n}=this.beans;return t==="top"?r==null?void 0:r.getPinnedTopRow(e):t==="bottom"?r==null?void 0:r.getPinnedBottomRow(e):n.getRow(e)}navigateToNextCell(e,t,r,n){let i=r,o=!1;const s=this.beans,{cellNavigation:a,focusSvc:l,gos:c}=s;for(;i&&(i===r||!this.isValidNavigateCell(i));)c.get("enableRtl")?t===j.LEFT&&(i=this.getLastCellOfColSpan(i)):t===j.RIGHT&&(i=this.getLastCellOfColSpan(i)),i=a.getNextCellToFocus(t,i),o=Xe(i);if(o&&e&&e.key===j.UP&&(i={rowIndex:-1,rowPinned:null,column:r.column}),n){const d=c.getCallback("navigateToNextCell");if(ie(d)){const f=d({key:t,previousCellPosition:r,nextCellPosition:i||null,event:e});ie(f)?i={rowPinned:f.rowPinned,rowIndex:f.rowIndex,column:f.column}:i=null}}if(!i)return;if(i.rowIndex<0){const d=pr(s);l.focusHeaderPosition({headerPosition:{headerRowIndex:d+i.rowIndex,column:r.column},event:e||void 0,fromCell:!0});return}const u=this.getNormalisedPosition(i);u?this.focusPosition(u):this.tryToFocusFullWidthRow(i)}getNormalisedPosition(e){var n;if(!!((n=this.beans.spannedRowRenderer)!=null&&n.getCellByPosition(e)))return e;this.ensureCellVisible(e);const r=Na(this.beans,e);return r?(e=r.getFocusedCellPosition(),this.ensureCellVisible(e),e):null}tryToFocusFullWidthRow(e,t){const{visibleCols:r,rowRenderer:n,focusSvc:i,eventSvc:o}=this.beans,s=r.allCols,a=n.getRowByPosition(e);if(!a||!a.isFullWidth())return!1;const l=i.getFocusedCell(),c={rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:e.column||(t?Ee(s):s[0])};this.focusPosition(c);const u=t??(l!=null&&bL(c,l));return o.dispatchEvent({type:"fullWidthRowFocused",rowIndex:c.rowIndex,rowPinned:c.rowPinned,column:c.column,isFullWidthCell:!0,fromBelow:u}),!0}focusPosition(e){const{focusSvc:t,rangeSvc:r}=this.beans;t.setFocusedCell({rowIndex:e.rowIndex,column:e.column,rowPinned:e.rowPinned,forceBrowserFocus:!0}),r==null||r.setRangeToCell(e)}isValidNavigateCell(e){return!!B1(this.beans,e)}getLastCellOfColSpan(e){const t=Na(this.beans,e);if(!t)return e;const r=t.getColSpanningList();return r.length===1?e:{rowIndex:e.rowIndex,column:Ee(r),rowPinned:e.rowPinned}}ensureCellVisible(e){const t=s1(this.gos),r=this.beans.rowModel.getRow(e.rowIndex),n=t&&(r==null?void 0:r.sticky),{scrollFeature:i}=this.gridBodyCon;!n&&Xe(e.rowPinned)&&i.ensureIndexVisible(e.rowIndex),e.column.isPinned()||i.ensureColumnVisible(e.column)}};function Od(e){return e.ctrlsSvc.getScrollFeature().getVScrollPosition()}var xN={moduleName:"KeyboardNavigation",version:he,beans:[SN,pN,Hz],apiFunctions:{getFocusedCell:mN,clearFocusedCell:vN,setFocusedCell:yN,setFocusedHeader:wN,tabToNextCell:bN,tabToPreviousCell:CN}},AN=class extends q{constructor(){super(...arguments),this.beanName="pageBoundsListener"}postConstruct(){this.addManagedEventListeners({modelUpdated:this.onModelUpdated.bind(this),recalculateRowBounds:this.calculatePages.bind(this)}),this.onModelUpdated()}onModelUpdated(e){this.calculatePages(),this.eventSvc.dispatchEvent({type:"paginationChanged",animate:(e==null?void 0:e.animate)??!1,newData:(e==null?void 0:e.newData)??!1,newPage:(e==null?void 0:e.newPage)??!1,newPageSize:(e==null?void 0:e.newPageSize)??!1,keepRenderedRows:(e==null?void 0:e.keepRenderedRows)??!1})}calculatePages(){const{pageBounds:e,pagination:t,rowModel:r}=this.beans;t?t.calculatePages():e.calculateBounds(0,r.getRowCount()-1)}},PN=class extends q{constructor(){super(...arguments),this.beanName="pageBounds",this.pixelOffset=0}getFirstRow(){var e;return((e=this.topRowBounds)==null?void 0:e.rowIndex)??-1}getLastRow(){var e;return((e=this.bottomRowBounds)==null?void 0:e.rowIndex)??-1}getCurrentPageHeight(){const{topRowBounds:e,bottomRowBounds:t}=this;return!e||!t?0:Math.max(t.rowTop+t.rowHeight-e.rowTop,0)}getCurrentPagePixelRange(){const{topRowBounds:e,bottomRowBounds:t}=this,r=(e==null?void 0:e.rowTop)??0,n=t?t.rowTop+t.rowHeight:0;return{pageFirstPixel:r,pageLastPixel:n}}calculateBounds(e,t){const{rowModel:r}=this.beans,n=r.getRowBounds(e);n&&(n.rowIndex=e),this.topRowBounds=n;const i=r.getRowBounds(t);i&&(i.rowIndex=t),this.bottomRowBounds=i,this.calculatePixelOffset()}getPixelOffset(){return this.pixelOffset}calculatePixelOffset(){var t;const e=((t=this.topRowBounds)==null?void 0:t.rowTop)??0;this.pixelOffset!==e&&(this.pixelOffset=e,this.eventSvc.dispatchEvent({type:"paginationPixelOffsetChanged"}))}},RN=".ag-pinned-left-floating-bottom,.ag-pinned-left-floating-top,.ag-pinned-right-floating-bottom,.ag-pinned-right-floating-top{min-width:0;overflow:hidden;position:relative}.ag-pinned-left-sticky-top,.ag-pinned-right-sticky-top{height:100%;overflow:hidden;position:relative}.ag-sticky-bottom-full-width-container,.ag-sticky-top-full-width-container{height:100%;overflow:hidden;width:100%}.ag-pinned-left-header,.ag-pinned-right-header{display:inline-block;height:100%;overflow:hidden;position:relative}.ag-body-horizontal-scroll:not(.ag-scrollbar-invisible){.ag-horizontal-left-spacer:not(.ag-scroller-corner){border-right:var(--ag-pinned-column-border)}.ag-horizontal-right-spacer:not(.ag-scroller-corner){border-left:var(--ag-pinned-column-border)}}.ag-pinned-right-header{border-left:var(--ag-pinned-column-border)}.ag-pinned-left-header{border-right:var(--ag-pinned-column-border)}.ag-cell.ag-cell-first-right-pinned:not(.ag-cell-range-left,.ag-cell-range-single-cell,.ag-cell-focus:not(.ag-cell-range-selected):focus-within){border-left:var(--ag-pinned-column-border)}.ag-cell.ag-cell-last-left-pinned:not(.ag-cell-range-right,.ag-cell-range-single-cell,.ag-cell-focus:not(.ag-cell-range-selected):focus-within){border-right:var(--ag-pinned-column-border)}.ag-pinned-left-header .ag-header-cell-resize:after{left:calc(50% - var(--ag-header-column-resize-handle-width))}.ag-pinned-right-header .ag-header-cell-resize:after{left:50%}.ag-pinned-left-header .ag-header-cell-resize{right:-3px}.ag-pinned-right-header .ag-header-cell-resize{left:-3px}",EN=class extends q{constructor(e,t){super(),this.isLeft=e,this.elements=t,this.getWidth=e?()=>this.beans.pinnedCols.leftWidth:()=>this.beans.pinnedCols.rightWidth}postConstruct(){this.addManagedEventListeners({[`${this.isLeft?"left":"right"}PinnedWidthChanged`]:this.onPinnedWidthChanged.bind(this)})}onPinnedWidthChanged(){const e=this.getWidth(),t=e>0;for(const r of this.elements)r&&(Je(r,t),yr(r,e))}},TN=class extends q{constructor(){super(...arguments),this.beanName="pinnedCols"}postConstruct(){this.beans.ctrlsSvc.whenReady(this,t=>{this.gridBodyCtrl=t.gridBodyCtrl});const e=this.checkContainerWidths.bind(this);this.addManagedEventListeners({displayedColumnsChanged:e,displayedColumnsWidthChanged:e}),this.addManagedPropertyListener("domLayout",e)}checkContainerWidths(){const{gos:e,visibleCols:t,eventSvc:r}=this.beans,n=pt(e,"print"),i=n?0:t.getColsLeftWidth(),o=n?0:t.getDisplayedColumnsRightWidth();i!=this.leftWidth&&(this.leftWidth=i,r.dispatchEvent({type:"leftPinnedWidthChanged"})),o!=this.rightWidth&&(this.rightWidth=o,r.dispatchEvent({type:"rightPinnedWidthChanged"}))}keepPinnedColumnsNarrowerThanViewport(){const e=this.gridBodyCtrl.eBodyViewport,t=As(e);if(t<=50)return;const r=this.getPinnedColumnsOverflowingViewport(t-50),n=this.gos.getCallback("processUnpinnedColumns"),{columns:i,hasLockedPinned:o}=r;let s=i;!s.length&&!o||(n&&(s=n({columns:s,viewportWidth:t})),!(!s||!s.length)&&(s=s.filter(a=>!Pi(a)),this.setColsPinned(s,null,"viewportSizeFeature")))}createPinnedWidthFeature(e,...t){return new EN(e,t)}setColsPinned(e,t,r){const{colModel:n,colAnimation:i,visibleCols:o,gos:s}=this.beans;if(!n.cols||!(e!=null&&e.length))return;if(pt(s,"print")){Q(37);return}i==null||i.start();let a;t===!0||t==="left"?a="left":t==="right"?a="right":a=null;const l=[];e.forEach(c=>{if(!c)return;const u=n.getCol(c);u&&u.getPinned()!==a&&(this.setColPinned(u,a),l.push(u))}),l.length&&(o.refresh(r),A1(this.eventSvc,l,r)),i==null||i.finish()}initCol(e){const{pinned:t,initialPinned:r}=e.colDef;t!==void 0?this.setColPinned(e,t):this.setColPinned(e,r)}setColPinned(e,t){t===!0||t==="left"?e.pinned="left":t==="right"?e.pinned="right":e.pinned=null,e.dispatchStateUpdatedEvent("pinned")}setupHeaderPinnedWidth(e){const{scrollVisibleSvc:t}=this.beans;if(e.pinned==null)return;const r=e.pinned==="left",n=e.pinned==="right";e.hidden=!0;const i=()=>{const o=r?this.leftWidth:this.rightWidth;if(o==null)return;const s=o==0,a=e.hidden!==s,l=this.gos.get("enableRtl"),c=t.getScrollbarWidth(),d=t.verticalScrollShowing&&(l&&r||!l&&n)?o+c:o;e.comp.setPinnedContainerWidth(`${d}px`),e.comp.setDisplayed(!s),a&&(e.hidden=s,e.refresh())};e.addManagedEventListeners({leftPinnedWidthChanged:i,rightPinnedWidthChanged:i,scrollVisibilityChanged:i,scrollbarWidthChanged:i})}getHeaderResizeDiff(e,t){if(t.getPinned()){const{leftWidth:n,rightWidth:i}=this,o=As(this.beans.ctrlsSvc.getGridBodyCtrl().eBodyViewport)-50;if(n+i+e>o)if(o>n+i)e=o-n-i;else return 0}return e}getPinnedColumnsOverflowingViewport(e){const t=this.rightWidth??0,r=this.leftWidth??0,n=t+r;let i=!1;if(n<e)return{columns:[],hasLockedPinned:i};const{visibleCols:o}=this.beans,s=[...o.leftCols],a=[...o.rightCols];let l=0,c=0;const u=0,d=[];let h=n-u-e;for(;(c<s.length||l<a.length)&&h>0;){if(l<a.length){const f=a[l++];if(f.colDef.lockPinned){i=!0;continue}h-=f.getActualWidth(),d.push(f)}if(c<s.length&&h>0){const f=s[c++];if(f.colDef.lockPinned){i=!0;continue}h-=f.getActualWidth(),d.push(f)}}return{columns:d,hasLockedPinned:i}}},FN={moduleName:"PinnedColumn",version:he,beans:[TN],css:[RN]},ON=class extends q{constructor(){super(),this.beanName="ariaAnnounce",this.descriptionContainer=null,this.pendingAnnouncements=new Map,this.lastAnnouncement="",this.updateAnnouncement=kr(this,this.updateAnnouncement.bind(this),200)}postConstruct(){const e=this.beans,t=gt(e),r=this.descriptionContainer=t.createElement("div");r.classList.add("ag-aria-description-container"),L2(r,"polite"),Ok(r,"additions text"),Fk(r,!0),e.eGridDiv.appendChild(r)}announceValue(e,t){this.pendingAnnouncements.set(t,e),this.updateAnnouncement()}updateAnnouncement(){if(!this.descriptionContainer)return;const e=Array.from(this.pendingAnnouncements.values()).join(". ");this.pendingAnnouncements.clear(),this.descriptionContainer.textContent="",setTimeout(()=>{if(this.isAlive()&&this.descriptionContainer){let t=e;this.lastAnnouncement===t&&(t=`${t}.`),this.lastAnnouncement=t,this.descriptionContainer.textContent=t}},50)}destroy(){var t;super.destroy();const{descriptionContainer:e}=this;e&&(hn(e),(t=e.parentElement)==null||t.removeChild(e)),this.descriptionContainer=null,this.pendingAnnouncements.clear()}},MN={moduleName:"Aria",version:he,beans:[ON]};function DN(e){var t;(t=e.overlays)==null||t.showLoadingOverlay()}function kN(e){var t;(t=e.overlays)==null||t.showNoRowsOverlay()}function IN(e){var t;(t=e.overlays)==null||t.hideOverlay()}var _N=".ag-overlay{inset:0;pointer-events:none;position:absolute;z-index:2}.ag-overlay-panel,.ag-overlay-wrapper{display:flex;height:100%;width:100%}.ag-overlay-wrapper{align-items:center;flex:none;justify-content:center;text-align:center}.ag-overlay-loading-wrapper{pointer-events:all}.ag-overlay-loading-center{background:var(--ag-background-color);border:1px solid var(--ag-border-color);border-radius:var(--ag-border-radius);box-shadow:var(--ag-popup-shadow);padding:var(--ag-spacing)}",LN={tag:"div",cls:"ag-overlay",role:"presentation",children:[{tag:"div",cls:"ag-overlay-panel",role:"presentation",children:[{tag:"div",ref:"eOverlayWrapper",cls:"ag-overlay-wrapper",role:"presentation"}]}]},IS=class extends ct{constructor(){super(LN),this.eOverlayWrapper=fe,this.activePromise=null,this.activeOverlay=null,this.updateListenerDestroyFunc=null,this.activeCssClass=null,this.elToFocusAfter=null,this.registerCSS(_N)}handleKeyDown(e){if(e.key!==j.TAB||e.defaultPrevented||Lr(e))return;const t=this.beans;if(yo(t,this.eOverlayWrapper,!1,e.shiftKey))return;let n=!1;e.shiftKey?n=t.focusSvc.focusGridView({column:Ee(t.visibleCols.allCols),backwards:!0,canFocusOverlay:!1}):n=Os(t,!1),n&&e.preventDefault()}updateLayoutClasses(e,t){const r=this.eOverlayWrapper.classList,{AUTO_HEIGHT:n,NORMAL:i,PRINT:o}=yl;r.toggle(n,t.autoHeight),r.toggle(i,t.normal),r.toggle(o,t.print)}postConstruct(){this.createManagedBean(new gp(this)),this.setDisplayed(!1,{skipAriaHidden:!0}),this.beans.overlays.setOverlayWrapperComp(this),this.addManagedElementListeners(this.getFocusableElement(),{keydown:this.handleKeyDown.bind(this)})}setWrapperTypeClass(e){const t=this.eOverlayWrapper.classList;this.activeCssClass&&t.toggle(this.activeCssClass,!1),this.activeCssClass=e,t.toggle(e,!0)}showOverlay(e,t,r,n){if(this.setWrapperTypeClass(t),this.destroyActiveOverlay(),this.elToFocusAfter=null,this.activePromise=e,!!e){if(this.setDisplayed(!0,{skipAriaHidden:!0}),r&&this.isGridFocused()){const i=Ke(this.beans);i&&!o1(this.beans)&&(this.elToFocusAfter=i)}e.then(i=>{if(this.activePromise!==e){this.activeOverlay!==i&&(this.destroyBean(i),i=null);return}if(this.activePromise=null,!!i){if(this.activeOverlay!==i&&(this.eOverlayWrapper.appendChild(i.getGui()),this.activeOverlay=i,n)){const o=i;this.updateListenerDestroyFunc=this.addManagedPropertyListener(n,({currentValue:s})=>{var a;(a=o.refresh)==null||a.call(o,pe(this.gos,{...s??{}}))})}r&&this.isGridFocused()&&qn(this.eOverlayWrapper)}})}}updateOverlayWrapperPaddingTop(e){this.eOverlayWrapper.style.setProperty("padding-top",`${e}px`)}destroyActiveOverlay(){var n;this.activePromise=null;const e=this.activeOverlay;if(!e)return;let t=this.elToFocusAfter;this.activeOverlay=null,this.elToFocusAfter=null,t&&!this.isGridFocused()&&(t=null);const r=this.updateListenerDestroyFunc;r&&(r(),this.updateListenerDestroyFunc=null),this.destroyBean(e),hn(this.eOverlayWrapper),(n=t==null?void 0:t.focus)==null||n.call(t,{preventScroll:!0})}hideOverlay(){this.destroyActiveOverlay(),this.setDisplayed(!1,{skipAriaHidden:!0})}isGridFocused(){const e=Ke(this.beans);return!!e&&this.beans.eGridDiv.contains(e)}destroy(){this.elToFocusAfter=null,this.destroyActiveOverlay(),this.beans.overlays.setOverlayWrapperComp(void 0),super.destroy()}},BN={selector:"AG-OVERLAY-WRAPPER",component:IS},zN=class extends q{constructor(){super(...arguments),this.beanName="overlays",this.state=0,this.showInitialOverlay=!0,this.wrapperPadding=0}postConstruct(){this.isClientSide=xt(this.gos),this.isServerSide=!this.isClientSide&&po(this.gos);const e=()=>this.updateOverlayVisibility();this.addManagedEventListeners({newColumnsLoaded:e,rowDataUpdated:e,gridSizeChanged:this.refreshWrapperPadding.bind(this),rowCountReady:()=>{this.showInitialOverlay=!1,this.updateOverlayVisibility()}}),this.addManagedPropertyListener("loading",e)}setOverlayWrapperComp(e){this.eWrapper=e,this.updateOverlayVisibility()}isVisible(){return this.state!==0&&!!this.eWrapper}isExclusive(){return this.state===1&&!!this.eWrapper}showLoadingOverlay(){this.showInitialOverlay=!1;const e=this.gos,t=e.get("loading");!t&&(t!==void 0||e.get("suppressLoadingOverlay"))||this.doShowLoadingOverlay()}showNoRowsOverlay(){this.showInitialOverlay=!1;const e=this.gos;e.get("loading")||e.get("suppressNoRowsOverlay")||this.doShowNoRowsOverlay()}hideOverlay(){if(this.showInitialOverlay=!1,this.gos.get("loading")){Q(99);return}this.doHideOverlay()}getOverlayWrapperSelector(){return BN}getOverlayWrapperCompClass(){return IS}updateOverlayVisibility(){if(!this.eWrapper){this.state=0;return}const{state:e,isClientSide:t,isServerSide:r,beans:{gos:n,colModel:i,rowModel:o}}=this;let s=this.gos.get("loading");s!==void 0&&(this.showInitialOverlay=!1),this.showInitialOverlay&&s===void 0&&!n.get("suppressLoadingOverlay")&&(s=!n.get("columnDefs")||!i.ready||!n.get("rowData")&&t),s?e!==1&&this.doShowLoadingOverlay():(this.showInitialOverlay=!1,t&&o.isEmpty()&&!n.get("suppressNoRowsOverlay")?e!==2&&this.doShowNoRowsOverlay():(e===1||!r&&e!==0)&&this.doHideOverlay())}doShowLoadingOverlay(){this.eWrapper&&(this.state=1,this.showOverlay(O_(this.beans.userCompFactory,pe(this.gos,{})),"ag-overlay-loading-wrapper","loadingOverlayComponentParams"),this.updateExclusive())}doShowNoRowsOverlay(){this.eWrapper&&(this.state=2,this.showOverlay(M_(this.beans.userCompFactory,pe(this.gos,{})),"ag-overlay-no-rows-wrapper","noRowsOverlayComponentParams"),this.updateExclusive())}doHideOverlay(){this.eWrapper&&(this.state=0,this.eWrapper.hideOverlay(),this.updateExclusive())}showOverlay(e,t,r){var i;const n=(e==null?void 0:e.newAgStackInstance())??null;(i=this.eWrapper)==null||i.showOverlay(n,t,this.isExclusive(),r),this.refreshWrapperPadding()}updateExclusive(){const e=this.exclusive;this.exclusive=this.isExclusive(),this.exclusive!==e&&this.eventSvc.dispatchEvent({type:"overlayExclusiveChanged"})}refreshWrapperPadding(){const e=this.eWrapper;if(!e)return;let t=0;if(this.state===2){const r=this.beans.ctrlsSvc.get("gridHeaderCtrl");t=(r==null?void 0:r.headerHeight)||0}else this.wrapperPadding!==0&&(t=0);this.wrapperPadding!==t&&(this.wrapperPadding=t,e.updateOverlayWrapperPaddingTop(t))}},NN={moduleName:"Overlay",version:he,userComponents:{agLoadingOverlay:A3,agNoRowsOverlay:R3},apiFunctions:{showLoadingOverlay:DN,showNoRowsOverlay:kN,hideOverlay:IN},beans:[zN]},$N=class extends q{constructor(){super(...arguments),this.beanName="rowContainerHeight",this.scrollY=0,this.uiBodyHeight=0}postConstruct(){this.addManagedEventListeners({bodyHeightChanged:this.updateOffset.bind(this)}),this.maxDivHeight=$k(),Vn(this.gos,"RowContainerHeightService - maxDivHeight = "+this.maxDivHeight)}updateOffset(){if(!this.stretching)return;const e=this.beans.ctrlsSvc.getScrollFeature().getVScrollPosition().top,t=this.getUiBodyHeight();(e!==this.scrollY||t!==this.uiBodyHeight)&&(this.scrollY=e,this.uiBodyHeight=t,this.calculateOffset())}calculateOffset(){this.setUiContainerHeight(this.maxDivHeight),this.pixelsToShave=this.modelHeight-this.uiContainerHeight,this.maxScrollY=this.uiContainerHeight-this.uiBodyHeight;const e=this.scrollY/this.maxScrollY,t=e*this.pixelsToShave;Vn(this.gos,`RowContainerHeightService - Div Stretch Offset = ${t} (${this.pixelsToShave} * ${e})`),this.setDivStretchOffset(t)}setUiContainerHeight(e){e!==this.uiContainerHeight&&(this.uiContainerHeight=e,this.eventSvc.dispatchEvent({type:"rowContainerHeightChanged"}))}clearOffset(){this.setUiContainerHeight(this.modelHeight),this.pixelsToShave=0,this.setDivStretchOffset(0)}setDivStretchOffset(e){const t=typeof e=="number"?Math.floor(e):null;this.divStretchOffset!==t&&(this.divStretchOffset=t,this.eventSvc.dispatchEvent({type:"heightScaleChanged"}))}setModelHeight(e){this.modelHeight=e,this.stretching=e!=null&&this.maxDivHeight>0&&e>this.maxDivHeight,this.stretching?this.calculateOffset():this.clearOffset()}getRealPixelPosition(e){return e-this.divStretchOffset}getUiBodyHeight(){const e=this.beans.ctrlsSvc.getScrollFeature().getVScrollPosition();return e.bottom-e.top}getScrollPositionForPixel(e){if(this.pixelsToShave<=0)return e;const t=this.modelHeight-this.getUiBodyHeight(),r=e/t;return this.maxScrollY*r}},HN=400,GN=class extends q{constructor(){super(...arguments),this.beanName="rowRenderer",this.destroyFuncsForColumnListeners=[],this.rowCtrlsByRowIndex={},this.zombieRowCtrls={},this.allRowCtrls=[],this.topRowCtrls=[],this.bottomRowCtrls=[],this.refreshInProgress=!1,this.dataFirstRenderedFired=!1,this.setupRangeSelectionListeners=()=>{const e=()=>{this.getAllCellCtrls().forEach(o=>o.onCellSelectionChanged())},t=()=>{this.getAllCellCtrls().forEach(o=>o.updateRangeBordersIfRangeCount())},r=()=>{this.eventSvc.addEventListener("cellSelectionChanged",e),this.eventSvc.addEventListener("columnMoved",t),this.eventSvc.addEventListener("columnPinned",t),this.eventSvc.addEventListener("columnVisible",t)},n=()=>{this.eventSvc.removeEventListener("cellSelectionChanged",e),this.eventSvc.removeEventListener("columnMoved",t),this.eventSvc.removeEventListener("columnPinned",t),this.eventSvc.removeEventListener("columnVisible",t)};this.addDestroyFunc(()=>n()),this.addManagedPropertyListeners(["enableRangeSelection","cellSelection"],()=>{Es(this.gos)?r():n()}),Es(this.gos)&&r()}}wireBeans(e){this.pageBounds=e.pageBounds,this.colModel=e.colModel,this.pinnedRowModel=e.pinnedRowModel,this.rowModel=e.rowModel,this.focusSvc=e.focusSvc,this.rowContainerHeight=e.rowContainerHeight,this.ctrlsSvc=e.ctrlsSvc}postConstruct(){this.ctrlsSvc.whenReady(this,e=>{this.gridBodyCtrl=e.gridBodyCtrl,this.initialise()})}initialise(){this.addManagedEventListeners({paginationChanged:this.onPageLoaded.bind(this),pinnedRowDataChanged:this.onPinnedRowDataChanged.bind(this),pinnedRowsChanged:this.onPinnedRowsChanged.bind(this),displayedColumnsChanged:this.onDisplayedColumnsChanged.bind(this),bodyScroll:this.onBodyScroll.bind(this),bodyHeightChanged:this.redraw.bind(this,{})}),this.addManagedPropertyListeners(["domLayout","embedFullWidthRows"],()=>this.onDomLayoutChanged()),this.addManagedPropertyListeners(["suppressMaxRenderedRowRestriction","rowBuffer"],()=>this.redraw()),this.addManagedPropertyListener("suppressCellFocus",n=>this.onSuppressCellFocusChanged(n.currentValue)),this.addManagedPropertyListeners(["groupSuppressBlankHeader","getBusinessKeyForNode","fullWidthCellRenderer","fullWidthCellRendererParams","suppressStickyTotalRow","groupRowRenderer","groupRowRendererParams","loadingCellRenderer","loadingCellRendererParams","detailCellRenderer","detailCellRendererParams","enableRangeSelection","enableCellTextSelection"],()=>this.redrawRows()),this.addManagedPropertyListener("cellSelection",({currentValue:n,previousValue:i})=>{(!i&&n||i&&!n)&&this.redrawRows()});const{stickyRowSvc:e,gos:t,showRowGroupCols:r}=this.beans;if(r&&this.addManagedPropertyListener("showOpenedGroup",()=>{const n=r.getShowRowGroupCols();n.length&&this.refreshCells({columns:n,force:!0})}),e)this.stickyRowFeature=e.createStickyRowFeature(this,this.createRowCon.bind(this),this.destroyRowCtrls.bind(this));else{const n=this.gridBodyCtrl;n.setStickyTopHeight(0),n.setStickyBottomHeight(0)}this.registerCellEventListeners(),this.initialiseCache(),this.printLayout=pt(t,"print"),this.embedFullWidthRows=this.printLayout||t.get("embedFullWidthRows"),this.redrawAfterModelUpdate()}initialiseCache(){if(this.gos.get("keepDetailRows")){const e=this.getKeepDetailRowsCount(),t=e??3;this.cachedRowCtrls=new WN(t)}}getKeepDetailRowsCount(){return this.gos.get("keepDetailRowsCount")}getStickyTopRowCtrls(){var e;return((e=this.stickyRowFeature)==null?void 0:e.stickyTopRowCtrls)??[]}getStickyBottomRowCtrls(){var e;return((e=this.stickyRowFeature)==null?void 0:e.stickyBottomRowCtrls)??[]}updateAllRowCtrls(){var n;const e=Object.values(this.rowCtrlsByRowIndex),t=Object.values(this.zombieRowCtrls),r=((n=this.cachedRowCtrls)==null?void 0:n.getEntries())??[];t.length>0||r.length>0?this.allRowCtrls=[...e,...t,...r]:this.allRowCtrls=e}isCellBeingRendered(e,t){var i;const r=this.rowCtrlsByRowIndex[e];return!t||!r?!!r:r.isFullWidth()?!0:!!((i=this.beans.spannedRowRenderer)==null?void 0:i.getCellByPosition({rowIndex:e,column:t,rowPinned:null}))||!!r.getCellCtrl(t)||!r.isRowRendered()}updateCellFocus(e){this.getAllCellCtrls().forEach(t=>t.onCellFocused(e)),this.getFullWidthRowCtrls().forEach(t=>t.onFullWidthRowFocused(e))}onCellFocusChanged(e){if(e&&e.rowIndex!=null&&!e.rowPinned){const t=this.beans.colModel.getCol(e.column)??void 0;this.isCellBeingRendered(e.rowIndex,t)||this.redraw()}this.updateCellFocus(e)}onSuppressCellFocusChanged(e){this.getAllCellCtrls().forEach(t=>t.onSuppressCellFocusChanged(e)),this.getFullWidthRowCtrls().forEach(t=>t.onSuppressCellFocusChanged(e))}registerCellEventListeners(){this.addManagedEventListeners({cellFocused:e=>this.onCellFocusChanged(e),cellFocusCleared:()=>this.updateCellFocus(),flashCells:e=>{const{cellFlashSvc:t}=this.beans;t&&this.getAllCellCtrls().forEach(r=>t.onFlashCells(r,e))},columnHoverChanged:()=>{this.getAllCellCtrls().forEach(e=>e.onColumnHover())},displayedColumnsChanged:()=>{this.getAllCellCtrls().forEach(e=>e.onDisplayedColumnsChanged())},displayedColumnsWidthChanged:()=>{this.printLayout&&this.getAllCellCtrls().forEach(e=>e.onLeftChanged())}}),this.setupRangeSelectionListeners(),this.refreshListenersToColumnsForCellComps(),this.addManagedEventListeners({gridColumnsChanged:this.refreshListenersToColumnsForCellComps.bind(this)}),this.addDestroyFunc(this.removeGridColumnListeners.bind(this))}removeGridColumnListeners(){this.destroyFuncsForColumnListeners.forEach(e=>e()),this.destroyFuncsForColumnListeners.length=0}refreshListenersToColumnsForCellComps(){this.removeGridColumnListeners(),this.colModel.getCols().forEach(t=>{const r=l=>{this.getAllCellCtrls().forEach(c=>{c.column===t&&l(c)})},n=()=>{r(l=>l.onLeftChanged())},i=()=>{r(l=>l.onWidthChanged())},o=()=>{r(l=>l.onFirstRightPinnedChanged())},s=()=>{r(l=>l.onLastLeftPinnedChanged())},a=()=>{r(l=>l.onColDefChanged())};t.__addEventListener("leftChanged",n),t.__addEventListener("widthChanged",i),t.__addEventListener("firstRightPinnedChanged",o),t.__addEventListener("lastLeftPinnedChanged",s),t.__addEventListener("colDefChanged",a),this.destroyFuncsForColumnListeners.push(()=>{t.__removeEventListener("leftChanged",n),t.__removeEventListener("widthChanged",i),t.__removeEventListener("firstRightPinnedChanged",o),t.__removeEventListener("lastLeftPinnedChanged",s),t.__removeEventListener("colDefChanged",a)})})}onDomLayoutChanged(){const e=pt(this.gos,"print"),t=e||this.gos.get("embedFullWidthRows"),r=t!==this.embedFullWidthRows||this.printLayout!==e;this.printLayout=e,this.embedFullWidthRows=t,r&&this.redrawAfterModelUpdate({domLayoutChanged:!0})}datasourceChanged(){this.firstRenderedRow=0,this.lastRenderedRow=-1;const e=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(e)}onPageLoaded(e){const t={recycleRows:e.keepRenderedRows,animate:e.animate,newData:e.newData,newPage:e.newPage,onlyBody:!0};this.redrawAfterModelUpdate(t)}getAllCellsNotSpanningForColumn(e){const t=[];return this.getAllRowCtrls().forEach(r=>{var i;const n=(i=r.getCellCtrl(e,!0))==null?void 0:i.eGui;n&&t.push(n)}),t}refreshFloatingRowComps(e=!0){this.refreshFloatingRows(this.topRowCtrls,"top",e),this.refreshFloatingRows(this.bottomRowCtrls,"bottom",e)}refreshFloatingRows(e,t,r){const{pinnedRowModel:n,beans:i,printLayout:o}=this,s=Object.fromEntries(e.map(l=>[l.rowNode.id,l]));n==null||n.forEachPinnedRow(t,(l,c)=>{const u=e[c];u&&n.getPinnedRowById(u.rowNode.id,t)===void 0&&(u.destroyFirstPass(),u.destroySecondPass()),l.id in s&&r?(e[c]=s[l.id],delete s[l.id]):e[c]=new Nh(l,i,!1,!1,o)});const a=(t==="top"?n==null?void 0:n.getPinnedTopRowCount():n==null?void 0:n.getPinnedBottomRowCount())??0;e.length=a}onPinnedRowDataChanged(){const e={recycleRows:!0};this.redrawAfterModelUpdate(e)}onPinnedRowsChanged(){this.redrawAfterModelUpdate({recycleRows:!0})}redrawRow(e,t=!1){var r,n;if(e.sticky)(r=this.stickyRowFeature)==null||r.refreshStickyNode(e);else if((n=this.cachedRowCtrls)!=null&&n.has(e)){this.cachedRowCtrls.removeRow(e);return}else{const i=o=>{const s=o[e.rowIndex];s&&s.rowNode===e&&(s.destroyFirstPass(),s.destroySecondPass(),o[e.rowIndex]=this.createRowCon(e,!1,!1))};switch(e.rowPinned){case"top":i(this.topRowCtrls);break;case"bottom":i(this.bottomRowCtrls);break;default:i(this.rowCtrlsByRowIndex),this.updateAllRowCtrls()}}t||this.dispatchDisplayedRowsChanged(!1)}redrawRows(e){if(e!=null){e==null||e.forEach(r=>this.redrawRow(r,!0)),this.dispatchDisplayedRowsChanged(!1);return}this.redrawAfterModelUpdate()}redrawAfterModelUpdate(e={}){var a;this.getLockOnRefresh();const t=(a=this.beans.focusSvc)==null?void 0:a.getFocusCellToUseAfterRefresh();this.updateContainerHeights(),this.scrollToTopIfNewData(e);const r=!e.domLayoutChanged&&!!e.recycleRows,n=e.animate&&xi(this.gos),i=r?this.getRowsToRecycle():null;r||this.removeAllRowComps(),this.workOutFirstAndLastRowsToRender();const{stickyRowFeature:o,gos:s}=this;if(o){o.checkStickyRows();const l=o.extraTopHeight+o.extraBottomHeight;l&&this.updateContainerHeights(l)}this.recycleRows(i,n),this.gridBodyCtrl.updateRowCount(),e.onlyBody||this.refreshFloatingRowComps(s.get("enableRowPinning")?r:void 0),this.dispatchDisplayedRowsChanged(),t!=null&&this.restoreFocusedCell(t),this.releaseLockOnRefresh()}scrollToTopIfNewData(e){var n;const t=e.newData||e.newPage,r=this.gos.get("suppressScrollOnNewData");t&&!r&&(this.gridBodyCtrl.scrollFeature.scrollToTop(),(n=this.stickyRowFeature)==null||n.resetOffsets())}updateContainerHeights(e=0){const{rowContainerHeight:t}=this;if(this.printLayout){t.setModelHeight(null);return}let r=this.pageBounds.getCurrentPageHeight();r===0&&(r=1),t.setModelHeight(r+e)}getLockOnRefresh(){var e,t;if(this.refreshInProgress)throw new Error(e1(252));this.refreshInProgress=!0,(t=(e=this.beans.frameworkOverrides).getLockOnRefresh)==null||t.call(e)}releaseLockOnRefresh(){var e,t;this.refreshInProgress=!1,(t=(e=this.beans.frameworkOverrides).releaseLockOnRefresh)==null||t.call(e)}isRefreshInProgress(){return this.refreshInProgress}restoreFocusedCell(e){if(!e)return;const t=this.beans.focusSvc,r=this.findPositionToFocus(e);if(!r){t.focusHeaderPosition({headerPosition:{headerRowIndex:pr(this.beans)-1,column:e.column}});return}if(e.rowIndex!==r.rowIndex||e.rowPinned!=r.rowPinned){t.setFocusedCell({...r,preventScrollOnBrowserFocus:!0,forceBrowserFocus:!0});return}t.doesRowOrCellHaveBrowserFocus()||this.updateCellFocus(pe(this.gos,{...r,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0,type:"cellFocused"}))}findPositionToFocus(e){const{pagination:t,pageBounds:r}=this.beans;let n=e;for(n.rowPinned==null&&t&&r&&!t.isRowInPage(n.rowIndex)&&(n={rowPinned:null,rowIndex:r.getFirstRow()});n;){if(n.rowPinned==null&&r)if(n.rowIndex<r.getFirstRow()){if(n=Gl(this.beans,{rowPinned:null,rowIndex:0}),!n)return null}else n.rowIndex>r.getLastRow()&&(n={rowPinned:null,rowIndex:r.getLastRow()});const i=this.getRowByPosition(n);if(i!=null&&i.isAlive())return{...i.getRowPosition(),column:e.column};n=Gl(this.beans,n)}return null}getAllCellCtrls(){const e=[],t=this.getAllRowCtrls(),r=t.length;for(let n=0;n<r;n++){const i=t[n].getAllCellCtrls(),o=i.length;for(let s=0;s<o;s++)e.push(i[s])}return e}getAllRowCtrls(){const{spannedRowRenderer:e}=this.beans,t=this.getStickyTopRowCtrls(),r=this.getStickyBottomRowCtrls();return[...this.topRowCtrls,...this.bottomRowCtrls,...t,...r,...(e==null?void 0:e.getCtrls("top"))??[],...(e==null?void 0:e.getCtrls("bottom"))??[],...(e==null?void 0:e.getCtrls("center"))??[],...Object.values(this.rowCtrlsByRowIndex)]}addRenderedRowListener(e,t,r){const n=this.rowCtrlsByRowIndex[t];n&&n.addEventListener(e,r)}refreshCells(e={}){const t={forceRefresh:e.force,newData:!1,suppressFlash:e.suppressFlash};for(const r of this.getCellCtrls(e.rowNodes,e.columns))r.refreshOrDestroyCell(t);this.refreshFullWidth(e.rowNodes)}refreshFullWidth(e){if(!e)return;let t=!1;for(const r of this.getRowCtrls(e)){if(!r.isFullWidth())continue;r.refreshFullWidth()||(t=!0,this.redrawRow(r.rowNode,!0))}t&&this.dispatchDisplayedRowsChanged(!1)}getRowCtrls(e){const t=dy(e),r=this.getAllRowCtrls();return!e||!t?r:r.filter(n=>{const i=n.rowNode;return hy(i,t)})}getCellCtrls(e,t){let r;ie(t)&&(r={},t.forEach(i=>{const o=this.colModel.getCol(i);ie(o)&&(r[o.getId()]=!0)}));const n=[];return this.getRowCtrls(e).forEach(i=>{i.getAllCellCtrls().forEach(o=>{const s=o.column.getId();r&&!r[s]||n.push(o)})}),n}destroy(){this.removeAllRowComps(!0),super.destroy()}removeAllRowComps(e=!1){var r;const t=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(t,e),(r=this.stickyRowFeature)==null||r.destroyStickyCtrls()}getRowsToRecycle(){const e=[];for(const r of Object.keys(this.rowCtrlsByRowIndex))this.rowCtrlsByRowIndex[r].rowNode.id==null&&e.push(r);this.removeRowCtrls(e);const t={};for(const r of Object.values(this.rowCtrlsByRowIndex)){const n=r.rowNode;t[n.id]=r}return this.rowCtrlsByRowIndex={},t}removeRowCtrls(e,t=!1){e.forEach(r=>{const n=this.rowCtrlsByRowIndex[r];n&&(n.destroyFirstPass(t),n.destroySecondPass()),delete this.rowCtrlsByRowIndex[r]})}onBodyScroll(e){e.direction==="vertical"&&this.redraw({afterScroll:!0})}redraw(e={}){const{focusSvc:t,animationFrameSvc:r}=this.beans,{afterScroll:n}=e;let i;const o=this.stickyRowFeature;o&&(i=(t==null?void 0:t.getFocusCellToUseAfterRefresh())||void 0);const s=this.firstRenderedRow,a=this.lastRenderedRow;this.workOutFirstAndLastRowsToRender();let l=!1;if(o){l=o.checkStickyRows();const u=o.extraTopHeight+o.extraBottomHeight;u&&this.updateContainerHeights(u)}const c=this.firstRenderedRow!==s||this.lastRenderedRow!==a;if(!(n&&!l&&!c)&&(this.getLockOnRefresh(),this.recycleRows(null,!1,n),this.releaseLockOnRefresh(),this.dispatchDisplayedRowsChanged(n&&!l),i!=null)){const u=t==null?void 0:t.getFocusCellToUseAfterRefresh();i!=null&&u==null&&(r==null||r.flushAllFrames(),this.restoreFocusedCell(i))}}removeRowCompsNotToDraw(e,t){const r={};e.forEach(o=>r[o]=!0);const i=Object.keys(this.rowCtrlsByRowIndex).filter(o=>!r[o]);this.removeRowCtrls(i,t)}calculateIndexesToDraw(e){var s,a;const t=[];for(let l=this.firstRenderedRow;l<=this.lastRenderedRow;l++)t.push(l);const r=this.beans.pagination,n=(a=(s=this.beans.focusSvc)==null?void 0:s.getFocusedCell())==null?void 0:a.rowIndex;n!=null&&(n<this.firstRenderedRow||n>this.lastRenderedRow)&&(!r||r.isRowInPage(n))&&n<this.rowModel.getRowCount()&&t.push(n);const i=l=>{const c=l.rowNode.rowIndex;c==null||c===n||(c<this.firstRenderedRow||c>this.lastRenderedRow)&&this.doNotUnVirtualiseRow(l)&&t.push(c)};for(const l of Object.values(this.rowCtrlsByRowIndex))i(l);if(e)for(const l of Object.values(e))i(l);t.sort((l,c)=>l-c);const o=[];for(let l=0;l<t.length;l++){const c=t[l],u=this.rowModel.getRow(c);u&&!u.sticky&&o.push(c)}return o}recycleRows(e,t=!1,r=!1){const n=this.calculateIndexesToDraw(e);if((this.printLayout||r)&&(t=!1),this.removeRowCompsNotToDraw(n,!t),n.forEach(i=>{this.createOrUpdateRowCtrl(i,e,t,r)}),e){const{animationFrameSvc:i}=this.beans;(i==null?void 0:i.active)&&r&&!this.printLayout?i.addDestroyTask(()=>{this.destroyRowCtrls(e,t),this.updateAllRowCtrls(),this.dispatchDisplayedRowsChanged()}):this.destroyRowCtrls(e,t)}this.updateAllRowCtrls()}dispatchDisplayedRowsChanged(e=!1){this.eventSvc.dispatchEvent({type:"displayedRowsChanged",afterScroll:e})}onDisplayedColumnsChanged(){const{visibleCols:e}=this.beans,t=e.isPinningLeft(),r=e.isPinningRight();(this.pinningLeft!==t||r!==this.pinningRight)&&(this.pinningLeft=t,this.pinningRight=r,this.embedFullWidthRows&&this.redrawFullWidthEmbeddedRows())}redrawFullWidthEmbeddedRows(){const e=[];this.getFullWidthRowCtrls().forEach(t=>{const r=t.rowNode.rowIndex;e.push(r.toString())}),this.refreshFloatingRowComps(),this.removeRowCtrls(e),this.redraw({afterScroll:!0})}getFullWidthRowCtrls(e){const t=dy(e);return this.getAllRowCtrls().filter(r=>{if(!r.isFullWidth())return!1;const n=r.rowNode;return!(t!=null&&!hy(n,t))})}createOrUpdateRowCtrl(e,t,r,n){let i,o=this.rowCtrlsByRowIndex[e];if(o||(i=this.rowModel.getRow(e),ie(i)&&ie(t)&&t[i.id]&&i.alreadyRendered&&(o=t[i.id],t[i.id]=null)),!o)if(i||(i=this.rowModel.getRow(e)),ie(i))o=this.createRowCon(i,r,n);else return;return i&&(i.alreadyRendered=!0),this.rowCtrlsByRowIndex[e]=o,o}destroyRowCtrls(e,t){const r=[];if(e){for(const n of Object.values(e))if(n){if(this.cachedRowCtrls&&n.isCacheable()){this.cachedRowCtrls.addRow(n);continue}if(n.destroyFirstPass(!t),t){const i=n.instanceId;this.zombieRowCtrls[i]=n,r.push(()=>{n.destroySecondPass(),delete this.zombieRowCtrls[i]})}else n.destroySecondPass()}}t&&(r.push(()=>{this.updateAllRowCtrls(),this.dispatchDisplayedRowsChanged()}),window.setTimeout(()=>r.forEach(n=>n()),HN))}getRowBuffer(){return this.gos.get("rowBuffer")}getRowBufferInPixels(){const e=this.getRowBuffer(),t=as(this.beans);return e*t}workOutFirstAndLastRowsToRender(){const{rowContainerHeight:e,pageBounds:t,rowModel:r}=this;e.updateOffset();let n,i;if(!r.isRowsToRender())n=0,i=-1;else if(this.printLayout)this.beans.environment.refreshRowHeightVariable(),n=t.getFirstRow(),i=t.getLastRow();else{const u=this.getRowBufferInPixels(),d=this.ctrlsSvc.getScrollFeature(),h=this.gos.get("suppressRowVirtualisation");let f=!1,g,m;do{const x=t.getPixelOffset(),{pageFirstPixel:C,pageLastPixel:S}=t.getCurrentPagePixelRange(),A=e.divStretchOffset,P=d.getVScrollPosition(),E=P.top,O=P.bottom;h?(g=C+A,m=S+A):(g=Math.max(E+x-u,C)+A,m=Math.min(O+x+u,S)+A),this.firstVisibleVPixel=Math.max(E+x,C)+A,this.lastVisibleVPixel=Math.min(O+x,S)+A,f=this.ensureAllRowsInRangeHaveHeightsCalculated(g,m)}while(f);let p=r.getRowIndexAtPixel(g),y=r.getRowIndexAtPixel(m);const w=t.getFirstRow(),b=t.getLastRow();p<w&&(p=w),y>b&&(y=b),n=p,i=y}const o=pt(this.gos,"normal"),s=this.gos.get("suppressMaxRenderedRowRestriction"),a=Math.max(this.getRowBuffer(),500);o&&!s&&i-n>a&&(i=n+a);const l=n!==this.firstRenderedRow,c=i!==this.lastRenderedRow;(l||c)&&(this.firstRenderedRow=n,this.lastRenderedRow=i,this.eventSvc.dispatchEvent({type:"viewportChanged",firstRow:n,lastRow:i}))}dispatchFirstDataRenderedEvent(){this.dataFirstRenderedFired||(this.dataFirstRenderedFired=!0,Ur(this.beans,()=>{this.beans.eventSvc.dispatchEvent({type:"firstDataRendered",firstRow:this.firstRenderedRow,lastRow:this.lastRenderedRow})}))}ensureAllRowsInRangeHaveHeightsCalculated(e,t){var a,l;const r=(a=this.pinnedRowModel)==null?void 0:a.ensureRowHeightsValid(),n=(l=this.stickyRowFeature)==null?void 0:l.ensureRowHeightsValid(),{pageBounds:i,rowModel:o}=this,s=o.ensureRowHeightsValid(e,t,i.getFirstRow(),i.getLastRow());return(s||n)&&this.eventSvc.dispatchEvent({type:"recalculateRowBounds"}),n||s||r?(this.updateContainerHeights(),!0):!1}doNotUnVirtualiseRow(e){const n=e.rowNode,i=this.focusSvc.isRowFocused(n.rowIndex,n.rowPinned),o=e.editing,s=n.detail;return i||o||s?!!this.isRowPresent(n):!1}isRowPresent(e){var t;return this.rowModel.isRowPresent(e)?((t=this.beans.pagination)==null?void 0:t.isRowInPage(e.rowIndex))??!0:!1}createRowCon(e,t,r){var s,a;const n=((s=this.cachedRowCtrls)==null?void 0:s.getRow(e))??null;if(n)return n;const i=r&&!this.printLayout&&!!((a=this.beans.animationFrameSvc)!=null&&a.active);return new Nh(e,this.beans,t,i,this.printLayout)}getRenderedNodes(){const e=Object.values(this.rowCtrlsByRowIndex).map(n=>n.rowNode),t=this.getStickyTopRowCtrls().map(n=>n.rowNode),r=this.getStickyBottomRowCtrls().map(n=>n.rowNode);return[...t,...e,...r]}getRowByPosition(e){let t;const{rowIndex:r}=e;switch(e.rowPinned){case"top":t=this.topRowCtrls[r];break;case"bottom":t=this.bottomRowCtrls[r];break;default:t=this.rowCtrlsByRowIndex[r],t||(t=this.getStickyTopRowCtrls().find(n=>n.rowNode.rowIndex===r)||null,t||(t=this.getStickyBottomRowCtrls().find(n=>n.rowNode.rowIndex===r)||null));break}return t}isRangeInRenderedViewport(e,t){if(e==null||t==null)return!1;const n=e>this.lastRenderedRow;return!(t<this.firstRenderedRow)&&!n}},WN=class{constructor(e){this.entriesMap={},this.entriesList=[],this.maxCount=e}addRow(e){if(this.entriesMap[e.rowNode.id]=e,this.entriesList.push(e),e.setCached(!0),this.entriesList.length>this.maxCount){const t=this.entriesList[0];t.destroyFirstPass(),t.destroySecondPass(),this.removeFromCache(t)}}getRow(e){if(e==null||e.id==null)return null;const t=this.entriesMap[e.id];return t?(this.removeFromCache(t),t.setCached(!1),t.rowNode!=e?null:t):null}has(e){return this.entriesMap[e.id]!=null}removeRow(e){const t=e.id,r=this.entriesMap[t];delete this.entriesMap[t],Zt(this.entriesList,r)}removeFromCache(e){const t=e.rowNode.id;delete this.entriesMap[t],Zt(this.entriesList,e)}getEntries(){return this.entriesList}};function dy(e){if(!e)return;const t={top:{},bottom:{},normal:{}};return e.forEach(r=>{const n=r.id;switch(r.rowPinned){case"top":t.top[n]=r;break;case"bottom":t.bottom[n]=r;break;default:t.normal[n]=r;break}}),t}function hy(e,t){const r=e.id;switch(e.rowPinned){case"top":return t.top[r]!=null;case"bottom":return t.bottom[r]!=null;default:return t.normal[r]!=null}}var jN=class extends q{constructor(){super(...arguments),this.beanName="rowNodeSorter"}postConstruct(){const{gos:e}=this;this.isAccentedSort=e.get("accentedSort"),this.primaryColumnsSortGroups=gr(e),this.addManagedPropertyListener("accentedSort",t=>this.isAccentedSort=t.currentValue),this.addManagedPropertyListener("autoGroupColumnDef",()=>this.primaryColumnsSortGroups=gr(e))}doFullSort(e,t){const r=e.map((n,i)=>({currentPos:i,rowNode:n}));return r.sort(this.compareRowNodes.bind(this,t)),r.map(n=>n.rowNode)}compareRowNodes(e,t,r){const n=t.rowNode,i=r.rowNode;for(let o=0,s=e.length;o<s;o++){const a=e[o],l=a.sort==="desc",c=this.getValue(n,a.column),u=this.getValue(i,a.column);let d;const h=this.getComparator(a,n);if(h?d=h(c,u,n,i,l):d=Jk(c,u,this.isAccentedSort),!isNaN(d)&&d!==0)return a.sort==="asc"?d:d*-1}return t.currentPos-r.currentPos}getComparator(e,t){const r=e.column,n=r.getColDef().comparator;if(n!=null)return n;if(!r.getColDef().showRowGroup)return;const i=!t.group&&r.getColDef().field;if(!i)return;const o=this.beans.colModel.getColDefCol(i);if(o)return o.getColDef().comparator}getValue(e,t){var a,l;const{valueSvc:r,colModel:n,showRowGroupCols:i,gos:o}=this.beans;if(!this.primaryColumnsSortGroups)return r.getValue(t,e,!1);if(e.rowGroupColumn===t){if(a1(o,n.isPivotActive())){const d=(a=e.allLeafChildren)==null?void 0:a[0];return d?r.getValue(t,d,!1):void 0}const u=i==null?void 0:i.getShowRowGroupCol(t.getId());return u?(l=e.groupData)==null?void 0:l[u.getId()]:void 0}if(!(e.group&&t.getColDef().showRowGroup))return r.getValue(t,e,!1)}};function VN(e){var t;(t=e.sortSvc)==null||t.onSortChanged("api")}var _S={moduleName:"Sort",version:he,beans:[Zz,jN],apiFunctions:{onSortChanged:VN},userComponents:{agSortIndicator:Pp},icons:{sortAscending:"asc",sortDescending:"desc",sortUnSort:"none"}},UN=class extends q{constructor(){super(...arguments),this.beanName="syncSvc",this.waitingForColumns=!1}postConstruct(){this.addManagedPropertyListener("columnDefs",e=>this.setColumnDefs(e))}start(){this.beans.ctrlsSvc.whenReady(this,()=>{const e=this.gos.get("columnDefs");e?this.setColumnsAndData(e):this.waitingForColumns=!0,this.gridReady()})}setColumnsAndData(e){const{colModel:t,rowModel:r}=this.beans;t.setColumnDefs(e??[],"gridInitializing"),r.start()}gridReady(){const{eventSvc:e,gos:t}=this;e.dispatchEvent({type:"gridReady"}),Vn(t,`initialised successfully, enterprise = ${t.isModuleRegistered("EnterpriseCore")}`)}setColumnDefs(e){const t=this.gos.get("columnDefs");if(t){if(this.waitingForColumns){this.waitingForColumns=!1,this.setColumnsAndData(t);return}this.beans.colModel.setColumnDefs(t,Ri(e.source))}}},KN="paste",qN=class extends q{constructor(){super(...arguments),this.beanName="changeDetectionSvc",this.clientSideRowModel=null}postConstruct(){const{gos:e,rowModel:t}=this.beans;xt(e)&&(this.clientSideRowModel=t),this.addManagedEventListeners({cellValueChanged:this.onCellValueChanged.bind(this)})}onCellValueChanged(e){const{gos:t,rowRenderer:r}=this.beans;if(e.source===KN||t.get("suppressChangeDetection"))return;const n=e.node,i=[n],o=this.clientSideRowModel,s=o==null?void 0:o.rootNode;if(s&&!n.isRowPinned()){const a=t.get("aggregateOnlyChangedColumns"),l=new Wl(a,s);l.addParentNode(n.parent,[e.column]),o.doAggregate(l),l.forEachChangedNodeDepthFirst(c=>{i.push(c),c.sibling&&i.push(c.sibling)})}r.refreshCells({rowNodes:i})}},YN=class extends q{constructor(){super(...arguments),this.beanName="expressionSvc",this.cache={}}evaluate(e,t){if(typeof e=="string")return this.evaluateExpression(e,t);_e(15,{expression:e})}evaluateExpression(e,t){try{return this.createExpressionFunction(e)(t.value,t.context,t.oldValue,t.newValue,t.value,t.node,t.data,t.colDef,t.rowIndex,t.api,t.getValue,t.column,t.columnGroup)}catch(r){return _e(16,{expression:e,params:t,e:r}),null}}createExpressionFunction(e){const t=this.cache;if(t[e])return t[e];const r=this.createFunctionBody(e),n=new Function("x, ctx, oldValue, newValue, value, node, data, colDef, rowIndex, api, getValue, column, columnGroup",r);return t[e]=n,n}createFunctionBody(e){return e.indexOf("return")>=0?e:"return "+e+";"}},JN={moduleName:"Expression",version:he,beans:[YN]},XN={moduleName:"ChangeDetection",version:he,beans:[qN]},ZN=class extends q{constructor(){super(...arguments),this.beanName="valueSvc",this.initialised=!1,this.isSsrm=!1}wireBeans(e){this.expressionSvc=e.expressionSvc,this.colModel=e.colModel,this.valueCache=e.valueCache,this.dataTypeSvc=e.dataTypeSvc}postConstruct(){this.initialised||this.init()}init(){this.executeValueGetter=this.valueCache?this.executeValueGetterWithValueCache.bind(this):this.executeValueGetterWithoutValueCache.bind(this),this.isSsrm=po(this.gos),this.cellExpressions=this.gos.get("enableCellExpressions"),this.isTreeData=this.gos.get("treeData"),this.initialised=!0;const e=t=>this.callColumnCellValueChangedHandler(t);this.eventSvc.addEventListener("cellValueChanged",e,!0),this.addDestroyFunc(()=>this.eventSvc.removeEventListener("cellValueChanged",e,!0)),this.addManagedPropertyListener("treeData",t=>this.isTreeData=t.currentValue)}getValueForDisplay(e,t,r=!1,n=!1){const{showRowGroupColValueSvc:i}=this.beans,o=!e&&t.group,s=e==null?void 0:e.colDef.showRowGroup,a=!this.isTreeData||t.footer;if(i&&a&&(o||s)){const g=i.getGroupValue(t,e);if(g==null)return{value:null,valueFormatted:null};if(!r)return{value:g.value,valueFormatted:null};const m=i.formatAndPrefixGroupColValue(g,e,n);return{value:g.value,valueFormatted:m}}if(!e)return{value:t.key,valueFormatted:null};const l=t.leafGroup&&this.colModel.isPivotMode(),c=t.group&&t.expanded&&!t.footer&&!l,u=this.gos.get("groupSuppressBlankHeader")||!t.sibling,d=c&&!u,h=this.getValue(e,t,d),f=r&&!(n&&e.colDef.useValueFormatterForExport===!1);return{value:h,valueFormatted:f?this.formatValue(e,t,h):null}}getValue(e,t,r=!1){var g;if(this.initialised||this.init(),!t)return;const n=e.getColDef(),i=n.field,o=e.getColId(),s=t.data;let a;const l=n.showRowGroup;if(typeof l=="string"&&(((g=this.beans.rowGroupColsSvc)==null?void 0:g.getColumnIndex(l))??-1)>t.level)return null;const c=typeof l!="string"||!t.group,u=t.groupData&&o in t.groupData,d=!r&&t.aggData&&t.aggData[o]!==void 0,h=this.isSsrm&&r&&!!e.getColDef().aggFunc,f=this.isSsrm&&t.footer&&t.field&&(e.getColDef().showRowGroup===!0||e.getColDef().showRowGroup===t.field);if(this.isTreeData&&d)a=t.aggData[o];else if(this.isTreeData&&n.valueGetter)a=this.executeValueGetter(n.valueGetter,s,e,t);else if(this.isTreeData&&i&&s)a=ls(s,i,e.isFieldContainsDots());else if(u)a=t.groupData[o];else if(d)a=t.aggData[o];else if(n.valueGetter){if(!c)return a;a=this.executeValueGetter(n.valueGetter,s,e,t)}else if(f)a=ls(s,t.field,e.isFieldContainsDots());else if(i&&s&&!h){if(!c)return a;a=ls(s,i,e.isFieldContainsDots())}if(this.cellExpressions&&typeof a=="string"&&a.indexOf("=")===0){const m=a.substring(1);a=this.executeValueGetter(m,s,e,t)}return a}parseValue(e,t,r,n){var s;const i=e.getColDef(),o=i.valueParser;if(ie(o)){const a=pe(this.gos,{node:t,data:t==null?void 0:t.data,oldValue:n,newValue:r,colDef:i,column:e});return typeof o=="function"?o(a):(s=this.expressionSvc)==null?void 0:s.evaluate(o,a)}return r}getDeleteValue(e,t){return ie(e.getColDef().valueParser)?this.parseValue(e,t,"",this.getValueForDisplay(e,t).value)??null:null}formatValue(e,t,r,n,i=!0){let o=null,s;const a=e.getColDef();if(n?s=n:i&&(s=a.valueFormatter),s){const l=pe(this.gos,{value:r,node:t,data:t?t.data:null,colDef:a,column:e});typeof s=="function"?o=s(l):o=this.expressionSvc?this.expressionSvc.evaluate(s,l):null}else if(a.refData)return a.refData[r]||"";return o==null&&Array.isArray(r)&&(o=r.join(", ")),o}setValue(e,t,r,n){var u,d;const i=this.colModel.getColDefCol(t);if(!e||!i)return!1;Xe(e.data)&&(e.data={});const{field:o,valueSetter:s}=i.getColDef();if(Xe(o)&&Xe(s))return Q(17),!1;if(this.dataTypeSvc&&!this.dataTypeSvc.checkType(i,r))return Q(135),!1;const a=pe(this.gos,{node:e,data:e.data,oldValue:this.getValue(i,e),newValue:r,colDef:i.getColDef(),column:i});a.newValue=r;let l;if(ie(s)?typeof s=="function"?l=s(a):l=(u=this.expressionSvc)==null?void 0:u.evaluate(s,a):l=this.setValueUsingField(e.data,o,r,i.isFieldContainsDots()),l===void 0&&(l=!0),!l)return!1;e.resetQuickFilterAggregateText(),(d=this.valueCache)==null||d.onDataChanged();const c=this.getValue(i,e);return this.eventSvc.dispatchEvent({type:"cellValueChanged",event:null,rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:a.column,colDef:a.colDef,data:e.data,node:e,oldValue:a.oldValue,newValue:c,value:c,source:n}),!0}callColumnCellValueChangedHandler(e){const t=e.colDef.onCellValueChanged;typeof t=="function"&&this.beans.frameworkOverrides.wrapOutgoing(()=>{t({node:e.node,data:e.data,oldValue:e.oldValue,newValue:e.newValue,colDef:e.colDef,column:e.column,api:e.api,context:e.context})})}setValueUsingField(e,t,r,n){if(!t)return!1;let i=!1;if(!n)i=e[t]===r,i||(e[t]=r);else{const o=t.split(".");let s=e;for(;o.length>0&&s;){const a=o.shift();o.length===0?(i=s[a]===r,i||(s[a]=r)):s=s[a]}}return!i}executeValueGetterWithValueCache(e,t,r,n){const i=r.getColId(),o=this.valueCache.getValue(n,i);if(o!==void 0)return o;const s=this.executeValueGetterWithoutValueCache(e,t,r,n);return this.valueCache.setValue(n,i,s),s}executeValueGetterWithoutValueCache(e,t,r,n){var s;const i=pe(this.gos,{data:t,node:n,column:r,colDef:r.getColDef(),getValue:this.getValueCallback.bind(this,n)});let o;return typeof e=="function"?o=e(i):o=(s=this.expressionSvc)==null?void 0:s.evaluate(e,i),o}getValueCallback(e,t){const r=this.colModel.getColDefCol(t);return r?this.getValue(r,e):null}getKeyForNode(e,t){const r=this.getValue(e,t),n=e.getColDef().keyCreator;let i=r;if(n){const o=pe(this.gos,{value:r,colDef:e.getColDef(),column:e,node:t,data:t.data});i=n(o)}return typeof i=="string"||i==null||(i=String(i),i==="[object Object]"&&Q(121)),i}},QN={moduleName:"CommunityCore",version:he,beans:[Uz,yB,M8,n_,$N,p8,$z,nN,QI,PN,AN,GN,ZN,jz,Nz,Vz,k8,UN,R8,E8],icons:{selectOpen:"small-down",smallDown:"small-down",colorPicker:"color-picker",smallUp:"small-up",checkboxChecked:"small-up",checkboxIndeterminate:"checkbox-indeterminate",checkboxUnchecked:"checkbox-unchecked",radioButtonOn:"radio-button-on",radioButtonOff:"radio-button-off",smallLeft:"small-left",smallRight:"small-right"},apiFunctions:{getGridId:bB,destroy:CB,isDestroyed:wB,getGridOption:SB,setGridOption:xB,updateGridOptions:lS,isModuleRegistered:AB},dependsOn:[x8,KB,e8,_S,cN,v8,uN,NN,XN,hN,xN,FN,MN,gN,O8,A8,JN]},e$=()=>`No AG Grid modules are registered! It is recommended to start with all Community features via the AllCommunityModule:
19
+
20
+ import { ModuleRegistry, AllCommunityModule } from 'ag-grid-community';
21
+
22
+ ModuleRegistry.registerModules([ AllCommunityModule ]);
23
+ `;function t$({moduleName:e,rowModelType:t}){return`To use the ${e}Module you must set the gridOption "rowModelType='${t}'"`}var Rp=class Sn{static applyGlobalGridOptions(t){if(!Sn.gridOptions)return{...t};let r={};return Et(r,Sn.gridOptions,!0,!0),Sn.mergeStrategy==="deep"?Et(r,t,!0,!0):r={...r,...t},Sn.gridOptions.context&&(r.context=Sn.gridOptions.context),t.context&&(Sn.mergeStrategy==="deep"&&r.context&&Et(t.context,r.context,!0,!0),r.context=t.context),r}};Rp.gridOptions=void 0;Rp.mergeStrategy="shallow";var LS=Rp;function r$(e){var t;return(t=LS.gridOptions)==null?void 0:t[e]}var n$=1,i$=class{create(e,t,r,n,i,o){const s=LS.applyGlobalGridOptions(t),a=s.gridId??String(n$++),l=this.getRegisteredModules(i,a,s.rowModelType),c=this.createBeansList(s.rowModelType,l,a),u=this.createProvidedBeans(e,s,i);if(!c)return;const d={providedBeanInstances:u,beanClasses:c,gridId:a,beanInitComparator:gB,beanDestroyComparator:pB,derivedBeans:[hB],destroyCallback:o},h=new K_(d);return this.registerModuleFeatures(h,l),r(h),h.getBean("syncSvc").start(),n&&n(h),h.getBean("gridApi")}getRegisteredModules(e,t,r){var n;return Fs(QN,void 0,!0),(n=e==null?void 0:e.modules)==null||n.forEach(i=>Fs(i,t)),$_(t,fy(r))}registerModuleFeatures(e,t){const r=e.getBean("registry"),n=e.getBean("apiFunctionSvc");t.forEach(i=>{r.registerModule(i);const o=i.apiFunctions;o&&Object.keys(o).forEach(a=>{n==null||n.addFunction(a,o[a])})})}createProvidedBeans(e,t,r){let n=r?r.frameworkOverrides:null;Xe(n)&&(n=new sS);const i={gridOptions:t,eGridDiv:e,globalListener:r?r.globalListener:null,globalSyncListener:r?r.globalSyncListener:null,frameworkOverrides:n};return r&&r.providedBeanInstances&&Object.assign(i,r.providedBeanInstances),i}createBeansList(e,t,r){const n={clientSide:"ClientSideRowModel",infinite:"InfiniteRowModel",serverSide:"ServerSideRowModel",viewport:"ViewportRowModel"},i=fy(e),o=n[i];if(!o){Zo(201,{rowModelType:i},`Unknown rowModelType ${i}.`);return}if(!W_()){Zo(272,void 0,e$());return}if(!e){const a=Object.entries(n).filter(([l,c])=>Lh(c,r,l));if(a.length==1){const[l,c]=a[0];if(l!==i){const u={moduleName:c,rowModelType:l};Zo(275,u,t$(u));return}}}if(!Lh(o,r,i)){Zo(200,{reasonOrId:`rowModelType = '${i}'`,moduleName:o,gridScoped:O1(),gridId:r,rowModelType:i},`Missing module ${o}Module for rowModelType ${i}.`);return}const s=new Set;return t.forEach(a=>{var l;return(l=a.beans)==null?void 0:l.forEach(c=>s.add(c))}),Array.from(s)}};function fy(e){return e??"clientSide"}function fu(e){const t=e.rowModel;return t.getType()==="infinite"?t:void 0}function o$(e){const t=e.rowModel;return t.getType()==="serverSide"?t:void 0}var s$=class{wrap(e,t,r,n){const i=this.createWrapper(e,n);return t==null||t.forEach(o=>{this.createMethod(i,o,!0)}),r==null||r.forEach(o=>{this.createMethod(i,o,!1)}),i}createMethod(e,t,r){e.addMethod(t,this.createMethodProxy(e,t,r))}createMethodProxy(e,t,r){return function(){return e.hasMethod(t)?e.callMethod(t,arguments):(r&&Q(49,{methodName:t}),null)}}},a$={tag:"div",cls:"ag-tooltip"},l$=class extends dB{constructor(){super(a$)}init(e){const{value:t}=e;this.getGui().textContent=Sa(t)}};function BS(e){e.sibling&&(e.sibling.childrenAfterFilter=e.childrenAfterFilter)}var c$=class extends q{constructor(){super(...arguments),this.beanName="filterStage",this.refreshProps=new Set(["excludeChildrenWhenTreeDataFiltering"]),this.step="filter"}wireBeans(e){this.filterManager=e.filterManager}execute(e){const{changedPath:t}=e;this.filter(t)}filter(e){var r;const t=!!((r=this.filterManager)!=null&&r.isChildFilterPresent());this.filterNodes(t,e)}filterNodes(e,t){const r=(n,i)=>{n.hasChildren()&&e&&!i?n.childrenAfterFilter=n.childrenAfterGroup.filter(o=>{const s=o.childrenAfterFilter&&o.childrenAfterFilter.length>0,a=o.data&&this.filterManager.doesRowPassFilter({rowNode:o});return s||a}):n.childrenAfterFilter=n.childrenAfterGroup,BS(n)};if(this.doingTreeDataFiltering()){const n=(o,s)=>{if(o.childrenAfterGroup)for(let a=0;a<o.childrenAfterGroup.length;a++){const l=o.childrenAfterGroup[a],c=s||this.filterManager.doesRowPassFilter({rowNode:l});l.childrenAfterGroup?n(o.childrenAfterGroup[a],c):r(l,c)}r(o,s)},i=o=>n(o,!1);t.executeFromRootNode(i)}else{const n=i=>r(i,!1);t.forEachChangedNodeDepthFirst(n,!0)}}doingTreeDataFiltering(){return this.gos.get("treeData")&&!this.gos.get("excludeChildrenWhenTreeDataFiltering")}},u$=class extends bp{constructor(){super(...arguments),this.iconCreated=!1}setComp(e,t,r,n,i){this.comp=e;const o=Aa(this,this.beans.context,i);this.eButtonShowMainFilter=r,this.eFloatingFilterBody=n,this.setGui(t,o),this.setupActive(),this.refreshHeaderStyles(),this.setupWidth(o),this.setupLeft(o),this.setupHover(o),this.setupFocus(o),this.setupAria(),this.setupFilterButton(),this.setupUserComp(),this.setupSyncWithFilter(o),this.setupUi(),o.addManagedElementListeners(this.eButtonShowMainFilter,{click:this.showParentFilter.bind(this)}),this.setupFilterChangedListener(o),o.addManagedListeners(this.column,{colDefChanged:()=>this.onColDefChanged(o)}),o.addDestroyFunc(()=>{this.eButtonShowMainFilter=null,this.eFloatingFilterBody=null,this.userCompDetails=null,this.clearComponent()})}resizeHeader(){}moveHeader(){}getHeaderClassParams(){const{column:e,beans:t}=this,r=e.colDef;return pe(t.gos,{colDef:r,column:e,floatingFilter:!0})}setupActive(){const e=this.column.getColDef(),t=!!e.filter,r=!!e.floatingFilter;this.active=t&&r}setupUi(){if(this.comp.setButtonWrapperDisplayed(!this.suppressFilterButton&&this.active),this.comp.addOrRemoveBodyCssClass("ag-floating-filter-full-body",this.suppressFilterButton),this.comp.addOrRemoveBodyCssClass("ag-floating-filter-body",!this.suppressFilterButton),!this.active||this.iconCreated)return;const e=Co("filter",this.beans,this.column);e&&(this.iconCreated=!0,this.eButtonShowMainFilter.appendChild(e))}setupFocus(e){e.createManagedBean(new bo(this.eGui,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)}))}setupAria(){const e=this.getLocaleTextFunc();lu(this.eButtonShowMainFilter,e("ariaFilterMenuOpen","Open Filter Menu"))}onTabKeyDown(e){var s;const{beans:t}=this;if(Ke(t)===this.eGui)return;const i=yo(t,this.eGui,null,e.shiftKey);if(i){(s=t.headerNavigation)==null||s.scrollToColumn(this.column),e.preventDefault(),i.focus();return}const o=this.findNextColumnWithFloatingFilter(e.shiftKey);o&&t.focusSvc.focusHeaderPosition({headerPosition:{headerRowIndex:this.rowCtrl.rowIndex,column:o},event:e})&&e.preventDefault()}findNextColumnWithFloatingFilter(e){const t=this.beans.visibleCols;let r=this.column;do if(r=e?t.getColBefore(r):t.getColAfter(r),!r)break;while(!r.getColDef().filter||!r.getColDef().floatingFilter);return r}handleKeyDown(e){super.handleKeyDown(e);const t=this.getWrapperHasFocus();switch(e.key){case j.UP:case j.DOWN:case j.LEFT:case j.RIGHT:if(t)return;Kn(e);case j.ENTER:t&&qn(this.eGui)&&e.preventDefault();break;case j.ESCAPE:t||this.eGui.focus()}}onFocusIn(e){if(this.eGui.contains(e.relatedTarget))return;const r=!!e.relatedTarget&&!e.relatedTarget.classList.contains("ag-floating-filter"),n=!!e.relatedTarget&&kn(e.relatedTarget,"ag-floating-filter");if(r&&n&&e.target===this.eGui){const i=this.lastFocusEvent,o=!!(i&&i.key===j.TAB);if(i&&o){const s=i.shiftKey;qn(this.eGui,s)}}this.focusThis()}setupHover(e){var t;(t=this.beans.colHover)==null||t.addHeaderFilterColumnHoverListener(e,this.comp,this.column,this.eGui)}setupLeft(e){const t=new yp(this.column,this.eGui,this.beans);e.createManagedBean(t)}setupFilterButton(){var e;this.suppressFilterButton=!((e=this.beans.menuSvc)!=null&&e.isFloatingFilterButtonEnabled(this.column)),this.highlightFilterButtonWhenActive=!Bt(this.gos)}setupUserComp(){var t;if(!this.active)return;const e=(t=this.beans.filterManager)==null?void 0:t.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter());e&&this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setCompDetails(e)}showParentFilter(){var t;const e=this.suppressFilterButton?this.eFloatingFilterBody:this.eButtonShowMainFilter;(t=this.beans.menuSvc)==null||t.showFilterMenu({column:this.column,buttonElement:e,containerType:"floatingFilter",positionBy:"button"})}setupSyncWithFilter(e){if(!this.active)return;const{filterManager:t}=this.beans,r=n=>{if((n==null?void 0:n.source)==="filterDestroyed"&&!this.isAlive())return;const i=this.comp.getFloatingFilterComp();i&&i.then(o=>{if(o){const s=t==null?void 0:t.getCurrentFloatingFilterParentModel(this.column),a=n?{...n,columns:n.columns??[],source:n.source==="api"?"api":"columnFilter"}:null;o.onParentModelChanged(s,a)}})};[this.destroySyncListener]=e.addManagedListeners(this.column,{filterChanged:r}),t!=null&&t.isFilterActive(this.column)&&r(null)}setupWidth(e){const t=()=>{const r=`${this.column.getActualWidth()}px`;this.comp.setWidth(r)};e.addManagedListeners(this.column,{widthChanged:t}),t()}setupFilterChangedListener(e){this.active&&([this.destroyFilterChangedListener]=e.addManagedListeners(this.column,{filterChanged:this.updateFilterButton.bind(this)}),this.updateFilterButton())}updateFilterButton(){var e;if(!this.suppressFilterButton&&this.comp){const t=!!((e=this.beans.filterManager)!=null&&e.isFilterAllowed(this.column));this.comp.setButtonWrapperDisplayed(t),this.highlightFilterButtonWhenActive&&t&&this.eButtonShowMainFilter.classList.toggle("ag-filter-active",this.column.isFilterActive())}}onColDefChanged(e){var o;const t=this.active;this.setupActive();const r=!t&&this.active;t&&!this.active&&(this.destroySyncListener(),this.destroyFilterChangedListener());const n=this.active?(o=this.beans.filterManager)==null?void 0:o.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter()):null,i=this.comp.getFloatingFilterComp();!i||!n?this.updateCompDetails(e,n,r):i.then(s=>{var a;!s||(a=this.beans.filterManager)!=null&&a.areFilterCompsDifferent(this.userCompDetails??null,n)?this.updateCompDetails(e,n,r):this.updateFloatingFilterParams(n)})}updateCompDetails(e,t,r){this.isAlive()&&(this.setCompDetails(t),this.setupFilterButton(),this.setupUi(),r&&(this.setupSyncWithFilter(e),this.setupFilterChangedListener(e)))}updateFloatingFilterParams(e){var r;if(!e)return;const t=e.params;(r=this.comp.getFloatingFilterComp())==null||r.then(n=>{n!=null&&n.refresh&&typeof n.refresh=="function"&&n.refresh(t)})}addResizeAndMoveKeyboardListeners(){}destroy(){super.destroy(),this.destroySyncListener=null,this.destroyFilterChangedListener=null}};function d$(e,t){var n;const r=e.colModel.getCol(t);if(!r){_e(12,{colKey:t});return}(n=e.menuSvc)==null||n.showColumnMenu({column:r,positionBy:"auto"})}function h$(e){var t;(t=e.menuSvc)==null||t.hidePopupMenu()}var f$={moduleName:"SharedMenu",version:he,beans:[S3],apiFunctions:{showColumnMenu:d$,hidePopupMenu:h$}},g$=0,p$=200,m$=class extends q{constructor(){super(...arguments),this.beanName="popupSvc",this.popupList=[]}postConstruct(){this.beans.ctrlsSvc.whenReady(this,e=>{this.gridCtrl=e.gridCtrl}),this.addManagedEventListeners({gridStylesChanged:this.handleThemeChange.bind(this)})}getPopupParent(){const e=this.gos.get("popupParent");return e||this.gridCtrl.getGui()}positionPopupForMenu(e){const{eventSource:t,ePopup:r,column:n,node:i,event:o}=e,s=t.getBoundingClientRect(),a=this.getParentRect();this.setAlignedTo(t,r);let l=!1;const c=()=>{const u=this.keepXYWithinBounds(r,s.top-a.top,0),d=r.clientWidth>0?r.clientWidth:200;l||(r.style.minWidth=`${d}px`,l=!0);const f=a.right-a.left-d;let g;return this.gos.get("enableRtl")?(g=p(),g<0&&(g=m(),this.setAlignedStyles(r,"left")),g>f&&(g=0,this.setAlignedStyles(r,"right"))):(g=m(),g>f&&(g=p(),this.setAlignedStyles(r,"right")),g<0&&(g=0,this.setAlignedStyles(r,"left"))),{x:g,y:u};function m(){return s.right-a.left-2}function p(){return s.left-a.left-d}};this.positionPopup({ePopup:r,keepWithinBounds:!0,updatePosition:c,postProcessCallback:()=>this.callPostProcessPopup("subMenu",r,t,o instanceof MouseEvent?o:void 0,n,i)})}positionPopupUnderMouseEvent(e){const{ePopup:t,nudgeX:r,nudgeY:n,skipObserver:i}=e;this.positionPopup({ePopup:t,nudgeX:r,nudgeY:n,keepWithinBounds:!0,skipObserver:i,updatePosition:()=>this.calculatePointerAlign(e.mouseEvent),postProcessCallback:()=>this.callPostProcessPopup(e.type,e.ePopup,null,e.mouseEvent,e.column,e.rowNode)})}calculatePointerAlign(e){const t=this.getParentRect();return{x:e.clientX-t.left,y:e.clientY-t.top}}positionPopupByComponent(e){const{ePopup:t,nudgeX:r,nudgeY:n,keepWithinBounds:i,eventSource:o,alignSide:s="left",position:a="over",column:l,rowNode:c,type:u}=e,d=o.getBoundingClientRect(),h=this.getParentRect();this.setAlignedTo(o,t);const f=()=>{let g=d.left-h.left;s==="right"&&(g-=t.offsetWidth-d.width);let m;return a==="over"?(m=d.top-h.top,this.setAlignedStyles(t,"over")):(this.setAlignedStyles(t,"under"),this.shouldRenderUnderOrAbove(t,d,h,e.nudgeY||0)==="under"?m=d.top-h.top+d.height:m=d.top-t.offsetHeight-(n||0)*2-h.top),{x:g,y:m}};this.positionPopup({ePopup:t,nudgeX:r,nudgeY:n,keepWithinBounds:i,updatePosition:f,postProcessCallback:()=>this.callPostProcessPopup(u,t,o,null,l,c)})}shouldRenderUnderOrAbove(e,t,r,n){const i=r.bottom-t.bottom,o=t.top-r.top,s=e.offsetHeight+n;return i>s?"under":o>s||o>i?"above":"under"}setAlignedStyles(e,t){const r=this.getPopupIndex(e);if(r===-1)return;const n=this.popupList[r],{alignedToElement:i}=n;!i||(["right","left","over","above","under"].forEach(s=>{i.classList.remove(`ag-has-popup-positioned-${s}`),e.classList.remove(`ag-popup-positioned-${s}`)}),!t)||(i.classList.add(`ag-has-popup-positioned-${t}`),e.classList.add(`ag-popup-positioned-${t}`))}setAlignedTo(e,t){const r=this.getPopupIndex(t);if(r!==-1){const n=this.popupList[r];n.alignedToElement=e}}callPostProcessPopup(e,t,r,n,i,o){const s=this.gos.getCallback("postProcessPopup");s&&s({column:i,rowNode:o,ePopup:t,type:e,eventSource:r,mouseEvent:n})}positionPopup(e){const{ePopup:t,keepWithinBounds:r,nudgeX:n,nudgeY:i,skipObserver:o,updatePosition:s}=e,a={width:0,height:0},l=(c=!1)=>{let{x:u,y:d}=s();c&&t.clientWidth===a.width&&t.clientHeight===a.height||(a.width=t.clientWidth,a.height=t.clientHeight,n&&(u+=n),i&&(d+=i),r&&(u=this.keepXYWithinBounds(t,u,1),d=this.keepXYWithinBounds(t,d,0)),t.style.left=`${u}px`,t.style.top=`${d}px`,e.postProcessCallback&&e.postProcessCallback())};if(l(),!o){const c=fn(this.beans,t,()=>l(!0));setTimeout(()=>c(),p$)}}getActivePopups(){return this.popupList.map(e=>e.element)}getParentRect(){const e=gt(this.beans);let t=this.getPopupParent();return t===e.body?t=e.documentElement:getComputedStyle(t).position==="static"&&(t=t.offsetParent),U2(t)}keepXYWithinBounds(e,t,r){const n=r===0,i=n?"clientHeight":"clientWidth",o=n?"top":"left",s=n?"height":"width",a=n?"scrollTop":"scrollLeft",l=gt(this.beans),c=l.documentElement,u=this.getPopupParent(),d=e.getBoundingClientRect(),h=u.getBoundingClientRect(),f=l.documentElement.getBoundingClientRect(),g=u===l.body,m=Math.ceil(d[s]);let y=g?(n?V2:Tl)(c)+c[a]:u[i];g&&(y-=Math.abs(f[o]-h[o]));const w=y-m;return Math.min(Math.max(t,0),Math.abs(w))}addPopup(e){const t=gt(this.beans),{eChild:r,ariaLabel:n,alwaysOnTop:i,positionCallback:o,anchorToElement:s}=e;if(!t)return Q(122),{hideFunc:()=>{}};const a=this.getPopupIndex(r);if(a!==-1)return{hideFunc:this.popupList[a].hideFunc};this.initialisePopupPosition(r);const l=this.createPopupWrapper(r,n,!!i),c=this.addEventListenersToPopup({...e,wrapperEl:l});return o&&o(),this.addPopupToPopupList(r,l,c,s),{hideFunc:c}}initialisePopupPosition(e){const r=this.getPopupParent().getBoundingClientRect();ie(e.style.top)||(e.style.top=`${r.top*-1}px`),ie(e.style.left)||(e.style.left=`${r.left*-1}px`)}createPopupWrapper(e,t,r){const n=this.getPopupParent(),{environment:i,gos:o}=this.beans,s=lt({tag:"div"});return i.applyThemeClasses(s),s.classList.add("ag-popup"),e.classList.add(o.get("enableRtl")?"ag-rtl":"ag-ltr","ag-popup-child"),e.hasAttribute("role")||_i(e,"dialog"),lu(e,t),s.appendChild(e),n.appendChild(s),r?this.setAlwaysOnTop(e,!0):this.bringPopupToFront(e),s}handleThemeChange(e){if(e.themeChanged){const t=this.beans.environment;for(const r of this.popupList)t.applyThemeClasses(r.wrapper)}}addEventListenersToPopup(e){const t=this.beans,r=gt(t),n=this.getPopupParent(),{wrapperEl:i,eChild:o,closedCallback:s,afterGuiAttached:a,closeOnEsc:l,modal:c}=e;let u=!1;const d=m=>{if(!i.contains(Ke(t)))return;m.key===j.ESCAPE&&!Lr(m)&&g({keyboardEvent:m})},h=m=>g({mouseEvent:m}),f=m=>g({touchEvent:m}),g=(m={})=>{const{mouseEvent:p,touchEvent:y,keyboardEvent:w,forceHide:b}=m;!b&&(this.isEventFromCurrentPopup({mouseEvent:p,touchEvent:y},o)||u)||(u=!0,n.removeChild(i),r.removeEventListener("keydown",d),r.removeEventListener("mousedown",h),r.removeEventListener("touchstart",f),r.removeEventListener("contextmenu",h),this.eventSvc.removeEventListener("dragStarted",h),s&&s(p||y||w),this.removePopupFromPopupList(o))};return a&&a({hidePopup:g}),window.setTimeout(()=>{l&&r.addEventListener("keydown",d),c&&(r.addEventListener("mousedown",h),this.eventSvc.addEventListener("dragStarted",h),r.addEventListener("touchstart",f),r.addEventListener("contextmenu",h))},0),g}addPopupToPopupList(e,t,r,n){this.popupList.push({element:e,wrapper:t,hideFunc:r,instanceId:g$++,isAnchored:!!n}),n&&this.setPopupPositionRelatedToElement(e,n)}getPopupIndex(e){return this.popupList.findIndex(t=>t.element===e)}setPopupPositionRelatedToElement(e,t){const r=this.getPopupIndex(e);if(r===-1)return;const n=this.popupList[r];if(n.stopAnchoringPromise&&n.stopAnchoringPromise.then(o=>o&&o()),n.stopAnchoringPromise=void 0,n.isAnchored=!1,!t)return;const i=this.keepPopupPositionedRelativeTo({element:t,ePopup:e,hidePopup:n.hideFunc});return n.stopAnchoringPromise=i,n.isAnchored=!0,i}removePopupFromPopupList(e){this.setAlignedStyles(e,null),this.setPopupPositionRelatedToElement(e,null),this.popupList=this.popupList.filter(t=>t.element!==e)}keepPopupPositionedRelativeTo(e){const t=this.getPopupParent(),r=t.getBoundingClientRect(),{element:n,ePopup:i}=e,o=n.getBoundingClientRect(),s=d=>parseInt(d.substring(0,d.length-1),10),a=(d,h)=>{const f=r[d]-o[d],g=s(i.style[d]);return{initialDiff:f,lastDiff:f,initial:g,last:g,direction:h}},l=a("top",0),c=a("left",1),u=this.beans.frameworkOverrides;return new Ie(d=>{u.wrapIncoming(()=>{u.setInterval(()=>{const h=t.getBoundingClientRect(),f=n.getBoundingClientRect();if(f.top==0&&f.left==0&&f.height==0&&f.width==0){e.hidePopup();return}const m=(p,y)=>{const w=s(i.style[y]);p.last!==w&&(p.initial=w,p.last=w);const b=h[y]-f[y];if(b!=p.lastDiff){const x=this.keepXYWithinBounds(i,p.initial+p.initialDiff-b,p.direction);i.style[y]=`${x}px`,p.last=x}p.lastDiff=b};m(l,"top"),m(c,"left")},200).then(h=>{d(()=>{h!=null&&window.clearInterval(h)})})},"popupPositioning")})}hasAnchoredPopup(){return this.popupList.some(e=>e.isAnchored)}isEventFromCurrentPopup(e,t){const{mouseEvent:r,touchEvent:n}=e,i=r||n;if(!i)return!1;const o=this.getPopupIndex(t);if(o===-1)return!1;for(let s=o;s<this.popupList.length;s++){const a=this.popupList[s];if(SI(a.element,i))return!0}return this.isElementWithinCustomPopup(i.target)}isElementWithinCustomPopup(e){const t=gt(this.beans);for(;e&&e!==t.body;){if(e.classList.contains("ag-custom-component-popup")||e.parentElement===null)return!0;e=e.parentElement}return!1}getWrapper(e){for(;!e.classList.contains("ag-popup")&&e.parentElement;)e=e.parentElement;return e.classList.contains("ag-popup")?e:null}setAlwaysOnTop(e,t){const r=this.getWrapper(e);r&&(r.classList.toggle("ag-always-on-top",!!t),t&&this.bringPopupToFront(r))}bringPopupToFront(e){const t=this.getPopupParent(),r=Array.prototype.slice.call(t.querySelectorAll(".ag-popup")),n=r.length,i=this.getWrapper(e);if(!i||n<=1||!t.contains(e))return;const o=[],s=[];for(const h of r)h!==i&&(h.classList.contains("ag-always-on-top")?s.push(h):o.push(h));const a=[],l=s.length,d=i.classList.contains("ag-always-on-top")||!l?[...o,...s,i]:[...o,i,...s];for(let h=0;h<=n;h++){const f=d[h];if(r[h]===d[h]||f===i)continue;f.querySelectorAll("div").forEach(m=>{m.scrollTop!==0&&a.push([m,m.scrollTop])}),h===0?t.insertAdjacentElement("afterbegin",f):d[h-1].insertAdjacentElement("afterend",f)}for(;a.length;){const h=a.pop();h[0].scrollTop=h[1]}}},zS={moduleName:"Popup",version:he,beans:[m$]},v$=".ag-set-filter{--ag-indentation-level:0}.ag-set-filter-item{align-items:center;display:flex;height:100%}:where(.ag-ltr) .ag-set-filter-item{padding-left:calc(var(--ag-widget-container-horizontal-padding) + var(--ag-indentation-level)*var(--ag-set-filter-indent-size))}:where(.ag-rtl) .ag-set-filter-item{padding-right:calc(var(--ag-widget-container-horizontal-padding) + var(--ag-indentation-level)*var(--ag-set-filter-indent-size))}.ag-set-filter-item-checkbox{display:flex;height:100%;width:100%}.ag-set-filter-group-icons{display:block;>*{cursor:pointer}}:where(.ag-ltr) .ag-set-filter-group-icons{margin-right:var(--ag-widget-container-horizontal-padding)}:where(.ag-rtl) .ag-set-filter-group-icons{margin-left:var(--ag-widget-container-horizontal-padding)}.ag-filter-body-wrapper{display:flex;flex-direction:column}:where(.ag-menu:not(.ag-tabs) .ag-filter) .ag-filter-body-wrapper,:where(.ag-menu:not(.ag-tabs) .ag-filter)>:not(.ag-filter-wrapper){min-width:180px}.ag-filter-filter{flex:1 1 0px}.ag-filter-condition{display:flex;justify-content:center}.ag-floating-filter-body{display:flex;flex:1 1 auto;height:100%;position:relative}.ag-floating-filter-full-body{align-items:center;display:flex;flex:1 1 auto;height:100%;overflow:hidden;width:100%}:where(.ag-floating-filter-full-body)>div{flex:1 1 auto}.ag-floating-filter-input{align-items:center;display:flex;width:100%;>*{flex:1 1 auto}:where(.ag-input-field-input[type=date]){width:1px}}.ag-floating-filter-button{display:flex;flex:none}.ag-date-floating-filter-wrapper{display:flex}.ag-set-floating-filter-input :where(input)[disabled]{pointer-events:none}.ag-floating-filter-button-button{-webkit-appearance:none;-moz-appearance:none;appearance:none;border:none;height:var(--ag-icon-size);width:var(--ag-icon-size)}.ag-filter-loading{align-items:unset;background-color:var(--ag-chrome-background-color);height:100%;padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding);position:absolute;width:100%;z-index:1;:where(.ag-menu) &{background-color:var(--ag-menu-background-color)}}.ag-filter-separator{border-top:1px solid var(--menu-separator-color)}:where(.ag-filter-select) .ag-picker-field-wrapper{width:0}.ag-filter-condition-operator{height:17px}:where(.ag-ltr) .ag-filter-condition-operator-or{margin-left:calc(var(--ag-spacing)*2)}:where(.ag-rtl) .ag-filter-condition-operator-or{margin-right:calc(var(--ag-spacing)*2)}.ag-set-filter-select-all{padding-top:var(--ag-widget-container-vertical-padding)}.ag-filter-no-matches,.ag-set-filter-list{height:calc(var(--ag-list-item-height)*6)}.ag-filter-no-matches{padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding)}.ag-set-filter-tree-list{height:calc(var(--ag-list-item-height)*10)}.ag-set-filter-filter{margin-left:var(--ag-widget-container-horizontal-padding);margin-right:var(--ag-widget-container-horizontal-padding);margin-top:var(--ag-widget-container-vertical-padding)}.ag-filter-to{margin-top:var(--ag-widget-vertical-spacing)}.ag-mini-filter{margin:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding)}:where(.ag-ltr) .ag-set-filter-add-group-indent{margin-left:calc(var(--ag-icon-size) + var(--ag-widget-container-horizontal-padding))}:where(.ag-rtl) .ag-set-filter-add-group-indent{margin-right:calc(var(--ag-icon-size) + var(--ag-widget-container-horizontal-padding))}:where(.ag-filter-menu) .ag-set-filter-list{min-width:200px}.ag-filter-virtual-list-item:focus-visible{box-shadow:inset var(--ag-focus-shadow)}.ag-filter-apply-panel{display:flex;justify-content:flex-end;overflow:hidden;padding:var(--ag-widget-vertical-spacing) var(--ag-widget-container-horizontal-padding) var(--ag-widget-container-vertical-padding)}.ag-filter-apply-panel-button{line-height:1.5}:where(.ag-ltr) .ag-filter-apply-panel-button{margin-left:calc(var(--ag-spacing)*2)}:where(.ag-rtl) .ag-filter-apply-panel-button{margin-right:calc(var(--ag-spacing)*2)}.ag-simple-filter-body-wrapper{display:flex;flex-direction:column;min-height:calc(var(--ag-list-item-height) + var(--ag-widget-container-vertical-padding) + var(--ag-widget-vertical-spacing));overflow-y:auto;padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding);padding-bottom:calc(var(--ag-widget-container-vertical-padding) - var(--ag-widget-vertical-spacing));&>*{margin-bottom:var(--ag-widget-vertical-spacing)}:where(.ag-resizer-wrapper){margin:0}}.ag-multi-filter-menu-item{margin:var(--ag-spacing) 0}.ag-multi-filter-group-title-bar{background-color:transparent;color:var(--ag-header-text-color);font-weight:500;padding:calc(var(--ag-spacing)*1.5) var(--ag-spacing)}.ag-group-filter-field-select-wrapper{display:flex;flex-direction:column;gap:var(--ag-widget-vertical-spacing);padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding)}";function y$(e){const t=e.filterManager;return!!(t!=null&&t.isColumnFilterPresent())||!!(t!=null&&t.isAggregateFilterPresent())}function b$(e,t){var r;return((r=e.filterManager)==null?void 0:r.getColumnFilterInstance(t))??Promise.resolve(void 0)}function C$(e,t){var n;const r=e.colModel.getColDefCol(t);if(r)return(n=e.filterManager)==null?void 0:n.destroyFilter(r,"api")}function w$(e,t){e.frameworkOverrides.wrapIncoming(()=>{var r;return(r=e.filterManager)==null?void 0:r.setFilterModel(t)})}function S$(e){var t;return((t=e.filterManager)==null?void 0:t.getFilterModel())??{}}function x$(e,t){var r;return((r=e.filterManager)==null?void 0:r.getColumnFilterModel(t))??null}function A$(e,t,r){var n;return((n=e.filterManager)==null?void 0:n.setColumnFilterModel(t,r))??Promise.resolve()}function P$(e,t){var n;const r=e.colModel.getCol(t);if(!r){_e(12,{colKey:t});return}(n=e.menuSvc)==null||n.showFilterMenu({column:r,containerType:"columnFilter",positionBy:"auto"})}var gy={january:"January",february:"February",march:"March",april:"April",may:"May",june:"June",july:"July",august:"August",september:"September",october:"October",november:"November",december:"December"},py=["january","february","march","april","may","june","july","august","september","october","november","december"];function R$(e,t){return e==null?-1:t==null?1:parseFloat(e)-parseFloat(t)}var E$=class extends q{constructor(){super(...arguments),this.beanName="colFilter",this.allColumnFilters=new Map,this.allColumnListeners=new Map,this.activeAggregateFilters=[],this.activeColumnFilters=[],this.processingFilterChange=!1,this.filterModelUpdateQueue=[],this.columnFilterModelUpdateQueue=[]}postConstruct(){var e,t;this.addManagedEventListeners({gridColumnsChanged:this.onColumnsChanged.bind(this),beforeRefreshModel:({params:r})=>{var n;(r.rowDataUpdated||(n=r.changedProps)!=null&&n.has("treeData"))&&this.onNewRowsLoaded("rowDataUpdated")},dataTypesInferred:this.processFilterModelUpdateQueue.bind(this)}),this.initialFilterModel={...((t=(e=this.gos.get("initialState"))==null?void 0:e.filter)==null?void 0:t.filterModel)??{}}}setFilterModel(e,t="api"){const{colModel:r,dataTypeSvc:n,filterManager:i}=this.beans;if(n!=null&&n.isPendingInference){this.filterModelUpdateQueue.push({model:e,source:t});return}const o=[],s=this.getFilterModel(!0);if(e){const a=new Set(Object.keys(e));this.allColumnFilters.forEach((l,c)=>{const u=e[c];o.push(Ka(l.filterPromise,u)),a.delete(c)}),a.forEach(l=>{const c=r.getColDefCol(l)||r.getCol(l);if(!c){Q(62,{colId:l});return}if(!c.isFilterAllowed()){Q(63,{colId:l});return}const u=this.getOrCreateFilterWrapper(c);if(!u){Q(64,{colId:l});return}o.push(Ka(u.filterPromise,e[l]))})}else this.allColumnFilters.forEach(a=>{o.push(Ka(a.filterPromise,null))});Ie.all(o).then(()=>{const a=this.getFilterModel(!0),l=[];this.allColumnFilters.forEach((c,u)=>{const d=s?s[u]:null,h=a?a[u]:null;sp(d,h)||l.push(c.column)}),l.length>0&&(i==null||i.onFilterChanged({columns:l,source:t}))})}getFilterModel(e){var o;const t={},{allColumnFilters:r,initialFilterModel:n,beans:{colModel:i}}=this;if(r.forEach((s,a)=>{const l=this.getModelFromFilterWrapper(s);ie(l)&&(t[a]=l)}),!e)for(const s of Object.keys(n)){const a=n[s];ie(a)&&!r.has(s)&&((o=i.getCol(s))!=null&&o.isFilterAllowed())&&(t[s]=a)}return t}getModelFromFilterWrapper(e){const{filter:t}=e;return t?typeof t.getModel!="function"?(Q(66),null):t.getModel():this.getModelFromInitialState(e.column)}getModelFromInitialState(e){return this.initialFilterModel[e.getColId()]??null}isColumnFilterPresent(){return this.activeColumnFilters.length>0}isAggregateFilterPresent(){return!!this.activeAggregateFilters.length}disableColumnFilters(){this.initialFilterModel={};const{allColumnFilters:e}=this;return e.size?(e.forEach(t=>this.disposeFilterWrapper(t,"advancedFilterEnabled")),!0):!1}doAggregateFiltersPass(e,t){return this.doColumnFiltersPass(e,t,!0)}updateActiveFilters(){const e=a=>a?a.isFilterActive?a.isFilterActive():(Q(67),!1):!1,{colModel:t,gos:r}=this.beans,n=!!kh(r),i=a=>{if(!a.isPrimary())return!0;const c=!t.isPivotActive();return!a.isValueActive()||!c?!1:t.isPivotMode()?!0:n},o=[],s=[];return this.forEachColumnFilter((a,l)=>{e(a)&&(i(l.column)?o.push(a):s.push(a))}).then(()=>{this.activeAggregateFilters=o,this.activeColumnFilters=s})}updateFilterFlagInColumns(e,t){return this.forEachColumnFilter((r,n)=>this.setColFilterActive(n.column,r.isFilterActive(),e,t))}forEachColumnFilter(e){const t=[];return this.allColumnFilters.forEach(r=>{const n=r.filterPromise;n&&t.push(n.then(i=>e(i,r)))}),Ie.all(t)}doColumnFiltersPass(e,t,r){const{data:n,aggData:i}=e,o=r?this.activeAggregateFilters:this.activeColumnFilters,s=r?i:n;for(let a=0;a<o.length;a++){const l=o[a];if(!(l==null||l===t)){if(typeof l.doesFilterPass!="function"){_e(91);continue}if(!l.doesFilterPass({node:e,data:s}))return!1}}return!0}callOnFilterChangedOutsideRenderCycle(e){const{rowRenderer:t,filterManager:r}=this.beans,n=()=>{this.isAlive()&&(r==null||r.onFilterChanged(e))};t.isRefreshInProgress()?setTimeout(n,0):n()}updateBeforeFilterChanged(e={}){const{filterInstance:t,additionalEventAttributes:r}=e;return this.updateDependentFilters(),this.updateActiveFilters().then(()=>this.updateFilterFlagInColumns("filterChanged",r).then(()=>{this.allColumnFilters.forEach(n=>{n.filterPromise&&n.filterPromise.then(i=>{i&&i!==t&&i.onAnyFilterChanged&&i.onAnyFilterChanged()})}),this.processingFilterChange=!0}))}updateAfterFilterChanged(){this.processingFilterChange=!1}isSuppressFlashingCellsBecauseFiltering(){return!(this.gos.get("allowShowChangeAfterFilter")??!1)&&this.processingFilterChange}onNewRowsLoaded(e){this.forEachColumnFilter(t=>{var r;(r=t.onNewRowsLoaded)==null||r.call(t)}).then(()=>this.updateFilterFlagInColumns(e,{afterDataChange:!0})).then(()=>this.updateActiveFilters())}createGetValue(e){const{filterValueSvc:t,colModel:r}=this.beans;return(n,i)=>{const o=i?r.getCol(i):e;return o?t.getValue(o,n):void 0}}isFilterActive(e){const{filter:t}=this.cachedFilter(e)??{};return t?t.isFilterActive():this.getModelFromInitialState(e)!=null}getOrCreateFilterWrapper(e){if(!e.isFilterAllowed())return null;let t=this.cachedFilter(e);return t||(t=this.createFilterWrapper(e),this.setColumnFilterWrapper(e,t)),t}cachedFilter(e){return this.allColumnFilters.get(e.getColId())}getDefaultFilter(e){let t;const{gos:r,dataTypeSvc:n}=this.beans;if(hd(r))t="agSetColumnFilter";else{const i=n==null?void 0:n.getBaseDataType(e);i==="number"?t="agNumberColumnFilter":i==="date"||i==="dateString"?t="agDateColumnFilter":t="agTextColumnFilter"}return t}getDefaultFloatingFilter(e){let t;const{gos:r,dataTypeSvc:n}=this.beans;if(hd(r))t="agSetColumnFloatingFilter";else{const i=n==null?void 0:n.getBaseDataType(e);i==="number"?t="agNumberColumnFloatingFilter":i==="date"||i==="dateString"?t="agDateColumnFloatingFilter":t="agTextColumnFloatingFilter"}return t}createFilterInstance(e,t){const r=this.getDefaultFilter(e),n=e.getColDef();let i;const o={...this.createFilterParams(e,n),filterModifiedCallback:()=>this.filterModifiedCallbackFactory(i,e)(),filterChangedCallback:a=>this.filterChangedCallbackFactory(i,e)(a),doesRowPassOtherFilter:a=>{var l;return((l=this.beans.filterManager)==null?void 0:l.doesRowPassOtherFilters(i,a))??!0}},s=F_(this.beans.userCompFactory,n,o,r);return s?{filterPromise:()=>{const a=s.newAgStackInstance();return a.then(l=>{i=l,t&&(t.filter=l??void 0)}),a},compDetails:s}:{filterPromise:null,compDetails:null}}createFilterParams(e,t){return pe(this.gos,{column:e,colDef:t,rowModel:this.beans.rowModel,filterChangedCallback:()=>{},filterModifiedCallback:()=>{},getValue:this.createGetValue(e),doesRowPassOtherFilter:()=>!0})}createFilterWrapper(e){const t={column:e,filterPromise:null,compDetails:null},{filterPromise:r,compDetails:n}=this.createFilterInstance(e,t);return t.filterPromise=(r==null?void 0:r())??null,t.compDetails=n,t}onColumnsChanged(){const e=[],{colModel:t,filterManager:r}=this.beans;this.allColumnFilters.forEach((i,o)=>{let s;i.column.isPrimary()?s=t.getColDefCol(o):s=t.getCol(o),!(s&&s===i.column)&&(e.push(i.column),this.disposeFilterWrapper(i,"columnChanged"),this.disposeColumnListener(o))});const n=e.every(my);e.length>0&&!n?r==null||r.onFilterChanged({columns:e,source:"api"}):this.updateDependentFilters()}updateDependentFilters(){var e,t;(t=(e=this.beans.autoColSvc)==null?void 0:e.getColumns())==null||t.forEach(r=>{my(r)&&this.getOrCreateFilterWrapper(r)})}isFilterAllowed(e){if(!e.isFilterAllowed())return!1;const{filter:r}=this.allColumnFilters.get(e.getColId())??{};return r&&typeof(r==null?void 0:r.isFilterAllowed)=="function"?r.isFilterAllowed():!0}getFloatingFilterCompDetails(e,t){const r=u=>{var h;const d=(h=this.getOrCreateFilterWrapper(e))==null?void 0:h.filterPromise;d!=null&&d.then(f=>{u(kv(f))})},n=e.getColDef(),i={...this.createFilterParams(e,n),filterChangedCallback:()=>r(u=>this.filterChangedCallbackFactory(u,e)())},{userCompFactory:o,frameworkOverrides:s}=this.beans,a=__(o,n,i);let l=IL(s,n,()=>this.getDefaultFloatingFilter(e));l==null&&(l="agReadOnlyFloatingFilter");const c=pe(this.gos,{column:e,filterParams:a,currentParentModel:()=>this.getCurrentFloatingFilterParentModel(e),parentFilterInstance:r,showParentFilter:t});return k_(o,n,c,l)}getCurrentFloatingFilterParentModel(e){return this.getModelFromFilterWrapper(this.cachedFilter(e)??{column:e})}destroyFilter(e,t="api"){const r=e.getColId(),n=this.allColumnFilters.get(r);this.disposeColumnListener(r),delete this.initialFilterModel[r],n&&this.disposeFilterWrapper(n,t).then(i=>{var o;i&&this.isAlive()&&((o=this.beans.filterManager)==null||o.onFilterChanged({columns:[e],source:"api"}))})}disposeColumnListener(e){const t=this.allColumnListeners.get(e);t&&(this.allColumnListeners.delete(e),t())}disposeFilterWrapper(e,t){var r;return((r=e.filterPromise)==null?void 0:r.then(n=>{const i=!!(n!=null&&n.isFilterActive());return this.destroyBean(n),this.setColFilterActive(e.column,!1,"filterDestroyed"),this.allColumnFilters.delete(e.column.getColId()),this.eventSvc.dispatchEvent({type:"filterDestroyed",source:t,column:e.column}),i}))??Ie.resolve(!1)}filterModifiedCallbackFactory(e,t){return()=>{this.eventSvc.dispatchEvent({type:"filterModified",column:t,filterInstance:e})}}filterChangedCallbackFactory(e,t){return r=>{const n=(r==null?void 0:r.source)??"columnFilter",i={filter:e,additionalEventAttributes:r,columns:[t],source:n};this.callOnFilterChangedOutsideRenderCycle(i)}}checkDestroyFilter(e){const t=this.allColumnFilters.get(e);if(!t)return;const r=t.column,{compDetails:n}=r.isFilterAllowed()?this.createFilterInstance(r):{compDetails:null};if(this.areFilterCompsDifferent(t.compDetails,n)){this.destroyFilter(r,"paramsUpdated");return}const i=r.getColDef().filterParams;if(!t.filterPromise){this.destroyFilter(r,"paramsUpdated");return}t.filterPromise.then(o=>{(o!=null&&o.refresh?o.refresh({...this.createFilterParams(r,r.getColDef()),filterModifiedCallback:this.filterModifiedCallbackFactory(o,r),filterChangedCallback:this.filterChangedCallbackFactory(o,r),doesRowPassOtherFilter:a=>{var l;return((l=this.beans.filterManager)==null?void 0:l.doesRowPassOtherFilters(o,a))??!0},...i}):!0)===!1&&this.destroyFilter(r,"paramsUpdated")})}setColumnFilterWrapper(e,t){const r=e.getColId();this.allColumnFilters.set(r,t),this.allColumnListeners.set(r,this.addManagedListeners(e,{colDefChanged:()=>this.checkDestroyFilter(r)})[0])}areFilterCompsDifferent(e,t){if(!t||!e)return!0;const{componentClass:r}=e,{componentClass:n}=t;return!(r===n||(r==null?void 0:r.render)&&(n==null?void 0:n.render)&&r.render===n.render)}hasFloatingFilters(){return this.beans.colModel.getCols().some(t=>t.getColDef().floatingFilter)}getColumnFilterInstance(e){return new Promise(t=>{this.getFilterInstanceImpl(e).then(r=>{t(kv(r))})})}getFilterInstanceImpl(e){var n;const t=this.beans.colModel.getColDefCol(e);return t?((n=this.getOrCreateFilterWrapper(t))==null?void 0:n.filterPromise)??Ie.resolve(null):Ie.resolve(void 0)}processFilterModelUpdateQueue(){this.filterModelUpdateQueue.forEach(({model:e,source:t})=>this.setFilterModel(e,t)),this.filterModelUpdateQueue=[],this.columnFilterModelUpdateQueue.forEach(({key:e,model:t,resolve:r})=>{this.setColumnFilterModel(e,t).then(()=>r())}),this.columnFilterModelUpdateQueue=[]}getColumnFilterModel(e){const t=this.getFilterWrapper(e);return t?this.getModelFromFilterWrapper(t):null}setColumnFilterModel(e,t){const{colModel:r,dataTypeSvc:n}=this.beans;if(n!=null&&n.isPendingInference){let a=()=>{};const l=new Promise(c=>{a=c});return this.columnFilterModelUpdateQueue.push({key:e,model:t,resolve:a}),l}const i=r.getColDefCol(e),o=i?this.getOrCreateFilterWrapper(i):null;return o?(a=>new Promise(l=>{a.then(c=>l(c))}))(Ka(o.filterPromise,t)):Promise.resolve()}getFilterWrapper(e){const t=this.beans.colModel.getColDefCol(e);return t?this.cachedFilter(t)??null:null}setColDefPropertiesForDataType(e,t,r){const n=hd(this.gos),i=this.getLocaleTextFunc(),o=s=>{const{filterParams:a}=e;e.filterParams=typeof a=="object"?{...a,...s}:s};switch(t.baseDataType){case"number":{n&&o({comparator:R$});break}case"boolean":{o(n?{valueFormatter:s=>ie(s.value)?i(String(s.value),s.value?"True":"False"):i("blanks","(Blanks)")}:{maxNumConditions:1,debounceMs:0,filterOptions:["empty",{displayKey:"true",displayName:"True",predicate:(s,a)=>a,numberOfInputs:0},{displayKey:"false",displayName:"False",predicate:(s,a)=>a===!1,numberOfInputs:0}]});break}case"date":{o(n?{valueFormatter:s=>{const a=r(s);return ie(a)?a:i("blanks","(Blanks)")},treeList:!0,treeListFormatter:(s,a)=>{if(s==="NaN")return i("invalidDate","Invalid Date");if(a===1&&s!=null){const l=py[Number(s)-1];return i(l,gy[l])}return s??i("blanks","(Blanks)")}}:{isValidDate:vy});break}case"dateString":{const s=t.dateParser;o(n?{valueFormatter:a=>{const l=r(a);return ie(l)?l:i("blanks","(Blanks)")},treeList:!0,treeListPathGetter:a=>{const l=s(a??void 0);return l?[String(l.getFullYear()),String(l.getMonth()+1),String(l.getDate())]:null},treeListFormatter:(a,l)=>{if(l===1&&a!=null){const c=py[Number(a)-1];return i(c,gy[c])}return a??i("blanks","(Blanks)")}}:{comparator:(a,l)=>{const c=s(l);return l==null||c<a?-1:c>a?1:0},isValidDate:a=>typeof a=="string"&&vy(s(a))});break}case"object":{n?o({valueFormatter:s=>{const a=r(s);return ie(a)?a:i("blanks","(Blanks)")}}):e.filterValueGetter=s=>r({column:s.column,node:s.node,value:this.beans.valueSvc.getValue(s.column,s.node)});break}}}setColFilterActive(e,t,r,n){e.filterActive!==t&&(e.filterActive=t,e.dispatchColEvent("filterActiveChanged",r)),e.dispatchColEvent("filterChanged",r,n)}destroy(){super.destroy(),this.allColumnFilters.forEach(e=>this.disposeFilterWrapper(e,"gridDestroyed")),this.allColumnListeners.clear()}};function Ka(e,t){return e?new Ie(r=>{e.then(n=>{typeof n.setModel!="function"&&(Q(65),r()),(n.setModel(t)||Ie.resolve()).then(()=>r())})}):Ie.resolve()}function my(e){return e.getColDef().filter==="agGroupColumnFilter"}function vy(e){return e instanceof Date&&!isNaN(e.getTime())}function T$(e){var t;return!!((t=e.filterManager)!=null&&t.isAnyFilterPresent())}function F$(e,t="api"){var r;(r=e.filterManager)==null||r.onFilterChanged({source:t})}var O$=class extends q{constructor(){super(...arguments),this.beanName="filterManager",this.advFilterModelUpdateQueue=[]}wireBeans(e){this.quickFilter=e.quickFilter,this.advancedFilter=e.advancedFilter,this.colFilter=e.colFilter}postConstruct(){const e=this.refreshFiltersForAggregations.bind(this),t=this.updateAdvFilterColumns.bind(this);this.addManagedEventListeners({columnValueChanged:e,columnPivotChanged:e,columnPivotModeChanged:e,newColumnsLoaded:t,columnVisible:t,advancedFilterEnabledChanged:({enabled:n})=>this.onAdvFilterEnabledChanged(n),dataTypesInferred:this.processFilterModelUpdateQueue.bind(this)}),this.externalFilterPresent=this.isExternalFilterPresentCallback(),this.addManagedPropertyListeners(["isExternalFilterPresent","doesExternalFilterPass"],()=>{this.onFilterChanged({source:"api"})}),this.updateAggFiltering(),this.addManagedPropertyListener("groupAggFiltering",()=>{this.updateAggFiltering(),this.onFilterChanged()}),this.quickFilter&&this.addManagedListeners(this.quickFilter,{quickFilterChanged:()=>this.onFilterChanged({source:"quickFilter"})});const{gos:r}=this;this.alwaysPassFilter=r.get("alwaysPassFilter"),this.addManagedPropertyListener("alwaysPassFilter",()=>{this.alwaysPassFilter=r.get("alwaysPassFilter"),this.onFilterChanged({source:"api"})})}isExternalFilterPresentCallback(){const e=this.gos.getCallback("isExternalFilterPresent");return typeof e=="function"&&e({})}doesExternalFilterPass(e){const t=this.gos.get("doesExternalFilterPass");return typeof t=="function"&&t(e)}setFilterModel(e,t="api"){var r;if(this.isAdvFilterEnabled()){this.warnAdvFilters();return}(r=this.colFilter)==null||r.setFilterModel(e,t)}getFilterModel(){var e;return((e=this.colFilter)==null?void 0:e.getFilterModel())??{}}isColumnFilterPresent(){var e;return!!((e=this.colFilter)!=null&&e.isColumnFilterPresent())}isAggregateFilterPresent(){var e;return!!((e=this.colFilter)!=null&&e.isAggregateFilterPresent())}isChildFilterPresent(){return this.isColumnFilterPresent()||this.isQuickFilterPresent()||this.externalFilterPresent||this.isAdvFilterPresent()}isAnyFilterPresent(){return this.isChildFilterPresent()||this.isAggregateFilterPresent()}isAdvFilterPresent(){return this.isAdvFilterEnabled()&&this.advancedFilter.isFilterPresent()}onAdvFilterEnabledChanged(e){var t,r;e?(t=this.colFilter)!=null&&t.disableColumnFilters()&&this.onFilterChanged({source:"advancedFilter"}):(r=this.advancedFilter)!=null&&r.isFilterPresent()&&(this.advancedFilter.setModel(null),this.onFilterChanged({source:"advancedFilter"}))}isAdvFilterEnabled(){var e;return!!((e=this.advancedFilter)!=null&&e.isEnabled())}isAdvFilterHeaderActive(){return this.isAdvFilterEnabled()&&this.advancedFilter.isHeaderActive()}refreshFiltersForAggregations(){kh(this.gos)&&this.onFilterChanged()}onFilterChanged(e={}){const{source:t,additionalEventAttributes:r,columns:n=[]}=e;this.externalFilterPresent=this.isExternalFilterPresentCallback(),(this.colFilter?this.colFilter.updateBeforeFilterChanged(e):Ie.resolve()).then(()=>{var o;const i={source:t,type:"filterChanged",columns:n};r&&Et(i,r),this.eventSvc.dispatchEvent(i),(o=this.colFilter)==null||o.updateAfterFilterChanged()})}isSuppressFlashingCellsBecauseFiltering(){var e;return!!((e=this.colFilter)!=null&&e.isSuppressFlashingCellsBecauseFiltering())}isQuickFilterPresent(){var e;return!!((e=this.quickFilter)!=null&&e.isFilterPresent())}updateAggFiltering(){this.aggFiltering=!!kh(this.gos)}isAggregateQuickFilterPresent(){return this.isQuickFilterPresent()&&this.shouldApplyQuickFilterAfterAgg()}isNonAggregateQuickFilterPresent(){return this.isQuickFilterPresent()&&!this.shouldApplyQuickFilterAfterAgg()}shouldApplyQuickFilterAfterAgg(){return(this.aggFiltering||this.beans.colModel.isPivotMode())&&!this.gos.get("applyQuickFilterBeforePivotOrAgg")}doesRowPassOtherFilters(e,t){return this.doesRowPassFilter({rowNode:t,filterInstanceToSkip:e})}doesRowPassAggregateFilters(e){var r;const{rowNode:t}=e;return(r=this.alwaysPassFilter)!=null&&r.call(this,t)?!0:!(this.isAggregateQuickFilterPresent()&&!this.quickFilter.doesRowPass(t)||this.isAggregateFilterPresent()&&!this.colFilter.doAggregateFiltersPass(t,e.filterInstanceToSkip))}doesRowPassFilter(e){var r;const{rowNode:t}=e;return(r=this.alwaysPassFilter)!=null&&r.call(this,t)?!0:!(this.isNonAggregateQuickFilterPresent()&&!this.quickFilter.doesRowPass(t)||this.externalFilterPresent&&!this.doesExternalFilterPass(t)||this.isColumnFilterPresent()&&!this.colFilter.doColumnFiltersPass(t,e.filterInstanceToSkip)||this.isAdvFilterPresent()&&!this.advancedFilter.doesFilterPass(t))}isFilterActive(e){var t;return!!((t=this.colFilter)!=null&&t.isFilterActive(e))}getOrCreateFilterWrapper(e){var t;return((t=this.colFilter)==null?void 0:t.getOrCreateFilterWrapper(e))??null}getDefaultFloatingFilter(e){return this.colFilter.getDefaultFloatingFilter(e)}createFilterParams(e,t){return this.colFilter.createFilterParams(e,t)}isFilterAllowed(e){var t;return this.isAdvFilterEnabled()?!1:!!((t=this.colFilter)!=null&&t.isFilterAllowed(e))}getFloatingFilterCompDetails(e,t){var r;return(r=this.colFilter)==null?void 0:r.getFloatingFilterCompDetails(e,t)}getCurrentFloatingFilterParentModel(e){var t;return(t=this.colFilter)==null?void 0:t.getCurrentFloatingFilterParentModel(e)}destroyFilter(e,t="api"){var r;(r=this.colFilter)==null||r.destroyFilter(e,t)}areFilterCompsDifferent(e,t){var r;return!!((r=this.colFilter)!=null&&r.areFilterCompsDifferent(e,t))}getAdvFilterModel(){return this.isAdvFilterEnabled()?this.advancedFilter.getModel():null}setAdvFilterModel(e,t="api"){var r;if(this.isAdvFilterEnabled()){if((r=this.beans.dataTypeSvc)!=null&&r.isPendingInference){this.advFilterModelUpdateQueue.push(e);return}this.advancedFilter.setModel(e??null),this.onFilterChanged({source:t})}}toggleAdvFilterBuilder(e,t){this.isAdvFilterEnabled()&&this.advancedFilter.getCtrl().toggleFilterBuilder({source:t,force:e})}updateAdvFilterColumns(){this.isAdvFilterEnabled()&&this.advancedFilter.updateValidity()&&this.onFilterChanged({source:"advancedFilter"})}hasFloatingFilters(){var e;return this.isAdvFilterEnabled()?!1:!!((e=this.colFilter)!=null&&e.hasFloatingFilters())}getColumnFilterInstance(e){var t;return this.isAdvFilterEnabled()?(this.warnAdvFilters(),Promise.resolve(void 0)):((t=this.colFilter)==null?void 0:t.getColumnFilterInstance(e))??Promise.resolve(void 0)}warnAdvFilters(){Q(68)}setupAdvFilterHeaderComp(e){var t;(t=this.advancedFilter)==null||t.getCtrl().setupHeaderComp(e)}getHeaderRowCount(){return this.isAdvFilterHeaderActive()?1:0}getHeaderHeight(){return this.isAdvFilterHeaderActive()?this.advancedFilter.getCtrl().getHeaderHeight():0}processFilterModelUpdateQueue(){this.advFilterModelUpdateQueue.forEach(e=>this.setAdvFilterModel(e)),this.advFilterModelUpdateQueue=[]}getColumnFilterModel(e){var t;return(t=this.colFilter)==null?void 0:t.getColumnFilterModel(e)}setColumnFilterModel(e,t){var r;return this.isAdvFilterEnabled()?(this.warnAdvFilters(),Promise.resolve()):((r=this.colFilter)==null?void 0:r.setColumnFilterModel(e,t))??Promise.resolve()}setColDefPropertiesForDataType(e,t,r){var n;(n=this.colFilter)==null||n.setColDefPropertiesForDataType(e,t,r)}},M$=class extends q{constructor(){super(...arguments),this.beanName="filterMenuFactory"}wireBeans(e){this.popupSvc=e.popupSvc}hideActiveMenu(){var e;(e=this.hidePopup)==null||e.call(this)}showMenuAfterMouseEvent(e,t,r,n){e&&!e.isColumn||this.showPopup(e,i=>{var o;(o=this.popupSvc)==null||o.positionPopupUnderMouseEvent({column:e,type:r,mouseEvent:t,ePopup:i})},r,t.target,Bt(this.gos),n)}showMenuAfterButtonClick(e,t,r,n){if(e&&!e.isColumn)return;let i=-1,o="left";const s=Bt(this.gos);!s&&this.gos.get("enableRtl")&&(i=1,o="right");const a=s?void 0:4*i,l=s?void 0:4;this.showPopup(e,c=>{var u;(u=this.popupSvc)==null||u.positionPopupByComponent({type:r,eventSource:t,ePopup:c,nudgeX:a,nudgeY:l,alignSide:o,keepWithinBounds:!0,position:"under",column:e})},r,t,s,n)}showPopup(e,t,r,n,i,o){var m;const s=e?this.createBean(new FL(e,"COLUMN_MENU")):void 0;if(this.activeMenu=s,!(s!=null&&s.hasFilter())||!e){_e(57);return}const a=lt({tag:"div",cls:`ag-menu${i?"":" ag-filter-menu"}`,role:"presentation"});[this.tabListener]=this.addManagedElementListeners(a,{keydown:p=>this.trapFocusWithin(p,a)}),a.appendChild(s==null?void 0:s.getGui());let l;const c=()=>s==null?void 0:s.afterGuiDetached(),u=pI(this.gos)?n??this.beans.ctrlsSvc.getGridBodyCtrl().eGridBody:void 0,d=p=>{Hv(e,!1,"contextMenu");const y=p instanceof KeyboardEvent;if(this.tabListener&&(this.tabListener=this.tabListener()),y&&n&&Sr(n)){const w=k1(n);w==null||w.focus({preventScroll:!0})}c(),this.destroyBean(this.activeMenu),this.dispatchVisibleChangedEvent(!1,r,e),o==null||o()},h=this.getLocaleTextFunc(),f=i&&r!=="columnFilter"?h("ariaLabelColumnMenu","Column Menu"):h("ariaLabelColumnFilter","Column Filter"),g=(m=this.popupSvc)==null?void 0:m.addPopup({modal:!0,eChild:a,closeOnEsc:!0,closedCallback:d,positionCallback:()=>t(a),anchorToElement:u,ariaLabel:f});g&&(this.hidePopup=l=g.hideFunc),s.afterInit().then(()=>{t(a),s.afterGuiAttached({container:r,hidePopup:l})}),Hv(e,!0,"contextMenu"),this.dispatchVisibleChangedEvent(!0,r,e)}trapFocusWithin(e,t){e.key!==j.TAB||e.defaultPrevented||yo(this.beans,t,!1,e.shiftKey)||(e.preventDefault(),qn(t,e.shiftKey))}dispatchVisibleChangedEvent(e,t,r){this.eventSvc.dispatchEvent({type:"columnMenuVisibleChanged",visible:e,switchingTab:!1,key:t,column:r??null,columnGroup:null})}isMenuEnabled(e){return e.isFilterAllowed()&&(e.getColDef().menuTabs??["filterMenuTab"]).includes("filterMenuTab")}showMenuAfterContextMenuEvent(){}destroy(){this.destroyBean(this.activeMenu),super.destroy()}},D$=class extends q{constructor(){super(...arguments),this.beanName="filterValueSvc"}getValue(e,t){if(!t)return;const r=e.getColDef(),{filterValueGetter:n}=r;return n?this.executeFilterValueGetter(n,t.data,e,t,r):this.beans.valueSvc.getValue(e,t)}executeFilterValueGetter(e,t,r,n,i){const{expressionSvc:o,valueSvc:s}=this.beans,a=pe(this.gos,{data:t,node:n,column:r,colDef:i,getValue:s.getValueCallback.bind(s,n)});return typeof e=="function"?e(a):o==null?void 0:o.evaluate(e,a)}},NS=class{constructor(){this.customFilterOptions={}}init(e,t){this.filterOptions=e.filterOptions||t,this.mapCustomOptions(),this.selectDefaultItem(e)}mapCustomOptions(){const{filterOptions:e}=this;e&&e.forEach(t=>{if(typeof t=="string")return;const r=[["displayKey"],["displayName"],["predicate","test"]],n=i=>i.some(o=>t[o]!=null)?!0:(Q(72,{keys:i}),!1);if(!r.every(n)){this.filterOptions=e.filter(i=>i===t)||[];return}this.customFilterOptions[t.displayKey]=t})}selectDefaultItem(e){const{filterOptions:t}=this;if(e.defaultOption)this.defaultOption=e.defaultOption;else if(t.length>=1){const r=t[0];typeof r=="string"?this.defaultOption=r:r.displayKey?this.defaultOption=r.displayKey:Q(73)}else Q(74)}getCustomOption(e){return this.customFilterOptions[e]}};function yy(e,t,r){return r==null?e.splice(t):e.splice(t,r)}function by(e){return e==null||typeof e=="string"&&e.trim().length===0}function k$(e){return e==="AND"||e==="OR"?e:"AND"}function I$(e,t,r){if(e==null)return;const{predicate:n}=e;if(n!=null&&!t.some(i=>i==null))return n(t,r)}function _$(e,t){let r=e.length;return r>t&&(e.splice(t),Q(78),r=t),r}var L$=class extends kL{constructor(){super(...arguments),this.eTypes=[],this.eJoinOperatorPanels=[],this.eJoinOperatorsAnd=[],this.eJoinOperatorsOr=[],this.eConditionBodies=[],this.listener=()=>this.onUiChanged(),this.lastUiCompletePosition=null,this.joinOperatorId=0}getNumberOfInputs(e){const t=this.optionsFactory.getCustomOption(e);if(t){const{numberOfInputs:n}=t;return n??1}return e&&["empty","notBlank","blank"].indexOf(e)>=0?0:e==="inRange"?2:1}onFloatingFilterChanged(e,t){this.setTypeFromFloatingFilter(e),this.setValueFromFloatingFilter(t),this.onUiChanged(!0)}setTypeFromFloatingFilter(e){this.eTypes.forEach((t,r)=>{const n=r===0?e:this.optionsFactory.defaultOption;t.setValue(n,!0)})}getModelFromUi(){const e=this.getUiCompleteConditions();return e.length===0?null:this.maxNumConditions>1&&e.length>1?{filterType:this.filterType,operator:this.getJoinOperator(),conditions:e}:e[0]}getConditionTypes(){return this.eTypes.map(e=>e.getValue())}getConditionType(e){return this.eTypes[e].getValue()}getJoinOperator(){const{eJoinOperatorsOr:e,defaultJoinOperator:t}=this;return e.length===0?t:e[0].getValue()===!0?"OR":"AND"}areModelsEqual(e,t){if(!e&&!t)return!0;if(!e&&t||e&&!t)return!1;const r=!e.operator,n=!t.operator;if(!r&&n||r&&!n)return!1;let o;if(r){const s=e,a=t;o=this.areSimpleModelsEqual(s,a)}else{const s=e,a=t;o=s.operator===a.operator&&mo(s.conditions,a.conditions,(l,c)=>this.areSimpleModelsEqual(l,c))}return o}shouldRefresh(e){var o;const t=this.getModel(),r=t?t.conditions??[t]:null,n=((o=e.filterOptions)==null?void 0:o.map(s=>typeof s=="string"?s:s.displayKey))??this.getDefaultFilterOptions();return!(!(!r||r.every(s=>n.find(a=>a===s.type)!==void 0))||typeof e.maxNumConditions=="number"&&r&&r.length>e.maxNumConditions)}refresh(e){return!this.shouldRefresh(e)||!super.refresh(e)?!1:(this.setParams(e),this.removeConditionsAndOperators(0),this.createOption(),this.setModel(this.getModel()),!0)}setModelIntoUi(e){if(e.operator){const r=e;let n=r.conditions;n==null&&(n=[],Q(77));const i=_$(n,this.maxNumConditions),o=this.getNumConditions();if(i<o)this.removeConditionsAndOperators(i);else if(i>o)for(let a=o;a<i;a++)this.createJoinOperatorPanel(),this.createOption();const s=r.operator==="OR";this.eJoinOperatorsAnd.forEach(a=>a.setValue(!s,!0)),this.eJoinOperatorsOr.forEach(a=>a.setValue(s,!0)),n.forEach((a,l)=>{this.eTypes[l].setValue(a.type,!0),this.setConditionIntoUi(a,l)})}else{const r=e;this.getNumConditions()>1&&this.removeConditionsAndOperators(1),this.eTypes[0].setValue(r.type,!0),this.setConditionIntoUi(r,0)}return this.lastUiCompletePosition=this.getNumConditions()-1,this.createMissingConditionsAndOperators(),this.onUiChanged(),Ie.resolve()}doesFilterPass(e){const t=this.getModel();if(t==null)return!0;const{operator:r}=t,n=[];if(r){const o=t;n.push(...o.conditions??[])}else n.push(t);return n[r&&r==="OR"?"some":"every"](o=>this.individualConditionPasses(e,o))}setParams(e){super.setParams(e),this.setNumConditions(e),this.defaultJoinOperator=k$(e.defaultJoinOperator),this.filterPlaceholder=e.filterPlaceholder,this.optionsFactory=new NS,this.optionsFactory.init(e,this.getDefaultFilterOptions()),this.createFilterListOptions(),this.createOption(),this.createMissingConditionsAndOperators(),this.isReadOnly()&&this.eFilterBody.setAttribute("tabindex","-1")}setNumConditions(e){let t=e.maxNumConditions??2;t<1&&(Q(79),t=1),this.maxNumConditions=t;let r=e.numAlwaysVisibleConditions??1;r<1&&(Q(80),r=1),r>t&&(Q(81),r=t),this.numAlwaysVisibleConditions=r}createOption(){const e=this.createManagedBean(new cB);this.eTypes.push(e),e.addCss("ag-filter-select"),this.eFilterBody.appendChild(e.getGui());const t=this.createValueElement();this.eConditionBodies.push(t),this.eFilterBody.appendChild(t),this.putOptionsIntoDropdown(e),this.resetType(e);const r=this.getNumConditions()-1;this.forEachPositionInput(r,n=>this.resetInput(n)),this.addChangedListeners(e,r)}createJoinOperatorPanel(){const e=lt({tag:"div",cls:"ag-filter-condition"});this.eJoinOperatorPanels.push(e);const t=this.createJoinOperator(this.eJoinOperatorsAnd,e,"and"),r=this.createJoinOperator(this.eJoinOperatorsOr,e,"or");this.eFilterBody.appendChild(e);const n=this.eJoinOperatorPanels.length-1,i=this.joinOperatorId++;this.resetJoinOperatorAnd(t,n,i),this.resetJoinOperatorOr(r,n,i),this.isReadOnly()||(t.onValueChange(this.listener),r.onValueChange(this.listener))}createJoinOperator(e,t,r){const n=this.createManagedBean(new Q3);e.push(n);const i="ag-filter-condition-operator";return n.addCss(i),n.addCss(`${i}-${r}`),t.appendChild(n.getGui()),n}createFilterListOptions(){this.filterListOptions=this.optionsFactory.filterOptions.map(e=>typeof e=="string"?this.createBoilerplateListOption(e):this.createCustomListOption(e))}putOptionsIntoDropdown(e){const{filterListOptions:t}=this;t.forEach(r=>{e.addOption(r)}),e.setDisabled(t.length<=1)}createBoilerplateListOption(e){return{value:e,text:this.translate(e)}}createCustomListOption(e){const{displayKey:t}=e,r=this.optionsFactory.getCustomOption(e.displayKey);return{value:t,text:r?this.getLocaleTextFunc()(r.displayKey,r.displayName):this.translate(t)}}createBodyTemplate(){return null}getAgComponents(){return[]}getCssIdentifier(){return"simple-filter"}updateUiVisibility(){const e=this.getJoinOperator();this.updateNumConditions(),this.updateConditionStatusesAndValues(this.lastUiCompletePosition,e)}updateNumConditions(){let e=-1,t=!0;for(let r=0;r<this.getNumConditions();r++)this.isConditionUiComplete(r)?e=r:t=!1;if(this.shouldAddNewConditionAtEnd(t))this.createJoinOperatorPanel(),this.createOption();else{const r=this.lastUiCompletePosition??this.getNumConditions()-2;if(e<r){this.removeConditionsAndOperators(r+1);const n=e+1,i=r-n;i>0&&this.removeConditionsAndOperators(n,i),this.createMissingConditionsAndOperators()}}this.lastUiCompletePosition=e}updateConditionStatusesAndValues(e,t){this.eTypes.forEach((n,i)=>{const o=this.isConditionDisabled(i,e);n.setDisabled(o||this.filterListOptions.length<=1),i===1&&(xs(this.eJoinOperatorPanels[0],o),this.eJoinOperatorsAnd[0].setDisabled(o),this.eJoinOperatorsOr[0].setDisabled(o))}),this.eConditionBodies.forEach((n,i)=>{Je(n,this.isConditionBodyVisible(i))});const r=(t??this.getJoinOperator())==="OR";this.eJoinOperatorsAnd.forEach(n=>{n.setValue(!r,!0)}),this.eJoinOperatorsOr.forEach(n=>{n.setValue(r,!0)}),this.forEachInput((n,i,o,s)=>{this.setElementDisplayed(n,i<s),this.setElementDisabled(n,this.isConditionDisabled(o,e))}),this.resetPlaceholder()}shouldAddNewConditionAtEnd(e){return e&&this.getNumConditions()<this.maxNumConditions&&!this.isReadOnly()}removeConditionsAndOperators(e,t){if(e>=this.getNumConditions())return;const{eTypes:r,eConditionBodies:n,eJoinOperatorPanels:i,eJoinOperatorsAnd:o,eJoinOperatorsOr:s}=this;this.removeComponents(r,e,t),this.removeElements(n,e,t),this.removeValueElements(e,t);const a=Math.max(e-1,0);this.removeElements(i,a,t),this.removeComponents(o,a,t),this.removeComponents(s,a,t)}removeElements(e,t,r){yy(e,t,r).forEach(i=>jn(i))}removeComponents(e,t,r){yy(e,t,r).forEach(i=>{jn(i.getGui()),this.destroyBean(i)})}afterGuiAttached(e){var t;if(super.afterGuiAttached(e),this.resetPlaceholder(),!(e!=null&&e.suppressFocus)){const{eFilterBody:r,eTypes:n}=this;let i;if(!this.isReadOnly()){const o=this.getInputs(0)[0];o instanceof pi&&this.isConditionBodyVisible(0)?i=o.getInputElement():i=(t=n[0])==null?void 0:t.getFocusableElement()}(i??r).focus({preventScroll:!0})}}afterGuiDetached(){super.afterGuiDetached();const e=this.getModel();this.resetUiToActiveModel(e);let t=-1,r=-1,n=!1;const i=this.getJoinOperator();for(let s=this.getNumConditions()-1;s>=0;s--)if(this.isConditionUiComplete(s))t===-1&&(t=s,r=s);else{const a=s>=this.numAlwaysVisibleConditions&&!this.isConditionUiComplete(s-1),l=s<t;(a||l)&&(this.removeConditionsAndOperators(s,1),n=!0,l&&r--)}let o=!1;this.getNumConditions()<this.numAlwaysVisibleConditions&&(this.createMissingConditionsAndOperators(),o=!0),this.shouldAddNewConditionAtEnd(r===this.getNumConditions()-1)&&(this.createJoinOperatorPanel(),this.createOption(),o=!0),o&&this.updateConditionStatusesAndValues(r,i),n&&this.updateJoinOperatorsDisabled(),this.lastUiCompletePosition=r}getPlaceholderText(e,t){let r=this.translate(e);if(typeof this.filterPlaceholder=="function"){const n=this.eTypes[t].getValue(),i=this.translate(n);r=this.filterPlaceholder({filterOptionKey:n,filterOption:i,placeholder:r})}else typeof this.filterPlaceholder=="string"&&(r=this.filterPlaceholder);return r}resetPlaceholder(){const e=this.getLocaleTextFunc();this.forEachInput((t,r,n,i)=>{if(!(t instanceof pi))return;const o=r===0&&i>1?"inRangeStart":r===0?"filterOoo":"inRangeEnd",s=r===0&&i>1?e("ariaFilterFromValue","Filter from value"):r===0?e("ariaFilterValue","Filter Value"):e("ariaFilterToValue","Filter to Value");t.setInputPlaceholder(this.getPlaceholderText(o,n)),t.setInputAriaLabel(s)})}setElementValue(e,t,r){e instanceof pi&&e.setValue(t!=null?String(t):null,!0)}setElementDisplayed(e,t){e instanceof ct&&Je(e.getGui(),t)}setElementDisabled(e,t){e instanceof ct&&xs(e.getGui(),t)}attachElementOnChange(e,t){e instanceof pi&&e.onValueChange(t)}forEachInput(e){this.getConditionTypes().forEach((t,r)=>{this.forEachPositionTypeInput(r,t,e)})}forEachPositionInput(e,t){const r=this.getConditionType(e);this.forEachPositionTypeInput(e,r,t)}forEachPositionTypeInput(e,t,r){const n=this.getNumberOfInputs(t),i=this.getInputs(e);for(let o=0;o<i.length;o++){const s=i[o];s!=null&&r(s,o,e,n)}}isConditionDisabled(e,t){return this.isReadOnly()?!0:e===0?!1:e>t+1}isConditionBodyVisible(e){const t=this.getConditionType(e);return this.getNumberOfInputs(t)>0}isConditionUiComplete(e){return!(e>=this.getNumConditions()||this.getConditionType(e)==="empty"||this.getValues(e).some(r=>r==null))}getNumConditions(){return this.eTypes.length}getUiCompleteConditions(){const e=[];for(let t=0;t<this.getNumConditions();t++)this.isConditionUiComplete(t)&&e.push(this.createCondition(t));return e}createMissingConditionsAndOperators(){if(!this.isReadOnly())for(let e=this.getNumConditions();e<this.numAlwaysVisibleConditions;e++)this.createJoinOperatorPanel(),this.createOption()}resetUiToDefaults(e){return this.removeConditionsAndOperators(this.isReadOnly()?1:this.numAlwaysVisibleConditions),this.eTypes.forEach(t=>this.resetType(t)),this.eJoinOperatorsAnd.forEach((t,r)=>this.resetJoinOperatorAnd(t,r,this.joinOperatorId+r)),this.eJoinOperatorsOr.forEach((t,r)=>this.resetJoinOperatorOr(t,r,this.joinOperatorId+r)),this.joinOperatorId++,this.forEachInput(t=>this.resetInput(t)),this.resetPlaceholder(),this.createMissingConditionsAndOperators(),this.lastUiCompletePosition=null,e||this.onUiChanged(),Ie.resolve()}resetType(e){const r=this.getLocaleTextFunc()("ariaFilteringOperator","Filtering operator");e.setValue(this.optionsFactory.defaultOption,!0).setAriaLabel(r).setDisabled(this.isReadOnly()||this.filterListOptions.length<=1)}resetJoinOperatorAnd(e,t,r){this.resetJoinOperator(e,t,this.defaultJoinOperator==="AND",this.translate("andCondition"),r)}resetJoinOperatorOr(e,t,r){this.resetJoinOperator(e,t,this.defaultJoinOperator==="OR",this.translate("orCondition"),r)}resetJoinOperator(e,t,r,n,i){this.updateJoinOperatorDisabled(e.setValue(r,!0).setName(`ag-simple-filter-and-or-${this.getCompId()}-${i}`).setLabel(n),t)}updateJoinOperatorsDisabled(){const e=(t,r)=>this.updateJoinOperatorDisabled(t,r);this.eJoinOperatorsAnd.forEach(e),this.eJoinOperatorsOr.forEach(e)}updateJoinOperatorDisabled(e,t){e.setDisabled(this.isReadOnly()||t>0)}resetInput(e){this.setElementValue(e,null),this.setElementDisabled(e,this.isReadOnly())}setConditionIntoUi(e,t){const r=this.mapValuesFromModel(e);this.forEachInput((n,i,o)=>{o===t&&this.setElementValue(n,r[i]!=null?r[i]:null)})}setValueFromFloatingFilter(e){this.forEachInput((t,r,n)=>{this.setElementValue(t,r===0&&n===0?e:null,!0)})}addChangedListeners(e,t){this.isReadOnly()||(e.onValueChange(this.listener),this.forEachPositionInput(t,r=>{this.attachElementOnChange(r,this.listener)}))}individualConditionPasses(e,t){const r=this.getCellValue(e.node),n=this.mapValuesFromModel(t),i=this.optionsFactory.getCustomOption(t.type),o=I$(i,n,r);return o??(r==null?this.evaluateNullValue(t.type):this.evaluateNonNullValue(n,r,t,e))}hasInvalidInputs(){return!1}},B$=class{constructor(e,t,r){this.getLocaleTextFunc=e,this.optionsFactory=t,this.valueFormatter=r}getModelAsString(e){if(!e)return null;const t=e.operator!=null,r=this.getLocaleTextFunc();if(t){const n=e,o=(n.conditions??[]).map(a=>this.getModelAsString(a)),s=n.operator==="AND"?"andCondition":"orCondition";return o.join(` ${r(s,W1[s])} `)}else{if(e.type==="blank"||e.type==="notBlank")return r(e.type,e.type);{const n=e,i=this.optionsFactory.getCustomOption(n.type),{displayKey:o,displayName:s,numberOfInputs:a}=i||{};return o&&s&&a===0?(r(o,s),s):this.conditionToString(n,i)}}}updateParams(e){this.optionsFactory=e.optionsFactory}formatValue(e){const t=this.valueFormatter;return t?t(e??null)??"":String(e)}},z$=class extends ct{constructor(){super(...arguments),this.defaultDebounceMs=0}setLastTypeFromModel(e){if(!e){this.lastType=this.optionsFactory.defaultOption;return}const t=e.operator;let r;t?r=e.conditions[0]:r=e,this.lastType=r.type}canWeEditAfterModelFromParentFilter(e){if(!e)return this.isTypeEditable(this.lastType);if(e.operator)return!1;const r=e;return this.isTypeEditable(r.type)}init(e){this.setSimpleParams(e,!1)}setSimpleParams(e,t=!0){const r=new NS;this.optionsFactory=r,r.init(e.filterParams,this.getDefaultOptions());const n=r.defaultOption;t||(this.lastType=n),this.readOnly=!!e.filterParams.readOnly;const i=this.isTypeEditable(n);this.setEditable(i)}refresh(e){this.setSimpleParams(e)}hasSingleInput(e){var r;const t=(r=this.optionsFactory.getCustomOption(e))==null?void 0:r.numberOfInputs;return t==null||t==1}isTypeEditable(e){const t=["inRange","empty","blank","notBlank"];return!!e&&!this.readOnly&&this.hasSingleInput(e)&&t.indexOf(e)<0}getAriaLabel(e){return`${this.beans.colNames.getDisplayNameForColumn(e.column,"header",!0)} ${this.getLocaleTextFunc()("ariaFilterInput","Filter Input")}`}},N$=class extends q{constructor(e){super(),this.params=e,this.eInput=fe,this.onValueChanged=()=>{}}setupGui(e){var n;this.eInput=this.createManagedBean(new oS((n=this.params)==null?void 0:n.config));const t=this.eInput.getGui();e.appendChild(t);const r=i=>this.onValueChanged(i);this.addManagedListeners(t,{input:r,keydown:r})}setEditable(e){this.eInput.setDisabled(!e)}getValue(){return this.eInput.getValue()}setValue(e,t){this.eInput.setValue(e,t)}setValueChangedListener(e){this.onValueChanged=e}setParams({ariaLabel:e,autoComplete:t}){const{eInput:r}=this;r.setInputAriaLabel(e),t!==void 0&&r.setAutoComplete(t)}};function $S(e){const t=e==null?void 0:e.trim();return t===""?e:t}var $$={tag:"div",ref:"eFloatingFilterInputContainer",cls:"ag-floating-filter-input",role:"presentation"},H$=class extends z${constructor(){super(...arguments),this.eFloatingFilterInputContainer=fe,this.defaultDebounceMs=500}postConstruct(){this.setTemplate($$)}onParentModelChanged(e,t){t!=null&&t.afterFloatingFilter||t!=null&&t.afterDataChange||(this.setLastTypeFromModel(e),this.setEditable(this.canWeEditAfterModelFromParentFilter(e)),this.inputSvc.setValue(this.filterModelFormatter.getModelAsString(e)))}init(e){this.setupFloatingFilterInputService(e),super.init(e),this.setTextInputParams(e)}setupFloatingFilterInputService(e){this.inputSvc=this.createFloatingFilterInputService(e),this.inputSvc.setupGui(this.eFloatingFilterInputContainer)}setTextInputParams(e){this.params=e;const t=e.browserAutoComplete??!1,{inputSvc:r,defaultDebounceMs:n,readOnly:i}=this;if(r.setParams({ariaLabel:this.getAriaLabel(e),autoComplete:t}),this.applyActive=jl(e.filterParams),!i){const o=j1(e.filterParams,n),s=kr(this,this.syncUpWithParentFilter.bind(this),o);r.setValueChangedListener(s)}}refresh(e){super.refresh(e),this.setTextInputParams(e)}recreateFloatingFilterInputService(e){const{inputSvc:t}=this,r=t.getValue();hn(this.eFloatingFilterInputContainer),this.destroyBean(t),this.setupFloatingFilterInputService(e),t.setValue(r,!0)}syncUpWithParentFilter(e){const t=e.key===j.ENTER;if(this.applyActive&&!t)return;const{inputSvc:r,params:n}=this;let i=r.getValue();n.filterParams.trimInput&&(i=$S(i),r.setValue(i,!0)),n.parentFilterInstance(o=>{o==null||o.onFloatingFilterChanged(this.lastType||null,i||null)})}setEditable(e){this.inputSvc.setEditable(e)}},HS=["contains","notContains","equals","notEqual","startsWith","endsWith","blank","notBlank"],GS=class extends B${conditionToString(e,t){const{numberOfInputs:r}=t||{},{filter:n,filterTo:i,type:o}=e;return o=="inRange"||r===2?`${n}-${i}`:n!=null?`${n}`:`${o}`}},G$=class extends L${constructor(){super("textFilter"),this.filterType="text",this.defaultFormatter=e=>e,this.defaultLowercaseFormatter=e=>e==null?null:e.toString().toLowerCase(),this.defaultMatcher=({filterOption:e,value:t,filterText:r})=>{if(r==null)return!1;switch(e){case"contains":return t.indexOf(r)>=0;case"notContains":return t.indexOf(r)<0;case"equals":return t===r;case"notEqual":return t!=r;case"startsWith":return t.indexOf(r)===0;case"endsWith":{const n=t.lastIndexOf(r);return n>=0&&n===t.length-r.length}default:return!1}},this.eValuesFrom=[],this.eValuesTo=[],this.defaultDebounceMs=500}setParams(e){this.textFilterParams=e,super.setParams(e),this.matcher=e.textMatcher||this.defaultMatcher,this.formatter=e.textFormatter||(e.caseSensitive?this.defaultFormatter:this.defaultLowercaseFormatter),this.filterModelFormatter=new GS(this.getLocaleTextFunc.bind(this),this.optionsFactory)}createCondition(e){const t=this.getConditionType(e),r={filterType:this.filterType,type:t},n=this.getValuesWithSideEffects(e,!0);return n.length>0&&(r.filter=n[0]),n.length>1&&(r.filterTo=n[1]),r}areSimpleModelsEqual(e,t){return e.filter===t.filter&&e.filterTo===t.filterTo&&e.type===t.type}getInputs(e){const{eValuesFrom:t,eValuesTo:r}=this;return e>=t.length?[null,null]:[t[e],r[e]]}getValues(e){return this.getValuesWithSideEffects(e,!1)}getValuesWithSideEffects(e,t){const r=[];return this.forEachPositionInput(e,(n,i,o,s)=>{if(i<s){let a=on(n.getValue());t&&this.textFilterParams.trimInput&&(a=$S(a)??null,n.setValue(a,!0)),r.push(a)}}),r}getDefaultFilterOptions(){return HS}createValueElement(){const e=lt({tag:"div",cls:"ag-filter-body",role:"presentation"});return this.createFromToElement(e,this.eValuesFrom,"from"),this.createFromToElement(e,this.eValuesTo,"to"),e}createFromToElement(e,t,r){const n=this.createManagedBean(new oS);n.addCss(`ag-filter-${r}`),n.addCss("ag-filter-filter"),t.push(n),e.appendChild(n.getGui())}removeValueElements(e,t){const r=n=>this.removeComponents(n,e,t);r(this.eValuesFrom),r(this.eValuesTo)}mapValuesFromModel(e){const{filter:t,filterTo:r,type:n}=e||{};return[t||null,r||null].slice(0,this.getNumberOfInputs(n))}evaluateNullValue(e){return e?["notEqual","notContains","blank"].indexOf(e)>=0:!1}evaluateNonNullValue(e,t,r,n){const i=e.map(h=>this.formatter(h))||[],o=this.formatter(t),{api:s,colDef:a,column:l,context:c,textFormatter:u}=this.textFilterParams;if(r.type==="blank")return by(t);if(r.type==="notBlank")return!by(t);const d={api:s,colDef:a,column:l,context:c,node:n.node,data:n.data,filterOption:r.type,value:o,textFormatter:u};return i.some(h=>this.matcher({...d,filterText:h}))}getModelAsString(e){return this.filterModelFormatter.getModelAsString(e)??""}},W$=class extends H${init(e){super.init(e),this.filterModelFormatter=new GS(this.getLocaleTextFunc.bind(this),this.optionsFactory)}refresh(e){super.refresh(e),this.filterModelFormatter.updateParams({optionsFactory:this.optionsFactory})}getDefaultOptions(){return HS}createFloatingFilterInputService(){return this.createManagedBean(new N$)}},j$={moduleName:"ClientSideRowModelFilter",version:he,rowModels:["clientSide"],beans:[c$]},V$={moduleName:"FilterCore",version:he,beans:[O$],apiFunctions:{isAnyFilterPresent:T$,onFilterChanged:F$},css:[v$],dependsOn:[j$]},U$={moduleName:"FilterValue",version:he,beans:[D$]},K$={moduleName:"ColumnFilter",version:he,beans:[E$,M$],dynamicBeans:{headerFilterCellCtrl:u$},icons:{filter:"filter",filterActive:"filter"},apiFunctions:{isColumnFilterPresent:y$,getColumnFilterInstance:b$,destroyFilter:C$,setFilterModel:w$,getFilterModel:S$,getColumnFilterModel:x$,setColumnFilterModel:A$,showColumnFilter:P$},dependsOn:[V$,zS,U$,f$]},q$={moduleName:"TextFilter",version:he,dependsOn:[K$],userComponents:{agTextColumnFilter:G$,agTextColumnFloatingFilter:W$}},Y$=class extends q{constructor(){super(...arguments),this.beanName="selectionColSvc"}postConstruct(){this.addManagedPropertyListener("rowSelection",e=>{this.onSelectionOptionsChanged(e.currentValue,e.previousValue,Ri(e.source))}),this.addManagedPropertyListener("selectionColumnDef",this.updateColumns.bind(this))}addColumns(e){const t=this.columns;t!=null&&(e.list=t.list.concat(e.list),e.tree=t.tree.concat(e.tree),BI(e))}createColumns(e,t){var h,f;const r=()=>{var g;Ll(this.beans,(g=this.columns)==null?void 0:g.tree),this.columns=null},n=e.treeDepth,o=(((h=this.columns)==null?void 0:h.treeDepth)??-1)==n,s=this.generateSelectionCols();if(LI(s,((f=this.columns)==null?void 0:f.list)??[])&&o)return;r();const{colGroupSvc:l}=this.beans,c=(l==null?void 0:l.findDepth(e.tree))??0,u=(l==null?void 0:l.balanceTreeForAutoCols(s,c))??[];this.columns={list:s,tree:u,treeDepth:c,map:{}},t(g=>{if(!g)return null;const m=g.filter(p=>!xa(p));return[...s,...m]})}updateColumns(e){var r;const t=Ri(e.source);(r=this.columns)==null||r.list.forEach(n=>{const i=this.createSelectionColDef(e.currentValue);n.setColDef(i,null,t),cp(this.beans,{state:[{...i,colId:n.getColId()}]},t)})}getColumn(e){var t;return((t=this.columns)==null?void 0:t.list.find(r=>y1(r,e)))??null}getColumns(){var e;return((e=this.columns)==null?void 0:e.list)??null}isSelectionColumnEnabled(){var s,a;const{gos:e,beans:t}=this,r=e.get("rowSelection");if(typeof r!="object"||!In(e))return!1;const n=(((a=(s=t.autoColSvc)==null?void 0:s.getColumns())==null?void 0:a.length)??0)>0;if(r.checkboxLocation==="autoGroupColumn"&&n)return!1;const i=!!Ai(r),o=fl(r);return i||o}createSelectionColDef(e){const{gos:t}=this.beans,r=e??t.get("selectionColumnDef"),n=t.get("enableRtl"),{rowSpan:i,spanRows:o,...s}=r??{};return{width:50,resizable:!1,suppressHeaderMenuButton:!0,sortable:!1,suppressMovable:!0,lockPosition:n?"right":"left",comparator(a,l,c,u){const d=c.isSelected(),h=u.isSelected();return d===h?0:d?1:-1},editable:!1,suppressFillHandle:!0,pinned:null,...s,colId:p1,chartDataType:"excluded"}}generateSelectionCols(){if(!this.isSelectionColumnEnabled())return[];const e=this.createSelectionColDef(),t=e.colId;this.gos.validateColDef(e,t,!0);const r=new cu(e,null,t,!1);return this.createBean(r),[r]}onSelectionOptionsChanged(e,t,r){const n=t&&typeof t!="string"?Ai(t):void 0,i=e&&typeof e!="string"?Ai(e):void 0,o=n!==i,s=t&&typeof t!="string"?fl(t):void 0,a=e&&typeof e!="string"?fl(e):void 0,l=s!==a,c=Dl(e),u=Dl(t);(o||l||c!==u)&&this.beans.colModel.refreshAll(r)}destroy(){var e;Ll(this.beans,(e=this.columns)==null?void 0:e.tree),super.destroy()}refreshVisibility(e,t,r){var l,c;if(!((l=this.columns)!=null&&l.list.length))return;const n=e.length+t.length+r.length;if(n===0)return;const i=this.columns.list[0];if(!i.isVisible())return;const o=()=>{let u;switch(i.pinned){case"left":case!0:u=e;break;case"right":u=r;break;default:u=t}u&&Zt(u,i)};(((c=this.beans.rowNumbersSvc)==null?void 0:c.getColumn(m1))?2:1)===n&&o()}};function J$(e,t){var s;if(!t.nodes.every(a=>a.rowPinned&&!Ra(a)?(Q(59),!1):a.id===void 0?(Q(60),!1):!0))return;const{nodes:n,source:i,newValue:o}=t;(s=e.selectionSvc)==null||s.setNodesSelected({nodes:n,source:i??"api",newValue:o})}function X$(e,t,r="apiSelectAll"){var n;(n=e.selectionSvc)==null||n.selectAllRowNodes({source:r,selectAll:t})}function Z$(e,t,r="apiSelectAll"){var n;(n=e.selectionSvc)==null||n.deselectAllRowNodes({source:r,selectAll:t})}function Q$(e,t="apiSelectAllFiltered"){var r;(r=e.selectionSvc)==null||r.selectAllRowNodes({source:t,selectAll:"filtered"})}function e4(e,t="apiSelectAllFiltered"){var r;(r=e.selectionSvc)==null||r.deselectAllRowNodes({source:t,selectAll:"filtered"})}function t4(e,t="apiSelectAllCurrentPage"){var r;(r=e.selectionSvc)==null||r.selectAllRowNodes({source:t,selectAll:"currentPage"})}function r4(e,t="apiSelectAllCurrentPage"){var r;(r=e.selectionSvc)==null||r.deselectAllRowNodes({source:t,selectAll:"currentPage"})}function n4(e){var t;return((t=e.selectionSvc)==null?void 0:t.getSelectedNodes())??[]}function i4(e){var t;return((t=e.selectionSvc)==null?void 0:t.getSelectedRows())??[]}var o4=class extends Z3{constructor(){super(...arguments),this.beanName="selectionSvc",this.selectedNodes=new Map,this.detailSelection=new Map,this.masterSelectsDetail=!1}postConstruct(){super.postConstruct();const{gos:e}=this;this.mode=kl(e),this.groupSelectsDescendants=Ts(e),this.groupSelectsFiltered=_l(e)==="filteredDescendants",this.masterSelectsDetail=Pv(e)==="detail",this.addManagedPropertyListeners(["groupSelectsChildren","groupSelectsFiltered","rowSelection"],()=>{const t=Ts(e),r=kl(e),n=_l(e)==="filteredDescendants";this.masterSelectsDetail=Pv(e)==="detail",(t!==this.groupSelectsDescendants||n!==this.groupSelectsFiltered||r!==this.mode)&&(this.deselectAllRowNodes({source:"api"}),this.groupSelectsDescendants=t,this.groupSelectsFiltered=n,this.mode=r)}),this.addManagedEventListeners({rowSelected:this.onRowSelected.bind(this)})}destroy(){super.destroy(),this.resetNodes()}handleSelectionEvent(e,t,r){if(this.isRowSelectionBlocked(t))return 0;const n=this.inferNodeSelections(t,e.shiftKey,e.metaKey||e.ctrlKey,r);return n==null?0:(this.selectionCtx.selectAll=!1,"select"in n?(n.reset?this.resetNodes():this.selectRange(n.deselect,!1,r),this.selectRange(n.select,!0,r)):this.setNodesSelected({nodes:[n.node],newValue:n.newValue,clearSelection:n.clearSelection,keepDescendants:n.keepDescendants,event:e,source:r}))}setNodesSelected({newValue:e,clearSelection:t,suppressFinishActions:r,nodes:n,event:i,source:o,keepDescendants:s=!1}){var l;if(!In(this.gos)&&e)return Q(132),0;if(n.length===0)return 0;if(n.length>1&&!this.isMultiSelect())return Q(130),0;let a=0;for(let c=0;c<n.length;c++){const u=n[c],d=ui(u),h=this.groupSelectsFiltered&&d.group;if(d.rowPinned&&!Ra(d)){Q(59);continue}if(d.id===void 0){Q(60);continue}h||this.selectRowNode(d,e,i,o)&&(this.detailSelection.delete(d.id),a++),this.groupSelectsDescendants&&((l=d.childrenAfterGroup)!=null&&l.length)&&(a+=this.selectChildren(d,e,o))}return r||(n.length===1&&o==="api"&&this.selectionCtx.setRoot(ui(n[0])),e&&(t||!this.isMultiSelect())&&(a+=this.clearOtherNodes(ui(n[0]),s,o)),a>0&&(this.updateGroupsFromChildrenSelections(o),this.dispatchSelectionChanged(o))),a}selectRange(e,t,r){let n=0;return e.forEach(i=>{const o=ui(i);if(o.group&&this.groupSelectsDescendants)return;this.selectRowNode(o,t,void 0,r)&&n++}),n>0&&(this.updateGroupsFromChildrenSelections(r),this.dispatchSelectionChanged(r)),n}selectChildren(e,t,r){const n=this.groupSelectsFiltered?e.childrenAfterAggFilter:e.childrenAfterGroup;return n?this.setNodesSelected({newValue:t,clearSelection:!1,suppressFinishActions:!0,source:r,nodes:n}):0}getSelectedNodes(){return Array.from(this.selectedNodes.values())}getSelectedRows(){const e=[];return this.selectedNodes.forEach(t=>e.push(t.data)),e}getSelectionCount(){return this.selectedNodes.size}filterFromSelection(e){const t=new Map;this.selectedNodes.forEach((r,n)=>{e(r)&&t.set(n,r)}),this.selectedNodes=t}updateGroupsFromChildrenSelections(e,t){if(!this.groupSelectsDescendants)return!1;const{gos:r,rowModel:n}=this.beans;if(!xt(r))return!1;const i=n.rootNode;if(!i)return!1;t||(t=new Wl(!0,i),t.active=!1);let o=!1;return t.forEachChangedNodeDepthFirst(s=>{if(s!==i){const a=this.calculateSelectedFromChildren(s);o=this.selectRowNode(s,a===null?!1:a,void 0,e)||o}}),o}clearOtherNodes(e,t,r){const n=new Map;let i=0;return this.selectedNodes.forEach(o=>{const s=o.id==e.id;if((t?!a4(e,o):!0)&&!s){const l=this.selectedNodes.get(o.id);i+=this.setNodesSelected({nodes:[l],newValue:!1,clearSelection:!1,suppressFinishActions:!0,source:r}),this.groupSelectsDescendants&&o.parent&&n.set(o.parent.id,o.parent)}}),n.forEach(o=>{const s=this.calculateSelectedFromChildren(o);this.selectRowNode(o,s===null?!1:s,void 0,r)}),i}onRowSelected(e){const t=e.node;this.groupSelectsDescendants&&t.group||(t.isSelected()?this.selectedNodes.set(t.id,t):this.selectedNodes.delete(t.id))}syncInRowNode(e,t){this.syncInOldRowNode(e,t),this.syncInNewRowNode(e)}createDaemonNode(e){if(!e.id)return;const t=new Yn(this.beans);return t.id=e.id,t.data=e.data,t.__daemon=!0,t.__selected=e.__selected,t.level=e.level,t}syncInOldRowNode(e,t){t&&e.id!==t.id&&this.selectedNodes.get(t.id)==e&&this.selectedNodes.set(t.id,t)}syncInNewRowNode(e){this.selectedNodes.has(e.id)?(e.__selected=!0,this.selectedNodes.set(e.id,e)):e.__selected=!1}reset(e){const t=this.getSelectionCount();this.resetNodes(),t&&this.dispatchSelectionChanged(e)}resetNodes(){this.selectedNodes.forEach(e=>{this.selectRowNode(e,!1)}),this.selectedNodes.clear()}getBestCostNodeSelection(){const{gos:e,rowModel:t}=this.beans;if(!xt(e))return;const r=t.getTopLevelNodes();if(r===null)return;const n=[];function i(o){for(let s=0,a=o.length;s<a;s++){const l=o[s];l.isSelected()?n.push(l):l.group&&l.childrenAfterGroup&&i(l.childrenAfterGroup)}}return i(r),n}isEmpty(){return this.getSelectionCount()===0}deselectAllRowNodes({source:e,selectAll:t}){const r=xt(this.gos);let n=!1;const i=o=>{const s=this.selectRowNode(ui(o),!1,void 0,e);n||(n=s)};if(t==="currentPage"||t==="filtered"){if(!r){_e(102);return}this.getNodesToSelect(t).forEach(i)}else this.selectedNodes.forEach(i),this.reset(e);if(this.selectionCtx.selectAll=!1,r&&this.groupSelectsDescendants){const o=this.updateGroupsFromChildrenSelections(e);n||(n=o)}n&&this.dispatchSelectionChanged(e)}getSelectedCounts(e){let t=0,r=0;return this.getNodesToSelect(e).forEach(n=>{this.groupSelectsDescendants&&n.group||(n.isSelected()?t++:n.selectable&&r++)}),{selectedCount:t,notSelectedCount:r}}getSelectAllState(e){const{selectedCount:t,notSelectedCount:r}=this.getSelectedCounts(e);return WS(t,r)??null}hasNodesToSelect(e){return this.getNodesToSelect(e).filter(t=>t.selectable).length>0}getNodesToSelect(e){if(!this.canSelectAll())return[];const t=[],r=i=>t.push(i);if(e==="currentPage")return this.forEachNodeOnPage(i=>{if(!i.group){r(i);return}if(!i.expanded&&!i.footer){const o=s=>{var a;r(s),(a=s.childrenAfterFilter)==null||a.forEach(o)};o(i);return}this.groupSelectsDescendants||r(i)}),t;const n=this.beans.rowModel;return e==="filtered"?(n.forEachNodeAfterFilter(r),t):(n.forEachNode(r),t)}forEachNodeOnPage(e){const{pageBounds:t,rowModel:r}=this.beans,n=t.getFirstRow(),i=t.getLastRow();for(let o=n;o<=i;o++){const s=r.getRow(o);s&&e(s)}}selectAllRowNodes(e){const{gos:t,selectionCtx:r}=this;if(!In(t)){Q(132);return}if(dI(t)&&!Il(t)){Q(130);return}if(!this.canSelectAll())return;const{source:n,selectAll:i}=e;let o=!1;if(this.getNodesToSelect(i).forEach(s=>{const a=this.selectRowNode(ui(s),!0,void 0,n);o||(o=a)}),r.selectAll=!0,xt(t)&&this.groupSelectsDescendants){const s=this.updateGroupsFromChildrenSelections(n);o||(o=s)}o&&this.dispatchSelectionChanged(n)}getSelectionState(){return this.isEmpty()?null:Array.from(this.selectedNodes.keys())}setSelectionState(e,t){if(!Array.isArray(e)){_e(103);return}const r=new Set(e),n=[];this.beans.rowModel.forEachNode(i=>{r.has(i.id)&&n.push(i)}),this.setNodesSelected({newValue:!0,nodes:n,source:t})}canSelectAll(){const{gos:e}=this.beans;return!!xt(e)}updateSelectable(e){var l;const{gos:t,rowModel:r}=this.beans;if(!In(t))return;const n="selectableChanged",i=e!==void 0,o=xt(t)&&this.groupSelectsDescendants,s=[],a=c=>{var d;if(i&&!c.group)return;if(o&&c.group){const h=((d=c.childrenAfterGroup)==null?void 0:d.some(f=>f.selectable))??!1;this.setRowSelectable(c,h,!0);return}!this.updateRowSelectable(c,!0)&&c.isSelected()&&s.push(c)};if(o){if(e===void 0){const c=r.rootNode;e=c?new Wl(!1,c):void 0}e==null||e.forEachChangedNodeDepthFirst(a,!i,!i)}else r.forEachNode(a);s.length&&this.setNodesSelected({nodes:s,newValue:!1,source:n}),!i&&o&&((l=this.updateGroupsFromChildrenSelections)==null||l.call(this,n))}updateSelectableAfterGrouping(e){var t;this.updateSelectable(e),this.groupSelectsDescendants&&((t=this.updateGroupsFromChildrenSelections)!=null&&t.call(this,"rowGroupChanged",e))&&this.dispatchSelectionChanged("rowGroupChanged")}refreshMasterNodeState(e,t){var o,s;if(!this.masterSelectsDetail)return;const r=(s=(o=e.detailNode)==null?void 0:o.detailGridInfo)==null?void 0:s.api;if(!r)return;const n=s4(r);if(e.isSelected()!==n&&this.selectRowNode(e,n,t,"masterDetail")&&this.dispatchSelectionChanged("masterDetail"),!n){const a=this.detailSelection.get(e.id)??new Set;for(const l of r.getSelectedNodes())a.add(l.id);this.detailSelection.set(e.id,a)}}setDetailSelectionState(e,t,r){if(this.masterSelectsDetail){if(!Il(t)){Q(269);return}switch(e.isSelected()){case!0:{r.selectAll();break}case!1:{r.deselectAll();break}case void 0:{const n=this.detailSelection.get(e.id);if(n){const i=[];for(const o of n){const s=r.getRowNode(o);s&&i.push(s)}r.setNodesSelected({nodes:i,newValue:!0,source:"masterDetail"})}break}}}}dispatchSelectionChanged(e){this.eventSvc.dispatchEvent({type:"selectionChanged",source:e,selectedNodes:this.getSelectedNodes(),serverSideState:null})}};function ui(e){return Ra(e)?e.pinnedSibling:e.footer?e.sibling:e}function s4(e){let t=0,r=0;return e.forEachNode(n=>{n.isSelected()?t++:n.selectable&&r++}),WS(t,r)}function WS(e,t){if(e===0&&t===0)return!1;if(!(e>0&&t>0))return e>0}function a4(e,t){let r=t.parent;for(;r;){if(r===e)return!0;r=r.parent}return!1}var l4={moduleName:"SharedRowSelection",version:he,beans:[Y$],apiFunctions:{setNodesSelected:J$,selectAll:X$,deselectAll:Z$,selectAllFiltered:Q$,deselectAllFiltered:e4,selectAllOnCurrentPage:t4,deselectAllOnCurrentPage:r4,getSelectedNodes:n4,getSelectedRows:i4}},c4={moduleName:"RowSelection",version:he,rowModels:["clientSide","infinite","viewport"],beans:[o4],dependsOn:[l4]};function u4(e,t,r){var o;const n=o$(e);if(n){if(((o=e.rowGroupColsSvc)==null?void 0:o.columns.length)===0){if(t<0){_e(238);return}n.setRowCount(t,r);return}_e(28);return}const i=fu(e);if(i){i.setRowCount(t,r);return}}function d4(e){var t;return po(e.gos)?e.rowModel.getBlockStates():((t=e.rowNodeBlockLoader)==null?void 0:t.getBlockState())??{}}function h4(e){return e.rowModel.isLastRowIndexKnown()}var f4={moduleName:"SsrmInfiniteSharedApi",version:he,apiFunctions:{setRowCount:u4,getCacheBlockState:d4,isLastRowIndexKnown:h4}},g4=class extends K3{constructor(){super(...arguments),this.beanName="csrmNodeSvc"}},Md=class{constructor(){this.removals=new Set,this.updates=new Set,this.adds=new Set}remove(e){this.adds.delete(e)||(this.updates.delete(e),this.removals.add(e))}update(e){this.adds.has(e)||this.updates.add(e)}add(e){this.adds.add(e)}};function p4(e){if(Xe(e.childrenAfterSort))return;const t=e.childrenAfterSort;for(let r=0;r<t.length;r++){const n=t[r],i=r===0,o=r===e.childrenAfterSort.length-1;n.setFirstChild(i),n.lastChild!==o&&(n.lastChild=o,n.dispatchRowEvent("lastChildChanged")),n.childIndex!==r&&(n.childIndex=r,n.dispatchRowEvent("childIndexChanged"))}}function jS(e){e.sibling&&(e.sibling.childrenAfterSort=e.childrenAfterSort),p4(e)}var m4=class extends q{constructor(){super(...arguments),this.beanName="sortStage",this.refreshProps=new Set(["postSortRows","groupDisplayType","accentedSort"]),this.step="sort"}execute(e){const t=this.beans,r=t.sortSvc.getSortOptions(),n=ie(r)&&r.length>0,i=n&&!!e.changedRowNodes&&this.gos.get("deltaSort"),o=r.some(({column:s})=>gr(t.gos)?s.isPrimary()&&s.isRowGroupActive():!!s.getColDef().showRowGroup);this.sort(t,r,n,i,e.changedRowNodes,e.changedPath,o)}sort(e,t,r,n,i,o,s){const{gos:a,colModel:l,rowGroupColsSvc:c,rowNodeSorter:u,rowRenderer:d,showRowGroupCols:h}=e,f=a.get("groupMaintainOrder"),g=l.getCols().some(b=>b.isRowGroupActive()),m=l.isPivotMode(),p=a.getCallback("postSortRows");let y=!1;const w=b=>{var A,P;const x=m&&b.leafGroup,C=f&&g&&!b.leafGroup&&!s;let S;if(C){const E=(A=c==null?void 0:c.columns)==null?void 0:A[b.level+1],O=(E==null?void 0:E.getSort())===null,R=b.childrenAfterAggFilter.slice(0);if(b.childrenAfterSort&&!O){const T={};b.childrenAfterSort.forEach((F,I)=>{T[F.id]=I}),R.sort((F,I)=>(T[F.id]??0)-(T[I.id]??0))}S=R}else!r||x?S=b.childrenAfterAggFilter.slice(0):n&&i?S=v4(u,b,i,o,t):S=u.doFullSort(b.childrenAfterAggFilter,t);if(y||(y=((P=b.childrenAfterSort)==null?void 0:P[0])!==S[0]),b.childrenAfterSort=S,jS(b),p){const E={nodes:b.childrenAfterSort};p(E)}};if(o==null||o.forEachChangedNodeDepthFirst(w),y&&this.gos.get("groupHideOpenParents")){const b=h==null?void 0:h.getShowRowGroupCols();b!=null&&b.length&&d.refreshCells({columns:b,force:!0})}}};function v4(e,t,r,n,i){const o=t.childrenAfterAggFilter,s=t.childrenAfterSort;if(!s)return e.doFullSort(o,i);const a=new Set,l=[],{updates:c,adds:u}=r;for(let h=0,f=o.length;h<f;++h){const g=o[h];c.has(g)||u.has(g)||n&&!n.canSkip(g)?l.push({currentPos:l.length,rowNode:g}):a.add(g.id)}const d=s.filter(h=>a.has(h.id)).map((h,f)=>({currentPos:f,rowNode:h}));return l.sort((h,f)=>e.compareRowNodes(i,h,f)),y4(e,i,l,d)}function y4(e,t,r,n){const i=[];let o=0,s=0;const a=r.length,l=n.length;for(;o<a&&s<l;){const c=r[o],u=n[s],d=e.compareRowNodes(t,c,u);let h;d<0?(h=c,++o):(h=u,++s),i.push(h.rowNode)}for(;o<a;)i.push(r[o++].rowNode);for(;s<l;)i.push(n[s++].rowNode);return i}var b4=class extends q{constructor(){super(...arguments),this.beanName="rowModel",this.rootNode=null,this.rowsToDisplay=[],this.lastHighlightedRow=null,this.started=!1,this.isRefreshingModel=!1,this.rowNodesCountReady=!1,this.rowCountReady=!1,this.onRowHeightChanged_debounced=kr(this,this.onRowHeightChanged.bind(this),100)}wireBeans(e){this.colModel=e.colModel,this.valueCache=e.valueCache,this.filterStage=e.filterStage,this.sortStage=e.sortStage,this.flattenStage=e.flattenStage,this.groupStage=e.groupStage,this.aggStage=e.aggStage,this.pivotStage=e.pivotStage,this.filterAggStage=e.filterAggStage}postConstruct(){this.orderedStages=[this.groupStage,this.filterStage,this.pivotStage,this.aggStage,this.sortStage,this.filterAggStage,this.flattenStage].filter(n=>!!n);const e=this.refreshModel.bind(this,{step:"group"}),t=this.refreshModel.bind(this,{step:"group",afterColumnsChanged:!0,keepRenderedRows:!0,animate:!this.gos.get("suppressAnimationFrame")});this.addManagedEventListeners({newColumnsLoaded:t,columnRowGroupChanged:e,columnValueChanged:this.onValueChanged.bind(this),columnPivotChanged:this.refreshModel.bind(this,{step:"pivot"}),filterChanged:this.onFilterChanged.bind(this),sortChanged:this.onSortChanged.bind(this),columnPivotModeChanged:e,gridStylesChanged:this.onGridStylesChanges.bind(this),gridReady:this.onGridReady.bind(this)}),this.addPropertyListeners(),this.rootNode=new Yn(this.beans);const r=this.getNewNodeManager();this.nodeManager=r,r.activate(this.rootNode)}getNewNodeManager(){const{gos:e,beans:t}=this;switch(bI(e)){case"treeNested":return t.csrmChildrenTreeNodeSvc??t.csrmNodeSvc;case"treePath":return t.csrmPathTreeNodeSvc??t.csrmNodeSvc;default:return t.csrmNodeSvc}}addPropertyListeners(){const e=["treeData","treeDataChildrenField",...this.orderedStages.flatMap(({refreshProps:t})=>[...t])];this.addManagedPropertyListeners(e,t=>{var n;const r=(n=t.changeSet)==null?void 0:n.properties;r&&this.onPropChange(r)}),this.addManagedPropertyListener("rowData",()=>this.onPropChange(["rowData"])),this.addManagedPropertyListener("rowHeight",()=>this.resetRowHeights())}start(){this.started=!0,this.rowNodesCountReady?this.refreshModel({step:"group",rowDataUpdated:!0,newData:!0}):this.setInitialData()}setInitialData(){this.gos.get("rowData")&&this.onPropChange(["rowData"])}ensureRowHeightsValid(e,t,r,n){let i,o=!1;do{i=!1;const s=this.getRowIndexAtPixel(e),a=this.getRowIndexAtPixel(t),l=Math.max(s,r),c=Math.min(a,n);for(let u=l;u<=c;u++){const d=this.getRow(u);if(d.rowHeightEstimated){const h=Un(this.beans,d);d.setRowHeight(h.height),i=!0,o=!0}}i&&this.setRowTopAndRowIndex()}while(i);return o}onPropChange(e){if(!this.rootNode)return;const t=this.gos,r=new Set(e),n={step:"nothing",changedProps:r},i=r.has("rowData"),o=this.nodeManager,s=this.getNewNodeManager(),a=o!==s||i&&r.has("treeData")&&t.get("treeData")||r.has("treeDataChildrenField")&&t.get("treeData");let l;if((a||i)&&(l=t.get("rowData"),l!=null&&!Array.isArray(l)&&(l=null,Q(1))),a&&(i||(l=(o==null?void 0:o.extractRowData())??l),o!==s&&(o==null||o.deactivate(),this.nodeManager=s),s.activate(this.rootNode)),l)if(!a&&!this.isEmpty()&&l.length>0&&t.exists("getRowId")&&!t.get("resetRowDataOnUpdate"))n.keepRenderedRows=!0,n.animate=!this.gos.get("suppressAnimationFrame"),n.changedRowNodes=new Md,s.setImmutableRowData(n,l);else{n.rowDataUpdated=!0,n.newData=!0;const{selectionSvc:u,pinnedRowModel:d}=this.beans;u==null||u.reset("rowDataChanged"),d!=null&&d.isManual()&&d.reset(),this.rowNodesCountReady=!0,s.setNewRowData(l)}if(n.rowDataUpdated)n.step="group";else if(n.step==="nothing"){for(const{refreshProps:c,step:u}of this.orderedStages)if(e.some(d=>c.has(d))){n.step=u;break}}n.step!=="nothing"&&this.refreshModel(n)}setRowTopAndRowIndex(){const{beans:e,rowsToDisplay:t}=this,r=e.environment.getDefaultRowHeight();let n=0;const i=new Set,o=pt(this.gos,"normal");for(let s=0,a=t.length;s<a;++s){const l=t[s];if(l.id!=null&&i.add(l.id),l.rowHeight==null){const c=Un(e,l,o,r);l.setRowHeight(c.height,c.estimated)}l.setRowTop(n),l.setRowIndex(s),n+=l.rowHeight}return i}clearRowTopAndRowIndex(e,t){const r=e.active,n=o=>{o&&o.id!=null&&!t.has(o.id)&&o.clearRowTopAndRowIndex()},i=o=>{if(o!==null&&(n(o),n(o.detailNode),n(o.sibling),o.hasChildren()&&o.childrenAfterGroup)){const s=o.level==-1;r&&!s&&!o.expanded||o.childrenAfterGroup.forEach(i)}};i(this.rootNode)}clearHighlight(){const e=this.lastHighlightedRow;e&&(e.highlighted=null,e.dispatchRowEvent("rowHighlightChanged"),this.lastHighlightedRow=null)}highlightRow(e,t){const r=e!==this.lastHighlightedRow,n=t!==e.highlighted;(r||n)&&(r&&this.clearHighlight(),e.highlighted=t,e.dispatchRowEvent("rowHighlightChanged"),this.lastHighlightedRow=e)}getLastHighlightedRowNode(){return this.lastHighlightedRow}isLastRowIndexKnown(){return!0}getRowCount(){return this.rowsToDisplay?this.rowsToDisplay.length:0}getTopLevelRowCount(){const e=this.rootNode;if(!e||this.rowsToDisplay.length===0)return 0;if(this.rowsToDisplay&&this.rowsToDisplay[0]===e)return 1;const r=e.childrenAfterAggFilter,n=e.sibling?1:0;return(r?r.length:0)+n}getTopLevelRowDisplayedIndex(e){const{rootNode:t,rowsToDisplay:r}=this;if(!t||!r.length||r[0]===t)return e;const{childrenAfterSort:i}=t,o=a=>{let l=i[a];if(this.gos.get("groupHideOpenParents"))for(;l.expanded&&l.childrenAfterSort&&l.childrenAfterSort.length>0;)l=l.childrenAfterSort[0];return l.rowIndex},{footerSvc:s}=this.beans;return s?s.getTopDisplayIndex(r,e,i,o):o(e)}getTopLevelIndexFromDisplayedIndex(e){var s;const{rootNode:t,rowsToDisplay:r}=this;if(!t||!r.length||r[0]===t)return e;let i=this.getRow(e);for(i.footer&&(i=i.sibling);i.parent&&i.parent!==t;)i=i.parent;const o=(s=t.childrenAfterSort)==null?void 0:s.findIndex(a=>a===i);return o===-1?e:o??e}getRowBounds(e){const t=this.rowsToDisplay[e];return t?{rowTop:t.rowTop,rowHeight:t.rowHeight}:null}onRowGroupOpened(){const e=xi(this.gos);this.refreshModel({step:"map",keepRenderedRows:!0,animate:e})}onFilterChanged(e){if(e.afterDataChange)return;const t=xi(this.gos),n=e.columns.length===0||e.columns.some(i=>i.isPrimary())?"filter":"filter_aggregates";this.refreshModel({step:n,keepRenderedRows:!0,animate:t})}onSortChanged(){const e=xi(this.gos);this.refreshModel({step:"sort",keepRenderedRows:!0,animate:e})}getType(){return"clientSide"}onValueChanged(){this.refreshModel({step:this.colModel.isPivotActive()?"pivot":"aggregate"})}createChangePath(e){const t=new Wl(!1,this.rootNode);return e||(t.active=!1),t}isSuppressModelUpdateAfterUpdateTransaction(e){if(!this.gos.get("suppressModelUpdateAfterUpdateTransaction"))return!1;const{changedRowNodes:t,newData:r,rowDataUpdated:n}=e;return!(!t||r||!n||t.removals.size||t.adds.size)}refreshModel(e){var n,i;if(!this.rootNode)return;const t=e.changedPath??(e.changedPath=this.createChangePath(!e.newData&&!!e.rowDataUpdated));if((i=(n=this.nodeManager).refreshModel)==null||i.call(n,e,this.started),this.eventSvc.dispatchEvent({type:"beforeRefreshModel",params:e}),!this.started||(e.rowDataUpdated&&this.eventSvc.dispatchEvent({type:"rowDataUpdated"}),this.isRefreshingModel||this.colModel.changeEventsDispatching||this.isSuppressModelUpdateAfterUpdateTransaction(e)))return;switch(this.isRefreshingModel=!0,e.step){case"group":this.doRowGrouping(e.changedRowNodes,t,!!e.rowNodesOrderChanged,!!e.afterColumnsChanged);case"filter":this.doFilter(t);case"pivot":this.doPivot(t);case"aggregate":this.doAggregate(t);case"filter_aggregates":this.doFilterAggregates(t);case"sort":this.doSort(e.changedRowNodes,t);case"map":this.doRowsToDisplay()}const r=this.setRowTopAndRowIndex();this.clearRowTopAndRowIndex(t,r),this.isRefreshingModel=!1,this.eventSvc.dispatchEvent({type:"modelUpdated",animate:e.animate,keepRenderedRows:e.keepRenderedRows,newData:e.newData,newPage:!1,keepUndoRedoStack:e.keepUndoRedoStack})}isEmpty(){var e,t,r;return!((t=(e=this.rootNode)==null?void 0:e.allLeafChildren)!=null&&t.length)||!((r=this.colModel)!=null&&r.ready)}isRowsToRender(){return this.rowsToDisplay.length>0}getNodesInRangeForSelection(e,t){let r=!1,n=!1;const i=[],o=Ts(this.gos);return this.forEachNodeAfterFilterAndSort(s=>{if(n)return;if(r&&(s===t||s===e)&&(n=!0,s.group&&o)){i.push(...s.allLeafChildren);return}if(!r){if(s!==t&&s!==e)return;r=!0}if(!s.group||!o){i.push(s);return}}),i}getTopLevelNodes(){var e;return((e=this.rootNode)==null?void 0:e.childrenAfterGroup)??null}getRow(e){return this.rowsToDisplay[e]}isRowPresent(e){return this.rowsToDisplay.indexOf(e)>=0}getRowIndexAtPixel(e){const t=this.rowsToDisplay;if(this.isEmpty()||t.length===0)return-1;let r=0,n=t.length-1;if(e<=0)return 0;if(Ee(t).rowTop<=e)return t.length-1;let o=-1,s=-1;for(;;){const a=Math.floor((r+n)/2),l=t[a];if(this.isRowInPixel(l,e)||(l.rowTop<e?r=a+1:l.rowTop>e&&(n=a-1),o===r&&s===n))return a;o=r,s=n}}isRowInPixel(e,t){const r=e.rowTop,n=e.rowTop+e.rowHeight;return r<=t&&n>t}forEachLeafNode(e){var t,r;(r=(t=this.rootNode)==null?void 0:t.allLeafChildren)==null||r.forEach((n,i)=>e(n,i))}forEachNode(e,t=!1){this.depthFirstSearchRowNodes(e,t)}forEachDisplayedNode(e){this.rowsToDisplay.forEach(e)}forEachNodeAfterFilter(e,t=!1){this.depthFirstSearchRowNodes(e,t,r=>r.childrenAfterAggFilter)}forEachNodeAfterFilterAndSort(e,t=!1){this.depthFirstSearchRowNodes(e,t,r=>r.childrenAfterSort)}forEachPivotNode(e,t=!1,r=!1){const{colModel:n,rowGroupColsSvc:i}=this.beans;if(!n.isPivotMode())return;if(!(i!=null&&i.columns.length)){e(this.rootNode,0);return}const o=r?"childrenAfterSort":"childrenAfterGroup";this.depthFirstSearchRowNodes(e,t,s=>s.leafGroup?null:s[o])}depthFirstSearchRowNodes(e,t=!1,r=o=>o.childrenAfterGroup,n=this.rootNode,i=0){let o=i;if(!n)return o;const s=n===this.rootNode;s||e(n,o++);const{footerSvc:a}=this.beans;if(n.hasChildren()&&!n.footer){const l=r(n);if(l){o=(a==null?void 0:a.addTotalRows(o,n,e,t,s,"top"))??o;for(const c of l)o=this.depthFirstSearchRowNodes(e,t,r,c,o);return(a==null?void 0:a.addTotalRows(o,n,e,t,s,"bottom"))??o}}return o}doAggregate(e){var r;const t=this.rootNode;t&&((r=this.aggStage)==null||r.execute({rowNode:t,changedPath:e}))}doFilterAggregates(e){const t=this.rootNode;this.filterAggStage?this.filterAggStage.execute({rowNode:t,changedPath:e}):t.childrenAfterAggFilter=t.childrenAfterFilter}doSort(e,t){this.sortStage?this.sortStage.execute({rowNode:this.rootNode,changedRowNodes:e,changedPath:t}):t.forEachChangedNodeDepthFirst(r=>{r.childrenAfterSort=r.childrenAfterAggFilter.slice(0),jS(r)})}doRowGrouping(e,t,r,n){var s;const i=this.rootNode;if(!((s=this.groupStage)==null?void 0:s.execute({rowNode:i,changedPath:t,changedRowNodes:e,rowNodesOrderChanged:r,afterColumnsChanged:n}))&&!this.nodeManager.treeData){const a=i.sibling;i.childrenAfterGroup=i.allLeafChildren,a&&(a.childrenAfterGroup=i.childrenAfterGroup),i.updateHasChildren()}this.rowNodesCountReady&&(this.rowCountReady=!0,this.eventSvc.dispatchEventOnce({type:"rowCountReady"}))}doFilter(e){this.filterStage?this.filterStage.execute({rowNode:this.rootNode,changedPath:e}):e.forEachChangedNodeDepthFirst(t=>{t.childrenAfterFilter=t.childrenAfterGroup,BS(t)},!0)}doPivot(e){var t;(t=this.pivotStage)==null||t.execute({rowNode:this.rootNode,changedPath:e})}getRowNode(e){if(typeof e=="string"&&e.indexOf(zh)==0){let r;return this.forEachNode(n=>{n.id===e&&(r=n)}),r}return this.nodeManager.getRowNode(e)}batchUpdateRowData(e,t){if(this.applyAsyncTransactionsTimeout==null){this.rowDataTransactionBatch=[];const r=this.gos.get("asyncTransactionWaitMillis");this.applyAsyncTransactionsTimeout=window.setTimeout(()=>{this.isAlive()&&this.executeBatchUpdateRowData()},r)}this.rowDataTransactionBatch.push({rowDataTransaction:e,callback:t})}flushAsyncTransactions(){this.applyAsyncTransactionsTimeout!=null&&(clearTimeout(this.applyAsyncTransactionsTimeout),this.executeBatchUpdateRowData())}executeBatchUpdateRowData(){var i,o;(i=this.valueCache)==null||i.onDataChanged();const e=[],t=[],r=new Md;let n=!1;(o=this.rowDataTransactionBatch)==null||o.forEach(s=>{this.rowNodesCountReady=!0;const{rowNodeTransaction:a,rowsInserted:l}=this.nodeManager.updateRowData(s.rowDataTransaction,r);l&&(n=!0),t.push(a),s.callback&&e.push(s.callback.bind(null,a))}),this.commitTransactions(n,r),e.length>0&&window.setTimeout(()=>{e.forEach(s=>s())},0),t.length>0&&this.eventSvc.dispatchEvent({type:"asyncTransactionsFlushed",results:t}),this.rowDataTransactionBatch=null,this.applyAsyncTransactionsTimeout=void 0}updateRowData(e){var i;(i=this.valueCache)==null||i.onDataChanged(),this.rowNodesCountReady=!0;const t=new Md,{rowNodeTransaction:r,rowsInserted:n}=this.nodeManager.updateRowData(e,t);return this.commitTransactions(n,t),r}commitTransactions(e,t){this.refreshModel({step:"group",rowDataUpdated:!0,rowNodesOrderChanged:e,keepRenderedRows:!0,animate:!this.gos.get("suppressAnimationFrame"),changedRowNodes:t,changedPath:this.createChangePath(!0)})}doRowsToDisplay(){const{flattenStage:e,rootNode:t}=this;let r;if(e)r=e.execute({rowNode:t});else{r=(t==null?void 0:t.childrenAfterSort)??[];for(const n of r)n.setUiLevel(0)}this.rowsToDisplay=r}onRowHeightChanged(){this.refreshModel({step:"map",keepRenderedRows:!0,keepUndoRedoStack:!0})}resetRowHeights(){const e=this.rootNode;if(!e)return;const t=this.resetRowHeightsForAllRowNodes();e.setRowHeight(e.rowHeight,!0),e.sibling&&e.sibling.setRowHeight(e.sibling.rowHeight,!0),t&&this.onRowHeightChanged()}resetRowHeightsForAllRowNodes(){let e=!1;return this.forEachNode(t=>{t.setRowHeight(t.rowHeight,!0);const r=t.detailNode;r&&r.setRowHeight(r.rowHeight,!0),t.sibling&&t.sibling.setRowHeight(t.sibling.rowHeight,!0),e=!0}),e}onGridStylesChanges(e){var t;if(e.rowHeightChanged){if((t=this.beans.rowAutoHeight)!=null&&t.active)return;this.resetRowHeights()}}onGridReady(){this.started||this.setInitialData()}isRowDataLoaded(){return this.rowCountReady}destroy(){super.destroy(),this.clearHighlight(),this.started=!1,this.rootNode=null,this.nodeManager=null,this.rowDataTransactionBatch=null,this.orderedStages=Tv,this.rowsToDisplay=Tv}onRowHeightChangedDebounced(){this.onRowHeightChanged_debounced()}},C4={moduleName:"ClientSideRowModel",version:he,rowModels:["clientSide"],beans:[g4,b4,m4],dependsOn:[_S]},w4=class extends q{constructor(e,t,r){super(),this.id=e,this.parentCache=t,this.params=r,this.state="needsLoading",this.version=0,this.startRow=e*r.blockSize,this.endRow=this.startRow+r.blockSize}load(){this.state="loading",this.loadFromDatasource()}setStateWaitingToLoad(){this.version++,this.state="needsLoading"}pageLoadFailed(e){this.isRequestMostRecentAndLive(e)&&(this.state="failed"),this.dispatchLocalEvent({type:"loadComplete"})}pageLoaded(e,t,r){this.successCommon(e,{rowData:t,rowCount:r})}isRequestMostRecentAndLive(e){const t=e===this.version,r=this.isAlive();return t&&r}successCommon(e,t){this.dispatchLocalEvent({type:"loadComplete"}),this.isRequestMostRecentAndLive(e)&&(this.state="loaded",this.processServerResult(t))}postConstruct(){this.rowNodes=[];const{params:{blockSize:e,rowHeight:t},startRow:r,beans:n,rowNodes:i}=this;for(let o=0;o<e;o++){const s=r+o,a=new Yn(n);a.setRowHeight(t),a.uiLevel=0,a.setRowIndex(s),a.setRowTop(t*s),i.push(a)}}getBlockStateJson(){const{id:e,startRow:t,endRow:r,state:n}=this;return{id:""+e,state:{blockNumber:e,startRow:t,endRow:r,pageStatus:n}}}setDataAndId(e,t,r){ie(t)?e.setDataAndId(t,r.toString()):e.setDataAndId(void 0,void 0)}loadFromDatasource(){const e=this.createLoadParams();if(Xe(this.params.datasource.getRows)){Q(90);return}window.setTimeout(()=>{this.params.datasource.getRows(e)},0)}createLoadParams(){const{startRow:e,endRow:t,version:r,params:{sortModel:n,filterModel:i},gos:o}=this;return{startRow:e,endRow:t,successCallback:this.pageLoaded.bind(this,r),failCallback:this.pageLoadFailed.bind(this,r),sortModel:n,filterModel:i,context:pe(o,{}).context}}forEachNode(e,t,r){this.rowNodes.forEach((n,i)=>{this.startRow+i<r&&e(n,t.value++)})}getRow(e,t=!1){t||(this.lastAccessed=this.params.lastAccessedSequence.value++);const r=e-this.startRow;return this.rowNodes[r]}processServerResult(e){const{rowNodes:t,beans:r}=this;t.forEach((i,o)=>{const s=e.rowData?e.rowData[o]:void 0;!i.id&&i.alreadyRendered&&s&&(t[o]=new Yn(r),t[o].setRowIndex(i.rowIndex),t[o].setRowTop(i.rowTop),t[o].setRowHeight(i.rowHeight),i.clearRowTopAndRowIndex()),this.setDataAndId(t[o],s,this.startRow+o)});const n=e.rowCount!=null&&e.rowCount>=0?e.rowCount:void 0;this.parentCache.pageLoaded(this,n)}destroy(){this.rowNodes.forEach(e=>{e.clearRowTopAndRowIndex()}),super.destroy()}},S4=2,x4=class extends q{constructor(e){super(),this.params=e,this.lastRowIndexKnown=!1,this.blocks={},this.blockCount=0,this.rowCount=e.initialRowCount}getRow(e,t=!1){const r=Math.floor(e/this.params.blockSize);let n=this.blocks[r];if(!n){if(t)return;n=this.createBlock(r)}return n.getRow(e)}createBlock(e){const t=this.params,r=this.createBean(new w4(e,this,t));return this.blocks[r.id]=r,this.blockCount++,this.purgeBlocksIfNeeded(r),t.rowNodeBlockLoader.addBlock(r),r}refreshCache(){if(this.blockCount==0){this.purgeCache();return}this.getBlocksInOrder().forEach(t=>t.setStateWaitingToLoad()),this.params.rowNodeBlockLoader.checkBlockToLoad()}destroy(){this.getBlocksInOrder().forEach(e=>this.destroyBlock(e)),super.destroy()}getRowCount(){return this.rowCount}isLastRowIndexKnown(){return this.lastRowIndexKnown}pageLoaded(e,t){this.isAlive()&&(Vn(this.gos,`InfiniteCache - onPageLoaded: page = ${e.id}, lastRow = ${t}`),this.checkRowCount(e,t),this.onCacheUpdated())}purgeBlocksIfNeeded(e){const t=this.getBlocksInOrder().filter(s=>s!=e),r=(s,a)=>a.lastAccessed-s.lastAccessed;t.sort(r);const n=this.params.maxBlocksInCache>0,i=n?this.params.maxBlocksInCache-1:null,o=S4-1;t.forEach((s,a)=>{const l=s.state==="needsLoading"&&a>=o,c=n?a>=i:!1;if(l||c){if(this.isBlockCurrentlyDisplayed(s)||this.isBlockFocused(s))return;this.removeBlockFromCache(s)}})}isBlockFocused(e){const t=this.beans.focusSvc.getFocusCellToUseAfterRefresh();if(!t||t.rowPinned!=null)return!1;const{startRow:r,endRow:n}=e;return t.rowIndex>=r&&t.rowIndex<n}isBlockCurrentlyDisplayed(e){const{startRow:t,endRow:r}=e;return this.beans.rowRenderer.isRangeInRenderedViewport(t,r-1)}removeBlockFromCache(e){e&&this.destroyBlock(e)}checkRowCount(e,t){if(typeof t=="number"&&t>=0)this.rowCount=t,this.lastRowIndexKnown=!0;else if(!this.lastRowIndexKnown){const{blockSize:r,overflowSize:n}=this.params,o=(e.id+1)*r+n;this.rowCount<o&&(this.rowCount=o)}}setRowCount(e,t){this.rowCount=e,ie(t)&&(this.lastRowIndexKnown=t),this.lastRowIndexKnown||this.rowCount%this.params.blockSize===0&&this.rowCount++,this.onCacheUpdated()}forEachNodeDeep(e){const t={value:0};this.getBlocksInOrder().forEach(r=>r.forEachNode(e,t,this.rowCount))}getBlocksInOrder(){const e=(r,n)=>r.id-n.id;return Object.values(this.blocks).sort(e)}destroyBlock(e){delete this.blocks[e.id],this.destroyBean(e),this.blockCount--,this.params.rowNodeBlockLoader.removeBlock(e)}onCacheUpdated(){this.isAlive()&&(this.destroyAllBlocksPastVirtualRowCount(),this.eventSvc.dispatchEvent({type:"storeUpdated"}))}destroyAllBlocksPastVirtualRowCount(){const e=[];this.getBlocksInOrder().forEach(t=>{t.id*this.params.blockSize>=this.rowCount&&e.push(t)}),e.length>0&&e.forEach(t=>this.destroyBlock(t))}purgeCache(){this.getBlocksInOrder().forEach(e=>this.removeBlockFromCache(e)),this.lastRowIndexKnown=!1,this.rowCount===0&&(this.rowCount=this.params.initialRowCount),this.onCacheUpdated()}getRowNodesInRange(e,t){const r=[];let n=-1,i=!1;const o={value:0};let s=!1;return this.getBlocksInOrder().forEach(l=>{if(!s){if(i&&n+1!==l.id){s=!0;return}n=l.id,l.forEachNode(c=>{const u=c===e||c===t;(i||u)&&r.push(c),u&&(i=!i)},o,this.rowCount)}}),s||i?[]:r}},A4=class extends q{constructor(){super(...arguments),this.beanName="rowModel"}getRowBounds(e){return{rowHeight:this.rowHeight,rowTop:this.rowHeight*e}}ensureRowHeightsValid(){return!1}postConstruct(){this.gos.get("rowModelType")==="infinite"&&(this.rowHeight=as(this.beans),this.addEventListeners(),this.addDestroyFunc(()=>this.destroyCache()))}start(){this.setDatasource(this.gos.get("datasource"))}destroy(){this.destroyDatasource(),super.destroy()}destroyDatasource(){this.datasource&&(this.destroyBean(this.datasource),this.beans.rowRenderer.datasourceChanged(),this.datasource=null)}addEventListeners(){this.addManagedEventListeners({filterChanged:this.reset.bind(this),sortChanged:this.reset.bind(this),newColumnsLoaded:this.onColumnEverything.bind(this),storeUpdated:this.dispatchModelUpdatedEvent.bind(this)}),this.addManagedPropertyListener("datasource",()=>this.setDatasource(this.gos.get("datasource"))),this.addManagedPropertyListener("cacheBlockSize",()=>this.resetCache()),this.addManagedPropertyListener("rowHeight",()=>{this.rowHeight=as(this.beans),this.cacheParams.rowHeight=this.rowHeight,this.updateRowHeights()})}onColumnEverything(){var t;let e;this.cacheParams?e=!sp(this.cacheParams.sortModel,((t=this.beans.sortSvc)==null?void 0:t.getSortModel())??[]):e=!0,e&&this.reset()}getType(){return"infinite"}setDatasource(e){this.destroyDatasource(),this.datasource=e,e&&this.reset()}isEmpty(){return!this.infiniteCache}isRowsToRender(){return!!this.infiniteCache}getNodesInRangeForSelection(e,t){var r;return((r=this.infiniteCache)==null?void 0:r.getRowNodesInRange(e,t))??[]}reset(){var r;if(!this.datasource)return;Rs(this.gos)!=null||(r=this.beans.selectionSvc)==null||r.reset("rowDataChanged"),this.resetCache()}dispatchModelUpdatedEvent(){this.eventSvc.dispatchEvent({type:"modelUpdated",newPage:!1,newPageSize:!1,newData:!1,keepRenderedRows:!0,animate:!1})}resetCache(){this.destroyCache();const e=this.beans,{filterManager:t,sortSvc:r,rowNodeBlockLoader:n,eventSvc:i,gos:o}=e;this.cacheParams={datasource:this.datasource,filterModel:(t==null?void 0:t.getFilterModel())??{},sortModel:(r==null?void 0:r.getSortModel())??[],rowNodeBlockLoader:n,initialRowCount:o.get("infiniteInitialRowCount"),maxBlocksInCache:o.get("maxBlocksInCache"),rowHeight:as(e),overflowSize:o.get("cacheOverflowSize"),blockSize:o.get("cacheBlockSize"),lastAccessedSequence:{value:0}},this.infiniteCache=this.createBean(new x4(this.cacheParams)),i.dispatchEventOnce({type:"rowCountReady"}),this.dispatchModelUpdatedEvent()}updateRowHeights(){this.forEachNode(e=>{e.setRowHeight(this.rowHeight),e.setRowTop(this.rowHeight*e.rowIndex)}),this.dispatchModelUpdatedEvent()}destroyCache(){this.infiniteCache=this.destroyBean(this.infiniteCache)}getRow(e){const t=this.infiniteCache;if(t&&!(e>=t.getRowCount()))return t.getRow(e)}getRowNode(e){let t;return this.forEachNode(r=>{r.id===e&&(t=r)}),t}forEachNode(e){var t;(t=this.infiniteCache)==null||t.forEachNodeDeep(e)}getTopLevelRowCount(){return this.getRowCount()}getTopLevelRowDisplayedIndex(e){return e}getRowIndexAtPixel(e){if(this.rowHeight!==0){const t=Math.floor(e/this.rowHeight),r=this.getRowCount()-1;return t>r?r:t}return 0}getRowCount(){return this.infiniteCache?this.infiniteCache.getRowCount():0}isRowPresent(e){return!!this.getRowNode(e.id)}refreshCache(){var e;(e=this.infiniteCache)==null||e.refreshCache()}purgeCache(){var e;(e=this.infiniteCache)==null||e.purgeCache()}isLastRowIndexKnown(){var e;return((e=this.infiniteCache)==null?void 0:e.isLastRowIndexKnown())??!1}setRowCount(e,t){var r;(r=this.infiniteCache)==null||r.setRowCount(e,t)}};function P4(e){var t;(t=fu(e))==null||t.refreshCache()}function R4(e){var t;(t=fu(e))==null||t.purgeCache()}function E4(e){var t;return(t=fu(e))==null?void 0:t.getRowCount()}var T4=class extends q{constructor(){super(...arguments),this.beanName="rowNodeBlockLoader",this.activeBlockLoadsCount=0,this.blocks=[],this.active=!0}postConstruct(){this.maxConcurrentRequests=uI(this.gos);const e=this.gos.get("blockLoadDebounceMillis");e&&e>0&&(this.checkBlockToLoadDebounce=kr(this,this.performCheckBlocksToLoad.bind(this),e))}addBlock(e){this.blocks.push(e),e.addEventListener("loadComplete",this.loadComplete.bind(this)),this.checkBlockToLoad()}removeBlock(e){Zt(this.blocks,e)}destroy(){super.destroy(),this.active=!1}loadComplete(){this.activeBlockLoadsCount--,this.checkBlockToLoad()}checkBlockToLoad(){this.checkBlockToLoadDebounce?this.checkBlockToLoadDebounce():this.performCheckBlocksToLoad()}performCheckBlocksToLoad(){if(!this.active)return;if(this.printCacheStatus(),this.maxConcurrentRequests!=null&&this.activeBlockLoadsCount>=this.maxConcurrentRequests){Vn(this.gos,"RowNodeBlockLoader - checkBlockToLoad: max loads exceeded");return}const e=this.maxConcurrentRequests!=null?this.maxConcurrentRequests-this.activeBlockLoadsCount:1,t=this.blocks.filter(r=>r.state==="needsLoading").slice(0,e);this.activeBlockLoadsCount+=t.length,t.forEach(r=>r.load()),this.printCacheStatus()}getBlockState(){const e={};return this.blocks.forEach(t=>{const{id:r,state:n}=t.getBlockStateJson();e[r]=n}),e}printCacheStatus(){Vn(this.gos,`RowNodeBlockLoader - printCacheStatus: activePageLoadsCount = ${this.activeBlockLoadsCount}, blocks = ${JSON.stringify(this.getBlockState())}`)}},F4={moduleName:"InfiniteRowModelCore",version:he,rowModels:["infinite"],beans:[A4,T4]},O4={moduleName:"InfiniteRowModel",version:he,apiFunctions:{refreshInfiniteCache:P4,purgeInfiniteCache:R4,getInfiniteRowCount:E4},dependsOn:[F4,f4]};function M4(e,t){var r,n;typeof t=="number"?(r=e.colAutosize)==null||r.sizeColumnsToFit(t,"api"):(n=e.colAutosize)==null||n.sizeColumnsToFitGridBody(t)}function D4(e,t,r){var n;(n=e.colAutosize)==null||n.autoSizeCols({colKeys:t,skipHeader:r,source:"api"})}function k4(e,t){var r;(r=e.colAutosize)==null||r.autoSizeAllColumns("api",t)}var I4=class extends q{constructor(){super(...arguments),this.beanName="colAutosize",this.timesDelayed=0,this.shouldQueueResizeOperations=!1,this.resizeOperationQueue=[]}postConstruct(){this.addManagedEventListeners({firstDataRendered:()=>this.onFirstDataRendered()})}autoSizeCols(e){if(this.shouldQueueResizeOperations){this.pushResizeOperation(()=>this.autoSizeCols(e));return}const{colKeys:t,skipHeader:r,skipHeaderGroups:n,stopAtGroup:i,source:o="api"}=e,{animationFrameSvc:s,renderStatus:a,colModel:l,autoWidthCalc:c,visibleCols:u}=this.beans;if(s==null||s.flushAllFrames(),this.timesDelayed<5&&a&&!a.areHeaderCellsRendered()){this.timesDelayed++,setTimeout(()=>{this.isAlive()&&this.autoSizeCols(e)});return}this.timesDelayed=0;const d=[];let h=-1;const f=r??this.gos.get("skipHeaderOnAutoSize"),g=n??f;for(;h!==0;){h=0;const m=[];t.forEach(p=>{if(!p)return;const y=l.getCol(p);if(!y||Pi(y)||d.indexOf(y)>=0)return;const w=c.getPreferredWidthForColumn(y,f);if(w>0){const b=_4(y,w);y.setActualWidth(b,o),d.push(y),h++}m.push(y)}),m.length&&u.refresh(o)}g||this.autoSizeColumnGroupsByColumns(t,o,i),Bi(this.eventSvc,d,!0,"autosizeColumns")}autoSizeColumn(e,t,r){e&&this.autoSizeCols({colKeys:[e],skipHeader:r,skipHeaderGroups:!0,source:t})}autoSizeColumnGroupsByColumns(e,t,r){const{colModel:n,ctrlsSvc:i}=this.beans,o=new Set;n.getColsForKeys(e).forEach(c=>{let u=c.getParent();for(;u&&u!=r;)u.isPadding()||o.add(u),u=u.getParent()});let a;const l=[];for(const c of o){for(const u of i.getHeaderRowContainerCtrls())if(a=u.getHeaderCtrlForColumn(c),a)break;a&&a.resizeLeafColumnsToFit(t)}return l}autoSizeAllColumns(e,t){if(this.shouldQueueResizeOperations){this.pushResizeOperation(()=>this.autoSizeAllColumns(e,t));return}const r=this.beans.visibleCols.allCols;this.autoSizeCols({colKeys:r,skipHeader:t,source:e})}addColumnAutosize(e,t){const r=this.gos.get("skipHeaderOnAutoSize"),n=()=>{this.autoSizeColumn(t,"uiColumnResized",r)};e.addEventListener("dblclick",n);const i=new wn(e);return i.addEventListener("doubleTap",n),()=>{e.removeEventListener("dblclick",n),i.removeEventListener("doubleTap",n),i.destroy()}}addColumnGroupResize(e,t,r){const n=this.gos.get("skipHeaderOnAutoSize"),i=()=>{const o=[];t.getDisplayedLeafColumns().forEach(a=>{a.getColDef().suppressAutoSize||o.push(a.getColId())}),o.length>0&&this.autoSizeCols({colKeys:o,skipHeader:n,stopAtGroup:t,source:"uiColumnResized"}),r()};return e.addEventListener("dblclick",i),()=>e.removeEventListener("dblclick",i)}sizeColumnsToFitGridBody(e,t){if(!this.isAlive())return;const{ctrlsSvc:r,scrollVisibleSvc:n}=this.beans,i=r.getGridBodyCtrl(),s=i.isVerticalScrollShowing()?n.getScrollbarWidth():0,l=As(i.eGridBody)-s;if(l>0){this.sizeColumnsToFit(l,"sizeColumnsToFit",!1,e);return}t===void 0?window.setTimeout(()=>{this.sizeColumnsToFitGridBody(e,100)},0):t===100?window.setTimeout(()=>{this.sizeColumnsToFitGridBody(e,500)},100):t===500?window.setTimeout(()=>{this.sizeColumnsToFitGridBody(e,-1)},500):Q(29)}sizeColumnsToFit(e,t="sizeColumnsToFit",r,n){var f;if(this.shouldQueueResizeOperations){this.pushResizeOperation(()=>this.sizeColumnsToFit(e,t,r,n));return}const i={};n&&((f=n==null?void 0:n.columnLimits)==null||f.forEach(({key:g,...m})=>{i[typeof g=="string"?g:g.getColId()]=m}));const o=this.beans.visibleCols.allCols;if(e<=0||!o.length||e===Mr(o)&&o.every(m=>{if(m.colDef.suppressSizeToFit)return!0;const p=i==null?void 0:i[m.getId()],y=(p==null?void 0:p.minWidth)??(n==null?void 0:n.defaultMinWidth),w=(p==null?void 0:p.maxWidth)??(n==null?void 0:n.defaultMaxWidth),b=m.getActualWidth();return(y==null||b>=y)&&(w==null||b<=w)}))return;const a=[],l=[];o.forEach(g=>{g.getColDef().suppressSizeToFit===!0?l.push(g):a.push(g)});const c=a.slice(0);let u=!1;const d=g=>{Zt(a,g),l.push(g)};for(a.forEach(g=>{g.resetActualWidth(t);const m=i==null?void 0:i[g.getId()],p=(m==null?void 0:m.minWidth)??(n==null?void 0:n.defaultMinWidth),y=(m==null?void 0:m.maxWidth)??(n==null?void 0:n.defaultMaxWidth),w=g.getActualWidth();typeof p=="number"&&w<p?g.setActualWidth(p,t,!0):typeof y=="number"&&w>y&&g.setActualWidth(y,t,!0)});!u;){u=!0;const g=e-Mr(l);if(g<=0)a.forEach(m=>{var y;const p=((y=i==null?void 0:i[m.getId()])==null?void 0:y.minWidth)??(n==null?void 0:n.defaultMinWidth);if(typeof p=="number"){m.setActualWidth(p,t,!0);return}m.setActualWidth(m.minWidth,t)});else{const m=g/Mr(a);let p=g;for(let y=a.length-1;y>=0;y--){const w=a[y],b=i==null?void 0:i[w.getId()],x=(b==null?void 0:b.minWidth)??(n==null?void 0:n.defaultMinWidth),C=(b==null?void 0:b.maxWidth)??(n==null?void 0:n.defaultMaxWidth),S=w.getMinWidth(),A=w.getMaxWidth(),P=typeof x=="number"&&x>S?x:S,E=typeof C=="number"&&C<A?C:A;let O=Math.round(w.getActualWidth()*m);O<P?(O=P,d(w),u=!1):O>E?(O=E,d(w),u=!1):y===0&&(O=p),w.setActualWidth(O,t,!0),p-=O}}}c.forEach(g=>{g.fireColumnWidthChangedEvent(t)});const h=this.beans.visibleCols;h.setLeftValues(t),h.updateBodyWidths(),!r&&Bi(this.eventSvc,c,!0,t)}applyAutosizeStrategy(){const e=this.gos.get("autoSizeStrategy");if(!e)return;const{type:t}=e;setTimeout(()=>{if(t==="fitGridWidth"){const{columnLimits:r,defaultMinWidth:n,defaultMaxWidth:i}=e,o=r==null?void 0:r.map(({colId:s,minWidth:a,maxWidth:l})=>({key:s,minWidth:a,maxWidth:l}));this.sizeColumnsToFitGridBody({defaultMinWidth:n,defaultMaxWidth:i,columnLimits:o})}else t==="fitProvidedWidth"&&this.sizeColumnsToFit(e.width,"sizeColumnsToFit")})}onFirstDataRendered(){const e=this.gos.get("autoSizeStrategy");if((e==null?void 0:e.type)!=="fitCellContents")return;const{colIds:t,skipHeader:r}=e;setTimeout(()=>{t?this.autoSizeCols({colKeys:t,skipHeader:r,source:"autosizeColumns"}):this.autoSizeAllColumns("autosizeColumns",r)})}processResizeOperations(){this.shouldQueueResizeOperations=!1,this.resizeOperationQueue.forEach(e=>e()),this.resizeOperationQueue=[]}pushResizeOperation(e){this.resizeOperationQueue.push(e)}destroy(){this.resizeOperationQueue.length=0,super.destroy()}};function _4(e,t){const r=e.getMinWidth();t<r&&(t=r);const n=e.getMaxWidth();return e.isGreaterThanMax(t)&&(t=n),t}var L4={moduleName:"ColumnAutoSize",version:he,beans:[I4],apiFunctions:{sizeColumnsToFit:M4,autoSizeColumns:D4,autoSizeAllColumns:k4},dependsOn:[hS]},B4=".ag-row-pinned-source{background-color:var(--ag-pinned-source-row-background-color);color:var(--ag-pinned-source-row-text-color);font-weight:var(--ag-pinned-source-row-font-weight)}.ag-row-pinned-manual{background-color:var(--ag-pinned-row-background-color);color:var(--ag-pinned-row-text-color);font-weight:var(--ag-pinned-row-font-weight)}";function z4(e){var t;return((t=e.pinnedRowModel)==null?void 0:t.getPinnedTopRowCount())??0}function N4(e){var t;return((t=e.pinnedRowModel)==null?void 0:t.getPinnedBottomRowCount())??0}function $4(e,t){var r;return(r=e.pinnedRowModel)==null?void 0:r.getPinnedTopRow(t)}function H4(e,t){var r;return(r=e.pinnedRowModel)==null?void 0:r.getPinnedBottomRow(t)}function G4(e,t,r){var n;return(n=e.pinnedRowModel)==null?void 0:n.forEachPinnedRow(t,r)}var W4={moduleName:"PinnedRow",version:he,beans:[V3],css:[B4],apiFunctions:{getPinnedTopRowCount:z4,getPinnedBottomRowCount:N4,getPinnedTopRow:$4,getPinnedBottomRow:H4,forEachPinnedRow:G4},icons:{rowPin:"pin",rowPinTop:"pinned-top",rowPinBottom:"pinned-bottom",rowUnpin:"un-pin"}},j4=class extends q{constructor(e,t){super(),this.cellCtrl=e,this.staticClasses=[],this.beans=t,this.column=e.column}setComp(e){this.cellComp=e,this.applyUserStyles(),this.applyCellClassRules(),this.applyClassesFromColDef()}applyCellClassRules(){const{column:e,cellComp:t}=this,r=e.colDef,n=r.cellClassRules,i=this.getCellClassParams(e,r);V1(this.beans.expressionSvc,n===this.cellClassRules?void 0:this.cellClassRules,n,i,o=>t.toggleCss(o,!0),o=>t.toggleCss(o,!1)),this.cellClassRules=n}applyUserStyles(){const e=this.column,t=e.colDef,r=t.cellStyle;if(!r)return;let n;if(typeof r=="function"){const i=this.getCellClassParams(e,t);n=r(i)}else n=r;n&&this.cellComp.setUserStyles(n)}applyClassesFromColDef(){const{column:e,cellComp:t}=this,r=e.colDef,n=this.getCellClassParams(e,r);this.staticClasses.forEach(o=>t.toggleCss(o,!1));const i=this.beans.cellStyles.getStaticCellClasses(r,n);this.staticClasses=i,i.forEach(o=>t.toggleCss(o,!0))}getCellClassParams(e,t){const{value:r,rowNode:n}=this.cellCtrl;return pe(this.beans.gos,{value:r,data:n.data,node:n,colDef:t,column:e,rowIndex:n.rowIndex})}},V4=class extends q{constructor(){super(...arguments),this.beanName="cellStyles"}processAllCellClasses(e,t,r,n){V1(this.beans.expressionSvc,void 0,e.cellClassRules,t,r,n),this.processStaticCellClasses(e,t,r)}getStaticCellClasses(e,t){const{cellClass:r}=e;if(!r)return[];let n;return typeof r=="function"?n=r(t):n=r,typeof n=="string"&&(n=[n]),n||[]}createCellCustomStyleFeature(e,t){return new j4(e,t)}processStaticCellClasses(e,t,r){this.getStaticCellClasses(e,t).forEach(i=>{r(i)})}},U4={moduleName:"CellStyle",version:he,beans:[V4]},K4=".ag-tooltip{background-color:var(--ag-tooltip-background-color);border:var(--ag-tooltip-border);border-radius:var(--ag-border-radius);color:var(--ag-tooltip-text-color);padding:var(--ag-widget-container-vertical-padding) var(--ag-widget-container-horizontal-padding);white-space:normal}.ag-tooltip,.ag-tooltip-custom{position:absolute;z-index:99999}.ag-tooltip-custom:where(:not(.ag-tooltip-interactive)),.ag-tooltip:where(:not(.ag-tooltip-interactive)){pointer-events:none}.ag-tooltip-animate{transition:opacity 1s;&:where(.ag-tooltip-hiding){opacity:0}}",q4=class extends q{constructor(){super(...arguments),this.beanName="tooltipSvc"}setupHeaderTooltip(e,t,r,n){e&&t.destroyBean(e);const i=wd(this.gos),{column:o,eGui:s}=t,a=o.getColDef();!n&&i&&!a.headerComponent&&(n=Cl(()=>s.querySelector(".ag-header-cell-text")));const l={getColumn:()=>o,getColDef:()=>o.getColDef(),getGui:()=>s,getLocation:()=>"header",getTooltipValue:()=>r??o.getColDef().headerTooltip,shouldDisplayTooltip:n};let c=this.createTooltipFeature(l);return c&&(c=t.createBean(c),t.setRefreshFunction("tooltip",()=>c.refreshTooltip())),c}setupHeaderGroupTooltip(e,t,r,n){e&&t.destroyBean(e);const i=wd(this.gos),{column:o,eGui:s}=t,a=o.getColGroupDef();!n&&i&&!(a!=null&&a.headerGroupComponent)&&(n=Cl(()=>s.querySelector(".ag-header-group-text")));const l={getColumn:()=>o,getGui:()=>s,getLocation:()=>"headerGroup",getTooltipValue:()=>r??(a&&a.headerTooltip),shouldDisplayTooltip:n};a&&(l.getColDef=()=>a);const c=this.createTooltipFeature(l);return c&&t.createBean(c)}enableCellTooltipFeature(e,t,r){const{column:n,rowNode:i}=e,o=()=>{const l=n.getColDef(),c=i.data;if(l.tooltipField&&ie(c))return ls(c,l.tooltipField,n.isTooltipFieldContainsDots());const u=l.tooltipValueGetter;return u?u(pe(this.gos,{location:"cell",colDef:n.getColDef(),column:n,rowIndex:e.cellPosition.rowIndex,node:i,data:i.data,value:e.value,valueFormatted:e.valueFormatted})):null},s=wd(this.gos);!r&&s&&!e.isCellRenderer()&&(r=Cl(()=>{const l=e.eGui;return l.children.length===0?l:l.querySelector(".ag-cell-value")}));const a={getColumn:()=>n,getColDef:()=>n.getColDef(),getRowIndex:()=>e.cellPosition.rowIndex,getRowNode:()=>i,getGui:()=>e.eGui,getLocation:()=>"cell",getTooltipValue:t!=null?()=>t:o,getValueFormatted:()=>e.valueFormatted,shouldDisplayTooltip:r};return this.createTooltipFeature(a,this.beans)}refreshRowTooltip(e,t,r,n){const i={getGui:()=>t.getFullWidthElement(),getTooltipValue:()=>r,getLocation:()=>"fullWidthRow",shouldDisplayTooltip:n},o=this.beans,s=o.context;e&&t.destroyBean(e,s);const a=this.createTooltipFeature(i,o);return t.createBean(a,s)}initCol(e){const{colDef:t}=e;e.tooltipEnabled=ie(t.tooltipField)||ie(t.tooltipValueGetter)||ie(t.tooltipComponent)}createTooltipFeature(e,t){return this.beans.registry.createDynamicBean("tooltipFeature",!1,e,t)}},Y4={moduleName:"Tooltip",version:he,beans:[q4],dynamicBeans:{tooltipFeature:nB},userComponents:{agTooltipComponent:l$},dependsOn:[zS],css:[K4]};const Dd=e=>r=>M.jsx("span",{children:e(r)}),J4=e=>M.jsx("a",{href:e.value,children:e.value}),X4=e=>{const t="data:image/png;base64,"+e.value;return M.jsx("img",{src:t})},Z4=e=>{const t={__html:e.value};return M.jsx("div",{dangerouslySetInnerHTML:t})},Q4=["#e65036","#e65138","#e75339","#e7553a","#e8563c","#e8583d","#e9593f","#e95b40","#e95c41","#ea5e43","#ea5f44","#eb6046","#eb6247","#ec6349","#ec654a","#ec664b","#ed684d","#ed694e","#ee6a50","#ee6c51","#ee6d52","#ef6f54","#ef7055","#ef7157","#f07358","#f0745a","#f1765b","#f1775d","#f1785e","#f27a5f","#f27b61","#f27c62","#f37e64","#f37f65","#f38067","#f48268","#f4836a","#f4846b","#f5866c","#f5876e","#f5886f","#f58a71","#f68b72","#f68c74","#f68d75","#f78f77","#f79078","#f7917a","#f7937b","#f8947d","#f8957e","#f89780","#f89881","#f99983","#f99a84","#f99c86","#f99d87","#f99e89","#faa08a","#faa18c","#faa28d","#faa38f","#faa590","#fba692","#fba793","#fba995","#fbaa96","#fbab98","#fbac99","#fcae9b","#fcaf9c","#fcb09e","#fcb19f","#fcb3a1","#fcb4a2","#fcb5a4","#fcb7a5","#fdb8a7","#fdb9a8","#fdbaaa","#fdbcac","#fdbdad","#fdbeaf","#fdbfb0","#fdc1b2","#fdc2b3","#fdc3b5","#fdc4b6","#fdc6b8","#fdc7ba","#fdc8bb","#fdcabd","#fdcbbe","#fdccc0","#fdcdc1","#fdcfc3","#fdd0c5","#fdd1c6","#fdd2c8","#fdd4c9","#fdd5cb","#fdd6cc","#fdd7ce","#fdd9d0","#fddad1","#fddbd3","#fddcd4","#fdded6","#fcdfd8","#fce0d9","#fce1db","#fce3dc","#fce4de","#fce5e0","#fce7e1","#fce8e3","#fbe9e5","#fbeae6","#fbece8","#fbede9","#fbeeeb","#faefed","#faf1ee","#faf2f0","#faf3f2","#f9f4f3","#f9f5f5","#f8f6f6","#f7f6f7","#f6f6f8","#f5f5f9","#f4f4f9","#f3f3f9","#f1f2f9","#f0f1f9","#eff0f9","#eeeffa","#edeefa","#ecedfa","#eaecfa","#e9ebfa","#e8eafa","#e7e9fa","#e6e8fa","#e5e7fa","#e3e6fa","#e2e5fa","#e1e4fa","#e0e3fa","#dfe2fb","#dde1fb","#dce0fb","#dbdffb","#dadefb","#d9ddfb","#d7dcfb","#d6dbfb","#d5dafb","#d4d9fb","#d3d8fb","#d1d7fb","#d0d6fb","#cfd5fb","#ced4fb","#cdd3fc","#cbd2fc","#cad1fc","#c9d0fc","#c8cffc","#c6cefc","#c5cdfc","#c4ccfc","#c3cbfc","#c1cafc","#c0c9fc","#bfc8fc","#bdc7fc","#bcc7fc","#bbc6fc","#bac5fc","#b8c4fc","#b7c3fc","#b6c2fc","#b4c1fd","#b3c0fd","#b2bffd","#b0befd","#afbdfd","#aebcfd","#acbbfd","#abbafd","#aab9fd","#a8b8fd","#a7b7fd","#a5b6fd","#a4b5fd","#a3b4fd","#a1b3fd","#a0b2fd","#9eb2fd","#9db1fd","#9bb0fd","#9aaffd","#99aefd","#97adfd","#96acfd","#94abfd","#93aafd","#91a9fd","#90a8fd","#8ea7fd","#8ca6fd","#8ba5fe","#89a4fe","#88a4fe","#86a3fe","#84a2fe","#83a1fe","#81a0fe","#809ffe","#7e9efe","#7c9dfe","#7a9cfe","#799bfe","#779afe","#759afe","#7399fe","#7198fe","#7097fe","#6e96fe","#6c95fe","#6a94fe","#6893fe","#6692fe","#6491fe","#6291fe","#5f90fe","#5d8ffe","#5b8efe","#598dfe","#568cfe","#548bfe","#518afe","#4f8afe","#4c89fe","#4988fe","#4787fe","#4486fe","#4085fe","#3d84fe","#3a83fe","#3683fe","#3282fe","#2e81fe","#2980fe","#247ffe"],eH=["#0488fc","#1089fb","#1789fb","#1d89fa","#228afa","#268af9","#2a8af9","#2e8af8","#318bf7","#348bf7","#378bf6","#3a8cf6","#3c8cf5","#3f8cf5","#418df4","#438df4","#458df3","#488df2","#4a8ef2","#4c8ef1","#4d8ef1","#4f8ff0","#518ff0","#538fef","#5490ee","#5690ee","#5890ed","#5991ed","#5b91ec","#5c91ec","#5e92eb","#5f92ea","#6192ea","#6292e9","#6393e9","#6593e8","#6693e8","#6794e7","#6994e6","#6a94e6","#6b95e5","#6c95e5","#6e95e4","#6f96e4","#7096e3","#7196e3","#7297e2","#7397e1","#7497e1","#7698e0","#7798e0","#7898df","#7999df","#7a99de","#7b99dd","#7c9add","#7d9adc","#7e9adc","#7f9bdb","#809bdb","#819bda","#829cd9","#839cd9","#849cd8","#849dd8","#859dd7","#869dd7","#879ed6","#889ed5","#899ed5","#8a9fd4","#8b9fd4","#8c9fd3","#8ca0d3","#8da0d2","#8ea0d1","#8fa1d1","#90a1d0","#91a1d0","#91a2cf","#92a2ce","#93a2ce","#94a3cd","#95a3cd","#95a3cc","#96a4cc","#97a4cb","#98a4ca","#98a5ca","#99a5c9","#9aa5c9","#9ba6c8","#9ba6c8","#9ca6c7","#9da7c6","#9ea7c6","#9ea7c5","#9fa8c5","#a0a8c4","#a0a9c3","#a1a9c3","#a2a9c2","#a2aac2","#a3aac1","#a4aac1","#a4abc0","#a5abbf","#a6abbf","#a6acbe","#a7acbe","#a8acbd","#a8adbc","#a9adbc","#aaadbb","#aaaebb","#abaeba","#acafb9","#acafb9","#adafb8","#adb0b8","#aeb0b7","#afb0b7","#afb1b6","#b0b1b5","#b1b1b5","#b1b2b4","#b2b2b4","#b2b2b3","#b3b3b2","#b4b3b2","#b4b3b1","#b5b4b1","#b6b4b0","#b7b4af","#b7b5af","#b8b5ae","#b9b5ad","#bab6ad","#bab6ac","#bbb6ac","#bcb7ab","#bcb7aa","#bdb7aa","#beb8a9","#beb8a8","#bfb8a8","#c0b9a7","#c0b9a7","#c1b9a6","#c2baa5","#c2baa5","#c3baa4","#c4bba3","#c4bba3","#c5bba2","#c6bca2","#c6bca1","#c7bca0","#c8bca0","#c8bd9f","#c9bd9e","#cabd9e","#cabe9d","#cbbe9c","#ccbe9c","#ccbf9b","#cdbf9b","#cdbf9a","#cec099","#cfc099","#cfc098","#d0c197","#d1c197","#d1c196","#d2c295","#d2c295","#d3c294","#d4c393","#d4c393","#d5c392","#d5c491","#d6c491","#d7c490","#d7c58f","#d8c58f","#d8c58e","#d9c68d","#dac68d","#dac68c","#dbc78b","#dbc78b","#dcc78a","#dcc889","#ddc889","#dec888","#dec987","#dfc987","#dfc986","#e0ca85","#e0ca85","#e1ca84","#e2cb83","#e2cb83","#e3cc82","#e3cc81","#e4cc80","#e4cd80","#e5cd7f","#e6cd7e","#e6ce7e","#e7ce7d","#e7ce7c","#e8cf7b","#e8cf7b","#e9cf7a","#e9d079","#ead078","#ead078","#ebd177","#ecd176","#ecd176","#edd275","#edd274","#eed273","#eed373","#efd372","#efd371","#f0d470","#f0d46f","#f1d46f","#f1d56e","#f2d56d","#f2d56c","#f3d66c","#f3d66b","#f4d66a","#f5d769","#f5d768","#f6d868","#f6d867","#f7d866","#f7d965","#f8d964","#f8d963","#f9da63","#f9da62","#fada61","#fadb60","#fbdb5f","#fbdb5e","#fcdc5d","#fcdc5d","#fddc5c","#fddd5b","#fedd5a","#fedd59"],VS=e=>e==="BLUE_TO_YELLOW"?eH:e==="DIVERGING_RED_WHITE_BLUE"?Q4:e;function tH(e,t){const r=t.length;if(r===0)return 0;for(let n=0;n<t.length;n++)if(e<=t[n])return n;return e>t[r-1]?r-1:t.length}function rH(e){function t(r){var g;const n=VS(e.map_name),i={backgroundColor:"inherit"},o=(g=r.context)==null?void 0:g.histogram_stats,s=e.val_column;if(s===void 0||o===void 0)return console.log("66 couldn't find stats_col"),i;const a=o[s];if(a===void 0||a.histogram_bins===void 0)return console.log("69 couldn't find summary_stats"),i;const l=a.histogram_bins;function c(m){const p=tH(m,l),y=Math.round(p/l.length*n.length);return n[y]}const u=e.val_column&&r.data?r.data[e.val_column]:r.value,d=c(u);return{backgroundColor:r.node.rowPinned?"inherit":d}}return{cellStyle:t}}function nH(e){const t=VS(e.map_name);function r(n){const i=e.val_column&&n.data?n.data[e.val_column]:n.value;return{backgroundColor:n.node.rowPinned?"inherit":t[i]}}return{cellStyle:r}}function iH(e){function t(n){if(n.data===void 0)return{backgroundColor:"inherit"};const i=n.data[e.exist_column],o=i&&i!==null,s=n.node.rowPinned;return{backgroundColor:o&&!s?e.conditional_color:"inherit"}}return{cellStyle:t}}function oH(e){function t(r){if(r.data===void 0)return{backgroundColor:"inherit"};const n=r.data[e.val_column],i=r.node.rowPinned;return{backgroundColor:n&&!i?n:"inherit"}}return{cellStyle:t}}function sH(e){function t(r){return{backgroundColor:r.node.rowPinned?"inherit":e.color}}return{cellStyle:t}}function aH(e){switch(e.color_rule){case"color_map":return rH(e);case"color_categorical":return nH(e);case"color_from_column":return oH(e);case"color_not_null":return iH(e);case"color_static":return sH(e)}}var mt=v.createContext({}),Ta=(e,t,r,n)=>{if(!e||e.componentFromFramework||t.isDestroyed())return;const o=e.newAgStackInstance();let s,a,l=!1;return o.then(c=>{if(l){t.destroyBean(c);return}s=c,a=s.getGui(),r.appendChild(a),Cy(n,s)}),()=>{var c;l=!0,s&&((c=a==null?void 0:a.parentElement)==null||c.removeChild(a),t.destroyBean(s),n&&Cy(n,void 0))}},Cy=(e,t)=>{if(e)if(e instanceof Function)e(t);else{const r=e;r.current=t}},Ut=(...e)=>e.filter(r=>r!=null&&r!=="").join(" "),Kt=class US{constructor(...t){this.classesMap={},t.forEach(r=>{this.classesMap[r]=!0})}setClass(t,r){if(!!this.classesMap[t]==r)return this;const i=new US;return i.classesMap={...this.classesMap},i.classesMap[t]=r,i}toString(){return Object.keys(this.classesMap).filter(r=>this.classesMap[r]).join(" ")}},wo=e=>{const t=()=>typeof Symbol=="function"&&Symbol.for,r=()=>t()?Symbol.for("react.memo"):60115;return typeof e=="function"&&!(e.prototype&&e.prototype.isReactComponent)||typeof e=="object"&&e.$$typeof===r()},jw,Vh=(jw=v.version)==null?void 0:jw.split(".")[0],lH=Vh==="16"||Vh==="17";function cH(){return Vh==="19"}var wl=!1;function uH(e){return wl||setTimeout(()=>wl=!1,0),wl=!0,e()}var ks=(e,t)=>{!lH&&e&&!wl?ma.flushSync(t):t()};function Ul(e,t,r){if(t==null||e==null)return t;if(e===t||t.length===0&&e.length===0)return e;if(r||e.length===0&&t.length>0||e.length>0&&t.length===0)return t;const n=[],i=[],o=new Map,s=new Map;for(let a=0;a<t.length;a++){const l=t[a];s.set(l.instanceId,l)}for(let a=0;a<e.length;a++){const l=e[a];o.set(l.instanceId,l),s.has(l.instanceId)&&n.push(l)}for(let a=0;a<t.length;a++){const l=t[a],c=l.instanceId;o.has(c)||i.push(l)}return n.length===e.length&&i.length===0?e:n.length===0&&i.length===t.length?t:n.length===0?i:i.length===0?n:[...n,...i]}var KS=v.forwardRef((e,t)=>{var N;const{registry:r,context:n}=v.useContext(mt),i=v.useRef(null),o=v.useRef(null),s=v.useRef(null),a=v.useRef(null),l=v.useRef(null),c=v.useRef(),[u,d]=v.useState(),[h,f]=v.useState(),[g,m]=v.useState(),[p,y]=v.useState(()=>new Kt),[w,b]=v.useState(()=>new Kt("ag-hidden")),[x,C]=v.useState(()=>new Kt("ag-hidden")),[S,A]=v.useState(()=>new Kt("ag-invisible"));v.useImperativeHandle(t,()=>({refresh(){return!1}})),v.useLayoutEffect(()=>Ta(u,n,o.current),[u]);const P=v.useCallback(z=>{if(i.current=z,!z){c.current=n.destroyBean(c.current);return}const W={setInnerRenderer:(L,$)=>{d(L),m($)},setChildCount:L=>f(L),toggleCss:(L,$)=>y(H=>H.setClass(L,$)),setContractedDisplayed:L=>C($=>$.setClass("ag-hidden",!L)),setExpandedDisplayed:L=>b($=>$.setClass("ag-hidden",!L)),setCheckboxVisible:L=>A($=>$.setClass("ag-invisible",!L)),setCheckboxSpacing:L=>A($=>$.setClass("ag-group-checkbox-spacing",L))},D=r.createDynamicBean("groupCellRendererCtrl",!0);D&&(c.current=n.createBean(D),c.current.init(W,z,s.current,a.current,l.current,KS,e))},[]),E=v.useMemo(()=>`ag-cell-wrapper ${p.toString()}`,[p]),O=v.useMemo(()=>`ag-group-expanded ${w.toString()}`,[w]),R=v.useMemo(()=>`ag-group-contracted ${x.toString()}`,[x]),T=v.useMemo(()=>`ag-group-checkbox ${S.toString()}`,[S]),F=u&&u.componentFromFramework,I=F?u.componentClass:void 0,k=u==null&&g!=null,B=Sa(g);return v.createElement("span",{className:E,ref:P,...e.colDef?{}:{role:(N=c.current)==null?void 0:N.getCellAriaRole()}},v.createElement("span",{className:O,ref:a}),v.createElement("span",{className:R,ref:l}),v.createElement("span",{className:T,ref:s}),v.createElement("span",{className:"ag-group-value",ref:o},k&&v.createElement(v.Fragment,null,B),F&&v.createElement(I,{...u.params})),v.createElement("span",{className:"ag-group-child-count"},h))}),wy=KS,Ep=v.createContext({setMethods:()=>{}}),dH=e=>{const{initialProps:t,addUpdateCallback:r,CustomComponentClass:n,setMethods:i}=e,[{key:o,...s},a]=v.useState(t);return v.useEffect(()=>{r(l=>a(l))},[]),v.createElement(Ep.Provider,{value:{setMethods:i}},v.createElement(n,{key:o,...s}))},hH=v.memo(dH),fH=0;function Sy(){return`agPortalKey_${++fH}`}var qS=class{constructor(e,t,r,n){this.portal=null,this.oldPortal=null,this.reactComponent=e,this.portalManager=t,this.componentType=r,this.suppressFallbackMethods=!!n,this.statelessComponent=this.isStateless(this.reactComponent),this.key=Sy(),this.portalKey=Sy(),this.instanceCreated=this.isStatelessComponent()?Ie.resolve(!1):new Ie(i=>{this.resolveInstanceCreated=i})}getGui(){return this.eParentElement}getRootElement(){return this.eParentElement.firstChild}destroy(){this.componentInstance&&typeof this.componentInstance.destroy=="function"&&this.componentInstance.destroy();const e=this.portal;e&&this.portalManager.destroyPortal(e)}createParentElement(e){const t=this.portalManager.getComponentWrappingElement(),r=document.createElement(t||"div");return r.classList.add("ag-react-container"),e.reactContainer=r,r}statelessComponentRendered(){return this.eParentElement.childElementCount>0||this.eParentElement.childNodes.length>0}getFrameworkComponentInstance(){return this.componentInstance}isStatelessComponent(){return this.statelessComponent}getReactComponentName(){return this.reactComponent.name}getMemoType(){return this.hasSymbol()?Symbol.for("react.memo"):60115}hasSymbol(){return typeof Symbol=="function"&&Symbol.for}isStateless(e){return typeof e=="function"&&!(e.prototype&&e.prototype.isReactComponent)||typeof e=="object"&&e.$$typeof===this.getMemoType()}hasMethod(e){const t=this.getFrameworkComponentInstance();return!!t&&t[e]!=null||this.fallbackMethodAvailable(e)}callMethod(e,t){const r=this.getFrameworkComponentInstance();if(this.isStatelessComponent())return this.fallbackMethod(e,t&&t[0]?t[0]:{});if(!r){setTimeout(()=>this.callMethod(e,t));return}const n=r[e];if(n)return n.apply(r,t);if(this.fallbackMethodAvailable(e))return this.fallbackMethod(e,t&&t[0]?t[0]:{})}addMethod(e,t){this[e]=t}init(e){return this.eParentElement=this.createParentElement(e),this.createOrUpdatePortal(e),new Ie(t=>this.createReactComponent(t))}createOrUpdatePortal(e){this.isStatelessComponent()||(this.ref=t=>{var r;this.componentInstance=t,(r=this.resolveInstanceCreated)==null||r.call(this,!0),this.resolveInstanceCreated=void 0},e.ref=this.ref),this.reactElement=this.createElement(this.reactComponent,{...e,key:this.key}),this.portal=ma.createPortal(this.reactElement,this.eParentElement,this.portalKey)}createElement(e,t){return v.createElement(e,t)}createReactComponent(e){this.portalManager.mountReactPortal(this.portal,this,e)}rendered(){return this.isStatelessComponent()&&this.statelessComponentRendered()||!!(!this.isStatelessComponent()&&this.getFrameworkComponentInstance())}refreshComponent(e){this.oldPortal=this.portal,this.createOrUpdatePortal(e),this.portalManager.updateReactPortal(this.oldPortal,this.portal)}fallbackMethod(e,t){const r=this[`${e}Component`];if(!this.suppressFallbackMethods&&r)return r.bind(this)(t)}fallbackMethodAvailable(e){return this.suppressFallbackMethods?!1:!!this[`${e}Component`]}};function Tp(e,t,r){e.forEach(n=>{const i=t[n];i&&(r[n]=i)})}var ur=class extends qS{constructor(){super(...arguments),this.awaitUpdateCallback=new Ie(e=>{this.resolveUpdateCallback=e}),this.wrapperComponent=hH}init(e){return this.sourceParams=e,super.init(this.getProps())}addMethod(){}getInstance(){return this.instanceCreated.then(()=>this.componentInstance)}getFrameworkComponentInstance(){return this}createElement(e,t){return super.createElement(this.wrapperComponent,{initialProps:t,CustomComponentClass:e,setMethods:r=>this.setMethods(r),addUpdateCallback:r=>{this.updateCallback=()=>(r(this.getProps()),new Ie(n=>{setTimeout(()=>{n()})})),this.resolveUpdateCallback()}})}setMethods(e){this.providedMethods=e,Tp(this.getOptionalMethods(),this.providedMethods,this)}getOptionalMethods(){return[]}getProps(){return{...this.sourceParams,key:this.key,ref:this.ref}}refreshProps(){return this.updateCallback?this.updateCallback():new Ie(e=>this.awaitUpdateCallback.then(()=>{this.updateCallback().then(()=>e())}))}},gH=class extends ur{refresh(e){return this.sourceParams=e,this.refreshProps(),!0}},pH=class extends ur{constructor(){super(...arguments),this.date=null,this.onDateChange=e=>this.updateDate(e)}getDate(){return this.date}setDate(e){this.date=e,this.refreshProps()}refresh(e){this.sourceParams=e,this.refreshProps()}getOptionalMethods(){return["afterGuiAttached","setInputPlaceholder","setInputAriaLabel","setDisabled"]}updateDate(e){this.setDate(e),this.sourceParams.onDateChanged()}getProps(){const e=super.getProps();return e.date=this.date,e.onDateChange=this.onDateChange,delete e.onDateChanged,e}},mH=class extends ur{constructor(){super(...arguments),this.label="",this.icon=null,this.shake=!1}setIcon(e,t){this.icon=e,this.shake=t,this.refreshProps()}setLabel(e){this.label=e,this.refreshProps()}getProps(){const e=super.getProps(),{label:t,icon:r,shake:n}=this;return e.label=t,e.icon=r,e.shake=n,e}},vH=class extends ur{constructor(){super(...arguments),this.model=null,this.onModelChange=e=>this.updateModel(e),this.onUiChange=()=>this.sourceParams.filterModifiedCallback(),this.expectingNewMethods=!0,this.hasBeenActive=!1,this.awaitSetMethodsCallback=new Ie(e=>{this.resolveSetMethodsCallback=e})}isFilterActive(){return this.model!=null}doesFilterPass(e){return this.providedMethods.doesFilterPass(e)}getModel(){return this.model}setModel(e){return this.expectingNewMethods=!0,this.model=e,this.hasBeenActive||(this.hasBeenActive=this.isFilterActive()),this.refreshProps()}refresh(e){return this.sourceParams=e,this.refreshProps(),!0}afterGuiAttached(e){var r;const t=this.providedMethods;t?(r=t.afterGuiAttached)==null||r.call(t,e):this.awaitSetMethodsCallback.then(()=>{var n,i;return(i=(n=this.providedMethods)==null?void 0:n.afterGuiAttached)==null?void 0:i.call(n,e)})}getOptionalMethods(){return["afterGuiAttached","afterGuiDetached","onNewRowsLoaded","getModelAsString","onAnyFilterChanged"]}setMethods(e){var t;this.expectingNewMethods===!1&&this.hasBeenActive&&((t=this.providedMethods)==null?void 0:t.doesFilterPass)!==(e==null?void 0:e.doesFilterPass)&&setTimeout(()=>{this.sourceParams.filterChangedCallback()}),this.expectingNewMethods=!1,super.setMethods(e),this.resolveSetMethodsCallback()}updateModel(e){this.setModel(e).then(()=>this.sourceParams.filterChangedCallback())}getProps(){const e=super.getProps();return e.model=this.model,e.onModelChange=this.onModelChange,e.onUiChange=this.onUiChange,delete e.filterChangedCallback,delete e.filterModifiedCallback,e}};function YS(e,t){e.parentFilterInstance(r=>{(r.setModel(t)||Ie.resolve()).then(()=>{e.filterParams.filterChangedCallback()})})}var yH=class{constructor(e,t){this.floatingFilterParams=e,this.refreshProps=t,this.model=null,this.onModelChange=r=>this.updateModel(r)}getProps(){return{...this.floatingFilterParams,model:this.model,onModelChange:this.onModelChange}}onParentModelChanged(e){this.model=e,this.refreshProps()}refresh(e){this.floatingFilterParams=e,this.refreshProps()}setMethods(e){Tp(this.getOptionalMethods(),e,this)}getOptionalMethods(){return["afterGuiAttached"]}updateModel(e){this.model=e,this.refreshProps(),YS(this.floatingFilterParams,e)}},bH=class extends ur{constructor(){super(...arguments),this.model=null,this.onModelChange=e=>this.updateModel(e)}onParentModelChanged(e){this.model=e,this.refreshProps()}refresh(e){this.sourceParams=e,this.refreshProps()}getOptionalMethods(){return["afterGuiAttached"]}updateModel(e){this.model=e,this.refreshProps(),YS(this.sourceParams,e)}getProps(){const e=super.getProps();return e.model=this.model,e.onModelChange=this.onModelChange,e}},CH=class extends ur{refresh(e){return this.sourceParams=e,this.refreshProps(),!0}},wH=class extends ur{refresh(e){this.sourceParams=e,this.refreshProps()}},SH=class extends ur{constructor(){super(...arguments),this.active=!1,this.expanded=!1,this.onActiveChange=e=>this.updateActive(e)}setActive(e){this.awaitSetActive(e)}setExpanded(e){this.expanded=e,this.refreshProps()}getOptionalMethods(){return["select","configureDefaults"]}awaitSetActive(e){return this.active=e,this.refreshProps()}updateActive(e){const t=this.awaitSetActive(e);e&&t.then(()=>this.sourceParams.onItemActivated())}getProps(){const e=super.getProps();return e.active=this.active,e.expanded=this.expanded,e.onActiveChange=this.onActiveChange,delete e.onItemActivated,e}},xH=class extends ur{refresh(e){this.sourceParams=e,this.refreshProps()}},AH=class extends ur{refresh(e){return this.sourceParams=e,this.refreshProps(),!0}},PH=class extends ur{constructor(){super(...arguments),this.onStateChange=e=>this.updateState(e)}refresh(e){return this.sourceParams=e,this.refreshProps(),!0}getState(){return this.state}updateState(e){this.state=e,this.refreshProps(),this.sourceParams.onStateUpdated()}getProps(){const e=super.getProps();return e.state=this.state,e.onStateChange=this.onStateChange,e}};function Fp(){Q(231)}var RH=1e3,EH=class{constructor(e,t,r){this.destroyed=!1,this.portals=[],this.hasPendingPortalUpdate=!1,this.wrappingElement=t||"div",this.refresher=e,this.maxComponentCreationTimeMs=r||RH}getPortals(){return this.portals}destroy(){this.destroyed=!0}destroyPortal(e){this.portals=this.portals.filter(t=>t!==e),this.batchUpdate()}getComponentWrappingElement(){return this.wrappingElement}mountReactPortal(e,t,r){this.portals=[...this.portals,e],this.waitForInstance(t,r),this.batchUpdate()}updateReactPortal(e,t){this.portals[this.portals.indexOf(e)]=t,this.batchUpdate()}batchUpdate(){this.hasPendingPortalUpdate||(setTimeout(()=>{this.destroyed||(this.refresher(),this.hasPendingPortalUpdate=!1)}),this.hasPendingPortalUpdate=!0)}waitForInstance(e,t,r=Date.now()){if(this.destroyed){t(null);return}if(e.rendered())t(e);else{if(Date.now()-r>=this.maxComponentCreationTimeMs&&!this.hasPendingPortalUpdate){ks(!0,()=>this.refresher()),e.rendered()&&t(e);return}window.setTimeout(()=>{this.waitForInstance(e,t,r)})}}},TH=({ctrl:e})=>{const t=e.isAlive(),{context:r}=v.useContext(mt),n=t?e.column.getColId():void 0,[i,o]=v.useState(),[s,a]=v.useState(),l=v.useRef(),c=v.useRef(null),u=v.useRef(null),d=v.useRef(null),h=v.useRef(),f=v.useRef();t&&!f.current&&(f.current=new Pa(()=>c.current));const g=v.useCallback(w=>{var C;if(c.current=w,l.current=w?r.createBean(new vo):r.destroyBean(l.current),!w||!e.isAlive())return;const b={setWidth:S=>{c.current&&(c.current.style.width=S)},toggleCss:(S,A)=>f.current.toggleCss(S,A),setUserStyles:S=>a(S),setAriaSort:S=>{c.current&&(S?Bk(c.current,S):zk(c.current))},setUserCompDetails:S=>o(S),getUserCompInstance:()=>h.current||void 0};e.setComp(b,w,u.current,d.current,l.current);const x=e.getSelectAllGui();x&&((C=u.current)==null||C.insertAdjacentElement("afterend",x),l.current.addDestroyFunc(()=>x.remove()))},[]);v.useLayoutEffect(()=>Ta(i,r,d.current,h),[i]),v.useEffect(()=>{e.setDragSource(c.current)},[i]);const m=v.useMemo(()=>!!((i==null?void 0:i.componentFromFramework)&&wo(i.componentClass)),[i]),p=i&&i.componentFromFramework,y=i&&i.componentClass;return v.createElement("div",{ref:g,style:s,className:"ag-header-cell","col-id":n,role:"columnheader"},v.createElement("div",{ref:u,className:"ag-header-cell-resize",role:"presentation"}),v.createElement("div",{ref:d,className:"ag-header-cell-comp-wrapper",role:"presentation"},p&&m&&v.createElement(y,{...i.params}),p&&!m&&v.createElement(y,{...i.params,ref:h})))},FH=v.memo(TH),OH=({ctrl:e})=>{const{context:t,gos:r}=v.useContext(mt),[n,i]=v.useState(),[o,s]=v.useState(()=>new Kt("ag-header-cell","ag-floating-filter")),[a,l]=v.useState(()=>new Kt),[c,u]=v.useState(()=>new Kt("ag-floating-filter-button","ag-hidden")),[d,h]=v.useState("false"),[f,g]=v.useState(),[,m]=v.useState(1),p=v.useRef(),y=v.useRef(null),w=v.useRef(null),b=v.useRef(null),x=v.useRef(null),C=v.useRef(),S=v.useRef(),A=z=>{z!=null&&C.current&&C.current(z)},P=v.useCallback(z=>{if(y.current=z,p.current=z?t.createBean(new vo):t.destroyBean(p.current),!z)return;S.current=new Ie(D=>{C.current=D});const W={toggleCss:(D,L)=>s($=>$.setClass(D,L)),setUserStyles:D=>i(D),addOrRemoveBodyCssClass:(D,L)=>l($=>$.setClass(D,L)),setButtonWrapperDisplayed:D=>{u(L=>L.setClass("ag-hidden",!D)),h(D?"false":"true")},setWidth:D=>{y.current&&(y.current.style.width=D)},setCompDetails:D=>g(D),getFloatingFilterComp:()=>S.current?S.current:null,setMenuIcon:D=>{var L;return(L=x.current)==null?void 0:L.appendChild(D)}};e.setComp(W,z,x.current,w.current,p.current)},[]);v.useLayoutEffect(()=>Ta(f,t,w.current,A),[f]);const E=v.useMemo(()=>o.toString(),[o]),O=v.useMemo(()=>a.toString(),[a]),R=v.useMemo(()=>c.toString(),[c]),T=v.useMemo(()=>!!(f&&f.componentFromFramework&&wo(f.componentClass)),[f]),F=v.useMemo(()=>r.get("reactiveCustomComponents"),[]),I=v.useMemo(()=>{if(f)if(F){const z=new yH(f.params,()=>m(W=>W+1));return A(z),z}else f.componentFromFramework&&Fp()},[f]),k=I==null?void 0:I.getProps(),B=f&&f.componentFromFramework,N=f&&f.componentClass;return v.createElement("div",{ref:P,style:n,className:E,role:"gridcell"},v.createElement("div",{ref:w,className:O,role:"presentation"},B&&!F&&v.createElement(N,{...f.params,ref:T?()=>{}:A}),B&&F&&v.createElement(Ep.Provider,{value:{setMethods:z=>I.setMethods(z)}},v.createElement(N,{...k}))),v.createElement("div",{ref:b,"aria-hidden":d,className:R,role:"presentation"},v.createElement("button",{ref:x,type:"button",className:"ag-button ag-floating-filter-button-button",tabIndex:-1})))},MH=v.memo(OH),DH=({ctrl:e})=>{const{context:t}=v.useContext(mt),[r,n]=v.useState(),[i,o]=v.useState(()=>new Kt),[s,a]=v.useState(()=>new Kt),[l,c]=v.useState("false"),[u,d]=v.useState(),[h,f]=v.useState(),g=v.useMemo(()=>e.column.getUniqueId(),[]),m=v.useRef(),p=v.useRef(null),y=v.useRef(null),w=v.useRef(null),b=v.useRef(),x=v.useCallback(O=>{if(p.current=O,m.current=O?t.createBean(new vo):t.destroyBean(m.current),!O)return;const R={setWidth:T=>{p.current&&(p.current.style.width=T)},toggleCss:(T,F)=>o(I=>I.setClass(T,F)),setUserStyles:T=>n(T),setHeaderWrapperHidden:T=>{const F=w.current;F&&(T?F.style.setProperty("display","none"):F.style.removeProperty("display"))},setHeaderWrapperMaxHeight:T=>{const F=w.current;F&&(T!=null?F.style.setProperty("max-height",`${T}px`):F.style.removeProperty("max-height"),F.classList.toggle("ag-header-cell-comp-wrapper-limited-height",T!=null))},setUserCompDetails:T=>f(T),setResizableDisplayed:T=>{a(F=>F.setClass("ag-hidden",!T)),c(T?"false":"true")},setAriaExpanded:T=>d(T),getUserCompInstance:()=>b.current||void 0};e.setComp(R,O,y.current,w.current,m.current)},[]);v.useLayoutEffect(()=>Ta(h,t,w.current),[h]),v.useEffect(()=>{p.current&&e.setDragSource(p.current)},[h]);const C=v.useMemo(()=>!!((h==null?void 0:h.componentFromFramework)&&wo(h.componentClass)),[h]),S=v.useMemo(()=>"ag-header-group-cell "+i.toString(),[i]),A=v.useMemo(()=>"ag-header-cell-resize "+s.toString(),[s]),P=h&&h.componentFromFramework,E=h&&h.componentClass;return v.createElement("div",{ref:x,style:r,className:S,"col-id":g,role:"columnheader","aria-expanded":u},v.createElement("div",{ref:w,className:"ag-header-cell-comp-wrapper",role:"presentation"},P&&C&&v.createElement(E,{...h.params}),P&&!C&&v.createElement(E,{...h.params,ref:b})),v.createElement("div",{ref:y,"aria-hidden":l,className:A}))},kH=v.memo(DH),IH=({ctrl:e})=>{const{context:t}=v.useContext(mt),{topOffset:r,rowHeight:n}=v.useMemo(()=>e.getTopAndHeight(),[]),i=e.getAriaRowIndex(),o=e.headerRowClass,[s,a]=v.useState(()=>n+"px"),[l,c]=v.useState(()=>r+"px"),u=v.useRef(null),d=v.useRef(null),[h,f]=v.useState(()=>e.getUpdatedHeaderCtrls()),g=v.useRef(),m=v.useRef(null),p=v.useCallback(b=>{if(m.current=b,g.current=b?t.createBean(new vo):t.destroyBean(g.current),!b)return;const x={setHeight:C=>a(C),setTop:C=>c(C),setHeaderCtrls:(C,S,A)=>{d.current=u.current,u.current=C;const P=Ul(d.current,C,S);P!==d.current&&ks(A,()=>f(P))},setWidth:C=>{m.current&&(m.current.style.width=C)}};e.setComp(x,g.current,!1)},[]),y=v.useMemo(()=>({height:s,top:l}),[s,l]),w=v.useCallback(b=>{switch(e.type){case"group":return v.createElement(kH,{ctrl:b,key:b.instanceId});case"filter":return v.createElement(MH,{ctrl:b,key:b.instanceId});default:return v.createElement(FH,{ctrl:b,key:b.instanceId})}},[]);return v.createElement("div",{ref:p,className:o,role:"row",style:y,"aria-rowindex":i},h.map(w))},_H=v.memo(IH),LH=({pinned:e})=>{const[t,r]=v.useState(!0),[n,i]=v.useState([]),{context:o}=v.useContext(mt),s=v.useRef(null),a=v.useRef(null),l=v.useRef(),c=e==="left",u=e==="right",d=!c&&!u,h=v.useCallback(m=>{if(s.current=m,l.current=m?o.createBean(new w3(e)):o.destroyBean(l.current),!m)return;const p={setDisplayed:r,setCtrls:y=>i(y),setCenterWidth:y=>{a.current&&(a.current.style.width=y)},setViewportScrollLeft:y=>{s.current&&(s.current.scrollLeft=y)},setPinnedContainerWidth:y=>{s.current&&(s.current.style.width=y,s.current.style.minWidth=y,s.current.style.maxWidth=y)}};l.current.setComp(p,s.current)},[]),f=t?"":"ag-hidden",g=()=>n.map(m=>v.createElement(_H,{ctrl:m,key:m.instanceId}));return v.createElement(v.Fragment,null,c&&v.createElement("div",{ref:h,className:"ag-pinned-left-header "+f,"aria-hidden":!t,role:"rowgroup"},g()),u&&v.createElement("div",{ref:h,className:"ag-pinned-right-header "+f,"aria-hidden":!t,role:"rowgroup"},g()),d&&v.createElement("div",{ref:h,className:"ag-header-viewport "+f,role:"presentation",tabIndex:-1},v.createElement("div",{ref:a,className:"ag-header-container",role:"rowgroup"},g())))},kd=v.memo(LH),BH=()=>{const[e,t]=v.useState(()=>new Kt),[r,n]=v.useState(),{context:i}=v.useContext(mt),o=v.useRef(null),s=v.useRef(),a=v.useCallback(u=>{if(o.current=u,s.current=u?i.createBean(new v3):i.destroyBean(s.current),!u)return;const d={toggleCss:(h,f)=>t(g=>g.setClass(h,f)),setHeightAndMinHeight:h=>n(h)};s.current.setComp(d,u,u)},[]),l=v.useMemo(()=>"ag-header "+e.toString(),[e]),c=v.useMemo(()=>({height:r,minHeight:r}),[r]);return v.createElement("div",{ref:a,className:l,style:c,role:"presentation"},v.createElement(kd,{pinned:"left"}),v.createElement(kd,{pinned:null}),v.createElement(kd,{pinned:"right"}))},zH=v.memo(BH),NH=(e,t)=>{v.useEffect(()=>{const r=t.current;if(r){const n=r.parentElement;if(n){const i=document.createComment(e);return n.insertBefore(i,r),()=>{n.removeChild(i)}}}},[e])},Rn=NH,$H=class{constructor(e,t){this.cellEditorParams=e,this.refreshProps=t,this.instanceCreated=new Ie(r=>{this.resolveInstanceCreated=r}),this.onValueChange=r=>this.updateValue(r),this.value=e.value}getProps(){return{...this.cellEditorParams,initialValue:this.cellEditorParams.value,value:this.value,onValueChange:this.onValueChange}}getValue(){return this.value}refresh(e){this.cellEditorParams=e,this.refreshProps()}setMethods(e){Tp(this.getOptionalMethods(),e,this)}getInstance(){return this.instanceCreated.then(()=>this.componentInstance)}setRef(e){var t;this.componentInstance=e,(t=this.resolveInstanceCreated)==null||t.call(this),this.resolveInstanceCreated=void 0}getOptionalMethods(){return["isCancelBeforeStart","isCancelAfterEnd","focusIn","focusOut","afterGuiAttached"]}updateValue(e){this.value=e,this.refreshProps()}},HH=e=>{const t=v.useRef(e),r=v.useRef(),n=v.useRef(!1),i=v.useRef(!1),[,o]=v.useState(0);n.current&&(i.current=!0),v.useEffect(()=>(n.current||(r.current=t.current(),n.current=!0),o(s=>s+1),()=>{var s;i.current&&((s=r.current)==null||s.call(r))}),[])},GH=e=>{const[t,r]=v.useState(),n=v.useContext(mt),{context:i,popupSvc:o,localeSvc:s,gos:a,editSvc:l}=n,{editDetails:c,cellCtrl:u,eParentCell:d}=e;return HH(()=>{var A,P;const{compDetails:h}=c,f=a.get("stopEditingWhenCellsLoseFocus"),g=i.createBean(l.createPopupEditorWrapper(h.params)),m=g.getGui();if(e.jsChildComp){const E=e.jsChildComp.getGui();E&&m.appendChild(E)}const{column:p,rowNode:y}=u,w={column:p,rowNode:y,type:"popupCellEditor",eventSource:d,ePopup:m,position:c.popupPosition,keepWithinBounds:!0},b=o==null?void 0:o.positionPopupByComponent.bind(o,w),x=k2(s),C=o==null?void 0:o.addPopup({modal:f,eChild:m,closeOnEsc:!0,closedCallback:()=>{u.onPopupEditorClosed()},anchorToElement:d,positionCallback:b,ariaLabel:x("ariaLabelCellEditor","Cell Editor")}),S=C?C.hideFunc:void 0;return r(g),(P=(A=e.jsChildComp)==null?void 0:A.afterGuiAttached)==null||P.call(A),()=>{S==null||S(),i.destroyBean(g)}}),v.useLayoutEffect(()=>()=>{u.isCellFocused()&&(t!=null&&t.getGui().contains(Ke(n)))&&d.focus({preventScroll:!0})},[t]),v.createElement(v.Fragment,null,t&&e.wrappedContent&&ma.createPortal(e.wrappedContent,t.getGui()))},xy=v.memo(GH),WH=(e,t,r,n,i,o)=>{const{context:s}=v.useContext(mt),a=v.useCallback(()=>{const l=i.current;if(!l)return;const c=l.getGui();c&&c.parentElement&&c.parentElement.removeChild(c),s.destroyBean(l),i.current=void 0},[]);v.useEffect(()=>{const l=e!=null,c=(e==null?void 0:e.compDetails)&&!e.compDetails.componentFromFramework,u=t&&r==null;if(!(l&&c&&!u)){a();return}const h=e.compDetails;if(i.current){const g=i.current,p=g.refresh!=null&&e.force==!1?g.refresh(h.params):!1;if(p===!0||p===void 0)return;a()}h.newAgStackInstance().then(g=>{if(!g)return;const m=g.getGui();if(!m)return;(t?r:o.current).appendChild(m),i.current=g})},[e,t,n]),v.useEffect(()=>a,[])},jH=WH,VH=(e,t,r)=>{const{compProxy:n}=e;r(n);const i=n.getProps(),o=wo(t);return v.createElement(Ep.Provider,{value:{setMethods:s=>n.setMethods(s)}},o?v.createElement(t,{...i}):v.createElement(t,{...i,ref:s=>n.setRef(s)}))},Ay=(e,t,r)=>{const n=e.compProxy;return v.createElement(v.Fragment,null,n?VH(e,t,r):v.createElement(t,{...e.compDetails.params,ref:r}))},UH=(e,t,r,n,i)=>{const o=e.compDetails,s=o.componentClass,a=o.componentFromFramework&&!e.popup,l=o.componentFromFramework&&e.popup,c=!o.componentFromFramework&&e.popup;return v.createElement(v.Fragment,null,a&&Ay(e,s,t),l&&v.createElement(xy,{editDetails:e,cellCtrl:n,eParentCell:r,wrappedContent:Ay(e,s,t)}),c&&i&&v.createElement(xy,{editDetails:e,cellCtrl:n,eParentCell:r,jsChildComp:i}))},KH=(e,t,r,n,i,o,s)=>{const{compDetails:a,value:l}=e,c=!a,u=a&&a.componentFromFramework,d=a&&a.componentClass,h=l!=null&&l.toString?l.toString():l,f=()=>v.createElement(v.Fragment,null,c&&v.createElement(v.Fragment,null,h),u&&!o&&v.createElement(d,{...a.params,key:t,ref:n}),u&&o&&v.createElement(d,{...a.params,key:t}));return v.createElement(v.Fragment,null,i?v.createElement("span",{role:"presentation",id:`cell-${r}`,className:"ag-cell-value",ref:s},f()):f())},qH=({cellCtrl:e,printLayout:t,editingRow:r})=>{const n=v.useContext(mt),{context:i}=n,{column:{colIdSanitised:o},instanceId:s}=e,a=v.useRef(),[l,c]=v.useState(()=>e.isCellRenderer()?void 0:{compDetails:void 0,value:e.getValueToDisplay(),force:!1}),[u,d]=v.useState(),[h,f]=v.useState(1),[g,m]=v.useState(),[p,y]=v.useState(!1),[w,b]=v.useState(!1),[x,C]=v.useState(!1),[S,A]=v.useState(),P=v.useMemo(()=>e.isForceWrapper(),[e]),E=v.useMemo(()=>e.getCellAriaRole(),[e]),O=v.useRef(null),R=v.useRef(null),T=v.useRef(null),F=v.useRef(),I=v.useRef(),k=v.useRef(),B=v.useRef([]),N=v.useRef(),[z,W]=v.useState(0),D=v.useCallback(ne=>{N.current=ne,W(U=>U+1)},[]),L=l!=null&&(p||x||w),$=P||L,H=v.useCallback(ne=>{if(I.current=ne,ne){const U=ne.isCancelBeforeStart&&ne.isCancelBeforeStart();setTimeout(()=>{U?(e.stopEditing(!0),e.focusCell(!0)):e.cellEditorAttached()})}},[e]),V=v.useRef();V.current||(V.current=new Pa(()=>O.current)),jH(l,$,N.current,z,F,O);const X=v.useRef();v.useLayoutEffect(()=>{var Pe;const ne=X.current,U=l;if(X.current=l,ne==null||ne.compDetails==null||U==null||U.compDetails==null)return;const ce=ne.compDetails,me=U.compDetails;if(ce.componentClass!=me.componentClass||((Pe=T.current)==null?void 0:Pe.refresh)==null)return;T.current.refresh(me.params)!=!0&&f(Ge=>Ge+1)},[l]),v.useLayoutEffect(()=>{if(!(u&&!u.compDetails.componentFromFramework))return;const U=u.compDetails,ce=u.popup===!0,me=U.newAgStackInstance();return me.then(ae=>{if(!ae)return;const Pe=ae.getGui();if(H(ae),!ce){const Ge=(P?k:O).current;Ge==null||Ge.appendChild(Pe),ae.afterGuiAttached&&ae.afterGuiAttached()}A(ae)}),()=>{me.then(ae=>{var Ge;const Pe=ae.getGui();i.destroyBean(ae),H(void 0),A(void 0),(Ge=Pe==null?void 0:Pe.parentElement)==null||Ge.removeChild(Pe)})}},[u]);const Y=v.useCallback(ne=>{if(k.current=ne,!ne){B.current.forEach(ce=>ce()),B.current=[];return}const U=ce=>{if(ce){const me=ce.getGui();ne.insertAdjacentElement("afterbegin",me),B.current.push(()=>{i.destroyBean(ce),jn(me)})}return ce};if(p){const ce=e.createSelectionCheckbox();U(ce)}x&&U(e.createDndSource()),w&&U(e.createRowDragComp())},[e,i,x,w,p]),re=v.useCallback(()=>{const ne=!e.isCellSpanning()||R.current,U=O.current;if(a.current=U?i.createBean(new vo):i.destroyBean(a.current),!U||!ne||!e)return;const ce={toggleCss:(ae,Pe)=>V.current.toggleCss(ae,Pe),setUserStyles:ae=>m(ae),getFocusableElement:()=>O.current,setIncludeSelection:ae=>y(ae),setIncludeRowDrag:ae=>b(ae),setIncludeDndSource:ae=>C(ae),getCellEditor:()=>I.current||null,getCellRenderer:()=>T.current??F.current,getParentOfValue:()=>N.current??k.current??O.current,setRenderDetails:(ae,Pe,Ge)=>{c(ze=>(ze==null?void 0:ze.compDetails)!==ae||(ze==null?void 0:ze.value)!==Pe||(ze==null?void 0:ze.force)!==Ge?{value:Pe,compDetails:ae,force:Ge}:ze)},setEditDetails:(ae,Pe,Ge,ze)=>{if(ae){let Ne;ze?Ne=new $H(ae.params,()=>f(qe=>qe+1)):ae.componentFromFramework&&Fp(),d({compDetails:ae,popup:Pe,popupPosition:Ge,compProxy:Ne}),Pe||c(void 0)}else e.hasBrowserFocus()&&ce.getFocusableElement().focus({preventScroll:!0}),d(qe=>{qe!=null&&qe.compProxy&&(I.current=void 0)})}},me=k.current||void 0;e.setComp(ce,U,R.current??void 0,me,t,r,a.current)},[]),oe=v.useCallback(ne=>{O.current=ne,re()},[]),K=v.useCallback(ne=>{R.current=ne,re()},[]),J=v.useMemo(()=>{var U;return!!(((U=l==null?void 0:l.compDetails)==null?void 0:U.componentFromFramework)&&wo(l.compDetails.componentClass))},[l]);v.useLayoutEffect(()=>{O.current&&(V.current.toggleCss("ag-cell-value",!$),V.current.toggleCss("ag-cell-inline-editing",!!u&&!u.popup),V.current.toggleCss("ag-cell-popup-editing",!!u&&!!u.popup),V.current.toggleCss("ag-cell-not-inline-editing",!u||!!u.popup),e.setInlineEditingCss())});const te=()=>v.createElement(v.Fragment,null,l!=null&&KH(l,h,s,T,$,J,D),u!=null&&UH(u,H,O.current,e,S)),_=()=>v.createElement("div",{ref:oe,style:g,role:E,"col-id":o},$?v.createElement("div",{className:"ag-cell-wrapper",role:"presentation",ref:Y},te()):te());return e.isCellSpanning()?v.createElement("div",{ref:K,className:"ag-spanned-cell-wrapper",role:"presentation"},_()):_()},YH=v.memo(qH),JH=({rowCtrl:e,containerType:t})=>{const{context:r,gos:n}=v.useContext(mt),i=v.useRef(),o=v.useRef(e.getDomOrder()),s=e.isFullWidth(),a=e.rowNode.displayed,[l,c]=v.useState(()=>a?e.rowNode.getRowIndexString():null),[u,d]=v.useState(()=>e.rowId),[h,f]=v.useState(()=>e.businessKey),[g,m]=v.useState(()=>e.rowStyles),p=v.useRef(null),y=v.useRef(null),[w,b]=v.useState(()=>null),[x,C]=v.useState(),[S,A]=v.useState(()=>a?e.getInitialRowTop(t):void 0),[P,E]=v.useState(()=>a?e.getInitialTransform(t):void 0),O=v.useRef(null),R=v.useRef(),T=v.useRef(!1),[F,I]=v.useState(0);v.useEffect(()=>{var X;if(T.current||!x||F>10)return;const V=(X=O.current)==null?void 0:X.firstChild;V?(e.setupDetailRowAutoHeight(V),T.current=!0):I(Y=>Y+1)},[x,F]);const k=v.useRef();k.current||(k.current=new Pa(()=>O.current));const B=v.useCallback(V=>{if(O.current=V,i.current=V?r.createBean(new vo):r.destroyBean(i.current),!V){e.unsetComp(t);return}if(!e.isAlive())return;const X={setTop:A,setTransform:E,toggleCss:(Y,re)=>k.current.toggleCss(Y,re),setDomOrder:Y=>o.current=Y,setRowIndex:c,setRowId:d,setRowBusinessKey:f,setUserStyles:m,setCellCtrls:(Y,re)=>{y.current=p.current,p.current=Y;const oe=Ul(y.current,Y,o.current);oe!==y.current&&ks(re,()=>b(oe))},showFullWidth:Y=>C(Y),getFullWidthCellRenderer:()=>R.current,refreshFullWidth:Y=>L.current?(C(re=>({...re,params:Y()})),!0):!R.current||!R.current.refresh?!1:R.current.refresh(Y())};e.setComp(X,V,t,i.current)},[]);v.useLayoutEffect(()=>Ta(x,r,O.current,R),[x]);const N=v.useMemo(()=>{const V={top:S,transform:P};return Object.assign(V,g),V},[S,P,g]),z=s&&(x==null?void 0:x.componentFromFramework),W=!s&&w!=null,D=v.useMemo(()=>!!((x==null?void 0:x.componentFromFramework)&&wo(x.componentClass)),[x]),L=v.useRef(!1);v.useEffect(()=>{L.current=D&&!!x&&!!n.get("reactiveCustomComponents")},[D,x]);const $=()=>w==null?void 0:w.map(V=>v.createElement(YH,{cellCtrl:V,editingRow:e.editing,printLayout:e.printLayout,key:V.instanceId})),H=()=>{const V=x.componentClass;return v.createElement(v.Fragment,null,D?v.createElement(V,{...x.params}):v.createElement(V,{...x.params,ref:R}))};return v.createElement("div",{ref:B,role:"row",style:N,"row-index":l,"row-id":u,"row-business-key":h},W&&$(),z&&H())},Py=v.memo(JH),XH=({name:e})=>{const{context:t,gos:r}=v.useContext(mt),n=v.useMemo(()=>Ea(e),[e]),i=v.useRef(null),o=v.useRef(null),s=v.useRef(null),a=v.useRef([]),l=v.useRef([]),[c,u]=v.useState(()=>[]),d=!!r.get("enableCellSpan")&&!!n.getSpannedRowCtrls,h=v.useRef([]),f=v.useRef([]),[g,m]=v.useState(()=>[]),p=v.useRef(!1),y=v.useRef(),w=v.useMemo(()=>Ut("ag-viewport",q1(e)),[e]),b=v.useMemo(()=>Ut(bl(e)),[e]),x=v.useMemo(()=>Ut("ag-spanning-container",qL(e)),[e]),C=n.type==="center"||d,S=C?i:o;Rn(" AG Row Container "+e+" ",S);const A=v.useCallback(()=>{const k=!C||i.current!=null,B=o.current!=null,N=!d||s.current!=null;return k&&B&&N},[]),P=v.useCallback(()=>i.current==null&&o.current==null&&s.current==null,[]),E=v.useCallback(()=>{if(P()&&(y.current=t.destroyBean(y.current)),A()){const k=z=>{const W=Ul(l.current,a.current,p.current);W!==l.current&&(l.current=W,ks(z,()=>u(W)))},B=z=>{const W=Ul(f.current,h.current,p.current);W!==f.current&&(f.current=W,ks(z,()=>m(W)))},N={setHorizontalScroll:z=>{i.current&&(i.current.scrollLeft=z)},setViewportHeight:z=>{i.current&&(i.current.style.height=z)},setRowCtrls:({rowCtrls:z,useFlushSync:W})=>{const D=!!W&&a.current.length>0&&z.length>0;a.current=z,k(D)},setSpannedRowCtrls:(z,W)=>{const D=!!W&&h.current.length>0&&z.length>0;h.current=z,B(D)},setDomOrder:z=>{p.current!=z&&(p.current=z,k(!1))},setContainerWidth:z=>{o.current&&(o.current.style.width=z)},setOffsetTop:z=>{o.current&&(o.current.style.transform=`translateY(${z})`)}};y.current=t.createBean(new i3(e)),y.current.setComp(N,o.current,s.current??void 0,i.current)}},[A,P]),O=v.useCallback(k=>{o.current=k,E()},[E]),R=v.useCallback(k=>{s.current=k,E()},[E]),T=v.useCallback(k=>{i.current=k,E()},[E]),F=()=>v.createElement("div",{className:b,ref:O,role:"rowgroup"},c.map(k=>v.createElement(Py,{rowCtrl:k,containerType:n.type,key:k.instanceId})));if(!C)return F();const I=()=>d&&v.createElement("div",{className:x,ref:R,role:"rowgroup"},g.map(k=>v.createElement(Py,{rowCtrl:k,containerType:n.type,key:k.instanceId})));return v.createElement("div",{className:w,ref:T,role:"presentation"},F(),I())},ZH=v.memo(XH),QH=()=>{const e=v.useContext(mt),{context:t,overlays:r}=e,[n,i]=v.useState(""),[o,s]=v.useState(0),[a,l]=v.useState(0),[c,u]=v.useState("0px"),[d,h]=v.useState("0px"),[f,g]=v.useState("100%"),[m,p]=v.useState("0px"),[y,w]=v.useState("0px"),[b,x]=v.useState("100%"),[C,S]=v.useState(!0),[A,P]=v.useState(!0),[E,O]=v.useState(null),[R,T]=v.useState(""),[F,I]=v.useState(null),[k,B]=v.useState("ag-layout-normal"),N=v.useRef();N.current||(N.current=new Pa(()=>z.current));const z=v.useRef(null),W=v.useRef(null),D=v.useRef(null),L=v.useRef(null),$=v.useRef(null),H=v.useRef(null),V=v.useRef(null),X=v.useRef([]),Y=v.useRef([]);Rn(" AG Grid Body ",z),Rn(" AG Pinned Top ",W),Rn(" AG Sticky Top ",D),Rn(" AG Middle ",H),Rn(" AG Pinned Bottom ",V);const re=v.useCallback(Ne=>{if(z.current=Ne,!Ne){X.current=t.destroyBeans(X.current),Y.current.forEach($e=>$e()),Y.current=[];return}if(!t)return;const qe=($e,Dt)=>{$e.appendChild(Dt),Y.current.push(()=>$e.removeChild(Dt))},bn=$e=>{const Dt=t.createBean(new $e);return X.current.push(Dt),Dt},Fr=($e,Dt,TE)=>{qe($e,document.createComment(TE)),qe($e,bn(Dt).getGui())};Fr(Ne,u3," AG Fake Horizontal Scroll ");const ci=r==null?void 0:r.getOverlayWrapperCompClass();ci&&Fr(Ne,ci," AG Overlay Wrapper "),$.current&&Fr($.current,h3," AG Fake Vertical Scroll ");const La={setRowAnimationCssOnBodyViewport:i,setColumnCount:$e=>{z.current&&_k(z.current,$e)},setRowCount:$e=>{z.current&&kk(z.current,$e)},setTopHeight:s,setBottomHeight:l,setStickyTopHeight:u,setStickyTopTop:h,setStickyTopWidth:g,setTopInvisible:S,setBottomInvisible:P,setColumnMovingCss:($e,Dt)=>N.current.toggleCss($e,Dt),updateLayoutClasses:B,setAlwaysVerticalScrollClass:O,setPinnedTopBottomOverflowY:T,setCellSelectableCss:($e,Dt)=>I(Dt?$e:null),setBodyViewportWidth:$e=>{H.current&&(H.current.style.width=$e)},registerBodyViewportResizeListener:$e=>{if(H.current){const Dt=fn(e,H.current,$e);Y.current.push(()=>Dt())}},setStickyBottomHeight:p,setStickyBottomBottom:w,setStickyBottomWidth:x,setGridRootRole:$e=>Ne.setAttribute("role",$e)},Bo=t.createBean(new l3);X.current.push(Bo),Bo.setComp(La,Ne,H.current,W.current,V.current,D.current,L.current)},[]),oe=v.useMemo(()=>Ut("ag-root","ag-unselectable",k),[k]),K=v.useMemo(()=>Ut("ag-body-viewport",n,k,E,F),[n,k,E,F]),J=v.useMemo(()=>Ut("ag-body",k),[k]),te=v.useMemo(()=>Ut("ag-floating-top",C?"ag-invisible":null,F),[F,C]),_=v.useMemo(()=>Ut("ag-sticky-top",F),[F]),ne=v.useMemo(()=>Ut("ag-sticky-bottom",m==="0px"?"ag-invisible":null,F),[F,m]),U=v.useMemo(()=>Ut("ag-floating-bottom",A?"ag-invisible":null,F),[F,A]),ce=v.useMemo(()=>({height:o,minHeight:o,overflowY:R}),[o,R]),me=v.useMemo(()=>({height:c,top:d,width:f}),[c,d,f]),ae=v.useMemo(()=>({height:m,bottom:y,width:b}),[m,y,b]),Pe=v.useMemo(()=>({height:a,minHeight:a,overflowY:R}),[a,R]),Ge=Ne=>v.createElement(ZH,{name:Ne,key:`${Ne}-container`}),ze=({section:Ne,children:qe,className:bn,style:Fr})=>v.createElement("div",{ref:Ne,className:bn,role:"presentation",style:Fr},qe.map(Ge));return v.createElement("div",{ref:re,className:oe},v.createElement(zH,null),ze({section:W,className:te,style:ce,children:["topLeft","topCenter","topRight","topFullWidth"]}),v.createElement("div",{className:J,ref:$,role:"presentation"},ze({section:H,className:K,children:["left","center","right","fullWidth"]})),ze({section:D,className:_,style:me,children:["stickyTopLeft","stickyTopCenter","stickyTopRight","stickyTopFullWidth"]}),ze({section:L,className:ne,style:ae,children:["stickyBottomLeft","stickyBottomCenter","stickyBottomRight","stickyBottomFullWidth"]}),ze({section:V,className:U,style:Pe,children:["bottomLeft","bottomCenter","bottomRight","bottomFullWidth"]}))},eG=v.memo(QH),tG=(e,t)=>{const{children:r,eFocusableElement:n,onTabKeyDown:i,gridCtrl:o,forceFocusOutWhenTabGuardsAreEmpty:s,isEmpty:a}=e,{context:l}=v.useContext(mt),c=v.useRef(null),u=v.useRef(null),d=v.useRef(),h=y=>{const w=y==null?void 0:parseInt(y,10).toString();[c,u].forEach(b=>{var x,C;w===void 0?(x=b.current)==null||x.removeAttribute("tabindex"):(C=b.current)==null||C.setAttribute("tabindex",w)})};v.useImperativeHandle(t,()=>({forceFocusOutOfContainer(y){var w;(w=d.current)==null||w.forceFocusOutOfContainer(y)}}));const f=v.useCallback(()=>{const y=c.current,w=u.current;if(!y&&!w){d.current=l.destroyBean(d.current);return}if(y&&w){const b={setTabIndex:h};d.current=l.createBean(new uB({comp:b,eTopGuard:y,eBottomGuard:w,eFocusableElement:n,onTabKeyDown:i,forceFocusOutWhenTabGuardsAreEmpty:s,focusInnerElement:x=>o.focusInnerElement(x),isEmpty:a}))}},[]),g=v.useCallback(y=>{c.current=y,f()},[f]),m=v.useCallback(y=>{u.current=y,f()},[f]),p=y=>{const w=y==="top"?Sd.TAB_GUARD_TOP:Sd.TAB_GUARD_BOTTOM;return v.createElement("div",{className:`${Sd.TAB_GUARD} ${w}`,role:"presentation",ref:y==="top"?g:m})};return v.createElement(v.Fragment,null,p("top"),r,p("bottom"))},rG=v.forwardRef(tG),nG=v.memo(rG),iG=({context:e})=>{const[t,r]=v.useState(""),[n,i]=v.useState(""),[o,s]=v.useState(null),[a,l]=v.useState(null),[c,u]=v.useState(!1),[d,h]=v.useState(),f=v.useRef(),g=v.useRef(null),m=v.useRef(),[p,y]=v.useState(null),w=v.useRef(()=>{}),b=v.useRef(),x=v.useRef([]),C=v.useCallback(()=>{},[]),S=v.useMemo(()=>e.isDestroyed()?null:e.getBeans(),[e]);Rn(" AG Grid ",g);const A=v.useCallback(F=>{if(g.current=F,f.current=F?e.createBean(new mB):e.destroyBean(f.current),!F||e.isDestroyed())return;const I=f.current;w.current=I.focusInnerElement.bind(I);const k={destroyGridUi:()=>{},setRtlClass:r,forceFocusOutOfContainer:B=>{var N,z;if(!B&&((N=b.current)!=null&&N.isDisplayed())){b.current.forceFocusOutOfContainer(B);return}(z=m.current)==null||z.forceFocusOutOfContainer(B)},updateLayoutClasses:i,getFocusableContainers:()=>{var z;const B=[],N=(z=g.current)==null?void 0:z.querySelector(".ag-root");return N&&B.push({getGui:()=>N}),x.current.forEach(W=>{W.isDisplayed()&&B.push(W)}),B},setCursor:s,setUserSelect:l};I.setComp(k,F,F),u(!0)},[]);v.useEffect(()=>{const F=f.current,I=g.current;if(!d||!S||!F||!p||!I)return;const k=[],{watermarkSelector:B,paginationSelector:N,sideBarSelector:z,statusBarSelector:W,gridHeaderDropZonesSelector:D}=F.getOptionalSelectors(),L=[];if(D){const H=e.createBean(new D.component),V=H.getGui();I.insertAdjacentElement("afterbegin",V),L.push(V),k.push(H)}if(z){const H=e.createBean(new z.component),V=H.getGui(),X=p.querySelector(".ag-tab-guard-bottom");X&&(X.insertAdjacentElement("beforebegin",V),L.push(V)),k.push(H),x.current.push(H)}const $=H=>{const V=e.createBean(new H),X=V.getGui();return I.insertAdjacentElement("beforeend",X),L.push(X),k.push(V),V};if(W&&$(W.component),N){const H=$(N.component);b.current=H,x.current.push(H)}return B&&$(B.component),()=>{e.destroyBeans(k),L.forEach(H=>{var V;(V=H.parentElement)==null||V.removeChild(H)})}},[d,p,S]);const P=v.useMemo(()=>Ut("ag-root-wrapper",t,n),[t,n]),E=v.useMemo(()=>Ut("ag-root-wrapper-body","ag-focus-managed",n),[n]),O=v.useMemo(()=>({userSelect:a??"",WebkitUserSelect:a??"",cursor:o??""}),[a,o]),R=v.useCallback(F=>{m.current=F,h(F!==null)},[]),T=v.useCallback(()=>{var F;return!((F=f.current)!=null&&F.isFocusable())},[]);return v.createElement("div",{ref:A,className:P,style:O,role:"presentation"},v.createElement("div",{className:E,ref:y,role:"presentation"},c&&p&&S&&v.createElement(mt.Provider,{value:S},v.createElement(nG,{ref:R,eFocusableElement:p,onTabKeyDown:C,gridCtrl:f.current,forceFocusOutWhenTabGuardsAreEmpty:!0,isEmpty:T},v.createElement(eG,null)))))},oG=v.memo(iG),sG=class extends q{wireBeans(e){this.ctrlsSvc=e.ctrlsSvc}areHeaderCellsRendered(){return this.ctrlsSvc.getHeaderRowContainerCtrls().every(e=>e.getAllCtrls().every(t=>t.areCellsRendered()))}},JS={setGridApi:void 0,maxComponentCreationTimeMs:void 0,children:void 0},aG={gridOptions:void 0,modules:void 0,containerStyle:void 0,className:void 0,passGridApi:void 0,componentWrappingElement:void 0,...JS},XS=new Set(Object.keys(aG)),lG=new Set(Object.keys(JS)),ZS=e=>{var p;const t=v.useRef(),r=v.useRef(null),n=v.useRef(null),i=v.useRef([]),o=v.useRef([]),s=v.useRef(e),a=v.useRef(),l=v.useRef(),c=v.useRef(!1),[u,d]=v.useState(void 0),[,h]=v.useState(0),f=v.useCallback(y=>{if(r.current=y,!y){i.current.forEach(R=>R()),i.current.length=0;return}const w=e.modules||[];n.current||(n.current=new EH(()=>h(R=>R+1),e.componentWrappingElement,e.maxComponentCreationTimeMs),i.current.push(()=>{var R;(R=n.current)==null||R.destroy(),n.current=null}));const b=vI(e.gridOptions,e,Object.keys(e).filter(R=>!XS.has(R))),x=()=>{if(c.current){const R=()=>{var F;return(F=a.current)!=null&&F.shouldQueueUpdates()?void 0:o.current.shift()};let T=R();for(;T;)T(),T=R()}},C=new hG(x);a.current=C;const S=new sG,A={providedBeanInstances:{frameworkCompWrapper:new uG(n.current,b.reactiveCustomComponents??r$("reactiveCustomComponents")??!0),renderStatus:S},modules:w,frameworkOverrides:C,setThemeOnGridDiv:!0},P=R=>{d(R),R.createBean(S),i.current.push(()=>{R.destroy()}),R.getBean("ctrlsSvc").whenReady({addDestroyFunc:T=>{i.current.push(T)}},()=>{var F;if(R.isDestroyed())return;const T=t.current;T&&((F=e.passGridApi)==null||F.call(e,T))})},E=R=>{R.getBean("ctrlsSvc").whenReady({addDestroyFunc:T=>{i.current.push(T)}},()=>{o.current.forEach(T=>T()),o.current.length=0,c.current=!0})},O=new i$;b.gridId??(b.gridId=l.current),t.current=O.create(y,b,P,E,A),i.current.push(()=>{t.current=void 0}),t.current&&(l.current=t.current.getGridId())},[]),g=v.useMemo(()=>({height:"100%",...e.containerStyle||{}}),[e.containerStyle]),m=v.useCallback(y=>{var w;c.current&&!((w=a.current)!=null&&w.shouldQueueUpdates())?y():o.current.push(y)},[]);return v.useEffect(()=>{const y=cG(s.current,e);s.current=e,m(()=>{t.current&&yI(y,t.current)})},[e]),v.createElement("div",{style:g,className:e.className,ref:f},u&&!u.isDestroyed()?v.createElement(oG,{context:u}):null,((p=n.current)==null?void 0:p.getPortals())??null)};function cG(e,t){const r={};return Object.keys(t).forEach(n=>{if(XS.has(n)){lG.has(n)&&Q(274,{prop:n});return}const i=t[n];e[n]!==i&&(r[n]=i)}),r}var uG=class extends s${constructor(e,t){super(),this.parent=e,this.reactiveCustomComponents=t}createWrapper(e,t){if(this.reactiveCustomComponents){const i=(o=>{switch(o){case"filter":return vH;case"floatingFilterComponent":return bH;case"dateComponent":return pH;case"dragAndDropImageComponent":return mH;case"loadingOverlayComponent":return wH;case"noRowsOverlayComponent":return xH;case"statusPanel":return AH;case"toolPanel":return PH;case"menuItem":return SH;case"cellRenderer":return gH;case"innerHeaderComponent":return CH}})(t.name);if(i)return new i(e,this.parent,t)}else switch(t.name){case"filter":case"floatingFilterComponent":case"dateComponent":case"dragAndDropImageComponent":case"loadingOverlayComponent":case"noRowsOverlayComponent":case"statusPanel":case"toolPanel":case"menuItem":case"cellRenderer":Fp();break}const r=!t.cellRenderer&&t.name!=="toolPanel";return new qS(e,this.parent,t,r)}},dG=v.forwardRef((e,t)=>{const r=v.useContext(mt),{registry:n,context:i,gos:o,rowModel:s}=r,[a,l]=v.useState(()=>new Kt),[c,u]=v.useState(()=>new Kt),[d,h]=v.useState(),[f,g]=v.useState(),m=v.useRef(),p=v.useRef(null),y=v.useRef(),w=v.useMemo(()=>G_(e.api.getGridId(),(d==null?void 0:d.rowModelType)??"clientSide"),[e]),b=v.useMemo(()=>a.toString()+" ag-details-row",[a]),x=v.useMemo(()=>c.toString()+" ag-details-grid",[c]);t&&v.useImperativeHandle(t,()=>({refresh(){var A;return((A=m.current)==null?void 0:A.refresh())??!1}})),e.template&&Q(230);const C=v.useCallback(A=>{var O;if(p.current=A,!A){m.current=i.destroyBean(m.current),(O=y.current)==null||O.call(y);return}const P={toggleCss:(R,T)=>l(F=>F.setClass(R,T)),toggleDetailGridCss:(R,T)=>u(F=>F.setClass(R,T)),setDetailGrid:R=>h(R),setRowData:R=>g(R),getGui:()=>p.current},E=n.createDynamicBean("detailCellRendererCtrl",!0);if(E&&(i.createBean(E),E.init(P,e),m.current=E,o.get("detailRowAutoHeight"))){const R=()=>{if(p.current==null)return;const T=p.current.clientHeight;T!=null&&T>0&&setTimeout(()=>{e.node.setRowHeight(T),(xt(o)||po(o))&&s.onRowHeightChanged()},0)};y.current=fn(r,A,R),R()}},[]),S=v.useCallback(A=>{var P;(P=m.current)==null||P.registerDetailWithMaster(A)},[]);return v.createElement("div",{className:b,ref:C},d&&v.createElement(ZS,{className:x,...d,modules:w,rowData:f,passGridApi:S}))}),hG=class extends sS{constructor(e){super("react"),this.processQueuedUpdates=e,this.queueUpdates=!1,this.renderingEngine="react",this.frameworkComponents={agGroupCellRenderer:wy,agGroupRowRenderer:wy,agDetailCellRenderer:dG},this.wrapIncoming=(t,r)=>r==="ensureVisible"?uH(t):t()}frameworkComponent(e){return this.frameworkComponents[e]}isFrameworkComponent(e){if(!e)return!1;const t=e.prototype;return!(t&&"getGui"in t)}getLockOnRefresh(){this.queueUpdates=!0}releaseLockOnRefresh(){this.queueUpdates=!1,this.processQueuedUpdates()}shouldQueueUpdates(){return this.queueUpdates}runWhenReadyAsync(){return cH()}},QS=class extends v.Component{constructor(){super(...arguments),this.apiListeners=[],this.setGridApi=e=>{this.api=e,this.apiListeners.forEach(t=>t(e))}}registerApiListener(e){this.apiListeners.push(e)}componentWillUnmount(){this.apiListeners.length=0}render(){return v.createElement(ZS,{...this.props,passGridApi:this.setGridApi})}};const Dr=typeof window<"u"&&typeof window.matchMedia=="function"?window.matchMedia("(prefers-color-scheme: dark)"):null;function fG(e){return Dr==null||Dr.addEventListener("change",e),()=>Dr==null?void 0:Dr.removeEventListener("change",e)}function gG(){return Dr!=null&&Dr.matches?"dark":"light"}function pG(){return"dark"}function Op(){return v.useSyncExternalStore(fG,gG,pG)}V_.registerModules([C4,O4,U4,L4,W4,c4,Y4,q$]);const mG="#2196F3",vG={rowSelection:"single",enableCellTextSelection:!0,tooltipShowDelay:0,suppressFieldDotNotation:!0,onRowClicked:e=>{var i;const t=document.getSelection();if(t===null)return;const r=document.createRange(),n=(i=e==null?void 0:e.event)==null?void 0:i.target;n!=null&&(r.selectNodeContents(n),t.removeAllRanges(),t.addRange(r))}},yG=(e,t)=>({...vG,...t||{},onCellClicked:r=>{const n=r.column.getColId();if(!(e===void 0||n===void 0)){const i=r.context.activeCol,o=[n,r.column.colDef.headerName];e(o),r.context.activeCol=o;const s={rowNodes:r.api.getRenderedNodes(),columns:[r.api.getColumn(n),r.api.getColumn(i[0])],force:!0};r.api.refreshCells(s)}}});function ni({data_wrapper:e,df_viewer_config:t,summary_stats_data:r,activeCol:n,setActiveCol:i,outside_df_params:o,error_info:s,max_rows_in_configs:a}){var A;const l=v.useMemo(()=>Date.now(),[]),c=5,u=t==null?void 0:t.component_config,d=(A=t==null?void 0:t.extra_grid_config)==null?void 0:A.rowHeight,h=JSON.stringify([c,u,d]),f=v.useMemo(()=>{var P;return Dhe(a||e.length,t.pinned_rows.length,t==null?void 0:t.component_config,(P=t==null?void 0:t.extra_grid_config)==null?void 0:P.rowHeight)},[h]),g=["",""],m=Op(),p=u==null?void 0:u.theme,y=WR(m,p),w=jR(y,p),x=`${y==="light"?"ag-theme-alpine":"ag-theme-alpine-dark"} ${(u==null?void 0:u.className)||""}`.trim(),C=(w==null?void 0:w.backgroundColor)||(y==="light"?"#ffffff":"#181D1F"),S={...f.applicableStyle,...w!=null&&w.accentColor?{"--bk-accent-color":w.accentColor}:{},...w!=null&&w.accentHoverColor?{"--bk-accent-hover-color":w.accentHoverColor}:{},"--bk-bg-color":C,...w!=null&&w.foregroundColor?{"--bk-fg-color":w.foregroundColor}:{}};return M.jsxs("div",{className:`df-viewer ${f.classMode} ${f.inIframe}`,children:[s?M.jsx("pre",{children:s}):null,M.jsx("div",{style:S,className:`theme-hanger ${x}`,children:M.jsx(bG,{data_wrapper:e,df_viewer_config:t,summary_stats_data:r||[],activeCol:n||g,setActiveCol:i,outside_df_params:o,renderStartTime:l,hs:f,themeConfig:w,effectiveScheme:y})})]})}function bG({data_wrapper:e,df_viewer_config:t,summary_stats_data:r,activeCol:n,setActiveCol:i,outside_df_params:o,renderStartTime:s,hs:a,themeConfig:l,effectiveScheme:c}){const u=v.useMemo(()=>Fhe(t),[t]),d=v.useMemo(()=>({sortable:!0,type:"rightAligned",cellStyle:R=>{var k;const F=R.column.getColDef().field,I=(k=R.context)==null?void 0:k.activeCol[0];if(!R.node.isRowPinned())return I===F?{background:(l==null?void 0:l.accentColor)||mG}:{background:"inherit"}},enableCellChangeFlash:!1,cellRendererSelector:Ohe(t.pinned_rows,t.column_config)}),[t.pinned_rows,t.column_config]),h=Mhe(r),f={activeCol:n,histogram_stats:h,pinned_rows_config:t.pinned_rows},g=t.pinned_rows,m=v.useMemo(()=>Ehe(r,g||[]),[r,g]),p=v.useCallback(R=>{var I,k;const T=JSON.stringify((I=R.context)==null?void 0:I.outside_df_params)||"";return`${String((k=R==null?void 0:R.data)==null?void 0:k.index)}-${T}`},[o]),y=c||"dark",w=v.useMemo(()=>VR(y,l).withParams({headerRowBorder:!0,headerColumnBorder:!0,headerColumnResizeHandleWidth:0,...y==="dark"?{backgroundColor:(l==null?void 0:l.backgroundColor)||"#121212",oddRowBackgroundColor:(l==null?void 0:l.oddRowBackgroundColor)||"#3f3f3f"}:{backgroundColor:(l==null?void 0:l.backgroundColor)||"#ffffff",oddRowBackgroundColor:(l==null?void 0:l.oddRowBackgroundColor)||"#f0f0f0"}}),[y,l]),b=v.useMemo(()=>{var R;return{...yG(i,t.extra_grid_config),domLayout:a.domLayout,autoSizeStrategy:((R=t.extra_grid_config)==null?void 0:R.autoSizeStrategy)||_he(u.length),onFirstDataRendered:T=>{},columnDefs:u,getRowId:p,rowModelType:"clientSide"}},[u.length,JSON.stringify(u),a,t.extra_grid_config,i,p,o]),x=v.useMemo(()=>e.data_type==="DataSource"?e.datasource:{rowCount:e.length,getRows:R=>{throw console.debug("fake datasource getRows called, unexpected"),new Error("fake datasource getRows called, unexpected")}},[e]),C=v.useMemo(()=>CG(e,b,a),[e,b,a]),S=v.useRef(null),A=v.useRef(null),P=v.useMemo(()=>{try{return u.map(R=>R==null?void 0:R.field).filter(Boolean)}catch{return[]}},[u]),E=v.useMemo(()=>{const R=(m||[]).map(F=>P.map(I=>F==null?void 0:F[I])),T=(g||[]).map(F=>F.primary_key_val);return JSON.stringify({k:T,f:P,v:R})},[m,P,g]);v.useEffect(()=>{var R,T;try{const F=(m||[]).map(I=>({...I}));A.current=F,(T=(R=S.current)==null?void 0:R.api)==null||T.setGridOption("pinnedTopRowData",F)}catch{}},[E]);const O=v.useMemo(()=>e.data_type==="Raw"?JSON.stringify(e.data):null,[e]);return v.useEffect(()=>{var R;if(e.data_type==="Raw"&&((R=S.current)!=null&&R.api)&&O)try{S.current.api.setGridOption("rowData",e.data)}catch{}},[O,e.data_type,e]),M.jsx(QS,{ref:S,theme:w,loadThemeGoogleFonts:!0,gridOptions:C,defaultColDef:d,datasource:x,columnDefs:u,onGridReady:R=>{try{R.api.setGridOption("pinnedTopRowData",A.current||[])}catch{}},context:{outside_df_params:o,...f}},JSON.stringify(o)||"no-outside-params")}const CG=(e,t,r)=>{if(e.data_type==="Raw")return{...t,rowData:e.data,suppressNoRowsOverlay:!0};if(e.data_type==="DataSource")return wG(t,r.maxRowsWithoutScrolling);throw new Error(`Unexpected data_wrapper.data_type on ${e}`)},wG=(e,t)=>({...e,animateRows:!1,suppressNoRowsOverlay:!0,onSortChanged:n=>{const i=n.api;console.log("sortChanged",i.getFirstDisplayedRowIndex(),i.getLastDisplayedRowIndex(),n),i.ensureIndexVisible(0)},rowBuffer:20,rowModelType:"infinite",cacheBlockSize:t+50,cacheOverflowSize:0,maxConcurrentDatasourceRequests:3,maxBlocksInCache:0});function gu({df_data:e,df_viewer_config:t,summary_stats_data:r,activeCol:n,setActiveCol:i}){const s=i||(a=>{console.log("defaultSetColumnFunc",a)});return M.jsx(ni,{data_wrapper:{data_type:"Raw",data:e,length:e.length},df_viewer_config:t,summary_stats_data:r,activeCol:n,setActiveCol:s})}const SG=e=>r=>{if(r.data.index==="histogram")return;const n=r.data[e].toString();return M.jsx("div",{className:"ag-tooltip",children:n})},xG=e=>{if(e===void 0)return{};switch(e.tooltip_type){case"simple":return{tooltipComponent:SG(e.val_column),tooltipField:e.val_column};case"summary_series":return{}}};function ex(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(r=ex(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function ve(){for(var e,t,r=0,n="",i=arguments.length;r<i;r++)(e=arguments[r])&&(t=ex(e))&&(n&&(n+=" "),n+=t);return n}var qa=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Le(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var AG=Array.isArray,Mt=AG,PG=typeof qa=="object"&&qa&&qa.Object===Object&&qa,tx=PG,RG=tx,EG=typeof self=="object"&&self&&self.Object===Object&&self,TG=RG||EG||Function("return this")(),Tr=TG,FG=Tr,OG=FG.Symbol,Fa=OG,Ry=Fa,rx=Object.prototype,MG=rx.hasOwnProperty,DG=rx.toString,Go=Ry?Ry.toStringTag:void 0;function kG(e){var t=MG.call(e,Go),r=e[Go];try{e[Go]=void 0;var n=!0}catch{}var i=DG.call(e);return n&&(t?e[Go]=r:delete e[Go]),i}var IG=kG,_G=Object.prototype,LG=_G.toString;function BG(e){return LG.call(e)}var zG=BG,Ey=Fa,NG=IG,$G=zG,HG="[object Null]",GG="[object Undefined]",Ty=Ey?Ey.toStringTag:void 0;function WG(e){return e==null?e===void 0?GG:HG:Ty&&Ty in Object(e)?NG(e):$G(e)}var Kr=WG;function jG(e){return e!=null&&typeof e=="object"}var qr=jG,VG=Kr,UG=qr,KG="[object Symbol]";function qG(e){return typeof e=="symbol"||UG(e)&&VG(e)==KG}var So=qG,YG=Mt,JG=So,XG=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ZG=/^\w*$/;function QG(e,t){if(YG(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||JG(e)?!0:ZG.test(e)||!XG.test(e)||t!=null&&e in Object(t)}var Mp=QG;function e6(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var gn=e6;const xo=Le(gn);var t6=Kr,r6=gn,n6="[object AsyncFunction]",i6="[object Function]",o6="[object GeneratorFunction]",s6="[object Proxy]";function a6(e){if(!r6(e))return!1;var t=t6(e);return t==i6||t==o6||t==n6||t==s6}var Dp=a6;const ge=Le(Dp);var l6=Tr,c6=l6["__core-js_shared__"],u6=c6,Id=u6,Fy=function(){var e=/[^.]+$/.exec(Id&&Id.keys&&Id.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function d6(e){return!!Fy&&Fy in e}var h6=d6,f6=Function.prototype,g6=f6.toString;function p6(e){if(e!=null){try{return g6.call(e)}catch{}try{return e+""}catch{}}return""}var nx=p6,m6=Dp,v6=h6,y6=gn,b6=nx,C6=/[\\^$.*+?()[\]{}|]/g,w6=/^\[object .+?Constructor\]$/,S6=Function.prototype,x6=Object.prototype,A6=S6.toString,P6=x6.hasOwnProperty,R6=RegExp("^"+A6.call(P6).replace(C6,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function E6(e){if(!y6(e)||v6(e))return!1;var t=m6(e)?R6:w6;return t.test(b6(e))}var T6=E6;function F6(e,t){return e==null?void 0:e[t]}var O6=F6,M6=T6,D6=O6;function k6(e,t){var r=D6(e,t);return M6(r)?r:void 0}var ii=k6,I6=ii,_6=I6(Object,"create"),pu=_6,Oy=pu;function L6(){this.__data__=Oy?Oy(null):{},this.size=0}var B6=L6;function z6(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var N6=z6,$6=pu,H6="__lodash_hash_undefined__",G6=Object.prototype,W6=G6.hasOwnProperty;function j6(e){var t=this.__data__;if($6){var r=t[e];return r===H6?void 0:r}return W6.call(t,e)?t[e]:void 0}var V6=j6,U6=pu,K6=Object.prototype,q6=K6.hasOwnProperty;function Y6(e){var t=this.__data__;return U6?t[e]!==void 0:q6.call(t,e)}var J6=Y6,X6=pu,Z6="__lodash_hash_undefined__";function Q6(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=X6&&t===void 0?Z6:t,this}var eW=Q6,tW=B6,rW=N6,nW=V6,iW=J6,oW=eW;function Ao(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Ao.prototype.clear=tW;Ao.prototype.delete=rW;Ao.prototype.get=nW;Ao.prototype.has=iW;Ao.prototype.set=oW;var sW=Ao;function aW(){this.__data__=[],this.size=0}var lW=aW;function cW(e,t){return e===t||e!==e&&t!==t}var kp=cW,uW=kp;function dW(e,t){for(var r=e.length;r--;)if(uW(e[r][0],t))return r;return-1}var mu=dW,hW=mu,fW=Array.prototype,gW=fW.splice;function pW(e){var t=this.__data__,r=hW(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():gW.call(t,r,1),--this.size,!0}var mW=pW,vW=mu;function yW(e){var t=this.__data__,r=vW(t,e);return r<0?void 0:t[r][1]}var bW=yW,CW=mu;function wW(e){return CW(this.__data__,e)>-1}var SW=wW,xW=mu;function AW(e,t){var r=this.__data__,n=xW(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var PW=AW,RW=lW,EW=mW,TW=bW,FW=SW,OW=PW;function Po(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Po.prototype.clear=RW;Po.prototype.delete=EW;Po.prototype.get=TW;Po.prototype.has=FW;Po.prototype.set=OW;var vu=Po,MW=ii,DW=Tr,kW=MW(DW,"Map"),Ip=kW,My=sW,IW=vu,_W=Ip;function LW(){this.size=0,this.__data__={hash:new My,map:new(_W||IW),string:new My}}var BW=LW;function zW(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var NW=zW,$W=NW;function HW(e,t){var r=e.__data__;return $W(t)?r[typeof t=="string"?"string":"hash"]:r.map}var yu=HW,GW=yu;function WW(e){var t=GW(this,e).delete(e);return this.size-=t?1:0,t}var jW=WW,VW=yu;function UW(e){return VW(this,e).get(e)}var KW=UW,qW=yu;function YW(e){return qW(this,e).has(e)}var JW=YW,XW=yu;function ZW(e,t){var r=XW(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var QW=ZW,ej=BW,tj=jW,rj=KW,nj=JW,ij=QW;function Ro(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Ro.prototype.clear=ej;Ro.prototype.delete=tj;Ro.prototype.get=rj;Ro.prototype.has=nj;Ro.prototype.set=ij;var _p=Ro,ix=_p,oj="Expected a function";function Lp(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(oj);var r=function(){var n=arguments,i=t?t.apply(this,n):n[0],o=r.cache;if(o.has(i))return o.get(i);var s=e.apply(this,n);return r.cache=o.set(i,s)||o,s};return r.cache=new(Lp.Cache||ix),r}Lp.Cache=ix;var ox=Lp;const sj=Le(ox);var aj=ox,lj=500;function cj(e){var t=aj(e,function(n){return r.size===lj&&r.clear(),n}),r=t.cache;return t}var uj=cj,dj=uj,hj=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,fj=/\\(\\)?/g,gj=dj(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(hj,function(r,n,i,o){t.push(i?o.replace(fj,"$1"):n||r)}),t}),pj=gj;function mj(e,t){for(var r=-1,n=e==null?0:e.length,i=Array(n);++r<n;)i[r]=t(e[r],r,e);return i}var Bp=mj,Dy=Fa,vj=Bp,yj=Mt,bj=So,ky=Dy?Dy.prototype:void 0,Iy=ky?ky.toString:void 0;function sx(e){if(typeof e=="string")return e;if(yj(e))return vj(e,sx)+"";if(bj(e))return Iy?Iy.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var Cj=sx,wj=Cj;function Sj(e){return e==null?"":wj(e)}var ax=Sj,xj=Mt,Aj=Mp,Pj=pj,Rj=ax;function Ej(e,t){return xj(e)?e:Aj(e,t)?[e]:Pj(Rj(e))}var lx=Ej,Tj=So;function Fj(e){if(typeof e=="string"||Tj(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var bu=Fj,Oj=lx,Mj=bu;function Dj(e,t){t=Oj(t,e);for(var r=0,n=t.length;e!=null&&r<n;)e=e[Mj(t[r++])];return r&&r==n?e:void 0}var zp=Dj,kj=zp;function Ij(e,t,r){var n=e==null?void 0:kj(e,t);return n===void 0?r:n}var cx=Ij;const Yt=Le(cx);function _j(e){return e==null}var Lj=_j;const ue=Le(Lj);var Bj=Kr,zj=Mt,Nj=qr,$j="[object String]";function Hj(e){return typeof e=="string"||!zj(e)&&Nj(e)&&Bj(e)==$j}var Gj=Hj;const Jn=Le(Gj);var Uh={exports:{}},Ce={};/**
24
+ * @license React
25
+ * react-is.production.min.js
26
+ *
27
+ * Copyright (c) Facebook, Inc. and its affiliates.
28
+ *
29
+ * This source code is licensed under the MIT license found in the
30
+ * LICENSE file in the root directory of this source tree.
31
+ */var _y;function Wj(){if(_y)return Ce;_y=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),s=Symbol.for("react.context"),a=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),f=Symbol.for("react.offscreen"),g;g=Symbol.for("react.module.reference");function m(p){if(typeof p=="object"&&p!==null){var y=p.$$typeof;switch(y){case e:switch(p=p.type,p){case r:case i:case n:case c:case u:return p;default:switch(p=p&&p.$$typeof,p){case a:case s:case l:case h:case d:case o:return p;default:return y}}case t:return y}}}return Ce.ContextConsumer=s,Ce.ContextProvider=o,Ce.Element=e,Ce.ForwardRef=l,Ce.Fragment=r,Ce.Lazy=h,Ce.Memo=d,Ce.Portal=t,Ce.Profiler=i,Ce.StrictMode=n,Ce.Suspense=c,Ce.SuspenseList=u,Ce.isAsyncMode=function(){return!1},Ce.isConcurrentMode=function(){return!1},Ce.isContextConsumer=function(p){return m(p)===s},Ce.isContextProvider=function(p){return m(p)===o},Ce.isElement=function(p){return typeof p=="object"&&p!==null&&p.$$typeof===e},Ce.isForwardRef=function(p){return m(p)===l},Ce.isFragment=function(p){return m(p)===r},Ce.isLazy=function(p){return m(p)===h},Ce.isMemo=function(p){return m(p)===d},Ce.isPortal=function(p){return m(p)===t},Ce.isProfiler=function(p){return m(p)===i},Ce.isStrictMode=function(p){return m(p)===n},Ce.isSuspense=function(p){return m(p)===c},Ce.isSuspenseList=function(p){return m(p)===u},Ce.isValidElementType=function(p){return typeof p=="string"||typeof p=="function"||p===r||p===i||p===n||p===c||p===u||p===f||typeof p=="object"&&p!==null&&(p.$$typeof===h||p.$$typeof===d||p.$$typeof===o||p.$$typeof===s||p.$$typeof===l||p.$$typeof===g||p.getModuleId!==void 0)},Ce.typeOf=m,Ce}var we={};/**
32
+ * @license React
33
+ * react-is.development.js
34
+ *
35
+ * Copyright (c) Facebook, Inc. and its affiliates.
36
+ *
37
+ * This source code is licensed under the MIT license found in the
38
+ * LICENSE file in the root directory of this source tree.
39
+ */var Ly;function jj(){return Ly||(Ly=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),s=Symbol.for("react.context"),a=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),f=Symbol.for("react.offscreen"),g=!1,m=!1,p=!1,y=!1,w=!1,b;b=Symbol.for("react.module.reference");function x(U){return!!(typeof U=="string"||typeof U=="function"||U===r||U===i||w||U===n||U===c||U===u||y||U===f||g||m||p||typeof U=="object"&&U!==null&&(U.$$typeof===h||U.$$typeof===d||U.$$typeof===o||U.$$typeof===s||U.$$typeof===l||U.$$typeof===b||U.getModuleId!==void 0))}function C(U){if(typeof U=="object"&&U!==null){var ce=U.$$typeof;switch(ce){case e:var me=U.type;switch(me){case r:case i:case n:case c:case u:return me;default:var ae=me&&me.$$typeof;switch(ae){case a:case s:case l:case h:case d:case o:return ae;default:return ce}}case t:return ce}}}var S=s,A=o,P=e,E=l,O=r,R=h,T=d,F=t,I=i,k=n,B=c,N=u,z=!1,W=!1;function D(U){return z||(z=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function L(U){return W||(W=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function $(U){return C(U)===s}function H(U){return C(U)===o}function V(U){return typeof U=="object"&&U!==null&&U.$$typeof===e}function X(U){return C(U)===l}function Y(U){return C(U)===r}function re(U){return C(U)===h}function oe(U){return C(U)===d}function K(U){return C(U)===t}function J(U){return C(U)===i}function te(U){return C(U)===n}function _(U){return C(U)===c}function ne(U){return C(U)===u}we.ContextConsumer=S,we.ContextProvider=A,we.Element=P,we.ForwardRef=E,we.Fragment=O,we.Lazy=R,we.Memo=T,we.Portal=F,we.Profiler=I,we.StrictMode=k,we.Suspense=B,we.SuspenseList=N,we.isAsyncMode=D,we.isConcurrentMode=L,we.isContextConsumer=$,we.isContextProvider=H,we.isElement=V,we.isForwardRef=X,we.isFragment=Y,we.isLazy=re,we.isMemo=oe,we.isPortal=K,we.isProfiler=J,we.isStrictMode=te,we.isSuspense=_,we.isSuspenseList=ne,we.isValidElementType=x,we.typeOf=C}()),we}process.env.NODE_ENV==="production"?Uh.exports=Wj():Uh.exports=jj();var Vj=Uh.exports,Uj=Kr,Kj=qr,qj="[object Number]";function Yj(e){return typeof e=="number"||Kj(e)&&Uj(e)==qj}var ux=Yj;const Jj=Le(ux);var Xj=ux;function Zj(e){return Xj(e)&&e!=+e}var Qj=Zj;const Eo=Le(Qj);var ar=function(t){return t===0?0:t>0?1:-1},Kh=function(t){return Jn(t)&&t.indexOf("%")===t.length-1},Z=function(t){return Jj(t)&&!Eo(t)},et=function(t){return Z(t)||Jn(t)},e5=0,oi=function(t){var r=++e5;return"".concat(t||"").concat(r)},Xn=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!Z(t)&&!Jn(t))return n;var o;if(Kh(t)){var s=t.indexOf("%");o=r*parseFloat(t.slice(0,s))/100}else o=+t;return Eo(o)&&(o=n),i&&o>r&&(o=r),o},gi=function(t){if(!t)return null;var r=Object.keys(t);return r&&r.length?t[r[0]]:null},t5=function(t){if(!Array.isArray(t))return!1;for(var r=t.length,n={},i=0;i<r;i++)if(!n[t[i]])n[t[i]]=!0;else return!0;return!1},Ue=function(t,r){return Z(t)&&Z(r)?function(n){return t+n*(r-t)}:function(){return r}};function Kl(e,t,r){return!e||!e.length?null:e.find(function(n){return n&&(typeof t=="function"?t(n):Yt(n,t))===r})}var r5=function(t){if(!t||!t.length)return null;for(var r=t.length,n=0,i=0,o=0,s=0,a=1/0,l=-1/0,c=0,u=0,d=0;d<r;d++)c=t[d].cx||0,u=t[d].cy||0,n+=c,i+=u,o+=c*u,s+=c*c,a=Math.min(a,c),l=Math.max(l,c);var h=r*s!==n*n?(r*o-n*i)/(r*s-n*n):0;return{xmin:a,xmax:l,a:h,b:(i-h*n)/r}},n5=function(t,r){return Z(t)&&Z(r)?t-r:Jn(t)&&Jn(r)?t.localeCompare(r):t instanceof Date&&r instanceof Date?t.getTime()-r.getTime():String(t).localeCompare(String(r))};function Fi(e,t){for(var r in e)if({}.hasOwnProperty.call(e,r)&&(!{}.hasOwnProperty.call(t,r)||e[r]!==t[r]))return!1;for(var n in t)if({}.hasOwnProperty.call(t,n)&&!{}.hasOwnProperty.call(e,n))return!1;return!0}function qh(e){"@babel/helpers - typeof";return qh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},qh(e)}var i5=["viewBox","children"],o5=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"],By=["points","pathLength"],_d={svg:i5,polygon:By,polyline:By},Np=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDragCapture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"],ql=function(t,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var n=t;if(v.isValidElement(t)&&(n=t.props),!xo(n))return null;var i={};return Object.keys(n).forEach(function(o){Np.includes(o)&&(i[o]=r||function(s){return n[o](n,s)})}),i},s5=function(t,r,n){return function(i){return t(r,n,i),null}},Is=function(t,r,n){if(!xo(t)||qh(t)!=="object")return null;var i=null;return Object.keys(t).forEach(function(o){var s=t[o];Np.includes(o)&&typeof s=="function"&&(i||(i={}),i[o]=s5(s,r,n))}),i},a5=["children"],l5=["children"];function zy(e,t){if(e==null)return{};var r=c5(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function c5(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Yh(e){"@babel/helpers - typeof";return Yh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Yh(e)}var Ny={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart",contextmenu:"onContextMenu",dblclick:"onDoubleClick"},sn=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},$y=null,Ld=null,$p=function e(t){if(t===$y&&Array.isArray(Ld))return Ld;var r=[];return v.Children.forEach(t,function(n){ue(n)||(Vj.isFragment(n)?r=r.concat(e(n.props.children)):r.push(n))}),Ld=r,$y=t,r};function Tt(e,t){var r=[],n=[];return Array.isArray(t)?n=t.map(function(i){return sn(i)}):n=[sn(t)],$p(e).forEach(function(i){var o=Yt(i,"type.displayName")||Yt(i,"type.name");n.indexOf(o)!==-1&&r.push(i)}),r}function Lt(e,t){var r=Tt(e,t);return r&&r[0]}var Hy=function(t){if(!t||!t.props)return!1;var r=t.props,n=r.width,i=r.height;return!(!Z(n)||n<=0||!Z(i)||i<=0)},u5=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],d5=function(t){return t&&t.type&&Jn(t.type)&&u5.indexOf(t.type)>=0},dx=function(t){return t&&Yh(t)==="object"&&"clipDot"in t},h5=function(t,r,n,i){var o,s=(o=_d==null?void 0:_d[i])!==null&&o!==void 0?o:[];return r.startsWith("data-")||!ge(t)&&(i&&s.includes(r)||o5.includes(r))||n&&Np.includes(r)},de=function(t,r,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(v.isValidElement(t)&&(i=t.props),!xo(i))return null;var o={};return Object.keys(i).forEach(function(s){var a;h5((a=i)===null||a===void 0?void 0:a[s],s,r,n)&&(o[s]=i[s])}),o},Jh=function e(t,r){if(t===r)return!0;var n=v.Children.count(t);if(n!==v.Children.count(r))return!1;if(n===0)return!0;if(n===1)return Gy(Array.isArray(t)?t[0]:t,Array.isArray(r)?r[0]:r);for(var i=0;i<n;i++){var o=t[i],s=r[i];if(Array.isArray(o)||Array.isArray(s)){if(!e(o,s))return!1}else if(!Gy(o,s))return!1}return!0},Gy=function(t,r){if(ue(t)&&ue(r))return!0;if(!ue(t)&&!ue(r)){var n=t.props||{},i=n.children,o=zy(n,a5),s=r.props||{},a=s.children,l=zy(s,l5);return i&&a?Fi(o,l)&&Jh(i,a):!i&&!a?Fi(o,l):!1}return!1},Wy=function(t,r){var n=[],i={};return $p(t).forEach(function(o,s){if(d5(o))n.push(o);else if(o){var a=sn(o.type),l=r[a]||{},c=l.handler,u=l.once;if(c&&(!u||!i[a])){var d=c(o,a,s);n.push(d),i[a]=!0}}}),n},f5=function(t){var r=t&&t.type;return r&&Ny[r]?Ny[r]:null},g5=function(t,r){return $p(r).indexOf(t)},p5=["children","width","height","viewBox","className","style","title","desc"];function Xh(){return Xh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Xh.apply(this,arguments)}function m5(e,t){if(e==null)return{};var r=v5(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function v5(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Zh(e){var t=e.children,r=e.width,n=e.height,i=e.viewBox,o=e.className,s=e.style,a=e.title,l=e.desc,c=m5(e,p5),u=i||{width:r,height:n,x:0,y:0},d=ve("recharts-surface",o);return v.createElement("svg",Xh({},de(c,!0,"svg"),{className:d,width:r,height:n,style:s,viewBox:"".concat(u.x," ").concat(u.y," ").concat(u.width," ").concat(u.height)}),v.createElement("title",null,a),v.createElement("desc",null,l),t)}var y5=["children","className"];function Qh(){return Qh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Qh.apply(this,arguments)}function b5(e,t){if(e==null)return{};var r=C5(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function C5(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var be=v.forwardRef(function(e,t){var r=e.children,n=e.className,i=b5(e,y5),o=ve("recharts-layer",n);return v.createElement("g",Qh({className:o},de(i,!0),{ref:t}),r)}),w5=process.env.NODE_ENV!=="production",Cu=function(t,r){for(var n=arguments.length,i=new Array(n>2?n-2:0),o=2;o<n;o++)i[o-2]=arguments[o];if(w5&&typeof console<"u"&&console.warn&&(r===void 0&&console.warn("LogUtils requires an error message argument"),!t))if(r===void 0)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var s=0;console.warn(r.replace(/%s/g,function(){return i[s++]}))}};function S5(e,t,r){var n=-1,i=e.length;t<0&&(t=-t>i?0:i+t),r=r>i?i:r,r<0&&(r+=i),i=t>r?0:r-t>>>0,t>>>=0;for(var o=Array(i);++n<i;)o[n]=e[n+t];return o}var x5=S5,A5=x5;function P5(e,t,r){var n=e.length;return r=r===void 0?n:r,!t&&r>=n?e:A5(e,t,r)}var R5=P5,E5="\\ud800-\\udfff",T5="\\u0300-\\u036f",F5="\\ufe20-\\ufe2f",O5="\\u20d0-\\u20ff",M5=T5+F5+O5,D5="\\ufe0e\\ufe0f",k5="\\u200d",I5=RegExp("["+k5+E5+M5+D5+"]");function _5(e){return I5.test(e)}var hx=_5;function L5(e){return e.split("")}var B5=L5,fx="\\ud800-\\udfff",z5="\\u0300-\\u036f",N5="\\ufe20-\\ufe2f",$5="\\u20d0-\\u20ff",H5=z5+N5+$5,G5="\\ufe0e\\ufe0f",W5="["+fx+"]",ef="["+H5+"]",tf="\\ud83c[\\udffb-\\udfff]",j5="(?:"+ef+"|"+tf+")",gx="[^"+fx+"]",px="(?:\\ud83c[\\udde6-\\uddff]){2}",mx="[\\ud800-\\udbff][\\udc00-\\udfff]",V5="\\u200d",vx=j5+"?",yx="["+G5+"]?",U5="(?:"+V5+"(?:"+[gx,px,mx].join("|")+")"+yx+vx+")*",K5=yx+vx+U5,q5="(?:"+[gx+ef+"?",ef,px,mx,W5].join("|")+")",Y5=RegExp(tf+"(?="+tf+")|"+q5+K5,"g");function J5(e){return e.match(Y5)||[]}var X5=J5,Z5=B5,Q5=hx,eV=X5;function tV(e){return Q5(e)?eV(e):Z5(e)}var rV=tV,nV=R5,iV=hx,oV=rV,sV=ax;function aV(e){return function(t){t=sV(t);var r=iV(t)?oV(t):void 0,n=r?r[0]:t.charAt(0),i=r?nV(r,1).join(""):t.slice(1);return n[e]()+i}}var lV=aV,cV=lV,uV=cV("toUpperCase"),dV=uV;const wu=Le(dV);function Oe(e){return function(){return e}}const bx=Math.cos,Yl=Math.sin,dr=Math.sqrt,Jl=Math.PI,Su=2*Jl,rf=Math.PI,nf=2*rf,xn=1e-6,hV=nf-xn;function Cx(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function fV(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Cx;const r=10**t;return function(n){this._+=n[0];for(let i=1,o=n.length;i<o;++i)this._+=Math.round(arguments[i]*r)/r+n[i]}}class gV{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Cx:fV(t)}moveTo(t,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,r){this._append`L${this._x1=+t},${this._y1=+r}`}quadraticCurveTo(t,r,n,i){this._append`Q${+t},${+r},${this._x1=+n},${this._y1=+i}`}bezierCurveTo(t,r,n,i,o,s){this._append`C${+t},${+r},${+n},${+i},${this._x1=+o},${this._y1=+s}`}arcTo(t,r,n,i,o){if(t=+t,r=+r,n=+n,i=+i,o=+o,o<0)throw new Error(`negative radius: ${o}`);let s=this._x1,a=this._y1,l=n-t,c=i-r,u=s-t,d=a-r,h=u*u+d*d;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(h>xn)if(!(Math.abs(d*l-c*u)>xn)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let f=n-s,g=i-a,m=l*l+c*c,p=f*f+g*g,y=Math.sqrt(m),w=Math.sqrt(h),b=o*Math.tan((rf-Math.acos((m+h-p)/(2*y*w)))/2),x=b/w,C=b/y;Math.abs(x-1)>xn&&this._append`L${t+x*u},${r+x*d}`,this._append`A${o},${o},0,0,${+(d*f>u*g)},${this._x1=t+C*l},${this._y1=r+C*c}`}}arc(t,r,n,i,o,s){if(t=+t,r=+r,n=+n,s=!!s,n<0)throw new Error(`negative radius: ${n}`);let a=n*Math.cos(i),l=n*Math.sin(i),c=t+a,u=r+l,d=1^s,h=s?i-o:o-i;this._x1===null?this._append`M${c},${u}`:(Math.abs(this._x1-c)>xn||Math.abs(this._y1-u)>xn)&&this._append`L${c},${u}`,n&&(h<0&&(h=h%nf+nf),h>hV?this._append`A${n},${n},0,1,${d},${t-a},${r-l}A${n},${n},0,1,${d},${this._x1=c},${this._y1=u}`:h>xn&&this._append`A${n},${n},0,${+(h>=rf)},${d},${this._x1=t+n*Math.cos(o)},${this._y1=r+n*Math.sin(o)}`)}rect(t,r,n,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${n=+n}v${+i}h${-n}Z`}toString(){return this._}}function Hp(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const n=Math.floor(r);if(!(n>=0))throw new RangeError(`invalid digits: ${r}`);t=n}return e},()=>new gV(t)}function Gp(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function wx(e){this._context=e}wx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function xu(e){return new wx(e)}function Sx(e){return e[0]}function xx(e){return e[1]}function Ax(e,t){var r=Oe(!0),n=null,i=xu,o=null,s=Hp(a);e=typeof e=="function"?e:e===void 0?Sx:Oe(e),t=typeof t=="function"?t:t===void 0?xx:Oe(t);function a(l){var c,u=(l=Gp(l)).length,d,h=!1,f;for(n==null&&(o=i(f=s())),c=0;c<=u;++c)!(c<u&&r(d=l[c],c,l))===h&&((h=!h)?o.lineStart():o.lineEnd()),h&&o.point(+e(d,c,l),+t(d,c,l));if(f)return o=null,f+""||null}return a.x=function(l){return arguments.length?(e=typeof l=="function"?l:Oe(+l),a):e},a.y=function(l){return arguments.length?(t=typeof l=="function"?l:Oe(+l),a):t},a.defined=function(l){return arguments.length?(r=typeof l=="function"?l:Oe(!!l),a):r},a.curve=function(l){return arguments.length?(i=l,n!=null&&(o=i(n)),a):i},a.context=function(l){return arguments.length?(l==null?n=o=null:o=i(n=l),a):n},a}function Ya(e,t,r){var n=null,i=Oe(!0),o=null,s=xu,a=null,l=Hp(c);e=typeof e=="function"?e:e===void 0?Sx:Oe(+e),t=typeof t=="function"?t:Oe(t===void 0?0:+t),r=typeof r=="function"?r:r===void 0?xx:Oe(+r);function c(d){var h,f,g,m=(d=Gp(d)).length,p,y=!1,w,b=new Array(m),x=new Array(m);for(o==null&&(a=s(w=l())),h=0;h<=m;++h){if(!(h<m&&i(p=d[h],h,d))===y)if(y=!y)f=h,a.areaStart(),a.lineStart();else{for(a.lineEnd(),a.lineStart(),g=h-1;g>=f;--g)a.point(b[g],x[g]);a.lineEnd(),a.areaEnd()}y&&(b[h]=+e(p,h,d),x[h]=+t(p,h,d),a.point(n?+n(p,h,d):b[h],r?+r(p,h,d):x[h]))}if(w)return a=null,w+""||null}function u(){return Ax().defined(i).curve(s).context(o)}return c.x=function(d){return arguments.length?(e=typeof d=="function"?d:Oe(+d),n=null,c):e},c.x0=function(d){return arguments.length?(e=typeof d=="function"?d:Oe(+d),c):e},c.x1=function(d){return arguments.length?(n=d==null?null:typeof d=="function"?d:Oe(+d),c):n},c.y=function(d){return arguments.length?(t=typeof d=="function"?d:Oe(+d),r=null,c):t},c.y0=function(d){return arguments.length?(t=typeof d=="function"?d:Oe(+d),c):t},c.y1=function(d){return arguments.length?(r=d==null?null:typeof d=="function"?d:Oe(+d),c):r},c.lineX0=c.lineY0=function(){return u().x(e).y(t)},c.lineY1=function(){return u().x(e).y(r)},c.lineX1=function(){return u().x(n).y(t)},c.defined=function(d){return arguments.length?(i=typeof d=="function"?d:Oe(!!d),c):i},c.curve=function(d){return arguments.length?(s=d,o!=null&&(a=s(o)),c):s},c.context=function(d){return arguments.length?(d==null?o=a=null:a=s(o=d),c):o},c}class Px{constructor(t,r){this._context=t,this._x=r}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,r){switch(t=+t,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,r):this._context.moveTo(t,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,r,t,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,t,this._y0,t,r);break}}this._x0=t,this._y0=r}}function pV(e){return new Px(e,!0)}function mV(e){return new Px(e,!1)}const Wp={draw(e,t){const r=dr(t/Jl);e.moveTo(r,0),e.arc(0,0,r,0,Su)}},vV={draw(e,t){const r=dr(t/5)/2;e.moveTo(-3*r,-r),e.lineTo(-r,-r),e.lineTo(-r,-3*r),e.lineTo(r,-3*r),e.lineTo(r,-r),e.lineTo(3*r,-r),e.lineTo(3*r,r),e.lineTo(r,r),e.lineTo(r,3*r),e.lineTo(-r,3*r),e.lineTo(-r,r),e.lineTo(-3*r,r),e.closePath()}},Rx=dr(1/3),yV=Rx*2,bV={draw(e,t){const r=dr(t/yV),n=r*Rx;e.moveTo(0,-r),e.lineTo(n,0),e.lineTo(0,r),e.lineTo(-n,0),e.closePath()}},CV={draw(e,t){const r=dr(t),n=-r/2;e.rect(n,n,r,r)}},wV=.8908130915292852,Ex=Yl(Jl/10)/Yl(7*Jl/10),SV=Yl(Su/10)*Ex,xV=-bx(Su/10)*Ex,AV={draw(e,t){const r=dr(t*wV),n=SV*r,i=xV*r;e.moveTo(0,-r),e.lineTo(n,i);for(let o=1;o<5;++o){const s=Su*o/5,a=bx(s),l=Yl(s);e.lineTo(l*r,-a*r),e.lineTo(a*n-l*i,l*n+a*i)}e.closePath()}},Bd=dr(3),PV={draw(e,t){const r=-dr(t/(Bd*3));e.moveTo(0,r*2),e.lineTo(-Bd*r,-r),e.lineTo(Bd*r,-r),e.closePath()}},$t=-.5,Ht=dr(3)/2,of=1/dr(12),RV=(of/2+1)*3,EV={draw(e,t){const r=dr(t/RV),n=r/2,i=r*of,o=n,s=r*of+r,a=-o,l=s;e.moveTo(n,i),e.lineTo(o,s),e.lineTo(a,l),e.lineTo($t*n-Ht*i,Ht*n+$t*i),e.lineTo($t*o-Ht*s,Ht*o+$t*s),e.lineTo($t*a-Ht*l,Ht*a+$t*l),e.lineTo($t*n+Ht*i,$t*i-Ht*n),e.lineTo($t*o+Ht*s,$t*s-Ht*o),e.lineTo($t*a+Ht*l,$t*l-Ht*a),e.closePath()}};function TV(e,t){let r=null,n=Hp(i);e=typeof e=="function"?e:Oe(e||Wp),t=typeof t=="function"?t:Oe(t===void 0?64:+t);function i(){let o;if(r||(r=o=n()),e.apply(this,arguments).draw(r,+t.apply(this,arguments)),o)return r=null,o+""||null}return i.type=function(o){return arguments.length?(e=typeof o=="function"?o:Oe(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:Oe(+o),i):t},i.context=function(o){return arguments.length?(r=o??null,i):r},i}function Xl(){}function Zl(e,t,r){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+r)/6)}function Tx(e){this._context=e}Tx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Zl(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Zl(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function FV(e){return new Tx(e)}function Fx(e){this._context=e}Fx.prototype={areaStart:Xl,areaEnd:Xl,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:Zl(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function OV(e){return new Fx(e)}function Ox(e){this._context=e}Ox.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+e)/6,n=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(r,n):this._context.moveTo(r,n);break;case 3:this._point=4;default:Zl(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function MV(e){return new Ox(e)}function Mx(e){this._context=e}Mx.prototype={areaStart:Xl,areaEnd:Xl,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function DV(e){return new Mx(e)}function jy(e){return e<0?-1:1}function Vy(e,t,r){var n=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(n||i<0&&-0),s=(r-e._y1)/(i||n<0&&-0),a=(o*i+s*n)/(n+i);return(jy(o)+jy(s))*Math.min(Math.abs(o),Math.abs(s),.5*Math.abs(a))||0}function Uy(e,t){var r=e._x1-e._x0;return r?(3*(e._y1-e._y0)/r-t)/2:t}function zd(e,t,r){var n=e._x0,i=e._y0,o=e._x1,s=e._y1,a=(o-n)/3;e._context.bezierCurveTo(n+a,i+a*t,o-a,s-a*r,o,s)}function Ql(e){this._context=e}Ql.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:zd(this,this._t0,Uy(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var r=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,zd(this,Uy(this,r=Vy(this,e,t)),r);break;default:zd(this,this._t0,r=Vy(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}};function Dx(e){this._context=new kx(e)}(Dx.prototype=Object.create(Ql.prototype)).point=function(e,t){Ql.prototype.point.call(this,t,e)};function kx(e){this._context=e}kx.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,r,n,i,o){this._context.bezierCurveTo(t,e,n,r,o,i)}};function kV(e){return new Ql(e)}function IV(e){return new Dx(e)}function Ix(e){this._context=e}Ix.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,r=e.length;if(r)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),r===2)this._context.lineTo(e[1],t[1]);else for(var n=Ky(e),i=Ky(t),o=0,s=1;s<r;++o,++s)this._context.bezierCurveTo(n[0][o],i[0][o],n[1][o],i[1][o],e[s],t[s]);(this._line||this._line!==0&&r===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function Ky(e){var t,r=e.length-1,n,i=new Array(r),o=new Array(r),s=new Array(r);for(i[0]=0,o[0]=2,s[0]=e[0]+2*e[1],t=1;t<r-1;++t)i[t]=1,o[t]=4,s[t]=4*e[t]+2*e[t+1];for(i[r-1]=2,o[r-1]=7,s[r-1]=8*e[r-1]+e[r],t=1;t<r;++t)n=i[t]/o[t-1],o[t]-=n,s[t]-=n*s[t-1];for(i[r-1]=s[r-1]/o[r-1],t=r-2;t>=0;--t)i[t]=(s[t]-i[t+1])/o[t];for(o[r-1]=(e[r]+i[r-1])/2,t=0;t<r-1;++t)o[t]=2*e[t+1]-i[t+1];return[i,o]}function _V(e){return new Ix(e)}function Au(e,t){this._context=e,this._t=t}Au.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var r=this._x*(1-this._t)+e*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,t)}break}}this._x=e,this._y=t}};function LV(e){return new Au(e,.5)}function BV(e){return new Au(e,0)}function zV(e){return new Au(e,1)}function Ni(e,t){if((s=e.length)>1)for(var r=1,n,i,o=e[t[0]],s,a=o.length;r<s;++r)for(i=o,o=e[t[r]],n=0;n<a;++n)o[n][1]+=o[n][0]=isNaN(i[n][1])?i[n][0]:i[n][1]}function sf(e){for(var t=e.length,r=new Array(t);--t>=0;)r[t]=t;return r}function NV(e,t){return e[t]}function $V(e){const t=[];return t.key=e,t}function HV(){var e=Oe([]),t=sf,r=Ni,n=NV;function i(o){var s=Array.from(e.apply(this,arguments),$V),a,l=s.length,c=-1,u;for(const d of o)for(a=0,++c;a<l;++a)(s[a][c]=[0,+n(d,s[a].key,c,o)]).data=d;for(a=0,u=Gp(t(s));a<l;++a)s[u[a]].index=a;return r(s,u),s}return i.keys=function(o){return arguments.length?(e=typeof o=="function"?o:Oe(Array.from(o)),i):e},i.value=function(o){return arguments.length?(n=typeof o=="function"?o:Oe(+o),i):n},i.order=function(o){return arguments.length?(t=o==null?sf:typeof o=="function"?o:Oe(Array.from(o)),i):t},i.offset=function(o){return arguments.length?(r=o??Ni,i):r},i}function GV(e,t){if((n=e.length)>0){for(var r,n,i=0,o=e[0].length,s;i<o;++i){for(s=r=0;r<n;++r)s+=e[r][i][1]||0;if(s)for(r=0;r<n;++r)e[r][i][1]/=s}Ni(e,t)}}function WV(e,t){if((i=e.length)>0){for(var r=0,n=e[t[0]],i,o=n.length;r<o;++r){for(var s=0,a=0;s<i;++s)a+=e[s][r][1]||0;n[r][1]+=n[r][0]=-a/2}Ni(e,t)}}function jV(e,t){if(!(!((s=e.length)>0)||!((o=(i=e[t[0]]).length)>0))){for(var r=0,n=1,i,o,s;n<o;++n){for(var a=0,l=0,c=0;a<s;++a){for(var u=e[t[a]],d=u[n][1]||0,h=u[n-1][1]||0,f=(d-h)/2,g=0;g<a;++g){var m=e[t[g]],p=m[n][1]||0,y=m[n-1][1]||0;f+=p-y}l+=d,c+=f*d}i[n-1][1]+=i[n-1][0]=r,l&&(r-=c/l)}i[n-1][1]+=i[n-1][0]=r,Ni(e,t)}}function _s(e){"@babel/helpers - typeof";return _s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_s(e)}var VV=["type","size","sizeType"];function af(){return af=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},af.apply(this,arguments)}function qy(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Yy(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?qy(Object(r),!0).forEach(function(n){UV(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):qy(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function UV(e,t,r){return t=KV(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function KV(e){var t=qV(e,"string");return _s(t)=="symbol"?t:t+""}function qV(e,t){if(_s(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(_s(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function YV(e,t){if(e==null)return{};var r=JV(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function JV(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var _x={symbolCircle:Wp,symbolCross:vV,symbolDiamond:bV,symbolSquare:CV,symbolStar:AV,symbolTriangle:PV,symbolWye:EV},XV=Math.PI/180,ZV=function(t){var r="symbol".concat(wu(t));return _x[r]||Wp},QV=function(t,r,n){if(r==="area")return t;switch(n){case"cross":return 5*t*t/9;case"diamond":return .5*t*t/Math.sqrt(3);case"square":return t*t;case"star":{var i=18*XV;return 1.25*t*t*(Math.tan(i)-Math.tan(i*2)*Math.pow(Math.tan(i),2))}case"triangle":return Math.sqrt(3)*t*t/4;case"wye":return(21-10*Math.sqrt(3))*t*t/8;default:return Math.PI*t*t/4}},e7=function(t,r){_x["symbol".concat(wu(t))]=r},Pu=function(t){var r=t.type,n=r===void 0?"circle":r,i=t.size,o=i===void 0?64:i,s=t.sizeType,a=s===void 0?"area":s,l=YV(t,VV),c=Yy(Yy({},l),{},{type:n,size:o,sizeType:a}),u=function(){var p=ZV(n),y=TV().type(p).size(QV(o,a,n));return y()},d=c.className,h=c.cx,f=c.cy,g=de(c,!0);return h===+h&&f===+f&&o===+o?v.createElement("path",af({},g,{className:ve("recharts-symbols",d),transform:"translate(".concat(h,", ").concat(f,")"),d:u()})):null};Pu.registerSymbol=e7;function $i(e){"@babel/helpers - typeof";return $i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$i(e)}function lf(){return lf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},lf.apply(this,arguments)}function Jy(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function t7(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Jy(Object(r),!0).forEach(function(n){Ls(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Jy(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function r7(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n7(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,Bx(n.key),n)}}function i7(e,t,r){return t&&n7(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function o7(e,t,r){return t=ec(t),s7(e,Lx()?Reflect.construct(t,r||[],ec(e).constructor):t.apply(e,r))}function s7(e,t){if(t&&($i(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return a7(e)}function a7(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Lx(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Lx=function(){return!!e})()}function ec(e){return ec=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},ec(e)}function l7(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&cf(e,t)}function cf(e,t){return cf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},cf(e,t)}function Ls(e,t,r){return t=Bx(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Bx(e){var t=c7(e,"string");return $i(t)=="symbol"?t:t+""}function c7(e,t){if($i(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if($i(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Gt=32,jp=function(e){function t(){return r7(this,t),o7(this,t,arguments)}return l7(t,e),i7(t,[{key:"renderIcon",value:function(n){var i=this.props.inactiveColor,o=Gt/2,s=Gt/6,a=Gt/3,l=n.inactive?i:n.color;if(n.type==="plainline")return v.createElement("line",{strokeWidth:4,fill:"none",stroke:l,strokeDasharray:n.payload.strokeDasharray,x1:0,y1:o,x2:Gt,y2:o,className:"recharts-legend-icon"});if(n.type==="line")return v.createElement("path",{strokeWidth:4,fill:"none",stroke:l,d:"M0,".concat(o,"h").concat(a,`
40
+ A`).concat(s,",").concat(s,",0,1,1,").concat(2*a,",").concat(o,`
41
+ H`).concat(Gt,"M").concat(2*a,",").concat(o,`
42
+ A`).concat(s,",").concat(s,",0,1,1,").concat(a,",").concat(o),className:"recharts-legend-icon"});if(n.type==="rect")return v.createElement("path",{stroke:"none",fill:l,d:"M0,".concat(Gt/8,"h").concat(Gt,"v").concat(Gt*3/4,"h").concat(-Gt,"z"),className:"recharts-legend-icon"});if(v.isValidElement(n.legendIcon)){var c=t7({},n);return delete c.legendIcon,v.cloneElement(n.legendIcon,c)}return v.createElement(Pu,{fill:l,cx:o,cy:o,size:Gt,sizeType:"diameter",type:n.type})}},{key:"renderItems",value:function(){var n=this,i=this.props,o=i.payload,s=i.iconSize,a=i.layout,l=i.formatter,c=i.inactiveColor,u={x:0,y:0,width:Gt,height:Gt},d={display:a==="horizontal"?"inline-block":"block",marginRight:10},h={display:"inline-block",verticalAlign:"middle",marginRight:4};return o.map(function(f,g){var m=f.formatter||l,p=ve(Ls(Ls({"recharts-legend-item":!0},"legend-item-".concat(g),!0),"inactive",f.inactive));if(f.type==="none")return null;var y=ge(f.value)?null:f.value;Cu(!ge(f.value),`The name property is also required when using a function for the dataKey of a chart's cartesian components. Ex: <Bar name="Name of my Data"/>`);var w=f.inactive?c:f.color;return v.createElement("li",lf({className:p,style:d,key:"legend-item-".concat(g)},Is(n.props,f,g)),v.createElement(Zh,{width:s,height:s,viewBox:u,style:h},n.renderIcon(f)),v.createElement("span",{className:"recharts-legend-item-text",style:{color:w}},m?m(y,f,g):y))})}},{key:"render",value:function(){var n=this.props,i=n.payload,o=n.layout,s=n.align;if(!i||!i.length)return null;var a={padding:0,margin:0,textAlign:o==="horizontal"?s:"left"};return v.createElement("ul",{className:"recharts-default-legend",style:a},this.renderItems())}}])}(v.PureComponent);Ls(jp,"displayName","Legend");Ls(jp,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var u7=vu;function d7(){this.__data__=new u7,this.size=0}var h7=d7;function f7(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var g7=f7;function p7(e){return this.__data__.get(e)}var m7=p7;function v7(e){return this.__data__.has(e)}var y7=v7,b7=vu,C7=Ip,w7=_p,S7=200;function x7(e,t){var r=this.__data__;if(r instanceof b7){var n=r.__data__;if(!C7||n.length<S7-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new w7(n)}return r.set(e,t),this.size=r.size,this}var A7=x7,P7=vu,R7=h7,E7=g7,T7=m7,F7=y7,O7=A7;function To(e){var t=this.__data__=new P7(e);this.size=t.size}To.prototype.clear=R7;To.prototype.delete=E7;To.prototype.get=T7;To.prototype.has=F7;To.prototype.set=O7;var zx=To,M7="__lodash_hash_undefined__";function D7(e){return this.__data__.set(e,M7),this}var k7=D7;function I7(e){return this.__data__.has(e)}var _7=I7,L7=_p,B7=k7,z7=_7;function tc(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new L7;++t<r;)this.add(e[t])}tc.prototype.add=tc.prototype.push=B7;tc.prototype.has=z7;var Nx=tc;function N7(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}var $x=N7;function $7(e,t){return e.has(t)}var Hx=$7,H7=Nx,G7=$x,W7=Hx,j7=1,V7=2;function U7(e,t,r,n,i,o){var s=r&j7,a=e.length,l=t.length;if(a!=l&&!(s&&l>a))return!1;var c=o.get(e),u=o.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,f=r&V7?new H7:void 0;for(o.set(e,t),o.set(t,e);++d<a;){var g=e[d],m=t[d];if(n)var p=s?n(m,g,d,t,e,o):n(g,m,d,e,t,o);if(p!==void 0){if(p)continue;h=!1;break}if(f){if(!G7(t,function(y,w){if(!W7(f,w)&&(g===y||i(g,y,r,n,o)))return f.push(w)})){h=!1;break}}else if(!(g===m||i(g,m,r,n,o))){h=!1;break}}return o.delete(e),o.delete(t),h}var Gx=U7,K7=Tr,q7=K7.Uint8Array,Y7=q7;function J7(e){var t=-1,r=Array(e.size);return e.forEach(function(n,i){r[++t]=[i,n]}),r}var X7=J7;function Z7(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var Vp=Z7,Xy=Fa,Zy=Y7,Q7=kp,e9=Gx,t9=X7,r9=Vp,n9=1,i9=2,o9="[object Boolean]",s9="[object Date]",a9="[object Error]",l9="[object Map]",c9="[object Number]",u9="[object RegExp]",d9="[object Set]",h9="[object String]",f9="[object Symbol]",g9="[object ArrayBuffer]",p9="[object DataView]",Qy=Xy?Xy.prototype:void 0,Nd=Qy?Qy.valueOf:void 0;function m9(e,t,r,n,i,o,s){switch(r){case p9:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case g9:return!(e.byteLength!=t.byteLength||!o(new Zy(e),new Zy(t)));case o9:case s9:case c9:return Q7(+e,+t);case a9:return e.name==t.name&&e.message==t.message;case u9:case h9:return e==t+"";case l9:var a=t9;case d9:var l=n&n9;if(a||(a=r9),e.size!=t.size&&!l)return!1;var c=s.get(e);if(c)return c==t;n|=i9,s.set(e,t);var u=e9(a(e),a(t),n,i,o,s);return s.delete(e),u;case f9:if(Nd)return Nd.call(e)==Nd.call(t)}return!1}var v9=m9;function y9(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}var Wx=y9,b9=Wx,C9=Mt;function w9(e,t,r){var n=t(e);return C9(e)?n:b9(n,r(e))}var S9=w9;function x9(e,t){for(var r=-1,n=e==null?0:e.length,i=0,o=[];++r<n;){var s=e[r];t(s,r,e)&&(o[i++]=s)}return o}var A9=x9;function P9(){return[]}var R9=P9,E9=A9,T9=R9,F9=Object.prototype,O9=F9.propertyIsEnumerable,e0=Object.getOwnPropertySymbols,M9=e0?function(e){return e==null?[]:(e=Object(e),E9(e0(e),function(t){return O9.call(e,t)}))}:T9,D9=M9;function k9(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var I9=k9,_9=Kr,L9=qr,B9="[object Arguments]";function z9(e){return L9(e)&&_9(e)==B9}var N9=z9,t0=N9,$9=qr,jx=Object.prototype,H9=jx.hasOwnProperty,G9=jx.propertyIsEnumerable,W9=t0(function(){return arguments}())?t0:function(e){return $9(e)&&H9.call(e,"callee")&&!G9.call(e,"callee")},Up=W9,rc={exports:{}};function j9(){return!1}var V9=j9;rc.exports;(function(e,t){var r=Tr,n=V9,i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,s=o&&o.exports===i,a=s?r.Buffer:void 0,l=a?a.isBuffer:void 0,c=l||n;e.exports=c})(rc,rc.exports);var Vx=rc.exports,U9=9007199254740991,K9=/^(?:0|[1-9]\d*)$/;function q9(e,t){var r=typeof e;return t=t??U9,!!t&&(r=="number"||r!="symbol"&&K9.test(e))&&e>-1&&e%1==0&&e<t}var Kp=q9,Y9=9007199254740991;function J9(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Y9}var qp=J9,X9=Kr,Z9=qp,Q9=qr,eU="[object Arguments]",tU="[object Array]",rU="[object Boolean]",nU="[object Date]",iU="[object Error]",oU="[object Function]",sU="[object Map]",aU="[object Number]",lU="[object Object]",cU="[object RegExp]",uU="[object Set]",dU="[object String]",hU="[object WeakMap]",fU="[object ArrayBuffer]",gU="[object DataView]",pU="[object Float32Array]",mU="[object Float64Array]",vU="[object Int8Array]",yU="[object Int16Array]",bU="[object Int32Array]",CU="[object Uint8Array]",wU="[object Uint8ClampedArray]",SU="[object Uint16Array]",xU="[object Uint32Array]",De={};De[pU]=De[mU]=De[vU]=De[yU]=De[bU]=De[CU]=De[wU]=De[SU]=De[xU]=!0;De[eU]=De[tU]=De[fU]=De[rU]=De[gU]=De[nU]=De[iU]=De[oU]=De[sU]=De[aU]=De[lU]=De[cU]=De[uU]=De[dU]=De[hU]=!1;function AU(e){return Q9(e)&&Z9(e.length)&&!!De[X9(e)]}var PU=AU;function RU(e){return function(t){return e(t)}}var Ux=RU,nc={exports:{}};nc.exports;(function(e,t){var r=tx,n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===n,s=o&&r.process,a=function(){try{var l=i&&i.require&&i.require("util").types;return l||s&&s.binding&&s.binding("util")}catch{}}();e.exports=a})(nc,nc.exports);var EU=nc.exports,TU=PU,FU=Ux,r0=EU,n0=r0&&r0.isTypedArray,OU=n0?FU(n0):TU,Kx=OU,MU=I9,DU=Up,kU=Mt,IU=Vx,_U=Kp,LU=Kx,BU=Object.prototype,zU=BU.hasOwnProperty;function NU(e,t){var r=kU(e),n=!r&&DU(e),i=!r&&!n&&IU(e),o=!r&&!n&&!i&&LU(e),s=r||n||i||o,a=s?MU(e.length,String):[],l=a.length;for(var c in e)(t||zU.call(e,c))&&!(s&&(c=="length"||i&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||_U(c,l)))&&a.push(c);return a}var $U=NU,HU=Object.prototype;function GU(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||HU;return e===r}var WU=GU;function jU(e,t){return function(r){return e(t(r))}}var qx=jU,VU=qx,UU=VU(Object.keys,Object),KU=UU,qU=WU,YU=KU,JU=Object.prototype,XU=JU.hasOwnProperty;function ZU(e){if(!qU(e))return YU(e);var t=[];for(var r in Object(e))XU.call(e,r)&&r!="constructor"&&t.push(r);return t}var QU=ZU,eK=Dp,tK=qp;function rK(e){return e!=null&&tK(e.length)&&!eK(e)}var Ru=rK,nK=$U,iK=QU,oK=Ru;function sK(e){return oK(e)?nK(e):iK(e)}var Yp=sK,aK=S9,lK=D9,cK=Yp;function uK(e){return aK(e,cK,lK)}var dK=uK,i0=dK,hK=1,fK=Object.prototype,gK=fK.hasOwnProperty;function pK(e,t,r,n,i,o){var s=r&hK,a=i0(e),l=a.length,c=i0(t),u=c.length;if(l!=u&&!s)return!1;for(var d=l;d--;){var h=a[d];if(!(s?h in t:gK.call(t,h)))return!1}var f=o.get(e),g=o.get(t);if(f&&g)return f==t&&g==e;var m=!0;o.set(e,t),o.set(t,e);for(var p=s;++d<l;){h=a[d];var y=e[h],w=t[h];if(n)var b=s?n(w,y,h,t,e,o):n(y,w,h,e,t,o);if(!(b===void 0?y===w||i(y,w,r,n,o):b)){m=!1;break}p||(p=h=="constructor")}if(m&&!p){var x=e.constructor,C=t.constructor;x!=C&&"constructor"in e&&"constructor"in t&&!(typeof x=="function"&&x instanceof x&&typeof C=="function"&&C instanceof C)&&(m=!1)}return o.delete(e),o.delete(t),m}var mK=pK,vK=ii,yK=Tr,bK=vK(yK,"DataView"),CK=bK,wK=ii,SK=Tr,xK=wK(SK,"Promise"),AK=xK,PK=ii,RK=Tr,EK=PK(RK,"Set"),Yx=EK,TK=ii,FK=Tr,OK=TK(FK,"WeakMap"),MK=OK,uf=CK,df=Ip,hf=AK,ff=Yx,gf=MK,Jx=Kr,Fo=nx,o0="[object Map]",DK="[object Object]",s0="[object Promise]",a0="[object Set]",l0="[object WeakMap]",c0="[object DataView]",kK=Fo(uf),IK=Fo(df),_K=Fo(hf),LK=Fo(ff),BK=Fo(gf),An=Jx;(uf&&An(new uf(new ArrayBuffer(1)))!=c0||df&&An(new df)!=o0||hf&&An(hf.resolve())!=s0||ff&&An(new ff)!=a0||gf&&An(new gf)!=l0)&&(An=function(e){var t=Jx(e),r=t==DK?e.constructor:void 0,n=r?Fo(r):"";if(n)switch(n){case kK:return c0;case IK:return o0;case _K:return s0;case LK:return a0;case BK:return l0}return t});var zK=An,$d=zx,NK=Gx,$K=v9,HK=mK,u0=zK,d0=Mt,h0=Vx,GK=Kx,WK=1,f0="[object Arguments]",g0="[object Array]",Ja="[object Object]",jK=Object.prototype,p0=jK.hasOwnProperty;function VK(e,t,r,n,i,o){var s=d0(e),a=d0(t),l=s?g0:u0(e),c=a?g0:u0(t);l=l==f0?Ja:l,c=c==f0?Ja:c;var u=l==Ja,d=c==Ja,h=l==c;if(h&&h0(e)){if(!h0(t))return!1;s=!0,u=!1}if(h&&!u)return o||(o=new $d),s||GK(e)?NK(e,t,r,n,i,o):$K(e,t,l,r,n,i,o);if(!(r&WK)){var f=u&&p0.call(e,"__wrapped__"),g=d&&p0.call(t,"__wrapped__");if(f||g){var m=f?e.value():e,p=g?t.value():t;return o||(o=new $d),i(m,p,r,n,o)}}return h?(o||(o=new $d),HK(e,t,r,n,i,o)):!1}var UK=VK,KK=UK,m0=qr;function Xx(e,t,r,n,i){return e===t?!0:e==null||t==null||!m0(e)&&!m0(t)?e!==e&&t!==t:KK(e,t,r,n,Xx,i)}var Jp=Xx,qK=zx,YK=Jp,JK=1,XK=2;function ZK(e,t,r,n){var i=r.length,o=i,s=!n;if(e==null)return!o;for(e=Object(e);i--;){var a=r[i];if(s&&a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++i<o;){a=r[i];var l=a[0],c=e[l],u=a[1];if(s&&a[2]){if(c===void 0&&!(l in e))return!1}else{var d=new qK;if(n)var h=n(c,u,l,e,t,d);if(!(h===void 0?YK(u,c,JK|XK,n,d):h))return!1}}return!0}var QK=ZK,eq=gn;function tq(e){return e===e&&!eq(e)}var Zx=tq,rq=Zx,nq=Yp;function iq(e){for(var t=nq(e),r=t.length;r--;){var n=t[r],i=e[n];t[r]=[n,i,rq(i)]}return t}var oq=iq;function sq(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}var Qx=sq,aq=QK,lq=oq,cq=Qx;function uq(e){var t=lq(e);return t.length==1&&t[0][2]?cq(t[0][0],t[0][1]):function(r){return r===e||aq(r,e,t)}}var dq=uq;function hq(e,t){return e!=null&&t in Object(e)}var fq=hq,gq=lx,pq=Up,mq=Mt,vq=Kp,yq=qp,bq=bu;function Cq(e,t,r){t=gq(t,e);for(var n=-1,i=t.length,o=!1;++n<i;){var s=bq(t[n]);if(!(o=e!=null&&r(e,s)))break;e=e[s]}return o||++n!=i?o:(i=e==null?0:e.length,!!i&&yq(i)&&vq(s,i)&&(mq(e)||pq(e)))}var wq=Cq,Sq=fq,xq=wq;function Aq(e,t){return e!=null&&xq(e,t,Sq)}var Pq=Aq,Rq=Jp,Eq=cx,Tq=Pq,Fq=Mp,Oq=Zx,Mq=Qx,Dq=bu,kq=1,Iq=2;function _q(e,t){return Fq(e)&&Oq(t)?Mq(Dq(e),t):function(r){var n=Eq(r,e);return n===void 0&&n===t?Tq(r,e):Rq(t,n,kq|Iq)}}var Lq=_q;function Bq(e){return e}var Oo=Bq;function zq(e){return function(t){return t==null?void 0:t[e]}}var Nq=zq,$q=zp;function Hq(e){return function(t){return $q(t,e)}}var Gq=Hq,Wq=Nq,jq=Gq,Vq=Mp,Uq=bu;function Kq(e){return Vq(e)?Wq(Uq(e)):jq(e)}var qq=Kq,Yq=dq,Jq=Lq,Xq=Oo,Zq=Mt,Qq=qq;function eY(e){return typeof e=="function"?e:e==null?Xq:typeof e=="object"?Zq(e)?Jq(e[0],e[1]):Yq(e):Qq(e)}var Mo=eY;function tY(e,t,r,n){for(var i=e.length,o=r+(n?1:-1);n?o--:++o<i;)if(t(e[o],o,e))return o;return-1}var rY=tY;function nY(e){return e!==e}var iY=nY;function oY(e,t,r){for(var n=r-1,i=e.length;++n<i;)if(e[n]===t)return n;return-1}var sY=oY,aY=rY,lY=iY,cY=sY;function uY(e,t,r){return t===t?cY(e,t,r):aY(e,lY,r)}var dY=uY,hY=dY;function fY(e,t){var r=e==null?0:e.length;return!!r&&hY(e,t,0)>-1}var gY=fY;function pY(e,t,r){for(var n=-1,i=e==null?0:e.length;++n<i;)if(r(t,e[n]))return!0;return!1}var mY=pY;function vY(){}var yY=vY,Hd=Yx,bY=yY,CY=Vp,wY=1/0,SY=Hd&&1/CY(new Hd([,-0]))[1]==wY?function(e){return new Hd(e)}:bY,xY=SY,AY=Nx,PY=gY,RY=mY,EY=Hx,TY=xY,FY=Vp,OY=200;function MY(e,t,r){var n=-1,i=PY,o=e.length,s=!0,a=[],l=a;if(r)s=!1,i=RY;else if(o>=OY){var c=t?null:TY(e);if(c)return FY(c);s=!1,i=EY,l=new AY}else l=t?[]:a;e:for(;++n<o;){var u=e[n],d=t?t(u):u;if(u=r||u!==0?u:0,s&&d===d){for(var h=l.length;h--;)if(l[h]===d)continue e;t&&l.push(d),a.push(u)}else i(l,d,r)||(l!==a&&l.push(d),a.push(u))}return a}var DY=MY,kY=Mo,IY=DY;function _Y(e,t){return e&&e.length?IY(e,kY(t)):[]}var LY=_Y;const v0=Le(LY);function eA(e,t,r){return t===!0?v0(e,r):ge(t)?v0(e,t):e}function Hi(e){"@babel/helpers - typeof";return Hi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Hi(e)}var BY=["ref"];function y0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Or(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?y0(Object(r),!0).forEach(function(n){Eu(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):y0(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function zY(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function b0(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,rA(n.key),n)}}function NY(e,t,r){return t&&b0(e.prototype,t),r&&b0(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function $Y(e,t,r){return t=ic(t),HY(e,tA()?Reflect.construct(t,r||[],ic(e).constructor):t.apply(e,r))}function HY(e,t){if(t&&(Hi(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return GY(e)}function GY(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function tA(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(tA=function(){return!!e})()}function ic(e){return ic=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},ic(e)}function WY(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&pf(e,t)}function pf(e,t){return pf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},pf(e,t)}function Eu(e,t,r){return t=rA(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function rA(e){var t=jY(e,"string");return Hi(t)=="symbol"?t:t+""}function jY(e,t){if(Hi(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Hi(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function VY(e,t){if(e==null)return{};var r=UY(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function UY(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function KY(e){return e.value}function qY(e,t){if(v.isValidElement(e))return v.cloneElement(e,t);if(typeof e=="function")return v.createElement(e,t);t.ref;var r=VY(t,BY);return v.createElement(jp,r)}var C0=1,Oi=function(e){function t(){var r;zY(this,t);for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];return r=$Y(this,t,[].concat(i)),Eu(r,"lastBoundingBox",{width:-1,height:-1}),r}return WY(t,e),NY(t,[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"getBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var n=this.wrapperNode.getBoundingClientRect();return n.height=this.wrapperNode.offsetHeight,n.width=this.wrapperNode.offsetWidth,n}return null}},{key:"updateBBox",value:function(){var n=this.props.onBBoxUpdate,i=this.getBBox();i?(Math.abs(i.width-this.lastBoundingBox.width)>C0||Math.abs(i.height-this.lastBoundingBox.height)>C0)&&(this.lastBoundingBox.width=i.width,this.lastBoundingBox.height=i.height,n&&n(i)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,n&&n(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?Or({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(n){var i=this.props,o=i.layout,s=i.align,a=i.verticalAlign,l=i.margin,c=i.chartWidth,u=i.chartHeight,d,h;if(!n||(n.left===void 0||n.left===null)&&(n.right===void 0||n.right===null))if(s==="center"&&o==="vertical"){var f=this.getBBoxSnapshot();d={left:((c||0)-f.width)/2}}else d=s==="right"?{right:l&&l.right||0}:{left:l&&l.left||0};if(!n||(n.top===void 0||n.top===null)&&(n.bottom===void 0||n.bottom===null))if(a==="middle"){var g=this.getBBoxSnapshot();h={top:((u||0)-g.height)/2}}else h=a==="bottom"?{bottom:l&&l.bottom||0}:{top:l&&l.top||0};return Or(Or({},d),h)}},{key:"render",value:function(){var n=this,i=this.props,o=i.content,s=i.width,a=i.height,l=i.wrapperStyle,c=i.payloadUniqBy,u=i.payload,d=Or(Or({position:"absolute",width:s||"auto",height:a||"auto"},this.getDefaultPosition(l)),l);return v.createElement("div",{className:"recharts-legend-wrapper",style:d,ref:function(f){n.wrapperNode=f}},qY(o,Or(Or({},this.props),{},{payload:eA(u,c,KY)})))}}],[{key:"getWithHeight",value:function(n,i){var o=Or(Or({},this.defaultProps),n.props),s=o.layout;return s==="vertical"&&Z(n.props.height)?{height:n.props.height}:s==="horizontal"?{width:n.props.width||i}:null}}])}(v.PureComponent);Eu(Oi,"displayName","Legend");Eu(Oi,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var w0=Fa,YY=Up,JY=Mt,S0=w0?w0.isConcatSpreadable:void 0;function XY(e){return JY(e)||YY(e)||!!(S0&&e&&e[S0])}var ZY=XY,QY=Wx,eJ=ZY;function nA(e,t,r,n,i){var o=-1,s=e.length;for(r||(r=eJ),i||(i=[]);++o<s;){var a=e[o];t>0&&r(a)?t>1?nA(a,t-1,r,n,i):QY(i,a):n||(i[i.length]=a)}return i}var iA=nA;function tJ(e){return function(t,r,n){for(var i=-1,o=Object(t),s=n(t),a=s.length;a--;){var l=s[e?a:++i];if(r(o[l],l,o)===!1)break}return t}}var rJ=tJ,nJ=rJ,iJ=nJ(),oJ=iJ,sJ=oJ,aJ=Yp;function lJ(e,t){return e&&sJ(e,t,aJ)}var oA=lJ,cJ=Ru;function uJ(e,t){return function(r,n){if(r==null)return r;if(!cJ(r))return e(r,n);for(var i=r.length,o=t?i:-1,s=Object(r);(t?o--:++o<i)&&n(s[o],o,s)!==!1;);return r}}var dJ=uJ,hJ=oA,fJ=dJ,gJ=fJ(hJ),Xp=gJ,pJ=Xp,mJ=Ru;function vJ(e,t){var r=-1,n=mJ(e)?Array(e.length):[];return pJ(e,function(i,o,s){n[++r]=t(i,o,s)}),n}var sA=vJ;function yJ(e,t){var r=e.length;for(e.sort(t);r--;)e[r]=e[r].value;return e}var bJ=yJ,x0=So;function CJ(e,t){if(e!==t){var r=e!==void 0,n=e===null,i=e===e,o=x0(e),s=t!==void 0,a=t===null,l=t===t,c=x0(t);if(!a&&!c&&!o&&e>t||o&&s&&l&&!a&&!c||n&&s&&l||!r&&l||!i)return 1;if(!n&&!o&&!c&&e<t||c&&r&&i&&!n&&!o||a&&r&&i||!s&&i||!l)return-1}return 0}var wJ=CJ,SJ=wJ;function xJ(e,t,r){for(var n=-1,i=e.criteria,o=t.criteria,s=i.length,a=r.length;++n<s;){var l=SJ(i[n],o[n]);if(l){if(n>=a)return l;var c=r[n];return l*(c=="desc"?-1:1)}}return e.index-t.index}var AJ=xJ,Gd=Bp,PJ=zp,RJ=Mo,EJ=sA,TJ=bJ,FJ=Ux,OJ=AJ,MJ=Oo,DJ=Mt;function kJ(e,t,r){t.length?t=Gd(t,function(o){return DJ(o)?function(s){return PJ(s,o.length===1?o[0]:o)}:o}):t=[MJ];var n=-1;t=Gd(t,FJ(RJ));var i=EJ(e,function(o,s,a){var l=Gd(t,function(c){return c(o)});return{criteria:l,index:++n,value:o}});return TJ(i,function(o,s){return OJ(o,s,r)})}var IJ=kJ;function _J(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var LJ=_J,BJ=LJ,A0=Math.max;function zJ(e,t,r){return t=A0(t===void 0?e.length-1:t,0),function(){for(var n=arguments,i=-1,o=A0(n.length-t,0),s=Array(o);++i<o;)s[i]=n[t+i];i=-1;for(var a=Array(t+1);++i<t;)a[i]=n[i];return a[t]=r(s),BJ(e,this,a)}}var NJ=zJ;function $J(e){return function(){return e}}var HJ=$J,GJ=ii,WJ=function(){try{var e=GJ(Object,"defineProperty");return e({},"",{}),e}catch{}}(),aA=WJ,jJ=HJ,P0=aA,VJ=Oo,UJ=P0?function(e,t){return P0(e,"toString",{configurable:!0,enumerable:!1,value:jJ(t),writable:!0})}:VJ,KJ=UJ,qJ=800,YJ=16,JJ=Date.now;function XJ(e){var t=0,r=0;return function(){var n=JJ(),i=YJ-(n-r);if(r=n,i>0){if(++t>=qJ)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var ZJ=XJ,QJ=KJ,eX=ZJ,tX=eX(QJ),rX=tX,nX=Oo,iX=NJ,oX=rX;function sX(e,t){return oX(iX(e,t,nX),e+"")}var aX=sX,lX=kp,cX=Ru,uX=Kp,dX=gn;function hX(e,t,r){if(!dX(r))return!1;var n=typeof t;return(n=="number"?cX(r)&&uX(t,r.length):n=="string"&&t in r)?lX(r[t],e):!1}var Tu=hX,fX=iA,gX=IJ,pX=aX,R0=Tu,mX=pX(function(e,t){if(e==null)return[];var r=t.length;return r>1&&R0(e,t[0],t[1])?t=[]:r>2&&R0(t[0],t[1],t[2])&&(t=[t[0]]),gX(e,fX(t,1),[])}),vX=mX;const Zp=Le(vX);function Bs(e){"@babel/helpers - typeof";return Bs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Bs(e)}function mf(){return mf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},mf.apply(this,arguments)}function yX(e,t){return SX(e)||wX(e,t)||CX(e,t)||bX()}function bX(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
43
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function CX(e,t){if(e){if(typeof e=="string")return E0(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return E0(e,t)}}function E0(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function wX(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function SX(e){if(Array.isArray(e))return e}function T0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Wd(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?T0(Object(r),!0).forEach(function(n){xX(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):T0(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function xX(e,t,r){return t=AX(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function AX(e){var t=PX(e,"string");return Bs(t)=="symbol"?t:t+""}function PX(e,t){if(Bs(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Bs(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function RX(e){return Array.isArray(e)&&et(e[0])&&et(e[1])?e.join(" ~ "):e}var EX=function(t){var r=t.separator,n=r===void 0?" : ":r,i=t.contentStyle,o=i===void 0?{}:i,s=t.itemStyle,a=s===void 0?{}:s,l=t.labelStyle,c=l===void 0?{}:l,u=t.payload,d=t.formatter,h=t.itemSorter,f=t.wrapperClassName,g=t.labelClassName,m=t.label,p=t.labelFormatter,y=t.accessibilityLayer,w=y===void 0?!1:y,b=function(){if(u&&u.length){var T={padding:0,margin:0},F=(h?Zp(u,h):u).map(function(I,k){if(I.type==="none")return null;var B=Wd({display:"block",paddingTop:4,paddingBottom:4,color:I.color||"#000"},a),N=I.formatter||d||RX,z=I.value,W=I.name,D=z,L=W;if(N&&D!=null&&L!=null){var $=N(z,W,I,k,u);if(Array.isArray($)){var H=yX($,2);D=H[0],L=H[1]}else D=$}return v.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(k),style:B},et(L)?v.createElement("span",{className:"recharts-tooltip-item-name"},L):null,et(L)?v.createElement("span",{className:"recharts-tooltip-item-separator"},n):null,v.createElement("span",{className:"recharts-tooltip-item-value"},D),v.createElement("span",{className:"recharts-tooltip-item-unit"},I.unit||""))});return v.createElement("ul",{className:"recharts-tooltip-item-list",style:T},F)}return null},x=Wd({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},o),C=Wd({margin:0},c),S=!ue(m),A=S?m:"",P=ve("recharts-default-tooltip",f),E=ve("recharts-tooltip-label",g);S&&p&&u!==void 0&&u!==null&&(A=p(m,u));var O=w?{role:"status","aria-live":"assertive"}:{};return v.createElement("div",mf({className:P,style:x},O),v.createElement("p",{className:E,style:C},v.isValidElement(A)?A:"".concat(A)),b())};function zs(e){"@babel/helpers - typeof";return zs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},zs(e)}function Xa(e,t,r){return t=TX(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function TX(e){var t=FX(e,"string");return zs(t)=="symbol"?t:t+""}function FX(e,t){if(zs(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(zs(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Wo="recharts-tooltip-wrapper",OX={visibility:"hidden"};function MX(e){var t=e.coordinate,r=e.translateX,n=e.translateY;return ve(Wo,Xa(Xa(Xa(Xa({},"".concat(Wo,"-right"),Z(r)&&t&&Z(t.x)&&r>=t.x),"".concat(Wo,"-left"),Z(r)&&t&&Z(t.x)&&r<t.x),"".concat(Wo,"-bottom"),Z(n)&&t&&Z(t.y)&&n>=t.y),"".concat(Wo,"-top"),Z(n)&&t&&Z(t.y)&&n<t.y))}function F0(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.key,i=e.offsetTopLeft,o=e.position,s=e.reverseDirection,a=e.tooltipDimension,l=e.viewBox,c=e.viewBoxDimension;if(o&&Z(o[n]))return o[n];var u=r[n]-a-i,d=r[n]+i;if(t[n])return s[n]?u:d;if(s[n]){var h=u,f=l[n];return h<f?Math.max(d,l[n]):Math.max(u,l[n])}var g=d+a,m=l[n]+c;return g>m?Math.max(u,l[n]):Math.max(d,l[n])}function DX(e){var t=e.translateX,r=e.translateY,n=e.useTranslate3d;return{transform:n?"translate3d(".concat(t,"px, ").concat(r,"px, 0)"):"translate(".concat(t,"px, ").concat(r,"px)")}}function kX(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.offsetTopLeft,i=e.position,o=e.reverseDirection,s=e.tooltipBox,a=e.useTranslate3d,l=e.viewBox,c,u,d;return s.height>0&&s.width>0&&r?(u=F0({allowEscapeViewBox:t,coordinate:r,key:"x",offsetTopLeft:n,position:i,reverseDirection:o,tooltipDimension:s.width,viewBox:l,viewBoxDimension:l.width}),d=F0({allowEscapeViewBox:t,coordinate:r,key:"y",offsetTopLeft:n,position:i,reverseDirection:o,tooltipDimension:s.height,viewBox:l,viewBoxDimension:l.height}),c=DX({translateX:u,translateY:d,useTranslate3d:a})):c=OX,{cssProperties:c,cssClasses:MX({translateX:u,translateY:d,coordinate:r})}}function Gi(e){"@babel/helpers - typeof";return Gi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Gi(e)}function O0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function M0(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?O0(Object(r),!0).forEach(function(n){yf(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):O0(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function IX(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _X(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,cA(n.key),n)}}function LX(e,t,r){return t&&_X(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function BX(e,t,r){return t=oc(t),zX(e,lA()?Reflect.construct(t,r||[],oc(e).constructor):t.apply(e,r))}function zX(e,t){if(t&&(Gi(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return NX(e)}function NX(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function lA(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(lA=function(){return!!e})()}function oc(e){return oc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},oc(e)}function $X(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&vf(e,t)}function vf(e,t){return vf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},vf(e,t)}function yf(e,t,r){return t=cA(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function cA(e){var t=HX(e,"string");return Gi(t)=="symbol"?t:t+""}function HX(e,t){if(Gi(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Gi(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var D0=1,GX=function(e){function t(){var r;IX(this,t);for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];return r=BX(this,t,[].concat(i)),yf(r,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),yf(r,"handleKeyDown",function(s){if(s.key==="Escape"){var a,l,c,u;r.setState({dismissed:!0,dismissedAtCoordinate:{x:(a=(l=r.props.coordinate)===null||l===void 0?void 0:l.x)!==null&&a!==void 0?a:0,y:(c=(u=r.props.coordinate)===null||u===void 0?void 0:u.y)!==null&&c!==void 0?c:0}})}}),r}return $X(t,e),LX(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var n=this.wrapperNode.getBoundingClientRect();(Math.abs(n.width-this.state.lastBoundingBox.width)>D0||Math.abs(n.height-this.state.lastBoundingBox.height)>D0)&&this.setState({lastBoundingBox:{width:n.width,height:n.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:"componentDidMount",value:function(){document.addEventListener("keydown",this.handleKeyDown),this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){var n,i;this.props.active&&this.updateBBox(),this.state.dismissed&&(((n=this.props.coordinate)===null||n===void 0?void 0:n.x)!==this.state.dismissedAtCoordinate.x||((i=this.props.coordinate)===null||i===void 0?void 0:i.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var n=this,i=this.props,o=i.active,s=i.allowEscapeViewBox,a=i.animationDuration,l=i.animationEasing,c=i.children,u=i.coordinate,d=i.hasPayload,h=i.isAnimationActive,f=i.offset,g=i.position,m=i.reverseDirection,p=i.useTranslate3d,y=i.viewBox,w=i.wrapperStyle,b=kX({allowEscapeViewBox:s,coordinate:u,offsetTopLeft:f,position:g,reverseDirection:m,tooltipBox:this.state.lastBoundingBox,useTranslate3d:p,viewBox:y}),x=b.cssClasses,C=b.cssProperties,S=M0(M0({transition:h&&o?"transform ".concat(a,"ms ").concat(l):void 0},C),{},{pointerEvents:"none",visibility:!this.state.dismissed&&o&&d?"visible":"hidden",position:"absolute",top:0,left:0},w);return v.createElement("div",{tabIndex:-1,className:x,style:S,ref:function(P){n.wrapperNode=P}},c)}}])}(v.PureComponent),WX=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},pn={isSsr:WX()};function Wi(e){"@babel/helpers - typeof";return Wi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Wi(e)}function k0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function I0(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?k0(Object(r),!0).forEach(function(n){Qp(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):k0(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function jX(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function VX(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,dA(n.key),n)}}function UX(e,t,r){return t&&VX(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function KX(e,t,r){return t=sc(t),qX(e,uA()?Reflect.construct(t,r||[],sc(e).constructor):t.apply(e,r))}function qX(e,t){if(t&&(Wi(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return YX(e)}function YX(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function uA(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(uA=function(){return!!e})()}function sc(e){return sc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},sc(e)}function JX(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&bf(e,t)}function bf(e,t){return bf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},bf(e,t)}function Qp(e,t,r){return t=dA(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function dA(e){var t=XX(e,"string");return Wi(t)=="symbol"?t:t+""}function XX(e,t){if(Wi(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Wi(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function ZX(e){return e.dataKey}function QX(e,t){return v.isValidElement(e)?v.cloneElement(e,t):typeof e=="function"?v.createElement(e,t):v.createElement(EX,t)}var rr=function(e){function t(){return jX(this,t),KX(this,t,arguments)}return JX(t,e),UX(t,[{key:"render",value:function(){var n=this,i=this.props,o=i.active,s=i.allowEscapeViewBox,a=i.animationDuration,l=i.animationEasing,c=i.content,u=i.coordinate,d=i.filterNull,h=i.isAnimationActive,f=i.offset,g=i.payload,m=i.payloadUniqBy,p=i.position,y=i.reverseDirection,w=i.useTranslate3d,b=i.viewBox,x=i.wrapperStyle,C=g??[];d&&C.length&&(C=eA(g.filter(function(A){return A.value!=null&&(A.hide!==!0||n.props.includeHidden)}),m,ZX));var S=C.length>0;return v.createElement(GX,{allowEscapeViewBox:s,animationDuration:a,animationEasing:l,isAnimationActive:h,active:o,coordinate:u,hasPayload:S,offset:f,position:p,reverseDirection:y,useTranslate3d:w,viewBox:b,wrapperStyle:x},QX(c,I0(I0({},this.props),{},{payload:C})))}}])}(v.PureComponent);Qp(rr,"displayName","Tooltip");Qp(rr,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!pn.isSsr,itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,viewBox:{x:0,y:0,height:0,width:0},wrapperStyle:{}});var eZ=Tr,tZ=function(){return eZ.Date.now()},rZ=tZ,nZ=/\s/;function iZ(e){for(var t=e.length;t--&&nZ.test(e.charAt(t)););return t}var oZ=iZ,sZ=oZ,aZ=/^\s+/;function lZ(e){return e&&e.slice(0,sZ(e)+1).replace(aZ,"")}var cZ=lZ,uZ=cZ,_0=gn,dZ=So,L0=NaN,hZ=/^[-+]0x[0-9a-f]+$/i,fZ=/^0b[01]+$/i,gZ=/^0o[0-7]+$/i,pZ=parseInt;function mZ(e){if(typeof e=="number")return e;if(dZ(e))return L0;if(_0(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=_0(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=uZ(e);var r=fZ.test(e);return r||gZ.test(e)?pZ(e.slice(2),r?2:8):hZ.test(e)?L0:+e}var hA=mZ,vZ=gn,jd=rZ,B0=hA,yZ="Expected a function",bZ=Math.max,CZ=Math.min;function wZ(e,t,r){var n,i,o,s,a,l,c=0,u=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(yZ);t=B0(t)||0,vZ(r)&&(u=!!r.leading,d="maxWait"in r,o=d?bZ(B0(r.maxWait)||0,t):o,h="trailing"in r?!!r.trailing:h);function f(S){var A=n,P=i;return n=i=void 0,c=S,s=e.apply(P,A),s}function g(S){return c=S,a=setTimeout(y,t),u?f(S):s}function m(S){var A=S-l,P=S-c,E=t-A;return d?CZ(E,o-P):E}function p(S){var A=S-l,P=S-c;return l===void 0||A>=t||A<0||d&&P>=o}function y(){var S=jd();if(p(S))return w(S);a=setTimeout(y,m(S))}function w(S){return a=void 0,h&&n?f(S):(n=i=void 0,s)}function b(){a!==void 0&&clearTimeout(a),c=0,n=l=i=a=void 0}function x(){return a===void 0?s:w(jd())}function C(){var S=jd(),A=p(S);if(n=arguments,i=this,l=S,A){if(a===void 0)return g(l);if(d)return clearTimeout(a),a=setTimeout(y,t),f(l)}return a===void 0&&(a=setTimeout(y,t)),s}return C.cancel=b,C.flush=x,C}var SZ=wZ,xZ=SZ,AZ=gn,PZ="Expected a function";function RZ(e,t,r){var n=!0,i=!0;if(typeof e!="function")throw new TypeError(PZ);return AZ(r)&&(n="leading"in r?!!r.leading:n,i="trailing"in r?!!r.trailing:i),xZ(e,t,{leading:n,maxWait:t,trailing:i})}var EZ=RZ;const TZ=Le(EZ);var em=function(t){return null};em.displayName="Cell";function Ns(e){"@babel/helpers - typeof";return Ns=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ns(e)}function z0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Cf(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?z0(Object(r),!0).forEach(function(n){FZ(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):z0(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function FZ(e,t,r){return t=OZ(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function OZ(e){var t=MZ(e,"string");return Ns(t)=="symbol"?t:t+""}function MZ(e,t){if(Ns(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Ns(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var di={widthCache:{},cacheCount:0},DZ=2e3,kZ={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},N0="recharts_measurement_span";function IZ(e){var t=Cf({},e);return Object.keys(t).forEach(function(r){t[r]||delete t[r]}),t}var us=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||pn.isSsr)return{width:0,height:0};var n=IZ(r),i=JSON.stringify({text:t,copyStyle:n});if(di.widthCache[i])return di.widthCache[i];try{var o=document.getElementById(N0);o||(o=document.createElement("span"),o.setAttribute("id",N0),o.setAttribute("aria-hidden","true"),document.body.appendChild(o));var s=Cf(Cf({},kZ),n);Object.assign(o.style,s),o.textContent="".concat(t);var a=o.getBoundingClientRect(),l={width:a.width,height:a.height};return di.widthCache[i]=l,++di.cacheCount>DZ&&(di.cacheCount=0,di.widthCache={}),l}catch{return{width:0,height:0}}},_Z=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function $s(e){"@babel/helpers - typeof";return $s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$s(e)}function ac(e,t){return NZ(e)||zZ(e,t)||BZ(e,t)||LZ()}function LZ(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
44
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function BZ(e,t){if(e){if(typeof e=="string")return $0(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return $0(e,t)}}function $0(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function zZ(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function NZ(e){if(Array.isArray(e))return e}function $Z(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function H0(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,GZ(n.key),n)}}function HZ(e,t,r){return t&&H0(e.prototype,t),r&&H0(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function GZ(e){var t=WZ(e,"string");return $s(t)=="symbol"?t:t+""}function WZ(e,t){if($s(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if($s(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var G0=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,W0=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,jZ=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,VZ=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,fA={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},UZ=Object.keys(fA),vi="NaN";function KZ(e,t){return e*fA[t]}var Za=function(){function e(t,r){$Z(this,e),this.num=t,this.unit=r,this.num=t,this.unit=r,Number.isNaN(t)&&(this.unit=""),r!==""&&!jZ.test(r)&&(this.num=NaN,this.unit=""),UZ.includes(r)&&(this.num=KZ(t,r),this.unit="px")}return HZ(e,[{key:"add",value:function(r){return this.unit!==r.unit?new e(NaN,""):new e(this.num+r.num,this.unit)}},{key:"subtract",value:function(r){return this.unit!==r.unit?new e(NaN,""):new e(this.num-r.num,this.unit)}},{key:"multiply",value:function(r){return this.unit!==""&&r.unit!==""&&this.unit!==r.unit?new e(NaN,""):new e(this.num*r.num,this.unit||r.unit)}},{key:"divide",value:function(r){return this.unit!==""&&r.unit!==""&&this.unit!==r.unit?new e(NaN,""):new e(this.num/r.num,this.unit||r.unit)}},{key:"toString",value:function(){return"".concat(this.num).concat(this.unit)}},{key:"isNaN",value:function(){return Number.isNaN(this.num)}}],[{key:"parse",value:function(r){var n,i=(n=VZ.exec(r))!==null&&n!==void 0?n:[],o=ac(i,3),s=o[1],a=o[2];return new e(parseFloat(s),a??"")}}])}();function gA(e){if(e.includes(vi))return vi;for(var t=e;t.includes("*")||t.includes("/");){var r,n=(r=G0.exec(t))!==null&&r!==void 0?r:[],i=ac(n,4),o=i[1],s=i[2],a=i[3],l=Za.parse(o??""),c=Za.parse(a??""),u=s==="*"?l.multiply(c):l.divide(c);if(u.isNaN())return vi;t=t.replace(G0,u.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var d,h=(d=W0.exec(t))!==null&&d!==void 0?d:[],f=ac(h,4),g=f[1],m=f[2],p=f[3],y=Za.parse(g??""),w=Za.parse(p??""),b=m==="+"?y.add(w):y.subtract(w);if(b.isNaN())return vi;t=t.replace(W0,b.toString())}return t}var j0=/\(([^()]*)\)/;function qZ(e){for(var t=e;t.includes("(");){var r=j0.exec(t),n=ac(r,2),i=n[1];t=t.replace(j0,gA(i))}return t}function YZ(e){var t=e.replace(/\s+/g,"");return t=qZ(t),t=gA(t),t}function JZ(e){try{return YZ(e)}catch{return vi}}function Vd(e){var t=JZ(e.slice(5,-1));return t===vi?"":t}var XZ=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],ZZ=["dx","dy","angle","className","breakAll"];function wf(){return wf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},wf.apply(this,arguments)}function V0(e,t){if(e==null)return{};var r=QZ(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function QZ(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function U0(e,t){return nQ(e)||rQ(e,t)||tQ(e,t)||eQ()}function eQ(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
45
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function tQ(e,t){if(e){if(typeof e=="string")return K0(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return K0(e,t)}}function K0(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function rQ(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function nQ(e){if(Array.isArray(e))return e}var pA=/[ \f\n\r\t\v\u2028\u2029]+/,mA=function(t){var r=t.children,n=t.breakAll,i=t.style;try{var o=[];ue(r)||(n?o=r.toString().split(""):o=r.toString().split(pA));var s=o.map(function(l){return{word:l,width:us(l,i).width}}),a=n?0:us(" ",i).width;return{wordsWithComputedWidth:s,spaceWidth:a}}catch{return null}},iQ=function(t,r,n,i,o){var s=t.maxLines,a=t.children,l=t.style,c=t.breakAll,u=Z(s),d=a,h=function(){var k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return k.reduce(function(B,N){var z=N.word,W=N.width,D=B[B.length-1];if(D&&(i==null||o||D.width+W+n<Number(i)))D.words.push(z),D.width+=W+n;else{var L={words:[z],width:W};B.push(L)}return B},[])},f=h(r),g=function(k){return k.reduce(function(B,N){return B.width>N.width?B:N})};if(!u)return f;for(var m="…",p=function(k){var B=d.slice(0,k),N=mA({breakAll:c,style:l,children:B+m}).wordsWithComputedWidth,z=h(N),W=z.length>s||g(z).width>Number(i);return[W,z]},y=0,w=d.length-1,b=0,x;y<=w&&b<=d.length-1;){var C=Math.floor((y+w)/2),S=C-1,A=p(S),P=U0(A,2),E=P[0],O=P[1],R=p(C),T=U0(R,1),F=T[0];if(!E&&!F&&(y=C+1),E&&F&&(w=C-1),!E&&F){x=O;break}b++}return x||f},q0=function(t){var r=ue(t)?[]:t.toString().split(pA);return[{words:r}]},oQ=function(t){var r=t.width,n=t.scaleToFit,i=t.children,o=t.style,s=t.breakAll,a=t.maxLines;if((r||n)&&!pn.isSsr){var l,c,u=mA({breakAll:s,children:i,style:o});if(u){var d=u.wordsWithComputedWidth,h=u.spaceWidth;l=d,c=h}else return q0(i);return iQ({breakAll:s,children:i,maxLines:a,style:o},l,c,r,n)}return q0(i)},Y0="#808080",lc=function(t){var r=t.x,n=r===void 0?0:r,i=t.y,o=i===void 0?0:i,s=t.lineHeight,a=s===void 0?"1em":s,l=t.capHeight,c=l===void 0?"0.71em":l,u=t.scaleToFit,d=u===void 0?!1:u,h=t.textAnchor,f=h===void 0?"start":h,g=t.verticalAnchor,m=g===void 0?"end":g,p=t.fill,y=p===void 0?Y0:p,w=V0(t,XZ),b=v.useMemo(function(){return oQ({breakAll:w.breakAll,children:w.children,maxLines:w.maxLines,scaleToFit:d,style:w.style,width:w.width})},[w.breakAll,w.children,w.maxLines,d,w.style,w.width]),x=w.dx,C=w.dy,S=w.angle,A=w.className,P=w.breakAll,E=V0(w,ZZ);if(!et(n)||!et(o))return null;var O=n+(Z(x)?x:0),R=o+(Z(C)?C:0),T;switch(m){case"start":T=Vd("calc(".concat(c,")"));break;case"middle":T=Vd("calc(".concat((b.length-1)/2," * -").concat(a," + (").concat(c," / 2))"));break;default:T=Vd("calc(".concat(b.length-1," * -").concat(a,")"));break}var F=[];if(d){var I=b[0].width,k=w.width;F.push("scale(".concat((Z(k)?k/I:1)/I,")"))}return S&&F.push("rotate(".concat(S,", ").concat(O,", ").concat(R,")")),F.length&&(E.transform=F.join(" ")),v.createElement("text",wf({},de(E,!0),{x:O,y:R,className:ve("recharts-text",A),textAnchor:f,fill:y.includes("url")?Y0:y}),b.map(function(B,N){var z=B.words.join(P?"":" ");return v.createElement("tspan",{x:O,dy:N===0?T:a,key:"".concat(z,"-").concat(N)},z)}))};function an(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function sQ(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function tm(e){let t,r,n;e.length!==2?(t=an,r=(a,l)=>an(e(a),l),n=(a,l)=>e(a)-l):(t=e===an||e===sQ?e:aQ,r=e,n=e);function i(a,l,c=0,u=a.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;r(a[d],l)<0?c=d+1:u=d}while(c<u)}return c}function o(a,l,c=0,u=a.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;r(a[d],l)<=0?c=d+1:u=d}while(c<u)}return c}function s(a,l,c=0,u=a.length){const d=i(a,l,c,u-1);return d>c&&n(a[d-1],l)>-n(a[d],l)?d-1:d}return{left:i,center:s,right:o}}function aQ(){return 0}function vA(e){return e===null?NaN:+e}function*lQ(e,t){for(let r of e)r!=null&&(r=+r)>=r&&(yield r)}const cQ=tm(an),Oa=cQ.right;tm(vA).center;class J0 extends Map{constructor(t,r=hQ){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),t!=null)for(const[n,i]of t)this.set(n,i)}get(t){return super.get(X0(this,t))}has(t){return super.has(X0(this,t))}set(t,r){return super.set(uQ(this,t),r)}delete(t){return super.delete(dQ(this,t))}}function X0({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):r}function uQ({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):(e.set(n,r),r)}function dQ({_intern:e,_key:t},r){const n=t(r);return e.has(n)&&(r=e.get(n),e.delete(n)),r}function hQ(e){return e!==null&&typeof e=="object"?e.valueOf():e}function fQ(e=an){if(e===an)return yA;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,r)=>{const n=e(t,r);return n||n===0?n:(e(r,r)===0)-(e(t,t)===0)}}function yA(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const gQ=Math.sqrt(50),pQ=Math.sqrt(10),mQ=Math.sqrt(2);function cc(e,t,r){const n=(t-e)/Math.max(0,r),i=Math.floor(Math.log10(n)),o=n/Math.pow(10,i),s=o>=gQ?10:o>=pQ?5:o>=mQ?2:1;let a,l,c;return i<0?(c=Math.pow(10,-i)/s,a=Math.round(e*c),l=Math.round(t*c),a/c<e&&++a,l/c>t&&--l,c=-c):(c=Math.pow(10,i)*s,a=Math.round(e/c),l=Math.round(t/c),a*c<e&&++a,l*c>t&&--l),l<a&&.5<=r&&r<2?cc(e,t,r*2):[a,l,c]}function Sf(e,t,r){if(t=+t,e=+e,r=+r,!(r>0))return[];if(e===t)return[e];const n=t<e,[i,o,s]=n?cc(t,e,r):cc(e,t,r);if(!(o>=i))return[];const a=o-i+1,l=new Array(a);if(n)if(s<0)for(let c=0;c<a;++c)l[c]=(o-c)/-s;else for(let c=0;c<a;++c)l[c]=(o-c)*s;else if(s<0)for(let c=0;c<a;++c)l[c]=(i+c)/-s;else for(let c=0;c<a;++c)l[c]=(i+c)*s;return l}function xf(e,t,r){return t=+t,e=+e,r=+r,cc(e,t,r)[2]}function Af(e,t,r){t=+t,e=+e,r=+r;const n=t<e,i=n?xf(t,e,r):xf(e,t,r);return(n?-1:1)*(i<0?1/-i:i)}function Z0(e,t){let r;for(const n of e)n!=null&&(r<n||r===void 0&&n>=n)&&(r=n);return r}function Q0(e,t){let r;for(const n of e)n!=null&&(r>n||r===void 0&&n>=n)&&(r=n);return r}function bA(e,t,r=0,n=1/0,i){if(t=Math.floor(t),r=Math.floor(Math.max(0,r)),n=Math.floor(Math.min(e.length-1,n)),!(r<=t&&t<=n))return e;for(i=i===void 0?yA:fQ(i);n>r;){if(n-r>600){const l=n-r+1,c=t-r+1,u=Math.log(l),d=.5*Math.exp(2*u/3),h=.5*Math.sqrt(u*d*(l-d)/l)*(c-l/2<0?-1:1),f=Math.max(r,Math.floor(t-c*d/l+h)),g=Math.min(n,Math.floor(t+(l-c)*d/l+h));bA(e,t,f,g,i)}const o=e[t];let s=r,a=n;for(jo(e,r,t),i(e[n],o)>0&&jo(e,r,n);s<a;){for(jo(e,s,a),++s,--a;i(e[s],o)<0;)++s;for(;i(e[a],o)>0;)--a}i(e[r],o)===0?jo(e,r,a):(++a,jo(e,a,n)),a<=t&&(r=a+1),t<=a&&(n=a-1)}return e}function jo(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function vQ(e,t,r){if(e=Float64Array.from(lQ(e)),!(!(n=e.length)||isNaN(t=+t))){if(t<=0||n<2)return Q0(e);if(t>=1)return Z0(e);var n,i=(n-1)*t,o=Math.floor(i),s=Z0(bA(e,o).subarray(0,o+1)),a=Q0(e.subarray(o+1));return s+(a-s)*(i-o)}}function yQ(e,t,r=vA){if(!(!(n=e.length)||isNaN(t=+t))){if(t<=0||n<2)return+r(e[0],0,e);if(t>=1)return+r(e[n-1],n-1,e);var n,i=(n-1)*t,o=Math.floor(i),s=+r(e[o],o,e),a=+r(e[o+1],o+1,e);return s+(a-s)*(i-o)}}function bQ(e,t,r){e=+e,t=+t,r=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+r;for(var n=-1,i=Math.max(0,Math.ceil((t-e)/r))|0,o=new Array(i);++n<i;)o[n]=e+n*r;return o}function er(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Yr(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const Pf=Symbol("implicit");function rm(){var e=new J0,t=[],r=[],n=Pf;function i(o){let s=e.get(o);if(s===void 0){if(n!==Pf)return n;e.set(o,s=t.push(o)-1)}return r[s%r.length]}return i.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new J0;for(const s of o)e.has(s)||e.set(s,t.push(s)-1);return i},i.range=function(o){return arguments.length?(r=Array.from(o),i):r.slice()},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return rm(t,r).unknown(n)},er.apply(i,arguments),i}function Hs(){var e=rm().unknown(void 0),t=e.domain,r=e.range,n=0,i=1,o,s,a=!1,l=0,c=0,u=.5;delete e.unknown;function d(){var h=t().length,f=i<n,g=f?i:n,m=f?n:i;o=(m-g)/Math.max(1,h-l+c*2),a&&(o=Math.floor(o)),g+=(m-g-o*(h-l))*u,s=o*(1-l),a&&(g=Math.round(g),s=Math.round(s));var p=bQ(h).map(function(y){return g+o*y});return r(f?p.reverse():p)}return e.domain=function(h){return arguments.length?(t(h),d()):t()},e.range=function(h){return arguments.length?([n,i]=h,n=+n,i=+i,d()):[n,i]},e.rangeRound=function(h){return[n,i]=h,n=+n,i=+i,a=!0,d()},e.bandwidth=function(){return s},e.step=function(){return o},e.round=function(h){return arguments.length?(a=!!h,d()):a},e.padding=function(h){return arguments.length?(l=Math.min(1,c=+h),d()):l},e.paddingInner=function(h){return arguments.length?(l=Math.min(1,h),d()):l},e.paddingOuter=function(h){return arguments.length?(c=+h,d()):c},e.align=function(h){return arguments.length?(u=Math.max(0,Math.min(1,h)),d()):u},e.copy=function(){return Hs(t(),[n,i]).round(a).paddingInner(l).paddingOuter(c).align(u)},er.apply(d(),arguments)}function CA(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return CA(t())},e}function ds(){return CA(Hs.apply(null,arguments).paddingInner(1))}function nm(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function wA(e,t){var r=Object.create(e.prototype);for(var n in t)r[n]=t[n];return r}function Ma(){}var Gs=.7,uc=1/Gs,Mi="\\s*([+-]?\\d+)\\s*",Ws="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",br="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",CQ=/^#([0-9a-f]{3,8})$/,wQ=new RegExp(`^rgb\\(${Mi},${Mi},${Mi}\\)$`),SQ=new RegExp(`^rgb\\(${br},${br},${br}\\)$`),xQ=new RegExp(`^rgba\\(${Mi},${Mi},${Mi},${Ws}\\)$`),AQ=new RegExp(`^rgba\\(${br},${br},${br},${Ws}\\)$`),PQ=new RegExp(`^hsl\\(${Ws},${br},${br}\\)$`),RQ=new RegExp(`^hsla\\(${Ws},${br},${br},${Ws}\\)$`),eb={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};nm(Ma,js,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:tb,formatHex:tb,formatHex8:EQ,formatHsl:TQ,formatRgb:rb,toString:rb});function tb(){return this.rgb().formatHex()}function EQ(){return this.rgb().formatHex8()}function TQ(){return SA(this).formatHsl()}function rb(){return this.rgb().formatRgb()}function js(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=CQ.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?nb(t):r===3?new At(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?Qa(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?Qa(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=wQ.exec(e))?new At(t[1],t[2],t[3],1):(t=SQ.exec(e))?new At(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=xQ.exec(e))?Qa(t[1],t[2],t[3],t[4]):(t=AQ.exec(e))?Qa(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=PQ.exec(e))?sb(t[1],t[2]/100,t[3]/100,1):(t=RQ.exec(e))?sb(t[1],t[2]/100,t[3]/100,t[4]):eb.hasOwnProperty(e)?nb(eb[e]):e==="transparent"?new At(NaN,NaN,NaN,0):null}function nb(e){return new At(e>>16&255,e>>8&255,e&255,1)}function Qa(e,t,r,n){return n<=0&&(e=t=r=NaN),new At(e,t,r,n)}function FQ(e){return e instanceof Ma||(e=js(e)),e?(e=e.rgb(),new At(e.r,e.g,e.b,e.opacity)):new At}function Rf(e,t,r,n){return arguments.length===1?FQ(e):new At(e,t,r,n??1)}function At(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}nm(At,Rf,wA(Ma,{brighter(e){return e=e==null?uc:Math.pow(uc,e),new At(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Gs:Math.pow(Gs,e),new At(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new At(zn(this.r),zn(this.g),zn(this.b),dc(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:ib,formatHex:ib,formatHex8:OQ,formatRgb:ob,toString:ob}));function ib(){return`#${Tn(this.r)}${Tn(this.g)}${Tn(this.b)}`}function OQ(){return`#${Tn(this.r)}${Tn(this.g)}${Tn(this.b)}${Tn((isNaN(this.opacity)?1:this.opacity)*255)}`}function ob(){const e=dc(this.opacity);return`${e===1?"rgb(":"rgba("}${zn(this.r)}, ${zn(this.g)}, ${zn(this.b)}${e===1?")":`, ${e})`}`}function dc(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function zn(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Tn(e){return e=zn(e),(e<16?"0":"")+e.toString(16)}function sb(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new sr(e,t,r,n)}function SA(e){if(e instanceof sr)return new sr(e.h,e.s,e.l,e.opacity);if(e instanceof Ma||(e=js(e)),!e)return new sr;if(e instanceof sr)return e;e=e.rgb();var t=e.r/255,r=e.g/255,n=e.b/255,i=Math.min(t,r,n),o=Math.max(t,r,n),s=NaN,a=o-i,l=(o+i)/2;return a?(t===o?s=(r-n)/a+(r<n)*6:r===o?s=(n-t)/a+2:s=(t-r)/a+4,a/=l<.5?o+i:2-o-i,s*=60):a=l>0&&l<1?0:s,new sr(s,a,l,e.opacity)}function MQ(e,t,r,n){return arguments.length===1?SA(e):new sr(e,t,r,n??1)}function sr(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}nm(sr,MQ,wA(Ma,{brighter(e){return e=e==null?uc:Math.pow(uc,e),new sr(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Gs:Math.pow(Gs,e),new sr(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*t,i=2*r-n;return new At(Ud(e>=240?e-240:e+120,i,n),Ud(e,i,n),Ud(e<120?e+240:e-120,i,n),this.opacity)},clamp(){return new sr(ab(this.h),el(this.s),el(this.l),dc(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=dc(this.opacity);return`${e===1?"hsl(":"hsla("}${ab(this.h)}, ${el(this.s)*100}%, ${el(this.l)*100}%${e===1?")":`, ${e})`}`}}));function ab(e){return e=(e||0)%360,e<0?e+360:e}function el(e){return Math.max(0,Math.min(1,e||0))}function Ud(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const im=e=>()=>e;function DQ(e,t){return function(r){return e+r*t}}function kQ(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(n){return Math.pow(e+n*t,r)}}function IQ(e){return(e=+e)==1?xA:function(t,r){return r-t?kQ(t,r,e):im(isNaN(t)?r:t)}}function xA(e,t){var r=t-e;return r?DQ(e,r):im(isNaN(e)?t:e)}const lb=function e(t){var r=IQ(t);function n(i,o){var s=r((i=Rf(i)).r,(o=Rf(o)).r),a=r(i.g,o.g),l=r(i.b,o.b),c=xA(i.opacity,o.opacity);return function(u){return i.r=s(u),i.g=a(u),i.b=l(u),i.opacity=c(u),i+""}}return n.gamma=e,n}(1);function _Q(e,t){t||(t=[]);var r=e?Math.min(t.length,e.length):0,n=t.slice(),i;return function(o){for(i=0;i<r;++i)n[i]=e[i]*(1-o)+t[i]*o;return n}}function LQ(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function BQ(e,t){var r=t?t.length:0,n=e?Math.min(r,e.length):0,i=new Array(n),o=new Array(r),s;for(s=0;s<n;++s)i[s]=Do(e[s],t[s]);for(;s<r;++s)o[s]=t[s];return function(a){for(s=0;s<n;++s)o[s]=i[s](a);return o}}function zQ(e,t){var r=new Date;return e=+e,t=+t,function(n){return r.setTime(e*(1-n)+t*n),r}}function hc(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}function NQ(e,t){var r={},n={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?r[i]=Do(e[i],t[i]):n[i]=t[i];return function(o){for(i in r)n[i]=r[i](o);return n}}var Ef=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Kd=new RegExp(Ef.source,"g");function $Q(e){return function(){return e}}function HQ(e){return function(t){return e(t)+""}}function GQ(e,t){var r=Ef.lastIndex=Kd.lastIndex=0,n,i,o,s=-1,a=[],l=[];for(e=e+"",t=t+"";(n=Ef.exec(e))&&(i=Kd.exec(t));)(o=i.index)>r&&(o=t.slice(r,o),a[s]?a[s]+=o:a[++s]=o),(n=n[0])===(i=i[0])?a[s]?a[s]+=i:a[++s]=i:(a[++s]=null,l.push({i:s,x:hc(n,i)})),r=Kd.lastIndex;return r<t.length&&(o=t.slice(r),a[s]?a[s]+=o:a[++s]=o),a.length<2?l[0]?HQ(l[0].x):$Q(t):(t=l.length,function(c){for(var u=0,d;u<t;++u)a[(d=l[u]).i]=d.x(c);return a.join("")})}function Do(e,t){var r=typeof t,n;return t==null||r==="boolean"?im(t):(r==="number"?hc:r==="string"?(n=js(t))?(t=n,lb):GQ:t instanceof js?lb:t instanceof Date?zQ:LQ(t)?_Q:Array.isArray(t)?BQ:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?NQ:hc)(e,t)}function om(e,t){return e=+e,t=+t,function(r){return Math.round(e*(1-r)+t*r)}}function WQ(e,t){t===void 0&&(t=e,e=Do);for(var r=0,n=t.length-1,i=t[0],o=new Array(n<0?0:n);r<n;)o[r]=e(i,i=t[++r]);return function(s){var a=Math.max(0,Math.min(n-1,Math.floor(s*=n)));return o[a](s-a)}}function jQ(e){return function(){return e}}function fc(e){return+e}var cb=[0,1];function wt(e){return e}function Tf(e,t){return(t-=e=+e)?function(r){return(r-e)/t}:jQ(isNaN(t)?NaN:.5)}function VQ(e,t){var r;return e>t&&(r=e,e=t,t=r),function(n){return Math.max(e,Math.min(t,n))}}function UQ(e,t,r){var n=e[0],i=e[1],o=t[0],s=t[1];return i<n?(n=Tf(i,n),o=r(s,o)):(n=Tf(n,i),o=r(o,s)),function(a){return o(n(a))}}function KQ(e,t,r){var n=Math.min(e.length,t.length)-1,i=new Array(n),o=new Array(n),s=-1;for(e[n]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<n;)i[s]=Tf(e[s],e[s+1]),o[s]=r(t[s],t[s+1]);return function(a){var l=Oa(e,a,1,n)-1;return o[l](i[l](a))}}function Da(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Fu(){var e=cb,t=cb,r=Do,n,i,o,s=wt,a,l,c;function u(){var h=Math.min(e.length,t.length);return s!==wt&&(s=VQ(e[0],e[h-1])),a=h>2?KQ:UQ,l=c=null,d}function d(h){return h==null||isNaN(h=+h)?o:(l||(l=a(e.map(n),t,r)))(n(s(h)))}return d.invert=function(h){return s(i((c||(c=a(t,e.map(n),hc)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,fc),u()):e.slice()},d.range=function(h){return arguments.length?(t=Array.from(h),u()):t.slice()},d.rangeRound=function(h){return t=Array.from(h),r=om,u()},d.clamp=function(h){return arguments.length?(s=h?!0:wt,u()):s!==wt},d.interpolate=function(h){return arguments.length?(r=h,u()):r},d.unknown=function(h){return arguments.length?(o=h,d):o},function(h,f){return n=h,i=f,u()}}function sm(){return Fu()(wt,wt)}function qQ(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function gc(e,t){if((r=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var r,n=e.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+e.slice(r+1)]}function ji(e){return e=gc(Math.abs(e)),e?e[1]:NaN}function YQ(e,t){return function(r,n){for(var i=r.length,o=[],s=0,a=e[0],l=0;i>0&&a>0&&(l+a+1>n&&(a=Math.max(1,n-l)),o.push(r.substring(i-=a,i+a)),!((l+=a+1)>n));)a=e[s=(s+1)%e.length];return o.reverse().join(t)}}function JQ(e){return function(t){return t.replace(/[0-9]/g,function(r){return e[+r]})}}var XQ=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Vs(e){if(!(t=XQ.exec(e)))throw new Error("invalid format: "+e);var t;return new am({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}Vs.prototype=am.prototype;function am(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}am.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function ZQ(e){e:for(var t=e.length,r=1,n=-1,i;r<t;++r)switch(e[r]){case".":n=i=r;break;case"0":n===0&&(n=r),i=r;break;default:if(!+e[r])break e;n>0&&(n=0);break}return n>0?e.slice(0,n)+e.slice(i+1):e}var AA;function QQ(e,t){var r=gc(e,t);if(!r)return e+"";var n=r[0],i=r[1],o=i-(AA=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,s=n.length;return o===s?n:o>s?n+new Array(o-s+1).join("0"):o>0?n.slice(0,o)+"."+n.slice(o):"0."+new Array(1-o).join("0")+gc(e,Math.max(0,t+o-1))[0]}function ub(e,t){var r=gc(e,t);if(!r)return e+"";var n=r[0],i=r[1];return i<0?"0."+new Array(-i).join("0")+n:n.length>i+1?n.slice(0,i+1)+"."+n.slice(i+1):n+new Array(i-n.length+2).join("0")}const db={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:qQ,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>ub(e*100,t),r:ub,s:QQ,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function hb(e){return e}var fb=Array.prototype.map,gb=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function eee(e){var t=e.grouping===void 0||e.thousands===void 0?hb:YQ(fb.call(e.grouping,Number),e.thousands+""),r=e.currency===void 0?"":e.currency[0]+"",n=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?hb:JQ(fb.call(e.numerals,String)),s=e.percent===void 0?"%":e.percent+"",a=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(d){d=Vs(d);var h=d.fill,f=d.align,g=d.sign,m=d.symbol,p=d.zero,y=d.width,w=d.comma,b=d.precision,x=d.trim,C=d.type;C==="n"?(w=!0,C="g"):db[C]||(b===void 0&&(b=12),x=!0,C="g"),(p||h==="0"&&f==="=")&&(p=!0,h="0",f="=");var S=m==="$"?r:m==="#"&&/[boxX]/.test(C)?"0"+C.toLowerCase():"",A=m==="$"?n:/[%p]/.test(C)?s:"",P=db[C],E=/[defgprs%]/.test(C);b=b===void 0?6:/[gprs]/.test(C)?Math.max(1,Math.min(21,b)):Math.max(0,Math.min(20,b));function O(R){var T=S,F=A,I,k,B;if(C==="c")F=P(R)+F,R="";else{R=+R;var N=R<0||1/R<0;if(R=isNaN(R)?l:P(Math.abs(R),b),x&&(R=ZQ(R)),N&&+R==0&&g!=="+"&&(N=!1),T=(N?g==="("?g:a:g==="-"||g==="("?"":g)+T,F=(C==="s"?gb[8+AA/3]:"")+F+(N&&g==="("?")":""),E){for(I=-1,k=R.length;++I<k;)if(B=R.charCodeAt(I),48>B||B>57){F=(B===46?i+R.slice(I+1):R.slice(I))+F,R=R.slice(0,I);break}}}w&&!p&&(R=t(R,1/0));var z=T.length+R.length+F.length,W=z<y?new Array(y-z+1).join(h):"";switch(w&&p&&(R=t(W+R,W.length?y-F.length:1/0),W=""),f){case"<":R=T+R+F+W;break;case"=":R=T+W+R+F;break;case"^":R=W.slice(0,z=W.length>>1)+T+R+F+W.slice(z);break;default:R=W+T+R+F;break}return o(R)}return O.toString=function(){return d+""},O}function u(d,h){var f=c((d=Vs(d),d.type="f",d)),g=Math.max(-8,Math.min(8,Math.floor(ji(h)/3)))*3,m=Math.pow(10,-g),p=gb[8+g/3];return function(y){return f(m*y)+p}}return{format:c,formatPrefix:u}}var tl,lm,PA;tee({thousands:",",grouping:[3],currency:["$",""]});function tee(e){return tl=eee(e),lm=tl.format,PA=tl.formatPrefix,tl}function ree(e){return Math.max(0,-ji(Math.abs(e)))}function nee(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(ji(t)/3)))*3-ji(Math.abs(e)))}function iee(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,ji(t)-ji(e))+1}function RA(e,t,r,n){var i=Af(e,t,r),o;switch(n=Vs(n??",f"),n.type){case"s":{var s=Math.max(Math.abs(e),Math.abs(t));return n.precision==null&&!isNaN(o=nee(i,s))&&(n.precision=o),PA(n,s)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(o=iee(i,Math.max(Math.abs(e),Math.abs(t))))&&(n.precision=o-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(o=ree(i))&&(n.precision=o-(n.type==="%")*2);break}}return lm(n)}function mn(e){var t=e.domain;return e.ticks=function(r){var n=t();return Sf(n[0],n[n.length-1],r??10)},e.tickFormat=function(r,n){var i=t();return RA(i[0],i[i.length-1],r??10,n)},e.nice=function(r){r==null&&(r=10);var n=t(),i=0,o=n.length-1,s=n[i],a=n[o],l,c,u=10;for(a<s&&(c=s,s=a,a=c,c=i,i=o,o=c);u-- >0;){if(c=xf(s,a,r),c===l)return n[i]=s,n[o]=a,t(n);if(c>0)s=Math.floor(s/c)*c,a=Math.ceil(a/c)*c;else if(c<0)s=Math.ceil(s*c)/c,a=Math.floor(a*c)/c;else break;l=c}return e},e}function pc(){var e=sm();return e.copy=function(){return Da(e,pc())},er.apply(e,arguments),mn(e)}function EA(e){var t;function r(n){return n==null||isNaN(n=+n)?t:n}return r.invert=r,r.domain=r.range=function(n){return arguments.length?(e=Array.from(n,fc),r):e.slice()},r.unknown=function(n){return arguments.length?(t=n,r):t},r.copy=function(){return EA(e).unknown(t)},e=arguments.length?Array.from(e,fc):[0,1],mn(r)}function TA(e,t){e=e.slice();var r=0,n=e.length-1,i=e[r],o=e[n],s;return o<i&&(s=r,r=n,n=s,s=i,i=o,o=s),e[r]=t.floor(i),e[n]=t.ceil(o),e}function pb(e){return Math.log(e)}function mb(e){return Math.exp(e)}function oee(e){return-Math.log(-e)}function see(e){return-Math.exp(-e)}function aee(e){return isFinite(e)?+("1e"+e):e<0?0:e}function lee(e){return e===10?aee:e===Math.E?Math.exp:t=>Math.pow(e,t)}function cee(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function vb(e){return(t,r)=>-e(-t,r)}function cm(e){const t=e(pb,mb),r=t.domain;let n=10,i,o;function s(){return i=cee(n),o=lee(n),r()[0]<0?(i=vb(i),o=vb(o),e(oee,see)):e(pb,mb),t}return t.base=function(a){return arguments.length?(n=+a,s()):n},t.domain=function(a){return arguments.length?(r(a),s()):r()},t.ticks=a=>{const l=r();let c=l[0],u=l[l.length-1];const d=u<c;d&&([c,u]=[u,c]);let h=i(c),f=i(u),g,m;const p=a==null?10:+a;let y=[];if(!(n%1)&&f-h<p){if(h=Math.floor(h),f=Math.ceil(f),c>0){for(;h<=f;++h)for(g=1;g<n;++g)if(m=h<0?g/o(-h):g*o(h),!(m<c)){if(m>u)break;y.push(m)}}else for(;h<=f;++h)for(g=n-1;g>=1;--g)if(m=h>0?g/o(-h):g*o(h),!(m<c)){if(m>u)break;y.push(m)}y.length*2<p&&(y=Sf(c,u,p))}else y=Sf(h,f,Math.min(f-h,p)).map(o);return d?y.reverse():y},t.tickFormat=(a,l)=>{if(a==null&&(a=10),l==null&&(l=n===10?"s":","),typeof l!="function"&&(!(n%1)&&(l=Vs(l)).precision==null&&(l.trim=!0),l=lm(l)),a===1/0)return l;const c=Math.max(1,n*a/t.ticks().length);return u=>{let d=u/o(Math.round(i(u)));return d*n<n-.5&&(d*=n),d<=c?l(u):""}},t.nice=()=>r(TA(r(),{floor:a=>o(Math.floor(i(a))),ceil:a=>o(Math.ceil(i(a)))})),t}function FA(){const e=cm(Fu()).domain([1,10]);return e.copy=()=>Da(e,FA()).base(e.base()),er.apply(e,arguments),e}function yb(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function bb(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function um(e){var t=1,r=e(yb(t),bb(t));return r.constant=function(n){return arguments.length?e(yb(t=+n),bb(t)):t},mn(r)}function OA(){var e=um(Fu());return e.copy=function(){return Da(e,OA()).constant(e.constant())},er.apply(e,arguments)}function Cb(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function uee(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function dee(e){return e<0?-e*e:e*e}function dm(e){var t=e(wt,wt),r=1;function n(){return r===1?e(wt,wt):r===.5?e(uee,dee):e(Cb(r),Cb(1/r))}return t.exponent=function(i){return arguments.length?(r=+i,n()):r},mn(t)}function hm(){var e=dm(Fu());return e.copy=function(){return Da(e,hm()).exponent(e.exponent())},er.apply(e,arguments),e}function hee(){return hm.apply(null,arguments).exponent(.5)}function wb(e){return Math.sign(e)*e*e}function fee(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function MA(){var e=sm(),t=[0,1],r=!1,n;function i(o){var s=fee(e(o));return isNaN(s)?n:r?Math.round(s):s}return i.invert=function(o){return e.invert(wb(o))},i.domain=function(o){return arguments.length?(e.domain(o),i):e.domain()},i.range=function(o){return arguments.length?(e.range((t=Array.from(o,fc)).map(wb)),i):t.slice()},i.rangeRound=function(o){return i.range(o).round(!0)},i.round=function(o){return arguments.length?(r=!!o,i):r},i.clamp=function(o){return arguments.length?(e.clamp(o),i):e.clamp()},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return MA(e.domain(),t).round(r).clamp(e.clamp()).unknown(n)},er.apply(i,arguments),mn(i)}function DA(){var e=[],t=[],r=[],n;function i(){var s=0,a=Math.max(1,t.length);for(r=new Array(a-1);++s<a;)r[s-1]=yQ(e,s/a);return o}function o(s){return s==null||isNaN(s=+s)?n:t[Oa(r,s)]}return o.invertExtent=function(s){var a=t.indexOf(s);return a<0?[NaN,NaN]:[a>0?r[a-1]:e[0],a<r.length?r[a]:e[e.length-1]]},o.domain=function(s){if(!arguments.length)return e.slice();e=[];for(let a of s)a!=null&&!isNaN(a=+a)&&e.push(a);return e.sort(an),i()},o.range=function(s){return arguments.length?(t=Array.from(s),i()):t.slice()},o.unknown=function(s){return arguments.length?(n=s,o):n},o.quantiles=function(){return r.slice()},o.copy=function(){return DA().domain(e).range(t).unknown(n)},er.apply(o,arguments)}function kA(){var e=0,t=1,r=1,n=[.5],i=[0,1],o;function s(l){return l!=null&&l<=l?i[Oa(n,l,0,r)]:o}function a(){var l=-1;for(n=new Array(r);++l<r;)n[l]=((l+1)*t-(l-r)*e)/(r+1);return s}return s.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,a()):[e,t]},s.range=function(l){return arguments.length?(r=(i=Array.from(l)).length-1,a()):i.slice()},s.invertExtent=function(l){var c=i.indexOf(l);return c<0?[NaN,NaN]:c<1?[e,n[0]]:c>=r?[n[r-1],t]:[n[c-1],n[c]]},s.unknown=function(l){return arguments.length&&(o=l),s},s.thresholds=function(){return n.slice()},s.copy=function(){return kA().domain([e,t]).range(i).unknown(o)},er.apply(mn(s),arguments)}function IA(){var e=[.5],t=[0,1],r,n=1;function i(o){return o!=null&&o<=o?t[Oa(e,o,0,n)]:r}return i.domain=function(o){return arguments.length?(e=Array.from(o),n=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(o){return arguments.length?(t=Array.from(o),n=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(o){var s=t.indexOf(o);return[e[s-1],e[s]]},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return IA().domain(e).range(t).unknown(r)},er.apply(i,arguments)}const qd=new Date,Yd=new Date;function rt(e,t,r,n){function i(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return i.floor=o=>(e(o=new Date(+o)),o),i.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),i.round=o=>{const s=i(o),a=i.ceil(o);return o-s<a-o?s:a},i.offset=(o,s)=>(t(o=new Date(+o),s==null?1:Math.floor(s)),o),i.range=(o,s,a)=>{const l=[];if(o=i.ceil(o),a=a==null?1:Math.floor(a),!(o<s)||!(a>0))return l;let c;do l.push(c=new Date(+o)),t(o,a),e(o);while(c<o&&o<s);return l},i.filter=o=>rt(s=>{if(s>=s)for(;e(s),!o(s);)s.setTime(s-1)},(s,a)=>{if(s>=s)if(a<0)for(;++a<=0;)for(;t(s,-1),!o(s););else for(;--a>=0;)for(;t(s,1),!o(s););}),r&&(i.count=(o,s)=>(qd.setTime(+o),Yd.setTime(+s),e(qd),e(Yd),Math.floor(r(qd,Yd))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(n?s=>n(s)%o===0:s=>i.count(0,s)%o===0):i)),i}const mc=rt(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);mc.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?rt(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):mc);mc.range;const Ir=1e3,qt=Ir*60,_r=qt*60,Hr=_r*24,fm=Hr*7,Sb=Hr*30,Jd=Hr*365,Fn=rt(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Ir)},(e,t)=>(t-e)/Ir,e=>e.getUTCSeconds());Fn.range;const gm=rt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ir)},(e,t)=>{e.setTime(+e+t*qt)},(e,t)=>(t-e)/qt,e=>e.getMinutes());gm.range;const pm=rt(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*qt)},(e,t)=>(t-e)/qt,e=>e.getUTCMinutes());pm.range;const mm=rt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ir-e.getMinutes()*qt)},(e,t)=>{e.setTime(+e+t*_r)},(e,t)=>(t-e)/_r,e=>e.getHours());mm.range;const vm=rt(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*_r)},(e,t)=>(t-e)/_r,e=>e.getUTCHours());vm.range;const ka=rt(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*qt)/Hr,e=>e.getDate()-1);ka.range;const Ou=rt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Hr,e=>e.getUTCDate()-1);Ou.range;const _A=rt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Hr,e=>Math.floor(e/Hr));_A.range;function si(e){return rt(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,r)=>{t.setDate(t.getDate()+r*7)},(t,r)=>(r-t-(r.getTimezoneOffset()-t.getTimezoneOffset())*qt)/fm)}const Mu=si(0),vc=si(1),gee=si(2),pee=si(3),Vi=si(4),mee=si(5),vee=si(6);Mu.range;vc.range;gee.range;pee.range;Vi.range;mee.range;vee.range;function ai(e){return rt(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCDate(t.getUTCDate()+r*7)},(t,r)=>(r-t)/fm)}const Du=ai(0),yc=ai(1),yee=ai(2),bee=ai(3),Ui=ai(4),Cee=ai(5),wee=ai(6);Du.range;yc.range;yee.range;bee.range;Ui.range;Cee.range;wee.range;const ym=rt(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());ym.range;const bm=rt(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());bm.range;const Gr=rt(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());Gr.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:rt(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,r)=>{t.setFullYear(t.getFullYear()+r*e)});Gr.range;const Wr=rt(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());Wr.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:rt(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCFullYear(t.getUTCFullYear()+r*e)});Wr.range;function LA(e,t,r,n,i,o){const s=[[Fn,1,Ir],[Fn,5,5*Ir],[Fn,15,15*Ir],[Fn,30,30*Ir],[o,1,qt],[o,5,5*qt],[o,15,15*qt],[o,30,30*qt],[i,1,_r],[i,3,3*_r],[i,6,6*_r],[i,12,12*_r],[n,1,Hr],[n,2,2*Hr],[r,1,fm],[t,1,Sb],[t,3,3*Sb],[e,1,Jd]];function a(c,u,d){const h=u<c;h&&([c,u]=[u,c]);const f=d&&typeof d.range=="function"?d:l(c,u,d),g=f?f.range(c,+u+1):[];return h?g.reverse():g}function l(c,u,d){const h=Math.abs(u-c)/d,f=tm(([,,p])=>p).right(s,h);if(f===s.length)return e.every(Af(c/Jd,u/Jd,d));if(f===0)return mc.every(Math.max(Af(c,u,d),1));const[g,m]=s[h/s[f-1][2]<s[f][2]/h?f-1:f];return g.every(m)}return[a,l]}const[See,xee]=LA(Wr,bm,Du,_A,vm,pm),[Aee,Pee]=LA(Gr,ym,Mu,ka,mm,gm);function Xd(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function Zd(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function Vo(e,t,r){return{y:e,m:t,d:r,H:0,M:0,S:0,L:0}}function Ree(e){var t=e.dateTime,r=e.date,n=e.time,i=e.periods,o=e.days,s=e.shortDays,a=e.months,l=e.shortMonths,c=Uo(i),u=Ko(i),d=Uo(o),h=Ko(o),f=Uo(s),g=Ko(s),m=Uo(a),p=Ko(a),y=Uo(l),w=Ko(l),b={a:N,A:z,b:W,B:D,c:null,d:Tb,e:Tb,f:Yee,g:ote,G:ate,H:Uee,I:Kee,j:qee,L:BA,m:Jee,M:Xee,p:L,q:$,Q:Mb,s:Db,S:Zee,u:Qee,U:ete,V:tte,w:rte,W:nte,x:null,X:null,y:ite,Y:ste,Z:lte,"%":Ob},x={a:H,A:V,b:X,B:Y,c:null,d:Fb,e:Fb,f:hte,g:Ste,G:Ate,H:cte,I:ute,j:dte,L:NA,m:fte,M:gte,p:re,q:oe,Q:Mb,s:Db,S:pte,u:mte,U:vte,V:yte,w:bte,W:Cte,x:null,X:null,y:wte,Y:xte,Z:Pte,"%":Ob},C={a:O,A:R,b:T,B:F,c:I,d:Rb,e:Rb,f:Gee,g:Pb,G:Ab,H:Eb,I:Eb,j:zee,L:Hee,m:Bee,M:Nee,p:E,q:Lee,Q:jee,s:Vee,S:$ee,u:Mee,U:Dee,V:kee,w:Oee,W:Iee,x:k,X:B,y:Pb,Y:Ab,Z:_ee,"%":Wee};b.x=S(r,b),b.X=S(n,b),b.c=S(t,b),x.x=S(r,x),x.X=S(n,x),x.c=S(t,x);function S(K,J){return function(te){var _=[],ne=-1,U=0,ce=K.length,me,ae,Pe;for(te instanceof Date||(te=new Date(+te));++ne<ce;)K.charCodeAt(ne)===37&&(_.push(K.slice(U,ne)),(ae=xb[me=K.charAt(++ne)])!=null?me=K.charAt(++ne):ae=me==="e"?" ":"0",(Pe=J[me])&&(me=Pe(te,ae)),_.push(me),U=ne+1);return _.push(K.slice(U,ne)),_.join("")}}function A(K,J){return function(te){var _=Vo(1900,void 0,1),ne=P(_,K,te+="",0),U,ce;if(ne!=te.length)return null;if("Q"in _)return new Date(_.Q);if("s"in _)return new Date(_.s*1e3+("L"in _?_.L:0));if(J&&!("Z"in _)&&(_.Z=0),"p"in _&&(_.H=_.H%12+_.p*12),_.m===void 0&&(_.m="q"in _?_.q:0),"V"in _){if(_.V<1||_.V>53)return null;"w"in _||(_.w=1),"Z"in _?(U=Zd(Vo(_.y,0,1)),ce=U.getUTCDay(),U=ce>4||ce===0?yc.ceil(U):yc(U),U=Ou.offset(U,(_.V-1)*7),_.y=U.getUTCFullYear(),_.m=U.getUTCMonth(),_.d=U.getUTCDate()+(_.w+6)%7):(U=Xd(Vo(_.y,0,1)),ce=U.getDay(),U=ce>4||ce===0?vc.ceil(U):vc(U),U=ka.offset(U,(_.V-1)*7),_.y=U.getFullYear(),_.m=U.getMonth(),_.d=U.getDate()+(_.w+6)%7)}else("W"in _||"U"in _)&&("w"in _||(_.w="u"in _?_.u%7:"W"in _?1:0),ce="Z"in _?Zd(Vo(_.y,0,1)).getUTCDay():Xd(Vo(_.y,0,1)).getDay(),_.m=0,_.d="W"in _?(_.w+6)%7+_.W*7-(ce+5)%7:_.w+_.U*7-(ce+6)%7);return"Z"in _?(_.H+=_.Z/100|0,_.M+=_.Z%100,Zd(_)):Xd(_)}}function P(K,J,te,_){for(var ne=0,U=J.length,ce=te.length,me,ae;ne<U;){if(_>=ce)return-1;if(me=J.charCodeAt(ne++),me===37){if(me=J.charAt(ne++),ae=C[me in xb?J.charAt(ne++):me],!ae||(_=ae(K,te,_))<0)return-1}else if(me!=te.charCodeAt(_++))return-1}return _}function E(K,J,te){var _=c.exec(J.slice(te));return _?(K.p=u.get(_[0].toLowerCase()),te+_[0].length):-1}function O(K,J,te){var _=f.exec(J.slice(te));return _?(K.w=g.get(_[0].toLowerCase()),te+_[0].length):-1}function R(K,J,te){var _=d.exec(J.slice(te));return _?(K.w=h.get(_[0].toLowerCase()),te+_[0].length):-1}function T(K,J,te){var _=y.exec(J.slice(te));return _?(K.m=w.get(_[0].toLowerCase()),te+_[0].length):-1}function F(K,J,te){var _=m.exec(J.slice(te));return _?(K.m=p.get(_[0].toLowerCase()),te+_[0].length):-1}function I(K,J,te){return P(K,t,J,te)}function k(K,J,te){return P(K,r,J,te)}function B(K,J,te){return P(K,n,J,te)}function N(K){return s[K.getDay()]}function z(K){return o[K.getDay()]}function W(K){return l[K.getMonth()]}function D(K){return a[K.getMonth()]}function L(K){return i[+(K.getHours()>=12)]}function $(K){return 1+~~(K.getMonth()/3)}function H(K){return s[K.getUTCDay()]}function V(K){return o[K.getUTCDay()]}function X(K){return l[K.getUTCMonth()]}function Y(K){return a[K.getUTCMonth()]}function re(K){return i[+(K.getUTCHours()>=12)]}function oe(K){return 1+~~(K.getUTCMonth()/3)}return{format:function(K){var J=S(K+="",b);return J.toString=function(){return K},J},parse:function(K){var J=A(K+="",!1);return J.toString=function(){return K},J},utcFormat:function(K){var J=S(K+="",x);return J.toString=function(){return K},J},utcParse:function(K){var J=A(K+="",!0);return J.toString=function(){return K},J}}}var xb={"-":"",_:" ",0:"0"},ot=/^\s*\d+/,Eee=/^%/,Tee=/[\\^$*+?|[\]().{}]/g;function ye(e,t,r){var n=e<0?"-":"",i=(n?-e:e)+"",o=i.length;return n+(o<r?new Array(r-o+1).join(t)+i:i)}function Fee(e){return e.replace(Tee,"\\$&")}function Uo(e){return new RegExp("^(?:"+e.map(Fee).join("|")+")","i")}function Ko(e){return new Map(e.map((t,r)=>[t.toLowerCase(),r]))}function Oee(e,t,r){var n=ot.exec(t.slice(r,r+1));return n?(e.w=+n[0],r+n[0].length):-1}function Mee(e,t,r){var n=ot.exec(t.slice(r,r+1));return n?(e.u=+n[0],r+n[0].length):-1}function Dee(e,t,r){var n=ot.exec(t.slice(r,r+2));return n?(e.U=+n[0],r+n[0].length):-1}function kee(e,t,r){var n=ot.exec(t.slice(r,r+2));return n?(e.V=+n[0],r+n[0].length):-1}function Iee(e,t,r){var n=ot.exec(t.slice(r,r+2));return n?(e.W=+n[0],r+n[0].length):-1}function Ab(e,t,r){var n=ot.exec(t.slice(r,r+4));return n?(e.y=+n[0],r+n[0].length):-1}function Pb(e,t,r){var n=ot.exec(t.slice(r,r+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function _ee(e,t,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(r,r+6));return n?(e.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function Lee(e,t,r){var n=ot.exec(t.slice(r,r+1));return n?(e.q=n[0]*3-3,r+n[0].length):-1}function Bee(e,t,r){var n=ot.exec(t.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function Rb(e,t,r){var n=ot.exec(t.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function zee(e,t,r){var n=ot.exec(t.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function Eb(e,t,r){var n=ot.exec(t.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function Nee(e,t,r){var n=ot.exec(t.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function $ee(e,t,r){var n=ot.exec(t.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function Hee(e,t,r){var n=ot.exec(t.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function Gee(e,t,r){var n=ot.exec(t.slice(r,r+6));return n?(e.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function Wee(e,t,r){var n=Eee.exec(t.slice(r,r+1));return n?r+n[0].length:-1}function jee(e,t,r){var n=ot.exec(t.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function Vee(e,t,r){var n=ot.exec(t.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function Tb(e,t){return ye(e.getDate(),t,2)}function Uee(e,t){return ye(e.getHours(),t,2)}function Kee(e,t){return ye(e.getHours()%12||12,t,2)}function qee(e,t){return ye(1+ka.count(Gr(e),e),t,3)}function BA(e,t){return ye(e.getMilliseconds(),t,3)}function Yee(e,t){return BA(e,t)+"000"}function Jee(e,t){return ye(e.getMonth()+1,t,2)}function Xee(e,t){return ye(e.getMinutes(),t,2)}function Zee(e,t){return ye(e.getSeconds(),t,2)}function Qee(e){var t=e.getDay();return t===0?7:t}function ete(e,t){return ye(Mu.count(Gr(e)-1,e),t,2)}function zA(e){var t=e.getDay();return t>=4||t===0?Vi(e):Vi.ceil(e)}function tte(e,t){return e=zA(e),ye(Vi.count(Gr(e),e)+(Gr(e).getDay()===4),t,2)}function rte(e){return e.getDay()}function nte(e,t){return ye(vc.count(Gr(e)-1,e),t,2)}function ite(e,t){return ye(e.getFullYear()%100,t,2)}function ote(e,t){return e=zA(e),ye(e.getFullYear()%100,t,2)}function ste(e,t){return ye(e.getFullYear()%1e4,t,4)}function ate(e,t){var r=e.getDay();return e=r>=4||r===0?Vi(e):Vi.ceil(e),ye(e.getFullYear()%1e4,t,4)}function lte(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ye(t/60|0,"0",2)+ye(t%60,"0",2)}function Fb(e,t){return ye(e.getUTCDate(),t,2)}function cte(e,t){return ye(e.getUTCHours(),t,2)}function ute(e,t){return ye(e.getUTCHours()%12||12,t,2)}function dte(e,t){return ye(1+Ou.count(Wr(e),e),t,3)}function NA(e,t){return ye(e.getUTCMilliseconds(),t,3)}function hte(e,t){return NA(e,t)+"000"}function fte(e,t){return ye(e.getUTCMonth()+1,t,2)}function gte(e,t){return ye(e.getUTCMinutes(),t,2)}function pte(e,t){return ye(e.getUTCSeconds(),t,2)}function mte(e){var t=e.getUTCDay();return t===0?7:t}function vte(e,t){return ye(Du.count(Wr(e)-1,e),t,2)}function $A(e){var t=e.getUTCDay();return t>=4||t===0?Ui(e):Ui.ceil(e)}function yte(e,t){return e=$A(e),ye(Ui.count(Wr(e),e)+(Wr(e).getUTCDay()===4),t,2)}function bte(e){return e.getUTCDay()}function Cte(e,t){return ye(yc.count(Wr(e)-1,e),t,2)}function wte(e,t){return ye(e.getUTCFullYear()%100,t,2)}function Ste(e,t){return e=$A(e),ye(e.getUTCFullYear()%100,t,2)}function xte(e,t){return ye(e.getUTCFullYear()%1e4,t,4)}function Ate(e,t){var r=e.getUTCDay();return e=r>=4||r===0?Ui(e):Ui.ceil(e),ye(e.getUTCFullYear()%1e4,t,4)}function Pte(){return"+0000"}function Ob(){return"%"}function Mb(e){return+e}function Db(e){return Math.floor(+e/1e3)}var hi,HA,GA;Rte({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Rte(e){return hi=Ree(e),HA=hi.format,hi.parse,GA=hi.utcFormat,hi.utcParse,hi}function Ete(e){return new Date(e)}function Tte(e){return e instanceof Date?+e:+new Date(+e)}function Cm(e,t,r,n,i,o,s,a,l,c){var u=sm(),d=u.invert,h=u.domain,f=c(".%L"),g=c(":%S"),m=c("%I:%M"),p=c("%I %p"),y=c("%a %d"),w=c("%b %d"),b=c("%B"),x=c("%Y");function C(S){return(l(S)<S?f:a(S)<S?g:s(S)<S?m:o(S)<S?p:n(S)<S?i(S)<S?y:w:r(S)<S?b:x)(S)}return u.invert=function(S){return new Date(d(S))},u.domain=function(S){return arguments.length?h(Array.from(S,Tte)):h().map(Ete)},u.ticks=function(S){var A=h();return e(A[0],A[A.length-1],S??10)},u.tickFormat=function(S,A){return A==null?C:c(A)},u.nice=function(S){var A=h();return(!S||typeof S.range!="function")&&(S=t(A[0],A[A.length-1],S??10)),S?h(TA(A,S)):u},u.copy=function(){return Da(u,Cm(e,t,r,n,i,o,s,a,l,c))},u}function Fte(){return er.apply(Cm(Aee,Pee,Gr,ym,Mu,ka,mm,gm,Fn,HA).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function Ote(){return er.apply(Cm(See,xee,Wr,bm,Du,Ou,vm,pm,Fn,GA).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function ku(){var e=0,t=1,r,n,i,o,s=wt,a=!1,l;function c(d){return d==null||isNaN(d=+d)?l:s(i===0?.5:(d=(o(d)-r)*i,a?Math.max(0,Math.min(1,d)):d))}c.domain=function(d){return arguments.length?([e,t]=d,r=o(e=+e),n=o(t=+t),i=r===n?0:1/(n-r),c):[e,t]},c.clamp=function(d){return arguments.length?(a=!!d,c):a},c.interpolator=function(d){return arguments.length?(s=d,c):s};function u(d){return function(h){var f,g;return arguments.length?([f,g]=h,s=d(f,g),c):[s(0),s(1)]}}return c.range=u(Do),c.rangeRound=u(om),c.unknown=function(d){return arguments.length?(l=d,c):l},function(d){return o=d,r=d(e),n=d(t),i=r===n?0:1/(n-r),c}}function vn(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function WA(){var e=mn(ku()(wt));return e.copy=function(){return vn(e,WA())},Yr.apply(e,arguments)}function jA(){var e=cm(ku()).domain([1,10]);return e.copy=function(){return vn(e,jA()).base(e.base())},Yr.apply(e,arguments)}function VA(){var e=um(ku());return e.copy=function(){return vn(e,VA()).constant(e.constant())},Yr.apply(e,arguments)}function wm(){var e=dm(ku());return e.copy=function(){return vn(e,wm()).exponent(e.exponent())},Yr.apply(e,arguments)}function Mte(){return wm.apply(null,arguments).exponent(.5)}function UA(){var e=[],t=wt;function r(n){if(n!=null&&!isNaN(n=+n))return t((Oa(e,n,1)-1)/(e.length-1))}return r.domain=function(n){if(!arguments.length)return e.slice();e=[];for(let i of n)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(an),r},r.interpolator=function(n){return arguments.length?(t=n,r):t},r.range=function(){return e.map((n,i)=>t(i/(e.length-1)))},r.quantiles=function(n){return Array.from({length:n+1},(i,o)=>vQ(e,o/n))},r.copy=function(){return UA(t).domain(e)},Yr.apply(r,arguments)}function Iu(){var e=0,t=.5,r=1,n=1,i,o,s,a,l,c=wt,u,d=!1,h;function f(m){return isNaN(m=+m)?h:(m=.5+((m=+u(m))-o)*(n*m<n*o?a:l),c(d?Math.max(0,Math.min(1,m)):m))}f.domain=function(m){return arguments.length?([e,t,r]=m,i=u(e=+e),o=u(t=+t),s=u(r=+r),a=i===o?0:.5/(o-i),l=o===s?0:.5/(s-o),n=o<i?-1:1,f):[e,t,r]},f.clamp=function(m){return arguments.length?(d=!!m,f):d},f.interpolator=function(m){return arguments.length?(c=m,f):c};function g(m){return function(p){var y,w,b;return arguments.length?([y,w,b]=p,c=WQ(m,[y,w,b]),f):[c(0),c(.5),c(1)]}}return f.range=g(Do),f.rangeRound=g(om),f.unknown=function(m){return arguments.length?(h=m,f):h},function(m){return u=m,i=m(e),o=m(t),s=m(r),a=i===o?0:.5/(o-i),l=o===s?0:.5/(s-o),n=o<i?-1:1,f}}function KA(){var e=mn(Iu()(wt));return e.copy=function(){return vn(e,KA())},Yr.apply(e,arguments)}function qA(){var e=cm(Iu()).domain([.1,1,10]);return e.copy=function(){return vn(e,qA()).base(e.base())},Yr.apply(e,arguments)}function YA(){var e=um(Iu());return e.copy=function(){return vn(e,YA()).constant(e.constant())},Yr.apply(e,arguments)}function Sm(){var e=dm(Iu());return e.copy=function(){return vn(e,Sm()).exponent(e.exponent())},Yr.apply(e,arguments)}function Dte(){return Sm.apply(null,arguments).exponent(.5)}const kb=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:Hs,scaleDiverging:KA,scaleDivergingLog:qA,scaleDivergingPow:Sm,scaleDivergingSqrt:Dte,scaleDivergingSymlog:YA,scaleIdentity:EA,scaleImplicit:Pf,scaleLinear:pc,scaleLog:FA,scaleOrdinal:rm,scalePoint:ds,scalePow:hm,scaleQuantile:DA,scaleQuantize:kA,scaleRadial:MA,scaleSequential:WA,scaleSequentialLog:jA,scaleSequentialPow:wm,scaleSequentialQuantile:UA,scaleSequentialSqrt:Mte,scaleSequentialSymlog:VA,scaleSqrt:hee,scaleSymlog:OA,scaleThreshold:IA,scaleTime:Fte,scaleUtc:Ote,tickFormat:RA},Symbol.toStringTag,{value:"Module"}));var kte=So;function Ite(e,t,r){for(var n=-1,i=e.length;++n<i;){var o=e[n],s=t(o);if(s!=null&&(a===void 0?s===s&&!kte(s):r(s,a)))var a=s,l=o}return l}var JA=Ite;function _te(e,t){return e>t}var Lte=_te,Bte=JA,zte=Lte,Nte=Oo;function $te(e){return e&&e.length?Bte(e,Nte,zte):void 0}var Hte=$te;const tn=Le(Hte);function Gte(e,t){return e<t}var Wte=Gte,jte=JA,Vte=Wte,Ute=Oo;function Kte(e){return e&&e.length?jte(e,Ute,Vte):void 0}var qte=Kte;const _u=Le(qte);var Yte=Bp,Jte=Mo,Xte=sA,Zte=Mt;function Qte(e,t){var r=Zte(e)?Yte:Xte;return r(e,Jte(t))}var ere=Qte,tre=iA,rre=ere;function nre(e,t){return tre(rre(e,t),1)}var ire=nre;const ore=Le(ire);var sre=Jp;function are(e,t){return sre(e,t)}var lre=are;const Zn=Le(lre);var ko=1e9,cre={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},Am,Be=!0,Qt="[DecimalError] ",Nn=Qt+"Invalid argument: ",xm=Qt+"Exponent out of range: ",Io=Math.floor,Pn=Math.pow,ure=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,zt,nt=1e7,ke=7,XA=9007199254740991,bc=Io(XA/ke),ee={};ee.absoluteValue=ee.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};ee.comparedTo=ee.cmp=function(e){var t,r,n,i,o=this;if(e=new o.constructor(e),o.s!==e.s)return o.s||-e.s;if(o.e!==e.e)return o.e>e.e^o.s<0?1:-1;for(n=o.d.length,i=e.d.length,t=0,r=n<i?n:i;t<r;++t)if(o.d[t]!==e.d[t])return o.d[t]>e.d[t]^o.s<0?1:-1;return n===i?0:n>i^o.s<0?1:-1};ee.decimalPlaces=ee.dp=function(){var e=this,t=e.d.length-1,r=(t-e.e)*ke;if(t=e.d[t],t)for(;t%10==0;t/=10)r--;return r<0?0:r};ee.dividedBy=ee.div=function(e){return zr(this,new this.constructor(e))};ee.dividedToIntegerBy=ee.idiv=function(e){var t=this,r=t.constructor;return Te(zr(t,new r(e),0,1),r.precision)};ee.equals=ee.eq=function(e){return!this.cmp(e)};ee.exponent=function(){return Ze(this)};ee.greaterThan=ee.gt=function(e){return this.cmp(e)>0};ee.greaterThanOrEqualTo=ee.gte=function(e){return this.cmp(e)>=0};ee.isInteger=ee.isint=function(){return this.e>this.d.length-2};ee.isNegative=ee.isneg=function(){return this.s<0};ee.isPositive=ee.ispos=function(){return this.s>0};ee.isZero=function(){return this.s===0};ee.lessThan=ee.lt=function(e){return this.cmp(e)<0};ee.lessThanOrEqualTo=ee.lte=function(e){return this.cmp(e)<1};ee.logarithm=ee.log=function(e){var t,r=this,n=r.constructor,i=n.precision,o=i+5;if(e===void 0)e=new n(10);else if(e=new n(e),e.s<1||e.eq(zt))throw Error(Qt+"NaN");if(r.s<1)throw Error(Qt+(r.s?"NaN":"-Infinity"));return r.eq(zt)?new n(0):(Be=!1,t=zr(Us(r,o),Us(e,o),o),Be=!0,Te(t,i))};ee.minus=ee.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?eP(t,e):ZA(t,(e.s=-e.s,e))};ee.modulo=ee.mod=function(e){var t,r=this,n=r.constructor,i=n.precision;if(e=new n(e),!e.s)throw Error(Qt+"NaN");return r.s?(Be=!1,t=zr(r,e,0,1).times(e),Be=!0,r.minus(t)):Te(new n(r),i)};ee.naturalExponential=ee.exp=function(){return QA(this)};ee.naturalLogarithm=ee.ln=function(){return Us(this)};ee.negated=ee.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};ee.plus=ee.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?ZA(t,e):eP(t,(e.s=-e.s,e))};ee.precision=ee.sd=function(e){var t,r,n,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Nn+e);if(t=Ze(i)+1,n=i.d.length-1,r=n*ke+1,n=i.d[n],n){for(;n%10==0;n/=10)r--;for(n=i.d[0];n>=10;n/=10)r++}return e&&t>r?t:r};ee.squareRoot=ee.sqrt=function(){var e,t,r,n,i,o,s,a=this,l=a.constructor;if(a.s<1){if(!a.s)return new l(0);throw Error(Qt+"NaN")}for(e=Ze(a),Be=!1,i=Math.sqrt(+a),i==0||i==1/0?(t=mr(a.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=Io((e+1)/2)-(e<0||e%2),i==1/0?t="5e"+e:(t=i.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),n=new l(t)):n=new l(i.toString()),r=l.precision,i=s=r+3;;)if(o=n,n=o.plus(zr(a,o,s+2)).times(.5),mr(o.d).slice(0,s)===(t=mr(n.d)).slice(0,s)){if(t=t.slice(s-3,s+1),i==s&&t=="4999"){if(Te(o,r+1,0),o.times(o).eq(a)){n=o;break}}else if(t!="9999")break;s+=4}return Be=!0,Te(n,r)};ee.times=ee.mul=function(e){var t,r,n,i,o,s,a,l,c,u=this,d=u.constructor,h=u.d,f=(e=new d(e)).d;if(!u.s||!e.s)return new d(0);for(e.s*=u.s,r=u.e+e.e,l=h.length,c=f.length,l<c&&(o=h,h=f,f=o,s=l,l=c,c=s),o=[],s=l+c,n=s;n--;)o.push(0);for(n=c;--n>=0;){for(t=0,i=l+n;i>n;)a=o[i]+f[n]*h[i-n-1]+t,o[i--]=a%nt|0,t=a/nt|0;o[i]=(o[i]+t)%nt|0}for(;!o[--s];)o.pop();return t?++r:o.shift(),e.d=o,e.e=r,Be?Te(e,d.precision):e};ee.toDecimalPlaces=ee.todp=function(e,t){var r=this,n=r.constructor;return r=new n(r),e===void 0?r:(Ar(e,0,ko),t===void 0?t=n.rounding:Ar(t,0,8),Te(r,e+Ze(r)+1,t))};ee.toExponential=function(e,t){var r,n=this,i=n.constructor;return e===void 0?r=Qn(n,!0):(Ar(e,0,ko),t===void 0?t=i.rounding:Ar(t,0,8),n=Te(new i(n),e+1,t),r=Qn(n,!0,e+1)),r};ee.toFixed=function(e,t){var r,n,i=this,o=i.constructor;return e===void 0?Qn(i):(Ar(e,0,ko),t===void 0?t=o.rounding:Ar(t,0,8),n=Te(new o(i),e+Ze(i)+1,t),r=Qn(n.abs(),!1,e+Ze(n)+1),i.isneg()&&!i.isZero()?"-"+r:r)};ee.toInteger=ee.toint=function(){var e=this,t=e.constructor;return Te(new t(e),Ze(e)+1,t.rounding)};ee.toNumber=function(){return+this};ee.toPower=ee.pow=function(e){var t,r,n,i,o,s,a=this,l=a.constructor,c=12,u=+(e=new l(e));if(!e.s)return new l(zt);if(a=new l(a),!a.s){if(e.s<1)throw Error(Qt+"Infinity");return a}if(a.eq(zt))return a;if(n=l.precision,e.eq(zt))return Te(a,n);if(t=e.e,r=e.d.length-1,s=t>=r,o=a.s,s){if((r=u<0?-u:u)<=XA){for(i=new l(zt),t=Math.ceil(n/ke+4),Be=!1;r%2&&(i=i.times(a),_b(i.d,t)),r=Io(r/2),r!==0;)a=a.times(a),_b(a.d,t);return Be=!0,e.s<0?new l(zt).div(i):Te(i,n)}}else if(o<0)throw Error(Qt+"NaN");return o=o<0&&e.d[Math.max(t,r)]&1?-1:1,a.s=1,Be=!1,i=e.times(Us(a,n+c)),Be=!0,i=QA(i),i.s=o,i};ee.toPrecision=function(e,t){var r,n,i=this,o=i.constructor;return e===void 0?(r=Ze(i),n=Qn(i,r<=o.toExpNeg||r>=o.toExpPos)):(Ar(e,1,ko),t===void 0?t=o.rounding:Ar(t,0,8),i=Te(new o(i),e,t),r=Ze(i),n=Qn(i,e<=r||r<=o.toExpNeg,e)),n};ee.toSignificantDigits=ee.tosd=function(e,t){var r=this,n=r.constructor;return e===void 0?(e=n.precision,t=n.rounding):(Ar(e,1,ko),t===void 0?t=n.rounding:Ar(t,0,8)),Te(new n(r),e,t)};ee.toString=ee.valueOf=ee.val=ee.toJSON=ee[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=Ze(e),r=e.constructor;return Qn(e,t<=r.toExpNeg||t>=r.toExpPos)};function ZA(e,t){var r,n,i,o,s,a,l,c,u=e.constructor,d=u.precision;if(!e.s||!t.s)return t.s||(t=new u(e)),Be?Te(t,d):t;if(l=e.d,c=t.d,s=e.e,i=t.e,l=l.slice(),o=s-i,o){for(o<0?(n=l,o=-o,a=c.length):(n=c,i=s,a=l.length),s=Math.ceil(d/ke),a=s>a?s+1:a+1,o>a&&(o=a,n.length=1),n.reverse();o--;)n.push(0);n.reverse()}for(a=l.length,o=c.length,a-o<0&&(o=a,n=c,c=l,l=n),r=0;o;)r=(l[--o]=l[o]+c[o]+r)/nt|0,l[o]%=nt;for(r&&(l.unshift(r),++i),a=l.length;l[--a]==0;)l.pop();return t.d=l,t.e=i,Be?Te(t,d):t}function Ar(e,t,r){if(e!==~~e||e<t||e>r)throw Error(Nn+e)}function mr(e){var t,r,n,i=e.length-1,o="",s=e[0];if(i>0){for(o+=s,t=1;t<i;t++)n=e[t]+"",r=ke-n.length,r&&(o+=en(r)),o+=n;s=e[t],n=s+"",r=ke-n.length,r&&(o+=en(r))}else if(s===0)return"0";for(;s%10===0;)s/=10;return o+s}var zr=function(){function e(n,i){var o,s=0,a=n.length;for(n=n.slice();a--;)o=n[a]*i+s,n[a]=o%nt|0,s=o/nt|0;return s&&n.unshift(s),n}function t(n,i,o,s){var a,l;if(o!=s)l=o>s?1:-1;else for(a=l=0;a<o;a++)if(n[a]!=i[a]){l=n[a]>i[a]?1:-1;break}return l}function r(n,i,o){for(var s=0;o--;)n[o]-=s,s=n[o]<i[o]?1:0,n[o]=s*nt+n[o]-i[o];for(;!n[0]&&n.length>1;)n.shift()}return function(n,i,o,s){var a,l,c,u,d,h,f,g,m,p,y,w,b,x,C,S,A,P,E=n.constructor,O=n.s==i.s?1:-1,R=n.d,T=i.d;if(!n.s)return new E(n);if(!i.s)throw Error(Qt+"Division by zero");for(l=n.e-i.e,A=T.length,C=R.length,f=new E(O),g=f.d=[],c=0;T[c]==(R[c]||0);)++c;if(T[c]>(R[c]||0)&&--l,o==null?w=o=E.precision:s?w=o+(Ze(n)-Ze(i))+1:w=o,w<0)return new E(0);if(w=w/ke+2|0,c=0,A==1)for(u=0,T=T[0],w++;(c<C||u)&&w--;c++)b=u*nt+(R[c]||0),g[c]=b/T|0,u=b%T|0;else{for(u=nt/(T[0]+1)|0,u>1&&(T=e(T,u),R=e(R,u),A=T.length,C=R.length),x=A,m=R.slice(0,A),p=m.length;p<A;)m[p++]=0;P=T.slice(),P.unshift(0),S=T[0],T[1]>=nt/2&&++S;do u=0,a=t(T,m,A,p),a<0?(y=m[0],A!=p&&(y=y*nt+(m[1]||0)),u=y/S|0,u>1?(u>=nt&&(u=nt-1),d=e(T,u),h=d.length,p=m.length,a=t(d,m,h,p),a==1&&(u--,r(d,A<h?P:T,h))):(u==0&&(a=u=1),d=T.slice()),h=d.length,h<p&&d.unshift(0),r(m,d,p),a==-1&&(p=m.length,a=t(T,m,A,p),a<1&&(u++,r(m,A<p?P:T,p))),p=m.length):a===0&&(u++,m=[0]),g[c++]=u,a&&m[0]?m[p++]=R[x]||0:(m=[R[x]],p=1);while((x++<C||m[0]!==void 0)&&w--)}return g[0]||g.shift(),f.e=l,Te(f,s?o+Ze(f)+1:o)}}();function QA(e,t){var r,n,i,o,s,a,l=0,c=0,u=e.constructor,d=u.precision;if(Ze(e)>16)throw Error(xm+Ze(e));if(!e.s)return new u(zt);for(Be=!1,a=d,s=new u(.03125);e.abs().gte(.1);)e=e.times(s),c+=5;for(n=Math.log(Pn(2,c))/Math.LN10*2+5|0,a+=n,r=i=o=new u(zt),u.precision=a;;){if(i=Te(i.times(e),a),r=r.times(++l),s=o.plus(zr(i,r,a)),mr(s.d).slice(0,a)===mr(o.d).slice(0,a)){for(;c--;)o=Te(o.times(o),a);return u.precision=d,t==null?(Be=!0,Te(o,d)):o}o=s}}function Ze(e){for(var t=e.e*ke,r=e.d[0];r>=10;r/=10)t++;return t}function Qd(e,t,r){if(t>e.LN10.sd())throw Be=!0,r&&(e.precision=r),Error(Qt+"LN10 precision limit exceeded");return Te(new e(e.LN10),t)}function en(e){for(var t="";e--;)t+="0";return t}function Us(e,t){var r,n,i,o,s,a,l,c,u,d=1,h=10,f=e,g=f.d,m=f.constructor,p=m.precision;if(f.s<1)throw Error(Qt+(f.s?"NaN":"-Infinity"));if(f.eq(zt))return new m(0);if(t==null?(Be=!1,c=p):c=t,f.eq(10))return t==null&&(Be=!0),Qd(m,c);if(c+=h,m.precision=c,r=mr(g),n=r.charAt(0),o=Ze(f),Math.abs(o)<15e14){for(;n<7&&n!=1||n==1&&r.charAt(1)>3;)f=f.times(e),r=mr(f.d),n=r.charAt(0),d++;o=Ze(f),n>1?(f=new m("0."+r),o++):f=new m(n+"."+r.slice(1))}else return l=Qd(m,c+2,p).times(o+""),f=Us(new m(n+"."+r.slice(1)),c-h).plus(l),m.precision=p,t==null?(Be=!0,Te(f,p)):f;for(a=s=f=zr(f.minus(zt),f.plus(zt),c),u=Te(f.times(f),c),i=3;;){if(s=Te(s.times(u),c),l=a.plus(zr(s,new m(i),c)),mr(l.d).slice(0,c)===mr(a.d).slice(0,c))return a=a.times(2),o!==0&&(a=a.plus(Qd(m,c+2,p).times(o+""))),a=zr(a,new m(d),c),m.precision=p,t==null?(Be=!0,Te(a,p)):a;a=l,i+=2}}function Ib(e,t){var r,n,i;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(n=t.search(/e/i))>0?(r<0&&(r=n),r+=+t.slice(n+1),t=t.substring(0,n)):r<0&&(r=t.length),n=0;t.charCodeAt(n)===48;)++n;for(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(n,i),t){if(i-=n,r=r-n-1,e.e=Io(r/ke),e.d=[],n=(r+1)%ke,r<0&&(n+=ke),n<i){for(n&&e.d.push(+t.slice(0,n)),i-=ke;n<i;)e.d.push(+t.slice(n,n+=ke));t=t.slice(n),n=ke-t.length}else n-=i;for(;n--;)t+="0";if(e.d.push(+t),Be&&(e.e>bc||e.e<-bc))throw Error(xm+r)}else e.s=0,e.e=0,e.d=[0];return e}function Te(e,t,r){var n,i,o,s,a,l,c,u,d=e.d;for(s=1,o=d[0];o>=10;o/=10)s++;if(n=t-s,n<0)n+=ke,i=t,c=d[u=0];else{if(u=Math.ceil((n+1)/ke),o=d.length,u>=o)return e;for(c=o=d[u],s=1;o>=10;o/=10)s++;n%=ke,i=n-ke+s}if(r!==void 0&&(o=Pn(10,s-i-1),a=c/o%10|0,l=t<0||d[u+1]!==void 0||c%o,l=r<4?(a||l)&&(r==0||r==(e.s<0?3:2)):a>5||a==5&&(r==4||l||r==6&&(n>0?i>0?c/Pn(10,s-i):0:d[u-1])%10&1||r==(e.s<0?8:7))),t<1||!d[0])return l?(o=Ze(e),d.length=1,t=t-o-1,d[0]=Pn(10,(ke-t%ke)%ke),e.e=Io(-t/ke)||0):(d.length=1,d[0]=e.e=e.s=0),e;if(n==0?(d.length=u,o=1,u--):(d.length=u+1,o=Pn(10,ke-n),d[u]=i>0?(c/Pn(10,s-i)%Pn(10,i)|0)*o:0),l)for(;;)if(u==0){(d[0]+=o)==nt&&(d[0]=1,++e.e);break}else{if(d[u]+=o,d[u]!=nt)break;d[u--]=0,o=1}for(n=d.length;d[--n]===0;)d.pop();if(Be&&(e.e>bc||e.e<-bc))throw Error(xm+Ze(e));return e}function eP(e,t){var r,n,i,o,s,a,l,c,u,d,h=e.constructor,f=h.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new h(e),Be?Te(t,f):t;if(l=e.d,d=t.d,n=t.e,c=e.e,l=l.slice(),s=c-n,s){for(u=s<0,u?(r=l,s=-s,a=d.length):(r=d,n=c,a=l.length),i=Math.max(Math.ceil(f/ke),a)+2,s>i&&(s=i,r.length=1),r.reverse(),i=s;i--;)r.push(0);r.reverse()}else{for(i=l.length,a=d.length,u=i<a,u&&(a=i),i=0;i<a;i++)if(l[i]!=d[i]){u=l[i]<d[i];break}s=0}for(u&&(r=l,l=d,d=r,t.s=-t.s),a=l.length,i=d.length-a;i>0;--i)l[a++]=0;for(i=d.length;i>s;){if(l[--i]<d[i]){for(o=i;o&&l[--o]===0;)l[o]=nt-1;--l[o],l[i]+=nt}l[i]-=d[i]}for(;l[--a]===0;)l.pop();for(;l[0]===0;l.shift())--n;return l[0]?(t.d=l,t.e=n,Be?Te(t,f):t):new h(0)}function Qn(e,t,r){var n,i=Ze(e),o=mr(e.d),s=o.length;return t?(r&&(n=r-s)>0?o=o.charAt(0)+"."+o.slice(1)+en(n):s>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+en(-i-1)+o,r&&(n=r-s)>0&&(o+=en(n))):i>=s?(o+=en(i+1-s),r&&(n=r-i-1)>0&&(o=o+"."+en(n))):((n=i+1)<s&&(o=o.slice(0,n)+"."+o.slice(n)),r&&(n=r-s)>0&&(i+1===s&&(o+="."),o+=en(n))),e.s<0?"-"+o:o}function _b(e,t){if(e.length>t)return e.length=t,!0}function tP(e){var t,r,n;function i(o){var s=this;if(!(s instanceof i))return new i(o);if(s.constructor=i,o instanceof i){s.s=o.s,s.e=o.e,s.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(Nn+o);if(o>0)s.s=1;else if(o<0)o=-o,s.s=-1;else{s.s=0,s.e=0,s.d=[0];return}if(o===~~o&&o<1e7){s.e=0,s.d=[o];return}return Ib(s,o.toString())}else if(typeof o!="string")throw Error(Nn+o);if(o.charCodeAt(0)===45?(o=o.slice(1),s.s=-1):s.s=1,ure.test(o))Ib(s,o);else throw Error(Nn+o)}if(i.prototype=ee,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.clone=tP,i.config=i.set=dre,e===void 0&&(e={}),e)for(n=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<n.length;)e.hasOwnProperty(r=n[t++])||(e[r]=this[r]);return i.config(e),i}function dre(e){if(!e||typeof e!="object")throw Error(Qt+"Object expected");var t,r,n,i=["precision",1,ko,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<i.length;t+=3)if((n=e[r=i[t]])!==void 0)if(Io(n)===n&&n>=i[t+1]&&n<=i[t+2])this[r]=n;else throw Error(Nn+r+": "+n);if((n=e[r="LN10"])!==void 0)if(n==Math.LN10)this[r]=new this(n);else throw Error(Nn+r+": "+n);return this}var Am=tP(cre);zt=new Am(1);const Re=Am;function hre(e){return mre(e)||pre(e)||gre(e)||fre()}function fre(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
46
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function gre(e,t){if(e){if(typeof e=="string")return Ff(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Ff(e,t)}}function pre(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function mre(e){if(Array.isArray(e))return Ff(e)}function Ff(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var vre=function(t){return t},rP={},nP=function(t){return t===rP},Lb=function(t){return function r(){return arguments.length===0||arguments.length===1&&nP(arguments.length<=0?void 0:arguments[0])?r:t.apply(void 0,arguments)}},yre=function e(t,r){return t===1?r:Lb(function(){for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];var s=i.filter(function(a){return a!==rP}).length;return s>=t?r.apply(void 0,i):e(t-s,Lb(function(){for(var a=arguments.length,l=new Array(a),c=0;c<a;c++)l[c]=arguments[c];var u=i.map(function(d){return nP(d)?l.shift():d});return r.apply(void 0,hre(u).concat(l))}))})},Lu=function(t){return yre(t.length,t)},Of=function(t,r){for(var n=[],i=t;i<r;++i)n[i-t]=i;return n},bre=Lu(function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map(function(r){return t[r]}).map(e)}),Cre=function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];if(!r.length)return vre;var i=r.reverse(),o=i[0],s=i.slice(1);return function(){return s.reduce(function(a,l){return l(a)},o.apply(void 0,arguments))}},Mf=function(t){return Array.isArray(t)?t.reverse():t.split("").reverse.join("")},iP=function(t){var r=null,n=null;return function(){for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r&&o.every(function(a,l){return a===r[l]})||(r=o,n=t.apply(void 0,o)),n}};function wre(e){var t;return e===0?t=1:t=Math.floor(new Re(e).abs().log(10).toNumber())+1,t}function Sre(e,t,r){for(var n=new Re(e),i=0,o=[];n.lt(t)&&i<1e5;)o.push(n.toNumber()),n=n.add(r),i++;return o}var xre=Lu(function(e,t,r){var n=+e,i=+t;return n+r*(i-n)}),Are=Lu(function(e,t,r){var n=t-+e;return n=n||1/0,(r-e)/n}),Pre=Lu(function(e,t,r){var n=t-+e;return n=n||1/0,Math.max(0,Math.min(1,(r-e)/n))});const Bu={rangeStep:Sre,getDigitCount:wre,interpolateNumber:xre,uninterpolateNumber:Are,uninterpolateTruncation:Pre};function Df(e){return Tre(e)||Ere(e)||oP(e)||Rre()}function Rre(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
47
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ere(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function Tre(e){if(Array.isArray(e))return kf(e)}function Ks(e,t){return Mre(e)||Ore(e,t)||oP(e,t)||Fre()}function Fre(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
48
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function oP(e,t){if(e){if(typeof e=="string")return kf(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return kf(e,t)}}function kf(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Ore(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var r=[],n=!0,i=!1,o=void 0;try{for(var s=e[Symbol.iterator](),a;!(n=(a=s.next()).done)&&(r.push(a.value),!(t&&r.length===t));n=!0);}catch(l){i=!0,o=l}finally{try{!n&&s.return!=null&&s.return()}finally{if(i)throw o}}return r}}function Mre(e){if(Array.isArray(e))return e}function sP(e){var t=Ks(e,2),r=t[0],n=t[1],i=r,o=n;return r>n&&(i=n,o=r),[i,o]}function aP(e,t,r){if(e.lte(0))return new Re(0);var n=Bu.getDigitCount(e.toNumber()),i=new Re(10).pow(n),o=e.div(i),s=n!==1?.05:.1,a=new Re(Math.ceil(o.div(s).toNumber())).add(r).mul(s),l=a.mul(i);return t?l:new Re(Math.ceil(l))}function Dre(e,t,r){var n=1,i=new Re(e);if(!i.isint()&&r){var o=Math.abs(e);o<1?(n=new Re(10).pow(Bu.getDigitCount(e)-1),i=new Re(Math.floor(i.div(n).toNumber())).mul(n)):o>1&&(i=new Re(Math.floor(e)))}else e===0?i=new Re(Math.floor((t-1)/2)):r||(i=new Re(Math.floor(e)));var s=Math.floor((t-1)/2),a=Cre(bre(function(l){return i.add(new Re(l-s).mul(n)).toNumber()}),Of);return a(0,t)}function lP(e,t,r,n){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(r-1)))return{step:new Re(0),tickMin:new Re(0),tickMax:new Re(0)};var o=aP(new Re(t).sub(e).div(r-1),n,i),s;e<=0&&t>=0?s=new Re(0):(s=new Re(e).add(t).div(2),s=s.sub(new Re(s).mod(o)));var a=Math.ceil(s.sub(e).div(o).toNumber()),l=Math.ceil(new Re(t).sub(s).div(o).toNumber()),c=a+l+1;return c>r?lP(e,t,r,n,i+1):(c<r&&(l=t>0?l+(r-c):l,a=t>0?a:a+(r-c)),{step:o,tickMin:s.sub(new Re(a).mul(o)),tickMax:s.add(new Re(l).mul(o))})}function kre(e){var t=Ks(e,2),r=t[0],n=t[1],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,s=Math.max(i,2),a=sP([r,n]),l=Ks(a,2),c=l[0],u=l[1];if(c===-1/0||u===1/0){var d=u===1/0?[c].concat(Df(Of(0,i-1).map(function(){return 1/0}))):[].concat(Df(Of(0,i-1).map(function(){return-1/0})),[u]);return r>n?Mf(d):d}if(c===u)return Dre(c,i,o);var h=lP(c,u,s,o),f=h.step,g=h.tickMin,m=h.tickMax,p=Bu.rangeStep(g,m.add(new Re(.1).mul(f)),f);return r>n?Mf(p):p}function Ire(e,t){var r=Ks(e,2),n=r[0],i=r[1],o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,s=sP([n,i]),a=Ks(s,2),l=a[0],c=a[1];if(l===-1/0||c===1/0)return[n,i];if(l===c)return[l];var u=Math.max(t,2),d=aP(new Re(c).sub(l).div(u-1),o,0),h=[].concat(Df(Bu.rangeStep(new Re(l),new Re(c).sub(new Re(.99).mul(d)),d)),[c]);return n>i?Mf(h):h}var _re=iP(kre),Lre=iP(Ire),Bre=process.env.NODE_ENV==="production",eh="Invariant failed";function Pt(e,t){if(Bre)throw new Error(eh);var r=typeof t=="function"?t():t,n=r?"".concat(eh,": ").concat(r):eh;throw new Error(n)}var zre=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function Ki(e){"@babel/helpers - typeof";return Ki=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ki(e)}function Cc(){return Cc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Cc.apply(this,arguments)}function Nre(e,t){return Wre(e)||Gre(e,t)||Hre(e,t)||$re()}function $re(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
49
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Hre(e,t){if(e){if(typeof e=="string")return Bb(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Bb(e,t)}}function Bb(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Gre(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function Wre(e){if(Array.isArray(e))return e}function jre(e,t){if(e==null)return{};var r=Vre(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Vre(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Ure(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Kre(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,dP(n.key),n)}}function qre(e,t,r){return t&&Kre(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Yre(e,t,r){return t=wc(t),Jre(e,cP()?Reflect.construct(t,r||[],wc(e).constructor):t.apply(e,r))}function Jre(e,t){if(t&&(Ki(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Xre(e)}function Xre(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function cP(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(cP=function(){return!!e})()}function wc(e){return wc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},wc(e)}function Zre(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&If(e,t)}function If(e,t){return If=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},If(e,t)}function uP(e,t,r){return t=dP(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function dP(e){var t=Qre(e,"string");return Ki(t)=="symbol"?t:t+""}function Qre(e,t){if(Ki(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Ki(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var _o=function(e){function t(){return Ure(this,t),Yre(this,t,arguments)}return Zre(t,e),qre(t,[{key:"render",value:function(){var n=this.props,i=n.offset,o=n.layout,s=n.width,a=n.dataKey,l=n.data,c=n.dataPointFormatter,u=n.xAxis,d=n.yAxis,h=jre(n,zre),f=de(h,!1);this.props.direction==="x"&&u.type!=="number"&&(process.env.NODE_ENV!=="production"?Pt(!1,'ErrorBar requires Axis type property to be "number".'):Pt());var g=l.map(function(m){var p=c(m,a),y=p.x,w=p.y,b=p.value,x=p.errorVal;if(!x)return null;var C=[],S,A;if(Array.isArray(x)){var P=Nre(x,2);S=P[0],A=P[1]}else S=A=x;if(o==="vertical"){var E=u.scale,O=w+i,R=O+s,T=O-s,F=E(b-S),I=E(b+A);C.push({x1:I,y1:R,x2:I,y2:T}),C.push({x1:F,y1:O,x2:I,y2:O}),C.push({x1:F,y1:R,x2:F,y2:T})}else if(o==="horizontal"){var k=d.scale,B=y+i,N=B-s,z=B+s,W=k(b-S),D=k(b+A);C.push({x1:N,y1:D,x2:z,y2:D}),C.push({x1:B,y1:W,x2:B,y2:D}),C.push({x1:N,y1:W,x2:z,y2:W})}return v.createElement(be,Cc({className:"recharts-errorBar",key:"bar-".concat(C.map(function(L){return"".concat(L.x1,"-").concat(L.x2,"-").concat(L.y1,"-").concat(L.y2)}))},f),C.map(function(L){return v.createElement("line",Cc({},L,{key:"line-".concat(L.x1,"-").concat(L.x2,"-").concat(L.y1,"-").concat(L.y2)}))}))});return v.createElement(be,{className:"recharts-errorBars"},g)}}])}(v.Component);uP(_o,"defaultProps",{stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"});uP(_o,"displayName","ErrorBar");function qs(e){"@babel/helpers - typeof";return qs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},qs(e)}function zb(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Cn(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?zb(Object(r),!0).forEach(function(n){ene(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):zb(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function ene(e,t,r){return t=tne(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function tne(e){var t=rne(e,"string");return qs(t)=="symbol"?t:t+""}function rne(e,t){if(qs(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(qs(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var hP=function(t){var r=t.children,n=t.formattedGraphicalItems,i=t.legendWidth,o=t.legendContent,s=Lt(r,Oi);if(!s)return null;var a=Oi.defaultProps,l=a!==void 0?Cn(Cn({},a),s.props):{},c;return s.props&&s.props.payload?c=s.props&&s.props.payload:o==="children"?c=(n||[]).reduce(function(u,d){var h=d.item,f=d.props,g=f.sectors||f.data||[];return u.concat(g.map(function(m){return{type:s.props.iconType||h.props.legendType,value:m.name,color:m.fill,payload:m}}))},[]):c=(n||[]).map(function(u){var d=u.item,h=d.type.defaultProps,f=h!==void 0?Cn(Cn({},h),d.props):{},g=f.dataKey,m=f.name,p=f.legendType,y=f.hide;return{inactive:y,dataKey:g,type:l.iconType||p||"square",color:Pm(d),value:m||g,payload:f}}),Cn(Cn(Cn({},l),Oi.getWithHeight(s,i)),{},{payload:c,item:s})};function Ys(e){"@babel/helpers - typeof";return Ys=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ys(e)}function Nb(e){return sne(e)||one(e)||ine(e)||nne()}function nne(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
50
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ine(e,t){if(e){if(typeof e=="string")return _f(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return _f(e,t)}}function one(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function sne(e){if(Array.isArray(e))return _f(e)}function _f(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function $b(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ve(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?$b(Object(r),!0).forEach(function(n){Di(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):$b(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Di(e,t,r){return t=ane(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ane(e){var t=lne(e,"string");return Ys(t)=="symbol"?t:t+""}function lne(e,t){if(Ys(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Ys(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function tt(e,t,r){return ue(e)||ue(t)?r:et(t)?Yt(e,t,r):ge(t)?t(e):r}function hs(e,t,r,n){var i=ore(e,function(a){return tt(a,t)});if(r==="number"){var o=i.filter(function(a){return Z(a)||parseFloat(a)});return o.length?[_u(o),tn(o)]:[1/0,-1/0]}var s=n?i.filter(function(a){return!ue(a)}):i;return s.map(function(a){return et(a)||a instanceof Date?a:""})}var cne=function(t){var r,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,s=-1,a=(r=n==null?void 0:n.length)!==null&&r!==void 0?r:0;if(a<=1)return 0;if(o&&o.axisType==="angleAxis"&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var l=o.range,c=0;c<a;c++){var u=c>0?i[c-1].coordinate:i[a-1].coordinate,d=i[c].coordinate,h=c>=a-1?i[0].coordinate:i[c+1].coordinate,f=void 0;if(ar(d-u)!==ar(h-d)){var g=[];if(ar(h-d)===ar(l[1]-l[0])){f=h;var m=d+l[1]-l[0];g[0]=Math.min(m,(m+u)/2),g[1]=Math.max(m,(m+u)/2)}else{f=u;var p=h+l[1]-l[0];g[0]=Math.min(d,(p+d)/2),g[1]=Math.max(d,(p+d)/2)}var y=[Math.min(d,(f+d)/2),Math.max(d,(f+d)/2)];if(t>y[0]&&t<=y[1]||t>=g[0]&&t<=g[1]){s=i[c].index;break}}else{var w=Math.min(u,h),b=Math.max(u,h);if(t>(w+d)/2&&t<=(b+d)/2){s=i[c].index;break}}}else for(var x=0;x<a;x++)if(x===0&&t<=(n[x].coordinate+n[x+1].coordinate)/2||x>0&&x<a-1&&t>(n[x].coordinate+n[x-1].coordinate)/2&&t<=(n[x].coordinate+n[x+1].coordinate)/2||x===a-1&&t>(n[x].coordinate+n[x-1].coordinate)/2){s=n[x].index;break}return s},Pm=function(t){var r,n=t,i=n.type.displayName,o=(r=t.type)!==null&&r!==void 0&&r.defaultProps?Ve(Ve({},t.type.defaultProps),t.props):t.props,s=o.stroke,a=o.fill,l;switch(i){case"Line":l=s;break;case"Area":case"Radar":l=s&&s!=="none"?s:a;break;default:l=a;break}return l},une=function(t){var r=t.barSize,n=t.totalSize,i=t.stackGroups,o=i===void 0?{}:i;if(!o)return{};for(var s={},a=Object.keys(o),l=0,c=a.length;l<c;l++)for(var u=o[a[l]].stackGroups,d=Object.keys(u),h=0,f=d.length;h<f;h++){var g=u[d[h]],m=g.items,p=g.cateAxisId,y=m.filter(function(A){return sn(A.type).indexOf("Bar")>=0});if(y&&y.length){var w=y[0].type.defaultProps,b=w!==void 0?Ve(Ve({},w),y[0].props):y[0].props,x=b.barSize,C=b[p];s[C]||(s[C]=[]);var S=ue(x)?r:x;s[C].push({item:y[0],stackList:y.slice(1),barSize:ue(S)?void 0:Xn(S,n,0)})}}return s},dne=function(t){var r=t.barGap,n=t.barCategoryGap,i=t.bandSize,o=t.sizeList,s=o===void 0?[]:o,a=t.maxBarSize,l=s.length;if(l<1)return null;var c=Xn(r,i,0,!0),u,d=[];if(s[0].barSize===+s[0].barSize){var h=!1,f=i/l,g=s.reduce(function(x,C){return x+C.barSize||0},0);g+=(l-1)*c,g>=i&&(g-=(l-1)*c,c=0),g>=i&&f>0&&(h=!0,f*=.9,g=l*f);var m=(i-g)/2>>0,p={offset:m-c,size:0};u=s.reduce(function(x,C){var S={item:C.item,position:{offset:p.offset+p.size+c,size:h?f:C.barSize}},A=[].concat(Nb(x),[S]);return p=A[A.length-1].position,C.stackList&&C.stackList.length&&C.stackList.forEach(function(P){A.push({item:P,position:p})}),A},d)}else{var y=Xn(n,i,0,!0);i-2*y-(l-1)*c<=0&&(c=0);var w=(i-2*y-(l-1)*c)/l;w>1&&(w>>=0);var b=a===+a?Math.min(w,a):w;u=s.reduce(function(x,C,S){var A=[].concat(Nb(x),[{item:C.item,position:{offset:y+(w+c)*S+(w-b)/2,size:b}}]);return C.stackList&&C.stackList.length&&C.stackList.forEach(function(P){A.push({item:P,position:A[A.length-1].position})}),A},d)}return u},hne=function(t,r,n,i){var o=n.children,s=n.width,a=n.margin,l=s-(a.left||0)-(a.right||0),c=hP({children:o,legendWidth:l});if(c){var u=i||{},d=u.width,h=u.height,f=c.align,g=c.verticalAlign,m=c.layout;if((m==="vertical"||m==="horizontal"&&g==="middle")&&f!=="center"&&Z(t[f]))return Ve(Ve({},t),{},Di({},f,t[f]+(d||0)));if((m==="horizontal"||m==="vertical"&&f==="center")&&g!=="middle"&&Z(t[g]))return Ve(Ve({},t),{},Di({},g,t[g]+(h||0)))}return t},fne=function(t,r,n){return ue(r)?!0:t==="horizontal"?r==="yAxis":t==="vertical"||n==="x"?r==="xAxis":n==="y"?r==="yAxis":!0},fP=function(t,r,n,i,o){var s=r.props.children,a=Tt(s,_o).filter(function(c){return fne(i,o,c.props.direction)});if(a&&a.length){var l=a.map(function(c){return c.props.dataKey});return t.reduce(function(c,u){var d=tt(u,n);if(ue(d))return c;var h=Array.isArray(d)?[_u(d),tn(d)]:[d,d],f=l.reduce(function(g,m){var p=tt(u,m,0),y=h[0]-Math.abs(Array.isArray(p)?p[0]:p),w=h[1]+Math.abs(Array.isArray(p)?p[1]:p);return[Math.min(y,g[0]),Math.max(w,g[1])]},[1/0,-1/0]);return[Math.min(f[0],c[0]),Math.max(f[1],c[1])]},[1/0,-1/0])}return null},gne=function(t,r,n,i,o){var s=r.map(function(a){return fP(t,a,n,o,i)}).filter(function(a){return!ue(a)});return s&&s.length?s.reduce(function(a,l){return[Math.min(a[0],l[0]),Math.max(a[1],l[1])]},[1/0,-1/0]):null},gP=function(t,r,n,i,o){var s=r.map(function(l){var c=l.props.dataKey;return n==="number"&&c&&fP(t,l,c,i)||hs(t,c,n,o)});if(n==="number")return s.reduce(function(l,c){return[Math.min(l[0],c[0]),Math.max(l[1],c[1])]},[1/0,-1/0]);var a={};return s.reduce(function(l,c){for(var u=0,d=c.length;u<d;u++)a[c[u]]||(a[c[u]]=!0,l.push(c[u]));return l},[])},pP=function(t,r){return t==="horizontal"&&r==="xAxis"||t==="vertical"&&r==="yAxis"||t==="centric"&&r==="angleAxis"||t==="radial"&&r==="radiusAxis"},On=function(t,r,n){if(!t)return null;var i=t.scale,o=t.duplicateDomain,s=t.type,a=t.range,l=t.realScaleType==="scaleBand"?i.bandwidth()/2:2,c=(r||n)&&s==="category"&&i.bandwidth?i.bandwidth()/l:0;if(c=t.axisType==="angleAxis"&&(a==null?void 0:a.length)>=2?ar(a[0]-a[1])*2*c:c,r&&(t.ticks||t.niceTicks)){var u=(t.ticks||t.niceTicks).map(function(d){var h=o?o.indexOf(d):d;return{coordinate:i(h)+c,value:d,offset:c}});return u.filter(function(d){return!Eo(d.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(d,h){return{coordinate:i(d)+c,value:d,index:h,offset:c}}):i.ticks&&!n?i.ticks(t.tickCount).map(function(d){return{coordinate:i(d)+c,value:d,offset:c}}):i.domain().map(function(d,h){return{coordinate:i(d)+c,value:o?o[d]:d,index:h,offset:c}})},th=new WeakMap,rl=function(t,r){if(typeof r!="function")return t;th.has(t)||th.set(t,new WeakMap);var n=th.get(t);if(n.has(r))return n.get(r);var i=function(){t.apply(void 0,arguments),r.apply(void 0,arguments)};return n.set(r,i),i},pne=function(t,r,n){var i=t.scale,o=t.type,s=t.layout,a=t.axisType;if(i==="auto")return s==="radial"&&a==="radiusAxis"?{scale:Hs(),realScaleType:"band"}:s==="radial"&&a==="angleAxis"?{scale:pc(),realScaleType:"linear"}:o==="category"&&r&&(r.indexOf("LineChart")>=0||r.indexOf("AreaChart")>=0||r.indexOf("ComposedChart")>=0&&!n)?{scale:ds(),realScaleType:"point"}:o==="category"?{scale:Hs(),realScaleType:"band"}:{scale:pc(),realScaleType:"linear"};if(Jn(i)){var l="scale".concat(wu(i));return{scale:(kb[l]||ds)(),realScaleType:kb[l]?l:"point"}}return ge(i)?{scale:i}:{scale:ds(),realScaleType:"point"}},Hb=1e-4,mne=function(t){var r=t.domain();if(!(!r||r.length<=2)){var n=r.length,i=t.range(),o=Math.min(i[0],i[1])-Hb,s=Math.max(i[0],i[1])+Hb,a=t(r[0]),l=t(r[n-1]);(a<o||a>s||l<o||l>s)&&t.domain([r[0],r[n-1]])}},vne=function(t,r){if(!t)return null;for(var n=0,i=t.length;n<i;n++)if(t[n].item===r)return t[n].position;return null},yne=function(t,r){if(!r||r.length!==2||!Z(r[0])||!Z(r[1]))return t;var n=Math.min(r[0],r[1]),i=Math.max(r[0],r[1]),o=[t[0],t[1]];return(!Z(t[0])||t[0]<n)&&(o[0]=n),(!Z(t[1])||t[1]>i)&&(o[1]=i),o[0]>i&&(o[0]=i),o[1]<n&&(o[1]=n),o},bne=function(t){var r=t.length;if(!(r<=0))for(var n=0,i=t[0].length;n<i;++n)for(var o=0,s=0,a=0;a<r;++a){var l=Eo(t[a][n][1])?t[a][n][0]:t[a][n][1];l>=0?(t[a][n][0]=o,t[a][n][1]=o+l,o=t[a][n][1]):(t[a][n][0]=s,t[a][n][1]=s+l,s=t[a][n][1])}},Cne=function(t){var r=t.length;if(!(r<=0))for(var n=0,i=t[0].length;n<i;++n)for(var o=0,s=0;s<r;++s){var a=Eo(t[s][n][1])?t[s][n][0]:t[s][n][1];a>=0?(t[s][n][0]=o,t[s][n][1]=o+a,o=t[s][n][1]):(t[s][n][0]=0,t[s][n][1]=0)}},wne={sign:bne,expand:GV,none:Ni,silhouette:WV,wiggle:jV,positive:Cne},Sne=function(t,r,n){var i=r.map(function(a){return a.props.dataKey}),o=wne[n],s=HV().keys(i).value(function(a,l){return+tt(a,l,0)}).order(sf).offset(o);return s(t)},xne=function(t,r,n,i,o,s){if(!t)return null;var a=s?r.reverse():r,l={},c=a.reduce(function(d,h){var f,g=(f=h.type)!==null&&f!==void 0&&f.defaultProps?Ve(Ve({},h.type.defaultProps),h.props):h.props,m=g.stackId,p=g.hide;if(p)return d;var y=g[n],w=d[y]||{hasStack:!1,stackGroups:{}};if(et(m)){var b=w.stackGroups[m]||{numericAxisId:n,cateAxisId:i,items:[]};b.items.push(h),w.hasStack=!0,w.stackGroups[m]=b}else w.stackGroups[oi("_stackId_")]={numericAxisId:n,cateAxisId:i,items:[h]};return Ve(Ve({},d),{},Di({},y,w))},l),u={};return Object.keys(c).reduce(function(d,h){var f=c[h];if(f.hasStack){var g={};f.stackGroups=Object.keys(f.stackGroups).reduce(function(m,p){var y=f.stackGroups[p];return Ve(Ve({},m),{},Di({},p,{numericAxisId:n,cateAxisId:i,items:y.items,stackedData:Sne(t,y.items,o)}))},g)}return Ve(Ve({},d),{},Di({},h,f))},u)},Ane=function(t,r){var n=r.realScaleType,i=r.type,o=r.tickCount,s=r.originalDomain,a=r.allowDecimals,l=n||r.scale;if(l!=="auto"&&l!=="linear")return null;if(o&&i==="number"&&s&&(s[0]==="auto"||s[1]==="auto")){var c=t.domain();if(!c.length)return null;var u=_re(c,o,a);return t.domain([_u(u),tn(u)]),{niceTicks:u}}if(o&&i==="number"){var d=t.domain(),h=Lre(d,o,a);return{niceTicks:h}}return null};function qi(e){var t=e.axis,r=e.ticks,n=e.bandSize,i=e.entry,o=e.index,s=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!ue(i[t.dataKey])){var a=Kl(r,"value",i[t.dataKey]);if(a)return a.coordinate+n/2}return r[o]?r[o].coordinate+n/2:null}var l=tt(i,ue(s)?t.dataKey:s);return ue(l)?null:t.scale(l)}var Gb=function(t){var r=t.axis,n=t.ticks,i=t.offset,o=t.bandSize,s=t.entry,a=t.index;if(r.type==="category")return n[a]?n[a].coordinate+i:null;var l=tt(s,r.dataKey,r.domain[a]);return ue(l)?null:r.scale(l)-o/2+i},Pne=function(t){var r=t.numericAxis,n=r.scale.domain();if(r.type==="number"){var i=Math.min(n[0],n[1]),o=Math.max(n[0],n[1]);return i<=0&&o>=0?0:o<0?o:i}return n[0]},Rne=function(t,r){var n,i=(n=t.type)!==null&&n!==void 0&&n.defaultProps?Ve(Ve({},t.type.defaultProps),t.props):t.props,o=i.stackId;if(et(o)){var s=r[o];if(s){var a=s.items.indexOf(t);return a>=0?s.stackedData[a]:null}}return null},Ene=function(t){return t.reduce(function(r,n){return[_u(n.concat([r[0]]).filter(Z)),tn(n.concat([r[1]]).filter(Z))]},[1/0,-1/0])},mP=function(t,r,n){return Object.keys(t).reduce(function(i,o){var s=t[o],a=s.stackedData,l=a.reduce(function(c,u){var d=Ene(u.slice(r,n+1));return[Math.min(c[0],d[0]),Math.max(c[1],d[1])]},[1/0,-1/0]);return[Math.min(l[0],i[0]),Math.max(l[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},Wb=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,jb=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Lf=function(t,r,n){if(ge(t))return t(r,n);if(!Array.isArray(t))return r;var i=[];if(Z(t[0]))i[0]=n?t[0]:Math.min(t[0],r[0]);else if(Wb.test(t[0])){var o=+Wb.exec(t[0])[1];i[0]=r[0]-o}else ge(t[0])?i[0]=t[0](r[0]):i[0]=r[0];if(Z(t[1]))i[1]=n?t[1]:Math.max(t[1],r[1]);else if(jb.test(t[1])){var s=+jb.exec(t[1])[1];i[1]=r[1]+s}else ge(t[1])?i[1]=t[1](r[1]):i[1]=r[1];return i},Sc=function(t,r,n){if(t&&t.scale&&t.scale.bandwidth){var i=t.scale.bandwidth();if(!n||i>0)return i}if(t&&r&&r.length>=2){for(var o=Zp(r,function(d){return d.coordinate}),s=1/0,a=1,l=o.length;a<l;a++){var c=o[a],u=o[a-1];s=Math.min((c.coordinate||0)-(u.coordinate||0),s)}return s===1/0?0:s}return n?void 0:0},Vb=function(t,r,n){return!t||!t.length||Zn(t,Yt(n,"type.defaultProps.domain"))?r:t},vP=function(t,r){var n=t.type.defaultProps?Ve(Ve({},t.type.defaultProps),t.props):t.props,i=n.dataKey,o=n.name,s=n.unit,a=n.formatter,l=n.tooltipType,c=n.chartType,u=n.hide;return Ve(Ve({},de(t,!1)),{},{dataKey:i,unit:s,formatter:a,name:o||i,color:Pm(t),value:tt(r,i),type:l,payload:r,chartType:c,hide:u})};function Js(e){"@babel/helpers - typeof";return Js=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Js(e)}function Ub(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Kb(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Ub(Object(r),!0).forEach(function(n){Tne(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ub(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Tne(e,t,r){return t=Fne(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Fne(e){var t=One(e,"string");return Js(t)=="symbol"?t:t+""}function One(e,t){if(Js(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Js(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var xc=Math.PI/180,Mne=function(t){return t*180/Math.PI},at=function(t,r,n,i){return{x:t+Math.cos(-xc*i)*n,y:r+Math.sin(-xc*i)*n}},Dne=function(t,r){var n=t.x,i=t.y,o=r.x,s=r.y;return Math.sqrt(Math.pow(n-o,2)+Math.pow(i-s,2))},kne=function(t,r){var n=t.x,i=t.y,o=r.cx,s=r.cy,a=Dne({x:n,y:i},{x:o,y:s});if(a<=0)return{radius:a};var l=(n-o)/a,c=Math.acos(l);return i>s&&(c=2*Math.PI-c),{radius:a,angle:Mne(c),angleInRadian:c}},Ine=function(t){var r=t.startAngle,n=t.endAngle,i=Math.floor(r/360),o=Math.floor(n/360),s=Math.min(i,o);return{startAngle:r-s*360,endAngle:n-s*360}},_ne=function(t,r){var n=r.startAngle,i=r.endAngle,o=Math.floor(n/360),s=Math.floor(i/360),a=Math.min(o,s);return t+a*360},qb=function(t,r){var n=t.x,i=t.y,o=kne({x:n,y:i},r),s=o.radius,a=o.angle,l=r.innerRadius,c=r.outerRadius;if(s<l||s>c)return!1;if(s===0)return!0;var u=Ine(r),d=u.startAngle,h=u.endAngle,f=a,g;if(d<=h){for(;f>h;)f-=360;for(;f<d;)f+=360;g=f>=d&&f<=h}else{for(;f>d;)f-=360;for(;f<h;)f+=360;g=f>=h&&f<=d}return g?Kb(Kb({},r),{},{radius:s,angle:_ne(f,r)}):null};function Xs(e){"@babel/helpers - typeof";return Xs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Xs(e)}var Lne=["offset"];function Bne(e){return Hne(e)||$ne(e)||Nne(e)||zne()}function zne(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
51
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Nne(e,t){if(e){if(typeof e=="string")return Bf(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Bf(e,t)}}function $ne(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Hne(e){if(Array.isArray(e))return Bf(e)}function Bf(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Gne(e,t){if(e==null)return{};var r=Wne(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Wne(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Yb(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Qe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Yb(Object(r),!0).forEach(function(n){jne(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Yb(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function jne(e,t,r){return t=Vne(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Vne(e){var t=Une(e,"string");return Xs(t)=="symbol"?t:t+""}function Une(e,t){if(Xs(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Xs(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Zs(){return Zs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Zs.apply(this,arguments)}var Kne=function(t){var r=t.value,n=t.formatter,i=ue(t.children)?r:t.children;return ge(n)?n(i):i},qne=function(t,r){var n=ar(r-t),i=Math.min(Math.abs(r-t),360);return n*i},Yne=function(t,r,n){var i=t.position,o=t.viewBox,s=t.offset,a=t.className,l=o,c=l.cx,u=l.cy,d=l.innerRadius,h=l.outerRadius,f=l.startAngle,g=l.endAngle,m=l.clockWise,p=(d+h)/2,y=qne(f,g),w=y>=0?1:-1,b,x;i==="insideStart"?(b=f+w*s,x=m):i==="insideEnd"?(b=g-w*s,x=!m):i==="end"&&(b=g+w*s,x=m),x=y<=0?x:!x;var C=at(c,u,p,b),S=at(c,u,p,b+(x?1:-1)*359),A="M".concat(C.x,",").concat(C.y,`
52
+ A`).concat(p,",").concat(p,",0,1,").concat(x?0:1,`,
53
+ `).concat(S.x,",").concat(S.y),P=ue(t.id)?oi("recharts-radial-line-"):t.id;return v.createElement("text",Zs({},n,{dominantBaseline:"central",className:ve("recharts-radial-bar-label",a)}),v.createElement("defs",null,v.createElement("path",{id:P,d:A})),v.createElement("textPath",{xlinkHref:"#".concat(P)},r))},Jne=function(t){var r=t.viewBox,n=t.offset,i=t.position,o=r,s=o.cx,a=o.cy,l=o.innerRadius,c=o.outerRadius,u=o.startAngle,d=o.endAngle,h=(u+d)/2;if(i==="outside"){var f=at(s,a,c+n,h),g=f.x,m=f.y;return{x:g,y:m,textAnchor:g>=s?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:s,y:a,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:s,y:a,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:s,y:a,textAnchor:"middle",verticalAnchor:"end"};var p=(l+c)/2,y=at(s,a,p,h),w=y.x,b=y.y;return{x:w,y:b,textAnchor:"middle",verticalAnchor:"middle"}},Xne=function(t){var r=t.viewBox,n=t.parentViewBox,i=t.offset,o=t.position,s=r,a=s.x,l=s.y,c=s.width,u=s.height,d=u>=0?1:-1,h=d*i,f=d>0?"end":"start",g=d>0?"start":"end",m=c>=0?1:-1,p=m*i,y=m>0?"end":"start",w=m>0?"start":"end";if(o==="top"){var b={x:a+c/2,y:l-d*i,textAnchor:"middle",verticalAnchor:f};return Qe(Qe({},b),n?{height:Math.max(l-n.y,0),width:c}:{})}if(o==="bottom"){var x={x:a+c/2,y:l+u+h,textAnchor:"middle",verticalAnchor:g};return Qe(Qe({},x),n?{height:Math.max(n.y+n.height-(l+u),0),width:c}:{})}if(o==="left"){var C={x:a-p,y:l+u/2,textAnchor:y,verticalAnchor:"middle"};return Qe(Qe({},C),n?{width:Math.max(C.x-n.x,0),height:u}:{})}if(o==="right"){var S={x:a+c+p,y:l+u/2,textAnchor:w,verticalAnchor:"middle"};return Qe(Qe({},S),n?{width:Math.max(n.x+n.width-S.x,0),height:u}:{})}var A=n?{width:c,height:u}:{};return o==="insideLeft"?Qe({x:a+p,y:l+u/2,textAnchor:w,verticalAnchor:"middle"},A):o==="insideRight"?Qe({x:a+c-p,y:l+u/2,textAnchor:y,verticalAnchor:"middle"},A):o==="insideTop"?Qe({x:a+c/2,y:l+h,textAnchor:"middle",verticalAnchor:g},A):o==="insideBottom"?Qe({x:a+c/2,y:l+u-h,textAnchor:"middle",verticalAnchor:f},A):o==="insideTopLeft"?Qe({x:a+p,y:l+h,textAnchor:w,verticalAnchor:g},A):o==="insideTopRight"?Qe({x:a+c-p,y:l+h,textAnchor:y,verticalAnchor:g},A):o==="insideBottomLeft"?Qe({x:a+p,y:l+u-h,textAnchor:w,verticalAnchor:f},A):o==="insideBottomRight"?Qe({x:a+c-p,y:l+u-h,textAnchor:y,verticalAnchor:f},A):xo(o)&&(Z(o.x)||Kh(o.x))&&(Z(o.y)||Kh(o.y))?Qe({x:a+Xn(o.x,c),y:l+Xn(o.y,u),textAnchor:"end",verticalAnchor:"end"},A):Qe({x:a+c/2,y:l+u/2,textAnchor:"middle",verticalAnchor:"middle"},A)},Zne=function(t){return"cx"in t&&Z(t.cx)};function ft(e){var t=e.offset,r=t===void 0?5:t,n=Gne(e,Lne),i=Qe({offset:r},n),o=i.viewBox,s=i.position,a=i.value,l=i.children,c=i.content,u=i.className,d=u===void 0?"":u,h=i.textBreakAll;if(!o||ue(a)&&ue(l)&&!v.isValidElement(c)&&!ge(c))return null;if(v.isValidElement(c))return v.cloneElement(c,i);var f;if(ge(c)){if(f=v.createElement(c,i),v.isValidElement(f))return f}else f=Kne(i);var g=Zne(o),m=de(i,!0);if(g&&(s==="insideStart"||s==="insideEnd"||s==="end"))return Yne(i,f,m);var p=g?Jne(i):Xne(i);return v.createElement(lc,Zs({className:ve("recharts-label",d)},m,p,{breakAll:h}),f)}ft.displayName="Label";var yP=function(t){var r=t.cx,n=t.cy,i=t.angle,o=t.startAngle,s=t.endAngle,a=t.r,l=t.radius,c=t.innerRadius,u=t.outerRadius,d=t.x,h=t.y,f=t.top,g=t.left,m=t.width,p=t.height,y=t.clockWise,w=t.labelViewBox;if(w)return w;if(Z(m)&&Z(p)){if(Z(d)&&Z(h))return{x:d,y:h,width:m,height:p};if(Z(f)&&Z(g))return{x:f,y:g,width:m,height:p}}return Z(d)&&Z(h)?{x:d,y:h,width:0,height:0}:Z(r)&&Z(n)?{cx:r,cy:n,startAngle:o||i||0,endAngle:s||i||0,innerRadius:c||0,outerRadius:u||l||a||0,clockWise:y}:t.viewBox?t.viewBox:{}},Qne=function(t,r){return t?t===!0?v.createElement(ft,{key:"label-implicit",viewBox:r}):et(t)?v.createElement(ft,{key:"label-implicit",viewBox:r,value:t}):v.isValidElement(t)?t.type===ft?v.cloneElement(t,{key:"label-implicit",viewBox:r}):v.createElement(ft,{key:"label-implicit",content:t,viewBox:r}):ge(t)?v.createElement(ft,{key:"label-implicit",content:t,viewBox:r}):xo(t)?v.createElement(ft,Zs({viewBox:r},t,{key:"label-implicit"})):null:null},eie=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!t||!t.children&&n&&!t.label)return null;var i=t.children,o=yP(t),s=Tt(i,ft).map(function(l,c){return v.cloneElement(l,{viewBox:r||o,key:"label-".concat(c)})});if(!n)return s;var a=Qne(t.label,r||o);return[a].concat(Bne(s))};ft.parseViewBox=yP;ft.renderCallByParent=eie;function tie(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}var rie=tie;const nie=Le(rie);function Qs(e){"@babel/helpers - typeof";return Qs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qs(e)}var iie=["valueAccessor"],oie=["data","dataKey","clockWise","id","textBreakAll"];function sie(e){return uie(e)||cie(e)||lie(e)||aie()}function aie(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
54
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function lie(e,t){if(e){if(typeof e=="string")return zf(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return zf(e,t)}}function cie(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function uie(e){if(Array.isArray(e))return zf(e)}function zf(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Ac(){return Ac=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ac.apply(this,arguments)}function Jb(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Xb(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Jb(Object(r),!0).forEach(function(n){die(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Jb(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function die(e,t,r){return t=hie(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hie(e){var t=fie(e,"string");return Qs(t)=="symbol"?t:t+""}function fie(e,t){if(Qs(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Qs(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Zb(e,t){if(e==null)return{};var r=gie(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function gie(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var pie=function(t){return Array.isArray(t.value)?nie(t.value):t.value};function Cr(e){var t=e.valueAccessor,r=t===void 0?pie:t,n=Zb(e,iie),i=n.data,o=n.dataKey,s=n.clockWise,a=n.id,l=n.textBreakAll,c=Zb(n,oie);return!i||!i.length?null:v.createElement(be,{className:"recharts-label-list"},i.map(function(u,d){var h=ue(o)?r(u,d):tt(u&&u.payload,o),f=ue(a)?{}:{id:"".concat(a,"-").concat(d)};return v.createElement(ft,Ac({},de(u,!0),c,f,{parentViewBox:u.parentViewBox,value:h,textBreakAll:l,viewBox:ft.parseViewBox(ue(s)?u:Xb(Xb({},u),{},{clockWise:s})),key:"label-".concat(d),index:d}))}))}Cr.displayName="LabelList";function mie(e,t){return e?e===!0?v.createElement(Cr,{key:"labelList-implicit",data:t}):v.isValidElement(e)||ge(e)?v.createElement(Cr,{key:"labelList-implicit",data:t,content:e}):xo(e)?v.createElement(Cr,Ac({data:t},e,{key:"labelList-implicit"})):null:null}function vie(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!e||!e.children&&r&&!e.label)return null;var n=e.children,i=Tt(n,Cr).map(function(s,a){return v.cloneElement(s,{data:t,key:"labelList-".concat(a)})});if(!r)return i;var o=mie(e.label,t);return[o].concat(sie(i))}Cr.renderCallByParent=vie;function ea(e){"@babel/helpers - typeof";return ea=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ea(e)}function Nf(){return Nf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Nf.apply(this,arguments)}function Qb(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function eC(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Qb(Object(r),!0).forEach(function(n){yie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Qb(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function yie(e,t,r){return t=bie(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function bie(e){var t=Cie(e,"string");return ea(t)=="symbol"?t:t+""}function Cie(e,t){if(ea(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ea(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var wie=function(t,r){var n=ar(r-t),i=Math.min(Math.abs(r-t),359.999);return n*i},nl=function(t){var r=t.cx,n=t.cy,i=t.radius,o=t.angle,s=t.sign,a=t.isExternal,l=t.cornerRadius,c=t.cornerIsExternal,u=l*(a?1:-1)+i,d=Math.asin(l/u)/xc,h=c?o:o+s*d,f=at(r,n,u,h),g=at(r,n,i,h),m=c?o-s*d:o,p=at(r,n,u*Math.cos(d*xc),m);return{center:f,circleTangency:g,lineTangency:p,theta:d}},bP=function(t){var r=t.cx,n=t.cy,i=t.innerRadius,o=t.outerRadius,s=t.startAngle,a=t.endAngle,l=wie(s,a),c=s+l,u=at(r,n,o,s),d=at(r,n,o,c),h="M ".concat(u.x,",").concat(u.y,`
55
+ A `).concat(o,",").concat(o,`,0,
56
+ `).concat(+(Math.abs(l)>180),",").concat(+(s>c),`,
57
+ `).concat(d.x,",").concat(d.y,`
58
+ `);if(i>0){var f=at(r,n,i,s),g=at(r,n,i,c);h+="L ".concat(g.x,",").concat(g.y,`
59
+ A `).concat(i,",").concat(i,`,0,
60
+ `).concat(+(Math.abs(l)>180),",").concat(+(s<=c),`,
61
+ `).concat(f.x,",").concat(f.y," Z")}else h+="L ".concat(r,",").concat(n," Z");return h},Sie=function(t){var r=t.cx,n=t.cy,i=t.innerRadius,o=t.outerRadius,s=t.cornerRadius,a=t.forceCornerRadius,l=t.cornerIsExternal,c=t.startAngle,u=t.endAngle,d=ar(u-c),h=nl({cx:r,cy:n,radius:o,angle:c,sign:d,cornerRadius:s,cornerIsExternal:l}),f=h.circleTangency,g=h.lineTangency,m=h.theta,p=nl({cx:r,cy:n,radius:o,angle:u,sign:-d,cornerRadius:s,cornerIsExternal:l}),y=p.circleTangency,w=p.lineTangency,b=p.theta,x=l?Math.abs(c-u):Math.abs(c-u)-m-b;if(x<0)return a?"M ".concat(g.x,",").concat(g.y,`
62
+ a`).concat(s,",").concat(s,",0,0,1,").concat(s*2,`,0
63
+ a`).concat(s,",").concat(s,",0,0,1,").concat(-s*2,`,0
64
+ `):bP({cx:r,cy:n,innerRadius:i,outerRadius:o,startAngle:c,endAngle:u});var C="M ".concat(g.x,",").concat(g.y,`
65
+ A`).concat(s,",").concat(s,",0,0,").concat(+(d<0),",").concat(f.x,",").concat(f.y,`
66
+ A`).concat(o,",").concat(o,",0,").concat(+(x>180),",").concat(+(d<0),",").concat(y.x,",").concat(y.y,`
67
+ A`).concat(s,",").concat(s,",0,0,").concat(+(d<0),",").concat(w.x,",").concat(w.y,`
68
+ `);if(i>0){var S=nl({cx:r,cy:n,radius:i,angle:c,sign:d,isExternal:!0,cornerRadius:s,cornerIsExternal:l}),A=S.circleTangency,P=S.lineTangency,E=S.theta,O=nl({cx:r,cy:n,radius:i,angle:u,sign:-d,isExternal:!0,cornerRadius:s,cornerIsExternal:l}),R=O.circleTangency,T=O.lineTangency,F=O.theta,I=l?Math.abs(c-u):Math.abs(c-u)-E-F;if(I<0&&s===0)return"".concat(C,"L").concat(r,",").concat(n,"Z");C+="L".concat(T.x,",").concat(T.y,`
69
+ A`).concat(s,",").concat(s,",0,0,").concat(+(d<0),",").concat(R.x,",").concat(R.y,`
70
+ A`).concat(i,",").concat(i,",0,").concat(+(I>180),",").concat(+(d>0),",").concat(A.x,",").concat(A.y,`
71
+ A`).concat(s,",").concat(s,",0,0,").concat(+(d<0),",").concat(P.x,",").concat(P.y,"Z")}else C+="L".concat(r,",").concat(n,"Z");return C},xie={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},CP=function(t){var r=eC(eC({},xie),t),n=r.cx,i=r.cy,o=r.innerRadius,s=r.outerRadius,a=r.cornerRadius,l=r.forceCornerRadius,c=r.cornerIsExternal,u=r.startAngle,d=r.endAngle,h=r.className;if(s<o||u===d)return null;var f=ve("recharts-sector",h),g=s-o,m=Xn(a,g,0,!0),p;return m>0&&Math.abs(u-d)<360?p=Sie({cx:n,cy:i,innerRadius:o,outerRadius:s,cornerRadius:Math.min(m,g/2),forceCornerRadius:l,cornerIsExternal:c,startAngle:u,endAngle:d}):p=bP({cx:n,cy:i,innerRadius:o,outerRadius:s,startAngle:u,endAngle:d}),v.createElement("path",Nf({},de(r,!0),{className:f,d:p,role:"img"}))};function ta(e){"@babel/helpers - typeof";return ta=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ta(e)}function $f(){return $f=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},$f.apply(this,arguments)}function tC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function rC(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?tC(Object(r),!0).forEach(function(n){Aie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):tC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Aie(e,t,r){return t=Pie(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Pie(e){var t=Rie(e,"string");return ta(t)=="symbol"?t:t+""}function Rie(e,t){if(ta(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ta(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var nC={curveBasisClosed:OV,curveBasisOpen:MV,curveBasis:FV,curveBumpX:pV,curveBumpY:mV,curveLinearClosed:DV,curveLinear:xu,curveMonotoneX:kV,curveMonotoneY:IV,curveNatural:_V,curveStep:LV,curveStepAfter:zV,curveStepBefore:BV},il=function(t){return t.x===+t.x&&t.y===+t.y},qo=function(t){return t.x},Yo=function(t){return t.y},Eie=function(t,r){if(ge(t))return t;var n="curve".concat(wu(t));return(n==="curveMonotone"||n==="curveBump")&&r?nC["".concat(n).concat(r==="vertical"?"Y":"X")]:nC[n]||xu},Tie=function(t){var r=t.type,n=r===void 0?"linear":r,i=t.points,o=i===void 0?[]:i,s=t.baseLine,a=t.layout,l=t.connectNulls,c=l===void 0?!1:l,u=Eie(n,a),d=c?o.filter(function(m){return il(m)}):o,h;if(Array.isArray(s)){var f=c?s.filter(function(m){return il(m)}):s,g=d.map(function(m,p){return rC(rC({},m),{},{base:f[p]})});return a==="vertical"?h=Ya().y(Yo).x1(qo).x0(function(m){return m.base.x}):h=Ya().x(qo).y1(Yo).y0(function(m){return m.base.y}),h.defined(il).curve(u),h(g)}return a==="vertical"&&Z(s)?h=Ya().y(Yo).x1(qo).x0(s):Z(s)?h=Ya().x(qo).y1(Yo).y0(s):h=Ax().x(qo).y(Yo),h.defined(il).curve(u),h(d)},$n=function(t){var r=t.className,n=t.points,i=t.path,o=t.pathRef;if((!n||!n.length)&&!i)return null;var s=n&&n.length?Tie(t):i;return v.createElement("path",$f({},de(t,!1),ql(t),{className:ve("recharts-curve",r),d:s,ref:o}))},Hf={exports:{}},ol={exports:{}},Se={};/** @license React v16.13.1
72
+ * react-is.production.min.js
73
+ *
74
+ * Copyright (c) Facebook, Inc. and its affiliates.
75
+ *
76
+ * This source code is licensed under the MIT license found in the
77
+ * LICENSE file in the root directory of this source tree.
78
+ */var iC;function Fie(){if(iC)return Se;iC=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,f=e?Symbol.for("react.memo"):60115,g=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,p=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,w=e?Symbol.for("react.scope"):60119;function b(C){if(typeof C=="object"&&C!==null){var S=C.$$typeof;switch(S){case t:switch(C=C.type,C){case l:case c:case n:case o:case i:case d:return C;default:switch(C=C&&C.$$typeof,C){case a:case u:case g:case f:case s:return C;default:return S}}case r:return S}}}function x(C){return b(C)===c}return Se.AsyncMode=l,Se.ConcurrentMode=c,Se.ContextConsumer=a,Se.ContextProvider=s,Se.Element=t,Se.ForwardRef=u,Se.Fragment=n,Se.Lazy=g,Se.Memo=f,Se.Portal=r,Se.Profiler=o,Se.StrictMode=i,Se.Suspense=d,Se.isAsyncMode=function(C){return x(C)||b(C)===l},Se.isConcurrentMode=x,Se.isContextConsumer=function(C){return b(C)===a},Se.isContextProvider=function(C){return b(C)===s},Se.isElement=function(C){return typeof C=="object"&&C!==null&&C.$$typeof===t},Se.isForwardRef=function(C){return b(C)===u},Se.isFragment=function(C){return b(C)===n},Se.isLazy=function(C){return b(C)===g},Se.isMemo=function(C){return b(C)===f},Se.isPortal=function(C){return b(C)===r},Se.isProfiler=function(C){return b(C)===o},Se.isStrictMode=function(C){return b(C)===i},Se.isSuspense=function(C){return b(C)===d},Se.isValidElementType=function(C){return typeof C=="string"||typeof C=="function"||C===n||C===c||C===o||C===i||C===d||C===h||typeof C=="object"&&C!==null&&(C.$$typeof===g||C.$$typeof===f||C.$$typeof===s||C.$$typeof===a||C.$$typeof===u||C.$$typeof===p||C.$$typeof===y||C.$$typeof===w||C.$$typeof===m)},Se.typeOf=b,Se}var xe={};/** @license React v16.13.1
79
+ * react-is.development.js
80
+ *
81
+ * Copyright (c) Facebook, Inc. and its affiliates.
82
+ *
83
+ * This source code is licensed under the MIT license found in the
84
+ * LICENSE file in the root directory of this source tree.
85
+ */var oC;function Oie(){return oC||(oC=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,f=e?Symbol.for("react.memo"):60115,g=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,p=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,w=e?Symbol.for("react.scope"):60119;function b(_){return typeof _=="string"||typeof _=="function"||_===n||_===c||_===o||_===i||_===d||_===h||typeof _=="object"&&_!==null&&(_.$$typeof===g||_.$$typeof===f||_.$$typeof===s||_.$$typeof===a||_.$$typeof===u||_.$$typeof===p||_.$$typeof===y||_.$$typeof===w||_.$$typeof===m)}function x(_){if(typeof _=="object"&&_!==null){var ne=_.$$typeof;switch(ne){case t:var U=_.type;switch(U){case l:case c:case n:case o:case i:case d:return U;default:var ce=U&&U.$$typeof;switch(ce){case a:case u:case g:case f:case s:return ce;default:return ne}}case r:return ne}}}var C=l,S=c,A=a,P=s,E=t,O=u,R=n,T=g,F=f,I=r,k=o,B=i,N=d,z=!1;function W(_){return z||(z=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),D(_)||x(_)===l}function D(_){return x(_)===c}function L(_){return x(_)===a}function $(_){return x(_)===s}function H(_){return typeof _=="object"&&_!==null&&_.$$typeof===t}function V(_){return x(_)===u}function X(_){return x(_)===n}function Y(_){return x(_)===g}function re(_){return x(_)===f}function oe(_){return x(_)===r}function K(_){return x(_)===o}function J(_){return x(_)===i}function te(_){return x(_)===d}xe.AsyncMode=C,xe.ConcurrentMode=S,xe.ContextConsumer=A,xe.ContextProvider=P,xe.Element=E,xe.ForwardRef=O,xe.Fragment=R,xe.Lazy=T,xe.Memo=F,xe.Portal=I,xe.Profiler=k,xe.StrictMode=B,xe.Suspense=N,xe.isAsyncMode=W,xe.isConcurrentMode=D,xe.isContextConsumer=L,xe.isContextProvider=$,xe.isElement=H,xe.isForwardRef=V,xe.isFragment=X,xe.isLazy=Y,xe.isMemo=re,xe.isPortal=oe,xe.isProfiler=K,xe.isStrictMode=J,xe.isSuspense=te,xe.isValidElementType=b,xe.typeOf=x}()),xe}var sC;function wP(){return sC||(sC=1,process.env.NODE_ENV==="production"?ol.exports=Fie():ol.exports=Oie()),ol.exports}/*
86
+ object-assign
87
+ (c) Sindre Sorhus
88
+ @license MIT
89
+ */var rh,aC;function Mie(){if(aC)return rh;aC=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function n(o){if(o==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(o)}function i(){try{if(!Object.assign)return!1;var o=new String("abc");if(o[5]="de",Object.getOwnPropertyNames(o)[0]==="5")return!1;for(var s={},a=0;a<10;a++)s["_"+String.fromCharCode(a)]=a;var l=Object.getOwnPropertyNames(s).map(function(u){return s[u]});if(l.join("")!=="0123456789")return!1;var c={};return"abcdefghijklmnopqrst".split("").forEach(function(u){c[u]=u}),Object.keys(Object.assign({},c)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return rh=i()?Object.assign:function(o,s){for(var a,l=n(o),c,u=1;u<arguments.length;u++){a=Object(arguments[u]);for(var d in a)t.call(a,d)&&(l[d]=a[d]);if(e){c=e(a);for(var h=0;h<c.length;h++)r.call(a,c[h])&&(l[c[h]]=a[c[h]])}}return l},rh}var nh,lC;function Rm(){if(lC)return nh;lC=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return nh=e,nh}var ih,cC;function SP(){return cC||(cC=1,ih=Function.call.bind(Object.prototype.hasOwnProperty)),ih}var oh,uC;function Die(){if(uC)return oh;uC=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=Rm(),r={},n=SP();e=function(o){var s="Warning: "+o;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function i(o,s,a,l,c){if(process.env.NODE_ENV!=="production"){for(var u in o)if(n(o,u)){var d;try{if(typeof o[u]!="function"){var h=Error((l||"React class")+": "+a+" type `"+u+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[u]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}d=o[u](s,u,l,a,null,t)}catch(g){d=g}if(d&&!(d instanceof Error)&&e((l||"React class")+": type specification of "+a+" `"+u+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof d+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),d instanceof Error&&!(d.message in r)){r[d.message]=!0;var f=c?c():"";e("Failed "+a+" type: "+d.message+(f??""))}}}}return i.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(r={})},oh=i,oh}var sh,dC;function kie(){if(dC)return sh;dC=1;var e=wP(),t=Mie(),r=Rm(),n=SP(),i=Die(),o=function(){};process.env.NODE_ENV!=="production"&&(o=function(a){var l="Warning: "+a;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function s(){return null}return sh=function(a,l){var c=typeof Symbol=="function"&&Symbol.iterator,u="@@iterator";function d(D){var L=D&&(c&&D[c]||D[u]);if(typeof L=="function")return L}var h="<<anonymous>>",f={array:y("array"),bigint:y("bigint"),bool:y("boolean"),func:y("function"),number:y("number"),object:y("object"),string:y("string"),symbol:y("symbol"),any:w(),arrayOf:b,element:x(),elementType:C(),instanceOf:S,node:O(),objectOf:P,oneOf:A,oneOfType:E,shape:T,exact:F};function g(D,L){return D===L?D!==0||1/D===1/L:D!==D&&L!==L}function m(D,L){this.message=D,this.data=L&&typeof L=="object"?L:{},this.stack=""}m.prototype=Error.prototype;function p(D){if(process.env.NODE_ENV!=="production")var L={},$=0;function H(X,Y,re,oe,K,J,te){if(oe=oe||h,J=J||re,te!==r){if(l){var _=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw _.name="Invariant Violation",_}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var ne=oe+":"+re;!L[ne]&&$<3&&(o("You are manually calling a React.PropTypes validation function for the `"+J+"` prop on `"+oe+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),L[ne]=!0,$++)}}return Y[re]==null?X?Y[re]===null?new m("The "+K+" `"+J+"` is marked as required "+("in `"+oe+"`, but its value is `null`.")):new m("The "+K+" `"+J+"` is marked as required in "+("`"+oe+"`, but its value is `undefined`.")):null:D(Y,re,oe,K,J)}var V=H.bind(null,!1);return V.isRequired=H.bind(null,!0),V}function y(D){function L($,H,V,X,Y,re){var oe=$[H],K=B(oe);if(K!==D){var J=N(oe);return new m("Invalid "+X+" `"+Y+"` of type "+("`"+J+"` supplied to `"+V+"`, expected ")+("`"+D+"`."),{expectedType:D})}return null}return p(L)}function w(){return p(s)}function b(D){function L($,H,V,X,Y){if(typeof D!="function")return new m("Property `"+Y+"` of component `"+V+"` has invalid PropType notation inside arrayOf.");var re=$[H];if(!Array.isArray(re)){var oe=B(re);return new m("Invalid "+X+" `"+Y+"` of type "+("`"+oe+"` supplied to `"+V+"`, expected an array."))}for(var K=0;K<re.length;K++){var J=D(re,K,V,X,Y+"["+K+"]",r);if(J instanceof Error)return J}return null}return p(L)}function x(){function D(L,$,H,V,X){var Y=L[$];if(!a(Y)){var re=B(Y);return new m("Invalid "+V+" `"+X+"` of type "+("`"+re+"` supplied to `"+H+"`, expected a single ReactElement."))}return null}return p(D)}function C(){function D(L,$,H,V,X){var Y=L[$];if(!e.isValidElementType(Y)){var re=B(Y);return new m("Invalid "+V+" `"+X+"` of type "+("`"+re+"` supplied to `"+H+"`, expected a single ReactElement type."))}return null}return p(D)}function S(D){function L($,H,V,X,Y){if(!($[H]instanceof D)){var re=D.name||h,oe=W($[H]);return new m("Invalid "+X+" `"+Y+"` of type "+("`"+oe+"` supplied to `"+V+"`, expected ")+("instance of `"+re+"`."))}return null}return p(L)}function A(D){if(!Array.isArray(D))return process.env.NODE_ENV!=="production"&&(arguments.length>1?o("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):o("Invalid argument supplied to oneOf, expected an array.")),s;function L($,H,V,X,Y){for(var re=$[H],oe=0;oe<D.length;oe++)if(g(re,D[oe]))return null;var K=JSON.stringify(D,function(te,_){var ne=N(_);return ne==="symbol"?String(_):_});return new m("Invalid "+X+" `"+Y+"` of value `"+String(re)+"` "+("supplied to `"+V+"`, expected one of "+K+"."))}return p(L)}function P(D){function L($,H,V,X,Y){if(typeof D!="function")return new m("Property `"+Y+"` of component `"+V+"` has invalid PropType notation inside objectOf.");var re=$[H],oe=B(re);if(oe!=="object")return new m("Invalid "+X+" `"+Y+"` of type "+("`"+oe+"` supplied to `"+V+"`, expected an object."));for(var K in re)if(n(re,K)){var J=D(re,K,V,X,Y+"."+K,r);if(J instanceof Error)return J}return null}return p(L)}function E(D){if(!Array.isArray(D))return process.env.NODE_ENV!=="production"&&o("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var L=0;L<D.length;L++){var $=D[L];if(typeof $!="function")return o("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+z($)+" at index "+L+"."),s}function H(V,X,Y,re,oe){for(var K=[],J=0;J<D.length;J++){var te=D[J],_=te(V,X,Y,re,oe,r);if(_==null)return null;_.data&&n(_.data,"expectedType")&&K.push(_.data.expectedType)}var ne=K.length>0?", expected one of type ["+K.join(", ")+"]":"";return new m("Invalid "+re+" `"+oe+"` supplied to "+("`"+Y+"`"+ne+"."))}return p(H)}function O(){function D(L,$,H,V,X){return I(L[$])?null:new m("Invalid "+V+" `"+X+"` supplied to "+("`"+H+"`, expected a ReactNode."))}return p(D)}function R(D,L,$,H,V){return new m((D||"React class")+": "+L+" type `"+$+"."+H+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+V+"`.")}function T(D){function L($,H,V,X,Y){var re=$[H],oe=B(re);if(oe!=="object")return new m("Invalid "+X+" `"+Y+"` of type `"+oe+"` "+("supplied to `"+V+"`, expected `object`."));for(var K in D){var J=D[K];if(typeof J!="function")return R(V,X,Y,K,N(J));var te=J(re,K,V,X,Y+"."+K,r);if(te)return te}return null}return p(L)}function F(D){function L($,H,V,X,Y){var re=$[H],oe=B(re);if(oe!=="object")return new m("Invalid "+X+" `"+Y+"` of type `"+oe+"` "+("supplied to `"+V+"`, expected `object`."));var K=t({},$[H],D);for(var J in K){var te=D[J];if(n(D,J)&&typeof te!="function")return R(V,X,Y,J,N(te));if(!te)return new m("Invalid "+X+" `"+Y+"` key `"+J+"` supplied to `"+V+"`.\nBad object: "+JSON.stringify($[H],null," ")+`
90
+ Valid keys: `+JSON.stringify(Object.keys(D),null," "));var _=te(re,J,V,X,Y+"."+J,r);if(_)return _}return null}return p(L)}function I(D){switch(typeof D){case"number":case"string":case"undefined":return!0;case"boolean":return!D;case"object":if(Array.isArray(D))return D.every(I);if(D===null||a(D))return!0;var L=d(D);if(L){var $=L.call(D),H;if(L!==D.entries){for(;!(H=$.next()).done;)if(!I(H.value))return!1}else for(;!(H=$.next()).done;){var V=H.value;if(V&&!I(V[1]))return!1}}else return!1;return!0;default:return!1}}function k(D,L){return D==="symbol"?!0:L?L["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&L instanceof Symbol:!1}function B(D){var L=typeof D;return Array.isArray(D)?"array":D instanceof RegExp?"object":k(L,D)?"symbol":L}function N(D){if(typeof D>"u"||D===null)return""+D;var L=B(D);if(L==="object"){if(D instanceof Date)return"date";if(D instanceof RegExp)return"regexp"}return L}function z(D){var L=N(D);switch(L){case"array":case"object":return"an "+L;case"boolean":case"date":case"regexp":return"a "+L;default:return L}}function W(D){return!D.constructor||!D.constructor.name?h:D.constructor.name}return f.checkPropTypes=i,f.resetWarningCache=i.resetWarningCache,f.PropTypes=f,f},sh}var ah,hC;function Iie(){if(hC)return ah;hC=1;var e=Rm();function t(){}function r(){}return r.resetWarningCache=t,ah=function(){function n(s,a,l,c,u,d){if(d!==e){var h=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw h.name="Invariant Violation",h}}n.isRequired=n;function i(){return n}var o={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:i,element:n,elementType:n,instanceOf:i,node:n,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:r,resetWarningCache:t};return o.PropTypes=o,o},ah}if(process.env.NODE_ENV!=="production"){var _ie=wP(),Lie=!0;Hf.exports=kie()(_ie.isElement,Lie)}else Hf.exports=Iie()();var Bie=Hf.exports;const Ae=Le(Bie);var zie=Object.getOwnPropertyNames,Nie=Object.getOwnPropertySymbols,$ie=Object.prototype.hasOwnProperty;function fC(e,t){return function(n,i,o){return e(n,i,o)&&t(n,i,o)}}function sl(e){return function(r,n,i){if(!r||!n||typeof r!="object"||typeof n!="object")return e(r,n,i);var o=i.cache,s=o.get(r),a=o.get(n);if(s&&a)return s===n&&a===r;o.set(r,n),o.set(n,r);var l=e(r,n,i);return o.delete(r),o.delete(n),l}}function gC(e){return zie(e).concat(Nie(e))}var Hie=Object.hasOwn||function(e,t){return $ie.call(e,t)};function li(e,t){return e===t||!e&&!t&&e!==e&&t!==t}var Gie="__v",Wie="__o",jie="_owner",pC=Object.getOwnPropertyDescriptor,mC=Object.keys;function Vie(e,t,r){var n=e.length;if(t.length!==n)return!1;for(;n-- >0;)if(!r.equals(e[n],t[n],n,n,e,t,r))return!1;return!0}function Uie(e,t){return li(e.getTime(),t.getTime())}function Kie(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function qie(e,t){return e===t}function vC(e,t,r){var n=e.size;if(n!==t.size)return!1;if(!n)return!0;for(var i=new Array(n),o=e.entries(),s,a,l=0;(s=o.next())&&!s.done;){for(var c=t.entries(),u=!1,d=0;(a=c.next())&&!a.done;){if(i[d]){d++;continue}var h=s.value,f=a.value;if(r.equals(h[0],f[0],l,d,e,t,r)&&r.equals(h[1],f[1],h[0],f[0],e,t,r)){u=i[d]=!0;break}d++}if(!u)return!1;l++}return!0}var Yie=li;function Jie(e,t,r){var n=mC(e),i=n.length;if(mC(t).length!==i)return!1;for(;i-- >0;)if(!xP(e,t,r,n[i]))return!1;return!0}function Jo(e,t,r){var n=gC(e),i=n.length;if(gC(t).length!==i)return!1;for(var o,s,a;i-- >0;)if(o=n[i],!xP(e,t,r,o)||(s=pC(e,o),a=pC(t,o),(s||a)&&(!s||!a||s.configurable!==a.configurable||s.enumerable!==a.enumerable||s.writable!==a.writable)))return!1;return!0}function Xie(e,t){return li(e.valueOf(),t.valueOf())}function Zie(e,t){return e.source===t.source&&e.flags===t.flags}function yC(e,t,r){var n=e.size;if(n!==t.size)return!1;if(!n)return!0;for(var i=new Array(n),o=e.values(),s,a;(s=o.next())&&!s.done;){for(var l=t.values(),c=!1,u=0;(a=l.next())&&!a.done;){if(!i[u]&&r.equals(s.value,a.value,s.value,a.value,e,t,r)){c=i[u]=!0;break}u++}if(!c)return!1}return!0}function Qie(e,t){var r=e.length;if(t.length!==r)return!1;for(;r-- >0;)if(e[r]!==t[r])return!1;return!0}function eoe(e,t){return e.hostname===t.hostname&&e.pathname===t.pathname&&e.protocol===t.protocol&&e.port===t.port&&e.hash===t.hash&&e.username===t.username&&e.password===t.password}function xP(e,t,r,n){return(n===jie||n===Wie||n===Gie)&&(e.$$typeof||t.$$typeof)?!0:Hie(t,n)&&r.equals(e[n],t[n],n,n,e,t,r)}var toe="[object Arguments]",roe="[object Boolean]",noe="[object Date]",ioe="[object Error]",ooe="[object Map]",soe="[object Number]",aoe="[object Object]",loe="[object RegExp]",coe="[object Set]",uoe="[object String]",doe="[object URL]",hoe=Array.isArray,bC=typeof ArrayBuffer=="function"&&ArrayBuffer.isView?ArrayBuffer.isView:null,CC=Object.assign,foe=Object.prototype.toString.call.bind(Object.prototype.toString);function goe(e){var t=e.areArraysEqual,r=e.areDatesEqual,n=e.areErrorsEqual,i=e.areFunctionsEqual,o=e.areMapsEqual,s=e.areNumbersEqual,a=e.areObjectsEqual,l=e.arePrimitiveWrappersEqual,c=e.areRegExpsEqual,u=e.areSetsEqual,d=e.areTypedArraysEqual,h=e.areUrlsEqual;return function(g,m,p){if(g===m)return!0;if(g==null||m==null)return!1;var y=typeof g;if(y!==typeof m)return!1;if(y!=="object")return y==="number"?s(g,m,p):y==="function"?i(g,m,p):!1;var w=g.constructor;if(w!==m.constructor)return!1;if(w===Object)return a(g,m,p);if(hoe(g))return t(g,m,p);if(bC!=null&&bC(g))return d(g,m,p);if(w===Date)return r(g,m,p);if(w===RegExp)return c(g,m,p);if(w===Map)return o(g,m,p);if(w===Set)return u(g,m,p);var b=foe(g);return b===noe?r(g,m,p):b===loe?c(g,m,p):b===ooe?o(g,m,p):b===coe?u(g,m,p):b===aoe?typeof g.then!="function"&&typeof m.then!="function"&&a(g,m,p):b===doe?h(g,m,p):b===ioe?n(g,m,p):b===toe?a(g,m,p):b===roe||b===soe||b===uoe?l(g,m,p):!1}}function poe(e){var t=e.circular,r=e.createCustomConfig,n=e.strict,i={areArraysEqual:n?Jo:Vie,areDatesEqual:Uie,areErrorsEqual:Kie,areFunctionsEqual:qie,areMapsEqual:n?fC(vC,Jo):vC,areNumbersEqual:Yie,areObjectsEqual:n?Jo:Jie,arePrimitiveWrappersEqual:Xie,areRegExpsEqual:Zie,areSetsEqual:n?fC(yC,Jo):yC,areTypedArraysEqual:n?Jo:Qie,areUrlsEqual:eoe};if(r&&(i=CC({},i,r(i))),t){var o=sl(i.areArraysEqual),s=sl(i.areMapsEqual),a=sl(i.areObjectsEqual),l=sl(i.areSetsEqual);i=CC({},i,{areArraysEqual:o,areMapsEqual:s,areObjectsEqual:a,areSetsEqual:l})}return i}function moe(e){return function(t,r,n,i,o,s,a){return e(t,r,a)}}function voe(e){var t=e.circular,r=e.comparator,n=e.createState,i=e.equals,o=e.strict;if(n)return function(l,c){var u=n(),d=u.cache,h=d===void 0?t?new WeakMap:void 0:d,f=u.meta;return r(l,c,{cache:h,equals:i,meta:f,strict:o})};if(t)return function(l,c){return r(l,c,{cache:new WeakMap,equals:i,meta:void 0,strict:o})};var s={cache:void 0,equals:i,meta:void 0,strict:o};return function(l,c){return r(l,c,s)}}var yoe=yn();yn({strict:!0});yn({circular:!0});yn({circular:!0,strict:!0});yn({createInternalComparator:function(){return li}});yn({strict:!0,createInternalComparator:function(){return li}});yn({circular:!0,createInternalComparator:function(){return li}});yn({circular:!0,createInternalComparator:function(){return li},strict:!0});function yn(e){e===void 0&&(e={});var t=e.circular,r=t===void 0?!1:t,n=e.createInternalComparator,i=e.createState,o=e.strict,s=o===void 0?!1:o,a=poe(e),l=goe(a),c=n?n(l):moe(l);return voe({circular:r,comparator:l,createState:i,equals:c,strict:s})}function boe(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function wC(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=-1,n=function i(o){r<0&&(r=o),o-r>t?(e(o),r=-1):boe(i)};requestAnimationFrame(n)}function Gf(e){"@babel/helpers - typeof";return Gf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Gf(e)}function Coe(e){return Aoe(e)||xoe(e)||Soe(e)||woe()}function woe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
91
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Soe(e,t){if(e){if(typeof e=="string")return SC(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return SC(e,t)}}function SC(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function xoe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Aoe(e){if(Array.isArray(e))return e}function Poe(){var e={},t=function(){return null},r=!1,n=function i(o){if(!r){if(Array.isArray(o)){if(!o.length)return;var s=o,a=Coe(s),l=a[0],c=a.slice(1);if(typeof l=="number"){wC(i.bind(null,c),l);return}i(l),wC(i.bind(null,c));return}Gf(o)==="object"&&(e=o,t(e)),typeof o=="function"&&o()}};return{stop:function(){r=!0},start:function(o){r=!1,n(o)},subscribe:function(o){return t=o,function(){t=function(){return null}}}}}function ra(e){"@babel/helpers - typeof";return ra=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ra(e)}function xC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function AC(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?xC(Object(r),!0).forEach(function(n){AP(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):xC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function AP(e,t,r){return t=Roe(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Roe(e){var t=Eoe(e,"string");return ra(t)==="symbol"?t:String(t)}function Eoe(e,t){if(ra(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ra(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Toe=function(t,r){return[Object.keys(t),Object.keys(r)].reduce(function(n,i){return n.filter(function(o){return i.includes(o)})})},Foe=function(t){return t},Ooe=function(t){return t.replace(/([A-Z])/g,function(r){return"-".concat(r.toLowerCase())})},fs=function(t,r){return Object.keys(r).reduce(function(n,i){return AC(AC({},n),{},AP({},i,t(i,r[i])))},{})},PC=function(t,r,n){return t.map(function(i){return"".concat(Ooe(i)," ").concat(r,"ms ").concat(n)}).join(",")},Moe=process.env.NODE_ENV!=="production",Pc=function(t,r,n,i,o,s,a,l){if(Moe&&typeof console<"u"&&console.warn&&(r===void 0&&console.warn("LogUtils requires an error message argument"),!t))if(r===void 0)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,i,o,s,a,l],u=0;console.warn(r.replace(/%s/g,function(){return c[u++]}))}};function Doe(e,t){return _oe(e)||Ioe(e,t)||PP(e,t)||koe()}function koe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
92
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ioe(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function _oe(e){if(Array.isArray(e))return e}function Loe(e){return Noe(e)||zoe(e)||PP(e)||Boe()}function Boe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
93
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function PP(e,t){if(e){if(typeof e=="string")return Wf(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Wf(e,t)}}function zoe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Noe(e){if(Array.isArray(e))return Wf(e)}function Wf(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var Rc=1e-4,RP=function(t,r){return[0,3*t,3*r-6*t,3*t-3*r+1]},EP=function(t,r){return t.map(function(n,i){return n*Math.pow(r,i)}).reduce(function(n,i){return n+i})},RC=function(t,r){return function(n){var i=RP(t,r);return EP(i,n)}},$oe=function(t,r){return function(n){var i=RP(t,r),o=[].concat(Loe(i.map(function(s,a){return s*a}).slice(1)),[0]);return EP(o,n)}},EC=function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];var i=r[0],o=r[1],s=r[2],a=r[3];if(r.length===1)switch(r[0]){case"linear":i=0,o=0,s=1,a=1;break;case"ease":i=.25,o=.1,s=.25,a=1;break;case"ease-in":i=.42,o=0,s=1,a=1;break;case"ease-out":i=.42,o=0,s=.58,a=1;break;case"ease-in-out":i=0,o=0,s=.58,a=1;break;default:{var l=r[0].split("(");if(l[0]==="cubic-bezier"&&l[1].split(")")[0].split(",").length===4){var c=l[1].split(")")[0].split(",").map(function(p){return parseFloat(p)}),u=Doe(c,4);i=u[0],o=u[1],s=u[2],a=u[3]}else Pc(!1,"[configBezier]: arguments should be one of oneOf 'linear', 'ease', 'ease-in', 'ease-out', 'ease-in-out','cubic-bezier(x1,y1,x2,y2)', instead received %s",r)}}Pc([i,s,o,a].every(function(p){return typeof p=="number"&&p>=0&&p<=1}),"[configBezier]: arguments should be x1, y1, x2, y2 of [0, 1] instead received %s",r);var d=RC(i,s),h=RC(o,a),f=$oe(i,s),g=function(y){return y>1?1:y<0?0:y},m=function(y){for(var w=y>1?1:y,b=w,x=0;x<8;++x){var C=d(b)-w,S=f(b);if(Math.abs(C-w)<Rc||S<Rc)return h(b);b=g(b-C/S)}return h(b)};return m.isStepper=!1,m},Hoe=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=t.stiff,n=r===void 0?100:r,i=t.damping,o=i===void 0?8:i,s=t.dt,a=s===void 0?17:s,l=function(u,d,h){var f=-(u-d)*n,g=h*o,m=h+(f-g)*a/1e3,p=h*a/1e3+u;return Math.abs(p-d)<Rc&&Math.abs(m)<Rc?[d,0]:[p,m]};return l.isStepper=!0,l.dt=a,l},Goe=function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];var i=r[0];if(typeof i=="string")switch(i){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return EC(i);case"spring":return Hoe();default:if(i.split("(")[0]==="cubic-bezier")return EC(i);Pc(!1,"[configEasing]: first argument should be one of 'ease', 'ease-in', 'ease-out', 'ease-in-out','cubic-bezier(x1,y1,x2,y2)', 'linear' and 'spring', instead received %s",r)}return typeof i=="function"?i:(Pc(!1,"[configEasing]: first argument type should be function or string, instead received %s",r),null)};function na(e){"@babel/helpers - typeof";return na=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},na(e)}function TC(e){return Voe(e)||joe(e)||TP(e)||Woe()}function Woe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
94
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function joe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Voe(e){if(Array.isArray(e))return Vf(e)}function FC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function st(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?FC(Object(r),!0).forEach(function(n){jf(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):FC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function jf(e,t,r){return t=Uoe(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Uoe(e){var t=Koe(e,"string");return na(t)==="symbol"?t:String(t)}function Koe(e,t){if(na(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(na(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function qoe(e,t){return Xoe(e)||Joe(e,t)||TP(e,t)||Yoe()}function Yoe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
95
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function TP(e,t){if(e){if(typeof e=="string")return Vf(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Vf(e,t)}}function Vf(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Joe(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function Xoe(e){if(Array.isArray(e))return e}var Ec=function(t,r,n){return t+(r-t)*n},Uf=function(t){var r=t.from,n=t.to;return r!==n},Zoe=function e(t,r,n){var i=fs(function(o,s){if(Uf(s)){var a=t(s.from,s.to,s.velocity),l=qoe(a,2),c=l[0],u=l[1];return st(st({},s),{},{from:c,velocity:u})}return s},r);return n<1?fs(function(o,s){return Uf(s)?st(st({},s),{},{velocity:Ec(s.velocity,i[o].velocity,n),from:Ec(s.from,i[o].from,n)}):s},r):e(t,i,n-1)};const Qoe=function(e,t,r,n,i){var o=Toe(e,t),s=o.reduce(function(p,y){return st(st({},p),{},jf({},y,[e[y],t[y]]))},{}),a=o.reduce(function(p,y){return st(st({},p),{},jf({},y,{from:e[y],velocity:0,to:t[y]}))},{}),l=-1,c,u,d=function(){return null},h=function(){return fs(function(y,w){return w.from},a)},f=function(){return!Object.values(a).filter(Uf).length},g=function(y){c||(c=y);var w=y-c,b=w/r.dt;a=Zoe(r,a,b),i(st(st(st({},e),t),h())),c=y,f()||(l=requestAnimationFrame(d))},m=function(y){u||(u=y);var w=(y-u)/n,b=fs(function(C,S){return Ec.apply(void 0,TC(S).concat([r(w)]))},s);if(i(st(st(st({},e),t),b)),w<1)l=requestAnimationFrame(d);else{var x=fs(function(C,S){return Ec.apply(void 0,TC(S).concat([r(1)]))},s);i(st(st(st({},e),t),x))}};return d=r.isStepper?g:m,function(){return requestAnimationFrame(d),function(){cancelAnimationFrame(l)}}};function Yi(e){"@babel/helpers - typeof";return Yi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Yi(e)}var ese=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function tse(e,t){if(e==null)return{};var r=rse(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function rse(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o<n.length;o++)i=n[o],!(t.indexOf(i)>=0)&&(r[i]=e[i]);return r}function lh(e){return sse(e)||ose(e)||ise(e)||nse()}function nse(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
96
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ise(e,t){if(e){if(typeof e=="string")return Kf(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Kf(e,t)}}function ose(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function sse(e){if(Array.isArray(e))return Kf(e)}function Kf(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function OC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function tr(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?OC(Object(r),!0).forEach(function(n){es(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):OC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function es(e,t,r){return t=FP(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ase(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function lse(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,FP(n.key),n)}}function cse(e,t,r){return t&&lse(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function FP(e){var t=use(e,"string");return Yi(t)==="symbol"?t:String(t)}function use(e,t){if(Yi(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Yi(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function dse(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&qf(e,t)}function qf(e,t){return qf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},qf(e,t)}function hse(e){var t=fse();return function(){var n=Tc(e),i;if(t){var o=Tc(this).constructor;i=Reflect.construct(n,arguments,o)}else i=n.apply(this,arguments);return Yf(this,i)}}function Yf(e,t){if(t&&(Yi(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Jf(e)}function Jf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function fse(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Tc(e){return Tc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Tc(e)}var cr=function(e){dse(r,e);var t=hse(r);function r(n,i){var o;ase(this,r),o=t.call(this,n,i);var s=o.props,a=s.isActive,l=s.attributeName,c=s.from,u=s.to,d=s.steps,h=s.children,f=s.duration;if(o.handleStyleChange=o.handleStyleChange.bind(Jf(o)),o.changeStyle=o.changeStyle.bind(Jf(o)),!a||f<=0)return o.state={style:{}},typeof h=="function"&&(o.state={style:u}),Yf(o);if(d&&d.length)o.state={style:d[0].style};else if(c){if(typeof h=="function")return o.state={style:c},Yf(o);o.state={style:l?es({},l,c):c}}else o.state={style:{}};return o}return cse(r,[{key:"componentDidMount",value:function(){var i=this.props,o=i.isActive,s=i.canBegin;this.mounted=!0,!(!o||!s)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(i){var o=this.props,s=o.isActive,a=o.canBegin,l=o.attributeName,c=o.shouldReAnimate,u=o.to,d=o.from,h=this.state.style;if(a){if(!s){var f={style:l?es({},l,u):u};this.state&&h&&(l&&h[l]!==u||!l&&h!==u)&&this.setState(f);return}if(!(yoe(i.to,u)&&i.canBegin&&i.isActive)){var g=!i.canBegin||!i.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var m=g||c?d:i.to;if(this.state&&h){var p={style:l?es({},l,m):m};(l&&h[l]!==m||!l&&h!==m)&&this.setState(p)}this.runAnimation(tr(tr({},this.props),{},{from:m,begin:0}))}}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var i=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),i&&i()}},{key:"handleStyleChange",value:function(i){this.changeStyle(i)}},{key:"changeStyle",value:function(i){this.mounted&&this.setState({style:i})}},{key:"runJSAnimation",value:function(i){var o=this,s=i.from,a=i.to,l=i.duration,c=i.easing,u=i.begin,d=i.onAnimationEnd,h=i.onAnimationStart,f=Qoe(s,a,Goe(c),l,this.changeStyle),g=function(){o.stopJSAnimation=f()};this.manager.start([h,u,g,l,d])}},{key:"runStepAnimation",value:function(i){var o=this,s=i.steps,a=i.begin,l=i.onAnimationStart,c=s[0],u=c.style,d=c.duration,h=d===void 0?0:d,f=function(m,p,y){if(y===0)return m;var w=p.duration,b=p.easing,x=b===void 0?"ease":b,C=p.style,S=p.properties,A=p.onAnimationEnd,P=y>0?s[y-1]:p,E=S||Object.keys(C);if(typeof x=="function"||x==="spring")return[].concat(lh(m),[o.runJSAnimation.bind(o,{from:P.style,to:C,duration:w,easing:x}),w]);var O=PC(E,w,x),R=tr(tr(tr({},P.style),C),{},{transition:O});return[].concat(lh(m),[R,w,A]).filter(Foe)};return this.manager.start([l].concat(lh(s.reduce(f,[u,Math.max(h,a)])),[i.onAnimationEnd]))}},{key:"runAnimation",value:function(i){this.manager||(this.manager=Poe());var o=i.begin,s=i.duration,a=i.attributeName,l=i.to,c=i.easing,u=i.onAnimationStart,d=i.onAnimationEnd,h=i.steps,f=i.children,g=this.manager;if(this.unSubscribe=g.subscribe(this.handleStyleChange),typeof c=="function"||typeof f=="function"||c==="spring"){this.runJSAnimation(i);return}if(h.length>1){this.runStepAnimation(i);return}var m=a?es({},a,l):l,p=PC(Object.keys(m),s,c);g.start([u,o,tr(tr({},m),{},{transition:p}),s,d])}},{key:"render",value:function(){var i=this.props,o=i.children;i.begin;var s=i.duration;i.attributeName,i.easing;var a=i.isActive;i.steps,i.from,i.to,i.canBegin,i.onAnimationEnd,i.shouldReAnimate,i.onAnimationReStart;var l=tse(i,ese),c=v.Children.count(o),u=this.state.style;if(typeof o=="function")return o(u);if(!a||c===0||s<=0)return o;var d=function(f){var g=f.props,m=g.style,p=m===void 0?{}:m,y=g.className,w=v.cloneElement(f,tr(tr({},l),{},{style:tr(tr({},p),u),className:y}));return w};return c===1?d(v.Children.only(o)):v.createElement("div",null,v.Children.map(o,function(h){return d(h)}))}}]),r}(v.PureComponent);cr.displayName="Animate";cr.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};cr.propTypes={from:Ae.oneOfType([Ae.object,Ae.string]),to:Ae.oneOfType([Ae.object,Ae.string]),attributeName:Ae.string,duration:Ae.number,begin:Ae.number,easing:Ae.oneOfType([Ae.string,Ae.func]),steps:Ae.arrayOf(Ae.shape({duration:Ae.number.isRequired,style:Ae.object.isRequired,easing:Ae.oneOfType([Ae.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),Ae.func]),properties:Ae.arrayOf("string"),onAnimationEnd:Ae.func})),children:Ae.oneOfType([Ae.node,Ae.func]),isActive:Ae.bool,canBegin:Ae.bool,onAnimationEnd:Ae.func,shouldReAnimate:Ae.bool,onAnimationStart:Ae.func,onAnimationReStart:Ae.func};function ia(e){"@babel/helpers - typeof";return ia=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ia(e)}function Fc(){return Fc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Fc.apply(this,arguments)}function gse(e,t){return yse(e)||vse(e,t)||mse(e,t)||pse()}function pse(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
97
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function mse(e,t){if(e){if(typeof e=="string")return MC(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return MC(e,t)}}function MC(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function vse(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function yse(e){if(Array.isArray(e))return e}function DC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function kC(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?DC(Object(r),!0).forEach(function(n){bse(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):DC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function bse(e,t,r){return t=Cse(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Cse(e){var t=wse(e,"string");return ia(t)=="symbol"?t:t+""}function wse(e,t){if(ia(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ia(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var IC=function(t,r,n,i,o){var s=Math.min(Math.abs(n)/2,Math.abs(i)/2),a=i>=0?1:-1,l=n>=0?1:-1,c=i>=0&&n>=0||i<0&&n<0?1:0,u;if(s>0&&o instanceof Array){for(var d=[0,0,0,0],h=0,f=4;h<f;h++)d[h]=o[h]>s?s:o[h];u="M".concat(t,",").concat(r+a*d[0]),d[0]>0&&(u+="A ".concat(d[0],",").concat(d[0],",0,0,").concat(c,",").concat(t+l*d[0],",").concat(r)),u+="L ".concat(t+n-l*d[1],",").concat(r),d[1]>0&&(u+="A ".concat(d[1],",").concat(d[1],",0,0,").concat(c,`,
98
+ `).concat(t+n,",").concat(r+a*d[1])),u+="L ".concat(t+n,",").concat(r+i-a*d[2]),d[2]>0&&(u+="A ".concat(d[2],",").concat(d[2],",0,0,").concat(c,`,
99
+ `).concat(t+n-l*d[2],",").concat(r+i)),u+="L ".concat(t+l*d[3],",").concat(r+i),d[3]>0&&(u+="A ".concat(d[3],",").concat(d[3],",0,0,").concat(c,`,
100
+ `).concat(t,",").concat(r+i-a*d[3])),u+="Z"}else if(s>0&&o===+o&&o>0){var g=Math.min(s,o);u="M ".concat(t,",").concat(r+a*g,`
101
+ A `).concat(g,",").concat(g,",0,0,").concat(c,",").concat(t+l*g,",").concat(r,`
102
+ L `).concat(t+n-l*g,",").concat(r,`
103
+ A `).concat(g,",").concat(g,",0,0,").concat(c,",").concat(t+n,",").concat(r+a*g,`
104
+ L `).concat(t+n,",").concat(r+i-a*g,`
105
+ A `).concat(g,",").concat(g,",0,0,").concat(c,",").concat(t+n-l*g,",").concat(r+i,`
106
+ L `).concat(t+l*g,",").concat(r+i,`
107
+ A `).concat(g,",").concat(g,",0,0,").concat(c,",").concat(t,",").concat(r+i-a*g," Z")}else u="M ".concat(t,",").concat(r," h ").concat(n," v ").concat(i," h ").concat(-n," Z");return u},Sse=function(t,r){if(!t||!r)return!1;var n=t.x,i=t.y,o=r.x,s=r.y,a=r.width,l=r.height;if(Math.abs(a)>0&&Math.abs(l)>0){var c=Math.min(o,o+a),u=Math.max(o,o+a),d=Math.min(s,s+l),h=Math.max(s,s+l);return n>=c&&n<=u&&i>=d&&i<=h}return!1},xse={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},Em=function(t){var r=kC(kC({},xse),t),n=v.useRef(),i=v.useState(-1),o=gse(i,2),s=o[0],a=o[1];v.useEffect(function(){if(n.current&&n.current.getTotalLength)try{var x=n.current.getTotalLength();x&&a(x)}catch{}},[]);var l=r.x,c=r.y,u=r.width,d=r.height,h=r.radius,f=r.className,g=r.animationEasing,m=r.animationDuration,p=r.animationBegin,y=r.isAnimationActive,w=r.isUpdateAnimationActive;if(l!==+l||c!==+c||u!==+u||d!==+d||u===0||d===0)return null;var b=ve("recharts-rectangle",f);return w?v.createElement(cr,{canBegin:s>0,from:{width:u,height:d,x:l,y:c},to:{width:u,height:d,x:l,y:c},duration:m,animationEasing:g,isActive:w},function(x){var C=x.width,S=x.height,A=x.x,P=x.y;return v.createElement(cr,{canBegin:s>0,from:"0px ".concat(s===-1?1:s,"px"),to:"".concat(s,"px 0px"),attributeName:"strokeDasharray",begin:p,duration:m,isActive:y,easing:g},v.createElement("path",Fc({},de(r,!0),{className:b,d:IC(A,P,C,S,h),ref:n})))}):v.createElement("path",Fc({},de(r,!0),{className:b,d:IC(l,c,u,d,h)}))};function Xf(){return Xf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Xf.apply(this,arguments)}var zu=function(t){var r=t.cx,n=t.cy,i=t.r,o=t.className,s=ve("recharts-dot",o);return r===+r&&n===+n&&i===+i?v.createElement("circle",Xf({},de(t,!1),ql(t),{className:s,cx:r,cy:n,r:i})):null};function oa(e){"@babel/helpers - typeof";return oa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},oa(e)}var Ase=["x","y","top","left","width","height","className"];function Zf(){return Zf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Zf.apply(this,arguments)}function _C(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Pse(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?_C(Object(r),!0).forEach(function(n){Rse(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):_C(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Rse(e,t,r){return t=Ese(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ese(e){var t=Tse(e,"string");return oa(t)=="symbol"?t:t+""}function Tse(e,t){if(oa(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(oa(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Fse(e,t){if(e==null)return{};var r=Ose(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Ose(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var Mse=function(t,r,n,i,o,s){return"M".concat(t,",").concat(o,"v").concat(i,"M").concat(s,",").concat(r,"h").concat(n)},Dse=function(t){var r=t.x,n=r===void 0?0:r,i=t.y,o=i===void 0?0:i,s=t.top,a=s===void 0?0:s,l=t.left,c=l===void 0?0:l,u=t.width,d=u===void 0?0:u,h=t.height,f=h===void 0?0:h,g=t.className,m=Fse(t,Ase),p=Pse({x:n,y:o,top:a,left:c,width:d,height:f},m);return!Z(n)||!Z(o)||!Z(d)||!Z(f)||!Z(a)||!Z(c)?null:v.createElement("path",Zf({},de(p,!0),{className:ve("recharts-cross",g),d:Mse(n,o,d,f,a,c)}))},kse=qx,Ise=kse(Object.getPrototypeOf,Object),_se=Ise,Lse=Kr,Bse=_se,zse=qr,Nse="[object Object]",$se=Function.prototype,Hse=Object.prototype,OP=$se.toString,Gse=Hse.hasOwnProperty,Wse=OP.call(Object);function jse(e){if(!zse(e)||Lse(e)!=Nse)return!1;var t=Bse(e);if(t===null)return!0;var r=Gse.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&OP.call(r)==Wse}var Vse=jse;const Use=Le(Vse);var Kse=Kr,qse=qr,Yse="[object Boolean]";function Jse(e){return e===!0||e===!1||qse(e)&&Kse(e)==Yse}var Xse=Jse;const Zse=Le(Xse);function sa(e){"@babel/helpers - typeof";return sa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sa(e)}function Oc(){return Oc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Oc.apply(this,arguments)}function Qse(e,t){return nae(e)||rae(e,t)||tae(e,t)||eae()}function eae(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
108
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function tae(e,t){if(e){if(typeof e=="string")return LC(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return LC(e,t)}}function LC(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function rae(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function nae(e){if(Array.isArray(e))return e}function BC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function zC(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?BC(Object(r),!0).forEach(function(n){iae(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):BC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function iae(e,t,r){return t=oae(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function oae(e){var t=sae(e,"string");return sa(t)=="symbol"?t:t+""}function sae(e,t){if(sa(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(sa(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var NC=function(t,r,n,i,o){var s=n-i,a;return a="M ".concat(t,",").concat(r),a+="L ".concat(t+n,",").concat(r),a+="L ".concat(t+n-s/2,",").concat(r+o),a+="L ".concat(t+n-s/2-i,",").concat(r+o),a+="L ".concat(t,",").concat(r," Z"),a},aae={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},lae=function(t){var r=zC(zC({},aae),t),n=v.useRef(),i=v.useState(-1),o=Qse(i,2),s=o[0],a=o[1];v.useEffect(function(){if(n.current&&n.current.getTotalLength)try{var b=n.current.getTotalLength();b&&a(b)}catch{}},[]);var l=r.x,c=r.y,u=r.upperWidth,d=r.lowerWidth,h=r.height,f=r.className,g=r.animationEasing,m=r.animationDuration,p=r.animationBegin,y=r.isUpdateAnimationActive;if(l!==+l||c!==+c||u!==+u||d!==+d||h!==+h||u===0&&d===0||h===0)return null;var w=ve("recharts-trapezoid",f);return y?v.createElement(cr,{canBegin:s>0,from:{upperWidth:0,lowerWidth:0,height:h,x:l,y:c},to:{upperWidth:u,lowerWidth:d,height:h,x:l,y:c},duration:m,animationEasing:g,isActive:y},function(b){var x=b.upperWidth,C=b.lowerWidth,S=b.height,A=b.x,P=b.y;return v.createElement(cr,{canBegin:s>0,from:"0px ".concat(s===-1?1:s,"px"),to:"".concat(s,"px 0px"),attributeName:"strokeDasharray",begin:p,duration:m,easing:g},v.createElement("path",Oc({},de(r,!0),{className:w,d:NC(A,P,x,C,S),ref:n})))}):v.createElement("g",null,v.createElement("path",Oc({},de(r,!0),{className:w,d:NC(l,c,u,d,h)})))},cae=["option","shapeType","propTransformer","activeClassName","isActive"];function aa(e){"@babel/helpers - typeof";return aa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},aa(e)}function uae(e,t){if(e==null)return{};var r=dae(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function dae(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function $C(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Mc(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?$C(Object(r),!0).forEach(function(n){hae(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):$C(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function hae(e,t,r){return t=fae(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function fae(e){var t=gae(e,"string");return aa(t)=="symbol"?t:t+""}function gae(e,t){if(aa(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(aa(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function pae(e,t){return Mc(Mc({},t),e)}function mae(e,t){return e==="symbols"}function HC(e){var t=e.shapeType,r=e.elementProps;switch(t){case"rectangle":return v.createElement(Em,r);case"trapezoid":return v.createElement(lae,r);case"sector":return v.createElement(CP,r);case"symbols":if(mae(t))return v.createElement(Pu,r);break;default:return null}}function vae(e){return v.isValidElement(e)?e.props:e}function Qf(e){var t=e.option,r=e.shapeType,n=e.propTransformer,i=n===void 0?pae:n,o=e.activeClassName,s=o===void 0?"recharts-active-shape":o,a=e.isActive,l=uae(e,cae),c;if(v.isValidElement(t))c=v.cloneElement(t,Mc(Mc({},l),vae(t)));else if(ge(t))c=t(l);else if(Use(t)&&!Zse(t)){var u=i(t,l);c=v.createElement(HC,{shapeType:r,elementProps:u})}else{var d=l;c=v.createElement(HC,{shapeType:r,elementProps:d})}return a?v.createElement(be,{className:s},c):c}function Nu(e,t){return t!=null&&"trapezoids"in e.props}function $u(e,t){return t!=null&&"sectors"in e.props}function la(e,t){return t!=null&&"points"in e.props}function yae(e,t){var r,n,i=e.x===(t==null||(r=t.labelViewBox)===null||r===void 0?void 0:r.x)||e.x===t.x,o=e.y===(t==null||(n=t.labelViewBox)===null||n===void 0?void 0:n.y)||e.y===t.y;return i&&o}function bae(e,t){var r=e.endAngle===t.endAngle,n=e.startAngle===t.startAngle;return r&&n}function Cae(e,t){var r=e.x===t.x,n=e.y===t.y,i=e.z===t.z;return r&&n&&i}function wae(e,t){var r;return Nu(e,t)?r=yae:$u(e,t)?r=bae:la(e,t)&&(r=Cae),r}function Sae(e,t){var r;return Nu(e,t)?r="trapezoids":$u(e,t)?r="sectors":la(e,t)&&(r="points"),r}function xae(e,t){if(Nu(e,t)){var r;return(r=t.tooltipPayload)===null||r===void 0||(r=r[0])===null||r===void 0||(r=r.payload)===null||r===void 0?void 0:r.payload}if($u(e,t)){var n;return(n=t.tooltipPayload)===null||n===void 0||(n=n[0])===null||n===void 0||(n=n.payload)===null||n===void 0?void 0:n.payload}return la(e,t)?t.payload:{}}function Aae(e){var t=e.activeTooltipItem,r=e.graphicalItem,n=e.itemData,i=Sae(r,t),o=xae(r,t),s=n.filter(function(l,c){var u=Zn(o,l),d=r.props[i].filter(function(g){var m=wae(r,t);return m(g,t)}),h=r.props[i].indexOf(d[d.length-1]),f=c===h;return u&&f}),a=n.indexOf(s[s.length-1]);return a}var Pae=Math.ceil,Rae=Math.max;function Eae(e,t,r,n){for(var i=-1,o=Rae(Pae((t-e)/(r||1)),0),s=Array(o);o--;)s[n?o:++i]=e,e+=r;return s}var Tae=Eae,Fae=hA,GC=1/0,Oae=17976931348623157e292;function Mae(e){if(!e)return e===0?e:0;if(e=Fae(e),e===GC||e===-GC){var t=e<0?-1:1;return t*Oae}return e===e?e:0}var Dae=Mae,kae=Tae,Iae=Tu,ch=Dae;function _ae(e){return function(t,r,n){return n&&typeof n!="number"&&Iae(t,r,n)&&(r=n=void 0),t=ch(t),r===void 0?(r=t,t=0):r=ch(r),n=n===void 0?t<r?1:-1:ch(n),kae(t,r,n,e)}}var Lae=_ae,Bae=Lae,zae=Bae(),Nae=zae;const Dc=Le(Nae);function ca(e){"@babel/helpers - typeof";return ca=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ca(e)}function WC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function jC(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?WC(Object(r),!0).forEach(function(n){MP(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):WC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function MP(e,t,r){return t=$ae(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function $ae(e){var t=Hae(e,"string");return ca(t)=="symbol"?t:t+""}function Hae(e,t){if(ca(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ca(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Gae=["Webkit","Moz","O","ms"],Wae=function(t,r){var n=t.replace(/(\w)/,function(o){return o.toUpperCase()}),i=Gae.reduce(function(o,s){return jC(jC({},o),{},MP({},s+n,r))},{});return i[t]=r,i};function Ji(e){"@babel/helpers - typeof";return Ji=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ji(e)}function kc(){return kc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},kc.apply(this,arguments)}function VC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function uh(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?VC(Object(r),!0).forEach(function(n){It(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):VC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function jae(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function UC(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,kP(n.key),n)}}function Vae(e,t,r){return t&&UC(e.prototype,t),r&&UC(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function Uae(e,t,r){return t=Ic(t),Kae(e,DP()?Reflect.construct(t,r||[],Ic(e).constructor):t.apply(e,r))}function Kae(e,t){if(t&&(Ji(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return qae(e)}function qae(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function DP(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(DP=function(){return!!e})()}function Ic(e){return Ic=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Ic(e)}function Yae(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&eg(e,t)}function eg(e,t){return eg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},eg(e,t)}function It(e,t,r){return t=kP(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function kP(e){var t=Jae(e,"string");return Ji(t)=="symbol"?t:t+""}function Jae(e,t){if(Ji(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Ji(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Xae=function(t){var r=t.data,n=t.startIndex,i=t.endIndex,o=t.x,s=t.width,a=t.travellerWidth;if(!r||!r.length)return{};var l=r.length,c=ds().domain(Dc(0,l)).range([o,o+s-a]),u=c.domain().map(function(d){return c(d)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:c(n),endX:c(i),scale:c,scaleValues:u}},KC=function(t){return t.changedTouches&&!!t.changedTouches.length},Xi=function(e){function t(r){var n;return jae(this,t),n=Uae(this,t,[r]),It(n,"handleDrag",function(i){n.leaveTimer&&(clearTimeout(n.leaveTimer),n.leaveTimer=null),n.state.isTravellerMoving?n.handleTravellerMove(i):n.state.isSlideMoving&&n.handleSlideDrag(i)}),It(n,"handleTouchMove",function(i){i.changedTouches!=null&&i.changedTouches.length>0&&n.handleDrag(i.changedTouches[0])}),It(n,"handleDragEnd",function(){n.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=n.props,o=i.endIndex,s=i.onDragEnd,a=i.startIndex;s==null||s({endIndex:o,startIndex:a})}),n.detachDragEndListener()}),It(n,"handleLeaveWrapper",function(){(n.state.isTravellerMoving||n.state.isSlideMoving)&&(n.leaveTimer=window.setTimeout(n.handleDragEnd,n.props.leaveTimeOut))}),It(n,"handleEnterSlideOrTraveller",function(){n.setState({isTextActive:!0})}),It(n,"handleLeaveSlideOrTraveller",function(){n.setState({isTextActive:!1})}),It(n,"handleSlideDragStart",function(i){var o=KC(i)?i.changedTouches[0]:i;n.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:o.pageX}),n.attachDragEndListener()}),n.travellerDragStartHandlers={startX:n.handleTravellerDragStart.bind(n,"startX"),endX:n.handleTravellerDragStart.bind(n,"endX")},n.state={},n}return Yae(t,e),Vae(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(n){var i=n.startX,o=n.endX,s=this.state.scaleValues,a=this.props,l=a.gap,c=a.data,u=c.length-1,d=Math.min(i,o),h=Math.max(i,o),f=t.getIndexInRange(s,d),g=t.getIndexInRange(s,h);return{startIndex:f-f%l,endIndex:g===u?u:g-g%l}}},{key:"getTextOfTick",value:function(n){var i=this.props,o=i.data,s=i.tickFormatter,a=i.dataKey,l=tt(o[n],a,n);return ge(s)?s(l,n):l}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(n){var i=this.state,o=i.slideMoveStartX,s=i.startX,a=i.endX,l=this.props,c=l.x,u=l.width,d=l.travellerWidth,h=l.startIndex,f=l.endIndex,g=l.onChange,m=n.pageX-o;m>0?m=Math.min(m,c+u-d-a,c+u-d-s):m<0&&(m=Math.max(m,c-s,c-a));var p=this.getIndex({startX:s+m,endX:a+m});(p.startIndex!==h||p.endIndex!==f)&&g&&g(p),this.setState({startX:s+m,endX:a+m,slideMoveStartX:n.pageX})}},{key:"handleTravellerDragStart",value:function(n,i){var o=KC(i)?i.changedTouches[0]:i;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:n,brushMoveStartX:o.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(n){var i=this.state,o=i.brushMoveStartX,s=i.movingTravellerId,a=i.endX,l=i.startX,c=this.state[s],u=this.props,d=u.x,h=u.width,f=u.travellerWidth,g=u.onChange,m=u.gap,p=u.data,y={startX:this.state.startX,endX:this.state.endX},w=n.pageX-o;w>0?w=Math.min(w,d+h-f-c):w<0&&(w=Math.max(w,d-c)),y[s]=c+w;var b=this.getIndex(y),x=b.startIndex,C=b.endIndex,S=function(){var P=p.length-1;return s==="startX"&&(a>l?x%m===0:C%m===0)||a<l&&C===P||s==="endX"&&(a>l?C%m===0:x%m===0)||a>l&&C===P};this.setState(It(It({},s,c+w),"brushMoveStartX",n.pageX),function(){g&&S()&&g(b)})}},{key:"handleTravellerMoveKeyboard",value:function(n,i){var o=this,s=this.state,a=s.scaleValues,l=s.startX,c=s.endX,u=this.state[i],d=a.indexOf(u);if(d!==-1){var h=d+n;if(!(h===-1||h>=a.length)){var f=a[h];i==="startX"&&f>=c||i==="endX"&&f<=l||this.setState(It({},i,f),function(){o.props.onChange(o.getIndex({startX:o.state.startX,endX:o.state.endX}))})}}}},{key:"renderBackground",value:function(){var n=this.props,i=n.x,o=n.y,s=n.width,a=n.height,l=n.fill,c=n.stroke;return v.createElement("rect",{stroke:c,fill:l,x:i,y:o,width:s,height:a})}},{key:"renderPanorama",value:function(){var n=this.props,i=n.x,o=n.y,s=n.width,a=n.height,l=n.data,c=n.children,u=n.padding,d=v.Children.only(c);return d?v.cloneElement(d,{x:i,y:o,width:s,height:a,margin:u,compact:!0,data:l}):null}},{key:"renderTravellerLayer",value:function(n,i){var o,s,a=this,l=this.props,c=l.y,u=l.travellerWidth,d=l.height,h=l.traveller,f=l.ariaLabel,g=l.data,m=l.startIndex,p=l.endIndex,y=Math.max(n,this.props.x),w=uh(uh({},de(this.props,!1)),{},{x:y,y:c,width:u,height:d}),b=f||"Min value: ".concat((o=g[m])===null||o===void 0?void 0:o.name,", Max value: ").concat((s=g[p])===null||s===void 0?void 0:s.name);return v.createElement(be,{tabIndex:0,role:"slider","aria-label":b,"aria-valuenow":n,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(C){["ArrowLeft","ArrowRight"].includes(C.key)&&(C.preventDefault(),C.stopPropagation(),a.handleTravellerMoveKeyboard(C.key==="ArrowRight"?1:-1,i))},onFocus:function(){a.setState({isTravellerFocused:!0})},onBlur:function(){a.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(h,w))}},{key:"renderSlide",value:function(n,i){var o=this.props,s=o.y,a=o.height,l=o.stroke,c=o.travellerWidth,u=Math.min(n,i)+c,d=Math.max(Math.abs(i-n)-c,0);return v.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:l,fillOpacity:.2,x:u,y:s,width:d,height:a})}},{key:"renderText",value:function(){var n=this.props,i=n.startIndex,o=n.endIndex,s=n.y,a=n.height,l=n.travellerWidth,c=n.stroke,u=this.state,d=u.startX,h=u.endX,f=5,g={pointerEvents:"none",fill:c};return v.createElement(be,{className:"recharts-brush-texts"},v.createElement(lc,kc({textAnchor:"end",verticalAnchor:"middle",x:Math.min(d,h)-f,y:s+a/2},g),this.getTextOfTick(i)),v.createElement(lc,kc({textAnchor:"start",verticalAnchor:"middle",x:Math.max(d,h)+l+f,y:s+a/2},g),this.getTextOfTick(o)))}},{key:"render",value:function(){var n=this.props,i=n.data,o=n.className,s=n.children,a=n.x,l=n.y,c=n.width,u=n.height,d=n.alwaysShowText,h=this.state,f=h.startX,g=h.endX,m=h.isTextActive,p=h.isSlideMoving,y=h.isTravellerMoving,w=h.isTravellerFocused;if(!i||!i.length||!Z(a)||!Z(l)||!Z(c)||!Z(u)||c<=0||u<=0)return null;var b=ve("recharts-brush",o),x=v.Children.count(s)===1,C=Wae("userSelect","none");return v.createElement(be,{className:b,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:C},this.renderBackground(),x&&this.renderPanorama(),this.renderSlide(f,g),this.renderTravellerLayer(f,"startX"),this.renderTravellerLayer(g,"endX"),(m||p||y||w||d)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(n){var i=n.x,o=n.y,s=n.width,a=n.height,l=n.stroke,c=Math.floor(o+a/2)-1;return v.createElement(v.Fragment,null,v.createElement("rect",{x:i,y:o,width:s,height:a,fill:l,stroke:"none"}),v.createElement("line",{x1:i+1,y1:c,x2:i+s-1,y2:c,fill:"none",stroke:"#fff"}),v.createElement("line",{x1:i+1,y1:c+2,x2:i+s-1,y2:c+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(n,i){var o;return v.isValidElement(n)?o=v.cloneElement(n,i):ge(n)?o=n(i):o=t.renderDefaultTraveller(i),o}},{key:"getDerivedStateFromProps",value:function(n,i){var o=n.data,s=n.width,a=n.x,l=n.travellerWidth,c=n.updateId,u=n.startIndex,d=n.endIndex;if(o!==i.prevData||c!==i.prevUpdateId)return uh({prevData:o,prevTravellerWidth:l,prevUpdateId:c,prevX:a,prevWidth:s},o&&o.length?Xae({data:o,width:s,x:a,travellerWidth:l,startIndex:u,endIndex:d}):{scale:null,scaleValues:null});if(i.scale&&(s!==i.prevWidth||a!==i.prevX||l!==i.prevTravellerWidth)){i.scale.range([a,a+s-l]);var h=i.scale.domain().map(function(f){return i.scale(f)});return{prevData:o,prevTravellerWidth:l,prevUpdateId:c,prevX:a,prevWidth:s,startX:i.scale(n.startIndex),endX:i.scale(n.endIndex),scaleValues:h}}return null}},{key:"getIndexInRange",value:function(n,i){for(var o=n.length,s=0,a=o-1;a-s>1;){var l=Math.floor((s+a)/2);n[l]>i?a=l:s=l}return i>=n[a]?a:s}}])}(v.PureComponent);It(Xi,"displayName","Brush");It(Xi,"defaultProps",{height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1});var Zae=Xp;function Qae(e,t){var r;return Zae(e,function(n,i,o){return r=t(n,i,o),!r}),!!r}var ele=Qae,tle=$x,rle=Mo,nle=ele,ile=Mt,ole=Tu;function sle(e,t,r){var n=ile(e)?tle:nle;return r&&ole(e,t,r)&&(t=void 0),n(e,rle(t))}var ale=sle;const lle=Le(ale);var wr=function(t,r){var n=t.alwaysShow,i=t.ifOverflow;return n&&(i="extendDomain"),i===r},qC=aA;function cle(e,t,r){t=="__proto__"&&qC?qC(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var ule=cle,dle=ule,hle=oA,fle=Mo;function gle(e,t){var r={};return t=fle(t),hle(e,function(n,i,o){dle(r,i,t(n,i,o))}),r}var ple=gle;const mle=Le(ple);function vle(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(!t(e[r],r,e))return!1;return!0}var yle=vle,ble=Xp;function Cle(e,t){var r=!0;return ble(e,function(n,i,o){return r=!!t(n,i,o),r}),r}var wle=Cle,Sle=yle,xle=wle,Ale=Mo,Ple=Mt,Rle=Tu;function Ele(e,t,r){var n=Ple(e)?Sle:xle;return r&&Rle(e,t,r)&&(t=void 0),n(e,Ale(t))}var Tle=Ele;const Fle=Le(Tle);var Ole=["x","y"];function Zi(e){"@babel/helpers - typeof";return Zi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zi(e)}function tg(){return tg=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},tg.apply(this,arguments)}function YC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Xo(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?YC(Object(r),!0).forEach(function(n){Mle(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):YC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Mle(e,t,r){return t=Dle(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Dle(e){var t=kle(e,"string");return Zi(t)=="symbol"?t:t+""}function kle(e,t){if(Zi(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Zi(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ile(e,t){if(e==null)return{};var r=_le(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function _le(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Lle(e,t){var r=e.x,n=e.y,i=Ile(e,Ole),o="".concat(r),s=parseInt(o,10),a="".concat(n),l=parseInt(a,10),c="".concat(t.height||i.height),u=parseInt(c,10),d="".concat(t.width||i.width),h=parseInt(d,10);return Xo(Xo(Xo(Xo(Xo({},t),i),s?{x:s}:{}),l?{y:l}:{}),{},{height:u,width:h,name:t.name,radius:t.radius})}function JC(e){return v.createElement(Qf,tg({shapeType:"rectangle",propTransformer:Lle,activeClassName:"recharts-active-bar"},e))}var Ble=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(n,i){if(typeof t=="number")return t;var o=typeof n=="number";return o?t(n,i):(o||(process.env.NODE_ENV!=="production"?Pt(!1,"minPointSize callback function received a value with type of ".concat(Zi(n),". Currently only numbers are supported.")):Pt()),r)}},zle=["value","background"],IP;function Qi(e){"@babel/helpers - typeof";return Qi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qi(e)}function Nle(e,t){if(e==null)return{};var r=$le(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function $le(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function _c(){return _c=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},_c.apply(this,arguments)}function XC(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ye(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?XC(Object(r),!0).forEach(function(n){rn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):XC(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Hle(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ZC(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,LP(n.key),n)}}function Gle(e,t,r){return t&&ZC(e.prototype,t),r&&ZC(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function Wle(e,t,r){return t=Lc(t),jle(e,_P()?Reflect.construct(t,r||[],Lc(e).constructor):t.apply(e,r))}function jle(e,t){if(t&&(Qi(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Vle(e)}function Vle(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _P(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(_P=function(){return!!e})()}function Lc(e){return Lc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Lc(e)}function Ule(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&rg(e,t)}function rg(e,t){return rg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},rg(e,t)}function rn(e,t,r){return t=LP(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function LP(e){var t=Kle(e,"string");return Qi(t)=="symbol"?t:t+""}function Kle(e,t){if(Qi(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Qi(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var We=function(e){function t(){var r;Hle(this,t);for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];return r=Wle(this,t,[].concat(i)),rn(r,"state",{isAnimationFinished:!1}),rn(r,"id",oi("recharts-bar-")),rn(r,"handleAnimationEnd",function(){var s=r.props.onAnimationEnd;r.setState({isAnimationFinished:!0}),s&&s()}),rn(r,"handleAnimationStart",function(){var s=r.props.onAnimationStart;r.setState({isAnimationFinished:!1}),s&&s()}),r}return Ule(t,e),Gle(t,[{key:"renderRectanglesStatically",value:function(n){var i=this,o=this.props,s=o.shape,a=o.dataKey,l=o.activeIndex,c=o.activeBar,u=de(this.props,!1);return n&&n.map(function(d,h){var f=h===l,g=f?c:s,m=Ye(Ye(Ye({},u),d),{},{isActive:f,option:g,index:h,dataKey:a,onAnimationStart:i.handleAnimationStart,onAnimationEnd:i.handleAnimationEnd});return v.createElement(be,_c({className:"recharts-bar-rectangle"},Is(i.props,d,h),{key:"rectangle-".concat(d==null?void 0:d.x,"-").concat(d==null?void 0:d.y,"-").concat(d==null?void 0:d.value,"-").concat(h)}),v.createElement(JC,m))})}},{key:"renderRectanglesWithAnimation",value:function(){var n=this,i=this.props,o=i.data,s=i.layout,a=i.isAnimationActive,l=i.animationBegin,c=i.animationDuration,u=i.animationEasing,d=i.animationId,h=this.state.prevData;return v.createElement(cr,{begin:l,duration:c,isActive:a,easing:u,from:{t:0},to:{t:1},key:"bar-".concat(d),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(f){var g=f.t,m=o.map(function(p,y){var w=h&&h[y];if(w){var b=Ue(w.x,p.x),x=Ue(w.y,p.y),C=Ue(w.width,p.width),S=Ue(w.height,p.height);return Ye(Ye({},p),{},{x:b(g),y:x(g),width:C(g),height:S(g)})}if(s==="horizontal"){var A=Ue(0,p.height),P=A(g);return Ye(Ye({},p),{},{y:p.y+p.height-P,height:P})}var E=Ue(0,p.width),O=E(g);return Ye(Ye({},p),{},{width:O})});return v.createElement(be,null,n.renderRectanglesStatically(m))})}},{key:"renderRectangles",value:function(){var n=this.props,i=n.data,o=n.isAnimationActive,s=this.state.prevData;return o&&i&&i.length&&(!s||!Zn(s,i))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(i)}},{key:"renderBackground",value:function(){var n=this,i=this.props,o=i.data,s=i.dataKey,a=i.activeIndex,l=de(this.props.background,!1);return o.map(function(c,u){c.value;var d=c.background,h=Nle(c,zle);if(!d)return null;var f=Ye(Ye(Ye(Ye(Ye({},h),{},{fill:"#eee"},d),l),Is(n.props,c,u)),{},{onAnimationStart:n.handleAnimationStart,onAnimationEnd:n.handleAnimationEnd,dataKey:s,index:u,className:"recharts-bar-background-rectangle"});return v.createElement(JC,_c({key:"background-bar-".concat(u),option:n.props.background,isActive:u===a},f))})}},{key:"renderErrorBar",value:function(n,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,s=o.data,a=o.xAxis,l=o.yAxis,c=o.layout,u=o.children,d=Tt(u,_o);if(!d)return null;var h=c==="vertical"?s[0].height/2:s[0].width/2,f=function(p,y){var w=Array.isArray(p.value)?p.value[1]:p.value;return{x:p.x,y:p.y,value:w,errorVal:tt(p,y)}},g={clipPath:n?"url(#clipPath-".concat(i,")"):null};return v.createElement(be,g,d.map(function(m){return v.cloneElement(m,{key:"error-bar-".concat(i,"-").concat(m.props.dataKey),data:s,xAxis:a,yAxis:l,layout:c,offset:h,dataPointFormatter:f})}))}},{key:"render",value:function(){var n=this.props,i=n.hide,o=n.data,s=n.className,a=n.xAxis,l=n.yAxis,c=n.left,u=n.top,d=n.width,h=n.height,f=n.isAnimationActive,g=n.background,m=n.id;if(i||!o||!o.length)return null;var p=this.state.isAnimationFinished,y=ve("recharts-bar",s),w=a&&a.allowDataOverflow,b=l&&l.allowDataOverflow,x=w||b,C=ue(m)?this.id:m;return v.createElement(be,{className:y},w||b?v.createElement("defs",null,v.createElement("clipPath",{id:"clipPath-".concat(C)},v.createElement("rect",{x:w?c:c-d/2,y:b?u:u-h/2,width:w?d:d*2,height:b?h:h*2}))):null,v.createElement(be,{className:"recharts-bar-rectangles",clipPath:x?"url(#clipPath-".concat(C,")"):null},g?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(x,C),(!f||p)&&Cr.renderCallByParent(this.props,o))}}],[{key:"getDerivedStateFromProps",value:function(n,i){return n.animationId!==i.prevAnimationId?{prevAnimationId:n.animationId,curData:n.data,prevData:i.curData}:n.data!==i.curData?{curData:n.data}:null}}])}(v.PureComponent);IP=We;rn(We,"displayName","Bar");rn(We,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!pn.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"});rn(We,"getComposedData",function(e){var t=e.props,r=e.item,n=e.barPosition,i=e.bandSize,o=e.xAxis,s=e.yAxis,a=e.xAxisTicks,l=e.yAxisTicks,c=e.stackedData,u=e.dataStartIndex,d=e.displayedData,h=e.offset,f=vne(n,r);if(!f)return null;var g=t.layout,m=r.type.defaultProps,p=m!==void 0?Ye(Ye({},m),r.props):r.props,y=p.dataKey,w=p.children,b=p.minPointSize,x=g==="horizontal"?s:o,C=c?x.scale.domain():null,S=Pne({numericAxis:x}),A=Tt(w,em),P=d.map(function(E,O){var R,T,F,I,k,B;c?R=yne(c[u+O],C):(R=tt(E,y),Array.isArray(R)||(R=[S,R]));var N=Ble(b,IP.defaultProps.minPointSize)(R[1],O);if(g==="horizontal"){var z,W=[s.scale(R[0]),s.scale(R[1])],D=W[0],L=W[1];T=Gb({axis:o,ticks:a,bandSize:i,offset:f.offset,entry:E,index:O}),F=(z=L??D)!==null&&z!==void 0?z:void 0,I=f.size;var $=D-L;if(k=Number.isNaN($)?0:$,B={x:T,y:s.y,width:I,height:s.height},Math.abs(N)>0&&Math.abs(k)<Math.abs(N)){var H=ar(k||N)*(Math.abs(N)-Math.abs(k));F-=H,k+=H}}else{var V=[o.scale(R[0]),o.scale(R[1])],X=V[0],Y=V[1];if(T=X,F=Gb({axis:s,ticks:l,bandSize:i,offset:f.offset,entry:E,index:O}),I=Y-X,k=f.size,B={x:o.x,y:F,width:o.width,height:k},Math.abs(N)>0&&Math.abs(I)<Math.abs(N)){var re=ar(I||N)*(Math.abs(N)-Math.abs(I));I+=re}}return Ye(Ye(Ye({},E),{},{x:T,y:F,width:I,height:k,value:c?R:R[1],payload:E,background:B},A&&A[O]&&A[O].props),{},{tooltipPayload:[vP(r,E)],tooltipPosition:{x:T+I/2,y:F+k/2}})});return Ye({data:P,layout:g},h)});function ua(e){"@babel/helpers - typeof";return ua=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ua(e)}function qle(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function QC(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,BP(n.key),n)}}function Yle(e,t,r){return t&&QC(e.prototype,t),r&&QC(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function ew(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function nr(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ew(Object(r),!0).forEach(function(n){Hu(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ew(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Hu(e,t,r){return t=BP(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function BP(e){var t=Jle(e,"string");return ua(t)=="symbol"?t:t+""}function Jle(e,t){if(ua(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ua(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var zP=function(t,r,n,i,o){var s=t.width,a=t.height,l=t.layout,c=t.children,u=Object.keys(r),d={left:n.left,leftMirror:n.left,right:s-n.right,rightMirror:s-n.right,top:n.top,topMirror:n.top,bottom:a-n.bottom,bottomMirror:a-n.bottom},h=!!Lt(c,We);return u.reduce(function(f,g){var m=r[g],p=m.orientation,y=m.domain,w=m.padding,b=w===void 0?{}:w,x=m.mirror,C=m.reversed,S="".concat(p).concat(x?"Mirror":""),A,P,E,O,R;if(m.type==="number"&&(m.padding==="gap"||m.padding==="no-gap")){var T=y[1]-y[0],F=1/0,I=m.categoricalDomain.sort(n5);if(I.forEach(function(V,X){X>0&&(F=Math.min((V||0)-(I[X-1]||0),F))}),Number.isFinite(F)){var k=F/T,B=m.layout==="vertical"?n.height:n.width;if(m.padding==="gap"&&(A=k*B/2),m.padding==="no-gap"){var N=Xn(t.barCategoryGap,k*B),z=k*B/2;A=z-N-(z-N)/B*N}}}i==="xAxis"?P=[n.left+(b.left||0)+(A||0),n.left+n.width-(b.right||0)-(A||0)]:i==="yAxis"?P=l==="horizontal"?[n.top+n.height-(b.bottom||0),n.top+(b.top||0)]:[n.top+(b.top||0)+(A||0),n.top+n.height-(b.bottom||0)-(A||0)]:P=m.range,C&&(P=[P[1],P[0]]);var W=pne(m,o,h),D=W.scale,L=W.realScaleType;D.domain(y).range(P),mne(D);var $=Ane(D,nr(nr({},m),{},{realScaleType:L}));i==="xAxis"?(R=p==="top"&&!x||p==="bottom"&&x,E=n.left,O=d[S]-R*m.height):i==="yAxis"&&(R=p==="left"&&!x||p==="right"&&x,E=d[S]-R*m.width,O=n.top);var H=nr(nr(nr({},m),$),{},{realScaleType:L,x:E,y:O,scale:D,width:i==="xAxis"?n.width:m.width,height:i==="yAxis"?n.height:m.height});return H.bandSize=Sc(H,$),!m.hide&&i==="xAxis"?d[S]+=(R?-1:1)*H.height:m.hide||(d[S]+=(R?-1:1)*H.width),nr(nr({},f),{},Hu({},g,H))},{})},NP=function(t,r){var n=t.x,i=t.y,o=r.x,s=r.y;return{x:Math.min(n,o),y:Math.min(i,s),width:Math.abs(o-n),height:Math.abs(s-i)}},Xle=function(t){var r=t.x1,n=t.y1,i=t.x2,o=t.y2;return NP({x:r,y:n},{x:i,y:o})},$P=function(){function e(t){qle(this,e),this.scale=t}return Yle(e,[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=n.bandAware,o=n.position;if(r!==void 0){if(o)switch(o){case"start":return this.scale(r);case"middle":{var s=this.bandwidth?this.bandwidth()/2:0;return this.scale(r)+s}case"end":{var a=this.bandwidth?this.bandwidth():0;return this.scale(r)+a}default:return this.scale(r)}if(i){var l=this.bandwidth?this.bandwidth()/2:0;return this.scale(r)+l}return this.scale(r)}}},{key:"isInRange",value:function(r){var n=this.range(),i=n[0],o=n[n.length-1];return i<=o?r>=i&&r<=o:r>=o&&r<=i}}],[{key:"create",value:function(r){return new e(r)}}])}();Hu($P,"EPS",1e-4);var Tm=function(t){var r=Object.keys(t).reduce(function(n,i){return nr(nr({},n),{},Hu({},i,$P.create(t[i])))},{});return nr(nr({},r),{},{apply:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=o.bandAware,a=o.position;return mle(i,function(l,c){return r[c].apply(l,{bandAware:s,position:a})})},isInRange:function(i){return Fle(i,function(o,s){return r[s].isInRange(o)})}})};function Zle(e){return(e%180+180)%180}var Qle=function(t){var r=t.width,n=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=Zle(i),s=o*Math.PI/180,a=Math.atan(n/r),l=s>a&&s<Math.PI-a?n/Math.sin(s):r/Math.cos(s);return Math.abs(l)},ece=sj(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return["l",e.left,"t",e.top,"w",e.width,"h",e.height].join("")});function Bc(e){"@babel/helpers - typeof";return Bc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Bc(e)}var HP=v.createContext(void 0),GP=v.createContext(void 0),WP=v.createContext(void 0),tce=v.createContext({}),jP=v.createContext(void 0),VP=v.createContext(0),UP=v.createContext(0),tw=function(t){var r=t.state,n=r.xAxisMap,i=r.yAxisMap,o=r.offset,s=t.clipPathId,a=t.children,l=t.width,c=t.height,u=ece(o);return v.createElement(HP.Provider,{value:n},v.createElement(GP.Provider,{value:i},v.createElement(tce.Provider,{value:o},v.createElement(WP.Provider,{value:u},v.createElement(jP.Provider,{value:s},v.createElement(VP.Provider,{value:c},v.createElement(UP.Provider,{value:l},a)))))))},rce=function(){return v.useContext(jP)};function KP(e){var t=Object.keys(e);return t.length===0?"There are no available ids.":"Available ids are: ".concat(t,".")}var qP=function(t){var r=v.useContext(HP);r==null&&(process.env.NODE_ENV!=="production"?Pt(!1,"Could not find Recharts context; are you sure this is rendered inside a Recharts wrapper component?"):Pt());var n=r[t];return n==null&&(process.env.NODE_ENV!=="production"?Pt(!1,'Could not find xAxis by id "'.concat(t,'" [').concat(Bc(t),"]. ").concat(KP(r))):Pt()),n},YP=function(t){var r=v.useContext(GP);r==null&&(process.env.NODE_ENV!=="production"?Pt(!1,"Could not find Recharts context; are you sure this is rendered inside a Recharts wrapper component?"):Pt());var n=r[t];return n==null&&(process.env.NODE_ENV!=="production"?Pt(!1,'Could not find yAxis by id "'.concat(t,'" [').concat(Bc(t),"]. ").concat(KP(r))):Pt()),n},nce=function(){var t=v.useContext(WP);return t},JP=function(){return v.useContext(UP)},XP=function(){return v.useContext(VP)};function eo(e){"@babel/helpers - typeof";return eo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},eo(e)}function ice(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function oce(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,QP(n.key),n)}}function sce(e,t,r){return t&&oce(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function ace(e,t,r){return t=zc(t),lce(e,ZP()?Reflect.construct(t,r||[],zc(e).constructor):t.apply(e,r))}function lce(e,t){if(t&&(eo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return cce(e)}function cce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ZP(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ZP=function(){return!!e})()}function zc(e){return zc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},zc(e)}function uce(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ng(e,t)}function ng(e,t){return ng=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},ng(e,t)}function rw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function nw(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?rw(Object(r),!0).forEach(function(n){Fm(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):rw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Fm(e,t,r){return t=QP(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function QP(e){var t=dce(e,"string");return eo(t)=="symbol"?t:t+""}function dce(e,t){if(eo(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(eo(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function hce(e,t){return mce(e)||pce(e,t)||gce(e,t)||fce()}function fce(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
109
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function gce(e,t){if(e){if(typeof e=="string")return iw(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return iw(e,t)}}function iw(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function pce(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function mce(e){if(Array.isArray(e))return e}function ig(){return ig=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ig.apply(this,arguments)}var vce=function(t,r){var n;return v.isValidElement(t)?n=v.cloneElement(t,r):ge(t)?n=t(r):n=v.createElement("line",ig({},r,{className:"recharts-reference-line-line"})),n},yce=function(t,r,n,i,o,s,a,l,c){var u=o.x,d=o.y,h=o.width,f=o.height;if(n){var g=c.y,m=t.y.apply(g,{position:s});if(wr(c,"discard")&&!t.y.isInRange(m))return null;var p=[{x:u+h,y:m},{x:u,y:m}];return l==="left"?p.reverse():p}if(r){var y=c.x,w=t.x.apply(y,{position:s});if(wr(c,"discard")&&!t.x.isInRange(w))return null;var b=[{x:w,y:d+f},{x:w,y:d}];return a==="top"?b.reverse():b}if(i){var x=c.segment,C=x.map(function(S){return t.apply(S,{position:s})});return wr(c,"discard")&&lle(C,function(S){return!t.isInRange(S)})?null:C}return null};function bce(e){var t=e.x,r=e.y,n=e.segment,i=e.xAxisId,o=e.yAxisId,s=e.shape,a=e.className,l=e.alwaysShow,c=rce(),u=qP(i),d=YP(o),h=nce();if(!c||!h)return null;Cu(l===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var f=Tm({x:u.scale,y:d.scale}),g=et(t),m=et(r),p=n&&n.length===2,y=yce(f,g,m,p,h,e.position,u.orientation,d.orientation,e);if(!y)return null;var w=hce(y,2),b=w[0],x=b.x,C=b.y,S=w[1],A=S.x,P=S.y,E=wr(e,"hidden")?"url(#".concat(c,")"):void 0,O=nw(nw({clipPath:E},de(e,!0)),{},{x1:x,y1:C,x2:A,y2:P});return v.createElement(be,{className:ve("recharts-reference-line",a)},vce(s,O),ft.renderCallByParent(e,Xle({x1:x,y1:C,x2:A,y2:P})))}var Om=function(e){function t(){return ice(this,t),ace(this,t,arguments)}return uce(t,e),sce(t,[{key:"render",value:function(){return v.createElement(bce,this.props)}}])}(v.Component);Fm(Om,"displayName","ReferenceLine");Fm(Om,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});function og(){return og=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},og.apply(this,arguments)}function to(e){"@babel/helpers - typeof";return to=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},to(e)}function ow(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function sw(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ow(Object(r),!0).forEach(function(n){Gu(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ow(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Cce(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function wce(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,tR(n.key),n)}}function Sce(e,t,r){return t&&wce(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function xce(e,t,r){return t=Nc(t),Ace(e,eR()?Reflect.construct(t,r||[],Nc(e).constructor):t.apply(e,r))}function Ace(e,t){if(t&&(to(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Pce(e)}function Pce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function eR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(eR=function(){return!!e})()}function Nc(e){return Nc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Nc(e)}function Rce(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&sg(e,t)}function sg(e,t){return sg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},sg(e,t)}function Gu(e,t,r){return t=tR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function tR(e){var t=Ece(e,"string");return to(t)=="symbol"?t:t+""}function Ece(e,t){if(to(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(to(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Tce=function(t){var r=t.x,n=t.y,i=t.xAxis,o=t.yAxis,s=Tm({x:i.scale,y:o.scale}),a=s.apply({x:r,y:n},{bandAware:!0});return wr(t,"discard")&&!s.isInRange(a)?null:a},Wu=function(e){function t(){return Cce(this,t),xce(this,t,arguments)}return Rce(t,e),Sce(t,[{key:"render",value:function(){var n=this.props,i=n.x,o=n.y,s=n.r,a=n.alwaysShow,l=n.clipPathId,c=et(i),u=et(o);if(Cu(a===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!c||!u)return null;var d=Tce(this.props);if(!d)return null;var h=d.x,f=d.y,g=this.props,m=g.shape,p=g.className,y=wr(this.props,"hidden")?"url(#".concat(l,")"):void 0,w=sw(sw({clipPath:y},de(this.props,!0)),{},{cx:h,cy:f});return v.createElement(be,{className:ve("recharts-reference-dot",p)},t.renderDot(m,w),ft.renderCallByParent(this.props,{x:h-s,y:f-s,width:2*s,height:2*s}))}}])}(v.Component);Gu(Wu,"displayName","ReferenceDot");Gu(Wu,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1});Gu(Wu,"renderDot",function(e,t){var r;return v.isValidElement(e)?r=v.cloneElement(e,t):ge(e)?r=e(t):r=v.createElement(zu,og({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"})),r});function ag(){return ag=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ag.apply(this,arguments)}function ro(e){"@babel/helpers - typeof";return ro=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ro(e)}function aw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function lw(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?aw(Object(r),!0).forEach(function(n){ju(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):aw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Fce(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Oce(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,nR(n.key),n)}}function Mce(e,t,r){return t&&Oce(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Dce(e,t,r){return t=$c(t),kce(e,rR()?Reflect.construct(t,r||[],$c(e).constructor):t.apply(e,r))}function kce(e,t){if(t&&(ro(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ice(e)}function Ice(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function rR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(rR=function(){return!!e})()}function $c(e){return $c=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},$c(e)}function _ce(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&lg(e,t)}function lg(e,t){return lg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},lg(e,t)}function ju(e,t,r){return t=nR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function nR(e){var t=Lce(e,"string");return ro(t)=="symbol"?t:t+""}function Lce(e,t){if(ro(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ro(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Bce=function(t,r,n,i,o){var s=o.x1,a=o.x2,l=o.y1,c=o.y2,u=o.xAxis,d=o.yAxis;if(!u||!d)return null;var h=Tm({x:u.scale,y:d.scale}),f={x:t?h.x.apply(s,{position:"start"}):h.x.rangeMin,y:n?h.y.apply(l,{position:"start"}):h.y.rangeMin},g={x:r?h.x.apply(a,{position:"end"}):h.x.rangeMax,y:i?h.y.apply(c,{position:"end"}):h.y.rangeMax};return wr(o,"discard")&&(!h.isInRange(f)||!h.isInRange(g))?null:NP(f,g)},Vu=function(e){function t(){return Fce(this,t),Dce(this,t,arguments)}return _ce(t,e),Mce(t,[{key:"render",value:function(){var n=this.props,i=n.x1,o=n.x2,s=n.y1,a=n.y2,l=n.className,c=n.alwaysShow,u=n.clipPathId;Cu(c===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var d=et(i),h=et(o),f=et(s),g=et(a),m=this.props.shape;if(!d&&!h&&!f&&!g&&!m)return null;var p=Bce(d,h,f,g,this.props);if(!p&&!m)return null;var y=wr(this.props,"hidden")?"url(#".concat(u,")"):void 0;return v.createElement(be,{className:ve("recharts-reference-area",l)},t.renderRect(m,lw(lw({clipPath:y},de(this.props,!0)),p)),ft.renderCallByParent(this.props,p))}}])}(v.Component);ju(Vu,"displayName","ReferenceArea");ju(Vu,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1});ju(Vu,"renderRect",function(e,t){var r;return v.isValidElement(e)?r=v.cloneElement(e,t):ge(e)?r=e(t):r=v.createElement(Em,ag({},t,{className:"recharts-reference-area-rect"})),r});function iR(e,t,r){if(t<1)return[];if(t===1&&r===void 0)return e;for(var n=[],i=0;i<e.length;i+=t)n.push(e[i]);return n}function zce(e,t,r){var n={width:e.width+t.width,height:e.height+t.height};return Qle(n,r)}function Nce(e,t,r){var n=r==="width",i=e.x,o=e.y,s=e.width,a=e.height;return t===1?{start:n?i:o,end:n?i+s:o+a}:{start:n?i+s:o+a,end:n?i:o}}function Hc(e,t,r,n,i){if(e*t<e*n||e*t>e*i)return!1;var o=r();return e*(t-e*o/2-n)>=0&&e*(t+e*o/2-i)<=0}function $ce(e,t){return iR(e,t+1)}function Hce(e,t,r,n,i){for(var o=(n||[]).slice(),s=t.start,a=t.end,l=0,c=1,u=s,d=function(){var g=n==null?void 0:n[l];if(g===void 0)return{v:iR(n,c)};var m=l,p,y=function(){return p===void 0&&(p=r(g,m)),p},w=g.coordinate,b=l===0||Hc(e,w,y,u,a);b||(l=0,u=s,c+=1),b&&(u=w+e*(y()/2+i),l+=c)},h;c<=o.length;)if(h=d(),h)return h.v;return[]}function da(e){"@babel/helpers - typeof";return da=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},da(e)}function cw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function dt(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?cw(Object(r),!0).forEach(function(n){Gce(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):cw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Gce(e,t,r){return t=Wce(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Wce(e){var t=jce(e,"string");return da(t)=="symbol"?t:t+""}function jce(e,t){if(da(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(da(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Vce(e,t,r,n,i){for(var o=(n||[]).slice(),s=o.length,a=t.start,l=t.end,c=function(h){var f=o[h],g,m=function(){return g===void 0&&(g=r(f,h)),g};if(h===s-1){var p=e*(f.coordinate+e*m()/2-l);o[h]=f=dt(dt({},f),{},{tickCoord:p>0?f.coordinate-p*e:f.coordinate})}else o[h]=f=dt(dt({},f),{},{tickCoord:f.coordinate});var y=Hc(e,f.tickCoord,m,a,l);y&&(l=f.tickCoord-e*(m()/2+i),o[h]=dt(dt({},f),{},{isShow:!0}))},u=s-1;u>=0;u--)c(u);return o}function Uce(e,t,r,n,i,o){var s=(n||[]).slice(),a=s.length,l=t.start,c=t.end;if(o){var u=n[a-1],d=r(u,a-1),h=e*(u.coordinate+e*d/2-c);s[a-1]=u=dt(dt({},u),{},{tickCoord:h>0?u.coordinate-h*e:u.coordinate});var f=Hc(e,u.tickCoord,function(){return d},l,c);f&&(c=u.tickCoord-e*(d/2+i),s[a-1]=dt(dt({},u),{},{isShow:!0}))}for(var g=o?a-1:a,m=function(w){var b=s[w],x,C=function(){return x===void 0&&(x=r(b,w)),x};if(w===0){var S=e*(b.coordinate-e*C()/2-l);s[w]=b=dt(dt({},b),{},{tickCoord:S<0?b.coordinate-S*e:b.coordinate})}else s[w]=b=dt(dt({},b),{},{tickCoord:b.coordinate});var A=Hc(e,b.tickCoord,C,l,c);A&&(l=b.tickCoord+e*(C()/2+i),s[w]=dt(dt({},b),{},{isShow:!0}))},p=0;p<g;p++)m(p);return s}function Kce(e,t,r){var n=e.tick,i=e.ticks,o=e.viewBox,s=e.minTickGap,a=e.orientation,l=e.interval,c=e.tickFormatter,u=e.unit,d=e.angle;if(!i||!i.length||!n)return[];if(Z(l)||pn.isSsr)return $ce(i,typeof l=="number"&&Z(l)?l:0);var h=[],f=a==="top"||a==="bottom"?"width":"height",g=u&&f==="width"?us(u,{fontSize:t,letterSpacing:r}):{width:0,height:0},m=function(b,x){var C=ge(c)?c(b.value,x):b.value;return f==="width"?zce(us(C,{fontSize:t,letterSpacing:r}),g,d):us(C,{fontSize:t,letterSpacing:r})[f]},p=i.length>=2?ar(i[1].coordinate-i[0].coordinate):1,y=Nce(o,p,f);return l==="equidistantPreserveStart"?Hce(p,y,m,i,s):(l==="preserveStart"||l==="preserveStartEnd"?h=Uce(p,y,m,i,s,l==="preserveStartEnd"):h=Vce(p,y,m,i,s),h.filter(function(w){return w.isShow}))}var qce=["viewBox"],Yce=["viewBox"],Jce=["ticks"];function no(e){"@babel/helpers - typeof";return no=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},no(e)}function yi(){return yi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},yi.apply(this,arguments)}function uw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function yt(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?uw(Object(r),!0).forEach(function(n){Mm(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):uw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function dh(e,t){if(e==null)return{};var r=Xce(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Xce(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Zce(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function dw(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,sR(n.key),n)}}function Qce(e,t,r){return t&&dw(e.prototype,t),r&&dw(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function eue(e,t,r){return t=Gc(t),tue(e,oR()?Reflect.construct(t,r||[],Gc(e).constructor):t.apply(e,r))}function tue(e,t){if(t&&(no(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return rue(e)}function rue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function oR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(oR=function(){return!!e})()}function Gc(e){return Gc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Gc(e)}function nue(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&cg(e,t)}function cg(e,t){return cg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},cg(e,t)}function Mm(e,t,r){return t=sR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function sR(e){var t=iue(e,"string");return no(t)=="symbol"?t:t+""}function iue(e,t){if(no(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(no(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Uu=function(e){function t(r){var n;return Zce(this,t),n=eue(this,t,[r]),n.state={fontSize:"",letterSpacing:""},n}return nue(t,e),Qce(t,[{key:"shouldComponentUpdate",value:function(n,i){var o=n.viewBox,s=dh(n,qce),a=this.props,l=a.viewBox,c=dh(a,Yce);return!Fi(o,l)||!Fi(s,c)||!Fi(i,this.state)}},{key:"componentDidMount",value:function(){var n=this.layerReference;if(n){var i=n.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];i&&this.setState({fontSize:window.getComputedStyle(i).fontSize,letterSpacing:window.getComputedStyle(i).letterSpacing})}}},{key:"getTickLineCoord",value:function(n){var i=this.props,o=i.x,s=i.y,a=i.width,l=i.height,c=i.orientation,u=i.tickSize,d=i.mirror,h=i.tickMargin,f,g,m,p,y,w,b=d?-1:1,x=n.tickSize||u,C=Z(n.tickCoord)?n.tickCoord:n.coordinate;switch(c){case"top":f=g=n.coordinate,p=s+ +!d*l,m=p-b*x,w=m-b*h,y=C;break;case"left":m=p=n.coordinate,g=o+ +!d*a,f=g-b*x,y=f-b*h,w=C;break;case"right":m=p=n.coordinate,g=o+ +d*a,f=g+b*x,y=f+b*h,w=C;break;default:f=g=n.coordinate,p=s+ +d*l,m=p+b*x,w=m+b*h,y=C;break}return{line:{x1:f,y1:m,x2:g,y2:p},tick:{x:y,y:w}}}},{key:"getTickTextAnchor",value:function(){var n=this.props,i=n.orientation,o=n.mirror,s;switch(i){case"left":s=o?"start":"end";break;case"right":s=o?"end":"start";break;default:s="middle";break}return s}},{key:"getTickVerticalAnchor",value:function(){var n=this.props,i=n.orientation,o=n.mirror,s="end";switch(i){case"left":case"right":s="middle";break;case"top":s=o?"start":"end";break;default:s=o?"end":"start";break}return s}},{key:"renderAxisLine",value:function(){var n=this.props,i=n.x,o=n.y,s=n.width,a=n.height,l=n.orientation,c=n.mirror,u=n.axisLine,d=yt(yt(yt({},de(this.props,!1)),de(u,!1)),{},{fill:"none"});if(l==="top"||l==="bottom"){var h=+(l==="top"&&!c||l==="bottom"&&c);d=yt(yt({},d),{},{x1:i,y1:o+h*a,x2:i+s,y2:o+h*a})}else{var f=+(l==="left"&&!c||l==="right"&&c);d=yt(yt({},d),{},{x1:i+f*s,y1:o,x2:i+f*s,y2:o+a})}return v.createElement("line",yi({},d,{className:ve("recharts-cartesian-axis-line",Yt(u,"className"))}))}},{key:"renderTicks",value:function(n,i,o){var s=this,a=this.props,l=a.tickLine,c=a.stroke,u=a.tick,d=a.tickFormatter,h=a.unit,f=Kce(yt(yt({},this.props),{},{ticks:n}),i,o),g=this.getTickTextAnchor(),m=this.getTickVerticalAnchor(),p=de(this.props,!1),y=de(u,!1),w=yt(yt({},p),{},{fill:"none"},de(l,!1)),b=f.map(function(x,C){var S=s.getTickLineCoord(x),A=S.line,P=S.tick,E=yt(yt(yt(yt({textAnchor:g,verticalAnchor:m},p),{},{stroke:"none",fill:c},y),P),{},{index:C,payload:x,visibleTicksCount:f.length,tickFormatter:d});return v.createElement(be,yi({className:"recharts-cartesian-axis-tick",key:"tick-".concat(x.value,"-").concat(x.coordinate,"-").concat(x.tickCoord)},Is(s.props,x,C)),l&&v.createElement("line",yi({},w,A,{className:ve("recharts-cartesian-axis-tick-line",Yt(l,"className"))})),u&&t.renderTickItem(u,E,"".concat(ge(d)?d(x.value,C):x.value).concat(h||"")))});return v.createElement("g",{className:"recharts-cartesian-axis-ticks"},b)}},{key:"render",value:function(){var n=this,i=this.props,o=i.axisLine,s=i.width,a=i.height,l=i.ticksGenerator,c=i.className,u=i.hide;if(u)return null;var d=this.props,h=d.ticks,f=dh(d,Jce),g=h;return ge(l)&&(g=h&&h.length>0?l(this.props):l(f)),s<=0||a<=0||!g||!g.length?null:v.createElement(be,{className:ve("recharts-cartesian-axis",c),ref:function(p){n.layerReference=p}},o&&this.renderAxisLine(),this.renderTicks(g,this.state.fontSize,this.state.letterSpacing),ft.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(n,i,o){var s;return v.isValidElement(n)?s=v.cloneElement(n,i):ge(n)?s=n(i):s=v.createElement(lc,yi({},i,{className:"recharts-cartesian-axis-tick-value"}),o),s}}])}(v.Component);Mm(Uu,"displayName","CartesianAxis");Mm(Uu,"defaultProps",{x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd"});var oue=["type","layout","connectNulls","ref"],sue=["key"];function io(e){"@babel/helpers - typeof";return io=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},io(e)}function hw(e,t){if(e==null)return{};var r=aue(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function aue(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function gs(){return gs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},gs.apply(this,arguments)}function fw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function kt(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?fw(Object(r),!0).forEach(function(n){ir(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):fw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function fi(e){return due(e)||uue(e)||cue(e)||lue()}function lue(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
110
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cue(e,t){if(e){if(typeof e=="string")return ug(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ug(e,t)}}function uue(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function due(e){if(Array.isArray(e))return ug(e)}function ug(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function hue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function gw(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,lR(n.key),n)}}function fue(e,t,r){return t&&gw(e.prototype,t),r&&gw(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function gue(e,t,r){return t=Wc(t),pue(e,aR()?Reflect.construct(t,r||[],Wc(e).constructor):t.apply(e,r))}function pue(e,t){if(t&&(io(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return mue(e)}function mue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function aR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(aR=function(){return!!e})()}function Wc(e){return Wc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Wc(e)}function vue(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&dg(e,t)}function dg(e,t){return dg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},dg(e,t)}function ir(e,t,r){return t=lR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function lR(e){var t=yue(e,"string");return io(t)=="symbol"?t:t+""}function yue(e,t){if(io(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(io(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var fr=function(e){function t(){var r;hue(this,t);for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];return r=gue(this,t,[].concat(i)),ir(r,"state",{isAnimationFinished:!0,totalLength:0}),ir(r,"generateSimpleStrokeDasharray",function(s,a){return"".concat(a,"px ").concat(s-a,"px")}),ir(r,"getStrokeDasharray",function(s,a,l){var c=l.reduce(function(y,w){return y+w});if(!c)return r.generateSimpleStrokeDasharray(a,s);for(var u=Math.floor(s/c),d=s%c,h=a-s,f=[],g=0,m=0;g<l.length;m+=l[g],++g)if(m+l[g]>d){f=[].concat(fi(l.slice(0,g)),[d-m]);break}var p=f.length%2===0?[0,h]:[h];return[].concat(fi(t.repeat(l,u)),fi(f),p).map(function(y){return"".concat(y,"px")}).join(", ")}),ir(r,"id",oi("recharts-line-")),ir(r,"pathRef",function(s){r.mainCurve=s}),ir(r,"handleAnimationEnd",function(){r.setState({isAnimationFinished:!0}),r.props.onAnimationEnd&&r.props.onAnimationEnd()}),ir(r,"handleAnimationStart",function(){r.setState({isAnimationFinished:!1}),r.props.onAnimationStart&&r.props.onAnimationStart()}),r}return vue(t,e),fue(t,[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var n=this.getTotalLength();this.setState({totalLength:n})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var n=this.getTotalLength();n!==this.state.totalLength&&this.setState({totalLength:n})}}},{key:"getTotalLength",value:function(){var n=this.mainCurve;try{return n&&n.getTotalLength&&n.getTotalLength()||0}catch{return 0}}},{key:"renderErrorBar",value:function(n,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,s=o.points,a=o.xAxis,l=o.yAxis,c=o.layout,u=o.children,d=Tt(u,_o);if(!d)return null;var h=function(m,p){return{x:m.x,y:m.y,value:m.value,errorVal:tt(m.payload,p)}},f={clipPath:n?"url(#clipPath-".concat(i,")"):null};return v.createElement(be,f,d.map(function(g){return v.cloneElement(g,{key:"bar-".concat(g.props.dataKey),data:s,xAxis:a,yAxis:l,layout:c,dataPointFormatter:h})}))}},{key:"renderDots",value:function(n,i,o){var s=this.props.isAnimationActive;if(s&&!this.state.isAnimationFinished)return null;var a=this.props,l=a.dot,c=a.points,u=a.dataKey,d=de(this.props,!1),h=de(l,!0),f=c.map(function(m,p){var y=kt(kt(kt({key:"dot-".concat(p),r:3},d),h),{},{index:p,cx:m.x,cy:m.y,value:m.value,dataKey:u,payload:m.payload,points:c});return t.renderDotItem(l,y)}),g={clipPath:n?"url(#clipPath-".concat(i?"":"dots-").concat(o,")"):null};return v.createElement(be,gs({className:"recharts-line-dots",key:"dots"},g),f)}},{key:"renderCurveStatically",value:function(n,i,o,s){var a=this.props,l=a.type,c=a.layout,u=a.connectNulls;a.ref;var d=hw(a,oue),h=kt(kt(kt({},de(d,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:i?"url(#clipPath-".concat(o,")"):null,points:n},s),{},{type:l,layout:c,connectNulls:u});return v.createElement($n,gs({},h,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(n,i){var o=this,s=this.props,a=s.points,l=s.strokeDasharray,c=s.isAnimationActive,u=s.animationBegin,d=s.animationDuration,h=s.animationEasing,f=s.animationId,g=s.animateNewValues,m=s.width,p=s.height,y=this.state,w=y.prevPoints,b=y.totalLength;return v.createElement(cr,{begin:u,duration:d,isActive:c,easing:h,from:{t:0},to:{t:1},key:"line-".concat(f),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(x){var C=x.t;if(w){var S=w.length/a.length,A=a.map(function(T,F){var I=Math.floor(F*S);if(w[I]){var k=w[I],B=Ue(k.x,T.x),N=Ue(k.y,T.y);return kt(kt({},T),{},{x:B(C),y:N(C)})}if(g){var z=Ue(m*2,T.x),W=Ue(p/2,T.y);return kt(kt({},T),{},{x:z(C),y:W(C)})}return kt(kt({},T),{},{x:T.x,y:T.y})});return o.renderCurveStatically(A,n,i)}var P=Ue(0,b),E=P(C),O;if(l){var R="".concat(l).split(/[,\s]+/gim).map(function(T){return parseFloat(T)});O=o.getStrokeDasharray(E,b,R)}else O=o.generateSimpleStrokeDasharray(b,E);return o.renderCurveStatically(a,n,i,{strokeDasharray:O})})}},{key:"renderCurve",value:function(n,i){var o=this.props,s=o.points,a=o.isAnimationActive,l=this.state,c=l.prevPoints,u=l.totalLength;return a&&s&&s.length&&(!c&&u>0||!Zn(c,s))?this.renderCurveWithAnimation(n,i):this.renderCurveStatically(s,n,i)}},{key:"render",value:function(){var n,i=this.props,o=i.hide,s=i.dot,a=i.points,l=i.className,c=i.xAxis,u=i.yAxis,d=i.top,h=i.left,f=i.width,g=i.height,m=i.isAnimationActive,p=i.id;if(o||!a||!a.length)return null;var y=this.state.isAnimationFinished,w=a.length===1,b=ve("recharts-line",l),x=c&&c.allowDataOverflow,C=u&&u.allowDataOverflow,S=x||C,A=ue(p)?this.id:p,P=(n=de(s,!1))!==null&&n!==void 0?n:{r:3,strokeWidth:2},E=P.r,O=E===void 0?3:E,R=P.strokeWidth,T=R===void 0?2:R,F=dx(s)?s:{},I=F.clipDot,k=I===void 0?!0:I,B=O*2+T;return v.createElement(be,{className:b},x||C?v.createElement("defs",null,v.createElement("clipPath",{id:"clipPath-".concat(A)},v.createElement("rect",{x:x?h:h-f/2,y:C?d:d-g/2,width:x?f:f*2,height:C?g:g*2})),!k&&v.createElement("clipPath",{id:"clipPath-dots-".concat(A)},v.createElement("rect",{x:h-B/2,y:d-B/2,width:f+B,height:g+B}))):null,!w&&this.renderCurve(S,A),this.renderErrorBar(S,A),(w||s)&&this.renderDots(S,k,A),(!m||y)&&Cr.renderCallByParent(this.props,a))}}],[{key:"getDerivedStateFromProps",value:function(n,i){return n.animationId!==i.prevAnimationId?{prevAnimationId:n.animationId,curPoints:n.points,prevPoints:i.curPoints}:n.points!==i.curPoints?{curPoints:n.points}:null}},{key:"repeat",value:function(n,i){for(var o=n.length%2!==0?[].concat(fi(n),[0]):n,s=[],a=0;a<i;++a)s=[].concat(fi(s),fi(o));return s}},{key:"renderDotItem",value:function(n,i){var o;if(v.isValidElement(n))o=v.cloneElement(n,i);else if(ge(n))o=n(i);else{var s=i.key,a=hw(i,sue),l=ve("recharts-line-dot",typeof n!="boolean"?n.className:"");o=v.createElement(zu,gs({key:s},a,{className:l}))}return o}}])}(v.PureComponent);ir(fr,"displayName","Line");ir(fr,"defaultProps",{xAxisId:0,yAxisId:0,connectNulls:!1,activeDot:!0,dot:!0,legendType:"line",stroke:"#3182bd",strokeWidth:1,fill:"#fff",points:[],isAnimationActive:!pn.isSsr,animateNewValues:!0,animationBegin:0,animationDuration:1500,animationEasing:"ease",hide:!1,label:!1});ir(fr,"getComposedData",function(e){var t=e.props,r=e.xAxis,n=e.yAxis,i=e.xAxisTicks,o=e.yAxisTicks,s=e.dataKey,a=e.bandSize,l=e.displayedData,c=e.offset,u=t.layout,d=l.map(function(h,f){var g=tt(h,s);return u==="horizontal"?{x:qi({axis:r,ticks:i,bandSize:a,entry:h,index:f}),y:ue(g)?null:n.scale(g),value:g,payload:h}:{x:ue(g)?null:r.scale(g),y:qi({axis:n,ticks:o,bandSize:a,entry:h,index:f}),value:g,payload:h}});return kt({points:d,layout:u},c)});var bue=["layout","type","stroke","connectNulls","isRange","ref"],Cue=["key"],cR;function oo(e){"@babel/helpers - typeof";return oo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},oo(e)}function uR(e,t){if(e==null)return{};var r=wue(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function wue(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Mn(){return Mn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Mn.apply(this,arguments)}function pw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Zr(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?pw(Object(r),!0).forEach(function(n){vr(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):pw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Sue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function mw(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,hR(n.key),n)}}function xue(e,t,r){return t&&mw(e.prototype,t),r&&mw(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function Aue(e,t,r){return t=jc(t),Pue(e,dR()?Reflect.construct(t,r||[],jc(e).constructor):t.apply(e,r))}function Pue(e,t){if(t&&(oo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Rue(e)}function Rue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function dR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(dR=function(){return!!e})()}function jc(e){return jc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},jc(e)}function Eue(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&hg(e,t)}function hg(e,t){return hg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},hg(e,t)}function vr(e,t,r){return t=hR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hR(e){var t=Tue(e,"string");return oo(t)=="symbol"?t:t+""}function Tue(e,t){if(oo(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(oo(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var St=function(e){function t(){var r;Sue(this,t);for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];return r=Aue(this,t,[].concat(i)),vr(r,"state",{isAnimationFinished:!0}),vr(r,"id",oi("recharts-area-")),vr(r,"handleAnimationEnd",function(){var s=r.props.onAnimationEnd;r.setState({isAnimationFinished:!0}),ge(s)&&s()}),vr(r,"handleAnimationStart",function(){var s=r.props.onAnimationStart;r.setState({isAnimationFinished:!1}),ge(s)&&s()}),r}return Eue(t,e),xue(t,[{key:"renderDots",value:function(n,i,o){var s=this.props.isAnimationActive,a=this.state.isAnimationFinished;if(s&&!a)return null;var l=this.props,c=l.dot,u=l.points,d=l.dataKey,h=de(this.props,!1),f=de(c,!0),g=u.map(function(p,y){var w=Zr(Zr(Zr({key:"dot-".concat(y),r:3},h),f),{},{index:y,cx:p.x,cy:p.y,dataKey:d,value:p.value,payload:p.payload,points:u});return t.renderDotItem(c,w)}),m={clipPath:n?"url(#clipPath-".concat(i?"":"dots-").concat(o,")"):null};return v.createElement(be,Mn({className:"recharts-area-dots"},m),g)}},{key:"renderHorizontalRect",value:function(n){var i=this.props,o=i.baseLine,s=i.points,a=i.strokeWidth,l=s[0].x,c=s[s.length-1].x,u=n*Math.abs(l-c),d=tn(s.map(function(h){return h.y||0}));return Z(o)&&typeof o=="number"?d=Math.max(o,d):o&&Array.isArray(o)&&o.length&&(d=Math.max(tn(o.map(function(h){return h.y||0})),d)),Z(d)?v.createElement("rect",{x:l<c?l:l-u,y:0,width:u,height:Math.floor(d+(a?parseInt("".concat(a),10):1))}):null}},{key:"renderVerticalRect",value:function(n){var i=this.props,o=i.baseLine,s=i.points,a=i.strokeWidth,l=s[0].y,c=s[s.length-1].y,u=n*Math.abs(l-c),d=tn(s.map(function(h){return h.x||0}));return Z(o)&&typeof o=="number"?d=Math.max(o,d):o&&Array.isArray(o)&&o.length&&(d=Math.max(tn(o.map(function(h){return h.x||0})),d)),Z(d)?v.createElement("rect",{x:0,y:l<c?l:l-u,width:d+(a?parseInt("".concat(a),10):1),height:Math.floor(u)}):null}},{key:"renderClipRect",value:function(n){var i=this.props.layout;return i==="vertical"?this.renderVerticalRect(n):this.renderHorizontalRect(n)}},{key:"renderAreaStatically",value:function(n,i,o,s){var a=this.props,l=a.layout,c=a.type,u=a.stroke,d=a.connectNulls,h=a.isRange;a.ref;var f=uR(a,bue);return v.createElement(be,{clipPath:o?"url(#clipPath-".concat(s,")"):null},v.createElement($n,Mn({},de(f,!0),{points:n,connectNulls:d,type:c,baseLine:i,layout:l,stroke:"none",className:"recharts-area-area"})),u!=="none"&&v.createElement($n,Mn({},de(this.props,!1),{className:"recharts-area-curve",layout:l,type:c,connectNulls:d,fill:"none",points:n})),u!=="none"&&h&&v.createElement($n,Mn({},de(this.props,!1),{className:"recharts-area-curve",layout:l,type:c,connectNulls:d,fill:"none",points:i})))}},{key:"renderAreaWithAnimation",value:function(n,i){var o=this,s=this.props,a=s.points,l=s.baseLine,c=s.isAnimationActive,u=s.animationBegin,d=s.animationDuration,h=s.animationEasing,f=s.animationId,g=this.state,m=g.prevPoints,p=g.prevBaseLine;return v.createElement(cr,{begin:u,duration:d,isActive:c,easing:h,from:{t:0},to:{t:1},key:"area-".concat(f),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(y){var w=y.t;if(m){var b=m.length/a.length,x=a.map(function(P,E){var O=Math.floor(E*b);if(m[O]){var R=m[O],T=Ue(R.x,P.x),F=Ue(R.y,P.y);return Zr(Zr({},P),{},{x:T(w),y:F(w)})}return P}),C;if(Z(l)&&typeof l=="number"){var S=Ue(p,l);C=S(w)}else if(ue(l)||Eo(l)){var A=Ue(p,0);C=A(w)}else C=l.map(function(P,E){var O=Math.floor(E*b);if(p[O]){var R=p[O],T=Ue(R.x,P.x),F=Ue(R.y,P.y);return Zr(Zr({},P),{},{x:T(w),y:F(w)})}return P});return o.renderAreaStatically(x,C,n,i)}return v.createElement(be,null,v.createElement("defs",null,v.createElement("clipPath",{id:"animationClipPath-".concat(i)},o.renderClipRect(w))),v.createElement(be,{clipPath:"url(#animationClipPath-".concat(i,")")},o.renderAreaStatically(a,l,n,i)))})}},{key:"renderArea",value:function(n,i){var o=this.props,s=o.points,a=o.baseLine,l=o.isAnimationActive,c=this.state,u=c.prevPoints,d=c.prevBaseLine,h=c.totalLength;return l&&s&&s.length&&(!u&&h>0||!Zn(u,s)||!Zn(d,a))?this.renderAreaWithAnimation(n,i):this.renderAreaStatically(s,a,n,i)}},{key:"render",value:function(){var n,i=this.props,o=i.hide,s=i.dot,a=i.points,l=i.className,c=i.top,u=i.left,d=i.xAxis,h=i.yAxis,f=i.width,g=i.height,m=i.isAnimationActive,p=i.id;if(o||!a||!a.length)return null;var y=this.state.isAnimationFinished,w=a.length===1,b=ve("recharts-area",l),x=d&&d.allowDataOverflow,C=h&&h.allowDataOverflow,S=x||C,A=ue(p)?this.id:p,P=(n=de(s,!1))!==null&&n!==void 0?n:{r:3,strokeWidth:2},E=P.r,O=E===void 0?3:E,R=P.strokeWidth,T=R===void 0?2:R,F=dx(s)?s:{},I=F.clipDot,k=I===void 0?!0:I,B=O*2+T;return v.createElement(be,{className:b},x||C?v.createElement("defs",null,v.createElement("clipPath",{id:"clipPath-".concat(A)},v.createElement("rect",{x:x?u:u-f/2,y:C?c:c-g/2,width:x?f:f*2,height:C?g:g*2})),!k&&v.createElement("clipPath",{id:"clipPath-dots-".concat(A)},v.createElement("rect",{x:u-B/2,y:c-B/2,width:f+B,height:g+B}))):null,w?null:this.renderArea(S,A),(s||w)&&this.renderDots(S,k,A),(!m||y)&&Cr.renderCallByParent(this.props,a))}}],[{key:"getDerivedStateFromProps",value:function(n,i){return n.animationId!==i.prevAnimationId?{prevAnimationId:n.animationId,curPoints:n.points,curBaseLine:n.baseLine,prevPoints:i.curPoints,prevBaseLine:i.curBaseLine}:n.points!==i.curPoints||n.baseLine!==i.curBaseLine?{curPoints:n.points,curBaseLine:n.baseLine}:null}}])}(v.PureComponent);cR=St;vr(St,"displayName","Area");vr(St,"defaultProps",{stroke:"#3182bd",fill:"#3182bd",fillOpacity:.6,xAxisId:0,yAxisId:0,legendType:"line",connectNulls:!1,points:[],dot:!1,activeDot:!0,hide:!1,isAnimationActive:!pn.isSsr,animationBegin:0,animationDuration:1500,animationEasing:"ease"});vr(St,"getBaseValue",function(e,t,r,n){var i=e.layout,o=e.baseValue,s=t.props.baseValue,a=s??o;if(Z(a)&&typeof a=="number")return a;var l=i==="horizontal"?n:r,c=l.scale.domain();if(l.type==="number"){var u=Math.max(c[0],c[1]),d=Math.min(c[0],c[1]);return a==="dataMin"?d:a==="dataMax"||u<0?u:Math.max(Math.min(c[0],c[1]),0)}return a==="dataMin"?c[0]:a==="dataMax"?c[1]:c[0]});vr(St,"getComposedData",function(e){var t=e.props,r=e.item,n=e.xAxis,i=e.yAxis,o=e.xAxisTicks,s=e.yAxisTicks,a=e.bandSize,l=e.dataKey,c=e.stackedData,u=e.dataStartIndex,d=e.displayedData,h=e.offset,f=t.layout,g=c&&c.length,m=cR.getBaseValue(t,r,n,i),p=f==="horizontal",y=!1,w=d.map(function(x,C){var S;g?S=c[u+C]:(S=tt(x,l),Array.isArray(S)?y=!0:S=[m,S]);var A=S[1]==null||g&&tt(x,l)==null;return p?{x:qi({axis:n,ticks:o,bandSize:a,entry:x,index:C}),y:A?null:i.scale(S[1]),value:S,payload:x}:{x:A?null:n.scale(S[1]),y:qi({axis:i,ticks:s,bandSize:a,entry:x,index:C}),value:S,payload:x}}),b;return g||y?b=w.map(function(x){var C=Array.isArray(x.value)?x.value[0]:null;return p?{x:x.x,y:C!=null&&x.y!=null?i.scale(C):null}:{x:C!=null?n.scale(C):null,y:x.y}}):b=p?i.scale(m):n.scale(m),Zr({points:w,baseLine:b,layout:f,isRange:y},h)});vr(St,"renderDotItem",function(e,t){var r;if(v.isValidElement(e))r=v.cloneElement(e,t);else if(ge(e))r=e(t);else{var n=ve("recharts-area-dot",typeof e!="boolean"?e.className:""),i=t.key,o=uR(t,Cue);r=v.createElement(zu,Mn({},o,{key:i,className:n}))}return r});function so(e){"@babel/helpers - typeof";return so=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},so(e)}function Fue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Oue(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,pR(n.key),n)}}function Mue(e,t,r){return t&&Oue(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Due(e,t,r){return t=Vc(t),kue(e,fR()?Reflect.construct(t,r||[],Vc(e).constructor):t.apply(e,r))}function kue(e,t){if(t&&(so(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Iue(e)}function Iue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function fR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(fR=function(){return!!e})()}function Vc(e){return Vc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Vc(e)}function _ue(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&fg(e,t)}function fg(e,t){return fg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},fg(e,t)}function gR(e,t,r){return t=pR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function pR(e){var t=Lue(e,"string");return so(t)=="symbol"?t:t+""}function Lue(e,t){if(so(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(so(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ku=function(e){function t(){return Fue(this,t),Due(this,t,arguments)}return _ue(t,e),Mue(t,[{key:"render",value:function(){return null}}])}(v.Component);gR(Ku,"displayName","ZAxis");gR(Ku,"defaultProps",{zAxisId:0,range:[64,64],scale:"auto",type:"number"});var Bue=["option","isActive"];function ps(){return ps=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ps.apply(this,arguments)}function zue(e,t){if(e==null)return{};var r=Nue(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Nue(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function $ue(e){var t=e.option,r=e.isActive,n=zue(e,Bue);return typeof t=="string"?v.createElement(Qf,ps({option:v.createElement(Pu,ps({type:t},n)),isActive:r,shapeType:"symbols"},n)):v.createElement(Qf,ps({option:t,isActive:r,shapeType:"symbols"},n))}function ao(e){"@babel/helpers - typeof";return ao=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ao(e)}function ms(){return ms=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ms.apply(this,arguments)}function vw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Vt(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?vw(Object(r),!0).forEach(function(n){nn(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):vw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Hue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function yw(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,vR(n.key),n)}}function Gue(e,t,r){return t&&yw(e.prototype,t),r&&yw(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function Wue(e,t,r){return t=Uc(t),jue(e,mR()?Reflect.construct(t,r||[],Uc(e).constructor):t.apply(e,r))}function jue(e,t){if(t&&(ao(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Vue(e)}function Vue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function mR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(mR=function(){return!!e})()}function Uc(e){return Uc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Uc(e)}function Uue(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&gg(e,t)}function gg(e,t){return gg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},gg(e,t)}function nn(e,t,r){return t=vR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function vR(e){var t=Kue(e,"string");return ao(t)=="symbol"?t:t+""}function Kue(e,t){if(ao(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ao(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var qu=function(e){function t(){var r;Hue(this,t);for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];return r=Wue(this,t,[].concat(i)),nn(r,"state",{isAnimationFinished:!1}),nn(r,"handleAnimationEnd",function(){r.setState({isAnimationFinished:!0})}),nn(r,"handleAnimationStart",function(){r.setState({isAnimationFinished:!1})}),nn(r,"id",oi("recharts-scatter-")),r}return Uue(t,e),Gue(t,[{key:"renderSymbolsStatically",value:function(n){var i=this,o=this.props,s=o.shape,a=o.activeShape,l=o.activeIndex,c=de(this.props,!1);return n.map(function(u,d){var h=l===d,f=h?a:s,g=Vt(Vt({},c),u);return v.createElement(be,ms({className:"recharts-scatter-symbol",key:"symbol-".concat(u==null?void 0:u.cx,"-").concat(u==null?void 0:u.cy,"-").concat(u==null?void 0:u.size,"-").concat(d)},Is(i.props,u,d),{role:"img"}),v.createElement($ue,ms({option:f,isActive:h,key:"symbol-".concat(d)},g)))})}},{key:"renderSymbolsWithAnimation",value:function(){var n=this,i=this.props,o=i.points,s=i.isAnimationActive,a=i.animationBegin,l=i.animationDuration,c=i.animationEasing,u=i.animationId,d=this.state.prevPoints;return v.createElement(cr,{begin:a,duration:l,isActive:s,easing:c,from:{t:0},to:{t:1},key:"pie-".concat(u),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(h){var f=h.t,g=o.map(function(m,p){var y=d&&d[p];if(y){var w=Ue(y.cx,m.cx),b=Ue(y.cy,m.cy),x=Ue(y.size,m.size);return Vt(Vt({},m),{},{cx:w(f),cy:b(f),size:x(f)})}var C=Ue(0,m.size);return Vt(Vt({},m),{},{size:C(f)})});return v.createElement(be,null,n.renderSymbolsStatically(g))})}},{key:"renderSymbols",value:function(){var n=this.props,i=n.points,o=n.isAnimationActive,s=this.state.prevPoints;return o&&i&&i.length&&(!s||!Zn(s,i))?this.renderSymbolsWithAnimation():this.renderSymbolsStatically(i)}},{key:"renderErrorBar",value:function(){var n=this.props.isAnimationActive;if(n&&!this.state.isAnimationFinished)return null;var i=this.props,o=i.points,s=i.xAxis,a=i.yAxis,l=i.children,c=Tt(l,_o);return c?c.map(function(u,d){var h=u.props,f=h.direction,g=h.dataKey;return v.cloneElement(u,{key:"".concat(f,"-").concat(g,"-").concat(o[d]),data:o,xAxis:s,yAxis:a,layout:f==="x"?"vertical":"horizontal",dataPointFormatter:function(p,y){return{x:p.cx,y:p.cy,value:f==="x"?+p.node.x:+p.node.y,errorVal:tt(p,y)}}})}):null}},{key:"renderLine",value:function(){var n=this.props,i=n.points,o=n.line,s=n.lineType,a=n.lineJointType,l=de(this.props,!1),c=de(o,!1),u,d;if(s==="joint")u=i.map(function(b){return{x:b.cx,y:b.cy}});else if(s==="fitting"){var h=r5(i),f=h.xmin,g=h.xmax,m=h.a,p=h.b,y=function(x){return m*x+p};u=[{x:f,y:y(f)},{x:g,y:y(g)}]}var w=Vt(Vt(Vt({},l),{},{fill:"none",stroke:l&&l.fill},c),{},{points:u});return v.isValidElement(o)?d=v.cloneElement(o,w):ge(o)?d=o(w):d=v.createElement($n,ms({},w,{type:a})),v.createElement(be,{className:"recharts-scatter-line",key:"recharts-scatter-line"},d)}},{key:"render",value:function(){var n=this.props,i=n.hide,o=n.points,s=n.line,a=n.className,l=n.xAxis,c=n.yAxis,u=n.left,d=n.top,h=n.width,f=n.height,g=n.id,m=n.isAnimationActive;if(i||!o||!o.length)return null;var p=this.state.isAnimationFinished,y=ve("recharts-scatter",a),w=l&&l.allowDataOverflow,b=c&&c.allowDataOverflow,x=w||b,C=ue(g)?this.id:g;return v.createElement(be,{className:y,clipPath:x?"url(#clipPath-".concat(C,")"):null},w||b?v.createElement("defs",null,v.createElement("clipPath",{id:"clipPath-".concat(C)},v.createElement("rect",{x:w?u:u-h/2,y:b?d:d-f/2,width:w?h:h*2,height:b?f:f*2}))):null,s&&this.renderLine(),this.renderErrorBar(),v.createElement(be,{key:"recharts-scatter-symbols"},this.renderSymbols()),(!m||p)&&Cr.renderCallByParent(this.props,o))}}],[{key:"getDerivedStateFromProps",value:function(n,i){return n.animationId!==i.prevAnimationId?{prevAnimationId:n.animationId,curPoints:n.points,prevPoints:i.curPoints}:n.points!==i.curPoints?{curPoints:n.points}:null}}])}(v.PureComponent);nn(qu,"displayName","Scatter");nn(qu,"defaultProps",{xAxisId:0,yAxisId:0,zAxisId:0,legendType:"circle",lineType:"joint",lineJointType:"linear",data:[],shape:"circle",hide:!1,isAnimationActive:!pn.isSsr,animationBegin:0,animationDuration:400,animationEasing:"linear"});nn(qu,"getComposedData",function(e){var t=e.xAxis,r=e.yAxis,n=e.zAxis,i=e.item,o=e.displayedData,s=e.xAxisTicks,a=e.yAxisTicks,l=e.offset,c=i.props.tooltipType,u=Tt(i.props.children,em),d=ue(t.dataKey)?i.props.dataKey:t.dataKey,h=ue(r.dataKey)?i.props.dataKey:r.dataKey,f=n&&n.dataKey,g=n?n.range:Ku.defaultProps.range,m=g&&g[0],p=t.scale.bandwidth?t.scale.bandwidth():0,y=r.scale.bandwidth?r.scale.bandwidth():0,w=o.map(function(b,x){var C=tt(b,d),S=tt(b,h),A=!ue(f)&&tt(b,f)||"-",P=[{name:ue(t.dataKey)?i.props.name:t.name||t.dataKey,unit:t.unit||"",value:C,payload:b,dataKey:d,type:c},{name:ue(r.dataKey)?i.props.name:r.name||r.dataKey,unit:r.unit||"",value:S,payload:b,dataKey:h,type:c}];A!=="-"&&P.push({name:n.name||n.dataKey,unit:n.unit||"",value:A,payload:b,dataKey:f,type:c});var E=qi({axis:t,ticks:s,bandSize:p,entry:b,index:x,dataKey:d}),O=qi({axis:r,ticks:a,bandSize:y,entry:b,index:x,dataKey:h}),R=A!=="-"?n.scale(A):m,T=Math.sqrt(Math.max(R,0)/Math.PI);return Vt(Vt({},b),{},{cx:E,cy:O,x:E-T,y:O-T,xAxis:t,yAxis:r,zAxis:n,width:2*T,height:2*T,size:R,node:{x:C,y:S,z:A},tooltipPayload:P,tooltipPosition:{x:E,y:O},payload:b},u&&u[x]&&u[x].props)});return Vt({points:w},l)});function lo(e){"@babel/helpers - typeof";return lo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lo(e)}function que(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Yue(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,CR(n.key),n)}}function Jue(e,t,r){return t&&Yue(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Xue(e,t,r){return t=Kc(t),Zue(e,yR()?Reflect.construct(t,r||[],Kc(e).constructor):t.apply(e,r))}function Zue(e,t){if(t&&(lo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Que(e)}function Que(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(yR=function(){return!!e})()}function Kc(e){return Kc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Kc(e)}function ede(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&pg(e,t)}function pg(e,t){return pg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},pg(e,t)}function bR(e,t,r){return t=CR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function CR(e){var t=tde(e,"string");return lo(t)=="symbol"?t:t+""}function tde(e,t){if(lo(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(lo(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function mg(){return mg=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},mg.apply(this,arguments)}function rde(e){var t=e.xAxisId,r=JP(),n=XP(),i=qP(t);return i==null?null:v.createElement(Uu,mg({},i,{className:ve("recharts-".concat(i.axisType," ").concat(i.axisType),i.className),viewBox:{x:0,y:0,width:r,height:n},ticksGenerator:function(s){return On(s,!0)}}))}var Yu=function(e){function t(){return que(this,t),Xue(this,t,arguments)}return ede(t,e),Jue(t,[{key:"render",value:function(){return v.createElement(rde,this.props)}}])}(v.Component);bR(Yu,"displayName","XAxis");bR(Yu,"defaultProps",{allowDecimals:!0,hide:!1,orientation:"bottom",width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:"category",padding:{left:0,right:0},allowDataOverflow:!1,scale:"auto",reversed:!1,allowDuplicatedCategory:!0});function co(e){"@babel/helpers - typeof";return co=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},co(e)}function nde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ide(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,xR(n.key),n)}}function ode(e,t,r){return t&&ide(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function sde(e,t,r){return t=qc(t),ade(e,wR()?Reflect.construct(t,r||[],qc(e).constructor):t.apply(e,r))}function ade(e,t){if(t&&(co(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return lde(e)}function lde(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(wR=function(){return!!e})()}function qc(e){return qc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},qc(e)}function cde(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&vg(e,t)}function vg(e,t){return vg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},vg(e,t)}function SR(e,t,r){return t=xR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function xR(e){var t=ude(e,"string");return co(t)=="symbol"?t:t+""}function ude(e,t){if(co(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(co(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function yg(){return yg=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},yg.apply(this,arguments)}var dde=function(t){var r=t.yAxisId,n=JP(),i=XP(),o=YP(r);return o==null?null:v.createElement(Uu,yg({},o,{className:ve("recharts-".concat(o.axisType," ").concat(o.axisType),o.className),viewBox:{x:0,y:0,width:n,height:i},ticksGenerator:function(a){return On(a,!0)}}))},Ju=function(e){function t(){return nde(this,t),sde(this,t,arguments)}return cde(t,e),ode(t,[{key:"render",value:function(){return v.createElement(dde,this.props)}}])}(v.Component);SR(Ju,"displayName","YAxis");SR(Ju,"defaultProps",{allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:"left",width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:"number",padding:{top:0,bottom:0},allowDataOverflow:!1,scale:"auto",reversed:!1});function bw(e){return pde(e)||gde(e)||fde(e)||hde()}function hde(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
111
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function fde(e,t){if(e){if(typeof e=="string")return bg(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return bg(e,t)}}function gde(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function pde(e){if(Array.isArray(e))return bg(e)}function bg(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var Cg=function(t,r,n,i,o){var s=Tt(t,Om),a=Tt(t,Wu),l=[].concat(bw(s),bw(a)),c=Tt(t,Vu),u="".concat(i,"Id"),d=i[0],h=r;if(l.length&&(h=l.reduce(function(m,p){if(p.props[u]===n&&wr(p.props,"extendDomain")&&Z(p.props[d])){var y=p.props[d];return[Math.min(m[0],y),Math.max(m[1],y)]}return m},h)),c.length){var f="".concat(d,"1"),g="".concat(d,"2");h=c.reduce(function(m,p){if(p.props[u]===n&&wr(p.props,"extendDomain")&&Z(p.props[f])&&Z(p.props[g])){var y=p.props[f],w=p.props[g];return[Math.min(m[0],y,w),Math.max(m[1],y,w)]}return m},h)}return o&&o.length&&(h=o.reduce(function(m,p){return Z(p)?[Math.min(m[0],p),Math.max(m[1],p)]:m},h)),h},AR={exports:{}};(function(e){var t=Object.prototype.hasOwnProperty,r="~";function n(){}Object.create&&(n.prototype=Object.create(null),new n().__proto__||(r=!1));function i(l,c,u){this.fn=l,this.context=c,this.once=u||!1}function o(l,c,u,d,h){if(typeof u!="function")throw new TypeError("The listener must be a function");var f=new i(u,d||l,h),g=r?r+c:c;return l._events[g]?l._events[g].fn?l._events[g]=[l._events[g],f]:l._events[g].push(f):(l._events[g]=f,l._eventsCount++),l}function s(l,c){--l._eventsCount===0?l._events=new n:delete l._events[c]}function a(){this._events=new n,this._eventsCount=0}a.prototype.eventNames=function(){var c=[],u,d;if(this._eventsCount===0)return c;for(d in u=this._events)t.call(u,d)&&c.push(r?d.slice(1):d);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(u)):c},a.prototype.listeners=function(c){var u=r?r+c:c,d=this._events[u];if(!d)return[];if(d.fn)return[d.fn];for(var h=0,f=d.length,g=new Array(f);h<f;h++)g[h]=d[h].fn;return g},a.prototype.listenerCount=function(c){var u=r?r+c:c,d=this._events[u];return d?d.fn?1:d.length:0},a.prototype.emit=function(c,u,d,h,f,g){var m=r?r+c:c;if(!this._events[m])return!1;var p=this._events[m],y=arguments.length,w,b;if(p.fn){switch(p.once&&this.removeListener(c,p.fn,void 0,!0),y){case 1:return p.fn.call(p.context),!0;case 2:return p.fn.call(p.context,u),!0;case 3:return p.fn.call(p.context,u,d),!0;case 4:return p.fn.call(p.context,u,d,h),!0;case 5:return p.fn.call(p.context,u,d,h,f),!0;case 6:return p.fn.call(p.context,u,d,h,f,g),!0}for(b=1,w=new Array(y-1);b<y;b++)w[b-1]=arguments[b];p.fn.apply(p.context,w)}else{var x=p.length,C;for(b=0;b<x;b++)switch(p[b].once&&this.removeListener(c,p[b].fn,void 0,!0),y){case 1:p[b].fn.call(p[b].context);break;case 2:p[b].fn.call(p[b].context,u);break;case 3:p[b].fn.call(p[b].context,u,d);break;case 4:p[b].fn.call(p[b].context,u,d,h);break;default:if(!w)for(C=1,w=new Array(y-1);C<y;C++)w[C-1]=arguments[C];p[b].fn.apply(p[b].context,w)}}return!0},a.prototype.on=function(c,u,d){return o(this,c,u,d,!1)},a.prototype.once=function(c,u,d){return o(this,c,u,d,!0)},a.prototype.removeListener=function(c,u,d,h){var f=r?r+c:c;if(!this._events[f])return this;if(!u)return s(this,f),this;var g=this._events[f];if(g.fn)g.fn===u&&(!h||g.once)&&(!d||g.context===d)&&s(this,f);else{for(var m=0,p=[],y=g.length;m<y;m++)(g[m].fn!==u||h&&!g[m].once||d&&g[m].context!==d)&&p.push(g[m]);p.length?this._events[f]=p.length===1?p[0]:p:s(this,f)}return this},a.prototype.removeAllListeners=function(c){var u;return c?(u=r?r+c:c,this._events[u]&&s(this,u)):(this._events=new n,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=r,a.EventEmitter=a,e.exports=a})(AR);var mde=AR.exports;const vde=Le(mde);var hh=new vde,fh="recharts.syncMouseEvents";function ha(e){"@babel/helpers - typeof";return ha=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ha(e)}function yde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function bde(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,PR(n.key),n)}}function Cde(e,t,r){return t&&bde(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function gh(e,t,r){return t=PR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function PR(e){var t=wde(e,"string");return ha(t)=="symbol"?t:t+""}function wde(e,t){if(ha(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ha(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Sde=function(){function e(){yde(this,e),gh(this,"activeIndex",0),gh(this,"coordinateList",[]),gh(this,"layout","horizontal")}return Cde(e,[{key:"setDetails",value:function(r){var n,i=r.coordinateList,o=i===void 0?null:i,s=r.container,a=s===void 0?null:s,l=r.layout,c=l===void 0?null:l,u=r.offset,d=u===void 0?null:u,h=r.mouseHandlerCallback,f=h===void 0?null:h;this.coordinateList=(n=o??this.coordinateList)!==null&&n!==void 0?n:[],this.container=a??this.container,this.layout=c??this.layout,this.offset=d??this.offset,this.mouseHandlerCallback=f??this.mouseHandlerCallback,this.activeIndex=Math.min(Math.max(this.activeIndex,0),this.coordinateList.length-1)}},{key:"focus",value:function(){this.spoofMouse()}},{key:"keyboardEvent",value:function(r){if(this.coordinateList.length!==0)switch(r.key){case"ArrowRight":{if(this.layout!=="horizontal")return;this.activeIndex=Math.min(this.activeIndex+1,this.coordinateList.length-1),this.spoofMouse();break}case"ArrowLeft":{if(this.layout!=="horizontal")return;this.activeIndex=Math.max(this.activeIndex-1,0),this.spoofMouse();break}}}},{key:"setIndex",value:function(r){this.activeIndex=r}},{key:"spoofMouse",value:function(){var r,n;if(this.layout==="horizontal"&&this.coordinateList.length!==0){var i=this.container.getBoundingClientRect(),o=i.x,s=i.y,a=i.height,l=this.coordinateList[this.activeIndex].coordinate,c=((r=window)===null||r===void 0?void 0:r.scrollX)||0,u=((n=window)===null||n===void 0?void 0:n.scrollY)||0,d=o+l+c,h=s+this.offset.top+a/2+u;this.mouseHandlerCallback({pageX:d,pageY:h})}}}])}();function xde(e,t,r){if(r==="number"&&t===!0&&Array.isArray(e)){var n=e==null?void 0:e[0],i=e==null?void 0:e[1];if(n&&i&&Z(n)&&Z(i))return!0}return!1}function Ade(e,t,r,n){var i=n/2;return{stroke:"none",fill:"#ccc",x:e==="horizontal"?t.x-i:r.left+.5,y:e==="horizontal"?r.top+.5:t.y-i,width:e==="horizontal"?n:r.width-1,height:e==="horizontal"?r.height-1:n}}function RR(e){var t=e.cx,r=e.cy,n=e.radius,i=e.startAngle,o=e.endAngle,s=at(t,r,n,i),a=at(t,r,n,o);return{points:[s,a],cx:t,cy:r,radius:n,startAngle:i,endAngle:o}}function Pde(e,t,r){var n,i,o,s;if(e==="horizontal")n=t.x,o=n,i=r.top,s=r.top+r.height;else if(e==="vertical")i=t.y,s=i,n=r.left,o=r.left+r.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var a=t.cx,l=t.cy,c=t.innerRadius,u=t.outerRadius,d=t.angle,h=at(a,l,c,d),f=at(a,l,u,d);n=h.x,i=h.y,o=f.x,s=f.y}else return RR(t);return[{x:n,y:i},{x:o,y:s}]}function fa(e){"@babel/helpers - typeof";return fa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fa(e)}function Cw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function al(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Cw(Object(r),!0).forEach(function(n){Rde(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Cw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Rde(e,t,r){return t=Ede(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ede(e){var t=Tde(e,"string");return fa(t)=="symbol"?t:t+""}function Tde(e,t){if(fa(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(fa(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Fde(e){var t,r,n=e.element,i=e.tooltipEventType,o=e.isActive,s=e.activeCoordinate,a=e.activePayload,l=e.offset,c=e.activeTooltipIndex,u=e.tooltipAxisBandSize,d=e.layout,h=e.chartName,f=(t=n.props.cursor)!==null&&t!==void 0?t:(r=n.type.defaultProps)===null||r===void 0?void 0:r.cursor;if(!n||!f||!o||!s||h!=="ScatterChart"&&i!=="axis")return null;var g,m=$n;if(h==="ScatterChart")g=s,m=Dse;else if(h==="BarChart")g=Ade(d,s,l,u),m=Em;else if(d==="radial"){var p=RR(s),y=p.cx,w=p.cy,b=p.radius,x=p.startAngle,C=p.endAngle;g={cx:y,cy:w,startAngle:x,endAngle:C,innerRadius:b,outerRadius:b},m=CP}else g={points:Pde(d,s,l)},m=$n;var S=al(al(al(al({stroke:"#ccc",pointerEvents:"none"},l),g),de(f,!1)),{},{payload:a,payloadIndex:c,className:ve("recharts-tooltip-cursor",f.className)});return v.isValidElement(f)?v.cloneElement(f,S):v.createElement(m,S)}var Ode=["item"],Mde=["children","className","width","height","style","compact","title","desc"];function uo(e){"@babel/helpers - typeof";return uo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},uo(e)}function bi(){return bi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},bi.apply(this,arguments)}function ww(e,t){return Ide(e)||kde(e,t)||TR(e,t)||Dde()}function Dde(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
112
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function kde(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t!==0)for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(u){c=!0,i=u}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}function Ide(e){if(Array.isArray(e))return e}function Sw(e,t){if(e==null)return{};var r=_de(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function _de(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Lde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Bde(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,FR(n.key),n)}}function zde(e,t,r){return t&&Bde(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Nde(e,t,r){return t=Yc(t),$de(e,ER()?Reflect.construct(t,r||[],Yc(e).constructor):t.apply(e,r))}function $de(e,t){if(t&&(uo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Hde(e)}function Hde(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ER(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ER=function(){return!!e})()}function Yc(e){return Yc=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Yc(e)}function Gde(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&wg(e,t)}function wg(e,t){return wg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},wg(e,t)}function ho(e){return Vde(e)||jde(e)||TR(e)||Wde()}function Wde(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
113
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function TR(e,t){if(e){if(typeof e=="string")return Sg(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Sg(e,t)}}function jde(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Vde(e){if(Array.isArray(e))return Sg(e)}function Sg(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function xw(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function G(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?xw(Object(r),!0).forEach(function(n){se(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):xw(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function se(e,t,r){return t=FR(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function FR(e){var t=Ude(e,"string");return uo(t)=="symbol"?t:t+""}function Ude(e,t){if(uo(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(uo(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Kde={xAxis:["bottom","top"],yAxis:["left","right"]},qde={width:"100%",height:"100%"},OR={x:0,y:0};function ll(e){return e}var Yde=function(t,r){return r==="horizontal"?t.x:r==="vertical"?t.y:r==="centric"?t.angle:t.radius},Jde=function(t,r,n,i){var o=r.find(function(u){return u&&u.index===n});if(o){if(t==="horizontal")return{x:o.coordinate,y:i.y};if(t==="vertical")return{x:i.x,y:o.coordinate};if(t==="centric"){var s=o.coordinate,a=i.radius;return G(G(G({},i),at(i.cx,i.cy,a,s)),{},{angle:s,radius:a})}var l=o.coordinate,c=i.angle;return G(G(G({},i),at(i.cx,i.cy,l,c)),{},{angle:c,radius:l})}return OR},Xu=function(t,r){var n=r.graphicalItems,i=r.dataStartIndex,o=r.dataEndIndex,s=(n??[]).reduce(function(a,l){var c=l.props.data;return c&&c.length?[].concat(ho(a),ho(c)):a},[]);return s.length>0?s:t&&t.length&&Z(i)&&Z(o)?t.slice(i,o+1):[]};function MR(e){return e==="number"?[0,"auto"]:void 0}var xg=function(t,r,n,i){var o=t.graphicalItems,s=t.tooltipAxis,a=Xu(r,t);return n<0||!o||!o.length||n>=a.length?null:o.reduce(function(l,c){var u,d=(u=c.props.data)!==null&&u!==void 0?u:r;d&&t.dataStartIndex+t.dataEndIndex!==0&&t.dataEndIndex-t.dataStartIndex>=n&&(d=d.slice(t.dataStartIndex,t.dataEndIndex+1));var h;if(s.dataKey&&!s.allowDuplicatedCategory){var f=d===void 0?a:d;h=Kl(f,s.dataKey,i)}else h=d&&d[n]||a[n];return h?[].concat(ho(l),[vP(c,h)]):l},[])},Aw=function(t,r,n,i){var o=i||{x:t.chartX,y:t.chartY},s=Yde(o,n),a=t.orderedTooltipTicks,l=t.tooltipAxis,c=t.tooltipTicks,u=cne(s,a,c,l);if(u>=0&&c){var d=c[u]&&c[u].value,h=xg(t,r,u,d),f=Jde(n,a,u,o);return{activeTooltipIndex:u,activeLabel:d,activePayload:h,activeCoordinate:f}}return null},Xde=function(t,r){var n=r.axes,i=r.graphicalItems,o=r.axisType,s=r.axisIdKey,a=r.stackGroups,l=r.dataStartIndex,c=r.dataEndIndex,u=t.layout,d=t.children,h=t.stackOffset,f=pP(u,o);return n.reduce(function(g,m){var p,y=m.type.defaultProps!==void 0?G(G({},m.type.defaultProps),m.props):m.props,w=y.type,b=y.dataKey,x=y.allowDataOverflow,C=y.allowDuplicatedCategory,S=y.scale,A=y.ticks,P=y.includeHidden,E=y[s];if(g[E])return g;var O=Xu(t.data,{graphicalItems:i.filter(function($){var H,V=s in $.props?$.props[s]:(H=$.type.defaultProps)===null||H===void 0?void 0:H[s];return V===E}),dataStartIndex:l,dataEndIndex:c}),R=O.length,T,F,I;xde(y.domain,x,w)&&(T=Lf(y.domain,null,x),f&&(w==="number"||S!=="auto")&&(I=hs(O,b,"category")));var k=MR(w);if(!T||T.length===0){var B,N=(B=y.domain)!==null&&B!==void 0?B:k;if(b){if(T=hs(O,b,w),w==="category"&&f){var z=t5(T);C&&z?(F=T,T=Dc(0,R)):C||(T=Vb(N,T,m).reduce(function($,H){return $.indexOf(H)>=0?$:[].concat(ho($),[H])},[]))}else if(w==="category")C?T=T.filter(function($){return $!==""&&!ue($)}):T=Vb(N,T,m).reduce(function($,H){return $.indexOf(H)>=0||H===""||ue(H)?$:[].concat(ho($),[H])},[]);else if(w==="number"){var W=gne(O,i.filter(function($){var H,V,X=s in $.props?$.props[s]:(H=$.type.defaultProps)===null||H===void 0?void 0:H[s],Y="hide"in $.props?$.props.hide:(V=$.type.defaultProps)===null||V===void 0?void 0:V.hide;return X===E&&(P||!Y)}),b,o,u);W&&(T=W)}f&&(w==="number"||S!=="auto")&&(I=hs(O,b,"category"))}else f?T=Dc(0,R):a&&a[E]&&a[E].hasStack&&w==="number"?T=h==="expand"?[0,1]:mP(a[E].stackGroups,l,c):T=gP(O,i.filter(function($){var H=s in $.props?$.props[s]:$.type.defaultProps[s],V="hide"in $.props?$.props.hide:$.type.defaultProps.hide;return H===E&&(P||!V)}),w,u,!0);if(w==="number")T=Cg(d,T,E,o,A),N&&(T=Lf(N,T,x));else if(w==="category"&&N){var D=N,L=T.every(function($){return D.indexOf($)>=0});L&&(T=D)}}return G(G({},g),{},se({},E,G(G({},y),{},{axisType:o,domain:T,categoricalDomain:I,duplicateDomain:F,originalDomain:(p=y.domain)!==null&&p!==void 0?p:k,isCategorical:f,layout:u})))},{})},Zde=function(t,r){var n=r.graphicalItems,i=r.Axis,o=r.axisType,s=r.axisIdKey,a=r.stackGroups,l=r.dataStartIndex,c=r.dataEndIndex,u=t.layout,d=t.children,h=Xu(t.data,{graphicalItems:n,dataStartIndex:l,dataEndIndex:c}),f=h.length,g=pP(u,o),m=-1;return n.reduce(function(p,y){var w=y.type.defaultProps!==void 0?G(G({},y.type.defaultProps),y.props):y.props,b=w[s],x=MR("number");if(!p[b]){m++;var C;return g?C=Dc(0,f):a&&a[b]&&a[b].hasStack?(C=mP(a[b].stackGroups,l,c),C=Cg(d,C,b,o)):(C=Lf(x,gP(h,n.filter(function(S){var A,P,E=s in S.props?S.props[s]:(A=S.type.defaultProps)===null||A===void 0?void 0:A[s],O="hide"in S.props?S.props.hide:(P=S.type.defaultProps)===null||P===void 0?void 0:P.hide;return E===b&&!O}),"number",u),i.defaultProps.allowDataOverflow),C=Cg(d,C,b,o)),G(G({},p),{},se({},b,G(G({axisType:o},i.defaultProps),{},{hide:!0,orientation:Yt(Kde,"".concat(o,".").concat(m%2),null),domain:C,originalDomain:x,isCategorical:g,layout:u})))}return p},{})},Qde=function(t,r){var n=r.axisType,i=n===void 0?"xAxis":n,o=r.AxisComp,s=r.graphicalItems,a=r.stackGroups,l=r.dataStartIndex,c=r.dataEndIndex,u=t.children,d="".concat(i,"Id"),h=Tt(u,o),f={};return h&&h.length?f=Xde(t,{axes:h,graphicalItems:s,axisType:i,axisIdKey:d,stackGroups:a,dataStartIndex:l,dataEndIndex:c}):s&&s.length&&(f=Zde(t,{Axis:o,graphicalItems:s,axisType:i,axisIdKey:d,stackGroups:a,dataStartIndex:l,dataEndIndex:c})),f},ehe=function(t){var r=gi(t),n=On(r,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:Zp(n,function(i){return i.coordinate}),tooltipAxis:r,tooltipAxisBandSize:Sc(r,n)}},Pw=function(t){var r=t.children,n=t.defaultShowTooltip,i=Lt(r,Xi),o=0,s=0;return t.data&&t.data.length!==0&&(s=t.data.length-1),i&&i.props&&(i.props.startIndex>=0&&(o=i.props.startIndex),i.props.endIndex>=0&&(s=i.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:o,dataEndIndex:s,activeTooltipIndex:-1,isTooltipActive:!!n}},the=function(t){return!t||!t.length?!1:t.some(function(r){var n=sn(r&&r.type);return n&&n.indexOf("Bar")>=0})},Rw=function(t){return t==="horizontal"?{numericAxisName:"yAxis",cateAxisName:"xAxis"}:t==="vertical"?{numericAxisName:"xAxis",cateAxisName:"yAxis"}:t==="centric"?{numericAxisName:"radiusAxis",cateAxisName:"angleAxis"}:{numericAxisName:"angleAxis",cateAxisName:"radiusAxis"}},rhe=function(t,r){var n=t.props,i=t.graphicalItems,o=t.xAxisMap,s=o===void 0?{}:o,a=t.yAxisMap,l=a===void 0?{}:a,c=n.width,u=n.height,d=n.children,h=n.margin||{},f=Lt(d,Xi),g=Lt(d,Oi),m=Object.keys(l).reduce(function(C,S){var A=l[S],P=A.orientation;return!A.mirror&&!A.hide?G(G({},C),{},se({},P,C[P]+A.width)):C},{left:h.left||0,right:h.right||0}),p=Object.keys(s).reduce(function(C,S){var A=s[S],P=A.orientation;return!A.mirror&&!A.hide?G(G({},C),{},se({},P,Yt(C,"".concat(P))+A.height)):C},{top:h.top||0,bottom:h.bottom||0}),y=G(G({},p),m),w=y.bottom;f&&(y.bottom+=f.props.height||Xi.defaultProps.height),g&&r&&(y=hne(y,i,n,r));var b=c-y.left-y.right,x=u-y.top-y.bottom;return G(G({brushBottom:w},y),{},{width:Math.max(b,0),height:Math.max(x,0)})},nhe=function(t,r){if(r==="xAxis")return t[r].width;if(r==="yAxis")return t[r].height},DR=function(t){var r=t.chartName,n=t.GraphicalChild,i=t.defaultTooltipEventType,o=i===void 0?"axis":i,s=t.validateTooltipEventTypes,a=s===void 0?["axis"]:s,l=t.axisComponents,c=t.legendContent,u=t.formatAxisMap,d=t.defaultProps,h=function(y,w){var b=w.graphicalItems,x=w.stackGroups,C=w.offset,S=w.updateId,A=w.dataStartIndex,P=w.dataEndIndex,E=y.barSize,O=y.layout,R=y.barGap,T=y.barCategoryGap,F=y.maxBarSize,I=Rw(O),k=I.numericAxisName,B=I.cateAxisName,N=the(b),z=[];return b.forEach(function(W,D){var L=Xu(y.data,{graphicalItems:[W],dataStartIndex:A,dataEndIndex:P}),$=W.type.defaultProps!==void 0?G(G({},W.type.defaultProps),W.props):W.props,H=$.dataKey,V=$.maxBarSize,X=$["".concat(k,"Id")],Y=$["".concat(B,"Id")],re={},oe=l.reduce(function(Ne,qe){var bn,Fr,ci=w["".concat(qe.axisType,"Map")],La=$["".concat(qe.axisType,"Id")];ci&&ci[La]||qe.axisType==="zAxis"||(process.env.NODE_ENV!=="production"?Pt(!1,"Specifying a(n) ".concat(qe.axisType,"Id requires a corresponding ").concat(qe.axisType,"Id on the targeted graphical component ").concat((bn=W==null||(Fr=W.type)===null||Fr===void 0?void 0:Fr.displayName)!==null&&bn!==void 0?bn:"")):Pt());var Bo=ci[La];return G(G({},Ne),{},se(se({},qe.axisType,Bo),"".concat(qe.axisType,"Ticks"),On(Bo)))},re),K=oe[B],J=oe["".concat(B,"Ticks")],te=x&&x[X]&&x[X].hasStack&&Rne(W,x[X].stackGroups),_=sn(W.type).indexOf("Bar")>=0,ne=Sc(K,J),U=[],ce=N&&une({barSize:E,stackGroups:x,totalSize:nhe(oe,B)});if(_){var me,ae,Pe=ue(V)?F:V,Ge=(me=(ae=Sc(K,J,!0))!==null&&ae!==void 0?ae:Pe)!==null&&me!==void 0?me:0;U=dne({barGap:R,barCategoryGap:T,bandSize:Ge!==ne?Ge:ne,sizeList:ce[Y],maxBarSize:Pe}),Ge!==ne&&(U=U.map(function(Ne){return G(G({},Ne),{},{position:G(G({},Ne.position),{},{offset:Ne.position.offset-Ge/2})})}))}var ze=W&&W.type&&W.type.getComposedData;ze&&z.push({props:G(G({},ze(G(G({},oe),{},{displayedData:L,props:y,dataKey:H,item:W,bandSize:ne,barPosition:U,offset:C,stackedData:te,layout:O,dataStartIndex:A,dataEndIndex:P}))),{},se(se(se({key:W.key||"item-".concat(D)},k,oe[k]),B,oe[B]),"animationId",S)),childIndex:g5(W,y.children),item:W})}),z},f=function(y,w){var b=y.props,x=y.dataStartIndex,C=y.dataEndIndex,S=y.updateId;if(!Hy({props:b}))return null;var A=b.children,P=b.layout,E=b.stackOffset,O=b.data,R=b.reverseStackOrder,T=Rw(P),F=T.numericAxisName,I=T.cateAxisName,k=Tt(A,n),B=xne(O,k,"".concat(F,"Id"),"".concat(I,"Id"),E,R),N=l.reduce(function($,H){var V="".concat(H.axisType,"Map");return G(G({},$),{},se({},V,Qde(b,G(G({},H),{},{graphicalItems:k,stackGroups:H.axisType===F&&B,dataStartIndex:x,dataEndIndex:C}))))},{}),z=rhe(G(G({},N),{},{props:b,graphicalItems:k}),w==null?void 0:w.legendBBox);Object.keys(N).forEach(function($){N[$]=u(b,N[$],z,$.replace("Map",""),r)});var W=N["".concat(I,"Map")],D=ehe(W),L=h(b,G(G({},N),{},{dataStartIndex:x,dataEndIndex:C,updateId:S,graphicalItems:k,stackGroups:B,offset:z}));return G(G({formattedGraphicalItems:L,graphicalItems:k,offset:z,stackGroups:B},D),N)},g=function(p){function y(w){var b,x,C;return Lde(this,y),C=Nde(this,y,[w]),se(C,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),se(C,"accessibilityManager",new Sde),se(C,"handleLegendBBoxUpdate",function(S){if(S){var A=C.state,P=A.dataStartIndex,E=A.dataEndIndex,O=A.updateId;C.setState(G({legendBBox:S},f({props:C.props,dataStartIndex:P,dataEndIndex:E,updateId:O},G(G({},C.state),{},{legendBBox:S}))))}}),se(C,"handleReceiveSyncEvent",function(S,A,P){if(C.props.syncId===S){if(P===C.eventEmitterSymbol&&typeof C.props.syncMethod!="function")return;C.applySyncEvent(A)}}),se(C,"handleBrushChange",function(S){var A=S.startIndex,P=S.endIndex;if(A!==C.state.dataStartIndex||P!==C.state.dataEndIndex){var E=C.state.updateId;C.setState(function(){return G({dataStartIndex:A,dataEndIndex:P},f({props:C.props,dataStartIndex:A,dataEndIndex:P,updateId:E},C.state))}),C.triggerSyncEvent({dataStartIndex:A,dataEndIndex:P})}}),se(C,"handleMouseEnter",function(S){var A=C.getMouseInfo(S);if(A){var P=G(G({},A),{},{isTooltipActive:!0});C.setState(P),C.triggerSyncEvent(P);var E=C.props.onMouseEnter;ge(E)&&E(P,S)}}),se(C,"triggeredAfterMouseMove",function(S){var A=C.getMouseInfo(S),P=A?G(G({},A),{},{isTooltipActive:!0}):{isTooltipActive:!1};C.setState(P),C.triggerSyncEvent(P);var E=C.props.onMouseMove;ge(E)&&E(P,S)}),se(C,"handleItemMouseEnter",function(S){C.setState(function(){return{isTooltipActive:!0,activeItem:S,activePayload:S.tooltipPayload,activeCoordinate:S.tooltipPosition||{x:S.cx,y:S.cy}}})}),se(C,"handleItemMouseLeave",function(){C.setState(function(){return{isTooltipActive:!1}})}),se(C,"handleMouseMove",function(S){S.persist(),C.throttleTriggeredAfterMouseMove(S)}),se(C,"handleMouseLeave",function(S){C.throttleTriggeredAfterMouseMove.cancel();var A={isTooltipActive:!1};C.setState(A),C.triggerSyncEvent(A);var P=C.props.onMouseLeave;ge(P)&&P(A,S)}),se(C,"handleOuterEvent",function(S){var A=f5(S),P=Yt(C.props,"".concat(A));if(A&&ge(P)){var E,O;/.*touch.*/i.test(A)?O=C.getMouseInfo(S.changedTouches[0]):O=C.getMouseInfo(S),P((E=O)!==null&&E!==void 0?E:{},S)}}),se(C,"handleClick",function(S){var A=C.getMouseInfo(S);if(A){var P=G(G({},A),{},{isTooltipActive:!0});C.setState(P),C.triggerSyncEvent(P);var E=C.props.onClick;ge(E)&&E(P,S)}}),se(C,"handleMouseDown",function(S){var A=C.props.onMouseDown;if(ge(A)){var P=C.getMouseInfo(S);A(P,S)}}),se(C,"handleMouseUp",function(S){var A=C.props.onMouseUp;if(ge(A)){var P=C.getMouseInfo(S);A(P,S)}}),se(C,"handleTouchMove",function(S){S.changedTouches!=null&&S.changedTouches.length>0&&C.throttleTriggeredAfterMouseMove(S.changedTouches[0])}),se(C,"handleTouchStart",function(S){S.changedTouches!=null&&S.changedTouches.length>0&&C.handleMouseDown(S.changedTouches[0])}),se(C,"handleTouchEnd",function(S){S.changedTouches!=null&&S.changedTouches.length>0&&C.handleMouseUp(S.changedTouches[0])}),se(C,"handleDoubleClick",function(S){var A=C.props.onDoubleClick;if(ge(A)){var P=C.getMouseInfo(S);A(P,S)}}),se(C,"handleContextMenu",function(S){var A=C.props.onContextMenu;if(ge(A)){var P=C.getMouseInfo(S);A(P,S)}}),se(C,"triggerSyncEvent",function(S){C.props.syncId!==void 0&&hh.emit(fh,C.props.syncId,S,C.eventEmitterSymbol)}),se(C,"applySyncEvent",function(S){var A=C.props,P=A.layout,E=A.syncMethod,O=C.state.updateId,R=S.dataStartIndex,T=S.dataEndIndex;if(S.dataStartIndex!==void 0||S.dataEndIndex!==void 0)C.setState(G({dataStartIndex:R,dataEndIndex:T},f({props:C.props,dataStartIndex:R,dataEndIndex:T,updateId:O},C.state)));else if(S.activeTooltipIndex!==void 0){var F=S.chartX,I=S.chartY,k=S.activeTooltipIndex,B=C.state,N=B.offset,z=B.tooltipTicks;if(!N)return;if(typeof E=="function")k=E(z,S);else if(E==="value"){k=-1;for(var W=0;W<z.length;W++)if(z[W].value===S.activeLabel){k=W;break}}var D=G(G({},N),{},{x:N.left,y:N.top}),L=Math.min(F,D.x+D.width),$=Math.min(I,D.y+D.height),H=z[k]&&z[k].value,V=xg(C.state,C.props.data,k),X=z[k]?{x:P==="horizontal"?z[k].coordinate:L,y:P==="horizontal"?$:z[k].coordinate}:OR;C.setState(G(G({},S),{},{activeLabel:H,activeCoordinate:X,activePayload:V,activeTooltipIndex:k}))}else C.setState(S)}),se(C,"renderCursor",function(S){var A,P=C.state,E=P.isTooltipActive,O=P.activeCoordinate,R=P.activePayload,T=P.offset,F=P.activeTooltipIndex,I=P.tooltipAxisBandSize,k=C.getTooltipEventType(),B=(A=S.props.active)!==null&&A!==void 0?A:E,N=C.props.layout,z=S.key||"_recharts-cursor";return v.createElement(Fde,{key:z,activeCoordinate:O,activePayload:R,activeTooltipIndex:F,chartName:r,element:S,isActive:B,layout:N,offset:T,tooltipAxisBandSize:I,tooltipEventType:k})}),se(C,"renderPolarAxis",function(S,A,P){var E=Yt(S,"type.axisType"),O=Yt(C.state,"".concat(E,"Map")),R=S.type.defaultProps,T=R!==void 0?G(G({},R),S.props):S.props,F=O&&O[T["".concat(E,"Id")]];return v.cloneElement(S,G(G({},F),{},{className:ve(E,F.className),key:S.key||"".concat(A,"-").concat(P),ticks:On(F,!0)}))}),se(C,"renderPolarGrid",function(S){var A=S.props,P=A.radialLines,E=A.polarAngles,O=A.polarRadius,R=C.state,T=R.radiusAxisMap,F=R.angleAxisMap,I=gi(T),k=gi(F),B=k.cx,N=k.cy,z=k.innerRadius,W=k.outerRadius;return v.cloneElement(S,{polarAngles:Array.isArray(E)?E:On(k,!0).map(function(D){return D.coordinate}),polarRadius:Array.isArray(O)?O:On(I,!0).map(function(D){return D.coordinate}),cx:B,cy:N,innerRadius:z,outerRadius:W,key:S.key||"polar-grid",radialLines:P})}),se(C,"renderLegend",function(){var S=C.state.formattedGraphicalItems,A=C.props,P=A.children,E=A.width,O=A.height,R=C.props.margin||{},T=E-(R.left||0)-(R.right||0),F=hP({children:P,formattedGraphicalItems:S,legendWidth:T,legendContent:c});if(!F)return null;var I=F.item,k=Sw(F,Ode);return v.cloneElement(I,G(G({},k),{},{chartWidth:E,chartHeight:O,margin:R,onBBoxUpdate:C.handleLegendBBoxUpdate}))}),se(C,"renderTooltip",function(){var S,A=C.props,P=A.children,E=A.accessibilityLayer,O=Lt(P,rr);if(!O)return null;var R=C.state,T=R.isTooltipActive,F=R.activeCoordinate,I=R.activePayload,k=R.activeLabel,B=R.offset,N=(S=O.props.active)!==null&&S!==void 0?S:T;return v.cloneElement(O,{viewBox:G(G({},B),{},{x:B.left,y:B.top}),active:N,label:k,payload:N?I:[],coordinate:F,accessibilityLayer:E})}),se(C,"renderBrush",function(S){var A=C.props,P=A.margin,E=A.data,O=C.state,R=O.offset,T=O.dataStartIndex,F=O.dataEndIndex,I=O.updateId;return v.cloneElement(S,{key:S.key||"_recharts-brush",onChange:rl(C.handleBrushChange,S.props.onChange),data:E,x:Z(S.props.x)?S.props.x:R.left,y:Z(S.props.y)?S.props.y:R.top+R.height+R.brushBottom-(P.bottom||0),width:Z(S.props.width)?S.props.width:R.width,startIndex:T,endIndex:F,updateId:"brush-".concat(I)})}),se(C,"renderReferenceElement",function(S,A,P){if(!S)return null;var E=C,O=E.clipPathId,R=C.state,T=R.xAxisMap,F=R.yAxisMap,I=R.offset,k=S.type.defaultProps||{},B=S.props,N=B.xAxisId,z=N===void 0?k.xAxisId:N,W=B.yAxisId,D=W===void 0?k.yAxisId:W;return v.cloneElement(S,{key:S.key||"".concat(A,"-").concat(P),xAxis:T[z],yAxis:F[D],viewBox:{x:I.left,y:I.top,width:I.width,height:I.height},clipPathId:O})}),se(C,"renderActivePoints",function(S){var A=S.item,P=S.activePoint,E=S.basePoint,O=S.childIndex,R=S.isRange,T=[],F=A.props.key,I=A.item.type.defaultProps!==void 0?G(G({},A.item.type.defaultProps),A.item.props):A.item.props,k=I.activeDot,B=I.dataKey,N=G(G({index:O,dataKey:B,cx:P.x,cy:P.y,r:4,fill:Pm(A.item),strokeWidth:2,stroke:"#fff",payload:P.payload,value:P.value},de(k,!1)),ql(k));return T.push(y.renderActiveDot(k,N,"".concat(F,"-activePoint-").concat(O))),E?T.push(y.renderActiveDot(k,G(G({},N),{},{cx:E.x,cy:E.y}),"".concat(F,"-basePoint-").concat(O))):R&&T.push(null),T}),se(C,"renderGraphicChild",function(S,A,P){var E=C.filterFormatItem(S,A,P);if(!E)return null;var O=C.getTooltipEventType(),R=C.state,T=R.isTooltipActive,F=R.tooltipAxis,I=R.activeTooltipIndex,k=R.activeLabel,B=C.props.children,N=Lt(B,rr),z=E.props,W=z.points,D=z.isRange,L=z.baseLine,$=E.item.type.defaultProps!==void 0?G(G({},E.item.type.defaultProps),E.item.props):E.item.props,H=$.activeDot,V=$.hide,X=$.activeBar,Y=$.activeShape,re=!!(!V&&T&&N&&(H||X||Y)),oe={};O!=="axis"&&N&&N.props.trigger==="click"?oe={onClick:rl(C.handleItemMouseEnter,S.props.onClick)}:O!=="axis"&&(oe={onMouseLeave:rl(C.handleItemMouseLeave,S.props.onMouseLeave),onMouseEnter:rl(C.handleItemMouseEnter,S.props.onMouseEnter)});var K=v.cloneElement(S,G(G({},E.props),oe));function J(qe){return typeof F.dataKey=="function"?F.dataKey(qe.payload):null}if(re)if(I>=0){var te,_;if(F.dataKey&&!F.allowDuplicatedCategory){var ne=typeof F.dataKey=="function"?J:"payload.".concat(F.dataKey.toString());te=Kl(W,ne,k),_=D&&L&&Kl(L,ne,k)}else te=W==null?void 0:W[I],_=D&&L&&L[I];if(Y||X){var U=S.props.activeIndex!==void 0?S.props.activeIndex:I;return[v.cloneElement(S,G(G(G({},E.props),oe),{},{activeIndex:U})),null,null]}if(!ue(te))return[K].concat(ho(C.renderActivePoints({item:E,activePoint:te,basePoint:_,childIndex:I,isRange:D})))}else{var ce,me=(ce=C.getItemByXY(C.state.activeCoordinate))!==null&&ce!==void 0?ce:{graphicalItem:K},ae=me.graphicalItem,Pe=ae.item,Ge=Pe===void 0?S:Pe,ze=ae.childIndex,Ne=G(G(G({},E.props),oe),{},{activeIndex:ze});return[v.cloneElement(Ge,Ne),null,null]}return D?[K,null,null]:[K,null]}),se(C,"renderCustomized",function(S,A,P){return v.cloneElement(S,G(G({key:"recharts-customized-".concat(P)},C.props),C.state))}),se(C,"renderMap",{CartesianGrid:{handler:ll,once:!0},ReferenceArea:{handler:C.renderReferenceElement},ReferenceLine:{handler:ll},ReferenceDot:{handler:C.renderReferenceElement},XAxis:{handler:ll},YAxis:{handler:ll},Brush:{handler:C.renderBrush,once:!0},Bar:{handler:C.renderGraphicChild},Line:{handler:C.renderGraphicChild},Area:{handler:C.renderGraphicChild},Radar:{handler:C.renderGraphicChild},RadialBar:{handler:C.renderGraphicChild},Scatter:{handler:C.renderGraphicChild},Pie:{handler:C.renderGraphicChild},Funnel:{handler:C.renderGraphicChild},Tooltip:{handler:C.renderCursor,once:!0},PolarGrid:{handler:C.renderPolarGrid,once:!0},PolarAngleAxis:{handler:C.renderPolarAxis},PolarRadiusAxis:{handler:C.renderPolarAxis},Customized:{handler:C.renderCustomized}}),C.clipPathId="".concat((b=w.id)!==null&&b!==void 0?b:oi("recharts"),"-clip"),C.throttleTriggeredAfterMouseMove=TZ(C.triggeredAfterMouseMove,(x=w.throttleDelay)!==null&&x!==void 0?x:1e3/60),C.state={},C}return Gde(y,p),zde(y,[{key:"componentDidMount",value:function(){var b,x;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(b=this.props.margin.left)!==null&&b!==void 0?b:0,top:(x=this.props.margin.top)!==null&&x!==void 0?x:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var b=this.props,x=b.children,C=b.data,S=b.height,A=b.layout,P=Lt(x,rr);if(P){var E=P.props.defaultIndex;if(!(typeof E!="number"||E<0||E>this.state.tooltipTicks.length-1)){var O=this.state.tooltipTicks[E]&&this.state.tooltipTicks[E].value,R=xg(this.state,C,E,O),T=this.state.tooltipTicks[E].coordinate,F=(this.state.offset.top+S)/2,I=A==="horizontal",k=I?{x:T,y:F}:{y:T,x:F},B=this.state.formattedGraphicalItems.find(function(z){var W=z.item;return W.type.name==="Scatter"});B&&(k=G(G({},k),B.props.points[E].tooltipPosition),R=B.props.points[E].tooltipPayload);var N={activeTooltipIndex:E,isTooltipActive:!0,activeLabel:O,activePayload:R,activeCoordinate:k};this.setState(N),this.renderCursor(P),this.accessibilityManager.setIndex(E)}}}},{key:"getSnapshotBeforeUpdate",value:function(b,x){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==x.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==b.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==b.margin){var C,S;this.accessibilityManager.setDetails({offset:{left:(C=this.props.margin.left)!==null&&C!==void 0?C:0,top:(S=this.props.margin.top)!==null&&S!==void 0?S:0}})}return null}},{key:"componentDidUpdate",value:function(b){Jh([Lt(b.children,rr)],[Lt(this.props.children,rr)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var b=Lt(this.props.children,rr);if(b&&typeof b.props.shared=="boolean"){var x=b.props.shared?"axis":"item";return a.indexOf(x)>=0?x:o}return o}},{key:"getMouseInfo",value:function(b){if(!this.container)return null;var x=this.container,C=x.getBoundingClientRect(),S=_Z(C),A={chartX:Math.round(b.pageX-S.left),chartY:Math.round(b.pageY-S.top)},P=C.width/x.offsetWidth||1,E=this.inRange(A.chartX,A.chartY,P);if(!E)return null;var O=this.state,R=O.xAxisMap,T=O.yAxisMap,F=this.getTooltipEventType(),I=Aw(this.state,this.props.data,this.props.layout,E);if(F!=="axis"&&R&&T){var k=gi(R).scale,B=gi(T).scale,N=k&&k.invert?k.invert(A.chartX):null,z=B&&B.invert?B.invert(A.chartY):null;return G(G({},A),{},{xValue:N,yValue:z},I)}return I?G(G({},A),I):null}},{key:"inRange",value:function(b,x){var C=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,S=this.props.layout,A=b/C,P=x/C;if(S==="horizontal"||S==="vertical"){var E=this.state.offset,O=A>=E.left&&A<=E.left+E.width&&P>=E.top&&P<=E.top+E.height;return O?{x:A,y:P}:null}var R=this.state,T=R.angleAxisMap,F=R.radiusAxisMap;if(T&&F){var I=gi(T);return qb({x:A,y:P},I)}return null}},{key:"parseEventsOfWrapper",value:function(){var b=this.props.children,x=this.getTooltipEventType(),C=Lt(b,rr),S={};C&&x==="axis"&&(C.props.trigger==="click"?S={onClick:this.handleClick}:S={onMouseEnter:this.handleMouseEnter,onDoubleClick:this.handleDoubleClick,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd,onContextMenu:this.handleContextMenu});var A=ql(this.props,this.handleOuterEvent);return G(G({},A),S)}},{key:"addListener",value:function(){hh.on(fh,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){hh.removeListener(fh,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(b,x,C){for(var S=this.state.formattedGraphicalItems,A=0,P=S.length;A<P;A++){var E=S[A];if(E.item===b||E.props.key===b.key||x===sn(E.item.type)&&C===E.childIndex)return E}return null}},{key:"renderClipPath",value:function(){var b=this.clipPathId,x=this.state.offset,C=x.left,S=x.top,A=x.height,P=x.width;return v.createElement("defs",null,v.createElement("clipPath",{id:b},v.createElement("rect",{x:C,y:S,height:A,width:P})))}},{key:"getXScales",value:function(){var b=this.state.xAxisMap;return b?Object.entries(b).reduce(function(x,C){var S=ww(C,2),A=S[0],P=S[1];return G(G({},x),{},se({},A,P.scale))},{}):null}},{key:"getYScales",value:function(){var b=this.state.yAxisMap;return b?Object.entries(b).reduce(function(x,C){var S=ww(C,2),A=S[0],P=S[1];return G(G({},x),{},se({},A,P.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(b){var x;return(x=this.state.xAxisMap)===null||x===void 0||(x=x[b])===null||x===void 0?void 0:x.scale}},{key:"getYScaleByAxisId",value:function(b){var x;return(x=this.state.yAxisMap)===null||x===void 0||(x=x[b])===null||x===void 0?void 0:x.scale}},{key:"getItemByXY",value:function(b){var x=this.state,C=x.formattedGraphicalItems,S=x.activeItem;if(C&&C.length)for(var A=0,P=C.length;A<P;A++){var E=C[A],O=E.props,R=E.item,T=R.type.defaultProps!==void 0?G(G({},R.type.defaultProps),R.props):R.props,F=sn(R.type);if(F==="Bar"){var I=(O.data||[]).find(function(z){return Sse(b,z)});if(I)return{graphicalItem:E,payload:I}}else if(F==="RadialBar"){var k=(O.data||[]).find(function(z){return qb(b,z)});if(k)return{graphicalItem:E,payload:k}}else if(Nu(E,S)||$u(E,S)||la(E,S)){var B=Aae({graphicalItem:E,activeTooltipItem:S,itemData:T.data}),N=T.activeIndex===void 0?B:T.activeIndex;return{graphicalItem:G(G({},E),{},{childIndex:N}),payload:la(E,S)?T.data[B]:E.props.data[B]}}}return null}},{key:"render",value:function(){var b=this;if(!Hy(this))return null;var x=this.props,C=x.children,S=x.className,A=x.width,P=x.height,E=x.style,O=x.compact,R=x.title,T=x.desc,F=Sw(x,Mde),I=de(F,!1);if(O)return v.createElement(tw,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},v.createElement(Zh,bi({},I,{width:A,height:P,title:R,desc:T}),this.renderClipPath(),Wy(C,this.renderMap)));if(this.props.accessibilityLayer){var k,B;I.tabIndex=(k=this.props.tabIndex)!==null&&k!==void 0?k:0,I.role=(B=this.props.role)!==null&&B!==void 0?B:"application",I.onKeyDown=function(z){b.accessibilityManager.keyboardEvent(z)},I.onFocus=function(){b.accessibilityManager.focus()}}var N=this.parseEventsOfWrapper();return v.createElement(tw,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},v.createElement("div",bi({className:ve("recharts-wrapper",S),style:G({position:"relative",cursor:"default",width:A,height:P},E)},N,{ref:function(W){b.container=W}}),v.createElement(Zh,bi({},I,{width:A,height:P,title:R,desc:T,style:qde}),this.renderClipPath(),Wy(C,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])}(v.Component);se(g,"displayName",r),se(g,"defaultProps",G({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},d)),se(g,"getDerivedStateFromProps",function(p,y){var w=p.dataKey,b=p.data,x=p.children,C=p.width,S=p.height,A=p.layout,P=p.stackOffset,E=p.margin,O=y.dataStartIndex,R=y.dataEndIndex;if(y.updateId===void 0){var T=Pw(p);return G(G(G({},T),{},{updateId:0},f(G(G({props:p},T),{},{updateId:0}),y)),{},{prevDataKey:w,prevData:b,prevWidth:C,prevHeight:S,prevLayout:A,prevStackOffset:P,prevMargin:E,prevChildren:x})}if(w!==y.prevDataKey||b!==y.prevData||C!==y.prevWidth||S!==y.prevHeight||A!==y.prevLayout||P!==y.prevStackOffset||!Fi(E,y.prevMargin)){var F=Pw(p),I={chartX:y.chartX,chartY:y.chartY,isTooltipActive:y.isTooltipActive},k=G(G({},Aw(y,b,A)),{},{updateId:y.updateId+1}),B=G(G(G({},F),I),k);return G(G(G({},B),f(G({props:p},B),y)),{},{prevDataKey:w,prevData:b,prevWidth:C,prevHeight:S,prevLayout:A,prevStackOffset:P,prevMargin:E,prevChildren:x})}if(!Jh(x,y.prevChildren)){var N,z,W,D,L=Lt(x,Xi),$=L&&(N=(z=L.props)===null||z===void 0?void 0:z.startIndex)!==null&&N!==void 0?N:O,H=L&&(W=(D=L.props)===null||D===void 0?void 0:D.endIndex)!==null&&W!==void 0?W:R,V=$!==O||H!==R,X=!ue(b),Y=X&&!V?y.updateId:y.updateId+1;return G(G({updateId:Y},f(G(G({props:p},y),{},{updateId:Y,dataStartIndex:$,dataEndIndex:H}),y)),{},{prevChildren:x,dataStartIndex:$,dataEndIndex:H})}return null}),se(g,"renderActiveDot",function(p,y,w){var b;return v.isValidElement(p)?b=v.cloneElement(p,y):ge(p)?b=p(y):b=v.createElement(zu,y),v.createElement(be,{className:"recharts-active-dot",key:w},b)});var m=v.forwardRef(function(y,w){return v.createElement(g,bi({},y,{ref:w}))});return m.displayName=g.displayName,m},ihe=DR({chartName:"BarChart",GraphicalChild:We,defaultTooltipEventType:"axis",validateTooltipEventTypes:["axis","item"],axisComponents:[{axisType:"xAxis",AxisComp:Yu},{axisType:"yAxis",AxisComp:Ju}],formatAxisMap:zP}),ohe=DR({chartName:"ComposedChart",GraphicalChild:[fr,St,We,qu],axisComponents:[{axisType:"xAxis",AxisComp:Yu},{axisType:"yAxis",AxisComp:Ju},{axisType:"zAxis",AxisComp:Ku}],formatAxisMap:zP});const she=(e,t,r)=>r.payload.name==="longtail"?[e,t]:[e,r.payload.name],ahe=({active:e,payload:t,screenCoords:r})=>{if(e&&t&&t.length&&r){const n=t[0].payload.name;return ma.createPortal(M.jsx("div",{style:{backgroundColor:"#eee",padding:"5px 10px 5px 10px",color:"#111",position:"absolute",top:r.y+10,left:r.x+10},children:M.jsx("p",{className:"label",children:`${n} : ${t[0].value}`})}),document.body)}return null},Ag={unique:"#0f0",longtail:"teal",NA:"red",cat_pop:"pink"};function lhe(e){return e==="light"?{unique:"#228B22",longtail:"#006060",NA:"#cc0000",cat_pop:"#c06"}:Ag}const che=e=>{const t={custom1_color:"teal",custom2_color:"orange",custom3_color:"purple"},r=e.colors?e.colors:{},n={...t,...r},{custom1_color:i,custom2_color:o,custom3_color:s}=n,a=c=>{if(c===void 0)return M.jsx("span",{});const u=c.value;return u===void 0||!He(u)?M.jsx("span",{}):l({histogramArr:u})},l=({histogramArr:c})=>{const u=(f,g)=>{console.log("dumbClickHandler",f)},[d,h]=v.useState(null);return M.jsx("div",{className:"histogram-component",children:M.jsxs(ohe,{width:100,height:24,data:c,onClick:u,onMouseMove:(f,g)=>{h({x:g.clientX,y:g.clientY})},children:[M.jsx(We,{dataKey:"barRed",stroke:"red",fill:"red",isAnimationActive:!1,stackId:"stack"}),M.jsx(We,{dataKey:"barBlue",stroke:"blue",fill:"blue",isAnimationActive:!1,stackId:"stack"}),M.jsx(We,{dataKey:"barGrayed",stroke:"gray",fill:"Gray",isAnimationActive:!1,stackId:"stack"}),M.jsx(We,{dataKey:"barCustom1",stroke:i,fill:i,isAnimationActive:!1,stackId:"stack"}),M.jsx(We,{dataKey:"barCustom2",stroke:o,fill:o,isAnimationActive:!1,stackId:"stack"}),M.jsx(We,{dataKey:"barCustom3",stroke:s,fill:s,isAnimationActive:!1,stackId:"stack"}),M.jsx(fr,{type:"monotone",dataKey:"lineRed",stroke:"red",fill:"red",isAnimationActive:!1}),M.jsx(fr,{type:"monotone",dataKey:"lineBlue",stroke:"blue",fill:"blue",isAnimationActive:!1}),M.jsx(fr,{type:"monotone",dataKey:"lineGray",stroke:"gray",fill:"gray",isAnimationActive:!1}),M.jsx(fr,{type:"monotone",dataKey:"lineCustom1",stroke:i,fill:i,isAnimationActive:!1}),M.jsx(fr,{type:"monotone",dataKey:"lineCustom2",stroke:o,fill:o,isAnimationActive:!1}),M.jsx(fr,{type:"monotone",dataKey:"lineCustom3",stroke:s,fill:s,isAnimationActive:!1}),M.jsx(St,{type:"monotone",dataKey:"areaBlue",stroke:"blue",fill:"blue",isAnimationActive:!1}),M.jsx(St,{type:"monotone",dataKey:"areaRed",stroke:"red",fill:"red",isAnimationActive:!1}),M.jsx(St,{type:"monotone",dataKey:"areaGray",stroke:"gray",fill:"gray",isAnimationActive:!1}),M.jsx(St,{type:"monotone",dataKey:"areaUnique",stroke:Ag.unique,fill:Ag.unique,isAnimationActive:!1}),M.jsx(St,{type:"monotone",dataKey:"areaCustom1",stroke:i,fill:i,isAnimationActive:!1}),M.jsx(St,{type:"monotone",dataKey:"areaCustom2",stroke:o,fill:o,isAnimationActive:!1}),M.jsx(St,{type:"monotone",dataKey:"areaCustom3",stroke:s,fill:s,isAnimationActive:!1}),M.jsx(rr,{formatter:she,allowEscapeViewBox:{x:!0,y:!0},wrapperStyle:{zIndex:99999999,color:"#111"},content:f=>M.jsx(ahe,{...f,screenCoords:d})})]})})};return a},uhe=(e,t,r)=>r.payload.name==="longtail"?[e,t]:[e,r.payload.name],dhe=({active:e,payload:t,screenCoords:r})=>{if(e&&t&&t.length&&r){const n=t[0].payload.name;return ma.createPortal(M.jsx("div",{style:{backgroundColor:"#eee",padding:"5px 10px 5px 10px",color:"#111",position:"absolute",top:r.y+10,left:r.x+10},children:M.jsx("p",{className:"label",children:`${n} : ${t[0].value}%`})}),document.body)}return null},Dm=e=>{const t=Op();if(e===void 0)return M.jsx("span",{});const r=e.value;if(r===void 0||!He(r))return M.jsx("span",{});const n=r,i=e.colDef.cellClass,o=typeof i=="string"?i:"";return M.jsx(hhe,{histogramArr:n,context:e.context,className:o,colorScheme:t})},hhe=({histogramArr:e,context:t,className:r,colorScheme:n="dark"})=>{const i=(P,E)=>{console.log("dumbClickHandler",P,t)},o=lhe(n),s=n==="light",a=s?"#888":"#000",l=s?"#999":"gray",c=s?"#666":"#000",u=P=>{const E=`${P}-${crypto.randomUUID()}`;return[E,`url(#${E})`]},[d,h]=u("star"),[f,g]=u("stripe"),[m,p]=u("circle"),[y,w]=u("checkers"),[b,x]=u("leafs"),[C,S]=v.useState(null),A=`histogram-component ${r}`;return M.jsx("div",{className:A,children:M.jsxs(ihe,{width:100,height:24,barGap:1,data:e,onClick:i,onMouseMove:(P,E)=>{S({x:E.clientX,y:E.clientY})},children:[M.jsxs("defs",{children:[M.jsx("pattern",{id:d,width:"10",height:"10",patternUnits:"userSpaceOnUse",children:M.jsx("polygon",{stroke:o.cat_pop,points:"0,0 2,5 0,10 5,8 10,10 8,5 10,0 5,2"})}),M.jsx("pattern",{id:f,width:"4",height:"4",patternUnits:"userSpaceOnUse",patternTransform:"rotate(45)",children:M.jsx("rect",{width:"2",height:"4",fill:o.NA})}),M.jsx("pattern",{id:m,width:"4",height:"4",patternUnits:"userSpaceOnUse",children:M.jsx("circle",{"data-color":"outline",stroke:o.cat_pop,cx:".5",cy:".5",r:"1.5"})}),M.jsxs("pattern",{id:y,x:"0",y:"0",width:"4",height:"4",patternUnits:"userSpaceOnUse",children:[M.jsx("rect",{stroke:o.unique,x:"0",width:"2",height:"2",y:"0"}),M.jsx("rect",{x:"2",width:"2",height:"2",y:"2"})]}),M.jsx("pattern",{id:b,x:"0",y:"0",width:"6",height:"6",patternUnits:"userSpaceOnUse",patternTransform:"translate(1, 1) rotate(0) skewX(0)",children:M.jsx("svg",{width:"5",height:"5",viewBox:"0 0 100 100",children:M.jsx("g",{fill:o.longtail,opacity:"1",children:M.jsx("path",{d:"M99.9557 99.9557C45.4895 98.3748 1.6248 54.5101 0.0439453 0.0439453C54.5101 1.6248 98.3748 45.4895 99.9557 99.9557Z"})})})})]}),M.jsx(We,{dataKey:"population",stroke:a,fill:l,stackId:"stack",isAnimationActive:!1}),M.jsx(We,{dataKey:"tail",stroke:a,fill:l,stackId:"stack",isAnimationActive:!1}),M.jsx(We,{dataKey:"true",stroke:"#00f",fill:"#00f",stackId:"stack",isAnimationActive:!1}),M.jsx(We,{dataKey:"false",stroke:c,fill:"#fff",stackId:"stack",isAnimationActive:!1}),M.jsx(We,{dataKey:"cat_pop",stroke:o.cat_pop,fill:p,stackId:"stack",isAnimationActive:!1}),M.jsx(We,{dataKey:"unique",stroke:o.unique,fill:w,stackId:"stack",isAnimationActive:!1}),M.jsx(We,{dataKey:"longtail",stroke:o.longtail,fill:x,stackId:"stack",isAnimationActive:!1}),M.jsx(We,{dataKey:"user1",stroke:o.longtail,fill:h,stackId:"stack",isAnimationActive:!1}),M.jsx(We,{dataKey:"NA",fill:g,stackId:"stack",isAnimationActive:!1}),M.jsx(rr,{formatter:uhe,allowEscapeViewBox:{x:!0,y:!0},wrapperStyle:{zIndex:99999999,color:"#111"},content:P=>M.jsx(dhe,{...P,screenCoords:C})})]})})},ph=new Intl.NumberFormat("en-US",{minimumFractionDigits:0,maximumFractionDigits:3}),Ew=e=>r=>{const n=r.value;if(n&&e.max_length&&typeof n=="string")try{return n.slice(0,e.max_length)}catch(i){return console.log("e",i,"val",n),""}return n},fhe=e=>`{ ${Rt(e,(r,n)=>`'${n}': ${km(r)}`).join(",")} }`,kR=e=>!!(ZD(e)&&isFinite(e.getTime())),ghe={year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1},phe=e=>{const t=e.toLocaleDateString("en-CA",ghe),[r,n]=t.split(",");return`${r} ${n}`},km=e=>e==null?"None":He(e)?`[ ${e.map(km).join(", ")}]`:YD(e)?_R(e):Ft(e)?fhe(e):e.toString(),IR=e=>r=>{const n=r.value,i=km(n);return e.max_length?i.slice(0,e.max_length):i},mhe=IR({}),_R=e=>e===!0?"True":e===!1?"False":"",vhe=e=>{const t=e.value;return _R(t)},yhe=e=>{const r=Math.floor(e.max_digits/3)+e.max_digits,n=new Intl.NumberFormat("en-US");return o=>{const s=o.value;return s===null||s===void 0?"":n.format(o.value).padStart(r," ")}},bhe=e=>{const t=new Intl.NumberFormat("en-US",{minimumFractionDigits:e.min_fraction_digits,maximumFractionDigits:e.max_fraction_digits});return r=>{if(r.value===null||r.value===void 0)return"";const n=t.format(r.value);if(Ii(n,".")){const i=n.split(".")[1],o=e.max_fraction_digits-i.length+n.length;return n.padEnd(o)}else{const i=n.length+e.max_fraction_digits+1;return n.padEnd(i)}}},Che=e=>t=>{const r=t.value;if(r==null)return"";const n=new Date(r);return kR(n)?n.toLocaleDateString(e.locale,e.args):""},whe=new Intl.NumberFormat("en",{notation:"compact",maximumFractionDigits:1}),She=()=>e=>e.value===null||e.value===void 0?"":whe.format(e.value),xhe=e=>{let t=0,r=0,n=0,i=0;const o=e.match(/^P(?:(\d+)D)?T(?:(\d+)H)?(?:(\d+)M)?(?:([\d.]+)S)?$/);if(o)t=parseInt(o[1]||"0",10),r=parseInt(o[2]||"0",10),n=parseInt(o[3]||"0",10),i=parseFloat(o[4]||"0");else{const a=e.match(/^(-?\d+)\s+days?\s+(\d{2}):(\d{2}):(\d{2}(?:\.\d+)?)$/);if(a)t=Math.abs(parseInt(a[1],10)),r=parseInt(a[2],10),n=parseInt(a[3],10),i=parseFloat(a[4]);else return e}if(t===0&&r===0&&n===0&&i===0)return"0s";const s=[];if(t>0&&s.push(`${t}d`),r>0&&s.push(`${r}h`),n>0&&s.push(`${n}m`),i>0)if(i<.001)s.push(`${Math.round(i*1e6)}µs`);else if(i<1){const a=i*1e3;s.push(a===Math.floor(a)?`${a}ms`:`${a.toFixed(1)}ms`)}else s.push(i===Math.floor(i)?`${i}s`:`${i.toFixed(3)}s`);return s.join(" ")},Ahe=()=>e=>{const t=e.value;if(t==null)return"";if(typeof t=="string")return xhe(t);if(typeof t=="number"){const r=Math.abs(t);if(r===0)return"0s";const n=t<0?"-":"",i=Math.floor(r/864e5),o=Math.floor(r%864e5/36e5),s=Math.floor(r%36e5/6e4),a=r%6e4/1e3,l=[];return i>0&&l.push(`${i}d`),o>0&&l.push(`${o}h`),s>0&&l.push(`${s}m`),a>0&&l.push(a===Math.floor(a)?`${a}s`:`${a.toFixed(3)}s`),n+l.join(" ")}return String(t)},Phe=e=>{const t=e.value;if(t==null)return"";const r=new Date(t);return kR(r)?phe(r):""};function LR(e){switch(e.displayer){case"integer":return yhe(e);case"string":return Ew(e);case"datetimeDefault":return Phe;case"datetimeLocaleString":return Che(e);case"float":return bhe(e);case"boolean":return vhe;case"obj":return IR(e);case"compact_number":return She();case"duration":return Ahe();default:return Ew({displayer:"string"})}}function BR(e){switch(e.displayer){case"histogram":return Dm;case"chart":return che(e);case"linkify":return J4;case"Base64PNGImageDisplayer":return X4;case"boolean_checkbox":return"agCheckboxCellRenderer";case"SVGDisplayer":return Z4}}function zR(e){return Ii(D2,e.displayer)?void 0:LR(e)}function Rhe(e){const t=zR(e);return e.displayer==="compact_number"&&t!==void 0?{valueFormatter:t,tooltipValueGetter:r=>r.value!=null?String(r.value):""}:t!==void 0?{valueFormatter:t}:Ii(D2,e.displayer)?{cellRenderer:BR(e)}:{}}function Ehe(e,t){return Rt(Rt(t,"primary_key_val"),r=>El(e,{index:r}))}const Im=e=>Ss(e,"col_path")?e.field:e.col_name;function NR(e){const t=e.color_map_config?aH(e.color_map_config):{};return{field:Im(e),cellDataType:!1,cellStyle:void 0,...Rhe(e.displayer_args),...t,...xG(e.tooltip_config),...e.ag_grid_specs}}function The(e){return{headerName:e.header_name,...NR(e)}}const Pg=(e,t)=>{const r=n=>Ss(n,"col_path")?n.col_path[t]:n.col_name+"!&single"+P2(e,n).toString();return e.reduce((n,i)=>{const o=r(i),s=n[n.length-1];return!s||r(s[0])!==o?n.push([i]):s.push(i),n},[])};function Tw(e,t){return console.log("f",e,e.ag_grid_specs),{headerName:e.col_path[t],...NR(e)}}function $R(e,t=0){if(e.length==0)throw new Error("f shouldn't be empty");const r=e[0].col_path,n=r[t],i=r.length;if(t==i)throw new Error("something went wrong, level is too deep");const o=t+1;if(i==1){const s={children:Rt(e,a=>Tw(a,0)),...e[0].ag_grid_specs};return console.log(" colDef from multiIndexColToColDef",s),s}if(o==i-1){const s={headerName:n,children:Rt(e,a=>Tw(a,o)),...e[0].ag_grid_specs};return console.log(" colDef from multiIndexColToColDef",s),s}else{const s=Pg(e,o),a={headerName:n,children:Rt(s,l=>$R(l,o)),...e[0].ag_grid_specs};return console.log(" colDef from multiIndexColToColDef",a),a}}const Fw=e=>{if(e.length==0)throw new Error("x shouldn't be empty");if(Ss(e[0],"col_path"))return $R(e);if(e.length>1)throw new Error(`for NormalColumnConfig, length should be 1, improperly grouped ${e}`);return The(e[0])};function cl(e,t,r){const n=$M(e);return n[t]===void 0?n[t]=r:(console.log("c",n,t),He(n[t])?n[t].push(r):n[t]=[n[t],r]),n}function Fhe(e){const i=Pg(e.left_col_configs,0).map(Fw).map(d=>cl(d,"headerClass","left_col_configs_header")).map(d=>cl(d,"cellClass","left_col_configs_cell"));if(i.length>0){const d=i.length-1;i[d]=cl(i[d],"headerClass","left_col_configs_header_last"),i[d]=cl(i[d],"cellClass","left_col_configs_cell_last")}const o=d=>({...d,pinned:"left"}),s=i.map(o),a=e.column_config,c=Pg(a,0).map(Fw);return[...s,...c]}function Ohe(e,t){const r={component:Dd(mhe)},n={};for(const i of t){const o=Im(i),s=zR(i.displayer_args);s&&(n[o]=s)}return i=>{var o;if(i.node.rowPinned){const s=ws(i.node.data,"index");if(s===void 0)return r;const a=El(e,{primary_key_val:s});if(a===void 0)return r;const l=a,c=(o=i.column)==null?void 0:o.getColId();if(l.default_renderer_columns===void 0&&c==="index"||Ii(l.default_renderer_columns,c))return r;if(l.displayer_args.displayer==="inherit"){const d=c?n[c]:void 0;return d?{component:Dd(d)}:r}const u=BR(l.displayer_args);return u===void 0?{component:Dd(LR(l.displayer_args))}:{component:u}}else return}}function Mhe(e){const t=El(e,{index:"histogram_bins"})||{},r=El(e,{index:"histogram_log_bins"})||{},n=uk(ck(Xt(t),Xt(r)),"index"),i=Rt(n,o=>({histogram_bins:ws(t,o,[]),histogram_log_bins:ws(r,o,[])}));return hk(n,i)}const HR=e=>{const t=new Date;return{createTime:t,rowCount:void 0,getRows:n=>{var c;console.log("gridUtils 198 calling getRows createTime",t,new Date-t);const i=n.sortModel,o=JSON.stringify((c=n.context)==null?void 0:c.outside_df_params),s={sourceName:o,start:n.startRow,end:n.startRow+1e3,origEnd:n.endRow,sort:i.length===1?i[0].colId:void 0,sort_direction:i.length===1?i[0].sort:void 0};console.log("[getRows] dsPayloadArgs",s,"context.outside_df_params",o);const a=(u,d)=>{console.log("successWrapper called 217",t,new Date-t),n.successCallback(u,d)},l=()=>{console.log("request failed for ",s),n.failCallback()};e.getRequestRows(s,a,l)}}},Dhe=(e,t,r,n)=>Ihe({numRows:t,pinnedRowLen:e,location:window.location,compC:r,rowHeight:n}),khe=()=>window.vscIPyWidgets!==void 0,Ihe=e=>{const{numRows:t,pinnedRowLen:r,location:n,rowHeight:i,compC:o}=e,s=n.host.indexOf("colab.googleusercontent.com")!==-1,a=window.parent!==window,l=window.innerHeight/((o==null?void 0:o.height_fraction)||2),c=(o==null?void 0:o.dfvHeight)||l;console.log("314, ",l,window.innerHeight,(o==null?void 0:o.height_fraction)||2,o==null?void 0:o.dfvHeight,l,c);const u={height:c,overflow:"hidden"},d={minHeight:50,maxHeight:c,overflow:"hidden"},f=Math.floor(c/(i||21)-3),g=t+r<f;console.log("belowMinRows",g,t,r,f);const m=(o==null?void 0:o.shortMode)||g&&i===void 0;console.log("shortMode",m,o==null?void 0:o.shortMode,g,i);const p=a?"in-iframe":"";if(s||khe()||a&&window.innerHeight<300)return{classMode:"regular-mode",domLayout:"normal",applicableStyle:{height:500},inIframe:p,maxRowsWithoutScrolling:f};const y=(o==null?void 0:o.layoutType)||(m?"autoHeight":"normal"),w=m?d:u;return console.log("351 gridUtils",m,d,u),{classMode:m?"short-mode":"regular-mode",domLayout:y,applicableStyle:w,inIframe:p,maxRowsWithoutScrolling:f}},_he=e=>e<1?{type:"fitProvidedWidth",width:window.innerWidth-100}:{type:"fitCellContents"},GR={spacing:5,cellHorizontalPaddingScale:.3,columnBorder:!0,rowBorder:!1,rowVerticalPaddingScale:.5,wrapperBorder:!1,fontSize:12,dataFontSize:"12px",headerFontSize:14,iconSize:10,headerVerticalPaddingScale:.6},Lhe=MS.withPart(pz).withParams({...GR,browserColorScheme:"dark",backgroundColor:"#181D1F",oddRowBackgroundColor:"#222628"}),Bhe=MS.withPart(fz).withParams({...GR,browserColorScheme:"light",backgroundColor:"#ffffff",oddRowBackgroundColor:"#f5f5f5"});function WR(e,t){const r=t==null?void 0:t.colorScheme;return r&&r!=="auto"?r:e}function jR(e,t){if(!t)return;const r=e==="light"?t.light:t.dark;return r?{...t,...r}:t}function VR(e,t){const r=e==="light"?Bhe:Lhe;if(!t)return r;const n={};return t.backgroundColor&&(n.backgroundColor=t.backgroundColor),t.foregroundColor&&(n.foregroundColor=t.foregroundColor),t.oddRowBackgroundColor&&(n.oddRowBackgroundColor=t.oddRowBackgroundColor),t.borderColor&&(n.borderColor=t.borderColor),t.headerBorderColor&&(n.headerColumnBorderColor=t.headerBorderColor),t.headerBackgroundColor&&(n.headerBackgroundColor=t.headerBackgroundColor),t.spacing!=null&&(n.spacing=t.spacing),t.cellHorizontalPaddingScale!=null&&(n.cellHorizontalPaddingScale=t.cellHorizontalPaddingScale),t.rowVerticalPaddingScale!=null&&(n.rowVerticalPaddingScale=t.rowVerticalPaddingScale),Object.keys(n).length===0?r:r.withParams(n)}function Zu({df_viewer_config:e,activeColumn:t,operations:r,setOperations:n,operation_result:i,command_config:o}){const s=e.column_config.map(Im);return M.jsx("div",{className:"columns-editor",style:{width:"100%"},children:M.jsxs("div",{children:[M.jsx(Zg,{operations:r,setOperations:n,activeColumn:t[1],allColumns:s,command_config:o}),M.jsx(Qg,{filledOperations:r,operation_result:i})]})})}const zhe=function(e){return M.jsx("a",{href:"https://buckaroo-data.readthedocs.io/en/latest/feature_reference.html",target:"_blank",rel:"noopener noreferrer",children:"?"})},Nhe=function(e){const t=e.value,r=e.context.buckarooOptions.df_display,n=i=>{const o=fo(e.context.buckarooState);o.df_display=i.target.value,e.context.setBuckarooState(o)};return M.jsx("select",{value:t,onChange:n,style:{width:"100%",background:"transparent",border:"none",color:"inherit"},children:r.map(i=>M.jsx("option",{value:i,children:i},i))})},$he=function(e){const t=e.value,r=e.context.buckarooOptions.cleaning_method,n=i=>{const o=fo(e.context.buckarooState);o.cleaning_method=i.target.value,e.context.setBuckarooState(o)};return M.jsx("select",{value:t,onChange:n,style:{width:"100%",background:"transparent",border:"none",color:"inherit"},children:r.map(i=>M.jsx("option",{value:i,children:i},i))})},Hhe=function(e){const t=e.value,r=e.context.buckarooOptions.post_processing,n=i=>{const o=fo(e.context.buckarooState);o.post_processing=i.target.value,e.context.setBuckarooState(o)};return M.jsx("select",{value:t,onChange:n,style:{width:"100%",background:"transparent",border:"none",color:"inherit"},children:r.map(i=>M.jsx("option",{value:i,children:i},i))})},Ghe=function(e){const t=e.value==="1",r=n=>{const i=fo(e.context.buckarooState);i.show_commands=n.target.checked?"1":"0",e.context.setBuckarooState(i)};return M.jsx("input",{type:"checkbox",checked:t,onChange:r,style:{margin:"0 auto",display:"block"}})},Whe=function(e){const t=e.value,[r,n]=v.useState(t||""),i=()=>{e.setValue(r===""?null:r)},o=s=>{s.key==="Enter"&&(s.preventDefault(),i())};return M.jsxs("div",{className:"FakeSearchEditor",tabIndex:1,style:{display:"flex",flexDirection:"row",width:"100%"},children:[M.jsx("input",{type:"text",style:{flex:"1 1 auto",minWidth:0},value:r,onChange:({target:{value:s}})=>n(s),onSubmit:i,onKeyDown:o}),M.jsx("button",{style:{flex:"none"},onClick:i,children:"🔍"}),M.jsx("button",{style:{flex:"none"},onClick:s=>{console.log("clickParams",s),e.setValue("")},children:"X"})]})},jhe=v.memo(({value:e,onValueChange:t,stopEditing:r})=>{const[n,i]=v.useState(!1),o=v.useRef(null);return v.useEffect(()=>{var s;(s=o.current)==null||s.focus(),i(!0)},[]),M.jsxs("div",{className:"SearchEditor",ref:o,tabIndex:1,style:{display:"flex",flexDirection:"row"},children:[M.jsx("input",{type:"text",style:{flex:"auto",width:150},value:e||"",onChange:({target:{value:s}})=>t(s===""?null:s)}),M.jsx("button",{style:{flex:"none"},onClick:()=>{t(""),r()},children:"X"})]})});function Ia({dfMeta:e,buckarooState:t,setBuckarooState:r,buckarooOptions:n,heightOverride:i,themeConfig:o}){var O;const s=n,a=x2(Rt(Xt(s),R=>[R,P2(s[R],t[R])])),l=(R,T)=>R===T.length-1?0:R+1,c=R=>{const T=s[R],F=a[R],I=l(F,T),k=T[I],B=fo(t);return B[R]=k,B},u=["quick_command_args","search","show_displayed_rows"],d=R=>{console.log("event.column",R.column,R.column.getColId());const T=R.column.getColId();if(!Ii(u,T)&&Ii(Xt(t),T)){const F=c(T);r(F)}},h=v.useCallback(R=>{const{oldValue:T,newValue:F}=R;if(T!==F&&F!==null){const I={...t,quick_command_args:{search:[F]}};r(I)}},[]),f=[{field:"search",headerName:"search",width:200,cellEditor:jhe,cellRenderer:Whe,onCellValueChanged:h},{field:"df_display",headerName:"Σ",headerTooltip:"Summary Stats",width:120,cellRenderer:Nhe},{field:"post_processing",headerName:"post processing",headerTooltip:"post process method",width:100,cellRenderer:Hhe},{field:"show_commands",headerName:"λ",headerTooltip:"Show Commands",width:30,cellRenderer:Ghe},{field:"cleaning_method",headerName:"cleaning",headerTooltip:"Auto cleaning method",width:80,cellRenderer:$he},{field:"help",headerName:"?",headerTooltip:"Help",width:30,cellRenderer:zhe},{field:"total_rows",width:100},{field:"filtered_rows",headerName:"filtered",width:85},{field:"rows_shown",headerName:"displayed",width:85,hide:e.rows_shown===-1},{field:"columns",width:75}],g=(O=t.quick_command_args)==null?void 0:O.search,m=g&&g.length===1?g[0]:"",p=[{total_rows:ph.format(e.total_rows),columns:e.columns,rows_shown:ph.format(e.rows_shown),cleaning_method:t.cleaning_method||"0",df_display:t.df_display,filtered_rows:ph.format(e.filtered_rows),post_processing:t.post_processing,show_commands:t.show_commands||"0",search:m}],y={suppressRowClickSelection:!0},w=v.useRef(null),b=v.useCallback(R=>{console.log("StatusBar252 onGridReady statusbar",R)},[]),x={sortable:!1,cellStyle:{textAlign:"left"}},C=Op(),S=WR(C,o),A=jR(S,o),P=v.useMemo(()=>VR(S,A).withParams({headerFontSize:14,rowVerticalPaddingScale:.8}),[S,A]),E=S==="light"?"ag-theme-alpine":"ag-theme-alpine-dark";return M.jsx("div",{className:"status-bar",children:M.jsx("div",{className:`theme-hanger ${E}`,children:M.jsx(QS,{ref:w,theme:P,loadThemeGoogleFonts:!0,onCellEditingStopped:b,onColumnHeaderClicked:d,onGridReady:b,gridOptions:y,defaultColDef:x,rowData:p,domLayout:"autoHeight",columnDefs:f,context:{buckarooState:t,setBuckarooState:r,buckarooOptions:n}})})})}function UR({df_data_dict:e,df_display_args:t,df_meta:r,operations:n,on_operations:i,operation_results:o,command_config:s,buckaroo_state:a,on_buckaroo_state:l,buckaroo_options:c}){var m,p;const[u,d]=v.useState(["a","stoptime"]),h=t[a.df_display];h===void 0&&console.log("cDisp undefined",a.df_display,c.df_display);const f=e[h.data_key],g=e[h.summary_stats_key];return M.jsxs("div",{className:"dcf-root flex flex-col buckaroo-widget",style:{width:"100%",height:"100%"},children:[M.jsxs("div",{className:"orig-df",style:{overflow:"hidden"},children:[M.jsx(Ia,{dfMeta:r,buckarooState:a,setBuckarooState:l,buckarooOptions:c,themeConfig:(p=(m=h.df_viewer_config)==null?void 0:m.component_config)==null?void 0:p.theme}),M.jsx(gu,{df_data:f,df_viewer_config:h.df_viewer_config,summary_stats_data:g,activeCol:u,setActiveCol:d})]}),a.show_commands?M.jsx(Zu,{df_viewer_config:h.df_viewer_config,activeColumn:u,operations:n,setOperations:i,operation_result:o,command_config:s}):M.jsx("span",{})]})}const ul=e=>`${e.sourceName}-${e.start}-${e.end}-${e.sort}-${e.sort_direction}`,mh=e=>`${e.sourceName}-${e.sort}-${e.sort_direction}`,KR=(e,t,r,n)=>{if(e.length==0)return[[r],[n]];const[i,o]=r,[s,a]=e[0];if(o<s)return[[r,...e],[n,...t]];const[l,c]=[[],[]];for(var u=0;u<e.length;u++){const[f,g]=[e[u],t[u]];if(Lo(f,r)){const[m,p]=qR([f,g],[r,n]),y=l.concat(e.slice(u+1)),w=c.concat(t.slice(u+1));return KR(y,w,m,p)}l.push(f),c.push(g),u<e.length-1&&YR(r,f,e[u+1])&&(l.push(r),c.push(n))}const[d,h]=e[e.length-1];return h<i&&(l.push(r),c.push(n)),[l,c]},qR=(e,t)=>{const[r,n]=e,[i,o]=t;if(Qu(i,r))return qR(t,e);const[s,a]=r,[l,c]=i;if(s<l&&c<a)return e;if(a===l){const h=n.concat(o);return[[s,c],h]}const u=l-a,d=n.slice(0,u).concat(o);return[[s,c],d]},YR=(e,t,r)=>{if(Qu(r,t))return YR(e,r,t);const[n,i]=e,o=t[1],s=r[0];return o<n&&i<s},Qu=(e,t)=>{const[r,n]=e,[i,o]=t;return r<i?!0:r==i&&n<o},Jc=(e,t)=>{const[r,n]=e,[i,o]=t;return r<=i&&o<=n},Lo=(e,t)=>{if(Qu(t,e))return Lo(t,e);const[r,n]=e,[i,o]=t;return r<=o&&n>=i},Vhe=(e,t)=>{const[r,n]=e,[i,o]=t;return[Math.max(r,i),Math.min(n,o)]},Ow=(e,t)=>{const[r,n]=e,[i,o]=t;if(Lo(e,t)){if(Jc(e,t))return!0;if(i===r)return{start:n,end:o};if(o===n)return{start:i,end:r};if(Jc(t,e))return{start:i,end:o};if(i<r)return{start:i,end:r};if(r<i)return{start:n,end:o}}else return{start:i,end:o};return{start:i,end:o}},Rg=(e,t,r)=>{const[n,i]=e,[o,s]=r,a=o-n,l=s-n;return t.slice(a,l)},Uhe=(e,t,r)=>{for(var n=0;n<e.length;n++){const[i,o]=[e[n],t[n]];if(Jc(i,r))return Rg(i,o,r)}throw new Error("RequestSeg {requestSeg} not in {segments}")},Khe=e=>{for(var t=0,r=0;r<e.length;r++){const[n,i]=e[r];t+=i-n}return t},qhe=e=>{const[t,r]=e;return r-t},Yhe=e=>Math.floor(e[0]+qhe(e)/2),Jhe=(e,t)=>{const r=Yhe(e),[n,i]=t,[o,s]=[r-n,i-r];return o<s?-o:s},Xhe=(e,t)=>{for(var r=0,n=0;n<e.length;n++)if(Lo(e[n],t)){const[i,o]=Vhe(e[n],t);r+=o-i}return r},JR=(e,t)=>[Math.floor(e-t),Math.floor(e+t)],vh=(e,t,r)=>Xhe(r,JR(e,t)),Zhe=(e,t,r)=>{const[n,i]=[[],[]];for(var o=0;o<e.length;o++){const[s,a]=[e[o],t[o]];if(Jc(r,s))n.push(s),i.push(a);else if(Lo(r,s))if(Qu(r,s)){const l=[s[0],r[1]],c=Rg(s,a,l);n.push(l),i.push(c)}else{const l=[r[0],s[1]],c=Rg(s,a,l);n.push(l),i.push(c)}}return[n,i]};class Qhe{constructor(){vt(this,"segments",[]);vt(this,"dfs",[]);vt(this,"sentLength",-1);vt(this,"maxSize",4e3);vt(this,"trimFactor",.8);vt(this,"lastRequest",[0,0])}usedSize(){return Khe(this.segments)}trimCache(){if(this.usedSize()<this.maxSize||this.lastRequest[0]===0&&this.lastRequest[1]===0)return;const t=this.lastRequest,n=(t[1]-t[0])/2+t[0];var i=0,o=Math.floor(this.maxSize*this.trimFactor/2);for(i=vh(n,o,this.segments);i<this.maxSize;)i=vh(n,o,this.segments),o*=2;const s=Math.floor(this.maxSize*this.trimFactor);for(;i>s;)o=Math.floor(.9*o),i=vh(n,o,this.segments);const a=JR(n,o),l=Zhe(this.segments,this.dfs,a);this.segments=l[0],this.dfs=l[1]}getExtents(){if(this.segments.length===0)throw new Error("No Segments");const t=this.segments[this.segments.length-1];return[this.segments[0][0],t[1]]}safeGetExtents(){if(this.segments.length===0)return[];const t=this.segments[this.segments.length-1];return[this.segments[0][0],t[1]]}addRows(t,r){const n=t[1]-t[0];if(r.length!==n){if(t[0]+r.length===this.sentLength){const s=[t[0],this.sentLength];return this.addRows(s,r)}return}const[i,o]=KR(this.segments,this.dfs,t,r);this.segments=i,this.dfs=o,this.trimCache()}hasRows(t){if(t[0]===0&&t[1]===0&&console.log("setting lastRequest to [0,0] in hasRows, this is unexpected"),this.sentLength>-1&&t[1]>this.sentLength){const r=[t[0],this.sentLength];return this.hasRows(r)}this.lastRequest=t;try{console.log("[SmartRowCache.hasRows] need",t,"extents",this.safeGetExtents(),"lastRequest",this.lastRequest)}catch{}for(const r of this.segments)if(Lo(r,t))return Ow(r,t);return Ow([0,0],t)}getRows(t){try{console.log("[SmartRowCache.getRows] range",t,"extents",this.safeGetExtents(),"segments",this.segments)}catch{}if(this.sentLength>0&&t[1]>this.sentLength)return this.getRows([t[0],this.sentLength]);if(this.hasRows(t)===!0)return t[0]===0&&t[1]===0&&console.log("unexpected setting lastRequest to [0,0] in getRows"),this.lastRequest=t,Uhe(this.segments,this.dfs,t);throw console.error("[SmartRowCache.getRows] Missing rows error. range",t,"extents",this.safeGetExtents(),"segments",this.segments,"sentLength",this.sentLength),new Error("Missing rows for {range}")}}function efe(e){debugger;return e.data.length!==0}class tfe{constructor(t){vt(this,"srcAccesses");vt(this,"waitingCallbacks");vt(this,"reqFn");vt(this,"maxSize",1e4);vt(this,"trimFactor",.8);vt(this,"lastRequest",[0,0]);vt(this,"reUpDist",300);vt(this,"padding",200);this.reqFn=t,this.waitingCallbacks={},this.srcAccesses=new Map}usedSize(){return ik(Array.from(this.srcAccesses.values()).map(t=>t.usedSize()))}debugCacheState(){Rt(x2(Array.from(this.srcAccesses.entries())),(t,r)=>{console.log(t,t.safeGetExtents())})}hasRows(t){const r=mh(t),n=[t.start,t.origEnd];if(!this.srcAccesses.has(r))return console.log("500 hasRows, returning False because couldn't find srcKey"),!1;const i=this.srcAccesses.get(r);if(i===void 0)throw new Error(`unexpected couldn't find SmartRowCache for ${r}`);return i.hasRows(n)===!0?!0:(console.log("500 hasRows, returning False because src didn't have rows"),!1)}getRows(t){const r=mh(t),n=[t.start,t.origEnd];if(!this.srcAccesses.has(r))throw new Error(`Missing source for ${t}`);let i=this.srcAccesses.get(r);if(i===void 0)throw new Error(`unexpected couldn't find SmartRowCache for ${r}`);if(this.srcAccesses.delete(r),this.srcAccesses.set(r,i),i.sentLength!==0&&i.sentLength<t.end){const o=Math.min(t.origEnd,i.sentLength),s=[t.start,o];return i.getRows(s)}return i.getRows(n)}maybeMakeLeadingRequest(t){const r=[t.start,t.origEnd],n=this.ensureRowCacheForPa(t),i=n.safeGetExtents();if(i[1]==n.sentLength){console.log("not making extra request because already have to the end of the available data",i,n.sentLength);return}const o=Jhe(r,i);if(console.log("maybeMakeLeadingRequest",o,r,i),o>0&&o<this.reUpDist){const s=new Date-1,a={sourceName:t.sourceName,sort:t.sort,sort_direction:t.sort_direction,start:i[1],end:i[1]+this.padding,origEnd:i[1]+this.padding,request_time:s};n.hasRows([i[1],i[1]+this.padding]),this.reqFn(a)}}getRequestRows(t,r,n){const i=ul(t),o=this.ensureRowCacheForPa(t),s=new Date-1;t.request_time=s;try{console.log("[KeyAware.getRequestRows] pa",t,"cbKey",i,"extents",o.safeGetExtents(),"sentLength",o.sentLength)}catch{}if(this.hasRows(t)){console.log(`request for ${[t.start,t.origEnd,t.end]} in cache, extents ${o.getExtents()}`);const a=[t.start,t.origEnd];r(o.getRows(a),o.sentLength);const l=ul(t);delete this.waitingCallbacks[l],this.maybeMakeLeadingRequest(t);return}this.waitingCallbacks[i]=[r,n],this.reqFn(t)}ensureRowCacheForPa(t){const r=mh(t);console.log("592 ensureRowCacheForPa",r,this.srcAccesses.has(r)),this.srcAccesses.has(r)||this.srcAccesses.set(r,new Qhe);const n=this.srcAccesses.get(r);if(n===void 0)throw new Error(`unexpected couldn't find SmartRowCache for ${r}`);return n}addPayloadResponse(t){const r=[t.key.start,t.key.end];t.key.request_time,this.trim();const n=this.ensureRowCacheForPa(t.key),i=ul(t.key);if(n.sentLength=t.length,t.data.length<r[1]-r[0]){const o=[t.key.start,t.key.start+t.data.length];n.addRows(o,t.data)}else n.addRows(r,t.data);if(Ss(this.waitingCallbacks,i)){const[o,s]=this.waitingCallbacks[i];efe(t)?o(this.getRows(t.key),n.sentLength):s(),delete this.waitingCallbacks[i]}}addErrorResponse(t){const r=ul(t.key);if(Ss(this.waitingCallbacks,r)){const[n,i]=this.waitingCallbacks[r];i(),delete this.waitingCallbacks[r]}}trim(){if(this.usedSize()>this.maxSize){const t=this.srcAccesses.keys().next().value;if(t!==void 0)this.srcAccesses.delete(t);else throw new Error("unexpected couldn't find any keys in srcAccesses ")}}}const Mw=["BOOLEAN","INT32","INT64","INT96","FLOAT","DOUBLE","BYTE_ARRAY","FIXED_LEN_BYTE_ARRAY"],En=["PLAIN","GROUP_VAR_INT","PLAIN_DICTIONARY","RLE","BIT_PACKED","DELTA_BINARY_PACKED","DELTA_LENGTH_BYTE_ARRAY","DELTA_BYTE_ARRAY","RLE_DICTIONARY","BYTE_STREAM_SPLIT"],rfe=["REQUIRED","OPTIONAL","REPEATED"],nfe=["UTF8","MAP","MAP_KEY_VALUE","LIST","ENUM","DECIMAL","DATE","TIME_MILLIS","TIME_MICROS","TIMESTAMP_MILLIS","TIMESTAMP_MICROS","UINT_8","UINT_16","UINT_32","UINT_64","INT_8","INT_16","INT_32","INT_64","JSON","BSON","INTERVAL"],ife=["UNCOMPRESSED","SNAPPY","GZIP","LZO","BROTLI","LZ4","ZSTD","LZ4_RAW"],XR=["DATA_PAGE","INDEX_PAGE","DICTIONARY_PAGE","DATA_PAGE_V2"],ofe=["SPHERICAL","VINCENTY","THOMAS","ANDOYER","KARNEY"];function Eg(e){const t=dl(e);if(t.type===1)return{type:"Point",coordinates:Tg(e,t)};if(t.type===2)return{type:"LineString",coordinates:Fg(e,t)};if(t.type===3)return{type:"Polygon",coordinates:Dw(e,t)};if(t.type===4){const r=[];for(let n=0;n<t.count;n++)r.push(Tg(e,dl(e)));return{type:"MultiPoint",coordinates:r}}else if(t.type===5){const r=[];for(let n=0;n<t.count;n++)r.push(Fg(e,dl(e)));return{type:"MultiLineString",coordinates:r}}else if(t.type===6){const r=[];for(let n=0;n<t.count;n++)r.push(Dw(e,dl(e)));return{type:"MultiPolygon",coordinates:r}}else if(t.type===7){const r=[];for(let n=0;n<t.count;n++)r.push(Eg(e));return{type:"GeometryCollection",geometries:r}}else throw new Error(`Unsupported geometry type: ${t.type}`)}function dl(e){const{view:t}=e,r=t.getUint8(e.offset++)===1,n=t.getUint32(e.offset,r);e.offset+=4;const i=n%1e3,o=Math.floor(n/1e3);let s=0;i>1&&i<=7&&(s=t.getUint32(e.offset,r),e.offset+=4);let a=2;return o&&a++,o===3&&a++,{littleEndian:r,type:i,dim:a,count:s}}function Tg(e,t){const r=[];for(let n=0;n<t.dim;n++){const i=e.view.getFloat64(e.offset,t.littleEndian);e.offset+=8,r.push(i)}return r}function Fg(e,t){const r=[];for(let n=0;n<t.count;n++)r.push(Tg(e,t));return r}function Dw(e,t){const{view:r}=e,n=[];for(let i=0;i<t.count;i++){const o=r.getUint32(e.offset,t.littleEndian);e.offset+=4,n.push(Fg(e,{...t,count:o}))}return n}const ZR=new TextDecoder,QR={timestampFromMilliseconds(e){return new Date(Number(e))},timestampFromMicroseconds(e){return new Date(Number(e/1000n))},timestampFromNanoseconds(e){return new Date(Number(e/1000000n))},dateFromDays(e){return new Date(e*864e5)},stringFromBytes(e){return e&&ZR.decode(e)},geometryFromBytes(e){return e&&Eg({view:new DataView(e.buffer,e.byteOffset,e.byteLength),offset:0})},geographyFromBytes(e){return e&&Eg({view:new DataView(e.buffer,e.byteOffset,e.byteLength),offset:0})}};function kw(e,t,r,n){if(t&&r.endsWith("_DICTIONARY")){let i=e;e instanceof Uint8Array&&!(t instanceof Uint8Array)&&(i=new t.constructor(e.length));for(let o=0;o<e.length;o++)i[o]=t[e[o]];return i}else return eE(e,n)}function eE(e,t){const{element:r,parsers:n,utf8:i=!0}=t,{type:o,converted_type:s,logical_type:a}=r;if(s==="DECIMAL"){const c=10**-(r.scale||0),u=new Array(e.length);for(let d=0;d<u.length;d++)e[d]instanceof Uint8Array?u[d]=tE(e[d])*c:u[d]=Number(e[d])*c;return u}if(!s&&o==="INT96")return Array.from(e).map(l=>n.timestampFromNanoseconds(sfe(l)));if(s==="DATE")return Array.from(e).map(l=>n.dateFromDays(l));if(s==="TIMESTAMP_MILLIS")return Array.from(e).map(l=>n.timestampFromMilliseconds(l));if(s==="TIMESTAMP_MICROS")return Array.from(e).map(l=>n.timestampFromMicroseconds(l));if(s==="JSON")return e.map(l=>JSON.parse(ZR.decode(l)));if(s==="BSON")throw new Error("parquet bson not supported");if(s==="INTERVAL")throw new Error("parquet interval not supported");if((a==null?void 0:a.type)==="GEOMETRY")return e.map(l=>n.geometryFromBytes(l));if((a==null?void 0:a.type)==="GEOGRAPHY")return e.map(l=>n.geographyFromBytes(l));if(s==="UTF8"||(a==null?void 0:a.type)==="STRING"||i&&o==="BYTE_ARRAY")return e.map(l=>n.stringFromBytes(l));if(s==="UINT_64"||(a==null?void 0:a.type)==="INTEGER"&&a.bitWidth===64&&!a.isSigned){if(e instanceof BigInt64Array)return new BigUint64Array(e.buffer,e.byteOffset,e.length);const l=new BigUint64Array(e.length);for(let c=0;c<l.length;c++)l[c]=BigInt(e[c]);return l}if(s==="UINT_32"||(a==null?void 0:a.type)==="INTEGER"&&a.bitWidth===32&&!a.isSigned){if(e instanceof Int32Array)return new Uint32Array(e.buffer,e.byteOffset,e.length);const l=new Uint32Array(e.length);for(let c=0;c<l.length;c++)l[c]=e[c];return l}if((a==null?void 0:a.type)==="FLOAT16")return Array.from(e).map(rE);if((a==null?void 0:a.type)==="TIMESTAMP"){const{unit:l}=a;let c=n.timestampFromMilliseconds;l==="MICROS"&&(c=n.timestampFromMicroseconds),l==="NANOS"&&(c=n.timestampFromNanoseconds);const u=new Array(e.length);for(let d=0;d<u.length;d++)u[d]=c(e[d]);return u}return e}function tE(e){if(!e.length)return 0;let t=0n;for(const n of e)t=t*256n+BigInt(n);const r=e.length*8;return t>=2n**BigInt(r-1)&&(t-=2n**BigInt(r)),Number(t)}function sfe(e){const t=(e>>64n)-2440588n,r=e&0xffffffffffffffffn;return t*86400000000000n+r}function rE(e){if(!e)return;const t=e[1]<<8|e[0],r=t>>15?-1:1,n=t>>10&31,i=t&1023;return n===0?r*2**-14*(i/1024):n===31?i?NaN:r*(1/0):r*2**(n-15)*(1+i/1024)}function nE(e,t,r){const n=e[t],i=[];let o=1;if(n.num_children)for(;i.length<n.num_children;){const s=e[t+o],a=nE(e,t+o,[...r,s.name]);o+=a.count,i.push(a)}return{count:o,element:n,children:i,path:r}}function iE(e,t){let r=nE(e,0,[]);const n=[r];for(const i of t){const o=r.children.find(s=>s.element.name===i);if(!o)throw new Error(`parquet schema element not found: ${t}`);n.push(o),r=o}return n}function afe(e){const t=[];function r(n){if(n.children.length)for(const i of n.children)r(i);else t.push(n.path.join("."))}return r(e),t}function oE(e){let t=0;for(const{element:r}of e)r.repetition_type==="REPEATED"&&t++;return t}function _m(e){let t=0;for(const{element:r}of e.slice(1))r.repetition_type!=="REQUIRED"&&t++;return t}function lfe(e){if(!e||e.element.converted_type!=="LIST"||e.children.length>1)return!1;const t=e.children[0];return!(t.children.length>1||t.element.repetition_type!=="REPEATED")}function cfe(e){if(!e||e.element.converted_type!=="MAP"||e.children.length>1)return!1;const t=e.children[0];if(t.children.length!==2||t.element.repetition_type!=="REPEATED")return!1;const r=t.children.find(i=>i.element.name==="key");if((r==null?void 0:r.element.repetition_type)==="REPEATED")return!1;const n=t.children.find(i=>i.element.name==="value");return(n==null?void 0:n.element.repetition_type)!=="REPEATED"}function sE(e){if(e.length!==2)return!1;const[,t]=e;return!(t.element.repetition_type==="REPEATED"||t.children.length)}const ut={STOP:0,TRUE:1,FALSE:2,BYTE:3,I16:4,I32:5,I64:6,DOUBLE:7,BINARY:8,LIST:9,STRUCT:12};function Lm(e){let t=0;const r={};for(;e.offset<e.view.byteLength;){const[n,i,o]=lE(e,t);if(t=o,n===ut.STOP)break;r[`field_${i}`]=Sl(e,n)}return r}function Sl(e,t){switch(t){case ut.TRUE:return!0;case ut.FALSE:return!1;case ut.BYTE:return e.view.getInt8(e.offset++);case ut.I16:case ut.I32:return aE(e);case ut.I64:return Og(e);case ut.DOUBLE:{const r=e.view.getFloat64(e.offset,!0);return e.offset+=8,r}case ut.BINARY:{const r=Hn(e),n=new Uint8Array(e.view.buffer,e.view.byteOffset+e.offset,r);return e.offset+=r,n}case ut.LIST:{const r=e.view.getUint8(e.offset++),n=r&15;let i=r>>4;i===15&&(i=Hn(e));const o=n===ut.TRUE||n===ut.FALSE,s=new Array(i);for(let a=0;a<i;a++)s[a]=o?Sl(e,ut.BYTE)===1:Sl(e,n);return s}case ut.STRUCT:{const r={};let n=0;for(;;){const[i,o,s]=lE(e,n);if(n=s,i===ut.STOP)break;r[`field_${o}`]=Sl(e,i)}return r}default:throw new Error(`thrift unhandled type: ${t}`)}}function Hn(e){let t=0,r=0;for(;;){const n=e.view.getUint8(e.offset++);if(t|=(n&127)<<r,!(n&128))return t;r+=7}}function ufe(e){let t=0n,r=0n;for(;;){const n=e.view.getUint8(e.offset++);if(t|=BigInt(n&127)<<r,!(n&128))return t;r+=7n}}function aE(e){const t=Hn(e);return t>>>1^-(t&1)}function Og(e){const t=ufe(e);return t>>1n^-(t&1n)}function lE(e,t){const r=e.view.getUint8(e.offset++),n=r&15;if(n===ut.STOP)return[0,0,t];const i=r>>4,o=i?t+i:aE(e);return[n,o,o]}function dfe(e,t){var o,s,a,l,c;const r=new Map,n=(o=t==null?void 0:t.find(({key:u})=>u==="geo"))==null?void 0:o.value,i=(n&&((s=JSON.parse(n))==null?void 0:s.columns))??{};for(const[u,d]of Object.entries(i)){if(d.encoding!=="WKB")continue;const h=d.edges==="spherical"?"GEOGRAPHY":"GEOMETRY",f=((a=d.crs)==null?void 0:a.id)??((c=(l=d.crs)==null?void 0:l.ids)==null?void 0:c[0]),g=f?`${f.authority}:${f.code.toString()}`:void 0;r.set(u,{type:h,crs:g})}for(let u=1;u<e.length;u++){const d=e[u],{logical_type:h,name:f,num_children:g,repetition_type:m,type:p}=d;if(g){u+=g;continue}p==="BYTE_ARRAY"&&h===void 0&&m!=="REPEATED"&&(d.logical_type=r.get(f))}}const hfe=1<<19,ffe=new TextDecoder;function hr(e){return e&&ffe.decode(e)}async function gfe(e,{parsers:t,initialFetchSize:r=hfe,geoparquet:n=!0}={}){if(!e||!(e.byteLength>=0))throw new Error("parquet expected AsyncBuffer");const i=Math.max(0,e.byteLength-r),o=await e.slice(i,e.byteLength),s=new DataView(o);if(s.getUint32(o.byteLength-4,!0)!==827474256)throw new Error("parquet file invalid (footer != PAR1)");const a=s.getUint32(o.byteLength-8,!0);if(a>e.byteLength-8)throw new Error(`parquet metadata length ${a} exceeds available buffer ${e.byteLength-8}`);if(a+8>r){const l=e.byteLength-a-8,c=await e.slice(l,i),u=new ArrayBuffer(a+8),d=new Uint8Array(u);return d.set(new Uint8Array(c)),d.set(new Uint8Array(o),i-l),ei(u,{parsers:t,geoparquet:n})}else return ei(o,{parsers:t,geoparquet:n})}function ei(e,{parsers:t,geoparquet:r=!0}={}){var p;if(!(e instanceof ArrayBuffer))throw new Error("parquet expected ArrayBuffer");const n=new DataView(e);if(t={...QR,...t},n.byteLength<8)throw new Error("parquet file is too short");if(n.getUint32(n.byteLength-4,!0)!==827474256)throw new Error("parquet file invalid (footer != PAR1)");const i=n.byteLength-8,o=n.getUint32(i,!0);if(o>n.byteLength-8)throw new Error(`parquet metadata length ${o} exceeds available buffer ${n.byteLength-8}`);const s=i-o,l=Lm({view:n,offset:s}),c=l.field_1,u=l.field_2.map(y=>({type:Mw[y.field_1],type_length:y.field_2,repetition_type:rfe[y.field_3],name:hr(y.field_4),num_children:y.field_5,converted_type:nfe[y.field_6],scale:y.field_7,precision:y.field_8,field_id:y.field_9,logical_type:pfe(y.field_10)})),d=u.filter(y=>y.type),h=l.field_3,f=l.field_4.map(y=>{var w;return{columns:y.field_1.map((b,x)=>{var C,S,A;return{file_path:hr(b.field_1),file_offset:b.field_2,meta_data:b.field_3&&{type:Mw[b.field_3.field_1],encodings:(C=b.field_3.field_2)==null?void 0:C.map(P=>En[P]),path_in_schema:b.field_3.field_3.map(hr),codec:ife[b.field_3.field_4],num_values:b.field_3.field_5,total_uncompressed_size:b.field_3.field_6,total_compressed_size:b.field_3.field_7,key_value_metadata:(S=b.field_3.field_8)==null?void 0:S.map(P=>({key:hr(P.field_1),value:hr(P.field_2)})),data_page_offset:b.field_3.field_9,index_page_offset:b.field_3.field_10,dictionary_page_offset:b.field_3.field_11,statistics:mfe(b.field_3.field_12,d[x],t),encoding_stats:(A=b.field_3.field_13)==null?void 0:A.map(P=>({page_type:XR[P.field_1],encoding:En[P.field_2],count:P.field_3})),bloom_filter_offset:b.field_3.field_14,bloom_filter_length:b.field_3.field_15,size_statistics:b.field_3.field_16&&{unencoded_byte_array_data_bytes:b.field_3.field_16.field_1,repetition_level_histogram:b.field_3.field_16.field_2,definition_level_histogram:b.field_3.field_16.field_3},geospatial_statistics:b.field_3.field_17&&{bbox:b.field_3.field_17.field_1&&{xmin:b.field_3.field_17.field_1.field_1,xmax:b.field_3.field_17.field_1.field_2,ymin:b.field_3.field_17.field_1.field_3,ymax:b.field_3.field_17.field_1.field_4,zmin:b.field_3.field_17.field_1.field_5,zmax:b.field_3.field_17.field_1.field_6,mmin:b.field_3.field_17.field_1.field_7,mmax:b.field_3.field_17.field_1.field_8},geospatial_types:b.field_3.field_17.field_2}},offset_index_offset:b.field_4,offset_index_length:b.field_5,column_index_offset:b.field_6,column_index_length:b.field_7,crypto_metadata:b.field_8,encrypted_column_metadata:b.field_9}}),total_byte_size:y.field_2,num_rows:y.field_3,sorting_columns:(w=y.field_4)==null?void 0:w.map(b=>({column_idx:b.field_1,descending:b.field_2,nulls_first:b.field_3})),file_offset:y.field_5,total_compressed_size:y.field_6,ordinal:y.field_7}}),g=(p=l.field_5)==null?void 0:p.map(y=>({key:hr(y.field_1),value:hr(y.field_2)})),m=hr(l.field_6);return r&&dfe(u,g),{version:c,schema:u,num_rows:h,row_groups:f,key_value_metadata:g,created_by:m,metadata_length:o}}function Mg({schema:e}){return iE(e,[])[0]}function pfe(e){return e!=null&&e.field_1?{type:"STRING"}:e!=null&&e.field_2?{type:"MAP"}:e!=null&&e.field_3?{type:"LIST"}:e!=null&&e.field_4?{type:"ENUM"}:e!=null&&e.field_5?{type:"DECIMAL",scale:e.field_5.field_1,precision:e.field_5.field_2}:e!=null&&e.field_6?{type:"DATE"}:e!=null&&e.field_7?{type:"TIME",isAdjustedToUTC:e.field_7.field_1,unit:Iw(e.field_7.field_2)}:e!=null&&e.field_8?{type:"TIMESTAMP",isAdjustedToUTC:e.field_8.field_1,unit:Iw(e.field_8.field_2)}:e!=null&&e.field_10?{type:"INTEGER",bitWidth:e.field_10.field_1,isSigned:e.field_10.field_2}:e!=null&&e.field_11?{type:"NULL"}:e!=null&&e.field_12?{type:"JSON"}:e!=null&&e.field_13?{type:"BSON"}:e!=null&&e.field_14?{type:"UUID"}:e!=null&&e.field_15?{type:"FLOAT16"}:e!=null&&e.field_16?{type:"VARIANT",specification_version:e.field_16.field_1}:e!=null&&e.field_17?{type:"GEOMETRY",crs:hr(e.field_17.field_1)}:e!=null&&e.field_18?{type:"GEOGRAPHY",crs:hr(e.field_18.field_1),algorithm:ofe[e.field_18.field_2]}:e}function Iw(e){if(e.field_1)return"MILLIS";if(e.field_2)return"MICROS";if(e.field_3)return"NANOS";throw new Error("parquet time unit required")}function mfe(e,t,r){return e&&{max:hl(e.field_1,t,r),min:hl(e.field_2,t,r),null_count:e.field_3,distinct_count:e.field_4,max_value:hl(e.field_5,t,r),min_value:hl(e.field_6,t,r),is_max_value_exact:e.field_7,is_min_value_exact:e.field_8}}function hl(e,t,r){const{type:n,converted_type:i,logical_type:o}=t;if(e===void 0)return e;if(n==="BOOLEAN")return e[0]===1;if(n==="BYTE_ARRAY")return r.stringFromBytes(e);const s=new DataView(e.buffer,e.byteOffset,e.byteLength);return n==="FLOAT"&&s.byteLength===4?s.getFloat32(0,!0):n==="DOUBLE"&&s.byteLength===8?s.getFloat64(0,!0):n==="INT32"&&i==="DATE"?r.dateFromDays(s.getInt32(0,!0)):n==="INT64"&&i==="TIMESTAMP_MILLIS"?r.timestampFromMilliseconds(s.getBigInt64(0,!0)):n==="INT64"&&i==="TIMESTAMP_MICROS"?r.timestampFromMicroseconds(s.getBigInt64(0,!0)):n==="INT64"&&(o==null?void 0:o.type)==="TIMESTAMP"&&(o==null?void 0:o.unit)==="NANOS"?r.timestampFromNanoseconds(s.getBigInt64(0,!0)):n==="INT64"&&(o==null?void 0:o.type)==="TIMESTAMP"&&(o==null?void 0:o.unit)==="MICROS"?r.timestampFromMicroseconds(s.getBigInt64(0,!0)):n==="INT64"&&(o==null?void 0:o.type)==="TIMESTAMP"?r.timestampFromMilliseconds(s.getBigInt64(0,!0)):n==="INT32"&&s.byteLength===4?s.getInt32(0,!0):n==="INT64"&&s.byteLength===8?s.getBigInt64(0,!0):i==="DECIMAL"?tE(e)*10**-(t.scale||0):(o==null?void 0:o.type)==="FLOAT16"?rE(e):e}function vfe(e){const t=Lm(e);return{page_locations:t.field_1.map(yfe),unencoded_byte_array_data_bytes:t.field_2}}function yfe(e){return{offset:e.field_1,compressed_page_size:e.field_2,first_row_index:e.field_3}}function cE(e,t){for(let n=0;n<t.length;n+=1e4)e.push(...t.slice(n,n+1e4))}function Nr(e,t,r=!0){if(r?e===t:e==t)return!0;if(e instanceof Uint8Array&&t instanceof Uint8Array)return Nr(Array.from(e),Array.from(t),r);if(!e||!t||typeof e!=typeof t)return!1;if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return!1;for(let i=0;i<e.length;i++)if(!Nr(e[i],t[i],r))return!1;return!0}if(typeof e!="object")return!1;const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(const i of n)if(!Nr(e[i],t[i],r))return!1;return!0}function uE(e){if(!e)return[];if(e.length===1)return e[0];const t=[];for(const r of e)cE(t,r);return t}function xl(e){if(!e)return[];const t=[];return"$and"in e&&Array.isArray(e.$and)?t.push(...e.$and.flatMap(xl)):"$or"in e&&Array.isArray(e.$or)?t.push(...e.$or.flatMap(xl)):"$nor"in e&&Array.isArray(e.$nor)?t.push(...e.$nor.flatMap(xl)):t.push(...Object.keys(e)),t}function ts(e,t,r=!0){return"$and"in t&&Array.isArray(t.$and)?t.$and.every(n=>ts(e,n,r)):"$or"in t&&Array.isArray(t.$or)?t.$or.some(n=>ts(e,n,r)):"$nor"in t&&Array.isArray(t.$nor)?!t.$nor.some(n=>ts(e,n,r)):Object.entries(t).every(([n,i])=>{const o=e[n];return typeof i!="object"||i===null||Array.isArray(i)?Nr(o,i,r):Object.entries(i||{}).every(([s,a])=>s==="$gt"?o>a:s==="$gte"?o>=a:s==="$lt"?o<a:s==="$lte"?o<=a:s==="$eq"?Nr(o,a,r):s==="$ne"?!Nr(o,a,r):s==="$in"?Array.isArray(a)&&a.includes(o):s==="$nin"?Array.isArray(a)&&!a.includes(o):s==="$not"?!ts({[n]:o},{[n]:a},r):!0)})}function Dg({rowGroup:e,physicalColumns:t,filter:r,strict:n=!0}){var i;if(!r)return!1;if("$and"in r&&Array.isArray(r.$and))return r.$and.some(o=>Dg({rowGroup:e,physicalColumns:t,filter:o,strict:n}));if("$or"in r&&Array.isArray(r.$or))return r.$or.every(o=>Dg({rowGroup:e,physicalColumns:t,filter:o,strict:n}));if("$nor"in r&&Array.isArray(r.$nor))return!1;for(const[o,s]of Object.entries(r)){const a=t.indexOf(o);if(a===-1)continue;const l=(i=e.columns[a].meta_data)==null?void 0:i.statistics;if(!l)continue;const{min:c,max:u,min_value:d,max_value:h}=l,f=d!==void 0?d:c,g=h!==void 0?h:u;if(!(f===void 0||g===void 0)){for(const[m,p]of Object.entries(s||{}))if(m==="$gt"&&g<=p||m==="$gte"&&g<p||m==="$lt"&&f>=p||m==="$lte"&&f>p||m==="$eq"&&(p<f||p>g)||m==="$ne"&&Nr(f,g,n)&&Nr(f,p,n)||m==="$in"&&Array.isArray(p)&&p.every(y=>y<f||y>g)||m==="$nin"&&Array.isArray(p)&&Nr(f,g,n)&&p.includes(f))return!0}}return!1}const bfe=1<<21;function Cfe({metadata:e,rowStart:t=0,rowEnd:r=1/0,columns:n,filter:i,filterStrict:o=!0,useOffsetIndex:s=!1}){if(!e)throw new Error("parquetPlan requires metadata");const a=[],l=[],c=[],u=afe(Mg(e));let d=0;for(const h of e.row_groups){const f=Number(h.num_rows),g=d+f;if(f>0&&g>t&&d<r&&!Dg({rowGroup:h,physicalColumns:u,filter:i,strict:o})){const m=[];for(const b of h.columns){const x=b.meta_data;if(b.file_path)throw new Error("parquet file_path not supported");if(!x)throw new Error("parquet column metadata is undefined");if(!n||n.includes(x.path_in_schema[0])){const C=x.dictionary_page_offset||x.data_page_offset,S=Number(C),A=Number(C+x.total_compressed_size);if(s&&b.offset_index_offset&&b.offset_index_length){const P=Number(b.offset_index_offset);m.push({columnMetadata:x,offsetIndex:{startByte:P,endByte:P+b.offset_index_length},bounds:{startByte:S,endByte:A}})}else m.push({columnMetadata:x,range:{startByte:S,endByte:A}})}}const p=Math.max(t-d,0),y=Math.min(r-d,f);a.push({chunks:m,rowGroup:h,groupStart:d,groupRows:f,selectStart:p,selectEnd:y});let w;for(const b of m)if("offsetIndex"in b)c.push(b.offsetIndex);else{const{range:x}=b;n?l.push(x):w&&x.endByte-w.startByte<=bfe?w.endByte=x.endByte:(w&&l.push(w),w={...x})}w&&l.push(w)}d=g}return isFinite(r)||(r=d),l.push(...c),{metadata:e,rowStart:t,rowEnd:r,columns:n,fetches:l,groups:a}}function wfe(e,{fetches:t}){const r=t.map(({startByte:n,endByte:i})=>e.slice(n,i));return{byteLength:e.byteLength,slice(n,i=e.byteLength){const o=t.findIndex(({startByte:s,endByte:a})=>s<=n&&i<=a);if(o<0)return e.slice(n,i);if(t[o].startByte!==n||t[o].endByte!==i){const s=n-t[o].startByte,a=i-t[o].startByte;return r[o]instanceof Promise?r[o].then(l=>l.slice(s,a)):r[o].slice(s,a)}else return r[o]}}}function _w(e,t,r,n,i){const o=(t==null?void 0:t.length)||r.length;if(!o)return n;const s=_m(i),a=i.map(({element:g})=>g.repetition_type);let l=0;const c=[e];let u=e,d=0,h=0,f=0;if(r[0])for(;d<a.length-2&&f<r[0];)d++,a[d]!=="REQUIRED"&&(u=u.at(-1),c.push(u),h++),a[d]==="REPEATED"&&f++;for(let g=0;g<o;g++){const m=t!=null&&t.length?t[g]:s,p=r[g];for(;d&&(p<f||a[d]!=="REPEATED");)a[d]!=="REQUIRED"&&(c.pop(),h--),a[d]==="REPEATED"&&f--,d--;for(u=c.at(-1);(d<a.length-2||a[d+1]==="REPEATED")&&(h<m||a[d+1]==="REQUIRED");){if(d++,a[d]!=="REQUIRED"){const y=[];u.push(y),u=y,c.push(y),h++}a[d]==="REPEATED"&&f++}m===s?u.push(n[l++]):d===a.length-2?u.push(null):u.push([])}if(!e.length)for(let g=0;g<s;g++){const m=[];u.push(m),u=m}return e}function rs(e,t,r=0){const n=t.path.join("."),i=t.element.repetition_type==="OPTIONAL",o=i?r+1:r;if(lfe(t)){let s=t.children[0],a=o;s.children.length===1&&(s=s.children[0],a++),rs(e,s,a);const l=s.path.join("."),c=e.get(l);if(!c)throw new Error("parquet list column missing values");i&&Al(c,r),e.set(n,c),e.delete(l);return}if(cfe(t)){const s=t.children[0].element.name;rs(e,t.children[0].children[0],o+1),rs(e,t.children[0].children[1],o+1);const a=e.get(`${n}.${s}.key`),l=e.get(`${n}.${s}.value`);if(!a)throw new Error("parquet map column missing keys");if(!l)throw new Error("parquet map column missing values");if(a.length!==l.length)throw new Error("parquet map column key/value length mismatch");const c=dE(a,l,o);i&&Al(c,r),e.delete(`${n}.${s}.key`),e.delete(`${n}.${s}.value`),e.set(n,c);return}if(t.children.length){const s=t.element.repetition_type==="REQUIRED"?r:r+1,a={};for(const c of t.children){rs(e,c,s);const u=e.get(c.path.join("."));if(!u)throw new Error("parquet struct missing child data");a[c.element.name]=u}for(const c of t.children)e.delete(c.path.join("."));const l=hE(a,s);i&&Al(l,r),e.set(n,l)}}function Al(e,t){for(let r=0;r<e.length;r++)t?Al(e[r],t-1):e[r]=e[r][0]}function dE(e,t,r){const n=[];for(let i=0;i<e.length;i++)if(r)n.push(dE(e[i],t[i],r-1));else if(e[i]){const o={};for(let s=0;s<e[i].length;s++){const a=t[i][s];o[e[i][s]]=a===void 0?null:a}n.push(o)}else n.push(void 0);return n}function hE(e,t){var o;const r=Object.keys(e),n=(o=e[r[0]])==null?void 0:o.length,i=[];for(let s=0;s<n;s++){const a={};for(const l of r){if(e[l].length!==n)throw new Error("parquet struct parsing error");a[l]=e[l][s]}t?i.push(hE(a,t-1)):i.push(a)}return i}function ga(e,t,r){const n=r instanceof Int32Array,i=Hn(e),o=Hn(e);Hn(e);let s=Og(e),a=0;r[a++]=n?Number(s):s;const l=i/o;for(;a<t;){const c=Og(e),u=new Uint8Array(o);for(let d=0;d<o;d++)u[d]=e.view.getUint8(e.offset++);for(let d=0;d<o&&a<t;d++){const h=BigInt(u[d]);if(h){let f=0n,g=l;const m=(1n<<h)-1n;for(;g&&a<t;){let p=BigInt(e.view.getUint8(e.offset))>>f&m;for(f+=h;f>=8;)f-=8n,e.offset++,f&&(p|=BigInt(e.view.getUint8(e.offset))<<h-f&m);const y=c+p;s+=y,r[a++]=n?Number(s):s,g--}g&&(e.offset+=Math.ceil((g*Number(h)+Number(f))/8))}else for(let f=0;f<l&&a<t;f++)s+=c,r[a++]=n?Number(s):s}}}function fE(e,t,r){const n=new Int32Array(t);ga(e,t,n);for(let i=0;i<t;i++)r[i]=new Uint8Array(e.view.buffer,e.view.byteOffset+e.offset,n[i]),e.offset+=n[i]}function Sfe(e,t,r){const n=new Int32Array(t);ga(e,t,n);const i=new Int32Array(t);ga(e,t,i);for(let o=0;o<t;o++){const s=new Uint8Array(e.view.buffer,e.view.byteOffset+e.offset,i[o]);n[o]?(r[o]=new Uint8Array(n[o]+i[o]),r[o].set(r[o-1].subarray(0,n[o])),r[o].set(s,n[o])):r[o]=s,e.offset+=i[o]}}function ed(e){return 32-Math.clz32(e)}function cn(e,t,r,n){n===void 0&&(n=e.view.getUint32(e.offset,!0),e.offset+=4);const i=e.offset;let o=0;for(;o<r.length;){const s=Hn(e);if(s&1)o=Afe(e,s,t,r,o);else{const a=s>>>1;xfe(e,a,t,r,o),o+=a}}e.offset=i+n}function xfe(e,t,r,n,i){const o=r+7>>3;let s=0;for(let a=0;a<o;a++)s|=e.view.getUint8(e.offset++)<<(a<<3);for(let a=0;a<t;a++)n[i+a]=s}function Afe(e,t,r,n,i){let o=t>>1<<3;const s=(1<<r)-1;let a=0;if(e.offset<e.view.byteLength)a=e.view.getUint8(e.offset++);else if(s)throw new Error(`parquet bitpack offset ${e.offset} out of range`);let l=8,c=0;for(;o;)c>8?(c-=8,l-=8,a>>>=8):l-c<r?(a|=e.view.getUint8(e.offset)<<l,e.offset++,l+=8):(i<n.length&&(n[i++]=a>>c&s),o--,c+=r);return i}function gE(e,t,r,n){const i=Pfe(r,n),o=new Uint8Array(t*i);for(let s=0;s<i;s++)for(let a=0;a<t;a++)o[a*i+s]=e.view.getUint8(e.offset++);if(r==="FLOAT")return new Float32Array(o.buffer);if(r==="DOUBLE")return new Float64Array(o.buffer);if(r==="INT32")return new Int32Array(o.buffer);if(r==="INT64")return new BigInt64Array(o.buffer);if(r==="FIXED_LEN_BYTE_ARRAY"){const s=new Array(t);for(let a=0;a<t;a++)s[a]=o.subarray(a*i,(a+1)*i);return s}throw new Error(`parquet byte_stream_split unsupported type: ${r}`)}function Pfe(e,t){switch(e){case"INT32":case"FLOAT":return 4;case"INT64":case"DOUBLE":return 8;case"FIXED_LEN_BYTE_ARRAY":if(!t)throw new Error("parquet byteWidth missing type_length");return t;default:throw new Error(`parquet unsupported type: ${e}`)}}function Bm(e,t,r,n){if(r===0)return[];if(t==="BOOLEAN")return Rfe(e,r);if(t==="INT32")return Efe(e,r);if(t==="INT64")return Tfe(e,r);if(t==="INT96")return Ffe(e,r);if(t==="FLOAT")return Ofe(e,r);if(t==="DOUBLE")return Mfe(e,r);if(t==="BYTE_ARRAY")return Dfe(e,r);if(t==="FIXED_LEN_BYTE_ARRAY"){if(!n)throw new Error("parquet missing fixed length");return kfe(e,r,n)}else throw new Error(`parquet unhandled type: ${t}`)}function Rfe(e,t){const r=new Array(t);for(let n=0;n<t;n++){const i=e.offset+(n/8|0),o=n%8,s=e.view.getUint8(i);r[n]=(s&1<<o)!==0}return e.offset+=Math.ceil(t/8),r}function Efe(e,t){const r=(e.view.byteOffset+e.offset)%4?new Int32Array(td(e.view.buffer,e.view.byteOffset+e.offset,t*4)):new Int32Array(e.view.buffer,e.view.byteOffset+e.offset,t);return e.offset+=t*4,r}function Tfe(e,t){const r=(e.view.byteOffset+e.offset)%8?new BigInt64Array(td(e.view.buffer,e.view.byteOffset+e.offset,t*8)):new BigInt64Array(e.view.buffer,e.view.byteOffset+e.offset,t);return e.offset+=t*8,r}function Ffe(e,t){const r=new Array(t);for(let n=0;n<t;n++){const i=e.view.getBigInt64(e.offset+n*12,!0),o=e.view.getInt32(e.offset+n*12+8,!0);r[n]=BigInt(o)<<64n|i}return e.offset+=t*12,r}function Ofe(e,t){const r=(e.view.byteOffset+e.offset)%4?new Float32Array(td(e.view.buffer,e.view.byteOffset+e.offset,t*4)):new Float32Array(e.view.buffer,e.view.byteOffset+e.offset,t);return e.offset+=t*4,r}function Mfe(e,t){const r=(e.view.byteOffset+e.offset)%8?new Float64Array(td(e.view.buffer,e.view.byteOffset+e.offset,t*8)):new Float64Array(e.view.buffer,e.view.byteOffset+e.offset,t);return e.offset+=t*8,r}function Dfe(e,t){const r=new Array(t);for(let n=0;n<t;n++){const i=e.view.getUint32(e.offset,!0);e.offset+=4,r[n]=new Uint8Array(e.view.buffer,e.view.byteOffset+e.offset,i),e.offset+=i}return r}function kfe(e,t,r){const n=new Array(t);for(let i=0;i<t;i++)n[i]=new Uint8Array(e.view.buffer,e.view.byteOffset+e.offset,r),e.offset+=r;return n}function td(e,t,r){const n=new ArrayBuffer(r);return new Uint8Array(n).set(new Uint8Array(e,t,r)),n}const Ife=[0,255,65535,16777215,4294967295];function Lw(e,t,r,n,i){for(let o=0;o<i;o++)r[n+o]=e[t+o]}function _fe(e,t){const r=e.byteLength,n=t.byteLength;let i=0,o=0;for(;i<r;){const s=e[i];if(i++,s<128)break}if(n&&i>=r)throw new Error("invalid snappy length header");for(;i<r;){const s=e[i];let a=0;if(i++,i>=r)throw new Error("missing eof marker");if(s&3){let l=0;switch(s&3){case 1:a=(s>>>2&7)+4,l=e[i]+(s>>>5<<8),i++;break;case 2:if(r<=i+1)throw new Error("snappy error end of input");a=(s>>>2)+1,l=e[i]+(e[i+1]<<8),i+=2;break;case 3:if(r<=i+3)throw new Error("snappy error end of input");a=(s>>>2)+1,l=e[i]+(e[i+1]<<8)+(e[i+2]<<16)+(e[i+3]<<24),i+=4;break}if(l===0||isNaN(l))throw new Error(`invalid offset ${l} pos ${i} inputLength ${r}`);if(l>o)throw new Error("cannot copy from before start of buffer");Lw(t,o-l,t,o,a),o+=a}else{let l=(s>>>2)+1;if(l>60){if(i+3>=r)throw new Error("snappy error literal pos + 3 >= inputLength");const c=l-60;l=e[i]+(e[i+1]<<8)+(e[i+2]<<16)+(e[i+3]<<24),l=(l&Ife[c])+1,i+=c}if(i+l>r)throw new Error("snappy error literal exceeds input length");Lw(e,i,t,o,l),i+=l,o+=l}}if(o!==n)throw new Error("premature end of input")}function Lfe(e,t,{type:r,element:n,schemaPath:i}){const o=new DataView(e.buffer,e.byteOffset,e.byteLength),s={view:o,offset:0};let a;const l=Bfe(s,t,i),{definitionLevels:c,numNulls:u}=zfe(s,t,i),d=t.num_values-u;if(t.encoding==="PLAIN")a=Bm(s,r,d,n.type_length);else if(t.encoding==="PLAIN_DICTIONARY"||t.encoding==="RLE_DICTIONARY"||t.encoding==="RLE"){const h=r==="BOOLEAN"?1:o.getUint8(s.offset++);h?(a=new Array(d),r==="BOOLEAN"?(cn(s,h,a),a=a.map(f=>!!f)):cn(s,h,a,o.byteLength-s.offset)):a=new Uint8Array(d)}else if(t.encoding==="BYTE_STREAM_SPLIT")a=gE(s,d,r,n.type_length);else if(t.encoding==="DELTA_BINARY_PACKED")a=r==="INT32"?new Int32Array(d):new BigInt64Array(d),ga(s,d,a);else if(t.encoding==="DELTA_LENGTH_BYTE_ARRAY")a=new Array(d),fE(s,d,a);else throw new Error(`parquet unsupported encoding: ${t.encoding}`);return{definitionLevels:c,repetitionLevels:l,dataPage:a}}function Bfe(e,t,r){if(r.length>1){const n=oE(r);if(n){const i=new Array(t.num_values);return cn(e,ed(n),i),i}}return[]}function zfe(e,t,r){const n=_m(r);if(!n)return{definitionLevels:[],numNulls:0};const i=new Array(t.num_values);cn(e,ed(n),i);let o=t.num_values;for(const s of i)s===n&&o--;return o===0&&(i.length=0),{definitionLevels:i,numNulls:o}}function kg(e,t,r,n){let i;const o=n==null?void 0:n[r];if(r==="UNCOMPRESSED")i=e;else if(o)i=o(e,t);else if(r==="SNAPPY")i=new Uint8Array(t),_fe(e,i);else throw new Error(`parquet unsupported compression codec: ${r}`);if((i==null?void 0:i.length)!==t)throw new Error(`parquet decompressed page length ${i==null?void 0:i.length} does not match header ${t}`);return i}function Nfe(e,t,r){const i={view:new DataView(e.buffer,e.byteOffset,e.byteLength),offset:0},{type:o,element:s,schemaPath:a,codec:l,compressors:c}=r,u=t.data_page_header_v2;if(!u)throw new Error("parquet data page header v2 is undefined");const d=$fe(i,u,a);i.offset=u.repetition_levels_byte_length;const h=Hfe(i,u,a),f=t.uncompressed_page_size-u.definition_levels_byte_length-u.repetition_levels_byte_length;let g=e.subarray(i.offset);u.is_compressed!==!1&&(g=kg(g,f,l,c));const m=new DataView(g.buffer,g.byteOffset,g.byteLength),p={view:m,offset:0};let y;const w=u.num_values-u.num_nulls;if(u.encoding==="PLAIN")y=Bm(p,o,w,s.type_length);else if(u.encoding==="RLE")y=new Array(w),cn(p,1,y),y=y.map(b=>!!b);else if(u.encoding==="PLAIN_DICTIONARY"||u.encoding==="RLE_DICTIONARY"){const b=m.getUint8(p.offset++);y=new Array(w),cn(p,b,y,f-1)}else if(u.encoding==="DELTA_BINARY_PACKED")y=o==="INT32"?new Int32Array(w):new BigInt64Array(w),ga(p,w,y);else if(u.encoding==="DELTA_LENGTH_BYTE_ARRAY")y=new Array(w),fE(p,w,y);else if(u.encoding==="DELTA_BYTE_ARRAY")y=new Array(w),Sfe(p,w,y);else if(u.encoding==="BYTE_STREAM_SPLIT")y=gE(p,w,o,s.type_length);else throw new Error(`parquet unsupported encoding: ${u.encoding}`);return{definitionLevels:h,repetitionLevels:d,dataPage:y}}function $fe(e,t,r){const n=oE(r);if(!n)return[];const i=new Array(t.num_values);return cn(e,ed(n),i,t.repetition_levels_byte_length),i}function Hfe(e,t,r){const n=_m(r);if(n){const i=new Array(t.num_values);return cn(e,ed(n),i,t.definition_levels_byte_length),i}}function Bw(e,{groupStart:t,selectStart:r,selectEnd:n},i,o){const{pathInSchema:s,schemaPath:a}=i,l=sE(a),c=[];let u,d,h=0;const f=o&&(()=>{d&&o({pathInSchema:s,columnData:d,rowStart:t+h-d.length,rowEnd:t+h})});for(;(l?h<n:e.offset<e.view.byteLength-1)&&!(e.offset>=e.view.byteLength-1);){const g=Gfe(e);if(g.type==="DICTIONARY_PAGE")u=zw(e,g,i,u,void 0,0),u=eE(u,i);else{const m=(d==null?void 0:d.length)||0,p=zw(e,g,i,u,d,r-h);d===p?h+=p.length-m:(f==null||f(),c.push(p),h+=p.length,d=p)}}return f==null||f(),c}function zw(e,t,r,n,i,o){const{type:s,element:a,schemaPath:l,codec:c,compressors:u}=r,d=new Uint8Array(e.view.buffer,e.view.byteOffset+e.offset,t.compressed_page_size);if(e.offset+=t.compressed_page_size,t.type==="DATA_PAGE"){const h=t.data_page_header;if(!h)throw new Error("parquet data page header is undefined");if(o>h.num_values&&sE(l))return new Array(h.num_values);const f=kg(d,Number(t.uncompressed_page_size),c,u),{definitionLevels:g,repetitionLevels:m,dataPage:p}=Lfe(f,h,r);let y=kw(p,n,h.encoding,r);if(m.length||g!=null&&g.length){const w=Array.isArray(i)?i:[];return _w(w,g,m,y,l)}else{for(let w=2;w<l.length;w++)l[w].element.repetition_type!=="REQUIRED"&&(y=Array.from(y,b=>[b]));return y}}else if(t.type==="DATA_PAGE_V2"){const h=t.data_page_header_v2;if(!h)throw new Error("parquet data page header v2 is undefined");if(o>h.num_rows)return new Array(h.num_values);const{definitionLevels:f,repetitionLevels:g,dataPage:m}=Nfe(d,t,r),p=kw(m,n,h.encoding,r),y=Array.isArray(i)?i:[];return _w(y,f,g,p,l)}else if(t.type==="DICTIONARY_PAGE"){const h=t.dictionary_page_header;if(!h)throw new Error("parquet dictionary page header is undefined");const f=kg(d,Number(t.uncompressed_page_size),c,u),g={view:new DataView(f.buffer,f.byteOffset,f.byteLength),offset:0};return Bm(g,s,h.num_values,a.type_length)}else throw new Error(`parquet unsupported page type: ${t.type}`)}function Gfe(e){const t=Lm(e),r=XR[t.field_1],n=t.field_2,i=t.field_3,o=t.field_4,s=t.field_5&&{num_values:t.field_5.field_1,encoding:En[t.field_5.field_2],definition_level_encoding:En[t.field_5.field_3],repetition_level_encoding:En[t.field_5.field_4],statistics:t.field_5.field_5&&{max:t.field_5.field_5.field_1,min:t.field_5.field_5.field_2,null_count:t.field_5.field_5.field_3,distinct_count:t.field_5.field_5.field_4,max_value:t.field_5.field_5.field_5,min_value:t.field_5.field_5.field_6}},a=t.field_6,l=t.field_7&&{num_values:t.field_7.field_1,encoding:En[t.field_7.field_2],is_sorted:t.field_7.field_3},c=t.field_8&&{num_values:t.field_8.field_1,num_nulls:t.field_8.field_2,num_rows:t.field_8.field_3,encoding:En[t.field_8.field_4],definition_levels_byte_length:t.field_8.field_5,repetition_levels_byte_length:t.field_8.field_6,is_compressed:t.field_8.field_7===void 0?!0:t.field_8.field_7,statistics:t.field_8.field_8};return{type:r,uncompressed_page_size:n,compressed_page_size:i,crc:o,data_page_header:s,index_page_header:a,dictionary_page_header:l,data_page_header_v2:c}}function Wfe(e,{metadata:t},r){const{file:n,compressors:i,utf8:o}=e,s=[],a={...QR,...e.parsers};for(const l of r.chunks){const{columnMetadata:c}=l,u=iE(t.schema,c.path_in_schema),d={pathInSchema:c.path_in_schema,type:c.type,element:u[u.length-1].element,schemaPath:u,codec:c.codec,parsers:a,compressors:i,utf8:o};if(!("offsetIndex"in l)){s.push({pathInSchema:c.path_in_schema,data:Promise.resolve(n.slice(l.range.startByte,l.range.endByte)).then(h=>{const f={view:new DataView(h),offset:0};return{pageSkip:0,data:Bw(f,r,d,e.onPage)}})});continue}s.push({pathInSchema:c.path_in_schema,data:Promise.resolve(n.slice(l.offsetIndex.startByte,l.offsetIndex.endByte)).then(async h=>{const f=vfe({view:new DataView(h),offset:0}),{selectStart:g,selectEnd:m}=r,p=f.page_locations;let y=NaN,w=NaN,b=0;for(let A=0;A<p.length;A++){const P=p[A],E=Number(P.first_row_index),O=A+1<p.length?Number(p[A+1].first_row_index):r.groupRows;E<m&&O>g&&(Number.isNaN(y)&&(y=Number(P.offset),b=E),w=Number(P.offset)+P.compressed_page_size)}const x=await n.slice(y,w),C={view:new DataView(x),offset:0},S=b?{...r,groupStart:r.groupStart+b,selectStart:r.selectStart-b,selectEnd:r.selectEnd-b}:r;return{data:Bw(C,S,d,e.onPage),pageSkip:b}})})}return{groupStart:r.groupStart,groupRows:r.groupRows,asyncColumns:s}}async function Nw({asyncColumns:e},t,r,n,i){const o=await Promise.all(e.map(async({data:d})=>{const h=await d;return{...h,data:uE(h.data)}})),s=e.map(d=>d.pathInSchema[0]).filter(d=>!n||n.includes(d)),a=n??s,l=a.map(d=>e.findIndex(h=>h.pathInSchema[0]===d)),c=r-t;if(i==="object"){const d=Array(c);for(let h=0;h<c;h++){const f=t+h,g={};for(let m=0;m<e.length;m++){const{data:p,pageSkip:y}=o[m];g[e[m].pathInSchema[0]]=p[f-y]}d[h]=g}return d}const u=Array(c);for(let d=0;d<c;d++){const h=t+d,f=Array(e.length);for(let g=0;g<a.length;g++){const m=l[g];if(m>=0){const{data:p,pageSkip:y}=o[m];f[g]=p[h-y]}}u[d]=f}return u}function jfe(e,t){const{asyncColumns:r}=e,n=[];for(const i of t.children)if(i.children.length){const o=r.filter(l=>l.pathInSchema[0]===i.element.name);if(!o.length)continue;const s=new Map,a=Promise.all(o.map(l=>l.data.then(({data:c})=>{s.set(l.pathInSchema.join("."),uE(c))}))).then(()=>{rs(s,i);const l=s.get(i.path.join("."));if(!l)throw new Error("parquet column data not assembled");return{data:[l],pageSkip:0}});n.push({pathInSchema:i.path,data:a})}else{const o=r.find(s=>s.pathInSchema[0]===i.element.name);o&&n.push(o)}return{...e,asyncColumns:n}}async function _a(e){e.metadata??(e.metadata=await gfe(e.file,e));const{rowStart:t=0,rowEnd:r,columns:n,onChunk:i,onComplete:o,rowFormat:s,filter:a,filterStrict:l=!0}=e;if(a&&s!=="object")throw new Error('parquet filter requires rowFormat: "object"');const c=xl(a);if(c.length){const p=Mg(e.metadata).children.map(w=>w.element.name),y=c.filter(w=>!p.includes(w));if(y.length)throw new Error(`parquet filter columns not found: ${y.join(", ")}`)}let u=n,d=!1;if(n&&a){const p=c.filter(y=>!n.includes(y));p.length&&(u=[...n,...p],d=!0)}const h=u!==n?{...e,columns:u}:e,f=Vfe(h);if(!o&&!i){for(const{asyncColumns:p}of f)for(const{data:y}of p)await y;return}const g=Mg(e.metadata),m=f.map(p=>jfe(p,g));if(i)for(const p of m)for(const y of p.asyncColumns)y.data.then(({data:w,pageSkip:b})=>{let x=p.groupStart+b;for(const C of w)i({columnName:y.pathInSchema[0],columnData:C,rowStart:x,rowEnd:x+C.length}),x+=C.length});if(o){const p=[];for(const y of m){const w=Math.max(t-y.groupStart,0),b=Math.min((r??1/0)-y.groupStart,y.groupRows),x=s==="object"?await Nw(y,w,b,u,"object"):await Nw(y,w,b,n,"array");if(a){for(const C of x)if(ts(C,a,l)){if(d&&n)for(const S of c)n.includes(S)||delete C[S];p.push(C)}}else cE(p,x)}o(p)}else for(const{asyncColumns:p}of m)for(const{data:y}of p)await y}function Vfe(e){if(!e.metadata)throw new Error("parquet requires metadata");const t=Cfe(e);return e.file=wfe(e.file,t),t.groups.map(r=>Wfe(e,t,r))}function Ufe({messages:e}){const[t,r]=v.useState(0),n=v.useRef(0),i=v.useMemo(()=>{if(!e||e.length===0)return n.current!==0&&(n.current=0,r(l=>l+1)),[];const a=e.map((l,c)=>!l||typeof l!="object"?{index:c,time:"",type:"",message:String(l||"")}:{index:c,time:l.time||"",type:l.type||"",message:l.message||"",...Object.fromEntries(Object.entries(l).filter(([u])=>!["time","type","message"].includes(u)))});return e.length!==n.current&&(n.current=e.length,r(l=>l+1)),a},[e]),o=v.useMemo(()=>{if(!e||e.length===0)return{pinned_rows:[],column_config:[],left_col_configs:[{col_name:"index",header_name:"index",displayer_args:{displayer:"obj"}}]};const a=new Set;e.forEach(c=>{c&&typeof c=="object"&&Object.keys(c).forEach(u=>a.add(u))}),a.add("index"),a.add("time"),a.add("type"),a.add("message");const l=Array.from(a).map(c=>({col_name:c,header_name:c,displayer_args:{displayer:"obj"}}));return{pinned_rows:[],column_config:l,left_col_configs:[{col_name:"index",header_name:"index",displayer_args:{displayer:"obj"}}]}},[e]),s=()=>{};return!e||e.length===0?null:M.jsx("div",{style:{height:"300px",width:"100%",border:"1px solid red",marginTop:"10px",backgroundColor:"#1a1a1a"},children:M.jsx(ni,{data_wrapper:{data_type:"Raw",data:i,length:i.length},df_viewer_config:o,summary_stats_data:[],activeCol:["",""],setActiveCol:s,error_info:""},`df-viewer-${t}-${i.length}`)})}const pE=(e,t,r,n)=>{if(e==="main")return{data_type:"DataSource",datasource:r,length:n||50};{const i=t[e];return{data_type:"Raw",data:i,length:i.length}}},mE=(e,t)=>{const r=i=>{e.send({type:"infinite_request",payload_args:i})},n=new tfe(r);return e.on("msg:custom",(i,o)=>{if(console.log("got a message",i),(i==null?void 0:i.type)!=="infinite_resp"){console.log("bailing not infinite_resp");return}if(i.data===void 0){console.log("bailing no data",i);return}const s=i;if(s.error_info!==void 0){console.log("there was a problem with the request, not adding to the cache"),n.addErrorResponse(s),console.log(s.error_info),t(s.error_info);return}if(s.key.request_time!==void 0){const u=new Date-1-s.key.request_time;console.log(`response before ${[s.key.start,s.key.origEnd,s.key.end]} parse took ${u}`)}console.log("about to read buffers[0]",o[0]);const a=o[0],l=ei(a.buffer);console.log("metadata",l),_a({file:a.buffer,metadata:l,rowFormat:"object",onComplete:c=>{const u=c;s.data=u,n.addPayloadResponse(s)}})}),n};function vE({df_data_dict:e,df_display_args:t,df_meta:r,operations:n,on_operations:i,operation_results:o,command_config:s,buckaroo_state:a,on_buckaroo_state:l,buckaroo_options:c,src:u}){var b,x;console.log("132 BuckarooInfiniteWidget");const d=new Date,h=v.useMemo(()=>(console.log("recreating data source because operations changed",d,new Date-d),u.debugCacheState(),HR(u)),[n,a.post_processing,a.cleaning_method,JSON.stringify(a.quick_command_args)]),[f,g]=v.useState(["a","stoptime"]),m=t[a.df_display],[p,y]=v.useMemo(()=>[pE(m.data_key,e,h,r.total_rows),e[m.summary_stats_key]],[m,n,a,e]),w=[n,a.post_processing,a.quick_command_args,a.df_display];return M.jsxs("div",{className:"dcf-root flex flex-col buckaroo-widget buckaroo-infinite-widget",style:{width:"100%",height:"100%"},children:[M.jsxs("div",{className:"orig-df flex flex-row",style:{overflow:"hidden"},children:[M.jsx(Ia,{dfMeta:r,buckarooState:a,setBuckarooState:l,buckarooOptions:c,themeConfig:(x=(b=m.df_viewer_config)==null?void 0:b.component_config)==null?void 0:x.theme}),M.jsx(ni,{data_wrapper:p,df_viewer_config:m.df_viewer_config,summary_stats_data:y,outside_df_params:w,activeCol:f,setActiveCol:g,error_info:""})]}),a.show_commands?M.jsx(Zu,{df_viewer_config:m.df_viewer_config,activeColumn:f,operations:n,setOperations:i,operation_result:o,command_config:s}):M.jsx("span",{})]})}function yE({df_meta:e,df_data_dict:t,df_display_args:r,src:n,df_id:i,message_log:o,show_message_box:s}){const a=v.useMemo(()=>(console.log("recreating data source because operations changed",new Date),n.debugCacheState(),HR(n)),[]),[l,c]=v.useState(["a","stoptime"]),u=r.main,[d,h]=v.useMemo(()=>[pE(u.data_key,t,a,e.total_rows),t[u.summary_stats_key]],[u,t,a,e.total_rows]),f=[i],g=(s==null?void 0:s.enabled)??!1,m=v.useMemo(()=>{const p=o==null?void 0:o.messages;return p?Array.isArray(p)?p:(console.warn("[DFViewerInfiniteDS] message_log.messages is not an array:",typeof p,p),[]):[]},[o==null?void 0:o.messages]);return v.useEffect(()=>{console.log("[DFViewerInfiniteDS] Message box state changed:",{messagesEnabled:g,messageCount:m.length,message_log_type:typeof o,message_log_keys:o?Object.keys(o):null,message_log_messages_type:o!=null&&o.messages?typeof o.messages:null,message_log_messages_isArray:Array.isArray(o==null?void 0:o.messages),firstFewMessages:m.slice(0,3)})},[m,g,o]),M.jsx("div",{className:"dcf-root flex flex-col buckaroo-widget buckaroo-infinite-widget",style:{width:"100%",height:"100%"},children:M.jsxs("div",{className:"orig-df flex flex-row",style:{overflow:"hidden"},children:[g&&M.jsx(Ufe,{messages:m}),M.jsx(ni,{data_wrapper:d,df_viewer_config:u.df_viewer_config,summary_stats_data:h,outside_df_params:f,activeCol:l,setActiveCol:c,error_info:""})]})})}function zm(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)&&e.format==="parquet_b64"&&typeof e.data=="string"}const Ci=new Map,Kfe=8;function Ig(e,t){if(Ci.size>=Kfe){const r=Ci.keys().next().value;r!==void 0&&Ci.delete(r)}Ci.set(e,t)}function bE(e){const t=atob(e),r=new Uint8Array(t.length);for(let n=0;n<t.length;n++)r[n]=t.charCodeAt(n);return r.buffer}function CE(e){const t={};for(const[r,n]of Object.entries(e))if(r==="index"||r==="level_0")t[r]=typeof n=="bigint"?Number(n):n;else if(typeof n=="string")try{t[r]=JSON.parse(n)}catch{t[r]=n}else if(typeof n=="bigint"){const i=BigInt(Number.MAX_SAFE_INTEGER);t[r]=n>=-i&&n<=i?Number(n):String(n)}else t[r]=n;return t}function Xc(e){if(e==null)return[];if(Array.isArray(e))return e;if(zm(e)){const t=Ci.get(e.data);if(t&&t.length>0)return t;try{const r=bE(e.data),n=ei(r);let i=[];return _a({file:r,metadata:n,rowFormat:"object",onComplete:o=>{i=o.map(CE),Ig(e.data,i)}}),i.length>0&&Ig(e.data,i),i}catch(r){return console.error("resolveDFData: failed to decode parquet_b64",r),[]}}return console.warn("resolveDFData: unknown payload format",e),[]}async function pa(e){if(e==null)return[];if(Array.isArray(e))return e;if(zm(e)){const t=Ci.get(e.data);if(t&&t.length>0)return t;try{const r=bE(e.data),n=ei(r),o=(await new Promise((s,a)=>{try{_a({file:r,metadata:n,rowFormat:"object",onComplete:l=>s(l)})}catch(l){a(l)}})).map(CE);return Ig(e.data,o),o}catch(r){return console.error("resolveDFDataAsync: failed to decode parquet_b64",r),[]}}return console.warn("resolveDFDataAsync: unknown payload format",e),[]}async function wE(e){if(!e)return{};const t={},r=[];for(const[n,i]of Object.entries(e))zm(i)?r.push(pa(i).then(o=>{t[n]=o})):t[n]=i;return await Promise.all(r),t}function SE({artifact:e}){const[t,r]=v.useState(null),[n,i]=v.useState(null);return v.useEffect(()=>{let o=!1;return Promise.all([pa(e.df_data),pa(e.summary_stats_data)]).then(([s,a])=>{o||(r(s),i(a))}),()=>{o=!0}},[e]),t===null||n===null?M.jsx("div",{style:{padding:20,fontFamily:"sans-serif"},children:"Loading..."}):e.embed_type==="Buckaroo"&&e.df_display_args&&e.df_data_dict&&e.df_meta&&e.buckaroo_options&&e.buckaroo_state?M.jsx(qfe,{dfData:t,summaryStats:n,artifact:e}):M.jsx(gu,{df_data:t,df_viewer_config:e.df_viewer_config,summary_stats_data:n})}function qfe({dfData:e,summaryStats:t,artifact:r}){var h,f;const[n,i]=v.useState(r.buckaroo_state),[o,s]=v.useState(["",""]),a=r.df_display_args,l=r.df_data_dict,c=a[n.df_display],[u,d]=v.useMemo(()=>{const g=c.data_key,m=c.summary_stats_key,p=g==="main"?e:Xc(l[g]),y=m==="all_stats"?t:Xc(l[m]);return[{data_type:"Raw",data:p,length:p.length},y]},[n.df_display,c,e,t,l]);return M.jsx("div",{className:"dcf-root flex flex-col buckaroo-widget buckaroo-infinite-widget",style:{width:"100%",height:"100%"},children:M.jsxs("div",{className:"orig-df flex flex-row",style:{overflow:"hidden"},children:[M.jsx(Ia,{dfMeta:r.df_meta,buckarooState:n,setBuckarooState:i,buckarooOptions:r.buckaroo_options,themeConfig:(f=(h=c.df_viewer_config)==null?void 0:h.component_config)==null?void 0:f.theme}),M.jsx(ni,{data_wrapper:u,df_viewer_config:c.df_viewer_config,summary_stats_data:d,activeCol:o,setActiveCol:s})]})})}const Yfe=[{athlete:"Michael Phelps",age:23,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:8,silver:0,bronze:0,total:8},{athlete:"Michael Phelps",age:19,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:6,silver:0,bronze:2,total:8},{athlete:"Michael Phelps",age:27,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:4,silver:2,bronze:0,total:6},{athlete:"Natalie Coughlin",age:25,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:2,bronze:3,total:6},{athlete:"Aleksey Nemov",age:24,country:"Russia",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:2,silver:1,bronze:3,total:6},{athlete:"Alicia Coutts",age:24,country:"Australia",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:3,bronze:1,total:5},{athlete:"Missy Franklin",age:17,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:4,silver:0,bronze:1,total:5},{athlete:"Ryan Lochte",age:27,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:2,bronze:1,total:5},{athlete:"Allison Schmitt",age:22,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:3,silver:1,bronze:1,total:5},{athlete:"Natalie Coughlin",age:21,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:2,silver:2,bronze:1,total:5},{athlete:"Ian Thorpe",age:17,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:3,silver:2,bronze:0,total:5},{athlete:"Dara Torres",age:33,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:3,total:5},{athlete:"Cindy Klassen",age:26,country:"Canada",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:1,silver:2,bronze:2,total:5},{athlete:"Nastia Liukin",age:18,country:"United States",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:1,silver:3,bronze:1,total:5},{athlete:"Marit Bjørgen",age:29,country:"Norway",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:3,silver:1,bronze:1,total:5},{athlete:"Sun Yang",age:20,country:"China",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:1,bronze:1,total:4},{athlete:"Kirsty Coventry",age:24,country:"Zimbabwe",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:3,bronze:0,total:4},{athlete:"Libby Lenton-Trickett",age:23,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:1,bronze:1,total:4},{athlete:"Ryan Lochte",age:24,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:0,bronze:2,total:4},{athlete:"Inge de Bruijn",age:30,country:"Netherlands",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:2,total:4},{athlete:"Petria Thomas",age:28,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:3,silver:1,bronze:0,total:4},{athlete:"Ian Thorpe",age:21,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:2,silver:1,bronze:1,total:4},{athlete:"Inge de Bruijn",age:27,country:"Netherlands",year:2e3,date:"01/10/2000",sport:"Swimming",gold:3,silver:1,bronze:0,total:4},{athlete:"Gary Hall Jr.",age:25,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:1,bronze:1,total:4},{athlete:"Michael Klim",age:23,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:2,bronze:0,total:4},{athlete:"Susie O'Neill",age:27,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:3,bronze:0,total:4},{athlete:"Jenny Thompson",age:27,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:3,silver:0,bronze:1,total:4},{athlete:"Pieter van den Hoogenband",age:22,country:"Netherlands",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:2,total:4},{athlete:"An Hyeon-Su",age:20,country:"South Korea",year:2006,date:"26/02/2006",sport:"Short-Track Speed Skating",gold:3,silver:0,bronze:1,total:4},{athlete:"Aliya Mustafina",age:17,country:"Russia",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:1,silver:1,bronze:2,total:4},{athlete:"Shawn Johnson",age:16,country:"United States",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:1,silver:3,bronze:0,total:4},{athlete:"Dmitry Sautin",age:26,country:"Russia",year:2e3,date:"01/10/2000",sport:"Diving",gold:1,silver:1,bronze:2,total:4},{athlete:"Leontien Zijlaard-van Moorsel",age:30,country:"Netherlands",year:2e3,date:"01/10/2000",sport:"Cycling",gold:3,silver:1,bronze:0,total:4},{athlete:"Petter Northug Jr.",age:24,country:"Norway",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:2,silver:1,bronze:1,total:4},{athlete:"Ole Einar Bjørndalen",age:28,country:"Norway",year:2002,date:"24/02/2002",sport:"Biathlon",gold:4,silver:0,bronze:0,total:4},{athlete:"Janica Kostelic",age:20,country:"Croatia",year:2002,date:"24/02/2002",sport:"Alpine Skiing",gold:3,silver:1,bronze:0,total:4},{athlete:"Nathan Adrian",age:23,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:1,bronze:0,total:3},{athlete:"Yannick Agnel",age:20,country:"France",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:1,bronze:0,total:3},{athlete:"Brittany Elmslie",age:18,country:"Australia",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:2,bronze:0,total:3},{athlete:"Matt Grevers",age:27,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:1,bronze:0,total:3},{athlete:"Ryosuke Irie",age:22,country:"Japan",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:2,bronze:1,total:3},{athlete:"Cullen Jones",age:28,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:2,bronze:0,total:3},{athlete:"Ranomi Kromowidjojo",age:21,country:"Netherlands",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:1,bronze:0,total:3},{athlete:"Camille Muffat",age:22,country:"France",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"Mel Schlanger",age:25,country:"Australia",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:2,bronze:0,total:3},{athlete:"Emily Seebohm",age:20,country:"Australia",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:2,bronze:0,total:3},{athlete:"Rebecca Soni",age:25,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:1,bronze:0,total:3},{athlete:"Satomi Suzuki",age:21,country:"Japan",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:1,bronze:2,total:3},{athlete:"Dana Vollmer",age:24,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:3,silver:0,bronze:0,total:3},{athlete:"Alain Bernard",age:25,country:"France",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"László Cseh Jr.",age:22,country:"Hungary",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:3,bronze:0,total:3},{athlete:"Matt Grevers",age:23,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:1,bronze:0,total:3},{athlete:"Margaret Hoelzer",age:25,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:2,bronze:1,total:3},{athlete:"Katie Hoff",age:19,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:1,bronze:2,total:3},{athlete:"Leisel Jones",age:22,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:1,bronze:0,total:3},{athlete:"Kosuke Kitajima",age:25,country:"Japan",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:0,bronze:1,total:3},{athlete:"Andrew Lauterstein",age:21,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:1,bronze:2,total:3},{athlete:"Jason Lezak",age:32,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:0,bronze:1,total:3},{athlete:"Pang Jiaying",age:23,country:"China",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:1,bronze:2,total:3},{athlete:"Aaron Peirsol",age:25,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:1,bronze:0,total:3},{athlete:"Steph Rice",age:20,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:3,silver:0,bronze:0,total:3},{athlete:"Jess Schipper",age:21,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:0,bronze:2,total:3},{athlete:"Rebecca Soni",age:21,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:2,bronze:0,total:3},{athlete:"Eamon Sullivan",age:22,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:2,bronze:1,total:3},{athlete:"Dara Torres",age:41,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:3,bronze:0,total:3},{athlete:"Amanda Beard",age:22,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:2,bronze:0,total:3},{athlete:"Antje Buschschulte",age:25,country:"Germany",year:2004,date:"29/08/2004",sport:"Swimming",gold:0,silver:0,bronze:3,total:3},{athlete:"Kirsty Coventry",age:20,country:"Zimbabwe",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"Ian Crocker",age:21,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"Grant Hackett",age:24,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:2,bronze:0,total:3},{athlete:"Brendan Hansen",age:22,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"Jodie Henry",age:20,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:3,silver:0,bronze:0,total:3},{athlete:"Otylia Jedrzejczak",age:20,country:"Poland",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:2,bronze:0,total:3},{athlete:"Leisel Jones",age:18,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"Kosuke Kitajima",age:21,country:"Japan",year:2004,date:"29/08/2004",sport:"Swimming",gold:2,silver:0,bronze:1,total:3},{athlete:"Laure Manaudou",age:17,country:"France",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"Aaron Peirsol",age:21,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:3,silver:0,bronze:0,total:3},{athlete:"Kaitlin Sandeno",age:21,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"Roland Schoeman",age:24,country:"South Africa",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"Pieter van den Hoogenband",age:26,country:"Netherlands",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:2,bronze:0,total:3},{athlete:"Therese Alshammar",age:23,country:"Sweden",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:2,bronze:1,total:3},{athlete:"Yana Klochkova",age:18,country:"Ukraine",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:1,bronze:0,total:3},{athlete:"Lenny Krayzelburg",age:24,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:3,silver:0,bronze:0,total:3},{athlete:"Massimiliano Rosolino",age:22,country:"Italy",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:1,bronze:1,total:3},{athlete:"Petria Thomas",age:25,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:2,bronze:1,total:3},{athlete:"Matt Welsh",age:23,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:2,bronze:1,total:3},{athlete:"Lee Jeong-Su",age:20,country:"South Korea",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:2,silver:1,bronze:0,total:3},{athlete:"Apolo Anton Ohno",age:27,country:"United States",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:0,silver:1,bronze:2,total:3},{athlete:"Wang Meng",age:24,country:"China",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:3,silver:0,bronze:0,total:3},{athlete:"Jin Seon-Yu",age:17,country:"South Korea",year:2006,date:"26/02/2006",sport:"Short-Track Speed Skating",gold:3,silver:0,bronze:0,total:3},{athlete:"Lee Ho-Seok",age:19,country:"South Korea",year:2006,date:"26/02/2006",sport:"Short-Track Speed Skating",gold:1,silver:2,bronze:0,total:3},{athlete:"Apolo Anton Ohno",age:23,country:"United States",year:2006,date:"26/02/2006",sport:"Short-Track Speed Skating",gold:1,silver:0,bronze:2,total:3},{athlete:"Wang Meng",age:20,country:"China",year:2006,date:"26/02/2006",sport:"Short-Track Speed Skating",gold:1,silver:1,bronze:1,total:3},{athlete:"Marc Gagnon",age:26,country:"Canada",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:2,silver:0,bronze:1,total:3},{athlete:"Yang Yang (A)",age:25,country:"China",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:2,silver:1,bronze:0,total:3},{athlete:"Stephanie Beckert",age:21,country:"Germany",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:1,silver:2,bronze:0,total:3},{athlete:"Martina Sáblíková",age:22,country:"Czech Republic",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:2,silver:0,bronze:1,total:3},{athlete:"Enrico Fabris",age:24,country:"Italy",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:2,silver:0,bronze:1,total:3},{athlete:"Chad Hedrick",age:28,country:"United States",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:1,silver:1,bronze:1,total:3},{athlete:"Jochem Uytdehaage",age:25,country:"Netherlands",year:2002,date:"24/02/2002",sport:"Speed Skating",gold:2,silver:1,bronze:0,total:3},{athlete:"Sabine Völker",age:28,country:"Germany",year:2002,date:"24/02/2002",sport:"Speed Skating",gold:0,silver:2,bronze:1,total:3},{athlete:"Gregor Schlierenzauer",age:20,country:"Austria",year:2010,date:"28/02/2010",sport:"Ski Jumping",gold:1,silver:0,bronze:2,total:3},{athlete:"Lars Bystøl",age:27,country:"Norway",year:2006,date:"26/02/2006",sport:"Ski Jumping",gold:1,silver:0,bronze:2,total:3},{athlete:"Johnny Spillane",age:29,country:"United States",year:2010,date:"28/02/2010",sport:"Nordic Combined",gold:0,silver:3,bronze:0,total:3},{athlete:"Felix Gottwald",age:30,country:"Austria",year:2006,date:"26/02/2006",sport:"Nordic Combined",gold:2,silver:1,bronze:0,total:3},{athlete:"Georg Hettich",age:27,country:"Germany",year:2006,date:"26/02/2006",sport:"Nordic Combined",gold:1,silver:1,bronze:1,total:3},{athlete:"Felix Gottwald",age:26,country:"Austria",year:2002,date:"24/02/2002",sport:"Nordic Combined",gold:0,silver:0,bronze:3,total:3},{athlete:"Samppa Lajunen",age:22,country:"Finland",year:2002,date:"24/02/2002",sport:"Nordic Combined",gold:3,silver:0,bronze:0,total:3},{athlete:"Aly Raisman",age:18,country:"United States",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:2,silver:0,bronze:1,total:3},{athlete:"Kohei Uchimura",age:23,country:"Japan",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:1,silver:2,bronze:0,total:3},{athlete:"Zou Kai",age:24,country:"China",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:2,silver:0,bronze:1,total:3},{athlete:"Cheng Fei",age:20,country:"China",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:1,silver:0,bronze:2,total:3},{athlete:"Yang Wei",age:28,country:"China",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:2,silver:1,bronze:0,total:3},{athlete:"Yang Yilin",age:15,country:"China",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:1,silver:0,bronze:2,total:3},{athlete:"Zou Kai",age:20,country:"China",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:3,silver:0,bronze:0,total:3},{athlete:"Marian Dragulescu",age:23,country:"Romania",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:0,silver:1,bronze:2,total:3},{athlete:"Paul Hamm",age:21,country:"United States",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:1,silver:2,bronze:0,total:3},{athlete:"Carly Patterson",age:16,country:"United States",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:1,silver:2,bronze:0,total:3},{athlete:"Catalina Ponor",age:16,country:"Romania",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:3,silver:0,bronze:0,total:3},{athlete:"Simona Amânar",age:20,country:"Romania",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:2,silver:0,bronze:1,total:3},{athlete:"Svetlana Khorkina",age:21,country:"Russia",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:1,silver:2,bronze:0,total:3},{athlete:"Yekaterina Lobaznyuk",age:17,country:"Russia",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:0,silver:2,bronze:1,total:3},{athlete:"Yelena Zamolodchikova",age:17,country:"Russia",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:2,silver:1,bronze:0,total:3},{athlete:"Guo Shuang",age:26,country:"China",year:2012,date:"12/08/2012",sport:"Cycling",gold:0,silver:2,bronze:1,total:3},{athlete:"Chris Hoy",age:32,country:"Great Britain",year:2008,date:"24/08/2008",sport:"Cycling",gold:3,silver:0,bronze:0,total:3},{athlete:"Bradley Wiggins",age:24,country:"Great Britain",year:2004,date:"29/08/2004",sport:"Cycling",gold:1,silver:1,bronze:1,total:3},{athlete:"Florian Rousseau",age:26,country:"France",year:2e3,date:"01/10/2000",sport:"Cycling",gold:2,silver:1,bronze:0,total:3},{athlete:"Justyna Kowalczyk",age:27,country:"Poland",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:1,silver:1,bronze:1,total:3},{athlete:"Johan Olsson",age:29,country:"Sweden",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:1,silver:0,bronze:2,total:3},{athlete:"Stefania Belmondo",age:33,country:"Italy",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:1,silver:1,bronze:1,total:3},{athlete:"Yuliya Chepalova",age:25,country:"Russia",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:1,silver:1,bronze:1,total:3},{athlete:"Frode Estil",age:29,country:"Norway",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:2,silver:1,bronze:0,total:3},{athlete:"Bente Skari-Martinsen",age:29,country:"Norway",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:1,silver:1,bronze:1,total:3},{athlete:"Magdalena Neuner",age:23,country:"Germany",year:2010,date:"28/02/2010",sport:"Biathlon",gold:2,silver:1,bronze:0,total:3},{athlete:"Emil Hegle Svendsen",age:24,country:"Norway",year:2010,date:"28/02/2010",sport:"Biathlon",gold:2,silver:1,bronze:0,total:3},{athlete:"Albina Akhatova",age:29,country:"Russia",year:2006,date:"26/02/2006",sport:"Biathlon",gold:1,silver:0,bronze:2,total:3},{athlete:"Ole Einar Bjørndalen",age:32,country:"Norway",year:2006,date:"26/02/2006",sport:"Biathlon",gold:0,silver:2,bronze:1,total:3},{athlete:"Sven Fischer",age:34,country:"Germany",year:2006,date:"26/02/2006",sport:"Biathlon",gold:2,silver:0,bronze:1,total:3},{athlete:"Martina Glagow-Beck",age:26,country:"Germany",year:2006,date:"26/02/2006",sport:"Biathlon",gold:0,silver:3,bronze:0,total:3},{athlete:"Michael Greis",age:29,country:"Germany",year:2006,date:"26/02/2006",sport:"Biathlon",gold:3,silver:0,bronze:0,total:3},{athlete:"Kati Wilhelm",age:29,country:"Germany",year:2006,date:"26/02/2006",sport:"Biathlon",gold:1,silver:2,bronze:0,total:3},{athlete:"Kati Wilhelm",age:25,country:"Germany",year:2002,date:"24/02/2002",sport:"Biathlon",gold:2,silver:1,bronze:0,total:3},{athlete:"Yohan Blake",age:22,country:"Jamaica",year:2012,date:"12/08/2012",sport:"Athletics",gold:1,silver:2,bronze:0,total:3},{athlete:"Usain Bolt",age:25,country:"Jamaica",year:2012,date:"12/08/2012",sport:"Athletics",gold:3,silver:0,bronze:0,total:3},{athlete:"Allyson Felix",age:26,country:"United States",year:2012,date:"12/08/2012",sport:"Athletics",gold:3,silver:0,bronze:0,total:3},{athlete:"Shelly-Ann Fraser-Pryce",age:25,country:"Jamaica",year:2012,date:"12/08/2012",sport:"Athletics",gold:1,silver:2,bronze:0,total:3},{athlete:"Carmelita Jeter",age:32,country:"United States",year:2012,date:"12/08/2012",sport:"Athletics",gold:1,silver:1,bronze:1,total:3},{athlete:"Usain Bolt",age:21,country:"Jamaica",year:2008,date:"24/08/2008",sport:"Athletics",gold:3,silver:0,bronze:0,total:3},{athlete:"Veronica Campbell-Brown",age:22,country:"Jamaica",year:2004,date:"29/08/2004",sport:"Athletics",gold:2,silver:0,bronze:1,total:3},{athlete:"Justin Gatlin",age:22,country:"United States",year:2004,date:"29/08/2004",sport:"Athletics",gold:1,silver:1,bronze:1,total:3},{athlete:"Bode Miller",age:32,country:"United States",year:2010,date:"28/02/2010",sport:"Alpine Skiing",gold:1,silver:1,bronze:1,total:3},{athlete:"Aksel Lund Svindal",age:27,country:"Norway",year:2010,date:"28/02/2010",sport:"Alpine Skiing",gold:1,silver:1,bronze:1,total:3},{athlete:"Anja Pärson",age:24,country:"Sweden",year:2006,date:"26/02/2006",sport:"Alpine Skiing",gold:1,silver:0,bronze:2,total:3},{athlete:"Stephan Eberharter",age:32,country:"Austria",year:2002,date:"24/02/2002",sport:"Alpine Skiing",gold:1,silver:1,bronze:1,total:3},{athlete:"Ding Ning",age:22,country:"China",year:2012,date:"12/08/2012",sport:"Table Tennis",gold:1,silver:1,bronze:0,total:2},{athlete:"Feng Tian Wei",age:25,country:"Singapore",year:2012,date:"12/08/2012",sport:"Table Tennis",gold:0,silver:0,bronze:2,total:2},{athlete:"Li Xiaoxia",age:24,country:"China",year:2012,date:"12/08/2012",sport:"Table Tennis",gold:2,silver:0,bronze:0,total:2},{athlete:"Dmitrij Ovtcharov",age:23,country:"Germany",year:2012,date:"12/08/2012",sport:"Table Tennis",gold:0,silver:0,bronze:2,total:2},{athlete:"Wang Hao",age:28,country:"China",year:2012,date:"12/08/2012",sport:"Table Tennis",gold:1,silver:1,bronze:0,total:2},{athlete:"Zhang Jike",age:24,country:"China",year:2012,date:"12/08/2012",sport:"Table Tennis",gold:2,silver:0,bronze:0,total:2},{athlete:"Guo Yue",age:20,country:"China",year:2008,date:"24/08/2008",sport:"Table Tennis",gold:1,silver:0,bronze:1,total:2},{athlete:"Ma Lin",age:28,country:"China",year:2008,date:"24/08/2008",sport:"Table Tennis",gold:2,silver:0,bronze:0,total:2},{athlete:"Wang Hao",age:24,country:"China",year:2008,date:"24/08/2008",sport:"Table Tennis",gold:1,silver:1,bronze:0,total:2},{athlete:"Wang Liqin",age:30,country:"China",year:2008,date:"24/08/2008",sport:"Table Tennis",gold:1,silver:0,bronze:1,total:2},{athlete:"Wang Nan",age:29,country:"China",year:2008,date:"24/08/2008",sport:"Table Tennis",gold:1,silver:1,bronze:0,total:2},{athlete:"Zhang Yining",age:26,country:"China",year:2008,date:"24/08/2008",sport:"Table Tennis",gold:2,silver:0,bronze:0,total:2},{athlete:"Zhang Yining",age:22,country:"China",year:2004,date:"29/08/2004",sport:"Table Tennis",gold:2,silver:0,bronze:0,total:2},{athlete:"Kong Linghui",age:24,country:"China",year:2e3,date:"01/10/2000",sport:"Table Tennis",gold:1,silver:1,bronze:0,total:2},{athlete:"Li Ju",age:24,country:"China",year:2e3,date:"01/10/2000",sport:"Table Tennis",gold:1,silver:1,bronze:0,total:2},{athlete:"Liu Guoliang",age:24,country:"China",year:2e3,date:"01/10/2000",sport:"Table Tennis",gold:0,silver:1,bronze:1,total:2},{athlete:"Wang Nan",age:21,country:"China",year:2e3,date:"01/10/2000",sport:"Table Tennis",gold:2,silver:0,bronze:0,total:2},{athlete:"Viktoriya Azarenko",age:22,country:"Belarus",year:2012,date:"12/08/2012",sport:"Tennis",gold:1,silver:0,bronze:1,total:2},{athlete:"Mike Bryan",age:34,country:"United States",year:2012,date:"12/08/2012",sport:"Tennis",gold:1,silver:0,bronze:1,total:2},{athlete:"Andy Murray",age:25,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Tennis",gold:1,silver:1,bronze:0,total:2},{athlete:"Serena Williams",age:30,country:"United States",year:2012,date:"12/08/2012",sport:"Tennis",gold:2,silver:0,bronze:0,total:2},{athlete:"Fernando González",age:24,country:"Chile",year:2004,date:"29/08/2004",sport:"Tennis",gold:1,silver:0,bronze:1,total:2},{athlete:"Nicolás Massú",age:26,country:"Chile",year:2004,date:"29/08/2004",sport:"Tennis",gold:2,silver:0,bronze:0,total:2},{athlete:"Venus Williams",age:20,country:"United States",year:2e3,date:"01/10/2000",sport:"Tennis",gold:2,silver:0,bronze:0,total:2},{athlete:"Ona Carbonell",age:22,country:"Spain",year:2012,date:"12/08/2012",sport:"Synchronized Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Andrea Fuentes",age:29,country:"Spain",year:2012,date:"12/08/2012",sport:"Synchronized Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Huang Xuechen",age:22,country:"China",year:2012,date:"12/08/2012",sport:"Synchronized Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Nataliya Ishchenko",age:26,country:"Russia",year:2012,date:"12/08/2012",sport:"Synchronized Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Liu Ou",age:25,country:"China",year:2012,date:"12/08/2012",sport:"Synchronized Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Svetlana Romashina",age:22,country:"Russia",year:2012,date:"12/08/2012",sport:"Synchronized Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Anastasiya Davydova",age:25,country:"Russia",year:2008,date:"24/08/2008",sport:"Synchronized Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Andrea Fuentes",age:25,country:"Spain",year:2008,date:"24/08/2008",sport:"Synchronized Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Gemma Mengual",age:31,country:"Spain",year:2008,date:"24/08/2008",sport:"Synchronized Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Anastasiya Yermakova",age:25,country:"Russia",year:2008,date:"24/08/2008",sport:"Synchronized Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Alison Bartosik",age:21,country:"United States",year:2004,date:"29/08/2004",sport:"Synchronized Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Anastasiya Davydova",age:21,country:"Russia",year:2004,date:"29/08/2004",sport:"Synchronized Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Anna Kozlova",age:31,country:"United States",year:2004,date:"29/08/2004",sport:"Synchronized Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Miya Tachibana",age:29,country:"Japan",year:2004,date:"29/08/2004",sport:"Synchronized Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Miho Takeda",age:27,country:"Japan",year:2004,date:"29/08/2004",sport:"Synchronized Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Anastasiya Yermakova",age:21,country:"Russia",year:2004,date:"29/08/2004",sport:"Synchronized Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Olga Brusnikina",age:21,country:"Russia",year:2e3,date:"01/10/2000",sport:"Synchronized Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Mariya Kiselyova",age:25,country:"Russia",year:2e3,date:"01/10/2000",sport:"Synchronized Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Miya Tachibana",age:25,country:"Japan",year:2e3,date:"01/10/2000",sport:"Synchronized Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Miho Takeda",age:24,country:"Japan",year:2e3,date:"01/10/2000",sport:"Synchronized Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Becky Adlington",age:23,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Bronte Barratt",age:23,country:"Australia",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Elizabeth Beisel",age:19,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Mireia Belmonte",age:21,country:"Spain",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Ricky Berens",age:24,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Aleksandra Gerasimenya",age:26,country:"Belarus",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Brendan Hansen",age:30,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Jessica Hardy",age:25,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Chad le Clos",age:20,country:"South Africa",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Clément Lefert",age:24,country:"France",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Amaury Leveaux",age:26,country:"France",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"James Magnussen",age:21,country:"Australia",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Takeshi Matsuda",age:28,country:"Japan",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Oussama Mellouli",age:28,country:"Tunisia",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Park Tae-Hwan",age:22,country:"South Korea",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Christian Sprenger",age:26,country:"Australia",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Jeremy Stravius",age:24,country:"France",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Aya Terakawa",age:27,country:"Japan",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Nick Thoman",age:26,country:"United States",year:2012,date:"12/08/2012",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Marleen Veldhuis",age:33,country:"Netherlands",year:2012,date:"12/08/2012",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Ye Shiwen",age:16,country:"China",year:2012,date:"12/08/2012",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Becky Adlington",age:19,country:"Great Britain",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Leith Brodie",age:22,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Cate Campbell",age:16,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"César Cielo Filho",age:21,country:"Brazil",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Hugues Duboscq",age:26,country:"France",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Felicity Galvez",age:23,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Grant Hackett",age:28,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Kara Lynn Joyce",age:22,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Amaury Leveaux",age:22,country:"France",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Christine Magnuson",age:22,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Patrick Murphy",age:24,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Park Tae-Hwan",age:18,country:"South Korea",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Shayne Reese",age:25,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Brenton Rickard",age:24,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Mel Schlanger",age:21,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Julia Smit",age:20,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Britta Steffen",age:24,country:"Germany",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Hayden Stoeckel",age:24,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Matt Targett",age:22,country:"Australia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Peter Vanderkaay",age:24,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Arkady Vyachanin",age:24,country:"Russia",year:2008,date:"24/08/2008",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Garrett Weber-Gale",age:23,country:"United States",year:2008,date:"24/08/2008",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Lindsay Benko",age:27,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Gary Hall Jr.",age:29,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Brooke Hanson",age:26,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Kara Lynn Joyce",age:18,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Klete Keller",age:22,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Yana Klochkova",age:22,country:"Ukraine",year:2004,date:"29/08/2004",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Rachel Komisarz",age:27,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Libby Lenton-Trickett",age:19,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Jason Lezak",age:28,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Ryan Lochte",age:20,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Alice Mills",age:18,country:"Australia",year:2004,date:"29/08/2004",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Tomomi Morita",age:19,country:"Japan",year:2004,date:"29/08/2004",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Markus Rogan",age:22,country:"Austria",year:2004,date:"29/08/2004",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Jenny Thompson",age:31,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Franziska van Almsick",age:26,country:"Germany",year:2004,date:"29/08/2004",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Neil Walker",age:28,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:1,silver:0,bronze:1,total:2},{athlete:"Amanda Weir",age:18,country:"United States",year:2004,date:"29/08/2004",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Takashi Yamamoto",age:26,country:"Japan",year:2004,date:"29/08/2004",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Brooke Bennett",age:20,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Beatrice Coada-Caslaru",age:25,country:"Romania",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Josh Davis",age:28,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Tom Dolan",age:25,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Anthony Ervin",age:19,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Domenico Fioravanti",age:23,country:"Italy",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Grant Hackett",age:20,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Geoff Huegill",age:21,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Leisel Jones",age:15,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Klete Keller",age:18,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Jason Lezak",age:24,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Diana Mocanu",age:16,country:"Romania",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Martina Moravcová",age:24,country:"Slovakia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Ed Moses",age:20,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Diana Munz",age:18,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Mai Nakamura",age:21,country:"Japan",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:1,bronze:1,total:2},{athlete:"Todd Pearson",age:22,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Adam Pine",age:24,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"Claudia Poll",age:27,country:"Costa Rica",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Megan Quann-Jendrick",age:16,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Giaan Rooney",age:17,country:"Australia",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:2,bronze:0,total:2},{athlete:"Courtney Shealy",age:22,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Ashley Tappin",age:25,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Stev Theloke",age:22,country:"Germany",year:2e3,date:"01/10/2000",sport:"Swimming",gold:0,silver:0,bronze:2,total:2},{athlete:"Amy Van Dyken",age:27,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:2,silver:0,bronze:0,total:2},{athlete:"Neil Walker",age:24,country:"United States",year:2e3,date:"01/10/2000",sport:"Swimming",gold:1,silver:1,bronze:0,total:2},{athlete:"J. R. Celski",age:19,country:"United States",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:0,silver:0,bronze:2,total:2},{athlete:"Charles Hamelin",age:25,country:"Canada",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:2,silver:0,bronze:0,total:2},{athlete:"Lee Ho-Seok",age:23,country:"South Korea",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:0,silver:2,bronze:0,total:2},{athlete:"Park Seung-Hui",age:17,country:"South Korea",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:0,silver:0,bronze:2,total:2},{athlete:"Katherine Reutter",age:21,country:"United States",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"Seong Si-Baek",age:22,country:"South Korea",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:0,silver:2,bronze:0,total:2},{athlete:"Marianne St-Gelais",age:19,country:"Canada",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:0,silver:2,bronze:0,total:2},{athlete:"François-Louis Tremblay",age:29,country:"Canada",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:1,silver:0,bronze:1,total:2},{athlete:"Zhou Yang",age:18,country:"China",year:2010,date:"28/02/2010",sport:"Short-Track Speed Skating",gold:2,silver:0,bronze:0,total:2},{athlete:"Choi Eun-Gyeong",age:21,country:"South Korea",year:2006,date:"26/02/2006",sport:"Short-Track Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Anouk Leblanc-Boucher",age:21,country:"Canada",year:2006,date:"26/02/2006",sport:"Short-Track Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"François-Louis Tremblay",age:25,country:"Canada",year:2006,date:"26/02/2006",sport:"Short-Track Speed Skating",gold:0,silver:2,bronze:0,total:2},{athlete:"Choi Eun-Gyeong",age:17,country:"South Korea",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Go Gi-Hyeon",age:15,country:"South Korea",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Jonathan Guilmette",age:23,country:"Canada",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Li Jiajun",age:26,country:"China",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"Apolo Anton Ohno",age:19,country:"United States",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Evgeniya Radanova",age:24,country:"Bulgaria",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"Mathieu Turcotte",age:25,country:"Canada",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:1,silver:0,bronze:1,total:2},{athlete:"Wang Chunlu",age:23,country:"China",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"Yang Yang (S)",age:24,country:"China",year:2002,date:"24/02/2002",sport:"Short-Track Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"Shani Davis",age:27,country:"United States",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Kristina Groves",age:33,country:"Canada",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"Chad Hedrick",age:32,country:"United States",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"Sven Kramer",age:23,country:"Netherlands",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:1,silver:0,bronze:1,total:2},{athlete:"Lee Seung-Hun",age:21,country:"South Korea",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Mo Tae-Beom",age:21,country:"South Korea",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Ivan Skobrev",age:27,country:"Russia",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"Mark Tuitert",age:29,country:"Netherlands",year:2010,date:"28/02/2010",sport:"Speed Skating",gold:1,silver:0,bronze:1,total:2},{athlete:"Joey Cheek",age:26,country:"United States",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Shani Davis",age:23,country:"United States",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Anni Friesinger-Postma",age:29,country:"Germany",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:1,silver:0,bronze:1,total:2},{athlete:"Kristina Groves",age:29,country:"Canada",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:0,silver:2,bronze:0,total:2},{athlete:"Clara Hughes",age:33,country:"Canada",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Sven Kramer",age:19,country:"Netherlands",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:0,silver:1,bronze:1,total:2},{athlete:"Claudia Pechstein",age:33,country:"Germany",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Carl Verheijen",age:30,country:"Netherlands",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:0,silver:0,bronze:2,total:2},{athlete:"Erben Wennemars",age:30,country:"Netherlands",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:0,silver:0,bronze:2,total:2},{athlete:"Ireen Wüst",age:19,country:"Netherlands",year:2006,date:"26/02/2006",sport:"Speed Skating",gold:1,silver:0,bronze:1,total:2},{athlete:"Derek Parra",age:31,country:"United States",year:2002,date:"24/02/2002",sport:"Speed Skating",gold:1,silver:1,bronze:0,total:2},{athlete:"Claudia Pechstein",age:29,country:"Germany",year:2002,date:"24/02/2002",sport:"Speed Skating",gold:2,silver:0,bronze:0,total:2},{athlete:"Jennifer Rodriguez",age:25,country:"United States",year:2002,date:"24/02/2002",sport:"Speed Skating",gold:0,silver:0,bronze:2,total:2},{athlete:"Simon Ammann",age:28,country:"Switzerland",year:2010,date:"28/02/2010",sport:"Ski Jumping",gold:2,silver:0,bronze:0,total:2},{athlete:"Adam Malysz",age:32,country:"Poland",year:2010,date:"28/02/2010",sport:"Ski Jumping",gold:0,silver:2,bronze:0,total:2},{athlete:"Matti Hautamäki",age:24,country:"Finland",year:2006,date:"26/02/2006",sport:"Ski Jumping",gold:0,silver:2,bronze:0,total:2},{athlete:"Andreas Kofler",age:21,country:"Austria",year:2006,date:"26/02/2006",sport:"Ski Jumping",gold:1,silver:1,bronze:0,total:2},{athlete:"Roar Ljøkelsøy",age:29,country:"Norway",year:2006,date:"26/02/2006",sport:"Ski Jumping",gold:0,silver:0,bronze:2,total:2},{athlete:"Thomas Morgenstern",age:19,country:"Austria",year:2006,date:"26/02/2006",sport:"Ski Jumping",gold:2,silver:0,bronze:0,total:2},{athlete:"Simon Ammann",age:20,country:"Switzerland",year:2002,date:"24/02/2002",sport:"Ski Jumping",gold:2,silver:0,bronze:0,total:2},{athlete:"Sven Hannawald",age:27,country:"Germany",year:2002,date:"24/02/2002",sport:"Ski Jumping",gold:1,silver:1,bronze:0,total:2},{athlete:"Matti Hautamäki",age:20,country:"Finland",year:2002,date:"24/02/2002",sport:"Ski Jumping",gold:0,silver:1,bronze:1,total:2},{athlete:"Adam Malysz",age:24,country:"Poland",year:2002,date:"24/02/2002",sport:"Ski Jumping",gold:0,silver:1,bronze:1,total:2},{athlete:"Niccolò Campriani",age:24,country:"Italy",year:2012,date:"12/08/2012",sport:"Shooting",gold:1,silver:1,bronze:0,total:2},{athlete:"Jin Jong-O",age:32,country:"South Korea",year:2012,date:"12/08/2012",sport:"Shooting",gold:2,silver:0,bronze:0,total:2},{athlete:"Olena Kostevych",age:27,country:"Ukraine",year:2012,date:"12/08/2012",sport:"Shooting",gold:0,silver:0,bronze:2,total:2},{athlete:"Jin Jong-O",age:28,country:"South Korea",year:2008,date:"24/08/2008",sport:"Shooting",gold:1,silver:1,bronze:0,total:2},{athlete:"Katerina Kurková-Emmons",age:24,country:"Czech Republic",year:2008,date:"24/08/2008",sport:"Shooting",gold:1,silver:1,bronze:0,total:2},{athlete:"Lyubov Galkina",age:31,country:"Russia",year:2004,date:"29/08/2004",sport:"Shooting",gold:1,silver:1,bronze:0,total:2},{athlete:"Mariya Grozdeva",age:32,country:"Bulgaria",year:2004,date:"29/08/2004",sport:"Shooting",gold:1,silver:0,bronze:1,total:2},{athlete:"Lee Bo-Na",age:23,country:"South Korea",year:2004,date:"29/08/2004",sport:"Shooting",gold:0,silver:1,bronze:1,total:2},{athlete:"Mikhail Nestruyev",age:35,country:"Russia",year:2004,date:"29/08/2004",sport:"Shooting",gold:1,silver:1,bronze:0,total:2},{athlete:"Igor Basinsky",age:37,country:"Belarus",year:2e3,date:"01/10/2000",sport:"Shooting",gold:0,silver:1,bronze:1,total:2},{athlete:"Tao Luna",age:26,country:"China",year:2e3,date:"01/10/2000",sport:"Shooting",gold:1,silver:1,bronze:0,total:2},{athlete:"Kim Crow",age:26,country:"Australia",year:2012,date:"12/08/2012",sport:"Rowing",gold:0,silver:1,bronze:1,total:2},{athlete:"Georgeta Damian-Andrunache",age:32,country:"Romania",year:2008,date:"24/08/2008",sport:"Rowing",gold:1,silver:0,bronze:1,total:2},{athlete:"Viorica Susanu",age:32,country:"Romania",year:2008,date:"24/08/2008",sport:"Rowing",gold:1,silver:0,bronze:1,total:2},{athlete:"Georgeta Damian-Andrunache",age:28,country:"Romania",year:2004,date:"29/08/2004",sport:"Rowing",gold:2,silver:0,bronze:0,total:2},{athlete:"Viorica Susanu",age:28,country:"Romania",year:2004,date:"29/08/2004",sport:"Rowing",gold:2,silver:0,bronze:0,total:2},{athlete:"Georgeta Damian-Andrunache",age:24,country:"Romania",year:2e3,date:"01/10/2000",sport:"Rowing",gold:2,silver:0,bronze:0,total:2},{athlete:"Doina Ignat",age:31,country:"Romania",year:2e3,date:"01/10/2000",sport:"Rowing",gold:2,silver:0,bronze:0,total:2},{athlete:"Pieta van Dishoeck",age:28,country:"Netherlands",year:2e3,date:"01/10/2000",sport:"Rowing",gold:0,silver:2,bronze:0,total:2},{athlete:"Eeke van Nes",age:31,country:"Netherlands",year:2e3,date:"01/10/2000",sport:"Rowing",gold:0,silver:2,bronze:0,total:2},{athlete:"Bill Demong",age:29,country:"United States",year:2010,date:"28/02/2010",sport:"Nordic Combined",gold:1,silver:1,bronze:0,total:2},{athlete:"Bernhard Gruber",age:27,country:"Austria",year:2010,date:"28/02/2010",sport:"Nordic Combined",gold:1,silver:0,bronze:1,total:2},{athlete:"Magnus Moan",age:22,country:"Norway",year:2006,date:"26/02/2006",sport:"Nordic Combined",gold:0,silver:1,bronze:1,total:2},{athlete:"Ronny Ackermann",age:24,country:"Germany",year:2002,date:"24/02/2002",sport:"Nordic Combined",gold:0,silver:2,bronze:0,total:2},{athlete:"Jaakko Tallus",age:20,country:"Finland",year:2002,date:"24/02/2002",sport:"Nordic Combined",gold:1,silver:1,bronze:0,total:2},{athlete:"Denis Ablyazin",age:19,country:"Russia",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Chen Yibing",age:27,country:"China",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:1,silver:1,bronze:0,total:2},{athlete:"Gabby Douglas",age:16,country:"United States",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:2,silver:0,bronze:0,total:2},{athlete:"Feng Zhe",age:24,country:"China",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:2,silver:0,bronze:0,total:2},{athlete:"Sandra Izbasa",age:22,country:"Romania",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:1,silver:0,bronze:1,total:2},{athlete:"Viktoriya Komova",age:17,country:"Russia",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:0,silver:2,bronze:0,total:2},{athlete:"McKayla Maroney",age:16,country:"United States",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:1,silver:1,bronze:0,total:2},{athlete:"Marcel Nguyen",age:24,country:"Germany",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:0,silver:2,bronze:0,total:2},{athlete:"Mariya Paseka",age:17,country:"Russia",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Catalina Ponor",age:24,country:"Romania",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Louis Smith",age:23,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Max Whitlock",age:19,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Gymnastics",gold:0,silver:0,bronze:2,total:2},{athlete:"Chen Yibing",age:23,country:"China",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:2,silver:0,bronze:0,total:2},{athlete:"Anton Golotsutskov",age:23,country:"Russia",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:0,silver:0,bronze:2,total:2},{athlete:"He Kexin",age:16,country:"China",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:2,silver:0,bronze:0,total:2},{athlete:"Jonathan Horton",age:22,country:"United States",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Sandra Izbasa",age:18,country:"Romania",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:1,silver:0,bronze:1,total:2},{athlete:"Li Xiaopeng",age:27,country:"China",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:2,silver:0,bronze:0,total:2},{athlete:"Kohei Uchimura",age:19,country:"Japan",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:0,silver:2,bronze:0,total:2},{athlete:"Xiao Qin",age:23,country:"China",year:2008,date:"24/08/2008",sport:"Gymnastics",gold:2,silver:0,bronze:0,total:2},{athlete:"Alexandra Eremia",age:17,country:"Romania",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:1,silver:0,bronze:1,total:2},{athlete:"Annia Hatch",age:26,country:"United States",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:0,silver:2,bronze:0,total:2},{athlete:"Terin Humphrey",age:18,country:"United States",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:0,silver:2,bronze:0,total:2},{athlete:"Takehiro Kashima",age:24,country:"Japan",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:1,silver:0,bronze:1,total:2},{athlete:"Svetlana Khorkina",age:25,country:"Russia",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Courtney Kupets",age:18,country:"United States",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Anna Pavlova",age:16,country:"Russia",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:0,silver:0,bronze:2,total:2},{athlete:"Monica Rosu",age:17,country:"Romania",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:2,silver:0,bronze:0,total:2},{athlete:"Dana Sofronie",age:16,country:"Romania",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:1,silver:1,bronze:0,total:2},{athlete:"Hiroyuki Tomita",age:23,country:"Japan",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:1,silver:1,bronze:0,total:2},{athlete:"Marius Urzica",age:28,country:"Romania",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Isao Yoneda",age:26,country:"Japan",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:1,silver:0,bronze:1,total:2},{athlete:"Yordan Yovchev",age:31,country:"Bulgaria",year:2004,date:"29/08/2004",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Oleksandr Beresh",age:22,country:"Ukraine",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Aleksey Bondarenko",age:22,country:"Russia",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Lee Ju-Hyeong",age:27,country:"South Korea",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Li Xiaopeng",age:19,country:"China",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:2,silver:0,bronze:0,total:2},{athlete:"Liu Xuan",age:21,country:"China",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:1,silver:0,bronze:1,total:2},{athlete:"Maria Olaru",age:18,country:"Romania",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:1,silver:1,bronze:0,total:2},{athlete:"Yelena Produnova",age:20,country:"Russia",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:0,silver:1,bronze:1,total:2},{athlete:"Andreea Raducan",age:16,country:"Romania",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:1,silver:1,bronze:0,total:2},{athlete:"Yang Wei",age:20,country:"China",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:1,silver:1,bronze:0,total:2},{athlete:"Yordan Yovchev",age:27,country:"Bulgaria",year:2e3,date:"01/10/2000",sport:"Gymnastics",gold:0,silver:0,bronze:2,total:2},{athlete:"Elisa Di Francisca",age:29,country:"Italy",year:2012,date:"12/08/2012",sport:"Fencing",gold:2,silver:0,bronze:0,total:2},{athlete:"Arianna Errigo",age:24,country:"Italy",year:2012,date:"12/08/2012",sport:"Fencing",gold:1,silver:1,bronze:0,total:2},{athlete:"Diego Occhiuzzi",age:31,country:"Italy",year:2012,date:"12/08/2012",sport:"Fencing",gold:0,silver:1,bronze:1,total:2},{athlete:"Sun Yujie",age:19,country:"China",year:2012,date:"12/08/2012",sport:"Fencing",gold:1,silver:0,bronze:1,total:2},{athlete:"Valentina Vezzali",age:38,country:"Italy",year:2012,date:"12/08/2012",sport:"Fencing",gold:1,silver:0,bronze:1,total:2},{athlete:"Stefano Carozzo",age:29,country:"Italy",year:2008,date:"24/08/2008",sport:"Fencing",gold:0,silver:0,bronze:2,total:2},{athlete:"Margherita Granbassi",age:28,country:"Italy",year:2008,date:"24/08/2008",sport:"Fencing",gold:0,silver:0,bronze:2,total:2},{athlete:"Sada Jacobson",age:25,country:"United States",year:2008,date:"24/08/2008",sport:"Fencing",gold:0,silver:1,bronze:1,total:2},{athlete:"Fabrice Jeannet",age:27,country:"France",year:2008,date:"24/08/2008",sport:"Fencing",gold:1,silver:1,bronze:0,total:2},{athlete:"Nicolas Lopez",age:27,country:"France",year:2008,date:"24/08/2008",sport:"Fencing",gold:1,silver:1,bronze:0,total:2},{athlete:"Matteo Tagliariol",age:25,country:"Italy",year:2008,date:"24/08/2008",sport:"Fencing",gold:1,silver:0,bronze:1,total:2},{athlete:"Valentina Vezzali",age:34,country:"Italy",year:2008,date:"24/08/2008",sport:"Fencing",gold:1,silver:0,bronze:1,total:2},{athlete:"Becca Ward",age:18,country:"United States",year:2008,date:"24/08/2008",sport:"Fencing",gold:0,silver:0,bronze:2,total:2},{athlete:"Mariel Zagunis",age:23,country:"United States",year:2008,date:"24/08/2008",sport:"Fencing",gold:1,silver:0,bronze:1,total:2},{athlete:"Andrea Cassarà",age:20,country:"Italy",year:2004,date:"29/08/2004",sport:"Fencing",gold:1,silver:0,bronze:1,total:2},{athlete:"Laura Flessel-Colovic",age:32,country:"France",year:2004,date:"29/08/2004",sport:"Fencing",gold:0,silver:1,bronze:1,total:2},{athlete:"Aldo Montano",age:25,country:"Italy",year:2004,date:"29/08/2004",sport:"Fencing",gold:1,silver:1,bronze:0,total:2},{athlete:"Maureen Nisima",age:23,country:"France",year:2004,date:"29/08/2004",sport:"Fencing",gold:0,silver:0,bronze:2,total:2},{athlete:"Salvatore Sanzo",age:28,country:"Italy",year:2004,date:"29/08/2004",sport:"Fencing",gold:1,silver:1,bronze:0,total:2},{athlete:"Mathieu Gourdain",age:26,country:"France",year:2e3,date:"01/10/2000",sport:"Fencing",gold:0,silver:2,bronze:0,total:2},{athlete:"Gianna Hablützel-Bürki",age:30,country:"Switzerland",year:2e3,date:"01/10/2000",sport:"Fencing",gold:0,silver:2,bronze:0,total:2},{athlete:"Rita König",age:23,country:"Germany",year:2e3,date:"01/10/2000",sport:"Fencing",gold:0,silver:1,bronze:1,total:2},{athlete:"Wiradech Kothny",age:21,country:"Germany",year:2e3,date:"01/10/2000",sport:"Fencing",gold:0,silver:0,bronze:2,total:2},{athlete:"Hugues Obry",age:27,country:"France",year:2e3,date:"01/10/2000",sport:"Fencing",gold:0,silver:2,bronze:0,total:2},{athlete:"Giovanna Trillini",age:30,country:"Italy",year:2e3,date:"01/10/2000",sport:"Fencing",gold:1,silver:0,bronze:1,total:2},{athlete:"Valentina Vezzali",age:26,country:"Italy",year:2e3,date:"01/10/2000",sport:"Fencing",gold:2,silver:0,bronze:0,total:2},{athlete:"Sandra Auffarth",age:25,country:"Germany",year:2012,date:"12/08/2012",sport:"Equestrian",gold:1,silver:0,bronze:1,total:2},{athlete:"Laura Bechtolsheimer",age:27,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Equestrian",gold:1,silver:0,bronze:1,total:2},{athlete:"Adelinde Cornelissen",age:33,country:"Netherlands",year:2012,date:"12/08/2012",sport:"Equestrian",gold:0,silver:1,bronze:1,total:2},{athlete:"Charlotte Dujardin",age:27,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Equestrian",gold:2,silver:0,bronze:0,total:2},{athlete:"Michael Jung",age:29,country:"Germany",year:2012,date:"12/08/2012",sport:"Equestrian",gold:2,silver:0,bronze:0,total:2},{athlete:"Gerco Schröder",age:34,country:"Netherlands",year:2012,date:"12/08/2012",sport:"Equestrian",gold:0,silver:2,bronze:0,total:2},{athlete:"Tina Cook",age:37,country:"Great Britain",year:2008,date:"24/08/2008",sport:"Equestrian",gold:0,silver:0,bronze:2,total:2},{athlete:"Heike Kemmer",age:46,country:"Germany",year:2008,date:"24/08/2008",sport:"Equestrian",gold:1,silver:0,bronze:1,total:2},{athlete:"Eric Lamaze",age:40,country:"Canada",year:2008,date:"24/08/2008",sport:"Equestrian",gold:1,silver:1,bronze:0,total:2},{athlete:"Beezie Madden",age:44,country:"United States",year:2008,date:"24/08/2008",sport:"Equestrian",gold:1,silver:0,bronze:1,total:2},{athlete:"Hinrich Romeike",age:45,country:"Germany",year:2008,date:"24/08/2008",sport:"Equestrian",gold:2,silver:0,bronze:0,total:2},{athlete:"Anky van Grunsven",age:40,country:"Netherlands",year:2008,date:"24/08/2008",sport:"Equestrian",gold:1,silver:1,bronze:0,total:2},{athlete:"Isabell Werth",age:39,country:"Germany",year:2008,date:"24/08/2008",sport:"Equestrian",gold:1,silver:1,bronze:0,total:2},{athlete:"Beatriz Ferrer-Salat",age:38,country:"Spain",year:2004,date:"29/08/2004",sport:"Equestrian",gold:0,silver:1,bronze:1,total:2},{athlete:"Pippa Funnell",age:35,country:"Great Britain",year:2004,date:"29/08/2004",sport:"Equestrian",gold:0,silver:1,bronze:1,total:2},{athlete:"Chris Kappler",age:37,country:"United States",year:2004,date:"29/08/2004",sport:"Equestrian",gold:1,silver:1,bronze:0,total:2},{athlete:"Marco Kutscher",age:29,country:"Germany",year:2004,date:"29/08/2004",sport:"Equestrian",gold:0,silver:0,bronze:2,total:2},{athlete:"Leslie Law",age:39,country:"Great Britain",year:2004,date:"29/08/2004",sport:"Equestrian",gold:1,silver:1,bronze:0,total:2},{athlete:"Ulla Salzgeber",age:46,country:"Germany",year:2004,date:"29/08/2004",sport:"Equestrian",gold:1,silver:1,bronze:0,total:2},{athlete:"Kim Severson",age:30,country:"United States",year:2004,date:"29/08/2004",sport:"Equestrian",gold:0,silver:1,bronze:1,total:2},{athlete:"Andrew Hoy",age:41,country:"Australia",year:2e3,date:"01/10/2000",sport:"Equestrian",gold:1,silver:1,bronze:0,total:2},{athlete:"David O'Connor",age:38,country:"United States",year:2e3,date:"01/10/2000",sport:"Equestrian",gold:1,silver:0,bronze:1,total:2},{athlete:"Ulla Salzgeber",age:42,country:"Germany",year:2e3,date:"01/10/2000",sport:"Equestrian",gold:1,silver:0,bronze:1,total:2},{athlete:"Anky van Grunsven",age:32,country:"Netherlands",year:2e3,date:"01/10/2000",sport:"Equestrian",gold:1,silver:1,bronze:0,total:2},{athlete:"Isabell Werth",age:31,country:"Germany",year:2e3,date:"01/10/2000",sport:"Equestrian",gold:1,silver:1,bronze:0,total:2},{athlete:"David Boudia",age:23,country:"United States",year:2012,date:"12/08/2012",sport:"Diving",gold:1,silver:0,bronze:1,total:2},{athlete:"Chen Ruolin",age:19,country:"China",year:2012,date:"12/08/2012",sport:"Diving",gold:2,silver:0,bronze:0,total:2},{athlete:"He Zi",age:21,country:"China",year:2012,date:"12/08/2012",sport:"Diving",gold:1,silver:1,bronze:0,total:2},{athlete:"Qin Kai",age:26,country:"China",year:2012,date:"12/08/2012",sport:"Diving",gold:1,silver:1,bronze:0,total:2},{athlete:"Wu Minxia",age:26,country:"China",year:2012,date:"12/08/2012",sport:"Diving",gold:2,silver:0,bronze:0,total:2},{athlete:"Ilya Zakharov",age:21,country:"Russia",year:2012,date:"12/08/2012",sport:"Diving",gold:1,silver:1,bronze:0,total:2},{athlete:"Chen Ruolin",age:15,country:"China",year:2008,date:"24/08/2008",sport:"Diving",gold:2,silver:0,bronze:0,total:2},{athlete:"Gleb Galperin",age:25,country:"Russia",year:2008,date:"24/08/2008",sport:"Diving",gold:0,silver:0,bronze:2,total:2},{athlete:"Guo Jingjing",age:26,country:"China",year:2008,date:"24/08/2008",sport:"Diving",gold:2,silver:0,bronze:0,total:2},{athlete:"Yuliya Pakhalina",age:30,country:"Russia",year:2008,date:"24/08/2008",sport:"Diving",gold:0,silver:2,bronze:0,total:2},{athlete:"Qin Kai",age:22,country:"China",year:2008,date:"24/08/2008",sport:"Diving",gold:1,silver:0,bronze:1,total:2},{athlete:"Wang Xin",age:16,country:"China",year:2008,date:"24/08/2008",sport:"Diving",gold:1,silver:0,bronze:1,total:2},{athlete:"Wu Minxia",age:22,country:"China",year:2008,date:"24/08/2008",sport:"Diving",gold:1,silver:0,bronze:1,total:2},{athlete:"Guo Jingjing",age:22,country:"China",year:2004,date:"29/08/2004",sport:"Diving",gold:2,silver:0,bronze:0,total:2},{athlete:"Mathew Helm",age:23,country:"Australia",year:2004,date:"29/08/2004",sport:"Diving",gold:0,silver:1,bronze:1,total:2},{athlete:"Lao Lishi",age:16,country:"China",year:2004,date:"29/08/2004",sport:"Diving",gold:1,silver:1,bronze:0,total:2},{athlete:"Chantelle Michell-Newbery",age:27,country:"Australia",year:2004,date:"29/08/2004",sport:"Diving",gold:1,silver:0,bronze:1,total:2},{athlete:"Robert Newbery",age:25,country:"Australia",year:2004,date:"29/08/2004",sport:"Diving",gold:0,silver:0,bronze:2,total:2},{athlete:"Yuliya Pakhalina",age:26,country:"Russia",year:2004,date:"29/08/2004",sport:"Diving",gold:0,silver:1,bronze:1,total:2},{athlete:"Tian Liang",age:24,country:"China",year:2004,date:"29/08/2004",sport:"Diving",gold:1,silver:0,bronze:1,total:2},{athlete:"Wu Minxia",age:18,country:"China",year:2004,date:"29/08/2004",sport:"Diving",gold:1,silver:1,bronze:0,total:2},{athlete:"Fu Mingxia",age:22,country:"China",year:2e3,date:"01/10/2000",sport:"Diving",gold:1,silver:1,bronze:0,total:2},{athlete:"Guo Jingjing",age:18,country:"China",year:2e3,date:"01/10/2000",sport:"Diving",gold:0,silver:2,bronze:0,total:2},{athlete:"Hu Jia",age:17,country:"China",year:2e3,date:"01/10/2000",sport:"Diving",gold:0,silver:2,bronze:0,total:2},{athlete:"Li Na",age:16,country:"China",year:2e3,date:"01/10/2000",sport:"Diving",gold:1,silver:1,bronze:0,total:2},{athlete:"Anne Montminy",age:25,country:"Canada",year:2e3,date:"01/10/2000",sport:"Diving",gold:0,silver:1,bronze:1,total:2},{athlete:"Tian Liang",age:21,country:"China",year:2e3,date:"01/10/2000",sport:"Diving",gold:1,silver:1,bronze:0,total:2},{athlete:"Xiong Ni",age:26,country:"China",year:2e3,date:"01/10/2000",sport:"Diving",gold:2,silver:0,bronze:0,total:2},{athlete:"Grégory Baugé",age:27,country:"France",year:2012,date:"12/08/2012",sport:"Cycling",gold:0,silver:2,bronze:0,total:2},{athlete:"Ed Clancy",age:27,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Cycling",gold:1,silver:0,bronze:1,total:2},{athlete:"Sarah Hammer",age:28,country:"United States",year:2012,date:"12/08/2012",sport:"Cycling",gold:0,silver:2,bronze:0,total:2},{athlete:"Chris Hoy",age:36,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Cycling",gold:2,silver:0,bronze:0,total:2},{athlete:"Jason Kenny",age:24,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Cycling",gold:2,silver:0,bronze:0,total:2},{athlete:"Maximilian Levy",age:25,country:"Germany",year:2012,date:"12/08/2012",sport:"Cycling",gold:0,silver:1,bronze:1,total:2},{athlete:"Anna Meares",age:28,country:"Australia",year:2012,date:"12/08/2012",sport:"Cycling",gold:1,silver:0,bronze:1,total:2},{athlete:"Vicki Pendleton",age:31,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Cycling",gold:1,silver:1,bronze:0,total:2},{athlete:"Laura Trott",age:20,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Cycling",gold:2,silver:0,bronze:0,total:2},{athlete:"Olga Zabelinskaya",age:32,country:"Russia",year:2012,date:"12/08/2012",sport:"Cycling",gold:0,silver:0,bronze:2,total:2},{athlete:"Mickaël Bourgain",age:28,country:"France",year:2008,date:"24/08/2008",sport:"Cycling",gold:0,silver:1,bronze:1,total:2},{athlete:"Fabian Cancellara",age:27,country:"Switzerland",year:2008,date:"24/08/2008",sport:"Cycling",gold:1,silver:1,bronze:0,total:2},{athlete:"Jason Kenny",age:20,country:"Great Britain",year:2008,date:"24/08/2008",sport:"Cycling",gold:1,silver:1,bronze:0,total:2},{athlete:"Joan Llaneras",age:39,country:"Spain",year:2008,date:"24/08/2008",sport:"Cycling",gold:1,silver:1,bronze:0,total:2},{athlete:"Hayden Roulston",age:27,country:"New Zealand",year:2008,date:"24/08/2008",sport:"Cycling",gold:0,silver:1,bronze:1,total:2},{athlete:"Bradley Wiggins",age:28,country:"Great Britain",year:2008,date:"24/08/2008",sport:"Cycling",gold:2,silver:0,bronze:0,total:2},{athlete:"Ryan Bayley",age:22,country:"Australia",year:2004,date:"29/08/2004",sport:"Cycling",gold:2,silver:0,bronze:0,total:2},{athlete:"Graeme Brown",age:25,country:"Australia",year:2004,date:"29/08/2004",sport:"Cycling",gold:2,silver:0,bronze:0,total:2},{athlete:"Sergi Escobar",age:29,country:"Spain",year:2004,date:"29/08/2004",sport:"Cycling",gold:0,silver:0,bronze:2,total:2},{athlete:"Rob Hayles",age:31,country:"Great Britain",year:2004,date:"29/08/2004",sport:"Cycling",gold:0,silver:1,bronze:1,total:2},{athlete:"Brad McGee",age:28,country:"Australia",year:2004,date:"29/08/2004",sport:"Cycling",gold:1,silver:1,bronze:0,total:2},{athlete:"Anna Meares",age:20,country:"Australia",year:2004,date:"29/08/2004",sport:"Cycling",gold:1,silver:0,bronze:1,total:2},{athlete:"Stefan Nimke",age:26,country:"Germany",year:2004,date:"29/08/2004",sport:"Cycling",gold:1,silver:0,bronze:1,total:2},{athlete:"Olga Slyusareva",age:35,country:"Russia",year:2004,date:"29/08/2004",sport:"Cycling",gold:1,silver:0,bronze:1,total:2},{athlete:"Arnaud Tournant",age:26,country:"France",year:2004,date:"29/08/2004",sport:"Cycling",gold:0,silver:1,bronze:1,total:2},{athlete:"René Wolff",age:26,country:"Germany",year:2004,date:"29/08/2004",sport:"Cycling",gold:1,silver:0,bronze:1,total:2},{athlete:"Leontien Zijlaard-van Moorsel",age:34,country:"Netherlands",year:2004,date:"29/08/2004",sport:"Cycling",gold:1,silver:0,bronze:1,total:2},{athlete:"Félicia Ballanger",age:29,country:"France",year:2e3,date:"01/10/2000",sport:"Cycling",gold:2,silver:0,bronze:0,total:2},{athlete:"Robert Bartko",age:24,country:"Germany",year:2e3,date:"01/10/2000",sport:"Cycling",gold:2,silver:0,bronze:0,total:2},{athlete:"Jens Fiedler",age:30,country:"Germany",year:2e3,date:"01/10/2000",sport:"Cycling",gold:0,silver:0,bronze:2,total:2},{athlete:"Jens Lehmann",age:32,country:"Germany",year:2e3,date:"01/10/2000",sport:"Cycling",gold:1,silver:1,bronze:0,total:2},{athlete:"Gary Neiwand",age:34,country:"Australia",year:2e3,date:"01/10/2000",sport:"Cycling",gold:0,silver:1,bronze:1,total:2},{athlete:"Jason Queally",age:30,country:"Great Britain",year:2e3,date:"01/10/2000",sport:"Cycling",gold:1,silver:1,bronze:0,total:2},{athlete:"Jan Ullrich",age:26,country:"Germany",year:2e3,date:"01/10/2000",sport:"Cycling",gold:1,silver:1,bronze:0,total:2},{athlete:"Lukáš Bauer",age:32,country:"Czech Republic",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:0,silver:0,bronze:2,total:2},{athlete:"Anna Haag",age:23,country:"Sweden",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:0,silver:2,bronze:0,total:2},{athlete:"Marcus Hellner",age:24,country:"Sweden",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:2,silver:0,bronze:0,total:2},{athlete:"Charlotte Kalla",age:22,country:"Sweden",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:1,silver:1,bronze:0,total:2},{athlete:"Claudia Künzel-Nystad",age:32,country:"Germany",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:1,silver:1,bronze:0,total:2},{athlete:"Aino-Kaisa Saarinen",age:31,country:"Finland",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:0,silver:0,bronze:2,total:2},{athlete:"Evi Sachenbacher-Stehle",age:29,country:"Germany",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:1,silver:1,bronze:0,total:2},{athlete:"Axel Teichmann",age:30,country:"Germany",year:2010,date:"28/02/2010",sport:"Cross Country Skiing",gold:0,silver:2,bronze:0,total:2},{athlete:"Tobias Angerer",age:28,country:"Germany",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:0,silver:1,bronze:1,total:2},{athlete:"Yuliya Chepalova",age:29,country:"Russia",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:1,silver:1,bronze:0,total:2},{athlete:"Yevgeny Dementyev",age:23,country:"Russia",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:1,silver:1,bronze:0,total:2},{athlete:"Giorgio Di Centa",age:33,country:"Italy",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:2,silver:0,bronze:0,total:2},{athlete:"Thobias Fredriksson",age:30,country:"Sweden",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:1,silver:0,bronze:1,total:2},{athlete:"Claudia Künzel-Nystad",age:28,country:"Germany",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:0,silver:2,bronze:0,total:2},{athlete:"Björn Lind",age:27,country:"Sweden",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:2,silver:0,bronze:0,total:2},{athlete:"Yevgeniya Medvedeva",age:29,country:"Russia",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:1,silver:0,bronze:1,total:2},{athlete:"Katerina Neumannová",age:32,country:"Czech Republic",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:1,silver:1,bronze:0,total:2},{athlete:"Pietro Piller Cottrer",age:31,country:"Italy",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:1,silver:0,bronze:1,total:2},{athlete:"Kristina Šmigun-Vähi",age:28,country:"Estonia",year:2006,date:"26/02/2006",sport:"Cross Country Skiing",gold:2,silver:0,bronze:0,total:2},{athlete:"Thomas Alsgaard",age:30,country:"Norway",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:2,silver:0,bronze:0,total:2},{athlete:"Viola Bauer",age:25,country:"Germany",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:1,silver:0,bronze:1,total:2},{athlete:"Anita Moen-Guidon",age:34,country:"Norway",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:0,silver:1,bronze:1,total:2},{athlete:"Katerina Neumannová",age:28,country:"Czech Republic",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:0,silver:2,bronze:0,total:2},{athlete:"Evi Sachenbacher-Stehle",age:21,country:"Germany",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:1,silver:1,bronze:0,total:2},{athlete:"Kristen Skjeldal",age:34,country:"Norway",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:1,silver:0,bronze:1,total:2},{athlete:"Andrus Veerpalu",age:31,country:"Estonia",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:1,silver:1,bronze:0,total:2},{athlete:"Cristian Zorzi",age:29,country:"Italy",year:2002,date:"24/02/2002",sport:"Cross Country Skiing",gold:0,silver:1,bronze:1,total:2},{athlete:"Tina Dietze",age:24,country:"Germany",year:2012,date:"12/08/2012",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Natasa Douchev-Janics",age:30,country:"Hungary",year:2012,date:"12/08/2012",sport:"Canoeing",gold:0,silver:1,bronze:1,total:2},{athlete:"Katalin Kovács",age:36,country:"Hungary",year:2012,date:"12/08/2012",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Danuta Kozák",age:25,country:"Hungary",year:2012,date:"12/08/2012",sport:"Canoeing",gold:2,silver:0,bronze:0,total:2},{athlete:"Inna Osypenko-Radomska",age:29,country:"Ukraine",year:2012,date:"12/08/2012",sport:"Canoeing",gold:0,silver:2,bronze:0,total:2},{athlete:"Franziska Weber",age:23,country:"Germany",year:2012,date:"12/08/2012",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Tim Brabants",age:31,country:"Great Britain",year:2008,date:"24/08/2008",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"David Cal",age:25,country:"Spain",year:2008,date:"24/08/2008",sport:"Canoeing",gold:0,silver:2,bronze:0,total:2},{athlete:"Natasa Douchev-Janics",age:26,country:"Hungary",year:2008,date:"24/08/2008",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Christian Gille",age:32,country:"Germany",year:2008,date:"24/08/2008",sport:"Canoeing",gold:0,silver:1,bronze:1,total:2},{athlete:"Katalin Kovács",age:32,country:"Hungary",year:2008,date:"24/08/2008",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Vadim Makhnyov",age:28,country:"Belarus",year:2008,date:"24/08/2008",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"Roman Petrushenko",age:27,country:"Belarus",year:2008,date:"24/08/2008",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"Katrin Wagner-Augustin",age:30,country:"Germany",year:2008,date:"24/08/2008",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"Ken Wallace",age:25,country:"Australia",year:2008,date:"24/08/2008",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"Tomasz Wylenzek",age:25,country:"Germany",year:2008,date:"24/08/2008",sport:"Canoeing",gold:0,silver:1,bronze:1,total:2},{athlete:"Nathan Baggaley",age:28,country:"Australia",year:2004,date:"29/08/2004",sport:"Canoeing",gold:0,silver:2,bronze:0,total:2},{athlete:"David Cal",age:21,country:"Spain",year:2004,date:"29/08/2004",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Andreas Dittmer",age:32,country:"Germany",year:2004,date:"29/08/2004",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Natasa Douchev-Janics",age:22,country:"Hungary",year:2004,date:"29/08/2004",sport:"Canoeing",gold:2,silver:0,bronze:0,total:2},{athlete:"Birgit Fischer-Schmidt",age:42,country:"Germany",year:2004,date:"29/08/2004",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Aleksandr Kostoglod",age:30,country:"Russia",year:2004,date:"29/08/2004",sport:"Canoeing",gold:0,silver:1,bronze:1,total:2},{athlete:"Katalin Kovács",age:28,country:"Hungary",year:2004,date:"29/08/2004",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Aleksandr Kovalyov",age:29,country:"Russia",year:2004,date:"29/08/2004",sport:"Canoeing",gold:0,silver:1,bronze:1,total:2},{athlete:"Eirik Verås Larsen",age:28,country:"Norway",year:2004,date:"29/08/2004",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"Carolin Leonhardt",age:19,country:"Germany",year:2004,date:"29/08/2004",sport:"Canoeing",gold:1,silver:1,bronze:0,total:2},{athlete:"Adam Van Koeverden",age:22,country:"Canada",year:2004,date:"29/08/2004",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"Andreas Dittmer",age:28,country:"Germany",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"Birgit Fischer-Schmidt",age:38,country:"Germany",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:2,silver:0,bronze:0,total:2},{athlete:"Knut Holmann",age:32,country:"Norway",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:2,silver:0,bronze:0,total:2},{athlete:"Zoltán Kammerer",age:22,country:"Hungary",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:2,silver:0,bronze:0,total:2},{athlete:"Katalin Kovács",age:24,country:"Hungary",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:0,silver:2,bronze:0,total:2},{athlete:"Petar Merkov",age:23,country:"Bulgaria",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:0,silver:2,bronze:0,total:2},{athlete:"Florin Popescu",age:26,country:"Romania",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"Mitica Pricop",age:22,country:"Romania",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:1,silver:0,bronze:1,total:2},{athlete:"Botond Storcz",age:25,country:"Hungary",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:2,silver:0,bronze:0,total:2},{athlete:"Szilvia Szabó",age:21,country:"Hungary",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:0,silver:2,bronze:0,total:2},{athlete:"Katrin Wagner-Augustin",age:22,country:"Germany",year:2e3,date:"01/10/2000",sport:"Canoeing",gold:2,silver:0,bronze:0,total:2},{athlete:"Kevin Kuske",age:31,country:"Germany",year:2010,date:"28/02/2010",sport:"Bobsleigh",gold:1,silver:1,bronze:0,total:2},{athlete:"André Lange",age:36,country:"Germany",year:2010,date:"28/02/2010",sport:"Bobsleigh",gold:1,silver:1,bronze:0,total:2},{athlete:"Martin Annen",age:32,country:"Switzerland",year:2006,date:"26/02/2006",sport:"Bobsleigh",gold:0,silver:0,bronze:2,total:2},{athlete:"Beat Hefti",age:28,country:"Switzerland",year:2006,date:"26/02/2006",sport:"Bobsleigh",gold:0,silver:0,bronze:2,total:2},{athlete:"Kevin Kuske",age:27,country:"Germany",year:2006,date:"26/02/2006",sport:"Bobsleigh",gold:2,silver:0,bronze:0,total:2},{athlete:"André Lange",age:32,country:"Germany",year:2006,date:"26/02/2006",sport:"Bobsleigh",gold:2,silver:0,bronze:0,total:2},{athlete:"Ole Einar Bjørndalen",age:36,country:"Norway",year:2010,date:"28/02/2010",sport:"Biathlon",gold:1,silver:1,bronze:0,total:2},{athlete:"Marie Laure Brunet",age:21,country:"France",year:2010,date:"28/02/2010",sport:"Biathlon",gold:0,silver:1,bronze:1,total:2},{athlete:"Marie Dorin",age:23,country:"France",year:2010,date:"28/02/2010",sport:"Biathlon",gold:0,silver:1,bronze:1,total:2},{athlete:"Simone Hauswald",age:30,country:"Germany",year:2010,date:"28/02/2010",sport:"Biathlon",gold:0,silver:0,bronze:2,total:2},{athlete:"Vincent Jay",age:24,country:"France",year:2010,date:"28/02/2010",sport:"Biathlon",gold:1,silver:0,bronze:1,total:2},{athlete:"Anastasia Kuzmina",age:25,country:"Slovakia",year:2010,date:"28/02/2010",sport:"Biathlon",gold:1,silver:1,bronze:0,total:2},{athlete:"Christoph Sumann",age:34,country:"Austria",year:2010,date:"28/02/2010",sport:"Biathlon",gold:0,silver:2,bronze:0,total:2},{athlete:"Yevgeny Ustyugov",age:24,country:"Russia",year:2010,date:"28/02/2010",sport:"Biathlon",gold:1,silver:0,bronze:1,total:2},{athlete:"Olga Zaytseva",age:31,country:"Russia",year:2010,date:"28/02/2010",sport:"Biathlon",gold:1,silver:1,bronze:0,total:2},{athlete:"Florence Baverel-Robert",age:31,country:"France",year:2006,date:"26/02/2006",sport:"Biathlon",gold:1,silver:0,bronze:1,total:2},{athlete:"Vincent Defrasne",age:28,country:"France",year:2006,date:"26/02/2006",sport:"Biathlon",gold:1,silver:0,bronze:1,total:2},{athlete:"Halvard Hanevold",age:36,country:"Norway",year:2006,date:"26/02/2006",sport:"Biathlon",gold:0,silver:1,bronze:1,total:2},{athlete:"Svetlana Ishmuratova",age:33,country:"Russia",year:2006,date:"26/02/2006",sport:"Biathlon",gold:2,silver:0,bronze:0,total:2},{athlete:"Anna-Carin Olofsson-Zidek",age:32,country:"Sweden",year:2006,date:"26/02/2006",sport:"Biathlon",gold:1,silver:1,bronze:0,total:2},{athlete:"Uschi Disl",age:31,country:"Germany",year:2002,date:"24/02/2002",sport:"Biathlon",gold:1,silver:1,bronze:0,total:2},{athlete:"Sven Fischer",age:30,country:"Germany",year:2002,date:"24/02/2002",sport:"Biathlon",gold:0,silver:2,bronze:0,total:2},{athlete:"Ricco Groß",age:31,country:"Germany",year:2002,date:"24/02/2002",sport:"Biathlon",gold:0,silver:1,bronze:1,total:2},{athlete:"Andrea Henkel",age:24,country:"Germany",year:2002,date:"24/02/2002",sport:"Biathlon",gold:2,silver:0,bronze:0,total:2},{athlete:"Frank Luck",age:34,country:"Germany",year:2002,date:"24/02/2002",sport:"Biathlon",gold:0,silver:2,bronze:0,total:2},{athlete:"Raphaël Poirée",age:27,country:"France",year:2002,date:"24/02/2002",sport:"Biathlon",gold:0,silver:1,bronze:1,total:2},{athlete:"Olga Pylyova-Medvedtseva",age:26,country:"Russia",year:2002,date:"24/02/2002",sport:"Biathlon",gold:1,silver:0,bronze:1,total:2},{athlete:"Liv Grete Skjelbreid-Poirée",age:27,country:"Norway",year:2002,date:"24/02/2002",sport:"Biathlon",gold:0,silver:2,bronze:0,total:2},{athlete:"Magdalena Wallin-Forsberg",age:34,country:"Sweden",year:2002,date:"24/02/2002",sport:"Biathlon",gold:0,silver:0,bronze:2,total:2},{athlete:"Zhao Yunlei",age:25,country:"China",year:2012,date:"12/08/2012",sport:"Badminton",gold:2,silver:0,bronze:0,total:2},{athlete:"Lee Hyo-Jeong",age:27,country:"South Korea",year:2008,date:"24/08/2008",sport:"Badminton",gold:1,silver:1,bronze:0,total:2},{athlete:"Yu Yang",age:22,country:"China",year:2008,date:"24/08/2008",sport:"Badminton",gold:1,silver:0,bronze:1,total:2},{athlete:"Gao Ling",age:25,country:"China",year:2004,date:"29/08/2004",sport:"Badminton",gold:1,silver:1,bronze:0,total:2},{athlete:"Gao Ling",age:21,country:"China",year:2e3,date:"01/10/2000",sport:"Badminton",gold:1,silver:0,bronze:1,total:2},{athlete:"Nataliya Antyukh",age:31,country:"Russia",year:2012,date:"12/08/2012",sport:"Athletics",gold:1,silver:1,bronze:0,total:2},{athlete:"Veronica Campbell-Brown",age:30,country:"Jamaica",year:2012,date:"12/08/2012",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Vivian Cheruiyot",age:28,country:"Kenya",year:2012,date:"12/08/2012",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Will Claye",age:21,country:"United States",year:2012,date:"12/08/2012",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Tirunesh Dibaba",age:27,country:"Ethiopia",year:2012,date:"12/08/2012",sport:"Athletics",gold:1,silver:0,bronze:1,total:2},{athlete:"Mo Farah",age:29,country:"Great Britain",year:2012,date:"12/08/2012",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Justin Gatlin",age:30,country:"United States",year:2012,date:"12/08/2012",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Lalonde Gordon",age:23,country:"Trinidad and Tobago",year:2012,date:"12/08/2012",sport:"Athletics",gold:0,silver:0,bronze:2,total:2},{athlete:"Sanya Richards-Ross",age:27,country:"United States",year:2012,date:"12/08/2012",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"DeeDee Trotter",age:29,country:"United States",year:2012,date:"12/08/2012",sport:"Athletics",gold:1,silver:0,bronze:1,total:2},{athlete:"Elvan Abeylegesse",age:25,country:"Turkey",year:2008,date:"24/08/2008",sport:"Athletics",gold:0,silver:2,bronze:0,total:2},{athlete:"Kenenisa Bekele",age:26,country:"Ethiopia",year:2008,date:"24/08/2008",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Kerron Clement",age:22,country:"United States",year:2008,date:"24/08/2008",sport:"Athletics",gold:1,silver:1,bronze:0,total:2},{athlete:"Tirunesh Dibaba",age:23,country:"Ethiopia",year:2008,date:"24/08/2008",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Walter Dix",age:22,country:"United States",year:2008,date:"24/08/2008",sport:"Athletics",gold:0,silver:0,bronze:2,total:2},{athlete:"Allyson Felix",age:22,country:"United States",year:2008,date:"24/08/2008",sport:"Athletics",gold:1,silver:1,bronze:0,total:2},{athlete:"Yuliya Gushchina",age:25,country:"Russia",year:2008,date:"24/08/2008",sport:"Athletics",gold:1,silver:1,bronze:0,total:2},{athlete:"Tatyana Lebedeva",age:32,country:"Russia",year:2008,date:"24/08/2008",sport:"Athletics",gold:0,silver:2,bronze:0,total:2},{athlete:"LaShawn Merritt",age:22,country:"United States",year:2008,date:"24/08/2008",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"David Neville",age:24,country:"United States",year:2008,date:"24/08/2008",sport:"Athletics",gold:1,silver:0,bronze:1,total:2},{athlete:"Sanya Richards-Ross",age:23,country:"United States",year:2008,date:"24/08/2008",sport:"Athletics",gold:1,silver:0,bronze:1,total:2},{athlete:"Kerron Stewart",age:24,country:"Jamaica",year:2008,date:"24/08/2008",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Jared Tallent",age:23,country:"Australia",year:2008,date:"24/08/2008",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Angelo Taylor",age:29,country:"United States",year:2008,date:"24/08/2008",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Richard Thompson",age:23,country:"Trinidad and Tobago",year:2008,date:"24/08/2008",sport:"Athletics",gold:0,silver:2,bronze:0,total:2},{athlete:"Jeremy Wariner",age:24,country:"United States",year:2008,date:"24/08/2008",sport:"Athletics",gold:1,silver:1,bronze:0,total:2},{athlete:"Shericka Williams",age:22,country:"Jamaica",year:2008,date:"24/08/2008",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Nataliya Antyukh",age:23,country:"Russia",year:2004,date:"29/08/2004",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Kenenisa Bekele",age:22,country:"Ethiopia",year:2004,date:"29/08/2004",sport:"Athletics",gold:1,silver:1,bronze:0,total:2},{athlete:"Derrick Brew",age:26,country:"United States",year:2004,date:"29/08/2004",sport:"Athletics",gold:1,silver:0,bronze:1,total:2},{athlete:"Shawn Crawford",age:26,country:"United States",year:2004,date:"29/08/2004",sport:"Athletics",gold:1,silver:1,bronze:0,total:2},{athlete:"Hicham El Guerrouj",age:29,country:"Morocco",year:2004,date:"29/08/2004",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Maurice Greene",age:30,country:"United States",year:2004,date:"29/08/2004",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Otis Harris",age:22,country:"United States",year:2004,date:"29/08/2004",sport:"Athletics",gold:1,silver:1,bronze:0,total:2},{athlete:"Kelly Holmes",age:34,country:"Great Britain",year:2004,date:"29/08/2004",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Tatyana Lebedeva",age:28,country:"Russia",year:2004,date:"29/08/2004",sport:"Athletics",gold:1,silver:0,bronze:1,total:2},{athlete:"Jeremy Wariner",age:20,country:"United States",year:2004,date:"29/08/2004",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Ato Boldon",age:26,country:"Trinidad and Tobago",year:2e3,date:"01/10/2000",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Pauline Davis-Thompson",age:34,country:"Bahamas",year:2e3,date:"01/10/2000",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Lorraine Graham",age:27,country:"Jamaica",year:2e3,date:"01/10/2000",sport:"Athletics",gold:0,silver:2,bronze:0,total:2},{athlete:"Maurice Greene",age:26,country:"United States",year:2e3,date:"01/10/2000",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Greg Haughton",age:26,country:"Jamaica",year:2e3,date:"01/10/2000",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Deon Hemmings",age:31,country:"Jamaica",year:2e3,date:"01/10/2000",sport:"Athletics",gold:0,silver:2,bronze:0,total:2},{athlete:"Robert Korzeniowski",age:32,country:"Poland",year:2e3,date:"01/10/2000",sport:"Athletics",gold:2,silver:0,bronze:0,total:2},{athlete:"Tayna Lawrence",age:25,country:"Jamaica",year:2e3,date:"01/10/2000",sport:"Athletics",gold:0,silver:2,bronze:0,total:2},{athlete:"Beverly McDonald",age:30,country:"Jamaica",year:2e3,date:"01/10/2000",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Merlene Ottey-Page",age:40,country:"Jamaica",year:2e3,date:"01/10/2000",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Irina Privalova",age:31,country:"Russia",year:2e3,date:"01/10/2000",sport:"Athletics",gold:1,silver:0,bronze:1,total:2},{athlete:"Gabriela Szabo",age:24,country:"Romania",year:2e3,date:"01/10/2000",sport:"Athletics",gold:1,silver:0,bronze:1,total:2},{athlete:"Gete Wami",age:25,country:"Ethiopia",year:2e3,date:"01/10/2000",sport:"Athletics",gold:0,silver:1,bronze:1,total:2},{athlete:"Elisabeth Görgl",age:28,country:"Austria",year:2010,date:"28/02/2010",sport:"Alpine Skiing",gold:0,silver:0,bronze:2,total:2},{athlete:"Lindsey Kildow-Vonn",age:25,country:"United States",year:2010,date:"28/02/2010",sport:"Alpine Skiing",gold:1,silver:0,bronze:1,total:2},{athlete:"Ivica Kostelic",age:30,country:"Croatia",year:2010,date:"28/02/2010",sport:"Alpine Skiing",gold:0,silver:2,bronze:0,total:2},{athlete:"Julia Mancuso",age:25,country:"United States",year:2010,date:"28/02/2010",sport:"Alpine Skiing",gold:0,silver:2,bronze:0,total:2},{athlete:"Tina Maze",age:26,country:"Slovenia",year:2010,date:"28/02/2010",sport:"Alpine Skiing",gold:0,silver:2,bronze:0,total:2},{athlete:"Maria Riesch",age:25,country:"Germany",year:2010,date:"28/02/2010",sport:"Alpine Skiing",gold:2,silver:0,bronze:0,total:2},{athlete:"Michaela Dorfmeister",age:32,country:"Austria",year:2006,date:"26/02/2006",sport:"Alpine Skiing",gold:2,silver:0,bronze:0,total:2},{athlete:"Janica Kostelic",age:24,country:"Croatia",year:2006,date:"26/02/2006",sport:"Alpine Skiing",gold:1,silver:1,bronze:0,total:2},{athlete:"Hermann Maier",age:33,country:"Austria",year:2006,date:"26/02/2006",sport:"Alpine Skiing",gold:0,silver:1,bronze:1,total:2},{athlete:"Benjamin Raich",age:27,country:"Austria",year:2006,date:"26/02/2006",sport:"Alpine Skiing",gold:2,silver:0,bronze:0,total:2},{athlete:"Marlies Schild",age:24,country:"Austria",year:2006,date:"26/02/2006",sport:"Alpine Skiing",gold:0,silver:1,bronze:1,total:2},{athlete:"Rainer Schönfelder",age:28,country:"Austria",year:2006,date:"26/02/2006",sport:"Alpine Skiing",gold:0,silver:0,bronze:2,total:2},{athlete:"Kjetil André Aamodt",age:30,country:"Norway",year:2002,date:"24/02/2002",sport:"Alpine Skiing",gold:2,silver:0,bronze:0,total:2},{athlete:"Renate Götschl",age:26,country:"Austria",year:2002,date:"24/02/2002",sport:"Alpine Skiing",gold:0,silver:1,bronze:1,total:2},{athlete:"Lasse Kjus",age:31,country:"Norway",year:2002,date:"24/02/2002",sport:"Alpine Skiing",gold:0,silver:1,bronze:1,total:2},{athlete:"Bode Miller",age:24,country:"United States",year:2002,date:"24/02/2002",sport:"Alpine Skiing",gold:0,silver:2,bronze:0,total:2},{athlete:"Anja Pärson",age:20,country:"Sweden",year:2002,date:"24/02/2002",sport:"Alpine Skiing",gold:0,silver:1,bronze:1,total:2},{athlete:"Benjamin Raich",age:23,country:"Austria",year:2002,date:"24/02/2002",sport:"Alpine Skiing",gold:0,silver:0,bronze:2,total:2},{athlete:"Ki Bo-Bae",age:24,country:"South Korea",year:2012,date:"12/08/2012",sport:"Archery",gold:2,silver:0,bronze:0,total:2},{athlete:"Oh Jin-Hyek",age:30,country:"South Korea",year:2012,date:"12/08/2012",sport:"Archery",gold:1,silver:0,bronze:1,total:2},{athlete:"Park Gyeong-Mo",age:32,country:"South Korea",year:2008,date:"24/08/2008",sport:"Archery",gold:1,silver:1,bronze:0,total:2},{athlete:"Park Seong-Hyeon",age:25,country:"South Korea",year:2008,date:"24/08/2008",sport:"Archery",gold:1,silver:1,bronze:0,total:2},{athlete:"Yun Ok-Hui",age:23,country:"South Korea",year:2008,date:"24/08/2008",sport:"Archery",gold:1,silver:0,bronze:1,total:2},{athlete:"Zhang Juanjuan",age:27,country:"China",year:2008,date:"24/08/2008",sport:"Archery",gold:1,silver:1,bronze:0,total:2},{athlete:"Lee Seong-Jin",age:19,country:"South Korea",year:2004,date:"29/08/2004",sport:"Archery",gold:1,silver:1,bronze:0,total:2},{athlete:"Park Seong-Hyeon",age:21,country:"South Korea",year:2004,date:"29/08/2004",sport:"Archery",gold:2,silver:0,bronze:0,total:2},{athlete:"Kim Nam-Sun",age:20,country:"South Korea",year:2e3,date:"01/10/2000",sport:"Archery",gold:1,silver:1,bronze:0,total:2},{athlete:"Kim Su-Nyeong",age:29,country:"South Korea",year:2e3,date:"01/10/2000",sport:"Archery",gold:1,silver:0,bronze:1,total:2},{athlete:"Vic Wunderle",age:24,country:"United States",year:2e3,date:"01/10/2000",sport:"Archery",gold:0,silver:1,bronze:1,total:2},{athlete:"Yun Mi-Jin",age:17,country:"South Korea",year:2e3,date:"01/10/2000",sport:"Archery",gold:2,silver:0,bronze:0,total:2},{athlete:"Artur Aleksanyan",age:20,country:"Armenia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Valeriy Andriitsev",age:25,country:"Ukraine",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Rövs?n Bayramov",age:25,country:"Azerbaijan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Jordan Burroughs",age:24,country:"United States",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Clarissa Chun",age:30,country:"United States",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Yogeshwar Dutt",age:29,country:"India",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Jaime Espinal",age:27,country:"Puerto Rico",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Johan Eurén",age:27,country:"Sweden",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Karam Gaber",age:32,country:"Egypt",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Daniyal Gadzhiyev",age:26,country:"Kazakhstan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Komeil Ghasemi",age:24,country:"Iran",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Giorgi Gogshelidze",age:32,country:"Georgia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Sadegh Goudarzi",age:24,country:"Iran",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Steeve Guénot",age:26,country:"France",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Carol Huynh",age:31,country:"Canada",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Kaori Icho",age:28,country:"Japan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Damian Janikowski",age:23,country:"Poland",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Jing Ruixue",age:24,country:"China",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Arsen Julfalakyan",age:25,country:"Armenia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Riza Kayaalp",age:22,country:"Turkey",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Aleksandras Kazakevicius",age:26,country:"Lithuania",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Vladimer Khinchegashvili",age:21,country:"Georgia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Alan Khugayev",age:23,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Kim Hyeon-Wu",age:23,country:"South Korea",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Besik Kudukhov",age:25,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Sushil Kumar",age:29,country:"India",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Zaur Kuramagomedov",age:24,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Ehsan Naser Lashgari",age:26,country:"Iran",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Revaz Lashkhi",age:24,country:"Georgia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Jimmy Lidberg",age:30,country:"Sweden",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Liván López",age:30,country:"Cuba",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Mijaín López",age:29,country:"Cuba",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Tamás Lorincz",age:25,country:"Hungary",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Bilyal Makhov",age:24,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Gyuzel Manyurova",age:34,country:"Kazakhstan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Dato Marsagishvili",age:21,country:"Georgia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Ryutaro Matsumoto",age:26,country:"Japan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Péter Módos",age:24,country:"Hungary",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Davit Modzmanashvili",age:25,country:"Georgia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Heiki Nabi",age:27,country:"Estonia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Omid Noroozi",age:26,country:"Iran",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Hitomi Obara",age:31,country:"Japan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Dzhamal Otarsultanov",age:25,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Xetaq Qazyumov",age:29,country:"Azerbaijan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Yuliya Ratkeviç",age:27,country:"Azerbaijan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Jackeline Rentería",age:26,country:"Colombia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Ghasem Rezaei",age:26,country:"Iran",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Coleman Scott",age:26,country:"United States",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Mingiyan Semyonov",age:22,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Soronzonboldyn Battsetseg",age:22,country:"Mongolia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Hamid Soryan",age:26,country:"Iran",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Mariya Stadnik",age:24,country:"Azerbaijan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"S?rif S?rifov",age:23,country:"Azerbaijan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Akzhurek Tanatarov",age:25,country:"Kazakhstan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Artur Taymazov",age:33,country:"Uzbekistan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Soslan Tigiyev",age:28,country:"Uzbekistan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Rustam Totrov",age:28,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Denis Tsargush",age:24,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Manuchar Tskhadaia",age:27,country:"Georgia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Maider Unda",age:35,country:"Spain",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Jake Varner",age:26,country:"United States",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Tonya Verbeek",age:34,country:"Canada",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Roman Vlasov",age:21,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Lyubov Volosova",age:29,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Nataliya Vorobyova",age:21,country:"Russia",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Yang Kyong-Il",age:23,country:"North Korea",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Tatsuhiro Yonemitsu",age:26,country:"Japan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Saori Yoshida",age:29,country:"Japan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Shinichi Yumoto",age:27,country:"Japan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Stanka Zlateva",age:29,country:"Bulgaria",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Emin ?hm?dov",age:25,country:"Azerbaijan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Togrul ?sg?rov",age:19,country:"Azerbaijan",year:2012,date:"12/08/2012",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Yusuf Abdusalomov",age:30,country:"Tajikistan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Bakhtiyar Akhmedov",age:21,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Islam-Beka Albiyev",age:19,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Roman Amoyan",age:24,country:"Armenia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Nazmi Avluca",age:31,country:"Turkey",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Khasan Baroyev",age:25,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Mavlet Batyrov",age:24,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Rövs?n Bayramov",age:21,country:"Azerbaijan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Kanat Begaliyev",age:24,country:"Kyrgyzstan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Henry Cejudo",age:21,country:"United States",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Chang Yongxiang",age:24,country:"China",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Taras Danko",age:28,country:"Ukraine",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Mirko Englich",age:29,country:"Germany",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Vasyl Fedoryshyn",age:27,country:"Ukraine",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Zoltán Fodor",age:23,country:"Hungary",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Murad Gaydarov",age:28,country:"Belarus",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Giorgi Gogshelidze",age:28,country:"Georgia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Christophe Guénot",age:29,country:"France",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Steeve Guénot",age:22,country:"France",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Kyoko Hamaguchi",age:30,country:"Japan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Carol Huynh",age:27,country:"Canada",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Chiharu Icho",age:26,country:"Japan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Kaori Icho",age:24,country:"Japan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Manuchar K'virk'elia",age:29,country:"Georgia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Alyona Kartashova",age:26,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Georgy Ketoyev",age:22,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Aslanbek Khushtov",age:28,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Besik Kudukhov",age:22,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Sushil Kumar",age:25,country:"India",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Mijaín López",age:25,country:"Cuba",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Aset Mambetov",age:26,country:"Kazakhstan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Nazyr Mankiyev",age:23,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Tomohiro Matsunaga",age:28,country:"Japan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Iryna Merleni-Mykulchyn",age:26,country:"Ukraine",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Randi Miller",age:24,country:"United States",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Revaz Mindorashvili",age:32,country:"Georgia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Andrea Minguzzi",age:26,country:"Italy",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Mindaugas Mizgaitis",age:28,country:"Lithuania",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Seyed Mohammadi",age:28,country:"Iran",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Sharvani Muradov",age:23,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"David Musulbes",age:36,country:"Slovakia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Marid Mutalimov",age:28,country:"Kazakhstan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Park Eun-Chul",age:27,country:"South Korea",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Yury Patrikeyev",age:28,country:"Armenia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Xetaq Qazyumov",age:25,country:"Azerbaijan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Jackeline Rentería",age:22,country:"Colombia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Vitaliy R?himov",age:23,country:"Azerbaijan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Ramazan Sahin",age:25,country:"Turkey",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Buvaisa Saytiyev",age:33,country:"Russia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Mikhail Semyonov",age:24,country:"Belarus",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Yelena Shalygina",age:21,country:"Kazakhstan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Andriy Stadnik",age:26,country:"Ukraine",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Mariya Stadnik",age:20,country:"Azerbaijan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Artur Taymazov",age:29,country:"Uzbekistan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1},{athlete:"Nurbakyt Tengizbayev",age:25,country:"Kazakhstan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Kiril Terziev",age:24,country:"Bulgaria",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Soslan Tigiyev",age:24,country:"Uzbekistan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Taymuraz Tigiyev",age:26,country:"Kazakhstan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:1,bronze:0,total:1},{athlete:"Otar Tushishvili",age:30,country:"Georgia",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Ruslan Tyumenbayev",age:22,country:"Kyrgyzstan",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Armen Vardanian",age:25,country:"Ukraine",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Radoslav Velikov",age:24,country:"Bulgaria",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Tonya Verbeek",age:31,country:"Canada",year:2008,date:"24/08/2008",sport:"Wrestling",gold:0,silver:0,bronze:1,total:1},{athlete:"Wang Jiao",age:20,country:"China",year:2008,date:"24/08/2008",sport:"Wrestling",gold:1,silver:0,bronze:0,total:1}],Jfe=[["Swimming",[[{symbol:"foo"},{symbol:"df"},"green"]]],["Gymnastics",[[{symbol:"bar"},{symbol:"df"},"green","purple"]]],["Tennis",[]],["Speed Skating",[]]],Xfe=({selectedCategory:e,setSelectedCategory:t,setOperations:r})=>{const n=i=>{t(i.target.value),r([[{symbol:"sport"},{symbol:"df"},i.target.value]])};return M.jsx("div",{children:M.jsxs("label",{children:["Category:",M.jsx("select",{value:e,onChange:n,children:Jfe.map(([i])=>M.jsx("option",{value:i,children:i},i))})]})})};function Zfe(e){return Rt(e,(t,r)=>({...t,idx:r+1}))}function Qfe(e){return Rt(e,(t,r)=>({...t,agIdx:`${t.idx}-${t.sport}`}))}function ege(e,t){return LD(e,{sport:t})}const tge=e=>{const t=Qfe(Zfe(ege(Yfe,e)));return console.log("dataset retval",t),t},rge=({payloadArgs:e,on_payloadArgs:t,payloadResponse:r,operations:n})=>(console.log("here",e,t,r,n),M.jsx("h1",{children:"broken"})),xE=()=>{const[e,t]=v.useState("Tennis"),r={sourceName:"paddy",start:0,end:100},[n,i]=v.useState(r),o=c=>{const u=tge(e),d=u.slice(c.start,c.end);return console.log("infinite ex",e,u,c.start,c.end),{data:d,key:c,length:u.length}},[s,a]=v.useState([[{symbol:"sport"},{symbol:"df"},e]]),l=o(n);return M.jsxs("div",{children:[M.jsx(Xfe,{selectedCategory:e,setSelectedCategory:t,setOperations:a}),M.jsx(rge,{payloadArgs:n,on_payloadArgs:i,payloadResponse:l,operations:s})]})},$w="buckaroo-style-block",nge=e=>{if(document.getElementById($w)!==null)return;let t=Object.assign(document.createElement("style"),{id:$w,type:"text/css"});t.appendChild(document.createTextNode(e)),document.head.appendChild(t)},AE=Object.freeze(Object.defineProperty({__proto__:null,injectBuckarooCSS:nge},Symbol.toStringTag,{value:"Module"})),PE=({label:e,onClick:t})=>M.jsx("button",{onClick:t,children:e}),RE=()=>M.jsx("h1",{children:" Header NoArgs "}),Hw=({value:e,setValue:t})=>{const r=()=>{t(e+1)};return M.jsx("button",{onClick:r,children:e})},EE=()=>{const[e,t]=v.useState(1);return M.jsxs("div",{children:[M.jsx(Hw,{value:e,setValue:t}),M.jsx(Hw,{value:e,setValue:t})]})},ige={ColumnsEditor:Zu,DependentTabs:Qg,OperationViewer:Zg,WidgetDCFCell:UR,DFViewer:gu,DFViewerInfinite:ni,DFViewerInfiniteDS:yE,StatusBar:Ia,HistogramCell:Dm,CommandUtils:M2,utils:O2,BuckarooInfiniteWidget:vE,getKeySmartRowCache:mE,InfiniteEx:xE,widgetUtils:AE,SampleButton:PE,HeaderNoArgs:RE,Counter:EE,parquetRead:_a,parquetMetadata:ei,resolveDFData:Xc,resolveDFDataAsync:pa,preResolveDFDataDict:wE,BuckarooStaticTable:SE};exports.BuckarooInfiniteWidget=vE;exports.BuckarooStaticTable=SE;exports.ColumnsEditor=Zu;exports.CommandUtils=M2;exports.Counter=EE;exports.DFViewer=gu;exports.DFViewerInfinite=ni;exports.DFViewerInfiniteDS=yE;exports.DependentTabs=Qg;exports.HeaderNoArgs=RE;exports.HistogramCell=Dm;exports.InfiniteEx=xE;exports.OperationViewer=Zg;exports.SampleButton=PE;exports.StatusBar=Ia;exports.WidgetDCFCell=UR;exports.default=ige;exports.getKeySmartRowCache=mE;exports.parquetMetadata=ei;exports.parquetRead=_a;exports.preResolveDFDataDict=wE;exports.resolveDFData=Xc;exports.resolveDFDataAsync=pa;exports.utils=O2;exports.widgetUtils=AE;
114
+ //# sourceMappingURL=index.cjs.js.map